// All material copyright ESRI, All Rights Reserved, unless otherwise specified.
// See http://js.arcgis.com/3.23/esri/copyright.txt for details.
//>>built
require({cache:{"url:esri/dijit/metadata/editor/templates/Editor.html":'\x3cdiv class\x3d"gxeEditor" data-dojo-attach-point\x3d"containerNode"\x3e\r\n  \x3cdiv data-dojo-type\x3d"esri/dijit/metadata/editor/PrimaryToolbar" data-dojo-attach-point\x3d"primaryToolbar"\x3e\x3c/div\x3e\r\n  \x3cdiv class\x3d"gxeCanvas" data-dojo-attach-point\x3d"canvasNode"\x3e\r\n    \x3cdiv data-dojo-type\x3d"esri/dijit/metadata/editor/ValidationPane" data-dojo-attach-point\x3d"validationPane" style\x3d"display:none;"\x3e\x3c/div\x3e\r\n    \x3cdiv data-dojo-type\x3d"esri/dijit/metadata/editor/ViewDocumentPane" data-dojo-attach-point\x3d"viewDocumentPane" style\x3d"display:none;"\x3e\x3c/div\x3e\r\n    \x3cdiv data-dojo-type\x3d"esri/dijit/metadata/editor/XmlPane" data-dojo-attach-point\x3d"xmlPane" style\x3d"display:none;"\x3e\x3c/div\x3e\r\n    \x3cdiv data-dojo-type\x3d"esri/dijit/metadata/editor/EditDocumentPane" data-dojo-attach-point\x3d"editDocumentPane" style\x3d"display:none;"\x3e\x3c/div\x3e\r\n  \x3c/div\x3e\r\n\x3c/div\x3e'}});
define("esri/dijit/metadata/editor/Editor","dojo/_base/declare dojo/_base/lang dojo/Deferred dojo/on dojo/keys dojo/_base/event dojo/dom-class dojo/dom-construct dojo/dom-style dojo/has dijit/Viewport ../context/GxeAdaptor ../context/GxeContext ../base/etc/viewOnlyUtil ../base/XDocument ../base/xml/XmlImporter ../types/arcgis/base/arcgisStyles ./EditorResizeMixin ../base/Templated dojo/text!./templates/Editor.html ../../../kernel ./PrimaryToolbar ./ValidationPane ./EditDocumentPane ./ViewDocumentPane ./XmlPane ../../../dijit/Geocoder ../form/Attribute ../form/Element ../form/ElementChoice ../form/HiddenAttribute ../form/HiddenElement ../form/OpenElement ../form/InputDate ../form/InputDelimitedTextArea ../form/InputNumber ../form/InputSelectMany ../form/InputSelectOne ../form/InputText ../form/InputTextArea ../form/IsoTopicCategoryOptions ../form/Option ../form/Options ../form/Section ../form/Tabs ../form/tools/ClickableTool ../form/tools/ClickableValueTool ../types/arcgis/form/InputCheckBox ../types/arcgis/form/InputDate ../types/arcgis/form/InputHtmlArea ../types/arcgis/form/InputSelectBoolean ../types/arcgis/form/InputSelectCode ../types/arcgis/form/InputSysTime".split(" "),
function(b,d,q,r,t,u,v,w,f,x,y,z,A,B,C,D,E,F,G,H,I){b=b([G,F],{dialogBroker:null,gxeAdaptor:null,gxeContext:null,templateString:H,postCreate:function(){this.inherited(arguments);this.gxeAdaptor||(this.gxeAdaptor=new z);this.gxeContext||(this.gxeContext=new A);this.primaryToolbar.editor=this;this.primaryToolbar.lastSavedXml=this.gxeAdaptor.getOriginalXml();this.validationPane.editor=this;this.xmlPane.setXml(this.gxeAdaptor.getOriginalXml(),"metadata");this.primaryToolbar.initialize();this.dialogBroker||
this.own(y.on("resize",d.hitch(this,"resize")));this.isLeftToRight()||v.add(this.domNode,"gxeRtl");this.own(r(document,"keydown, keypress",d.hitch(this,function(a){a.keyCode===t.BACKSPACE&&void 0===a.target.size&&void 0===a.target.rows&&u.stop(a)})))},destroy:function(){try{this.viewDocumentPane.gxeDocument&&this.viewDocumentPane.gxeDocument.rootDescriptor&&this.viewDocumentPane.gxeDocument.rootDescriptor.destroyRecursive(!1)}catch(a){console.error(a)}try{this.editDocumentPane.gxeDocument&&this.editDocumentPane.gxeDocument.rootDescriptor&&
this.editDocumentPane.gxeDocument.rootDescriptor.destroyRecursive(!1)}catch(a){console.error(a)}this.inherited(arguments)},getEditDocument:function(){return this.editDocumentPane.gxeDocument},getViewDocument:function(){return this.viewDocumentPane.gxeDocument},initializeView:function(){this.primaryToolbar.initializeView()},_loadDocumentPane:function(a,J,e,b,d){var c=null,g=!1,m=!1,l=new q;a===this.editDocumentPane?this.validationPane.clearMessages():g=!0;try{var n,h=a.gxeDocument,p=w.create("div",
{},a.rootContainer),c=new C({gxeContext:this.gxeContext,isViewOnly:g,_editor:this});c.initialize(J,p,e);e&&(n=new D,n.importDocument(c,e,b));h&&(f.set(h.rootDescriptor.domNode,"display","none"),h.rootDescriptor&&h.rootDescriptor.destroyRecursive(!1));m=!0;a.gxeDocument=c;f.set(p,"display","");f.set(a.domNode,"display","");g&&B.applyViewOnly(c);try{g?this.gxeAdaptor.afterViewDocumentLoad(c,d):this.gxeAdaptor.afterEditDocumentLoad(c,e,b,d)}catch(k){console.error(k)}l.resolve(c);this.primaryToolbar.updateUI()}catch(k){try{c&&
c.rootDescriptor&&!m&&(f.set(c.rootDescriptor.domNode,"display","none"),c.rootDescriptor.destroyRecursive(!1))}catch(K){}console.error("Error constructing document");console.error(k);l.reject(k)}return l},loadEditor:function(a,b,e,d){this.editDocumentPane.hideMessage();a&&b&&"arcgis"===a.key&&E.preLoad(this.gxeContext,b);return this._loadDocumentPane(this.editDocumentPane,a,b,e,d)},loadView:function(a,b,d){return this._loadDocumentPane(this.viewDocumentPane,a,b,!1,d)}});x("extend-esri")&&d.setObject("dijit.metadata.editor.Editor",
b,I);return b});