show some suggestions at top of the contact picker screen
This commit is contained in:
parent
e792ff37ab
commit
5a462775fd
7 changed files with 124 additions and 7 deletions
|
|
@ -0,0 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<size
|
||||
android:width="@dimen/activity_margin"
|
||||
android:height="0dp" />
|
||||
</shape>
|
||||
|
|
@ -38,11 +38,39 @@
|
|||
android:background="@color/divider_grey"
|
||||
android:importantForAccessibility="no" />
|
||||
|
||||
<com.simplemobiletools.commons.views.MyTextView
|
||||
android:id="@+id/suggestions_label"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@+id/message_divider_two"
|
||||
android:alpha="0.8"
|
||||
android:padding="@dimen/activity_margin"
|
||||
android:text="@string/suggestions"
|
||||
android:textSize="@dimen/normal_text_size" />
|
||||
|
||||
<HorizontalScrollView
|
||||
android:id="@+id/suggestions_scrollview"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@+id/suggestions_label"
|
||||
android:layout_marginBottom="@dimen/medium_margin"
|
||||
android:overScrollMode="never"
|
||||
android:scrollbars="none">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/suggestions_holder"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:divider="@drawable/linear_layout_horizontal_divider"
|
||||
android:orientation="horizontal"
|
||||
android:showDividers="middle" />
|
||||
</HorizontalScrollView>
|
||||
|
||||
<com.simplemobiletools.commons.views.MyRecyclerView
|
||||
android:id="@+id/suggestions_list"
|
||||
android:id="@+id/contacts_list"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_below="@+id/message_divider_two"
|
||||
android:layout_below="@+id/suggestions_scrollview"
|
||||
android:clipToPadding="false"
|
||||
android:overScrollMode="ifContentScrolls"
|
||||
android:scrollbars="none"
|
||||
|
|
|
|||
31
app/src/main/res/layout/item_suggested_contact.xml
Normal file
31
app/src/main/res/layout/item_suggested_contact.xml
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/suggested_contact_holder"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/suggested_contact_image"
|
||||
android:layout_width="@dimen/bigger_avatar_size"
|
||||
android:layout_height="@dimen/bigger_avatar_size"
|
||||
android:paddingStart="@dimen/tiny_margin"
|
||||
android:paddingEnd="@dimen/tiny_margin"
|
||||
tools:src="@drawable/ic_circle_filled" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/suggested_contact_name"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@+id/suggested_contact_image"
|
||||
android:layout_alignStart="@+id/suggested_contact_image"
|
||||
android:layout_alignEnd="@id/suggested_contact_image"
|
||||
android:ellipsize="end"
|
||||
android:gravity="center_horizontal"
|
||||
android:lines="1"
|
||||
android:paddingTop="@dimen/medium_margin"
|
||||
android:paddingBottom="@dimen/medium_margin"
|
||||
android:textSize="@dimen/normal_text_size"
|
||||
tools:text="John" />
|
||||
|
||||
</RelativeLayout>
|
||||
|
|
@ -2,5 +2,6 @@
|
|||
<resources>
|
||||
<dimen name="notification_large_icon_size">72dp</dimen>
|
||||
<dimen name="avatar_size">40dp</dimen>
|
||||
<dimen name="bigger_avatar_size">64dp</dimen>
|
||||
<dimen name="play_outline_size">36dp</dimen>
|
||||
</resources>
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@
|
|||
<!-- New message -->
|
||||
<string name="create_new_message">Create new message</string>
|
||||
<string name="add_contact_or_number">Add Contact or Number…</string>
|
||||
<string name="suggestions">Suggestions</string>
|
||||
|
||||
<!-- Notifications -->
|
||||
<string name="channel_received_sms">Received SMS</string>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue