Magisk/app/src/main/res/layout/fragment_hide_md2.xml

111 lines
4.4 KiB
XML
Raw Normal View History

2019-10-18 17:04:41 +02:00
<?xml version="1.0" encoding="utf-8"?>
<layout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools">
2019-10-18 17:04:41 +02:00
<data>
<variable
name="viewModel"
2020-01-13 00:43:09 +08:00
type="com.topjohnwu.magisk.ui.hide.HideViewModel" />
2019-10-18 17:04:41 +02:00
</data>
2019-10-31 20:53:37 +01:00
<FrameLayout
2019-10-18 17:04:41 +02:00
android:layout_width="match_parent"
2019-10-31 20:53:37 +01:00
android:layout_height="match_parent">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/hide_content"
2020-08-10 07:05:07 -07:00
dividerVertical="@{@drawable/divider_l_50}"
invisibleUnless="@{viewModel.loaded || !viewModel.items.empty}"
itemBinding="@{viewModel.itemBinding}"
items="@{viewModel.items}"
2019-10-31 20:53:37 +01:00
android:layout_width="match_parent"
android:layout_height="match_parent"
android:clipToPadding="false"
android:orientation="vertical"
android:paddingStart="@dimen/l1"
android:paddingTop="@{viewModel.insets.top + (int) @dimen/internal_action_bar_size + (int) @dimen/l1}"
android:paddingEnd="@dimen/l1"
android:paddingBottom="@{viewModel.insets.bottom + (int) @dimen/internal_action_bar_size + (int) @dimen/l1}"
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
tools:listitem="@layout/item_hide_md2"
tools:paddingTop="40dp" />
<com.google.android.material.floatingactionbutton.FloatingActionButton
android:id="@+id/hide_filter_toggle"
2020-09-24 04:48:38 +08:00
invisibleUnless="@{viewModel.loaded || !viewModel.items.empty}"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom|end"
android:layout_marginStart="@dimen/l1"
android:layout_marginEnd="@dimen/l1"
android:layout_marginBottom="@{viewModel.insets.bottom + (int) @dimen/l1}"
app:backgroundTint="?colorSurfaceSurfaceVariant"
2020-08-27 03:10:25 -07:00
app:srcCompat="@drawable/ic_search_md2"
app:tint="?colorPrimary"
tools:layout_marginBottom="64dp" />
<com.google.android.material.circularreveal.cardview.CircularRevealCardView
android:id="@+id/hide_filter"
2020-09-17 02:27:43 -07:00
style="@style/WidgetFoundation.Card"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="bottom"
android:visibility="invisible"
app:cardCornerRadius="0dp">
<include
android:id="@+id/hide_filter_include"
layout="@layout/include_hide_filter"
viewModel="@{viewModel}"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
</com.google.android.material.circularreveal.cardview.CircularRevealCardView>
2019-10-31 20:53:37 +01:00
<LinearLayout
goneUnless="@{viewModel.loading &amp;&amp; viewModel.items.empty}"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:gravity="center"
2020-08-10 07:05:07 -07:00
android:orientation="vertical"
tools:visibility="gone">
2019-10-31 20:53:37 +01:00
2020-08-10 07:05:07 -07:00
<TextView
2019-10-31 20:53:37 +01:00
android:layout_width="wrap_content"
android:layout_height="wrap_content"
2020-09-24 04:44:44 +08:00
android:text="@string/loading"
android:textAppearance="@style/AppearanceFoundation.Title"
2019-10-31 20:53:37 +01:00
android:textStyle="bold" />
<ProgressBar
style="@style/WidgetFoundation.ProgressBar.Indeterminate"
2019-10-31 20:53:37 +01:00
android:layout_marginTop="@dimen/l1" />
</LinearLayout>
2020-09-24 04:48:38 +08:00
<LinearLayout
goneUnless="@{viewModel.loadFailed}"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:gravity="center"
android:orientation="vertical"
tools:visibility="gone">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/not_available"
android:textAppearance="@style/AppearanceFoundation.Title"
android:textStyle="bold" />
</LinearLayout>
2019-10-31 20:53:37 +01:00
</FrameLayout>
2019-10-18 17:04:41 +02:00
2020-01-13 00:43:09 +08:00
</layout>