Bug 1331521 Remove about:newaddon r=kmag
authorAndrew Swan <aswan@mozilla.com>
Mon, 16 Apr 2018 14:11:10 -0700
changeset 413976 c85fefa9248cf393873f8abff5e6d3a3ce65de81
parent 413975 3793175d2c0075364ad2b45d27f2ec28a621654b
child 413977 4c40ad65f4724f1e647002dc0f84b6b71cae5f50
push id33853
push usercbrindusan@mozilla.com
push dateTue, 17 Apr 2018 09:51:13 +0000
treeherdermozilla-central@8b0ba3f7d099 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskmag
bugs1331521
milestone61.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1331521 Remove about:newaddon r=kmag MozReview-Commit-ID: 6OFXGYEmSmy
browser/base/content/browser-siteIdentity.js
browser/base/content/browser.js
browser/modules/ExtensionsUI.jsm
docshell/base/nsAboutRedirector.cpp
docshell/build/nsDocShellModule.cpp
toolkit/locales/en-US/chrome/mozapps/extensions/newaddon.dtd
toolkit/locales/en-US/chrome/mozapps/extensions/newaddon.properties
toolkit/locales/jar.mn
toolkit/mozapps/extensions/content/newaddon.js
toolkit/mozapps/extensions/content/newaddon.xul
toolkit/mozapps/extensions/jar.mn
toolkit/mozapps/extensions/test/browser/browser.ini
toolkit/mozapps/extensions/test/browser/browser_newaddon.js
toolkit/themes/linux/mozapps/extensions/newaddon.css
toolkit/themes/linux/mozapps/jar.mn
toolkit/themes/osx/mozapps/extensions/newaddon.css
toolkit/themes/osx/mozapps/jar.mn
toolkit/themes/shared/extensions/newaddon.inc.css
toolkit/themes/windows/mozapps/extensions/newaddon.css
toolkit/themes/windows/mozapps/jar.mn
--- a/browser/base/content/browser-siteIdentity.js
+++ b/browser/base/content/browser-siteIdentity.js
@@ -50,17 +50,17 @@ var gIdentityHandler = {
    * to be able to focus it on the popupshown event.
    */
   _popupTriggeredByKeyboard: false,
 
   /**
    * RegExp used to decide if an about url should be shown as being part of
    * the browser UI.
    */
-  _secureInternalUIWhitelist: /^(?:accounts|addons|cache|config|crashes|customizing|downloads|healthreport|license|newaddon|permissions|preferences|rights|searchreset|sessionrestore|support|welcomeback)(?:[?#]|$)/i,
+  _secureInternalUIWhitelist: /^(?:accounts|addons|cache|config|crashes|customizing|downloads|healthreport|license|permissions|preferences|rights|searchreset|sessionrestore|support|welcomeback)(?:[?#]|$)/i,
 
   get _isBroken() {
     return this._state & Ci.nsIWebProgressListener.STATE_IS_BROKEN;
   },
 
   get _isSecure() {
     // If a <browser> is included within a chrome document, then this._state
     // will refer to the security state for the <browser> and not the top level
--- a/browser/base/content/browser.js
+++ b/browser/base/content/browser.js
@@ -7349,17 +7349,17 @@ var gIdentityHandler = {
    * to be able to focus it on the popupshown event.
    */
   _popupTriggeredByKeyboard: false,
 
   /**
    * RegExp used to decide if an about url should be shown as being part of
    * the browser UI.
    */
-  _secureInternalUIWhitelist: /^(?:accounts|addons|cache|config|crashes|customizing|downloads|healthreport|license|newaddon|permissions|preferences|rights|searchreset|sessionrestore|support|welcomeback)(?:[?#]|$)/i,
+  _secureInternalUIWhitelist: /^(?:accounts|addons|cache|config|crashes|customizing|downloads|healthreport|license|permissions|preferences|rights|searchreset|sessionrestore|support|welcomeback)(?:[?#]|$)/i,
 
   get _isBroken() {
     return this._state & Ci.nsIWebProgressListener.STATE_IS_BROKEN;
   },
 
   get _isSecure() {
     // If a <browser> is included within a chrome document, then this._state
     // will refer to the security state for the <browser> and not the top level
--- a/browser/modules/ExtensionsUI.jsm
+++ b/browser/modules/ExtensionsUI.jsm
@@ -92,23 +92,16 @@ var ExtensionsUI = {
         };
         AddonManager.addAddonListener(this.sideloadListener);
       }
 
       for (let addon of sideloaded) {
         this.sideloaded.add(addon);
       }
         this._updateNotifications();
-    } else {
-      // This and all the accompanying about:newaddon code can eventually
-      // be removed.  See bug 1331521.
-      let win = RecentWindow.getMostRecentBrowserWindow();
-      for (let addon of sideloaded) {
-        win.openTrustedLinkIn(`about:newaddon?id=${addon.id}`, "tab");
-      }
     }
   },
 
   async _checkNewDistroAddons() {
     let newDistroAddons = AddonManagerPrivate.getNewDistroAddons();
     if (!newDistroAddons) {
       return;
     }
--- a/docshell/base/nsAboutRedirector.cpp
+++ b/docshell/base/nsAboutRedirector.cpp
@@ -79,21 +79,16 @@ static const RedirEntry kRedirMap[] = {
       nsIAboutModule::ALLOW_SCRIPT |
       nsIAboutModule::HIDE_FROM_ABOUTABOUT
   },
   {
     "networking", "chrome://global/content/aboutNetworking.xhtml",
     nsIAboutModule::ALLOW_SCRIPT
   },
   {
-    "newaddon", "chrome://mozapps/content/extensions/newaddon.xul",
-    nsIAboutModule::ALLOW_SCRIPT |
-      nsIAboutModule::HIDE_FROM_ABOUTABOUT
-  },
-  {
     "performance", "chrome://global/content/aboutPerformance.xhtml",
     nsIAboutModule::ALLOW_SCRIPT
   },
   {
     "plugins", "chrome://global/content/plugins.html",
     nsIAboutModule::URI_MUST_LOAD_IN_CHILD
   },
   {
--- a/docshell/build/nsDocShellModule.cpp
+++ b/docshell/build/nsDocShellModule.cpp
@@ -180,17 +180,16 @@ const mozilla::Module::ContractIDEntry k
 #endif
   { NS_ABOUT_MODULE_CONTRACTID_PREFIX "credits", &kNS_ABOUT_REDIRECTOR_MODULE_CID },
   { NS_ABOUT_MODULE_CONTRACTID_PREFIX "license", &kNS_ABOUT_REDIRECTOR_MODULE_CID },
   { NS_ABOUT_MODULE_CONTRACTID_PREFIX "logo", &kNS_ABOUT_REDIRECTOR_MODULE_CID },
   { NS_ABOUT_MODULE_CONTRACTID_PREFIX "memory", &kNS_ABOUT_REDIRECTOR_MODULE_CID },
   { NS_ABOUT_MODULE_CONTRACTID_PREFIX "mozilla", &kNS_ABOUT_REDIRECTOR_MODULE_CID },
   { NS_ABOUT_MODULE_CONTRACTID_PREFIX "neterror", &kNS_ABOUT_REDIRECTOR_MODULE_CID },
   { NS_ABOUT_MODULE_CONTRACTID_PREFIX "networking", &kNS_ABOUT_REDIRECTOR_MODULE_CID },
-  { NS_ABOUT_MODULE_CONTRACTID_PREFIX "newaddon", &kNS_ABOUT_REDIRECTOR_MODULE_CID },
   { NS_ABOUT_MODULE_CONTRACTID_PREFIX "performance", &kNS_ABOUT_REDIRECTOR_MODULE_CID },
   { NS_ABOUT_MODULE_CONTRACTID_PREFIX "plugins", &kNS_ABOUT_REDIRECTOR_MODULE_CID },
   { NS_ABOUT_MODULE_CONTRACTID_PREFIX "serviceworkers", &kNS_ABOUT_REDIRECTOR_MODULE_CID },
 #ifndef ANDROID
   { NS_ABOUT_MODULE_CONTRACTID_PREFIX "profiles", &kNS_ABOUT_REDIRECTOR_MODULE_CID },
 #endif
   { NS_ABOUT_MODULE_CONTRACTID_PREFIX "srcdoc", &kNS_ABOUT_REDIRECTOR_MODULE_CID },
   { NS_ABOUT_MODULE_CONTRACTID_PREFIX "support", &kNS_ABOUT_REDIRECTOR_MODULE_CID },
deleted file mode 100644
--- a/toolkit/locales/en-US/chrome/mozapps/extensions/newaddon.dtd
+++ /dev/null
@@ -1,15 +0,0 @@
-<!-- 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 title           "Install Add-on">
-<!ENTITY intro           "Another program on your computer would like to modify
-                          &brandShortName; with the following add-on:">
-<!ENTITY warning         "Install add-ons only from authors whom you trust.">
-<!ENTITY allow           "Allow this installation">
-<!ENTITY later           "You can always change your mind at any time by going
-                          to the Add-ons Manager.">
-<!ENTITY continue        "Continue">
-<!ENTITY restartMessage  "You must restart &brandShortName; to finish installing this add-on.">
-<!ENTITY restartButton   "Restart &brandShortName;">
-<!ENTITY cancelButton    "Cancel">
deleted file mode 100644
--- a/toolkit/locales/en-US/chrome/mozapps/extensions/newaddon.properties
+++ /dev/null
@@ -1,10 +0,0 @@
-# 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/.
-
-#LOCALIZATION NOTE (name) %1$S is the add-on name, %2$S is the add-on version
-name=%1$S %2$S
-#LOCALIZATION NOTE (author) %S is the author of the add-on
-author=By %S
-#LOCALIZATION NOTE (location) %S is the path the add-on is installed in
-location=Location: %S
--- a/toolkit/locales/jar.mn
+++ b/toolkit/locales/jar.mn
@@ -90,18 +90,16 @@
   locale/@AB_CD@/mozapps/downloads/unknownContentType.dtd         (%chrome/mozapps/downloads/unknownContentType.dtd)
   locale/@AB_CD@/mozapps/downloads/settingsChange.dtd             (%chrome/mozapps/downloads/settingsChange.dtd)
   locale/@AB_CD@/mozapps/downloads/downloads.properties           (%chrome/mozapps/downloads/downloads.properties)
   locale/@AB_CD@/mozapps/extensions/extensions.dtd                (%chrome/mozapps/extensions/extensions.dtd)
 #ifndef MOZ_FENNEC
   locale/@AB_CD@/mozapps/extensions/extensions.properties         (%chrome/mozapps/extensions/extensions.properties)
   locale/@AB_CD@/mozapps/extensions/blocklist.dtd                 (%chrome/mozapps/extensions/blocklist.dtd)
   locale/@AB_CD@/mozapps/extensions/update.properties             (%chrome/mozapps/extensions/update.properties)
-  locale/@AB_CD@/mozapps/extensions/newaddon.dtd                  (%chrome/mozapps/extensions/newaddon.dtd)
-  locale/@AB_CD@/mozapps/extensions/newaddon.properties           (%chrome/mozapps/extensions/newaddon.properties)
 #endif
   locale/@AB_CD@/mozapps/handling/handling.dtd                    (%chrome/mozapps/handling/handling.dtd)
   locale/@AB_CD@/mozapps/handling/handling.properties             (%chrome/mozapps/handling/handling.properties)
   locale/@AB_CD@/mozapps/preferences/changemp.dtd                 (%chrome/mozapps/preferences/changemp.dtd)
   locale/@AB_CD@/mozapps/preferences/removemp.dtd                 (%chrome/mozapps/preferences/removemp.dtd)
   locale/@AB_CD@/mozapps/preferences/preferences.properties       (%chrome/mozapps/preferences/preferences.properties)
   locale/@AB_CD@/mozapps/profile/createProfileWizard.dtd          (%chrome/mozapps/profile/createProfileWizard.dtd)
   locale/@AB_CD@/mozapps/profile/profileSelection.properties      (%chrome/mozapps/profile/profileSelection.properties)
deleted file mode 100644
--- a/toolkit/mozapps/extensions/content/newaddon.js
+++ /dev/null
@@ -1,132 +0,0 @@
-/* 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/. */
-
-/* exported cancelClicked, continueClicked, initialize, restartClicked, unload */
-
-ChromeUtils.import("resource://gre/modules/Services.jsm");
-ChromeUtils.import("resource://gre/modules/AddonManager.jsm");
-
-var gAddon = null;
-
-// If the user enables the add-on through some other UI close this window
-var EnableListener = {
-  onEnabling(aAddon) {
-    if (aAddon.id == gAddon.id)
-      window.close();
-  }
-};
-AddonManager.addAddonListener(EnableListener);
-
-function initialize() {
-  // About URIs don't implement nsIURL so we have to find the query string
-  // manually
-  let spec = document.location.href;
-  let pos = spec.indexOf("?");
-  let query = "";
-  if (pos >= 0)
-    query = spec.substring(pos + 1);
-
-  // Just assume the query is "id=<id>"
-  let id = query.substring(3);
-  if (!id) {
-    window.location = "about:blank";
-    return;
-  }
-
-  let bundle = Services.strings.createBundle("chrome://mozapps/locale/extensions/newaddon.properties");
-
-  AddonManager.getAddonByID(id, function(aAddon) {
-    // If the add-on doesn't exist or it is already enabled or it has already
-    // been seen or it cannot be enabled then this UI is useless, just close it.
-    // This shouldn't normally happen unless session restore restores the tab.
-    if (!aAddon || !aAddon.userDisabled || aAddon.seen ||
-        !(aAddon.permissions & AddonManager.PERM_CAN_ENABLE)) {
-      window.close();
-      return;
-    }
-
-    gAddon = aAddon;
-
-    document.getElementById("addon-info").setAttribute("type", aAddon.type);
-
-    let icon = document.getElementById("icon");
-    if (aAddon.icon64URL)
-      icon.src = aAddon.icon64URL;
-    else if (aAddon.iconURL)
-      icon.src = aAddon.iconURL;
-
-    let name = bundle.formatStringFromName("name", [aAddon.name, aAddon.version],
-                                           2);
-    document.getElementById("name").value = name;
-
-    if (aAddon.creator) {
-      let creator = bundle.formatStringFromName("author", [aAddon.creator], 1);
-      document.getElementById("author").value = creator;
-    } else {
-      document.getElementById("author").hidden = true;
-    }
-
-    let uri = "getResourceURI" in aAddon ? aAddon.getResourceURI() : null;
-    let locationLabel = document.getElementById("location");
-    if (uri instanceof Ci.nsIFileURL) {
-      let location = bundle.formatStringFromName("location", [uri.file.path], 1);
-      locationLabel.value = location;
-      locationLabel.setAttribute("tooltiptext", location);
-    } else {
-      document.getElementById("location").hidden = true;
-    }
-
-    // Only mark the add-on as seen if the page actually gets focus
-    if (document.hasFocus()) {
-      aAddon.markAsSeen();
-    } else {
-      document.addEventListener("focus", () => aAddon.markAsSeen());
-    }
-
-    var event = document.createEvent("Events");
-    event.initEvent("AddonDisplayed", true, true);
-    document.dispatchEvent(event);
-  });
-}
-
-function unload() {
-  AddonManager.removeAddonListener(EnableListener);
-}
-
-function continueClicked() {
-  AddonManager.removeAddonListener(EnableListener);
-
-  if (document.getElementById("allow").checked) {
-    gAddon.userDisabled = false;
-
-    if (gAddon.pendingOperations & AddonManager.PENDING_ENABLE) {
-      document.getElementById("allow").disabled = true;
-      document.getElementById("buttonDeck").selectedPanel = document.getElementById("restartPanel");
-      return;
-    }
-  }
-
-  window.close();
-}
-
-function restartClicked() {
-  let cancelQuit = Cc["@mozilla.org/supports-PRBool;1"].
-                   createInstance(Ci.nsISupportsPRBool);
-  Services.obs.notifyObservers(cancelQuit, "quit-application-requested",
-                               "restart");
-  if (cancelQuit.data)
-    return; // somebody canceled our quit request
-
-  window.close();
-
-  Services.startup.quit(Ci.nsIAppStartup.eAttemptQuit | Ci.nsIAppStartup.eRestart);
-}
-
-function cancelClicked() {
-  gAddon.userDisabled = true;
-  AddonManager.addAddonListener(EnableListener);
-
-  document.getElementById("allow").disabled = false;
-  document.getElementById("buttonDeck").selectedPanel = document.getElementById("continuePanel");
-}
deleted file mode 100644
--- a/toolkit/mozapps/extensions/content/newaddon.xul
+++ /dev/null
@@ -1,67 +0,0 @@
-<?xml version="1.0"?>
-<!-- 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/. -->
-
-<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
-<?xml-stylesheet href="chrome://mozapps/skin/extensions/newaddon.css"?>
-
-<!DOCTYPE page [
-<!ENTITY % brandDTD SYSTEM "chrome://branding/locale/brand.dtd" >
-%brandDTD;
-<!ENTITY % newaddonDTD SYSTEM "chrome://mozapps/locale/extensions/newaddon.dtd">
-%newaddonDTD;
-]>
-
-<page xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
-      xmlns:xhtml="http://www.w3.org/1999/xhtml" title="&title;"
-      disablefastfind="true" id="addon-page" onload="initialize()"
-      onunload="unload()" role="application" align="stretch" pack="stretch">
-
-  <xhtml:link rel="shortcut icon" style="display: none"
-              href="chrome://mozapps/skin/extensions/extensionGeneric-16.svg"/>
-
-  <script type="application/javascript"
-          src="chrome://mozapps/content/extensions/newaddon.js"/>
-
-  <scrollbox id="addon-scrollbox" align="center">
-    <spacer id="spacer-start"/>
-
-    <vbox id="addon-container" class="main-content">
-      <description>&intro;</description>
-
-      <hbox id="addon-info">
-        <image id="icon"/>
-        <vbox flex="1">
-          <label id="name"/>
-          <label id="author"/>
-          <label id="location" crop="end"/>
-        </vbox>
-      </hbox>
-
-      <hbox id="warning">
-        <image id="warning-icon"/>
-        <description flex="1">&warning;</description>
-      </hbox>
-
-      <checkbox id="allow" label="&allow;"/>
-      <description id="later">&later;</description>
-
-      <deck id="buttonDeck">
-        <hbox id="continuePanel">
-          <button id="continue-button" label="&continue;"
-                  oncommand="continueClicked()"/>
-        </hbox>
-        <vbox id="restartPanel">
-          <description id="restartMessage">&restartMessage;</description>
-          <hbox id="restartPanelButtons">
-            <button id="restart-button" label="&restartButton;" oncommand="restartClicked()"/>
-            <button id="cancel-button" label="&cancelButton;" oncommand="cancelClicked()"/>
-          </hbox>
-        </vbox>
-      </deck>
-    </vbox>
-
-    <spacer id="spacer-end"/>
-  </scrollbox>
-</page>
--- a/toolkit/mozapps/extensions/jar.mn
+++ b/toolkit/mozapps/extensions/jar.mn
@@ -14,18 +14,16 @@ toolkit.jar:
   content/mozapps/extensions/blocklist.js                       (content/blocklist.js)
   content/mozapps/extensions/blocklist.css                      (content/blocklist.css)
   content/mozapps/extensions/blocklist.xml                      (content/blocklist.xml)
   content/mozapps/extensions/update.html                        (content/update.html)
   content/mozapps/extensions/update.js                          (content/update.js)
   content/mozapps/extensions/update.css                         (content/update.css)
   content/mozapps/extensions/eula.xul                           (content/eula.xul)
   content/mozapps/extensions/eula.js                            (content/eula.js)
-  content/mozapps/extensions/newaddon.xul                       (content/newaddon.xul)
-  content/mozapps/extensions/newaddon.js                        (content/newaddon.js)
   content/mozapps/extensions/pluginPrefs.xul                    (content/pluginPrefs.xul)
   content/mozapps/extensions/pluginPrefs.js                     (content/pluginPrefs.js)
   content/mozapps/extensions/OpenH264-license.txt               (content/OpenH264-license.txt)
 #endif
   content/mozapps/xpinstall/xpinstallConfirm.xul                (content/xpinstallConfirm.xul)
   content/mozapps/xpinstall/xpinstallConfirm.js                 (content/xpinstallConfirm.js)
   content/mozapps/xpinstall/xpinstallConfirm.css                (content/xpinstallConfirm.css)
   content/mozapps/xpinstall/xpinstallItem.xml                   (content/xpinstallItem.xml)
--- a/toolkit/mozapps/extensions/test/browser/browser.ini
+++ b/toolkit/mozapps/extensions/test/browser/browser.ini
@@ -70,17 +70,16 @@ skip-if = os == 'linux' && !debug # Bug 
 [browser_inlinesettings_browser.js]
 [browser_installssl.js]
 [browser_langpack_signing.js]
 [browser_legacy.js]
 [browser_legacy_pre57.js]
 [browser_legacy_themes.js]
 [browser_list.js]
 [browser_manualupdates.js]
-[browser_newaddon.js]
 [browser_pluginprefs.js]
 [browser_pluginprefs_is_not_disabled.js]
 skip-if = buildapp == 'mulet'
 [browser_plugin_enabled_state_locked.js]
 [browser_recentupdates.js]
 [browser_sorting.js]
 [browser_sorting_plugins.js]
 [browser_tabsettings.js]
deleted file mode 100644
--- a/toolkit/mozapps/extensions/test/browser/browser_newaddon.js
+++ /dev/null
@@ -1,230 +0,0 @@
-/* Any copyright is dedicated to the Public Domain.
- * http://creativecommons.org/publicdomain/zero/1.0/
- */
-
-// Tests the new add-on tab
-
-var gProvider;
-
-function loadPage(aURL, aCallback, aBackground = false) {
-  let tab = BrowserTestUtils.addTab(gBrowser);
-  if (!aBackground)
-    gBrowser.selectedTab = tab;
-  let browser = tab.linkedBrowser;
-  browser.loadURI(aURL);
-  browser.addEventListener("AddonDisplayed", function(event) {
-    aCallback(tab);
-  }, {once: true});
-}
-
-function test() {
-  waitForExplicitFinish();
-
-  gProvider = new MockProvider();
-
-  gProvider.createAddons([{
-    id: "addon1@tests.mozilla.org",
-    name: "Test 1",
-    version: "5.3",
-    userDisabled: true,
-    seen: false,
-    operationsRequiringRestart: AddonManager.OP_NEEDS_RESTART_NONE
-  }, {
-    id: "addon2@tests.mozilla.org",
-    name: "Test 2",
-    version: "7.1",
-    creator: "Dave Townsend",
-    userDisabled: true,
-    seen: false
-  }]);
-
-  run_next_test();
-}
-
-function end_test() {
-  finish();
-}
-
-// Tests that ignoring a restartless add-on works
-add_test(function() {
-  loadPage("about:newaddon?id=addon1@tests.mozilla.org", function(aTab) {
-    var doc = aTab.linkedBrowser.contentDocument;
-    is(doc.getElementById("name").value, "Test 1 5.3", "Should say the right name");
-
-    is_element_hidden(doc.getElementById("author"), "Should be no author displayed");
-    is_element_hidden(doc.getElementById("location"), "Should be no location displayed");
-
-    is(doc.getElementById("buttonDeck").selectedPanel, doc.getElementById("continuePanel"),
-       "Should be showing the right buttons");
-
-    AddonManager.getAddonByID("addon1@tests.mozilla.org", function(aAddon) {
-      ok(aAddon.seen, "Add-on should have been marked as seen");
-
-      EventUtils.synthesizeMouseAtCenter(doc.getElementById("continue-button"),
-                                         {}, aTab.linkedBrowser.contentWindow);
-
-      is(gBrowser.tabs.length, 1, "Page should have been closed");
-
-      ok(aAddon.userDisabled, "Add-on should not have been enabled");
-
-      ok(!aAddon.isActive, "Add-on should not be running");
-
-      aAddon.seen = false;
-      run_next_test();
-    });
-  });
-});
-
-// Tests that enabling a restartless add-on works
-add_test(function() {
-  loadPage("about:newaddon?id=addon1@tests.mozilla.org", function(aTab) {
-    var doc = aTab.linkedBrowser.contentDocument;
-    is(doc.getElementById("name").value, "Test 1 5.3", "Should say the right name");
-
-    is_element_hidden(doc.getElementById("author"), "Should be no author displayed");
-    is_element_hidden(doc.getElementById("location"), "Should be no location displayed");
-
-    is(doc.getElementById("buttonDeck").selectedPanel, doc.getElementById("continuePanel"),
-       "Should be showing the right buttons");
-
-    AddonManager.getAddonByID("addon1@tests.mozilla.org", function(aAddon) {
-      ok(aAddon.seen, "Add-on should have been marked as seen");
-
-      EventUtils.synthesizeMouseAtCenter(doc.getElementById("allow"),
-                                         {}, aTab.linkedBrowser.contentWindow);
-
-      EventUtils.synthesizeMouseAtCenter(doc.getElementById("continue-button"),
-                                         {}, aTab.linkedBrowser.contentWindow);
-
-      is(gBrowser.tabs.length, 1, "Page should have been closed");
-
-      ok(!aAddon.userDisabled, "Add-on should now have been enabled");
-
-      ok(aAddon.isActive, "Add-on should now be running");
-
-      aAddon.userDisabled = true;
-      aAddon.seen = false;
-      run_next_test();
-    });
-  });
-});
-
-// Tests that ignoring a non-restartless add-on works
-add_test(function() {
-  loadPage("about:newaddon?id=addon2@tests.mozilla.org", function(aTab) {
-    var doc = aTab.linkedBrowser.contentDocument;
-    is(doc.getElementById("name").value, "Test 2 7.1", "Should say the right name");
-
-    is_element_visible(doc.getElementById("author"), "Should be an author displayed");
-    is(doc.getElementById("author").value, "By Dave Townsend", "Should have the right author");
-    is_element_hidden(doc.getElementById("location"), "Should be no location displayed");
-
-    is(doc.getElementById("buttonDeck").selectedPanel, doc.getElementById("continuePanel"),
-       "Should be showing the right buttons");
-
-    AddonManager.getAddonByID("addon2@tests.mozilla.org", function(aAddon) {
-      ok(aAddon.seen, "Add-on should have been marked as seen");
-
-      EventUtils.synthesizeMouseAtCenter(doc.getElementById("continue-button"),
-                                         {}, aTab.linkedBrowser.contentWindow);
-
-      is(gBrowser.tabs.length, 1, "Page should have been closed");
-
-      ok(aAddon.userDisabled, "Add-on should not have been enabled");
-
-      ok(!aAddon.isActive, "Add-on should not be running");
-
-      aAddon.seen = false;
-      run_next_test();
-    });
-  });
-});
-
-// Tests that enabling a non-restartless add-on works
-add_test(function() {
-  loadPage("about:newaddon?id=addon2@tests.mozilla.org", function(aTab) {
-    var doc = aTab.linkedBrowser.contentDocument;
-    is(doc.getElementById("name").value, "Test 2 7.1", "Should say the right name");
-
-    is_element_visible(doc.getElementById("author"), "Should be an author displayed");
-    is(doc.getElementById("author").value, "By Dave Townsend", "Should have the right author");
-    is_element_hidden(doc.getElementById("location"), "Should be no location displayed");
-
-    is(doc.getElementById("buttonDeck").selectedPanel, doc.getElementById("continuePanel"),
-       "Should be showing the right buttons");
-
-    AddonManager.getAddonByID("addon2@tests.mozilla.org", function(aAddon) {
-      ok(aAddon.seen, "Add-on should have been marked as seen");
-
-      EventUtils.synthesizeMouseAtCenter(doc.getElementById("allow"),
-                                         {}, aTab.linkedBrowser.contentWindow);
-
-      EventUtils.synthesizeMouseAtCenter(doc.getElementById("continue-button"),
-                                         {}, aTab.linkedBrowser.contentWindow);
-
-      is(doc.getElementById("buttonDeck").selectedPanel, doc.getElementById("restartPanel"),
-         "Should be showing the right buttons");
-
-      ok(!aAddon.userDisabled, "Add-on should now have been enabled");
-
-      ok(!aAddon.isActive, "Add-on should not be running");
-
-      ok(doc.getElementById("allow").disabled, "Should have disabled checkbox");
-
-      EventUtils.synthesizeMouseAtCenter(doc.getElementById("cancel-button"),
-                                         {}, aTab.linkedBrowser.contentWindow);
-
-      is(doc.getElementById("buttonDeck").selectedPanel, doc.getElementById("continuePanel"),
-         "Should be showing the right buttons");
-
-      ok(!doc.getElementById("allow").disabled, "Should have enabled checkbox");
-
-      ok(aAddon.userDisabled, "Add-on should not have been enabled");
-
-      ok(!aAddon.isActive, "Add-on should not be running");
-
-      EventUtils.synthesizeMouseAtCenter(doc.getElementById("allow"),
-                                         {}, aTab.linkedBrowser.contentWindow);
-
-      EventUtils.synthesizeMouseAtCenter(doc.getElementById("continue-button"),
-                                         {}, aTab.linkedBrowser.contentWindow);
-
-      ok(aAddon.userDisabled, "Add-on should not have been enabled");
-
-      ok(!aAddon.isActive, "Add-on should not be running");
-
-      is(gBrowser.tabs.length, 1, "Page should have been closed");
-
-      aAddon.seen = false;
-      run_next_test();
-    });
-  });
-});
-
-// Tests that opening the page in the background doesn't mark as seen
-add_test(function() {
-  loadPage("about:newaddon?id=addon1@tests.mozilla.org", function(aTab) {
-    var doc = aTab.linkedBrowser.contentDocument;
-    is(doc.getElementById("name").value, "Test 1 5.3", "Should say the right name");
-
-    is_element_hidden(doc.getElementById("author"), "Should be no author displayed");
-    is_element_hidden(doc.getElementById("location"), "Should be no location displayed");
-
-    is(doc.getElementById("buttonDeck").selectedPanel, doc.getElementById("continuePanel"),
-       "Should be showing the right buttons");
-
-    AddonManager.getAddonByID("addon1@tests.mozilla.org", function(aAddon) {
-      ok(!aAddon.seen, "Add-on should not have been marked as seen.");
-
-      gBrowser.selectedTab = aTab;
-
-      waitForFocus(function() {
-        ok(aAddon.seen, "Add-on should have been marked as seen after focusing the tab.");
-
-        gBrowser.removeTab(aTab);
-
-        run_next_test();
-      }, aTab.linkedBrowser.contentWindow);
-    });
-  }, true);
-});
deleted file mode 100644
--- a/toolkit/themes/linux/mozapps/extensions/newaddon.css
+++ /dev/null
@@ -1,5 +0,0 @@
-/* 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/. */
-
-%include ../../../shared/extensions/newaddon.inc.css
--- a/toolkit/themes/linux/mozapps/jar.mn
+++ b/toolkit/themes/linux/mozapps/jar.mn
@@ -1,16 +1,15 @@
 # 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/.
 
 toolkit.jar:
 #include ../../shared/mozapps.inc.mn
 * skin/classic/mozapps/extensions/extensions.css           (extensions/extensions.css)
-* skin/classic/mozapps/extensions/newaddon.css             (extensions/newaddon.css)
   skin/classic/mozapps/extensions/heart.png                (extensions/heart.png)
   skin/classic/mozapps/profile/profileicon.png             (profile/profileicon.png)
   skin/classic/mozapps/update/updates.css                  (update/updates.css)
 
 #if MOZ_BUILD_APP == browser
 [browser/extensions/{972ce4c6-7e08-4474-a285-3208198ce6fd}] chrome.jar:
 #elif MOZ_SEPARATE_MANIFEST_FOR_THEME_OVERRIDES
 [extensions/{972ce4c6-7e08-4474-a285-3208198ce6fd}] chrome.jar:
deleted file mode 100644
--- a/toolkit/themes/osx/mozapps/extensions/newaddon.css
+++ /dev/null
@@ -1,5 +0,0 @@
-/* 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/. */
-
-%include ../../../shared/extensions/newaddon.inc.css
--- a/toolkit/themes/osx/mozapps/jar.mn
+++ b/toolkit/themes/osx/mozapps/jar.mn
@@ -10,17 +10,16 @@ toolkit.jar:
   skin/classic/mozapps/extensions/rating-won.png                  (extensions/rating-won.png)
   skin/classic/mozapps/extensions/rating-not-won.png              (extensions/rating-not-won.png)
   skin/classic/mozapps/extensions/cancel.png                      (extensions/cancel.png)
   skin/classic/mozapps/extensions/toolbarbutton-dropmarker.png    (extensions/toolbarbutton-dropmarker.png)
   skin/classic/mozapps/extensions/heart.png                       (extensions/heart.png)
 * skin/classic/mozapps/extensions/extensions.css                  (extensions/extensions.css)
   skin/classic/mozapps/extensions/eula.css                        (extensions/eula.css)
   skin/classic/mozapps/extensions/blocklist.css                   (extensions/blocklist.css)
-* skin/classic/mozapps/extensions/newaddon.css                    (extensions/newaddon.css)
   skin/classic/mozapps/plugins/pluginHelp-16.png                  (plugins/pluginHelp-16.png)
   skin/classic/mozapps/profile/profileicon.png                    (profile/profileicon.png)
   skin/classic/mozapps/profile/profileSelection.css               (profile/profileSelection.css)
   skin/classic/mozapps/profile/profileicon-selected.png           (profile/profileicon-selected.png)
   skin/classic/mozapps/update/buttons.png                         (update/buttons.png)
 * skin/classic/mozapps/update/updates.css                         (update/updates.css)
   skin/classic/mozapps/xpinstall/xpinstallConfirm.css             (extensions/xpinstallConfirm.css)
   skin/classic/mozapps/handling/handling.css                      (handling/handling.css)
deleted file mode 100644
--- a/toolkit/themes/shared/extensions/newaddon.inc.css
+++ /dev/null
@@ -1,114 +0,0 @@
-%if 0
-/* 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/. */
-%endif
-@import url("chrome://global/skin/in-content/common.css");
-
-#addon-page {
-  font-size: 1.1em;
-}
-
-#addon-scrollbox {
-  overflow: auto;
-  -moz-box-orient: vertical;
-  -moz-box-flex: 1;
-}
-
-#spacer-start {
-  -moz-box-flex: 1;
-}
-
-#spacer-end {
-  -moz-box-flex: 3;
-}
-
-#addon-container {
-  overflow: visible;
-  max-width: 800px;
-  margin: 20px;
-  padding: 30px 90px;
-}
-
-#addon-info {
-  -moz-box-align: start;
-  margin: 25px 10px;
-}
-
-#icon {
-  margin-top: 8px;
-  margin-inline-end: 10px;
-  max-width: 64px;
-  max-height: 64px;
-  list-style-image: url("chrome://mozapps/skin/extensions/extensionGeneric.svg");
-}
-
-.addon-info[type="theme"] #icon {
-  list-style-image: url("chrome://mozapps/skin/extensions/themeGeneric.svg");
-}
-
-.addon-info[type="locale"] #icon {
-  list-style-image: url("chrome://mozapps/skin/extensions/localeGeneric.svg");
-}
-
-.addon-info[type="plugin"] #icon {
-  list-style-image: url("chrome://mozapps/skin/plugins/pluginGeneric.svg");
-}
-
-.addon-info[type="dictionary"] #icon {
-  list-style-image: url("chrome://mozapps/skin/extensions/dictionaryGeneric.svg");
-}
-
-#name {
-  font-size: 130%;
-}
-
-#author {
-  color: GrayText;
-}
-
-#location {
-  color: GrayText;
-}
-
-#warning {
-  margin-bottom: 25px;
-  -moz-box-align: start;
-}
-
-#warning-icon {
-  list-style-image: url("chrome://mozapps/skin/extensions/alerticon-warning.svg");
-  width: 16px;
-  height: 16px;
-  margin-top: 5px;
-  margin-inline-end: 5px;
-}
-
-#allow {
-  margin-inline-start: 84px;
-  margin-bottom: 20px;
-}
-
-#buttonDeck {
-  margin-top: 25px;
-  -moz-box-align: stretch;
-}
-
-#continuePanel {
-  -moz-box-pack: end;
-  -moz-box-align: end;
-}
-
-#restartPanel {
-  -moz-box-pack: end;
-  -moz-box-align: stretch;
-}
-
-#restartPanelButtons {
-  margin-top: 25px;
-  -moz-box-pack: end;
-}
-
-#later {
-  color: GrayText;
-}
deleted file mode 100644
--- a/toolkit/themes/windows/mozapps/extensions/newaddon.css
+++ /dev/null
@@ -1,5 +0,0 @@
-/* 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/. */
-
-%include ../../../shared/extensions/newaddon.inc.css
--- a/toolkit/themes/windows/mozapps/jar.mn
+++ b/toolkit/themes/windows/mozapps/jar.mn
@@ -1,17 +1,16 @@
 # 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/.
 
 toolkit.jar:
 #include ../../shared/mozapps.inc.mn
 * skin/classic/mozapps/extensions/extensions.css             (extensions/extensions.css)
   skin/classic/mozapps/extensions/heart.png                  (extensions/heart.png)
-* skin/classic/mozapps/extensions/newaddon.css               (extensions/newaddon.css)
   skin/classic/mozapps/profile/profileicon.png               (profile/profileicon.png)
   skin/classic/mozapps/update/updates.css                    (update/updates.css)
 
 #if MOZ_BUILD_APP == browser
 [browser/extensions/{972ce4c6-7e08-4474-a285-3208198ce6fd}] chrome.jar:
 #elif MOZ_SEPARATE_MANIFEST_FOR_THEME_OVERRIDES
 [extensions/{972ce4c6-7e08-4474-a285-3208198ce6fd}] chrome.jar:
 #endif