Class FlutterFragmentActivity

java.lang.Object
android.content.Context
android.content.ContextWrapper
android.view.ContextThemeWrapper
android.app.Activity
androidx.core.app.ComponentActivity
androidx.activity.ComponentActivity
androidx.fragment.app.FragmentActivity
io.flutter.app.FlutterFragmentActivity
All Implemented Interfaces:
ComponentCallbacks, ComponentCallbacks2, KeyEvent.Callback, LayoutInflater.Factory, LayoutInflater.Factory2, View.OnCreateContextMenuListener, Window.Callback, androidx.activity.contextaware.ContextAware, androidx.activity.FullyDrawnReporterOwner, androidx.activity.OnBackPressedDispatcherOwner, androidx.activity.result.ActivityResultCaller, androidx.activity.result.ActivityResultRegistryOwner, androidx.core.app.ActivityCompat.OnRequestPermissionsResultCallback, androidx.core.app.ActivityCompat.RequestPermissionsRequestCodeValidator, androidx.core.app.OnMultiWindowModeChangedProvider, androidx.core.app.OnNewIntentProvider, androidx.core.app.OnPictureInPictureModeChangedProvider, androidx.core.content.OnConfigurationChangedProvider, androidx.core.content.OnTrimMemoryProvider, androidx.core.view.KeyEventDispatcher.Component, androidx.core.view.MenuHost, androidx.lifecycle.HasDefaultViewModelProviderFactory, androidx.lifecycle.LifecycleOwner, androidx.lifecycle.ViewModelStoreOwner, androidx.savedstate.SavedStateRegistryOwner, FlutterActivityDelegate.ViewFactory, PluginRegistry, FlutterView.Provider

@Deprecated public class FlutterFragmentActivity extends androidx.fragment.app.FragmentActivity implements FlutterView.Provider, PluginRegistry, FlutterActivityDelegate.ViewFactory
Deprecated.
this class is replaced by FlutterFragmentActivity.
Deprecated class for activities that use Flutter who also require the use of the Android v4 Support library's FragmentActivity.

Applications that don't have this need will likely want to use FlutterActivity instead.

Important! Flutter does not bundle the necessary Android v4 Support library classes for this class to work at runtime. It is the responsibility of the app developer using this class to ensure that they link against the v4 support library .jar file when creating their app to ensure that FragmentActivity is available at runtime.

