mirror of
https://github.com/FossifyOrg/Gallery.git
synced 2024-11-26 22:47:59 +01:00
make zooming in and out a bit easier
This commit is contained in:
parent
b02f0ad8fb
commit
9e9d164f9f
1 changed files with 2 additions and 2 deletions
|
@ -36,8 +36,8 @@ class MyScalableRecyclerView : RecyclerView {
|
||||||
}
|
}
|
||||||
|
|
||||||
class GestureListener : ScaleGestureDetector.SimpleOnScaleGestureListener() {
|
class GestureListener : ScaleGestureDetector.SimpleOnScaleGestureListener() {
|
||||||
val ZOOM_IN_THRESHOLD = -0.7f
|
val ZOOM_IN_THRESHOLD = -0.6f
|
||||||
val ZOOM_OUT_THRESHOLD = 0.3f
|
val ZOOM_OUT_THRESHOLD = 0.25f
|
||||||
|
|
||||||
override fun onScale(detector: ScaleGestureDetector): Boolean {
|
override fun onScale(detector: ScaleGestureDetector): Boolean {
|
||||||
if (System.currentTimeMillis() - mLastUp < 1000)
|
if (System.currentTimeMillis() - mLastUp < 1000)
|
||||||
|
|
Loading…
Reference in a new issue