Results 1 to 2 of 2

Thread: Swipe left right very narrow on x-axis

  1. #1
    Sencha Premium Member
    Join Date
    Aug 2008
    Posts
    209
    Answers
    4
    Vote Rating
    4
      0  

    Default Answered: Swipe left right very narrow on x-axis

    Hi,

    I have an issue with the swipe left & right. When swiping horizontally it the threshold is quite narrow. What would I have to override there to extend it more along the y-axis?

    some users are swiping from left down to right up and miss the framework 'misses'/ignores the swipe that way.

    I tried to overwrite Ext.event.recognizer.Swipe directly in the sencha-touch-all-debug.js and this worked once I set the values to:

    config: {
    minDistance: 50, // 80
    maxOffset: 400, //35
    maxDuration: 1000
    },

    is there any better way to do that within the code and not editing the source file directly? Via Ext.override or extend?

    thanks,
    Alex

  2. You may subscribe on swipe event and check in function-listener distance or duration

    Code:
    onSwipe: function(e) {
       if (e.distance > 200) {
           //My code
       }
    }

  3. #2
    Sencha User
    Join Date
    May 2012
    Posts
    32
    Answers
    2
    Vote Rating
    1
      0  

    Default

    You may subscribe on swipe event and check in function-listener distance or duration

    Code:
    onSwipe: function(e) {
       if (e.distance > 200) {
           //My code
       }
    }

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •