!function(){function e(e){for(var n=(e=e.getElementsByTag("*")).count(),o=0;o<n;o++)(function(e){for(var n=0;n<t.length;n++)!function(t){var n=e.getAttribute("on"+t);e.hasAttribute("on"+t)&&(e.removeAttribute("on"+t),e.on(t,(function(t){var o=(a=/(return\s*)?NEW_CKEDITOR\.tools\.callFunction\(([^)]+)\)/.exec(n))&&a[1],i=a&&a[2].split(","),a=/return false;/.test(n);if(i){for(var r,l=i.length,s=0;s<l;s++){i[s]=r=NEW_CKEDITOR.tools.trim(i[s]);var u=r.match(/^(["'])([^"']*?)\1$/);if(u)i[s]=u[2];else if(r.match(/\d+/))i[s]=parseInt(r,10);else switch(r){case"this":i[s]=e.$;break;case"event":i[s]=t.data.$;break;case"null":i[s]=null}}i=NEW_CKEDITOR.tools.callFunction.apply(window,i),o&&!1===i&&(a=1)}a&&t.data.preventDefault()})))}(t[n])})(e.getItem(o))}var t="click keydown mousedown keypress mouseover mouseout".split(" ");NEW_CKEDITOR.plugins.add("adobeair",{onLoad:function(){NEW_CKEDITOR.env.air&&(NEW_CKEDITOR.dom.document.prototype.write=NEW_CKEDITOR.tools.override(NEW_CKEDITOR.dom.document.prototype.write,(function(e){function t(e,t,n,o){t=e.append(t),(n=NEW_CKEDITOR.htmlParser.fragment.fromHtml(n).children[0].attributes)&&t.setAttributes(n),o&&t.append(e.getDocument().createText(o))}return function(n){if(this.getBody()){var o=this,i=this.getHead();n=n.replace(/(<style[^>]*>)([\s\S]*?)<\/style>/gi,(function(e,n,o){return t(i,"style",n,o),""})),n=(n=n.replace(/<base\b[^>]*\/>/i,(function(e){return t(i,"base",e),""}))).replace(/<title>([\s\S]*)<\/title>/i,(function(e,t){return o.$.title=t,""})),n=n.replace(/<head>([\s\S]*)<\/head>/i,(function(e){var t=new NEW_CKEDITOR.dom.element("div",o);return t.setHtml(e),t.moveChildren(i),""})),n.replace(/(<body[^>]*>)([\s\S]*)(?=$|<\/body>)/i,(function(e,t,n){o.getBody().setHtml(n),(e=NEW_CKEDITOR.htmlParser.fragment.fromHtml(t).children[0].attributes)&&o.getBody().setAttributes(e)}))}else e.apply(this,arguments)}})),NEW_CKEDITOR.addCss("body.edi_editable { padding: 8px }"),NEW_CKEDITOR.ui.on("ready",(function(t){if((t=t.data)._.panel){var n=t._.panel._.panel;!function t(){n.isLoaded?e(n._.holder):setTimeout(t,30)}()}else t instanceof NEW_CKEDITOR.dialog&&e(t._.element)})))},init:function(t){NEW_CKEDITOR.env.air&&(t.on("uiReady",(function(){e(t.container),t.on("elementsPathUpdate",(function(t){e(t.data.space)}))})),t.on("contentDom",(function(){t.document.on("click",(function(e){e.data.preventDefault(!0)}))})))}})}();