Skip to content

Commit 41f44f2

Browse files
author
Kurian Vithayathil
committed
Migrate from android support to androidx libraries
1 parent b9ac798 commit 41f44f2

File tree

46 files changed

+125
-121
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+125
-121
lines changed

build.gradle

+5-2
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,12 @@ project.ext.set("targetSdkVersion", 28)
66
project.ext.set("libraryGroup", 'com.willowtreeapps.hyperion')
77
project.ext.set("libraryVersion", '0.9.28-SNAPSHOT')
88

9-
project.ext.set("versionSupportLibrary", "28.0.0")
109
project.ext.set("versionAutoService", "1.0-rc4")
1110
project.ext.set("versionDagger", "2.15")
11+
project.ext.set("versionRecyclerview", "1.0.0")
12+
project.ext.set("versionAppCompat", "1.0.2")
13+
project.ext.set("versionConstraintLayout", "1.1.3")
14+
project.ext.set("versionMaterial", "1.0.0")
1215

1316
buildscript {
1417

@@ -25,7 +28,7 @@ buildscript {
2528
}
2629

2730
dependencies {
28-
classpath 'com.android.tools.build:gradle:3.4.0'
31+
classpath 'com.android.tools.build:gradle:3.4.1'
2932
classpath "me.tatarka.gradle:pom:1.0"
3033
}
3134
}

gradle.properties

+3-1
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,6 @@ org.gradle.jvmargs=-Xmx1536m
1616
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
1717
org.gradle.parallel=true
1818
# enable after fix https://github.com/gradle/gradle/issues/4848
19-
org.gradle.configureondemand=false
19+
org.gradle.configureondemand=false
20+
android.useAndroidX=true
21+
android.enableJetifier=true

hyperion-attr-appcompat-v7/build.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ android {
1313
versionCode buildVersionCode()
1414
versionName version
1515

16-
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
16+
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
1717
}
1818

