1. #1
    Sencha User
    Join Date
    Sep 2011
    Location
    Boston
    Posts
    145
    Vote Rating
    6
    Answers
    5
    drb is on a distinguished road

      0  

    Default Unanswered: Any way to Reduce TouchMove sensitivity so Itemtaphold fires more reliably?

    Unanswered: Any way to Reduce TouchMove sensitivity so Itemtaphold fires more reliably?


    Touch 2.1.0-rc2

    Is there any way to reduce the sensitivity of TouchMove?

    I am using itemtaphold on Ext.List and it is very hard for the user to hold a finger still enough on an iPad 3 to register an itemtaphold. It seems that the touch move event gets fired at the slightest jiggle.

    Thanks
    David

  2. #2
    Sencha User
    Join Date
    Sep 2011
    Location
    Boston
    Posts
    145
    Vote Rating
    6
    Answers
    5
    drb is on a distinguished road

      0  

    Default


    I have tried the following, but I don't know if it is really safe.

    The idea is to ignore finger movement of less than 5 in any direction.
    Code:
            Ext.define('Ext.overrides.event.recognizer.LongPress', {
                override: 'Ext.event.recognizer.LongPress',
                onTouchMove: function (e) {
                    if (e.absDeltaX < 5 && e.absDeltaY < 5) {
                        return;
                    }
                    return this.fail(this.self.TOUCH_MOVED);
                }
            });