AndroidX Activity 1.9.0-alpha03

1.9.0-alpha03
Changed 2
  • The OnBackPressedCallback, BackHandler, and PredictiveBackHandler APIs now warn when calling onBackPressedDispatcher.onBackPressed() while handling back, as that will always break the Predictive Back Animation
  • A back event sent from the system during an already running Predictive Back Gesture cancels the current gesture and begins a new Predictive Back Gesture
Fixed 1
  • Fixed a crash when accessing the onBackPressedDispatcher from a ComponentActivity for the first time from a background thread; it is now safe to access the onBackPressedDispatcher on any thread

From AndroidX Activity

The OnBackPressedCallback, BackHandler, and PredictiveBackHandler APIs now warn when calling onBackPressedDispatcher.onBackPressed() when handling back as that will always break the Predictive Back Animation. See the best practices guide for more details. ( 1e4222, 2c950d, b/287505200) If a back event is sent from the system started during an already running Predictive Back Gesture, the currently running Predictive Back Gesture is canceled and the new back event takes over to begin a new Predictive Back Gesture. ( I3482e) Fixed a crash when accessing the onBackPressedDispatcher from a ComponentActivity for the first time from a background thread. It is now safe to access the onBackPressedDispatcher on any thread. ( I79955)

View original

Upgraded? How did it go?

Discussion