mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-11 18:29:05 +01:00
It now uses conversation bubbles in alternating colors and vector drawables to indicate message state. The conversation bubbles have been taken from Telegram and can be replaced by a UX designer later. This commit also addresses #9, because message text can now be selected and copied. This is done by using android:textIsSelectable="true" which only works for API level 11 or higher. If we want copy and paste on lower API levels, additional measures have to be implemented.
42 lines
1.2 KiB
XML
42 lines
1.2 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<LinearLayout
|
|
xmlns:android="http://schemas.android.com/apk/res/android"
|
|
xmlns:tools="http://schemas.android.com/tools"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:orientation="vertical"
|
|
android:paddingRight="@dimen/margin_medium"
|
|
android:paddingEnd="@dimen/margin_medium"
|
|
android:paddingTop="@dimen/margin_small"
|
|
android:paddingBottom="@dimen/margin_small">
|
|
|
|
<RelativeLayout
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:layout_gravity="left|start"
|
|
android:background="@drawable/msg_in"
|
|
android:paddingLeft="17dp"
|
|
android:paddingTop="5dp"
|
|
android:paddingRight="7dp"
|
|
android:paddingBottom="5dp">
|
|
|
|
<TextView
|
|
android:id="@+id/msgBody"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:minWidth="80dp"
|
|
android:textIsSelectable="true"
|
|
tools:text="Short message"/>
|
|
|
|
<TextView
|
|
android:id="@+id/msgTime"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:textSize="10sp"
|
|
android:textColor="@color/private_message_date"
|
|
android:layout_below="@+id/msgBody"
|
|
tools:text="Dec 24, 13:37"/>
|
|
|
|
</RelativeLayout>
|
|
|
|
</LinearLayout> |