rem stringlengths 0 126k | add stringlengths 0 441k | context stringlengths 15 136k |
|---|---|---|
prefManager.onPrefChanged = onPrefChanged; | prefManager.addObserver({ onPrefChanged: onPrefChanged }); network.prefManager.addObserver(prefManager); | function getUserPrefManager(user){ var network = user.parent.parent; function defer(prefName) { return network.prefs[prefName]; }; function onPrefChanged(prefName, newValue, oldValue) { onUserPrefChanged (user, prefName, newValue, oldValue); }; var logDefault = client.prefM... |
if (accountArray[serverId] == null) { | if (!(serverId in accountArray)) { | function getValueArrayFor(serverId) { if (serverId == undefined) serverId="global"; if (accountArray[serverId] == null) { accountArray[serverId] = new Array; } return accountArray[serverId];} |
return g_wcapErrorCodes[getWcapErrorIndex(errno) * 2]; | var index = -1; if (errno >= -1 && errno <= 81) index = (errno + 1); else if (errno >= 11000 && errno <= 11008) index = (errno - 11000 + 100 + 1); if (index >= 0 && g_wcapErrorCodes[index * 2] != Components.results.NS_ERROR_INVALID_ARG) { return g_wcapErrorCodes[index * 2]; } throw Components.results.NS_ERROR_INVALID_A... | function getWcapErrorCode( errno ){ return g_wcapErrorCodes[getWcapErrorIndex(errno) * 2];} |
return getWcapErrorCodeString(rc); | return wcapErrorToString(rc); | getWcapErrorString: function( rc ) { return getWcapErrorCodeString(rc); }, |
throw Components.interfaces.calIWcapErrors.WCAP_NO_ERRNO; | throw new Components.Exception( "No WCAP errno (missing X-NSCP-WCAP-ERRNO).", Components.interfaces.calIWcapErrors.WCAP_NO_ERRNO ); | function getWcapIcalErrno( icalRootComp ){ var prop = icalRootComp.getFirstProperty( "X-NSCP-WCAP-ERRNO" ); if (prop) return parseInt(prop.value); // some commands just respond with an empty calendar, no errno. WTF. throw Components.interfaces.calIWcapErrors.WCAP_NO_ERRNO;} |
if (icalRootComp == undefined) throw new Error("no VCALENDAR root component!"); | function getWcapIcalErrno( icalRootComp ){ if (icalRootComp == undefined) throw new Error("no VCALENDAR root component!"); var prop = icalRootComp.getFirstProperty( "X-NSCP-WCAP-ERRNO" ); if (prop) return parseInt(prop.value); else { // xxx todo: throw new Eror("missing element X-NSCP-W... | |
else { return 0; } | throw Components.interfaces.calIWcapErrors.WCAP_NO_ERRNO; | function getWcapIcalErrno( icalRootComp ){ if (icalRootComp == undefined) throw new Error("no VCALENDAR root component!"); var prop = icalRootComp.getFirstProperty( "X-NSCP-WCAP-ERRNO" ); if (prop) return parseInt(prop.value); else { // xxx todo: throw new Eror("missing element X-NSCP-W... |
throw Components.interfaces.calIWcapErrors.WCAP_NO_ERRNO; | throw new Components.Exception( "No WCAP errno (missing X-NSCP-WCAP-ERRNO).", Components.interfaces.calIWcapErrors.WCAP_NO_ERRNO ); | function getWcapXmlErrno( xml ){ var elem = xml.getElementsByTagName( "X-NSCP-WCAP-ERRNO" ); if (elem) { elem = elem.item(0); if (elem) return parseInt(elem.textContent); } // some commands just respond with an empty calendar, no errno. WTF. throw Components.interfaces.calIWcapEr... |
if (xml == undefined) throw new Error("no XML!"); var item = xml.getElementsByTagName("X-NSCP-WCAP-ERRNO").item(0); if (item) return parseInt(item.textContent); else { return 0; | var elem = xml.getElementsByTagName( "X-NSCP-WCAP-ERRNO" ); if (elem) { elem = elem.item(0); if (elem) return parseInt(elem.textContent); | function getWcapXmlErrno( xml ){ if (xml == undefined) throw new Error("no XML!"); var item = xml.getElementsByTagName("X-NSCP-WCAP-ERRNO").item(0); if (item) return parseInt(item.textContent); else { // xxx todo: throw new Eror("missing element X-NSCP-WCAP-ERRNO!"); // ... |
throw Components.interfaces.calIWcapErrors.WCAP_NO_ERRNO; | function getWcapXmlErrno( xml ){ if (xml == undefined) throw new Error("no XML!"); var item = xml.getElementsByTagName("X-NSCP-WCAP-ERRNO").item(0); if (item) return parseInt(item.textContent); else { // xxx todo: throw new Eror("missing element X-NSCP-WCAP-ERRNO!"); // ... | |
switch( weekNumber ) | var dateStringBundle = srGetStrBundle("chrome: if ( weekNumber >= 1 && weekNumber <= 4 ) | function getWeekNumberText( weekNumber ){ switch( weekNumber ) { case 1: return( "First" ); case 2: return( "Second" ); case 3: return( "Third" ); case 4: return( "Fourth" ); case 5: return( "Last" ); default: return( false ); }} |
case 1: return( "First" ); case 2: return( "Second" ); case 3: return( "Third" ); case 4: return( "Fourth" ); case 5: return( "Last" ); default: | return( dateStringBundle.GetStringFromName( "ordinal.name."+weekNumber) ); } else if( weekNumber == 5 ) { return( dateStringBundle.GetStringFromName( "ordinal.name.last" ) ); } else { | function getWeekNumberText( weekNumber ){ switch( weekNumber ) { case 1: return( "First" ); case 2: return( "Second" ); case 3: return( "Third" ); case 4: return( "Fourth" ); case 5: return( "Last" ); default: return( false ); }} |
var wrapCol = 72; try { var textEditor = window.editorShell.editor.QueryInterface(nsIPlaintextEditor); wrapCol = textEditor.wrapWidth; } catch (e) {} return wrapCol; | return gEditor.wrapWidth; | function GetWrapColumn(){ var wrapCol = 72; try { var textEditor = window.editorShell.editor.QueryInterface(nsIPlaintextEditor); wrapCol = textEditor.wrapWidth; } catch (e) {} return wrapCol;} |
itemUrl = this.getProperty(item, NC_NS+"URL"); itemName = this.getProperty(item, NC_NS+"Name"); | itemUrl = this.getProperty(item, gNC_NS+"URL"); itemName = this.getProperty(item, gNC_NS+"Name"); | getXferDataFromSelection: function (aSelection) { if (aSelection.length == 0) return null; var dataSet = new TransferDataSet(); var data, item, itemUrl, itemName, parent, name; for (var i=0; i<aSelection.length; ++i) { data = new TransferData(); item = aSelection.item[i].Value; ... |
var xmlDocument = domParser.parseFromString( "<libical/>", "text/xml" ); | var xmlDocument = domParser.parseFromString( "<libical/>", "application/xml" ); | function getXmlDocument ( eventList ){ // use the domparser to create the XML var domParser = new DOMParser; // start with one tag var xmlDocument = domParser.parseFromString( "<libical/>", "text/xml" ); // get the top tag, there will only be one. var topNodeList = xmlDocument.getElementsByTagNam... |
var controller = top.document.commandDispatcher.getControllerForCommand(command); | function goDoCommand(command){ var controller = top.document.commandDispatcher.getControllerForCommand(command); if ( controller && controller.isCommandEnabled(command)) controller.doCommand(command);} | |
if ( controller && controller.isCommandEnabled(command)) controller.doCommand(command); | try { var controller = top.document.commandDispatcher.getControllerForCommand(command); if ( controller && controller.isCommandEnabled(command)) controller.doCommand(command); } catch (e) { dump("An error occurred executing the "+command+" command\n"); } | function goDoCommand(command){ var controller = top.document.commandDispatcher.getControllerForCommand(command); if ( controller && controller.isCommandEnabled(command)) controller.doCommand(command);} |
var controller = top.document.commandDispatcher.getController(); if ( !controller ) controller = top.goDefaultController; | var controller = top.document.commandDispatcher.getControllerForCommand(command); | function goDoCommand(command){ var controller = top.document.commandDispatcher.getController(); if ( !controller ) controller = top.goDefaultController; if ( controller ) controller.DoCommand(command);} |
controller.DoCommand(command); | controller.doCommand(command); | function goDoCommand(command){ var controller = top.document.commandDispatcher.getController(); if ( !controller ) controller = top.goDefaultController; if ( controller ) controller.DoCommand(command);} |
dump(e+"\n") | function goDoCommand(command){ try { var controller = top.document.commandDispatcher.getControllerForCommand(command); if ( controller && controller.isCommandEnabled(command)) controller.doCommand(command); } catch (e) { dump("An error occurred executing the "+command+" command\n"); }} | |
"chrome,resizeable=no,modal,titlebar,centerscreen", | "chrome,resizable=no,modal,titlebar,centerscreen", | function goEditCardDialog(abURI, card, okCallback, abCardURI){ window.openDialog("chrome://messenger/content/addressbook/abEditCardDialog.xul", "", "chrome,resizeable=no,modal,titlebar,centerscreen", {abURI:abURI, card:card, okCallback:okCallback, abCardURI:abCardURI});} |
return; | function goEditListDialog(abURI, listURI){ return; window.openDialog("chrome://messenger/content/addressbook/abEditListDialog.xul", "", "chrome,resizeable=no", {abURI:abURI, listURI:listURI});} | |
"chrome,titlebar,resizeable=no", | "chrome,titlebar,resizable=no", | function goEditListDialog(abURI, listURI){ window.openDialog("chrome://messenger/content/addressbook/abEditListDialog.xul", "", "chrome,titlebar,resizeable=no", {abURI:abURI, listURI:listURI});} |
"chrome,resizeable=no,titlebar,modal,centerscreen", | "chrome,resizable=no,titlebar,modal,centerscreen", | function goNewCardDialog(selectedAB){ window.openDialog("chrome://messenger/content/addressbook/abNewCardDialog.xul", "", "chrome,resizeable=no,titlebar,modal,centerscreen", {selectedAB:selectedAB});} |
if ( selArray && (selArray.length == 1) ) | var length = selArray.length; if ( selArray && ((length == 0) || (length == 1)) ) | function GoNextMessage(nextFunction, startFromBeginning){ var tree = GetThreadTree(); var selArray = tree.selectedItems; if ( selArray && (selArray.length == 1) ) { var nextMessage = GetNextMessage(selArray[0], nextFunction, startFromBeginning); ChangeSelection(tree, nextMessage); }} |
var nextMessage = GetNextMessage(selArray[0], nextFunction, startFromBeginning); ChangeSelection(tree, nextMessage); | var currentMessage; if(length == 0) currentMessage = null; else currentMessage = selArray[0]; var nextMessage = GetNextMessage(tree, currentMessage, nextFunction, startFromBeginning); if(nextMessage && (nextMessage != currentMessage)) ChangeSelection(tree, nextMessage); | function GoNextMessage(nextFunction, startFromBeginning){ var tree = GetThreadTree(); var selArray = tree.selectedItems; if ( selArray && (selArray.length == 1) ) { var nextMessage = GetNextMessage(selArray[0], nextFunction, startFromBeginning); ChangeSelection(tree, nextMessage); }} |
currentTopMessage = FindFirstMessage(tree); | currentTopMessage = msgNavigationService.FindFirstMessage(tree); | function GoNextThread(type, startFromBeginning, gotoNextInThread){ if(messageView.showThreads) { var tree = GetThreadTree(); var selArray = tree.selectedItems; var length = selArray.length; if ( selArray && ((length == 0) || (length == 1)) ) { var currentMessage; if(length == 0) currentMessage = null; e... |
msgComposeService.OpenComposeWindowWithValues(null, 0, 0, null, null, null, null, null); | msgComposeService.OpenComposeWindowWithValues(null, 0, null, null, null, null, null, null); | function goOpenNewMessage(){ var msgComposeService = Components.classes["component://netscape/messengercompose"].getService(); msgComposeService = msgComposeService.QueryInterface(Components.interfaces.nsIMsgComposeService); msgComposeService.OpenComposeWindowWithValues(null, 0, 0, null, null, null, null, null); } |
function goPageSetup(printSettings) | function goPageSetup(domwin, printSettings) | function goPageSetup(printSettings){ try { if (printSettings == null) { alert("PrintSettings arg is null!"); } // This code calls the printoptions service to bring up the printoptions // dialog. This will be an xp dialog if the platform did not override // the ShowPrintSetupDialog method. var p... |
var printOptionsService = Components.classes["@mozilla.org/gfx/printoptions;1"] .getService(Components.interfaces.nsIPrintOptions); printOptionsService.ShowPrintSetupDialog(printSettings); } catch(e) { | var printingPromptService = Components.classes["@mozilla.org/embedcomp/printingprompt-service;1"] .getService(Components.interfaces.nsIPrintingPromptService); printingPromptService.showPageSetup(domwin, printSettings); return true; } catch(e) { return false; | function goPageSetup(printSettings){ try { if (printSettings == null) { alert("PrintSettings arg is null!"); } // This code calls the printoptions service to bring up the printoptions // dialog. This will be an xp dialog if the platform did not override // the ShowPrintSetupDialog method. var p... |
function goPageSetup() | function goPageSetup(printSettings) | function goPageSetup(){ // This code brings up the native page setup dialog (for platforms that // implement nsIPrintOptions.ShowNativeDialog()). var printOptionsService = Components.classes["@mozilla.org/gfx/printoptions;1"] .getService(Components.interfaces.nsIPrintOptio... |
var printOptionsService = Components.classes["@mozilla.org/gfx/printoptions;1"] .getService(Components.interfaces.nsIPrintOptions); printOptionsService.ReadPrefs(); printOptionsService.ShowNativeDialog(); printOptionsService.WritePrefs(); | window.openDialog("chrome: | function goPageSetup(){ // This code brings up the native page setup dialog (for platforms that // implement nsIPrintOptions.ShowNativeDialog()). var printOptionsService = Components.classes["@mozilla.org/gfx/printoptions;1"] .getService(Components.interfaces.nsIPrintOptio... |
var previousMessage = GetPreviousMessage(selArray[0], previousFunction, startFromEnd); ChangeSelection(tree, previousMessage); | var currentMessage = selArray[0]; var previousMessage = GetPreviousMessage(currentMessage, previousFunction, startFromEnd); if(previousMessage && (previousMessage != currentMessage)) ChangeSelection(tree, previousMessage); | function GoPreviousMessage(previousFunction, startFromEnd){ var tree = GetThreadTree(); var selArray = tree.selectedItems; if ( selArray && (selArray.length == 1) ) { var previousMessage = GetPreviousMessage(selArray[0], previousFunction, startFromEnd); ChangeSelection(tree, previousMessage); }} |
var appShell = Components.classes['@mozilla.org/appshell/appShellService;1'].getService(); appShell = appShell.QueryInterface( Components.interfaces.nsIAppShellService ); | var appStartup = Components.classes["@mozilla.org/toolkit/app-startup;1"]. getService(Components.interfaces.nsIAppStartup); | function goQuitApplication(){ var ObserverService = Components.classes["@mozilla.org/observer-service;1"].getService(); ObserverService = ObserverService.QueryInterface(Components.interfaces.nsIObserverService); if (ObserverService) { try { // XXX FIX! we should have a way to cancel a requested quit; see... |
nativeAppSupport = appShell.nativeAppSupport; | nativeAppSupport = appStartup.nativeAppSupport; | function goQuitApplication(){ var ObserverService = Components.classes["@mozilla.org/observer-service;1"].getService(); ObserverService = ObserverService.QueryInterface(Components.interfaces.nsIObserverService); if (ObserverService) { try { // XXX FIX! we should have a way to cancel a requested quit; see... |
appShell.quit(Components.interfaces.nsIAppShellService.eAttemptQuit); | appStartup.quit(Components.interfaces.nsIAppStartup.eAttemptQuit); | function goQuitApplication(){ var ObserverService = Components.classes["@mozilla.org/observer-service;1"].getService(); ObserverService = ObserverService.QueryInterface(Components.interfaces.nsIObserverService); if (ObserverService) { try { // XXX FIX! we should have a way to cancel a requested quit; see... |
var appShell = Components.classes['@mozilla.org/appshell/appShellService;1'].getService(); appShell = appShell.QueryInterface( Components.interfaces.nsIAppShellService ); var nativeAppSupport = null; try { nativeAppSupport = appShell.nativeAppSupport; } catch ( ex ) { } | var appStartup = Components.classes['@mozilla.org/toolkit/app-startup;1']. getService(Components.interfaces.nsIAppStartup); | function goQuitApplication(){ if (!canQuitApplication()) return; var windowManager = Components.classes['@mozilla.org/appshell/window-mediator;1'].getService(); var windowManagerInterface = windowManager.QueryInterface( Components.interfaces.nsIWindowMediator); var enumerator = windowManagerInterface.getEnum... |
appShell.quit(Components.interfaces.nsIAppShellService.eAttemptQuit); | appStartup.quit(Components.interfaces.nsIAppStartup.eAttemptQuit); | function goQuitApplication(){ if (!canQuitApplication()) return; var windowManager = Components.classes['@mozilla.org/appshell/window-mediator;1'].getService(); var windowManagerInterface = windowManager.QueryInterface( Components.interfaces.nsIWindowMediator); var enumerator = windowManagerInterface.getEnum... |
top.goDefaultController = controller; | top.controllers.appendController(controller); | function goSetDefaultController(controller){ top.goDefaultController = controller;} |
treeView.QueryInterface(nsITreeView).selection.clearSelection(); | function gotoDirectory(directory) { window.setCursor("wait"); try { populateAncestorList(directory); treeView.setDirectory(directory); document.getElementById("errorShower").selectedIndex = 0; } catch(ex) { document.getElementById("errorShower").selectedIndex = 1; } window.setCursor("auto"); treeView.... | |
populateAncestorList(directory); | document.getElementById("errorShower").selectedIndex = 0; | function gotoDirectory(directory) { window.setCursor("wait"); try { outlinerView.setDirectory(directory); populateAncestorList(directory); } catch(ex) { var errorTitle = gFilePickerBundle.getString("noPermissionTitle"); var errorMsg = gFilePickerBundle.getString("noPermissionError"); var promptService... |
var errorTitle = gFilePickerBundle.getString("noPermissionTitle"); var errorMsg = gFilePickerBundle.getString("noPermissionError"); var promptService = Components.classes["@mozilla.org/embedcomp/prompt-service;1"] .getService(Components.interfaces.nsIPromptService); promptService.alert(window, errorTitle, errorMsg); wi... | document.getElementById("errorShower").selectedIndex = 1; | function gotoDirectory(directory) { window.setCursor("wait"); try { outlinerView.setDirectory(directory); populateAncestorList(directory); } catch(ex) { var errorTitle = gFilePickerBundle.getString("noPermissionTitle"); var errorMsg = gFilePickerBundle.getString("noPermissionError"); var promptService... |
textInput.setAttribute("autocompletesearchparam", directory.path); | function gotoDirectory(directory) { window.setCursor("wait"); try { populateAncestorList(directory); treeView.setDirectory(directory); document.getElementById("errorShower").selectedIndex = 0; } catch(ex) { document.getElementById("errorShower").selectedIndex = 1; } window.setCursor("auto"); treeView.... | |
treeView.QueryInterface(nsITreeView).selection.clearSelection(); | function gotoDirectory(directory) { window.setCursor("wait"); try { populateAncestorList(directory); treeView.setDirectory(directory); document.getElementById("errorShower").selectedIndex = 0; } catch(ex) { document.getElementById("errorShower").selectedIndex = 1; } window.setCursor("auto"); treeView.... | |
outlinerView.setDirectory(directory.unicodePath); | outlinerView.setDirectory(directory); | function gotoDirectory(directory) { addToHistory(directory.unicodePath); window.setCursor("wait"); outlinerView.setDirectory(directory.unicodePath); window.setCursor("auto"); outlinerView.selection.clearSelection(); textInput.focus(); sfile = directory;} |
outlinerView.selection.clearSelection(); | outlinerView.QueryInterface(nsIOutlinerView).selection.clearSelection(); | function gotoDirectory(directory) { addToHistory(directory.unicodePath); window.setCursor("wait"); outlinerView.setDirectory(directory.unicodePath); window.setCursor("auto"); outlinerView.selection.clearSelection(); textInput.focus(); sfile = directory;} |
return false; | function gotoHistoryIndex( aEvent ) { var index = aEvent.target.getAttribute("index"); if (index) { appCore.gotoHistoryIndex(index); return true; } else { var id = aEvent.target.getAttribute("id"); if (id == "menuitem-back") BrowserBack(); else if (id == "me... | |
if (index) { | if (!index) return false; try { | function gotoHistoryIndex(aEvent){ var index = aEvent.target.getAttribute("index"); if (index) { getWebNavigation().gotoIndex(index); return true; } return false;} |
return true; | function gotoHistoryIndex(aEvent){ var index = aEvent.target.getAttribute("index"); if (index) { getWebNavigation().gotoIndex(index); return true; } return false;} | |
return false; | catch(ex) { return false; } return true; | function gotoHistoryIndex(aEvent){ var index = aEvent.target.getAttribute("index"); if (index) { getWebNavigation().gotoIndex(index); return true; } return false;} |
var controller = top.document.commandDispatcher.getControllerForCommand(command); var enabled = false; if ( controller ) enabled = controller.isCommandEnabled(command); goSetCommandEnabled(command, enabled); | try { var controller = top.document.commandDispatcher.getControllerForCommand(command); var enabled = false; if ( controller ) enabled = controller.isCommandEnabled(command); goSetCommandEnabled(command, enabled); } catch (e) { dump("An error occurred updating the "+command+" command\n"); } | function goUpdateCommand(command){ var controller = top.document.commandDispatcher.getControllerForCommand(command); var enabled = false; if ( controller ) enabled = controller.isCommandEnabled(command); goSetCommandEnabled(command, enabled);} |
var controller = top.document.commandDispatcher.getController(); if ( !controller ) controller = top.goDefaultController; | var controller = top.document.commandDispatcher.getControllerForCommand(command); | function goUpdateCommand(command){ var controller = top.document.commandDispatcher.getController(); if ( !controller ) controller = top.goDefaultController; var enabled = false; if ( controller ) enabled = controller.IsCommandEnabled(command); else goSetMenuValue(command, 'valueDefault'); goSetCommandEnabled(com... |
enabled = controller.IsCommandEnabled(command); | enabled = controller.isCommandEnabled(command); | function goUpdateCommand(command){ var controller = top.document.commandDispatcher.getController(); if ( !controller ) controller = top.goDefaultController; var enabled = false; if ( controller ) enabled = controller.IsCommandEnabled(command); else goSetMenuValue(command, 'valueDefault'); goSetCommandEnabled(com... |
try { document.getElementById('cmd_SwitchTextDirection').setAttribute('disabled', !document.commandDispatcher.focusedElement); } catch (e) {} | function goUpdateGlobalEditMenuItems(){ goUpdateCommand('cmd_undo'); goUpdateCommand('cmd_redo'); goUpdateCommand('cmd_cut'); goUpdateCommand('cmd_copy'); goUpdateCommand('cmd_paste'); goUpdateCommand('cmd_selectAll'); goUpdateCommand('cmd_delete');} | |
try { var changer = document.getElementById('cmd_SwitchTextDirection'); if (changer) changer.setAttribute('disabled', !document.commandDispatcher.focusedElement); } catch (e) {} | if (gShowBiDi) goUpdateCommand('cmd_switchTextDirection'); | function goUpdateGlobalEditMenuItems(){ goUpdateCommand('cmd_undo'); goUpdateCommand('cmd_redo'); goUpdateCommand('cmd_cut'); goUpdateCommand('cmd_copy'); goUpdateCommand('cmd_paste'); goUpdateCommand('cmd_selectAll'); goUpdateCommand('cmd_delete'); try { // XXX: implement controller for cmd_SwitchTextDirect... |
if (gEditor && !(flags & nsIPlaintextEditor.eEditorReadonlyMask) && | if (!(flags & nsIPlaintextEditor.eEditorReadonlyMask) && | function goUpdateTableMenuItems(commandset){ var enabled = false; var enabledIfTable = false; if (!gEditor) { dump("goUpdateTableMenuItems: too early, not initialized\n"); return; } var flags = gEditor.flags; if (gEditor && !(flags & nsIPlaintextEditor.eEditorReadonlyMask) && IsEditingRenderedHTML()) ... |
var selectedCountObj = new Object(); | function goUpdateTableMenuItems(commandset){ var enabled = false; var enabledIfTable = false; if (!gEditor) { dump("goUpdateTableMenuItems: too early, not initialized\n"); return; } var flags = gEditor.flags; if (gEditor && !(flags & nsIPlaintextEditor.eEditorReadonlyMask) && IsEditingRenderedHTML()) ... | |
var tableEditor = gEditor.QueryInterface(Components.interfaces.nsITableEditor); var element = 0; element = tableEditor.getSelectedOrParentTableElement(tagNameObj, selectedCountObj); if (element) | var element = new Object(); try { gEditor.getSelectedOrParentTableElement(element, tagNameObj); } catch(e) {} if (element && element.value) | function goUpdateTableMenuItems(commandset){ var enabled = false; var enabledIfTable = false; if (!gEditor) { dump("goUpdateTableMenuItems: too early, not initialized\n"); return; } var flags = gEditor.flags; if (gEditor && !(flags & nsIPlaintextEditor.eEditorReadonlyMask) && IsEditingRenderedHTML()) ... |
var element = { value: null }; | var element; | function goUpdateTableMenuItems(commandset){ var enabled = false; var enabledIfTable = false; if (!gEditor) { dump("goUpdateTableMenuItems: too early, not initialized\n"); return; } var flags = gEditor.flags; if (!(flags & nsIPlaintextEditor.eEditorReadonlyMask) && IsEditingRenderedHTML()) { var t... |
gEditor.getSelectedOrParentTableElement(element, tagNameObj); | element = gEditor.getSelectedOrParentTableElement(tagNameObj, {value:0}); | function goUpdateTableMenuItems(commandset){ var enabled = false; var enabledIfTable = false; if (!gEditor) { dump("goUpdateTableMenuItems: too early, not initialized\n"); return; } var flags = gEditor.flags; if (!(flags & nsIPlaintextEditor.eEditorReadonlyMask) && IsEditingRenderedHTML()) { var t... |
if (element && element.value) | if (element) | function goUpdateTableMenuItems(commandset){ var enabled = false; var enabledIfTable = false; if (!gEditor) { dump("goUpdateTableMenuItems: too early, not initialized\n"); return; } var flags = gEditor.flags; if (!(flags & nsIPlaintextEditor.eEditorReadonlyMask) && IsEditingRenderedHTML()) { var t... |
case "form": formView.addRow([elem.name, elem.method, elem.getAttribute("action"), elem]); break; | if (/^image$/i.test(elem.type)) imageView.addRow([getAbsoluteURL(elem.src, elem), gStrings.mediaInput, (elem.hasAttribute("alt")) ? elem.alt : gStrings.notSet, elem, false]); else if (/^submit$/i.test(elem.type)) linkView.addRow([elem.value || gStrings.linkSubmit, getAbsoluteURL(elem.form.getAttribute("action"), elem),... | function grabAll(elem){ var linktext; // check for background images, any node may have one var url = elem.ownerDocument.defaultView.getComputedStyle(elem, "").getPropertyCSSValue("background-image"); if (url && url.primitiveType == CSSPrimitiveValue.CSS_URI) { imageView.addRow([url.getStringValue(), gStrings.m... |
theList = theList.concat(aDocument.getElementsByTagName("embed"), aDocument.applets, aDocument.getElementsByTagName("object")); | theList = theList.concat(aDocument.getElementsByTagName("embed")); theList = theList.concat(aDocument.getElementsByTagName("object")); if (!navigator.javaEnabled()) theList = theList.concat(aDocument.applets); | function grabAllMedia(aWindow, aDocument){ var theList = []; if (aWindow && aWindow.frames.length > 0) { var num = aWindow.frames.length; for (var i = 0; i < num; i++) { var frame = aWindow.frames[i]; theList = theList.concat(grabAllMedia(frame, frame.document)); } } theList = theList.concat(... |
tests_run.getAttributeNode("value").nodeValue++; if (success) tests_passed.getAttributeNode("value").nodeValue++; else tests_failed.getAttributeNode("value").nodeValue++; | function handle_result(name,success){ var classname = (success ? "succeeded" : "failed"); var content_row = document.getElementById(name); if (content_row){ content_row.setAttribute("class",classname); }} | |
{ this.mSaveHdr = messenger.messageServiceFromURI(uri).messageURIToMsgHdr(uri); | handleAttachment: function(contentType, url, displayName, uri, isExternalAttachment) { // presentation level change....don't show vcards as external attachments in the UI. // libmime already renders them inline. if (contentType == "text/x-vcard") { var inlineAttachments = pref.getBool... | |
} | handleAttachment: function(contentType, url, displayName, uri, isExternalAttachment) { // presentation level change....don't show vcards as external attachments in the UI. // libmime already renders them inline. if (contentType == "text/x-vcard") { var inlineAttachments = pref.getBool... | |
var hdr = messenger.messageServiceFromURI(uri).messageURIToMsgHdr(uri); hdr.markHasAttachments(true); | this.mSaveHdr.markHasAttachments(true); | handleAttachment: function(contentType, url, displayName, uri, isExternalAttachment) { // presentation level change....don't show vcards as external attachments in the UI. // libmime already renders them inline. if (contentType == "text/x-vcard") { var inlineAttachments = pref.getBool... |
var displayName = displayName.replace(/ +/g, " "); | displayName = displayName.replace(/ +/g, " "); | handleAttachment: function(contentType, url, displayName, uri, isExternalAttachment) { // presentation level change....don't show vcards as external attachments in the UI. // libmime already renders them inline. try { if (!this.mSaveHdr) this.mSaveHdr = messenger.messageServi... |
var commandString = "OpenAttachURL('" + contentType + "', '" + url + "', '" + escape(displayName) + "', '" + uri + "')"; var screenDisplayName = displayName; if (notDownloaded) { screenDisplayName += " " + gMessengerBundle.getString("notDownloaded"); } AddAttachmentToMenu(screenDisplayName, commandString); var count... | var numAttachments = currentAttachments.length; currentAttachments.push (new createNewAttachmentInfo(contentType, url, displayName, uri, notDownloaded)); | handleAttachment: function(contentType, url, displayName, uri, notDownloaded) { // be sure to escape the display name before we insert it into the // method var commandString = "OpenAttachURL('" + contentType + "', '" + url + "', '" + escape(displayName) + "', '" + uri + "')"; var screenD... |
handleAttachment: function(url, displayName, uri, notDownloaded) | handleAttachment: function(contentType, url, displayName, uri, notDownloaded) | handleAttachment: function(url, displayName, uri, notDownloaded) { // be sure to escape the display name before we insert it into the // method var commandString = "OpenAttachURL('" + url + "', '" + escape(displayName) + "', '" + uri + "')"; if (notDownloaded) { displayName +... |
var commandString = "OpenAttachURL('" + url + "', '" + escape(displayName) + "', '" + uri + "')"; | var commandString = "OpenAttachURL('" + contentType + "', '" + url + "', '" + escape(displayName) + "', '" + uri + "')"; | handleAttachment: function(url, displayName, uri, notDownloaded) { // be sure to escape the display name before we insert it into the // method var commandString = "OpenAttachURL('" + url + "', '" + escape(displayName) + "', '" + uri + "')"; if (notDownloaded) { displayName +... |
if (contentType == "text/x-vcard") return; | handleAttachment: function(contentType, url, displayName, uri, notDownloaded) { currentAttachments.push (new createNewAttachmentInfo(contentType, url, displayName, uri, notDownloaded)); // if we have an attachment, set the MSG_FLAG_ATTACH flag on the hdr // this will cause the "message with attac... | |
if( aEvent.clickCount == 2 ) { if( aEvent.target.nodeName.toLowerCase() == "treecell" ) | if( aEvent.clickCount == 2 && aEvent.which == 1 ) { if( aEvent.target.nodeName.toLowerCase() == "treecell" && aEvent.target.parentNode.parentNode.nodeName.toLowerCase() != "treehead" ) | function HandleClickEvent( aEvent ){ if( aEvent.clickCount == 2 ) { if( aEvent.target.nodeName.toLowerCase() == "treecell" ) return onStart(); } else return showSelection(aEvent.target.parentNode.parentNode);} |
outlinerView.sort(sortType, sortOrder, false); | outlinerView.sort(sortType, sortOrder); | function handleColumnClick(columnID) { var sortType = convertColumnIDtoSortType(columnID); var sortOrder = (outlinerView.sortType == sortType) ? !outlinerView.reverseSort : false; outlinerView.sort(sortType, sortOrder, false); // set the sort indicator on the column we are sorted by var sortedColumn = document.g... |
setTitleFromFolder(folder,null); | function HandleDeleteOrMoveMsgCompleted(folder){ if (gNextMessageViewIndexAfterDelete != -2) { if (IsCurrentLoadedFolder(folder)) { var outlinerView = gDBView.QueryInterface(Components.interfaces.nsIOutlinerView); var outlinerSelection = outlinerView.selection; if (gNextMessageViewIndexAfterDel... | |
else { ClearMessagePane(); } | function HandleDeleteOrMoveMsgCompleted(folder){ if (IsCurrentLoadedFolder(folder)) { if (gNextMessageViewIndexAfterDelete != -1) { var outlinerView = gDBView.QueryInterface(Components.interfaces.nsIOutlinerView); var outlinerSelection = outlinerView.selection; viewSize = outlinerView.rowCount; ... | |
var threadTree = GetThreadTree(); | function HandleDeleteOrMoveMsgCompleted(folder){ if(IsCurrentLoadedFolder(folder)) { msgNavigationService.EnsureDocumentIsLoaded(document); if(gNextMessageAfterDelete) { var nextMessage = document.getElementById(gNextMessageAfterDelete); gNextMessageAfterDelete = null; SelectNextMessage(nextMessage); var thr... | |
if (gBatching) { gBatching = false; dump("XXX end tree batch (delete or move succeeded)\n"); } ThreadPaneSelectionChange(true); | function HandleDeleteOrMoveMsgCompleted(folder){ if(IsCurrentLoadedFolder(folder)) { msgNavigationService.EnsureDocumentIsLoaded(document); if(gNextMessageAfterDelete) { var nextMessage = document.getElementById(gNextMessageAfterDelete); gNextMessageAfterDelete = null; SelectNextMessage(nextMessage); var thr... | |
var folderUri = folderResource.Value; if ((folderUri == gCurrentFolderUri) && gCurrentMessageIsDeleted) | if ((folderResource.Value == gCurrentFolderUri) && gCurrentMessageIsDeleted) | function HandleDeleteOrMoveMsgCompleted(folder){ var folderResource = folder.QueryInterface(Components.interfaces.nsIRDFResource); if (!folderResource) return; var folderUri = folderResource.Value; if ((folderUri == gCurrentFolderUri) && gCurrentMessageIsDeleted) { gDBView.onDeleteCompleted(true); gCurrentMessag... |
outlinerSelection.select(gNextMessageViewIndexAfterDelete); | if (gNextMessageViewIndexAfterDelete >= 0) outlinerSelection.select(gNextMessageViewIndexAfterDelete); | function HandleDeleteOrMoveMsgCompleted(folder){ gDBView.onDeleteCompleted(true); if (gNextMessageViewIndexAfterDelete != -2) { if (IsCurrentLoadedFolder(folder)) { var outlinerView = gDBView.QueryInterface(Components.interfaces.nsIOutlinerView); var outlinerSelection = outlinerView.selection; ... |
gDBView.loadMessageByMsgKey(nextMstKey); | if (nextMstKey != -1) { gDBView.loadMessageByMsgKey(nextMstKey); } else { window.close(); } | function HandleDeleteOrMoveMsgCompleted(folder){ dump("In HandleDeleteOrMoveMsgCompleted\n"); var folderResource = folder.QueryInterface(Components.interfaces.nsIRDFResource); if(!folderResource) return; var folderUri = folderResource.Value; if((folderUri == gCurrentFolderUri) && gCurrentMessageIsDeleted) { gCurren... |
var outlinerView = gDBView.QueryInterface(Components.interfaces.nsIOutlinerView); | function HandleDeleteOrMoveMsgCompleted(folder){ if (IsCurrentLoadedFolder(folder)) { if (gNextMessageViewIndexAfterDelete != -1) { var outlinerView = gDBView.QueryInterface(Components.interfaces.nsIOutlinerView); var outlinerSelection = outlinerView.selection; viewSize = outlinerView.rowCount; ... | |
if(IsCurrentLoadedFolder(folder)) { if(gNextMessageAfterDelete) { gNextMessageAfterDelete = null; } } | if (gBatching) { gBatching = false; var threadTree = GetThreadTree(); dump("XXX end tree batch (delete or move failed)\n"); } | function HandleDeleteOrMoveMsgFailed(folder){ if(IsCurrentLoadedFolder(folder)) { if(gNextMessageAfterDelete) { gNextMessageAfterDelete = null; } }} |
ThreadPaneSelectionChange(true); | function HandleDeleteOrMoveMsgFailed(folder){ if(IsCurrentLoadedFolder(folder)) { if(gNextMessageAfterDelete) { gNextMessageAfterDelete = null; } }} | |
var folderUri = folderResource.Value; | function HandleDeleteOrMoveMsgFailed(folder){ var folderResource = folder.QueryInterface(Components.interfaces.nsIRDFResource); if (!folderResource) return; var folderUri = folderResource.Value; gDBView.onDeleteCompleted(false); if ((folderUri == gCurrentFolderUri) && gCurrentMessageIsDeleted) gCurrentMessa... | |
if ((folderUri == gCurrentFolderUri) && gCurrentMessageIsDeleted) | if ((folderResource.Value == gCurrentFolderUri) && gCurrentMessageIsDeleted) | function HandleDeleteOrMoveMsgFailed(folder){ var folderResource = folder.QueryInterface(Components.interfaces.nsIRDFResource); if (!folderResource) return; var folderUri = folderResource.Value; gDBView.onDeleteCompleted(false); if ((folderUri == gCurrentFolderUri) && gCurrentMessageIsDeleted) gCurrentMessa... |
var tbox = qsdata[prefix + "tb"]; var tname = qsdata[prefix + "tn"]; var baseline = (qsdata[prefix + "bl"] == "1"); | function handleHash(hash) { var qsdata = {}; for each (var s in hash.substring(1).split("&")) { var q = s.split("="); qsdata[q[0]] = q[1]; } var ctr = 1; while (("m" + ctr + "tb") in qsdata) { var prefix = "m" + ctr; var tbox = qsdata[prefix + "tb"]; var tname = qsdata[... | |
var m = addGraphForm({tinderbox: tbox, testname: tname, baseline: baseline}); | var m = addGraphForm(); m.handleQueryStringData(prefix, qsdata); | function handleHash(hash) { var qsdata = {}; for each (var s in hash.substring(1).split("&")) { var q = s.split("="); qsdata[q[0]] = q[1]; } var ctr = 1; while (("m" + ctr + "tb") in qsdata) { var prefix = "m" + ctr; var tbox = qsdata[prefix + "tb"]; var tname = qsdata[... |
var tstart = new Number(qsdata["spstart"]); var tend = new Number(qsdata["spend"]); Tinderbox.defaultLoadRange = [tstart, tend]; | function handleHash(hash) { var qsdata = {}; for each (var s in hash.substring(1).split("&")) { var q = s.split("="); qsdata[q[0]] = q[1]; } var ctr = 1; while (("m" + ctr + "tb") in qsdata) { var prefix = "m" + ctr; var tbox = qsdata[prefix + "tb"]; var tname = qsdata[... | |
tbo.selection.select(row.value); | tbo.view.selection.select(row.value); | function handleHistoryClick(aEvent){ var tbo = gHistoryTree.treeBoxObject; var row = { }, col = { }, obj = { }; tbo.getCellAt(aEvent.clientX, aEvent.clientY, row, col, obj); var x = { }, y = { }, w = { }, h = { }; tbo.getCoordsForCellItem(row.value, col.value, "image", x, y, w, h); var... |
var messageURI = GetLoadedMessage(); if (messageURI && (GetNumSelectedMessages() == 1)) SetUpJunkBar(messenger.messageServiceFromURI(messageURI).messageURIToMsgHdr(messageURI)); else SetUpJunkBar(null); | var msgHdr = null; if (GetNumSelectedMessages() == 1) msgHdr = messenger.messageServiceFromURI(loadedMessage).messageURIToMsgHdr(loadedMessage); gMessageNotificationBar.setJunkMsg(msgHdr); | function HandleJunkStatusChanged(folder){ // this might be the stand alone window, open to a message that was // and attachment (or on disk), in which case, we want to ignore it. var loadedMessage = GetLoadedMessage(); if (loadedMessage && (!(/type=x-message-display/.test(loadedMessage))) && IsCurrentLoadedFolder(f... |
var folder = GetLoadedMsgFolder(); var moveJunkMail = (folder && folder.server && folder.server.spamSettings) ? folder.server.spamSettings.manualMark : false; | var loadedFolder = GetLoadedMsgFolder(); var moveJunkMail = (loadedFolder && loadedFolder.server && loadedFolder.server.spamSettings) ? loadedFolder.server.spamSettings.manualMark : false; | function HandleJunkStatusChanged(folder){ // this might be the stand alone window, open to a message that was // and attachment (or on disk), in which case, we want to ignore it. var loadedMessage = GetLoadedMessage(); if (loadedMessage && (!(/type=application\/x-message-display/.test(loadedMessage))) && IsCurrentL... |
var sanitizeJunkMail = gPrefs.getBoolPref("mailnews.display.sanitizeJunkMail"); | var sanitizeJunkMail = gPrefBranch.getBoolPref("mailnews.display.sanitizeJunkMail"); | function HandleJunkStatusChanged(folder){ // this might be the stand alone window, open to a message that was // and attachment (or on disk), in which case, we want to ignore it. var loadedMessage = GetLoadedMessage(); if (loadedMessage && (!(/type=x-message-display/.test(loadedMessage))) && IsCurrentLoadedFolder(f... |
var changedJunkStatus = SetUpJunkBar(msgHdr); | var changedJunkStatus = gMessageNotificationBar.setJunkMsg(msgHdr); | function HandleJunkStatusChanged(folder){ // this might be the stand alone window, open to a message that was // and attachment (or on disk), in which case, we want to ignore it. var loadedMessage = GetLoadedMessage(); if (loadedMessage && (!(/type=x-message-display/.test(loadedMessage))) && IsCurrentLoadedFolder(f... |
SetUpJunkBar(null); | gMessageNotificationBar.setJunkMsg(null); | function HandleJunkStatusChanged(folder){ // this might be the stand alone window, open to a message that was // and attachment (or on disk), in which case, we want to ignore it. var loadedMessage = GetLoadedMessage(); if (loadedMessage && (!(/type=x-message-display/.test(loadedMessage))) && IsCurrentLoadedFolder(f... |
msgHdr = messenger.messageServiceFromURI(loadedMessage).messageURIToMsgHdr(loadedMessage); | msgHdr = messenger.msgHdrFromURI(loadedMessage); | function HandleJunkStatusChanged(folder){ // this might be the stand alone window, open to a message that was // and attachment (or on disk), in which case, we want to ignore it. var loadedMessage = GetLoadedMessage(); if (loadedMessage && (!(/type=application\/x-message-display/.test(loadedMessage))) && IsCurrentL... |
if (element.value != "" && event.keyCode == 13) event.preventBubble(); | if (element.value != "" && event.keyCode == 13) { event.stopPropagation(); event.preventDefault(); } | function handleKeyPress(element, event){ // allow dialog to close on enter if focused textbox has no value if (element.value != "" && event.keyCode == 13) event.preventBubble();} |
urlSecurityCheck(href, document); | function handleLinkClick(event, href, linkNode) { // Make sure we are allowed to open this URL urlSecurityCheck(href, document); switch (event.button) { case 0: // if left button clicked if (event.metaKey ... | |
if (openNewTabOrWindow(event, href, true)) | if (openNewTabOrWindow(event, href, linkNode.ownerDocument)) | function handleLinkClick(event, href, linkNode) { // Make sure we are allowed to open this URL urlSecurityCheck(href, document); switch (event.button) { case 0: // if left button clicked if (event.metaKey ... |
saveURL(href, linkNode ? gatherTextUnder(linkNode) : "", "SaveLinkTitle", false, getReferrer(document)); | saveURL(href, gatherTextUnder(linkNode), "SaveLinkTitle", false, getReferrer(linkNode.ownerDocument)); | function handleLinkClick(event, href, linkNode) { // Make sure we are allowed to open this URL urlSecurityCheck(href, document); switch (event.button) { case 0: // if left button clicked if (event.metaKey ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.