mirror of
https://github.com/jquery/jquery-ui.git
synced 2024-10-05 01:44:18 +00:00
Draggable: Removed ridiculousness (some of it anyway).
This commit is contained in:
parent
57f0188239
commit
0c8eed67f5
@ -439,12 +439,8 @@ $.ui.plugin.add("draggable", "connectToSortable", {
|
||||
var inst = $(this).data("draggable"), o = inst.options;
|
||||
inst.sortables = [];
|
||||
$(o.connectToSortable).each(function() {
|
||||
// 'this' points to a string, and should therefore resolved as query, but instead, if the string is assigned to a variable, it loops through the strings properties,
|
||||
// so we have to append '' to make it anonymous again
|
||||
$(typeof this == 'string' ? this+'': this).each(function() {
|
||||
if($.data(this, 'sortable')) {
|
||||
var sortable = $.data(this, 'sortable');
|
||||
if (sortable.options.disabled) { return; }
|
||||
if (sortable && !sortable.options.disabled) {
|
||||
inst.sortables.push({
|
||||
instance: sortable,
|
||||
shouldRevert: sortable.options.revert
|
||||
@ -453,7 +449,6 @@ $.ui.plugin.add("draggable", "connectToSortable", {
|
||||
sortable._trigger("activate", event, inst);
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
},
|
||||
stop: function(event, ui) {
|
||||
|
Loading…
Reference in New Issue
Block a user