Selection is active on click, not mousedown

This commit is contained in:
Romain Neutron
2011-12-27 19:18:11 +01:00
parent 069ec209aa
commit 458dc822ec

View File

@@ -34,7 +34,7 @@
jQuery($container).addClass('selectionnable'); jQuery($container).addClass('selectionnable');
jQuery(this.options.selector, $container) jQuery(this.options.selector, $container)
.live('mousedown', function(event){ .live('click', function(event){
if(typeof $this.options.selectStart === 'function') if(typeof $this.options.selectStart === 'function')
{ {
@@ -66,7 +66,8 @@
$.each(jQuery(exp, $container),function(i,n){ $.each(jQuery(exp, $container),function(i,n){
if(!jQuery(n).hasClass('selected')) if(!jQuery(n).hasClass('selected'))
{ {
$this.push(jQuery(n).attr('id').split('_').slice(2,4).join('_')); var k = get_value(jQuery(n), $this);
$this.push(k);
jQuery(n).addClass('selected'); jQuery(n).addClass('selected');
} }
}); });