mirror of
https://codeberg.org/Bazsalanszky/Infinity-For-Lemmy.git
synced 2024-11-10 20:57:25 +01:00
Fix awarded comment's background color cannot be changed when searching.
This commit is contained in:
parent
67416fa3e4
commit
f7361b9518
@ -397,11 +397,6 @@ public class CommentsRecyclerViewAdapter extends RecyclerView.Adapter<RecyclerVi
|
|||||||
if (holder instanceof CommentViewHolder) {
|
if (holder instanceof CommentViewHolder) {
|
||||||
Comment comment = getCurrentComment(position);
|
Comment comment = getCurrentComment(position);
|
||||||
if (comment != null) {
|
if (comment != null) {
|
||||||
if (position == mSearchCommentIndex) {
|
|
||||||
holder.itemView.setBackgroundColor(Color.parseColor("#03A9F4"));
|
|
||||||
} else {
|
|
||||||
holder.itemView.setBackgroundColor(mCommentBackgroundColor);
|
|
||||||
}
|
|
||||||
if (mIsSingleCommentThreadMode && comment.getId().equals(mSingleCommentId)) {
|
if (mIsSingleCommentThreadMode && comment.getId().equals(mSingleCommentId)) {
|
||||||
holder.itemView.setBackgroundColor(mSingleCommentThreadBackgroundColor);
|
holder.itemView.setBackgroundColor(mSingleCommentThreadBackgroundColor);
|
||||||
} else if (comment.getAwards() != null && !comment.getAwards().equals("")) {
|
} else if (comment.getAwards() != null && !comment.getAwards().equals("")) {
|
||||||
@ -520,6 +515,10 @@ public class CommentsRecyclerViewAdapter extends RecyclerView.Adapter<RecyclerVi
|
|||||||
} else {
|
} else {
|
||||||
((CommentViewHolder) holder).saveButton.setImageResource(R.drawable.ic_bookmark_border_grey_24dp);
|
((CommentViewHolder) holder).saveButton.setImageResource(R.drawable.ic_bookmark_border_grey_24dp);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (position == mSearchCommentIndex) {
|
||||||
|
holder.itemView.setBackgroundColor(Color.parseColor("#03A9F4"));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else if (holder instanceof CommentFullyCollapsedViewHolder) {
|
} else if (holder instanceof CommentFullyCollapsedViewHolder) {
|
||||||
Comment comment = getCurrentComment(position);
|
Comment comment = getCurrentComment(position);
|
||||||
|
@ -12,7 +12,6 @@ import android.graphics.drawable.Drawable;
|
|||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import android.os.Handler;
|
import android.os.Handler;
|
||||||
import android.util.DisplayMetrics;
|
import android.util.DisplayMetrics;
|
||||||
import android.util.Log;
|
|
||||||
import android.view.HapticFeedbackConstants;
|
import android.view.HapticFeedbackConstants;
|
||||||
import android.view.LayoutInflater;
|
import android.view.LayoutInflater;
|
||||||
import android.view.Menu;
|
import android.view.Menu;
|
||||||
|
Loading…
Reference in New Issue
Block a user