From a663b89665dc3b6146d1733128c307677df5d2ee Mon Sep 17 00:00:00 2001 From: tibbi Date: Tue, 5 Sep 2017 15:14:44 +0200 Subject: [PATCH] do not trigger the brightness and volume slider so agressively --- .../com/simplemobiletools/gallery/fragments/VideoFragment.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/fragments/VideoFragment.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/fragments/VideoFragment.kt index 47c8f93b6..a2762d99a 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/fragments/VideoFragment.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/fragments/VideoFragment.kt @@ -154,7 +154,7 @@ class VideoFragment : ViewPagerFragment(), SurfaceHolder.Callback, SeekBar.OnSee val diffX = mTouchDownX - event.x val diffY = mTouchDownY - event.y - if (Math.abs(diffY) > Math.abs(diffX)) { + if (Math.abs(diffY) > 20 && Math.abs(diffY) > Math.abs(diffX)) { var percent = ((diffY / ViewPagerActivity.screenHeight) * 100).toInt() * 3 percent = Math.min(100, Math.max(-100, percent)) @@ -190,7 +190,7 @@ class VideoFragment : ViewPagerFragment(), SurfaceHolder.Callback, SeekBar.OnSee val diffX = mTouchDownX - event.x val diffY = mTouchDownY - event.y - if (Math.abs(diffY) > Math.abs(diffX)) { + if (Math.abs(diffY) > 20 && Math.abs(diffY) > Math.abs(diffX)) { var percent = ((diffY / ViewPagerActivity.screenHeight) * 100).toInt() * 3 percent = Math.min(100, Math.max(-100, percent))