Backed out changeset 78f117b43e0a (bug 1464785) for devtools failures on browser_parsable_css.js. CLOSED TREE

This commit is contained in:
Brindusan Cristian 2018-06-26 15:17:52 +03:00
Родитель 19dbb3ce5e
Коммит 6060756652
3 изменённых файлов: 18 добавлений и 23 удалений

Просмотреть файл

@ -89,24 +89,22 @@
loadEvents.push(loadPromise);
}
if (os !== "win") {
// Windows always uses native scrollbars, other platforms might use custom floating
// scrollbar implementation.
try {
const StylesheetUtils = require("devtools/shared/layout/utils");
const SCROLLBARS_URL = "chrome://devtools/skin/floating-scrollbars-dark-theme.css";
if (!Services.appShell.hiddenDOMWindow
.matchMedia("(-moz-overlay-scrollbars)").matches) {
if (newTheme == "dark") {
StylesheetUtils.loadSheet(window, SCROLLBARS_URL, "agent");
} else if (oldTheme == "dark") {
StylesheetUtils.removeSheet(window, SCROLLBARS_URL, "agent");
}
forceStyle();
try {
const StylesheetUtils = require("devtools/shared/layout/utils");
const SCROLLBARS_URL = "chrome://devtools/skin/floating-scrollbars-dark-theme.css";
// TODO: extensions might want to customize scrollbar styles too.
if (!Services.appShell.hiddenDOMWindow
.matchMedia("(-moz-overlay-scrollbars)").matches) {
if (newTheme == "dark") {
StylesheetUtils.loadSheet(window, SCROLLBARS_URL, "agent");
} else if (oldTheme == "dark") {
StylesheetUtils.removeSheet(window, SCROLLBARS_URL, "agent");
}
} catch (e) {
console.warn("customize scrollbar styles is only supported in firefox");
forceStyle();
}
} catch (e) {
console.warn("customize scrollbar styles is only supported in firefox");
}
Promise.all(loadEvents).then(() => {

Просмотреть файл

@ -31,13 +31,6 @@
--monospace-font-family: monospace;
}
:root.theme-dark[platform="win"] {
/* Set colors for native scrollbars on Windows dark theme */
/* Other platforms support for scrollbar theming is Bug 1460109 */
scrollbar-face-color: var(--theme-body-color-inactive);
scrollbar-track-color: var(--theme-splitter-color);
}
.devtools-monospace {
font-family: var(--monospace-font-family);
}

Просмотреть файл

@ -47,9 +47,13 @@
-moz-appearance: none !important;
}
*|*:root[platform="win"] > scrollbar scrollbarbutton,
*|*:root[platform="linux"] > scrollbar scrollbarbutton,
*|*:root[platform="win"] > scrollbar gripper,
*|*:root[platform="linux"] > scrollbar gripper,
*|*:root[platform="win"] *|*:not(html|select) > scrollbar scrollbarbutton,
*|*:root[platform="linux"] *|*:not(html|select) > scrollbar scrollbarbutton,
*|*:root[platform="win"] *|*:not(html|select) > scrollbar gripper,
*|*:root[platform="linux"] *|*:not(html|select) > scrollbar gripper {
display: none;
}