diff --git a/android/build.gradle b/android/build.gradle index fa7154f4..9cc60378 100755 --- a/android/build.gradle +++ b/android/build.gradle @@ -4,7 +4,7 @@ version '1.0-SNAPSHOT' buildscript { repositories { google() - jcenter() + mavenCentral() } dependencies { @@ -15,7 +15,7 @@ buildscript { rootProject.allprojects { repositories { google() - jcenter() + mavenCentral() } } diff --git a/android/src/main/AndroidManifest.xml b/android/src/main/AndroidManifest.xml index c6ffe08e..52fb1c85 100755 --- a/android/src/main/AndroidManifest.xml +++ b/android/src/main/AndroidManifest.xml @@ -4,13 +4,16 @@ diff --git a/android/src/main/java/com/pichillilorenzo/flutter_inappwebview/chrome_custom_tabs/ChromeCustomTabsActivity.java b/android/src/main/java/com/pichillilorenzo/flutter_inappwebview/chrome_custom_tabs/ChromeCustomTabsActivity.java index ba8d0f06..fa0c0803 100755 --- a/android/src/main/java/com/pichillilorenzo/flutter_inappwebview/chrome_custom_tabs/ChromeCustomTabsActivity.java +++ b/android/src/main/java/com/pichillilorenzo/flutter_inappwebview/chrome_custom_tabs/ChromeCustomTabsActivity.java @@ -207,8 +207,13 @@ public class ChromeCustomTabsActivity extends Activity implements MethodChannel. extras.putString(ActionBroadcastReceiver.CHROME_MANAGER_ID, manager.id); actionIntent.putExtras(extras); - return PendingIntent.getBroadcast( - this, actionSourceId, actionIntent, PendingIntent.FLAG_UPDATE_CURRENT); + if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.M) { + return PendingIntent.getBroadcast( + this, actionSourceId, actionIntent, PendingIntent.FLAG_UPDATE_CURRENT | PendingIntent.FLAG_IMMUTABLE); + } else { + return PendingIntent.getBroadcast( + this, actionSourceId, actionIntent, PendingIntent.FLAG_UPDATE_CURRENT); + } } public void dispose() { diff --git a/example/android/app/src/main/AndroidManifest.xml b/example/android/app/src/main/AndroidManifest.xml index 810f0cdc..8e93da90 100755 --- a/example/android/app/src/main/AndroidManifest.xml +++ b/example/android/app/src/main/AndroidManifest.xml @@ -55,6 +55,7 @@ android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|layoutDirection|fontScale|screenLayout|density" android:hardwareAccelerated="true" android:launchMode="singleTop" + android:exported="true" android:name="io.flutter.embedding.android.FlutterActivity" android:theme="@style/LaunchTheme" android:windowSoftInputMode="adjustResize"> diff --git a/example/android/build.gradle b/example/android/build.gradle index 714549c2..4256f917 100755 --- a/example/android/build.gradle +++ b/example/android/build.gradle @@ -2,7 +2,7 @@ buildscript { ext.kotlin_version = '1.6.10' repositories { google() - jcenter() + mavenCentral() } dependencies { @@ -14,7 +14,7 @@ buildscript { allprojects { repositories { google() - jcenter() + mavenCentral() } } diff --git a/example/pubspec.yaml b/example/pubspec.yaml index 2ce18c4a..aa1622d8 100755 --- a/example/pubspec.yaml +++ b/example/pubspec.yaml @@ -10,8 +10,8 @@ description: Demonstrates how to use the flutter_inappwebview plugin. version: 1.0.0+1 environment: - sdk: ">=2.12.0-0 <3.0.0" - flutter: ">=1.22.2" + sdk: ">=2.14.0 <3.0.0" + flutter: ">=2.5.0" dependencies: flutter: @@ -19,11 +19,11 @@ dependencies: # The following adds the Cupertino Icons font to your application. # Use with the CupertinoIcons class for iOS style icons. - cupertino_icons: ^1.0.2 - flutter_downloader: ^1.5.2 - path_provider: ^2.0.0-nullsafety - permission_handler: ^5.1.0+2 - url_launcher: ^6.0.0-nullsafety.4 + cupertino_icons: ^1.0.4 + flutter_downloader: ^1.7.3 + path_provider: ^2.0.9 + permission_handler: ^9.2.0 + url_launcher: ^6.0.20 # connectivity: ^0.4.5+6 flutter_inappwebview: path: ../