Skip to content

Commit daa0f06

Browse files
committed
refact:升级安卓 compileSdkVersion 到 28 支持android x
1 parent 5bb7581 commit daa0f06

File tree

4 files changed

+9
-6
lines changed

4 files changed

+9
-6
lines changed

android/app/build.gradle

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ if (keystorePropertiesFile.exists()) {
3232
}
3333

3434
android {
35-
compileSdkVersion 27
35+
compileSdkVersion 28
3636

3737
lintOptions {
3838
disable 'InvalidPackage'
@@ -42,10 +42,10 @@ android {
4242
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
4343
applicationId "com.flutter.beer"
4444
minSdkVersion 16
45-
targetSdkVersion 27
45+
targetSdkVersion 28
4646
versionCode flutterVersionCode.toInteger()
4747
versionName flutterVersionName
48-
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
48+
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
4949
}
5050

5151
signingConfigs {
@@ -79,8 +79,8 @@ flutter {
7979

8080
dependencies {
8181
testImplementation 'junit:junit:4.12'
82-
androidTestImplementation 'com.android.support.test:runner:1.0.2'
83-
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
82+
androidTestImplementation 'androidx.test:runner:1.1.0-alpha4'
83+
androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.0-alpha4'
8484
//firebase
8585
implementation 'com.google.firebase:firebase-core:16.0.8'
8686
//Crashlytics SDK

android/gradle.properties

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
11
org.gradle.jvmargs=-Xmx1536M
2+
android.useAndroidX=true
3+
android.enableJetifier=true

lib/page/component/tabs.dart

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ class _IndexState extends State<Index>
7070

7171
Widget _TabBar() {
7272
return TabBar(
73+
indicatorColor: Color(AppTheme.secondColor),
7374
controller: _tabController,
7475
isScrollable: true,
7576
tabs: _mapList.map((v) {

pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ description: A new Flutter project.
77
# Both the version and the builder number may be overridden in flutter
88
# build by specifying --build-name and --build-number, respectively.
99
# Read more about versioning at semver.org.
10-
version: 1.0.0+1
10+
version: 1.0.1+1
1111

1212
environment:
1313
sdk: ">=2.1.0 <3.0.0"

0 commit comments

Comments
 (0)