From: Jan Schneider Date: Fri, 20 Mar 2009 23:15:27 +0000 (+0100) Subject: Cross-hair cursor for drags. X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=217060a7582004c360a432220a39e2b20f17b8eb;p=horde.git Cross-hair cursor for drags. Don't trigger event update if dropped on the current parent. --- diff --git a/kronolith/js/src/kronolith.js b/kronolith/js/src/kronolith.js index da0060b75..50c43aec6 100644 --- a/kronolith/js/src/kronolith.js +++ b/kronolith/js/src/kronolith.js @@ -402,6 +402,9 @@ KronolithCore = { } new Drop(cell, { onDrop: function(drop) { var el = DragDrop.Drags.drag.element; + if (drop == el.parentNode) { + return; + } drop.insert(el); this.doAction('UpdateEvent', { cal: el.readAttribute('calendar'), @@ -608,6 +611,7 @@ KronolithCore = { } $('kronolithMonthDay' + date.key).insert(div); if (event.value.e) { + div.setStyle({ 'cursor': 'move' }); new Drag('kronolithEventmonth' + r.response.cal + event.key, { threshold: 5, parentElement: function() { return $('kronolithViewMonth').select('.kronolithViewBody')[0]; }, snapToParent: true }); } break;