//>>built
define("mill/ribbon",["dijit/dijit","dijit/_Widget"],function(){dojo.declare("mill.ribbon",[dijit._Widget,dijit._Templated],{templateString:dojo.cache("mill","ribbon.html",'\x3cdiv class\x3d"ribbon"\x3e\x3cdiv class\x3d"ribbonBackround ribbonBackroundGreen" dojoAttachPoint\x3d"backgroundNode"\x3e\x3c/div\x3e\x3cdiv class\x3d"ribbonButton ribbonButtonGreen" dojoAttachPoint\x3d"buttonNode"\x3e\x3cdiv align\x3d"center" class\x3d"ribbonLabel" dojoAttachPoint\x3d"labelNode"\x3e\x3c/div\x3e\x3c/div\x3e\x3cdiv class\x3d"ribbonPercentage" dojoAttachPoint\x3d"percentageNode"\x3e\x3c/div\x3e\x3cdiv class\x3d"ribbonContent" dojoAttachPoint\x3d"containerNode"\x3e\x3c/div\x3e\x3c/div\x3e'),
color:"green",label:"",button:!0,percents:null,attributeMap:dojo.delegate(dijit._WidgetBase,{color:"",label:"",button:"",percents:0}),_setColorAttr:function(a){this.color=a;this.render()},_setLabelAttr:function(a){this.label=a;this.render()},_setButtonAttr:function(a){this.button=a;this.render()},_setPercentsAttr:function(a){this.percents=a;this.render()},startup:function(){this.inherited(arguments);this.render()},render:function(){this.buttonNode.style.display=this.button?"":"none";dojo.removeClass(this.backgroundNode,
"ribbonBackroundGreen");dojo.removeClass(this.backgroundNode,"ribbonBackroundRed");dojo.removeClass(this.backgroundNode,"ribbonBackroundBlue");dojo.removeClass(this.backgroundNode,"ribbonBackroundAqua");dojo.addClass(this.backgroundNode,"red"==this.color?"ribbonBackroundRed":"blue"==this.color?"ribbonBackroundBlue":"green"==this.color?"ribbonBackroundGreen":"ribbonBackroundAqua");dojo.removeClass(this.buttonNode,"ribbonButtonGreen");dojo.removeClass(this.buttonNode,"ribbonButtonRed");dojo.removeClass(this.buttonNode,
"ribbonButtonBlue");dojo.removeClass(this.buttonNode,"ribbonButtonAqua");dojo.addClass(this.buttonNode,"red"==this.color?"ribbonButtonRed":"blue"==this.color?"ribbonButtonBlue":"green"==this.color?"ribbonButtonGreen":"ribbonButtonAqua");if(this.percents){var a=dojo.marginBox(this.domNode);this.percentageNode.style.width=(100-this.percents)*(a.w-120)/100+"px"}else this.percentageNode.style.width="0";this.labelNode.innerHTML=this.label}})});