Correct undo behavior

Bug: 7307293
Change-Id: I72f814acd3625024f1e2aeccec4abfd28ad3319b
diff --git a/src/com/android/gallery3d/app/PhotoPage.java b/src/com/android/gallery3d/app/PhotoPage.java
index 7ded725..3a97c53 100644
--- a/src/com/android/gallery3d/app/PhotoPage.java
+++ b/src/com/android/gallery3d/app/PhotoPage.java
@@ -303,7 +303,7 @@
                                 mMediaSet.getMediaItemCount() > 1) {
                             mPhotoView.switchToImage(1);
                         } else {
-                            mPhotoView.setFilmMode(false);
+                            mPhotoView.setFilmMode(mPhotoView.canUndo());
                             stayedOnCamera = true;
                         }
 
diff --git a/src/com/android/gallery3d/ui/PhotoView.java b/src/com/android/gallery3d/ui/PhotoView.java
index 3fa13cf..7097dff 100644
--- a/src/com/android/gallery3d/ui/PhotoView.java
+++ b/src/com/android/gallery3d/ui/PhotoView.java
@@ -630,7 +630,7 @@
             if ((mHolding & ~HOLD_TOUCH_DOWN) != 0) return;
 
             if (mWantPictureCenterCallbacks && mPositionController.isCenter()) {
-                mListener.onPictureCenter(mIsCamera && !canUndoLastPicture());
+                mListener.onPictureCenter(mIsCamera);
             }
         }
 
@@ -1375,13 +1375,8 @@
         }
     }
 
-    // Returns true if the user can still undo the deletion of the last
-    // remaining picture in the album. We need to check this and delay making
-    // the camera preview full screen, otherwise the user won't have a chance to
-    // undo it.
-    private boolean canUndoLastPicture() {
-        if ((mUndoBarState & UNDO_BAR_SHOW) == 0) return false;
-        return (mUndoBarState & UNDO_BAR_DELETE_LAST) != 0;
+    public boolean canUndo() {
+        return (mUndoBarState & UNDO_BAR_SHOW) != 0;
     }
 
     ////////////////////////////////////////////////////////////////////////////