summaryrefslogtreecommitdiffstats
path: root/browser/base/content/newtab/customize.js
diff options
context:
space:
mode:
Diffstat (limited to 'browser/base/content/newtab/customize.js')
-rw-r--r--browser/base/content/newtab/customize.js17
1 files changed, 4 insertions, 13 deletions
diff --git a/browser/base/content/newtab/customize.js b/browser/base/content/newtab/customize.js
index 28a52373c..39724fa91 100644
--- a/browser/base/content/newtab/customize.js
+++ b/browser/base/content/newtab/customize.js
@@ -25,7 +25,6 @@ var gCustomize = {
this._nodes.button.addEventListener("click", e => this.showPanel(e));
this._nodes.blank.addEventListener("click", this);
this._nodes.classic.addEventListener("click", this);
- this._nodes.enhanced.addEventListener("click", this);
this._nodes.learn.addEventListener("click", this);
this.updateSelected();
@@ -87,11 +86,7 @@ var gCustomize = {
sendAsyncMessage("NewTab:Customize", {enabled: false, enhanced: false});
break;
case "newtab-customize-classic":
- if (this._nodes.enhanced.getAttribute("selected")){
- sendAsyncMessage("NewTab:Customize", {enabled: true, enhanced: true});
- } else {
- sendAsyncMessage("NewTab:Customize", {enabled: true, enhanced: false});
- }
+ sendAsyncMessage("NewTab:Customize", {enabled: true, enhanced: false});
break;
case "newtab-customize-enhanced":
sendAsyncMessage("NewTab:Customize", {enabled: true, enhanced: !gAllPages.enhanced});
@@ -114,9 +109,9 @@ var gCustomize = {
},
updateSelected: function() {
- let {enabled, enhanced} = gAllPages;
- let selected = enabled ? enhanced ? "enhanced" : "classic" : "blank";
- ["enhanced", "classic", "blank"].forEach(id => {
+ let {enabled} = gAllPages;
+ let selected = enabled ? "classic" : "blank";
+ ["classic", "blank"].forEach(id => {
let node = this._nodes[id];
if (id == selected) {
node.setAttribute("selected", true);
@@ -125,9 +120,5 @@ var gCustomize = {
node.removeAttribute("selected");
}
});
- if (selected == "enhanced") {
- // If enhanced is selected, so is classic (since enhanced is a subitem of classic)
- this._nodes.classic.setAttribute("selected", true);
- }
},
};