Fixed
Status Update
Comments
il...@google.com <il...@google.com> #2
since these are in public API (:/) we need to do this in 1.2
th...@gmail.com <th...@gmail.com> #3
since it is already marked as deprecated, we can probably do it by now.
il...@google.com <il...@google.com> #4
Opening diff shortly
ap...@google.com <ap...@google.com> #5
Project: platform/frameworks/support
Branch: androidx-master-dev
commit d576cbdc911cba16638a44fd8223391a90a07ef7
Author: Mike Nakhimovich <digitalbuddha@users.noreply.github.com>
Date: Tue Aug 11 09:30:34 2020
[GH] Hide deprecated internal API.
## Proposed Changes
* `RoomDatabase.java` has protected `mCallbacks` field which is leaking in the API docs, we should @Hide it.
## Testing
Test: Ran unit tests locally
## Issues Fixed
Fixes: 76109329
This is an imported pull request fromhttps://github.com/androidx/androidx/pull/61 .
Resolves #61
Github-Pr-Head-Sha: 6440daa3a63752c7f9d5ba2a390248cd85bc634f
GitOrigin-RevId: fe92d8466a59b44b218b6ca3cbd57dcda17992f7
Change-Id: Id599cdf5b02b32bdae0166266fb7da967598fe92
A room/runtime/api/current.ignore
M room/runtime/api/current.txt
M room/runtime/api/public_plus_experimental_current.txt
M room/runtime/api/restricted_current.txt
M room/runtime/src/main/java/androidx/room/RoomDatabase.java
https://android-review.googlesource.com/1396827
Branch: androidx-master-dev
commit d576cbdc911cba16638a44fd8223391a90a07ef7
Author: Mike Nakhimovich <digitalbuddha@users.noreply.github.com>
Date: Tue Aug 11 09:30:34 2020
[GH] Hide deprecated internal API.
## Proposed Changes
* `RoomDatabase.java` has protected `mCallbacks` field which is leaking in the API docs, we should @Hide it.
## Testing
Test: Ran unit tests locally
## Issues Fixed
Fixes: 76109329
This is an imported pull request from
Resolves #61
Github-Pr-Head-Sha: 6440daa3a63752c7f9d5ba2a390248cd85bc634f
GitOrigin-RevId: fe92d8466a59b44b218b6ca3cbd57dcda17992f7
Change-Id: Id599cdf5b02b32bdae0166266fb7da967598fe92
A room/runtime/api/current.ignore
M room/runtime/api/current.txt
M room/runtime/api/public_plus_experimental_current.txt
M room/runtime/api/restricted_current.txt
M room/runtime/src/main/java/androidx/room/RoomDatabase.java
ap...@google.com <ap...@google.com> #6
Project: platform/frameworks/support
Branch: androidx-master-dev
commit d5a1c250e6e3471297f64e116a46d1a3a5c9db6c
Author: Ian Lake <ilake@google.com>
Date: Wed Apr 24 15:37:02 2019
Use OnBackPressedCallback in NavController
Replace the brittle OnBackStackChangedListener
with an OnBackPressedCallback registered at the
NavController level which works on all Navigators.
It also helps fix a timing issue where the state
of the FragmentNavigator isn't updated after a Fragment
is popped off the stack, leading to a mismatch in
expected actions available if the newly visible Fragment
calls navigate() in a lifecycle method.
Test: updated tests, new OnBackPressedTest
BUG: 111598096
Change-Id: Id679ea6ac9b238240649656fc0796552d6191757
M navigation/common/api/restricted_2.1.0-alpha03.txt
M navigation/common/api/restricted_current.txt
M navigation/common/src/main/java/androidx/navigation/Navigator.java
M navigation/fragment/src/androidTest/AndroidManifest.xml
M navigation/fragment/src/androidTest/java/androidx/navigation/fragment/FragmentNavigatorTest.kt
A navigation/fragment/src/androidTest/java/androidx/navigation/fragment/OnBackPressedTest.kt
M navigation/fragment/src/androidTest/java/androidx/navigation/fragment/test/EmptyFragment.kt
A navigation/fragment/src/androidTest/java/androidx/navigation/fragment/test/NavigationActivity.kt
A navigation/fragment/src/androidTest/res/navigation/nav_simple.xml
M navigation/fragment/src/main/java/androidx/navigation/fragment/FragmentNavigator.java
M navigation/fragment/src/main/java/androidx/navigation/fragment/NavHostFragment.java
M navigation/runtime/api/2.1.0-alpha03.txt
M navigation/runtime/api/current.txt
M navigation/runtime/build.gradle
M navigation/runtime/src/androidTest/java/androidx/navigation/NavControllerTest.kt
M navigation/runtime/src/main/java/androidx/navigation/NavController.java
M navigation/runtime/src/main/java/androidx/navigation/NavHost.java
https://android-review.googlesource.com/951629
https://goto.google.com/android-sha1/d5a1c250e6e3471297f64e116a46d1a3a5c9db6c
Branch: androidx-master-dev
commit d5a1c250e6e3471297f64e116a46d1a3a5c9db6c
Author: Ian Lake <ilake@google.com>
Date: Wed Apr 24 15:37:02 2019
Use OnBackPressedCallback in NavController
Replace the brittle OnBackStackChangedListener
with an OnBackPressedCallback registered at the
NavController level which works on all Navigators.
It also helps fix a timing issue where the state
of the FragmentNavigator isn't updated after a Fragment
is popped off the stack, leading to a mismatch in
expected actions available if the newly visible Fragment
calls navigate() in a lifecycle method.
Test: updated tests, new OnBackPressedTest
BUG: 111598096
Change-Id: Id679ea6ac9b238240649656fc0796552d6191757
M navigation/common/api/restricted_2.1.0-alpha03.txt
M navigation/common/api/restricted_current.txt
M navigation/common/src/main/java/androidx/navigation/Navigator.java
M navigation/fragment/src/androidTest/AndroidManifest.xml
M navigation/fragment/src/androidTest/java/androidx/navigation/fragment/FragmentNavigatorTest.kt
A navigation/fragment/src/androidTest/java/androidx/navigation/fragment/OnBackPressedTest.kt
M navigation/fragment/src/androidTest/java/androidx/navigation/fragment/test/EmptyFragment.kt
A navigation/fragment/src/androidTest/java/androidx/navigation/fragment/test/NavigationActivity.kt
A navigation/fragment/src/androidTest/res/navigation/nav_simple.xml
M navigation/fragment/src/main/java/androidx/navigation/fragment/FragmentNavigator.java
M navigation/fragment/src/main/java/androidx/navigation/fragment/NavHostFragment.java
M navigation/runtime/api/2.1.0-alpha03.txt
M navigation/runtime/api/current.txt
M navigation/runtime/build.gradle
M navigation/runtime/src/androidTest/java/androidx/navigation/NavControllerTest.kt
M navigation/runtime/src/main/java/androidx/navigation/NavController.java
M navigation/runtime/src/main/java/androidx/navigation/NavHost.java
il...@google.com <il...@google.com> #7
NavController now offers new APIs to hook up to an OnBackPressedDispatcher: https://developer.android.com/guide/navigation/navigation-custom-back
Which allows NavController to intercept the back button before the FragmentManager, ensuring that we update our state before going through Lifecycle events and fixing this edge case.
This behavior is enabled by default if you're using NavHostFragment, but custom NavHosts can call through to this same API for their own Navigators and not try to intercept the back button themselves.
Which allows NavController to intercept the back button before the FragmentManager, ensuring that we update our state before going through Lifecycle events and fixing this edge case.
This behavior is enabled by default if you're using NavHostFragment, but custom NavHosts can call through to this same API for their own Navigators and not try to intercept the back button themselves.
il...@google.com <il...@google.com> #8
This will be available in Navigation 2.1.0-alpha03.
Description
Version used: 1.0.0-alpha03
Devices/Android versions reproduced on: All
Trying to navigate in onResume of a fragment is causing a crash if the fragment was popped to.
The attached project consists of three fragments: A, B, C.
A is the home fragment and has conditional navigation to B. The conditional navigation will be triggered when the app is started, and after fragment C has been shown.
When navigating to B from A at app start there are no issues. Going back to A, then tapping the button to navigate to C, and then going back will trigger the conditional navigation again and cause a crash.
Same problem exists in alpha02.