Fixed
Status Update
Comments
ti...@google.com <ti...@google.com>
ib...@google.com <ib...@google.com> #2
Navigation is built with Support Library Fragments so has no access to the FragmentFactory itself. I think we can make some minor changes to FragmentNavigator to make it easy for developers who are using Navigation 1.0 and Fragments 1.1.0 together to call through to their FragmentFactory.
Once Navigation switches to AndroidX (post 1.0), we'll use FragmentFactory directly.
Once Navigation switches to AndroidX (post 1.0), we'll use FragmentFactory directly.
ma...@gmail.com <ma...@gmail.com> #3
Project: platform/frameworks/support
Branch: androidx-master-dev
commit 1b215f0d93828286782776b9a12d2387097947f9
Author: Ian Lake <ilake@google.com>
Date: Sun Nov 25 21:45:56 2018
Move Fragment creation to FragmentNavigator
Provide an instantiateFragment() method on
FragmentNavigator which serves as the
centralized place to instantiate new
Fragment instances for FragmentNavigator.
Besides moving this business logic out of
the dumb POJO FragmentNavigator.Destination,
this also provides a future extension point
for integrating in FragmentFactory.
Test: existing tests passes, testapp still works
BUG: 119054429
Change-Id: If60471a704ef77bc35b30838e152a31cde8bc235
M navigation/fragment/ktx/src/androidTest/java/androidx/navigation/fragment/FragmentNavigatorDestinationBuilderTest.kt
M navigation/fragment/ktx/src/main/java/androidx/navigation/fragment/FragmentNavigatorDestinationBuilder.kt
M navigation/fragment/src/androidTest/java/androidx/navigation/fragment/FragmentNavigatorTest.kt
M navigation/fragment/src/main/java/androidx/navigation/fragment/FragmentNavigator.java
https://android-review.googlesource.com/835682
https://goto.google.com/android-sha1/1b215f0d93828286782776b9a12d2387097947f9
Branch: androidx-master-dev
commit 1b215f0d93828286782776b9a12d2387097947f9
Author: Ian Lake <ilake@google.com>
Date: Sun Nov 25 21:45:56 2018
Move Fragment creation to FragmentNavigator
Provide an instantiateFragment() method on
FragmentNavigator which serves as the
centralized place to instantiate new
Fragment instances for FragmentNavigator.
Besides moving this business logic out of
the dumb POJO FragmentNavigator.Destination,
this also provides a future extension point
for integrating in FragmentFactory.
Test: existing tests passes, testapp still works
BUG: 119054429
Change-Id: If60471a704ef77bc35b30838e152a31cde8bc235
M navigation/fragment/ktx/src/androidTest/java/androidx/navigation/fragment/FragmentNavigatorDestinationBuilderTest.kt
M navigation/fragment/ktx/src/main/java/androidx/navigation/fragment/FragmentNavigatorDestinationBuilder.kt
M navigation/fragment/src/androidTest/java/androidx/navigation/fragment/FragmentNavigatorTest.kt
M navigation/fragment/src/main/java/androidx/navigation/fragment/FragmentNavigator.java
ib...@google.com <ib...@google.com> #4
Navigation still depends on Support Library and not AndroidX, so we can't directly use FragmentFactory in FragmentNavigator.
However, in alpha08, you'll be able to subclass FragmentNavigator and override instantiateFragment(), calling into FragmentFactory if you're using AndroidX Fragment 1.1.0+. You'd also need to subclass NavHostFragment and override createFragmentNavigator() to return your custom FragmentNavigator subclass (or, if you're not using app:navGraph, you can set it via navHostFragment.navController.navigatorProvider += YourFragmentNavigator(context, navHostFragment.childFragmentManager)).
We'll keep this open until Navigation has moved to AndroidX and can directly use FragmentFactory as its default implementation of instantiateFragment().
However, in alpha08, you'll be able to subclass FragmentNavigator and override instantiateFragment(), calling into FragmentFactory if you're using AndroidX Fragment 1.1.0+. You'd also need to subclass NavHostFragment and override createFragmentNavigator() to return your custom FragmentNavigator subclass (or, if you're not using app:navGraph, you can set it via navHostFragment.navController.navigatorProvider += YourFragmentNavigator(context, navHostFragment.childFragmentManager)).
We'll keep this open until Navigation has moved to AndroidX and can directly use FragmentFactory as its default implementation of instantiateFragment().
ma...@gmail.com <ma...@gmail.com> #5
Thanks for the workaround in alpha08!
ma...@gmail.com <ma...@gmail.com> #6
Can't wait to use this library after the move to AndroidX.
For us is a major blocking feature and we don't want to proceed overriding all the necessary classes.
Thank you Ian and the rest of the navigation team.
For us is a major blocking feature and we don't want to proceed overriding all the necessary classes.
Thank you Ian and the rest of the navigation team.
ib...@google.com <ib...@google.com> #7
Project: platform/frameworks/support
Branch: androidx-master-dev
commit 74c3760e428648d00249dc1d38865b7802f48a9a
Author: Ian Lake <ilake@google.com>
Date: Wed Mar 13 13:11:57 2019
Use FragmentFactory in FragmentNavigator
Rely on the FragmentManager's FragmentFactory
to instantiate Fragments created for
FragmentNavigator.
Test: new FragmentNavigatorTest
Fixes: 119054429
Change-Id: Icbeb2771e29cafdc52e4c4ea770ce89f739921d1
M navigation/fragment/src/androidTest/java/androidx/navigation/fragment/FragmentNavigatorTest.kt
M navigation/fragment/src/main/java/androidx/navigation/fragment/FragmentNavigator.java
https://android-review.googlesource.com/928481
https://goto.google.com/android-sha1/74c3760e428648d00249dc1d38865b7802f48a9a
Branch: androidx-master-dev
commit 74c3760e428648d00249dc1d38865b7802f48a9a
Author: Ian Lake <ilake@google.com>
Date: Wed Mar 13 13:11:57 2019
Use FragmentFactory in FragmentNavigator
Rely on the FragmentManager's FragmentFactory
to instantiate Fragments created for
FragmentNavigator.
Test: new FragmentNavigatorTest
Fixes: 119054429
Change-Id: Icbeb2771e29cafdc52e4c4ea770ce89f739921d1
M navigation/fragment/src/androidTest/java/androidx/navigation/fragment/FragmentNavigatorTest.kt
M navigation/fragment/src/main/java/androidx/navigation/fragment/FragmentNavigator.java
ib...@google.com <ib...@google.com> #8
This is fixed internally - FragmentNavigator will use the FragmentFactory to create Fragments in the upcoming 2.1.0-alpha01 release.
ib...@google.com <ib...@google.com>
ap...@google.com <ap...@google.com> #9
Thank you Ian :)
ap...@google.com <ap...@google.com> #10
Project: platform/frameworks/support
Branch: androidx-master-dev
commit 3dd6d1fcdb3ffa7d4bd265a023f0ac7c94e14d19
Author: Ian Lake <ilake@google.com>
Date: Mon Mar 18 09:36:37 2019
Deprecate FragmentNavigator.instantiateFragment
Instead of providing a custom subclass of
FragmentNavigator, instantiation of Fragments
should be controlled by setting a custom
FragmentFactory, which is the default behavior
of instantiateFragment() now.
By deprecating the class, we ensure that
developers who were overriding this method
are informed of the changes and can change
their code to use FragmentFactory.
Test: ./gradlew checkApi
BUG: 119054429
Change-Id: Iff46919face98baa6dc62835ca3fc105d987d141
M navigation/fragment/api/2.1.0-alpha01.txt
M navigation/fragment/api/current.txt
M navigation/fragment/src/main/java/androidx/navigation/fragment/FragmentNavigator.java
https://android-review.googlesource.com/930120
https://goto.google.com/android-sha1/3dd6d1fcdb3ffa7d4bd265a023f0ac7c94e14d19
Branch: androidx-master-dev
commit 3dd6d1fcdb3ffa7d4bd265a023f0ac7c94e14d19
Author: Ian Lake <ilake@google.com>
Date: Mon Mar 18 09:36:37 2019
Deprecate FragmentNavigator.instantiateFragment
Instead of providing a custom subclass of
FragmentNavigator, instantiation of Fragments
should be controlled by setting a custom
FragmentFactory, which is the default behavior
of instantiateFragment() now.
By deprecating the class, we ensure that
developers who were overriding this method
are informed of the changes and can change
their code to use FragmentFactory.
Test: ./gradlew checkApi
BUG: 119054429
Change-Id: Iff46919face98baa6dc62835ca3fc105d987d141
M navigation/fragment/api/2.1.0-alpha01.txt
M navigation/fragment/api/current.txt
M navigation/fragment/src/main/java/androidx/navigation/fragment/FragmentNavigator.java
ap...@google.com <ap...@google.com> #11
Project: platform/frameworks/support
Branch: androidx-main
commit c23003716636d5c161e9b8c5d139ebbde0b7c8b5
Author: Ian Baker <ibaker@google.com>
Date: Wed Apr 10 17:03:20 2024
Split GPS_TIMESTAMP handling from the rest of the backwards compat rational tags
This tag has different special handling to the rest in this set, so it
doesn't really make sense to include it here.
Bug: 312680558
Test: ExifInterfaceTest
Change-Id: Ibec7f06d8cfe2c7cd1edf029e32b002ce8e2e22b
M exifinterface/exifinterface/src/main/java/androidx/exifinterface/media/ExifInterface.java
https://android-review.googlesource.com/3039227
Branch: androidx-main
commit c23003716636d5c161e9b8c5d139ebbde0b7c8b5
Author: Ian Baker <ibaker@google.com>
Date: Wed Apr 10 17:03:20 2024
Split GPS_TIMESTAMP handling from the rest of the backwards compat rational tags
This tag has different special handling to the rest in this set, so it
doesn't really make sense to include it here.
Bug: 312680558
Test: ExifInterfaceTest
Change-Id: Ibec7f06d8cfe2c7cd1edf029e32b002ce8e2e22b
M exifinterface/exifinterface/src/main/java/androidx/exifinterface/media/ExifInterface.java
ap...@google.com <ap...@google.com> #12
Project: platform/frameworks/support
Branch: androidx-main
commit 34755e56581a1d2b474c2e556eab6b7c587aa116
Author: Ian Baker <ibaker@google.com>
Date: Wed Apr 03 14:10:27 2024
Improve precision of ExifInterface double -> rational conversion
Bug: 312680558
Test: ExifInterfaceTest
Change-Id: Iafd9736aab51fc627a7f25a11b9384b5008fb9bf
M exifinterface/exifinterface/src/androidTest/java/androidx/exifinterface/media/ExifInterfaceTest.java
M exifinterface/exifinterface/src/main/java/androidx/exifinterface/media/ExifInterface.java
https://android-review.googlesource.com/3025043
Branch: androidx-main
commit 34755e56581a1d2b474c2e556eab6b7c587aa116
Author: Ian Baker <ibaker@google.com>
Date: Wed Apr 03 14:10:27 2024
Improve precision of ExifInterface double -> rational conversion
Bug: 312680558
Test: ExifInterfaceTest
Change-Id: Iafd9736aab51fc627a7f25a11b9384b5008fb9bf
M exifinterface/exifinterface/src/androidTest/java/androidx/exifinterface/media/ExifInterfaceTest.java
M exifinterface/exifinterface/src/main/java/androidx/exifinterface/media/ExifInterface.java
ap...@google.com <ap...@google.com> #13
Project: platform/frameworks/support
Branch: androidx-main
commit 67282b9c5804e5b8bb28993e57940b322b963988
Author: Ian Baker <ibaker@google.com>
Date: Tue Apr 09 17:30:03 2024
Document ExifInterface 'rational' attributes returned as decimals
These specific attributes have special handling, for backwards
compatibility with the implementation of ExifInterface that preceded the
platform android.media.ExifInterface. See more context in this
internal code review comment from 2016:
http://ag/c/platform/frameworks/base/+/909922/2..9/api/current.txt#b20093
Also add tests for this handling, including the current behaviour of
rejecting/ignoring the 'correct' rational format when passed to
setAttribute(String, String). A follow-up change adds support for this
format (and updates these tests to reflect this).
Bug: 312680558
Test: ExifInterfaceTest
Change-Id: Ia09c2956f0f80279108ccf872174eb98214a38a8
M exifinterface/exifinterface/src/androidTest/java/androidx/exifinterface/media/ExifInterfaceTest.java
M exifinterface/exifinterface/src/main/java/androidx/exifinterface/media/ExifInterface.java
https://android-review.googlesource.com/3037113
Branch: androidx-main
commit 67282b9c5804e5b8bb28993e57940b322b963988
Author: Ian Baker <ibaker@google.com>
Date: Tue Apr 09 17:30:03 2024
Document ExifInterface 'rational' attributes returned as decimals
These specific attributes have special handling, for backwards
compatibility with the implementation of ExifInterface that preceded the
platform android.media.ExifInterface. See more context in this
internal code review comment from 2016:
Also add tests for this handling, including the current behaviour of
rejecting/ignoring the 'correct' rational format when passed to
setAttribute(String, String). A follow-up change adds support for this
format (and updates these tests to reflect this).
Bug: 312680558
Test: ExifInterfaceTest
Change-Id: Ia09c2956f0f80279108ccf872174eb98214a38a8
M exifinterface/exifinterface/src/androidTest/java/androidx/exifinterface/media/ExifInterfaceTest.java
M exifinterface/exifinterface/src/main/java/androidx/exifinterface/media/ExifInterface.java
ib...@google.com <ib...@google.com>
na...@google.com <na...@google.com> #14
The following release(s) address this bug.It is possible this bug has only been partially addressed:
androidx.exifinterface:exifinterface:1.4.0-alpha01
Description
Version used: 1.3.6
Devices/Android versions reproduced on: ALL
Steps to reproduce:
1. Create ExifInterface for an image file
2. Set time exposure attribute to value 0.000625 which corresponds to time exposure value of 1/1600
3. Save attributes to image file
Actual outcome:
- When reading exposure time value from that file the value is 0.0006, so it is truncated. This results in exposure time changed from 1/1600 to 1/1666.
Expected outcome:
- The exposure time value should be 0.000625 which corresponds to the expected exposure time value of 1/1600.
Reproducibility:
It seems to occur on all devices and all image files/formats. Likely the problem is that the double value is converted to rational value which has limited precision.