showIOSNoticeWhenForeground method

  1. @override
Future<Map> showIOSNoticeWhenForeground(
  1. bool enable
)
override

App处于前台时显示通知

Implementation

@override
Future<Map<dynamic, dynamic>> showIOSNoticeWhenForeground(bool enable) async {
  if (!Platform.isIOS) {
    return {
      'code': kAliyunPushOnlyIOS,
      'errorMsg': 'Only support iOS',
    };
  }

  Map<dynamic, dynamic> result = await methodChannel
      .invokeMethod('showNoticeWhenForeground', {'enable': enable});
  return result;
}