Bug 1481052 - 'Normalise' function definitions for main patch to apply. r+a=me
authorJorg K <jorgk@jorgk.com>
Thu, 29 Nov 2018 15:58:48 +0100
changeset 32677 4088f33deefaba669e3faae2bbd57f71fcca860b
parent 32676 dd975eb905a52f367bb577e994d3ee5a6b38e530
child 32678 9398d440a92d2e9a4f9126cd7287abb0ba5397ff
push id2341
push usermozilla@jorgk.com
push dateThu, 29 Nov 2018 15:19:09 +0000
treeherdercomm-beta@7ee2051d5d5d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1481052
Bug 1481052 - 'Normalise' function definitions for main patch to apply. r+a=me
mail/components/cloudfile/cloudFileAccounts.js
mail/components/cloudfile/content/addAccountDialog.js
mail/components/preferences/applications.js
--- a/mail/components/cloudfile/cloudFileAccounts.js
+++ b/mail/components/cloudfile/cloudFileAccounts.js
@@ -107,18 +107,17 @@ var cloudFileAccounts = {
       return provider;
     } catch (e) {
       Services.prefs.deleteBranch(ACCOUNT_ROOT + key);
       throw e;
     }
   },
 
   // Set provider-specific prefs
-  _processExtraPrefs: function CFA__processExtraPrefs(aAccountKey,
-                                                      aExtraPrefs) {
+  _processExtraPrefs(aAccountKey, aExtraPrefs) {
     const kFuncMap = {
       "int": "setIntPref",
       "bool": "setBoolPref",
       "char": "setCharPref",
     };
 
     for (let prefKey in aExtraPrefs) {
       let type = aExtraPrefs[prefKey].type;
@@ -162,29 +161,29 @@ var cloudFileAccounts = {
     }
   },
 
   get accounts() {
     return this._accountKeys.filter(key => this.getAccount(key) != null).
       map(key => this.getAccount(key));
   },
 
-  getAccountsForType: function CFA_getAccountsForType(aType) {
+  getAccountsForType(aType) {
     let result = [];
 
     for (let accountKey of this._accountKeys) {
       let type = Services.prefs.getCharPref(ACCOUNT_ROOT + accountKey + ".type");
       if (type === aType)
         result.push(this.getAccount(accountKey));
     }
 
     return result;
   },
 
-  addAccountDialog: function CFA_addAccountDialog() {
+  addAccountDialog() {
     let params = {accountKey: null};
     Services.wm
             .getMostRecentWindow(null)
             .openDialog("chrome://messenger/content/cloudfile/"
                         + "addAccountDialog.xul",
                         "", "chrome, dialog, modal, resizable=yes",
                         params).focus();
     return params.accountKey;
--- a/mail/components/cloudfile/content/addAccountDialog.js
+++ b/mail/components/cloudfile/content/addAccountDialog.js
@@ -155,24 +155,24 @@ var addAccountDialog = {
       this._settings.style.height = this._settings.style.minHeight = "16px";
       return;
     }
     let newHeight = this._settings.contentDocument.body.offsetHeight;
     this._settings.style.height = this._settings.style.minHeight = newHeight + "px";
     window.sizeToContent();
   },
 
-  removeTitleMenuItem: function AAD_removeTitleMenuItem() {
+  removeTitleMenuItem() {
     let menuitem = this._accountType.querySelector('menuitem[value=""]');
     if (menuitem)
       menuitem.remove();
   },
 
   // Return number of additions to the menulist, zero if none happened.
-  addAccountTypes: function AAD_addAccountTypes() {
+  addAccountTypes() {
     let accountTypeTotal = 0;
     for (let [key, provider] of cloudFileAccounts.enumerateProviders()) {
       // If we already have an account for this type, don't add it to the list.
       // This limitation will hopefully be removed in the future.
       if (cloudFileAccounts.getAccountsForType(key).length > 0)
         continue;
 
       if (this._blacklist.has(key))
@@ -222,17 +222,17 @@ var addAccountDialog = {
 
     this._messages.selectedPanel = this._authSpinner;
 
     // Uninitialize the dialog before closing.
     this.onUnInit();
     return false;
   },
 
-  getExtraArgs: function AAD_getExtraArgs() {
+  getExtraArgs() {
     if (!this._settings)
       return {};
 
     let func = this._settings.contentWindow
                    .wrappedJSObject
                    .extraArgs;
     if (!func)
       return {};
@@ -251,17 +251,17 @@ var addAccountDialog = {
 
     // Reset the message display
     this._messages.selectedIndex = -1;
 
     // Load up the correct XHTML page for this provider.
     this._settings.contentDocument.location.href = provider.settingsURL;
   },
 
-  onClickLink: function AAD_onClickLink(e) {
+  onClickLink(e) {
     e.preventDefault();
     let href = e.target.getAttribute("href");
     gProtocolService.loadURI(Services.io.newURI(href, "UTF-8"));
   },
 
   onInput: function AAD_onInput() {
     // Let's see if we have everything we need to make OK enabled...
     if (this._accountType.selectedIndex == -1) {
--- a/mail/components/preferences/applications.js
+++ b/mail/components/preferences/applications.js
@@ -819,17 +819,17 @@ var gCloudFileTab = {
       this._showAccountManagement(account);
     } else if (result == Ci.nsIMsgCloudFileProvider.authErr) {
       this._settingsDeck.selectedPanel = this._authErrorPanel;
     } else {
       Cu.reportError("Unexpected connection error.");
     }
   },
 
-  _showAccountManagement: function CFT__showAccountManagement(aProvider) {
+  _showAccountManagement(aProvider) {
     let iframe = document.createElement("iframe");
 
     iframe.setAttribute("src", aProvider.managementURL);
     iframe.setAttribute("flex", "1");
 
     // If we have a past iframe, we replace it. Else append
     // to the wrapper.
     if (this._settings)