Fixed
Status Update
Comments
jb...@google.com <jb...@google.com> #2
Project: platform/frameworks/support
Branch: androidx-main
commit f0dc0968ae703e34aba39b2c6c836077c340d2a5
Author: Jeremy Woods <jbwoods@google.com>
Date: Wed Sep 01 15:34:41 2021
Make argument default params last
When generating an argument in kotlin from safe args, default parameters
should always come after none defaults in the argument's constructor.
RelNote: "When generating arguments, safe args now puts parameters
without default values before those with default values."
Test: ./gradlew --rerun-tasks
navigation:navigation-safe-args-generator:test
Bug: 198493585
Change-Id: I8970968c48deb3a1437437df9a3db696ed497372
M navigation/navigation-safe-args-generator/src/main/kotlin/androidx/navigation/safe/args/generator/kotlin/KotlinNavWriter.kt
M navigation/navigation-safe-args-generator/src/test/test-data/expected/kotlin_nav_writer_test/MainFragmentArgs.kt
https://android-review.googlesource.com/1816980
Branch: androidx-main
commit f0dc0968ae703e34aba39b2c6c836077c340d2a5
Author: Jeremy Woods <jbwoods@google.com>
Date: Wed Sep 01 15:34:41 2021
Make argument default params last
When generating an argument in kotlin from safe args, default parameters
should always come after none defaults in the argument's constructor.
RelNote: "When generating arguments, safe args now puts parameters
without default values before those with default values."
Test: ./gradlew --rerun-tasks
navigation:navigation-safe-args-generator:test
Bug: 198493585
Change-Id: I8970968c48deb3a1437437df9a3db696ed497372
M navigation/navigation-safe-args-generator/src/main/kotlin/androidx/navigation/safe/args/generator/kotlin/KotlinNavWriter.kt
M navigation/navigation-safe-args-generator/src/test/test-data/expected/kotlin_nav_writer_test/MainFragmentArgs.kt
ap...@google.com <ap...@google.com> #3
This has been fixed internally and will be available in the Navigation 2.4.0-alpha09
release.
ap...@google.com <ap...@google.com> #4
Problem as a result of this in alpha09, it will now generate broken code when nullable parameters are before non-nullable parameters in the navigation resource file.
ap...@google.com <ap...@google.com> #5
Re
In the future, please always file regressions as new bugs with a sample project that reproduces your issue rather than commenting on issues already marked as fixed - that way we can properly track those fixes for the next release.
jb...@google.com <jb...@google.com> #6
This has been fixed internally and will be in the Navigation 2.6.0-alpha05
and Fragment 1.6.0-alpha05
releases.
pr...@google.com <pr...@google.com> #7
The following release(s) address this bug.It is possible this bug has only been partially addressed:
androidx.fragment:fragment:1.6.0-alpha05
androidx.navigation:navigation-common:2.6.0-alpha05
androidx.navigation:navigation-fragment:2.6.0-alpha05
androidx.navigation:navigation-runtime:2.6.0-alpha05
androidx.navigation:navigation-testing:2.6.0-alpha05
Description
Navigation 2.4 introduced new Navigator APIs that were equipped to handle transitions, ensuring that NavBackStackEntries would always be in the proper state. (i.e.
STARTED
until the incoming transition completes then movingRESUMED
orCREATED
until the outgoing transition completes and then moving toDESTROYED
).Now that these APIs are available, they should also be implemented in Navigation with Fragments. This would ensure that the state of Fragment also follows the same conventions of NavBackStackEntry and provides properly Lifecycle updates while handling animations, animators, and transitions.