diff options
author | Christian S <christian@pix-art.de> | 2015-09-26 21:47:55 +0200 |
---|---|---|
committer | Christian S <christian@pix-art.de> | 2015-09-26 21:47:55 +0200 |
commit | a2f93d019aa50725a8fdb4a6186b8f5cdd4f20ba (patch) | |
tree | 1984b082e25669dc2e4a74d544cff90167aa8c8d /src/main | |
parent | cbb5db25234b83337544063adb4e76b3ba3f9674 (diff) |
added blue tick as read indicator
Diffstat (limited to 'src/main')
-rw-r--r-- | src/main/java/eu/siacs/conversations/ui/ConversationFragment.java | 6 | ||||
-rw-r--r-- | src/main/java/eu/siacs/conversations/ui/adapter/MessageAdapter.java | 5 | ||||
-rw-r--r-- | src/main/res/drawable-hdpi/ic_read_indicator.png | bin | 0 -> 490 bytes | |||
-rw-r--r-- | src/main/res/drawable-mdpi/ic_read_indicator.png | bin | 0 -> 373 bytes | |||
-rw-r--r-- | src/main/res/drawable-xhdpi/ic_read_indicator.png | bin | 0 -> 598 bytes | |||
-rw-r--r-- | src/main/res/drawable-xxhdpi/ic_read_indicator.png | bin | 0 -> 826 bytes | |||
-rw-r--r-- | src/main/res/drawable-xxxhdpi/ic_read_indicator.png | bin | 0 -> 1029 bytes | |||
-rw-r--r-- | src/main/res/layout/message_sent.xml | 9 |
8 files changed, 17 insertions, 3 deletions
diff --git a/src/main/java/eu/siacs/conversations/ui/ConversationFragment.java b/src/main/java/eu/siacs/conversations/ui/ConversationFragment.java index 8f12b14ce..a98ccd430 100644 --- a/src/main/java/eu/siacs/conversations/ui/ConversationFragment.java +++ b/src/main/java/eu/siacs/conversations/ui/ConversationFragment.java @@ -1025,9 +1025,9 @@ public class ConversationFragment extends Fragment implements EditMessage.Keyboa return; } else { if (this.messageList.get(i).getStatus() == Message.STATUS_SEND_DISPLAYED) { - this.messageList.add(i + 1, - Message.createStatusMessage(conversation, getString(R.string.contact_has_read_up_to_this_point, conversation.getName()))); - return; +// this.messageList.add(i + 1, +// Message.createStatusMessage(conversation, getString(R.string.contact_has_read_up_to_this_point, conversation.getName()))); +// return; } } } 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 461127506..a15079512 100644 --- a/src/main/java/eu/siacs/conversations/ui/adapter/MessageAdapter.java +++ b/src/main/java/eu/siacs/conversations/ui/adapter/MessageAdapter.java @@ -112,6 +112,7 @@ public class MessageAdapter extends ArrayAdapter<Message> { boolean error = false; if (viewHolder.indicatorReceived != null) { viewHolder.indicatorReceived.setVisibility(View.GONE); + viewHolder.indicatorRead.setVisibility(View.GONE); } boolean multiReceived = message.getConversation().getMode() == Conversation.MODE_MULTI && message.getMergedStatus() <= Message.STATUS_RECEIVED; @@ -149,6 +150,7 @@ public class MessageAdapter extends ArrayAdapter<Message> { case Message.STATUS_SEND_DISPLAYED: if (mIndicateReceived) { viewHolder.indicatorReceived.setVisibility(View.VISIBLE); + viewHolder.indicatorRead.setVisibility(View.VISIBLE); } break; case Message.STATUS_SEND_FAILED: @@ -436,6 +438,8 @@ public class MessageAdapter extends ArrayAdapter<Message> { .findViewById(R.id.message_time); viewHolder.indicatorReceived = (ImageView) view .findViewById(R.id.indicator_received); + viewHolder.indicatorRead = (ImageView) view + .findViewById(R.id.indicator_read); break; case RECEIVED: view = activity.getLayoutInflater().inflate( @@ -648,6 +652,7 @@ public class MessageAdapter extends ArrayAdapter<Message> { protected ImageView image; protected ImageView indicator; protected ImageView indicatorReceived; + protected ImageView indicatorRead; protected TextView time; protected TextView messageBody; protected ImageView contact_picture; diff --git a/src/main/res/drawable-hdpi/ic_read_indicator.png b/src/main/res/drawable-hdpi/ic_read_indicator.png Binary files differnew file mode 100644 index 000000000..b2a502fb1 --- /dev/null +++ b/src/main/res/drawable-hdpi/ic_read_indicator.png diff --git a/src/main/res/drawable-mdpi/ic_read_indicator.png b/src/main/res/drawable-mdpi/ic_read_indicator.png Binary files differnew file mode 100644 index 000000000..5b5c63f5e --- /dev/null +++ b/src/main/res/drawable-mdpi/ic_read_indicator.png diff --git a/src/main/res/drawable-xhdpi/ic_read_indicator.png b/src/main/res/drawable-xhdpi/ic_read_indicator.png Binary files differnew file mode 100644 index 000000000..6adb409e1 --- /dev/null +++ b/src/main/res/drawable-xhdpi/ic_read_indicator.png diff --git a/src/main/res/drawable-xxhdpi/ic_read_indicator.png b/src/main/res/drawable-xxhdpi/ic_read_indicator.png Binary files differnew file mode 100644 index 000000000..8573818e6 --- /dev/null +++ b/src/main/res/drawable-xxhdpi/ic_read_indicator.png diff --git a/src/main/res/drawable-xxxhdpi/ic_read_indicator.png b/src/main/res/drawable-xxxhdpi/ic_read_indicator.png Binary files differnew file mode 100644 index 000000000..8ae6cfb03 --- /dev/null +++ b/src/main/res/drawable-xxxhdpi/ic_read_indicator.png diff --git a/src/main/res/layout/message_sent.xml b/src/main/res/layout/message_sent.xml index d76117d89..1d5cfb062 100644 --- a/src/main/res/layout/message_sent.xml +++ b/src/main/res/layout/message_sent.xml @@ -103,6 +103,15 @@ android:alpha="0.54" android:gravity="center_vertical" android:src="@drawable/ic_received_indicator" /> + <ImageView + android:id="@+id/indicator_read" + android:layout_width="?attr/TextSizeInfo" + android:layout_height="?attr/TextSizeInfo" + android:layout_gravity="center_vertical" + android:alpha="0.54" + android:gravity="center_vertical" + android:src="@drawable/ic_read_indicator" + android:layout_marginLeft="-6sp" /> </LinearLayout> </LinearLayout> </LinearLayout> |