diff options
author | Chih-Chung Chang <chihchung@google.com> | 2012-09-06 20:02:09 +0800 |
---|---|---|
committer | Chih-Chung Chang <chihchung@google.com> | 2012-09-11 19:50:29 +0800 |
commit | 1a980d945c8715de18bdbe6406599503d812185f (patch) | |
tree | 1a82aef8daf26280ae907cb53628d2566af5aad6 /src/com | |
parent | 4e19aebb22c40beb18ed9b5e8d4c0a07e205674e (diff) | |
download | android_packages_apps_Snap-1a980d945c8715de18bdbe6406599503d812185f.tar.gz android_packages_apps_Snap-1a980d945c8715de18bdbe6406599503d812185f.tar.bz2 android_packages_apps_Snap-1a980d945c8715de18bdbe6406599503d812185f.zip |
Do not accept fling gesture after we changed from/to filmstrip mode.
Change-Id: Ifb3d692bcf621ff02c6d4e6d91ba8484d702f905
Diffstat (limited to 'src/com')
-rw-r--r-- | src/com/android/gallery3d/ui/PhotoView.java | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/com/android/gallery3d/ui/PhotoView.java b/src/com/android/gallery3d/ui/PhotoView.java index 932173f7c..c31546b6b 100644 --- a/src/com/android/gallery3d/ui/PhotoView.java +++ b/src/com/android/gallery3d/ui/PhotoView.java @@ -938,8 +938,6 @@ public class PhotoView extends GLView { private boolean mModeChanged; // If this scaling gesture should be ignored. private boolean mIgnoreScalingGesture; - // If we have seen a scaling gesture. - private boolean mSeenScaling; // whether the down action happened while the view is scrolling. private boolean mDownInScrolling; // If we should ignore all gestures other than onSingleTapUp. @@ -1057,7 +1055,7 @@ public class PhotoView extends GLView { @Override public boolean onFling(float velocityX, float velocityY) { if (mIgnoreSwipingGesture) return true; - if (mSeenScaling) return true; + if (mModeChanged) return true; if (swipeImages(velocityX, velocityY)) { mIgnoreUpEvent = true; } else { @@ -1128,8 +1126,6 @@ public class PhotoView extends GLView { // mode and at minimal scale. mCanChangeMode = mFilmMode || mPositionController.isAtMinimalScale(); - mModeChanged = false; - mSeenScaling = true; mAccScale = 1f; return true; } @@ -1206,7 +1202,7 @@ public class PhotoView extends GLView { checkHideUndoBar(UNDO_BAR_TOUCHED); mDeltaY = 0; - mSeenScaling = false; + mModeChanged = false; if (mIgnoreSwipingGesture) return; |