summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAdnan Begovic <adnan@cyngn.com>2016-05-20 13:06:35 -0700
committerMichael Bestas <mikeioannina@gmail.com>2017-01-04 21:57:50 +0200
commit5cab2e3f008f6b6e21eda10af41904d094db88ce (patch)
treea108e9e31ec6f14f367d50892c803c52caf45d7c
parent4d959eb3d16933b7e876da0a9c1ed278dc56f5b2 (diff)
downloadandroid_packages_apps_Snap-5cab2e3f008f6b6e21eda10af41904d094db88ce.zip
android_packages_apps_Snap-5cab2e3f008f6b6e21eda10af41904d094db88ce.tar.gz
android_packages_apps_Snap-5cab2e3f008f6b6e21eda10af41904d094db88ce.tar.bz2
Snap: Use new window manager flag for prevent system keys.
Change-Id: I94ed12ddd33729a4fb486f7fb68f1bbab788b239 TICKET: FEIJ-522
-rw-r--r--AndroidManifest.xml2
-rwxr-xr-xsrc/com/android/camera/CameraActivity.java4
2 files changed, 3 insertions, 3 deletions
diff --git a/AndroidManifest.xml b/AndroidManifest.xml
index 44d56cf..c7820f5 100644
--- a/AndroidManifest.xml
+++ b/AndroidManifest.xml
@@ -25,7 +25,7 @@
<uses-permission android:name="android.permission.WRITE_SYNC_SETTINGS" />
<uses-permission android:name="android.permission.MOUNT_UNMOUNT_FILESYSTEMS" />
<uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS" />
- <uses-permission android:name="android.permission.PREVENT_POWER_KEY" />
+ <uses-permission android:name="android.permission.PREVENT_SYSTEM_KEYS" />
<supports-screens
android:anyDensity="true"
diff --git a/src/com/android/camera/CameraActivity.java b/src/com/android/camera/CameraActivity.java
index f7aa35a..347a60f 100755
--- a/src/com/android/camera/CameraActivity.java
+++ b/src/com/android/camera/CameraActivity.java
@@ -1966,10 +1966,10 @@ public class CameraActivity extends Activity
}
if (mPowerShutter && mInCameraApp) {
getWindow().addPrivateFlags(
- WindowManager.LayoutParams.PRIVATE_FLAG_PREVENT_POWER_KEY);
+ WindowManager.LayoutParams.PRIVATE_FLAG_PREVENT_SYSTEM_KEYS);
} else {
getWindow().clearPrivateFlags(
- WindowManager.LayoutParams.PRIVATE_FLAG_PREVENT_POWER_KEY);
+ WindowManager.LayoutParams.PRIVATE_FLAG_PREVENT_SYSTEM_KEYS);
}
}