From 0f3d7ada2628903d557eb8333bd30ef37c936d5a Mon Sep 17 00:00:00 2001 From: Nikita Ivanov Date: Wed, 5 Feb 2020 17:34:54 +0300 Subject: [PATCH 1/2] migrated to AndroidX --- README.md | 4 +++- animatedtext/build.gradle | 15 ++++++++------- .../com/omega/animatedtext/AnimatedTextView.java | 3 ++- app/build.gradle | 16 ++++++++-------- .../omega/omegaanimatedtext/MainActivity.java | 3 ++- app/src/main/res/layout/activity_main.xml | 4 ++-- build.gradle | 2 +- gradle.properties | 2 ++ gradle/wrapper/gradle-wrapper.properties | 4 ++-- 9 files changed, 30 insertions(+), 23 deletions(-) diff --git a/README.md b/README.md index e843224..a2c6afd 100644 --- a/README.md +++ b/README.md @@ -22,10 +22,12 @@ allprojects { **Step 2.** Add the dependency ``` dependencies { - implementation 'com.github.Omega-R:OmegaAnimatedText:v1.0.0' + implementation 'com.github.Omega-R:OmegaAnimatedText:v2.0.0' } ``` +For Support library the latest version is '1.0.0' + # Usage Start animation: ``` Java diff --git a/animatedtext/build.gradle b/animatedtext/build.gradle index e3a13d8..66eb8f7 100644 --- a/animatedtext/build.gradle +++ b/animatedtext/build.gradle @@ -1,13 +1,13 @@ apply plugin: 'com.android.library' android { - compileSdkVersion 28 + compileSdkVersion 29 defaultConfig { minSdkVersion 15 - targetSdkVersion 28 + targetSdkVersion 29 versionCode 1 - versionName "1.0.0" - testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" + versionName "2.0.0" + testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" } buildTypes { release { @@ -19,7 +19,8 @@ android { dependencies { implementation fileTree(dir: 'libs', include: ['*.jar']) - implementation 'com.android.support:appcompat-v7:28.0.0-rc01' - testImplementation 'junit:junit:4.12' - androidTestImplementation 'com.android.support.test:runner:1.0.2' + implementation 'androidx.appcompat:appcompat:1.1.0' + testImplementation "junit:junit:4.12" + androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0' + androidTestImplementation 'androidx.test.ext:junit:1.1.1' } diff --git a/animatedtext/src/main/java/com/omega/animatedtext/AnimatedTextView.java b/animatedtext/src/main/java/com/omega/animatedtext/AnimatedTextView.java index ed48ea7..f0d7328 100644 --- a/animatedtext/src/main/java/com/omega/animatedtext/AnimatedTextView.java +++ b/animatedtext/src/main/java/com/omega/animatedtext/AnimatedTextView.java @@ -5,9 +5,10 @@ import android.content.Context; import android.graphics.Canvas; import android.graphics.Paint; -import android.support.v7.widget.AppCompatTextView; import android.util.AttributeSet; +import androidx.appcompat.widget.AppCompatTextView; + public class AnimatedTextView extends AppCompatTextView { private float mStrokeScale = 0.0f; diff --git a/app/build.gradle b/app/build.gradle index 84623c8..9490aef 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -1,14 +1,14 @@ apply plugin: 'com.android.application' android { - compileSdkVersion 28 + compileSdkVersion 29 defaultConfig { applicationId "com.omega.omegaanimatedtext" minSdkVersion 15 - targetSdkVersion 28 + targetSdkVersion 29 versionCode 1 versionName "1.0" - testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" + testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" } buildTypes { release { @@ -20,10 +20,10 @@ android { dependencies { implementation fileTree(include: ['*.jar'], dir: 'libs') - implementation 'com.android.support:appcompat-v7:28.0.0-rc01' - implementation 'com.android.support.constraint:constraint-layout:1.1.2' - testImplementation 'junit:junit:4.12' - androidTestImplementation 'com.android.support.test:runner:1.0.2' - androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2' + implementation 'androidx.appcompat:appcompat:1.1.0' + implementation 'androidx.constraintlayout:constraintlayout:1.1.3' + testImplementation "junit:junit:4.12" + androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0' + androidTestImplementation 'androidx.test.ext:junit:1.1.1' implementation project(':animatedtext') } diff --git a/app/src/main/java/com/omega/omegaanimatedtext/MainActivity.java b/app/src/main/java/com/omega/omegaanimatedtext/MainActivity.java index 3613785..7c10be6 100644 --- a/app/src/main/java/com/omega/omegaanimatedtext/MainActivity.java +++ b/app/src/main/java/com/omega/omegaanimatedtext/MainActivity.java @@ -1,9 +1,10 @@ package com.omega.omegaanimatedtext; -import android.support.v7.app.AppCompatActivity; import android.os.Bundle; import android.view.View; +import androidx.appcompat.app.AppCompatActivity; + import com.omega.animatedtext.AnimatedTextView; public class MainActivity extends AppCompatActivity implements View.OnClickListener { diff --git a/app/src/main/res/layout/activity_main.xml b/app/src/main/res/layout/activity_main.xml index a9379b7..4343b37 100644 --- a/app/src/main/res/layout/activity_main.xml +++ b/app/src/main/res/layout/activity_main.xml @@ -1,5 +1,5 @@ - @@ -74,4 +74,4 @@ app:layout_constraintEnd_toStartOf="@+id/fwd_button" app:layout_constraintStart_toStartOf="parent" /> - \ No newline at end of file + \ No newline at end of file diff --git a/build.gradle b/build.gradle index 077cb2f..ded884a 100644 --- a/build.gradle +++ b/build.gradle @@ -7,7 +7,7 @@ buildscript { jcenter() } dependencies { - classpath 'com.android.tools.build:gradle:3.1.4' + classpath 'com.android.tools.build:gradle:3.5.3' // NOTE: Do not place your application dependencies here; they belong diff --git a/gradle.properties b/gradle.properties index 743d692..8de5058 100644 --- a/gradle.properties +++ b/gradle.properties @@ -6,6 +6,8 @@ # http://www.gradle.org/docs/current/userguide/build_environment.html # Specifies the JVM arguments used for the daemon process. # The setting is particularly useful for tweaking memory settings. +android.enableJetifier=true +android.useAndroidX=true org.gradle.jvmargs=-Xmx1536m # When configured, Gradle will run in incubating parallel mode. # This option should only be used with decoupled projects. More details, visit diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index a455372..0edd806 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ -#Wed Aug 15 12:26:22 MSK 2018 +#Wed Feb 05 17:18:53 MSK 2020 distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-4.4-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-5.4.1-all.zip From a0aa40da5f41d6f63d74d4eaedfa5348698bcab7 Mon Sep 17 00:00:00 2001 From: Nikita Ivanov Date: Wed, 5 Feb 2020 17:36:51 +0300 Subject: [PATCH 2/2] updated license --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index a2c6afd..37c16bd 100644 --- a/README.md +++ b/README.md @@ -48,7 +48,7 @@ Both methods returns android.animation.Animator instance so you can make animati ``` The MIT License -Copyright 2018 Omega-R +Copyright 2020 Omega-R Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction,