activity_search.xml 2.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
  3. xmlns:tools="http://schemas.android.com/tools"
  4. android:layout_width="match_parent"
  5. android:layout_height="match_parent"
  6. android:background="#ffffff"
  7. tools:context=".ui.activity.SearchActivity">
  8. <LinearLayout
  9. android:id="@+id/search_bar"
  10. android:layout_width="match_parent"
  11. android:layout_height="wrap_content"
  12. android:layout_alignParentTop="true"
  13. android:gravity="center"
  14. android:orientation="horizontal"
  15. android:padding="5dp">
  16. <ImageView
  17. android:id="@+id/search_but_back"
  18. android:layout_width="wrap_content"
  19. android:layout_height="match_parent"
  20. android:contentDescription="@string/image_des"
  21. android:padding="10dp"
  22. android:src="@drawable/narrow_back_black" />
  23. <EditText
  24. android:id="@+id/search_input_txt"
  25. android:layout_width="0dp"
  26. android:layout_height="match_parent"
  27. android:layout_marginLeft="8dp"
  28. android:layout_marginRight="8dp"
  29. android:layout_weight="1"
  30. android:background="@drawable/shape_input_background_radius"
  31. android:hint="@string/search_hint_txt"
  32. android:inputType="text"
  33. android:paddingLeft="5dp"
  34. android:paddingRight="5dp"
  35. android:textColor="#666666"
  36. android:textColorHint="#aaaaaa"
  37. android:textSize="14sp" />
  38. <TextView
  39. android:id="@+id/search_but_search"
  40. android:layout_width="wrap_content"
  41. android:layout_height="match_parent"
  42. android:gravity="center"
  43. android:paddingLeft="8dp"
  44. android:paddingRight="8dp"
  45. android:text="@string/search_but_text" />
  46. </LinearLayout>
  47. <android.support.v7.widget.RecyclerView
  48. android:layout_width="match_parent"
  49. android:layout_height="match_parent"
  50. android:layout_below="@+id/search_bar"
  51. android:layout_alignParentStart="true" />
  52. </RelativeLayout>