//>>built require({cache:{"url:dojox/editor/plugins/resources/insertTable.html":'\x3cdiv class\x3d"dijitDialog" tabindex\x3d"-1" role\x3d"dialog" aria-labelledby\x3d"${id}_title"\x3e\r\n\t\x3cdiv dojoAttachPoint\x3d"titleBar" class\x3d"dijitDialogTitleBar"\x3e\r\n\t\x3cspan dojoAttachPoint\x3d"titleNode" class\x3d"dijitDialogTitle" id\x3d"${id}_title"\x3e${insertTableTitle}\x3c/span\x3e\r\n\t\x3cspan dojoAttachPoint\x3d"closeButtonNode" class\x3d"dijitDialogCloseIcon" dojoAttachEvent\x3d"onclick: onCancel" title\x3d"${buttonCancel}"\x3e\r\n\t\t\x3cspan dojoAttachPoint\x3d"closeText" class\x3d"closeText" title\x3d"${buttonCancel}"\x3ex\x3c/span\x3e\r\n\t\x3c/span\x3e\r\n\t\x3c/div\x3e\r\n \x3cdiv dojoAttachPoint\x3d"containerNode" class\x3d"dijitDialogPaneContent"\x3e\r\n \x3ctable class\x3d"etdTable"\x3e\x3ctr\x3e\r\n \x3ctd\x3e\r\n \x3clabel\x3e${rows}\x3c/label\x3e\r\n\t\t\t\x3c/td\x3e\x3ctd\x3e\r\n \x3cspan dojoAttachPoint\x3d"selectRow" dojoType\x3d"dijit.form.TextBox" value\x3d"2"\x3e\x3c/span\x3e\r\n \x3c/td\x3e\x3ctd\x3e\x3ctable\x3e\x3ctr\x3e\x3ctd class\x3d"inner"\x3e\r\n \x3clabel\x3e${columns}\x3c/label\x3e\r\n\t\t\t\x3c/td\x3e\x3ctd class\x3d"inner"\x3e\r\n \x3cspan dojoAttachPoint\x3d"selectCol" dojoType\x3d"dijit.form.TextBox" value\x3d"2"\x3e\x3c/span\x3e\r\n \x3c/td\x3e\x3c/tr\x3e\x3c/table\x3e\x3c/td\x3e\x3c/tr\x3e\t\t\r\n\t\t\t\x3ctr\x3e\x3ctd\x3e\r\n \x3clabel\x3e${tableWidth}\x3c/label\x3e\r\n \x3c/td\x3e\x3ctd\x3e\r\n \x3cspan dojoAttachPoint\x3d"selectWidth" dojoType\x3d"dijit.form.TextBox" value\x3d"100"\x3e\x3c/span\x3e\r\n\t\t\t\x3c/td\x3e\x3ctd\x3e\r\n \x3cselect dojoAttachPoint\x3d"selectWidthType" hasDownArrow\x3d"true" dojoType\x3d"dijit.form.FilteringSelect"\x3e\r\n \x3coption value\x3d"percent"\x3e${percent}\x3c/option\x3e\r\n \x3coption value\x3d"pixels"\x3e${pixels}\x3c/option\x3e\r\n \x3c/select\x3e\x3c/td\x3e\x3c/tr\x3e\t\r\n \x3ctr\x3e\x3ctd\x3e\r\n \x3clabel\x3e${borderThickness}\x3c/label\x3e\r\n \x3c/td\x3e\x3ctd\x3e\r\n \x3cspan dojoAttachPoint\x3d"selectBorder" dojoType\x3d"dijit.form.TextBox" value\x3d"1"\x3e\x3c/span\x3e\r\n \x3c/td\x3e\x3ctd\x3e\r\n ${pixels}\r\n \x3c/td\x3e\x3c/tr\x3e\x3ctr\x3e\x3ctd\x3e\r\n \x3clabel\x3e${cellPadding}\x3c/label\x3e\r\n \x3c/td\x3e\x3ctd\x3e\r\n \x3cspan dojoAttachPoint\x3d"selectPad" dojoType\x3d"dijit.form.TextBox" value\x3d"0"\x3e\x3c/span\x3e\r\n \x3c/td\x3e\x3ctd class\x3d"cellpad"\x3e\x3c/td\x3e\x3c/tr\x3e\x3ctr\x3e\x3ctd\x3e\r\n \x3clabel\x3e${cellSpacing}\x3c/label\x3e\r\n \x3c/td\x3e\x3ctd\x3e\r\n \x3cspan dojoAttachPoint\x3d"selectSpace" dojoType\x3d"dijit.form.TextBox" value\x3d"0"\x3e\x3c/span\x3e\r\n \x3c/td\x3e\x3ctd class\x3d"cellspace"\x3e\x3c/td\x3e\x3c/tr\x3e\x3c/table\x3e\r\n \x3cdiv class\x3d"dialogButtonContainer"\x3e\r\n \x3cdiv dojoType\x3d"dijit.form.Button" dojoAttachEvent\x3d"onClick: onInsert"\x3e${buttonInsert}\x3c/div\x3e\r\n \x3cdiv dojoType\x3d"dijit.form.Button" dojoAttachEvent\x3d"onClick: onCancel"\x3e${buttonCancel}\x3c/div\x3e\r\n \x3c/div\x3e\r\n\t\x3c/div\x3e\r\n\x3c/div\x3e\r\n', "url:dojox/editor/plugins/resources/modifyTable.html":'\x3cdiv class\x3d"dijitDialog" tabindex\x3d"-1" role\x3d"dialog" aria-labelledby\x3d"${id}_title"\x3e\r\n\t\x3cdiv dojoAttachPoint\x3d"titleBar" class\x3d"dijitDialogTitleBar"\x3e\r\n\t\x3cspan dojoAttachPoint\x3d"titleNode" class\x3d"dijitDialogTitle" id\x3d"${id}_title"\x3e${modifyTableTitle}\x3c/span\x3e\r\n\t\x3cspan dojoAttachPoint\x3d"closeButtonNode" class\x3d"dijitDialogCloseIcon" dojoAttachEvent\x3d"onclick: onCancel" title\x3d"${buttonCancel}"\x3e\r\n\t\t\x3cspan dojoAttachPoint\x3d"closeText" class\x3d"closeText" title\x3d"${buttonCancel}"\x3ex\x3c/span\x3e\r\n\t\x3c/span\x3e\r\n\t\x3c/div\x3e\r\n \x3cdiv dojoAttachPoint\x3d"containerNode" class\x3d"dijitDialogPaneContent"\x3e\r\n \x3ctable class\x3d"etdTable"\x3e\r\n \x3ctr\x3e\x3ctd\x3e\r\n \x3clabel\x3e${backgroundColor}\x3c/label\x3e\r\n \x3c/td\x3e\x3ctd colspan\x3d"2"\x3e\r\n \x3cspan class\x3d"colorSwatchBtn" dojoAttachPoint\x3d"backgroundCol"\x3e\x3c/span\x3e\r\n \x3c/td\x3e\x3c/tr\x3e\x3ctr\x3e\x3ctd\x3e\r\n \x3clabel\x3e${borderColor}\x3c/label\x3e\r\n \x3c/td\x3e\x3ctd colspan\x3d"2"\x3e\r\n \x3cspan class\x3d"colorSwatchBtn" dojoAttachPoint\x3d"borderCol"\x3e\x3c/span\x3e\r\n \x3c/td\x3e\x3c/tr\x3e\x3ctr\x3e\x3ctd\x3e\r\n \x3clabel\x3e${align}\x3c/label\x3e\r\n \x3c/td\x3e\x3ctd colspan\x3d"2"\x3e\t\r\n \x3cselect dojoAttachPoint\x3d"selectAlign" dojoType\x3d"dijit.form.FilteringSelect"\x3e\r\n \x3coption value\x3d"default"\x3e${default}\x3c/option\x3e\r\n \x3coption value\x3d"left"\x3e${left}\x3c/option\x3e\r\n \x3coption value\x3d"center"\x3e${center}\x3c/option\x3e\r\n \x3coption value\x3d"right"\x3e${right}\x3c/option\x3e\r\n \x3c/select\x3e\r\n \x3c/td\x3e\x3c/tr\x3e\r\n \x3ctr\x3e\x3ctd\x3e\r\n \x3clabel\x3e${tableWidth}\x3c/label\x3e\r\n \x3c/td\x3e\x3ctd\x3e\r\n \x3cspan dojoAttachPoint\x3d"selectWidth" dojoType\x3d"dijit.form.TextBox" value\x3d"100"\x3e\x3c/span\x3e\r\n \x3c/td\x3e\x3ctd\x3e\r\n \x3cselect dojoAttachPoint\x3d"selectWidthType" hasDownArrow\x3d"true" dojoType\x3d"dijit.form.FilteringSelect"\x3e\r\n \x3coption value\x3d"percent"\x3e${percent}\x3c/option\x3e\r\n \x3coption value\x3d"pixels"\x3e${pixels}\x3c/option\x3e\r\n \x3c/select\x3e\x3c/td\x3e\x3c/tr\x3e\t\r\n \x3ctr\x3e\x3ctd\x3e\r\n \x3clabel\x3e${borderThickness}\x3c/label\x3e\r\n \x3c/td\x3e\x3ctd\x3e\r\n \x3cspan dojoAttachPoint\x3d"selectBorder" dojoType\x3d"dijit.form.TextBox" value\x3d"1"\x3e\x3c/span\x3e\r\n \x3c/td\x3e\x3ctd\x3e\r\n ${pixels}\r\n \x3c/td\x3e\x3c/tr\x3e\x3ctr\x3e\x3ctd\x3e\r\n \x3clabel\x3e${cellPadding}\x3c/label\x3e\r\n \x3c/td\x3e\x3ctd\x3e\r\n \x3cspan dojoAttachPoint\x3d"selectPad" dojoType\x3d"dijit.form.TextBox" value\x3d"0"\x3e\x3c/span\x3e\r\n \x3c/td\x3e\x3ctd class\x3d"cellpad"\x3e\x3c/td\x3e\x3c/tr\x3e\x3ctr\x3e\x3ctd\x3e\r\n \x3clabel\x3e${cellSpacing}\x3c/label\x3e\r\n \x3c/td\x3e\x3ctd\x3e\r\n \x3cspan dojoAttachPoint\x3d"selectSpace" dojoType\x3d"dijit.form.TextBox" value\x3d"0"\x3e\x3c/span\x3e\r\n \x3c/td\x3e\x3ctd class\x3d"cellspace"\x3e\x3c/td\x3e\x3c/tr\x3e\r\n \x3c/table\x3e\r\n \x3cdiv class\x3d"dialogButtonContainer"\x3e\r\n \x3cdiv dojoType\x3d"dijit.form.Button" dojoAttachEvent\x3d"onClick: onSet"\x3e${buttonSet}\x3c/div\x3e\r\n \x3cdiv dojoType\x3d"dijit.form.Button" dojoAttachEvent\x3d"onClick: onCancel"\x3e${buttonCancel}\x3c/div\x3e\r\n \x3c/div\x3e\r\n\t\x3c/div\x3e\r\n\x3c/div\x3e\r\n'}}); define("dojo/_base/declare dojo/_base/array dojo/_base/Color dojo/aspect dojo/dom-attr dojo/dom-style dijit/_editor/_Plugin dijit/_WidgetBase dijit/_TemplatedMixin dijit/_WidgetsInTemplateMixin dijit/Dialog dijit/Menu dijit/MenuItem dijit/MenuSeparator dijit/ColorPalette dojox/widget/ColorPicker dojo/text!./resources/insertTable.html dojo/text!./resources/modifyTable.html dojo/i18n!./nls/TableDialog dijit/_base/popup dijit/popup dojo/_base/connect dijit/TooltipDialog dijit/form/Button dijit/form/DropDownButton dijit/form/TextBox dijit/form/FilteringSelect".split(" "), function(k,w,x,y,g,l,f,z,q,r,t,A,m,u,B,v,C,D,h){function n(a){return new p(a)}dojo.experimental("dojox.editor.plugins.TablePlugins");var E=k(f,{tablesConnected:!1,currentlyAvailable:!1,alwaysAvailable:!1,availableCurrentlySet:!1,initialized:!1,tableData:null,shiftKeyDown:!1,editorDomNode:null,undoEnabled:!0,refCount:0,doMixins:function(){dojo.mixin(this.editor,{getAncestorElement:function(a){return this._sCall("getAncestorElement",[a])},hasAncestorElement:function(a){return this._sCall("hasAncestorElement", [a])},selectElement:function(a){this._sCall("selectElement",[a])},byId:function(a){return dojo.byId(a,this.document)},query:function(a,b,c){a=dojo.query(a,b||this.document);return c?a[0]:a}})},initialize:function(a){this.refCount++;a.customUndo=!0;this.initialized||(this.initialized=!0,this.editor=a,this.editor._tablePluginHandler=this,a.onLoadDeferred.addCallback(dojo.hitch(this,function(){this.editorDomNode=this.editor.editNode||this.editor.iframe.document.body.firstChild;this._myListeners=[dojo.connect(this.editorDomNode, "mouseup",this.editor,"onClick"),dojo.connect(this.editor,"onDisplayChanged",this,"checkAvailable"),dojo.connect(this.editor,"onBlur",this,"checkAvailable"),dojo.connect(this.editor,"_saveSelection",this,function(){this._savedTableInfo=this.getTableInfo()}),dojo.connect(this.editor,"_restoreSelection",this,function(){delete this._savedTableInfo})];this.doMixins();this.connectDraggable()})))},getTableInfo:function(a){if(this._savedTableInfo)return this._savedTableInfo;a&&this._tempStoreTableData(!1); if(this.tableData)return this.tableData;var b,c,e,d,f,g,h;if(c=this.editor.getAncestorElement("td"))b=c.parentNode;(d=this.editor.getAncestorElement("table"))?(e=dojo.query("td",d),e.forEach(function(a,b){c==a&&(g=b)}),a=dojo.query("tr",d),a.forEach(function(a,c){b==a&&(h=c)}),f=e.length/a.length,a={tbl:d,td:c,tr:b,trs:a,tds:e,rows:a.length,cols:f,tdIndex:g,trIndex:h,colIndex:g%f}):a={};this.tableData=a;this._tempStoreTableData(500);return this.tableData},connectDraggable:function(){dojo.isIE&&(this.editorDomNode.ondragstart= dojo.hitch(this,"onDragStart"),this.editorDomNode.ondragend=dojo.hitch(this,"onDragEnd"))},onDragStart:function(){var a=window.event;a.srcElement.id||(a.srcElement.id="tbl_"+(new Date).getTime())},onDragEnd:function(){var a=window.event.srcElement,b=a.id,c=this.editor.document;"table"==a.tagName.toLowerCase()&&setTimeout(function(){var a=dojo.byId(b,c);dojo.removeAttr(a,"align")},100)},checkAvailable:function(){if(this.availableCurrentlySet)return this.currentlyAvailable;if(!this.editor)return!1; if(this.alwaysAvailable)return!0;(this.currentlyAvailable=this.editor.focused&&(this._savedTableInfo?this._savedTableInfo.tbl:this.editor.hasAncestorElement("table")))?this.connectTableKeys():this.disconnectTableKeys();this._tempAvailability(500);dojo.publish(this.editor.id+"_tablePlugins",[this.currentlyAvailable]);return this.currentlyAvailable},_prepareTable:function(a){var b=this.editor.query("td",a);console.log("prep:",b,a);b[0].id||b.forEach(function(a,b){a.id||(a.id="tdid"+b+this.getTimeStamp())}, this);return b},getTimeStamp:function(){return(new Date).getTime()},_tempStoreTableData:function(a){!0!==a&&(!1===a?this.tableData=null:void 0===a?console.warn("_tempStoreTableData must be passed an argument"):setTimeout(dojo.hitch(this,function(){this.tableData=null}),a))},_tempAvailability:function(a){!0===a?this.availableCurrentlySet=!0:!1===a?this.availableCurrentlySet=!1:void 0===a?console.warn("_tempAvailability must be passed an argument"):(this.availableCurrentlySet=!0,setTimeout(dojo.hitch(this, function(){this.availableCurrentlySet=!1}),a))},connectTableKeys:function(){if(!this.tablesConnected){this.tablesConnected=!0;var a=this.editor.iframe?this.editor.document:this.editor.editNode;this.cnKeyDn=dojo.connect(a,"onkeydown",this,"onKeyDown");this.cnKeyUp=dojo.connect(a,"onkeyup",this,"onKeyUp");this._myListeners.push(dojo.connect(a,"onkeypress",this,"onKeyUp"))}},disconnectTableKeys:function(){dojo.disconnect(this.cnKeyDn);dojo.disconnect(this.cnKeyUp);this.tablesConnected=!1},onKeyDown:function(a){var b= a.keyCode;16==b&&(this.shiftKeyDown=!0);9==b&&(b=this.getTableInfo(),b.tdIndex=this.shiftKeyDown?b.tdIndex-1:tabTo=b.tdIndex+1,0<=b.tdIndex&&b.tdIndex