Flutter Engine
The Flutter Engine
Public Member Functions | Static Public Attributes | List of all members
dev.flutter.scenarios.PlatformViewsActivity Class Reference
Inheritance diagram for dev.flutter.scenarios.PlatformViewsActivity:
dev.flutter.scenarios.TestActivity dev.flutter.scenarios.TestableFlutterActivity io.flutter.embedding.android.FlutterActivity io.flutter.embedding.android.FlutterActivityAndFragmentDelegate.Host io.flutter.embedding.android.FlutterEngineProvider io.flutter.embedding.android.FlutterEngineConfigurator io.flutter.plugin.platform.PlatformPlugin.PlatformPluginDelegate

Public Member Functions

void configureFlutterEngine (@NonNull FlutterEngine flutterEngine)
 
- Public Member Functions inherited from dev.flutter.scenarios.TestActivity
FlutterShellArgs getFlutterShellArgs ()
 
void onFlutterUiDisplayed ()
 
- Public Member Functions inherited from dev.flutter.scenarios.TestableFlutterActivity
void configureFlutterEngine (@NonNull FlutterEngine flutterEngine)
 
void waitUntilFlutterRendered ()
 
- Public Member Functions inherited from io.flutter.embedding.android.FlutterActivity
 FlutterActivity ()
 
ExclusiveAppComponent< Activity > getExclusiveAppComponent ()
 
void registerOnBackInvokedCallback ()
 
void unregisterOnBackInvokedCallback ()
 
void setFrameworkHandlesBack (boolean frameworkHandlesBack)
 
void onPostResume ()
 
void release ()
 
void detachFromFlutterEngine ()
 
void onBackPressed ()
 
void startBackGesture (@NonNull BackEvent backEvent)
 
void updateBackGestureProgress (@NonNull BackEvent backEvent)
 
void commitBackGesture ()
 
void cancelBackGesture ()
 
void onRequestPermissionsResult (int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults)
 
void onUserLeaveHint ()
 
void onWindowFocusChanged (boolean hasFocus)
 
void onTrimMemory (int level)
 
Context getContext ()
 
Activity getActivity ()
 
Lifecycle getLifecycle ()
 
FlutterShellArgs getFlutterShellArgs ()
 
String getCachedEngineId ()
 
String getCachedEngineGroupId ()
 
boolean shouldDestroyEngineWithHost ()
 
String getDartEntrypointFunctionName ()
 
List< String > getDartEntrypointArgs ()
 
String getDartEntrypointLibraryUri ()
 
String getInitialRoute ()
 
String getAppBundlePath ()
 
RenderMode getRenderMode ()
 
TransparencyMode getTransparencyMode ()
 
FlutterEngine provideFlutterEngine (@NonNull Context context)
 
PlatformPlugin providePlatformPlugin ( @Nullable Activity activity, @NonNull FlutterEngine flutterEngine)
 
void configureFlutterEngine (@NonNull FlutterEngine flutterEngine)
 
void cleanUpFlutterEngine (@NonNull FlutterEngine flutterEngine)
 
boolean shouldAttachEngineToActivity ()
 
boolean shouldHandleDeeplinking ()
 
void onFlutterSurfaceViewCreated (@NonNull FlutterSurfaceView flutterSurfaceView)
 
void onFlutterTextureViewCreated (@NonNull FlutterTextureView flutterTextureView)
 
void onFlutterUiDisplayed ()
 
void onFlutterUiNoLongerDisplayed ()
 
boolean shouldRestoreAndSaveState ()
 
boolean shouldDispatchAppLifecycleState ()
 
boolean attachToEngineAutomatically ()
 
boolean popSystemNavigator ()
 
void updateSystemUiOverlays ()
 
Context getContext ()
 
boolean shouldHandleDeeplinking ()
 
Activity getActivity ()
 
Lifecycle getLifecycle ()
 
FlutterShellArgs getFlutterShellArgs ()
 
String getCachedEngineId ()
 
String getCachedEngineGroupId ()
 
boolean shouldDestroyEngineWithHost ()
 
void detachFromFlutterEngine ()
 
String getDartEntrypointFunctionName ()
 
String getDartEntrypointLibraryUri ()
 
List< String > getDartEntrypointArgs ()
 
String getAppBundlePath ()
 
String getInitialRoute ()
 
RenderMode getRenderMode ()
 
TransparencyMode getTransparencyMode ()
 
ExclusiveAppComponent< Activity > getExclusiveAppComponent ()
 
FlutterEngine provideFlutterEngine (@NonNull Context context)
 
PlatformPlugin providePlatformPlugin ( @Nullable Activity activity, @NonNull FlutterEngine flutterEngine)
 
void configureFlutterEngine (@NonNull FlutterEngine flutterEngine)
 
void cleanUpFlutterEngine (@NonNull FlutterEngine flutterEngine)
 
boolean shouldAttachEngineToActivity ()
 
void onFlutterSurfaceViewCreated (@NonNull FlutterSurfaceView flutterSurfaceView)
 
void onFlutterTextureViewCreated (@NonNull FlutterTextureView flutterTextureView)
 
void onFlutterUiDisplayed ()
 
void onFlutterUiNoLongerDisplayed ()
 
boolean shouldRestoreAndSaveState ()
 
void updateSystemUiOverlays ()
 
boolean shouldDispatchAppLifecycleState ()
 
boolean attachToEngineAutomatically ()
 
FlutterEngine provideFlutterEngine (@NonNull Context context)
 
void configureFlutterEngine (@NonNull FlutterEngine flutterEngine)
 
