Interface PlatformPlugin.PlatformPluginDelegate

All Known Implementing Classes:
FlutterActivity, FlutterFragment
Enclosing class:
PlatformPlugin

public static interface PlatformPlugin.PlatformPluginDelegate
The PlatformPlugin generally has default behaviors implemented for platform functionalities requested by the Flutter framework. However, functionalities exposed through this interface could be customized by the more public-facing APIs that implement this interface such as the FlutterActivity or the FlutterFragment.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Allow implementer to customize the behavior needed when the Flutter framework calls to pop the Android-side navigation stack.
    default void
    setFrameworkHandlesBack(boolean frameworkHandlesBack)
    The Flutter application would or would not like to handle navigation pop events itself.
  • Method Details

    • popSystemNavigator

      boolean popSystemNavigator()
      Allow implementer to customize the behavior needed when the Flutter framework calls to pop the Android-side navigation stack.
      Returns:
      true if the implementation consumed the pop signal. If false, a default behavior of finishing the activity or sending the signal to OnBackPressedDispatcher will be executed.
    • setFrameworkHandlesBack

      default void setFrameworkHandlesBack(boolean frameworkHandlesBack)
      The Flutter application would or would not like to handle navigation pop events itself.

      Relevant for registering and unregistering the app's OnBackInvokedCallback for the Predictive Back feature, for example as in FlutterActivity.