Fix setting text to CW button in fav/reblog notification. Fix #1641 (#1642)

This is a regression from e1e9268ef5
main
Ivan Kupalov 5 years ago committed by Konrad Pozniak
parent bd66a9e6ae
commit 701e1dafe3
  1. 5
      app/src/main/java/com/keylesspalace/tusky/adapter/NotificationsAdapter.java

@ -479,6 +479,11 @@ public class NotificationsAdapter extends RecyclerView.Adapter {
boolean hasSpoiler = !TextUtils.isEmpty(statusViewData.getSpoilerText());
contentWarningDescriptionTextView.setVisibility(hasSpoiler ? View.VISIBLE : View.GONE);
contentWarningButton.setVisibility(hasSpoiler ? View.VISIBLE : View.GONE);
if (statusViewData.isExpanded()) {
contentWarningButton.setText(R.string.status_content_warning_show_less);
} else {
contentWarningButton.setText(R.string.status_content_warning_show_more);
}
contentWarningButton.setOnClickListener(view -> {
if (getAdapterPosition() != RecyclerView.NO_POSITION) {

Loading…
Cancel
Save