PlayerAndroid/app/src/main/res/layout/activity_search.xml

122 lines
5.4 KiB
XML
Raw Normal View History

2018-07-27 13:07:33 +00:00
<?xml version="1.0" encoding="utf-8"?>
2019-04-05 10:45:09 +00:00
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
2018-07-27 13:07:33 +00:00
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
2019-12-01 15:27:01 +00:00
android:background="?attr/colorSurface"
2019-12-08 18:27:07 +00:00
android:fitsSystemWindows="true"
2018-08-08 08:03:38 +00:00
android:orientation="vertical">
2019-05-11 15:37:22 +00:00
2019-04-05 10:45:09 +00:00
<com.google.android.material.appbar.AppBarLayout
2019-05-11 15:37:22 +00:00
android:id="@+id/appBarLayout"
2018-07-27 13:07:33 +00:00
android:layout_width="match_parent"
2019-05-11 15:37:22 +00:00
android:layout_height="wrap_content"
2019-12-01 15:27:01 +00:00
android:background="@android:color/transparent"
2019-12-08 18:27:07 +00:00
android:elevation="0dp"
2019-05-11 15:37:22 +00:00
android:fitsSystemWindows="true"
2019-12-08 18:27:07 +00:00
app:elevation="0dp"
2019-09-29 03:33:23 +00:00
app:liftOnScroll="true">
2018-08-08 08:03:38 +00:00
<com.google.android.material.card.MaterialCardView
android:id="@+id/searchContainer"
2018-07-27 13:07:33 +00:00
android:layout_width="match_parent"
android:layout_height="wrap_content"
2019-09-29 03:33:23 +00:00
android:layout_marginStart="@dimen/toolbar_margin_horizontal"
android:layout_marginTop="@dimen/toolbar_margin_vertical"
android:layout_marginEnd="@dimen/toolbar_margin_horizontal"
android:layout_marginBottom="@dimen/toolbar_margin_vertical"
app:cardBackgroundColor="?colorSurface"
app:cardCornerRadius="8dp"
2019-06-29 17:15:31 +00:00
app:cardUseCompatPadding="true"
2019-09-29 08:58:05 +00:00
app:layout_scrollFlags="scroll|enterAlways">
2018-07-27 13:07:33 +00:00
<LinearLayout
2018-12-25 14:58:47 +00:00
android:layout_width="match_parent"
2019-09-29 08:37:57 +00:00
android:layout_height="wrap_content"
android:gravity="center_vertical">
2019-09-29 03:33:23 +00:00
<androidx.appcompat.widget.AppCompatImageView
android:id="@+id/back"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
2019-10-01 18:15:06 +00:00
android:padding="12dp"
2019-09-29 03:33:23 +00:00
app:srcCompat="@drawable/ic_keyboard_backspace_black_24dp"
app:tint="?colorOnSurface" />
2018-08-08 08:03:38 +00:00
2019-07-30 20:20:01 +00:00
<com.google.android.material.textfield.TextInputEditText
2018-12-06 10:23:03 +00:00
android:id="@+id/searchView"
2018-08-08 08:03:38 +00:00
android:layout_width="match_parent"
2019-09-29 08:37:57 +00:00
android:layout_height="@dimen/toolbar_height"
android:layout_weight="1"
2018-08-22 17:54:07 +00:00
android:background="@null"
2018-12-25 14:58:47 +00:00
android:hint="@string/action_search"
android:inputType="text|textAutoComplete"
android:textAppearance="@style/TextViewSubtitle1">
<requestFocus />
2019-07-30 20:20:01 +00:00
</com.google.android.material.textfield.TextInputEditText>
2018-08-22 17:54:07 +00:00
2019-11-30 11:12:47 +00:00
<FrameLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
2019-11-30 11:12:47 +00:00
android:layout_weight="0">
<androidx.appcompat.widget.AppCompatImageView
android:id="@+id/voiceSearch"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:background="?roundSelector"
android:padding="12dp"
app:srcCompat="@drawable/ic_mic_white_24dp"
app:tint="?colorOnSurface"
tools:visibility="visible" />
<androidx.appcompat.widget.AppCompatImageView
android:id="@+id/clearText"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:background="?roundSelector"
android:padding="12dp"
2019-12-01 15:27:01 +00:00
android:visibility="gone"
2019-11-30 11:12:47 +00:00
app:srcCompat="@drawable/ic_close_white_24dp"
app:tint="?colorOnSurface"
tools:visibility="visible" />
</FrameLayout>
</LinearLayout>
</com.google.android.material.card.MaterialCardView>
2019-04-05 10:45:09 +00:00
</com.google.android.material.appbar.AppBarLayout>
2018-08-08 08:03:38 +00:00
2019-10-24 20:08:09 +00:00
<com.google.android.material.textview.MaterialTextView
android:id="@android:id/empty"
android:layout_width="wrap_content"
2019-05-11 15:37:22 +00:00
android:layout_height="wrap_content"
2019-10-24 20:08:09 +00:00
android:layout_gravity="center"
android:gravity="center"
android:text="@string/no_results"
android:textAppearance="@style/TextViewHeadline6"
android:visibility="gone"
tools:visibility="visible" />
2019-09-29 03:33:23 +00:00
2019-10-24 20:08:09 +00:00
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recyclerView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:clipToPadding="false"
android:scrollbarStyle="outsideOverlay"
android:scrollbars="vertical"
app:layout_behavior="com.google.android.material.appbar.AppBarLayout$ScrollingViewBehavior" />
2019-05-11 15:37:22 +00:00
2019-04-05 10:45:09 +00:00
<com.google.android.material.floatingactionbutton.ExtendedFloatingActionButton
2019-05-11 15:37:22 +00:00
android:id="@+id/keyboardPopup"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom|end"
android:layout_margin="16dp"
2019-07-21 12:41:33 +00:00
android:text="@string/keyboard"
android:textAppearance="@style/TextViewHeadline6"
2019-05-11 15:37:22 +00:00
app:icon="@drawable/ic_keyboard_white_24dp" />
2019-04-05 10:45:09 +00:00
</androidx.coordinatorlayout.widget.CoordinatorLayout>