Files
Android-key-of-love/app/src/main/res/layout/activity_main.xml
pengxiaolong c1a80dd4cf 优化
2025-12-31 18:36:55 +08:00

41 lines
1.6 KiB
XML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?xml version="1.0" encoding="utf-8"?>
<androidx.coordinatorlayout.widget.CoordinatorLayout
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"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".MainActivity">
<FrameLayout
android:id="@+id/root_container"
android:layout_width="match_parent"
android:layout_height="match_parent">
<!-- 3个Tab NavHost 都 add 到这里 -->
<androidx.fragment.app.FragmentContainerView
android:id="@+id/tab_container"
android:layout_width="match_parent"
android:layout_height="match_parent"/>
<!-- 全局页面覆盖层login/recharge等 -->
<androidx.fragment.app.FragmentContainerView
android:id="@+id/global_container"
android:name="androidx.navigation.fragment.NavHostFragment"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="gone" />
</FrameLayout>
<com.google.android.material.bottomnavigation.BottomNavigationView
android:id="@+id/bottom_nav"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="bottom"
android:background="@android:color/white"
app:menu="@menu/menu_bottom_nav"
app:itemIconTint="@null"
app:itemTextColor="@color/nav_text_color"/>
</androidx.coordinatorlayout.widget.CoordinatorLayout>