http://git-wip-us.apache.org/repos/asf/camel/blob/9f5e32db/components/camel-web/src/main/webapp/js/dojox/editor/refactor/RichText.js ---------------------------------------------------------------------- diff --git a/components/camel-web/src/main/webapp/js/dojox/editor/refactor/RichText.js b/components/camel-web/src/main/webapp/js/dojox/editor/refactor/RichText.js deleted file mode 100644 index a290f1b..0000000 --- a/components/camel-web/src/main/webapp/js/dojox/editor/refactor/RichText.js +++ /dev/null @@ -1,1370 +0,0 @@ -/* - Copyright (c) 2004-2009, 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["dojox.editor.refactor.RichText"]){ -dojo._hasResource["dojox.editor.refactor.RichText"]=true; -dojo.provide("dojox.editor.refactor.RichText"); -dojo.require("dojo.AdapterRegistry"); -dojo.require("dijit._Widget"); -dojo.require("dijit._editor.selection"); -dojo.require("dijit._editor.range"); -dojo.require("dijit._editor.html"); -dojo.require("dojo.i18n"); -dojo.requireLocalization("dijit.form","Textarea",null,"ROOT,ar,ca,cs,da,de,el,es,fi,fr,he,hu,it,ja,ko,nb,nl,pl,pt,pt-pt,ru,sk,sl,sv,th,tr,zh,zh-tw"); -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",left:"-100px",height:"3px",width:"3px"}); -dojo.body().appendChild(_1); -})(); -}else{ -try{ -dojo.doc.write("<textarea id=\""+dijit._scopeName+"._editor.RichText.savedContent\" "+"style=\"display:none;position:absolute;top:-100px;left:-100px;height:3px;width:3px;overflow:hidden;\"></textarea>"); -} -catch(e){ -} -} -} -dojox.editor.refactor.RichTextIframeMixin={_writeOpen:function(_2){ -if(dojo.isIE||dojo.isSafari||dojo.isOpera){ -if(dojo.config["useXDomain"]&&!dojo.config["dojoBlankHtmlUrl"]){ -console.warn("dojox.editor.newRT.RichText: When using cross-domain Dojo builds,"+" please save dojo/resources/blank.html to your domain and set djConfig.dojoBlankHtmlUrl"+" to the path on your domain to blank.html"); -} -var _3=dojo.config["dojoBlankHtmlUrl"]||(dojo.moduleUrl("dojo","resources/blank.html")+""); -var _4=this.editorObject=this.iframe=dojo.doc.createElement("iframe"); -_4.id=this.id+"_iframe"; -_4.src=_3; -_4.style.border="none"; -_4.style.width="100%"; -_4.frameBorder=0; -this.editingArea.appendChild(_4); -var h=null; -var _6=dojo.hitch(this,function(){ -if(h){ -dojo.disconnect(h); -h=null; -} -this.window=_4.contentWindow; -var d=this.document=this.window.document; -d.open(); -d.write(this._getIframeDocTxt(_2)); -d.close(); -if(dojo.isIE>=7){ -if(this.height){ -_4.style.height=this.height; -} -if(this.minHeight){ -_4.style.minHeight=this.minHeight; -} -}else{ -_4.style.height=this.height?this.height:this.minHeight; -} -if(dojo.isIE){ -this._localizeEditorCommands(); -} -this.onLoad(); -this.savedContent=this.getValue(true); -}); -if(dojo.isIE<7){ -var t=setInterval(function(){ -if(_4.contentWindow.isLoaded){ -clearInterval(t); -_6(); -} -},100); -}else{ -h=dojo.connect(((dojo.isIE)?_4.contentWindow:_4),"onload",_6); -} -}else{ -this._drawIframe(_2); -this.savedContent=this.getValue(true); -} -},_getIframeDocTxt:function(_9){ -var _a=dojo.getComputedStyle(this.domNode); -if(!this.height&&!dojo.isMoz){ -_9="<div>"+_9+"</div>"; -} -var _b=[_a.fontWeight,_a.fontSize,_a.fontFamily].join(" "); -var _c=_a.lineHeight; -if(_c.indexOf("px")>=0){ -_c=parseFloat(_c)/parseFloat(_a.fontSize); -}else{ -if(_c.indexOf("em")>=0){ -_c=parseFloat(_c); -}else{ -_c="1.0"; -} -} -return [this.isLeftToRight()?"<html><head>":"<html dir='rtl'><head>",(dojo.isMoz?"<title>"+this._localizedIframeTitles.iframeEditTitle+"</title>":""),"<style>","body,html {","\tbackground:transparent;","\tpadding: 0;","\tmargin: 0;","}","body{","\ttop:0px; left:0px; right:0px;",((this.height||dojo.isOpera)?"":"position: fixed;"),"\tfont:",_b,";","\tmin-height:",this.minHeight,";","\tline-height:",_c,"}","p{ margin: 1em 0 !important; }",(this.height?"":"body,html{overflow-y:hidden;/*for IE*/} body > div {overflow-x:auto;/*for FF to show vertical scrollbar*/}"),"li > ul:-moz-first-node, li > ol:-moz-first-node{ padding-top: 1.2em; } ","li{ min-height:1.2em; }","</style>",this._applyEditingAreaStyleSheets(),"</head><body>"+_9+"</body></html>"].join(""); -},_drawIframe:function(_d){ -if(!this.iframe){ -var _e=this.iframe=dojo.doc.createElement("iframe"); -_e.id=this.id+"_iframe"; -var _f=_e.style; -_f.border="none"; -_f.lineHeight="0"; -_f.verticalAlign="bottom"; -this.editorObject=this.iframe; -this._localizedIframeTitles=dojo.i18n.getLocalization("dijit.form","Textarea"); -var _10=dojo.query("label[for=\""+this.id+"\"]"); -if(_10.length){ -this._localizedIframeTitles.iframeEditTitle=_10[0].innerHTML+" "+this._localizedIframeTitles.iframeEditTitle; -} -} -this.iframe.style.width=this.inheritWidth?this._oldWidth:"100%"; -if(this.height){ -this.iframe.style.height=this.height; -}else{ -this.iframe.height=this._oldHeight; -} -var _11; -if(this.textarea){ -_11=this.srcNodeRef; -}else{ -_11=dojo.doc.createElement("div"); -_11.style.display="none"; -_11.innerHTML=_d; -this.editingArea.appendChild(_11); -} -this.editingArea.appendChild(this.iframe); -var _12=dojo.hitch(this,function(){ -if(!this.editNode){ -if(!this.document){ -try{ -if(this.iframe.contentWindow){ -this.window=this.iframe.contentWindow; -this.document=this.iframe.contentWindow.document; -}else{ -if(this.iframe.contentDocument){ -this.window=this.iframe.contentDocument.window; -this.document=this.iframe.contentDocument; -} -} -} -catch(e){ -setTimeout(_12,50); -return; -} -if(!this.document){ -setTimeout(_12,50); -return; -} -var _13=this.document; -_13.open(); -_13.write(this._getIframeDocTxt(_d)); -_13.close(); -dojo.destroy(_11); -} -if(!this.document.body){ -setTimeout(_12,50); -return; -} -this.onLoad(); -}else{ -dojo.destroy(_11); -this.editNode.innerHTML=_d; -this.onDisplayChanged(); -} -this._preDomFilterContent(this.editNode); -}); -_12(); -},onLoad:function(e){ -this.focusNode=this.editNode=(this.height||dojo.isMoz)?this.document.body:this.document.body.firstChild; -dojox.editor.refactor.RichText.prototype.onLoad.call(this,e); -},_applyEditingAreaStyleSheets:function(){ -var _15=[]; -if(this.styleSheets){ -_15=this.styleSheets.split(";"); -this.styleSheets=""; -} -_15=_15.concat(this.editingAreaStyleSheets); -this.editingAreaStyleSheets=[]; -var _16="",i=0,url; -while((url=_15[i++])){ -var _19=(new dojo._Url(dojo.global.location,url)).toString(); -this.editingAreaStyleSheets.push(_19); -_16+="<link rel=\"stylesheet\" type=\"text/css\" href=\""+_19+"\">"; -} -return _16; -},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); -if(this.document.createStyleSheet){ -this.document.createStyleSheet(url); -}else{ -var _1c=this.document.getElementsByTagName("head")[0]; -var _1d=this.document.createElement("link"); -with(_1d){ -rel="stylesheet"; -type="text/css"; -href=url; -} -_1c.appendChild(_1d); -} -},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 _20=dojo.indexOf(this.editingAreaStyleSheets,url); -if(_20==-1){ -return; -} -delete this.editingAreaStyleSheets[_20]; -dojo.withGlobal(this.window,"query",dojo,["link:[href=\""+url+"\"]"]).orphan(); -},_setDisabledAttr:function(_21){ -_21=Boolean(_21); -if(dojo.isMoz&&this.iframe){ -this.document.designMode=_21?"off":"on"; -} -dojox.editor.refactor.RichText.prototype._setDisabledAttr.call(this,_21); -},blur:function(){ -this.window.blur(); -}}; -dojo.declare("dojox.editor.refactor.RichText",dijit._Widget,{constructor:function(_22){ -this.contentPreFilters=[]; -this.contentPostFilters=[]; -this.contentDomPreFilters=[]; -this.contentDomPostFilters=[]; -this.editingAreaStyleSheets=[]; -this._keyHandlers={}; -this.contentPreFilters.push(dojo.hitch(this,"_preFixUrlAttributes")); -if(dojo.isMoz){ -this.contentPreFilters.push(this._fixContentForMoz); -this.contentPostFilters.push(this._removeMozBogus); -} -if(dojo.isSafari){ -this.contentPostFilters.push(this._removeSafariBogus); -} -this.onLoadDeferred=new dojo.Deferred(); -this.useIframe=(dojo.isFF&&(dojo.isFF<3))||_22["useIframe"]||_22["styleSheets"]; -if(this.useIframe){ -dojo.mixin(this,dojox.editor.refactor.RichTextIframeMixin); -} -this.onLoadDeferred.addCallback(this,function(_23){ -this.connect(this.editNode,"onblur","_customOnBlur"); -this.connect(this.editNode,"onfocus","_customOnFocus"); -return _23; -}); -},inheritWidth:false,focusOnLoad:false,name:"",styleSheets:"",useIframe:false,_content:"",height:"300px",minHeight:"1em",isClosed:true,isLoaded:false,_SEPARATOR:"@@**%%__RICHTEXTBOUNDRY__%%**@@",onLoadDeferred:null,isTabIndent:false,postCreate:function(){ -if("textarea"==this.domNode.tagName.toLowerCase()){ -console.warn("RichText should not be used with the TEXTAREA tag. See dojox.editor.refactor.RichText docs."); -} -dojo.publish(dijit._scopeName+"._editor.RichText::init",[this]); -this.open(); -this.setupDefaultShortcuts(); -},setupDefaultShortcuts:function(){ -var _24=dojo.hitch(this,function(cmd,arg){ -return function(){ -return !this.execCommand(cmd,arg); -}; -}); -var _27={b:_24("bold"),i:_24("italic"),u:_24("underline"),a:_24("selectall"),s:function(){ -this.save(true); -},m:function(){ -this.isTabIndent=!this.isTabIndent; -},"1":_24("formatblock","h1"),"2":_24("formatblock","h2"),"3":_24("formatblock","h3"),"4":_24("formatblock","h4"),"\\":_24("insertunorderedlist")}; -if(!dojo.isIE){ -_27.Z=_24("redo"); -} -for(var key in _27){ -this.addKeyHandler(key,true,false,_27[key]); -} -},events:["onKeyPress","onKeyDown","onKeyUp","onClick"],captureEvents:[],_editorCommandsLocalized:false,_localizeEditorCommands:function(){ -if(this._editorCommandsLocalized){ -return; -} -this._editorCommandsLocalized=true; -var _29=["div","p","pre","h1","h2","h3","h4","h5","h6","ol","ul","address"]; -var _2a="",_2b,i=0; -while((_2b=_29[i++])){ -if(_2b.charAt(1)!="l"){ -_2a+="<"+_2b+"><span>content</span></"+_2b+"><br/>"; -}else{ -_2a+="<"+_2b+"><li>content</li></"+_2b+"><br/>"; -} -} -var div=dojo.doc.createElement("div"); -dojo.style(div,{position:"absolute",left:"-2000px",top:"-2000px"}); -dojo.doc.body.appendChild(div); -div.innerHTML=_2a; -var _2e=div.firstChild; -try{ -while(_2e){ -dijit._editor.selection.selectElement(_2e.firstChild); -this.s_call("selectElement",[_2e.firstChild]); -var _2f=_2e.tagName.toLowerCase(); -this._local2NativeFormatNames[_2f]=document.queryCommandValue("formatblock"); -this._native2LocalFormatNames[this._local2NativeFormatNames[_2f]]=_2f; -_2e=_2e.nextSibling.nextSibling; -} -} -catch(e){ - -} -dojo.body().removeChild(div); -},open:function(_30){ -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)&&(_30["nodeName"])){ -this.domNode=_30; -} -var dn=this.domNode; -var _32; -if((dn["nodeName"])&&(dn.nodeName.toLowerCase()=="textarea")){ -var ta=this.textarea=dn; -this.name=ta.name; -_32=this._preFilterContent(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"); -ta.onfocus=function(e){ - -dojo.stopEvent(e); -return false; -}; -var _35=dojo.hitch(this,function(){ -with(ta.style){ -display="block"; -position="absolute"; -left=top="-1000px"; -if(dojo.isIE){ -this.__overflow=overflow; -overflow="hidden"; -} -} -}); -if(dojo.isIE){ -setTimeout(_35,10); -}else{ -_35(); -} -if(ta.form){ -dojo.connect(ta.form,"onsubmit",this,function(){ -ta.value=this.getValue(); -}); -} -}else{ -_32=this._preFilterContent(dijit._editor.getChildrenHtml(dn)); -dn.innerHTML=""; -} -if(_32==""){ -_32=" "; -} -var _36=dojo.contentBox(dn); -this._oldHeight=_36.h; -this._oldWidth=_36.w; -this.savedContent=_32; -if((dn["nodeName"])&&(dn.nodeName=="LI")){ -dn.innerHTML=" <br>"; -} -this.editingArea=dn.ownerDocument.createElement("div"); -dn.appendChild(this.editingArea); -if(this.name!=""&&(!dojo.config["useXDomain"]||dojo.config["allowXdRichTextSave"])){ -var _37=dojo.byId(dijit._scopeName+"._editor.RichText.savedContent"); -if(_37.value!=""){ -var _38=_37.value.split(this._SEPARATOR),i=0,dat; -while((dat=_38[i++])){ -var _3b=dat.split(":"); -if(_3b[0]==this.name){ -_32=_3b[1]; -_38.splice(i,1); -break; -} -} -} -this.connect(window,"onbeforeunload","_saveContent"); -} -this.isClosed=false; -this._writeOpen(_32); -if(dn.nodeName=="LI"){ -dn.lastChild.style.marginTop="-1.2em"; -} -dojo.addClass(dn,"RichTextEditable"); -return this.onLoadDeferred; -},_writeOpen:function(_3c){ -var en=this.focusNode=this.editNode=this.editingArea; -en.id=this.id; -en.className="dijitEditorArea"; -en.innerHTML=_3c; -en.contentEditable=true; -if(this.height){ -en.style.height=this.height; -} -if(this.height){ -en.style.overflowY="auto"; -} -this.window=dojo.global; -this.document=dojo.doc; -if(dojo.isIE){ -this._localizeEditorCommands(); -} -this.onLoad(); -},_local2NativeFormatNames:{},_native2LocalFormatNames:{},_localizedIframeTitles:null,disabled:true,_mozSettingProps:{"styleWithCSS":false},_setDisabledAttr:function(_3e){ -_3e=Boolean(_3e); -if(!this.editNode){ -return; -} -this.editNode.contentEditable=!_3e; -this.disabled=_3e; -if(!_3e&&this._mozSettingProps){ -var ps=this._mozSettingProps; -for(var n in ps){ -if(ps.hasOwnProperty(n)){ -try{ -this.document.execCommand(n,false,ps[n]); -} -catch(e){ -} -} -} -} -},setDisabled:function(_41){ -dojo.deprecated("dijit.Editor::setDisabled is deprecated","use dijit.Editor::attr(\"disabled\",boolean) instead",2); -this.attr("disabled",_41); -},_isResized:function(){ -return false; -},onLoad:function(e){ -this.isLoaded=true; -if(!this.window.__registeredWindow){ -this.window.__registeredWindow=true; -dijit.registerWin(this.window); -} -try{ -this.attr("disabled",true); -this.attr("disabled",false); -} -catch(e){ -var _43=dojo.connect(this,"onClick",this,function(){ -this.attr("disabled",false); -dojo.disconnect(_43); -}); -} -this._preDomFilterContent(this.editNode); -var _44=this.events.concat(this.captureEvents); -var ap=(this.iframe)?this.document:this.editNode; -dojo.forEach(_44,function(_46){ -this.connect(ap,_46.toLowerCase(),_46); -},this); -if(dojo.isIE){ -this.editNode.style.zoom=1; -} -if(this.focusOnLoad){ -setTimeout(dojo.hitch(this,"focus"),0); -} -this.onDisplayChanged(e); -if(this.onLoadDeferred){ -this.onLoadDeferred.callback(true); -} -},onKeyDown:function(e){ -if(dojo.isIE){ -if(e.keyCode===dojo.keys.BACKSPACE&&this.document.selection.type==="Control"){ -dojo.stopEvent(e); -this.execCommand("delete"); -} -} -return true; -},_lastPressStopped:false,onKeyUp:function(e){ -if(this._lastPressStopped){ -this._lastPressStopped=false; -dojo.stopEvent(e); -return false; -} -return true; -},onKeyPress:function(e){ -var c=e.keyChar.toLowerCase()||e.keyCode; -var _4b=this._keyHandlers[c]; -var _4c=arguments; -if(_4b){ -dojo.forEach(_4b,function(h){ -if((!!h.shift==!!e.shiftKey)&&(!!h.ctrl==!!e.ctrlKey)){ -if(!h.handler.apply(this,_4c)){ -dojo.stopEvent(e); -this._lastPressStopped=true; -} -} -},this); -} -if(!this._onKeyHitch){ -this._onKeyHitch=dojo.hitch(this,"onKeyPressed"); -} -setTimeout(this._onKeyHitch,1); -return true; -},addKeyHandler:function(key,_4f,_50,_51){ -if(!dojo.isArray(this._keyHandlers[key])){ -this._keyHandlers[key]=[]; -} -this._keyHandlers[key].push({shift:_50||false,ctrl:_4f||false,handler:_51}); -},onKeyPressed:function(){ -this.onDisplayChanged(); -},onClick:function(e){ -this.onDisplayChanged(e); -},_onMouseDown:function(e){ -if(!this._focused&&!this.disabled){ -this.focus(); -} -},_savedSelection:null,_saveSelection:function(){ -var r=dijit.range.getSelection(this.window).getRangeAt(0); -var _55=this._getRangeNodes(r); -this._savedSelection={range:((dojo.isIE)?r.duplicate():r.cloneRange()),nodes:_55,bookmark:this._getBookmark(_55)}; - -},_onBlur:function(e){ -},_customOnBlur:function(e){ -this._saveSelection(); -var _c=this.getValue(true); -if(_c!=this.savedContent){ -this.onChange(_c); -this.savedContent=_c; -} -if(dojo.isMoz&&this.iframe){ -this.iframe.contentDocument.title=this._localizedIframeTitles.iframeEditTitle; -} -e.stopPropagation(); -},_initialFocus:true,_customOnFocus:function(e){ -setTimeout(dojo.hitch(this,"_doOnFocus"),10); -},_doOnFocus:function(){ -if(this._initialFocus){ -this._initialFocus=false; -if(dojo.isMoz){ -if(this.editNode.innerHTML.replace(/^\s+|\s+$/g,"")==" "){ -this.placeCursorAtStart(); -} -} -} -if(dojo.isSafari){ -this.placeCursorAtStart(); -} - -if(this._savedSelection){ -this._moveToBookmark(this._savedSelection.bookmark); -} -this._savedSelection=null; -},blur:function(){ -this.editNode.blur(); -},focus:function(){ - -if(!this.iframe&&dojo.isSafari){ -return; -} -if(this.iframe&&!dojo.isIE){ -dijit.focus(this.iframe); -}else{ -if(this.editNode&&this.editNode.focus){ -this.editNode.focus(); -} -} -},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(_5b){ -},_normalizeCommand:function(cmd){ -var _5d=cmd.toLowerCase(); -if(_5d=="formatblock"){ -if(dojo.isSafari){ -_5d="heading"; -} -}else{ -if(_5d=="hilitecolor"&&!dojo.isMoz){ -_5d="backcolor"; -} -} -return _5d; -},_qcaCache:{},queryCommandAvailable:function(_5e){ -var ca=this._qcaCache[_5e]; -if(ca!=undefined){ -return ca; -} -return this._qcaCache[_5e]=this._queryCommandAvailable(_5e); -},_queryCommandAvailable:function(_60){ -var ie=1; -var _62=1<<1; -var _63=1<<2; -var _64=1<<3; -var _65=1<<4; -var _66=dojo.isSafari; -function _67(_68){ -return {ie:Boolean(_68&ie),mozilla:Boolean(_68&_62),safari:Boolean(_68&_63),safari420:Boolean(_68&_65),opera:Boolean(_68&_64)}; -}; -var _69=null; -switch(_60.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": -_69=_67(_62|ie|_63|_64); -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": -_69=_67(_62|ie|_64|_65); -break; -case "blockdirltr": -case "blockdirrtl": -case "dirltr": -case "dirrtl": -case "inlinedirltr": -case "inlinedirrtl": -_69=_67(ie); -break; -case "cut": -case "copy": -case "paste": -_69=_67(ie|_62|_65); -break; -case "inserttable": -_69=_67(_62|ie); -break; -case "insertcell": -case "insertcol": -case "insertrow": -case "deletecells": -case "deletecols": -case "deleterows": -case "mergecells": -case "splitcell": -_69=_67(ie|_62); -break; -default: -return false; -} -return (dojo.isIE&&_69.ie)||(dojo.isMoz&&_69.mozilla)||(dojo.isSafari&&_69.safari)||(_66&&_69.safari420)||(dojo.isOpera&&_69.opera); -},execCommand:function(_6a,_6b){ -var _6c; -this.focus(); -var c=dojox.editor.refactor.RichText._commands; -var _6e; -if(_6e=c.match(_6a.toLowerCase())){ -return _6e.applyCommand(this,_6b); -} -_6a=this._normalizeCommand(_6a); -if(_6b!=undefined){ -if(_6a=="heading"){ -throw new Error("unimplemented"); -}else{ -if((_6a=="formatblock")&&dojo.isIE){ -_6b="<"+_6b+">"; -} -} -} -if(_6a=="inserthtml"){ -_6b=this._preFilterContent(_6b); -_6c=true; -if(dojo.isIE){ -var _6f=this.document.selection.createRange(); -_6f.pasteHTML(_6b); -_6f.select(); -}else{ -if(dojo.isMoz&&!_6b.length){ -this._sCall("remove"); -_6c=true; -}else{ -_6c=this.document.execCommand(_6a,false,_6b); -} -} -}else{ -if((_6a=="unlink")&&(this.queryCommandEnabled("unlink"))&&(dojo.isMoz||dojo.isSafari)){ -var a=this._sCall("getAncestorElement",["a"]); -this._sCall("selectElement",[a]); -_6c=this.document.execCommand("unlink",false,null); -}else{ -if((_6a=="hilitecolor")&&(dojo.isMoz)){ -this.document.execCommand("styleWithCSS",false,true); -_6c=this.document.execCommand(_6a,false,_6b); -this.document.execCommand("styleWithCSS",false,false); -}else{ -if((dojo.isIE)&&((_6a=="backcolor")||(_6a=="forecolor"))){ -_6b=arguments.length>1?_6b:null; -_6c=this.document.execCommand(_6a,false,_6b); -}else{ -_6b=arguments.length>1?_6b:null; -if(_6b||_6a!="createlink"){ -_6c=this.document.execCommand(_6a,false,_6b); -} -} -} -} -} -this.onDisplayChanged(); -return _6c; -},queryCommandEnabled:function(_71){ -if(this.disabled){ -return false; -} -_71=this._normalizeCommand(_71); -if(dojo.isMoz||dojo.isSafari){ -if(_71=="unlink"){ -this._sCall("hasAncestorElement",["a"]); -}else{ -if(_71=="inserttable"){ -return true; -} -} -} -if(dojo.isSafari){ -if(_71=="copy"){ -_71="cut"; -}else{ -if(_71=="paste"){ -return true; -} -} -} -if(_71=="indent"){ -var li=this._sCall("getAncestorElement",["li"]); -var n=li&&li.previousSibling; -while(n){ -if(n.nodeType==1){ -return true; -} -n=n.previousSibling; -} -return false; -}else{ -if(_71=="outdent"){ -return this._sCall("hasAncestorElement",["li"]); -} -} -var _74=dojo.isIE?this.document.selection.createRange():this.document; -return _74.queryCommandEnabled(_71); -},queryCommandState:function(_75){ -if(this.disabled){ -return false; -} -var c=dojox.editor.refactor.RichText._commands; -var _77; -if(_77=c.match(_75)){ -return _77.queryState(this); -} -_75=this._normalizeCommand(_75); -this.editNode.contentEditable=true; -return this.document.queryCommandState(_75); -},queryCommandValue:function(_78){ -if(this.disabled){ -return false; -} -var r; -_78=this._normalizeCommand(_78); -if(dojo.isIE&&_78=="formatblock"){ -r=this._native2LocalFormatNames[this.document.queryCommandValue(_78)]; -}else{ -r=this.document.queryCommandValue(_78); -} -return r; -},_sCall:function(_7a,_7b){ -dojo.withGlobal(this.window,_7a,dijit._editor.selection,_7b); -},placeCursorAtStart:function(){ -this.focus(); -var _7c=false; -if(dojo.isMoz){ -var _7d=this.editNode.firstChild; -while(_7d){ -if(_7d.nodeType==3){ -if(_7d.nodeValue.replace(/^\s+|\s+$/g,"").length>0){ -_7c=true; -this._sCall("selectElement",[_7d]); -break; -} -}else{ -if(_7d.nodeType==1){ -_7c=true; -this._sCall("selectElementChildren",[_7d]); -break; -} -} -_7d=_7d.nextSibling; -} -}else{ -_7c=true; -this._sCall("selectElementChildren",[this.editNode]); -} -if(_7c){ -this._sCall("collapse",[true]); -} -},placeCursorAtEnd:function(){ -this.focus(); -var _7e=false; -if(dojo.isMoz){ -var _7f=this.editNode.lastChild; -while(_7f){ -if(_7f.nodeType==3){ -if(_7f.nodeValue.replace(/^\s+|\s+$/g,"").length>0){ -_7e=true; -this._sCall("selectElement",[_7f]); -break; -} -}else{ -if(_7f.nodeType==1){ -_7e=true; -if(_7f.lastChild){ -this._sCall("selectElement",[_7f.lastChild]); -}else{ -this._sCall("selectElement",[_7f]); -} -break; -} -} -_7f=_7f.previousSibling; -} -}else{ -_7e=true; -this._sCall("selectElementChildren",[this.editNode]); -} -if(_7e){ -this._sCall("collapse",[false]); -} -},getValue:function(_80){ -if(this.textarea){ -if(this.isClosed||!this.isLoaded){ -return this.textarea.value; -} -} -return this._postFilterContent(null,_80); -},setValue:function(_81){ -if(this.textarea&&(this.isClosed||!this.isLoaded)){ -this.textarea.value=_81; -}else{ -_81=this._preFilterContent(_81); -var _82=this.isClosed?this.domNode:this.editNode; -_82.innerHTML=_81; -this._preDomFilterContent(_82); -} -this.onDisplayChanged(); -},replaceValue:function(_83){ -if(this.isClosed){ -this.setValue(_83); -}else{ -if(this.window&&this.window.getSelection&&!dojo.isMoz){ -this.setValue(_83); -}else{ -if(this.window&&this.window.getSelection){ -_83=this._preFilterContent(_83); -this.execCommand("selectall"); -if(dojo.isMoz&&!_83){ -_83=" "; -} -this.execCommand("inserthtml",_83); -this._preDomFilterContent(this.editNode); -}else{ -if(this.document&&this.document.selection){ -this.setValue(_83); -} -} -} -} -},_preFilterContent:function(_84){ -var ec=_84; -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,_8a){ -var ec; -if(!dojo.isString(dom)){ -dom=dom||this.editNode; -if(this.contentDomPostFilters.length){ -if(_8a){ -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 _8f=dojo.byId(dijit._scopeName+"._editor.RichText.savedContent"); -_8f.value+=this._SEPARATOR+this.name+":"+this.getValue(); -},escapeXml:function(str,_91){ -str=str.replace(/&/gm,"&").replace(/</gm,"<").replace(/>/gm,">").replace(/"/gm,"""); -if(!_91){ -str=str.replace(/'/gm,"'"); -} -return str; -},getNodeHtml:function(_92){ -dojo.deprecated("dijit.Editor::getNodeHtml is deprecated","use dijit._editor.getNodeHtml instead",2); -return dijit._editor.getNodeHtml(_92); -},getNodeChildrenHtml:function(dom){ -dojo.deprecated("dijit.Editor::getNodeChildrenHtml is deprecated","use dijit._editor.getChildrenHtml instead",2); -return dijit._editor.getChildrenHtml(dom); -},close:function(_94,_95){ -if(this.isClosed){ -return false; -} -if(!arguments.length){ -_94=true; -} -this._content=this.getValue(); -var _96=(this.savedContent!=this._content); -if(this.interval){ -clearInterval(this.interval); -} -if(this.textarea){ -with(this.textarea.style){ -position=""; -left=top=""; -if(dojo.isIE){ -overflow=this.__overflow; -this.__overflow=null; -} -} -this.textarea.value=_94?this._content:this.savedContent; -dojo.destroy(this.domNode); -this.domNode=this.textarea; -}else{ -this.domNode.innerHTML=_94?this._content:this.savedContent; -} -dojo.removeClass(this.domNode,"RichTextEditable"); -this.isClosed=true; -this.isLoaded=false; -delete this.editNode; -if(this.window&&this.window._frameElement){ -this.window._frameElement=null; -} -this.window=null; -this.document=null; -this.editingArea=null; -this.editorObject=null; -return _96; -},destroyRendering:function(){ -},destroy:function(){ -this.destroyRendering(); -if(!this.isClosed){ -this.close(false); -} -this.inherited("destroy",arguments); -},_removeMozBogus:function(_97){ -return _97.replace(/\stype="_moz"/gi,"").replace(/\s_moz_dirty=""/gi,""); -},_removeSafariBogus:function(_98){ -return _98.replace(/\sclass="webkit-block-placeholder"/gi,""); -},_fixContentForMoz:function(_99){ -return _99.replace(/<(\/)?strong([ \>])/gi,"<$1b$2").replace(/<(\/)?em([ \>])/gi,"<$1i$2"); -},_preFixUrlAttributes:function(_9a){ -return _9a.replace(/(?:(<a(?=\s).*?\shref=)("|')(.*?)\2)|(?:(<a\s.*?href=)([^"'][^ >]+))/gi,"$1$4$2$3$5$2 _djrealurl=$2$3$5$2").replace(/(?:(<img(?=\s).*?\ssrc=)("|')(.*?)\2)|(?:(<img\s.*?src=)([^"'][^ >]+))/gi,"$1$4$2$3$5$2 _djrealurl=$2$3$5$2"); -},_bookmarkId:0,_getBookmark:function(_9b){ -var _9c,_9d; -var id=this._bookmarkId++; -if(_9b.length){ -_9c=this.document.createElement("span"); -dojo.attr(_9c,{isBookmark:"true",bookmarkId:id,style:{width:"1px",height:"1px",overflow:"hidden",border:"3px solid blue"}}); -_9d=_9c.cloneNode(false); -var sid="_richText_startMarker_"+this.id+"_"+id; -var eid="_richText_endMarker_"+this.id+"_"+id; -_9c.id=sid; -_9d.id=eid; -if(dojo.isIE){ -_9c.innerHTML=sid; -_9d.innerHTML=eid; -} -dojo.place(_9c,_9b[0],"before"); -dojo.place(_9d,_9b.last(),"after"); -} -return [_9c,_9d]; -},_getRangeNodes:function(s){ -if(!s){ -s=dijit.range.getSelection(this.window); -} -if(!s.startContainer&&s.focusNode){ -s=s.getRangeAt(0); -} -var r=[]; -r.last=function(){ -return this[this.length-1]; -}; -var _a3=s.commonAncestorContainer; -var sc=s.startContainer; -var so=s.startOffset; -var ec=s.endContainer; -var eo=s.endOffset; -var od=sc.ownerDocument; -var tmp=od.createTextNode(""); -if(sc===ec){ -var _aa=(dojo.isIE)?!s.text.length:s.collapsed; -if(_aa){ -var _ab=tmp.cloneNode(true); -if(sc.nodeType==1){ -dojo.place(_ab,this.domNode,"first"); -}else{ -var _ac=sc.splitText(so); -sc.parentNode.insertBefore(_ab,_ac); -} -r.push(_ab); -}else{ -if(1==sc.nodeType){ -var tmp=so; -do{ -r.push(sc.childNodes.item(tmp)); -tmp++; -}while(tmp<eo); -}else{ -if(3==sc.nodeType){ -sc.splitText(eo); -r.push(sc.splitText(so)); -} -} -} -return r; -} -if(3==sc.nodeType){ -var l=String(sc.value).length; -if(0==so){ -if((sc.parentNode!=_a3)&&!sc.previousSibling){ -r.push(sc.parentNode); -}else{ -r.push(sc); -} -}else{ -if(l==so){ -var ns=sc.nextSibling; -if(ns){ -if(!dojo.isDescendant(ec,ns)){ -r.push(ns); -}else{ -var _ab=tmp.cloneNode(); -dojo.place(_ab,sc,"after"); -r.push(_ab); -} -} -}else{ -r.push(sc.splitText(so)); -ec.splitText(eo); -} -} -}else{ -if(1==sc.nodeType){ -var cn=dojo._toArray(sc.childNodes); -if(sc===_a3){ -var end=false; -dojo.forEach(cn,function(_b1,idx,arr){ -if(end){ -return; -} -if((_b1===ec)||dojo.isDescendant(ec,_b1)){ -end=true; -return; -} -if(idx>=so){ -r.push(_b1); -} -}); -}else{ -if(sc.parentNode===_a3){ -dojo.forEach(cn,function(_b4,idx,arr){ -if(idx>=so){ -r.push(_b4); -} -}); -var _ac=sc.nextSibling; -while(_ac&&((_ac!==ec)&&!dojo.isDescendant(ec,_ac))){ -r.push(_ac); -_ac=_ac.nextSibling; -} -}else{ -if(so){ -r.push.apply(r,cn.slice(so)); -}else{ -r.push(sc); -} -} -} -} -} -this._collectNodes(r,_a3,ec,eo); -return r; -},_collectNodes:function(arr,_b8,end,_ba){ -var _bb=arr.last(); -if(!_bb||(_bb===_b8)){ -return; -} -do{ -var n=_bb.nextSibling; -while(n){ -if(dojo.isDescendant(end,n)){ -break; -} -arr.push(n); -n=n.nextSibling; -} -_bb=_bb.parentNode; -}while(_bb&&_bb!=_b8); -_bb=arr.last(); -if(1==end.nodeType){ -end=end.childNodes[_ba-1]; -} -arr.push(end); -var al=arr.length-1; -var _be=end; -do{ -var n=_be.previousSibling; -while(n){ -if(n==_bb){ -return; -} -arr.splice(al,0,n); -n=n.previousSibling; -} -_be=_be.parentNode; -}while(_be&&_be!=_b8); -},_moveToBookmark:function(_bf){ -var _c0=_bf[0]; -var end=_bf[1]; -if(!_c0||!end){ -console.error("_moveToBookmark must be passed start/end caps to be removed!"); -return; -} -if(dojo.isIE){ -var r=this.document.createTextRange(); -var r2=r.duplicate(); -var _c4=r.findText(_c0.innerHTML,100000000); -var _c5=r2.findText(end.innerHTML,100000000); -var r3=r.duplicate(); -r3.move("character",_c0.innerHTML.length); -r3.setEndPoint("EndToStart",r2); -r3.select(); -} -var _c7=_c0.nextSibling; -var _c8=end.previousSibling; -var _c9=end.nextSibling; -if(dojo.isIE){ -end.innerHTML=_c0.innerHTML=""; -} -_c0.parentNode.removeChild(_c0); -end.parentNode.removeChild(end); -if(!dojo.isIE){ -var s=this.window.getSelection(); -if(s.rangeCount>0){ -s.removeAllRanges(); -} -var r=this.document.createRange(); -r.setStartBefore(_c7); -var ep=_c8||_c9.previousSibling||_c9.parentNode.previousSibling||_c9; -r.setEndAfter(ep); -s.addRange(r); -} -}}); -dojo.declare("dojox.editor.refactor.Command",null,{name:"",constructor:function(_cc){ -dojo.mixin(this,_cc); -this.register(); -this.init(); -},register:function(_cd){ -var r=this.registry=_cd||this.registry; -if(r&&this.name.length){ -r.register(this.name,dojo.hitch(this,"registryCheck"),this); -} -},init:function(){ -},registryCheck:function(_cf,_d0){ -return (_cf==this.name); -},queryEnabled:function(rt){ -return false; -},queryValue:function(rt){ -return null; -},queryState:function(rt){ -return false; -},applyCommand:function(rt,_d5){ -return true; -}}); -dojo.declare("dojox.editor.refactor.TagWrapCommand",dojox.editor.refactor.Command,{init:function(){ -if(this.tag){ -this._upperTag=this._upperTag||this.tag.toUpperCase(); -} -if(this.name){ -this._nameAttr=this.name+"_command"; -} -},tag:"",attrs:{},applicationHelper:function(arg,_d7){ -},removalHelper:function(arg,_d9){ -},isntAppliedHelper:function(_da){ -return false; -},reParentOnRemoval:false,applyCommand:function(rt,arg){ -var _dd=rt._getRangeNodes(); -var _de=rt._getBookmark(_dd); -var _df=dojo.filter(_dd,this._isntAppliedToNode,this); -if(!_df.length){ - -dojo.forEach(_dd,this._removeFromNode,this); -dojo.forEach(_dd,dojo.hitch(this,"removalHelper",arg)); -}else{ - -dojo.forEach(_df,this._applyToNode,this); -dojo.forEach(_df,dojo.hitch(this,"applicationHelper",arg)); -} -rt._moveToBookmark(_de); -return true; -},queryState:function(rt){ -return this._isApplied(rt._getRangeNodes()); -},_isApplied:function(rn){ -var r=(0==dojo.filter(rn,this._isntAppliedToNode,this)); -return r; -},_isntAppliedToNode:function(_e3){ -var ta=this.attrs; -var nt=_e3.nodeType; -if(1==nt){ -if(this.tag.length){ -if(!this._isTagMatch(_e3)){ -return true; -} -} -for(var x in ta){ -if(x=="style"){ -continue; -} -if(dojo.attr(_e3,x)!=ta[x]){ -return true; -} -} -if(ta.style){ -for(var x in ta.style){ -if(dojo.style(_e3,x)!=ta.style[x]){ -return true; -} -} -} -return this.isntAppliedHelper(_e3); -}else{ -if(3==nt){ -if(!_e3.nodeValue.length){ -return false; -} -return this._isntAppliedToNode(_e3.parentNode); -} -} -},_isTagMatch:function(_e7){ -return (_e7.tagName==this._upperTag); -},_applyToNode:function(_e8){ -var nt=_e8.nodeType; -var el=_e8; -if((3==nt)||!this._isTagMatch(_e8)){ -el=_e8.ownerDocument.createElement(this.tag||"span"); -_e8.parentNode.replaceChild(el,_e8); -el.appendChild(_e8); -} -dojo.attr(el,this.attrs); -dojo.attr(el,this._nameAttr,"applied"); -return el; -},_removeFromSingleNode:function(_eb){ -try{ -dojo.removeAttr(_eb,this._nameAttr); -} -catch(e){ -} -for(var x in this.attrs){ -if(x!="style"){ -dojo.attr(_eb,x,""); -} -} -for(var x in this.attrs.style){ -dojo.style(_eb,x,""); -} -if(this.reParentOnRemoval){ -while(_eb.firstChild){ -_eb.parentNode.insertBefore(_eb.firstChild,_eb); -} -_eb.parentNode.removeChild(_eb); -} -},_removeFromNode:function(_ed,idx,arr){ -if(3==_ed.nodeType){ -var pn=_ed.parentNode; -if(pn.lastChild==_ed){ -dojo.place(_ed,pn,"after"); -}else{ -if(pn.firstChild==_ed){ -dojo.place(_ed,pn,"before"); -}else{ -return this._removeFromNode(pn,idx,arr); -} -} -return; -} -if(dojo.attr(_ed,this._nameAttr)){ -this._removeFromSingleNode(_ed); -} -dojo.query("["+this._nameAttr+"]",_ed).forEach(this._removeFromSingleNode,this); -}}); -(function(){ -var de=dojox.editor.refactor; -var c=de.RichText._commands=new dojo.AdapterRegistry(true); -var TRC=de.TagWrapCommand; -new TRC({name:"bold",tag:"span",attrs:{style:{fontWeight:"bold"}},registry:c}); -new TRC({name:"italic",tag:"span",attrs:{style:{fontStyle:"italic"}},registry:c}); -new TRC({name:"strikethrough",tag:"span",attrs:{style:{textDecoration:"line-through"}},registry:c}); -new TRC({name:"underline",tag:"span",attrs:{style:{textDecoration:"underline"}},registry:c}); -new TRC({name:"subscript",tag:"span",attrs:{style:{verticalAlign:"sub"}},registry:c}); -new TRC({name:"superscript",tag:"span",attrs:{style:{verticalAlign:"super"}},registry:c}); -new TRC({name:"fontname",tag:"span",applicationHelper:function(arg,_f5){ -dojo.style(_f5,"fontFamily",arg); -},removalHelper:function(arg,_f7){ -dojo.style(_f7,"fontFamily",""); -},isntAppliedHelper:function(_f8){ - -return !dojo.style(_f8,"fontFamily"); -},registry:c}); -})(); -}
http://git-wip-us.apache.org/repos/asf/camel/blob/9f5e32db/components/camel-web/src/main/webapp/js/dojox/embed/Flash.js ---------------------------------------------------------------------- diff --git a/components/camel-web/src/main/webapp/js/dojox/embed/Flash.js b/components/camel-web/src/main/webapp/js/dojox/embed/Flash.js deleted file mode 100644 index 43e74dc..0000000 --- a/components/camel-web/src/main/webapp/js/dojox/embed/Flash.js +++ /dev/null @@ -1,263 +0,0 @@ -/* - Copyright (c) 2004-2009, 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["dojox.embed.Flash"]){ -dojo._hasResource["dojox.embed.Flash"]=true; -dojo.provide("dojox.embed.Flash"); -(function(){ -var _1,_2; -var _3=9; -var _4="dojox-embed-flash-",_5=0; -var _6={expressInstall:false,width:320,height:240,swLiveConnect:"true",allowScriptAccess:"sameDomain",allowNetworking:"all",style:null,redirect:null}; -function _7(_8){ -_8=dojo.delegate(_6,_8); -if(!("path" in _8)){ -console.error("dojox.embed.Flash(ctor):: no path reference to a Flash movie was provided."); -return null; -} -if(!("id" in _8)){ -_8.id=(_4+_5++); -} -return _8; -}; -if(dojo.isIE){ -_1=function(_9){ -_9=_7(_9); -if(!_9){ -return null; -} -var p; -var _b=_9.path; -if(_9.vars){ -var a=[]; -for(p in _9.vars){ -a.push(p+"="+_9.vars[p]); -} -_b+=((_b.indexOf("?")==-1)?"?":"&")+a.join("&"); -} -var s="<object id=\""+_9.id+"\" "+"classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" "+"width=\""+_9.width+"\" "+"height=\""+_9.height+"\""+((_9.style)?" style=\""+_9.style+"\"":"")+">"+"<param name=\"movie\" value=\""+_b+"\" />"; -if(_9.params){ -for(p in _9.params){ -s+="<param name=\""+p+"\" value=\""+_9.params[p]+"\" />"; -} -} -s+="</object>"; -return {id:_9.id,markup:s}; -}; -_2=(function(){ -var _e=10,_f=null; -while(!_f&&_e>7){ -try{ -_f=new ActiveXObject("ShockwaveFlash.ShockwaveFlash."+_e--); -} -catch(e){ -} -} -if(_f){ -var v=_f.GetVariable("$version").split(" ")[1].split(","); -return {major:(v[0]!=null)?parseInt(v[0]):0,minor:(v[1]!=null)?parseInt(v[1]):0,rev:(v[2]!=null)?parseInt(v[2]):0}; -} -return {major:0,minor:0,rev:0}; -})(); -dojo.addOnUnload(function(){ -var _12=function(){ -}; -var _13=dojo.query("object").reverse().style("display","none").forEach(function(i){ -for(var p in i){ -if((p!="FlashVars")&&dojo.isFunction(i[p])){ -try{ -i[p]=_12; -} -catch(e){ -} -} -} -}); -}); -}else{ -_1=function(_16){ -_16=_7(_16); -if(!_16){ -return null; -} -var p; -var _18=_16.path; -if(_16.vars){ -var a=[]; -for(p in _16.vars){ -a.push(p+"="+_16.vars[p]); -} -_18+=((_18.indexOf("?")==-1)?"?":"&")+a.join("&"); -} -var s="<embed type=\"application/x-shockwave-flash\" "+"src=\""+_18+"\" "+"id=\""+_16.id+"\" "+"width=\""+_16.width+"\" "+"height=\""+_16.height+"\""+((_16.style)?" style=\""+_16.style+"\" ":"")+"swLiveConnect=\""+_16.swLiveConnect+"\" "+"allowScriptAccess=\""+_16.allowScriptAccess+"\" "+"allowNetworking=\""+_16.allowNetworking+"\" "+"pluginspage=\""+window.location.protocol+"//www.adobe.com/go/getflashplayer\" "; -if(_16.params){ -for(p in _16.params){ -s+=" "+p+"=\""+_16.params[p]+"\""; -} -} -s+=" />"; -return {id:_16.id,markup:s}; -}; -_2=(function(){ -var _1b=navigator.plugins["Shockwave Flash"]; -if(_1b&&_1b.description){ -var v=_1b.description.replace(/([a-zA-Z]|\s)+/,"").replace(/(\s+r|\s+b[0-9]+)/,".").split("."); -return {major:(v[0]!=null)?parseInt(v[0]):0,minor:(v[1]!=null)?parseInt(v[1]):0,rev:(v[2]!=null)?parseInt(v[2]):0}; -} -return {major:0,minor:0,rev:0}; -})(); -} -dojox.embed.Flash=function(_1d,_1e){ -if(location.href.toLowerCase().indexOf("file://")>-1){ -throw new Error("dojox.embed.Flash can't be run directly from a file. To instatiate the required SWF correctly it must be run from a server, like localHost."); -} -this.available=dojox.embed.Flash.available; -this.minimumVersion=_1d.minimumVersion||_3; -this.id=null; -this.movie=null; -this.domNode=null; -if(_1e){ -_1e=dojo.byId(_1e); -} -setTimeout(dojo.hitch(this,function(){ -if(this.available&&this.available>=this.minimumVersion){ -if(_1d&&_1e){ -this.init(_1d,_1e); -} -}else{ -if(!this.available){ -this.onError("Flash is not installed."); -}else{ -this.onError("Flash version detected: "+this.available+" is out of date. Minimum required: "+this.minimumVersion); -} -} -}),100); -}; -dojo.extend(dojox.embed.Flash,{onReady:function(_1f){ -},onLoad:function(_20){ -},onError:function(msg){ -},_onload:function(){ -clearInterval(this._poller); -delete this._poller; -delete this._pollCount; -delete this._pollMax; -this.onLoad(this.movie); -},init:function(_22,_23){ -this.destroy(); -_23=dojo.byId(_23||this.domNode); -if(!_23){ -throw new Error("dojox.embed.Flash: no domNode reference has been passed."); -} -var p=0,_25=false; -this._poller=null; -this._pollCount=0; -this._pollMax=5; -this.pollTime=100; -if(dojox.embed.Flash.initialized){ -this.id=dojox.embed.Flash.place(_22,_23); -this.domNode=_23; -setTimeout(dojo.hitch(this,function(){ -this.movie=dojox.embed.Flash.byId(this.id); -this.onReady(this.movie); -this._poller=setInterval(dojo.hitch(this,function(){ -try{ -p=this.movie.PercentLoaded(); -} -catch(e){ -console.warn("this.movie.PercentLoaded() failed"); -} -if(p==100){ -this._onload(); -}else{ -if(p==0&&this._pollCount++>this._pollMax){ -throw new Error("Building SWF failed."); -} -} -}),this.pollTime); -}),1); -} -},_destroy:function(){ -try{ -this.domNode.removeChild(this.movie); -} -catch(e){ -} -this.id=this.movie=this.domNode=null; -},destroy:function(){ -if(!this.movie){ -return; -} -var _26=dojo.delegate({id:true,movie:true,domNode:true,onReady:true,onLoad:true}); -for(var p in this){ -if(!_26[p]){ -delete this[p]; -} -} -if(this._poller){ -dojo.connect(this,"onLoad",this,"_destroy"); -}else{ -this._destroy(); -} -}}); -dojo.mixin(dojox.embed.Flash,{byId:function(_28){ -if(document.embeds[_28]){ -return document.embeds[_28]; -} -if(window.document[_28]){ -return window.document[_28]; -} -if(window[_28]){ -return window[_28]; -} -if(document[_28]){ -return document[_28]; -} -return null; -}}); -dojo.mixin(dojox.embed.Flash,{minSupported:8,available:_2.major,supported:(_2.major>=_2.required),minimumRequired:_2.required,version:_2,initialized:false,onInitialize:function(){ -dojox.embed.Flash.initialized=true; -},__ie_markup__:function(_29){ -return _1(_29); -},proxy:function(obj,_2b){ -dojo.forEach((dojo.isArray(_2b)?_2b:[_2b]),function(_2c){ -this[_2c]=dojo.hitch(this,function(){ -return (function(){ -return eval(this.movie.CallFunction("<invoke name=\""+_2c+"\" returntype=\"javascript\">"+"<arguments>"+dojo.map(arguments,function(_2d){ -return __flash__toXML(_2d); -}).join("")+"</arguments>"+"</invoke>")); -}).apply(this,arguments||[]); -}); -},obj); -}}); -if(dojo.isIE){ -if(dojo._initFired){ -var e=document.createElement("script"); -e.type="text/javascript"; -e.src=dojo.moduleUrl("dojox","embed/IE/flash.js"); -document.getElementsByTagName("head")[0].appendChild(e); -}else{ -document.write("<scr"+"ipt type=\"text/javascript\" src=\""+dojo.moduleUrl("dojox","embed/IE/flash.js")+"\">"+"</scr"+"ipt>"); -} -}else{ -dojox.embed.Flash.place=function(_2e,_2f){ -var o=_1(_2e); -_2f=dojo.byId(_2f); -if(!_2f){ -_2f=dojo.doc.createElement("div"); -_2f.id=o.id+"-container"; -dojo.body().appendChild(_2f); -} -if(o){ -_2f.innerHTML=o.markup; -return o.id; -} -return null; -}; -dojox.embed.Flash.onInitialize(); -} -})(); -} http://git-wip-us.apache.org/repos/asf/camel/blob/9f5e32db/components/camel-web/src/main/webapp/js/dojox/embed/IE/flash.js ---------------------------------------------------------------------- diff --git a/components/camel-web/src/main/webapp/js/dojox/embed/IE/flash.js b/components/camel-web/src/main/webapp/js/dojox/embed/IE/flash.js deleted file mode 100644 index fc8b0de..0000000 --- a/components/camel-web/src/main/webapp/js/dojox/embed/IE/flash.js +++ /dev/null @@ -1,22 +0,0 @@ -/* - Copyright (c) 2004-2009, 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 -*/ - - -dojox.embed.Flash.place=function(_1,_2){ -var o=dojox.embed.Flash.__ie_markup__(_1); -_2=dojo.byId(_2); -if(!_2){ -_2=dojo.doc.createElement("div"); -_2.id=o.id+"-container"; -dojo.body().appendChild(_2); -} -if(o){ -_2.innerHTML=o.markup; -return o.id; -} -return null; -}; -dojox.embed.Flash.onInitialize(); http://git-wip-us.apache.org/repos/asf/camel/blob/9f5e32db/components/camel-web/src/main/webapp/js/dojox/embed/Object.js ---------------------------------------------------------------------- diff --git a/components/camel-web/src/main/webapp/js/dojox/embed/Object.js b/components/camel-web/src/main/webapp/js/dojox/embed/Object.js deleted file mode 100644 index 48b0df0..0000000 --- a/components/camel-web/src/main/webapp/js/dojox/embed/Object.js +++ /dev/null @@ -1,39 +0,0 @@ -/* - Copyright (c) 2004-2009, 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["dojox.embed.Object"]){ -dojo._hasResource["dojox.embed.Object"]=true; -dojo.provide("dojox.embed.Object"); -dojo.experimental("dojox.embed.Object"); -dojo.require("dijit._Widget"); -dojo.require("dojox.embed.Flash"); -dojo.require("dojox.embed.Quicktime"); -dojo.declare("dojox.embed.Object",dijit._Widget,{width:0,height:0,src:"",movie:null,params:null,reFlash:/\.swf|\.flv/gi,reQtMovie:/\.3gp|\.avi|\.m4v|\.mov|\.mp4|\.mpg|\.mpeg|\.qt/gi,reQtAudio:/\.aiff|\.aif|\.m4a|\.m4b|\.m4p|\.midi|\.mid|\.mp3|\.mpa|\.wav/gi,postCreate:function(){ -if(!this.width||!this.height){ -var _1=dojo.marginBox(this.domNode); -this.width=_1.w,this.height=_1.h; -} -var em=dojox.embed.Flash; -if(this.src.match(this.reQtMovie)||this.src.match(this.reQtAudio)){ -em=dojox.embed.Quicktime; -} -if(!this.params){ -this.params={}; -if(this.domNode.hasAttributes()){ -var _3={dojoType:"",width:"",height:"","class":"",style:"",id:"",src:""}; -var _4=this.domNode.attributes; -for(var i=0,l=_4.length;i<l;i++){ -if(!_3[_4[i].name]){ -this.params[_4[i].name]=_4[i].value; -} -} -} -} -var _7={path:this.src,width:this.width,height:this.height,params:this.params}; -this.movie=new (em)(_7,this.domNode); -}}); -} http://git-wip-us.apache.org/repos/asf/camel/blob/9f5e32db/components/camel-web/src/main/webapp/js/dojox/embed/Quicktime.js ---------------------------------------------------------------------- diff --git a/components/camel-web/src/main/webapp/js/dojox/embed/Quicktime.js b/components/camel-web/src/main/webapp/js/dojox/embed/Quicktime.js deleted file mode 100644 index 5387bd8..0000000 --- a/components/camel-web/src/main/webapp/js/dojox/embed/Quicktime.js +++ /dev/null @@ -1,179 +0,0 @@ -/* - Copyright (c) 2004-2009, 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["dojox.embed.Quicktime"]){ -dojo._hasResource["dojox.embed.Quicktime"]=true; -dojo.provide("dojox.embed.Quicktime"); -(function(){ -var _1,_2,_3,_4={width:320,height:240,redirect:null}; -var _5="dojox-embed-quicktime-",_6=0; -var _7=dojo.moduleUrl("dojox","embed/resources/version.mov"); -function _8(_9){ -_9=dojo.mixin(dojo.clone(_4),_9||{}); -if(!("path" in _9)){ -console.error("dojox.embed.Quicktime(ctor):: no path reference to a QuickTime movie was provided."); -return null; -} -if(!("id" in _9)){ -_9.id=(_5+_6++); -} -return _9; -}; -var _a="This content requires the <a href=\"http://www.apple.com/quicktime/download/\" title=\"Download and install QuickTime.\">QuickTime plugin</a>."; -if(dojo.isIE){ -_2=0; -_3=(function(){ -try{ -var o=new ActiveXObject("QuickTimeCheckObject.QuickTimeCheck.1"); -if(o!==undefined){ -var v=o.QuickTimeVersion.toString(16); -_2={major:parseInt(v.substring(0,1),10)||0,minor:parseInt(v.substring(1,2),10)||0,rev:parseInt(v.substring(2,3),10)||0}; -return o.IsQuickTimeAvailable(0); -} -} -catch(e){ -} -return false; -})(); -_1=function(_d){ -if(!_3){ -return {id:null,markup:_a}; -} -_d=_8(_d); -if(!_d){ -return null; -} -var s="<object classid=\"clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B\" "+"codebase=\"http://www.apple.com/qtactivex/qtplugin.cab#version=6,0,2,0\" "+"id=\""+_d.id+"\" "+"width=\""+_d.width+"\" "+"height=\""+_d.height+"\">"+"<param name=\"src\" value=\""+_d.path+"\" />"; -if(_d.params){ -for(var p in _d.params){ -s+="<param name=\""+p+"\" value=\""+_d.params[p]+"\" />"; -} -} -s+="</object>"; -return {id:_d.id,markup:s}; -}; -}else{ -_3=(function(){ -for(var i=0,l=navigator.plugins.length;i<l;i++){ -if(navigator.plugins[i].name.indexOf("QuickTime")>-1){ -return true; -} -} -return false; -})(); -_1=function(_12){ -if(!_3){ -return {id:null,markup:_a}; -} -_12=_8(_12); -if(!_12){ -return null; -} -var s="<embed type=\"video/quicktime\" src=\""+_12.path+"\" "+"id=\""+_12.id+"\" "+"name=\""+_12.id+"\" "+"pluginspage=\"www.apple.com/quicktime/download\" "+"enablejavascript=\"true\" "+"width=\""+_12.width+"\" "+"height=\""+_12.height+"\""; -if(_12.params){ -for(var p in _12.params){ -s+=" "+p+"=\""+_12.params[p]+"\""; -} -} -s+="></embed>"; -return {id:_12.id,markup:s}; -}; -} -dojox.embed.Quicktime=function(_15,_16){ -return dojox.embed.Quicktime.place(_15,_16); -}; -dojo.mixin(dojox.embed.Quicktime,{minSupported:6,available:_3,supported:_3,version:_2,initialized:false,onInitialize:function(){ -dojox.embed.Quicktime.initialized=true; -},place:function(_17,_18){ -var o=_1(_17); -_18=dojo.byId(_18); -if(!_18){ -_18=dojo.doc.createElement("div"); -_18.id=o.id+"-container"; -dojo.body().appendChild(_18); -} -if(o){ -_18.innerHTML=o.markup; -if(o.id){ -return (dojo.isIE)?dojo.byId(o.id):document[o.id]; -} -} -return null; -}}); -if(!dojo.isIE){ -_2=dojox.embed.Quicktime.version={major:0,minor:0,rev:0}; -var o=_1({path:_7,width:4,height:4}); -function _1b(){ -if(!dojo._initFired){ -var s="<div style=\"top:0;left:0;width:1px;height:1px;;overflow:hidden;position:absolute;\" id=\"-qt-version-test\">"+o.markup+"</div>"; -document.write(s); -}else{ -var n=document.createElement("div"); -n.id="-qt-version-test"; -n.style.cssText="top:0;left:0;width:1px;height:1px;overflow:hidden;position:absolute;"; -dojo.body().appendChild(n); -n.innerHTML=o.markup; -} -}; -function _1e(mv){ -var qt,n,v=[0,0,0]; -if(mv){ -qt=mv,n=qt.parentNode; -}else{ -if(o.id){ -_1b(); -if(!dojo.isOpera){ -setTimeout(function(){ -_1e(document[o.id]); -},50); -}else{ -var fn=function(){ -setTimeout(function(){ -_1e(document[o.id]); -},50); -}; -if(!dojo._initFired){ -dojo.addOnLoad(fn); -}else{ -dojo.connect(document[o.id],"onload",fn); -} -} -} -return; -} -if(qt){ -try{ -v=qt.GetQuickTimeVersion().split("."); -_2={major:parseInt(v[0]||0),minor:parseInt(v[1]||0),rev:parseInt(v[2]||0)}; -} -catch(e){ -_2={major:0,minor:0,rev:0}; -} -} -dojox.embed.Quicktime.supported=v[0]; -dojox.embed.Quicktime.version=_2; -if(dojox.embed.Quicktime.supported){ -dojox.embed.Quicktime.onInitialize(); -}else{ - -} -try{ -if(!mv){ -dojo.body().removeChild(n); -} -} -catch(e){ -} -}; -_1e(); -}else{ -if(dojo.isIE&&_3){ -dojox.embed.Quicktime.onInitialize(); -} -} -})(); -} http://git-wip-us.apache.org/repos/asf/camel/blob/9f5e32db/components/camel-web/src/main/webapp/js/dojox/embed/README ---------------------------------------------------------------------- diff --git a/components/camel-web/src/main/webapp/js/dojox/embed/README b/components/camel-web/src/main/webapp/js/dojox/embed/README deleted file mode 100644 index 1f5cb00..0000000 --- a/components/camel-web/src/main/webapp/js/dojox/embed/README +++ /dev/null @@ -1,44 +0,0 @@ -------------------------------------------------------------------------------- -dojox.embed -------------------------------------------------------------------------------- -Version 0.1 -Release date: 4/7/2008 -------------------------------------------------------------------------------- -Project state: -beta -------------------------------------------------------------------------------- -Credits - Tom Trenka (ttrenka AT gmail.com) -------------------------------------------------------------------------------- -Project description - -A move/port of what was in dojox.av._base; the nominal purpose is to provide -easy ways of including external objects that would normally require the use -of either an OBJECT or an EMBED tag. - -The following constructors are considered beta (working tests and docs) as of -2008-06-04: - -dojox.embed.Flash -dojox.embed.FlashProxy -dojox.embed.Quicktime -dojox.embed.Object (a Dijit that can load anything there is an embed for here) -------------------------------------------------------------------------------- -Dependencies: - -dojox.embed has no dependencies, other than the Dojo base. -------------------------------------------------------------------------------- -Documentation - -TBD -------------------------------------------------------------------------------- -Installation instructions - -Grab the following from the Dojo SVN Repository: -http://svn.dojotoolkit.org/dojox/trunk/embed/* - -Install into the following directory structure: -/dojox/embed/ - -...which should be at the same level as your Dojo checkout. -------------------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/camel/blob/9f5e32db/components/camel-web/src/main/webapp/js/dojox/embed/resources/version.mov ---------------------------------------------------------------------- diff --git a/components/camel-web/src/main/webapp/js/dojox/embed/resources/version.mov b/components/camel-web/src/main/webapp/js/dojox/embed/resources/version.mov deleted file mode 100644 index 4f2cb73..0000000 Binary files a/components/camel-web/src/main/webapp/js/dojox/embed/resources/version.mov and /dev/null differ http://git-wip-us.apache.org/repos/asf/camel/blob/9f5e32db/components/camel-web/src/main/webapp/js/dojox/encoding/LICENSE ---------------------------------------------------------------------- diff --git a/components/camel-web/src/main/webapp/js/dojox/encoding/LICENSE b/components/camel-web/src/main/webapp/js/dojox/encoding/LICENSE deleted file mode 100644 index ffe5b0f..0000000 --- a/components/camel-web/src/main/webapp/js/dojox/encoding/LICENSE +++ /dev/null @@ -1,9 +0,0 @@ -License Disclaimer: - -All contents of this directory are Copyright (c) the Dojo Foundation, with the -following exceptions: -------------------------------------------------------------------------------- - -MD5.js, SHA1.js: - * Copyright 1998-2005, Paul Johnstone - Distributed under the terms of the BSD License http://git-wip-us.apache.org/repos/asf/camel/blob/9f5e32db/components/camel-web/src/main/webapp/js/dojox/encoding/README ---------------------------------------------------------------------- diff --git a/components/camel-web/src/main/webapp/js/dojox/encoding/README b/components/camel-web/src/main/webapp/js/dojox/encoding/README deleted file mode 100644 index 8826008..0000000 --- a/components/camel-web/src/main/webapp/js/dojox/encoding/README +++ /dev/null @@ -1,35 +0,0 @@ -------------------------------------------------------------------------------- -DojoX Encoding -------------------------------------------------------------------------------- -Version 0.1.0 -Release date: 7/30/2007 -------------------------------------------------------------------------------- -Project state: -experimental -------------------------------------------------------------------------------- -Credits - Eugene Lazutkin - Tom Trenka -------------------------------------------------------------------------------- -Project description - -DojoX Encoding provides a set of routines for common encoding algorithms. -------------------------------------------------------------------------------- -Dependencies: - -Encoding only depends on the Dojo Core. -------------------------------------------------------------------------------- -Documentation - -See the API documentation for details. -------------------------------------------------------------------------------- -Installation instructions - -Grab the following from the Dojo SVN Repository: -http://svn.dojotoolkit.org/var/src/dojo/dojox/trunk/encoding/* - -Install into the following directory structure: -/dojox/encoding/ - -...which should be at the same level as your Dojo checkout. -------------------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/camel/blob/9f5e32db/components/camel-web/src/main/webapp/js/dojox/encoding/_base.js ---------------------------------------------------------------------- diff --git a/components/camel-web/src/main/webapp/js/dojox/encoding/_base.js b/components/camel-web/src/main/webapp/js/dojox/encoding/_base.js deleted file mode 100644 index 8c60ddc..0000000 --- a/components/camel-web/src/main/webapp/js/dojox/encoding/_base.js +++ /dev/null @@ -1,11 +0,0 @@ -/* - Copyright (c) 2004-2009, 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["dojox.encoding._base"]){ -dojo._hasResource["dojox.encoding._base"]=true; -dojo.provide("dojox.encoding._base"); -} http://git-wip-us.apache.org/repos/asf/camel/blob/9f5e32db/components/camel-web/src/main/webapp/js/dojox/encoding/ascii85.js ---------------------------------------------------------------------- diff --git a/components/camel-web/src/main/webapp/js/dojox/encoding/ascii85.js b/components/camel-web/src/main/webapp/js/dojox/encoding/ascii85.js deleted file mode 100644 index 3e9acb0..0000000 --- a/components/camel-web/src/main/webapp/js/dojox/encoding/ascii85.js +++ /dev/null @@ -1,71 +0,0 @@ -/* - Copyright (c) 2004-2009, 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["dojox.encoding.ascii85"]){ -dojo._hasResource["dojox.encoding.ascii85"]=true; -dojo.provide("dojox.encoding.ascii85"); -(function(){ -var c=function(_2,_3,_4){ -var i,j,n,b=[0,0,0,0,0]; -for(i=0;i<_3;i+=4){ -n=((_2[i]*256+_2[i+1])*256+_2[i+2])*256+_2[i+3]; -if(!n){ -_4.push("z"); -}else{ -for(j=0;j<5;b[j++]=n%85+33,n=Math.floor(n/85)){ -} -} -_4.push(String.fromCharCode(b[4],b[3],b[2],b[1],b[0])); -} -}; -dojox.encoding.ascii85.encode=function(_9){ -var _a=[],_b=_9.length%4,_c=_9.length-_b; -c(_9,_c,_a); -if(_b){ -var t=_9.slice(_c); -while(t.length<4){ -t.push(0); -} -c(t,4,_a); -var x=_a.pop(); -if(x=="z"){ -x="!!!!!"; -} -_a.push(x.substr(0,_b+1)); -} -return _a.join(""); -}; -dojox.encoding.ascii85.decode=function(_f){ -var n=_f.length,r=[],b=[0,0,0,0,0],i,j,t,x,y,d; -for(i=0;i<n;++i){ -if(_f.charAt(i)=="z"){ -r.push(0,0,0,0); -continue; -} -for(j=0;j<5;++j){ -b[j]=_f.charCodeAt(i+j)-33; -} -d=n-i; -if(d<5){ -for(j=d;j<4;b[++j]=0){ -} -b[d]=85; -} -t=(((b[0]*85+b[1])*85+b[2])*85+b[3])*85+b[4]; -x=t&255; -t>>>=8; -y=t&255; -t>>>=8; -r.push(t>>>8,t&255,y,x); -for(j=d;j<5;++j,r.pop()){ -} -i+=4; -} -return r; -}; -})(); -} http://git-wip-us.apache.org/repos/asf/camel/blob/9f5e32db/components/camel-web/src/main/webapp/js/dojox/encoding/base64.js ---------------------------------------------------------------------- diff --git a/components/camel-web/src/main/webapp/js/dojox/encoding/base64.js b/components/camel-web/src/main/webapp/js/dojox/encoding/base64.js deleted file mode 100644 index 3edb863..0000000 --- a/components/camel-web/src/main/webapp/js/dojox/encoding/base64.js +++ /dev/null @@ -1,70 +0,0 @@ -/* - Copyright (c) 2004-2009, 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["dojox.encoding.base64"]){ -dojo._hasResource["dojox.encoding.base64"]=true; -dojo.provide("dojox.encoding.base64"); -(function(){ -var p="="; -var _2="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; -var _3=dojox.encoding; -_3.base64.encode=function(ba){ -var s=[],l=ba.length; -var rm=l%3; -var x=l-rm; -for(var i=0;i<x;){ -var t=ba[i++]<<16|ba[i++]<<8|ba[i++]; -s.push(_2.charAt((t>>>18)&63)); -s.push(_2.charAt((t>>>12)&63)); -s.push(_2.charAt((t>>>6)&63)); -s.push(_2.charAt(t&63)); -} -switch(rm){ -case 2: -var t=ba[i++]<<16|ba[i++]<<8; -s.push(_2.charAt((t>>>18)&63)); -s.push(_2.charAt((t>>>12)&63)); -s.push(_2.charAt((t>>>6)&63)); -s.push(p); -break; -case 1: -var t=ba[i++]<<16; -s.push(_2.charAt((t>>>18)&63)); -s.push(_2.charAt((t>>>12)&63)); -s.push(p); -s.push(p); -break; -} -return s.join(""); -}; -_3.base64.decode=function(_b){ -var s=_b.split(""),_d=[]; -var l=s.length; -while(s[--l]==p){ -} -for(var i=0;i<l;){ -var t=_2.indexOf(s[i++])<<18; -if(i<=l){ -t|=_2.indexOf(s[i++])<<12; -} -if(i<=l){ -t|=_2.indexOf(s[i++])<<6; -} -if(i<=l){ -t|=_2.indexOf(s[i++]); -} -_d.push((t>>>16)&255); -_d.push((t>>>8)&255); -_d.push(t&255); -} -while(_d[_d.length-1]==0){ -_d.pop(); -} -return _d; -}; -})(); -} http://git-wip-us.apache.org/repos/asf/camel/blob/9f5e32db/components/camel-web/src/main/webapp/js/dojox/encoding/bits.js ---------------------------------------------------------------------- diff --git a/components/camel-web/src/main/webapp/js/dojox/encoding/bits.js b/components/camel-web/src/main/webapp/js/dojox/encoding/bits.js deleted file mode 100644 index d385a16..0000000 --- a/components/camel-web/src/main/webapp/js/dojox/encoding/bits.js +++ /dev/null @@ -1,64 +0,0 @@ -/* - Copyright (c) 2004-2009, 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["dojox.encoding.bits"]){ -dojo._hasResource["dojox.encoding.bits"]=true; -dojo.provide("dojox.encoding.bits"); -dojox.encoding.bits.OutputStream=function(){ -this.reset(); -}; -dojo.extend(dojox.encoding.bits.OutputStream,{reset:function(){ -this.buffer=[]; -this.accumulator=0; -this.available=8; -},putBits:function(_1,_2){ -while(_2){ -var w=Math.min(_2,this.available); -var v=(w<=_2?_1>>>(_2-w):_1)<<(this.available-w); -this.accumulator|=v&(255>>>(8-this.available)); -this.available-=w; -if(!this.available){ -this.buffer.push(this.accumulator); -this.accumulator=0; -this.available=8; -} -_2-=w; -} -},getWidth:function(){ -return this.buffer.length*8+(8-this.available); -},getBuffer:function(){ -var b=this.buffer; -if(this.available<8){ -b.push(this.accumulator&(255<<this.available)); -} -this.reset(); -return b; -}}); -dojox.encoding.bits.InputStream=function(_6,_7){ -this.buffer=_6; -this.width=_7; -this.bbyte=this.bit=0; -}; -dojo.extend(dojox.encoding.bits.InputStream,{getBits:function(_8){ -var r=0; -while(_8){ -var w=Math.min(_8,8-this.bit); -var v=this.buffer[this.bbyte]>>>(8-this.bit-w); -r<<=w; -r|=v&~(~0<<w); -this.bit+=w; -if(this.bit==8){ -++this.bbyte; -this.bit=0; -} -_8-=w; -} -return r; -},getWidth:function(){ -return this.width-this.bbyte*8-this.bit; -}}); -} http://git-wip-us.apache.org/repos/asf/camel/blob/9f5e32db/components/camel-web/src/main/webapp/js/dojox/encoding/compression/lzw.js ---------------------------------------------------------------------- diff --git a/components/camel-web/src/main/webapp/js/dojox/encoding/compression/lzw.js b/components/camel-web/src/main/webapp/js/dojox/encoding/compression/lzw.js deleted file mode 100644 index 8a5f9ce..0000000 --- a/components/camel-web/src/main/webapp/js/dojox/encoding/compression/lzw.js +++ /dev/null @@ -1,83 +0,0 @@ -/* - Copyright (c) 2004-2009, 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["dojox.encoding.compression.lzw"]){ -dojo._hasResource["dojox.encoding.compression.lzw"]=true; -dojo.provide("dojox.encoding.compression.lzw"); -dojo.require("dojox.encoding.bits"); -(function(){ -var _1=function(x){ -var w=1; -for(var v=2;x>=v;v<<=1,++w){ -} -return w; -}; -dojox.encoding.compression.lzw.Encoder=function(n){ -this.size=n; -this.init(); -}; -dojo.extend(dojox.encoding.compression.lzw.Encoder,{init:function(){ -this.dict={}; -for(var i=0;i<this.size;++i){ -this.dict[String.fromCharCode(i)]=i; -} -this.width=_1(this.code=this.size); -this.p=""; -},encode:function(_7,_8){ -var c=String.fromCharCode(_7),p=this.p+c,r=0; -if(p in this.dict){ -this.p=p; -return r; -} -_8.putBits(this.dict[this.p],this.width); -if((this.code&(this.code+1))==0){ -_8.putBits(this.code++,r=this.width++); -} -this.dict[p]=this.code++; -this.p=c; -return r+this.width; -},flush:function(_c){ -if(this.p.length==0){ -return 0; -} -_c.putBits(this.dict[this.p],this.width); -this.p=""; -return this.width; -}}); -dojox.encoding.compression.lzw.Decoder=function(n){ -this.size=n; -this.init(); -}; -dojo.extend(dojox.encoding.compression.lzw.Decoder,{init:function(){ -this.codes=new Array(this.size); -for(var i=0;i<this.size;++i){ -this.codes[i]=String.fromCharCode(i); -} -this.width=_1(this.size); -this.p=-1; -},decode:function(_f){ -var c=_f.getBits(this.width),v; -if(c<this.codes.length){ -v=this.codes[c]; -if(this.p>=0){ -this.codes.push(this.codes[this.p]+v.substr(0,1)); -} -}else{ -if((c&(c+1))==0){ -this.codes.push(""); -++this.width; -return ""; -} -var x=this.codes[this.p]; -v=x+x.substr(0,1); -this.codes.push(v); -} -this.p=c; -return v; -}}); -})(); -} http://git-wip-us.apache.org/repos/asf/camel/blob/9f5e32db/components/camel-web/src/main/webapp/js/dojox/encoding/compression/splay.js ---------------------------------------------------------------------- diff --git a/components/camel-web/src/main/webapp/js/dojox/encoding/compression/splay.js b/components/camel-web/src/main/webapp/js/dojox/encoding/compression/splay.js deleted file mode 100644 index 2c00ff6..0000000 --- a/components/camel-web/src/main/webapp/js/dojox/encoding/compression/splay.js +++ /dev/null @@ -1,65 +0,0 @@ -/* - Copyright (c) 2004-2009, 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["dojox.encoding.compression.splay"]){ -dojo._hasResource["dojox.encoding.compression.splay"]=true; -dojo.provide("dojox.encoding.compression.splay"); -dojo.require("dojox.encoding.bits"); -dojox.encoding.compression.Splay=function(n){ -this.up=new Array(2*n+1); -this.left=new Array(n); -this.right=new Array(n); -this.reset(); -}; -dojo.extend(dojox.encoding.compression.Splay,{reset:function(){ -for(var i=1;i<this.up.length;this.up[i]=Math.floor((i-1)/2),++i){ -} -for(var i=0;i<this.left.length;this.left[i]=2*i+1,this.right[i]=2*i+2,++i){ -} -},splay:function(i){ -var a=i+this.left.length; -do{ -var c=this.up[a]; -if(c){ -var d=this.up[c]; -var b=this.left[d]; -if(c==b){ -b=this.right[d]; -this.right[d]=a; -}else{ -this.left[d]=a; -} -this[a==this.left[c]?"left":"right"][c]=b; -this.up[a]=d; -this.up[b]=c; -a=d; -}else{ -a=c; -} -}while(a); -},encode:function(_8,_9){ -var s=[],a=_8+this.left.length; -do{ -s.push(this.right[this.up[a]]==a); -a=this.up[a]; -}while(a); -this.splay(_8); -var l=s.length; -while(s.length){ -_9.putBits(s.pop()?1:0,1); -} -return l; -},decode:function(_d){ -var a=0; -do{ -a=this[_d.getBits(1)?"right":"left"][a]; -}while(a<this.left.length); -a-=this.left.length; -this.splay(a); -return a; -}}); -} http://git-wip-us.apache.org/repos/asf/camel/blob/9f5e32db/components/camel-web/src/main/webapp/js/dojox/encoding/crypto/Blowfish.js ---------------------------------------------------------------------- diff --git a/components/camel-web/src/main/webapp/js/dojox/encoding/crypto/Blowfish.js b/components/camel-web/src/main/webapp/js/dojox/encoding/crypto/Blowfish.js deleted file mode 100644 index bdb55a1..0000000 --- a/components/camel-web/src/main/webapp/js/dojox/encoding/crypto/Blowfish.js +++ /dev/null @@ -1,275 +0,0 @@ -/* - Copyright (c) 2004-2009, 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["dojox.encoding.crypto.Blowfish"]){ -dojo._hasResource["dojox.encoding.crypto.Blowfish"]=true; -dojo.provide("dojox.encoding.crypto.Blowfish"); -dojo.require("dojox.encoding.base64"); -dojo.require("dojox.encoding.crypto._base"); -dojox.encoding.crypto.Blowfish=new function(){ -var _1=Math.pow(2,2); -var _2=Math.pow(2,3); -var _3=Math.pow(2,4); -var _4=Math.pow(2,8); -var _5=Math.pow(2,16); -var _6=Math.pow(2,24); -var iv=null; -var _8={p:[608135816,2242054355,320440878,57701188,2752067618,698298832,137296536,3964562569,1160258022,953160567,3193202383,887688300,3232508343,3380367581,1065670069,3041331479,2450970073,2306472731],s0:[3509652390,2564797868,805139163,3491422135,3101798381,1780907670,3128725573,4046225305,614570311,3012652279,134345442,2240740374,1667834072,1901547113,2757295779,4103290238,227898511,1921955416,1904987480,2182433518,2069144605,3260701109,2620446009,720527379,3318853667,677414384,3393288472,3101374703,2390351024,1614419982,1822297739,2954791486,3608508353,3174124327,2024746970,1432378464,3864339955,2857741204,1464375394,1676153920,1439316330,715854006,3033291828,289532110,2706671279,2087905683,3018724369,1668267050,732546397,1947742710,3462151702,2609353502,2950085171,1814351708,2050118529,680887927,999245976,1800124847,3300911131,1713906067,1641548236,4213287313,1216130144,1575780402,4018429277,3917837745,3693486850,3949271944,596196993,3549867205,258830323,2213823033,772490370,27 60122372,1774776394,2652871518,566650946,4142492826,1728879713,2882767088,1783734482,3629395816,2517608232,2874225571,1861159788,326777828,3124490320,2130389656,2716951837,967770486,1724537150,2185432712,2364442137,1164943284,2105845187,998989502,3765401048,2244026483,1075463327,1455516326,1322494562,910128902,469688178,1117454909,936433444,3490320968,3675253459,1240580251,122909385,2157517691,634681816,4142456567,3825094682,3061402683,2540495037,79693498,3249098678,1084186820,1583128258,426386531,1761308591,1047286709,322548459,995290223,1845252383,2603652396,3431023940,2942221577,3202600964,3727903485,1712269319,422464435,3234572375,1170764815,3523960633,3117677531,1434042557,442511882,3600875718,1076654713,1738483198,4213154764,2393238008,3677496056,1014306527,4251020053,793779912,2902807211,842905082,4246964064,1395751752,1040244610,2656851899,3396308128,445077038,3742853595,3577915638,679411651,2892444358,2354009459,1767581616,3150600392,3791627101,3102740896,284835224,42468320 56,1258075500,768725851,2589189241,3069724005,3532540348,1274779536,3789419226,2764799539,1660621633,3471099624,4011903706,913787905,3497959166,737222580,2514213453,2928710040,3937242737,1804850592,3499020752,2949064160,2386320175,2390070455,2415321851,4061277028,2290661394,2416832540,1336762016,1754252060,3520065937,3014181293,791618072,3188594551,3933548030,2332172193,3852520463,3043980520,413987798,3465142937,3030929376,4245938359,2093235073,3534596313,375366246,2157278981,2479649556,555357303,3870105701,2008414854,3344188149,4221384143,3956125452,2067696032,3594591187,2921233993,2428461,544322398,577241275,1471733935,610547355,4027169054,1432588573,1507829418,2025931657,3646575487,545086370,48609733,2200306550,1653985193,298326376,1316178497,3007786442,2064951626,458293330,2589141269,3591329599,3164325604,727753846,2179363840,146436021,1461446943,4069977195,705550613,3059967265,3887724982,4281599278,3313849956,1404054877,2845806497,146425753,1854211946],s1:[1266315497,3048417604 ,3681880366,3289982499,2909710000,1235738493,2632868024,2414719590,3970600049,1771706367,1449415276,3266420449,422970021,1963543593,2690192192,3826793022,1062508698,1531092325,1804592342,2583117782,2714934279,4024971509,1294809318,4028980673,1289560198,2221992742,1669523910,35572830,157838143,1052438473,1016535060,1802137761,1753167236,1386275462,3080475397,2857371447,1040679964,2145300060,2390574316,1461121720,2956646967,4031777805,4028374788,33600511,2920084762,1018524850,629373528,3691585981,3515945977,2091462646,2486323059,586499841,988145025,935516892,3367335476,2599673255,2839830854,265290510,3972581182,2759138881,3795373465,1005194799,847297441,406762289,1314163512,1332590856,1866599683,4127851711,750260880,613907577,1450815602,3165620655,3734664991,3650291728,3012275730,3704569646,1427272223,778793252,1343938022,2676280711,2052605720,1946737175,3164576444,3914038668,3967478842,3682934266,1661551462,3294938066,4011595847,840292616,3712170807,616741398,312560963,711312465,1351 876610,322626781,1910503582,271666773,2175563734,1594956187,70604529,3617834859,1007753275,1495573769,4069517037,2549218298,2663038764,504708206,2263041392,3941167025,2249088522,1514023603,1998579484,1312622330,694541497,2582060303,2151582166,1382467621,776784248,2618340202,3323268794,2497899128,2784771155,503983604,4076293799,907881277,423175695,432175456,1378068232,4145222326,3954048622,3938656102,3820766613,2793130115,2977904593,26017576,3274890735,3194772133,1700274565,1756076034,4006520079,3677328699,720338349,1533947780,354530856,688349552,3973924725,1637815568,332179504,3949051286,53804574,2852348879,3044236432,1282449977,3583942155,3416972820,4006381244,1617046695,2628476075,3002303598,1686838959,431878346,2686675385,1700445008,1080580658,1009431731,832498133,3223435511,2605976345,2271191193,2516031870,1648197032,4164389018,2548247927,300782431,375919233,238389289,3353747414,2531188641,2019080857,1475708069,455242339,2609103871,448939670,3451063019,1395535956,2413381860,1841 049896,1491858159,885456874,4264095073,4001119347,1565136089,3898914787,1108368660,540939232,1173283510,2745871338,3681308437,4207628240,3343053890,4016749493,1699691293,1103962373,3625875870,2256883143,3830138730,1031889488,3479347698,1535977030,4236805024,3251091107,2132092099,1774941330,1199868427,1452454533,157007616,2904115357,342012276,595725824,1480756522,206960106,497939518,591360097,863170706,2375253569,3596610801,1814182875,2094937945,3421402208,1082520231,3463918190,2785509508,435703966,3908032597,1641649973,2842273706,3305899714,1510255612,2148256476,2655287854,3276092548,4258621189,236887753,3681803219,274041037,1734335097,3815195456,3317970021,1899903192,1026095262,4050517792,356393447,2410691914,3873677099,3682840055],s2:[3913112168,2491498743,4132185628,2489919796,1091903735,1979897079,3170134830,3567386728,3557303409,857797738,1136121015,1342202287,507115054,2535736646,337727348,3213592640,1301675037,2528481711,1895095763,1721773893,3216771564,62756741,2142006736,83 5421444,2531993523,1442658625,3659876326,2882144922,676362277,1392781812,170690266,3921047035,1759253602,3611846912,1745797284,664899054,1329594018,3901205900,3045908486,2062866102,2865634940,3543621612,3464012697,1080764994,553557557,3656615353,3996768171,991055499,499776247,1265440854,648242737,3940784050,980351604,3713745714,1749149687,3396870395,4211799374,3640570775,1161844396,3125318951,1431517754,545492359,4268468663,3499529547,1437099964,2702547544,3433638243,2581715763,2787789398,1060185593,1593081372,2418618748,4260947970,69676912,2159744348,86519011,2512459080,3838209314,1220612927,3339683548,133810670,1090789135,1078426020,1569222167,845107691,3583754449,4072456591,1091646820,628848692,1613405280,3757631651,526609435,236106946,48312990,2942717905,3402727701,1797494240,859738849,992217954,4005476642,2243076622,3870952857,3732016268,765654824,3490871365,2511836413,1685915746,3888969200,1414112111,2273134842,3281911079,4080962846,172450625,2569994100,980381355,4109958455,28 19808352,2716589560,2568741196,3681446669,3329971472,1835478071,660984891,3704678404,4045999559,3422617507,3040415634,1762651403,1719377915,3470491036,2693910283,3642056355,3138596744,1364962596,2073328063,1983633131,926494387,3423689081,2150032023,4096667949,1749200295,3328846651,309677260,2016342300,1779581495,3079819751,111262694,1274766160,443224088,298511866,1025883608,3806446537,1145181785,168956806,3641502830,3584813610,1689216846,3666258015,3200248200,1692713982,2646376535,4042768518,1618508792,1610833997,3523052358,4130873264,2001055236,3610705100,2202168115,4028541809,2961195399,1006657119,2006996926,3186142756,1430667929,3210227297,1314452623,4074634658,4101304120,2273951170,1399257539,3367210612,3027628629,1190975929,2062231137,2333990788,2221543033,2438960610,1181637006,548689776,2362791313,3372408396,3104550113,3145860560,296247880,1970579870,3078560182,3769228297,1714227617,3291629107,3898220290,166772364,1251581989,493813264,448347421,195405023,2709975567,677966185,3 703036547,1463355134,2715995803,1338867538,1343315457,2802222074,2684532164,233230375,2599980071,2000651841,3277868038,1638401717,4028070440,3237316320,6314154,819756386,300326615,590932579,1405279636,3267499572,3150704214,2428286686,3959192993,3461946742,1862657033,1266418056,963775037,2089974820,2263052895,1917689273,448879540,3550394620,3981727096,150775221,3627908307,1303187396,508620638,2975983352,2726630617,1817252668,1876281319,1457606340,908771278,3720792119,3617206836,2455994898,1729034894,1080033504],s3:[976866871,3556439503,2881648439,1522871579,1555064734,1336096578,3548522304,2579274686,3574697629,3205460757,3593280638,3338716283,3079412587,564236357,2993598910,1781952180,1464380207,3163844217,3332601554,1699332808,1393555694,1183702653,3581086237,1288719814,691649499,2847557200,2895455976,3193889540,2717570544,1781354906,1676643554,2592534050,3230253752,1126444790,2770207658,2633158820,2210423226,2615765581,2414155088,3127139286,673620729,2805611233,1269405062,40153505 05,3341807571,4149409754,1057255273,2012875353,2162469141,2276492801,2601117357,993977747,3918593370,2654263191,753973209,36408145,2530585658,25011837,3520020182,2088578344,530523599,2918365339,1524020338,1518925132,3760827505,3759777254,1202760957,3985898139,3906192525,674977740,4174734889,2031300136,2019492241,3983892565,4153806404,3822280332,352677332,2297720250,60907813,90501309,3286998549,1016092578,2535922412,2839152426,457141659,509813237,4120667899,652014361,1966332200,2975202805,55981186,2327461051,676427537,3255491064,2882294119,3433927263,1307055953,942726286,933058658,2468411793,3933900994,4215176142,1361170020,2001714738,2830558078,3274259782,1222529897,1679025792,2729314320,3714953764,1770335741,151462246,3013232138,1682292957,1483529935,471910574,1539241949,458788160,3436315007,1807016891,3718408830,978976581,1043663428,3165965781,1927990952,4200891579,2372276910,3208408903,3533431907,1412390302,2931980059,4132332400,1947078029,3881505623,4168226417,2941484381,1077988 104,1320477388,886195818,18198404,3786409000,2509781533,112762804,3463356488,1866414978,891333506,18488651,661792760,1628790961,3885187036,3141171499,876946877,2693282273,1372485963,791857591,2686433993,3759982718,3167212022,3472953795,2716379847,445679433,3561995674,3504004811,3574258232,54117162,3331405415,2381918588,3769707343,4154350007,1140177722,4074052095,668550556,3214352940,367459370,261225585,2610173221,4209349473,3468074219,3265815641,314222801,3066103646,3808782860,282218597,3406013506,3773591054,379116347,1285071038,846784868,2669647154,3771962079,3550491691,2305946142,453669953,1268987020,3317592352,3279303384,3744833421,2610507566,3859509063,266596637,3847019092,517658769,3462560207,3443424879,370717030,4247526661,2224018117,4143653529,4112773975,2788324899,2477274417,1456262402,2901442914,1517677493,1846949527,2295493580,3734397586,2176403920,1280348187,1908823572,3871786941,846861322,1172426758,3287448474,3383383037,1655181056,3139813346,901632758,1897031941,2986607 138,3066810236,3447102507,1393639104,373351379,950779232,625454576,3124240540,4148612726,2007998917,544563296,2244738638,2330496472,2058025392,1291430526,424198748,50039436,29584100,3605783033,2429876329,2791104160,1057563949,3255363231,3075367218,3463963227,1469046755,985887462]}; -function _9(x,y){ -return (((x>>16)+(y>>16)+(((x&65535)+(y&65535))>>16))<<16)|(((x&65535)+(y&65535))&65535); -}; -function _c(x,y){ -return (((x>>16)^(y>>16))<<16)|(((x&65535)^(y&65535))&65535); -}; -function $(v,box){ -var d=box.s3[v&255]; -v>>=8; -var c=box.s2[v&255]; -v>>=8; -var b=box.s1[v&255]; -v>>=8; -var a=box.s0[v&255]; -var r=(((a>>16)+(b>>16)+(((a&65535)+(b&65535))>>16))<<16)|(((a&65535)+(b&65535))&65535); -r=(((r>>16)^(c>>16))<<16)|(((r&65535)^(c&65535))&65535); -return (((r>>16)+(d>>16)+(((r&65535)+(d&65535))>>16))<<16)|(((r&65535)+(d&65535))&65535); -}; -function eb(o,box){ -var l=o.left; -var r=o.right; -l=_c(l,box.p[0]); -r=_c(r,_c($(l,box),box.p[1])); -l=_c(l,_c($(r,box),box.p[2])); -r=_c(r,_c($(l,box),box.p[3])); -l=_c(l,_c($(r,box),box.p[4])); -r=_c(r,_c($(l,box),box.p[5])); -l=_c(l,_c($(r,box),box.p[6])); -r=_c(r,_c($(l,box),box.p[7])); -l=_c(l,_c($(r,box),box.p[8])); -r=_c(r,_c($(l,box),box.p[9])); -l=_c(l,_c($(r,box),box.p[10])); -r=_c(r,_c($(l,box),box.p[11])); -l=_c(l,_c($(r,box),box.p[12])); -r=_c(r,_c($(l,box),box.p[13])); -l=_c(l,_c($(r,box),box.p[14])); -r=_c(r,_c($(l,box),box.p[15])); -l=_c(l,_c($(r,box),box.p[16])); -o.right=l; -o.left=_c(r,box.p[17]); -}; -function db(o,box){ -var l=o.left; -var r=o.right; -l=_c(l,box.p[17]); -r=_c(r,_c($(l,box),box.p[16])); -l=_c(l,_c($(r,box),box.p[15])); -r=_c(r,_c($(l,box),box.p[14])); -l=_c(l,_c($(r,box),box.p[13])); -r=_c(r,_c($(l,box),box.p[12])); -l=_c(l,_c($(r,box),box.p[11])); -r=_c(r,_c($(l,box),box.p[10])); -l=_c(l,_c($(r,box),box.p[9])); -r=_c(r,_c($(l,box),box.p[8])); -l=_c(l,_c($(r,box),box.p[7])); -r=_c(r,_c($(l,box),box.p[6])); -l=_c(l,_c($(r,box),box.p[5])); -r=_c(r,_c($(l,box),box.p[4])); -l=_c(l,_c($(r,box),box.p[3])); -r=_c(r,_c($(l,box),box.p[2])); -l=_c(l,_c($(r,box),box.p[1])); -o.right=l; -o.left=_c(r,box.p[0]); -}; -function _21(key){ -var k=key; -if(dojo.isString(k)){ -k=dojo.map(k.split(""),function(_24){ -return _24.charCodeAt(0)&255; -}); -} -var pos=0,_26=0,res={left:0,right:0},i,j,l; -var box={p:dojo.map(_8.p.slice(0),function(_2c){ -var l=k.length,j; -for(j=0;j<4;j++){ -_26=(_26*_4)|k[pos++%l]; -} -return (((_2c>>16)^(_26>>16))<<16)|(((_2c&65535)^(_26&65535))&65535); -}),s0:_8.s0.slice(0),s1:_8.s1.slice(0),s2:_8.s2.slice(0),s3:_8.s3.slice(0)}; -for(i=0,l=box.p.length;i<l;){ -eb(res,box); -box.p[i++]=res.left,box.p[i++]=res.right; -} -for(i=0;i<4;i++){ -for(j=0,l=box["s"+i].length;j<l;){ -eb(res,box); -box["s"+i][j++]=res.left,box["s"+i][j++]=res.right; -} -} -return box; -}; -this.getIV=function(_2e){ -var out=_2e||dojox.encoding.crypto.outputTypes.Base64; -switch(out){ -case dojox.encoding.crypto.outputTypes.Hex: -return dojo.map(iv,function(_30){ -return (_30<=15?"0":"")+_30.toString(16); -}).join(""); -case dojox.encoding.crypto.outputTypes.String: -return iv.join(""); -case dojox.encoding.crypto.outputTypes.Raw: -return iv; -default: -return dojox.encoding.base64.encode(iv); -} -}; -this.setIV=function(_31,_32){ -var ip=_32||dojox.encoding.crypto.outputTypes.Base64; -var ba=null; -switch(ip){ -case dojox.encoding.crypto.outputTypes.String: -ba=dojo.map(_31.split(""),function(_35){ -return _35.charCodeAt(0); -}); -break; -case dojox.encoding.crypto.outputTypes.Hex: -ba=[]; -for(var i=0,l=_31.length-1;i<l;i+=2){ -ba.push(parseInt(_31.substr(i,2),16)); -} -break; -case dojox.encoding.crypto.outputTypes.Raw: -ba=_31; -break; -default: -ba=dojox.encoding.base64.decode(_31); -break; -} -iv={}; -iv.left=ba[0]*_6|ba[1]*_5|ba[2]*_4|ba[3]; -iv.right=ba[4]*_6|ba[5]*_5|ba[6]*_4|ba[7]; -}; -this.encrypt=function(_38,key,ao){ -var out=dojox.encoding.crypto.outputTypes.Base64; -var _3c=dojox.encoding.crypto.cipherModes.ECB; -if(ao){ -if(ao.outputType){ -out=ao.outputType; -} -if(ao.cipherMode){ -_3c=ao.cipherMode; -} -} -var bx=_21(key),_3e=8-(_38.length&7); -for(var i=0;i<_3e;i++){ -_38+=String.fromCharCode(_3e); -} -var _40=[],_41=_38.length>>3,pos=0,o={},_44=(_3c==dojox.encoding.crypto.cipherModes.CBC); -var _45={left:iv.left||null,right:iv.right||null}; -for(var i=0;i<_41;i++){ -o.left=_38.charCodeAt(pos)*_6|_38.charCodeAt(pos+1)*_5|_38.charCodeAt(pos+2)*_4|_38.charCodeAt(pos+3); -o.right=_38.charCodeAt(pos+4)*_6|_38.charCodeAt(pos+5)*_5|_38.charCodeAt(pos+6)*_4|_38.charCodeAt(pos+7); -if(_44){ -o.left=(((o.left>>16)^(_45.left>>16))<<16)|(((o.left&65535)^(_45.left&65535))&65535); -o.right=(((o.right>>16)^(_45.right>>16))<<16)|(((o.right&65535)^(_45.right&65535))&65535); -} -eb(o,bx); -if(_44){ -_45.left=o.left; -_45.right=o.right; -} -_40.push((o.left>>24)&255); -_40.push((o.left>>16)&255); -_40.push((o.left>>8)&255); -_40.push(o.left&255); -_40.push((o.right>>24)&255); -_40.push((o.right>>16)&255); -_40.push((o.right>>8)&255); -_40.push(o.right&255); -pos+=8; -} -switch(out){ -case dojox.encoding.crypto.outputTypes.Hex: -return dojo.map(_40,function(_46){ -return (_46<=15?"0":"")+_46.toString(16); -}).join(""); -case dojox.encoding.crypto.outputTypes.String: -return _40.join(""); -case dojox.encoding.crypto.outputTypes.Raw: -return _40; -default: -return dojox.encoding.base64.encode(_40); -} -}; -this.decrypt=function(_47,key,ao){ -var ip=dojox.encoding.crypto.outputTypes.Base64; -var _4b=dojox.encoding.crypto.cipherModes.ECB; -if(ao){ -if(ao.outputType){ -ip=ao.outputType; -} -if(ao.cipherMode){ -_4b=ao.cipherMode; -} -} -var bx=_21(key); -var pt=[]; -var c=null; -switch(ip){ -case dojox.encoding.crypto.outputTypes.Hex: -c=[]; -for(var i=0,l=_47.length-1;i<l;i+=2){ -c.push(parseInt(_47.substr(i,2),16)); -} -break; -case dojox.encoding.crypto.outputTypes.String: -c=dojo.map(_47.split(""),function(_51){ -return _51.charCodeAt(0); -}); -break; -case dojox.encoding.crypto.outputTypes.Raw: -c=_47; -break; -default: -c=dojox.encoding.base64.decode(_47); -break; -} -var _52=c.length>>3,pos=0,o={},_55=(_4b==dojox.encoding.crypto.cipherModes.CBC); -var _56={left:iv.left||null,right:iv.right||null}; -for(var i=0;i<_52;i++){ -o.left=c[pos]*_6|c[pos+1]*_5|c[pos+2]*_4|c[pos+3]; -o.right=c[pos+4]*_6|c[pos+5]*_5|c[pos+6]*_4|c[pos+7]; -if(_55){ -var _57=o.left; -var _58=o.right; -} -db(o,bx); -if(_55){ -o.left=(((o.left>>16)^(_56.left>>16))<<16)|(((o.left&65535)^(_56.left&65535))&65535); -o.right=(((o.right>>16)^(_56.right>>16))<<16)|(((o.right&65535)^(_56.right&65535))&65535); -_56.left=_57; -_56.right=_58; -} -pt.push((o.left>>24)&255); -pt.push((o.left>>16)&255); -pt.push((o.left>>8)&255); -pt.push(o.left&255); -pt.push((o.right>>24)&255); -pt.push((o.right>>16)&255); -pt.push((o.right>>8)&255); -pt.push(o.right&255); -pos+=8; -} -if(pt[pt.length-1]==pt[pt.length-2]||pt[pt.length-1]==1){ -var n=pt[pt.length-1]; -pt.splice(pt.length-n,n); -} -return dojo.map(pt,function(_5a){ -return String.fromCharCode(_5a); -}).join(""); -}; -this.setIV("0000000000000000",dojox.encoding.crypto.outputTypes.Hex); -}(); -} http://git-wip-us.apache.org/repos/asf/camel/blob/9f5e32db/components/camel-web/src/main/webapp/js/dojox/encoding/crypto/_base.js ---------------------------------------------------------------------- diff --git a/components/camel-web/src/main/webapp/js/dojox/encoding/crypto/_base.js b/components/camel-web/src/main/webapp/js/dojox/encoding/crypto/_base.js deleted file mode 100644 index 94f62c0..0000000 --- a/components/camel-web/src/main/webapp/js/dojox/encoding/crypto/_base.js +++ /dev/null @@ -1,16 +0,0 @@ -/* - Copyright (c) 2004-2009, 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["dojox.encoding.crypto._base"]){ -dojo._hasResource["dojox.encoding.crypto._base"]=true; -dojo.provide("dojox.encoding.crypto._base"); -(function(){ -var c=dojox.encoding.crypto; -c.cipherModes={ECB:0,CBC:1,PCBC:2,CFB:3,OFB:4,CTR:5}; -c.outputTypes={Base64:0,Hex:1,String:2,Raw:3}; -})(); -}