summaryrefslogtreecommitdiffstats
path: root/src/com/android
diff options
context:
space:
mode:
authorBobby Georgescu <georgescu@google.com>2012-10-22 15:56:00 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2012-10-22 15:56:00 -0700
commitd49f3bb068bf4fd78480cf9de04d28c9ae70388f (patch)
treea156546b82ccdebc3cfe8f4e9b7fe54dd6099ac9 /src/com/android
parent817f83be3d4b7baedf73aee2ebc100452b615630 (diff)
parente49d4f91b60b33c8f2f59e217916ffe4507f1714 (diff)
downloadandroid_packages_apps_Snap-d49f3bb068bf4fd78480cf9de04d28c9ae70388f.tar.gz
android_packages_apps_Snap-d49f3bb068bf4fd78480cf9de04d28c9ae70388f.tar.bz2
android_packages_apps_Snap-d49f3bb068bf4fd78480cf9de04d28c9ae70388f.zip
am e96e907a: Merge "Scroll to placeholder in gallery filmstrip launches camera" into gb-ub-photos-arches
* commit 'e96e907a01c0d633828dade014f07a5b93b07356': Scroll to placeholder in gallery filmstrip launches camera
Diffstat (limited to 'src/com/android')
-rw-r--r--src/com/android/gallery3d/app/PhotoPage.java16
1 files changed, 13 insertions, 3 deletions
diff --git a/src/com/android/gallery3d/app/PhotoPage.java b/src/com/android/gallery3d/app/PhotoPage.java
index d6c8ef481..fb4e88b2a 100644
--- a/src/com/android/gallery3d/app/PhotoPage.java
+++ b/src/com/android/gallery3d/app/PhotoPage.java
@@ -345,13 +345,22 @@ public class PhotoPage extends ActivityState implements
mMediaSet.getMediaItemCount() > 1) {
mPhotoView.switchToImage(1);
} else {
- mPhotoView.setFilmMode(false);
+ if (mAppBridge != null) mPhotoView.setFilmMode(false);
stayedOnCamera = true;
}
if (stayedOnCamera) {
- updateBars();
- updateCurrentPhoto(mModel.getMediaItem(0));
+ if (mAppBridge == null) {
+ GalleryUtils.startCameraActivity(mActivity);
+ /* We got here by swiping from photo 1 to the
+ placeholder, so make it be the thing that
+ is in focus when the user presses back from
+ the camera app */
+ mPhotoView.switchToImage(1);
+ } else {
+ updateBars();
+ updateCurrentPhoto(mModel.getMediaItem(0));
+ }
}
break;
}
@@ -579,6 +588,7 @@ public class PhotoPage extends ActivityState implements
@Override
public void onPictureCenter(boolean isCamera) {
+ isCamera = isCamera || (mInCameraRoll && mAppBridge == null);
mPhotoView.setWantPictureCenterCallbacks(false);
mHandler.removeMessages(MSG_ON_CAMERA_CENTER);
mHandler.removeMessages(MSG_ON_PICTURE_CENTER);