Twidere-App-Android-Twitter.../twidere/src/main/res/layout/list_item_message_entry.xml

156 lines
6.9 KiB
XML

<?xml version="1.0" encoding="utf-8"?><!--
~ Twidere - Twitter client for Android
~
~ Copyright (C) 2012-2014 Mariotaku Lee <mariotaku.lee@gmail.com>
~
~ This program is free software: you can redistribute it and/or modify
~ it under the terms of the GNU General Public License as published by
~ the Free Software Foundation, either version 3 of the License, or
~ (at your option) any later version.
~
~ This program is distributed in the hope that it will be useful,
~ but WITHOUT ANY WARRANTY; without even the implied warranty of
~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
~ GNU General Public License for more details.
~
~ You should have received a copy of the GNU General Public License
~ along with this program. If not, see <http://www.gnu.org/licenses/>.
-->
<org.mariotaku.twidere.view.ColorLabelRelativeLayout
android:id="@+id/content"
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="?selectableItemBackground"
android:focusable="true"
android:minHeight="?android:listPreferredItemHeight"
android:orientation="horizontal"
android:paddingLeft="@dimen/element_spacing_normal"
android:paddingRight="@dimen/element_spacing_normal"
app:ignorePadding="true"
tools:context=".adapter.MessagesEntriesAdapter"
tools:layout_height="?android:listPreferredItemHeight">
<org.mariotaku.twidere.view.ProfileImageView
android:id="@+id/profileImage"
style="?profileImageStyle"
android:layout_width="@dimen/icon_size_card_list_item"
android:layout_height="@dimen/icon_size_card_list_item"
android:layout_alignParentLeft="true"
android:layout_alignParentStart="true"
android:layout_centerVertical="true"
android:layout_marginBottom="@dimen/element_spacing_small"
android:layout_marginLeft="@dimen/element_spacing_normal"
android:layout_marginRight="@dimen/element_spacing_normal"
android:layout_marginTop="@dimen/element_spacing_small"
android:contentDescription="@string/profile_image"
tools:src="@drawable/ic_profile_image_default_group"/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:layout_toEndOf="@+id/profileImage"
android:layout_toRightOf="@+id/profileImage"
android:gravity="center_vertical"
android:orientation="vertical"
android:paddingBottom="@dimen/element_spacing_normal"
android:paddingEnd="@dimen/element_spacing_normal"
android:paddingLeft="0dp"
android:paddingRight="@dimen/element_spacing_normal"
android:paddingStart="0dp"
android:paddingTop="@dimen/element_spacing_normal">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_vertical"
android:orientation="horizontal">
<org.mariotaku.twidere.view.IconActionView
android:id="@+id/typeIndicator"
android:layout_width="16dp"
android:layout_height="16dp"
android:layout_marginEnd="@dimen/element_spacing_small"
android:layout_marginRight="@dimen/element_spacing_small"
android:layout_weight="0"
android:adjustViewBounds="true"
android:scaleType="centerInside"
android:src="@drawable/ic_message_convertion_type_group"
tools:tint="?android:textColorSecondary"/>
<org.mariotaku.twidere.view.NameView
android:id="@+id/name"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="center_vertical"
app:nv_primaryTextColor="?android:textColorPrimary"
app:nv_primaryTextStyle="bold"
app:nv_secondaryTextColor="?android:textColorSecondary"
app:nv_twoLine="false"/>
<org.mariotaku.twidere.view.IconActionView
android:id="@+id/stateIndicator"
android:layout_width="16dp"
android:layout_height="16dp"
android:layout_marginLeft="@dimen/element_spacing_small"
android:layout_marginStart="@dimen/element_spacing_small"
android:layout_weight="0"
android:adjustViewBounds="true"
android:scaleType="centerInside"
android:src="@drawable/ic_message_type_outgoing"
tools:tint="?android:textColorSecondary"/>
<org.mariotaku.twidere.view.ShortTimeView
android:id="@+id/time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="0"
android:drawablePadding="4dp"
android:gravity="center"
android:maxLines="1"
android:textColor="?android:attr/textColorSecondary"
tools:text="12:00"/>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/element_spacing_small"
android:gravity="center_vertical"
android:minHeight="24dp"
android:orientation="horizontal">
<org.mariotaku.twidere.view.TimelineContentTextView
android:id="@+id/text"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:ellipsize="end"
android:gravity="center_vertical"
android:maxLines="1"
android:textColor="?android:attr/textColorSecondary"
tools:text="@string/sample_status_text"/>
<org.mariotaku.twidere.view.FixedTextView
android:id="@+id/unreadCount"
android:layout_width="wrap_content"
android:layout_height="24dp"
android:layout_marginLeft="@dimen/element_spacing_small"
android:layout_marginStart="@dimen/element_spacing_small"
android:layout_weight="0"
android:background="@drawable/bg_message_unread_indicator"
android:gravity="center"
android:minWidth="24dp"
android:textColor="@android:color/white"
android:textStyle="bold"
tools:text="9"/>
</LinearLayout>
</LinearLayout>
</org.mariotaku.twidere.view.ColorLabelRelativeLayout>