See Also:
  • Constructor Details

    • FlutterFragmentActivity

      public FlutterFragmentActivity()
      Deprecated.
  • Method Details

    • getFlutterView

      public FlutterView getFlutterView()
      Deprecated.
      Returns the Flutter view used by this activity; will be null before onCreate(Bundle) is called.
      Specified by:
      getFlutterView in interface FlutterView.Provider
      Returns:
      a reference to the Flutter view maintained by this object.
    • createFlutterView

      public FlutterView createFlutterView(Context context)
      Deprecated.
      Hook for subclasses to customize the creation of the FlutterView.

      The default implementation returns null, which will cause the activity to use a newly instantiated full-screen view.

      Specified by:
      createFlutterView in interface FlutterActivityDelegate.ViewFactory
    • createFlutterNativeView

      public FlutterNativeView createFlutterNativeView()
      Deprecated.
      Specified by:
      createFlutterNativeView in interface FlutterActivityDelegate.ViewFactory
    • retainFlutterNativeView

      public boolean retainFlutterNativeView()
      Deprecated.
      Description copied from interface: FlutterActivityDelegate.ViewFactory
      Hook for subclasses to indicate that the FlutterNativeView returned by FlutterActivityDelegate.ViewFactory.createFlutterNativeView() should not be destroyed when this activity is destroyed.
      Specified by:
      retainFlutterNativeView in interface FlutterActivityDelegate.ViewFactory
      Returns:
      Whether the FlutterNativeView is retained.
    • hasPlugin

      public final boolean hasPlugin(String key)
      Deprecated.
      Description copied from interface: PluginRegistry
      Returns whether the specified plugin is known to this registry.
      Specified by:
      hasPlugin in interface PluginRegistry
      Parameters:
      key - a unique String identifying the plugin; typically the fully qualified name of the plugin's main class.
      Returns:
      true if this registry has handed out a registrar for the specified plugin.
    • valuePublishedByPlugin

      public final <T> T valuePublishedByPlugin(String pluginKey)
      Deprecated.
      Description copied from interface: PluginRegistry
      Returns the value published by the specified plugin, if any.

      Plugins may publish a single value, such as an instance of the plugin's main class, for situations where external control or interaction is needed. Clients are expected to know the value's type.

      Specified by:
      valuePublishedByPlugin in interface PluginRegistry
      Type Parameters:
      T - The type of the value.
      Parameters:
      pluginKey - a unique String identifying the plugin; typically the fully qualified name of the plugin's main class.
      Returns:
      the published value, possibly null.
    • registrarFor

      public final PluginRegistry.Registrar registrarFor(String pluginKey)
      Deprecated.
      Description copied from interface: PluginRegistry
      Returns a PluginRegistry.Registrar for receiving the registrations pertaining to the specified plugin.
      Specified by:
      registrarFor in interface PluginRegistry
      Parameters:
      pluginKey - a unique String identifying the plugin; typically the fully qualified name of the plugin's main class.
      Returns:
      A PluginRegistry.Registrar for receiving the registrations pertianing to the specified plugin.
    • onCreate

      protected void onCreate(Bundle savedInstanceState)
      Deprecated.
      Overrides:
      onCreate in class androidx.fragment.app.FragmentActivity
    • onDestroy

      protected void onDestroy()
      Deprecated.
      Overrides:
      onDestroy in class androidx.fragment.app.FragmentActivity
    • onBackPressed

      public void onBackPressed()
      Deprecated.
      Overrides:
      onBackPressed in class androidx.activity.ComponentActivity
    • onStart

      protected void onStart()
      Deprecated.
      Overrides:
      onStart in class androidx.fragment.app.FragmentActivity
    • onStop

      protected void onStop()
      Deprecated.
      Overrides:
      onStop in class androidx.fragment.app.FragmentActivity
    • onPause

      protected void onPause()
      Deprecated.
      Overrides:
      onPause in class androidx.fragment.app.FragmentActivity
    • onPostResume

      protected void onPostResume()
      Deprecated.
      Overrides:
      onPostResume in class androidx.fragment.app.FragmentActivity
    • onRequestPermissionsResult

      public void onRequestPermissionsResult(int requestCode, String[] permissions, int[] grantResults)
      Deprecated.
      Specified by:
      onRequestPermissionsResult in interface androidx.core.app.ActivityCompat.OnRequestPermissionsResultCallback
      Overrides:
      onRequestPermissionsResult in class androidx.fragment.app.FragmentActivity
    • onActivityResult

      protected void onActivityResult(int requestCode, int resultCode, Intent data)
      Deprecated.
      Overrides:
      onActivityResult in class androidx.fragment.app.FragmentActivity
    • onNewIntent

      protected void onNewIntent(Intent intent)
      Deprecated.
      Overrides:
      onNewIntent in class androidx.activity.ComponentActivity
    • onUserLeaveHint

      public void onUserLeaveHint()
      Deprecated.
      Overrides:
      onUserLeaveHint in class Activity
    • onWindowFocusChanged

      public void onWindowFocusChanged(boolean hasFocus)
      Deprecated.
      Specified by:
      onWindowFocusChanged in interface Window.Callback
      Overrides:
      onWindowFocusChanged in class Activity
    • onTrimMemory

      public void onTrimMemory(int level)
      Deprecated.
      Specified by:
      onTrimMemory in interface ComponentCallbacks2
      Overrides:
      onTrimMemory in class androidx.activity.ComponentActivity
    • onLowMemory

      public void onLowMemory()
      Deprecated.
      Specified by:
      onLowMemory in interface ComponentCallbacks
      Overrides:
      onLowMemory in class Activity
    • onConfigurationChanged

      public void onConfigurationChanged(Configuration newConfig)
      Deprecated.
      Specified by:
      onConfigurationChanged in interface ComponentCallbacks
      Overrides:
      onConfigurationChanged in class androidx.activity.ComponentActivity