Loading core/java/android/view/WindowManager.java +4 −2 Original line number Diff line number Diff line Loading @@ -604,8 +604,10 @@ public interface WindowManager extends ViewManager { public static final int TYPE_DRAG = FIRST_SYSTEM_WINDOW+16; /** * Window type: panel that slides out from under the status bar * In multiuser systems shows on all users' windows. * Window type: panel that slides out from over the status bar * In multiuser systems shows on all users' windows. These windows * are displayed on top of the stauts bar and any {@link #TYPE_STATUS_BAR_PANEL} * windows. * @hide */ public static final int TYPE_STATUS_BAR_SUB_PANEL = FIRST_SYSTEM_WINDOW+17; Loading services/core/java/com/android/server/policy/WindowManagerPolicy.java +3 −3 Original line number Diff line number Diff line Loading @@ -808,11 +808,11 @@ public interface WindowManagerPolicy extends WindowManagerPolicyConstants { case TYPE_INPUT_METHOD_DIALOG: // on-screen keyboards and other such input method user interfaces go here. return 15; case TYPE_STATUS_BAR_SUB_PANEL: return 17; case TYPE_STATUS_BAR: return 18; return 17; case TYPE_STATUS_BAR_PANEL: return 18; case TYPE_STATUS_BAR_SUB_PANEL: return 19; case TYPE_KEYGUARD_DIALOG: return 20; Loading services/tests/servicestests/src/com/android/server/wm/ZOrderingTests.java +20 −0 Original line number Diff line number Diff line Loading @@ -42,6 +42,9 @@ import static android.view.WindowManager.LayoutParams.TYPE_APPLICATION_ATTACHED_ import static android.view.WindowManager.LayoutParams.TYPE_APPLICATION_MEDIA_OVERLAY; import static android.view.WindowManager.LayoutParams.TYPE_BASE_APPLICATION; import static android.view.WindowManager.LayoutParams.TYPE_SYSTEM_OVERLAY; import static android.view.WindowManager.LayoutParams.TYPE_NAVIGATION_BAR_PANEL; import static android.view.WindowManager.LayoutParams.TYPE_STATUS_BAR_PANEL; import static android.view.WindowManager.LayoutParams.TYPE_STATUS_BAR_SUB_PANEL; /** * Tests for the {@link WindowLayersController} class. Loading Loading @@ -323,4 +326,21 @@ public class ZOrderingTests extends WindowTestsBase { assertWindowLayerGreaterThan(mTransaction, assistantStackWindow, dockedStackWindow); assertWindowLayerGreaterThan(mTransaction, pinnedStackWindow, assistantStackWindow); } @Test public void testAssignWindowLayers_ForSysUiPanels() throws Exception { final WindowState navBarPanel = createWindow(null, TYPE_NAVIGATION_BAR_PANEL, mDisplayContent, "NavBarPanel"); final WindowState statusBarPanel = createWindow(null, TYPE_STATUS_BAR_PANEL, mDisplayContent, "StatusBarPanel"); final WindowState statusBarSubPanel = createWindow(null, TYPE_STATUS_BAR_SUB_PANEL, mDisplayContent, "StatusBarSubPanel"); mDisplayContent.assignChildLayers(mTransaction); // Ime should be above all app windows and below system windows if it is targeting an app // window. assertWindowLayerGreaterThan(mTransaction, navBarPanel, mNavBarWindow); assertWindowLayerGreaterThan(mTransaction, statusBarPanel, mStatusBarWindow); assertWindowLayerGreaterThan(mTransaction, statusBarSubPanel, statusBarPanel); } } Loading
core/java/android/view/WindowManager.java +4 −2 Original line number Diff line number Diff line Loading @@ -604,8 +604,10 @@ public interface WindowManager extends ViewManager { public static final int TYPE_DRAG = FIRST_SYSTEM_WINDOW+16; /** * Window type: panel that slides out from under the status bar * In multiuser systems shows on all users' windows. * Window type: panel that slides out from over the status bar * In multiuser systems shows on all users' windows. These windows * are displayed on top of the stauts bar and any {@link #TYPE_STATUS_BAR_PANEL} * windows. * @hide */ public static final int TYPE_STATUS_BAR_SUB_PANEL = FIRST_SYSTEM_WINDOW+17; Loading
services/core/java/com/android/server/policy/WindowManagerPolicy.java +3 −3 Original line number Diff line number Diff line Loading @@ -808,11 +808,11 @@ public interface WindowManagerPolicy extends WindowManagerPolicyConstants { case TYPE_INPUT_METHOD_DIALOG: // on-screen keyboards and other such input method user interfaces go here. return 15; case TYPE_STATUS_BAR_SUB_PANEL: return 17; case TYPE_STATUS_BAR: return 18; return 17; case TYPE_STATUS_BAR_PANEL: return 18; case TYPE_STATUS_BAR_SUB_PANEL: return 19; case TYPE_KEYGUARD_DIALOG: return 20; Loading
services/tests/servicestests/src/com/android/server/wm/ZOrderingTests.java +20 −0 Original line number Diff line number Diff line Loading @@ -42,6 +42,9 @@ import static android.view.WindowManager.LayoutParams.TYPE_APPLICATION_ATTACHED_ import static android.view.WindowManager.LayoutParams.TYPE_APPLICATION_MEDIA_OVERLAY; import static android.view.WindowManager.LayoutParams.TYPE_BASE_APPLICATION; import static android.view.WindowManager.LayoutParams.TYPE_SYSTEM_OVERLAY; import static android.view.WindowManager.LayoutParams.TYPE_NAVIGATION_BAR_PANEL; import static android.view.WindowManager.LayoutParams.TYPE_STATUS_BAR_PANEL; import static android.view.WindowManager.LayoutParams.TYPE_STATUS_BAR_SUB_PANEL; /** * Tests for the {@link WindowLayersController} class. Loading Loading @@ -323,4 +326,21 @@ public class ZOrderingTests extends WindowTestsBase { assertWindowLayerGreaterThan(mTransaction, assistantStackWindow, dockedStackWindow); assertWindowLayerGreaterThan(mTransaction, pinnedStackWindow, assistantStackWindow); } @Test public void testAssignWindowLayers_ForSysUiPanels() throws Exception { final WindowState navBarPanel = createWindow(null, TYPE_NAVIGATION_BAR_PANEL, mDisplayContent, "NavBarPanel"); final WindowState statusBarPanel = createWindow(null, TYPE_STATUS_BAR_PANEL, mDisplayContent, "StatusBarPanel"); final WindowState statusBarSubPanel = createWindow(null, TYPE_STATUS_BAR_SUB_PANEL, mDisplayContent, "StatusBarSubPanel"); mDisplayContent.assignChildLayers(mTransaction); // Ime should be above all app windows and below system windows if it is targeting an app // window. assertWindowLayerGreaterThan(mTransaction, navBarPanel, mNavBarWindow); assertWindowLayerGreaterThan(mTransaction, statusBarPanel, mStatusBarWindow); assertWindowLayerGreaterThan(mTransaction, statusBarSubPanel, statusBarPanel); } }