aboutsummaryrefslogtreecommitdiff
path: root/app/src/main
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--app/src/main/java/ml/docilealligator/infinityforreddit/adapters/FollowedUsersRecyclerViewAdapter.java5
-rw-r--r--app/src/main/java/ml/docilealligator/infinityforreddit/adapters/MultiRedditListingRecyclerViewAdapter.java3
-rw-r--r--app/src/main/java/ml/docilealligator/infinityforreddit/adapters/SubscribedSubredditsRecyclerViewAdapter.java2
3 files changed, 6 insertions, 4 deletions
diff --git a/app/src/main/java/ml/docilealligator/infinityforreddit/adapters/FollowedUsersRecyclerViewAdapter.java b/app/src/main/java/ml/docilealligator/infinityforreddit/adapters/FollowedUsersRecyclerViewAdapter.java
index 430371b4..008944e2 100644
--- a/app/src/main/java/ml/docilealligator/infinityforreddit/adapters/FollowedUsersRecyclerViewAdapter.java
+++ b/app/src/main/java/ml/docilealligator/infinityforreddit/adapters/FollowedUsersRecyclerViewAdapter.java
@@ -3,6 +3,7 @@ package ml.docilealligator.infinityforreddit.adapters;
import android.content.Intent;
import android.os.Handler;
import android.view.LayoutInflater;
+import android.view.View;
import android.view.ViewGroup;
import android.widget.Toast;
@@ -177,10 +178,10 @@ public class FollowedUsersRecyclerViewAdapter extends RecyclerView.Adapter<Recyc
@NonNull
@Override
- public String getPopupText(int position) {
+ public CharSequence getPopupText(@NonNull View view, int position) {
switch (getItemViewType(position)) {
case VIEW_TYPE_USER:
- int offset = (mFavoriteSubscribedUserData != null && mFavoriteSubscribedUserData.size() > 0) ?
+ int offset = (mFavoriteSubscribedUserData != null && !mFavoriteSubscribedUserData.isEmpty()) ?
mFavoriteSubscribedUserData.size() + 2 : 0;
return mSubscribedUserData.get(position - offset).getName().substring(0, 1).toUpperCase();
case VIEW_TYPE_FAVORITE_USER:
diff --git a/app/src/main/java/ml/docilealligator/infinityforreddit/adapters/MultiRedditListingRecyclerViewAdapter.java b/app/src/main/java/ml/docilealligator/infinityforreddit/adapters/MultiRedditListingRecyclerViewAdapter.java
index 38d0a938..06da34f8 100644
--- a/app/src/main/java/ml/docilealligator/infinityforreddit/adapters/MultiRedditListingRecyclerViewAdapter.java
+++ b/app/src/main/java/ml/docilealligator/infinityforreddit/adapters/MultiRedditListingRecyclerViewAdapter.java
@@ -2,6 +2,7 @@ package ml.docilealligator.infinityforreddit.adapters;
import android.os.Handler;
import android.view.LayoutInflater;
+import android.view.View;
import android.view.ViewGroup;
import android.widget.Toast;
@@ -354,7 +355,7 @@ public class MultiRedditListingRecyclerViewAdapter extends RecyclerView.Adapter<
@NonNull
@Override
- public String getPopupText(int position) {
+ public String getPopupText(@NonNull View view, int position) {
switch (getItemViewType(position)) {
case VIEW_TYPE_MULTI_REDDIT:
int offset = (mFavoriteMultiReddits != null && mFavoriteMultiReddits.size() > 0) ?
diff --git a/app/src/main/java/ml/docilealligator/infinityforreddit/adapters/SubscribedSubredditsRecyclerViewAdapter.java b/app/src/main/java/ml/docilealligator/infinityforreddit/adapters/SubscribedSubredditsRecyclerViewAdapter.java
index 9b59fcf6..93ad1ca5 100644
--- a/app/src/main/java/ml/docilealligator/infinityforreddit/adapters/SubscribedSubredditsRecyclerViewAdapter.java
+++ b/app/src/main/java/ml/docilealligator/infinityforreddit/adapters/SubscribedSubredditsRecyclerViewAdapter.java
@@ -425,7 +425,7 @@ public class SubscribedSubredditsRecyclerViewAdapter extends RecyclerView.Adapte
@NonNull
@Override
- public String getPopupText(int position) {
+ public CharSequence getPopupText(@NonNull View view, int position) {
switch (getItemViewType(position)) {
case VIEW_TYPE_SUBREDDIT:
if (hasClearSelectionRow && position == 0) {