jquery-archive / jquery-mobile

jQuery Mobile Framework
https://jquerymobile.com
Other
9.68k stars 2.4k forks source link

Is tapholdThreshold working as intended? #4628

Closed jahvi closed 11 years ago

jahvi commented 12 years ago

I was playing around with the 1.2.0 Pre version and noticed that changing the $.event.special.tap.tapholdThreshold default wasn't working as I thought it would, for example if I set it to 2000ms the binded event would fire after 2s of holding the element no matter if I just held it for a bit.

I thought it'd behave like the hoverIntent plugin so the event would fire only if you hold the element for at least 2s. Looking at the code it looks like it's intended to behave like that since it just uses the setTimeout function, is there a reason for this?

jaspermdegroot commented 12 years ago

@javiervd

Thanks for reporting. You are right that it is supposed to behave like that. So this sounds like a bug we have to look into.

arschmitz commented 11 years ago

this is fixed by commit 3ba4a42d56754314d38792ca2c1b21d39eace3f8