Skip to content

Commit

Permalink
Merge pull request #110 from Omega-R/feature/android-x
Browse files Browse the repository at this point in the history
Migration to AndroidX
  • Loading branch information
anton-knyazev authored Jan 11, 2019
2 parents 8ce7415 + 592525b commit 918ff93
Show file tree
Hide file tree
Showing 56 changed files with 138 additions and 151 deletions.
10 changes: 5 additions & 5 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ android {
targetSdkVersion 28
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
Expand All @@ -21,11 +21,11 @@ android {
}

dependencies {
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
implementation 'androidx.constraintlayout:constraintlayout:2.0.0-alpha3'
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'com.android.support:appcompat-v7:' + rootProject.supportLibVersion
implementation 'com.android.support:support-v4:' + rootProject.supportLibVersion
implementation 'com.android.support:design:' + rootProject.supportLibVersion
implementation 'androidx.appcompat:appcompat:1.1.0-alpha01'
implementation 'androidx.legacy:legacy-support-v4:1.0.0'
implementation 'com.google.android.material:material:1.1.0-alpha02'

implementation 'com.github.Omega-R.OmegaIntentBuilder:core:' + rootProject.omegaIntentBuilder
implementation 'com.github.Omega-R.OmegaIntentBuilder:annotations:' + rootProject.omegaIntentBuilder
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package com.omega_r.omegarecyclerview;

import android.content.Context;
import android.support.test.InstrumentationRegistry;
import android.support.test.runner.AndroidJUnit4;
import androidx.test.InstrumentationRegistry;
import androidx.test.runner.AndroidJUnit4;

import org.junit.Test;
import org.junit.runner.RunWith;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
package com.omega_r.omegarecyclerview.ListAdapterExample;

import android.support.v7.app.AppCompatActivity;
import androidx.appcompat.app.AppCompatActivity;
import android.os.Bundle;
import android.support.v7.widget.RecyclerView;
import androidx.recyclerview.widget.RecyclerView;
import android.widget.Toast;

import com.omega_r.libs.omegarecyclerview.BaseListAdapter;
import com.omega_r.omegarecyclerview.R;

import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;

import omega.com.annotations.OmegaActivity;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.omega_r.omegarecyclerview;

import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import androidx.appcompat.app.AppCompatActivity;
import android.view.View;

import com.omega_r.libs.omegaintentbuilder.AppOmegaIntentBuilder;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.omega_r.omegarecyclerview.expandable_example;

import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import androidx.appcompat.app.AppCompatActivity;
import android.view.View;

import com.omega_r.libs.omegaintentbuilder.AppOmegaIntentBuilder;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package com.omega_r.omegarecyclerview.expandable_example.core;

import android.os.Bundle;
import android.support.annotation.LayoutRes;
import android.support.v7.app.AppCompatActivity;
import androidx.annotation.LayoutRes;
import androidx.appcompat.app.AppCompatActivity;
import android.widget.CompoundButton;
import android.widget.RadioButton;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,10 @@
package com.omega_r.omegarecyclerview.expandable_example.core;

import android.support.annotation.NonNull;
import androidx.annotation.NonNull;
import android.view.ViewGroup;
import android.widget.TextView;
import android.widget.Toast;

import com.omega_r.libs.omegarecyclerview.OmegaRecyclerView;
import com.omega_r.libs.omegarecyclerview.expandable_recycler_view.OmegaExpandableRecyclerView;
import com.omega_r.libs.omegarecyclerview.sticky_header.StickyHeaderAdapter;
import com.omega_r.omegarecyclerview.R;

public class ExpandableAdapter extends OmegaExpandableRecyclerView.Adapter<QuoteGlobalInfo, String> {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.omega_r.omegarecyclerview.expandable_example.core;

import android.support.annotation.Nullable;
import androidx.annotation.Nullable;

import com.omega_r.libs.omegarecyclerview.expandable_recycler_view.data.GroupProvider;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.omega_r.omegarecyclerview.expandable_example.support_sticky;

import android.support.annotation.NonNull;
import androidx.annotation.NonNull;
import android.view.ViewGroup;
import android.widget.TextView;
import android.widget.Toast;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.omega_r.omegarecyclerview.pagination_example;

import android.support.annotation.DrawableRes;
import androidx.annotation.DrawableRes;

import com.omega_r.omegarecyclerview.R;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.omega_r.omegarecyclerview.pagination_example;

import android.support.annotation.Nullable;
import androidx.annotation.Nullable;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import android.os.Bundle;
import android.os.Handler;
import android.support.v7.app.AppCompatActivity;
import androidx.appcompat.app.AppCompatActivity;

import com.omega_r.libs.omegarecyclerview.OmegaRecyclerView;
import com.omega_r.libs.omegarecyclerview.pagination.OnPageRequestListener;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.omega_r.omegarecyclerview.sections_example;

import android.support.v7.app.AppCompatActivity;
import androidx.appcompat.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import android.widget.Toast;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.omega_r.omegarecyclerview.sticky_header_example;

import android.support.v7.app.AppCompatActivity;
import androidx.appcompat.app.AppCompatActivity;
import android.os.Bundle;

import com.omega_r.libs.omegarecyclerview.OmegaRecyclerView;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,11 @@
package com.omega_r.omegarecyclerview.swipe_menu_example;

import android.support.v7.app.AppCompatActivity;
import androidx.appcompat.app.AppCompatActivity;
import android.os.Bundle;
import android.support.v7.widget.LinearLayoutManager;

import com.omega_r.libs.omegarecyclerview.OmegaRecyclerView;
import com.omega_r.omegarecyclerview.R;

import java.util.List;

import omega.com.annotations.OmegaActivity;

@OmegaActivity
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@

import android.annotation.SuppressLint;
import android.content.Context;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import android.support.v7.app.AppCompatActivity;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.appcompat.app.AppCompatActivity;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
Expand Down
3 changes: 1 addition & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,7 @@ task clean(type: Delete) {

ext {
buildToolsVersion = "28.0.3"
supportLibVersion = "28.0.0"
espressoVersion = "3.0.1"
junitVersion = "4.12"
omegaIntentBuilder = "1.1.2"
omegaIntentBuilder = "1.1.5"
}
2 changes: 2 additions & 0 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@

# 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.
Expand Down
6 changes: 3 additions & 3 deletions omegarecyclerviewlibs/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ android {
versionCode 1
versionName "1.0"

testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"

}
buildTypes {
Expand All @@ -25,7 +25,7 @@ android {

dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation "com.android.support:appcompat-v7:$rootProject.supportLibVersion"
implementation "com.android.support:design:$rootProject.supportLibVersion"
implementation 'androidx.appcompat:appcompat:1.1.0-alpha01'
implementation 'com.google.android.material:material:1.1.0-alpha02'

}
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
package android.support.v7.widget;
package androidx.recyclerview.widget;

import android.content.Context;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import android.util.AttributeSet;
import android.view.View;

import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

public class ExpandedRecyclerView extends RecyclerView {
public static final int STEP_START = 1;
public static final int STEP_LAYOUT = 2;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.omega_r.libs.omegarecyclerview;


import android.support.v7.widget.RecyclerView;
import androidx.recyclerview.widget.RecyclerView;

import java.util.Arrays;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
package com.omega_r.libs.omegarecyclerview;

import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import android.view.View;
import android.view.ViewGroup;

import java.util.ArrayList;
import java.util.Collections;
import java.util.List;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.omega_r.libs.omegarecyclerview;

import android.support.annotation.LayoutRes;
import androidx.annotation.LayoutRes;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,16 @@
import android.graphics.Color;
import android.graphics.drawable.ColorDrawable;
import android.graphics.drawable.Drawable;
import android.support.annotation.ColorInt;
import android.support.annotation.ColorRes;
import android.support.annotation.IdRes;
import android.support.annotation.LayoutRes;
import android.support.annotation.Nullable;
import android.support.annotation.StringRes;
import android.support.v4.content.ContextCompat;
import android.support.v7.widget.ExpandedRecyclerView;
import android.support.v7.widget.LinearLayoutManager;
import android.support.v7.widget.RecyclerView;
import androidx.annotation.ColorInt;
import androidx.annotation.ColorRes;
import androidx.annotation.IdRes;
import androidx.annotation.LayoutRes;
import androidx.annotation.Nullable;
import androidx.annotation.StringRes;
import androidx.core.content.ContextCompat;
import androidx.recyclerview.widget.ExpandedRecyclerView;
import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
import android.util.AttributeSet;
import android.view.LayoutInflater;
import android.view.MotionEvent;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
import android.graphics.Canvas;
import android.graphics.Path;
import android.graphics.RectF;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import android.support.v7.widget.RecyclerView;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.recyclerview.widget.RecyclerView;
import android.view.View;
import android.view.ViewGroup;
import android.view.ViewParent;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

import android.graphics.Canvas;
import android.graphics.Rect;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import android.support.v4.util.Pair;
import android.support.v7.widget.RecyclerView;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.core.util.Pair;
import androidx.recyclerview.widget.RecyclerView;
import android.util.SparseArray;
import android.view.View;
import android.view.ViewGroup;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@
import android.os.Bundle;
import android.os.Parcelable;
import android.os.SystemClock;
import android.support.annotation.CallSuper;
import android.support.annotation.DrawableRes;
import android.support.annotation.IntDef;
import android.support.annotation.LayoutRes;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import android.support.v7.widget.DefaultItemAnimator;
import android.support.v7.widget.RecyclerView;
import androidx.annotation.CallSuper;
import androidx.annotation.DrawableRes;
import androidx.annotation.IntDef;
import androidx.annotation.LayoutRes;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.recyclerview.widget.DefaultItemAnimator;
import androidx.recyclerview.widget.RecyclerView;
import android.util.AttributeSet;
import android.util.Log;
import android.view.LayoutInflater;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package com.omega_r.libs.omegarecyclerview.expandable_recycler_view.animation;

import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import android.support.v7.widget.RecyclerView;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.recyclerview.widget.RecyclerView;

import com.omega_r.libs.omegarecyclerview.expandable_recycler_view.OmegaExpandableRecyclerView;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@

import android.animation.Animator;
import android.animation.AnimatorListenerAdapter;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import android.support.v4.view.ViewCompat;
import android.support.v7.widget.RecyclerView;
import android.support.v7.widget.RecyclerView.ViewHolder;
import android.support.v7.widget.SimpleItemAnimator;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.core.view.ViewCompat;
import androidx.recyclerview.widget.RecyclerView;
import androidx.recyclerview.widget.RecyclerView.ViewHolder;
import androidx.recyclerview.widget.SimpleItemAnimator;
import android.view.View;
import android.view.ViewPropertyAnimator;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import android.animation.ValueAnimator;
import android.annotation.TargetApi;
import android.os.Build;
import android.support.v7.widget.RecyclerView;
import androidx.recyclerview.widget.RecyclerView;
import android.view.View;
import android.view.ViewPropertyAnimator;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package com.omega_r.libs.omegarecyclerview.expandable_recycler_view.data;


import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

import java.util.Arrays;
import java.util.List;
Expand Down
Loading

0 comments on commit 918ff93

Please sign in to comment.