From 2c854bb917480b69630c9ab01aa9247df57a564a Mon Sep 17 00:00:00 2001 From: Wu-cheng Li Date: Fri, 30 Oct 2009 17:18:23 +0800 Subject: Fix the bug that wrong zoom value is set in takePicture. The application does not getParameters in takePicture due to performance. After smooth zoom, zoom value has been changed. But mParameters of the app still keeps the the old value. This is a regression. b2226717 --- src/com/android/camera/Camera.java | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/com/android/camera/Camera.java') diff --git a/src/com/android/camera/Camera.java b/src/com/android/camera/Camera.java index 1e30ca0..ddb6611 100644 --- a/src/com/android/camera/Camera.java +++ b/src/com/android/camera/Camera.java @@ -666,6 +666,9 @@ public class Camera extends Activity implements View.OnClickListener, Log.v(TAG, "ZoomCallback: zoom value=" + zoomValue + ". stopped=" + stopped); mZoomValue = zoomValue; + // Keep mParameters up to date. We do not getParameter again in + // takePicture. If we do not do this, wrong zoom value will be set. + mParameters.setZoom(zoomValue); // We only care if the zoom is stopped. mZooming is set to true when // we start smooth zoom. if (stopped) mZooming = false; -- cgit v1.1