Fixed
Status Update
Comments
[Deleted User] <[Deleted User]> #2
After upgrading to fragment 1.3.3, I experienced an issue with espresso tests hanging on startup. I've traced the issue back to insets dispatching constantly, which never allows the app to become "idle", so espresso never proceeds with the tests. Our app does have a BottomNavigationView but it is outside of any FragmentContainerView.
il...@google.com <il...@google.com>
jb...@google.com <jb...@google.com> #3
There was something done with window insets on API 29 where they work differently than every other API. I am guessing if you did this on another API level everything works fine.
Adding Chris, Adrian, Jorim, and Paul to see if they have any ideas on how
ap...@google.com <ap...@google.com> #4
Project: platform/frameworks/support
Branch: androidx-main
commit ae19215aa71372218770972d89c1b65f463a8291
Author: Jeremy Woods <jbwoods@google.com>
Date: Wed Apr 28 15:57:15 2021
Fix window insets dispatch for API 29
Right now we call ViewCompat.onApplyWindowInsets from
FragmentContainerView's dispatchApplyWindowInsets method. When combined
with fitSystemWindows on API 29, fitSystemWindows kicks off its own
dispatch cycle, which makes us dispatch indefinitely.
We should override onApplyWindowInsets to simple return the given insets
so we properly stop dispatching insets.
RelNote: "When using `FragmentContainerView` on API 29, insets will no
longer dispatch indefinitely."
Test: FragmentContainerViewTest
Bug: 186012452
Change-Id: I1bb780dffcbbcb6a78fbfb74d288a3c0620a3a40
M fragment/fragment/src/androidTest/java/androidx/fragment/app/FragmentContainerViewTest.kt
M fragment/fragment/src/main/java/androidx/fragment/app/FragmentContainerView.java
https://android-review.googlesource.com/1690232
Branch: androidx-main
commit ae19215aa71372218770972d89c1b65f463a8291
Author: Jeremy Woods <jbwoods@google.com>
Date: Wed Apr 28 15:57:15 2021
Fix window insets dispatch for API 29
Right now we call ViewCompat.onApplyWindowInsets from
FragmentContainerView's dispatchApplyWindowInsets method. When combined
with fitSystemWindows on API 29, fitSystemWindows kicks off its own
dispatch cycle, which makes us dispatch indefinitely.
We should override onApplyWindowInsets to simple return the given insets
so we properly stop dispatching insets.
RelNote: "When using `FragmentContainerView` on API 29, insets will no
longer dispatch indefinitely."
Test: FragmentContainerViewTest
Bug: 186012452
Change-Id: I1bb780dffcbbcb6a78fbfb74d288a3c0620a3a40
M fragment/fragment/src/androidTest/java/androidx/fragment/app/FragmentContainerViewTest.kt
M fragment/fragment/src/main/java/androidx/fragment/app/FragmentContainerView.java
jb...@google.com <jb...@google.com> #5
This has been fixed internally and will be part of the Fragment 1.3.4
release.
Description
Version used: androidx.fragment:fragment-ktx:1.3.3
Devices/Android versions reproduced on: Google Pixel API 29
I've noticed that reveal animation on view outside fragment container not working on 1.3.3, when fragment container contains bottom nav (see videos).
It seems like an inset dispatching problem, cause logs shows a lot of useless inset events on reveal target view (see screenshots).
Test project also attached.