Status Update
Comments
ap...@google.com <ap...@google.com> #2
Branch: androidx-main
commit 57ca221882695bd6a52549f4d9ea3b812e6fe87c
Author: Simon Schiller <simonschiller@users.noreply.github.com>
Date: Mon Mar 22 16:09:30 2021
[GH] [FragmentStrictMode] Detect <fragment> tag usage
## Proposed Changes
- Detect `<fragment>` tag usage inside XML layouts
## Testing
Test: See `FragmentStrictModeTest#detectFragmentTagUsage`
## Issues Fixed
Fixes: 153738235
This is an imported pull request from
Resolves #141
Github-Pr-Head-Sha: 4ea052596e4341b9f11bcf335e2bc38045a91f19
GitOrigin-RevId: 62e7487aa4874eef6bb556490e193717cf937251
Change-Id: Iae48578e85e4e4897f806d7ade2e2a660adf9479
M fragment/fragment/api/public_plus_experimental_current.txt
M fragment/fragment/api/restricted_current.txt
M fragment/fragment/src/androidTest/java/androidx/fragment/app/strictmode/FragmentStrictModeTest.kt
M fragment/fragment/src/main/java/androidx/fragment/app/FragmentLayoutInflaterFactory.java
M fragment/fragment/src/main/java/androidx/fragment/app/strictmode/FragmentStrictMode.java
A fragment/fragment/src/main/java/androidx/fragment/app/strictmode/FragmentTagUsageViolation.java
jb...@google.com <jb...@google.com> #3
This has been added internally and will be available in the Fragment 1.7.0-alpha05
release.
ap...@google.com <ap...@google.com> #4
Branch: androidx-main
commit c250706435c04194eebb0f22168cad3e71ae6969
Author: Jeremy Woods <jbwoods@google.com>
Date: Mon Sep 11 18:43:01 2023
Actually turn on seeking for Androidx Transitions
We need to make sure the isSeekingSupport API with no params returns
true for AndroidX transitions.
Test: existing tests pass
Bug: 285175724
Change-Id: I1136e51712b09795b0d422ee93bc0a9cfd3e21e9
M transition/transition/src/main/java/androidx/transition/FragmentTransitionSupport.java
lb...@gmail.com <lb...@gmail.com> #5
Can the new predictive-back-gesture be applied nicely for Fragments inside navigation container, so that even when navigating between them, you will see what's behind, just like for Activities?
jb...@google.com <jb...@google.com> #6
If you depend on the next release of Fragments and Androidx Transitions, and you use those transitions when you navigate, yes you will.
lb...@gmail.com <lb...@gmail.com> #7
Or even better:
Change the new app wizard and have it there with a checkbox to support the new predictive-back-gesture?
as...@google.com <as...@google.com> #9
Hi
na...@google.com <na...@google.com> #10
The following release(s) address this bug.It is possible this bug has only been partially addressed:
androidx.fragment:fragment:1.7.0-alpha05
androidx.transition:transition:1.5.0-alpha03
lb...@gmail.com <lb...@gmail.com> #11
It's mostly about Activities.
Also, speaking of Activities, I can't find a way to support it only to some Activities. Currently it's all-or-nothing, making it very hard to migrate to it and also reduce the appeal of migrating to it (as it requires the entire project to migrate, instead of just what matters).
@9 Please also show samples in fragments within navigation.
In the past when I talked about it, Google actually said (maybe even here in the issue tracker) that it's denied and won't be added.
I don't understand what's going on now.
as...@google.com <as...@google.com> #12
Hi
We are planning on publishing a set of samples showing fragment animations. You'll be able to find them in
lb...@gmail.com <lb...@gmail.com> #13
About the samples, please also add for navigation and maybe also for the navigation-drawer sample.
Even better if you put it in the templates of a new Activity, as this way you could encourage developers to do it.
as...@google.com <as...@google.com> #14
Yes, per-activity opt-in is new in Android 14 and so this portion of the guide was added recently. Thank you for your feedback -- we'll take it into consideration.
lb...@gmail.com <lb...@gmail.com> #15
lb...@gmail.com <lb...@gmail.com> #16
I learn better from tiny samples than large ones. And those that are shown "on the way" right in the templates of the IDE mean you are serious about them.
Please make sure that we can have all of the possible behaviors of the Predictive Back Gesture when used in a fragment withing the navigation graph:
1. Show the fragment that we will go to when trying to go back
2. Block going to previous fragment (either doesn't exist, or exist and we choose not to allow it) and instead show what's behind in terms of Activity (or app), instead (leaving the current Activity/app)
3. Block back gesture completely, not allowing to go back
Will you please also fix the countless of weird exceptions that appear to this day even on Android 14, related to foreground service?
I've been struggling with it for a very long time. Even found some scenarios for some of the exceptions to occur, and some even contradict the documentation, including even on Pixel devices...
lb...@gmail.com <lb...@gmail.com> #17
This is something that was said to use instead of clearing the stack itself:
So you wouldn't want to show the MainFragment there, and instead you'd want to allow to skip directly to the Activity behind, even though MainFragment is in the back-stack of the navigation.
Sadly even there on this documentation, there is no sample and there is a lot of missing code.
Description
API 34 provided a new Predictive Back Gesture that allows seeking when going back and provides a View of the previous Activity.
Now that this feature is available between Activities it would be nice if it was also available between Fragments. Fragments need to handle multiple effects system to get this working and this bug will focus on providing support for Transitions.