File tree Expand file tree Collapse file tree 4 files changed +23
-9
lines changed Expand file tree Collapse file tree 4 files changed +23
-9
lines changed Original file line number Diff line number Diff line change 11group ' com.flutter_webview_plugin'
22version ' 1.0-SNAPSHOT'
33
4+ def ANDROIDX_WARNING = " flutterPluginsAndroidXWarning" ;
5+ gradle. buildFinished { buildResult ->
6+ if (buildResult. failure && ! rootProject. ext. has(ANDROIDX_WARNING )) {
7+ println ' *********************************************************'
8+ println ' WARNING: This version of flutter_webview_plugin will break your Android build if it or its dependencies aren\' t compatible with AndroidX.'
9+ println ' See https://goo.gl/CP92wY for more information on the problem and how to fix it.'
10+ println ' This warning prints for all Android build failures. The real root cause of the error may be unrelated.'
11+ println ' *********************************************************'
12+ rootProject. ext. set(ANDROIDX_WARNING , true );
13+ }
14+ }
15+
416buildscript {
517 repositories {
618 google()
719 jcenter()
820 }
921
1022 dependencies {
11- classpath ' com.android.tools.build:gradle:3.2.1 '
23+ classpath ' com.android.tools.build:gradle:3.3.2 '
1224 }
1325}
1426
@@ -21,10 +33,10 @@ allprojects {
2133apply plugin : ' com.android.library'
2234
2335android {
24- compileSdkVersion 27
36+ compileSdkVersion 28
2537
2638 defaultConfig {
27- testInstrumentationRunner " android.support .test.runner.AndroidJUnitRunner"
39+ testInstrumentationRunner " androidx .test.runner.AndroidJUnitRunner"
2840 // NOTE(jeffmikels): When targetSdkVersion or minSdkVersion is not set or < 4, gradle adds
2941 // additional scary permissions such as WRITE_EXTERNAL_STORAGE and READ_PHONE_STATE.
3042 minSdkVersion 16
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ apply plugin: 'com.android.application'
1515apply from : " $flutterRoot /packages/flutter_tools/gradle/flutter.gradle"
1616
1717android {
18- compileSdkVersion 27
18+ compileSdkVersion 28
1919
2020 lintOptions {
2121 disable ' InvalidPackage'
@@ -42,7 +42,7 @@ flutter {
4242}
4343
4444dependencies {
45- androidTestImplementation ' com.android.support:support-annotations:27 .0.0 '
46- androidTestImplementation ' com.android.support. test:runner:1.0.2 '
47- androidTestImplementation ' com.android.support. test:rules:1.0.2 '
45+ androidTestImplementation ' androidx.annotation:annotation:1 .0.2 '
46+ androidTestImplementation ' androidx. test:runner:1.1.1 '
47+ androidTestImplementation ' androidx. test:rules:1.1.1 '
4848}
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ buildscript {
88 }
99
1010 dependencies {
11- classpath ' com.android.tools.build:gradle:3.2.1 '
11+ classpath ' com.android.tools.build:gradle:3.3.2 '
1212 }
1313}
1414
@@ -33,5 +33,5 @@ task clean(type: Delete) {
3333}
3434
3535task wrapper (type : Wrapper ) {
36- gradleVersion = ' 2.14.1 '
36+ gradleVersion = ' 4.10.2 '
3737}
Original file line number Diff line number Diff line change 11org.gradle.jvmargs =-Xmx1536M
2+ android.useAndroidX =true
3+ android.enableJetifier =false
You can’t perform that action at this time.
0 commit comments