rem
stringlengths 0
126k
| add
stringlengths 0
441k
| context
stringlengths 15
136k
|
|---|---|---|
theNode.appendChild(document.createTextNode(" " + theLabel));
|
theNode.appendChild(document.createTextNode("\u00a0" + theLabel));
|
function getLabel(n) { // get the label text for a buffer: var theNode = document.createElement('div'); var theNum = null; var linkAction = "javascript:refreshBufferList(" + n + ", \"getLabel.linkAction\")"; var linkFunction = function() { refreshBufferList(n, "getLabel.linkFunction") }; var className = 'bufferlabel'; if (g_cq_buffer_current != n) { // provide a link to load the buffer theNum = document.createElement('a'); theNum.setAttribute('href', linkAction); // make the whole node active theNode.onclick = linkFunction; // set tooltip theNode.title = "Click to activate this query buffer."; } else { // show the current index in bold, with no link debug.print("getLabel: " + n + " == " + g_cq_buffer_current); theNum = document.createElement('b'); className = 'bufferlabelactive'; // set tooltip theNode.title = null; } theNum.appendChild(document.createTextNode("" + (1+n) + ".")); theNode.appendChild(theNum); // make sure it doesn't break for huge strings // let the css handle text that's too large for the buffer // we shouldn't have to normalize spaces, but IE6 is broken // ...and so we have to hint word-breaks to both browsers... var theLabel = nudge(getBuffer(n).value.substr(0, 1024)); // put a space here for formatting, so it won't be inside the link theNode.appendChild(document.createTextNode(" " + theLabel)); // highlight the current buffer // IE6 doesn't like setAttribute here, but gecko accepts it theNode.className = className; // TODO mouseover for fully formatted text contents as tooltip? return theNode;} // getLabel
|
return viewPortPx.add(-parseInt(this.layerContainerDiv.style.left), -parseInt(this.layerContainerDiv.style.top));
|
var layerPx = null; if (viewPortPx != null) { var dX = -parseInt(this.layerContainerDiv.style.left); var dY = -parseInt(this.layerContainerDiv.style.top); layerPx = viewPortPx.add(dX, dY); } return layerPx;
|
getLayerPxFromViewPortPx:function(viewPortPx) { return viewPortPx.add(-parseInt(this.layerContainerDiv.style.left), -parseInt(this.layerContainerDiv.style.top)); },
|
return "link=" + exactMatchPattern(text.replace(/^\s*(.*?)\s*$/, "$1"));
|
return "link=" + exactMatchPattern(text.replace(/\xA0/g, " ").replace(/^\s*(.*?)\s*$/, "$1"));
|
getLinkLocator: function(e) { if (e.nodeName == 'A') { var text = e.textContent; if (!text.match(/^\s*$/)) { return "link=" + exactMatchPattern(text.replace(/^\s*(.*?)\s*$/, "$1")); } } return null; },
|
this.getHrefXPathLocator,
|
this.getLocator = function(window, e) { var locatorDetectors = [this.getLinkLocator, this.getIDLocator, this.getNameLocator, this.getLinkXPathLocator, this.getAttributesXPathLocator, this.getPositionXPathLocator]; var i = 0; var xpathLevel = 0; var maxLevel = 10; var locator; var pageBot = this.getPageBot(window); log.debug("getLocator for element " + e); for (var i = 0; i < locatorDetectors.length; i++) { locator = locatorDetectors[i].call(this, e, pageBot); if (locator) { log.debug("locator=" + locator); // test the locator try { if (e == pageBot.findElement(locator)) { return locator; } } catch (error) { log.warn("findElement error: " + error + ", node=" + e + ", locator=" + locator); } } } return "LOCATOR_DETECTION_FAILED"; }
|
|
} catch (e) { log.warn("findElement error: " + e);
|
} catch (error) { log.warn("findElement error: " + error + ", node=" + e + ", locator=" + locator);
|
function getLocator(window, e) { var locatorDetectors = new Array(getIDLocator, getVisibleLocator, getVisible2Locator, getNameLocator); var i = 0; var xpathLevel = 0; var maxLevel = 10; var locator; var pageBot = getPageBot(window); while (true) { if (i < locatorDetectors.length) { locator = locatorDetectors[i].call(this, e); i++; } else { locator = getAbsoluteXPathLocator(e, xpathLevel); xpathLevel++; } log.debug("locator=" + locator); if (locator != '') { // test the locator try { if (e == pageBot.findElement(locator)) { return locator; } } catch (e) { log.warn("findElement error: " + e); //break; } } else if (xpathLevel > 0) { break; } if (xpathLevel >= maxLevel) { break; } } return "LOCATOR_DETECTION_FAILED"; }
|
var gLatLng = this.gmap.fromDivPixelToLatLng(gPoint)
|
var gLatLng = this.gmap.fromContainerPixelToLatLng(gPoint)
|
getLonLatFromViewPortPx: function (viewPortPx) { var gPoint = this.getGPointFromOLPixel(viewPortPx); var gLatLng = this.gmap.fromDivPixelToLatLng(gPoint) return this.getOLLonLatFromGLatLng(gLatLng); },
|
var delta_x = viewPortPx.x - (size.w / 2); var delta_y = viewPortPx.y - (size.h / 2);
|
var delta_x = viewPortPx.x - Math.ceil(size.w / 2); var delta_y = viewPortPx.y - Math.ceil(size.h / 2);
|
getLonLatFromViewPortPx: function (viewPortPx) { var lonlat = null; if (viewPortPx != null) { var size = this.map.getSize(); var center = this.map.getCenter(); var res = this.map.getResolution(); var delta_x = viewPortPx.x - (size.w / 2); var delta_y = viewPortPx.y - (size.h / 2); lonlat = new OpenLayers.LonLat(center.lon + delta_x * res , center.lat - delta_y * res); } return lonlat; },
|
this.element.offsets[0] += (document.documentElement.scrollLeft || document.body.scrollLeft); this.element.offsets[1] += (document.documentElement.scrollTop || document.body.scrollTop);
|
getMousePosition: function (evt) { if (!this.element.offsets) { this.element.offsets = OpenLayers.Util.pagePosition(this.element); } return new OpenLayers.Pixel( (evt.clientX + (document.documentElement.scrollLeft || document.body.scrollLeft)) - this.element.offsets[0], (evt.clientY + (document.documentElement.scrollTop || document.body.scrollTop)) - this.element.offsets[1] ); },
|
|
var i = 0;
|
if(value >= this.values.max()) return(this.values.max()); if(value <= this.values.min()) return(this.values.min());
|
getNearestValue: function(value){ if(this.values){ var i = 0; var offset = Math.abs(this.values[0] - value); var newValue = this.values[0]; for(i=0; i < this.values.length; i++){ var currentOffset = Math.abs(this.values[i] - value); if(currentOffset < offset){ newValue = this.values[i]; offset = currentOffset; } } return newValue; } return value; },
|
for(i=0; i < this.values.length; i++){ var currentOffset = Math.abs(this.values[i] - value); if(currentOffset < offset){ newValue = this.values[i];
|
this.values.each( function(v) { var currentOffset = Math.abs(v - value); if(currentOffset <= offset){ newValue = v;
|
getNearestValue: function(value){ if(this.values){ var i = 0; var offset = Math.abs(this.values[0] - value); var newValue = this.values[0]; for(i=0; i < this.values.length; i++){ var currentOffset = Math.abs(this.values[i] - value); if(currentOffset < offset){ newValue = this.values[i]; offset = currentOffset; } } return newValue; } return value; },
|
} }
|
} });
|
getNearestValue: function(value){ if(this.values){ var i = 0; var offset = Math.abs(this.values[0] - value); var newValue = this.values[0]; for(i=0; i < this.values.length; i++){ var currentOffset = Math.abs(this.values[i] - value); if(currentOffset < offset){ newValue = this.values[i]; offset = currentOffset; } } return newValue; } return value; },
|
zoom = gZoom - 1;
|
zoom = gZoom;
|
getOLZoomFromGZoom: function(gZoom) { var zoom = null; if (gZoom != null) { zoom = gZoom - 1; } return zoom; },
|
zoom = veZoom - 1;
|
zoom = veZoom;
|
getOLZoomFromVEZoom: function(veZoom) { var zoom = null; if (veZoom != null) { zoom = veZoom - 1; } return zoom; },
|
return parseFloat(Element.getStyle(element, "opacity") || '1');
|
var opacity; if (opacity = Element.getStyle(element, "opacity")) return parseFloat(opacity); if (opacity = (Element.getStyle(element, "filter") || '').match(/alpha\(opacity=(.*)\)/)) if(opacity[1]) return parseFloat(opacity[1]) / 100; return 1.0;
|
Element.getOpacity = function(element){ return parseFloat(Element.getStyle(element, "opacity") || '1');}
|
if (opacity = Element.getStyle(element, "filter").match(/alpha\(opacity=(.*)\)/))
|
if (opacity = (Element.getStyle(element, "filter") || '').match(/alpha\(opacity=(.*)\)/))
|
Element.getOpacity = function(element){ var opacity; if (opacity = Element.getStyle(element, "opacity")) return parseFloat(opacity); if (opacity = Element.getStyle(element, "filter").match(/alpha\(opacity=(.*)\)/)) if(opacity[1]) return parseFloat(opacity[1]) / 100; return 1.0;}
|
return parseFloat(Element.getStyle(element, "opacity")) || '1';
|
return parseFloat(Element.getStyle(element, "opacity") || '1');
|
Element.getOpacity = function(element){ return parseFloat(Element.getStyle(element, "opacity")) || '1'; // || Element.getStyle(element, "-moz-opacity") // || Element.getStyle(element, "-khtml-opacity") // || '1');}
|
modifiers: { 'x': 'left', 'y': 'top' },
|
modifiers: {x: 'left', y: 'top'},
|
getOptions: function(){ return { handle: false, unit: 'px', onStart: Class.empty, onComplete: Class.empty, onSnap: Class.empty, onDrag: Class.empty, limit: false, modifiers: { 'x': 'left', 'y': 'top' }, snap: 6 }; },
|
paramsArray.push(key + "=" + value);
|
paramsArray.push(encodeURIComponent(key) + "=" + encodeURIComponent(value));
|
OpenLayers.Util.getParameterString = function(params) { paramsArray = new Array(); for (var key in params) { var value = params[key]; if ((value != null) && (typeof value != 'function')) { paramsArray.push(key + "=" + value); } } return paramsArray.join("&");};
|
var obj = {}, offs = this.getOffsets(); obj.width = this.offsetWidth; obj.height = this.offsetHeight; obj.left = offs.x; obj.top = offs.y; obj.right = obj.left + obj.width; obj.bottom = obj.top + obj.height;
|
var offs = this.getOffsets(); var obj = { 'width': this.offsetWidth, 'height': this.offsetHeight, 'left': offs.x, 'top': offs.y }; obj.right = obj.left + obj.width; obj.bottom = obj.top + obj.height;
|
getPosition: function(){ var obj = {}, offs = this.getOffsets(); obj.width = this.offsetWidth; obj.height = this.offsetHeight; obj.left = offs.x; obj.top = offs.y; obj.right = obj.left + obj.width; obj.bottom = obj.top + obj.height; return obj; },
|
debug.print("QueryBufferListClass.getQuery: using textarea " + this.input.value);
|
this.getQuery = function(n) { //debug.print("QueryBufferListClass.getBufferValue: " + n); if (null == n || this.pos == n) { debug.print("QueryBufferListClass.getQuery: using textarea " + this.input.value); var buf = this.getBuffer(n); buf.setQuery(this.input.value); return this.input.value; } return this.getBuffer(n).getQuery(); }
|
|
this.getBuffer(n).setQuery(this.input.value);
|
var buf = this.getBuffer(n); buf.setQuery(this.input.value); buf.setContentSource(this.eval.value);
|
this.getQuery = function(n) { //debug.print("QueryBufferListClass.getBufferValue: " + n); if (null == n || this.pos == n) { debug.print("QueryBufferListClass.getQuery: using textarea " + this.input.value); this.getBuffer(n).setQuery(this.input.value); return this.input.value; } return this.getBuffer(n).getQuery(); }
|
if (n == this.pos) {
|
if (null == n || this.pos == n) { debug.print("QueryBufferListClass.getQuery: using textarea " + this.input.value); this.getBuffer(n).setQuery(this.input.value);
|
this.getQuery = function(n) { //debug.print("QueryBufferListClass.getBufferValue: " + n); if (n == this.pos) { return this.input.value; } return this.getBuffer(n).getQuery(); }
|
return this.input.value;
|
return buf.getQuery();
|
this.getQuery = function(n) { //debug.print("QueryBufferListClass.getBufferValue: " + n); if (null == n || this.pos == n) { //debug.print("QueryBufferListClass.getQuery: using textarea " // + this.input.value); var buf = this.getBuffer(n); buf.setQuery(this.input.value); return this.input.value; } return this.getBuffer(n).getQuery(); }
|
debug("saveQueryHistory: null historyNode"); return;
|
debug.print("saveQueryHistory: null historyNode"); return null;
|
function getQueryHistoryListNode(bootstrapFlag) { var historyNode = document.getElementById(g_cq_history_node); if (! historyNode) { debug("saveQueryHistory: null historyNode"); return; } // history entries will be list-item elements in an ordered-list var listNode = historyNode.lastChild; if (!listNode && bootstrapFlag) { listNode = document.createElement("ol"); historyNode.appendChild(listNode); } return listNode;}
|
var listNode = historyNode.lastChild; if (!listNode && bootstrapFlag) { listNode = document.createElement("ol"); historyNode.appendChild(listNode);
|
var listNode = historyNode.getElementsByTagName("ol"); debug.print("getQueryHistoryListNode: found " + listNode); if (listNode && listNode[0]) { return listNode[0];
|
function getQueryHistoryListNode(bootstrapFlag) { var historyNode = document.getElementById(g_cq_history_node); if (! historyNode) { debug.print("saveQueryHistory: null historyNode"); return null; } // history entries will be list-item elements in an ordered-list var listNode = historyNode.lastChild; if (!listNode && bootstrapFlag) { listNode = document.createElement("ol"); historyNode.appendChild(listNode); } return listNode;}
|
if (!bootstrapFlag) { return null; } debug.print("getQueryHistoryListNode: bootstrapping"); removeChildNodes(historyNode); listNode = document.createElement("ol"); historyNode.appendChild(listNode);
|
function getQueryHistoryListNode(bootstrapFlag) { var historyNode = document.getElementById(g_cq_history_node); if (! historyNode) { debug.print("saveQueryHistory: null historyNode"); return null; } // history entries will be list-item elements in an ordered-list var listNode = historyNode.lastChild; if (!listNode && bootstrapFlag) { listNode = document.createElement("ol"); historyNode.appendChild(listNode); } return listNode;}
|
|
var clauses = location.search.substr(1).split('&');
|
var str = getQueryString(); if (str == null) return null; var clauses = str.split('&');
|
function getQueryParameter(searchKey) { var clauses = location.search.substr(1).split('&'); for (var i = 0; i < clauses.length; i++) { var keyValuePair = clauses[i].split('=',2); var key = unescape(keyValuePair[0]); if (key == searchKey) { return unescape(keyValuePair[1]); } } return null;}
|
var query = window.location.search.substring(1);
|
var query = getQueryString(); if (query == null) return null;
|
function getQueryVariable(variable) { var query = window.location.search.substring(1); var vars = query.split("&"); for (var i=0;i<vars.length;i++) { var pair = vars[i].split("="); if (pair[0] == variable) { return pair[1]; } }}
|
var prefs = Components.classes["@mozilla.org/preferences-service;1"]. getService(Components.interfaces.nsIPrefService); var branch = prefs.getBranch("extensions."+MYSTRING+"."); var refresh = branch.getIntPref("refresh");
|
var refresh = that.preferences.data.refresh;
|
that.getRefresh = function() { var prefs = Components.classes["@mozilla.org/preferences-service;1"]. getService(Components.interfaces.nsIPrefService); var branch = prefs.getBranch("extensions."+MYSTRING+"."); var refresh = branch.getIntPref("refresh"); var retval = Math.round((1000*refresh) + (1000*Math.random())); that.debug('refresh in',retval); return retval; };
|
return Math.max( extent.getWidth() / viewSize.w, extent.getHeight() / viewSize.h ); },
|
if ((viewSize != null) && (extent != null)) { resolution = Math.max( extent.getWidth() / viewSize.w, extent.getHeight() / viewSize.h ); } return resolution; },
|
getResolution: function() { var viewSize = this.map.getSize(); var extent = this.getExtent(); return Math.max( extent.getWidth() / viewSize.w, extent.getHeight() / viewSize.h ); },
|
return this.RESOLUTION_AT_ZOOM_LEVEL_0 / Math.pow(2, this.zoom);
|
return this.maxResolution / Math.pow(2, this.zoom);
|
getResolution: function () { // return degrees per pixel return this.RESOLUTION_AT_ZOOM_LEVEL_0 / Math.pow(2, this.zoom); },
|
var theFrame = parent.document.getElementById(g_cq_result_frame); return theFrame;
|
return parent.document.getElementById(g_cq_result_frame_id);
|
function getResultFrame() { // if the result frame is an iframe, get it from the current document //document.getElementById(g_cq_result_frame); // if the result frame is in a frameset, get it from the parent document var theFrame = parent.document.getElementById(g_cq_result_frame); return theFrame;} // getResultFrame
|
if(user_input==all) return true;
|
function getReviseOwn(element){ if(!element){ return false; } var user_input = getRadioButtonCheckedValue(element); if(user_input==all) return true; if(user_input==own) return true; else return false;}
|
|
var inst = this.instance; var sel = this.getSel();
|
var s = this.getSel();
|
getRng : function() { var inst = this.instance; var sel = this.getSel(); if (sel == null) return null; if (tinyMCE.isMSIE && !tinyMCE.isOpera) return sel.createRange(); if (tinyMCE.isSafari && !sel.getRangeAt) return '' + window.getSelection(); return sel.getRangeAt(0); },
|
if (sel == null)
|
if (s == null)
|
getRng : function() { var inst = this.instance; var sel = this.getSel(); if (sel == null) return null; if (tinyMCE.isMSIE && !tinyMCE.isOpera) return sel.createRange(); if (tinyMCE.isSafari && !sel.getRangeAt) return '' + window.getSelection(); return sel.getRangeAt(0); },
|
if (tinyMCE.isMSIE && !tinyMCE.isOpera) return sel.createRange();
|
if (tinyMCE.isRealIE) return s.createRange();
|
getRng : function() { var inst = this.instance; var sel = this.getSel(); if (sel == null) return null; if (tinyMCE.isMSIE && !tinyMCE.isOpera) return sel.createRange(); if (tinyMCE.isSafari && !sel.getRangeAt) return '' + window.getSelection(); return sel.getRangeAt(0); },
|
if (tinyMCE.isSafari && !sel.getRangeAt)
|
if (tinyMCE.isSafari && !s.getRangeAt)
|
getRng : function() { var inst = this.instance; var sel = this.getSel(); if (sel == null) return null; if (tinyMCE.isMSIE && !tinyMCE.isOpera) return sel.createRange(); if (tinyMCE.isSafari && !sel.getRangeAt) return '' + window.getSelection(); return sel.getRangeAt(0); },
|
return sel.getRangeAt(0);
|
return s.getRangeAt(0);
|
getRng : function() { var inst = this.instance; var sel = this.getSel(); if (sel == null) return null; if (tinyMCE.isMSIE && !tinyMCE.isOpera) return sel.createRange(); if (tinyMCE.isSafari && !sel.getRangeAt) return '' + window.getSelection(); return sel.getRangeAt(0); },
|
var file = getContentDir(); file.append("scripts");
|
var file = Components.classes["@mozilla.org/file/directory_service;1"] .getService(Components.interfaces.nsIProperties) .get("ProfD", Components.interfaces.nsILocalFile); file.append("gm_scripts");
|
function getScriptDir() { var file = getContentDir(); file.append("scripts"); return file;}
|
if (tinyMCE.isMSIE && !tinyMCE.isOpera)
|
if (tinyMCE.isRealIE)
|
getSel : function() { var inst = this.instance; if (tinyMCE.isMSIE && !tinyMCE.isOpera) return inst.getDoc().selection; return inst.contentWindow.getSelection(); },
|
if (tinyMCE.isSafari) { return r.toString(); }
|
if (!r) return null;
|
getSelectedHTML : function() { var inst = this.instance; var e, r = this.getRng(), h; if (tinyMCE.isSafari) { // Not realy perfect!! return r.toString(); } e = document.createElement("body"); if (tinyMCE.isGecko) e.appendChild(r.cloneContents()); else e.innerHTML = r.item ? r.item(0).outerHTML : r.htmlText; h = tinyMCE._cleanupHTML(inst, inst.contentDocument, inst.settings, e, e, false, true, false); // When editing always use fonts internaly if (tinyMCE.getParam("convert_fonts_to_spans")) tinyMCE.convertSpansToFonts(inst.getDoc()); return h; },
|
if (tinyMCE.isGecko)
|
if (r.cloneContents)
|
getSelectedHTML : function() { var inst = this.instance; var e, r = this.getRng(), h; if (tinyMCE.isSafari) { // Not realy perfect!! return r.toString(); } e = document.createElement("body"); if (tinyMCE.isGecko) e.appendChild(r.cloneContents()); else e.innerHTML = r.item ? r.item(0).outerHTML : r.htmlText; h = tinyMCE._cleanupHTML(inst, inst.contentDocument, inst.settings, e, e, false, true, false); // When editing always use fonts internaly if (tinyMCE.getParam("convert_fonts_to_spans")) tinyMCE.convertSpansToFonts(inst.getDoc()); return h; },
|
else
|
else if (typeof(r.item) != 'undefined' || typeof(r.htmlText) != 'undefined')
|
getSelectedHTML : function() { var inst = this.instance; var e, r = this.getRng(), h; if (tinyMCE.isSafari) { // Not realy perfect!! return r.toString(); } e = document.createElement("body"); if (tinyMCE.isGecko) e.appendChild(r.cloneContents()); else e.innerHTML = r.item ? r.item(0).outerHTML : r.htmlText; h = tinyMCE._cleanupHTML(inst, inst.contentDocument, inst.settings, e, e, false, true, false); // When editing always use fonts internaly if (tinyMCE.getParam("convert_fonts_to_spans")) tinyMCE.convertSpansToFonts(inst.getDoc()); return h; },
|
else e.innerHTML = r.toString();
|
getSelectedHTML : function() { var inst = this.instance; var e, r = this.getRng(), h; if (tinyMCE.isSafari) { // Not realy perfect!! return r.toString(); } e = document.createElement("body"); if (tinyMCE.isGecko) e.appendChild(r.cloneContents()); else e.innerHTML = r.item ? r.item(0).outerHTML : r.htmlText; h = tinyMCE._cleanupHTML(inst, inst.contentDocument, inst.settings, e, e, false, true, false); // When editing always use fonts internaly if (tinyMCE.getParam("convert_fonts_to_spans")) tinyMCE.convertSpansToFonts(inst.getDoc()); return h; },
|
|
if (tinyMCE.isMSIE) {
|
if (tinyMCE.isIE) {
|
getSelectedText : function() { var inst = this.instance; var d, r, s, t; if (tinyMCE.isMSIE) { d = inst.getDoc(); if (d.selection.type == "Text") { r = d.selection.createRange(); t = r.text; } else t = ''; } else { s = this.getSel(); if (s && s.toString) t = s.toString(); else t = ''; } return t; },
|
var w = selenium.browserbot.getCurrentWindow();
|
var w = (proxyInjectionMode ? selenium.browserbot.getCurrentWindow() : window);
|
function getSeleniumWindowName() { var w = selenium.browserbot.getCurrentWindow(); if (w.opener==null) { return ""; } if (w["seleniumWindowName"]==null) { return "?"; } return w["seleniumWindowName"];}
|
debugger
|
function getSeleniumWindowNameURLparameters() { var w = (proxyInjectionMode ? selenium.browserbot.getCurrentWindow() : window).top; var s = "&seleniumWindowName="; if (w.opener == null) { return s; } if (w["seleniumWindowName"] == null) { s += 'generatedSeleniumWindowName_' + Math.round(100000 * Math.random()); } else { s += w["seleniumWindowName"]; } var windowOpener = w.opener; for (key in windowOpener) { var val = null; try { val = windowOpener[key]; } catch(e) { } if (val==w) { s += "&jsWindowNameVar=" + key; // found a js variable in the opener referring to this window } } debugger return s;}
|
|
return this.size;
|
var size = null; if (this.size != null) { size = this.size.clone(); } return size;
|
getSize: function () { return this.size; },
|
function(str, p1, offset, s) { result = eval(p1); return result != null ? result : ''; });
|
function(str, p1, offset, s) { result = eval(p1, {command: command, comment: comment}); return result != null ? result : ''; });
|
function getSourceForCommand(commandObj) { var command = null; var comment = null; var template = ''; if (commandObj.type == 'command') { command = commandObj; command = command.createCopy(); convertText(command, this.encodeText); template = options.commandTemplate; } else if (commandObj.type == 'comment') { comment = commandObj; template = options.commentTemplate; } var result; var text = template.replace(/\$\{([a-zA-Z0-9_\.]+)\}/g, function(str, p1, offset, s) { result = eval(p1); return result != null ? result : ''; }); return text;}
|
var top = this.getStyle(property+'-top') || 0; var right = this.getStyle(property+'-right') || 0; var bottom = this.getStyle(property+'-bottom') || 0; var left = this.getStyle(property+'-left') || 0; return top+' '+right+' '+bottom+' '+left;
|
return [this.getStyle(property+'-top') || 0, this.getStyle(property+'-right') || 0, this.getStyle(property+'-bottom') || 0, this.getStyle(property+'-left') || 0].join(' ');
|
getStyle: function(property){ property = property.camelCase(); var style = this.style[property] || false; if (!$chk(style)){ if (property == 'opacity') return (this.opacity != undefined) ? this.opacity : 1; if (['margin', 'padding'].test(property)){ var top = this.getStyle(property+'-top') || 0; var right = this.getStyle(property+'-right') || 0; var bottom = this.getStyle(property+'-bottom') || 0; var left = this.getStyle(property+'-left') || 0; return top+' '+right+' '+bottom+' '+left; } if (document.defaultView) style = document.defaultView.getComputedStyle(this,null).getPropertyValue(property.hyphenate()); else if (this.currentStyle) style = this.currentStyle[property]; } return (style && property.test('color', 'i') && style.test('rgb')) ? style.rgbToHex() : style; },
|
return ".html";
|
switch(contentType) { case "text/xml": return ".xml"; case "application/xhtml+xml": return ".xhtml"; case "image/svg+xml": return ".svg"; case "text/mathml": return ".mml"; } return ".html";
|
function getSuffix(contentType) { return ".html";}
|
if (navigator.appName != "Microsoft Internet Explorer"){ return node; }
|
function getSurroundingRowNode(node){ while(node){ if (node.tagName == "TR"){ break; } node = node.parentNode; } return node;}
|
|
var grid = new Array(); var rows = table.rows;
|
var grid = new Array(), rows = table.rows, x, y, td, sd, xstart, x2, y2;
|
function getTableGrid(table) { var grid = new Array(); var rows = table.rows; for (var y=0; y<rows.length; y++) { for (var x=0; x<rows[y].cells.length; x++) { var td = rows[y].cells[x]; var sd = getColRowSpan(td); // All ready filled for (xstart = x; grid[y] && grid[y][xstart]; xstart++) ; // Fill box for (var y2=y; y2<y+sd['rowspan']; y2++) { if (!grid[y2]) grid[y2] = new Array(); for (var x2=xstart; x2<xstart+sd['colspan']; x2++) { grid[y2][x2] = td; } } } } return grid; }
|
for (var y=0; y<rows.length; y++) { for (var x=0; x<rows[y].cells.length; x++) { var td = rows[y].cells[x]; var sd = getColRowSpan(td);
|
for (y=0; y<rows.length; y++) { for (x=0; x<rows[y].cells.length; x++) { td = rows[y].cells[x]; sd = getColRowSpan(td);
|
function getTableGrid(table) { var grid = new Array(); var rows = table.rows; for (var y=0; y<rows.length; y++) { for (var x=0; x<rows[y].cells.length; x++) { var td = rows[y].cells[x]; var sd = getColRowSpan(td); // All ready filled for (xstart = x; grid[y] && grid[y][xstart]; xstart++) ; // Fill box for (var y2=y; y2<y+sd['rowspan']; y2++) { if (!grid[y2]) grid[y2] = new Array(); for (var x2=xstart; x2<xstart+sd['colspan']; x2++) { grid[y2][x2] = td; } } } } return grid; }
|
for (var y2=y; y2<y+sd['rowspan']; y2++) {
|
for (y2=y; y2<y+sd['rowspan']; y2++) {
|
function getTableGrid(table) { var grid = new Array(); var rows = table.rows; for (var y=0; y<rows.length; y++) { for (var x=0; x<rows[y].cells.length; x++) { var td = rows[y].cells[x]; var sd = getColRowSpan(td); // All ready filled for (xstart = x; grid[y] && grid[y][xstart]; xstart++) ; // Fill box for (var y2=y; y2<y+sd['rowspan']; y2++) { if (!grid[y2]) grid[y2] = new Array(); for (var x2=xstart; x2<xstart+sd['colspan']; x2++) { grid[y2][x2] = td; } } } } return grid; }
|
for (var x2=xstart; x2<xstart+sd['colspan']; x2++) {
|
for (x2=xstart; x2<xstart+sd['colspan']; x2++)
|
function getTableGrid(table) { var grid = new Array(); var rows = table.rows; for (var y=0; y<rows.length; y++) { for (var x=0; x<rows[y].cells.length; x++) { var td = rows[y].cells[x]; var sd = getColRowSpan(td); // All ready filled for (xstart = x; grid[y] && grid[y][xstart]; xstart++) ; // Fill box for (var y2=y; y2<y+sd['rowspan']; y2++) { if (!grid[y2]) grid[y2] = new Array(); for (var x2=xstart; x2<xstart+sd['colspan']; x2++) { grid[y2][x2] = td; } } } } return grid; }
|
}
|
function getTableGrid(table) { var grid = new Array(); var rows = table.rows; for (var y=0; y<rows.length; y++) { for (var x=0; x<rows[y].cells.length; x++) { var td = rows[y].cells[x]; var sd = getColRowSpan(td); // All ready filled for (xstart = x; grid[y] && grid[y][xstart]; xstart++) ; // Fill box for (var y2=y; y2<y+sd['rowspan']; y2++) { if (!grid[y2]) grid[y2] = new Array(); for (var x2=xstart; x2<xstart+sd['colspan']; x2++) { grid[y2][x2] = td; } } } } return grid; }
|
|
if (Calendar.is_ie) { return window.event.srcElement; } else { return ev.target; }
|
var f = Calendar.is_ie ? window.event.srcElement : ev.target; while (f.nodeType != 1) f = f.parentNode; return f;
|
Calendar.getTargetElement = function(ev) { if (Calendar.is_ie) { return window.event.srcElement; } else { return ev.target; }};
|
if (this.options.loadTextURL) { this.loadExternalText(); return this.options.loadingText; } else { return this.element.innerHTML; }
|
return this.element.innerHTML;
|
getText: function() { if (this.options.loadTextURL) { this.loadExternalText(); return this.options.loadingText; } else { return this.element.innerHTML; } },
|
if(element.textContent)
|
if(isFirefox)
|
function getText(element) { text = ""; if(element.textContent) { var dummyElement = element.cloneNode(true); renderWhitespaceInTextContent(dummyElement); text = dummyElement.textContent; } else if(element.innerText) { text = element.innerText; } text = normalizeNewlines(text); text = normalizeSpaces(text); return text.trim();}
|
} else if(element.innerText)
|
} else if(element.textContent) { text = element.textContent; } else if(element.innerText)
|
function getText(element) { text = ""; if(element.textContent) { var dummyElement = element.cloneNode(true); renderWhitespaceInTextContent(dummyElement); text = dummyElement.textContent; } else if(element.innerText) { text = element.innerText; } text = normalizeNewlines(text); text = normalizeSpaces(text); return text.trim();}
|
text = text.replace(/\240/g, " ");
|
function getText(element) { text = ""; if(element.textContent) { text = element.textContent; } else if(element.innerText) { text = element.innerText; } return text.trim();}
|
|
} else if (browserVersion.isOpera) { var dummyElement = element.cloneNode(true); renderWhitespaceInTextContent(dummyElement); text = dummyElement.innerText;
|
function getText(element) { var text = ""; if(browserVersion.isFirefox && browserVersion.firefoxVersion >= "1.5") { var dummyElement = element.cloneNode(true); renderWhitespaceInTextContent(dummyElement); text = dummyElement.textContent; } else if(element.textContent) { text = element.textContent; } else if(element.innerText) { text = element.innerText; } text = normalizeNewlines(text); text = normalizeSpaces(text); return text.trim();}
|
|
text = "";
|
var text = "";
|
function getText(element) { text = ""; if(browserVersion.isFirefox) { var dummyElement = element.cloneNode(true); renderWhitespaceInTextContent(dummyElement); text = dummyElement.textContent; } else if(element.textContent) { text = element.textContent; } else if(element.innerText) { text = element.innerText; } text = normalizeNewlines(text); text = normalizeSpaces(text); return text.trim();}
|
if(browserVersion.isFirefox)
|
if(browserVersion.isFirefox && browserVersion.firefoxVersion >= "1.5")
|
function getText(element) { text = ""; if(browserVersion.isFirefox) { var dummyElement = element.cloneNode(true); renderWhitespaceInTextContent(dummyElement); text = dummyElement.textContent; } else if(element.textContent) { text = element.textContent; } else if(element.innerText) { text = element.innerText; } text = normalizeNewlines(text); text = normalizeSpaces(text); return text.trim();}
|
} else if (browserVersion.isKonqueror) {
|
} else if (browserVersion.isKonqueror || browserVersion.isSafari) {
|
function getText(element) { var text = ""; if (browserVersion.isFirefox && browserVersion.firefoxVersion >= "1.5") { var dummyElement = element.cloneNode(true); renderWhitespaceInTextContent(dummyElement); text = dummyElement.textContent; } else if (browserVersion.isKonqueror) { var dummyElement = element.cloneNode(true); renderWhitespaceInTextContent(dummyElement); text = dummyElement.innerText; } else if (browserVersion.isOpera) { var dummyElement = element.cloneNode(true); renderWhitespaceInTextContent(dummyElement); text = dummyElement.innerText; text = xmlDecode(text); } else if (element.textContent) { text = element.textContent; } else if (element.innerText) { text = element.innerText; } text = normalizeNewlines(text); text = normalizeSpaces(text); return text.trim();}
|
return '<select id="{$editor_id}_titleSelect" name="{$editor_id}_titleSelect" class="mceSelectList" onchange="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Title\',false,this.options[this.selectedIndex].value);wikiEditor.executedCommand(\'Title\');">\ <option value="0">{$lang_wiki_title_menu}</option>\ <option value="1">{$lang_wiki_title_1}</option>\ <option value="2">{$lang_wiki_title_2}</option>\ <option value="3">{$lang_wiki_title_3}</option>\ <option value="4">{$lang_wiki_title_4}</option>\ <option value="5">{$lang_wiki_title_5}</option>\ </select>';
|
return '<select id="{$editor_id}_titleSelect" name="{$editor_id}_titleSelect" class="mceSelectList" onchange="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Title\',false,this.options[this.selectedIndex].value);wikiEditor.executedCommand(\'Title\');">' + '<option value="0">{$lang_wiki_title_menu}</option>' + '<option value="1">{$lang_wiki_title_1}</option>' + '<option value="2">{$lang_wiki_title_2}</option>' + '<option value="3">{$lang_wiki_title_3}</option>' + '<option value="4">{$lang_wiki_title_4}</option>' + '<option value="5">{$lang_wiki_title_5}</option>' + '</select>';
|
WikiEditor.prototype.getTitleControl = function(button_name) { return '<select id="{$editor_id}_titleSelect" name="{$editor_id}_titleSelect" class="mceSelectList" onchange="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Title\',false,this.options[this.selectedIndex].value);wikiEditor.executedCommand(\'Title\');">\ <option value="0">{$lang_wiki_title_menu}</option>\ <option value="1">{$lang_wiki_title_1}</option>\ <option value="2">{$lang_wiki_title_2}</option>\ <option value="3">{$lang_wiki_title_3}</option>\ <option value="4">{$lang_wiki_title_4}</option>\ <option value="5">{$lang_wiki_title_5}</option>\ </select>';}
|
}
|
},
|
getTransport: function() { return Try.these( function() {return new ActiveXObject('Msxml2.XMLHTTP')}, function() {return new ActiveXObject('Microsoft.XMLHTTP')}, function() {return new XMLHttpRequest()} ) || false; }
|
function() {return new ActiveXObject('Microsoft.XMLHTTP')}, function() {return new XMLHttpRequest()}
|
function() {return new ActiveXObject('Microsoft.XMLHTTP')}
|
getTransport: function() { return Try.these( function() {return new ActiveXObject('Msxml2.XMLHTTP')}, function() {return new ActiveXObject('Microsoft.XMLHTTP')}, function() {return new XMLHttpRequest()} ) || false; },
|
getTransport: function(ajaxRequest) { var transport = Try.these(
|
getTransport: function() { return Try.these(
|
getTransport: function(ajaxRequest) { var transport = Try.these( function() {return new ActiveXObject('Msxml2.XMLHTTP')}, function() {return new ActiveXObject('Microsoft.XMLHTTP')}, function() {return new XMLHttpRequest()} ); transport.ajaxRequest = ajaxRequest; return transport; }
|
); transport.ajaxRequest = ajaxRequest; return transport;
|
) || false;
|
getTransport: function(ajaxRequest) { var transport = Try.these( function() {return new ActiveXObject('Msxml2.XMLHTTP')}, function() {return new ActiveXObject('Microsoft.XMLHTTP')}, function() {return new XMLHttpRequest()} ); transport.ajaxRequest = ajaxRequest; return transport; }
|
getTransport: function() { return Try.these(
|
getTransport: function(ajaxRequest) { var transport = Try.these(
|
getTransport: function() { return Try.these( function() {return new ActiveXObject('Msxml2.XMLHTTP')}, function() {return new ActiveXObject('Microsoft.XMLHTTP')}, function() {return new XMLHttpRequest()} ) || false; }
|
) || false;
|
); transport.ajaxRequest = ajaxRequest; return transport;
|
getTransport: function() { return Try.these( function() {return new ActiveXObject('Msxml2.XMLHTTP')}, function() {return new ActiveXObject('Microsoft.XMLHTTP')}, function() {return new XMLHttpRequest()} ) || false; }
|
var zoom = this.map.getZoom();
|
var mapRes = this.map.getResolution();
|
getURL: function (bounds) { var zoom = this.map.getZoom(); var scale = this.map.getScale(); var cellSize = new OpenLayers.Size(mapRes*this.tileSize.w, mapRes*this.tileSize.h); var pX = Math.round(((bounds.left) / cellSize.w) * this.tileSize.w); var pY = -Math.round(((bounds.top) / cellSize.h) * this.tileSize.h); return this.getFullRequestString( { t: pY, l: pX, s: scale }); },
|
tileSize.w = tileSize.w * 2; tileSize.h = tileSize.h * 2;
|
tileSize.w = tileSize.w * this.ratio; tileSize.h = tileSize.h * this.ratio;
|
getURL: function(bounds) { var tileSize = this.map.getSize(); tileSize.w = tileSize.w * 2; tileSize.h = tileSize.h * 2; return this.getFullRequestString( {'BBOX': bounds.toBBOX(), 'WIDTH': tileSize.w, 'HEIGHT': tileSize.h} ); },
|
var zoom = this.getZoom(); var extent = this.map.getMaxExtent();
|
getURL: function (bounds) { var deg = this.lzd/Math.pow(2,this.getZoom()); var x = Math.floor((bounds.left - extent.left)/deg); var y = Math.floor((bounds.bottom - extent.bottom)/deg); return this.getFullRequestString( { L: zoom, X: x, Y: y }); },
|
|
if (!path.match(/^file:/)) {
|
if (!path.match(/^(file|chrome):/)) {
|
getURLs: function(commaSeparatedPaths) { var urls = []; if (commaSeparatedPaths) { commaSeparatedPaths.split(/,/).forEach(function(path) { path = path.replace(/^\s*/, ''); path = path.replace(/\s*$/, ''); if (!path.match(/^file:/)) { path = FileUtils.fileURI(FileUtils.getFile(path)); } urls.push(path); }); } return urls; },
|
case 'input': if ((this.checked && ['checkbox', 'radio'].test(this.type)) || ['hidden', 'text', 'password'].test(this.type)) return this.value; break;
|
case 'input': if (!(this.checked && ['checkbox', 'radio'].test(this.type)) && !['hidden', 'text', 'password'].test(this.type)) break;
|
getValue: function(){ switch (this.getTag()){ case 'select': if (this.selectedIndex != -1) return this.options[this.selectedIndex].value; break; case 'input': if ((this.checked && ['checkbox', 'radio'].test(this.type)) || ['hidden', 'text', 'password'].test(this.type)) return this.value; break; case 'textarea': return this.value; } return false; }
|
zoom = olZoom + 1;
|
zoom = olZoom;
|
getVEZoomFromOLZoom: function(olZoom) { var zoom = null; if (olZoom != null) { zoom = olZoom + 1; } return zoom; },
|
left : self.pageXOffset || self.document.documentElement.scrollLeft || self.document.body.scrollLeft, top: self.pageYOffset || self.document.documentElement.scrollTop || self.document.body.scrollTop,
|
getViewPort : function() { return { width : document.documentElement.offsetWidth || document.body.offsetWidth, height : self.innerHeight || document.documentElement.clientHeight || document.body.clientHeight }; },
|
|
return layerPx.add(parseInt(this.layerContainerDiv.style.left), parseInt(this.layerContainerDiv.style.top) );
|
var viewPortPx = null; if (layerPx != null) { var dX = parseInt(this.layerContainerDiv.style.left); var dY = parseInt(this.layerContainerDiv.style.top); viewPortPx = layerPx.add(dX, dY); } return viewPortPx;
|
getViewPortPxFromLayerPx:function(layerPx) { return layerPx.add(parseInt(this.layerContainerDiv.style.left), parseInt(this.layerContainerDiv.style.top) ); },
|
var gPoint = this.gmap.fromLatLngToDivPixel(gLatLng)
|
var gPoint = this.fromLatLngToContainerPixel(gLatLng);
|
getViewPortPxFromLonLat: function (lonlat) { var gLatLng = this.getGLatLngFromOLLonLat(lonlat); var gPoint = this.gmap.fromLatLngToDivPixel(gLatLng) return this.getOLPixelFromGPoint(gPoint); },
|
var value = obj.style.visibility; if (!value) { if (document.defaultView && typeof (document.defaultView.getComputedStyle) == "function") { if (!Calendar.is_khtml) value = document.defaultView. getComputedStyle(obj, "").getPropertyValue("visibility"); else value = ''; } else if (obj.currentStyle) { value = obj.currentStyle.visibility; } else
|
var value = obj.style.visibility; if (!value) { if (document.defaultView && typeof (document.defaultView.getComputedStyle) == "function") { if (!Calendar.is_khtml) value = document.defaultView. getComputedStyle(obj, "").getPropertyValue("visibility"); else
|
function getVisib(obj){ var value = obj.style.visibility; if (!value) { if (document.defaultView && typeof (document.defaultView.getComputedStyle) == "function") { // Gecko, W3C if (!Calendar.is_khtml) value = document.defaultView. getComputedStyle(obj, "").getPropertyValue("visibility"); else value = ''; } else if (obj.currentStyle) { // IE value = obj.currentStyle.visibility; } else value = ''; } return value; };
|
} return value; };
|
} else if (obj.currentStyle) { value = obj.currentStyle.visibility; } else value = ''; } return value; };
|
function getVisib(obj){ var value = obj.style.visibility; if (!value) { if (document.defaultView && typeof (document.defaultView.getComputedStyle) == "function") { // Gecko, W3C if (!Calendar.is_khtml) value = document.defaultView. getComputedStyle(obj, "").getPropertyValue("visibility"); else value = ''; } else if (obj.currentStyle) { // IE value = obj.currentStyle.visibility; } else value = ''; } return value; };
|
zoom = zoom - Math.log(this.map.maxResolution / (this.lzd/512))/Math.log(2);
|
zoom = zoom - Math.log(this.maxResolution / (this.lzd/512))/Math.log(2);
|
getZoom: function () { var zoom = this.map.getZoom(); var extent = this.map.getMaxExtent(); zoom = zoom - Math.log(this.map.maxResolution / (this.lzd/512))/Math.log(2); return zoom; },
|
for(var i=1; i <= this.resolutions.length; i++) { if ( this.resolutions[i] < idealResolution) { break; } } return (i - 1);
|
return this.getZoomForResolution(idealResolution);
|
getZoomForExtent: function(extent) { var viewSize = this.map.getSize(); var idealResolution = Math.max( extent.getWidth() / viewSize.w, extent.getHeight() / viewSize.h ); for(var i=1; i <= this.resolutions.length; i++) { if ( this.resolutions[i] < idealResolution) { break; } } return (i - 1); },
|
for(var i=1; i <= this.resolutions.length; i++) {
|
for(var i=1; i < this.resolutions.length; i++) {
|
getZoomForResolution: function(resolution) { for(var i=1; i <= this.resolutions.length; i++) { if ( this.resolutions[i] < resolution) { break; } } return (i - 1); },
|
var parts = url.match(/^(search|summary|shortlog|log|commit|commitdiff|tree|tag)(\s(.*))?/);
|
var parts = url.match(/^(search|summary|shortlog|log|blob|commit|commitdiff|history|tree|tag)(\s(.*))?/);
|
function gitweb(base, project, url){ var parts = url.match(/^(search|summary|shortlog|log|commit|commitdiff|tree|tag)(\s(.*))?/); var query = '?p=' + project; if (parts) { query += ';a=' + parts[1]; /* If the extra arg is not for searching assume it is an ID. */ if (parts[1] == 'search' && parts[3]) query += ';s=' + escape(parts[3]); else if (parts[3]) query += ';h=' + escape(parts[3]); } else { query += ';a=summary'; } return base + query;}
|
else if ((parts[1] == 'blob' || parts[1] == 'history' || parts[1] == 'tree') && parts[3]) query += ';f=' + escape(parts[3]);
|
function gitweb(base, project, url){ var parts = url.match(/^(search|summary|shortlog|log|commit|commitdiff|tree|tag)(\s(.*))?/); var query = '?p=' + project; if (parts) { query += ';a=' + parts[1]; /* If the extra arg is not for searching assume it is an ID. */ if (parts[1] == 'search' && parts[3]) query += ';s=' + escape(parts[3]); else if (parts[3]) query += ';h=' + escape(parts[3]); } else { query += ';a=summary'; } return base + query;}
|
|
target = "_top"
|
target = "_self"
|
function gLnk(optionFlags, description, linkData) { var fullLink = ""; var targetFlag = ""; var target = ""; var protocolFlag = ""; var protocol = ""; if (optionFlags>=0) //is numeric (old style) or empty (error) { return oldGLnk(optionFlags, description, linkData) } targetFlag = optionFlags.charAt(0) if (targetFlag=="B") target = "_blank" if (targetFlag=="P") target = "_parent" if (targetFlag=="R") target = "basefrm" if (targetFlag=="S") target = "_self" if (targetFlag=="T") target = "_top" if (optionFlags.length > 1) { protocolFlag = optionFlags.charAt(1) if (protocolFlag=="h") protocol = "http://" if (protocolFlag=="s") protocol = "https://" if (protocolFlag=="f") protocol = "ftp://" if (protocolFlag=="m") protocol = "mailto:" } fullLink = "'" + protocol + linkData + "' target=" + target linkItem = new Item(description, protocol+linkData, target) return linkItem }
|
this.matches = function(actual) { return this.regexp.test(actual); };
|
PatternMatcher.GlobMatchStrategy = function(globString) { this.regexp = new RegExp(this.regexpFromGlob(globString));};
|
|
webProgress.addProgressListener(this, nsIWebProgress.NOTIFY_PROGRESS);
|
Components.classes["@mozilla.org/docloaderservice;1"] .getService(Components.interfaces.nsIWebProgress) .addProgressListener(this, Components.interfaces.nsIWebProgress .NOTIFY_PROGRESS);
|
function GM_DocHandler(unsafeContentWin, chromeWindow, menuCommander, isFile) { GM_log("> GM_DocHandler") this.unsafeContentWin = unsafeContentWin; this.chromeWindow = chromeWindow; this.menuCommander = menuCommander; this.isFile = isFile; // this will be all scripts to be injected into this document. this.scripts = []; this.loadHandler = GM_hitch(this, "contentLoad"); GM_listen(this.chromeWindow, "DOMContentLoaded", this.loadHandler); if (this.isFile) { } else { webProgress.addProgressListener(this, nsIWebProgress.NOTIFY_PROGRESS); } GM_log("< GM_DocHandler")}
|
function GM_DocHandler(contentWindow, chromeWindow) {
|
function GM_DocHandler(contentWindow, chromeWindow, menuCommander) {
|
function GM_DocHandler(contentWindow, chromeWindow) { GM_log("> GM_DocHandler") this.contentWindow = contentWindow; this.chromeWindow = chromeWindow; this.initScripts(); this.injectScripts(); GM_log("< GM_DocHandler")}
|
this.menuCommander = menuCommander;
|
function GM_DocHandler(contentWindow, chromeWindow) { GM_log("> GM_DocHandler") this.contentWindow = contentWindow; this.chromeWindow = chromeWindow; this.initScripts(); this.injectScripts(); GM_log("< GM_DocHandler")}
|
|
return (scheme == "http" || scheme == "https" || scheme == "file") && !/hiddenWindow\.html$/.test(url);
|
return (scheme == "http" || scheme == "https" || scheme == "file" || url.match(/^about:cache/)) && !/hiddenWindow\.html$/.test(url);
|
function GM_isGreasemonkeyable(url) { var scheme = Components.classes["@mozilla.org/network/io-service;1"] .getService(Components.interfaces.nsIIOService) .extractScheme(url); return (scheme == "http" || scheme == "https" || scheme == "file") && !/hiddenWindow\.html$/.test(url);}
|
consoleService.logMessage(aMessage);
|
if (level) { if (level == 1) { level = 1; } else { level = 0; } var consoleError = Components.classes["@mozilla.org/scripterror;1"] .createInstance(Components.interfaces.nsIScriptError); consoleError.init(aMessage, null, null, 0, 0, level, "XUL javascript"); consoleService.logMessage(consoleError); } else { consoleService.logStringMessage(aMessage); }
|
function GM_log(aMessage, level) { var consoleService = Components.classes["@mozilla.org/consoleservice;1"] .getService(Components.interfaces.nsIConsoleService); consoleService.logMessage(aMessage);}
|
function GM_log(aMessage) {
|
function GM_log(aMessage, level) {
|
function GM_log(aMessage) { var consoleService = Components.classes["@mozilla.org/consoleservice;1"] .getService(Components.interfaces.nsIConsoleService); consoleService.logStringMessage("Greasemonkey: " + aMessage);}
|
consoleService.logStringMessage("Greasemonkey: " + aMessage);
|
consoleService.logMessage(aMessage);
|
function GM_log(aMessage) { var consoleService = Components.classes["@mozilla.org/consoleservice;1"] .getService(Components.interfaces.nsIConsoleService); consoleService.logStringMessage("Greasemonkey: " + aMessage);}
|
this.commandData = []; this.activeKeys = [];
|
this.menuItems = []; this.keys = [];
|
function GM_MenuCommander() { GM_log("> GM_MenuCommander") this.menu = document.getElementById("userscript-commands"); this.keyset = document.getElementById("mainKeyset"); this.commandData = []; this.activeKeys = []; this.attached = false; this.menuPopup = null; GM_log("< GM_MenuCommander")}
|
this.menuPopup = null;
|
function GM_MenuCommander() { GM_log("> GM_MenuCommander") this.menu = document.getElementById("userscript-commands"); this.keyset = document.getElementById("mainKeyset"); this.commandData = []; this.activeKeys = []; this.attached = false; this.menuPopup = null; GM_log("< GM_MenuCommander")}
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.