[Android] Video player: Disable quick scale gesture

Geoffrey Métais git at videolan.org
Tue Apr 17 14:38:48 CEST 2018


vlc-android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Tue Apr 17 14:38:24 2018 +0200| [89bfb4dcc14345af152c76340f5ca8248392176f] | committer: Geoffrey Métais

Video player: Disable quick scale gesture

> https://code.videolan.org/videolan/vlc-android/commit/89bfb4dcc14345af152c76340f5ca8248392176f
---

 vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java b/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
index 3190c1684..7831c1a45 100644
--- a/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
+++ b/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
@@ -59,6 +59,7 @@ import android.support.design.widget.Snackbar;
 import android.support.v4.app.FragmentManager;
 import android.support.v4.content.LocalBroadcastManager;
 import android.support.v4.view.GestureDetectorCompat;
+import android.support.v4.view.ScaleGestureDetectorCompat;
 import android.support.v4.view.ViewCompat;
 import android.support.v7.app.ActionBar;
 import android.support.v7.app.AlertDialog;
@@ -2038,8 +2039,10 @@ public class VideoPlayerActivity extends AppCompatActivity implements IVLCVout.C
             mDetector = new GestureDetectorCompat(this, mGestureListener);
             mDetector.setOnDoubleTapListener(mGestureListener);
         }
-        if (mScaleGestureDetector == null)
+        if (mScaleGestureDetector == null) {
             mScaleGestureDetector = new ScaleGestureDetector(this, mScaleListener);
+            ScaleGestureDetectorCompat.setQuickScaleEnabled(mScaleGestureDetector, false);
+        }
         if (mPlaybackSetting != DelayState.OFF) {
             if (event.getAction() == MotionEvent.ACTION_UP) endPlaybackSetting();
             return true;



More information about the Android mailing list