Changeset 13167
- Timestamp:
- 03/20/08 23:32:30 (10 months ago)
- Files:
-
- 1 modified
-
dojo/trunk/dnd/move.js (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
dojo/trunk/dnd/move.js
r13098 r13167 30 30 // summary: called during the very first move notification, 31 31 // can be used to initialize coordinates, can be overwritten. 32 var c = this.constraintBox = this.constraints.call(this, mover), m = mover.marginBox; 33 c.r = c.l + c.w - (this.within ? m.w : 0); 34 c.b = c.t + c.h - (this.within ? m.h : 0); 32 var c = this.constraintBox = this.constraints.call(this, mover); 33 c.r = c.l + c.w; 34 c.b = c.t + c.h; 35 if(this.within){ 36 var mb = dojo.marginBox(mover.node); 37 c.r -= mb.w; 38 c.b -= mb.h; 39 } 35 40 }, 36 41 onMove: function(/* dojo.dnd.Mover */ mover, /* Object */ leftTop){ … … 134 139 // summary: called once to initialize things; it is meant to be called only once 135 140 dojo.dnd.Mover.prototype.onFirstMove.call(this); 136 var c = this.constraintBox = fun.call(this), m = this.marginBox; 137 c.r = c.l + c.w - (within ? m.w : 0); 138 c.b = c.t + c.h - (within ? m.h : 0); 141 var c = this.constraintBox = fun.call(this); 142 c.r = c.l + c.w; 143 c.b = c.t + c.h; 144 if(within){ 145 var mb = dojo.marginBox(this.node); 146 c.r -= mb.w; 147 c.b -= mb.h; 148 } 139 149 } 140 150 });