diff --git a/src/main/java/eu/siacs/conversations/ui/adapter/MessageAdapter.java b/src/main/java/eu/siacs/conversations/ui/adapter/MessageAdapter.java index ffab2baf4..e0cd74da1 100644 --- a/src/main/java/eu/siacs/conversations/ui/adapter/MessageAdapter.java +++ b/src/main/java/eu/siacs/conversations/ui/adapter/MessageAdapter.java @@ -771,10 +771,12 @@ public class MessageAdapter extends ArrayAdapter { public void onClick(View v) { if (isTextViewClicked[0]) { //This will shrink textview to 6 lines if it is expanded. + viewHolder.showMore().setText(R.string.show_more); viewHolder.messageBody().setMaxLines(6); isTextViewClicked[0] = false; } else { //This will expand the textview if it is of 6 lines + viewHolder.showMore().setText(R.string.show_less); viewHolder.messageBody().setMaxLines(Integer.MAX_VALUE); isTextViewClicked[0] = true; } diff --git a/src/main/res/layout/item_message_content.xml b/src/main/res/layout/item_message_content.xml index 55772534b..5619c585b 100644 --- a/src/main/res/layout/item_message_content.xml +++ b/src/main/res/layout/item_message_content.xml @@ -75,7 +75,7 @@ android:layout_height="wrap_content" android:layout_below="@+id/message_body" android:layout_marginHorizontal="10dp" - android:text="... more / less" + android:text="@string/show_more" android:textColor="?colorPrimary" android:textStyle="bold" android:textAppearance="?textAppearanceBodyLarge"