Bug 1311541 - use resource:// urls for devtools css in addon-sdk;r=jryans draft
authorJulian Descottes <jdescottes@mozilla.com>
Wed, 07 Dec 2016 18:20:46 +0100
changeset 451508 94aa503fb94ee56f876307e322d18ceeffdda0e5
parent 451507 640d431de76d5227db133fafb6dbf7545ec93dfe
child 540053 7def80862ecad5a779e52f2cabe91be180d39495
push id39208
push userjdescottes@mozilla.com
push dateTue, 20 Dec 2016 14:43:39 +0000
reviewersjryans
bugs1311541
milestone53.0a1
Bug 1311541 - use resource:// urls for devtools css in addon-sdk;r=jryans MozReview-Commit-ID: K9YR4gnbBWW
addon-sdk/source/lib/dev/theme.js
devtools/client/framework/options-panel.css
devtools/client/themes/common.css
--- a/addon-sdk/source/lib/dev/theme.js
+++ b/addon-sdk/source/lib/dev/theme.js
@@ -118,18 +118,18 @@ onDisable.define(Theme, (theme, {window,
     theme.onDisable(window, newTheme);
   }
 });
 
 // Support for built-in themes
 
 const LightTheme = Theme({
   name: "theme-light",
-  styles: "chrome://devtools/skin/light-theme.css",
+  styles: "resource://devtools/client/themes/light-theme.css",
 });
 
 const DarkTheme = Theme({
   name: "theme-dark",
-  styles: "chrome://devtools/skin/dark-theme.css",
+  styles: "resource://devtools/client/themes/dark-theme.css",
 });
 
 exports.LightTheme = LightTheme;
 exports.DarkTheme = DarkTheme;
--- a/devtools/client/framework/options-panel.css
+++ b/devtools/client/framework/options-panel.css
@@ -102,11 +102,11 @@
   min-width: 130px;
 }
 
 #devtools-sourceeditor-tabsize-select {
   min-width: 80px;
 }
 
 #screenshot-icon::before {
-  background-image: url(chrome://devtools/skin/images/command-screenshot.svg);
+  background-image: url(../themes/images/command-screenshot.svg);
   margin-inline-start: 5px;
 }
--- a/devtools/client/themes/common.css
+++ b/devtools/client/themes/common.css
@@ -1,25 +1,25 @@
 /* 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/. */
 
-@namespace html url("http://www.w3.org/1999/xhtml");
-
 /**
  * Note: common.css imports stylesheets containing variables shared by other devtools
  * stylesheets. All devtools documents should load common.css before loading any other
  * stylesheet to avoid early warnings about undefined variables.
  */
 
 @import url(variables.css);
 @import url(splitters.css);
 @import url(toolbars.css);
 @import url(tooltips.css);
 
+@namespace html url("http://www.w3.org/1999/xhtml");
+
 :root {
   font: message-box;
 }
 
 :root,
 :root[platform="win"] {
   --monospace-font-family: Consolas, monospace;
 }