I notice that some Garmin Apps on the F7/Epix Gen2 range display the ability to turn off the touch screen:
Is that functionality available in the Toybox API?
I notice that some Garmin Apps on the F7/Epix Gen2 range display the ability to turn off the touch screen:
Is that functionality available in the Toybox API?
If i swipe left on Fenix7, input test app from SDK shows that input is KEY_ESC :( which obviously i wont disable
Hmm, I assume that's the unmodified Input sample on the real device? That doesn't happen in the sim. I do get onBack for right swipe. (onBack is also associated with the back button, which also triggers KEY_ESC.)
So I noticed that in the input sample (on the sim), even though onSwipe() returns true, the corresponding behaviors for the various swipes are still triggered (onBack, onNextPage, onPreviousPage).
So I was wrong, you can't just return true from all the touch handlers in order to "ignore touch". Sorry about that!
If you really want to "disable touch", I think you would have to avoid using behavior handlers such as onNextPage() and only use onKey(). Except even that wouldn't work if any touches actually trigger onKey on a real device (which I would consider a bug).
And that would probably be a major refactor, plus it could present problems on old or obscure devices with weird key mappings.
Sorry for the bad advice! I should've tried the input sample.
So I'll do a 180 and agree with all of the ppl in this thread who would like the ability for CIQ apps to explicitly disable touch.
I do wonder if it's a bug that returning true from various touch handlers doesn't cause the corresponding behavior or key handler to be skipped. Because last time I checked, if you handle a key, the corresponding behavior handler is not called.
I meant swipe rgiht... sorry.. My goal is to avoid going back when water hits screen (as it is happening at the moment). Thus i ended up with solution (not a clean one.....)
I made this TouchAwareBehaviorDelegate gist: https://gist.github.com/flocsy/40f4d1082187a35336f3c4813e1ddccc
You'll get the idea and if you need more actions you can easily add them.