From 2f01fe57a8d37767827d6db42850aef86a767c53 Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Mon, 15 Nov 2010 10:39:52 +0300 Subject: add dijit/dojo stuff; initial ui mockup --- lib/dijit/_editor/RichText.js | 1046 ++++++++++++++++++++++++ lib/dijit/_editor/_Plugin.js | 73 ++ lib/dijit/_editor/html.js | 147 ++++ lib/dijit/_editor/nls/FontChoice.js | 1 + lib/dijit/_editor/nls/LinkDialog.js | 1 + lib/dijit/_editor/nls/ar/FontChoice.js | 1 + lib/dijit/_editor/nls/ar/LinkDialog.js | 1 + lib/dijit/_editor/nls/ar/commands.js | 1 + lib/dijit/_editor/nls/ca/FontChoice.js | 1 + lib/dijit/_editor/nls/ca/LinkDialog.js | 1 + lib/dijit/_editor/nls/ca/commands.js | 1 + lib/dijit/_editor/nls/commands.js | 1 + lib/dijit/_editor/nls/cs/FontChoice.js | 1 + lib/dijit/_editor/nls/cs/LinkDialog.js | 1 + lib/dijit/_editor/nls/cs/commands.js | 1 + lib/dijit/_editor/nls/da/FontChoice.js | 1 + lib/dijit/_editor/nls/da/LinkDialog.js | 1 + lib/dijit/_editor/nls/da/commands.js | 1 + lib/dijit/_editor/nls/de/FontChoice.js | 1 + lib/dijit/_editor/nls/de/LinkDialog.js | 1 + lib/dijit/_editor/nls/de/commands.js | 1 + lib/dijit/_editor/nls/el/FontChoice.js | 1 + lib/dijit/_editor/nls/el/LinkDialog.js | 1 + lib/dijit/_editor/nls/el/commands.js | 1 + lib/dijit/_editor/nls/es/FontChoice.js | 1 + lib/dijit/_editor/nls/es/LinkDialog.js | 1 + lib/dijit/_editor/nls/es/commands.js | 1 + lib/dijit/_editor/nls/fi/FontChoice.js | 1 + lib/dijit/_editor/nls/fi/LinkDialog.js | 1 + lib/dijit/_editor/nls/fi/commands.js | 1 + lib/dijit/_editor/nls/fr/FontChoice.js | 1 + lib/dijit/_editor/nls/fr/LinkDialog.js | 1 + lib/dijit/_editor/nls/fr/commands.js | 1 + lib/dijit/_editor/nls/he/FontChoice.js | 1 + lib/dijit/_editor/nls/he/LinkDialog.js | 1 + lib/dijit/_editor/nls/he/commands.js | 1 + lib/dijit/_editor/nls/hu/FontChoice.js | 1 + lib/dijit/_editor/nls/hu/LinkDialog.js | 1 + lib/dijit/_editor/nls/hu/commands.js | 1 + lib/dijit/_editor/nls/it/FontChoice.js | 1 + lib/dijit/_editor/nls/it/LinkDialog.js | 1 + lib/dijit/_editor/nls/it/commands.js | 1 + lib/dijit/_editor/nls/ja/FontChoice.js | 1 + lib/dijit/_editor/nls/ja/LinkDialog.js | 1 + lib/dijit/_editor/nls/ja/commands.js | 1 + lib/dijit/_editor/nls/ko/FontChoice.js | 1 + lib/dijit/_editor/nls/ko/LinkDialog.js | 1 + lib/dijit/_editor/nls/ko/commands.js | 1 + lib/dijit/_editor/nls/nb/FontChoice.js | 1 + lib/dijit/_editor/nls/nb/LinkDialog.js | 1 + lib/dijit/_editor/nls/nb/commands.js | 1 + lib/dijit/_editor/nls/nl/FontChoice.js | 1 + lib/dijit/_editor/nls/nl/LinkDialog.js | 1 + lib/dijit/_editor/nls/nl/commands.js | 1 + lib/dijit/_editor/nls/pl/FontChoice.js | 1 + lib/dijit/_editor/nls/pl/LinkDialog.js | 1 + lib/dijit/_editor/nls/pl/commands.js | 1 + lib/dijit/_editor/nls/pt-pt/FontChoice.js | 1 + lib/dijit/_editor/nls/pt-pt/LinkDialog.js | 1 + lib/dijit/_editor/nls/pt-pt/commands.js | 1 + lib/dijit/_editor/nls/pt/FontChoice.js | 1 + lib/dijit/_editor/nls/pt/LinkDialog.js | 1 + lib/dijit/_editor/nls/pt/commands.js | 1 + lib/dijit/_editor/nls/ro/FontChoice.js | 1 + lib/dijit/_editor/nls/ro/LinkDialog.js | 1 + lib/dijit/_editor/nls/ro/commands.js | 1 + lib/dijit/_editor/nls/ru/FontChoice.js | 1 + lib/dijit/_editor/nls/ru/LinkDialog.js | 1 + lib/dijit/_editor/nls/ru/commands.js | 1 + lib/dijit/_editor/nls/sk/FontChoice.js | 1 + lib/dijit/_editor/nls/sk/LinkDialog.js | 1 + lib/dijit/_editor/nls/sk/commands.js | 1 + lib/dijit/_editor/nls/sl/FontChoice.js | 1 + lib/dijit/_editor/nls/sl/LinkDialog.js | 1 + lib/dijit/_editor/nls/sl/commands.js | 1 + lib/dijit/_editor/nls/sv/FontChoice.js | 1 + lib/dijit/_editor/nls/sv/LinkDialog.js | 1 + lib/dijit/_editor/nls/sv/commands.js | 1 + lib/dijit/_editor/nls/th/FontChoice.js | 1 + lib/dijit/_editor/nls/th/LinkDialog.js | 1 + lib/dijit/_editor/nls/th/commands.js | 1 + lib/dijit/_editor/nls/tr/FontChoice.js | 1 + lib/dijit/_editor/nls/tr/LinkDialog.js | 1 + lib/dijit/_editor/nls/tr/commands.js | 1 + lib/dijit/_editor/nls/zh-tw/FontChoice.js | 1 + lib/dijit/_editor/nls/zh-tw/LinkDialog.js | 1 + lib/dijit/_editor/nls/zh-tw/commands.js | 1 + lib/dijit/_editor/nls/zh/FontChoice.js | 1 + lib/dijit/_editor/nls/zh/LinkDialog.js | 1 + lib/dijit/_editor/nls/zh/commands.js | 1 + lib/dijit/_editor/plugins/AlwaysShowToolbar.js | 119 +++ lib/dijit/_editor/plugins/EnterKeyHandling.js | 423 ++++++++++ lib/dijit/_editor/plugins/FontChoice.js | 265 ++++++ lib/dijit/_editor/plugins/FullScreen.js | 232 ++++++ lib/dijit/_editor/plugins/LinkDialog.js | 236 ++++++ lib/dijit/_editor/plugins/NewPage.js | 36 + lib/dijit/_editor/plugins/Print.js | 65 ++ lib/dijit/_editor/plugins/TabIndent.js | 33 + lib/dijit/_editor/plugins/TextColor.js | 62 ++ lib/dijit/_editor/plugins/ToggleDir.js | 42 + lib/dijit/_editor/plugins/ViewSource.js | 317 +++++++ lib/dijit/_editor/range.js | 453 ++++++++++ lib/dijit/_editor/selection.js | 267 ++++++ 103 files changed, 3903 insertions(+) create mode 100644 lib/dijit/_editor/RichText.js create mode 100644 lib/dijit/_editor/_Plugin.js create mode 100644 lib/dijit/_editor/html.js create mode 100644 lib/dijit/_editor/nls/FontChoice.js create mode 100644 lib/dijit/_editor/nls/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/ar/FontChoice.js create mode 100644 lib/dijit/_editor/nls/ar/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/ar/commands.js create mode 100644 lib/dijit/_editor/nls/ca/FontChoice.js create mode 100644 lib/dijit/_editor/nls/ca/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/ca/commands.js create mode 100644 lib/dijit/_editor/nls/commands.js create mode 100644 lib/dijit/_editor/nls/cs/FontChoice.js create mode 100644 lib/dijit/_editor/nls/cs/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/cs/commands.js create mode 100644 lib/dijit/_editor/nls/da/FontChoice.js create mode 100644 lib/dijit/_editor/nls/da/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/da/commands.js create mode 100644 lib/dijit/_editor/nls/de/FontChoice.js create mode 100644 lib/dijit/_editor/nls/de/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/de/commands.js create mode 100644 lib/dijit/_editor/nls/el/FontChoice.js create mode 100644 lib/dijit/_editor/nls/el/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/el/commands.js create mode 100644 lib/dijit/_editor/nls/es/FontChoice.js create mode 100644 lib/dijit/_editor/nls/es/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/es/commands.js create mode 100644 lib/dijit/_editor/nls/fi/FontChoice.js create mode 100644 lib/dijit/_editor/nls/fi/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/fi/commands.js create mode 100644 lib/dijit/_editor/nls/fr/FontChoice.js create mode 100644 lib/dijit/_editor/nls/fr/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/fr/commands.js create mode 100644 lib/dijit/_editor/nls/he/FontChoice.js create mode 100644 lib/dijit/_editor/nls/he/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/he/commands.js create mode 100644 lib/dijit/_editor/nls/hu/FontChoice.js create mode 100644 lib/dijit/_editor/nls/hu/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/hu/commands.js create mode 100644 lib/dijit/_editor/nls/it/FontChoice.js create mode 100644 lib/dijit/_editor/nls/it/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/it/commands.js create mode 100644 lib/dijit/_editor/nls/ja/FontChoice.js create mode 100644 lib/dijit/_editor/nls/ja/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/ja/commands.js create mode 100644 lib/dijit/_editor/nls/ko/FontChoice.js create mode 100644 lib/dijit/_editor/nls/ko/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/ko/commands.js create mode 100644 lib/dijit/_editor/nls/nb/FontChoice.js create mode 100644 lib/dijit/_editor/nls/nb/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/nb/commands.js create mode 100644 lib/dijit/_editor/nls/nl/FontChoice.js create mode 100644 lib/dijit/_editor/nls/nl/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/nl/commands.js create mode 100644 lib/dijit/_editor/nls/pl/FontChoice.js create mode 100644 lib/dijit/_editor/nls/pl/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/pl/commands.js create mode 100644 lib/dijit/_editor/nls/pt-pt/FontChoice.js create mode 100644 lib/dijit/_editor/nls/pt-pt/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/pt-pt/commands.js create mode 100644 lib/dijit/_editor/nls/pt/FontChoice.js create mode 100644 lib/dijit/_editor/nls/pt/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/pt/commands.js create mode 100644 lib/dijit/_editor/nls/ro/FontChoice.js create mode 100644 lib/dijit/_editor/nls/ro/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/ro/commands.js create mode 100644 lib/dijit/_editor/nls/ru/FontChoice.js create mode 100644 lib/dijit/_editor/nls/ru/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/ru/commands.js create mode 100644 lib/dijit/_editor/nls/sk/FontChoice.js create mode 100644 lib/dijit/_editor/nls/sk/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/sk/commands.js create mode 100644 lib/dijit/_editor/nls/sl/FontChoice.js create mode 100644 lib/dijit/_editor/nls/sl/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/sl/commands.js create mode 100644 lib/dijit/_editor/nls/sv/FontChoice.js create mode 100644 lib/dijit/_editor/nls/sv/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/sv/commands.js create mode 100644 lib/dijit/_editor/nls/th/FontChoice.js create mode 100644 lib/dijit/_editor/nls/th/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/th/commands.js create mode 100644 lib/dijit/_editor/nls/tr/FontChoice.js create mode 100644 lib/dijit/_editor/nls/tr/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/tr/commands.js create mode 100644 lib/dijit/_editor/nls/zh-tw/FontChoice.js create mode 100644 lib/dijit/_editor/nls/zh-tw/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/zh-tw/commands.js create mode 100644 lib/dijit/_editor/nls/zh/FontChoice.js create mode 100644 lib/dijit/_editor/nls/zh/LinkDialog.js create mode 100644 lib/dijit/_editor/nls/zh/commands.js create mode 100644 lib/dijit/_editor/plugins/AlwaysShowToolbar.js create mode 100644 lib/dijit/_editor/plugins/EnterKeyHandling.js create mode 100644 lib/dijit/_editor/plugins/FontChoice.js create mode 100644 lib/dijit/_editor/plugins/FullScreen.js create mode 100644 lib/dijit/_editor/plugins/LinkDialog.js create mode 100644 lib/dijit/_editor/plugins/NewPage.js create mode 100644 lib/dijit/_editor/plugins/Print.js create mode 100644 lib/dijit/_editor/plugins/TabIndent.js create mode 100644 lib/dijit/_editor/plugins/TextColor.js create mode 100644 lib/dijit/_editor/plugins/ToggleDir.js create mode 100644 lib/dijit/_editor/plugins/ViewSource.js create mode 100644 lib/dijit/_editor/range.js create mode 100644 lib/dijit/_editor/selection.js (limited to 'lib/dijit/_editor') diff --git a/lib/dijit/_editor/RichText.js b/lib/dijit/_editor/RichText.js new file mode 100644 index 000000000..696715986 --- /dev/null +++ b/lib/dijit/_editor/RichText.js @@ -0,0 +1,1046 @@ +/* + Copyright (c) 2004-2010, The Dojo Foundation All Rights Reserved. + Available via Academic Free License >= 2.1 OR the modified BSD license. + see: http://dojotoolkit.org/license for details +*/ + + +if(!dojo._hasResource["dijit._editor.RichText"]){ +dojo._hasResource["dijit._editor.RichText"]=true; +dojo.provide("dijit._editor.RichText"); +dojo.require("dijit._Widget"); +dojo.require("dijit._CssStateMixin"); +dojo.require("dijit._editor.selection"); +dojo.require("dijit._editor.range"); +dojo.require("dijit._editor.html"); +if(!dojo.config["useXDomain"]||dojo.config["allowXdRichTextSave"]){ +if(dojo._postLoad){ +(function(){ +var _1=dojo.doc.createElement("textarea"); +_1.id=dijit._scopeName+"._editor.RichText.savedContent"; +dojo.style(_1,{display:"none",position:"absolute",top:"-100px",height:"3px",width:"3px"}); +dojo.body().appendChild(_1); +})(); +}else{ +try{ +dojo.doc.write(""); +} +catch(e){ +} +} +} +dojo.declare("dijit._editor.RichText",[dijit._Widget,dijit._CssStateMixin],{constructor:function(_2){ +this.contentPreFilters=[]; +this.contentPostFilters=[]; +this.contentDomPreFilters=[]; +this.contentDomPostFilters=[]; +this.editingAreaStyleSheets=[]; +this.events=[].concat(this.events); +this._keyHandlers={}; +this.contentPreFilters.push(dojo.hitch(this,"_preFixUrlAttributes")); +if(dojo.isMoz){ +this.contentPreFilters.push(this._normalizeFontStyle); +this.contentPostFilters.push(this._removeMozBogus); +} +if(dojo.isWebKit){ +this.contentPreFilters.push(this._removeWebkitBogus); +this.contentPostFilters.push(this._removeWebkitBogus); +} +if(dojo.isIE){ +this.contentPostFilters.push(this._normalizeFontStyle); +} +if(_2&&dojo.isString(_2.value)){ +this.value=_2.value; +} +this.onLoadDeferred=new dojo.Deferred(); +},baseClass:"dijitEditor",inheritWidth:false,focusOnLoad:false,name:"",styleSheets:"",_content:"",height:"300px",minHeight:"1em",isClosed:true,isLoaded:false,_SEPARATOR:"@@**%%__RICHTEXTBOUNDRY__%%**@@",onLoadDeferred:null,isTabIndent:false,disableSpellCheck:false,postCreate:function(){ +if("textarea"==this.domNode.tagName.toLowerCase()){ +console.warn("RichText should not be used with the TEXTAREA tag. See dijit._editor.RichText docs."); +} +this.inherited(arguments); +dojo.publish(dijit._scopeName+"._editor.RichText::init",[this]); +this.open(); +this.setupDefaultShortcuts(); +},setupDefaultShortcuts:function(){ +var _3=dojo.hitch(this,function(_4,_5){ +return function(){ +return !this.execCommand(_4,_5); +}; +}); +var _6={b:_3("bold"),i:_3("italic"),u:_3("underline"),a:_3("selectall"),s:function(){ +this.save(true); +},m:function(){ +this.isTabIndent=!this.isTabIndent; +},"1":_3("formatblock","h1"),"2":_3("formatblock","h2"),"3":_3("formatblock","h3"),"4":_3("formatblock","h4"),"\\":_3("insertunorderedlist")}; +if(!dojo.isIE){ +_6.Z=_3("redo"); +} +for(var _7 in _6){ +this.addKeyHandler(_7,true,false,_6[_7]); +} +},events:["onKeyPress","onKeyDown","onKeyUp","onClick"],captureEvents:[],_editorCommandsLocalized:false,_localizeEditorCommands:function(){ +if(this._editorCommandsLocalized){ +return; +} +this._editorCommandsLocalized=true; +var _8=["div","p","pre","h1","h2","h3","h4","h5","h6","ol","ul","address"]; +var _9="",_a,i=0; +while((_a=_8[i++])){ +if(_a.charAt(1)!="l"){ +_9+="<"+_a+">content
"; +}else{ +_9+="<"+_a+">
  • content

  • "; +} +} +var _b=dojo.doc.createElement("div"); +dojo.style(_b,{position:"absolute",top:"-2000px"}); +dojo.doc.body.appendChild(_b); +_b.innerHTML=_9; +var _c=_b.firstChild; +while(_c){ +dijit._editor.selection.selectElement(_c.firstChild); +dojo.withGlobal(this.window,"selectElement",dijit._editor.selection,[_c.firstChild]); +var _d=_c.tagName.toLowerCase(); +this._local2NativeFormatNames[_d]=document.queryCommandValue("formatblock"); +this._native2LocalFormatNames[this._local2NativeFormatNames[_d]]=_d; +_c=_c.nextSibling.nextSibling; +} +dojo.body().removeChild(_b); +},open:function(_e){ +if(!this.onLoadDeferred||this.onLoadDeferred.fired>=0){ +this.onLoadDeferred=new dojo.Deferred(); +} +if(!this.isClosed){ +this.close(); +} +dojo.publish(dijit._scopeName+"._editor.RichText::open",[this]); +this._content=""; +if(arguments.length==1&&_e.nodeName){ +this.domNode=_e; +} +var dn=this.domNode; +var _f; +if(dojo.isString(this.value)){ +_f=this.value; +delete this.value; +dn.innerHTML=""; +}else{ +if(dn.nodeName&&dn.nodeName.toLowerCase()=="textarea"){ +var ta=(this.textarea=dn); +this.name=ta.name; +_f=ta.value; +dn=this.domNode=dojo.doc.createElement("div"); +dn.setAttribute("widgetId",this.id); +ta.removeAttribute("widgetId"); +dn.cssText=ta.cssText; +dn.className+=" "+ta.className; +dojo.place(dn,ta,"before"); +var _10=dojo.hitch(this,function(){ +dojo.style(ta,{display:"block",position:"absolute",top:"-1000px"}); +if(dojo.isIE){ +var s=ta.style; +this.__overflow=s.overflow; +s.overflow="hidden"; +} +}); +if(dojo.isIE){ +setTimeout(_10,10); +}else{ +_10(); +} +if(ta.form){ +dojo.connect(ta.form,"onsubmit",this,function(){ +ta.value=this.getValue(); +}); +} +}else{ +_f=dijit._editor.getChildrenHtml(dn); +dn.innerHTML=""; +} +} +var _11=dojo.contentBox(dn); +this._oldHeight=_11.h; +this._oldWidth=_11.w; +this.savedContent=_f; +if(dn.nodeName&&dn.nodeName=="LI"){ +dn.innerHTML="
    "; +} +this.header=dn.ownerDocument.createElement("div"); +dn.appendChild(this.header); +this.editingArea=dn.ownerDocument.createElement("div"); +dn.appendChild(this.editingArea); +this.footer=dn.ownerDocument.createElement("div"); +dn.appendChild(this.footer); +if(this.name!==""&&(!dojo.config["useXDomain"]||dojo.config["allowXdRichTextSave"])){ +var _12=dojo.byId(dijit._scopeName+"._editor.RichText.savedContent"); +if(_12.value!==""){ +var _13=_12.value.split(this._SEPARATOR),i=0,dat; +while((dat=_13[i++])){ +var _14=dat.split(":"); +if(_14[0]==this.name){ +_f=_14[1]; +_13.splice(i,1); +break; +} +} +} +dojo.addOnUnload(dojo.hitch(this,"_saveContent")); +} +this.isClosed=false; +var ifr=(this.editorObject=this.iframe=dojo.doc.createElement("iframe")); +ifr.id=this.id+"_iframe"; +this._iframeSrc=this._getIframeDocTxt(); +ifr.style.border="none"; +ifr.style.width="100%"; +if(this._layoutMode){ +ifr.style.height="100%"; +}else{ +if(dojo.isIE>=7){ +if(this.height){ +ifr.style.height=this.height; +} +if(this.minHeight){ +ifr.style.minHeight=this.minHeight; +} +}else{ +ifr.style.height=this.height?this.height:this.minHeight; +} +} +ifr.frameBorder=0; +ifr._loadFunc=dojo.hitch(this,function(win){ +this.window=win; +this.document=this.window.document; +if(dojo.isIE){ +this._localizeEditorCommands(); +} +this.onLoad(_f); +}); +var s="javascript:parent."+dijit._scopeName+".byId(\""+this.id+"\")._iframeSrc"; +ifr.setAttribute("src",s); +this.editingArea.appendChild(ifr); +if(dn.nodeName=="LI"){ +dn.lastChild.style.marginTop="-1.2em"; +} +dojo.addClass(this.domNode,this.baseClass); +},_local2NativeFormatNames:{},_native2LocalFormatNames:{},_getIframeDocTxt:function(){ +var _15=dojo.getComputedStyle(this.domNode); +var _16=""; +var _17=true; +if(dojo.isIE||(!this.height&&!dojo.isMoz)){ +_16="
    "; +_17=false; +}else{ +if(dojo.isMoz){ +this._cursorToStart=true; +_16=" "; +} +} +var _18=[_15.fontWeight,_15.fontSize,_15.fontFamily].join(" "); +var _19=_15.lineHeight; +if(_19.indexOf("px")>=0){ +_19=parseFloat(_19)/parseFloat(_15.fontSize); +}else{ +if(_19.indexOf("em")>=0){ +_19=parseFloat(_19); +}else{ +_19="normal"; +} +} +var _1a=""; +var _1b=this; +this.style.replace(/(^|;)\s*(line-|font-?)[^;]+/ig,function(_1c){ +_1c=_1c.replace(/^;/ig,"")+";"; +var s=_1c.split(":")[0]; +if(s){ +s=dojo.trim(s); +s=s.toLowerCase(); +var i; +var sC=""; +for(i=0;i\n\n":"\n\n",(dojo.isMoz&&_1d.length?""+_1d[0].innerHTML+"\n":""),"\n","\n",this._applyEditingAreaStyleSheets(),"\n","\n",_16,"\n"].join(""); +},_applyEditingAreaStyleSheets:function(){ +var _1e=[]; +if(this.styleSheets){ +_1e=this.styleSheets.split(";"); +this.styleSheets=""; +} +_1e=_1e.concat(this.editingAreaStyleSheets); +this.editingAreaStyleSheets=[]; +var _1f="",i=0,url; +while((url=_1e[i++])){ +var _20=(new dojo._Url(dojo.global.location,url)).toString(); +this.editingAreaStyleSheets.push(_20); +_1f+=""; +} +return _1f; +},addStyleSheet:function(uri){ +var url=uri.toString(); +if(url.charAt(0)=="."||(url.charAt(0)!="/"&&!uri.host)){ +url=(new dojo._Url(dojo.global.location,url)).toString(); +} +if(dojo.indexOf(this.editingAreaStyleSheets,url)>-1){ +return; +} +this.editingAreaStyleSheets.push(url); +this.onLoadDeferred.addCallback(dojo.hitch(function(){ +if(this.document.createStyleSheet){ +this.document.createStyleSheet(url); +}else{ +var _21=this.document.getElementsByTagName("head")[0]; +var _22=this.document.createElement("link"); +_22.rel="stylesheet"; +_22.type="text/css"; +_22.href=url; +_21.appendChild(_22); +} +})); +},removeStyleSheet:function(uri){ +var url=uri.toString(); +if(url.charAt(0)=="."||(url.charAt(0)!="/"&&!uri.host)){ +url=(new dojo._Url(dojo.global.location,url)).toString(); +} +var _23=dojo.indexOf(this.editingAreaStyleSheets,url); +if(_23==-1){ +return; +} +delete this.editingAreaStyleSheets[_23]; +dojo.withGlobal(this.window,"query",dojo,["link:[href=\""+url+"\"]"]).orphan(); +},disabled:false,_mozSettingProps:{"styleWithCSS":false},_setDisabledAttr:function(_24){ +this.disabled=_24; +if(!this.isLoaded){ +return; +} +_24=!!_24; +if(dojo.isIE||dojo.isWebKit||dojo.isOpera){ +var _25=dojo.isIE&&(this.isLoaded||!this.focusOnLoad); +if(_25){ +this.editNode.unselectable="on"; +} +this.editNode.contentEditable=!_24; +if(_25){ +var _26=this; +setTimeout(function(){ +_26.editNode.unselectable="off"; +},0); +} +}else{ +try{ +this.document.designMode=(_24?"off":"on"); +} +catch(e){ +return; +} +if(!_24&&this._mozSettingProps){ +var ps=this._mozSettingProps; +for(var n in ps){ +if(ps.hasOwnProperty(n)){ +try{ +this.document.execCommand(n,false,ps[n]); +} +catch(e2){ +} +} +} +} +} +this._disabledOK=true; +},onLoad:function(_27){ +if(!this.window.__registeredWindow){ +this.window.__registeredWindow=true; +this._iframeRegHandle=dijit.registerIframe(this.iframe); +} +if(!dojo.isIE&&(this.height||dojo.isMoz)){ +this.editNode=this.document.body; +}else{ +this.editNode=this.document.body.firstChild; +var _28=this; +if(dojo.isIE){ +var _29=(this.tabStop=dojo.doc.createElement("
    ")); +this.editingArea.appendChild(_29); +this.iframe.onfocus=function(){ +_28.editNode.setActive(); +}; +} +} +this.focusNode=this.editNode; +var _2a=this.events.concat(this.captureEvents); +var ap=this.iframe?this.document:this.editNode; +dojo.forEach(_2a,function(_2b){ +this.connect(ap,_2b.toLowerCase(),_2b); +},this); +if(dojo.isIE){ +this.connect(this.document,"onmousedown","_onIEMouseDown"); +this.editNode.style.zoom=1; +}else{ +this.connect(this.document,"onmousedown",function(){ +delete this._cursorToStart; +}); +} +if(dojo.isWebKit){ +this._webkitListener=this.connect(this.document,"onmouseup","onDisplayChanged"); +} +if(dojo.isIE){ +try{ +this.document.execCommand("RespectVisibilityInDesign",true,null); +} +catch(e){ +} +} +this.isLoaded=true; +this.set("disabled",this.disabled); +var _2c=dojo.hitch(this,function(){ +this.setValue(_27); +if(this.onLoadDeferred){ +this.onLoadDeferred.callback(true); +} +this.onDisplayChanged(); +if(this.focusOnLoad){ +dojo.addOnLoad(dojo.hitch(this,function(){ +setTimeout(dojo.hitch(this,"focus"),this.updateInterval); +})); +} +this.savedContent=this.getValue(true); +}); +if(this.setValueDeferred){ +this.setValueDeferred.addCallback(_2c); +}else{ +_2c(); +} +},onKeyDown:function(e){ +if(e.keyCode===dojo.keys.TAB&&this.isTabIndent){ +dojo.stopEvent(e); +if(this.queryCommandEnabled((e.shiftKey?"outdent":"indent"))){ +this.execCommand((e.shiftKey?"outdent":"indent")); +} +} +if(dojo.isIE){ +if(e.keyCode==dojo.keys.TAB&&!this.isTabIndent){ +if(e.shiftKey&&!e.ctrlKey&&!e.altKey){ +this.iframe.focus(); +}else{ +if(!e.shiftKey&&!e.ctrlKey&&!e.altKey){ +this.tabStop.focus(); +} +} +}else{ +if(e.keyCode===dojo.keys.BACKSPACE&&this.document.selection.type==="Control"){ +dojo.stopEvent(e); +this.execCommand("delete"); +}else{ +if((65<=e.keyCode&&e.keyCode<=90)||(e.keyCode>=37&&e.keyCode<=40)){ +e.charCode=e.keyCode; +this.onKeyPress(e); +} +} +} +} +return true; +},onKeyUp:function(e){ +return; +},setDisabled:function(_2d){ +dojo.deprecated("dijit.Editor::setDisabled is deprecated","use dijit.Editor::attr(\"disabled\",boolean) instead",2); +this.set("disabled",_2d); +},_setValueAttr:function(_2e){ +this.setValue(_2e); +},_setDisableSpellCheckAttr:function(_2f){ +if(this.document){ +dojo.attr(this.document.body,"spellcheck",!_2f); +}else{ +this.onLoadDeferred.addCallback(dojo.hitch(this,function(){ +dojo.attr(this.document.body,"spellcheck",!_2f); +})); +} +this.disableSpellCheck=_2f; +},onKeyPress:function(e){ +var c=(e.keyChar&&e.keyChar.toLowerCase())||e.keyCode,_30=this._keyHandlers[c],_31=arguments; +if(_30&&!e.altKey){ +dojo.some(_30,function(h){ +if(!(h.shift^e.shiftKey)&&!(h.ctrl^(e.ctrlKey||e.metaKey))){ +if(!h.handler.apply(this,_31)){ +e.preventDefault(); +} +return true; +} +},this); +} +if(!this._onKeyHitch){ +this._onKeyHitch=dojo.hitch(this,"onKeyPressed"); +} +setTimeout(this._onKeyHitch,1); +return true; +},addKeyHandler:function(key,_32,_33,_34){ +if(!dojo.isArray(this._keyHandlers[key])){ +this._keyHandlers[key]=[]; +} +this._keyHandlers[key].push({shift:_33||false,ctrl:_32||false,handler:_34}); +},onKeyPressed:function(){ +this.onDisplayChanged(); +},onClick:function(e){ +this.onDisplayChanged(e); +},_onIEMouseDown:function(e){ +if(!this._focused&&!this.disabled){ +this.focus(); +} +},_onBlur:function(e){ +this.inherited(arguments); +var _35=this.getValue(true); +if(_35!=this.savedContent){ +this.onChange(_35); +this.savedContent=_35; +} +},_onFocus:function(e){ +if(!this.disabled){ +if(!this._disabledOK){ +this.set("disabled",false); +} +this.inherited(arguments); +} +},blur:function(){ +if(!dojo.isIE&&this.window.document.documentElement&&this.window.document.documentElement.focus){ +this.window.document.documentElement.focus(); +}else{ +if(dojo.doc.body.focus){ +dojo.doc.body.focus(); +} +} +},focus:function(){ +if(!this.isLoaded){ +this.focusOnLoad=true; +return; +} +if(this._cursorToStart){ +delete this._cursorToStart; +if(this.editNode.childNodes){ +this.placeCursorAtStart(); +return; +} +} +if(!dojo.isIE){ +dijit.focus(this.iframe); +}else{ +if(this.editNode&&this.editNode.focus){ +this.iframe.fireEvent("onfocus",document.createEventObject()); +} +} +},updateInterval:200,_updateTimer:null,onDisplayChanged:function(e){ +if(this._updateTimer){ +clearTimeout(this._updateTimer); +} +if(!this._updateHandler){ +this._updateHandler=dojo.hitch(this,"onNormalizedDisplayChanged"); +} +this._updateTimer=setTimeout(this._updateHandler,this.updateInterval); +},onNormalizedDisplayChanged:function(){ +delete this._updateTimer; +},onChange:function(_36){ +},_normalizeCommand:function(cmd,_37){ +var _38=cmd.toLowerCase(); +if(_38=="formatblock"){ +if(dojo.isSafari&&_37===undefined){ +_38="heading"; +} +}else{ +if(_38=="hilitecolor"&&!dojo.isMoz){ +_38="backcolor"; +} +} +return _38; +},_qcaCache:{},queryCommandAvailable:function(_39){ +var ca=this._qcaCache[_39]; +if(ca!==undefined){ +return ca; +} +return (this._qcaCache[_39]=this._queryCommandAvailable(_39)); +},_queryCommandAvailable:function(_3a){ +var ie=1; +var _3b=1<<1; +var _3c=1<<2; +var _3d=1<<3; +var _3e=1<<4; +function _3f(_40){ +return {ie:Boolean(_40&ie),mozilla:Boolean(_40&_3b),webkit:Boolean(_40&_3c),webkit420:Boolean(_40&_3e),opera:Boolean(_40&_3d)}; +}; +var _41=null; +switch(_3a.toLowerCase()){ +case "bold": +case "italic": +case "underline": +case "subscript": +case "superscript": +case "fontname": +case "fontsize": +case "forecolor": +case "hilitecolor": +case "justifycenter": +case "justifyfull": +case "justifyleft": +case "justifyright": +case "delete": +case "selectall": +case "toggledir": +_41=_3f(_3b|ie|_3c|_3d); +break; +case "createlink": +case "unlink": +case "removeformat": +case "inserthorizontalrule": +case "insertimage": +case "insertorderedlist": +case "insertunorderedlist": +case "indent": +case "outdent": +case "formatblock": +case "inserthtml": +case "undo": +case "redo": +case "strikethrough": +case "tabindent": +_41=_3f(_3b|ie|_3d|_3e); +break; +case "blockdirltr": +case "blockdirrtl": +case "dirltr": +case "dirrtl": +case "inlinedirltr": +case "inlinedirrtl": +_41=_3f(ie); +break; +case "cut": +case "copy": +case "paste": +_41=_3f(ie|_3b|_3e); +break; +case "inserttable": +_41=_3f(_3b|ie); +break; +case "insertcell": +case "insertcol": +case "insertrow": +case "deletecells": +case "deletecols": +case "deleterows": +case "mergecells": +case "splitcell": +_41=_3f(ie|_3b); +break; +default: +return false; +} +return (dojo.isIE&&_41.ie)||(dojo.isMoz&&_41.mozilla)||(dojo.isWebKit&&_41.webkit)||(dojo.isWebKit>420&&_41.webkit420)||(dojo.isOpera&&_41.opera); +},execCommand:function(_42,_43){ +var _44; +this.focus(); +_42=this._normalizeCommand(_42,_43); +if(_43!==undefined){ +if(_42=="heading"){ +throw new Error("unimplemented"); +}else{ +if((_42=="formatblock")&&dojo.isIE){ +_43="<"+_43+">"; +} +} +} +var _45="_"+_42+"Impl"; +if(this[_45]){ +_44=this[_45](_43); +}else{ +_43=arguments.length>1?_43:null; +if(_43||_42!="createlink"){ +_44=this.document.execCommand(_42,false,_43); +} +} +this.onDisplayChanged(); +return _44; +},queryCommandEnabled:function(_46){ +if(this.disabled||!this._disabledOK){ +return false; +} +_46=this._normalizeCommand(_46); +if(dojo.isMoz||dojo.isWebKit){ +if(_46=="unlink"){ +return this._sCall("hasAncestorElement",["a"]); +}else{ +if(_46=="inserttable"){ +return true; +} +} +} +if(dojo.isWebKit){ +if(_46=="copy"){ +_46="cut"; +}else{ +if(_46=="paste"){ +return true; +} +} +} +var _47=dojo.isIE?this.document.selection.createRange():this.document; +try{ +return _47.queryCommandEnabled(_46); +} +catch(e){ +return false; +} +},queryCommandState:function(_48){ +if(this.disabled||!this._disabledOK){ +return false; +} +_48=this._normalizeCommand(_48); +try{ +return this.document.queryCommandState(_48); +} +catch(e){ +return false; +} +},queryCommandValue:function(_49){ +if(this.disabled||!this._disabledOK){ +return false; +} +var r; +_49=this._normalizeCommand(_49); +if(dojo.isIE&&_49=="formatblock"){ +r=this._native2LocalFormatNames[this.document.queryCommandValue(_49)]; +}else{ +if(dojo.isMoz&&_49==="hilitecolor"){ +var _4a; +try{ +_4a=this.document.queryCommandValue("styleWithCSS"); +} +catch(e){ +_4a=false; +} +this.document.execCommand("styleWithCSS",false,true); +r=this.document.queryCommandValue(_49); +this.document.execCommand("styleWithCSS",false,_4a); +}else{ +r=this.document.queryCommandValue(_49); +} +} +return r; +},_sCall:function(_4b,_4c){ +return dojo.withGlobal(this.window,_4b,dijit._editor.selection,_4c); +},placeCursorAtStart:function(){ +this.focus(); +var _4d=false; +if(dojo.isMoz){ +var _4e=this.editNode.firstChild; +while(_4e){ +if(_4e.nodeType==3){ +if(_4e.nodeValue.replace(/^\s+|\s+$/g,"").length>0){ +_4d=true; +this._sCall("selectElement",[_4e]); +break; +} +}else{ +if(_4e.nodeType==1){ +_4d=true; +var tg=_4e.tagName?_4e.tagName.toLowerCase():""; +if(/br|input|img|base|meta|area|basefont|hr|link/.test(tg)){ +this._sCall("selectElement",[_4e]); +}else{ +this._sCall("selectElementChildren",[_4e]); +} +break; +} +} +_4e=_4e.nextSibling; +} +}else{ +_4d=true; +this._sCall("selectElementChildren",[this.editNode]); +} +if(_4d){ +this._sCall("collapse",[true]); +} +},placeCursorAtEnd:function(){ +this.focus(); +var _4f=false; +if(dojo.isMoz){ +var _50=this.editNode.lastChild; +while(_50){ +if(_50.nodeType==3){ +if(_50.nodeValue.replace(/^\s+|\s+$/g,"").length>0){ +_4f=true; +this._sCall("selectElement",[_50]); +break; +} +}else{ +if(_50.nodeType==1){ +_4f=true; +if(_50.lastChild){ +this._sCall("selectElement",[_50.lastChild]); +}else{ +this._sCall("selectElement",[_50]); +} +break; +} +} +_50=_50.previousSibling; +} +}else{ +_4f=true; +this._sCall("selectElementChildren",[this.editNode]); +} +if(_4f){ +this._sCall("collapse",[false]); +} +},getValue:function(_51){ +if(this.textarea){ +if(this.isClosed||!this.isLoaded){ +return this.textarea.value; +} +} +return this._postFilterContent(null,_51); +},_getValueAttr:function(){ +return this.getValue(true); +},setValue:function(_52){ +if(!this.isLoaded){ +this.onLoadDeferred.addCallback(dojo.hitch(this,function(){ +this.setValue(_52); +})); +return; +} +this._cursorToStart=true; +if(this.textarea&&(this.isClosed||!this.isLoaded)){ +this.textarea.value=_52; +}else{ +_52=this._preFilterContent(_52); +var _53=this.isClosed?this.domNode:this.editNode; +if(!_52&&dojo.isWebKit){ +_52=" "; +} +_53.innerHTML=_52; +this._preDomFilterContent(_53); +} +this.onDisplayChanged(); +},replaceValue:function(_54){ +if(this.isClosed){ +this.setValue(_54); +}else{ +if(this.window&&this.window.getSelection&&!dojo.isMoz){ +this.setValue(_54); +}else{ +if(this.window&&this.window.getSelection){ +_54=this._preFilterContent(_54); +this.execCommand("selectall"); +if(!_54){ +this._cursorToStart=true; +_54=" "; +} +this.execCommand("inserthtml",_54); +this._preDomFilterContent(this.editNode); +}else{ +if(this.document&&this.document.selection){ +this.setValue(_54); +} +} +} +} +},_preFilterContent:function(_55){ +var ec=_55; +dojo.forEach(this.contentPreFilters,function(ef){ +if(ef){ +ec=ef(ec); +} +}); +return ec; +},_preDomFilterContent:function(dom){ +dom=dom||this.editNode; +dojo.forEach(this.contentDomPreFilters,function(ef){ +if(ef&&dojo.isFunction(ef)){ +ef(dom); +} +},this); +},_postFilterContent:function(dom,_56){ +var ec; +if(!dojo.isString(dom)){ +dom=dom||this.editNode; +if(this.contentDomPostFilters.length){ +if(_56){ +dom=dojo.clone(dom); +} +dojo.forEach(this.contentDomPostFilters,function(ef){ +dom=ef(dom); +}); +} +ec=dijit._editor.getChildrenHtml(dom); +}else{ +ec=dom; +} +if(!dojo.trim(ec.replace(/^\xA0\xA0*/,"").replace(/\xA0\xA0*$/,"")).length){ +ec=""; +} +dojo.forEach(this.contentPostFilters,function(ef){ +ec=ef(ec); +}); +return ec; +},_saveContent:function(e){ +var _57=dojo.byId(dijit._scopeName+"._editor.RichText.savedContent"); +if(_57.value){ +_57.value+=this._SEPARATOR; +} +_57.value+=this.name+":"+this.getValue(true); +},escapeXml:function(str,_58){ +str=str.replace(/&/gm,"&").replace(//gm,">").replace(/"/gm,"""); +if(!_58){ +str=str.replace(/'/gm,"'"); +} +return str; +},getNodeHtml:function(_59){ +dojo.deprecated("dijit.Editor::getNodeHtml is deprecated","use dijit._editor.getNodeHtml instead",2); +return dijit._editor.getNodeHtml(_59); +},getNodeChildrenHtml:function(dom){ +dojo.deprecated("dijit.Editor::getNodeChildrenHtml is deprecated","use dijit._editor.getChildrenHtml instead",2); +return dijit._editor.getChildrenHtml(dom); +},close:function(_5a){ +if(this.isClosed){ +return false; +} +if(!arguments.length){ +_5a=true; +} +this._content=this.getValue(); +var _5b=(this.savedContent!=this._content); +if(this.interval){ +clearInterval(this.interval); +} +if(this._webkitListener){ +this.disconnect(this._webkitListener); +delete this._webkitListener; +} +if(dojo.isIE){ +this.iframe.onfocus=null; +} +this.iframe._loadFunc=null; +if(this._iframeRegHandle){ +dijit.unregisterIframe(this._iframeRegHandle); +delete this._iframeRegHandle; +} +if(this.textarea){ +var s=this.textarea.style; +s.position=""; +s.left=s.top=""; +if(dojo.isIE){ +s.overflow=this.__overflow; +this.__overflow=null; +} +this.textarea.value=_5a?this._content:this.savedContent; +dojo.destroy(this.domNode); +this.domNode=this.textarea; +}else{ +this.domNode.innerHTML=_5a?this._content:this.savedContent; +} +delete this.iframe; +dojo.removeClass(this.domNode,this.baseClass); +this.isClosed=true; +this.isLoaded=false; +delete this.editNode; +delete this.focusNode; +if(this.window&&this.window._frameElement){ +this.window._frameElement=null; +} +this.window=null; +this.document=null; +this.editingArea=null; +this.editorObject=null; +return _5b; +},destroy:function(){ +if(!this.isClosed){ +this.close(false); +} +this.inherited(arguments); +},_removeMozBogus:function(_5c){ +return _5c.replace(/\stype="_moz"/gi,"").replace(/\s_moz_dirty=""/gi,"").replace(/_moz_resizing="(true|false)"/gi,""); +},_removeWebkitBogus:function(_5d){ +_5d=_5d.replace(/\sclass="webkit-block-placeholder"/gi,""); +_5d=_5d.replace(/\sclass="apple-style-span"/gi,""); +return _5d; +},_normalizeFontStyle:function(_5e){ +return _5e.replace(/<(\/)?strong([ \>])/gi,"<$1b$2").replace(/<(\/)?em([ \>])/gi,"<$1i$2"); +},_preFixUrlAttributes:function(_5f){ +return _5f.replace(/(?:(]+))/gi,"$1$4$2$3$5$2 _djrealurl=$2$3$5$2").replace(/(?:(]+))/gi,"$1$4$2$3$5$2 _djrealurl=$2$3$5$2"); +},_inserthorizontalruleImpl:function(_60){ +if(dojo.isIE){ +return this._inserthtmlImpl("
    "); +} +return this.document.execCommand("inserthorizontalrule",false,_60); +},_unlinkImpl:function(_61){ +if((this.queryCommandEnabled("unlink"))&&(dojo.isMoz||dojo.isWebKit)){ +var a=this._sCall("getAncestorElement",["a"]); +this._sCall("selectElement",[a]); +return this.document.execCommand("unlink",false,null); +} +return this.document.execCommand("unlink",false,_61); +},_hilitecolorImpl:function(_62){ +var _63; +if(dojo.isMoz){ +this.document.execCommand("styleWithCSS",false,true); +_63=this.document.execCommand("hilitecolor",false,_62); +this.document.execCommand("styleWithCSS",false,false); +}else{ +_63=this.document.execCommand("hilitecolor",false,_62); +} +return _63; +},_backcolorImpl:function(_64){ +if(dojo.isIE){ +_64=_64?_64:null; +} +return this.document.execCommand("backcolor",false,_64); +},_forecolorImpl:function(_65){ +if(dojo.isIE){ +_65=_65?_65:null; +} +return this.document.execCommand("forecolor",false,_65); +},_inserthtmlImpl:function(_66){ +_66=this._preFilterContent(_66); +var rv=true; +if(dojo.isIE){ +var _67=this.document.selection.createRange(); +if(this.document.selection.type.toUpperCase()=="CONTROL"){ +var n=_67.item(0); +while(_67.length){ +_67.remove(_67.item(0)); +} +n.outerHTML=_66; +}else{ +_67.pasteHTML(_66); +} +_67.select(); +}else{ +if(dojo.isMoz&&!_66.length){ +this._sCall("remove"); +}else{ +rv=this.document.execCommand("inserthtml",false,_66); +} +} +return rv; +},getHeaderHeight:function(){ +return this._getNodeChildrenHeight(this.header); +},getFooterHeight:function(){ +return this._getNodeChildrenHeight(this.footer); +},_getNodeChildrenHeight:function(_68){ +var h=0; +if(_68&&_68.childNodes){ +var i; +for(i=0;i<_68.childNodes.length;i++){ +var _69=dojo.position(_68.childNodes[i]); +h+=_69.h; +} +} +return h; +}}); +} diff --git a/lib/dijit/_editor/_Plugin.js b/lib/dijit/_editor/_Plugin.js new file mode 100644 index 000000000..f3c95aae0 --- /dev/null +++ b/lib/dijit/_editor/_Plugin.js @@ -0,0 +1,73 @@ +/* + Copyright (c) 2004-2010, The Dojo Foundation All Rights Reserved. + Available via Academic Free License >= 2.1 OR the modified BSD license. + see: http://dojotoolkit.org/license for details +*/ + + +if(!dojo._hasResource["dijit._editor._Plugin"]){ +dojo._hasResource["dijit._editor._Plugin"]=true; +dojo.provide("dijit._editor._Plugin"); +dojo.require("dijit._Widget"); +dojo.require("dijit.form.Button"); +dojo.declare("dijit._editor._Plugin",null,{constructor:function(_1,_2){ +this.params=_1||{}; +dojo.mixin(this,this.params); +this._connects=[]; +},editor:null,iconClassPrefix:"dijitEditorIcon",button:null,command:"",useDefaultCommand:true,buttonClass:dijit.form.Button,getLabel:function(_3){ +return this.editor.commands[_3]; +},_initButton:function(){ +if(this.command.length){ +var _4=this.getLabel(this.command),_5=this.editor,_6=this.iconClassPrefix+" "+this.iconClassPrefix+this.command.charAt(0).toUpperCase()+this.command.substr(1); +if(!this.button){ +var _7=dojo.mixin({label:_4,dir:_5.dir,lang:_5.lang,showLabel:false,iconClass:_6,dropDown:this.dropDown,tabIndex:"-1"},this.params||{}); +this.button=new this.buttonClass(_7); +} +} +},destroy:function(){ +dojo.forEach(this._connects,dojo.disconnect); +if(this.dropDown){ +this.dropDown.destroyRecursive(); +} +},connect:function(o,f,tf){ +this._connects.push(dojo.connect(o,f,this,tf)); +},updateState:function(){ +var e=this.editor,c=this.command,_8,_9; +if(!e||!e.isLoaded||!c.length){ +return; +} +if(this.button){ +try{ +_9=e.queryCommandEnabled(c); +if(this.enabled!==_9){ +this.enabled=_9; +this.button.set("disabled",!_9); +} +if(typeof this.button.checked=="boolean"){ +_8=e.queryCommandState(c); +if(this.checked!==_8){ +this.checked=_8; +this.button.set("checked",e.queryCommandState(c)); +} +} +} +catch(e){ +} +} +},setEditor:function(_a){ +this.editor=_a; +this._initButton(); +if(this.button&&this.useDefaultCommand){ +if(this.editor.queryCommandAvailable(this.command)){ +this.connect(this.button,"onClick",dojo.hitch(this.editor,"execCommand",this.command,this.commandArg)); +}else{ +this.button.domNode.style.display="none"; +} +} +this.connect(this.editor,"onNormalizedDisplayChanged","updateState"); +},setToolbar:function(_b){ +if(this.button){ +_b.addChild(this.button); +} +}}); +} diff --git a/lib/dijit/_editor/html.js b/lib/dijit/_editor/html.js new file mode 100644 index 000000000..7db85c7d9 --- /dev/null +++ b/lib/dijit/_editor/html.js @@ -0,0 +1,147 @@ +/* + Copyright (c) 2004-2010, The Dojo Foundation All Rights Reserved. + Available via Academic Free License >= 2.1 OR the modified BSD license. + see: http://dojotoolkit.org/license for details +*/ + + +if(!dojo._hasResource["dijit._editor.html"]){ +dojo._hasResource["dijit._editor.html"]=true; +dojo.provide("dijit._editor.html"); +dijit._editor.escapeXml=function(_1,_2){ +_1=_1.replace(/&/gm,"&").replace(//gm,">").replace(/"/gm,"""); +if(!_2){ +_1=_1.replace(/'/gm,"'"); +} +return _1; +}; +dijit._editor.getNodeHtml=function(_3){ +var _4; +switch(_3.nodeType){ +case 1: +var _5=_3.nodeName.toLowerCase(); +if(!_5||_5.charAt(0)=="/"){ +return ""; +} +_4="<"+_5; +var _6=[]; +var _7; +if(dojo.isIE&&_3.outerHTML){ +var s=_3.outerHTML; +s=s.substr(0,s.indexOf(">")).replace(/(['"])[^"']*\1/g,""); +var _8=/(\b\w+)\s?=/g; +var m,_9; +while((m=_8.exec(s))){ +_9=m[1]; +if(_9.substr(0,3)!="_dj"){ +if(_9=="src"||_9=="href"){ +if(_3.getAttribute("_djrealurl")){ +_6.push([_9,_3.getAttribute("_djrealurl")]); +continue; +} +} +var _a,_b; +switch(_9){ +case "style": +_a=_3.style.cssText.toLowerCase(); +break; +case "class": +_a=_3.className; +break; +case "width": +if(_5==="img"){ +_b=/width=(\S+)/i.exec(s); +if(_b){ +_a=_b[1]; +} +break; +} +case "height": +if(_5==="img"){ +_b=/height=(\S+)/i.exec(s); +if(_b){ +_a=_b[1]; +} +break; +} +default: +_a=_3.getAttribute(_9); +} +if(_a!=null){ +_6.push([_9,_a.toString()]); +} +} +} +}else{ +var i=0; +while((_7=_3.attributes[i++])){ +var n=_7.name; +if(n.substr(0,3)!="_dj"){ +var v=_7.value; +if(n=="src"||n=="href"){ +if(_3.getAttribute("_djrealurl")){ +v=_3.getAttribute("_djrealurl"); +} +} +_6.push([n,v]); +} +} +} +_6.sort(function(a,b){ +return a[0]"; +}else{ +if(_3.childNodes.length){ +_4+=">"+dijit._editor.getChildrenHtml(_3)+""; +}else{ +switch(_5){ +case "br": +case "hr": +case "img": +case "input": +case "base": +case "meta": +case "area": +case "basefont": +_4+=" />"; +break; +default: +_4+=">"; +} +} +} +break; +case 4: +case 3: +_4=dijit._editor.escapeXml(_3.nodeValue,true); +break; +case 8: +_4=""; +break; +default: +_4=""; +} +return _4; +}; +dijit._editor.getChildrenHtml=function(_c){ +var _d=""; +if(!_c){ +return _d; +} +var _e=_c["childNodes"]||_c; +var _f=!dojo.isIE||_e!==_c; +var _10,i=0; +while((_10=_e[i++])){ +if(!_f||_10.parentNode==_c){ +_d+=dijit._editor.getNodeHtml(_10); +} +} +return _d; +}; +} diff --git a/lib/dijit/_editor/nls/FontChoice.js b/lib/dijit/_editor/nls/FontChoice.js new file mode 100644 index 000000000..f2b6e0c90 --- /dev/null +++ b/lib/dijit/_editor/nls/FontChoice.js @@ -0,0 +1 @@ +({"noFormat":"None","1":"xx-small","2":"x-small","formatBlock":"Format","3":"small","4":"medium","5":"large","6":"x-large","7":"xx-large","fantasy":"fantasy","serif":"serif","p":"Paragraph","pre":"Pre-formatted","sans-serif":"sans-serif","fontName":"Font","h1":"Heading","h2":"Subheading","h3":"Sub-subheading","monospace":"monospace","fontSize":"Size","cursive":"cursive"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/LinkDialog.js b/lib/dijit/_editor/nls/LinkDialog.js new file mode 100644 index 000000000..0dd81f149 --- /dev/null +++ b/lib/dijit/_editor/nls/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Description:","insertImageTitle":"Image Properties","set":"Set","newWindow":"New Window","topWindow":"Topmost Window","target":"Target:","createLinkTitle":"Link Properties","parentWindow":"Parent Window","currentWindow":"Current Window","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/ar/FontChoice.js b/lib/dijit/_editor/nls/ar/FontChoice.js new file mode 100644 index 000000000..71683c008 --- /dev/null +++ b/lib/dijit/_editor/nls/ar/FontChoice.js @@ -0,0 +1 @@ +({"1":"صغير جدا جدا","2":"صغير جدا","formatBlock":"النسق","3":"صغير","4":"متوسط","5":"كبير","6":"كبير جدا","7":"كبير جدا جدا","fantasy":"خيالي","serif":"serif","p":"فقرة","pre":"منسق بصفة مسبقة","sans-serif":"sans-serif","fontName":"طاقم طباعة","h1":"عنوان","h2":"عنوان فرعي","h3":"فرعي-عنوان فرعي","monospace":"أحادي المسافة","fontSize":"الحجم","cursive":"كتابة بحروف متصلة","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/ar/LinkDialog.js b/lib/dijit/_editor/nls/ar/LinkDialog.js new file mode 100644 index 000000000..1a1b32e59 --- /dev/null +++ b/lib/dijit/_editor/nls/ar/LinkDialog.js @@ -0,0 +1 @@ +({"text":"الوصف:","insertImageTitle":"خصائص الصورة","set":"تحديد","newWindow":"نافذة جديدة","topWindow":"النافذة العلوية","target":"الهدف: ","createLinkTitle":"خصائص الوصلة","parentWindow":"النافذة الرئيسية","currentWindow":"النافذة الحالية","url":"عنوان URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/ar/commands.js b/lib/dijit/_editor/nls/ar/commands.js new file mode 100644 index 000000000..3e524ea91 --- /dev/null +++ b/lib/dijit/_editor/nls/ar/commands.js @@ -0,0 +1 @@ +({"removeFormat":"ازالة النسق","copy":"نسخ","paste":"لصق","selectAll":"اختيار كل","insertOrderedList":"‏كشف مرقم‏","insertTable":"ادراج/تحرير جدول","print":"‏طباعة‏","underline":"~تسطير","foreColor":"لون الواجهة الأمامية","htmlToggle":"مصدر HTML","formatBlock":"نمط الفقرة","newPage":"صفحة جديدة","insertHorizontalRule":"مسطرة أفقية","delete":"حذف","insertUnorderedList":"كشف نقطي","tableProp":"خصائص الجدول","insertImage":"ادراج صورة","superscript":"رمز علوي","subscript":"رمز سفلي","createLink":"تكوين وصلة","undo":"تراجع","fullScreen":"تبديل الشاشة الكاملة","italic":"~مائل","fontName":"اسم طاقم الطباعة","justifyLeft":"محاذاة الى اليسار","unlink":"ازالة وصلة","toggleTableBorder":"تبديل حدود الجدول","viewSource":"‫مشاهدة مصدر HTML‬","ctrlKey":"ctrl+${0}","fontSize":"حجم طاقم الطباعة","systemShortcut":"التصرف \"${0}\" يكون متاحا فقط في برنامج الاستعراض الخاص بك باستخدام المسار المختصر للوحة المفاتيح. استخدم ${1}.","indent":"‏ازاحة للداخل‏","redo":"‏اعادة‏","strikethrough":"تشطيب","justifyFull":"ضبط","justifyCenter":"محاذاة في الوسط","hiliteColor":"‏لون الخلفية‏","deleteTable":"حذف جدول","outdent":"ازاحة للخارج","cut":"قص","plainFormatBlock":"نمط الفقرة","toggleDir":"تبديل الاتجاه","bold":"عري~ض","tabIndent":"ازاحة للداخل باستخدام Tab","justifyRight":"محاذاة الى اليمين","appleKey":"⌘${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/ca/FontChoice.js b/lib/dijit/_editor/nls/ca/FontChoice.js new file mode 100644 index 000000000..efba7dec4 --- /dev/null +++ b/lib/dijit/_editor/nls/ca/FontChoice.js @@ -0,0 +1 @@ +({"1":"xx-petit","2":"x-petit","formatBlock":"Format","3":"petit","4":"mitjà","5":"gran","6":"x-gran","7":"xx-gran","fantasy":"Fantasia","serif":"serif","p":"Paràgraf","pre":"Format previ","sans-serif":"sans-serif","fontName":"Tipus de lletra","h1":"Títol","h2":"Subtítol","h3":"Subsubtítol","monospace":"monoespai","fontSize":"Mida","cursive":"Cursiva","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/ca/LinkDialog.js b/lib/dijit/_editor/nls/ca/LinkDialog.js new file mode 100644 index 000000000..b030a2ced --- /dev/null +++ b/lib/dijit/_editor/nls/ca/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Descipció:","insertImageTitle":"Propietats de la imatge","set":"Defineix","newWindow":"Finestra nova","topWindow":"Finestra superior","target":"Destinació:","createLinkTitle":"Propietats de l'enllaç","parentWindow":"Finestra pare","currentWindow":"Finestra actual","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/ca/commands.js b/lib/dijit/_editor/nls/ca/commands.js new file mode 100644 index 000000000..f78e71c85 --- /dev/null +++ b/lib/dijit/_editor/nls/ca/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Elimina el format","copy":"Copia","paste":"Enganxa","selectAll":"Selecciona-ho tot","insertOrderedList":"Llista numerada","insertTable":"Insereix/edita la taula","print":"Imprimeix","underline":"Subratllat","foreColor":"Color de primer pla","htmlToggle":"Font HTML","formatBlock":"Estil de paràgraf","newPage":"Pàgina nova","insertHorizontalRule":"Regle horitzontal","delete":"Suprimeix","insertUnorderedList":"Llista de vinyetes","tableProp":"Propietat de taula","insertImage":"Insereix imatge","superscript":"Superíndex","subscript":"Subíndex","createLink":"Crea un enllaç","undo":"Desfés","fullScreen":"Commuta pantalla completa","italic":"Cursiva","fontName":"Nom del tipus de lletra","justifyLeft":"Alinea a la esquerra","unlink":"Elimina l'enllaç","toggleTableBorder":"Inverteix els contorns de taula","viewSource":"Visualitza font HTML","ctrlKey":"control+${0}","fontSize":"Cos de la lletra","systemShortcut":"L'acció \"${0}\" és l'única disponible al navegador utilitzant una drecera del teclat. Utilitzeu ${1}.","indent":"Sagnat","redo":"Refés","strikethrough":"Ratllat","justifyFull":"Justifica","justifyCenter":"Centra","hiliteColor":"Color de fons","deleteTable":"Suprimeix la taula","outdent":"Sagna a l'esquerra","cut":"Retalla","plainFormatBlock":"Estil de paràgraf","toggleDir":"Inverteix la direcció","bold":"Negreta","tabIndent":"Sagnat","justifyRight":"Alinea a la dreta","appleKey":"⌘${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/commands.js b/lib/dijit/_editor/nls/commands.js new file mode 100644 index 000000000..582b782c0 --- /dev/null +++ b/lib/dijit/_editor/nls/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Remove Format","copy":"Copy","paste":"Paste","selectAll":"Select All","insertOrderedList":"Numbered List","insertTable":"Insert/Edit Table","print":"Print","underline":"Underline","foreColor":"Foreground Color","htmlToggle":"HTML Source","formatBlock":"Paragraph Style","newPage":"New Page","insertHorizontalRule":"Horizontal Rule","delete":"Delete","appleKey":"⌘${0}","insertUnorderedList":"Bullet List","tableProp":"Table Property","insertImage":"Insert Image","superscript":"Superscript","subscript":"Subscript","createLink":"Create Link","undo":"Undo","fullScreen":"Toggle Full Screen","italic":"Italic","fontName":"Font Name","justifyLeft":"Align Left","unlink":"Remove Link","toggleTableBorder":"Toggle Table Border","viewSource":"View HTML Source","ctrlKey":"ctrl+${0}","fontSize":"Font Size","systemShortcut":"The \"${0}\" action is only available in your browser using a keyboard shortcut. Use ${1}.","indent":"Indent","redo":"Redo","strikethrough":"Strikethrough","justifyFull":"Justify","justifyCenter":"Align Center","hiliteColor":"Background Color","deleteTable":"Delete Table","outdent":"Outdent","cut":"Cut","plainFormatBlock":"Paragraph Style","toggleDir":"Toggle Direction","bold":"Bold","tabIndent":"Tab Indent","justifyRight":"Align Right"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/cs/FontChoice.js b/lib/dijit/_editor/nls/cs/FontChoice.js new file mode 100644 index 000000000..447fe6685 --- /dev/null +++ b/lib/dijit/_editor/nls/cs/FontChoice.js @@ -0,0 +1 @@ +({"1":"extra malé","2":"velmi malé","formatBlock":"Formát","3":"malé","4":"střední","5":"velké","6":"velmi velké","7":"extra velké","fantasy":"fantasy","serif":"serif","p":"Odstavec","pre":"Předformátované","sans-serif":"sans-serif","fontName":"Písmo","h1":"Nadpis","h2":"Podnadpis","h3":"Podnadpis 2","monospace":"monospace","fontSize":"Velikost","cursive":"cursive","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/cs/LinkDialog.js b/lib/dijit/_editor/nls/cs/LinkDialog.js new file mode 100644 index 000000000..41dad34f6 --- /dev/null +++ b/lib/dijit/_editor/nls/cs/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Popis:","insertImageTitle":"Vlastnosti obrázku","set":"Nastavit","newWindow":"Nové okno","topWindow":"Okno nejvyšší úrovně","target":"Cíl:","createLinkTitle":"Vlastnosti odkazu","parentWindow":"Nadřízené okno","currentWindow":"Aktuální okno","url":"Adresa URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/cs/commands.js b/lib/dijit/_editor/nls/cs/commands.js new file mode 100644 index 000000000..ce515587c --- /dev/null +++ b/lib/dijit/_editor/nls/cs/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Odebrat formát","copy":"Kopírovat","paste":"Vložit","selectAll":"Vybrat vše","insertOrderedList":"Číslovaný seznam","insertTable":"Vložit/upravit tabulku","print":"Tisk","underline":"Podtržení","foreColor":"Barva popředí","htmlToggle":"Zdroj HTML","formatBlock":"Styl odstavce","newPage":"Nová stránka","insertHorizontalRule":"Vodorovná čára","delete":"Odstranit","insertUnorderedList":"Seznam s odrážkami","tableProp":"Vlastnost tabulky","insertImage":"Vložit obrázek","superscript":"Horní index","subscript":"Dolní index","createLink":"Vytvořit odkaz","undo":"Zpět","fullScreen":"Přepnout režim celé obrazovky","italic":"Kurzíva","fontName":"Název písma","justifyLeft":"Zarovnat vlevo","unlink":"Odebrat odkaz","toggleTableBorder":"Přepnout ohraničení tabulky","viewSource":"Zobrazit zdroj ve formátu HTML","fontSize":"Velikost písma","systemShortcut":"Akce \"${0}\" je v prohlížeči dostupná pouze prostřednictvím klávesové zkratky. Použijte klávesovou zkratku ${1}.","indent":"Odsadit","redo":"Opakovat","strikethrough":"Přeškrtnutí","justifyFull":"Do bloku","justifyCenter":"Zarovnat na střed","hiliteColor":"Barva pozadí","deleteTable":"Odstranit tabulku","outdent":"Předsadit","cut":"Vyjmout","plainFormatBlock":"Styl odstavce","toggleDir":"Přepnout směr","bold":"Tučné","tabIndent":"Odsazení tabulátoru","justifyRight":"Zarovnat vpravo","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/da/FontChoice.js b/lib/dijit/_editor/nls/da/FontChoice.js new file mode 100644 index 000000000..5b380ece6 --- /dev/null +++ b/lib/dijit/_editor/nls/da/FontChoice.js @@ -0,0 +1 @@ +({"1":"xx-small","2":"x-small","formatBlock":"Format","3":"small","4":"medium","5":"large","6":"x-large","7":"xx-large","fantasy":"fantasy","serif":"serif","p":"Afsnit","pre":"Forudformateret","sans-serif":"sans-serif","fontName":"Skrifttype","h1":"Overskrift","h2":"Underoverskrift","h3":"Underunderoverskrift","monospace":"monospace","fontSize":"Størrelse","cursive":"kursiv","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/da/LinkDialog.js b/lib/dijit/_editor/nls/da/LinkDialog.js new file mode 100644 index 000000000..9b757f75d --- /dev/null +++ b/lib/dijit/_editor/nls/da/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Beskrivelse:","insertImageTitle":"Billedegenskaber","set":"Definér","newWindow":"Nyt vindue","topWindow":"Øverste vindue","target":"Mål:","createLinkTitle":"Linkegenskaber","parentWindow":"Overordnet vindue","currentWindow":"Aktuelt vindue","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/da/commands.js b/lib/dijit/_editor/nls/da/commands.js new file mode 100644 index 000000000..d2d93547e --- /dev/null +++ b/lib/dijit/_editor/nls/da/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Fjern format","copy":"Kopiér","paste":"Sæt ind","selectAll":"Markér alle","insertOrderedList":"Nummereret liste","insertTable":"Indsæt/redigér tabel","print":"Udskriv","underline":"Understreget","foreColor":"Forgrundsfarve","htmlToggle":"HTML-kilde","formatBlock":"Afsnitstypografi","newPage":"Ny side","insertHorizontalRule":"Vandret linje","delete":"Slet","insertUnorderedList":"Punktliste","tableProp":"Tabelegenskab","insertImage":"Indsæt billede","superscript":"Hævet skrift","subscript":"Sænket skrift","createLink":"Opret link","undo":"Fortryd","fullScreen":"Aktivér/deaktivér fuldskærm","italic":"Kursiv","fontName":"Skriftnavn","justifyLeft":"Venstrejusteret","unlink":"Fjern link","toggleTableBorder":"Skift tabelramme","viewSource":"Vis HTML-kilde","ctrlKey":"Ctrl+${0}","fontSize":"Skriftstørrelse","systemShortcut":"Funktionen \"${0}\" kan kun bruges i din browser med en tastaturgenvej. Brug ${1}.","indent":"Indrykning","redo":"Annullér Fortryd","strikethrough":"Gennemstreget","justifyFull":"Lige margener","justifyCenter":"Centreret","hiliteColor":"Baggrundsfarve","deleteTable":"Slet tabel","outdent":"Udrykning","cut":"Klip","plainFormatBlock":"Afsnitstypografi","toggleDir":"Skift retning","bold":"Fed","tabIndent":"Indrykning med tabulator","justifyRight":"Højrejusteret","appleKey":"⌘${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/de/FontChoice.js b/lib/dijit/_editor/nls/de/FontChoice.js new file mode 100644 index 000000000..ed65ff3e7 --- /dev/null +++ b/lib/dijit/_editor/nls/de/FontChoice.js @@ -0,0 +1 @@ +({"1":"XXS","2":"XS","formatBlock":"Format","3":"S","4":"M","5":"L","6":"XL","7":"XXL","fantasy":"Fantasie","serif":"Serife","p":"Absatz","pre":"Vorformatiert","sans-serif":"Serifenlos","fontName":"Schriftart","h1":"Überschrift","h2":"Unterüberschrift","h3":"Unterunterüberschrift","monospace":"Monospaceschrift","fontSize":"Größe","cursive":"Kursiv","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/de/LinkDialog.js b/lib/dijit/_editor/nls/de/LinkDialog.js new file mode 100644 index 000000000..b1eab6cb4 --- /dev/null +++ b/lib/dijit/_editor/nls/de/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Beschreibung:","insertImageTitle":"Grafikeigenschaften","set":"Festlegen","newWindow":"Neues Fenster","topWindow":"Aktives Fenster","target":"Ziel:","createLinkTitle":"Linkeigenschaften","parentWindow":"Übergeordnetes Fenster","currentWindow":"Aktuelles Fenster","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/de/commands.js b/lib/dijit/_editor/nls/de/commands.js new file mode 100644 index 000000000..8fa589cc7 --- /dev/null +++ b/lib/dijit/_editor/nls/de/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Formatierung entfernen","copy":"Kopieren","paste":"Einfügen","selectAll":"Alles auswählen","insertOrderedList":"Nummerierung","insertTable":"Tabelle einfügen/bearbeiten","print":"Drucken","underline":"Unterstrichen","foreColor":"Vordergrundfarbe","htmlToggle":"HTML-Quelltext","formatBlock":"Absatzstil","newPage":"Neue Seite","insertHorizontalRule":"Horizontaler Strich","delete":"Löschen","insertUnorderedList":"Aufzählungszeichen","tableProp":"Tabelleneigenschaft","insertImage":"Grafik einfügen","superscript":"Hochgestellt","subscript":"Tiefgestellt","createLink":"Link erstellen","undo":"Rückgängig","fullScreen":"Gesamtanzeige","italic":"Kursiv","fontName":"Schriftartname","justifyLeft":"Linksbündig","unlink":"Link entfernen","toggleTableBorder":"Tabellenumrandung ein-/ausschalten","viewSource":"HTML-Quelle","ctrlKey":"Strg+${0}","fontSize":"Schriftgröße","systemShortcut":"Die Aktion \"${0}\" ist nur über einen Direktaufruf in Ihrem Browser verfügbar. Verwenden Sie ${1}.","indent":"Einrücken","redo":"Wiederherstellen","strikethrough":"Durchgestrichen","justifyFull":"Blocksatz","justifyCenter":"Zentriert","hiliteColor":"Hintergrundfarbe","deleteTable":"Tabelle löschen","outdent":"Ausrücken","cut":"Ausschneiden","plainFormatBlock":"Absatzstil","toggleDir":"Wechselrichtung","bold":"Fett","tabIndent":"Tabulatoreinrückung","justifyRight":"Rechtsbündig","appleKey":"⌘${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/el/FontChoice.js b/lib/dijit/_editor/nls/el/FontChoice.js new file mode 100644 index 000000000..13c661c63 --- /dev/null +++ b/lib/dijit/_editor/nls/el/FontChoice.js @@ -0,0 +1 @@ +({"1":"xx-μικρά","2":"x-μικρά","formatBlock":"Μορφή","3":"μικρά","4":"μεσαία","5":"μεγάλα","6":"x-μεγάλα","7":"xx-μεγάλα","fantasy":"φαντασίας","serif":"με πατούρες (serif)","p":"Παράγραφος","pre":"Προ-μορφοποιημένο","sans-serif":"χωρίς πατούρες (sans-serif)","fontName":"Γραμματοσειρά","h1":"Επικεφαλίδα","h2":"Δευτερεύουσα επικεφαλίδα","h3":"Δευτερεύουσα επικεφαλίδα τρίτου επιπέδου","monospace":"σταθερού πλάτους","fontSize":"Μέγεθος","cursive":"πλάγιοι","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/el/LinkDialog.js b/lib/dijit/_editor/nls/el/LinkDialog.js new file mode 100644 index 000000000..8a1e121e8 --- /dev/null +++ b/lib/dijit/_editor/nls/el/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Περιγραφή:","insertImageTitle":"Ιδιότητες εικόνας","set":"Ορισμός","newWindow":"Νέο παράθυρο","topWindow":"Παράθυρο σε πρώτο πλάνο","target":"Προορισμός:","createLinkTitle":"Ιδιότητες σύνδεσης","parentWindow":"Γονικό παράθυρο","currentWindow":"Τρέχον παράθυρο","url":"Διεύθυνση URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/el/commands.js b/lib/dijit/_editor/nls/el/commands.js new file mode 100644 index 000000000..dc8540574 --- /dev/null +++ b/lib/dijit/_editor/nls/el/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Αφαίρεση μορφοποίησης","copy":"Αντιγραφή","paste":"Επικόλληση","selectAll":"Επιλογή όλων","insertOrderedList":"Αριθμημένη λίστα","insertTable":"Εισαγωγή/Τροποποίηση πίνακα","print":"Εκτύπωση","underline":"Υπογράμμιση","foreColor":"Χρώμα προσκηνίου","htmlToggle":"Πρωτογενής κώδικας HTML","formatBlock":"Στυλ παραγράφου","newPage":"Νέα σελίδα","insertHorizontalRule":"Οριζόντια γραμμή","delete":"Διαγραφή","insertUnorderedList":"Λίστα με κουκίδες","tableProp":"Ιδιότητα πίνακα","insertImage":"Εισαγωγή εικόνας","superscript":"Εκθέτης","subscript":"Δείκτης","createLink":"Δημιουργία σύνδεσης","undo":"Αναίρεση","fullScreen":"Εναλλαγή κατάστασης πλήρους οθόνης","italic":"Πλάγια","fontName":"Όνομα γραμματοσειράς","justifyLeft":"Στοίχιση αριστερά","unlink":"Αφαίρεση σύνδεσης","toggleTableBorder":"Εναλλαγή εμφάνισης περιγράμματος πίνακα","viewSource":"Προβολή προέλευσης HTML","fontSize":"Μέγεθος γραμματοσειράς","systemShortcut":"Σε αυτό το πρόγραμμα πλοήγησης, η ενέργεια \"${0}\" είναι διαθέσιμη μόνο με τη χρήση μιας συντόμευσης πληκτρολογίου. Χρησιμοποιήστε τη συντόμευση ${1}.","indent":"Εσοχή","redo":"Ακύρωση αναίρεσης","strikethrough":"Διαγράμμιση","justifyFull":"Πλήρης στοίχιση","justifyCenter":"Στοίχιση στο κέντρο","hiliteColor":"Χρώμα φόντου","deleteTable":"Διαγραφή πίνακα","outdent":"Μείωση περιθωρίου","cut":"Αποκοπή","plainFormatBlock":"Στυλ παραγράφου","toggleDir":"Εναλλαγή κατεύθυνσης","bold":"Έντονα","tabIndent":"Εσοχή με το πλήκτρο Tab","justifyRight":"Στοίχιση δεξιά","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/es/FontChoice.js b/lib/dijit/_editor/nls/es/FontChoice.js new file mode 100644 index 000000000..905a5609a --- /dev/null +++ b/lib/dijit/_editor/nls/es/FontChoice.js @@ -0,0 +1 @@ +({"1":"xx-pequeño","2":"x-pequeño","formatBlock":"Formato","3":"pequeño","4":"medio","5":"grande","6":"x-grande","7":"xx-grande","fantasy":"fantasía","serif":"serif","p":"Párrafo","pre":"Preformateado","sans-serif":"sans-serif","fontName":"Font","h1":"Cabecera","h2":"Subcabecera","h3":"Sub-subcabecera","monospace":"espacio sencillo","fontSize":"Tamaño","cursive":"cursiva","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/es/LinkDialog.js b/lib/dijit/_editor/nls/es/LinkDialog.js new file mode 100644 index 000000000..15802d77a --- /dev/null +++ b/lib/dijit/_editor/nls/es/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Descripción: ","insertImageTitle":"Propiedades de la imagen","set":"Establecer","newWindow":"Nueva ventana","topWindow":"Ventana superior","target":"Destino: ","createLinkTitle":"Propiedades del enlace","parentWindow":"Ventana padre","currentWindow":"Ventana actual","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/es/commands.js b/lib/dijit/_editor/nls/es/commands.js new file mode 100644 index 000000000..0d189dc8d --- /dev/null +++ b/lib/dijit/_editor/nls/es/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Eliminar formato","copy":"Copiar","paste":"Pegar","selectAll":"Seleccionar todo","insertOrderedList":"Lista numerada","insertTable":"Insertar/Editar tabla","print":"Imprimir","underline":"Subrayado","foreColor":"Color de primer plano","htmlToggle":"Fuente HTML","formatBlock":"Estilo de párrafo","newPage":"Nueva página","insertHorizontalRule":"Regla horizontal","delete":"Suprimir","insertUnorderedList":"Lista con viñetas","tableProp":"Propiedad de tabla","insertImage":"Insertar imagen","superscript":"Superíndice","subscript":"Subíndice","createLink":"Crear enlace","undo":"Deshacer","fullScreen":"Conmutar pantalla completa","italic":"Cursiva","fontName":"Nombre de font","justifyLeft":"Alinear izquierda","unlink":"Eliminar enlace","toggleTableBorder":"Conmutar borde de tabla","viewSource":"Ver fuente HTML","ctrlKey":"control+${0}","fontSize":"Tamaño de font","systemShortcut":"La acción \"${0}\" sólo está disponible en su navegador mediante un atajo de teclado. Utilice ${1}.","indent":"Sangría","redo":"Rehacer","strikethrough":"Tachado","justifyFull":"Justificar","justifyCenter":"Alinear centro","hiliteColor":"Color de segundo plano","deleteTable":"Suprimir tabla","outdent":"Anular sangría","cut":"Cortar","plainFormatBlock":"Estilo de párrafo","toggleDir":"Conmutar dirección","bold":"Negrita","tabIndent":"Sangría de tabulador","justifyRight":"Alinear derecha","appleKey":"⌘${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/fi/FontChoice.js b/lib/dijit/_editor/nls/fi/FontChoice.js new file mode 100644 index 000000000..7107971c7 --- /dev/null +++ b/lib/dijit/_editor/nls/fi/FontChoice.js @@ -0,0 +1 @@ +({"1":"xx-small","2":"x-small","formatBlock":"Muoto","3":"small","4":"medium","5":"large","6":"x-large","7":"xx-large","fantasy":"fantasy","serif":"serif","p":"Kappale","pre":"Esimuotoiltu","sans-serif":"sans-serif","fontName":"Fontti","h1":"Otsikko","h2":"Alatason otsikko","h3":"Alimman tason otsikko","monospace":"monospace","fontSize":"Koko","cursive":"cursive","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/fi/LinkDialog.js b/lib/dijit/_editor/nls/fi/LinkDialog.js new file mode 100644 index 000000000..817dfe875 --- /dev/null +++ b/lib/dijit/_editor/nls/fi/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Kuvaus:","insertImageTitle":"Kuvan ominaisuudet","set":"Aseta","newWindow":"Uusi ikkuna","topWindow":"Päällimmäinen ikkuna","target":"Kohde:","createLinkTitle":"Linkin ominaisuudet","parentWindow":"Pääikkuna","currentWindow":"Nykyinen ikkuna","url":"URL-osoite:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/fi/commands.js b/lib/dijit/_editor/nls/fi/commands.js new file mode 100644 index 000000000..b67d4ae62 --- /dev/null +++ b/lib/dijit/_editor/nls/fi/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Poista muotoilu","copy":"Kopioi","paste":"Liitä","selectAll":"Valitse kaikki","insertOrderedList":"Numeroitu luettelo","insertTable":"Lisää taulukko/muokkaa taulukkoa","print":"Tulosta","underline":"Alleviivaus","foreColor":"Edustaväri","htmlToggle":"HTML-lähde","formatBlock":"Kappaletyyli","newPage":"Uusi sivu","insertHorizontalRule":"Vaakasuuntainen viiva","delete":"Poista","insertUnorderedList":"Numeroimaton luettelo","tableProp":"Taulukon ominaisuudet","insertImage":"Lisää kuva","superscript":"Yläindeksi","subscript":"Alaindeksi","createLink":"Luo linkki","undo":"Kumoa","fullScreen":"Vaihda koko näyttö","italic":"Kursivointi","fontName":"Fontin nimi","justifyLeft":"Tasaus vasemmalle","unlink":"Poista linkki","toggleTableBorder":"Ota taulukon kehys käyttöön/poista kehys käytöstä","viewSource":"Näytä HTML-lähde","fontSize":"Fontin koko","systemShortcut":"Toiminto \"${0}\" on käytettävissä selaimessa vain näppäimistön pikatoiminnolla. Käytä seuraavaa: ${1}.","indent":"Sisennä","redo":"Tee uudelleen","strikethrough":"Yliviivaus","justifyFull":"Tasaus","justifyCenter":"Tasaus keskelle","hiliteColor":"Taustaväri","deleteTable":"Poista taulukko","outdent":"Ulonna","cut":"Leikkaa","plainFormatBlock":"Kappaletyyli","toggleDir":"Vaihda suuntaa","bold":"Lihavointi","tabIndent":"Sarkainsisennys","justifyRight":"Tasaus oikealle","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/fr/FontChoice.js b/lib/dijit/_editor/nls/fr/FontChoice.js new file mode 100644 index 000000000..a96fac045 --- /dev/null +++ b/lib/dijit/_editor/nls/fr/FontChoice.js @@ -0,0 +1 @@ +({"1":"xxs","2":"xs","formatBlock":"Mise en forme","3":"s","4":"m","5":"l","6":"xl","7":"xxl","fantasy":"fantaisie","serif":"serif","p":"Paragraphe","pre":"Pré-mise en forme","sans-serif":"sans serif","fontName":"Police","h1":"En-tête","h2":"Sous-en-tête","h3":"Sous-sous-en-tête","monospace":"espacement fixe","fontSize":"Taille","cursive":"cursive","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/fr/LinkDialog.js b/lib/dijit/_editor/nls/fr/LinkDialog.js new file mode 100644 index 000000000..70946013a --- /dev/null +++ b/lib/dijit/_editor/nls/fr/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Description :","insertImageTitle":"Propriétés des images","set":"Définir","newWindow":"Nouvelle fenêtre","topWindow":"Première fenêtre","target":"Cible :","createLinkTitle":"Propriétés des liens","parentWindow":"Fenêtre parent","currentWindow":"Fenêtre en cours","url":"URL :"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/fr/commands.js b/lib/dijit/_editor/nls/fr/commands.js new file mode 100644 index 000000000..df8cb3b92 --- /dev/null +++ b/lib/dijit/_editor/nls/fr/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Supprimer la mise en forme","copy":"Copier","paste":"Coller","selectAll":"Sélectionner tout","insertOrderedList":"Liste numérotée","insertTable":"Insérer/Modifier un tableau","print":"Imprimer","underline":"Souligner","foreColor":"Couleur avant-plan","htmlToggle":"Source HTML","formatBlock":"Style de paragraphe","newPage":"Nouvelle page","insertHorizontalRule":"Règle horizontale","delete":"Supprimer","insertUnorderedList":"Liste à puces","tableProp":"Propriété du tableau","insertImage":"Insérer une image","superscript":"Exposant","subscript":"Indice","createLink":"Créer un lien","undo":"Annuler","fullScreen":"Basculer vers le mode plein écran","italic":"Italique","fontName":"Nom de police","justifyLeft":"Aligner à gauche","unlink":"Supprimer le lien","toggleTableBorder":"Afficher/Masquer la bordure du tableau","viewSource":"Afficher la source HTML","fontSize":"Taille de police","systemShortcut":"Action \"${0}\" uniquement disponible dans votre navigateur via un raccourci clavier. Utilisez ${1}.","indent":"Retrait","redo":"Rétablir","strikethrough":"Barrer","justifyFull":"Justifier","justifyCenter":"Aligner au centre","hiliteColor":"Couleur arrière-plan","deleteTable":"Supprimer le tableau","outdent":"Retrait négatif","cut":"Couper","plainFormatBlock":"Style de paragraphe","toggleDir":"Changer de sens","bold":"Gras","tabIndent":"Retrait de tabulation","justifyRight":"Aligner à droite","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/he/FontChoice.js b/lib/dijit/_editor/nls/he/FontChoice.js new file mode 100644 index 000000000..37140fb00 --- /dev/null +++ b/lib/dijit/_editor/nls/he/FontChoice.js @@ -0,0 +1 @@ +({"1":"קטן ביות","2":"קטן מאוד","formatBlock":"עיצוב","3":"קטן","4":"בינוני","5":"גדול","6":"גדול מאוד","7":"גדול ביותר","fantasy":"fantasy","serif":"serif","p":"פיסקה","pre":"מעוצב מראש","sans-serif":"sans-serif","fontName":"גופן","h1":"כותרת","h2":"תת-כותרת","h3":"תת-תת-כותרת","monospace":"monospace","fontSize":"גודל","cursive":"cursive","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/he/LinkDialog.js b/lib/dijit/_editor/nls/he/LinkDialog.js new file mode 100644 index 000000000..7b75850de --- /dev/null +++ b/lib/dijit/_editor/nls/he/LinkDialog.js @@ -0,0 +1 @@ +({"text":"תיאור:","insertImageTitle":"תכונות תמונה","set":"הגדרה","newWindow":"חלון חדש","topWindow":"חלון עליון ","target":"יעד:","createLinkTitle":"תכונות קישור","parentWindow":"חלון אב","currentWindow":"חלון נוכחי ","url":"URL:‏"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/he/commands.js b/lib/dijit/_editor/nls/he/commands.js new file mode 100644 index 000000000..75e95ab3e --- /dev/null +++ b/lib/dijit/_editor/nls/he/commands.js @@ -0,0 +1 @@ +({"removeFormat":"סילוק עיצוב","copy":"עותק","paste":"הדבקה","selectAll":"בחירת הכל","insertOrderedList":"רשימה ממוספרת","insertTable":"הוספת/עריכת טבלה","print":"הדפסה","underline":"קו תחתי","foreColor":"צבע חזית","htmlToggle":"מקור HTML","formatBlock":"סגנון פיסקה","newPage":"דף חדש ","insertHorizontalRule":"קו אופקי","delete":"מחיקה","appleKey":"⌘${0}‎","insertUnorderedList":"רשימה עם תבליטים","tableProp":"תכונת טבלה","insertImage":"הוספת תמונה","superscript":"כתב עילי","subscript":"כתב תחתי","createLink":"יצירת קישור","undo":"ביטול פעולה","fullScreen":"מיתוג מסך מלא ","italic":"נטוי","fontName":"שם גופן","justifyLeft":"יישור לשמאל","unlink":"סילוק הקישור","toggleTableBorder":"מיתוג גבול טבלה","viewSource":"הצגת מקור HTML ","ctrlKey":"ctrl+${0}‎","fontSize":"גופן יחסי","systemShortcut":"הפעולה \"${0}\" זמינה בדפדפן רק באמצעות קיצור דרך במקלדת. השתמשו בקיצור ${1}.","indent":"הגדלת כניסה","redo":"שחזור פעולה","strikethrough":"קו חוצה","justifyFull":"יישור דו-צדדי","justifyCenter":"יישור למרכז","hiliteColor":"צבע רקע","deleteTable":"מחיקת טבלה","outdent":"הקטנת כניסה","cut":"גזירה","plainFormatBlock":"סגנון פיסקה","toggleDir":"מיתוג כיוון","bold":"מודגש","tabIndent":"כניסת טאב","justifyRight":"יישור לימין"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/hu/FontChoice.js b/lib/dijit/_editor/nls/hu/FontChoice.js new file mode 100644 index 000000000..7b67d13e9 --- /dev/null +++ b/lib/dijit/_editor/nls/hu/FontChoice.js @@ -0,0 +1 @@ +({"1":"xx-kicsi","2":"x-kicsi","formatBlock":"Formátum","3":"kicsi","4":"közepes","5":"nagy","6":"x-nagy","7":"xx-nagy","fantasy":"fantázia","serif":"talpas","p":"Bekezdés","pre":"Előformázott","sans-serif":"talpatlan","fontName":"Betűtípus","h1":"Címsor","h2":"Alcím","h3":"Al-alcím","monospace":"rögzített szélességű","fontSize":"Méret","cursive":"kurzív","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/hu/LinkDialog.js b/lib/dijit/_editor/nls/hu/LinkDialog.js new file mode 100644 index 000000000..23f765ef6 --- /dev/null +++ b/lib/dijit/_editor/nls/hu/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Leírás:","insertImageTitle":"Kép tulajdonságai","set":"Beállítás","newWindow":"Új ablak","topWindow":"Legfelső szintű ablak","target":"Cél:","createLinkTitle":"Hivatkozás tulajdonságai","parentWindow":"Szülő ablak","currentWindow":"Aktuális ablak","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/hu/commands.js b/lib/dijit/_editor/nls/hu/commands.js new file mode 100644 index 000000000..bd016cf92 --- /dev/null +++ b/lib/dijit/_editor/nls/hu/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Formázás eltávolítása","copy":"Másolás","paste":"Beillesztés","selectAll":"Összes kijelölése","insertOrderedList":"Számozott lista","insertTable":"Táblázat beszúrása/szerkesztése","print":"Nyomtatás","underline":"Aláhúzott","foreColor":"Előtérszín","htmlToggle":"HTML forrás","formatBlock":"Bekezdés stílusa","newPage":"Új oldal","insertHorizontalRule":"Vízszintes vonalzó","delete":"Törlés","insertUnorderedList":"Felsorolásjeles lista","tableProp":"Táblázat tulajdonságai","insertImage":"Kép beszúrása","superscript":"Felső index","subscript":"Alsó index","createLink":"Hivatkozás létrehozása","undo":"Visszavonás","fullScreen":"Váltás teljes képernyőre","italic":"Dőlt","fontName":"Betűtípus","justifyLeft":"Balra igazítás","unlink":"Hivatkozás eltávolítása","toggleTableBorder":"Táblázatszegély ki-/bekapcsolása","viewSource":"HTML forrás megjelenítése","fontSize":"Betűméret","systemShortcut":"A(z) \"${0}\" művelet a böngészőben csak billentyűparancs használatával érhető el. Használja a következőt: ${1}.","indent":"Behúzás","redo":"Újra","strikethrough":"Áthúzott","justifyFull":"Sorkizárás","justifyCenter":"Középre igazítás","hiliteColor":"Háttérszín","deleteTable":"Táblázat törlése","outdent":"Negatív behúzás","cut":"Kivágás","plainFormatBlock":"Bekezdés stílusa","toggleDir":"Irány váltókapcsoló","bold":"Félkövér","tabIndent":"Tab behúzás","justifyRight":"Jobbra igazítás","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/it/FontChoice.js b/lib/dijit/_editor/nls/it/FontChoice.js new file mode 100644 index 000000000..50f234087 --- /dev/null +++ b/lib/dijit/_editor/nls/it/FontChoice.js @@ -0,0 +1 @@ +({"1":"xx-small","2":"x-small","formatBlock":"Formato","3":"small","4":"medium","5":"large","6":"x-large","7":"xx-large","fantasy":"fantasy","serif":"serif","p":"Paragrafo","pre":"Preformattato","sans-serif":"sans-serif","fontName":"Carattere","h1":"Intestazione","h2":"Sottointestazione","h3":"Sottointestazione secondaria","monospace":"spaziatura fissa","fontSize":"Dimensione","cursive":"corsivo","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/it/LinkDialog.js b/lib/dijit/_editor/nls/it/LinkDialog.js new file mode 100644 index 000000000..ad3adef0e --- /dev/null +++ b/lib/dijit/_editor/nls/it/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Descrizione:","insertImageTitle":"Proprietà immagine","set":"Imposta","newWindow":"Nuova finestra","topWindow":"Finestra superiore","target":"Destinazione:","createLinkTitle":"Proprietà collegamento","parentWindow":"Finestra padre","currentWindow":"Finestra corrente","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/it/commands.js b/lib/dijit/_editor/nls/it/commands.js new file mode 100644 index 000000000..4abbd7ec8 --- /dev/null +++ b/lib/dijit/_editor/nls/it/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Rimuovi formato","copy":"Copia","paste":"Incolla","selectAll":"Seleziona tutto","insertOrderedList":"Elenco numerato","insertTable":"Inserisci/Modifica tabella","print":"Stampa","underline":"Sottolinea","foreColor":"Colore primo piano","htmlToggle":"Origine HTML","formatBlock":"Stile paragrafo","newPage":"Nuova pagina","insertHorizontalRule":"Righello orizzontale","delete":"Elimina","insertUnorderedList":"Elenco puntato","tableProp":"Proprietà tabella","insertImage":"Inserisci immagine","superscript":"Apice","subscript":"Pedice","createLink":"Crea collegamento","undo":"Annulla","fullScreen":"Attiva/Disattiva schermo intero","italic":"Corsivo","fontName":"Nome carattere","justifyLeft":"Allinea a sinistra","unlink":"Rimuovi collegamento","toggleTableBorder":"Attiva/Disattiva bordo tabella","viewSource":"Visualizza origine HTML","fontSize":"Dimensione carattere","systemShortcut":"La azione \"${0}\" è disponibile solo nel browser tramite un tasto di scelta rapida. Utilizzare ${1}.","indent":"Rientro","redo":"Ripristina","strikethrough":"Barrato","justifyFull":"Giustifica","justifyCenter":"Allinea al centro","hiliteColor":"Colore sfondo","deleteTable":"Elimina tabella","outdent":"Annulla rientro","cut":"Taglia","plainFormatBlock":"Stile paragrafo","toggleDir":"Attiva/Disattiva direzione","bold":"Grassetto","tabIndent":"Rientro tabulazione","justifyRight":"Allinea a destra","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/ja/FontChoice.js b/lib/dijit/_editor/nls/ja/FontChoice.js new file mode 100644 index 000000000..6083ab381 --- /dev/null +++ b/lib/dijit/_editor/nls/ja/FontChoice.js @@ -0,0 +1 @@ +({"1":"超極小","2":"極小","formatBlock":"フォーマット","3":"小","4":"標準","5":"大","6":"特大","7":"超特大","fantasy":"fantasy","serif":"serif","p":"段落","pre":"事前フォーマット済み","sans-serif":"sans-serif","fontName":"フォント","h1":"見出し","h2":"副見出し","h3":"副見出しの副見出し","monospace":"monospace","fontSize":"サイズ","cursive":"cursive","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/ja/LinkDialog.js b/lib/dijit/_editor/nls/ja/LinkDialog.js new file mode 100644 index 000000000..815f5083d --- /dev/null +++ b/lib/dijit/_editor/nls/ja/LinkDialog.js @@ -0,0 +1 @@ +({"text":"説明:","insertImageTitle":"イメージ・プロパティー","set":"設定","newWindow":"新規ウィンドウ","topWindow":"最上位ウィンドウ","target":"ターゲット:","createLinkTitle":"リンク・プロパティー","parentWindow":"親ウィンドウ","currentWindow":"現行ウィンドウ","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/ja/commands.js b/lib/dijit/_editor/nls/ja/commands.js new file mode 100644 index 000000000..618746e23 --- /dev/null +++ b/lib/dijit/_editor/nls/ja/commands.js @@ -0,0 +1 @@ +({"removeFormat":"形式の除去","copy":"コピー","paste":"貼り付け","selectAll":"すべて選択","insertOrderedList":"番号付きリスト","insertTable":"テーブルの挿入/編集","print":"印刷","underline":"下線","foreColor":"前景色","htmlToggle":"HTML ソース","formatBlock":"段落スタイル","newPage":"新しいページ","insertHorizontalRule":"水平罫線","delete":"削除","insertUnorderedList":"黒丸付きリスト","tableProp":"テーブルプロパティ","insertImage":"イメージの挿入","superscript":"上付き文字","subscript":"下付き文字","createLink":"リンクの作成","undo":"元に戻す","fullScreen":"全画面表示に切り替え","italic":"斜体","fontName":"フォント名","justifyLeft":"左揃え","unlink":"リンクの削除","toggleTableBorder":"テーブルボーダーの切り替え","viewSource":"HTML ソースの表示","fontSize":"フォントサイズ","systemShortcut":"\"${0}\" アクションを使用できるのは、ブラウザーでキーボードショートカットを使用する場合のみです。 ${1} を使用してください。","indent":"インデント","redo":"やり直し","strikethrough":"取り消し線","justifyFull":"両端揃え","justifyCenter":"中央揃え","hiliteColor":"背景色","deleteTable":"テーブルの削除","outdent":"アウトデント","cut":"切り取り","plainFormatBlock":"段落スタイル","toggleDir":"方向の切り替え","bold":"太字","tabIndent":"タブインデント","justifyRight":"右揃え","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/ko/FontChoice.js b/lib/dijit/_editor/nls/ko/FontChoice.js new file mode 100644 index 000000000..fda733702 --- /dev/null +++ b/lib/dijit/_editor/nls/ko/FontChoice.js @@ -0,0 +1 @@ +({"1":"가장 작게","2":"조금 작게","formatBlock":"서식","3":"작게","4":"중간","5":"크게","6":"조금 크게","7":"가장 크게","fantasy":"fantasy","serif":"serif","p":"단락","pre":"서식이 지정됨","sans-serif":"sans-serif","fontName":"글꼴","h1":"제목","h2":"부제목","h3":"하위 부제목","monospace":"monospace","fontSize":"크기","cursive":"cursive","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/ko/LinkDialog.js b/lib/dijit/_editor/nls/ko/LinkDialog.js new file mode 100644 index 000000000..1f46bd71f --- /dev/null +++ b/lib/dijit/_editor/nls/ko/LinkDialog.js @@ -0,0 +1 @@ +({"text":"설명:","insertImageTitle":"이미지 특성","set":"설정","newWindow":"새 창","topWindow":"최상위 창","target":"대상:","createLinkTitle":"링크 특성","parentWindow":"상위 창","currentWindow":"현재 창","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/ko/commands.js b/lib/dijit/_editor/nls/ko/commands.js new file mode 100644 index 000000000..4c8f95493 --- /dev/null +++ b/lib/dijit/_editor/nls/ko/commands.js @@ -0,0 +1 @@ +({"removeFormat":"형식 제거","copy":"복사","paste":"붙여넣기","selectAll":"모두 선택","insertOrderedList":"번호 목록","insertTable":"테이블 삽입/편집","print":"인쇄","underline":"밑줄","foreColor":"전경색","htmlToggle":"HTML 소스","formatBlock":"단락 스타일","newPage":"새 페이지","insertHorizontalRule":"수평 자","delete":"삭제","insertUnorderedList":"글머리표 목록","tableProp":"테이블 특성","insertImage":"이미지 삽입","superscript":"위첨자","subscript":"아래첨자","createLink":"링크 작성","undo":"실행 취소","fullScreen":"토글 전체 화면","italic":"기울임체","fontName":"글꼴 이름","justifyLeft":"왼쪽 맞춤","unlink":"링크 제거","toggleTableBorder":"토글 테이블 테두리","viewSource":"HTML 소스 보기","fontSize":"글꼴 크기","systemShortcut":"\"${0}\" 조치는 브라우저에서 키보드 단축키를 이용해서만 사용할 수 있습니다. ${1}을(를) 사용하십시오.","indent":"들여쓰기","redo":"다시 실행","strikethrough":"취소선","justifyFull":"양쪽 맞춤","justifyCenter":"가운데 맞춤","hiliteColor":"배경색","deleteTable":"테이블 삭제","outdent":"내어쓰기","cut":"잘라내기","plainFormatBlock":"단락 스타일","toggleDir":"토글 방향","bold":"굵은체","tabIndent":"탭 들여쓰기","justifyRight":"오른쪽 맞춤","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/nb/FontChoice.js b/lib/dijit/_editor/nls/nb/FontChoice.js new file mode 100644 index 000000000..b1ad6abf2 --- /dev/null +++ b/lib/dijit/_editor/nls/nb/FontChoice.js @@ -0,0 +1 @@ +({"1":"xx-liten","2":"x-liten","formatBlock":"Format","3":"liten","4":"middels","5":"stor","6":"x-stor","7":"xx-stor","fantasy":"fantasi","serif":"serif","p":"Avsnitt","pre":"Forhåndsformatert","sans-serif":"sans-serif","fontName":"Skrift","h1":"Overskrift","h2":"Undertittel","h3":"Under-undertittel","monospace":"monospace","fontSize":"Størrelse","cursive":"kursiv","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/nb/LinkDialog.js b/lib/dijit/_editor/nls/nb/LinkDialog.js new file mode 100644 index 000000000..5a5653cad --- /dev/null +++ b/lib/dijit/_editor/nls/nb/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Beskrivelse:","insertImageTitle":"Bildeegenskaper","set":"Definer","newWindow":"Nytt vindu","topWindow":"Øverste vindu","target":"Mål:","createLinkTitle":"Koblingsegenskaper","parentWindow":"Overordnet vindu","currentWindow":"Gjeldende vindu","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/nb/commands.js b/lib/dijit/_editor/nls/nb/commands.js new file mode 100644 index 000000000..d1f215f52 --- /dev/null +++ b/lib/dijit/_editor/nls/nb/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Fjern format","copy":"Kopier","paste":"Lim inn","selectAll":"Velg alle","insertOrderedList":"Nummerert liste","insertTable":"Sett inn/rediger tabell","print":"Skriv ut","underline":"Understreking","foreColor":"Forgrunnsfarge","htmlToggle":"HTML-kilde","formatBlock":"Avsnittsstil","newPage":"Ny side","insertHorizontalRule":"Vannrett strek","delete":"Slett","insertUnorderedList":"Punktliste","tableProp":"Tabellegenskap","insertImage":"Sett inn bilde","superscript":"Hevet skrift","subscript":"Senket skrift","createLink":"Opprett kobling","undo":"Angre","fullScreen":"Slå på/av full skjerm","italic":"Kursiv","fontName":"Skriftnavn","justifyLeft":"Venstrejuster","unlink":"Fjern kobling","toggleTableBorder":"Bytt tabellkant","viewSource":"Vis HTML-kilde","fontSize":"Skriftstørrelse","systemShortcut":"Handlingen \"${0}\" er bare tilgjengelig i nettleseren ved hjelp av en tastatursnarvei. Bruk ${1}.","indent":"Innrykk","redo":"Gjør om","strikethrough":"Gjennomstreking","justifyFull":"Juster","justifyCenter":"Midtstill","hiliteColor":"Bakgrunnsfarge","deleteTable":"Slett tabell","outdent":"Fjern innrykk","cut":"Klipp ut","plainFormatBlock":"Avsnittsstil","toggleDir":"Bytt retning","bold":"Fet","tabIndent":"Tabulatorinnrykk","justifyRight":"Høyrejuster","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/nl/FontChoice.js b/lib/dijit/_editor/nls/nl/FontChoice.js new file mode 100644 index 000000000..d3d4f19f3 --- /dev/null +++ b/lib/dijit/_editor/nls/nl/FontChoice.js @@ -0,0 +1 @@ +({"1":"xx-klein","2":"x-klein","formatBlock":"Opmaak","3":"klein","4":"gemiddeld","5":"groot","6":"x-groot","7":"xx-groot","fantasy":"fantasy","serif":"serif","p":"Alinea","pre":"Vooraf opgemaakt","sans-serif":"sans-serif","fontName":"Lettertype","h1":"Kop","h2":"Subkop","h3":"Sub-subkop","monospace":"monospace","fontSize":"Grootte","cursive":"cursief","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/nl/LinkDialog.js b/lib/dijit/_editor/nls/nl/LinkDialog.js new file mode 100644 index 000000000..5f4ba588a --- /dev/null +++ b/lib/dijit/_editor/nls/nl/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Beschrijving:","insertImageTitle":"Afbeeldingseigenschappen","set":"Instellen","newWindow":"Nieuw venster","topWindow":"Bovenste venster","target":"Doel:","createLinkTitle":"Linkeigenschappen","parentWindow":"Hoofdvenster","currentWindow":"Huidig venster","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/nl/commands.js b/lib/dijit/_editor/nls/nl/commands.js new file mode 100644 index 000000000..ebc7c9947 --- /dev/null +++ b/lib/dijit/_editor/nls/nl/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Opmaak verwijderen","copy":"Kopiëren","paste":"Plakken","selectAll":"Alles selecteren","insertOrderedList":"Genummerde lijst","insertTable":"Tabel invoegen/bewerken","print":"Afdrukken","underline":"Onderstrepen","foreColor":"Voorgrondkleur","htmlToggle":"HTML-bron","formatBlock":"Alineastijl","newPage":"Nieuwe pagina","insertHorizontalRule":"Horizontale liniaal","delete":"Wissen","insertUnorderedList":"Lijst met opsommingstekens","tableProp":"Tabeleigenschap","insertImage":"Afbeelding invoegen","superscript":"Superscript","subscript":"Subscript","createLink":"Link maken","undo":"Ongedaan maken","fullScreen":"Volledig scherm in-/uitschakelen","italic":"Cursief","fontName":"Lettertype","justifyLeft":"Links uitlijnen","unlink":"Link verwijderen","toggleTableBorder":"Tabelkader wijzigen","viewSource":"HTML-bron bekijken","fontSize":"Lettergrootte","systemShortcut":"De actie \"${0}\" is alleen beschikbaar in uw browser via een sneltoetscombinatie. Gebruik ${1}.","indent":"Inspringen","redo":"Opnieuw","strikethrough":"Doorhalen","justifyFull":"Uitvullen","justifyCenter":"Centreren","hiliteColor":"Achtergrondkleur","deleteTable":"Tabel wissen","outdent":"Uitspringen","cut":"Knippen","plainFormatBlock":"Alineastijl","toggleDir":"Schrijfrichting wijzigen","bold":"Vet","tabIndent":"Inspringen","justifyRight":"Rechts uitlijnen","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/pl/FontChoice.js b/lib/dijit/_editor/nls/pl/FontChoice.js new file mode 100644 index 000000000..8beb6bf63 --- /dev/null +++ b/lib/dijit/_editor/nls/pl/FontChoice.js @@ -0,0 +1 @@ +({"1":"najmniejsza","2":"mniejsza","formatBlock":"Format","3":"mała","4":"średnia","5":"duża","6":"większa","7":"największa","fantasy":"fantazyjna","serif":"szeryfowa","p":"Akapit","pre":"Wstępnie sformatowane","sans-serif":"bezszeryfowa","fontName":"Czcionka","h1":"Nagłówek","h2":"Nagłówek 2-go poziomu","h3":"Nagłówek 3-go poziomu","monospace":"czcionka o stałej szerokości","fontSize":"Wielkość","cursive":"kursywa","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/pl/LinkDialog.js b/lib/dijit/_editor/nls/pl/LinkDialog.js new file mode 100644 index 000000000..86f71e53c --- /dev/null +++ b/lib/dijit/_editor/nls/pl/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Opis:","insertImageTitle":"Właściwości obrazu","set":"Ustaw","newWindow":"Nowe okno","topWindow":"Okno najwyższego poziomu","target":"Cel:","createLinkTitle":"Właściwości odsyłacza","parentWindow":"Okno macierzyste","currentWindow":"Bieżące okno","url":"Adres URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/pl/commands.js b/lib/dijit/_editor/nls/pl/commands.js new file mode 100644 index 000000000..8ee8acfa9 --- /dev/null +++ b/lib/dijit/_editor/nls/pl/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Usuń formatowanie","copy":"Kopiuj","paste":"Wklej","selectAll":"Wybierz wszystko","insertOrderedList":"Lista numerowana","insertTable":"Wstaw/edytuj tabelę","print":"Drukuj","underline":"Podkreślenie","foreColor":"Kolor pierwszego planu","htmlToggle":"Źródło HTML","formatBlock":"Styl akapitu","newPage":"Nowa strona","insertHorizontalRule":"Linia pozioma","delete":"Usuń","insertUnorderedList":"Lista wypunktowana","tableProp":"Właściwość tabeli","insertImage":"Wstaw obraz","superscript":"Indeks górny","subscript":"Indeks dolny","createLink":"Utwórz odsyłacz","undo":"Cofnij","fullScreen":"Przełącz pełny ekran","italic":"Kursywa","fontName":"Nazwa czcionki","justifyLeft":"Wyrównaj do lewej","unlink":"Usuń odsyłacz","toggleTableBorder":"Przełącz ramkę tabeli","viewSource":"Wyświetl kod źródłowy HTML","ctrlKey":"Ctrl+${0}","fontSize":"Wielkość czcionki","systemShortcut":"Działanie ${0} jest dostępne w tej przeglądarce wyłącznie przy użyciu skrótu klawiaturowego. Należy użyć klawiszy ${1}.","indent":"Wcięcie","redo":"Ponów","strikethrough":"Przekreślenie","justifyFull":"Wyrównaj do lewej i prawej","justifyCenter":"Wyrównaj do środka","hiliteColor":"Kolor tła","deleteTable":"Usuń tabelę","outdent":"Usuń wcięcie","cut":"Wytnij","plainFormatBlock":"Styl akapitu","toggleDir":"Przełącz kierunek","bold":"Pogrubienie","tabIndent":"Wcięcie o tabulator","justifyRight":"Wyrównaj do prawej","appleKey":"⌘${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/pt-pt/FontChoice.js b/lib/dijit/_editor/nls/pt-pt/FontChoice.js new file mode 100644 index 000000000..dec5354e1 --- /dev/null +++ b/lib/dijit/_editor/nls/pt-pt/FontChoice.js @@ -0,0 +1 @@ +({"1":"xxs","2":"xs","formatBlock":"Formato","3":"small","4":"medium","5":"large","6":"xl","7":"xxl","fantasy":"fantasy","serif":"serif","p":"Parágrafo","pre":"Pré-formatado","sans-serif":"sans-serif","fontName":"Tipo de letra","h1":"Título","h2":"Sub-título","h3":"Sub-subtítulo","monospace":"monospace","fontSize":"Tamanho","cursive":"cursive","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/pt-pt/LinkDialog.js b/lib/dijit/_editor/nls/pt-pt/LinkDialog.js new file mode 100644 index 000000000..4499fa7c0 --- /dev/null +++ b/lib/dijit/_editor/nls/pt-pt/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Descrição:","insertImageTitle":"Propriedades da imagem","set":"Definir","newWindow":"Nova janela","topWindow":"Janela superior","target":"Destino:","createLinkTitle":"Propriedades da ligação","parentWindow":"Janela ascendente","currentWindow":"Janela actual","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/pt-pt/commands.js b/lib/dijit/_editor/nls/pt-pt/commands.js new file mode 100644 index 000000000..fbf5182ef --- /dev/null +++ b/lib/dijit/_editor/nls/pt-pt/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Remover formato","copy":"Copiar","paste":"Colar","selectAll":"Seleccionar tudo","insertOrderedList":"Lista numerada","insertTable":"Inserir/Editar tabela","print":"Imprimir","underline":"Sublinhado","foreColor":"Cor de primeiro plano","htmlToggle":"Origem HTML","formatBlock":"Estilo de parágrafo","newPage":"Nova página","insertHorizontalRule":"Régua horizontal","delete":"Eliminar","insertUnorderedList":"Lista marcada","tableProp":"Propriedades da tabela","insertImage":"Inserir imagem","superscript":"Superior à linha","subscript":"Inferior à linha","createLink":"Criar ligação","undo":"Anular","fullScreen":"Alternar ecrã completo","italic":"Itálico","fontName":"Nome do tipo de letra","justifyLeft":"Alinhar à esquerda","unlink":"Remover ligação","toggleTableBorder":"Alternar contorno da tabela","viewSource":"Ver origem HTML","fontSize":"Tamanho do tipo de letra","systemShortcut":"A acção \"${0}\" apenas está disponível no navegador utilizando um atalho de teclado. Utilize ${1}.","indent":"Indentar","redo":"Repetir","strikethrough":"Rasurado","justifyFull":"Justificar","justifyCenter":"Alinhar ao centro","hiliteColor":"Cor de segundo plano","deleteTable":"Eliminar tabela","outdent":"Recuar","cut":"Cortar","plainFormatBlock":"Estilo de parágrafo","toggleDir":"Alternar direcção","bold":"Negrito","tabIndent":"Indentar com a tecla Tab","justifyRight":"Alinhar à direita","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/pt/FontChoice.js b/lib/dijit/_editor/nls/pt/FontChoice.js new file mode 100644 index 000000000..50de220af --- /dev/null +++ b/lib/dijit/_editor/nls/pt/FontChoice.js @@ -0,0 +1 @@ +({"1":"extra-extra-pequeno","2":"extra-pequeno","formatBlock":"Formatar","3":"pequena","4":"médio","5":"grande","6":"extra-grande","7":"extra-extra-grande","fantasy":"fantasy","serif":"serif","p":"Parágrafo","pre":"Pré-formatado","sans-serif":"sans-serif","fontName":"Fonte","h1":"Título","h2":"Subtítulo","h3":"Sub-subtítulo","monospace":"espaço simples","fontSize":"Tamanho","cursive":"cursiva","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/pt/LinkDialog.js b/lib/dijit/_editor/nls/pt/LinkDialog.js new file mode 100644 index 000000000..0a55795eb --- /dev/null +++ b/lib/dijit/_editor/nls/pt/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Descrição:","insertImageTitle":"Propriedades de Imagem","set":"Definir","newWindow":"Nova Janela","topWindow":"Primeira Janela","target":"Destino:","createLinkTitle":"Propriedades de Link","parentWindow":"Janela Pai","currentWindow":"Janela Atual","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/pt/commands.js b/lib/dijit/_editor/nls/pt/commands.js new file mode 100644 index 000000000..271c6cf51 --- /dev/null +++ b/lib/dijit/_editor/nls/pt/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Remover Formato","copy":"Copiar","paste":"Colar","selectAll":"Selecionar Todos","insertOrderedList":"Lista Numerada","insertTable":"Inserir/Editar Tabela","print":"Impressão","underline":"Sublinhado","foreColor":"Cor do Primeiro Plano","htmlToggle":"Origem HTML","formatBlock":"Estilo de Parágrafo","newPage":"Nova Página","insertHorizontalRule":"Régua Horizontal","delete":"Excluir","insertUnorderedList":"Lista com Marcadores","tableProp":"Propriedade da Tabela","insertImage":"Inserir Imagem","superscript":"Sobrescrito","subscript":"Subscrito","createLink":"Criar Link","undo":"Desfazer","fullScreen":"Comutar Tela Cheia","italic":"Itálico","fontName":"Nome da Fonte","justifyLeft":"Alinhar pela Esquerda","unlink":"Remover Link","toggleTableBorder":"Alternar Moldura da Tabela","viewSource":"Visualizar Origem HTML","fontSize":"Tamanho da Fonte","systemShortcut":"A ação \"${0}\" está disponível em seu navegador apenas usando um atalho do teclado. Use ${1}.","indent":"Recuar","redo":"Refazer","strikethrough":"Tachado","justifyFull":"Justificar","justifyCenter":"Alinhar pelo Centro","hiliteColor":"Cor de segundo plano","deleteTable":"Excluir Tabela","outdent":"Não-chanfrado","cut":"Recortar","plainFormatBlock":"Estilo de Parágrafo","toggleDir":"Comutar Direção","bold":"Negrito","tabIndent":"Recuo de Guia","justifyRight":"Alinhar pela Direita","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/ro/FontChoice.js b/lib/dijit/_editor/nls/ro/FontChoice.js new file mode 100644 index 000000000..4806cb3e9 --- /dev/null +++ b/lib/dijit/_editor/nls/ro/FontChoice.js @@ -0,0 +1 @@ +({"noFormat":"Fără","1":"xxs (xx-small)","2":"xs (x-small)","formatBlock":"Format","3":"s (small)","4":"m (medium)","5":"l (large)","6":"xl (x-large)","7":"xxl (xx-large)","fantasy":"fantasy","serif":"serif","p":"Paragraf","pre":"Preformatat","sans-serif":"sans-serif","fontName":"Font","h1":"Titlu","h2":"Subtitlu","h3":"Sub-subtitlu","monospace":"monospace","fontSize":"Dimensiune","cursive":"cursive"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/ro/LinkDialog.js b/lib/dijit/_editor/nls/ro/LinkDialog.js new file mode 100644 index 000000000..c3cfb3990 --- /dev/null +++ b/lib/dijit/_editor/nls/ro/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Descriere:","insertImageTitle":"Proprietăţi imagine","set":"Setare","newWindow":"Fereastră nouă","topWindow":"Fereastra cea mai de sus","target":"Ţintă:","createLinkTitle":"Proprietăţi legătură","parentWindow":"Fereastra părinte","currentWindow":"Fereastra curentă","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/ro/commands.js b/lib/dijit/_editor/nls/ro/commands.js new file mode 100644 index 000000000..f73017cbf --- /dev/null +++ b/lib/dijit/_editor/nls/ro/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Înlăturare format","copy":"Copiere","paste":"Lipire","selectAll":"Selectare toate","insertOrderedList":"Listă numerotată","insertTable":"Inserare/Editare tabelă","print":"Tipărire","underline":"Subliniere","foreColor":"Culoare prim plan","htmlToggle":"Sursă HTML","formatBlock":"Stil paragraf","newPage":"Pagină nouă","insertHorizontalRule":"Regulă orizontală","delete":"Ştergere","insertUnorderedList":"Listă cu marcaje","tableProp":"Proprietăţi tabelă","insertImage":"Inserare imagine","superscript":"Scriere indice superior","subscript":"Scriere indice inferior","createLink":"Creare legătură","undo":"Anulare acţiune","fullScreen":"Comutare ecran complet","italic":"Cursive","fontName":"Nume font","justifyLeft":"Aliniere la stânga","unlink":"Înlăturare legătură","toggleTableBorder":"Comutare bordură tabelă","viewSource":"Vizualizare sursă HTML","fontSize":"Dimensiune font","systemShortcut":"Acţiunea \"${0}\" este disponibilă în browser folosind o scurtătură de la tastatură. Folosiţi ${1}.","indent":"Indentare","redo":"Repetare acţiune","strikethrough":"Suprascriere linie","justifyFull":"Aliniere","justifyCenter":"Aliniere pe centru","hiliteColor":"Culoare fundal","deleteTable":"Ştergere tabelă","outdent":"Outdentare","cut":"Tăiere","plainFormatBlock":"Stil paragraf","toggleDir":"Comutare direcţie","bold":"Aldine","tabIndent":"Indentare cu tab","justifyRight":"Aliniere la dreapta","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/ru/FontChoice.js b/lib/dijit/_editor/nls/ru/FontChoice.js new file mode 100644 index 000000000..bdc10430a --- /dev/null +++ b/lib/dijit/_editor/nls/ru/FontChoice.js @@ -0,0 +1 @@ +({"1":"самый маленький","2":"очень маленький","formatBlock":"Формат","3":"маленький","4":"средний","5":"большой","6":"очень большой","7":"самый большой","fantasy":"артистический","serif":"с засечками","p":"Абзац","pre":"Заранее отформатированный","sans-serif":"без засечек","fontName":"Шрифт","h1":"Заголовок","h2":"Подзаголовок","h3":"Вложенный подзаголовок","monospace":"непропорциональный","fontSize":"Размер","cursive":"курсив","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/ru/LinkDialog.js b/lib/dijit/_editor/nls/ru/LinkDialog.js new file mode 100644 index 000000000..ddc2f7b0f --- /dev/null +++ b/lib/dijit/_editor/nls/ru/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Описание:","insertImageTitle":"Свойства изображения","set":"Задать","newWindow":"Новое окно","topWindow":"Окно верхнего уровня","target":"Целевой объект:","createLinkTitle":"Свойства ссылки","parentWindow":"Родительское окно","currentWindow":"Текущее окно","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/ru/commands.js b/lib/dijit/_editor/nls/ru/commands.js new file mode 100644 index 000000000..bbc76174a --- /dev/null +++ b/lib/dijit/_editor/nls/ru/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Удалить формат","copy":"Копировать","paste":"Вставить","selectAll":"Выбрать все","insertOrderedList":"Нумерованный список","insertTable":"Вставить/изменить таблицу","print":"Печать","underline":"Подчеркивание","foreColor":"Цвет текста","htmlToggle":"Код HTML","formatBlock":"Стиль абзаца","newPage":"Создать страницу","insertHorizontalRule":"Горизонтальная линейка","delete":"Удалить","insertUnorderedList":"Список с маркерами","tableProp":"Свойства таблицы","insertImage":"Вставить изображение","superscript":"Верхний индекс","subscript":"Нижний индекс","createLink":"Создать ссылку","undo":"Отменить","fullScreen":"Переключить полноэкранный режим","italic":"Курсив","fontName":"Название шрифта","justifyLeft":"По левому краю","unlink":"Удалить ссылку","toggleTableBorder":"Переключить рамку таблицы","viewSource":"Показать исходный код HTML","fontSize":"Размер шрифта","systemShortcut":"Действие \"${0}\" можно выполнить в браузере только путем нажатия клавиш ${1}.","indent":"Отступ","redo":"Повторить","strikethrough":"Перечеркивание","justifyFull":"По ширине","justifyCenter":"По центру","hiliteColor":"Цвет фона","deleteTable":"Удалить таблицу","outdent":"Втяжка","cut":"Вырезать","plainFormatBlock":"Стиль абзаца","toggleDir":"Изменить направление","bold":"Полужирный","tabIndent":"Табуляция","justifyRight":"По правому краю","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/sk/FontChoice.js b/lib/dijit/_editor/nls/sk/FontChoice.js new file mode 100644 index 000000000..b7415e83d --- /dev/null +++ b/lib/dijit/_editor/nls/sk/FontChoice.js @@ -0,0 +1 @@ +({"1":"xx-small","2":"x-small","formatBlock":"Formát","3":"small","4":"medium","5":"large","6":"x-large","7":"xx-large","fantasy":"fantasy","serif":"serif","p":"Odsek","pre":"Predformátované","sans-serif":"sans-serif","fontName":"Písmo","h1":"Hlavička","h2":"Podhlavička","h3":"Pod-podhlavička","monospace":"monospace","fontSize":"Veľkosť","cursive":"cursive","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/sk/LinkDialog.js b/lib/dijit/_editor/nls/sk/LinkDialog.js new file mode 100644 index 000000000..75d0f885e --- /dev/null +++ b/lib/dijit/_editor/nls/sk/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Opis:","insertImageTitle":"Vlastnosti obrázka ","set":"Nastaviť","newWindow":"Nové okno ","topWindow":"Najvrchnejšie okno ","target":"Cieľ:","createLinkTitle":"Pripojiť vlastnosti","parentWindow":"Rodičovské okno ","currentWindow":"Aktuálne okno ","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/sk/commands.js b/lib/dijit/_editor/nls/sk/commands.js new file mode 100644 index 000000000..a59975e72 --- /dev/null +++ b/lib/dijit/_editor/nls/sk/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Odstrániť formát","copy":"Kopírovať","paste":"Nalepiť","selectAll":"Vybrať všetko","insertOrderedList":"Číslovaný zoznam","insertTable":"Vložiť/upraviť tabuľku","print":"Tlačiť","underline":"Podčiarknuť","foreColor":"Farba popredia","htmlToggle":"Zdroj HTML","formatBlock":"Štýl odseku","newPage":"Nová stránka ","insertHorizontalRule":"Horizontálna čiara","delete":"Vymazať","insertUnorderedList":"Zoznam s odrážkami","tableProp":"Vlastnosť tabuľky","insertImage":"Vložiť obrázok","superscript":"Horný index","subscript":"Dolný index","createLink":"Vytvoriť prepojenie","undo":"Vrátiť späť","fullScreen":"Zobraziť na celú obrazovku","italic":"Kurzíva","fontName":"Názov písma","justifyLeft":"Zarovnať doľava","unlink":"Odstrániť prepojenie","toggleTableBorder":"Prepnúť rámček tabuľky","viewSource":"Zobraziť zdrojový kód HTML ","fontSize":"Veľkosť písma","systemShortcut":"Akcia \"${0}\" je vo vašom prehliadači dostupná len s použitím klávesovej skratky. Použite ${1}.","indent":"Odsadiť","redo":"Znova vykonať","strikethrough":"Prečiarknuť","justifyFull":"Zarovnať podľa okraja","justifyCenter":"Zarovnať na stred","hiliteColor":"Farba pozadia","deleteTable":"Vymazať tabuľku","outdent":"Predsadiť","cut":"Vystrihnúť","plainFormatBlock":"Štýl odseku","toggleDir":"Prepnúť smer","bold":"Tučné písmo","tabIndent":"Odsadenie tabulátora","justifyRight":"Zarovnať doprava","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/sl/FontChoice.js b/lib/dijit/_editor/nls/sl/FontChoice.js new file mode 100644 index 000000000..2dcfed191 --- /dev/null +++ b/lib/dijit/_editor/nls/sl/FontChoice.js @@ -0,0 +1 @@ +({"1":"xx-majhno","2":"x-majhno","formatBlock":"Oblika","3":"majhno","4":"srednje","5":"veliko","6":"x-veliko","7":"xx-veliko","fantasy":"fantasy","serif":"serif","p":"Odstavek","pre":"Vnaprej oblikovano","sans-serif":"sans-serif","fontName":"Pisava","h1":"Naslov","h2":"Podnaslov","h3":"Pod podnaslov","monospace":"monospace","fontSize":"Velikost","cursive":"cursive","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/sl/LinkDialog.js b/lib/dijit/_editor/nls/sl/LinkDialog.js new file mode 100644 index 000000000..bad7dd641 --- /dev/null +++ b/lib/dijit/_editor/nls/sl/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Opis:","insertImageTitle":"Lastnosti slike","set":"Nastavi","newWindow":"Novo okno","topWindow":"Najvišje okno","target":"Cilj:","createLinkTitle":"Lastnosti povezave","parentWindow":"Nadrejeno okno","currentWindow":"Trenutno okno","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/sl/commands.js b/lib/dijit/_editor/nls/sl/commands.js new file mode 100644 index 000000000..72431aa71 --- /dev/null +++ b/lib/dijit/_editor/nls/sl/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Odstrani obliko zapisa","copy":"Prekopiraj","paste":"Prilepi","selectAll":"Izberi vse","insertOrderedList":"Oštevilčen seznam","insertTable":"Vstavi/uredi tabelo","print":"Natisni","underline":"Podčrtano","foreColor":"Barva ospredja","htmlToggle":"Izvorna koda HTML","formatBlock":"Slog odstavka","newPage":"Nova stran","insertHorizontalRule":"Vodoravno ravnilo","delete":"Izbriši","insertUnorderedList":"Naštevni seznam","tableProp":"Lastnost tabele","insertImage":"Vstavi sliko","superscript":"Nadpisano","subscript":"Podpisano","createLink":"Ustvari povezavo","undo":"Razveljavi","fullScreen":"Preklopi na celozaslonski način","italic":"Ležeče","fontName":"Ime pisave","justifyLeft":"Poravnaj levo","unlink":"Odstrani povezavo","toggleTableBorder":"Preklopi na rob tabele","viewSource":"Prikaži izvorno kodo HTML","fontSize":"Velikost pisave","systemShortcut":"Dejanje \"${0}\" lahko v vašem brskalniku uporabite samo z bližnjico na tipkovnici. Uporabite ${1}.","indent":"Zamik","redo":"Znova uveljavi","strikethrough":"Prečrtano","justifyFull":"Obojestranska poravnava","justifyCenter":"Poravnaj na sredino","hiliteColor":"Barva ozadja","deleteTable":"Izbriši tabelo","outdent":"Viseč odstavek","cut":"Izreži","plainFormatBlock":"Slog odstavka","toggleDir":"Preklopi na usmeritev","bold":"Krepko","tabIndent":"Zamik tabulatorja","justifyRight":"Poravnaj desno","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/sv/FontChoice.js b/lib/dijit/_editor/nls/sv/FontChoice.js new file mode 100644 index 000000000..a778cc83b --- /dev/null +++ b/lib/dijit/_editor/nls/sv/FontChoice.js @@ -0,0 +1 @@ +({"1":"mycket, mycket litet","2":"mycket litet","formatBlock":"Format","3":"litet","4":"medelstort","5":"stort","6":"extra stort","7":"extra extra stort","fantasy":"fantasy","serif":"serif","p":"Stycke","pre":"Förformaterat","sans-serif":"sans-serif","fontName":"Teckensnitt","h1":"Rubrik","h2":"Underrubrik","h3":"Underunderrubrik","monospace":"monospace","fontSize":"Storlek","cursive":"kursivt","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/sv/LinkDialog.js b/lib/dijit/_editor/nls/sv/LinkDialog.js new file mode 100644 index 000000000..80a1259cf --- /dev/null +++ b/lib/dijit/_editor/nls/sv/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Beskrivning:","insertImageTitle":"Bildegenskaper","set":"Ange","newWindow":"nytt fönster","topWindow":"översta fönstret","target":"Mål:","createLinkTitle":"Länkegenskaper","parentWindow":"överordnat fönster","currentWindow":"aktuellt fönster","url":"URL-adress:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/sv/commands.js b/lib/dijit/_editor/nls/sv/commands.js new file mode 100644 index 000000000..b571e8233 --- /dev/null +++ b/lib/dijit/_editor/nls/sv/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Ta bort format","copy":"Kopiera","paste":"Klistra in","selectAll":"Markera allt","insertOrderedList":"Numrerad lista","insertTable":"Infoga/redigera tabell","print":"Skriv ut","underline":"Understrykning","foreColor":"Förgrundsfärg","htmlToggle":"HTML-källkod","formatBlock":"Styckeformat","newPage":"Ny sida","insertHorizontalRule":"Horisontell linjal","delete":"Ta bort","appleKey":"⌘+${0}","insertUnorderedList":"Punktlista","tableProp":"Tabellegenskap","insertImage":"Infoga bild","superscript":"Upphöjt","subscript":"Nedsänkt","createLink":"Skapa länk","undo":"Ångra","fullScreen":"Växla helskärm","italic":"Kursiv","fontName":"Teckensnittsnamn","justifyLeft":"Vänsterjustera","unlink":"Ta bort länk","toggleTableBorder":"Aktivera/avaktivera tabellram","viewSource":"Visa HTML-kod","ctrlKey":"Ctrl+${0}","fontSize":"Teckenstorlek","systemShortcut":"Åtgärden \"${0}\" är endast tillgänglig i webbläsaren med hjälp av ett kortkommando. Använd ${1}.","indent":"Indrag","redo":"Gör om","strikethrough":"Genomstruken","justifyFull":"Marginaljustera","justifyCenter":"Centrera","hiliteColor":"Bakgrundsfärg","deleteTable":"Ta bort tabell","outdent":"Utdrag","cut":"Klipp ut","plainFormatBlock":"Styckeformat","toggleDir":"Växla riktning","bold":"Fetstil","tabIndent":"Tabbindrag","justifyRight":"Högerjustera"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/th/FontChoice.js b/lib/dijit/_editor/nls/th/FontChoice.js new file mode 100644 index 000000000..c3e8f811d --- /dev/null +++ b/lib/dijit/_editor/nls/th/FontChoice.js @@ -0,0 +1 @@ +({"1":"xx-small","2":"x-small","formatBlock":"รูปแบบ","3":"small","4":"medium","5":"large","6":"x-large","7":"xx-large","fantasy":"fantasy","serif":"serif","p":"ย่อหน้า","pre":"การกำหนดรูปแบบล่วงหน้า","sans-serif":"sans-serif","fontName":"ฟอนต์","h1":"ส่วนหัว","h2":"ส่วนหัวย่อย","h3":"ส่วนย่อยของส่วนหัวย่อย","monospace":"monospace","fontSize":"ขนาด","cursive":"cursive","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/th/LinkDialog.js b/lib/dijit/_editor/nls/th/LinkDialog.js new file mode 100644 index 000000000..d571c53b4 --- /dev/null +++ b/lib/dijit/_editor/nls/th/LinkDialog.js @@ -0,0 +1 @@ +({"text":"รายละเอียด","insertImageTitle":"คุณสมบัติอิมเมจ","set":"ตั้งค่า","newWindow":"หน้าต่างใหม่","topWindow":"หน้าต่างบนสุด","target":"เป้าหมาย:","createLinkTitle":"คุณสมบัติลิงก์","parentWindow":"หน้าต่างหลัก","currentWindow":"หน้าต่างปัจจุบัน","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/th/commands.js b/lib/dijit/_editor/nls/th/commands.js new file mode 100644 index 000000000..a98942a8d --- /dev/null +++ b/lib/dijit/_editor/nls/th/commands.js @@ -0,0 +1 @@ +({"removeFormat":"ลบรูปแบบออก","copy":"คัดลอก","paste":"วาง","selectAll":"เลือกทั้งหมด","insertOrderedList":"ลำดับเลข","insertTable":"แทรก/แก้ไขตาราง","print":"พิมพ์","underline":"ขีดเส้นใต้","foreColor":"สีพื้นหน้า","htmlToggle":"ซอร์ส HTML","formatBlock":"ลักษณะย่อหน้า","newPage":"หน้าใหม่","insertHorizontalRule":"ไม้บรรทัดแนวนอน","delete":"ลบ","insertUnorderedList":"หัวข้อย่อย","tableProp":"คุณสมบัติตาราง","insertImage":"แทรกอิมเมจ","superscript":"ตัวยก","subscript":"ตัวห้อย","createLink":"สร้างลิงก์","undo":"เลิกทำ","fullScreen":"สลับจอภาพแบบเต็ม","italic":"ตัวเอียง","fontName":"ชื่อฟอนต์","justifyLeft":"จัดชิดซ้าย","unlink":"ลบลิงก์ออก","toggleTableBorder":"สลับเส้นขอบตาราง","viewSource":"ดูซอร์ส HTML","fontSize":"ขนาดฟอนต์","systemShortcut":"การดำเนินการ\"${0}\" ใช้งานได้เฉพาะกับเบราว์เซอร์ของคุณโดยใช้แป้นพิมพ์ลัด ใช้ ${1}","indent":"เพิ่มการเยื้อง","redo":"ทำซ้ำ","strikethrough":"ขีดทับ","justifyFull":"จัดชิดขอบ","justifyCenter":"จัดกึ่งกลาง","hiliteColor":"สีพื้นหลัง","deleteTable":"ลบตาราง","outdent":"ลดการเยื้อง","cut":"ตัด","plainFormatBlock":"ลักษณะย่อหน้า","toggleDir":"สลับทิศทาง","bold":"ตัวหนา","tabIndent":"เยื้องแท็บ","justifyRight":"จัดชิดขวา","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/tr/FontChoice.js b/lib/dijit/_editor/nls/tr/FontChoice.js new file mode 100644 index 000000000..c9cdfea53 --- /dev/null +++ b/lib/dijit/_editor/nls/tr/FontChoice.js @@ -0,0 +1 @@ +({"1":"xx-küçük","2":"x-küçük","formatBlock":"Biçim","3":"küçük","4":"orta","5":"büyük","6":"x-büyük","7":"xx-büyük","fantasy":"fantazi","serif":"serif","p":"Paragraf","pre":"Önceden Biçimlendirilmiş","sans-serif":"sans-serif","fontName":"Yazı Tipi","h1":"Başlık","h2":"Alt Başlık","h3":"Alt Alt Başlık","monospace":"tek aralıklı","fontSize":"Boyut","cursive":"el yazısı","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/tr/LinkDialog.js b/lib/dijit/_editor/nls/tr/LinkDialog.js new file mode 100644 index 000000000..64bf3e219 --- /dev/null +++ b/lib/dijit/_editor/nls/tr/LinkDialog.js @@ -0,0 +1 @@ +({"text":"Açıklama:","insertImageTitle":"Resim Özellikleri","set":"Ayarla","newWindow":"Yeni Pencere","topWindow":"En Üst Pencere","target":"Hedef:","createLinkTitle":"Bağlantı Özellikleri","parentWindow":"Üst Pencere","currentWindow":"Geçerli Pencere","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/tr/commands.js b/lib/dijit/_editor/nls/tr/commands.js new file mode 100644 index 000000000..ed7b66db8 --- /dev/null +++ b/lib/dijit/_editor/nls/tr/commands.js @@ -0,0 +1 @@ +({"removeFormat":"Biçimi Kaldır","copy":"Kopyala","paste":"Yapıştır","selectAll":"Tümünü Seç","insertOrderedList":"Numaralı Liste","insertTable":"Tablo Ekle/Düzenle","print":"Yazdır","underline":"Altı Çizili","foreColor":"Ön Plan Rengi","htmlToggle":"HTML Kaynağı","formatBlock":"Paragraf Stili","newPage":"Yeni Sayfa","insertHorizontalRule":"Yatay Kural","delete":"Sil","insertUnorderedList":"Madde İşaretli Liste","tableProp":"Tablo Özelliği","insertImage":"Resim Ekle","superscript":"Üst Simge","subscript":"Alt Simge","createLink":"Bağlantı Oluştur","undo":"Geri Al","fullScreen":"Tam Ekranı Aç/Kapat","italic":"İtalik","fontName":"Yazı Tipi Adı","justifyLeft":"Sola Hizala","unlink":"Bağlantıyı Kaldır","toggleTableBorder":"Tablo Kenarlığını Göster/Gizle","viewSource":"HTML Kaynağını Görüntüle","fontSize":"Yazı Tipi Boyutu","systemShortcut":"\"${0}\" işlemi yalnızca tarayıcınızda bir klavye kısayoluyla birlikte kullanılabilir. Şunu kullanın: ${1}.","indent":"Girinti","redo":"Yinele","strikethrough":"Üstü Çizili","justifyFull":"Yasla","justifyCenter":"Ortaya Hizala","hiliteColor":"Arka Plan Rengi","deleteTable":"Tabloyu Sil","outdent":"Çıkıntı","cut":"Kes","plainFormatBlock":"Paragraf Stili","toggleDir":"Yönü Değiştir","bold":"Kalın","tabIndent":"Sekme Girintisi","justifyRight":"Sağa Hizala","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/zh-tw/FontChoice.js b/lib/dijit/_editor/nls/zh-tw/FontChoice.js new file mode 100644 index 000000000..b821ec0ec --- /dev/null +++ b/lib/dijit/_editor/nls/zh-tw/FontChoice.js @@ -0,0 +1 @@ +({"1":"最小","2":"較小","formatBlock":"格式","3":"小","4":"中","5":"大","6":"較大","7":"最大","fantasy":"Fantasy","serif":"新細明體","p":"段落","pre":"預先格式化","sans-serif":"新細明體","fontName":"字型","h1":"標題","h2":"子標題","h3":"次子標題","monospace":"等寬","fontSize":"大小","cursive":"Cursive","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/zh-tw/LinkDialog.js b/lib/dijit/_editor/nls/zh-tw/LinkDialog.js new file mode 100644 index 000000000..949318b40 --- /dev/null +++ b/lib/dijit/_editor/nls/zh-tw/LinkDialog.js @@ -0,0 +1 @@ +({"text":"說明:","insertImageTitle":"影像內容","set":"設定","newWindow":"新視窗","topWindow":"最上面的視窗","target":"目標:","createLinkTitle":"鏈結內容","parentWindow":"上層視窗","currentWindow":"現行視窗","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/zh-tw/commands.js b/lib/dijit/_editor/nls/zh-tw/commands.js new file mode 100644 index 000000000..d72dc4ec4 --- /dev/null +++ b/lib/dijit/_editor/nls/zh-tw/commands.js @@ -0,0 +1 @@ +({"removeFormat":"移除格式","copy":"複製","paste":"貼上","selectAll":"全選","insertOrderedList":"編號清單","insertTable":"插入/編輯表格","print":"列印","underline":"底線","foreColor":"前景顏色","htmlToggle":"HTML 原始檔","formatBlock":"段落樣式","newPage":"新建頁面","insertHorizontalRule":"水平尺規","delete":"刪除","insertUnorderedList":"項目符號清單","tableProp":"表格內容","insertImage":"插入影像","superscript":"上標","subscript":"下標","createLink":"建立鏈結","undo":"復原","fullScreen":"切換全螢幕","italic":"斜體","fontName":"字型名稱","justifyLeft":"靠左對齊","unlink":"移除鏈結","toggleTableBorder":"切換表格邊框","viewSource":"檢視 HTML 原始檔","fontSize":"字型大小","systemShortcut":"\"${0}\" 動作只能在瀏覽器中透過使用鍵盤快速鍵來使用。請使用 ${1}。","indent":"縮排","redo":"重做","strikethrough":"加刪除線","justifyFull":"對齊","justifyCenter":"置中對齊","hiliteColor":"背景顏色","deleteTable":"刪除表格","outdent":"凸排","cut":"剪下","plainFormatBlock":"段落樣式","toggleDir":"切換方向","bold":"粗體","tabIndent":"定位點縮排","justifyRight":"靠右對齊","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/zh/FontChoice.js b/lib/dijit/_editor/nls/zh/FontChoice.js new file mode 100644 index 000000000..4d52bb78e --- /dev/null +++ b/lib/dijit/_editor/nls/zh/FontChoice.js @@ -0,0 +1 @@ +({"1":"XXS 号","2":"XS 号","formatBlock":"格式","3":"S 号","4":"M 号","5":"L 号","6":"XL 号","7":"XXL 号","fantasy":"虚线","serif":"有衬线","p":"段落","pre":"预设有格式的","sans-serif":"无衬线","fontName":"字体","h1":"标题","h2":"子标题","h3":"二级子标题","monospace":"等宽字体","fontSize":"大小","cursive":"草书","noFormat":"None"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/zh/LinkDialog.js b/lib/dijit/_editor/nls/zh/LinkDialog.js new file mode 100644 index 000000000..da4c50026 --- /dev/null +++ b/lib/dijit/_editor/nls/zh/LinkDialog.js @@ -0,0 +1 @@ +({"text":"描述:","insertImageTitle":"图像属性","set":"设置","newWindow":"新窗口","topWindow":"最顶部窗口","target":"目标:","createLinkTitle":"链接属性","parentWindow":"父窗口","currentWindow":"当前窗口","url":"URL:"}) \ No newline at end of file diff --git a/lib/dijit/_editor/nls/zh/commands.js b/lib/dijit/_editor/nls/zh/commands.js new file mode 100644 index 000000000..11763dfc4 --- /dev/null +++ b/lib/dijit/_editor/nls/zh/commands.js @@ -0,0 +1 @@ +({"removeFormat":"除去格式","copy":"复制","paste":"粘贴","selectAll":"全选","insertOrderedList":"编号列表","insertTable":"插入/编辑表","print":"打印","underline":"下划线","foreColor":"前景色","htmlToggle":"HTML 源代码","formatBlock":"段落样式","newPage":"新建页面","insertHorizontalRule":"水平线","delete":"删除","insertUnorderedList":"符号列表","tableProp":"表属性","insertImage":"插入图像","superscript":"上标","subscript":"下标","createLink":"创建链接","undo":"撤销","fullScreen":"切换全屏幕","italic":"斜体","fontName":"字体名称","justifyLeft":"左对齐","unlink":"除去链接","toggleTableBorder":"切换表边框","viewSource":"查看 HTML 源代码","fontSize":"字体大小","systemShortcut":"只能在浏览器中通过键盘快捷方式执行“${0}”操作。使用 ${1}。","indent":"增加缩进","redo":"重做","strikethrough":"删除线","justifyFull":"对齐","justifyCenter":"居中","hiliteColor":"背景色","deleteTable":"删除表","outdent":"减少缩进","cut":"剪切","plainFormatBlock":"段落样式","toggleDir":"固定方向","bold":"粗体","tabIndent":"制表符缩进","justifyRight":"右对齐","appleKey":"⌘${0}","ctrlKey":"ctrl+${0}"}) \ No newline at end of file diff --git a/lib/dijit/_editor/plugins/AlwaysShowToolbar.js b/lib/dijit/_editor/plugins/AlwaysShowToolbar.js new file mode 100644 index 000000000..1e0e2ed3f --- /dev/null +++ b/lib/dijit/_editor/plugins/AlwaysShowToolbar.js @@ -0,0 +1,119 @@ +/* + Copyright (c) 2004-2010, The Dojo Foundation All Rights Reserved. + Available via Academic Free License >= 2.1 OR the modified BSD license. + see: http://dojotoolkit.org/license for details +*/ + + +if(!dojo._hasResource["dijit._editor.plugins.AlwaysShowToolbar"]){ +dojo._hasResource["dijit._editor.plugins.AlwaysShowToolbar"]=true; +dojo.provide("dijit._editor.plugins.AlwaysShowToolbar"); +dojo.declare("dijit._editor.plugins.AlwaysShowToolbar",dijit._editor._Plugin,{_handleScroll:true,setEditor:function(e){ +if(!e.iframe){ +return; +} +this.editor=e; +e.onLoadDeferred.addCallback(dojo.hitch(this,this.enable)); +},enable:function(d){ +this._updateHeight(); +this.connect(window,"onscroll","globalOnScrollHandler"); +this.connect(this.editor,"onNormalizedDisplayChanged","_updateHeight"); +return d; +},_updateHeight:function(){ +var e=this.editor; +if(!e.isLoaded){ +return; +} +if(e.height){ +return; +} +var _1=dojo.marginBox(e.editNode).h; +if(dojo.isOpera){ +_1=e.editNode.scrollHeight; +} +if(!_1){ +_1=dojo.marginBox(e.document.body).h; +} +if(_1==0){ +return; +} +if(dojo.isIE<=7&&this.editor.minHeight){ +var _2=parseInt(this.editor.minHeight); +if(_1<_2){ +_1=_2; +} +} +if(_1!=this._lastHeight){ +this._lastHeight=_1; +dojo.marginBox(e.iframe,{h:this._lastHeight}); +} +},_lastHeight:0,globalOnScrollHandler:function(){ +var _3=dojo.isIE<7; +if(!this._handleScroll){ +return; +} +var _4=this.editor.header; +var db=dojo.body; +if(!this._scrollSetUp){ +this._scrollSetUp=true; +this._scrollThreshold=dojo.position(_4,true).y; +} +var _5=dojo._docScroll().y; +var s=_4.style; +if(_5>this._scrollThreshold&&_5this._scrollThreshold+_7)?"none":""; +}else{ +if(this._fixEnabled){ +this.editor.iframe.style.marginTop=""; +s.position=""; +s.top=""; +s.zIndex=""; +s.display=""; +if(_3){ +s.left=""; +dojo.removeClass(_4,"dijitIEFixedToolbar"); +if(this._IEOriginalPos){ +dojo.place(_4,this._IEOriginalPos[1],this._IEOriginalPos[0]); +this._IEOriginalPos=null; +}else{ +dojo.place(_4,this.editor.iframe,"before"); +} +} +s.width=""; +this._fixEnabled=false; +} +} +},destroy:function(){ +this._IEOriginalPos=null; +this._handleScroll=false; +dojo.forEach(this._connects,dojo.disconnect); +if(dojo.isIE<7){ +dojo.removeClass(this.editor.header,"dijitIEFixedToolbar"); +} +}}); +} diff --git a/lib/dijit/_editor/plugins/EnterKeyHandling.js b/lib/dijit/_editor/plugins/EnterKeyHandling.js new file mode 100644 index 000000000..51a8fdde8 --- /dev/null +++ b/lib/dijit/_editor/plugins/EnterKeyHandling.js @@ -0,0 +1,423 @@ +/* + Copyright (c) 2004-2010, The Dojo Foundation All Rights Reserved. + Available via Academic Free License >= 2.1 OR the modified BSD license. + see: http://dojotoolkit.org/license for details +*/ + + +if(!dojo._hasResource["dijit._editor.plugins.EnterKeyHandling"]){ +dojo._hasResource["dijit._editor.plugins.EnterKeyHandling"]=true; +dojo.provide("dijit._editor.plugins.EnterKeyHandling"); +dojo.require("dojo.window"); +dojo.declare("dijit._editor.plugins.EnterKeyHandling",dijit._editor._Plugin,{blockNodeForEnter:"BR",constructor:function(_1){ +if(_1){ +dojo.mixin(this,_1); +} +},setEditor:function(_2){ +this.editor=_2; +if(this.blockNodeForEnter=="BR"){ +if(dojo.isIE){ +_2.contentDomPreFilters.push(dojo.hitch(this,"regularPsToSingleLinePs")); +_2.contentDomPostFilters.push(dojo.hitch(this,"singleLinePsToRegularPs")); +_2.onLoadDeferred.addCallback(dojo.hitch(this,"_fixNewLineBehaviorForIE")); +}else{ +_2.onLoadDeferred.addCallback(dojo.hitch(this,function(d){ +try{ +this.editor.document.execCommand("insertBrOnReturn",false,true); +} +catch(e){ +} +return d; +})); +} +}else{ +if(this.blockNodeForEnter){ +dojo["require"]("dijit._editor.range"); +var h=dojo.hitch(this,this.handleEnterKey); +_2.addKeyHandler(13,0,0,h); +_2.addKeyHandler(13,0,1,h); +this.connect(this.editor,"onKeyPressed","onKeyPressed"); +} +} +},onKeyPressed:function(e){ +if(this._checkListLater){ +if(dojo.withGlobal(this.editor.window,"isCollapsed",dijit)){ +var _3=dojo.withGlobal(this.editor.window,"getAncestorElement",dijit._editor.selection,["LI"]); +if(!_3){ +dijit._editor.RichText.prototype.execCommand.call(this.editor,"formatblock",this.blockNodeForEnter); +var _4=dojo.withGlobal(this.editor.window,"getAncestorElement",dijit._editor.selection,[this.blockNodeForEnter]); +if(_4){ +_4.innerHTML=this.bogusHtmlContent; +if(dojo.isIE){ +var r=this.editor.document.selection.createRange(); +r.move("character",-1); +r.select(); +} +}else{ +console.error("onKeyPressed: Cannot find the new block node"); +} +}else{ +if(dojo.isMoz){ +if(_3.parentNode.parentNode.nodeName=="LI"){ +_3=_3.parentNode.parentNode; +} +} +var fc=_3.firstChild; +if(fc&&fc.nodeType==1&&(fc.nodeName=="UL"||fc.nodeName=="OL")){ +_3.insertBefore(fc.ownerDocument.createTextNode(" "),fc); +var _5=dijit.range.create(this.editor.window); +_5.setStart(_3.firstChild,0); +var _6=dijit.range.getSelection(this.editor.window,true); +_6.removeAllRanges(); +_6.addRange(_5); +} +} +} +this._checkListLater=false; +} +if(this._pressedEnterInBlock){ +if(this._pressedEnterInBlock.previousSibling){ +this.removeTrailingBr(this._pressedEnterInBlock.previousSibling); +} +delete this._pressedEnterInBlock; +} +},bogusHtmlContent:" ",blockNodes:/^(?:P|H1|H2|H3|H4|H5|H6|LI)$/,handleEnterKey:function(e){ +var _7,_8,_9,_a=this.editor.document,br; +if(e.shiftKey){ +var _b=dojo.withGlobal(this.editor.window,"getParentElement",dijit._editor.selection); +var _c=dijit.range.getAncestor(_b,this.blockNodes); +if(_c){ +if(!e.shiftKey&&_c.tagName=="LI"){ +return true; +} +_7=dijit.range.getSelection(this.editor.window); +_8=_7.getRangeAt(0); +if(!_8.collapsed){ +_8.deleteContents(); +_7=dijit.range.getSelection(this.editor.window); +_8=_7.getRangeAt(0); +} +if(dijit.range.atBeginningOfContainer(_c,_8.startContainer,_8.startOffset)){ +if(e.shiftKey){ +br=_a.createElement("br"); +_9=dijit.range.create(this.editor.window); +_c.insertBefore(br,_c.firstChild); +_9.setStartBefore(br.nextSibling); +_7.removeAllRanges(); +_7.addRange(_9); +}else{ +dojo.place(br,_c,"before"); +} +}else{ +if(dijit.range.atEndOfContainer(_c,_8.startContainer,_8.startOffset)){ +_9=dijit.range.create(this.editor.window); +br=_a.createElement("br"); +if(e.shiftKey){ +_c.appendChild(br); +_c.appendChild(_a.createTextNode(" ")); +_9.setStart(_c.lastChild,0); +}else{ +dojo.place(br,_c,"after"); +_9.setStartAfter(_c); +} +_7.removeAllRanges(); +_7.addRange(_9); +}else{ +return true; +} +} +}else{ +dijit._editor.RichText.prototype.execCommand.call(this.editor,"inserthtml","
    "); +} +return false; +} +var _d=true; +_7=dijit.range.getSelection(this.editor.window); +_8=_7.getRangeAt(0); +if(!_8.collapsed){ +_8.deleteContents(); +_7=dijit.range.getSelection(this.editor.window); +_8=_7.getRangeAt(0); +} +var _e=dijit.range.getBlockAncestor(_8.endContainer,null,this.editor.editNode); +var _f=_e.blockNode; +if((this._checkListLater=(_f&&(_f.nodeName=="LI"||_f.parentNode.nodeName=="LI")))){ +if(dojo.isMoz){ +this._pressedEnterInBlock=_f; +} +if(/^(\s| |\xA0|]*\bclass=['"]Apple-style-span['"][^>]*>(\s| |\xA0)<\/span>)?(
    )?$/.test(_f.innerHTML)){ +_f.innerHTML=""; +if(dojo.isWebKit){ +_9=dijit.range.create(this.editor.window); +_9.setStart(_f,0); +_7.removeAllRanges(); +_7.addRange(_9); +} +this._checkListLater=false; +} +return true; +} +if(!_e.blockNode||_e.blockNode===this.editor.editNode){ +try{ +dijit._editor.RichText.prototype.execCommand.call(this.editor,"formatblock",this.blockNodeForEnter); +} +catch(e2){ +} +_e={blockNode:dojo.withGlobal(this.editor.window,"getAncestorElement",dijit._editor.selection,[this.blockNodeForEnter]),blockContainer:this.editor.editNode}; +if(_e.blockNode){ +if(_e.blockNode!=this.editor.editNode&&(!(_e.blockNode.textContent||_e.blockNode.innerHTML).replace(/^\s+|\s+$/g,"").length)){ +this.removeTrailingBr(_e.blockNode); +return false; +} +}else{ +_e.blockNode=this.editor.editNode; +} +_7=dijit.range.getSelection(this.editor.window); +_8=_7.getRangeAt(0); +} +var _10=_a.createElement(this.blockNodeForEnter); +_10.innerHTML=this.bogusHtmlContent; +this.removeTrailingBr(_e.blockNode); +if(dijit.range.atEndOfContainer(_e.blockNode,_8.endContainer,_8.endOffset)){ +if(_e.blockNode===_e.blockContainer){ +_e.blockNode.appendChild(_10); +}else{ +dojo.place(_10,_e.blockNode,"after"); +} +_d=false; +_9=dijit.range.create(this.editor.window); +_9.setStart(_10,0); +_7.removeAllRanges(); +_7.addRange(_9); +if(this.editor.height){ +dojo.window.scrollIntoView(_10); +} +}else{ +if(dijit.range.atBeginningOfContainer(_e.blockNode,_8.startContainer,_8.startOffset)){ +dojo.place(_10,_e.blockNode,_e.blockNode===_e.blockContainer?"first":"before"); +if(_10.nextSibling&&this.editor.height){ +_9=dijit.range.create(this.editor.window); +_9.setStart(_10.nextSibling,0); +_7.removeAllRanges(); +_7.addRange(_9); +dojo.window.scrollIntoView(_10.nextSibling); +} +_d=false; +}else{ +if(_e.blockNode===_e.blockContainer){ +_e.blockNode.appendChild(_10); +}else{ +dojo.place(_10,_e.blockNode,"after"); +} +_d=false; +if(_e.blockNode.style){ +if(_10.style){ +if(_e.blockNode.style.cssText){ +_10.style.cssText=_e.blockNode.style.cssText; +} +} +} +var rs=_8.startContainer; +if(rs&&rs.nodeType==3){ +var _11,_12; +var txt=rs.nodeValue; +var _13=_a.createTextNode(txt.substring(0,_8.startOffset)); +var _14=_a.createTextNode(txt.substring(_8.startOffset,txt.length)); +dojo.place(_13,rs,"before"); +dojo.place(_14,rs,"after"); +dojo.destroy(rs); +var _15=_13.parentNode; +while(_15!==_e.blockNode){ +var tg=_15.tagName; +var _16=_a.createElement(tg); +if(_15.style){ +if(_16.style){ +if(_15.style.cssText){ +_16.style.cssText=_15.style.cssText; +} +} +} +_11=_14; +while(_11){ +_12=_11.nextSibling; +_16.appendChild(_11); +_11=_12; +} +dojo.place(_16,_15,"after"); +_13=_15; +_14=_16; +_15=_15.parentNode; +} +_11=_14; +if(_11.nodeType==1||(_11.nodeType==3&&_11.nodeValue)){ +_10.innerHTML=""; +} +while(_11){ +_12=_11.nextSibling; +_10.appendChild(_11); +_11=_12; +} +} +_9=dijit.range.create(this.editor.window); +_9.setStart(_10,0); +_7.removeAllRanges(); +_7.addRange(_9); +if(this.editor.height){ +dijit.scrollIntoView(_10); +} +if(dojo.isMoz){ +this._pressedEnterInBlock=_e.blockNode; +} +} +} +return _d; +},removeTrailingBr:function(_17){ +var _18=/P|DIV|LI/i.test(_17.tagName)?_17:dijit._editor.selection.getParentOfType(_17,["P","DIV","LI"]); +if(!_18){ +return; +} +if(_18.lastChild){ +if((_18.childNodes.length>1&&_18.lastChild.nodeType==3&&/^[\s\xAD]*$/.test(_18.lastChild.nodeValue))||_18.lastChild.tagName=="BR"){ +dojo.destroy(_18.lastChild); +} +} +if(!_18.childNodes.length){ +_18.innerHTML=this.bogusHtmlContent; +} +},_fixNewLineBehaviorForIE:function(d){ +var doc=this.editor.document; +if(doc.__INSERTED_EDITIOR_NEWLINE_CSS===undefined){ +var _19=dojo.create("style",{type:"text/css"},doc.getElementsByTagName("head")[0]); +_19.styleSheet.cssText="p{margin:0;}"; +this.editor.document.__INSERTED_EDITIOR_NEWLINE_CSS=true; +} +return d; +},regularPsToSingleLinePs:function(_1a,_1b){ +function _1c(el){ +function _1d(_1e){ +var _1f=_1e[0].ownerDocument.createElement("p"); +_1e[0].parentNode.insertBefore(_1f,_1e[0]); +dojo.forEach(_1e,function(_20){ +_1f.appendChild(_20); +}); +}; +var _21=0; +var _22=[]; +var _23; +while(_21=0;i--){ +_26=el.childNodes[i]; +if(_26.nodeName=="BR"){ +var _29=_26.ownerDocument.createElement("p"); +dojo.place(_29,el,"after"); +if(_27.length==0&&i!=_28){ +_29.innerHTML=" "; +} +dojo.forEach(_27,function(_2a){ +_29.appendChild(_2a); +}); +dojo.destroy(_26); +_27=[]; +}else{ +_27.unshift(_26); +} +} +}; +var _2b=[]; +var ps=_1a.getElementsByTagName("p"); +dojo.forEach(ps,function(p){ +_2b.push(p); +}); +dojo.forEach(_2b,function(p){ +var _2c=p.previousSibling; +if((_2c)&&(_2c.nodeType==1)&&(_2c.nodeName=="P"||dojo.style(_2c,"display")!="block")){ +var _2d=p.parentNode.insertBefore(this.document.createElement("p"),p); +_2d.innerHTML=_1b?"":" "; +} +_25(p); +},this.editor); +_1c(_1a); +return _1a; +},singleLinePsToRegularPs:function(_2e){ +function _2f(_30){ +var ps=_30.getElementsByTagName("p"); +var _31=[]; +for(var i=0;i= 2.1 OR the modified BSD license. + see: http://dojotoolkit.org/license for details +*/ + + +if(!dojo._hasResource["dijit._editor.plugins.FontChoice"]){ +dojo._hasResource["dijit._editor.plugins.FontChoice"]=true; +dojo.provide("dijit._editor.plugins.FontChoice"); +dojo.require("dijit._editor._Plugin"); +dojo.require("dijit._editor.range"); +dojo.require("dijit._editor.selection"); +dojo.require("dijit.form.FilteringSelect"); +dojo.require("dojo.data.ItemFileReadStore"); +dojo.require("dojo.i18n"); +dojo.requireLocalization("dijit._editor","FontChoice",null,"ROOT,ar,ca,cs,da,de,el,es,fi,fr,he,hu,it,ja,ko,nb,nl,pl,pt,pt-pt,ro,ru,sk,sl,sv,th,tr,zh,zh-tw"); +dojo.declare("dijit._editor.plugins._FontDropDown",[dijit._Widget,dijit._Templated],{label:"",widgetsInTemplate:true,plainText:false,templateString:""+""+""+"",postMixInProperties:function(){ +this.inherited(arguments); +this.strings=dojo.i18n.getLocalization("dijit._editor","FontChoice"); +this.label=this.strings[this.command]; +this.id=dijit.getUniqueId(this.declaredClass.replace(/\./g,"_")); +this.selectId=this.id+"_select"; +this.inherited(arguments); +},postCreate:function(){ +var _1=dojo.map(this.values,function(_2){ +var _3=this.strings[_2]||_2; +return {label:this.getLabel(_2,_3),name:_3,value:_2}; +},this); +this.select.store=new dojo.data.ItemFileReadStore({data:{identifier:"value",items:_1}}); +this.select.set("value","",false); +this.disabled=this.select.get("disabled"); +},_setValueAttr:function(_4,_5){ +_5=_5!==false?true:false; +this.select.set("value",dojo.indexOf(this.values,_4)<0?"":_4,_5); +if(!_5){ +this.select._lastValueReported=null; +} +},_getValueAttr:function(){ +return this.select.get("value"); +},focus:function(){ +this.select.focus(); +},_setDisabledAttr:function(_6){ +this.disabled=_6; +this.select.set("disabled",_6); +}}); +dojo.declare("dijit._editor.plugins._FontNameDropDown",dijit._editor.plugins._FontDropDown,{generic:false,command:"fontName",postMixInProperties:function(){ +if(!this.values){ +this.values=this.generic?["serif","sans-serif","monospace","cursive","fantasy"]:["Arial","Times New Roman","Comic Sans MS","Courier New"]; +} +this.inherited(arguments); +},getLabel:function(_7,_8){ +if(this.plainText){ +return _8; +}else{ +return "
    "+_8+"
    "; +} +},_setValueAttr:function(_9,_a){ +_a=_a!==false?true:false; +if(this.generic){ +var _b={"Arial":"sans-serif","Helvetica":"sans-serif","Myriad":"sans-serif","Times":"serif","Times New Roman":"serif","Comic Sans MS":"cursive","Apple Chancery":"cursive","Courier":"monospace","Courier New":"monospace","Papyrus":"fantasy"}; +_9=_b[_9]||_9; +} +this.inherited(arguments,[_9,_a]); +}}); +dojo.declare("dijit._editor.plugins._FontSizeDropDown",dijit._editor.plugins._FontDropDown,{command:"fontSize",values:[1,2,3,4,5,6,7],getLabel:function(_c,_d){ +if(this.plainText){ +return _d; +}else{ +return ""+_d+""; +} +},_setValueAttr:function(_e,_f){ +_f=_f!==false?true:false; +if(_e.indexOf&&_e.indexOf("px")!=-1){ +var _10=parseInt(_e,10); +_e={10:1,13:2,16:3,18:4,24:5,32:6,48:7}[_10]||_e; +} +this.inherited(arguments,[_e,_f]); +}}); +dojo.declare("dijit._editor.plugins._FormatBlockDropDown",dijit._editor.plugins._FontDropDown,{command:"formatBlock",values:["noFormat","p","h1","h2","h3","pre"],postCreate:function(){ +this.inherited(arguments); +this.set("value","noFormat",false); +},getLabel:function(_11,_12){ +if(this.plainText){ +return _12; +}else{ +return "<"+_11+">"+_12+""; +} +},_execCommand:function(_13,_14,_15){ +if(_15==="noFormat"){ +var _16; +var end; +var sel=dijit.range.getSelection(_13.window); +if(sel&&sel.rangeCount>0){ +var _17=sel.getRangeAt(0); +var _18,tag; +if(_17){ +_16=_17.startContainer; +end=_17.endContainer; +while(_16&&_16!==_13.editNode&&_16!==_13.document.body&&_16.nodeType!==1){ +_16=_16.parentNode; +} +while(end&&end!==_13.editNode&&end!==_13.document.body&&end.nodeType!==1){ +end=end.parentNode; +} +var _19=dojo.hitch(this,function(_1a,_1b){ +if(_1a.childNodes&&_1a.childNodes.length){ +var i; +for(i=0;i<_1a.childNodes.length;i++){ +var c=_1a.childNodes[i]; +if(c.nodeType==1){ +if(dojo.withGlobal(_13.window,"inSelection",dijit._editor.selection,[c])){ +var tag=c.tagName?c.tagName.toLowerCase():""; +if(dojo.indexOf(this.values,tag)!==-1){ +_1b.push(c); +} +_19(c,_1b); +} +} +} +} +}); +var _1c=dojo.hitch(this,function(_1d){ +if(_1d&&_1d.length){ +_13.beginEditing(); +while(_1d.length){ +this._removeFormat(_13,_1d.pop()); +} +_13.endEditing(); +} +}); +var _1e=[]; +if(_16==end){ +var _1f; +_18=_16; +while(_18&&_18!==_13.editNode&&_18!==_13.document.body){ +if(_18.nodeType==1){ +tag=_18.tagName?_18.tagName.toLowerCase():""; +if(dojo.indexOf(this.values,tag)!==-1){ +_1f=_18; +break; +} +} +_18=_18.parentNode; +} +_19(_16,_1e); +if(_1f){ +_1e=[_1f].concat(_1e); +} +_1c(_1e); +}else{ +_18=_16; +while(dojo.withGlobal(_13.window,"inSelection",dijit._editor.selection,[_18])){ +if(_18.nodeType==1){ +tag=_18.tagName?_18.tagName.toLowerCase():""; +if(dojo.indexOf(this.values,tag)!==-1){ +_1e.push(_18); +} +_19(_18,_1e); +} +_18=_18.nextSibling; +} +_1c(_1e); +} +_13.onDisplayChanged(); +} +} +}else{ +_13.execCommand(_14,_15); +} +},_removeFormat:function(_20,_21){ +if(_20.customUndo){ +while(_21.firstChild){ +dojo.place(_21.firstChild,_21,"before"); +} +_21.parentNode.removeChild(_21); +}else{ +dojo.withGlobal(_20.window,"selectElementChildren",dijit._editor.selection,[_21]); +var _22=dojo.withGlobal(_20.window,"getSelectedHtml",dijit._editor.selection,[null]); +dojo.withGlobal(_20.window,"selectElement",dijit._editor.selection,[_21]); +_20.execCommand("inserthtml",_22||""); +} +}}); +dojo.declare("dijit._editor.plugins.FontChoice",dijit._editor._Plugin,{useDefaultCommand:false,_initButton:function(){ +var _23={fontName:dijit._editor.plugins._FontNameDropDown,fontSize:dijit._editor.plugins._FontSizeDropDown,formatBlock:dijit._editor.plugins._FormatBlockDropDown}[this.command],_24=this.params; +if(this.params.custom){ +_24.values=this.params.custom; +} +var _25=this.editor; +this.button=new _23(dojo.delegate({dir:_25.dir,lang:_25.lang},_24)); +this.connect(this.button.select,"onChange",function(_26){ +this.editor.focus(); +if(this.command=="fontName"&&_26.indexOf(" ")!=-1){ +_26="'"+_26+"'"; +} +if(this.button._execCommand){ +this.button._execCommand(this.editor,this.command,_26); +}else{ +this.editor.execCommand(this.command,_26); +} +this.editor.customUndo=this.editor.customUndo||dojo.isWebKit; +}); +},updateState:function(){ +var _27=this.editor; +var _28=this.command; +if(!_27||!_27.isLoaded||!_28.length){ +return; +} +if(this.button){ +var _29; +try{ +_29=_27.queryCommandValue(_28)||""; +} +catch(e){ +_29=""; +} +var _2a=dojo.isString(_29)&&_29.match(/'([^']*)'/); +if(_2a){ +_29=_2a[1]; +} +if(_28==="formatBlock"){ +if(!_29||_29=="p"){ +_29=null; +var _2b; +var sel=dijit.range.getSelection(this.editor.window); +if(sel&&sel.rangeCount>0){ +var _2c=sel.getRangeAt(0); +if(_2c){ +_2b=_2c.endContainer; +} +} +while(_2b&&_2b!==_27.editNode&&_2b!==_27.document){ +var tg=_2b.tagName?_2b.tagName.toLowerCase():""; +if(tg&&dojo.indexOf(this.button.values,tg)>-1){ +_29=tg; +break; +} +_2b=_2b.parentNode; +} +if(!_29){ +_29="noFormat"; +} +}else{ +if(dojo.indexOf(this.button.values,_29)<0){ +_29="noFormat"; +} +} +} +if(_29!==this.button.get("value")){ +this.button.set("value",_29,false); +} +} +}}); +dojo.subscribe(dijit._scopeName+".Editor.getPlugin",null,function(o){ +if(o.plugin){ +return; +} +switch(o.args.name){ +case "fontName": +case "fontSize": +case "formatBlock": +o.plugin=new dijit._editor.plugins.FontChoice({command:o.args.name,plainText:o.args.plainText?o.args.plainText:false}); +} +}); +} diff --git a/lib/dijit/_editor/plugins/FullScreen.js b/lib/dijit/_editor/plugins/FullScreen.js new file mode 100644 index 000000000..7a6dac55d --- /dev/null +++ b/lib/dijit/_editor/plugins/FullScreen.js @@ -0,0 +1,232 @@ +/* + Copyright (c) 2004-2010, The Dojo Foundation All Rights Reserved. + Available via Academic Free License >= 2.1 OR the modified BSD license. + see: http://dojotoolkit.org/license for details +*/ + + +if(!dojo._hasResource["dijit._editor.plugins.FullScreen"]){ +dojo._hasResource["dijit._editor.plugins.FullScreen"]=true; +dojo.provide("dijit._editor.plugins.FullScreen"); +dojo.require("dojo.window"); +dojo.require("dojo.i18n"); +dojo.require("dijit._editor._Plugin"); +dojo.require("dijit.form.Button"); +dojo.requireLocalization("dijit._editor","commands",null,"ROOT,ar,ca,cs,da,de,el,es,fi,fr,he,hu,it,ja,ko,nb,nl,pl,pt,pt-pt,ro,ru,sk,sl,sv,th,tr,zh,zh-tw"); +dojo.declare("dijit._editor.plugins.FullScreen",dijit._editor._Plugin,{zIndex:500,_origState:null,_origiFrameState:null,_resizeHandle:null,isFullscreen:false,toggle:function(){ +this.button.set("checked",!this.button.get("checked")); +},_initButton:function(){ +var _1=dojo.i18n.getLocalization("dijit._editor","commands"),_2=this.editor; +this.button=new dijit.form.ToggleButton({label:_1["fullScreen"],dir:_2.dir,lang:_2.lang,showLabel:false,iconClass:this.iconClassPrefix+" "+this.iconClassPrefix+"FullScreen",tabIndex:"-1",onChange:dojo.hitch(this,"_setFullScreen")}); +},setEditor:function(_3){ +this.editor=_3; +this._initButton(); +this.editor.addKeyHandler(dojo.keys.F11,true,true,dojo.hitch(this,function(e){ +this.toggle(); +dojo.stopEvent(e); +setTimeout(dojo.hitch(this,function(){ +this.editor.focus(); +}),250); +return true; +})); +this.connect(this.editor.domNode,"onkeydown","_containFocus"); +},_containFocus:function(e){ +if(this.isFullscreen){ +var ed=this.editor; +if(!ed.isTabIndent&&ed._fullscreen_oldOnKeyDown&&e.keyCode===dojo.keys.TAB){ +var f=dijit.getFocus(); +var _4=this._getAltViewNode(); +if(f.node==ed.iframe||(_4&&f.node===_4)){ +setTimeout(dojo.hitch(this,function(){ +ed.toolbar.focus(); +}),10); +}else{ +if(_4&&dojo.style(ed.iframe,"display")==="none"){ +setTimeout(dojo.hitch(this,function(){ +dijit.focus(_4); +}),10); +}else{ +setTimeout(dojo.hitch(this,function(){ +ed.focus(); +}),10); +} +} +dojo.stopEvent(e); +}else{ +if(ed._fullscreen_oldOnKeyDown){ +ed._fullscreen_oldOnKeyDown(e); +} +} +} +},_resizeEditor:function(){ +var vp=dojo.window.getBox(); +dojo.marginBox(this.editor.domNode,{w:vp.w,h:vp.h}); +var _5=this.editor.getHeaderHeight(); +var _6=this.editor.getFooterHeight(); +var _7=dojo._getPadBorderExtents(this.editor.domNode); +var _8=dojo._getPadBorderExtents(this.editor.iframe.parentNode); +var _9=dojo._getMarginExtents(this.editor.iframe.parentNode); +var _a=vp.h-(_5+_7.h+_6); +dojo.marginBox(this.editor.iframe.parentNode,{h:_a,w:vp.w}); +dojo.marginBox(this.editor.iframe,{h:_a-(_8.h+_9.h)}); +},_getAltViewNode:function(){ +},_setFullScreen:function(_b){ +var vp=dojo.window.getBox(); +var ed=this.editor; +var _c=dojo.body(); +var _d=ed.domNode.parentNode; +this.isFullscreen=_b; +if(_b){ +while(_d&&_d!==dojo.body()){ +dojo.addClass(_d,"dijitForceStatic"); +_d=_d.parentNode; +} +this._editorResizeHolder=this.editor.resize; +ed.resize=function(){ +}; +ed._fullscreen_oldOnKeyDown=ed.onKeyDown; +ed.onKeyDown=dojo.hitch(this,this._containFocus); +this._origState={}; +this._origiFrameState={}; +var _e=ed.domNode,_f=_e&&_e.style||{}; +this._origState={width:_f.width||"",height:_f.height||"",top:dojo.style(_e,"top")||"",left:dojo.style(_e,"left")||"",position:dojo.style(_e,"position")||"static",marginBox:dojo.marginBox(ed.domNode)}; +var _10=ed.iframe,_11=_10&&_10.style||{}; +var bc=dojo.style(ed.iframe,"backgroundColor"); +this._origiFrameState={backgroundColor:bc||"transparent",width:_11.width||"auto",height:_11.height||"auto",zIndex:_11.zIndex||""}; +dojo.style(ed.domNode,{position:"absolute",top:"0px",left:"0px",zIndex:this.zIndex,width:vp.w+"px",height:vp.h+"px"}); +dojo.style(ed.iframe,{height:"100%",width:"100%",zIndex:this.zIndex,backgroundColor:bc!=="transparent"&&bc!=="rgba(0, 0, 0, 0)"?bc:"white"}); +dojo.style(ed.iframe.parentNode,{height:"95%",width:"100%"}); +if(_c.style&&_c.style.overflow){ +this._oldOverflow=dojo.style(_c,"overflow"); +}else{ +this._oldOverflow=""; +} +if(dojo.isIE&&!dojo.isQuirks){ +if(_c.parentNode&&_c.parentNode.style&&_c.parentNode.style.overflow){ +this._oldBodyParentOverflow=_c.parentNode.style.overflow; +}else{ +try{ +this._oldBodyParentOverflow=dojo.style(_c.parentNode,"overflow"); +} +catch(e){ +this._oldBodyParentOverflow="scroll"; +} +} +dojo.style(_c.parentNode,"overflow","hidden"); +} +dojo.style(_c,"overflow","hidden"); +var _12=function(){ +var vp=dojo.window.getBox(); +if("_prevW" in this&&"_prevH" in this){ +if(vp.w===this._prevW&&vp.h===this._prevH){ +return; +} +}else{ +this._prevW=vp.w; +this._prevH=vp.h; +} +if(this._resizer){ +clearTimeout(this._resizer); +delete this._resizer; +} +this._resizer=setTimeout(dojo.hitch(this,function(){ +delete this._resizer; +this._resizeEditor(); +}),10); +}; +this._resizeHandle=dojo.connect(window,"onresize",this,_12); +this._resizeHandle2=dojo.connect(ed,"resize",dojo.hitch(this,function(){ +if(this._resizer){ +clearTimeout(this._resizer); +delete this._resizer; +} +this._resizer=setTimeout(dojo.hitch(this,function(){ +delete this._resizer; +this._resizeEditor(); +}),10); +})); +this._resizeEditor(); +var dn=this.editor.toolbar.domNode; +setTimeout(function(){ +dojo.window.scrollIntoView(dn); +},250); +}else{ +if(this._resizeHandle){ +dojo.disconnect(this._resizeHandle); +this._resizeHandle=null; +} +if(this._resizeHandle2){ +dojo.disconnect(this._resizeHandle2); +this._resizeHandle2=null; +} +if(this._rst){ +clearTimeout(this._rst); +this._rst=null; +} +while(_d&&_d!==dojo.body()){ +dojo.removeClass(_d,"dijitForceStatic"); +_d=_d.parentNode; +} +if(this._editorResizeHolder){ +this.editor.resize=this._editorResizeHolder; +} +if(!this._origState&&!this._origiFrameState){ +return; +} +if(ed._fullscreen_oldOnKeyDown){ +ed.onKeyDown=ed._fullscreen_oldOnKeyDown; +delete ed._fullscreen_oldOnKeyDown; +} +var _13=this; +setTimeout(function(){ +var mb=_13._origState.marginBox; +var oh=_13._origState.height; +if(dojo.isIE&&!dojo.isQuirks){ +_c.parentNode.style.overflow=_13._oldBodyParentOverflow; +delete _13._oldBodyParentOverflow; +} +dojo.style(_c,"overflow",_13._oldOverflow); +delete _13._oldOverflow; +dojo.style(ed.domNode,_13._origState); +dojo.style(ed.iframe.parentNode,{height:"",width:""}); +dojo.style(ed.iframe,_13._origiFrameState); +delete _13._origState; +delete _13._origiFrameState; +var _14=dijit.getEnclosingWidget(ed.domNode.parentNode); +if(_14&&_14.resize){ +_14.resize(); +}else{ +if(!oh||oh.indexOf("%")<0){ +setTimeout(dojo.hitch(this,function(){ +ed.resize({h:mb.h}); +}),0); +} +} +dojo.window.scrollIntoView(_13.editor.toolbar.domNode); +},100); +} +},destroy:function(){ +if(this._resizeHandle){ +dojo.disconnect(this._resizeHandle); +this._resizeHandle=null; +} +if(this._resizeHandle2){ +dojo.disconnect(this._resizeHandle2); +this._resizeHandle2=null; +} +if(this._resizer){ +clearTimeout(this._resizer); +this._resizer=null; +} +this.inherited(arguments); +}}); +dojo.subscribe(dijit._scopeName+".Editor.getPlugin",null,function(o){ +if(o.plugin){ +return; +} +var _15=o.args.name.toLowerCase(); +if(_15==="fullscreen"){ +o.plugin=new dijit._editor.plugins.FullScreen({zIndex:("zIndex" in o.args)?o.args.zIndex:500}); +} +}); +} diff --git a/lib/dijit/_editor/plugins/LinkDialog.js b/lib/dijit/_editor/plugins/LinkDialog.js new file mode 100644 index 000000000..71de3ad8f --- /dev/null +++ b/lib/dijit/_editor/plugins/LinkDialog.js @@ -0,0 +1,236 @@ +/* + Copyright (c) 2004-2010, The Dojo Foundation All Rights Reserved. + Available via Academic Free License >= 2.1 OR the modified BSD license. + see: http://dojotoolkit.org/license for details +*/ + + +if(!dojo._hasResource["dijit._editor.plugins.LinkDialog"]){ +dojo._hasResource["dijit._editor.plugins.LinkDialog"]=true; +dojo.provide("dijit._editor.plugins.LinkDialog"); +dojo.require("dijit._Widget"); +dojo.require("dijit._Templated"); +dojo.require("dijit._editor._Plugin"); +dojo.require("dijit.TooltipDialog"); +dojo.require("dijit.form.Button"); +dojo.require("dijit.form.ValidationTextBox"); +dojo.require("dijit.form.Select"); +dojo.require("dijit._editor.range"); +dojo.require("dojo.i18n"); +dojo.require("dojo.string"); +dojo.requireLocalization("dijit","common",null,"ROOT,ar,ca,cs,da,de,el,es,fi,fr,he,hu,it,ja,ko,nb,nl,pl,pt,pt-pt,ro,ru,sk,sl,sv,th,tr,zh,zh-tw"); +dojo.requireLocalization("dijit._editor","LinkDialog",null,"ROOT,ar,ca,cs,da,de,el,es,fi,fr,he,hu,it,ja,ko,nb,nl,pl,pt,pt-pt,ro,ru,sk,sl,sv,th,tr,zh,zh-tw"); +dojo.declare("dijit._editor.plugins.LinkDialog",dijit._editor._Plugin,{buttonClass:dijit.form.DropDownButton,useDefaultCommand:false,urlRegExp:"((https?|ftps?|file)\\://|./|/|)(/[a-zA-Z]{1,1}:/|)(((?:(?:[\\da-zA-Z](?:[-\\da-zA-Z]{0,61}[\\da-zA-Z])?)\\.)*(?:[a-zA-Z](?:[-\\da-zA-Z]{0,80}[\\da-zA-Z])?)\\.?)|(((\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])\\.){3}(\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])|(0[xX]0*[\\da-fA-F]?[\\da-fA-F]\\.){3}0[xX]0*[\\da-fA-F]?[\\da-fA-F]|(0+[0-3][0-7][0-7]\\.){3}0+[0-3][0-7][0-7]|(0|[1-9]\\d{0,8}|[1-3]\\d{9}|4[01]\\d{8}|42[0-8]\\d{7}|429[0-3]\\d{6}|4294[0-8]\\d{5}|42949[0-5]\\d{4}|429496[0-6]\\d{3}|4294967[01]\\d{2}|42949672[0-8]\\d|429496729[0-5])|0[xX]0*[\\da-fA-F]{1,8}|([\\da-fA-F]{1,4}\\:){7}[\\da-fA-F]{1,4}|([\\da-fA-F]{1,4}\\:){6}((\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])\\.){3}(\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])))(\\:\\d+)?(/(?:[^?#\\s/]+/)*(?:[^?#\\s/]+(?:\\?[^?#\\s/]*)?(?:#.*)?)?)?",emailRegExp:"?",htmlTemplate:"${textInput}",tag:"a",_hostRxp:new RegExp("^((([^\\[:]+):)?([^@]+)@)?(\\[([^\\]]+)\\]|([^\\[:]*))(:([0-9]+))?$"),_userAtRxp:new RegExp("^([!#-'*+\\-\\/-9=?A-Z^-~]+[.])*[!#-'*+\\-\\/-9=?A-Z^-~]+@","i"),linkDialogTemplate:["
    ","","","","
    ","","","","
    ","","","","
    ","","","
    "].join(""),_initButton:function(){ +var _1=this; +this.tag=this.command=="insertImage"?"img":"a"; +var _2=dojo.mixin(dojo.i18n.getLocalization("dijit","common",this.lang),dojo.i18n.getLocalization("dijit._editor","LinkDialog",this.lang)); +var _3=(this.dropDown=new dijit.TooltipDialog({title:_2[this.command+"Title"],execute:dojo.hitch(this,"setValue"),onOpen:function(){ +_1._onOpenDialog(); +dijit.TooltipDialog.prototype.onOpen.apply(this,arguments); +},onCancel:function(){ +setTimeout(dojo.hitch(_1,"_onCloseDialog"),0); +}})); +_2.urlRegExp=this.urlRegExp; +_2.id=dijit.getUniqueId(this.editor.id); +this._uniqueId=_2.id; +this._setContent(_3.title+"
    "+dojo.string.substitute(this.linkDialogTemplate,_2)); +_3.startup(); +this._urlInput=dijit.byId(this._uniqueId+"_urlInput"); +this._textInput=dijit.byId(this._uniqueId+"_textInput"); +this._setButton=dijit.byId(this._uniqueId+"_setButton"); +this.connect(dijit.byId(this._uniqueId+"_cancelButton"),"onClick",function(){ +this.dropDown.onCancel(); +}); +if(this._urlInput){ +this.connect(this._urlInput,"onChange","_checkAndFixInput"); +} +if(this._textInput){ +this.connect(this._textInput,"onChange","_checkAndFixInput"); +} +this._urlRegExp=new RegExp("^"+this.urlRegExp+"$","i"); +this._emailRegExp=new RegExp("^"+this.emailRegExp+"$","i"); +this._urlInput.isValid=dojo.hitch(this,function(){ +var _4=this._urlInput.get("value"); +return this._urlRegExp.test(_4)||this._emailRegExp.test(_4); +}); +this._connectTagEvents(); +this.inherited(arguments); +},_checkAndFixInput:function(){ +var _5=this; +var _6=this._urlInput.get("value"); +var _7=function(_8){ +var _9=false; +var _a=false; +if(_8&&_8.length>1){ +_8=dojo.trim(_8); +if(_8.indexOf("mailto:")!==0){ +if(_8.indexOf("/")>0){ +if(_8.indexOf("://")===-1){ +if(_8.charAt(0)!=="/"&&_8.indexOf("./")!==0){ +if(_5._hostRxp.test(_8)){ +_9=true; +} +} +} +}else{ +if(_5._userAtRxp.test(_8)){ +_a=true; +} +} +} +} +if(_9){ +_5._urlInput.set("value","http://"+_8); +} +if(_a){ +_5._urlInput.set("value","mailto:"+_8); +} +_5._setButton.set("disabled",!_5._isValid()); +}; +if(this._delayedCheck){ +clearTimeout(this._delayedCheck); +this._delayedCheck=null; +} +this._delayedCheck=setTimeout(function(){ +_7(_6); +},250); +},_connectTagEvents:function(){ +this.editor.onLoadDeferred.addCallback(dojo.hitch(this,function(){ +this.connect(this.editor.editNode,"ondblclick",this._onDblClick); +})); +},_isValid:function(){ +return this._urlInput.isValid()&&this._textInput.isValid(); +},_setContent:function(_b){ +this.dropDown.set("content",_b); +},_checkValues:function(_c){ +if(_c&&_c.urlInput){ +_c.urlInput=_c.urlInput.replace(/"/g,"""); +} +return _c; +},setValue:function(_d){ +this._onCloseDialog(); +if(dojo.isIE){ +var _e=dijit.range.getSelection(this.editor.window); +var _f=_e.getRangeAt(0); +var a=_f.endContainer; +if(a.nodeType===3){ +a=a.parentNode; +} +if(a&&(a.nodeName&&a.nodeName.toLowerCase()!==this.tag)){ +a=dojo.withGlobal(this.editor.window,"getSelectedElement",dijit._editor.selection,[this.tag]); +} +if(a&&(a.nodeName&&a.nodeName.toLowerCase()===this.tag)){ +if(this.editor.queryCommandEnabled("unlink")){ +dojo.withGlobal(this.editor.window,"selectElementChildren",dijit._editor.selection,[a]); +this.editor.execCommand("unlink"); +} +} +} +_d=this._checkValues(_d); +this.editor.execCommand("inserthtml",dojo.string.substitute(this.htmlTemplate,_d)); +},_onCloseDialog:function(){ +this.editor.focus(); +},_getCurrentValues:function(a){ +var url,_10,_11; +if(a&&a.tagName.toLowerCase()===this.tag){ +url=a.getAttribute("_djrealurl")||a.getAttribute("href"); +_11=a.getAttribute("target")||"_self"; +_10=a.textContent||a.innerText; +dojo.withGlobal(this.editor.window,"selectElement",dijit._editor.selection,[a,true]); +}else{ +_10=dojo.withGlobal(this.editor.window,dijit._editor.selection.getSelectedText); +} +return {urlInput:url||"",textInput:_10||"",targetSelect:_11||""}; +},_onOpenDialog:function(){ +var a; +if(dojo.isIE){ +var sel=dijit.range.getSelection(this.editor.window); +var _12=sel.getRangeAt(0); +a=_12.endContainer; +if(a.nodeType===3){ +a=a.parentNode; +} +if(a&&(a.nodeName&&a.nodeName.toLowerCase()!==this.tag)){ +a=dojo.withGlobal(this.editor.window,"getSelectedElement",dijit._editor.selection,[this.tag]); +} +}else{ +a=dojo.withGlobal(this.editor.window,"getAncestorElement",dijit._editor.selection,[this.tag]); +} +this.dropDown.reset(); +this._setButton.set("disabled",true); +this.dropDown.set("value",this._getCurrentValues(a)); +},_onDblClick:function(e){ +if(e&&e.target){ +var t=e.target; +var tg=t.tagName?t.tagName.toLowerCase():""; +if(tg===this.tag&&dojo.attr(t,"href")){ +dojo.withGlobal(this.editor.window,"selectElement",dijit._editor.selection,[t]); +this.editor.onDisplayChanged(); +setTimeout(dojo.hitch(this,function(){ +this.button.set("disabled",false); +this.button.openDropDown(); +}),10); +} +} +}}); +dojo.declare("dijit._editor.plugins.ImgLinkDialog",[dijit._editor.plugins.LinkDialog],{linkDialogTemplate:["
    ","","","","
    ","","","","
    ","","
    ","","","
    "].join(""),htmlTemplate:"\"${textInput}\"",tag:"img",_getCurrentValues:function(img){ +var url,_13; +if(img&&img.tagName.toLowerCase()===this.tag){ +url=img.getAttribute("_djrealurl")||img.getAttribute("src"); +_13=img.getAttribute("alt"); +dojo.withGlobal(this.editor.window,"selectElement",dijit._editor.selection,[img,true]); +}else{ +_13=dojo.withGlobal(this.editor.window,dijit._editor.selection.getSelectedText); +} +return {urlInput:url||"",textInput:_13||""}; +},_isValid:function(){ +return this._urlInput.isValid(); +},_connectTagEvents:function(){ +this.inherited(arguments); +this.editor.onLoadDeferred.addCallback(dojo.hitch(this,function(){ +this.connect(this.editor.editNode,"onmousedown",this._selectTag); +})); +},_selectTag:function(e){ +if(e&&e.target){ +var t=e.target; +var tg=t.tagName?t.tagName.toLowerCase():""; +if(tg===this.tag){ +dojo.withGlobal(this.editor.window,"selectElement",dijit._editor.selection,[t]); +} +} +},_checkValues:function(_14){ +if(_14&&_14.urlInput){ +_14.urlInput=_14.urlInput.replace(/"/g,"""); +} +if(_14&&_14.textInput){ +_14.textInput=_14.textInput.replace(/"/g,"""); +} +return _14; +},_onDblClick:function(e){ +if(e&&e.target){ +var t=e.target; +var tg=t.tagName?t.tagName.toLowerCase():""; +if(tg===this.tag&&dojo.attr(t,"src")){ +dojo.withGlobal(this.editor.window,"selectElement",dijit._editor.selection,[t]); +this.editor.onDisplayChanged(); +setTimeout(dojo.hitch(this,function(){ +this.button.set("disabled",false); +this.button.openDropDown(); +}),10); +} +} +}}); +dojo.subscribe(dijit._scopeName+".Editor.getPlugin",null,function(o){ +if(o.plugin){ +return; +} +switch(o.args.name){ +case "createLink": +o.plugin=new dijit._editor.plugins.LinkDialog({command:o.args.name}); +break; +case "insertImage": +o.plugin=new dijit._editor.plugins.ImgLinkDialog({command:o.args.name}); +break; +} +}); +} diff --git a/lib/dijit/_editor/plugins/NewPage.js b/lib/dijit/_editor/plugins/NewPage.js new file mode 100644 index 000000000..14c2cfa62 --- /dev/null +++ b/lib/dijit/_editor/plugins/NewPage.js @@ -0,0 +1,36 @@ +/* + Copyright (c) 2004-2010, The Dojo Foundation All Rights Reserved. + Available via Academic Free License >= 2.1 OR the modified BSD license. + see: http://dojotoolkit.org/license for details +*/ + + +if(!dojo._hasResource["dijit._editor.plugins.NewPage"]){ +dojo._hasResource["dijit._editor.plugins.NewPage"]=true; +dojo.provide("dijit._editor.plugins.NewPage"); +dojo.require("dijit._editor._Plugin"); +dojo.require("dijit.form.Button"); +dojo.require("dojo.i18n"); +dojo.requireLocalization("dijit._editor","commands",null,"ROOT,ar,ca,cs,da,de,el,es,fi,fr,he,hu,it,ja,ko,nb,nl,pl,pt,pt-pt,ro,ru,sk,sl,sv,th,tr,zh,zh-tw"); +dojo.declare("dijit._editor.plugins.NewPage",dijit._editor._Plugin,{content:"
    ",_initButton:function(){ +var _1=dojo.i18n.getLocalization("dijit._editor","commands"),_2=this.editor; +this.button=new dijit.form.Button({label:_1["newPage"],dir:_2.dir,lang:_2.lang,showLabel:false,iconClass:this.iconClassPrefix+" "+this.iconClassPrefix+"NewPage",tabIndex:"-1",onClick:dojo.hitch(this,"_newPage")}); +},setEditor:function(_3){ +this.editor=_3; +this._initButton(); +},_newPage:function(){ +this.editor.beginEditing(); +this.editor.set("value",this.content); +this.editor.endEditing(); +this.editor.focus(); +}}); +dojo.subscribe(dijit._scopeName+".Editor.getPlugin",null,function(o){ +if(o.plugin){ +return; +} +var _4=o.args.name.toLowerCase(); +if(_4==="newpage"){ +o.plugin=new dijit._editor.plugins.NewPage({content:("content" in o.args)?o.args.content:"
    "}); +} +}); +} diff --git a/lib/dijit/_editor/plugins/Print.js b/lib/dijit/_editor/plugins/Print.js new file mode 100644 index 000000000..b2e739aee --- /dev/null +++ b/lib/dijit/_editor/plugins/Print.js @@ -0,0 +1,65 @@ +/* + Copyright (c) 2004-2010, The Dojo Foundation All Rights Reserved. + Available via Academic Free License >= 2.1 OR the modified BSD license. + see: http://dojotoolkit.org/license for details +*/ + + +if(!dojo._hasResource["dijit._editor.plugins.Print"]){ +dojo._hasResource["dijit._editor.plugins.Print"]=true; +dojo.provide("dijit._editor.plugins.Print"); +dojo.require("dijit._editor._Plugin"); +dojo.require("dijit.form.Button"); +dojo.require("dojo.i18n"); +dojo.requireLocalization("dijit._editor","commands",null,"ROOT,ar,ca,cs,da,de,el,es,fi,fr,he,hu,it,ja,ko,nb,nl,pl,pt,pt-pt,ro,ru,sk,sl,sv,th,tr,zh,zh-tw"); +dojo.declare("dijit._editor.plugins.Print",dijit._editor._Plugin,{_initButton:function(){ +var _1=dojo.i18n.getLocalization("dijit._editor","commands"),_2=this.editor; +this.button=new dijit.form.Button({label:_1["print"],dir:_2.dir,lang:_2.lang,showLabel:false,iconClass:this.iconClassPrefix+" "+this.iconClassPrefix+"Print",tabIndex:"-1",onClick:dojo.hitch(this,"_print")}); +},setEditor:function(_3){ +this.editor=_3; +this._initButton(); +this.editor.onLoadDeferred.addCallback(dojo.hitch(this,function(){ +if(!this.editor.iframe.contentWindow["print"]){ +this.button.set("disabled",true); +} +})); +},_print:function(){ +var _4=this.editor.iframe; +if(_4.contentWindow["print"]){ +if(!dojo.isOpera&&!dojo.isChrome){ +dijit.focus(_4); +_4.contentWindow.print(); +}else{ +var _5=this.editor.document; +var _6=this.editor.get("value"); +_6=""+_6+""; +var _7=window.open("javascript: ''","","status=0,menubar=0,location=0,toolbar=0,"+"width=1,height=1,resizable=0,scrollbars=0"); +_7.document.open(); +_7.document.write(_6); +_7.document.close(); +var _8=[]; +var _9=_5.getElementsByTagName("style"); +if(_9){ +var i; +for(i=0;i<_9.length;i++){ +var _a=_9[i].innerHTML; +var _b=_7.document.createElement("style"); +_b.appendChild(_7.document.createTextNode(_a)); +_7.document.getElementsByTagName("head")[0].appendChild(_b); +} +} +_7.print(); +_7.close(); +} +} +}}); +dojo.subscribe(dijit._scopeName+".Editor.getPlugin",null,function(o){ +if(o.plugin){ +return; +} +var _c=o.args.name.toLowerCase(); +if(_c==="print"){ +o.plugin=new dijit._editor.plugins.Print({command:"print"}); +} +}); +} diff --git a/lib/dijit/_editor/plugins/TabIndent.js b/lib/dijit/_editor/plugins/TabIndent.js new file mode 100644 index 000000000..74cda400f --- /dev/null +++ b/lib/dijit/_editor/plugins/TabIndent.js @@ -0,0 +1,33 @@ +/* + Copyright (c) 2004-2010, The Dojo Foundation All Rights Reserved. + Available via Academic Free License >= 2.1 OR the modified BSD license. + see: http://dojotoolkit.org/license for details +*/ + + +if(!dojo._hasResource["dijit._editor.plugins.TabIndent"]){ +dojo._hasResource["dijit._editor.plugins.TabIndent"]=true; +dojo.provide("dijit._editor.plugins.TabIndent"); +dojo.experimental("dijit._editor.plugins.TabIndent"); +dojo.require("dijit._editor._Plugin"); +dojo.require("dijit.form.ToggleButton"); +dojo.declare("dijit._editor.plugins.TabIndent",dijit._editor._Plugin,{useDefaultCommand:false,buttonClass:dijit.form.ToggleButton,command:"tabIndent",_initButton:function(){ +this.inherited(arguments); +var e=this.editor; +this.connect(this.button,"onChange",function(_1){ +e.set("isTabIndent",_1); +}); +this.updateState(); +},updateState:function(){ +this.button.set("checked",this.editor.isTabIndent,false); +}}); +dojo.subscribe(dijit._scopeName+".Editor.getPlugin",null,function(o){ +if(o.plugin){ +return; +} +switch(o.args.name){ +case "tabIndent": +o.plugin=new dijit._editor.plugins.TabIndent({command:o.args.name}); +} +}); +} diff --git a/lib/dijit/_editor/plugins/TextColor.js b/lib/dijit/_editor/plugins/TextColor.js new file mode 100644 index 000000000..da7bbc9a6 --- /dev/null +++ b/lib/dijit/_editor/plugins/TextColor.js @@ -0,0 +1,62 @@ +/* + Copyright (c) 2004-2010, The Dojo Foundation All Rights Reserved. + Available via Academic Free License >= 2.1 OR the modified BSD license. + see: http://dojotoolkit.org/license for details +*/ + + +if(!dojo._hasResource["dijit._editor.plugins.TextColor"]){ +dojo._hasResource["dijit._editor.plugins.TextColor"]=true; +dojo.provide("dijit._editor.plugins.TextColor"); +dojo.require("dijit._editor._Plugin"); +dojo.require("dijit.ColorPalette"); +dojo.declare("dijit._editor.plugins.TextColor",dijit._editor._Plugin,{buttonClass:dijit.form.DropDownButton,useDefaultCommand:false,constructor:function(){ +this.dropDown=new dijit.ColorPalette(); +this.connect(this.dropDown,"onChange",function(_1){ +this.editor.execCommand(this.command,_1); +}); +},updateState:function(){ +var _2=this.editor; +var _3=this.command; +if(!_2||!_2.isLoaded||!_3.length){ +return; +} +if(this.button){ +var _4; +try{ +_4=_2.queryCommandValue(_3)||""; +} +catch(e){ +_4=""; +} +} +if(_4==""){ +_4="#000000"; +} +if(_4=="transparent"){ +_4="#ffffff"; +} +if(typeof _4=="string"){ +if(_4.indexOf("rgb")>-1){ +_4=dojo.colorFromRgb(_4).toHex(); +} +}else{ +_4=((_4&255)<<16)|(_4&65280)|((_4&16711680)>>>16); +_4=_4.toString(16); +_4="#000000".slice(0,7-_4.length)+_4; +} +if(_4!==this.dropDown.get("value")){ +this.dropDown.set("value",_4,false); +} +}}); +dojo.subscribe(dijit._scopeName+".Editor.getPlugin",null,function(o){ +if(o.plugin){ +return; +} +switch(o.args.name){ +case "foreColor": +case "hiliteColor": +o.plugin=new dijit._editor.plugins.TextColor({command:o.args.name}); +} +}); +} diff --git a/lib/dijit/_editor/plugins/ToggleDir.js b/lib/dijit/_editor/plugins/ToggleDir.js new file mode 100644 index 000000000..f5ecb7909 --- /dev/null +++ b/lib/dijit/_editor/plugins/ToggleDir.js @@ -0,0 +1,42 @@ +/* + Copyright (c) 2004-2010, The Dojo Foundation All Rights Reserved. + Available via Academic Free License >= 2.1 OR the modified BSD license. + see: http://dojotoolkit.org/license for details +*/ + + +if(!dojo._hasResource["dijit._editor.plugins.ToggleDir"]){ +dojo._hasResource["dijit._editor.plugins.ToggleDir"]=true; +dojo.provide("dijit._editor.plugins.ToggleDir"); +dojo.experimental("dijit._editor.plugins.ToggleDir"); +dojo.require("dijit._editor._Plugin"); +dojo.require("dijit.form.ToggleButton"); +dojo.declare("dijit._editor.plugins.ToggleDir",dijit._editor._Plugin,{useDefaultCommand:false,command:"toggleDir",buttonClass:dijit.form.ToggleButton,_initButton:function(){ +this.inherited(arguments); +this.editor.onLoadDeferred.addCallback(dojo.hitch(this,function(){ +var _1=this.editor.editorObject.contentWindow.document.documentElement; +_1=_1.getElementsByTagName("body")[0]; +var _2=dojo.getComputedStyle(_1).direction=="ltr"; +this.button.set("checked",!_2); +this.connect(this.button,"onChange","_setRtl"); +})); +},updateState:function(){ +},_setRtl:function(_3){ +var _4="ltr"; +if(_3){ +_4="rtl"; +} +var _5=this.editor.editorObject.contentWindow.document.documentElement; +_5=_5.getElementsByTagName("body")[0]; +_5.dir=_4; +}}); +dojo.subscribe(dijit._scopeName+".Editor.getPlugin",null,function(o){ +if(o.plugin){ +return; +} +switch(o.args.name){ +case "toggleDir": +o.plugin=new dijit._editor.plugins.ToggleDir({command:o.args.name}); +} +}); +} diff --git a/lib/dijit/_editor/plugins/ViewSource.js b/lib/dijit/_editor/plugins/ViewSource.js new file mode 100644 index 000000000..41ea2970f --- /dev/null +++ b/lib/dijit/_editor/plugins/ViewSource.js @@ -0,0 +1,317 @@ +/* + Copyright (c) 2004-2010, The Dojo Foundation All Rights Reserved. + Available via Academic Free License >= 2.1 OR the modified BSD license. + see: http://dojotoolkit.org/license for details +*/ + + +if(!dojo._hasResource["dijit._editor.plugins.ViewSource"]){ +dojo._hasResource["dijit._editor.plugins.ViewSource"]=true; +dojo.provide("dijit._editor.plugins.ViewSource"); +dojo.require("dojo.window"); +dojo.require("dojo.i18n"); +dojo.require("dijit._editor._Plugin"); +dojo.require("dijit.form.Button"); +dojo.requireLocalization("dijit._editor","commands",null,"ROOT,ar,ca,cs,da,de,el,es,fi,fr,he,hu,it,ja,ko,nb,nl,pl,pt,pt-pt,ro,ru,sk,sl,sv,th,tr,zh,zh-tw"); +dojo.declare("dijit._editor.plugins.ViewSource",dijit._editor._Plugin,{stripScripts:true,stripComments:true,stripIFrames:true,readOnly:false,_fsPlugin:null,toggle:function(){ +if(dojo.isWebKit){ +this._vsFocused=true; +} +this.button.set("checked",!this.button.get("checked")); +},_initButton:function(){ +var _1=dojo.i18n.getLocalization("dijit._editor","commands"),_2=this.editor; +this.button=new dijit.form.ToggleButton({label:_1["viewSource"],dir:_2.dir,lang:_2.lang,showLabel:false,iconClass:this.iconClassPrefix+" "+this.iconClassPrefix+"ViewSource",tabIndex:"-1",onChange:dojo.hitch(this,"_showSource")}); +if(dojo.isIE==7){ +this._ieFixNode=dojo.create("div",{style:{opacity:"0",zIndex:"-1000",position:"absolute",top:"-1000px"}},dojo.body()); +} +this.button.set("readOnly",false); +},setEditor:function(_3){ +this.editor=_3; +this._initButton(); +this.editor.addKeyHandler(dojo.keys.F12,true,true,dojo.hitch(this,function(e){ +this.button.focus(); +this.toggle(); +dojo.stopEvent(e); +setTimeout(dojo.hitch(this,function(){ +this.editor.focus(); +}),100); +})); +},_showSource:function(_4){ +var ed=this.editor; +var _5=ed._plugins; +var _6; +this._sourceShown=_4; +var _7=this; +try{ +if(!this.sourceArea){ +this._createSourceView(); +} +if(_4){ +ed._sourceQueryCommandEnabled=ed.queryCommandEnabled; +ed.queryCommandEnabled=function(_8){ +var _9=_8.toLowerCase(); +if(_9==="viewsource"){ +return true; +}else{ +return false; +} +}; +this.editor.onDisplayChanged(); +_6=ed.get("value"); +_6=this._filter(_6); +ed.set("value",_6); +this._pluginList=[]; +this._disabledPlugins=dojo.filter(_5,function(p){ +if(p&&p.button&&!p.button.get("disabled")&&!(p instanceof dijit._editor.plugins.ViewSource)){ +p._vs_updateState=p.updateState; +p.updateState=function(){ +return false; +}; +p.button.set("disabled",true); +if(p.command){ +switch(p.command){ +case "bold": +case "italic": +case "underline": +case "strikethrough": +case "superscript": +case "subscript": +p.button.set("checked",false); +break; +default: +break; +} +} +return true; +} +}); +if(this._fsPlugin){ +this._fsPlugin._getAltViewNode=function(){ +return _7.sourceArea; +}; +} +this.sourceArea.value=_6; +var is=dojo.marginBox(ed.iframe.parentNode); +dojo.marginBox(this.sourceArea,{w:is.w,h:is.h}); +dojo.style(ed.iframe,"display","none"); +dojo.style(this.sourceArea,{display:"block"}); +var _a=function(){ +var vp=dojo.window.getBox(); +if("_prevW" in this&&"_prevH" in this){ +if(vp.w===this._prevW&&vp.h===this._prevH){ +return; +}else{ +this._prevW=vp.w; +this._prevH=vp.h; +} +}else{ +this._prevW=vp.w; +this._prevH=vp.h; +} +if(this._resizer){ +clearTimeout(this._resizer); +delete this._resizer; +} +this._resizer=setTimeout(dojo.hitch(this,function(){ +delete this._resizer; +this._resize(); +}),10); +}; +this._resizeHandle=dojo.connect(window,"onresize",this,_a); +setTimeout(dojo.hitch(this,this._resize),100); +this.editor.onNormalizedDisplayChanged(); +}else{ +if(!ed._sourceQueryCommandEnabled){ +return; +} +dojo.disconnect(this._resizeHandle); +delete this._resizeHandle; +ed.queryCommandEnabled=ed._sourceQueryCommandEnabled; +if(!this._readOnly){ +_6=this.sourceArea.value; +_6=this._filter(_6); +ed.beginEditing(); +ed.set("value",_6); +ed.endEditing(); +} +dojo.forEach(this._disabledPlugins,function(p){ +p.button.set("disabled",false); +if(p._vs_updateState){ +p.updateState=p._vs_updateState; +} +}); +this._disabledPlugins=null; +dojo.style(this.sourceArea,"display","none"); +dojo.style(ed.iframe,"display","block"); +delete ed._sourceQueryCommandEnabled; +this.editor.onDisplayChanged(); +} +setTimeout(dojo.hitch(this,function(){ +var _b=ed.domNode.parentNode; +if(_b){ +var _c=dijit.getEnclosingWidget(_b); +if(_c&&_c.resize){ +_c.resize(); +} +} +ed.resize(); +}),300); +} +catch(e){ +} +},_resize:function(){ +var ed=this.editor; +var _d=ed.getHeaderHeight(); +var fH=ed.getFooterHeight(); +var eb=dojo.position(ed.domNode); +var _e=dojo._getPadBorderExtents(ed.iframe.parentNode); +var _f=dojo._getMarginExtents(ed.iframe.parentNode); +var _10=dojo._getPadBorderExtents(ed.domNode); +var _11=dojo._getMarginExtents(ed.domNode); +var edb={w:eb.w-(_10.w+_11.w),h:eb.h-(_d+_10.h+_11.h+fH)}; +if(this._fsPlugin&&this._fsPlugin.isFullscreen){ +var vp=dojo.window.getBox(); +edb.w=(vp.w-_10.w); +edb.h=(vp.h-(_d+_10.h+fH)); +} +if(dojo.isIE){ +edb.h-=2; +} +if(this._ieFixNode){ +var _12=-this._ieFixNode.offsetTop/1000; +edb.w=Math.floor((edb.w+0.9)/_12); +edb.h=Math.floor((edb.h+0.9)/_12); +} +dojo.marginBox(this.sourceArea,{w:edb.w-(_e.w+_f.w),h:edb.h-(_e.h+_f.h)}); +dojo.marginBox(ed.iframe.parentNode,{h:edb.h}); +},_createSourceView:function(){ +var ed=this.editor; +var _13=ed._plugins; +this.sourceArea=dojo.create("textarea"); +if(this.readOnly){ +dojo.attr(this.sourceArea,"readOnly",true); +this._readOnly=true; +} +dojo.style(this.sourceArea,{padding:"0px",margin:"0px",borderWidth:"0px",borderStyle:"none"}); +dojo.place(this.sourceArea,ed.iframe,"before"); +if(dojo.isIE&&ed.iframe.parentNode.lastChild!==ed.iframe){ +dojo.style(ed.iframe.parentNode.lastChild,{width:"0px",height:"0px",padding:"0px",margin:"0px",borderWidth:"0px",borderStyle:"none"}); +} +ed._viewsource_oldFocus=ed.focus; +var _14=this; +ed.focus=function(){ +if(_14._sourceShown){ +_14.setSourceAreaCaret(); +}else{ +try{ +if(this._vsFocused){ +delete this._vsFocused; +dijit.focus(ed.editNode); +}else{ +ed._viewsource_oldFocus(); +} +} +catch(e){ +} +} +}; +var i,p; +for(i=0;i<_13.length;i++){ +p=_13[i]; +if(p&&(p.declaredClass==="dijit._editor.plugins.FullScreen"||p.declaredClass===(dijit._scopeName+"._editor.plugins.FullScreen"))){ +this._fsPlugin=p; +break; +} +} +if(this._fsPlugin){ +this._fsPlugin._viewsource_getAltViewNode=this._fsPlugin._getAltViewNode; +this._fsPlugin._getAltViewNode=function(){ +return _14._sourceShown?_14.sourceArea:this._viewsource_getAltViewNode(); +}; +} +this.connect(this.sourceArea,"onkeydown",dojo.hitch(this,function(e){ +if(this._sourceShown&&e.keyCode==dojo.keys.F12&&e.ctrlKey&&e.shiftKey){ +this.button.focus(); +this.button.set("checked",false); +setTimeout(dojo.hitch(this,function(){ +ed.focus(); +}),100); +dojo.stopEvent(e); +} +})); +},_stripScripts:function(_15){ +if(_15){ +_15=_15.replace(/<\s*script[^>]*>((.|\s)*?)<\\?\/\s*script\s*>/ig,""); +_15=_15.replace(/<\s*script\b([^<>]|\s)*>?/ig,""); +_15=_15.replace(/<[^>]*=(\s|)*[("|')]javascript:[^$1][(\s|.)]*[$1][^>]*>/ig,""); +} +return _15; +},_stripComments:function(_16){ +if(_16){ +_16=_16.replace(//g,""); +} +return _16; +},_stripIFrames:function(_17){ +if(_17){ +_17=_17.replace(/<\s*iframe[^>]*>((.|\s)*?)<\\?\/\s*iframe\s*>/ig,""); +} +return _17; +},_filter:function(_18){ +if(_18){ +if(this.stripScripts){ +_18=this._stripScripts(_18); +} +if(this.stripComments){ +_18=this._stripComments(_18); +} +if(this.stripIFrames){ +_18=this._stripIFrames(_18); +} +} +return _18; +},setSourceAreaCaret:function(){ +var win=dojo.global; +var _19=this.sourceArea; +dijit.focus(_19); +if(this._sourceShown&&!this.readOnly){ +if(dojo.isIE){ +if(this.sourceArea.createTextRange){ +var _1a=_19.createTextRange(); +_1a.collapse(true); +_1a.moveStart("character",-99999); +_1a.moveStart("character",0); +_1a.moveEnd("character",0); +_1a.select(); +} +}else{ +if(win.getSelection){ +if(_19.setSelectionRange){ +_19.setSelectionRange(0,0); +} +} +} +} +},destroy:function(){ +if(this._ieFixNode){ +dojo.body().removeChild(this._ieFixNode); +} +if(this._resizer){ +clearTimeout(this._resizer); +delete this._resizer; +} +if(this._resizeHandle){ +dojo.disconnect(this._resizeHandle); +delete this._resizeHandle; +} +this.inherited(arguments); +}}); +dojo.subscribe(dijit._scopeName+".Editor.getPlugin",null,function(o){ +if(o.plugin){ +return; +} +var _1b=o.args.name.toLowerCase(); +if(_1b==="viewsource"){ +o.plugin=new dijit._editor.plugins.ViewSource({readOnly:("readOnly" in o.args)?o.args.readOnly:false,stripComments:("stripComments" in o.args)?o.args.stripComments:true,stripScripts:("stripScripts" in o.args)?o.args.stripScripts:true,stripIFrames:("stripIFrames" in o.args)?o.args.stripIFrames:true}); +} +}); +} diff --git a/lib/dijit/_editor/range.js b/lib/dijit/_editor/range.js new file mode 100644 index 000000000..2b1bd81e3 --- /dev/null +++ b/lib/dijit/_editor/range.js @@ -0,0 +1,453 @@ +/* + Copyright (c) 2004-2010, The Dojo Foundation All Rights Reserved. + Available via Academic Free License >= 2.1 OR the modified BSD license. + see: http://dojotoolkit.org/license for details +*/ + + +if(!dojo._hasResource["dijit._editor.range"]){ +dojo._hasResource["dijit._editor.range"]=true; +dojo.provide("dijit._editor.range"); +dijit.range={}; +dijit.range.getIndex=function(_1,_2){ +var _3=[],_4=[]; +var _5=_2; +var _6=_1; +var _7,n; +while(_1!=_5){ +var i=0; +_7=_1.parentNode; +while((n=_7.childNodes[i++])){ +if(n===_1){ +--i; +break; +} +} +_3.unshift(i); +_4.unshift(i-_7.childNodes.length); +_1=_7; +} +if(_3.length>0&&_6.nodeType==3){ +n=_6.previousSibling; +while(n&&n.nodeType==3){ +_3[_3.length-1]--; +n=n.previousSibling; +} +n=_6.nextSibling; +while(n&&n.nodeType==3){ +_4[_4.length-1]++; +n=n.nextSibling; +} +} +return {o:_3,r:_4}; +}; +dijit.range.getNode=function(_8,_9){ +if(!dojo.isArray(_8)||_8.length==0){ +return _9; +} +var _a=_9; +dojo.every(_8,function(i){ +if(i>=0&&i<_a.childNodes.length){ +_a=_a.childNodes[i]; +}else{ +_a=null; +return false; +} +return true; +}); +return _a; +}; +dijit.range.getCommonAncestor=function(n1,n2,_b){ +_b=_b||n1.ownerDocument.body; +var _c=function(n){ +var as=[]; +while(n){ +as.unshift(n); +if(n!==_b){ +n=n.parentNode; +}else{ +break; +} +} +return as; +}; +var _d=_c(n1); +var _e=_c(n2); +var m=Math.min(_d.length,_e.length); +var _f=_d[0]; +for(var i=1;i0){ +dojo.every(_38.childNodes,function(_3c,i){ +var _3d; +if(_3c.nodeType!=3){ +_36.moveToElementText(_3c); +if(_36.compareEndPoints(_37,_35)>0){ +if(_3b&&_3b.nodeType==3){ +_39=_3b; +_3d=true; +}else{ +_39=_38; +_3a=i; +return false; +} +}else{ +if(i==_38.childNodes.length-1){ +_39=_38; +_3a=_38.childNodes.length; +return false; +} +} +}else{ +if(i==_38.childNodes.length-1){ +_39=_3c; +_3d=true; +} +} +if(_3d&&_39){ +var _3e=dijit.range.adjacentNoneTextNode(_39)[0]; +if(_3e){ +_39=_3e.nextSibling; +}else{ +_39=_38.firstChild; +} +var _3f=dijit.range.adjacentNoneTextNode(_39); +_3e=_3f[0]; +var _40=_3f[1]; +if(_3e){ +_36.moveToElementText(_3e); +_36.collapse(false); +}else{ +_36.moveToElementText(_38); +} +_36.setEndPoint(_37,_35); +_3a=_36.text.length-_40; +return false; +} +_3b=_3c; +return true; +}); +}else{ +_39=_38; +_3a=0; +} +if(!end&&_39.nodeType==1&&_3a==_39.childNodes.length){ +var _41=_39.nextSibling; +if(_41&&_41.nodeType==3){ +_39=_41; +_3a=0; +} +} +return [_39,_3a]; +},setEndPoint:function(_42,_43,_44){ +var _45=_42.duplicate(),_46,len; +if(_43.nodeType!=3){ +if(_44>0){ +_46=_43.childNodes[_44-1]; +if(_46){ +if(_46.nodeType==3){ +_43=_46; +_44=_46.length; +}else{ +if(_46.nextSibling&&_46.nextSibling.nodeType==3){ +_43=_46.nextSibling; +_44=0; +}else{ +_45.moveToElementText(_46.nextSibling?_46:_43); +var _47=_46.parentNode; +var _48=_47.insertBefore(_46.ownerDocument.createTextNode(" "),_46.nextSibling); +_45.collapse(false); +_47.removeChild(_48); +} +} +} +}else{ +_45.moveToElementText(_43); +_45.collapse(true); +} +} +if(_43.nodeType==3){ +var _49=dijit.range.adjacentNoneTextNode(_43); +var _4a=_49[0]; +len=_49[1]; +if(_4a){ +_45.moveToElementText(_4a); +_45.collapse(false); +if(_4a.contentEditable!="inherit"){ +len++; +} +}else{ +_45.moveToElementText(_43.parentNode); +_45.collapse(true); +} +_44+=len; +if(_44>0){ +if(_45.move("character",_44)!=_44){ +console.error("Error when moving!"); +} +} +} +return _45; +},decomposeTextRange:function(_4b){ +var _4c=dijit.range.ie.getEndPoint(_4b); +var _4d=_4c[0],_4e=_4c[1]; +var _4f=_4c[0],_50=_4c[1]; +if(_4b.htmlText.length){ +if(_4b.htmlText==_4b.text){ +_50=_4e+_4b.text.length; +}else{ +_4c=dijit.range.ie.getEndPoint(_4b,true); +_4f=_4c[0],_50=_4c[1]; +} +} +return [_4d,_4e,_4f,_50]; +},setRange:function(_51,_52,_53,_54,_55,_56){ +var _57=dijit.range.ie.setEndPoint(_51,_52,_53); +_51.setEndPoint("StartToStart",_57); +if(!_56){ +var end=dijit.range.ie.setEndPoint(_51,_54,_55); +} +_51.setEndPoint("EndToEnd",end||_57); +return _51; +}}; +dojo.declare("dijit.range.W3CRange",null,{constructor:function(){ +if(arguments.length>0){ +this.setStart(arguments[0][0],arguments[0][1]); +this.setEnd(arguments[0][2],arguments[0][3]); +}else{ +this.commonAncestorContainer=null; +this.startContainer=null; +this.startOffset=0; +this.endContainer=null; +this.endOffset=0; +this.collapsed=true; +} +},_updateInternal:function(){ +if(this.startContainer!==this.endContainer){ +this.commonAncestorContainer=dijit.range.getCommonAncestor(this.startContainer,this.endContainer); +}else{ +this.commonAncestorContainer=this.startContainer; +} +this.collapsed=(this.startContainer===this.endContainer)&&(this.startOffset==this.endOffset); +},setStart:function(_58,_59){ +_59=parseInt(_59); +if(this.startContainer===_58&&this.startOffset==_59){ +return; +} +delete this._cachedBookmark; +this.startContainer=_58; +this.startOffset=_59; +if(!this.endContainer){ +this.setEnd(_58,_59); +}else{ +this._updateInternal(); +} +},setEnd:function(_5a,_5b){ +_5b=parseInt(_5b); +if(this.endContainer===_5a&&this.endOffset==_5b){ +return; +} +delete this._cachedBookmark; +this.endContainer=_5a; +this.endOffset=_5b; +if(!this.startContainer){ +this.setStart(_5a,_5b); +}else{ +this._updateInternal(); +} +},setStartAfter:function(_5c,_5d){ +this._setPoint("setStart",_5c,_5d,1); +},setStartBefore:function(_5e,_5f){ +this._setPoint("setStart",_5e,_5f,0); +},setEndAfter:function(_60,_61){ +this._setPoint("setEnd",_60,_61,1); +},setEndBefore:function(_62,_63){ +this._setPoint("setEnd",_62,_63,0); +},_setPoint:function(_64,_65,_66,ext){ +var _67=dijit.range.getIndex(_65,_65.parentNode).o; +this[_64](_65.parentNode,_67.pop()+ext); +},_getIERange:function(){ +var r=(this._body||this.endContainer.ownerDocument.body).createTextRange(); +dijit.range.ie.setRange(r,this.startContainer,this.startOffset,this.endContainer,this.endOffset,this.collapsed); +return r; +},getBookmark:function(_68){ +this._getIERange(); +return this._cachedBookmark; +},_select:function(){ +var r=this._getIERange(); +r.select(); +},deleteContents:function(){ +var r=this._getIERange(); +r.pasteHTML(""); +this.endContainer=this.startContainer; +this.endOffset=this.startOffset; +this.collapsed=true; +},cloneRange:function(){ +var r=new dijit.range.W3CRange([this.startContainer,this.startOffset,this.endContainer,this.endOffset]); +r._body=this._body; +return r; +},detach:function(){ +this._body=null; +this.commonAncestorContainer=null; +this.startContainer=null; +this.startOffset=0; +this.endContainer=null; +this.endOffset=0; +this.collapsed=true; +}}); +} +} diff --git a/lib/dijit/_editor/selection.js b/lib/dijit/_editor/selection.js new file mode 100644 index 000000000..3c99c0610 --- /dev/null +++ b/lib/dijit/_editor/selection.js @@ -0,0 +1,267 @@ +/* + Copyright (c) 2004-2010, The Dojo Foundation All Rights Reserved. + Available via Academic Free License >= 2.1 OR the modified BSD license. + see: http://dojotoolkit.org/license for details +*/ + + +if(!dojo._hasResource["dijit._editor.selection"]){ +dojo._hasResource["dijit._editor.selection"]=true; +dojo.provide("dijit._editor.selection"); +dojo.mixin(dijit._editor.selection,{getType:function(){ +if(dojo.isIE){ +return dojo.doc.selection.type.toLowerCase(); +}else{ +var _1="text"; +var _2; +try{ +_2=dojo.global.getSelection(); +} +catch(e){ +} +if(_2&&_2.rangeCount==1){ +var _3=_2.getRangeAt(0); +if((_3.startContainer==_3.endContainer)&&((_3.endOffset-_3.startOffset)==1)&&(_3.startContainer.nodeType!=3)){ +_1="control"; +} +} +return _1; +} +},getSelectedText:function(){ +if(dojo.isIE){ +if(dijit._editor.selection.getType()=="control"){ +return null; +} +return dojo.doc.selection.createRange().text; +}else{ +var _4=dojo.global.getSelection(); +if(_4){ +return _4.toString(); +} +} +return ""; +},getSelectedHtml:function(){ +if(dojo.isIE){ +if(dijit._editor.selection.getType()=="control"){ +return null; +} +return dojo.doc.selection.createRange().htmlText; +}else{ +var _5=dojo.global.getSelection(); +if(_5&&_5.rangeCount){ +var i; +var _6=""; +for(i=0;i<_5.rangeCount;i++){ +var _7=_5.getRangeAt(i).cloneContents(); +var _8=dojo.doc.createElement("div"); +_8.appendChild(_7); +_6+=_8.innerHTML; +} +return _6; +} +return null; +} +},getSelectedElement:function(){ +if(dijit._editor.selection.getType()=="control"){ +if(dojo.isIE){ +var _9=dojo.doc.selection.createRange(); +if(_9&&_9.item){ +return dojo.doc.selection.createRange().item(0); +} +}else{ +var _a=dojo.global.getSelection(); +return _a.anchorNode.childNodes[_a.anchorOffset]; +} +} +return null; +},getParentElement:function(){ +if(dijit._editor.selection.getType()=="control"){ +var p=this.getSelectedElement(); +if(p){ +return p.parentNode; +} +}else{ +if(dojo.isIE){ +var r=dojo.doc.selection.createRange(); +r.collapse(true); +return r.parentElement(); +}else{ +var _b=dojo.global.getSelection(); +if(_b){ +var _c=_b.anchorNode; +while(_c&&(_c.nodeType!=1)){ +_c=_c.parentNode; +} +return _c; +} +} +} +return null; +},hasAncestorElement:function(_d){ +return this.getAncestorElement.apply(this,arguments)!=null; +},getAncestorElement:function(_e){ +var _f=this.getSelectedElement()||this.getParentElement(); +return this.getParentOfType(_f,arguments); +},isTag:function(_10,_11){ +if(_10&&_10.tagName){ +var _12=_10.tagName.toLowerCase(); +for(var i=0;i<_11.length;i++){ +var _13=String(_11[i]).toLowerCase(); +if(_12==_13){ +return _13; +} +} +} +return ""; +},getParentOfType:function(_14,_15){ +while(_14){ +if(this.isTag(_14,_15).length){ +return _14; +} +_14=_14.parentNode; +} +return null; +},collapse:function(_16){ +if(window.getSelection){ +var _17=dojo.global.getSelection(); +if(_17.removeAllRanges){ +if(_16){ +_17.collapseToStart(); +}else{ +_17.collapseToEnd(); +} +}else{ +_17.collapse(_16); +} +}else{ +if(dojo.isIE){ +var _18=dojo.doc.selection.createRange(); +_18.collapse(_16); +_18.select(); +} +} +},remove:function(){ +var sel=dojo.doc.selection; +if(dojo.isIE){ +if(sel.type.toLowerCase()!="none"){ +sel.clear(); +} +return sel; +}else{ +sel=dojo.global.getSelection(); +sel.deleteFromDocument(); +return sel; +} +},selectElementChildren:function(_19,_1a){ +var win=dojo.global; +var doc=dojo.doc; +var _1b; +_19=dojo.byId(_19); +if(doc.selection&&dojo.isIE&&dojo.body().createTextRange){ +_1b=_19.ownerDocument.body.createTextRange(); +_1b.moveToElementText(_19); +if(!_1a){ +try{ +_1b.select(); +} +catch(e){ +} +} +}else{ +if(win.getSelection){ +var _1c=dojo.global.getSelection(); +if(dojo.isOpera){ +if(_1c.rangeCount){ +_1b=_1c.getRangeAt(0); +}else{ +_1b=doc.createRange(); +} +_1b.setStart(_19,0); +_1b.setEnd(_19,(_19.nodeType==3)?_19.length:_19.childNodes.length); +_1c.addRange(_1b); +}else{ +_1c.selectAllChildren(_19); +} +} +} +},selectElement:function(_1d,_1e){ +var _1f; +var doc=dojo.doc; +var win=dojo.global; +_1d=dojo.byId(_1d); +if(dojo.isIE&&dojo.body().createTextRange){ +try{ +_1f=dojo.body().createControlRange(); +_1f.addElement(_1d); +if(!_1e){ +_1f.select(); +} +} +catch(e){ +this.selectElementChildren(_1d,_1e); +} +}else{ +if(dojo.global.getSelection){ +var _20=win.getSelection(); +_1f=doc.createRange(); +if(_20.removeAllRanges){ +if(dojo.isOpera){ +if(_20.getRangeAt(0)){ +_1f=_20.getRangeAt(0); +} +} +_1f.selectNode(_1d); +_20.removeAllRanges(); +_20.addRange(_1f); +} +} +} +},inSelection:function(_21){ +if(_21){ +var _22; +var doc=dojo.doc; +var _23; +if(dojo.global.getSelection){ +var sel=dojo.global.getSelection(); +if(sel&&sel.rangeCount>0){ +_23=sel.getRangeAt(0); +} +if(_23&&_23.compareBoundaryPoints&&doc.createRange){ +try{ +_22=doc.createRange(); +_22.setStart(_21,0); +if(_23.compareBoundaryPoints(_23.START_TO_END,_22)===1){ +return true; +} +} +catch(e){ +} +} +}else{ +if(doc.selection){ +_23=doc.selection.createRange(); +try{ +_22=_21.ownerDocument.body.createControlRange(); +if(_22){ +_22.addElement(_21); +} +} +catch(e1){ +try{ +_22=_21.ownerDocument.body.createTextRange(); +_22.moveToElementText(_21); +} +catch(e2){ +} +} +if(_23&&_22){ +if(_23.compareEndPoints("EndToStart",_22)===1){ +return true; +} +} +} +} +} +return false; +}}); +} -- cgit v1.2.3