/* Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. Available via Academic Free License >= 2.1 OR the modified BSD license. see: http://dojotoolkit.org/license for details */ //>>built define("dojo/dnd/move",["../main","./Mover","./Moveable"],function(_1){_1.declare("dojo.dnd.move.constrainedMoveable",_1.dnd.Moveable,{constraints:function(){},within:false,constructor:function(_2,_3){if(!_3){_3={};}this.constraints=_3.constraints;this.within=_3.within;},onFirstMove:function(_4){var c=this.constraintBox=this.constraints.call(this,_4);c.r=c.l+c.w;c.b=c.t+c.h;if(this.within){var mb=_1._getMarginSize(_4.node);c.r-=mb.w;c.b-=mb.h;}},onMove:function(_5,_6){var c=this.constraintBox,s=_5.node.style;this.onMoving(_5,_6);_6.l=_6.l