Conversation names and members number are displayed in the list

This commit is contained in:
Pierre
2017-12-10 18:25:06 +01:00
parent c92587cf26
commit 9b08184b1f
7 changed files with 110 additions and 7 deletions

View File

@ -1,14 +1,65 @@
<?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="match_parent"
xmlns:tools="http://schemas.android.com/tools"
android:orientation="vertical">
android:orientation="horizontal"
android:paddingBottom="8dp"
android:paddingEnd="8dp"
android:paddingStart="8dp"
android:paddingTop="8dp">
<TextView
<LinearLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:orientation="vertical">
<!-- Conversation name -->
<TextView
android:id="@+id/fragment_conversationslist_item_name"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:text="Conversation name"/>
android:layout_height="wrap_content"
android:textSize="16sp"
android:textStyle="bold"
tools:text="Conversation name" />
<!-- Number of members -->
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal">
<ImageView
android:layout_width="@dimen/fragment_conversations_list_icon_width"
android:layout_height="@dimen/fragment_conversations_list_icon_height"
android:src="@drawable/ic_menu_allfriends" />
<TextView
android:id="@+id/fragment_conversationslist_item_number_members"
android:layout_width="wrap_content"
android:layout_height="match_parent"
tools:text="x Members" />
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content">
<ImageView
android:layout_width="@dimen/fragment_conversations_list_icon_width"
android:layout_height="@dimen/fragment_conversations_list_icon_height"
android:src="@android:drawable/ic_menu_my_calendar"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
tools:text="1min" />
</LinearLayout>
</LinearLayout>

View File

@ -6,4 +6,6 @@
<color name="holo_green_dark">#ff669900</color>
<color name="darker_gray">#aaa</color>
<color name="darker_darker_gray">#5b5b5b</color>
<color name="dark_blue">#303F9F</color>
</resources>

View File

@ -3,5 +3,7 @@
<dimen name="account_image_default_width">64dp</dimen>
<dimen name="account_image_default_height">64dp</dimen>
<!-- Dimensions for the conversation list -->
<dimen name="fragment_conversations_list_icon_width">20dp</dimen>
<dimen name="fragment_conversations_list_icon_height">20dp</dimen>
</resources>

View File

@ -34,4 +34,14 @@
<string name="popup_respond_friendship_request_title">Respond to the request</string>
<string name="popup_respond_friendship_request_message">Do you want to accept or deny this friendship request ?</string>
<string name="fragment_conversationslist_err_get_list">An error occurred while retrieving conversations list !</string>
<string name="conversations_members_number">%d members</string>
<string name="date_now">now</string>
<string name="date_seconds">seconds</string>
<string name="date_minutes">minutes</string>
<string name="date_min">min</string>
<string name="date_sec">sec</string>
<string name="date_h">h</string>
<string name="date_m">m</string>
<string name="date_s">s</string>
<string name="date_hours">date_hours</string>
</resources>