rem
stringlengths 0
126k
| add
stringlengths 0
441k
| context
stringlengths 15
136k
|
---|---|---|
"number")e=this.nthLine(e);this.selectLines(e,0);this.win.focus()},currentLine:function(){return this.lineNumber(this.cursorLine())},cursorLine:function(){return this.cursorPosition().line},cursorCoords:function(e){return this.editor.cursorCoords(e)},activateLineNumbers:function(){function e(){if(f.offsetWidth!=0){for(var y=f;y.parentNode;y=y.parentNode);if(!l.parentNode||y!=document||!g.Editor){try{w()}catch(A){}clearInterval(x)}else if(l.offsetWidth!=u){u=l.offsetWidth;f.parentNode.style.paddingLeft= | "number")a=this.nthLine(a);this.selectLines(a,0);this.win.focus()},currentLine:function(){return this.lineNumber(this.cursorLine())},cursorLine:function(){return this.cursorPosition().line},cursorCoords:function(a){return this.editor.cursorCoords(a)},activateLineNumbers:function(){function a(){if(d.offsetWidth!=0){for(var h=d;h.parentNode;h=h.parentNode);if(!i.parentNode||h!=document||!f.Editor){try{x()}catch(o){}clearInterval(I)}else if(i.offsetWidth!=y){y=i.offsetWidth;d.parentNode.style.paddingLeft= | "number")e=this.nthLine(e);this.selectLines(e,0);this.win.focus()},currentLine:function(){return this.lineNumber(this.cursorLine())},cursorLine:function(){return this.cursorPosition().line},cursorCoords:function(e){return this.editor.cursorCoords(e)},activateLineNumbers:function(){function e(){if(f.offsetWidth!=0){for(var y=f;y.parentNode;y=y.parentNode);if(!l.parentNode||y!=document||!g.Editor){try{w()}catch(A){}clearInterval(x)}else if(l.offsetWidth!=u){u=l.offsetWidth;f.parentNode.style.paddingLeft= |
offset:0},{node:b,offset:0})},cursorActivity:function(a){if(this.unloaded){window.document.designMode="off";window.document.designMode="on";this.unloaded=false}if(internetExplorer){this.container.createTextRange().execCommand("unlink");this.selectionSnapshot=select.getBookmark(this.container)}var b=this.options.cursorActivity;if(!a||b){var d=select.selectionTopNode(this.container,false);if(!(d===false||!this.container.firstChild)){d=d||this.container.firstChild;b&&b(d);if(!a){this.scheduleHighlight(); this.addDirtyNode(d)}}}},reparseBuffer:function(){forEach(this.container.childNodes,function(a){a.dirty=true});this.container.firstChild&&this.addDirtyNode(this.container.firstChild)},addDirtyNode:function(a){if(a=a||this.container.firstChild){for(var b=0;b<this.dirty.length;b++)if(this.dirty[b]==a)return;if(a.nodeType!=3)a.dirty=true;this.dirty.push(a)}},allClean:function(){return!this.dirty.length},scheduleHighlight:function(){var a=this;this.parent.clearTimeout(this.highlightTimeout);this.highlightTimeout= | d}else if(d)j=p*d;if(j)b.wrapping.style.height=Math.max(m+j,b.options.minHeight)+"px"}var b=this,c=b.options.cursorActivity,e=b.win,g=e.document.body,d=null,f=null,m=2*b.frame.offsetTop;g.style.overflowY="hidden";e.document.documentElement.style.overflowY="hidden";this.frame.scrolling="no";setTimeout(a,300);b.options.cursorActivity=function(p){c&&c(p);clearTimeout(f);f=setTimeout(a,100)}}};s.InvalidLineHandle={toString:function(){return"CodeMirror.InvalidLineHandle"}};s.replace=function(a){if(typeof a== | offset:0},{node:b,offset:0})},cursorActivity:function(a){if(this.unloaded){window.document.designMode="off";window.document.designMode="on";this.unloaded=false}if(internetExplorer){this.container.createTextRange().execCommand("unlink");this.selectionSnapshot=select.getBookmark(this.container)}var b=this.options.cursorActivity;if(!a||b){var d=select.selectionTopNode(this.container,false);if(!(d===false||!this.container.firstChild)){d=d||this.container.firstChild;b&&b(d);if(!a){this.scheduleHighlight();this.addDirtyNode(d)}}}},reparseBuffer:function(){forEach(this.container.childNodes,function(a){a.dirty=true});this.container.firstChild&&this.addDirtyNode(this.container.firstChild)},addDirtyNode:function(a){if(a=a||this.container.firstChild){for(var b=0;b<this.dirty.length;b++)if(this.dirty[b]==a)return;if(a.nodeType!=3)a.dirty=true;this.dirty.push(a)}},allClean:function(){return!this.dirty.length},scheduleHighlight:function(){var a=this;this.parent.clearTimeout(this.highlightTimeout);this.highlightTimeout= |
d);webkitLastLineHack(this.container)}},cursorCoords:function(a){function b(j,l){var m=-(document.body.scrollTop||document.documentElement.scrollTop||0),r=-(document.body.scrollLeft||document.documentElement.scrollLeft||0)+l;forEach([j,window.frameElement],function(u){for(;u;){r+=u.offsetLeft;m+=u.offsetTop;u=u.offsetParent}});return{x:r,y:m,yBot:m+j.offsetHeight}}function d(j,l){var m=document.createElement("SPAN");m.appendChild(document.createTextNode(j));try{return l(m)}finally{m.parentNode&&m.parentNode.removeChild(m)}} var f=select.cursorPos(this.container,a);if(!f)return null;a=f.offset;for(var g=f.node,h=this;a;){g=g?g.nextSibling:this.container.firstChild;f=nodeText(g);if(a<f.length)return d(f.substr(0,a),function(j){j.style.position="absolute";j.style.visibility="hidden";j.className=g.className;h.container.appendChild(j);return b(g,j.offsetWidth)});a-=f.length}return g&&isSpan(g)?b(g,g.offsetWidth):g&&g.nextSibling&&isSpan(g.nextSibling)?b(g.nextSibling,0):d("\u200b",function(j){g?g.parentNode.insertBefore(j, g.nextSibling):h.container.insertBefore(j,h.container.firstChild);return b(j,0)})},reroutePasteEvent:function(){if(!(this.capturingPaste||window.opera)){this.capturingPaste=true;var a=window.frameElement.CodeMirror.textareaHack;parent.focus();a.value="";a.focus();var b=this;this.parent.setTimeout(function(){b.capturingPaste=false;window.focus();b.selectionSnapshot&&window.select.setBookmark(b.container,b.selectionSnapshot);var d=a.value;if(d){b.replaceSelection(d);select.scrollToCursor(b.container)}}, | "number")a=this.nthLine(a);this.selectLines(a,0);this.win.focus()},currentLine:function(){return this.lineNumber(this.cursorLine())},cursorLine:function(){return this.cursorPosition().line},cursorCoords:function(a){return this.editor.cursorCoords(a)},activateLineNumbers:function(){function a(){if(d.offsetWidth!=0){for(var h=d;h.parentNode;h=h.parentNode);if(!i.parentNode||h!=document||!f.Editor){try{x()}catch(o){}clearInterval(I)}else if(i.offsetWidth!=y){y=i.offsetWidth;d.parentNode.style.paddingLeft= | d);webkitLastLineHack(this.container)}},cursorCoords:function(a){function b(j,l){var m=-(document.body.scrollTop||document.documentElement.scrollTop||0),r=-(document.body.scrollLeft||document.documentElement.scrollLeft||0)+l;forEach([j,window.frameElement],function(u){for(;u;){r+=u.offsetLeft;m+=u.offsetTop;u=u.offsetParent}});return{x:r,y:m,yBot:m+j.offsetHeight}}function d(j,l){var m=document.createElement("SPAN");m.appendChild(document.createTextNode(j));try{return l(m)}finally{m.parentNode&&m.parentNode.removeChild(m)}}var f=select.cursorPos(this.container,a);if(!f)return null;a=f.offset;for(var g=f.node,h=this;a;){g=g?g.nextSibling:this.container.firstChild;f=nodeText(g);if(a<f.length)return d(f.substr(0,a),function(j){j.style.position="absolute";j.style.visibility="hidden";j.className=g.className;h.container.appendChild(j);return b(g,j.offsetWidth)});a-=f.length}return g&&isSpan(g)?b(g,g.offsetWidth):g&&g.nextSibling&&isSpan(g.nextSibling)?b(g.nextSibling,0):d("\u200b",function(j){g?g.parentNode.insertBefore(j,g.nextSibling):h.container.insertBefore(j,h.container.firstChild);return b(j,0)})},reroutePasteEvent:function(){if(!(this.capturingPaste||window.opera)){this.capturingPaste=true;var a=window.frameElement.CodeMirror.textareaHack;parent.focus();a.value="";a.focus();var b=this;this.parent.setTimeout(function(){b.capturingPaste=false;window.focus();b.selectionSnapshot&&window.select.setBookmark(b.container,b.selectionSnapshot);var d=a.value;if(d){b.replaceSelection(d);select.scrollToCursor(b.container)}}, |
},cursorPosition:function(a){if(a==null)a=true;return(a=select.cursorPos(this.container,a))?{line:a.node,character:a.offset}:{line:null,character:0}},firstLine:function(){return null},lastLine:function(){return this.container.lastChild?n(this.container.lastChild):null},nextLine:function(a){this.checkLine(a);return o(a,this.container)||false},prevLine:function(a){this.checkLine(a);if(a==null)return false;return n(a.previousSibling)},visibleLineCount:function(){for(var a=this.container.firstChild;a&& | !this.lineNumbers){this.lineNumbers=E(this.wrapping,this.options.firstLineNumber);this.activateLineNumbers()}else if(!a&&this.lineNumbers){this.wrapping.removeChild(this.lineNumbers);this.wrapping.style.paddingLeft="";this.lineNumbers=null}},cursorPosition:function(a){this.focusIfIE();return this.editor.cursorPosition(a)},firstLine:function(){return this.editor.firstLine()},lastLine:function(){return this.editor.lastLine()},nextLine:function(a){return this.editor.nextLine(a)},prevLine:function(a){return this.editor.prevLine(a)}, | },cursorPosition:function(a){if(a==null)a=true;return(a=select.cursorPos(this.container,a))?{line:a.node,character:a.offset}:{line:null,character:0}},firstLine:function(){return null},lastLine:function(){return this.container.lastChild?n(this.container.lastChild):null},nextLine:function(a){this.checkLine(a);return o(a,this.container)||false},prevLine:function(a){this.checkLine(a);if(a==null)return false;return n(a.previousSibling)},visibleLineCount:function(){for(var a=this.container.firstChild;a&& |
null))return this.elem[this.prop];return(a=parseFloat(c.css(this.elem,this.prop,a)))&&a>-10000?a:parseFloat(c.curCSS(this.elem,this.prop))||0},custom:function(a,b,d){function f(i){return e.step(i)}this.startTime=K();this.start=a;this.end=b;this.unit=d||this.unit||"px";this.now=this.start;this.pos=this.state=0;var e=this;f.elem=this.elem;if(f()&&c.timers.push(f)&&!Z)Z=setInterval(c.fx.tick,13)},show:function(){this.options.orig[this.prop]=c.style(this.elem,this.prop);this.options.show=true;this.custom(this.prop=== | c.fx.step._default)(this);if((this.prop==="height"||this.prop==="width")&&this.elem.style)this.elem.style.display="block"},cur:function(a){if(this.elem[this.prop]!=null&&(!this.elem.style||this.elem.style[this.prop]==null))return this.elem[this.prop];return(a=parseFloat(c.css(this.elem,this.prop,a)))&&a>-10000?a:parseFloat(c.curCSS(this.elem,this.prop))||0},custom:function(a,b,d){function f(j){return e.step(j)}this.startTime=J();this.start=a;this.end=b;this.unit=d||this.unit||"px";this.now=this.start; this.pos=this.state=0;var e=this;f.elem=this.elem;if(f()&&c.timers.push(f)&&!W)W=setInterval(c.fx.tick,13)},show:function(){this.options.orig[this.prop]=c.style(this.elem,this.prop);this.options.show=true;this.custom(this.prop==="width"||this.prop==="height"?1:0,this.cur());c(this.elem).show()},hide:function(){this.options.orig[this.prop]=c.style(this.elem,this.prop);this.options.hide=true;this.custom(this.cur(),0)},step:function(a){var b=J(),d=true;if(a||b>=this.options.duration+this.startTime){this.now= | null))return this.elem[this.prop];return(a=parseFloat(c.css(this.elem,this.prop,a)))&&a>-10000?a:parseFloat(c.curCSS(this.elem,this.prop))||0},custom:function(a,b,d){function f(i){return e.step(i)}this.startTime=K();this.start=a;this.end=b;this.unit=d||this.unit||"px";this.now=this.start;this.pos=this.state=0;var e=this;f.elem=this.elem;if(f()&&c.timers.push(f)&&!Z)Z=setInterval(c.fx.tick,13)},show:function(){this.options.orig[this.prop]=c.style(this.elem,this.prop);this.options.show=true;this.custom(this.prop=== |
k){y=m[u.sizset];break}if(u.nodeType===1&&!q){u.sizcache=k;u.sizset=r}if(u.nodeName.toLowerCase()===h){y=u;break}u=u[g]}m[r]=y}}}function d(g,h,k,m,r,q){r=0;for(var v=m.length;r<v;r++){var u=m[r];if(u){u=u[g];for(var y=false;u;){if(u.sizcache===k){y=m[u.sizset];break}if(u.nodeType===1){if(!q){u.sizcache=k;u.sizset=r}if(typeof h!=="string"){if(u===h){y=true;break}}else if(p.filter(h,[u]).length>0){y=u;break}}u=u[g]}m[r]=y}}}var f=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g, | if(t){t=t[g];for(var y=false;t;){if(t.sizcache===l){y=m[t.sizset];break}if(t.nodeType===1&&!p){t.sizcache=l;t.sizset=q}if(t.nodeName.toLowerCase()===h){y=t;break}t=t[g]}m[q]=y}}}function d(g,h,l,m,q,p){q=0;for(var v=m.length;q<v;q++){var t=m[q];if(t){t=t[g];for(var y=false;t;){if(t.sizcache===l){y=m[t.sizset];break}if(t.nodeType===1){if(!p){t.sizcache=l;t.sizset=q}if(typeof h!=="string"){if(t===h){y=true;break}}else if(k.filter(h,[t]).length>0){y=t;break}}t=t[g]}m[q]=y}}}var f=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g, | k){y=m[u.sizset];break}if(u.nodeType===1&&!q){u.sizcache=k;u.sizset=r}if(u.nodeName.toLowerCase()===h){y=u;break}u=u[g]}m[r]=y}}}function d(g,h,k,m,r,q){r=0;for(var v=m.length;r<v;r++){var u=m[r];if(u){u=u[g];for(var y=false;u;){if(u.sizcache===k){y=m[u.sizset];break}if(u.nodeType===1){if(!q){u.sizcache=k;u.sizset=r}if(typeof h!=="string"){if(u===h){y=true;break}}else if(p.filter(h,[u]).length>0){y=u;break}}u=u[g]}m[r]=y}}}var f=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g, |
c(O):a(N)}function O(s,C){C=="in"?c(u):c(w,N)}function N(s,C){if(s==";")c(B);else C=="in"?c(u):c(u,j(";"),B)}function B(s){s==")"?a():c(u)}function D(s,C){if(s=="variable"){f(C);c(D)}else s=="("&&c(b,v(G,")"),r,d)}function G(s,C){if(s=="variable"){f(C);c()}}var F=tokenizeJavaScript(o),M=[n?m:l],J=null,K=new i((q||0)-indentUnit,0,"block",false),Q=0,R=0,t,I,P={next:function(){for(;M[M.length-1].lex;)M.pop()();var s=F.next();if(s.type=="whitespace"&&Q==0)R=s.value.length;Q+=s.value.length;if(s.content== | var CodeMirrorConfig=window.CodeMirrorConfig||{},CodeMirror=function(){function C(a,b){for(var c in b)a.hasOwnProperty(c)||(a[c]=b[c])}function D(a,b){for(var c=0;c<a.length;c++)b(a[c])}function E(a,b){var c=document.createElement("DIV"),e=document.createElement("DIV");c.style.position="absolute";c.style.height="100%";if(c.style.setExpression)try{c.style.setExpression("height","this.previousSibling.offsetHeight + 'px'")}catch(g){}c.style.top="0px";c.style.left="0px";c.style.overflow="hidden";a.appendChild(c); | c(O):a(N)}function O(s,C){C=="in"?c(u):c(w,N)}function N(s,C){if(s==";")c(B);else C=="in"?c(u):c(u,j(";"),B)}function B(s){s==")"?a():c(u)}function D(s,C){if(s=="variable"){f(C);c(D)}else s=="("&&c(b,v(G,")"),r,d)}function G(s,C){if(s=="variable"){f(C);c()}}var F=tokenizeJavaScript(o),M=[n?m:l],J=null,K=new i((q||0)-indentUnit,0,"block",false),Q=0,R=0,t,I,P={next:function(){for(;M[M.length-1].lex;)M.pop()();var s=F.next();if(s.type=="whitespace"&&Q==0)R=s.value.length;Q+=s.value.length;if(s.content== |
d.guid,function(f){var e=f.target,i=e.type;if((i==="text"||i==="password")&&c(e).closest("form").length&&f.keyCode===13)return pa("submit",this,arguments)})}else return false},remove:function(a,b){c.event.remove(this,"click.specialSubmit"+(b?"."+b.guid:""));c.event.remove(this,"keypress.specialSubmit"+(b?"."+b.guid:""))}};if(!c.support.changeBubbles){var ga=/textarea|input|select/i;function Da(a){var b=a.type,d=a.value;if(b==="radio"||b==="checkbox")d=a.checked;else if(b==="select-multiple")d=a.selectedIndex> -1?c.map(a.options,function(f){return f.selected}).join("-"):"";else if(a.nodeName.toLowerCase()==="select")d=a.selectedIndex;return d}function ha(a,b){var d=a.target,f,e;if(!(!ga.test(d.nodeName)||d.readOnly)){f=c.data(d,"_change_data");e=Da(d);if(e!==f){if(a.type!=="focusout"||d.type!=="radio")c.data(d,"_change_data",e);if(d.type!=="select"&&(f!=null||e)){a.type="change";return c.event.trigger(a,b,this)}}}}c.event.special.change={filters:{focusout:ha,click:function(a){var b=a.target,d=b.type;if(d=== | isImmediatePropagationStopped:Y};var Da=function(a){var b=a.relatedTarget;try{for(;b&&b!==this;)b=b.parentNode;if(b!==this){a.type=a.data;c.event.handle.apply(this,arguments)}}catch(d){}},Ea=function(a){a.type=a.data;c.event.handle.apply(this,arguments)};c.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(a,b){c.event.special[a]={setup:function(d){c.event.add(this,b,d&&d.selector?Ea:Da,a)},teardown:function(d){c.event.remove(this,b,d&&d.selector?Ea:Da)}}});if(!c.support.submitBubbles)c.event.special.submit= | d.guid,function(f){var e=f.target,i=e.type;if((i==="text"||i==="password")&&c(e).closest("form").length&&f.keyCode===13)return pa("submit",this,arguments)})}else return false},remove:function(a,b){c.event.remove(this,"click.specialSubmit"+(b?"."+b.guid:""));c.event.remove(this,"keypress.specialSubmit"+(b?"."+b.guid:""))}};if(!c.support.changeBubbles){var ga=/textarea|input|select/i;function Da(a){var b=a.type,d=a.value;if(b==="radio"||b==="checkbox")d=a.checked;else if(b==="select-multiple")d=a.selectedIndex>-1?c.map(a.options,function(f){return f.selected}).join("-"):"";else if(a.nodeName.toLowerCase()==="select")d=a.selectedIndex;return d}function ha(a,b){var d=a.target,f,e;if(!(!ga.test(d.nodeName)||d.readOnly)){f=c.data(d,"_change_data");e=Da(d);if(e!==f){if(a.type!=="focusout"||d.type!=="radio")c.data(d,"_change_data",e);if(d.type!=="select"&&(f!=null||e)){a.type="change";return c.event.trigger(a,b,this)}}}}c.event.special.change={filters:{focusout:ha,click:function(a){var b=a.target,d=b.type;if(d=== |
this.addonID = this.name + "@dactyl.googlecode.com"; | function Dactyl() { this.wrappedJSObject = this; this.HELP_TAGS = {}; this.FILE_MAP = {}; this.OVERLAY_MAP = {};} |
|
Dactyl.prototype.__proto__ = Cc["@dactyl.googlecode.com/base/dactyl"].getService().wrappedJSObject; | function Dactyl() { this.wrappedJSObject = this; this.HELP_TAGS = {}; this.FILE_MAP = {}; this.OVERLAY_MAP = {}; this.addonID = this.name + "@dactyl.googlecode.com";} |
|
require(global, "util"); | function Dactyl() { this.wrappedJSObject = this; this.HELP_TAGS = {}; this.FILE_MAP = {}; this.OVERLAY_MAP = {}; this.pages = {}; Cu.import("resource://dactyl/base.jsm"); require(global, "prefs"); ["appName", "fileExt", "host", "hostbin", "idName", "name", "version"].forEach(function (pref) this.__defineGetter__(pref, function () prefs.get("extensions.dactyl." + pref, "dactyl")), this); memoize(this, "addonID", function () this.name + "@dactyl.googlecode.com");} |
|
this.addonID = this.name + "@dactyl.googlecode.com"; | function Dactyl() { this.wrappedJSObject = this; this.HELP_TAGS = {}; this.FILE_MAP = {}; this.OVERLAY_MAP = {}; this.addonID = this.name + "@dactyl.googlecode.com"; this.pages = {}; for each (let pref in ["appName", "fileExt", "host", "hostbin", "idName", "name"]) this[pref] = prefs.getComplexValue(pref, Ci.nsISupportsString).data;} |
|
this.addonID = this.name + "@dactyl.googlecode.com"; | function Dactyl() { this.wrappedJSObject = this; this.HELP_TAGS = {}; this.FILE_MAP = {}; this.OVERLAY_MAP = {}; this.addonID = this.name + "@dactyl.googlecode.com"; this.pages = {}; for each (let pref in ["appName", "fileExt", "host", "hostbin", "idName", "name"]) this[pref] = prefs.getComplexValue(pref, Ci.nsISupportsString).data;} |
|
for each (let pref in ["appName", "fileExt", "host", "hostbin", "idName", "name"]) this[pref] = prefs.getComplexValue(pref, Ci.nsISupportsString).data; | function Dactyl() { this.wrappedJSObject = this; this.HELP_TAGS = {}; this.FILE_MAP = {}; this.OVERLAY_MAP = {}; this.addonID = this.name + "@dactyl.googlecode.com"; this.pages = {};} |
|
Dactyl.prototype.__proto__ = Cc["@dactyl.googlecode.com/base/dactyl"].getService().wrappedJSObject; | function Dactyl() { Dactyl.prototype.__proto__ = Cc["@dactyl.googlecode.com/base/dactyl"].getService().wrappedJSObject; this.wrappedJSObject = this; this.HELP_TAGS = {}; this.FILE_MAP = {}; this.OVERLAY_MAP = {}; this.addonID = this.name + "@dactyl.googlecode.com";} |
|
dasherize: function() { return this.gsub(/_/,'-'); }, | var Prototype={Version:"1.6.1",Browser:(function(){var b=navigator.userAgent;var a=Object.prototype.toString.call(window.opera)=="[object Opera]";return{IE:!!window.attachEvent&&!a,Opera:a,WebKit:b.indexOf("AppleWebKit/")>-1,Gecko:b.indexOf("Gecko")>-1&&b.indexOf("KHTML")===-1,MobileSafari:/Apple.*Mobile.*Safari/.test(b)}})(),BrowserFeatures:{XPath:!!document.evaluate,SelectorsAPI:!!document.querySelector,ElementExtensions:(function(){var a=window.Element||window.HTMLElement;return !!(a&&a.prototype)})(),SpecificElementExtensions:(function(){if(typeof window.HTMLDivElement!=="undefined"){return true}var c=document.createElement("div");var b=document.createElement("form");var a=false;if(c.__proto__&&(c.__proto__!==b.__proto__)){a=true}c=b=null;return a})()},ScriptFragment:"<script[^>]*>([\\S\\s]*?)<\/script>",JSONFilter:/^\/\*-secure-([\s\S]*)\*\/\s*$/,emptyFunction:function(){},K:function(a){return a}};if(Prototype.Browser.MobileSafari){Prototype.BrowserFeatures.SpecificElementExtensions=false}var Abstract={};var Try={these:function(){var c;for(var b=0,d=arguments.length;b<d;b++){var a=arguments[b];try{c=a();break}catch(f){}}return c}};var Class=(function(){function a(){}function b(){var g=null,f=$A(arguments);if(Object.isFunction(f[0])){g=f.shift()}function d(){this.initialize.apply(this,arguments)}Object.extend(d,Class.Methods);d.superclass=g;d.subclasses=[];if(g){a.prototype=g.prototype;d.prototype=new a;g.subclasses.push(d)}for(var e=0;e<f.length;e++){d.addMethods(f[e])}if(!d.prototype.initialize){d.prototype.initialize=Prototype.emptyFunction}d.prototype.constructor=d;return d}function c(k){var f=this.superclass&&this.superclass.prototype;var e=Object.keys(k);if(!Object.keys({toString:true}).length){if(k.toString!=Object.prototype.toString){e.push("toString")}if(k.valueOf!=Object.prototype.valueOf){e.push("valueOf")}}for(var d=0,g=e.length;d<g;d++){var j=e[d],h=k[j];if(f&&Object.isFunction(h)&&h.argumentNames().first()=="$super"){var l=h;h=(function(i){return function(){return f[i].apply(this,arguments)}})(j).wrap(l);h.valueOf=l.valueOf.bind(l);h.toString=l.toString.bind(l)}this.prototype[j]=h}return this}return{create:b,Methods:{addMethods:c}}})();(function(){var d=Object.prototype.toString;function i(q,s){for(var r in s){q[r]=s[r]}return q}function l(q){try{if(e(q)){return"undefined"}if(q===null){return"null"}return q.inspect?q.inspect():String(q)}catch(r){if(r instanceof RangeError){return"..."}throw r}}function k(q){var s=typeof q;switch(s){case"undefined":case"function":case"unknown":return;case"boolean":return q.toString()}if(q===null){return"null"}if(q.toJSON){return q.toJSON()}if(h(q)){return}var r=[];for(var u in q){var t=k(q[u]);if(!e(t)){r.push(u.toJSON()+": "+t)}}return"{"+r.join(", ")+"}"}function c(q){return $H(q).toQueryString()}function f(q){return q&&q.toHTML?q.toHTML():String.interpret(q)}function o(q){var r=[];for(var s in q){r.push(s)}return r}function m(q){var r=[];for(var s in q){r.push(q[s])}return r}function j(q){return i({},q)}function h(q){return !!(q&&q.nodeType==1)}function g(q){return d.call(q)=="[object Array]"}function p(q){return q instanceof Hash}function b(q){return typeof q==="function"}function a(q){return d.call(q)=="[object String]"}function n(q){return d.call(q)=="[object Number]"}function e(q){return typeof q==="undefined"}i(Object,{extend:i,inspect:l,toJSON:k,toQueryString:c,toHTML:f,keys:o,values:m,clone:j,isElement:h,isArray:g,isHash:p,isFunction:b,isString:a,isNumber:n,isUndefined:e})})();Object.extend(Function.prototype,(function(){var k=Array.prototype.slice;function d(o,l){var n=o.length,m=l.length;while(m--){o[n+m]=l[m]}return o}function i(m,l){m=k.call(m,0);return d(m,l)}function g(){var l=this.toString().match(/^[\s\(]*function[^(]*\(([^)]*)\)/)[1].replace(/\/\/.*?[\r\n]|\/\*(?:.|[\r\n])*?\*\ | dasherize: function() { return this.gsub(/_/,'-'); }, |
this.invokeLater(this.set, 100, "delayedShow", this.get("show")); | this.invokeLater(this.set, 100, "nowShowing", this.get("show") || "welcome"); | delayShow: function() { // wait a moment before loading to let things finish... this.invokeLater(this.set, 100, "delayedShow", this.get("show")); this.hideMasterPicker(); }.observes("show"), |
return path.split('~').last(); } | return( path.split( '~' ).last() ); } | function DePath(path) { // Returns the last element in a tilda-separated path as produced by StaticSync for the various tree levels. return path.split('~').last(); } |
function deprecated(reason, fn) | function deprecated(reason, fn) update( | function deprecated(reason, fn) function deprecatedMethod() { let frame = Components.stack.caller; if (!set.add(deprecated.seen, frame.filename)) dactyl.echoerr(frame.filename + ":" + frame.lineNumber + ": " + (this.className || this.constructor.className) + "." + fn.name + " is deprecated: " + reason); return fn.apply(this, arguments); }const Dactyl = Module("dactyl", { |
if (!set.add(deprecated.seen, frame.filename)) | if (!set.add(deprecatedMethod.seen, frame.filename)) | function deprecated(reason, fn) function deprecatedMethod() { let frame = Components.stack.caller; if (!set.add(deprecated.seen, frame.filename)) dactyl.echoerr(frame.filename + ":" + frame.lineNumber + ": " + (this.className || this.constructor.className) + "." + fn.name + " is deprecated: " + reason); return fn.apply(this, arguments); }const Dactyl = Module("dactyl", { |
} const Dactyl = Module("dactyl", { | }, { seen: { "chrome: | function deprecated(reason, fn) function deprecatedMethod() { let frame = Components.stack.caller; if (!set.add(deprecated.seen, frame.filename)) dactyl.echoerr(frame.filename + ":" + frame.lineNumber + ": " + (this.className || this.constructor.className) + "." + fn.name + " is deprecated: " + reason); return fn.apply(this, arguments); }const Dactyl = Module("dactyl", { |
if (!set.add(deprecated.seen, frame.filename)) | if (!set.add(deprecatedMethod.seen, frame.filename)) | function deprecatedMethod() { let frame = Components.stack.caller; if (!set.add(deprecated.seen, frame.filename)) dactyl.echoerr(frame.filename + ":" + frame.lineNumber + ": " + (this.className || this.constructor.className) + "." + fn.name + " is deprecated: " + reason); return fn.apply(this, arguments); } |
} | }, | function deprecatedMethod() { let frame = Components.stack.caller; if (!set.add(deprecated.seen, frame.filename)) dactyl.echoerr(frame.filename + ":" + frame.lineNumber + ": " + (this.className || this.constructor.className) + "." + fn.name + " is deprecated: " + reason); return fn.apply(this, arguments); } |
descendantOf: function(element, ancestor) { element = $(element), ancestor = $(ancestor); if (element.compareDocumentPosition) return (element.compareDocumentPosition(ancestor) & 8) === 8; if (ancestor.contains) return ancestor.contains(element) && ancestor !== element; while (element = element.parentNode) if (element == ancestor) return true; return false; }, | var Prototype={Version:"1.6.1",Browser:(function(){var b=navigator.userAgent;var a=Object.prototype.toString.call(window.opera)=="[object Opera]";return{IE:!!window.attachEvent&&!a,Opera:a,WebKit:b.indexOf("AppleWebKit/")>-1,Gecko:b.indexOf("Gecko")>-1&&b.indexOf("KHTML")===-1,MobileSafari:/Apple.*Mobile.*Safari/.test(b)}})(),BrowserFeatures:{XPath:!!document.evaluate,SelectorsAPI:!!document.querySelector,ElementExtensions:(function(){var a=window.Element||window.HTMLElement;return !!(a&&a.prototype)})(),SpecificElementExtensions:(function(){if(typeof window.HTMLDivElement!=="undefined"){return true}var c=document.createElement("div");var b=document.createElement("form");var a=false;if(c.__proto__&&(c.__proto__!==b.__proto__)){a=true}c=b=null;return a})()},ScriptFragment:"<script[^>]*>([\\S\\s]*?)<\/script>",JSONFilter:/^\/\*-secure-([\s\S]*)\*\/\s*$/,emptyFunction:function(){},K:function(a){return a}};if(Prototype.Browser.MobileSafari){Prototype.BrowserFeatures.SpecificElementExtensions=false}var Abstract={};var Try={these:function(){var c;for(var b=0,d=arguments.length;b<d;b++){var a=arguments[b];try{c=a();break}catch(f){}}return c}};var Class=(function(){function a(){}function b(){var g=null,f=$A(arguments);if(Object.isFunction(f[0])){g=f.shift()}function d(){this.initialize.apply(this,arguments)}Object.extend(d,Class.Methods);d.superclass=g;d.subclasses=[];if(g){a.prototype=g.prototype;d.prototype=new a;g.subclasses.push(d)}for(var e=0;e<f.length;e++){d.addMethods(f[e])}if(!d.prototype.initialize){d.prototype.initialize=Prototype.emptyFunction}d.prototype.constructor=d;return d}function c(k){var f=this.superclass&&this.superclass.prototype;var e=Object.keys(k);if(!Object.keys({toString:true}).length){if(k.toString!=Object.prototype.toString){e.push("toString")}if(k.valueOf!=Object.prototype.valueOf){e.push("valueOf")}}for(var d=0,g=e.length;d<g;d++){var j=e[d],h=k[j];if(f&&Object.isFunction(h)&&h.argumentNames().first()=="$super"){var l=h;h=(function(i){return function(){return f[i].apply(this,arguments)}})(j).wrap(l);h.valueOf=l.valueOf.bind(l);h.toString=l.toString.bind(l)}this.prototype[j]=h}return this}return{create:b,Methods:{addMethods:c}}})();(function(){var d=Object.prototype.toString;function i(q,s){for(var r in s){q[r]=s[r]}return q}function l(q){try{if(e(q)){return"undefined"}if(q===null){return"null"}return q.inspect?q.inspect():String(q)}catch(r){if(r instanceof RangeError){return"..."}throw r}}function k(q){var s=typeof q;switch(s){case"undefined":case"function":case"unknown":return;case"boolean":return q.toString()}if(q===null){return"null"}if(q.toJSON){return q.toJSON()}if(h(q)){return}var r=[];for(var u in q){var t=k(q[u]);if(!e(t)){r.push(u.toJSON()+": "+t)}}return"{"+r.join(", ")+"}"}function c(q){return $H(q).toQueryString()}function f(q){return q&&q.toHTML?q.toHTML():String.interpret(q)}function o(q){var r=[];for(var s in q){r.push(s)}return r}function m(q){var r=[];for(var s in q){r.push(q[s])}return r}function j(q){return i({},q)}function h(q){return !!(q&&q.nodeType==1)}function g(q){return d.call(q)=="[object Array]"}function p(q){return q instanceof Hash}function b(q){return typeof q==="function"}function a(q){return d.call(q)=="[object String]"}function n(q){return d.call(q)=="[object Number]"}function e(q){return typeof q==="undefined"}i(Object,{extend:i,inspect:l,toJSON:k,toQueryString:c,toHTML:f,keys:o,values:m,clone:j,isElement:h,isArray:g,isHash:p,isFunction:b,isString:a,isNumber:n,isUndefined:e})})();Object.extend(Function.prototype,(function(){var k=Array.prototype.slice;function d(o,l){var n=o.length,m=l.length;while(m--){o[n+m]=l[m]}return o}function i(m,l){m=k.call(m,0);return d(m,l)}function g(){var l=this.toString().match(/^[\s\(]*function[^(]*\(([^)]*)\)/)[1].replace(/\/\/.*?[\r\n]|\/\*(?:.|[\r\n])*?\*\ | descendantOf: function(element, ancestor) { element = $(element), ancestor = $(ancestor); if (element.compareDocumentPosition) return (element.compareDocumentPosition(ancestor) & 8) === 8; if (ancestor.contains) return ancestor.contains(element) && ancestor !== element; while (element = element.parentNode) if (element == ancestor) return true; return false; }, |
descendants: function(element) { return $(element).select("*"); }, | var Prototype={Version:"1.6.1",Browser:(function(){var b=navigator.userAgent;var a=Object.prototype.toString.call(window.opera)=="[object Opera]";return{IE:!!window.attachEvent&&!a,Opera:a,WebKit:b.indexOf("AppleWebKit/")>-1,Gecko:b.indexOf("Gecko")>-1&&b.indexOf("KHTML")===-1,MobileSafari:/Apple.*Mobile.*Safari/.test(b)}})(),BrowserFeatures:{XPath:!!document.evaluate,SelectorsAPI:!!document.querySelector,ElementExtensions:(function(){var a=window.Element||window.HTMLElement;return !!(a&&a.prototype)})(),SpecificElementExtensions:(function(){if(typeof window.HTMLDivElement!=="undefined"){return true}var c=document.createElement("div");var b=document.createElement("form");var a=false;if(c.__proto__&&(c.__proto__!==b.__proto__)){a=true}c=b=null;return a})()},ScriptFragment:"<script[^>]*>([\\S\\s]*?)<\/script>",JSONFilter:/^\/\*-secure-([\s\S]*)\*\/\s*$/,emptyFunction:function(){},K:function(a){return a}};if(Prototype.Browser.MobileSafari){Prototype.BrowserFeatures.SpecificElementExtensions=false}var Abstract={};var Try={these:function(){var c;for(var b=0,d=arguments.length;b<d;b++){var a=arguments[b];try{c=a();break}catch(f){}}return c}};var Class=(function(){function a(){}function b(){var g=null,f=$A(arguments);if(Object.isFunction(f[0])){g=f.shift()}function d(){this.initialize.apply(this,arguments)}Object.extend(d,Class.Methods);d.superclass=g;d.subclasses=[];if(g){a.prototype=g.prototype;d.prototype=new a;g.subclasses.push(d)}for(var e=0;e<f.length;e++){d.addMethods(f[e])}if(!d.prototype.initialize){d.prototype.initialize=Prototype.emptyFunction}d.prototype.constructor=d;return d}function c(k){var f=this.superclass&&this.superclass.prototype;var e=Object.keys(k);if(!Object.keys({toString:true}).length){if(k.toString!=Object.prototype.toString){e.push("toString")}if(k.valueOf!=Object.prototype.valueOf){e.push("valueOf")}}for(var d=0,g=e.length;d<g;d++){var j=e[d],h=k[j];if(f&&Object.isFunction(h)&&h.argumentNames().first()=="$super"){var l=h;h=(function(i){return function(){return f[i].apply(this,arguments)}})(j).wrap(l);h.valueOf=l.valueOf.bind(l);h.toString=l.toString.bind(l)}this.prototype[j]=h}return this}return{create:b,Methods:{addMethods:c}}})();(function(){var d=Object.prototype.toString;function i(q,s){for(var r in s){q[r]=s[r]}return q}function l(q){try{if(e(q)){return"undefined"}if(q===null){return"null"}return q.inspect?q.inspect():String(q)}catch(r){if(r instanceof RangeError){return"..."}throw r}}function k(q){var s=typeof q;switch(s){case"undefined":case"function":case"unknown":return;case"boolean":return q.toString()}if(q===null){return"null"}if(q.toJSON){return q.toJSON()}if(h(q)){return}var r=[];for(var u in q){var t=k(q[u]);if(!e(t)){r.push(u.toJSON()+": "+t)}}return"{"+r.join(", ")+"}"}function c(q){return $H(q).toQueryString()}function f(q){return q&&q.toHTML?q.toHTML():String.interpret(q)}function o(q){var r=[];for(var s in q){r.push(s)}return r}function m(q){var r=[];for(var s in q){r.push(q[s])}return r}function j(q){return i({},q)}function h(q){return !!(q&&q.nodeType==1)}function g(q){return d.call(q)=="[object Array]"}function p(q){return q instanceof Hash}function b(q){return typeof q==="function"}function a(q){return d.call(q)=="[object String]"}function n(q){return d.call(q)=="[object Number]"}function e(q){return typeof q==="undefined"}i(Object,{extend:i,inspect:l,toJSON:k,toQueryString:c,toHTML:f,keys:o,values:m,clone:j,isElement:h,isArray:g,isHash:p,isFunction:b,isString:a,isNumber:n,isUndefined:e})})();Object.extend(Function.prototype,(function(){var k=Array.prototype.slice;function d(o,l){var n=o.length,m=l.length;while(m--){o[n+m]=l[m]}return o}function i(m,l){m=k.call(m,0);return d(m,l)}function g(){var l=this.toString().match(/^[\s\(]*function[^(]*\(([^)]*)\)/)[1].replace(/\/\/.*?[\r\n]|\/\*(?:.|[\r\n])*?\*\ | descendants: function(element) { return $(element).select("*"); }, |
var path=DePath(TreeNames[field][node]); var p=TreeParents[field][node]; while (p>-1) { path=DePath(TreeNames[field][p]) + " / " + path; var p=TreeParents[field][p]; } return path; | var path = DePath( TreeNames[field][node] ); var p = TreeParents[field][node]; while( p > -1 ) { path = DePath( TreeNames[field][p] ) + " / " + path; var p = TreeParents[field][p]; | function DescribeNode(field,node) { // Returns a string containing the node's 'path' var path=DePath(TreeNames[field][node]); var p=TreeParents[field][node]; while (p>-1) { path=DePath(TreeNames[field][p]) + " / " + path; var p=TreeParents[field][p]; } return path; } |
return( path ); } | function DescribeNode(field,node) { // Returns a string containing the node's 'path' var path=DePath(TreeNames[field][node]); var p=TreeParents[field][node]; while (p>-1) { path=DePath(TreeNames[field][p]) + " / " + path; var p=TreeParents[field][p]; } return path; } |
|
description: function (item) self.getKey(obj, item), | description: function (item) self.getKey(args.obj, item), | description: function (item) self.getKey(obj, item), |
function DeselectAll(field) { var i=0; for (i=0;i<TreeParents[field].length;i++) { TreeChecked[field][i]=0; } DrawTree(field); UpdateStatusBox(field); UpdateHiddenField(field); | function DeselectAll( field ) { for( var i = 0; i < TreeParents[field].length; i++ ) { TreeChecked[field][i] = 0; | function DeselectAll(field) { var i=0; for (i=0;i<TreeParents[field].length;i++) { TreeChecked[field][i]=0; } DrawTree(field); UpdateStatusBox(field); UpdateHiddenField(field); } |
DrawTree( field ); UpdateStatusBox( field ); UpdateHiddenField( field ); } | function DeselectAll(field) { var i=0; for (i=0;i<TreeParents[field].length;i++) { TreeChecked[field][i]=0; } DrawTree(field); UpdateStatusBox(field); UpdateHiddenField(field); } |
|
autocommands.trigger(config.name + "LeavePre", {}); | autocommands.trigger("LeavePre", {}); | destroy: function () { autocommands.trigger(config.name + "LeavePre", {}); storage.saveAll(); dactyl.triggerObserver("shutdown", null); dactyl.dump("All dactyl modules destroyed\n"); autocommands.trigger(config.name + "Leave", {}); }, |
autocommands.trigger(config.name + "Leave", {}); | autocommands.trigger("Leave", {}); | destroy: function () { autocommands.trigger(config.name + "LeavePre", {}); storage.saveAll(); dactyl.triggerObserver("shutdown", null); dactyl.dump("All dactyl modules destroyed\n"); autocommands.trigger(config.name + "Leave", {}); }, |
destroy: function () { }, | destroy: function() { if (this.docShell) this.docShell.destroy(); }, | destroy: function () { }, |
try { config.browser.removeProgressListener(this.progressListener); } catch (e) {} | destroy: function () { try { config.browser.removeProgressListener(this.progressListener); } catch (e) {} // Why? --djk }, |
|
var isObserving = this._scfl_isObserving || SC.CoreSet.create(); for (var idx in isObserving) { this._scfl_unobserveChild(isObserving[idx]); | var isObserving = this._scfl_isObserving; if (!isObserving) return; var len = isObserving.length, idx; for (idx = 0; idx < len; idx++) { this.unobserveChildLayout(isObserving[idx]); | destroyMixin: function() { var isObserving = this._scfl_isObserving || SC.CoreSet.create(); for (var idx in isObserving) { this._scfl_unobserveChild(isObserving[idx]); } } |
this[0].parentNode){c.isFunction(a)||(a=c(a).detach());return this.each(function(){var b=this.nextSibling,d=this.parentNode;c(this).remove();b?c(b).before(a):c(d).append(a)})}else return this.pushStack(c(c.isFunction(a)?a():a),"replaceWith",a)},detach:function(a){return this.remove(a,true)},domManip:function(a,b,d){function f(t){return c.nodeName(t,"table")?t.getElementsByTagName("tbody")[0]||t.appendChild(t.ownerDocument.createElement("tbody")):t}var e,i,j=a[0],o=[];if(c.isFunction(j))return this.each(function(t){var z= | this[0].parentNode){if(c.isFunction(a))return this.each(function(b){var d=c(this),f=d.html();d.replaceWith(a.call(this,b,f))});if(typeof a!=="string")a=c(a).detach();return this.each(function(){var b=this.nextSibling,d=this.parentNode;c(this).remove();b?c(b).before(a):c(d).append(a)})}else return this.pushStack(c(c.isFunction(a)?a():a),"replaceWith",a)},detach:function(a){return this.remove(a,true)},domManip:function(a,b,d){function f(u){return c.nodeName(u,"table")?u.getElementsByTagName("tbody")[0]|| | this[0].parentNode){c.isFunction(a)||(a=c(a).detach());return this.each(function(){var b=this.nextSibling,d=this.parentNode;c(this).remove();b?c(b).before(a):c(d).append(a)})}else return this.pushStack(c(c.isFunction(a)?a():a),"replaceWith",a)},detach:function(a){return this.remove(a,true)},domManip:function(a,b,d){function f(t){return c.nodeName(t,"table")?t.getElementsByTagName("tbody")[0]||t.appendChild(t.ownerDocument.createElement("tbody")):t}var e,i,j=a[0],o=[];if(c.isFunction(j))return this.each(function(t){var z= |
context.completions = config.dialogs; | context.completions = [[k, v[0]] for ([k, v] in Iterator(config.dialogs))]; | completion.dialog = function dialog(context) { context.title = ["Dialog"]; context.completions = config.dialogs; }; |
var len = arguments.len, idx; | var len = arguments.length, idx; | didChangeFor: function(context) { var len = arguments.len, idx; for (idx = 1; idx < len; idx++) { var property = arguments[idx], displayProperty = 'display' + property.capitalize(); if (this._displayPropertiesLookup[displayProperty]) { if (this.view.didChangeFor(context, displayProperty)) return YES; } else if (this._displayPropertiesLookup[property]) { if (this.view.didChangeFor(context, property)) return YES; } } return NO; } |
} else { throw "RenderDelegate expected property '" + property + "', but the view " + "does not have this property as a displayProperty."; | didChangeFor: function(context) { var len = arguments.len, idx; for (idx = 1; idx < len; idx++) { var property = arguments[idx], displayProperty = 'display' + property.capitalize(); if (this._displayPropertiesLookup[displayProperty]) { if (this.view.didChangeFor(context, displayProperty)) return YES; } else if (this._displayPropertiesLookup[property]) { if (this.view.didChangeFor(context, property)) return YES; } else { throw "RenderDelegate expected property '" + property + "', but the view " + "does not have this property as a displayProperty."; } } return NO; } |
|
didCreateLayerMixin: function() { mixinCount++; } | didCreateLayerMixin: function() { mixinCount++; }, | didCreateLayerMixin: function() { mixinCount++; } |
a.contentDocument||a.contentWindow.document:c.makeArray(a.childNodes)}},function(a,b){c.fn[a]=function(d,f){var e=c.map(this,b,d);ab.test(a)||(f=d);if(f&&typeof f==="string")e=c.filter(f,e);e=this.length>1?c.unique(e):e;if((this.length>1||cb.test(f))&&bb.test(a))e=e.reverse();return this.pushStack(e,a,R.call(arguments).join(","))}});c.extend({filter:function(a,b,d){if(d)a=":not("+a+")";return c.find.matches(a,b)},dir:function(a,b,d){var f=[];for(a=a[b];a&&a.nodeType!==9&&(d===w||!c(a).is(d));){a.nodeType=== 1&&f.push(a);a=a[b]}return f},nth:function(a,b,d){b=b||1;for(var f=0;a;a=a[d])if(a.nodeType===1&&++f===b)break;return a},sibling:function(a,b){for(var d=[];a;a=a.nextSibling)a.nodeType===1&&a!==b&&d.push(a);return d}});var Ga=/ jQuery\d+="(?:\d+|null)"/g,Y=/^\s+/,db=/(<([\w:]+)[^>]*?)\/>/g,eb=/^(?:area|br|col|embed|hr|img|input|link|meta|param)$/i,Ha=/<([\w:]+)/,fb=/<tbody/i,gb=/<|&\w+;/,hb=function(a,b,d){return eb.test(d)?a:b+"></"+d+">"},G={option:[1,"<select multiple='multiple'>","</select>"], | a.contentDocument||a.contentWindow.document:c.makeArray(a.childNodes)}},function(a,b){c.fn[a]=function(d,f){var e=c.map(this,b,d);eb.test(a)||(f=d);if(f&&typeof f==="string")e=c.filter(f,e);e=this.length>1?c.unique(e):e;if((this.length>1||gb.test(f))&&fb.test(a))e=e.reverse();return this.pushStack(e,a,R.call(arguments).join(","))}});c.extend({filter:function(a,b,d){if(d)a=":not("+a+")";return c.find.matches(a,b)},dir:function(a,b,d){var f=[];for(a=a[b];a&&a.nodeType!==9&&(d===w||a.nodeType!==1||!c(a).is(d));){a.nodeType=== 1&&f.push(a);a=a[b]}return f},nth:function(a,b,d){b=b||1;for(var f=0;a;a=a[d])if(a.nodeType===1&&++f===b)break;return a},sibling:function(a,b){for(var d=[];a;a=a.nextSibling)a.nodeType===1&&a!==b&&d.push(a);return d}});var Ja=/ jQuery\d+="(?:\d+|null)"/g,V=/^\s+/,Ka=/(<([\w:]+)[^>]*?)\/>/g,hb=/^(?:area|br|col|embed|hr|img|input|link|meta|param)$/i,La=/<([\w:]+)/,ib=/<tbody/i,jb=/<|&#?\w+;/,ta=/<script|<object|<embed|<option|<style/i,ua=/checked\s*(?:[^=]|=\s*.checked.)/i,Ma=function(a,b,d){return hb.test(d)? | a.contentDocument||a.contentWindow.document:c.makeArray(a.childNodes)}},function(a,b){c.fn[a]=function(d,f){var e=c.map(this,b,d);ab.test(a)||(f=d);if(f&&typeof f==="string")e=c.filter(f,e);e=this.length>1?c.unique(e):e;if((this.length>1||cb.test(f))&&bb.test(a))e=e.reverse();return this.pushStack(e,a,R.call(arguments).join(","))}});c.extend({filter:function(a,b,d){if(d)a=":not("+a+")";return c.find.matches(a,b)},dir:function(a,b,d){var f=[];for(a=a[b];a&&a.nodeType!==9&&(d===w||!c(a).is(d));){a.nodeType===1&&f.push(a);a=a[b]}return f},nth:function(a,b,d){b=b||1;for(var f=0;a;a=a[d])if(a.nodeType===1&&++f===b)break;return a},sibling:function(a,b){for(var d=[];a;a=a.nextSibling)a.nodeType===1&&a!==b&&d.push(a);return d}});var Ga=/ jQuery\d+="(?:\d+|null)"/g,Y=/^\s+/,db=/(<([\w:]+)[^>]*?)\/>/g,eb=/^(?:area|br|col|embed|hr|img|input|link|meta|param)$/i,Ha=/<([\w:]+)/,fb=/<tbody/i,gb=/<|&\w+;/,hb=function(a,b,d){return eb.test(d)?a:b+"></"+d+">"},G={option:[1,"<select multiple='multiple'>","</select>"], |
completion.directory = function directory(context, full) { this.file(context, full); | completion.directory = function directory(context, args, full) { this.file(context, args, full); | completion.directory = function directory(context, full) { this.file(context, full); context.filters.push(function ({ item }) item.isDirectory()); }; |
disable: function(element) { element = $(element); element.disabled = true; return element; }, | var Prototype={Version:"1.6.1",Browser:(function(){var b=navigator.userAgent;var a=Object.prototype.toString.call(window.opera)=="[object Opera]";return{IE:!!window.attachEvent&&!a,Opera:a,WebKit:b.indexOf("AppleWebKit/")>-1,Gecko:b.indexOf("Gecko")>-1&&b.indexOf("KHTML")===-1,MobileSafari:/Apple.*Mobile.*Safari/.test(b)}})(),BrowserFeatures:{XPath:!!document.evaluate,SelectorsAPI:!!document.querySelector,ElementExtensions:(function(){var a=window.Element||window.HTMLElement;return !!(a&&a.prototype)})(),SpecificElementExtensions:(function(){if(typeof window.HTMLDivElement!=="undefined"){return true}var c=document.createElement("div");var b=document.createElement("form");var a=false;if(c.__proto__&&(c.__proto__!==b.__proto__)){a=true}c=b=null;return a})()},ScriptFragment:"<script[^>]*>([\\S\\s]*?)<\/script>",JSONFilter:/^\/\*-secure-([\s\S]*)\*\/\s*$/,emptyFunction:function(){},K:function(a){return a}};if(Prototype.Browser.MobileSafari){Prototype.BrowserFeatures.SpecificElementExtensions=false}var Abstract={};var Try={these:function(){var c;for(var b=0,d=arguments.length;b<d;b++){var a=arguments[b];try{c=a();break}catch(f){}}return c}};var Class=(function(){function a(){}function b(){var g=null,f=$A(arguments);if(Object.isFunction(f[0])){g=f.shift()}function d(){this.initialize.apply(this,arguments)}Object.extend(d,Class.Methods);d.superclass=g;d.subclasses=[];if(g){a.prototype=g.prototype;d.prototype=new a;g.subclasses.push(d)}for(var e=0;e<f.length;e++){d.addMethods(f[e])}if(!d.prototype.initialize){d.prototype.initialize=Prototype.emptyFunction}d.prototype.constructor=d;return d}function c(k){var f=this.superclass&&this.superclass.prototype;var e=Object.keys(k);if(!Object.keys({toString:true}).length){if(k.toString!=Object.prototype.toString){e.push("toString")}if(k.valueOf!=Object.prototype.valueOf){e.push("valueOf")}}for(var d=0,g=e.length;d<g;d++){var j=e[d],h=k[j];if(f&&Object.isFunction(h)&&h.argumentNames().first()=="$super"){var l=h;h=(function(i){return function(){return f[i].apply(this,arguments)}})(j).wrap(l);h.valueOf=l.valueOf.bind(l);h.toString=l.toString.bind(l)}this.prototype[j]=h}return this}return{create:b,Methods:{addMethods:c}}})();(function(){var d=Object.prototype.toString;function i(q,s){for(var r in s){q[r]=s[r]}return q}function l(q){try{if(e(q)){return"undefined"}if(q===null){return"null"}return q.inspect?q.inspect():String(q)}catch(r){if(r instanceof RangeError){return"..."}throw r}}function k(q){var s=typeof q;switch(s){case"undefined":case"function":case"unknown":return;case"boolean":return q.toString()}if(q===null){return"null"}if(q.toJSON){return q.toJSON()}if(h(q)){return}var r=[];for(var u in q){var t=k(q[u]);if(!e(t)){r.push(u.toJSON()+": "+t)}}return"{"+r.join(", ")+"}"}function c(q){return $H(q).toQueryString()}function f(q){return q&&q.toHTML?q.toHTML():String.interpret(q)}function o(q){var r=[];for(var s in q){r.push(s)}return r}function m(q){var r=[];for(var s in q){r.push(q[s])}return r}function j(q){return i({},q)}function h(q){return !!(q&&q.nodeType==1)}function g(q){return d.call(q)=="[object Array]"}function p(q){return q instanceof Hash}function b(q){return typeof q==="function"}function a(q){return d.call(q)=="[object String]"}function n(q){return d.call(q)=="[object Number]"}function e(q){return typeof q==="undefined"}i(Object,{extend:i,inspect:l,toJSON:k,toQueryString:c,toHTML:f,keys:o,values:m,clone:j,isElement:h,isArray:g,isHash:p,isFunction:b,isString:a,isNumber:n,isUndefined:e})})();Object.extend(Function.prototype,(function(){var k=Array.prototype.slice;function d(o,l){var n=o.length,m=l.length;while(m--){o[n+m]=l[m]}return o}function i(m,l){m=k.call(m,0);return d(m,l)}function g(){var l=this.toString().match(/^[\s\(]*function[^(]*\(([^)]*)\)/)[1].replace(/\/\/.*?[\r\n]|\/\*(?:.|[\r\n])*?\*\ | disable: function(element) { element = $(element); element.disabled = true; return element; }, |
equals(view.$('.sc-disclosure-view').size(), 0, "should not have disclosure"); | ok(!cq.hasClass('has-disclosure'), "should not have has-disclosure class"); equals(disclosureCQ.size(), 0, "should not have disclosure"); | function disclosure(view, state) { if (state === null) { equals(view.$('.sc-disclosure-view').size(), 0, "should not have disclosure"); } else { var cq = view.$('.sc-disclosure-view'); equals(cq.size(), 1, "should have disclosure element"); equals(cq.hasClass('sel'), state === true, "disclosure expects sel class"); }} |
var cq = view.$('.sc-disclosure-view'); equals(cq.size(), 1, "should have disclosure element"); equals(cq.hasClass('sel'), state === true, "disclosure expects sel class"); | ok(cq.hasClass('has-disclosure'), "should have has-disclosure class"); equals(disclosureCQ.size(), 1, "should have disclosure element"); equals(disclosureCQ.hasClass('sel'), state === true, "disclosure expects sel class"); | function disclosure(view, state) { if (state === null) { equals(view.$('.sc-disclosure-view').size(), 0, "should not have disclosure"); } else { var cq = view.$('.sc-disclosure-view'); equals(cq.size(), 1, "should have disclosure element"); equals(cq.hasClass('sel'), state === true, "disclosure expects sel class"); }} |
dispatch: function(callback, request, transport, json) { this.each(function(responder) { if (Object.isFunction(responder[callback])) { try { responder[callback].apply(responder, [request, transport, json]); } catch (e) { } } }); } | var Prototype={Version:"1.6.1",Browser:(function(){var b=navigator.userAgent;var a=Object.prototype.toString.call(window.opera)=="[object Opera]";return{IE:!!window.attachEvent&&!a,Opera:a,WebKit:b.indexOf("AppleWebKit/")>-1,Gecko:b.indexOf("Gecko")>-1&&b.indexOf("KHTML")===-1,MobileSafari:/Apple.*Mobile.*Safari/.test(b)}})(),BrowserFeatures:{XPath:!!document.evaluate,SelectorsAPI:!!document.querySelector,ElementExtensions:(function(){var a=window.Element||window.HTMLElement;return !!(a&&a.prototype)})(),SpecificElementExtensions:(function(){if(typeof window.HTMLDivElement!=="undefined"){return true}var c=document.createElement("div");var b=document.createElement("form");var a=false;if(c.__proto__&&(c.__proto__!==b.__proto__)){a=true}c=b=null;return a})()},ScriptFragment:"<script[^>]*>([\\S\\s]*?)<\/script>",JSONFilter:/^\/\*-secure-([\s\S]*)\*\/\s*$/,emptyFunction:function(){},K:function(a){return a}};if(Prototype.Browser.MobileSafari){Prototype.BrowserFeatures.SpecificElementExtensions=false}var Abstract={};var Try={these:function(){var c;for(var b=0,d=arguments.length;b<d;b++){var a=arguments[b];try{c=a();break}catch(f){}}return c}};var Class=(function(){function a(){}function b(){var g=null,f=$A(arguments);if(Object.isFunction(f[0])){g=f.shift()}function d(){this.initialize.apply(this,arguments)}Object.extend(d,Class.Methods);d.superclass=g;d.subclasses=[];if(g){a.prototype=g.prototype;d.prototype=new a;g.subclasses.push(d)}for(var e=0;e<f.length;e++){d.addMethods(f[e])}if(!d.prototype.initialize){d.prototype.initialize=Prototype.emptyFunction}d.prototype.constructor=d;return d}function c(k){var f=this.superclass&&this.superclass.prototype;var e=Object.keys(k);if(!Object.keys({toString:true}).length){if(k.toString!=Object.prototype.toString){e.push("toString")}if(k.valueOf!=Object.prototype.valueOf){e.push("valueOf")}}for(var d=0,g=e.length;d<g;d++){var j=e[d],h=k[j];if(f&&Object.isFunction(h)&&h.argumentNames().first()=="$super"){var l=h;h=(function(i){return function(){return f[i].apply(this,arguments)}})(j).wrap(l);h.valueOf=l.valueOf.bind(l);h.toString=l.toString.bind(l)}this.prototype[j]=h}return this}return{create:b,Methods:{addMethods:c}}})();(function(){var d=Object.prototype.toString;function i(q,s){for(var r in s){q[r]=s[r]}return q}function l(q){try{if(e(q)){return"undefined"}if(q===null){return"null"}return q.inspect?q.inspect():String(q)}catch(r){if(r instanceof RangeError){return"..."}throw r}}function k(q){var s=typeof q;switch(s){case"undefined":case"function":case"unknown":return;case"boolean":return q.toString()}if(q===null){return"null"}if(q.toJSON){return q.toJSON()}if(h(q)){return}var r=[];for(var u in q){var t=k(q[u]);if(!e(t)){r.push(u.toJSON()+": "+t)}}return"{"+r.join(", ")+"}"}function c(q){return $H(q).toQueryString()}function f(q){return q&&q.toHTML?q.toHTML():String.interpret(q)}function o(q){var r=[];for(var s in q){r.push(s)}return r}function m(q){var r=[];for(var s in q){r.push(q[s])}return r}function j(q){return i({},q)}function h(q){return !!(q&&q.nodeType==1)}function g(q){return d.call(q)=="[object Array]"}function p(q){return q instanceof Hash}function b(q){return typeof q==="function"}function a(q){return d.call(q)=="[object String]"}function n(q){return d.call(q)=="[object Number]"}function e(q){return typeof q==="undefined"}i(Object,{extend:i,inspect:l,toJSON:k,toQueryString:c,toHTML:f,keys:o,values:m,clone:j,isElement:h,isArray:g,isHash:p,isFunction:b,isString:a,isNumber:n,isUndefined:e})})();Object.extend(Function.prototype,(function(){var k=Array.prototype.slice;function d(o,l){var n=o.length,m=l.length;while(m--){o[n+m]=l[m]}return o}function i(m,l){m=k.call(m,0);return d(m,l)}function g(){var l=this.toString().match(/^[\s\(]*function[^(]*\(([^)]*)\)/)[1].replace(/\/\/.*?[\r\n]|\/\*(?:.|[\r\n])*?\*\ | dispatch: function(callback, request, transport, json) { this.each(function(responder) { if (Object.isFunction(responder[callback])) { try { responder[callback].apply(responder, [request, transport, json]); } catch (e) { } } }); } |
dispatchException: function(exception) { (this.options.onException || Prototype.emptyFunction)(this, exception); Ajax.Responders.dispatch('onException', this, exception); } | var Prototype={Version:"1.6.1",Browser:(function(){var b=navigator.userAgent;var a=Object.prototype.toString.call(window.opera)=="[object Opera]";return{IE:!!window.attachEvent&&!a,Opera:a,WebKit:b.indexOf("AppleWebKit/")>-1,Gecko:b.indexOf("Gecko")>-1&&b.indexOf("KHTML")===-1,MobileSafari:/Apple.*Mobile.*Safari/.test(b)}})(),BrowserFeatures:{XPath:!!document.evaluate,SelectorsAPI:!!document.querySelector,ElementExtensions:(function(){var a=window.Element||window.HTMLElement;return !!(a&&a.prototype)})(),SpecificElementExtensions:(function(){if(typeof window.HTMLDivElement!=="undefined"){return true}var c=document.createElement("div");var b=document.createElement("form");var a=false;if(c.__proto__&&(c.__proto__!==b.__proto__)){a=true}c=b=null;return a})()},ScriptFragment:"<script[^>]*>([\\S\\s]*?)<\/script>",JSONFilter:/^\/\*-secure-([\s\S]*)\*\/\s*$/,emptyFunction:function(){},K:function(a){return a}};if(Prototype.Browser.MobileSafari){Prototype.BrowserFeatures.SpecificElementExtensions=false}var Abstract={};var Try={these:function(){var c;for(var b=0,d=arguments.length;b<d;b++){var a=arguments[b];try{c=a();break}catch(f){}}return c}};var Class=(function(){function a(){}function b(){var g=null,f=$A(arguments);if(Object.isFunction(f[0])){g=f.shift()}function d(){this.initialize.apply(this,arguments)}Object.extend(d,Class.Methods);d.superclass=g;d.subclasses=[];if(g){a.prototype=g.prototype;d.prototype=new a;g.subclasses.push(d)}for(var e=0;e<f.length;e++){d.addMethods(f[e])}if(!d.prototype.initialize){d.prototype.initialize=Prototype.emptyFunction}d.prototype.constructor=d;return d}function c(k){var f=this.superclass&&this.superclass.prototype;var e=Object.keys(k);if(!Object.keys({toString:true}).length){if(k.toString!=Object.prototype.toString){e.push("toString")}if(k.valueOf!=Object.prototype.valueOf){e.push("valueOf")}}for(var d=0,g=e.length;d<g;d++){var j=e[d],h=k[j];if(f&&Object.isFunction(h)&&h.argumentNames().first()=="$super"){var l=h;h=(function(i){return function(){return f[i].apply(this,arguments)}})(j).wrap(l);h.valueOf=l.valueOf.bind(l);h.toString=l.toString.bind(l)}this.prototype[j]=h}return this}return{create:b,Methods:{addMethods:c}}})();(function(){var d=Object.prototype.toString;function i(q,s){for(var r in s){q[r]=s[r]}return q}function l(q){try{if(e(q)){return"undefined"}if(q===null){return"null"}return q.inspect?q.inspect():String(q)}catch(r){if(r instanceof RangeError){return"..."}throw r}}function k(q){var s=typeof q;switch(s){case"undefined":case"function":case"unknown":return;case"boolean":return q.toString()}if(q===null){return"null"}if(q.toJSON){return q.toJSON()}if(h(q)){return}var r=[];for(var u in q){var t=k(q[u]);if(!e(t)){r.push(u.toJSON()+": "+t)}}return"{"+r.join(", ")+"}"}function c(q){return $H(q).toQueryString()}function f(q){return q&&q.toHTML?q.toHTML():String.interpret(q)}function o(q){var r=[];for(var s in q){r.push(s)}return r}function m(q){var r=[];for(var s in q){r.push(q[s])}return r}function j(q){return i({},q)}function h(q){return !!(q&&q.nodeType==1)}function g(q){return d.call(q)=="[object Array]"}function p(q){return q instanceof Hash}function b(q){return typeof q==="function"}function a(q){return d.call(q)=="[object String]"}function n(q){return d.call(q)=="[object Number]"}function e(q){return typeof q==="undefined"}i(Object,{extend:i,inspect:l,toJSON:k,toQueryString:c,toHTML:f,keys:o,values:m,clone:j,isElement:h,isArray:g,isHash:p,isFunction:b,isString:a,isNumber:n,isUndefined:e})})();Object.extend(Function.prototype,(function(){var k=Array.prototype.slice;function d(o,l){var n=o.length,m=l.length;while(m--){o[n+m]=l[m]}return o}function i(m,l){m=k.call(m,0);return d(m,l)}function g(){var l=this.toString().match(/^[\s\(]*function[^(]*\(([^)]*)\)/)[1].replace(/\/\/.*?[\r\n]|\/\*(?:.|[\r\n])*?\*\ | dispatchException: function(exception) { (this.options.onException || Prototype.emptyFunction)(this, exception); Ajax.Responders.dispatch('onException', this, exception); } |
? (modes.getStack(2).main.display() || modes.getStack(2).mainMode.name) + " (next)" | ? (modes.getStack(2).main.display() || modes.getStack(2).main.name) + " (next)" | display: function () modes.getStack(1).main == modes.PASS_THROUGH ? (modes.getStack(2).main.display() || modes.getStack(2).mainMode.name) + " (next)" : "PASS THROUGH (next)" }, { |
display: function () modes.getStack(1).main == modes.PASS_THROUGH ? (modes.getStack(2).main.display() || modes.getStack(2).mainMode.name) + " (next)" : "PASS THROUGH (next)" }, { | display: function () this.disp, | display: function () modes.getStack(1).main == modes.PASS_THROUGH ? (modes.getStack(2).main.display() || modes.getStack(2).mainMode.name) + " (next)" : "PASS THROUGH (next)" }, { |
return this.displayItemIndexForPosition(evt.pageX, evt.pageY); | if (this.renderer) return this.renderer.indexForEvent(evt); | displayItemIndexForEvent: function(evt) { return this.displayItemIndexForPosition(evt.pageX, evt.pageY); }, |
r = segment.getBoundingClientRect(); | if (segment.getBoundingClientRect) { r = segment.getBoundingClientRect(); }else{ r = {}; var ret = SC.viewportOffset(segment); var cq = SC.$(segment); r.top = ret.y; r.left = ret.x; r.bottom = ret.y + cq.outerHeight(); r.right = ret.x + cq.outerWidth(); } | displayItemIndexForPosition: function(pageX, pageY) { // find the segments var segments = this.$('.sc-segment'), len = segments.length, idx, segment, r; // loop through them (yes, this comment is mostly because it looks nice in TextMate) for (idx = 0; idx < len; idx++) { // get the segment segment = segments[idx]; // get its rectangle r = segment.getBoundingClientRect(); // based on orientation, check the position left-to-right or up-to-down. if (this.get('layoutDirection') == SC.LAYOUT_VERTICAL) { // if it fits, return it right away if (pageY > r.top && pageY < r.bottom) return idx; } else { // if it fits, return it right away. if (pageX > r.left && pageX < r.right) return idx; } } // if we didn't find anything, return the old standard -1 for "not found." return -1; }, |
cur = [item.humanize().titleize(), item, YES, null, null, null, idx] ; | cur = { title: item.humanize().titleize(), value: item, isEnabled: YES, icon: null, width: null, toolTip: null, index: idx }; | displayItems: function() { var items = this.get('items'), loc = this.get('localize'), keys=null, itemType, cur, ret = [], max = items.get('length'), idx, item, fetchKeys = SC._segmented_fetchKeys, fetchItem = SC._segmented_fetchItem; // loop through items and collect data for(idx=0;idx<max;idx++) { item = items.objectAt(idx) ; if (SC.none(item)) continue; //skip is null or undefined // if the item is a string, build the array using defaults... itemType = SC.typeOf(item); if (itemType === SC.T_STRING) { cur = [item.humanize().titleize(), item, YES, null, null, null, idx] ; // if the item is not an array, try to use the itemKeys. } else if (itemType !== SC.T_ARRAY) { // get the itemKeys the first time if (keys===null) { keys = this.itemKeys.map(fetchKeys,this); } // now loop through the keys and try to get the values on the item cur = keys.map(fetchItem, item); cur[cur.length] = idx; // save current index // special case 1...if title key is null, try to make into string if (!keys[0] && item.toString) cur[0] = item.toString(); // special case 2...if value key is null, use item itself if (!keys[1]) cur[1] = item; // special case 3...if isEnabled is null, default to yes. if (!keys[2]) cur[2] = YES ; } // finally, be sure to loc the title if needed if (loc && cur[0]) cur[0] = cur[0].loc(); // finally, be sure to loc the toolTip if needed if (loc && cur[5] && SC.typeOf(cur[5]) === SC.T_STRING) cur[5] = cur[5].loc(); // add to return array ret[ret.length] = cur; } // all done, return! return ret ; }.property('items', 'itemTitleKey', 'itemValueKey', 'itemIsEnabledKey', 'localize', 'itemIconKey', 'itemWidthKey', 'itemToolTipKey'), |
cur[cur.length] = idx; | cur = { title: cur[0], value: cur[1], isEnabled: cur[2], icon: cur[3], width: cur[4], toolTip: cur[5], index: idx }; | displayItems: function() { var items = this.get('items'), loc = this.get('localize'), keys=null, itemType, cur, ret = [], max = items.get('length'), idx, item, fetchKeys = SC._segmented_fetchKeys, fetchItem = SC._segmented_fetchItem; // loop through items and collect data for(idx=0;idx<max;idx++) { item = items.objectAt(idx) ; if (SC.none(item)) continue; //skip is null or undefined // if the item is a string, build the array using defaults... itemType = SC.typeOf(item); if (itemType === SC.T_STRING) { cur = [item.humanize().titleize(), item, YES, null, null, null, idx] ; // if the item is not an array, try to use the itemKeys. } else if (itemType !== SC.T_ARRAY) { // get the itemKeys the first time if (keys===null) { keys = this.itemKeys.map(fetchKeys,this); } // now loop through the keys and try to get the values on the item cur = keys.map(fetchItem, item); cur[cur.length] = idx; // save current index // special case 1...if title key is null, try to make into string if (!keys[0] && item.toString) cur[0] = item.toString(); // special case 2...if value key is null, use item itself if (!keys[1]) cur[1] = item; // special case 3...if isEnabled is null, default to yes. if (!keys[2]) cur[2] = YES ; } // finally, be sure to loc the title if needed if (loc && cur[0]) cur[0] = cur[0].loc(); // finally, be sure to loc the toolTip if needed if (loc && cur[5] && SC.typeOf(cur[5]) === SC.T_STRING) cur[5] = cur[5].loc(); // add to return array ret[ret.length] = cur; } // all done, return! return ret ; }.property('items', 'itemTitleKey', 'itemValueKey', 'itemIsEnabledKey', 'localize', 'itemIconKey', 'itemWidthKey', 'itemToolTipKey'), |
if (!keys[0] && item.toString) cur[0] = item.toString(); | if (!keys[0] && item.toString) cur.title = item.toString(); | displayItems: function() { var items = this.get('items'), loc = this.get('localize'), keys=null, itemType, cur, ret = [], max = items.get('length'), idx, item, fetchKeys = SC._segmented_fetchKeys, fetchItem = SC._segmented_fetchItem; // loop through items and collect data for(idx=0;idx<max;idx++) { item = items.objectAt(idx) ; if (SC.none(item)) continue; //skip is null or undefined // if the item is a string, build the array using defaults... itemType = SC.typeOf(item); if (itemType === SC.T_STRING) { cur = [item.humanize().titleize(), item, YES, null, null, null, idx] ; // if the item is not an array, try to use the itemKeys. } else if (itemType !== SC.T_ARRAY) { // get the itemKeys the first time if (keys===null) { keys = this.itemKeys.map(fetchKeys,this); } // now loop through the keys and try to get the values on the item cur = keys.map(fetchItem, item); cur[cur.length] = idx; // save current index // special case 1...if title key is null, try to make into string if (!keys[0] && item.toString) cur[0] = item.toString(); // special case 2...if value key is null, use item itself if (!keys[1]) cur[1] = item; // special case 3...if isEnabled is null, default to yes. if (!keys[2]) cur[2] = YES ; } // finally, be sure to loc the title if needed if (loc && cur[0]) cur[0] = cur[0].loc(); // finally, be sure to loc the toolTip if needed if (loc && cur[5] && SC.typeOf(cur[5]) === SC.T_STRING) cur[5] = cur[5].loc(); // add to return array ret[ret.length] = cur; } // all done, return! return ret ; }.property('items', 'itemTitleKey', 'itemValueKey', 'itemIsEnabledKey', 'localize', 'itemIconKey', 'itemWidthKey', 'itemToolTipKey'), |
if (!keys[1]) cur[1] = item; | if (!keys[1]) cur.value = item; | displayItems: function() { var items = this.get('items'), loc = this.get('localize'), keys=null, itemType, cur, ret = [], max = items.get('length'), idx, item, fetchKeys = SC._segmented_fetchKeys, fetchItem = SC._segmented_fetchItem; // loop through items and collect data for(idx=0;idx<max;idx++) { item = items.objectAt(idx) ; if (SC.none(item)) continue; //skip is null or undefined // if the item is a string, build the array using defaults... itemType = SC.typeOf(item); if (itemType === SC.T_STRING) { cur = [item.humanize().titleize(), item, YES, null, null, null, idx] ; // if the item is not an array, try to use the itemKeys. } else if (itemType !== SC.T_ARRAY) { // get the itemKeys the first time if (keys===null) { keys = this.itemKeys.map(fetchKeys,this); } // now loop through the keys and try to get the values on the item cur = keys.map(fetchItem, item); cur[cur.length] = idx; // save current index // special case 1...if title key is null, try to make into string if (!keys[0] && item.toString) cur[0] = item.toString(); // special case 2...if value key is null, use item itself if (!keys[1]) cur[1] = item; // special case 3...if isEnabled is null, default to yes. if (!keys[2]) cur[2] = YES ; } // finally, be sure to loc the title if needed if (loc && cur[0]) cur[0] = cur[0].loc(); // finally, be sure to loc the toolTip if needed if (loc && cur[5] && SC.typeOf(cur[5]) === SC.T_STRING) cur[5] = cur[5].loc(); // add to return array ret[ret.length] = cur; } // all done, return! return ret ; }.property('items', 'itemTitleKey', 'itemValueKey', 'itemIsEnabledKey', 'localize', 'itemIconKey', 'itemWidthKey', 'itemToolTipKey'), |
if (!keys[2]) cur[2] = YES ; | if (!keys[2]) cur.isEnabled = YES ; | displayItems: function() { var items = this.get('items'), loc = this.get('localize'), keys=null, itemType, cur, ret = [], max = items.get('length'), idx, item, fetchKeys = SC._segmented_fetchKeys, fetchItem = SC._segmented_fetchItem; // loop through items and collect data for(idx=0;idx<max;idx++) { item = items.objectAt(idx) ; if (SC.none(item)) continue; //skip is null or undefined // if the item is a string, build the array using defaults... itemType = SC.typeOf(item); if (itemType === SC.T_STRING) { cur = [item.humanize().titleize(), item, YES, null, null, null, idx] ; // if the item is not an array, try to use the itemKeys. } else if (itemType !== SC.T_ARRAY) { // get the itemKeys the first time if (keys===null) { keys = this.itemKeys.map(fetchKeys,this); } // now loop through the keys and try to get the values on the item cur = keys.map(fetchItem, item); cur[cur.length] = idx; // save current index // special case 1...if title key is null, try to make into string if (!keys[0] && item.toString) cur[0] = item.toString(); // special case 2...if value key is null, use item itself if (!keys[1]) cur[1] = item; // special case 3...if isEnabled is null, default to yes. if (!keys[2]) cur[2] = YES ; } // finally, be sure to loc the title if needed if (loc && cur[0]) cur[0] = cur[0].loc(); // finally, be sure to loc the toolTip if needed if (loc && cur[5] && SC.typeOf(cur[5]) === SC.T_STRING) cur[5] = cur[5].loc(); // add to return array ret[ret.length] = cur; } // all done, return! return ret ; }.property('items', 'itemTitleKey', 'itemValueKey', 'itemIsEnabledKey', 'localize', 'itemIconKey', 'itemWidthKey', 'itemToolTipKey'), |
if (loc && cur[0]) cur[0] = cur[0].loc(); | if (loc && cur.title) cur.title = cur.title.loc(); | displayItems: function() { var items = this.get('items'), loc = this.get('localize'), keys=null, itemType, cur, ret = [], max = items.get('length'), idx, item, fetchKeys = SC._segmented_fetchKeys, fetchItem = SC._segmented_fetchItem; // loop through items and collect data for(idx=0;idx<max;idx++) { item = items.objectAt(idx) ; if (SC.none(item)) continue; //skip is null or undefined // if the item is a string, build the array using defaults... itemType = SC.typeOf(item); if (itemType === SC.T_STRING) { cur = [item.humanize().titleize(), item, YES, null, null, null, idx] ; // if the item is not an array, try to use the itemKeys. } else if (itemType !== SC.T_ARRAY) { // get the itemKeys the first time if (keys===null) { keys = this.itemKeys.map(fetchKeys,this); } // now loop through the keys and try to get the values on the item cur = keys.map(fetchItem, item); cur[cur.length] = idx; // save current index // special case 1...if title key is null, try to make into string if (!keys[0] && item.toString) cur[0] = item.toString(); // special case 2...if value key is null, use item itself if (!keys[1]) cur[1] = item; // special case 3...if isEnabled is null, default to yes. if (!keys[2]) cur[2] = YES ; } // finally, be sure to loc the title if needed if (loc && cur[0]) cur[0] = cur[0].loc(); // finally, be sure to loc the toolTip if needed if (loc && cur[5] && SC.typeOf(cur[5]) === SC.T_STRING) cur[5] = cur[5].loc(); // add to return array ret[ret.length] = cur; } // all done, return! return ret ; }.property('items', 'itemTitleKey', 'itemValueKey', 'itemIsEnabledKey', 'localize', 'itemIconKey', 'itemWidthKey', 'itemToolTipKey'), |
if (loc && cur[5] && SC.typeOf(cur[5]) === SC.T_STRING) cur[5] = cur[5].loc(); | if (loc && cur.toolTip && SC.typeOf(cur.toolTip) === SC.T_STRING) cur.toolTip = cur.toolTip.loc(); | displayItems: function() { var items = this.get('items'), loc = this.get('localize'), keys=null, itemType, cur, ret = [], max = items.get('length'), idx, item, fetchKeys = SC._segmented_fetchKeys, fetchItem = SC._segmented_fetchItem; // loop through items and collect data for(idx=0;idx<max;idx++) { item = items.objectAt(idx) ; if (SC.none(item)) continue; //skip is null or undefined // if the item is a string, build the array using defaults... itemType = SC.typeOf(item); if (itemType === SC.T_STRING) { cur = [item.humanize().titleize(), item, YES, null, null, null, idx] ; // if the item is not an array, try to use the itemKeys. } else if (itemType !== SC.T_ARRAY) { // get the itemKeys the first time if (keys===null) { keys = this.itemKeys.map(fetchKeys,this); } // now loop through the keys and try to get the values on the item cur = keys.map(fetchItem, item); cur[cur.length] = idx; // save current index // special case 1...if title key is null, try to make into string if (!keys[0] && item.toString) cur[0] = item.toString(); // special case 2...if value key is null, use item itself if (!keys[1]) cur[1] = item; // special case 3...if isEnabled is null, default to yes. if (!keys[2]) cur[2] = YES ; } // finally, be sure to loc the title if needed if (loc && cur[0]) cur[0] = cur[0].loc(); // finally, be sure to loc the toolTip if needed if (loc && cur[5] && SC.typeOf(cur[5]) === SC.T_STRING) cur[5] = cur[5].loc(); // add to return array ret[ret.length] = cur; } // all done, return! return ret ; }.property('items', 'itemTitleKey', 'itemValueKey', 'itemIsEnabledKey', 'localize', 'itemIconKey', 'itemWidthKey', 'itemToolTipKey'), |
item, fetchKeys = SC._segmented_fetchKeys, fetchItem = SC._segmented_fetchItem; | item, fetchKeys = SC._segmented_fetchKeys, fetchItem = SC._segmented_fetchItem, overflowItems; | displayItems: function() { var items = this.get('items'), loc = this.get('localize'), keys=null, itemType, cur, ret = [], max = items.get('length'), idx, item, fetchKeys = SC._segmented_fetchKeys, fetchItem = SC._segmented_fetchItem; // loop through items and collect data for(idx=0;idx<max;idx++) { item = items.objectAt(idx) ; if (SC.none(item)) continue; //skip is null or undefined // if the item is a string, build the array using defaults... itemType = SC.typeOf(item); if (itemType === SC.T_STRING) { cur = { title: item.humanize().titleize(), value: item, isEnabled: YES, icon: null, width: null, toolTip: null, index: idx }; // cur = [item.humanize().titleize(), item, YES, null, null, null, idx] ; // if the item is not an array, try to use the itemKeys. } else if (itemType !== SC.T_ARRAY) { // get the itemKeys the first time if (keys===null) { keys = this.itemKeys.map(fetchKeys,this); } // now loop through the keys and try to get the values on the item cur = keys.map(fetchItem, item); // create the actual item cur = { title: cur[0], value: cur[1], isEnabled: cur[2], icon: cur[3], width: cur[4], toolTip: cur[5], index: idx }; // special case 1...if title key is null, try to make into string if (!keys[0] && item.toString) cur.title = item.toString(); // special case 2...if value key is null, use item itself if (!keys[1]) cur.value = item; // special case 3...if isEnabled is null, default to yes. if (!keys[2]) cur.isEnabled = YES ; } // finally, be sure to loc the title if needed if (loc && cur.title) cur.title = cur.title.loc(); // finally, be sure to loc the toolTip if needed if (loc && cur.toolTip && SC.typeOf(cur.toolTip) === SC.T_STRING) cur.toolTip = cur.toolTip.loc(); // add to return array ret[ret.length] = cur; } // all done, return! return ret ; }.property('items', 'itemTitleKey', 'itemValueKey', 'itemIsEnabledKey', 'localize', 'itemIconKey', 'itemWidthKey', 'itemToolTipKey'), |
ret[ret.length] = cur; | if (this.overflowIndex <= idx) { if (overflowItems.length === 0) { ret[ret.length] = {width: null, isOverflowSegment: YES}; } overflowItems[overflowItems.length] = cur; } else { ret[ret.length] = cur; } | displayItems: function() { var items = this.get('items'), loc = this.get('localize'), keys=null, itemType, cur, ret = [], max = items.get('length'), idx, item, fetchKeys = SC._segmented_fetchKeys, fetchItem = SC._segmented_fetchItem; // loop through items and collect data for(idx=0;idx<max;idx++) { item = items.objectAt(idx) ; if (SC.none(item)) continue; //skip is null or undefined // if the item is a string, build the array using defaults... itemType = SC.typeOf(item); if (itemType === SC.T_STRING) { cur = { title: item.humanize().titleize(), value: item, isEnabled: YES, icon: null, width: null, toolTip: null, index: idx }; // cur = [item.humanize().titleize(), item, YES, null, null, null, idx] ; // if the item is not an array, try to use the itemKeys. } else if (itemType !== SC.T_ARRAY) { // get the itemKeys the first time if (keys===null) { keys = this.itemKeys.map(fetchKeys,this); } // now loop through the keys and try to get the values on the item cur = keys.map(fetchItem, item); // create the actual item cur = { title: cur[0], value: cur[1], isEnabled: cur[2], icon: cur[3], width: cur[4], toolTip: cur[5], index: idx }; // special case 1...if title key is null, try to make into string if (!keys[0] && item.toString) cur.title = item.toString(); // special case 2...if value key is null, use item itself if (!keys[1]) cur.value = item; // special case 3...if isEnabled is null, default to yes. if (!keys[2]) cur.isEnabled = YES ; } // finally, be sure to loc the title if needed if (loc && cur.title) cur.title = cur.title.loc(); // finally, be sure to loc the toolTip if needed if (loc && cur.toolTip && SC.typeOf(cur.toolTip) === SC.T_STRING) cur.toolTip = cur.toolTip.loc(); // add to return array ret[ret.length] = cur; } // all done, return! return ret ; }.property('items', 'itemTitleKey', 'itemValueKey', 'itemIsEnabledKey', 'localize', 'itemIconKey', 'itemWidthKey', 'itemToolTipKey'), |
if (!this.overflowSegmentWidth) { ret[ret.length] = {width: null, isOverflowSegment: YES}; } | displayItems: function() { var items = this.get('items'), loc = this.get('localize'), keys=null, itemType, cur, ret = [], max = items.get('length'), idx, item, fetchKeys = SC._segmented_fetchKeys, fetchItem = SC._segmented_fetchItem; // loop through items and collect data for(idx=0;idx<max;idx++) { item = items.objectAt(idx) ; if (SC.none(item)) continue; //skip is null or undefined // if the item is a string, build the array using defaults... itemType = SC.typeOf(item); if (itemType === SC.T_STRING) { cur = { title: item.humanize().titleize(), value: item, isEnabled: YES, icon: null, width: null, toolTip: null, index: idx }; // cur = [item.humanize().titleize(), item, YES, null, null, null, idx] ; // if the item is not an array, try to use the itemKeys. } else if (itemType !== SC.T_ARRAY) { // get the itemKeys the first time if (keys===null) { keys = this.itemKeys.map(fetchKeys,this); } // now loop through the keys and try to get the values on the item cur = keys.map(fetchItem, item); // create the actual item cur = { title: cur[0], value: cur[1], isEnabled: cur[2], icon: cur[3], width: cur[4], toolTip: cur[5], index: idx }; // special case 1...if title key is null, try to make into string if (!keys[0] && item.toString) cur.title = item.toString(); // special case 2...if value key is null, use item itself if (!keys[1]) cur.value = item; // special case 3...if isEnabled is null, default to yes. if (!keys[2]) cur.isEnabled = YES ; } // finally, be sure to loc the title if needed if (loc && cur.title) cur.title = cur.title.loc(); // finally, be sure to loc the toolTip if needed if (loc && cur.toolTip && SC.typeOf(cur.toolTip) === SC.T_STRING) cur.toolTip = cur.toolTip.loc(); // add to return array ret[ret.length] = cur; } // all done, return! return ret ; }.property('items', 'itemTitleKey', 'itemValueKey', 'itemIsEnabledKey', 'localize', 'itemIconKey', 'itemWidthKey', 'itemToolTipKey'), |
|
}.property('items', 'itemTitleKey', 'itemValueKey', 'itemIsEnabledKey', 'localize', 'itemIconKey', 'itemWidthKey', 'itemToolTipKey'), | }.property('items', 'itemTitleKey', 'itemValueKey', 'itemIsEnabledKey', 'localize', 'itemIconKey', 'itemWidthKey', 'itemToolTipKey').cacheable(), | displayItems: function() { var items = this.get('items'), loc = this.get('localize'), keys=null, itemType, cur, ret = [], max = items.get('length'), idx, item, fetchKeys = SC._segmented_fetchKeys, fetchItem = SC._segmented_fetchItem; // loop through items and collect data for(idx=0;idx<max;idx++) { item = items.objectAt(idx) ; if (SC.none(item)) continue; //skip is null or undefined // if the item is a string, build the array using defaults... itemType = SC.typeOf(item); if (itemType === SC.T_STRING) { cur = { title: item.humanize().titleize(), value: item, isEnabled: YES, icon: null, width: null, toolTip: null, index: idx }; // cur = [item.humanize().titleize(), item, YES, null, null, null, idx] ; // if the item is not an array, try to use the itemKeys. } else if (itemType !== SC.T_ARRAY) { // get the itemKeys the first time if (keys===null) { keys = this.itemKeys.map(fetchKeys,this); } // now loop through the keys and try to get the values on the item cur = keys.map(fetchItem, item); // create the actual item cur = { title: cur[0], value: cur[1], isEnabled: cur[2], icon: cur[3], width: cur[4], toolTip: cur[5], index: idx }; // special case 1...if title key is null, try to make into string if (!keys[0] && item.toString) cur.title = item.toString(); // special case 2...if value key is null, use item itself if (!keys[1]) cur.value = item; // special case 3...if isEnabled is null, default to yes. if (!keys[2]) cur.isEnabled = YES ; } // finally, be sure to loc the title if needed if (loc && cur.title) cur.title = cur.title.loc(); // finally, be sure to loc the toolTip if needed if (loc && cur.toolTip && SC.typeOf(cur.toolTip) === SC.T_STRING) cur.toolTip = cur.toolTip.loc(); // add to return array ret[ret.length] = cur; } // all done, return! return ret ; }.property('items', 'itemTitleKey', 'itemValueKey', 'itemIsEnabledKey', 'localize', 'itemIconKey', 'itemWidthKey', 'itemToolTipKey'), |
document.title = $(stanza).attr('from').split("/")[0]; | if ($(stanza).attr('from')) { document.title = $(stanza).attr('from').split("/")[0]; } | displayMessage: function(user,srcurl,stanza,current_user) { var stamp = null; //search for an existing time stamp in the message $(stanza).find("x").each(function () { if($(this).attr('stamp')) { stamp = $(this).attr('stamp'); } }); var time = ""; var year = ""; var month = ""; var day = ""; var hour = ""; var minute = ""; var second = ""; if (stamp) { ymdhms = stamp.split("T"); year = ymdhms[0].substr(0,4); month = ymdhms[0].substr(4,2); day = ymdhms[0].substr(6,2); timearray = [year, "/", month, "/", day, " - ", ymdhms[1], " UTC"]; hms = ymdhms[1].split(':'); hour = hms[0]; minute = hms[1]; second = hms[2]; time = timearray.join(""); } else { /*Create current time if time stamp is not sent in the stanza.*/ date = new Date(); year = date.getUTCFullYear(); month = Speeqe.zeroPad(date.getUTCMonth() + 1,2); day = Speeqe.zeroPad(date.getUTCDate(),2); hour = Speeqe.zeroPad(date.getUTCHours(),2); minute = Speeqe.zeroPad(date.getUTCMinutes(),2); second = Speeqe.zeroPad(date.getUTCSeconds(),2); var Y = ""+year; var M = "/"+ month; var D = "/"+day; var h = ""+hour; var m = ""+minute; var s = ""+second; time = Y + M + D + " - " + h + ":" + m + ":" + s + " UTC"; } var cleannick = user.replace("@","at"); cleannick = cleannick.replace(new RegExp(".","g"),"dot"); //remove domain if (Speeqe.XMPP_DOMAIN !== null) { user = user.replace("@"+Speeqe.XMPP_DOMAIN,""); } //First search for an html based message and use it. var message = $(stanza).find("html").find("body").text(); var me_style = message.match(/^\/me.+\S+/); var private_message = $(stanza).attr("type") != "groupchat"; if (message.length == 0) { //if html based message isn't found use the regular body text message = $(stanza).find("body").text(); me_style = message.match(/^\/me.+\S+/); /*Used to display when the user sends a private message.*/ if(private_message && message.length == 0) { message = jQuery.trim($(stanza).text()); } if (!Speeqe.testSupportedTags(message)) { message = this.translateMessage(message,true); } else { //strip unsafe attributes from tags var elem = $(message); elem = this._handleSupportedTags(elem); message = elem; } } else { message = this.translateMessage(message,true); } message = jQuery.trim(message); if(message.length > 0) { var post_clone = $("#chatpane_post").clone(); post_clone.removeAttr("id"); post_clone.find("img").attr("class","avatar"+cleannick); post_clone.find("img").attr("src",srcurl); post_clone.find("img").attr("alt",user); post_clone.find("#message_time_stamp").text(time); post_clone.find("#message_time_stamp").removeAttr("id"); //break up username into user and domain var userdomainname = user.split('@'); var username = userdomainname[0]; var userdomain = userdomainname[1]; //break down date if wanted and user , domain var message_ids = {'#message_time_year':year, '#message_time_month':month, '#message_time_day':day, '#message_time_hour':hour, '#message_time_minute':minute, '#message_time_second':second, '#message_user_name':username, '#message_user_domain':userdomain }; jQuery.each(message_ids, function(i,val) { var ms = post_clone.find(i); if(ms.length > 0) { ms.text(val); ms.removeAttr("id"); } }); post_clone.find("#message_username").text(user); if(private_message == true) { post_clone.addClass("private_message"); } else { post_clone.removeClass("private_message"); } post_clone.find("#messagepost").html(message); post_clone.find("#messagepost").removeAttr("id"); if(current_user == true) { post_clone.addClass("current_user"); } else { post_clone.removeClass("current_user"); } if(me_style) { post_clone.addClass("me_command"); } else { post_clone.removeClass("me_command"); } var chatwindow = $("#chatWindow_chatpane"); Speeqe.scaleImage(post_clone); if (chatwindow.hasClass('direction-up')) { var scrollit = true; //use chat window to scroll unless it has the default overflow var scroll_elements = chatwindow; if(chatwindow.css('overflow') == 'visible') { scroll_elements = $('html,body'); } scroll_elements.each(function(i,elem) { if((elem.scrollTop+elem.clientHeight) < elem.scrollHeight) { if(elem.scrollTop !== 0) { scrollit = false; } } }); var inline_obj = post_clone.find('.autoinline'); var msg_view = this; inline_obj.load( function() { //scroll after inline object loads if(scrollit) { msg_view.scrollTop(); } }); chatwindow.append(post_clone.get(0)); if(scrollit) { this.scrollTop(); } } else { chatwindow.prepend(post_clone.get(0)); } } if(! app.winFocus) { //if this window is out of focus attach a notification of //new messages document.title = "** " + $(stanza).attr('from').split("/")[0]; } else { document.title = $(stanza).attr('from').split("/")[0]; } /*if window has grown too large chop off the last message.*/ var chatWindow_divs = $("#chatWindow_chatpane > div"); var chatwindow = $("#chatWindow_chatpane"); if( chatWindow_divs.length > MAX_SCROLL_SIZE ) { var msg_index = chatWindow_divs.length - 2; if (chatwindow.hasClass('direction-up')) { msg_index = 1; } var lastelem = chatWindow_divs.get(msg_index); $(lastelem).remove(); } }, |
if (aColorCode == PAGESPEED.Utils.SCORE_CODE_RED) { if (a.experimental != b.experimental) { return a.experimental ? 1 : -1; } } | PAGESPEED.PageSpeedContext.prototype.displayPerformance = function( panel, browserTab) { // The rules array holds the rule objects used to fill the domplate. var rules = []; var totalScore = 0; var totalWeight = 0; var lintRules = PAGESPEED.LintRules.lintRules.concat( PAGESPEED.LintRules.nativeRuleResults); /** * Sorts rules by their name. */ var sortByName = function(a, b) { if (a.name == b.name) { return 0; } return a.name > b.name ? 1 : -1; }; /** * Sorts rules by their color code and/or score. */ var sortByScore = function(a, b) { var aColorCode = PAGESPEED.Utils.getColorCode(a); var bColorCode = PAGESPEED.Utils.getColorCode(b); if (aColorCode != bColorCode) { return aColorCode - bColorCode; } // Past this point, the color codes are the same. var aDetails = !!((a.warnings || '') + (a.information || '')); var bDetails = !!((b.warnings || '') + (b.information || '')); if (aDetails != bDetails) { return aDetails ? -1 : 1; } if (aColorCode == 4) { // Non-scoring (informational) color code. sort by score if both // scores are strings. var aIsString = (typeof a.score == 'string'); var bIsString = (typeof b.score == 'string'); if (aIsString && bIsString) { // If both are strings, then perform a lexical sort. if (a.score == b.score) { return sortByName(a, b); } return (a.score > b.score) ? 1 : -1; } return aIsString ? 1 : -1; } if (b.weight == a.weight) { return sortByName(a, b); } return b.weight - a.weight; }; lintRules.sort(sortByScore); // Keep track of the number of each score code that we encounter. var scoreCodeCounts = {}; scoreCodeCounts[PAGESPEED.Utils.SCORE_CODE_RED] = 0; scoreCodeCounts[PAGESPEED.Utils.SCORE_CODE_YELLOW] = 0; scoreCodeCounts[PAGESPEED.Utils.SCORE_CODE_GREEN] = 0; scoreCodeCounts[PAGESPEED.Utils.SCORE_CODE_INFO] = 0; for (var i = 0, len = lintRules.length; i < len; i++) { // Always display the rule if it is a scoring rule. If its a non-scoring // rule display it only if it detected a violation. if (lintRules[i].weight || (!lintRules[i].weight && lintRules[i].score != 'n/a' && lintRules[i].score != 100)) { // If its a non-scoring rule, clear the score so it doesn't display. if (lintRules[i].weight === 0) { lintRules[i].score = 'unscored'; } var colorCode = PAGESPEED.Utils.getColorCode(lintRules[i]); if (colorCode == PAGESPEED.Utils.SCORE_CODE_INFO && !lintRules[i].information) { lintRules[i].information = 'This suggestion does not apply to the current page.'; } scoreCodeCounts[colorCode]++; rules.push(panel.createRuleTagDomplateData(lintRules[i])); if (!isNaN(lintRules[i].score) && !isNaN(lintRules[i].weight)) { totalScore += lintRules[i].score * lintRules[i].weight; totalWeight += lintRules[i].weight; } } } var overallScore = Math.round(totalWeight ? totalScore / totalWeight : 0); var SCORE_CODE_THRESHOLD_ = 4; // Determine an overall color code based on the score code counts. var overallScoreColorCode = PAGESPEED.Utils.SCORE_CODE_INFO; if (scoreCodeCounts[PAGESPEED.Utils.SCORE_CODE_RED] >= SCORE_CODE_THRESHOLD_) { // There are enough 'red' codes that we give an overall score of // 'red'. overallScoreColorCode = PAGESPEED.Utils.SCORE_CODE_RED; } else if (scoreCodeCounts[PAGESPEED.Utils.SCORE_CODE_RED] > 0 || scoreCodeCounts[PAGESPEED.Utils.SCORE_CODE_YELLOW] >= SCORE_CODE_THRESHOLD_) { // There are enough 'red' or 'yellow' codes that we give an // overall score of 'yellow'. overallScoreColorCode = PAGESPEED.Utils.SCORE_CODE_YELLOW; } else if (scoreCodeCounts[PAGESPEED.Utils.SCORE_CODE_GREEN] > 0) { // If at least one rule scores green, give an overall score of // green. overallScoreColorCode = PAGESPEED.Utils.SCORE_CODE_GREEN; } panel.table = panel.tableTag.replace( panel.createTableTagDomplateData(overallScoreColorCode, overallScore), panel.panelNode, panel); var tbody = panel.table.firstChild; var lastRow = tbody.lastChild; var row = panel.ruleTag.insertRows({'rules': rules}, lastRow)[0]; for (var i = 0; i < rules.length; ++i) { row.repObject = rules[i]; rules[i].row = row; row = row.nextSibling; } return overallScore;} |
|
displaySelectedItem: function() { var menuView, currSel, itemViews, title, val, itemIdx = 0, button, object, len, found = null, objTmp; menuView = this.parentMenu() ; currSel = menuView.get('currentSelectedMenuItem') ; itemViews = menuView.menuItemViews ; if (currSel && itemViews) { itemIdx = itemViews.indexOf(currSel) ; } button = menuView.get('anchor') ; object = menuView.get('items') ; len = object.length ; while (!found && (--len >= 0)) { objTmp = object[len]; title = !SC.none(objTmp.title) ? objTmp.title: object.toString() ; val = !SC.none(objTmp.value) ? objTmp.value: title ; if (title === this.get('value') && (itemIdx === len)) { found = object ; button.set('value', val) ; button.set('title', title) ; } } button.set('icon', this.get('icon')).set('_currentSelItem', currSel). set('_itemIdx', itemIdx) ; | displaySelectedItem: function(menuView) { var currentItem = menuView.get("selectedItem"); this.set("value", currentItem.get("value")); this.set("title", currentItem.get("title")); this.set("_itemIdx", currentItem.get("contentIndex")); | displaySelectedItem: function() { var menuView, currSel, itemViews, title, val, itemIdx = 0, button, object, len, found = null, objTmp; //Get MenuPane, currentSelectedMenuItem & menuItemView // Get the main parent view to show the menus menuView = this.parentMenu() ; currSel = menuView.get('currentSelectedMenuItem') ; itemViews = menuView.menuItemViews ; // Fetch the index of the current selected item if (currSel && itemViews) { itemIdx = itemViews.indexOf(currSel) ; } // Get the select button View button = menuView.get('anchor') ; // set the value and title object = menuView.get('items') ; len = object.length ; while (!found && (--len >= 0)) { objTmp = object[len]; title = !SC.none(objTmp.title) ? objTmp.title: object.toString() ; val = !SC.none(objTmp.value) ? objTmp.value: title ; if (title === this.get('value') && (itemIdx === len)) { found = object ; button.set('value', val) ; button.set('title', title) ; } } // set the icon, currentSelectedItem and itemIdx button.set('icon', this.get('icon')).set('_currentSelItem', currSel). set('_itemIdx', itemIdx) ; }, |
}.property('value').cacheable() | }.property('value', 'maximum', 'minimum').cacheable() | displayValue: function(){ var minimum = this.get('minimum') || 0.0, maximum = this.get('maximum') || 1.0, value = this.get('value') || 0.0; value = (value - minimum) / (maximum - minimum); if (value > 1.0) value = 1.0; if(isNaN(value)) value = 0.0; // cannot be smaller then minimum if(value<minimum) value = 0.0; // cannot be larger then maximum if(value>maximum) value = 1.0; return value; }.property('value').cacheable() |
if (this.get('escapeHTML')) value = SC.RenderContext.escapeHTML(value); | displayValue: function() { var value, formatter; value = this.get('value') ; // 1. apply the formatter formatter = this.getDelegateProperty('formatter', this.displayDelegate) ; if (formatter) { var formattedValue = (SC.typeOf(formatter) === SC.T_FUNCTION) ? formatter(value, this) : formatter.fieldValueForObject(value, this) ; if (!SC.none(formattedValue)) value = formattedValue ; } // 2. If the returned value is an array, convert items to strings and // join with commas. if (SC.typeOf(value) === SC.T_ARRAY) { var ary = []; for(var idx=0, idxLen = value.get('length'); idx< idxLen;idx++) { var x = value.objectAt(idx) ; if (!SC.none(x) && x.toString) x = x.toString() ; ary.push(x) ; } value = ary.join(',') ; } // 3. If value is not a string, convert to string. (handles 0) if (!SC.none(value) && value.toString) value = value.toString() ; // 4. Localize if (value && this.getDelegateProperty('localize', this.displayDelegate)) value = value.loc() ; // 5. escapeHTML if needed if (this.get('escapeHTML')) value = SC.RenderContext.escapeHTML(value); return value ; }.property('value', 'localize', 'formatter', 'escapeHTML').cacheable(), |
|
}.property('value', 'localize', 'formatter', 'escapeHTML').cacheable(), | }.property('value', 'localize', 'formatter').cacheable(), | displayValue: function() { var value, formatter; value = this.get('value') ; // 1. apply the formatter formatter = this.getDelegateProperty('formatter', this.displayDelegate) ; if (formatter) { var formattedValue = (SC.typeOf(formatter) === SC.T_FUNCTION) ? formatter(value, this) : formatter.fieldValueForObject(value, this) ; if (!SC.none(formattedValue)) value = formattedValue ; } // 2. If the returned value is an array, convert items to strings and // join with commas. if (SC.typeOf(value) === SC.T_ARRAY) { var ary = []; for(var idx=0, idxLen = value.get('length'); idx< idxLen;idx++) { var x = value.objectAt(idx) ; if (!SC.none(x) && x.toString) x = x.toString() ; ary.push(x) ; } value = ary.join(',') ; } // 3. If value is not a string, convert to string. (handles 0) if (!SC.none(value) && value.toString) value = value.toString() ; // 4. Localize if (value && this.getDelegateProperty('localize', this.displayDelegate)) value = value.loc() ; // 5. escapeHTML if needed if (this.get('escapeHTML')) value = SC.RenderContext.escapeHTML(value); return value ; }.property('value', 'localize', 'formatter', 'escapeHTML').cacheable(), |
} var elements = doctest.getElementsByTagAndClassName('pre', ['doctest', 'setup']); for (var i=0; i<testEls.length; i++) { elements.push(testEls[i]); | var elements = doctest.getElementsByTagAndClassName('pre', ['doctest', 'setup']); for (var i=0; i<testEls.length; i++) { elements.push(testEls[i]); } | var docTestOnLoad = function () { var auto = false; if (/\bautodoctest\b/.exec(document.body.className)) { doctest.autoSetup(); auto = true; } else { logDebug('No autodoctest class on <body>'); } var loc = window.location.search.substring(1); if (auto || (/doctestRun/).exec(loc)) { var elements = null; // FIXME: we need to put the output near the specific test being tested: if (location.hash) { var el = document.getElementById(location.hash.substr(1)); if (el) { if (/\btest\b/.exec(el.className)) { testEls = doctest.getElementsByTagAndClassName('pre', 'doctest', el); } var elements = doctest.getElementsByTagAndClassName('pre', ['doctest', 'setup']); for (var i=0; i<testEls.length; i++) { elements.push(testEls[i]); } } } doctest(0, elements); }}; |
elements = doctest.getElementsByTagAndClassName('pre', 'doctest', el); | testEls = doctest.getElementsByTagAndClassName('pre', 'doctest', el); } var elements = doctest.getElementsByTagAndClassName('pre', ['doctest', 'setup']); for (var i=0; i<testEls.length; i++) { elements.push(testEls[i]); | var docTestOnLoad = function () { var auto = false; if (/\bautodoctest\b/.exec(document.body.className)) { doctest.autoSetup(); auto = true; } else { logDebug('No autodoctest class on <body>'); } var loc = window.location.search.substring(1); if (auto || (/doctestRun/).exec(loc)) { var elements = null; // FIXME: we need to put the output near the specific test being tested: if (location.hash) { var el = document.getElementById(location.hash.substr(1)); if (el) { if (/\btest\b/.exec(el.className)) { elements = doctest.getElementsByTagAndClassName('pre', 'doctest', el); } } } doctest(0, elements); }}; |
else if ( oldShippSelIndex != 'undefined' ) | else if ( oldShippSelIndex ) | var doit = function(data) { if ( Y.Node.get( '#shippingtype' ).get( 'tagName' ) == 'INPUT' ) { return false; } // If shippingtype is selected: get the old value for checking it later if ( Y.Node.get( '#shippingtype' ).get( 'selectedIndex' ) > 0 ) { var oldShippSelIndex = Y.Node.get( '#shippingtype' ).get( 'selectedIndex' ); var oldname = Y.Node.get( '#shippingtype' ).get( 'options' ).item( oldShippSelIndex ).get( 'text' ); var old = Y.Node.get( '#shippingtype' ).get( 'options' ).item( oldShippSelIndex ).get( 'value' ); } var nodes = Y.all('#shippingtype option'); var deleteNodes = function(n, a, b) { n.get('parentNode').removeChild(n); }; nodes.each(deleteNodes); for (i = 0; i < data.length; i++) { if (data[i][2] == false) { var node = Y.Node.create('<option value="' + data[i][1] + '" disabled>' + data[i][0] + '</option>'); } else { if (old == data[i][1]) { var selected = i; } var node = Y.Node.create('<option value="' + data[i][1] + '">' + data[i][0] + '</option>'); } Y.Node.get('#shippingtype').appendChild(node); } if (typeof (selected) != 'undefined') { Y.Node.get('#shippingtype').set('selectedIndex', selected); } else if ( oldShippSelIndex != 'undefined' ) { if ( Y.Node.get( '#shippingtype' ).get( 'selectedIndex' ) != -1 ) { var replace = new Array(); replace['%old%'] = oldname; var newShippSelIndex = Y.Node.get( '#shippingtype' ).get( 'selectedIndex' ); var newname = Y.Node.get( '#shippingtype' ).get( 'options' ).item( newShippSelIndex ).get( 'text' ); replace['%new%'] = newname; ez18nAlert("The shipping method '%old%' is not available for your country of destination and was changed to '%new%'.", replace); } } Y.log('INFO2: ' + Y.Lang.dump(Y.Node.get('#shippingtype').get('options'))); }; |
ez18nAlert("The shipping method '%old%' is not available for your country of destination and was changed to '%new%'.", replace); | if ( oldname ) { ez18nAlert("The shipping method '%old%' is not available for your country of destination and was changed to '%new%'.", replace); } | var doit = function(data) { if ( Y.Node.get( '#shippingtype' ).get( 'tagName' ) == 'INPUT' ) { return false; } // If shippingtype is selected: get the old value for checking it later if ( Y.Node.get( '#shippingtype' ).get( 'selectedIndex' ) > 0 ) { var oldShippSelIndex = Y.Node.get( '#shippingtype' ).get( 'selectedIndex' ); var oldname = Y.Node.get( '#shippingtype' ).get( 'options' ).item( oldShippSelIndex ).get( 'text' ); var old = Y.Node.get( '#shippingtype' ).get( 'options' ).item( oldShippSelIndex ).get( 'value' ); } var nodes = Y.all('#shippingtype option'); var deleteNodes = function(n, a, b) { n.get('parentNode').removeChild(n); }; nodes.each(deleteNodes); for (i = 0; i < data.length; i++) { if (data[i][2] == false) { var node = Y.Node.create('<option value="' + data[i][1] + '" disabled>' + data[i][0] + '</option>'); } else { if (old == data[i][1]) { var selected = i; } var node = Y.Node.create('<option value="' + data[i][1] + '">' + data[i][0] + '</option>'); } Y.Node.get('#shippingtype').appendChild(node); } if (typeof (selected) != 'undefined') { Y.Node.get('#shippingtype').set('selectedIndex', selected); } else if ( oldShippSelIndex != 'undefined' ) { if ( Y.Node.get( '#shippingtype' ).get( 'selectedIndex' ) != -1 ) { var replace = new Array(); replace['%old%'] = oldname; var newShippSelIndex = Y.Node.get( '#shippingtype' ).get( 'selectedIndex' ); var newname = Y.Node.get( '#shippingtype' ).get( 'options' ).item( newShippSelIndex ).get( 'text' ); replace['%new%'] = newname; ez18nAlert("The shipping method '%old%' is not available for your country of destination and was changed to '%new%'.", replace); } } Y.log('INFO2: ' + Y.Lang.dump(Y.Node.get('#shippingtype').get('options'))); }; |
this[0].parentNode){c.isFunction(a)||(a=c(a).detach());return this.each(function(){var b=this.nextSibling,d=this.parentNode;c(this).remove();b?c(b).before(a):c(d).append(a)})}else return this.pushStack(c(c.isFunction(a)?a():a),"replaceWith",a)},detach:function(a){return this.remove(a,true)},domManip:function(a,b,d){function f(t){return c.nodeName(t,"table")?t.getElementsByTagName("tbody")[0]||t.appendChild(t.ownerDocument.createElement("tbody")):t}var e,i,j=a[0],o=[];if(c.isFunction(j))return this.each(function(t){var z= c(this);a[0]=j.call(this,t,b?z.html():w);return z.domManip(a,b,d)});if(this[0]){e=a[0]&&a[0].parentNode&&a[0].parentNode.nodeType===11?{fragment:a[0].parentNode}:ua(a,this,o);if(i=e.fragment.firstChild){b=b&&c.nodeName(i,"tr");for(var p=0,n=this.length;p<n;p++)d.call(b?f(this[p],i):this[p],e.cacheable||this.length>1||p>0?e.fragment.cloneNode(true):e.fragment)}o&&c.each(o,La)}return this}});c.fragments={};c.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"}, | this[0].parentNode){if(c.isFunction(a))return this.each(function(b){var d=c(this),f=d.html();d.replaceWith(a.call(this,b,f))});if(typeof a!=="string")a=c(a).detach();return this.each(function(){var b=this.nextSibling,d=this.parentNode;c(this).remove();b?c(b).before(a):c(d).append(a)})}else return this.pushStack(c(c.isFunction(a)?a():a),"replaceWith",a)},detach:function(a){return this.remove(a,true)},domManip:function(a,b,d){function f(u){return c.nodeName(u,"table")?u.getElementsByTagName("tbody")[0]|| u.appendChild(u.ownerDocument.createElement("tbody")):u}var e,j,i=a[0],o=[],k;if(!c.support.checkClone&&arguments.length===3&&typeof i==="string"&&ua.test(i))return this.each(function(){c(this).domManip(a,b,d,true)});if(c.isFunction(i))return this.each(function(u){var z=c(this);a[0]=i.call(this,u,b?z.html():w);z.domManip(a,b,d)});if(this[0]){e=i&&i.parentNode;e=c.support.parentNode&&e&&e.nodeType===11&&e.childNodes.length===this.length?{fragment:e}:sa(a,this,o);k=e.fragment;if(j=k.childNodes.length=== 1?(k=k.firstChild):k.firstChild){b=b&&c.nodeName(j,"tr");for(var n=0,r=this.length;n<r;n++)d.call(b?f(this[n],j):this[n],n>0||e.cacheable||this.length>1?k.cloneNode(true):k)}o.length&&c.each(o,Qa)}return this}});c.fragments={};c.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){c.fn[a]=function(d){var f=[];d=c(d);var e=this.length===1&&this[0].parentNode;if(e&&e.nodeType===11&&e.childNodes.length===1&&d.length===1){d[b](this[0]); | this[0].parentNode){c.isFunction(a)||(a=c(a).detach());return this.each(function(){var b=this.nextSibling,d=this.parentNode;c(this).remove();b?c(b).before(a):c(d).append(a)})}else return this.pushStack(c(c.isFunction(a)?a():a),"replaceWith",a)},detach:function(a){return this.remove(a,true)},domManip:function(a,b,d){function f(t){return c.nodeName(t,"table")?t.getElementsByTagName("tbody")[0]||t.appendChild(t.ownerDocument.createElement("tbody")):t}var e,i,j=a[0],o=[];if(c.isFunction(j))return this.each(function(t){var z=c(this);a[0]=j.call(this,t,b?z.html():w);return z.domManip(a,b,d)});if(this[0]){e=a[0]&&a[0].parentNode&&a[0].parentNode.nodeType===11?{fragment:a[0].parentNode}:ua(a,this,o);if(i=e.fragment.firstChild){b=b&&c.nodeName(i,"tr");for(var p=0,n=this.length;p<n;p++)d.call(b?f(this[p],i):this[p],e.cacheable||this.length>1||p>0?e.fragment.cloneNode(true):e.fragment)}o&&c.each(o,La)}return this}});c.fragments={};c.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"}, |
if (!pool) pool = pools[guid] = SC._DoublyLinkedList.create(); | if (!pool) pool = pools[guid] = SC.CollectionFastPath._DoublyLinkedList.create(); | domPoolForExampleView: function(exampleView) { var pools = this._domPools || (this._domPools = {}), guid = SC.guidFor(exampleView), pool = pools[guid]; if(!exampleView) "no exampleView to create from"; if (!pool) pool = pools[guid] = SC._DoublyLinkedList.create(); return pool; }, |
if(!exampleView) debugger; | if(!exampleView) "no exampleView to create from"; | domPoolForExampleView: function(exampleView) { var pools = this._domPools || (this._domPools = {}), guid = SC.guidFor(exampleView), pool = pools[guid]; if(!exampleView) debugger; if (!pool) pool = pools[guid] = SC._DoublyLinkedList.create(); return pool; }, |
this.throwIfDisposed(); | activity.TimelineModel.prototype.doneAddingEvents = function(endTimeUsec) { this.throwIfDisposed(); this.addingEventDepth_--; if (this.addingEventDepth_ < 0) { throw new Error('addingEventDepth_ went negative'); } if (this.addingEventDepth_ != 0) { // Wait til all event generators have completed. return; } if (endTimeUsec > this.pendingEndTimeUsec_) { this.pendingEndTimeUsec_ = endTimeUsec; } if (this.pendingEndTimeUsec_ > this.endTimeUsec_) { this.endTimeUsec_ = this.pendingEndTimeUsec_; this.pendingEndTimeUsec_ = 0; this.onEndTimeChanged_(); }}; |
|
var url = virtroot + '/search.cgi?tree=' + treename; | sep = virtroot[virtroot.length - 1] === '/' ? '' : '/'; var url = virtroot + sep + 'search.cgi?tree=' + treename; | function doSearch(id) { var f = document.getElementById(id); var treename = 'mozilla-central'; var args = f.string.value.split(/ +/); var string = ""; var url = virtroot + '/search.cgi?tree=' + treename; for (var i = 0; i < args.length; i++) { var arg = args[i]; if (/^path:.+/(arg)) url += "&path=" + encodeURIComponent(/^path:(.+)/.exec(arg).slice(1,2)); else if (/^ext:.+/(arg)) url += "&ext=" + encodeURIComponent(/^ext:(.+)/.exec(arg).slice(1,2)); else if (/^type:.+/(arg)) url += "&type=" + encodeURIComponent(/^type:(.+)/.exec(arg).slice(1,2)); else if (/^member:.+/(arg)) url += "&member=" + encodeURIComponent(/^member:(.+)/.exec(arg).slice(1,2)); else if (/^derived:.+/(arg)) url += "&derived=" + encodeURIComponent(/^derived:(.+)/.exec(arg).slice(1,2)); else if (/^callers:.+/(arg)) url += "&callers=" + encodeURIComponent(/^callers:(.+)/.exec(arg).slice(1,2)); else if (/^macro:.+/(arg)) url += "¯o=" + encodeURIComponent(/^macro:(.+)/.exec(arg).slice(1,2)); else if (/^warnings:.*/(arg)) { var warnings = /^warnings:(.*)/.exec(arg).slice(1,2); // see if user did warnings:<nothing>, meaning "show all warnings" if (warnings == '') warnings = '*'; url += "&warnings=" + encodeURIComponent(warnings); } else { string += arg + " "; continue; } } if (string.length > 0) { string = string.substring(0, string.length-1); if (/^\/.+\/$/(string)) { string = string.substring(1, string.length-1); url += "®exp=on"; } url += "&string=" + encodeURIComponent(string); } url = url.replace(/\&/g, '&'); window.location = url; return false;} |
else { | else if (/^warnings:.*/(arg)) { var warnings = /^warnings:(.*)/.exec(arg).slice(1,2); if (warnings == '') warnings = '*'; url += "&warnings=" + encodeURIComponent(warnings); } else { | function doSearch(id) { var f = document.getElementById(id); var treename = 'mozilla-central'; var args = f.string.value.split(/ +/); var string = ""; var url = virtroot + '/search.cgi?tree=' + treename; for (var i = 0; i < args.length; i++) { var arg = args[i]; if (/^path:.+/(arg)) url += "&path=" + encodeURIComponent(/^path:(.+)/.exec(arg).slice(1,2)); else if (/^ext:.+/(arg)) url += "&ext=" + encodeURIComponent(/^ext:(.+)/.exec(arg).slice(1,2)); else if (/^type:.+/(arg)) url += "&type=" + encodeURIComponent(/^type:(.+)/.exec(arg).slice(1,2)); else if (/^member:.+/(arg)) url += "&member=" + encodeURIComponent(/^member:(.+)/.exec(arg).slice(1,2)); else if (/^derived:.+/(arg)) url += "&derived=" + encodeURIComponent(/^derived:(.+)/.exec(arg).slice(1,2)); else if (/^callers:.+/(arg)) url += "&callers=" + encodeURIComponent(/^callers:(.+)/.exec(arg).slice(1,2)); else if (/^macro:.+/(arg)) url += "¯o=" + encodeURIComponent(/^macro:(.+)/.exec(arg).slice(1,2)); else { string += arg + " "; continue; } } if (string.length > 0) { string = string.substring(0, string.length-1); if (/^\/.+\/$/(string)) { string = string.substring(1, string.length-1); url += "®exp=on"; } url += "&string=" + encodeURIComponent(string); } url = url.replace(/\&/g, '&'); window.location = url; return false;} |
var treename = this.tree || document.getElementById('trees').value; | var treename = 'mozilla-central'; | function doSearch(id) { var f = document.getElementById(id); var treename = this.tree || document.getElementById('trees').value; var args = f.string.value.split(/ +/); var string = ""; var url = virtroot + '/search.cgi?tree=' + treename; for (var i = 0; i < args.length; i++) { var arg = args[i]; if (/^path:.+/(arg)) url += "&path=" + encodeURIComponent(/^path:(.+)/.exec(arg).slice(1,2)); else if (/^ext:.+/(arg)) url += "&ext=" + encodeURIComponent(/^ext:(.+)/.exec(arg).slice(1,2)); else if (/^type:.+/(arg)) url += "&type=" + encodeURIComponent(/^type:(.+)/.exec(arg).slice(1,2)); else if (/^member:.+/(arg)) url += "&member=" + encodeURIComponent(/^member:(.+)/.exec(arg).slice(1,2)); else if (/^derived:.+/(arg)) url += "&derived=" + encodeURIComponent(/^derived:(.+)/.exec(arg).slice(1,2)); else if (/^callers:.+/(arg)) url += "&callers=" + encodeURIComponent(/^callers:(.+)/.exec(arg).slice(1,2)); else if (/^macro:.+/(arg)) url += "¯o=" + encodeURIComponent(/^macro:(.+)/.exec(arg).slice(1,2)); else { string += arg + " "; continue; } } if (string.length > 0) { string = string.substring(0, string.length-1); if (/^\/.+\/$/(string)) { string = string.substring(1, string.length-1); url += "®exp=on"; } url += "&string=" + encodeURIComponent(string); } url = url.replace(/\&/g, '&'); window.location = url; return false;} |
down: function(element, expression, index) { element = $(element); if (arguments.length == 1) return element.firstDescendant(); return Object.isNumber(expression) ? element.descendants()[expression] : Element.select(element, expression)[index || 0]; }, | var Prototype={Version:"1.6.1",Browser:(function(){var b=navigator.userAgent;var a=Object.prototype.toString.call(window.opera)=="[object Opera]";return{IE:!!window.attachEvent&&!a,Opera:a,WebKit:b.indexOf("AppleWebKit/")>-1,Gecko:b.indexOf("Gecko")>-1&&b.indexOf("KHTML")===-1,MobileSafari:/Apple.*Mobile.*Safari/.test(b)}})(),BrowserFeatures:{XPath:!!document.evaluate,SelectorsAPI:!!document.querySelector,ElementExtensions:(function(){var a=window.Element||window.HTMLElement;return !!(a&&a.prototype)})(),SpecificElementExtensions:(function(){if(typeof window.HTMLDivElement!=="undefined"){return true}var c=document.createElement("div");var b=document.createElement("form");var a=false;if(c.__proto__&&(c.__proto__!==b.__proto__)){a=true}c=b=null;return a})()},ScriptFragment:"<script[^>]*>([\\S\\s]*?)<\/script>",JSONFilter:/^\/\*-secure-([\s\S]*)\*\/\s*$/,emptyFunction:function(){},K:function(a){return a}};if(Prototype.Browser.MobileSafari){Prototype.BrowserFeatures.SpecificElementExtensions=false}var Abstract={};var Try={these:function(){var c;for(var b=0,d=arguments.length;b<d;b++){var a=arguments[b];try{c=a();break}catch(f){}}return c}};var Class=(function(){function a(){}function b(){var g=null,f=$A(arguments);if(Object.isFunction(f[0])){g=f.shift()}function d(){this.initialize.apply(this,arguments)}Object.extend(d,Class.Methods);d.superclass=g;d.subclasses=[];if(g){a.prototype=g.prototype;d.prototype=new a;g.subclasses.push(d)}for(var e=0;e<f.length;e++){d.addMethods(f[e])}if(!d.prototype.initialize){d.prototype.initialize=Prototype.emptyFunction}d.prototype.constructor=d;return d}function c(k){var f=this.superclass&&this.superclass.prototype;var e=Object.keys(k);if(!Object.keys({toString:true}).length){if(k.toString!=Object.prototype.toString){e.push("toString")}if(k.valueOf!=Object.prototype.valueOf){e.push("valueOf")}}for(var d=0,g=e.length;d<g;d++){var j=e[d],h=k[j];if(f&&Object.isFunction(h)&&h.argumentNames().first()=="$super"){var l=h;h=(function(i){return function(){return f[i].apply(this,arguments)}})(j).wrap(l);h.valueOf=l.valueOf.bind(l);h.toString=l.toString.bind(l)}this.prototype[j]=h}return this}return{create:b,Methods:{addMethods:c}}})();(function(){var d=Object.prototype.toString;function i(q,s){for(var r in s){q[r]=s[r]}return q}function l(q){try{if(e(q)){return"undefined"}if(q===null){return"null"}return q.inspect?q.inspect():String(q)}catch(r){if(r instanceof RangeError){return"..."}throw r}}function k(q){var s=typeof q;switch(s){case"undefined":case"function":case"unknown":return;case"boolean":return q.toString()}if(q===null){return"null"}if(q.toJSON){return q.toJSON()}if(h(q)){return}var r=[];for(var u in q){var t=k(q[u]);if(!e(t)){r.push(u.toJSON()+": "+t)}}return"{"+r.join(", ")+"}"}function c(q){return $H(q).toQueryString()}function f(q){return q&&q.toHTML?q.toHTML():String.interpret(q)}function o(q){var r=[];for(var s in q){r.push(s)}return r}function m(q){var r=[];for(var s in q){r.push(q[s])}return r}function j(q){return i({},q)}function h(q){return !!(q&&q.nodeType==1)}function g(q){return d.call(q)=="[object Array]"}function p(q){return q instanceof Hash}function b(q){return typeof q==="function"}function a(q){return d.call(q)=="[object String]"}function n(q){return d.call(q)=="[object Number]"}function e(q){return typeof q==="undefined"}i(Object,{extend:i,inspect:l,toJSON:k,toQueryString:c,toHTML:f,keys:o,values:m,clone:j,isElement:h,isArray:g,isHash:p,isFunction:b,isString:a,isNumber:n,isUndefined:e})})();Object.extend(Function.prototype,(function(){var k=Array.prototype.slice;function d(o,l){var n=o.length,m=l.length;while(m--){o[n+m]=l[m]}return o}function i(m,l){m=k.call(m,0);return d(m,l)}function g(){var l=this.toString().match(/^[\s\(]*function[^(]*\(([^)]*)\)/)[1].replace(/\/\/.*?[\r\n]|\/\*(?:.|[\r\n])*?\*\ | down: function(element, expression, index) { element = $(element); if (arguments.length == 1) return element.firstDescendant(); return Object.isNumber(expression) ? element.descendants()[expression] : Element.select(element, expression)[index || 0]; }, |
new Request.JSON({'url' : 'php/vg_proxy.php?track=' + url, onSuccess: this.setTrack.bind(this)}, method: 'get').send(); | new Request.JSON({ 'url' : 'php/vg_proxy.php?track=' + url, onSuccess: this.setTrack.bind(this), method: 'get'} ).send(); | downloadTrack : function(url) { new Request.JSON({'url' : 'php/vg_proxy.php?track=' + url, onSuccess: this.setTrack.bind(this)}, method: 'get').send(); }, /* Property: toggleAnim (INTERNAL) Toggle (start/stop) the animation */ _toggleAnim : function(e) { if (e.rightClick) { this.animPos = 0; $clear(this.animTimer); this.animTimer = null; var playGif = $('vgps-anim').getStyle('background-image').replace(/pause/, 'play'); $('vgps-anim').setStyle('background-image', playGif); this._animate(); } else { if (this.animTimer === null) { this.animTimer = this._animate.periodical(this.animDelay.val, this); this.charts.showCursor(true); var pauseGif = $('vgps-anim').getStyle('background-image').replace(/play/, 'pause'); $('vgps-anim').setStyle('background-image', pauseGif); } else { $clear(this.animTimer); this.animTimer = null; var playGif = $('vgps-anim').getStyle('background-image').replace(/pause/, 'play'); $('vgps-anim').setStyle('background-image', playGif); } } }, /* Property: _setAnimDelay (INTERNAL) Set animation speed Arguments: val: 0 = min ... 100 = max */ _setAnimDelay : function(val) { this.animDelay.val = this.animDelay.min + (100 - val) / 100 * (this.animDelay.max - this.animDelay.min); if (this.animTimer !== null) { $clear(this.animTimer); this.animTimer = this._animate.periodical(this.animDelay.val, this); } }, |
_toggleAnim : function(e) { if (e.rightClick) { this.animPos = 0; $clear(this.animTimer); this.animTimer = null; var playGif = $('vgps-anim').getStyle('background-image').replace(/pause/, 'play'); $('vgps-anim').setStyle('background-image', playGif); this._animate(); } else { if (this.animTimer === null) { this.animTimer = this._animate.periodical(this.animDelay.val, this); this.charts.showCursor(true); var pauseGif = $('vgps-anim').getStyle('background-image').replace(/play/, 'pause'); $('vgps-anim').setStyle('background-image', pauseGif); } else { $clear(this.animTimer); this.animTimer = null; var playGif = $('vgps-anim').getStyle('background-image').replace(/pause/, 'play'); $('vgps-anim').setStyle('background-image', playGif); } } }, _setAnimDelay : function(val) { this.animDelay.val = this.animDelay.min + (100 - val) / 100 * (this.animDelay.max - this.animDelay.min); if (this.animTimer !== null) { $clear(this.animTimer); this.animTimer = this._animate.periodical(this.animDelay.val, this); } }, | downloadTrack : function(url) { new Request.JSON({'url' : 'php/vg_proxy.php?track=' + url, onSuccess: this.setTrack.bind(this)}, method: 'get').send(); }, /* Property: toggleAnim (INTERNAL) Toggle (start/stop) the animation */ _toggleAnim : function(e) { if (e.rightClick) { this.animPos = 0; $clear(this.animTimer); this.animTimer = null; var playGif = $('vgps-anim').getStyle('background-image').replace(/pause/, 'play'); $('vgps-anim').setStyle('background-image', playGif); this._animate(); } else { if (this.animTimer === null) { this.animTimer = this._animate.periodical(this.animDelay.val, this); this.charts.showCursor(true); var pauseGif = $('vgps-anim').getStyle('background-image').replace(/play/, 'pause'); $('vgps-anim').setStyle('background-image', pauseGif); } else { $clear(this.animTimer); this.animTimer = null; var playGif = $('vgps-anim').getStyle('background-image').replace(/pause/, 'play'); $('vgps-anim').setStyle('background-image', playGif); } } }, /* Property: _setAnimDelay (INTERNAL) Set animation speed Arguments: val: 0 = min ... 100 = max */ _setAnimDelay : function(val) { this.animDelay.val = this.animDelay.min + (100 - val) / 100 * (this.animDelay.max - this.animDelay.min); if (this.animTimer !== null) { $clear(this.animTimer); this.animTimer = this._animate.periodical(this.animDelay.val, this); } }, |
|
if (e.srcElement.parentNode.nodeName == "A") { data = e.srcElement.parentNode.href; } else { data = e.dataTransfer.getData('Text'); if (!data) { data = window.getSelection().toString(); } } | var data = getDragSelection(e); | function dragEnd(e) { if (start_x == -1 || start_y == -1) { // The drop event is from external, keep original action. return true; } document.body.style.cursor = mouse_style; mouse_style = "default"; var x_dir = 1; if (e.preventDefault) { e.preventDefault (); } if (e.screenX < start_x) { x_dir = -1; } var y_dir = 1; if (e.screenY < start_y) { y_dir = -1; } start_x = -1; start_y = -1; if (e.srcElement.parentNode.nodeName == "A") { data = e.srcElement.parentNode.href; } else { data = e.dataTransfer.getData('Text'); if (!data) { data = window.getSelection().toString(); } } if (data) { chrome.extension.connect().postMessage({ message: 'tab', values: data, x_dir: x_dir, y_dir: y_dir}); return false; } return true;} |
e.dataTransfer.effectAllowed = "copy"; e.dataTransfer.dropEffect = "copy"; | dragOver: function(e) { if (!this.in_drag) { return true; } if (e.preventDefault) { e.preventDefault (); } return false; }, |
|
this.drag_selection.text = link; | this.drag_selection.data = link; | dragStart: function(e) { if (this.local_options["alt_key"] == "true" && e.altKey || this.local_options["ctrl_key"] == "true" && e.ctrlKey) { return true; } this.in_drag = true; this.start_x = e.pageX; this.start_y = e.pageY; this.drag_selection = this.getDragSelection(e); if (this.drag_selection.type == "text") { var link = this.getTextLink(this.drag_selection.data); if (link != "") { this.drag_selection.type = "link"; this.drag_selection.text = link; } } return false; }, |
var visColumns = variablesToColumns(bindings, variables); | var visVariables = objectsByVisType(visType, variables); var visColumns = variablesToColumns(bindings, visVariables); | function draw(container, visType, bindings, variables, options){ var visColumns = variablesToColumns(bindings, variables);//alert(visType + " " + visColumns.toSource());//alert(visType + " " + bindings.toSource() + " " + variables.toSource()); var view = new google.visualization.DataView(data); if (visType.indexOf("Table") == -1) view.setColumns(visColumns); // all columns for Table var visOptions = optionsByVisType(visType, options); var optArray = { }; for (var j in visOptions) optArray[options[j].name] = options[j].value; // set visualization options optArray["height"] = 450; // CSS doesn't work on Table?? container.draw(view, optArray); /* if (visType.indexOf("Map") != -1) if (typeColumns.lat.length > 0 && typeColumns.lng.length > 0) drawMap(container, bindingTypes, variables); */} |
var visOptions = optionsByVisType(visType, options); | var visOptions = objectsByVisType(visType, options); | function draw(container, visType, bindings, variables, options){ var visColumns = variablesToColumns(bindings, variables);//alert(visType + " " + visColumns.toSource());//alert(visType + " " + bindings.toSource() + " " + variables.toSource()); var view = new google.visualization.DataView(data); if (visType.indexOf("Table") == -1) view.setColumns(visColumns); // all columns for Table var visOptions = optionsByVisType(visType, options); var optArray = { }; for (var j in visOptions) optArray[options[j].name] = options[j].value; // set visualization options optArray["height"] = 450; // CSS doesn't work on Table?? container.draw(view, optArray); /* if (visType.indexOf("Map") != -1) if (typeColumns.lat.length > 0 && typeColumns.lng.length > 0) drawMap(container, bindingTypes, variables); */} |
srchFldLbl: _Settings.searchLabel, | srchFldLbl: _Settings.searchLabel | var draw = function() { $('#content').lkfw_searchableList({ listId: 'users', items: thisRef.Data.mem.users, srchFldLbl: _Settings.searchLabel, }); $('#users_0 li').unbind('click').click( function() { thisRef.userListItem_Click(this) }); $('#users_0 li').unbind('mouseover').mouseover( function() { thisRef.userListItem_MouseOver(this) }); $('#users_0 li').unbind('mouseout').mouseout( function() { thisRef.userListItem_MouseOut(this) }); }; |
var orderColumns = new Array(); var restColumns = new Array(); for (var i = 0; i < variables.length; i++) { var bindingType = bindingTypeByVariable(bindingTypes, variables[i]); if ("order" in bindingType) orderColumns[bindingType.order] = variables[i].variable; else restColumns = restColumns.concat(variables[i].variable); } var visColumns = orderColumns.concat(restColumns); | var visColumns = variablesToColumns(bindingTypes, variables); | function draw(container, visType, bindingTypes, variables, options){ //alert(container.toSource()); //alert(visualizations); var orderColumns = new Array(); var restColumns = new Array(); for (var i = 0; i < variables.length; i++) { var bindingType = bindingTypeByVariable(bindingTypes, variables[i]); if ("order" in bindingType) orderColumns[bindingType.order] = variables[i].variable; else restColumns = restColumns.concat(variables[i].variable); } var visColumns = orderColumns.concat(restColumns); var view = new google.visualization.DataView(data); if (visType.indexOf("Table") == -1) view.setColumns(visColumns); // all columns for Table var visOptions = optionsByVisType(visType, options); var optArray = { }; for (var j in visOptions) optArray[options[j].name] = options[j].value; // set visualization options optArray["height"] = 450; // CSS doesn't work on Table?? container.draw(view, optArray); /* if (visType.indexOf("Map") != -1) if (typeColumns.lat.length > 0 && typeColumns.lng.length > 0) drawMap(container, bindingTypes, variables); */} |
optArray['height'] = 450; | function draw(container, visType, bindingTypes, variables, options){ //alert(container.toSource()); //alert(visualizations); var orderColumns = new Array(); var restColumns = new Array(); for (var i = 0; i < variables.length; i++) { var bindingType = bindingTypeByVariable(bindingTypes, variables[i]); if ("order" in bindingType) orderColumns[bindingType.order] = variables[i].variable; else restColumns = restColumns.concat(variables[i].variable); } var visColumns = orderColumns.concat(restColumns); var view = new google.visualization.DataView(data); if (visType.indexOf("Table") == -1) view.setColumns(visColumns); // all columns for Table var optArray = { }; for (var j = 0; j < options.length; j++) if (visType == options[j].visType) optArray[options[j].name] = options[j].value; // set visualization options//alert(optArray.toSource()); container.draw(view, optArray); /* if (visType.indexOf("Map") != -1) if (typeColumns.lat.length > 0 && typeColumns.lng.length > 0) drawMap(container, bindingTypes, variables); */} |
|
thisRef.Data.ajax_getData_charts('chartData_'+i, _charts[i].dataURL, _charts[i].dataURL_params(thisRef.Data), function(data, chart){ getData(data, chart); }, function(){},_charts[i]); | this.Data.ajax_getData_sync('chartData_'+i, _charts[i].dataURL, _charts[i].dataURL_params(this.Data), getData, function(){},_charts[i]); | this.drawCharts = function(_charts) { var thisRef = this; var cnt = 1; var draw = function(gData) { var query = gData.join('&'); thisRef.charts_load(query, cnt);cnt++; }; var getData = function(data, chart) { var translatedData = chart.translateData(data); var gData = []; for (key in chart.gChart) { // Adding static variables gData.push(key+'='+chart.gChart[key]); } for (key in translatedData) { // Adding dynamic variables gData.push(key+'='+translatedData[key]); } draw(gData); }; $('#chartContent').empty(); try { this.charts_prepTable(_charts.length); for (var i=0;i<_charts.length;i++) { // Get the data from ajax call if (_charts[i].dataURL) { thisRef.Data.ajax_getData_charts('chartData_'+i, _charts[i].dataURL, _charts[i].dataURL_params(thisRef.Data), function(data, chart){ getData(data, chart); }, function(){},_charts[i]); } else { getData(this.Data.mem, _charts[i]); } } } catch(err) {} }; |
var gData = [ 'chtt='+chart.gChart.chtt, 'cht='+chart.gChart.cht, 'chs='+chart.gChart.chs, 'chd='+translatedData.chd, 'chl='+translatedData.chl ]; | var gData = []; for (key in chart.gChart) { gData.push(key+'='+chart.gChart[key]); } for (key in translatedData) { gData.push(key+'='+translatedData[key]); } draw(gData); }; | this.drawCharts = function(_charts) { var thisRef = this; var draw = function(gData) { var query = gData.join('&'); $('#chartContent').append( $('<img></img>').attr('src','http://chart.apis.google.com/chart?'+query) ); }; var getData = function(data, chart) { var translatedData = chart.translateData(data); var gData = [ 'chtt='+chart.gChart.chtt, 'cht='+chart.gChart.cht, 'chs='+chart.gChart.chs, 'chd='+translatedData.chd, 'chl='+translatedData.chl ]; //if (chart.gChart.chco) gData.push('chco='+chart.gChart.chco); if (translatedData.chco) gData.push('chco='+translatedData.chco); draw(gData); }; $('#chartContent').empty(); try { for (var i=0;i<_charts.length;i++) { // Get the data from ajax call if (_charts[i].ajax) thisRef.Data.ajax_getData_charts(_charts[i].dataURL, _charts[i].dataURL_params(thisRef.Data), function(data, chart){getData(data, chart);}, function(){},_charts[i]);} } catch(err) {} }; |
if (translatedData.chco) gData.push('chco='+translatedData.chco); draw(gData); }; | this.drawCharts = function(_charts) { var thisRef = this; var draw = function(gData) { var query = gData.join('&'); $('#chartContent').append( $('<img></img>').attr('src','http://chart.apis.google.com/chart?'+query) ); }; var getData = function(data, chart) { var translatedData = chart.translateData(data); var gData = [ 'chtt='+chart.gChart.chtt, 'cht='+chart.gChart.cht, 'chs='+chart.gChart.chs, 'chd='+translatedData.chd, 'chl='+translatedData.chl ]; //if (chart.gChart.chco) gData.push('chco='+chart.gChart.chco); if (translatedData.chco) gData.push('chco='+translatedData.chco); draw(gData); }; $('#chartContent').empty(); try { for (var i=0;i<_charts.length;i++) { // Get the data from ajax call if (_charts[i].ajax) thisRef.Data.ajax_getData_charts(_charts[i].dataURL, _charts[i].dataURL_params(thisRef.Data), function(data, chart){getData(data, chart);}, function(){},_charts[i]);} } catch(err) {} }; |
|
if (_charts[i].ajax) thisRef.Data.ajax_getData_charts(_charts[i].dataURL, _charts[i].dataURL_params(thisRef.Data), function(data, chart){getData(data, chart);}, function(){},_charts[i]);} | if (_charts[i].dataURL) { thisRef.Data.ajax_getData_charts(_charts[i].dataURL, _charts[i].dataURL_params(thisRef.Data), function(data, chart){ getData(data, chart); }, function(){},_charts[i]); } else { getData(this.Data.mem.tasks.data, _charts[i]); } } | this.drawCharts = function(_charts) { var thisRef = this; var draw = function(gData) { var query = gData.join('&'); $('#chartContent').append( $('<img></img>').attr('src','http://chart.apis.google.com/chart?'+query) ); }; var getData = function(data, chart) { var translatedData = chart.translateData(data); var gData = [ 'chtt='+chart.gChart.chtt, 'cht='+chart.gChart.cht, 'chs='+chart.gChart.chs, 'chd='+translatedData.chd, 'chl='+translatedData.chl ]; //if (chart.gChart.chco) gData.push('chco='+chart.gChart.chco); if (translatedData.chco) gData.push('chco='+translatedData.chco); draw(gData); }; $('#chartContent').empty(); try { for (var i=0;i<_charts.length;i++) { // Get the data from ajax call if (_charts[i].ajax) thisRef.Data.ajax_getData_charts(_charts[i].dataURL, _charts[i].dataURL_params(thisRef.Data), function(data, chart){getData(data, chart);}, function(){},_charts[i]);} } catch(err) {} }; |
function DrawFromNode(field,node,inner) { var result=""; var i=0; var width=10; if (node==-1) {width=0;} var c=0; | function DrawFromNode( field, node, inner ) { var result = ""; var width = 10; var numChildren = 0; | function DrawFromNode(field,node,inner) { var result=""; var i=0; var width=10; if (node==-1) {width=0;} var c=0; if (!inner) {result+="<table border=0 cellpadding=0 cellspacing=1><td width=" + width + "> </td><td class='treetext' id='" + field + "_node" + node + "'>";} //loop through all nodes with <node> as the parent for (i=0;i<TreeParents[field].length;i++) { if (TreeParents[field][i]==node) { if (TreeExpand[field][i]) {icon="<img xalign=middle width=11 height=11 hspace=3 src=admin/gfx/node_ex.gif";} else {icon="<img xalign=middle hspace=3 width=11 height=11 src=admin/gfx/node_unex.gif";} c=CountChildren(field,i); if (c==0) {icon="<img xalign=top src=admin/gfx/sp.gif width=11 height=11 hspace=3>";} else {icon+=" onClick=\"ToggleNode('" + field + "'," + i + ");\">";} icon2=""; result+=icon + icon2; checked="";if (TreeChecked[field][i]==1) {checked="checked";} if (TreeClickable[field][i]) {result+="<input name='' type=checkbox id=checkbox" + i + " " + checked + " onclick=\"CheckNode('" + field + "'," + i + ");\">";} result+=DePath(TreeNames[field][i]); result+="<br>"; if (TreeExpand[field][i] && c>0) {result+=DrawFromNode(field,i);} } } if (!inner) {result+="</td></tr></table>";} return result; } |
if (!inner) {result+="<table border=0 cellpadding=0 cellspacing=1><td width=" + width + "> </td><td class='treetext' id='" + field + "_node" + node + "'>";} | if( node == -1 ) { width = 0; } if( !inner ) { result += "<table border=0 cellpadding=0 cellspacing=1><td width=" + width + "> </td><td class='treetext' id='" + field + "_node" + node + "'>"; } | function DrawFromNode(field,node,inner) { var result=""; var i=0; var width=10; if (node==-1) {width=0;} var c=0; if (!inner) {result+="<table border=0 cellpadding=0 cellspacing=1><td width=" + width + "> </td><td class='treetext' id='" + field + "_node" + node + "'>";} //loop through all nodes with <node> as the parent for (i=0;i<TreeParents[field].length;i++) { if (TreeParents[field][i]==node) { if (TreeExpand[field][i]) {icon="<img xalign=middle width=11 height=11 hspace=3 src=admin/gfx/node_ex.gif";} else {icon="<img xalign=middle hspace=3 width=11 height=11 src=admin/gfx/node_unex.gif";} c=CountChildren(field,i); if (c==0) {icon="<img xalign=top src=admin/gfx/sp.gif width=11 height=11 hspace=3>";} else {icon+=" onClick=\"ToggleNode('" + field + "'," + i + ");\">";} icon2=""; result+=icon + icon2; checked="";if (TreeChecked[field][i]==1) {checked="checked";} if (TreeClickable[field][i]) {result+="<input name='' type=checkbox id=checkbox" + i + " " + checked + " onclick=\"CheckNode('" + field + "'," + i + ");\">";} result+=DePath(TreeNames[field][i]); result+="<br>"; if (TreeExpand[field][i] && c>0) {result+=DrawFromNode(field,i);} } } if (!inner) {result+="</td></tr></table>";} return result; } |
for (i=0;i<TreeParents[field].length;i++) { if (TreeParents[field][i]==node) { if (TreeExpand[field][i]) {icon="<img xalign=middle width=11 height=11 hspace=3 src=admin/gfx/node_ex.gif";} else {icon="<img xalign=middle hspace=3 width=11 height=11 src=admin/gfx/node_unex.gif";} | for( var i = 0; i < TreeParents[field].length; i++ ) { if( TreeParents[field][i] == node ) { if( HasTickedDescendants( field, i ) ) { if( !TreeDrawn ) { TreeExpand[field][i] = true; } TreeChecked[field][i] = 1; } if( TreeExpand[field][i] ) { icon = "<img xalign=middle width=11 height=11 hspace=3 src=admin/gfx/node_ex.gif"; } else { icon = "<img xalign=middle hspace=3 width=11 height=11 src=admin/gfx/node_unex.gif"; } | function DrawFromNode(field,node,inner) { var result=""; var i=0; var width=10; if (node==-1) {width=0;} var c=0; if (!inner) {result+="<table border=0 cellpadding=0 cellspacing=1><td width=" + width + "> </td><td class='treetext' id='" + field + "_node" + node + "'>";} //loop through all nodes with <node> as the parent for (i=0;i<TreeParents[field].length;i++) { if (TreeParents[field][i]==node) { if (TreeExpand[field][i]) {icon="<img xalign=middle width=11 height=11 hspace=3 src=admin/gfx/node_ex.gif";} else {icon="<img xalign=middle hspace=3 width=11 height=11 src=admin/gfx/node_unex.gif";} c=CountChildren(field,i); if (c==0) {icon="<img xalign=top src=admin/gfx/sp.gif width=11 height=11 hspace=3>";} else {icon+=" onClick=\"ToggleNode('" + field + "'," + i + ");\">";} icon2=""; result+=icon + icon2; checked="";if (TreeChecked[field][i]==1) {checked="checked";} if (TreeClickable[field][i]) {result+="<input name='' type=checkbox id=checkbox" + i + " " + checked + " onclick=\"CheckNode('" + field + "'," + i + ");\">";} result+=DePath(TreeNames[field][i]); result+="<br>"; if (TreeExpand[field][i] && c>0) {result+=DrawFromNode(field,i);} } } if (!inner) {result+="</td></tr></table>";} return result; } |
c=CountChildren(field,i); if (c==0) {icon="<img xalign=top src=admin/gfx/sp.gif width=11 height=11 hspace=3>";} else {icon+=" onClick=\"ToggleNode('" + field + "'," + i + ");\">";} icon2=""; result+=icon + icon2; checked="";if (TreeChecked[field][i]==1) {checked="checked";} if (TreeClickable[field][i]) {result+="<input name='' type=checkbox id=checkbox" + i + " " + checked + " onclick=\"CheckNode('" + field + "'," + i + ");\">";} result+=DePath(TreeNames[field][i]); result+="<br>"; if (TreeExpand[field][i] && c>0) {result+=DrawFromNode(field,i);} | numChildren = CountChildren( field, i ); if( numChildren == 0 ) { icon = "<img xalign=top src=admin/gfx/sp.gif width=11 height=11 hspace=3>"; } else { icon += " onClick=\"ToggleNode('" + field + "'," + i + ");\">"; } result += icon; checked = ""; if( TreeChecked[field][i] == 1 ) { checked = "checked"; } if( TreeClickable[field][i] ) { result += "<input name='' type=checkbox id=checkbox" + i + " " + checked + " onclick=\"CheckNode('" + field + "'," + i + ");\">"; } result += DePath( TreeNames[field][i] ); result += "<br>"; if( TreeExpand[field][i] && numChildren > 0 ) { result += DrawFromNode( field, i, false ); | function DrawFromNode(field,node,inner) { var result=""; var i=0; var width=10; if (node==-1) {width=0;} var c=0; if (!inner) {result+="<table border=0 cellpadding=0 cellspacing=1><td width=" + width + "> </td><td class='treetext' id='" + field + "_node" + node + "'>";} //loop through all nodes with <node> as the parent for (i=0;i<TreeParents[field].length;i++) { if (TreeParents[field][i]==node) { if (TreeExpand[field][i]) {icon="<img xalign=middle width=11 height=11 hspace=3 src=admin/gfx/node_ex.gif";} else {icon="<img xalign=middle hspace=3 width=11 height=11 src=admin/gfx/node_unex.gif";} c=CountChildren(field,i); if (c==0) {icon="<img xalign=top src=admin/gfx/sp.gif width=11 height=11 hspace=3>";} else {icon+=" onClick=\"ToggleNode('" + field + "'," + i + ");\">";} icon2=""; result+=icon + icon2; checked="";if (TreeChecked[field][i]==1) {checked="checked";} if (TreeClickable[field][i]) {result+="<input name='' type=checkbox id=checkbox" + i + " " + checked + " onclick=\"CheckNode('" + field + "'," + i + ");\">";} result+=DePath(TreeNames[field][i]); result+="<br>"; if (TreeExpand[field][i] && c>0) {result+=DrawFromNode(field,i);} } } if (!inner) {result+="</td></tr></table>";} return result; } |
if (!inner) {result+="</td></tr></table>";} | } if( !inner ) { result += "</td></tr></table>"; } if( node == -1 ) { TreeDrawn = true; } | function DrawFromNode(field,node,inner) { var result=""; var i=0; var width=10; if (node==-1) {width=0;} var c=0; if (!inner) {result+="<table border=0 cellpadding=0 cellspacing=1><td width=" + width + "> </td><td class='treetext' id='" + field + "_node" + node + "'>";} //loop through all nodes with <node> as the parent for (i=0;i<TreeParents[field].length;i++) { if (TreeParents[field][i]==node) { if (TreeExpand[field][i]) {icon="<img xalign=middle width=11 height=11 hspace=3 src=admin/gfx/node_ex.gif";} else {icon="<img xalign=middle hspace=3 width=11 height=11 src=admin/gfx/node_unex.gif";} c=CountChildren(field,i); if (c==0) {icon="<img xalign=top src=admin/gfx/sp.gif width=11 height=11 hspace=3>";} else {icon+=" onClick=\"ToggleNode('" + field + "'," + i + ");\">";} icon2=""; result+=icon + icon2; checked="";if (TreeChecked[field][i]==1) {checked="checked";} if (TreeClickable[field][i]) {result+="<input name='' type=checkbox id=checkbox" + i + " " + checked + " onclick=\"CheckNode('" + field + "'," + i + ");\">";} result+=DePath(TreeNames[field][i]); result+="<br>"; if (TreeExpand[field][i] && c>0) {result+=DrawFromNode(field,i);} } } if (!inner) {result+="</td></tr></table>";} return result; } |
return result; } | return( result ); } | function DrawFromNode(field,node,inner) { var result=""; var i=0; var width=10; if (node==-1) {width=0;} var c=0; if (!inner) {result+="<table border=0 cellpadding=0 cellspacing=1><td width=" + width + "> </td><td class='treetext' id='" + field + "_node" + node + "'>";} //loop through all nodes with <node> as the parent for (i=0;i<TreeParents[field].length;i++) { if (TreeParents[field][i]==node) { if (TreeExpand[field][i]) {icon="<img xalign=middle width=11 height=11 hspace=3 src=admin/gfx/node_ex.gif";} else {icon="<img xalign=middle hspace=3 width=11 height=11 src=admin/gfx/node_unex.gif";} c=CountChildren(field,i); if (c==0) {icon="<img xalign=top src=admin/gfx/sp.gif width=11 height=11 hspace=3>";} else {icon+=" onClick=\"ToggleNode('" + field + "'," + i + ");\">";} icon2=""; result+=icon + icon2; checked="";if (TreeChecked[field][i]==1) {checked="checked";} if (TreeClickable[field][i]) {result+="<input name='' type=checkbox id=checkbox" + i + " " + checked + " onclick=\"CheckNode('" + field + "'," + i + ");\">";} result+=DePath(TreeNames[field][i]); result+="<br>"; if (TreeExpand[field][i] && c>0) {result+=DrawFromNode(field,i);} } } if (!inner) {result+="</td></tr></table>";} return result; } |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.