@@ -787,10 +787,12 @@ void onBackPressed() {
787
787
/**
788
788
* Invoke this from {@link OnBackAnimationCallback#onBackStarted(BackEvent)}.
789
789
*
790
- * <p>This method should be called when the back gesture is initiated, as part of the
791
- * implementation of {@link OnBackAnimationCallback}. It's responsible for handling the initial
792
- * response to the start of a back gesture, such as initiating animations or preparing the UI for
793
- * the back navigation process.
790
+ * <p>This method should be called when the back gesture is initiated. It should be invoked as
791
+ * part of the implementation of {@link OnBackAnimationCallback}.
792
+ *
793
+ * <p>This method delegates the handling of the start of a back gesture to the Flutter framework,
794
+ * which is responsible for the appropriate response, such as initiating animations or preparing
795
+ * the UI for the back navigation process.
794
796
*
795
797
* @param backEvent The BackEvent object containing information about the touch.
796
798
*/
@@ -810,9 +812,10 @@ void startBackGesture(@NonNull BackEvent backEvent) {
810
812
* Invoke this from {@link OnBackAnimationCallback#onBackProgressed(BackEvent)}.
811
813
*
812
814
* <p>This method should be called in response to progress in a back gesture, as part of the
813
- * implementation of {@link OnBackAnimationCallback}. It allows for updating the state of the
814
- * application or UI elements based on the ongoing back gesture, such as progressing animations or
815
- * interactive elements.
815
+ * implementation of {@link OnBackAnimationCallback}.
816
+ *
817
+ * <p>This method delegates to the Flutter framework to update UI elements or animations based on
818
+ * the progression of the back gesture.
816
819
*
817
820
* @param backEvent An BackEvent object describing the progress event.
818
821
*/
@@ -833,11 +836,13 @@ void updateBackGestureProgress(@NonNull BackEvent backEvent) {
833
836
/**
834
837
* Invoke this from {@link OnBackAnimationCallback#onBackInvoked()}.
835
838
*
836
- * <p>This method signifies the completion of a back gesture and commits the navigation action
837
- * initiated by the gesture. It should be called as a final step in the back gesture handling,
838
- * indicating that the application is ready to proceed with the back navigation. This could
839
- * involve finalizing animations, updating the UI to reflect the navigation, or performing cleanup
840
- * tasks related to the gesture.
839
+ * <p>This method is called to signify the completion of a back gesture and commits the navigation
840
+ * action initiated by the gesture. It should be invoked as the final step in handling a back
841
+ * gesture.
842
+ *
843
+ * <p>This method indicates to the Flutter framework that it should proceed with the back
844
+ * navigation, including finalizing animations and updating the UI to reflect the navigation
845
+ * outcome.
841
846
*/
842
847
@ TargetApi (API_LEVELS .API_34 )
843
848
@ RequiresApi (API_LEVELS .API_34 )
@@ -854,10 +859,12 @@ void commitBackGesture() {
854
859
/**
855
860
* Invoke this from {@link OnBackAnimationCallback#onBackCancelled()}.
856
861
*
857
- * <p>This method should be called when a back gesture is cancelled or back button pressed, as
858
- * part of the implementation of {@link OnBackAnimationCallback}. It's responsible for handling
859
- * the rollback of any changes or animations that were initiated in response to the back gesture.
860
- * This includes resetting UI elements or state to their original form before the gesture started.
862
+ * <p>This method should be called when a back gesture is cancelled or the back button is pressed.
863
+ * It informs the Flutter framework about the cancellation.
864
+ *
865
+ * <p>This method enables the Flutter framework to rollback any UI changes or animations initiated
866
+ * in response to the back gesture. This includes resetting UI elements to their state prior to
867
+ * the gesture's start.
861
868
*/
862
869
@ TargetApi (API_LEVELS .API_34 )
863
870
@ RequiresApi (API_LEVELS .API_34 )
0 commit comments