rem
stringlengths
0
126k
add
stringlengths
0
441k
context
stringlengths
15
136k
else { outlinerSelection.clearSelection(); setTitleFromFolder(folder,null); ClearMessagePane(); }
function HandleDeleteOrMoveMsgCompleted(folder){ gDBView.onDeleteCompleted(true); if (gNextMessageViewIndexAfterDelete != -2) { if (IsCurrentLoadedFolder(folder)) { var outlinerView = gDBView.QueryInterface(Components.interfaces.nsIOutlinerView); var outlinerSelection = outlinerView.selection; ...
if (gNextMessageViewIndexAfterDelete != -2) { if (IsCurrentLoadedFolder(folder))
if (!IsCurrentLoadedFolder(folder)) { gNextMessageViewIndexAfterDelete = -2; return; } var treeView = gDBView.QueryInterface(Components.interfaces.nsITreeView); var treeSelection = treeView.selection; if (gNextMessageViewIndexAfterDelete == -2) { if (treeSelection.count == 0) { treeSelection.clearSelection();...
function HandleDeleteOrMoveMsgCompleted(folder){ // you might not have a db view. this can happen if // biff fires when the 3 pane is set to account central. if (!gDBView) return; gDBView.onDeleteCompleted(true); if (gNextMessageViewIndexAfterDelete != -2) { if (IsCurrentLoadedFolder(folder)) { v...
var treeView = gDBView.QueryInterface(Components.interfaces.nsITreeView); var treeSelection = treeView.selection; if (gNextMessageViewIndexAfterDelete != nsMsgViewIndex_None)
viewSize = treeView.rowCount; if (gNextMessageViewIndexAfterDelete >= viewSize)
function HandleDeleteOrMoveMsgCompleted(folder){ // you might not have a db view. this can happen if // biff fires when the 3 pane is set to account central. if (!gDBView) return; gDBView.onDeleteCompleted(true); if (gNextMessageViewIndexAfterDelete != -2) { if (IsCurrentLoadedFolder(folder)) { v...
viewSize = treeView.rowCount; if (gNextMessageViewIndexAfterDelete >= viewSize) { if (viewSize > 0) gNextMessageViewIndexAfterDelete = viewSize - 1; else { gNextMessageViewIndexAfterDelete = nsMsgViewIndex_None;
if (viewSize > 0) gNextMessageViewIndexAfterDelete = viewSize - 1; else { gNextMessageViewIndexAfterDelete = nsMsgViewIndex_None;
function HandleDeleteOrMoveMsgCompleted(folder){ // you might not have a db view. this can happen if // biff fires when the 3 pane is set to account central. if (!gDBView) return; gDBView.onDeleteCompleted(true); if (gNextMessageViewIndexAfterDelete != -2) { if (IsCurrentLoadedFolder(folder)) { v...
treeSelection.clearSelection(); setTitleFromFolder(folder,null); ClearMessagePane(); }
treeSelection.clearSelection(); setTitleFromFolder(folder, null); ClearMessagePane(); UpdateMailToolbar("delete from current view, 0 rows left");
function HandleDeleteOrMoveMsgCompleted(folder){ // you might not have a db view. this can happen if // biff fires when the 3 pane is set to account central. if (!gDBView) return; gDBView.onDeleteCompleted(true); if (gNextMessageViewIndexAfterDelete != -2) { if (IsCurrentLoadedFolder(folder)) { v...
NotifyObservers(window, "mail:updateToolbarItems", null); }
UpdateMailToolbar("delete from current view, at least one row selected");
function HandleDeleteOrMoveMsgCompleted(folder){ // you might not have a db view. this can happen if // biff fires when the 3 pane is set to account central. if (!gDBView) return; gDBView.onDeleteCompleted(true); if (gNextMessageViewIndexAfterDelete != -2) { if (IsCurrentLoadedFolder(folder)) { v...
gNextMessageViewIndexAfterDelete = -2;
function HandleDeleteOrMoveMsgCompleted(folder){ // you might not have a db view. this can happen if // biff fires when the 3 pane is set to account central. if (!gDBView) return; gDBView.onDeleteCompleted(true); if (gNextMessageViewIndexAfterDelete != -2) { if (IsCurrentLoadedFolder(folder)) { v...
gNextMessageViewIndexAfterDelete = -2;
function HandleDeleteOrMoveMsgCompleted(folder){ // you might not have a db view. this can happen if // biff fires when the 3 pane is set to account central. if (!gDBView) return; gDBView.onDeleteCompleted(true); if (gNextMessageViewIndexAfterDelete != -2) { if (IsCurrentLoadedFolder(folder)) { v...
var languageName = node.getAttribute('value');
var languageName = node.getAttribute('label');
function HandleDoubleClick(node){ var languageId = node.id; var languageName = node.getAttribute('value'); if (languageName && languageName.length > 0) { if (!LangAlreadyActive(languageId)) { AddTreeItem(window.opener.document, active_languages_treeroot, languageId, languageName); } window.close();...
AddTreeItem(window.opener.document, active_languages_treeroot, languageId, languageName);
AddListItem(window.opener.document, active_languages, languageId, languageName);
function HandleDoubleClick(node){ var languageId = node.id; var languageName = node.getAttribute('label'); if (languageName && languageName.length > 0) { if (!LangAlreadyActive(languageId)) { AddTreeItem(window.opener.document, active_languages_treeroot, languageId, languageName); } window.close()...
if (!this._window) { return; }
handleEvent: function(event) { if (event.target.ownerDocument != this._document) { LOG("FeedWriter.handleEvent: Someone passed the feed writer as a listener to the events of another document!"); return; } switch(event.type) { case "command" : { switch(event.target.id) { case "s...
if (!this._window) { return; }
event = new XPCNativeWrapper(event);
handleEvent: function(event) { if (!this._window) { // this._window is null unless this.write was called with a trusted // window object. return; } if (event.target.ownerDocument != this._document) { LOG("FeedWriter.handleEvent: Someone passed the feed writer as a listener to the events o...
lowerCaseHeaderName = headerName.toLowerCase();
var lowerCaseHeaderName = headerName.toLowerCase();
handleHeader: function(headerName, headerValue) { // WARNING: if you are modifying this function, make sure you do not do *ANY* // dom manipulations which would trigger a reflow. This method gets called // for every rfc822 header in the message being displayed. If you introduce a reflow // ...
case 13: onStart(); break;
function HandleKeyEvent( aEvent ){ switch( aEvent.keyCode ) { case 13: onStart(); break; case 46: if( profileManagerMode != "manager" ) return; ConfirmDelete(); break; case "VK_F2": if( profileManagerMode != "manager" ) return; RenameProfile(); break; }}
d.textContent = r[2].replace(/[\n\r]$/, '');
d.textContent = r[2];
handleLog: function(aLog, aDlg, aLocale) { var df = document.createDocumentFragment(); for each (var r in aLog) { var d = document.createElement('pre'); d.className = 'log-row ' + r[1]; // XXX filter on r[0:1] d.textContent = r[2].replace(/[\n\r]$/, ''); df.appendChild(d); } aDlg....
if (SelectedMessagesAreJunk()) return;
function HandleMDNResponse(aUrl){ if (!aUrl) return; var msgFolder = aUrl.folder; var msgURI = GetLoadedMessage(); if (!msgFolder || !msgURI) return; if (IsNewsMessage(msgURI)) return; var msgHdr = messenger.messageServiceFromURI(msgURI).messageURIToMsgHdr(msgURI); var mimeHdr = aUrl.mimeHeaders; // I...
this.cache.put(o._mURL, obj);
handleSuccess : function(o) { if (o.responseText === undefined) throw "expected response text in handleSuccess"; if (o.callback) { var obj = eval('('+o.responseText+')'); o.callback(obj); delete o.callback; } },
addToUrlbarHistory();
addToUrlbarHistory(gURLBar.value);
function handleURLBarCommand(aUserAction, aTriggeringEvent){ try { addToUrlbarHistory(); } catch (ex) { // Things may go wrong when adding url to session history, // but don't let that interfere with the loading of the url. } BrowserLoadURL(aTriggeringEvent); }
addToUrlbarHistory();
addToUrlbarHistory(gURLBar.value);
function handleURLBarCommand(aTriggeringEvent){ var postData = { }; canonizeUrl(aTriggeringEvent, postData); try { addToUrlbarHistory(); } catch (ex) { // Things may go wrong when adding url to session history, // but don't let that interfere with the loading of the url. } BrowserLoadURL(aTriggeringEvent...
SetPageProxyState("valid");
function handleURLBarRevert(){ var url = _content.location.href; var throbberElement = document.getElementById("navigator-throbber"); var isScrolling = gURLBar.userAction == "scrolling"; // don't revert to last valid url unless page is NOT loading // and user is NOT key-scrolling through autocomplete list if (!...
SetPageProxyState("valid");
SetPageProxyState("valid", null);
function handleURLBarRevert(){ var url = _content.location.href; var throbberElement = document.getElementById("navigator-throbber"); var isScrolling = gURLBar.userAction == "scrolling"; // don't revert to last valid url unless page is NOT loading // and user is NOT key-scrolling through autocomplete list if (!...
if (aArc.EqualsNode(this.kNC_child)) {
if (aArc.EqualsNode(this.kNC_child) || aArc.EqualsNode(this.kNC_recursiveChild)) { var listType = (aArc.EqualsNode(this.kNC_child) ? "flat.messagelist.ldap" : "recursive.messagelist.ldap");
hasArcOut: function(aSource, aArc) { if (DEBUG) { dump("hasArcOut() called with args: \n\t" + aSource.Value + "\n\t" + aArc.Value + "\n\n"); } var delegate; if (aArc.EqualsNode(this.kNC_child)) { try { delegate = aSource.GetDelegate("...
delegate = aSource.GetDelegate("messagelist.ldap", Components.interfaces.nsISupportsArray); } catch (e) {
delegate = aSource.GetDelegate(listType, Components.interfaces.nsISupportsArray); } catch (e) {
hasArcOut: function(aSource, aArc) { if (DEBUG) { dump("hasArcOut() called with args: \n\t" + aSource.Value + "\n\t" + aArc.Value + "\n\n"); } var delegate; if (aArc.EqualsNode(this.kNC_child)) { try { delegate = aSource.GetDelegate("...
else { var refStart = aArc.Value.indexOf("#"); if (aArc.Value.slice(0, refStart + 1) == LDAPATTR_NAMESPACE_URI) { try { delegate = aSource.GetDelegate("message.ldap", Components.interfaces.nsILDAPMessage); } catch (e) { } if (delegate != null) { var attributeName = aArc.Value.slice(refStart + 1); var attributeArray = t...
else if (aArc.EqualsNode(this.kNC_DN)) { try { delegate = aSource.GetDelegate("message.ldap", Components.interfaces.nsILDAPMessage);
hasArcOut: function(aSource, aArc) { if (DEBUG) { dump("hasArcOut() called with args: \n\t" + aSource.Value + "\n\t" + aArc.Value + "\n\n"); } var delegate; if (aArc.EqualsNode(this.kNC_child)) { try { delegate = aSource.GetDelegate("...
return false;
var refStart = aArc.Value.indexOf("#"); if (aArc.Value.slice(0, refStart + 1) == LDAPATTR_NAMESPACE_URI) { try { delegate = aSource.GetDelegate("message.ldap", Components.interfaces.nsILDAPMessage); } catch (e) { } if (delegate != null) { var attributeName = aArc.Value.slice(refStart + 1); var attributeArray = this.get...
hasArcOut: function(aSource, aArc) { if (DEBUG) { dump("hasArcOut() called with args: \n\t" + aSource.Value + "\n\t" + aArc.Value + "\n\n"); } var delegate; if (aArc.EqualsNode(this.kNC_child)) { try { delegate = aSource.GetDelegate("...
var refStart = aArc.Value.indexOf("#"); if (aArc.Value.slice(0, refStart + 1) == LDAPATTR_NAMESPACE_URI) { try { delegate = aSource.GetDelegate("message.ldap", Components.interfaces.nsILDAPMessage); } catch (e) { } if (delegate != null) { var attributeName = aArc.Value.slice(refStart + 1); var attributeArray = this.get...
var refStart = aArc.Value.indexOf("#"); if (aArc.Value.slice(0, refStart + 1) == LDAPATTR_NAMESPACE_URI) { try { delegate = aSource.GetDelegate("message.ldap", Components.interfaces.nsILDAPMessage); } catch (e) { } if (delegate != null) { var attributeName = aArc.Value.slice(refStart + 1); var attributeArray = this.get...
hasArcOut: function(aSource, aArc) { if (DEBUG) { dump("hasArcOut() called with args: \n\t" + aSource.Value + "\n\t" + aArc.Value + "\n\n"); } var delegate; if (aArc.EqualsNode(this.kNC_child) || aArc.EqualsNode(this.kNC_recursiveChild)) { ...
if (aSource.EqualsNode(this.kRasputin) && aProperty.EqualsNode(this.kNC_child) && aTarget.EqualsNode(this.kElvis) && aTruthValue) { return true; }
HasAssertion: function(aSource, aProperty, aTarget, aTruthValue) { // figure out what kind of nsIRDFNode aTarget is // XXXdmose: code incomplete // aTarget = aTarget.QueryInterface(Components.interfaces.nsIRDFResource); // spew debugging info // if (DEBUG) { dump("HasAssertion() called with args: \n\t" +...
#if PLUGIN_TYPE_MANAGER var plugins = { }; var catman = Components.classes["@mozilla.org/categorymanager;1"].getService(Components.interfaces.nsICategoryManager); var types = catman.enumerateCategory("Gecko-Content-Viewers"); while (types.hasMoreElements()) { var currType = types.getNext().QueryInterface(Components.i...
function HelperApps(){ if (!gRDF) gRDF = Components.classes["@mozilla.org/rdf/rdf-service;1"].getService(Components.interfaces.nsIRDFService); const mimeTypes = "UMimTyp"; var fileLocator = Components.classes["@mozilla.org/file/directory_service;1"].getService(Components.interfaces.nsIProperties); var file ...
this.fileName = MSG_HELP_TITLE;
this.fileName = "x-jsd:help";
function HelpText (){ this.tabWidth = console.prefs["sourcetext.tab.width"]; this.fileName = MSG_HELP_TITLE; this.reloadSource();}
var disabledItems = ['cmd_close', 'Browser:SendPage', 'Browser:EditPage',
var disabledItems = ['cmd_close', 'Browser:SendPage', 'Browser:EditPage', 'Browser:PrintSetup',
function hiddenWindowStartup(){ // focus the hidden window window.focus(); // Disable menus which are not appropriate var disabledItems = ['cmd_close', 'Browser:SendPage', 'Browser:EditPage', /*'Browser:PrintSetup', 'Browser:PrintPreview',*/ 'Browser:Print', 'canGoBack', 'canGoForward', 'Brows...
'viewThreaded', 'viewAll', 'viewUnread', 'viewLabelMenuItem1',
'viewThreaded', 'viewMessageViewMenu', 'viewAll', 'viewUnread', 'viewLabelMenuItem1',
function hiddenWindowStartup(){ // focus the hidden window window.focus(); // Disable menus which are not appropriate var disabledItems = ['newNewMsgCmd', 'menu_newFolder', 'newAccountMenuItem', 'menu_close', 'menu_sendunsentmsgs', 'menu_subscribe', 'menu_renameFolder', 'menu_selectAll', ...
window.focus();
function hiddenWindowStartup(){ // Disable menus which are not appropriate var disabledItems = ['cmd_close', 'Browser:SendPage', 'Browser:EditPage', /*'Browser:PrintSetup', 'Browser:PrintPreview',*/ 'Browser:Print', 'canGoBack', 'canGoForward', 'Browser:Home', 'Browser:AddBookmark', 'cmd_undo', ...
'cmd_printSetup',
'Browser:SavePage', 'cmd_printSetup',
function hiddenWindowStartup(){ // focus the hidden window window.focus(); // Disable menus which are not appropriate var disabledItems = ['cmd_close', 'Browser:SendPage', 'Browser:EditPage', 'cmd_printSetup', /*'Browser:PrintPreview',*/ 'Browser:Print', 'canGoBack', 'can...
if (this.mTarget.localName == "menuitem" || this.mTarget.localName == "menu") {
if (this.mTarget.localName == "menu" || this.mTarget.localName == "menuitem" || this.mTarget.localName == "menuseparator") {
hide: function () { if (!this.mTarget) return; // special case for the menu items... if (this.mTarget.localName == "menuitem" || this.mTarget.localName == "menu") { this.hideMenuitem(); return; } var insertion = document.getElementById("insertion-feedback"); insertion.hidden ...
window.frames["accountCentralPane"].location = "about:blank"; accountCentralBox.setAttribute("collapsed", "true"); gSearchBox.removeAttribute("collapsed"); messagesBox.removeAttribute("collapsed"); gAccountCentralLoaded = false;
function HideAccountCentral(){ try { switch (gPaneConfig) { case 0: window.frames["accountCentralPane"].location = "about:blank"; accountCentralBox.setAttribute("collapsed", "true"); gSearchBox.removeAttribute("collapsed"); messa...
window.frames["accountCentralPane"].location = "about:blank"; accountCentralBox.setAttribute("collapsed", "true"); var messagePaneBox = document.getElementById("messagepanebox"); messagePaneBox.removeAttribute("collapsed"); var searchAndThreadPaneBox = document.getElementById("searchAndthreadpaneBox"); searchAndThr...
gThreadPaneSplitter.removeAttribute("collapsed");
function HideAccountCentral(){ try { switch (gPaneConfig) { case 0: window.frames["accountCentralPane"].location = "about:blank"; accountCentralBox.setAttribute("collapsed", "true"); gSearchBox.removeAttribute("collapsed"); messa...
document.getElementById("key_toggleMessagePane").removeAttribute("disabled");
function HideAccountCentral(){ try { window.frames["accountCentralPane"].location.href = "about:blank"; document.getElementById("accountCentralBox").collapsed = true; GetThreadTree().collapsed = false; gSearchBox.collapsed = false; var threadPaneSplitter = document.getElementByI...
debug("hideElement: hiding " + elementId);
function hideElement(elementId){ try { debug("hideElement: hiding " + elementId); document.getElementById(elementId).setAttribute("hidden", "true"); } catch (e) { dump("hideElement: Couldn't set hidden attribute on " + elementId + "\n"); }}
var goStartPageSeparator = document.getElementById('goStartPageSeparator');
var goStartPageSeparator = document.getElementById('goNextSeparator');
function HideMenus(){ var message_menuitem=document.getElementById('menu_showMessage'); if (message_menuitem) message_menuitem.setAttribute("hidden", "true"); var showSearchToolbar = document.getElementById('menu_showSearchToolbar'); if (showSearchToolbar) showSearchToolbar.setAttribute("hidden", "true"); var showSea...
var showSearchToolbar = document.getElementById('menu_showSearchToolbar'); if(showSearchToolbar) showSearchToolbar.setAttribute("hidden", "true"); var showSearch_showMessage_Separator = document.getElementById('menu_showSearch_showMessage_Separator'); if(showSearch_showMessage_Separator) showSearch_showMessage_Separat...
function HideMenus(){ var message_menuitem=document.getElementById('menu_showMessage'); if(message_menuitem) message_menuitem.setAttribute("hidden", "true"); var expandOrCollapseMenu = document.getElementById('menu_expandOrCollapse'); if(expandOrCollapseMenu) expandOrCollapseMenu.setAttribute("hidden", "true"); var r...
var renameFolderMenu = document.getElementById('menu_renameFolder'); if(renameFolderMenu) renameFolderMenu.setAttribute("hidden", "true");
function HideMenus(){ var message_menuitem=document.getElementById('menu_showMessage'); if(message_menuitem) message_menuitem.setAttribute("hidden", "true"); var expandOrCollapseMenu = document.getElementById('menu_expandOrCollapse'); if(expandOrCollapseMenu) expandOrCollapseMenu.setAttribute("hidden", "true");}
boxToHide.style.visibility = "collapse";
boxToHide.setAttribute("hidden", "true");
function hideShowSmtpSettings(smtpServer) { var noSmtpBox = document.getElementById("noSmtp"); var haveSmtpBox = document.getElementById("haveSmtp"); var boxToHide; var boxToShow; if (smtpServer && smtpServer.hostname && smtpServer.hostname != "") { // we have a hostname, so show the static text boxTo...
boxToShow.style.visibility = "visible";
boxToShow.removeAttribute("hidden");
function hideShowSmtpSettings(smtpServer) { var noSmtpBox = document.getElementById("noSmtp"); var haveSmtpBox = document.getElementById("haveSmtp"); var boxToHide; var boxToShow; if (smtpServer && smtpServer.hostname && smtpServer.hostname != "") { // we have a hostname, so show the static text boxTo...
document.getElementById("view_hidetoolbar").setAttribute("value", GetString("HideToolbar"));
document.getElementById("view_hidetoolbar").setAttribute("label", GetString("HideToolbar"));
function hideToolbar(){ // Check to see if toolbar is already hidden if (tHide){ // If it is show it document.getElementById("toolbar").setAttribute("collapsed", "false"); // Set the menu items text back to "Hide Toolbar" document.getElementById("view_hidetoolbar").setAttribute("value", GetString("HideToo...
document.getElementById("view_hidetoolbar").setAttribute("value", GetString("ShowToolbar"));
document.getElementById("view_hidetoolbar").setAttribute("label", GetString("ShowToolbar"));
function hideToolbar(){ // Check to see if toolbar is already hidden if (tHide){ // If it is show it document.getElementById("toolbar").setAttribute("collapsed", "false"); // Set the menu items text back to "Hide Toolbar" document.getElementById("view_hidetoolbar").setAttribute("value", GetString("HideToo...
defaultSet = defaultSet.replace(/mailviews-container/i, "");
function HideToolbarButtons(){ // How can we remove these two items from the palette as well? var mailToolbar = document.getElementById('mail-bar2'); if (mailToolbar) { var defaultSet = mailToolbar.getAttribute("defaultset"); defaultSet = defaultSet.replace(/search-container/i, ""); defaultSet = defaultSe...
var searchContainer = document.getElementById('search-container'); if (searchContainer) searchContainer.parentNode.removeChild(searchContainer); var toolbarPalette = document.getElementById('mail-toolbox').palette; toolbarPalette.removeChild(toolbarPalette.getElementsByAttribute('id', 'search-container')[0]); toolb...
function HideToolbarButtons(){ // How can we remove these two items from the palette as well? var mailToolbar = document.getElementById('mail-bar2'); if (mailToolbar) { var defaultSet = mailToolbar.getAttribute("defaultset"); defaultSet = defaultSet.replace(/search-container/i, ""); defaultSet = defaultSe...
imageEl.style.setProperty("-moz-opacity", "1.0", true);
imageEl.style.setProperty("opacity", "1.0", true);
function highContrast(){ if (highCont == true){ frameDoc.getElementById("bgDiv").style.background = "url('chrome://editor/skin/images/Map_checker.gif')"; frameDoc.getElementById("bgDiv").style.backgroundColor = "white"; imageEl.style.setProperty("-moz-opacity", "1.0", true); document.getElementById("Map:Co...
imageEl.style.setProperty("-moz-opacity", ".3", true);
imageEl.style.setProperty("opacity", ".3", true);
function highContrast(){ if (highCont == true){ frameDoc.getElementById("bgDiv").style.background = "url('chrome://editor/skin/images/Map_checker.gif')"; frameDoc.getElementById("bgDiv").style.backgroundColor = "white"; imageEl.style.setProperty("-moz-opacity", "1.0", true); document.getElementById("Map:Co...
GroupBy(gHistoryGrouping);
UpdateTreeGrouping();
function HistoryCommonInit(){ gHistoryTree = document.getElementById("historyTree"); gDeleteByHostname = document.getElementById("menu_deleteByHostname"); gDeleteByDomain = document.getElementById("menu_deleteByDomain"); gHistoryBundle = document.getElementById("historyBundle"); gHistoryStatus = ...
if (gHistoryStatus) gHistoryTree.focus();
function HistoryCommonInit(){ gHistoryTree = document.getElementById("historyTree"); gDeleteByHostname = document.getElementById("menu_deleteByHostname"); gDeleteByDomain = document.getElementById("menu_deleteByDomain"); gHistoryBundle = document.getElementById("historyBundle"); gHistoryStatus = ...
if ("arguments" in window && window.arguments[0] && window.arguments.length >= 1) { var uri = window.arguments[0]; gHistoryTree.setAttribute("ref", uri); if (uri.substring(0,5) == "find:" && !(window.arguments.length > 1 && window.arguments[1] == "newWindow")) { var windowNode = document.getElementById("history-wind...
var mode = document.getElementById("viewButton").getAttribute("selectedsort"); if (mode == "site") document.getElementById("bysite").setAttribute("checked", "true"); else if (mode == "visited") document.getElementById("byvisited").setAttribute("checked", "true"); else document.getElementById("byday").setAttribute("chec...
function HistoryCommonInit(){ gHistoryTree = document.getElementById("historyTree"); gDeleteByHostname = document.getElementById("menu_deleteByHostname"); gDeleteByDomain = document.getElementById("menu_deleteByDomain"); gHistoryBundle = document.getElementById("historyBundle"); gSearchBox = do...
gPrefService = Components.classes["@mozilla.org/preferences;1"] .getService(Components.interfaces.nsIPref);
gPrefService = Components.classes["@mozilla.org/preferences-service;1"] .getService(Components.interfaces.nsIPrefBranch);
function HistoryInit(){ gHistoryOutliner = document.getElementById("historyOutliner"); gDeleteByHostname = document.getElementById("menu_deleteByHostname"); gDeleteByDomain = document.getElementById("menu_deleteByDomain"); gHistoryBundle = document.getElementById("historyBundle"); gHistoryStatus = ...
var grouping = gPrefService.GetCharPref("browser.history.grouping");
var grouping = gPrefService.getCharPref("browser.history.grouping");
function HistoryInit(){ gHistoryOutliner = document.getElementById("historyOutliner"); gDeleteByHostname = document.getElementById("menu_deleteByHostname"); gDeleteByDomain = document.getElementById("menu_deleteByDomain"); gHistoryBundle = document.getElementById("historyBundle"); gHistoryStatus = ...
if (!gHistoryStatus) { var currentIndex = gHistoryTree.currentIndex;
if (!gHistoryStatus && aEvent.button == 0) {
function historyOnClick(aEvent){ // This is kind of a hack but matches the currently implemented behaviour. // If a status bar is not present, assume we're in sidebar mode, and thus single clicks on containers // will open the container. Single clicks on non-containers are handled below in historyOnSelect. if (!gH...
if (row.value >= 0 && isContainer(gHistoryTree, row.value))
if (row.value >= 0 && col.value && elt.value != "twisty" && isContainer(gHistoryTree, row.value))
function historyOnClick(aEvent){ // This is kind of a hack but matches the currently implemented behaviour. // If a status bar is not present, assume we're in sidebar mode, and thus single clicks on containers // will open the container. Single clicks on non-containers are handled below in historyOnSelect. if (!gH...
OpenURL(false);
OpenURL("current");
function historyOnClick(aEvent){ // This is kind of a hack but matches the currently implemented behaviour. // If a status bar is not present, assume we're in sidebar mode, and thus single clicks on containers // will open the container. Single clicks on non-containers are handled below in historyOnSelect. if (!gH...
var url = rowIsContainer ? gHistoryTree.treeBoxObject.view.getCellText(currentIndex, "URL") : null;
var url = rowIsContainer ? "" : gHistoryTree.treeBoxObject.view.getCellText(currentIndex, "URL");
function historyOnSelect(){ // every time selection changes, save the last hostname gLastHostname = ""; gLastDomain = ""; var match; var currentIndex = gHistoryTree.currentIndex; var rowIsContainer = gHistoryGrouping != "none" && currentIndex >= 0 && isContainer(gHistoryTree, currentIndex); var url...
match = url.match(/^.*?:\/\/(?:([^\/:]*)(?::([^\/:]*))?@)?([^\/:]*)(?::([^\/:]*))?(.*)$/); if (match && match.length>1) gLastHostname = match[3]; gHistoryStatus.label = url; } else { gHistoryStatus.label = "";
if (!gIOService) gIOService = Components.classes['@mozilla.org/network/io-service;1'] .getService(Components.interfaces.nsIIOService); try { gLastHostname = gIOService.newURI(url, null, null).host; match = gLastHostname.match(/([^.]+\.[^.]+$)/); if (match) gLastDomain = match[1]; } catch (e) {}
function historyOnSelect(){ // every time selection changes, save the last hostname gLastHostname = ""; gLastDomain = ""; var match; var currentIndex = gHistoryTree.currentIndex; var rowIsContainer = gHistoryGrouping != "none" && currentIndex >= 0 && isContainer(gHistoryTree, currentIndex); var url...
if (gLastHostname) { match = gLastHostname.match(/([^.]+\.[^.]+$)/); if (match) gLastDomain = match[1]; }
if (gHistoryStatus) gHistoryStatus.label = url;
function historyOnSelect(){ // every time selection changes, save the last hostname gLastHostname = ""; gLastDomain = ""; var match; var currentIndex = gHistoryTree.currentIndex; var rowIsContainer = gHistoryGrouping != "none" && currentIndex >= 0 && isContainer(gHistoryTree, currentIndex); var url...
}
function hookScriptSealed (e){ if (!("componentPath" in console)) { var ary = e.scriptInstance.url.match (/(.*)venkman-service\.js$/); if (ary) console.componentPath = ary[1]; } for (var fbp in console.fbreaks) { if (console.fbreaks[fbp].enabled && e.scriptInsta...
function hostNameIsIPAddress(aHostName, aUnobscuredHostName) {
hostNameIsIPAddress: function(aHostName, aUnobscuredHostName) { var index;
function hostNameIsIPAddress(aHostName, aUnobscuredHostName){ // TODO: Add Support for IPv6 var index; // scammers frequently obscure the IP address by encoding each component as octal, hex // or in some cases a mix match of each. The IP address could also be represented as a DWORD. // break the IP address down in...
var index;
function hostNameIsIPAddress(aHostName, aUnobscuredHostName){ // TODO: Add Support for IPv6 var index; // scammers frequently obscure the IP address by encoding each component as octal, hex // or in some cases a mix match of each. The IP address could also be represented as a DWORD. // break the IP address down in...
var ipComponents = aHostName.split(".");
function hostNameIsIPAddress(aHostName, aUnobscuredHostName){ // TODO: Add Support for IPv6 var index; // scammers frequently obscure the IP address by encoding each component as octal, hex // or in some cases a mix match of each. The IP address could also be represented as a DWORD. // break the IP address down in...
var ipComponents = aHostName.split(".");
if (ipComponents.length < 4) { var binaryDword = parseInt(aHostName).toString(2); if (isNaN(binaryDword)) return false;
function hostNameIsIPAddress(aHostName, aUnobscuredHostName){ // TODO: Add Support for IPv6 var index; // scammers frequently obscure the IP address by encoding each component as octal, hex // or in some cases a mix match of each. The IP address could also be represented as a DWORD. // break the IP address down in...
if (ipComponents.length < 4) { var binaryDword = parseInt(aHostName).toString(2); if (isNaN(binaryDword)) return false;
ipComponents = new Array; ipComponents[0] = (aHostName >> 24) & 255; ipComponents[1] = (aHostName >> 16) & 255; ipComponents[2] = (aHostName >> 8) & 255; ipComponents[3] = (aHostName & 255); } else { for (index = 0; index < ipComponents.length; ++index) { ipComponents[index] = parseInt(ipComponents[index]); } }
function hostNameIsIPAddress(aHostName, aUnobscuredHostName){ // TODO: Add Support for IPv6 var index; // scammers frequently obscure the IP address by encoding each component as octal, hex // or in some cases a mix match of each. The IP address could also be represented as a DWORD. // break the IP address down in...
ipComponents = new Array; ipComponents[0] = (aHostName >> 24) & 255; ipComponents[1] = (aHostName >> 16) & 255; ipComponents[2] = (aHostName >> 8) & 255; ipComponents[3] = (aHostName & 255); } else {
function hostNameIsIPAddress(aHostName, aUnobscuredHostName){ // TODO: Add Support for IPv6 var index; // scammers frequently obscure the IP address by encoding each component as octal, hex // or in some cases a mix match of each. The IP address could also be represented as a DWORD. // break the IP address down in...
ipComponents[index] = parseInt(ipComponents[index]);
aUnobscuredHostName.value = hostName; return true;
function hostNameIsIPAddress(aHostName, aUnobscuredHostName){ // TODO: Add Support for IPv6 var index; // scammers frequently obscure the IP address by encoding each component as octal, hex // or in some cases a mix match of each. The IP address could also be represented as a DWORD. // break the IP address down in...
} for (index = 0; index < ipComponents.length; ++index) if (isNaN(ipComponents[index])) return false; var hostName = ipComponents[0] + '.' + ipComponents[1] + '.' + ipComponents[2] + '.' + ipComponents[3]; if (isIPv4HostName(hostName)) { aUnobscuredHostName.value = hostName; return true; } return false; }
return false; },
function hostNameIsIPAddress(aHostName, aUnobscuredHostName){ // TODO: Add Support for IPv6 var index; // scammers frequently obscure the IP address by encoding each component as octal, hex // or in some cases a mix match of each. The IP address could also be represented as a DWORD. // break the IP address down in...
for (index = 0; index < ipComponents.length; index++)
for (index = 0; index < ipComponents.length; ++index)
function hostNameIsIPAddress(aHostName, aUnobscuredHostName){ // TODO: Add Support for IPv6 var index; // scammers frequently obscure the IP address by encoding each component as octal, hex // or in some cases a mix match of each. The IP address could also be represented as a DWORD. // break the IP address down in...
linkNode = event.originalTarget;
function hrefForClickEvent(event) { var target = event.target; var linkNode; var isKeyPress = (event.type == "keypress"); if ( target instanceof HTMLAnchorElement || target instanceof HTMLAreaElement || target instanceof HTMLLinkElement ) { if (target.hasAttribute("href")) ...
&& event.target.value.length == 0) {
&& event.target.value.length == 0 && "@mozilla.org/wallet/wallet-service;1" in Components.classes ) {
function hrefForClickEvent(event) { var target = event.target; var linkNode; var local_name = target.localName; if (local_name) { local_name = local_name.toLowerCase(); } var isKeyPress = (event.type == "keypress"); switch (local_name) { case "a": case "area": case "link"...
var local_name = target.localName; if (local_name) { local_name = local_name.toLowerCase(); }
function hrefForClickEvent(event) { var target = event.target; var linkNode; var local_name = target.localName; if (local_name) { local_name = local_name.toLowerCase(); } var isKeyPress = (event.type == "keypress"); switch (local_name) { case "a": case "area": case "link"...
switch (local_name) { case "a": case "area": case "link": if (target.hasAttribute("href")) linkNode = target; break; case "input": if ((event.target.type == "text")
if ( target instanceof HTMLAnchorElement || target instanceof HTMLAreaElement || target instanceof HTMLLinkElement ) { if (target.hasAttribute("href")) linkNode = target; } else if ( target instanceof HTMLInputElement && (event.target.type == "text")
function hrefForClickEvent(event) { var target = event.target; var linkNode; var local_name = target.localName; if (local_name) { local_name = local_name.toLowerCase(); } var isKeyPress = (event.type == "keypress"); switch (local_name) { case "a": case "area": case "link"...
) { prefillTextBox(target); } break; default: linkNode = findParentNode(event.originalTarget, "a"); if (linkNode && !linkNode.hasAttribute("href")) linkNode = null; break;
) { prefillTextBox(target); } else { linkNode = findParentNode(event.originalTarget, "a"); if (linkNode && !linkNode.hasAttribute("href")) linkNode = null;
function hrefForClickEvent(event) { var target = event.target; var linkNode; var local_name = target.localName; if (local_name) { local_name = local_name.toLowerCase(); } var isKeyPress = (event.type == "keypress"); switch (local_name) { case "a": case "area": case "link"...
href = linkNode.href;
href = new XPCNativeWrapper(linkNode, "href").href;
function hrefForClickEvent(event) { var target = event.target; var linkNode; var local_name = target.localName; if (local_name) { local_name = local_name.toLowerCase(); } var isKeyPress = (event.type == "keypress"); switch (local_name) { case "a": case "area": case "link"...
href = linkNode.getAttributeNS("http:
var wrapper = new XPCNativeWrapper(linkNode, "getAttributeNS()"); href = wrapper.getAttributeNS("http:
function hrefForClickEvent(event) { var target = event.target; var linkNode; var local_name = target.localName; if (local_name) { local_name = local_name.toLowerCase(); } var isKeyPress = (event.type == "keypress"); switch (local_name) { case "a": case "area": case "link"...
href = makeURLAbsolute(target.baseURI,href);
var baseURI = new XPCNativeWrapper(linkNode, "baseURI").baseURI; href = makeURLAbsolute(baseURI, href);
function hrefForClickEvent(event) { var target = event.target; var linkNode; var local_name = target.localName; if (local_name) { local_name = local_name.toLowerCase(); } var isKeyPress = (event.type == "keypress"); switch (local_name) { case "a": case "area": case "link"...
this.mChannel = null;
function httpHooks() {}
var octetArray = ""; var scriptableInputStream = Components.classes["@mozilla.org/scriptableinputstream;1"] .createInstance(Components.interfaces.nsIScriptableInputStream); scriptableInputStream.init(aStream); octetArray = scriptableInputStream.read(-1);
var octetArray = []; var binaryInputStream = Components.classes["@mozilla.org/binaryinputstream;1"] .createInstance(Components.interfaces.nsIBinaryInputStream); binaryInputStream.setInputStream(aStream); octetArray = binaryInputStream.readByteArray(binaryInputStream.available());
function ics_importFromStream(aStream, aCount) { var items = new Array(); // Read in the string. Note that it isn't a real string at this point, because // likely, the file is utf8. The multibyte chars show up as multiple 'chars' // in this string. So call it an array of octets for now. var octetArra...
octetArray = octetArray.replace(/\n /, "");
for (var i=octetArray.length-2; i>=0; i--) { if (octetArray[i] == "\n" && octetArray[i+1] == " ") { octetArray = octetArray.splice(i, 2); } }
function ics_importFromStream(aStream, aCount) { var items = new Array(); // Read in the string. Note that it isn't a real string at this point, because // likely, the file is utf8. The multibyte chars show up as multiple 'chars' // in this string. So call it an array of octets for now. var octetArra...
var str = unicodeConverter.ConvertFromUnicode(octetArray);
var str = unicodeConverter.convertFromByteArray(octetArray, octetArray.length);
function ics_importFromStream(aStream, aCount) { var items = new Array(); // Read in the string. Note that it isn't a real string at this point, because // likely, the file is utf8. The multibyte chars show up as multiple 'chars' // in this string. So call it an array of octets for now. var octetArra...
this.disconnect();
this.connection.disconnect();
function ident_listener_rawdata(e){ var ports = e.line.match(/(\d+) *, *(\d+)/); // <port-on-server> , <port-on-client> // (where "server" is the ident server) if (!ports) { this.disconnect(); // same meaning as "ERROR : UNKNOWN-ERROR" return; } e.type = "parsedrequest"; e.destObje...
this.disconnect();
this.connection.disconnect();
function ident_listener_request(e){ function response(str) { return e.localPort + " , " + e.remotePort + " : " + str + "\r\n"; }; function validPort(p) { return (p >= 1) && (p <= 65535); }; if (!validPort(e.localPort) || !validPort(e.remotePort)) { this.connection.sendData(r...
if(!idFromName.isValid() || !idFromIID.isValid()) { return (same && idFromName.isValid() == idFromIID.isValid()) || (!same && idFromName.isValid() != idFromIID.isValid());
if(!idFromName.valid || !idFromIID.valid) { return (same && idFromName.valid == idFromIID.valid) || (!same && idFromName.valid != idFromIID.valid);
function idTest(name, iid, same){ result = true; var idFromName = new nsID(name); var idFromIID = new nsID(iid); if(!idFromName.isValid() || !idFromIID.isValid()) { return (same && idFromName.isValid() == idFromIID.isValid()) || (!same && idFromName.isValid() != idFromIID.isValid()); ...
idFromName_NameNormalized = idFromName.toName() ? idFromName.toName().toLowerCase() : idFromName.toName();
idFromName_NameNormalized = idFromName.name ? idFromName.name.toLowerCase() : idFromName.name;
function idTest(name, iid, same){ result = true; var idFromName = new nsID(name); var idFromIID = new nsID(iid); if(!idFromName.isValid() || !idFromIID.isValid()) { return (same && idFromName.isValid() == idFromIID.isValid()) || (!same && idFromName.isValid() != idFromIID.isValid()); ...
idFromIID_NameNormalized = idFromIID.toName() ? idFromIID.toName().toLowerCase() : idFromIID.toName();
idFromIID_NameNormalized = idFromIID.name ? idFromIID.name.toLowerCase() : idFromIID.name;
function idTest(name, iid, same){ result = true; var idFromName = new nsID(name); var idFromIID = new nsID(iid); if(!idFromName.isValid() || !idFromIID.isValid()) { return (same && idFromName.isValid() == idFromIID.isValid()) || (!same && idFromName.isValid() != idFromIID.isValid()); ...
idFromName_StringNormalized = idFromName.toString() ? idFromName.toString().toLowerCase() : idFromName.toString();
idFromName_StringNormalized = idFromName.number ? idFromName.number.toLowerCase() : idFromName.number;
function idTest(name, iid, same){ result = true; var idFromName = new nsID(name); var idFromIID = new nsID(iid); if(!idFromName.isValid() || !idFromIID.isValid()) { return (same && idFromName.isValid() == idFromIID.isValid()) || (!same && idFromName.isValid() != idFromIID.isValid()); ...
idFromIID_StringNormalized = idFromIID.toString() ? idFromIID.toString().toLowerCase() : idFromIID.toString();
idFromIID_StringNormalized = idFromIID.number ? idFromIID.number.toLowerCase() : idFromIID.number;
function idTest(name, iid, same){ result = true; var idFromName = new nsID(name); var idFromIID = new nsID(iid); if(!idFromName.isValid() || !idFromIID.isValid()) { return (same && idFromName.isValid() == idFromIID.isValid()) || (!same && idFromName.isValid() != idFromIID.isValid()); ...
if (misspelledWord != "") { spellChecker.IgnoreWordAllOccurrences(misspelledWord);
if (MisspelledWord != "") { spellChecker.IgnoreWordAllOccurrences(MisspelledWord);
function IgnoreAll(){ dump("SpellCheck: IgnoreAll\n"); if (misspelledWord != "") { spellChecker.IgnoreWordAllOccurrences(misspelledWord); } NextWord();}
var addInterface = module.GetImportInterface( "addressbook"); if (addInterface != null) addInterface = addInterface.QueryInterface( Components.interfaces.nsIImportGeneric); if (addInterface == null) { error.data = gImportMsgsBundle.getString('ImportAddressBadModule'); return( false); } var loc = addInterface.GetStatu...
var addInterface = module.GetImportInterface( "addressbook"); if (addInterface != null) addInterface = addInterface.QueryInterface( Components.interfaces.nsIImportGeneric); if (addInterface == null) { error.data = gImportMsgsBundle.getString('ImportAddressBadModule'); return( false); }
function ImportAddress( module, success, error) { if (top.progressInfo.importInterface || top.progressInfo.intervalState) { error.data = gImportMsgsBundle.getString('ImportAlreadyInProgress'); return( false); } top.progressInfo.importSuccess = false; var addInterface = module.GetImportInterface( "addressbook"); if (a...
var filePicker = Components.classes["@mozilla.org/filepicker;1"].createInstance(); if (filePicker != null) { filePicker = filePicker.QueryInterface( Components.interfaces.nsIFilePicker); if (filePicker == null) { error.data = gImportMsgsBundle.getString('ImportAddressNotFound'); return( false); } } else { error.data = ...
function ImportAddress( module, success, error) { if (top.progressInfo.importInterface || top.progressInfo.intervalState) { error.data = gImportMsgsBundle.getString('ImportAlreadyInProgress'); return( false); } top.progressInfo.importSuccess = false; var addInterface = module.GetImportInterface( "addressbook"); if (a...
var file = null; if (addInterface.GetStatus( "supportsMultiple") != 0) { try { filePicker.init( top.window, gImportMsgsBundle.getString('ImportSelectAddrDir'), Components.interfaces.nsIFilePicker.modeGetFolder); filePicker.appendFilters( Components.interfaces.nsIFilePicker.filterAll); filePicker.show(); if (filePicker...
var loc = addInterface.GetStatus( "autoFind"); if (loc == false) { loc = addInterface.GetData( "addressLocation"); if (loc != null) { loc = loc.QueryInterface( Components.interfaces.nsIFileSpec); if (loc != null) { if (!loc.exists) loc = null; } } }
function ImportAddress( module, success, error) { if (top.progressInfo.importInterface || top.progressInfo.intervalState) { error.data = gImportMsgsBundle.getString('ImportAlreadyInProgress'); return( false); } top.progressInfo.importSuccess = false; var addInterface = module.GetImportInterface( "addressbook"); if (a...
if (file == null) { return( false); } file = CreateNewFileSpecFromPath( file);
if (loc == null) { if (addInterface.GetStatus( "canUserSetLocation") == 0) { error.data = gImportMsgsBundle.getString('ImportAddressNotFound'); return( false); }
function ImportAddress( module, success, error) { if (top.progressInfo.importInterface || top.progressInfo.intervalState) { error.data = gImportMsgsBundle.getString('ImportAlreadyInProgress'); return( false); } top.progressInfo.importSuccess = false; var addInterface = module.GetImportInterface( "addressbook"); if (a...
addInterface.SetData( "addressLocation", file); } var map = addInterface.GetData( "fieldMap"); if (map != null) { map = map.QueryInterface( Components.interfaces.nsIImportFieldMap); if (map != null) { var result = new Object(); result.ok = false; top.window.openDialog( "chrome: "", "chrome,modal,titlebar", {fieldMap: ...
var filePicker = Components.classes["@mozilla.org/filepicker;1"].createInstance(); if (filePicker != null) { filePicker = filePicker.QueryInterface( Components.interfaces.nsIFilePicker); if (filePicker == null) { error.data = gImportMsgsBundle.getString('ImportAddressNotFound'); return( false); } } else { error.data = ...
function ImportAddress( module, success, error) { if (top.progressInfo.importInterface || top.progressInfo.intervalState) { error.data = gImportMsgsBundle.getString('ImportAlreadyInProgress'); return( false); } top.progressInfo.importSuccess = false; var addInterface = module.GetImportInterface( "addressbook"); if (a...
if (addInterface.WantsProgress()) { if (addInterface.BeginImport( success, error)) { top.progressInfo.importInterface = addInterface; return( true); } else { return( false); } } else { if (addInterface.BeginImport( success, error)) { return( true); } else { return( false); } }
var file = null; if (addInterface.GetStatus( "supportsMultiple") != 0) { try { filePicker.init( top.window, gImportMsgsBundle.getString('ImportSelectAddrDir'), Components.interfaces.nsIFilePicker.modeGetFolder); filePicker.appendFilters( Components.interfaces.nsIFilePicker.filterAll); filePicker.show(); if (filePicker...
function ImportAddress( module, success, error) { if (top.progressInfo.importInterface || top.progressInfo.intervalState) { error.data = gImportMsgsBundle.getString('ImportAlreadyInProgress'); return( false); } top.progressInfo.importSuccess = false; var addInterface = module.GetImportInterface( "addressbook"); if (a...
filePicker.chooseDirectory( "Select address book directory");
filePicker.chooseDirectory( GetBundleString( 'ImportSelectAddrDir'));
function ImportAddress( module, success, error) { if (top.progressInfo.importInterface || top.progressInfo.intervalState) { error.data = GetBundleString( 'ImportAlreadyInProgress'); return( false); } top.progressInfo.importSuccess = false; var addInterface = module.GetImportInterface( "addressbook"); if (addInterface...
filePicker.chooseInputFile( "Select address book file", filePicker.eAllFiles, null, null);
filePicker.chooseInputFile( GetBundleString( 'ImportSelectAddrFile'), filePicker.eAllFiles, null, null);
function ImportAddress( module, success, error) { if (top.progressInfo.importInterface || top.progressInfo.intervalState) { error.data = GetBundleString( 'ImportAlreadyInProgress'); return( false); } top.progressInfo.importSuccess = false; var addInterface = module.GetImportInterface( "addressbook"); if (addInterface...
var addInterface = module.GetImportInterface( "addressbook");
addInterface = module.GetImportInterface( "addressbook");
function ImportAddress( module, success, error) { if (top.progressInfo.importInterface || top.progressInfo.intervalState) { error.data = gImportMsgsBundle.getString('ImportAlreadyInProgress'); return( false); } top.progressInfo.importSuccess = false; var addInterface = module.GetImportInterface( "addressbook"...
var path ;
function ImportAddress( module, success, error) { if (top.progressInfo.importInterface || top.progressInfo.intervalState) { error.data = gImportMsgsBundle.getString('ImportAlreadyInProgress'); return( false); } top.progressInfo.importSuccess = false; var addInterface = module.GetImportInterface( "addressbook"...