summaryrefslogtreecommitdiffstats
path: root/src/com/android
diff options
context:
space:
mode:
authorAngus Kong <shkong@google.com>2012-11-01 15:08:44 +0800
committerAngus Kong <shkong@google.com>2012-11-01 15:15:19 +0800
commit3935ca3762344c5f8a306596d70c0d4d4a2fda4b (patch)
tree15cd46d9d0dfaf71e240065dc54b96072cb94a3b /src/com/android
parent262c7bd76f21d440f2da3a4118c432987fcb8cdd (diff)
downloadandroid_packages_apps_Gallery2-3935ca3762344c5f8a306596d70c0d4d4a2fda4b.tar.gz
android_packages_apps_Gallery2-3935ca3762344c5f8a306596d70c0d4d4a2fda4b.tar.bz2
android_packages_apps_Gallery2-3935ca3762344c5f8a306596d70c0d4d4a2fda4b.zip
Jump to lockscreen in secure album if tap on video
bug:7454356 Change-Id: I1e7e9ed886d414d5b41abdb1cc1d00c7736ae006
Diffstat (limited to 'src/com/android')
-rw-r--r--src/com/android/gallery3d/app/PhotoPage.java9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/com/android/gallery3d/app/PhotoPage.java b/src/com/android/gallery3d/app/PhotoPage.java
index 4c2130b40..a48db37d8 100644
--- a/src/com/android/gallery3d/app/PhotoPage.java
+++ b/src/com/android/gallery3d/app/PhotoPage.java
@@ -1136,8 +1136,7 @@ public class PhotoPage extends ActivityState implements
}
int supported = item.getSupportedOperations();
- boolean playVideo = (mSecureAlbum == null) &&
- ((supported & MediaItem.SUPPORT_PLAY) != 0);
+ boolean playVideo = ((supported & MediaItem.SUPPORT_PLAY) != 0);
boolean unlock = ((supported & MediaItem.SUPPORT_UNLOCK) != 0);
boolean goBack = ((supported & MediaItem.SUPPORT_BACK) != 0);
boolean launchCamera = ((supported & MediaItem.SUPPORT_CAMERA_SHORTCUT) != 0);
@@ -1152,7 +1151,11 @@ public class PhotoPage extends ActivityState implements
}
if (playVideo) {
- playVideo(mActivity, item.getPlayUri(), item.getName());
+ if (mSecureAlbum == null) {
+ playVideo(mActivity, item.getPlayUri(), item.getName());
+ } else {
+ mActivity.getStateManager().finishState(this);
+ }
} else if (goBack) {
onBackPressed();
} else if (unlock) {