mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-16 04:39:54 +01:00
Show timer change notices in private conversations
This commit is contained in:
@@ -1,4 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
||||
<!-- This layout is only used indirectly by cloning and setting its ConstraintSet -->
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
||||
<!-- This layout is only used indirectly by cloning and setting its ConstraintSet -->
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
|
||||
@@ -1,14 +1,19 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/list_item_background_selectable">
|
||||
android:background="@drawable/list_item_background_selectable"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!--
|
||||
We need to wrap the actual layout, because
|
||||
* we want to clone the ConstraintLayout's constraints in the ViewHolder
|
||||
* we want to have a selectable frame around the message bubble
|
||||
We need to wrap the actual layout, because we want to
|
||||
* clone the ConstraintLayout's constraints in the ViewHolder
|
||||
* have a selectable frame around the message bubble
|
||||
* insert a top notice with its own independent width
|
||||
-->
|
||||
|
||||
<include layout="@layout/list_item_conversation_top_notice_in" />
|
||||
|
||||
<include layout="@layout/list_item_conversation_msg_in_content" />
|
||||
|
||||
</FrameLayout>
|
||||
</LinearLayout>
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
||||
<!-- This layout gets wrapped in *_msg_in.xml -->
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
|
||||
@@ -1,10 +1,14 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/list_item_background_selectable">
|
||||
android:background="@drawable/list_item_background_selectable"
|
||||
android:orientation="vertical"
|
||||
android:paddingTop="@dimen/message_bubble_margin">
|
||||
|
||||
<include layout="@layout/list_item_conversation_top_notice_out" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/layout"
|
||||
@@ -98,4 +102,4 @@
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
</FrameLayout>
|
||||
</LinearLayout>
|
||||
@@ -5,8 +5,9 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/list_item_background_selectable"
|
||||
android:orientation="vertical"
|
||||
android:paddingTop="@dimen/message_bubble_margin">
|
||||
android:orientation="vertical">
|
||||
|
||||
<include layout="@layout/list_item_conversation_top_notice_in" />
|
||||
|
||||
<com.vanniktech.emoji.EmojiTextView
|
||||
android:id="@+id/msgText"
|
||||
@@ -15,11 +16,13 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/message_bubble_margin_tail"
|
||||
android:layout_marginLeft="@dimen/message_bubble_margin_tail"
|
||||
android:layout_marginTop="@dimen/message_bubble_margin"
|
||||
android:layout_marginEnd="@dimen/message_bubble_margin_non_tail"
|
||||
android:layout_marginRight="@dimen/message_bubble_margin_non_tail"
|
||||
android:background="@drawable/msg_in_top"
|
||||
android:elevation="@dimen/message_bubble_elevation"
|
||||
tools:text="Short message" />
|
||||
tools:text="Short message"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/layout"
|
||||
|
||||
@@ -8,6 +8,8 @@
|
||||
android:orientation="vertical"
|
||||
android:paddingTop="@dimen/message_bubble_margin">
|
||||
|
||||
<include layout="@layout/list_item_conversation_top_notice_out" />
|
||||
|
||||
<com.vanniktech.emoji.EmojiTextView
|
||||
android:id="@+id/msgText"
|
||||
style="@style/TextMessage"
|
||||
@@ -15,12 +17,14 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/message_bubble_margin_non_tail"
|
||||
android:layout_marginLeft="@dimen/message_bubble_margin_non_tail"
|
||||
android:layout_marginTop="@dimen/message_bubble_margin"
|
||||
android:layout_marginEnd="@dimen/message_bubble_margin_tail"
|
||||
android:layout_marginRight="@dimen/message_bubble_margin_tail"
|
||||
android:background="@drawable/msg_out_top"
|
||||
android:elevation="@dimen/message_bubble_elevation"
|
||||
android:textColor="@color/briar_text_primary_inverse"
|
||||
tools:text="This is a long long long message that spans over several lines.\n\nIt ends here." />
|
||||
tools:text="This is a long long long message that spans over several lines.\n\nIt ends here."
|
||||
tools:visibility="visible" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/layout"
|
||||
|
||||
@@ -5,8 +5,9 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/list_item_background_selectable"
|
||||
android:orientation="vertical"
|
||||
android:paddingTop="@dimen/message_bubble_margin">
|
||||
android:orientation="vertical">
|
||||
|
||||
<include layout="@layout/list_item_conversation_top_notice_in" />
|
||||
|
||||
<com.vanniktech.emoji.EmojiTextView
|
||||
android:id="@+id/msgText"
|
||||
@@ -15,6 +16,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/message_bubble_margin_tail"
|
||||
android:layout_marginLeft="@dimen/message_bubble_margin_tail"
|
||||
android:layout_marginTop="@dimen/message_bubble_margin"
|
||||
android:layout_marginEnd="@dimen/message_bubble_margin_non_tail"
|
||||
android:layout_marginRight="@dimen/message_bubble_margin_non_tail"
|
||||
android:background="@drawable/msg_in_top"
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<com.vanniktech.emoji.EmojiTextView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/topNotice"
|
||||
style="@style/TextMessage.Notice"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/message_bubble_margin_tail"
|
||||
android:layout_marginLeft="@dimen/message_bubble_margin_tail"
|
||||
android:layout_marginTop="@dimen/message_bubble_margin"
|
||||
android:layout_marginEnd="@dimen/message_bubble_margin_non_tail"
|
||||
android:layout_marginRight="@dimen/message_bubble_margin_non_tail"
|
||||
android:layout_marginBottom="@dimen/message_bubble_margin"
|
||||
android:background="@drawable/notice_in"
|
||||
android:elevation="@dimen/message_bubble_elevation"
|
||||
android:paddingBottom="@dimen/message_bubble_padding_top"
|
||||
android:visibility="gone"
|
||||
tools:text="@string/auto_delete_msg_contact_enabled"
|
||||
tools:visibility="visible" />
|
||||
@@ -0,0 +1,21 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<com.vanniktech.emoji.EmojiTextView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/topNotice"
|
||||
style="@style/TextMessage.Notice"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="end|right"
|
||||
android:layout_marginStart="@dimen/message_bubble_margin_non_tail"
|
||||
android:layout_marginLeft="@dimen/message_bubble_margin_non_tail"
|
||||
android:layout_marginEnd="@dimen/message_bubble_margin_tail"
|
||||
android:layout_marginRight="@dimen/message_bubble_margin_tail"
|
||||
android:layout_marginBottom="@dimen/message_bubble_margin"
|
||||
android:background="@drawable/notice_out"
|
||||
android:elevation="@dimen/message_bubble_elevation"
|
||||
android:paddingBottom="@dimen/message_bubble_padding_top"
|
||||
android:textColor="@color/private_message_date_inverse"
|
||||
android:visibility="gone"
|
||||
tools:showIn="@layout/list_item_conversation_msg_out"
|
||||
tools:text="@string/auto_delete_msg_you_enabled"
|
||||
tools:visibility="visible" />
|
||||
Reference in New Issue
Block a user