Add support for Thunderbird 60
authorSukhbir Singh <sukhbir@torproject.org>
Sun, 6 May 2018 22:48:06 +0000 (18:48 -0400)
committerSukhbir Singh <sukhbir@torproject.org>
Sun, 6 May 2018 22:48:06 +0000 (18:48 -0400)
See https://wiki.mozilla.org/Thunderbird/Add-ons_Guide_57 for changes
relevant to Thunderbird 60. This commit also bumps up the minimum
supported version to Thunderbird 52.

chrome/content/accountWizard/accountWizard.js
chrome/content/accountWizard/accountWizard.xul
chrome/content/accountWizard/createInBackend.js
install.rdf.template

index cdd02f0..b04b2a9 100644 (file)
@@ -589,7 +589,7 @@ BitmaskAccountWizard.prototype =
         { id: "next_button", action: makeCallback(this, this.onNext) },
         { id: "create_button", action: makeCallback(this, this.onCreate) },
       ];
-      for each (let button in buttons) {
+      for (let button of buttons) {
         button.e = e(button.id);
         if (button.e.hidden || button.e.disabled) {
           continue;
index 2ffbffc..681817d 100644 (file)
@@ -21,7 +21,7 @@
 <window xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
         id="autoconfigWizard"
         windowtype="mail:autoconfig"
-        title="&autoconfigWizard.title;"
+        title="&autoconfigWizard2.title;"
         onload="gBitmaskAccountWizard.onLoad();"
         onkeypress="gBitmaskAccountWizard.onKeyDown(event)"
         onclose="gBitmaskAccountWizard.onWizardShutdown();"
                  control="email"/>
           <textbox id="email"
                    class="padded uri-element"
-                   placeholder="&email.placeholder;"
+                   placeholder="&email2.placeholder;"
                    oninput="gBitmaskAccountWizard.onInputEmail();"
                    onblur="gBitmaskAccountWizard.onBlurEmail();"/>
           <hbox>
index 46dbbae..ed2424b 100644 (file)
@@ -218,7 +218,7 @@ function doNotCache(inServer)
   inServerQI.offlineDownload = false;
   // and remove offline flag from all folders
   var allFolders = inServer.rootFolder.descendants;
-  for (let folder in fixIterator(allFolders, Components.interfaces.nsIMsgFolder))
+  for (let folder of fixIterator(allFolders, Components.interfaces.nsIMsgFolder))
     folder.clearFlag(Components.interfaces.nsMsgFolderFlags.Offline);
 }
 
@@ -236,8 +236,12 @@ function rememberPassword(server, password)
   login.init(passwordURI, null, passwordURI, server.username, password, "", "");
   try {
     Services.logins.addLogin(login);
-  } catch (e if e.message.includes("This login already exists")) {
-    // TODO modify
+  } catch (e) {
+    if (e.message.includes("This login already exists")) {
+      // TODO modify
+    } else {
+      throw e;
+    }
   }
 }
 
index bbdeab3..9d7c44f 100644 (file)
@@ -35,8 +35,8 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
     <em:targetApplication>
       <Description>
         <em:id>{3550f703-e582-4d05-9a08-453d09bdfdc6}</em:id>
-        <em:minVersion>24.0</em:minVersion>
-        <em:maxVersion>31.*</em:maxVersion>
+        <em:minVersion>52.0</em:minVersion>
+        <em:maxVersion>60.0</em:maxVersion>
       </Description>
     </em:targetApplication>
     <em:localized>