!function(){function e(e,n,t){var c,d;(t="string"==typeof t?CKEDITOR.document.getById(t):new CKEDITOR.dom.element(t))&&(c=e.fire("uiSpace",{space:n,html:""}).html)&&(e.on("uiSpace",(function(e){e.data.space==n&&e.cancel()}),null,null,1),d=t.append(CKEDITOR.dom.element.createFromHtml(a.output({id:e.id,name:e.name,langDir:e.lang.dir,langCode:e.langCode,space:n,spaceId:e.ui.spaceId(n),content:c}))),t.getCustomData("cke_hasshared")?d.hide():t.setCustomData("cke_hasshared",1),d.unselectable(),d.on("mousedown",(function(e){(e=e.data).getTarget().hasAscendant("a",1)||e.preventDefault()})),e.focusManager.add(d,1),e.on("focus",(function(){for(var e,a=0,n=t.getChildren();e=n.getItem(a);a++)e.type==CKEDITOR.NODE_ELEMENT&&!e.equals(d)&&e.hasClass("cke_shared")&&e.hide();d.show()})),e.on("destroy",(function(){d.remove()})))}var a=CKEDITOR.addTemplate("sharedcontainer",'<div id="cke_{name}" class="cke {id} cke_reset_all cke_chrome cke_editor_{name} cke_shared cke_detached cke_{langDir} '+CKEDITOR.env.cssClass+'" dir="{langDir}" title="'+(CKEDITOR.env.gecko?" ":"")+'" lang="{langCode}" role="presentation"><div class="cke_inner"><div id="{spaceId}" class="cke_{space}" role="presentation">{content}</div></div></div>');CKEDITOR.plugins.add("sharedspace",{init:function(a){a.on("loaded",(function(){var n=a.config.sharedSpaces;if(n)for(var t in n)e(a,t,n[t])}),null,null,9)}})}();