diff options
author | Wu-cheng Li <wuchengli@google.com> | 2011-10-28 00:22:04 +0800 |
---|---|---|
committer | Wu-cheng Li <wuchengli@google.com> | 2011-10-28 00:40:08 +0800 |
commit | 30e2c49eedfbce51be7458161829a750f809d56d (patch) | |
tree | e6e9c1496df8a3659fd0c9a04cd40c4121a7d118 /src/com/android/camera/FocusManager.java | |
parent | c04d01bb510465ea35a06b09146a3bb79c6f770e (diff) | |
download | LegacyCamera-30e2c49eedfbce51be7458161829a750f809d56d.zip LegacyCamera-30e2c49eedfbce51be7458161829a750f809d56d.tar.gz LegacyCamera-30e2c49eedfbce51be7458161829a750f809d56d.tar.bz2 |
Remove long pressing shutter triggers autocous.
autoFocus behavior has changed in CAF. The focus callback
will not return immediately if CAF is scanning. There is
no need to have long pressing behavior.
bug:5514415
Change-Id: Iacf14fa3ad48b03c79122296a74e7511c41ea62f
Diffstat (limited to 'src/com/android/camera/FocusManager.java')
-rw-r--r-- | src/com/android/camera/FocusManager.java | 23 |
1 files changed, 1 insertions, 22 deletions
diff --git a/src/com/android/camera/FocusManager.java b/src/com/android/camera/FocusManager.java index 86b92c2..72ea8b5 100644 --- a/src/com/android/camera/FocusManager.java +++ b/src/com/android/camera/FocusManager.java @@ -56,7 +56,6 @@ public class FocusManager { private boolean mInitialized; private boolean mFocusAreaSupported; - private boolean mInLongPress; private boolean mLockAeAwbNeeded; private boolean mAeAwbLock; private Matrix mMatrix; @@ -174,22 +173,6 @@ public class FocusManager { } } - public void shutterLongPressed() { - if (Parameters.FOCUS_MODE_CONTINUOUS_PICTURE.equals(mFocusMode) - && isSupported(Parameters.FOCUS_MODE_AUTO, mParameters.getSupportedFocusModes())) { - if (mState == STATE_IDLE || mState == STATE_FOCUSING_SNAP_ON_FINISH) { - Log.e(TAG, "Invalid focus state=" + mState); - } - mInLongPress = true; - // Cancel any outstanding Auto focus requests. The auto focus mode - // will be changed from CAF to auto in cancelAutoFocus. - onShutterUp(); - // Call Autofocus - onShutterDown(); - mInLongPress = false; - } - } - public void doSnap() { if (!mInitialized) return; @@ -379,11 +362,7 @@ public class FocusManager { public String getFocusMode() { if (mOverrideFocusMode != null) return mOverrideFocusMode; - if (mInLongPress) { - // Users long-press the shutter button in CAF. Change it to auto - // mode, so it will do a full scan. - mFocusMode = Parameters.FOCUS_MODE_AUTO; - } else if (mFocusAreaSupported && mFocusArea != null) { + if (mFocusAreaSupported && mFocusArea != null) { // Always use autofocus in tap-to-focus. mFocusMode = Parameters.FOCUS_MODE_AUTO; } else { |