1
0
mirror of https://github.com/sismics/docs.git synced 2026-02-09 05:41:53 +00:00

Android: Searching

This commit is contained in:
jendib
2014-11-23 00:49:56 +01:00
parent c610364ef7
commit 1773998ca0
16 changed files with 253 additions and 56 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 14 KiB

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

After

Width:  |  Height:  |  Size: 3.6 KiB

View File

@@ -18,12 +18,40 @@
android:layout_height="match_parent"
android:layout_gravity="start"
android:gravity="center"
android:orientation="vertical">
android:orientation="vertical"
android:background="#fff"
android:elevation="5dp">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="#aaa"
android:padding="12dp"
android:orientation="vertical"
android:elevation="4dp">
<TextView
android:id="@+id/usernameTextView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="#fff"
android:fontFamily="sans-serif"/>
<TextView
android:id="@+id/emailTextView"
android:layout_marginTop="8dp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="#fff"
android:fontFamily="sans-serif-light"/>
</LinearLayout>
<ListView
android:id="@+id/drawer_list"
android:layout_weight="1"
android:id="@+id/tagListView"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_height="0dp"
android:choiceMode="singleChoice"
android:divider="@android:color/transparent"
android:dividerHeight="0dp" />

View File

@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<menu xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto">
<item android:id="@+id/action_search"
android:title="@string/action_search"
app:showAsAction="ifRoom"
app:actionViewClass="android.support.v7.widget.SearchView" />
</menu>

View File

@@ -30,5 +30,6 @@
<string name="downloading_file">Downloading file number %1s</string>
<string name="download_document">Download all files</string>
<string name="downloading_document">Downloading document</string>
<string name="action_search">Search documents</string>
</resources>

View File

@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<searchable xmlns:android="http://schemas.android.com/apk/res/android"
android:label="@string/app_name"
android:hint="@string/action_search"
android:searchSuggestAuthority="com.sismics.docs.provider.RecentSuggestionsProvider"
android:searchSuggestSelection=" ?">
</searchable>