You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* @param contentDescription text for accessibility see [Image] for further info
24
24
* @param onSwipeLeft Optional function to run when user swipes from right to left - does nothing by default
25
25
* @param onSwipeRight Optional function to run when user swipes from left to right - does nothing by default
26
+
* @param dragGesturesEnabled A function with a [ZoomableState] scope that returns a boolean value to enable/disable dragging gestures (swiping and panning). Returns `true` by default. *Note*: For some use cases it may be required that only panning is possible. Use `{!notTransformed}` in that case
26
27
* @param onDoubleTap Optional function to run when user double taps. Zooms in by 2x when scale is currently 1 and zooms out to scale = 1 when zoomed in when null (default)
* @param contentDescription text for accessibility see [Image] for further info
58
61
* @param onSwipeLeft Optional function to run when user swipes from right to left - does nothing by default
59
62
* @param onSwipeRight Optional function to run when user swipes from left to right - does nothing by default
63
+
* @param dragGesturesEnabled A function with a [ZoomableState] scope that returns a boolean value to enable/disable dragging gestures (swiping and panning). Returns `true` by default. *Note*: For some use cases it may be required that only panning is possible. Use `{!notTransformed}` in that case
60
64
* @param onDoubleTap Optional function to run when user double taps. Zooms in by 2x when scale is currently 1 and zooms out to scale = 1 when zoomed in when null (default)
* @param contentDescription text for accessibility see [Image] for further info
96
102
* @param onSwipeLeft Optional function to run when user swipes from right to left - does nothing by default
97
103
* @param onSwipeRight Optional function to run when user swipes from left to right - does nothing by default
104
+
* @param dragGesturesEnabled A function with a [ZoomableState] scope that returns a boolean value to enable/disable dragging gestures (swiping and panning). Returns `true` by default. *Note*: For some use cases it may be required that only panning is possible. Use `{!notTransformed}` in that case
98
105
* @param onDoubleTap Optional function to run when user double taps. Zooms in by 2x when scale is currently 1 and zooms out to scale = 1 when zoomed in when null (default)
Copy file name to clipboardExpand all lines: zoomables/src/main/kotlin/de/mr_pine/zoomables/Zoomables.kt
+35-31Lines changed: 35 additions & 31 deletions
Original file line number
Diff line number
Diff line change
@@ -34,16 +34,18 @@ import kotlin.math.*
34
34
*
35
35
* @param coroutineScope used for smooth asynchronous zoom/pan/rotation animations
36
36
* @param zoomableState Contains the current transform states - obtained via [rememberZoomableState]
37
+
* @param dragGesturesEnabled A function with a [ZoomableState] scope that returns a boolean value to enable/disable dragging gestures (swiping and panning). Returns `true` by default. *Note*: For some use cases it may be required that only panning is possible. Use `{!notTransformed}` in that case
37
38
* @param onSwipeLeft Optional function to run when user swipes from right to left - does nothing by default
38
39
* @param onSwipeRight Optional function to run when user swipes from left to right - does nothing by default
39
40
* @param minimumSwipeDistance Minimum distance the user has to travel on the screen for it to count as swiping
40
-
* @param onDoubleTap Optional function to run when user double taps. Zooms in by 2x to the touch point when scale is currently 1 and zooms out to scale = 1 when zoomed in when null (default)
41
+
* @param onDoubleTap Optional function to run when user double taps. Zooms in by 2x to the touch point when scale is currently 1 and zooms out to scale = 1 when zoomed in when `null` (default)
0 commit comments