summaryrefslogtreecommitdiffstats
path: root/services
diff options
context:
space:
mode:
authorSultanxda <sultanxda@gmail.com>2016-06-02 10:09:38 -0700
committerAdnan Begovic <adnan@cyngn.com>2016-06-02 10:39:25 -0700
commitce709c9f22d500606d20c682298e937bd32e14d9 (patch)
tree71dbe44d326cbaf0b947228462d480048a9a2863 /services
parentcb4391b421d2d461eef7ac10e83cdbc406d4cf9b (diff)
downloadframeworks_base-ce709c9f22d500606d20c682298e937bd32e14d9.zip
frameworks_base-ce709c9f22d500606d20c682298e937bd32e14d9.tar.gz
frameworks_base-ce709c9f22d500606d20c682298e937bd32e14d9.tar.bz2
fw: Fix power key interception for PRIVATE_FLAG_PREVENT_POWER_KEY
TICKET: CYNGNOS-2958 Change-Id: I67a7469257a1617b1c999f5533c5863014595dcc
Diffstat (limited to 'services')
-rw-r--r--services/core/java/com/android/server/policy/PhoneWindowManager.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/services/core/java/com/android/server/policy/PhoneWindowManager.java b/services/core/java/com/android/server/policy/PhoneWindowManager.java
index 98104b7..33ede76 100644
--- a/services/core/java/com/android/server/policy/PhoneWindowManager.java
+++ b/services/core/java/com/android/server/policy/PhoneWindowManager.java
@@ -3265,8 +3265,7 @@ public class PhoneWindowManager implements WindowManagerPolicy {
if (mTopFullscreenOpaqueWindowState != null &&
(mTopFullscreenOpaqueWindowState.getAttrs().privateFlags
- & (WindowManager.LayoutParams.PRIVATE_FLAG_PREVENT_SYSTEM_KEYS |
- WindowManager.LayoutParams.PRIVATE_FLAG_PREVENT_POWER_KEY)) != 0
+ & WindowManager.LayoutParams.PRIVATE_FLAG_PREVENT_SYSTEM_KEYS) != 0
&& mScreenOnFully) {
return 0;
}
@@ -5855,7 +5854,8 @@ public class PhoneWindowManager implements WindowManagerPolicy {
case KeyEvent.KEYCODE_POWER: {
if (mTopFullscreenOpaqueWindowState != null &&
(mTopFullscreenOpaqueWindowState.getAttrs().privateFlags
- & WindowManager.LayoutParams.PRIVATE_FLAG_PREVENT_SYSTEM_KEYS) != 0
+ & (WindowManager.LayoutParams.PRIVATE_FLAG_PREVENT_SYSTEM_KEYS |
+ WindowManager.LayoutParams.PRIVATE_FLAG_PREVENT_POWER_KEY)) != 0
&& mScreenOnFully) {
return result;
}