android11-隐藏状态栏和导航栏

隐藏导航栏

/android11/frameworks/base/packages/SystemUI/res/layout/navigation_bar.xml
diff --git a/frameworks/base/packages/SystemUI/res/layout/navigation_bar.xml b/frameworks/base/packages/SystemUI/res/layout/navigation_bar.xml
index ba6b6956f1..6db2348df8 100644
--- a/frameworks/base/packages/SystemUI/res/layout/navigation_bar.xml
+++ b/frameworks/base/packages/SystemUI/res/layout/navigation_bar.xml
@@ -22,6 +22,7 @@
     xmlns:systemui="http://schemas.android.com/apk/res-auto"
     android:layout_height="match_parent"
     android:layout_width="match_parent"
+    android:visibility="gone"
     android:background="@drawable/system_bar_background">
 
     
+        android:layout_height="match_parent" 
+        android:visibility="gone"/>

隐藏状态栏

/android11/frameworks/base/packages/SystemUI/res/layout/status_bar.xml
diff --git a/frameworks/base/packages/SystemUI/res/layout/status_bar.xml b/frameworks/base/packages/SystemUI/res/layout/status_bar.xml
index f8db97dbf8..3427430fa5 100644
--- a/frameworks/base/packages/SystemUI/res/layout/status_bar.xml
+++ b/frameworks/base/packages/SystemUI/res/layout/status_bar.xml
@@ -26,6 +26,7 @@
     android:id="@+id/status_bar"
     android:orientation="vertical"
     android:focusable="false"
+    android:visibility="gone"
     android:descendantFocusability="afterDescendants"
     android:accessibilityPaneTitle="@string/status_bar"
     >

你可能感兴趣的:(Android,android)