|
@@ -94,6 +94,12 @@ class _HomePageState extends State<HomePage> with WidgetsBindingObserver, Ticker |
|
|
try { |
|
|
try { |
|
|
WidgetsBinding.instance.addObserver(this); |
|
|
WidgetsBinding.instance.addObserver(this); |
|
|
|
|
|
|
|
|
|
|
|
// mob锁粉隐私协议提交 |
|
|
|
|
|
Moblink.uploadPrivacyPermissionStatus(1, (bool success) {}); |
|
|
|
|
|
// mob分享SDK隐私协议提交 |
|
|
|
|
|
SharesdkPlugin.uploadPrivacyPermissionStatus(1, (bool success) {}); |
|
|
|
|
|
// mob短信SDK隐私协议提交 |
|
|
|
|
|
Mobcommonlib.submitPolicyGrantResult(true, (dynamic ret, Map err) => {}); |
|
|
// 监听开始(传递监听到原生端,用户监听场景还原的数据回传回来) |
|
|
// 监听开始(传递监听到原生端,用户监听场景还原的数据回传回来) |
|
|
eventChannelSubscription = _eventChannel.receiveBroadcastStream().listen(_onEvent, onError: _onError); |
|
|
eventChannelSubscription = _eventChannel.receiveBroadcastStream().listen(_onEvent, onError: _onError); |
|
|
|
|
|
|
|
@@ -104,7 +110,9 @@ class _HomePageState extends State<HomePage> with WidgetsBindingObserver, Ticker |
|
|
Timer(Duration(milliseconds: delay), () { |
|
|
Timer(Duration(milliseconds: delay), () { |
|
|
NativeUtil.notifyInitSuccess(); |
|
|
NativeUtil.notifyInitSuccess(); |
|
|
//app后台杀死时候的还原 |
|
|
//app后台杀死时候的还原 |
|
|
Moblink.restoreScene(_restore); |
|
|
|
|
|
|
|
|
Timer(Duration(milliseconds: 1500), () { |
|
|
|
|
|
Moblink.restoreScene(_restore); |
|
|
|
|
|
}); |
|
|
}); |
|
|
}); |
|
|
}); |
|
|
}); |
|
|
|
|
|
|
|
@@ -116,13 +124,6 @@ class _HomePageState extends State<HomePage> with WidgetsBindingObserver, Ticker |
|
|
//弹窗 |
|
|
//弹窗 |
|
|
_showPolicy(); |
|
|
_showPolicy(); |
|
|
|
|
|
|
|
|
// mob锁粉隐私协议提交 |
|
|
|
|
|
Moblink.uploadPrivacyPermissionStatus(1, (bool success) {}); |
|
|
|
|
|
// mob分享SDK隐私协议提交 |
|
|
|
|
|
SharesdkPlugin.uploadPrivacyPermissionStatus(1, (bool success) {}); |
|
|
|
|
|
// mob短信SDK隐私协议提交 |
|
|
|
|
|
Mobcommonlib.submitPolicyGrantResult(true, (dynamic ret, Map err) => {}); |
|
|
|
|
|
|
|
|
|
|
|
///设置推送标识 |
|
|
///设置推送标识 |
|
|
setAlias(); |
|
|
setAlias(); |
|
|
// 是安卓系统,Android场景还原的实现 |
|
|
// 是安卓系统,Android场景还原的实现 |
|
|