|
|
@ -384,7 +384,7 @@ |
|
|
|
dragEl = target; |
|
|
|
dragEl = target; |
|
|
|
parentEl = dragEl.parentNode; |
|
|
|
parentEl = dragEl.parentNode; |
|
|
|
nextEl = dragEl.nextSibling; |
|
|
|
nextEl = dragEl.nextSibling; |
|
|
|
lastDownEl = target |
|
|
|
lastDownEl = target; |
|
|
|
activeGroup = options.group; |
|
|
|
activeGroup = options.group; |
|
|
|
oldIndex = startIndex; |
|
|
|
oldIndex = startIndex; |
|
|
|
|
|
|
|
|
|
|
@ -476,11 +476,11 @@ |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
try { |
|
|
|
try { |
|
|
|
if (document.selection) {
|
|
|
|
if (document.selection) { |
|
|
|
// Timeout neccessary for IE9
|
|
|
|
// Timeout neccessary for IE9
|
|
|
|
setTimeout(function () { |
|
|
|
setTimeout(function () { |
|
|
|
document.selection.empty(); |
|
|
|
document.selection.empty(); |
|
|
|
});
|
|
|
|
}); |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
window.getSelection().removeAllRanges(); |
|
|
|
window.getSelection().removeAllRanges(); |
|
|
|
} |
|
|
|
} |
|
|
@ -724,8 +724,13 @@ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if ((el.children.length === 0) || (el.children[0] === ghostEl) || |
|
|
|
if ((el.children.length === 0) || (el.children[0] === ghostEl) || |
|
|
|
(el === evt.target) && (target = _ghostIsLast(el, evt)) |
|
|
|
(el === evt.target) && (_ghostIsLast(el, evt)) |
|
|
|
) { |
|
|
|
) { |
|
|
|
|
|
|
|
//assign target only if condition is true
|
|
|
|
|
|
|
|
if (el.children.length !== 0 && el.children[0] !== ghostEl && el === evt.target) { |
|
|
|
|
|
|
|
target = el.lastElementChild; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if (target) { |
|
|
|
if (target) { |
|
|
|
if (target.animated) { |
|
|
|
if (target.animated) { |
|
|
|
return; |
|
|
|
return; |
|
|
@ -1290,10 +1295,8 @@ |
|
|
|
|
|
|
|
|
|
|
|
// 5 — min delta
|
|
|
|
// 5 — min delta
|
|
|
|
// abs — нельзя добавлять, а то глюки при наведении сверху
|
|
|
|
// abs — нельзя добавлять, а то глюки при наведении сверху
|
|
|
|
return ( |
|
|
|
return (evt.clientY - (rect.top + rect.height) > 5) || |
|
|
|
(evt.clientY - (rect.top + rect.height) > 5) || |
|
|
|
(evt.clientX - (rect.left + rect.width) > 5); |
|
|
|
(evt.clientX - (rect.right + rect.width) > 5) |
|
|
|
|
|
|
|
) && lastEl; |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|