Skip to content

Commit

Permalink
Migrated To AndroidX
Browse files Browse the repository at this point in the history
  • Loading branch information
TutorialsAndroid committed Jun 9, 2019
1 parent 06bdb9b commit 182a3b0
Show file tree
Hide file tree
Showing 10 changed files with 42 additions and 40 deletions.
4 changes: 3 additions & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,6 @@
# When configured, Gradle will run in incubating parallel mode.
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
# org.gradle.parallel=true
android.enableJetifier=true
android.useAndroidX=true
20 changes: 10 additions & 10 deletions library/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@ apply plugin: 'com.github.dcendents.android-maven'
group='com.github.TutorialsAndroid'

android {
compileSdkVersion 28
compileSdkVersion 29
resourcePrefix 'crash_'

defaultConfig {
minSdkVersion 15
targetSdkVersion 28
versionCode 4
versionName "1.0.19" //renamed library version properly.
targetSdkVersion 29
versionCode 5
versionName "2.0.19" //renamed library version properly.
}
buildTypes {
release {
Expand All @@ -25,10 +25,10 @@ dependencies {
implementation fileTree(include: ['*.jar'], dir: 'libs')

//ANDROID SUPPORT LIBRARIES
implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'com.android.support:support-v4:28.0.0'
implementation 'com.android.support:recyclerview-v7:28.0.0'
implementation 'com.android.support:design:28.0.0'
implementation "com.android.support:preference-v7:28.0.0"
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
implementation 'androidx.appcompat:appcompat:1.0.0'
implementation 'androidx.legacy:legacy-support-v4:1.0.0'
implementation 'androidx.recyclerview:recyclerview:1.0.0'
implementation 'com.google.android.material:material:1.0.0'
implementation 'androidx.preference:preference:1.0.0'
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
}
6 changes: 3 additions & 3 deletions library/src/main/java/com/kinda/crash/CrashActivity.java
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@
import android.content.pm.ResolveInfo;
import android.os.Build;
import android.os.Bundle;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import android.support.annotation.RestrictTo;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.annotation.RestrictTo;
import android.util.Log;

import java.io.PrintWriter;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@
import android.content.res.TypedArray;
import android.os.Build;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v4.content.res.ResourcesCompat;
import android.support.v7.app.AlertDialog;
import android.support.v7.app.AppCompatActivity;
import androidx.annotation.Nullable;
import androidx.core.content.res.ResourcesCompat;
import androidx.appcompat.app.AlertDialog;
import androidx.appcompat.app.AppCompatActivity;
import android.util.TypedValue;
import android.view.View;
import android.view.Window;
Expand Down
8 changes: 4 additions & 4 deletions library/src/main/java/com/kinda/crash/config/CrashConfig.java
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
package com.kinda.crash.config;

import android.app.Activity;
import android.support.annotation.DrawableRes;
import android.support.annotation.IntDef;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import androidx.annotation.DrawableRes;
import androidx.annotation.IntDef;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

import java.io.Serializable;
import java.lang.annotation.Retention;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
import android.content.ContentValues;
import android.database.Cursor;
import android.net.Uri;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

import com.kinda.crash.CrashActivity;

Expand Down
4 changes: 2 additions & 2 deletions library/src/main/res/layout/crash_default_error_activity.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
android:layout_height="match_parent"
android:background="#D50000">

<android.support.v7.widget.CardView
<androidx.cardview.widget.CardView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
Expand Down Expand Up @@ -64,5 +64,5 @@
android:background="#D50000"
android:drawableBottom="@drawable/crash_ic_error"/>
</LinearLayout>
</android.support.v7.widget.CardView>
</androidx.cardview.widget.CardView>
</RelativeLayout>
20 changes: 10 additions & 10 deletions sample/build.gradle
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
apply plugin: 'com.android.application'

android {
compileSdkVersion 28
compileSdkVersion 29

defaultConfig {
applicationId "com.kinda.crash.sample"
minSdkVersion 15
targetSdkVersion 28
versionCode 4
versionName "1.0.19" //renamed library version properly.
targetSdkVersion 29
versionCode 5
versionName "2.0.19" //renamed library version properly.
}
buildTypes {
debug {
Expand All @@ -26,12 +26,12 @@ dependencies {
implementation fileTree(include: ['*.jar'], dir: 'libs')

//ANDROID SUPPORT LIBRARIES
implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'com.android.support:support-v4:28.0.0'
implementation 'com.android.support:recyclerview-v7:28.0.0'
implementation 'com.android.support:design:28.0.0'
implementation "com.android.support:preference-v7:28.0.0"
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
implementation 'androidx.appcompat:appcompat:1.0.0'
implementation 'androidx.legacy:legacy-support-v4:1.0.0'
implementation 'androidx.recyclerview:recyclerview:1.0.0'
implementation 'com.google.android.material:material:1.0.0'
implementation 'androidx.preference:preference:1.0.0'
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'

//CrashX library
implementation project(":library")
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package com.kinda.crash.sample.activity;

import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v7.app.AppCompatActivity;
import androidx.annotation.Nullable;
import androidx.appcompat.app.AppCompatActivity;
import android.view.View;
import android.widget.Button;
import android.widget.TextView;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
import android.annotation.SuppressLint;
import android.os.AsyncTask;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v7.app.AppCompatActivity;
import androidx.annotation.Nullable;
import androidx.appcompat.app.AppCompatActivity;
import android.view.View;
import android.widget.Button;

Expand Down

0 comments on commit 182a3b0

Please sign in to comment.