1919
lintOptions {
@@ -28,7 +28,7 @@ dependencies {
2828
compileOnly project(':hyperion-plugin')
2929
compileOnly project(':hyperion-attr')
3030
annotationProcessor "com.google.auto.service:auto-service:${project.versionAutoService}"
31-
implementation "com.android.support:appcompat-v7:${project.versionSupportLibrary}"
31+
implementation "androidx.appcompat:appcompat:${project.versionAppCompat}"
3232
}
3333

3434
apply from: '../publish.gradle'

hyperion-attr-design/build.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ android {
1313
versionCode buildVersionCode()
1414
versionName version
1515

16-
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
16+
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
1717
}
1818

1919
lintOptions {
@@ -27,7 +27,7 @@ dependencies {
2727
compileOnly project(':hyperion-plugin')
2828
compileOnly project(':hyperion-attr')
2929
annotationProcessor "com.google.auto.service:auto-service:${project.versionAutoService}"
30-
implementation "com.android.support:design:${project.versionSupportLibrary}"
30+
implementation "com.google.android.material:material:${project.versionMaterial}"
3131
}
3232

3333
apply from: '../publish.gradle'

hyperion-attr-recyclerview/build.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ android {
1313
versionCode buildVersionCode()
1414
versionName version
1515

16-
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
16+
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
1717
}
1818

1919
lintOptions {
@@ -27,7 +27,7 @@ dependencies {
2727
compileOnly project(':hyperion-plugin')
2828
compileOnly project(':hyperion-attr')
2929
annotationProcessor "com.google.auto.service:auto-service:${project.versionAutoService}"
30-
implementation "com.android.support:recyclerview-v7:${project.versionSupportLibrary}"
30+
implementation "androidx.recyclerview:recyclerview:${project.versionRecyclerview}"
3131
}
3232

3333
apply from: '../publish.gradle'

hyperion-attr-support-v4/build.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ android {
1313
versionCode buildVersionCode()
1414
versionName version
1515

16-
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
16+
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
1717
}
1818

1919
lintOptions {
@@ -27,7 +27,7 @@ dependencies {
2727
compileOnly project(':hyperion-plugin')
2828
compileOnly project(':hyperion-attr')
2929
annotationProcessor "com.google.auto.service:auto-service:${project.versionAutoService}"
30-
implementation "com.android.support:appcompat-v7:${project.versionSupportLibrary}"
30+
implementation "androidx.appcompat:appcompat:${project.versionAppCompat}"
3131
}
3232

3333
apply from: '../publish.gradle'

hyperion-attr/build.gradle

+4-4
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ android {
1414
versionName version
1515
consumerProguardFiles 'consumer-proguard-rules.pro'
1616

17-
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
17+
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
1818
}
1919

2020
lintOptions {
@@ -26,9 +26,9 @@ android {
2626

2727
dependencies {
2828
api project(':hyperion-plugin')
29-
implementation "com.android.support:appcompat-v7:${project.versionSupportLibrary}"
30-
implementation "com.android.support:design:${project.versionSupportLibrary}"
31-
implementation "com.android.support:recyclerview-v7:${project.versionSupportLibrary}"
29+
implementation "androidx.appcompat:appcompat:${project.versionAppCompat}"
30+
implementation "com.google.android.material:material:${project.versionMaterial}"
31+
implementation "androidx.recyclerview:recyclerview:${project.versionRecyclerview}"
3232
implementation "com.google.dagger:dagger:${project.versionDagger}"
3333
annotationProcessor "com.google.auto.service:auto-service:${project.versionAutoService}"
3434
}

hyperion-attr/src/main/res/layout/ha_item_plugin.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
android:gravity="center_vertical"
1010
android:background="?attr/selectableItemBackground">
1111

12-
<android.support.v7.widget.AppCompatImageView
12+
<androidx.appcompat.widget.AppCompatImageView
1313
android:layout_width="@dimen/hype_plugin_icon_size"
1414
android:layout_height="@dimen/hype_plugin_icon_size"
1515
android:layout_marginRight="28dp"

hyperion-build-config/build.gradle

+5-5
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ android {
1313
versionCode buildVersionCode()
1414
versionName version
1515

16-
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
16+
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
1717
}
1818

1919
lintOptions {
@@ -26,11 +26,11 @@ android {
2626
dependencies {
2727
testImplementation "junit:junit:4.12"
2828
api project(':hyperion-plugin')
29-
implementation "com.android.support:appcompat-v7:${project.versionSupportLibrary}"
29+
implementation "androidx.appcompat:appcompat:${project.versionAppCompat}"
3030
annotationProcessor "com.google.auto.service:auto-service:${project.versionAutoService}"
31-
implementation "com.android.support:recyclerview-v7:${project.versionSupportLibrary}"
32-
implementation "com.android.support:design:${project.versionSupportLibrary}"
33-
implementation 'com.android.support.constraint:constraint-layout:1.1.2'
31+
implementation "androidx.recyclerview:recyclerview:${project.versionRecyclerview}"
32+
implementation "com.google.android.material:material:${project.versionMaterial}"
33+
implementation "androidx.constraintlayout:constraintlayout:${project.versionConstraintLayout}"
3434
}
3535

3636
apply from: '../publish.gradle'

hyperion-build-config/src/main/java/com/willowtreeapps/hyperion/buildconfig/list/BuildConfigListActivity.java

-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
import java.util.Arrays;
1919
import java.util.LinkedList;
2020
import java.util.List;
21-
import java.util.Objects;
2221

2322
@HyperionIgnore
2423
public class BuildConfigListActivity extends AppCompatActivity {
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<?xml version="1.0" encoding="utf-8"?>
2-
<android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
2+
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
33
xmlns:app="http://schemas.android.com/apk/res-auto"
44
xmlns:tools="http://schemas.android.com/tools"
55
android:layout_width="match_parent"
@@ -8,25 +8,25 @@
88
android:focusableInTouchMode="true"
99
tools:context=".list.BuildConfigListActivity">
1010

11-
<android.support.design.widget.AppBarLayout
11+
<com.google.android.material.appbar.AppBarLayout
1212
android:layout_width="match_parent"
1313
android:layout_height="wrap_content">
1414

15-
<android.support.v7.widget.Toolbar
15+
<androidx.appcompat.widget.Toolbar
1616
android:id="@+id/tmb_toolbar"
1717
android:layout_width="match_parent"
1818
android:layout_height="?attr/actionBarSize"
1919
android:theme="@style/hbc_ActionBar"
2020
app:popupTheme="@style/ThemeOverlay.AppCompat.Light"
2121
app:title="@string/hbc_plugin_name" />
2222

23-
</android.support.design.widget.AppBarLayout>
23+
</com.google.android.material.appbar.AppBarLayout>
2424

25-
<android.support.v7.widget.RecyclerView
25+
<androidx.recyclerview.widget.RecyclerView
2626
android:id="@+id/hbc_recycler"
2727
android:layout_width="match_parent"
2828
android:layout_height="match_parent"
2929
app:layout_behavior="@string/appbar_scrolling_view_behavior"
30-
app:layoutManager="android.support.v7.widget.LinearLayoutManager" />
30+
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" />
3131

32-
</android.support.design.widget.CoordinatorLayout>
32+
</androidx.coordinatorlayout.widget.CoordinatorLayout>

hyperion-build-config/src/main/res/layout/hbc_item_plugin.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
android:gravity="center_vertical"
1111
android:background="?attr/selectableItemBackground">
1212

13-
<android.support.v7.widget.AppCompatImageView
13+
<androidx.appcompat.widget.AppCompatImageView
1414
android:layout_width="@dimen/hype_plugin_icon_size"
1515
android:layout_height="@dimen/hype_plugin_icon_size"
1616
android:layout_marginRight="28dp"

hyperion-build-config/src/main/res/layout/hbc_value_row.xml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<?xml version="1.0" encoding="utf-8"?>
2-
<android.support.constraint.ConstraintLayout
2+
<androidx.constraintlayout.widget.ConstraintLayout
33
xmlns:android="http://schemas.android.com/apk/res/android"
44
xmlns:app="http://schemas.android.com/apk/res-auto"
55
xmlns:tools="http://schemas.android.com/tools"
@@ -40,4 +40,4 @@
4040
app:layout_constraintTop_toBottomOf="@+id/hbc_name"
4141
tools:text="Value"/>
4242

43-
</android.support.constraint.ConstraintLayout>
43+
</androidx.constraintlayout.widget.ConstraintLayout>

hyperion-core-no-op/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ android {
1313
versionCode buildVersionCode()
1414
versionName version
1515

16-
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
16+
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
1717
}
1818

1919
lintOptions {

hyperion-core/build.gradle

+3-3
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ android {
1414
versionName version
1515
consumerProguardFiles 'consumer-proguard-rules.pro'
1616

17-
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
17+
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
1818
}
1919

2020
lintOptions {
@@ -28,8 +28,8 @@ dependencies {
2828
implementation(project(':hyperion-plugin')) {
2929
transitive = true
3030
}
31-
implementation "com.android.support:appcompat-v7:${project.versionSupportLibrary}"
32-
implementation "com.android.support:recyclerview-v7:${project.versionSupportLibrary}"
31+
implementation "androidx.appcompat:appcompat:${project.versionAppCompat}"
32+
implementation "androidx.recyclerview:recyclerview:${project.versionRecyclerview}"
3333
implementation "com.google.dagger:dagger:${project.versionDagger}"
3434
annotationProcessor "com.google.dagger:dagger-compiler:${project.versionDagger}"
3535
}

hyperion-crash/build.gradle

+3-3
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ android {
1313
versionCode buildVersionCode()
1414
versionName version
1515

16-
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
16+
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
1717
}
1818

1919
lintOptions {
@@ -25,8 +25,8 @@ android {
2525

2626
dependencies {
2727
api project(':hyperion-plugin')
28-
implementation "com.android.support:appcompat-v7:${project.versionSupportLibrary}"
29-
implementation "com.android.support:design:${project.versionSupportLibrary}"
28+
implementation "androidx.appcompat:appcompat:${project.versionAppCompat}"
29+
implementation "com.google.android.material:material:${project.versionMaterial}"
3030
annotationProcessor "com.google.auto.service:auto-service:${project.versionAutoService}"
3131
}
3232

hyperion-crash/src/main/res/layout/hc_activity.xml

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
<?xml version="1.0" encoding="utf-8"?>
2-
<android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
2+
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
33
android:layout_width="match_parent"
44
android:layout_height="match_parent"
55
xmlns:tools="http://schemas.android.com/tools">
66

7-
<android.support.design.widget.FloatingActionButton
7+
<com.google.android.material.floatingactionbutton.FloatingActionButton
88
android:id="@+id/fab"
99
android:layout_width="wrap_content"
1010
android:layout_height="wrap_content"
@@ -46,4 +46,4 @@
4646

4747
</ScrollView>
4848

49-
</android.support.design.widget.CoordinatorLayout>
49+
</androidx.coordinatorlayout.widget.CoordinatorLayout>

hyperion-disk/build.gradle

+3-3
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ android {
1313
versionCode buildVersionCode()
1414
versionName version
1515

16-
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
16+
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
1717
}
1818

1919
lintOptions {
@@ -25,8 +25,8 @@ android {
2525

2626
dependencies {
2727
api project(':hyperion-plugin')
28-
implementation "com.android.support:appcompat-v7:${project.versionSupportLibrary}"
29-
implementation "com.android.support:recyclerview-v7:${project.versionSupportLibrary}"
28+
implementation "androidx.appcompat:appcompat:${project.versionAppCompat}"
29+
implementation "androidx.recyclerview:recyclerview:${project.versionRecyclerview}"
3030
annotationProcessor "com.google.auto.service:auto-service:${project.versionAutoService}"
3131
}
3232

hyperion-disk/src/main/res/layout/hd_item_plugin.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
android:gravity="center_vertical"
1111
android:background="?attr/selectableItemBackground">
1212

13-
<android.support.v7.widget.AppCompatImageView
13+
<androidx.appcompat.widget.AppCompatImageView
1414
android:layout_width="@dimen/hype_plugin_icon_size"
1515
android:layout_height="@dimen/hype_plugin_icon_size"
1616
android:layout_marginRight="28dp"

hyperion-disk/src/main/res/layout/hd_view_file_explorer.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
android:layout_height="match_parent"
66
tools:parentTag="android.widget.FrameLayout">
77

8-
<android.support.v7.widget.RecyclerView
8+
<androidx.recyclerview.widget.RecyclerView
99
android:id="@+id/recycler"
1010
android:layout_width="match_parent"
1111
android:layout_height="match_parent"/>

hyperion-geiger-counter/build.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ android {
1313
versionCode buildVersionCode()
1414
versionName version
1515

16-
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
16+
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
1717
}
1818

1919
lintOptions {
@@ -25,7 +25,7 @@ android {
2525

2626
dependencies {
2727
api project(':hyperion-plugin')
28-
implementation "com.android.support:appcompat-v7:${project.versionSupportLibrary}"
28+
implementation "androidx.appcompat:appcompat:${project.versionAppCompat}"
2929
annotationProcessor "com.google.auto.service:auto-service:${project.versionAutoService}"
3030
}
3131

hyperion-geiger-counter/src/main/res/layout/hgc_item_plugin.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
android:gravity="center_vertical"
1414
android:background="?attr/selectableItemBackground">
1515

16-
<android.support.v7.widget.AppCompatImageView
16+
<androidx.appcompat.widget.AppCompatImageView
1717
android:layout_width="@dimen/hype_plugin_icon_size"
1818
android:layout_height="@dimen/hype_plugin_icon_size"
1919
android:layout_marginRight="28dp"

hyperion-location/build.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ android {
1313
versionCode buildVersionCode()
1414
versionName version
1515

16-
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
16+
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
1717
}
1818

1919
lintOptions {
@@ -25,6 +25,6 @@ android {
2525

2626
dependencies {
2727
compileOnly project(':hyperion-plugin')
28-
implementation "com.android.support:appcompat-v7:${project.versionSupportLibrary}"
28+
implementation "androidx.appcompat:appcompat:${project.versionAppCompat}"
2929
annotationProcessor "com.google.auto.service:auto-service:${project.versionAutoService}"
3030
}

0 commit comments

Comments
 (0)