Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Instance Methods | List of all members
TestPlatformViewFactory Class Reference
Inheritance diagram for TestPlatformViewFactory:
<FlutterPlatformViewFactory>

Instance Methods

(nonnull NSView *) - createWithViewIdentifier:arguments: [implementation]
 
- Instance Methods inherited from <FlutterPlatformViewFactory>
(NSObject< FlutterPlatformView > *) - createWithFrame:viewIdentifier:arguments:
 
(NSObject< FlutterMessageCodec > *) - createArgsCodec
 
(nullable NSObject< FlutterMessageCodec > *) - createArgsCodec
 

Detailed Description

Definition at line 48 of file FlutterEngineTest.mm.

Method Documentation

◆ createWithViewIdentifier:arguments:

- (nonnull NSView *) createWithViewIdentifier: (FlutterViewIdentifier viewId
arguments: (nullable id args 
implementation

Create a Platform View which is an NSView.

A MacOS plugin should implement this method and return an NSView, which can be embedded in a Flutter App.

The implementation of this method should create a new NSView.

Parameters
viewIdA unique identifier for this view.
argsParameters for creating the view sent from the Dart side of the Flutter app. If createArgsCodec is not implemented, or if no creation arguments were sent from the Dart code, this will be null. Otherwise this will be the value sent from the Dart code as decoded by createArgsCodec.

Reimplemented from <FlutterPlatformViewFactory>.

Definition at line 44 of file FlutterEngineTest.mm.

52 :(FlutterViewIdentifier)viewIdentifier
53 arguments:(nullable id)args {
54 return viewIdentifier == 42 ? [[NSView alloc] init] : nil;
55}
G_BEGIN_DECLS G_MODULE_EXPORT FlValue * args
int64_t FlutterViewIdentifier
init(device_serial, adb_binary)
Definition _adb_path.py:12
const uintptr_t id

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