diff options
-rw-r--r-- | src/com/android/camera/PhotoModule.java | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/com/android/camera/PhotoModule.java b/src/com/android/camera/PhotoModule.java index d5bdfd012..0e0ab1f40 100644 --- a/src/com/android/camera/PhotoModule.java +++ b/src/com/android/camera/PhotoModule.java @@ -166,6 +166,7 @@ public class PhotoModule private static final int SWITCH_TO_GCAM_MODULE = 12; private static final int ON_PREVIEW_STARTED = 13; private static final int INSTANT_CAPTURE = 14; + private static final int UNLOCK_CAM_SHUTTER = 15; private static final int NO_DEPTH_EFFECT = 0; private static final int DEPTH_EFFECT_SUCCESS = 1; @@ -568,6 +569,11 @@ public class PhotoModule onShutterButtonClick(); break; } + + case UNLOCK_CAM_SHUTTER: { + mUI.enableShutter(true); + break; + } } } } @@ -1949,10 +1955,12 @@ public class PhotoModule mPreviewRestartSupport &= PIXEL_FORMAT_JPEG.equalsIgnoreCase( pictureFormat); + mUI.enableShutter(false); + // We don't want user to press the button again while taking a // multi-second HDR photo. For longshot, no need to disable. - if (CameraUtil.SCENE_MODE_HDR.equals(mSceneMode)) { - mUI.enableShutter(false); + if (!CameraUtil.SCENE_MODE_HDR.equals(mSceneMode)) { + mHandler.sendEmptyMessageDelayed(UNLOCK_CAM_SHUTTER, 120); } if (!isShutterSoundOn()) { |