From 2f8fa22db439650d8dbcbd5dad72c9044163c907 Mon Sep 17 00:00:00 2001 From: Lorenzo Pichilli Date: Wed, 2 Nov 2022 15:08:44 +0100 Subject: [PATCH] code format --- .../in_app_webview/on_content_size_changed.dart | 3 +-- .../in_app_webview/on_permission_request.dart | 2 +- .../integration_test/service_worker_controller/main.dart | 4 ++-- example/integration_test/tracing_controller/main.dart | 4 ++-- .../integration_test/tracing_controller/start_and_stop.dart | 6 +++--- lib/src/android/tracing_controller.dart | 3 ++- lib/src/in_app_webview/headless_in_app_webview.dart | 3 +-- lib/src/in_app_webview/in_app_webview.dart | 3 +-- lib/src/in_app_webview/webview.dart | 3 +-- lib/src/types/main.dart | 2 +- lib/src/types/tracing_category.dart | 3 ++- 11 files changed, 17 insertions(+), 19 deletions(-) diff --git a/example/integration_test/in_app_webview/on_content_size_changed.dart b/example/integration_test/in_app_webview/on_content_size_changed.dart index 67e8e1b22..7b7b927d0 100644 --- a/example/integration_test/in_app_webview/on_content_size_changed.dart +++ b/example/integration_test/in_app_webview/on_content_size_changed.dart @@ -16,8 +16,7 @@ void onContentSizeChanged() { ].contains(defaultTargetPlatform); testWidgets('onContentSizeChanged', (WidgetTester tester) async { - final Completer onContentSizeChangedCompleter = - Completer(); + final Completer onContentSizeChangedCompleter = Completer(); await tester.pumpWidget( Directionality( textDirection: TextDirection.ltr, diff --git a/example/integration_test/in_app_webview/on_permission_request.dart b/example/integration_test/in_app_webview/on_permission_request.dart index 5fec6d09c..b8f7eb094 100644 --- a/example/integration_test/in_app_webview/on_permission_request.dart +++ b/example/integration_test/in_app_webview/on_permission_request.dart @@ -118,7 +118,7 @@ void onPermissionRequest() { controller.reload(); final List canceledResources = - await onPermissionRequestCancelCompleter.future; + await onPermissionRequestCancelCompleter.future; expect(listEquals(canceledResources, expectedValue), true); }, skip: shouldSkip2); } diff --git a/example/integration_test/service_worker_controller/main.dart b/example/integration_test/service_worker_controller/main.dart index 192b4954e..0d110c171 100644 --- a/example/integration_test/service_worker_controller/main.dart +++ b/example/integration_test/service_worker_controller/main.dart @@ -8,8 +8,8 @@ void main() { final shouldSkip = kIsWeb ? true : ![ - TargetPlatform.android, - ].contains(defaultTargetPlatform); + TargetPlatform.android, + ].contains(defaultTargetPlatform); group('Service Worker Controller', () { shouldInterceptRequest(); diff --git a/example/integration_test/tracing_controller/main.dart b/example/integration_test/tracing_controller/main.dart index 86347e943..4f89763a9 100644 --- a/example/integration_test/tracing_controller/main.dart +++ b/example/integration_test/tracing_controller/main.dart @@ -7,8 +7,8 @@ void main() { final shouldSkip = kIsWeb ? true : ![ - TargetPlatform.android, - ].contains(defaultTargetPlatform); + TargetPlatform.android, + ].contains(defaultTargetPlatform); group('Tracing Controller', () { startAndStop(); diff --git a/example/integration_test/tracing_controller/start_and_stop.dart b/example/integration_test/tracing_controller/start_and_stop.dart index 33a9015b5..c78563613 100644 --- a/example/integration_test/tracing_controller/start_and_stop.dart +++ b/example/integration_test/tracing_controller/start_and_stop.dart @@ -55,9 +55,9 @@ void startAndStop() { await pageLoaded.future; Directory appDocDir = await getApplicationDocumentsDirectory(); - String traceFilePath = '${appDocDir.path}${Platform.pathSeparator}trace.json'; - expect( - await tracingController.stop(filePath: traceFilePath), true); + String traceFilePath = + '${appDocDir.path}${Platform.pathSeparator}trace.json'; + expect(await tracingController.stop(filePath: traceFilePath), true); expect(File(traceFilePath).existsSync(), true); diff --git a/lib/src/android/tracing_controller.dart b/lib/src/android/tracing_controller.dart index 893cd8c4e..26d303780 100644 --- a/lib/src/android/tracing_controller.dart +++ b/lib/src/android/tracing_controller.dart @@ -147,7 +147,8 @@ class TracingSettings_ { assert( this .categories - .map((e) => e.runtimeType is String || e.runtimeType is TracingCategory) + .map((e) => + e.runtimeType is String || e.runtimeType is TracingCategory) .contains(false), "categories must contain only String or TracingCategory items"); } diff --git a/lib/src/in_app_webview/headless_in_app_webview.dart b/lib/src/in_app_webview/headless_in_app_webview.dart index 625a170a1..901b7df9b 100644 --- a/lib/src/in_app_webview/headless_in_app_webview.dart +++ b/lib/src/in_app_webview/headless_in_app_webview.dart @@ -684,8 +684,7 @@ class HeadlessInAppWebView implements WebView, Disposable { PermissionRequest permissionRequest)? onPermissionRequestCanceled; @override - final void Function(InAppWebViewController controller)? - onRequestFocus; + final void Function(InAppWebViewController controller)? onRequestFocus; @override void Function( diff --git a/lib/src/in_app_webview/in_app_webview.dart b/lib/src/in_app_webview/in_app_webview.dart index 3c18c6935..d27247fbe 100755 --- a/lib/src/in_app_webview/in_app_webview.dart +++ b/lib/src/in_app_webview/in_app_webview.dart @@ -558,8 +558,7 @@ class InAppWebView extends StatefulWidget implements WebView { PermissionRequest permissionRequest)? onPermissionRequestCanceled; @override - final void Function(InAppWebViewController controller)? - onRequestFocus; + final void Function(InAppWebViewController controller)? onRequestFocus; @override final void Function( diff --git a/lib/src/in_app_webview/webview.dart b/lib/src/in_app_webview/webview.dart index 41a5d4f3c..1a8754405 100644 --- a/lib/src/in_app_webview/webview.dart +++ b/lib/src/in_app_webview/webview.dart @@ -863,8 +863,7 @@ abstract class WebView { /// ///**Supported Platforms/Implementations**: ///- Android native WebView ([Official API - WebChromeClient.onRequestFocus](https://developer.android.com/reference/android/webkit/WebChromeClient#onRequestFocus(android.webkit.WebView))) - final void Function(InAppWebViewController controller)? - onRequestFocus; + final void Function(InAppWebViewController controller)? onRequestFocus; ///Use [onWebContentProcessDidTerminate] instead. @Deprecated('Use onWebContentProcessDidTerminate instead') diff --git a/lib/src/types/main.dart b/lib/src/types/main.dart index 4cad6ba24..64118b6d6 100644 --- a/lib/src/types/main.dart +++ b/lib/src/types/main.dart @@ -224,4 +224,4 @@ export 'ui_image.dart' show UIImage; export 'activity_button.dart' show ActivityButton; export 'ui_event_attribution.dart' show UIEventAttribution; export 'tracing_mode.dart' show TracingMode; -export 'tracing_category.dart' show TracingCategory; \ No newline at end of file +export 'tracing_category.dart' show TracingCategory; diff --git a/lib/src/types/tracing_category.dart b/lib/src/types/tracing_category.dart index 00cac6ce6..cc355875e 100644 --- a/lib/src/types/tracing_category.dart +++ b/lib/src/types/tracing_category.dart @@ -28,7 +28,8 @@ class TracingCategory_ { ///Predefined set of categories for analyzing javascript and rendering issues. ///Typically includes "blink", "compositor", "gpu", "renderer.scheduler" and "v8" categories. - static const CATEGORIES_JAVASCRIPT_AND_RENDERING = const TracingCategory_._internal(32); + static const CATEGORIES_JAVASCRIPT_AND_RENDERING = + const TracingCategory_._internal(32); ///Indicates that there are no predefined categories. static const CATEGORIES_NONE = const TracingCategory_._internal(0);