Bug 1296767 part 9 - Remove Old Sync link in about:accounts. r?markh draft
authorEdouard Oger <eoger@fastmail.com>
Thu, 19 Jan 2017 12:02:46 -0500
changeset 467369 54b01340514852b94662bb9b567bd5ff611e34ad
parent 467368 814b2604647786a204f93e3539e58fbd18b21617
child 467370 227eebd073abf6031570cffca234bc5b6536e5cc
push id43155
push userbmo:eoger@fastmail.com
push dateFri, 27 Jan 2017 18:31:15 +0000
reviewersmarkh
bugs1296767
milestone54.0a1
Bug 1296767 part 9 - Remove Old Sync link in about:accounts. r?markh MozReview-Commit-ID: 8HjZbLIT6YA
browser/base/content/aboutaccounts/aboutaccounts.js
browser/base/content/aboutaccounts/aboutaccounts.xhtml
browser/locales/en-US/chrome/browser/aboutAccounts.dtd
--- a/browser/base/content/aboutaccounts/aboutaccounts.js
+++ b/browser/base/content/aboutaccounts/aboutaccounts.js
@@ -299,28 +299,16 @@ var wrapper = {
       console.log("Failed to inject data", e);
       setErrorPage("configError");
     });
   },
 };
 
 
 // Button onclick handlers
-function handleOldSync() {
-  let chromeWin = window
-    .QueryInterface(Ci.nsIInterfaceRequestor)
-    .getInterface(Ci.nsIWebNavigation)
-    .QueryInterface(Ci.nsIDocShellTreeItem)
-    .rootTreeItem
-    .QueryInterface(Ci.nsIInterfaceRequestor)
-    .getInterface(Ci.nsIDOMWindow)
-    .QueryInterface(Ci.nsIDOMChromeWindow);
-  let url = Services.urlFormatter.formatURLPref("app.support.baseURL") + "old-sync";
-  chromeWin.switchToTabHavingURI(url, true);
-}
 
 function getStarted() {
   show("remote");
 }
 
 function retry() {
   show("remote");
   wrapper.retry();
@@ -498,20 +486,17 @@ function getDefaultProfilePath() {
 document.addEventListener("DOMContentLoaded", function() {
   init();
   var buttonGetStarted = document.getElementById("buttonGetStarted");
   buttonGetStarted.addEventListener("click", getStarted);
 
   var buttonRetry = document.getElementById("buttonRetry");
   buttonRetry.addEventListener("click", retry);
 
-  var oldsync = document.getElementById("oldsync");
-  oldsync.addEventListener("click", handleOldSync);
-
-  var buttonOpenPrefs = document.getElementById("buttonOpenPrefs")
+  var buttonOpenPrefs = document.getElementById("buttonOpenPrefs");
   buttonOpenPrefs.addEventListener("click", openPrefs);
 }, {capture: true, once: true});
 
 function initObservers() {
   function observe(subject, topic, data) {
     log("about:accounts observed " + topic);
     if (topic == fxAccountsCommon.ONLOGOUT_NOTIFICATION) {
       // All about:account windows get changed to action=signin on logout.
--- a/browser/base/content/aboutaccounts/aboutaccounts.xhtml
+++ b/browser/base/content/aboutaccounts/aboutaccounts.xhtml
@@ -58,20 +58,16 @@
         <section>
             <div class="graphic graphic-sync-intro"> </div>
 
             <div class="description">&aboutAccountsConfig.description;</div>
 
             <div class="button-row">
               <button id="buttonGetStarted" class="button" tabindex="1">&aboutAccountsConfig.startButton.label;</button>
             </div>
-
-            <div class="links">
-              <button id="oldsync" tabindex="2">&aboutAccountsConfig.useOldSync.label;</button>
-            </div>
         </section>
       </div>
 
       <div id="networkError">
         <header>
           <h1>&aboutAccounts.noConnection.title;</h1>
         </header>
 
--- a/browser/locales/en-US/chrome/browser/aboutAccounts.dtd
+++ b/browser/locales/en-US/chrome/browser/aboutAccounts.dtd
@@ -1,15 +1,14 @@
 <!-- This Source Code Form is subject to the terms of the Mozilla Public
    - License, v. 2.0. If a copy of the MPL was not distributed with this
    - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
 
 <!ENTITY aboutAccounts.welcome "Welcome to &syncBrand.shortName.label;">
 
 <!ENTITY aboutAccountsConfig.description "Sign in to sync your tabs, bookmarks, passwords &amp; more.">
 <!ENTITY aboutAccountsConfig.startButton.label "Get started">
-<!ENTITY aboutAccountsConfig.useOldSync.label "Using an older version of Sync?">
 <!ENTITY aboutAccountsConfig.syncPreferences.label "Sync preferences">
 <!ENTITY aboutAccounts.noConnection.title "No connection">
 <!ENTITY aboutAccounts.noConnection.description "You must be connected to the Internet to sign in.">
 <!ENTITY aboutAccounts.noConnection.retry "Try again">
 <!ENTITY aboutAccounts.badConfig.title "Bad configuration">
 <!ENTITY aboutAccounts.badConfig.description "Unable to determine your Firefox Account server configuration. Please try again later.">