Flutter Engine
FlutterPlatformPlugin Class Reference

#import <FlutterPlatformPlugin.h>

Inheritance diagram for FlutterPlatformPlugin:

Instance Methods

(instancetype) - NS_UNAVAILABLE
 
(instancetype) - initWithEngine:
 
(void) - handleMethodCall:result:
 

Class Methods

(instancetype) + NS_UNAVAILABLE
 

Detailed Description

Definition at line 12 of file FlutterPlatformPlugin.h.

Method Documentation

◆ handleMethodCall:result:()

- (void) handleMethodCall: (FlutterMethodCall*)  call
result: (FlutterResult result 

Definition at line 59 of file FlutterPlatformPlugin.mm.

References args, FlutterMethodCall::arguments, FlutterMethodNotImplemented, format, kTextPlainFormat, FlutterMethodCall::method, and result.

Referenced by FlutterEngine::destroyContext.

60  NSString* method = call.method;
61  id args = call.arguments;
62  if ([method isEqualToString:@"SystemSound.play"]) {
63  [self playSystemSound:args];
64  result(nil);
65  } else if ([method isEqualToString:@"HapticFeedback.vibrate"]) {
66  [self vibrateHapticFeedback:args];
67  result(nil);
68  } else if ([method isEqualToString:@"SystemChrome.setPreferredOrientations"]) {
69  [self setSystemChromePreferredOrientations:args];
70  result(nil);
71  } else if ([method isEqualToString:@"SystemChrome.setApplicationSwitcherDescription"]) {
72  [self setSystemChromeApplicationSwitcherDescription:args];
73  result(nil);
74  } else if ([method isEqualToString:@"SystemChrome.setEnabledSystemUIOverlays"]) {
75  [self setSystemChromeEnabledSystemUIOverlays:args];
76  result(nil);
77  } else if ([method isEqualToString:@"SystemChrome.setEnabledSystemUIMode"]) {
78  [self setSystemChromeEnabledSystemUIMode:args];
79  result(nil);
80  } else if ([method isEqualToString:@"SystemChrome.restoreSystemUIOverlays"]) {
81  [self restoreSystemChromeSystemUIOverlays];
82  result(nil);
83  } else if ([method isEqualToString:@"SystemChrome.setSystemUIOverlayStyle"]) {
84  [self setSystemChromeSystemUIOverlayStyle:args];
85  result(nil);
86  } else if ([method isEqualToString:@"SystemNavigator.pop"]) {
87  NSNumber* isAnimated = args;
88  [self popSystemNavigator:isAnimated.boolValue];
89  result(nil);
90  } else if ([method isEqualToString:@"Clipboard.getData"]) {
91  result([self getClipboardData:args]);
92  } else if ([method isEqualToString:@"Clipboard.setData"]) {
93  [self setClipboardData:args];
94  result(nil);
95  } else if ([method isEqualToString:@"Clipboard.hasStrings"]) {
96  result([self clipboardHasStrings]);
97  } else {
99  }
100 }
G_BEGIN_DECLS FlValue * args
GAsyncResult * result
void(^ FlutterResult)(id _Nullable result)
FLUTTER_DARWIN_EXPORT NSObject const * FlutterMethodNotImplemented

◆ initWithEngine:()

- (instancetype) initWithEngine: (fml::WeakPtr< FlutterEngine >)  NS_DESIGNATED_INITIALIZER

◆ NS_UNAVAILABLE() [1/2]

- (instancetype) NS_UNAVAILABLE

◆ NS_UNAVAILABLE() [2/2]

+ (instancetype) NS_UNAVAILABLE

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