Skip to content
This repository was archived by the owner on Feb 22, 2023. It is now read-only.

Commit 44d7782

Browse files
committed
Added PR feedback
1 parent 4cc0f56 commit 44d7782

File tree

8 files changed

+11
-14
lines changed

8 files changed

+11
-14
lines changed

packages/webview_flutter/webview_flutter_platform_interface/lib/v4/src/javascript_channel_registry.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ class JavaScriptChannelRegistry {
3131
javaScriptChannel.onMessageReceived(JavaScriptMessage(message: message));
3232
}
3333

34-
/// Updates the set of [JavaScriptChannel]s with the new set.
34+
/// Replaces the set of [JavaScriptChannel]s with the new set.
3535
void updateJavaScriptChannelsFromSet(Set<JavaScriptChannel>? channels) {
3636
this.channels.clear();
3737
if (channels == null) {

packages/webview_flutter/webview_flutter_platform_interface/lib/v4/src/navigation_callback_delegate.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import 'webview_platform.dart';
1313
///
1414
/// The [WebViewControllerDelegate] is notifying this delegate on events that
1515
/// happened on the platform's webview. Platform implementations should
16-
/// implement this class and pass an instance to the[WebViewControllerDelegate].
16+
/// implement this class and pass an instance to the [WebViewControllerDelegate].
1717
abstract class NavigationCallbackDelegate extends PlatformInterface {
1818
/// Creates a new [NavigationCallbackDelegate]
1919
factory NavigationCallbackDelegate(NavigationCallbackCreationParams params) {

packages/webview_flutter/webview_flutter_platform_interface/lib/v4/src/types/javascript_message.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import 'package:flutter/foundation.dart';
77
/// A message that was sent by JavaScript code running in a [WebView].
88
///
99
/// Platform specific implementations can add additional fields by extending
10-
/// this class and provide a factory method that takes the
10+
/// this class and providing a factory method that takes the
1111
/// [JavaScriptMessage] as a parameter.
1212
///
1313
/// {@tool sample}

packages/webview_flutter/webview_flutter_platform_interface/lib/v4/src/types/web_resource_error.dart

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,5 @@ class WebResourceError {
115115
final String description;
116116

117117
/// The type this error can be categorized as.
118-
///
119-
/// This will never be `null` on Android, but can be `null` on iOS.
120118
final WebResourceErrorType? errorType;
121119
}

packages/webview_flutter/webview_flutter_platform_interface/lib/v4/src/types/webview_widget_creation_params.dart

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ class WebViewWidgetCreationParams {
5050
const WebViewWidgetCreationParams({
5151
this.key,
5252
required this.controller,
53-
this.gestureRecognizers,
53+
this.gestureRecognizers = const <Factory<OneSequenceGestureRecognizer>>{},
5454
});
5555

5656
/// Controls how one widget replaces another widget in the tree.
@@ -72,8 +72,8 @@ class WebViewWidgetCreationParams {
7272
/// [ListView] will want to handle vertical drags. The web view will claim
7373
/// gestures that are recognized by any of the recognizers on this list.
7474
///
75-
/// When `gestureRecognizers` is empty or null, the web view will only handle
75+
/// When `gestureRecognizers` is empty (default), the web view will only handle
7676
/// pointer events for gestures that were not claimed by any other gesture
7777
/// recognizer.
78-
final Set<Factory<OneSequenceGestureRecognizer>>? gestureRecognizers;
78+
final Set<Factory<OneSequenceGestureRecognizer>> gestureRecognizers;
7979
}

packages/webview_flutter/webview_flutter_platform_interface/lib/v4/src/webview_controller_delegate.dart

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,6 @@ abstract class WebViewControllerDelegate extends PlatformInterface {
146146
/// 2. [Cache API](https://developers.google.com/web/fundamentals/instant-and-offline/web-storage/cache-api) caches.
147147
/// These are not yet supported in iOS WkWebView. Service workers tend to use this cache.
148148
/// 3. Application cache.
149-
/// 4. Local Storage.
150149
Future<void> clearCache() {
151150
throw UnimplementedError(
152151
'clearCache is not implemented on the current platform');

packages/webview_flutter/webview_flutter_platform_interface/lib/v4/src/webview_platform.dart

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ abstract class WebViewPlatform extends PlatformInterface {
3838

3939
/// Creates a new [WebViewCookieManagerDelegate].
4040
///
41-
/// This function should only be called by the app-facing plugin.
41+
/// This function should only be called by the app-facing package.
4242
/// Look at using [WebViewCookieManager] in `webview_flutter` instead.
4343
WebViewCookieManagerDelegate createCookieManagerDelegate(
4444
WebViewCookieManagerCreationParams params,
@@ -49,7 +49,7 @@ abstract class WebViewPlatform extends PlatformInterface {
4949

5050
/// Creates a new [NavigationCallbackDelegate].
5151
///
52-
/// This function should only be called by the app-facing plugin.
52+
/// This function should only be called by the app-facing package.
5353
/// Look at using [NavigationCallbackHandler] in `webview_flutter` instead.
5454
NavigationCallbackDelegate createNavigationCallbackDelegate(
5555
NavigationCallbackCreationParams params,
@@ -60,7 +60,7 @@ abstract class WebViewPlatform extends PlatformInterface {
6060

6161
/// Create a new [WebViewControllerDelegate].
6262
///
63-
/// This function should only be called by the app-facing plugin.
63+
/// This function should only be called by the app-facing package.
6464
/// Look at using [WebViewController] in `webview_flutter` instead.
6565
WebViewControllerDelegate createWebViewControllerDelegate(
6666
WebViewControllerCreationParams params,
@@ -71,7 +71,7 @@ abstract class WebViewPlatform extends PlatformInterface {
7171

7272
/// Create a new [WebViewWidgetDelegate].
7373
///
74-
/// This function should only be called by the app-facing plugin.
74+
/// This function should only be called by the app-facing package.
7575
/// Look at using [WebViewWidget] in `webview_flutter` instead.
7676
WebViewWidgetDelegate createWebViewWidgetDelegate(
7777
WebViewWidgetCreationParams params,

packages/webview_flutter/webview_flutter_platform_interface/test/src/v4/javascript_channel_registry_test.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
// found in the LICENSE file.
44

55
import 'package:flutter_test/flutter_test.dart';
6-
import 'package:webview_flutter_platform_interface/v4/src/javaScript_channel_registry.dart';
6+
import 'package:webview_flutter_platform_interface/v4/src/javascript_channel_registry.dart';
77
import 'package:webview_flutter_platform_interface/v4/src/types/types.dart';
88

99
void main() {

0 commit comments

Comments
 (0)