diff --git a/ios/Podfile.lock b/ios/Podfile.lock index 6b2fd3954..501cdc6da 100644 --- a/ios/Podfile.lock +++ b/ios/Podfile.lock @@ -1,6 +1,4 @@ PODS: - - countly_flutter (24.4.1): - - Flutter - device_info_plus (0.0.1): - Flutter - file_picker (0.0.1): @@ -36,7 +34,6 @@ PODS: - Flutter DEPENDENCIES: - - countly_flutter (from `.symlinks/plugins/countly_flutter/ios`) - device_info_plus (from `.symlinks/plugins/device_info_plus/ios`) - file_picker (from `.symlinks/plugins/file_picker/ios`) - Flutter (from `Flutter`) @@ -55,8 +52,6 @@ DEPENDENCIES: - watch_connectivity (from `.symlinks/plugins/watch_connectivity/ios`) EXTERNAL SOURCES: - countly_flutter: - :path: ".symlinks/plugins/countly_flutter/ios" device_info_plus: :path: ".symlinks/plugins/device_info_plus/ios" file_picker: @@ -91,7 +86,6 @@ EXTERNAL SOURCES: :path: ".symlinks/plugins/watch_connectivity/ios" SPEC CHECKSUMS: - countly_flutter: 56233d921c6b4e0a720774a39b8ee8110d6f8d91 device_info_plus: 97af1d7e84681a90d0693e63169a5d50e0839a0d file_picker: c79185e70b9b45728cde2a8d8da454e0cb43f287 Flutter: e0871f40cf51350855a761d2e70bf5af5b9b5de7 diff --git a/lib/view/page/setting/platform/ios.dart b/lib/view/page/setting/platform/ios.dart index 7deec8e9c..ea581fe51 100644 --- a/lib/view/page/setting/platform/ios.dart +++ b/lib/view/page/setting/platform/ios.dart @@ -82,9 +82,7 @@ class _IOSSettingsPageState extends State { Widget _buildWatchApp() { return FutureWidget( future: () async { - if (!await wc.isPaired) { - return null; - } + if (!await wc.isPaired) return null; return await wc.applicationContext; }(), loading: UIs.centerLoading, @@ -114,16 +112,15 @@ class _IOSSettingsPageState extends State { void _onTapWatchApp(Map map) async { final urls = Map.from(map['urls'] as Map? ?? {}); final result = await AppRoutes.kvEditor(data: urls).go(context); - if (result == null || result! is Map) return; + if (result == null || result is! Map) return; try { - await wc.updateApplicationContext({'urls': result}); - } catch (e, trace) { - context.showRoundDialog( - title: l10n.error, - child: Text('${l10n.save}:\n$e'), - ); - Loggers.app.warning('Update watch config failed', e, trace); + await context.showLoadingDialog(fn: () async { + await wc.updateApplicationContext({'urls': result}); + }); + } catch (e, s) { + context.showErrDialog(e: e, s: s, operation: 'Watch Context'); + Loggers.app.warning('Update watch config failed', e, s); } } } diff --git a/pubspec.lock b/pubspec.lock index 0eb6634d8..b97717cd1 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -1396,19 +1396,11 @@ packages: dependency: "direct main" description: path: "." - ref: "v1.0.84" - resolved-ref: "50405d87bea86aece143c235b8b17263d37de3ef" + ref: "v1.0.85" + resolved-ref: "13e42750a8f8dbf9a6c7890198b0dd18283a0692" url: "https://github.com/lollipopkit/watch_connectivity" source: git version: "0.1.5" - watch_connectivity_platform_interface: - dependency: transitive - description: - name: watch_connectivity_platform_interface - sha256: "9074115391bd764c08a17346fcbc4d5c0b555672defbe6928ac648503b54aa9c" - url: "https://pub.dev" - source: hosted - version: "0.1.2" watcher: dependency: transitive description: diff --git a/pubspec.yaml b/pubspec.yaml index 7ab548ef9..2cfe0a285 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -50,7 +50,7 @@ dependencies: watch_connectivity: git: url: https://github.com/lollipopkit/watch_connectivity - ref: v1.0.84 + ref: v1.0.85 plain_notification_token: git: url: https://github.com/lollipopkit/plain_notification_token