window.tinyMCE_GZ={loaded:true};
(function(n){var p=/^\s*|\s*$/g,o="B".replace(/A(.)|B/,"$1")==="$1",q={majorVersion:"3",minorVersion:"4.7",releaseDate:"2011-11-03",_init:function(){function e(b){if(b.src&&/tiny-(|en|es|pt)(-src)?.js/.test(b.src)){if(/_(src|dev)\.js/g.test(b.src))a.suffix="_src";if((j=b.src.indexOf("?"))!=-1)a.query=b.src.substring(j+1);a.baseURL=b.src.substring(0,b.src.lastIndexOf("/"));if(d&&a.baseURL.indexOf("://")==-1&&a.baseURL.indexOf("/")!==0)a.baseURL=d+a.baseURL;return a.baseURL}return null}var a=this,g=
document,h=navigator,f=h.userAgent,d,j,k;a.isOpera=n.opera&&opera.buildNumber;a.isWebKit=/WebKit/.test(f);a.isIE=!a.isWebKit&&!a.isOpera&&/MSIE/gi.test(f)&&/Explorer/gi.test(h.appName);a.isIE6=a.isIE&&/MSIE [56]/.test(f);a.isIE7=a.isIE&&/MSIE [7]/.test(f);a.isIE8=a.isIE&&/MSIE [8]/.test(f);a.isIE9=a.isIE&&/MSIE [9]/.test(f);a.isGecko=!a.isWebKit&&/Gecko/.test(f);a.isMac=f.indexOf("Mac")!=-1;a.isAir=/adobeair/i.test(f);a.isIDevice=/(iPad|iPhone)/.test(f);a.isIOS5=a.isIDevice&&f.match(/AppleWebKit\/(\d*)/)[1]>=
534;if(n.tinyMCEPreInit){a.suffix=tinyMCEPreInit.suffix;a.baseURL=tinyMCEPreInit.base;a.query=tinyMCEPreInit.query}else{a.suffix="";f=g.getElementsByTagName("base");for(h=0;h<f.length;h++)if(k=f[h].href){if(/^https?:\/\/[^\/]+$/.test(k))k+="/";d=k?k.match(/.*\//)[0]:""}f=g.getElementsByTagName("script");for(h=0;h<f.length;h++)if(e(f[h]))return;if(g=g.getElementsByTagName("head")[0]){f=g.getElementsByTagName("script");for(h=0;h<f.length;h++)if(e(f[h]))return}}},is:function(e,a){if(!a)return e!==void 0;
if(a=="array"&&e.hasOwnProperty&&e instanceof Array)return true;return typeof e==a},makeMap:function(e,a,g){e=e||[];a=a||",";if(typeof e=="string")e=e.split(a);g=g||{};for(a=e.length;a--;)g[e[a]]={};return g},each:function(e,a,g){var h,f;if(!e)return 0;g=g||e;if(e.length!==void 0){h=0;for(f=e.length;h<f;h++)if(a.call(g,e[h],h,e)===false)return 0}else for(h in e)if(e.hasOwnProperty(h))if(a.call(g,e[h],h,e)===false)return 0;return 1},map:function(e,a){var g=[];q.each(e,function(h){g.push(a(h))});return g},
grep:function(e,a){var g=[];q.each(e,function(h){if(!a||a(h))g.push(h)});return g},inArray:function(e,a){var g,h;if(e){g=0;for(h=e.length;g<h;g++)if(e[g]===a)return g}return-1},extend:function(e,a){var g,h,f=arguments;g=1;for(h=f.length;g<h;g++){a=f[g];q.each(a,function(d,j){if(d!==void 0)e[j]=d})}return e},trim:function(e){return(e?""+e:"").replace(p,"")},create:function(e,a,g){var h,f,d,j,k,b=0;e=/^((static) )?([\w.]+)(:([\w.]+))?/.exec(e);d=e[3].match(/(^|\.)(\w+)$/i)[2];f=this.createNS(e[3].replace(/\.\w+$/,
""),g);if(!f[d])if(e[2]=="static"){f[d]=a;this.onCreate&&this.onCreate(e[2],e[3],f[d])}else{if(!a[d]){a[d]=function(){};b=1}f[d]=a[d];this.extend(f[d].prototype,a);if(e[5]){h=this.resolve(e[5]).prototype;j=e[5].match(/\.(\w+)$/i)[1];k=f[d];f[d]=b?function(){return h[j].apply(this,arguments)}:function(){this.parent=h[j];return k.apply(this,arguments)};f[d].prototype[d]=f[d];this.each(h,function(c,l){f[d].prototype[l]=h[l]});this.each(a,function(c,l){if(h[l])f[d].prototype[l]=function(){this.parent=
h[l];return c.apply(this,arguments)};else if(l!=d)f[d].prototype[l]=c})}this.each(a["static"],function(c,l){f[d][l]=c});this.onCreate&&this.onCreate(e[2],e[3],f[d].prototype)}},walk:function(e,a,g,h){h=h||this;if(e){if(g)e=e[g];q.each(e,function(f,d){if(a.call(h,f,d,g)===false)return false;q.walk(f,a,g,h)})}},createNS:function(e,a){var g,h;a=a||n;e=e.split(".");for(g=0;g<e.length;g++){h=e[g];a[h]||(a[h]={});a=a[h]}return a},resolve:function(e,a){var g,h;a=a||n;e=e.split(".");g=0;for(h=e.length;g<
h;g++){a=a[e[g]];if(!a)break}return a},addUnload:function(e,a){var g=this;e={func:e,scope:a||this};if(g.unloads)g.unloads.push(e);else{var h=function(){var d=g.unloads,j,k;if(d){for(k in d)(j=d[k])&&j.func&&j.func.call(j.scope,1);if(n.detachEvent){n.detachEvent("onbeforeunload",f);n.detachEvent("onunload",h)}else n.removeEventListener&&n.removeEventListener("unload",h,false);g.unloads=w=h=0;n.CollectGarbage&&CollectGarbage()}},f=function(){var d=document;if(d.readyState=="interactive"){var j=function(){d.detachEvent("onstop",
j);h&&h();d=0};d&&d.attachEvent("onstop",j);n.setTimeout(function(){d&&d.detachEvent("onstop",j)},0)}};if(n.attachEvent){n.attachEvent("onunload",h);n.attachEvent("onbeforeunload",f)}else n.addEventListener&&n.addEventListener("unload",h,false);g.unloads=[e]}return e},removeUnload:function(e){var a=this.unloads,g=null;q.each(a,function(h,f){if(h&&h.func==e){a.splice(f,1);g=e;return false}});return g},explode:function(e,a){return e?q.map(e.split(a||","),q.trim):e},_addVer:function(e){var a;if(!this.query)return e;
a=(e.indexOf("?")==-1?"?":"&")+this.query;if(e.indexOf("#")==-1)return e+a;return e.replace("#",a+"#")},_replace:function(e,a,g){if(o)return g.replace(e,function(){var h=a,f=arguments,d;for(d=0;d<f.length-2;d++)h=f[d]===void 0?h.replace(new RegExp("\\$"+d,"g"),""):h.replace(new RegExp("\\$"+d,"g"),f[d]);return h});return g.replace(e,a)}};q._init();n.tinymce=n.tinyMCE=q})(window);
tinymce.create("tinymce.util.Dispatcher",{scope:null,listeners:null,Dispatcher:function(n){this.scope=n||this;this.listeners=[]},add:function(n,p){this.listeners.push({cb:n,scope:p||this.scope});return n},addToTop:function(n,p){this.listeners.unshift({cb:n,scope:p||this.scope});return n},remove:function(n){var p=this.listeners,o=null;tinymce.each(p,function(q,e){if(n==q.cb){o=n;p.splice(e,1);return false}});return o},dispatch:function(){var n,p=arguments,o,q=this.listeners;for(o=0;o<q.length;o++){n=
q[o];n=n.cb.apply(n.scope,p);if(n===false)break}return n}});
(function(){var n=tinymce.each;tinymce.create("tinymce.util.URI",{URI:function(p,o){var q=this,e;p=tinymce.trim(p);o=q.settings=o||{};if(/^([\w\-]+):([^\/]{2})/i.test(p)||/^\s*#/.test(p))q.source=p;else{if(p.indexOf("/")===0&&p.indexOf("//")!==0)p=(o.base_uri?o.base_uri.protocol||"http":"http")+"://mce_host"+p;if(!/^[\w-]*:?\/\//.test(p)){e=o.base_uri?o.base_uri.path:(new tinymce.util.URI(location.href)).directory;p=(o.base_uri&&o.base_uri.protocol||"http")+"://mce_host"+q.toAbsPath(e,p)}p=p.replace(/@@/g,
"(mce_at)");p=/^(?:(?![^:@]+:[^:@\/]*@)([^:\/?#.]+):)?(?:\/\/)?((?:(([^:@]*):?([^:@]*))?@)?([^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/.exec(p);n(["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"],function(a,g){if(g=p[g])g=g.replace(/\(mce_at\)/g,"@@");q[a]=g});if(o=o.base_uri){if(!q.protocol)q.protocol=o.protocol;if(!q.userInfo)q.userInfo=o.userInfo;
if(!q.port&&q.host=="mce_host")q.port=o.port;if(!q.host||q.host=="mce_host")q.host=o.host;q.source=""}}},setPath:function(p){p=/^(.*?)\/?(\w+)?$/.exec(p);this.path=p[0];this.directory=p[1];this.file=p[2];this.source="";this.getURI()},toRelative:function(p){var o;if(p==="./")return p;p=new tinymce.util.URI(p,{base_uri:this});if(p.host!="mce_host"&&this.host!=p.host&&p.host||this.port!=p.port||this.protocol!=p.protocol)return p.getURI();o=this.toRelPath(this.path,p.path);if(p.query)o+="?"+p.query;if(p.anchor)o+=
"#"+p.anchor;return o},toAbsolute:function(p,o){p=new tinymce.util.URI(p,{base_uri:this});return p.getURI(this.host==p.host&&this.protocol==p.protocol?o:0)},toRelPath:function(p,o){var q,e=0,a="",g,h;p=p.substring(0,p.lastIndexOf("/"));p=p.split("/");q=o.split("/");if(p.length>=q.length){g=0;for(h=p.length;g<h;g++)if(g>=q.length||p[g]!=q[g]){e=g+1;break}}if(p.length<q.length){g=0;for(h=q.length;g<h;g++)if(g>=p.length||p[g]!=q[g]){e=g+1;break}}if(e==1)return o;g=0;for(h=p.length-(e-1);g<h;g++)a+="../";
g=e-1;for(h=q.length;g<h;g++)a+=g!=e-1?"/"+q[g]:q[g];return a},toAbsPath:function(p,o){var q,e=0,a=[],g;g=/\/$/.test(o)?"/":"";p=p.split("/");o=o.split("/");n(p,function(h){h&&a.push(h)});p=a;q=o.length-1;for(a=[];q>=0;q--)if(!(o[q].length==0||o[q]=="."))if(o[q]=="..")e++;else if(e>0)e--;else a.push(o[q]);q=p.length-e;p=q<=0?a.reverse().join("/"):p.slice(0,q).join("/")+"/"+a.reverse().join("/");if(p.indexOf("/")!==0)p="/"+p;if(g&&p.lastIndexOf("/")!==p.length-1)p+=g;return p},getURI:function(p){var o;
if(!this.source||p){o="";if(!p){if(this.protocol)o+=this.protocol+"://";if(this.userInfo)o+=this.userInfo+"@";if(this.host)o+=this.host;if(this.port)o+=":"+this.port}if(this.path)o+=this.path;if(this.query)o+="?"+this.query;if(this.anchor)o+="#"+this.anchor;this.source=o}return this.source}})})();
(function(){var n=tinymce.each;tinymce.create("static tinymce.util.Cookie",{getHash:function(p){p=this.get(p);var o;p&&n(p.split("&"),function(q){q=q.split("=");o=o||{};o[unescape(q[0])]=unescape(q[1])});return o},setHash:function(p,o,q,e,a,g){var h="";n(o,function(f,d){h+=(!h?"":"&")+escape(d)+"="+escape(f)});this.set(p,h,q,e,a,g)},get:function(p){var o=document.cookie,q=p+"=",e;if(o){e=o.indexOf("; "+q);if(e==-1){e=o.indexOf(q);if(e!=0)return null}else e+=2;p=o.indexOf(";",e);if(p==-1)p=o.length;
return unescape(o.substring(e+q.length,p))}},set:function(p,o,q,e,a,g){document.cookie=p+"="+escape(o)+(q?"; expires="+q.toGMTString():"")+(e?"; path="+escape(e):"")+(a?"; domain="+a:"")+(g?"; secure":"")},remove:function(p,o){var q=new Date;q.setTime(q.getTime()-1E3);this.set(p,"",q,o,q)}})})();
(function(){function n(p,o){var q,e,a;o=o||'"';if(p==null)return"null";a=typeof p;if(a=="string"){e="\u0008b\tt\nn\u000cf\rr\"\"''\\\\";return o+p.replace(/([\u0080-\uFFFF\x00-\x1f\"\'\\])/g,function(g,h){if(o==='"'&&g==="'")return g;q=e.indexOf(h);if(q+1)return"\\"+e.charAt(q+1);g=h.charCodeAt().toString(16);return"\\u"+"0000".substring(g.length)+g})+o}if(a=="object"){if(p.hasOwnProperty&&p instanceof Array){q=0;for(e="[";q<p.length;q++)e+=(q>0?",":"")+n(p[q],o);return e+"]"}e="{";for(q in p)if(p.hasOwnProperty(q))e+=
typeof p[q]!="function"?(e.length>1?","+o:o)+q+o+":"+n(p[q],o):"";return e+"}"}return""+p}tinymce.util.JSON={serialize:n,parse:function(p){try{return eval("("+p+")")}catch(o){}}}})();
tinymce.create("static tinymce.util.XHR",{send:function(n){function p(g){o=0;try{o=new ActiveXObject(g)}catch(h){}return o}var o,q=window,e=0;n.scope=n.scope||this;n.success_scope=n.success_scope||n.scope;n.error_scope=n.error_scope||n.scope;n.async=n.async===false?false:true;n.data=n.data||"";if(o=q.XMLHttpRequest?new XMLHttpRequest:p("Microsoft.XMLHTTP")||p("Msxml2.XMLHTTP")){o.overrideMimeType&&o.overrideMimeType(n.content_type);o.open(n.type||(n.data?"POST":"GET"),n.url,n.async);n.content_type&&
o.setRequestHeader("Content-Type",n.content_type);o.setRequestHeader("X-Requested-With","XMLHttpRequest");o.send(n.data);var a=function(){if(!n.async||o.readyState==4||e++>1E4){if(n.success&&e<1E4&&o.status==200)n.success.call(n.success_scope,""+o.responseText,o,n);else if(n.error)n.error.call(n.error_scope,e>1E4?"TIMED_OUT":"GENERAL",o,n);o=null}else q.setTimeout(a,10)};if(!n.async)return a();q.setTimeout(a,10)}}});
(function(){var n=tinymce.extend,p=tinymce.util.JSON,o=tinymce.util.XHR;tinymce.create("tinymce.util.JSONRequest",{JSONRequest:function(q){this.settings=n({},q);this.count=0},send:function(q){var e=q.error,a=q.success;q=n(this.settings,q);q.success=function(g,h){g=p.parse(g);if(typeof g=="undefined")g={error:"JSON Parse error."};g.error?e.call(q.error_scope||q.scope,g.error,h):a.call(q.success_scope||q.scope,g.result)};q.error=function(g,h){if(e)e.call(q.error_scope||q.scope,g,h)};q.data=p.serialize({id:q.id||
"c"+this.count++,method:q.method,params:q.params});q.content_type="application/json";o.send(q)},"static":{sendRPC:function(q){return(new tinymce.util.JSONRequest).send(q)}}})})();(function(n){n.VK={DELETE:46,BACKSPACE:8,ENTER:13,TAB:9,SPACEBAR:32,UP:38,DOWN:40}})(tinymce);
(function(n){function p(b){var c=b.dom,l=b.selection;b.onKeyDown.add(function(s,i){var m,r,t;if((t=i.keyCode==k)||i.keyCode==j){i.preventDefault();i=l.getRng();m=c.getParent(i.startContainer,c.isBlock);if(t)m=c.getNext(m,c.isBlock);if(m){for(m=m.firstChild;m&&m.nodeType==3&&m.nodeValue.length==0;)m=m.nextSibling;if(m&&m.nodeName==="SPAN")r=m.cloneNode(false)}s.getDoc().execCommand(t?"ForwardDelete":"Delete",false,null);m=c.getParent(i.startContainer,c.isBlock);n.each(c.select("span.Apple-style-span,font.Apple-style-span",
m),function(u){var v=l.getBookmark();r?c.replace(r.cloneNode(false),u,true):c.remove(u,true);l.moveToBookmark(v)})}})}function o(b){b.onKeyUp.add(function(c,l){l=l.keyCode;if(l==k||l==j)if(c.dom.isEmpty(c.getBody())){c.setContent("",{format:"raw"});c.nodeChanged()}})}function q(b){b.dom.bind(b.getDoc(),"focusin",function(){b.selection.setRng(b.selection.getRng())})}function e(b){b.onKeyDown.add(function(c,l){if(l.keyCode===j)if(c.selection.isCollapsed()&&c.selection.getRng(true).startOffset===0){var s=
c.selection.getNode().previousSibling;if(s&&s.nodeName&&s.nodeName.toLowerCase()==="hr"){c.dom.remove(s);n.dom.Event.cancel(l)}}})}function a(b){Range.prototype.getClientRects||b.onMouseDown.add(function(c,l){if(l.target.nodeName==="HTML"){var s=c.getBody();s.blur();setTimeout(function(){s.focus()},0)}})}function g(b){b.onClick.add(function(c,l){l=l.target;/^(IMG|HR)$/.test(l.nodeName)&&c.selection.getSel().setBaseAndExtent(l,0,l,1);l.nodeName=="A"&&c.dom.hasClass(l,"mceItemAnchor")&&c.selection.select(l);
c.nodeChanged()})}function h(b){var c,l;b.dom.bind(b.getDoc(),"selectionchange",function(){if(l){clearTimeout(l);l=0}l=window.setTimeout(function(){var s=b.selection.getRng();if(!c||!n.dom.RangeUtils.compareRanges(s,c)){b.nodeChanged();c=s}},50)})}function f(){document.body.setAttribute("role","application")}var d=n.VK,j=d.BACKSPACE,k=d.DELETE;n.create("tinymce.util.Quirks",{Quirks:function(b){if(n.isWebKit){p(b);o(b);q(b);g(b);n.isIDevice&&h(b)}if(n.isIE){e(b);o(b);f(b)}if(n.isGecko){e(b);a(b)}}})})(tinymce);
(function(n){function p(k){var b;b=document.createElement("div");b.innerHTML=k;return b.textContent||b.innerText||k}function o(k,b){var c,l,s,i={};if(k){k=k.split(",");b=b||10;for(c=0;c<k.length;c+=2){l=String.fromCharCode(parseInt(k[c],b));if(!e[l]){s="&"+k[c+1]+";";i[l]=s;i[s]=l}}return i}}var q,e,a,g=/[&<>\"\u007E-\uD7FF\uE000-\uFFEF]|[\uD800-\uDBFF][\uDC00-\uDFFF]/g,h=/[<>&\u007E-\uD7FF\uE000-\uFFEF]|[\uD800-\uDBFF][\uDC00-\uDFFF]/g,f=/[<>&\"\']/g,d=/&(#x|#)?([\w]+);/g,j={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"};e={'"':"&quot;","'":"&#39;","<":"&lt;",">":"&gt;","&":"&amp;"};a={"&lt;":"<","&gt;":">","&amp;":"&","&quot;":'"',"&apos;":"'"};q=o("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);n.html=n.html||{};n.html.Entities={encodeRaw:function(k,b){return k.replace(b?g:h,function(c){return e[c]||c})},encodeAllRaw:function(k){return(""+k).replace(f,function(b){return e[b]||b})},encodeNumeric:function(k,b){return k.replace(b?g:h,function(c){if(c.length>1)return"&#"+((c.charCodeAt(0)-55296)*1024+(c.charCodeAt(1)-56320)+65536)+";";return e[c]||"&#"+c.charCodeAt(0)+";"})},encodeNamed:function(k,b,c){c=c||q;return k.replace(b?g:h,function(l){return e[l]||c[l]||l})},getEncodeFunc:function(k,
b){function c(i,m){return i.replace(m?g:h,function(r){return e[r]||b[r]||"&#"+r.charCodeAt(0)+";"||r})}function l(i,m){return s.encodeNamed(i,m,b)}var s=n.html.Entities;b=o(b)||q;k=n.makeMap(k.replace(/\+/g,","));if(k.named&&k.numeric)return c;if(k.named){if(b)return l;return s.encodeNamed}if(k.numeric)return s.encodeNumeric;return s.encodeRaw},decode:function(k){return k.replace(d,function(b,c,l){if(c){l=parseInt(l,c.length===2?16:10);if(l>65535){l-=65536;return String.fromCharCode(55296+(l>>10),
56320+(l&1023))}else return j[l]||String.fromCharCode(l)}return a[b]||q[b]||p(b)})}}})(tinymce);
tinymce.html.Styles=function(n,p){function o(j,k,b,c){function l(s){s=parseInt(s).toString(16);return s.length>1?s:"0"+s}return"#"+l(k)+l(b)+l(c)}var q=/rgb\s*\(\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\s*\)/gi,e=/(?:url(?:(?:\(\s*\"([^\"]+)\"\s*\))|(?:\(\s*\'([^\']+)\'\s*\))|(?:\(\s*([^)\s]+)\s*\))))|(?:\'([^\']+)\')|(?:\"([^\"]+)\")/gi,a=/\s*([^:]+):\s*([^;]+);?/g,g=/\s+$/,h,f={},d;n=n||{};d="\\\" \\' \\; \\: ; : \ufeff".split(" ");for(h=0;h<d.length;h++){f[d[h]]="\ufeff"+h;f["\ufeff"+h]=d[h]}return{toHex:function(j){return j.replace(q,
o)},parse:function(j){function k(y,C){var F,H;if(F=i[y+"-top"+C]){H=i[y+"-right"+C];if(F==H){F=i[y+"-bottom"+C];if(H==F){H=i[y+"-left"+C];if(F==H){i[y+C]=H;delete i[y+"-top"+C];delete i[y+"-right"+C];delete i[y+"-bottom"+C];delete i[y+"-left"+C]}}}}}function b(y){var C=i[y],F;if(!(!C||C.indexOf(" ")<0)){C=C.split(" ");for(F=C.length;F--;)if(C[F]!==C[0])return false;i[y]=C[0];return true}}function c(y,C,F,H){if(b(C))if(b(F))if(b(H)){i[y]=i[C]+" "+i[F]+" "+i[H];delete i[C];delete i[F];delete i[H]}}
function l(y){u=true;return f[y]}function s(y,C){if(u)y=y.replace(/\uFEFF[0-9]/g,function(F){return f[F]});C||(y=y.replace(/\\([\'\";:])/g,"$1"));return y}var i={},m,r,t,u,v=n.url_converter,x=n.url_converter_scope||this;if(j){for(j=j.replace(/\\[\"\';:\uFEFF]/g,l).replace(/\"[^\"]+\"|\'[^\']+\'/g,function(y){return y.replace(/[;:]/g,l)});m=a.exec(j);){r=m[1].replace(g,"").toLowerCase();t=m[2].replace(g,"");if(r&&t.length>0){if(r==="font-weight"&&t==="700")t="bold";else if(r==="color"||r==="background-color")t=
t.toLowerCase();t=t.replace(q,o);t=t.replace(e,function(y,C,F,H,M,P){if(M=M||P){M=s(M);return"'"+M.replace(/\'/g,"\\'")+"'"}C=s(C||F||H);if(v)C=v.call(x,C,"style");return"url('"+C.replace(/\'/g,"\\'")+"')"});i[r]=u?s(t,true):t}a.lastIndex=m.index+m[0].length}k("border","");k("border","-width");k("border","-color");k("border","-style");k("padding","");k("margin","");c("border","border-width","border-style","border-color");i.border==="medium none"&&delete i.border}return i},serialize:function(j,k){function b(s){var i,
m,r,t;if(i=p.styles[s]){m=0;for(r=i.length;m<r;m++){s=i[m];t=j[s];if(t!==void 0&&t.length>0)c+=(c.length>0?" ":"")+s+": "+t+";"}}}var c="",l;if(k&&p&&p.styles){b("*");b(k)}else for(l in j){k=j[l];if(k!==void 0&&k.length>0)c+=(c.length>0?" ":"")+l+": "+k+";"}return c}}};
(function(n){function p(c,l){return c.split(l||",")}function o(c,l){function s(r){return r.replace(/[A-Z]+/g,function(t){return s(c[t])})}var i,m={};for(i in c)if(c.hasOwnProperty(i))c[i]=s(c[i]);s(l).replace(/#/g,"#text").replace(/(\w+)\[([^\]]+)\]\[([^\]]*)\]/g,function(r,t,u,v){u=p(u,"|");m[t]={attributes:k(u),attributesOrder:u,children:k(v,"|",{"#comment":{}})}});return m}var q={},e,a,g,h,f={},d,j,k=n.makeMap,b=n.each;a="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";
a=k(a,",",k(a.toUpperCase()));q=o({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]");
e=k("checked,compact,declare,defer,disabled,ismap,multiple,nohref,noresize,noshade,nowrap,readonly,selected,autoplay,loop,controls");g=k("area,base,basefont,br,col,frame,hr,img,input,isindex,link,meta,param,embed,source");h=n.extend(k("td,th,iframe,video,audio,object"),g);d=k("pre,script,style,textarea");j=k("colgroup,dd,dt,li,options,p,td,tfoot,th,thead,tr");n.html.Schema=function(c){function l(F){return new RegExp("^"+F.replace(/([?+*])/g,".$1")+"$")}function s(F){var H,M,P,R,K,S,D,Y,Z,ba,ka,ha,
na,fa,W,$,la,sa,ra=/^([#+-])?([^\[\/]+)(?:\/([^\[]+))?(?:\[([^\]]+)\])?$/,z=/^([!\-])?(\w+::\w+|[^=:<]+)?(?:([=:<])(.*))?$/,A=/[*?+]/;if(F){F=p(F);if(u["@"]){$=u["@"].attributes;la=u["@"].attributesOrder}H=0;for(M=F.length;H<M;H++)if(K=ra.exec(F[H])){fa=K[1];Z=K[2];W=K[3];Y=K[4];ha={};na=[];S={attributes:ha,attributesOrder:na};if(fa==="#")S.paddEmpty=true;if(fa==="-")S.removeEmpty=true;if($){for(sa in $)ha[sa]=$[sa];na.push.apply(na,la)}if(Y){Y=p(Y,"|");P=0;for(R=Y.length;P<R;P++)if(K=z.exec(Y[P])){D=
{};ka=K[1];ba=K[2].replace(/::/g,":");fa=K[3];K=K[4];if(ka==="!"){S.attributesRequired=S.attributesRequired||[];S.attributesRequired.push(ba);D.required=true}if(ka==="-"){delete ha[ba];na.splice(n.inArray(na,ba),1)}else{if(fa){if(fa==="="){S.attributesDefault=S.attributesDefault||[];S.attributesDefault.push({name:ba,value:K});D.defaultValue=K}if(fa===":"){S.attributesForced=S.attributesForced||[];S.attributesForced.push({name:ba,value:K});D.forcedValue=K}if(fa==="<")D.validValues=k(K,"?")}if(A.test(ba)){S.attributePatterns=
S.attributePatterns||[];D.pattern=l(ba);S.attributePatterns.push(D)}else{ha[ba]||na.push(ba);ha[ba]=D}}}}if(!$&&Z=="@"){$=ha;la=na}if(W){S.outputName=Z;u[W]=S}if(A.test(Z)){S.pattern=l(Z);x.push(S)}else u[Z]=S}}}function i(F){u={};x=[];s(F);b(q,function(H,M){v[M]=H.children})}function m(F){var H=/^(~)?(.+)$/;F&&b(p(F),function(M){M=H.exec(M);var P=M[1]==="~",R=P?"span":"div",K=M[2];v[K]=v[R];f[K]=R;P||(a[K]={});b(v,function(S){if(S[R])S[K]=S[R]})})}function r(F){var H=/^([+\-]?)(\w+)\[([^\]]+)\]$/;
F&&b(p(F),function(M){M=H.exec(M);var P,R;if(M){P=(R=M[1])?v[M[2]]:(v[M[2]]={"#comment":{}});P=v[M[2]];b(p(M[3],"|"),function(K){if(R==="-")delete P[K];else P[K]={}})}})}function t(F){var H=u[F],M;if(H)return H;for(M=x.length;M--;){H=x[M];if(H.pattern.test(F))return H}}var u={},v={},x=[],y,C;c=c||{};if(c.verify_html===false)c.valid_elements="*[*]";if(c.valid_styles){y={};b(c.valid_styles,function(F,H){y[H]=n.explode(F)})}C=c.whitespace_elements?k(c.whitespace_elements):d;if(c.valid_elements)i(c.valid_elements);
else{b(q,function(F,H){u[H]={attributes:F.attributes,attributesOrder:F.attributesOrder};v[H]=F.children});b(p("strong/b,em/i"),function(F){F=p(F,"/");u[F[1]].outputName=F[0]});u.img.attributesDefault=[{name:"alt",value:""}];b(p("ol,ul,sub,sup,blockquote,span,font,a,table,tbody,tr"),function(F){u[F].removeEmpty=true});b(p("p,h1,h2,h3,h4,h5,h6,th,td,pre,div,address,caption"),function(F){u[F].paddEmpty=true})}m(c.custom_elements);r(c.valid_children);s(c.extended_valid_elements);r("+ol[ul|ol],+ul[ul|ol]");
t("span")||s("span[!data-mce-type|*]");c.invalid_elements&&n.each(n.explode(c.invalid_elements),function(F){u[F]&&delete u[F]});this.children=v;this.styles=y;this.getBoolAttrs=function(){return e};this.getBlockElements=function(){return a};this.getShortEndedElements=function(){return g};this.getSelfClosingElements=function(){return j};this.getNonEmptyElements=function(){return h};this.getWhiteSpaceElements=function(){return C};this.isValidChild=function(F,H){F=v[F];return!!(F&&F[H])};this.getElementRule=
t;this.getCustomElements=function(){return f};this.addValidElements=s;this.setValidElements=i;this.addCustomElements=m;this.addValidChildren=r};n.html.Schema.boolAttrMap=e;n.html.Schema.blockElementsMap=a})(tinymce);
(function(n){n.html.SaxParser=function(p,o){var q=this,e=function(){};p=p||{};q.schema=o=o||new n.html.Schema;if(p.fix_self_closing!==false)p.fix_self_closing=true;n.each("comment cdata text start end pi doctype".split(" "),function(a){if(a)q[a]=p[a]||e});q.parse=function(a){function g(fa){var W,$;for(W=b.length;W--;)if(b[W].name===fa)break;if(W>=0){for($=b.length-1;$>=W;$--){fa=b[$];fa.valid&&h.end(fa.name)}b.length=W}}var h=this,f,d=0,j,k,b=[],c,l,s,i,m,r,t,u,v,x,y,C,F,H,M,P,R,K,S,D,Y,Z,ba=0,ka=
n.html.Entities.decode,ha,na;D=new RegExp("<(?:(?:!--([\\w\\W]*?)--\>)|(?:!\\[CDATA\\[([\\w\\W]*?)\\]\\]>)|(?:!DOCTYPE([\\w\\W]*?)>)|(?:\\?([^\\s\\/<>]+) ?([\\w\\W]*?)[?/]>)|(?:\\/([^>]+)>)|(?:([^\\s\\/<>]+)((?:\\s+[^\"'>]+(?:(?:\"[^\"]*\")|(?:'[^']*')|[^>]*))*|\\/)>))","g");Y=/([\w:\-]+)(?:\s*=\s*(?:(?:\"((?:\\.|[^\"])*)\")|(?:\'((?:\\.|[^\'])*)\')|([^>\s]+)))?/g;Z={script:/<\/script[^>]*>/gi,style:/<\/style[^>]*>/gi,noscript:/<\/noscript[^>]*>/gi};r=o.getShortEndedElements();S=o.getSelfClosingElements();
t=o.getBoolAttrs();u=p.validate;m=p.remove_internals;ha=p.fix_self_closing;na=n.isIE;for(F=/^:/;f=D.exec(a);){d<f.index&&h.text(ka(a.substr(d,f.index-d)));if(j=f[6]){j=j.toLowerCase();if(na&&F.test(j))j=j.substr(1);g(j)}else if(j=f[7]){j=j.toLowerCase();if(na&&F.test(j))j=j.substr(1);d=j in r;ha&&S[j]&&b.length>0&&b[b.length-1].name===j&&g(j);if(!u||(v=o.getElementRule(j))){x=true;if(u){H=v.attributes;M=v.attributePatterns}if(C=f[8]){if((i=C.indexOf("data-mce-type")!==-1)&&m)x=false;c=[];c.map={};
C.replace(Y,function(fa,W,$,la,sa){W=W.toLowerCase();$=W in t?W:ka($||la||sa||"");if(u&&!i&&W.indexOf("data-")!==0){fa=H[W];if(!fa&&M){for(la=M.length;la--;){fa=M[la];if(fa.pattern.test(W))break}if(la===-1)fa=null}if(!fa)return;if(fa.validValues&&!($ in fa.validValues))return}c.map[W]=$;c.push({name:W,value:$})})}else{c=[];c.map={}}if(u&&!i){P=v.attributesRequired;R=v.attributesDefault;if(K=v.attributesForced)for(k=K.length;k--;){y=K[k];s=y.name;y=y.value;if(y==="{$uid}")y="mce_"+ba++;c.map[s]=y;
c.push({name:s,value:y})}if(R)for(k=R.length;k--;){y=R[k];s=y.name;if(!(s in c.map)){y=y.value;if(y==="{$uid}")y="mce_"+ba++;c.map[s]=y;c.push({name:s,value:y})}}if(P){for(k=P.length;k--;)if(P[k]in c.map)break;if(k===-1)x=false}if(c.map["data-mce-bogus"])x=false}x&&h.start(j,c,d)}else x=false;if(k=Z[j]){k.lastIndex=d=f.index+f[0].length;if(f=k.exec(a)){if(x)l=a.substr(d,f.index-d);d=f.index+f[0].length}else{l=a.substr(d);d=a.length}x&&l.length>0&&h.text(l,true);x&&h.end(j);D.lastIndex=d;continue}if(!d)if(!C||
C.indexOf("/")!=C.length-1)b.push({name:j,valid:x});else x&&h.end(j)}else if(j=f[1])h.comment(j);else if(j=f[2])h.cdata(j);else if(j=f[3])h.doctype(j);else if(j=f[4])h.pi(j,f[5]);d=f.index+f[0].length}d<a.length&&h.text(ka(a.substr(d)));for(k=b.length-1;k>=0;k--){j=b[k];j.valid&&h.end(j.name)}}}})(tinymce);
(function(n){function p(a,g,h){var f;f=h?"lastChild":"firstChild";h=h?"prev":"next";if(a[f])return a[f];if(a!==g){if(f=a[h])return f;for(a=a.parent;a&&a!==g;a=a.parent)if(f=a[h])return f}}function o(a,g){this.name=a;this.type=g;if(g===1){this.attributes=[];this.attributes.map={}}}var q=/^[ \t\r\n]*$/,e={"#text":3,"#comment":8,"#cdata":4,"#pi":7,"#doctype":10,"#document-fragment":11};n.extend(o.prototype,{replace:function(a){a.parent&&a.remove();this.insert(a,this);this.remove();return this},attr:function(a,
g){var h,f;if(typeof a!=="string"){for(f in a)this.attr(f,a[f]);return this}if(h=this.attributes)if(g!==void 0){if(g===null){if(a in h.map){delete h.map[a];for(f=h.length;f--;)if(h[f].name===a){h.splice(f,1);return this}}return this}if(a in h.map)for(f=h.length;f--;){if(h[f].name===a){h[f].value=g;break}}else h.push({name:a,value:g});h.map[a]=g;return this}else return h.map[a]},clone:function(){var a=new o(this.name,this.type),g,h,f,d,j;if(f=this.attributes){j=[];j.map={};g=0;for(h=f.length;g<h;g++){d=
f[g];if(d.name!=="id"){j[j.length]={name:d.name,value:d.value};j.map[d.name]=d.value}}a.attributes=j}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,g;for(a=this.firstChild;a;){g=a.next;this.insert(a,this,true);a=g}this.remove()},remove:function(){var a=this.parent,g=this.next,h=this.prev;if(a){if(a.firstChild===this){if(a.firstChild=g)g.prev=null}else h.next=g;if(a.lastChild===this){if(a.lastChild=
h)h.next=null}else g.prev=h;this.parent=this.next=this.prev=null}return this},append:function(a){var g;a.parent&&a.remove();if(g=this.lastChild){g.next=a;a.prev=g;this.lastChild=a}else this.lastChild=this.firstChild=a;a.parent=this;return a},insert:function(a,g,h){var f;a.parent&&a.remove();f=g.parent||this;if(h){if(g===f.firstChild)f.firstChild=a;else g.prev.next=a;a.prev=g.prev;a.next=g;g.prev=a}else{if(g===f.lastChild)f.lastChild=a;else g.next.prev=a;a.next=g.next;a.prev=g;g.next=a}a.parent=f;
return a},getAll:function(a){var g,h=[];for(g=this.firstChild;g;g=p(g,this))g.name===a&&h.push(g);return h},empty:function(){var a,g,h;if(this.firstChild){a=[];for(h=this.firstChild;h;h=p(h,this))a.push(h);for(g=a.length;g--;){h=a[g];h.parent=h.firstChild=h.lastChild=h.next=h.prev=null}}this.firstChild=this.lastChild=null;return this},isEmpty:function(a){var g=this.firstChild,h,f;if(g){do{if(g.type===1){if(g.attributes.map["data-mce-bogus"])continue;if(a[g.name])return false;for(h=g.attributes.length;h--;){f=
g.attributes[h].name;if(f==="name"||f.indexOf("data-")===0)return false}}if(g.type===3&&!q.test(g.value))return false}while(g=p(g,this))}return true},walk:function(a){return p(this,null,a)}});n.extend(o,{create:function(a,g){var h;a=new o(a,e[a]||1);if(g)for(h in g)a.attr(h,g[h]);return a}});n.html.Node=o})(tinymce);
(function(n){var p=n.html.Node;n.html.DomParser=function(o,q){function e(j){var k,b,c,l,s,i,m,r,t,u,v;u=n.makeMap("tr,td,th,tbody,thead,tfoot,table");t=q.getNonEmptyElements();for(k=0;k<j.length;k++){b=j[k];if(b.parent){l=[b];for(c=b.parent;c&&!q.isValidChild(c.name,b.name)&&!u[c.name];c=c.parent)l.push(c);if(c&&l.length>1){l.reverse();s=i=a.filterNode(l[0].clone());for(r=0;r<l.length-1;r++){if(q.isValidChild(i.name,l[r].name)){m=a.filterNode(l[r].clone());i.append(m)}else m=i;for(i=l[r].firstChild;i&&
i!=l[r+1];){v=i.next;m.append(i);i=v}i=m}if(s.isEmpty(t))c.insert(b,l[0],true);else{c.insert(s,l[0],true);c.insert(b,s)}c=l[0];if(c.isEmpty(t)||c.firstChild===c.lastChild&&c.firstChild.name==="br")c.empty().remove()}else if(b.parent)if(b.name==="li")if((c=b.prev)&&(c.name==="ul"||c.name==="ul"))c.append(b);else(c=b.next)&&(c.name==="ul"||c.name==="ul")?c.insert(b,c.firstChild,true):b.wrap(a.filterNode(new p("ul",1)));else if(q.isValidChild(b.parent.name,"div")&&q.isValidChild("div",b.name))b.wrap(a.filterNode(new p("div",
1)));else b.name==="style"||b.name==="script"?b.empty().remove():b.unwrap()}}}var a=this,g={},h=[],f={},d={};o=o||{};o.validate="validate"in o?o.validate:true;o.root_name=o.root_name||"body";a.schema=q=q||new n.html.Schema;a.filterNode=function(j){var k,b,c;if(b in g)if(c=f[b])c.push(j);else f[b]=[j];for(k=h.length;k--;){b=h[k].name;if(b in j.attributes.map)if(c=d[b])c.push(j);else d[b]=[j]}return j};a.addNodeFilter=function(j,k){n.each(n.explode(j),function(b){var c=g[b];c||(g[b]=c=[]);c.push(k)})};
a.addAttributeFilter=function(j,k){n.each(n.explode(j),function(b){var c;for(c=0;c<h.length;c++)if(h[c].name===b){h[c].callbacks.push(k);return}h.push({name:b,callbacks:[k]})})};a.parse=function(j,k){function b(){for(var D=i.firstChild,Y,Z;D;){Y=D.next;if(D.type==3||D.type==1&&D.name!=="p"&&!y[D.name]&&!D.attr("data-mce-type")){if(!Z){Z=c(S,1);i.insert(Z,D)}Z.append(D)}else Z=null;D=Y}}function c(D,Y){Y=new p(D,Y);var Z;if(D in g)if(Z=f[D])Z.push(Y);else f[D]=[Y];return Y}function l(D){var Y;for(D=
D.prev;D&&D.type===3;){Y=D.value.replace(H,"");if(Y.length>0){D.value=Y;D=D.prev}else{Y=D.prev;D.remove();D=Y}}}var s,i,m,r,t,u,v,x,y,C,F=[],H,M,P,R,K,S;k=k||{};f={};d={};y=n.extend(n.makeMap("script,style,head,html,body,title,meta,param"),q.getBlockElements());K=q.getNonEmptyElements();R=q.children;x=o.validate;S="forced_root_block"in k?k.forced_root_block:o.forced_root_block;P=q.getWhiteSpaceElements();C=/^[ \t\r\n]+/;H=/[ \t\r\n]+$/;M=/[ \t\r\n]+/g;s=new n.html.SaxParser({validate:x,fix_self_closing:!x,
cdata:function(D){m.append(c("#cdata",4)).value=D},text:function(D,Y){var Z;if(!P[m.name]){D=D.replace(M," ");if(m.lastChild&&y[m.lastChild.name])D=D.replace(C,"")}if(D.length!==0){Z=c("#text",3);Z.raw=!!Y;m.append(Z).value=D}},comment:function(D){m.append(c("#comment",8)).value=D},pi:function(D,Y){m.append(c(D,7)).value=Y;l(m)},doctype:function(D){m.append(c("#doctype",10)).value=D;l(m)},start:function(D,Y,Z){var ba,ka,ha;if(ba=x?q.getElementRule(D):{}){ba=c(ba.outputName||D,1);ba.attributes=Y;ba.shortEnded=
Z;m.append(ba);(ka=R[m.name])&&R[ba.name]&&!ka[ba.name]&&F.push(ba);for(ka=h.length;ka--;){ha=h[ka].name;if(ha in Y.map)if(v=d[ha])v.push(ba);else d[ha]=[ba]}y[D]&&l(ba);Z||(m=ba)}},end:function(D){var Y,Z;if(Y=x?q.getElementRule(D):{}){if(y[D]){if(!P[m.name]){for(D=m.firstChild;D&&D.type===3;){Z=D.value.replace(C,"");if(Z.length>0){D.value=Z;D=D.next}else{Z=D.next;D.remove();D=Z}}for(D=m.lastChild;D&&D.type===3;){Z=D.value.replace(H,"");if(Z.length>0){D.value=Z;D=D.prev}else{Z=D.prev;D.remove();
D=Z}}}if((D=m.prev)&&D.type===3){Z=D.value.replace(C,"");if(Z.length>0)D.value=Z;else D.remove()}}if(Y.removeEmpty||Y.paddEmpty)if(m.isEmpty(K))if(Y.paddEmpty)m.empty().append(new p("#text","3")).value="\u00a0";else if(!m.attributes.map.name){Y=m.parent;m.empty().remove();m=Y;return}m=m.parent}}},q);i=m=new p(k.context||o.root_name,11);s.parse(j);if(x&&F.length)if(k.context)k.invalid=true;else e(F);S&&i.name=="body"&&b();if(!k.invalid){for(u in f){v=g[u];j=f[u];for(t=j.length;t--;)j[t].parent||j.splice(t,
1);s=0;for(r=v.length;s<r;s++)v[s](j,u,k)}s=0;for(r=h.length;s<r;s++){v=h[s];if(v.name in d){j=d[v.name];for(t=j.length;t--;)j[t].parent||j.splice(t,1);t=0;for(u=v.callbacks.length;t<u;t++)v.callbacks[t](j,v.name,k)}}}return i};o.remove_trailing_brs&&a.addNodeFilter("br",function(j){var k,b=j.length,c,l=q.getBlockElements(),s=q.getNonEmptyElements(),i,m,r;l.body=1;for(k=0;k<b;k++){c=j[k];i=c.parent;if(l[c.parent.name]&&c===i.lastChild){for(m=c.prev;m;){r=m.name;if(r!=="span"||m.attr("data-mce-type")!==
"bookmark"){if(r!=="br")break;if(r==="br"){c=null;break}}m=m.prev}if(c){c.remove();if(i.isEmpty(s))if(elementRule=q.getElementRule(i.name))if(elementRule.removeEmpty)i.remove();else if(elementRule.paddEmpty)i.empty().append(new n.html.Node("#text",3)).value="\u00a0"}}}})}})(tinymce);
tinymce.html.Writer=function(n){var p=[],o,q,e,a,g;n=n||{};o=n.indent;q=tinymce.makeMap(n.indent_before||"");e=tinymce.makeMap(n.indent_after||"");a=tinymce.html.Entities.getEncodeFunc(n.entity_encoding||"raw",n.entities);g=n.element_format=="html";return{start:function(h,f,d){var j,k,b;if(o&&q[h]&&p.length>0){j=p[p.length-1];j.length>0&&j!=="\n"&&p.push("\n")}p.push("<",h);if(f){j=0;for(k=f.length;j<k;j++){b=f[j];p.push(" ",b.name,'="',a(b.value,true),'"')}}p[p.length]=!d||g?">":" />";if(d&&o&&e[h]&&
p.length>0){j=p[p.length-1];j.length>0&&j!=="\n"&&p.push("\n")}},end:function(h){p.push("</",h,">");if(o&&e[h]&&p.length>0){h=p[p.length-1];h.length>0&&h!=="\n"&&p.push("\n")}},text:function(h,f){if(h.length>0)p[p.length]=f?h:a(h)},cdata:function(h){p.push("<![CDATA[",h,"]]\>")},comment:function(h){p.push("<!--",h,"--\>")},pi:function(h,f){f?p.push("<?",h," ",f,"?>"):p.push("<?",h,"?>");o&&p.push("\n")},doctype:function(h){p.push("<!DOCTYPE",h,">",o?"\n":"")},reset:function(){p.length=0},getContent:function(){return p.join("").replace(/\n$/,
"")}}};
(function(n){n.html.Serializer=function(p,o){var q=new n.html.Writer(p);p=p||{};p.validate="validate"in p?p.validate:true;this.schema=o=o||new n.html.Schema;this.writer=q;this.serialize=function(e){function a(f){var d=g[f.type],j,k,b,c,l,s,i,m;if(d)d(f);else{d=f.name;j=f.shortEnded;k=f.attributes;if(h&&k&&k.length>1){l=[];l.map={};m=o.getElementRule(f.name);s=0;for(i=m.attributesOrder.length;s<i;s++){b=m.attributesOrder[s];if(b in k.map){c=k.map[b];l.map[b]=c;l.push({name:b,value:c})}}s=0;for(i=k.length;s<
i;s++){b=k[s].name;if(!(b in l.map)){c=k.map[b];l.map[b]=c;l.push({name:b,value:c})}}k=l}q.start(f.name,k,j);if(!j){if(f=f.firstChild){do a(f);while(f=f.next)}q.end(d)}}}var g,h;h=p.validate;g={3:function(f){q.text(f.value,f.raw)},8:function(f){q.comment(f.value)},7:function(f){q.pi(f.name,f.value)},10:function(f){q.doctype(f.value)},4:function(f){q.cdata(f.value)},11:function(f){if(f=f.firstChild){do a(f);while(f=f.next)}}};q.reset();e.type==1&&!p.inner?a(e):g[11](e);return q.getContent()}}})(tinymce);
(function(n){var p=n.each,o=n.is,q=n.isWebKit,e=n.isIE,a=n.html.Entities,g=/^([a-z0-9],?)+$/i,h=n.html.Schema.blockElementsMap,f=/^[ \t\r\n]*$/;n.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(d,
j){var k;this.doc=d;this.win=window;this.files={};this.cssFlicker=false;this.counter=0;this.stdMode=!n.isIE||d.documentMode>=8;this.boxModel=!n.isIE||d.compatMode=="CSS1Compat"||this.stdMode;this.hasOuterHTML="outerHTML"in d.createElement("a");this.settings=j=n.extend({keep_values:false,hex_colors:1},j);this.schema=j.schema;this.styles=new n.html.Styles({url_converter:j.url_converter,url_converter_scope:j.url_converter_scope},j.schema);if(n.isIE6)try{d.execCommand("BackgroundImageCache",false,true)}catch(b){this.cssFlicker=
true}if(e&&j.schema){"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(c){d.createElement(c)});for(k in j.schema.getCustomElements())d.createElement(k)}n.addUnload(this.destroy,this)},getRoot:function(){var d=this.settings;return d&&this.get(d.root_element)||this.doc.body},getViewPort:function(d){var j;d=!d?this.win:d;j=d.document;j=this.boxModel?j.documentElement:j.body;return{x:d.pageXOffset||
j.scrollLeft,y:d.pageYOffset||j.scrollTop,w:d.innerWidth||j.clientWidth,h:d.innerHeight||j.clientHeight}},getRect:function(d){var j;d=this.get(d);j=this.getPos(d);d=this.getSize(d);return{x:j.x,y:j.y,w:d.w,h:d.h}},getSize:function(d){var j,k;d=this.get(d);j=this.getStyle(d,"width");k=this.getStyle(d,"height");if(j.indexOf("px")===-1)j=0;if(k.indexOf("px")===-1)k=0;return{w:parseInt(j)||d.offsetWidth||d.clientWidth,h:parseInt(k)||d.offsetHeight||d.clientHeight}},getParent:function(d,j,k){return this.getParents(d,
j,k,false)},getParents:function(d,j,k,b){var c=this,l,s=c.settings,i=[];d=c.get(d);b=b===undefined;if(s.strict_root)k=k||c.getRoot();if(o(j,"string")){l=j;j=j==="*"?function(m){return m.nodeType==1}:function(m){return c.is(m,l)}}for(;d;){if(d==k||!d.nodeType||d.nodeType===9)break;if(!j||j(d))if(b)i.push(d);else return d;d=d.parentNode}return b?i:null},get:function(d){var j;if(d&&this.doc&&typeof d=="string"){j=d;if((d=this.doc.getElementById(d))&&d.id!==j)return this.doc.getElementsByName(j)[1]}return d},
getNext:function(d,j){return this._findSib(d,j,"nextSibling")},getPrev:function(d,j){return this._findSib(d,j,"previousSibling")},select:function(d,j){return n.dom.Sizzle(d,this.get(j)||this.get(this.settings.root_element)||this.doc,[])},is:function(d,j){var k;if(d.length===undefined){if(j==="*")return d.nodeType==1;if(g.test(j)){j=j.toLowerCase().split(/,/);d=d.nodeName.toLowerCase();for(k=j.length-1;k>=0;k--)if(j[k]==d)return true;return false}}return n.dom.Sizzle.matches(j,d.nodeType?[d]:d).length>
0},add:function(d,j,k,b,c){var l=this;return this.run(d,function(s){var i;i=o(j,"string")?l.doc.createElement(j):j;l.setAttribs(i,k);if(b)b.nodeType?i.appendChild(b):l.setHTML(i,b);return!c?s.appendChild(i):i})},create:function(d,j,k){return this.add(this.doc.createElement(d),d,j,k,1)},createHTML:function(d,j,k){var b="",c;b+="<"+d;for(c in j)if(j.hasOwnProperty(c))b+=" "+c+'="'+this.encode(j[c])+'"';if(typeof k!="undefined")return b+">"+k+"</"+d+">";return b+" />"},remove:function(d,j){return this.run(d,
function(k){var b,c=k.parentNode;if(!c)return null;if(j)for(;b=k.firstChild;)!n.isIE||b.nodeType!==3||b.nodeValue?c.insertBefore(b,k):k.removeChild(b);return c.removeChild(k)})},setStyle:function(d,j,k){var b=this;return b.run(d,function(c){var l;l=c.style;j=j.replace(/-(\D)/g,function(s,i){return i.toUpperCase()});if(b.pixelStyles.test(j)&&(n.is(k,"number")||/^[\-0-9\.]+$/.test(k)))k+="px";switch(j){case "opacity":if(e){l.filter=k===""?"":"alpha(opacity="+k*100+")";if(!d.currentStyle||!d.currentStyle.hasLayout)l.display=
"inline-block"}l[j]=l["-moz-opacity"]=l["-khtml-opacity"]=k||"";break;case "float":e?(l.styleFloat=k):(l.cssFloat=k);break;default:l[j]=k||""}b.settings.update_styles&&b.setAttrib(c,"data-mce-style")})},getStyle:function(d,j,k){if(d=this.get(d)){if(this.doc.defaultView&&k){j=j.replace(/[A-Z]/g,function(c){return"-"+c});try{return this.doc.defaultView.getComputedStyle(d,null).getPropertyValue(j)}catch(b){return null}}j=j.replace(/-(\D)/g,function(c,l){return l.toUpperCase()});if(j=="float")j=e?"styleFloat":
"cssFloat";if(d.currentStyle&&k)return d.currentStyle[j];return d.style?d.style[j]:undefined}},setStyles:function(d,j){var k=this,b=k.settings,c;c=b.update_styles;b.update_styles=0;p(j,function(l,s){k.setStyle(d,s,l)});b.update_styles=c;b.update_styles&&k.setAttrib(d,b.cssText)},removeAllAttribs:function(d){return this.run(d,function(j){var k,b=j.attributes;for(k=b.length-1;k>=0;k--)j.removeAttributeNode(b.item(k))})},setAttrib:function(d,j,k){var b=this;if(d&&j){if(b.settings.strict)j=j.toLowerCase();
return this.run(d,function(c){var l=b.settings;if(k!==null)switch(j){case "style":if(!o(k,"string")){p(k,function(s,i){b.setStyle(c,i,s)});return}if(l.keep_values)k&&!b._isRes(k)?c.setAttribute("data-mce-style",k,2):c.removeAttribute("data-mce-style",2);c.style.cssText=k;break;case "class":c.className=k||"";break;case "src":case "href":if(l.keep_values){if(l.url_converter)k=l.url_converter.call(l.url_converter_scope||b,k,j,c);b.setAttrib(c,"data-mce-"+j,k,2)}break;case "shape":c.setAttribute("data-mce-style",
k);break}o(k)&&k!==null&&k.length!==0?c.setAttribute(j,""+k,2):c.removeAttribute(j,2)})}},setAttribs:function(d,j){var k=this;return this.run(d,function(b){p(j,function(c,l){k.setAttrib(b,l,c)})})},getAttrib:function(d,j,k){var b;d=this.get(d);if(!d||d.nodeType!==1)return k===void 0?false:k;o(k)||(k="");if(/^(src|href|style|coords|shape)$/.test(j))if(b=d.getAttribute("data-mce-"+j))return b;if(e&&this.props[j])b=(b=d[this.props[j]])&&b.nodeValue?b.nodeValue:b;b||(b=d.getAttribute(j,2));if(/^(checked|compact|declare|defer|disabled|ismap|multiple|nohref|noshade|nowrap|readonly|selected)$/.test(j)){if(d[this.props[j]]===
true&&b==="")return j;return b?j:""}if(d.nodeName==="FORM"&&d.getAttributeNode(j))return d.getAttributeNode(j).nodeValue;if(j==="style")if(b=b||d.style.cssText){b=this.serializeStyle(this.parseStyle(b),d.nodeName);this.settings.keep_values&&!this._isRes(b)&&d.setAttribute("data-mce-style",b)}if(q&&j==="class"&&b)b=b.replace(/(apple|webkit)\-[a-z\-]+/gi,"");if(e)switch(j){case "rowspan":case "colspan":if(b===1)b="";break;case "size":if(b==="+0"||b===20||b===0)b="";break;case "width":case "height":case "vspace":case "checked":case "disabled":case "readonly":if(b===
0)b="";break;case "hspace":if(b===-1)b="";break;case "maxlength":case "tabindex":if(b===32768||b===2147483647||b==="32768")b="";break;case "multiple":case "compact":case "noshade":case "nowrap":if(b===65535)return j;return k;case "shape":b=b.toLowerCase();break;default:if(j.indexOf("on")===0&&b)b=n._replace(/^function\s+\w+\(\)\s+\{\s+(.*)\s+\}$/,"$1",""+b)}return b!==void 0&&b!==null&&b!==""?""+b:k},getPos:function(d,j){var k=0,b=0,c=this.doc;d=this.get(d);j=j||c.body;if(d){if(d.getBoundingClientRect){d=
d.getBoundingClientRect();j=this.boxModel?c.documentElement:c.body;k=d.left+(c.documentElement.scrollLeft||c.body.scrollLeft)-j.clientTop;b=d.top+(c.documentElement.scrollTop||c.body.scrollTop)-j.clientLeft;return{x:k,y:b}}for(c=d;c&&c!=j&&c.nodeType;){k+=c.offsetLeft||0;b+=c.offsetTop||0;c=c.offsetParent}for(c=d.parentNode;c&&c!=j&&c.nodeType;){k-=c.scrollLeft||0;b-=c.scrollTop||0;c=c.parentNode}}return{x:k,y:b}},parseStyle:function(d){return this.styles.parse(d)},serializeStyle:function(d,j){return this.styles.serialize(d,
j)},loadCSS:function(d){var j=this,k=j.doc,b;d||(d="");b=j.select("head")[0];p(d.split(","),function(c){var l;if(!j.files[c]){j.files[c]=true;l=j.create("link",{rel:"stylesheet",href:n._addVer(c)});if(e&&k.documentMode&&k.recalc)l.onload=function(){k.recalc&&k.recalc();l.onload=null};b.appendChild(l)}})},addClass:function(d,j){return this.run(d,function(k){var b;if(!j)return 0;if(this.hasClass(k,j))return k.className;b=this.removeClass(k,j);return k.className=(b!=""?b+" ":"")+j})},removeClass:function(d,
j){var k=this,b;return k.run(d,function(c){var l;if(k.hasClass(c,j)){b||(b=new RegExp("(^|\\s+)"+j+"(\\s+|$)","g"));l=c.className.replace(b," ");l=n.trim(l!=" "?l:"");c.className=l;if(!l){c.removeAttribute("class");c.removeAttribute("className")}return l}return c.className})},hasClass:function(d,j){d=this.get(d);if(!d||!j)return false;return(" "+d.className+" ").indexOf(" "+j+" ")!==-1},show:function(d){return this.setStyle(d,"display","block")},hide:function(d){return this.setStyle(d,"display","none")},
isHidden:function(d){d=this.get(d);return!d||d.style.display=="none"||this.getStyle(d,"display")=="none"},uniqueId:function(d){return(!d?"mce_":d)+this.counter++},setHTML:function(d,j){var k=this;return k.run(d,function(b){if(e){for(;b.firstChild;)b.removeChild(b.firstChild);try{b.innerHTML="<br />"+j;b.removeChild(b.firstChild)}catch(c){b=k.create("div");b.innerHTML="<br />"+j;p(b.childNodes,function(l,s){s&&b.appendChild(l)})}}else b.innerHTML=j;return j})},getOuterHTML:function(d){var j;d=this.get(d);
if(!d)return null;if(d.nodeType===1&&this.hasOuterHTML)return d.outerHTML;j=(d.ownerDocument||this.doc).createElement("body");j.appendChild(d.cloneNode(true));return j.innerHTML},setOuterHTML:function(d,j,k){function b(l,s,i){i=i.createElement("body");i.innerHTML=s;for(s=i.lastChild;s;){c.insertAfter(s.cloneNode(true),l);s=s.previousSibling}c.remove(l)}var c=this;return this.run(d,function(l){l=c.get(l);if(l.nodeType==1){k=k||l.ownerDocument||c.doc;if(e)try{if(e&&l.nodeType==1)l.outerHTML=j;else b(l,
j,k)}catch(s){b(l,j,k)}else b(l,j,k)}})},decode:a.decode,encode:a.encodeAllRaw,insertAfter:function(d,j){j=this.get(j);return this.run(d,function(k){var b,c;b=j.parentNode;(c=j.nextSibling)?b.insertBefore(k,c):b.appendChild(k);return k})},isBlock:function(d){var j=d.nodeType;if(j)return!!(j===1&&h[d.nodeName]);return!!h[d]},replace:function(d,j,k){if(o(j,"array"))d=d.cloneNode(true);return this.run(j,function(b){k&&p(n.grep(b.childNodes),function(c){d.appendChild(c)});return b.parentNode.replaceChild(d,
b)})},rename:function(d,j){var k=this,b;if(d.nodeName!=j.toUpperCase()){b=k.create(j);p(k.getAttribs(d),function(c){k.setAttrib(b,c.nodeName,k.getAttrib(d,c.nodeName))});k.replace(b,d,1)}return b||d},findCommonAncestor:function(d,j){for(var k=d,b;k;){for(b=j;b&&k!=b;)b=b.parentNode;if(k==b)break;k=k.parentNode}if(!k&&d.ownerDocument)return d.ownerDocument.documentElement;return k},toHex:function(d){function j(b){b=parseInt(b).toString(16);return b.length>1?b:"0"+b}var k=/^\s*rgb\s*?\(\s*?([0-9]+)\s*?,\s*?([0-9]+)\s*?,\s*?([0-9]+)\s*?\)\s*$/i.exec(d);
if(k)return d="#"+j(k[1])+j(k[2])+j(k[3]);return d},getClasses:function(){function d(s){p(s.imports,function(i){d(i)});p(s.cssRules||s.rules,function(i){switch(i.type||1){case 1:i.selectorText&&p(i.selectorText.split(","),function(m){m=m.replace(/^\s*|\s*$|^\s\./g,"");if(!(/\.mce/.test(m)||!/\.[\w\-]+$/.test(m))){c=m;m=n._replace(/.*\.([a-z0-9_\-]+).*/i,"$1",m);if(!(b&&!(m=b(m,c))))if(!k[m]){j.push({"class":m});k[m]=1}}});break;case 3:d(i.styleSheet);break}})}var j=[],k={},b=this.settings.class_filter,
c;if(this.classes)return this.classes;try{p(this.doc.styleSheets,d)}catch(l){}if(j.length>0)this.classes=j;return j},run:function(d,j,k){var b=this,c;if(b.doc&&typeof d==="string")d=b.get(d);if(!d)return false;k=k||this;if(!d.nodeType&&(d.length||d.length===0)){c=[];p(d,function(l,s){if(l){if(typeof l=="string")l=b.doc.getElementById(l);c.push(j.call(k,l,s))}});return c}return j.call(k,d)},getAttribs:function(d){var j;d=this.get(d);if(!d)return[];if(e){j=[];if(d.nodeName=="OBJECT")return d.attributes;
d.nodeName==="OPTION"&&this.getAttrib(d,"selected")&&j.push({specified:1,nodeName:"selected"});d.cloneNode(false).outerHTML.replace(/<\/?[\w:\-]+ ?|=[\"][^\"]+\"|=\'[^\']+\'|=[\w\-]+|>/gi,"").replace(/[\w:\-]+/gi,function(k){j.push({specified:1,nodeName:k})});return j}return d.attributes},isEmpty:function(d,j){var k,b,c,l;if(d=d.firstChild){c=new n.dom.TreeWalker(d);j=j||this.schema?this.schema.getNonEmptyElements():null;do{b=d.nodeType;if(b===1){if(d.getAttribute("data-mce-bogus"))continue;l=d.nodeName.toLowerCase();
if(j&&j[l]){k=d.parentNode;if(l==="br"&&this.isBlock(k)&&k.firstChild===d&&k.lastChild===d)continue;return false}this.getAttribs(d);for(k=d.attributes.length;k--;){l=d.attributes[k].nodeName;if(l==="name"||l==="data-mce-bookmark")return false}}if(b===3&&!f.test(d.nodeValue))return false}while(d=c.next())}return true},destroy:function(d){this.events&&this.events.destroy();this.win=this.doc=this.root=this.events=null;d||n.removeUnload(this.destroy)},createRng:function(){var d=this.doc;return d.createRange?
d.createRange():new n.dom.Range(this)},nodeIndex:function(d,j){var k=0,b,c;if(d){b=d.nodeType;for(d=d.previousSibling;d;d=d.previousSibling){c=d.nodeType;if(j&&c==3)if(c==b||!d.nodeValue.length)continue;k++;b=c}}return k},split:function(d,j,k){function b(m){var r,t=m.childNodes,u=m.nodeType;if(!(u==1&&m.getAttribute("data-mce-type")=="bookmark")){for(r=t.length-1;r>=0;r--)b(t[r]);if(u!=9){if(u==3&&m.nodeValue.length>0){if(!c.isBlock(m.parentNode)||n.trim(m.nodeValue).length>0)return}else if(u==1){t=
m.childNodes;t.length==1&&t[0]&&t[0].nodeType==1&&t[0].getAttribute("data-mce-type")=="bookmark"&&m.parentNode.insertBefore(t[0],m);if(t.length||/^(br|hr|input|img)$/i.test(m.nodeName))return}c.remove(m)}return m}}var c=this,l=c.createRng(),s,i;if(d&&j){l.setStart(d.parentNode,c.nodeIndex(d));l.setEnd(j.parentNode,c.nodeIndex(j));s=l.extractContents();l=c.createRng();l.setStart(j.parentNode,c.nodeIndex(j)+1);l.setEnd(d.parentNode,c.nodeIndex(d)+1);l=l.extractContents();i=d.parentNode;i.insertBefore(b(s),
d);k?i.replaceChild(k,j):i.insertBefore(j,d);i.insertBefore(b(l),d);c.remove(d);return k||j}},bind:function(d,j,k,b){if(!this.events)this.events=new n.dom.EventUtils;return this.events.add(d,j,k,b||this)},unbind:function(d,j,k){if(!this.events)this.events=new n.dom.EventUtils;return this.events.remove(d,j,k)},_findSib:function(d,j,k){var b=this,c=j;if(d){if(o(c,"string"))c=function(l){return b.is(l,j)};for(d=d[k];d;d=d[k])if(c(d))return d}return null},_isRes:function(d){return/^(top|left|bottom|right|width|height)/i.test(d)||
/;\s*(top|left|bottom|right|width|height)/i.test(d)}});n.DOM=new n.dom.DOMUtils(document,{process_html:0})})(tinymce);
(function(n){function p(o){function q(z,A){x(ha,z,A)}function e(z,A){x(na,z,A)}function a(z){q(z.parentNode,ra(z))}function g(z){q(z.parentNode,ra(z)+1)}function h(z){e(z.parentNode,ra(z))}function f(z){e(z.parentNode,ra(z)+1)}function d(z){if(z){D[$]=D[W];D[la]=D[fa]}else{D[W]=D[$];D[fa]=D[la]}D.collapsed=ha}function j(z){a(z);f(z)}function k(z){q(z,0);e(z,z.nodeType===1?z.childNodes.length:z.nodeValue.length)}function b(z,A){var B=D[W],G=D[fa],I=D[$],L=D[la],V=A.startContainer,O=A.startOffset,aa=
A.endContainer;A=A.endOffset;if(z===0)return v(B,G,V,O);if(z===1)return v(I,L,V,O);if(z===2)return v(I,L,aa,A);if(z===3)return v(B,G,aa,A)}function c(){y(ka)}function l(){return y(Z)}function s(){return y(ba)}function i(z){var A=this[W],B=this[fa],G;if((A.nodeType===3||A.nodeType===4)&&A.nodeValue)if(B)if(B>=A.nodeValue.length)o.insertAfter(z,A);else{B=A.splitText(B);A.parentNode.insertBefore(z,B)}else A.parentNode.insertBefore(z,A);else{if(A.childNodes.length>0)G=A.childNodes[B];G?A.insertBefore(z,
G):A.appendChild(z)}}function m(z){var A=D.extractContents();D.insertNode(z);z.appendChild(A);D.selectNode(z)}function r(){return sa(new p(o),{startContainer:D[W],startOffset:D[fa],endContainer:D[$],endOffset:D[la],collapsed:D.collapsed,commonAncestorContainer:D.commonAncestorContainer})}function t(z,A){var B;if(z.nodeType==3)return z;if(A<0)return z;for(B=z.firstChild;B&&A>0;){--A;B=B.nextSibling}if(B)return B;return z}function u(){return D[W]==D[$]&&D[fa]==D[la]}function v(z,A,B,G){var I,L;if(z==
B){if(A==G)return 0;if(A<G)return-1;return 1}for(I=B;I&&I.parentNode!=z;)I=I.parentNode;if(I){L=0;for(B=z.firstChild;B!=I&&L<A;){L++;B=B.nextSibling}if(A<=L)return-1;return 1}for(I=z;I&&I.parentNode!=B;)I=I.parentNode;if(I){L=0;for(B=B.firstChild;B!=I&&L<G;){L++;B=B.nextSibling}if(L<G)return-1;return 1}A=o.findCommonAncestor(z,B);for(z=z;z&&z.parentNode!=A;)z=z.parentNode;z||(z=A);for(G=B;G&&G.parentNode!=A;)G=G.parentNode;G||(G=A);if(z==G)return 0;for(B=A.firstChild;B;){if(B==z)return-1;if(B==G)return 1;
B=B.nextSibling}}function x(z,A,B){if(z){D[W]=A;D[fa]=B}else{D[$]=A;D[la]=B}for(A=D[$];A.parentNode;)A=A.parentNode;for(B=D[W];B.parentNode;)B=B.parentNode;if(B==A)v(D[W],D[fa],D[$],D[la])>0&&D.collapse(z);else D.collapse(z);D.collapsed=u();D.commonAncestorContainer=o.findCommonAncestor(D[W],D[$])}function y(z){var A,B=0,G=0,I;if(D[W]==D[$])return C(z);A=D[$];for(I=A.parentNode;I;A=I,I=I.parentNode){if(I==D[W])return F(A,z);++B}A=D[W];for(I=A.parentNode;I;A=I,I=I.parentNode){if(I==D[$])return H(A,
z);++G}G=G-B;for(A=D[W];G>0;){A=A.parentNode;G--}for(B=D[$];G<0;){B=B.parentNode;G++}G=A.parentNode;for(I=B.parentNode;G!=I;G=G.parentNode,I=I.parentNode){A=G;B=I}return M(A,B,z)}function C(z){var A,B,G,I;if(z!=ka)A=Y.createDocumentFragment();if(D[fa]==D[la])return A;if(D[W].nodeType==3){B=D[W].nodeValue;B=B.substring(D[fa],D[la]);if(z!=ba){D[W].deleteData(D[fa],D[la]-D[fa]);D.collapse(ha)}if(z==ka)return;A.appendChild(Y.createTextNode(B));return A}G=t(D[W],D[fa]);for(B=D[la]-D[fa];B>0;){I=G.nextSibling;
G=S(G,z);A&&A.appendChild(G);--B;G=I}z!=ba&&D.collapse(ha);return A}function F(z,A){var B,G,I,L;if(A!=ka)B=Y.createDocumentFragment();G=P(z,A);B&&B.appendChild(G);I=ra(z)-D[fa];if(I<=0){if(A!=ba){D.setEndBefore(z);D.collapse(na)}return B}for(G=z.previousSibling;I>0;){L=G.previousSibling;G=S(G,A);B&&B.insertBefore(G,B.firstChild);--I;G=L}if(A!=ba){D.setEndBefore(z);D.collapse(na)}return B}function H(z,A){var B,G,I,L;if(A!=ka)B=Y.createDocumentFragment();I=R(z,A);B&&B.appendChild(I);G=ra(z);++G;G=D[la]-
G;for(I=z.nextSibling;G>0;){L=I.nextSibling;I=S(I,A);B&&B.appendChild(I);--G;I=L}if(A!=ba){D.setStartAfter(z);D.collapse(ha)}return B}function M(z,A,B){var G,I,L,V;if(B!=ka)I=Y.createDocumentFragment();G=R(z,B);I&&I.appendChild(G);L=ra(z);V=ra(A);++L;L=V-L;for(G=z.nextSibling;L>0;){V=G.nextSibling;G=S(G,B);I&&I.appendChild(G);G=V;--L}G=P(A,B);I&&I.appendChild(G);if(B!=ba){D.setStartAfter(z);D.collapse(ha)}return I}function P(z,A){var B=t(D[$],D[la]-1),G,I,L,V=B!=D[$];if(B==z)return K(B,V,na,A);G=
B.parentNode;for(I=K(G,na,na,A);G;){for(;B;){L=B.previousSibling;B=K(B,V,na,A);A!=ka&&I.insertBefore(B,I.firstChild);V=ha;B=L}if(G==z)return I;B=G.previousSibling;G=G.parentNode;L=K(G,na,na,A);A!=ka&&L.appendChild(I);I=L}}function R(z,A){var B=t(D[W],D[fa]),G=B!=D[W],I,L,V;if(B==z)return K(B,G,ha,A);I=B.parentNode;for(L=K(I,na,ha,A);I;){for(;B;){V=B.nextSibling;B=K(B,G,ha,A);A!=ka&&L.appendChild(B);G=ha;B=V}if(I==z)return L;B=I.nextSibling;I=I.parentNode;V=K(I,na,ha,A);A!=ka&&V.appendChild(L);L=V}}
function K(z,A,B,G){var I;if(A)return S(z,G);if(z.nodeType==3){A=z.nodeValue;if(B){I=D[fa];B=A.substring(I);A=A.substring(0,I)}else{I=D[la];B=A.substring(0,I);A=A.substring(I)}if(G!=ba)z.nodeValue=A;if(G==ka)return;z=z.cloneNode(na);z.nodeValue=B;return z}if(G!=ka)return z.cloneNode(na)}function S(z,A){if(A!=ka)return A==ba?z.cloneNode(ha):z;z.parentNode.removeChild(z)}var D=this,Y=o.doc,Z=0,ba=1,ka=2,ha=true,na=false,fa="startOffset",W="startContainer",$="endContainer",la="endOffset",sa=tinymce.extend,
ra=o.nodeIndex;sa(D,{startContainer:Y,startOffset:0,endContainer:Y,endOffset:0,collapsed:ha,commonAncestorContainer:Y,START_TO_START:0,START_TO_END:1,END_TO_END:2,END_TO_START:3,setStart:q,setEnd:e,setStartBefore:a,setStartAfter:g,setEndBefore:h,setEndAfter:f,collapse:d,selectNode:j,selectNodeContents:k,compareBoundaryPoints:b,deleteContents:c,extractContents:l,cloneContents:s,insertNode:i,surroundContents:m,cloneRange:r})}n.Range=p})(tinymce.dom);
(function(){function n(p){function o(h,f){var d,j=0,k,b,c,l,s,i,m=-1,r;d=h.duplicate();d.collapse(f);r=d.parentElement();if(r.ownerDocument===p.dom.doc){for(;r.contentEditable==="false";)r=r.parentNode;if(!r.hasChildNodes())return{node:r,inside:1};c=r.children;for(k=c.length-1;j<=k;){i=Math.floor((j+k)/2);l=c[i];d.moveToElementText(l);m=d.compareEndPoints(f?"StartToStart":"EndToEnd",h);if(m>0)k=i-1;else if(m<0)j=i+1;else return{node:l}}if(m<0){if(l)d.collapse(false);else{d.moveToElementText(r);d.collapse(true);
l=r;b=true}d.setEndPoint(f?"EndToStart":"EndToEnd",h);if(d.compareEndPoints(f?"StartToStart":"StartToEnd",h)>0){d=h.duplicate();d.collapse(f);for(s=-1;r==d.parentElement();){if(d.move("character",-1)==0)break;s++}}s=s||d.text.replace("\r\n"," ").length}else{d.collapse(true);d.setEndPoint(f?"StartToStart":"StartToEnd",h);s=d.text.replace("\r\n"," ").length}return{node:l,position:m,offset:s,inside:b}}}function q(){function h(s){var i=o(f,s),m,r,t=0,u;m=i.node;r=i.offset;if(i.inside&&!m.hasChildNodes())d[s?
"setStart":"setEnd"](m,0);else if(r===void 0)d[s?"setStartBefore":"setEndAfter"](m);else{if(i.position<0){i=i.inside?m.firstChild:m.nextSibling;if(!i){d[s?"setStartAfter":"setEndAfter"](m);return}if(!r){i.nodeType==3?d[s?"setStart":"setEnd"](i,0):d[s?"setStartBefore":"setEndBefore"](i);return}for(;i;){u=i.nodeValue;t+=u.length;if(t>=r){m=i;t-=r;t=u.length-t;break}i=i.nextSibling}}else{i=m.previousSibling;if(!i)return d[s?"setStartBefore":"setEndBefore"](m);if(!r){m.nodeType==3?d[s?"setStart":"setEnd"](i,
m.nodeValue.length):d[s?"setStartAfter":"setEndAfter"](i);return}for(;i;){t+=i.nodeValue.length;if(t>=r){m=i;t-=r;break}i=i.previousSibling}}d[s?"setStart":"setEnd"](m,t)}}var f=p.getRng(),d=a.createRng(),j,k,b,c;j=f.item?f.item(0):f.parentElement();if(j.ownerDocument!=a.doc)return d;k=p.isCollapsed();if(f.item){d.setStart(j.parentNode,a.nodeIndex(j));d.setEnd(d.startContainer,d.startOffset+1);return d}try{h(true);k||h()}catch(l){if(l.number==-2147024809){c=e.getBookmark(2);b=f.duplicate();b.collapse(true);
j=b.parentElement();if(!k){b=f.duplicate();b.collapse(false);b=b.parentElement();b.innerHTML=b.innerHTML}j.innerHTML=j.innerHTML;e.moveToBookmark(c);f=p.getRng();h(true);k||h()}else throw l;}return d}var e=this,a=p.dom,g=true;this.getBookmark=function(h){function f(b){var c,l,s,i,m=[];c=b.parentNode;for(l=a.getRoot().parentNode;c!=l&&c.nodeType!==9;){s=c.children;for(i=s.length;i--;)if(b===s[i]){m.push(i);break}b=c;c=c.parentNode}return m}function d(b){if(b=o(j,b))return{position:b.position,offset:b.offset,
indexes:f(b.node),inside:b.inside}}var j=p.getRng(),k={};if(h===2)if(j.item)k.start={ctrl:true,indexes:f(j.item(0))};else{k.start=d(true);if(!p.isCollapsed())k.end=d()}return k};this.moveToBookmark=function(h){function f(b){var c,l,s,i;c=a.getRoot();for(l=b.length-1;l>=0;l--){i=c.children;s=b[l];if(s<=i.length-1)c=i[s]}return c}function d(b){var c=h[b?"start":"end"],l,s;if(c){l=c.position>0;s=k.createTextRange();s.moveToElementText(f(c.indexes));offset=c.offset;if(offset!==void 0){s.collapse(c.inside||
l);s.moveStart("character",l?-offset:offset)}else s.collapse(b);j.setEndPoint(b?"StartToStart":"EndToStart",s);b&&j.collapse(true)}}var j,k=a.doc.body;if(h.start){if(h.start.ctrl){j=k.createControlRange();j.addElement(f(h.start.indexes))}else{j=k.createTextRange();d(true);d()}j.select()}};this.addRange=function(h){function f(r){var t,u,v,x,y;v=a.create("a");t=r?k:c;u=r?b:l;x=d.duplicate();if(t==s||t==s.documentElement){t=i;u=0}if(t.nodeType==3){t.parentNode.insertBefore(v,t);x.moveToElementText(v);
x.moveStart("character",u);a.remove(v);d.setEndPoint(r?"StartToStart":"EndToEnd",x)}else{y=t.childNodes;if(y.length){u>=y.length?a.insertAfter(v,y[y.length-1]):t.insertBefore(v,y[u]);x.moveToElementText(v)}else{v=s.createTextNode("\ufeff");t.appendChild(v);x.moveToElementText(v.parentNode);x.collapse(g)}d.setEndPoint(r?"StartToStart":"EndToEnd",x);a.remove(v)}}var d,j,k,b,c,l,s=p.dom.doc,i=s.body;k=h.startContainer;b=h.startOffset;c=h.endContainer;l=h.endOffset;d=i.createTextRange();if(k==c&&k.nodeType==
1&&b==l-1)if(b==l-1)try{j=i.createControlRange();j.addElement(k.childNodes[b]);j.select();return}catch(m){}f(true);f();d.select()};this.getRangeAt=q}tinymce.dom.TridentSelection=n})();
(function(){function n(i,m,r,t,u,v){u=0;for(var x=t.length;u<x;u++){var y=t[u];if(y){y=y[i];for(var C=false;y;){if(y.sizcache===r){C=t[y.sizset];break}if(y.nodeType===1&&!v){y.sizcache=r;y.sizset=u}if(y.nodeName.toLowerCase()===m){C=y;break}y=y[i]}t[u]=C}}}function p(i,m,r,t,u,v){u=0;for(var x=t.length;u<x;u++){var y=t[u];if(y){y=y[i];for(var C=false;y;){if(y.sizcache===r){C=t[y.sizset];break}if(y.nodeType===1){if(!v){y.sizcache=r;y.sizset=u}if(typeof m!=="string"){if(y===m){C=true;break}}else if(h.filter(m,
[y]).length>0){C=y;break}}y=y[i]}t[u]=C}}}var o=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^\[\]]*\]|['"][^'"]*['"]|[^\[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,q=0,e=Object.prototype.toString,a=false,g=true;[0,0].sort(function(){g=false;return 0});var h=function(i,m,r,t){r=r||[];var u=m=m||document;if(m.nodeType!==1&&m.nodeType!==9)return[];if(!i||typeof i!=="string")return r;var v=[],x,y,C,F,H=true,M=h.isXML(m),P=i,R;do{o.exec("");if(x=o.exec(P)){P=x[3];v.push(x[1]);if(x[2]){F=
x[3];break}}}while(x);if(v.length>1&&d.exec(i))if(v.length===2&&f.relative[v[0]])y=s(v[0]+v[1],m);else for(y=f.relative[v[0]]?[m]:h(v.shift(),m);v.length;){i=v.shift();if(f.relative[i])i+=v.shift();y=s(i,y)}else{if(!t&&v.length>1&&m.nodeType===9&&!M&&f.match.ID.test(v[0])&&!f.match.ID.test(v[v.length-1])){x=h.find(v.shift(),m,M);m=x.expr?h.filter(x.expr,x.set)[0]:x.set[0]}if(m){x=t?{expr:v.pop(),set:b(t)}:h.find(v.pop(),v.length===1&&(v[0]==="~"||v[0]==="+")&&m.parentNode?m.parentNode:m,M);y=x.expr?
h.filter(x.expr,x.set):x.set;if(v.length>0)C=b(y);else H=false;for(;v.length;){x=R=v.pop();if(f.relative[R])x=v.pop();else R="";if(x==null)x=m;f.relative[R](C,x,M)}}else C=[]}C||(C=y);C||h.error(R||i);if(e.call(C)==="[object Array]")if(H)if(m&&m.nodeType===1)for(i=0;C[i]!=null;i++){if(C[i]&&(C[i]===true||C[i].nodeType===1&&h.contains(m,C[i])))r.push(y[i])}else for(i=0;C[i]!=null;i++)C[i]&&C[i].nodeType===1&&r.push(y[i]);else r.push.apply(r,C);else b(C,r);if(F){h(F,u,r,t);h.uniqueSort(r)}return r};
h.uniqueSort=function(i){if(l){a=g;i.sort(l);if(a)for(var m=1;m<i.length;m++)i[m]===i[m-1]&&i.splice(m--,1)}return i};h.matches=function(i,m){return h(i,null,null,m)};h.find=function(i,m,r){var t;if(!i)return[];for(var u=0,v=f.order.length;u<v;u++){var x=f.order[u],y;if(y=f.leftMatch[x].exec(i)){var C=y[1];y.splice(1,1);if(C.substr(C.length-1)!=="\\"){y[1]=(y[1]||"").replace(/\\/g,"");t=f.find[x](y,m,r);if(t!=null){i=i.replace(f.match[x],"");break}}}}t||(t=m.getElementsByTagName("*"));return{set:t,
expr:i}};h.filter=function(i,m,r,t){for(var u=i,v=[],x=m,y,C,F=m&&m[0]&&h.isXML(m[0]);i&&m.length;){for(var H in f.filter)if((y=f.leftMatch[H].exec(i))!=null&&y[2]){var M=f.filter[H],P,R;R=y[1];C=false;y.splice(1,1);if(R.substr(R.length-1)!=="\\"){if(x===v)v=[];if(f.preFilter[H])if(y=f.preFilter[H](y,x,r,v,t,F)){if(y===true)continue}else C=P=true;if(y)for(var K=0;(R=x[K])!=null;K++)if(R){P=M(R,y,K,x);var S=t^!!P;if(r&&P!=null)if(S)C=true;else x[K]=false;else if(S){v.push(R);C=true}}if(P!==undefined){r||
(x=v);i=i.replace(f.match[H],"");if(!C)return[];break}}}if(i===u)if(C==null)h.error(i);else break;u=i}return x};h.error=function(i){throw"Syntax error, unrecognized expression: "+i;};var f=h.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(i){return i.getAttribute("href")}},relative:{"+":function(i,m){var r=typeof m==="string",t=r&&!/\W/.test(m);r=r&&!t;if(t)m=m.toLowerCase();t=0;for(var u=i.length,v;t<u;t++)if(v=i[t]){for(;(v=v.previousSibling)&&v.nodeType!==1;);i[t]=r||v&&v.nodeName.toLowerCase()===
m?v||false:v===m}r&&h.filter(m,i,true)},">":function(i,m){var r=typeof m==="string",t,u=0,v=i.length;if(r&&!/\W/.test(m))for(m=m.toLowerCase();u<v;u++){if(t=i[u]){r=t.parentNode;i[u]=r.nodeName.toLowerCase()===m?r:false}}else{for(;u<v;u++)if(t=i[u])i[u]=r?t.parentNode:t.parentNode===m;r&&h.filter(m,i,true)}},"":function(i,m,r){var t=q++,u=p,v;if(typeof m==="string"&&!/\W/.test(m)){v=m=m.toLowerCase();u=n}u("parentNode",m,t,i,v,r)},"~":function(i,m,r){var t=q++,u=p,v;if(typeof m==="string"&&!/\W/.test(m)){v=
m=m.toLowerCase();u=n}u("previousSibling",m,t,i,v,r)}},find:{ID:function(i,m,r){if(typeof m.getElementById!=="undefined"&&!r)return(i=m.getElementById(i[1]))?[i]:[]},NAME:function(i,m){if(typeof m.getElementsByName!=="undefined"){var r=[];m=m.getElementsByName(i[1]);for(var t=0,u=m.length;t<u;t++)m[t].getAttribute("name")===i[1]&&r.push(m[t]);return r.length===0?null:r}},TAG:function(i,m){return m.getElementsByTagName(i[1])}},preFilter:{CLASS:function(i,m,r,t,u,v){i=" "+i[1].replace(/\\/g,"")+" ";
if(v)return i;v=0;for(var x;(x=m[v])!=null;v++)if(x)if(u^(x.className&&(" "+x.className+" ").replace(/[\t\n]/g," ").indexOf(i)>=0))r||t.push(x);else if(r)m[v]=false;return false},ID:function(i){return i[1].replace(/\\/g,"")},TAG:function(i){return i[1].toLowerCase()},CHILD:function(i){if(i[1]==="nth"){var m=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(i[2]==="even"&&"2n"||i[2]==="odd"&&"2n+1"||!/\D/.test(i[2])&&"0n+"+i[2]||i[2]);i[2]=m[1]+(m[2]||1)-0;i[3]=m[3]-0}i[0]=q++;return i},ATTR:function(i,m,r,t,u,v){m=
i[1].replace(/\\/g,"");if(!v&&f.attrMap[m])i[1]=f.attrMap[m];if(i[2]==="~=")i[4]=" "+i[4]+" ";return i},PSEUDO:function(i,m,r,t,u){if(i[1]==="not")if((o.exec(i[3])||"").length>1||/^\w/.test(i[3]))i[3]=h(i[3],null,null,m);else{i=h.filter(i[3],m,r,true^u);r||t.push.apply(t,i);return false}else if(f.match.POS.test(i[0])||f.match.CHILD.test(i[0]))return true;return i},POS:function(i){i.unshift(true);return i}},filters:{enabled:function(i){return i.disabled===false&&i.type!=="hidden"},disabled:function(i){return i.disabled===
true},checked:function(i){return i.checked===true},selected:function(i){return i.selected===true},parent:function(i){return!!i.firstChild},empty:function(i){return!i.firstChild},has:function(i,m,r){return!!h(r[3],i).length},header:function(i){return/h\d/i.test(i.nodeName)},text:function(i){return"text"===i.type},radio:function(i){return"radio"===i.type},checkbox:function(i){return"checkbox"===i.type},file:function(i){return"file"===i.type},password:function(i){return"password"===i.type},submit:function(i){return"submit"===
i.type},image:function(i){return"image"===i.type},reset:function(i){return"reset"===i.type},button:function(i){return"button"===i.type||i.nodeName.toLowerCase()==="button"},input:function(i){return/input|select|textarea|button/i.test(i.nodeName)}},setFilters:{first:function(i,m){return m===0},last:function(i,m,r,t){return m===t.length-1},even:function(i,m){return m%2===0},odd:function(i,m){return m%2===1},lt:function(i,m,r){return m<r[3]-0},gt:function(i,m,r){return m>r[3]-0},nth:function(i,m,r){return r[3]-
0===m},eq:function(i,m,r){return r[3]-0===m}},filter:{PSEUDO:function(i,m,r,t){var u=m[1],v=f.filters[u];if(v)return v(i,r,m,t);else if(u==="contains")return(i.textContent||i.innerText||h.getText([i])||"").indexOf(m[3])>=0;else if(u==="not"){m=m[3];r=0;for(t=m.length;r<t;r++)if(m[r]===i)return false;return true}else h.error("Syntax error, unrecognized expression: "+u)},CHILD:function(i,m){var r=m[1],t=i;switch(r){case "only":case "first":for(;t=t.previousSibling;)if(t.nodeType===1)return false;if(r===
"first")return true;t=i;case "last":for(;t=t.nextSibling;)if(t.nodeType===1)return false;return true;case "nth":r=m[2];var u=m[3];if(r===1&&u===0)return true;m=m[0];var v=i.parentNode;if(v&&(v.sizcache!==m||!i.nodeIndex)){var x=0;for(t=v.firstChild;t;t=t.nextSibling)if(t.nodeType===1)t.nodeIndex=++x;v.sizcache=m}i=i.nodeIndex-u;return r===0?i===0:i%r===0&&i/r>=0}},ID:function(i,m){return i.nodeType===1&&i.getAttribute("id")===m},TAG:function(i,m){return m==="*"&&i.nodeType===1||i.nodeName.toLowerCase()===
m},CLASS:function(i,m){return(" "+(i.className||i.getAttribute("class"))+" ").indexOf(m)>-1},ATTR:function(i,m){var r=m[1];i=f.attrHandle[r]?f.attrHandle[r](i):i[r]!=null?i[r]:i.getAttribute(r);r=i+"";var t=m[2];m=m[4];return i==null?t==="!=":t==="="?r===m:t==="*="?r.indexOf(m)>=0:t==="~="?(" "+r+" ").indexOf(m)>=0:!m?r&&i!==false:t==="!="?r!==m:t==="^="?r.indexOf(m)===0:t==="$="?r.substr(r.length-m.length)===m:t==="|="?r===m||r.substr(0,m.length+1)===m+"-":false},POS:function(i,m,r,t){var u=f.setFilters[m[2]];
if(u)return u(i,r,m,t)}}},d=f.match.POS,j=function(i,m){return"\\"+(m-0+1)};for(var k in f.match){f.match[k]=new RegExp(f.match[k].source+/(?![^\[]*\])(?![^\(]*\))/.source);f.leftMatch[k]=new RegExp(/(^(?:.|\r|\n)*?)/.source+f.match[k].source.replace(/\\(\d+)/g,j))}var b=function(i,m){i=Array.prototype.slice.call(i,0);if(m){m.push.apply(m,i);return m}return i};try{Array.prototype.slice.call(document.documentElement.childNodes,0)}catch(c){b=function(i,m){m=m||[];var r=0;if(e.call(i)==="[object Array]")Array.prototype.push.apply(m,
i);else if(typeof i.length==="number")for(var t=i.length;r<t;r++)m.push(i[r]);else for(;i[r];r++)m.push(i[r]);return m}}var l;if(document.documentElement.compareDocumentPosition)l=function(i,m){if(!i.compareDocumentPosition||!m.compareDocumentPosition){if(i==m)a=true;return i.compareDocumentPosition?-1:1}i=i.compareDocumentPosition(m)&4?-1:i===m?0:1;if(i===0)a=true;return i};else if("sourceIndex"in document.documentElement)l=function(i,m){if(!i.sourceIndex||!m.sourceIndex){if(i==m)a=true;return i.sourceIndex?
-1:1}i=i.sourceIndex-m.sourceIndex;if(i===0)a=true;return i};else if(document.createRange)l=function(i,m){if(!i.ownerDocument||!m.ownerDocument){if(i==m)a=true;return i.ownerDocument?-1:1}var r=i.ownerDocument.createRange(),t=m.ownerDocument.createRange();r.setStart(i,0);r.setEnd(i,0);t.setStart(m,0);t.setEnd(m,0);i=r.compareBoundaryPoints(Range.START_TO_END,t);if(i===0)a=true;return i};h.getText=function(i){for(var m="",r,t=0;i[t];t++){r=i[t];if(r.nodeType===3||r.nodeType===4)m+=r.nodeValue;else if(r.nodeType!==
8)m+=h.getText(r.childNodes)}return m};(function(){var i=document.createElement("div"),m="script"+(new Date).getTime();i.innerHTML="<a name='"+m+"'/>";var r=document.documentElement;r.insertBefore(i,r.firstChild);if(document.getElementById(m)){f.find.ID=function(t,u,v){if(typeof u.getElementById!=="undefined"&&!v)return(u=u.getElementById(t[1]))?u.id===t[1]||typeof u.getAttributeNode!=="undefined"&&u.getAttributeNode("id").nodeValue===t[1]?[u]:undefined:[]};f.filter.ID=function(t,u){var v=typeof t.getAttributeNode!==
"undefined"&&t.getAttributeNode("id");return t.nodeType===1&&v&&v.nodeValue===u}}r.removeChild(i);r=i=null})();(function(){var i=document.createElement("div");i.appendChild(document.createComment(""));if(i.getElementsByTagName("*").length>0)f.find.TAG=function(m,r){r=r.getElementsByTagName(m[1]);if(m[1]==="*"){m=[];for(var t=0;r[t];t++)r[t].nodeType===1&&m.push(r[t]);r=m}return r};i.innerHTML="<a href='#'></a>";if(i.firstChild&&typeof i.firstChild.getAttribute!=="undefined"&&i.firstChild.getAttribute("href")!==
"#")f.attrHandle.href=function(m){return m.getAttribute("href",2)};i=null})();document.querySelectorAll&&function(){var i=h,m=document.createElement("div");m.innerHTML="<p class='TEST'></p>";if(!(m.querySelectorAll&&m.querySelectorAll(".TEST").length===0)){h=function(t,u,v,x){u=u||document;if(!x&&u.nodeType===9&&!h.isXML(u))try{return b(u.querySelectorAll(t),v)}catch(y){}return i(t,u,v,x)};for(var r in i)h[r]=i[r];m=null}}();(function(){var i=document.createElement("div");i.innerHTML="<div class='test e'></div><div class='test'></div>";
if(!(!i.getElementsByClassName||i.getElementsByClassName("e").length===0)){i.lastChild.className="e";if(i.getElementsByClassName("e").length!==1){f.order.splice(1,0,"CLASS");f.find.CLASS=function(m,r,t){if(typeof r.getElementsByClassName!=="undefined"&&!t)return r.getElementsByClassName(m[1])};i=null}}})();h.contains=document.compareDocumentPosition?function(i,m){return!!(i.compareDocumentPosition(m)&16)}:function(i,m){return i!==m&&(i.contains?i.contains(m):true)};h.isXML=function(i){return(i=(i?
i.ownerDocument||i:0).documentElement)?i.nodeName!=="HTML":false};var s=function(i,m){var r=[],t="",u;for(m=m.nodeType?[m]:m;u=f.match.PSEUDO.exec(i);){t+=u[0];i=i.replace(f.match.PSEUDO,"")}i=f.relative[i]?i+"*":i;u=0;for(var v=m.length;u<v;u++)h(i,m[u],r);return h.filter(t,r)};window.tinymce.dom.Sizzle=h})();
(function(n){var p=n.each,o=n.DOM,q=n.isIE,e;n.create("tinymce.dom.EventUtils",{EventUtils:function(){this.inits=[];this.events=[]},add:function(a,g,h,f){var d,j=this,k=j.events,b;if(g instanceof Array){b=[];p(g,function(c){b.push(j.add(a,c,h,f))});return b}if(a&&a.hasOwnProperty&&a instanceof Array){b=[];p(a,function(c){c=o.get(c);b.push(j.add(c,g,h,f))});return b}if(a=o.get(a)){d=function(c){if(!j.disabled){if((c=c||window.event)&&q){if(!c.target)c.target=c.srcElement;n.extend(c,j._stoppers)}if(!f)return h(c);
return h.call(f,c)}};if(g=="unload"){n.unloads.unshift({func:d});return d}if(g=="init"){j.domLoaded?d():j.inits.push(d);return d}k.push({obj:a,name:g,func:h,cfunc:d,scope:f});j._add(a,g,d);return h}},remove:function(a,g,h){var f=this,d=f.events,j=false,k;if(a&&a.hasOwnProperty&&a instanceof Array){k=[];p(a,function(b){b=o.get(b);k.push(f.remove(b,g,h))});return k}a=o.get(a);p(d,function(b,c){if(b.obj==a&&b.name==g&&(!h||b.func==h||b.cfunc==h)){d.splice(c,1);f._remove(a,g,b.cfunc);j=true;return false}});
return j},clear:function(a){var g=this.events,h,f;if(a){a=o.get(a);for(h=g.length-1;h>=0;h--){f=g[h];if(f.obj===a){this._remove(f.obj,f.name,f.cfunc);f.obj=f.cfunc=null;g.splice(h,1)}}}},cancel:function(a){if(!a)return false;this.stop(a);return this.prevent(a)},stop:function(a){if(a.stopPropagation)a.stopPropagation();else a.cancelBubble=true;return false},prevent:function(a){if(a.preventDefault)a.preventDefault();else a.returnValue=false;return false},destroy:function(){var a=this;p(a.events,function(g){a._remove(g.obj,
g.name,g.cfunc);g.obj=g.cfunc=null});a.events=[];a=null},_add:function(a,g,h){if(a.attachEvent)a.attachEvent("on"+g,h);else if(a.addEventListener)a.addEventListener(g,h,false);else a["on"+g]=h},_remove:function(a,g,h){if(a)try{if(a.detachEvent)a.detachEvent("on"+g,h);else if(a.removeEventListener)a.removeEventListener(g,h,false);else a["on"+g]=null}catch(f){}},_pageInit:function(){if(!this.domLoaded){this.domLoaded=true;p(this.inits,function(a){a()});this.inits=[]}},_wait:function(a){var g=this,h=
a.document;if(a.tinyMCE_GZ&&tinyMCE_GZ.loaded)g.domLoaded=1;else{if(h.attachEvent){h.attachEvent("onreadystatechange",function(){if(h.readyState==="complete"){h.detachEvent("onreadystatechange",arguments.callee);g._pageInit(a)}});h.documentElement.doScroll&&a==a.top&&function(){if(!g.domLoaded){try{h.documentElement.doScroll("left")}catch(f){setTimeout(arguments.callee,0);return}g._pageInit(a)}}()}else h.addEventListener&&g._add(a,"DOMContentLoaded",function(){g._pageInit(a)});g._add(a,"load",function(){g._pageInit(a)})}},
_stoppers:{preventDefault:function(){this.returnValue=false},stopPropagation:function(){this.cancelBubble=true}}});e=n.dom.Event=new n.dom.EventUtils;e._wait(window);n.addUnload(function(){e.destroy()})})(tinymce);
(function(n){n.dom.Element=function(p,o){var q=this,e;q.settings=o=o||{};q.id=p;q.dom=e=o.dom||n.DOM;n.isIE||e.get(q.id);n.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){q[a]=function(){var g=[p],h;for(h=0;h<arguments.length;h++)g.push(arguments[h]);g=e[a].apply(e,g);q.update(a);return g}});n.extend(q,{on:function(a,g,h){return n.dom.Event.add(q.id,
a,g,h)},getXY:function(){return{x:parseInt(q.getStyle("left")),y:parseInt(q.getStyle("top"))}},getSize:function(){var a=e.get(q.id);return{w:parseInt(q.getStyle("width")||a.clientWidth),h:parseInt(q.getStyle("height")||a.clientHeight)}},moveTo:function(a,g){q.setStyles({left:a,top:g})},moveBy:function(a,g){var h=q.getXY();q.moveTo(h.x+a,h.y+g)},resizeTo:function(a,g){q.setStyles({width:a,height:g})},resizeBy:function(a,g){var h=q.getSize();q.resizeTo(h.w+a,h.h+g)},update:function(a){if(n.isIE6&&o.blocker){a=
a||"";if(!(a.indexOf("get")===0||a.indexOf("has")===0||a.indexOf("is")===0))if(a=="remove")e.remove(q.blocker);else{if(q.blocker)a=e.get(q.blocker);else{q.blocker=e.uniqueId();a=e.add(o.container||e.getRoot(),"iframe",{id:q.blocker,style:"position:absolute;",frameBorder:0,src:'javascript:""'});e.setStyle(a,"opacity",0)}e.setStyles(a,{left:q.getStyle("left",1),top:q.getStyle("top",1),width:q.getStyle("width",1),height:q.getStyle("height",1),display:q.getStyle("display",1),zIndex:parseInt(q.getStyle("zIndex",
1)||0)-1})}}}})}})(tinymce);
(function(n){var p=n.is,o=n.isIE,q=n.each;n.create("tinymce.dom.Selection",{Selection:function(e,a,g){var h=this;h.dom=e;h.win=a;h.serializer=g;q(["onBeforeSetContent","onBeforeGetContent","onSetContent","onGetContent"],function(f){h[f]=new n.util.Dispatcher(h)});if(!h.win.getSelection)h.tridentSel=new n.dom.TridentSelection(h);n.isIE&&e.boxModel&&this._fixIESelection();n.addUnload(h.destroy,h)},setCursorLocation:function(e,a){var g=this.dom.createRng();g.setStart(e,a);g.setEnd(e,a);this.setRng(g);
this.collapse(false)},getContent:function(e){var a=this.getRng(),g=this.dom.create("body"),h=this.getSel(),f,d;e=e||{};f=d="";e.get=true;e.format=e.format||"html";e.forced_root_block="";this.onBeforeGetContent.dispatch(this,e);if(e.format=="text")return this.isCollapsed()?"":a.text||(h.toString?h.toString():"");if(a.cloneContents)(a=a.cloneContents())&&g.appendChild(a);else if(p(a.item)||p(a.htmlText)){g.innerHTML="<br>"+(a.item?a.item(0).outerHTML:a.htmlText);g.removeChild(g.firstChild)}else g.innerHTML=
a.toString();if(/^\s/.test(g.innerHTML))f=" ";if(/\s+$/.test(g.innerHTML))d=" ";e.getInner=true;e.content=this.isCollapsed()?"":f+this.serializer.serialize(g,e)+d;this.onGetContent.dispatch(this,e);return e.content},setContent:function(e,a){var g=this.getRng(),h=this.win.document,f,d;a=a||{format:"html"};a.set=true;a.content=e;a.no_events||this.onBeforeSetContent.dispatch(this,a);e=a.content;if(g.insertNode){e+='<span id="__caret">_</span>';if(g.startContainer==h&&g.endContainer==h)h.body.innerHTML=
e;else{g.deleteContents();if(h.body.childNodes.length==0)h.body.innerHTML=e;else if(g.createContextualFragment)g.insertNode(g.createContextualFragment(e));else{f=h.createDocumentFragment();d=h.createElement("div");f.appendChild(d);d.outerHTML=e;g.insertNode(f)}}e=this.dom.get("__caret");g=h.createRange();g.setStartBefore(e);g.setEndBefore(e);this.setRng(g);this.dom.remove("__caret");try{this.setRng(g)}catch(j){}}else{if(g.item){h.execCommand("Delete",false,null);g=this.getRng()}if(/^\s+/.test(e)){g.pasteHTML('<span id="__mce_tmp">_</span>'+
e);this.dom.remove("__mce_tmp")}else g.pasteHTML(e)}a.no_events||this.onSetContent.dispatch(this,a)},getStart:function(){var e=this.getRng(),a,g;if(e.duplicate||e.item){if(e.item)return e.item(0);a=e.duplicate();a.collapse(1);a=a.parentElement();for(e=g=e.parentElement();g=g.parentNode;)if(g==a){a=e;break}}else{a=e.startContainer;if(a.nodeType==1&&a.hasChildNodes())a=a.childNodes[Math.min(a.childNodes.length-1,e.startOffset)];if(a&&a.nodeType==3)return a.parentNode}return a},getEnd:function(){var e=
this.getRng(),a;if(e.duplicate||e.item){if(e.item)return e.item(0);e=e.duplicate();e.collapse(0);if((a=e.parentElement())&&a.nodeName=="BODY")return a.lastChild||a}else{a=e.endContainer;e=e.endOffset;if(a.nodeType==1&&a.hasChildNodes())a=a.childNodes[e>0?e-1:e];if(a&&a.nodeType==3)return a.parentNode}return a},getBookmark:function(e,a){function g(l,s){var i=0;q(f.select(l),function(m,r){if(m==s)i=r});return i}var h=this,f=h.dom,d,j,k,b;if(e==2){if(h.tridentSel)return h.tridentSel.getBookmark(e);return function(){function l(r,
t){var u=r[t?"startContainer":"endContainer"];r=r[t?"startOffset":"endOffset"];t=[];var v,x=0;if(u.nodeType==3){if(a)for(v=u.previousSibling;v&&v.nodeType==3;v=v.previousSibling)r+=v.nodeValue.length;t.push(r)}else{v=u.childNodes;if(r>=v.length&&v.length){x=1;r=Math.max(0,v.length-1)}t.push(h.dom.nodeIndex(v[r],a)+x)}for(;u&&u!=i;u=u.parentNode)t.push(h.dom.nodeIndex(u,a));return t}var s=h.getRng(true),i=f.getRoot(),m={};m.start=l(s,true);if(!h.isCollapsed())m.end=l(s);return m}()}if(e)return{rng:h.getRng()};
e=h.getRng();j=f.uniqueId();k=tinyMCE.activeEditor.selection.isCollapsed();if(e.duplicate||e.item)if(e.item){b=e.item(0);d=b.nodeName;return{name:d,index:g(d,b)}}else{d=e.duplicate();try{e.collapse();e.pasteHTML('<span data-mce-type="bookmark" id="'+j+'_start" style="overflow:hidden;line-height:0px">\ufeff</span>');if(!k){d.collapse(false);e.moveToElementText(d.parentElement());e.compareEndPoints("StartToEnd",d)==0&&d.move("character",-1);d.pasteHTML('<span data-mce-type="bookmark" id="'+j+'_end" style="overflow:hidden;line-height:0px">\ufeff</span>')}}catch(c){return null}}else{b=
h.getNode();d=b.nodeName;if(d=="IMG")return{name:d,index:g(d,b)};d=e.cloneRange();if(!k){d.collapse(false);d.insertNode(f.create("span",{"data-mce-type":"bookmark",id:j+"_end",style:"overflow:hidden;line-height:0px"},"\ufeff"))}e.collapse(true);e.insertNode(f.create("span",{"data-mce-type":"bookmark",id:j+"_start",style:"overflow:hidden;line-height:0px"},"\ufeff"))}h.moveToBookmark({id:j,keep:1});return{id:j}},moveToBookmark:function(e){var a=this.dom,g,h,f,d,j,k;if(e)if(e.start){g=a.createRng();
h=a.getRoot();var b=function(l){var s=e[l?"start":"end"],i,m,r;if(s){r=s[0];m=h;for(i=s.length-1;i>=1;i--){m=m.childNodes;if(s[i]>m.length-1)return;m=m[s[i]]}if(m.nodeType===3)r=Math.min(s[0],m.nodeValue.length);if(m.nodeType===1)r=Math.min(s[0],m.childNodes.length);l?g.setStart(m,r):g.setEnd(m,r)}return true};if(this.tridentSel)return this.tridentSel.moveToBookmark(e);b(true)&&b()&&this.setRng(g)}else if(e.id){b=function(l){var s=a.get(e.id+"_"+l),i,m,r;r=e.keep;if(s){i=s.parentNode;if(l=="start"){if(r){i=
s.firstChild;m=1}else m=a.nodeIndex(s);f=d=i;j=k=m}else{if(r){i=s.firstChild;m=1}else m=a.nodeIndex(s);d=i;k=m}if(!r){r=s.previousSibling;i=s.nextSibling;for(q(n.grep(s.childNodes),function(t){if(t.nodeType==3)t.nodeValue=t.nodeValue.replace(/\uFEFF/g,"")});s=a.get(e.id+"_"+l);)a.remove(s,1);if(r&&i&&r.nodeType==i.nodeType&&r.nodeType==3&&!n.isOpera){m=r.nodeValue.length;r.appendData(i.nodeValue);a.remove(i);if(l=="start"){f=d=r;j=k=m}else{d=r;k=m}}}}};var c=function(l){if(a.isBlock(l)&&!l.innerHTML)l.innerHTML=
!o?'<br data-mce-bogus="1" />':" ";return l};b("start");b("end");if(f){g=a.createRng();g.setStart(c(f),j);g.setEnd(c(d),k);this.setRng(g)}}else if(e.name)this.select(a.select(e.name)[e.index]);else e.rng&&this.setRng(e.rng)},select:function(e,a){var g=this.dom,h=g.createRng();if(e){g=g.nodeIndex(e);h.setStart(e.parentNode,g);h.setEnd(e.parentNode,g+1);if(a){a=function(f,d){var j=new n.dom.TreeWalker(f,f);do{if(f.nodeType==3&&n.trim(f.nodeValue).length!=0){d?h.setStart(f,0):h.setEnd(f,f.nodeValue.length);
return}if(f.nodeName=="BR"){d?h.setStartBefore(f):h.setEndBefore(f);return}}while(f=d?j.next():j.prev())};a(e,1);a(e)}this.setRng(h)}return e},isCollapsed:function(){var e=this.getRng(),a=this.getSel();if(!e||e.item)return false;if(e.compareEndPoints)return e.compareEndPoints("StartToEnd",e)===0;return!a||e.collapsed},collapse:function(e){var a=this.getRng(),g;if(a.item){g=a.item(0);a=this.win.document.body.createTextRange();a.moveToElementText(g)}a.collapse(!!e);this.setRng(a)},getSel:function(){var e=
this.win;return e.getSelection?e.getSelection():e.document.selection},getRng:function(e){var a,g,h=this.win.document;if(e&&this.tridentSel)return this.tridentSel.getRangeAt(0);try{if(a=this.getSel())g=a.rangeCount>0?a.getRangeAt(0):a.createRange?a.createRange():h.createRange()}catch(f){}if(n.isIE&&g&&g.setStart&&h.selection.createRange().item){e=h.selection.createRange().item(0);g=h.createRange();g.setStartBefore(e);g.setEndAfter(e)}g||(g=h.createRange?h.createRange():h.body.createTextRange());if(this.selectedRange&&
this.explicitRange)if(g.compareBoundaryPoints(g.START_TO_START,this.selectedRange)===0&&g.compareBoundaryPoints(g.END_TO_END,this.selectedRange)===0)g=this.explicitRange;else this.explicitRange=this.selectedRange=null;return g},setRng:function(e){var a;if(this.tridentSel)if(e.cloneRange)this.tridentSel.addRange(e);else try{e.select()}catch(g){}else if(a=this.getSel()){this.explicitRange=e;try{a.removeAllRanges()}catch(h){}a.addRange(e);this.selectedRange=a.getRangeAt(0)}},setNode:function(e){this.setContent(this.dom.getOuterHTML(e));
return e},getNode:function(){var e=this.getRng();this.getSel();var a,g=e.startContainer,h=e.endContainer;if(!e)return this.dom.getRoot();if(e.setStart){a=e.commonAncestorContainer;if(!e.collapsed){if(e.startContainer==e.endContainer)if(e.endOffset-e.startOffset<2)if(e.startContainer.hasChildNodes())a=e.startContainer.childNodes[e.startOffset];if(g.nodeType===3&&h.nodeType===3){var f=function(d,j){for(var k=d;d&&d.nodeType===3&&d.length===0;)d=j?d.nextSibling:d.previousSibling;return d||k};g=g.length===
e.startOffset?f(g.nextSibling,true):g.parentNode;h=e.endOffset===0?f(h.previousSibling,false):h.parentNode;if(g&&g===h)return g}}if(a&&a.nodeType==3)return a.parentNode;return a}return e.item?e.item(0):e.parentElement()},getSelectedBlocks:function(e,a){var g=this.dom,h,f=[];e=g.getParent(e||this.getStart(),g.isBlock);a=g.getParent(a||this.getEnd(),g.isBlock);e&&f.push(e);if(e&&a&&e!=a){h=e;for(var d=new n.dom.TreeWalker(e,g.getRoot());(h=d.next())&&h!=a;)g.isBlock(h)&&f.push(h)}a&&e!=a&&f.push(a);
return f},normalize:function(){function e(f){var d,j,k,b=a.dom;k=b.getRoot();var c;d=g[(f?"start":"end")+"Container"];j=g[(f?"start":"end")+"Offset"];if(d.nodeType===9){d=d.body;j=0}if(d===k)if(d.hasChildNodes()){d=d.childNodes[Math.min(!f&&j>0?j-1:j,d.childNodes.length-1)];j=0;if(d.hasChildNodes()){c=d;k=new n.dom.TreeWalker(d,k);do{if(c.nodeType===3){j=f?0:c.nodeValue.length-1;d=c;break}if(c.nodeName==="BR"){j=b.nodeIndex(c);d=c.parentNode;break}}while(c=f?k.next():k.prev());h=true}}if(h)g["set"+
(f?"Start":"End")](d,j)}var a=this,g,h;if(!n.isIE){g=a.getRng();e(true);g.collapsed&&e();h&&a.setRng(g)}},destroy:function(e){this.win=null;e||n.removeUnload(this.destroy)},_fixIESelection:function(){function e(c,l){var s=d.createTextRange();try{s.moveToPoint(c,l)}catch(i){s=null}return s}function a(c){if(c.button){if(c=e(c.x,c.y)){c.compareEndPoints("StartToStart",k)>0?c.setEndPoint("StartToStart",k):c.setEndPoint("EndToEnd",k);c.select()}}else g()}function g(){var c=f.selection.createRange();k&&
!c.item&&c.compareEndPoints("StartToEnd",c)===0&&k.select();h.unbind(f,"mouseup",g);h.unbind(f,"mousemove",a);k=j=0}var h=this.dom,f=h.doc,d=f.body,j,k,b;f.documentElement.unselectable=true;h.bind(f,["mousedown","contextmenu"],function(c){if(c.target.nodeName==="HTML"){j&&g();b=f.documentElement;if(!(b.scrollHeight>b.clientHeight)){j=1;if(k=e(c.x,c.y)){h.bind(f,"mouseup",g);h.bind(f,"mousemove",a);h.win.focus();k.select()}}}})}})})(tinymce);
(function(n){n.dom.Serializer=function(p,o,q){var e,a,g=n.isIE,h=n.each,f;if(!p.apply_source_formatting)p.indent=false;p.remove_trailing_brs=true;o=o||n.DOM;q=q||new n.html.Schema(p);p.entity_encoding=p.entity_encoding||"named";e=new n.util.Dispatcher(self);a=new n.util.Dispatcher(self);f=new n.html.DomParser(p,q);f.addAttributeFilter("src,href,style",function(d,j){for(var k=d.length,b,c,l="data-mce-"+j,s=p.url_converter,i=p.url_converter_scope;k--;){b=d[k];c=b.attributes.map[l];if(c!==void 0){b.attr(j,
c.length>0?c:null);b.attr(l,null)}else{c=b.attributes.map[j];if(j==="style")c=o.serializeStyle(o.parseStyle(c),b.name);else if(s)c=s.call(i,c,j,b.name);b.attr(j,c.length>0?c:null)}}});f.addAttributeFilter("class",function(d){for(var j=d.length,k,b;j--;){k=d[j];b=k.attr("class").replace(/\s*mce(Item\w+|Selected)\s*/g,"");k.attr("class",b.length>0?b:null)}});f.addAttributeFilter("data-mce-type",function(d,j,k){j=d.length;for(var b;j--;){b=d[j];b.attributes.map["data-mce-type"]==="bookmark"&&!k.cleanup&&
b.remove()}});f.addNodeFilter("script,style",function(d,j){function k(s){return s.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 b=d.length,c,l;b--;){c=d[b];l=c.firstChild?c.firstChild.value:"";if(j==="script"){c.attr("type",(c.attr("type")||"text/javascript").replace(/^mce\-/,""));if(l.length>0)c.firstChild.value="// <![CDATA[\n"+
k(l)+"\n// ]]\>"}else if(l.length>0)c.firstChild.value="<!--\n"+k(l)+"\n--\>"}});f.addNodeFilter("#comment",function(d){for(var j=d.length,k;j--;){k=d[j];if(k.value.indexOf("[CDATA[")===0){k.name="#cdata";k.type=4;k.value=k.value.replace(/^\[CDATA\[|\]\]$/g,"")}else if(k.value.indexOf("mce:protected ")===0){k.name="#text";k.type=3;k.raw=true;k.value=unescape(k.value).substr(14)}}});f.addNodeFilter("xml:namespace,input",function(d,j){for(var k=d.length,b;k--;){b=d[k];if(b.type===7)b.remove();else b.type===
1&&j==="input"&&!("type"in b.attributes.map)&&b.attr("type","text")}});p.fix_list_elements&&f.addNodeFilter("ul,ol",function(d){for(var j=d.length,k,b;j--;){k=d[j];b=k.parent;if(b.name==="ul"||b.name==="ol")k.prev&&k.prev.name==="li"&&k.prev.append(k)}});f.addAttributeFilter("data-mce-src,data-mce-href,data-mce-style",function(d,j){for(var k=d.length;k--;)d[k].attr(j,null)});return{schema:q,addNodeFilter:f.addNodeFilter,addAttributeFilter:f.addAttributeFilter,onPreProcess:e,onPostProcess:a,serialize:function(d,
j){var k,b,c;if(g&&o.select("script,style,select,map").length>0){k=d.innerHTML;d=d.cloneNode(false);o.setHTML(d,k)}else d=d.cloneNode(true);k=d.ownerDocument.implementation;if(k.createHTMLDocument){b=k.createHTMLDocument("");h(d.nodeName=="BODY"?d.childNodes:[d],function(l){b.body.appendChild(b.importNode(l,true))});d=d.nodeName!="BODY"?b.body.firstChild:b.body;c=o.doc;o.doc=b}j=j||{};j.format=j.format||"html";if(!j.no_events){j.node=d;e.dispatch(self,j)}k=new n.html.Serializer(p,q);j.content=k.serialize(f.parse(j.getInner?
d.innerHTML:n.trim(o.getOuterHTML(d),j),j));if(!j.cleanup)j.content=j.content.replace(/\uFEFF|\u200B/g,"");j.no_events||a.dispatch(self,j);if(c)o.doc=c;j.node=null;return j.content},addRules:function(d){q.addValidElements(d)},setRules:function(d){q.setValidElements(d)}}}})(tinymce);
(function(n){n.dom.ScriptLoader=function(){function p(h,f){function d(){k.remove(s);if(b)b.onreadystatechange=b.onload=b=null;f()}function j(){typeof console!=="undefined"&&console.log&&console.log("Failed to load: "+h)}var k=n.DOM,b,c,l,s;s=k.uniqueId();if(n.isIE6){c=new n.util.URI(h);l=location;if(c.host==l.hostname&&c.port==l.port&&c.protocol+":"==l.protocol&&c.protocol.toLowerCase()!="file"){n.util.XHR.send({url:n._addVer(c.getURI()),success:function(i){var m=k.create("script",{type:"text/javascript"});
m.text=i;document.getElementsByTagName("head")[0].appendChild(m);k.remove(m);d()},error:j});return}}b=k.create("script",{id:s,type:"text/javascript",src:n._addVer(h)});if(!n.isIE)b.onload=d;b.onerror=j;if(!n.isOpera)b.onreadystatechange=function(){var i=b.readyState;if(i=="complete"||i=="loaded")d()};(document.getElementsByTagName("head")[0]||document.body).appendChild(b)}var o={},q=[],e={},a=[],g=0;this.isDone=function(h){return o[h]==2};this.markDone=function(h){o[h]=2};this.add=this.load=function(h,
f,d){if(o[h]==void 0){q.push(h);o[h]=0}if(f){e[h]||(e[h]=[]);e[h].push({func:f,scope:d||this})}};this.loadQueue=function(h,f){this.loadScripts(q,h,f)};this.loadScripts=function(h,f,d){function j(b){n.each(e[b],function(c){c.func.call(c.scope)});e[b]=void 0}var k;a.push({func:f,scope:d||this});k=function(){var b=n.grep(h);h.length=0;n.each(b,function(c){if(o[c]==2)j(c);else if(o[c]!=1){o[c]=1;g++;p(c,function(){o[c]=2;g--;j(c);k()})}});if(!g){n.each(a,function(c){c.func.call(c.scope)});a.length=0}};
k()}};n.ScriptLoader=new n.dom.ScriptLoader})(tinymce);tinymce.dom.TreeWalker=function(n,p){function o(e,a,g,h){if(e){if(!h&&e[a])return e[a];if(e!=p){if(a=e[g])return a;for(e=e.parentNode;e&&e!=p;e=e.parentNode)if(a=e[g])return a}}}var q=n;this.current=function(){return q};this.next=function(e){return q=o(q,"firstChild","nextSibling",e)};this.prev=function(e){return q=o(q,"lastChild","previousSibling",e)}};
(function(n){n.dom.RangeUtils=function(p){this.walk=function(o,q){function e(i){var m;m=i[0];m.nodeType===3&&m===f&&d>=m.nodeValue.length&&i.splice(0,1);m=i[i.length-1];k===0&&i.length>0&&m===j&&m.nodeType===3&&i.splice(i.length-1,1);return i}function a(i,m,r){for(var t=[];i&&i!=r;i=i[m])t.push(i);return t}function g(i,m){do{if(i.parentNode==m)return i;i=i.parentNode}while(i)}function h(i,m,r){var t=r?"nextSibling":"previousSibling";c=i;for(l=c.parentNode;c&&c!=m;c=l){l=c.parentNode;s=a(c==i?c:c[t],
t);if(s.length){r||s.reverse();q(e(s))}}}var f=o.startContainer,d=o.startOffset,j=o.endContainer,k=o.endOffset,b,c,l,s;o=p.select("td.mceSelected,th.mceSelected");if(o.length>0)n.each(o,function(i){q([i])});else{if(f.nodeType==1&&f.hasChildNodes())f=f.childNodes[d];if(j.nodeType==1&&j.hasChildNodes())j=j.childNodes[Math.min(k-1,j.childNodes.length-1)];if(f==j)return q(e([f]));b=p.findCommonAncestor(f,j);for(c=f;c;c=c.parentNode){if(c===j)return h(f,b,true);if(c===b)break}for(c=j;c;c=c.parentNode){if(c===
f)return h(j,b);if(c===b)break}o=g(f,b)||f;b=g(j,b)||j;h(f,o,true);s=a(o==f?o:o.nextSibling,"nextSibling",b==j?b.nextSibling:b);s.length&&q(e(s));h(j,b)}};this.split=function(o){function q(h,f){return h.splitText(f)}var e=o.startContainer,a=o.startOffset,g=o.endContainer;o=o.endOffset;if(e==g&&e.nodeType==3){if(a>0&&a<e.nodeValue.length){g=q(e,a);e=g.previousSibling;if(o>a){o-=a;e=g=q(g,o).previousSibling;o=g.nodeValue.length;a=0}else o=0}}else{if(e.nodeType==3&&a>0&&a<e.nodeValue.length){e=q(e,a);
a=0}if(g.nodeType==3&&o>0&&o<g.nodeValue.length){g=q(g,o).previousSibling;o=g.nodeValue.length}}return{startContainer:e,startOffset:a,endContainer:g,endOffset:o}}};n.dom.RangeUtils.compareRanges=function(p,o){if(p&&o)if(p.item||p.duplicate){if(p.item&&o.item&&p.item(0)===o.item(0))return true;if(p.isEqual&&o.isEqual&&o.isEqual(p))return true}else return p.startContainer==o.startContainer&&p.startOffset==o.startOffset;return false}})(tinymce);
(function(n){var p=n.dom.Event,o=n.each;n.create("tinymce.ui.KeyboardNavigation",{KeyboardNavigation:function(q,e){var a=this,g=q.root,h=q.items,f=q.enableUpDown,d=q.enableLeftRight||!q.enableUpDown,j=q.excludeFromTabOrder,k,b,c,l,s;e=e||n.DOM;k=function(i){s=i.target.id};b=function(i){e.setAttrib(i.target.id,"tabindex","-1")};l=function(){var i=e.get(s);e.setAttrib(i,"tabindex","0");i.focus()};a.focus=function(){e.get(s).focus()};a.destroy=function(){o(h,function(i){e.unbind(e.get(i.id),"focus",
k);e.unbind(e.get(i.id),"blur",b)});e.unbind(e.get(g),"focus",l);e.unbind(e.get(g),"keydown",c);h=e=g=a.focus=k=b=c=l=null;a.destroy=function(){}};a.moveFocus=function(i,m){var r=-1;if(s){o(h,function(t,u){if(t.id===s){r=u;return false}});r+=i;if(r<0)r=h.length-1;else if(r>=h.length)r=0;i=h[r];e.setAttrib(s,"tabindex","-1");e.setAttrib(i.id,"tabindex","0");e.get(i.id).focus();q.actOnFocus&&q.onAction(i.id);m&&p.cancel(m)}};c=function(i){switch(i.keyCode){case 37:d&&a.moveFocus(-1);break;case 39:d&&
a.moveFocus(1);break;case 38:f&&a.moveFocus(-1);break;case 40:f&&a.moveFocus(1);break;case 27:if(q.onCancel){q.onCancel();p.cancel(i)}break;case 14:case 13:case 32:if(q.onAction){q.onAction(s);p.cancel(i)}break}};o(h,function(i,m){if(!i.id)i.id=e.uniqueId("_mce_item_");if(j){e.bind(i.id,"blur",b);m="-1"}else m=m===0?"0":"-1";e.setAttrib(i.id,"tabindex",m);e.bind(e.get(i.id),"focus",k)});if(h[0])s=h[0].id;e.setAttrib(g,"tabindex","-1");e.bind(e.get(g),"focus",l);e.bind(e.get(g),"keydown",c)}})})(tinymce);
(function(n){var p=n.DOM,o=n.is;n.create("tinymce.ui.Control",{Control:function(q,e,a){this.id=q;this.settings=e=e||{};this.rendered=false;this.onRender=new n.util.Dispatcher(this);this.classPrefix="";this.scope=e.scope||this;this.active=this.disabled=0;this.editor=a},setAriaProperty:function(q,e){var a=p.get(this.id+"_aria")||p.get(this.id);a&&p.setAttrib(a,"aria-"+q,!!e)},focus:function(){p.get(this.id).focus()},setDisabled:function(q){if(q!=this.disabled){this.setAriaProperty("disabled",q);this.setState("Disabled",
q);this.setState("Enabled",!q);this.disabled=q}},isDisabled:function(){return this.disabled},setActive:function(q){if(q!=this.active){this.setState("Active",q);this.active=q;this.setAriaProperty("pressed",q)}},isActive:function(){return this.active},setState:function(q,e){var a=p.get(this.id);q=this.classPrefix+q;e?p.addClass(a,q):p.removeClass(a,q)},isRendered:function(){return this.rendered},renderHTML:function(){},renderTo:function(q){p.setHTML(q,this.renderHTML())},postRender:function(){var q;
if(o(this.disabled)){q=this.disabled;this.disabled=-1;this.setDisabled(q)}if(o(this.active)){q=this.active;this.active=-1;this.setActive(q)}},remove:function(){p.remove(this.id);this.destroy()},destroy:function(){n.dom.Event.clear(this.id)}})})(tinymce);tinymce.create("tinymce.ui.Container:tinymce.ui.Control",{Container:function(n,p,o){this.parent(n,p,o);this.controls=[];this.lookup={}},add:function(n){this.lookup[n.id]=n;this.controls.push(n);return n},get:function(n){return this.lookup[n]}});
tinymce.create("tinymce.ui.Separator:tinymce.ui.Control",{Separator:function(n,p){this.parent(n,p);this.classPrefix="mceSeparator";this.setDisabled(true)},renderHTML:function(){return tinymce.DOM.createHTML("span",{"class":this.classPrefix,role:"separator","aria-orientation":"vertical",tabindex:"-1"})}});
(function(n){var p=n.is;n.create("tinymce.ui.MenuItem:tinymce.ui.Control",{MenuItem:function(o,q){this.parent(o,q);this.classPrefix="mceMenuItem"},setSelected:function(o){this.setState("Selected",o);this.setAriaProperty("checked",!!o);this.selected=o},isSelected:function(){return this.selected},postRender:function(){this.parent();p(this.selected)&&this.setSelected(this.selected)}})})(tinymce);
(function(n){var p=n.DOM,o=n.walk;n.create("tinymce.ui.Menu:tinymce.ui.MenuItem",{Menu:function(q,e){this.parent(q,e);this.items={};this.collapsed=false;this.menuCount=0;this.onAddItem=new n.util.Dispatcher(this)},expand:function(q){q&&o(this,function(e){e.expand&&e.expand()},"items",this);this.collapsed=false},collapse:function(q){q&&o(this,function(e){e.collapse&&e.collapse()},"items",this);this.collapsed=true},isCollapsed:function(){return this.collapsed},add:function(q){q.settings||(q=new n.ui.MenuItem(q.id||
p.uniqueId(),q));this.onAddItem.dispatch(this,q);return this.items[q.id]=q},addSeparator:function(){return this.add({separator:true})},addMenu:function(q){q.collapse||(q=this.createMenu(q));this.menuCount++;return this.add(q)},hasMenus:function(){return this.menuCount!==0},remove:function(q){delete this.items[q.id]},removeAll:function(){o(this,function(q){q.removeAll?q.removeAll():q.remove();q.destroy()},"items",this);this.items={}},createMenu:function(q){q=new n.ui.Menu(q.id||p.uniqueId(),q);q.onAddItem.add(this.onAddItem.dispatch,
this.onAddItem);return q}})})(tinymce);
(function(n){var p=n.is,o=n.DOM,q=n.each,e=n.dom.Event,a=n.dom.Element;n.create("tinymce.ui.DropMenu:tinymce.ui.Menu",{DropMenu:function(g,h){h=h||{};h.container=h.container||o.doc.body;h.offset_x=h.offset_x||0;h.offset_y=h.offset_y||0;h.vp_offset_x=h.vp_offset_x||0;h.vp_offset_y=h.vp_offset_y||0;if(p(h.icons)&&!h.icons)h["class"]+=" mceNoIcons";this.parent(g,h);this.onShowMenu=new n.util.Dispatcher(this);this.onHideMenu=new n.util.Dispatcher(this);this.classPrefix="mceMenu"},createMenu:function(g){var h=
this.settings;g.container=g.container||h.container;g.parent=this;g.constrain=g.constrain||h.constrain;g["class"]=g["class"]||h["class"];g.vp_offset_x=g.vp_offset_x||h.vp_offset_x;g.vp_offset_y=g.vp_offset_y||h.vp_offset_y;g.keyboard_focus=h.keyboard_focus;g=new n.ui.DropMenu(g.id||o.uniqueId(),g);g.onAddItem.add(this.onAddItem.dispatch,this.onAddItem);return g},focus:function(){this.keyboardNav&&this.keyboardNav.focus()},update:function(){var g=this.settings,h=o.get("menu_"+this.id+"_tbl"),f=o.get("menu_"+
this.id+"_co"),d,j;d=g.max_width?Math.min(h.clientWidth,g.max_width):h.clientWidth;j=g.max_height?Math.min(h.clientHeight,g.max_height):h.clientHeight;o.boxModel?this.element.setStyles({width:d,height:j}):this.element.setStyles({width:d+2,height:j+2});g.max_width&&o.setStyle(f,"width",d);if(g.max_height){o.setStyle(f,"height",j);h.clientHeight<g.max_height&&o.setStyle(f,"overflow","hidden")}},showMenu:function(g,h,f){var d=this,j=d.settings,k,b=o.getViewPort(),c,l,s,i,m=d.classPrefix;d.collapse(1);
if(!d.isMenuVisible){if(d.rendered)k=o.get("menu_"+d.id);else{k=o.add(d.settings.container,d.renderNode());q(d.items,function(r){r.postRender()});d.element=new a("menu_"+d.id,{blocker:1,container:j.container})}n.isOpera||o.setStyles(k,{left:-65535,top:-65535});o.show(k);d.update();g+=j.offset_x||0;h+=j.offset_y||0;b.w-=4;b.h-=4;if(j.constrain){c=k.clientWidth-2;l=k.clientHeight-2;s=b.x+b.w;b=b.y+b.h;if(g+j.vp_offset_x+c>s)g=f?f-c:Math.max(0,s-j.vp_offset_x-c);if(h+j.vp_offset_y+l>b)h=Math.max(0,b-
j.vp_offset_y-l)}o.setStyles(k,{left:g,top:h});d.element.update();d.isMenuVisible=1;d.mouseClickFunc=e.add(k,"click",function(r){var t;if((r=r.target)&&(r=o.getParent(r,"tr"))&&!o.hasClass(r,m+"ItemSub")){t=d.items[r.id];if(!t.isDisabled()){for(i=d;i;){i.hideMenu&&i.hideMenu();i=i.settings.parent}t.settings.onclick&&t.settings.onclick(r);return e.cancel(r)}}});if(d.hasMenus())d.mouseOverFunc=e.add(k,"mouseover",function(r){var t;if((r=r.target)&&(r=o.getParent(r,"tr"))){t=d.items[r.id];d.lastMenu&&
d.lastMenu.collapse(1);if(!t.isDisabled())if(r&&o.hasClass(r,m+"ItemSub")){r=o.getRect(r);t.showMenu(r.x+r.w-2,r.y-2,r.x);d.lastMenu=t;o.addClass(o.get(t.id).firstChild,m+"ItemActive")}}});e.add(k,"keydown",d._keyHandler,d);d.onShowMenu.dispatch(d);j.keyboard_focus&&d._setupKeyboardNav()}},hideMenu:function(g){var h=o.get("menu_"+this.id);if(this.isMenuVisible){this.keyboardNav&&this.keyboardNav.destroy();e.remove(h,"mouseover",this.mouseOverFunc);e.remove(h,"click",this.mouseClickFunc);e.remove(h,
"keydown",this._keyHandler);o.hide(h);this.isMenuVisible=0;g||this.collapse(1);this.element&&this.element.hide();if(g=o.get(this.id))o.removeClass(g.firstChild,this.classPrefix+"ItemActive");this.onHideMenu.dispatch(this)}},add:function(g){var h;g=this.parent(g);if(this.isRendered&&(h=o.get("menu_"+this.id)))this._add(o.select("tbody",h)[0],g);return g},collapse:function(g){this.parent(g);this.hideMenu(1)},remove:function(g){o.remove(g.id);this.destroy();return this.parent(g)},destroy:function(){var g=
o.get("menu_"+this.id);this.keyboardNav&&this.keyboardNav.destroy();e.remove(g,"mouseover",this.mouseOverFunc);e.remove(o.select("a",g),"focus",this.mouseOverFunc);e.remove(g,"click",this.mouseClickFunc);e.remove(g,"keydown",this._keyHandler);this.element&&this.element.remove();o.remove(g)},renderNode:function(){var g=this,h=g.settings,f,d,j;j=o.create("div",{role:"listbox",id:"menu_"+g.id,"class":h["class"],style:"position:absolute;left:0;top:0;z-index:200000;outline:0"});g.settings.parent&&o.setAttrib(j,
"aria-parent","menu_"+g.settings.parent.id);d=o.add(j,"div",{role:"presentation",id:"menu_"+g.id+"_co","class":g.classPrefix+(h["class"]?" "+h["class"]:"")});g.element=new a("menu_"+g.id,{blocker:1,container:h.container});h.menu_line&&o.add(d,"span",{"class":g.classPrefix+"Line"});h=o.add(d,"table",{role:"presentation",id:"menu_"+g.id+"_tbl",border:0,cellPadding:0,cellSpacing:0});f=o.add(h,"tbody");q(g.items,function(k){g._add(f,k)});g.rendered=true;return j},_setupKeyboardNav:function(){var g,h,
f=this;g=o.select("#menu_"+f.id)[0];h=o.select("a[role=option]","menu_"+f.id);h.splice(0,0,g);f.keyboardNav=new n.ui.KeyboardNavigation({root:"menu_"+f.id,items:h,onCancel:function(){f.hideMenu()},enableUpDown:true});g.focus()},_keyHandler:function(g){switch(g.keyCode){case 37:if(this.settings.parent){this.hideMenu();this.settings.parent.focus();e.cancel(g)}break;case 39:this.mouseOverFunc&&this.mouseOverFunc(g);break}},_add:function(g,h){var f,d=h.settings,j,k,b,c=this.classPrefix;if(d.separator){k=
o.add(g,"tr",{id:h.id,"class":c+"ItemSeparator"});o.add(k,"td",{"class":c+"ItemSeparator"});if(f=k.previousSibling)o.addClass(f,"mceLast")}else{f=k=o.add(g,"tr",{id:h.id,"class":c+"Item "+c+"ItemEnabled"});f=b=o.add(f,d.titleItem?"th":"td");f=j=o.add(f,"a",{id:h.id+"_aria",role:d.titleItem?"presentation":"option",href:"javascript:;",onclick:"return false;",onmousedown:"return false;"});if(d.parent){o.setAttrib(j,"aria-haspopup","true");o.setAttrib(j,"aria-owns","menu_"+h.id)}o.addClass(b,d["class"]);
j=o.add(f,"span",{"class":"mceIcon"+(d.icon?" mce_"+d.icon:"")});d.icon_src&&o.add(j,"img",{src:d.icon_src});f=o.add(f,d.element||"span",{"class":"mceText",title:h.settings.title},h.settings.title);h.settings.style&&o.setAttrib(f,"style",h.settings.style);g.childNodes.length==1&&o.addClass(k,"mceFirst");if((f=k.previousSibling)&&o.hasClass(f,c+"ItemSeparator"))o.addClass(k,"mceFirst");h.collapse&&o.addClass(k,c+"ItemSub");if(f=k.previousSibling)o.removeClass(f,"mceLast");o.addClass(k,"mceLast")}}})})(tinymce);
(function(n){var p=n.DOM;n.create("tinymce.ui.Button:tinymce.ui.Control",{Button:function(o,q,e){this.parent(o,q,e);this.classPrefix="mceButton"},renderHTML:function(){var o=this.classPrefix,q=this.settings,e,a;a=p.encode(q.label||"");e='<a role="button" id="'+this.id+'" href="javascript:;" class="'+o+" "+o+"Enabled "+q["class"]+(a?" "+o+"Labeled":"")+'" onmousedown="return false;" onclick="return false;" aria-labelledby="'+this.id+'_voice" title="'+p.encode(q.title)+'">';e+=q.image&&!(this.editor&&
this.editor.forcedHighContrastMode)?'<img class="mceIcon" src="'+q.image+'" alt="'+p.encode(q.title)+'" />'+a:'<span class="mceIcon '+q["class"]+'"></span>'+(a?'<span class="'+o+'Label">'+a+"</span>":"");e+='<span class="mceVoiceLabel mceIconOnly" style="display: none;" id="'+this.id+'_voice">'+q.title+"</span>";e+="</a>";return e},postRender:function(){var o=this,q=o.settings;n.dom.Event.add(o.id,"click",function(e){if(!o.isDisabled())return q.onclick.call(q.scope,e)})}})})(tinymce);
(function(n){var p=n.DOM,o=n.dom.Event,q=n.each,e=n.util.Dispatcher;n.create("tinymce.ui.ListBox:tinymce.ui.Control",{ListBox:function(a,g,h){this.parent(a,g,h);this.items=[];this.onChange=new e(this);this.onPostRender=new e(this);this.onAdd=new e(this);this.onRenderMenu=new n.util.Dispatcher(this);this.classPrefix="mceListBox"},select:function(a){var g=this,h,f;if(a==undefined)return g.selectByIndex(-1);f=a&&a.call?a:function(d){return d==a};if(a!=g.selectedValue){q(g.items,function(d,j){if(f(d.value)){h=
1;g.selectByIndex(j);return false}});h||g.selectByIndex(-1)}},selectByIndex:function(a){var g,h,f;if(a!=this.selectedIndex){g=p.get(this.id+"_text");f=p.get(this.id+"_voiceDesc");if(h=this.items[a]){this.selectedValue=h.value;this.selectedIndex=a;p.setHTML(g,p.encode(h.title));p.setHTML(f,this.settings.title+" - "+h.title);p.removeClass(g,"mceTitle");p.setAttrib(this.id,"aria-valuenow",h.title)}else{p.setHTML(g,p.encode(this.settings.title));p.setHTML(f,p.encode(this.settings.title));p.addClass(g,
"mceTitle");this.selectedValue=this.selectedIndex=null;p.setAttrib(this.id,"aria-valuenow",this.settings.title)}}},add:function(a,g,h){h=h||{};h=n.extend(h,{title:a,value:g});this.items.push(h);this.onAdd.dispatch(this,h)},getLength:function(){return this.items.length},renderHTML:function(){var a="";a=this.settings;var g=this.classPrefix;a='<span role="listbox" aria-haspopup="true" aria-labelledby="'+this.id+'_voiceDesc" aria-describedby="'+this.id+'_voiceDesc"><table role="presentation" tabindex="0" id="'+
this.id+'" cellpadding="0" cellspacing="0" class="'+g+" "+g+"Enabled"+(a["class"]?" "+a["class"]:"")+'"><tbody><tr>';a+="<td>"+p.createHTML("span",{id:this.id+"_voiceDesc","class":"voiceLabel",style:"display:none;"},this.settings.title);a+=p.createHTML("a",{id:this.id+"_text",tabindex:-1,href:"javascript:;","class":"mceText",onclick:"return false;",onmousedown:"return false;"},p.encode(this.settings.title))+"</td>";a+="<td>"+p.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,g,h=p.get(this.id),f;if(!(a.isDisabled()||a.items.length==0)){if(a.menu&&a.menu.isMenuVisible)return a.hideMenu();if(!a.isMenuRendered){a.renderMenu();a.isMenuRendered=true}g=p.getPos(h);f=a.menu;var d=f.id.split("_")[0]+"_parent";d=p.get(d);p.setStyles(d,{position:"relative",
display:"block"});var j=p.getPos(d);f.settings.container=d;f.settings.offset_x=g.x-j.x;f.settings.offset_y=g.y-j.y;f.settings.keyboard_focus=!n.isOpera;a.oldID&&f.items[a.oldID].setSelected(0);q(a.items,function(k){if(k.value===a.selectedValue){f.items[k.id].setSelected(1);a.oldID=k.id}});f.showMenu(0,h.clientHeight);o.add(p.doc,"mousedown",a.hideMenu,a);p.addClass(a.id,a.classPrefix+"Selected")}},hideMenu:function(a){if(this.menu&&this.menu.isMenuVisible){p.removeClass(this.id,this.classPrefix+"Selected");
if(!(a&&a.type=="mousedown"&&(a.target.id==this.id+"_text"||a.target.id==this.id+"_open")))if(!a||!p.getParent(a.target,".mceMenu")){p.removeClass(this.id,this.classPrefix+"Selected");o.remove(p.doc,"mousedown",this.hideMenu,this);this.menu.hideMenu()}}},renderMenu:function(){var a=this,g;g=a.settings.control_manager.createDropMenu(a.id+"_menu",{menu_line:1,"class":a.classPrefix+"Menu mceNoIcons",max_width:150,max_height:150});g.onHideMenu.add(function(){a.hideMenu();a.focus()});g.add({title:a.settings.title,
"class":"mceMenuItemTitle",onclick:function(){a.settings.onselect("")!==false&&a.select("")}});q(a.items,function(h){if(h.value===undefined)g.add({title:h.title,role:"option","class":"mceMenuItemTitle",onclick:function(){a.settings.onselect("")!==false&&a.select("")}});else{h.id=p.uniqueId();h.role="option";h.onclick=function(){a.settings.onselect(h.value)!==false&&a.select(h.value)};g.add(h)}});a.onRenderMenu.dispatch(a,g);a.menu=g},postRender:function(){var a=this,g=a.classPrefix;o.add(a.id,"click",
a.showMenu,a);o.add(a.id,"keydown",function(h){if(h.keyCode==32){a.showMenu(h);o.cancel(h)}});o.add(a.id,"focus",function(){if(!a._focused){a.keyDownHandler=o.add(a.id,"keydown",function(h){if(h.keyCode==40){a.showMenu();o.cancel(h)}});a.keyPressHandler=o.add(a.id,"keypress",function(h){var f;if(h.keyCode==13){f=a.selectedValue;a.selectedValue=null;o.cancel(h);a.settings.onselect(f)}})}a._focused=1});o.add(a.id,"blur",function(){o.remove(a.id,"keydown",a.keyDownHandler);o.remove(a.id,"keypress",a.keyPressHandler);
a._focused=0});if(n.isIE6||!p.boxModel){o.add(a.id,"mouseover",function(){p.hasClass(a.id,g+"Disabled")||p.addClass(a.id,g+"Hover")});o.add(a.id,"mouseout",function(){p.hasClass(a.id,g+"Disabled")||p.removeClass(a.id,g+"Hover")})}a.onPostRender.dispatch(a,p.get(a.id))},destroy:function(){this.parent();o.clear(this.id+"_text");o.clear(this.id+"_open")}})})(tinymce);
(function(n){var p=n.DOM,o=n.dom.Event,q=n.each;n.create("tinymce.ui.NativeListBox:tinymce.ui.ListBox",{NativeListBox:function(e,a){this.parent(e,a);this.classPrefix="mceNativeListBox"},setDisabled:function(e){p.get(this.id).disabled=e;this.setAriaProperty("disabled",e)},isDisabled:function(){return p.get(this.id).disabled},select:function(e){var a=this,g,h;if(e==undefined)return a.selectByIndex(-1);h=e&&e.call?e:function(f){return f==e};if(e!=a.selectedValue){q(a.items,function(f,d){if(h(f.value)){g=
1;a.selectByIndex(d);return false}});g||a.selectByIndex(-1)}},selectByIndex:function(e){p.get(this.id).selectedIndex=e+1;this.selectedValue=this.items[e]?this.items[e].value:null},add:function(e,a,g){g=g||{};g.value=a;this.isRendered()&&p.add(p.get(this.id),"option",g,e);e={title:e,value:a,attribs:g};this.items.push(e);this.onAdd.dispatch(this,e)},getLength:function(){return this.items.length},renderHTML:function(){var e;e=p.createHTML("option",{value:""},"-- "+this.settings.title+" --");q(this.items,
function(a){e+=p.createHTML("option",{value:a.value},a.title)});e=p.createHTML("select",{id:this.id,"class":"mceNativeListBox","aria-labelledby":this.id+"_aria"},e);e+=p.createHTML("span",{id:this.id+"_aria",style:"display: none"},this.settings.title);return e},postRender:function(){function e(h){if((h=a.items[h.target.selectedIndex-1])&&(h=h.value)){a.onChange.dispatch(a,h);a.settings.onselect&&a.settings.onselect(h)}}var a=this,g=true;a.rendered=true;o.add(a.id,"change",e);o.add(a.id,"keydown",
function(h){var f;o.remove(a.id,"change",void 0);g=false;f=o.add(a.id,"blur",function(){if(!g){g=true;o.add(a.id,"change",e);o.remove(a.id,"blur",f)}});if(n.isWebKit&&(h.keyCode==37||h.keyCode==39))return o.prevent(h);if(h.keyCode==13||h.keyCode==32){e(h);return o.cancel(h)}});a.onPostRender.dispatch(a,p.get(a.id))}})})(tinymce);
(function(n){var p=n.DOM,o=n.dom.Event;n.create("tinymce.ui.MenuButton:tinymce.ui.Button",{MenuButton:function(q,e,a){this.parent(q,e,a);this.onRenderMenu=new n.util.Dispatcher(this);e.menu_container=e.menu_container||p.doc.body},showMenu:function(){var q,e=p.get(this.id),a;if(!this.isDisabled()){if(!this.isMenuRendered){this.renderMenu();this.isMenuRendered=true}if(this.isMenuVisible)return this.hideMenu();p.getPos(this.settings.menu_container);q=p.getPos(e);a=this.menu;a.settings.offset_x=q.x;a.settings.offset_y=
q.y;a.settings.vp_offset_x=q.x;a.settings.vp_offset_y=q.y;a.settings.keyboard_focus=this._focused;a.showMenu(0,e.clientHeight);o.add(p.doc,"mousedown",this.hideMenu,this);this.setState("Selected",1);this.isMenuVisible=1}},renderMenu:function(){var q=this,e;e=q.settings.control_manager.createDropMenu(q.id+"_menu",{menu_line:1,"class":this.classPrefix+"Menu",icons:q.settings.icons});e.onHideMenu.add(function(){q.hideMenu();q.focus()});q.onRenderMenu.dispatch(q,e);q.menu=e},hideMenu:function(q){var e=
this;if(!(q&&q.type=="mousedown"&&p.getParent(q.target,function(a){return a.id===e.id||a.id===e.id+"_open"}))){if(!q||!p.getParent(q.target,".mceMenu")){e.setState("Selected",0);o.remove(p.doc,"mousedown",e.hideMenu,e);e.menu&&e.menu.hideMenu()}e.isMenuVisible=0}},postRender:function(){var q=this,e=q.settings;o.add(q.id,"click",function(){if(!q.isDisabled()){e.onclick&&e.onclick(q.value);q.showMenu()}})}})})(tinymce);
(function(n){var p=n.DOM,o=n.dom.Event;n.create("tinymce.ui.SplitButton:tinymce.ui.MenuButton",{SplitButton:function(q,e,a){this.parent(q,e,a);this.classPrefix="mceSplitButton"},renderHTML:function(){var q,e=this.settings,a;q="<tbody><tr>";a=e.image?p.createHTML("img ",{src:e.image,role:"presentation","class":"mceAction "+e["class"]}):p.createHTML("span",{"class":"mceAction "+e["class"]},"");a+=p.createHTML("span",{"class":"mceVoiceLabel mceIconOnly",id:this.id+"_voice",style:"display:none;"},e.title);
q+="<td >"+p.createHTML("a",{role:"button",id:this.id+"_action",tabindex:"-1",href:"javascript:;","class":"mceAction "+e["class"],onclick:"return false;",onmousedown:"return false;",title:e.title},a)+"</td>";a=p.createHTML("span",{"class":"mceOpen "+e["class"]},'<span style="display:none;" class="mceIconOnly" aria-hidden="true">\u25bc</span>');q+="<td >"+p.createHTML("a",{role:"button",id:this.id+"_open",tabindex:"-1",href:"javascript:;","class":"mceOpen "+e["class"],onclick:"return false;",onmousedown:"return false;",
title:e.title},a)+"</td>";q+="</tr></tbody>";q=p.createHTML("table",{role:"presentation","class":"mceSplitButton mceSplitButtonEnabled "+e["class"],cellpadding:"0",cellspacing:"0",title:e.title},q);return p.createHTML("div",{id:this.id,role:"button",tabindex:"0","aria-labelledby":this.id+"_voice","aria-haspopup":"true"},q)},postRender:function(){var q=this,e=q.settings,a;if(e.onclick){a=function(g){if(!q.isDisabled()){e.onclick(q.value);o.cancel(g)}};o.add(q.id+"_action","click",a);o.add(q.id,["click",
"keydown"],function(g){if((g.keyCode===32||g.keyCode===13||g.keyCode===14)&&!g.altKey&&!g.ctrlKey&&!g.metaKey){a();o.cancel(g)}else if(g.type==="click"||g.keyCode===40){q.showMenu();o.cancel(g)}})}o.add(q.id+"_open","click",function(g){q.showMenu();o.cancel(g)});o.add([q.id,q.id+"_open"],"focus",function(){q._focused=1});o.add([q.id,q.id+"_open"],"blur",function(){q._focused=0});if(n.isIE6||!p.boxModel){o.add(q.id,"mouseover",function(){p.hasClass(q.id,"mceSplitButtonDisabled")||p.addClass(q.id,"mceSplitButtonHover")});
o.add(q.id,"mouseout",function(){p.hasClass(q.id,"mceSplitButtonDisabled")||p.removeClass(q.id,"mceSplitButtonHover")})}},destroy:function(){this.parent();o.clear(this.id+"_action");o.clear(this.id+"_open");o.clear(this.id)}})})(tinymce);
(function(n){var p=n.DOM,o=n.dom.Event,q=n.is,e=n.each;n.create("tinymce.ui.ColorSplitButton:tinymce.ui.SplitButton",{ColorSplitButton:function(a,g,h){this.parent(a,g,h);this.settings=g=n.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 n.util.Dispatcher(this);this.onHideMenu=new n.util.Dispatcher(this);this.value=g.default_color},showMenu:function(){var a=this,g,h;if(!a.isDisabled()){if(!a.isMenuRendered){a.renderMenu();a.isMenuRendered=true}if(a.isMenuVisible)return a.hideMenu();g=p.get(a.id);p.show(a.id+"_menu");p.addClass(g,"mceSplitButtonSelected");h=p.getPos(g);var f=a.id.split("_")[0]+"_parent";pmenu=p.getPos(f);p.setStyles(a.id+"_menu",{left:h.x-pmenu.x,top:h.y-pmenu.y+g.clientHeight,zIndex:2E5});
g=0;o.add(p.doc,"mousedown",a.hideMenu,a);a.onShowMenu.dispatch(a);if(a._focused){a._keyHandler=o.add(a.id+"_menu","keydown",function(d){d.keyCode==27&&a.hideMenu()});p.select("a",a.id+"_menu")[0].focus()}a.isMenuVisible=1}},hideMenu:function(a){var g=this;if(g.isMenuVisible)if(!(a&&a.type=="mousedown"&&p.getParent(a.target,function(h){return h.id===g.id+"_open"}))){if(!a||!p.getParent(a.target,".mceSplitButtonMenu")){p.removeClass(g.id,"mceSplitButtonSelected");o.remove(p.doc,"mousedown",g.hideMenu,
g);o.remove(g.id+"_menu","keydown",g._keyHandler);p.hide(g.id+"_menu")}g.isMenuVisible=0;g.onHideMenu.dispatch()}},renderMenu:function(){var a=this,g,h=0,f=a.settings,d,j,k,b,c;g=a.id.split("_")[0]+"_parent";p.setStyles(g,{position:"relative",display:"block"});b=p.add(g,"div",{role:"listbox",id:a.id+"_menu","class":f.menu_class+" "+f["class"],style:"position:absolute;left:0;top:-1000px;"});g=p.add(b,"div",{"class":f["class"]+" mceSplitButtonMenu"});p.add(g,"span",{"class":"mceMenuLine"});d=p.add(g,
"table",{role:"presentation","class":"mceColorSplitMenu"});j=p.add(d,"tbody");h=0;e(q(f.colors,"array")?f.colors:f.colors.split(","),function(l){l=l.replace(/^#/,"");if(!h--){k=p.add(j,"tr");h=f.grid_width-1}d=p.add(k,"td");d=p.add(d,"a",{role:"option",href:"javascript:;",style:{backgroundColor:"#"+l},title:a.editor.getLang("colors."+l,l),"data-mce-color":"#"+l});d=p.add(d,"span",{style:{backgroundColor:"#"+l},"data-mce-color":"#"+l});if(a.editor.forcedHighContrastMode){d=p.add(d,"canvas",{width:16,
height:16,"aria-hidden":"true"});if(d.getContext&&(c=d.getContext("2d"))){c.fillStyle="#"+l;c.fillRect(0,0,16,16)}else p.remove(d)}});if(f.more_colors_func){d=p.add(j,"tr");d=p.add(d,"td",{colspan:f.grid_width,"class":"mceMoreColors"});d=p.add(d,"a",{role:"option",id:a.id+"_more",href:"javascript:;",onclick:"return false;","class":"mceMoreColors"},f.more_colors_title);o.add(d,"click",function(l){f.more_colors_func.call(f.more_colors_scope||this);return o.cancel(l)})}p.addClass(g,"mceColorSplitMenu");
new n.ui.KeyboardNavigation({root:a.id+"_menu",items:p.select("a",a.id+"_menu"),onCancel:function(){a.hideMenu();a.focus()}});o.add(a.id+"_menu","mousedown",function(l){return o.cancel(l)});o.add(a.id+"_menu","click",function(l){var s;if((l=p.getParent(l.target,"a",j))&&l.nodeName.toLowerCase()=="a"&&(s=l.getAttribute("data-mce-color")))a.setColor(s);return o.cancel(l)});return b},setColor:function(a){this.displayColor(a);this.hideMenu();this.settings.onselect(a)},displayColor:function(a){p.setStyle(this.id+
"_preview","backgroundColor",a);this.value=a},postRender:function(){var a=this.id;this.parent();p.add(a+"_action","div",{id:a+"_preview","class":"mceColorPreview"});p.setStyle(this.id+"_preview","backgroundColor",this.value)},destroy:function(){this.parent();o.clear(this.id+"_menu");o.clear(this.id+"_more");p.remove(this.id+"_menu")}})})(tinymce);
(function(n){var p=n.DOM,o=n.each,q=n.dom.Event;n.create("tinymce.ui.ToolbarGroup:tinymce.ui.Container",{renderHTML:function(){var e=[],a=this.controls,g=n.each,h=this.settings;e.push('<div id="'+this.id+'" role="group" aria-labelledby="'+this.id+'_voice">');e.push("<span role='application'>");e.push('<span id="'+this.id+'_voice" class="mceVoiceLabel" style="display:none;">'+p.encode(h.name)+"</span>");g(a,function(f){e.push(f.renderHTML())});e.push("</span>");e.push("</div>");return e.join("")},
focus:function(){p.get(this.id).focus()},postRender:function(){var e=this,a=[];o(e.controls,function(g){o(g.controls,function(h){h.id&&a.push(h)})});e.keyNav=new n.ui.KeyboardNavigation({root:e.id,items:a,onCancel:function(){n.isWebKit&&p.get(e.editor.id+"_ifr").focus();e.editor.focus()},excludeFromTabOrder:!e.settings.tab_focus_toolbar})},destroy:function(){this.parent();this.keyNav.destroy();q.clear(this.id)}})})(tinymce);
(function(n){var p=n.DOM;n.create("tinymce.ui.Toolbar:tinymce.ui.Container",{renderHTML:function(){var o="",q,e,a=this.settings,g,h,f,d;d=this.controls;for(g=0;g<d.length;g++){e=d[g];h=d[g-1];f=d[g+1];if(g===0){q="mceToolbarStart";if(e.Button)q+=" mceToolbarStartButton";else if(e.SplitButton)q+=" mceToolbarStartSplitButton";else if(e.ListBox)q+=" mceToolbarStartListBox";o+=p.createHTML("td",{"class":q},p.createHTML("span",null,"<!-- IE --\>"))}if(h&&e.ListBox)if(h.Button||h.SplitButton)o+=p.createHTML("td",
{"class":"mceToolbarEnd"},p.createHTML("span",null,"<!-- IE --\>"));o+=p.stdMode?'<td style="position: relative">'+e.renderHTML()+"</td>":"<td>"+e.renderHTML()+"</td>";if(f&&e.ListBox)if(f.Button||f.SplitButton)o+=p.createHTML("td",{"class":"mceToolbarStart"},p.createHTML("span",null,"<!-- IE --\>"))}q="mceToolbarEnd";if(e.Button)q+=" mceToolbarEndButton";else if(e.SplitButton)q+=" mceToolbarEndSplitButton";else if(e.ListBox)q+=" mceToolbarEndListBox";o+=p.createHTML("td",{"class":q},p.createHTML("span",
null,"<!-- IE --\>"));return p.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>"+o+"</tr></tbody>")}})})(tinymce);
(function(n){var p=n.util.Dispatcher;n.create("tinymce.AddOnManager",{AddOnManager:function(){this.items=[];this.urls={};this.lookup={};this.onAdd=new p(this)},get:function(o){if(this.lookup[o])return this.lookup[o].instance},dependencies:function(o){var q;if(this.lookup[o])q=this.lookup[o].dependencies;return q||[]},requireLangPack:function(o){var q=n.settings;q&&q.language&&q.language_load!==false&&n.ScriptLoader.add(this.urls[o]+"/langs/"+q.language+".js")},add:function(o,q,e){this.items.push(q);
this.lookup[o]={instance:q,dependencies:e};this.onAdd.dispatch(this,o,q);return q},createUrl:function(o,q){return typeof q==="object"?q:{prefix:o.prefix,resource:q,suffix:o.suffix}},addComponents:function(o,q){var e=this.urls[o];n.each(q,function(a){n.ScriptLoader.add(e+"/"+a)})},load:function(o,q,e,a){function g(){var d=h.dependencies(o);n.each(d,function(j){j=h.createUrl(q,j);h.load(j.resource,j,undefined,undefined)});if(e)a?e.call(a):e.call(n.ScriptLoader)}var h=this,f=q;if(!h.urls[o]){if(typeof q===
"object")f=q.prefix+q.resource+q.suffix;if(f.indexOf("/")!=0&&f.indexOf("://")==-1)f=n.baseURL+"/"+f;h.urls[o]=f.substring(0,f.lastIndexOf("/"));h.lookup[o]?g():n.ScriptLoader.add(f,g,a)}}});n.PluginManager=new n.AddOnManager;n.ThemeManager=new n.AddOnManager})(tinymce);
(function(n){var p=n.each,o=n.extend,q=n.DOM,e=n.dom.Event,a=n.explode,g=n.util.Dispatcher,h=0;n.documentBaseURL=window.location.href.replace(/[\?#].*$/,"").replace(/[\/\\][^\/]+$/,"");/[\/\\]$/.test(n.documentBaseURL)||(n.documentBaseURL+="/");n.baseURL=(new n.util.URI(n.documentBaseURL)).toAbsolute(n.baseURL);n.baseURI=new n.util.URI(n.baseURL);n.onBeforeUnload=new g(n);e.add(window,"beforeunload",function(f){n.onBeforeUnload.dispatch(n,f)});n.onAddEditor=new g(n);n.onRemoveEditor=new g(n);n.EditorManager=
o(n,{editors:[],i18n:{},activeEditor:null,init:function(f){function d(l,s,i){var m=l[s];if(m){if(n.is(m,"string")){i=(i=m.replace(/\.\w+$/,""))?n.resolve(i):0;m=n.resolve(m)}return m.apply(i||this,Array.prototype.slice.call(arguments,2))}}var j=this,k,b=[],c;f=o({theme:"simple",language:"en"},f);j.settings=f;e.add(document,"init",function(){var l,s;d(f,"onpageload");switch(f.mode){case "exact":l=f.elements||"";l.length>0&&p(a(l),function(m){if(q.get(m)){c=new n.Editor(m,f);b.push(c);c.render(1)}else p(document.forms,
function(r){p(r.elements,function(t){if(t.name===m){m="mce_editor_"+h++;q.setAttrib(t,"id",m);c=new n.Editor(m,f);b.push(c);c.render(1)}})})});break;case "textareas":case "specific_textareas":var i=function(m,r){return r.constructor===RegExp?r.test(m.className):q.hasClass(m,r)};p(q.select("textarea"),function(m){if(!(f.editor_deselector&&i(m,f.editor_deselector)))if(!f.editor_selector||i(m,f.editor_selector)){k=q.get(m.name);if(!m.id&&!k)m.id=m.name;if(!m.id||j.get(m.id))m.id=q.uniqueId();c=new n.Editor(m.id,
f);b.push(c);c.render(1)}});break}if(f.oninit){l=s=0;p(b,function(m){s++;if(m.initialized)l++;else m.onInit.add(function(){l++;l==s&&d(f,"oninit")});l==s&&d(f,"oninit")})}})},get:function(f){if(f===void 0)return this.editors;return this.editors[f]},getInstanceById:function(f){return this.get(f)},add:function(f){var d=this.editors;d[f.id]=f;d.push(f);this._setActive(f);this.onAddEditor.dispatch(this,f);return f},remove:function(f){var d,j=this.editors;if(!j[f.id])return null;delete j[f.id];for(d=0;d<
j.length;d++)if(j[d]==f){j.splice(d,1);break}this.activeEditor==f&&this._setActive(j[0]);f.destroy();this.onRemoveEditor.dispatch(this,f);return f},execCommand:function(f,d,j){var k=this.get(j),b;switch(f){case "mceFocus":k.focus();return true;case "mceAddEditor":case "mceAddControl":this.get(j)||(new n.Editor(j,this.settings)).render();return true;case "mceAddFrameControl":b=j.window;b.tinyMCE=tinyMCE;b.tinymce=n;n.DOM.doc=b.document;n.DOM.win=b;k=new n.Editor(j.element_id,j);k.render();if(n.isIE){var c=
function(){k.destroy();b.detachEvent("onunload",c);b=b.tinyMCE=b.tinymce=null};b.attachEvent("onunload",c)}j.page_window=null;return true;case "mceRemoveEditor":case "mceRemoveControl":k&&k.remove();return true;case "mceToggleEditor":if(!k){this.execCommand("mceAddControl",0,j);return true}k.isHidden()?k.show():k.hide();return true}if(this.activeEditor)return this.activeEditor.execCommand(f,d,j);return false},execInstanceCommand:function(f,d,j,k){if(f=this.get(f))return f.execCommand(d,j,k);return false},
triggerSave:function(){p(this.editors,function(f){f.save()})},addI18n:function(f,d){var j=this.i18n;n.is(f,"string")?p(d,function(k,b){j[f+"."+b]=k}):p(f,function(k,b){p(k,function(c,l){p(c,function(s,i){if(l==="common")j[b+"."+i]=s;else j[b+"."+l+"."+i]=s})})})},_setActive:function(f){this.selectedInstance=this.activeEditor=f}})})(tinymce);
(function(n){var p=n.DOM,o=n.dom.Event,q=n.extend,e=n.util.Dispatcher,a=n.each,g=n.isGecko,h=n.isIE,f=n.is,d=n.ThemeManager,j=n.PluginManager,k=n.explode;n.create("tinymce.Editor",{Editor:function(b,c){var l=this;l.id=l.editorId=b;l.execCommands={};l.queryStateCommands={};l.queryValueCommands={};l.isNotDirty=false;l.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(s){l[s]=new e(l)});l.settings=c=q({id:b,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:n.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",
font_size_legacy_values:"xx-small,small,medium,large,x-large,xx-large,300%",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:true,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:true,entity_encoding:"named",url_converter:l.convertURL,url_converter_scope:l,ie7_compat:true},c);l.documentBaseURI=new n.util.URI(c.document_base_url||n.documentBaseURL,{base_uri:tinyMCE.baseURI});l.baseURI=n.baseURI;l.contentCSS=[];l.execCallback("setup",l)},render:function(){function b(){l.language&&l.language_load!==false&&i.add(n.baseURL+"/langs/"+l.language+".js");l.theme&&l.theme.charAt(0)!="-"&&!d.urls[l.theme]&&d.load(l.theme,"themes/"+l.theme+"/editor_template"+n.suffix+".js");
a(k(l.plugins),function(m){if(m&&!j.urls[m])if(m.charAt(0)=="-"){m=m.substr(1,m.length);m=j.dependencies(m);a(m,function(r){r=j.createUrl({prefix:"plugins/",resource:r,suffix:"/editor_plugin"+n.suffix+".js"},r);j.load(r.resource,r)})}else m!="safari"&&j.load(m,{prefix:"plugins/",resource:m,suffix:"/editor_plugin"+n.suffix+".js"})});i.loadQueue(function(){c.removed||c.init()})}var c=this,l=c.settings,s=c.id,i=n.ScriptLoader;if(o.domLoaded){tinyMCE.settings=l;if(c.getElement())if(!(n.isIDevice&&!n.isIOS5)){!/TEXTAREA|INPUT/i.test(c.getElement().nodeName)&&
l.hidden_input&&p.getParent(s,"form")&&p.insertAfter(p.create("input",{type:"hidden",name:s}),s);if(n.WindowManager)c.windowManager=new n.WindowManager(c);l.encoding=="xml"&&c.onGetContent.add(function(m,r){if(r.save)r.content=p.encode(r.content)});l.add_form_submit_trigger&&c.onSubmit.addToTop(function(){if(c.initialized){c.save();c.isNotDirty=1}});if(l.add_unload_trigger)c._beforeUnload=tinyMCE.onBeforeUnload.add(function(){c.initialized&&!c.destroyed&&!c.isHidden()&&c.save({format:"raw",no_events:true})});
n.addUnload(c.destroy,c);l.submit_patch&&c.onBeforeRenderUI.add(function(){var m=c.getElement().form;if(m)if(!m._mceOldSubmit){if(!m.submit.nodeType&&!m.submit.length){c.formElement=m;m._mceOldSubmit=m.submit;m.submit=function(){n.triggerSave();c.isNotDirty=1;return c.formElement._mceOldSubmit(c.formElement)}}m=null}});b()}}else o.add(document,"init",function(){c.render()})},init:function(){function b(x){var y=j.get(x),C=j.urls[x]||n.documentBaseURL.replace(/\/$/,"");if(y&&n.inArray(v,x)===-1){a(j.dependencies(x),
function(F){b(F)});y=new y(l,C);l.plugins[x]=y;if(y.init){y.init(l,C);v.push(x)}}}var c,l=this;c=l.settings;var s,i,m=l.getElement(),r,t,u,v=[];n.add(l);c.aria_label=c.aria_label||p.getAttrib(m,"aria-label",l.getLang("aria.rich_text_area"));if(c.theme){c.theme=c.theme.replace(/-/,"");r=d.get(c.theme);l.theme=new r;if(l.theme.init&&c.init_theme)l.theme.init(l,d.urls[c.theme]||n.documentBaseURL.replace(/\/$/,""))}a(k(c.plugins.replace(/\-/g,"")),b);if(c.popup_css!==false)c.popup_css=c.popup_css?l.documentBaseURI.toAbsolute(c.popup_css):
l.baseURI.toAbsolute("themes/"+c.theme+"/skins/"+c.skin+"/dialog.css");if(c.popup_css_add)c.popup_css+=","+l.documentBaseURI.toAbsolute(c.popup_css_add);l.controlManager=new n.ControlManager(l);if(c.custom_undo_redo){l.onBeforeExecCommand.add(function(x,y,C,F,H){if(y!="Undo"&&y!="Redo"&&y!="mceRepaint"&&(!H||!H.skip_undo))l.undoManager.beforeChange()});l.onExecCommand.add(function(x,y,C,F,H){if(y!="Undo"&&y!="Redo"&&y!="mceRepaint"&&(!H||!H.skip_undo))l.undoManager.add()})}l.onExecCommand.add(function(x,
y){/^(FontName|FontSize)$/.test(y)||l.nodeChanged()});if(g){u=function(x,y){if(!y||!y.initial)l.execCommand("mceRepaint")};l.onUndo.add(u);l.onRedo.add(u);l.onSetContent.add(u)}l.onBeforeRenderUI.dispatch(l,l.controlManager);if(c.render_ui){s=c.width||m.style.width||m.offsetWidth;i=c.height||m.style.height||m.offsetHeight;l.orgDisplay=m.style.display;u=/^[0-9\.]+(|px)$/i;if(u.test(""+s))s=Math.max(parseInt(s)+(r.deltaWidth||0),100);if(u.test(""+i))i=Math.max(parseInt(i)+(r.deltaHeight||0),100);r=
l.theme.renderUI({targetNode:m,width:s,height:i,deltaWidth:c.delta_width,deltaHeight:c.delta_height});l.editorContainer=r.editorContainer}if(document.domain&&location.hostname!=document.domain)n.relaxedDomain=document.domain;p.setStyles(r.sizeContainer||r.editorContainer,{width:s,height:i});c.content_css&&n.each(k(c.content_css),function(x){l.contentCSS.push(l.documentBaseURI.toAbsolute(x))});i=(r.iframeHeight||i)+(typeof i=="number"?r.deltaHeight||0:"");if(i<100)i=100;l.iframeHTML=c.doctype+'<html><head xmlns="http://www.w3.org/1999/xhtml">';
if(c.document_base_url!=n.documentBaseURL)l.iframeHTML+='<base href="'+l.documentBaseURI.getURI()+'" />';l.iframeHTML+=c.ie7_compat?'<meta http-equiv="X-UA-Compatible" content="IE=7" />':'<meta http-equiv="X-UA-Compatible" content="IE=edge" />';l.iframeHTML+='<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />';for(s=0;s<l.contentCSS.length;s++)l.iframeHTML+='<link type="text/css" rel="stylesheet" href="'+l.contentCSS[s]+'" />';s=c.body_id||"tinymce";if(s.indexOf("=")!=-1){s=l.getParam("body_id",
"","hash");s=s[l.id]||s}m=c.body_class||"";if(m.indexOf("=")!=-1){m=l.getParam("body_class","","hash");m=m[l.id]||""}l.iframeHTML+='</head><body id="'+s+'" class="mceContentBody '+m+'"><br></body></html>';if(n.relaxedDomain&&(h||n.isOpera&&parseFloat(opera.version())<11))t='javascript:(function(){document.open();document.domain="'+document.domain+'";var ed = window.parent.tinyMCE.get("'+l.id+'");document.write(ed.iframeHTML);document.close();ed.setupIframe();})()';c=p.add(r.iframeContainer,"iframe",
{id:l.id+"_ifr",src:t||'javascript:""',frameBorder:"0",allowTransparency:"true",title:c.aria_label,style:{width:"100%",height:i,display:"block"}});l.contentAreaContainer=r.iframeContainer;p.get(r.editorContainer).style.display=l.orgDisplay;p.get(l.id).style.display="none";p.setAttrib(l.id,"aria-hidden",true);if(!n.relaxedDomain||!t)l.setupIframe();m=c=r=null},setupIframe:function(){var b=this,c=b.settings,l=p.get(b.id);l=b.getDoc();if(!h||!n.relaxedDomain){l.open();l.write(b.iframeHTML);l.close();
if(n.relaxedDomain)l.domain=n.relaxedDomain}l=b.getBody();l.disabled=true;if(!c.readonly)l.contentEditable=true;l.disabled=false;b.schema=new n.html.Schema(c);b.dom=new n.dom.DOMUtils(b.getDoc(),{keep_values:true,url_converter:b.convertURL,url_converter_scope:b,hex_colors:c.force_hex_style_colors,class_filter:c.class_filter,update_styles:1,fix_ie_paragraphs:1,schema:b.schema});b.parser=new n.html.DomParser(c,b.schema);b.settings.allow_html_in_named_anchor||b.parser.addAttributeFilter("name",function(i){for(var m=
i.length,r,t,u,v;m--;){v=i[m];if(v.name==="a"&&v.firstChild){u=v.parent;r=v.lastChild;do{t=r.prev;u.insert(r,v);r=t}while(r)}}});b.parser.addAttributeFilter("src,href,style",function(i,m){for(var r=i.length,t,u=b.dom,v,x;r--;){t=i[r];v=t.attr(m);x="data-mce-"+m;t.attributes.map[x]||(m==="style"?t.attr(x,u.serializeStyle(u.parseStyle(v),t.name)):t.attr(x,b.convertURL(v,m,t.name)))}});b.parser.addNodeFilter("script",function(i){for(var m=i.length,r;m--;){r=i[m];r.attr("type","mce-"+(r.attr("type")||
"text/javascript"))}});b.parser.addNodeFilter("#cdata",function(i){for(var m=i.length,r;m--;){r=i[m];r.type=8;r.name="#comment";r.value="[CDATA["+r.value+"]]"}});b.parser.addNodeFilter("p,h1,h2,h3,h4,h5,h6,div",function(i){for(var m=i.length,r,t=b.schema.getNonEmptyElements();m--;){r=i[m];if(r.isEmpty(t))r.empty().append(new n.html.Node("br",1)).shortEnded=true}});b.serializer=new n.dom.Serializer(c,b.dom,b.schema);b.selection=new n.dom.Selection(b.dom,b.getWin(),b.serializer);b.formatter=new n.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:false,styles:{"float":"left"}}],aligncenter:[{selector:"p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li",styles:{textAlign:"center"}},{selector:"img",collapsed:false,styles:{display:"block",marginLeft:"auto",marginRight:"auto"}},{selector:"table",collapsed:false,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:false,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:true},{inline:"u",remove:"all"}],strikethrough:[{inline:"span",
styles:{textDecoration:"line-through"},exact:true},{inline:"strike",remove:"all"}],forecolor:{inline:"span",styles:{color:"%value"},wrap_links:false},hilitecolor:{inline:"span",styles:{backgroundColor:"%value"},wrap_links:false},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"},
link:{inline:"a",selector:"a",remove:"all",split:true,deep:true,onmatch:function(){return true},onformat:function(i,m,r){a(r,function(t,u){b.dom.setAttrib(i,u,t)})}},removeformat:[{selector:"b,strong,em,i,font,u,strike",remove:"all",split:true,expand:false,block_expand:true,deep:true},{selector:"span",attributes:["style","class"],remove:"empty",split:true,expand:false,deep:true},{selector:"*",attributes:["style","class"],split:false,expand:false,deep:true}]});a("p h1 h2 h3 h4 h5 h6 div address pre div code dt dd samp".split(/\s/),
function(i){b.formatter.register(i,{block:i,remove:"all"})});b.formatter.register(b.settings.formats);b.undoManager=new n.UndoManager(b);b.undoManager.onAdd.add(function(i,m){if(i.hasUndo())return b.onChange.dispatch(b,m,i)});b.undoManager.onUndo.add(function(i,m){return b.onUndo.dispatch(b,m,i)});b.undoManager.onRedo.add(function(i,m){return b.onRedo.dispatch(b,m,i)});b.forceBlocks=new n.ForceBlocks(b,{forced_root_block:c.forced_root_block});b.editorCommands=new n.EditorCommands(b);b.serializer.onPreProcess.add(function(i,
m){return b.onPreProcess.dispatch(b,m,i)});b.serializer.onPostProcess.add(function(i,m){return b.onPostProcess.dispatch(b,m,i)});b.onPreInit.dispatch(b);if(!c.gecko_spellcheck)b.getBody().spellcheck=0;c.readonly||b._addEvents();b.controlManager.onPostRender.dispatch(b,b.controlManager);b.onPostRender.dispatch(b);b.quirks=new n.util.Quirks(this);if(c.directionality)b.getBody().dir=c.directionality;if(c.nowrap)b.getBody().style.whiteSpace="nowrap";c.handle_node_change_callback&&b.onNodeChange.add(function(i,
m,r){b.execCallback("handle_node_change_callback",b.id,r,-1,-1,true,b.selection.isCollapsed())});c.save_callback&&b.onSaveContent.add(function(i,m){if(i=b.execCallback("save_callback",b.id,m.content,b.getBody()))m.content=i});c.onchange_callback&&b.onChange.add(function(i,m){b.execCallback("onchange_callback",b,m)});c.protect&&b.onBeforeSetContent.add(function(i,m){c.protect&&a(c.protect,function(r){m.content=m.content.replace(r,function(t){return"<!--mce:protected "+escape(t)+"--\>"})})});c.convert_newlines_to_brs&&
b.onBeforeSetContent.add(function(i,m){if(m.initial)m.content=m.content.replace(/\r?\n/g,"<br />")});c.preformatted&&b.onPostProcess.add(function(i,m){m.content=m.content.replace(/^\s*<pre.*?>/,"");m.content=m.content.replace(/<\/pre>\s*$/,"");if(m.set)m.content='<pre class="mceItemHidden">'+m.content+"</pre>"});if(c.verify_css_classes)b.serializer.attribValueFilter=function(i,m){var r;if(i=="class"){if(!b.classesRE){i=b.dom.getClasses();if(i.length>0){r="";a(i,function(t){r+=(r?"|":"")+t["class"]});
b.classesRE=new RegExp("("+r+")","gi")}}return!b.classesRE||/(\bmceItem\w+\b|\bmceTemp\w+\b)/g.test(m)||b.classesRE.test(m)?m:""}return m};if(c.cleanup_callback){b.onBeforeSetContent.add(function(i,m){m.content=b.execCallback("cleanup_callback","insert_to_editor",m.content,m)});b.onPreProcess.add(function(i,m){m.set&&b.execCallback("cleanup_callback","insert_to_editor_dom",m.node,m);m.get&&b.execCallback("cleanup_callback","get_from_editor_dom",m.node,m)});b.onPostProcess.add(function(i,m){if(m.set)m.content=
b.execCallback("cleanup_callback","insert_to_editor",m.content,m);if(m.get)m.content=b.execCallback("cleanup_callback","get_from_editor",m.content,m)})}c.save_callback&&b.onGetContent.add(function(i,m){if(m.save)m.content=b.execCallback("save_callback",b.id,m.content,b.getBody())});c.handle_event_callback&&b.onEvent.add(function(i,m,r){b.execCallback("handle_event_callback",m,i,r)===false&&o.cancel(m)});b.onSetContent.add(function(){b.addVisual(b.getBody())});c.padd_empty_editor&&b.onPostProcess.add(function(i,
m){m.content=m.content.replace(/^(<p[^>]*>(&nbsp;|&#160;|\s|\u00a0|)<\/p>[\r\n]*|<br \/>[\r\n]*)$/,"")});if(g){var s=function(i){a(i.dom.select("a"),function(m){var r=m.parentNode;i.dom.isBlock(r)&&r.lastChild===m&&i.dom.add(r,"br",{"data-mce-bogus":1})})};b.onExecCommand.add(function(i,m){m==="CreateLink"&&s(i)});b.onSetContent.add(b.selection.onSetContent.add(s))}b.load({initial:true,format:"html"});b.startContent=b.getContent({format:"raw"});b.undoManager.add();b.initialized=true;b.onInit.dispatch(b);
b.execCallback("setupcontent_callback",b.id,b.getBody(),b.getDoc());b.execCallback("init_instance_callback",b);b.focus(true);b.nodeChanged({initial:1});a(b.contentCSS,function(i){b.dom.loadCSS(i)});c.auto_focus&&setTimeout(function(){var i=n.get(c.auto_focus);i.selection.select(i.getBody(),1);i.selection.collapse(1);i.getBody().focus();i.getWin().focus()},100);l=null},focus:function(b){var c;c=this.selection;var l=this.settings.content_editable,s,i=this.getDoc();if(!b){b=c.getRng();if(b.item)s=b.item(0);
this._refreshContentEditable();c.normalize();l||this.getWin().focus();n.isGecko&&this.getBody().focus();if(s&&s.ownerDocument==i){b=i.body.createControlRange();b.addElement(s);b.select()}}if(n.activeEditor!=this){if((c=n.activeEditor)!=null)c.onDeactivate.dispatch(c,this);this.onActivate.dispatch(this,c)}n._setActive(this)},execCallback:function(b){var c=this.settings[b],l;if(c){if(this.callbackLookup&&(l=this.callbackLookup[b])){c=l.func;l=l.scope}if(f(c,"string")){l=(l=c.replace(/\.\w+$/,""))?n.resolve(l):
0;c=n.resolve(c);this.callbackLookup=this.callbackLookup||{};this.callbackLookup[b]={func:c,scope:l}}return c.apply(l||this,Array.prototype.slice.call(arguments,1))}},translate:function(b){var c=this.settings.language||"en",l=n.i18n;if(!b)return"";return l[c+"."+b]||b.replace(/{\#([^}]+)\}/g,function(s,i){return l[c+"."+i]||"{#"+i+"}"})},getLang:function(b,c){return n.i18n[(this.settings.language||"en")+"."+b]||(f(c)?c:"{#"+b+"}")},getParam:function(b,c,l){var s=n.trim;b=f(this.settings[b])?this.settings[b]:
c;var i;if(l==="hash"){i={};if(f(b,"string"))a(b.indexOf("=")>0?b.split(/[;,](?![^=;,]*(?:[;,]|$))/):b.split(","),function(m){m=m.split("=");if(m.length>1)i[s(m[0])]=s(m[1]);else i[s(m[0])]=s(m)});else i=b;return i}return b},nodeChanged:function(b){var c=this.selection,l=c.getStart()||this.getBody();if(this.initialized){b=b||{};l=h&&l.ownerDocument!=this.getDoc()?this.getBody():l;b.parents=[];this.dom.getParent(l,function(s){if(s.nodeName=="BODY")return true;b.parents.push(s)});this.onNodeChange.dispatch(this,
b?b.controlManager||this.controlManager:this.controlManager,l,c.isCollapsed(),b)}},addButton:function(b,c){this.buttons=this.buttons||{};this.buttons[b]=c},addCommand:function(b,c,l){this.execCommands[b]={func:c,scope:l||this}},addQueryStateHandler:function(b,c,l){this.queryStateCommands[b]={func:c,scope:l||this}},addQueryValueHandler:function(b,c,l){this.queryValueCommands[b]={func:c,scope:l||this}},addShortcut:function(b,c,l,s){var i=this,m;if(!i.settings.custom_shortcuts)return false;i.shortcuts=
i.shortcuts||{};if(f(l,"string")){m=l;l=function(){i.execCommand(m,false,null)}}if(f(l,"object")){m=l;l=function(){i.execCommand(m[0],m[1],m[2])}}a(k(b),function(r){var t={func:l,scope:s||this,desc:c,alt:false,ctrl:false,shift:false};a(k(r,"+"),function(u){switch(u){case "alt":case "ctrl":case "shift":t[u]=true;break;default:t.charCode=u.charCodeAt(0);t.keyCode=u.toUpperCase().charCodeAt(0)}});i.shortcuts[(t.ctrl?"ctrl":"")+","+(t.alt?"alt":"")+","+(t.shift?"shift":"")+","+t.keyCode]=t});return true},
execCommand:function(b,c,l,s){var i=this,m=0,r;if(!/^(mceAddUndoLevel|mceEndUndoLevel|mceBeginUndoLevel|mceRepaint|SelectAll)$/.test(b)&&(!s||!s.skip_focus))i.focus();r={};i.onBeforeExecCommand.dispatch(i,b,c,l,r);if(r.terminate)return false;if(i.execCallback("execcommand_callback",i.id,i.selection.getNode(),b,c,l)){i.onExecCommand.dispatch(i,b,c,l,s);return true}if(r=i.execCommands[b]){r=r.func.call(r.scope,c,l);if(r!==true){i.onExecCommand.dispatch(i,b,c,l,s);return r}}a(i.plugins,function(t){if(t.execCommand&&
t.execCommand(b,c,l)){i.onExecCommand.dispatch(i,b,c,l,s);m=1;return false}});if(m)return true;if(i.theme&&i.theme.execCommand&&i.theme.execCommand(b,c,l)){i.onExecCommand.dispatch(i,b,c,l,s);return true}if(i.editorCommands.execCommand(b,c,l)){i.onExecCommand.dispatch(i,b,c,l,s);return true}i.getDoc().execCommand(b,c,l);i.onExecCommand.dispatch(i,b,c,l,s)},queryCommandState:function(b){var c;if(!this._isHidden()){if(c=this.queryStateCommands[b]){c=c.func.call(c.scope);if(c!==true)return c}c=this.editorCommands.queryCommandState(b);
if(c!==-1)return c;try{return this.getDoc().queryCommandState(b)}catch(l){}}},queryCommandValue:function(b){var c;if(!this._isHidden()){if(c=this.queryValueCommands[b]){c=c.func.call(c.scope);if(c!==true)return c}c=this.editorCommands.queryCommandValue(b);if(f(c))return c;try{return this.getDoc().queryCommandValue(b)}catch(l){}}},show:function(){p.show(this.getContainer());p.hide(this.id);this.load()},hide:function(){var b=this.getDoc();h&&b&&b.execCommand("SelectAll");this.save();p.hide(this.getContainer());
p.setStyle(this.id,"display",this.orgDisplay)},isHidden:function(){return!p.isHidden(this.id)},setProgressState:function(b,c,l){this.onSetProgressState.dispatch(this,b,c,l);return b},load:function(b){var c=this.getElement(),l;if(c){b=b||{};b.load=true;l=this.setContent(f(c.value)?c.value:c.innerHTML,b);b.element=c;b.no_events||this.onLoadContent.dispatch(this,b);b.element=null;return l}},save:function(b){var c=this,l=c.getElement(),s;if(l&&c.initialized){b=b||{};b.save=true;if(!b.no_events){c.undoManager.typing=
false;c.undoManager.add()}b.element=l;s=b.content=c.getContent(b);b.no_events||c.onSaveContent.dispatch(c,b);s=b.content;if(/TEXTAREA|INPUT/i.test(l.nodeName))l.value=s;else{l.innerHTML=s;if(l=p.getParent(c.id,"form"))a(l.elements,function(i){if(i.name==c.id){i.value=s;return false}})}b.element=l=null;return s}},setContent:function(b,c){var l=this.getBody();c=c||{};c.format=c.format||"html";c.set=true;c.content=b;c.no_events||this.onBeforeSetContent.dispatch(this,c);b=c.content;if(!n.isIE&&(b.length===
0||/^\s+$/.test(b))){b=(b=this.settings.forced_root_block)?"<"+b+'><br data-mce-bogus="1"></'+b+">":'<br data-mce-bogus="1">';l.innerHTML=b;this.selection.select(l,true);this.selection.collapse(true)}else{if(c.format!=="raw")b=(new n.html.Serializer({},this.schema)).serialize(this.parser.parse(b));c.content=n.trim(b);this.dom.setHTML(l,c.content);c.no_events||this.onSetContent.dispatch(this,c);this.selection.normalize();return c.content}},getContent:function(b){var c;b=b||{};b.format=b.format||"html";
b.get=true;b.no_events||this.onBeforeGetContent.dispatch(this,b);c=b.format=="raw"?this.getBody().innerHTML:this.serializer.serialize(this.getBody(),b);b.content=n.trim(c);b.no_events||this.onGetContent.dispatch(this,b);return b.content},isDirty:function(){return n.trim(this.startContent)!=n.trim(this.getContent({format:"raw",no_events:1}))&&!this.isNotDirty},getContainer:function(){if(!this.container)this.container=p.get(this.editorContainer||this.id+"_parent");return this.container},getContentAreaContainer:function(){return this.contentAreaContainer},
getElement:function(){return p.get(this.settings.content_element||this.id)},getWin:function(){var b;if(!this.contentWindow)if(b=p.get(this.id+"_ifr"))this.contentWindow=b.contentWindow;return this.contentWindow},getDoc:function(){var b;if(!this.contentDocument)if(b=this.getWin())this.contentDocument=b.document;return this.contentDocument},getBody:function(){return this.bodyElement||this.getDoc().body},convertURL:function(b,c,l){var s=this.settings;if(s.urlconverter_callback)return this.execCallback("urlconverter_callback",
b,l,true,c);if(!s.convert_urls||l&&l.nodeName=="LINK"||b.indexOf("file:")===0)return b;if(s.relative_urls)return this.documentBaseURI.toRelative(b);return b=this.documentBaseURI.toAbsolute(b,s.remove_script_host)},addVisual:function(b){var c=this,l=c.settings;b=b||c.getBody();if(!f(c.hasVisual))c.hasVisual=l.visual;a(c.dom.select("table,a",b),function(s){var i;switch(s.nodeName){case "TABLE":i=c.dom.getAttrib(s,"border");if(!i||i=="0")c.hasVisual?c.dom.addClass(s,l.visual_table_class):c.dom.removeClass(s,
l.visual_table_class);return;case "A":if(i=c.dom.getAttrib(s,"name"))c.hasVisual?c.dom.addClass(s,"mceItemAnchor"):c.dom.removeClass(s,"mceItemAnchor");return}});c.onVisualAid.dispatch(c,b,c.hasVisual)},remove:function(){var b=this.getContainer();this.removed=1;this.hide();this.execCallback("remove_instance_callback",this);this.onRemove.dispatch(this);this.onExecCommand.listeners=[];n.remove(this);p.remove(b)},destroy:function(b){if(!this.destroyed){if(!b){n.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();if(!this.settings.content_editable){o.clear(this.getWin());o.clear(this.getDoc())}o.clear(this.getBody());o.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(x,y){if(!c.removed)if(c.onEvent.dispatch(c,x,y)!==false)c[m[x.fakeType||x.type]].dispatch(c,x,y)}var c=this,l,s=c.settings,i=c.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(x,y){switch(y){case "contextmenu":i.bind(c.getDoc(),y,b);break;case "paste":i.bind(c.getBody(),y,function(C){b(C)});break;case "submit":case "reset":i.bind(c.getElement().form||p.getParent(c.id,"form"),y,b);break;default:i.bind(s.content_editable?c.getBody():c.getDoc(),y,b)}});i.bind(s.content_editable?c.getBody():g?c.getDoc():c.getWin(),"focus",function(){c.focus(true)});n.isGecko&&i.bind(c.getDoc(),"DOMNodeInserted",function(x){var y;x=x.target;if(x.nodeType===1&&x.nodeName==="IMG"&&
(y=x.getAttribute("data-mce-src")))x.src=c.documentBaseURI.toAbsolute(y)});if(g){l=function(){var x=this.getDoc(),y=this.settings;if(g&&!y.readonly){this._refreshContentEditable();try{x.execCommand("styleWithCSS",0,false)}catch(C){if(!this._isHidden())try{x.execCommand("useCSS",0,true)}catch(F){}}if(!y.table_inline_editing)try{x.execCommand("enableInlineTableEditing",false,false)}catch(H){}if(!y.object_resizing)try{x.execCommand("enableObjectResizing",false,false)}catch(M){}}};c.onBeforeExecCommand.add(l);
c.onMouseDown.add(l)}c.onMouseUp.add(c.nodeChanged);c.onKeyUp.add(function(x,y){x=y.keyCode;if(x>=33&&x<=36||x>=37&&x<=40||x==13||x==45||x==46||x==8||n.isMac&&(x==91||x==93)||y.ctrlKey)c.nodeChanged()});c.onKeyDown.add(function(x,y){if(y.keyCode==8){y=x.selection.getRng().startContainer;for(var C=x.selection.getRng().startOffset;y&&y.nodeType&&y.nodeType!=1&&y.parentNode;)y=y.parentNode;if(y&&y.parentNode&&y.parentNode.tagName==="BLOCKQUOTE"&&y.parentNode.firstChild==y&&C==0){x.formatter.toggle("blockquote",
null,y.parentNode);C=x.selection.getRng();C.setStart(y,0);C.setEnd(y,0);x.selection.setRng(C);x.selection.collapse(false)}}});c.onReset.add(function(){c.setContent(c.startContent,{format:"raw"})});if(s.custom_shortcuts){if(s.custom_undo_redo_keyboard_shortcuts){c.addShortcut("ctrl+z",c.getLang("undo_desc"),"Undo");c.addShortcut("ctrl+y",c.getLang("redo_desc"),"Redo")}c.addShortcut("ctrl+b",c.getLang("bold_desc"),"Bold");c.addShortcut("ctrl+i",c.getLang("italic_desc"),"Italic");c.addShortcut("ctrl+u",
c.getLang("underline_desc"),"Underline");for(l=1;l<=6;l++)c.addShortcut("ctrl+"+l,"",["FormatBlock",false,"h"+l]);c.addShortcut("ctrl+7","",["FormatBlock",false,"p"]);c.addShortcut("ctrl+8","",["FormatBlock",false,"div"]);c.addShortcut("ctrl+9","",["FormatBlock",false,"address"]);var r=function(x){var y=null;if(!x.altKey&&!x.ctrlKey&&!x.metaKey)return y;a(c.shortcuts,function(C){if(!(n.isMac&&C.ctrl!=x.metaKey))if(!(!n.isMac&&C.ctrl!=x.ctrlKey))if(C.alt==x.altKey)if(C.shift==x.shiftKey)if(x.keyCode==
C.keyCode||x.charCode&&x.charCode==C.charCode){y=C;return false}});return y};c.onKeyUp.add(function(x,y){if(r(y))return o.cancel(y)});c.onKeyPress.add(function(x,y){if(r(y))return o.cancel(y)});c.onKeyDown.add(function(x,y){if(x=r(y)){x.func.call(x.scope);return o.cancel(y)}})}n.isIE&&i.bind(c.getDoc(),"controlselect",function(x){var y=c.resizeInfo;x=x.target;if(x.nodeName==="IMG"){y&&i.unbind(y.node,y.ev,y.cb);if(i.hasClass(x,"mceItemNoResize")){ev="resizestart";y=i.bind(x,"resizestart",o.cancel,
o)}else{ev="resizeend";y=i.bind(x,ev,function(C){var F;C=C.target;if(F=i.getStyle(C,"width")){i.setAttrib(C,"width",F.replace(/[^0-9%]+/g,""));i.setStyle(C,"width","")}if(F=i.getStyle(C,"height")){i.setAttrib(C,"height",F.replace(/[^0-9%]+/g,""));i.setStyle(C,"height","")}})}y=c.resizeInfo={node:x,ev:ev,cb:y}}});n.isOpera&&c.onClick.add(function(x,y){o.prevent(y)});if(s.custom_undo_redo){var t=function(){c.undoManager.typing=false;c.undoManager.add()};i.bind(c.getDoc(),"focusout",function(){!c.removed&&
c.undoManager.typing&&t()});c.dom.bind(c.dom.getRoot(),"dragend",function(){t()});c.onKeyUp.add(function(x,y){x=y.keyCode;if(x>=33&&x<=36||x>=37&&x<=40||x==13||x==45||y.ctrlKey)t()});c.onKeyDown.add(function(x,y){var C=y.keyCode,F;if(C==8)if((F=c.getDoc().selection)&&F.createRange&&F.createRange().item){c.undoManager.beforeChange();x.dom.remove(F.createRange().item(0));t();return o.cancel(y)}if(C>=33&&C<=36||C>=37&&C<=40||C==13||C==45){n.isIE&&C==13&&c.undoManager.beforeChange();c.undoManager.typing&&
t()}else if((C<16||C>20)&&C!=224&&C!=91&&!c.undoManager.typing){c.undoManager.beforeChange();c.undoManager.typing=true;c.undoManager.add()}});c.onMouseDown.add(function(){c.undoManager.typing&&t()})}if(n.isGecko){var u=function(){var x=c.dom.getAttribs(c.selection.getStart().cloneNode(false));return function(){var y=c.selection.getStart();if(y!==c.getBody()){c.dom.setAttrib(y,"style",null);a(x,function(C){y.setAttributeNode(C.cloneNode(true))})}}},v=function(){var x=c.selection;return!x.isCollapsed()&&
x.getStart()!=x.getEnd()};c.onKeyPress.add(function(x,y){if((y.keyCode==8||y.keyCode==46)&&v()){x=u();c.getDoc().execCommand("delete",false,null);x();return o.cancel(y)}});c.dom.bind(c.getDoc(),"cut",function(){var x;if(v()){x=u();c.onKeyUp.addToTop(o.cancel,o);setTimeout(function(){x();c.onKeyUp.remove(o.cancel,o)},0)}})}},_refreshContentEditable:function(){var b,c;if(this._isHidden()){b=this.getBody();c=b.parentNode;c.removeChild(b);c.appendChild(b);b.focus()}},_isHidden:function(){var b;if(!g)return 0;
b=this.selection.getSel();return!b||!b.rangeCount||b.rangeCount==0}})})(tinymce);
(function(n){var p=n.each,o=true,q=false;n.EditorCommands=function(e){function a(u,v,x){var y;u=u.toLowerCase();if(y=i.exec[u]){y(u,v,x);return o}return q}function g(u){var v;u=u.toLowerCase();if(v=i.state[u])return v(u);return-1}function h(u){var v;u=u.toLowerCase();if(v=i.value[u])return v(u);return q}function f(u,v){v=v||"exec";p(u,function(x,y){p(y.toLowerCase().split(","),function(C){i[v][C]=x})})}function d(u,v,x){if(v===void 0)v=q;if(x===void 0)x=null;return e.getDoc().execCommand(u,v,x)}function j(u){return r.match(u)}
function k(u,v){r.toggle(u,v?{value:v}:void 0)}function b(u){t=s.getBookmark(u)}function c(){s.moveToBookmark(t)}var l=e.dom,s=e.selection,i={state:{},exec:{},value:{}},m=e.settings,r=e.formatter,t;n.extend(this,{execCommand:a,queryCommandState:g,queryCommandValue:h,addCommands:f});f({"mceResetDesignMode,mceBeginUndoLevel":function(){},"mceEndUndoLevel,mceAddUndoLevel":function(){e.undoManager.add()},"Cut,Copy,Paste":function(u){var v=e.getDoc(),x;try{d(u)}catch(y){x=o}if(x||!v.queryCommandSupported(u))n.isGecko?
e.windowManager.confirm(e.getLang("clipboard_msg"),function(C){C&&open("http://www.mozilla.org/editor/midasdemo/securityprefs.html","_blank")}):e.windowManager.alert(e.getLang("clipboard_no_support"))},unlink:function(u){s.isCollapsed()&&s.select(s.getNode());d(u);s.collapse(q)},"JustifyLeft,JustifyCenter,JustifyRight,JustifyFull":function(u){var v=u.substring(7);p("left,center,right,full".split(","),function(x){v!=x&&r.remove("align"+x)});k("align"+v);a("mceRepaint")},"InsertUnorderedList,InsertOrderedList":function(u){var v;
d(u);if(u=l.getParent(s.getNode(),"ol,ul")){v=u.parentNode;if(/^(H[1-6]|P|ADDRESS|PRE)$/.test(v.nodeName)){b();l.split(v,u);c()}}},"Bold,Italic,Underline,Strikethrough,Superscript,Subscript":function(u){k(u)},"ForeColor,HiliteColor,FontName":function(u,v,x){k(u,x)},FontSize:function(u,v,x){var y;if(x>=1&&x<=7){y=n.explode(m.font_size_style_values);x=(v=n.explode(m.font_size_classes))?v[x-1]||x:y[x-1]||x}k(u,x)},RemoveFormat:function(u){r.remove(u)},mceBlockQuote:function(){k("blockquote")},FormatBlock:function(u,
v,x){return k(x||"p")},mceCleanup:function(){var u=s.getBookmark();e.setContent(e.getContent({cleanup:o}),{cleanup:o});s.moveToBookmark(u)},mceRemoveNode:function(u,v,x){u=x||s.getNode();if(u!=e.getBody()){b();e.dom.remove(u,o);c()}},mceSelectNodeDepth:function(u,v,x){var y=0;l.getParent(s.getNode(),function(C){if(C.nodeType==1&&y++==x){s.select(C);return q}},e.getBody())},mceSelectNode:function(u,v,x){s.select(x)},mceInsertContent:function(u,v,x){var y,C,F,H,M;y=e.parser;C=new n.html.Serializer({},
e.schema);u={content:x,format:"html"};s.onBeforeSetContent.dispatch(s,u);x=u.content;if(x.indexOf("{$caret}")==-1)x+="{$caret}";x=x.replace(/\{\$caret\}/,'<span id="mce_marker" data-mce-type="bookmark">\ufeff</span>');s.isCollapsed()||e.getDoc().execCommand("Delete",false,null);F=s.getNode();u={context:F.nodeName.toLowerCase()};M=y.parse(x,u);v=M.lastChild;if(v.attr("id")=="mce_marker"){x=v;for(v=v.prev;v;v=v.walk(true))if(v.type==3||!l.isBlock(v.name)){v.parent.insert(x,v,v.name==="br");break}}if(u.invalid){s.setContent('<span id="mce_marker" data-mce-type="bookmark">\ufeff</span>');
F=e.selection.getNode();H=e.getBody();if(F.nodeType==9)F=v=H;else v=F;for(;v!==H;){F=v;v=v.parentNode}x=F==H?H.innerHTML:l.getOuterHTML(F);x=C.serialize(y.parse(x.replace(/<span (id="mce_marker"|id=mce_marker).+?<\/span>/i,function(){return C.serialize(M)})));F==H?l.setHTML(H,x):l.setOuterHTML(F,x)}else{x=C.serialize(M);v=F.firstChild;y=F.lastChild;!v||v===y&&v.nodeName==="BR"?l.setHTML(F,x):s.setContent(x)}x=l.get("mce_marker");v=l.getRect(x);F=l.getViewPort(e.getWin());if(v.y+v.h>F.y+F.h||v.y<F.y||
v.x>F.x+F.w||v.x<F.x){y=n.isIE?e.getDoc().documentElement:e.getBody();y.scrollLeft=v.x;y.scrollTop=v.y-F.h+25}F=l.createRng();if((v=x.previousSibling)&&v.nodeType==3)F.setStart(v,v.nodeValue.length);else{F.setStartBefore(x);F.setEndBefore(x)}l.remove(x);s.setRng(F);s.onSetContent.dispatch(s,u);e.addVisual()},mceInsertRawHTML:function(u,v,x){s.setContent("tiny_mce_marker");e.setContent(e.getContent().replace(/tiny_mce_marker/g,function(){return x}))},mceSetContent:function(u,v,x){e.setContent(x)},
"Indent,Outdent":function(u){var v,x,y;v=m.indentation;x=/[a-z%]+$/i.exec(v);v=parseInt(v);!g("InsertUnorderedList")&&!g("InsertOrderedList")?p(s.getSelectedBlocks(),function(C){if(u=="outdent"){y=Math.max(0,parseInt(C.style.paddingLeft||0)-v);l.setStyle(C,"paddingLeft",y?y+x:"")}else l.setStyle(C,"paddingLeft",parseInt(C.style.paddingLeft||0)+v+x)}):d(u)},mceRepaint:function(){if(n.isGecko)try{b(o);s.getSel()&&s.getSel().selectAllChildren(e.getBody());s.collapse(o);c()}catch(u){}},mceToggleFormat:function(u,
v,x){r.toggle(x)},InsertHorizontalRule:function(){e.execCommand("mceInsertContent",false,"<hr />")},mceToggleVisualAid:function(){e.hasVisual=!e.hasVisual;e.addVisual()},mceReplaceContent:function(u,v,x){e.execCommand("mceInsertContent",false,x.replace(/\{\$selection\}/g,s.getContent({format:"text"})))},mceInsertLink:function(u,v,x){if(typeof x=="string")x={href:x};u=l.getParent(s.getNode(),"a");x.href=x.href.replace(" ","%20");if(!u||!x.href)r.remove("link");x.href&&r.apply("link",x,u)},selectAll:function(){var u=
l.getRoot(),v=l.createRng();v.setStart(u,0);v.setEnd(u,u.childNodes.length);e.selection.setRng(v)}});f({"JustifyLeft,JustifyCenter,JustifyRight,JustifyFull":function(u){return j("align"+u.substring(7))},"Bold,Italic,Underline,Strikethrough,Superscript,Subscript":function(u){return j(u)},mceBlockQuote:function(){return j("blockquote")},Outdent:function(){var u;if(m.inline_styles){if((u=l.getParent(s.getStart(),l.isBlock))&&parseInt(u.style.paddingLeft)>0)return o;if((u=l.getParent(s.getEnd(),l.isBlock))&&
parseInt(u.style.paddingLeft)>0)return o}return g("InsertUnorderedList")||g("InsertOrderedList")||!m.inline_styles&&!!l.getParent(s.getNode(),"BLOCKQUOTE")},"InsertUnorderedList,InsertOrderedList":function(u){return l.getParent(s.getNode(),u=="insertunorderedlist"?"UL":"OL")}},"state");f({"FontSize,FontName":function(u){var v=0,x;if(x=l.getParent(s.getNode(),"span"))v=u=="fontsize"?x.style.fontSize:x.style.fontFamily.replace(/, /g,",").replace(/[\'\"]/g,"").toLowerCase();return v}},"value");m.custom_undo_redo&&
f({Undo:function(){e.undoManager.undo()},Redo:function(){e.undoManager.redo()}})}})(tinymce);
(function(n){var p=n.util.Dispatcher;n.UndoManager=function(o){function q(){return n.trim(o.getContent({format:"raw",no_events:1}))}var e,a=0,g=[],h;return e={typing:false,onAdd:new p(e),onUndo:new p(e),onRedo:new p(e),beforeChange:function(){h=o.selection.getBookmark(2,true)},add:function(f){var d;d=o.settings;var j;f=f||{};f.content=q();if((j=g[a])&&j.content==f.content)return null;if(g[a])g[a].beforeBookmark=h;if(d.custom_undo_redo_levels)if(g.length>d.custom_undo_redo_levels){for(d=0;d<g.length-
1;d++)g[d]=g[d+1];g.length--;a=g.length}f.bookmark=o.selection.getBookmark(2,true);if(a<g.length-1)g.length=a+1;g.push(f);a=g.length-1;e.onAdd.dispatch(e,f);o.isNotDirty=0;return f},undo:function(){var f;if(e.typing){e.add();e.typing=false}if(a>0){f=g[--a];o.setContent(f.content,{format:"raw"});o.selection.moveToBookmark(f.beforeBookmark);e.onUndo.dispatch(e,f)}return f},redo:function(){var f;if(a<g.length-1){f=g[++a];o.setContent(f.content,{format:"raw"});o.selection.moveToBookmark(f.bookmark);e.onRedo.dispatch(e,
f)}return f},clear:function(){g=[];a=0;e.typing=false},hasUndo:function(){return a>0||this.typing},hasRedo:function(){return a<g.length-1&&!this.typing}}}})(tinymce);
(function(n){function p(j){var k,b,c;do if(/^(SPAN|STRONG|B|EM|I|FONT|STRIKE|U)$/.test(j.nodeName)){if(k){b=j.cloneNode(false);b.appendChild(k);k=b}else k=c=j.cloneNode(false);k.removeAttribute("id")}while(j=j.parentNode);if(k)return{wrapper:k,inner:c}}function o(j,k){var b=k.ownerDocument.createRange();b.setStart(j.endContainer,j.endOffset);b.setEndAfter(k);return b.cloneContents().textContent.length==0}function q(j,k,b){var c;if(k.isEmpty(b)){c=k.getParent(b,"ul,ol");if(!k.getParent(c.parentNode,
"ul,ol")){k.split(c,b);c=k.create("p",0,'<br data-mce-bogus="1" />');k.replace(c,b);j.select(c,1)}return d}return f}var e=n.dom.Event,a=n.isIE,g=n.isGecko,h=n.isOpera,f=true,d=false;n.create("tinymce.ForceBlocks",{ForceBlocks:function(j){var k=j.settings,b;this.editor=j;this.dom=j.dom;b=(k.forced_root_block||"p").toLowerCase();k.element=b.toUpperCase();j.onPreInit.add(this.setup,this)},setup:function(){var j=this,k=j.editor,b=k.settings,c=k.dom,l=k.selection,s=k.schema.getBlockElements();if(b.forced_root_block){var i=
function(){var r=l.getStart(),t=k.getBody(),u,v,x,y,C,F,H;if(!(!r||r.nodeType!==1)){for(;r!=t;){if(s[r.nodeName])return;r=r.parentNode}u=l.getRng();if(u.setStart){v=u.startContainer;x=u.startOffset;y=u.endContainer;C=u.endOffset}else{if(u.item){u=k.getDoc().body.createTextRange();u.moveToElementText(u.item(0))}tmpRng=u.duplicate();tmpRng.collapse(true);x=tmpRng.move("character",-16777215)*-1;if(!tmpRng.collapsed){tmpRng=u.duplicate();tmpRng.collapse(false);C=tmpRng.move("character",-16777215)*-1-
x}}for(r=t.firstChild;r;)if(r.nodeType===3||r.nodeType==1&&!s[r.nodeName]){if(!F){F=c.create(b.forced_root_block);r.parentNode.insertBefore(F,r)}H=r;r=r.nextSibling;F.appendChild(H)}else{F=null;r=r.nextSibling}if(u.setStart){u.setStart(v,x);u.setEnd(y,C);l.setRng(u)}else try{u=k.getDoc().body.createTextRange();u.moveToElementText(t);u.collapse(true);u.moveStart("character",x);C>0&&u.moveEnd("character",C);u.select()}catch(M){}k.nodeChanged()}};k.onKeyUp.add(i);k.onClick.add(i)}b.force_br_newlines&&
a&&k.onKeyPress.add(function(r,t){if(t.keyCode==13&&l.getNode().nodeName!="LI"){l.setContent('<br id="__" /> ',{format:"raw"});r=c.get("__");r.removeAttribute("id");l.select(r);l.collapse();return e.cancel(t)}});if(b.force_p_newlines){if(a){n.addUnload(function(){j._previousFormats=0});k.onKeyPress.add(function(r,t){j._previousFormats=0;if(t.keyCode==13&&!t.shiftKey&&r.selection.isCollapsed()&&b.keep_styles)j._previousFormats=p(r.selection.getStart())});k.onKeyUp.add(function(r,t){if(t.keyCode==13&&
!t.shiftKey){t=r.selection.getStart();var u=j._previousFormats;if(!t.hasChildNodes()&&u)if((t=c.getParent(t,c.isBlock))&&t.nodeName!="LI"){t.innerHTML="";if(j._previousFormats){t.appendChild(u.wrapper);u.inner.innerHTML="\ufeff"}else t.innerHTML="\ufeff";l.select(t,1);l.collapse(true);r.getDoc().execCommand("Delete",false,null);j._previousFormats=0}}})}else k.onKeyPress.add(function(r,t){t.keyCode==13&&!t.shiftKey&&!j.insertPara(t)&&e.cancel(t)});g&&k.onKeyDown.add(function(r,t){if((t.keyCode==8||
t.keyCode==46)&&!t.shiftKey)j.backspaceDelete(t,t.keyCode==8)})}if(n.isWebKit){var m=function(r){var t=l.getRng(),u,v=c.create("div",null," "),x=c.getViewPort(r.getWin()).h;t.insertNode(u=c.create("br"));t.setStartAfter(u);t.setEndAfter(u);l.setRng(t);if(l.getSel().focusNode==u.previousSibling){l.select(c.insertAfter(c.doc.createTextNode("\u00a0"),u));l.collapse(f)}c.insertAfter(v,u);t=c.getPos(v).y;c.remove(v);t>x&&r.getWin().scrollTo(0,t)};k.onKeyPress.add(function(r,t){if(t.keyCode==13&&(t.shiftKey||
b.force_br_newlines&&!c.getParent(l.getNode(),"h1,h2,h3,h4,h5,h6,ol,ul"))){m(r);e.cancel(t)}})}if(a)if(b.element!="P"){k.onKeyPress.add(function(){j.lastElm=l.getNode().nodeName});k.onKeyUp.add(function(r,t){var u=l.getNode();if(r.getBody().childNodes.length===1&&u.nodeName=="P"){u=c.rename(u,b.element);l.select(u);l.collapse();r.nodeChanged()}else if(t.keyCode==13&&!t.shiftKey&&j.lastElm!="P")if(t=c.getParent(u,"p")){c.rename(t,b.element);r.nodeChanged()}})}},getParentBlock:function(j){var k=this.dom;
return k.getParent(j,k.isBlock)},insertPara:function(){function j(S,D){var Y=[],Z;S.innerHTML="";if(l.keep_styles){Z=D;do if(/^(SPAN|STRONG|B|EM|I|FONT|STRIKE|U)$/.test(Z.nodeName)){D=Z.cloneNode(d);b.setAttrib(D,"id","");Y.push(D)}while(Z=Z.parentNode)}if(Y.length>0){Z=Y.length-1;for(D=S;Z>=0;Z--)D=D.appendChild(Y[Z]);Y[0].innerHTML=h?"\u00a0":"<br />";return Y[0]}else S.innerHTML=h?"\u00a0":"<br />"}var k=this.editor,b=k.dom,c=k.getDoc(),l=k.settings,s=k.selection.getSel(),i=s.getRangeAt(0),m=c.body,
r,t,u,v,x,y,C,F,H,M,P,R=b.getViewPort(k.getWin());k.undoManager.beforeChange();r=c.createRange();r.setStart(s.anchorNode,s.anchorOffset);r.collapse(f);t=c.createRange();t.setStart(s.focusNode,s.focusOffset);t.collapse(f);v=(u=r.compareBoundaryPoints(r.START_TO_END,t)<0)?s.anchorNode:s.focusNode;x=u?s.anchorOffset:s.focusOffset;y=u?s.focusNode:s.anchorNode;s=u?s.focusOffset:s.anchorOffset;if(v===y&&/^(TD|TH)$/.test(v.nodeName)){v.firstChild.nodeName=="BR"&&b.remove(v.firstChild);if(v.childNodes.length==
0)k.dom.add(v,l.element,null,"<br />");else{P=v.innerHTML;v.innerHTML="";k.dom.add(v,l.element,null,P)}F=k.dom.add(v,l.element,null,"<br />");i=c.createRange();i.selectNodeContents(F);i.collapse(1);k.selection.setRng(i);return d}if(v==m&&y==m&&m.firstChild&&k.dom.isBlock(m.firstChild)){v=y=v.firstChild;x=s=0;r=c.createRange();r.setStart(v,0);t=c.createRange();t.setStart(y,0)}c.body.hasChildNodes()||c.body.appendChild(b.create("br"));v=v.nodeName=="HTML"?c.body:v;v=v.nodeName=="BODY"?v.firstChild:
v;y=y.nodeName=="HTML"?c.body:y;y=y.nodeName=="BODY"?y.firstChild:y;C=this.getParentBlock(v);F=this.getParentBlock(y);u=C?C.nodeName:l.element;if(P=this.dom.getParent(C,"li,pre")){if(P.nodeName=="LI")return q(k.selection,this.dom,P);return f}if(C&&(C.nodeName=="CAPTION"||/absolute|relative|fixed/gi.test(b.getStyle(C,"position",1)))){u=l.element;C=null}if(F&&(F.nodeName=="CAPTION"||/absolute|relative|fixed/gi.test(b.getStyle(C,"position",1)))){u=l.element;F=null}if(/(TD|TABLE|TH|CAPTION)/.test(u)||
C&&u=="DIV"&&/left|right/gi.test(b.getStyle(C,"float",1))){u=l.element;C=F=null}H=C&&C.nodeName==u?C.cloneNode(0):k.dom.create(u);F=F&&F.nodeName==u?F.cloneNode(0):k.dom.create(u);F.removeAttribute("id");if(/^(H[1-6])$/.test(u)&&o(i,C))F=k.dom.create(l.element);P=C=v;do{if(P==m||P.nodeType==9||this.dom.isBlock(P)||/(TD|TABLE|TH|CAPTION)/.test(P.nodeName))break;C=P}while(P=P.previousSibling?P.previousSibling:P.parentNode);P=M=y;do{if(P==m||P.nodeType==9||this.dom.isBlock(P)||/(TD|TABLE|TH|CAPTION)/.test(P.nodeName))break;
M=P}while(P=P.nextSibling?P.nextSibling:P.parentNode);C.nodeName==u?r.setStart(C,0):r.setStartBefore(C);r.setEnd(v,x);H.appendChild(r.cloneContents()||c.createTextNode(""));try{t.setEndAfter(M)}catch(K){}t.setStart(y,s);F.appendChild(t.cloneContents()||c.createTextNode(""));i=c.createRange();if(!C.previousSibling&&C.parentNode.nodeName==u)i.setStartBefore(C.parentNode);else r.startContainer.nodeName==u&&r.startOffset==0?i.setStartBefore(r.startContainer):i.setStart(r.startContainer,r.startOffset);
!M.nextSibling&&M.parentNode.nodeName==u?i.setEndAfter(M.parentNode):i.setEnd(t.endContainer,t.endOffset);i.deleteContents();h&&k.getWin().scrollTo(0,R.y);if(H.firstChild&&H.firstChild.nodeName==u)H.innerHTML=H.firstChild.innerHTML;if(F.firstChild&&F.firstChild.nodeName==u)F.innerHTML=F.firstChild.innerHTML;b.isEmpty(H)&&j(H,v);b.isEmpty(F)&&j(F,y);if(h&&parseFloat(opera.version())<9.5){i.insertNode(H);i.insertNode(F)}else{i.insertNode(F);i.insertNode(H)}F.normalize();H.normalize();k.selection.select(F,
true);k.selection.collapse(true);c=k.dom.getPos(F).y;if(c<R.y||c+25>R.y+R.h)k.getWin().scrollTo(0,c<R.y?c:c-R.h+25);k.undoManager.add();return d},backspaceDelete:function(j,k){var b=this.editor,c=b.getBody(),l,s=b.selection,i=s.getRng(),m=i.startContainer,r;if(!k&&i.collapsed&&m.nodeType==1&&i.startOffset==m.childNodes.length){r=new n.dom.TreeWalker(m.lastChild,m);for(l=m.lastChild;l;l=r.prev())if(l.nodeType==3){i.setStart(l,l.nodeValue.length);i.collapse(true);s.setRng(i);return}}if(m&&b.dom.isBlock(m)&&
!/^(TD|TH)$/.test(m.nodeName)&&k)if(m.childNodes.length==0||m.childNodes.length==1&&m.firstChild.nodeName=="BR"){for(l=m;(l=l.previousSibling)&&!b.dom.isBlock(l););if(l){if(m!=c.firstChild){for(k=b.dom.doc.createTreeWalker(l,NodeFilter.SHOW_TEXT,null,d);c=k.nextNode();)l=c;i=b.getDoc().createRange();i.setStart(l,l.nodeValue?l.nodeValue.length:0);i.setEnd(l,l.nodeValue?l.nodeValue.length:0);s.setRng(i);b.dom.remove(m)}return e.cancel(j)}}}})})(tinymce);
(function(n){var p=n.dom.Event,o=n.each,q=n.extend;n.create("tinymce.ControlManager",{ControlManager:function(e,a){var g=this;a=a||{};g.editor=e;g.controls={};g.onAdd=new n.util.Dispatcher(g);g.onPostRender=new n.util.Dispatcher(g);g.prefix=a.prefix||e.id+"_";g._cls={};g.onPostRender.add(function(){o(g.controls,function(h){h.postRender()})})},get:function(e){return this.controls[this.prefix+e]||this.controls[e]},setActive:function(e,a){var g=null;if(g=this.get(e))g.setActive(a);return g},setDisabled:function(e,
a){var g=null;if(g=this.get(e))g.setDisabled(a);return g},add:function(e){if(e){this.controls[e.id]=e;this.onAdd.dispatch(e,this)}return e},createControl:function(e){var a,g=this,h=g.editor;o(h.plugins,function(f){if(f.createControl)if(a=f.createControl(e,g))return false});switch(e){case "|":case "separator":return g.createSeparator()}if(!a&&h.buttons&&(a=h.buttons[e]))return g.createButton(e,a);return g.add(a)},createDropMenu:function(e,a,g){var h=this.editor,f,d,j;a=q({"class":"mceDropDown",constrain:h.settings.constrain_menus},
a);a["class"]=a["class"]+" "+h.getParam("skin")+"Skin";if(j=h.getParam("skin_variant"))a["class"]+=" "+h.getParam("skin")+"Skin"+j.substring(0,1).toUpperCase()+j.substring(1);e=this.prefix+e;f=this.controls[e]=new (g||this._cls.dropmenu||n.ui.DropMenu)(e,a);f.onAddItem.add(function(k,b){var c=b.settings;c.title=h.getLang(c.title,c.title);if(!c.onclick)c.onclick=function(){if(c.cmd)h.execCommand(c.cmd,c.ui||false,c.value)}});h.onRemove.add(function(){f.destroy()});if(n.isIE){f.onShowMenu.add(function(){h.focus();
d=h.selection.getBookmark(1)});f.onHideMenu.add(function(){if(d){h.selection.moveToBookmark(d);d=0}})}return this.add(f)},createListBox:function(e,a,g){function h(d){return d.settings.use_accessible_selects&&!n.isGecko}var f=this.editor;if(this.get(e))return null;a.title=f.translate(a.title);a.scope=a.scope||f;if(!a.onselect)a.onselect=function(d){f.execCommand(a.cmd,a.ui||false,d||a.value)};a=q({title:a.title,"class":"mce_"+e,scope:a.scope,control_manager:this},a);e=this.prefix+e;if(f.settings.use_native_selects||
h(f))g=new n.ui.NativeListBox(e,a);else{g=g||this._cls.listbox||n.ui.ListBox;g=new g(e,a,f)}this.controls[e]=g;n.isWebKit&&g.onPostRender.add(function(d,j){p.add(j,"mousedown",function(){f.bookmark=f.selection.getBookmark(1)});p.add(j,"focus",function(){f.selection.moveToBookmark(f.bookmark);f.bookmark=null})});g.hideMenu&&f.onMouseDown.add(g.hideMenu,g);return this.add(g)},createButton:function(e,a,g){var h=this.editor;if(this.get(e))return null;a.title=h.translate(a.title);a.label=h.translate(a.label);
a.scope=a.scope||h;if(!a.onclick&&!a.menu_button)a.onclick=function(){h.execCommand(a.cmd,a.ui||false,a.value)};a=q({title:a.title,"class":"mce_"+e,unavailable_prefix:h.getLang("unavailable",""),scope:a.scope,control_manager:this},a);e=this.prefix+e;if(a.menu_button){g=g||this._cls.menubutton||n.ui.MenuButton;e=new g(e,a,h);h.onMouseDown.add(e.hideMenu,e)}else{g=this._cls.button||n.ui.Button;e=new g(e,a,h)}return this.add(e)},createMenuButton:function(e,a,g){a=a||{};a.menu_button=1;return this.createButton(e,
a,g)},createSplitButton:function(e,a,g){var h=this.editor;if(this.get(e))return null;a.title=h.translate(a.title);a.scope=a.scope||h;if(!a.onclick)a.onclick=function(f){h.execCommand(a.cmd,a.ui||false,f||a.value)};if(!a.onselect)a.onselect=function(f){h.execCommand(a.cmd,a.ui||false,f||a.value)};a=q({title:a.title,"class":"mce_"+e,scope:a.scope,control_manager:this},a);e=this.prefix+e;e=this.add(new (g||this._cls.splitbutton||n.ui.SplitButton)(e,a,h));h.onMouseDown.add(e.hideMenu,e);return e},createColorSplitButton:function(e,
a,g){var h=this.editor,f,d;if(this.get(e))return null;a.title=h.translate(a.title);a.scope=a.scope||h;if(!a.onclick)a.onclick=function(j){if(n.isIE)d=h.selection.getBookmark(1);h.execCommand(a.cmd,a.ui||false,j||a.value)};if(!a.onselect)a.onselect=function(j){h.execCommand(a.cmd,a.ui||false,j||a.value)};a=q({title:a.title,"class":"mce_"+e,menu_class:h.getParam("skin")+"Skin",scope:a.scope,more_colors_title:h.getLang("more_colors")},a);e=this.prefix+e;f=new (g||this._cls.colorsplitbutton||n.ui.ColorSplitButton)(e,
a,h);h.onMouseDown.add(f.hideMenu,f);h.onRemove.add(function(){f.destroy()});if(n.isIE){f.onShowMenu.add(function(){h.focus();d=h.selection.getBookmark(1)});f.onHideMenu.add(function(){if(d){h.selection.moveToBookmark(d);d=0}})}return this.add(f)},createToolbar:function(e,a,g){e=this.prefix+e;a=new (g||this._cls.toolbar||n.ui.Toolbar)(e,a,this.editor);if(this.get(e))return null;return this.add(a)},createToolbarGroup:function(e,a,g){e=this.prefix+e;a=new (g||this._cls.toolbarGroup||n.ui.ToolbarGroup)(e,
a,this.editor);if(this.get(e))return null;return this.add(a)},createSeparator:function(e){return new (e||this._cls.separator||n.ui.Separator)},setControlType:function(e,a){return this._cls[e.toLowerCase()]=a},destroy:function(){o(this.controls,function(e){e.destroy()});this.controls=null}})})(tinymce);
(function(n){var p=n.util.Dispatcher,o=n.each,q=n.isIE,e=n.isOpera;n.create("tinymce.WindowManager",{WindowManager:function(a){this.editor=a;this.onOpen=new p(this);this.onClose=new p(this);this.params={};this.features={}},open:function(a,g){var h="",f=this.editor.settings.dialog_type=="modal",d,j,k;k=n.DOM.getViewPort();a=a||{};g=g||{};j=e?k.w:screen.width;k=e?k.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=true;
a.left=a.left||parseInt(j/2)-a.width/2;a.top=a.top||parseInt(k/2)-a.height/2;g.inline=false;g.mce_width=a.width;g.mce_height=a.height;g.mce_auto_focus=a.auto_focus;if(f)if(q){a.center=true;a.help=false;a.dialogWidth=a.width+"px";a.dialogHeight=a.height+"px";a.scroll=a.scrollbars||false}o(a,function(c,l){if(n.is(c,"boolean"))c=c?"yes":"no";/^(name|url)$/.test(l)||(h+=q&&f?(h?";":"")+l+":"+c:(h?",":"")+l+"="+c)});this.features=a;this.params=g;this.onOpen.dispatch(this,a,g);g=a.url||a.file;g=n._addVer(g);
try{if(q&&f){d=1;window.showModalDialog(g,window,h)}else d=window.open(g,a.name,h)}catch(b){}d||alert(this.editor.getLang("popup_blocked"))},close:function(a){a.close();this.onClose.dispatch(this)},createInstance:function(a,g,h,f,d,j){return new (n.resolve(a))(g,h,f,d,j)},confirm:function(a,g,h,f){f=f||window;g.call(h||this,f.confirm(this._decode(this.editor.getLang(a,a))))},alert:function(a,g,h,f){f=f||window;f.alert(this._decode(this.editor.getLang(a,a)));if(g)g.call(h||this)},resizeBy:function(a,
g,h){h.resizeBy(a,g)},_decode:function(a){return n.DOM.decode(a).replace(/\\n/g,"\n")}})})(tinymce);
(function(n){n.Formatter=function(p){function o(z,A){return K.getParents(z,A,K.getRoot())}function q(z){return z.nodeType===1&&(z.face==="mceinline"||z.style.fontFamily==="mceinline")}function e(z){return z?P[z]:P}function a(z,A){if(z)if(typeof z!=="string")R(z,function(B,G){a(G,B)});else{A=A.length?A:[A];R(A,function(B){if(B.deep===la)B.deep=!B.selector;if(B.split===la)B.split=!B.selector||B.inline;if(B.remove===la&&B.selector&&!B.inline)B.remove="none";if(B.selector&&B.inline){B.mixed=true;B.block_expand=
true}if(typeof B.classes==="string")B.classes=B.classes.split(/\s+/)});P[z]=A}}function g(z,A,B){function G(E){var J=E.startContainer,N=E.startOffset;if(J.nodeType==1||J.nodeValue==="")if(J=J.nodeType==1?J.childNodes[N]:J){J=new D(J,J.parentNode);for(N=J.current();N;N=J.next())if(N.nodeType==3&&!m(N)){E.setStart(N,0);break}}return E}function I(E,J){J=J||Q;if(E){J.onformat&&J.onformat(E,J,A,B);R(J.styles,function(N,U){K.setStyle(E,U,i(N,A))});R(J.attributes,function(N,U){K.setAttrib(E,U,i(N,A))});
R(J.classes,function(N){N=i(N,A);K.hasClass(E,N)||K.addClass(E,N)})}}function L(){function E(da,ga){ga=new D(ga);for(B=ga.current();B;B=ga.prev())if(B.childNodes.length>1||B==da)return B}var J=p.selection.getRng(),N=J.startContainer,U=J.endContainer;if(N!=U&&J.endOffset==0){N=E(N,U);J.setEnd(N,N.nodeType==3?N.length:N.childNodes.length)}return J}function V(E,J,N,U,da){var ga=[],ca=-1,qa,ma=-1,ia=-1,oa;R(E.childNodes,function(ja,pa){if(ja.nodeName==="UL"||ja.nodeName==="OL"){ca=pa;qa=ja;return false}});
R(E.childNodes,function(ja,pa){if(ja.nodeName==="SPAN"&&K.getAttrib(ja,"data-mce-type")=="bookmark")if(ja.id==J.id+"_start")ma=pa;else if(ja.id==J.id+"_end")ia=pa});if(ca<=0||ma<ca&&ia>ca){R(n.grep(E.childNodes),da);return 0}else{oa=N.cloneNode(W);R(n.grep(E.childNodes),function(ja,pa){if(ma<ca&&pa<ca||ma>ca&&pa>ca){ga.push(ja);ja.parentNode.removeChild(ja)}});if(ma<ca)E.insertBefore(oa,qa);else ma>ca&&E.insertBefore(oa,qa.nextSibling);U.push(oa);R(ga,function(ja){oa.appendChild(ja)});return oa}}
function O(E,J,N){var U=[],da,ga;da=Q.inline||Q.block;ga=K.create(da);I(ga);Y.walk(E,function(ca){function qa(ia){var oa=ia.nodeName.toLowerCase(),ja=ia.parentNode.nodeName.toLowerCase(),pa;if(l(oa,"br")){ma=0;Q.block&&K.remove(ia)}else if(Q.wrapper&&d(ia,z,A))ma=0;else if(Q.block&&!Q.wrapper&&F(oa)){ia=K.rename(ia,da);I(ia);U.push(ia);ma=0}else{if(Q.selector){R(aa,function(ta){if(!("collapsed"in ta&&ta.collapsed!==T))if(K.is(ia,ta.selector)&&!q(ia)){I(ia,ta);pa=true}});if(!Q.inline||pa){ma=0;return}}if(Z(da,
oa)&&Z(ja,da)&&!(!N&&ia.nodeType===3&&ia.nodeValue.length===1&&ia.nodeValue.charCodeAt(0)===65279)&&ia.id!=="_mce_caret"){if(!ma){ma=ga.cloneNode(W);ia.parentNode.insertBefore(ma,ia);U.push(ma)}ma.appendChild(ia)}else if(oa=="li"&&J)ma=V(ia,J,ga,U,qa);else{ma=0;R(n.grep(ia.childNodes),qa);ma=0}}}var ma;R(ca,qa)});Q.wrap_links===false&&R(U,function(ca){function qa(ma){var ia,oa,ja;if(ma.nodeName==="A"){oa=ga.cloneNode(W);U.push(oa);ja=n.grep(ma.childNodes);for(ia=0;ia<ja.length;ia++)oa.appendChild(ja[ia]);
ma.appendChild(oa)}R(n.grep(ma.childNodes),qa)}qa(ca)});R(U,function(ca){function qa(oa){var ja=0;R(oa.childNodes,function(pa){!m(pa)&&!y(pa)&&ja++});return ja}function ma(oa){var ja,pa;R(oa.childNodes,function(ta){if(ta.nodeType==1&&!y(ta)&&!q(ta)){ja=ta;return W}});if(ja&&c(ja,Q)){pa=ja.cloneNode(W);I(pa);K.replace(pa,oa,$);K.remove(ja,1)}return pa||oa}var ia;ia=qa(ca);if((U.length>1||!ba(ca))&&ia===0)K.remove(ca,1);else if(Q.inline||Q.wrapper){if(!Q.exact&&ia===1)ca=ma(ca);R(aa,function(oa){R(K.select(oa.inline,
ca),function(ja){var pa;if(oa.wrap_links===false){pa=ja.parentNode;do if(pa.nodeName==="A")return;while(pa=pa.parentNode)}u(oa,A,ja,oa.exact?ja:null)})});if(d(ca.parentNode,z,A)){K.remove(ca,1);ca=0;return $}Q.merge_with_parents&&K.getParent(ca.parentNode,function(oa){if(d(oa,z,A)){K.remove(ca,1);ca=0;return $}});if(ca&&Q.merge_siblings!==false){ca=C(x(ca),ca);ca=C(ca,x(ca,$))}}})}var aa=e(z),Q=aa[0],ea,T=S.isCollapsed();if(Q)if(B)if(B.nodeType){ea=K.createRng();ea.setStartBefore(B);ea.setEndAfter(B);
O(t(ea,aa),null,true)}else O(B,null,true);else if(!T||!Q.inline||K.select("td.mceSelected,th.mceSelected").length){var X=p.selection.getNode();p.selection.setRng(L());ea=S.getBookmark();O(t(S.getRng($),aa),ea);if(Q.styles&&(Q.styles.color||Q.styles.textDecoration)){n.walk(X,ra,"childNodes");ra(X)}S.moveToBookmark(ea);S.setRng(G(S.getRng($)));p.nodeChanged()}else M("apply",z,A)}function h(z,A,B){function G(E){var J=E.startContainer,N=E.startOffset,U;if(J.nodeType==3&&N>=J.nodeValue.length-1){J=J.parentNode;
N=ha(J)+1}if(J.nodeType==1){U=J.childNodes;J=U[Math.min(N,U.length-1)];J=new D(J);N>U.length-1&&J.next();for(N=J.current();N;N=J.next())if(N.nodeType==3&&!m(N)){J=K.create("a",null,na);N.parentNode.insertBefore(J,N);E.setStart(N,0);S.setRng(E);K.remove(J);return}}}function I(E){var J,N,U;J=n.grep(E.childNodes);N=0;for(U=ea.length;N<U;N++)if(u(ea[N],A,E,E))break;if(T.deep){N=0;for(U=J.length;N<U;N++)I(J[N])}}function L(E){var J;R(o(E.parentNode).reverse(),function(N){var U;if(!J&&N.id!="_start"&&N.id!=
"_end")if((U=d(N,z,A))&&U.split!==false)J=N});return J}function V(E,J,N,U){var da,ga,ca,qa,ma,ia;if(E){ia=E.parentNode;for(da=J.parentNode;da&&da!=ia;da=da.parentNode){ga=da.cloneNode(W);for(ma=0;ma<ea.length;ma++)if(u(ea[ma],A,ga,ga)){ga=0;break}if(ga){ca&&ga.appendChild(ca);qa||(qa=ga);ca=ga}}if(U&&(!T.mixed||!ba(E)))J=K.split(E,J);if(ca){N.parentNode.insertBefore(ca,N);qa.appendChild(N)}}return J}function O(E){return V(L(E),E,E,true)}function aa(E){var J=K.get(E?"_start":"_end"),N=J[E?"firstChild":
"lastChild"];if(y(N))N=N[E?"firstChild":"lastChild"];K.remove(J,true);return N}function Q(E){var J,N;E=t(E,ea,$);if(T.split){J=H(E,$);N=H(E);if(J!=N){J=r(J,"span",{id:"_start","data-mce-type":"bookmark"});N=r(N,"span",{id:"_end","data-mce-type":"bookmark"});O(J);O(N);J=aa($);N=aa()}else J=N=O(J);E.startContainer=J.parentNode;E.startOffset=ha(J);E.endContainer=N.parentNode;E.endOffset=ha(N)+1}Y.walk(E,function(U){R(U,function(da){I(da);da.nodeType===1&&p.dom.getStyle(da,"text-decoration")==="underline"&&
da.parentNode&&sa(da.parentNode)==="underline"&&u({deep:false,exact:true,inline:"span",styles:{textDecoration:"underline"}},null,da)})})}var ea=e(z),T=ea[0],X;if(B)if(B.nodeType){X=K.createRng();X.setStartBefore(B);X.setEndAfter(B);Q(X)}else Q(B);else{if(!S.isCollapsed()||!T.inline||K.select("td.mceSelected,th.mceSelected").length){B=S.getBookmark();Q(S.getRng($));S.moveToBookmark(B);T.inline&&j(z,A,S.getStart())&&G(S.getRng(true));p.nodeChanged()}else M("remove",z,A);n.isWebKit&&p.execCommand("mceCleanup")}}
function f(z,A,B){var G=e(z);j(z,A,B)&&(!("toggle"in G[0])||G[0].toggle)?h(z,A,B):g(z,A,B)}function d(z,A,B,G){function I(O,aa,Q){var ea,T,X=aa[Q];if(aa.onmatch)return aa.onmatch(O,aa,Q);if(X)if(X.length===la)for(ea in X){if(X.hasOwnProperty(ea)){T=Q==="attributes"?K.getAttrib(O,ea):s(O,ea);if(G&&!T&&!aa.exact)return;if((!G||aa.exact)&&!l(T,i(X[ea],B)))return}}else for(ea=0;ea<X.length;ea++)if(Q==="attributes"?K.getAttrib(O,X[ea]):s(O,X[ea]))return aa;return aa}var L=e(A),V;if(L&&z)for(V=0;V<L.length;V++){A=
L[V];if(c(z,A)&&I(z,A,"attributes")&&I(z,A,"styles")){if(L=A.classes)for(V=0;V<L.length;V++)if(!K.hasClass(z,L[V]))return;return A}}}function j(z,A,B){function G(L){L=K.getParent(L,function(V){return!!d(V,z,A,true)});return d(L,z,A)}var I;if(B)return G(B);B=S.getNode();if(G(B))return $;I=S.getStart();if(I!=B)if(G(I))return $;return W}function k(z,A){var B,G=[],I={};B=S.getStart();K.getParent(B,function(L){var V,O;for(V=0;V<z.length;V++){O=z[V];if(!I[O]&&d(L,O,A)){I[O]=true;G.push(O)}}});return G}
function b(z){z=e(z);var A,B,G,I;if(z){A=S.getStart();A=o(A);for(G=z.length-1;G>=0;G--){I=z[G].selector;if(!I)return $;for(B=A.length-1;B>=0;B--)if(K.is(A[B],I))return $}}return W}function c(z,A){if(l(z,A.inline))return $;if(l(z,A.block))return $;if(A.selector)return K.is(z,A.selector)}function l(z,A){z=z||"";A=A||"";z=""+(z.nodeName||z);A=""+(A.nodeName||A);return z.toLowerCase()==A.toLowerCase()}function s(z,A){z=K.getStyle(z,A);if(A=="color"||A=="backgroundColor")z=K.toHex(z);if(A=="fontWeight"&&
z==700)z="bold";return""+z}function i(z,A){if(typeof z!="string")z=z(A);else if(A)z=z.replace(/%(\w+)/g,function(B,G){return A[G]||B});return z}function m(z){return z&&z.nodeType===3&&/^([\t \r\n]+|)$/.test(z.nodeValue)}function r(z,A,B){A=K.create(A,B);z.parentNode.insertBefore(A,z);A.appendChild(z);return A}function t(z,A,B){function G(T){var X,E,J;X=E=T?L:O;J=T?"previousSibling":"nextSibling";root=K.getRoot();if(X.nodeType==3&&!m(X))if(T?V>0:aa<X.nodeValue.length)return X;for(;;){if(E==root||!A[0].block_expand&&
ba(E))return E;for(T=E[J];T;T=T[J])if(!y(T)&&!m(T))return E;E=E.parentNode}return X}function I(T,X){if(X===la)X=T.nodeType===3?T.length:T.childNodes.length;for(;T&&T.hasChildNodes();)if(T=T.childNodes[X])X=T.nodeType===3?T.length:T.childNodes.length;return{node:T,offset:X}}var L=z.startContainer,V=z.startOffset,O=z.endContainer,aa=z.endOffset,Q;if(L.nodeType==1&&L.hasChildNodes()){Q=L.childNodes.length-1;L=L.childNodes[V>Q?Q:V];if(L.nodeType==3)V=0}if(O.nodeType==1&&O.hasChildNodes()){Q=O.childNodes.length-
1;O=O.childNodes[aa>Q?Q:aa-1];if(O.nodeType==3)aa=O.nodeValue.length}if(y(L.parentNode)||y(L)){L=y(L)?L:L.parentNode;L=L.nextSibling||L;if(L.nodeType==3)V=0}if(y(O.parentNode)||y(O)){O=y(O)?O:O.parentNode;O=O.previousSibling||O;if(O.nodeType==3)aa=O.length}if(A[0].inline){if(z.collapsed){var ea=function(T,X,E){function J(da,ga){var ca=da.nodeValue;if(typeof ga=="undefined")ga=E?ca.length:0;if(E){da=ca.lastIndexOf(" ",ga);ga=ca.lastIndexOf("\u00a0",ga);da=da>ga?da:ga;da!==-1&&!B&&da++}else{da=ca.indexOf(" ",
ga);ga=ca.indexOf("\u00a0",ga);da=da!==-1&&(ga===-1||da<ga)?da:ga}return da}var N,U;if(T.nodeType===3){X=J(T,X);if(X!==-1)return{container:T,offset:X};U=T}for(T=new D(T,K.getParent(T,ba)||p.getBody());N=T[E?"prev":"next"]();)if(N.nodeType===3){U=N;X=J(N);if(X!==-1)return{container:N,offset:X}}else if(ba(N))break;if(U){X=E?0:U.length;return{container:U,offset:X}}};if(Q=ea(L,V,true)){L=Q.container;V=Q.offset}if(Q=ea(O,aa)){O=Q.container;aa=Q.offset}}Q=I(O,aa);if(Q.node){for(;Q.node&&Q.offset===0&&Q.node.previousSibling;)Q=
I(Q.node.previousSibling);if(Q.node&&Q.offset>0&&Q.node.nodeType===3&&Q.node.nodeValue.charAt(Q.offset-1)===" ")if(Q.offset>1){O=Q.node;O.splitText(Q.offset-1)}}}if(A[0].inline||A[0].block_expand){if(!A[0].inline||L.nodeType!=3||V===0)L=G(true);if(!A[0].inline||O.nodeType!=3||aa===O.nodeValue.length)O=G()}if(A[0].selector&&A[0].expand!==W&&!A[0].inline){Q=function(T,X){var E,J,N;if(T.nodeType==3&&T.nodeValue.length==0&&T[X])T=T[X];X=o(T);for(E=0;E<X.length;E++)for(J=0;J<A.length;J++){N=A[J];if(!("collapsed"in
N&&N.collapsed!==z.collapsed))if(K.is(X[E],N.selector))return X[E]}return T};L=Q(L,"previousSibling");O=Q(O,"nextSibling")}if(A[0].block||A[0].selector){Q=function(T,X){var E;A[0].wrapper||(E=K.getParent(T,A[0].block));E||(E=K.getParent(T.nodeType==3?T.parentNode:T,ba));if(E&&A[0].wrapper)E=o(E,"ul,ol").reverse()[0]||E;if(!E)for(E=T;E[X]&&!ba(E[X]);){E=E[X];if(l(E,"br"))break}return E||T};L=Q(L,"previousSibling");O=Q(O,"nextSibling");if(A[0].block){ba(L)||(L=G(true));ba(O)||(O=G())}}if(L.nodeType==
1){V=ha(L);L=L.parentNode}if(O.nodeType==1){aa=ha(O)+1;O=O.parentNode}return{startContainer:L,startOffset:V,endContainer:O,endOffset:aa}}function u(z,A,B,G){var I,L,V;if(!c(B,z))return W;if(z.remove!="all"){R(z.styles,function(O,aa){O=i(O,A);if(typeof aa==="number"){aa=O;G=0}if(!G||l(s(G,aa),O))K.setStyle(B,aa,"");V=1});if(V&&K.getAttrib(B,"style")==""){B.removeAttribute("style");B.removeAttribute("data-mce-style")}R(z.attributes,function(O,aa){var Q;O=i(O,A);if(typeof aa==="number"){aa=O;G=0}if(!G||
l(K.getAttrib(G,aa),O)){if(aa=="class")if(O=K.getAttrib(B,aa)){Q="";R(O.split(/\s+/),function(ea){if(/mce\w+/.test(ea))Q+=(Q?" ":"")+ea});if(Q){K.setAttrib(B,aa,Q);return}}aa=="class"&&B.removeAttribute("className");fa.test(aa)&&B.removeAttribute("data-mce-"+aa);B.removeAttribute(aa)}});R(z.classes,function(O){O=i(O,A);if(!G||K.hasClass(G,O))K.removeClass(B,O)});L=K.getAttribs(B);for(I=0;I<L.length;I++)if(L[I].nodeName.indexOf("_")!==0)return W}if(z.remove!="none"){v(B,z);return $}}function v(z,A){var B=
z.parentNode,G;if(A.block)if(ka){if(B==K.getRoot())if(!A.list_block||!l(z,A.list_block))R(n.grep(z.childNodes),function(L){if(Z(ka,L.nodeName.toLowerCase()))if(G)G.appendChild(L);else G=r(L,ka);else G=0})}else{var I=function(L,V,O){L=x(L,V,O);return!L||L.nodeName=="BR"||ba(L)};if(ba(z)&&!ba(B)){!I(z,W)&&!I(z.firstChild,$,1)&&z.insertBefore(K.create("br"),z.firstChild);!I(z,$)&&!I(z.lastChild,W,1)&&z.appendChild(K.create("br"))}}A.selector&&A.inline&&!l(A.inline,z)||K.remove(z,1)}function x(z,A,B){if(z){A=
A?"nextSibling":"previousSibling";for(z=B?z:z[A];z;z=z[A])if(z.nodeType==1||!m(z))return z}}function y(z){return z&&z.nodeType==1&&z.getAttribute("data-mce-type")=="bookmark"}function C(z,A){function B(L,V){function O(Q){var ea={};R(K.getAttribs(Q),function(T){T=T.nodeName.toLowerCase();if(T.indexOf("_")!==0&&T!=="style")ea[T]=K.getAttrib(Q,T)});return ea}function aa(Q,ea){var T,X;for(X in Q)if(Q.hasOwnProperty(X)){T=ea[X];if(T===la)return W;if(Q[X]!=T)return W;delete ea[X]}for(X in ea)if(ea.hasOwnProperty(X))return W;
return $}if(L.nodeName!=V.nodeName)return W;if(!aa(O(L),O(V)))return W;if(!aa(K.parseStyle(K.getAttrib(L,"style")),K.parseStyle(K.getAttrib(V,"style"))))return W;return $}var G,I;if(z&&A){I=function(L,V){for(G=L;G;G=G[V]){if(G.nodeType==3&&G.nodeValue.length!==0)return L;if(G.nodeType==1&&!y(G))return G}return L};z=I(z,"previousSibling");A=I(A,"nextSibling");if(B(z,A)){for(G=z.nextSibling;G&&G!=A;){I=G;G=G.nextSibling;z.appendChild(I)}K.remove(A);R(n.grep(A.childNodes),function(L){z.appendChild(L)});
return z}}return A}function F(z){return/^(h[1-6]|p|div|pre|address|dl|dt|dd)$/.test(z)}function H(z,A){var B,G;B=z[A?"startContainer":"endContainer"];z=z[A?"startOffset":"endOffset"];if(B.nodeType==1){G=B.childNodes.length-1;!A&&z&&z--;B=B.childNodes[z>G?G:z]}if(B.nodeType===3&&A&&z>=B.nodeValue.length)B=(new D(B,p.getBody())).next()||B;if(B.nodeType===3&&!A&&z==0)B=(new D(B,p.getBody())).prev()||B;return B}function M(z,A,B){function G(E){var J=K.create("span",{id:T,"data-mce-bogus":true,style:X?
"color:red":""});E&&J.appendChild(p.getDoc().createTextNode(ea));return J}function I(E,J){for(;E;){if(E.nodeType===3&&E.nodeValue!==ea||E.childNodes.length>1)return false;J&&E.nodeType===1&&J.push(E);E=E.firstChild}return true}function L(E){for(;E;){if(E.id===T)return E;E=E.parentNode}}function V(E){var J;if(E){J=new D(E,E);for(E=J.current();E;E=J.next())if(E.nodeType===3)return E}}function O(E,J){var N;if(E){N=S.getRng(true);if(I(E)){if(J!==false){N.setStartBefore(E);N.setEndBefore(E)}K.remove(E)}else{J=
V(E);J.deleteData(0,1);K.remove(E,1)}S.setRng(N)}else{E=L(S.getStart());if(!E)for(;E=K.get(T);)O(E,false)}}function aa(){var E,J,N,U,da;E=S.getRng(true);U=E.startOffset;da=E.startContainer.nodeValue;if(J=L(S.getStart()))N=V(J);if(da&&U>0&&U<da.length&&/\w/.test(da.charAt(U))&&/\w/.test(da.charAt(U-1))){J=S.getBookmark();E.collapse(true);E=t(E,e(A));E=Y.split(E);g(A,B,E);S.moveToBookmark(J)}else{if(!J||N.nodeValue!==ea){J=G(true);N=J.firstChild;E.insertNode(J);U=1}g(A,B,J);S.setCursorLocation(N,U)}}
function Q(){var E=S.getRng(true),J,N,U,da,ga,ca=[];J=E.startContainer;N=E.startOffset;U=J;if(J.nodeType==3){if(N!=J.nodeValue.length||J.nodeValue===ea)da=true;U=U.parentNode}for(;U;){if(d(U,A,B)){ga=U;break}if(U.nextSibling)da=true;ca.push(U);U=U.parentNode}if(ga)if(da){U=S.getBookmark();E.collapse(true);E=t(E,e(A),true);E=Y.split(E);h(A,B,E);S.moveToBookmark(U)}else{U=J=G();for(E=ca.length-1;E>=0;E--){U.appendChild(ca[E].cloneNode(false));U=U.firstChild}U.appendChild(K.doc.createTextNode(ea));U=
U.firstChild;K.insertAfter(J,ga);S.setCursorLocation(U,1)}}var ea,T="_mce_caret",X=p.settings.caret_debug;ea=n.isGecko?"\u200b":na;p.onBeforeGetContent.addToTop(function(){var E=[],J;if(I(L(S.getStart()),E))for(J=E.length;J--;)K.setAttrib(E[J],"data-mce-bogus","1")});n.each("onMouseUp onKeyUp".split(" "),function(E){p[E].addToTop(function(){O()})});p.onKeyDown.addToTop(function(E,J){E=J.keyCode;if(E==8||E==37||E==39)O(L(S.getStart()))});z=="apply"?aa():Q()}var P={},R=n.each,K=p.dom,S=p.selection,
D=n.dom.TreeWalker,Y=new n.dom.RangeUtils(K),Z=p.schema.isValidChild,ba=K.isBlock,ka=p.settings.forced_root_block,ha=K.nodeIndex,na="\ufeff",fa=/^(src|href|style)$/,W=false,$=true,la,sa=function(z){var A;p.dom.getParent(z,function(B){return(A=p.dom.getStyle(B,"text-decoration"))&&A!=="none"});return A},ra=function(z){var A;if(z.nodeType===1&&z.parentNode&&z.parentNode.nodeType===1){A=sa(z.parentNode);if(p.dom.getStyle(z,"color")&&A)p.dom.setStyle(z,"text-decoration",A);else p.dom.getStyle(z,"textdecoration")===
A&&p.dom.setStyle(z,"text-decoration",null)}};n.extend(this,{get:e,register:a,apply:g,remove:h,toggle:f,match:j,matchAll:k,matchNode:d,canApply:b})}})(tinymce);
tinymce.onAddEditor.add(function(n,p){var o,q,e,a=p.settings;if(a.inline_styles){q=n.explode(a.font_size_legacy_values);var g=function(f,d){n.each(d,function(j,k){j&&e.setStyle(f,k,j)});e.rename(f,"span")};o={font:function(f,d){g(d,{backgroundColor:d.style.backgroundColor,color:d.color,fontFamily:d.face,fontSize:q[parseInt(d.size)-1]})},u:function(f,d){g(d,{textDecoration:"underline"})},strike:function(f,d){g(d,{textDecoration:"line-through"})}};var h=function(f,d){e=f.dom;a.convert_fonts_to_spans&&
n.each(e.select("font,u,strike",d.node),function(j){o[j.nodeName.toLowerCase()](p.dom,j)})};p.onPreProcess.add(h);p.onSetContent.add(h);p.onInit.add(function(){p.selection.onSetContent.add(h)})}});
var TMCEFix={settings:{themes:"advanced",plugins:"bligooimages,externalcode,youtube,vimeo,fileupload,pagebreak,flash,paste",languages:"es",suffix:""},start:function(){function n(e){tinymce.ScriptLoader.markDone(tinyMCE.baseURI.toAbsolute(e))}var p=tinymce.each,o=this.settings,q=o.languages.split(",");tinymce.suffix=o.suffix;p(q,function(e){e&&n("langs/"+e+".js")});p(o.themes.split(","),function(e){if(e){n("themes/"+e+"/editor_template"+o.suffix+".js");p(q,function(a){a&&n("themes/"+e+"/langs/"+a+
".js")})}});p(o.plugins.split(","),function(e){if(e){n("plugins/"+e+"/editor_plugin"+o.suffix+".js");p(q,function(a){a&&n("plugins/"+e+"/langs/"+a+".js")})}})}};TMCEFix.start();
(function(n){var p=n.DOM,o=n.dom.Event,q=n.extend,e=n.each,a=n.util.Cookie,g,h=n.explode;n.ThemeManager.requireLangPack("advanced");n.create("tinymce.themes.AdvancedTheme",{sizes:[8,10,12,14,18,24,36],controls:{bold:["bold_desc","Bold"],italic:["italic_desc","Italic"],underline:["underline_desc","Underline"],strikethrough:["striketrough_desc","Strikethrough"],justifyleft:["justifyleft_desc","JustifyLeft"],justifycenter:["justifycenter_desc","JustifyCenter"],justifyright:["justifyright_desc","JustifyRight"],
justifyfull:["justifyfull_desc","JustifyFull"],bullist:["bullist_desc","InsertUnorderedList"],numlist:["numlist_desc","InsertOrderedList"],outdent:["outdent_desc","Outdent"],indent:["indent_desc","Indent"],cut:["cut_desc","Cut"],copy:["copy_desc","Copy"],paste:["paste_desc","Paste"],undo:["undo_desc","Undo"],redo:["redo_desc","Redo"],link:["link_desc","mceLink"],unlink:["unlink_desc","unlink"],image:["image_desc","mceImage"],cleanup:["cleanup_desc","mceCleanup"],help:["help_desc","mceHelp"],code:["code_desc",
"mceCodeEditor"],hr:["hr_desc","InsertHorizontalRule"],removeformat:["removeformat_desc","RemoveFormat"],sub:["sub_desc","subscript"],sup:["sup_desc","superscript"],forecolor:["forecolor_desc","ForeColor"],forecolorpicker:["forecolor_desc","mceForeColor"],backcolor:["backcolor_desc","HiliteColor"],backcolorpicker:["backcolor_desc","mceBackColor"],charmap:["charmap_desc","mceCharMap"],visualaid:["visualaid_desc","mceToggleVisualAid"],anchor:["anchor_desc","mceInsertAnchor"],newdocument:["newdocument_desc",
"mceNewDocument"],blockquote:["blockquote_desc","mceBlockQuote"]},stateControls:["bold","italic","underline","strikethrough","bullist","numlist","justifyleft","justifycenter","justifyright","justifyfull","sub","sup","blockquote"],init:function(f,d){var j=this,k,b,c;j.editor=f;j.url=d;j.onResolveName=new n.util.Dispatcher(this);f.forcedHighContrastMode=f.settings.detect_highcontrast&&j._isHighContrast();f.settings.skin=f.forcedHighContrastMode?"highcontrast":f.settings.skin;j.settings=k=q({theme_advanced_path:true,
theme_advanced_toolbar_location:"bottom",theme_advanced_buttons1:"bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,|,styleselect,formatselect",theme_advanced_buttons2:"bullist,numlist,|,outdent,indent,|,undo,redo,|,link,unlink,anchor,image,cleanup,help,code",theme_advanced_buttons3:"hr,removeformat,visualaid,|,sub,sup,|,charmap",theme_advanced_blockformats:"p,address,pre,h1,h2,h3,h4,h5,h6",theme_advanced_toolbar_align:"center",theme_advanced_fonts:"Andale Mono=andale mono,times;Arial=arial,helvetica,sans-serif;Arial Black=arial black,avant garde;Book Antiqua=book antiqua,palatino;Comic Sans MS=comic sans ms,sans-serif;Courier New=courier new,courier;Georgia=georgia,palatino;Helvetica=helvetica;Impact=impact,chicago;Symbol=symbol;Tahoma=tahoma,arial,helvetica,sans-serif;Terminal=terminal,monaco;Times New Roman=times new roman,times;Trebuchet MS=trebuchet ms,geneva;Verdana=verdana,geneva;Webdings=webdings;Wingdings=wingdings,zapf dingbats",
theme_advanced_more_colors:1,theme_advanced_row_height:23,theme_advanced_resize_horizontal:1,theme_advanced_resizing_use_cookie:1,theme_advanced_font_sizes:"1,2,3,4,5,6,7",theme_advanced_font_selector:"span",theme_advanced_show_current_color:0,readonly:f.settings.readonly},f.settings);if(!k.font_size_style_values)k.font_size_style_values="8pt,10pt,12pt,14pt,18pt,24pt,36pt";if(n.is(k.theme_advanced_font_sizes,"string")){k.font_size_style_values=n.explode(k.font_size_style_values);k.font_size_classes=
n.explode(k.font_size_classes||"");c={};f.settings.theme_advanced_font_sizes=k.theme_advanced_font_sizes;e(f.getParam("theme_advanced_font_sizes","","hash"),function(l,s){var i;if(s==l&&l>=1&&l<=7){s=l+" ("+j.sizes[l-1]+"pt)";i=k.font_size_classes[l-1];l=k.font_size_style_values[l-1]||j.sizes[l-1]+"pt"}if(/^\s*\./.test(l))i=l.replace(/\./g,"");c[s]=i?{"class":i}:{fontSize:l}});k.theme_advanced_font_sizes=c}if((b=k.theme_advanced_path_location)&&b!="none")k.theme_advanced_statusbar_location=k.theme_advanced_path_location;
if(k.theme_advanced_statusbar_location=="none")k.theme_advanced_statusbar_location=0;f.settings.content_css!==false&&f.contentCSS.push(f.baseURI.toAbsolute(d+"/skins/"+f.settings.skin+"/content.css"));f.onInit.add(function(){if(!f.settings.readonly){f.onNodeChange.add(j._nodeChanged,j);f.onKeyUp.add(j._updateUndoStatus,j);f.onMouseUp.add(j._updateUndoStatus,j);f.dom.bind(f.dom.getRoot(),"dragend",function(){j._updateUndoStatus(f)})}});f.onSetProgressState.add(function(l,s,i){var m,r=l.id,t;if(s)j.progressTimer=
setTimeout(function(){m=l.getContainer();m=m.insertBefore(p.create("DIV",{style:"position:relative"}),m.firstChild);t=p.get(l.id+"_tbl");p.add(m,"div",{id:r+"_blocker","class":"mceBlocker",style:{width:t.clientWidth+2,height:t.clientHeight+2}});p.add(m,"div",{id:r+"_progress","class":"mceProgress",style:{left:t.clientWidth/2,top:t.clientHeight/2}})},i||0);else{p.remove(r+"_blocker");p.remove(r+"_progress");clearTimeout(j.progressTimer)}});p.loadCSS(k.editor_css?f.documentBaseURI.toAbsolute(k.editor_css):
d+"/skins/"+f.settings.skin+"/ui.css");k.skin_variant&&p.loadCSS(d+"/skins/"+f.settings.skin+"/ui_"+k.skin_variant+".css")},_isHighContrast:function(){var f,d=p.add(p.getRoot(),"div",{style:"background-color: rgb(171,239,86);"});f=(p.getStyle(d,"background-color",true)+"").toLowerCase().replace(/ /g,"");p.remove(d);return f!="rgb(171,239,86)"&&f!="#abef56"},createControl:function(f,d){var j;if(j=d.createControl(f))return j;switch(f){case "styleselect":return this._createStyleSelect();case "formatselect":return this._createBlockFormats();
case "fontselect":return this._createFontSelect();case "fontsizeselect":return this._createFontSizeSelect();case "forecolor":return this._createForeColorMenu();case "backcolor":return this._createBackColorMenu()}if(j=this.controls[f])return d.createButton(f,{title:"advanced."+j[0],cmd:j[1],ui:j[2],value:j[3]})},execCommand:function(f,d,j){if(f=this["_"+f]){f.call(this,d,j);return true}return false},_importClasses:function(){var f=this.editor,d=f.controlManager.get("styleselect");d.getLength()==0&&
e(f.dom.getClasses(),function(j,k){k="style_"+k;f.formatter.register(k,{inline:"span",attributes:{"class":j["class"]},selector:"*"});d.add(j["class"],k)})},_createStyleSelect:function(){var f=this,d=f.editor,j;j=d.controlManager.createListBox("styleselect",{title:"advanced.style_select",onselect:function(k){var b,c=[];e(j.items,function(l){c.push(l.value)});d.focus();d.undoManager.add();b=d.formatter.matchAll(c);if(!k||b[0]==k)b[0]&&d.formatter.remove(b[0]);else d.formatter.apply(k);d.undoManager.add();
d.nodeChanged();return false}});d.onInit.add(function(){var k=0,b=d.getParam("style_formats");b?e(b,function(c){var l,s=0;e(c,function(){s++});if(s>1){l=c.name=c.name||"style_"+k++;d.formatter.register(l,c);j.add(c.title,l)}else j.add(c.title)}):e(d.getParam("theme_advanced_styles","","hash"),function(c,l){var s;if(c){s="style_"+k++;d.formatter.register(s,{inline:"span",classes:c,selector:"*"});j.add(f.editor.translate(l),s)}})});j.getLength()==0&&j.onPostRender.add(function(k,b){if(j.NativeListBox)o.add(b.id,
"focus",f._importClasses,f);else{o.add(b.id+"_text","focus",f._importClasses,f);o.add(b.id+"_text","mousedown",f._importClasses,f);o.add(b.id+"_open","focus",f._importClasses,f);o.add(b.id+"_open","mousedown",f._importClasses,f)}});return j},_createFontSelect:function(){var f,d=this.editor;(f=d.controlManager.createListBox("fontselect",{title:"advanced.fontdefault",onselect:function(j){var k=f.items[f.selectedIndex];if(!j&&k)d.execCommand("FontName",false,k.value);else{d.execCommand("FontName",false,
j);f.select(function(b){return j==b});k&&k.value==j&&f.select(null);return false}}}))&&e(d.getParam("theme_advanced_fonts",this.settings.theme_advanced_fonts,"hash"),function(j,k){f.add(d.translate(k),j,{style:j.indexOf("dings")==-1?"font-family:"+j:""})});return f},_createFontSizeSelect:function(){var f=this,d=f.editor,j,k=0;(j=d.controlManager.createListBox("fontsizeselect",{title:"",onselect:function(b){var c=j.items[j.selectedIndex];if(!b&&c){c=c.value;if(c["class"]){d.formatter.toggle("fontsize_class",
{value:c["class"]});d.undoManager.add();d.nodeChanged()}else d.execCommand("FontSize",false,c.fontSize)}else{if(b["class"]){d.focus();d.undoManager.add();d.formatter.toggle("fontsize_class",{value:b["class"]});d.undoManager.add();d.nodeChanged()}else d.execCommand("FontSize",false,b.fontSize);j.select(function(l){return b==l});if(c&&(c.value.fontSize==b.fontSize||c.value["class"]==b["class"]))j.select(null);return false}}}))&&e(f.settings.theme_advanced_font_sizes,function(b,c){var l=b.fontSize;if(l>=
1&&l<=7)l=f.sizes[parseInt(l)-1]+"pt";j.add(c,b,{style:"font-size:"+l,"class":"mceFontSize"+k++ +(" "+(b["class"]||""))})});return j},_createBlockFormats:function(){var f,d={p:"advanced.paragraph",address:"advanced.address",pre:"advanced.pre",h1:"advanced.h1",h2:"advanced.h2",h3:"advanced.h3",h4:"advanced.h4",h5:"advanced.h5",h6:"advanced.h6",div:"advanced.div",blockquote:"advanced.blockquote",code:"advanced.code",dt:"advanced.dt",dd:"advanced.dd",samp:"advanced.samp"},j=this;(f=j.editor.controlManager.createListBox("formatselect",
{title:"advanced.block",onselect:function(k){j.editor.execCommand("FormatBlock",false,k);return false}}))&&e(j.editor.getParam("theme_advanced_blockformats",j.settings.theme_advanced_blockformats,"hash"),function(k,b){f.add(j.editor.translate(b!=k?b:d[k]),k,{"class":"mce_formatPreview mce_"+k})});return f},_createForeColorMenu:function(){var f,d=this,j=d.settings,k={},b;if(j.theme_advanced_more_colors)k.more_colors_func=function(){d._mceColorPicker(0,{color:f.value,func:function(c){f.setColor(c)}})};
if(b=j.theme_advanced_text_colors)k.colors=b;if(j.theme_advanced_default_foreground_color)k.default_color=j.theme_advanced_default_foreground_color;k.title="advanced.forecolor_desc";k.cmd="ForeColor";k.scope=this;return f=d.editor.controlManager.createColorSplitButton("forecolor",k)},_createBackColorMenu:function(){var f,d=this,j=d.settings,k={},b;if(j.theme_advanced_more_colors)k.more_colors_func=function(){d._mceColorPicker(0,{color:f.value,func:function(c){f.setColor(c)}})};if(b=j.theme_advanced_background_colors)k.colors=
b;if(j.theme_advanced_default_background_color)k.default_color=j.theme_advanced_default_background_color;k.title="advanced.backcolor_desc";k.cmd="HiliteColor";k.scope=this;return f=d.editor.controlManager.createColorSplitButton("backcolor",k)},renderUI:function(f){var d,j,k,b=this,c=b.editor,l=b.settings,s,i,m;if(c.settings)c.settings.aria_label=l.aria_label+c.getLang("advanced.help_shortcut");d=i=p.create("span",{role:"application","aria-labelledby":c.id+"_voice",id:c.id+"_parent","class":"mceEditor "+
c.settings.skin+"Skin"+(l.skin_variant?" "+c.settings.skin+"Skin"+b._ufirst(l.skin_variant):"")});p.add(d,"span",{"class":"mceVoiceLabel",style:"display:none;",id:c.id+"_voice"},l.aria_label);p.boxModel||(d=p.add(d,"div",{"class":"mceOldBoxModel"}));d=s=p.add(d,"table",{role:"presentation",id:c.id+"_tbl","class":"mceLayout",cellSpacing:0,cellPadding:0});d=k=p.add(d,"tbody");switch((l.theme_advanced_layout_manager||"").toLowerCase()){case "rowlayout":j=b._rowLayout(l,k,f);break;case "customlayout":j=
c.execCallback("theme_advanced_custom_layout",l,k,f,i);break;default:j=b._simpleLayout(l,k,f,i)}d=f.targetNode;m=s.rows;p.addClass(m[0],"mceFirst");p.addClass(m[m.length-1],"mceLast");e(p.select("tr",k),function(r){p.addClass(r.firstChild,"mceFirst");p.addClass(r.childNodes[r.childNodes.length-1],"mceLast")});p.get(l.theme_advanced_toolbar_container)?p.get(l.theme_advanced_toolbar_container).appendChild(i):p.insertAfter(i,d);o.add(c.id+"_path_row","click",function(r){r=r.target;if(r.nodeName=="A"){b._sel(r.className.replace(/^.*mcePath_([0-9]+).*$/,
"$1"));return o.cancel(r)}});c.getParam("accessibility_focus")||o.add(p.add(i,"a",{href:"#"},"<!-- IE --\>"),"focus",function(){tinyMCE.get(c.id).focus()});if(l.theme_advanced_toolbar_location=="external")f.deltaHeight=0;b.deltaHeight=f.deltaHeight;f.targetNode=null;c.onKeyDown.add(function(r,t){if(t.altKey)if(t.keyCode===121){n.isWebKit&&window.focus();b.toolbarGroup.focus();return o.cancel(t)}else if(t.keyCode===122){p.get(r.id+"_path_row").focus();return o.cancel(t)}});c.addShortcut("alt+0","",
"mceShortcuts",b);return{iframeContainer:j,editorContainer:c.id+"_parent",sizeContainer:s,deltaHeight:f.deltaHeight}},getInfo:function(){return{longname:"Advanced theme",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",version:n.majorVersion+"."+n.minorVersion}},resizeBy:function(f,d){var j=p.get(this.editor.id+"_ifr");this.resizeTo(j.clientWidth+f,j.clientHeight+d)},resizeTo:function(f,d,j){var k=this.editor,b=this.settings,c=p.get(k.id+"_tbl"),l=p.get(k.id+"_ifr");f=Math.max(b.theme_advanced_resizing_min_width||
100,f);d=Math.max(b.theme_advanced_resizing_min_height||100,d);f=Math.min(b.theme_advanced_resizing_max_width||65535,f);d=Math.min(b.theme_advanced_resizing_max_height||65535,d);p.setStyle(c,"height","");p.setStyle(l,"height",d);if(b.theme_advanced_resize_horizontal){p.setStyle(c,"width","");p.setStyle(l,"width",f);if(f<c.clientWidth){f=c.clientWidth;p.setStyle(l,"width",c.clientWidth)}}j&&b.theme_advanced_resizing_use_cookie&&a.setHash("TinyMCE_"+k.id+"_size",{cw:f,ch:d})},destroy:function(){var f=
this.editor.id;o.clear(f+"_resize");o.clear(f+"_path_row");o.clear(f+"_external_close")},_simpleLayout:function(f,d,j,k){var b=this.editor,c=f.theme_advanced_toolbar_location,l=f.theme_advanced_statusbar_location,s,i,m;if(f.readonly){s=p.add(d,"tr");return s=i=p.add(s,"td",{"class":"mceIframeContainer"})}c=="top"&&this._addToolbars(d,j);if(c=="external"){s=m=p.create("div",{style:"position:relative"});s=p.add(s,"div",{id:b.id+"_external","class":"mceExternalToolbar"});p.add(s,"a",{id:b.id+"_external_close",
href:"javascript:;","class":"mceExternalClose"});s=p.add(s,"table",{id:b.id+"_tblext",cellSpacing:0,cellPadding:0});s=p.add(s,"tbody");k.firstChild.className=="mceOldBoxModel"?k.firstChild.appendChild(m):k.insertBefore(m,k.firstChild);this._addToolbars(s,j);b.onMouseUp.add(function(){var r=p.get(b.id+"_external");p.show(r);p.hide(g);var t=o.add(b.id+"_external_close","click",function(){p.hide(b.id+"_external");o.remove(b.id+"_external_close","click",t)});p.show(r);p.setStyle(r,"top",0-p.getRect(b.id+
"_tblext").h-1);p.hide(r);p.show(r);r.style.filter="";g=b.id+"_external";r=null})}l=="top"&&this._addStatusBar(d,j);if(!f.theme_advanced_toolbar_container){s=p.add(d,"tr");s=i=p.add(s,"td",{"class":"mceIframeContainer"})}c=="bottom"&&this._addToolbars(d,j);l=="bottom"&&this._addStatusBar(d,j);return i},_rowLayout:function(f,d,j){var k=this,b,c,l=k.editor.controlManager,s,i,m,r;b=f.theme_advanced_containers_default_class||"";c=f.theme_advanced_containers_default_align||"center";e(h(f.theme_advanced_containers||
""),function(t,u){var v=f["theme_advanced_container_"+t]||"";switch(t.toLowerCase()){case "mceeditor":s=p.add(d,"tr");s=i=p.add(s,"td",{"class":"mceIframeContainer"});break;case "mceelementpath":k._addStatusBar(d,j);break;default:r=(f["theme_advanced_container_"+t+"_align"]||c).toLowerCase();r="mce"+k._ufirst(r);s=p.add(p.add(d,"tr"),"td",{"class":"mceToolbar "+(f["theme_advanced_container_"+t+"_class"]||b)+" "+r||c});m=l.createToolbar("toolbar"+u);k._addControls(v,m);p.setHTML(s,m.renderHTML());
j.deltaHeight-=f.theme_advanced_row_height}});return i},_addControls:function(f,d){var j=this,k=j.settings,b,c=j.editor.controlManager;if(k.theme_advanced_disable&&!j._disabled){b={};e(h(k.theme_advanced_disable),function(l){b[l]=1});j._disabled=b}else b=j._disabled;e(h(f),function(l){if(!(b&&b[l]))if(l=="tablecontrols")e(["table","|","row_props","cell_props","|","row_before","row_after","delete_row","|","col_before","col_after","delete_col","|","split_cells","merge_cells"],function(s){(s=j.createControl(s,
c))&&d.add(s)});else(l=j.createControl(l,c))&&d.add(l)})},_addToolbars:function(f,d){var j,k=this.editor,b=this.settings,c,l=k.controlManager,s,i=[],m;this.toolbarGroup=m=l.createToolbarGroup("toolbargroup",{name:k.getLang("advanced.toolbar"),tab_focus_toolbar:k.getParam("theme_advanced_tab_focus_toolbar")});j=b.theme_advanced_toolbar_align.toLowerCase();j="mce"+this._ufirst(j);s=p.add(p.add(f,"tr",{role:"presentation"}),"td",{"class":"mceToolbar "+j,role:"presentation"});for(f=1;c=b["theme_advanced_buttons"+
f];f++){j=l.createToolbar("toolbar"+f,{"class":"mceToolbarRow"+f});if(b["theme_advanced_buttons"+f+"_add"])c+=","+b["theme_advanced_buttons"+f+"_add"];if(b["theme_advanced_buttons"+f+"_add_before"])c=b["theme_advanced_buttons"+f+"_add_before"]+","+c;this._addControls(c,j);m.add(j);d.deltaHeight-=b.theme_advanced_row_height}i.push(m.renderHTML());i.push(p.createHTML("a",{href:"#",accesskey:"z",title:k.getLang("advanced.toolbar_focus"),onfocus:"tinyMCE.getInstanceById('"+k.id+"').focus();"},"<!-- IE --\>"));
p.setHTML(s,i.join(""))},_addStatusBar:function(f,d){var j=this,k=j.editor,b=j.settings,c;f=p.add(f,"tr");f=c=p.add(f,"td",{"class":"mceStatusbar"});f=p.add(f,"div",{id:k.id+"_path_row",role:"group","aria-labelledby":k.id+"_path_voice"});if(b.theme_advanced_path){p.add(f,"span",{id:k.id+"_path_voice"},k.translate("advanced.path"));p.add(f,"span",{},": ")}else p.add(f,"span",{},"&#160;");if(b.theme_advanced_resizing){p.add(c,"a",{id:k.id+"_resize",href:"javascript:;",onclick:"return false;","class":"mceResize",
tabIndex:"-1"});b.theme_advanced_resizing_use_cookie&&k.onPostRender.add(function(){var l=a.getHash("TinyMCE_"+k.id+"_size");p.get(k.id+"_tbl");l&&j.resizeTo(l.cw,l.ch)});k.onPostRender.add(function(){o.add(k.id+"_resize","click",function(l){l.preventDefault()});o.add(k.id+"_resize","mousedown",function(l){function s(M){M.preventDefault();F=y+(M.screenX-v);H=C+(M.screenY-x);j.resizeTo(F,H)}function i(M){o.remove(p.doc,"mousemove",m);o.remove(k.getDoc(),"mousemove",r);o.remove(p.doc,"mouseup",t);o.remove(k.getDoc(),
"mouseup",u);F=y+(M.screenX-v);H=C+(M.screenY-x);j.resizeTo(F,H,true)}var m,r,t,u,v,x,y,C,F,H;l.preventDefault();v=l.screenX;x=l.screenY;l=p.get(j.editor.id+"_ifr");y=F=l.clientWidth;C=H=l.clientHeight;m=o.add(p.doc,"mousemove",s);r=o.add(k.getDoc(),"mousemove",s);t=o.add(p.doc,"mouseup",i);u=o.add(k.getDoc(),"mouseup",i)})})}d.deltaHeight-=21;f=f=null},_updateUndoStatus:function(f){var d=f.controlManager;f=f.undoManager;d.setDisabled("undo",!f.hasUndo()&&!f.typing);d.setDisabled("redo",!f.hasRedo())},
_nodeChanged:function(f,d,j,k,b){function c(H){var M,P=b.parents,R=H;if(typeof H=="string")R=function(K){return K.nodeName==H};for(M=0;M<P.length;M++)if(R(P[M]))return P[M]}var l=this,s,i=0,m,r,t=l.settings,u,v,x,y,C,F;n.each(l.stateControls,function(H){d.setActive(H,f.queryCommandState(l.controls[H][1]))});d.setActive("visualaid",f.hasVisual);l._updateUndoStatus(f);d.setDisabled("outdent",!f.queryCommandState("Outdent"));s=c("A");if(r=d.get("link"))if(!s||!s.name){r.setDisabled(!s&&k);r.setActive(!!s)}if(r=
d.get("unlink")){r.setDisabled(!s&&k);r.setActive(!!s&&!s.name)}if(r=d.get("anchor"))r.setActive(!k&&!!s&&s.name);s=c("IMG");if(r=d.get("image"))r.setActive(!k&&!!s&&j.className.indexOf("mceItem")==-1);if(r=d.get("styleselect")){l._importClasses();F=[];e(r.items,function(H){F.push(H.value)});k=f.formatter.matchAll(F);r.select(k[0])}if(r=d.get("formatselect"))(s=c(p.isBlock))&&r.select(s.nodeName.toLowerCase());c(function(H){if(H.nodeName==="SPAN")if(!u&&H.className)u=H.className;if(f.dom.is(H,t.theme_advanced_font_selector)){if(!v&&
H.style.fontSize)v=H.style.fontSize;if(!x&&H.style.fontFamily)x=H.style.fontFamily.replace(/[\"\']+/g,"").replace(/^([^,]+).*/,"$1").toLowerCase();if(!y&&H.style.color)y=H.style.color;if(!C&&H.style.backgroundColor)C=H.style.backgroundColor}return false});if(r=d.get("fontselect"))r.select(function(H){return H.replace(/^([^,]+).*/,"$1").toLowerCase()==x});if(r=d.get("fontsizeselect")){if(t.theme_advanced_runtime_fontsize&&!v&&!u)v=f.dom.getStyle(j,"fontSize",true);r.select(function(H){if(H.fontSize&&
H.fontSize===v)return true;if(H["class"]&&H["class"]===u)return true})}if(t.theme_advanced_show_current_color){j=function(H,M){if(r=d.get(H)){if(!M)M=r.settings.default_color;M!==r.value&&r.displayColor(M)}};j("forecolor",y);j("backcolor",C)}if(t.theme_advanced_show_current_color){j=function(H,M){if(r=d.get(H)){if(!M)M=r.settings.default_color;M!==r.value&&r.displayColor(M)}};j("forecolor",y);j("backcolor",C)}if(t.theme_advanced_path&&t.theme_advanced_statusbar_location){s=p.get(f.id+"_path")||p.add(f.id+
"_path_row","span",{id:f.id+"_path"});if(l.statusKeyboardNavigation){l.statusKeyboardNavigation.destroy();l.statusKeyboardNavigation=null}p.setHTML(s,"");c(function(H){var M=H.nodeName.toLowerCase(),P="";if(!(H.nodeType!=1||M==="br"||H.getAttribute("data-mce-bogus")||p.hasClass(H,"mceItemHidden")||p.hasClass(H,"mceItemRemoved"))){if(n.isIE&&H.scopeName!=="HTML")M=H.scopeName+":"+M;M=M.replace(/mce\:/g,"");switch(M){case "b":M="strong";break;case "i":M="em";break;case "img":if(m=p.getAttrib(H,"src"))P+=
"src: "+m+" ";break;case "a":if(m=p.getAttrib(H,"name")){P+="name: "+m+" ";M+="#"+m}if(m=p.getAttrib(H,"href"))P+="href: "+m+" ";break;case "font":if(m=p.getAttrib(H,"face"))P+="font: "+m+" ";if(m=p.getAttrib(H,"size"))P+="size: "+m+" ";if(m=p.getAttrib(H,"color"))P+="color: "+m+" ";break;case "span":if(m=p.getAttrib(H,"style"))P+="style: "+m+" ";break}if(m=p.getAttrib(H,"id"))P+="id: "+m+" ";if(m=H.className)if(m=m.replace(/\b\s*(webkit|mce|Apple-)\w+\s*\b/g,"")){P+="class: "+m+" ";if(p.isBlock(H)||
M=="img"||M=="span")M+="."+m}M=M.replace(/(html:)/g,"");M={name:M,node:H,title:P};l.onResolveName.dispatch(l,M);P=M.title;M=M.name;H=p.create("a",{href:"javascript:;",role:"button",onmousedown:"return false;",title:P,"class":"mcePath_"+i++},M);if(s.hasChildNodes()){s.insertBefore(p.create("span",{"aria-hidden":"true"},"\u00a0\u00bb "),s.firstChild);s.insertBefore(H,s.firstChild)}else s.appendChild(H)}},f.getBody());if(p.select("a",s).length>0)l.statusKeyboardNavigation=new n.ui.KeyboardNavigation({root:f.id+
"_path_row",items:p.select("a",s),excludeFromTabOrder:true,onCancel:function(){f.focus()}},p)}},_sel:function(f){this.editor.execCommand("mceSelectNodeDepth",false,f)},_mceInsertAnchor:function(){var f=this.editor;f.windowManager.open({url:this.url+"/anchor.htm",width:320+parseInt(f.getLang("advanced.anchor_delta_width",0)),height:90+parseInt(f.getLang("advanced.anchor_delta_height",0)),inline:true},{theme_url:this.url})},_mceCharMap:function(){var f=this.editor;f.windowManager.open({url:this.url+
"/charmap.htm",width:550+parseInt(f.getLang("advanced.charmap_delta_width",0)),height:260+parseInt(f.getLang("advanced.charmap_delta_height",0)),inline:true},{theme_url:this.url})},_mceHelp:function(){this.editor.windowManager.open({url:this.url+"/about.htm",width:480,height:380,inline:true},{theme_url:this.url})},_mceShortcuts:function(){this.editor.windowManager.open({url:this.url+"/shortcuts.htm",width:480,height:380,inline:true},{theme_url:this.url})},_mceColorPicker:function(f,d){f=this.editor;
d=d||{};f.windowManager.open({url:this.url+"/color_picker.htm",width:375+parseInt(f.getLang("advanced.colorpicker_delta_width",0)),height:250+parseInt(f.getLang("advanced.colorpicker_delta_height",0)),close_previous:false,inline:true},{input_color:d.color,func:d.func,theme_url:this.url})},_mceCodeEditor:function(){var f=this.editor;f.windowManager.open({url:this.url+"/source_editor.htm",width:parseInt(f.getParam("theme_advanced_source_editor_width",720)),height:parseInt(f.getParam("theme_advanced_source_editor_height",
580)),inline:true,resizable:true,maximizable:true},{theme_url:this.url})},_mceImage:function(){var f=this.editor;f.dom.getAttrib(f.selection.getNode(),"class").indexOf("mceItem")==-1&&f.windowManager.open({url:this.url+"/image.htm",width:355+parseInt(f.getLang("advanced.image_delta_width",0)),height:275+parseInt(f.getLang("advanced.image_delta_height",0)),inline:true},{theme_url:this.url})},_mceLink:function(){var f=this.editor;f.windowManager.open({url:this.url+"/link.htm",width:410+parseInt(f.getLang("advanced.link_delta_width",
0)),height:200+parseInt(f.getLang("advanced.link_delta_height",0)),inline:true},{theme_url:this.url})},_mceNewDocument:function(){var f=this.editor;f.windowManager.confirm("advanced.newdocument",function(d){d&&f.execCommand("mceSetContent",false,"")})},_mceForeColor:function(){var f=this;this._mceColorPicker(0,{color:f.fgColor,func:function(d){f.fgColor=d;f.editor.execCommand("ForeColor",false,d)}})},_mceBackColor:function(){var f=this;this._mceColorPicker(0,{color:f.bgColor,func:function(d){f.bgColor=
d;f.editor.execCommand("HiliteColor",false,d)}})},_ufirst:function(f){return f.substring(0,1).toUpperCase()+f.substring(1)}});n.ThemeManager.add("advanced",n.themes.AdvancedTheme)})(tinymce);
(function(){tinymce.PluginManager.requireLangPack("bligooimages");tinymce.create("tinymce.plugins.BligooImagesPlugin",{init:function(n,p){n.addCommand("mceBligooImages",function(){this.helper=new ImageUploadHelper(n)});n.addButton("bligooimages",{title:"bligooimages.desc",cmd:"mceBligooImages",image:p+"/img/bligooimages.gif"});n.onNodeChange.add(function(o,q,e){o.editorId=="content-blidget"&&q.setActive("bligooimages",e.nodeName=="IMG"&&o.dom.hasClass(e,"mceBligooImages"))});n.onEvent.add(function(o,
q){var e=q.target;if(this.imageEdit!=null){this.imageEdit.remove();this.imageEdit=null}if(e.nodeName=="IMG"&&!o.dom.hasClass(e,"mceExternalCode")&&!o.dom.hasClass(e,"mceYouTube")&&!o.dom.hasClass(e,"mceVimeo")&&!o.dom.hasClass(e,"mceFlash")&&o.editorId!="content-blidget"){var a=function(){this.helper=new ImageUploadHelper(o)}.bind(this);o.selection.select(e);this.imageEdit=new TinyMCEEditArea(o,e,a,q,{edit:o.getLang("bligooimages.edit"),remove:o.getLang("bligooimages.remove"),remmain:o.getLang("bligooimages.remmain"),
setmain:o.getLang("bligooimages.setmain")})}});n.onPostProcess.add(function(){});n.onBeforeSetContent.add(function(){})},createControl:function(){return null},getInfo:function(){return{longname:"BligooImages plugin",author:"BlueCompany",authorurl:"http://bluecompany.cl",version:"1.0"}}});tinymce.PluginManager.add("bligooimages",tinymce.plugins.BligooImagesPlugin)})();
(function(){tinymce.PluginManager.requireLangPack("externalcode");tinymce.create("tinymce.plugins.ExternalCodePlugin",{init:function(n,p){var o={_keyStr:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",encode:function(q){var e="",a,g,h,f,d,j,k=0;for(q=o._utf8_encode(q);k<q.length;){a=q.charCodeAt(k++);g=q.charCodeAt(k++);h=q.charCodeAt(k++);f=a>>2;a=(a&3)<<4|g>>4;d=(g&15)<<2|h>>6;j=h&63;if(isNaN(g))d=j=64;else if(isNaN(h))j=64;e=e+this._keyStr.charAt(f)+this._keyStr.charAt(a)+this._keyStr.charAt(d)+
this._keyStr.charAt(j)}return e},decode:function(q){var e="",a,g,h,f,d,j=0;for(q=q.replace(/[^A-Za-z0-9\+\/\=]/g,"");j<q.length;){a=this._keyStr.indexOf(q.charAt(j++));g=this._keyStr.indexOf(q.charAt(j++));f=this._keyStr.indexOf(q.charAt(j++));d=this._keyStr.indexOf(q.charAt(j++));a=a<<2|g>>4;g=(g&15)<<4|f>>2;h=(f&3)<<6|d;e+=String.fromCharCode(a);if(f!=64)e+=String.fromCharCode(g);if(d!=64)e+=String.fromCharCode(h)}return e=o._utf8_decode(e)},_utf8_encode:function(q){q=q.replace(/\r\n/g,"\n");for(var e=
"",a=0;a<q.length;a++){var g=q.charCodeAt(a);if(g<128)e+=String.fromCharCode(g);else{if(g>127&&g<2048)e+=String.fromCharCode(g>>6|192);else{e+=String.fromCharCode(g>>12|224);e+=String.fromCharCode(g>>6&63|128)}e+=String.fromCharCode(g&63|128)}}return e},_utf8_decode:function(q){for(var e="",a=0,g=c1=c2=0;a<q.length;){g=q.charCodeAt(a);if(g<128){e+=String.fromCharCode(g);a++}else if(g>191&&g<224){c2=q.charCodeAt(a+1);e+=String.fromCharCode((g&31)<<6|c2&63);a+=2}else{c2=q.charCodeAt(a+1);c3=q.charCodeAt(a+
2);e+=String.fromCharCode((g&15)<<12|(c2&63)<<6|c3&63);a+=3}}return e}};n.onInit.add(function(){n.settings.content_css!==false&&n.dom.loadCSS(p+"/css/content.css")});n.addCommand("mceExternalCode",function(){n.windowManager.open({file:p+"/dialog.htm",width:470+parseInt(n.getLang("externalcode.delta_width",0)),height:320+parseInt(n.getLang("externalcode.delta_height",0)),inline:1},{plugin_url:p,base64:o,cls:"mceExternalCode"})});n.addButton("externalcode",{title:"externalcode.desc",cmd:"mceExternalCode",
image:p+"/img/externalcode.gif"});n.onNodeChange.add(function(q,e,a){e.setActive("externalcode",a.nodeName=="IMG"&&q.dom.hasClass(a,"mceExternalCode"))});n.onEvent.add(function(q,e){var a=e.target;if(this.extCodeEdit!=null){this.extCodeEdit.remove();this.extCodeEdit=null}if(a.nodeName=="IMG"&&q.dom.hasClass(a,"mceExternalCode")){var g=function(){new ExternalCodePlugin(q,a,null)}.bind(this);this.extCodeEdit=new TinyMCEEditArea(q,a,g,e,{edit:q.getLang("externalcode.edit"),remove:q.getLang("externalcode.remove")})}});
n.onPostProcess.add(function(q,e){function a(g,h){return(h=(new RegExp(h+'="([^"]+)"',"g")).exec(g))?q.dom.decode(h[1]):""}if(e.get)e.content=e.content.replace(/<img[^>]+class="[^"]*mceExternalCode[^"]*"[^>]*>/gi,function(g){return"<!--external_code_start--\>"+o.decode(a(g,"title"))+"<!--external_code_end--\>"})});n.onBeforeSetContent.add(function(q,e){if(e.content!=""){for(var a="",g=e.content,h,f,d;(h=g.indexOf("<!--external_code_start--\>"))>=0;){f=g.indexOf("<!--external_code_end--\>",h);d=g.substring(0,
h);h=g.substring(h+26,f);g=g.substring(f+24);h=o.encode(h);h='<img src="'+p+'/img/spacer.gif" mce_src="'+p+'/img/spacer.gif" border="0"  title="'+h+'" class="mceExternalCode mceExternalCode-'+q.getParam("language","es")+' mceItemNoResize" />';a+=d+h;g=g}a+=g;e.content=a}})},createControl:function(){return null},getInfo:function(){return{longname:"ExternalCode plugin",author:"BlueCompany",authorurl:"http://bluecompany.cl",version:"1.0"}}});tinymce.PluginManager.add("externalcode",tinymce.plugins.ExternalCodePlugin)})();
(function(){tinymce.PluginManager.requireLangPack("youtube");tinymce.create("tinymce.plugins.YouTubePlugin",{init:function(n,p){n.addCommand("mceYouTube",function(){n.windowManager.open({file:p+"/dialog.htm",width:380,height:150,inline:1},{plugin_url:p,cls:"mceYouTube"})});n.addButton("youtube",{title:"youtube.desc",cmd:"mceYouTube",image:p+"/img/youtube.gif"});n.onNodeChange.add(function(o,q,e){q.setActive("youtube",e.nodeName=="IMG"&&o.dom.hasClass(e,"mceYouTube"))});n.onEvent.add(function(o,q){var e=
q.target;if(this.youtubeEdit!=null){this.youtubeEdit.remove();this.youtubeEdit=null}if(e.nodeName=="IMG"&&o.dom.hasClass(e,"mceYouTube")){var a=function(){new VideoPlugin(o,e,null)}.bind(this);this.youtubeEdit=new TinyMCEEditArea(o,e,a,q,{edit:o.getLang("youtube.edit"),remove:o.getLang("youtube.remove")})}});n.onPostProcess.add(function(o,q){function e(a,g){return(g=(new RegExp(g+'="([^"]+)"',"g")).exec(a))?o.dom.decode(g[1]):""}if(q.get)q.content=q.content.replace(/<img[^>]+>/g,function(a){if(a.indexOf('class="mceYouTube')!==
-1){var g=e(a,"width"),h=e(a,"height");return html='<object width="'+g+'" height="'+h+'"><param name="movie" value="http://www.youtube.com/v/'+e(a,"alt")+'&fs=1"></param><param name="allowFullScreen" value="true"></param><param name="wmode" value="transparent"></param><embed src="http://www.youtube.com/v/'+e(a,"alt")+'&fs=1" wmode="transparent" allowfullscreen="true" type="application/x-shockwave-flash" width="'+g+'" height="'+h+'"></embed></object>'}return a})});n.onBeforeSetContent.add(function(o,
q){function e(k){var b="",c="",l,s,i=[],m=new RegExp("^[ \n\r\t]+","g");if(k==null||k.length<2)return null;l=s=false;for(var r=0;r<k.length;r++){var t=k.charAt(r);if((t=='"'||t=="'")&&!s)s=true;else if((t=='"'||t=="'")&&s){s=false;var u=b.lastIndexOf(" ");if(u!=-1)b=b.substring(u+1);i[b.toLowerCase()]=c.substring(1);c=b=""}else if(!m.test(t)&&!l&&!s)l=true;if(t=="="&&l)l=false;if(l)b+=t;if(s)c+=t}return i}o=q.content;var a=-1,g=[];o=o.replace(new RegExp("<[ ]*embed","gi"),"<embed");o=o.replace(new RegExp("<[ ]*object",
"gi"),"<object");for(o=o.replace(new RegExp("<[ ]*/object[ ]*>","gi"),"</object>");(a=o.indexOf("<embed",a+1))!=-1;){var h=o.indexOf(">",a),f=e(o.substring(a+6,h));if(o.substring(a+6,h).indexOf("http://www.youtube.com/v/")!=-1)g[g.length]=f}var d=0;for(a=-1;(a=o.indexOf("<object",a))!=-1;){if(d>=g.length)break;f=g[d];h=o.indexOf("</object>",a);if(o.substring(a+7,h).indexOf("http://www.youtube.com/v/")!=-1){h+=9;var j=o.substring(h);f.src=f.src.replace(new RegExp("http://www.youtube.com/v/","gi"),
"");o=o.substring(0,a);o+='<img width="'+f.width+'" height="'+f.height+'"';o+=' src="'+p+'/img/youtube.jpg" title="'+f.src+'"';o+=' alt="'+f.src+'" class="mceYouTube mceItem" />'+o.substring(h);o+=j;d++}a++}a=-1;for(d=0;(a=o.indexOf("<embed",a))!=-1;){if(d>=g.length)break;f=g[d];h=o.indexOf(">",a+8);if(o.substring(a+7,h).indexOf("http://www.youtube.com/v/")!=-1){h+=9;j=o.substring(h);f.src=f.src.replace(new RegExp("http://www.youtube.com/v/","gi"),"");o=o.substring(0,a);o+=' src="'+p+'/img/youtube.jpg" title="'+
f.src+'"';o+=' alt="'+f.src+'" class="mceYouTube mceItem" />'+o.substring(h);o+=j;d++}a++}q.content=o})},createControl:function(){return null},getInfo:function(){return{longname:"YouTube plugin",author:"BlueCompany",authorurl:"http://bluecompany.cl",version:"1.0"}}});tinymce.PluginManager.add("youtube",tinymce.plugins.YouTubePlugin)})();
(function(){tinymce.PluginManager.requireLangPack("vimeo");tinymce.create("tinymce.plugins.VimeoPlugin",{init:function(n,p){n.addCommand("mceVimeo",function(){n.windowManager.open({file:p+"/dialog.htm",width:380,height:150,inline:1},{plugin_url:p,cls:"mceVimeo"})});n.addButton("vimeo",{title:"vimeo.desc",cmd:"mceVimeo",image:p+"/img/vimeo.gif"});n.onNodeChange.add(function(o,q,e){q.setActive("vimeo",e.nodeName=="IMG"&&o.dom.hasClass(e,"mceVimeo"))});n.onEvent.add(function(o,q){var e=q.target;if(this.vimeoEdit!=
null){this.vimeoEdit.remove();this.vimeoEdit=null}if(e.nodeName=="IMG"&&o.dom.hasClass(e,"mceVimeo")){var a=function(){new VideoPlugin(o,e,null)}.bind(this);this.vimeoEdit=new TinyMCEEditArea(o,e,a,q,{edit:o.getLang("vimeo.edit"),remove:o.getLang("vimeo.remove")})}});n.onPostProcess.add(function(o,q){function e(a,g){return(g=(new RegExp(g+'="([^"]+)"',"g")).exec(a))?o.dom.decode(g[1]):""}if(q.get)q.content=q.content.replace(/<img[^>]+>/g,function(a){if(a.indexOf('class="mceVimeo')!==-1){var g=e(a,
"width"),h=e(a,"height");return'<object width="'+g+'" height="'+h+'"><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="wmode" value="transparent" /><param name="movie" value="http://www.vimeo.com/moogaloop.swf?clip_id='+e(a,"alt")+'&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=&amp;fullscreen=1" /><embed src="http://www.vimeo.com/moogaloop.swf?clip_id='+e(a,"alt")+'&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=&amp;fullscreen=1" type="application/x-shockwave-flash" allowfullscreen="true" allowscriptaccess="always" wmode="transparent" width="'+
g+'" height="'+h+'"></embed></object>'}return a})});n.onBeforeSetContent.add(function(o,q){function e(k){var b="",c="",l,s,i=[],m=new RegExp("^[ \n\r\t]+","g");if(k==null||k.length<2)return null;l=s=false;for(var r=0;r<k.length;r++){var t=k.charAt(r);if((t=='"'||t=="'")&&!s)s=true;else if((t=='"'||t=="'")&&s){s=false;var u=b.lastIndexOf(" ");if(u!=-1)b=b.substring(u+1);i[b.toLowerCase()]=c.substring(1);c=b=""}else if(!m.test(t)&&!l&&!s)l=true;if(t=="="&&l)l=false;if(l)b+=t;if(s)c+=t}return i}o=q.content;
var a=-1,g=[];o=o.replace(new RegExp("<[ ]*embed","gi"),"<embed");o=o.replace(new RegExp("<[ ]*object","gi"),"<object");for(o=o.replace(new RegExp("<[ ]*/object[ ]*>","gi"),"</object>");(a=o.indexOf("<embed",a+1))!=-1;){var h=o.indexOf(">",a),f=e(o.substring(a+6,h));if(o.substring(a+6,h).indexOf("http://www.vimeo.com/")!=-1)g[g.length]=f}var d=0;for(a=-1;(a=o.indexOf("<object",a))!=-1;){if(d>=g.length)break;f=g[d];h=o.indexOf("</object>",a);if(o.substring(a+7,h).indexOf("http://www.vimeo.com/")!=
-1){h+=9;var j=o.substring(h);f.src=f.src.replace(new RegExp("http://www.vimeo.com/moogaloop.swf\\?clip_id=([0-9]*).*","gi"),"$1");o=o.substring(0,a);o+='<img width="'+f.width+'" height="'+f.height+'"';o+=' src="'+p+'/img/vimeo.jpg" title="'+f.src+'"';o+=' alt="'+f.src+'" class="mceVimeo mceItem" />'+o.substring(h);o+=j;d++}a++}a=-1;for(d=0;(a=o.indexOf("<embed",a))!=-1;){if(d>=g.length)break;f=g[d];h=o.indexOf(">",a+8);if(o.substring(a+7,h).indexOf("http://www.vimeo.com/")!=-1){h+=9;j=o.substring(h);
f.src=f.src.replace(new RegExp("http://www.vimeo.com/moogaloop.swf\\?clip_id=([0-9]*).*","gi"),"$1");alert("fuente = "+f.src);o=o.substring(0,a);o+=' src="'+p+'/img/vimeo.jpg" title="'+f.src+'"';o+=' alt="'+f.src+'" class="mceVimeo mceItem" />'+o.substring(h);o+=j;d++}a++}q.content=o})},createControl:function(){return null},getInfo:function(){return{longname:"Vimeo plugin",author:"BlueCompany",authorurl:"http://bluecompany.cl",version:"1.0"}}});tinymce.PluginManager.add("vimeo",tinymce.plugins.VimeoPlugin)})();
(function(){tinymce.PluginManager.requireLangPack("fileupload");tinymce.create("tinymce.plugins.FileUploadPlugin",{init:function(n,p){n.addCommand("mceFileUpload",function(){n.windowManager.open({file:p+"/dialog.htm",width:500,height:350,inline:1},{plugin_url:p,cls:"mceFileUpload"})});n.addButton("fileupload",{title:"fileupload.desc",cmd:"mceFileUpload",image:p+"/img/fileupload.gif"})},createControl:function(){return null},getInfo:function(){return{longname:"FileUpload plugin",author:"BlueCompany",
authorurl:"http://bluecompany.cl",version:"1.0"}}});tinymce.PluginManager.add("fileupload",tinymce.plugins.FileUploadPlugin)})();
(function(){tinymce.create("tinymce.plugins.PageBreakPlugin",{init:function(n){var p='<img src="'+n.theme.url+'/img/trans.gif" class="mcePageBreak mceItemNoResize" />',o=n.getParam("pagebreak_separator","<!-- pagebreak --\>"),q;q=new RegExp(o.replace(/[\?\.\*\[\]\(\)\{\}\+\^\$\:]/g,function(e){return"\\"+e}),"g");n.addCommand("mcePageBreak",function(){n.execCommand("mceInsertContent",0,p)});n.addButton("pagebreak",{title:"pagebreak.desc",cmd:"mcePageBreak"});n.onInit.add(function(){n.theme.onResolveName&&
n.theme.onResolveName.add(function(e,a){if(a.node.nodeName=="IMG"&&n.dom.hasClass(a.node,"mcePageBreak"))a.name="pagebreak"})});n.onClick.add(function(e,a){a=a.target;a.nodeName==="IMG"&&e.dom.hasClass(a,"mcePageBreak")&&e.selection.select(a)});n.onNodeChange.add(function(e,a,g){a.setActive("pagebreak",g.nodeName==="IMG"&&e.dom.hasClass(g,"mcePageBreak"))});n.onBeforeSetContent.add(function(e,a){a.content=a.content.replace(q,p)});n.onPostProcess.add(function(e,a){if(a.get)a.content=a.content.replace(/<img[^>]+>/g,
function(g){if(g.indexOf('class="mcePageBreak')!==-1)g=o;return g})})},getInfo:function(){return{longname:"PageBreak",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/pagebreak",version:tinymce.majorVersion+"."+tinymce.minorVersion}}});tinymce.PluginManager.add("pagebreak",tinymce.plugins.PageBreakPlugin)})();
(function(){tinymce.PluginManager.requireLangPack("flash");tinymce.create("tinymce.plugins.FlashPlugin",{init:function(n,p){n.addCommand("mceFlash",function(){n.windowManager.open({file:p+"/dialog.htm",width:380,height:150,inline:1},{plugin_url:p,cls:"mceFlash"})});n.onInit.add(function(){n.settings.content_css!==false&&n.dom.loadCSS(p+"/css/content.css")});n.addButton("flash",{title:"flash.desc",cmd:"mceFlash",image:p+"/img/flash.gif"});n.onNodeChange.add(function(o,q,e){q.setActive("flash",e.nodeName==
"IMG"&&o.dom.hasClass(e,"mceFlash"))});n.onEvent.add(function(o,q){var e=q.target;if(this.flashEdit!=null){this.flashEdit.remove();this.flashEdit=null}if(e.nodeName=="IMG"&&o.dom.hasClass(e,"mceFlash")){var a=function(){new FlashUploadHelper(o,e)}.bind(this);this.flashEdit=new TinyMCEEditArea(o,e,a,q,{edit:o.getLang("flash.edit"),remove:o.getLang("flash.remove")})}});n.onPostProcess.add(function(o,q){function e(a,g){return(g=(new RegExp(g+'="([^"]+)"',"g")).exec(a))?o.dom.decode(g[1]):""}if(q.get)q.content=
q.content.replace(/<img[^>]+>/g,function(a){if(a.indexOf('class="mceFlash')!==-1){var g=e(a,"width"),h=e(a,"height");html='<object width="'+g+'" height="'+h+'">';html+='<param name="movie" value="'+e(a,"alt")+'" />';html+='<param name="wmode" value="transparent" />';html+='<embed src="'+e(a,"alt")+'" wmode="transparent" type="application/x-shockwave-flash" width="'+g+'" height="'+h+'"></object>';return html}return a})});n.onBeforeSetContent.add(function(o,q){function e(k){var b="",c="",l,s,i=[],m=
new RegExp("^[ \n\r\t]+","g");if(k==null||k.length<2)return null;l=s=false;for(var r=0;r<k.length;r++){var t=k.charAt(r);if((t=='"'||t=="'")&&!s)s=true;else if((t=='"'||t=="'")&&s){s=false;var u=b.lastIndexOf(" ");if(u!=-1)b=b.substring(u+1);i[b.toLowerCase()]=c.substring(1);c=b=""}else if(!m.test(t)&&!l&&!s)l=true;if(t=="="&&l)l=false;if(l)b+=t;if(s)c+=t}return i}o=q.content;var a=-1,g=[];o=o.replace(new RegExp("<[ ]*embed","gi"),"<embed");o=o.replace(new RegExp("<[ ]*object","gi"),"<object");for(o=
o.replace(new RegExp("<[ ]*/object[ ]*>","gi"),"</object>");(a=o.indexOf("<embed",a+1))!=-1;){var h=o.indexOf(">",a),f=e(o.substring(a+6,h));if(o.substring(a+6,h).indexOf("http://video.google.com/googleplayer.swf?docId=")<0&&o.substring(a+6,h).indexOf("http://www.youtube.com/v/")<0)g[g.length]=f}var d=0;for(a=-1;(a=o.indexOf("<object",a))!=-1;){h=o.indexOf(">",a);if(d>=g.length)break;f=g[d];h=o.indexOf("</object>",a);if(o.substring(a+7,h).indexOf("http://video.google.com/googleplayer.swf?docId=")<
0&&o.substring(a+7,h).indexOf("http://www.youtube.com/v/")<0){h+=9;var j=o.substring(h);o=o.substring(0,a);o+='<img width="'+f.width+'" height="'+f.height+'"';o+=' src="'+p+'/img/trans.gif" title="'+f.src+'"';o+=' alt="'+f.src+'" class="mceFlash mceItem" />'+o.substring(h);o+=j;d++}a++}a=-1;for(d=0;(a=o.indexOf("<embed",a))!=-1;){h=o.indexOf(">",a);if(d>=g.length)break;f=g[d];h=o.indexOf(">",a+8);if(o.substring(a+7,h).indexOf("http://video.google.com/googleplayer.swf?docId=")<0&&o.substring(a+7,h).indexOf("http://www.youtube.com/v/")<
0){h+=9;j=o.substring(h);o=o.substring(0,a);o+=' src="'+p+'/img/trans.gif" title="'+f.src+'"';o+=' alt="'+f.src+'" class="mceFlash mceItem" />'+o.substring(h);o+=j;d++}a++}q.content=o})},createControl:function(){return null},getInfo:function(){return{longname:"Flash plugin",author:"BlueCompany",authorurl:"http://bluecompany.cl",version:"1.0"}}});tinymce.PluginManager.add("flash",tinymce.plugins.FlashPlugin)})();
(function(){function n(q,e){return q.getParam(e,o[e])}var p=tinymce.each,o={paste_auto_cleanup_on_paste:true,paste_enable_default_filters:true,paste_block_drop:false,paste_retain_style_properties:"none",paste_strip_class_attributes:"mso",paste_remove_spans:false,paste_remove_styles:false,paste_remove_styles_if_webkit:true,paste_convert_middot_lists:true,paste_convert_headers_to_strong:false,paste_dialog_width:"450",paste_dialog_height:"400",paste_text_use_dialog:false,paste_text_sticky:false,paste_text_sticky_default:false,
paste_text_notifyalways:false,paste_text_linebreaktype:"combined",paste_text_replacements:[[/\u2026/g,"..."],[/[\x93\x94\u201c\u201d]/g,'"'],[/[\x60\x91\x92\u2018\u2019]/g,"'"]]};tinymce.create("tinymce.plugins.PastePlugin",{init:function(q,e){function a(f,d){var j=q.dom,k;h.onPreProcess.dispatch(h,f);f.node=j.create("div",0,f.content);if(tinymce.isGecko){k=q.selection.getRng(true);k.startContainer==k.endContainer&&k.startContainer.nodeType==3&&f.node.childNodes.length===1&&/^(p|h[1-6]|pre)$/i.test(f.node.firstChild.nodeName)&&
f.content.indexOf("__MCE_ITEM__")===-1&&j.remove(f.node.firstChild,true)}h.onPostProcess.dispatch(h,f);f.content=q.serializer.serialize(f.node,{getInner:1,forced_root_block:""});if(!d&&q.pasteAsPlainText){h._insertPlainText(f.content);if(!n(q,"paste_text_sticky")){q.pasteAsPlainText=false;q.controlManager.setActive("pastetext",false)}}else h._insert(f.content)}function g(f){var d,j,k,b,c=q.selection,l=q.dom;k=q.getBody();var s;if(f.clipboardData||l.doc.dataTransfer){s=(f.clipboardData||l.doc.dataTransfer).getData("Text");
if(q.pasteAsPlainText){f.preventDefault();a({content:l.encode(s).replace(/\r?\n/g,"<br />")});return}}if(!l.get("_mcePaste")){d=l.add(k,"div",{id:"_mcePaste","class":"mcePaste","data-mce-bogus":"1"},"\ufeff\ufeff");k=k!=q.getDoc().body?l.getPos(q.selection.getStart(),k).y:k.scrollTop+l.getViewPort(q.getWin()).y;l.setStyles(d,{position:"absolute",left:tinymce.isGecko?-40:0,top:k-25,width:1,height:1,overflow:"hidden"});if(tinymce.isIE){b=c.getRng();k=l.doc.body.createTextRange();k.moveToElementText(d);
k.execCommand("Paste");l.remove(d);if(d.innerHTML==="\ufeff\ufeff"){q.execCommand("mcePasteWord");f.preventDefault()}else{c.setRng(b);c.setContent("");setTimeout(function(){a({content:d.innerHTML})},0);return tinymce.dom.Event.cancel(f)}}else{var i=function(m){m.preventDefault()};l.bind(q.getDoc(),"mousedown",i);l.bind(q.getDoc(),"keydown",i);j=q.selection.getRng();d=d.firstChild;k=q.getDoc().createRange();k.setStart(d,0);k.setEnd(d,2);c.setRng(k);window.setTimeout(function(){var m="",r;if(l.select("div.mcePaste > div.mcePaste").length)m=
"<p>"+l.encode(s).replace(/\r?\n\r?\n/g,"</p><p>").replace(/\r?\n/g,"<br />")+"</p>";else{r=l.select("div.mcePaste");p(r,function(t){var u=t.firstChild;u&&u.nodeName=="DIV"&&u.style.marginTop&&u.style.backgroundColor&&l.remove(u,1);p(l.select("span.Apple-style-span",t),function(v){l.remove(v,1)});p(l.select("br[data-mce-bogus]",t),function(v){l.remove(v)});if(t.parentNode.className!="mcePaste")m+=t.innerHTML})}p(l.select("div.mcePaste"),function(t){l.remove(t)});j&&c.setRng(j);a({content:m});l.unbind(q.getDoc(),
"mousedown",i);l.unbind(q.getDoc(),"keydown",i)},0)}}}var h=this;h.editor=q;h.url=e;h.onPreProcess=new tinymce.util.Dispatcher(h);h.onPostProcess=new tinymce.util.Dispatcher(h);h.onPreProcess.add(h._preProcess);h.onPostProcess.add(h._postProcess);h.onPreProcess.add(function(f,d){q.execCallback("paste_preprocess",f,d)});h.onPostProcess.add(function(f,d){q.execCallback("paste_postprocess",f,d)});q.onKeyDown.addToTop(function(f,d){if((tinymce.isMac?d.metaKey:d.ctrlKey)&&d.keyCode==86||d.shiftKey&&d.keyCode==
45)return false});q.pasteAsPlainText=n(q,"paste_text_sticky_default");q.addCommand("mceInsertClipboardContent",function(f,d){a(d,true)});n(q,"paste_text_use_dialog")||q.addCommand("mcePasteText",function(){var f=tinymce.util.Cookie;q.pasteAsPlainText=!q.pasteAsPlainText;q.controlManager.setActive("pastetext",q.pasteAsPlainText);if(q.pasteAsPlainText&&!f.get("tinymcePasteText")){n(q,"paste_text_sticky")?q.windowManager.alert(q.translate("paste.plaintext_mode_sticky")):q.windowManager.alert(q.translate("paste.plaintext_mode"));
n(q,"paste_text_notifyalways")||f.set("tinymcePasteText","1",new Date((new Date).getFullYear()+1,12,31))}});q.addButton("pastetext",{title:"paste.paste_text_desc",cmd:"mcePasteText"});q.addButton("selectall",{title:"paste.selectall_desc",cmd:"selectall"});if(n(q,"paste_auto_cleanup_on_paste"))tinymce.isOpera||/Firefox\/2/.test(navigator.userAgent)?q.onKeyDown.addToTop(function(f,d){if((tinymce.isMac?d.metaKey:d.ctrlKey)&&d.keyCode==86||d.shiftKey&&d.keyCode==45)g(d)}):q.onPaste.addToTop(function(f,
d){return g(d)});q.onInit.add(function(){q.controlManager.setActive("pastetext",q.pasteAsPlainText);n(q,"paste_block_drop")&&q.dom.bind(q.getBody(),["dragend","dragover","draggesture","dragdrop","drop","drag"],function(f){f.preventDefault();f.stopPropagation();return false})});h._legacySupport()},getInfo:function(){return{longname:"Paste text/word",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/paste",version:tinymce.majorVersion+
"."+tinymce.minorVersion}},_preProcess:function(q,e){function a(b){p(b,function(c){g=c.constructor==RegExp?g.replace(c,""):g.replace(c[0],c[1])})}q=this.editor;var g=e.content,h=tinymce.grep,f=tinymce.explode,d=tinymce.trim,j,k;if(q.settings.paste_enable_default_filters!=false){if(tinymce.isIE&&document.documentMode>=9){a([[/(?:<br>&nbsp;[\s\r\n]+|<br>)*(<\/?(h[1-6r]|p|div|address|pre|form|table|tbody|thead|tfoot|th|tr|td|li|ol|ul|caption|blockquote|center|dl|dt|dd|dir|fieldset)[^>]*>)(?:<br>&nbsp;[\s\r\n]+|<br>)*/g,
"$1"]]);a([[/<br><br>/g,"<BR><BR>"],[/<br>/g," "],[/<BR><BR>/g,"<br>"]])}if(/class="?Mso|style="[^"]*\bmso-|w:WordDocument/i.test(g)||e.wordContent){e.wordContent=true;a([/^\s*(&nbsp;)+/gi,/(&nbsp;|<br[^>]*>)+\s*$/gi]);if(n(q,"paste_convert_headers_to_strong"))g=g.replace(/<p [^>]*class="?MsoHeading"?[^>]*>(.*?)<\/p>/gi,"<p><strong>$1</strong></p>");n(q,"paste_convert_middot_lists")&&a([[/<!--\[if !supportLists\]--\>/gi,"$&__MCE_ITEM__"],[/(<span[^>]+(?:mso-list:|:\s*symbol)[^>]+>)/gi,"$1__MCE_ITEM__"],
[/(<p[^>]+(?:MsoListParagraph)[^>]+>)/gi,"$1__MCE_ITEM__"]]);a([/<!--[\s\S]+?--\>/gi,/<(!|script[^>]*>.*?<\/script(?=[>\s])|\/?(\?xml(:\w+)?|img|meta|link|style|\w:\w+)(?=[\s\/>]))[^>]*>/gi,[/<(\/?)s>/gi,"<$1strike>"],[/&nbsp;/gi,"\u00a0"]]);do{j=g.length;g=g.replace(/(<[a-z][^>]*\s)(?:id|name|language|type|on\w+|\w+:\w+)=(?:"[^"]*"|\w+)\s?/gi,"$1")}while(j!=g.length);if(n(q,"paste_retain_style_properties").replace(/^none$/i,"").length==0)g=g.replace(/<\/?span[^>]*>/gi,"");else a([[/<span\s+style\s*=\s*"\s*mso-spacerun\s*:\s*yes\s*;?\s*"\s*>([\s\u00a0]*)<\/span>/gi,
function(b,c){return c.length>0?c.replace(/./," ").slice(Math.floor(c.length/2)).split("").join("\u00a0"):""}],[/(<[a-z][^>]*)\sstyle="([^"]*)"/gi,function(b,c,l){var s=[],i=0;b=f(d(l).replace(/&quot;/gi,"'"),";");p(b,function(m){function r(v){return v+(v!=="0"&&/\d$/.test(v))?"px":""}var t,u=f(m,":");if(u.length==2){m=u[0].toLowerCase();t=u[1].toLowerCase();switch(m){case "mso-padding-alt":case "mso-padding-top-alt":case "mso-padding-right-alt":case "mso-padding-bottom-alt":case "mso-padding-left-alt":case "mso-margin-alt":case "mso-margin-top-alt":case "mso-margin-right-alt":case "mso-margin-bottom-alt":case "mso-margin-left-alt":case "mso-table-layout-alt":case "mso-height":case "mso-width":case "mso-vertical-align-alt":s[i++]=
m.replace(/^mso-|-alt$/g,"")+":"+r(t);return;case "horiz-align":s[i++]="text-align:"+t;return;case "vert-align":s[i++]="vertical-align:"+t;return;case "font-color":case "mso-foreground":s[i++]="color:"+t;return;case "mso-background":case "mso-highlight":s[i++]="background:"+t;return;case "mso-default-height":s[i++]="min-height:"+r(t);return;case "mso-default-width":s[i++]="min-width:"+r(t);return;case "mso-padding-between-alt":s[i++]="border-collapse:separate;border-spacing:"+r(t);return;case "text-line-through":if(t==
"single"||t=="double")s[i++]="text-decoration:line-through";return;case "mso-zero-height":if(t=="yes")s[i++]="display:none";return}/^(mso|column|font-emph|lang|layout|line-break|list-image|nav|panose|punct|row|ruby|sep|size|src|tab-|table-border|text-(?!align|decor|indent|trans)|top-bar|version|vnd|word-break)/.test(m)||(s[i++]=m+":"+u[1])}});return i>0?c+' style="'+s.join(";")+'"':c}]])}n(q,"paste_convert_headers_to_strong")&&a([[/<h[1-6][^>]*>/gi,"<p><strong>"],[/<\/h[1-6][^>]*>/gi,"</strong></p>"]]);
a([[/Version:[\d.]+\nStartHTML:\d+\nEndHTML:\d+\nStartFragment:\d+\nEndFragment:\d+/gi,""]]);k=n(q,"paste_strip_class_attributes");if(k!=="none"){j=function(b,c){if(k==="all")return"";b=h(f(c.replace(/^(["'])(.*)\1$/,"$2")," "),function(l){return/^(?!mso)/i.test(l)});return b.length?' class="'+b.join(" ")+'"':""};g=g.replace(/ class="([^"]+)"/gi,j);g=g.replace(/ class=([\-\w]+)/gi,j)}if(n(q,"paste_remove_spans"))g=g.replace(/<\/?span[^>]*>/gi,"");e.content=g}},_postProcess:function(q,e){var a=this.editor,
g=a.dom,h;if(a.settings.paste_enable_default_filters!=false){if(e.wordContent){p(g.select("a",e.node),function(f){if(!f.href||f.href.indexOf("#_Toc")!=-1)g.remove(f,1)});n(a,"paste_convert_middot_lists")&&this._convertLists(q,e);h=n(a,"paste_retain_style_properties");if(tinymce.is(h,"string")&&h!=="all"&&h!=="*"){h=tinymce.explode(h.replace(/^none$/i,""));p(g.select("*",e.node),function(f){var d={},j=0,k,b,c;if(h)for(k=0;k<h.length;k++){b=h[k];if(c=g.getStyle(f,b)){d[b]=c;j++}}g.setAttrib(f,"style",
"");if(h&&j>0)g.setStyles(f,d);else f.nodeName=="SPAN"&&!f.className&&g.remove(f,true)})}}if(n(a,"paste_remove_styles")||n(a,"paste_remove_styles_if_webkit")&&tinymce.isWebKit)p(g.select("*[style]",e.node),function(f){f.removeAttribute("style");f.removeAttribute("data-mce-style")});else tinymce.isWebKit&&p(g.select("*",e.node),function(f){f.removeAttribute("data-mce-style")})}},_convertLists:function(q,e){var a=q.editor.dom,g,h,f=-1,d,j=[],k;p(a.select("p",e.node),function(b){var c,l="",s;for(c=b.firstChild;c&&
c.nodeType==3;c=c.nextSibling)l+=c.nodeValue;l=b.innerHTML.replace(/<\/?\w+[^>]*>/gi,"").replace(/&nbsp;/g,"\u00a0");if(/^(__MCE_ITEM__)+[\u2022\u00b7\u00a7\u00d8o\u25CF]\s*\u00a0*/.test(l))s="ul";if(/^__MCE_ITEM__\s*\w+\.\s*\u00a0+/.test(l))s="ol";if(s){d=parseFloat(b.style.marginLeft||0);d>f&&j.push(d);if(!g||s!=k){g=a.create(s);a.insertAfter(g,b)}else if(d>f)g=h.appendChild(a.create(s));else if(d<f){c=tinymce.inArray(j,d);l=a.getParents(g.parentNode,s);g=l[l.length-1-c]||g}p(a.select("span",b),
function(i){var m=i.innerHTML.replace(/<\/?\w+[^>]*>/gi,"");if(s=="ul"&&/^__MCE_ITEM__[\u2022\u00b7\u00a7\u00d8o\u25CF]/.test(m))a.remove(i);else/^__MCE_ITEM__[\s\S]*\w+\.(&nbsp;|\u00a0)*\s*/.test(m)&&a.remove(i)});c=b.innerHTML;c=s=="ul"?b.innerHTML.replace(/__MCE_ITEM__/g,"").replace(/^[\u2022\u00b7\u00a7\u00d8o\u25CF]\s*(&nbsp;|\u00a0)+\s*/,""):b.innerHTML.replace(/__MCE_ITEM__/g,"").replace(/^\s*\w+\.(&nbsp;|\u00a0)+\s*/,"");h=g.appendChild(a.create("li",0,c));a.remove(b);f=d;k=s}else g=f=0});
q=e.node.innerHTML;if(q.indexOf("__MCE_ITEM__")!=-1)e.node.innerHTML=q.replace(/__MCE_ITEM__/g,"")},_insert:function(q,e){var a=this.editor,g=a.selection.getRng();!a.selection.isCollapsed()&&g.startContainer!=g.endContainer&&a.getDoc().execCommand("Delete",false,null);a.execCommand("mceInsertContent",false,q,{skip_undo:e})},_insertPlainText:function(q){function e(d){p(d,function(j){q=j.constructor==RegExp?q.replace(j,""):q.replace(j[0],j[1])})}var a=this.editor,g=n(a,"paste_text_linebreaktype"),h=
n(a,"paste_text_replacements"),f=tinymce.is;if(typeof q==="string"&&q.length>0){/<(?:p|br|h[1-6]|ul|ol|dl|table|t[rdh]|div|blockquote|fieldset|pre|address|center)[^>]*>/i.test(q)?e([/[\n\r]+/g]):e([/\r+/g]);e([[/<\/(?:p|h[1-6]|ul|ol|dl|table|div|blockquote|fieldset|pre|address|center)>/gi,"\n\n"],[/<br[^>]*>|<\/tr>/gi,"\n"],[/<\/t[dh]>\s*<t[dh][^>]*>/gi,"\t"],/<[a-z!\/?][^>]*>/gi,[/&nbsp;/gi," "],[/(?:(?!\n)\s)*(\n+)(?:(?!\n)\s)*/gi,"$1"],[/\n{3,}/g,"\n\n"]]);q=a.dom.decode(tinymce.html.Entities.encodeRaw(q));
if(f(h,"array"))e(h);else f(h,"string")&&e(new RegExp(h,"gi"));if(g=="none")e([[/\n+/g," "]]);else if(g=="br")e([[/\n/g,"<br />"]]);else g=="p"?e([[/\n+/g,"</p><p>"],[/^(.*<\/p>)(<p>)$/,"<p>$1"]]):e([[/\n\n/g,"</p><p>"],[/^(.*<\/p>)(<p>)$/,"<p>$1"],[/\n/g,"<br />"]]);a.execCommand("mceInsertContent",false,q)}},_legacySupport:function(){var q=this,e=q.editor;e.addCommand("mcePasteWord",function(){e.windowManager.open({file:q.url+"/pasteword.htm",width:parseInt(n(e,"paste_dialog_width")),height:parseInt(n(e,
"paste_dialog_height")),inline:1})});n(e,"paste_text_use_dialog")&&e.addCommand("mcePasteText",function(){e.windowManager.open({file:q.url+"/pastetext.htm",width:parseInt(n(e,"paste_dialog_width")),height:parseInt(n(e,"paste_dialog_height")),inline:1})});e.addButton("pasteword",{title:"paste.paste_word_desc",cmd:"mcePasteWord"})}});tinymce.PluginManager.add("paste",tinymce.plugins.PastePlugin)})();
tinyMCE.addI18n({es:{common:{more_colors:"M\u00e1s Colores...",invalid_data:"Error: Introdujo un valor no v\u00e1lido, est\u00e1n marcados en rojo.",popup_blocked:"Lo sentimos, su bloqueo de ventanas emergentes ha deshabilitado una ventana que provee funcionalidades a la aplicaci\u00f3n. Necesita deshabilitar este bloqueo en este sitio para poder utilizar todas las funciones.",clipboard_no_support:"Su navegador no soporta las funciones de cortapapeles, use los accesos por teclado.",clipboard_msg:"Copiar/Cortar/Pegar no se encuentra disponible en Mozilla y Firefox.\n \u00bfDesea obtener m\u00e1s informaci\u00f3n acerca de este tema?",
not_set:"-- Ninguno --",class_name:"Clase",browse:"Examinar",close:"Cerrar",cancel:"Cancelar",update:"Actualizar",insert:"Insertar",apply:"Applicar",edit_confirm:" \u00bfDesea utilizar el modo WYSIWYG para esta caja de texto?",invalid_data_number:"{#field} debe ser un n\u00famero",invalid_data_min:"{#field} debe ser un n\u00famero mayor que {#min}",invalid_data_size:"{#field} debe ser un n\u00famero o porcentaje",value:"(valor)"},contextmenu:{full:"Justificado",right:"Derecha",center:"Centrado",left:"Izquierda",
align:"Alineaci\u00f3n"},insertdatetime:{day_short:"Dom,Lun,Mar,Mie,Jue,Vie,Sab,Dom",day_long:"Domingo,Lunes,Martes,Mi\u00e9rcoles,Jueves,Viernes,S\u00e1bado,Domingo",months_short:"Ene,Feb,Mar,Abr,May,Jun,Jul,Ago,Sep,Oct,Nov,Dic",months_long:"Enero,Febrero,Marzo,Abril,Mayo,Junio,Julio,Agosto,Septiembre,Octubre,Noviembre,Diciembre",inserttime_desc:"Insertar hora",insertdate_desc:"Insertar fecha",time_fmt:"%H:%M:%S",date_fmt:"%d-%m-%Y"},print:{print_desc:"Imprimir"},preview:{preview_desc:"Vista previa"},
directionality:{ltr_desc:"Direcci\u00f3n izquierda a derecha",rtl_desc:"Direcci\u00f3n derecha a izquierda"},layer:{content:"Nueva capa...",absolute_desc:"Cambiar a posici\u00f3n absoluta",backward_desc:"Retroceder",forward_desc:"Avanzar",insertlayer_desc:"Insertar nueva capa"},save:{save_desc:"Guardar",cancel_desc:"Cancelar todos los cambios"},nonbreaking:{nonbreaking_desc:"Insertar caracter de espacio 'non-breaking'"},iespell:{download:"No se detect\u00f3 'ieSpell'.  \u00bfDesea instalarlo ahora?",
iespell_desc:"Corrector ortogr\u00e1fico"},advhr:{delta_height:"",delta_width:"",advhr_desc:"Insertar l\u00ednea horizontal"},emotions:{delta_height:"",delta_width:"",emotions_desc:"Emoticones"},searchreplace:{replace_desc:"Buscar/Reemplazar",delta_width:"",delta_height:"",search_desc:"Buscar"},advimage:{delta_width:"",image_desc:"Insertar/editar imagen",delta_height:""},advlink:{delta_height:"",delta_width:"",link_desc:"Insertar/editar hiperv\u00ednculo"},xhtmlxtras:{attribs_delta_height:"",attribs_delta_width:"",
ins_delta_height:"",ins_delta_width:"",del_delta_height:"",del_delta_width:"",acronym_delta_height:"",acronym_delta_width:"",abbr_delta_height:"",abbr_delta_width:"",cite_delta_height:"",cite_delta_width:"",attribs_desc:"Insertar/Editar atributos",ins_desc:"Inserci\u00f3n",del_desc:"Borrado",acronym_desc:"Acr\u00f3nimo",abbr_desc:"Abreviatura",cite_desc:"Cita"},style:{delta_height:"",delta_width:"",desc:"Editar Estilo CSS"},paste:{plaintext_mode_stick:"Pegar est\u00e1 ahora en modo texto plano. Haga click otra vez para volver al modo de pegar normal.",
plaintext_mode:"Pegar est\u00e1 ahora en modo texto plano. Haga click otra vez para volver al modo de pegar normal. Despu\u00e9s de pegar algo volver\u00e1 al modo de pegar normal.",selectall_desc:"Elegir todo",paste_word_desc:"Pegar desde Word",paste_text_desc:"Pegar como texto plano"},paste_dlg:{text_title:"Use CTRL+V en su teclado para pegar el texto en la ventana.",text_linebreaks:"Keep linebreaks",word_title:"Use CTRL+V en su teclado para pegar el texto en la ventana."},table:{merge_cells_delta_height:"",
merge_cells_delta_width:"",table_delta_height:"",table_delta_width:"",cellprops_delta_height:"",cellprops_delta_width:"",rowprops_delta_height:"",rowprops_delta_width:"",cell:"Celda",col:"Columna",row:"Fila",del:"Eliminar tabla",copy_row_desc:"Copiar fila",cut_row_desc:"Cortar fila",paste_row_after_desc:"Pegar filas (despu\u00e9s)",paste_row_before_desc:"Pegar filas (antes)",props_desc:"Propiedades de la tabla",cell_desc:"Propiedades de la celda",row_desc:"Propiedades de la fila",merge_cells_desc:"Vincular celdas",
split_cells_desc:"Dividir celdas",delete_col_desc:"Suprimir columna",col_after_desc:"Insertar columna (despu\u00e9s)",col_before_desc:"Insertar columna (antes)",delete_row_desc:"Suprimir fila",row_after_desc:"Insertar fila (despu\u00e9s)",row_before_desc:"Insertar fila (antes)",desc:"Inserta una nueva tabla"},autosave:{warning_message:"Si restaura el contenido guardado, perder\u00e1 todo el contenido que est\u00e1 actualmente en el editor.\n\nSeguro quiere restaurar el contenido guardado?",restore_content:"Restaurar el contenido guardado autom\u00e1ticamente.",
unload_msg:"Los cambios realizados se perder\u00e1n si sale de esta p\u00e1gina."},fullscreen:{desc:"Cambiar a modo Pantalla Completa"},media:{delta_height:"",delta_width:"",edit:"Editar medio embebido",desc:"Insertar/editar medio embebido"},fullpage:{desc:"Propiedades del documento",delta_width:"",delta_height:""},template:{desc:"Insertar contenido de plantilla predefinida"},visualchars:{desc:"Caracteres de control ON/OFF."},spellchecker:{desc:"Cambiar a corrector ortogr\u00e1fico",menu:"Configuraci\u00f3n de corrector ortogr\u00e1fico",
ignore_word:"Ignorar",ignore_words:"Ignorar todo",langs:"Idiomas",wait:"Espere...",sug:"Sugerencias",no_sug:"Sin sugerencias",no_mpell:"No se encontraron errores.",learn_word:"Aprender palabra"},pagebreak:{desc:"Insertar fin de p\u00e1gina"},advlist:{types:"Types",def:"Default",lower_alpha:"Lower Alpha",lower_greek:"Lower Greek",lower_roman:"Lower Roman",upper_alpha:"Upper Alpha",upper_roman:"Upper Roman",circle:"Circle",disc:"Disc",square:"Square"},colors:{"333300":"Oliva oscuro","993300":"Naranjo quemado",
"000000":"Negro","003300":"Verde oscuro","003366":"Dark azure","000080":"Azul marino","333399":"Indigo","333333":"Gris muy oscuro","800000":"Granate",FF6600:"Naranjo","808000":"Oliva","008000":"Verde","008080":"Verde azulado","0000FF":"Azul","666699":"Azul gris\u00e1ceo","808080":"Gris",FF0000:"Rojo",FF9900:"\u00c1mbar","99CC00":"Verde amarillo","339966":"Verde mar","33CCCC":"Turquesa","3366FF":"Azul rey","800080":"Morado","999999":"Azul medio",FF00FF:"Magenta",FFCC00:"Oro",FFFF00:"Amarillo","00FF00":"Lima",
"00FFFF":"Aqua","00CCFF":"Azul cielo","993366":"Caf\u00e9",C0C0C0:"Plata",FF99CC:"Rosado",FFCC99:"Damasco",FFFF99:"Amarillo claro",CCFFCC:"Verde p\u00e1lido",CCFFFF:"Cyan p\u00e1lido","99CCFF":"Azul cielo claro",CC99FF:"Ciruela",FFFFFF:"Blanco"},aria:{rich_text_area:"\u00c1rea de texto enriquecido"},wordcount:{words:"Palabras:"}}});
tinyMCE.addI18n("es.advanced",{style_select:"Estilos",font_size:"Tama\u00f1o",fontdefault:"Fuente",block:"Formato",paragraph:"P\u00e1rrafo",div:"Div",address:"Direcci\u00f3n",pre:"Preformateado",h1:"Encabezado 1",h2:"Encabezado 2",h3:"Encabezado 3",h4:"Encabezado 4",h5:"Encabezado 5",h6:"Encabezado 6",blockquote:"Cita",code:"C\u00f3digo",samp:"Ejemplo de c\u00f3digo",dt:"T\u00e9rmino de definici\u00f3n",dd:"Descripci\u00f3n de definici\u00f3n",bold_desc:"Negrita (Ctrl+B)",italic_desc:"Cursiva (Ctrl+I)",
underline_desc:"Subrayado (Ctrl+U)",striketrough_desc:"Tachado",justifyleft_desc:"Alinear a la izquierda",justifycenter_desc:"Alinear al centro",justifyright_desc:"Alinear a la derecha",justifyfull_desc:"Justificar",bullist_desc:"Lista desordenada",numlist_desc:"Lista ordenada",outdent_desc:"Reducir sangr\u00eda",indent_desc:"Aumentar sangr\u00eda",undo_desc:"Deshacer (Ctrl+Z)",redo_desc:"Rehacer (Ctrl+Y)",link_desc:"Insertar/editar hiperv\u00ednculo",unlink_desc:"Quitar hiperv\u00ednculo",image_desc:"Insertar/editar imagen",
cleanup_desc:"Limpiar c\u00f3digo basura",code_desc:"Editar c\u00f3digo HTML",sub_desc:"Sub\u00edndice",sup_desc:"Super\u00edndice",hr_desc:"Insertar regla horizontal",removeformat_desc:"Limpiar formato",custom1_desc:"Su descripci\u00f3n personal aqu\u00ed",forecolor_desc:"Elegir color del texto",backcolor_desc:"Elegir color de fondo",charmap_desc:"Insertar caracteres personalizados",visualaid_desc:"Mostrar/ocultar l\u00ednea de gu\u00eda/elementos invisibles",anchor_desc:"Insertar/editar ancla",
cut_desc:"Cortar",copy_desc:"Copiar",paste_desc:"Pegar",image_props_desc:"Propiedades de imagen",newdocument_desc:"Nuevo documento",help_desc:"Ayuda",blockquote_desc:"Cita",clipboard_msg:"Copiar/Cortar/Pegar no se encuentra disponible en Mozilla y Firefox.\n \u00bfQuiere m\u00e1s informaci\u00f3n sobre este tema?",path:"Ruta",newdocument:" \u00bfSeguro que desea limpiar todo el contenido?",toolbar_focus:"Ir a los botones de herramientas - Alt+Q, Ir al editor - Alt-Z, Ir a la ruta del elemento - Alt-X",
more_colors:"M\u00e1s colores"});tinyMCE.addI18n("es.bligooimages",{desc:"Insertar imagen",edit:"Editar",remove:"Eliminar",remmain:"Desmarcar como imagen principal",setmain:"Marcar como imagen principal"});tinyMCE.addI18n("es.externalcode",{desc:"Insertar / editar c\u00f3digo",edit:"Editar",remove:"Eliminar"});tinyMCE.addI18n("es.youtube",{desc:"Insertar video YouTube",edit:"Editar",remove:"Eliminar"});tinyMCE.addI18n("es.vimeo",{desc:"Insertar video Vimeo",edit:"Editar",remove:"Eliminar"});
tinyMCE.addI18n("es.fileupload",{desc:"Subir archivo / Insertar link de archivo"});tinyMCE.addI18n("es.flash",{desc:"Insertar Flash",edit:"Editar",remove:"Eliminar"});

