Acknowledged

Touch events delivered to apps even when touchscreen is disabled

Hi Garmin Connect IQ Team,

Currently, there is no reliable way for an app to detect whether the device’s touchscreen is disabled (for example when the user has turned touch off in settings or enabled touch lock during an activity). The existing System.getDeviceSettings() properties like isTouchScreen and isTouchScreenActive only indicate hardware capability and not whether touch input is enabled or locked. As a result, even when the user has disabled touch, the app continues to receive and respond to touch events, which can lead to unintended interactions in sport/activity contexts.

This affects apps that rely on buttons and should respect the user’s preference or device lock during activities.

For example, for my app "Hyrox Smash", in a sweaty condition, it's quite risky to have the touch screen enabled. 

If there’s already a recommended approach I’ve missed, I’d be happy to hear about it. Otherwise, I’d appreciate you considering this enhancement for future SDK versions.

Thanks for your time and support.

Cheers,

Saeed from Multipassionate

Parents
  • Hi Richard,

    Such a hero! Thanks for your help. It's very much appreciated. Disabling or enabling all the touch events works like a charm. 

    I put this as a trial option, and it works:

    if (WatchUi has :configureTouchEvents) {

                WatchUi.configureTouchEvents({

                    :enabled => false

                });

                //System.println("Touch has been programmatically disabled.");

            }

    However, the WatchUi.getTouchEventsConfiguration(); seems always to return true, regardless of the touch screen settings on the watch. The watch always shows CONF: Enabled, unless I change it via the option above.

    var touchStatusText = "Config: Unsupported";

    if (WatchUi has :getTouchEventsConfiguration) {
           var config = WatchUi.getTouchEventsConfiguration();

           if (config != null && config.hasKey(:enabled)) {
                  var isEnabled = config[:enabled];

                  touchStatusText = (isEnabled == true) ? "CONF: ENABLED" : "CONF: DISABLED";
           } else {
                 touchStatusText = "Config: Key Missing";
           }
    }

    I've got a Forerunner 965, and it runs on the latest firmware.

Comment
  • Hi Richard,

    Such a hero! Thanks for your help. It's very much appreciated. Disabling or enabling all the touch events works like a charm. 

    I put this as a trial option, and it works:

    if (WatchUi has :configureTouchEvents) {

                WatchUi.configureTouchEvents({

                    :enabled => false

                });

                //System.println("Touch has been programmatically disabled.");

            }

    However, the WatchUi.getTouchEventsConfiguration(); seems always to return true, regardless of the touch screen settings on the watch. The watch always shows CONF: Enabled, unless I change it via the option above.

    var touchStatusText = "Config: Unsupported";

    if (WatchUi has :getTouchEventsConfiguration) {
           var config = WatchUi.getTouchEventsConfiguration();

           if (config != null && config.hasKey(:enabled)) {
                  var isEnabled = config[:enabled];

                  touchStatusText = (isEnabled == true) ? "CONF: ENABLED" : "CONF: DISABLED";
           } else {
                 touchStatusText = "Config: Key Missing";
           }
    }

    I've got a Forerunner 965, and it runs on the latest firmware.

Children
No Data