Loading core/java/android/view/WindowManagerPolicy.java +11 −4 Original line number Diff line number Diff line Loading @@ -275,6 +275,13 @@ public interface WindowManagerPolicy { */ public int getSurfaceLayer(); /** * Retrieve the type of the top-level window. * * @return the base type of the parent window if attached or its own type otherwise */ public int getBaseType(); /** * Return the token for the application (actually activity) that owns * this window. May return null for system windows. Loading services/core/java/com/android/server/policy/PhoneWindowManager.java +2 −2 Original line number Diff line number Diff line Loading @@ -6386,8 +6386,8 @@ public class PhoneWindowManager implements WindowManagerPolicy { immersiveSticky = (vis & View.SYSTEM_UI_FLAG_IMMERSIVE_STICKY) != 0; final boolean navAllowedHidden = immersive || immersiveSticky; if (!navAllowedHidden && windowTypeToLayerLw(type) > windowTypeToLayerLw(TYPE_INPUT_CONSUMER)) { if (hideNavBarSysui && !navAllowedHidden && windowTypeToLayerLw(win.getBaseType()) > windowTypeToLayerLw(TYPE_INPUT_CONSUMER)) { // We can't hide the navbar from this window otherwise the input consumer would not get // the input events. vis = (vis & ~View.SYSTEM_UI_FLAG_HIDE_NAVIGATION); Loading services/core/java/com/android/server/wm/WindowState.java +9 −0 Original line number Diff line number Diff line Loading @@ -780,6 +780,15 @@ final class WindowState implements WindowManagerPolicy.WindowState { return mLayer; } @Override public int getBaseType() { WindowState win = this; while (win.mAttachedWindow != null) { win = win.mAttachedWindow; } return win.mAttrs.type; } @Override public IApplicationToken getAppToken() { return mAppToken != null ? mAppToken.appToken : null; Loading Loading
core/java/android/view/WindowManagerPolicy.java +11 −4 Original line number Diff line number Diff line Loading @@ -275,6 +275,13 @@ public interface WindowManagerPolicy { */ public int getSurfaceLayer(); /** * Retrieve the type of the top-level window. * * @return the base type of the parent window if attached or its own type otherwise */ public int getBaseType(); /** * Return the token for the application (actually activity) that owns * this window. May return null for system windows. Loading
services/core/java/com/android/server/policy/PhoneWindowManager.java +2 −2 Original line number Diff line number Diff line Loading @@ -6386,8 +6386,8 @@ public class PhoneWindowManager implements WindowManagerPolicy { immersiveSticky = (vis & View.SYSTEM_UI_FLAG_IMMERSIVE_STICKY) != 0; final boolean navAllowedHidden = immersive || immersiveSticky; if (!navAllowedHidden && windowTypeToLayerLw(type) > windowTypeToLayerLw(TYPE_INPUT_CONSUMER)) { if (hideNavBarSysui && !navAllowedHidden && windowTypeToLayerLw(win.getBaseType()) > windowTypeToLayerLw(TYPE_INPUT_CONSUMER)) { // We can't hide the navbar from this window otherwise the input consumer would not get // the input events. vis = (vis & ~View.SYSTEM_UI_FLAG_HIDE_NAVIGATION); Loading
services/core/java/com/android/server/wm/WindowState.java +9 −0 Original line number Diff line number Diff line Loading @@ -780,6 +780,15 @@ final class WindowState implements WindowManagerPolicy.WindowState { return mLayer; } @Override public int getBaseType() { WindowState win = this; while (win.mAttachedWindow != null) { win = win.mAttachedWindow; } return win.mAttrs.type; } @Override public IApplicationToken getAppToken() { return mAppToken != null ? mAppToken.appToken : null; Loading