[Pale-Moon] Remove excess whitespace.

This commit is contained in:
athenian200 2020-02-06 09:46:16 -06:00 • committed by Roy Tam
commit b6b33a6b2a
73 changed files with 1883 additions and 1883 deletions

View file

@ -20,7 +20,7 @@ var gSyncUI = {
_unloaded: false,
init: function () {
init: function() {
// Proceed to set up the UI if Sync has already started up.
// Otherwise we'll do it when Sync is firing up.
let xps = Components.classes["@mozilla.org/weave/service;1"]
@ -48,7 +48,7 @@ var gSyncUI = {
}, false);
},
initUI: function () {
initUI: function() {
// If this is a browser window?
if (gBrowser) {
this._obs.push("weave:notification:added");
@ -64,7 +64,7 @@ var gSyncUI = {
this.updateUI();
},
initNotifications: function () {
initNotifications: function() {
const XULNS = "http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul";
let notificationbox = document.createElementNS(XULNS, "notificationbox");
notificationbox.id = "sync-notifications";
@ -82,13 +82,13 @@ var gSyncUI = {
_wasDelayed: false,
_needsSetup: function () {
_needsSetup: function() {
let firstSync = Services.prefs.getCharPref("services.sync.firstSync", "");
return Weave.Status.checkSetup() == Weave.CLIENT_NOT_CONFIGURED ||
firstSync == "notReady";
},
updateUI: function () {
updateUI: function() {
let needsSetup = this._needsSetup();
document.getElementById("sync-setup-state").hidden = !needsSetup;
document.getElementById("sync-syncnow-state").hidden = needsSetup;
@ -108,7 +108,7 @@ var gSyncUI = {
// Functions called by observers
onActivityStart: function () {
onActivityStart: function() {
if (!gBrowser)
return;
@ -119,7 +119,7 @@ var gSyncUI = {
button.setAttribute("status", "active");
},
onSyncDelay: function () {
onSyncDelay: function() {
// basically, we want to just inform users that stuff is going to take a while
let title = this._stringBundle.GetStringFromName("error.sync.no_node_found.title");
let description = this._stringBundle.GetStringFromName("error.sync.no_node_found");
@ -134,17 +134,17 @@ var gSyncUI = {
this._wasDelayed = true;
},
onLoginFinish: function () {
onLoginFinish: function() {
// Clear out any login failure notifications
let title = this._stringBundle.GetStringFromName("error.login.title");
this.clearError(title);
},
onSetupComplete: function () {
onSetupComplete: function() {
this.onLoginFinish();
},
onLoginError: function () {
onLoginError: function() {
// if login fails, any other notifications are essentially moot
Weave.Notifications.removeAll();
@ -182,11 +182,11 @@ var gSyncUI = {
this.updateUI();
},
onLogout: function () {
onLogout: function() {
this.updateUI();
},
onStartOver: function () {
onStartOver: function() {
this.clearError();
},
@ -205,17 +205,17 @@ var gSyncUI = {
Weave.Notifications.replaceTitle(notification);
},
openServerStatus: function () {
openServerStatus: function() {
let statusURL = Services.prefs.getCharPref("services.sync.statusURL");
window.openUILinkIn(statusURL, "tab");
},
// Commands
doSync: function () {
doSync: function() {
setTimeout(function() Weave.Service.errorHandler.syncAndReportErrors(), 0);
},
handleToolbarButton: function () {
handleToolbarButton: function() {
if (this._needsSetup())
this.openSetup();
else
@ -235,7 +235,7 @@ var gSyncUI = {
* "reset" -- reset sync
*/
openSetup: function (wizardType) {
openSetup: function(wizardType) {
let win = Services.wm.getMostRecentWindow("Weave:AccountSetup");
if (win)
win.focus();
@ -246,7 +246,7 @@ var gSyncUI = {
}
},
openAddDevice: function () {
openAddDevice: function() {
if (!Weave.Utils.ensureMPUnlocked())
return;
@ -258,7 +258,7 @@ var gSyncUI = {
"syncAddDevice", "centerscreen,chrome,resizable=no");
},
openQuotaDialog: function () {
openQuotaDialog: function() {
let win = Services.wm.getMostRecentWindow("Sync:ViewQuota");
if (win)
win.focus();
@ -268,13 +268,13 @@ var gSyncUI = {
"centerscreen,chrome,dialog,modal");
},
openPrefs: function () {
openPrefs: function() {
openPreferences("paneSync");
},
// Helpers
_updateLastSyncTime: function () {
_updateLastSyncTime: function() {
if (!gBrowser)
return;
@ -296,12 +296,12 @@ var gSyncUI = {
syncButton.setAttribute("tooltiptext", lastSyncLabel);
},
clearError: function (errorString) {
clearError: function(errorString) {
Weave.Notifications.removeAll(errorString);
this.updateUI();
},
onSyncFinish: function () {
onSyncFinish: function() {
let title = this._stringBundle.GetStringFromName("error.sync.title");
// Clear out sync failures on a successful sync
@ -314,7 +314,7 @@ var gSyncUI = {
}
},
onSyncError: function () {
onSyncError: function() {
let title = this._stringBundle.GetStringFromName("error.sync.title");
if (Weave.Status.login != Weave.LOGIN_SUCCEEDED) {
@ -395,7 +395,7 @@ var gSyncUI = {
this.updateUI();
},
observe: function (subject, topic, data) {
observe: function(subject, topic, data) {
if (this._unloaded) {
Cu.reportError("SyncUI observer called after unload: " + topic);
return;