|
|
@ -154,14 +154,6 @@ public class NotificationsAdapter extends RecyclerView.Adapter { |
|
|
|
public void onBindViewHolder(@NonNull RecyclerView.ViewHolder viewHolder, int position, @NonNull List payloads) { |
|
|
|
public void onBindViewHolder(@NonNull RecyclerView.ViewHolder viewHolder, int position, @NonNull List payloads) { |
|
|
|
bindViewHolder(viewHolder, position, payloads); |
|
|
|
bindViewHolder(viewHolder, position, payloads); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
private void fixupHiddenUsers(StatusViewData.Concrete status, View v) { |
|
|
|
|
|
|
|
if(status.isUserMuted()) { |
|
|
|
|
|
|
|
v.setVisibility(View.GONE); |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
v.setVisibility(View.VISIBLE); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private void bindViewHolder(@NonNull RecyclerView.ViewHolder viewHolder, int position, @Nullable List payloads) { |
|
|
|
private void bindViewHolder(@NonNull RecyclerView.ViewHolder viewHolder, int position, @Nullable List payloads) { |
|
|
|
Object payloadForHolder = payloads != null && !payloads.isEmpty() ? payloads.get(0) : null; |
|
|
|
Object payloadForHolder = payloads != null && !payloads.isEmpty() ? payloads.get(0) : null; |
|
|
@ -188,7 +180,6 @@ public class NotificationsAdapter extends RecyclerView.Adapter { |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
holder.hideStatusInfo(); |
|
|
|
holder.hideStatusInfo(); |
|
|
|
} |
|
|
|
} |
|
|
|
fixupHiddenUsers(status, holder.itemView); |
|
|
|
|
|
|
|
break; |
|
|
|
break; |
|
|
|
} |
|
|
|
} |
|
|
|
case VIEW_TYPE_MUTED_STATUS: { |
|
|
|
case VIEW_TYPE_MUTED_STATUS: { |
|
|
@ -196,7 +187,6 @@ public class NotificationsAdapter extends RecyclerView.Adapter { |
|
|
|
StatusViewData.Concrete status = concreteNotificaton.getStatusViewData(); |
|
|
|
StatusViewData.Concrete status = concreteNotificaton.getStatusViewData(); |
|
|
|
holder.setupWithStatus(status, |
|
|
|
holder.setupWithStatus(status, |
|
|
|
statusListener, statusDisplayOptions, payloadForHolder); |
|
|
|
statusListener, statusDisplayOptions, payloadForHolder); |
|
|
|
fixupHiddenUsers(status, holder.itemView); |
|
|
|
|
|
|
|
break; |
|
|
|
break; |
|
|
|
} |
|
|
|
} |
|
|
|
case VIEW_TYPE_STATUS_NOTIFICATION: { |
|
|
|
case VIEW_TYPE_STATUS_NOTIFICATION: { |
|
|
|