From 145b61a5b2e762b80695e97b22274c7d32c02656 Mon Sep 17 00:00:00 2001 From: Owen Lin Date: Thu, 25 Jun 2009 11:12:11 -0700 Subject: [PATCH] Retry to submit it again. It seems I changed the file "IImage" -> "Image" before I create the commit. --- src/com/android/camera/ViewImage.java | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/com/android/camera/ViewImage.java b/src/com/android/camera/ViewImage.java index af17ca8..ab12fac 100644 --- a/src/com/android/camera/ViewImage.java +++ b/src/com/android/camera/ViewImage.java @@ -176,6 +176,7 @@ public class ViewImage extends Activity implements View.OnClickListener { } private void showOnScreenControls(final boolean autoDismiss) { + if (mPaused) return; // If the view has not been attached to the window yet, the // zoomButtonControls will not able to show up. So delay it until the // view has attached to window. @@ -1109,6 +1110,14 @@ public class ViewImage extends Activity implements View.OnClickListener { // The CropImage activity passes back the Uri of the // cropped image as the Action rather than the Data. mSavedUri = Uri.parse(data.getAction()); + + // if onStart() runs before, then set the returned + // image as currentImage. + if (mAllImages != null) { + IImage image = mAllImages.getImageForUri(mSavedUri); + mCurrentPosition = mAllImages.getImageIndex(image); + setImage(mCurrentPosition); + } } break; } -- 2.11.0