Bug 591853 - Optimize chrome layer size with lightweight themes with transparent or no footer images. r=enn
--- a/browser/themes/gnomestripe/browser/browser.css
+++ b/browser/themes/gnomestripe/browser/browser.css
@@ -63,17 +63,17 @@
}
#navigator-toolbox[inFullscreen="true"],
#navigator-toolbox[inFullscreen="true"] > #nav-bar {
border-top: none;
padding-top: 0;
}
-#browser-bottombox:not([lwthemefooter="true"]) {
+#browser-bottombox {
/* opaque for layers optimization */
background-color: -moz-Dialog;
}
#urlbar:-moz-lwtheme:not([focused="true"]),
.searchbar-textbox:-moz-lwtheme:not([focused="true"]),
.tabbrowser-tab:-moz-lwtheme:not([selected="true"]) {
opacity: .85;
--- a/toolkit/content/LightweightThemeConsumer.jsm
+++ b/toolkit/content/LightweightThemeConsumer.jsm
@@ -84,16 +84,17 @@ LightweightThemeConsumer.prototype = {
root.style.backgroundColor = "";
root.removeAttribute("lwthemetextcolor");
root.removeAttribute("lwtheme");
}
_setImage(root, active, aData.headerURL);
if (this._footerId) {
let footer = this._doc.getElementById(this._footerId);
+ footer.style.backgroundColor = active ? aData.accentcolor || "white" : "";
_setImage(footer, active, aData.footerURL);
if (active && aData.footerURL)
footer.setAttribute("lwthemefooter", "true");
else
footer.removeAttribute("lwthemefooter");
}
#ifdef XP_MACOSX