a:17:{s:9:"#provides";s:14:"dojo.dnd.Mover";s:9:"#resource";s:12:"dnd/Mover.js";s:9:"#requires";a:2:{i:0;a:2:{i:0;s:6:"common";i:1;s:15:"dojo.dnd.common";}i:1;a:2:{i:0;s:6:"common";i:1;s:19:"dojo.dnd.autoscroll";}}s:14:"dojo.dnd.Mover";a:5:{s:4:"type";s:8:"Function";s:10:"parameters";a:3:{s:4:"node";a:2:{s:4:"type";s:4:"Node";s:7:"summary";s:33:"a node (or node's id) to be moved";}s:1:"e";a:2:{s:4:"type";s:5:"Event";s:7:"summary";s:79:"a mouse event, which started the move; only pageX and pageY properties are used";}s:4:"host";a:3:{s:4:"type";s:6:"Object";s:8:"optional";b:1;s:7:"summary";s:109:"object which implements the functionality of the move, and defines proper events (onMoveStart and onMoveStop)";}}s:6:"source";s:624:" this.node = dojo.byId(node); this.marginBox = {l: e.pageX, t: e.pageY}; this.mouseButton = e.button; var h = this.host = host, d = node.ownerDocument, firstEvent = dojo.connect(d, "onmousemove", this, "onFirstMove"); this.events = [ dojo.connect(d, "onmousemove", this, "onMouseMove"), dojo.connect(d, "onmouseup", this, "onMouseUp"), // cancel text selection and text dragging dojo.connect(d, "ondragstart", dojo.stopEvent), dojo.connect(d.body, "onselectstart", dojo.stopEvent), firstEvent ]; // notify that the move has started if(h && h.onMoveStart){ h.onMoveStart(this); }";s:7:"summary";s:110:"an object, which makes a node follow the mouse, used as a default mover, and as a base class for custom movers";s:9:"classlike";b:1;}s:26:"dojo.dnd.Mover.onMouseMove";a:5:{s:9:"prototype";s:14:"dojo.dnd.Mover";s:4:"type";s:8:"Function";s:10:"parameters";a:1:{s:1:"e";a:2:{s:4:"type";s:5:"Event";s:7:"summary";s:11:"mouse event";}}s:6:"source";s:136:" dojo.dnd.autoScroll(e); var m = this.marginBox; this.host.onMove(this, {l: m.l + e.pageX, t: m.t + e.pageY}); dojo.stopEvent(e);";s:7:"summary";s:31:"event processor for onmousemove";}s:24:"dojo.dnd.Mover.onMouseUp";a:5:{s:9:"prototype";s:14:"dojo.dnd.Mover";s:4:"type";s:8:"Function";s:10:"parameters";a:1:{s:1:"e";a:1:{s:4:"type";s:0:"";}}s:6:"source";s:160:" if(dojo.isWebKit && dojo.dnd._isMac && this.mouseButton == 2 ? e.button == 0 : this.mouseButton == e.button){ this.destroy(); } dojo.stopEvent(e);";s:7:"summary";s:0:"";}s:26:"dojo.dnd.Mover.onFirstMove";a:4:{s:9:"prototype";s:14:"dojo.dnd.Mover";s:4:"type";s:8:"Function";s:6:"source";s:1240:" var s = this.node.style, l, t, h = this.host; switch(s.position){ case "relative": case "absolute": // assume that left and top values are in pixels already l = Math.round(parseFloat(s.left)); t = Math.round(parseFloat(s.top)); break; default: s.position = "absolute"; // enforcing the absolute mode var m = dojo.marginBox(this.node); // event.pageX/pageY (which we used to generate the initial // margin box) includes padding and margin set on the body. // However, setting the node's position to absolute and then // doing dojo.marginBox on it *doesn't* take that additional // space into account - so we need to subtract the combined // padding and margin. We use getComputedStyle and // _getMarginBox/_getContentBox to avoid the extra lookup of // the computed style. var b = dojo.doc.body; var bs = dojo.getComputedStyle(b); var bm = dojo._getMarginBox(b, bs); var bc = dojo._getContentBox(b, bs); l = m.l - (bc.l - bm.l); t = m.t - (bc.t - bm.t); break; } this.marginBox.l = l - this.marginBox.l; this.marginBox.t = t - this.marginBox.t; if(h && h.onFirstMove){ h.onFirstMove(this); } dojo.disconnect(this.events.pop());";s:7:"summary";s:132:"makes the node absolute; it is meant to be called only once. relative and absolutely positioned nodes are assumed to use pixel units";}s:22:"dojo.dnd.Mover.destroy";a:4:{s:9:"prototype";s:14:"dojo.dnd.Mover";s:4:"type";s:8:"Function";s:6:"source";s:211:" dojo.forEach(this.events, dojo.disconnect); // undo global settings var h = this.host; if(h && h.onMoveStop){ h.onMoveStop(this); } // destroy objects this.events = this.node = this.host = null;";s:7:"summary";s:78:"stops the move, deletes all references, so the object can be garbage-collected";}s:26:"dojo.dnd.Mover.mouseButton";a:2:{s:8:"instance";s:14:"dojo.dnd.Mover";s:7:"summary";s:0:"";}s:26:"dojo.dnd.Mover.marginBox.l";a:2:{s:8:"instance";s:14:"dojo.dnd.Mover";s:7:"summary";s:0:"";}s:26:"dojo.dnd.Mover.marginBox.t";a:2:{s:8:"instance";s:14:"dojo.dnd.Mover";s:7:"summary";s:0:"";}s:21:"dojo.dnd.Mover.events";a:2:{s:8:"instance";s:14:"dojo.dnd.Mover";s:7:"summary";s:0:"";}s:19:"dojo.dnd.Mover.node";a:3:{s:8:"instance";s:14:"dojo.dnd.Mover";s:4:"type";s:4:"Node";s:7:"summary";s:33:"a node (or node's id) to be moved";}s:24:"dojo.dnd.Mover.marginBox";a:2:{s:8:"instance";s:14:"dojo.dnd.Mover";s:7:"summary";s:0:"";}s:19:"dojo.dnd.Mover.host";a:3:{s:8:"instance";s:14:"dojo.dnd.Mover";s:4:"type";s:7:"Object?";s:7:"summary";s:109:"object which implements the functionality of the move, and defines proper events (onMoveStart and onMoveStop)";}s:8:"dojo.dnd";a:2:{s:4:"type";s:6:"Object";s:7:"summary";s:0:"";}s:4:"dojo";a:2:{s:4:"type";s:6:"Object";s:7:"summary";s:0:"";}}