/* 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 */ /* This is an optimized version of Dojo, built for deployment and not for development. To get sources and documentation, please visit: http://dojotoolkit.org */ if(!dojo._hasResource["dojo.colors"]){dojo._hasResource["dojo.colors"]=true;dojo.provide("dojo.colors");dojo.getObject("colors",true,dojo);(function(){var _1=function(m1,m2,h){if(h<0){++h;}if(h>1){--h;}var h6=6*h;if(h6<1){return m1+(m2-m1)*h6;}if(2*h<1){return m2;}if(3*h<2){return m1+(m2-m1)*(2/3-h)*6;}return m1;};dojo.colorFromRgb=function(_2,_3){var m=_2.toLowerCase().match(/^(rgba?|hsla?)\(([\s\.\-,%0-9]+)\)/);if(m){var c=m[2].split(/\s*,\s*/),l=c.length,t=m[1],a;if((t=="rgb"&&l==3)||(t=="rgba"&&l==4)){var r=c[0];if(r.charAt(r.length-1)=="%"){a=dojo.map(c,function(x){return parseFloat(x)*2.56;});if(l==4){a[3]=c[3];}return dojo.colorFromArray(a,_3);}return dojo.colorFromArray(c,_3);}if((t=="hsl"&&l==3)||(t=="hsla"&&l==4)){var H=((parseFloat(c[0])%360)+360)%360/360,S=parseFloat(c[1])/100,L=parseFloat(c[2])/100,m2=L<=0.5?L*(S+1):L+S-L*S,m1=2*L-m2;a=[_1(m1,m2,H+1/3)*256,_1(m1,m2,H)*256,_1(m1,m2,H-1/3)*256,1];if(l==4){a[3]=c[3];}return dojo.colorFromArray(a,_3);}}return null;};var _4=function(c,_5,_6){c=Number(c);return isNaN(c)?_6:c<_5?_5:c>_6?_6:c;};dojo.Color.prototype.sanitize=function(){var t=this;t.r=Math.round(_4(t.r,0,255));t.g=Math.round(_4(t.g,0,255));t.b=Math.round(_4(t.b,0,255));t.a=_4(t.a,0,1);return this;};})();dojo.colors.makeGrey=function(g,a){return dojo.colorFromArray([g,g,g,a]);};dojo.mixin(dojo.Color.named,{aliceblue:[240,248,255],antiquewhite:[250,235,215],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],blanchedalmond:[255,235,205],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],oldlace:[253,245,230],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],thistle:[216,191,216],tomato:[255,99,71],transparent:[0,0,0,0],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],whitesmoke:[245,245,245],yellowgreen:[154,205,50]});}if(!dojo._hasResource["dojo.i18n"]){dojo._hasResource["dojo.i18n"]=true;dojo.provide("dojo.i18n");dojo.getObject("i18n",true,dojo);dojo.i18n.getLocalization=dojo.i18n.getLocalization||function(_7,_8,_9){_9=dojo.i18n.normalizeLocale(_9);var _a=_9.split("-");var _b=[_7,"nls",_8].join(".");var _c=dojo._loadedModules[_b];if(_c){var _d;for(var i=_a.length;i>0;i--){var _e=_a.slice(0,i).join("_");if(_c[_e]){_d=_c[_e];break;}}if(!_d){_d=_c.ROOT;}if(_d){var _f=function(){};_f.prototype=_d;return new _f();}}throw new Error("Bundle not found: "+_8+" in "+_7+" , locale="+_9);};dojo.i18n.normalizeLocale=function(_10){var _11=_10?_10.toLowerCase():dojo.locale;if(_11=="root"){_11="ROOT";}return _11;};dojo.i18n._requireLocalization=function(_12,_13,_14,_15){var _16=dojo.i18n.normalizeLocale(_14);var _17=[_12,"nls",_13].join(".");var _18="";if(_15){var _19=_15.split(",");for(var i=0;i<_19.length;i++){if(_16["indexOf"](_19[i])==0){if(_19[i].length>_18.length){_18=_19[i];}}}if(!_18){_18="ROOT";}}var _1a=_15?_18:_16;var _1b=dojo._loadedModules[_17];var _1c=null;if(_1b){if(dojo.config.localizationComplete&&_1b._built){return;}var _1d=_1a.replace(/-/g,"_");var _1e=_17+"."+_1d;_1c=dojo._loadedModules[_1e];}if(!_1c){_1b=dojo["provide"](_17);var _1f=dojo._getModuleSymbols(_12);var _20=_1f.concat("nls").join("/");var _21;dojo.i18n._searchLocalePath(_1a,_15,function(loc){var _22=loc.replace(/-/g,"_");var _23=_17+"."+_22;var _24=false;if(!dojo._loadedModules[_23]){dojo["provide"](_23);var _25=[_20];if(loc!="ROOT"){_25.push(loc);}_25.push(_13);var _26=_25.join("/")+".js";_24=dojo._loadPath(_26,null,function(_27){_27=_27.root||_27;var _28=function(){};_28.prototype=_21;_1b[_22]=new _28();for(var j in _27){_1b[_22][j]=_27[j];}});}else{_24=true;}if(_24&&_1b[_22]){_21=_1b[_22];}else{_1b[_22]=_21;}if(_15){return true;}});}if(_15&&_16!=_18){_1b[_16.replace(/-/g,"_")]=_1b[_18.replace(/-/g,"_")];}};(function(){var _29=dojo.config.extraLocale;if(_29){if(!_29 instanceof Array){_29=[_29];}var req=dojo.i18n._requireLocalization;dojo.i18n._requireLocalization=function(m,b,_2a,_2b){req(m,b,_2a,_2b);if(_2a){return;}for(var i=0;i<_29.length;i++){req(m,b,_29[i],_2b);}};}})();dojo.i18n._searchLocalePath=function(_2c,_2d,_2e){_2c=dojo.i18n.normalizeLocale(_2c);var _2f=_2c.split("-");var _30=[];for(var i=_2f.length;i>0;i--){_30.push(_2f.slice(0,i).join("-"));}_30.push(false);if(_2d){_30.reverse();}for(var j=_30.length-1;j>=0;j--){var loc=_30[j]||"ROOT";var _31=_2e(loc);if(_31){break;}}};dojo.i18n._preloadLocalizations=function(_32,_33){function _34(_35){_35=dojo.i18n.normalizeLocale(_35);dojo.i18n._searchLocalePath(_35,true,function(loc){for(var i=0;i<_33.length;i++){if(_33[i]==loc){dojo["require"](_32+"_"+loc);return true;}}return false;});};_34();var _36=dojo.config.extraLocale||[];for(var i=0;i<_36.length;i++){_34(_36[i]);}};}if(!dojo._hasResource["dijit._PaletteMixin"]){dojo._hasResource["dijit._PaletteMixin"]=true;dojo.provide("dijit._PaletteMixin");dojo.declare("dijit._PaletteMixin",[dijit._CssStateMixin],{defaultTimeout:500,timeoutChangeRate:0.9,value:null,_selectedCell:-1,tabIndex:"0",cellClass:"dijitPaletteCell",dyeClass:"",_preparePalette:function(_37,_38){this._cells=[];var url=this._blankGif;var _39=dojo.getObject(this.dyeClass);for(var row=0;row<_37.length;row++){var _3a=dojo.create("tr",{tabIndex:"-1"},this.gridNode);for(var col=0;col<_37[row].length;col++){var _3b=_37[row][col];if(_3b){var _3c=new _39(_3b);var _3d=dojo.create("td",{"class":this.cellClass,tabIndex:"-1",title:_38[_3b]});_3c.fillCell(_3d,url);this.connect(_3d,"ondijitclick","_onCellClick");this._trackMouseState(_3d,this.cellClass);dojo.place(_3d,_3a);_3d.index=this._cells.length;this._cells.push({node:_3d,dye:_3c});}}}this._xDim=_37[0].length;this._yDim=_37.length;var _3e={UP_ARROW:-this._xDim,DOWN_ARROW:this._xDim,RIGHT_ARROW:this.isLeftToRight()?1:-1,LEFT_ARROW:this.isLeftToRight()?-1:1};for(var key in _3e){this._connects.push(dijit.typematic.addKeyListener(this.domNode,{charOrCode:dojo.keys[key],ctrlKey:false,altKey:false,shiftKey:false},this,function(){var _3f=_3e[key];return function(_40){this._navigateByKey(_3f,_40);};}(),this.timeoutChangeRate,this.defaultTimeout));}},postCreate:function(){this.inherited(arguments);this._setCurrent(this._cells[0].node);},focus:function(){dijit.focus(this._currentFocus);},_onCellClick:function(evt){var _41=evt.currentTarget,_42=this._getDye(_41).getValue();this._setCurrent(_41);setTimeout(dojo.hitch(this,function(){dijit.focus(_41);this._setValueAttr(_42,true);}));dojo.removeClass(_41,"dijitPaletteCellHover");dojo.stopEvent(evt);},_setCurrent:function(_43){if("_currentFocus" in this){dojo.attr(this._currentFocus,"tabIndex","-1");}this._currentFocus=_43;if(_43){dojo.attr(_43,"tabIndex",this.tabIndex);}},_setValueAttr:function(_44,_45){if(this._selectedCell>=0){dojo.removeClass(this._cells[this._selectedCell].node,"dijitPaletteCellSelected");}this._selectedCell=-1;if(_44){for(var i=0;i=0?_44:null);},onChange:function(_46){},_navigateByKey:function(_47,_48){if(_48==-1){return;}var _49=this._currentFocus.index+_47;if(_49-1){var _4a=this._cells[_49].node;this._setCurrent(_4a);setTimeout(dojo.hitch(dijit,"focus",_4a),0);}},_getDye:function(_4b){return this._cells[_4b.index].dye;}});}if(!dojo._hasResource["dijit.ColorPalette"]){dojo._hasResource["dijit.ColorPalette"]=true;dojo.provide("dijit.ColorPalette");dojo.declare("dijit.ColorPalette",[dijit._Widget,dijit._Templated,dijit._PaletteMixin],{palette:"7x10",_palettes:{"7x10":[["white","seashell","cornsilk","lemonchiffon","lightyellow","palegreen","paleturquoise","lightcyan","lavender","plum"],["lightgray","pink","bisque","moccasin","khaki","lightgreen","lightseagreen","lightskyblue","cornflowerblue","violet"],["silver","lightcoral","sandybrown","orange","palegoldenrod","chartreuse","mediumturquoise","skyblue","mediumslateblue","orchid"],["gray","red","orangered","darkorange","yellow","limegreen","darkseagreen","royalblue","slateblue","mediumorchid"],["dimgray","crimson","chocolate","coral","gold","forestgreen","seagreen","blue","blueviolet","darkorchid"],["darkslategray","firebrick","saddlebrown","sienna","olive","green","darkcyan","mediumblue","darkslateblue","darkmagenta"],["black","darkred","maroon","brown","darkolivegreen","darkgreen","midnightblue","navy","indigo","purple"]],"3x4":[["white","lime","green","blue"],["silver","yellow","fuchsia","navy"],["gray","red","purple","black"]]},_imagePaths:{"7x10":dojo.moduleUrl("dijit.themes","a11y/colors7x10.png"),"3x4":dojo.moduleUrl("dijit.themes","a11y/colors3x4.png"),"7x10-rtl":dojo.moduleUrl("dijit.themes","a11y/colors7x10-rtl.png"),"3x4-rtl":dojo.moduleUrl("dijit.themes","a11y/colors3x4-rtl.png")},templateString:dojo.cache("dijit","templates/ColorPalette.html","
\r\n\t\"\"/\r\n\t\r\n\t\t\r\n\t
\r\n
\r\n"),baseClass:"dijitColorPalette",dyeClass:"dijit._Color",buildRendering:function(){this.inherited(arguments);this.imageNode.setAttribute("src",this._imagePaths[this.palette+(this.isLeftToRight()?"":"-rtl")].toString());var _4c=dojo.i18n.getLocalization("dojo","colors",this.lang);this._preparePalette(this._palettes[this.palette],_4c);}});dojo.declare("dijit._Color",dojo.Color,{constructor:function(_4d){this._alias=_4d;this.setColor(dojo.Color.named[_4d]);},getValue:function(){return this.toHex();},fillCell:function(_4e,_4f){dojo.create("img",{src:_4f,"class":"dijitPaletteImg",alt:this._alias},_4e);}});}if(!dojo._hasResource["dijit.Declaration"]){dojo._hasResource["dijit.Declaration"]=true;dojo.provide("dijit.Declaration");dojo.declare("dijit.Declaration",dijit._Widget,{_noScript:true,stopParser:true,widgetClass:"",defaults:null,mixins:[],buildRendering:function(){var src=this.srcNodeRef.parentNode.removeChild(this.srcNodeRef),_50=dojo.query("> script[type^='dojo/method']",src).orphan(),_51=dojo.query("> script[type^='dojo/connect']",src).orphan(),_52=src.nodeName;var _53=this.defaults||{};dojo.forEach(_50,function(s){var evt=s.getAttribute("event")||s.getAttribute("data-dojo-event"),_54=dojo.parser._functionFromScript(s);if(evt){_53[evt]=_54;}else{_51.push(s);}});this.mixins=this.mixins.length?dojo.map(this.mixins,function(_55){return dojo.getObject(_55);}):[dijit._Widget,dijit._Templated];_53.widgetsInTemplate=true;_53._skipNodeCache=true;_53.templateString="<"+_52+" class='"+src.className+"' dojoAttachPoint='"+(src.getAttribute("dojoAttachPoint")||"")+"' dojoAttachEvent='"+(src.getAttribute("dojoAttachEvent")||"")+"' >"+src.innerHTML.replace(/\%7B/g,"{").replace(/\%7D/g,"}")+"";dojo.query("[dojoType]",src).forEach(function(_56){_56.removeAttribute("dojoType");});var wc=dojo.declare(this.widgetClass,this.mixins,_53);dojo.forEach(_51,function(s){var evt=s.getAttribute("event")||s.getAttribute("data-dojo-event")||"postscript",_57=dojo.parser._functionFromScript(s);dojo.connect(wc.prototype,evt,_57);});}});}if(!dojo._hasResource["dojo.dnd.common"]){dojo._hasResource["dojo.dnd.common"]=true;dojo.provide("dojo.dnd.common");dojo.getObject("dnd",true,dojo);dojo.dnd.getCopyKeyState=dojo.isCopyKey;dojo.dnd._uniqueId=0;dojo.dnd.getUniqueId=function(){var id;do{id=dojo._scopeName+"Unique"+(++dojo.dnd._uniqueId);}while(dojo.byId(id));return id;};dojo.dnd._empty={};dojo.dnd.isFormElement=function(e){var t=e.target;if(t.nodeType==3){t=t.parentNode;}return " button textarea input select option ".indexOf(" "+t.tagName.toLowerCase()+" ")>=0;};}if(!dojo._hasResource["dojo.dnd.autoscroll"]){dojo._hasResource["dojo.dnd.autoscroll"]=true;dojo.provide("dojo.dnd.autoscroll");dojo.getObject("dnd",true,dojo);dojo.dnd.getViewport=dojo.window.getBox;dojo.dnd.V_TRIGGER_AUTOSCROLL=32;dojo.dnd.H_TRIGGER_AUTOSCROLL=32;dojo.dnd.V_AUTOSCROLL_VALUE=16;dojo.dnd.H_AUTOSCROLL_VALUE=16;dojo.dnd.autoScroll=function(e){var v=dojo.window.getBox(),dx=0,dy=0;if(e.clientXv.w-dojo.dnd.H_TRIGGER_AUTOSCROLL){dx=dojo.dnd.H_AUTOSCROLL_VALUE;}}if(e.clientYv.h-dojo.dnd.V_TRIGGER_AUTOSCROLL){dy=dojo.dnd.V_AUTOSCROLL_VALUE;}}window.scrollBy(dx,dy);};dojo.dnd._validNodes={"div":1,"p":1,"td":1};dojo.dnd._validOverflow={"auto":1,"scroll":1};dojo.dnd.autoScrollNodes=function(e){for(var n=e.target;n;){if(n.nodeType==1&&(n.tagName.toLowerCase() in dojo.dnd._validNodes)){var s=dojo.getComputedStyle(n);if(s.overflow.toLowerCase() in dojo.dnd._validOverflow){var b=dojo._getContentBox(n,s),t=dojo.position(n,true);var w=Math.min(dojo.dnd.H_TRIGGER_AUTOSCROLL,b.w/2),h=Math.min(dojo.dnd.V_TRIGGER_AUTOSCROLL,b.h/2),rx=e.pageX-t.x,ry=e.pageY-t.y,dx=0,dy=0;if(dojo.isWebKit||dojo.isOpera){rx+=dojo.body().scrollLeft;ry+=dojo.body().scrollTop;}if(rx>0&&rxb.w-w){dx=w;}}}if(ry>0&&ryb.h-h){dy=h;}}}var _58=n.scrollLeft,_59=n.scrollTop;n.scrollLeft=n.scrollLeft+dx;n.scrollTop=n.scrollTop+dy;if(_58!=n.scrollLeft||_59!=n.scrollTop){return;}}}try{n=n.parentNode;}catch(x){n=null;}}dojo.dnd.autoScroll(e);};}if(!dojo._hasResource["dojo.dnd.Mover"]){dojo._hasResource["dojo.dnd.Mover"]=true;dojo.provide("dojo.dnd.Mover");dojo.declare("dojo.dnd.Mover",null,{constructor:function(_5a,e,_5b){this.node=dojo.byId(_5a);var pos=e.touches?e.touches[0]:e;this.marginBox={l:pos.pageX,t:pos.pageY};this.mouseButton=e.button;var h=(this.host=_5b),d=_5a.ownerDocument;this.events=[dojo.connect(d,"onmousemove",this,"onFirstMove"),dojo.connect(d,"ontouchmove",this,"onFirstMove"),dojo.connect(d,"onmousemove",this,"onMouseMove"),dojo.connect(d,"ontouchmove",this,"onMouseMove"),dojo.connect(d,"onmouseup",this,"onMouseUp"),dojo.connect(d,"ontouchend",this,"onMouseUp"),dojo.connect(d,"ondragstart",dojo.stopEvent),dojo.connect(d.body,"onselectstart",dojo.stopEvent)];if(h&&h.onMoveStart){h.onMoveStart(this);}},onMouseMove:function(e){dojo.dnd.autoScroll(e);var m=this.marginBox,pos=e.touches?e.touches[0]:e;this.host.onMove(this,{l:m.l+pos.pageX,t:m.t+pos.pageY},e);dojo.stopEvent(e);},onMouseUp:function(e){if(dojo.isWebKit&&dojo.isMac&&this.mouseButton==2?e.button==0:this.mouseButton==e.button){this.destroy();}dojo.stopEvent(e);},onFirstMove:function(e){var s=this.node.style,l,t,h=this.host;switch(s.position){case "relative":case "absolute":l=Math.round(parseFloat(s.left))||0;t=Math.round(parseFloat(s.top))||0;break;default:s.position="absolute";var m=dojo.marginBox(this.node);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,e);}dojo.disconnect(this.events.shift());dojo.disconnect(this.events.shift());},destroy:function(){dojo.forEach(this.events,dojo.disconnect);var h=this.host;if(h&&h.onMoveStop){h.onMoveStop(this);}this.events=this.node=this.host=null;}});}if(!dojo._hasResource["dojo.dnd.Moveable"]){dojo._hasResource["dojo.dnd.Moveable"]=true;dojo.provide("dojo.dnd.Moveable");dojo.declare("dojo.dnd.Moveable",null,{handle:"",delay:0,skip:false,constructor:function(_5c,_5d){this.node=dojo.byId(_5c);if(!_5d){_5d={};}this.handle=_5d.handle?dojo.byId(_5d.handle):null;if(!this.handle){this.handle=this.node;}this.delay=_5d.delay>0?_5d.delay:0;this.skip=_5d.skip;this.mover=_5d.mover?_5d.mover:dojo.dnd.Mover;this.events=[dojo.connect(this.handle,"onmousedown",this,"onMouseDown"),dojo.connect(this.handle,"ontouchstart",this,"onMouseDown"),dojo.connect(this.handle,"ondragstart",this,"onSelectStart"),dojo.connect(this.handle,"onselectstart",this,"onSelectStart")];},markupFactory:function(_5e,_5f){return new dojo.dnd.Moveable(_5f,_5e);},destroy:function(){dojo.forEach(this.events,dojo.disconnect);this.events=this.node=this.handle=null;},onMouseDown:function(e){if(this.skip&&dojo.dnd.isFormElement(e)){return;}if(this.delay){this.events.push(dojo.connect(this.handle,"onmousemove",this,"onMouseMove"),dojo.connect(this.handle,"ontouchmove",this,"onMouseMove"),dojo.connect(this.handle,"onmouseup",this,"onMouseUp"),dojo.connect(this.handle,"ontouchend",this,"onMouseUp"));var pos=e.touches?e.touches[0]:e;this._lastX=pos.pageX;this._lastY=pos.pageY;}else{this.onDragDetected(e);}dojo.stopEvent(e);},onMouseMove:function(e){var pos=e.touches?e.touches[0]:e;if(Math.abs(pos.pageX-this._lastX)>this.delay||Math.abs(pos.pageY-this._lastY)>this.delay){this.onMouseUp(e);this.onDragDetected(e);}dojo.stopEvent(e);},onMouseUp:function(e){for(var i=0;i<2;++i){dojo.disconnect(this.events.pop());}dojo.stopEvent(e);},onSelectStart:function(e){if(!this.skip||!dojo.dnd.isFormElement(e)){dojo.stopEvent(e);}},onDragDetected:function(e){new this.mover(this.node,e,this);},onMoveStart:function(_60){dojo.publish("/dnd/move/start",[_60]);dojo.addClass(dojo.body(),"dojoMove");dojo.addClass(this.node,"dojoMoveItem");},onMoveStop:function(_61){dojo.publish("/dnd/move/stop",[_61]);dojo.removeClass(dojo.body(),"dojoMove");dojo.removeClass(this.node,"dojoMoveItem");},onFirstMove:function(_62,e){},onMove:function(_63,_64,e){this.onMoving(_63,_64);var s=_63.node.style;s.left=_64.l+"px";s.top=_64.t+"px";this.onMoved(_63,_64);},onMoving:function(_65,_66){},onMoved:function(_67,_68){}});}if(!dojo._hasResource["dojo.dnd.move"]){dojo._hasResource["dojo.dnd.move"]=true;dojo.provide("dojo.dnd.move");dojo.declare("dojo.dnd.move.constrainedMoveable",dojo.dnd.Moveable,{constraints:function(){},within:false,markupFactory:function(_69,_6a){return new dojo.dnd.move.constrainedMoveable(_6a,_69);},constructor:function(_6b,_6c){if(!_6c){_6c={};}this.constraints=_6c.constraints;this.within=_6c.within;},onFirstMove:function(_6d){var c=this.constraintBox=this.constraints.call(this,_6d);c.r=c.l+c.w;c.b=c.t+c.h;if(this.within){var mb=dojo._getMarginSize(_6d.node);c.r-=mb.w;c.b-=mb.h;}},onMove:function(_6e,_6f){var c=this.constraintBox,s=_6e.node.style;this.onMoving(_6e,_6f);_6f.l=_6f.l=0){this.timeout=_7b.timeout;}},markupFactory:function(_7c,_7d){return new dojo.dnd.TimedMoveable(_7d,_7c);},onMoveStop:function(_7e){if(_7e._timer){clearTimeout(_7e._timer);_79.call(this,_7e,_7e._leftTop);}dojo.dnd.Moveable.prototype.onMoveStop.apply(this,arguments);},onMove:function(_7f,_80){_7f._leftTop=_80;if(!_7f._timer){var _81=this;_7f._timer=setTimeout(function(){_7f._timer=null;_79.call(_81,_7f,_7f._leftTop);},this.timeout);}}});})();}if(!dojo._hasResource["dojo.fx.Toggler"]){dojo._hasResource["dojo.fx.Toggler"]=true;dojo.provide("dojo.fx.Toggler");dojo.declare("dojo.fx.Toggler",null,{node:null,showFunc:dojo.fadeIn,hideFunc:dojo.fadeOut,showDuration:200,hideDuration:200,constructor:function(_82){var _83=this;dojo.mixin(_83,_82);_83.node=_82.node;_83._showArgs=dojo.mixin({},_82);_83._showArgs.node=_83.node;_83._showArgs.duration=_83.showDuration;_83.showAnim=_83.showFunc(_83._showArgs);_83._hideArgs=dojo.mixin({},_82);_83._hideArgs.node=_83.node;_83._hideArgs.duration=_83.hideDuration;_83.hideAnim=_83.hideFunc(_83._hideArgs);dojo.connect(_83.showAnim,"beforeBegin",dojo.hitch(_83.hideAnim,"stop",true));dojo.connect(_83.hideAnim,"beforeBegin",dojo.hitch(_83.showAnim,"stop",true));},show:function(_84){return this.showAnim.play(_84||0);},hide:function(_85){return this.hideAnim.play(_85||0);}});}if(!dojo._hasResource["dojo.fx"]){dojo._hasResource["dojo.fx"]=true;dojo.provide("dojo.fx");(function(){var d=dojo,_86={_fire:function(evt,_87){if(this[evt]){this[evt].apply(this,_87||[]);}return this;}};var _88=function(_89){this._index=-1;this._animations=_89||[];this._current=this._onAnimateCtx=this._onEndCtx=null;this.duration=0;d.forEach(this._animations,function(a){this.duration+=a.duration;if(a.delay){this.duration+=a.delay;}},this);};d.extend(_88,{_onAnimate:function(){this._fire("onAnimate",arguments);},_onEnd:function(){d.disconnect(this._onAnimateCtx);d.disconnect(this._onEndCtx);this._onAnimateCtx=this._onEndCtx=null;if(this._index+1==this._animations.length){this._fire("onEnd");}else{this._current=this._animations[++this._index];this._onAnimateCtx=d.connect(this._current,"onAnimate",this,"_onAnimate");this._onEndCtx=d.connect(this._current,"onEnd",this,"_onEnd");this._current.play(0,true);}},play:function(_8a,_8b){if(!this._current){this._current=this._animations[this._index=0];}if(!_8b&&this._current.status()=="playing"){return this;}var _8c=d.connect(this._current,"beforeBegin",this,function(){this._fire("beforeBegin");}),_8d=d.connect(this._current,"onBegin",this,function(arg){this._fire("onBegin",arguments);}),_8e=d.connect(this._current,"onPlay",this,function(arg){this._fire("onPlay",arguments);d.disconnect(_8c);d.disconnect(_8d);d.disconnect(_8e);});if(this._onAnimateCtx){d.disconnect(this._onAnimateCtx);}this._onAnimateCtx=d.connect(this._current,"onAnimate",this,"_onAnimate");if(this._onEndCtx){d.disconnect(this._onEndCtx);}this._onEndCtx=d.connect(this._current,"onEnd",this,"_onEnd");this._current.play.apply(this._current,arguments);return this;},pause:function(){if(this._current){var e=d.connect(this._current,"onPause",this,function(arg){this._fire("onPause",arguments);d.disconnect(e);});this._current.pause();}return this;},gotoPercent:function(_8f,_90){this.pause();var _91=this.duration*_8f;this._current=null;d.some(this._animations,function(a){if(a.duration<=_91){this._current=a;return true;}_91-=a.duration;return false;});if(this._current){this._current.gotoPercent(_91/this._current.duration,_90);}return this;},stop:function(_92){if(this._current){if(_92){for(;this._index+1this._animations.length){this._fire("onEnd");}},_call:function(_9a,_9b){var t=this._pseudoAnimation;t[_9a].apply(t,_9b);},play:function(_9c,_9d){this._finished=0;this._doAction("play",arguments);this._call("play",arguments);return this;},pause:function(){this._doAction("pause",arguments);this._call("pause",arguments);return this;},gotoPercent:function(_9e,_9f){var ms=this.duration*_9e;d.forEach(this._animations,function(a){a.gotoPercent(a.duration=0?"Error":dojo.indexOf(_bd,"Incomplete")>=0?"Incomplete":"";},disconnectChildren:function(){dojo.forEach(this._childConnections||[],dojo.hitch(this,"disconnect"));dojo.forEach(this._childWatches||[],function(w){w.unwatch();});},connectChildren:function(_be){var _bf=this;this.disconnectChildren();this._descendants=this.getDescendants();var set=_be?function(_c0,val){_bf[_c0]=val;}:dojo.hitch(this,"_set");set("value",this.get("value"));set("state",this._getState());var _c1=(this._childConnections=[]),_c2=(this._childWatches=[]);dojo.forEach(dojo.filter(this._descendants,function(_c3){return _c3.validate;}),function(_c4){dojo.forEach(["state","disabled"],function(_c5){_c2.push(_c4.watch(_c5,function(_c6,_c7,_c8){_bf.set("state",_bf._getState());}));});});var _c9=function(){if(_bf._onChangeDelayTimer){clearTimeout(_bf._onChangeDelayTimer);}_bf._onChangeDelayTimer=setTimeout(function(){delete _bf._onChangeDelayTimer;_bf._set("value",_bf.get("value"));},10);};dojo.forEach(dojo.filter(this._descendants,function(_ca){return _ca.onChange;}),function(_cb){_c1.push(_bf.connect(_cb,"onChange",_c9));_c2.push(_cb.watch("disabled",_c9));});},startup:function(){this.inherited(arguments);this.connectChildren(true);this.watch("state",function(_cc,_cd,_ce){this.onValidStateChange(_ce=="");});},destroy:function(){this.disconnectChildren();this.inherited(arguments);}});}if(!dojo._hasResource["dijit._DialogMixin"]){dojo._hasResource["dijit._DialogMixin"]=true;dojo.provide("dijit._DialogMixin");dojo.declare("dijit._DialogMixin",null,{attributeMap:dijit._Widget.prototype.attributeMap,execute:function(_cf){},onCancel:function(){},onExecute:function(){},_onSubmit:function(){this.onExecute();this.execute(this.get("value"));},_getFocusItems:function(){var _d0=dijit._getTabNavigable(this.containerNode);this._firstFocusItem=_d0.lowest||_d0.first||this.closeButtonNode||this.domNode;this._lastFocusItem=_d0.last||_d0.highest||this._firstFocusItem;}});}if(!dojo._hasResource["dijit.DialogUnderlay"]){dojo._hasResource["dijit.DialogUnderlay"]=true;dojo.provide("dijit.DialogUnderlay");dojo.declare("dijit.DialogUnderlay",[dijit._Widget,dijit._Templated],{templateString:"
",dialogId:"","class":"",attributeMap:{id:"domNode"},_setDialogIdAttr:function(id){dojo.attr(this.node,"id",id+"_underlay");this._set("dialogId",id);},_setClassAttr:function(_d1){this.node.className="dijitDialogUnderlay "+_d1;this._set("class",_d1);},postCreate:function(){dojo.body().appendChild(this.domNode);},layout:function(){var is=this.node.style,os=this.domNode.style;os.display="none";var _d2=dojo.window.getBox();os.top=_d2.t+"px";os.left=_d2.l+"px";is.width=_d2.w+"px";is.height=_d2.h+"px";os.display="block";},show:function(){this.domNode.style.display="block";this.layout();this.bgIframe=new dijit.BackgroundIframe(this.domNode);},hide:function(){this.bgIframe.destroy();delete this.bgIframe;this.domNode.style.display="none";}});}if(!dojo._hasResource["dijit.layout._ContentPaneResizeMixin"]){dojo._hasResource["dijit.layout._ContentPaneResizeMixin"]=true;dojo.provide("dijit.layout._ContentPaneResizeMixin");dojo.declare("dijit.layout._ContentPaneResizeMixin",null,{doLayout:true,isContainer:true,isLayoutContainer:true,_startChildren:function(){dojo.forEach(this.getChildren(),function(_d3){_d3.startup();_d3._started=true;});},startup:function(){if(this._started){return;}var _d4=dijit._Contained.prototype.getParent.call(this);this._childOfLayoutWidget=_d4&&_d4.isLayoutContainer;this._needLayout=!this._childOfLayoutWidget;this.inherited(arguments);this._startChildren();},_checkIfSingleChild:function(){var _d5=dojo.query("> *",this.containerNode).filter(function(_d6){return _d6.tagName!=="SCRIPT";}),_d7=_d5.filter(function(_d8){return dojo.hasAttr(_d8,"data-dojo-type")||dojo.hasAttr(_d8,"dojoType")||dojo.hasAttr(_d8,"widgetId");}),_d9=dojo.filter(_d7.map(dijit.byNode),function(_da){return _da&&_da.domNode&&_da.resize;});if(_d5.length==_d7.length&&_d9.length==1){this._singleChild=_d9[0];}else{delete this._singleChild;}dojo.toggleClass(this.containerNode,this.baseClass+"SingleChild",!!this._singleChild);},resize:function(_db,_dc){this._layout(_db,_dc);},_layout:function(_dd,_de){if(_dd){dojo.marginBox(this.domNode,_dd);}var cn=this.containerNode;if(cn===this.domNode){var mb=_de||{};dojo.mixin(mb,_dd||{});if(!("h" in mb)||!("w" in mb)){mb=dojo.mixin(dojo.marginBox(cn),mb);}this._contentBox=dijit.layout.marginBox2contentBox(cn,mb);}else{this._contentBox=dojo.contentBox(cn);}this._layoutChildren();delete this._needLayout;},_layoutChildren:function(){if(this.doLayout){this._checkIfSingleChild();}if(this._singleChild&&this._singleChild.resize){var cb=this._contentBox||dojo.contentBox(this.containerNode);this._singleChild.resize({w:cb.w,h:cb.h});}else{dojo.forEach(this.getChildren(),function(_df){if(_df.resize){_df.resize();}});}}});}if(!dojo._hasResource["dojo.html"]){dojo._hasResource["dojo.html"]=true;dojo.provide("dojo.html");dojo.getObject("html",true,dojo);(function(){var _e0=0,d=dojo;dojo.html._secureForInnerHtml=function(_e1){return _e1.replace(/(?:\s*]+>|]*>[\s\S]*?<\/title>)/ig,"");};dojo.html._emptyNode=dojo.empty;dojo.html._setNodeContent=function(_e2,_e3){d.empty(_e2);if(_e3){if(typeof _e3=="string"){_e3=d._toDom(_e3,_e2.ownerDocument);}if(!_e3.nodeType&&d.isArrayLike(_e3)){for(var _e4=_e3.length,i=0;i<_e3.length;i=_e4==_e3.length?i+1:0){d.place(_e3[i],_e2,"last");}}else{d.place(_e3,_e2,"last");}}return _e2;};dojo.declare("dojo.html._ContentSetter",null,{node:"",content:"",id:"",cleanContent:false,extractContent:false,parseContent:false,parserScope:dojo._scopeName,startup:true,constructor:function(_e5,_e6){dojo.mixin(this,_e5||{});_e6=this.node=dojo.byId(this.node||_e6);if(!this.id){this.id=["Setter",(_e6)?_e6.id||_e6.tagName:"",_e0++].join("_");}},set:function(_e7,_e8){if(undefined!==_e7){this.content=_e7;}if(_e8){this._mixin(_e8);}this.onBegin();this.setContent();this.onEnd();return this.node;},setContent:function(){var _e9=this.node;if(!_e9){throw new Error(this.declaredClass+": setContent given no node");}try{_e9=dojo.html._setNodeContent(_e9,this.content);}catch(e){var _ea=this.onContentError(e);try{_e9.innerHTML=_ea;}catch(e){console.error("Fatal "+this.declaredClass+".setContent could not change content due to "+e.message,e);}}this.node=_e9;},empty:function(){if(this.parseResults&&this.parseResults.length){dojo.forEach(this.parseResults,function(w){if(w.destroy){w.destroy();}});delete this.parseResults;}dojo.html._emptyNode(this.node);},onBegin:function(){var _eb=this.content;if(dojo.isString(_eb)){if(this.cleanContent){_eb=dojo.html._secureForInnerHtml(_eb);}if(this.extractContent){var _ec=_eb.match(/]*>\s*([\s\S]+)\s*<\/body>/im);if(_ec){_eb=_ec[1];}}}this.empty();this.content=_eb;return this.node;},onEnd:function(){if(this.parseContent){this._parse();}return this.node;},tearDown:function(){delete this.parseResults;delete this.node;delete this.content;},onContentError:function(err){return "Error occured setting content: "+err;},_mixin:function(_ed){var _ee={},key;for(key in _ed){if(key in _ee){continue;}this[key]=_ed[key];}},_parse:function(){var _ef=this.node;try{this.parseResults=dojo.parser.parse({rootNode:_ef,noStart:!this.startup,inherited:{dir:this.dir,lang:this.lang},scope:this.parserScope});}catch(e){this._onError("Content",e,"Error parsing in _ContentSetter#"+this.id);}},_onError:function(_f0,err,_f1){var _f2=this["on"+_f0+"Error"].call(this,err);if(_f1){console.error(_f1,err);}else{if(_f2){dojo.html._setNodeContent(this.node,_f2,true);}}}});dojo.html.set=function(_f3,_f4,_f5){if(undefined==_f4){console.warn("dojo.html.set: no cont argument provided, using empty string");_f4="";}if(!_f5){return dojo.html._setNodeContent(_f3,_f4,true);}else{var op=new dojo.html._ContentSetter(dojo.mixin(_f5,{content:_f4,node:_f3}));return op.set();}};})();}if(!dojo._hasResource["dijit.layout.ContentPane"]){dojo._hasResource["dijit.layout.ContentPane"]=true;dojo.provide("dijit.layout.ContentPane");dojo.declare("dijit.layout.ContentPane",[dijit._Widget,dijit.layout._ContentPaneResizeMixin],{href:"",extractContent:false,parseOnLoad:true,parserScope:dojo._scopeName,preventCache:false,preload:false,refreshOnShow:false,loadingMessage:"${loadingState}",errorMessage:"${errorState}",isLoaded:false,baseClass:"dijitContentPane",ioArgs:{},onLoadDeferred:null,attributeMap:dojo.delegate(dijit._Widget.prototype.attributeMap,{title:[]}),stopParser:true,template:false,create:function(_f6,_f7){if((!_f6||!_f6.template)&&_f7&&!("href" in _f6)&&!("content" in _f6)){var df=dojo.doc.createDocumentFragment();_f7=dojo.byId(_f7);while(_f7.firstChild){df.appendChild(_f7.firstChild);}_f6=dojo.delegate(_f6,{content:df});}this.inherited(arguments,[_f6,_f7]);},postMixInProperties:function(){this.inherited(arguments);var _f8=dojo.i18n.getLocalization("dijit","loading",this.lang);this.loadingMessage=dojo.string.substitute(this.loadingMessage,_f8);this.errorMessage=dojo.string.substitute(this.errorMessage,_f8);},buildRendering:function(){this.inherited(arguments);if(!this.containerNode){this.containerNode=this.domNode;}this.domNode.title="";if(!dojo.attr(this.domNode,"role")){dijit.setWaiRole(this.domNode,"group");}},_startChildren:function(){this.inherited(arguments);if(this._contentSetter){dojo.forEach(this._contentSetter.parseResults,function(obj){if(!obj._started&&!obj._destroyed&&dojo.isFunction(obj.startup)){obj.startup();obj._started=true;}},this);}},startup:function(){if(this._started){return;}this.inherited(arguments);if(this._isShown()){this._onShow();}},setHref:function(_f9){dojo.deprecated("dijit.layout.ContentPane.setHref() is deprecated. Use set('href', ...) instead.","","2.0");return this.set("href",_f9);},_setHrefAttr:function(_fa){this.cancel();this.onLoadDeferred=new dojo.Deferred(dojo.hitch(this,"cancel"));this.onLoadDeferred.addCallback(dojo.hitch(this,"onLoad"));this._set("href",_fa);if(this.preload||(this._created&&this._isShown())){this._load();}else{this._hrefChanged=true;}return this.onLoadDeferred;},setContent:function(_fb){dojo.deprecated("dijit.layout.ContentPane.setContent() is deprecated. Use set('content', ...) instead.","","2.0");this.set("content",_fb);},_setContentAttr:function(_fc){this._set("href","");this.cancel();this.onLoadDeferred=new dojo.Deferred(dojo.hitch(this,"cancel"));if(this._created){this.onLoadDeferred.addCallback(dojo.hitch(this,"onLoad"));}this._setContent(_fc||"");this._isDownloaded=false;return this.onLoadDeferred;},_getContentAttr:function(){return this.containerNode.innerHTML;},cancel:function(){if(this._xhrDfd&&(this._xhrDfd.fired==-1)){this._xhrDfd.cancel();}delete this._xhrDfd;this.onLoadDeferred=null;},uninitialize:function(){if(this._beingDestroyed){this.cancel();}this.inherited(arguments);},destroyRecursive:function(_fd){if(this._beingDestroyed){return;}this.inherited(arguments);},resize:function(_fe,_ff){if(!this._wasShown&&this.open!==false){this._onShow();}this._resizeCalled=true;this._scheduleLayout(_fe,_ff);},_isShown:function(){if(this._childOfLayoutWidget){if(this._resizeCalled&&"open" in this){return this.open;}return this._resizeCalled;}else{if("open" in this){return this.open;}else{var node=this.domNode,_100=this.domNode.parentNode;return (node.style.display!="none")&&(node.style.visibility!="hidden")&&!dojo.hasClass(node,"dijitHidden")&&_100&&_100.style&&(_100.style.display!="none");}}},_onShow:function(){if(this.href){if(!this._xhrDfd&&(!this.isLoaded||this._hrefChanged||this.refreshOnShow)){var d=this.refresh();}}else{if(this._needLayout){this._layout(this._changeSize,this._resultSize);}}this.inherited(arguments);this._wasShown=true;return d;},refresh:function(){this.cancel();this.onLoadDeferred=new dojo.Deferred(dojo.hitch(this,"cancel"));this.onLoadDeferred.addCallback(dojo.hitch(this,"onLoad"));this._load();return this.onLoadDeferred;},_load:function(){this._setContent(this.onDownloadStart(),true);var self=this;var _101={preventCache:(this.preventCache||this.refreshOnShow),url:this.href,handleAs:"text"};if(dojo.isObject(this.ioArgs)){dojo.mixin(_101,this.ioArgs);}var hand=(this._xhrDfd=(this.ioMethod||dojo.xhrGet)(_101));hand.addCallback(function(html){try{self._isDownloaded=true;self._setContent(html,false);self.onDownloadEnd();}catch(err){self._onError("Content",err);}delete self._xhrDfd;return html;});hand.addErrback(function(err){if(!hand.canceled){self._onError("Download",err);}delete self._xhrDfd;return err;});delete this._hrefChanged;},_onLoadHandler:function(data){this._set("isLoaded",true);try{this.onLoadDeferred.callback(data);}catch(e){console.error("Error "+this.widgetId+" running custom onLoad code: "+e.message);}},_onUnloadHandler:function(){this._set("isLoaded",false);try{this.onUnload();}catch(e){console.error("Error "+this.widgetId+" running custom onUnload code: "+e.message);}},destroyDescendants:function(){if(this.isLoaded){this._onUnloadHandler();}var _102=this._contentSetter;dojo.forEach(this.getChildren(),function(_103){if(_103.destroyRecursive){_103.destroyRecursive();}});if(_102){dojo.forEach(_102.parseResults,function(_104){if(_104.destroyRecursive&&_104.domNode&&_104.domNode.parentNode==dojo.body()){_104.destroyRecursive();}});delete _102.parseResults;}dojo.html._emptyNode(this.containerNode);delete this._singleChild;},_setContent:function(cont,_105){this.destroyDescendants();var _106=this._contentSetter;if(!(_106&&_106 instanceof dojo.html._ContentSetter)){_106=this._contentSetter=new dojo.html._ContentSetter({node:this.containerNode,_onError:dojo.hitch(this,this._onError),onContentError:dojo.hitch(this,function(e){var _107=this.onContentError(e);try{this.containerNode.innerHTML=_107;}catch(e){console.error("Fatal "+this.id+" could not change content due to "+e.message,e);}})});}var _108=dojo.mixin({cleanContent:this.cleanContent,extractContent:this.extractContent,parseContent:this.parseOnLoad,parserScope:this.parserScope,startup:false,dir:this.dir,lang:this.lang},this._contentSetterParams||{});_106.set((dojo.isObject(cont)&&cont.domNode)?cont.domNode:cont,_108);delete this._contentSetterParams;if(this.doLayout){this._checkIfSingleChild();}if(!_105){if(this._started){this._startChildren();this._scheduleLayout();}this._onLoadHandler(cont);}},_onError:function(type,err,_109){this.onLoadDeferred.errback(err);var _10a=this["on"+type+"Error"].call(this,err);if(_109){console.error(_109,err);}else{if(_10a){this._setContent(_10a,true);}}},_scheduleLayout:function(_10b,_10c){if(this._isShown()){this._layout(_10b,_10c);}else{this._needLayout=true;this._changeSize=_10b;this._resultSize=_10c;}},onLoad:function(data){},onUnload:function(){},onDownloadStart:function(){return this.loadingMessage;},onContentError:function(_10d){},onDownloadError:function(_10e){return this.errorMessage;},onDownloadEnd:function(){}});}if(!dojo._hasResource["dijit.TooltipDialog"]){dojo._hasResource["dijit.TooltipDialog"]=true;dojo.provide("dijit.TooltipDialog");dojo.declare("dijit.TooltipDialog",[dijit.layout.ContentPane,dijit._Templated,dijit.form._FormMixin,dijit._DialogMixin],{title:"",doLayout:false,autofocus:true,baseClass:"dijitTooltipDialog",_firstFocusItem:null,_lastFocusItem:null,templateString:dojo.cache("dijit","templates/TooltipDialog.html","
\r\n\t
\r\n\t\t
\r\n\t
\r\n\t
\r\n
\r\n"),_setTitleAttr:function(_10f){this.containerNode.title=_10f;this._set("title",_10f);},postCreate:function(){this.inherited(arguments);this.connect(this.containerNode,"onkeypress","_onKey");},orient:function(node,_110,_111){var newC="dijitTooltipAB"+(_111.charAt(1)=="L"?"Left":"Right")+" dijitTooltip"+(_111.charAt(0)=="T"?"Below":"Above");dojo.replaceClass(this.domNode,newC,this._currentOrientClass||"");this._currentOrientClass=newC;},focus:function(){this._getFocusItems(this.containerNode);dijit.focus(this._firstFocusItem);},onOpen:function(pos){this.orient(this.domNode,pos.aroundCorner,pos.corner);this._onShow();},onClose:function(){this.onHide();},_onKey:function(evt){var node=evt.target;var dk=dojo.keys;if(evt.charOrCode===dk.TAB){this._getFocusItems(this.containerNode);}var _112=(this._firstFocusItem==this._lastFocusItem);if(evt.charOrCode==dk.ESCAPE){setTimeout(dojo.hitch(this,"onCancel"),0);dojo.stopEvent(evt);}else{if(node==this._firstFocusItem&&evt.shiftKey&&evt.charOrCode===dk.TAB){if(!_112){dijit.focus(this._lastFocusItem);}dojo.stopEvent(evt);}else{if(node==this._lastFocusItem&&evt.charOrCode===dk.TAB&&!evt.shiftKey){if(!_112){dijit.focus(this._firstFocusItem);}dojo.stopEvent(evt);}else{if(evt.charOrCode===dk.TAB){evt.stopPropagation();}}}}}});}if(!dojo._hasResource["dijit.Dialog"]){dojo._hasResource["dijit.Dialog"]=true;dojo.provide("dijit.Dialog");dojo.declare("dijit._DialogBase",[dijit._Templated,dijit.form._FormMixin,dijit._DialogMixin,dijit._CssStateMixin],{templateString:dojo.cache("dijit","templates/Dialog.html","
\r\n\t
\r\n\t\r\n\t\r\n\t\tx\r\n\t\r\n\t
\r\n\t\t
\r\n
\r\n"),baseClass:"dijitDialog",cssStateNodes:{closeButtonNode:"dijitDialogCloseIcon"},attributeMap:dojo.delegate(dijit._Widget.prototype.attributeMap,{title:[{node:"titleNode",type:"innerHTML"},{node:"titleBar",type:"attribute"}],"aria-describedby":""}),open:false,duration:dijit.defaultDuration,refocus:true,autofocus:true,_firstFocusItem:null,_lastFocusItem:null,doLayout:false,draggable:true,"aria-describedby":"",postMixInProperties:function(){var _113=dojo.i18n.getLocalization("dijit","common");dojo.mixin(this,_113);this.inherited(arguments);},postCreate:function(){dojo.style(this.domNode,{display:"none",position:"absolute"});dojo.body().appendChild(this.domNode);this.inherited(arguments);this.connect(this,"onExecute","hide");this.connect(this,"onCancel","hide");this._modalconnects=[];},onLoad:function(){this._position();if(this.autofocus&&dijit._DialogLevelManager.isTop(this)){this._getFocusItems(this.domNode);dijit.focus(this._firstFocusItem);}this.inherited(arguments);},_endDrag:function(e){if(e&&e.node&&e.node===this.domNode){this._relativePosition=dojo.position(e.node);}},_setup:function(){var node=this.domNode;if(this.titleBar&&this.draggable){this._moveable=(dojo.isIE==6)?new dojo.dnd.TimedMoveable(node,{handle:this.titleBar}):new dojo.dnd.Moveable(node,{handle:this.titleBar,timeout:0});this._dndListener=dojo.subscribe("/dnd/move/stop",this,"_endDrag");}else{dojo.addClass(node,"dijitDialogFixed");}this.underlayAttrs={dialogId:this.id,"class":dojo.map(this["class"].split(/\s/),function(s){return s+"_underlay";}).join(" ")};},_size:function(){this._checkIfSingleChild();if(this._singleChild){if(this._singleChildOriginalStyle){this._singleChild.domNode.style.cssText=this._singleChildOriginalStyle;}delete this._singleChildOriginalStyle;}else{dojo.style(this.containerNode,{width:"auto",height:"auto"});}var mb=dojo._getMarginSize(this.domNode);var _114=dojo.window.getBox();if(mb.w>=_114.w||mb.h>=_114.h){var w=Math.min(mb.w,Math.floor(_114.w*0.75)),h=Math.min(mb.h,Math.floor(_114.h*0.75));if(this._singleChild&&this._singleChild.resize){this._singleChildOriginalStyle=this._singleChild.domNode.style.cssText;this._singleChild.resize({w:w,h:h});}else{dojo.style(this.containerNode,{width:w+"px",height:h+"px",overflow:"auto",position:"relative"});}}else{if(this._singleChild&&this._singleChild.resize){this._singleChild.resize();}}},_position:function(){if(!dojo.hasClass(dojo.body(),"dojoMove")){var node=this.domNode,_115=dojo.window.getBox(),p=this._relativePosition,bb=p?null:dojo._getBorderBox(node),l=Math.floor(_115.l+(p?p.x:(_115.w-bb.w)/2)),t=Math.floor(_115.t+(p?p.y:(_115.h-bb.h)/2));dojo.style(node,{left:l+"px",top:t+"px"});}},_onKey:function(evt){if(evt.charOrCode){var dk=dojo.keys;var node=evt.target;if(evt.charOrCode===dk.TAB){this._getFocusItems(this.domNode);}var _116=(this._firstFocusItem==this._lastFocusItem);if(node==this._firstFocusItem&&evt.shiftKey&&evt.charOrCode===dk.TAB){if(!_116){dijit.focus(this._lastFocusItem);}dojo.stopEvent(evt);}else{if(node==this._lastFocusItem&&evt.charOrCode===dk.TAB&&!evt.shiftKey){if(!_116){dijit.focus(this._firstFocusItem);}dojo.stopEvent(evt);}else{while(node){if(node==this.domNode||dojo.hasClass(node,"dijitPopup")){if(evt.charOrCode==dk.ESCAPE){this.onCancel();}else{return;}}node=node.parentNode;}if(evt.charOrCode!==dk.TAB){dojo.stopEvent(evt);}else{if(!dojo.isOpera){try{this._firstFocusItem.focus();}catch(e){}}}}}}},show:function(){if(this.open){return;}if(!this._started){this.startup();}if(!this._alreadyInitialized){this._setup();this._alreadyInitialized=true;}if(this._fadeOutDeferred){this._fadeOutDeferred.cancel();}this._modalconnects.push(dojo.connect(window,"onscroll",this,"layout"));this._modalconnects.push(dojo.connect(window,"onresize",this,function(){var _117=dojo.window.getBox();if(!this._oldViewport||_117.h!=this._oldViewport.h||_117.w!=this._oldViewport.w){this.layout();this._oldViewport=_117;}}));this._modalconnects.push(dojo.connect(this.domNode,"onkeypress",this,"_onKey"));dojo.style(this.domNode,{opacity:0,display:""});this._set("open",true);this._onShow();this._size();this._position();var _118;this._fadeInDeferred=new dojo.Deferred(dojo.hitch(this,function(){_118.stop();delete this._fadeInDeferred;}));_118=dojo.fadeIn({node:this.domNode,duration:this.duration,beforeBegin:dojo.hitch(this,function(){dijit._DialogLevelManager.show(this,this.underlayAttrs);}),onEnd:dojo.hitch(this,function(){if(this.autofocus&&dijit._DialogLevelManager.isTop(this)){this._getFocusItems(this.domNode);dijit.focus(this._firstFocusItem);}this._fadeInDeferred.callback(true);delete this._fadeInDeferred;})}).play();return this._fadeInDeferred;},hide:function(){if(!this._alreadyInitialized){return;}if(this._fadeInDeferred){this._fadeInDeferred.cancel();}var _119;this._fadeOutDeferred=new dojo.Deferred(dojo.hitch(this,function(){_119.stop();delete this._fadeOutDeferred;}));_119=dojo.fadeOut({node:this.domNode,duration:this.duration,onEnd:dojo.hitch(this,function(){this.domNode.style.display="none";dijit._DialogLevelManager.hide(this);this.onHide();this._fadeOutDeferred.callback(true);delete this._fadeOutDeferred;})}).play();if(this._scrollConnected){this._scrollConnected=false;}dojo.forEach(this._modalconnects,dojo.disconnect);this._modalconnects=[];if(this._relativePosition){delete this._relativePosition;}this._set("open",false);return this._fadeOutDeferred;},layout:function(){if(this.domNode.style.display!="none"){if(dijit._underlay){dijit._underlay.layout();}this._position();}},destroy:function(){if(this._fadeInDeferred){this._fadeInDeferred.cancel();}if(this._fadeOutDeferred){this._fadeOutDeferred.cancel();}if(this._moveable){this._moveable.destroy();}if(this._dndListener){dojo.unsubscribe(this._dndListener);}dojo.forEach(this._modalconnects,dojo.disconnect);dijit._DialogLevelManager.hide(this);this.inherited(arguments);}});dojo.declare("dijit.Dialog",[dijit.layout.ContentPane,dijit._DialogBase],{});dijit._DialogLevelManager={show:function(_11a,_11b){var ds=dijit._dialogStack;ds[ds.length-1].focus=dijit.getFocus(_11a);var _11c=dijit._underlay;if(!_11c||_11c._destroyed){_11c=dijit._underlay=new dijit.DialogUnderlay(_11b);}else{_11c.set(_11a.underlayAttrs);}var _11d=ds[ds.length-1].dialog?ds[ds.length-1].zIndex+2:950;if(ds.length==1){_11c.show();}dojo.style(dijit._underlay.domNode,"zIndex",_11d-1);dojo.style(_11a.domNode,"zIndex",_11d);ds.push({dialog:_11a,underlayAttrs:_11b,zIndex:_11d});},hide:function(_11e){var ds=dijit._dialogStack;if(ds[ds.length-1].dialog==_11e){ds.pop();var pd=ds[ds.length-1];if(ds.length==1){if(!dijit._underlay._destroyed){dijit._underlay.hide();}}else{dojo.style(dijit._underlay.domNode,"zIndex",pd.zIndex-1);dijit._underlay.set(pd.underlayAttrs);}if(_11e.refocus){var _11f=pd.focus;if(!_11f||(pd.dialog&&!dojo.isDescendant(_11f.node,pd.dialog.domNode))){pd.dialog._getFocusItems(pd.dialog.domNode);_11f=pd.dialog._firstFocusItem;}try{dijit.focus(_11f);}catch(e){}}}else{var idx=dojo.indexOf(dojo.map(ds,function(elem){return elem.dialog;}),_11e);if(idx!=-1){ds.splice(idx,1);}}},isTop:function(_120){var ds=dijit._dialogStack;return ds[ds.length-1].dialog==_120;}};dijit._dialogStack=[{dialog:null,focus:null,underlayAttrs:null}];}if(!dojo._hasResource["dijit._editor.selection"]){dojo._hasResource["dijit._editor.selection"]=true;dojo.provide("dijit._editor.selection");dojo.getObject("_editor.selection",true,dijit);dojo.mixin(dijit._editor.selection,{getType:function(){if(dojo.isIE){return dojo.doc.selection.type.toLowerCase();}else{var _121="text";var oSel;try{oSel=dojo.global.getSelection();}catch(e){}if(oSel&&oSel.rangeCount==1){var _122=oSel.getRangeAt(0);if((_122.startContainer==_122.endContainer)&&((_122.endOffset-_122.startOffset)==1)&&(_122.startContainer.nodeType!=3)){_121="control";}}return _121;}},getSelectedText:function(){if(dojo.isIE){if(dijit._editor.selection.getType()=="control"){return null;}return dojo.doc.selection.createRange().text;}else{var _123=dojo.global.getSelection();if(_123){return _123.toString();}}return "";},getSelectedHtml:function(){if(dojo.isIE){if(dijit._editor.selection.getType()=="control"){return null;}return dojo.doc.selection.createRange().htmlText;}else{var _124=dojo.global.getSelection();if(_124&&_124.rangeCount){var i;var html="";for(i=0;i<_124.rangeCount;i++){var frag=_124.getRangeAt(i).cloneContents();var div=dojo.doc.createElement("div");div.appendChild(frag);html+=div.innerHTML;}return html;}return null;}},getSelectedElement:function(){if(dijit._editor.selection.getType()=="control"){if(dojo.isIE){var _125=dojo.doc.selection.createRange();if(_125&&_125.item){return dojo.doc.selection.createRange().item(0);}}else{var _126=dojo.global.getSelection();return _126.anchorNode.childNodes[_126.anchorOffset];}}return null;},getParentElement:function(){if(dijit._editor.selection.getType()=="control"){var p=this.getSelectedElement();if(p){return p.parentNode;}}else{if(dojo.isIE){var r=dojo.doc.selection.createRange();r.collapse(true);return r.parentElement();}else{var _127=dojo.global.getSelection();if(_127){var node=_127.anchorNode;while(node&&(node.nodeType!=1)){node=node.parentNode;}return node;}}}return null;},hasAncestorElement:function(_128){return this.getAncestorElement.apply(this,arguments)!=null;},getAncestorElement:function(_129){var node=this.getSelectedElement()||this.getParentElement();return this.getParentOfType(node,arguments);},isTag:function(node,tags){if(node&&node.tagName){var _12a=node.tagName.toLowerCase();for(var i=0;i0){_138=sel.getRangeAt(0);}if(_138&&_138.compareBoundaryPoints&&doc.createRange){try{_137=doc.createRange();_137.setStart(node,0);if(_138.compareBoundaryPoints(_138.START_TO_END,_137)===1){return true;}}catch(e){}}}else{if(doc.selection){_138=doc.selection.createRange();try{_137=node.ownerDocument.body.createControlRange();if(_137){_137.addElement(node);}}catch(e1){try{_137=node.ownerDocument.body.createTextRange();_137.moveToElementText(node);}catch(e2){}}if(_138&&_137){if(_138.compareEndPoints("EndToStart",_137)===1){return true;}}}}}return false;}});}if(!dojo._hasResource["dijit._editor.range"]){dojo._hasResource["dijit._editor.range"]=true;dojo.provide("dijit._editor.range");dijit.range={};dijit.range.getIndex=function(node,_139){var ret=[],retR=[];var stop=_139;var _13a=node;var _13b,n;while(node!=stop){var i=0;_13b=node.parentNode;while((n=_13b.childNodes[i++])){if(n===node){--i;break;}}ret.unshift(i);retR.unshift(i-_13b.childNodes.length);node=_13b;}if(ret.length>0&&_13a.nodeType==3){n=_13a.previousSibling;while(n&&n.nodeType==3){ret[ret.length-1]--;n=n.previousSibling;}n=_13a.nextSibling;while(n&&n.nodeType==3){retR[retR.length-1]++;n=n.nextSibling;}}return {o:ret,r:retR};};dijit.range.getNode=function(_13c,_13d){if(!dojo.isArray(_13c)||_13c.length==0){return _13d;}var node=_13d;dojo.every(_13c,function(i){if(i>=0&&i0){dojo.every(_15b.childNodes,function(node,i){var _15f;if(node.nodeType!=3){_159.moveToElementText(node);if(_159.compareEndPoints(_15a,_158)>0){if(_15e&&_15e.nodeType==3){_15c=_15e;_15f=true;}else{_15c=_15b;_15d=i;return false;}}else{if(i==_15b.childNodes.length-1){_15c=_15b;_15d=_15b.childNodes.length;return false;}}}else{if(i==_15b.childNodes.length-1){_15c=node;_15f=true;}}if(_15f&&_15c){var _160=dijit.range.adjacentNoneTextNode(_15c)[0];if(_160){_15c=_160.nextSibling;}else{_15c=_15b.firstChild;}var _161=dijit.range.adjacentNoneTextNode(_15c);_160=_161[0];var _162=_161[1];if(_160){_159.moveToElementText(_160);_159.collapse(false);}else{_159.moveToElementText(_15b);}_159.setEndPoint(_15a,_158);_15d=_159.text.length-_162;return false;}_15e=node;return true;});}else{_15c=_15b;_15d=0;}if(!end&&_15c.nodeType==1&&_15d==_15c.childNodes.length){var _163=_15c.nextSibling;if(_163&&_163.nodeType==3){_15c=_163;_15d=0;}}return [_15c,_15d];},setEndPoint:function(_164,_165,_166){var _167=_164.duplicate(),node,len;if(_165.nodeType!=3){if(_166>0){node=_165.childNodes[_166-1];if(node){if(node.nodeType==3){_165=node;_166=node.length;}else{if(node.nextSibling&&node.nextSibling.nodeType==3){_165=node.nextSibling;_166=0;}else{_167.moveToElementText(node.nextSibling?node:_165);var _168=node.parentNode;var _169=_168.insertBefore(node.ownerDocument.createTextNode(" "),node.nextSibling);_167.collapse(false);_168.removeChild(_169);}}}}else{_167.moveToElementText(_165);_167.collapse(true);}}if(_165.nodeType==3){var _16a=dijit.range.adjacentNoneTextNode(_165);var _16b=_16a[0];len=_16a[1];if(_16b){_167.moveToElementText(_16b);_167.collapse(false);if(_16b.contentEditable!="inherit"){len++;}}else{_167.moveToElementText(_165.parentNode);_167.collapse(true);}_166+=len;if(_166>0){if(_167.move("character",_166)!=_166){console.error("Error when moving!");}}}return _167;},decomposeTextRange:function(_16c){var _16d=dijit.range.ie.getEndPoint(_16c);var _16e=_16d[0],_16f=_16d[1];var _170=_16d[0],_171=_16d[1];if(_16c.htmlText.length){if(_16c.htmlText==_16c.text){_171=_16f+_16c.text.length;}else{_16d=dijit.range.ie.getEndPoint(_16c,true);_170=_16d[0],_171=_16d[1];}}return [_16e,_16f,_170,_171];},setRange:function(_172,_173,_174,_175,_176,_177){var _178=dijit.range.ie.setEndPoint(_172,_173,_174);_172.setEndPoint("StartToStart",_178);if(!_177){var end=dijit.range.ie.setEndPoint(_172,_175,_176);}_172.setEndPoint("EndToEnd",end||_178);return _172;}};dojo.declare("dijit.range.W3CRange",null,{constructor:function(){if(arguments.length>0){this.setStart(arguments[0][0],arguments[0][1]);this.setEnd(arguments[0][2],arguments[0][3]);}else{this.commonAncestorContainer=null;this.startContainer=null;this.startOffset=0;this.endContainer=null;this.endOffset=0;this.collapsed=true;}},_updateInternal:function(){if(this.startContainer!==this.endContainer){this.commonAncestorContainer=dijit.range.getCommonAncestor(this.startContainer,this.endContainer);}else{this.commonAncestorContainer=this.startContainer;}this.collapsed=(this.startContainer===this.endContainer)&&(this.startOffset==this.endOffset);},setStart:function(node,_179){_179=parseInt(_179);if(this.startContainer===node&&this.startOffset==_179){return;}delete this._cachedBookmark;this.startContainer=node;this.startOffset=_179;if(!this.endContainer){this.setEnd(node,_179);}else{this._updateInternal();}},setEnd:function(node,_17a){_17a=parseInt(_17a);if(this.endContainer===node&&this.endOffset==_17a){return;}delete this._cachedBookmark;this.endContainer=node;this.endOffset=_17a;if(!this.startContainer){this.setStart(node,_17a);}else{this._updateInternal();}},setStartAfter:function(node,_17b){this._setPoint("setStart",node,_17b,1);},setStartBefore:function(node,_17c){this._setPoint("setStart",node,_17c,0);},setEndAfter:function(node,_17d){this._setPoint("setEnd",node,_17d,1);},setEndBefore:function(node,_17e){this._setPoint("setEnd",node,_17e,0);},_setPoint:function(what,node,_17f,ext){var _180=dijit.range.getIndex(node,node.parentNode).o;this[what](node.parentNode,_180.pop()+ext);},_getIERange:function(){var r=(this._body||this.endContainer.ownerDocument.body).createTextRange();dijit.range.ie.setRange(r,this.startContainer,this.startOffset,this.endContainer,this.endOffset,this.collapsed);return r;},getBookmark:function(body){this._getIERange();return this._cachedBookmark;},_select:function(){var r=this._getIERange();r.select();},deleteContents:function(){var r=this._getIERange();r.pasteHTML("");this.endContainer=this.startContainer;this.endOffset=this.startOffset;this.collapsed=true;},cloneRange:function(){var r=new dijit.range.W3CRange([this.startContainer,this.startOffset,this.endContainer,this.endOffset]);r._body=this._body;return r;},detach:function(){this._body=null;this.commonAncestorContainer=null;this.startContainer=null;this.startOffset=0;this.endContainer=null;this.endOffset=0;this.collapsed=true;}});}}if(!dojo._hasResource["dijit._editor.html"]){dojo._hasResource["dijit._editor.html"]=true;dojo.provide("dijit._editor.html");dojo.getObject("_editor",true,dijit);dijit._editor.escapeXml=function(str,_181){str=str.replace(/&/gm,"&").replace(//gm,">").replace(/"/gm,""");if(!_181){str=str.replace(/'/gm,"'");}return str;};dijit._editor.getNodeHtml=function(node){var _182;switch(node.nodeType){case 1:var _183=node.nodeName.toLowerCase();if(!_183||_183.charAt(0)=="/"){return "";}_182="<"+_183;var _184=[];var attr;if(dojo.isIE&&node.outerHTML){var s=node.outerHTML;s=s.substr(0,s.indexOf(">")).replace(/(['"])[^"']*\1/g,"");var reg=/(\b\w+)\s?=/g;var m,key;while((m=reg.exec(s))){key=m[1];if(key.substr(0,3)!="_dj"){if(key=="src"||key=="href"){if(node.getAttribute("_djrealurl")){_184.push([key,node.getAttribute("_djrealurl")]);continue;}}var val,_185;switch(key){case "style":val=node.style.cssText.toLowerCase();break;case "class":val=node.className;break;case "width":if(_183==="img"){_185=/width=(\S+)/i.exec(s);if(_185){val=_185[1];}break;}case "height":if(_183==="img"){_185=/height=(\S+)/i.exec(s);if(_185){val=_185[1];}break;}default:val=node.getAttribute(key);}if(val!=null){_184.push([key,val.toString()]);}}}}else{var i=0;while((attr=node.attributes[i++])){var n=attr.name;if(n.substr(0,3)!="_dj"){var v=attr.value;if(n=="src"||n=="href"){if(node.getAttribute("_djrealurl")){v=node.getAttribute("_djrealurl");}}_184.push([n,v]);}}}_184.sort(function(a,b){return a[0]"+node.innerHTML+"";}else{if(node.childNodes.length){_182+=">"+dijit._editor.getChildrenHtml(node)+"";}else{switch(_183){case "br":case "hr":case "img":case "input":case "base":case "meta":case "area":case "basefont":_182+=" />";break;default:_182+=">";}}}break;case 4:case 3:_182=dijit._editor.escapeXml(node.nodeValue,true);break;case 8:_182="";break;default:_182="";}return _182;};dijit._editor.getChildrenHtml=function(dom){var out="";if(!dom){return out;}var _186=dom["childNodes"]||dom;var _187=!dojo.isIE||_186!==dom;var node,i=0;while((node=_186[i++])){if(!_187||node.parentNode==dom){out+=dijit._editor.getNodeHtml(node);}}return out;};}if(!dojo._hasResource["dijit._editor.RichText"]){dojo._hasResource["dijit._editor.RichText"]=true;dojo.provide("dijit._editor.RichText");if(!dojo.config["useXDomain"]||dojo.config["allowXdRichTextSave"]){if(dojo._postLoad){(function(){var _188=dojo.doc.createElement("textarea");_188.id=dijit._scopeName+"._editor.RichText.value";dojo.style(_188,{display:"none",position:"absolute",top:"-100px",height:"3px",width:"3px"});dojo.body().appendChild(_188);})();}else{try{dojo.doc.write("");}catch(e){}}}dojo.declare("dijit._editor.RichText",[dijit._Widget,dijit._CssStateMixin],{constructor:function(_189){this.contentPreFilters=[];this.contentPostFilters=[];this.contentDomPreFilters=[];this.contentDomPostFilters=[];this.editingAreaStyleSheets=[];this.events=[].concat(this.events);this._keyHandlers={};if(_189&&dojo.isString(_189.value)){this.value=_189.value;}this.onLoadDeferred=new dojo.Deferred();},baseClass:"dijitEditor",inheritWidth:false,focusOnLoad:false,name:"",styleSheets:"",height:"300px",minHeight:"1em",isClosed:true,isLoaded:false,_SEPARATOR:"@@**%%__RICHTEXTBOUNDRY__%%**@@",_NAME_CONTENT_SEP:"@@**%%:%%**@@",onLoadDeferred:null,isTabIndent:false,disableSpellCheck:false,postCreate:function(){if("textarea"==this.domNode.tagName.toLowerCase()){console.warn("RichText should not be used with the TEXTAREA tag. See dijit._editor.RichText docs.");}this.contentPreFilters=[dojo.hitch(this,"_preFixUrlAttributes")].concat(this.contentPreFilters);if(dojo.isMoz){this.contentPreFilters=[this._normalizeFontStyle].concat(this.contentPreFilters);this.contentPostFilters=[this._removeMozBogus].concat(this.contentPostFilters);}if(dojo.isWebKit){this.contentPreFilters=[this._removeWebkitBogus].concat(this.contentPreFilters);this.contentPostFilters=[this._removeWebkitBogus].concat(this.contentPostFilters);}if(dojo.isIE){this.contentPostFilters=[this._normalizeFontStyle].concat(this.contentPostFilters);}this.inherited(arguments);dojo.publish(dijit._scopeName+"._editor.RichText::init",[this]);this.open();this.setupDefaultShortcuts();},setupDefaultShortcuts:function(){var exec=dojo.hitch(this,function(cmd,arg){return function(){return !this.execCommand(cmd,arg);};});var _18a={b:exec("bold"),i:exec("italic"),u:exec("underline"),a:exec("selectall"),s:function(){this.save(true);},m:function(){this.isTabIndent=!this.isTabIndent;},"1":exec("formatblock","h1"),"2":exec("formatblock","h2"),"3":exec("formatblock","h3"),"4":exec("formatblock","h4"),"\\":exec("insertunorderedlist")};if(!dojo.isIE){_18a.Z=exec("redo");}for(var key in _18a){this.addKeyHandler(key,true,false,_18a[key]);}},events:["onKeyPress","onKeyDown","onKeyUp"],captureEvents:[],_editorCommandsLocalized:false,_localizeEditorCommands:function(){if(this._editorCommandsLocalized){return;}this._editorCommandsLocalized=true;var _18b=["div","p","pre","h1","h2","h3","h4","h5","h6","ol","ul","address"];var _18c="",_18d,i=0;while((_18d=_18b[i++])){if(_18d.charAt(1)!="l"){_18c+="<"+_18d+">content
";}else{_18c+="<"+_18d+">
  • content

  • ";}}var div=dojo.doc.createElement("div");dojo.style(div,{position:"absolute",top:"-2000px"});dojo.doc.body.appendChild(div);div.innerHTML=_18c;var node=div.firstChild;while(node){dijit._editor.selection.selectElement(node.firstChild);dojo.withGlobal(this.window,"selectElement",dijit._editor.selection,[node.firstChild]);var _18e=node.tagName.toLowerCase();this._local2NativeFormatNames[_18e]=document.queryCommandValue("formatblock");this._native2LocalFormatNames[this._local2NativeFormatNames[_18e]]=_18e;node=node.nextSibling.nextSibling;}dojo.body().removeChild(div);},open:function(_18f){if(!this.onLoadDeferred||this.onLoadDeferred.fired>=0){this.onLoadDeferred=new dojo.Deferred();}if(!this.isClosed){this.close();}dojo.publish(dijit._scopeName+"._editor.RichText::open",[this]);if(arguments.length==1&&_18f.nodeName){this.domNode=_18f;}var dn=this.domNode;var html;if(dojo.isString(this.value)){html=this.value;delete this.value;dn.innerHTML="";}else{if(dn.nodeName&&dn.nodeName.toLowerCase()=="textarea"){var ta=(this.textarea=dn);this.name=ta.name;html=ta.value;dn=this.domNode=dojo.doc.createElement("div");dn.setAttribute("widgetId",this.id);ta.removeAttribute("widgetId");dn.cssText=ta.cssText;dn.className+=" "+ta.className;dojo.place(dn,ta,"before");var _190=dojo.hitch(this,function(){dojo.style(ta,{display:"block",position:"absolute",top:"-1000px"});if(dojo.isIE){var s=ta.style;this.__overflow=s.overflow;s.overflow="hidden";}});if(dojo.isIE){setTimeout(_190,10);}else{_190();}if(ta.form){var _191=ta.value;this.reset=function(){var _192=this.getValue();if(_192!=_191){this.replaceValue(_191);}};dojo.connect(ta.form,"onsubmit",this,function(){dojo.attr(ta,"disabled",this.disabled);ta.value=this.getValue();});}}else{html=dijit._editor.getChildrenHtml(dn);dn.innerHTML="";}}var _193=dojo.contentBox(dn);this._oldHeight=_193.h;this._oldWidth=_193.w;this.value=html;if(dn.nodeName&&dn.nodeName=="LI"){dn.innerHTML="
    ";}this.header=dn.ownerDocument.createElement("div");dn.appendChild(this.header);this.editingArea=dn.ownerDocument.createElement("div");dn.appendChild(this.editingArea);this.footer=dn.ownerDocument.createElement("div");dn.appendChild(this.footer);if(!this.name){this.name=this.id+"_AUTOGEN";}if(this.name!==""&&(!dojo.config["useXDomain"]||dojo.config["allowXdRichTextSave"])){var _194=dojo.byId(dijit._scopeName+"._editor.RichText.value");if(_194&&_194.value!==""){var _195=_194.value.split(this._SEPARATOR),i=0,dat;while((dat=_195[i++])){var data=dat.split(this._NAME_CONTENT_SEP);if(data[0]==this.name){html=data[1];_195=_195.splice(i,1);_194.value=_195.join(this._SEPARATOR);break;}}}if(!dijit._editor._globalSaveHandler){dijit._editor._globalSaveHandler={};dojo.addOnUnload(function(){var id;for(id in dijit._editor._globalSaveHandler){var f=dijit._editor._globalSaveHandler[id];if(dojo.isFunction(f)){f();}}});}dijit._editor._globalSaveHandler[this.id]=dojo.hitch(this,"_saveContent");}this.isClosed=false;var ifr=(this.editorObject=this.iframe=dojo.doc.createElement("iframe"));ifr.id=this.id+"_iframe";this._iframeSrc=this._getIframeDocTxt();ifr.style.border="none";ifr.style.width="100%";if(this._layoutMode){ifr.style.height="100%";}else{if(dojo.isIE>=7){if(this.height){ifr.style.height=this.height;}if(this.minHeight){ifr.style.minHeight=this.minHeight;}}else{ifr.style.height=this.height?this.height:this.minHeight;}}ifr.frameBorder=0;ifr._loadFunc=dojo.hitch(this,function(win){this.window=win;this.document=this.window.document;if(dojo.isIE){this._localizeEditorCommands();}this.onLoad(html);});var s="javascript:parent."+dijit._scopeName+".byId(\""+this.id+"\")._iframeSrc";ifr.setAttribute("src",s);this.editingArea.appendChild(ifr);if(dojo.isSafari<=4){var src=ifr.getAttribute("src");if(!src||src.indexOf("javascript")==-1){setTimeout(function(){ifr.setAttribute("src",s);},0);}}if(dn.nodeName=="LI"){dn.lastChild.style.marginTop="-1.2em";}dojo.addClass(this.domNode,this.baseClass);},_local2NativeFormatNames:{},_native2LocalFormatNames:{},_getIframeDocTxt:function(){var _196=dojo.getComputedStyle(this.domNode);var html="";var _197=true;if(dojo.isIE||dojo.isWebKit||(!this.height&&!dojo.isMoz)){html="
    ";_197=false;}else{if(dojo.isMoz){this._cursorToStart=true;html=" ";}}var font=[_196.fontWeight,_196.fontSize,_196.fontFamily].join(" ");var _198=_196.lineHeight;if(_198.indexOf("px")>=0){_198=parseFloat(_198)/parseFloat(_196.fontSize);}else{if(_198.indexOf("em")>=0){_198=parseFloat(_198);}else{_198="normal";}}var _199="";var self=this;this.style.replace(/(^|;)\s*(line-|font-?)[^;]+/ig,function(_19a){_19a=_19a.replace(/^;/ig,"")+";";var s=_19a.split(":")[0];if(s){s=dojo.trim(s);s=s.toLowerCase();var i;var sC="";for(i=0;i\n\n":"\n\n",(dojo.isMoz&&_19b.length?""+_19b[0].innerHTML+"\n":""),"\n","\n",this._applyEditingAreaStyleSheets(),"\n","\n",html,"\n"].join("");},_applyEditingAreaStyleSheets:function(){var _19c=[];if(this.styleSheets){_19c=this.styleSheets.split(";");this.styleSheets="";}_19c=_19c.concat(this.editingAreaStyleSheets);this.editingAreaStyleSheets=[];var text="",i=0,url;while((url=_19c[i++])){var _19d=(new dojo._Url(dojo.global.location,url)).toString();this.editingAreaStyleSheets.push(_19d);text+="";}return text;},addStyleSheet:function(uri){var url=uri.toString();if(url.charAt(0)=="."||(url.charAt(0)!="/"&&!uri.host)){url=(new dojo._Url(dojo.global.location,url)).toString();}if(dojo.indexOf(this.editingAreaStyleSheets,url)>-1){return;}this.editingAreaStyleSheets.push(url);this.onLoadDeferred.addCallback(dojo.hitch(this,function(){if(this.document.createStyleSheet){this.document.createStyleSheet(url);}else{var head=this.document.getElementsByTagName("head")[0];var _19e=this.document.createElement("link");_19e.rel="stylesheet";_19e.type="text/css";_19e.href=url;head.appendChild(_19e);}}));},removeStyleSheet:function(uri){var url=uri.toString();if(url.charAt(0)=="."||(url.charAt(0)!="/"&&!uri.host)){url=(new dojo._Url(dojo.global.location,url)).toString();}var _19f=dojo.indexOf(this.editingAreaStyleSheets,url);if(_19f==-1){return;}delete this.editingAreaStyleSheets[_19f];dojo.withGlobal(this.window,"query",dojo,["link:[href=\""+url+"\"]"]).orphan();},disabled:false,_mozSettingProps:{"styleWithCSS":false},_setDisabledAttr:function(_1a0){_1a0=!!_1a0;this._set("disabled",_1a0);if(!this.isLoaded){return;}if(dojo.isIE||dojo.isWebKit||dojo.isOpera){var _1a1=dojo.isIE&&(this.isLoaded||!this.focusOnLoad);if(_1a1){this.editNode.unselectable="on";}this.editNode.contentEditable=!_1a0;if(_1a1){var _1a2=this;setTimeout(function(){_1a2.editNode.unselectable="off";},0);}}else{try{this.document.designMode=(_1a0?"off":"on");}catch(e){return;}if(!_1a0&&this._mozSettingProps){var ps=this._mozSettingProps;for(var n in ps){if(ps.hasOwnProperty(n)){try{this.document.execCommand(n,false,ps[n]);}catch(e2){}}}}}this._disabledOK=true;},onLoad:function(html){if(!this.window.__registeredWindow){this.window.__registeredWindow=true;this._iframeRegHandle=dijit.registerIframe(this.iframe);}if(!dojo.isIE&&!dojo.isWebKit&&(this.height||dojo.isMoz)){this.editNode=this.document.body;}else{this.editNode=this.document.body.firstChild;var _1a3=this;if(dojo.isIE){this.tabStop=dojo.create("div",{tabIndex:-1},this.editingArea);this.iframe.onfocus=function(){_1a3.editNode.setActive();};}}this.focusNode=this.editNode;var _1a4=this.events.concat(this.captureEvents);var ap=this.iframe?this.document:this.editNode;dojo.forEach(_1a4,function(item){this.connect(ap,item.toLowerCase(),item);},this);this.connect(ap,"onmouseup","onClick");if(dojo.isIE){this.connect(this.document,"onmousedown","_onIEMouseDown");this.editNode.style.zoom=1;}else{this.connect(this.document,"onmousedown",function(){delete this._cursorToStart;});}if(dojo.isWebKit){this._webkitListener=this.connect(this.document,"onmouseup","onDisplayChanged");this.connect(this.document,"onmousedown",function(e){var t=e.target;if(t&&(t===this.document.body||t===this.document)){setTimeout(dojo.hitch(this,"placeCursorAtEnd"),0);}});}if(dojo.isIE){try{this.document.execCommand("RespectVisibilityInDesign",true,null);}catch(e){}}this.isLoaded=true;this.set("disabled",this.disabled);var _1a5=dojo.hitch(this,function(){this.setValue(html);if(this.onLoadDeferred){this.onLoadDeferred.callback(true);}this.onDisplayChanged();if(this.focusOnLoad){dojo.addOnLoad(dojo.hitch(this,function(){setTimeout(dojo.hitch(this,"focus"),this.updateInterval);}));}this.value=this.getValue(true);});if(this.setValueDeferred){this.setValueDeferred.addCallback(_1a5);}else{_1a5();}},onKeyDown:function(e){if(e.keyCode===dojo.keys.TAB&&this.isTabIndent){dojo.stopEvent(e);if(this.queryCommandEnabled((e.shiftKey?"outdent":"indent"))){this.execCommand((e.shiftKey?"outdent":"indent"));}}if(dojo.isIE){if(e.keyCode==dojo.keys.TAB&&!this.isTabIndent){if(e.shiftKey&&!e.ctrlKey&&!e.altKey){this.iframe.focus();}else{if(!e.shiftKey&&!e.ctrlKey&&!e.altKey){this.tabStop.focus();}}}else{if(e.keyCode===dojo.keys.BACKSPACE&&this.document.selection.type==="Control"){dojo.stopEvent(e);this.execCommand("delete");}else{if((65<=e.keyCode&&e.keyCode<=90)||(e.keyCode>=37&&e.keyCode<=40)){e.charCode=e.keyCode;this.onKeyPress(e);}}}}return true;},onKeyUp:function(e){return;},setDisabled:function(_1a6){dojo.deprecated("dijit.Editor::setDisabled is deprecated","use dijit.Editor::attr(\"disabled\",boolean) instead",2);this.set("disabled",_1a6);},_setValueAttr:function(_1a7){this.setValue(_1a7);},_setDisableSpellCheckAttr:function(_1a8){if(this.document){dojo.attr(this.document.body,"spellcheck",!_1a8);}else{this.onLoadDeferred.addCallback(dojo.hitch(this,function(){dojo.attr(this.document.body,"spellcheck",!_1a8);}));}this._set("disableSpellCheck",_1a8);},onKeyPress:function(e){var c=(e.keyChar&&e.keyChar.toLowerCase())||e.keyCode,_1a9=this._keyHandlers[c],args=arguments;if(_1a9&&!e.altKey){dojo.some(_1a9,function(h){if(!(h.shift^e.shiftKey)&&!(h.ctrl^(e.ctrlKey||e.metaKey))){if(!h.handler.apply(this,args)){e.preventDefault();}return true;}},this);}if(!this._onKeyHitch){this._onKeyHitch=dojo.hitch(this,"onKeyPressed");}setTimeout(this._onKeyHitch,1);return true;},addKeyHandler:function(key,ctrl,_1aa,_1ab){if(!dojo.isArray(this._keyHandlers[key])){this._keyHandlers[key]=[];}this._keyHandlers[key].push({shift:_1aa||false,ctrl:ctrl||false,handler:_1ab});},onKeyPressed:function(){this.onDisplayChanged();},onClick:function(e){this.onDisplayChanged(e);},_onIEMouseDown:function(e){if(!this._focused&&!this.disabled){this.focus();}},_onBlur:function(e){this.inherited(arguments);var _1ac=this.getValue(true);if(_1ac!=this.value){this.onChange(_1ac);}this._set("value",_1ac);},_onFocus:function(e){if(!this.disabled){if(!this._disabledOK){this.set("disabled",false);}this.inherited(arguments);}},blur:function(){if(!dojo.isIE&&this.window.document.documentElement&&this.window.document.documentElement.focus){this.window.document.documentElement.focus();}else{if(dojo.doc.body.focus){dojo.doc.body.focus();}}},focus:function(){if(!this.isLoaded){this.focusOnLoad=true;return;}if(this._cursorToStart){delete this._cursorToStart;if(this.editNode.childNodes){this.placeCursorAtStart();return;}}if(!dojo.isIE){dijit.focus(this.iframe);}else{if(this.editNode&&this.editNode.focus){this.iframe.fireEvent("onfocus",document.createEventObject());}}},updateInterval:200,_updateTimer:null,onDisplayChanged:function(e){if(this._updateTimer){clearTimeout(this._updateTimer);}if(!this._updateHandler){this._updateHandler=dojo.hitch(this,"onNormalizedDisplayChanged");}this._updateTimer=setTimeout(this._updateHandler,this.updateInterval);},onNormalizedDisplayChanged:function(){delete this._updateTimer;},onChange:function(_1ad){},_normalizeCommand:function(cmd,_1ae){var _1af=cmd.toLowerCase();if(_1af=="formatblock"){if(dojo.isSafari&&_1ae===undefined){_1af="heading";}}else{if(_1af=="hilitecolor"&&!dojo.isMoz){_1af="backcolor";}}return _1af;},_qcaCache:{},queryCommandAvailable:function(_1b0){var ca=this._qcaCache[_1b0];if(ca!==undefined){return ca;}return (this._qcaCache[_1b0]=this._queryCommandAvailable(_1b0));},_queryCommandAvailable:function(_1b1){var ie=1;var _1b2=1<<1;var _1b3=1<<2;var _1b4=1<<3;function _1b5(_1b6){return {ie:Boolean(_1b6&ie),mozilla:Boolean(_1b6&_1b2),webkit:Boolean(_1b6&_1b3),opera:Boolean(_1b6&_1b4)};};var _1b7=null;switch(_1b1.toLowerCase()){case "bold":case "italic":case "underline":case "subscript":case "superscript":case "fontname":case "fontsize":case "forecolor":case "hilitecolor":case "justifycenter":case "justifyfull":case "justifyleft":case "justifyright":case "delete":case "selectall":case "toggledir":_1b7=_1b5(_1b2|ie|_1b3|_1b4);break;case "createlink":case "unlink":case "removeformat":case "inserthorizontalrule":case "insertimage":case "insertorderedlist":case "insertunorderedlist":case "indent":case "outdent":case "formatblock":case "inserthtml":case "undo":case "redo":case "strikethrough":case "tabindent":_1b7=_1b5(_1b2|ie|_1b4|_1b3);break;case "blockdirltr":case "blockdirrtl":case "dirltr":case "dirrtl":case "inlinedirltr":case "inlinedirrtl":_1b7=_1b5(ie);break;case "cut":case "copy":case "paste":_1b7=_1b5(ie|_1b2|_1b3);break;case "inserttable":_1b7=_1b5(_1b2|ie);break;case "insertcell":case "insertcol":case "insertrow":case "deletecells":case "deletecols":case "deleterows":case "mergecells":case "splitcell":_1b7=_1b5(ie|_1b2);break;default:return false;}return (dojo.isIE&&_1b7.ie)||(dojo.isMoz&&_1b7.mozilla)||(dojo.isWebKit&&_1b7.webkit)||(dojo.isOpera&&_1b7.opera);},execCommand:function(_1b8,_1b9){var _1ba;this.focus();_1b8=this._normalizeCommand(_1b8,_1b9);if(_1b9!==undefined){if(_1b8=="heading"){throw new Error("unimplemented");}else{if((_1b8=="formatblock")&&dojo.isIE){_1b9="<"+_1b9+">";}}}var _1bb="_"+_1b8+"Impl";if(this[_1bb]){_1ba=this[_1bb](_1b9);}else{_1b9=arguments.length>1?_1b9:null;if(_1b9||_1b8!="createlink"){_1ba=this.document.execCommand(_1b8,false,_1b9);}}this.onDisplayChanged();return _1ba;},queryCommandEnabled:function(_1bc){if(this.disabled||!this._disabledOK){return false;}_1bc=this._normalizeCommand(_1bc);if(dojo.isMoz||dojo.isWebKit){if(_1bc=="unlink"){return this._sCall("hasAncestorElement",["a"]);}else{if(_1bc=="inserttable"){return true;}}}if(dojo.isWebKit){if(_1bc=="cut"||_1bc=="copy"){var sel=this.window.getSelection();if(sel){sel=sel.toString();}return !!sel;}else{if(_1bc=="paste"){return true;}}}var elem=dojo.isIE?this.document.selection.createRange():this.document;try{return elem.queryCommandEnabled(_1bc);}catch(e){return false;}},queryCommandState:function(_1bd){if(this.disabled||!this._disabledOK){return false;}_1bd=this._normalizeCommand(_1bd);try{return this.document.queryCommandState(_1bd);}catch(e){return false;}},queryCommandValue:function(_1be){if(this.disabled||!this._disabledOK){return false;}var r;_1be=this._normalizeCommand(_1be);if(dojo.isIE&&_1be=="formatblock"){r=this._native2LocalFormatNames[this.document.queryCommandValue(_1be)];}else{if(dojo.isMoz&&_1be==="hilitecolor"){var _1bf;try{_1bf=this.document.queryCommandValue("styleWithCSS");}catch(e){_1bf=false;}this.document.execCommand("styleWithCSS",false,true);r=this.document.queryCommandValue(_1be);this.document.execCommand("styleWithCSS",false,_1bf);}else{r=this.document.queryCommandValue(_1be);}}return r;},_sCall:function(name,args){return dojo.withGlobal(this.window,name,dijit._editor.selection,args);},placeCursorAtStart:function(){this.focus();var _1c0=false;if(dojo.isMoz){var _1c1=this.editNode.firstChild;while(_1c1){if(_1c1.nodeType==3){if(_1c1.nodeValue.replace(/^\s+|\s+$/g,"").length>0){_1c0=true;this._sCall("selectElement",[_1c1]);break;}}else{if(_1c1.nodeType==1){_1c0=true;var tg=_1c1.tagName?_1c1.tagName.toLowerCase():"";if(/br|input|img|base|meta|area|basefont|hr|link/.test(tg)){this._sCall("selectElement",[_1c1]);}else{this._sCall("selectElementChildren",[_1c1]);}break;}}_1c1=_1c1.nextSibling;}}else{_1c0=true;this._sCall("selectElementChildren",[this.editNode]);}if(_1c0){this._sCall("collapse",[true]);}},placeCursorAtEnd:function(){this.focus();var _1c2=false;if(dojo.isMoz){var last=this.editNode.lastChild;while(last){if(last.nodeType==3){if(last.nodeValue.replace(/^\s+|\s+$/g,"").length>0){_1c2=true;this._sCall("selectElement",[last]);break;}}else{if(last.nodeType==1){_1c2=true;if(last.lastChild){this._sCall("selectElement",[last.lastChild]);}else{this._sCall("selectElement",[last]);}break;}}last=last.previousSibling;}}else{_1c2=true;this._sCall("selectElementChildren",[this.editNode]);}if(_1c2){this._sCall("collapse",[false]);}},getValue:function(_1c3){if(this.textarea){if(this.isClosed||!this.isLoaded){return this.textarea.value;}}return this._postFilterContent(null,_1c3);},_getValueAttr:function(){return this.getValue(true);},setValue:function(html){if(!this.isLoaded){this.onLoadDeferred.addCallback(dojo.hitch(this,function(){this.setValue(html);}));return;}this._cursorToStart=true;if(this.textarea&&(this.isClosed||!this.isLoaded)){this.textarea.value=html;}else{html=this._preFilterContent(html);var node=this.isClosed?this.domNode:this.editNode;if(html&&dojo.isMoz&&html.toLowerCase()=="

    "){html="

     

    ";}if(!html&&dojo.isWebKit){html=" ";}node.innerHTML=html;this._preDomFilterContent(node);}this.onDisplayChanged();this._set("value",this.getValue(true));},replaceValue:function(html){if(this.isClosed){this.setValue(html);}else{if(this.window&&this.window.getSelection&&!dojo.isMoz){this.setValue(html);}else{if(this.window&&this.window.getSelection){html=this._preFilterContent(html);this.execCommand("selectall");if(!html){this._cursorToStart=true;html=" ";}this.execCommand("inserthtml",html);this._preDomFilterContent(this.editNode);}else{if(this.document&&this.document.selection){this.setValue(html);}}}}this._set("value",this.getValue(true));},_preFilterContent:function(html){var ec=html;dojo.forEach(this.contentPreFilters,function(ef){if(ef){ec=ef(ec);}});return ec;},_preDomFilterContent:function(dom){dom=dom||this.editNode;dojo.forEach(this.contentDomPreFilters,function(ef){if(ef&&dojo.isFunction(ef)){ef(dom);}},this);},_postFilterContent:function(dom,_1c4){var ec;if(!dojo.isString(dom)){dom=dom||this.editNode;if(this.contentDomPostFilters.length){if(_1c4){dom=dojo.clone(dom);}dojo.forEach(this.contentDomPostFilters,function(ef){dom=ef(dom);});}ec=dijit._editor.getChildrenHtml(dom);}else{ec=dom;}if(!dojo.trim(ec.replace(/^\xA0\xA0*/,"").replace(/\xA0\xA0*$/,"")).length){ec="";}dojo.forEach(this.contentPostFilters,function(ef){ec=ef(ec);});return ec;},_saveContent:function(e){var _1c5=dojo.byId(dijit._scopeName+"._editor.RichText.value");if(_1c5.value){_1c5.value+=this._SEPARATOR;}_1c5.value+=this.name+this._NAME_CONTENT_SEP+this.getValue(true);},escapeXml:function(str,_1c6){str=str.replace(/&/gm,"&").replace(//gm,">").replace(/"/gm,""");if(!_1c6){str=str.replace(/'/gm,"'");}return str;},getNodeHtml:function(node){dojo.deprecated("dijit.Editor::getNodeHtml is deprecated","use dijit._editor.getNodeHtml instead",2);return dijit._editor.getNodeHtml(node);},getNodeChildrenHtml:function(dom){dojo.deprecated("dijit.Editor::getNodeChildrenHtml is deprecated","use dijit._editor.getChildrenHtml instead",2);return dijit._editor.getChildrenHtml(dom);},close:function(save){if(this.isClosed){return;}if(!arguments.length){save=true;}if(save){this._set("value",this.getValue(true));}if(this.interval){clearInterval(this.interval);}if(this._webkitListener){this.disconnect(this._webkitListener);delete this._webkitListener;}if(dojo.isIE){this.iframe.onfocus=null;}this.iframe._loadFunc=null;if(this._iframeRegHandle){dijit.unregisterIframe(this._iframeRegHandle);delete this._iframeRegHandle;}if(this.textarea){var s=this.textarea.style;s.position="";s.left=s.top="";if(dojo.isIE){s.overflow=this.__overflow;this.__overflow=null;}this.textarea.value=this.value;dojo.destroy(this.domNode);this.domNode=this.textarea;}else{this.domNode.innerHTML=this.value;}delete this.iframe;dojo.removeClass(this.domNode,this.baseClass);this.isClosed=true;this.isLoaded=false;delete this.editNode;delete this.focusNode;if(this.window&&this.window._frameElement){this.window._frameElement=null;}this.window=null;this.document=null;this.editingArea=null;this.editorObject=null;},destroy:function(){if(!this.isClosed){this.close(false);}this.inherited(arguments);if(dijit._editor._globalSaveHandler){delete dijit._editor._globalSaveHandler[this.id];}},_removeMozBogus:function(html){return html.replace(/\stype="_moz"/gi,"").replace(/\s_moz_dirty=""/gi,"").replace(/_moz_resizing="(true|false)"/gi,"");},_removeWebkitBogus:function(html){html=html.replace(/\sclass="webkit-block-placeholder"/gi,"");html=html.replace(/\sclass="apple-style-span"/gi,"");html=html.replace(//gi,"");return html;},_normalizeFontStyle:function(html){return html.replace(/<(\/)?strong([ \>])/gi,"<$1b$2").replace(/<(\/)?em([ \>])/gi,"<$1i$2");},_preFixUrlAttributes:function(html){return html.replace(/(?:(]+))/gi,"$1$4$2$3$5$2 _djrealurl=$2$3$5$2").replace(/(?:(]+))/gi,"$1$4$2$3$5$2 _djrealurl=$2$3$5$2");},_inserthorizontalruleImpl:function(_1c7){if(dojo.isIE){return this._inserthtmlImpl("
    ");}return this.document.execCommand("inserthorizontalrule",false,_1c7);},_unlinkImpl:function(_1c8){if((this.queryCommandEnabled("unlink"))&&(dojo.isMoz||dojo.isWebKit)){var a=this._sCall("getAncestorElement",["a"]);this._sCall("selectElement",[a]);return this.document.execCommand("unlink",false,null);}return this.document.execCommand("unlink",false,_1c8);},_hilitecolorImpl:function(_1c9){var _1ca;if(dojo.isMoz){this.document.execCommand("styleWithCSS",false,true);_1ca=this.document.execCommand("hilitecolor",false,_1c9);this.document.execCommand("styleWithCSS",false,false);}else{_1ca=this.document.execCommand("hilitecolor",false,_1c9);}return _1ca;},_backcolorImpl:function(_1cb){if(dojo.isIE){_1cb=_1cb?_1cb:null;}return this.document.execCommand("backcolor",false,_1cb);},_forecolorImpl:function(_1cc){if(dojo.isIE){_1cc=_1cc?_1cc:null;}return this.document.execCommand("forecolor",false,_1cc);},_inserthtmlImpl:function(_1cd){_1cd=this._preFilterContent(_1cd);var rv=true;if(dojo.isIE){var _1ce=this.document.selection.createRange();if(this.document.selection.type.toUpperCase()=="CONTROL"){var n=_1ce.item(0);while(_1ce.length){_1ce.remove(_1ce.item(0));}n.outerHTML=_1cd;}else{_1ce.pasteHTML(_1cd);}_1ce.select();}else{if(dojo.isMoz&&!_1cd.length){this._sCall("remove");}else{rv=this.document.execCommand("inserthtml",false,_1cd);}}return rv;},_boldImpl:function(_1cf){if(dojo.isIE){this._adaptIESelection();}return this.document.execCommand("bold",false,_1cf);},_italicImpl:function(_1d0){if(dojo.isIE){this._adaptIESelection();}return this.document.execCommand("italic",false,_1d0);},_underlineImpl:function(_1d1){if(dojo.isIE){this._adaptIESelection();}return this.document.execCommand("underline",false,_1d1);},_strikethroughImpl:function(_1d2){if(dojo.isIE){this._adaptIESelection();}return this.document.execCommand("strikethrough",false,_1d2);},getHeaderHeight:function(){return this._getNodeChildrenHeight(this.header);},getFooterHeight:function(){return this._getNodeChildrenHeight(this.footer);},_getNodeChildrenHeight:function(node){var h=0;if(node&&node.childNodes){var i;for(i=0;i0){return this._isNodeEmpty(node.childNodes[0],_1d3);}return true;}else{if(node.nodeType==3){return (node.nodeValue.substring(_1d3)=="");}}return false;},_removeStartingRangeFromRange:function(node,_1d4){if(node.nextSibling){_1d4.setStart(node.nextSibling,0);}else{var _1d5=node.parentNode;while(_1d5&&_1d5.nextSibling==null){_1d5=_1d5.parentNode;}if(_1d5){_1d4.setStart(_1d5.nextSibling,0);}}return _1d4;},_adaptIESelection:function(){var _1d6=dijit.range.getSelection(this.window);if(_1d6&&_1d6.rangeCount){var _1d7=_1d6.getRangeAt(0);var _1d8=_1d7.startContainer;var _1d9=_1d7.startOffset;while(_1d8.nodeType==3&&_1d9>=_1d8.length&&_1d8.nextSibling){_1d9=_1d9-_1d8.length;_1d8=_1d8.nextSibling;}var _1da=null;while(this._isNodeEmpty(_1d8,_1d9)&&_1d8!=_1da){_1da=_1d8;_1d7=this._removeStartingRangeFromRange(_1d8,_1d7);_1d8=_1d7.startContainer;_1d9=0;}_1d6.removeAllRanges();_1d6.addRange(_1d7);}}});}if(!dojo._hasResource["dijit._KeyNavContainer"]){dojo._hasResource["dijit._KeyNavContainer"]=true;dojo.provide("dijit._KeyNavContainer");dojo.declare("dijit._KeyNavContainer",dijit._Container,{tabIndex:"0",_keyNavCodes:{},connectKeyNavHandlers:function(_1db,_1dc){var _1dd=(this._keyNavCodes={});var prev=dojo.hitch(this,this.focusPrev);var next=dojo.hitch(this,this.focusNext);dojo.forEach(_1db,function(code){_1dd[code]=prev;});dojo.forEach(_1dc,function(code){_1dd[code]=next;});_1dd[dojo.keys.HOME]=dojo.hitch(this,"focusFirstChild");_1dd[dojo.keys.END]=dojo.hitch(this,"focusLastChild");this.connect(this.domNode,"onkeypress","_onContainerKeypress");this.connect(this.domNode,"onfocus","_onContainerFocus");},startupKeyNavChildren:function(){dojo.forEach(this.getChildren(),dojo.hitch(this,"_startupChild"));},addChild:function(_1de,_1df){dijit._KeyNavContainer.superclass.addChild.apply(this,arguments);this._startupChild(_1de);},focus:function(){this.focusFirstChild();},focusFirstChild:function(){var _1e0=this._getFirstFocusableChild();if(_1e0){this.focusChild(_1e0);}},focusLastChild:function(){var _1e1=this._getLastFocusableChild();if(_1e1){this.focusChild(_1e1);}},focusNext:function(){var _1e2=this._getNextFocusableChild(this.focusedChild,1);this.focusChild(_1e2);},focusPrev:function(){var _1e3=this._getNextFocusableChild(this.focusedChild,-1);this.focusChild(_1e3,true);},focusChild:function(_1e4,last){if(this.focusedChild&&_1e4!==this.focusedChild){this._onChildBlur(this.focusedChild);}_1e4.focus(last?"end":"start");this._set("focusedChild",_1e4);},_startupChild:function(_1e5){_1e5.set("tabIndex","-1");this.connect(_1e5,"_onFocus",function(){_1e5.set("tabIndex",this.tabIndex);});this.connect(_1e5,"_onBlur",function(){_1e5.set("tabIndex","-1");});},_onContainerFocus:function(evt){if(evt.target!==this.domNode){return;}this.focusFirstChild();dojo.attr(this.domNode,"tabIndex","-1");},_onBlur:function(evt){if(this.tabIndex){dojo.attr(this.domNode,"tabIndex",this.tabIndex);}this.inherited(arguments);},_onContainerKeypress:function(evt){if(evt.ctrlKey||evt.altKey){return;}var func=this._keyNavCodes[evt.charOrCode];if(func){func();dojo.stopEvent(evt);}},_onChildBlur:function(_1e6){},_getFirstFocusableChild:function(){return this._getNextFocusableChild(null,1);},_getLastFocusableChild:function(){return this._getNextFocusableChild(null,-1);},_getNextFocusableChild:function(_1e7,dir){if(_1e7){_1e7=this._getSiblingOfChild(_1e7,dir);}var _1e8=this.getChildren();for(var i=0;i<_1e8.length;i++){if(!_1e7){_1e7=_1e8[(dir>0)?0:(_1e8.length-1)];}if(_1e7.isFocusable()){return _1e7;}_1e7=this._getSiblingOfChild(_1e7,dir);}return null;}});}if(!dojo._hasResource["dijit.ToolbarSeparator"]){dojo._hasResource["dijit.ToolbarSeparator"]=true;dojo.provide("dijit.ToolbarSeparator");dojo.declare("dijit.ToolbarSeparator",[dijit._Widget,dijit._Templated],{templateString:"
    ",buildRendering:function(){this.inherited(arguments);dojo.setSelectable(this.domNode,false);},isFocusable:function(){return false;}});}if(!dojo._hasResource["dijit.Toolbar"]){dojo._hasResource["dijit.Toolbar"]=true;dojo.provide("dijit.Toolbar");dojo.declare("dijit.Toolbar",[dijit._Widget,dijit._Templated,dijit._KeyNavContainer],{templateString:"
    "+"
    ",baseClass:"dijitToolbar",postCreate:function(){this.inherited(arguments);this.connectKeyNavHandlers(this.isLeftToRight()?[dojo.keys.LEFT_ARROW]:[dojo.keys.RIGHT_ARROW],this.isLeftToRight()?[dojo.keys.RIGHT_ARROW]:[dojo.keys.LEFT_ARROW]);},startup:function(){if(this._started){return;}this.startupKeyNavChildren();this.inherited(arguments);}});}if(!dojo._hasResource["dijit._HasDropDown"]){dojo._hasResource["dijit._HasDropDown"]=true;dojo.provide("dijit._HasDropDown");dojo.declare("dijit._HasDropDown",null,{_buttonNode:null,_arrowWrapperNode:null,_popupStateNode:null,_aroundNode:null,dropDown:null,autoWidth:true,forceWidth:false,maxHeight:0,dropDownPosition:["below","above"],_stopClickEvents:true,_onDropDownMouseDown:function(e){if(this.disabled||this.readOnly){return;}this._docHandler=this.connect(dojo.doc,"onmouseup","_onDropDownMouseUp");this.toggleDropDown();},_onDropDownMouseUp:function(e){if(e&&this._docHandler){this.disconnect(this._docHandler);}var _1e9=this.dropDown,_1ea=false;if(e&&this._opened){var c=dojo.position(this._buttonNode,true);if(!(e.pageX>=c.x&&e.pageX<=c.x+c.w)||!(e.pageY>=c.y&&e.pageY<=c.y+c.h)){var t=e.target;while(t&&!_1ea){if(dojo.hasClass(t,"dijitPopup")){_1ea=true;}else{t=t.parentNode;}}if(_1ea){t=e.target;if(_1e9.onItemClick){var _1eb;while(t&&!(_1eb=dijit.byNode(t))){t=t.parentNode;}if(_1eb&&_1eb.onClick&&_1eb.getParent){_1eb.getParent().onItemClick(_1eb,e);}}return;}}}if(this._opened&&_1e9.focus&&_1e9.autoFocus!==false){window.setTimeout(dojo.hitch(_1e9,"focus"),1);}},_onDropDownClick:function(e){if(this._stopClickEvents){dojo.stopEvent(e);}},buildRendering:function(){this.inherited(arguments);this._buttonNode=this._buttonNode||this.focusNode||this.domNode;this._popupStateNode=this._popupStateNode||this.focusNode||this._buttonNode;var _1ec={"after":this.isLeftToRight()?"Right":"Left","before":this.isLeftToRight()?"Left":"Right","above":"Up","below":"Down","left":"Left","right":"Right"}[this.dropDownPosition[0]]||this.dropDownPosition[0]||"Down";dojo.addClass(this._arrowWrapperNode||this._buttonNode,"dijit"+_1ec+"ArrowButton");},postCreate:function(){this.inherited(arguments);this.connect(this._buttonNode,"onmousedown","_onDropDownMouseDown");this.connect(this._buttonNode,"onclick","_onDropDownClick");this.connect(this.focusNode,"onkeypress","_onKey");},destroy:function(){if(this.dropDown){if(!this.dropDown._destroyed){this.dropDown.destroyRecursive();}delete this.dropDown;}this.inherited(arguments);},_onKey:function(e){if(this.disabled||this.readOnly){return;}var d=this.dropDown,_1ed=e.target;if(d&&this._opened&&d.handleKey){if(d.handleKey(e)===false){dojo.stopEvent(e);return;}}if(d&&this._opened&&e.charOrCode==dojo.keys.ESCAPE){this.closeDropDown();dojo.stopEvent(e);}else{if(!this._opened&&(e.charOrCode==dojo.keys.DOWN_ARROW||((e.charOrCode==dojo.keys.ENTER||e.charOrCode==" ")&&((_1ed.tagName||"").toLowerCase()!=="input"||(_1ed.type&&_1ed.type.toLowerCase()!=="text"))))){this.toggleDropDown();d=this.dropDown;if(d&&d.focus){setTimeout(dojo.hitch(d,"focus"),1);}dojo.stopEvent(e);}}},_onBlur:function(){var _1ee=dijit._curFocus&&this.dropDown&&dojo.isDescendant(dijit._curFocus,this.dropDown.domNode);this.closeDropDown(_1ee);this.inherited(arguments);},isLoaded:function(){return true;},loadDropDown:function(_1ef){_1ef();},toggleDropDown:function(){if(this.disabled||this.readOnly){return;}if(!this._opened){if(!this.isLoaded()){this.loadDropDown(dojo.hitch(this,"openDropDown"));return;}else{this.openDropDown();}}else{this.closeDropDown();}},openDropDown:function(){var _1f0=this.dropDown,_1f1=_1f0.domNode,_1f2=this._aroundNode||this.domNode,self=this;if(!this._preparedNode){this._preparedNode=true;if(_1f1.style.width){this._explicitDDWidth=true;}if(_1f1.style.height){this._explicitDDHeight=true;}}if(this.maxHeight||this.forceWidth||this.autoWidth){var _1f3={display:"",visibility:"hidden"};if(!this._explicitDDWidth){_1f3.width="";}if(!this._explicitDDHeight){_1f3.height="";}dojo.style(_1f1,_1f3);var _1f4=this.maxHeight;if(_1f4==-1){var _1f5=dojo.window.getBox(),_1f6=dojo.position(_1f2,false);_1f4=Math.floor(Math.max(_1f6.y,_1f5.h-(_1f6.y+_1f6.h)));}if(_1f0.startup&&!_1f0._started){_1f0.startup();}dijit.popup.moveOffScreen(_1f0);var mb=dojo._getMarginSize(_1f1);var _1f7=(_1f4&&mb.h>_1f4);dojo.style(_1f1,{overflowX:"hidden",overflowY:_1f7?"auto":"hidden"});if(_1f7){mb.h=_1f4;if("w" in mb){mb.w+=16;}}else{delete mb.h;}if(this.forceWidth){mb.w=_1f2.offsetWidth;}else{if(this.autoWidth){mb.w=Math.max(mb.w,_1f2.offsetWidth);}else{delete mb.w;}}if(dojo.isFunction(_1f0.resize)){_1f0.resize(mb);}else{dojo.marginBox(_1f1,mb);}}var _1f8=dijit.popup.open({parent:this,popup:_1f0,around:_1f2,orient:dijit.getPopupAroundAlignment((this.dropDownPosition&&this.dropDownPosition.length)?this.dropDownPosition:["below"],this.isLeftToRight()),onExecute:function(){self.closeDropDown(true);},onCancel:function(){self.closeDropDown(true);},onClose:function(){dojo.attr(self._popupStateNode,"popupActive",false);dojo.removeClass(self._popupStateNode,"dijitHasDropDownOpen");self._opened=false;}});dojo.attr(this._popupStateNode,"popupActive","true");dojo.addClass(self._popupStateNode,"dijitHasDropDownOpen");this._opened=true;return _1f8;},closeDropDown:function(_1f9){if(this._opened){if(_1f9){this.focus();}dijit.popup.close(this.dropDown);this._opened=false;}}});}if(!dojo._hasResource["dijit.form.Button"]){dojo._hasResource["dijit.form.Button"]=true;dojo.provide("dijit.form.Button");dojo.declare("dijit.form.Button",dijit.form._FormWidget,{label:"",showLabel:true,iconClass:"",type:"button",baseClass:"dijitButton",templateString:dojo.cache("dijit.form","templates/Button.html","\r\n"),attributeMap:dojo.delegate(dijit.form._FormWidget.prototype.attributeMap,{value:"valueNode"}),_onClick:function(e){if(this.disabled){return false;}this._clicked();return this.onClick(e);},_onButtonClick:function(e){if(this._onClick(e)===false){e.preventDefault();}else{if(this.type=="submit"&&!(this.valueNode||this.focusNode).form){for(var node=this.domNode;node.parentNode;node=node.parentNode){var _1fa=dijit.byNode(node);if(_1fa&&typeof _1fa._onSubmit=="function"){_1fa._onSubmit(e);break;}}}else{if(this.valueNode){this.valueNode.click();e.preventDefault();}}}},buildRendering:function(){this.inherited(arguments);dojo.setSelectable(this.focusNode,false);},_fillContent:function(_1fb){if(_1fb&&(!this.params||!("label" in this.params))){this.set("label",_1fb.innerHTML);}},_setShowLabelAttr:function(val){if(this.containerNode){dojo.toggleClass(this.containerNode,"dijitDisplayNone",!val);}this._set("showLabel",val);},onClick:function(e){return true;},_clicked:function(e){},setLabel:function(_1fc){dojo.deprecated("dijit.form.Button.setLabel() is deprecated. Use set('label', ...) instead.","","2.0");this.set("label",_1fc);},_setLabelAttr:function(_1fd){this._set("label",_1fd);this.containerNode.innerHTML=_1fd;if(this.showLabel==false&&!this.params.title){this.titleNode.title=dojo.trim(this.containerNode.innerText||this.containerNode.textContent||"");}},_setIconClassAttr:function(val){var _1fe=this.iconClass||"dijitNoIcon",_1ff=val||"dijitNoIcon";dojo.replaceClass(this.iconNode,_1ff,_1fe);this._set("iconClass",val);}});dojo.declare("dijit.form.DropDownButton",[dijit.form.Button,dijit._Container,dijit._HasDropDown],{baseClass:"dijitDropDownButton",templateString:dojo.cache("dijit.form","templates/DropDownButton.html","\r\n"),_fillContent:function(){if(this.srcNodeRef){var _200=dojo.query("*",this.srcNodeRef);dijit.form.DropDownButton.superclass._fillContent.call(this,_200[0]);this.dropDownContainer=this.srcNodeRef;}},startup:function(){if(this._started){return;}if(!this.dropDown&&this.dropDownContainer){var _201=dojo.query("[widgetId]",this.dropDownContainer)[0];this.dropDown=dijit.byNode(_201);delete this.dropDownContainer;}if(this.dropDown){dijit.popup.hide(this.dropDown);}this.inherited(arguments);},isLoaded:function(){var _202=this.dropDown;return (!!_202&&(!_202.href||_202.isLoaded));},loadDropDown:function(){var _203=this.dropDown;if(!_203){return;}if(!this.isLoaded()){var _204=dojo.connect(_203,"onLoad",this,function(){dojo.disconnect(_204);this.openDropDown();});_203.refresh();}else{this.openDropDown();}},isFocusable:function(){return this.inherited(arguments)&&!this._mouseDown;}});dojo.declare("dijit.form.ComboButton",dijit.form.DropDownButton,{templateString:dojo.cache("dijit.form","templates/ComboButton.html","
    \r\n"),attributeMap:dojo.mixin(dojo.clone(dijit.form.Button.prototype.attributeMap),{id:"",tabIndex:["focusNode","titleNode"],title:"titleNode"}),optionsTitle:"",baseClass:"dijitComboButton",cssStateNodes:{"buttonNode":"dijitButtonNode","titleNode":"dijitButtonContents","_popupStateNode":"dijitDownArrowButton"},_focusedNode:null,_onButtonKeyPress:function(evt){if(evt.charOrCode==dojo.keys[this.isLeftToRight()?"RIGHT_ARROW":"LEFT_ARROW"]){dijit.focus(this._popupStateNode);dojo.stopEvent(evt);}},_onArrowKeyPress:function(evt){if(evt.charOrCode==dojo.keys[this.isLeftToRight()?"LEFT_ARROW":"RIGHT_ARROW"]){dijit.focus(this.titleNode);dojo.stopEvent(evt);}},focus:function(_205){if(!this.disabled){dijit.focus(_205=="start"?this.titleNode:this._popupStateNode);}}});dojo.declare("dijit.form.ToggleButton",dijit.form.Button,{baseClass:"dijitToggleButton",checked:false,attributeMap:dojo.mixin(dojo.clone(dijit.form.Button.prototype.attributeMap),{checked:"focusNode"}),_clicked:function(evt){this.set("checked",!this.checked);},_setCheckedAttr:function(_206,_207){this._set("checked",_206);dojo.attr(this.focusNode||this.domNode,"checked",_206);dijit.setWaiState(this.focusNode||this.domNode,"pressed",_206);this._handleOnChange(_206,_207);},setChecked:function(_208){dojo.deprecated("setChecked("+_208+") is deprecated. Use set('checked',"+_208+") instead.","","2.0");this.set("checked",_208);},reset:function(){this._hasBeenBlurred=false;this.set("checked",this.params.checked||false);}});}if(!dojo._hasResource["dijit._editor._Plugin"]){dojo._hasResource["dijit._editor._Plugin"]=true;dojo.provide("dijit._editor._Plugin");dojo.declare("dijit._editor._Plugin",null,{constructor:function(args,node){this.params=args||{};dojo.mixin(this,this.params);this._connects=[];this._attrPairNames={};},editor:null,iconClassPrefix:"dijitEditorIcon",button:null,command:"",useDefaultCommand:true,buttonClass:dijit.form.Button,disabled:false,getLabel:function(key){return this.editor.commands[key];},_initButton:function(){if(this.command.length){var _209=this.getLabel(this.command),_20a=this.editor,_20b=this.iconClassPrefix+" "+this.iconClassPrefix+this.command.charAt(0).toUpperCase()+this.command.substr(1);if(!this.button){var _20c=dojo.mixin({label:_209,dir:_20a.dir,lang:_20a.lang,showLabel:false,iconClass:_20b,dropDown:this.dropDown,tabIndex:"-1"},this.params||{});this.button=new this.buttonClass(_20c);}}if(this.get("disabled")&&this.button){this.button.set("disabled",this.get("disabled"));}},destroy:function(){dojo.forEach(this._connects,dojo.disconnect);if(this.dropDown){this.dropDown.destroyRecursive();}},connect:function(o,f,tf){this._connects.push(dojo.connect(o,f,this,tf));},updateState:function(){var e=this.editor,c=this.command,_20d,_20e;if(!e||!e.isLoaded||!c.length){return;}var _20f=this.get("disabled");if(this.button){try{_20e=!_20f&&e.queryCommandEnabled(c);if(this.enabled!==_20e){this.enabled=_20e;this.button.set("disabled",!_20e);}if(typeof this.button.checked=="boolean"){_20d=e.queryCommandState(c);if(this.checked!==_20d){this.checked=_20d;this.button.set("checked",e.queryCommandState(c));}}}catch(e){}}},setEditor:function(_210){this.editor=_210;this._initButton();if(this.button&&this.useDefaultCommand){if(this.editor.queryCommandAvailable(this.command)){this.connect(this.button,"onClick",dojo.hitch(this.editor,"execCommand",this.command,this.commandArg));}else{this.button.domNode.style.display="none";}}this.connect(this.editor,"onNormalizedDisplayChanged","updateState");},setToolbar:function(_211){if(this.button){_211.addChild(this.button);}},set:function(name,_212){if(typeof name==="object"){for(var x in name){this.set(x,name[x]);}return this;}var _213=this._getAttrNames(name);if(this[_213.s]){var _214=this[_213.s].apply(this,Array.prototype.slice.call(arguments,1));}else{this._set(name,_212);}return _214||this;},get:function(name){var _215=this._getAttrNames(name);return this[_215.g]?this[_215.g]():this[name];},_setDisabledAttr:function(_216){this.disabled=_216;this.updateState();},_getAttrNames:function(name){var apn=this._attrPairNames;if(apn[name]){return apn[name];}var uc=name.charAt(0).toUpperCase()+name.substr(1);return (apn[name]={s:"_set"+uc+"Attr",g:"_get"+uc+"Attr"});},_set:function(name,_217){var _218=this[name];this[name]=_217;}});}if(!dojo._hasResource["dijit._editor.plugins.EnterKeyHandling"]){dojo._hasResource["dijit._editor.plugins.EnterKeyHandling"]=true;dojo.provide("dijit._editor.plugins.EnterKeyHandling");dojo.declare("dijit._editor.plugins.EnterKeyHandling",dijit._editor._Plugin,{blockNodeForEnter:"BR",constructor:function(args){if(args){if("blockNodeForEnter" in args){args.blockNodeForEnter=args.blockNodeForEnter.toUpperCase();}dojo.mixin(this,args);}},setEditor:function(_219){if(this.editor===_219){return;}this.editor=_219;if(this.blockNodeForEnter=="BR"){this.editor.customUndo=true;_219.onLoadDeferred.addCallback(dojo.hitch(this,function(d){this.connect(_219.document,"onkeypress",function(e){if(e.charOrCode==dojo.keys.ENTER){var ne=dojo.mixin({},e);ne.shiftKey=true;if(!this.handleEnterKey(ne)){dojo.stopEvent(e);}}});return d;}));}else{if(this.blockNodeForEnter){var h=dojo.hitch(this,this.handleEnterKey);_219.addKeyHandler(13,0,0,h);_219.addKeyHandler(13,0,1,h);this.connect(this.editor,"onKeyPressed","onKeyPressed");}}},onKeyPressed:function(e){if(this._checkListLater){if(dojo.withGlobal(this.editor.window,"isCollapsed",dijit)){var _21a=dojo.withGlobal(this.editor.window,"getAncestorElement",dijit._editor.selection,["LI"]);if(!_21a){dijit._editor.RichText.prototype.execCommand.call(this.editor,"formatblock",this.blockNodeForEnter);var _21b=dojo.withGlobal(this.editor.window,"getAncestorElement",dijit._editor.selection,[this.blockNodeForEnter]);if(_21b){_21b.innerHTML=this.bogusHtmlContent;if(dojo.isIE){var r=this.editor.document.selection.createRange();r.move("character",-1);r.select();}}else{console.error("onKeyPressed: Cannot find the new block node");}}else{if(dojo.isMoz){if(_21a.parentNode.parentNode.nodeName=="LI"){_21a=_21a.parentNode.parentNode;}}var fc=_21a.firstChild;if(fc&&fc.nodeType==1&&(fc.nodeName=="UL"||fc.nodeName=="OL")){_21a.insertBefore(fc.ownerDocument.createTextNode(" "),fc);var _21c=dijit.range.create(this.editor.window);_21c.setStart(_21a.firstChild,0);var _21d=dijit.range.getSelection(this.editor.window,true);_21d.removeAllRanges();_21d.addRange(_21c);}}}this._checkListLater=false;}if(this._pressedEnterInBlock){if(this._pressedEnterInBlock.previousSibling){this.removeTrailingBr(this._pressedEnterInBlock.previousSibling);}delete this._pressedEnterInBlock;}},bogusHtmlContent:" ",blockNodes:/^(?:P|H1|H2|H3|H4|H5|H6|LI)$/,handleEnterKey:function(e){var _21e,_21f,_220,doc=this.editor.document,br,rs,txt;if(e.shiftKey){var _221=dojo.withGlobal(this.editor.window,"getParentElement",dijit._editor.selection);var _222=dijit.range.getAncestor(_221,this.blockNodes);if(_222){if(_222.tagName=="LI"){return true;}_21e=dijit.range.getSelection(this.editor.window);_21f=_21e.getRangeAt(0);if(!_21f.collapsed){_21f.deleteContents();_21e=dijit.range.getSelection(this.editor.window);_21f=_21e.getRangeAt(0);}if(dijit.range.atBeginningOfContainer(_222,_21f.startContainer,_21f.startOffset)){br=doc.createElement("br");_220=dijit.range.create(this.editor.window);_222.insertBefore(br,_222.firstChild);_220.setStartBefore(br.nextSibling);_21e.removeAllRanges();_21e.addRange(_220);}else{if(dijit.range.atEndOfContainer(_222,_21f.startContainer,_21f.startOffset)){_220=dijit.range.create(this.editor.window);br=doc.createElement("br");_222.appendChild(br);_222.appendChild(doc.createTextNode(" "));_220.setStart(_222.lastChild,0);_21e.removeAllRanges();_21e.addRange(_220);}else{rs=_21f.startContainer;if(rs&&rs.nodeType==3){txt=rs.nodeValue;dojo.withGlobal(this.editor.window,function(){var _223=doc.createTextNode(txt.substring(0,_21f.startOffset));var _224=doc.createTextNode(txt.substring(_21f.startOffset));var _225=doc.createElement("br");if(_224.nodeValue==""&&dojo.isWebKit){_224=doc.createTextNode(" ");}dojo.place(_223,rs,"after");dojo.place(_225,_223,"after");dojo.place(_224,_225,"after");dojo.destroy(rs);_220=dijit.range.create(dojo.gobal);_220.setStart(_224,0);_21e.removeAllRanges();_21e.addRange(_220);});return false;}return true;}}}else{_21e=dijit.range.getSelection(this.editor.window);if(_21e.rangeCount){_21f=_21e.getRangeAt(0);if(_21f&&_21f.startContainer){if(!_21f.collapsed){_21f.deleteContents();_21e=dijit.range.getSelection(this.editor.window);_21f=_21e.getRangeAt(0);}rs=_21f.startContainer;var _226,_227,_228;if(rs&&rs.nodeType==3){dojo.withGlobal(this.editor.window,dojo.hitch(this,function(){var _229=false;var _22a=_21f.startOffset;if(rs.length<_22a){ret=this._adjustNodeAndOffset(rs,_22a);rs=ret.node;_22a=ret.offset;}txt=rs.nodeValue;_226=doc.createTextNode(txt.substring(0,_22a));_227=doc.createTextNode(txt.substring(_22a));_228=doc.createElement("br");if(!_227.length){_227=doc.createTextNode(" ");_229=true;}if(_226.length){dojo.place(_226,rs,"after");}else{_226=rs;}dojo.place(_228,_226,"after");dojo.place(_227,_228,"after");dojo.destroy(rs);_220=dijit.range.create(dojo.gobal);_220.setStart(_227,0);_220.setEnd(_227,_227.length);_21e.removeAllRanges();_21e.addRange(_220);if(_229&&!dojo.isWebKit){dijit._editor.selection.remove();}else{dijit._editor.selection.collapse(true);}}));}else{dojo.withGlobal(this.editor.window,dojo.hitch(this,function(){var _22b=doc.createElement("br");rs.appendChild(_22b);var _22c=doc.createTextNode(" ");rs.appendChild(_22c);_220=dijit.range.create(dojo.global);_220.setStart(_22c,0);_220.setEnd(_22c,_22c.length);_21e.removeAllRanges();_21e.addRange(_220);dijit._editor.selection.collapse(true);}));}}}else{dijit._editor.RichText.prototype.execCommand.call(this.editor,"inserthtml","
    ");}}return false;}var _22d=true;_21e=dijit.range.getSelection(this.editor.window);_21f=_21e.getRangeAt(0);if(!_21f.collapsed){_21f.deleteContents();_21e=dijit.range.getSelection(this.editor.window);_21f=_21e.getRangeAt(0);}var _22e=dijit.range.getBlockAncestor(_21f.endContainer,null,this.editor.editNode);var _22f=_22e.blockNode;if((this._checkListLater=(_22f&&(_22f.nodeName=="LI"||_22f.parentNode.nodeName=="LI")))){if(dojo.isMoz){this._pressedEnterInBlock=_22f;}if(/^(\s| |\xA0|]*\bclass=['"]Apple-style-span['"][^>]*>(\s| |\xA0)<\/span>)?(
    )?$/.test(_22f.innerHTML)){_22f.innerHTML="";if(dojo.isWebKit){_220=dijit.range.create(this.editor.window);_220.setStart(_22f,0);_21e.removeAllRanges();_21e.addRange(_220);}this._checkListLater=false;}return true;}if(!_22e.blockNode||_22e.blockNode===this.editor.editNode){try{dijit._editor.RichText.prototype.execCommand.call(this.editor,"formatblock",this.blockNodeForEnter);}catch(e2){}_22e={blockNode:dojo.withGlobal(this.editor.window,"getAncestorElement",dijit._editor.selection,[this.blockNodeForEnter]),blockContainer:this.editor.editNode};if(_22e.blockNode){if(_22e.blockNode!=this.editor.editNode&&(!(_22e.blockNode.textContent||_22e.blockNode.innerHTML).replace(/^\s+|\s+$/g,"").length)){this.removeTrailingBr(_22e.blockNode);return false;}}else{_22e.blockNode=this.editor.editNode;}_21e=dijit.range.getSelection(this.editor.window);_21f=_21e.getRangeAt(0);}var _230=doc.createElement(this.blockNodeForEnter);_230.innerHTML=this.bogusHtmlContent;this.removeTrailingBr(_22e.blockNode);var _231=_21f.endOffset;var node=_21f.endContainer;if(node.length<_231){var ret=this._adjustNodeAndOffset(node,_231);node=ret.node;_231=ret.offset;}if(dijit.range.atEndOfContainer(_22e.blockNode,node,_231)){if(_22e.blockNode===_22e.blockContainer){_22e.blockNode.appendChild(_230);}else{dojo.place(_230,_22e.blockNode,"after");}_22d=false;_220=dijit.range.create(this.editor.window);_220.setStart(_230,0);_21e.removeAllRanges();_21e.addRange(_220);if(this.editor.height){dojo.window.scrollIntoView(_230);}}else{if(dijit.range.atBeginningOfContainer(_22e.blockNode,_21f.startContainer,_21f.startOffset)){dojo.place(_230,_22e.blockNode,_22e.blockNode===_22e.blockContainer?"first":"before");if(_230.nextSibling&&this.editor.height){_220=dijit.range.create(this.editor.window);_220.setStart(_230.nextSibling,0);_21e.removeAllRanges();_21e.addRange(_220);dojo.window.scrollIntoView(_230.nextSibling);}_22d=false;}else{if(_22e.blockNode===_22e.blockContainer){_22e.blockNode.appendChild(_230);}else{dojo.place(_230,_22e.blockNode,"after");}_22d=false;if(_22e.blockNode.style){if(_230.style){if(_22e.blockNode.style.cssText){_230.style.cssText=_22e.blockNode.style.cssText;}}}rs=_21f.startContainer;if(rs&&rs.nodeType==3){var _232,_233;_231=_21f.endOffset;if(rs.length<_231){ret=this._adjustNodeAndOffset(rs,_231);rs=ret.node;_231=ret.offset;}txt=rs.nodeValue;var _226=doc.createTextNode(txt.substring(0,_231));var _227=doc.createTextNode(txt.substring(_231,txt.length));dojo.place(_226,rs,"before");dojo.place(_227,rs,"after");dojo.destroy(rs);var _234=_226.parentNode;while(_234!==_22e.blockNode){var tg=_234.tagName;var _235=doc.createElement(tg);if(_234.style){if(_235.style){if(_234.style.cssText){_235.style.cssText=_234.style.cssText;}}}_232=_227;while(_232){_233=_232.nextSibling;_235.appendChild(_232);_232=_233;}dojo.place(_235,_234,"after");_226=_234;_227=_235;_234=_234.parentNode;}_232=_227;if(_232.nodeType==1||(_232.nodeType==3&&_232.nodeValue)){_230.innerHTML="";}while(_232){_233=_232.nextSibling;_230.appendChild(_232);_232=_233;}}_220=dijit.range.create(this.editor.window);_220.setStart(_230,0);_21e.removeAllRanges();_21e.addRange(_220);if(this.editor.height){dijit.scrollIntoView(_230);}if(dojo.isMoz){this._pressedEnterInBlock=_22e.blockNode;}}}return _22d;},_adjustNodeAndOffset:function(node,_236){while(node.length<_236&&node.nextSibling&&node.nextSibling.nodeType==3){_236=_236-node.length;node=node.nextSibling;}var ret={"node":node,"offset":_236};return ret;},removeTrailingBr:function(_237){var para=/P|DIV|LI/i.test(_237.tagName)?_237:dijit._editor.selection.getParentOfType(_237,["P","DIV","LI"]);if(!para){return;}if(para.lastChild){if((para.childNodes.length>1&¶.lastChild.nodeType==3&&/^[\s\xAD]*$/.test(para.lastChild.nodeValue))||para.lastChild.tagName=="BR"){dojo.destroy(para.lastChild);}}if(!para.childNodes.length){para.innerHTML=this.bogusHtmlContent;}}});}if(!dojo._hasResource["dijit.Editor"]){dojo._hasResource["dijit.Editor"]=true;dojo.provide("dijit.Editor");dojo.declare("dijit.Editor",dijit._editor.RichText,{plugins:null,extraPlugins:null,constructor:function(){if(!dojo.isArray(this.plugins)){this.plugins=["undo","redo","|","cut","copy","paste","|","bold","italic","underline","strikethrough","|","insertOrderedList","insertUnorderedList","indent","outdent","|","justifyLeft","justifyRight","justifyCenter","justifyFull","dijit._editor.plugins.EnterKeyHandling"];}this._plugins=[];this._editInterval=this.editActionInterval*1000;if(dojo.isIE){this.events.push("onBeforeDeactivate");this.events.push("onBeforeActivate");}},postMixInProperties:function(){this.setValueDeferred=new dojo.Deferred();this.inherited(arguments);},postCreate:function(){this._steps=this._steps.slice(0);this._undoedSteps=this._undoedSteps.slice(0);if(dojo.isArray(this.extraPlugins)){this.plugins=this.plugins.concat(this.extraPlugins);}this.inherited(arguments);this.commands=dojo.i18n.getLocalization("dijit._editor","commands",this.lang);if(!this.toolbar){this.toolbar=new dijit.Toolbar({dir:this.dir,lang:this.lang});this.header.appendChild(this.toolbar.domNode);}dojo.forEach(this.plugins,this.addPlugin,this);this.setValueDeferred.callback(true);dojo.addClass(this.iframe.parentNode,"dijitEditorIFrameContainer");dojo.addClass(this.iframe,"dijitEditorIFrame");dojo.attr(this.iframe,"allowTransparency",true);if(dojo.isWebKit){dojo.style(this.domNode,"KhtmlUserSelect","none");}this.toolbar.startup();this.onNormalizedDisplayChanged();},destroy:function(){dojo.forEach(this._plugins,function(p){if(p&&p.destroy){p.destroy();}});this._plugins=[];this.toolbar.destroyRecursive();delete this.toolbar;this.inherited(arguments);},addPlugin:function(_238,_239){var args=dojo.isString(_238)?{name:_238}:_238;if(!args.setEditor){var o={"args":args,"plugin":null,"editor":this};dojo.publish(dijit._scopeName+".Editor.getPlugin",[o]);if(!o.plugin){var pc=dojo.getObject(args.name);if(pc){o.plugin=new pc(args);}}if(!o.plugin){console.warn("Cannot find plugin",_238);return;}_238=o.plugin;}if(arguments.length>1){this._plugins[_239]=_238;}else{this._plugins.push(_238);}_238.setEditor(this);if(dojo.isFunction(_238.setToolbar)){_238.setToolbar(this.toolbar);}},startup:function(){},resize:function(size){if(size){dijit.layout._LayoutWidget.prototype.resize.apply(this,arguments);}},layout:function(){var _23a=(this._contentBox.h-(this.getHeaderHeight()+this.getFooterHeight()+dojo._getPadBorderExtents(this.iframe.parentNode).h+dojo._getMarginExtents(this.iframe.parentNode).h));this.editingArea.style.height=_23a+"px";if(this.iframe){this.iframe.style.height="100%";}this._layoutMode=true;},_onIEMouseDown:function(e){var _23b;var b=this.document.body;var _23c=b.clientWidth;var _23d=b.clientHeight;var _23e=b.clientLeft;var _23f=b.offsetWidth;var _240=b.offsetHeight;var _241=b.offsetLeft;bodyDir=b.dir?b.dir.toLowerCase():"";if(bodyDir!="rtl"){if(_23c<_23f&&e.x>_23c&&e.x<_23f){_23b=true;}}else{if(e.x<_23e&&e.x>_241){_23b=true;}}if(!_23b){if(_23d<_240&&e.y>_23d&&e.y<_240){_23b=true;}}if(!_23b){delete this._cursorToStart;delete this._savedSelection;if(e.target.tagName=="BODY"){setTimeout(dojo.hitch(this,"placeCursorAtEnd"),0);}this.inherited(arguments);}},onBeforeActivate:function(e){this._restoreSelection();},onBeforeDeactivate:function(e){if(this.customUndo){this.endEditing(true);}if(e.target.tagName!="BODY"){this._saveSelection();}},customUndo:true,editActionInterval:3,beginEditing:function(cmd){if(!this._inEditing){this._inEditing=true;this._beginEditing(cmd);}if(this.editActionInterval>0){if(this._editTimer){clearTimeout(this._editTimer);}this._editTimer=setTimeout(dojo.hitch(this,this.endEditing),this._editInterval);}},_steps:[],_undoedSteps:[],execCommand:function(cmd){if(this.customUndo&&(cmd=="undo"||cmd=="redo")){return this[cmd]();}else{if(this.customUndo){this.endEditing();this._beginEditing();}var r;var _242=/copy|cut|paste/.test(cmd);try{r=this.inherited(arguments);if(dojo.isWebKit&&_242&&!r){throw {code:1011};}}catch(e){if(e.code==1011&&_242){var sub=dojo.string.substitute,_243={cut:"X",copy:"C",paste:"V"};alert(sub(this.commands.systemShortcut,[this.commands[cmd],sub(this.commands[dojo.isMac?"appleKey":"ctrlKey"],[_243[cmd]])]));}r=false;}if(this.customUndo){this._endEditing();}return r;}},queryCommandEnabled:function(cmd){if(this.customUndo&&(cmd=="undo"||cmd=="redo")){return cmd=="undo"?(this._steps.length>1):(this._undoedSteps.length>0);}else{return this.inherited(arguments);}},_moveToBookmark:function(b){var _244=b.mark;var mark=b.mark;var col=b.isCollapsed;var r,_245,_246,sel;if(mark){if(dojo.isIE){if(dojo.isArray(mark)){_244=[];dojo.forEach(mark,function(n){_244.push(dijit.range.getNode(n,this.editNode));},this);dojo.withGlobal(this.window,"moveToBookmark",dijit,[{mark:_244,isCollapsed:col}]);}else{if(mark.startContainer&&mark.endContainer){sel=dijit.range.getSelection(this.window);if(sel&&sel.removeAllRanges){sel.removeAllRanges();r=dijit.range.create(this.window);_245=dijit.range.getNode(mark.startContainer,this.editNode);_246=dijit.range.getNode(mark.endContainer,this.editNode);if(_245&&_246){r.setStart(_245,mark.startOffset);r.setEnd(_246,mark.endOffset);sel.addRange(r);}}}}}else{sel=dijit.range.getSelection(this.window);if(sel&&sel.removeAllRanges){sel.removeAllRanges();r=dijit.range.create(this.window);_245=dijit.range.getNode(mark.startContainer,this.editNode);_246=dijit.range.getNode(mark.endContainer,this.editNode);if(_245&&_246){r.setStart(_245,mark.startOffset);r.setEnd(_246,mark.endOffset);sel.addRange(r);}}}}},_changeToStep:function(from,to){this.setValue(to.text);var b=to.bookmark;if(!b){return;}this._moveToBookmark(b);},undo:function(){var ret=false;if(!this._undoRedoActive){this._undoRedoActive=true;this.endEditing(true);var s=this._steps.pop();if(s&&this._steps.length>0){this.focus();this._changeToStep(s,this._steps[this._steps.length-1]);this._undoedSteps.push(s);this.onDisplayChanged();delete this._undoRedoActive;ret=true;}delete this._undoRedoActive;}return ret;},redo:function(){var ret=false;if(!this._undoRedoActive){this._undoRedoActive=true;this.endEditing(true);var s=this._undoedSteps.pop();if(s&&this._steps.length>0){this.focus();this._changeToStep(this._steps[this._steps.length-1],s);this._steps.push(s);this.onDisplayChanged();ret=true;}delete this._undoRedoActive;}return ret;},endEditing:function(_247){if(this._editTimer){clearTimeout(this._editTimer);}if(this._inEditing){this._endEditing(_247);this._inEditing=false;}},_getBookmark:function(){var b=dojo.withGlobal(this.window,dijit.getBookmark);var tmp=[];if(b&&b.mark){var mark=b.mark;if(dojo.isIE){var sel=dijit.range.getSelection(this.window);if(!dojo.isArray(mark)){if(sel){var _248;if(sel.rangeCount){_248=sel.getRangeAt(0);}if(_248){b.mark=_248.cloneRange();}else{b.mark=dojo.withGlobal(this.window,dijit.getBookmark);}}}else{dojo.forEach(b.mark,function(n){tmp.push(dijit.range.getIndex(n,this.editNode).o);},this);b.mark=tmp;}}try{if(b.mark&&b.mark.startContainer){tmp=dijit.range.getIndex(b.mark.startContainer,this.editNode).o;b.mark={startContainer:tmp,startOffset:b.mark.startOffset,endContainer:b.mark.endContainer===b.mark.startContainer?tmp:dijit.range.getIndex(b.mark.endContainer,this.editNode).o,endOffset:b.mark.endOffset};}}catch(e){b.mark=null;}}return b;},_beginEditing:function(cmd){if(this._steps.length===0){this._steps.push({"text":dijit._editor.getChildrenHtml(this.editNode),"bookmark":this._getBookmark()});}},_endEditing:function(_249){var v=dijit._editor.getChildrenHtml(this.editNode);this._undoedSteps=[];this._steps.push({text:v,bookmark:this._getBookmark()});},onKeyDown:function(e){if(!dojo.isIE&&!this.iframe&&e.keyCode==dojo.keys.TAB&&!this.tabIndent){this._saveSelection();}if(!this.customUndo){this.inherited(arguments);return;}var k=e.keyCode,ks=dojo.keys;if(e.ctrlKey&&!e.altKey){if(k==90||k==122){dojo.stopEvent(e);this.undo();return;}else{if(k==89||k==121){dojo.stopEvent(e);this.redo();return;}}}this.inherited(arguments);switch(k){case ks.ENTER:case ks.BACKSPACE:case ks.DELETE:this.beginEditing();break;case 88:case 86:if(e.ctrlKey&&!e.altKey&&!e.metaKey){this.endEditing();if(e.keyCode==88){this.beginEditing("cut");setTimeout(dojo.hitch(this,this.endEditing),1);}else{this.beginEditing("paste");setTimeout(dojo.hitch(this,this.endEditing),1);}break;}default:if(!e.ctrlKey&&!e.altKey&&!e.metaKey&&(e.keyCodedojo.keys.F15)){this.beginEditing();break;}case ks.ALT:this.endEditing();break;case ks.UP_ARROW:case ks.DOWN_ARROW:case ks.LEFT_ARROW:case ks.RIGHT_ARROW:case ks.HOME:case ks.END:case ks.PAGE_UP:case ks.PAGE_DOWN:this.endEditing(true);break;case ks.CTRL:case ks.SHIFT:case ks.TAB:break;}},_onBlur:function(){this.inherited(arguments);this.endEditing(true);},_saveSelection:function(){try{this._savedSelection=this._getBookmark();}catch(e){}},_restoreSelection:function(){if(this._savedSelection){delete this._cursorToStart;if(dojo.withGlobal(this.window,"isCollapsed",dijit)){this._moveToBookmark(this._savedSelection);}delete this._savedSelection;}},onClick:function(){this.endEditing(true);this.inherited(arguments);},replaceValue:function(html){if(!this.customUndo){this.inherited(arguments);}else{if(this.isClosed){this.setValue(html);}else{this.beginEditing();if(!html){html=" ";}this.setValue(html);this.endEditing();}}},_setDisabledAttr:function(_24a){var _24b=dojo.hitch(this,function(){if((!this.disabled&&_24a)||(!this._buttonEnabledPlugins&&_24a)){dojo.forEach(this._plugins,function(p){p.set("disabled",true);});}else{if(this.disabled&&!_24a){dojo.forEach(this._plugins,function(p){p.set("disabled",false);});}}});this.setValueDeferred.addCallback(_24b);this.inherited(arguments);},_setStateClass:function(){try{this.inherited(arguments);if(this.document&&this.document.body){dojo.style(this.document.body,"color",dojo.style(this.iframe,"color"));}}catch(e){}}});dojo.subscribe(dijit._scopeName+".Editor.getPlugin",null,function(o){if(o.plugin){return;}var args=o.args,p;var _24c=dijit._editor._Plugin;var name=args.name;switch(name){case "undo":case "redo":case "cut":case "copy":case "paste":case "insertOrderedList":case "insertUnorderedList":case "indent":case "outdent":case "justifyCenter":case "justifyFull":case "justifyLeft":case "justifyRight":case "delete":case "selectAll":case "removeFormat":case "unlink":case "insertHorizontalRule":p=new _24c({command:name});break;case "bold":case "italic":case "underline":case "strikethrough":case "subscript":case "superscript":p=new _24c({buttonClass:dijit.form.ToggleButton,command:name});break;case "|":p=new _24c({button:new dijit.ToolbarSeparator(),setEditor:function(_24d){this.editor=_24d;}});}o.plugin=p;});}if(!dojo._hasResource["dojo.regexp"]){dojo._hasResource["dojo.regexp"]=true;dojo.provide("dojo.regexp");dojo.getObject("regexp",true,dojo);dojo.regexp.escapeString=function(str,_24e){return str.replace(/([\.$?*|{}\(\)\[\]\\\/\+^])/g,function(ch){if(_24e&&_24e.indexOf(ch)!=-1){return ch;}return "\\"+ch;});};dojo.regexp.buildGroupRE=function(arr,re,_24f){if(!(arr instanceof Array)){return re(arr);}var b=[];for(var i=0;ib||a==null){r=1;}}return r;};dojo.data.util.sorter.createSortFunction=function(_252,_253){var _254=[];function _255(attr,dir,comp,s){return function(_256,_257){var a=s.getValue(_256,attr);var b=s.getValue(_257,attr);return dir*comp(a,b);};};var _258;var map=_253.comparatorMap;var bc=dojo.data.util.sorter.basicComparator;for(var i=0;i<_252.length;i++){_258=_252[i];var attr=_258.attribute;if(attr){var dir=(_258.descending)?-1:1;var comp=bc;if(map){if(typeof attr!=="string"&&("toString" in attr)){attr=attr.toString();}comp=map[attr]||bc;}_254.push(_255(attr,dir,comp,_253));}}return function(rowA,rowB){var i=0;while(i<_254.length){var ret=_254[i++](rowA,rowB);if(ret!==0){return ret;}}return 0;};};}if(!dojo._hasResource["dojo.data.util.simpleFetch"]){dojo._hasResource["dojo.data.util.simpleFetch"]=true;dojo.provide("dojo.data.util.simpleFetch");dojo.getObject("data.util.simpleFetch",true,dojo);dojo.data.util.simpleFetch.fetch=function(_259){_259=_259||{};if(!_259.store){_259.store=this;}var self=this;var _25a=function(_25b,_25c){if(_25c.onError){var _25d=_25c.scope||dojo.global;_25c.onError.call(_25d,_25b,_25c);}};var _25e=function(_25f,_260){var _261=_260.abort||null;var _262=false;var _263=_260.start?_260.start:0;var _264=(_260.count&&(_260.count!==Infinity))?(_263+_260.count):_25f.length;_260.abort=function(){_262=true;if(_261){_261.call(_260);}};var _265=_260.scope||dojo.global;if(!_260.store){_260.store=self;}if(_260.onBegin){_260.onBegin.call(_265,_25f.length,_260);}if(_260.sort){_25f.sort(dojo.data.util.sorter.createSortFunction(_260.sort,self));}if(_260.onItem){for(var i=_263;(i<_25f.length)&&(i<_264);++i){var item=_25f[i];if(!_262){_260.onItem.call(_265,item,_260);}}}if(_260.onComplete&&!_262){var _266=null;if(!_260.onItem){_266=_25f.slice(_263,_264);}_260.onComplete.call(_265,_266,_260);}};this._fetchItems(_259,_25e,_25a);return _259;};}if(!dojo._hasResource["dojo.data.util.filter"]){dojo._hasResource["dojo.data.util.filter"]=true;dojo.provide("dojo.data.util.filter");dojo.getObject("data.util.filter",true,dojo);dojo.data.util.filter.patternToRegExp=function(_267,_268){var rxp="^";var c=null;for(var i=0;i<_267.length;i++){c=_267.charAt(i);switch(c){case "\\":rxp+=c;i++;rxp+=_267.charAt(i);break;case "*":rxp+=".*";break;case "?":rxp+=".";break;case "$":case "^":case "/":case "+":case ".":case "|":case "(":case ")":case "{":case "}":case "[":case "]":rxp+="\\";default:rxp+=c;}}rxp+="$";if(_268){return new RegExp(rxp,"mi");}else{return new RegExp(rxp,"m");}};}if(!dojo._hasResource["dijit.form.TextBox"]){dojo._hasResource["dijit.form.TextBox"]=true;dojo.provide("dijit.form.TextBox");dojo.declare("dijit.form.TextBox",dijit.form._FormValueWidget,{trim:false,uppercase:false,lowercase:false,propercase:false,maxLength:"",selectOnClick:false,placeHolder:"",templateString:dojo.cache("dijit.form","templates/TextBox.html","
    \r\n"),_singleNodeTemplate:"",_buttonInputDisabled:dojo.isIE?"disabled":"",baseClass:"dijitTextBox",attributeMap:dojo.delegate(dijit.form._FormValueWidget.prototype.attributeMap,{maxLength:"focusNode"}),postMixInProperties:function(){var type=this.type.toLowerCase();if(this.templateString&&this.templateString.toLowerCase()=="input"||((type=="hidden"||type=="file")&&this.templateString==dijit.form.TextBox.prototype.templateString)){this.templateString=this._singleNodeTemplate;}this.inherited(arguments);},_setPlaceHolderAttr:function(v){this._set("placeHolder",v);if(!this._phspan){this._attachPoints.push("_phspan");this._phspan=dojo.create("span",{className:"dijitPlaceHolder dijitInputField"},this.textbox,"after");}this._phspan.innerHTML="";this._phspan.appendChild(document.createTextNode(v));this._updatePlaceHolder();},_updatePlaceHolder:function(){if(this._phspan){this._phspan.style.display=(this.placeHolder&&!this._focused&&!this.textbox.value)?"":"none";}},_getValueAttr:function(){return this.parse(this.get("displayedValue"),this.constraints);},_setValueAttr:function(_269,_26a,_26b){var _26c;if(_269!==undefined){_26c=this.filter(_269);if(typeof _26b!="string"){if(_26c!==null&&((typeof _26c!="number")||!isNaN(_26c))){_26b=this.filter(this.format(_26c,this.constraints));}else{_26b="";}}}if(_26b!=null&&_26b!=undefined&&((typeof _26b)!="number"||!isNaN(_26b))&&this.textbox.value!=_26b){this.textbox.value=_26b;this._set("displayedValue",this.get("displayedValue"));}this._updatePlaceHolder();this.inherited(arguments,[_26c,_26a]);},displayedValue:"",getDisplayedValue:function(){dojo.deprecated(this.declaredClass+"::getDisplayedValue() is deprecated. Use set('displayedValue') instead.","","2.0");return this.get("displayedValue");},_getDisplayedValueAttr:function(){return this.filter(this.textbox.value);},setDisplayedValue:function(_26d){dojo.deprecated(this.declaredClass+"::setDisplayedValue() is deprecated. Use set('displayedValue', ...) instead.","","2.0");this.set("displayedValue",_26d);},_setDisplayedValueAttr:function(_26e){if(_26e===null||_26e===undefined){_26e="";}else{if(typeof _26e!="string"){_26e=String(_26e);}}this.textbox.value=_26e;this._setValueAttr(this.get("value"),undefined);this._set("displayedValue",this.get("displayedValue"));},format:function(_26f,_270){return ((_26f==null||_26f==undefined)?"":(_26f.toString?_26f.toString():_26f));},parse:function(_271,_272){return _271;},_refreshState:function(){},_onInput:function(e){if(e&&e.type&&/key/i.test(e.type)&&e.keyCode){switch(e.keyCode){case dojo.keys.SHIFT:case dojo.keys.ALT:case dojo.keys.CTRL:case dojo.keys.TAB:return;}}if(this.intermediateChanges){var _273=this;setTimeout(function(){_273._handleOnChange(_273.get("value"),false);},0);}this._refreshState();this._set("displayedValue",this.get("displayedValue"));},postCreate:function(){if(dojo.isIE){setTimeout(dojo.hitch(this,function(){var s=dojo.getComputedStyle(this.domNode);if(s){var ff=s.fontFamily;if(ff){var _274=this.domNode.getElementsByTagName("INPUT");if(_274){for(var i=0;i<_274.length;i++){_274[i].style.fontFamily=ff;}}}}}),0);}this.textbox.setAttribute("value",this.textbox.value);this.inherited(arguments);if(dojo.isMoz||dojo.isOpera){this.connect(this.textbox,"oninput","_onInput");}else{this.connect(this.textbox,"onkeydown","_onInput");this.connect(this.textbox,"onkeyup","_onInput");this.connect(this.textbox,"onpaste","_onInput");this.connect(this.textbox,"oncut","_onInput");}},_blankValue:"",filter:function(val){if(val===null){return this._blankValue;}if(typeof val!="string"){return val;}if(this.trim){val=dojo.trim(val);}if(this.uppercase){val=val.toUpperCase();}if(this.lowercase){val=val.toLowerCase();}if(this.propercase){val=val.replace(/[^\s]+/g,function(word){return word.substring(0,1).toUpperCase()+word.substring(1);});}return val;},_setBlurValue:function(){this._setValueAttr(this.get("value"),true);},_onBlur:function(e){if(this.disabled){return;}this._setBlurValue();this.inherited(arguments);if(this._selectOnClickHandle){this.disconnect(this._selectOnClickHandle);}if(this.selectOnClick&&dojo.isMoz){this.textbox.selectionStart=this.textbox.selectionEnd=undefined;}this._updatePlaceHolder();},_onFocus:function(by){if(this.disabled||this.readOnly){return;}if(this.selectOnClick&&by=="mouse"){this._selectOnClickHandle=this.connect(this.domNode,"onmouseup",function(){this.disconnect(this._selectOnClickHandle);var _275;if(dojo.isIE){var _276=dojo.doc.selection.createRange();var _277=_276.parentElement();_275=_277==this.textbox&&_276.text.length==0;}else{_275=this.textbox.selectionStart==this.textbox.selectionEnd;}if(_275){dijit.selectInputText(this.textbox);}});}this._updatePlaceHolder();this.inherited(arguments);this._refreshState();},reset:function(){this.textbox.value="";this.inherited(arguments);}});dijit.selectInputText=function(_278,_279,stop){var _27a=dojo.global;var _27b=dojo.doc;_278=dojo.byId(_278);if(isNaN(_279)){_279=0;}if(isNaN(stop)){stop=_278.value?_278.value.length:0;}dijit.focus(_278);if(_27b["selection"]&&dojo.body()["createTextRange"]){if(_278.createTextRange){var r=_278.createTextRange();r.collapse(true);r.moveStart("character",-99999);r.moveStart("character",_279);r.moveEnd("character",stop-_279);r.select();}}else{if(_27a["getSelection"]){if(_278.setSelectionRange){_278.setSelectionRange(_279,stop);}}}};}if(!dojo._hasResource["dijit.Tooltip"]){dojo._hasResource["dijit.Tooltip"]=true;dojo.provide("dijit.Tooltip");dojo.declare("dijit._MasterTooltip",[dijit._Widget,dijit._Templated],{duration:dijit.defaultDuration,templateString:dojo.cache("dijit","templates/Tooltip.html","