Merge branch 'master' of https://gitlab.finogeeks.club/finclipsdk/finclip-flutter-sdk
commit
353cb45295
|
@ -84,11 +84,11 @@
|
||||||
return models;
|
return models;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)customMenu:(id<FATAppletMenuProtocol>)customMenu inApplet:(FATAppletInfo *)appletInfo didClickAtPath:(NSString *)path {
|
- (void)clickCustomItemMenuWithInfo:(NSDictionary *)contentInfo inApplet:(FATAppletInfo *)appletInfo completion:(void (^)(FATExtensionCode code, NSDictionary *result))completion {
|
||||||
NSDictionary *arguments = @{
|
NSDictionary *arguments = @{
|
||||||
@"appId": appletInfo.appId,
|
@"appId": contentInfo[@"appId"],
|
||||||
@"path": path,
|
@"path": contentInfo[@"path"],
|
||||||
@"menuId": customMenu.menuId,
|
@"menuId": contentInfo[@"menuId"],
|
||||||
@"appInfo": appletInfo.description
|
@"appInfo": appletInfo.description
|
||||||
};
|
};
|
||||||
FlutterMethodChannel *channel = [[MopPlugin instance] methodChannel];
|
FlutterMethodChannel *channel = [[MopPlugin instance] methodChannel];
|
||||||
|
@ -96,26 +96,6 @@
|
||||||
|
|
||||||
}];
|
}];
|
||||||
|
|
||||||
if ([@"Desktop" isEqualToString:customMenu.menuId]) {
|
|
||||||
[self addToDesktopItemClick:appletInfo path:path];
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
- (void)clickCustomItemMenuWithInfo:(NSDictionary *)contentInfo completion:(void (^)(FATExtensionCode code, NSDictionary *result))completion {
|
|
||||||
NSDictionary *arguments = @{
|
|
||||||
@"appId": contentInfo[@"appId"],
|
|
||||||
@"path": contentInfo[@"path"],
|
|
||||||
@"menuId": contentInfo[@"menuId"],
|
|
||||||
@"appInfo": [NSString stringWithFormat:@"{'title': '%@', 'description': '%@', 'imageUrl': '%@'}", contentInfo[@"title"], contentInfo[@"description"], contentInfo[@"imageUrl"]]
|
|
||||||
};
|
|
||||||
FlutterMethodChannel *channel = [[MopPlugin instance] methodChannel];
|
|
||||||
[channel invokeMethod:@"extensionApi:onCustomMenuClick" arguments:arguments result:^(id _Nullable result) {
|
|
||||||
|
|
||||||
}];
|
|
||||||
}
|
|
||||||
|
|
||||||
- (void)clickCustomItemMenuWithInfo:(NSDictionary *)contentInfo inApplet:(FATAppletInfo *)appletInfo completion:(void (^)(FATExtensionCode code, NSDictionary *result))completion {
|
|
||||||
if ([@"Desktop" isEqualToString:contentInfo[@"menuId"]]) {
|
if ([@"Desktop" isEqualToString:contentInfo[@"menuId"]]) {
|
||||||
[self addToDesktopItemClick:appletInfo path:contentInfo[@"path"]];
|
[self addToDesktopItemClick:appletInfo path:contentInfo[@"path"]];
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue