diff --git a/packages/messageport/lib/src/messageport_manager.dart b/packages/messageport/lib/src/messageport_manager.dart index 536db6962..38af5a7e8 100644 --- a/packages/messageport/lib/src/messageport_manager.dart +++ b/packages/messageport/lib/src/messageport_manager.dart @@ -25,9 +25,9 @@ class TizenMessagePortManager { args['remoteAppId'] = remoteAppId; args['portName'] = portName; args['trusted'] = trusted; - final bool status = - await _channel.invokeMethod('checkForRemote', args) as bool; - return status; + final bool? status = + await _channel.invokeMethod('checkForRemote', args); + return status ?? false; } Future send(RemotePort remotePort, dynamic message) async { diff --git a/packages/path_provider/lib/src/app_common.dart b/packages/path_provider/lib/src/app_common.dart index cc2b59d7e..31a0df2ac 100644 --- a/packages/path_provider/lib/src/app_common.dart +++ b/packages/path_provider/lib/src/app_common.dart @@ -8,10 +8,10 @@ import 'dart:ffi'; import 'package:ffi/ffi.dart'; -typedef _app_common_get_data_path = Pointer Function(); -typedef _app_common_get_cache_path = Pointer Function(); -typedef _app_common_get_external_data_path = Pointer Function(); -typedef _app_common_get_external_cache_path = Pointer Function(); +typedef _AppCommonGetDataPath = Pointer Function(); +typedef _AppCommonGetCachePath = Pointer Function(); +typedef _AppCommonGetExternalDataPath = Pointer Function(); +typedef _AppCommonGetExternalCachePath = Pointer Function(); AppCommon? _appCommonInstance; AppCommon get appCommon => _appCommonInstance ??= AppCommon(); @@ -24,18 +24,17 @@ class AppCommon { final DynamicLibrary libAppCommon = DynamicLibrary.open('libcapi-appfw-app-common.so.0'); _getDataPath = libAppCommon - .lookup>('app_get_data_path') + .lookup>('app_get_data_path') .asFunction(); _getCachePath = libAppCommon - .lookup>( - 'app_get_cache_path') + .lookup>('app_get_cache_path') .asFunction(); _getExternalDataPath = libAppCommon - .lookup>( + .lookup>( 'app_get_external_data_path') .asFunction(); _getExternalCachePath = libAppCommon - .lookup>( + .lookup>( 'app_get_external_cache_path') .asFunction(); } diff --git a/packages/path_provider/lib/src/storage.dart b/packages/path_provider/lib/src/storage.dart index 988d839eb..504a69db8 100644 --- a/packages/path_provider/lib/src/storage.dart +++ b/packages/path_provider/lib/src/storage.dart @@ -10,12 +10,12 @@ import 'dart:ffi'; import 'package:ffi/ffi.dart'; import 'package:flutter/services.dart'; -typedef _storage_get_directory = Int32 Function( +typedef _StorageGetDirectory = Int32 Function( Int32, Int32, Pointer>); -typedef _storage_callback = Int32 Function( +typedef _StorageCallback = Int32 Function( Int32, Int32, Int32, Pointer, Pointer); -typedef _storage_foreach_device_supported = Int32 Function( - Pointer>, Pointer); +typedef _StorageForeachDeviceSupported = Int32 Function( + Pointer>, Pointer); /// Corresponds to `storage_directory_e`. enum StorageDirectoryType { @@ -40,11 +40,11 @@ class Storage { Storage() { final DynamicLibrary libStorage = DynamicLibrary.open('libstorage.so.0.1'); _storageGetDirectory = libStorage - .lookup>('storage_get_directory') + .lookup>('storage_get_directory') .asFunction(); _storageForeachDeviceSupported = libStorage - .lookup>( + .lookup>( 'storage_foreach_device_supported') .asFunction(); @@ -63,7 +63,7 @@ class Storage { } late int Function(int, int, Pointer>) _storageGetDirectory; - late int Function(Pointer>, Pointer) + late int Function(Pointer>, Pointer) _storageForeachDeviceSupported; /// The unique storage device id. diff --git a/packages/share_plus/example/lib/main.dart b/packages/share_plus/example/lib/main.dart index ab7ec1d4e..43eb32cc5 100644 --- a/packages/share_plus/example/lib/main.dart +++ b/packages/share_plus/example/lib/main.dart @@ -66,7 +66,7 @@ class DemoAppState extends State { title: Text('Add image'), onTap: () async { final imagePicker = ImagePicker(); - final pickedFile = await imagePicker.getImage( + final pickedFile = await imagePicker.pickImage( source: ImageSource.gallery, ); if (pickedFile != null) { diff --git a/packages/shared_preferences/pubspec.yaml b/packages/shared_preferences/pubspec.yaml index b9ec274d4..64aab53ae 100644 --- a/packages/shared_preferences/pubspec.yaml +++ b/packages/shared_preferences/pubspec.yaml @@ -11,7 +11,7 @@ flutter: fileName: shared_preferences_tizen.dart dependencies: - ffi: ^1.0.0 + ffi: ^1.1.2 flutter: sdk: flutter shared_preferences_platform_interface: ^2.0.0 @@ -20,5 +20,5 @@ dev_dependencies: pedantic: ^1.10.0 environment: - sdk: '>=2.12.0 <3.0.0' + sdk: ">=2.12.0 <3.0.0" flutter: ">=2.0.0" diff --git a/packages/video_player/example/pubspec.yaml b/packages/video_player/example/pubspec.yaml index c668ba932..8d79ad3a4 100644 --- a/packages/video_player/example/pubspec.yaml +++ b/packages/video_player/example/pubspec.yaml @@ -10,23 +10,24 @@ dependencies: path: ../ dev_dependencies: - flutter_test: - sdk: flutter flutter_driver: sdk: flutter + flutter_test: + sdk: flutter integration_test: sdk: flutter integration_test_tizen: path: ../../integration_test/ pedantic: ^1.10.0 + test: any flutter: - uses-material-design: true assets: - assets/flutter-mark-square-64.png - assets/Butterfly-209.mp4 - assets/bumble_bee_captions.srt + uses-material-design: true environment: - sdk: ">=2.12.0 <3.0.0" flutter: ">=2.0.0" + sdk: ">=2.12.0 <3.0.0" diff --git a/packages/video_player/pubspec.yaml b/packages/video_player/pubspec.yaml index 6320d10d5..f620e1350 100644 --- a/packages/video_player/pubspec.yaml +++ b/packages/video_player/pubspec.yaml @@ -12,13 +12,13 @@ flutter: fileName: video_player_tizen_plugin.h dependencies: - video_player_platform_interface: ^4.1.0 flutter: sdk: flutter + video_player_platform_interface: ^4.1.0 dev_dependencies: pedantic: ^1.10.0 environment: - sdk: ">=2.12.0<3.0.0" flutter: ">=2.0.0" + sdk: ">=2.12.0<3.0.0" diff --git a/packages/wakelock/example/integration_test/wakelock_test.dart b/packages/wakelock/example/integration_test/wakelock_test.dart index 70762581a..c61f9391a 100644 --- a/packages/wakelock/example/integration_test/wakelock_test.dart +++ b/packages/wakelock/example/integration_test/wakelock_test.dart @@ -12,12 +12,12 @@ void main() { }); testWidgets('enable wakelock', (WidgetTester tester) async { - Wakelock.enable(); + await Wakelock.enable(); expect(await Wakelock.enabled, true); }); testWidgets('disable wakelock', (WidgetTester tester) async { - Wakelock.disable(); + await Wakelock.disable(); expect(await Wakelock.enabled, false); }); } diff --git a/packages/webview_flutter/example/lib/main.dart b/packages/webview_flutter/example/lib/main.dart index cdb05d526..9363e4f0a 100644 --- a/packages/webview_flutter/example/lib/main.dart +++ b/packages/webview_flutter/example/lib/main.dart @@ -6,7 +6,6 @@ import 'dart:async'; import 'dart:convert'; -import 'dart:io'; import 'package:flutter/material.dart'; import 'package:webview_flutter/webview_flutter.dart'; diff --git a/packages/webview_flutter/lib/src/platform_view_tizen.dart b/packages/webview_flutter/lib/src/platform_view_tizen.dart index 4fc9884ec..03722f7bc 100644 --- a/packages/webview_flutter/lib/src/platform_view_tizen.dart +++ b/packages/webview_flutter/lib/src/platform_view_tizen.dart @@ -363,8 +363,10 @@ class TizenViewController extends PlatformViewController { @override Future dispose() async { - if (_state == _TizenViewState.creating || _state == _TizenViewState.created) + if (_state == _TizenViewState.creating || + _state == _TizenViewState.created) { await _sendDisposeMessage(); + } _platformViewCreatedCallbacks.clear(); _state = _TizenViewState.disposed; PlatformViewsServiceTizen._instance._focusCallbacks.remove(viewId);