From 73de90274bf4959b60daeb1035c9576d49b20eb1 Mon Sep 17 00:00:00 2001 From: Alexandre Poirot Date: Fri, 8 Jan 2016 06:59:34 -0800 Subject: [PATCH] Bug 1235781 - Remove preprocessing from common.css. r=bgrins --- browser/base/content/browser.xul | 2 +- devtools/client/jar.mn | 4 +- devtools/client/themes/common.css | 69 ++++++--------------- devtools/client/themes/devtools-browser.css | 15 +++++ devtools/client/themes/splitters.css | 34 ++++++++++ 5 files changed, 71 insertions(+), 53 deletions(-) create mode 100644 devtools/client/themes/devtools-browser.css create mode 100644 devtools/client/themes/splitters.css diff --git a/browser/base/content/browser.xul b/browser/base/content/browser.xul index 428a9777495a..177eddf056e3 100644 --- a/browser/base/content/browser.xul +++ b/browser/base/content/browser.xul @@ -8,7 +8,7 @@ - + diff --git a/devtools/client/jar.mn b/devtools/client/jar.mn index 231383484bc9..eab431f09db4 100644 --- a/devtools/client/jar.mn +++ b/devtools/client/jar.mn @@ -148,7 +148,9 @@ devtools.jar: content/aboutdebugging/aboutdebugging.css (aboutdebugging/aboutdebugging.css) content/aboutdebugging/aboutdebugging.js (aboutdebugging/aboutdebugging.js) % skin devtools classic/1.0 %skin/ -* skin/common.css (themes/common.css) + skin/devtools-browser.css (themes/devtools-browser.css) + skin/common.css (themes/common.css) + skin/splitters.css (themes/splitters.css) skin/dark-theme.css (themes/dark-theme.css) skin/light-theme.css (themes/light-theme.css) skin/toolbars.css (themes/toolbars.css) diff --git a/devtools/client/themes/common.css b/devtools/client/themes/common.css index b298d47858c6..9759c4908fa2 100644 --- a/devtools/client/themes/common.css +++ b/devtools/client/themes/common.css @@ -1,66 +1,33 @@ -%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("splitters.css"); :root { font: message-box; -%ifdef XP_MACOSX +} + +:root[platform="mac"] { --monospace-font-family: Menlo, monospace; -%elifdef XP_WIN +} + +:root[platform="win"] { --monospace-font-family: Consolas, monospace; -%else +} + +:root[platform="linux"] { --monospace-font-family: monospace; -%endif } .devtools-monospace { font-family: var(--monospace-font-family); -%if defined(MOZ_WIDGET_GTK) || defined(MOZ_WIDGET_QT) +} + +:root[platform="linux"] .devtools-monospace { font-size: 80%; -%endif } -/* Bottom-docked toolbox minimize transition */ -.devtools-toolbox-bottom-iframe { - transition: margin-bottom .1s; -} - -/* Splitters */ -.devtools-horizontal-splitter { - -moz-appearance: none; - background-image: none; - background-color: transparent; - border: 0; - border-bottom: 1px solid rgba(118, 121, 125, .5); - min-height: 3px; - height: 3px; - margin-top: -3px; - position: relative; -} - -.devtools-side-splitter { - -moz-appearance: none; - background-image: none; - background-color: transparent; - border: 0; - -moz-border-end: 1px solid rgba(118, 121, 125, .5); - min-width: 3px; - width: 3px; - -moz-margin-start: -3px; - position: relative; - cursor: e-resize; -} - -.devtools-horizontal-splitter.disabled, -.devtools-side-splitter.disabled { - pointer-events: none; -} - -.devtools-toolbox-side-iframe { - min-width: 465px; -} /* Autocomplete Popup */ /* Dark and light theme */ @@ -71,11 +38,11 @@ background-color: transparent; border-radius: 3px; overflow-x: hidden; -%if defined(MOZ_WIDGET_GTK) || defined(MOZ_WIDGET_QT) - max-height: 32rem; -%else max-height: 40rem; -%endif +} + +:root[platform="linux"] .devtools-autocomplete-popup { + max-height: 32rem; } .devtools-autocomplete-listbox { diff --git a/devtools/client/themes/devtools-browser.css b/devtools/client/themes/devtools-browser.css new file mode 100644 index 000000000000..b6f2f0499382 --- /dev/null +++ b/devtools/client/themes/devtools-browser.css @@ -0,0 +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/. */ + +@import url("splitters.css"); + +/* Bottom-docked toolbox minimize transition */ +.devtools-toolbox-bottom-iframe { + transition: margin-bottom .1s; +} + +.devtools-toolbox-side-iframe { + min-width: 465px; +} + diff --git a/devtools/client/themes/splitters.css b/devtools/client/themes/splitters.css new file mode 100644 index 000000000000..c71218625d5d --- /dev/null +++ b/devtools/client/themes/splitters.css @@ -0,0 +1,34 @@ +/* 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/. */ + +/* Splitters */ +.devtools-horizontal-splitter { + -moz-appearance: none; + background-image: none; + background-color: transparent; + border: 0; + border-bottom: 1px solid rgba(118, 121, 125, .5); + min-height: 3px; + height: 3px; + margin-top: -3px; + position: relative; +} + +.devtools-side-splitter { + -moz-appearance: none; + background-image: none; + background-color: transparent; + border: 0; + -moz-border-end: 1px solid rgba(118, 121, 125, .5); + min-width: 3px; + width: 3px; + -moz-margin-start: -3px; + position: relative; + cursor: e-resize; +} + +.devtools-horizontal-splitter.disabled, +.devtools-side-splitter.disabled { + pointer-events: none; +}