summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAngus Kong <shkong@google.com>2013-09-06 17:39:28 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2013-09-06 17:39:28 -0700
commit31ee75ce69df47e13e8125923caee634678f9ec7 (patch)
treeb761f4929dba999f2cf56ebc9dfe074d4e87669e
parente9dba8accf223071007175c1b81ce04ee0760c01 (diff)
parenta71946012df0eee8fe4859a22da3c56feba0344e (diff)
downloadandroid_packages_apps_Snap-31ee75ce69df47e13e8125923caee634678f9ec7.tar.gz
android_packages_apps_Snap-31ee75ce69df47e13e8125923caee634678f9ec7.tar.bz2
android_packages_apps_Snap-31ee75ce69df47e13e8125923caee634678f9ec7.zip
am a7194601: Disable swipe in capture intent mode.
* commit 'a71946012df0eee8fe4859a22da3c56feba0344e': Disable swipe in capture intent mode.
-rw-r--r--src/com/android/camera/CameraActivity.java16
1 files changed, 14 insertions, 2 deletions
diff --git a/src/com/android/camera/CameraActivity.java b/src/com/android/camera/CameraActivity.java
index 7b127fa4d..384b8bf3b 100644
--- a/src/com/android/camera/CameraActivity.java
+++ b/src/com/android/camera/CameraActivity.java
@@ -742,7 +742,9 @@ public class CameraActivity extends Activity
if (!mSecureCamera) {
mDataAdapter = mWrappedDataAdapter;
mFilmStripView.setDataAdapter(mDataAdapter);
- mDataAdapter.requestLoad(getContentResolver());
+ if (!isCaptureIntent()) {
+ mDataAdapter.requestLoad(getContentResolver());
+ }
} else {
// Put a lock placeholder as the last image by setting its date to 0.
ImageView v = (ImageView) getLayoutInflater().inflate(
@@ -1043,8 +1045,18 @@ public class CameraActivity extends Activity
public void onShowSwitcherPopup() {
}
+ /**
+ * Enable/disable swipe-to-filmstrip.
+ * Will always disable swipe if in capture intent.
+ *
+ * @param enable {@code true} to enable swipe.
+ */
public void setSwipingEnabled(boolean enable) {
- mCameraPreviewData.lockPreview(!enable);
+ if (isCaptureIntent()) {
+ mCameraPreviewData.lockPreview(true);
+ } else {
+ mCameraPreviewData.lockPreview(!enable);
+ }
}
// Accessor methods for getting latency times used in performance testing