From e1f4178fd41d2dae8b08d7c61700930803aad294 Mon Sep 17 00:00:00 2001 From: Maurice Parrish <10687576+bparrishMines@users.noreply.github.com> Date: Wed, 15 Mar 2023 19:36:18 -0400 Subject: [PATCH 1/3] Updates the README with the migration of and Hybrid Composition on Android --- packages/webview_flutter/webview_flutter/CHANGELOG.md | 5 +++++ packages/webview_flutter/webview_flutter/README.md | 9 ++++++--- packages/webview_flutter/webview_flutter/pubspec.yaml | 2 +- 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/packages/webview_flutter/webview_flutter/CHANGELOG.md b/packages/webview_flutter/webview_flutter/CHANGELOG.md index 8d35f107a14..3fd3dec7ce8 100644 --- a/packages/webview_flutter/webview_flutter/CHANGELOG.md +++ b/packages/webview_flutter/webview_flutter/CHANGELOG.md @@ -1,3 +1,8 @@ +## 4.0.7 + +* Updates the README with the migration of `WebView.initialCookies` and Hybrid Composition on + Android. + ## 4.0.6 * Updates iOS minimum version in README. diff --git a/packages/webview_flutter/webview_flutter/README.md b/packages/webview_flutter/webview_flutter/README.md index cc14760782a..e3a096d6ec5 100644 --- a/packages/webview_flutter/webview_flutter/README.md +++ b/packages/webview_flutter/webview_flutter/README.md @@ -157,7 +157,7 @@ In version 3.0 and below, `WebViewController` could only be retrieved in a callb `WebView` was added to the widget tree. Now, `WebViewController` must be instantiated and can be used before it is added to the widget tree. See `Usage` section above for an example. -### Replacing WebView Functionality +### Replacing WebView Functionality The `WebView` class has been removed and its functionality has been split into `WebViewController` and `WebViewWidget`. @@ -177,8 +177,9 @@ for more details. The PlatformView implementation for Android is currently no longer configurable. It uses Texture Layer Hybrid Composition on versions 23+ and automatically fallbacks to Hybrid Composition for -version 19-23. See https://github.com/flutter/flutter/issues/108106 for progress on manually -switching to Hybrid Composition on versions 23+. +version 19-23. See section `Platform-Specific Features` and +[AndroidWebViewWidgetCreationParams.displayWithHybridComposition](https://pub.dev/documentation/webview_flutter_android/latest/webview_flutter_android/AndroidWebViewWidgetCreationParams/displayWithHybridComposition.html) +to manually switch to Hybrid Composition on versions 23+. ### API Changes @@ -194,6 +195,8 @@ Below is a non-exhaustive list of changes to the API: been replaced by `WebViewController.getScrollPosition`. * `WebViewController.runJavaScriptReturningResult` now returns an `Object` and not a `String`. This will attempt to return a `bool` or `num` if the return value can be parsed. +* `WebView.initialCookies` has been removed. Use `WebViewCookieManager.setCookie` before calling + `WebViewController.loadRequest`. * `CookieManager` is replaced by `WebViewCookieManager`. * `NavigationDelegate.onWebResourceError` callback includes errors that are not from the main frame. Use the `WebResourceError.isForMainFrame` field to filter errors. diff --git a/packages/webview_flutter/webview_flutter/pubspec.yaml b/packages/webview_flutter/webview_flutter/pubspec.yaml index 2899d97fda9..168cf965169 100644 --- a/packages/webview_flutter/webview_flutter/pubspec.yaml +++ b/packages/webview_flutter/webview_flutter/pubspec.yaml @@ -2,7 +2,7 @@ name: webview_flutter description: A Flutter plugin that provides a WebView widget on Android and iOS. repository: https://github.com/flutter/packages/tree/main/packages/webview_flutter/webview_flutter issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+webview%22 -version: 4.0.6 +version: 4.0.7 environment: sdk: ">=2.17.0 <3.0.0" From ac50a8ee15f78e38d495f8b359bd919bc989d4a9 Mon Sep 17 00:00:00 2001 From: Maurice Parrish <10687576+bparrishMines@users.noreply.github.com> Date: Wed, 15 Mar 2023 19:40:57 -0400 Subject: [PATCH 2/3] remove test code --- packages/webview_flutter/webview_flutter/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/webview_flutter/webview_flutter/README.md b/packages/webview_flutter/webview_flutter/README.md index e3a096d6ec5..8d600e665e4 100644 --- a/packages/webview_flutter/webview_flutter/README.md +++ b/packages/webview_flutter/webview_flutter/README.md @@ -157,7 +157,7 @@ In version 3.0 and below, `WebViewController` could only be retrieved in a callb `WebView` was added to the widget tree. Now, `WebViewController` must be instantiated and can be used before it is added to the widget tree. See `Usage` section above for an example. -### Replacing WebView Functionality +### Replacing WebView Functionality The `WebView` class has been removed and its functionality has been split into `WebViewController` and `WebViewWidget`. From be0ada2064a67a971cf96dc98d5527365a53fcde Mon Sep 17 00:00:00 2001 From: Maurice Parrish <10687576+bparrishMines@users.noreply.github.com> Date: Sun, 19 Mar 2023 10:30:11 -0400 Subject: [PATCH 3/3] remove configurable statement --- packages/webview_flutter/webview_flutter/README.md | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/packages/webview_flutter/webview_flutter/README.md b/packages/webview_flutter/webview_flutter/README.md index 8d600e665e4..5338b0eb2ea 100644 --- a/packages/webview_flutter/webview_flutter/README.md +++ b/packages/webview_flutter/webview_flutter/README.md @@ -175,10 +175,9 @@ for more details. ### PlatformView Implementation on Android -The PlatformView implementation for Android is currently no longer configurable. It uses Texture -Layer Hybrid Composition on versions 23+ and automatically fallbacks to Hybrid Composition for -version 19-23. See section `Platform-Specific Features` and -[AndroidWebViewWidgetCreationParams.displayWithHybridComposition](https://pub.dev/documentation/webview_flutter_android/latest/webview_flutter_android/AndroidWebViewWidgetCreationParams/displayWithHybridComposition.html) +The PlatformView implementation for Android uses Texture Layer Hybrid Composition on versions 23+ +and automatically fallbacks to Hybrid Composition for version 19-23. See section +`Platform-Specific Features` and [AndroidWebViewWidgetCreationParams.displayWithHybridComposition](https://pub.dev/documentation/webview_flutter_android/latest/webview_flutter_android/AndroidWebViewWidgetCreationParams/displayWithHybridComposition.html) to manually switch to Hybrid Composition on versions 23+. ### API Changes