Files
arcanechat-android/res/layout/account_selection_list_item.xml
T
2021-11-06 22:07:20 +01:00

105 lines
4.4 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<org.thoughtcrime.securesms.accounts.AccountSelectionListItem
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="60dp"
android:orientation="horizontal"
android:gravity="center_vertical"
android:focusable="true"
android:background="?attr/conversation_list_item_background"
android:paddingLeft="16dp"
android:paddingStart="16dp"
android:paddingRight="10dp"
android:paddingEnd="10dp">
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="45dp"
android:layout_height="50dp">
<org.thoughtcrime.securesms.components.AvatarImageView
android:id="@+id/contact_photo_image"
android:layout_width="40dp"
android:layout_height="40dp"
android:foreground="@drawable/contact_photo_background"
android:cropToPadding="true"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
tools:src="@color/blue_600"
android:contentDescription="@null" />
<ImageView
android:id="@+id/checkbox"
android:layout_width="20dp"
android:layout_height="20dp"
android:layout_marginStart="22dp"
android:layout_marginTop="22dp"
app:layout_constraintStart_toStartOf="@id/contact_photo_image"
app:layout_constraintTop_toTopOf="@id/contact_photo_image"
android:src="@drawable/ic_circle_checkbox"
android:contentDescription="@null" />
</androidx.constraintlayout.widget.ConstraintLayout>
<LinearLayout android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:layout_marginLeft="11dp"
android:layout_marginStart="11dp"
android:paddingRight="16dp"
android:paddingEnd="16dp"
android:orientation="vertical">
<org.thoughtcrime.securesms.components.emoji.EmojiTextView
android:id="@+id/name"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:drawablePadding="5dp"
android:ellipsize="marquee"
android:singleLine="true"
android:fontFamily="sans-serif"
android:textSize="16sp"
tools:text="Frieeeeeeedrich Nieeeeeeeeeetzsche" />
<!-- Attention: Using android:maxLines="1", if the name is an emoji followed by a
long word and the chat is muted, then the long word is not shown at all
(instead of using `…`). That's why we use android:singleLine="true" -->
<LinearLayout android:id="@+id/addr_container"
android:orientation="horizontal"
android:layout_width="wrap_content"
android:layout_height="wrap_content">
<TextView android:id="@+id/addr"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textDirection="ltr"
android:singleLine="true"
android:ellipsize="marquee"
android:textAppearance="?android:attr/textAppearanceSmall"
android:textSize="14sp"
android:fontFamily="sans-serif-light"
tools:text="user@example.com" />
</LinearLayout>
</LinearLayout>
<ImageView android:id="@+id/unread_indicator"
android:layout_width="24dp"
android:layout_height="24dp"/>
<ImageButton
android:id="@+id/delete"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:layout_centerVertical="true"
android:padding="6dp"
android:contentDescription="@string/delete"
android:background="#00ffffff"
android:src="@drawable/ic_delete_white_24dp" />
</org.thoughtcrime.securesms.accounts.AccountSelectionListItem>