|
2 | 2 | * jQuery Mobile Events |
3 | 3 | * by Ben Major |
4 | 4 | * |
5 | | - * Copyright 2011-2017, Ben Major |
| 5 | + * Copyright 2011-2019, Ben Major |
6 | 6 | * Licensed under the MIT License: |
7 | 7 | * |
8 | 8 | * Permission is hereby granted, free of charge, to any person obtaining a copy |
|
247 | 247 | varele_threshold=($this.parent().data('threshold')) ?$this.parent().data('threshold') :$this.data('threshold'), |
248 | 248 | threshold=(typeofele_threshold!=='undefined'&&ele_threshold!==false&&parseInt(ele_threshold)) ?parseInt(ele_threshold) :settings.taphold_threshold; |
249 | 249 |
|
250 | | -settings.hold_timer=window.setTimeout(function(){ |
| 250 | +$this.data('hold_timer',window.setTimeout(function(){ |
251 | 251 |
|
252 | 252 | vardiff_x=(start_pos.x-end_x), |
253 | 253 | diff_y=(start_pos.y-end_y); |
|
286 | 286 |
|
287 | 287 | triggerCustomEvent(thisObject,evt_name,e,touchData); |
288 | 288 | } |
289 | | -},threshold); |
| 289 | +},threshold)); |
290 | 290 |
|
291 | 291 | returntrue; |
292 | 292 | } |
293 | 293 | }).on(settings.endevent,functiontapHoldFunc2(){ |
294 | 294 | $this.data('callee2',tapHoldFunc2); |
295 | 295 | $this.data('tapheld',false); |
296 | | -window.clearTimeout(settings.hold_timer); |
| 296 | +window.clearTimeout($this.data('hold_timer')); |
297 | 297 | }) |
298 | 298 | .on(settings.moveevent,functiontapHoldFunc3(e){ |
299 | 299 | $this.data('callee3',tapHoldFunc3); |
|