rem
stringlengths
0
126k
add
stringlengths
0
441k
context
stringlengths
15
136k
var startDate = gCalendarWindow.currentView.getNewEventDate();
if( gNewDateVariable != null ) { var startDate = gNewDateVariable; } else var startDate = gCalendarWindow.currentView.getNewEventDate();
function newEventCommand(){ var startDate = gCalendarWindow.currentView.getNewEventDate(); var Minutes = Math.ceil( startDate.getMinutes() / 5 ) * 5 ; startDate = new Date( startDate.getFullYear(), startDate.getMonth(), startDate.getDate(), ...
if (!jsenv.HAS_XPCOM)
if ((!jsenv.HAS_XPCOM) || (!getPriv("UniversalXPConnect")))
function newObject(progID, iface){ if (!jsenv.HAS_XPCOM) return null; netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect"); var obj = Components.classes[progID].createInstance(); var rv; switch (typeof iface) { case "string": rv = obj.QueryInterface(Compone...
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
function newObject(progID, iface){ if (!jsenv.HAS_XPCOM) return null; netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect"); var obj = Components.classes[progID].createInstance(); var rv; switch (typeof iface) { case "string": rv = obj.QueryInterface(Compone...
return new SyntaxError(m, this.filename, this.lineno);
var e = new SyntaxError(m, this.filename, this.lineno); e.source = this.source; e.cursor = this.cursor; return e;
newSyntaxError: function (m) { return new SyntaxError(m, this.filename, this.lineno); }
var prefService = Components.classes["@mozilla.org/preferences-service;1"] .getService(Components.interfaces.nsIPrefService); var alarmsBranch = prefService.getBranch("calendar.alarms."); if (alarmsBranch.getIntPref("onfortodos") == 1) { if (!calendarToDo.entryDate) calendarToDo.entryDate = jsDateToDateTime( gCalenda...
setDefaultAlarmValues(calendarToDo);
function newToDo ( startDate, dueDate ) { var calendarToDo = createToDo(); // created todo has no start or due date unless user wants one if (startDate) calendarToDo.entryDate = jsDateToDateTime(startDate); if (dueDate) calendarToDo.dueDate = jsDateToDateTime(startDate); var prefService ...
gTree.setAttribute("ref", "urn:mimetypes");
gList.setAttribute("ref", "urn:mimetypes");
function newType(){ window.openDialog("chrome://communicator/content/pref/pref-applications-new.xul", "appEdit", "chrome,modal=yes,resizable=no"); if (gNewTypeRV) { //gTree.builder.rebuild(); gTree.setAttribute("ref", "urn:mimetypes"); gNewTypeRV = null; }}
if (gNewTypeRV) { gList.builder.rebuild(); gNewTypeRV = null; }
function newType(){ var handlerOverride = new HandlerOverride(); window.openDialog("chrome://communicator/content/pref/pref-applications-edit.xul", "appEdit", "chrome,modal=yes,resizable=no", handlerOverride); if (gNewTypeRV) { gList.builder.rebuild(); gNewTypeRV = null; }}
SwitchType(radioGroup.data);
SwitchType(radioGroup.value);
function next(){ var deck = document.getElementById("stateDeck"); var index = deck.getAttribute("index"); switch (index) { case "0": var backButton = document.getElementById("back"); backButton.removeAttribute("disabled"); var radioGroup = document.getElementById("importFields"); SwitchType(radioGroup.d...
case "4" : var isHomeRadioGroup = document.getElementById("homeorwork"); if (isHomeRadioGroup.selectedItem.getAttribute("value") == "Home") selLocIsHome = true ; ExportComm4x() ; break ;
function next(){ var deck = document.getElementById("stateDeck"); var index = deck.getAttribute("index"); switch (index) { case "0": var backButton = document.getElementById("back"); backButton.removeAttribute("disabled"); var radioGroup = document.getElementById("importFields"); SwitchType(radioGroup.v...
misspelledWord = spellChecker.GetNextMisspelledWord(); dialog.misspelledWord.setAttribute("value",misspelledWord); if (misspelledWord == "") { dump("FINISHED SPELL CHECKING\n"); Close(); } else { FillSuggestedList(); } dialog.replaceWordInput.value = misspelledWord;
MisspelledWord = spellChecker.GetNextMisspelledWord(); SetWidgetsForMisspelledWord();
function NextWord(){ misspelledWord = spellChecker.GetNextMisspelledWord(); dialog.misspelledWord.setAttribute("value",misspelledWord); if (misspelledWord == "") { dump("FINISHED SPELL CHECKING\n"); // Simply close dialog when finished. Close(); } else { FillSuggestedList(); } // Initial replace word ...
function nodeBeginsBlock(node)
function nodeBeginsBlock(editor, node)
function nodeBeginsBlock(node){ while (nodeIsBlank(node)) node = node.nextSibling; return nodeIsBlock(node);}
return nodeIsBlock(node);
return nodeIsBreak(editor, node);
function nodeBeginsBlock(node){ while (nodeIsBlank(node)) node = node.nextSibling; return nodeIsBlock(node);}
function nodeEndsBlock(node)
function nodeEndsBlock(editor, node)
function nodeEndsBlock(node){ while (nodeIsBlank(node)) node = node.previousSibling; return nodeIsBlock(node);}
return nodeIsBlock(node);
return nodeIsBreak(editor, node);
function nodeEndsBlock(node){ while (nodeIsBlank(node)) node = node.previousSibling; return nodeIsBlock(node);}
return node && node.NODE_TYPE == Node.TEXT_NODE && !/\S/.test(node.data);
return node && node.nodeType == Node.TEXT_NODE && !/\S/.test(node.data);
function nodeIsBlank(node){ return node && node.NODE_TYPE == Node.TEXT_NODE && !/\S/.test(node.data);}
for (var i=0; i < ls.length; i++) {
for (var i=0; i < ls.length; ++i) {
function normalizeLinks(helpBaseURI, links) { if (!helpBaseURI) return links; var ls = links.split(/\s+/); if (ls.length == 0) return links; for (var i=0; i < ls.length; i++) { if (ls[i] == "") continue; if (ls[i].substr(0,7) != "chrome:" && ls[i].substr(0,4) != "rdf:") ls[i] = helpBaseURI + ...
if (tb.getAttribute ("src") == client.NACT_IMG) tb.setAttribute ("src", client.ACT_IMG); else
{ if (tb.getAttribute ("state") == "normal") { tb.setAttribute ("state", "activity"); } else if (tb.getAttribute("state") == "activity")
function notifyActivity (source){ if (typeof source != "object") source = client.viewsArray[source].source; var tb = getTBForObject (source, true); if (client.currentObject != source) if (tb.getAttribute ("src") == client.NACT_IMG) tb.setAttribute ("src", client.ACT_IMG); el...
tb.setAttribute ("src", client.NACT_IMG);
tb.setAttribute ("state", "normal");
function notifyActivity (source){ if (typeof source != "object") source = client.viewsArray[source].source; var tb = getTBForObject (source, true); if (client.currentObject != source) if (tb.getAttribute ("src") == client.NACT_IMG) tb.setAttribute ("src", client.ACT_IMG); el...
}
function notifyActivity (source){ if (typeof source != "object") source = client.viewsArray[source].source; var tb = getTBForObject (source, true); if (client.currentObject != source) if (tb.getAttribute ("src") == client.NACT_IMG) tb.setAttribute ("src", client.ACT_IMG); el...
window.GetAttention();
window.getAttention();
function notifyAttention (source){ if (typeof source != "object") source = client.viewsArray[source].source; if (client.currentObject != source) { var tb = getTabForObject (source, true); var vk = Number(tb.getAttribute("viewKey")); tb.setAttribute ("state", "attention"); ...
msgCompose.UnregisterStateListener(stateListener); }
},
NotifyComposeFieldsReady: function() {// dump("\n RECEIVE NotifyComposeFieldsReady\n\n"); documentLoaded = true; msgCompose.UnregisterStateListener(stateListener); }
gEditor.addOverrideStyleSheet(gBaseEditorStyleSheet);
gEditor.addOverrideStyleSheet(kBaseEditorStyleSheet);
NotifyDocumentCreated: function() { gEditor = editorShell.editor; // do all of our QI'ing here so we don't need to do it elsewhere DoAllQueryInterfaceOnEditor(); addEditorClickEventListener(); try { // Add the base sheet for editor cursor etc. gEditor.addOverrideStyleSheet(gBaseEditorStyleSh...
content.focus(); window.updateCommands("create");
NotifyDocumentCreated: function() { EditorSetDefaultPrefs(); // Call EditorSetDefaultPrefs first // so it gets the default author before initing toolbars EditorInitToolbars(); },
{ EditorSetDefaultPrefs(); },
{ EditorSetDefaultPrefs(); EditorInitToolbars(); },
NotifyDocumentCreated: function() { EditorSetDefaultPrefs(); },
SetComposeWindowTitle(13);
NotifyDocumentCreated: function() { if (document.getElementById("msgRecipient#1").value == "") { dump("set focus on the recipient\n"); document.getElementById("msgRecipient#1").focus(); } else { dump("set focus on the body\n"); contentWindow.focus(); } }
window.updateCommands("create");
NotifyDocumentStateChanged:function( isNowDirty ) { /* Notify our dirty detector so this window won't be closed if another document is opened */ if (isNowDirty) docWasModified = true; }
function NotifySaveListeners()
function NotifySaveListeners(directory)
function NotifySaveListeners(){ if (!gOnSaveListeners.length) return; for ( var i = 0; i < gOnSaveListeners.length; i++ ) gOnSaveListeners[i](); // the save listeners might have tweaked the card // in which case we need to commit it. gEditCard.card.editCardToDatabase(gEditCard.abURI);}
gEditCard.card.editCardToDatabase(gEditCard.abURI);
directory.modifyCard(gEditCard.card);
function NotifySaveListeners(){ if (!gOnSaveListeners.length) return; for ( var i = 0; i < gOnSaveListeners.length; i++ ) gOnSaveListeners[i](); // the save listeners might have tweaked the card // in which case we need to commit it. gEditCard.card.editCardToDatabase(gEditCard.abURI);}
if (aEvent.target.localName != "notification") return;
function noUpdatesDismiss(aEvent){ window.removeEventListener("command", noUpdatesDismiss, true); if (aEvent.target.localName != "notification") return; var children = gExtensionsView.children; for (var i = 0; i < children.length; ++i) { var child = children[i]; if (child.hasAttribute("updateStatus")) ...
if (aEvent.target.localName != "notification") document.getElementById("addonsMsg").removeCurrentNotification();
function noUpdatesDismiss(aEvent){ window.removeEventListener("command", noUpdatesDismiss, true); if (aEvent.target.localName != "notification") return; var children = gExtensionsView.children; for (var i = 0; i < children.length; ++i) { var child = children[i]; if (child.hasAttribute("updateStatus")) ...
pref.addObserver(this.domain, this);
var pbi = pref.QueryInterface(Components.interfaces.nsIPrefBranchInternal); if (pbi) pbi.addObserver(this.domain, this, false);
function nsButtonPrefListener(){ try { pref.addObserver(this.domain, this); } catch(ex) { dump("Failed to observe prefs: " + ex + "\n"); }}
Components.interfaces.nsIPrefBranchInternal);
Components.interfaces.nsIPrefBranch2);
function nsDefaultEngine(){ try { var pb = Components.classes["@mozilla.org/preferences-service;1"]. getService(Components.interfaces.nsIPrefBranch); var pbi = pb.QueryInterface( Components.interfaces.nsIPrefBranchInternal); pbi.addObserver(this.domain, th...
this.mSelectedFilter = 0;
function nsFilePicker(){ /* attributes */ this.mSelectedFilter = 0; this.mDefaultString = ""; this.mDisplayDirectory = lastDirectory; this.mFilterTitles = new Array(); this.mFilters = new Array();}
return ChatzillaModule;
return CalendarModule;
function NSGetModule(compMgr, fileSpec) { return ChatzillaModule;}
.createInstance().QueryInterface(Components.interfaces.nsIURIChecker);
.createInstance(Components.interfaces.nsIURIChecker); this.linkChecker.init(this.uri);
function nsHeaderSniffer(aURL, aCallback, aData){ this.mCallback = aCallback; this.mData = aData; this.uri = makeURL(aURL); this.linkChecker = Components.classes["@mozilla.org/network/urichecker;1"] .createInstance().QueryInterface(Components.interfaces.nsIURIChecker); var flags; if (aData.bypassCache) { ...
this.linkChecker.asyncCheckURI(aURL, this, null, flags);
this.linkChecker.asyncCheck(this, null);
function nsHeaderSniffer(aURL, aCallback, aData){ this.mCallback = aCallback; this.mData = aData; this.uri = makeURL(aURL); this.linkChecker = Components.classes["@mozilla.org/network/urichecker;1"] .createInstance().QueryInterface(Components.interfaces.nsIURIChecker); var flags; if (aData.bypassCache) { ...
.createInstance().QueryInterface(Components.interfaces.nsIURIChecker);
.createInstance(Components.interfaces.nsIURIChecker); this.linkChecker.init(this.uri);
function nsHeaderSniffer(aURL, aCallback, aData, aSkipPrompt){ this.mCallback = aCallback; this.mData = aData; this.mSkipPrompt = aSkipPrompt; this.uri = makeURL(aURL); this.linkChecker = Components.classes["@mozilla.org/network/urichecker;1"] .createInstance().QueryInterface(Components.interfaces.nsIURIChe...
this.linkChecker.asyncCheckURI(aURL, this, null, flags);
this.linkChecker.asyncCheck(this, null);
function nsHeaderSniffer(aURL, aCallback, aData, aSkipPrompt){ this.mCallback = aCallback; this.mData = aData; this.mSkipPrompt = aSkipPrompt; this.uri = makeURL(aURL); this.linkChecker = Components.classes["@mozilla.org/network/urichecker;1"] .createInstance().QueryInterface(Components.interfaces.nsIURIChe...
this.updateSelf = true;
function nsHelperAppDialog() { // Initialize data properties. this.mLauncher = null; this.mContext = null; this.mSourcePath = null; this.choseApp = false; this.chosenApp = null; this.givenDefaultApp = false; this.strings = new Array; this.elements = new Array;}
var arrayOfDirectories = null;
var arrayOfDirectories;
function nsLDAPPrefsService() { var arrayOfDirectories = null; var j = 0; try { gPrefInt = Components.classes["@mozilla.org/preferences;1"]; gPrefInt = gPrefInt.getService(nsIPref); } catch (ex) { dump("failed to get prefs service!\n"); return; } /* generate the list of directory servers from prefere...
gPrefInt = Components.classes["@mozilla.org/preferences;1"]; gPrefInt = gPrefInt.getService(nsIPref);
gPrefInt = Components.classes["@mozilla.org/preferences-service;1"]; gPrefInt = gPrefInt.getService(nsIPrefBranch);
function nsLDAPPrefsService() { var arrayOfDirectories = null; var j = 0; try { gPrefInt = Components.classes["@mozilla.org/preferences;1"]; gPrefInt = gPrefInt.getService(nsIPref); } catch (ex) { dump("failed to get prefs service!\n"); return; } /* generate the list of directory servers from prefere...
var children = gPrefInt.CreateChildList("ldap_2.servers"); if(children) { arrayOfDirectories = children.split(';');
var prefCount = {value:0}; try { arrayOfDirectories = gPrefInt.getChildList("ldap_2.servers", prefCount); } catch (ex) { arrayOfDirectories = null; } if (arrayOfDirectories) {
function nsLDAPPrefsService() { var arrayOfDirectories = null; var j = 0; try { gPrefInt = Components.classes["@mozilla.org/preferences;1"]; gPrefInt = gPrefInt.getService(nsIPref); } catch (ex) { dump("failed to get prefs service!\n"); return; } /* generate the list of directory servers from prefere...
for (var i=0; i<arrayOfDirectories.length; i++)
for (var i = 0; i < prefCount.value; i++)
function nsLDAPPrefsService() { var arrayOfDirectories = null; var j = 0; try { gPrefInt = Components.classes["@mozilla.org/preferences;1"]; gPrefInt = gPrefInt.getService(nsIPref); } catch (ex) { dump("failed to get prefs service!\n"); return; } /* generate the list of directory servers from prefere...
position = gPrefInt.GetIntPref(arrayOfDirectories[i]+".position");
position = gPrefInt.getIntPref(arrayOfDirectories[i]+".position");
function nsLDAPPrefsService() { var arrayOfDirectories = null; var j = 0; try { gPrefInt = Components.classes["@mozilla.org/preferences;1"]; gPrefInt = gPrefInt.getService(nsIPref); } catch (ex) { dump("failed to get prefs service!\n"); return; } /* generate the list of directory servers from prefere...
dirType = gPrefInt.GetIntPref(arrayOfDirectories[i]+".dirType");
dirType = gPrefInt.getIntPref(arrayOfDirectories[i]+".dirType");
function nsLDAPPrefsService() { var arrayOfDirectories = null; var j = 0; try { gPrefInt = Components.classes["@mozilla.org/preferences;1"]; gPrefInt = gPrefInt.getService(nsIPref); } catch (ex) { dump("failed to get prefs service!\n"); return; } /* generate the list of directory servers from prefere...
description = gPrefInt.CopyUnicharPref(arrayOfDirectories[i]+".description");
description = gPrefInt.getComplexValue(arrayOfDirectories[i]+".description", Components.interfaces.nsISupportsWString);
function nsLDAPPrefsService() { var arrayOfDirectories = null; var j = 0; try { gPrefInt = Components.classes["@mozilla.org/preferences;1"]; gPrefInt = gPrefInt.getService(nsIPref); } catch (ex) { dump("failed to get prefs service!\n"); return; } /* generate the list of directory servers from prefere...
var obj = Components.classes.nsEcho.createInstance(); obj = obj.QueryInterface(Components.interfaces.nsIEcho); return obj;
var clazz = Components.classes["@mozilla.org/js/xpc/test/Echo;1"]; var iface = Components.interfaces.nsIEcho; return new clazz(iface);
function nsNativeEcho(){ var obj = Components.classes.nsEcho.createInstance(); obj = obj.QueryInterface(Components.interfaces.nsIEcho); return obj;}
this.mPercent = 0;
this.mPercent = -1;
function nsProgressDialog() { // Initialize data properties. this.mParent = null; this.mOperation = null; this.mStartTime = ( new Date() ).getTime(); this.observer = null; this.mLastUpdate = Number.MIN_VALUE; // To ensure first onProgress causes update. this.mInterval = 750; // Def...
this.dsURI = prefBranch.getComplexValue("pfs.datasource.url", Components.interfaces.nsIPrefLocalizedString).data;
this.dsURI = prefBranch.getCharPref("pfs.datasource.url");
function nsRDFItemUpdater(aClientOS, aChromeLocale){ this._rdfService = Components.classes["@mozilla.org/rdf/rdf-service;1"] .getService(Components.interfaces.nsIRDFService); this._os = Components.classes["@mozilla.org/observer-service;1"] .getService(Components.interfaces...
if (type == seperatorUri)
if (type == SEPARATOR_URI)
function nsTreeController_copy(tree){ var select_list = tree.selectedItems; if (!select_list) return false; if (select_list.length < 1) return false; var datasource = tree.database; // Build a url that encodes all the select nodes // as well as their parent nodes var url = ""; var text = ""...
this.defaultStatus = bundle.GetStringFromName("defaultStatus");
function nsXULBrowserWindow(){}
this.locationField = document.getElementById("urlbar");
function nsXULBrowserWindow(){ this.locationField = document.getElementById("urlbar");}
return this.makeURLAbsolute( objElem.baseURI, data );
return this.makeURLAbsolute( objElem.ownerDocument, data );
objectImageURL : function ( objElem ) { // Extract url from data= attribute. var data = objElem.getAttribute( "data" ); // Make it absolute. return this.makeURLAbsolute( objElem.baseURI, data ); },
switch (aPrefName) { case "calendar.view.defaultstarthour": case "calendar.view.defaultendhour": var sHour = this.rootPrefBranch.getIntPref ("calendar.view.defaultstarthour"); var eHour = this.rootPrefBranch.getIntPref ("calendar.view.defaultendhour"); document.getElementById("calendar-multiday-view") .setStartEndMinut...
observe: function(aSubject, aTopic, aPrefName) { switch (aPrefName) { case "calendar.view.defaultstarthour": case "calendar.view.defaultendhour": var sHour = this.rootPrefBranch.getIntPref ("calendar.view.defaultstarthour"); var eH...
if (gUpdatingBatch) return;
observe: function(subject, topic, state) { if (topic == "cookieChanged") { if (state == "cookies") { cookies.length = 0; if (lastCookieSortColumn == "rawHost") { lastCookieSortAscending = !lastCookieSortAscending; // prevents sort from being reversed } loadCookies(); ...
if(allLeftButtonsAreHidden()) document.getElementById("home-bm-separator").setAttribute("hidden", "true"); else document.getElementById("home-bm-separator").removeAttribute("hidden");
Observe: function(subject, topic, prefName) { // verify that we're changing a button pref if (topic != "nsPref:changed") return; if (prefName.substr(0, this.domain.length) != this.domain) return; var buttonName = prefName.substr(this.domain.length+1); var buttonId = buttonName + "-button"; var butt...
getCalendarManager().removeObserver(this);
observe: function( subject, topic, data ) { this.log( "observing: " + topic + ", data: " + data ); if (topic == "network:offline-about-to-go-offline") { this.logout(); } else if (topic == "quit-application") { this.logout(); // xxx todo: valid upon ...
if (dl.percentComplete == -1) {
var percentComplete = dl.percentComplete; if (percentComplete == -1) {
observe: function(subject, topic, state) { if (topic != "dl-progress") return; var dl = subject.QueryInterface(Components.interfaces.nsIDownload); var elt = document.getElementById(dl.target.path); if (dl.percentComplete == -1) { if (!elt.hasAttribute("progressmode")) elt.setAttribute("progres...
elt.setAttribute("progress", dl.percentComplete);
elt.setAttribute("progress", percentComplete);
observe: function(subject, topic, state) { if (topic != "dl-progress") return; var dl = subject.QueryInterface(Components.interfaces.nsIDownload); var elt = document.getElementById(dl.target.path); if (dl.percentComplete == -1) { if (!elt.hasAttribute("progressmode")) elt.setAttribute("progres...
} };
} }
observe: function(subject, topic, state) { if (topic != "dl-progress") return; var dl = subject.QueryInterface(Components.interfaces.nsIDownload); var elt = document.getElementById(dl.target.path); if (dl.percentComplete == -1) { if (!elt.hasAttribute("progressmode")) elt.setAttribute("progres...
case "profile-after-change":
case "final-ui-startup":
observe: function(subject, topic, data) { switch(topic) { case "xpcom-shutdown": this._dispose(); break; case "profile-change-teardown": this._onProfileShutdown(); break; case "profile-after-change": this._onProfileStartup(); break; } }
GroupBy(aPrefBranch.QueryInterface(Components.interfaces.nsIPrefBranch).getCharPref(aPrefName));
gHistoryGrouping = gPrefService.getCharPref("browser.history.grouping");
observe: function(aPrefBranch, aTopic, aPrefName) { try { GroupBy(aPrefBranch.QueryInterface(Components.interfaces.nsIPrefBranch).getCharPref(aPrefName)); } catch(ex) { } }
catch(ex) {
catch(e) { gHistoryGrouping = "day";
observe: function(aPrefBranch, aTopic, aPrefName) { try { GroupBy(aPrefBranch.QueryInterface(Components.interfaces.nsIPrefBranch).getCharPref(aPrefName)); } catch(ex) { } }
UpdateTreeGrouping();
observe: function(aPrefBranch, aTopic, aPrefName) { try { GroupBy(aPrefBranch.QueryInterface(Components.interfaces.nsIPrefBranch).getCharPref(aPrefName)); } catch(ex) { } }
if (topic != "nsPref:changed") return; if (prefName.substr(0, this.domain.length) != this.domain) return;
if (topic != "nsPref:changed") return;
observe: function(subject, topic, prefName) { // verify that we're changing a button pref if (topic != "nsPref:changed") return; if (prefName.substr(0, this.domain.length) != this.domain) return; var buttonName = prefName.substr(this.domain.length+1); var buttonId = buttonName + "-button"; var butt...
var buttonName = prefName.substr(this.domain.length+1); var buttonId = buttonName + "-button"; var button = document.getElementById(buttonId); var show = pref.getBoolPref(prefName); if (show) button.setAttribute("hidden","false"); else button.setAttribute("hidden", "true"); if(allLeftButtonsAreHidden()) document.ge...
var stripVisibility = !pref.getBoolPref(prefName); if (gBrowser.mTabContainer.childNodes.length == 1) gBrowser.setStripVisibilityTo(stripVisibility);
observe: function(subject, topic, prefName) { // verify that we're changing a button pref if (topic != "nsPref:changed") return; if (prefName.substr(0, this.domain.length) != this.domain) return; var buttonName = prefName.substr(this.domain.length+1); var buttonId = buttonName + "-button"; var butt...
if (this.CalendarPreferences.calendarWindow.currentView != null) { this.CalendarPreferences.calendarWindow.currentView.refresh(); }
observe: function(subject, topic, prefName) { subject = subject.QueryInterface(Components.interfaces.nsIPrefBranch2); // when calendar pref was changed, we reinitialize switch( prefName ) { case "calendar.week.start": if (this.CalendarPreferences.calendarWin...
if (aTopic != "cookie-changed" || !aCookie)
if (aTopic != "cookie-changed")
observe: function (aCookie, aTopic, aData) { if (aTopic != "cookie-changed" || !aCookie) return; if (aCookie instanceof Components.interfaces.nsICookie) { var strippedHost = this._makeStrippedHost(aCookie.host); if (aData == "changed") this._handleCookieChanged(aCookie, strippedHost)...
else if (aData == "cleared") { this._hosts = {}; this._hostOrder = []; var oldRowCount = this._view._rowCount; this._view._rowCount = 0; this._tree.treeBoxObject.rowCountChanged(0, -oldRowCount); this._view.selection.clearSelection(); }
observe: function (aCookie, aTopic, aData) { if (aTopic != "cookie-changed" || !aCookie) return; if (aCookie instanceof Components.interfaces.nsICookie) { var strippedHost = this._makeStrippedHost(aCookie.host); if (aData == "changed") this._handleCookieChanged(aCookie, strippedHost)...
case "calendar.view.defaultstarthour": case "calendar.view.defaultendhour":
observe: function(subject, topic, prefName) { subject = subject.QueryInterface(Components.interfaces.nsIPrefBranch2); // when calendar pref was changed, we reinitialize switch( prefName ) { case "calendar.view.defaultstarthour": case "calendar.view.defaultendhou...
statusbarDisplay.value = gNavigatorBundle.getString("jserror");
statusbarDisplay.label = gNavigatorBundle.getString("jserror");
observe: function (aMsgObject) { const nsIScriptError = Components.interfaces.nsIScriptError; var scriptError = aMsgObject.QueryInterface(nsIScriptError); var isWarning = scriptError.flags & nsIScriptError.warningFlag != 0; if (!isWarning) { var statusbarDisplay = document.getElementById("statusbar-...
if (topic != "network:offline-status-changed") return;
if (topic == "network:offline-status-changed")
observe: function(subject, topic, state) { // sanity checks if (topic != "network:offline-status-changed") return; MailOfflineStateChanged(state == "offline"); }
var show = pref.GetBoolPref(prefName);
var show = pref.getBoolPref(prefName);
Observe: function(subject, topic, prefName) { // verify that we're changing a button pref if (topic != "nsPref:changed") return; if (prefName.substr(0, this.domain.length) != this.domain) return; var buttonName = prefName.substr(this.domain.length+1); var buttonId = buttonName + "-button"; var butt...
if (prefName.substr(0, this.domain.length) != this.domain) return;
if (prefName.substr(0, kUseCssPref.length) == kUseCssPref) { var cmd = document.getElementById("cmd_highlight"); if (cmd) { var prefs = GetPrefs(); var useCSS = prefs.getBoolPref(prefName); var editor = GetCurrentEditor(); if (useCSS && editor) { var mixedObj = {}; var state = editor.getHighlightColorState(mixedObj); c...
observe: function(subject, topic, prefName) { if (!IsHTMLEditor()) return; // verify that we're changing a button pref if (topic != "nsPref:changed") return; if (prefName.substr(0, this.domain.length) != this.domain) return; var cmd = document.getElementById("cmd_highlight"); if (cmd) { v...
var cmd = document.getElementById("cmd_highlight"); if (cmd) { var prefs = GetPrefs(); var useCSS = prefs.getBoolPref(prefName);
if (editor) editor.isCSSEnabled = useCSS; } } else if (prefName.substr(0, kEditorToolbarPrefs.length) == kEditorToolbarPrefs) { var id = prefName.substr(kEditorToolbarPrefs.length) + "Button"; var button = document.getElementById(id); if (button) { button.hidden = !gPrefs.getBoolPref(prefName); ShowHideToolbarSeparator...
observe: function(subject, topic, prefName) { if (!IsHTMLEditor()) return; // verify that we're changing a button pref if (topic != "nsPref:changed") return; if (prefName.substr(0, this.domain.length) != this.domain) return; var cmd = document.getElementById("cmd_highlight"); if (cmd) { v...
if (useCSS && editor) { var mixedObj = {}; var state = editor.getHighlightColorState(mixedObj); cmd.setAttribute("state", state); cmd.collapsed = false; } else { cmd.setAttribute("state", "transparent"); cmd.collapsed = true; }
observe: function(subject, topic, prefName) { if (!IsHTMLEditor()) return; // verify that we're changing a button pref if (topic != "nsPref:changed") return; if (prefName.substr(0, this.domain.length) != this.domain) return; var cmd = document.getElementById("cmd_highlight"); if (cmd) { v...
editor.isCSSEnabled = useCSS; }
editor.returnInParagraphCreatesNewParagraph = crInParagraphCreatesParagraph; }
observe: function(subject, topic, prefName) { if (!IsHTMLEditor()) return; // verify that we're changing a button pref if (topic != "nsPref:changed") return; if (prefName.substr(0, this.domain.length) != this.domain) return; var cmd = document.getElementById("cmd_highlight"); if (cmd) { v...
case progId+";onError": onError( data ); break;
Observe: function( subject, topic, data ) { switch ( topic ) { case progId+";onProgress": var words = data.split( " " ); onProgress( words[0], words[1] ); break; case progId+";onStatus": onStatus( data ); break; ...
observeModifyItem: function (aOldItem, aNewItem) {
observeModifyItem: function (aNewItem, aOldItem) {
observeModifyItem: function (aOldItem, aNewItem) { for each (obs in this.mObservers) obs.onModifyItem (aOldItem, aNewItem); },
obs.onModifyItem (aOldItem, aNewItem);
obs.onModifyItem (aNewItem, aOldItem);
observeModifyItem: function (aOldItem, aNewItem) { for each (obs in this.mObservers) obs.onModifyItem (aOldItem, aNewItem); },
if (!(item instanceof Components.interfaces.calIEvent)) return;
function observer_onDeleteItem(item, rebuildFlag){ if (!(item instanceof Components.interfaces.calIEvent)) return; var occs = item.getOccurrencesBetween(this.agendaTreeView.today.start, this.agendaTreeView.soon.end, {}); occs.forEach(this.agendaTreeView.deleteIte...
var radio = document.getElementById("all"); if (radio) { dump("radio value " + radio.checked + "\n"); if (radio.checked) { param.SetInt(1, 1); } else { param.SetInt(1, 0); } } param.SetInt(0, 1);
function OkButtonCallback() { nntpServer.maxArticles = numberElement.value; nntpServer.markOldRead = markreadElement.checked; return true;}
if (gSearchInput) gSearchInput.value =""; onAbSearchInput(true);
gSearchInput.value = ""; onEnterInSearchBar();
function onAbClearSearch() { if (gSearchInput) gSearchInput.value =""; //on input does not get fired for some reason onAbSearchInput(true);}
gStatusText.setAttribute("label", "");
function onAbSearchReset(event) { gPropertiesButton.setAttribute("disabled","true"); gComposeButton.setAttribute("disabled","true"); CloseAbView(); onReset(event);}
if (gDialog.labelText.value) { var textNode = editor.document.createTextNode(gDialog.labelText.value); editor.insertNode(textNode, labelElement, 0); editor.selectElement(labelElement); }
if (gDialog.labelText.value) editor.insertNode(editor.document.createTextNode(gDialog.labelText.value), labelElement, 0);
function onAccept(){ // All values are valid - copy to actual element in doc ValidateData(); var editor = GetCurrentEditor(); editor.beginTransaction(); try { if (gDialog.editText.checked) { editor.setShouldTxnSetSelection(false); while (labelElement.firstChild) editor.deleteNode(labelElemen...
if (gDialog.editText.checked)
} else if (gDialog.editText.checked)
function onAccept(){ // All values are valid - copy to actual element in doc ValidateData(); var editor = GetCurrentEditor(); editor.beginTransaction(); try { editor.cloneAttributes(legendElement, globalElement); if (insertNew) InsertElementAroundSelection(fieldsetElement); if (gDialog.editText.chec...
editor.DeleteNode(legendElement);
editor.deleteNode(legendElement);
function onAccept(){ // All values are valid - copy to actual element in doc ValidateData(); var editor = GetCurrentEditor(); editor.beginTransaction(); try { editor.cloneAttributes(legendElement, globalElement); if (insertNew) InsertElementAroundSelection(fieldsetElement); if (gDialog.editText.chec...
gPrintSetInterface.kInitSaveResolutionName | gPrintSetInterface.kInitSaveDownloadFonts |
function onAccept(){ if (gPrintSettings != null) { var print_howToEnableUI = gPrintSetInterface.kFrameEnableNone; var stringBundle = srGetStrBundle("chrome://global/locale/printing.properties"); var promptService = Components.classes["@mozilla.org/embedcomp/prompt-service;1"] .getServic...
if (gFindInstData && gFindInst != gFindInstData.webBrowserFind) { gFindInstData.init(); gFindInst = gFindInstData.webBrowserFind; }
function onAccept(){ // Transfer dialog contents to the find service. saveFindData(); // set up the find instance gFindInst.searchString = dialog.findKey.value; gFindInst.matchCase = dialog.caseSensitive.checked; gFindInst.wrapFind = dialog.wrap.checked; gFindInst.findBackwards = dialog.up.selected; ...
if (insertNew && !InsertElementAroundSelection(buttonElement))
if (insertNew)
function onAccept(){ // All values are valid - copy to actual element in doc or // element created to insert ValidateData(); var editor = GetCurrentEditor(); editor.cloneAttributes(buttonElement, globalElement); if (insertNew && !InsertElementAroundSelection(buttonElement)) { buttonElement.innerHTML = edito...
buttonElement.innerHTML = editor.outputToString("text/html", 1); editor.insertElementAtSelection(buttonElement, true);
if (!InsertElementAroundSelection(buttonElement)) { buttonElement.innerHTML = editor.outputToString("text/html", 1); editor.insertElementAtSelection(buttonElement, true); }
function onAccept(){ // All values are valid - copy to actual element in doc or // element created to insert ValidateData(); var editor = GetCurrentEditor(); editor.cloneAttributes(buttonElement, globalElement); if (insertNew && !InsertElementAroundSelection(buttonElement)) { buttonElement.innerHTML = edito...
SavePublishSiteDataToPrefs(null, gDefaultSiteName);
SetDefaultSiteName(gDefaultSiteName);
function onAccept(){ // Save any pending changes locally first if (gSettingsChanged && !UpdateSettings()) return false; if (gSiteDataChanged) { // Save all local data to prefs SavePublishSiteDataToPrefs(gPublishSiteData, gDefaultSiteName); } else if (gPreviousDefaultSite != gDefaultSiteName) { // onl...
window.onAcceptCallback(item, calendar, originalItem);
window.onAcceptCallback(item, calendar, window.originalItem);
function onAccept(){ // if this event isn't mutable, we need to clone it like a sheep var originalItem = window.calendarItem; var item = (originalItem.isMutable) ? originalItem : originalItem.clone(); saveDialog(item); var calendar = document.getElementById("item-calendar").selectedItem.calendar; wind...
var selectedInx = dialog.paperList.selectedIndex; if (gPaperArray[selectedInx].inches) {
var paperSelectedInx = dialog.paperList.selectedIndex; var plexSelectedInx = dialog.plexList.selectedIndex; if (gPaperArray[paperSelectedInx].inches) {
function onAccept(){ var print_paper_type = gPrintSettingsInterface.kPaperSizeDefined; var print_paper_unit = gPrintSettingsInterface.kPaperSizeInches; var print_paper_width = 0.0; var print_paper_height = 0.0; var print_paper_name = ""; if (gPrintSettings != null) { var selectedInx = dialog.paperList.s...
print_paper_width = gPaperArray[selectedInx].width; print_paper_height = gPaperArray[selectedInx].height; print_paper_name = gPaperArray[selectedInx].name; gPrintSettings.paperSize = gPaperArray[selectedInx].paperSize;
print_paper_width = gPaperArray[paperSelectedInx].width; print_paper_height = gPaperArray[paperSelectedInx].height; print_paper_name = gPaperArray[paperSelectedInx].name; print_plex_name = gPlexArray[plexSelectedInx].name; gPrintSettings.paperSize = gPaperArray[paperSelectedInx].paperSize;
function onAccept(){ var print_paper_type = gPrintSettingsInterface.kPaperSizeDefined; var print_paper_unit = gPrintSettingsInterface.kPaperSizeInches; var print_paper_width = 0.0; var print_paper_height = 0.0; var print_paper_name = ""; if (gPrintSettings != null) { var selectedInx = dialog.paperList.s...
dump("plexName '"+print_plex_name+"'\n");
function onAccept(){ var print_paper_type = gPrintSettingsInterface.kPaperSizeDefined; var print_paper_unit = gPrintSettingsInterface.kPaperSizeInches; var print_paper_width = 0.0; var print_paper_height = 0.0; var print_paper_name = ""; if (gPrintSettings != null) { var selectedInx = dialog.paperList.s...
if (tree.selectedItems.length < 1) return; var node = tree.selectedItems[0];
var result = getServerIdAndPageIdFromTree(tree);
function onAccountClick(tree) { if (tree.selectedItems.length < 1) return; var node = tree.selectedItems[0]; updateButtons(tree); // get the page to load // (stored in the PageTag attribute of this node) var pageId = node.getAttribute('PageTag'); // get the server's ID // (stored in the ID attribute of the ...
updateButtons(tree); var pageId = node.getAttribute('PageTag'); var servernode = node.parentNode.parentNode; if (servernode.tagName != "treeitem") { servernode = node;
if (result) { showPage(result.serverId, result.pageId); updateButtons(tree,result.serverId);
function onAccountClick(tree) { if (tree.selectedItems.length < 1) return; var node = tree.selectedItems[0]; updateButtons(tree); // get the page to load // (stored in the PageTag attribute of this node) var pageId = node.getAttribute('PageTag'); // get the server's ID // (stored in the ID attribute of the ...
var serverid = servernode.getAttribute('id'); showPage(serverid, pageId);
function onAccountClick(tree) { if (tree.selectedItems.length < 1) return; var node = tree.selectedItems[0]; updateButtons(tree); // get the page to load // (stored in the PageTag attribute of this node) var pageId = node.getAttribute('PageTag'); // get the server's ID // (stored in the ID attribute of the ...
function onAccountClick(tree) {
function onAccountClick(tree) { var currentSelection = getServerIdAndPageIdFromTree(tree);
function onAccountClick(tree) { //dump("onAccountClick()\n"); var result = getServerIdAndPageIdFromTree(tree); //dump("sputter:"+bug51546CurrentPage+","+bug51546CurrentServerId+":"+result.pageId+","+result.serverId+"\n"); if ((bug51546CurrentPage == result.pageId) && (bug51546CurrentServerId == result.serverId)) { ...