Fixed
Status Update
Comments
si...@outlook.com <si...@outlook.com> #2
I change to fragment1.3.0 and navigation component 2.3.3, the popEnterAnim works fine. (I find the solution from the https://issuetracker.google.com/issues/182195688 example project).
il...@google.com <il...@google.com> #3
Please include a sample project that reproduces your issue.
As per the navigate()
, the enter
and exit
animations run.
si...@outlook.com <si...@outlook.com> #4
Thanks, here it's the project and video.
pr...@gmail.com <pr...@gmail.com> #5
I am also facing same issue exit animations does not work even if i set it from navigation graph and using Direction Classes
il...@google.com <il...@google.com>
mu...@gmail.com <mu...@gmail.com> #6
I also saw the same issue. I suspect two modules are involved.
If either of them is versioned up, the same issue occurs.
My Check Point
androidx.appcompat.appcompat:1.3.0-beta01 -> rc01
fragment-ktx:1.3.1 -> 1.3.2
appcompat:1.3.0-beta01 & fragment-ktx:1.3.1 ----> not issue
appcompat:1.3.0-beta01 & fragment-ktx:1.3.2 ----> issue
appcompat:1.3.0-rc01 & fragment-ktx:1.3.1 ----> issue
appcompat:1.3.0-rc01 & fragment-ktx:1.3.2 ----> issue
I apologize for the immature comment. check please :)
If either of them is versioned up, the same issue occurs.
My Check Point
androidx.appcompat.appcompat:1.3.0-beta01 -> rc01
fragment-ktx:1.3.1 -> 1.3.2
appcompat:1.3.0-beta01 & fragment-ktx:1.3.1 ----> not issue
appcompat:1.3.0-beta01 & fragment-ktx:1.3.2 ----> issue
appcompat:1.3.0-rc01 & fragment-ktx:1.3.1 ----> issue
appcompat:1.3.0-rc01 & fragment-ktx:1.3.2 ----> issue
I apologize for the immature comment. check please :)
cu...@gmail.com <cu...@gmail.com> #7
I have the same issue:
When updating from androidx.appcompat.appcompat:1.3.0-beta01 to -rc01 or from fragment-ktx:1.3.1 to 1.3.2 popEnterAmin stops working.
When updating from androidx.appcompat.appcompat:1.3.0-beta01 to -rc01 or from fragment-ktx:1.3.1 to 1.3.2 popEnterAmin stops working.
[Deleted User] <[Deleted User]> #8
Same issue, reverting to version 1.3.1 of androidx.fragment:fragment-ktx fixes the problem
ap...@google.com <ap...@google.com> #9
Project: platform/frameworks/support
Branch: androidx-main
commit 7a15383997e42b427798e2208cad5cbcce607c59
Author: Jeremy Woods <jbwoods@google.com>
Date: Thu Apr 08 15:25:28 2021
Fix popEnter animations when popping setPrimaryNavFragment
When doing a FragmentTransactions, if you setCustomAnimations with a
popEnter animation, do an op that triggers an animation (i.e. add, replace, etc),
and then do setPrimaryNavFragment, when you pop that transaction, there will be
no popEnter animation. The reason for this is the setPrimaryNavFragment
Op clears all of the animations for the incoming fragment.
We should only change animations for operations that actually trigger
them.
RelNote: "PopEnter animations will now be present when popping a
setPrimaryNavFragment operation."
Test: FragmentAnimationTest
Bug: 183877426
Change-Id: I38c877ae34c825b3a451ab325b6f683de00a2457
M fragment/fragment/src/androidTest/java/androidx/fragment/app/FragmentAnimationTest.kt
M fragment/fragment/src/main/java/androidx/fragment/app/BackStackRecord.java
https://android-review.googlesource.com/1670154
Branch: androidx-main
commit 7a15383997e42b427798e2208cad5cbcce607c59
Author: Jeremy Woods <jbwoods@google.com>
Date: Thu Apr 08 15:25:28 2021
Fix popEnter animations when popping setPrimaryNavFragment
When doing a FragmentTransactions, if you setCustomAnimations with a
popEnter animation, do an op that triggers an animation (i.e. add, replace, etc),
and then do setPrimaryNavFragment, when you pop that transaction, there will be
no popEnter animation. The reason for this is the setPrimaryNavFragment
Op clears all of the animations for the incoming fragment.
We should only change animations for operations that actually trigger
them.
RelNote: "PopEnter animations will now be present when popping a
setPrimaryNavFragment operation."
Test: FragmentAnimationTest
Bug: 183877426
Change-Id: I38c877ae34c825b3a451ab325b6f683de00a2457
M fragment/fragment/src/androidTest/java/androidx/fragment/app/FragmentAnimationTest.kt
M fragment/fragment/src/main/java/androidx/fragment/app/BackStackRecord.java
vy...@gmail.com <vy...@gmail.com> #10
I've created this issue, which is probably related:
jb...@google.com <jb...@google.com> #11
This has been fixed internally and will be available as part of the Fragment version 1.3.3
release.
Description
Version used: 1.3.2
Devices/Android versions reproduced on:
both
findNavController().navigate(
R.id.terms_catalog_fragment,
null,
navOptions {
anim {
enter = R.anim.slide_in_from_right
exit = R.anim.slide_out_to_left
popEnter = R.anim.slide_in_from_left
popExit = R.anim.slide_out_to_right
}
}
)
findNavController().navigate(
AboutFragmentDirections
.actionAboutFragmentToTermsCatalogFragment()
)
doesn't play popEnterAnim. I use android.R.animator.fade_in and android.R.animator.fade_out, still doesn't play popEnterAnim.
I didn't use any custom navOption. just follow the official guide.
navigation component: 2.3.4
AVD Pixel 4 XL API 29 / Samsung s9+ API 29
If this is a bug in the library, we would appreciate if you could attach:
- Sample project to trigger the issue.
- A screenrecord or screenshots showing the issue (if UI related).