summaryrefslogtreecommitdiffstats
path: root/src/com/android/camera/FocusManager.java
diff options
context:
space:
mode:
authorSundar Raman <sunds@ti.com>2011-08-24 20:32:36 -0700
committerWu-cheng Li <wuchengli@google.com>2011-08-25 22:05:31 +0800
commit5d4972e63a1f81139c6503fd433f06c77276fc38 (patch)
treea1d60acd7fd6f45ae1e796a08bad79fd3f28a9aa /src/com/android/camera/FocusManager.java
parent76826f41f73ad1474d6a680cf9a9a1f389c018b7 (diff)
downloadLegacyCamera-5d4972e63a1f81139c6503fd433f06c77276fc38.zip
LegacyCamera-5d4972e63a1f81139c6503fd433f06c77276fc38.tar.gz
LegacyCamera-5d4972e63a1f81139c6503fd433f06c77276fc38.tar.bz2
Reset the touch AF before calling cancelAutoFocus
If touch AF is reset after cancelAutoFocus then the AF mode stays at auto and also the touch region passed to the driver doesnt get reset. Change-Id: I6bc4241c1fde104e41315e065aaa70489cc7a197 Signed-off-by: Sundar Raman <sunds@ti.com>
Diffstat (limited to 'src/com/android/camera/FocusManager.java')
-rw-r--r--src/com/android/camera/FocusManager.java6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/com/android/camera/FocusManager.java b/src/com/android/camera/FocusManager.java
index 2c8b66f..94093e6 100644
--- a/src/com/android/camera/FocusManager.java
+++ b/src/com/android/camera/FocusManager.java
@@ -297,10 +297,14 @@ public class FocusManager {
private void cancelAutoFocus() {
Log.v(TAG, "Cancel autofocus.");
+
+ // Reset the tap area before calling mListener.cancelAutofocus.
+ // Otherwise, focus mode stays at auto and the tap area passed to the
+ // driver is not reset.
+ resetTouchFocus();
mListener.cancelAutoFocus();
if (mFaceView != null) mFaceView.resume();
mState = STATE_IDLE;
- resetTouchFocus();
updateFocusUI();
mHandler.removeMessages(RESET_TOUCH_FOCUS);
}