Skip to content

Commit d4f708b

Browse files
author
Emmanuel Garcia
authored
[webview_flutter] Remove fallback Activity and watch uiMode (flutter#3849)
1 parent 15cedbc commit d4f708b

File tree

4 files changed

+7
-33
lines changed

4 files changed

+7
-33
lines changed

packages/webview_flutter/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
## 2.0.5
2+
3+
* Example app observes `uiMode`, so the WebView isn't reattached when the UI mode changes. (e.g. switching to Dark mode).
4+
15
## 2.0.4
26

37
* Fix a bug where `allowsInlineMediaPlayback` is not respected on iOS.

packages/webview_flutter/example/android/app/src/main/AndroidManifest.xml

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,10 @@
1414
android:name="flutterEmbedding"
1515
android:value="2" />
1616
<activity
17-
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|layoutDirection|fontScale|screenLayout|density"
18-
android:exported="true"
17+
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode"
1918
android:hardwareAccelerated="true"
2019
android:launchMode="singleTop"
21-
android:name=".EmbeddingV1Activity"
20+
android:name="io.flutter.embedding.android.FlutterActivity"
2221
android:theme="@style/LaunchTheme"
2322
android:windowSoftInputMode="adjustResize">
2423
<!-- This keeps the window background of the activity showing
@@ -28,14 +27,6 @@
2827
<meta-data
2928
android:name="io.flutter.app.android.SplashScreenUntilFirstFrame"
3029
android:value="true"/>
31-
</activity>
32-
<activity
33-
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|layoutDirection|fontScale|screenLayout|density"
34-
android:hardwareAccelerated="true"
35-
android:launchMode="singleTop"
36-
android:name="io.flutter.embedding.android.FlutterActivity"
37-
android:theme="@style/LaunchTheme"
38-
android:windowSoftInputMode="adjustResize">
3930
<intent-filter>
4031
<action android:name="android.intent.action.MAIN"/>
4132
<category android:name="android.intent.category.LAUNCHER"/>

packages/webview_flutter/example/android/app/src/main/java/io/flutter/plugins/webviewflutterexample/EmbeddingV1Activity.java

Lines changed: 0 additions & 21 deletions
This file was deleted.

packages/webview_flutter/pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name: webview_flutter
22
description: A Flutter plugin that provides a WebView widget on Android and iOS.
33
homepage: https://github.com/flutter/plugins/tree/master/packages/webview_flutter
4-
version: 2.0.4
4+
version: 2.0.5
55

66
environment:
77
sdk: ">=2.12.0 <3.0.0"

0 commit comments

Comments
 (0)