]> git.donarmstrong.com Git - roundcube.git/blobdiff - program/js/tiny_mce/tiny_mce.js
Imported Debian patch 0.5.2+dfsg-1
[roundcube.git] / program / js / tiny_mce / tiny_mce.js
index 447ea07ed55065beed55b1ee3acc555baaa05177..8596abaa1bf81e7312925182b33fb89a6da8bef8 100644 (file)
@@ -1 +1,388 @@
-var tinymce={majorVersion:"3",minorVersion:"2.3",releaseDate:"2009-04-23",_init:function(){var o=this,k=document,l=window,j=navigator,b=j.userAgent,h,a,g,f,e,m;o.isOpera=l.opera&&opera.buildNumber;o.isWebKit=/WebKit/.test(b);o.isIE=!o.isWebKit&&!o.isOpera&&(/MSIE/gi).test(b)&&(/Explorer/gi).test(j.appName);o.isIE6=o.isIE&&/MSIE [56]/.test(b);o.isGecko=!o.isWebKit&&/Gecko/.test(b);o.isMac=b.indexOf("Mac")!=-1;o.isAir=/adobeair/i.test(b);if(l.tinyMCEPreInit){o.suffix=tinyMCEPreInit.suffix;o.baseURL=tinyMCEPreInit.base;o.query=tinyMCEPreInit.query;return}o.suffix="";a=k.getElementsByTagName("base");for(h=0;h<a.length;h++){if(m=a[h].href){if(/^https?:\/\/[^\/]+$/.test(m)){m+="/"}f=m?m.match(/.*\//)[0]:""}}function c(d){if(d.src&&/tiny_mce(|_dev|_src|_gzip|_jquery|_prototype).js/.test(d.src)){if(/_(src|dev)\.js/g.test(d.src)){o.suffix="_src"}if((e=d.src.indexOf("?"))!=-1){o.query=d.src.substring(e+1)}o.baseURL=d.src.substring(0,d.src.lastIndexOf("/"));if(f&&o.baseURL.indexOf("://")==-1){o.baseURL=f+o.baseURL}return o.baseURL}return null}a=k.getElementsByTagName("script");for(h=0;h<a.length;h++){if(c(a[h])){return}}g=k.getElementsByTagName("head")[0];if(g){a=g.getElementsByTagName("script");for(h=0;h<a.length;h++){if(c(a[h])){return}}}return},is:function(b,a){var c=typeof(b);if(!a){return c!="undefined"}if(a=="array"&&(b.hasOwnProperty&&b instanceof Array)){return true}return c==a},each:function(d,a,c){var e,b;if(!d){return 0}c=c||d;if(typeof(d.length)!="undefined"){for(e=0,b=d.length;e<b;e++){if(a.call(c,d[e],e,d)===false){return 0}}}else{for(e in d){if(d.hasOwnProperty(e)){if(a.call(c,d[e],e,d)===false){return 0}}}}return 1},map:function(b,c){var d=[];tinymce.each(b,function(a){d.push(c(a))});return d},grep:function(b,c){var d=[];tinymce.each(b,function(a){if(!c||c(a)){d.push(a)}});return d},inArray:function(c,d){var e,b;if(c){for(e=0,b=c.length;e<b;e++){if(c[e]===d){return e}}}return -1},extend:function(f,d){var c,b=arguments;for(c=1;c<b.length;c++){d=b[c];tinymce.each(d,function(a,e){if(typeof(a)!=="undefined"){f[e]=a}})}return f},trim:function(a){return(a?""+a:"").replace(/^\s*|\s*$/g,"")},create:function(j,a){var i=this,b,e,f,g,d,h=0;j=/^((static) )?([\w.]+)(:([\w.]+))?/.exec(j);f=j[3].match(/(^|\.)(\w+)$/i)[2];e=i.createNS(j[3].replace(/\.\w+$/,""));if(e[f]){return}if(j[2]=="static"){e[f]=a;if(this.onCreate){this.onCreate(j[2],j[3],e[f])}return}if(!a[f]){a[f]=function(){};h=1}e[f]=a[f];i.extend(e[f].prototype,a);if(j[5]){b=i.resolve(j[5]).prototype;g=j[5].match(/\.(\w+)$/i)[1];d=e[f];if(h){e[f]=function(){return b[g].apply(this,arguments)}}else{e[f]=function(){this.parent=b[g];return d.apply(this,arguments)}}e[f].prototype[f]=e[f];i.each(b,function(c,k){e[f].prototype[k]=b[k]});i.each(a,function(c,k){if(b[k]){e[f].prototype[k]=function(){this.parent=b[k];return c.apply(this,arguments)}}else{if(k!=f){e[f].prototype[k]=c}}})}i.each(a["static"],function(c,k){e[f][k]=c});if(this.onCreate){this.onCreate(j[2],j[3],e[f].prototype)}},walk:function(c,b,d,a){a=a||this;if(c){if(d){c=c[d]}tinymce.each(c,function(f,e){if(b.call(a,f,e,d)===false){return false}tinymce.walk(f,b,d,a)})}},createNS:function(d,c){var b,a;c=c||window;d=d.split(".");for(b=0;b<d.length;b++){a=d[b];if(!c[a]){c[a]={}}c=c[a]}return c},resolve:function(d,c){var b,a;c=c||window;d=d.split(".");for(b=0,a=d.length;b<a;b++){c=c[d[b]];if(!c){break}}return c},addUnload:function(e,d){var c=this,a=window;e={func:e,scope:d||this};if(!c.unloads){function b(){var f=c.unloads,h,i;if(f){for(i in f){h=f[i];if(h&&h.func){h.func.call(h.scope,1)}}if(a.detachEvent){a.detachEvent("onbeforeunload",g);a.detachEvent("onunload",b)}else{if(a.removeEventListener){a.removeEventListener("unload",b,false)}}c.unloads=h=f=a=b=0;if(window.CollectGarbage){window.CollectGarbage()}}}function g(){var h=document;if(h.readyState=="interactive"){function f(){h.detachEvent("onstop",f);if(b){b()}h=0}if(h){h.attachEvent("onstop",f)}window.setTimeout(function(){if(h){h.detachEvent("onstop",f)}},0)}}if(a.attachEvent){a.attachEvent("onunload",b);a.attachEvent("onbeforeunload",g)}else{if(a.addEventListener){a.addEventListener("unload",b,false)}}c.unloads=[e]}else{c.unloads.push(e)}return e},removeUnload:function(c){var a=this.unloads,b=null;tinymce.each(a,function(e,d){if(e&&e.func==c){a.splice(d,1);b=c;return false}});return b},explode:function(a,b){return a?tinymce.map(a.split(b||","),tinymce.trim):a},_addVer:function(b){var a;if(!this.query){return b}a=(b.indexOf("?")==-1?"?":"&")+this.query;if(b.indexOf("#")==-1){return b+a}return b.replace("#",a+"#")}};window.tinymce=tinymce;tinymce._init();tinymce.create("tinymce.util.Dispatcher",{scope:null,listeners:null,Dispatcher:function(a){this.scope=a||this;this.listeners=[]},add:function(a,b){this.listeners.push({cb:a,scope:b||this.scope});return a},addToTop:function(a,b){this.listeners.unshift({cb:a,scope:b||this.scope});return a},remove:function(a){var b=this.listeners,c=null;tinymce.each(b,function(e,d){if(a==e.cb){c=a;b.splice(d,1);return false}});return c},dispatch:function(){var f,d=arguments,e,b=this.listeners,g;for(e=0;e<b.length;e++){g=b[e];f=g.cb.apply(g.scope,d);if(f===false){break}}return f}});(function(){var a=tinymce.each;tinymce.create("tinymce.util.URI",{URI:function(e,g){var f=this,h,d,c;g=f.settings=g||{};if(/^(mailto|tel|news|javascript|about):/i.test(e)||/^\s*#/.test(e)){f.source=e;return}if(e.indexOf("/")===0&&e.indexOf("//")!==0){e=(g.base_uri?g.base_uri.protocol||"http":"http")+"://mce_host"+e}if(e.indexOf(":/")===-1&&e.indexOf("//")!==0){e=(g.base_uri.protocol||"http")+"://mce_host"+f.toAbsPath(g.base_uri.path,e)}e=e.replace(/@@/g,"(mce_at)");e=/^(?:(?![^:@]+:[^:@\/]*@)([^:\/?#.]+):)?(?:\/\/)?((?:(([^:@]*):?([^:@]*))?@)?([^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/.exec(e);a(["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"],function(b,j){var k=e[j];if(k){k=k.replace(/\(mce_at\)/g,"@@")}f[b]=k});if(c=g.base_uri){if(!f.protocol){f.protocol=c.protocol}if(!f.userInfo){f.userInfo=c.userInfo}if(!f.port&&f.host=="mce_host"){f.port=c.port}if(!f.host||f.host=="mce_host"){f.host=c.host}f.source=""}},setPath:function(c){var b=this;c=/^(.*?)\/?(\w+)?$/.exec(c);b.path=c[0];b.directory=c[1];b.file=c[2];b.source="";b.getURI()},toRelative:function(b){var c=this,d;if(b==="./"){return b}b=new tinymce.util.URI(b,{base_uri:c});if((b.host!="mce_host"&&c.host!=b.host&&b.host)||c.port!=b.port||c.protocol!=b.protocol){return b.getURI()}d=c.toRelPath(c.path,b.path);if(b.query){d+="?"+b.query}if(b.anchor){d+="#"+b.anchor}return d},toAbsolute:function(b,c){var b=new tinymce.util.URI(b,{base_uri:this});return b.getURI(this.host==b.host?c:0)},toRelPath:function(g,h){var c,f=0,d="",e,b;g=g.substring(0,g.lastIndexOf("/"));g=g.split("/");c=h.split("/");if(g.length>=c.length){for(e=0,b=g.length;e<b;e++){if(e>=c.length||g[e]!=c[e]){f=e+1;break}}}if(g.length<c.length){for(e=0,b=c.length;e<b;e++){if(e>=g.length||g[e]!=c[e]){f=e+1;break}}}if(f==1){return h}for(e=0,b=g.length-(f-1);e<b;e++){d+="../"}for(e=f-1,b=c.length;e<b;e++){if(e!=f-1){d+="/"+c[e]}else{d+=c[e]}}return d},toAbsPath:function(e,f){var c,b=0,g=[],d;d=/\/$/.test(f)?"/":"";e=e.split("/");f=f.split("/");a(e,function(h){if(h){g.push(h)}});e=g;for(c=f.length-1,g=[];c>=0;c--){if(f[c].length==0||f[c]=="."){continue}if(f[c]==".."){b++;continue}if(b>0){b--;continue}g.push(f[c])}c=e.length-b;if(c<=0){return"/"+g.reverse().join("/")+d}return"/"+e.slice(0,c).join("/")+"/"+g.reverse().join("/")+d},getURI:function(d){var c,b=this;if(!b.source||d){c="";if(!d){if(b.protocol){c+=b.protocol+"://"}if(b.userInfo){c+=b.userInfo+"@"}if(b.host){c+=b.host}if(b.port){c+=":"+b.port}}if(b.path){c+=b.path}if(b.query){c+="?"+b.query}if(b.anchor){c+="#"+b.anchor}b.source=c}return b.source}})})();(function(){var a=tinymce.each;tinymce.create("static tinymce.util.Cookie",{getHash:function(d){var b=this.get(d),c;if(b){a(b.split("&"),function(e){e=e.split("=");c=c||{};c[unescape(e[0])]=unescape(e[1])})}return c},setHash:function(j,b,g,f,i,c){var h="";a(b,function(e,d){h+=(!h?"":"&")+escape(d)+"="+escape(e)});this.set(j,h,g,f,i,c)},get:function(i){var h=document.cookie,g,f=i+"=",d;if(!h){return}d=h.indexOf("; "+f);if(d==-1){d=h.indexOf(f);if(d!=0){return null}}else{d+=2}g=h.indexOf(";",d);if(g==-1){g=h.length}return unescape(h.substring(d+f.length,g))},set:function(i,b,g,f,h,c){document.cookie=i+"="+escape(b)+((g)?"; expires="+g.toGMTString():"")+((f)?"; path="+escape(f):"")+((h)?"; domain="+h:"")+((c)?"; secure":"")},remove:function(e,b){var c=new Date();c.setTime(c.getTime()-1000);this.set(e,"",c,b,c)}})})();tinymce.create("static tinymce.util.JSON",{serialize:function(e){var c,a,d=tinymce.util.JSON.serialize,b;if(e==null){return"null"}b=typeof e;if(b=="string"){a="\bb\tt\nn\ff\rr\"\"''\\\\";return'"'+e.replace(/([\u0080-\uFFFF\x00-\x1f\"])/g,function(g,f){c=a.indexOf(f);if(c+1){return"\\"+a.charAt(c+1)}g=f.charCodeAt().toString(16);return"\\u"+"0000".substring(g.length)+g})+'"'}if(b=="object"){if(e.hasOwnProperty&&e instanceof Array){for(c=0,a="[";c<e.length;c++){a+=(c>0?",":"")+d(e[c])}return a+"]"}a="{";for(c in e){a+=typeof e[c]!="function"?(a.length>1?',"':'"')+c+'":'+d(e[c]):""}return a+"}"}return""+e},parse:function(s){try{return eval("("+s+")")}catch(ex){}}});tinymce.create("static tinymce.util.XHR",{send:function(g){var a,e,b=window,h=0;g.scope=g.scope||this;g.success_scope=g.success_scope||g.scope;g.error_scope=g.error_scope||g.scope;g.async=g.async===false?false:true;g.data=g.data||"";function d(i){a=0;try{a=new ActiveXObject(i)}catch(c){}return a}a=b.XMLHttpRequest?new XMLHttpRequest():d("Microsoft.XMLHTTP")||d("Msxml2.XMLHTTP");if(a){if(a.overrideMimeType){a.overrideMimeType(g.content_type)}a.open(g.type||(g.data?"POST":"GET"),g.url,g.async);if(g.content_type){a.setRequestHeader("Content-Type",g.content_type)}a.send(g.data);function f(){if(!g.async||a.readyState==4||h++>10000){if(g.success&&h<10000&&a.status==200){g.success.call(g.success_scope,""+a.responseText,a,g)}else{if(g.error){g.error.call(g.error_scope,h>10000?"TIMED_OUT":"GENERAL",a,g)}}a=null}else{b.setTimeout(f,10)}}if(!g.async){return f()}e=b.setTimeout(f,10)}}});(function(){var c=tinymce.extend,b=tinymce.util.JSON,a=tinymce.util.XHR;tinymce.create("tinymce.util.JSONRequest",{JSONRequest:function(d){this.settings=c({},d);this.count=0},send:function(f){var e=f.error,d=f.success;f=c(this.settings,f);f.success=function(h,g){h=b.parse(h);if(typeof(h)=="undefined"){h={error:"JSON Parse error."}}if(h.error){e.call(f.error_scope||f.scope,h.error,g)}else{d.call(f.success_scope||f.scope,h.result)}};f.error=function(h,g){e.call(f.error_scope||f.scope,h,g)};f.data=b.serialize({id:f.id||"c"+(this.count++),method:f.method,params:f.params});f.content_type="application/json";a.send(f)},"static":{sendRPC:function(d){return new tinymce.util.JSONRequest().send(d)}}})}());(function(c){var e=c.each,b=c.is;var d=c.isWebKit,a=c.isIE;c.create("tinymce.dom.DOMUtils",{doc:null,root:null,files:null,pixelStyles:/^(top|left|bottom|right|width|height|borderWidth)$/,props:{"for":"htmlFor","class":"className",className:"className",checked:"checked",disabled:"disabled",maxlength:"maxLength",readonly:"readOnly",selected:"selected",value:"value",id:"id",name:"name",type:"type"},DOMUtils:function(i,g){var f=this;f.doc=i;f.win=window;f.files={};f.cssFlicker=false;f.counter=0;f.boxModel=!c.isIE||i.compatMode=="CSS1Compat";f.stdMode=i.documentMode===8;this.settings=g=c.extend({keep_values:false,hex_colors:1,process_html:1},g);if(c.isIE6){try{i.execCommand("BackgroundImageCache",false,true)}catch(h){f.cssFlicker=true}}c.addUnload(f.destroy,f)},getRoot:function(){var f=this,g=f.settings;return(g&&f.get(g.root_element))||f.doc.body},getViewPort:function(g){var h,f;g=!g?this.win:g;h=g.document;f=this.boxModel?h.documentElement:h.body;return{x:g.pageXOffset||f.scrollLeft,y:g.pageYOffset||f.scrollTop,w:g.innerWidth||f.clientWidth,h:g.innerHeight||f.clientHeight}},getRect:function(i){var h,f=this,g;i=f.get(i);h=f.getPos(i);g=f.getSize(i);return{x:h.x,y:h.y,w:g.w,h:g.h}},getSize:function(j){var g=this,f,i;j=g.get(j);f=g.getStyle(j,"width");i=g.getStyle(j,"height");if(f.indexOf("px")===-1){f=0}if(i.indexOf("px")===-1){i=0}return{w:parseInt(f)||j.offsetWidth||j.clientWidth,h:parseInt(i)||j.offsetHeight||j.clientHeight}},is:function(g,f){return c.dom.Sizzle.matches(f,g.nodeType?[g]:g).length>0},getParent:function(i,h,g){return this.getParents(i,h,g,false)},getParents:function(p,k,i,m){var h=this,g,j=h.settings,l=[];p=h.get(p);m=m===undefined;if(j.strict_root){i=i||h.getRoot()}if(b(k,"string")){g=k;if(k==="*"){k=function(f){return f.nodeType==1}}else{k=function(f){return h.is(f,g)}}}while(p){if(p==i||!p.nodeType||p.nodeType===9){break}if(!k||k(p)){if(m){l.push(p)}else{return p}}p=p.parentNode}return m?l:null},get:function(f){var g;if(f&&this.doc&&typeof(f)=="string"){g=f;f=this.doc.getElementById(f);if(f&&f.id!==g){return this.doc.getElementsByName(g)[1]}}return f},select:function(h,g){var f=this;return c.dom.Sizzle(h,f.get(g)||f.get(f.settings.root_element)||f.doc,[])},add:function(j,l,f,i,k){var g=this;return this.run(j,function(n){var m,h;m=b(l,"string")?g.doc.createElement(l):l;g.setAttribs(m,f);if(i){if(i.nodeType){m.appendChild(i)}else{g.setHTML(m,i)}}return !k?n.appendChild(m):m})},create:function(i,f,g){return this.add(this.doc.createElement(i),i,f,g,1)},createHTML:function(m,f,j){var l="",i=this,g;l+="<"+m;for(g in f){if(f.hasOwnProperty(g)){l+=" "+g+'="'+i.encode(f[g])+'"'}}if(c.is(j)){return l+">"+j+"</"+m+">"}return l+" />"},remove:function(h,f){var g=this;return this.run(h,function(m){var l,k,j;l=m.parentNode;if(!l){return null}if(f){for(j=m.childNodes.length-1;j>=0;j--){g.insertAfter(m.childNodes[j],m)}}if(g.fixPsuedoLeaks){l=m.cloneNode(true);f="IELeakGarbageBin";k=g.get(f)||g.add(g.doc.body,"div",{id:f,style:"display:none"});k.appendChild(m);k.innerHTML="";return l}return l.removeChild(m)})},setStyle:function(i,f,g){var h=this;return h.run(i,function(l){var k,j;k=l.style;f=f.replace(/-(\D)/g,function(n,m){return m.toUpperCase()});if(h.pixelStyles.test(f)&&(c.is(g,"number")||/^[\-0-9\.]+$/.test(g))){g+="px"}switch(f){case"opacity":if(a){k.filter=g===""?"":"alpha(opacity="+(g*100)+")";if(!i.currentStyle||!i.currentStyle.hasLayout){k.display="inline-block"}}k[f]=k["-moz-opacity"]=k["-khtml-opacity"]=g||"";break;case"float":a?k.styleFloat=g:k.cssFloat=g;break;default:k[f]=g||""}if(h.settings.update_styles){h.setAttrib(l,"mce_style")}})},getStyle:function(i,f,h){i=this.get(i);if(!i){return false}if(this.doc.defaultView&&h){f=f.replace(/[A-Z]/g,function(j){return"-"+j});try{return this.doc.defaultView.getComputedStyle(i,null).getPropertyValue(f)}catch(g){return null}}f=f.replace(/-(\D)/g,function(k,j){return j.toUpperCase()});if(f=="float"){f=a?"styleFloat":"cssFloat"}if(i.currentStyle&&h){return i.currentStyle[f]}return i.style[f]},setStyles:function(i,j){var g=this,h=g.settings,f;f=h.update_styles;h.update_styles=0;e(j,function(k,l){g.setStyle(i,l,k)});h.update_styles=f;if(h.update_styles){g.setAttrib(i,h.cssText)}},setAttrib:function(h,i,f){var g=this;if(!h||!i){return}if(g.settings.strict){i=i.toLowerCase()}return this.run(h,function(k){var j=g.settings;switch(i){case"style":if(!b(f,"string")){e(f,function(l,m){g.setStyle(k,m,l)});return}if(j.keep_values){if(f&&!g._isRes(f)){k.setAttribute("mce_style",f,2)}else{k.removeAttribute("mce_style",2)}}k.style.cssText=f;break;case"class":k.className=f||"";break;case"src":case"href":if(j.keep_values){if(j.url_converter){f=j.url_converter.call(j.url_converter_scope||g,f,i,k)}g.setAttrib(k,"mce_"+i,f,2)}break;case"shape":k.setAttribute("mce_style",f);break}if(b(f)&&f!==null&&f.length!==0){k.setAttribute(i,""+f,2)}else{k.removeAttribute(i,2)}})},setAttribs:function(g,h){var f=this;return this.run(g,function(i){e(h,function(j,k){f.setAttrib(i,k,j)})})},getAttrib:function(i,j,h){var f,g=this;i=g.get(i);if(!i||i.nodeType!==1){return false}if(!b(h)){h=""}if(/^(src|href|style|coords|shape)$/.test(j)){f=i.getAttribute("mce_"+j);if(f){return f}}if(a&&g.props[j]){f=i[g.props[j]];f=f&&f.nodeValue?f.nodeValue:f}if(!f){f=i.getAttribute(j,2)}if(j==="style"){f=f||i.style.cssText;if(f){f=g.serializeStyle(g.parseStyle(f));if(g.settings.keep_values&&!g._isRes(f)){i.setAttribute("mce_style",f)}}}if(d&&j==="class"&&f){f=f.replace(/(apple|webkit)\-[a-z\-]+/gi,"")}if(a){switch(j){case"rowspan":case"colspan":if(f===1){f=""}break;case"size":if(f==="+0"||f===20||f===0){f=""}break;case"width":case"height":case"vspace":case"checked":case"disabled":case"readonly":if(f===0){f=""}break;case"hspace":if(f===-1){f=""}break;case"maxlength":case"tabindex":if(f===32768||f===2147483647||f==="32768"){f=""}break;case"multiple":case"compact":case"noshade":case"nowrap":if(f===65535){return j}return h;case"shape":f=f.toLowerCase();break;default:if(j.indexOf("on")===0&&f){f=(""+f).replace(/^function\s+anonymous\(\)\s+\{\s+(.*)\s+\}$/,"$1")}}}return(f!==undefined&&f!==null&&f!=="")?""+f:h},getPos:function(m,i){var g=this,f=0,l=0,j,k=g.doc,h;m=g.get(m);i=i||k.body;if(m){if(a&&!g.stdMode){m=m.getBoundingClientRect();j=g.boxModel?k.documentElement:k.body;f=g.getStyle(g.select("html")[0],"borderWidth");f=(f=="medium"||g.boxModel&&!g.isIE6)&&2||f;m.top+=g.win.self!=g.win.top?2:0;return{x:m.left+j.scrollLeft-f,y:m.top+j.scrollTop-f}}h=m;while(h&&h!=i&&h.nodeType){f+=h.offsetLeft||0;l+=h.offsetTop||0;h=h.offsetParent}h=m.parentNode;while(h&&h!=i&&h.nodeType){f-=h.scrollLeft||0;l-=h.scrollTop||0;h=h.parentNode}}return{x:f,y:l}},parseStyle:function(h){var i=this,j=i.settings,k={};if(!h){return k}function f(w,q,v){var o,u,m,n;o=k[w+"-top"+q];if(!o){return}u=k[w+"-right"+q];if(o!=u){return}m=k[w+"-bottom"+q];if(u!=m){return}n=k[w+"-left"+q];if(m!=n){return}k[v]=n;delete k[w+"-top"+q];delete k[w+"-right"+q];delete k[w+"-bottom"+q];delete k[w+"-left"+q]}function g(n,m,l,p){var o;o=k[m];if(!o){return}o=k[l];if(!o){return}o=k[p];if(!o){return}k[n]=k[m]+" "+k[l]+" "+k[p];delete k[m];delete k[l];delete k[p]}h=h.replace(/&(#?[a-z0-9]+);/g,"&$1_MCE_SEMI_");e(h.split(";"),function(m){var l,n=[];if(m){m=m.replace(/_MCE_SEMI_/g,";");m=m.replace(/url\([^\)]+\)/g,function(o){n.push(o);return"url("+n.length+")"});m=m.split(":");l=c.trim(m[1]);l=l.replace(/url\(([^\)]+)\)/g,function(p,o){return n[parseInt(o)-1]});l=l.replace(/rgb\([^\)]+\)/g,function(o){return i.toHex(o)});if(j.url_converter){l=l.replace(/url\([\'\"]?([^\)\'\"]+)[\'\"]?\)/g,function(o,p){return"url("+j.url_converter.call(j.url_converter_scope||i,i.decode(p),"style",null)+")"})}k[c.trim(m[0]).toLowerCase()]=l}});f("border","","border");f("border","-width","border-width");f("border","-color","border-color");f("border","-style","border-style");f("padding","","padding");f("margin","","margin");g("border","border-width","border-style","border-color");if(a){if(k.border=="medium none"){k.border=""}}return k},serializeStyle:function(g){var f="";e(g,function(i,h){if(h&&i){if(c.isGecko&&h.indexOf("-moz-")===0){return}switch(h){case"color":case"background-color":i=i.toLowerCase();break}f+=(f?" ":"")+h+": "+i+";"}});return f},loadCSS:function(f){var g=this,h=g.doc;if(!f){f=""}e(f.split(","),function(i){if(g.files[i]){return}g.files[i]=true;g.add(g.select("head")[0],"link",{rel:"stylesheet",href:c._addVer(i)})})},addClass:function(f,g){return this.run(f,function(h){var i;if(!g){return 0}if(this.hasClass(h,g)){return h.className}i=this.removeClass(h,g);return h.className=(i!=""?(i+" "):"")+g})},removeClass:function(h,i){var f=this,g;return f.run(h,function(k){var j;if(f.hasClass(k,i)){if(!g){g=new RegExp("(^|\\s+)"+i+"(\\s+|$)","g")}j=k.className.replace(g," ");return k.className=c.trim(j!=" "?j:"")}return k.className})},hasClass:function(g,f){g=this.get(g);if(!g||!f){return false}return(" "+g.className+" ").indexOf(" "+f+" ")!==-1},show:function(f){return this.setStyle(f,"display","block")},hide:function(f){return this.setStyle(f,"display","none")},isHidden:function(f){f=this.get(f);return !f||f.style.display=="none"||this.getStyle(f,"display")=="none"},uniqueId:function(f){return(!f?"mce_":f)+(this.counter++)},setHTML:function(i,g){var f=this;return this.run(i,function(m){var h,k,j,q,l,h;g=f.processHTML(g);if(a){function o(){try{m.innerHTML="<br />"+g;m.removeChild(m.firstChild)}catch(n){while(m.firstChild){m.firstChild.removeNode()}h=f.create("div");h.innerHTML="<br />"+g;e(h.childNodes,function(r,p){if(p){m.appendChild(r)}})}}if(f.settings.fix_ie_paragraphs){g=g.replace(/<p><\/p>|<p([^>]+)><\/p>|<p[^\/+]\/>/gi,'<p$1 mce_keep="true">&nbsp;</p>')}o();if(f.settings.fix_ie_paragraphs){j=m.getElementsByTagName("p");for(k=j.length-1,h=0;k>=0;k--){q=j[k];if(!q.hasChildNodes()){if(!q.mce_keep){h=1;break}q.removeAttribute("mce_keep")}}}if(h){g=g.replace(/<p ([^>]+)>|<p>/g,'<div $1 mce_tmp="1">');g=g.replace(/<\/p>/g,"</div>");o();if(f.settings.fix_ie_paragraphs){j=m.getElementsByTagName("DIV");for(k=j.length-1;k>=0;k--){q=j[k];if(q.mce_tmp){l=f.doc.createElement("p");q.cloneNode(false).outerHTML.replace(/([a-z0-9\-_]+)=/gi,function(p,n){var r;if(n!=="mce_tmp"){r=q.getAttribute(n);if(!r&&n==="class"){r=q.className}l.setAttribute(n,r)}});for(h=0;h<q.childNodes.length;h++){l.appendChild(q.childNodes[h].cloneNode(true))}q.swapNode(l)}}}}}else{m.innerHTML=g}return g})},processHTML:function(j){var g=this,i=g.settings;if(!i.process_html){return j}if(c.isGecko){j=j.replace(/<(\/?)strong>|<strong( [^>]+)>/gi,"<$1b$2>");j=j.replace(/<(\/?)em>|<em( [^>]+)>/gi,"<$1i$2>")}else{if(a){j=j.replace(/&apos;/g,"&#39;");j=j.replace(/\s+(disabled|checked|readonly|selected)\s*=\s*[\"\']?(false|0)[\"\']?/gi,"")}}j=j.replace(/<a( )([^>]+)\/>|<a\/>/gi,"<a$1$2></a>");if(i.keep_values){if(/<script|style/.test(j)){function f(h){h=h.replace(/(<!--\[CDATA\[|\]\]-->)/g,"\n");h=h.replace(/^[\r\n]*|[\r\n]*$/g,"");h=h.replace(/^\s*(\/\/\s*<!--|\/\/\s*<!\[CDATA\[|<!--|<!\[CDATA\[)[\r\n]*/g,"");h=h.replace(/\s*(\/\/\s*\]\]>|\/\/\s*-->|\]\]>|-->|\]\]-->)\s*$/g,"");return h}j=j.replace(/<script([^>]+|)>([\s\S]*?)<\/script>/g,function(l,k,h){h=f(h);if(!k){k=' type="text/javascript"'}if(h){h="<!--\n"+h+"\n// -->"}return"<mce:script"+k+">"+h+"</mce:script>"});j=j.replace(/<style([^>]+|)>([\s\S]*?)<\/style>/g,function(l,k,h){h=f(h);return"<mce:style"+k+"><!--\n"+h+"\n--></mce:style><style"+k+' mce_bogus="1">'+h+"</style>"})}j=j.replace(/<!\[CDATA\[([\s\S]+)\]\]>/g,"<!--[CDATA[$1]]-->");j=j.replace(/<([\w:]+) [^>]*(src|href|style|shape|coords)[^>]*>/gi,function(h,l){function k(o,n,q){var p=q;if(h.indexOf("mce_"+n)!=-1){return o}if(n=="style"){if(g._isRes(q)){return o}if(i.hex_colors){p=p.replace(/rgb\([^\)]+\)/g,function(m){return g.toHex(m)})}if(i.url_converter){p=p.replace(/url\([\'\"]?([^\)\'\"]+)\)/g,function(m,r){return"url("+g.encode(i.url_converter.call(i.url_converter_scope||g,g.decode(r),n,l))+")"})}}else{if(n!="coords"&&n!="shape"){if(i.url_converter){p=g.encode(i.url_converter.call(i.url_converter_scope||g,g.decode(q),n,l))}}}return" "+n+'="'+q+'" mce_'+n+'="'+p+'"'}h=h.replace(/ (src|href|style|coords|shape)=[\"]([^\"]+)[\"]/gi,k);h=h.replace(/ (src|href|style|coords|shape)=[\']([^\']+)[\']/gi,k);return h.replace(/ (src|href|style|coords|shape)=([^\s\"\'>]+)/gi,k)})}return j},getOuterHTML:function(f){var g;f=this.get(f);if(!f){return null}if(f.outerHTML!==undefined){return f.outerHTML}g=(f.ownerDocument||this.doc).createElement("body");g.appendChild(f.cloneNode(true));return g.innerHTML},setOuterHTML:function(i,g,j){var f=this;return this.run(i,function(h){var l,k;h=f.get(h);j=j||h.ownerDocument||f.doc;if(a&&h.nodeType==1){h.outerHTML=g}else{k=j.createElement("body");k.innerHTML=g;l=k.lastChild;while(l){f.insertAfter(l.cloneNode(true),h);l=l.previousSibling}f.remove(h)}})},decode:function(g){var h,i,f;if(/&[^;]+;/.test(g)){h=this.doc.createElement("div");h.innerHTML=g;i=h.firstChild;f="";if(i){do{f+=i.nodeValue}while(i.nextSibling)}return f||g}return g},encode:function(f){return f?(""+f).replace(/[<>&\"]/g,function(h,g){switch(h){case"&":return"&amp;";case'"':return"&quot;";case"<":return"&lt;";case">":return"&gt;"}return h}):f},insertAfter:function(h,g){var f=this;g=f.get(g);return this.run(h,function(k){var j,i;j=g.parentNode;i=g.nextSibling;if(i){j.insertBefore(k,i)}else{j.appendChild(k)}return k})},isBlock:function(f){if(f.nodeType&&f.nodeType!==1){return false}f=f.nodeName||f;return/^(H[1-6]|HR|P|DIV|ADDRESS|PRE|FORM|TABLE|LI|OL|UL|TR|TD|CAPTION|BLOCKQUOTE|CENTER|DL|DT|DD|DIR|FIELDSET|NOSCRIPT|NOFRAMES|MENU|ISINDEX|SAMP)$/.test(f)},replace:function(i,h,f){var g=this;if(b(h,"array")){i=i.cloneNode(true)}return g.run(h,function(j){if(f){e(j.childNodes,function(k){i.appendChild(k.cloneNode(true))})}if(g.fixPsuedoLeaks&&j.nodeType===1){j.parentNode.insertBefore(i,j);g.remove(j);return i}return j.parentNode.replaceChild(i,j)})},findCommonAncestor:function(h,f){var i=h,g;while(i){g=f;while(g&&i!=g){g=g.parentNode}if(i==g){break}i=i.parentNode}if(!i&&h.ownerDocument){return h.ownerDocument.documentElement}return i},toHex:function(f){var h=/^\s*rgb\s*?\(\s*?([0-9]+)\s*?,\s*?([0-9]+)\s*?,\s*?([0-9]+)\s*?\)\s*$/i.exec(f);function g(i){i=parseInt(i).toString(16);return i.length>1?i:"0"+i}if(h){f="#"+g(h[1])+g(h[2])+g(h[3]);return f}return f},getClasses:function(){var l=this,g=[],k,m={},n=l.settings.class_filter,j;if(l.classes){return l.classes}function o(f){e(f.imports,function(i){o(i)});e(f.cssRules||f.rules,function(i){switch(i.type||1){case 1:if(i.selectorText){e(i.selectorText.split(","),function(p){p=p.replace(/^\s*|\s*$|^\s\./g,"");if(/\.mce/.test(p)||!/\.[\w\-]+$/.test(p)){return}j=p;p=p.replace(/.*\.([a-z0-9_\-]+).*/i,"$1");if(n&&!(p=n(p,j))){return}if(!m[p]){g.push({"class":p});m[p]=1}})}break;case 3:o(i.styleSheet);break}})}try{e(l.doc.styleSheets,o)}catch(h){}if(g.length>0){l.classes=g}return g},run:function(j,i,h){var g=this,k;if(g.doc&&typeof(j)==="string"){j=g.get(j)}if(!j){return false}h=h||this;if(!j.nodeType&&(j.length||j.length===0)){k=[];e(j,function(l,f){if(l){if(typeof(l)=="string"){l=g.doc.getElementById(l)}k.push(i.call(h,l,f))}});return k}return i.call(h,j)},getAttribs:function(g){var f;g=this.get(g);if(!g){return[]}if(a){f=[];if(g.nodeName=="OBJECT"){return g.attributes}g.cloneNode(false).outerHTML.replace(/([a-z0-9\:\-_]+)=/gi,function(i,h){f.push({specified:1,nodeName:h})});return f}return g.attributes},destroy:function(g){var f=this;f.win=f.doc=f.root=null;if(!g){c.removeUnload(f.destroy)}},createRng:function(){var f=this.doc;return f.createRange?f.createRange():new c.dom.Range(this)},split:function(k,j,n){var o=this,f=o.createRng(),l,i,m;function g(q,p){q=q[p];if(q&&q[p]&&q[p].nodeType==1&&h(q[p])){o.remove(q[p])}}function h(p){p=o.getOuterHTML(p);p=p.replace(/<(img|hr|table)/gi,"-");p=p.replace(/<[^>]+>/g,"");return p.replace(/[ \t\r\n]+|&nbsp;|&#160;/g,"")==""}if(k&&j){f.setStartBefore(k);f.setEndBefore(j);l=f.extractContents();f=o.createRng();f.setStartAfter(j);f.setEndAfter(k);i=f.extractContents();m=k.parentNode;g(l,"lastChild");if(!h(l)){m.insertBefore(l,k)}if(n){m.replaceChild(n,j)}else{m.insertBefore(j,k)}g(i,"firstChild");if(!h(i)){m.insertBefore(i,k)}o.remove(k);return n||j}},_isRes:function(f){return/^(top|left|bottom|right|width|height)/i.test(f)||/;\s*(top|left|bottom|right|width|height)/i.test(f)}});c.DOM=new c.dom.DOMUtils(document,{process_html:0})})(tinymce);(function(f){var h=0,c=1,e=2,d=tinymce.extend;function g(m,k){var j,l;if(m.parentNode!=k){return -1}for(l=k.firstChild,j=0;l!=m;l=l.nextSibling){j++}return j}function b(k){var j=0;while(k.previousSibling){j++;k=k.previousSibling}return j}function i(j,k){var l;if(j.nodeType==3){return j}if(k<0){return j}l=j.firstChild;while(l!=null&&k>0){--k;l=l.nextSibling}if(l!=null){return l}return j}function a(k){var j=k.doc;d(this,{dom:k,startContainer:j,startOffset:0,endContainer:j,endOffset:0,collapsed:true,commonAncestorContainer:j,START_TO_START:0,START_TO_END:1,END_TO_END:2,END_TO_START:3})}d(a.prototype,{setStart:function(k,j){this._setEndPoint(true,k,j)},setEnd:function(k,j){this._setEndPoint(false,k,j)},setStartBefore:function(j){this.setStart(j.parentNode,b(j))},setStartAfter:function(j){this.setStart(j.parentNode,b(j)+1)},setEndBefore:function(j){this.setEnd(j.parentNode,b(j))},setEndAfter:function(j){this.setEnd(j.parentNode,b(j)+1)},collapse:function(k){var j=this;if(k){j.endContainer=j.startContainer;j.endOffset=j.startOffset}else{j.startContainer=j.endContainer;j.startOffset=j.endOffset}j.collapsed=true},selectNode:function(j){this.setStartBefore(j);this.setEndAfter(j)},selectNodeContents:function(j){this.setStart(j,0);this.setEnd(j,j.nodeType===1?j.childNodes.length:j.nodeValue.length)},compareBoundaryPoints:function(m,n){var l=this,p=l.startContainer,o=l.startOffset,k=l.endContainer,j=l.endOffset;if(m===0){return l._compareBoundaryPoints(p,o,p,o)}if(m===1){return l._compareBoundaryPoints(p,o,k,j)}if(m===2){return l._compareBoundaryPoints(k,j,k,j)}if(m===3){return l._compareBoundaryPoints(k,j,p,o)}},deleteContents:function(){this._traverse(e)},extractContents:function(){return this._traverse(h)},cloneContents:function(){return this._traverse(c)},insertNode:function(m){var j=this,l,k;if(m.nodeType===3||m.nodeType===4){l=j.startContainer.splitText(j.startOffset);j.startContainer.parentNode.insertBefore(m,l)}else{if(j.startContainer.childNodes.length>0){k=j.startContainer.childNodes[j.startOffset]}j.startContainer.insertBefore(m,k)}},surroundContents:function(l){var j=this,k=j.extractContents();j.insertNode(l);l.appendChild(k);j.selectNode(l)},cloneRange:function(){var j=this;return d(new a(j.dom),{startContainer:j.startContainer,startOffset:j.startOffset,endContainer:j.endContainer,endOffset:j.endOffset,collapsed:j.collapsed,commonAncestorContainer:j.commonAncestorContainer})},_isCollapsed:function(){return(this.startContainer==this.endContainer&&this.startOffset==this.endOffset)},_compareBoundaryPoints:function(m,p,k,o){var q,l,j,r,t,s;if(m==k){if(p==o){return 0}else{if(p<o){return -1}else{return 1}}}q=k;while(q&&q.parentNode!=m){q=q.parentNode}if(q){l=0;j=m.firstChild;while(j!=q&&l<p){l++;j=j.nextSibling}if(p<=l){return -1}else{return 1}}q=m;while(q&&q.parentNode!=k){q=q.parentNode}if(q){l=0;j=k.firstChild;while(j!=q&&l<o){l++;j=j.nextSibling}if(l<o){return -1}else{return 1}}r=this.dom.findCommonAncestor(m,k);t=m;while(t&&t.parentNode!=r){t=t.parentNode}if(!t){t=r}s=k;while(s&&s.parentNode!=r){s=s.parentNode}if(!s){s=r}if(t==s){return 0}j=r.firstChild;while(j){if(j==t){return -1}if(j==s){return 1}j=j.nextSibling}},_setEndPoint:function(k,q,p){var l=this,j,m;if(k){l.startContainer=q;l.startOffset=p}else{l.endContainer=q;l.endOffset=p}j=l.endContainer;while(j.parentNode){j=j.parentNode}m=l.startContainer;while(m.parentNode){m=m.parentNode}if(m!=j){l.collapse(k)}else{if(l._compareBoundaryPoints(l.startContainer,l.startOffset,l.endContainer,l.endOffset)>0){l.collapse(k)}}l.collapsed=l._isCollapsed();l.commonAncestorContainer=l.dom.findCommonAncestor(l.startContainer,l.endContainer)},_traverse:function(r){var s=this,q,m=0,v=0,k,o,l,n,j,u;if(s.startContainer==s.endContainer){return s._traverseSameContainer(r)}for(q=s.endContainer,k=q.parentNode;k!=null;q=k,k=k.parentNode){if(k==s.startContainer){return s._traverseCommonStartContainer(q,r)}++m}for(q=s.startContainer,k=q.parentNode;k!=null;q=k,k=k.parentNode){if(k==s.endContainer){return s._traverseCommonEndContainer(q,r)}++v}o=v-m;l=s.startContainer;while(o>0){l=l.parentNode;o--}n=s.endContainer;while(o<0){n=n.parentNode;o++}for(j=l.parentNode,u=n.parentNode;j!=u;j=j.parentNode,u=u.parentNode){l=j;n=u}return s._traverseCommonAncestors(l,n,r)},_traverseSameContainer:function(o){var r=this,q,u,j,k,l,p,m;if(o!=e){q=r.dom.doc.createDocumentFragment()}if(r.startOffset==r.endOffset){return q}if(r.startContainer.nodeType==3){u=r.startContainer.nodeValue;j=u.substring(r.startOffset,r.endOffset);if(o!=c){r.startContainer.deleteData(r.startOffset,r.endOffset-r.startOffset);r.collapse(true)}if(o==e){return null}q.appendChild(r.dom.doc.createTextNode(j));return q}k=i(r.startContainer,r.startOffset);l=r.endOffset-r.startOffset;while(l>0){p=k.nextSibling;m=r._traverseFullySelected(k,o);if(q){q.appendChild(m)}--l;k=p}if(o!=c){r.collapse(true)}return q},_traverseCommonStartContainer:function(j,p){var s=this,r,k,l,m,q,o;if(p!=e){r=s.dom.doc.createDocumentFragment()}k=s._traverseRightBoundary(j,p);if(r){r.appendChild(k)}l=g(j,s.startContainer);m=l-s.startOffset;if(m<=0){if(p!=c){s.setEndBefore(j);s.collapse(false)}return r}k=j.previousSibling;while(m>0){q=k.previousSibling;o=s._traverseFullySelected(k,p);if(r){r.insertBefore(o,r.firstChild)}--m;k=q}if(p!=c){s.setEndBefore(j);s.collapse(false)}return r},_traverseCommonEndContainer:function(m,p){var s=this,r,o,j,k,q,l;if(p!=e){r=s.dom.doc.createDocumentFragment()}j=s._traverseLeftBoundary(m,p);if(r){r.appendChild(j)}o=g(m,s.endContainer);++o;k=s.endOffset-o;j=m.nextSibling;while(k>0){q=j.nextSibling;l=s._traverseFullySelected(j,p);if(r){r.appendChild(l)}--k;j=q}if(p!=c){s.setStartAfter(m);s.collapse(true)}return r},_traverseCommonAncestors:function(p,j,s){var w=this,l,v,o,q,r,k,u,m;if(s!=e){v=w.dom.doc.createDocumentFragment()}l=w._traverseLeftBoundary(p,s);if(v){v.appendChild(l)}o=p.parentNode;q=g(p,o);r=g(j,o);++q;k=r-q;u=p.nextSibling;while(k>0){m=u.nextSibling;l=w._traverseFullySelected(u,s);if(v){v.appendChild(l)}u=m;--k}l=w._traverseRightBoundary(j,s);if(v){v.appendChild(l)}if(s!=c){w.setStartAfter(p);w.collapse(true)}return v},_traverseRightBoundary:function(p,q){var s=this,l=i(s.endContainer,s.endOffset-1),r,o,n,j,k;var m=l!=s.endContainer;if(l==p){return s._traverseNode(l,m,false,q)}r=l.parentNode;o=s._traverseNode(r,false,false,q);while(r!=null){while(l!=null){n=l.previousSibling;j=s._traverseNode(l,m,false,q);if(q!=e){o.insertBefore(j,o.firstChild)}m=true;l=n}if(r==p){return o}l=r.previousSibling;r=r.parentNode;k=s._traverseNode(r,false,false,q);if(q!=e){k.appendChild(o)}o=k}return null},_traverseLeftBoundary:function(p,q){var s=this,m=i(s.startContainer,s.startOffset);var n=m!=s.startContainer,r,o,l,j,k;if(m==p){return s._traverseNode(m,n,true,q)}r=m.parentNode;o=s._traverseNode(r,false,true,q);while(r!=null){while(m!=null){l=m.nextSibling;j=s._traverseNode(m,n,true,q);if(q!=e){o.appendChild(j)}n=true;m=l}if(r==p){return o}m=r.nextSibling;r=r.parentNode;k=s._traverseNode(r,false,true,q);if(q!=e){k.appendChild(o)}o=k}return null},_traverseNode:function(j,o,r,s){var u=this,m,l,p,k,q;if(o){return u._traverseFullySelected(j,s)}if(j.nodeType==3){m=j.nodeValue;if(r){k=u.startOffset;l=m.substring(k);p=m.substring(0,k)}else{k=u.endOffset;l=m.substring(0,k);p=m.substring(k)}if(s!=c){j.nodeValue=p}if(s==e){return null}q=j.cloneNode(false);q.nodeValue=l;return q}if(s==e){return null}return j.cloneNode(false)},_traverseFullySelected:function(l,k){var j=this;if(k!=e){return k==c?l.cloneNode(true):l}l.parentNode.removeChild(l);return null}});f.Range=a})(tinymce.dom);(function(){function a(e){var d=this,h="\uFEFF",b,g;function c(j,i){if(j&&i){if(j.item&&i.item&&j.item(0)===i.item(0)){return 1}if(j.isEqual&&i.isEqual&&i.isEqual(j)){return 1}}return 0}function f(){var m=e.dom,j=e.getRng(),s=m.createRng(),p,k,n,q,o,l;function i(v){var t=v.parentNode.childNodes,u;for(u=t.length-1;u>=0;u--){if(t[u]==v){return u}}return -1}function r(v){var t=j.duplicate(),B,y,u,w,x=0,z=0,A,C;t.collapse(v);B=t.parentElement();t.pasteHTML(h);u=B.childNodes;for(y=0;y<u.length;y++){w=u[y];if(y>0&&(w.nodeType!==3||u[y-1].nodeType!==3)){z++}if(w.nodeType===3){A=w.nodeValue.indexOf(h);if(A!==-1){x+=A;break}x+=w.nodeValue.length}else{x=0}}t.moveStart("character",-1);t.text="";return{index:z,offset:x,parent:B}}n=j.item?j.item(0):j.parentElement();if(n.ownerDocument!=m.doc){return s}if(j.item||!n.hasChildNodes()){s.setStart(n.parentNode,i(n));s.setEnd(s.startContainer,s.startOffset+1);return s}l=e.isCollapsed();p=r(true);k=r(false);p.parent.normalize();k.parent.normalize();q=p.parent.childNodes[Math.min(p.index,p.parent.childNodes.length-1)];if(q.nodeType!=3){s.setStart(p.parent,p.index)}else{s.setStart(p.parent.childNodes[p.index],p.offset)}o=k.parent.childNodes[Math.min(k.index,k.parent.childNodes.length-1)];if(o.nodeType!=3){if(!l){k.index++}s.setEnd(k.parent,k.index)}else{s.setEnd(k.parent.childNodes[k.index],k.offset)}if(!l){q=s.startContainer;if(q.nodeType==1){s.setStart(q,Math.min(s.startOffset,q.childNodes.length))}o=s.endContainer;if(o.nodeType==1){s.setEnd(o,Math.min(s.endOffset,o.childNodes.length))}}d.addRange(s);return s}this.addRange=function(j){var o,m=e.dom.doc.body,p,k,q,l,n,i;q=j.startContainer;l=j.startOffset;n=j.endContainer;i=j.endOffset;o=m.createTextRange();q=q.nodeType==1?q.childNodes[Math.min(l,q.childNodes.length-1)]:q;n=n.nodeType==1?n.childNodes[Math.min(l==i?i:i-1,n.childNodes.length-1)]:n;if(q==n&&q.nodeType==1){if(/^(IMG|TABLE)$/.test(q.nodeName)&&l!=i){o=m.createControlRange();o.addElement(q)}else{o=m.createTextRange();if(!q.hasChildNodes()&&q.canHaveHTML){q.innerHTML=h}o.moveToElementText(q);if(q.innerHTML==h){o.collapse(true);q.removeChild(q.firstChild)}}if(l==i){o.collapse(i<=j.endContainer.childNodes.length-1)}o.select();return}function r(t,v){var u,s,w;if(t.nodeType!=3){return -1}u=t.nodeValue;s=m.createTextRange();t.nodeValue=u.substring(0,v)+h+u.substring(v);s.moveToElementText(t.parentNode);s.findText(h);w=Math.abs(s.moveStart("character",-1048575));t.nodeValue=u;return w}if(j.collapsed){pos=r(q,l);o=m.createTextRange();o.move("character",pos);o.select();return}else{if(q==n&&q.nodeType==3){p=r(q,l);o.move("character",p);o.moveEnd("character",i-l);o.select();return}p=r(q,l);k=r(n,i);o=m.createTextRange();if(p==-1){o.moveToElementText(q);p=0}else{o.move("character",p)}tmpRng=m.createTextRange();if(k==-1){tmpRng.moveToElementText(n)}else{tmpRng.move("character",k)}o.setEndPoint("EndToEnd",tmpRng);o.select();return}};this.getRangeAt=function(){if(!b||!c(g,e.getRng())){b=f();g=e.getRng()}return b};this.destroy=function(){g=b=null}}tinymce.dom.TridentSelection=a})();(function(){var p=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?/g,i=0,d=Object.prototype.toString,n=false;var b=function(D,t,A,v){A=A||[];var e=t=t||document;if(t.nodeType!==1&&t.nodeType!==9){return[]}if(!D||typeof D!=="string"){return A}var B=[],C,y,G,F,z,s,r=true,w=o(t);p.lastIndex=0;while((C=p.exec(D))!==null){B.push(C[1]);if(C[2]){s=RegExp.rightContext;break}}if(B.length>1&&j.exec(D)){if(B.length===2&&f.relative[B[0]]){y=g(B[0]+B[1],t)}else{y=f.relative[B[0]]?[t]:b(B.shift(),t);while(B.length){D=B.shift();if(f.relative[D]){D+=B.shift()}y=g(D,y)}}}else{if(!v&&B.length>1&&t.nodeType===9&&!w&&f.match.ID.test(B[0])&&!f.match.ID.test(B[B.length-1])){var H=b.find(B.shift(),t,w);t=H.expr?b.filter(H.expr,H.set)[0]:H.set[0]}if(t){var H=v?{expr:B.pop(),set:a(v)}:b.find(B.pop(),B.length===1&&(B[0]==="~"||B[0]==="+")&&t.parentNode?t.parentNode:t,w);y=H.expr?b.filter(H.expr,H.set):H.set;if(B.length>0){G=a(y)}else{r=false}while(B.length){var u=B.pop(),x=u;if(!f.relative[u]){u=""}else{x=B.pop()}if(x==null){x=t}f.relative[u](G,x,w)}}else{G=B=[]}}if(!G){G=y}if(!G){throw"Syntax error, unrecognized expression: "+(u||D)}if(d.call(G)==="[object Array]"){if(!r){A.push.apply(A,G)}else{if(t&&t.nodeType===1){for(var E=0;G[E]!=null;E++){if(G[E]&&(G[E]===true||G[E].nodeType===1&&h(t,G[E]))){A.push(y[E])}}}else{for(var E=0;G[E]!=null;E++){if(G[E]&&G[E].nodeType===1){A.push(y[E])}}}}}else{a(G,A)}if(s){b(s,e,A,v);b.uniqueSort(A)}return A};b.uniqueSort=function(r){if(c){n=false;r.sort(c);if(n){for(var e=1;e<r.length;e++){if(r[e]===r[e-1]){r.splice(e--,1)}}}}};b.matches=function(e,r){return b(e,null,null,r)};b.find=function(x,e,y){var w,u;if(!x){return[]}for(var t=0,s=f.order.length;t<s;t++){var v=f.order[t],u;if((u=f.match[v].exec(x))){var r=RegExp.leftContext;if(r.substr(r.length-1)!=="\\"){u[1]=(u[1]||"").replace(/\\/g,"");w=f.find[v](u,e,y);if(w!=null){x=x.replace(f.match[v],"");break}}}}if(!w){w=e.getElementsByTagName("*")}return{set:w,expr:x}};b.filter=function(A,z,D,t){var s=A,F=[],x=z,v,e,w=z&&z[0]&&o(z[0]);while(A&&z.length){for(var y in f.filter){if((v=f.match[y].exec(A))!=null){var r=f.filter[y],E,C;e=false;if(x==F){F=[]}if(f.preFilter[y]){v=f.preFilter[y](v,x,D,F,t,w);if(!v){e=E=true}else{if(v===true){continue}}}if(v){for(var u=0;(C=x[u])!=null;u++){if(C){E=r(C,v,u,x);var B=t^!!E;if(D&&E!=null){if(B){e=true}else{x[u]=false}}else{if(B){F.push(C);e=true}}}}}if(E!==undefined){if(!D){x=F}A=A.replace(f.match[y],"");if(!e){return[]}break}}}if(A==s){if(e==null){throw"Syntax error, unrecognized expression: "+A}else{break}}s=A}return x};var f=b.selectors={order:["ID","NAME","TAG"],match:{ID:/#((?:[\w\u00c0-\uFFFF_-]|\\.)+)/,CLASS:/\.((?:[\w\u00c0-\uFFFF_-]|\\.)+)/,NAME:/\[name=['"]*((?:[\w\u00c0-\uFFFF_-]|\\.)+)['"]*\]/,ATTR:/\[\s*((?:[\w\u00c0-\uFFFF_-]|\\.)+)\s*(?:(\S?=)\s*(['"]*)(.*?)\3|)\s*\]/,TAG:/^((?:[\w\u00c0-\uFFFF\*_-]|\\.)+)/,CHILD:/:(only|nth|last|first)-child(?:\((even|odd|[\dn+-]*)\))?/,POS:/:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^-]|$)/,PSEUDO:/:((?:[\w\u00c0-\uFFFF_-]|\\.)+)(?:\((['"]*)((?:\([^\)]+\)|[^\2\(\)]*)+)\2\))?/},attrMap:{"class":"className","for":"htmlFor"},attrHandle:{href:function(e){return e.getAttribute("href")}},relative:{"+":function(x,e,w){var u=typeof e==="string",y=u&&!/\W/.test(e),v=u&&!y;if(y&&!w){e=e.toUpperCase()}for(var t=0,s=x.length,r;t<s;t++){if((r=x[t])){while((r=r.previousSibling)&&r.nodeType!==1){}x[t]=v||r&&r.nodeName===e?r||false:r===e}}if(v){b.filter(e,x,true)}},">":function(w,r,x){var u=typeof r==="string";if(u&&!/\W/.test(r)){r=x?r:r.toUpperCase();for(var s=0,e=w.length;s<e;s++){var v=w[s];if(v){var t=v.parentNode;w[s]=t.nodeName===r?t:false}}}else{for(var s=0,e=w.length;s<e;s++){var v=w[s];if(v){w[s]=u?v.parentNode:v.parentNode===r}}if(u){b.filter(r,w,true)}}},"":function(t,r,v){var s=i++,e=q;if(!r.match(/\W/)){var u=r=v?r:r.toUpperCase();e=m}e("parentNode",r,s,t,u,v)},"~":function(t,r,v){var s=i++,e=q;if(typeof r==="string"&&!r.match(/\W/)){var u=r=v?r:r.toUpperCase();e=m}e("previousSibling",r,s,t,u,v)}},find:{ID:function(r,s,t){if(typeof s.getElementById!=="undefined"&&!t){var e=s.getElementById(r[1]);return e?[e]:[]}},NAME:function(s,v,w){if(typeof v.getElementsByName!=="undefined"){var r=[],u=v.getElementsByName(s[1]);for(var t=0,e=u.length;t<e;t++){if(u[t].getAttribute("name")===s[1]){r.push(u[t])}}return r.length===0?null:r}},TAG:function(e,r){return r.getElementsByTagName(e[1])}},preFilter:{CLASS:function(t,r,s,e,w,x){t=" "+t[1].replace(/\\/g,"")+" ";if(x){return t}for(var u=0,v;(v=r[u])!=null;u++){if(v){if(w^(v.className&&(" "+v.className+" ").indexOf(t)>=0)){if(!s){e.push(v)}}else{if(s){r[u]=false}}}}return false},ID:function(e){return e[1].replace(/\\/g,"")},TAG:function(r,e){for(var s=0;e[s]===false;s++){}return e[s]&&o(e[s])?r[1]:r[1].toUpperCase()},CHILD:function(e){if(e[1]=="nth"){var r=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(e[2]=="even"&&"2n"||e[2]=="odd"&&"2n+1"||!/\D/.test(e[2])&&"0n+"+e[2]||e[2]);e[2]=(r[1]+(r[2]||1))-0;e[3]=r[3]-0}e[0]=i++;return e},ATTR:function(u,r,s,e,v,w){var t=u[1].replace(/\\/g,"");if(!w&&f.attrMap[t]){u[1]=f.attrMap[t]}if(u[2]==="~="){u[4]=" "+u[4]+" "}return u},PSEUDO:function(u,r,s,e,v){if(u[1]==="not"){if(u[3].match(p).length>1||/^\w/.test(u[3])){u[3]=b(u[3],null,null,r)}else{var t=b.filter(u[3],r,s,true^v);if(!s){e.push.apply(e,t)}return false}}else{if(f.match.POS.test(u[0])||f.match.CHILD.test(u[0])){return true}}return u},POS:function(e){e.unshift(true);return e}},filters:{enabled:function(e){return e.disabled===false&&e.type!=="hidden"},disabled:function(e){return e.disabled===true},checked:function(e){return e.checked===true},selected:function(e){e.parentNode.selectedIndex;return e.selected===true},parent:function(e){return !!e.firstChild},empty:function(e){return !e.firstChild},has:function(s,r,e){return !!b(e[3],s).length},header:function(e){return/h\d/i.test(e.nodeName)},text:function(e){return"text"===e.type},radio:function(e){return"radio"===e.type},checkbox:function(e){return"checkbox"===e.type},file:function(e){return"file"===e.type},password:function(e){return"password"===e.type},submit:function(e){return"submit"===e.type},image:function(e){return"image"===e.type},reset:function(e){return"reset"===e.type},button:function(e){return"button"===e.type||e.nodeName.toUpperCase()==="BUTTON"},input:function(e){return/input|select|textarea|button/i.test(e.nodeName)}},setFilters:{first:function(r,e){return e===0},last:function(s,r,e,t){return r===t.length-1},even:function(r,e){return e%2===0},odd:function(r,e){return e%2===1},lt:function(s,r,e){return r<e[3]-0},gt:function(s,r,e){return r>e[3]-0},nth:function(s,r,e){return e[3]-0==r},eq:function(s,r,e){return e[3]-0==r}},filter:{PSEUDO:function(w,s,t,x){var r=s[1],u=f.filters[r];if(u){return u(w,t,s,x)}else{if(r==="contains"){return(w.textContent||w.innerText||"").indexOf(s[3])>=0}else{if(r==="not"){var v=s[3];for(var t=0,e=v.length;t<e;t++){if(v[t]===w){return false}}return true}}}},CHILD:function(e,t){var w=t[1],r=e;switch(w){case"only":case"first":while(r=r.previousSibling){if(r.nodeType===1){return false}}if(w=="first"){return true}r=e;case"last":while(r=r.nextSibling){if(r.nodeType===1){return false}}return true;case"nth":var s=t[2],z=t[3];if(s==1&&z==0){return true}var v=t[0],y=e.parentNode;if(y&&(y.sizcache!==v||!e.nodeIndex)){var u=0;for(r=y.firstChild;r;r=r.nextSibling){if(r.nodeType===1){r.nodeIndex=++u}}y.sizcache=v}var x=e.nodeIndex-z;if(s==0){return x==0}else{return(x%s==0&&x/s>=0)}}},ID:function(r,e){return r.nodeType===1&&r.getAttribute("id")===e},TAG:function(r,e){return(e==="*"&&r.nodeType===1)||r.nodeName===e},CLASS:function(r,e){return(" "+(r.className||r.getAttribute("class"))+" ").indexOf(e)>-1},ATTR:function(v,t){var s=t[1],e=f.attrHandle[s]?f.attrHandle[s](v):v[s]!=null?v[s]:v.getAttribute(s),w=e+"",u=t[2],r=t[4];return e==null?u==="!=":u==="="?w===r:u==="*="?w.indexOf(r)>=0:u==="~="?(" "+w+" ").indexOf(r)>=0:!r?w&&e!==false:u==="!="?w!=r:u==="^="?w.indexOf(r)===0:u==="$="?w.substr(w.length-r.length)===r:u==="|="?w===r||w.substr(0,r.length+1)===r+"-":false},POS:function(u,r,s,v){var e=r[2],t=f.setFilters[e];if(t){return t(u,s,r,v)}}}};var j=f.match.POS;for(var l in f.match){f.match[l]=new RegExp(f.match[l].source+/(?![^\[]*\])(?![^\(]*\))/.source)}var a=function(r,e){r=Array.prototype.slice.call(r);if(e){e.push.apply(e,r);return e}return r};try{Array.prototype.slice.call(document.documentElement.childNodes)}catch(k){a=function(u,t){var r=t||[];if(d.call(u)==="[object Array]"){Array.prototype.push.apply(r,u)}else{if(typeof u.length==="number"){for(var s=0,e=u.length;s<e;s++){r.push(u[s])}}else{for(var s=0;u[s];s++){r.push(u[s])}}}return r}}var c;if(document.documentElement.compareDocumentPosition){c=function(r,e){var s=r.compareDocumentPosition(e)&4?-1:r===e?0:1;if(s===0){n=true}return s}}else{if("sourceIndex" in document.documentElement){c=function(r,e){var s=r.sourceIndex-e.sourceIndex;if(s===0){n=true}return s}}else{if(document.createRange){c=function(t,r){var s=t.ownerDocument.createRange(),e=r.ownerDocument.createRange();s.setStart(t,0);s.setEnd(t,0);e.setStart(r,0);e.setEnd(r,0);var u=s.compareBoundaryPoints(Range.START_TO_END,e);if(u===0){n=true}return u}}}}(function(){var r=document.createElement("div"),s="script"+(new Date).getTime();r.innerHTML="<a name='"+s+"'/>";var e=document.documentElement;e.insertBefore(r,e.firstChild);if(!!document.getElementById(s)){f.find.ID=function(u,v,w){if(typeof v.getElementById!=="undefined"&&!w){var t=v.getElementById(u[1]);return t?t.id===u[1]||typeof t.getAttributeNode!=="undefined"&&t.getAttributeNode("id").nodeValue===u[1]?[t]:undefined:[]}};f.filter.ID=function(v,t){var u=typeof v.getAttributeNode!=="undefined"&&v.getAttributeNode("id");return v.nodeType===1&&u&&u.nodeValue===t}}e.removeChild(r)})();(function(){var e=document.createElement("div");e.appendChild(document.createComment(""));if(e.getElementsByTagName("*").length>0){f.find.TAG=function(r,v){var u=v.getElementsByTagName(r[1]);if(r[1]==="*"){var t=[];for(var s=0;u[s];s++){if(u[s].nodeType===1){t.push(u[s])}}u=t}return u}}e.innerHTML="<a href='#'></a>";if(e.firstChild&&typeof e.firstChild.getAttribute!=="undefined"&&e.firstChild.getAttribute("href")!=="#"){f.attrHandle.href=function(r){return r.getAttribute("href",2)}}})();if(document.querySelectorAll){(function(){var e=b,s=document.createElement("div");s.innerHTML="<p class='TEST'></p>";if(s.querySelectorAll&&s.querySelectorAll(".TEST").length===0){return}b=function(w,v,t,u){v=v||document;if(!u&&v.nodeType===9&&!o(v)){try{return a(v.querySelectorAll(w),t)}catch(x){}}return e(w,v,t,u)};for(var r in e){b[r]=e[r]}})()}if(document.getElementsByClassName&&document.documentElement.getElementsByClassName){(function(){var e=document.createElement("div");e.innerHTML="<div class='test e'></div><div class='test'></div>";if(e.getElementsByClassName("e").length===0){return}e.lastChild.className="e";if(e.getElementsByClassName("e").length===1){return}f.order.splice(1,0,"CLASS");f.find.CLASS=function(r,s,t){if(typeof s.getElementsByClassName!=="undefined"&&!t){return s.getElementsByClassName(r[1])}}})()}function m(r,w,v,A,x,z){var y=r=="previousSibling"&&!z;for(var t=0,s=A.length;t<s;t++){var e=A[t];if(e){if(y&&e.nodeType===1){e.sizcache=v;e.sizset=t}e=e[r];var u=false;while(e){if(e.sizcache===v){u=A[e.sizset];break}if(e.nodeType===1&&!z){e.sizcache=v;e.sizset=t}if(e.nodeName===w){u=e;break}e=e[r]}A[t]=u}}}function q(r,w,v,A,x,z){var y=r=="previousSibling"&&!z;for(var t=0,s=A.length;t<s;t++){var e=A[t];if(e){if(y&&e.nodeType===1){e.sizcache=v;e.sizset=t}e=e[r];var u=false;while(e){if(e.sizcache===v){u=A[e.sizset];break}if(e.nodeType===1){if(!z){e.sizcache=v;e.sizset=t}if(typeof w!=="string"){if(e===w){u=true;break}}else{if(b.filter(w,[e]).length>0){u=e;break}}}e=e[r]}A[t]=u}}}var h=document.compareDocumentPosition?function(r,e){return r.compareDocumentPosition(e)&16}:function(r,e){return r!==e&&(r.contains?r.contains(e):true)};var o=function(e){return e.nodeType===9&&e.documentElement.nodeName!=="HTML"||!!e.ownerDocument&&e.ownerDocument.documentElement.nodeName!=="HTML"};var g=function(e,x){var t=[],u="",v,s=x.nodeType?[x]:x;while((v=f.match.PSEUDO.exec(e))){u+=v[0];e=e.replace(f.match.PSEUDO,"")}e=f.relative[e]?e+"*":e;for(var w=0,r=s.length;w<r;w++){b(e,s[w],t)}return b.filter(u,t)};window.tinymce.dom.Sizzle=b})();(function(d){var f=d.each,c=d.DOM,b=d.isIE,e=d.isWebKit,a;d.create("static tinymce.dom.Event",{inits:[],events:[],add:function(m,p,l,j){var g,h=this,i=h.events,k;if(m&&m.hasOwnProperty&&m instanceof Array){k=[];f(m,function(n){n=c.get(n);k.push(h.add(n,p,l,j))});return k}m=c.get(m);if(!m){return}g=function(n){n=n||window.event;if(n&&!n.target&&b){n.target=n.srcElement}if(!j){return l(n)}return l.call(j,n)};if(p=="unload"){d.unloads.unshift({func:g});return g}if(p=="init"){if(h.domLoaded){g()}else{h.inits.push(g)}return g}i.push({obj:m,name:p,func:l,cfunc:g,scope:j});h._add(m,p,g);return l},remove:function(l,m,k){var h=this,g=h.events,i=false,j;if(l&&l.hasOwnProperty&&l instanceof Array){j=[];f(l,function(n){n=c.get(n);j.push(h.remove(n,m,k))});return j}l=c.get(l);f(g,function(o,n){if(o.obj==l&&o.name==m&&(!k||(o.func==k||o.cfunc==k))){g.splice(n,1);h._remove(l,m,o.cfunc);i=true;return false}});return i},clear:function(l){var j=this,g=j.events,h,k;if(l){l=c.get(l);for(h=g.length-1;h>=0;h--){k=g[h];if(k.obj===l){j._remove(k.obj,k.name,k.cfunc);k.obj=k.cfunc=null;g.splice(h,1)}}}},cancel:function(g){if(!g){return false}this.stop(g);return this.prevent(g)},stop:function(g){if(g.stopPropagation){g.stopPropagation()}else{g.cancelBubble=true}return false},prevent:function(g){if(g.preventDefault){g.preventDefault()}else{g.returnValue=false}return false},_unload:function(){var g=a;f(g.events,function(j,h){g._remove(j.obj,j.name,j.cfunc);j.obj=j.cfunc=null});g.events=[];g=null},_add:function(h,i,g){if(h.attachEvent){h.attachEvent("on"+i,g)}else{if(h.addEventListener){h.addEventListener(i,g,false)}else{h["on"+i]=g}}},_remove:function(i,j,h){if(i){try{if(i.detachEvent){i.detachEvent("on"+j,h)}else{if(i.removeEventListener){i.removeEventListener(j,h,false)}else{i["on"+j]=null}}}catch(g){}}},_pageInit:function(){var g=a;if(g.domLoaded){return}g._remove(window,"DOMContentLoaded",g._pageInit);g.domLoaded=true;f(g.inits,function(h){h()});g.inits=[]},_wait:function(){if(window.tinyMCE_GZ&&tinyMCE_GZ.loaded){a.domLoaded=1;return}if(document.attachEvent){document.attachEvent("onreadystatechange",function(){if(document.readyState==="complete"){document.detachEvent("onreadystatechange",arguments.callee);a._pageInit()}});if(document.documentElement.doScroll&&window==window.top){(function(){if(a.domLoaded){return}try{document.documentElement.doScroll("left")}catch(g){setTimeout(arguments.callee,0);return}a._pageInit()})()}}else{if(document.addEventListener){a._add(window,"DOMContentLoaded",a._pageInit,a)}}a._add(window,"load",a._pageInit,a)}});a=d.dom.Event;a._wait();d.addUnload(a._unload)})(tinymce);(function(a){var b=a.each;a.create("tinymce.dom.Element",{Element:function(g,e){var c=this,f,d;e=e||{};c.id=g;c.dom=f=e.dom||a.DOM;c.settings=e;if(!a.isIE){d=c.dom.get(c.id)}b(["getPos","getRect","getParent","add","setStyle","getStyle","setStyles","setAttrib","setAttribs","getAttrib","addClass","removeClass","hasClass","getOuterHTML","setOuterHTML","remove","show","hide","isHidden","setHTML","get"],function(h){c[h]=function(){var j=[g],k;for(k=0;k<arguments.length;k++){j.push(arguments[k])}j=f[h].apply(f,j);c.update(h);return j}})},on:function(e,d,c){return a.dom.Event.add(this.id,e,d,c)},getXY:function(){return{x:parseInt(this.getStyle("left")),y:parseInt(this.getStyle("top"))}},getSize:function(){var c=this.dom.get(this.id);return{w:parseInt(this.getStyle("width")||c.clientWidth),h:parseInt(this.getStyle("height")||c.clientHeight)}},moveTo:function(c,d){this.setStyles({left:c,top:d})},moveBy:function(c,e){var d=this.getXY();this.moveTo(d.x+c,d.y+e)},resizeTo:function(c,d){this.setStyles({width:c,height:d})},resizeBy:function(c,e){var d=this.getSize();this.resizeTo(d.w+c,d.h+e)},update:function(d){var e=this,c,f=e.dom;if(a.isIE6&&e.settings.blocker){d=d||"";if(d.indexOf("get")===0||d.indexOf("has")===0||d.indexOf("is")===0){return}if(d=="remove"){f.remove(e.blocker);return}if(!e.blocker){e.blocker=f.uniqueId();c=f.add(e.settings.container||f.getRoot(),"iframe",{id:e.blocker,style:"position:absolute;",frameBorder:0,src:'javascript:""'});f.setStyle(c,"opacity",0)}else{c=f.get(e.blocker)}f.setStyle(c,"left",e.getStyle("left",1));f.setStyle(c,"top",e.getStyle("top",1));f.setStyle(c,"width",e.getStyle("width",1));f.setStyle(c,"height",e.getStyle("height",1));f.setStyle(c,"display",e.getStyle("display",1));f.setStyle(c,"zIndex",parseInt(e.getStyle("zIndex",1)||0)-1)}}})})(tinymce);(function(c){function e(f){return f.replace(/[\n\r]+/g,"")}var b=c.is,a=c.isIE,d=c.each;c.create("tinymce.dom.Selection",{Selection:function(i,h,g){var f=this;f.dom=i;f.win=h;f.serializer=g;d(["onBeforeSetContent","onBeforeGetContent","onSetContent","onGetContent"],function(j){f[j]=new c.util.Dispatcher(f)});if(!f.win.getSelection){f.tridentSel=new c.dom.TridentSelection(f)}c.addUnload(f.destroy,f)},getContent:function(g){var f=this,h=f.getRng(),l=f.dom.create("body"),j=f.getSel(),i,k,m;g=g||{};i=k="";g.get=true;g.format=g.format||"html";f.onBeforeGetContent.dispatch(f,g);if(g.format=="text"){return f.isCollapsed()?"":(h.text||(j.toString?j.toString():""))}if(h.cloneContents){m=h.cloneContents();if(m){l.appendChild(m)}}else{if(b(h.item)||b(h.htmlText)){l.innerHTML=h.item?h.item(0).outerHTML:h.htmlText}else{l.innerHTML=h.toString()}}if(/^\s/.test(l.innerHTML)){i=" "}if(/\s+$/.test(l.innerHTML)){k=" "}g.getInner=true;g.content=f.isCollapsed()?"":i+f.serializer.serialize(l,g)+k;f.onGetContent.dispatch(f,g);return g.content},setContent:function(i,g){var f=this,j=f.getRng(),l,k=f.win.document;g=g||{format:"html"};g.set=true;i=g.content=f.dom.processHTML(i);f.onBeforeSetContent.dispatch(f,g);i=g.content;if(j.insertNode){i+='<span id="__caret">_</span>';j.deleteContents();j.insertNode(f.getRng().createContextualFragment(i));l=f.dom.get("__caret");j=k.createRange();j.setStartBefore(l);j.setEndAfter(l);f.setRng(j);f.dom.remove("__caret")}else{if(j.item){k.execCommand("Delete",false,null);j=f.getRng()}j.pasteHTML(i)}f.onSetContent.dispatch(f,g)},getStart:function(){var f=this,g=f.getRng(),h;if(a){if(g.item){return g.item(0)}g=g.duplicate();g.collapse(1);h=g.parentElement();if(h&&h.nodeName=="BODY"){return h.firstChild}return h}else{h=g.startContainer;if(h.nodeName=="BODY"){return h.firstChild}return f.dom.getParent(h,"*")}},getEnd:function(){var f=this,g=f.getRng(),h;if(a){if(g.item){return g.item(0)}g=g.duplicate();g.collapse(0);h=g.parentElement();if(h&&h.nodeName=="BODY"){return h.lastChild}return h}else{h=g.endContainer;if(h.nodeName=="BODY"){return h.lastChild}return f.dom.getParent(h,"*")}},getBookmark:function(x){var j=this,m=j.getRng(),f,n,l,u=j.dom.getViewPort(j.win),v,p,z,o,w=-16777215,k,h=j.dom.getRoot(),g=0,i=0,y;n=u.x;l=u.y;if(x=="simple"){return{rng:m,scrollX:n,scrollY:l}}if(a){if(m.item){v=m.item(0);d(j.dom.select(v.nodeName),function(s,r){if(v==s){p=r;return false}});return{tag:v.nodeName,index:p,scrollX:n,scrollY:l}}f=j.dom.doc.body.createTextRange();f.moveToElementText(h);f.collapse(true);z=Math.abs(f.move("character",w));f=m.duplicate();f.collapse(true);p=Math.abs(f.move("character",w));f=m.duplicate();f.collapse(false);o=Math.abs(f.move("character",w))-p;return{start:p-z,length:o,scrollX:n,scrollY:l}}v=j.getNode();k=j.getSel();if(!k){return null}if(v&&v.nodeName=="IMG"){return{scrollX:n,scrollY:l}}function q(A,D,t){var s=j.dom.doc.createTreeWalker(A,NodeFilter.SHOW_TEXT,null,false),E,B=0,C={};while((E=s.nextNode())!=null){if(E==D){C.start=B}if(E==t){C.end=B;return C}B+=e(E.nodeValue||"").length}return null}if(k.anchorNode==k.focusNode&&k.anchorOffset==k.focusOffset){v=q(h,k.anchorNode,k.focusNode);if(!v){return{scrollX:n,scrollY:l}}e(k.anchorNode.nodeValue||"").replace(/^\s+/,function(r){g=r.length});return{start:Math.max(v.start+k.anchorOffset-g,0),end:Math.max(v.end+k.focusOffset-g,0),scrollX:n,scrollY:l,beg:k.anchorOffset-g==0}}else{v=q(h,m.startContainer,m.endContainer);if(!v){return{scrollX:n,scrollY:l}}return{start:Math.max(v.start+m.startOffset-g,0),end:Math.max(v.end+m.endOffset-i,0),scrollX:n,scrollY:l,beg:m.startOffset-g==0}}},moveToBookmark:function(n){var o=this,g=o.getRng(),p=o.getSel(),j=o.dom.getRoot(),m,h,k;function i(q,t,D){var B=o.dom.doc.createTreeWalker(q,NodeFilter.SHOW_TEXT,null,false),x,s=0,A={},u,C,z,y;while((x=B.nextNode())!=null){z=y=0;k=x.nodeValue||"";h=e(k).length;s+=h;if(s>=t&&!A.startNode){u=t-(s-h);if(n.beg&&u>=h){continue}A.startNode=x;A.startOffset=u+y}if(s>=D){A.endNode=x;A.endOffset=D-(s-h)+y;return A}}return null}if(!n){return false}o.win.scrollTo(n.scrollX,n.scrollY);if(a){if(g=n.rng){try{g.select()}catch(l){}return true}o.win.focus();if(n.tag){g=j.createControlRange();d(o.dom.select(n.tag),function(r,q){if(q==n.index){g.addElement(r)}})}else{try{if(n.start<0){return true}g=p.createRange();g.moveToElementText(j);g.collapse(true);g.moveStart("character",n.start);g.moveEnd("character",n.length)}catch(f){return true}}try{g.select()}catch(l){}return true}if(!p){return false}if(n.rng){p.removeAllRanges();p.addRange(n.rng)}else{if(b(n.start)&&b(n.end)){try{m=i(j,n.start,n.end);if(m){g=o.dom.doc.createRange();g.setStart(m.startNode,m.startOffset);g.setEnd(m.endNode,m.endOffset);p.removeAllRanges();p.addRange(g)}if(!c.isOpera){o.win.focus()}}catch(l){}}}},select:function(g,l){var p=this,f=p.getRng(),q=p.getSel(),o,m,k,j=p.win.document;function h(u,t){var s,r;if(u){s=j.createTreeWalker(u,NodeFilter.SHOW_TEXT,null,false);while(u=s.nextNode()){r=u;if(c.trim(u.nodeValue).length!=0){if(t){return u}else{r=u}}}}return r}if(a){try{o=j.body;if(/^(IMG|TABLE)$/.test(g.nodeName)){f=o.createControlRange();f.addElement(g)}else{f=o.createTextRange();f.moveToElementText(g)}f.select()}catch(i){}}else{if(l){m=h(g,1)||p.dom.select("br:first",g)[0];k=h(g,0)||p.dom.select("br:last",g)[0];if(m&&k){f=j.createRange();if(m.nodeName=="BR"){f.setStartBefore(m)}else{f.setStart(m,0)}if(k.nodeName=="BR"){f.setEndBefore(k)}else{f.setEnd(k,k.nodeValue.length)}}else{f.selectNode(g)}}else{f.selectNode(g)}p.setRng(f)}return g},isCollapsed:function(){var f=this,h=f.getRng(),g=f.getSel();if(!h||h.item){return false}return !g||h.boundingWidth==0||h.collapsed},collapse:function(f){var g=this,h=g.getRng(),i;if(h.item){i=h.item(0);h=this.win.document.body.createTextRange();h.moveToElementText(i)}h.collapse(!!f);g.setRng(h)},getSel:function(){var g=this,f=this.win;return f.getSelection?f.getSelection():f.document.selection},getRng:function(j){var g=this,h,i;if(j&&g.tridentSel){return g.tridentSel.getRangeAt(0)}try{if(h=g.getSel()){i=h.rangeCount>0?h.getRangeAt(0):(h.createRange?h.createRange():g.win.document.createRange())}}catch(f){}if(!i){i=a?g.win.document.body.createTextRange():g.win.document.createRange()}return i},setRng:function(i){var h,g=this;if(!g.tridentSel){h=g.getSel();if(h){h.removeAllRanges();h.addRange(i)}}else{if(i.cloneRange){g.tridentSel.addRange(i);return}try{i.select()}catch(f){}}},setNode:function(g){var f=this;f.setContent(f.dom.getOuterHTML(g));return g},getNode:function(){var f=this,h=f.getRng(),g=f.getSel(),i;if(!a){if(!h){return f.dom.getRoot()}i=h.commonAncestorContainer;if(!h.collapsed){if(c.isWebKit&&g.anchorNode&&g.anchorNode.nodeType==1){return g.anchorNode.childNodes[g.anchorOffset]}if(h.startContainer==h.endContainer){if(h.startOffset-h.endOffset<2){if(h.startContainer.hasChildNodes()){i=h.startContainer.childNodes[h.startOffset]}}}}return f.dom.getParent(i,"*")}return h.item?h.item(0):h.parentElement()},getSelectedBlocks:function(g,f){var i=this,j=i.dom,m,h,l,k=[];m=j.getParent(g||i.getStart(),j.isBlock);h=j.getParent(f||i.getEnd(),j.isBlock);if(m){k.push(m)}if(m&&h&&m!=h){l=m;while((l=l.nextSibling)&&l!=h){if(j.isBlock(l)){k.push(l)}}}if(h&&m!=h){k.push(h)}return k},destroy:function(g){var f=this;f.win=null;if(f.tridentSel){f.tridentSel.destroy()}if(!g){c.removeUnload(f.destroy)}}})})(tinymce);(function(a){a.create("tinymce.dom.XMLWriter",{node:null,XMLWriter:function(c){function b(){var e=document.implementation;if(!e||!e.createDocument){try{return new ActiveXObject("MSXML2.DOMDocument")}catch(d){}try{return new ActiveXObject("Microsoft.XmlDom")}catch(d){}}else{return e.createDocument("","",null)}}this.doc=b();this.valid=a.isOpera||a.isWebKit;this.reset()},reset:function(){var b=this,c=b.doc;if(c.firstChild){c.removeChild(c.firstChild)}b.node=c.appendChild(c.createElement("html"))},writeStartElement:function(c){var b=this;b.node=b.node.appendChild(b.doc.createElement(c))},writeAttribute:function(c,b){if(this.valid){b=b.replace(/>/g,"%MCGT%")}this.node.setAttribute(c,b)},writeEndElement:function(){this.node=this.node.parentNode},writeFullEndElement:function(){var b=this,c=b.node;c.appendChild(b.doc.createTextNode(""));b.node=c.parentNode},writeText:function(b){if(this.valid){b=b.replace(/>/g,"%MCGT%")}this.node.appendChild(this.doc.createTextNode(b))},writeCDATA:function(b){this.node.appendChild(this.doc.createCDATA(b))},writeComment:function(b){if(a.isIE){b=b.replace(/^\-|\-$/g," ")}this.node.appendChild(this.doc.createComment(b.replace(/\-\-/g," ")))},getContent:function(){var b;b=this.doc.xml||new XMLSerializer().serializeToString(this.doc);b=b.replace(/<\?[^?]+\?>|<html>|<\/html>|<html\/>|<!DOCTYPE[^>]+>/g,"");b=b.replace(/ ?\/>/g," />");if(this.valid){b=b.replace(/\%MCGT%/g,"&gt;")}return b}})})(tinymce);(function(a){a.create("tinymce.dom.StringWriter",{str:null,tags:null,count:0,settings:null,indent:null,StringWriter:function(b){this.settings=a.extend({indent_char:" ",indentation:1},b);this.reset()},reset:function(){this.indent="";this.str="";this.tags=[];this.count=0},writeStartElement:function(b){this._writeAttributesEnd();this.writeRaw("<"+b);this.tags.push(b);this.inAttr=true;this.count++;this.elementCount=this.count},writeAttribute:function(d,b){var c=this;c.writeRaw(" "+c.encode(d)+'="'+c.encode(b)+'"')},writeEndElement:function(){var b;if(this.tags.length>0){b=this.tags.pop();if(this._writeAttributesEnd(1)){this.writeRaw("</"+b+">")}if(this.settings.indentation>0){this.writeRaw("\n")}}},writeFullEndElement:function(){if(this.tags.length>0){this._writeAttributesEnd();this.writeRaw("</"+this.tags.pop()+">");if(this.settings.indentation>0){this.writeRaw("\n")}}},writeText:function(b){this._writeAttributesEnd();this.writeRaw(this.encode(b));this.count++},writeCDATA:function(b){this._writeAttributesEnd();this.writeRaw("<![CDATA["+b+"]]>");this.count++},writeComment:function(b){this._writeAttributesEnd();this.writeRaw("<!-- "+b+"-->");this.count++},writeRaw:function(b){this.str+=b},encode:function(b){return b.replace(/[<>&"]/g,function(c){switch(c){case"<":return"&lt;";case">":return"&gt;";case"&":return"&amp;";case'"':return"&quot;"}return c})},getContent:function(){return this.str},_writeAttributesEnd:function(b){if(!this.inAttr){return}this.inAttr=false;if(b&&this.elementCount==this.count){this.writeRaw(" />");return false}this.writeRaw(">");return true}})})(tinymce);(function(e){var g=e.extend,f=e.each,b=e.util.Dispatcher,d=e.isIE,a=e.isGecko;function c(h){return h.replace(/([?+*])/g,".$1")}e.create("tinymce.dom.Serializer",{Serializer:function(j){var i=this;i.key=0;i.onPreProcess=new b(i);i.onPostProcess=new b(i);try{i.writer=new e.dom.XMLWriter()}catch(h){i.writer=new e.dom.StringWriter()}i.settings=j=g({dom:e.DOM,valid_nodes:0,node_filter:0,attr_filter:0,invalid_attrs:/^(mce_|_moz_)/,closed:/^(br|hr|input|meta|img|link|param|area)$/,entity_encoding:"named",entities:"160,nbsp,161,iexcl,162,cent,163,pound,164,curren,165,yen,166,brvbar,167,sect,168,uml,169,copy,170,ordf,171,laquo,172,not,173,shy,174,reg,175,macr,176,deg,177,plusmn,178,sup2,179,sup3,180,acute,181,micro,182,para,183,middot,184,cedil,185,sup1,186,ordm,187,raquo,188,frac14,189,frac12,190,frac34,191,iquest,192,Agrave,193,Aacute,194,Acirc,195,Atilde,196,Auml,197,Aring,198,AElig,199,Ccedil,200,Egrave,201,Eacute,202,Ecirc,203,Euml,204,Igrave,205,Iacute,206,Icirc,207,Iuml,208,ETH,209,Ntilde,210,Ograve,211,Oacute,212,Ocirc,213,Otilde,214,Ouml,215,times,216,Oslash,217,Ugrave,218,Uacute,219,Ucirc,220,Uuml,221,Yacute,222,THORN,223,szlig,224,agrave,225,aacute,226,acirc,227,atilde,228,auml,229,aring,230,aelig,231,ccedil,232,egrave,233,eacute,234,ecirc,235,euml,236,igrave,237,iacute,238,icirc,239,iuml,240,eth,241,ntilde,242,ograve,243,oacute,244,ocirc,245,otilde,246,ouml,247,divide,248,oslash,249,ugrave,250,uacute,251,ucirc,252,uuml,253,yacute,254,thorn,255,yuml,402,fnof,913,Alpha,914,Beta,915,Gamma,916,Delta,917,Epsilon,918,Zeta,919,Eta,920,Theta,921,Iota,922,Kappa,923,Lambda,924,Mu,925,Nu,926,Xi,927,Omicron,928,Pi,929,Rho,931,Sigma,932,Tau,933,Upsilon,934,Phi,935,Chi,936,Psi,937,Omega,945,alpha,946,beta,947,gamma,948,delta,949,epsilon,950,zeta,951,eta,952,theta,953,iota,954,kappa,955,lambda,956,mu,957,nu,958,xi,959,omicron,960,pi,961,rho,962,sigmaf,963,sigma,964,tau,965,upsilon,966,phi,967,chi,968,psi,969,omega,977,thetasym,978,upsih,982,piv,8226,bull,8230,hellip,8242,prime,8243,Prime,8254,oline,8260,frasl,8472,weierp,8465,image,8476,real,8482,trade,8501,alefsym,8592,larr,8593,uarr,8594,rarr,8595,darr,8596,harr,8629,crarr,8656,lArr,8657,uArr,8658,rArr,8659,dArr,8660,hArr,8704,forall,8706,part,8707,exist,8709,empty,8711,nabla,8712,isin,8713,notin,8715,ni,8719,prod,8721,sum,8722,minus,8727,lowast,8730,radic,8733,prop,8734,infin,8736,ang,8743,and,8744,or,8745,cap,8746,cup,8747,int,8756,there4,8764,sim,8773,cong,8776,asymp,8800,ne,8801,equiv,8804,le,8805,ge,8834,sub,8835,sup,8836,nsub,8838,sube,8839,supe,8853,oplus,8855,otimes,8869,perp,8901,sdot,8968,lceil,8969,rceil,8970,lfloor,8971,rfloor,9001,lang,9002,rang,9674,loz,9824,spades,9827,clubs,9829,hearts,9830,diams,338,OElig,339,oelig,352,Scaron,353,scaron,376,Yuml,710,circ,732,tilde,8194,ensp,8195,emsp,8201,thinsp,8204,zwnj,8205,zwj,8206,lrm,8207,rlm,8211,ndash,8212,mdash,8216,lsquo,8217,rsquo,8218,sbquo,8220,ldquo,8221,rdquo,8222,bdquo,8224,dagger,8225,Dagger,8240,permil,8249,lsaquo,8250,rsaquo,8364,euro",bool_attrs:/(checked|disabled|readonly|selected|nowrap)/,valid_elements:"*[*]",extended_valid_elements:0,valid_child_elements:0,invalid_elements:0,fix_table_elements:1,fix_list_elements:true,fix_content_duplication:true,convert_fonts_to_spans:false,font_size_classes:0,font_size_style_values:0,apply_source_formatting:0,indent_mode:"simple",indent_char:"\t",indent_levels:1,remove_linebreaks:1,remove_redundant_brs:1,element_format:"xhtml"},j);i.dom=j.dom;if(j.remove_redundant_brs){i.onPostProcess.add(function(k,l){l.content=l.content.replace(/(<br \/>\s*)+<\/(p|h[1-6]|div|li)>/gi,function(n,m,o){if(/^<br \/>\s*<\//.test(n)){return"</"+o+">"}return n})})}if(j.element_format=="html"){i.onPostProcess.add(function(k,l){l.content=l.content.replace(/<([^>]+) \/>/g,"<$1>")})}if(j.fix_list_elements){i.onPreProcess.add(function(v,s){var l,y,w=["ol","ul"],u,t,q,k=/^(OL|UL)$/,z;function m(r,x){var o=x.split(","),p;while((r=r.previousSibling)!=null){for(p=0;p<o.length;p++){if(r.nodeName==o[p]){return r}}}return null}for(y=0;y<w.length;y++){l=i.dom.select(w[y],s.node);for(u=0;u<l.length;u++){t=l[u];q=t.parentNode;if(k.test(q.nodeName)){z=m(t,"LI");if(!z){z=i.dom.create("li");z.innerHTML="&nbsp;";z.appendChild(t);q.insertBefore(z,q.firstChild)}else{z.appendChild(t)}}}}})}if(j.fix_table_elements){i.onPreProcess.add(function(k,l){f(i.dom.select("p table",l.node),function(m){i.dom.split(i.dom.getParent(m,"p"),m)})})}},setEntities:function(p){var n=this,j,m,h={},o="",k;if(n.entityLookup){return}j=p.split(",");for(m=0;m<j.length;m+=2){k=j[m];if(k==34||k==38||k==60||k==62){continue}h[String.fromCharCode(j[m])]=j[m+1];k=parseInt(j[m]).toString(16);o+="\\u"+"0000".substring(k.length)+k}if(!o){n.settings.entity_encoding="raw";return}n.entitiesRE=new RegExp("["+o+"]","g");n.entityLookup=h},setValidChildRules:function(h){this.childRules=null;this.addValidChildRules(h)},addValidChildRules:function(k){var j=this,l,h,i;if(!k){return}l="A|BR|SPAN|BDO|MAP|OBJECT|IMG|TT|I|B|BIG|SMALL|EM|STRONG|DFN|CODE|Q|SAMP|KBD|VAR|CITE|ABBR|ACRONYM|SUB|SUP|#text|#comment";h="A|BR|SPAN|BDO|OBJECT|APPLET|IMG|MAP|IFRAME|TT|I|B|U|S|STRIKE|BIG|SMALL|FONT|BASEFONT|EM|STRONG|DFN|CODE|Q|SAMP|KBD|VAR|CITE|ABBR|ACRONYM|SUB|SUP|INPUT|SELECT|TEXTAREA|LABEL|BUTTON|#text|#comment";i="H[1-6]|P|DIV|ADDRESS|PRE|FORM|TABLE|LI|OL|UL|TD|CAPTION|BLOCKQUOTE|CENTER|DL|DT|DD|DIR|FIELDSET|FORM|NOSCRIPT|NOFRAMES|MENU|ISINDEX|SAMP";f(k.split(","),function(n){var o=n.split(/\[|\]/),m;n="";f(o[1].split("|"),function(p){if(n){n+="|"}switch(p){case"%itrans":p=h;break;case"%itrans_na":p=h.substring(2);break;case"%istrict":p=l;break;case"%istrict_na":p=l.substring(2);break;case"%btrans":p=i;break;case"%bstrict":p=i;break}n+=p});m=new RegExp("^("+n.toLowerCase()+")$","i");f(o[0].split("/"),function(p){j.childRules=j.childRules||{};j.childRules[p]=m})});k="";f(j.childRules,function(n,m){if(k){k+="|"}k+=m});j.parentElementsRE=new RegExp("^("+k.toLowerCase()+")$","i")},setRules:function(i){var h=this;h._setup();h.rules={};h.wildRules=[];h.validElements={};return h.addRules(i)},addRules:function(i){var h=this,j;if(!i){return}h._setup();f(i.split(","),function(m){var q=m.split(/\[|\]/),l=q[0].split("/"),r,k,o,n=[];if(j){k=e.extend([],j.attribs)}if(q.length>1){f(q[1].split("|"),function(u){var p={},t;k=k||[];u=u.replace(/::/g,"~");u=/^([!\-])?([\w*.?~_\-]+|)([=:<])?(.+)?$/.exec(u);u[2]=u[2].replace(/~/g,":");if(u[1]=="!"){r=r||[];r.push(u[2])}if(u[1]=="-"){for(t=0;t<k.length;t++){if(k[t].name==u[2]){k.splice(t,1);return}}}switch(u[3]){case"=":p.defaultVal=u[4]||"";break;case":":p.forcedVal=u[4];break;case"<":p.validVals=u[4].split("?");break}if(/[*.?]/.test(u[2])){o=o||[];p.nameRE=new RegExp("^"+c(u[2])+"$");o.push(p)}else{p.name=u[2];k.push(p)}n.push(u[2])})}f(l,function(v,u){var w=v.charAt(0),t=1,p={};if(j){if(j.noEmpty){p.noEmpty=j.noEmpty}if(j.fullEnd){p.fullEnd=j.fullEnd}if(j.padd){p.padd=j.padd}}switch(w){case"-":p.noEmpty=true;break;case"+":p.fullEnd=true;break;case"#":p.padd=true;break;default:t=0}l[u]=v=v.substring(t);h.validElements[v]=1;if(/[*.?]/.test(l[0])){p.nameRE=new RegExp("^"+c(l[0])+"$");h.wildRules=h.wildRules||{};h.wildRules.push(p)}else{p.name=l[0];if(l[0]=="@"){j=p}h.rules[v]=p}p.attribs=k;if(r){p.requiredAttribs=r}if(o){v="";f(n,function(s){if(v){v+="|"}v+="("+c(s)+")"});p.validAttribsRE=new RegExp("^"+v.toLowerCase()+"$");p.wildAttribs=o}})});i="";f(h.validElements,function(m,l){if(i){i+="|"}if(l!="@"){i+=l}});h.validElementsRE=new RegExp("^("+c(i.toLowerCase())+")$")},findRule:function(m){var j=this,l=j.rules,h,k;j._setup();k=l[m];if(k){return k}l=j.wildRules;for(h=0;h<l.length;h++){if(l[h].nameRE.test(m)){return l[h]}}return null},findAttribRule:function(h,l){var j,k=h.wildAttribs;for(j=0;j<k.length;j++){if(k[j].nameRE.test(l)){return k[j]}}return null},serialize:function(l,k){var j,i=this;i._setup();k=k||{};k.format=k.format||"html";i.processObj=k;l=l.cloneNode(true);i.key=""+(parseInt(i.key)+1);if(!k.no_events){k.node=l;i.onPreProcess.dispatch(i,k)}i.writer.reset();i._serializeNode(l,k.getInner);k.content=i.writer.getContent();if(!k.no_events){i.onPostProcess.dispatch(i,k)}i._postProcess(k);k.node=null;return e.trim(k.content)},_postProcess:function(n){var i=this,k=i.settings,j=n.content,m=[],l;if(n.format=="html"){l=i._protect({content:j,patterns:[{pattern:/(<script[^>]*>)(.*?)(<\/script>)/g},{pattern:/(<style[^>]*>)(.*?)(<\/style>)/g},{pattern:/(<pre[^>]*>)(.*?)(<\/pre>)/g,encode:1},{pattern:/(<!--\[CDATA\[)(.*?)(\]\]-->)/g}]});j=l.content;if(k.entity_encoding!=="raw"){j=i._encode(j)}if(!n.set){j=j.replace(/<p>\s+<\/p>|<p([^>]+)>\s+<\/p>/g,k.entity_encoding=="numeric"?"<p$1>&#160;</p>":"<p$1>&nbsp;</p>");if(k.remove_linebreaks){j=j.replace(/\r?\n|\r/g," ");j=j.replace(/(<[^>]+>)\s+/g,"$1 ");j=j.replace(/\s+(<\/[^>]+>)/g," $1");j=j.replace(/<(p|h[1-6]|blockquote|hr|div|table|tbody|tr|td|body|head|html|title|meta|style|pre|script|link|object) ([^>]+)>\s+/g,"<$1 $2>");j=j.replace(/<(p|h[1-6]|blockquote|hr|div|table|tbody|tr|td|body|head|html|title|meta|style|pre|script|link|object)>\s+/g,"<$1>");j=j.replace(/\s+<\/(p|h[1-6]|blockquote|hr|div|table|tbody|tr|td|body|head|html|title|meta|style|pre|script|link|object)>/g,"</$1>")}if(k.apply_source_formatting&&k.indent_mode=="simple"){j=j.replace(/<(\/?)(ul|hr|table|meta|link|tbody|tr|object|body|head|html|map)(|[^>]+)>\s*/g,"\n<$1$2$3>\n");j=j.replace(/\s*<(p|h[1-6]|blockquote|div|title|style|pre|script|td|li|area)(|[^>]+)>/g,"\n<$1$2>");j=j.replace(/<\/(p|h[1-6]|blockquote|div|title|style|pre|script|td|li)>\s*/g,"</$1>\n");j=j.replace(/\n\n/g,"\n")}}j=i._unprotect(j,l);j=j.replace(/<!--\[CDATA\[([\s\S]+)\]\]-->/g,"<![CDATA[$1]]>");if(k.entity_encoding=="raw"){j=j.replace(/<p>&nbsp;<\/p>|<p([^>]+)>&nbsp;<\/p>/g,"<p$1>\u00a0</p>")}}n.content=j},_serializeNode:function(C,m){var y=this,z=y.settings,u=y.writer,p,j,r,E,D,F,A,h,x,k,q,B,o;if(!z.node_filter||z.node_filter(C)){switch(C.nodeType){case 1:if(C.hasAttribute?C.hasAttribute("mce_bogus"):C.getAttribute("mce_bogus")){return}o=false;p=C.hasChildNodes();k=C.getAttribute("mce_name")||C.nodeName.toLowerCase();if(d){if(C.scopeName!=="HTML"&&C.scopeName!=="html"){k=C.scopeName+":"+k}}if(k.indexOf("mce:")===0){k=k.substring(4)}if(!y.validElementsRE.test(k)||(y.invalidElementsRE&&y.invalidElementsRE.test(k))||m){o=true;break}if(d){if(z.fix_content_duplication){if(C.mce_serialized==y.key){return}C.mce_serialized=y.key}if(k.charAt(0)=="/"){k=k.substring(1)}}else{if(a){if(C.nodeName==="BR"&&C.getAttribute("type")=="_moz"){return}}}if(y.childRules){if(y.parentElementsRE.test(y.elementName)){if(!y.childRules[y.elementName].test(k)){o=true;break}}y.elementName=k}q=y.findRule(k);k=q.name||k;if((!p&&q.noEmpty)||(d&&!k)){o=true;break}if(q.requiredAttribs){F=q.requiredAttribs;for(E=F.length-1;E>=0;E--){if(this.dom.getAttrib(C,F[E])!==""){break}}if(E==-1){o=true;break}}u.writeStartElement(k);if(q.attribs){for(E=0,A=q.attribs,D=A.length;E<D;E++){F=A[E];x=y._getAttrib(C,F);if(x!==null){u.writeAttribute(F.name,x)}}}if(q.validAttribsRE){A=y.dom.getAttribs(C);for(E=A.length-1;E>-1;E--){h=A[E];if(h.specified){F=h.nodeName.toLowerCase();if(z.invalid_attrs.test(F)||!q.validAttribsRE.test(F)){continue}B=y.findAttribRule(q,F);x=y._getAttrib(C,B,F);if(x!==null){u.writeAttribute(F,x)}}}}if(q.padd){if(p&&(r=C.firstChild)&&r.nodeType===1&&C.childNodes.length===1){if(r.hasAttribute?r.hasAttribute("mce_bogus"):r.getAttribute("mce_bogus")){u.writeText("\u00a0")}}else{if(!p){u.writeText("\u00a0")}}}break;case 3:if(y.childRules&&y.parentElementsRE.test(y.elementName)){if(!y.childRules[y.elementName].test(C.nodeName)){return}}return u.writeText(C.nodeValue);case 4:return u.writeCDATA(C.nodeValue);case 8:return u.writeComment(C.nodeValue)}}else{if(C.nodeType==1){p=C.hasChildNodes()}}if(p){r=C.firstChild;while(r){y._serializeNode(r);y.elementName=k;r=r.nextSibling}}if(!o){if(p||!z.closed.test(k)){u.writeFullEndElement()}else{u.writeEndElement()}}},_protect:function(j){var i=this;j.items=j.items||[];function h(l){return l.replace(/[\r\n\\]/g,function(m){if(m==="\n"){return"\\n"}else{if(m==="\\"){return"\\\\"}}return"\\r"})}function k(l){return l.replace(/\\[\\rn]/g,function(m){if(m==="\\n"){return"\n"}else{if(m==="\\\\"){return"\\"}}return"\r"})}f(j.patterns,function(l){j.content=k(h(j.content).replace(l.pattern,function(n,o,m,p){m=k(m);if(l.encode){m=i._encode(m)}j.items.push(m);return o+"<!--mce:"+(j.items.length-1)+"-->"+p}))});return j},_unprotect:function(i,j){i=i.replace(/\<!--mce:([0-9]+)--\>/g,function(k,h){return j.items[parseInt(h)]});j.items=[];return i},_encode:function(m){var j=this,k=j.settings,i;if(k.entity_encoding!=="raw"){if(k.entity_encoding.indexOf("named")!=-1){j.setEntities(k.entities);i=j.entityLookup;m=m.replace(j.entitiesRE,function(h){var l;if(l=i[h]){h="&"+l+";"}return h})}if(k.entity_encoding.indexOf("numeric")!=-1){m=m.replace(/[\u007E-\uFFFF]/g,function(h){return"&#"+h.charCodeAt(0)+";"})}}return m},_setup:function(){var h=this,i=this.settings;if(h.done){return}h.done=1;h.setRules(i.valid_elements);h.addRules(i.extended_valid_elements);h.addValidChildRules(i.valid_child_elements);if(i.invalid_elements){h.invalidElementsRE=new RegExp("^("+c(i.invalid_elements.replace(/,/g,"|").toLowerCase())+")$")}if(i.attrib_value_filter){h.attribValueFilter=i.attribValueFilter}},_getAttrib:function(m,j,h){var l,k;h=h||j.name;if(j.forcedVal&&(k=j.forcedVal)){if(k==="{$uid}"){return this.dom.uniqueId()}return k}k=this.dom.getAttrib(m,h);if(this.settings.bool_attrs.test(h)&&k){k=(""+k).toLowerCase();if(k==="false"||k==="0"){return null}k=h}switch(h){case"rowspan":case"colspan":if(k=="1"){k=""}break}if(this.attribValueFilter){k=this.attribValueFilter(h,k,m)}if(j.validVals){for(l=j.validVals.length-1;l>=0;l--){if(k==j.validVals[l]){break}}if(l==-1){return null}}if(k===""&&typeof(j.defaultVal)!="undefined"){k=j.defaultVal;if(k==="{$uid}"){return this.dom.uniqueId()}return k}else{if(h=="class"&&this.processObj.get){k=k.replace(/\s?mceItem\w+\s?/g,"")}}if(k===""){return null}return k}})})(tinymce);(function(tinymce){var each=tinymce.each,Event=tinymce.dom.Event;tinymce.create("tinymce.dom.ScriptLoader",{ScriptLoader:function(s){this.settings=s||{};this.queue=[];this.lookup={}},isDone:function(u){return this.lookup[u]?this.lookup[u].state==2:0},markDone:function(u){this.lookup[u]={state:2,url:u}},add:function(u,cb,s,pr){var t=this,lo=t.lookup,o;if(o=lo[u]){if(cb&&o.state==2){cb.call(s||this)}return o}o={state:0,url:u,func:cb,scope:s||this};if(pr){t.queue.unshift(o)}else{t.queue.push(o)}lo[u]=o;return o},load:function(u,cb,s){var t=this,o;if(o=t.lookup[u]){if(cb&&o.state==2){cb.call(s||t)}return o}function loadScript(u){if(Event.domLoaded||t.settings.strict_mode){tinymce.util.XHR.send({url:tinymce._addVer(u),error:t.settings.error,async:false,success:function(co){t.eval(co)}})}else{document.write('<script type="text/javascript" src="'+tinymce._addVer(u)+'"><\/script>')}}if(!tinymce.is(u,"string")){each(u,function(u){loadScript(u)});if(cb){cb.call(s||t)}}else{loadScript(u);if(cb){cb.call(s||t)}}},loadQueue:function(cb,s){var t=this;if(!t.queueLoading){t.queueLoading=1;t.queueCallbacks=[];t.loadScripts(t.queue,function(){t.queueLoading=0;if(cb){cb.call(s||t)}each(t.queueCallbacks,function(o){o.func.call(o.scope)})})}else{if(cb){t.queueCallbacks.push({func:cb,scope:s||t})}}},eval:function(co){var w=window;if(!w.execScript){try{eval.call(w,co)}catch(ex){eval(co,w)}}else{w.execScript(co)}},loadScripts:function(sc,cb,s){var t=this,lo=t.lookup;function done(o){o.state=2;if(o.func){o.func.call(o.scope||t)}}function allDone(){var l;l=sc.length;each(sc,function(o){o=lo[o.url];if(o.state===2){done(o);l--}else{load(o)}});if(l===0&&cb){cb.call(s||t);cb=0}}function load(o){if(o.state>0){return}o.state=1;tinymce.dom.ScriptLoader.loadScript(o.url,function(){done(o);allDone()})}each(sc,function(o){var u=o.url;if(!lo[u]){lo[u]=o;t.queue.push(o)}else{o=lo[u]}if(o.state>0){return}if(!Event.domLoaded&&!t.settings.strict_mode){var ix,ol="";if(cb||o.func){o.state=1;ix=tinymce.dom.ScriptLoader._addOnLoad(function(){done(o);allDone()});if(tinymce.isIE){ol=' onreadystatechange="'}else{ol=' onload="'}ol+="tinymce.dom.ScriptLoader._onLoad(this,'"+u+"',"+ix+');"'}document.write('<script type="text/javascript" src="'+tinymce._addVer(u)+'"'+ol+"><\/script>");if(!o.func){done(o)}}else{load(o)}});allDone()},"static":{_addOnLoad:function(f){var t=this;t._funcs=t._funcs||[];t._funcs.push(f);return t._funcs.length-1},_onLoad:function(e,u,ix){if(!tinymce.isIE||e.readyState=="complete"){this._funcs[ix].call(this)}},loadScript:function(u,cb){var id=tinymce.DOM.uniqueId(),e;function done(){Event.clear(id);tinymce.DOM.remove(id);if(cb){cb.call(document,u);cb=0}}if(tinymce.isIE){tinymce.util.XHR.send({url:tinymce._addVer(u),async:false,success:function(co){window.execScript(co);done()}})}else{e=tinymce.DOM.create("script",{id:id,type:"text/javascript",src:tinymce._addVer(u)});Event.add(e,"load",done);(document.getElementsByTagName("head")[0]||document.body).appendChild(e)}}}});tinymce.ScriptLoader=new tinymce.dom.ScriptLoader()})(tinymce);(function(c){var b=c.DOM,a=c.is;c.create("tinymce.ui.Control",{Control:function(e,d){this.id=e;this.settings=d=d||{};this.rendered=false;this.onRender=new c.util.Dispatcher(this);this.classPrefix="";this.scope=d.scope||this;this.disabled=0;this.active=0},setDisabled:function(d){var f;if(d!=this.disabled){f=b.get(this.id);if(f&&this.settings.unavailable_prefix){if(d){this.prevTitle=f.title;f.title=this.settings.unavailable_prefix+": "+f.title}else{f.title=this.prevTitle}}this.setState("Disabled",d);this.setState("Enabled",!d);this.disabled=d}},isDisabled:function(){return this.disabled},setActive:function(d){if(d!=this.active){this.setState("Active",d);this.active=d}},isActive:function(){return this.active},setState:function(f,d){var e=b.get(this.id);f=this.classPrefix+f;if(d){b.addClass(e,f)}else{b.removeClass(e,f)}},isRendered:function(){return this.rendered},renderHTML:function(){},renderTo:function(d){b.setHTML(d,this.renderHTML())},postRender:function(){var e=this,d;if(a(e.disabled)){d=e.disabled;e.disabled=-1;e.setDisabled(d)}if(a(e.active)){d=e.active;e.active=-1;e.setActive(d)}},remove:function(){b.remove(this.id);this.destroy()},destroy:function(){c.dom.Event.clear(this.id)}})})(tinymce);tinymce.create("tinymce.ui.Container:tinymce.ui.Control",{Container:function(b,a){this.parent(b,a);this.controls=[];this.lookup={}},add:function(a){this.lookup[a.id]=a;this.controls.push(a);return a},get:function(a){return this.lookup[a]}});tinymce.create("tinymce.ui.Separator:tinymce.ui.Control",{Separator:function(b,a){this.parent(b,a);this.classPrefix="mceSeparator"},renderHTML:function(){return tinymce.DOM.createHTML("span",{"class":this.classPrefix})}});(function(d){var c=d.is,b=d.DOM,e=d.each,a=d.walk;d.create("tinymce.ui.MenuItem:tinymce.ui.Control",{MenuItem:function(g,f){this.parent(g,f);this.classPrefix="mceMenuItem"},setSelected:function(f){this.setState("Selected",f);this.selected=f},isSelected:function(){return this.selected},postRender:function(){var f=this;f.parent();if(c(f.selected)){f.setSelected(f.selected)}}})})(tinymce);(function(d){var c=d.is,b=d.DOM,e=d.each,a=d.walk;d.create("tinymce.ui.Menu:tinymce.ui.MenuItem",{Menu:function(h,g){var f=this;f.parent(h,g);f.items={};f.collapsed=false;f.menuCount=0;f.onAddItem=new d.util.Dispatcher(this)},expand:function(g){var f=this;if(g){a(f,function(h){if(h.expand){h.expand()}},"items",f)}f.collapsed=false},collapse:function(g){var f=this;if(g){a(f,function(h){if(h.collapse){h.collapse()}},"items",f)}f.collapsed=true},isCollapsed:function(){return this.collapsed},add:function(f){if(!f.settings){f=new d.ui.MenuItem(f.id||b.uniqueId(),f)}this.onAddItem.dispatch(this,f);return this.items[f.id]=f},addSeparator:function(){return this.add({separator:true})},addMenu:function(f){if(!f.collapse){f=this.createMenu(f)}this.menuCount++;return this.add(f)},hasMenus:function(){return this.menuCount!==0},remove:function(f){delete this.items[f.id]},removeAll:function(){var f=this;a(f,function(g){if(g.removeAll){g.removeAll()}else{g.remove()}g.destroy()},"items",f);f.items={}},createMenu:function(g){var f=new d.ui.Menu(g.id||b.uniqueId(),g);f.onAddItem.add(this.onAddItem.dispatch,this.onAddItem);return f}})})(tinymce);(function(e){var d=e.is,c=e.DOM,f=e.each,a=e.dom.Event,b=e.dom.Element;e.create("tinymce.ui.DropMenu:tinymce.ui.Menu",{DropMenu:function(h,g){g=g||{};g.container=g.container||c.doc.body;g.offset_x=g.offset_x||0;g.offset_y=g.offset_y||0;g.vp_offset_x=g.vp_offset_x||0;g.vp_offset_y=g.vp_offset_y||0;if(d(g.icons)&&!g.icons){g["class"]+=" mceNoIcons"}this.parent(h,g);this.onShowMenu=new e.util.Dispatcher(this);this.onHideMenu=new e.util.Dispatcher(this);this.classPrefix="mceMenu"},createMenu:function(j){var h=this,i=h.settings,g;j.container=j.container||i.container;j.parent=h;j.constrain=j.constrain||i.constrain;j["class"]=j["class"]||i["class"];j.vp_offset_x=j.vp_offset_x||i.vp_offset_x;j.vp_offset_y=j.vp_offset_y||i.vp_offset_y;g=new e.ui.DropMenu(j.id||c.uniqueId(),j);g.onAddItem.add(h.onAddItem.dispatch,h.onAddItem);return g},update:function(){var i=this,j=i.settings,g=c.get("menu_"+i.id+"_tbl"),l=c.get("menu_"+i.id+"_co"),h,k;h=j.max_width?Math.min(g.clientWidth,j.max_width):g.clientWidth;k=j.max_height?Math.min(g.clientHeight,j.max_height):g.clientHeight;if(!c.boxModel){i.element.setStyles({width:h+2,height:k+2})}else{i.element.setStyles({width:h,height:k})}if(j.max_width){c.setStyle(l,"width",h)}if(j.max_height){c.setStyle(l,"height",k);if(g.clientHeight<j.max_height){c.setStyle(l,"overflow","hidden")}}},showMenu:function(p,n,r){var z=this,A=z.settings,o,g=c.getViewPort(),u,l,v,q,i=2,k,j,m=z.classPrefix;z.collapse(1);if(z.isMenuVisible){return}if(!z.rendered){o=c.add(z.settings.container,z.renderNode());f(z.items,function(h){h.postRender()});z.element=new b("menu_"+z.id,{blocker:1,container:A.container})}else{o=c.get("menu_"+z.id)}if(!e.isOpera){c.setStyles(o,{left:-65535,top:-65535})}c.show(o);z.update();p+=A.offset_x||0;n+=A.offset_y||0;g.w-=4;g.h-=4;if(A.constrain){u=o.clientWidth-i;l=o.clientHeight-i;v=g.x+g.w;q=g.y+g.h;if((p+A.vp_offset_x+u)>v){p=r?r-u:Math.max(0,(v-A.vp_offset_x)-u)}if((n+A.vp_offset_y+l)>q){n=Math.max(0,(q-A.vp_offset_y)-l)}}c.setStyles(o,{left:p,top:n});z.element.update();z.isMenuVisible=1;z.mouseClickFunc=a.add(o,"click",function(s){var h;s=s.target;if(s&&(s=c.getParent(s,"tr"))&&!c.hasClass(s,m+"ItemSub")){h=z.items[s.id];if(h.isDisabled()){return}k=z;while(k){if(k.hideMenu){k.hideMenu()}k=k.settings.parent}if(h.settings.onclick){h.settings.onclick(s)}return a.cancel(s)}});if(z.hasMenus()){z.mouseOverFunc=a.add(o,"mouseover",function(w){var h,t,s;w=w.target;if(w&&(w=c.getParent(w,"tr"))){h=z.items[w.id];if(z.lastMenu){z.lastMenu.collapse(1)}if(h.isDisabled()){return}if(w&&c.hasClass(w,m+"ItemSub")){t=c.getRect(w);h.showMenu((t.x+t.w-i),t.y-i,t.x);z.lastMenu=h;c.addClass(c.get(h.id).firstChild,m+"ItemActive")}}})}z.onShowMenu.dispatch(z);if(A.keyboard_focus){a.add(o,"keydown",z._keyHandler,z);c.select("a","menu_"+z.id)[0].focus();z._focusIdx=0}},hideMenu:function(j){var g=this,i=c.get("menu_"+g.id),h;if(!g.isMenuVisible){return}a.remove(i,"mouseover",g.mouseOverFunc);a.remove(i,"click",g.mouseClickFunc);a.remove(i,"keydown",g._keyHandler);c.hide(i);g.isMenuVisible=0;if(!j){g.collapse(1)}if(g.element){g.element.hide()}if(h=c.get(g.id)){c.removeClass(h.firstChild,g.classPrefix+"ItemActive")}g.onHideMenu.dispatch(g)},add:function(i){var g=this,h;i=g.parent(i);if(g.isRendered&&(h=c.get("menu_"+g.id))){g._add(c.select("tbody",h)[0],i)}return i},collapse:function(g){this.parent(g);this.hideMenu(1)},remove:function(g){c.remove(g.id);this.destroy();return this.parent(g)},destroy:function(){var g=this,h=c.get("menu_"+g.id);a.remove(h,"mouseover",g.mouseOverFunc);a.remove(h,"click",g.mouseClickFunc);if(g.element){g.element.remove()}c.remove(h)},renderNode:function(){var i=this,j=i.settings,l,h,k,g;g=c.create("div",{id:"menu_"+i.id,"class":j["class"],style:"position:absolute;left:0;top:0;z-index:200000"});k=c.add(g,"div",{id:"menu_"+i.id+"_co","class":i.classPrefix+(j["class"]?" "+j["class"]:"")});i.element=new b("menu_"+i.id,{blocker:1,container:j.container});if(j.menu_line){c.add(k,"span",{"class":i.classPrefix+"Line"})}l=c.add(k,"table",{id:"menu_"+i.id+"_tbl",border:0,cellPadding:0,cellSpacing:0});h=c.add(l,"tbody");f(i.items,function(m){i._add(h,m)});i.rendered=true;return g},_keyHandler:function(j){var i=this,h=j.keyCode;function g(m){var k=i._focusIdx+m,l=c.select("a","menu_"+i.id)[k];if(l){i._focusIdx=k;l.focus()}}switch(h){case 38:g(-1);return;case 40:g(1);return;case 13:return;case 27:return this.hideMenu()}},_add:function(j,h){var i,q=h.settings,p,l,k,m=this.classPrefix,g;if(q.separator){l=c.add(j,"tr",{id:h.id,"class":m+"ItemSeparator"});c.add(l,"td",{"class":m+"ItemSeparator"});if(i=l.previousSibling){c.addClass(i,"mceLast")}return}i=l=c.add(j,"tr",{id:h.id,"class":m+"Item "+m+"ItemEnabled"});i=k=c.add(i,"td");i=p=c.add(i,"a",{href:"javascript:;",onclick:"return false;",onmousedown:"return false;"});c.addClass(k,q["class"]);g=c.add(i,"span",{"class":"mceIcon"+(q.icon?" mce_"+q.icon:"")});if(q.icon_src){c.add(g,"img",{src:q.icon_src})}i=c.add(i,q.element||"span",{"class":"mceText",title:h.settings.title},h.settings.title);if(h.settings.style){c.setAttrib(i,"style",h.settings.style)}if(j.childNodes.length==1){c.addClass(l,"mceFirst")}if((i=l.previousSibling)&&c.hasClass(i,m+"ItemSeparator")){c.addClass(l,"mceFirst")}if(h.collapse){c.addClass(l,m+"ItemSub")}if(i=l.previousSibling){c.removeClass(i,"mceLast")}c.addClass(l,"mceLast")}})})(tinymce);(function(b){var a=b.DOM;b.create("tinymce.ui.Button:tinymce.ui.Control",{Button:function(d,c){this.parent(d,c);this.classPrefix="mceButton"},renderHTML:function(){var f=this.classPrefix,e=this.settings,d,c;c=a.encode(e.label||"");d='<a id="'+this.id+'" href="javascript:;" class="'+f+" "+f+"Enabled "+e["class"]+(c?" "+f+"Labeled":"")+'" onmousedown="return false;" onclick="return false;" title="'+a.encode(e.title)+'">';if(e.image){d+='<img class="mceIcon" src="'+e.image+'" />'+c+"</a>"}else{d+='<span class="mceIcon '+e["class"]+'"></span>'+(c?'<span class="'+f+'Label">'+c+"</span>":"")+"</a>"}return d},postRender:function(){var c=this,d=c.settings;b.dom.Event.add(c.id,"click",function(f){if(!c.isDisabled()){return d.onclick.call(d.scope,f)}})}})})(tinymce);(function(d){var c=d.DOM,b=d.dom.Event,e=d.each,a=d.util.Dispatcher;d.create("tinymce.ui.ListBox:tinymce.ui.Control",{ListBox:function(h,g){var f=this;f.parent(h,g);f.items=[];f.onChange=new a(f);f.onPostRender=new a(f);f.onAdd=new a(f);f.onRenderMenu=new d.util.Dispatcher(this);f.classPrefix="mceListBox"},select:function(h){var g=this,j,i;if(h==undefined){return g.selectByIndex(-1)}if(h&&h.call){i=h}else{i=function(f){return f==h}}if(h!=g.selectedValue){e(g.items,function(k,f){if(i(k.value)){j=1;g.selectByIndex(f);return false}});if(!j){g.selectByIndex(-1)}}},selectByIndex:function(f){var g=this,h,i;if(f!=g.selectedIndex){h=c.get(g.id+"_text");i=g.items[f];if(i){g.selectedValue=i.value;g.selectedIndex=f;c.setHTML(h,c.encode(i.title));c.removeClass(h,"mceTitle")}else{c.setHTML(h,c.encode(g.settings.title));c.addClass(h,"mceTitle");g.selectedValue=g.selectedIndex=null}h=0}},add:function(i,f,h){var g=this;h=h||{};h=d.extend(h,{title:i,value:f});g.items.push(h);g.onAdd.dispatch(g,h)},getLength:function(){return this.items.length},renderHTML:function(){var i="",f=this,g=f.settings,j=f.classPrefix;i='<table id="'+f.id+'" cellpadding="0" cellspacing="0" class="'+j+" "+j+"Enabled"+(g["class"]?(" "+g["class"]):"")+'"><tbody><tr>';i+="<td>"+c.createHTML("a",{id:f.id+"_text",href:"javascript:;","class":"mceText",onclick:"return false;",onmousedown:"return false;"},c.encode(f.settings.title))+"</td>";i+="<td>"+c.createHTML("a",{id:f.id+"_open",tabindex:-1,href:"javascript:;","class":"mceOpen",onclick:"return false;",onmousedown:"return false;"},"<span></span>")+"</td>";i+="</tr></tbody></table>";return i},showMenu:function(){var g=this,j,i,h=c.get(this.id),f;if(g.isDisabled()||g.items.length==0){return}if(g.menu&&g.menu.isMenuVisible){return g.hideMenu()}if(!g.isMenuRendered){g.renderMenu();g.isMenuRendered=true}j=c.getPos(this.settings.menu_container);i=c.getPos(h);f=g.menu;f.settings.offset_x=i.x;f.settings.offset_y=i.y;f.settings.keyboard_focus=!d.isOpera;if(g.oldID){f.items[g.oldID].setSelected(0)}e(g.items,function(k){if(k.value===g.selectedValue){f.items[k.id].setSelected(1);g.oldID=k.id}});f.showMenu(0,h.clientHeight);b.add(c.doc,"mousedown",g.hideMenu,g);c.addClass(g.id,g.classPrefix+"Selected")},hideMenu:function(g){var f=this;if(g&&g.type=="mousedown"&&(g.target.id==f.id+"_text"||g.target.id==f.id+"_open")){return}if(!g||!c.getParent(g.target,".mceMenu")){c.removeClass(f.id,f.classPrefix+"Selected");b.remove(c.doc,"mousedown",f.hideMenu,f);if(f.menu){f.menu.hideMenu()}}},renderMenu:function(){var g=this,f;f=g.settings.control_manager.createDropMenu(g.id+"_menu",{menu_line:1,"class":g.classPrefix+"Menu mceNoIcons",max_width:150,max_height:150});f.onHideMenu.add(g.hideMenu,g);f.add({title:g.settings.title,"class":"mceMenuItemTitle",onclick:function(){if(g.settings.onselect("")!==false){g.select("")}}});e(g.items,function(h){h.id=c.uniqueId();h.onclick=function(){if(g.settings.onselect(h.value)!==false){g.select(h.value)}};f.add(h)});g.onRenderMenu.dispatch(g,f);g.menu=f},postRender:function(){var f=this,g=f.classPrefix;b.add(f.id,"click",f.showMenu,f);b.add(f.id+"_text","focus",function(h){if(!f._focused){f.keyDownHandler=b.add(f.id+"_text","keydown",function(l){var i=-1,j,k=l.keyCode;e(f.items,function(m,n){if(f.selectedValue==m.value){i=n}});if(k==38){j=f.items[i-1]}else{if(k==40){j=f.items[i+1]}else{if(k==13){j=f.selectedValue;f.selectedValue=null;f.settings.onselect(j);return b.cancel(l)}}}if(j){f.hideMenu();f.select(j.value)}})}f._focused=1});b.add(f.id+"_text","blur",function(){b.remove(f.id+"_text","keydown",f.keyDownHandler);f._focused=0});if(d.isIE6||!c.boxModel){b.add(f.id,"mouseover",function(){if(!c.hasClass(f.id,g+"Disabled")){c.addClass(f.id,g+"Hover")}});b.add(f.id,"mouseout",function(){if(!c.hasClass(f.id,g+"Disabled")){c.removeClass(f.id,g+"Hover")}})}f.onPostRender.dispatch(f,c.get(f.id))},destroy:function(){this.parent();b.clear(this.id+"_text")}})})(tinymce);(function(d){var c=d.DOM,b=d.dom.Event,e=d.each,a=d.util.Dispatcher;d.create("tinymce.ui.NativeListBox:tinymce.ui.ListBox",{NativeListBox:function(g,f){this.parent(g,f);this.classPrefix="mceNativeListBox"},setDisabled:function(f){c.get(this.id).disabled=f},isDisabled:function(){return c.get(this.id).disabled},select:function(h){var g=this,j,i;if(h==undefined){return g.selectByIndex(-1)}if(h&&h.call){i=h}else{i=function(f){return f==h}}if(h!=g.selectedValue){e(g.items,function(k,f){if(i(k.value)){j=1;g.selectByIndex(f);return false}});if(!j){g.selectByIndex(-1)}}},selectByIndex:function(f){c.get(this.id).selectedIndex=f+1;this.selectedValue=this.items[f]?this.items[f].value:null},add:function(j,g,f){var i,h=this;f=f||{};f.value=g;if(h.isRendered()){c.add(c.get(this.id),"option",f,j)}i={title:j,value:g,attribs:f};h.items.push(i);h.onAdd.dispatch(h,i)},getLength:function(){return c.get(this.id).options.length-1},renderHTML:function(){var g,f=this;g=c.createHTML("option",{value:""},"-- "+f.settings.title+" --");e(f.items,function(h){g+=c.createHTML("option",{value:h.value},h.title)});g=c.createHTML("select",{id:f.id,"class":"mceNativeListBox"},g);return g},postRender:function(){var g=this,h;g.rendered=true;function f(j){var i=g.items[j.target.selectedIndex-1];if(i&&(i=i.value)){g.onChange.dispatch(g,i);if(g.settings.onselect){g.settings.onselect(i)}}}b.add(g.id,"change",f);b.add(g.id,"keydown",function(j){var i;b.remove(g.id,"change",h);i=b.add(g.id,"blur",function(){b.add(g.id,"change",f);b.remove(g.id,"blur",i)});if(j.keyCode==13||j.keyCode==32){f(j);return b.cancel(j)}});g.onPostRender.dispatch(g,c.get(g.id))}})})(tinymce);(function(c){var b=c.DOM,a=c.dom.Event,d=c.each;c.create("tinymce.ui.MenuButton:tinymce.ui.Button",{MenuButton:function(f,e){this.parent(f,e);this.onRenderMenu=new c.util.Dispatcher(this);e.menu_container=e.menu_container||b.doc.body},showMenu:function(){var g=this,j,i,h=b.get(g.id),f;if(g.isDisabled()){return}if(!g.isMenuRendered){g.renderMenu();g.isMenuRendered=true}if(g.isMenuVisible){return g.hideMenu()}j=b.getPos(g.settings.menu_container);i=b.getPos(h);f=g.menu;f.settings.offset_x=i.x;f.settings.offset_y=i.y;f.settings.vp_offset_x=i.x;f.settings.vp_offset_y=i.y;f.settings.keyboard_focus=g._focused;f.showMenu(0,h.clientHeight);a.add(b.doc,"mousedown",g.hideMenu,g);g.setState("Selected",1);g.isMenuVisible=1},renderMenu:function(){var f=this,e;e=f.settings.control_manager.createDropMenu(f.id+"_menu",{menu_line:1,"class":this.classPrefix+"Menu",icons:f.settings.icons});e.onHideMenu.add(f.hideMenu,f);f.onRenderMenu.dispatch(f,e);f.menu=e},hideMenu:function(g){var f=this;if(g&&g.type=="mousedown"&&b.getParent(g.target,function(h){return h.id===f.id||h.id===f.id+"_open"})){return}if(!g||!b.getParent(g.target,".mceMenu")){f.setState("Selected",0);a.remove(b.doc,"mousedown",f.hideMenu,f);if(f.menu){f.menu.hideMenu()}}f.isMenuVisible=0},postRender:function(){var e=this,f=e.settings;a.add(e.id,"click",function(){if(!e.isDisabled()){if(f.onclick){f.onclick(e.value)}e.showMenu()}})}})})(tinymce);(function(c){var b=c.DOM,a=c.dom.Event,d=c.each;c.create("tinymce.ui.SplitButton:tinymce.ui.MenuButton",{SplitButton:function(f,e){this.parent(f,e);this.classPrefix="mceSplitButton"},renderHTML:function(){var i,f=this,g=f.settings,e;i="<tbody><tr>";if(g.image){e=b.createHTML("img ",{src:g.image,"class":"mceAction "+g["class"]})}else{e=b.createHTML("span",{"class":"mceAction "+g["class"]},"")}i+="<td>"+b.createHTML("a",{id:f.id+"_action",href:"javascript:;","class":"mceAction "+g["class"],onclick:"return false;",onmousedown:"return false;",title:g.title},e)+"</td>";e=b.createHTML("span",{"class":"mceOpen "+g["class"]});i+="<td>"+b.createHTML("a",{id:f.id+"_open",href:"javascript:;","class":"mceOpen "+g["class"],onclick:"return false;",onmousedown:"return false;",title:g.title},e)+"</td>";i+="</tr></tbody>";return b.createHTML("table",{id:f.id,"class":"mceSplitButton mceSplitButtonEnabled "+g["class"],cellpadding:"0",cellspacing:"0",onmousedown:"return false;",title:g.title},i)},postRender:function(){var e=this,f=e.settings;if(f.onclick){a.add(e.id+"_action","click",function(){if(!e.isDisabled()){f.onclick(e.value)}})}a.add(e.id+"_open","click",e.showMenu,e);a.add(e.id+"_open","focus",function(){e._focused=1});a.add(e.id+"_open","blur",function(){e._focused=0});if(c.isIE6||!b.boxModel){a.add(e.id,"mouseover",function(){if(!b.hasClass(e.id,"mceSplitButtonDisabled")){b.addClass(e.id,"mceSplitButtonHover")}});a.add(e.id,"mouseout",function(){if(!b.hasClass(e.id,"mceSplitButtonDisabled")){b.removeClass(e.id,"mceSplitButtonHover")}})}},destroy:function(){this.parent();a.clear(this.id+"_action");a.clear(this.id+"_open")}})})(tinymce);(function(d){var c=d.DOM,a=d.dom.Event,b=d.is,e=d.each;d.create("tinymce.ui.ColorSplitButton:tinymce.ui.SplitButton",{ColorSplitButton:function(h,g){var f=this;f.parent(h,g);f.settings=g=d.extend({colors:"000000,993300,333300,003300,003366,000080,333399,333333,800000,FF6600,808000,008000,008080,0000FF,666699,808080,FF0000,FF9900,99CC00,339966,33CCCC,3366FF,800080,999999,FF00FF,FFCC00,FFFF00,00FF00,00FFFF,00CCFF,993366,C0C0C0,FF99CC,FFCC99,FFFF99,CCFFCC,CCFFFF,99CCFF,CC99FF,FFFFFF",grid_width:8,default_color:"#888888"},f.settings);f.onShowMenu=new d.util.Dispatcher(f);f.onHideMenu=new d.util.Dispatcher(f);f.value=g.default_color},showMenu:function(){var f=this,g,j,i,h;if(f.isDisabled()){return}if(!f.isMenuRendered){f.renderMenu();f.isMenuRendered=true}if(f.isMenuVisible){return f.hideMenu()}i=c.get(f.id);c.show(f.id+"_menu");c.addClass(i,"mceSplitButtonSelected");h=c.getPos(i);c.setStyles(f.id+"_menu",{left:h.x,top:h.y+i.clientHeight,zIndex:200000});i=0;a.add(c.doc,"mousedown",f.hideMenu,f);if(f._focused){f._keyHandler=a.add(f.id+"_menu","keydown",function(k){if(k.keyCode==27){f.hideMenu()}});c.select("a",f.id+"_menu")[0].focus()}f.onShowMenu.dispatch(f);f.isMenuVisible=1},hideMenu:function(g){var f=this;if(g&&g.type=="mousedown"&&c.getParent(g.target,function(h){return h.id===f.id+"_open"})){return}if(!g||!c.getParent(g.target,".mceSplitButtonMenu")){c.removeClass(f.id,"mceSplitButtonSelected");a.remove(c.doc,"mousedown",f.hideMenu,f);a.remove(f.id+"_menu","keydown",f._keyHandler);c.hide(f.id+"_menu")}f.onHideMenu.dispatch(f);f.isMenuVisible=0},renderMenu:function(){var k=this,f,j=0,l=k.settings,p,h,o,g;g=c.add(l.menu_container,"div",{id:k.id+"_menu","class":l.menu_class+" "+l["class"],style:"position:absolute;left:0;top:-1000px;"});f=c.add(g,"div",{"class":l["class"]+" mceSplitButtonMenu"});c.add(f,"span",{"class":"mceMenuLine"});p=c.add(f,"table",{"class":"mceColorSplitMenu"});h=c.add(p,"tbody");j=0;e(b(l.colors,"array")?l.colors:l.colors.split(","),function(i){i=i.replace(/^#/,"");if(!j--){o=c.add(h,"tr");j=l.grid_width-1}p=c.add(o,"td");p=c.add(p,"a",{href:"javascript:;",style:{backgroundColor:"#"+i},mce_color:"#"+i})});if(l.more_colors_func){p=c.add(h,"tr");p=c.add(p,"td",{colspan:l.grid_width,"class":"mceMoreColors"});p=c.add(p,"a",{id:k.id+"_more",href:"javascript:;",onclick:"return false;","class":"mceMoreColors"},l.more_colors_title);a.add(p,"click",function(i){l.more_colors_func.call(l.more_colors_scope||this);return a.cancel(i)})}c.addClass(f,"mceColorSplitMenu");a.add(k.id+"_menu","click",function(i){var m;i=i.target;if(i.nodeName=="A"&&(m=i.getAttribute("mce_color"))){k.setColor(m)}return a.cancel(i)});return g},setColor:function(g){var f=this;c.setStyle(f.id+"_preview","backgroundColor",g);f.value=g;f.hideMenu();f.settings.onselect(g)},postRender:function(){var f=this,g=f.id;f.parent();c.add(g+"_action","div",{id:g+"_preview","class":"mceColorPreview"});c.setStyle(f.id+"_preview","backgroundColor",f.value)},destroy:function(){this.parent();a.clear(this.id+"_menu");a.clear(this.id+"_more");c.remove(this.id+"_menu")}})})(tinymce);tinymce.create("tinymce.ui.Toolbar:tinymce.ui.Container",{renderHTML:function(){var l=this,e="",g,j,b=tinymce.DOM,m=l.settings,d,a,f,k;k=l.controls;for(d=0;d<k.length;d++){j=k[d];a=k[d-1];f=k[d+1];if(d===0){g="mceToolbarStart";if(j.Button){g+=" mceToolbarStartButton"}else{if(j.SplitButton){g+=" mceToolbarStartSplitButton"}else{if(j.ListBox){g+=" mceToolbarStartListBox"}}}e+=b.createHTML("td",{"class":g},b.createHTML("span",null,"<!-- IE -->"))}if(a&&j.ListBox){if(a.Button||a.SplitButton){e+=b.createHTML("td",{"class":"mceToolbarEnd"},b.createHTML("span",null,"<!-- IE -->"))}}if(b.stdMode){e+='<td style="position: relative">'+j.renderHTML()+"</td>"}else{e+="<td>"+j.renderHTML()+"</td>"}if(f&&j.ListBox){if(f.Button||f.SplitButton){e+=b.createHTML("td",{"class":"mceToolbarStart"},b.createHTML("span",null,"<!-- IE -->"))}}}g="mceToolbarEnd";if(j.Button){g+=" mceToolbarEndButton"}else{if(j.SplitButton){g+=" mceToolbarEndSplitButton"}else{if(j.ListBox){g+=" mceToolbarEndListBox"}}}e+=b.createHTML("td",{"class":g},b.createHTML("span",null,"<!-- IE -->"));return b.createHTML("table",{id:l.id,"class":"mceToolbar"+(m["class"]?" "+m["class"]:""),cellpadding:"0",cellspacing:"0",align:l.settings.align||""},"<tbody><tr>"+e+"</tr></tbody>")}});(function(b){var a=b.util.Dispatcher,c=b.each;b.create("tinymce.AddOnManager",{items:[],urls:{},lookup:{},onAdd:new a(this),get:function(d){return this.lookup[d]},requireLangPack:function(f){var d,e=b.EditorManager.settings;if(e&&e.language){d=this.urls[f]+"/langs/"+e.language+".js";if(!b.dom.Event.domLoaded&&!e.strict_mode){b.ScriptLoader.load(d)}else{b.ScriptLoader.add(d)}}},add:function(e,d){this.items.push(d);this.lookup[e]=d;this.onAdd.dispatch(this,e,d);return d},load:function(h,e,d,g){var f=this;if(f.urls[h]){return}if(e.indexOf("/")!=0&&e.indexOf("://")==-1){e=b.baseURL+"/"+e}f.urls[h]=e.substring(0,e.lastIndexOf("/"));b.ScriptLoader.add(e,d,g)}});b.PluginManager=new b.AddOnManager();b.ThemeManager=new b.AddOnManager()}(tinymce));(function(f){var g=f.each,h=f.extend,e=f.DOM,a=f.dom.Event,c=f.ThemeManager,b=f.PluginManager,d=f.explode;f.create("static tinymce.EditorManager",{editors:{},i18n:{},activeEditor:null,preInit:function(){var i=this,j=window.location;f.documentBaseURL=j.href.replace(/[\?#].*$/,"").replace(/[\/\\][^\/]+$/,"");if(!/[\/\\]$/.test(f.documentBaseURL)){f.documentBaseURL+="/"}f.baseURL=new f.util.URI(f.documentBaseURL).toAbsolute(f.baseURL);f.EditorManager.baseURI=new f.util.URI(f.baseURL);if(document.domain&&j.hostname!=document.domain){f.relaxedDomain=document.domain}i.onBeforeUnload=new f.util.Dispatcher(i);a.add(window,"beforeunload",function(k){i.onBeforeUnload.dispatch(i,k)})},init:function(q){var p=this,l,k=f.ScriptLoader,o,n,i=[],m;function j(u,v,r){var t=u[v];if(!t){return}if(f.is(t,"string")){r=t.replace(/\.\w+$/,"");r=r?f.resolve(r):0;t=f.resolve(t)}return t.apply(r||this,Array.prototype.slice.call(arguments,2))}q=h({theme:"simple",language:"en",strict_loading_mode:document.contentType=="application/xhtml+xml"},q);p.settings=q;if(!a.domLoaded&&!q.strict_loading_mode){if(q.language){k.add(f.baseURL+"/langs/"+q.language+".js")}if(q.theme&&q.theme.charAt(0)!="-"&&!c.urls[q.theme]){c.load(q.theme,"themes/"+q.theme+"/editor_template"+f.suffix+".js")}if(q.plugins){l=d(q.plugins);if(f.inArray(l,"compat2x")!=-1){b.load("compat2x","plugins/compat2x/editor_plugin"+f.suffix+".js")}g(l,function(r){if(r&&r.charAt(0)!="-"&&!b.urls[r]){if(!f.isWebKit&&r=="safari"){return}b.load(r,"plugins/"+r+"/editor_plugin"+f.suffix+".js")}})}k.loadQueue()}a.add(document,"init",function(){var r,t;j(q,"onpageload");if(q.browsers){r=false;g(d(q.browsers),function(u){switch(u){case"ie":case"msie":if(f.isIE){r=true}break;case"gecko":if(f.isGecko){r=true}break;case"safari":case"webkit":if(f.isWebKit){r=true}break;case"opera":if(f.isOpera){r=true}break}});if(!r){return}}switch(q.mode){case"exact":r=q.elements||"";if(r.length>0){g(d(r),function(u){if(e.get(u)){m=new f.Editor(u,q);i.push(m);m.render(1)}else{o=0;g(document.forms,function(v){g(v.elements,function(w){if(w.name===u){u="mce_editor_"+o;e.setAttrib(w,"id",u);m=new f.Editor(u,q);i.push(m);m.render(1)}})})}})}break;case"textareas":case"specific_textareas":function s(v,u){return u.constructor===RegExp?u.test(v.className):e.hasClass(v,u)}g(e.select("textarea"),function(u){if(q.editor_deselector&&s(u,q.editor_deselector)){return}if(!q.editor_selector||s(u,q.editor_selector)){n=e.get(u.name);if(!u.id&&!n){u.id=u.name}if(!u.id||p.get(u.id)){u.id=e.uniqueId()}m=new f.Editor(u.id,q);i.push(m);m.render(1)}});break}if(q.oninit){r=t=0;g(i,function(u){t++;if(!u.initialized){u.onInit.add(function(){r++;if(r==t){j(q,"oninit")}})}else{r++}if(r==t){j(q,"oninit")}})}})},get:function(i){return this.editors[i]},getInstanceById:function(i){return this.get(i)},add:function(i){this.editors[i.id]=i;this._setActive(i);return i},remove:function(j){var i=this;if(!i.editors[j.id]){return null}delete i.editors[j.id];if(i.activeEditor==j){g(i.editors,function(k){i._setActive(k);return false})}j.destroy();return j},execCommand:function(o,m,l){var n=this,k=n.get(l),i;switch(o){case"mceFocus":k.focus();return true;case"mceAddEditor":case"mceAddControl":if(!n.get(l)){new f.Editor(l,n.settings).render()}return true;case"mceAddFrameControl":i=l.window;i.tinyMCE=tinyMCE;i.tinymce=f;f.DOM.doc=i.document;f.DOM.win=i;k=new f.Editor(l.element_id,l);k.render();if(f.isIE){function j(){k.destroy();i.detachEvent("onunload",j);i=i.tinyMCE=i.tinymce=null}i.attachEvent("onunload",j)}l.page_window=null;return true;case"mceRemoveEditor":case"mceRemoveControl":if(k){k.remove()}return true;case"mceToggleEditor":if(!k){n.execCommand("mceAddControl",0,l);return true}if(k.isHidden()){k.show()}else{k.hide()}return true}if(n.activeEditor){return n.activeEditor.execCommand(o,m,l)}return false},execInstanceCommand:function(m,l,k,j){var i=this.get(m);if(i){return i.execCommand(l,k,j)}return false},triggerSave:function(){g(this.editors,function(i){i.save()})},addI18n:function(k,l){var i,j=this.i18n;if(!f.is(k,"string")){g(k,function(n,m){g(n,function(q,p){g(q,function(s,r){if(p==="common"){j[m+"."+r]=s}else{j[m+"."+p+"."+r]=s}})})})}else{g(l,function(n,m){j[k+"."+m]=n})}},_setActive:function(i){this.selectedInstance=this.activeEditor=i}});f.EditorManager.preInit()})(tinymce);var tinyMCE=window.tinyMCE=tinymce.EditorManager;(function(n){var o=n.DOM,k=n.dom.Event,f=n.extend,l=n.util.Dispatcher;var j=n.each,a=n.isGecko,b=n.isIE,e=n.isWebKit;var d=n.is,h=n.ThemeManager,c=n.PluginManager,i=n.EditorManager;var p=n.inArray,m=n.grep,g=n.explode;n.create("tinymce.Editor",{Editor:function(u,r){var q=this;q.id=q.editorId=u;q.execCommands={};q.queryStateCommands={};q.queryValueCommands={};q.plugins={};j(["onPreInit","onBeforeRenderUI","onPostRender","onInit","onRemove","onActivate","onDeactivate","onClick","onEvent","onMouseUp","onMouseDown","onDblClick","onKeyDown","onKeyUp","onKeyPress","onContextMenu","onSubmit","onReset","onPaste","onPreProcess","onPostProcess","onBeforeSetContent","onBeforeGetContent","onSetContent","onGetContent","onLoadContent","onSaveContent","onNodeChange","onChange","onBeforeExecCommand","onExecCommand","onUndo","onRedo","onVisualAid","onSetProgressState"],function(s){q[s]=new l(q)});q.settings=r=f({id:u,language:"en",docs_language:"en",theme:"simple",skin:"default",delta_width:0,delta_height:0,popup_css:"",plugins:"",document_base_url:n.documentBaseURL,add_form_submit_trigger:1,submit_patch:1,add_unload_trigger:1,convert_urls:1,relative_urls:1,remove_script_host:1,table_inline_editing:0,object_resizing:1,cleanup:1,accessibility_focus:1,custom_shortcuts:1,custom_undo_redo_keyboard_shortcuts:1,custom_undo_redo_restore_selection:1,custom_undo_redo:1,doctype:'<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">',visual_table_class:"mceItemTable",visual:1,inline_styles:true,convert_fonts_to_spans:true,font_size_style_values:"xx-small,x-small,small,medium,large,x-large,xx-large",apply_source_formatting:1,directionality:"ltr",forced_root_block:"p",valid_elements:"@[id|class|style|title|dir<ltr?rtl|lang|xml::lang|onclick|ondblclick|onmousedown|onmouseup|onmouseover|onmousemove|onmouseout|onkeypress|onkeydown|onkeyup],a[rel|rev|charset|hreflang|tabindex|accesskey|type|name|href|target|title|class|onfocus|onblur],strong/b,em/i,strike,u,#p[align],-ol[type|compact],-ul[type|compact],-li,br,img[longdesc|usemap|src|border|alt=|title|hspace|vspace|width|height|align],-sub,-sup,-blockquote[cite],-table[border=0|cellspacing|cellpadding|width|frame|rules|height|align|summary|bgcolor|background|bordercolor],-tr[rowspan|width|height|align|valign|bgcolor|background|bordercolor],tbody,thead,tfoot,#td[colspan|rowspan|width|height|align|valign|bgcolor|background|bordercolor|scope],#th[colspan|rowspan|width|height|align|valign|scope],caption,-div,-span,-code,-pre,address,-h1,-h2,-h3,-h4,-h5,-h6,hr[size|noshade],-font[face|size|color],dd,dl,dt,cite,abbr,acronym,del[datetime|cite],ins[datetime|cite],object[classid|width|height|codebase|*],param[name|value],embed[type|width|height|src|*],script[src|type],map[name],area[shape|coords|href|alt|target],bdo,button,col[align|char|charoff|span|valign|width],colgroup[align|char|charoff|span|valign|width],dfn,fieldset,form[action|accept|accept-charset|enctype|method],input[accept|alt|checked|disabled|maxlength|name|readonly|size|src|type|value|tabindex|accesskey],kbd,label[for],legend,noscript,optgroup[label|disabled],option[disabled|label|selected|value],q[cite],samp,select[disabled|multiple|name|size],small,textarea[cols|rows|disabled|name|readonly],tt,var,big",hidden_input:1,padd_empty_editor:1,render_ui:1,init_theme:1,force_p_newlines:1,indentation:"30px",keep_styles:1,fix_table_elements:1,removeformat_selector:"span,b,strong,em,i,font,u,strike"},r);q.documentBaseURI=new n.util.URI(r.document_base_url||n.documentBaseURL,{base_uri:tinyMCE.baseURI});q.baseURI=i.baseURI;q.execCallback("setup",q)},render:function(u){var v=this,w=v.settings,x=v.id,q=n.ScriptLoader;if(!k.domLoaded){k.add(document,"init",function(){v.render()});return}if(!u){w.strict_loading_mode=1;tinyMCE.settings=w}if(!v.getElement()){return}if(w.strict_loading_mode){q.settings.strict_mode=w.strict_loading_mode;n.DOM.settings.strict=1}if(!/TEXTAREA|INPUT/i.test(v.getElement().nodeName)&&w.hidden_input&&o.getParent(x,"form")){o.insertAfter(o.create("input",{type:"hidden",name:x}),x)}if(n.WindowManager){v.windowManager=new n.WindowManager(v)}if(w.encoding=="xml"){v.onGetContent.add(function(s,t){if(t.save){t.content=o.encode(t.content)}})}if(w.add_form_submit_trigger){v.onSubmit.addToTop(function(){if(v.initialized){v.save();v.isNotDirty=1}})}if(w.add_unload_trigger){v._beforeUnload=tinyMCE.onBeforeUnload.add(function(){if(v.initialized&&!v.destroyed&&!v.isHidden()){v.save({format:"raw",no_events:true})}})}n.addUnload(v.destroy,v);if(w.submit_patch){v.onBeforeRenderUI.add(function(){var s=v.getElement().form;if(!s){return}if(s._mceOldSubmit){return}if(!s.submit.nodeType&&!s.submit.length){v.formElement=s;s._mceOldSubmit=s.submit;s.submit=function(){i.triggerSave();v.isNotDirty=1;return v.formElement._mceOldSubmit(v.formElement)}}s=null})}function r(){if(w.language){q.add(n.baseURL+"/langs/"+w.language+".js")}if(w.theme&&w.theme.charAt(0)!="-"&&!h.urls[w.theme]){h.load(w.theme,"themes/"+w.theme+"/editor_template"+n.suffix+".js")}j(g(w.plugins),function(s){if(s&&s.charAt(0)!="-"&&!c.urls[s]){if(!e&&s=="safari"){return}c.load(s,"plugins/"+s+"/editor_plugin"+n.suffix+".js")}});q.loadQueue(function(){if(!v.removed){v.init()}})}if(w.plugins.indexOf("compat2x")!=-1){c.load("compat2x","plugins/compat2x/editor_plugin"+n.suffix+".js");q.loadQueue(r)}else{r()}},init:function(){var v,F=this,G=F.settings,C,z,B=F.getElement(),r,q,D,y,A,E;i.add(F);if(G.theme){G.theme=G.theme.replace(/-/,"");r=h.get(G.theme);F.theme=new r();if(F.theme.init&&G.init_theme){F.theme.init(F,h.urls[G.theme]||n.documentBaseURL.replace(/\/$/,""))}}j(g(G.plugins.replace(/\-/g,"")),function(w){var H=c.get(w),t=c.urls[w]||n.documentBaseURL.replace(/\/$/,""),s;if(H){s=new H(F,t);F.plugins[w]=s;if(s.init){s.init(F,t)}}});if(G.popup_css!==false){if(G.popup_css){G.popup_css=F.documentBaseURI.toAbsolute(G.popup_css)}else{G.popup_css=F.baseURI.toAbsolute("themes/"+G.theme+"/skins/"+G.skin+"/dialog.css")}}if(G.popup_css_add){G.popup_css+=","+F.documentBaseURI.toAbsolute(G.popup_css_add)}F.controlManager=new n.ControlManager(F);F.undoManager=new n.UndoManager(F);F.undoManager.onAdd.add(function(t,s){if(!s.initial){return F.onChange.dispatch(F,s,t)}});F.undoManager.onUndo.add(function(t,s){return F.onUndo.dispatch(F,s,t)});F.undoManager.onRedo.add(function(t,s){return F.onRedo.dispatch(F,s,t)});if(G.custom_undo_redo){F.onExecCommand.add(function(t,w,u,H,s){if(w!="Undo"&&w!="Redo"&&w!="mceRepaint"&&(!s||!s.skip_undo)){F.undoManager.add()}})}F.onExecCommand.add(function(s,t){if(!/^(FontName|FontSize)$/.test(t)){F.nodeChanged()}});if(a){function x(s,t){if(!t||!t.initial){F.execCommand("mceRepaint")}}F.onUndo.add(x);F.onRedo.add(x);F.onSetContent.add(x)}F.onBeforeRenderUI.dispatch(F,F.controlManager);if(G.render_ui){C=G.width||B.style.width||B.offsetWidth;z=G.height||B.style.height||B.offsetHeight;F.orgDisplay=B.style.display;E=/^[0-9\.]+(|px)$/i;if(E.test(""+C)){C=Math.max(parseInt(C)+(r.deltaWidth||0),100)}if(E.test(""+z)){z=Math.max(parseInt(z)+(r.deltaHeight||0),100)}r=F.theme.renderUI({targetNode:B,width:C,height:z,deltaWidth:G.delta_width,deltaHeight:G.delta_height});F.editorContainer=r.editorContainer}o.setStyles(r.sizeContainer||r.editorContainer,{width:C,height:z});z=(r.iframeHeight||z)+(typeof(z)=="number"?(r.deltaHeight||0):"");if(z<100){z=100}F.iframeHTML=G.doctype+'<html><head xmlns="http://www.w3.org/1999/xhtml"><base href="'+F.documentBaseURI.getURI()+'" />';F.iframeHTML+='<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />';if(n.relaxedDomain){F.iframeHTML+='<script type="text/javascript">document.domain = "'+n.relaxedDomain+'";<\/script>'}y=G.body_id||"tinymce";if(y.indexOf("=")!=-1){y=F.getParam("body_id","","hash");y=y[F.id]||y}A=G.body_class||"";if(A.indexOf("=")!=-1){A=F.getParam("body_class","","hash");A=A[F.id]||""}F.iframeHTML+='</head><body id="'+y+'" class="mceContentBody '+A+'"></body></html>';if(n.relaxedDomain){if(b||(n.isOpera&&parseFloat(opera.version())>=9.5)){D='javascript:(function(){document.open();document.domain="'+document.domain+'";var ed = window.parent.tinyMCE.get("'+F.id+'");document.write(ed.iframeHTML);document.close();ed.setupIframe();})()'}else{if(n.isOpera){D='javascript:(function(){document.open();document.domain="'+document.domain+'";document.close();ed.setupIframe();})()'}}}v=o.add(r.iframeContainer,"iframe",{id:F.id+"_ifr",src:D||'javascript:""',frameBorder:"0",style:{width:"100%",height:z}});F.contentAreaContainer=r.iframeContainer;o.get(r.editorContainer).style.display=F.orgDisplay;o.get(F.id).style.display="none";if(!b||!n.relaxedDomain){F.setupIframe()}B=v=r=null},setupIframe:function(){var z=this,A=z.settings,u=o.get(z.id),v=z.getDoc(),r,x;if(!b||!n.relaxedDomain){v.open();v.write(z.iframeHTML);v.close()}if(!b){try{if(!A.readonly){v.designMode="On"}}catch(w){}}if(b){x=z.getBody();o.hide(x);if(!A.readonly){x.contentEditable=true}o.show(x)}z.dom=new n.DOM.DOMUtils(z.getDoc(),{keep_values:true,url_converter:z.convertURL,url_converter_scope:z,hex_colors:A.force_hex_style_colors,class_filter:A.class_filter,update_styles:1,fix_ie_paragraphs:1});z.serializer=new n.dom.Serializer({entity_encoding:A.entity_encoding,entities:A.entities,valid_elements:A.verify_html===false?"*[*]":A.valid_elements,extended_valid_elements:A.extended_valid_elements,valid_child_elements:A.valid_child_elements,invalid_elements:A.invalid_elements,fix_table_elements:A.fix_table_elements,fix_list_elements:A.fix_list_elements,fix_content_duplication:A.fix_content_duplication,convert_fonts_to_spans:A.convert_fonts_to_spans,font_size_classes:A.font_size_classes,font_size_style_values:A.font_size_style_values,apply_source_formatting:A.apply_source_formatting,remove_linebreaks:A.remove_linebreaks,element_format:A.element_format,dom:z.dom});z.selection=new n.dom.Selection(z.dom,z.getWin(),z.serializer);z.forceBlocks=new n.ForceBlocks(z,{forced_root_block:A.forced_root_block});z.editorCommands=new n.EditorCommands(z);z.serializer.onPreProcess.add(function(s,t){return z.onPreProcess.dispatch(z,t,s)});z.serializer.onPostProcess.add(function(s,t){return z.onPostProcess.dispatch(z,t,s)});z.onPreInit.dispatch(z);if(!A.gecko_spellcheck){z.getBody().spellcheck=0}if(!A.readonly){z._addEvents()}z.controlManager.onPostRender.dispatch(z,z.controlManager);z.onPostRender.dispatch(z);if(A.directionality){z.getBody().dir=A.directionality}if(A.nowrap){z.getBody().style.whiteSpace="nowrap"}if(A.auto_resize){z.onNodeChange.add(z.resizeToContent,z)}if(A.custom_elements){function y(s,t){j(g(A.custom_elements),function(B){var C;if(B.indexOf("~")===0){B=B.substring(1);C="span"}else{C="div"}t.content=t.content.replace(new RegExp("<("+B+")([^>]*)>","g"),"<"+C+' mce_name="$1"$2>');t.content=t.content.replace(new RegExp("</("+B+")>","g"),"</"+C+">")})}z.onBeforeSetContent.add(y);z.onPostProcess.add(function(s,t){if(t.set){y(s,t)}})}if(A.handle_node_change_callback){z.onNodeChange.add(function(t,s,B){z.execCallback("handle_node_change_callback",z.id,B,-1,-1,true,z.selection.isCollapsed())})}if(A.save_callback){z.onSaveContent.add(function(s,B){var t=z.execCallback("save_callback",z.id,B.content,z.getBody());if(t){B.content=t}})}if(A.onchange_callback){z.onChange.add(function(t,s){z.execCallback("onchange_callback",z,s)})}if(A.convert_newlines_to_brs){z.onBeforeSetContent.add(function(s,t){if(t.initial){t.content=t.content.replace(/\r?\n/g,"<br />")}})}if(A.fix_nesting&&b){z.onBeforeSetContent.add(function(s,t){t.content=z._fixNesting(t.content)})}if(A.preformatted){z.onPostProcess.add(function(s,t){t.content=t.content.replace(/^\s*<pre.*?>/,"");t.content=t.content.replace(/<\/pre>\s*$/,"");if(t.set){t.content='<pre class="mceItemHidden">'+t.content+"</pre>"}})}if(A.verify_css_classes){z.serializer.attribValueFilter=function(D,B){var C,t;if(D=="class"){if(!z.classesRE){t=z.dom.getClasses();if(t.length>0){C="";j(t,function(s){C+=(C?"|":"")+s["class"]});z.classesRE=new RegExp("("+C+")","gi")}}return !z.classesRE||/(\bmceItem\w+\b|\bmceTemp\w+\b)/g.test(B)||z.classesRE.test(B)?B:""}return B}}if(A.convert_fonts_to_spans){z._convertFonts()}if(A.inline_styles){z._convertInlineElements()}if(A.cleanup_callback){z.onBeforeSetContent.add(function(s,t){t.content=z.execCallback("cleanup_callback","insert_to_editor",t.content,t)});z.onPreProcess.add(function(s,t){if(t.set){z.execCallback("cleanup_callback","insert_to_editor_dom",t.node,t)}if(t.get){z.execCallback("cleanup_callback","get_from_editor_dom",t.node,t)}});z.onPostProcess.add(function(s,t){if(t.set){t.content=z.execCallback("cleanup_callback","insert_to_editor",t.content,t)}if(t.get){t.content=z.execCallback("cleanup_callback","get_from_editor",t.content,t)}})}if(A.save_callback){z.onGetContent.add(function(s,t){if(t.save){t.content=z.execCallback("save_callback",z.id,t.content,z.getBody())}})}if(A.handle_event_callback){z.onEvent.add(function(s,t,B){if(z.execCallback("handle_event_callback",t,s,B)===false){k.cancel(t)}})}z.onSetContent.add(function(){z.addVisual(z.getBody())});if(A.padd_empty_editor){z.onPostProcess.add(function(s,t){t.content=t.content.replace(/^(<p[^>]*>(&nbsp;|&#160;|\s|\u00a0|)<\/p>[\r\n]*|<br \/>[\r\n]*)$/,"")})}if(a){function q(s,t){j(s.dom.select("a"),function(C){var B=C.parentNode;if(s.dom.isBlock(B)&&B.lastChild===C){s.dom.add(B,"br",{mce_bogus:1})}})}z.onExecCommand.add(function(s,t){if(t==="CreateLink"){q(s)}});z.onSetContent.add(z.selection.onSetContent.add(q));if(!A.readonly){try{v.designMode="Off";v.designMode="On"}catch(w){}}}setTimeout(function(){if(z.removed){return}z.load({initial:true,format:(A.cleanup_on_startup?"html":"raw")});z.startContent=z.getContent({format:"raw"});z.undoManager.add({initial:true});z.initialized=true;z.onInit.dispatch(z);z.execCallback("setupcontent_callback",z.id,z.getBody(),z.getDoc());z.execCallback("init_instance_callback",z);z.focus(true);z.nodeChanged({initial:1});if(A.content_css){n.each(g(A.content_css),function(s){z.dom.loadCSS(z.documentBaseURI.toAbsolute(s))})}if(A.auto_focus){setTimeout(function(){var s=i.get(A.auto_focus);s.selection.select(s.getBody(),1);s.selection.collapse(1);s.getWin().focus()},100)}},1);u=null},focus:function(r){var u,q=this,s=q.settings.content_editable;if(!r){if(!s&&(!b||q.selection.getNode().ownerDocument!=q.getDoc())){q.getWin().focus()}}if(i.activeEditor!=q){if((u=i.activeEditor)!=null){u.onDeactivate.dispatch(u,q)}q.onActivate.dispatch(q,u)}i._setActive(q)},execCallback:function(v){var q=this,u=q.settings[v],r;if(!u){return}if(q.callbackLookup&&(r=q.callbackLookup[v])){u=r.func;r=r.scope}if(d(u,"string")){r=u.replace(/\.\w+$/,"");r=r?n.resolve(r):0;u=n.resolve(u);q.callbackLookup=q.callbackLookup||{};q.callbackLookup[v]={func:u,scope:r}}return u.apply(r||q,Array.prototype.slice.call(arguments,1))},translate:function(q){var t=this.settings.language||"en",r=i.i18n;if(!q){return""}return r[t+"."+q]||q.replace(/{\#([^}]+)\}/g,function(u,s){return r[t+"."+s]||"{#"+s+"}"})},getLang:function(r,q){return i.i18n[(this.settings.language||"en")+"."+r]||(d(q)?q:"{#"+r+"}")},getParam:function(w,s,q){var t=n.trim,r=d(this.settings[w])?this.settings[w]:s,u;if(q==="hash"){u={};if(d(r,"string")){j(r.indexOf("=")>0?r.split(/[;,](?![^=;,]*(?:[;,]|$))/):r.split(","),function(x){x=x.split("=");if(x.length>1){u[t(x[0])]=t(x[1])}else{u[t(x[0])]=t(x)}})}else{u=r}return u}return r},nodeChanged:function(u){var q=this,r=q.selection,v=r.getNode()||q.getBody();if(q.initialized){q.onNodeChange.dispatch(q,u?u.controlManager||q.controlManager:q.controlManager,b&&v.ownerDocument!=q.getDoc()?q.getBody():v,r.isCollapsed(),u)}},addButton:function(u,r){var q=this;q.buttons=q.buttons||{};q.buttons[u]=r},addCommand:function(t,r,q){this.execCommands[t]={func:r,scope:q||this}},addQueryStateHandler:function(t,r,q){this.queryStateCommands[t]={func:r,scope:q||this}},addQueryValueHandler:function(t,r,q){this.queryValueCommands[t]={func:r,scope:q||this}},addShortcut:function(s,v,q,u){var r=this,w;if(!r.settings.custom_shortcuts){return false}r.shortcuts=r.shortcuts||{};if(d(q,"string")){w=q;q=function(){r.execCommand(w,false,null)}}if(d(q,"object")){w=q;q=function(){r.execCommand(w[0],w[1],w[2])}}j(g(s),function(t){var x={func:q,scope:u||this,desc:v,alt:false,ctrl:false,shift:false};j(g(t,"+"),function(y){switch(y){case"alt":case"ctrl":case"shift":x[y]=true;break;default:x.charCode=y.charCodeAt(0);x.keyCode=y.toUpperCase().charCodeAt(0)}});r.shortcuts[(x.ctrl?"ctrl":"")+","+(x.alt?"alt":"")+","+(x.shift?"shift":"")+","+x.keyCode]=x});return true},execCommand:function(x,w,z,q){var u=this,v=0,y,r;if(!/^(mceAddUndoLevel|mceEndUndoLevel|mceBeginUndoLevel|mceRepaint|SelectAll)$/.test(x)&&(!q||!q.skip_focus)){u.focus()}y={};u.onBeforeExecCommand.dispatch(u,x,w,z,y);if(y.terminate){return false}if(u.execCallback("execcommand_callback",u.id,u.selection.getNode(),x,w,z)){u.onExecCommand.dispatch(u,x,w,z,q);return true}if(y=u.execCommands[x]){r=y.func.call(y.scope,w,z);if(r!==true){u.onExecCommand.dispatch(u,x,w,z,q);return r}}j(u.plugins,function(s){if(s.execCommand&&s.execCommand(x,w,z)){u.onExecCommand.dispatch(u,x,w,z,q);v=1;return false}});if(v){return true}if(u.theme&&u.theme.execCommand&&u.theme.execCommand(x,w,z)){u.onExecCommand.dispatch(u,x,w,z,q);return true}if(n.GlobalCommands.execCommand(u,x,w,z)){u.onExecCommand.dispatch(u,x,w,z,q);return true}if(u.editorCommands.execCommand(x,w,z)){u.onExecCommand.dispatch(u,x,w,z,q);return true}u.getDoc().execCommand(x,w,z);u.onExecCommand.dispatch(u,x,w,z,q)},queryCommandState:function(w){var r=this,v,u;if(r._isHidden()){return}if(v=r.queryStateCommands[w]){u=v.func.call(v.scope);if(u!==true){return u}}v=r.editorCommands.queryCommandState(w);if(v!==-1){return v}try{return this.getDoc().queryCommandState(w)}catch(q){}},queryCommandValue:function(w){var r=this,v,u;if(r._isHidden()){return}if(v=r.queryValueCommands[w]){u=v.func.call(v.scope);if(u!==true){return u}}v=r.editorCommands.queryCommandValue(w);if(d(v)){return v}try{return this.getDoc().queryCommandValue(w)}catch(q){}},show:function(){var q=this;o.show(q.getContainer());o.hide(q.id);q.load()},hide:function(){var q=this,r=q.getDoc();if(b&&r){r.execCommand("SelectAll")}q.save();o.hide(q.getContainer());o.setStyle(q.id,"display",q.orgDisplay)},isHidden:function(){return !o.isHidden(this.id)},setProgressState:function(q,r,s){this.onSetProgressState.dispatch(this,q,r,s);return q},resizeToContent:function(){var q=this;o.setStyle(q.id+"_ifr","height",q.getBody().scrollHeight)},load:function(u){var q=this,s=q.getElement(),r;if(s){u=u||{};u.load=true;r=q.setContent(d(s.value)?s.value:s.innerHTML,u);u.element=s;if(!u.no_events){q.onLoadContent.dispatch(q,u)}u.element=s=null;return r}},save:function(v){var q=this,u=q.getElement(),r,s;if(!u||!q.initialized){return}v=v||{};v.save=true;if(!v.no_events){q.undoManager.typing=0;q.undoManager.add()}v.element=u;r=v.content=q.getContent(v);if(!v.no_events){q.onSaveContent.dispatch(q,v)}r=v.content;if(!/TEXTAREA|INPUT/i.test(u.nodeName)){u.innerHTML=r;if(s=o.getParent(q.id,"form")){j(s.elements,function(t){if(t.name==q.id){t.value=r;return false}})}}else{u.value=r}v.element=u=null;return r},setContent:function(r,s){var q=this;s=s||{};s.format=s.format||"html";s.set=true;s.content=r;if(!s.no_events){q.onBeforeSetContent.dispatch(q,s)}if(!n.isIE&&(r.length===0||/^\s+$/.test(r))){s.content=q.dom.setHTML(q.getBody(),'<br mce_bogus="1" />');s.format="raw"}s.content=q.dom.setHTML(q.getBody(),n.trim(s.content));if(s.format!="raw"&&q.settings.cleanup){s.getInner=true;s.content=q.dom.setHTML(q.getBody(),q.serializer.serialize(q.getBody(),s))}if(!s.no_events){q.onSetContent.dispatch(q,s)}return s.content},getContent:function(s){var q=this,r;s=s||{};s.format=s.format||"html";s.get=true;if(!s.no_events){q.onBeforeGetContent.dispatch(q,s)}if(s.format!="raw"&&q.settings.cleanup){s.getInner=true;r=q.serializer.serialize(q.getBody(),s)}else{r=q.getBody().innerHTML}r=r.replace(/^\s*|\s*$/g,"");s.content=r;if(!s.no_events){q.onGetContent.dispatch(q,s)}return s.content},isDirty:function(){var q=this;return n.trim(q.startContent)!=n.trim(q.getContent({format:"raw",no_events:1}))&&!q.isNotDirty},getContainer:function(){var q=this;if(!q.container){q.container=o.get(q.editorContainer||q.id+"_parent")}return q.container},getContentAreaContainer:function(){return this.contentAreaContainer},getElement:function(){return o.get(this.settings.content_element||this.id)},getWin:function(){var q=this,r;if(!q.contentWindow){r=o.get(q.id+"_ifr");if(r){q.contentWindow=r.contentWindow}}return q.contentWindow},getDoc:function(){var r=this,q;if(!r.contentDocument){q=r.getWin();if(q){r.contentDocument=q.document}}return r.contentDocument},getBody:function(){return this.bodyElement||this.getDoc().body},convertURL:function(q,x,w){var r=this,v=r.settings;if(v.urlconverter_callback){return r.execCallback("urlconverter_callback",q,w,true,x)}if(!v.convert_urls||(w&&w.nodeName=="LINK")||q.indexOf("file:")===0){return q}if(v.relative_urls){return r.documentBaseURI.toRelative(q)}q=r.documentBaseURI.toAbsolute(q,v.remove_script_host);return q},addVisual:function(u){var q=this,r=q.settings;u=u||q.getBody();if(!d(q.hasVisual)){q.hasVisual=r.visual}j(q.dom.select("table,a",u),function(t){var s;switch(t.nodeName){case"TABLE":s=q.dom.getAttrib(t,"border");if(!s||s=="0"){if(q.hasVisual){q.dom.addClass(t,r.visual_table_class)}else{q.dom.removeClass(t,r.visual_table_class)}}return;case"A":s=q.dom.getAttrib(t,"name");if(s){if(q.hasVisual){q.dom.addClass(t,"mceItemAnchor")}else{q.dom.removeClass(t,"mceItemAnchor")}}return}});q.onVisualAid.dispatch(q,u,q.hasVisual)},remove:function(){var q=this,r=q.getContainer();q.removed=1;q.hide();q.execCallback("remove_instance_callback",q);q.onRemove.dispatch(q);q.onExecCommand.listeners=[];i.remove(q);o.remove(r)},destroy:function(r){var q=this;if(q.destroyed){return}if(!r){n.removeUnload(q.destroy);tinyMCE.onBeforeUnload.remove(q._beforeUnload);if(q.theme&&q.theme.destroy){q.theme.destroy()}q.controlManager.destroy();q.selection.destroy();q.dom.destroy();if(!q.settings.content_editable){k.clear(q.getWin());k.clear(q.getDoc())}k.clear(q.getBody());k.clear(q.formElement)}if(q.formElement){q.formElement.submit=q.formElement._mceOldSubmit;q.formElement._mceOldSubmit=null}q.contentAreaContainer=q.formElement=q.container=q.settings.content_element=q.bodyElement=q.contentDocument=q.contentWindow=null;if(q.selection){q.selection=q.selection.win=q.selection.dom=q.selection.dom.doc=null}q.destroyed=1},_addEvents:function(){var w=this,v,y=w.settings,x={mouseup:"onMouseUp",mousedown:"onMouseDown",click:"onClick",keyup:"onKeyUp",keydown:"onKeyDown",keypress:"onKeyPress",submit:"onSubmit",reset:"onReset",contextmenu:"onContextMenu",dblclick:"onDblClick",paste:"onPaste"};function u(t,A){var s=t.type;if(w.removed){return}if(w.onEvent.dispatch(w,t,A)!==false){w[x[t.fakeType||t.type]].dispatch(w,t,A)}}j(x,function(t,s){switch(s){case"contextmenu":if(n.isOpera){k.add(w.getBody(),"mousedown",function(A){if(A.ctrlKey){A.fakeType="contextmenu";u(A)}})}else{k.add(w.getBody(),s,u)}break;case"paste":k.add(w.getBody(),s,function(A){u(A)});break;case"submit":case"reset":k.add(w.getElement().form||o.getParent(w.id,"form"),s,u);break;default:k.add(y.content_editable?w.getBody():w.getDoc(),s,u)}});k.add(y.content_editable?w.getBody():(a?w.getDoc():w.getWin()),"focus",function(s){w.focus(true)});if(n.isGecko){k.add(w.getDoc(),"DOMNodeInserted",function(t){var s;t=t.target;if(t.nodeType===1&&t.nodeName==="IMG"&&(s=t.getAttribute("mce_src"))){t.src=w.documentBaseURI.toAbsolute(s)}})}if(a){function q(){var B=this,D=B.getDoc(),C=B.settings;if(a&&!C.readonly){if(B._isHidden()){try{if(!C.content_editable){D.designMode="On"}}catch(A){}}try{D.execCommand("styleWithCSS",0,false)}catch(A){if(!B._isHidden()){try{D.execCommand("useCSS",0,true)}catch(A){}}}if(!C.table_inline_editing){try{D.execCommand("enableInlineTableEditing",false,false)}catch(A){}}if(!C.object_resizing){try{D.execCommand("enableObjectResizing",false,false)}catch(A){}}}}w.onBeforeExecCommand.add(q);w.onMouseDown.add(q)}w.onMouseUp.add(w.nodeChanged);w.onClick.add(w.nodeChanged);w.onKeyUp.add(function(s,t){var A=t.keyCode;if((A>=33&&A<=36)||(A>=37&&A<=40)||A==13||A==45||A==46||A==8||(n.isMac&&(A==91||A==93))||t.ctrlKey){w.nodeChanged()}});w.onReset.add(function(){w.setContent(w.startContent,{format:"raw"})});if(y.custom_shortcuts){if(y.custom_undo_redo_keyboard_shortcuts){w.addShortcut("ctrl+z",w.getLang("undo_desc"),"Undo");w.addShortcut("ctrl+y",w.getLang("redo_desc"),"Redo")}if(a){w.addShortcut("ctrl+b",w.getLang("bold_desc"),"Bold");w.addShortcut("ctrl+i",w.getLang("italic_desc"),"Italic");w.addShortcut("ctrl+u",w.getLang("underline_desc"),"Underline")}for(v=1;v<=6;v++){w.addShortcut("ctrl+"+v,"",["FormatBlock",false,"<h"+v+">"])}w.addShortcut("ctrl+7","",["FormatBlock",false,"<p>"]);w.addShortcut("ctrl+8","",["FormatBlock",false,"<div>"]);w.addShortcut("ctrl+9","",["FormatBlock",false,"<address>"]);function z(t){var s=null;if(!t.altKey&&!t.ctrlKey&&!t.metaKey){return s}j(w.shortcuts,function(A){if(n.isMac&&A.ctrl!=t.metaKey){return}else{if(!n.isMac&&A.ctrl!=t.ctrlKey){return}}if(A.alt!=t.altKey){return}if(A.shift!=t.shiftKey){return}if(t.keyCode==A.keyCode||(t.charCode&&t.charCode==A.charCode)){s=A;return false}});return s}w.onKeyUp.add(function(s,t){var A=z(t);if(A){return k.cancel(t)}});w.onKeyPress.add(function(s,t){var A=z(t);if(A){return k.cancel(t)}});w.onKeyDown.add(function(s,t){var A=z(t);if(A){A.func.call(A.scope);return k.cancel(t)}})}if(n.isIE){k.add(w.getDoc(),"controlselect",function(A){var t=w.resizeInfo,s;A=A.target;if(A.nodeName!=="IMG"){return}if(t){k.remove(t.node,t.ev,t.cb)}if(!w.dom.hasClass(A,"mceItemNoResize")){ev="resizeend";s=k.add(A,ev,function(C){var B;C=C.target;if(B=w.dom.getStyle(C,"width")){w.dom.setAttrib(C,"width",B.replace(/[^0-9%]+/g,""));w.dom.setStyle(C,"width","")}if(B=w.dom.getStyle(C,"height")){w.dom.setAttrib(C,"height",B.replace(/[^0-9%]+/g,""));w.dom.setStyle(C,"height","")}})}else{ev="resizestart";s=k.add(A,"resizestart",k.cancel,k)}t=w.resizeInfo={node:A,ev:ev,cb:s}});w.onKeyDown.add(function(s,t){switch(t.keyCode){case 8:if(w.selection.getRng().item){w.selection.getRng().item(0).removeNode();return k.cancel(t)}}})}if(n.isOpera){w.onClick.add(function(s,t){k.prevent(t)})}if(y.custom_undo_redo){function r(){w.undoManager.typing=0;w.undoManager.add()}if(n.isIE){k.add(w.getWin(),"blur",function(s){var t;if(w.selection){t=w.selection.getNode();if(!w.removed&&t.ownerDocument&&t.ownerDocument!=w.getDoc()){r()}}})}else{k.add(w.getDoc(),"blur",function(){if(w.selection&&!w.removed){r()}})}w.onMouseDown.add(r);w.onKeyUp.add(function(s,t){if((t.keyCode>=33&&t.keyCode<=36)||(t.keyCode>=37&&t.keyCode<=40)||t.keyCode==13||t.keyCode==45||t.ctrlKey){w.undoManager.typing=0;w.undoManager.add()}});w.onKeyDown.add(function(s,t){if((t.keyCode>=33&&t.keyCode<=36)||(t.keyCode>=37&&t.keyCode<=40)||t.keyCode==13||t.keyCode==45){if(w.undoManager.typing){w.undoManager.add();w.undoManager.typing=0}return}if(!w.undoManager.typing){w.undoManager.add();w.undoManager.typing=1}})}},_convertInlineElements:function(){var z=this,B=z.settings,r=z.dom,y,w,u,A,q;function x(s,t){if(!B.inline_styles){return}if(t.get){j(z.dom.select("table,u,strike",t.node),function(v){switch(v.nodeName){case"TABLE":if(y=r.getAttrib(v,"height")){r.setStyle(v,"height",y);r.setAttrib(v,"height","")}break;case"U":case"STRIKE":v.style.textDecoration=v.nodeName=="U"?"underline":"line-through";r.setAttrib(v,"mce_style","");r.setAttrib(v,"mce_name","span");break}})}else{if(t.set){j(z.dom.select("table,span",t.node).reverse(),function(v){if(v.nodeName=="TABLE"){if(y=r.getStyle(v,"height")){r.setAttrib(v,"height",y.replace(/[^0-9%]+/g,""))}}else{if(v.style.textDecoration=="underline"){u="u"}else{if(v.style.textDecoration=="line-through"){u="strike"}else{u=""}}if(u){v.style.textDecoration="";r.setAttrib(v,"mce_style","");w=r.create(u,{style:r.getAttrib(v,"style")});r.replace(w,v,1)}}})}}}z.onPreProcess.add(x);if(!B.cleanup_on_startup){z.onSetContent.add(function(s,t){if(t.initial){x(z,{node:z.getBody(),set:1})}})}},_convertFonts:function(){var w=this,x=w.settings,z=w.dom,v,r,q,u;if(!x.inline_styles){return}v=[8,10,12,14,18,24,36];r=["xx-small","x-small","small","medium","large","x-large","xx-large"];if(q=x.font_size_style_values){q=g(q)}if(u=x.font_size_classes){u=g(u)}function y(B){var C,A,t,s;if(!x.inline_styles){return}t=w.dom.select("font",B);for(s=t.length-1;s>=0;s--){C=t[s];A=z.create("span",{style:z.getAttrib(C,"style"),"class":z.getAttrib(C,"class")});z.setStyles(A,{fontFamily:z.getAttrib(C,"face"),color:z.getAttrib(C,"color"),backgroundColor:C.style.backgroundColor});if(C.size){if(q){z.setStyle(A,"fontSize",q[parseInt(C.size)-1])}else{z.setAttrib(A,"class",u[parseInt(C.size)-1])}}z.setAttrib(A,"mce_style","");z.replace(A,C,1)}}w.onPreProcess.add(function(s,t){if(t.get){y(t.node)}});w.onSetContent.add(function(s,t){if(t.initial){y(t.node)}})},_isHidden:function(){var q;if(!a){return 0}q=this.selection.getSel();return(!q||!q.rangeCount||q.rangeCount==0)},_fixNesting:function(r){var t=[],q;r=r.replace(/<(\/)?([^\s>]+)[^>]*?>/g,function(u,s,w){var v;if(s==="/"){if(!t.length){return""}if(w!==t[t.length-1].tag){for(q=t.length-1;q>=0;q--){if(t[q].tag===w){t[q].close=1;break}}return""}else{t.pop();if(t.length&&t[t.length-1].close){u=u+"</"+t[t.length-1].tag+">";t.pop()}}}else{if(/^(br|hr|input|meta|img|link|param)$/i.test(w)){return u}if(/\/>$/.test(u)){return u}t.push({tag:w})}return u});for(q=t.length-1;q>=0;q--){r+="</"+t[q].tag+">"}return r}})})(tinymce);(function(d){var f=d.each,c=d.isIE,a=d.isGecko,b=d.isOpera,e=d.isWebKit;d.create("tinymce.EditorCommands",{EditorCommands:function(g){this.editor=g},execCommand:function(k,j,l){var h=this,g=h.editor,i;switch(k){case"mceResetDesignMode":case"mceBeginUndoLevel":return true;case"unlink":h.UnLink();return true;case"JustifyLeft":case"JustifyCenter":case"JustifyRight":case"JustifyFull":h.mceJustify(k,k.substring(7).toLowerCase());return true;default:i=this[k];if(i){i.call(this,j,l);return true}}return false},Indent:function(){var g=this.editor,l=g.dom,j=g.selection,k,h,i;h=g.settings.indentation;i=/[a-z%]+$/i.exec(h);h=parseInt(h);if(g.settings.inline_styles&&(!this.queryStateInsertUnorderedList()&&!this.queryStateInsertOrderedList())){f(j.getSelectedBlocks(),function(m){l.setStyle(m,"paddingLeft",(parseInt(m.style.paddingLeft||0)+h)+i)});return}g.getDoc().execCommand("Indent",false,null);if(c){l.getParent(j.getNode(),function(m){if(m.nodeName=="BLOCKQUOTE"){m.dir=m.style.cssText=""}})}},Outdent:function(){var h=this.editor,m=h.dom,k=h.selection,l,g,i,j;i=h.settings.indentation;j=/[a-z%]+$/i.exec(i);i=parseInt(i);if(h.settings.inline_styles&&(!this.queryStateInsertUnorderedList()&&!this.queryStateInsertOrderedList())){f(k.getSelectedBlocks(),function(n){g=Math.max(0,parseInt(n.style.paddingLeft||0)-i);m.setStyle(n,"paddingLeft",g?g+j:"")});return}h.getDoc().execCommand("Outdent",false,null)},mceSetContent:function(h,g){this.editor.setContent(g)},mceToggleVisualAid:function(){var g=this.editor;g.hasVisual=!g.hasVisual;g.addVisual()},mceReplaceContent:function(h,g){var i=this.editor.selection;i.setContent(g.replace(/\{\$selection\}/g,i.getContent({format:"text"})))},mceInsertLink:function(i,h){var g=this.editor,j=g.selection,k=g.dom.getParent(j.getNode(),"a");if(d.is(h,"string")){h={href:h}}function l(m){f(h,function(o,n){g.dom.setAttrib(m,n,o)})}if(!k){g.execCommand("CreateLink",false,"javascript:mctmp(0);");f(g.dom.select("a[href=javascript:mctmp(0);]"),function(m){l(m)})}else{if(h.href){l(k)}else{g.dom.remove(k,1)}}},UnLink:function(){var g=this.editor,h=g.selection;if(h.isCollapsed()){h.select(h.getNode())}g.getDoc().execCommand("unlink",false,null);h.collapse(0)},FontName:function(i,h){var j=this,g=j.editor,k=g.selection,l;if(!h){if(k.isCollapsed()){k.select(k.getNode())}}else{if(g.settings.convert_fonts_to_spans){j._applyInlineStyle("span",{style:{fontFamily:h}})}else{g.getDoc().execCommand("FontName",false,h)}}},FontSize:function(j,i){var h=this.editor,l=h.settings,k,g;if(l.convert_fonts_to_spans&&i>=1&&i<=7){g=d.explode(l.font_size_style_values);k=d.explode(l.font_size_classes);if(k){i=k[i-1]||i}else{i=g[i-1]||i}}if(i>=1&&i<=7){h.getDoc().execCommand("FontSize",false,i)}else{this._applyInlineStyle("span",{style:{fontSize:i}})}},queryCommandValue:function(h){var g=this["queryValue"+h];if(g){return g.call(this,h)}return false},queryCommandState:function(h){var g;switch(h){case"JustifyLeft":case"JustifyCenter":case"JustifyRight":case"JustifyFull":return this.queryStateJustify(h,h.substring(7).toLowerCase());default:if(g=this["queryState"+h]){return g.call(this,h)}}return -1},_queryState:function(h){try{return this.editor.getDoc().queryCommandState(h)}catch(g){}},_queryVal:function(h){try{return this.editor.getDoc().queryCommandValue(h)}catch(g){}},queryValueFontSize:function(){var h=this.editor,g=0,i;if(i=h.dom.getParent(h.selection.getNode(),"span")){g=i.style.fontSize}if(!g&&(b||e)){if(i=h.dom.getParent(h.selection.getNode(),"font")){g=i.size}return g}return g||this._queryVal("FontSize")},queryValueFontName:function(){var h=this.editor,g=0,i;if(i=h.dom.getParent(h.selection.getNode(),"font")){g=i.face}if(i=h.dom.getParent(h.selection.getNode(),"span")){g=i.style.fontFamily.replace(/, /g,",").replace(/[\'\"]/g,"").toLowerCase()}if(!g){g=this._queryVal("FontName")}return g},mceJustify:function(o,p){var k=this.editor,m=k.selection,g=m.getNode(),q=g.nodeName,h,j,i=k.dom,l;if(k.settings.inline_styles&&this.queryStateJustify(o,p)){l=1}h=i.getParent(g,k.dom.isBlock);if(q=="IMG"){if(p=="full"){return}if(l){if(p=="center"){i.setStyle(h||g.parentNode,"textAlign","")}i.setStyle(g,"float","");this.mceRepaint();return}if(p=="center"){if(h&&/^(TD|TH)$/.test(h.nodeName)){h=0}if(!h||h.childNodes.length>1){j=i.create("p");j.appendChild(g.cloneNode(false));if(h){i.insertAfter(j,h)}else{i.insertAfter(j,g)}i.remove(g);g=j.firstChild;h=j}i.setStyle(h,"textAlign",p);i.setStyle(g,"float","")}else{i.setStyle(g,"float",p);i.setStyle(h||g.parentNode,"textAlign","")}this.mceRepaint();return}if(k.settings.inline_styles&&k.settings.forced_root_block){if(l){p=""}f(m.getSelectedBlocks(i.getParent(m.getStart(),i.isBlock),i.getParent(m.getEnd(),i.isBlock)),function(n){i.setAttrib(n,"align","");i.setStyle(n,"textAlign",p=="full"?"justify":p)});return}else{if(!l){k.getDoc().execCommand(o,false,null)}}if(k.settings.inline_styles){if(l){i.getParent(k.selection.getNode(),function(r){if(r.style&&r.style.textAlign){i.setStyle(r,"textAlign","")}});return}f(i.select("*"),function(s){var r=s.align;if(r){if(r=="full"){r="justify"}i.setStyle(s,"textAlign",r);i.setAttrib(s,"align","")}})}},mceSetCSSClass:function(h,g){this.mceSetStyleInfo(0,{command:"setattrib",name:"class",value:g})},getSelectedElement:function(){var w=this,o=w.editor,n=o.dom,s=o.selection,h=s.getRng(),l,k,u,p,j,g,q,i,x,v;if(s.isCollapsed()||h.item){return s.getNode()}v=o.settings.merge_styles_invalid_parents;if(d.is(v,"string")){v=new RegExp(v,"i")}if(c){l=h.duplicate();l.collapse(true);u=l.parentElement();k=h.duplicate();k.collapse(false);p=k.parentElement();if(u!=p){l.move("character",1);u=l.parentElement()}if(u==p){l=h.duplicate();l.moveToElementText(u);if(l.compareEndPoints("StartToStart",h)==0&&l.compareEndPoints("EndToEnd",h)==0){return v&&v.test(u.nodeName)?null:u}}}else{function m(r){return n.getParent(r,"*")}u=h.startContainer;p=h.endContainer;j=h.startOffset;g=h.endOffset;if(!h.collapsed){if(u==p){if(j-g<2){if(u.hasChildNodes()){i=u.childNodes[j];return v&&v.test(i.nodeName)?null:i}}}}if(u.nodeType!=3||p.nodeType!=3){return null}if(j==0){i=m(u);if(i&&i.firstChild!=u){i=null}}if(j==u.nodeValue.length){q=u.nextSibling;if(q&&q.nodeType==1){i=u.nextSibling}}if(g==0){q=p.previousSibling;if(q&&q.nodeType==1){x=q}}if(g==p.nodeValue.length){x=m(p);if(x&&x.lastChild!=p){x=null}}if(i==x){return v&&i&&v.test(i.nodeName)?null:i}}return null},mceSetStyleInfo:function(n,m){var q=this,h=q.editor,j=h.getDoc(),g=h.dom,i,k,r=h.selection,p=m.wrapper||"span",k=r.getBookmark(),o;function l(t,s){if(t.nodeType==1){switch(m.command){case"setattrib":return g.setAttrib(t,m.name,m.value);case"setstyle":return g.setStyle(t,m.name,m.value);case"removeformat":return g.setAttrib(t,"class","")}}}o=h.settings.merge_styles_invalid_parents;if(d.is(o,"string")){o=new RegExp(o,"i")}if((i=q.getSelectedElement())&&!h.settings.force_span_wrappers){l(i,1)}else{j.execCommand("FontName",false,"__");f(g.select("span,font"),function(u){var s,t;if(g.getAttrib(u,"face")=="__"||u.style.fontFamily==="__"){s=g.create(p,{mce_new:"1"});l(s);f(u.childNodes,function(v){s.appendChild(v.cloneNode(true))});g.replace(s,u)}})}f(g.select(p).reverse(),function(t){var s=t.parentNode;if(!g.getAttrib(t,"mce_new")){s=g.getParent(t,"*[mce_new]");if(s){g.remove(t,1)}}});f(g.select(p).reverse(),function(t){var s=t.parentNode;if(!s||!g.getAttrib(t,"mce_new")){return}if(h.settings.force_span_wrappers&&s.nodeName!="SPAN"){return}if(s.nodeName==p.toUpperCase()&&s.childNodes.length==1){return g.remove(s,1)}if(t.nodeType==1&&(!o||!o.test(s.nodeName))&&s.childNodes.length==1){l(s);g.setAttrib(t,"class","")}});f(g.select(p).reverse(),function(s){if(g.getAttrib(s,"mce_new")||(g.getAttribs(s).length<=1&&s.className==="")){if(!g.getAttrib(s,"class")&&!g.getAttrib(s,"style")){return g.remove(s,1)}g.setAttrib(s,"mce_new","")}});r.moveToBookmark(k)},queryStateJustify:function(k,h){var g=this.editor,j=g.selection.getNode(),i=g.dom;if(j&&j.nodeName=="IMG"){if(i.getStyle(j,"float")==h){return 1}return j.parentNode.style.textAlign==h}j=i.getParent(g.selection.getStart(),function(l){return l.nodeType==1&&l.style.textAlign});if(h=="full"){h="justify"}if(g.settings.inline_styles){return(j&&j.style.textAlign==h)}return this._queryState(k)},ForeColor:function(i,h){var g=this.editor;if(g.settings.convert_fonts_to_spans){this._applyInlineStyle("span",{style:{color:h}});return}else{g.getDoc().execCommand("ForeColor",false,h)}},HiliteColor:function(i,k){var h=this,g=h.editor,j=g.getDoc();if(g.settings.convert_fonts_to_spans){this._applyInlineStyle("span",{style:{backgroundColor:k}});return}function l(n){if(!a){return}try{j.execCommand("styleWithCSS",0,n)}catch(m){j.execCommand("useCSS",0,!n)}}if(a||b){l(true);j.execCommand("hilitecolor",false,k);l(false)}else{j.execCommand("BackColor",false,k)}},FormatBlock:function(n,h){var o=this,l=o.editor,p=l.selection,j=l.dom,g,k,m;function i(q){return/^(P|DIV|H[1-6]|ADDRESS|BLOCKQUOTE|PRE)$/.test(q.nodeName)}g=j.getParent(p.getNode(),function(q){return i(q)});if(g){if((c&&i(g.parentNode))||g.nodeName=="DIV"){k=l.dom.create(h);f(j.getAttribs(g),function(q){j.setAttrib(k,q.nodeName,j.getAttrib(g,q.nodeName))});m=p.getBookmark();j.replace(k,g,1);p.moveToBookmark(m);l.nodeChanged();return}}h=l.settings.forced_root_block?(h||"<p>"):h;if(h.indexOf("<")==-1){h="<"+h+">"}if(d.isGecko){h=h.replace(/<(div|blockquote|code|dt|dd|dl|samp)>/gi,"$1")}l.getDoc().execCommand("FormatBlock",false,h)},mceCleanup:function(){var h=this.editor,i=h.selection,g=i.getBookmark();h.setContent(h.getContent());i.moveToBookmark(g)},mceRemoveNode:function(j,k){var h=this.editor,i=h.selection,g,l=k||i.getNode();if(l==h.getBody()){return}g=i.getBookmark();h.dom.remove(l,1);i.moveToBookmark(g);h.nodeChanged()},mceSelectNodeDepth:function(i,j){var g=this.editor,h=g.selection,k=0;g.dom.getParent(h.getNode(),function(l){if(l.nodeType==1&&k++==j){h.select(l);g.nodeChanged();return false}},g.getBody())},mceSelectNode:function(h,g){this.editor.selection.select(g)},mceInsertContent:function(g,h){this.editor.selection.setContent(h)},mceInsertRawHTML:function(h,i){var g=this.editor;g.selection.setContent("tiny_mce_marker");g.setContent(g.getContent().replace(/tiny_mce_marker/g,i))},mceRepaint:function(){var i,g,j=this.editor;if(d.isGecko){try{i=j.selection;g=i.getBookmark(true);if(i.getSel()){i.getSel().selectAllChildren(j.getBody())}i.collapse(true);i.moveToBookmark(g)}catch(h){}}},queryStateUnderline:function(){var g=this.editor,h=g.selection.getNode();if(h&&h.nodeName=="A"){return false}return this._queryState("Underline")},queryStateOutdent:function(){var g=this.editor,h;if(g.settings.inline_styles){if((h=g.dom.getParent(g.selection.getStart(),g.dom.isBlock))&&parseInt(h.style.paddingLeft)>0){return true}if((h=g.dom.getParent(g.selection.getEnd(),g.dom.isBlock))&&parseInt(h.style.paddingLeft)>0){return true}}return this.queryStateInsertUnorderedList()||this.queryStateInsertOrderedList()||(!g.settings.inline_styles&&!!g.dom.getParent(g.selection.getNode(),"BLOCKQUOTE"))},queryStateInsertUnorderedList:function(){return this.editor.dom.getParent(this.editor.selection.getNode(),"UL")},queryStateInsertOrderedList:function(){return this.editor.dom.getParent(this.editor.selection.getNode(),"OL")},queryStatemceBlockQuote:function(){return !!this.editor.dom.getParent(this.editor.selection.getStart(),function(g){return g.nodeName==="BLOCKQUOTE"})},_applyInlineStyle:function(o,j,m){var q=this,n=q.editor,l=n.dom,i,p={},k,r;o=o.toUpperCase();if(m&&m.check_classes&&j["class"]){m.check_classes.push(j["class"])}function h(){f(l.select(o).reverse(),function(t){var s=0;f(l.getAttribs(t),function(u){if(u.nodeName.substring(0,1)!="_"&&l.getAttrib(t,u.nodeName)!=""){s++}});if(s==0){l.remove(t,1)}})}function g(){var s;f(l.select("span,font"),function(t){if(t.style.fontFamily=="mceinline"||t.face=="mceinline"){if(!s){s=n.selection.getBookmark()}j._mce_new="1";l.replace(l.create(o,j),t,1)}});f(l.select(o+"[_mce_new]"),function(u){function t(v){if(v.nodeType==1){f(j.style,function(x,w){l.setStyle(v,w,"")});if(j["class"]&&v.className&&m){f(m.check_classes,function(w){if(l.hasClass(v,w)){l.removeClass(v,w)}})}}}f(l.select(o,u),t);if(u.parentNode&&u.parentNode.nodeType==1&&u.parentNode.childNodes.length==1){t(u.parentNode)}l.getParent(u.parentNode,function(v){if(v.nodeType==1){if(j.style){f(j.style,function(y,x){var w;if(!p[x]&&(w=l.getStyle(v,x))){if(w===y){l.setStyle(u,x,"")}p[x]=1}})}if(j["class"]&&v.className&&m){f(m.check_classes,function(w){if(l.hasClass(v,w)){l.removeClass(u,w)}})}}return false});u.removeAttribute("_mce_new")});h();n.selection.moveToBookmark(s);return !!s}n.focus();n.getDoc().execCommand("FontName",false,"mceinline");g();if(k=q._applyInlineStyle.keyhandler){n.onKeyUp.remove(k);n.onKeyPress.remove(k);n.onKeyDown.remove(k);n.onSetContent.remove(q._applyInlineStyle.chandler)}if(n.selection.isCollapsed()){if(!c){f(l.getParents(n.selection.getNode(),"span"),function(s){f(j.style,function(u,t){var w;if(w=l.getStyle(s,t)){if(w==u){l.setStyle(s,t,"");r=2;return false}r=1;return false}});if(r){return false}});if(r==2){i=n.selection.getBookmark();h();n.selection.moveToBookmark(i);window.setTimeout(function(){n.nodeChanged()},1);return}}q._pendingStyles=d.extend(q._pendingStyles||{},j.style);q._applyInlineStyle.chandler=n.onSetContent.add(function(){delete q._pendingStyles});q._applyInlineStyle.keyhandler=k=function(s){if(q._pendingStyles){j.style=q._pendingStyles;delete q._pendingStyles}if(g()){n.onKeyDown.remove(q._applyInlineStyle.keyhandler);n.onKeyPress.remove(q._applyInlineStyle.keyhandler)}if(s.type=="keyup"){n.onKeyUp.remove(q._applyInlineStyle.keyhandler)}};n.onKeyDown.add(k);n.onKeyPress.add(k);n.onKeyUp.add(k)}else{q._pendingStyles=0}}})})(tinymce);(function(a){a.create("tinymce.UndoManager",{index:0,data:null,typing:0,UndoManager:function(c){var d=this,b=a.util.Dispatcher;d.editor=c;d.data=[];d.onAdd=new b(this);d.onUndo=new b(this);d.onRedo=new b(this)},add:function(d){var g=this,f,e=g.editor,c,h=e.settings,j;d=d||{};d.content=d.content||e.getContent({format:"raw",no_events:1});d.content=d.content.replace(/^\s*|\s*$/g,"");j=g.data[g.index>0&&(g.index==0||g.index==g.data.length)?g.index-1:g.index];if(!d.initial&&j&&d.content==j.content){return null}if(h.custom_undo_redo_levels){if(g.data.length>h.custom_undo_redo_levels){for(f=0;f<g.data.length-1;f++){g.data[f]=g.data[f+1]}g.data.length--;g.index=g.data.length}}if(h.custom_undo_redo_restore_selection&&!d.initial){d.bookmark=c=d.bookmark||e.selection.getBookmark()}if(g.index<g.data.length){g.index++}if(g.data.length===0&&!d.initial){return null}g.data.length=g.index+1;g.data[g.index++]=d;if(d.initial){g.index=0}if(g.data.length==2&&g.data[0].initial){g.data[0].bookmark=c}g.onAdd.dispatch(g,d);e.isNotDirty=0;return d},undo:function(){var e=this,c=e.editor,b=b,d;if(e.typing){e.add();e.typing=0}if(e.index>0){if(e.index==e.data.length&&e.index>1){d=e.index;e.typing=0;if(!e.add()){e.index=d}--e.index}b=e.data[--e.index];c.setContent(b.content,{format:"raw"});c.selection.moveToBookmark(b.bookmark);e.onUndo.dispatch(e,b)}return b},redo:function(){var d=this,c=d.editor,b=null;if(d.index<d.data.length-1){b=d.data[++d.index];c.setContent(b.content,{format:"raw"});c.selection.moveToBookmark(b.bookmark);d.onRedo.dispatch(d,b)}return b},clear:function(){var b=this;b.data=[];b.index=0;b.typing=0;b.add({initial:true})},hasUndo:function(){return this.index!=0||this.typing},hasRedo:function(){return this.index<this.data.length-1}})})(tinymce);(function(e){var b,d,a,c,f,h;b=e.dom.Event;d=e.isIE;a=e.isGecko;c=e.isOpera;f=e.each;h=e.extend;function g(i){i=i.innerHTML;i=i.replace(/<\w+ .*?mce_\w+\"?=.*?>/gi,"-");i=i.replace(/<(img|hr|table)/gi,"-");i=i.replace(/<[^>]+>/g,"");return i.replace(/[ \t\r\n]+/g,"")==""}e.create("tinymce.ForceBlocks",{ForceBlocks:function(j){var k=this,l=j.settings,m;k.editor=j;k.dom=j.dom;m=(l.forced_root_block||"p").toLowerCase();l.element=m.toUpperCase();j.onPreInit.add(k.setup,k);k.reOpera=new RegExp("(\\u00a0|&#160;|&nbsp;)</"+m+">","gi");k.rePadd=new RegExp("<p( )([^>]+)><\\/p>|<p( )([^>]+)\\/>|<p( )([^>]+)>\\s+<\\/p>|<p><\\/p>|<p\\/>|<p>\\s+<\\/p>".replace(/p/g,m),"gi");k.reNbsp2BR1=new RegExp("<p( )([^>]+)>[\\s\\u00a0]+<\\/p>|<p>[\\s\\u00a0]+<\\/p>".replace(/p/g,m),"gi");k.reNbsp2BR2=new RegExp("<%p()([^>]+)>(&nbsp;|&#160;)<\\/%p>|<%p>(&nbsp;|&#160;)<\\/%p>".replace(/%p/g,m),"gi");k.reBR2Nbsp=new RegExp("<p( )([^>]+)>\\s*<br \\/>\\s*<\\/p>|<p>\\s*<br \\/>\\s*<\\/p>".replace(/p/g,m),"gi");function i(n,p){if(c){p.content=p.content.replace(k.reOpera,"</"+m+">")}p.content=p.content.replace(k.rePadd,"<"+m+"$1$2$3$4$5$6>\u00a0</"+m+">");if(!d&&!c&&p.set){p.content=p.content.replace(k.reNbsp2BR1,"<"+m+"$1$2><br /></"+m+">");p.content=p.content.replace(k.reNbsp2BR2,"<"+m+"$1$2><br /></"+m+">")}else{p.content=p.content.replace(k.reBR2Nbsp,"<"+m+"$1$2>\u00a0</"+m+">")}}j.onBeforeSetContent.add(i);j.onPostProcess.add(i);if(l.forced_root_block){j.onInit.add(k.forceRoots,k);j.onSetContent.add(k.forceRoots,k);j.onBeforeGetContent.add(k.forceRoots,k)}},setup:function(){var j=this,i=j.editor,k=i.settings;if(k.forced_root_block){i.onKeyUp.add(j.forceRoots,j);i.onPreProcess.add(j.forceRoots,j)}if(k.force_br_newlines){if(d){i.onKeyPress.add(function(m,p){var q,o=m.selection;if(p.keyCode==13&&o.getNode().nodeName!="LI"){o.setContent('<br id="__" /> ',{format:"raw"});q=m.dom.get("__");q.removeAttribute("id");o.select(q);o.collapse();return b.cancel(p)}})}return}if(!d&&k.force_p_newlines){i.onKeyPress.add(function(m,n){if(n.keyCode==13&&!n.shiftKey){if(!j.insertPara(n)){b.cancel(n)}}});if(a){i.onKeyDown.add(function(m,n){if((n.keyCode==8||n.keyCode==46)&&!n.shiftKey){j.backspaceDelete(n,n.keyCode==8)}})}}function l(n,m){var o=i.dom.create(m);f(n.attributes,function(p){if(p.specified&&p.nodeValue){o.setAttribute(p.nodeName.toLowerCase(),p.nodeValue)}});f(n.childNodes,function(p){o.appendChild(p.cloneNode(true))});n.parentNode.replaceChild(o,n);return o}if(d){i.onPreProcess.add(function(m,n){f(m.dom.select("p,h1,h2,h3,h4,h5,h6,div",n.node),function(o){if(g(o)){o.innerHTML=""}})});if(k.element!="P"){i.onKeyPress.add(function(m,n){j.lastElm=m.selection.getNode().nodeName});i.onKeyUp.add(function(o,q){var s,p=o.selection,r=p.getNode(),m=o.getBody();if(m.childNodes.length===1&&r.nodeName=="P"){r=l(r,k.element);p.select(r);p.collapse();o.nodeChanged()}else{if(q.keyCode==13&&!q.shiftKey&&j.lastElm!="P"){s=o.dom.getParent(r,"p");if(s){l(s,k.element);o.nodeChanged()}}}})}}},find:function(o,k,l){var j=this.editor,i=j.getDoc().createTreeWalker(o,4,null,false),m=-1;while(o=i.nextNode()){m++;if(k==0&&o==l){return m}if(k==1&&m==l){return o}}return -1},forceRoots:function(p,D){var u=this,p=u.editor,H=p.getBody(),E=p.getDoc(),K=p.selection,v=K.getSel(),w=K.getRng(),I=-2,o,B,j,k,F=-16777215;var G,l,J,A,x,m=H.childNodes,z,y,q;for(z=m.length-1;z>=0;z--){G=m[z];if(G.nodeType==3||(!u.dom.isBlock(G)&&G.nodeType!=8)){if(!l){if(G.nodeType!=3||/[^\s]/g.test(G.nodeValue)){if(I==-2&&w){if(!d){if(w.startContainer.nodeType==1&&(y=w.startContainer.childNodes[w.startOffset])&&y.nodeType==1){q=y.getAttribute("id");y.setAttribute("id","__mce")}else{if(p.dom.getParent(w.startContainer,function(i){return i===H})){B=w.startOffset;j=w.endOffset;I=u.find(H,0,w.startContainer);o=u.find(H,0,w.endContainer)}}}else{k=E.body.createTextRange();k.moveToElementText(H);k.collapse(1);J=k.move("character",F)*-1;k=w.duplicate();k.collapse(1);A=k.move("character",F)*-1;k=w.duplicate();k.collapse(0);x=(k.move("character",F)*-1)-A;I=A-J;o=x}}l=p.dom.create(p.settings.forced_root_block);l.appendChild(G.cloneNode(1));G.parentNode.replaceChild(l,G)}}else{if(l.hasChildNodes()){l.insertBefore(G,l.firstChild)}else{l.appendChild(G)}}}else{l=null}}if(I!=-2){if(!d){l=H.getElementsByTagName(p.settings.element)[0];w=E.createRange();if(I!=-1){w.setStart(u.find(H,1,I),B)}else{w.setStart(l,0)}if(o!=-1){w.setEnd(u.find(H,1,o),j)}else{w.setEnd(l,0)}if(v){v.removeAllRanges();v.addRange(w)}}else{try{w=v.createRange();w.moveToElementText(H);w.collapse(1);w.moveStart("character",I);w.moveEnd("character",o);w.select()}catch(C){}}}else{if(!d&&(y=p.dom.get("__mce"))){if(q){y.setAttribute("id",q)}else{y.removeAttribute("id")}w=E.createRange();w.setStartBefore(y);w.setEndBefore(y);K.setRng(w)}}},getParentBlock:function(j){var i=this.dom;return i.getParent(j,i.isBlock)},insertPara:function(M){var A=this,o=A.editor,I=o.dom,N=o.getDoc(),R=o.settings,B=o.selection.getSel(),C=B.getRangeAt(0),Q=N.body;var F,G,D,K,J,l,j,m,q,i,x,P,k,p,E,H=I.getViewPort(o.getWin()),w,z,v;F=N.createRange();F.setStart(B.anchorNode,B.anchorOffset);F.collapse(true);G=N.createRange();G.setStart(B.focusNode,B.focusOffset);G.collapse(true);D=F.compareBoundaryPoints(F.START_TO_END,G)<0;K=D?B.anchorNode:B.focusNode;J=D?B.anchorOffset:B.focusOffset;l=D?B.focusNode:B.anchorNode;j=D?B.focusOffset:B.anchorOffset;if(K===l&&/^(TD|TH)$/.test(K.nodeName)){I.remove(K.firstChild);o.dom.add(K,R.element,null,"<br />");P=o.dom.add(K,R.element,null,"<br />");C=N.createRange();C.selectNodeContents(P);C.collapse(1);o.selection.setRng(C);return false}if(K==Q&&l==Q&&Q.firstChild&&o.dom.isBlock(Q.firstChild)){K=l=K.firstChild;J=j=0;F=N.createRange();F.setStart(K,0);G=N.createRange();G.setStart(l,0)}K=K.nodeName=="HTML"?N.body:K;K=K.nodeName=="BODY"?K.firstChild:K;l=l.nodeName=="HTML"?N.body:l;l=l.nodeName=="BODY"?l.firstChild:l;m=A.getParentBlock(K);q=A.getParentBlock(l);i=m?m.nodeName:R.element;if(A.dom.getParent(m,"ol,ul,pre")){return true}if(m&&(m.nodeName=="CAPTION"||/absolute|relative|fixed/gi.test(I.getStyle(m,"position",1)))){i=R.element;m=null}if(q&&(q.nodeName=="CAPTION"||/absolute|relative|fixed/gi.test(I.getStyle(m,"position",1)))){i=R.element;q=null}if(/(TD|TABLE|TH|CAPTION)/.test(i)||(m&&i=="DIV"&&/left|right/gi.test(I.getStyle(m,"float",1)))){i=R.element;m=q=null}x=(m&&m.nodeName==i)?m.cloneNode(0):o.dom.create(i);P=(q&&q.nodeName==i)?q.cloneNode(0):o.dom.create(i);P.removeAttribute("id");if(/^(H[1-6])$/.test(i)&&K.nodeValue&&J==K.nodeValue.length){P=o.dom.create(R.element)}E=k=K;do{if(E==Q||E.nodeType==9||A.dom.isBlock(E)||/(TD|TABLE|TH|CAPTION)/.test(E.nodeName)){break}k=E}while((E=E.previousSibling?E.previousSibling:E.parentNode));E=p=l;do{if(E==Q||E.nodeType==9||A.dom.isBlock(E)||/(TD|TABLE|TH|CAPTION)/.test(E.nodeName)){break}p=E}while((E=E.nextSibling?E.nextSibling:E.parentNode));if(k.nodeName==i){F.setStart(k,0)}else{F.setStartBefore(k)}F.setEnd(K,J);x.appendChild(F.cloneContents()||N.createTextNode(""));try{G.setEndAfter(p)}catch(L){}G.setStart(l,j);P.appendChild(G.cloneContents()||N.createTextNode(""));C=N.createRange();if(!k.previousSibling&&k.parentNode.nodeName==i){C.setStartBefore(k.parentNode)}else{if(F.startContainer.nodeName==i&&F.startOffset==0){C.setStartBefore(F.startContainer)}else{C.setStart(F.startContainer,F.startOffset)}}if(!p.nextSibling&&p.parentNode.nodeName==i){C.setEndAfter(p.parentNode)}else{C.setEnd(G.endContainer,G.endOffset)}C.deleteContents();if(c){o.getWin().scrollTo(0,H.y)}if(x.firstChild&&x.firstChild.nodeName==i){x.innerHTML=x.firstChild.innerHTML}if(P.firstChild&&P.firstChild.nodeName==i){P.innerHTML=P.firstChild.innerHTML}if(g(x)){x.innerHTML="<br />"}function O(y,s){var r=[],T,S,t;y.innerHTML="";if(R.keep_styles){S=s;do{if(/^(SPAN|STRONG|B|EM|I|FONT|STRIKE|U)$/.test(S.nodeName)){T=S.cloneNode(false);I.setAttrib(T,"id","");r.push(T)}}while(S=S.parentNode)}if(r.length>0){for(t=r.length-1,T=y;t>=0;t--){T=T.appendChild(r[t])}r[0].innerHTML=c?"&nbsp;":"<br />";return r[0]}else{y.innerHTML=c?"&nbsp;":"<br />"}}if(g(P)){v=O(P,l)}if(c&&parseFloat(opera.version())<9.5){C.insertNode(x);C.insertNode(P)}else{C.insertNode(P);C.insertNode(x)}P.normalize();x.normalize();function u(r){return N.createTreeWalker(r,NodeFilter.SHOW_TEXT,null,false).nextNode()||r}C=N.createRange();C.selectNodeContents(a?u(v||P):v||P);C.collapse(1);B.removeAllRanges();B.addRange(C);w=o.dom.getPos(P).y;z=P.clientHeight;if(w<H.y||w+z>H.y+H.h){o.getWin().scrollTo(0,w<H.y?w:w-H.h+25)}return false},backspaceDelete:function(l,u){var x=this,k=x.editor,p=k.getBody(),j,m=k.selection,i=m.getRng(),o=i.startContainer,j,q,s;if(o&&k.dom.isBlock(o)&&!/^(TD|TH)$/.test(o.nodeName)&&u){if(o.childNodes.length==0||(o.childNodes.length==1&&o.firstChild.nodeName=="BR")){j=o;while((j=j.previousSibling)&&!k.dom.isBlock(j)){}if(j){if(o!=p.firstChild){q=k.dom.doc.createTreeWalker(j,NodeFilter.SHOW_TEXT,null,false);while(s=q.nextNode()){j=s}i=k.getDoc().createRange();i.setStart(j,j.nodeValue?j.nodeValue.length:0);i.setEnd(j,j.nodeValue?j.nodeValue.length:0);m.setRng(i);k.dom.remove(o)}return b.cancel(l)}}}function v(n){var r;n=n.target;if(n&&n.parentNode&&n.nodeName=="BR"&&(j=x.getParentBlock(n))){r=n.previousSibling;b.remove(p,"DOMNodeInserted",v);if(r&&r.nodeType==3&&/\s+$/.test(r.nodeValue)){return}if(n.previousSibling||n.nextSibling){k.dom.remove(n)}}}b._add(p,"DOMNodeInserted",v);window.setTimeout(function(){b._remove(p,"DOMNodeInserted",v)},1)}})})(tinymce);(function(c){var b=c.DOM,a=c.dom.Event,d=c.each,e=c.extend;c.create("tinymce.ControlManager",{ControlManager:function(f,j){var h=this,g;j=j||{};h.editor=f;h.controls={};h.onAdd=new c.util.Dispatcher(h);h.onPostRender=new c.util.Dispatcher(h);h.prefix=j.prefix||f.id+"_";h._cls={};h.onPostRender.add(function(){d(h.controls,function(i){i.postRender()})})},get:function(f){return this.controls[this.prefix+f]||this.controls[f]},setActive:function(h,f){var g=null;if(g=this.get(h)){g.setActive(f)}return g},setDisabled:function(h,f){var g=null;if(g=this.get(h)){g.setDisabled(f)}return g},add:function(g){var f=this;if(g){f.controls[g.id]=g;f.onAdd.dispatch(g,f)}return g},createControl:function(i){var h,g=this,f=g.editor;d(f.plugins,function(j){if(j.createControl){h=j.createControl(i,g);if(h){return false}}});switch(i){case"|":case"separator":return g.createSeparator()}if(!h&&f.buttons&&(h=f.buttons[i])){return g.createButton(i,h)}return g.add(h)},createDropMenu:function(f,n,h){var m=this,i=m.editor,j,g,k,l;n=e({"class":"mceDropDown",constrain:i.settings.constrain_menus},n);n["class"]=n["class"]+" "+i.getParam("skin")+"Skin";if(k=i.getParam("skin_variant")){n["class"]+=" "+i.getParam("skin")+"Skin"+k.substring(0,1).toUpperCase()+k.substring(1)}f=m.prefix+f;l=h||m._cls.dropmenu||c.ui.DropMenu;j=m.controls[f]=new l(f,n);j.onAddItem.add(function(r,q){var p=q.settings;p.title=i.getLang(p.title,p.title);if(!p.onclick){p.onclick=function(o){i.execCommand(p.cmd,p.ui||false,p.value)}}});i.onRemove.add(function(){j.destroy()});if(c.isIE){j.onShowMenu.add(function(){i.focus();g=i.selection.getBookmark(1)});j.onHideMenu.add(function(){if(g){i.selection.moveToBookmark(g);g=0}})}return m.add(j)},createListBox:function(m,i,l){var h=this,g=h.editor,j,k,f;if(h.get(m)){return null}i.title=g.translate(i.title);i.scope=i.scope||g;if(!i.onselect){i.onselect=function(n){g.execCommand(i.cmd,i.ui||false,n||i.value)}}i=e({title:i.title,"class":"mce_"+m,scope:i.scope,control_manager:h},i);m=h.prefix+m;if(g.settings.use_native_selects){k=new c.ui.NativeListBox(m,i)}else{f=l||h._cls.listbox||c.ui.ListBox;k=new f(m,i)}h.controls[m]=k;if(c.isWebKit){k.onPostRender.add(function(p,o){a.add(o,"mousedown",function(){g.bookmark=g.selection.getBookmark("simple")});a.add(o,"focus",function(){g.selection.moveToBookmark(g.bookmark);g.bookmark=null})})}if(k.hideMenu){g.onMouseDown.add(k.hideMenu,k)}return h.add(k)},createButton:function(m,i,l){var h=this,g=h.editor,j,k,f;if(h.get(m)){return null}i.title=g.translate(i.title);i.label=g.translate(i.label);i.scope=i.scope||g;if(!i.onclick&&!i.menu_button){i.onclick=function(){g.execCommand(i.cmd,i.ui||false,i.value)}}i=e({title:i.title,"class":"mce_"+m,unavailable_prefix:g.getLang("unavailable",""),scope:i.scope,control_manager:h},i);m=h.prefix+m;if(i.menu_button){f=l||h._cls.menubutton||c.ui.MenuButton;k=new f(m,i);g.onMouseDown.add(k.hideMenu,k)}else{f=h._cls.button||c.ui.Button;k=new f(m,i)}return h.add(k)},createMenuButton:function(h,f,g){f=f||{};f.menu_button=1;return this.createButton(h,f,g)},createSplitButton:function(m,i,l){var h=this,g=h.editor,j,k,f;if(h.get(m)){return null}i.title=g.translate(i.title);i.scope=i.scope||g;if(!i.onclick){i.onclick=function(n){g.execCommand(i.cmd,i.ui||false,n||i.value)}}if(!i.onselect){i.onselect=function(n){g.execCommand(i.cmd,i.ui||false,n||i.value)}}i=e({title:i.title,"class":"mce_"+m,scope:i.scope,control_manager:h},i);m=h.prefix+m;f=l||h._cls.splitbutton||c.ui.SplitButton;k=h.add(new f(m,i));g.onMouseDown.add(k.hideMenu,k);return k},createColorSplitButton:function(f,n,h){var l=this,j=l.editor,i,k,m,g;if(l.get(f)){return null}n.title=j.translate(n.title);n.scope=n.scope||j;if(!n.onclick){n.onclick=function(o){if(c.isIE){g=j.selection.getBookmark(1)}j.execCommand(n.cmd,n.ui||false,o||n.value)}}if(!n.onselect){n.onselect=function(o){j.execCommand(n.cmd,n.ui||false,o||n.value)}}n=e({title:n.title,"class":"mce_"+f,menu_class:j.getParam("skin")+"Skin",scope:n.scope,more_colors_title:j.getLang("more_colors")},n);f=l.prefix+f;m=h||l._cls.colorsplitbutton||c.ui.ColorSplitButton;k=new m(f,n);j.onMouseDown.add(k.hideMenu,k);j.onRemove.add(function(){k.destroy()});if(c.isIE){k.onHideMenu.add(function(){if(g){j.selection.moveToBookmark(g);g=0}})}return l.add(k)},createToolbar:function(k,h,j){var i,g=this,f;k=g.prefix+k;f=j||g._cls.toolbar||c.ui.Toolbar;i=new f(k,h);if(g.get(k)){return null}return g.add(i)},createSeparator:function(g){var f=g||this._cls.separator||c.ui.Separator;return new f()},setControlType:function(g,f){return this._cls[g.toLowerCase()]=f},destroy:function(){d(this.controls,function(f){f.destroy()});this.controls=null}})})(tinymce);(function(d){var a=d.util.Dispatcher,e=d.each,c=d.isIE,b=d.isOpera;d.create("tinymce.WindowManager",{WindowManager:function(f){var g=this;g.editor=f;g.onOpen=new a(g);g.onClose=new a(g);g.params={};g.features={}},open:function(z,h){var v=this,k="",n,m,i=v.editor.settings.dialog_type=="modal",q,o,j,g=d.DOM.getViewPort(),r;z=z||{};h=h||{};o=b?g.w:screen.width;j=b?g.h:screen.height;z.name=z.name||"mc_"+new Date().getTime();z.width=parseInt(z.width||320);z.height=parseInt(z.height||240);z.resizable=true;z.left=z.left||parseInt(o/2)-(z.width/2);z.top=z.top||parseInt(j/2)-(z.height/2);h.inline=false;h.mce_width=z.width;h.mce_height=z.height;h.mce_auto_focus=z.auto_focus;if(i){if(c){z.center=true;z.help=false;z.dialogWidth=z.width+"px";z.dialogHeight=z.height+"px";z.scroll=z.scrollbars||false}}e(z,function(p,f){if(d.is(p,"boolean")){p=p?"yes":"no"}if(!/^(name|url)$/.test(f)){if(c&&i){k+=(k?";":"")+f+":"+p}else{k+=(k?",":"")+f+"="+p}}});v.features=z;v.params=h;v.onOpen.dispatch(v,z,h);r=z.url||z.file;r=d._addVer(r);try{if(c&&i){q=1;window.showModalDialog(r,window,k)}else{q=window.open(r,z.name,k)}}catch(l){}if(!q){alert(v.editor.getLang("popup_blocked"))}},close:function(f){f.close();this.onClose.dispatch(this)},createInstance:function(i,h,g,m,l,k){var j=d.resolve(i);return new j(h,g,m,l,k)},confirm:function(h,f,i,g){g=g||window;f.call(i||this,g.confirm(this._decode(this.editor.getLang(h,h))))},alert:function(h,f,j,g){var i=this;g=g||window;g.alert(i._decode(i.editor.getLang(h,h)));if(f){f.call(j||i)}},_decode:function(f){return d.DOM.decode(f).replace(/\\n/g,"\n")}})}(tinymce));(function(a){a.CommandManager=function(){var c={},b={},d={};function e(i,h,g,f){if(typeof(h)=="string"){h=[h]}a.each(h,function(j){i[j.toLowerCase()]={func:g,scope:f}})}a.extend(this,{add:function(h,g,f){e(c,h,g,f)},addQueryStateHandler:function(h,g,f){e(b,h,g,f)},addQueryValueHandler:function(h,g,f){e(d,h,g,f)},execCommand:function(g,j,i,h,f){if(j=c[j.toLowerCase()]){if(j.func.call(g||j.scope,i,h,f)!==false){return true}}},queryCommandValue:function(){if(cmd=d[cmd.toLowerCase()]){return cmd.func.call(scope||cmd.scope,ui,value,args)}},queryCommandState:function(){if(cmd=b[cmd.toLowerCase()]){return cmd.func.call(scope||cmd.scope,ui,value,args)}}})};a.GlobalCommands=new a.CommandManager()})(tinymce);(function(b){function a(i,d,h,m){var j,g,e,l,f;function k(p,o){do{if(p.parentNode==o){return p}p=p.parentNode}while(p)}function c(o){m(o);b.walk(o,m,"childNodes")}j=i.findCommonAncestor(d,h);e=k(d,j)||d;l=k(h,j)||h;for(g=d;g&&g!=e;g=g.parentNode){for(f=g.nextSibling;f;f=f.nextSibling){c(f)}}if(e!=l){for(g=e.nextSibling;g&&g!=l;g=g.nextSibling){c(g)}}else{c(e)}for(g=h;g&&g!=l;g=g.parentNode){for(f=g.previousSibling;f;f=f.previousSibling){c(f)}}}b.GlobalCommands.add("RemoveFormat",function(){var m=this,l=m.dom,u=m.selection,d=u.getRng(1),e=[],h,f,j,q,g,o,c,i;function k(s){var r;l.getParent(s,function(v){if(l.is(v,m.getParam("removeformat_selector"))){r=v}return l.isBlock(v)},m.getBody());return r}function p(r){if(l.is(r,m.getParam("removeformat_selector"))){e.push(r)}}function t(r){p(r);b.walk(r,p,"childNodes")}h=u.getBookmark();q=d.startContainer;o=d.endContainer;g=d.startOffset;c=d.endOffset;q=q.nodeType==1?q.childNodes[Math.min(g,q.childNodes.length-1)]:q;o=o.nodeType==1?o.childNodes[Math.min(g==c?c:c-1,o.childNodes.length-1)]:o;if(q==o){f=k(q);if(q.nodeType==3){if(f&&f.nodeType==1){i=q.splitText(g);i.splitText(c-g);l.split(f,i);u.moveToBookmark(h)}return}t(l.split(f,q)||q)}else{f=k(q);j=k(o);if(f){if(q.nodeType==3){if(g==q.nodeValue.length){q.nodeValue+="\uFEFF"}q=q.splitText(g)}}if(j){if(o.nodeType==3){o.splitText(c)}}if(f&&f==j){l.replace(l.create("span",{id:"__end"},o.cloneNode(true)),o)}if(f){f=l.split(f,q)}else{f=q}if(i=l.get("__end")){o=i;j=k(o)}if(j){j=l.split(j,o)}else{j=o}a(l,f,j,p);if(q.nodeValue=="\uFEFF"){q.nodeValue=""}t(o);t(q)}b.each(e,function(r){l.remove(r,1)});l.remove("__end",1);u.moveToBookmark(h)})})(tinymce);(function(a){a.GlobalCommands.add("mceBlockQuote",function(){var j=this,o=j.selection,f=j.dom,l,k,e,d,p,c,m,h,b;function g(i){return f.getParent(i,function(q){return q.nodeName==="BLOCKQUOTE"})}l=f.getParent(o.getStart(),f.isBlock);k=f.getParent(o.getEnd(),f.isBlock);if(p=g(l)){if(l!=k||l.childNodes.length>1||(l.childNodes.length==1&&l.firstChild.nodeName!="BR")){d=o.getBookmark()}if(g(k)){m=p.cloneNode(false);while(e=k.nextSibling){m.appendChild(e.parentNode.removeChild(e))}}if(m){f.insertAfter(m,p)}b=o.getSelectedBlocks(l,k);for(h=b.length-1;h>=0;h--){f.insertAfter(b[h],p)}if(/^\s*$/.test(p.innerHTML)){f.remove(p,1)}if(m&&/^\s*$/.test(m.innerHTML)){f.remove(m,1)}if(!d){if(!a.isIE){c=j.getDoc().createRange();c.setStart(l,0);c.setEnd(l,0);o.setRng(c)}else{o.select(l);o.collapse(0);if(f.getParent(o.getStart(),f.isBlock)!=l){c=o.getRng();c.move("character",-1);c.select()}}}else{j.selection.moveToBookmark(d)}return}if(a.isIE&&!l&&!k){j.getDoc().execCommand("Indent");e=g(o.getNode());e.style.margin=e.dir="";return}if(!l||!k){return}if(l!=k||l.childNodes.length>1||(l.childNodes.length==1&&l.firstChild.nodeName!="BR")){d=o.getBookmark()}a.each(o.getSelectedBlocks(g(o.getStart()),g(o.getEnd())),function(i){if(i.nodeName=="BLOCKQUOTE"&&!p){p=i;return}if(!p){p=f.create("blockquote");i.parentNode.insertBefore(p,i)}if(i.nodeName=="BLOCKQUOTE"&&p){e=i.firstChild;while(e){p.appendChild(e.cloneNode(true));e=e.nextSibling}f.remove(i);return}p.appendChild(f.remove(i))});if(!d){if(!a.isIE){c=j.getDoc().createRange();c.setStart(l,0);c.setEnd(l,0);o.setRng(c)}else{o.select(l);o.collapse(1)}}else{o.moveToBookmark(d)}})})(tinymce);(function(a){a.each(["Cut","Copy","Paste"],function(b){a.GlobalCommands.add(b,function(){var c=this,e=c.getDoc();try{e.execCommand(b,false,null);if(!e.queryCommandSupported(b)){throw"Error"}}catch(d){c.windowManager.alert(c.getLang("clipboard_no_support"))}})})})(tinymce);(function(a){a.GlobalCommands.add("InsertHorizontalRule",function(){if(a.isOpera){return this.getDoc().execCommand("InsertHorizontalRule",false,"")}this.selection.setContent("<hr />")})})(tinymce);(function(){var a=tinymce.GlobalCommands;a.add(["mceEndUndoLevel","mceAddUndoLevel"],function(){this.undoManager.add()});a.add("Undo",function(){var b=this;if(b.settings.custom_undo_redo){b.undoManager.undo();b.nodeChanged();return true}return false});a.add("Redo",function(){var b=this;if(b.settings.custom_undo_redo){b.undoManager.redo();b.nodeChanged();return true}return false})})();
\ No newline at end of file
+(function(c){var i=/^\s*|\s*$/g,j="B".replace(/A(.)|B/,"$1")==="$1",g={majorVersion:"3",minorVersion:"4.2",releaseDate:"2011-04-07",_init:function(){function b(e){if(e.src&&/tiny_mce(|_gzip|_jquery|_prototype|_full)(_dev|_src)?.js/.test(e.src)){if(/_(src|dev)\.js/g.test(e.src))a.suffix="_src";if((m=e.src.indexOf("?"))!=-1)a.query=e.src.substring(m+1);a.baseURL=e.src.substring(0,e.src.lastIndexOf("/"));if(k&&a.baseURL.indexOf("://")==-1&&a.baseURL.indexOf("/")!==0)a.baseURL=k+a.baseURL;return a.baseURL}return null}
+var a=this,f=document,d=navigator,n=d.userAgent,k,m,o;a.isOpera=c.opera&&opera.buildNumber;a.isWebKit=/WebKit/.test(n);a.isIE=!a.isWebKit&&!a.isOpera&&/MSIE/gi.test(n)&&/Explorer/gi.test(d.appName);a.isIE6=a.isIE&&/MSIE [56]/.test(n);a.isGecko=!a.isWebKit&&/Gecko/.test(n);a.isMac=n.indexOf("Mac")!=-1;a.isAir=/adobeair/i.test(n);a.isIDevice=/(iPad|iPhone)/.test(n);if(c.tinyMCEPreInit)a.suffix=tinyMCEPreInit.suffix,a.baseURL=tinyMCEPreInit.base,a.query=tinyMCEPreInit.query;else{a.suffix="";n=f.getElementsByTagName("base");
+for(d=0;d<n.length;d++)if(o=n[d].href)/^https?:\/\/[^\/]+$/.test(o)&&(o+="/"),k=o?o.match(/.*\//)[0]:"";n=f.getElementsByTagName("script");for(d=0;d<n.length;d++)if(b(n[d]))return;if(f=f.getElementsByTagName("head")[0]){n=f.getElementsByTagName("script");for(d=0;d<n.length;d++)if(b(n[d]))break}}},is:function(b,a){if(!a)return b!==void 0;if(a=="array"&&b.hasOwnProperty&&b instanceof Array)return!0;return typeof b==a},makeMap:function(b,a,f){b=b||[];typeof b=="string"&&(b=b.split(a||","));f=f||{};for(a=
+b.length;a--;)f[b[a]]={};return f},each:function(b,a,f){var d,n;if(!b)return 0;f=f||b;if(b.length!==void 0){d=0;for(n=b.length;d<n;d++)if(a.call(f,b[d],d,b)===!1)return 0}else for(d in b)if(b.hasOwnProperty(d)&&a.call(f,b[d],d,b)===!1)return 0;return 1},map:function(b,a){var f=[];g.each(b,function(b){f.push(a(b))});return f},grep:function(b,a){var f=[];g.each(b,function(b){(!a||a(b))&&f.push(b)});return f},inArray:function(b,a){var f,d;if(b){f=0;for(d=b.length;f<d;f++)if(b[f]===a)return f}return-1},
+extend:function(b,a){var f,d,n=arguments;f=1;for(d=n.length;f<d;f++)a=n[f],g.each(a,function(a,d){a!==void 0&&(b[d]=a)});return b},trim:function(b){return(b?""+b:"").replace(i,"")},create:function(b,a,f){var d,n,k,m,o,e=0,b=/^((static) )?([\w.]+)(:([\w.]+))?/.exec(b);k=b[3].match(/(^|\.)(\w+)$/i)[2];n=this.createNS(b[3].replace(/\.\w+$/,""),f);if(!n[k])if(b[2]=="static"){if(n[k]=a,this.onCreate)this.onCreate(b[2],b[3],n[k])}else{a[k]||(a[k]=function(){},e=1);n[k]=a[k];this.extend(n[k].prototype,a);
+if(b[5])d=this.resolve(b[5]).prototype,m=b[5].match(/\.(\w+)$/i)[1],o=n[k],n[k]=e?function(){return d[m].apply(this,arguments)}:function(){this.parent=d[m];return o.apply(this,arguments)},n[k].prototype[k]=n[k],this.each(d,function(a,e){n[k].prototype[e]=d[e]}),this.each(a,function(a,e){d[e]?n[k].prototype[e]=function(){this.parent=d[e];return a.apply(this,arguments)}:e!=k&&(n[k].prototype[e]=a)});this.each(a["static"],function(a,e){n[k][e]=a});if(this.onCreate)this.onCreate(b[2],b[3],n[k].prototype)}},
+walk:function(b,a,f,d){d=d||this;b&&(f&&(b=b[f]),g.each(b,function(b,k){if(a.call(d,b,k,f)===!1)return!1;g.walk(b,a,f,d)}))},createNS:function(b,a){var f,d,a=a||c,b=b.split(".");for(f=0;f<b.length;f++)d=b[f],a[d]||(a[d]={}),a=a[d];return a},resolve:function(b,a){var f,d,a=a||c,b=b.split(".");f=0;for(d=b.length;f<d;f++)if(a=a[b[f]],!a)break;return a},addUnload:function(b,a){var f=this,b={func:b,scope:a||this};if(f.unloads)f.unloads.push(b);else{var d=function(){var a=f.unloads,b,o;if(a){for(o in a)(b=
+a[o])&&b.func&&b.func.call(b.scope,1);c.detachEvent?(c.detachEvent("onbeforeunload",n),c.detachEvent("onunload",d)):c.removeEventListener&&c.removeEventListener("unload",d,!1);f.unloads=w=d=0;c.CollectGarbage&&CollectGarbage()}},n=function(){var a=document;if(a.readyState=="interactive"){var b=function(){a.detachEvent("onstop",b);d&&d();a=0};a&&a.attachEvent("onstop",b);c.setTimeout(function(){a&&a.detachEvent("onstop",b)},0)}};c.attachEvent?(c.attachEvent("onunload",d),c.attachEvent("onbeforeunload",
+n)):c.addEventListener&&c.addEventListener("unload",d,!1);f.unloads=[b]}return b},removeUnload:function(b){var a=this.unloads,f=null;g.each(a,function(d,n){if(d&&d.func==b)return a.splice(n,1),f=b,!1});return f},explode:function(b,a){return b?g.map(b.split(a||","),g.trim):b},_addVer:function(b){var a;if(!this.query)return b;a=(b.indexOf("?")==-1?"?":"&")+this.query;if(b.indexOf("#")==-1)return b+a;return b.replace("#",a+"#")},_replace:function(b,a,f){if(j)return f.replace(b,function(){var b=a,f=arguments,
+k;for(k=0;k<f.length-2;k++)b=f[k]===void 0?b.replace(RegExp("\\$"+k,"g"),""):b.replace(RegExp("\\$"+k,"g"),f[k]);return b});return f.replace(b,a)}};g._init();c.tinymce=c.tinyMCE=g})(window);
+tinymce.create("tinymce.util.Dispatcher",{scope:null,listeners:null,Dispatcher:function(c){this.scope=c||this;this.listeners=[]},add:function(c,i){this.listeners.push({cb:c,scope:i||this.scope});return c},addToTop:function(c,i){this.listeners.unshift({cb:c,scope:i||this.scope});return c},remove:function(c){var i=this.listeners,j=null;tinymce.each(i,function(g,b){if(c==g.cb)return j=c,i.splice(b,1),!1});return j},dispatch:function(){var c,i=arguments,j,g=this.listeners;for(j=0;j<g.length;j++)if(c=
+g[j],c=c.cb.apply(c.scope,i),c===!1)break;return c}});
+(function(){var c=tinymce.each;tinymce.create("tinymce.util.URI",{URI:function(i,j){var g=this,b,i=tinymce.trim(i),j=g.settings=j||{};if(/^(mailto|tel|news|javascript|about|data):/i.test(i)||/^\s*#/.test(i))g.source=i;else if(i.indexOf("/")===0&&i.indexOf("//")!==0&&(i=(j.base_uri?j.base_uri.protocol||"http":"http")+"://mce_host"+i),/^\w*:?\/\//.test(i)||(i=(j.base_uri.protocol||"http")+"://mce_host"+g.toAbsPath(j.base_uri.path,i)),i=i.replace(/@@/g,"(mce_at)"),i=/^(?:(?![^:@]+:[^:@\/]*@)([^:\/?#.]+):)?(?:\/\/)?((?:(([^:@]*):?([^:@]*))?@)?([^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/.exec(i),
+c(["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"],function(a,b){var d=i[b];d&&(d=d.replace(/\(mce_at\)/g,"@@"));g[a]=d}),b=j.base_uri){if(!g.protocol)g.protocol=b.protocol;if(!g.userInfo)g.userInfo=b.userInfo;if(!g.port&&g.host=="mce_host")g.port=b.port;if(!g.host||g.host=="mce_host")g.host=b.host;g.source=""}},setPath:function(c){c=/^(.*?)\/?(\w+)?$/.exec(c);this.path=c[0];this.directory=c[1];this.file=c[2];this.source=
+"";this.getURI()},toRelative:function(c){var j;if(c==="./")return c;c=new tinymce.util.URI(c,{base_uri:this});if(c.host!="mce_host"&&this.host!=c.host&&c.host||this.port!=c.port||this.protocol!=c.protocol)return c.getURI();j=this.toRelPath(this.path,c.path);c.query&&(j+="?"+c.query);c.anchor&&(j+="#"+c.anchor);return j},toAbsolute:function(c,j){c=new tinymce.util.URI(c,{base_uri:this});return c.getURI(this.host==c.host&&this.protocol==c.protocol?j:0)},toRelPath:function(c,j){var g,b=0,a="",f,d,c=
+c.substring(0,c.lastIndexOf("/")),c=c.split("/");g=j.split("/");if(c.length>=g.length){f=0;for(d=c.length;f<d;f++)if(f>=g.length||c[f]!=g[f]){b=f+1;break}}if(c.length<g.length){f=0;for(d=g.length;f<d;f++)if(f>=c.length||c[f]!=g[f]){b=f+1;break}}if(b==1)return j;f=0;for(d=c.length-(b-1);f<d;f++)a+="../";f=b-1;for(d=g.length;f<d;f++)a+=f!=b-1?"/"+g[f]:g[f];return a},toAbsPath:function(i,j){var g,b=0,a=[],f;f=/\/$/.test(j)?"/":"";i=i.split("/");j=j.split("/");c(i,function(b){b&&a.push(b)});i=a;g=j.length-
+1;for(a=[];g>=0;g--)j[g].length==0||j[g]=="."||(j[g]==".."?b++:b>0?b--:a.push(j[g]));g=i.length-b;g=g<=0?a.reverse().join("/"):i.slice(0,g).join("/")+"/"+a.reverse().join("/");g.indexOf("/")!==0&&(g="/"+g);f&&g.lastIndexOf("/")!==g.length-1&&(g+=f);return g},getURI:function(c){var j;if(!this.source||c)j="",c||(this.protocol&&(j+=this.protocol+"://"),this.userInfo&&(j+=this.userInfo+"@"),this.host&&(j+=this.host),this.port&&(j+=":"+this.port)),this.path&&(j+=this.path),this.query&&(j+="?"+this.query),
+this.anchor&&(j+="#"+this.anchor),this.source=j;return this.source}})})();
+(function(){var c=tinymce.each;tinymce.create("static tinymce.util.Cookie",{getHash:function(i){var i=this.get(i),j;i&&c(i.split("&"),function(c){c=c.split("=");j=j||{};j[unescape(c[0])]=unescape(c[1])});return j},setHash:function(i,j,g,b,a,f){var d="";c(j,function(a,b){d+=(!d?"":"&")+escape(b)+"="+escape(a)});this.set(i,d,g,b,a,f)},get:function(c){var j=document.cookie,g=c+"=",b;if(j){b=j.indexOf("; "+g);if(b==-1){if(b=j.indexOf(g),b!=0)return null}else b+=2;c=j.indexOf(";",b);if(c==-1)c=j.length;
+return unescape(j.substring(b+g.length,c))}},set:function(c,j,g,b,a,f){document.cookie=c+"="+escape(j)+(g?"; expires="+g.toGMTString():"")+(b?"; path="+escape(b):"")+(a?"; domain="+a:"")+(f?"; secure":"")},remove:function(c,j){var g=new Date;g.setTime(g.getTime()-1E3);this.set(c,"",g,j,g)}})})();
+(function(){function c(i,j){var g,b,a,j=j||'"';if(i==null)return"null";a=typeof i;if(a=="string")return b="\u0008b\tt\nn\u000cf\rr\"\"''\\\\",j+i.replace(/([\u0080-\uFFFF\x00-\x1f\"\'\\])/g,function(a,d){if(j==='"'&&a==="'")return a;g=b.indexOf(d);if(g+1)return"\\"+b.charAt(g+1);a=d.charCodeAt().toString(16);return"\\u"+"0000".substring(a.length)+a})+j;if(a=="object"){if(i.hasOwnProperty&&i instanceof Array){g=0;for(b="[";g<i.length;g++)b+=(g>0?",":"")+c(i[g],j);return b+"]"}b="{";for(g in i)b+=typeof i[g]!=
+"function"?(b.length>1?","+j:j)+g+j+":"+c(i[g],j):"";return b+"}"}return""+i}tinymce.util.JSON={serialize:c,parse:function(c){try{return eval("("+c+")")}catch(j){}}}})();
+tinymce.create("static tinymce.util.XHR",{send:function(c){function i(a){j=0;try{j=new ActiveXObject(a)}catch(b){}return j}var j,g=window,b=0;c.scope=c.scope||this;c.success_scope=c.success_scope||c.scope;c.error_scope=c.error_scope||c.scope;c.async=c.async===!1?!1:!0;c.data=c.data||"";if(j=g.XMLHttpRequest?new XMLHttpRequest:i("Microsoft.XMLHTTP")||i("Msxml2.XMLHTTP")){j.overrideMimeType&&j.overrideMimeType(c.content_type);j.open(c.type||(c.data?"POST":"GET"),c.url,c.async);c.content_type&&j.setRequestHeader("Content-Type",
+c.content_type);j.setRequestHeader("X-Requested-With","XMLHttpRequest");j.send(c.data);var a=function(){!c.async||j.readyState==4||b++>1E4?(c.success&&b<1E4&&j.status==200?c.success.call(c.success_scope,""+j.responseText,j,c):c.error&&c.error.call(c.error_scope,b>1E4?"TIMED_OUT":"GENERAL",j,c),j=null):g.setTimeout(a,10)};if(!c.async)return a();g.setTimeout(a,10)}}});
+(function(){var c=tinymce.extend,i=tinymce.util.JSON,j=tinymce.util.XHR;tinymce.create("tinymce.util.JSONRequest",{JSONRequest:function(g){this.settings=c({},g);this.count=0},send:function(g){var b=g.error,a=g.success,g=c(this.settings,g);g.success=function(f,d){f=i.parse(f);typeof f=="undefined"&&(f={error:"JSON Parse error."});f.error?b.call(g.error_scope||g.scope,f.error,d):a.call(g.success_scope||g.scope,f.result)};g.error=function(a,d){b&&b.call(g.error_scope||g.scope,a,d)};g.data=i.serialize({id:g.id||
+"c"+this.count++,method:g.method,params:g.params});g.content_type="application/json";j.send(g)},"static":{sendRPC:function(c){return(new tinymce.util.JSONRequest).send(c)}}})})();
+(function(c){function i(a,b){var e,h,k,d={};if(a){a=a.split(",");b=b||10;for(e=0;e<a.length;e+=2)h=String.fromCharCode(parseInt(a[e],b)),g[h]||(k="&"+a[e+1]+";",d[h]=k,d[k]=h);return d}}var j,g,b,a=/[&\"\u007E-\uD7FF]|[\uD800-\uDBFF][\uDC00-\uDFFF]/g,f=/[<>&\u007E-\uD7FF]|[\uD800-\uDBFF][\uDC00-\uDFFF]/g,d=/[<>&\"\']/g,n=/&(#)?([\w]+);/g,k={128:"\u20ac",130:"\u201a",131:"\u0192",132:"\u201e",133:"\u2026",134:"\u2020",135:"\u2021",136:"\u02c6",137:"\u2030",138:"\u0160",139:"\u2039",140:"\u0152",142:"\u017d",
+145:"\u2018",146:"\u2019",147:"\u201c",148:"\u201d",149:"\u2022",150:"\u2013",151:"\u2014",152:"\u02dc",153:"\u2122",154:"\u0161",155:"\u203a",156:"\u0153",158:"\u017e",159:"\u0178"};g={'"':"&quot;","'":"&#39;","<":"&lt;",">":"&gt;","&":"&amp;"};b={"&lt;":"<","&gt;":">","&amp;":"&","&quot;":'"',"&apos;":"'"};j=i("50,nbsp,51,iexcl,52,cent,53,pound,54,curren,55,yen,56,brvbar,57,sect,58,uml,59,copy,5a,ordf,5b,laquo,5c,not,5d,shy,5e,reg,5f,macr,5g,deg,5h,plusmn,5i,sup2,5j,sup3,5k,acute,5l,micro,5m,para,5n,middot,5o,cedil,5p,sup1,5q,ordm,5r,raquo,5s,frac14,5t,frac12,5u,frac34,5v,iquest,60,Agrave,61,Aacute,62,Acirc,63,Atilde,64,Auml,65,Aring,66,AElig,67,Ccedil,68,Egrave,69,Eacute,6a,Ecirc,6b,Euml,6c,Igrave,6d,Iacute,6e,Icirc,6f,Iuml,6g,ETH,6h,Ntilde,6i,Ograve,6j,Oacute,6k,Ocirc,6l,Otilde,6m,Ouml,6n,times,6o,Oslash,6p,Ugrave,6q,Uacute,6r,Ucirc,6s,Uuml,6t,Yacute,6u,THORN,6v,szlig,70,agrave,71,aacute,72,acirc,73,atilde,74,auml,75,aring,76,aelig,77,ccedil,78,egrave,79,eacute,7a,ecirc,7b,euml,7c,igrave,7d,iacute,7e,icirc,7f,iuml,7g,eth,7h,ntilde,7i,ograve,7j,oacute,7k,ocirc,7l,otilde,7m,ouml,7n,divide,7o,oslash,7p,ugrave,7q,uacute,7r,ucirc,7s,uuml,7t,yacute,7u,thorn,7v,yuml,ci,fnof,sh,Alpha,si,Beta,sj,Gamma,sk,Delta,sl,Epsilon,sm,Zeta,sn,Eta,so,Theta,sp,Iota,sq,Kappa,sr,Lambda,ss,Mu,st,Nu,su,Xi,sv,Omicron,t0,Pi,t1,Rho,t3,Sigma,t4,Tau,t5,Upsilon,t6,Phi,t7,Chi,t8,Psi,t9,Omega,th,alpha,ti,beta,tj,gamma,tk,delta,tl,epsilon,tm,zeta,tn,eta,to,theta,tp,iota,tq,kappa,tr,lambda,ts,mu,tt,nu,tu,xi,tv,omicron,u0,pi,u1,rho,u2,sigmaf,u3,sigma,u4,tau,u5,upsilon,u6,phi,u7,chi,u8,psi,u9,omega,uh,thetasym,ui,upsih,um,piv,812,bull,816,hellip,81i,prime,81j,Prime,81u,oline,824,frasl,88o,weierp,88h,image,88s,real,892,trade,89l,alefsym,8cg,larr,8ch,uarr,8ci,rarr,8cj,darr,8ck,harr,8dl,crarr,8eg,lArr,8eh,uArr,8ei,rArr,8ej,dArr,8ek,hArr,8g0,forall,8g2,part,8g3,exist,8g5,empty,8g7,nabla,8g8,isin,8g9,notin,8gb,ni,8gf,prod,8gh,sum,8gi,minus,8gn,lowast,8gq,radic,8gt,prop,8gu,infin,8h0,ang,8h7,and,8h8,or,8h9,cap,8ha,cup,8hb,int,8hk,there4,8hs,sim,8i5,cong,8i8,asymp,8j0,ne,8j1,equiv,8j4,le,8j5,ge,8k2,sub,8k3,sup,8k4,nsub,8k6,sube,8k7,supe,8kl,oplus,8kn,otimes,8l5,perp,8m5,sdot,8o8,lceil,8o9,rceil,8oa,lfloor,8ob,rfloor,8p9,lang,8pa,rang,9ea,loz,9j0,spades,9j3,clubs,9j5,hearts,9j6,diams,ai,OElig,aj,oelig,b0,Scaron,b1,scaron,bo,Yuml,m6,circ,ms,tilde,802,ensp,803,emsp,809,thinsp,80c,zwnj,80d,zwj,80e,lrm,80f,rlm,80j,ndash,80k,mdash,80o,lsquo,80p,rsquo,80q,sbquo,80s,ldquo,80t,rdquo,80u,bdquo,810,dagger,811,Dagger,81g,permil,81p,lsaquo,81q,rsaquo,85c,euro",
+32);c.html=c.html||{};c.html.Entities={encodeRaw:function(b,k){return b.replace(k?a:f,function(a){return g[a]||a})},encodeAllRaw:function(a){return(""+a).replace(d,function(a){return g[a]||a})},encodeNumeric:function(b,k){return b.replace(k?a:f,function(a){if(a.length>1)return"&#"+((a.charCodeAt(0)-55296)*1024+(a.charCodeAt(1)-56320)+65536)+";";return g[a]||"&#"+a.charCodeAt(0)+";"})},encodeNamed:function(b,k,e){e=e||j;return b.replace(k?a:f,function(a){return g[a]||e[a]||a})},getEncodeFunc:function(b,
+k){function e(e,l){return e.replace(l?a:f,function(a){return g[a]||k[a]||"&#"+a.charCodeAt(0)+";"||a})}function h(a,e){return d.encodeNamed(a,e,k)}var d=c.html.Entities,k=i(k)||j,b=c.makeMap(b.replace(/\+/g,","));if(b.named&&b.numeric)return e;if(b.named){if(k)return h;return d.encodeNamed}if(b.numeric)return d.encodeNumeric;return d.encodeRaw},decode:function(a){return a.replace(n,function(a,e,h){if(e)return h=parseInt(h),h>65535?(h-=65536,String.fromCharCode(55296+(h>>10),56320+(h&1023))):k[h]||
+String.fromCharCode(h);if(!(e=b[a]))if(!(e=j[a]))e=document.createElement("div"),e.innerHTML=a,e=e.textContent||e.innerText||a;return e})}}})(tinymce);
+tinymce.html.Styles=function(c,i){function j(a,b,e,h){function k(a){a=parseInt(a).toString(16);return a.length>1?a:"0"+a}return"#"+k(b)+k(e)+k(h)}var g=/rgb\s*\(\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\s*\)/gi,b=/(?:url(?:(?:\(\s*\"([^\"]+)\"\s*\))|(?:\(\s*\'([^\']+)\'\s*\))|(?:\(\s*([^)\s]+)\s*\))))|(?:\'([^\']+)\')|(?:\"([^\"]+)\")/gi,a=/\s*([^:]+):\s*([^;]+);?/g,f=/\s+$/,d,n={},k,c=c||{};k="\\\" \\' \\; \\: ; : _".split(" ");for(d=0;d<k.length;d++)n[k[d]]="_"+d,n["_"+d]=k[d];return{toHex:function(a){return a.replace(g,
+j)},parse:function(k){function d(a,e){var h,b;if(h=l[a+"-top"+e])b=l[a+"-right"+e],h==b&&(h=l[a+"-bottom"+e],b==h&&(b=l[a+"-left"+e],h==b&&(l[a+e]=b,delete l[a+"-top"+e],delete l[a+"-right"+e],delete l[a+"-bottom"+e],delete l[a+"-left"+e])))}function e(a){var e=l[a],h;if(e&&!(e.indexOf(" ")<0)){e=e.split(" ");for(h=e.length;h--;)if(e[h]!==e[0])return!1;l[a]=e[0];return!0}}function h(a,h,b,k){e(h)&&e(b)&&e(k)&&(l[a]=l[h]+" "+l[b]+" "+l[k],delete l[h],delete l[b],delete l[k])}function p(a){t=!0;return n[a]}
+function u(a,e){t&&(a=a.replace(/_[0-9]/g,function(a){return n[a]}));e||(a=a.replace(/\\([\'\";:])/g,"$1"));return a}var l={},s,i,r,t,y=c.url_converter,z=c.url_converter_scope||this;if(k){for(k=k.replace(/\\[\"\';:_]/g,p).replace(/\"[^\"]+\"|\'[^\']+\'/g,function(a){return a.replace(/[;:]/g,p)});s=a.exec(k);){i=s[1].replace(f,"").toLowerCase();r=s[2].replace(f,"");if(i&&r.length>0){if(i==="font-weight"&&r==="700")r="bold";else if(i==="color"||i==="background-color")r=r.toLowerCase();r=r.replace(g,
+j);r=r.replace(b,function(a,e,l,h,b,k){if(b=b||k)return b=u(b),"'"+b.replace(/\'/g,"\\'")+"'";e=u(e||l||h);y&&(e=y.call(z,e,"style"));return"url('"+e.replace(/\'/g,"\\'")+"')"});l[i]=t?u(r,!0):r}a.lastIndex=s.index+s[0].length}d("border","");d("border","-width");d("border","-color");d("border","-style");d("padding","");d("margin","");h("border","border-width","border-style","border-color");l.border==="medium none"&&delete l.border}return l},serialize:function(a,b){function e(e){var b,k,d,f;if(b=i.styles[e]){k=
+0;for(d=b.length;k<d;k++)e=b[k],f=a[e],f!==void 0&&f.length>0&&(h+=(h.length>0?" ":"")+e+": "+f+";")}}var h="",k,d;if(b&&i&&i.styles)e("*"),e(k);else for(k in a)d=a[k],d!==void 0&&d.length>0&&(h+=(h.length>0?" ":"")+k+": "+d+";");return h}}};
+(function(c){function i(a,e){return a.split(e||",")}var j={},g,b,a,f,d,n,k=c.makeMap,m=c.each;b="h1,h2,h3,h4,h5,h6,hr,p,div,address,pre,form,table,tbody,thead,tfoot,th,tr,td,li,ol,ul,caption,blockquote,center,dl,dt,dd,dir,fieldset,noscript,menu,isindex,samp,header,footer,article,section,hgroup";b=k(b,",",k(b.toUpperCase()));j=function(a,e){function h(e){return e.replace(/[A-Z]+/g,function(e){return h(a[e])})}var b,d={};for(b in a)a.hasOwnProperty(b)&&(a[b]=h(a[b]));h(e).replace(/#/g,"#text").replace(/(\w+)\[([^\]]+)\]\[([^\]]*)\]/g,
+function(a,e,b,h){b=i(b,"|");d[e]={attributes:k(b),attributesOrder:b,children:k(h,"|",{"#comment":{}})}});return d}({Z:"H|K|N|O|P",Y:"X|form|R|Q",ZG:"E|span|width|align|char|charoff|valign",X:"p|T|div|U|W|isindex|fieldset|table",ZF:"E|align|char|charoff|valign",W:"pre|hr|blockquote|address|center|noframes",ZE:"abbr|axis|headers|scope|rowspan|colspan|align|char|charoff|valign|nowrap|bgcolor|width|height",ZD:"[E][S]",U:"ul|ol|dl|menu|dir",ZC:"p|Y|div|U|W|table|br|span|bdo|object|applet|img|map|K|N|Q",
+T:"h1|h2|h3|h4|h5|h6",ZB:"X|S|Q",S:"R|P",ZA:"a|G|J|M|O|P",R:"a|H|K|N|O",Q:"noscript|P",P:"ins|del|script",O:"input|select|textarea|label|button",N:"M|L",M:"em|strong|dfn|code|q|samp|kbd|var|cite|abbr|acronym",L:"sub|sup",K:"J|I",J:"tt|i|b|u|s|strike",I:"big|small|font|basefont",H:"G|F",G:"br|span|bdo",F:"object|applet|img|map|iframe",E:"A|B|C",D:"accesskey|tabindex|onfocus|onblur",C:"onclick|ondblclick|onmousedown|onmouseup|onmouseover|onmousemove|onmouseout|onkeypress|onkeydown|onkeyup",B:"lang|xml:lang|dir",
+A:"id|class|style|title"},"script[id|charset|type|language|src|defer|xml:space][]style[B|id|type|media|title|xml:space][]object[E|declare|classid|codebase|data|type|codetype|archive|standby|width|height|usemap|name|tabindex|align|border|hspace|vspace][#|param|Y]param[id|name|value|valuetype|type][]p[E|align][#|S]a[E|D|charset|type|name|href|hreflang|rel|rev|shape|coords|target][#|Z]br[A|clear][]span[E][#|S]bdo[A|C|B][#|S]applet[A|codebase|archive|code|object|alt|name|width|height|align|hspace|vspace][#|param|Y]h1[E|align][#|S]img[E|src|alt|name|longdesc|width|height|usemap|ismap|align|border|hspace|vspace][]map[B|C|A|name][X|form|Q|area]h2[E|align][#|S]iframe[A|longdesc|name|src|frameborder|marginwidth|marginheight|scrolling|align|width|height][#|Y]h3[E|align][#|S]tt[E][#|S]i[E][#|S]b[E][#|S]u[E][#|S]s[E][#|S]strike[E][#|S]big[E][#|S]small[E][#|S]font[A|B|size|color|face][#|S]basefont[id|size|color|face][]em[E][#|S]strong[E][#|S]dfn[E][#|S]code[E][#|S]q[E|cite][#|S]samp[E][#|S]kbd[E][#|S]var[E][#|S]cite[E][#|S]abbr[E][#|S]acronym[E][#|S]sub[E][#|S]sup[E][#|S]input[E|D|type|name|value|checked|disabled|readonly|size|maxlength|src|alt|usemap|onselect|onchange|accept|align][]select[E|name|size|multiple|disabled|tabindex|onfocus|onblur|onchange][optgroup|option]optgroup[E|disabled|label][option]option[E|selected|disabled|label|value][]textarea[E|D|name|rows|cols|disabled|readonly|onselect|onchange][]label[E|for|accesskey|onfocus|onblur][#|S]button[E|D|name|value|type|disabled][#|p|T|div|U|W|table|G|object|applet|img|map|K|N|Q]h4[E|align][#|S]ins[E|cite|datetime][#|Y]h5[E|align][#|S]del[E|cite|datetime][#|Y]h6[E|align][#|S]div[E|align][#|Y]ul[E|type|compact][li]li[E|type|value][#|Y]ol[E|type|compact|start][li]dl[E|compact][dt|dd]dt[E][#|S]dd[E][#|Y]menu[E|compact][li]dir[E|compact][li]pre[E|width|xml:space][#|ZA]hr[E|align|noshade|size|width][]blockquote[E|cite][#|Y]address[E][#|S|p]center[E][#|Y]noframes[E][#|Y]isindex[A|B|prompt][]fieldset[E][#|legend|Y]legend[E|accesskey|align][#|S]table[E|summary|width|border|frame|rules|cellspacing|cellpadding|align|bgcolor][caption|col|colgroup|thead|tfoot|tbody|tr]caption[E|align][#|S]col[ZG][]colgroup[ZG][col]thead[ZF][tr]tr[ZF|bgcolor][th|td]th[E|ZE][#|Y]form[E|action|method|name|enctype|onsubmit|onreset|accept|accept-charset|target][#|X|R|Q]noscript[E][#|Y]td[E|ZE][#|Y]tfoot[ZF][tr]tbody[ZF][tr]area[E|D|shape|coords|href|nohref|alt|target][]base[id|href|target][]body[E|onload|onunload|background|bgcolor|text|link|vlink|alink][#|Y]");
+g=k("checked,compact,declare,defer,disabled,ismap,multiple,nohref,noresize,noshade,nowrap,readonly,selected,preload,autoplay,loop,controls");a=k("area,base,basefont,br,col,frame,hr,img,input,isindex,link,meta,param,embed,source");f=c.extend(k("td,th,iframe,video,object"),a);d=k("pre,script,style");n=k("colgroup,dd,dt,li,options,p,td,tfoot,th,thead,tr");c.html.Schema=function(o){function e(a){var e,b,h,d,f,m,n,o,s,g,p,j,u,r,I,E,L,G,Q=/^([#+-])?([^\[\/]+)(?:\/([^\[]+))?(?:\[([^\]]+)\])?$/,O=/^([!\-])?(\w+::\w+|[^=:<]+)?(?:([=:<])(.*))?$/,
+R=/[*?+]/;if(a){a=i(a);if(l["@"])E=l["@"].attributes,L=l["@"].attributesOrder;e=0;for(b=a.length;e<b;e++)if(f=Q.exec(a[e])){r=f[1];s=f[2];I=f[3];o=f[4];j={};u=[];m={attributes:j,attributesOrder:u};if(r==="#")m.paddEmpty=!0;if(r==="-")m.removeEmpty=!0;if(E){for(G in E)j[G]=E[G];u.push.apply(u,L)}if(o){o=i(o,"|");h=0;for(d=o.length;h<d;h++)if(f=O.exec(o[h])){n={};p=f[1];g=f[2].replace(/::/g,":");r=f[3];f=f[4];if(p==="!")m.attributesRequired=m.attributesRequired||[],m.attributesRequired.push(g),n.required=
+!0;if(p==="-")delete j[g],u.splice(c.inArray(u,g),1);else{if(r){if(r==="=")m.attributesDefault=m.attributesDefault||[],m.attributesDefault.push({name:g,value:f}),n.defaultValue=f;if(r===":")m.attributesForced=m.attributesForced||[],m.attributesForced.push({name:g,value:f}),n.forcedValue=f;if(r==="<")n.validValues=k(f,"?")}R.test(g)?(m.attributePatterns=m.attributePatterns||[],n.pattern=RegExp("^"+g.replace(/([?+*])/g,".$1")+"$"),m.attributePatterns.push(n)):(j[g]||u.push(g),j[g]=n)}}}!E&&s=="@"&&
+(E=j,L=u);if(I)m.outputName=s,l[I]=m;R.test(s)?(m.pattern=RegExp("^"+s.replace(/([?+*])/g,".$1")+"$"),B.push(m)):l[s]=m}}}function h(a){l={};B=[];e(a);m(j,function(a,e){s[e]=a.children})}function p(a){var e=/^(~)?(.+)$/;a&&m(i(a),function(a){var a=e.exec(a),l=a[1]==="~"?"span":"div",b=a[2];s[b]=s[l];m(s,function(a){a[l]&&(a[b]=a[l])})})}function u(a){var e=/^([+\-]?)(\w+)\[([^\]]+)\]$/;a&&m(i(a),function(a){var a=e.exec(a),l,b;a&&(l=(b=a[1])?s[a[2]]:s[a[2]]={"#comment":{}},l=s[a[2]],m(i(a[3],"|"),
+function(a){b==="-"?delete l[a]:l[a]={}}))})}var l={},s={},B=[],r,o=o||{};if(o.verify_html===!1)o.valid_elements="*[*]";o.valid_styles&&(r={},m(o.valid_styles,function(a,e){r[e]=c.explode(a)}));o.valid_elements?h(o.valid_elements):(m(j,function(a,e){l[e]={attributes:a.attributes,attributesOrder:a.attributesOrder};s[e]=a.children}),m(i("strong/b,em/i"),function(a){a=i(a,"/");l[a[1]].outputName=a[0]}),l.img.attributesDefault=[{name:"alt",value:""}],m(i("ol,ul,li,sub,sup,blockquote,tr,div,span,font,a,table,tbody"),
+function(a){l[a].removeEmpty=!0}),m(i("p,h1,h2,h3,h4,h5,h6,th,td,pre,div,address,caption"),function(a){l[a].paddEmpty=!0}));p(o.custom_elements);u(o.valid_children);e(o.extended_valid_elements);u("+ol[ul|ol],+ul[ul|ol]");o.invalid_elements&&c.each(c.explode(o.invalid_elements),function(a){l[a]&&delete l[a]});this.children=s;this.styles=r;this.getBoolAttrs=function(){return g};this.getBlockElements=function(){return b};this.getShortEndedElements=function(){return a};this.getSelfClosingElements=function(){return n};
+this.getNonEmptyElements=function(){return f};this.getWhiteSpaceElements=function(){return d};this.isValidChild=function(a,e){var l=s[a];return!(!l||!l[e])};this.getElementRule=function(a){var e=l[a],b;if(e)return e;for(b=B.length;b--;)if(e=B[b],e.pattern.test(a))return e};this.addValidElements=e;this.setValidElements=h;this.addCustomElements=p;this.addValidChildren=u};c.html.Schema.boolAttrMap=g;c.html.Schema.blockElementsMap=b})(tinymce);
+(function(c){c.html.SaxParser=function(i,j){var g=this,b=function(){},i=i||{};g.schema=j=j||new c.html.Schema;if(i.fix_self_closing!==!1)i.fix_self_closing=!0;c.each("comment cdata text start end pi doctype".split(" "),function(a){a&&(g[a]=i[a]||b)});g.parse=function(a){function b(a){var l,h;for(l=e.length;l--;)if(e[l].name===a)break;if(l>=0){for(h=e.length-1;h>=l;h--)a=e[h],a.valid&&d.end(a.name);e.length=l}}var d=this,n,k=0,m,o,e=[],h,g,u,l,s,B,r,t,y,z,x,v,q,A,D,C,H,F,K,M=0,N=c.html.Entities.decode,
+P;H=RegExp("<(?:(?:!--([\\w\\W]*?)--\>)|(?:!\\[CDATA\\[([\\w\\W]*?)\\]\\]>)|(?:!DOCTYPE([\\w\\W]*?)>)|(?:\\?([^\\s\\/<>]+) ?([\\w\\W]*?)[?/]>)|(?:\\/([^>]+)>)|(?:([^\\s\\/<>]+)\\s*((?:[^\"'>]+(?:(?:\"[^\"]*\")|(?:'[^']*')|[^>]*))*)>))","g");F=/([\w:\-]+)(?:\s*=\s*(?:(?:\"((?:\\.|[^\"])*)\")|(?:\'((?:\\.|[^\'])*)\')|([^>\s]+)))?/g;K={script:/<\/script[^>]*>/gi,style:/<\/style[^>]*>/gi,noscript:/<\/noscript[^>]*>/gi};l=j.getShortEndedElements();C=j.getSelfClosingElements();s=j.getBoolAttrs();B=i.validate;
+for(P=i.fix_self_closing;n=H.exec(a);){k<n.index&&d.text(N(a.substr(k,n.index-k)));if(m=n[6])b(m.toLowerCase());else if(m=n[7]){m=m.toLowerCase();k=m in l;P&&C[m]&&e.length>0&&e[e.length-1].name===m&&b(m);if(!B||(r=j.getElementRule(m))){t=!0;if(B)x=r.attributes,v=r.attributePatterns;(z=n[8])?(h=[],h.map={},z.replace(F,function(a,e,l,b,k){e=e.toLowerCase();l=e in s?e:N(l||b||k||"");if(B&&e.indexOf("data-")!==0){a=x[e];if(!a&&v){for(b=v.length;b--;)if(a=v[b],a.pattern.test(e))break;b===-1&&(a=null)}if(!a)return;
+if(a.validValues&&!(l in a.validValues))return}h.map[e]=l;h.push({name:e,value:l})})):(h=[],h.map={});if(B){q=r.attributesRequired;A=r.attributesDefault;if(D=r.attributesForced)for(o=D.length;o--;)y=D[o],u=y.name,y=y.value,y==="{$uid}"&&(y="mce_"+M++),h.map[u]=y,h.push({name:u,value:y});if(A)for(o=A.length;o--;)if(y=A[o],u=y.name,!(u in h.map))y=y.value,y==="{$uid}"&&(y="mce_"+M++),h.map[u]=y,h.push({name:u,value:y});if(q){for(o=q.length;o--;)if(q[o]in h.map)break;o===-1&&(t=!1)}h.map["data-mce-bogus"]&&
+(t=!1)}t&&d.start(m,h,k)}else t=!1;if(o=K[m]){o.lastIndex=k=n.index+n[0].length;(n=o.exec(a))?(t&&(g=a.substr(k,n.index-k)),k=n.index+n[0].length):(g=a.substr(k),k=a.length);t&&g.length>0&&d.text(g,!0);t&&d.end(m);H.lastIndex=k;continue}k||(!z||z.indexOf("/")!=z.length-1?e.push({name:m,valid:t}):t&&d.end(m))}else(m=n[1])?d.comment(m):(m=n[2])?d.cdata(m):(m=n[3])?d.doctype(m):(m=n[4])&&d.pi(m,n[5]);k=n.index+n[0].length}k<a.length&&d.text(N(a.substr(k)));for(o=e.length-1;o>=0;o--)m=e[o],m.valid&&d.end(m.name)}}})(tinymce);
+(function(c){function i(a,b,d){var c;c=d?"lastChild":"firstChild";d=d?"prev":"next";if(a[c])return a[c];if(a!==b){if(c=a[d])return c;for(a=a.parent;a&&a!==b;a=a.parent)if(c=a[d])return c}}function j(a,b){this.name=a;this.type=b;if(b===1)this.attributes=[],this.attributes.map={}}var g=/^[ \t\r\n]*$/,b={"#text":3,"#comment":8,"#cdata":4,"#pi":7,"#doctype":10,"#document-fragment":11};c.extend(j.prototype,{replace:function(a){a.parent&&a.remove();this.insert(a,this);this.remove();return this},attr:function(a,
+b){var d,c;if(typeof a!=="string"){for(c in a)this.attr(c,a[c]);return this}if(d=this.attributes)if(b!==void 0){if(b===null){if(a in d.map){delete d.map[a];for(c=d.length;c--;)if(d[c].name===a){d.splice(c,1);break}}return this}if(a in d.map)for(c=d.length;c--;){if(d[c].name===a){d[c].value=b;break}}else d.push({name:a,value:b});d.map[a]=b;return this}else return d.map[a]},clone:function(){var a=new j(this.name,this.type),b,d,c,k,m;if(c=this.attributes){m=[];m.map={};b=0;for(d=c.length;b<d;b++)if(k=
+c[b],k.name!=="id")m[m.length]={name:k.name,value:k.value},m.map[k.name]=k.value;a.attributes=m}a.value=this.value;a.shortEnded=this.shortEnded;return a},wrap:function(a){this.parent.insert(a,this);a.append(this);return this},unwrap:function(){var a,b;for(a=this.firstChild;a;)b=a.next,this.insert(a,this,!0),a=b;this.remove()},remove:function(){var a=this.parent,b=this.next,d=this.prev;if(a){if(a.firstChild===this){if(a.firstChild=b)b.prev=null}else d.next=b;if(a.lastChild===this){if(a.lastChild=d)d.next=
+null}else b.prev=d;this.parent=this.next=this.prev=null}return this},append:function(a){var b;a.parent&&a.remove();(b=this.lastChild)?(b.next=a,a.prev=b,this.lastChild=a):this.lastChild=this.firstChild=a;a.parent=this;return a},insert:function(a,b,d){var c;a.parent&&a.remove();c=b.parent||this;d?(b===c.firstChild?c.firstChild=a:b.prev.next=a,a.prev=b.prev,a.next=b,b.prev=a):(b===c.lastChild?c.lastChild=a:b.next.prev=a,a.next=b.next,a.prev=b,b.next=a);a.parent=c;return a},getAll:function(a){var b,
+d=[];for(b=this.firstChild;b;b=i(b,this))b.name===a&&d.push(b);return d},empty:function(){var a,b,d;if(this.firstChild){a=[];for(d=this.firstChild;d;d=i(d,this))a.push(d);for(b=a.length;b--;)d=a[b],d.parent=d.firstChild=d.lastChild=d.next=d.prev=null}this.firstChild=this.lastChild=null;return this},isEmpty:function(a){var b=this.firstChild,d,c;if(b){do{if(b.type===1){if(b.attributes.map["data-mce-bogus"])continue;if(a[b.name])return!1;for(d=b.attributes.length;d--;)if(c=b.attributes[d].name,c==="name"||
+c.indexOf("data-")===0)return!1}if(b.type===3&&!g.test(b.value))return!1}while(b=i(b,this))}return!0}});c.extend(j,{create:function(a,c){var d,n;d=new j(a,b[a]||1);if(c)for(n in c)d.attr(n,c[n]);return d}});c.html.Node=j})(tinymce);
+(function(c){var i=c.html.Node;c.html.DomParser=function(j,g){function b(b){var k,e,h,d,f,l,n,j,r,t,y;t=c.makeMap("tr,td,th,tbody,thead,tfoot,table");r=g.getNonEmptyElements();for(k=0;k<b.length;k++)if(e=b[k],e.parent){d=[e];for(h=e.parent;h&&!g.isValidChild(h.name,e.name)&&!t[h.name];h=h.parent)d.push(h);if(h&&d.length>1){d.reverse();f=l=a.filterNode(d[0].clone());for(j=0;j<d.length-1;j++){g.isValidChild(l.name,d[j].name)?(n=a.filterNode(d[j].clone()),l.append(n)):n=l;for(l=d[j].firstChild;l&&l!=
+d[j+1];)y=l.next,n.append(l),l=y;l=n}f.isEmpty(r)?h.insert(e,d[0],!0):(h.insert(f,d[0],!0),h.insert(e,f));h=d[0];(h.isEmpty(r)||h.firstChild===h.lastChild&&h.firstChild.name==="br")&&h.empty().remove()}else if(e.parent)e.name==="li"?(h=e.prev)&&(h.name==="ul"||h.name==="ul")?h.append(e):(h=e.next)&&(h.name==="ul"||h.name==="ul")?h.insert(e,h.firstChild,!0):e.wrap(a.filterNode(new i("ul",1))):g.isValidChild(e.parent.name,"div")&&g.isValidChild("div",e.name)?e.wrap(a.filterNode(new i("div",1))):e.name===
+"style"||e.name==="script"?e.empty().remove():e.unwrap()}}var a=this,f={},d=[],n={},k={},j=j||{};j.validate="validate"in j?j.validate:!0;j.root_name=j.root_name||"body";a.schema=g=g||new c.html.Schema;a.filterNode=function(a){var b,e,h;e in f&&((h=n[e])?h.push(a):n[e]=[a]);for(b=d.length;b--;)e=d[b].name,e in a.attributes.map&&((h=k[e])?h.push(a):k[e]=[a]);return a};a.addNodeFilter=function(a,b){c.each(c.explode(a),function(a){var h=f[a];h||(f[a]=h=[]);h.push(b)})};a.addAttributeFilter=function(a,
+b){c.each(c.explode(a),function(a){var h;for(h=0;h<d.length;h++)if(d[h].name===a){d[h].callbacks.push(b);return}d.push({name:a,callbacks:[b]})})};a.parse=function(a,o){function e(a,e){var b=new i(a,e),l;a in f&&((l=n[a])?l.push(b):n[a]=[b]);return b}function h(a){for(var e,a=a.prev;a&&a.type===3;)e=a.value.replace(A,""),e.length>0?(a.value=e,a=a.prev):(e=a.prev,a.remove(),a=e)}var p,u,l,s,B,r,t,y,z,x,v,q=[],A,D,C,H,F,o=o||{};n={};k={};x=c.extend(c.makeMap("script,style,head,html,body,title,meta,param"),
+g.getBlockElements());F=g.getNonEmptyElements();H=g.children;z=j.validate;C=g.getWhiteSpaceElements();v=/^[ \t\r\n]+/;A=/[ \t\r\n]+$/;D=/[ \t\r\n]+/g;p=new c.html.SaxParser({validate:z,fix_self_closing:!z,cdata:function(a){l.append(e("#cdata",4)).value=a},text:function(a,b){var h;C[l.name]||(a=a.replace(D," "),l.lastChild&&x[l.lastChild.name]&&(a=a.replace(v,"")));if(a.length!==0)h=e("#text",3),h.raw=!!b,l.append(h).value=a},comment:function(a){l.append(e("#comment",8)).value=a},pi:function(a,b){l.append(e(a,
+7)).value=b;h(l)},doctype:function(a){l.append(e("#doctype",10)).value=a;h(l)},start:function(a,b,c){var m,f,n;if(m=z?g.getElementRule(a):{}){m=e(m.outputName||a,1);m.attributes=b;m.shortEnded=c;l.append(m);(f=H[l.name])&&H[m.name]&&!f[m.name]&&q.push(m);for(f=d.length;f--;)n=d[f].name,n in b.map&&((y=k[n])?y.push(m):k[n]=[m]);x[a]&&h(m);c||(l=m)}},end:function(a){var e,b;if(e=z?g.getElementRule(a):{}){if(x[a]){if(!C[l.name]){for(a=l.firstChild;a&&a.type===3;)b=a.value.replace(v,""),b.length>0?(a.value=
+b,a=a.next):(b=a.next,a.remove(),a=b);for(a=l.lastChild;a&&a.type===3;)b=a.value.replace(A,""),b.length>0?(a.value=b,a=a.prev):(b=a.prev,a.remove(),a=b)}if((a=l.prev)&&a.type===3)b=a.value.replace(v,""),b.length>0?a.value=b:a.remove()}if((e.removeEmpty||e.paddEmpty)&&l.isEmpty(F))if(e.paddEmpty)l.empty().append(new i("#text","3")).value="\u00a0";else if(!l.attributes.map.name){e=l.parent;l.empty().remove();l=e;return}l=l.parent}}},g);u=l=new i(j.root_name,11);p.parse(a);z&&b(q);for(t in n){y=f[t];
+p=n[t];for(r=p.length;r--;)p[r].parent||p.splice(r,1);s=0;for(B=y.length;s<B;s++)y[s](p,t,o)}s=0;for(B=d.length;s<B;s++)if(y=d[s],y.name in k){p=k[y.name];for(r=p.length;r--;)p[r].parent||p.splice(r,1);r=0;for(t=y.callbacks.length;r<t;r++)y.callbacks[r](p,y.name,o)}return u};j.remove_trailing_brs&&a.addNodeFilter("br",function(a){var b,e=a.length,h,k=g.getBlockElements(),d=g.getNonEmptyElements(),l,f,n;for(b=0;b<e;b++)if(h=a[b],l=h.parent,k[h.parent.name]&&h===l.lastChild){for(f=h.prev;f;){n=f.name;
+if(n!=="span"||f.attr("data-mce-type")!=="bookmark"){if(n!=="br")break;if(n==="br"){h=null;break}}f=f.prev}if(h&&(h.remove(),l.isEmpty(d)))if(elementRule=g.getElementRule(l.name),elementRule.removeEmpty)l.remove();else if(elementRule.paddEmpty)l.empty().append(new c.html.Node("#text",3)).value="\u00a0"}})}})(tinymce);
+tinymce.html.Writer=function(c){var i=[],j,g,b,a,f,c=c||{};j=c.indent;g=tinymce.makeMap(c.indent_before||"");b=tinymce.makeMap(c.indent_after||"");a=tinymce.html.Entities.getEncodeFunc(c.entity_encoding||"raw",c.entities);f=c.element_format=="html";return{start:function(d,c,k){var m,o,e;j&&g[d]&&i.length>0&&(m=i[i.length-1],m.length>0&&m!=="\n"&&i.push("\n"));i.push("<",d);if(c){m=0;for(o=c.length;m<o;m++)e=c[m],i.push(" ",e.name,'="',a(e.value,!0),'"')}i[i.length]=!k||f?">":" />";k&&j&&b[d]&&i.length>
+0&&(m=i[i.length-1],m.length>0&&m!=="\n"&&i.push("\n"))},end:function(a){i.push("</",a,">");j&&b[a]&&i.length>0&&(a=i[i.length-1],a.length>0&&a!=="\n"&&i.push("\n"))},text:function(b,c){b.length>0&&(i[i.length]=c?b:a(b))},cdata:function(a){i.push("<![CDATA[",a,"]]\>")},comment:function(a){i.push("<\!--",a,"--\>")},pi:function(a,b){b?i.push("<?",a," ",b,"?>"):i.push("<?",a,"?>");j&&i.push("\n")},doctype:function(a){i.push("<!DOCTYPE",a,">",j?"\n":"")},reset:function(){i.length=0},getContent:function(){return i.join("").replace(/\n$/,
+"")}}};
+(function(c){c.html.Serializer=function(i,j){var g=new c.html.Writer(i),i=i||{};i.validate="validate"in i?i.validate:!0;this.schema=j=j||new c.html.Schema;this.writer=g;this.serialize=function(b){function a(b){var k=c[b.type],m,o,e,h,p,i,l,s;if(k)k(b);else{k=b.name;m=b.shortEnded;o=b.attributes;if(d&&o&&o.length>1){p=[];p.map={};s=j.getElementRule(b.name);i=0;for(l=s.attributesOrder.length;i<l;i++)e=s.attributesOrder[i],e in o.map&&(h=o.map[e],p.map[e]=h,p.push({name:e,value:h}));i=0;for(l=o.length;i<
+l;i++)e=o[i].name,e in p.map||(h=o.map[e],p.map[e]=h,p.push({name:e,value:h}));o=p}g.start(b.name,o,m);if(!m){if(b=b.firstChild){do a(b);while(b=b.next)}g.end(k)}}}var c,d;d=i.validate;c={3:function(a){g.text(a.value,a.raw)},8:function(a){g.comment(a.value)},7:function(a){g.pi(a.name,a.value)},10:function(a){g.doctype(a.value)},4:function(a){g.cdata(a.value)},11:function(b){if(b=b.firstChild){do a(b);while(b=b.next)}}};g.reset();if(b.type==1&&!i.inner)a(b);else c[11](b);return g.getContent()}}})(tinymce);
+(function(c){var i=c.each,j=c.is,g=c.isWebKit,b=c.isIE,a=c.html.Entities,f=/^([a-z0-9],?)+$/i,d=c.html.Schema.blockElementsMap,n=/^[ \t\r\n]*$/;c.create("tinymce.dom.DOMUtils",{doc:null,root:null,files:null,pixelStyles:/^(top|left|bottom|right|width|height|borderWidth)$/,props:{"for":"htmlFor","class":"className",className:"className",checked:"checked",disabled:"disabled",maxlength:"maxLength",readonly:"readOnly",selected:"selected",value:"value",id:"id",name:"name",type:"type"},DOMUtils:function(a,
+d){this.doc=a;this.win=window;this.files={};this.cssFlicker=!1;this.counter=0;this.stdMode=!c.isIE||a.documentMode>=8;this.boxModel=!c.isIE||a.compatMode=="CSS1Compat"||this.stdMode;this.hasOuterHTML="outerHTML"in a.createElement("a");this.settings=d=c.extend({keep_values:!1,hex_colors:1},d);this.schema=d.schema;this.styles=new c.html.Styles({url_converter:d.url_converter,url_converter_scope:d.url_converter_scope},d.schema);if(c.isIE6)try{a.execCommand("BackgroundImageCache",!1,!0)}catch(f){this.cssFlicker=
+!0}b&&"abbr article aside audio canvas details figcaption figure footer header hgroup mark menu meter nav output progress section summary time video".replace(/\w+/g,function(e){a.createElement(e)});c.addUnload(this.destroy,this)},getRoot:function(){var a=this.settings;return a&&this.get(a.root_element)||this.doc.body},getViewPort:function(a){var b,a=!a?this.win:a;b=a.document;b=this.boxModel?b.documentElement:b.body;return{x:a.pageXOffset||b.scrollLeft,y:a.pageYOffset||b.scrollTop,w:a.innerWidth||
+b.clientWidth,h:a.innerHeight||b.clientHeight}},getRect:function(a){var b,a=this.get(a);b=this.getPos(a);a=this.getSize(a);return{x:b.x,y:b.y,w:a.w,h:a.h}},getSize:function(a){var b,d,a=this.get(a);b=this.getStyle(a,"width");d=this.getStyle(a,"height");b.indexOf("px")===-1&&(b=0);d.indexOf("px")===-1&&(d=0);return{w:parseInt(b)||a.offsetWidth||a.clientWidth,h:parseInt(d)||a.offsetHeight||a.clientHeight}},getParent:function(a,b,d){return this.getParents(a,b,d,!1)},getParents:function(a,b,d,e){var h=
+this,c,f=h.settings,l=[],a=h.get(a),e=e===void 0;f.strict_root&&(d=d||h.getRoot());j(b,"string")&&(c=b,b=b==="*"?function(a){return a.nodeType==1}:function(a){return h.is(a,c)});for(;a;){if(a==d||!a.nodeType||a.nodeType===9)break;if(!b||b(a))if(e)l.push(a);else return a;a=a.parentNode}return e?l:null},get:function(a){var b;if(a&&this.doc&&typeof a=="string"&&(b=a,(a=this.doc.getElementById(a))&&a.id!==b))return this.doc.getElementsByName(b)[1];return a},getNext:function(a,b){return this._findSib(a,
+b,"nextSibling")},getPrev:function(a,b){return this._findSib(a,b,"previousSibling")},select:function(a,b){return c.dom.Sizzle(a,this.get(b)||this.get(this.settings.root_element)||this.doc,[])},is:function(a,b){var d;if(a.length===void 0){if(b==="*")return a.nodeType==1;if(f.test(b)){b=b.toLowerCase().split(/,/);a=a.nodeName.toLowerCase();for(d=b.length-1;d>=0;d--)if(b[d]==a)return!0;return!1}}return c.dom.Sizzle.matches(b,a.nodeType?[a]:a).length>0},add:function(a,b,d,e,h){var c=this;return this.run(a,
+function(a){var l;l=j(b,"string")?c.doc.createElement(b):b;c.setAttribs(l,d);e&&(e.nodeType?l.appendChild(e):c.setHTML(l,e));return!h?a.appendChild(l):l})},create:function(a,b,d){return this.add(this.doc.createElement(a),a,b,d,1)},createHTML:function(a,b,d){var e="",h;e+="<"+a;for(h in b)b.hasOwnProperty(h)&&(e+=" "+h+'="'+this.encode(b[h])+'"');if(typeof d!="undefined")return e+">"+d+"</"+a+">";return e+" />"},remove:function(a,b){return this.run(a,function(a){var e,h=a.parentNode;if(!h)return null;
+if(b)for(;e=a.firstChild;)!c.isIE||e.nodeType!==3||e.nodeValue?h.insertBefore(e,a):a.removeChild(e);return h.removeChild(a)})},setStyle:function(a,d,f){var e=this;return e.run(a,function(h){var g;g=h.style;d=d.replace(/-(\D)/g,function(a,b){return b.toUpperCase()});if(e.pixelStyles.test(d)&&(c.is(f,"number")||/^[\-0-9\.]+$/.test(f)))f+="px";switch(d){case "opacity":if(b&&(g.filter=f===""?"":"alpha(opacity="+f*100+")",!a.currentStyle||!a.currentStyle.hasLayout))g.display="inline-block";g[d]=g["-moz-opacity"]=
+g["-khtml-opacity"]=f||"";break;case "float":b?g.styleFloat=f:g.cssFloat=f;break;default:g[d]=f||""}e.settings.update_styles&&e.setAttrib(h,"data-mce-style")})},getStyle:function(a,d,c){if(a=this.get(a)){if(this.doc.defaultView&&c){d=d.replace(/[A-Z]/g,function(a){return"-"+a});try{return this.doc.defaultView.getComputedStyle(a,null).getPropertyValue(d)}catch(e){return null}}d=d.replace(/-(\D)/g,function(a,b){return b.toUpperCase()});d=="float"&&(d=b?"styleFloat":"cssFloat");if(a.currentStyle&&c)return a.currentStyle[d];
+return a.style?a.style[d]:void 0}},setStyles:function(a,b){var d=this,e=d.settings,h;h=e.update_styles;e.update_styles=0;i(b,function(b,e){d.setStyle(a,e,b)});e.update_styles=h;e.update_styles&&d.setAttrib(a,e.cssText)},removeAllAttribs:function(a){return this.run(a,function(a){var b,e=a.attributes;for(b=e.length-1;b>=0;b--)a.removeAttributeNode(e.item(b))})},setAttrib:function(a,b,d){var e=this;if(a&&b)return e.settings.strict&&(b=b.toLowerCase()),this.run(a,function(a){var k=e.settings;switch(b){case "style":if(!j(d,
+"string")){i(d,function(b,l){e.setStyle(a,l,b)});return}k.keep_values&&(d&&!e._isRes(d)?a.setAttribute("data-mce-style",d,2):a.removeAttribute("data-mce-style",2));a.style.cssText=d;break;case "class":a.className=d||"";break;case "src":case "href":k.keep_values&&(k.url_converter&&(d=k.url_converter.call(k.url_converter_scope||e,d,b,a)),e.setAttrib(a,"data-mce-"+b,d,2));break;case "shape":a.setAttribute("data-mce-style",d)}j(d)&&d!==null&&d.length!==0?a.setAttribute(b,""+d,2):a.removeAttribute(b,2)})},
+setAttribs:function(a,b){var d=this;return this.run(a,function(a){i(b,function(b,k){d.setAttrib(a,k,b)})})},getAttrib:function(a,d,f){var e,a=this.get(a);if(!a||a.nodeType!==1)return!1;j(f)||(f="");if(/^(src|href|style|coords|shape)$/.test(d)&&(e=a.getAttribute("data-mce-"+d)))return e;b&&this.props[d]&&(e=(e=a[this.props[d]])&&e.nodeValue?e.nodeValue:e);e||(e=a.getAttribute(d,2));if(/^(checked|compact|declare|defer|disabled|ismap|multiple|nohref|noshade|nowrap|readonly|selected)$/.test(d)){if(a[this.props[d]]===
+!0&&e==="")return d;return e?d:""}if(a.nodeName==="FORM"&&a.getAttributeNode(d))return a.getAttributeNode(d).nodeValue;if(d==="style"&&(e=e||a.style.cssText))e=this.serializeStyle(this.parseStyle(e),a.nodeName),this.settings.keep_values&&!this._isRes(e)&&a.setAttribute("data-mce-style",e);g&&d==="class"&&e&&(e=e.replace(/(apple|webkit)\-[a-z\-]+/gi,""));if(b)switch(d){case "rowspan":case "colspan":e===1&&(e="");break;case "size":if(e==="+0"||e===20||e===0)e="";break;case "width":case "height":case "vspace":case "checked":case "disabled":case "readonly":e===
+0&&(e="");break;case "hspace":e===-1&&(e="");break;case "maxlength":case "tabindex":if(e===32768||e===2147483647||e==="32768")e="";break;case "multiple":case "compact":case "noshade":case "nowrap":if(e===65535)return d;return f;case "shape":e=e.toLowerCase();break;default:d.indexOf("on")===0&&e&&(e=c._replace(/^function\s+\w+\(\)\s+\{\s+(.*)\s+\}$/,"$1",""+e))}return e!==void 0&&e!==null&&e!==""?""+e:f},getPos:function(a,d){var c=0,e=0,h=this.doc,a=this.get(a),d=d||h.body;if(a){if(b&&!this.stdMode)return a=
+a.getBoundingClientRect(),e=this.boxModel?h.documentElement:h.body,c=this.getStyle(this.select("html")[0],"borderWidth"),c=(c=="medium"||this.boxModel&&!this.isIE6)&&2||c,{x:a.left+e.scrollLeft-c,y:a.top+e.scrollTop-c};for(h=a;h&&h!=d&&h.nodeType;)c+=h.offsetLeft||0,e+=h.offsetTop||0,h=h.offsetParent;for(h=a.parentNode;h&&h!=d&&h.nodeType;)c-=h.scrollLeft||0,e-=h.scrollTop||0,h=h.parentNode}return{x:c,y:e}},parseStyle:function(a){return this.styles.parse(a)},serializeStyle:function(a,b){return this.styles.serialize(a,
+b)},loadCSS:function(a){var d=this,f=d.doc,e;a||(a="");e=d.select("head")[0];i(a.split(","),function(a){var k;if(!d.files[a]){d.files[a]=!0;k=d.create("link",{rel:"stylesheet",href:c._addVer(a)});if(b&&f.documentMode&&f.recalc)k.onload=function(){f.recalc&&f.recalc();k.onload=null};e.appendChild(k)}})},addClass:function(a,b){return this.run(a,function(a){var e;if(!b)return 0;if(this.hasClass(a,b))return a.className;e=this.removeClass(a,b);return a.className=(e!=""?e+" ":"")+b})},removeClass:function(a,
+b){var d=this,e;return d.run(a,function(a){var f;if(d.hasClass(a,b))return e||(e=RegExp("(^|\\s+)"+b+"(\\s+|$)","g")),f=a.className.replace(e," "),f=c.trim(f!=" "?f:""),a.className=f,f||(a.removeAttribute("class"),a.removeAttribute("className")),f;return a.className})},hasClass:function(a,b){a=this.get(a);if(!a||!b)return!1;return(" "+a.className+" ").indexOf(" "+b+" ")!==-1},show:function(a){return this.setStyle(a,"display","block")},hide:function(a){return this.setStyle(a,"display","none")},isHidden:function(a){a=
+this.get(a);return!a||a.style.display=="none"||this.getStyle(a,"display")=="none"},uniqueId:function(a){return(!a?"mce_":a)+this.counter++},setHTML:function(a,d){var c=this;return c.run(a,function(a){if(b){for(;a.firstChild;)a.removeChild(a.firstChild);try{a.innerHTML="<br />"+d,a.removeChild(a.firstChild)}catch(h){a=c.create("div"),a.innerHTML="<br />"+d,i(a.childNodes,function(b,d){d&&a.appendChild(b)})}}else a.innerHTML=d;return d})},getOuterHTML:function(a){var b,a=this.get(a);if(!a)return null;
+if(a.nodeType===1&&this.hasOuterHTML)return a.outerHTML;b=(a.ownerDocument||this.doc).createElement("body");b.appendChild(a.cloneNode(!0));return b.innerHTML},setOuterHTML:function(a,d,c){function e(a,b,e){e=e.createElement("body");e.innerHTML=b;for(b=e.lastChild;b;)h.insertAfter(b.cloneNode(!0),a),b=b.previousSibling;h.remove(a)}var h=this;return this.run(a,function(a){a=h.get(a);if(a.nodeType==1)if(c=c||a.ownerDocument||h.doc,b)try{b&&a.nodeType==1?a.outerHTML=d:e(a,d,c)}catch(f){e(a,d,c)}else e(a,
+d,c)})},decode:a.decode,encode:a.encodeAllRaw,insertAfter:function(a,b){b=this.get(b);return this.run(a,function(a){var e,d;e=b.parentNode;(d=b.nextSibling)?e.insertBefore(a,d):e.appendChild(a);return a})},isBlock:function(a){var b=a.nodeType;if(b)return!!(b===1&&d[a.nodeName]);return!!d[a]},replace:function(a,b,d){j(b,"array")&&(a=a.cloneNode(!0));return this.run(b,function(b){d&&i(c.grep(b.childNodes),function(b){a.appendChild(b)});return b.parentNode.replaceChild(a,b)})},rename:function(a,b){var d=
+this,e;a.nodeName!=b.toUpperCase()&&(e=d.create(b),i(d.getAttribs(a),function(b){d.setAttrib(e,b.nodeName,d.getAttrib(a,b.nodeName))}),d.replace(e,a,1));return e||a},findCommonAncestor:function(a,b){for(var d=a,e;d;){for(e=b;e&&d!=e;)e=e.parentNode;if(d==e)break;d=d.parentNode}if(!d&&a.ownerDocument)return a.ownerDocument.documentElement;return d},toHex:function(a){function b(a){a=parseInt(a).toString(16);return a.length>1?a:"0"+a}var d=/^\s*rgb\s*?\(\s*?([0-9]+)\s*?,\s*?([0-9]+)\s*?,\s*?([0-9]+)\s*?\)\s*$/i.exec(a);
+d&&(a="#"+b(d[1])+b(d[2])+b(d[3]));return a},getClasses:function(){function a(f){i(f.imports,function(b){a(b)});i(f.cssRules||f.rules,function(l){switch(l.type||1){case 1:l.selectorText&&i(l.selectorText.split(","),function(a){a=a.replace(/^\s*|\s*$|^\s\./g,"");if(!/\.mce/.test(a)&&/\.[\w\-]+$/.test(a)&&(h=a,a=c._replace(/.*\.([a-z0-9_\-]+).*/i,"$1",a),(!e||(a=e(a,h)))&&!d[a]))b.push({"class":a}),d[a]=1});break;case 3:a(l.styleSheet)}})}var b=[],d={},e=this.settings.class_filter,h;if(this.classes)return this.classes;
+try{i(this.doc.styleSheets,a)}catch(f){}if(b.length>0)this.classes=b;return b},run:function(a,b,d){var e=this,h;e.doc&&typeof a==="string"&&(a=e.get(a));if(!a)return!1;d=d||this;if(!a.nodeType&&(a.length||a.length===0))return h=[],i(a,function(a,c){a&&(typeof a=="string"&&(a=e.doc.getElementById(a)),h.push(b.call(d,a,c)))}),h;return b.call(d,a)},getAttribs:function(a){var d,a=this.get(a);if(!a)return[];if(b){d=[];if(a.nodeName=="OBJECT")return a.attributes;a.nodeName==="OPTION"&&this.getAttrib(a,
+"selected")&&d.push({specified:1,nodeName:"selected"});a.cloneNode(!1).outerHTML.replace(/<\/?[\w:\-]+ ?|=[\"][^\"]+\"|=\'[^\']+\'|=[\w\-]+|>/gi,"").replace(/[\w:\-]+/gi,function(a){d.push({specified:1,nodeName:a})});return d}return a.attributes},isEmpty:function(a,b){var d,e,h,f;if(a=a.firstChild){h=new c.dom.TreeWalker(a);b=b||this.schema?this.schema.getNonEmptyElements():null;do{e=a.nodeType;if(e===1){if(a.getAttribute("data-mce-bogus"))continue;if(b&&b[a.nodeName.toLowerCase()])return!1;this.getAttribs(a);
+for(d=a.attributes.length;d--;)if(f=a.attributes[d].nodeName,f==="name"||f.indexOf("data-")===0)return!1}if(e===3&&!n.test(a.nodeValue))return!1}while(a=h.next())}return!0},destroy:function(a){this.events&&this.events.destroy();this.win=this.doc=this.root=this.events=null;a||c.removeUnload(this.destroy)},createRng:function(){var a=this.doc;return a.createRange?a.createRange():new c.dom.Range(this)},nodeIndex:function(a,b){var d=0,e,h,c;if(a){e=a.nodeType;for(a=a.previousSibling;a;a=a.previousSibling){h=
+a.nodeType;if(b&&h==3){c=!1;try{c=a.nodeValue.length}catch(f){}if(h==e||!c)continue}d++;e=h}}return d},split:function(a,b,d){function e(a){var b,d=a.childNodes,l=a.nodeType;if(!(l==1&&a.getAttribute("data-mce-type")=="bookmark")){for(b=d.length-1;b>=0;b--)e(d[b]);if(l!=9){if(l==3&&a.nodeValue.length>0){if(!h.isBlock(a.parentNode)||c.trim(a.nodeValue).length>0)return}else if(l==1&&(d=a.childNodes,d.length==1&&d[0]&&d[0].nodeType==1&&d[0].getAttribute("data-mce-type")=="bookmark"&&a.parentNode.insertBefore(d[0],
+a),d.length||/^(br|hr|input|img)$/i.test(a.nodeName)))return;h.remove(a)}return a}}var h=this,f=h.createRng(),g,l;if(a&&b)return f.setStart(a.parentNode,h.nodeIndex(a)),f.setEnd(b.parentNode,h.nodeIndex(b)),g=f.extractContents(),f=h.createRng(),f.setStart(b.parentNode,h.nodeIndex(b)+1),f.setEnd(a.parentNode,h.nodeIndex(a)+1),f=f.extractContents(),l=a.parentNode,l.insertBefore(e(g),a),d?l.replaceChild(d,b):l.insertBefore(b,a),l.insertBefore(e(f),a),h.remove(a),d||b},bind:function(a,b,d,e){if(!this.events)this.events=
+new c.dom.EventUtils;return this.events.add(a,b,d,e||this)},unbind:function(a,b,d){if(!this.events)this.events=new c.dom.EventUtils;return this.events.remove(a,b,d)},_findSib:function(a,b,d){var e=this,h=b;if(a){j(h,"string")&&(h=function(a){return e.is(a,b)});for(a=a[d];a;a=a[d])if(h(a))return a}return null},_isRes:function(a){return/^(top|left|bottom|right|width|height)/i.test(a)||/;\s*(top|left|bottom|right|width|height)/i.test(a)}});c.DOM=new c.dom.DOMUtils(document,{process_html:0})})(tinymce);
+(function(c){function i(c){function g(a,b){k(t,a,b)}function b(a,b){k(y,a,b)}function a(a){g(a.parentNode,D(a))}function f(a){b(a.parentNode,D(a)+1)}function d(a,b){var e;if(a.nodeType==3)return a;if(b<0)return a;for(e=a.firstChild;e&&b>0;)--b,e=e.nextSibling;if(e)return e;return a}function n(a,b,e,d){var l,h;if(a==e){if(b==d)return 0;if(b<d)return-1;return 1}for(l=e;l&&l.parentNode!=a;)l=l.parentNode;if(l){h=0;for(e=a.firstChild;e!=l&&h<b;)h++,e=e.nextSibling;if(b<=h)return-1;return 1}for(l=a;l&&
+l.parentNode!=e;)l=l.parentNode;if(l){h=0;for(e=e.firstChild;e!=l&&h<d;)h++,e=e.nextSibling;if(h<d)return-1;return 1}for(b=c.findCommonAncestor(a,e);a&&a.parentNode!=b;)a=a.parentNode;a||(a=b);for(d=e;d&&d.parentNode!=b;)d=d.parentNode;d||(d=b);if(a==d)return 0;for(e=b.firstChild;e;){if(e==a)return-1;if(e==d)return 1;e=e.nextSibling}}function k(a,b,e){a?(l[x]=b,l[z]=e):(l[v]=b,l[q]=e);for(b=l[v];b.parentNode;)b=b.parentNode;for(e=l[x];e.parentNode;)e=e.parentNode;e==b?n(l[x],l[z],l[v],l[q])>0&&l.collapse(a):
+l.collapse(a);l.collapsed=l[x]==l[v]&&l[z]==l[q];l.commonAncestorContainer=c.findCommonAncestor(l[x],l[v])}function m(a){var b,d=0,c=0,f;if(l[x]==l[v])return o(a);b=l[v];for(f=b.parentNode;f;b=f,f=f.parentNode){if(f==l[x]){var g=b;f=c=d=f=b=void 0;a!=r&&(b=s.createDocumentFragment());f=e(g,a);b&&b.appendChild(f);d=D(g)-l[z];if(!(d<=0))for(f=g.previousSibling;d>0;)c=f.previousSibling,f=u(f,a),b&&b.insertBefore(f,b.firstChild),--d,f=c;a!=B&&(l.setEndBefore(g),l.collapse(y));a=b;return a}++d}b=l[x];
+for(f=b.parentNode;f;b=f,f=f.parentNode){if(f==l[v]){g=b;f=c=d=f=d=b=void 0;a!=r&&(b=s.createDocumentFragment());f=h(g,a);b&&b.appendChild(f);d=D(g);++d;d=l[q]-d;for(f=g.nextSibling;d>0;)c=f.nextSibling,f=u(f,a),b&&b.appendChild(f),--d,f=c;a!=B&&(l.setStartAfter(g),l.collapse(t));return b}++c}c-=d;for(b=l[x];c>0;)b=b.parentNode,c--;for(d=l[v];c<0;)d=d.parentNode,c++;c=b.parentNode;for(f=d.parentNode;c!=f;c=c.parentNode,f=f.parentNode)b=c,d=f;var k;a!=r&&(g=s.createDocumentFragment());k=h(b,a);g&&
+g.appendChild(k);c=D(b);f=D(d);++c;c=f-c;for(k=b.nextSibling;c>0;)f=k.nextSibling,k=u(k,a),g&&g.appendChild(k),k=f,--c;k=e(d,a);g&&g.appendChild(k);a!=B&&(l.setStartAfter(b),l.collapse(t));return g}function o(a){var b,e,h,f;a!=r&&(b=s.createDocumentFragment());if(l[z]==l[q])return b;if(l[x].nodeType==3){e=l[x].nodeValue;e=e.substring(l[z],l[q]);a!=B&&(l[x].deleteData(l[z],l[q]-l[z]),l.collapse(t));if(a==r)return;b.appendChild(s.createTextNode(e));return b}h=d(l[x],l[z]);for(e=l[q]-l[z];e>0;)f=h.nextSibling,
+h=u(h,a),b&&b.appendChild(h),--e,h=f;a!=B&&l.collapse(t);return b}function e(a,b){var e=d(l[v],l[q]-1),h,f,c,g=e!=l[v];if(e==a)return p(e,g,y,b);h=e.parentNode;for(f=p(h,y,y,b);h;){for(;e;)c=e.previousSibling,e=p(e,g,y,b),b!=r&&f.insertBefore(e,f.firstChild),g=t,e=c;if(h==a)return f;e=h.previousSibling;h=h.parentNode;c=p(h,y,y,b);b!=r&&c.appendChild(f);f=c}}function h(a,b){var e=d(l[x],l[z]),h=e!=l[x],f,c,g;if(e==a)return p(e,h,t,b);f=e.parentNode;for(c=p(f,y,t,b);f;){for(;e;)g=e.nextSibling,e=p(e,
+h,t,b),b!=r&&c.appendChild(e),h=t,e=g;if(f==a)return c;e=f.nextSibling;f=f.parentNode;g=p(f,y,t,b);b!=r&&g.appendChild(c);c=g}}function p(a,b,e,d){var h;if(b)return u(a,d);if(a.nodeType==3){b=a.nodeValue;e?(h=l[z],e=b.substring(h),b=b.substring(0,h)):(h=l[q],e=b.substring(0,h),b=b.substring(h));if(d!=B)a.nodeValue=b;if(d==r)return;a=a.cloneNode(y);a.nodeValue=e;return a}if(d!=r)return a.cloneNode(y)}function u(a,b){if(b!=r)return b==B?a.cloneNode(t):a;a.parentNode.removeChild(a)}var l=this,s=c.doc,
+B=1,r=2,t=!0,y=!1,z="startOffset",x="startContainer",v="endContainer",q="endOffset",A=tinymce.extend,D=c.nodeIndex;A(l,{startContainer:s,startOffset:0,endContainer:s,endOffset:0,collapsed:t,commonAncestorContainer:s,START_TO_START:0,START_TO_END:1,END_TO_END:2,END_TO_START:3,setStart:g,setEnd:b,setStartBefore:a,setStartAfter:function(a){g(a.parentNode,D(a)+1)},setEndBefore:function(a){b(a.parentNode,D(a))},setEndAfter:f,collapse:function(a){a?(l[v]=l[x],l[q]=l[z]):(l[x]=l[v],l[z]=l[q]);l.collapsed=
+t},selectNode:function(b){a(b);f(b)},selectNodeContents:function(a){g(a,0);b(a,a.nodeType===1?a.childNodes.length:a.nodeValue.length)},compareBoundaryPoints:function(a,b){var e=l[x],d=l[z],h=l[v],f=l[q],c=b.startContainer,g=b.startOffset,k=b.endContainer,s=b.endOffset;if(a===0)return n(e,d,c,g);if(a===1)return n(h,f,c,g);if(a===2)return n(h,f,k,s);if(a===3)return n(e,d,k,s)},deleteContents:function(){m(r)},extractContents:function(){return m(0)},cloneContents:function(){return m(B)},insertNode:function(a){var b=
+this[x],e=this[z],d;(b.nodeType===3||b.nodeType===4)&&b.nodeValue?e?e>=b.nodeValue.length?c.insertAfter(a,b):(e=b.splitText(e),b.parentNode.insertBefore(a,e)):b.parentNode.insertBefore(a,b):(b.childNodes.length>0&&(d=b.childNodes[e]),d?b.insertBefore(a,d):b.appendChild(a))},surroundContents:function(a){var b=l.extractContents();l.insertNode(a);a.appendChild(b);l.selectNode(a)},cloneRange:function(){return A(new i(c),{startContainer:l[x],startOffset:l[z],endContainer:l[v],endOffset:l[q],collapsed:l.collapsed,
+commonAncestorContainer:l.commonAncestorContainer})}})}c.Range=i})(tinymce.dom);
+(function(){tinymce.dom.TridentSelection=function(c){function i(){function b(e){var d,c,j,l=0,s,i,m,o;j=f.duplicate();j.collapse(e);d=a.create("a");m=j.parentElement();if(m.hasChildNodes())if(m.appendChild(d),j.moveToElementText(d),o=f.compareEndPoints(e?"StartToStart":"EndToEnd",j),o>0)g[e?"setStartAfter":"setEndAfter"](m),a.remove(d);else{c=tinymce.grep(m.childNodes);for(s=c.length-1;l<=s;)if(i=Math.floor((l+s)/2),m.insertBefore(d,c[i]),j.moveToElementText(d),o=f.compareEndPoints(e?"StartToStart":
+"EndToEnd",j),o>0)l=i+1;else if(o<0)s=i-1;else{found=!0;break}c=o>0||i==0?d.nextSibling:d.previousSibling;c.nodeType==1?(a.remove(d),j=a.nodeIndex(c),c=c.parentNode,(!e||i>0)&&j++):(o>0||i==0?(j.setEndPoint(e?"StartToStart":"EndToEnd",f),j=j.text.length):(j.setEndPoint(e?"StartToStart":"EndToEnd",f),j=c.nodeValue.length-j.text.length),a.remove(d));g[e?"setStart":"setEnd"](c,j)}else g[e?"setStart":"setEnd"](m,0)}var f=c.getRng(),g=a.createRng(),j,i;j=f.item?f.item(0):f.parentElement();if(j.ownerDocument!=
+a.doc)return g;i=c.isCollapsed();if(f.item||!j.hasChildNodes())return i?(g.setStart(j,0),g.setEnd(j,0)):(g.setStart(j.parentNode,a.nodeIndex(j)),g.setEnd(g.startContainer,g.startOffset+1)),g;b(!0);i||b();return g}var j="\ufeff",g,b,a=c.dom,f=!0;this.addRange=function(b){function g(b){var d,c,n,s,i;n=a.create("a");d=b?o:h;c=b?e:p;s=k.duplicate();if(d==u||d==u.documentElement)d=l,c=0;d.nodeType==3?(d.parentNode.insertBefore(n,d),s.moveToElementText(n),s.moveStart("character",c),a.remove(n),k.setEndPoint(b?
+"StartToStart":"EndToEnd",s)):(i=d.childNodes,i.length?(c>=i.length?a.insertAfter(n,i[i.length-1]):d.insertBefore(n,i[c]),s.moveToElementText(n)):(n=u.createTextNode(j),d.appendChild(n),s.moveToElementText(n.parentNode),s.collapse(f)),k.setEndPoint(b?"StartToStart":"EndToEnd",s),a.remove(n))}var k,i,o,e,h,p,u=c.dom.doc,l=u.body;this.destroy();o=b.startContainer;e=b.startOffset;h=b.endContainer;p=b.endOffset;k=l.createTextRange();if(o==h&&o.nodeType==1&&e==p-1&&e==p-1)try{i=l.createControlRange();
+i.addElement(o.childNodes[e]);i.select();return}catch(s){}g(!0);g();k.select()};this.getRangeAt=function(){if(!g||!tinymce.dom.RangeUtils.compareRanges(b,c.getRng()))g=i(),b=c.getRng();return g};this.destroy=function(){b=g=null}}})();
+(function(){function c(a,b,e,d,h,f){for(var h=0,c=d.length;h<c;h++){var g=d[h];if(g){for(var g=g[a],k=!1;g;){if(g.sizcache===e){k=d[g.sizset];break}if(g.nodeType===1&&!f)g.sizcache=e,g.sizset=h;if(g.nodeName.toLowerCase()===b){k=g;break}g=g[a]}d[h]=k}}}function i(a,b,e,h,f,c){for(var f=0,g=h.length;f<g;f++){var k=h[f];if(k){for(var k=k[a],n=!1;k;){if(k.sizcache===e){n=h[k.sizset];break}if(k.nodeType===1){if(!c)k.sizcache=e,k.sizset=f;if(typeof b!=="string"){if(k===b){n=!0;break}}else if(d.filter(b,
+[k]).length>0){n=k;break}}k=k[a]}h[f]=n}}}var j=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^\[\]]*\]|['"][^'"]*['"]|[^\[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,g=0,b=Object.prototype.toString,a=!1,f=!0;[0,0].sort(function(){f=!1;return 0});var d=function(a,h,f,c){var f=f||[],g=h=h||document;if(h.nodeType!==1&&h.nodeType!==9)return[];if(!a||typeof a!=="string")return f;var i=[],m,o,p,q,A=!0,D=d.isXML(h),C=a,H;do if(j.exec(""),m=j.exec(C))if(C=m[3],i.push(m[1]),m[2]){q=m[3];break}while(m);
+if(i.length>1&&k.exec(a))if(i.length===2&&n.relative[i[0]])o=u(i[0]+i[1],h);else for(o=n.relative[i[0]]?[h]:d(i.shift(),h);i.length;)a=i.shift(),n.relative[a]&&(a+=i.shift()),o=u(a,o);else if(!c&&i.length>1&&h.nodeType===9&&!D&&n.match.ID.test(i[0])&&!n.match.ID.test(i[i.length-1])&&(m=d.find(i.shift(),h,D),h=m.expr?d.filter(m.expr,m.set)[0]:m.set[0]),h){m=c?{expr:i.pop(),set:e(c)}:d.find(i.pop(),i.length===1&&(i[0]==="~"||i[0]==="+")&&h.parentNode?h.parentNode:h,D);o=m.expr?d.filter(m.expr,m.set):
+m.set;for(i.length>0?p=e(o):A=!1;i.length;)m=H=i.pop(),n.relative[H]?m=i.pop():H="",m==null&&(m=h),n.relative[H](p,m,D)}else p=[];p||(p=o);p||d.error(H||a);if(b.call(p)==="[object Array]")if(A)if(h&&h.nodeType===1)for(a=0;p[a]!=null;a++)p[a]&&(p[a]===!0||p[a].nodeType===1&&d.contains(h,p[a]))&&f.push(o[a]);else for(a=0;p[a]!=null;a++)p[a]&&p[a].nodeType===1&&f.push(o[a]);else f.push.apply(f,p);else e(p,f);q&&(d(q,g,f,c),d.uniqueSort(f));return f};d.uniqueSort=function(b){if(p&&(a=f,b.sort(p),a))for(var e=
+1;e<b.length;e++)b[e]===b[e-1]&&b.splice(e--,1);return b};d.matches=function(a,b){return d(a,null,null,b)};d.find=function(a,b,e){var d;if(!a)return[];for(var h=0,f=n.order.length;h<f;h++){var c=n.order[h],g;if(g=n.leftMatch[c].exec(a)){var k=g[1];g.splice(1,1);if(k.substr(k.length-1)!=="\\"&&(g[1]=(g[1]||"").replace(/\\/g,""),d=n.find[c](g,b,e),d!=null)){a=a.replace(n.match[c],"");break}}}d||(d=b.getElementsByTagName("*"));return{set:d,expr:a}};d.filter=function(a,b,e,h){for(var f=a,c=[],g=b,k,i,
+j=b&&b[0]&&d.isXML(b[0]);a&&b.length;){for(var m in n.filter)if((k=n.leftMatch[m].exec(a))!=null&&k[2]){var o=n.filter[m],p,u;u=k[1];i=!1;k.splice(1,1);if(u.substr(u.length-1)!=="\\"){g===c&&(c=[]);if(n.preFilter[m])if(k=n.preFilter[m](k,g,e,c,h,j)){if(k===!0)continue}else i=p=!0;if(k)for(var F=0;(u=g[F])!=null;F++)if(u){p=o(u,k,F,g);var K=h^!!p;e&&p!=null?K?i=!0:g[F]=!1:K&&(c.push(u),i=!0)}if(p!==void 0){e||(g=c);a=a.replace(n.match[m],"");if(!i)return[];break}}}if(a===f)if(i==null)d.error(a);else break;
+f=a}return g};d.error=function(a){throw"Syntax error, unrecognized expression: "+a;};var n=d.selectors={order:["ID","NAME","TAG"],match:{ID:/#((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,CLASS:/\.((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,NAME:/\[name=['"]*((?:[\w\u00c0-\uFFFF\-]|\\.)+)['"]*\]/,ATTR:/\[\s*((?:[\w\u00c0-\uFFFF\-]|\\.)+)\s*(?:(\S?=)\s*(['"]*)(.*?)\3|)\s*\]/,TAG:/^((?:[\w\u00c0-\uFFFF\*\-]|\\.)+)/,CHILD:/:(only|nth|last|first)-child(?:\((even|odd|[\dn+\-]*)\))?/,POS:/:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^\-]|$)/,
+PSEUDO:/:((?:[\w\u00c0-\uFFFF\-]|\\.)+)(?:\((['"]?)((?:\([^\)]+\)|[^\(\)]*)+)\2\))?/},leftMatch:{},attrMap:{"class":"className","for":"htmlFor"},attrHandle:{href:function(a){return a.getAttribute("href")}},relative:{"+":function(a,b){var e=typeof b==="string",h=e&&!/\W/.test(b),e=e&&!h;h&&(b=b.toLowerCase());for(var h=0,f=a.length,c;h<f;h++)if(c=a[h]){for(;(c=c.previousSibling)&&c.nodeType!==1;);a[h]=e||c&&c.nodeName.toLowerCase()===b?c||!1:c===b}e&&d.filter(b,a,!0)},">":function(a,b){var e=typeof b===
+"string",h,f=0,c=a.length;if(e&&!/\W/.test(b))for(b=b.toLowerCase();f<c;f++){if(h=a[f])e=h.parentNode,a[f]=e.nodeName.toLowerCase()===b?e:!1}else{for(;f<c;f++)(h=a[f])&&(a[f]=e?h.parentNode:h.parentNode===b);e&&d.filter(b,a,!0)}},"":function(a,b,e){var d=g++,h=i,f;typeof b==="string"&&!/\W/.test(b)&&(f=b=b.toLowerCase(),h=c);h("parentNode",b,d,a,f,e)},"~":function(a,b,e){var d=g++,h=i,f;typeof b==="string"&&!/\W/.test(b)&&(f=b=b.toLowerCase(),h=c);h("previousSibling",b,d,a,f,e)}},find:{ID:function(a,
+b,e){if(typeof b.getElementById!=="undefined"&&!e)return(a=b.getElementById(a[1]))?[a]:[]},NAME:function(a,b){if(typeof b.getElementsByName!=="undefined"){for(var e=[],d=b.getElementsByName(a[1]),h=0,f=d.length;h<f;h++)d[h].getAttribute("name")===a[1]&&e.push(d[h]);return e.length===0?null:e}},TAG:function(a,b){return b.getElementsByTagName(a[1])}},preFilter:{CLASS:function(a,b,e,d,h,f){a=" "+a[1].replace(/\\/g,"")+" ";if(f)return a;for(var f=0,c;(c=b[f])!=null;f++)c&&(h^(c.className&&(" "+c.className+
+" ").replace(/[\t\n]/g," ").indexOf(a)>=0)?e||d.push(c):e&&(b[f]=!1));return!1},ID:function(a){return a[1].replace(/\\/g,"")},TAG:function(a){return a[1].toLowerCase()},CHILD:function(a){if(a[1]==="nth"){var b=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(a[2]==="even"&&"2n"||a[2]==="odd"&&"2n+1"||!/\D/.test(a[2])&&"0n+"+a[2]||a[2]);a[2]=b[1]+(b[2]||1)-0;a[3]=b[3]-0}a[0]=g++;return a},ATTR:function(a,b,e,d,h,f){b=a[1].replace(/\\/g,"");!f&&n.attrMap[b]&&(a[1]=n.attrMap[b]);a[2]==="~="&&(a[4]=" "+a[4]+" ");return a},
+PSEUDO:function(a,b,e,h,f){if(a[1]==="not")if((j.exec(a[3])||"").length>1||/^\w/.test(a[3]))a[3]=d(a[3],null,null,b);else return a=d.filter(a[3],b,e,1^f),e||h.push.apply(h,a),!1;else if(n.match.POS.test(a[0])||n.match.CHILD.test(a[0]))return!0;return a},POS:function(a){a.unshift(!0);return a}},filters:{enabled:function(a){return a.disabled===!1&&a.type!=="hidden"},disabled:function(a){return a.disabled===!0},checked:function(a){return a.checked===!0},selected:function(a){return a.selected===!0},parent:function(a){return!!a.firstChild},
+empty:function(a){return!a.firstChild},has:function(a,b,e){return!!d(e[3],a).length},header:function(a){return/h\d/i.test(a.nodeName)},text:function(a){return"text"===a.type},radio:function(a){return"radio"===a.type},checkbox:function(a){return"checkbox"===a.type},file:function(a){return"file"===a.type},password:function(a){return"password"===a.type},submit:function(a){return"submit"===a.type},image:function(a){return"image"===a.type},reset:function(a){return"reset"===a.type},button:function(a){return"button"===
+a.type||a.nodeName.toLowerCase()==="button"},input:function(a){return/input|select|textarea|button/i.test(a.nodeName)}},setFilters:{first:function(a,b){return b===0},last:function(a,b,e,d){return b===d.length-1},even:function(a,b){return b%2===0},odd:function(a,b){return b%2===1},lt:function(a,b,e){return b<e[3]-0},gt:function(a,b,e){return b>e[3]-0},nth:function(a,b,e){return e[3]-0===b},eq:function(a,b,e){return e[3]-0===b}},filter:{PSEUDO:function(a,b,e,h){var f=b[1],c=n.filters[f];if(c)return c(a,
+e,b,h);else if(f==="contains")return(a.textContent||a.innerText||d.getText([a])||"").indexOf(b[3])>=0;else if(f==="not"){b=b[3];e=0;for(h=b.length;e<h;e++)if(b[e]===a)return!1;return!0}else d.error("Syntax error, unrecognized expression: "+f)},CHILD:function(a,b){var e=b[1],d=a;switch(e){case "only":case "first":for(;d=d.previousSibling;)if(d.nodeType===1)return!1;if(e==="first")return!0;d=a;case "last":for(;d=d.nextSibling;)if(d.nodeType===1)return!1;return!0;case "nth":var e=b[2],h=b[3];if(e===
+1&&h===0)return!0;var f=b[0],c=a.parentNode;if(c&&(c.sizcache!==f||!a.nodeIndex)){for(var g=0,d=c.firstChild;d;d=d.nextSibling)if(d.nodeType===1)d.nodeIndex=++g;c.sizcache=f}d=a.nodeIndex-h;return e===0?d===0:d%e===0&&d/e>=0}},ID:function(a,b){return a.nodeType===1&&a.getAttribute("id")===b},TAG:function(a,b){return b==="*"&&a.nodeType===1||a.nodeName.toLowerCase()===b},CLASS:function(a,b){return(" "+(a.className||a.getAttribute("class"))+" ").indexOf(b)>-1},ATTR:function(a,b){var e=b[1],e=n.attrHandle[e]?
+n.attrHandle[e](a):a[e]!=null?a[e]:a.getAttribute(e),d=e+"",h=b[2],f=b[4];return e==null?h==="!=":h==="="?d===f:h==="*="?d.indexOf(f)>=0:h==="~="?(" "+d+" ").indexOf(f)>=0:!f?d&&e!==!1:h==="!="?d!==f:h==="^="?d.indexOf(f)===0:h==="$="?d.substr(d.length-f.length)===f:h==="|="?d===f||d.substr(0,f.length+1)===f+"-":!1},POS:function(a,b,e,d){var h=n.setFilters[b[2]];if(h)return h(a,e,b,d)}}},k=n.match.POS,m=function(a,b){return"\\"+(b-0+1)},o;for(o in n.match)n.match[o]=RegExp(n.match[o].source+/(?![^\[]*\])(?![^\(]*\))/.source),
+n.leftMatch[o]=RegExp(/(^(?:.|\r|\n)*?)/.source+n.match[o].source.replace(/\\(\d+)/g,m));var e=function(a,b){a=Array.prototype.slice.call(a,0);if(b)return b.push.apply(b,a),b;return a};try{Array.prototype.slice.call(document.documentElement.childNodes,0)}catch(h){e=function(a,e){var d=e||[],h=0;if(b.call(a)==="[object Array]")Array.prototype.push.apply(d,a);else if(typeof a.length==="number")for(var f=a.length;h<f;h++)d.push(a[h]);else for(;a[h];h++)d.push(a[h]);return d}}var p;document.documentElement.compareDocumentPosition?
+p=function(b,e){if(!b.compareDocumentPosition||!e.compareDocumentPosition)return b==e&&(a=!0),b.compareDocumentPosition?-1:1;var d=b.compareDocumentPosition(e)&4?-1:b===e?0:1;d===0&&(a=!0);return d}:"sourceIndex"in document.documentElement?p=function(b,e){if(!b.sourceIndex||!e.sourceIndex)return b==e&&(a=!0),b.sourceIndex?-1:1;var d=b.sourceIndex-e.sourceIndex;d===0&&(a=!0);return d}:document.createRange&&(p=function(b,e){if(!b.ownerDocument||!e.ownerDocument)return b==e&&(a=!0),b.ownerDocument?-1:
+1;var d=b.ownerDocument.createRange(),h=e.ownerDocument.createRange();d.setStart(b,0);d.setEnd(b,0);h.setStart(e,0);h.setEnd(e,0);d=d.compareBoundaryPoints(Range.START_TO_END,h);d===0&&(a=!0);return d});d.getText=function(a){for(var b="",e,h=0;a[h];h++)e=a[h],e.nodeType===3||e.nodeType===4?b+=e.nodeValue:e.nodeType!==8&&(b+=d.getText(e.childNodes));return b};(function(){var a=document.createElement("div"),b="script"+(new Date).getTime();a.innerHTML="<a name='"+b+"'/>";var e=document.documentElement;
+e.insertBefore(a,e.firstChild);if(document.getElementById(b))n.find.ID=function(a,b,e){if(typeof b.getElementById!=="undefined"&&!e)return(b=b.getElementById(a[1]))?b.id===a[1]||typeof b.getAttributeNode!=="undefined"&&b.getAttributeNode("id").nodeValue===a[1]?[b]:void 0:[]},n.filter.ID=function(a,b){var e=typeof a.getAttributeNode!=="undefined"&&a.getAttributeNode("id");return a.nodeType===1&&e&&e.nodeValue===b};e.removeChild(a);e=a=null})();(function(){var a=document.createElement("div");a.appendChild(document.createComment(""));
+if(a.getElementsByTagName("*").length>0)n.find.TAG=function(a,b){var e=b.getElementsByTagName(a[1]);if(a[1]==="*"){for(var d=[],h=0;e[h];h++)e[h].nodeType===1&&d.push(e[h]);e=d}return e};a.innerHTML="<a href='#'></a>";if(a.firstChild&&typeof a.firstChild.getAttribute!=="undefined"&&a.firstChild.getAttribute("href")!=="#")n.attrHandle.href=function(a){return a.getAttribute("href",2)};a=null})();document.querySelectorAll&&function(){var a=d,b=document.createElement("div");b.innerHTML="<p class='TEST'></p>";
+if(!(b.querySelectorAll&&b.querySelectorAll(".TEST").length===0)){d=function(b,h,f,c){h=h||document;if(!c&&h.nodeType===9&&!d.isXML(h))try{return e(h.querySelectorAll(b),f)}catch(g){}return a(b,h,f,c)};for(var h in a)d[h]=a[h];b=null}}();(function(){var a=document.createElement("div");a.innerHTML="<div class='test e'></div><div class='test'></div>";if(a.getElementsByClassName&&a.getElementsByClassName("e").length!==0&&(a.lastChild.className="e",a.getElementsByClassName("e").length!==1))n.order.splice(1,
+0,"CLASS"),n.find.CLASS=function(a,b,e){if(typeof b.getElementsByClassName!=="undefined"&&!e)return b.getElementsByClassName(a[1])},a=null})();d.contains=document.compareDocumentPosition?function(a,b){return!!(a.compareDocumentPosition(b)&16)}:function(a,b){return a!==b&&(a.contains?a.contains(b):!0)};d.isXML=function(a){return(a=(a?a.ownerDocument||a:0).documentElement)?a.nodeName!=="HTML":!1};var u=function(a,b){for(var e=[],h="",f,c=b.nodeType?[b]:b;f=n.match.PSEUDO.exec(a);)h+=f[0],a=a.replace(n.match.PSEUDO,
+"");a=n.relative[a]?a+"*":a;f=0;for(var g=c.length;f<g;f++)d(a,c[f],e);return d.filter(h,e)};window.tinymce.dom.Sizzle=d})();
+(function(c){var i=c.each,j=c.DOM,g=c.isIE,b;c.create("tinymce.dom.EventUtils",{EventUtils:function(){this.inits=[];this.events=[]},add:function(a,b,d,n){var k,m=this,o=m.events,e;if(b instanceof Array)return e=[],i(b,function(b){e.push(m.add(a,b,d,n))}),e;if(a&&a.hasOwnProperty&&a instanceof Array)return e=[],i(a,function(a){a=j.get(a);e.push(m.add(a,b,d,n))}),e;if(a=j.get(a)){k=function(a){if(!m.disabled){if((a=a||window.event)&&g){if(!a.target)a.target=a.srcElement;c.extend(a,m._stoppers)}if(!n)return d(a);
+return d.call(n,a)}};if(b=="unload")return c.unloads.unshift({func:k}),k;if(b=="init")return m.domLoaded?k():m.inits.push(k),k;o.push({obj:a,name:b,func:d,cfunc:k,scope:n});m._add(a,b,k);return d}},remove:function(a,b,d){var c=this,g=c.events,m=!1,o;if(a&&a.hasOwnProperty&&a instanceof Array)return o=[],i(a,function(a){a=j.get(a);o.push(c.remove(a,b,d))}),o;a=j.get(a);i(g,function(e,h){if(e.obj==a&&e.name==b&&(!d||e.func==d||e.cfunc==d))return g.splice(h,1),c._remove(a,b,e.cfunc),m=!0,!1});return m},
+clear:function(a){var b=this.events,d,c;if(a){a=j.get(a);for(d=b.length-1;d>=0;d--)if(c=b[d],c.obj===a)this._remove(c.obj,c.name,c.cfunc),c.obj=c.cfunc=null,b.splice(d,1)}},cancel:function(a){if(!a)return!1;this.stop(a);return this.prevent(a)},stop:function(a){a.stopPropagation?a.stopPropagation():a.cancelBubble=!0;return!1},prevent:function(a){a.preventDefault?a.preventDefault():a.returnValue=!1;return!1},destroy:function(){var a=this;i(a.events,function(b){a._remove(b.obj,b.name,b.cfunc);b.obj=
+b.cfunc=null});a.events=[];a=null},_add:function(a,b,d){a.attachEvent?a.attachEvent("on"+b,d):a.addEventListener?a.addEventListener(b,d,!1):a["on"+b]=d},_remove:function(a,b,d){if(a)try{a.detachEvent?a.detachEvent("on"+b,d):a.removeEventListener?a.removeEventListener(b,d,!1):a["on"+b]=null}catch(c){}},_pageInit:function(){if(!this.domLoaded)this.domLoaded=!0,i(this.inits,function(a){a()}),this.inits=[]},_wait:function(a){var b=this,d=a.document;a.tinyMCE_GZ&&tinyMCE_GZ.loaded?b.domLoaded=1:(d.attachEvent?
+(d.attachEvent("onreadystatechange",function(){d.readyState==="complete"&&(d.detachEvent("onreadystatechange",arguments.callee),b._pageInit(a))}),d.documentElement.doScroll&&a==a.top&&function(){if(!b.domLoaded){try{d.documentElement.doScroll("left")}catch(c){setTimeout(arguments.callee,0);return}b._pageInit(a)}}()):d.addEventListener&&b._add(a,"DOMContentLoaded",function(){b._pageInit(a)}),b._add(a,"load",function(){b._pageInit(a)}))},_stoppers:{preventDefault:function(){this.returnValue=!1},stopPropagation:function(){this.cancelBubble=
+!0}}});b=c.dom.Event=new c.dom.EventUtils;b._wait(window);c.addUnload(function(){b.destroy()})})(tinymce);
+(function(c){c.dom.Element=function(i,j){var g=this,b;g.settings=j=j||{};g.id=i;g.dom=b=j.dom||c.DOM;c.isIE||b.get(g.id);c.each("getPos,getRect,getParent,add,setStyle,getStyle,setStyles,setAttrib,setAttribs,getAttrib,addClass,removeClass,hasClass,getOuterHTML,setOuterHTML,remove,show,hide,isHidden,setHTML,get".split(/,/),function(a){g[a]=function(){var c=[i],d;for(d=0;d<arguments.length;d++)c.push(arguments[d]);c=b[a].apply(b,c);g.update(a);return c}});c.extend(g,{on:function(a,b,d){return c.dom.Event.add(g.id,
+a,b,d)},getXY:function(){return{x:parseInt(g.getStyle("left")),y:parseInt(g.getStyle("top"))}},getSize:function(){var a=b.get(g.id);return{w:parseInt(g.getStyle("width")||a.clientWidth),h:parseInt(g.getStyle("height")||a.clientHeight)}},moveTo:function(a,b){g.setStyles({left:a,top:b})},moveBy:function(a,b){var d=g.getXY();g.moveTo(d.x+a,d.y+b)},resizeTo:function(a,b){g.setStyles({width:a,height:b})},resizeBy:function(a,b){var d=g.getSize();g.resizeTo(d.w+a,d.h+b)},update:function(a){if(c.isIE6&&j.blocker&&
+(a=a||"",!(a.indexOf("get")===0||a.indexOf("has")===0||a.indexOf("is")===0)))a=="remove"?b.remove(g.blocker):(g.blocker?a=b.get(g.blocker):(g.blocker=b.uniqueId(),a=b.add(j.container||b.getRoot(),"iframe",{id:g.blocker,style:"position:absolute;",frameBorder:0,src:'javascript:""'}),b.setStyle(a,"opacity",0)),b.setStyles(a,{left:g.getStyle("left",1),top:g.getStyle("top",1),width:g.getStyle("width",1),height:g.getStyle("height",1),display:g.getStyle("display",1),zIndex:parseInt(g.getStyle("zIndex",1)||
+0)-1}))}})}})(tinymce);
+(function(c){var i=c.is,j=c.isIE,g=c.each;c.create("tinymce.dom.Selection",{Selection:function(b,a,f){var d=this;d.dom=b;d.win=a;d.serializer=f;g(["onBeforeSetContent","onBeforeGetContent","onSetContent","onGetContent"],function(a){d[a]=new c.util.Dispatcher(d)});if(!d.win.getSelection)d.tridentSel=new c.dom.TridentSelection(d);c.isIE&&b.boxModel&&this._fixIESelection();c.addUnload(d.destroy,d)},getContent:function(b){var a=this.getRng(),c=this.dom.create("body"),d=this.getSel(),g,k,b=b||{};g=k="";
+b.get=!0;b.format=b.format||"html";this.onBeforeGetContent.dispatch(this,b);if(b.format=="text")return this.isCollapsed()?"":a.text||(d.toString?d.toString():"");a.cloneContents?(a=a.cloneContents())&&c.appendChild(a):c.innerHTML=i(a.item)||i(a.htmlText)?a.item?a.item(0).outerHTML:a.htmlText:a.toString();/^\s/.test(c.innerHTML)&&(g=" ");/\s+$/.test(c.innerHTML)&&(k=" ");b.getInner=!0;b.content=this.isCollapsed()?"":g+this.serializer.serialize(c,b)+k;this.onGetContent.dispatch(this,b);return b.content},
+setContent:function(b,a){var c=this.getRng(),d,g=this.win.document,k,a=a||{format:"html"};a.set=!0;a.content=b;a.no_events||this.onBeforeSetContent.dispatch(this,a);b=a.content;c.insertNode?(b+='<span id="__caret">_</span>',c.startContainer==g&&c.endContainer==g?g.body.innerHTML=b:(c.deleteContents(),g.body.childNodes.length==0?g.body.innerHTML=b:c.createContextualFragment?c.insertNode(c.createContextualFragment(b)):(d=g.createDocumentFragment(),k=g.createElement("div"),d.appendChild(k),k.outerHTML=
+b,c.insertNode(d))),d=this.dom.get("__caret"),c=g.createRange(),c.setStartBefore(d),c.setEndBefore(d),this.setRng(c),this.dom.remove("__caret"),this.setRng(c)):(c.item&&(g.execCommand("Delete",!1,null),c=this.getRng()),c.pasteHTML(b));a.no_events||this.onSetContent.dispatch(this,a)},getStart:function(){var d;var b=this.getRng(),a,c;if(b.duplicate||b.item){if(b.item)return b.item(0);a=b.duplicate();a.collapse(1);a=a.parentElement();for(d=c=b.parentElement(),b=d;c=c.parentNode;)if(c==a){a=b;break}}else if(a=
+b.startContainer,a.nodeType==1&&a.hasChildNodes()&&(a=a.childNodes[Math.min(a.childNodes.length-1,b.startOffset)]),a&&a.nodeType==3)return a.parentNode;return a},getEnd:function(){var b=this.getRng(),a;if(b.duplicate||b.item){if(b.item)return b.item(0);b=b.duplicate();b.collapse(0);if((a=b.parentElement())&&a.nodeName=="BODY")return a.lastChild||a}else if(a=b.endContainer,b=b.endOffset,a.nodeType==1&&a.hasChildNodes()&&(a=a.childNodes[b>0?b-1:b]),a&&a.nodeType==3)return a.parentNode;return a},getBookmark:function(b,
+a){function c(a,b){var e=0;g(i.select(a),function(a,d){a==b&&(e=d)});return e}var d=this,i=d.dom,k,j,o,e,h;if(b==2)return function(){function b(e,c){var f=e[c?"startContainer":"endContainer"],g=e[c?"startOffset":"endOffset"],l=[],k,i=0;if(f.nodeType==3){if(a)for(k=f.previousSibling;k&&k.nodeType==3;k=k.previousSibling)g+=k.nodeValue.length;l.push(g)}else k=f.childNodes,g>=k.length&&k.length&&(i=1,g=Math.max(0,k.length-1)),l.push(d.dom.nodeIndex(k[g],a)+i);for(;f&&f!=h;f=f.parentNode)l.push(d.dom.nodeIndex(f,
+a));return l}var e=d.getRng(!0),h=i.getRoot(),c={};c.start=b(e,!0);if(!d.isCollapsed())c.end=b(e);return c}();if(b)return{rng:d.getRng()};k=d.getRng();o=i.uniqueId();e=tinyMCE.activeEditor.selection.isCollapsed();if(k.duplicate||k.item)if(k.item)return h=k.item(0),j=h.nodeName,{name:j,index:c(j,h)};else{j=k.duplicate();try{k.collapse(),k.pasteHTML('<span data-mce-type="bookmark" id="'+o+'_start" style="overflow:hidden;line-height:0px">\ufeff</span>'),e||(j.collapse(!1),k.moveToElementText(j.parentElement()),
+k.compareEndPoints("StartToEnd",j)==0&&j.move("character",-1),j.pasteHTML('<span data-mce-type="bookmark" id="'+o+'_end" style="overflow:hidden;line-height:0px">\ufeff</span>'))}catch(p){return null}}else{h=d.getNode();j=h.nodeName;if(j=="IMG")return{name:j,index:c(j,h)};j=k.cloneRange();e||(j.collapse(!1),j.insertNode(i.create("span",{"data-mce-type":"bookmark",id:o+"_end",style:"overflow:hidden;line-height:0px"},"\ufeff")));k.collapse(!0);k.insertNode(i.create("span",{"data-mce-type":"bookmark",
+id:o+"_start",style:"overflow:hidden;line-height:0px"},"\ufeff"))}d.moveToBookmark({id:o,keep:1});return{id:o}},moveToBookmark:function(b){var a=this.dom,f,d,i,k,m,o;this.tridentSel&&this.tridentSel.destroy();if(b)if(b.start){f=a.createRng();d=a.getRoot();var e=function(a){var e=b[a?"start":"end"],h,c,g;if(e){g=e[0];c=d;for(h=e.length-1;h>=1;h--){c=c.childNodes;if(e[h]>c.length-1)return;c=c[e[h]]}c.nodeType===3&&(g=Math.min(e[0],c.nodeValue.length));c.nodeType===1&&(g=Math.min(e[0],c.childNodes.length));
+a?f.setStart(c,g):f.setEnd(c,g)}return!0};e(!0)&&e()&&this.setRng(f)}else if(b.id){var e=function(e){var d=a.get(b.id+"_"+e),h,f,j;j=b.keep;if(d&&(h=d.parentNode,e=="start"?(j?(h=d.firstChild,f=1):f=a.nodeIndex(d),i=k=h,m=o=f):(j?(h=d.firstChild,f=1):f=a.nodeIndex(d),k=h,o=f),!j)){j=d.previousSibling;h=d.nextSibling;for(g(c.grep(d.childNodes),function(a){if(a.nodeType==3)a.nodeValue=a.nodeValue.replace(/\uFEFF/g,"")});d=a.get(b.id+"_"+e);)a.remove(d,1);if(j&&h&&j.nodeType==h.nodeType&&j.nodeType==
+3&&!c.isOpera)f=j.nodeValue.length,j.appendData(h.nodeValue),a.remove(h),e=="start"?(i=k=j,m=o=f):(k=j,o=f)}},h=function(b){if(a.isBlock(b)&&!b.innerHTML)b.innerHTML=!j?'<br data-mce-bogus="1" />':" ";return b};e("start");e("end");i&&(f=a.createRng(),f.setStart(h(i),m),f.setEnd(h(k),o),this.setRng(f))}else b.name?this.select(a.select(b.name)[b.index]):b.rng&&this.setRng(b.rng)},select:function(b,a){var f=this.dom,d=f.createRng();b&&(f=f.nodeIndex(b),d.setStart(b.parentNode,f),d.setEnd(b.parentNode,
+f+1),a&&(f=function(a,b){var f=new c.dom.TreeWalker(a,a);do{if(a.nodeType==3&&c.trim(a.nodeValue).length!=0){b?d.setStart(a,0):d.setEnd(a,a.nodeValue.length);break}if(a.nodeName=="BR"){b?d.setStartBefore(a):d.setEndBefore(a);break}}while(a=b?f.next():f.prev())},f(b,1),f(b)),this.setRng(d));return b},isCollapsed:function(){var b=this.getRng(),a=this.getSel();if(!b||b.item)return!1;if(b.compareEndPoints)return b.compareEndPoints("StartToEnd",b)===0;return!a||b.collapsed},collapse:function(b){var a=
+this.getRng(),c;a.item&&(c=a.item(0),a=this.win.document.body.createTextRange(),a.moveToElementText(c));a.collapse(!!b);this.setRng(a)},getSel:function(){var b=this.win;return b.getSelection?b.getSelection():b.document.selection},getRng:function(b){var a,f,d=this.win.document;if(b&&this.tridentSel)return this.tridentSel.getRangeAt(0);try{if(a=this.getSel())f=a.rangeCount>0?a.getRangeAt(0):a.createRange?a.createRange():d.createRange()}catch(g){}c.isIE&&f&&f.setStart&&d.selection.createRange().item&&
+(b=d.selection.createRange().item(0),f=d.createRange(),f.setStartBefore(b),f.setEndAfter(b));f||(f=d.createRange?d.createRange():d.body.createTextRange());if(this.selectedRange&&this.explicitRange)f.compareBoundaryPoints(f.START_TO_START,this.selectedRange)===0&&f.compareBoundaryPoints(f.END_TO_END,this.selectedRange)===0?f=this.explicitRange:this.explicitRange=this.selectedRange=null;return f},setRng:function(b){var a;if(this.tridentSel)if(b.cloneRange)this.tridentSel.addRange(b);else try{b.select()}catch(c){}else if(a=
+this.getSel()){this.explicitRange=b;try{a.removeAllRanges()}catch(d){}a.addRange(b);this.selectedRange=a.getRangeAt(0)}},setNode:function(b){this.setContent(this.dom.getOuterHTML(b));return b},getNode:function(){var b=this.getRng();this.getSel();var a,c=b.startContainer,d=b.endContainer;if(!b)return this.dom.getRoot();if(b.setStart){a=b.commonAncestorContainer;if(!b.collapsed&&(b.startContainer==b.endContainer&&b.endOffset-b.startOffset<2&&b.startContainer.hasChildNodes()&&(a=b.startContainer.childNodes[b.startOffset]),
+c.nodeType===3&&d.nodeType===3)){var g=function(a,b){for(var d=a;a&&a.nodeType===3&&a.length===0;)a=b?a.nextSibling:a.previousSibling;return a||d},c=c.length===b.startOffset?g(c.nextSibling,!0):c.parentNode,d=b.endOffset===0?g(d.previousSibling,!1):d.parentNode;if(c&&c===d)return c}if(a&&a.nodeType==3)return a.parentNode;return a}return b.item?b.item(0):b.parentElement()},getSelectedBlocks:function(b,a){var c=this.dom,d,g,k,j=[];d=c.getParent(b||this.getStart(),c.isBlock);g=c.getParent(a||this.getEnd(),
+c.isBlock);d&&j.push(d);if(d&&g&&d!=g)for(k=d;(k=k.nextSibling)&&k!=g;)c.isBlock(k)&&j.push(k);g&&d!=g&&j.push(g);return j},destroy:function(b){this.win=null;this.tridentSel&&this.tridentSel.destroy();b||c.removeUnload(this.destroy)},_fixIESelection:function(){function b(a,b){var e=k.createTextRange();try{e.moveToPoint(a,b)}catch(d){e=null}return e}function a(a){if(a.button){if(a=b(a.x,a.y))a.compareEndPoints("StartToStart",i)>0?a.setEndPoint("StartToStart",i):a.setEndPoint("EndToEnd",i),a.select()}else c()}
+function c(){var b=g.selection.createRange();i&&!b.item&&b.compareEndPoints("StartToEnd",b)===0&&i.select();d.unbind(g,"mouseup",c);d.unbind(g,"mousemove",a);i=j=0}var d=this.dom,g=d.doc,k=g.body,j,i,e;g.documentElement.unselectable=!0;d.bind(g,["mousedown","contextmenu"],function(h){if(h.target.nodeName==="HTML"&&(j&&c(),e=g.documentElement,!(e.scrollHeight>e.clientHeight)&&(j=1,i=b(h.x,h.y))))d.bind(g,"mouseup",c),d.bind(g,"mousemove",a),d.win.focus(),i.select()})}})})(tinymce);
+(function(c){c.dom.Serializer=function(i,j,g){var b,a,f=c.isIE,d=c.each,n;if(!i.apply_source_formatting)i.indent=!1;i.remove_trailing_brs=!0;j=j||c.DOM;g=g||new c.html.Schema(i);i.entity_encoding=i.entity_encoding||"named";b=new c.util.Dispatcher(self);a=new c.util.Dispatcher(self);n=new c.html.DomParser(i,g);n.addAttributeFilter("src,href,style",function(a,b){for(var d=a.length,e,c,f="data-mce-"+b,g=i.url_converter,l=i.url_converter_scope;d--;)e=a[d],c=e.attributes.map[f],c!==void 0?(e.attr(b,c.length>
+0?c:null),e.attr(f,null)):(c=e.attributes.map[b],b==="style"?c=j.serializeStyle(j.parseStyle(c),e.name):g&&(c=g.call(l,c,b,e.name)),e.attr(b,c.length>0?c:null))});n.addAttributeFilter("class",function(a){for(var b=a.length,d,e;b--;)d=a[b],e=d.attr("class").replace(/\s*mce(Item\w+|Selected)\s*/g,""),d.attr("class",e.length>0?e:null)});n.addAttributeFilter("data-mce-type",function(a,b,d){for(var b=a.length,e;b--;)e=a[b],e.attributes.map["data-mce-type"]==="bookmark"&&!d.cleanup&&e.remove()});n.addNodeFilter("script,style",
+function(a,b){function d(a){return a.replace(/(<\!--\[CDATA\[|\]\]--\>)/g,"\n").replace(/^[\r\n]*|[\r\n]*$/g,"").replace(/^\s*(\/\/\s*<\!--|\/\/\s*<!\[CDATA\[|<\!--|<!\[CDATA\[)[\r\n]*/g,"").replace(/\s*(\/\/\s*\]\]>|\/\/\s*--\>|\]\]>|--\>|\]\]--\>)\s*$/g,"")}for(var e=a.length,c,f;e--;)if(c=a[e],f=c.firstChild?c.firstChild.value:"",b==="script"){if(c.attr("type",(c.attr("type")||"text/javascript").replace(/^mce\-/,"")),f.length>0)c.firstChild.value="// <![CDATA[\n"+d(f)+"\n// ]]\>"}else if(f.length>
+0)c.firstChild.value="<\!--\n"+d(f)+"\n--\>"});n.addNodeFilter("#comment",function(a){for(var b=a.length,d;b--;)if(d=a[b],d.value.indexOf("[CDATA[")===0)d.name="#cdata",d.type=4,d.value=d.value.replace(/^\[CDATA\[|\]\]$/g,"");else if(d.value.indexOf("mce:protected ")===0)d.name="#text",d.type=3,d.raw=!0,d.value=unescape(d.value).substr(14)});n.addNodeFilter("xml:namespace,input",function(a,b){for(var d=a.length,e;d--;)e=a[d],e.type===7?e.remove():e.type===1&&b==="input"&&!("type"in e.attributes.map)&&
+e.attr("type","text")});i.fix_list_elements&&n.addNodeFilter("ul,ol",function(a){for(var b=a.length,d,e;b--;)d=a[b],e=d.parent,(e.name==="ul"||e.name==="ol")&&d.prev&&d.prev.name==="li"&&d.prev.append(d)});n.addAttributeFilter("data-mce-src,data-mce-href,data-mce-style",function(a,b){for(var d=a.length;d--;)a[d].attr(b,null)});return{schema:g,addNodeFilter:n.addNodeFilter,addAttributeFilter:n.addAttributeFilter,onPreProcess:b,onPostProcess:a,serialize:function(k,m){var o,e,h;f&&j.select("script,style,select").length>
+0?(o=k.innerHTML,k=k.cloneNode(!1),j.setHTML(k,o)):k=k.cloneNode(!0);o=k.ownerDocument.implementation;if(o.createHTMLDocument)e=o.createHTMLDocument(""),d(k.nodeName=="BODY"?k.childNodes:[k],function(a){e.body.appendChild(e.importNode(a,!0))}),k=k.nodeName!="BODY"?e.body.firstChild:e.body,h=j.doc,j.doc=e;m=m||{};m.format=m.format||"html";if(!m.no_events)m.node=k,b.dispatch(self,m);o=new c.html.Serializer(i,g);m.content=o.serialize(n.parse(m.getInner?k.innerHTML:c.trim(j.getOuterHTML(k),m),m));if(!m.cleanup)m.content=
+m.content.replace(/\uFEFF/g,"");m.no_events||a.dispatch(self,m);if(h)j.doc=h;m.node=null;return m.content},addRules:function(a){g.addValidElements(a)},setRules:function(a){g.setValidElements(a)}}}})(tinymce);
+(function(c){c.dom.ScriptLoader=function(){function i(a,b){function f(){j.remove(u);if(e)e.onreadystatechange=e.onload=e=null;b()}function g(){typeof console!=="undefined"&&console.log&&console.log("Failed to load: "+a)}var j=c.DOM,e,h,i,u;u=j.uniqueId();if(c.isIE6&&(h=new c.util.URI(a),i=location,h.host==i.hostname&&h.port==i.port&&h.protocol+":"==i.protocol&&h.protocol.toLowerCase()!="file")){c.util.XHR.send({url:c._addVer(h.getURI()),success:function(a){var b=j.create("script",{type:"text/javascript"});
+b.text=a;document.getElementsByTagName("head")[0].appendChild(b);j.remove(b);f()},error:g});return}e=j.create("script",{id:u,type:"text/javascript",src:c._addVer(a)});if(!c.isIE)e.onload=f;e.onerror=g;if(!c.isOpera)e.onreadystatechange=function(){var a=e.readyState;(a=="complete"||a=="loaded")&&f()};(document.getElementsByTagName("head")[0]||document.body).appendChild(e)}var j={},g=[],b={},a=[],f=0;this.isDone=function(a){return j[a]==2};this.markDone=function(a){j[a]=2};this.add=this.load=function(a,
+c,f){j[a]==void 0&&(g.push(a),j[a]=0);c&&(b[a]||(b[a]=[]),b[a].push({func:c,scope:f||this}))};this.loadQueue=function(a,b){this.loadScripts(g,a,b)};this.loadScripts=function(d,g,k){function m(a){c.each(b[a],function(a){a.func.call(a.scope)});b[a]=void 0}var o;a.push({func:g,scope:k||this});o=function(){var b=c.grep(d);d.length=0;c.each(b,function(a){j[a]==2?m(a):j[a]!=1&&(j[a]=1,f++,i(a,function(){j[a]=2;f--;m(a);o()}))});if(!f)c.each(a,function(a){a.func.call(a.scope)}),a.length=0};o()}};c.ScriptLoader=
+new c.dom.ScriptLoader})(tinymce);tinymce.dom.TreeWalker=function(c,i){function j(b,a,c,d){if(b){if(!d&&b[a])return b[a];if(b!=i){if(a=b[c])return a;for(b=b.parentNode;b&&b!=i;b=b.parentNode)if(a=b[c])return a}}}var g=c;this.current=function(){return g};this.next=function(b){return g=j(g,"firstChild","nextSibling",b)};this.prev=function(b){return g=j(g,"lastChild","previousSibling",b)}};
+(function(c){c.dom.RangeUtils=function(i){this.walk=function(j,g){function b(a,b,e){for(var d=[];a&&a!=e;a=a[b])d.push(a);return d}function a(a,b){do{if(a.parentNode==b)return a;a=a.parentNode}while(a)}function f(a,d,c){var f=c?"nextSibling":"previousSibling";o=a;for(e=o.parentNode;o&&o!=d;o=e)e=o.parentNode,h=b(o==a?o:o[f],f),h.length&&(c||h.reverse(),g(h))}var d=j.startContainer,n=j.startOffset,k=j.endContainer,m=j.endOffset,o,e,h,p;p=i.select("td.mceSelected,th.mceSelected");if(p.length>0)c.each(p,
+function(a){g([a])});else{d.nodeType==1&&d.hasChildNodes()&&(d=d.childNodes[n]);k.nodeType==1&&k.hasChildNodes()&&(k=k.childNodes[Math.min(m-1,k.childNodes.length-1)]);m=i.findCommonAncestor(d,k);if(d==k)return g([d]);for(o=d;o;o=o.parentNode){if(o==k)return f(d,m,!0);if(o==m)break}for(o=k;o;o=o.parentNode){if(o==d)return f(k,m);if(o==m)break}n=a(d,m)||d;m=a(k,m)||k;f(d,n,!0);h=b(n==d?n:n.nextSibling,"nextSibling",m==k?m.nextSibling:m);h.length&&g(h);f(k,m)}}};c.dom.RangeUtils.compareRanges=function(c,
+j){if(c&&j)if(c.item||c.duplicate){if(c.item&&j.item&&c.item(0)===j.item(0))return!0;if(c.isEqual&&j.isEqual&&j.isEqual(c))return!0}else return c.startContainer==j.startContainer&&c.startOffset==j.startOffset;return!1}})(tinymce);
+(function(c){var i=c.dom.Event,j=c.each;c.create("tinymce.ui.KeyboardNavigation",{KeyboardNavigation:function(g,b){var a=this,f=g.root,d=g.items,n=g.enableUpDown,k=g.enableLeftRight||!g.enableUpDown,m=g.excludeFromTabOrder,o,e,h,p,u,b=b||c.DOM;o=function(a){u=a.target.id};e=function(a){b.setAttrib(a.target.id,"tabindex","-1")};p=function(){var a=b.get(u);b.setAttrib(a,"tabindex","0");a.focus()};a.focus=function(){b.get(u).focus()};a.destroy=function(){j(d,function(a){b.unbind(b.get(a.id),"focus",
+o);b.unbind(b.get(a.id),"blur",e)});b.unbind(b.get(f),"focus",p);b.unbind(b.get(f),"keydown",h);d=b=f=a.focus=o=e=h=p=null;a.destroy=function(){}};a.moveFocus=function(a,e){var c=-1,h;if(u){j(d,function(a,b){if(a.id===u)return c=b,!1});c+=a;c<0?c=d.length-1:c>=d.length&&(c=0);h=d[c];b.setAttrib(u,"tabindex","-1");b.setAttrib(h.id,"tabindex","0");b.get(h.id).focus();if(g.actOnFocus)g.onAction(h.id);e&&i.cancel(e)}};h=function(b){switch(b.keyCode){case 37:k&&a.moveFocus(-1);break;case 39:k&&a.moveFocus(1);
+break;case 38:n&&a.moveFocus(-1);break;case 40:n&&a.moveFocus(1);break;case 27:g.onCancel&&(g.onCancel(),i.cancel(b));break;case 14:case 13:case 32:g.onAction&&(g.onAction(u),i.cancel(b))}};j(d,function(a,d){var c;if(!a.id)a.id=b.uniqueId("_mce_item_");m?(b.bind(a.id,"blur",e),c="-1"):c=d===0?"0":"-1";b.setAttrib(a.id,"tabindex",c);b.bind(b.get(a.id),"focus",o)});if(d[0])u=d[0].id;b.setAttrib(f,"tabindex","-1");b.bind(b.get(f),"focus",p);b.bind(b.get(f),"keydown",h)}})})(tinymce);
+(function(c){var i=c.DOM,j=c.is;c.create("tinymce.ui.Control",{Control:function(g,b,a){this.id=g;this.settings=b=b||{};this.rendered=!1;this.onRender=new c.util.Dispatcher(this);this.classPrefix="";this.scope=b.scope||this;this.active=this.disabled=0;this.editor=a},setAriaProperty:function(c,b){var a=i.get(this.id+"_aria")||i.get(this.id);a&&i.setAttrib(a,"aria-"+c,!!b)},focus:function(){i.get(this.id).focus()},setDisabled:function(c){if(c!=this.disabled)this.setAriaProperty("disabled",c),this.setState("Disabled",
+c),this.setState("Enabled",!c),this.disabled=c},isDisabled:function(){return this.disabled},setActive:function(c){if(c!=this.active)this.setState("Active",c),this.active=c,this.setAriaProperty("pressed",c)},isActive:function(){return this.active},setState:function(c,b){var a=i.get(this.id),c=this.classPrefix+c;b?i.addClass(a,c):i.removeClass(a,c)},isRendered:function(){return this.rendered},renderHTML:function(){},renderTo:function(c){i.setHTML(c,this.renderHTML())},postRender:function(){var c;if(j(this.disabled))c=
+this.disabled,this.disabled=-1,this.setDisabled(c);if(j(this.active))c=this.active,this.active=-1,this.setActive(c)},remove:function(){i.remove(this.id);this.destroy()},destroy:function(){c.dom.Event.clear(this.id)}})})(tinymce);tinymce.create("tinymce.ui.Container:tinymce.ui.Control",{Container:function(c,i,j){this.parent(c,i,j);this.controls=[];this.lookup={}},add:function(c){this.lookup[c.id]=c;this.controls.push(c);return c},get:function(c){return this.lookup[c]}});
+tinymce.create("tinymce.ui.Separator:tinymce.ui.Control",{Separator:function(c,i){this.parent(c,i);this.classPrefix="mceSeparator";this.setDisabled(!0)},renderHTML:function(){return tinymce.DOM.createHTML("span",{"class":this.classPrefix,role:"separator","aria-orientation":"vertical",tabindex:"-1"})}});
+(function(c){var i=c.is;c.create("tinymce.ui.MenuItem:tinymce.ui.Control",{MenuItem:function(c,g){this.parent(c,g);this.classPrefix="mceMenuItem"},setSelected:function(c){this.setState("Selected",c);this.setAriaProperty("checked",!!c);this.selected=c},isSelected:function(){return this.selected},postRender:function(){this.parent();i(this.selected)&&this.setSelected(this.selected)}})})(tinymce);
+(function(c){var i=c.DOM,j=c.walk;c.create("tinymce.ui.Menu:tinymce.ui.MenuItem",{Menu:function(g,b){this.parent(g,b);this.items={};this.collapsed=!1;this.menuCount=0;this.onAddItem=new c.util.Dispatcher(this)},expand:function(c){c&&j(this,function(b){b.expand&&b.expand()},"items",this);this.collapsed=!1},collapse:function(c){c&&j(this,function(b){b.collapse&&b.collapse()},"items",this);this.collapsed=!0},isCollapsed:function(){return this.collapsed},add:function(g){g.settings||(g=new c.ui.MenuItem(g.id||
+i.uniqueId(),g));this.onAddItem.dispatch(this,g);return this.items[g.id]=g},addSeparator:function(){return this.add({separator:!0})},addMenu:function(c){c.collapse||(c=this.createMenu(c));this.menuCount++;return this.add(c)},hasMenus:function(){return this.menuCount!==0},remove:function(c){delete this.items[c.id]},removeAll:function(){j(this,function(c){c.removeAll?c.removeAll():c.remove();c.destroy()},"items",this);this.items={}},createMenu:function(g){g=new c.ui.Menu(g.id||i.uniqueId(),g);g.onAddItem.add(this.onAddItem.dispatch,
+this.onAddItem);return g}})})(tinymce);
+(function(c){var i=c.is,j=c.DOM,g=c.each,b=c.dom.Event,a=c.dom.Element;c.create("tinymce.ui.DropMenu:tinymce.ui.Menu",{DropMenu:function(a,b){b=b||{};b.container=b.container||j.doc.body;b.offset_x=b.offset_x||0;b.offset_y=b.offset_y||0;b.vp_offset_x=b.vp_offset_x||0;b.vp_offset_y=b.vp_offset_y||0;i(b.icons)&&!b.icons&&(b["class"]+=" mceNoIcons");this.parent(a,b);this.onShowMenu=new c.util.Dispatcher(this);this.onHideMenu=new c.util.Dispatcher(this);this.classPrefix="mceMenu"},createMenu:function(a){var b=
+this.settings;a.container=a.container||b.container;a.parent=this;a.constrain=a.constrain||b.constrain;a["class"]=a["class"]||b["class"];a.vp_offset_x=a.vp_offset_x||b.vp_offset_x;a.vp_offset_y=a.vp_offset_y||b.vp_offset_y;a.keyboard_focus=b.keyboard_focus;a=new c.ui.DropMenu(a.id||j.uniqueId(),a);a.onAddItem.add(this.onAddItem.dispatch,this.onAddItem);return a},focus:function(){this.keyboardNav&&this.keyboardNav.focus()},update:function(){var a=this.settings,b=j.get("menu_"+this.id+"_tbl"),c=j.get("menu_"+
+this.id+"_co"),g,i;g=a.max_width?Math.min(b.clientWidth,a.max_width):b.clientWidth;i=a.max_height?Math.min(b.clientHeight,a.max_height):b.clientHeight;j.boxModel?this.element.setStyles({width:g,height:i}):this.element.setStyles({width:g+2,height:i+2});a.max_width&&j.setStyle(c,"width",g);a.max_height&&(j.setStyle(c,"height",i),b.clientHeight<a.max_height&&j.setStyle(c,"overflow","hidden"))},showMenu:function(f,d,i){var k=this,m=k.settings,o,e=j.getViewPort(),h,p,u,l,s=k.classPrefix;k.collapse(1);
+if(!k.isMenuVisible){k.rendered?o=j.get("menu_"+k.id):(o=j.add(k.settings.container,k.renderNode()),g(k.items,function(a){a.postRender()}),k.element=new a("menu_"+k.id,{blocker:1,container:m.container}));c.isOpera||j.setStyles(o,{left:-65535,top:-65535});j.show(o);k.update();f+=m.offset_x||0;d+=m.offset_y||0;e.w-=4;e.h-=4;m.constrain&&(h=o.clientWidth-2,p=o.clientHeight-2,u=e.x+e.w,e=e.y+e.h,f+m.vp_offset_x+h>u&&(f=i?i-h:Math.max(0,u-m.vp_offset_x-h)),d+m.vp_offset_y+p>e&&(d=Math.max(0,e-m.vp_offset_y-
+p)));j.setStyles(o,{left:f,top:d});k.element.update();k.isMenuVisible=1;k.mouseClickFunc=b.add(o,"click",function(a){var e;if((a=a.target)&&(a=j.getParent(a,"tr"))&&!j.hasClass(a,s+"ItemSub"))if(e=k.items[a.id],!e.isDisabled()){for(l=k;l;)l.hideMenu&&l.hideMenu(),l=l.settings.parent;if(e.settings.onclick)e.settings.onclick(a);return b.cancel(a)}});if(k.hasMenus())k.mouseOverFunc=b.add(o,"mouseover",function(a){var b;if((a=a.target)&&(a=j.getParent(a,"tr")))if(b=k.items[a.id],k.lastMenu&&k.lastMenu.collapse(1),
+!b.isDisabled()&&a&&j.hasClass(a,s+"ItemSub"))a=j.getRect(a),b.showMenu(a.x+a.w-2,a.y-2,a.x),k.lastMenu=b,j.addClass(j.get(b.id).firstChild,s+"ItemActive")});b.add(o,"keydown",k._keyHandler,k);k.onShowMenu.dispatch(k);m.keyboard_focus&&k._setupKeyboardNav()}},hideMenu:function(a){var d=j.get("menu_"+this.id),c;if(this.isMenuVisible)this.keyboardNav&&this.keyboardNav.destroy(),b.remove(d,"mouseover",this.mouseOverFunc),b.remove(d,"click",this.mouseClickFunc),b.remove(d,"keydown",this._keyHandler),
+j.hide(d),this.isMenuVisible=0,a||this.collapse(1),this.element&&this.element.hide(),(c=j.get(this.id))&&j.removeClass(c.firstChild,this.classPrefix+"ItemActive"),this.onHideMenu.dispatch(this)},add:function(a){var b,a=this.parent(a);this.isRendered&&(b=j.get("menu_"+this.id))&&this._add(j.select("tbody",b)[0],a);return a},collapse:function(a){this.parent(a);this.hideMenu(1)},remove:function(a){j.remove(a.id);this.destroy();return this.parent(a)},destroy:function(){var a=j.get("menu_"+this.id);this.keyboardNav&&
+this.keyboardNav.destroy();b.remove(a,"mouseover",this.mouseOverFunc);b.remove(j.select("a",a),"focus",this.mouseOverFunc);b.remove(a,"click",this.mouseClickFunc);b.remove(a,"keydown",this._keyHandler);this.element&&this.element.remove();j.remove(a)},renderNode:function(){var b=this,d=b.settings,c,i,m;m=j.create("div",{role:"listbox",id:"menu_"+b.id,"class":d["class"],style:"position:absolute;left:0;top:0;z-index:200000;outline:0"});b.settings.parent&&j.setAttrib(m,"aria-parent","menu_"+b.settings.parent.id);
+i=j.add(m,"div",{role:"presentation",id:"menu_"+b.id+"_co","class":b.classPrefix+(d["class"]?" "+d["class"]:"")});b.element=new a("menu_"+b.id,{blocker:1,container:d.container});d.menu_line&&j.add(i,"span",{"class":b.classPrefix+"Line"});d=j.add(i,"table",{role:"presentation",id:"menu_"+b.id+"_tbl",border:0,cellPadding:0,cellSpacing:0});c=j.add(d,"tbody");g(b.items,function(a){b._add(c,a)});b.rendered=!0;return m},_setupKeyboardNav:function(){var a,b,g=this;a=j.select("#menu_"+g.id)[0];b=j.select("a[role=option]",
+"menu_"+g.id);b.splice(0,0,a);g.keyboardNav=new c.ui.KeyboardNavigation({root:"menu_"+g.id,items:b,onCancel:function(){g.hideMenu()},enableUpDown:!0});a.focus()},_keyHandler:function(a){switch(a.keyCode){case 37:this.settings.parent&&(this.hideMenu(),this.settings.parent.focus(),b.cancel(a));break;case 39:this.mouseOverFunc&&this.mouseOverFunc(a)}},_add:function(a,b){var c,g=b.settings,i,o,e,h=this.classPrefix;g.separator?(o=j.add(a,"tr",{id:b.id,"class":h+"ItemSeparator"}),j.add(o,"td",{"class":h+
+"ItemSeparator"}),(c=o.previousSibling)&&j.addClass(c,"mceLast")):(c=o=j.add(a,"tr",{id:b.id,"class":h+"Item "+h+"ItemEnabled"}),c=e=j.add(c,g.titleItem?"th":"td"),c=i=j.add(c,"a",{id:b.id+"_aria",role:g.titleItem?"presentation":"option",href:"javascript:;",onclick:"return false;",onmousedown:"return false;"}),g.parent&&(j.setAttrib(i,"aria-haspopup","true"),j.setAttrib(i,"aria-owns","menu_"+b.id)),j.addClass(e,g["class"]),i=j.add(c,"span",{"class":"mceIcon"+(g.icon?" mce_"+g.icon:"")}),g.icon_src&&
+j.add(i,"img",{src:g.icon_src}),c=j.add(c,g.element||"span",{"class":"mceText",title:b.settings.title},b.settings.title),b.settings.style&&j.setAttrib(c,"style",b.settings.style),a.childNodes.length==1&&j.addClass(o,"mceFirst"),(c=o.previousSibling)&&j.hasClass(c,h+"ItemSeparator")&&j.addClass(o,"mceFirst"),b.collapse&&j.addClass(o,h+"ItemSub"),(c=o.previousSibling)&&j.removeClass(c,"mceLast"),j.addClass(o,"mceLast"))}})})(tinymce);
+(function(c){var i=c.DOM;c.create("tinymce.ui.Button:tinymce.ui.Control",{Button:function(c,g,b){this.parent(c,g,b);this.classPrefix="mceButton"},renderHTML:function(){var c=this.classPrefix,g=this.settings,b,a;a=i.encode(g.label||"");b='<a role="button" id="'+this.id+'" href="javascript:;" class="'+c+" "+c+"Enabled "+g["class"]+(a?" "+c+"Labeled":"")+'" onmousedown="return false;" onclick="return false;" aria-labelledby="'+this.id+'_voice" title="'+i.encode(g.title)+'">';b+=g.image?'<img class="mceIcon" src="'+
+g.image+'" alt="'+i.encode(g.title)+'" />'+a:'<span class="mceIcon '+g["class"]+'"></span>'+(a?'<span class="'+c+'Label">'+a+"</span>":"");b+='<span class="mceVoiceLabel mceIconOnly" style="display: none;" id="'+this.id+'_voice">'+g.title+"</span>";b+="</a>";return b},postRender:function(){var i=this,g=i.settings;c.dom.Event.add(i.id,"click",function(b){if(!i.isDisabled())return g.onclick.call(g.scope,b)})}})})(tinymce);
+(function(c){var i=c.DOM,j=c.dom.Event,g=c.each,b=c.util.Dispatcher;c.create("tinymce.ui.ListBox:tinymce.ui.Control",{ListBox:function(a,f,d){this.parent(a,f,d);this.items=[];this.onChange=new b(this);this.onPostRender=new b(this);this.onAdd=new b(this);this.onRenderMenu=new c.util.Dispatcher(this);this.classPrefix="mceListBox"},select:function(a){var b=this,c,i;if(a==void 0)return b.selectByIndex(-1);i=a&&a.call?a:function(b){return b==a};a!=b.selectedValue&&(g(b.items,function(a,g){if(i(a.value))return c=
+1,b.selectByIndex(g),!1}),c||b.selectByIndex(-1))},selectByIndex:function(a){var b,c;if(a!=this.selectedIndex)b=i.get(this.id+"_text"),(c=this.items[a])?(this.selectedValue=c.value,this.selectedIndex=a,i.setHTML(b,i.encode(c.title)),i.removeClass(b,"mceTitle"),i.setAttrib(this.id,"aria-valuenow",c.title)):(i.setHTML(b,i.encode(this.settings.title)),i.addClass(b,"mceTitle"),this.selectedValue=this.selectedIndex=null,i.setAttrib(this.id,"aria-valuenow",this.settings.title))},add:function(a,b,d){d=d||
+{};d=c.extend(d,{title:a,value:b});this.items.push(d);this.onAdd.dispatch(this,d)},getLength:function(){return this.items.length},renderHTML:function(){var a="",a=this.settings,b=this.classPrefix,a='<span role="button" aria-haspopup="true" aria-labelledby="'+this.id+'_text" aria-describedby="'+this.id+'_voiceDesc"><table role="presentation" tabindex="0" id="'+this.id+'" cellpadding="0" cellspacing="0" class="'+b+" "+b+"Enabled"+(a["class"]?" "+a["class"]:"")+'"><tbody><tr>';a+="<td>"+i.createHTML("span",
+{id:this.id+"_voiceDesc","class":"voiceLabel",style:"display:none;"},this.settings.title);a+=i.createHTML("a",{id:this.id+"_text",tabindex:-1,href:"javascript:;","class":"mceText",onclick:"return false;",onmousedown:"return false;"},i.encode(this.settings.title))+"</td>";a+="<td>"+i.createHTML("a",{id:this.id+"_open",tabindex:-1,href:"javascript:;","class":"mceOpen",onclick:"return false;",onmousedown:"return false;"},'<span><span style="display:none;" class="mceIconOnly" aria-hidden="true">\u25bc</span></span>')+
+"</td>";a+="</tr></tbody></table></span>";return a},showMenu:function(){var a=this,b,d=i.get(this.id),n;if(!(a.isDisabled()||a.items.length==0)){if(a.menu&&a.menu.isMenuVisible)return a.hideMenu();if(!a.isMenuRendered)a.renderMenu(),a.isMenuRendered=!0;i.getPos(this.settings.menu_container);b=i.getPos(d);n=a.menu;n.settings.offset_x=b.x;n.settings.offset_y=b.y;n.settings.keyboard_focus=!c.isOpera;a.oldID&&n.items[a.oldID].setSelected(0);g(a.items,function(b){if(b.value===a.selectedValue)n.items[b.id].setSelected(1),
+a.oldID=b.id});n.showMenu(0,d.clientHeight);j.add(i.doc,"mousedown",a.hideMenu,a);i.addClass(a.id,a.classPrefix+"Selected")}},hideMenu:function(a){if(this.menu&&this.menu.isMenuVisible&&(i.removeClass(this.id,this.classPrefix+"Selected"),!a||!(a.type=="mousedown"&&(a.target.id==this.id+"_text"||a.target.id==this.id+"_open"))))if(!a||!i.getParent(a.target,".mceMenu"))i.removeClass(this.id,this.classPrefix+"Selected"),j.remove(i.doc,"mousedown",this.hideMenu,this),this.menu.hideMenu()},renderMenu:function(){var a=
+this,b;b=a.settings.control_manager.createDropMenu(a.id+"_menu",{menu_line:1,"class":a.classPrefix+"Menu mceNoIcons",max_width:150,max_height:150});b.onHideMenu.add(function(){a.hideMenu();a.focus()});b.add({title:a.settings.title,"class":"mceMenuItemTitle",onclick:function(){a.settings.onselect("")!==!1&&a.select("")}});g(a.items,function(c){c.value===void 0?b.add({title:c.title,"class":"mceMenuItemTitle",onclick:function(){a.settings.onselect("")!==!1&&a.select("")}}):(c.id=i.uniqueId(),c.onclick=
+function(){a.settings.onselect(c.value)!==!1&&a.select(c.value)},b.add(c))});a.onRenderMenu.dispatch(a,b);a.menu=b},postRender:function(){var a=this,b=a.classPrefix;j.add(a.id,"click",a.showMenu,a);j.add(a.id,"keydown",function(b){b.keyCode==32&&(a.showMenu(b),j.cancel(b))});j.add(a.id,"focus",function(){if(!a._focused)a.keyDownHandler=j.add(a.id,"keydown",function(b){b.keyCode==40&&(a.showMenu(),j.cancel(b))}),a.keyPressHandler=j.add(a.id,"keypress",function(b){var c;if(b.keyCode==13)c=a.selectedValue,
+a.selectedValue=null,j.cancel(b),a.settings.onselect(c)});a._focused=1});j.add(a.id,"blur",function(){j.remove(a.id,"keydown",a.keyDownHandler);j.remove(a.id,"keypress",a.keyPressHandler);a._focused=0});if(c.isIE6||!i.boxModel)j.add(a.id,"mouseover",function(){i.hasClass(a.id,b+"Disabled")||i.addClass(a.id,b+"Hover")}),j.add(a.id,"mouseout",function(){i.hasClass(a.id,b+"Disabled")||i.removeClass(a.id,b+"Hover")});a.onPostRender.dispatch(a,i.get(a.id))},destroy:function(){this.parent();j.clear(this.id+
+"_text");j.clear(this.id+"_open")}})})(tinymce);
+(function(c){var i=c.DOM,j=c.dom.Event,g=c.each;c.create("tinymce.ui.NativeListBox:tinymce.ui.ListBox",{NativeListBox:function(b,a){this.parent(b,a);this.classPrefix="mceNativeListBox"},setDisabled:function(b){i.get(this.id).disabled=b;this.setAriaProperty("disabled",b)},isDisabled:function(){return i.get(this.id).disabled},select:function(b){var a=this,c,d;if(b==void 0)return a.selectByIndex(-1);d=b&&b.call?b:function(a){return a==b};b!=a.selectedValue&&(g(a.items,function(b,g){if(d(b.value))return c=
+1,a.selectByIndex(g),!1}),c||a.selectByIndex(-1))},selectByIndex:function(b){i.get(this.id).selectedIndex=b+1;this.selectedValue=this.items[b]?this.items[b].value:null},add:function(b,a,c){c=c||{};c.value=a;this.isRendered()&&i.add(i.get(this.id),"option",c,b);b={title:b,value:a,attribs:c};this.items.push(b);this.onAdd.dispatch(this,b)},getLength:function(){return this.items.length},renderHTML:function(){var b;b=i.createHTML("option",{value:""},"-- "+this.settings.title+" --");g(this.items,function(a){b+=
+i.createHTML("option",{value:a.value},a.title)});b=i.createHTML("select",{id:this.id,"class":"mceNativeListBox","aria-labelledby":this.id+"_aria"},b);b+=i.createHTML("span",{id:this.id+"_aria",style:"display: none"},this.settings.title);return b},postRender:function(){function b(b){if((b=a.items[b.target.selectedIndex-1])&&(b=b.value))if(a.onChange.dispatch(a,b),a.settings.onselect)a.settings.onselect(b)}var a=this,c=!0;a.rendered=!0;j.add(a.id,"change",b);j.add(a.id,"keydown",function(d){var g;j.remove(a.id,
+"change",void 0);c=!1;g=j.add(a.id,"blur",function(){c||(c=!0,j.add(a.id,"change",b),j.remove(a.id,"blur",g))});if(d.keyCode==13||d.keyCode==32)return b(d),j.cancel(d)});a.onPostRender.dispatch(a,i.get(a.id))}})})(tinymce);
+(function(c){var i=c.DOM,j=c.dom.Event;c.create("tinymce.ui.MenuButton:tinymce.ui.Button",{MenuButton:function(g,b,a){this.parent(g,b,a);this.onRenderMenu=new c.util.Dispatcher(this);b.menu_container=b.menu_container||i.doc.body},showMenu:function(){var c,b=i.get(this.id),a;if(!this.isDisabled()){if(!this.isMenuRendered)this.renderMenu(),this.isMenuRendered=!0;if(this.isMenuVisible)return this.hideMenu();i.getPos(this.settings.menu_container);c=i.getPos(b);a=this.menu;a.settings.offset_x=c.x;a.settings.offset_y=
+c.y;a.settings.vp_offset_x=c.x;a.settings.vp_offset_y=c.y;a.settings.keyboard_focus=this._focused;a.showMenu(0,b.clientHeight);j.add(i.doc,"mousedown",this.hideMenu,this);this.setState("Selected",1);this.isMenuVisible=1}},renderMenu:function(){var c=this,b;b=c.settings.control_manager.createDropMenu(c.id+"_menu",{menu_line:1,"class":this.classPrefix+"Menu",icons:c.settings.icons});b.onHideMenu.add(function(){c.hideMenu();c.focus()});c.onRenderMenu.dispatch(c,b);c.menu=b},hideMenu:function(c){var b=
+this;if(!c||!(c.type=="mousedown"&&i.getParent(c.target,function(a){return a.id===b.id||a.id===b.id+"_open"}))){if(!c||!i.getParent(c.target,".mceMenu"))b.setState("Selected",0),j.remove(i.doc,"mousedown",b.hideMenu,b),b.menu&&b.menu.hideMenu();b.isMenuVisible=0}},postRender:function(){var c=this,b=c.settings;j.add(c.id,"click",function(){if(!c.isDisabled()){if(b.onclick)b.onclick(c.value);c.showMenu()}})}})})(tinymce);
+(function(c){var i=c.DOM,j=c.dom.Event;c.create("tinymce.ui.SplitButton:tinymce.ui.MenuButton",{SplitButton:function(c,b,a){this.parent(c,b,a);this.classPrefix="mceSplitButton"},renderHTML:function(){var c,b=this.settings,a;c="<tbody><tr>";a=b.image?i.createHTML("img ",{src:b.image,role:"presentation","class":"mceAction "+b["class"]}):i.createHTML("span",{"class":"mceAction "+b["class"]},"");a+=i.createHTML("span",{"class":"mceVoiceLabel mceIconOnly",id:this.id+"_voice",style:"display:none;"},b.title);
+c+="<td >"+i.createHTML("a",{role:"button",id:this.id+"_action",tabindex:"-1",href:"javascript:;","class":"mceAction "+b["class"],onclick:"return false;",onmousedown:"return false;",title:b.title},a)+"</td>";a=i.createHTML("span",{"class":"mceOpen "+b["class"]},'<span style="display:none;" class="mceIconOnly" aria-hidden="true">\u25bc</span>');c+="<td >"+i.createHTML("a",{role:"button",id:this.id+"_open",tabindex:"-1",href:"javascript:;","class":"mceOpen "+b["class"],onclick:"return false;",onmousedown:"return false;",
+title:b.title},a)+"</td>";c+="</tr></tbody>";c=i.createHTML("table",{id:this.id,role:"presentation",tabindex:"0","class":"mceSplitButton mceSplitButtonEnabled "+b["class"],cellpadding:"0",cellspacing:"0",title:b.title},c);return i.createHTML("span",{role:"button","aria-labelledby":this.id+"_voice","aria-haspopup":"true"},c)},postRender:function(){var g=this,b=g.settings,a;b.onclick&&(a=function(a){g.isDisabled()||(b.onclick(g.value),j.cancel(a))},j.add(g.id+"_action","click",a),j.add(g.id,["click",
+"keydown"],function(b){if((b.keyCode===32||b.keyCode===13||b.keyCode===14)&&!b.altKey&&!b.ctrlKey&&!b.metaKey)a(),j.cancel(b);else if(b.type==="click"||b.keyCode===40)g.showMenu(),j.cancel(b)}));j.add(g.id+"_open","click",function(a){g.showMenu();j.cancel(a)});j.add([g.id,g.id+"_open"],"focus",function(){g._focused=1});j.add([g.id,g.id+"_open"],"blur",function(){g._focused=0});if(c.isIE6||!i.boxModel)j.add(g.id,"mouseover",function(){i.hasClass(g.id,"mceSplitButtonDisabled")||i.addClass(g.id,"mceSplitButtonHover")}),
+j.add(g.id,"mouseout",function(){i.hasClass(g.id,"mceSplitButtonDisabled")||i.removeClass(g.id,"mceSplitButtonHover")})},destroy:function(){this.parent();j.clear(this.id+"_action");j.clear(this.id+"_open");j.clear(this.id)}})})(tinymce);
+(function(c){var i=c.DOM,j=c.dom.Event,g=c.is,b=c.each;c.create("tinymce.ui.ColorSplitButton:tinymce.ui.SplitButton",{ColorSplitButton:function(a,b,d){this.parent(a,b,d);this.settings=b=c.extend({colors:"000000,993300,333300,003300,003366,000080,333399,333333,800000,FF6600,808000,008000,008080,0000FF,666699,808080,FF0000,FF9900,99CC00,339966,33CCCC,3366FF,800080,999999,FF00FF,FFCC00,FFFF00,00FF00,00FFFF,00CCFF,993366,C0C0C0,FF99CC,FFCC99,FFFF99,CCFFCC,CCFFFF,99CCFF,CC99FF,FFFFFF",grid_width:8,default_color:"#888888"},
+this.settings);this.onShowMenu=new c.util.Dispatcher(this);this.onHideMenu=new c.util.Dispatcher(this);this.value=b.default_color},showMenu:function(){var a=this,b,c;if(!a.isDisabled()){if(!a.isMenuRendered)a.renderMenu(),a.isMenuRendered=!0;if(a.isMenuVisible)return a.hideMenu();b=i.get(a.id);i.show(a.id+"_menu");i.addClass(b,"mceSplitButtonSelected");c=i.getPos(b);i.setStyles(a.id+"_menu",{left:c.x,top:c.y+b.clientHeight,zIndex:2E5});b=0;j.add(i.doc,"mousedown",a.hideMenu,a);a.onShowMenu.dispatch(a);
+if(a._focused)a._keyHandler=j.add(a.id+"_menu","keydown",function(b){b.keyCode==27&&a.hideMenu()}),i.select("a",a.id+"_menu")[0].focus();a.isMenuVisible=1}},hideMenu:function(a){var b=this;if(b.isMenuVisible&&(!a||!(a.type=="mousedown"&&i.getParent(a.target,function(a){return a.id===b.id+"_open"})))){if(!a||!i.getParent(a.target,".mceSplitButtonMenu"))i.removeClass(b.id,"mceSplitButtonSelected"),j.remove(i.doc,"mousedown",b.hideMenu,b),j.remove(b.id+"_menu","keydown",b._keyHandler),i.hide(b.id+"_menu");
+b.isMenuVisible=0}},renderMenu:function(){var a=this,f,d=0,n=a.settings,k,m,o,e,h;e=i.add(n.menu_container,"div",{role:"listbox",id:a.id+"_menu","class":n.menu_class+" "+n["class"],style:"position:absolute;left:0;top:-1000px;"});f=i.add(e,"div",{"class":n["class"]+" mceSplitButtonMenu"});i.add(f,"span",{"class":"mceMenuLine"});k=i.add(f,"table",{role:"presentation","class":"mceColorSplitMenu"});m=i.add(k,"tbody");d=0;b(g(n.colors,"array")?n.colors:n.colors.split(","),function(b){b=b.replace(/^#/,
+"");d--||(o=i.add(m,"tr"),d=n.grid_width-1);k=i.add(o,"td");k=i.add(k,"a",{role:"option",href:"javascript:;",style:{backgroundColor:"#"+b},title:a.editor.getLang("colors."+b,b),"data-mce-color":"#"+b});if(a.editor.forcedHighContrastMode)k=i.add(k,"canvas",{width:16,height:16,"aria-hidden":"true"}),k.getContext&&(h=k.getContext("2d"))?(h.fillStyle="#"+b,h.fillRect(0,0,16,16)):i.remove(k)});n.more_colors_func&&(k=i.add(m,"tr"),k=i.add(k,"td",{colspan:n.grid_width,"class":"mceMoreColors"}),k=i.add(k,
+"a",{role:"option",id:a.id+"_more",href:"javascript:;",onclick:"return false;","class":"mceMoreColors"},n.more_colors_title),j.add(k,"click",function(a){n.more_colors_func.call(n.more_colors_scope||this);return j.cancel(a)}));i.addClass(f,"mceColorSplitMenu");new c.ui.KeyboardNavigation({root:a.id+"_menu",items:i.select("a",a.id+"_menu"),onCancel:function(){a.hideMenu();a.focus()}});j.add(a.id+"_menu","mousedown",function(a){return j.cancel(a)});j.add(a.id+"_menu","click",function(b){var e;(b=i.getParent(b.target,
+"a",m))&&b.nodeName.toLowerCase()=="a"&&(e=b.getAttribute("data-mce-color"))&&a.setColor(e);return j.cancel(b)});return e},setColor:function(a){this.displayColor(a);this.hideMenu();this.settings.onselect(a)},displayColor:function(a){i.setStyle(this.id+"_preview","backgroundColor",a);this.value=a},postRender:function(){var a=this.id;this.parent();i.add(a+"_action","div",{id:a+"_preview","class":"mceColorPreview"});i.setStyle(this.id+"_preview","backgroundColor",this.value)},destroy:function(){this.parent();
+j.clear(this.id+"_menu");j.clear(this.id+"_more");i.remove(this.id+"_menu")}})})(tinymce);
+(function(c){var i=c.DOM,j=c.each,g=c.dom.Event;c.create("tinymce.ui.ToolbarGroup:tinymce.ui.Container",{renderHTML:function(){var b=[],a=this.controls,f=c.each,d=this.settings;b.push('<div id="'+this.id+'" role="group" aria-labelledby="'+this.id+'_voice">');b.push("<span role='application'>");b.push('<span id="'+this.id+'_voice" class="mceVoiceLabel" style="display:none;">'+i.encode(d.name)+"</span>");f(a,function(a){b.push(a.renderHTML())});b.push("</span>");b.push("</div>");return b.join("")},
+focus:function(){this.keyNav.focus()},postRender:function(){var b=this,a=[];j(b.controls,function(b){j(b.controls,function(b){b.id&&a.push(b)})});b.keyNav=new c.ui.KeyboardNavigation({root:b.id,items:a,onCancel:function(){b.editor.focus()},excludeFromTabOrder:!b.settings.tab_focus_toolbar})},destroy:function(){this.parent();this.keyNav.destroy();g.clear(this.id)}})})(tinymce);
+(function(c){var i=c.DOM;c.create("tinymce.ui.Toolbar:tinymce.ui.Container",{renderHTML:function(){var c="",g,b,a=this.settings,f,d,n,k;k=this.controls;for(f=0;f<k.length;f++){b=k[f];d=k[f-1];n=k[f+1];f===0&&(g="mceToolbarStart",b.Button?g+=" mceToolbarStartButton":b.SplitButton?g+=" mceToolbarStartSplitButton":b.ListBox&&(g+=" mceToolbarStartListBox"),c+=i.createHTML("td",{"class":g},i.createHTML("span",null,"<\!-- IE --\>")));if(d&&b.ListBox&&(d.Button||d.SplitButton))c+=i.createHTML("td",{"class":"mceToolbarEnd"},
+i.createHTML("span",null,"<\!-- IE --\>"));c+=i.stdMode?'<td style="position: relative">'+b.renderHTML()+"</td>":"<td>"+b.renderHTML()+"</td>";if(n&&b.ListBox&&(n.Button||n.SplitButton))c+=i.createHTML("td",{"class":"mceToolbarStart"},i.createHTML("span",null,"<\!-- IE --\>"))}g="mceToolbarEnd";b.Button?g+=" mceToolbarEndButton":b.SplitButton?g+=" mceToolbarEndSplitButton":b.ListBox&&(g+=" mceToolbarEndListBox");c+=i.createHTML("td",{"class":g},i.createHTML("span",null,"<\!-- IE --\>"));return i.createHTML("table",
+{id:this.id,"class":"mceToolbar"+(a["class"]?" "+a["class"]:""),cellpadding:"0",cellspacing:"0",align:this.settings.align||"",role:"presentation",tabindex:"-1"},"<tbody><tr>"+c+"</tr></tbody>")}})})(tinymce);
+(function(c){var i=c.util.Dispatcher;c.create("tinymce.AddOnManager",{AddOnManager:function(){this.items=[];this.urls={};this.lookup={};this.onAdd=new i(this)},get:function(c){return this.lookup[c]},requireLangPack:function(i){var g=c.settings;g&&g.language&&g.language_load!==!1&&c.ScriptLoader.add(this.urls[i]+"/langs/"+g.language+".js")},add:function(c,g){this.items.push(g);this.lookup[c]=g;this.onAdd.dispatch(this,c,g);return g},load:function(i,g,b,a){this.urls[i]||(g.indexOf("/")!=0&&g.indexOf("://")==
+-1&&(g=c.baseURL+"/"+g),this.urls[i]=g.substring(0,g.lastIndexOf("/")),this.lookup[i]||c.ScriptLoader.add(g,b,a))}});c.PluginManager=new c.AddOnManager;c.ThemeManager=new c.AddOnManager})(tinymce);
+(function(c){var i=c.each,j=c.extend,g=c.DOM,b=c.dom.Event,a=c.explode,f=c.util.Dispatcher,d=0;c.documentBaseURL=window.location.href.replace(/[\?#].*$/,"").replace(/[\/\\][^\/]+$/,"");/[\/\\]$/.test(c.documentBaseURL)||(c.documentBaseURL+="/");c.baseURL=(new c.util.URI(c.documentBaseURL)).toAbsolute(c.baseURL);c.baseURI=new c.util.URI(c.baseURL);c.onBeforeUnload=new f(c);b.add(window,"beforeunload",function(a){c.onBeforeUnload.dispatch(c,a)});c.onAddEditor=new f(c);c.onRemoveEditor=new f(c);c.EditorManager=
+j(c,{editors:[],i18n:{},activeEditor:null,init:function(f){function k(a,b,e){var d=a[b];if(d)return c.is(d,"string")&&(e=(e=d.replace(/\.\w+$/,""))?c.resolve(e):0,d=c.resolve(d)),d.apply(e||this,Array.prototype.slice.call(arguments,2))}var m=this,o,e=[],h,f=j({theme:"simple",language:"en"},f);m.settings=f;b.add(document,"init",function(){var b,j;k(f,"onpageload");switch(f.mode){case "exact":b=f.elements||"";b.length>0&&i(a(b),function(a){g.get(a)?(h=new c.Editor(a,f),e.push(h),h.render(1)):i(document.forms,
+function(b){i(b.elements,function(b){b.name===a&&(a="mce_editor_"+d++,g.setAttrib(b,"id",a),h=new c.Editor(a,f),e.push(h),h.render(1))})})});break;case "textareas":case "specific_textareas":i(g.select("textarea"),function(a){if(!f.editor_deselector||!(f.editor_deselector.constructor===RegExp?f.editor_deselector.test(a.className):g.hasClass(a,f.editor_deselector)))if(!f.editor_selector||(f.editor_selector.constructor===RegExp?f.editor_selector.test(a.className):g.hasClass(a,f.editor_selector))){o=
+g.get(a.name);if(!a.id&&!o)a.id=a.name;if(!a.id||m.get(a.id))a.id=g.uniqueId();h=new c.Editor(a.id,f);e.push(h);h.render(1)}})}f.oninit&&(b=j=0,i(e,function(a){j++;a.initialized?b++:a.onInit.add(function(){b++;b==j&&k(f,"oninit")});b==j&&k(f,"oninit")}))})},get:function(a){if(a===void 0)return this.editors;return this.editors[a]},getInstanceById:function(a){return this.get(a)},add:function(a){var b=this.editors;b[a.id]=a;b.push(a);this._setActive(a);this.onAddEditor.dispatch(this,a);return a},remove:function(a){var b,
+c=this.editors;if(!c[a.id])return null;delete c[a.id];for(b=0;b<c.length;b++)if(c[b]==a){c.splice(b,1);break}this.activeEditor==a&&this._setActive(c[0]);a.destroy();this.onRemoveEditor.dispatch(this,a);return a},execCommand:function(a,b,d){var f=this.get(d),e;switch(a){case "mceFocus":return f.focus(),!0;case "mceAddEditor":case "mceAddControl":return this.get(d)||(new c.Editor(d,this.settings)).render(),!0;case "mceAddFrameControl":e=d.window;e.tinyMCE=tinyMCE;e.tinymce=c;c.DOM.doc=e.document;c.DOM.win=
+e;f=new c.Editor(d.element_id,d);f.render();if(c.isIE){var h=function(){var k;f.destroy();e.detachEvent("onunload",h);k=e.tinyMCE=e.tinymce=null,e=k};e.attachEvent("onunload",h)}d.page_window=null;return!0;case "mceRemoveEditor":case "mceRemoveControl":return f&&f.remove(),!0;case "mceToggleEditor":if(!f)return this.execCommand("mceAddControl",0,d),!0;f.isHidden()?f.show():f.hide();return!0}if(this.activeEditor)return this.activeEditor.execCommand(a,b,d);return!1},execInstanceCommand:function(a,b,
+c,d){if(a=this.get(a))return a.execCommand(b,c,d);return!1},triggerSave:function(){i(this.editors,function(a){a.save()})},addI18n:function(a,b){var d=this.i18n;c.is(a,"string")?i(b,function(b,e){d[a+"."+e]=b}):i(a,function(a,b){i(a,function(a,c){i(a,function(a,h){c==="common"?d[b+"."+h]=a:d[b+"."+c+"."+h]=a})})})},_setActive:function(a){this.selectedInstance=this.activeEditor=a}})})(tinymce);
+(function(c){var i=c.DOM,j=c.dom.Event,g=c.extend,b=c.util.Dispatcher,a=c.each,f=c.isGecko,d=c.isIE,n=c.is,k=c.ThemeManager,m=c.PluginManager,o=c.explode;c.create("tinymce.Editor",{Editor:function(e,d){var f=this;f.id=f.editorId=e;f.execCommands={};f.queryStateCommands={};f.queryValueCommands={};f.isNotDirty=!1;f.plugins={};a(["onPreInit","onBeforeRenderUI","onPostRender","onInit","onRemove","onActivate","onDeactivate","onClick","onEvent","onMouseUp","onMouseDown","onDblClick","onKeyDown","onKeyUp",
+"onKeyPress","onContextMenu","onSubmit","onReset","onPaste","onPreProcess","onPostProcess","onBeforeSetContent","onBeforeGetContent","onSetContent","onGetContent","onLoadContent","onSaveContent","onNodeChange","onChange","onBeforeExecCommand","onExecCommand","onUndo","onRedo","onVisualAid","onSetProgressState"],function(a){f[a]=new b(f)});f.settings=d=g({id:e,language:"en",docs_language:"en",theme:"simple",skin:"default",delta_width:0,delta_height:0,popup_css:"",plugins:"",document_base_url:c.documentBaseURL,
+add_form_submit_trigger:1,submit_patch:1,add_unload_trigger:1,convert_urls:1,relative_urls:1,remove_script_host:1,table_inline_editing:0,object_resizing:1,cleanup:1,accessibility_focus:1,custom_shortcuts:1,custom_undo_redo_keyboard_shortcuts:1,custom_undo_redo_restore_selection:1,custom_undo_redo:1,doctype:c.isIE6?'<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">':"<!DOCTYPE>",visual_table_class:"mceItemTable",visual:1,font_size_style_values:"xx-small,x-small,small,medium,large,x-large,xx-large",
+apply_source_formatting:1,directionality:"ltr",forced_root_block:"p",hidden_input:1,padd_empty_editor:1,render_ui:1,init_theme:1,force_p_newlines:1,indentation:"30px",keep_styles:1,fix_table_elements:1,inline_styles:1,convert_fonts_to_spans:!0,indent:"simple",indent_before:"p,h1,h2,h3,h4,h5,h6,blockquote,div,title,style,pre,script,td,ul,li,area,table,thead,tfoot,tbody,tr",indent_after:"p,h1,h2,h3,h4,h5,h6,blockquote,div,title,style,pre,script,td,ul,li,area,table,thead,tfoot,tbody,tr",validate:!0,
+entity_encoding:"named",url_converter:f.convertURL,url_converter_scope:f,ie7_compat:!0},d);f.documentBaseURI=new c.util.URI(d.document_base_url||c.documentBaseURL,{base_uri:tinyMCE.baseURI});f.baseURI=c.baseURI;f.contentCSS=[];f.execCallback("setup",f)},render:function(){var b=this,d=b.settings,f=b.id,g=c.ScriptLoader;if(j.domLoaded){if(tinyMCE.settings=d,b.getElement()&&!c.isIDevice){!/TEXTAREA|INPUT/i.test(b.getElement().nodeName)&&d.hidden_input&&i.getParent(f,"form")&&i.insertAfter(i.create("input",
+{type:"hidden",name:f}),f);if(c.WindowManager)b.windowManager=new c.WindowManager(b);d.encoding=="xml"&&b.onGetContent.add(function(a,b){if(b.save)b.content=i.encode(b.content)});d.add_form_submit_trigger&&b.onSubmit.addToTop(function(){if(b.initialized)b.save(),b.isNotDirty=1});if(d.add_unload_trigger)b._beforeUnload=tinyMCE.onBeforeUnload.add(function(){b.initialized&&!b.destroyed&&!b.isHidden()&&b.save({format:"raw",no_events:!0})});c.addUnload(b.destroy,b);d.submit_patch&&b.onBeforeRenderUI.add(function(){var a=
+b.getElement().form;if(a&&!a._mceOldSubmit){if(!a.submit.nodeType&&!a.submit.length)b.formElement=a,a._mceOldSubmit=a.submit,a.submit=function(){c.triggerSave();b.isNotDirty=1;return b.formElement._mceOldSubmit(b.formElement)};a=null}});(function(){d.language&&d.language_load!==!1&&g.add(c.baseURL+"/langs/"+d.language+".js");d.theme&&d.theme.charAt(0)!="-"&&!k.urls[d.theme]&&k.load(d.theme,"themes/"+d.theme+"/editor_template"+c.suffix+".js");a(o(d.plugins),function(a){a&&a.charAt(0)!="-"&&!m.urls[a]&&
+a!="safari"&&m.load(a,"plugins/"+a+"/editor_plugin"+c.suffix+".js")});g.loadQueue(function(){b.removed||b.init()})})()}}else j.add(document,"init",function(){b.render()})},init:function(){var b=this,h=b.settings,g,j,l=b.getElement(),n,B,r;c.add(b);h.aria_label=h.aria_label||i.getAttrib(l,"aria-label",b.getLang("aria.rich_text_area"));if(h.theme)h.theme=h.theme.replace(/-/,""),n=k.get(h.theme),b.theme=new n,b.theme.init&&h.init_theme&&b.theme.init(b,k.urls[h.theme]||c.documentBaseURL.replace(/\/$/,
+""));a(o(h.plugins.replace(/\-/g,"")),function(a){var d=m.get(a),h=m.urls[a]||c.documentBaseURL.replace(/\/$/,"");d&&(d=new d(b,h),b.plugins[a]=d,d.init&&d.init(b,h))});if(h.popup_css!==!1)h.popup_css=h.popup_css?b.documentBaseURI.toAbsolute(h.popup_css):b.baseURI.toAbsolute("themes/"+h.theme+"/skins/"+h.skin+"/dialog.css");h.popup_css_add&&(h.popup_css+=","+b.documentBaseURI.toAbsolute(h.popup_css_add));b.controlManager=new c.ControlManager(b);h.custom_undo_redo&&(b.onBeforeExecCommand.add(function(a,
+c,d,h,f){c!="Undo"&&c!="Redo"&&c!="mceRepaint"&&(!f||!f.skip_undo)&&b.undoManager.beforeChange()}),b.onExecCommand.add(function(a,c,d,h,f){c!="Undo"&&c!="Redo"&&c!="mceRepaint"&&(!f||!f.skip_undo)&&b.undoManager.add()}));b.onExecCommand.add(function(a,c){/^(FontName|FontSize)$/.test(c)||b.nodeChanged()});f&&(r=function(a,c){(!c||!c.initial)&&b.execCommand("mceRepaint")},b.onUndo.add(r),b.onRedo.add(r),b.onSetContent.add(r));b.onBeforeRenderUI.dispatch(b,b.controlManager);if(h.render_ui)g=h.width||
+l.style.width||l.offsetWidth,j=h.height||l.style.height||l.offsetHeight,b.orgDisplay=l.style.display,r=/^[0-9\.]+(|px)$/i,r.test(""+g)&&(g=Math.max(parseInt(g)+(n.deltaWidth||0),100)),r.test(""+j)&&(j=Math.max(parseInt(j)+(n.deltaHeight||0),100)),n=b.theme.renderUI({targetNode:l,width:g,height:j,deltaWidth:h.delta_width,deltaHeight:h.delta_height}),b.editorContainer=n.editorContainer;if(document.domain&&location.hostname!=document.domain)c.relaxedDomain=document.domain;i.setStyles(n.sizeContainer||
+n.editorContainer,{width:g,height:j});h.content_css&&c.each(o(h.content_css),function(a){b.contentCSS.push(b.documentBaseURI.toAbsolute(a))});j=(n.iframeHeight||j)+(typeof j=="number"?n.deltaHeight||0:"");j<100&&(j=100);b.iframeHTML=h.doctype+'<html><head xmlns="http://www.w3.org/1999/xhtml">';h.document_base_url!=c.documentBaseURL&&(b.iframeHTML+='<base href="'+b.documentBaseURI.getURI()+'" />');b.iframeHTML+=h.ie7_compat?'<meta http-equiv="X-UA-Compatible" content="IE=7" />':'<meta http-equiv="X-UA-Compatible" content="IE=edge" />';
+b.iframeHTML+='<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />';if(!f||!/Firefox\/2/.test(navigator.userAgent)){for(g=0;g<b.contentCSS.length;g++)b.iframeHTML+='<link type="text/css" rel="stylesheet" href="'+b.contentCSS[g]+'" />';b.contentCSS=[]}g=h.body_id||"tinymce";g.indexOf("=")!=-1&&(g=b.getParam("body_id","","hash"),g=g[b.id]||g);l=h.body_class||"";l.indexOf("=")!=-1&&(l=b.getParam("body_class","","hash"),l=l[b.id]||"");b.iframeHTML+='</head><body id="'+g+'" class="mceContentBody '+
+l+'"></body></html>';if(c.relaxedDomain&&(d||c.isOpera&&parseFloat(opera.version())<11))B='javascript:(function(){document.open();document.domain="'+document.domain+'";var ed = window.parent.tinyMCE.get("'+b.id+'");document.write(ed.iframeHTML);document.close();ed.setupIframe();})()';i.add(n.iframeContainer,"iframe",{id:b.id+"_ifr",src:B||'javascript:""',frameBorder:"0",title:h.aria_label,style:{width:"100%",height:j}});b.contentAreaContainer=n.iframeContainer;i.get(n.editorContainer).style.display=
+b.orgDisplay;i.get(b.id).style.display="none";i.setAttrib(b.id,"aria-hidden",!0);(!c.relaxedDomain||!B)&&b.setupIframe();l=n=null},setupIframe:function(){var b=this,h=b.settings;i.get(b.id);var g=b.getDoc(),k;if(!d||!c.relaxedDomain)if(g.open(),g.write(b.iframeHTML),g.close(),c.relaxedDomain)g.domain=c.relaxedDomain;if(!d)try{if(!h.readonly)g.designMode="On"}catch(l){}if(d){k=b.getBody();i.hide(k);if(!h.readonly)k.contentEditable=!0;i.show(k)}b.schema=new c.html.Schema(h);b.dom=new c.dom.DOMUtils(b.getDoc(),
+{keep_values:!0,url_converter:b.convertURL,url_converter_scope:b,hex_colors:h.force_hex_style_colors,class_filter:h.class_filter,update_styles:1,fix_ie_paragraphs:1,schema:b.schema});b.parser=new c.html.DomParser(h,b.schema);b.parser.addAttributeFilter("name",function(a){for(var b=a.length,c,d,e,h;b--;)if(h=a[b],h.name==="a"&&h.firstChild){e=h.parent;c=h.lastChild;do d=c.prev,e.insert(c,h),c=d;while(c)}});b.parser.addAttributeFilter("src,href,style",function(a,c){for(var d=a.length,h,f=b.dom,g;d--;)h=
+a[d],g=h.attr(c),c==="style"?h.attr("data-mce-style",f.serializeStyle(f.parseStyle(g),h.name)):h.attr("data-mce-"+c,b.convertURL(g,c,h.name))});b.parser.addNodeFilter("script",function(a){for(var b=a.length;b--;)a[b].attr("type","mce-text/javascript")});b.parser.addNodeFilter("#cdata",function(a){for(var b=a.length,c;b--;)c=a[b],c.type=8,c.name="#comment",c.value="[CDATA["+c.value+"]]"});b.parser.addNodeFilter("p,h1,h2,h3,h4,h5,h6,div",function(a){for(var d=a.length,h,f=b.schema.getNonEmptyElements();d--;)if(h=
+a[d],h.isEmpty(f))h.empty().append(new c.html.Node("br",1)).shortEnded=!0});b.serializer=new c.dom.Serializer(h,b.dom,b.schema);b.selection=new c.dom.Selection(b.dom,b.getWin(),b.serializer);b.formatter=new c.Formatter(this);b.formatter.register({alignleft:[{selector:"p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li",styles:{textAlign:"left"}},{selector:"img,table",collapsed:!1,styles:{"float":"left"}}],aligncenter:[{selector:"p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li",styles:{textAlign:"center"}},{selector:"img",
+collapsed:!1,styles:{display:"block",marginLeft:"auto",marginRight:"auto"}},{selector:"table",collapsed:!1,styles:{marginLeft:"auto",marginRight:"auto"}}],alignright:[{selector:"p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li",styles:{textAlign:"right"}},{selector:"img,table",collapsed:!1,styles:{"float":"right"}}],alignfull:[{selector:"p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li",styles:{textAlign:"justify"}}],bold:[{inline:"strong",remove:"all"},{inline:"span",styles:{fontWeight:"bold"}},{inline:"b",remove:"all"}],
+italic:[{inline:"em",remove:"all"},{inline:"span",styles:{fontStyle:"italic"}},{inline:"i",remove:"all"}],underline:[{inline:"span",styles:{textDecoration:"underline"},exact:!0},{inline:"u",remove:"all"}],strikethrough:[{inline:"span",styles:{textDecoration:"line-through"},exact:!0},{inline:"strike",remove:"all"}],forecolor:{inline:"span",styles:{color:"%value"},wrap_links:!1},hilitecolor:{inline:"span",styles:{backgroundColor:"%value"},wrap_links:!1},fontname:{inline:"span",styles:{fontFamily:"%value"}},
+fontsize:{inline:"span",styles:{fontSize:"%value"}},fontsize_class:{inline:"span",attributes:{"class":"%value"}},blockquote:{block:"blockquote",wrapper:1,remove:"all"},subscript:{inline:"sub"},superscript:{inline:"sup"},removeformat:[{selector:"b,strong,em,i,font,u,strike",remove:"all",split:!0,expand:!1,block_expand:!0,deep:!0},{selector:"span",attributes:["style","class"],remove:"empty",split:!0,expand:!1,deep:!0},{selector:"*",attributes:["style","class"],split:!1,expand:!1,deep:!0}]});a("p h1 h2 h3 h4 h5 h6 div address pre div code dt dd samp".split(/\s/),
+function(a){b.formatter.register(a,{block:a,remove:"all"})});b.formatter.register(b.settings.formats);b.undoManager=new c.UndoManager(b);b.undoManager.onAdd.add(function(a,c){if(a.hasUndo())return b.onChange.dispatch(b,c,a)});b.undoManager.onUndo.add(function(a,c){return b.onUndo.dispatch(b,c,a)});b.undoManager.onRedo.add(function(a,c){return b.onRedo.dispatch(b,c,a)});b.forceBlocks=new c.ForceBlocks(b,{forced_root_block:h.forced_root_block});b.editorCommands=new c.EditorCommands(b);b.serializer.onPreProcess.add(function(a,
+c){return b.onPreProcess.dispatch(b,c,a)});b.serializer.onPostProcess.add(function(a,c){return b.onPostProcess.dispatch(b,c,a)});b.onPreInit.dispatch(b);if(!h.gecko_spellcheck)b.getBody().spellcheck=0;h.readonly||b._addEvents();b.controlManager.onPostRender.dispatch(b,b.controlManager);b.onPostRender.dispatch(b);if(h.directionality)b.getBody().dir=h.directionality;if(h.nowrap)b.getBody().style.whiteSpace="nowrap";h.handle_node_change_callback&&b.onNodeChange.add(function(a,c,d){b.execCallback("handle_node_change_callback",
+b.id,d,-1,-1,!0,b.selection.isCollapsed())});h.save_callback&&b.onSaveContent.add(function(a,c){var d=b.execCallback("save_callback",b.id,c.content,b.getBody());if(d)c.content=d});h.onchange_callback&&b.onChange.add(function(a,c){b.execCallback("onchange_callback",b,c)});h.protect&&b.onBeforeSetContent.add(function(b,c){h.protect&&a(h.protect,function(a){c.content=c.content.replace(a,function(a){return"<\!--mce:protected "+escape(a)+"--\>"})})});h.convert_newlines_to_brs&&b.onBeforeSetContent.add(function(a,
+b){if(b.initial)b.content=b.content.replace(/\r?\n/g,"<br />")});h.preformatted&&b.onPostProcess.add(function(a,b){b.content=b.content.replace(/^\s*<pre.*?>/,"");b.content=b.content.replace(/<\/pre>\s*$/,"");if(b.set)b.content='<pre class="mceItemHidden">'+b.content+"</pre>"});if(h.verify_css_classes)b.serializer.attribValueFilter=function(c,d){var h,f;if(c=="class"){if(!b.classesRE&&(f=b.dom.getClasses(),f.length>0))h="",a(f,function(a){h+=(h?"|":"")+a["class"]}),b.classesRE=RegExp("("+h+")","gi");
+return!b.classesRE||/(\bmceItem\w+\b|\bmceTemp\w+\b)/g.test(d)||b.classesRE.test(d)?d:""}return d};h.cleanup_callback&&(b.onBeforeSetContent.add(function(a,c){c.content=b.execCallback("cleanup_callback","insert_to_editor",c.content,c)}),b.onPreProcess.add(function(a,c){c.set&&b.execCallback("cleanup_callback","insert_to_editor_dom",c.node,c);c.get&&b.execCallback("cleanup_callback","get_from_editor_dom",c.node,c)}),b.onPostProcess.add(function(a,c){if(c.set)c.content=b.execCallback("cleanup_callback",
+"insert_to_editor",c.content,c);if(c.get)c.content=b.execCallback("cleanup_callback","get_from_editor",c.content,c)}));h.save_callback&&b.onGetContent.add(function(a,c){if(c.save)c.content=b.execCallback("save_callback",b.id,c.content,b.getBody())});h.handle_event_callback&&b.onEvent.add(function(a,c,d){b.execCallback("handle_event_callback",c,a,d)===!1&&j.cancel(c)});b.onSetContent.add(function(){b.addVisual(b.getBody())});h.padd_empty_editor&&b.onPostProcess.add(function(a,b){b.content=b.content.replace(/^(<p[^>]*>(&nbsp;|&#160;|\s|\u00a0|)<\/p>[\r\n]*|<br \/>[\r\n]*)$/,
+"")});if(f){var m=function(b){a(b.dom.select("a"),function(a){var c=a.parentNode;b.dom.isBlock(c)&&c.lastChild===a&&b.dom.add(c,"br",{"data-mce-bogus":1})})};b.onExecCommand.add(function(a,b){b==="CreateLink"&&m(a)});b.onSetContent.add(b.selection.onSetContent.add(m));if(!h.readonly)try{g.designMode="Off",g.designMode="On"}catch(n){}}setTimeout(function(){if(!b.removed)b.load({initial:!0,format:"html"}),b.startContent=b.getContent({format:"raw"}),b.undoManager.add(),b.initialized=!0,b.onInit.dispatch(b),
+b.execCallback("setupcontent_callback",b.id,b.getBody(),b.getDoc()),b.execCallback("init_instance_callback",b),b.focus(!0),b.nodeChanged({initial:1}),a(b.contentCSS,function(a){b.dom.loadCSS(a)}),h.auto_focus&&setTimeout(function(){var a=c.get(h.auto_focus);a.selection.select(a.getBody(),1);a.selection.collapse(1);a.getWin().focus()},100)},1)},focus:function(a){var b,d=this.settings.content_editable,f,g=this.getDoc();a||(a=this.selection.getRng(),a.item&&(f=a.item(0)),d||this.getWin().focus(),f&&
+f.ownerDocument==g&&(a=g.body.createControlRange(),a.addElement(f),a.select()));if(c.activeEditor!=this)(b=c.activeEditor)!=null&&b.onDeactivate.dispatch(b,this),this.onActivate.dispatch(this,b);c._setActive(this)},execCallback:function(a){var b=this.settings[a],d;if(b){if(this.callbackLookup&&(d=this.callbackLookup[a]))b=d.func,d=d.scope;if(n(b,"string"))d=(d=b.replace(/\.\w+$/,""))?c.resolve(d):0,b=c.resolve(b),this.callbackLookup=this.callbackLookup||{},this.callbackLookup[a]={func:b,scope:d};
+return b.apply(d||this,Array.prototype.slice.call(arguments,1))}},translate:function(a){var b=this.settings.language||"en",d=c.i18n;if(!a)return"";return d[b+"."+a]||a.replace(/{\#([^}]+)\}/g,function(a,c){return d[b+"."+c]||"{#"+c+"}"})},getLang:function(a,b){return c.i18n[(this.settings.language||"en")+"."+a]||(n(b)?b:"{#"+a+"}")},getParam:function(b,d,f){var g=c.trim,b=n(this.settings[b])?this.settings[b]:d,i;if(f==="hash")return i={},n(b,"string")?a(b.indexOf("=")>0?b.split(/[;,](?![^=;,]*(?:[;,]|$))/):
+b.split(","),function(a){a=a.split("=");a.length>1?i[g(a[0])]=g(a[1]):i[g(a[0])]=g(a)}):i=b,i;return b},nodeChanged:function(a){var b=this.selection,c=b.getStart()||this.getBody();if(this.initialized)a=a||{},c=d&&c.ownerDocument!=this.getDoc()?this.getBody():c,a.parents=[],this.dom.getParent(c,function(b){if(b.nodeName=="BODY")return!0;a.parents.push(b)}),this.onNodeChange.dispatch(this,a?a.controlManager||this.controlManager:this.controlManager,c,b.isCollapsed(),a)},addButton:function(a,b){this.buttons=
+this.buttons||{};this.buttons[a]=b},addCommand:function(a,b,c){this.execCommands[a]={func:b,scope:c||this}},addQueryStateHandler:function(a,b,c){this.queryStateCommands[a]={func:b,scope:c||this}},addQueryValueHandler:function(a,b,c){this.queryValueCommands[a]={func:b,scope:c||this}},addShortcut:function(b,c,d,f){var g=this,i;if(!g.settings.custom_shortcuts)return!1;g.shortcuts=g.shortcuts||{};n(d,"string")&&(i=d,d=function(){g.execCommand(i,!1,null)});n(d,"object")&&(i=d,d=function(){g.execCommand(i[0],
+i[1],i[2])});a(o(b),function(b){var e={func:d,scope:f||this,desc:c,alt:!1,ctrl:!1,shift:!1};a(o(b,"+"),function(a){switch(a){case "alt":case "ctrl":case "shift":e[a]=!0;break;default:e.charCode=a.charCodeAt(0),e.keyCode=a.toUpperCase().charCodeAt(0)}});g.shortcuts[(e.ctrl?"ctrl":"")+","+(e.alt?"alt":"")+","+(e.shift?"shift":"")+","+e.keyCode]=e});return!0},execCommand:function(b,c,d,f){var g=this,i=0,j;!/^(mceAddUndoLevel|mceEndUndoLevel|mceBeginUndoLevel|mceRepaint|SelectAll)$/.test(b)&&(!f||!f.skip_focus)&&
+g.focus();j={};g.onBeforeExecCommand.dispatch(g,b,c,d,j);if(j.terminate)return!1;if(g.execCallback("execcommand_callback",g.id,g.selection.getNode(),b,c,d))return g.onExecCommand.dispatch(g,b,c,d,f),!0;if(j=g.execCommands[b])if(j=j.func.call(j.scope,c,d),j!==!0)return g.onExecCommand.dispatch(g,b,c,d,f),j;a(g.plugins,function(a){if(a.execCommand&&a.execCommand(b,c,d))return g.onExecCommand.dispatch(g,b,c,d,f),i=1,!1});if(i)return!0;if(g.theme&&g.theme.execCommand&&g.theme.execCommand(b,c,d))return g.onExecCommand.dispatch(g,
+b,c,d,f),!0;if(g.editorCommands.execCommand(b,c,d))return g.onExecCommand.dispatch(g,b,c,d,f),!0;g.getDoc().execCommand(b,c,d);g.onExecCommand.dispatch(g,b,c,d,f)},queryCommandState:function(a){var b;if(!this._isHidden()){if(b=this.queryStateCommands[a])if(b=b.func.call(b.scope),b!==!0)return b;b=this.editorCommands.queryCommandState(a);if(b!==-1)return b;try{return this.getDoc().queryCommandState(a)}catch(c){}}},queryCommandValue:function(a){var b;if(!this._isHidden()){if(b=this.queryValueCommands[a])if(b=
+b.func.call(b.scope),b!==!0)return b;b=this.editorCommands.queryCommandValue(a);if(n(b))return b;try{return this.getDoc().queryCommandValue(a)}catch(c){}}},show:function(){i.show(this.getContainer());i.hide(this.id);this.load()},hide:function(){var a=this.getDoc();d&&a&&a.execCommand("SelectAll");this.save();i.hide(this.getContainer());i.setStyle(this.id,"display",this.orgDisplay)},isHidden:function(){return!i.isHidden(this.id)},setProgressState:function(a,b,c){this.onSetProgressState.dispatch(this,
+a,b,c);return a},load:function(a){var b=this.getElement(),c;if(b)return a=a||{},a.load=!0,c=this.setContent(n(b.value)?b.value:b.innerHTML,a),a.element=b,a.no_events||this.onLoadContent.dispatch(this,a),a.element=null,c},save:function(b){var c=this,d=c.getElement(),f,g;if(d&&c.initialized){b=b||{};b.save=!0;if(!b.no_events)c.undoManager.typing=!1,c.undoManager.add();b.element=d;f=b.content=c.getContent(b);b.no_events||c.onSaveContent.dispatch(c,b);f=b.content;/TEXTAREA|INPUT/i.test(d.nodeName)?d.value=
+f:(d.innerHTML=f,(g=i.getParent(c.id,"form"))&&a(g.elements,function(a){if(a.name==c.id)return a.value=f,!1}));b.element=d=null;return f}},setContent:function(a,b){var d=this.getBody(),b=b||{};b.format=b.format||"html";b.set=!0;b.content=a;b.no_events||this.onBeforeSetContent.dispatch(this,b);a=b.content;if(!c.isIE&&(a.length===0||/^\s+$/.test(a)))d.innerHTML='<br data-mce-bogus="1" />';else return b.format!=="raw"&&(a=(new c.html.Serializer({},this.schema)).serialize(this.parser.parse(a))),b.content=
+c.trim(a),this.dom.setHTML(d,b.content),b.no_events||this.onSetContent.dispatch(this,b),b.content},getContent:function(a){var b,a=a||{};a.format=a.format||"html";a.get=!0;a.no_events||this.onBeforeGetContent.dispatch(this,a);b=a.format=="raw"?this.getBody().innerHTML:this.serializer.serialize(this.getBody(),a);a.content=c.trim(b);a.no_events||this.onGetContent.dispatch(this,a);return a.content},isDirty:function(){return c.trim(this.startContent)!=c.trim(this.getContent({format:"raw",no_events:1}))&&
+!this.isNotDirty},getContainer:function(){if(!this.container)this.container=i.get(this.editorContainer||this.id+"_parent");return this.container},getContentAreaContainer:function(){return this.contentAreaContainer},getElement:function(){return i.get(this.settings.content_element||this.id)},getWin:function(){var a;if(!this.contentWindow&&(a=i.get(this.id+"_ifr")))this.contentWindow=a.contentWindow;return this.contentWindow},getDoc:function(){var a;if(!this.contentDocument&&(a=this.getWin()))this.contentDocument=
+a.document;return this.contentDocument},getBody:function(){return this.bodyElement||this.getDoc().body},convertURL:function(a,b,c){var d=this.settings;if(d.urlconverter_callback)return this.execCallback("urlconverter_callback",a,c,!0,b);if(!d.convert_urls||c&&c.nodeName=="LINK"||a.indexOf("file:")===0)return a;if(d.relative_urls)return this.documentBaseURI.toRelative(a);return a=this.documentBaseURI.toAbsolute(a,d.remove_script_host)},addVisual:function(b){var c=this,d=c.settings,b=b||c.getBody();
+if(!n(c.hasVisual))c.hasVisual=d.visual;a(c.dom.select("table,a",b),function(a){var b;switch(a.nodeName){case "TABLE":b=c.dom.getAttrib(a,"border");if(!b||b=="0")c.hasVisual?c.dom.addClass(a,d.visual_table_class):c.dom.removeClass(a,d.visual_table_class);break;case "A":(b=c.dom.getAttrib(a,"name"))&&(c.hasVisual?c.dom.addClass(a,"mceItemAnchor"):c.dom.removeClass(a,"mceItemAnchor"))}});c.onVisualAid.dispatch(c,b,c.hasVisual)},remove:function(){var a=this.getContainer();this.removed=1;this.hide();
+this.execCallback("remove_instance_callback",this);this.onRemove.dispatch(this);this.onExecCommand.listeners=[];c.remove(this);i.remove(a)},destroy:function(a){if(!this.destroyed){a||(c.removeUnload(this.destroy),tinyMCE.onBeforeUnload.remove(this._beforeUnload),this.theme&&this.theme.destroy&&this.theme.destroy(),this.controlManager.destroy(),this.selection.destroy(),this.dom.destroy(),this.settings.content_editable||(j.clear(this.getWin()),j.clear(this.getDoc())),j.clear(this.getBody()),j.clear(this.formElement));
+if(this.formElement)this.formElement.submit=this.formElement._mceOldSubmit,this.formElement._mceOldSubmit=null;this.contentAreaContainer=this.formElement=this.container=this.settings.content_element=this.bodyElement=this.contentDocument=this.contentWindow=null;if(this.selection)this.selection=this.selection.win=this.selection.dom=this.selection.dom.doc=null;this.destroyed=1}},_addEvents:function(){function b(a,c){h.removed||h.onEvent.dispatch(h,a,c)!==!1&&h[m[a.fakeType||a.type]].dispatch(h,a,c)}
+var h=this,g,k=h.settings,l=h.dom,m={mouseup:"onMouseUp",mousedown:"onMouseDown",click:"onClick",keyup:"onKeyUp",keydown:"onKeyDown",keypress:"onKeyPress",submit:"onSubmit",reset:"onReset",contextmenu:"onContextMenu",dblclick:"onDblClick",paste:"onPaste"};a(m,function(a,c){switch(c){case "contextmenu":l.bind(h.getDoc(),c,b);break;case "paste":l.bind(h.getBody(),c,function(a){b(a)});break;case "submit":case "reset":l.bind(h.getElement().form||i.getParent(h.id,"form"),c,b);break;default:l.bind(k.content_editable?
+h.getBody():h.getDoc(),c,b)}});l.bind(k.content_editable?h.getBody():f?h.getDoc():h.getWin(),"focus",function(){h.focus(!0)});c.isGecko&&l.bind(h.getDoc(),"DOMNodeInserted",function(a){var b,a=a.target;if(a.nodeType===1&&a.nodeName==="IMG"&&(b=a.getAttribute("data-mce-src")))a.src=h.documentBaseURI.toAbsolute(b)});f&&(g=function(){var a=this.getDoc(),b=this.settings;if(f&&!b.readonly){if(this._isHidden())try{if(!b.content_editable)a.designMode="On"}catch(c){}try{a.execCommand("styleWithCSS",0,!1)}catch(d){if(!this._isHidden())try{a.execCommand("useCSS",
+0,!0)}catch(e){}}if(!b.table_inline_editing)try{a.execCommand("enableInlineTableEditing",!1,!1)}catch(h){}if(!b.object_resizing)try{a.execCommand("enableObjectResizing",!1,!1)}catch(g){}}},h.onBeforeExecCommand.add(g),h.onMouseDown.add(g));c.isWebKit&&h.onClick.add(function(a,b){b=b.target;if(b.nodeName=="IMG"||b.nodeName=="A"&&l.hasClass(b,"mceItemAnchor"))h.selection.getSel().setBaseAndExtent(b,0,b,1),h.nodeChanged()});h.onMouseUp.add(h.nodeChanged);h.onKeyUp.add(function(a,b){var d=b.keyCode;(d>=
+33&&d<=36||d>=37&&d<=40||d==13||d==45||d==46||d==8||c.isMac&&(d==91||d==93)||b.ctrlKey)&&h.nodeChanged()});h.onReset.add(function(){h.setContent(h.startContent,{format:"raw"})});if(k.custom_shortcuts){k.custom_undo_redo_keyboard_shortcuts&&(h.addShortcut("ctrl+z",h.getLang("undo_desc"),"Undo"),h.addShortcut("ctrl+y",h.getLang("redo_desc"),"Redo"));h.addShortcut("ctrl+b",h.getLang("bold_desc"),"Bold");h.addShortcut("ctrl+i",h.getLang("italic_desc"),"Italic");h.addShortcut("ctrl+u",h.getLang("underline_desc"),
+"Underline");for(g=1;g<=6;g++)h.addShortcut("ctrl+"+g,"",["FormatBlock",!1,"h"+g]);h.addShortcut("ctrl+7","",["FormatBlock",!1,"<p>"]);h.addShortcut("ctrl+8","",["FormatBlock",!1,"<div>"]);h.addShortcut("ctrl+9","",["FormatBlock",!1,"<address>"]);var n=function(b){var d=null;if(!b.altKey&&!b.ctrlKey&&!b.metaKey)return d;a(h.shortcuts,function(a){if(!(c.isMac&&a.ctrl!=b.metaKey)&&(c.isMac||a.ctrl==b.ctrlKey))if(a.alt==b.altKey&&a.shift==b.shiftKey&&(b.keyCode==a.keyCode||b.charCode&&b.charCode==a.charCode))return d=
+a,!1});return d};h.onKeyUp.add(function(a,b){if(n(b))return j.cancel(b)});h.onKeyPress.add(function(a,b){if(n(b))return j.cancel(b)});h.onKeyDown.add(function(a,b){var c=n(b);if(c)return c.func.call(c.scope),j.cancel(b)})}c.isIE&&(l.bind(h.getDoc(),"controlselect",function(a){var b=h.resizeInfo,a=a.target;if(a.nodeName==="IMG")b&&l.unbind(b.node,b.ev,b.cb),l.hasClass(a,"mceItemNoResize")?(ev="resizestart",b=l.bind(a,"resizestart",j.cancel,j)):(ev="resizeend",b=l.bind(a,ev,function(a){var b,a=a.target;
+if(b=l.getStyle(a,"width"))l.setAttrib(a,"width",b.replace(/[^0-9%]+/g,"")),l.setStyle(a,"width","");if(b=l.getStyle(a,"height"))l.setAttrib(a,"height",b.replace(/[^0-9%]+/g,"")),l.setStyle(a,"height","")})),b=h.resizeInfo={node:a,ev:ev,cb:b}}),h.onKeyDown.add(function(a,b){var c;switch(b.keyCode){case 8:if(c=h.getDoc().selection,c.createRange&&c.createRange().item)return a.dom.remove(c.createRange().item(0)),j.cancel(b)}}));c.isOpera&&h.onClick.add(function(a,b){j.prevent(b)});if(k.custom_undo_redo){var o=
+function(){h.undoManager.typing=!1;h.undoManager.add()};l.bind(h.getDoc(),"focusout",function(){!h.removed&&h.undoManager.typing&&o()});h.dom.bind(h.dom.getRoot(),"dragend",function(){o()});h.onKeyUp.add(function(a,b){var c,e;if(d&&b.keyCode==8&&(c=h.selection.getRng(),c.parentElement))c=c.parentElement(),e=h.selection.getBookmark(),c.innerHTML=c.innerHTML,h.selection.moveToBookmark(e);(b.keyCode>=33&&b.keyCode<=36||b.keyCode>=37&&b.keyCode<=40||b.keyCode==13||b.keyCode==45||b.ctrlKey)&&o()});h.onKeyDown.add(function(a,
+b){var e,f;f=b.keyCode;if(d&&f==46&&(e=h.selection.getRng(),e.parentElement)){f=e.parentElement();if(!h.undoManager.typing)h.undoManager.beforeChange(),h.undoManager.typing=!0,h.undoManager.add();b.ctrlKey&&(e.moveEnd("word",1),e.select());h.selection.getSel().clear();if(e.parentElement()==f){e=h.selection.getBookmark();try{f.innerHTML=f.innerHTML}catch(g){}h.selection.moveToBookmark(e)}b.preventDefault();return}if(f>=33&&f<=36||f>=37&&f<=40||f==13||f==45)c.isIE&&f==13&&h.undoManager.beforeChange(),
+h.undoManager.typing&&o();else if((f<16||f>20)&&f!=224&&f!=91&&!h.undoManager.typing)h.undoManager.beforeChange(),h.undoManager.add(),h.undoManager.typing=!0});h.onMouseDown.add(function(){h.undoManager.typing&&o()})}if(c.isGecko){var t=function(){var b=h.dom.getAttribs(h.selection.getStart().cloneNode(!1));return function(){var c=h.selection.getStart();h.dom.removeAllAttribs(c);a(b,function(a){c.setAttributeNode(a.cloneNode(!0))})}},y=function(){var a=h.selection;return!a.isCollapsed()&&a.getStart()!=
+a.getEnd()};h.onKeyPress.add(function(a,b){var c;if((b.keyCode==8||b.keyCode==46)&&y())return c=t(),h.getDoc().execCommand("delete",!1,null),c(),j.cancel(b)});h.dom.bind(h.getDoc(),"cut",function(){var a;y()&&(a=t(),h.onKeyUp.addToTop(j.cancel,j),setTimeout(function(){a();h.onKeyUp.remove(j.cancel,j)},0))})}},_isHidden:function(){var a;if(!f)return 0;a=this.selection.getSel();return!a||!a.rangeCount||a.rangeCount==0}})})(tinymce);
+(function(c){var i=c.each,j=!0,g=!1;c.EditorCommands=function(b){function a(a,b,c){var d,a=a.toLowerCase();if(d=e.exec[a])return d(a,b,c),j;return g}function f(a){var b,a=a.toLowerCase();if(b=e.state[a])return b(a);return-1}function d(a,b){b=b||"exec";i(a,function(a,c){i(c.toLowerCase().split(","),function(c){e[b][c]=a})})}function n(a,c,d){c===void 0&&(c=g);d===void 0&&(d=null);return b.getDoc().execCommand(a,c,d)}function k(a,c){b.formatter.toggle(a,c?{value:c}:void 0)}var m=b.dom,o=b.selection,
+e={state:{},exec:{},value:{}},h=b.settings,p;c.extend(this,{execCommand:a,queryCommandState:f,queryCommandValue:function(a){var b,a=a.toLowerCase();if(b=e.value[a])return b(a);return g},addCommands:d});d({"mceResetDesignMode,mceBeginUndoLevel":function(){},"mceEndUndoLevel,mceAddUndoLevel":function(){b.undoManager.add()},"Cut,Copy,Paste":function(a){var d=b.getDoc(),e;try{n(a)}catch(h){e=j}if(e||!d.queryCommandSupported(a))c.isGecko?b.windowManager.confirm(b.getLang("clipboard_msg"),function(a){a&&
+open("http://www.mozilla.org/editor/midasdemo/securityprefs.html","_blank")}):b.windowManager.alert(b.getLang("clipboard_no_support"))},unlink:function(a){o.isCollapsed()&&o.select(o.getNode());n(a);o.collapse(g)},"JustifyLeft,JustifyCenter,JustifyRight,JustifyFull":function(c){var d=c.substring(7);i("left,center,right,full".split(","),function(a){d!=a&&b.formatter.remove("align"+a)});k("align"+d);a("mceRepaint")},"InsertUnorderedList,InsertOrderedList":function(a){var b;n(a);if(a=m.getParent(o.getNode(),
+"ol,ul"))b=a.parentNode,/^(H[1-6]|P|ADDRESS|PRE)$/.test(b.nodeName)&&(p=o.getBookmark(void 0),m.split(b,a),o.moveToBookmark(p))},"Bold,Italic,Underline,Strikethrough,Superscript,Subscript":function(a){k(a)},"ForeColor,HiliteColor,FontName":function(a,b,c){k(a,c)},FontSize:function(a,b,d){var e;d>=1&&d<=7&&(e=c.explode(h.font_size_style_values),d=(b=c.explode(h.font_size_classes))?b[d-1]||d:e[d-1]||d);k(a,d)},RemoveFormat:function(a){b.formatter.remove(a)},mceBlockQuote:function(){k("blockquote")},
+FormatBlock:function(a,b,c){return k(c||"p")},mceCleanup:function(){var a=o.getBookmark();b.setContent(b.getContent({cleanup:j}),{cleanup:j});o.moveToBookmark(a)},mceRemoveNode:function(a,c,d){a=d||o.getNode();a!=b.getBody()&&(p=o.getBookmark(void 0),b.dom.remove(a,j),o.moveToBookmark(p))},mceSelectNodeDepth:function(a,c,d){var e=0;m.getParent(o.getNode(),function(a){if(a.nodeType==1&&e++==d)return o.select(a),g},b.getBody())},mceSelectNode:function(a,b,c){o.select(c)},mceInsertContent:function(a,
+d,e){function h(a,b,d){for(b=new c.dom.TreeWalker(d?a.nextSibling:a.previousSibling,b);a=b.current();){if(a.nodeType==3&&c.trim(a.nodeValue).length||a.nodeName=="BR"||a.nodeName=="IMG")return a;d?b.next():b.prev()}}var f,g,a={content:e,format:"html"};o.onBeforeSetContent.dispatch(o,a);e=a.content;e.indexOf("{$caret}")==-1&&(e+="{$caret}");o.setContent('<span id="__mce">\ufeff</span>',{no_events:!1});m.setOuterHTML("__mce",e.replace(/\{\$caret\}/,'<span data-mce-type="bookmark" id="__mce">\ufeff</span>'));
+d=m.select("#__mce")[0];g=m.getRoot();if(d.previousSibling&&m.isBlock(d.previousSibling)||d.parentNode==g)(e=h(d,g))&&(e.nodeName=="BR"?e.parentNode.insertBefore(d,e):m.insertAfter(d,e));for(;d;){if(d===g){m.setOuterHTML(f,(new c.html.Serializer({},b.schema)).serialize(b.parser.parse(m.getOuterHTML(f))));break}f=d;d=d.parentNode}if(d=m.select("#__mce")[0])if(e=h(d,g)||h(d,g,!0),m.remove(d),e){f=m.createRng();e.nodeType==3?(f.setStart(e,e.length),f.setEnd(e,e.length)):e.nodeName=="BR"?(f.setStartBefore(e),
+f.setEndBefore(e)):(f.setStartAfter(e),f.setEndAfter(e));o.setRng(f);if(!c.isIE){e=m.create("span",null,"\u00a0");f.insertNode(e);f=m.getRect(e);d=m.getViewPort(b.getWin());if(f.y>d.y+d.h||f.y<d.y||f.x>d.x+d.w||f.x<d.x)b.getBody().scrollLeft=f.x,b.getBody().scrollTop=f.y;m.remove(e)}o.collapse(!0)}o.onSetContent.dispatch(o,a);b.addVisual()},mceInsertRawHTML:function(a,c,d){o.setContent("tiny_mce_marker");b.setContent(b.getContent().replace(/tiny_mce_marker/g,function(){return d}))},mceSetContent:function(a,
+c,d){b.setContent(d)},"Indent,Outdent":function(a){var b,c,d;b=h.indentation;c=/[a-z%]+$/i.exec(b);b=parseInt(b);!f("InsertUnorderedList")&&!f("InsertOrderedList")?i(o.getSelectedBlocks(),function(e){a=="outdent"?(d=Math.max(0,parseInt(e.style.paddingLeft||0)-b),m.setStyle(e,"paddingLeft",d?d+c:"")):m.setStyle(e,"paddingLeft",parseInt(e.style.paddingLeft||0)+b+c)}):n(a)},mceRepaint:function(){if(c.isGecko)try{p=o.getBookmark(j),o.getSel()&&o.getSel().selectAllChildren(b.getBody()),o.collapse(j),o.moveToBookmark(p)}catch(a){}},
+mceToggleFormat:function(a,c,d){b.formatter.toggle(d)},InsertHorizontalRule:function(){b.execCommand("mceInsertContent",!1,"<hr />")},mceToggleVisualAid:function(){b.hasVisual=!b.hasVisual;b.addVisual()},mceReplaceContent:function(a,c,d){b.execCommand("mceInsertContent",!1,d.replace(/\{\$selection\}/g,o.getContent({format:"text"})))},mceInsertLink:function(a,d,e){var a=m.getParent(o.getNode(),"a"),h,f;c.is(e,"string")&&(e={href:e});e.href=e.href.replace(" ","%20");if(a)e.href?m.setAttribs(a,e):b.dom.remove(a,
+j);else{if(c.isWebKit&&(h=m.getParent(o.getNode(),"img")))f=h.style.cssFloat,h.style.cssFloat=null;n("CreateLink",g,"javascript:mctmp(0);");if(f)h.style.cssFloat=f;i(m.select("a[href='javascript:mctmp(0);']"),function(a){m.setAttribs(a,e)})}},selectAll:function(){var a=m.getRoot(),c=m.createRng();c.setStart(a,0);c.setEnd(a,a.childNodes.length);b.selection.setRng(c)}});d({"JustifyLeft,JustifyCenter,JustifyRight,JustifyFull":function(a){a="align"+a.substring(7);return b.formatter.match(a)},"Bold,Italic,Underline,Strikethrough,Superscript,Subscript":function(a){return b.formatter.match(a)},
+mceBlockQuote:function(){return b.formatter.match("blockquote")},Outdent:function(){var a;if(h.inline_styles){if((a=m.getParent(o.getStart(),m.isBlock))&&parseInt(a.style.paddingLeft)>0)return j;if((a=m.getParent(o.getEnd(),m.isBlock))&&parseInt(a.style.paddingLeft)>0)return j}return f("InsertUnorderedList")||f("InsertOrderedList")||!h.inline_styles&&!!m.getParent(o.getNode(),"BLOCKQUOTE")},"InsertUnorderedList,InsertOrderedList":function(a){return m.getParent(o.getNode(),a=="insertunorderedlist"?
+"UL":"OL")}},"state");d({"FontSize,FontName":function(a){var b=0,c;if(c=m.getParent(o.getNode(),"span"))b=a=="fontsize"?c.style.fontSize:c.style.fontFamily.replace(/, /g,",").replace(/[\'\"]/g,"").toLowerCase();return b}},"value");h.custom_undo_redo&&d({Undo:function(){b.undoManager.undo()},Redo:function(){b.undoManager.redo()}})}})(tinymce);
+(function(c){var i=c.util.Dispatcher;c.UndoManager=function(j){var g,b=0,a=[];return g={typing:!1,onAdd:new i(g),onUndo:new i(g),onRedo:new i(g),beforeChange:function(){if(a[b])a[b].beforeBookmark=j.selection.getBookmark(2,!0)},add:function(f){var d;d=j.settings;var i,f=f||{};f.content=c.trim(j.getContent({format:"raw",no_events:1}));if((i=a[b])&&i.content==f.content)return null;if(d.custom_undo_redo_levels&&a.length>d.custom_undo_redo_levels){for(d=0;d<a.length-1;d++)a[d]=a[d+1];a.length--;b=a.length}f.bookmark=
+j.selection.getBookmark(2,!0);if(b<a.length-1)a.length=b+1;a.push(f);b=a.length-1;g.onAdd.dispatch(g,f);j.isNotDirty=0;return f},undo:function(){var c;if(g.typing)g.add(),g.typing=!1;b>0&&(c=a[--b],j.setContent(c.content,{format:"raw"}),j.selection.moveToBookmark(c.beforeBookmark),g.onUndo.dispatch(g,c));return c},redo:function(){var c;b<a.length-1&&(c=a[++b],j.setContent(c.content,{format:"raw"}),j.selection.moveToBookmark(c.bookmark),g.onRedo.dispatch(g,c));return c},clear:function(){a=[];b=0;g.typing=
+!1},hasUndo:function(){return b>0||this.typing},hasRedo:function(){return b<a.length-1&&!this.typing}}}})(tinymce);
+(function(c){function i(a,b){var c=b.ownerDocument.createRange();c.setStart(a.endContainer,a.endOffset);c.setEndAfter(b);return c.cloneContents().textContent.length==0}function j(a,b,c){var e;if(b.isEmpty(c))return e=b.getParent(c,"ul,ol"),b.getParent(e.parentNode,"ul,ol")||(b.split(e,c),e=b.create("p",0,'<br data-mce-bogus="1" />'),b.replace(e,c),a.select(e,1)),n;return d}var g=c.dom.Event,b=c.isIE,a=c.isGecko,f=c.isOpera,d=!0,n=!1;c.create("tinymce.ForceBlocks",{ForceBlocks:function(a){var b=this,
+c=a.settings,d;b.editor=a;b.dom=a.dom;d=(c.forced_root_block||"p").toLowerCase();c.element=d.toUpperCase();a.onPreInit.add(b.setup,b);c.forced_root_block&&(a.onInit.add(b.forceRoots,b),a.onSetContent.add(b.forceRoots,b),a.onBeforeGetContent.add(b.forceRoots,b),a.onExecCommand.add(function(a,c){c=="mceInsertContent"&&(b.forceRoots(),a.nodeChanged())}))},setup:function(){var f=this,i=f.editor,j=i.settings,e=i.dom,h=i.selection;j.forced_root_block&&(i.onBeforeExecCommand.add(f.forceRoots,f),i.onKeyUp.add(f.forceRoots,
+f),i.onPreProcess.add(f.forceRoots,f));j.force_br_newlines&&b&&i.onKeyPress.add(function(a,b){var c;if(b.keyCode==13&&h.getNode().nodeName!="LI")return h.setContent('<br id="__" /> ',{format:"raw"}),c=e.get("__"),c.removeAttribute("id"),h.select(c),h.collapse(),g.cancel(b)});j.force_p_newlines&&(b?(c.addUnload(function(){f._previousFormats=0}),i.onKeyPress.add(function(a,b){f._previousFormats=0;if(b.keyCode==13&&!b.shiftKey&&a.selection.isCollapsed()&&j.keep_styles){var c;var d=a.selection.getStart(),
+e,h,g;do/^(SPAN|STRONG|B|EM|I|FONT|STRIKE|U)$/.test(d.nodeName)&&(e?(h=d.cloneNode(!1),h.appendChild(e),e=h):e=g=d.cloneNode(!1),e.removeAttribute("id"));while(d=d.parentNode);e&&(c={wrapper:e,inner:g});f._previousFormats=c}}),i.onKeyUp.add(function(a,b){if(b.keyCode==13&&!b.shiftKey){var c=a.selection.getStart(),d=f._previousFormats;if(!c.hasChildNodes()&&d&&(c=e.getParent(c,e.isBlock))&&c.nodeName!="LI")c.innerHTML="",f._previousFormats?(c.appendChild(d.wrapper),d.inner.innerHTML="\ufeff"):c.innerHTML=
+"\ufeff",h.select(c,1),h.collapse(!0),a.getDoc().execCommand("Delete",!1,null),f._previousFormats=0}})):i.onKeyPress.add(function(a,b){b.keyCode==13&&!b.shiftKey&&!f.insertPara(b)&&g.cancel(b)}),a&&i.onKeyDown.add(function(a,b){(b.keyCode==8||b.keyCode==46)&&!b.shiftKey&&f.backspaceDelete(b,b.keyCode==8)}));c.isWebKit&&i.onKeyPress.add(function(a,b){if(b.keyCode==13&&(b.shiftKey||j.force_br_newlines&&!e.getParent(h.getNode(),"h1,h2,h3,h4,h5,h6,ol,ul"))){var c=h.getRng(),f,i=e.create("div",null," "),
+k=e.getViewPort(a.getWin()).h;c.insertNode(f=e.create("br"));c.setStartAfter(f);c.setEndAfter(f);h.setRng(c);h.getSel().focusNode==f.previousSibling&&(h.select(e.insertAfter(e.doc.createTextNode("\u00a0"),f)),h.collapse(d));e.insertAfter(i,f);c=e.getPos(i).y;e.remove(i);c>k&&a.getWin().scrollTo(0,c);g.cancel(b)}});b&&j.element!="P"&&(i.onKeyPress.add(function(){f.lastElm=h.getNode().nodeName}),i.onKeyUp.add(function(a,b){var c;c=h.getNode();if(a.getBody().childNodes.length===1&&c.nodeName=="P")c=
+e.rename(c,j.element),h.select(c),h.collapse(),a.nodeChanged();else if(b.keyCode==13&&!b.shiftKey&&f.lastElm!="P"&&(c=e.getParent(c,"p")))e.rename(c,j.element),a.nodeChanged()}))},find:function(a,b,c){for(var d=this.editor.getDoc().createTreeWalker(a,4,null,n),f=-1;a=d.nextNode();){f++;if(b==0&&a==c)return f;if(b==1&&f==c)return a}return-1},forceRoots:function(a){var a=this.editor,c=a.getBody(),d=a.getDoc(),e=a.selection,f=e.getSel(),g=e.getRng(),i=-2,j,n,B,r,t,y=c.childNodes,z,x,v;for(z=y.length-
+1;z>=0;z--)if(t=y[z],t.nodeType===1&&t.getAttribute("data-mce-type"))r=null;else if(t.nodeType===3||!this.dom.isBlock(t)&&t.nodeType!==8&&!/^(script|mce:script|style|mce:style)$/i.test(t.nodeName))if(r)r.hasChildNodes()?r.insertBefore(t,r.firstChild):r.appendChild(t);else{if(t.nodeType!=3||/[^\s]/g.test(t.nodeValue)){if(i==-2&&g)if(!b||g.setStart)if(g.startContainer.nodeType==1&&(x=g.startContainer.childNodes[g.startOffset])&&x.nodeType==1)v=x.getAttribute("id"),x.setAttribute("id","__mce");else{if(a.dom.getParent(g.startContainer,
+function(a){return a===c}))n=g.startOffset,B=g.endOffset,i=this.find(c,0,g.startContainer),j=this.find(c,0,g.endContainer)}else g.item&&(r=d.body.createTextRange(),r.moveToElementText(g.item(0)),g=r),r=d.body.createTextRange(),r.moveToElementText(c),r.collapse(1),i=r.move("character",-16777215)*-1,r=g.duplicate(),r.collapse(1),j=r.move("character",-16777215)*-1,r=g.duplicate(),r.collapse(0),r=r.move("character",-16777215)*-1-j,i=j-i,j=r;r=a.dom.create(a.settings.forced_root_block);t.parentNode.replaceChild(r,
+t);r.appendChild(t)}}else r=null;if(i!=-2)if(!b||g.setStart)r=c.getElementsByTagName(a.settings.element)[0],g=d.createRange(),i!=-1?g.setStart(this.find(c,1,i),n):g.setStart(r,0),j!=-1?g.setEnd(this.find(c,1,j),B):g.setEnd(r,0),f&&(f.removeAllRanges(),f.addRange(g));else try{g=f.createRange(),g.moveToElementText(c),g.collapse(1),g.moveStart("character",i),g.moveEnd("character",j),g.select()}catch(q){}else if((!b||g.setStart)&&(x=a.dom.get("__mce")))v?x.setAttribute("id",v):x.removeAttribute("id"),
+g=d.createRange(),g.setStartBefore(x),g.setEndBefore(x),e.setRng(g)},getParentBlock:function(a){var b=this.dom;return b.getParent(a,b.isBlock)},insertPara:function(){var k;function b(a,c){var d=[],e,i;a.innerHTML="";if(h.keep_styles){i=c;do/^(SPAN|STRONG|B|EM|I|FONT|STRIKE|U)$/.test(i.nodeName)&&(e=i.cloneNode(n),g.setAttrib(e,"id",""),d.push(e));while(i=i.parentNode)}if(d.length>0){i=d.length-1;for(e=a;i>=0;i--)e=e.appendChild(d[i]);d[0].innerHTML=f?"\u00a0":"<br />";return d[0]}else a.innerHTML=
+f?"\u00a0":"<br />"}var c=this.editor,g=c.dom,e=c.getDoc(),h=c.settings,p=c.selection.getSel(),u=p.getRangeAt(0),l=e.body,s,B,r,t,y,z,x,v,q,A,D,C,H=g.getViewPort(c.getWin()),F;c.undoManager.beforeChange();s=e.createRange();s.setStart(p.anchorNode,p.anchorOffset);s.collapse(d);B=e.createRange();B.setStart(p.focusNode,p.focusOffset);B.collapse(d);t=(r=s.compareBoundaryPoints(s.START_TO_END,B)<0)?p.anchorNode:p.focusNode;y=r?p.anchorOffset:p.focusOffset;z=r?p.focusNode:p.anchorNode;r=r?p.focusOffset:
+p.anchorOffset;if(t===z&&/^(TD|TH)$/.test(t.nodeName))return t.firstChild.nodeName=="BR"&&g.remove(t.firstChild),t.childNodes.length==0?c.dom.add(t,h.element,null,"<br />"):(C=t.innerHTML,t.innerHTML="",c.dom.add(t,h.element,null,C)),v=c.dom.add(t,h.element,null,"<br />"),u=e.createRange(),u.selectNodeContents(v),u.collapse(1),c.selection.setRng(u),n;if(t==l&&z==l&&l.firstChild&&c.dom.isBlock(l.firstChild))k=z=t.firstChild,t=k,y=r=0,s=e.createRange(),s.setStart(t,0),B=e.createRange(),B.setStart(z,
+0);t=t.nodeName=="HTML"?e.body:t;t=t.nodeName=="BODY"?t.firstChild:t;z=z.nodeName=="HTML"?e.body:z;z=z.nodeName=="BODY"?z.firstChild:z;x=this.getParentBlock(t);v=this.getParentBlock(z);q=x?x.nodeName:h.element;if(C=this.dom.getParent(x,"li,pre")){if(C.nodeName=="LI")return j(c.selection,this.dom,C);return d}if(x&&(x.nodeName=="CAPTION"||/absolute|relative|fixed/gi.test(g.getStyle(x,"position",1))))q=h.element,x=null;if(v&&(v.nodeName=="CAPTION"||/absolute|relative|fixed/gi.test(g.getStyle(x,"position",
+1))))q=h.element,v=null;if(/(TD|TABLE|TH|CAPTION)/.test(q)||x&&q=="DIV"&&/left|right/gi.test(g.getStyle(x,"float",1)))q=h.element,x=v=null;A=x&&x.nodeName==q?x.cloneNode(0):c.dom.create(q);v=v&&v.nodeName==q?v.cloneNode(0):c.dom.create(q);v.removeAttribute("id");/^(H[1-6])$/.test(q)&&i(u,x)&&(v=c.dom.create(h.element));C=x=t;do{if(C==l||C.nodeType==9||this.dom.isBlock(C)||/(TD|TABLE|TH|CAPTION)/.test(C.nodeName))break;x=C}while(C=C.previousSibling?C.previousSibling:C.parentNode);C=D=z;do{if(C==l||
+C.nodeType==9||this.dom.isBlock(C)||/(TD|TABLE|TH|CAPTION)/.test(C.nodeName))break;D=C}while(C=C.nextSibling?C.nextSibling:C.parentNode);x.nodeName==q?s.setStart(x,0):s.setStartBefore(x);s.setEnd(t,y);A.appendChild(s.cloneContents()||e.createTextNode(""));try{B.setEndAfter(D)}catch(K){}B.setStart(z,r);v.appendChild(B.cloneContents()||e.createTextNode(""));u=e.createRange();!x.previousSibling&&x.parentNode.nodeName==q?u.setStartBefore(x.parentNode):s.startContainer.nodeName==q&&s.startOffset==0?u.setStartBefore(s.startContainer):
+u.setStart(s.startContainer,s.startOffset);!D.nextSibling&&D.parentNode.nodeName==q?u.setEndAfter(D.parentNode):u.setEnd(B.endContainer,B.endOffset);u.deleteContents();f&&c.getWin().scrollTo(0,H.y);if(A.firstChild&&A.firstChild.nodeName==q)A.innerHTML=A.firstChild.innerHTML;if(v.firstChild&&v.firstChild.nodeName==q)v.innerHTML=v.firstChild.innerHTML;if(g.isEmpty(A))A.innerHTML="<br />";g.isEmpty(v)&&(F=b(v,z));f&&parseFloat(opera.version())<9.5?(u.insertNode(A),u.insertNode(v)):(u.insertNode(v),u.insertNode(A));
+v.normalize();A.normalize();u=e.createRange();u.selectNodeContents(a?e.createTreeWalker(F||v,NodeFilter.SHOW_TEXT,null,n).nextNode()||F||v:F||v);u.collapse(1);p.removeAllRanges();p.addRange(u);e=c.dom.getPos(v).y;if(e<H.y||e+25>H.y+H.h)c.getWin().scrollTo(0,e<H.y?e:e-H.h+25);c.undoManager.add();return n},backspaceDelete:function(a,b){var d=this.editor,e=d.getBody(),f,i=d.selection,j=i.getRng(),l=j.startContainer,s;if(!b&&j.collapsed&&l.nodeType==1&&j.startOffset==l.childNodes.length){s=new c.dom.TreeWalker(l.lastChild,
+l);for(f=l.lastChild;f;f=s.prev())if(f.nodeType==3){j.setStart(f,f.nodeValue.length);j.collapse(!0);i.setRng(j);return}}if(l&&d.dom.isBlock(l)&&!/^(TD|TH)$/.test(l.nodeName)&&b&&(l.childNodes.length==0||l.childNodes.length==1&&l.firstChild.nodeName=="BR")){for(f=l;(f=f.previousSibling)&&!d.dom.isBlock(f););if(f){if(l!=e.firstChild){for(e=d.dom.doc.createTreeWalker(f,NodeFilter.SHOW_TEXT,null,n);j=e.nextNode();)f=j;j=d.getDoc().createRange();j.setStart(f,f.nodeValue?f.nodeValue.length:0);j.setEnd(f,
+f.nodeValue?f.nodeValue.length:0);i.setRng(j);d.dom.remove(l)}return g.cancel(a)}}}})})(tinymce);
+(function(c){var i=c.dom.Event,j=c.each,g=c.extend;c.create("tinymce.ControlManager",{ControlManager:function(b,a){var f=this,a=a||{};f.editor=b;f.controls={};f.onAdd=new c.util.Dispatcher(f);f.onPostRender=new c.util.Dispatcher(f);f.prefix=a.prefix||b.id+"_";f._cls={};f.onPostRender.add(function(){j(f.controls,function(a){a.postRender()})})},get:function(b){return this.controls[this.prefix+b]||this.controls[b]},setActive:function(b,a){var c=null;(c=this.get(b))&&c.setActive(a);return c},setDisabled:function(b,
+a){var c=null;(c=this.get(b))&&c.setDisabled(a);return c},add:function(b){b&&(this.controls[b.id]=b,this.onAdd.dispatch(b,this));return b},createControl:function(b){var a,c=this,d=c.editor;j(d.plugins,function(d){if(d.createControl&&(a=d.createControl(b,c)))return!1});switch(b){case "|":case "separator":return c.createSeparator()}if(!a&&d.buttons&&(a=d.buttons[b]))return c.createButton(b,a);return c.add(a)},createDropMenu:function(b,a,f){var d=this.editor,i,j,m,a=g({"class":"mceDropDown",constrain:d.settings.constrain_menus},
+a);a["class"]=a["class"]+" "+d.getParam("skin")+"Skin";if(m=d.getParam("skin_variant"))a["class"]+=" "+d.getParam("skin")+"Skin"+m.substring(0,1).toUpperCase()+m.substring(1);b=this.prefix+b;i=this.controls[b]=new (f||this._cls.dropmenu||c.ui.DropMenu)(b,a);i.onAddItem.add(function(a,b){var c=b.settings;c.title=d.getLang(c.title,c.title);if(!c.onclick)c.onclick=function(){c.cmd&&d.execCommand(c.cmd,c.ui||!1,c.value)}});d.onRemove.add(function(){i.destroy()});c.isIE&&(i.onShowMenu.add(function(){d.focus();
+j=d.selection.getBookmark(1)}),i.onHideMenu.add(function(){j&&(d.selection.moveToBookmark(j),j=0)}));return this.add(i)},createListBox:function(b,a,f){var d=this.editor;if(this.get(b))return null;a.title=d.translate(a.title);a.scope=a.scope||d;if(!a.onselect)a.onselect=function(b){d.execCommand(a.cmd,a.ui||!1,b||a.value)};a=g({title:a.title,"class":"mce_"+b,scope:a.scope,control_manager:this},a);b=this.prefix+b;d.settings.use_native_selects?f=new c.ui.NativeListBox(b,a):(f=f||this._cls.listbox||c.ui.ListBox,
+f=new f(b,a,d));this.controls[b]=f;c.isWebKit&&f.onPostRender.add(function(a,b){i.add(b,"mousedown",function(){d.bookmark=d.selection.getBookmark(1)});i.add(b,"focus",function(){d.selection.moveToBookmark(d.bookmark);d.bookmark=null})});f.hideMenu&&d.onMouseDown.add(f.hideMenu,f);return this.add(f)},createButton:function(b,a,f){var d=this.editor;if(this.get(b))return null;a.title=d.translate(a.title);a.label=d.translate(a.label);a.scope=a.scope||d;if(!a.onclick&&!a.menu_button)a.onclick=function(){d.execCommand(a.cmd,
+a.ui||!1,a.value)};a=g({title:a.title,"class":"mce_"+b,unavailable_prefix:d.getLang("unavailable",""),scope:a.scope,control_manager:this},a);b=this.prefix+b;a.menu_button?(f=f||this._cls.menubutton||c.ui.MenuButton,b=new f(b,a,d),d.onMouseDown.add(b.hideMenu,b)):(f=this._cls.button||c.ui.Button,b=new f(b,a));return this.add(b)},createMenuButton:function(b,a,c){a=a||{};a.menu_button=1;return this.createButton(b,a,c)},createSplitButton:function(b,a,f){var d=this.editor;if(this.get(b))return null;a.title=
+d.translate(a.title);a.scope=a.scope||d;if(!a.onclick)a.onclick=function(b){d.execCommand(a.cmd,a.ui||!1,b||a.value)};if(!a.onselect)a.onselect=function(b){d.execCommand(a.cmd,a.ui||!1,b||a.value)};a=g({title:a.title,"class":"mce_"+b,scope:a.scope,control_manager:this},a);b=this.prefix+b;b=this.add(new (f||this._cls.splitbutton||c.ui.SplitButton)(b,a,d));d.onMouseDown.add(b.hideMenu,b);return b},createColorSplitButton:function(b,a,f){var d=this.editor,i,j;if(this.get(b))return null;a.title=d.translate(a.title);
+a.scope=a.scope||d;if(!a.onclick)a.onclick=function(b){c.isIE&&(j=d.selection.getBookmark(1));d.execCommand(a.cmd,a.ui||!1,b||a.value)};if(!a.onselect)a.onselect=function(b){d.execCommand(a.cmd,a.ui||!1,b||a.value)};a=g({title:a.title,"class":"mce_"+b,menu_class:d.getParam("skin")+"Skin",scope:a.scope,more_colors_title:d.getLang("more_colors")},a);b=this.prefix+b;i=new (f||this._cls.colorsplitbutton||c.ui.ColorSplitButton)(b,a,d);d.onMouseDown.add(i.hideMenu,i);d.onRemove.add(function(){i.destroy()});
+c.isIE&&(i.onShowMenu.add(function(){d.focus();j=d.selection.getBookmark(1)}),i.onHideMenu.add(function(){j&&(d.selection.moveToBookmark(j),j=0)}));return this.add(i)},createToolbar:function(b,a,f){b=this.prefix+b;a=new (f||this._cls.toolbar||c.ui.Toolbar)(b,a,this.editor);if(this.get(b))return null;return this.add(a)},createToolbarGroup:function(b,a,f){b=this.prefix+b;a=new (f||this._cls.toolbarGroup||c.ui.ToolbarGroup)(b,a,this.editor);if(this.get(b))return null;return this.add(a)},createSeparator:function(b){return new (b||
+this._cls.separator||c.ui.Separator)},setControlType:function(b,a){return this._cls[b.toLowerCase()]=a},destroy:function(){j(this.controls,function(b){b.destroy()});this.controls=null}})})(tinymce);
+(function(c){var i=c.util.Dispatcher,j=c.each,g=c.isIE,b=c.isOpera;c.create("tinymce.WindowManager",{WindowManager:function(a){this.editor=a;this.onOpen=new i(this);this.onClose=new i(this);this.params={};this.features={}},open:function(a,f){var d="",i=this.editor.settings.dialog_type=="modal",k,m,o;o=c.DOM.getViewPort();a=a||{};f=f||{};m=b?o.w:screen.width;o=b?o.h:screen.height;a.name=a.name||"mc_"+(new Date).getTime();a.width=parseInt(a.width||320);a.height=parseInt(a.height||240);a.resizable=!0;
+a.left=a.left||parseInt(m/2)-a.width/2;a.top=a.top||parseInt(o/2)-a.height/2;f.inline=!1;f.mce_width=a.width;f.mce_height=a.height;f.mce_auto_focus=a.auto_focus;if(i&&g)a.center=!0,a.help=!1,a.dialogWidth=a.width+"px",a.dialogHeight=a.height+"px",a.scroll=a.scrollbars||!1;j(a,function(a,b){c.is(a,"boolean")&&(a=a?"yes":"no");/^(name|url)$/.test(b)||(d+=g&&i?(d?";":"")+b+":"+a:(d?",":"")+b+"="+a)});this.features=a;this.params=f;this.onOpen.dispatch(this,a,f);m=a.url||a.file;m=c._addVer(m);try{g&&i?
+(k=1,window.showModalDialog(m,window,d)):k=window.open(m,a.name,d)}catch(e){}k||alert(this.editor.getLang("popup_blocked"))},close:function(a){a.close();this.onClose.dispatch(this)},createInstance:function(a,b,d,g,i,j){return new (c.resolve(a))(b,d,g,i,j)},confirm:function(a,b,c,g){b.call(c||this,(g||window).confirm(this._decode(this.editor.getLang(a,a))))},alert:function(a,b,c,g){(g||window).alert(this._decode(this.editor.getLang(a,a)));b&&b.call(c||this)},resizeBy:function(a,b,c){c.resizeBy(a,b)},
+_decode:function(a){return c.DOM.decode(a).replace(/\\n/g,"\n")}})})(tinymce);
+(function(c){c.Formatter=function(i){function j(a){return a.nodeType===1&&(a.face==="mceinline"||a.style.fontFamily==="mceinline")}function g(a){return a?x[a]:x}function b(a,c){a&&(typeof a!=="string"?v(a,function(a,c){b(c,a)}):(c=c.length?c:[c],v(c,function(a){if(a.deep===L)a.deep=!a.selector;if(a.split===L)a.split=!a.selector||a.inline;if(a.remove===L&&a.selector&&!a.inline)a.remove="none";if(a.selector&&a.inline)a.mixed=!0,a.block_expand=!0;if(typeof a.classes==="string")a.classes=a.classes.split(/\s+/)}),
+x[a]=c))}function a(a,b,f){function n(a){var b=a.startContainer,c=a.startOffset;if(b.nodeType==1||b.nodeValue==="")if(b=b.nodeType==1?b.childNodes[c]:b){b=new D(b,b.parentNode);for(c=b.current();c;c=b.next())if(c.nodeType==3&&!h(c)){a.setStart(c,0);break}}return a}function o(a,c){c=c||J;a&&(v(c.styles,function(c,d){q.setStyle(a,d,e(c,b))}),v(c.attributes,function(c,d){q.setAttrib(a,d,e(c,b))}),v(c.classes,function(c){c=e(c,b);q.hasClass(a,c)||q.addClass(a,c)}))}function p(e){var f=[],g,i;g=J.inline||
+J.block;i=q.create(g);o(i);C.walk(e,function(e){function h(e){var l=e.nodeName.toLowerCase(),n=e.parentNode.nodeName.toLowerCase(),p;if(m(l,"br"))k=0,J.block&&q.remove(e);else if(J.wrapper&&d(e,a,b))k=0;else if(J.block&&!J.wrapper&&/^(h[1-6]|p|div|pre|address|dl|dt|dd)$/.test(l))e=q.rename(e,g),o(e),f.push(e),k=0;else{if(J.selector&&(v(s,function(a){!("collapsed"in a&&a.collapsed!==S)&&q.is(e,a.selector)&&!j(e)&&(o(e,a),p=!0)}),!J.inline||p)){k=0;return}H(g,l)&&H(n,g)&&!(e.nodeType===3&&e.nodeValue.length===
+1&&e.nodeValue.charCodeAt(0)===65279)?(k||(k=i.cloneNode(I),e.parentNode.insertBefore(k,e),f.push(k)),k.appendChild(e)):(k=0,v(c.grep(e.childNodes),h),k=0)}}var k;v(e,h)});J.wrap_links===!1&&v(f,function(a){function b(a){var d,e,g;if(a.nodeName==="A"){e=i.cloneNode(I);f.push(e);g=c.grep(a.childNodes);for(d=0;d<g.length;d++)e.appendChild(g[d]);a.appendChild(e)}v(c.grep(a.childNodes),b)}b(a)});v(f,function(c){function e(a){var b,c;v(a.childNodes,function(a){if(a.nodeType==1&&!r(a)&&!j(a))return b=a,
+I});b&&k(b,J)&&(c=b.cloneNode(I),o(c),q.replace(c,a,E),q.remove(b,1));return c||a}var g;g=function(a){var b=0;v(a.childNodes,function(a){!h(a)&&!r(a)&&b++});return b}(c);if((f.length>1||!F(c))&&g===0)q.remove(c,1);else if(J.inline||J.wrapper){!J.exact&&g===1&&(c=e(c));v(s,function(a){v(q.select(a.inline,c),function(c){var d;if(a.wrap_links===!1){d=c.parentNode;do if(d.nodeName==="A")return;while(d=d.parentNode)}l(a,b,c,a.exact?c:null)})});if(d(c.parentNode,a,b))return q.remove(c,1),c=0,E;J.merge_with_parents&&
+q.getParent(c.parentNode,function(e){if(d(e,a,b))return q.remove(c,1),c=0,E});c&&(c=t(B(c),c),c=t(c,B(c,E)))}})}var s=g(a),J=s[0],x,S=A.isCollapsed();if(J)if(f)x=q.createRng(),x.setStartBefore(f),x.setEndAfter(f),p(u(x,s));else if(!S||!J.inline||q.select("td.mceSelected,th.mceSelected").length){x=i.selection.getNode();f=A.getBookmark();p(u(A.getRng(E),s));if(J.styles&&(J.styles.color||J.styles.textDecoration))c.walk(x,O,"childNodes"),O(x);A.moveToBookmark(f);A.setRng(n(A.getRng(E)));i.nodeChanged()}else z("apply",
+a,b)}function f(a,b,e){function f(a){var b=a.startContainer,c=a.startOffset,d;if(b.nodeType==3&&c>=b.nodeValue.length-1)b=b.parentNode,c=M(b)+1;if(b.nodeType==1){d=b.childNodes;b=d[Math.min(c,d.length-1)];b=new D(b);c>d.length-1&&b.next();for(c=b.current();c;c=b.next())if(c.nodeType==3&&!h(c)){b=q.create("a",null,N);c.parentNode.insertBefore(b,c);a.setStart(c,0);A.setRng(a);q.remove(b);break}}}function j(a){var d,e,f;d=c.grep(a.childNodes);e=0;for(f=t.length;e<f;e++)if(l(t[e],b,a,a))break;if(x.deep){e=
+0;for(f=d.length;e<f;e++)j(d[e])}}function k(c){var e;v(q.getParents(c.parentNode,void 0,q.getRoot()).reverse(),function(c){var f;!e&&c.id!="_start"&&c.id!="_end"&&(f=d(c,a,b))&&f.split!==!1&&(e=c)});return e}function m(a,c,d,e){var f,g,h,i,j,k;if(a){k=a.parentNode;for(f=c.parentNode;f&&f!=k;f=f.parentNode){g=f.cloneNode(I);for(j=0;j<t.length;j++)if(l(t[j],b,g,g)){g=0;break}g&&(h&&g.appendChild(h),i||(i=g),h=g)}if(e&&(!x.mixed||!F(a)))c=q.split(a,c);h&&(d.parentNode.insertBefore(h,d),i.appendChild(d))}return c}
+function o(a){var b=q.get(a?"_start":"_end"),c=b[a?"firstChild":"lastChild"];r(c)&&(c=c[a?"firstChild":"lastChild"]);q.remove(b,!0);return c}function s(a){var b,c,a=u(a,t,E);if(x.split)b=y(a,E),c=y(a),b!=c?(b=p(b,"span",{id:"_start","data-mce-type":"bookmark"}),c=p(c,"span",{id:"_end","data-mce-type":"bookmark"}),m(k(b),b,b,!0),m(k(c),c,c,!0),b=o(E),c=o()):b=c=m(k(b),b,b,!0),a.startContainer=b.parentNode,a.startOffset=M(b),a.endContainer=c.parentNode,a.endOffset=M(c)+1;C.walk(a,function(a){v(a,function(a){j(a);
+a.nodeType===1&&i.dom.getStyle(a,"text-decoration")==="underline"&&a.parentNode&&Q(a.parentNode)==="underline"&&l({deep:!1,exact:!0,inline:"span",styles:{textDecoration:"underline"}},null,a)})})}var t=g(a),x=t[0],B;e?(B=q.createRng(),B.setStartBefore(e),B.setEndAfter(e),s(B)):!A.isCollapsed()||!x.inline||q.select("td.mceSelected,th.mceSelected").length?(e=A.getBookmark(),s(A.getRng(E)),A.moveToBookmark(e),n(a,b,A.getStart())&&f(A.getRng(!0)),i.nodeChanged()):z("remove",a,b)}function d(a,b,c,d){function f(a,
+b,g){var h,i,j=b[g];if(j)if(j.length===L)for(h in j){if(j.hasOwnProperty(h)){i=g==="attributes"?q.getAttrib(a,h):o(a,h);if(d&&!i&&!b.exact)return;if((!d||b.exact)&&!m(i,e(j[h],c)))return}}else for(h=0;h<j.length;h++)if(g==="attributes"?q.getAttrib(a,j[h]):o(a,j[h]))break;return b}var h=g(b),i;if(h&&a)for(i=0;i<h.length;i++)if(b=h[i],k(a,b)&&f(a,b,"attributes")&&f(a,b,"styles")){if(h=b.classes)for(i=0;i<h.length;i++)if(!q.hasClass(a,h[i]))return;return b}}function n(a,b,c){function e(c){c=q.getParent(c,
+function(c){return!!d(c,a,b,!0)});return d(c,a,b)}var f;if(c)return e(c);if(A.isCollapsed()){for(c=G.apply.length-1;c>=0;c--)if(G.apply[c].name==a)return!0;for(c=G.remove.length-1;c>=0;c--)if(G.remove[c].name==a)return!1;return e(A.getNode())}c=A.getNode();if(e(c))return E;f=A.getStart();if(f!=c&&e(f))return E;return I}function k(a,b){if(m(a,b.inline))return E;if(m(a,b.block))return E;if(b.selector)return q.is(a,b.selector)}function m(a,b){a=a||"";b=b||"";a=""+(a.nodeName||a);b=""+(b.nodeName||b);
+return a.toLowerCase()==b.toLowerCase()}function o(a,b){var c=q.getStyle(a,b);if(b=="color"||b=="backgroundColor")c=q.toHex(c);b=="fontWeight"&&c==700&&(c="bold");return""+c}function e(a,b){typeof a!="string"?a=a(b):b&&(a=a.replace(/%(\w+)/g,function(a,c){return b[c]||a}));return a}function h(a){return a&&a.nodeType===3&&/^([\s\r\n]+|)$/.test(a.nodeValue)}function p(a,b,c){b=q.create(b,c);a.parentNode.insertBefore(b,a);b.appendChild(a);return b}function u(a,b){function c(a,d,e,f){for(var g,f=f||q.getRoot();;){g=
+a.parentNode;if(g==f||!b[0].block_expand&&F(g))break;for(j=g[d];j&&j!=a;j=j[e]){if(j.nodeType==1&&!r(j))return a;if(j.nodeType==3&&!h(j))return a}a=a.parentNode}return a}function d(a,b){for(b===L&&(b=a.nodeType===3?a.length:a.childNodes.length);a&&a.hasChildNodes();)(a=a.childNodes[b])&&(b=a.nodeType===3?a.length:a.childNodes.length);return{node:a,offset:b}}var e=a.startContainer,f=a.startOffset,g=a.endContainer,i=a.endOffset,j,k;e.nodeType==1&&e.hasChildNodes()&&(k=e.childNodes.length-1,e=e.childNodes[f>
+k?k:f],e.nodeType==3&&(f=0));if(g.nodeType==1&&g.hasChildNodes()&&(k=g.childNodes.length-1,g=g.childNodes[i>k?k:i-1],g.nodeType==3))i=g.nodeValue.length;if(r(e.parentNode))e=e.parentNode;r(e)&&(e=e.nextSibling||e);if(r(g.parentNode))i=q.nodeIndex(g),g=g.parentNode;if(r(g)&&g.previousSibling)g=g.previousSibling,i=g.length;if(b[0].inline&&(k=d(g,i),k.node)){for(;k.node&&k.offset===0&&k.node.previousSibling;)k=d(k.node.previousSibling);if(k.node&&k.offset>0&&k.node.nodeType===3&&k.node.nodeValue.charAt(k.offset-
+1)===" ")if(k.offset>1)g=k.node,g.splitText(k.offset-1);else if(k.node.previousSibling)g=k.node.previousSibling}if(b[0].inline||b[0].block_expand)e=c(e,"firstChild","nextSibling"),g=c(g,"lastChild","previousSibling");b[0].selector&&b[0].expand!==I&&!b[0].inline&&(k=function(c,d){var e,f,g,h;c.nodeType==3&&c.nodeValue.length==0&&c[d]&&(c=c[d]);e=q.getParents(c,void 0,q.getRoot());for(f=0;f<e.length;f++)for(g=0;g<b.length;g++)if(h=b[g],!("collapsed"in h&&h.collapsed!==a.collapsed)&&q.is(e[f],h.selector))return e[f];
+return c},e=k(e,"previousSibling"),g=k(g,"nextSibling"));if(b[0].block||b[0].selector)k=function(a,c){var d;b[0].wrapper||(d=q.getParent(a,b[0].block));d||(d=q.getParent(a.nodeType==3?a.parentNode:a,F));d&&b[0].wrapper&&(d=q.getParents(d,"ul,ol",q.getRoot()).reverse()[0]||d);if(!d)for(d=a;d[c]&&!F(d[c]);)if(d=d[c],m(d,"br"))break;return d||a},e=k(e,"previousSibling"),g=k(g,"nextSibling"),b[0].block&&(F(e)||(e=c(e,"firstChild","nextSibling")),F(g)||(g=c(g,"lastChild","previousSibling")));if(e.nodeType==
+1)f=M(e),e=e.parentNode;if(g.nodeType==1)i=M(g)+1,g=g.parentNode;return{startContainer:e,startOffset:f,endContainer:g,endOffset:i}}function l(a,b,c,d){var f,g,h;if(!k(c,a))return I;if(a.remove!="all"){v(a.styles,function(a,f){a=e(a,b);typeof f==="number"&&(f=a,d=0);(!d||m(o(d,f),a))&&q.setStyle(c,f,"");h=1});h&&q.getAttrib(c,"style")==""&&(c.removeAttribute("style"),c.removeAttribute("data-mce-style"));v(a.attributes,function(a,f){var g,a=e(a,b);typeof f==="number"&&(f=a,d=0);if(!d||m(q.getAttrib(d,
+f),a)){if(f=="class"&&(a=q.getAttrib(c,f)))if(g="",v(a.split(/\s+/),function(a){/mce\w+/.test(a)&&(g+=(g?" ":"")+a)}),g){q.setAttrib(c,f,g);return}f=="class"&&c.removeAttribute("className");P.test(f)&&c.removeAttribute("data-mce-"+f);c.removeAttribute(f)}});v(a.classes,function(a){a=e(a,b);(!d||q.hasClass(d,a))&&q.removeClass(c,a)});g=q.getAttribs(c);for(f=0;f<g.length;f++)if(g[f].nodeName.indexOf("_")!==0)return I}if(a.remove!="none")return s(c,a),E}function s(a,b){var d=a.parentNode,e;if(b.block)if(K)d==
+q.getRoot()&&(!b.list_block||!m(a,b.list_block))&&v(c.grep(a.childNodes),function(a){H(K,a.nodeName.toLowerCase())?e?e.appendChild(a):e=p(a,K):e=0});else{var f=function(a,b,c){a=B(a,b,c);return!a||a.nodeName=="BR"||F(a)};F(a)&&!F(d)&&(!f(a,I)&&!f(a.firstChild,E,1)&&a.insertBefore(q.create("br"),a.firstChild),!f(a,E)&&!f(a.lastChild,I,1)&&a.appendChild(q.create("br")))}(!b.selector||!b.inline||m(b.inline,a))&&q.remove(a,1)}function B(a,b,c){if(a){b=b?"nextSibling":"previousSibling";for(a=c?a:a[b];a;a=
+a[b])if(a.nodeType==1||!h(a))return a}}function r(a){return a&&a.nodeType==1&&a.getAttribute("data-mce-type")=="bookmark"}function t(a,b){function d(a,b){function c(a){var b={};v(q.getAttribs(a),function(c){c=c.nodeName.toLowerCase();c.indexOf("_")!==0&&c!=="style"&&(b[c]=q.getAttrib(a,c))});return b}function e(a,b){var c,d;for(d in a)if(a.hasOwnProperty(d)){c=b[d];if(c===L)return I;if(a[d]!=c)return I;delete b[d]}for(d in b)if(b.hasOwnProperty(d))return I;return E}if(a.nodeName!=b.nodeName)return I;
+if(!e(c(a),c(b)))return I;if(!e(q.parseStyle(q.getAttrib(a,"style")),q.parseStyle(q.getAttrib(b,"style"))))return I;return E}var e,f;if(a&&b&&(f=function(a,b){for(e=a;e;e=e[b]){if(e.nodeType==3&&e.nodeValue.length!==0)break;if(e.nodeType==1&&!r(e))return e}return a},a=f(a,"previousSibling"),b=f(b,"nextSibling"),d(a,b))){for(e=a.nextSibling;e&&e!=b;)f=e,e=e.nextSibling,a.appendChild(f);q.remove(b);v(c.grep(b.childNodes),function(b){a.appendChild(b)});return a}return b}function y(a,b){var c,d,e;c=a[b?
+"startContainer":"endContainer"];d=a[b?"startOffset":"endOffset"];c.nodeType==1&&(e=c.childNodes.length-1,!b&&d&&d--,c=c.childNodes[d>e?e:d]);return c}function z(b,d,e){function g(){return G.apply.length||G.remove.length}function h(b){v(G.apply.reverse(),function(c){a(c.name,c.vars,b);c.name==="forecolor"&&c.vars.value&&O(b.parentNode)});v(G.remove.reverse(),function(a){f(a.name,a.vars,b)});q.remove(b,1);G.apply=[];G.remove=[]}for(var k=G[b],l=G[b=="apply"?"remove":"apply"],b=k.length-1;b>=0;b--)if(k[b].name==
+d)return;k.push({name:d,vars:e});for(b=l.length-1;b>=0;b--)l[b].name==d&&l.splice(b,1);if(g()&&(i.getDoc().execCommand("FontName",!1,"mceinline"),G.lastRng=A.getRng(),v(q.select("font,span"),function(a){var b;j(a)&&(b=A.getBookmark(),h(a),A.moveToBookmark(b),i.nodeChanged())}),!G.isListening&&g()))G.isListening=!0,v("onKeyDown,onKeyUp,onKeyPress,onMouseUp".split(","),function(a){i[a].addToTop(function(a,b){if(g()&&!c.dom.RangeUtils.compareRanges(G.lastRng,A.getRng())&&(v(q.select("font,span"),function(b){var c;
+if(j(b))(c=b.firstChild)?(h(b),b=q.createRng(),b.setStart(c,c.nodeValue.length),b.setEnd(c,c.nodeValue.length),A.setRng(b),a.nodeChanged()):q.remove(b)}),b.type=="keyup"||b.type=="mouseup"))G.apply=[],G.remove=[]})})}var x={},v=c.each,q=i.dom,A=i.selection,D=c.dom.TreeWalker,C=new c.dom.RangeUtils(q),H=i.schema.isValidChild,F=q.isBlock,K=i.settings.forced_root_block,M=q.nodeIndex,N="\ufeff",P=/^(src|href|style)$/,I=!1,E=!0,L,G={apply:[],remove:[]},Q=function(a){var b;i.dom.getParent(a,function(a){return(b=
+i.dom.getStyle(a,"text-decoration"))&&b!=="none"});return b},O=function(a){var b;a.nodeType===1&&a.parentNode&&a.parentNode.nodeType===1&&(b=Q(a.parentNode),i.dom.getStyle(a,"color")&&b?i.dom.setStyle(a,"text-decoration",b):i.dom.getStyle(a,"textdecoration")===b&&i.dom.setStyle(a,"text-decoration",null))};c.extend(this,{get:g,register:b,apply:a,remove:f,toggle:function(b,c,d){var e=g(b);n(b,c,d)&&(!("toggle"in e[0])||e[0].toggle)?f(b,c,d):a(b,c,d)},match:n,matchAll:function(a,b){var c,e=[],f={},g,
+h;if(A.isCollapsed()){for(g=0;g<a.length;g++)for(c=G.remove.length-1;c>=0;c--)if(h=a[g],G.remove[c].name==h){f[h]=!0;break}for(c=G.apply.length-1;c>=0;c--)for(g=0;g<a.length;g++)h=a[g],!f[h]&&G.apply[c].name==h&&(f[h]=!0,e.push(h))}c=A.getStart();q.getParent(c,function(c){var g,h;for(g=0;g<a.length;g++)h=a[g],!f[h]&&d(c,h,b)&&(f[h]=!0,e.push(h))});return e},matchNode:d,canApply:function(a){var a=g(a),b,c,d,e;if(a){b=A.getStart();b=q.getParents(b,void 0,q.getRoot());for(d=a.length-1;d>=0;d--){e=a[d].selector;
+if(!e)return E;for(c=b.length-1;c>=0;c--)if(q.is(b[c],e))return E}}return I}})}})(tinymce);
+tinymce.onAddEditor.add(function(c,i){var j,g,b,a=i.settings;if(a.inline_styles){g=c.explode(a.font_size_style_values);var f=function(a,d){c.each(d,function(c,d){c&&b.setStyle(a,d,c)});b.rename(a,"span")};j={font:function(a,b){f(b,{backgroundColor:b.style.backgroundColor,color:b.color,fontFamily:b.face,fontSize:g[parseInt(b.size)-1]})},u:function(a,b){f(b,{textDecoration:"underline"})},strike:function(a,b){f(b,{textDecoration:"line-through"})}};var d=function(d,f){b=d.dom;a.convert_fonts_to_spans&&
+c.each(b.select("font,u,strike",f.node),function(a){j[a.nodeName.toLowerCase()](i.dom,a)})};i.onPreProcess.add(d);i.onSetContent.add(d);i.onInit.add(function(){i.selection.onSetContent.add(d)})}});