Merge "Volume panel should not clear system ui flags." into klp-dev

This commit is contained in:
John Spurlock
2014-03-04 19:09:20 +00:00
committed by Android (Google) Code Review
3 changed files with 7 additions and 17 deletions

View File

@@ -311,7 +311,6 @@ public class VolumePanel extends Handler implements OnSeekBarChangeListener, Vie
lp.type = LayoutParams.TYPE_VOLUME_OVERLAY; lp.type = LayoutParams.TYPE_VOLUME_OVERLAY;
lp.width = LayoutParams.WRAP_CONTENT; lp.width = LayoutParams.WRAP_CONTENT;
lp.height = LayoutParams.WRAP_CONTENT; lp.height = LayoutParams.WRAP_CONTENT;
lp.privateFlags |= LayoutParams.PRIVATE_FLAG_FORCE_SHOW_NAV_BAR;
window.setAttributes(lp); window.setAttributes(lp);
window.addFlags(LayoutParams.FLAG_NOT_FOCUSABLE | LayoutParams.FLAG_NOT_TOUCH_MODAL window.addFlags(LayoutParams.FLAG_NOT_FOCUSABLE | LayoutParams.FLAG_NOT_TOUCH_MODAL
| LayoutParams.FLAG_WATCH_OUTSIDE_TOUCH); | LayoutParams.FLAG_WATCH_OUTSIDE_TOUCH);

View File

@@ -1062,13 +1062,6 @@ public interface WindowManager extends ViewManager {
* {@hide} */ * {@hide} */
public static final int PRIVATE_FLAG_SHOW_FOR_ALL_USERS = 0x00000010; public static final int PRIVATE_FLAG_SHOW_FOR_ALL_USERS = 0x00000010;
/**
* Special flag for the volume overlay: force the window manager out of "hide nav bar"
* mode while the window is on screen.
*
* {@hide} */
public static final int PRIVATE_FLAG_FORCE_SHOW_NAV_BAR = 0x00000020;
/** /**
* Never animate position changes of the window. * Never animate position changes of the window.
* *

View File

@@ -3277,8 +3277,9 @@ public class PhoneWindowManager implements WindowManagerPolicy {
+ mRestrictedScreenWidth; + mRestrictedScreenWidth;
pf.bottom = df.bottom = of.bottom = cf.bottom = mRestrictedScreenTop pf.bottom = df.bottom = of.bottom = cf.bottom = mRestrictedScreenTop
+ mRestrictedScreenHeight; + mRestrictedScreenHeight;
} else if (attrs.type == TYPE_TOAST || attrs.type == TYPE_SYSTEM_ALERT) { } else if (attrs.type == TYPE_TOAST || attrs.type == TYPE_SYSTEM_ALERT
// Toasts are stable to interim decor changes. || attrs.type == TYPE_VOLUME_OVERLAY) {
// These dialogs are stable to interim decor changes.
pf.left = df.left = of.left = cf.left = mStableLeft; pf.left = df.left = of.left = cf.left = mStableLeft;
pf.top = df.top = of.top = cf.top = mStableTop; pf.top = df.top = of.top = cf.top = mStableTop;
pf.right = df.right = of.right = cf.right = mStableRight; pf.right = df.right = of.right = cf.right = mStableRight;
@@ -3382,13 +3383,10 @@ public class PhoneWindowManager implements WindowManagerPolicy {
WindowManager.LayoutParams attrs) { WindowManager.LayoutParams attrs) {
if (DEBUG_LAYOUT) Slog.i(TAG, "Win " + win + ": isVisibleOrBehindKeyguardLw=" if (DEBUG_LAYOUT) Slog.i(TAG, "Win " + win + ": isVisibleOrBehindKeyguardLw="
+ win.isVisibleOrBehindKeyguardLw()); + win.isVisibleOrBehindKeyguardLw());
if (mTopFullscreenOpaqueWindowState == null && (win.getAttrs().privateFlags if (mTopFullscreenOpaqueWindowState == null
&WindowManager.LayoutParams.PRIVATE_FLAG_FORCE_SHOW_NAV_BAR) != 0 && win.isVisibleLw() && attrs.type == TYPE_INPUT_METHOD) {
|| (win.isVisibleLw() && attrs.type == TYPE_INPUT_METHOD)) { mForcingShowNavBar = true;
if (mForcingShowNavBarLayer < 0) { mForcingShowNavBarLayer = win.getSurfaceLayer();
mForcingShowNavBar = true;
mForcingShowNavBarLayer = win.getSurfaceLayer();
}
} }
if (mTopFullscreenOpaqueWindowState == null && if (mTopFullscreenOpaqueWindowState == null &&
win.isVisibleOrBehindKeyguardLw() && !win.isGoneForLayoutLw()) { win.isVisibleOrBehindKeyguardLw() && !win.isGoneForLayoutLw()) {