Detect whether "all" swipe is up or down?

14 views
Skip to first unread message

nmyshkin

unread,
Mar 13, 2023, 1:49:26 PM3/13/23
to Tasker
I'm trying to implement a gesture/swipe control for the reading light on an e-ink device. The plan is to have a narrow invisible rectangle along the left side of the screen which is a swipe zone (shown in image below but temporarily colored during development).screenshot_2023_03_13_10.12.jpg
The device is not very good at swipes or scrolls but I've managed to get a reasonably good response with a minimum swipe of "1". The problem is that what I really need is a slider, but that can't be invisible. Hence I have two swipe zones, one for "up" and one for "down" to change the intensity of the light.

The zones have to be wide enough or the device just can't catch the swipe, but the left side of the screen is also used for touch input to go to the previous page so I can't make the zones too wide or they get in the way. Ideally I would like to have ONE zone that can both increase and decrease the light intensity depending on the swipe direction. The "
all" option for swipe doesn't distinguish between up or down.

Is there some way to detect the direction of the swipe (adb shell?) which won't completely bog down the routine?

Just to keep potential responses in the realm of possibilities, the device is running Android 2.1 and I'm using a very old version of Tasker, so no fancy plugins, etc. The approach has to be pretty basic.

nmyshkin

unread,
Mar 13, 2023, 2:47:19 PM3/13/23
to Tasker
Got it! Thank goodness for %stroke_dir!!!
Reply all
Reply to author
Forward
0 new messages