mirror of
https://github.com/Mottie/tablesorter.git
synced 2025-01-12 15:24:21 +00:00
Core: make core compatible with jQuery v1.2.6 again
This commit is contained in:
parent
b425a715bf
commit
5263aa75ae
@ -11,8 +11,8 @@
|
|||||||
* @type jQuery
|
* @type jQuery
|
||||||
* @name tablesorter (FORK)
|
* @name tablesorter (FORK)
|
||||||
* @cat Plugins/Tablesorter
|
* @cat Plugins/Tablesorter
|
||||||
* @author Christian Bach/christian.bach@polyester.se
|
* @author Christian Bach - christian.bach@polyester.se
|
||||||
* @contributor Rob Garrison/https://github.com/Mottie/tablesorter
|
* @contributor Rob Garrison - https://github.com/Mottie/tablesorter
|
||||||
*/
|
*/
|
||||||
/*jshint browser:true, jquery:true, unused:false, expr: true */
|
/*jshint browser:true, jquery:true, unused:false, expr: true */
|
||||||
/*global console:false, alert:false, require:false, define:false, module:false */
|
/*global console:false, alert:false, require:false, define:false, module:false */
|
||||||
@ -1342,9 +1342,10 @@
|
|||||||
// set timer on mousedown
|
// set timer on mousedown
|
||||||
if (type === 'mousedown') {
|
if (type === 'mousedown') {
|
||||||
downTime = new Date().getTime();
|
downTime = new Date().getTime();
|
||||||
|
cell = $.fn.closest ? $(e.target).closest('td,th') : $(e.target).parents('td,th').filter(':first');
|
||||||
return /(input|select|button|textarea)/i.test(e.target.tagName) ||
|
return /(input|select|button|textarea)/i.test(e.target.tagName) ||
|
||||||
// allow clicks to contents of selected cells
|
// allow clicks to contents of selected cells
|
||||||
$(e.target).closest('td,th').hasClass(c.cssAllowClicks) ? '' : !c.cancelSelection;
|
cell.hasClass(c.cssAllowClicks) ? '' : !c.cancelSelection;
|
||||||
}
|
}
|
||||||
if (c.delayInit && isEmptyObject(c.cache)) { buildCache(table); }
|
if (c.delayInit && isEmptyObject(c.cache)) { buildCache(table); }
|
||||||
// jQuery v1.2.6 doesn't have closest()
|
// jQuery v1.2.6 doesn't have closest()
|
||||||
|
Loading…
Reference in New Issue
Block a user