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

66 lines
2.6 KiB
XML
Raw Normal View History

2019-10-17 16:57:00 +00: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-17 16:57:00 +00:00
<data>
<import type="com.topjohnwu.magisk.Config" />
2019-10-17 16:57:00 +00:00
<variable
name="viewModel"
type="com.topjohnwu.magisk.redesign.module.ModuleViewModel" />
</data>
<androidx.core.widget.NestedScrollView
android:layout_width="match_parent"
android:clipToPadding="false"
2019-10-17 16:57:00 +00:00
android:layout_height="match_parent"
android:fillViewport="true"
android:paddingTop="@{viewModel.insets.top + (int) @dimen/internal_action_bar_size}"
android:paddingBottom="@{viewModel.insets.bottom + (int) @dimen/l2}"
tools:paddingTop="24dp">
2019-10-17 16:57:00 +00:00
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<com.google.android.material.card.MaterialCardView
android:id="@+id/module_notice"
style="?styleCardNormal"
gone="@{!Config.coreOnly}"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="@dimen/l1"
android:visibility="gone"
app:cardBackgroundColor="?colorError"
app:layout_constraintTop_toTopOf="parent"
tools:visibility="visible">
<androidx.appcompat.widget.AppCompatTextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:padding="@dimen/l1"
android:text="@string/module_safe_mode_message"
android:textAppearance="?appearanceTextCaptionOnPrimary"
android:textStyle="bold" />
</com.google.android.material.card.MaterialCardView>
<androidx.recyclerview.widget.RecyclerView
itemBinding="@{viewModel.itemBinding}"
items="@{viewModel.items}"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/l1"
android:orientation="vertical"
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
app:layout_constraintTop_toBottomOf="@+id/module_notice" />
</androidx.constraintlayout.widget.ConstraintLayout>
2019-10-17 16:57:00 +00:00
</androidx.core.widget.NestedScrollView>
</layout>