void cleanUpFlutterEngine (@NonNull FlutterEngine flutterEngine)
 
boolean popSystemNavigator ()
 
default void setFrameworkHandlesBack (boolean frameworkHandlesBack)
 

Static Public Attributes

static final String TEXT_VIEW_PV = "scenarios/textPlatformView"
 
static final String SURFACE_VIEW_PV = "scenarios/surfacePlatformV"
 
static final String SURFACE_VIEW_BAD_CONTEXT_PV = "scenarios/surfaceVBadCntxt"
 
static final String TEXTURE_VIEW_PV = "scenarios/texturePlatformV"
 
- Static Public Attributes inherited from io.flutter.embedding.android.FlutterActivity
static final int FLUTTER_VIEW_ID = View.generateViewId()
 

Additional Inherited Members

- Static Public Member Functions inherited from io.flutter.embedding.android.FlutterActivity
static Intent createDefaultIntent (@NonNull Context launchContext)
 
static NewEngineIntentBuilder withNewEngine ()
 
static CachedEngineIntentBuilder withCachedEngine (@NonNull String cachedEngineId)
 
static NewEngineInGroupIntentBuilder withNewEngineInGroup (@NonNull String engineGroupId)
 
- Protected Member Functions inherited from dev.flutter.scenarios.TestActivity
void onCreate (@Nullable Bundle savedInstanceState)
 
void onDestroy ()
 
void getScenarioParams (@NonNull Map< String, Object > args)
 
void testFlutterLoaderCallbackWhenInitializedTwice ()
 
- Protected Member Functions inherited from dev.flutter.scenarios.TestableFlutterActivity
void onCreate (@Nullable Bundle savedInstanceState)
 
void notifyFlutterRendered ()
 
- Protected Member Functions inherited from io.flutter.embedding.android.FlutterActivity
void onCreate (@Nullable Bundle savedInstanceState)
 
OnBackInvokedCallback getOnBackInvokedCallback ()
 
void onStart ()
 
void onResume ()
 
void onPause ()
 
void onStop ()
 
void onSaveInstanceState (Bundle outState)
 
void onDestroy ()
 
void onActivityResult (int requestCode, int resultCode, Intent data)
 
void onNewIntent (@NonNull Intent intent)
 
BackgroundMode getBackgroundMode ()
 
FlutterEngine getFlutterEngine ()
 
Bundle getMetaData () throws PackageManager.NameNotFoundException
 
- Protected Attributes inherited from io.flutter.embedding.android.FlutterActivity
FlutterActivityAndFragmentDelegate delegate
 
- Package Functions inherited from io.flutter.embedding.android.FlutterActivity
void setDelegate (@NonNull FlutterActivityAndFragmentDelegate delegate)
 

Detailed Description

Definition at line 10 of file PlatformViewsActivity.java.

Member Function Documentation

◆ configureFlutterEngine()

void dev.flutter.scenarios.PlatformViewsActivity.configureFlutterEngine ( @NonNull FlutterEngine  flutterEngine)
inline

Hook for subclasses to easily configure a FlutterEngine.

This method is called after provideFlutterEngine(Context).

All plugins listed in the app's pubspec are registered in the base implementation of this method unless the FlutterEngine for this activity was externally created. To avoid the automatic plugin registration for implicitly created FlutterEngines, override this method without invoking super(). To keep automatic plugin registration and further configure the FlutterEngine, override this method, invoke super(), and then configure the FlutterEngine as desired.

Reimplemented from dev.flutter.scenarios.TestableFlutterActivity.

Definition at line 20 of file PlatformViewsActivity.java.

20 {
21 super.configureFlutterEngine(flutterEngine);
22 flutterEngine
23 .getPlatformViewsController()
24 .getRegistry()
25 .registerViewFactory(TEXT_VIEW_PV, new TextPlatformViewFactory());
26
27 flutterEngine
28 .getPlatformViewsController()
29 .getRegistry()
30 .registerViewFactory(SURFACE_VIEW_PV, new SurfacePlatformViewFactory(true));
31
32 flutterEngine
33 .getPlatformViewsController()
34 .getRegistry()
35 .registerViewFactory(SURFACE_VIEW_BAD_CONTEXT_PV, new SurfacePlatformViewFactory(false));
36
37 flutterEngine
38 .getPlatformViewsController()
39 .getRegistry()
40 .registerViewFactory(TEXTURE_VIEW_PV, new TexturePlatformViewFactory());
41 }

Member Data Documentation

◆ SURFACE_VIEW_BAD_CONTEXT_PV

final String dev.flutter.scenarios.PlatformViewsActivity.SURFACE_VIEW_BAD_CONTEXT_PV = "scenarios/surfaceVBadCntxt"
static

Definition at line 16 of file PlatformViewsActivity.java.

◆ SURFACE_VIEW_PV

final String dev.flutter.scenarios.PlatformViewsActivity.SURFACE_VIEW_PV = "scenarios/surfacePlatformV"
static

Definition at line 15 of file PlatformViewsActivity.java.

◆ TEXT_VIEW_PV

final String dev.flutter.scenarios.PlatformViewsActivity.TEXT_VIEW_PV = "scenarios/textPlatformView"
static

Definition at line 14 of file PlatformViewsActivity.java.

◆ TEXTURE_VIEW_PV

final String dev.flutter.scenarios.PlatformViewsActivity.TEXTURE_VIEW_PV = "scenarios/texturePlatformV"
static

Definition at line 17 of file PlatformViewsActivity.java.


The documentation for this class was generated from the following file: