//>>built
define("dojox/app/layout/utils",["dojo/_base/array","dojo/dom-class","dojo/dom-geometry","dojo/dom-style","dojo/_base/lang"],function(h,k,f,i,d){function j(b,a){var c=b.resize?b.resize(a):f.setMarginBox(b.domNode,a);c?d.mixin(b,c):(d.mixin(b,f.getMarginBox(b.domNode)),d.mixin(b,a))}return{marginBox2contentBox:function(b,a){var c=i.getComputedStyle(b),g=f.getMarginExtents(b,c),d=f.getPadBorderExtents(b,c);return{l:i.toPixelValue(b,c.paddingLeft),t:i.toPixelValue(b,c.paddingTop),w:a.w-(g.w+d.w),h:a.h-
(g.h+d.h)}},layoutChildren:function(b,a,c,g,f){a=d.mixin({},a);k.add(b,"dijitLayoutContainer");c=h.filter(c,function(a){return"center"!=a.region&&"client"!=a.layoutAlign}).concat(h.filter(c,function(a){return"center"==a.region||"client"==a.layoutAlign}));h.forEach(c,function(b){var c=b.domNode,e=b.region||b.layoutAlign;if(!e)throw Error("No region setting for "+b.id);var d=c.style;d.left=a.l+"px";d.top=a.t+"px";d.position="absolute";k.add(c,"dijitAlign"+(e.substring(0,1).toUpperCase()+e.substring(1)));
c={};g&&g==b.id&&(c["top"==b.region||"bottom"==b.region?"h":"w"]=f);"top"==e||"bottom"==e?(c.w=a.w,j(b,c),a.h-=b.h,"top"==e?a.t+=b.h:d.top=a.t+a.h+"px"):"left"==e||"right"==e?(c.h=a.h,j(b,c),a.w-=b.w,"left"==e?a.l+=b.w:d.left=a.l+a.w+"px"):("client"==e||"center"==e)&&j(b,a)})}}});