Commit 6dd50a28 authored by Mygod's avatar Mygod

Navigation view fits system windows

parent fe68f36a
...@@ -20,6 +20,7 @@ ...@@ -20,6 +20,7 @@
<activity <activity
android:name=".MainActivity" android:name=".MainActivity"
android:label="@string/app_name" android:label="@string/app_name"
android:theme="@style/Theme.Shadowsocks.Navigation"
android:launchMode="singleTask"> android:launchMode="singleTask">
<intent-filter> <intent-filter>
<action android:name="android.intent.action.MAIN"/> <action android:name="android.intent.action.MAIN"/>
......
...@@ -5,12 +5,14 @@ ...@@ -5,12 +5,14 @@
xmlns:tools="http://schemas.android.com/tools" xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/drawer" android:id="@+id/drawer"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent"
android:fitsSystemWindows="true">
<androidx.coordinatorlayout.widget.CoordinatorLayout <androidx.coordinatorlayout.widget.CoordinatorLayout
android:id="@+id/snackbar" android:id="@+id/snackbar"
android:clipChildren="false" android:clipChildren="false"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent"
android:fitsSystemWindows="true">
<FrameLayout <FrameLayout
android:id="@+id/fragment_holder" android:id="@+id/fragment_holder"
...@@ -124,6 +126,7 @@ ...@@ -124,6 +126,7 @@
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_gravity="start" android:layout_gravity="start"
android:fitsSystemWindows="true"
app:itemIconTint="@color/nav_item_tint" app:itemIconTint="@color/nav_item_tint"
app:itemTextColor="@color/nav_item_tint" app:itemTextColor="@color/nav_item_tint"
app:headerLayout="@layout/navigation_header" app:headerLayout="@layout/navigation_header"
......
<?xml version="1.0" encoding="utf-8"?>
<resources>
<style name="Theme.Shadowsocks.Navigation">
<item name="android:windowDrawsSystemBarBackgrounds">true</item>
<item name="android:statusBarColor">@android:color/transparent</item>
</style>
</resources>
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment