Skip to content

Commit ad813d7

Browse files
committed
New r3dfox css theme and colors
1 parent 3046429 commit ad813d7

File tree

10 files changed

+414
-2
lines changed

10 files changed

+414
-2
lines changed

browser/components/BrowserGlue.sys.mjs

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -172,6 +172,22 @@ let gThisInstanceIsLaunchOnLogin = false;
172172
// a taskbar tab shortcut will contain the "taskbar-tab" flag.
173173
let gThisInstanceIsTaskbarTab = false;
174174

175+
function applyCustomCSS() {
176+
let styleSheetService = Components.classes["@mozilla.org/content/style-sheet-service;1"]
177+
.getService(Components.interfaces.nsIStyleSheetService);
178+
let ioService = Components.classes["@mozilla.org/network/io-service;1"]
179+
.getService(Components.interfaces.nsIIOService);
180+
let uri = ioService.newURI("chrome://browser/skin/r3dfox.css", null, null);
181+
182+
if (!styleSheetService.sheetRegistered(uri, styleSheetService.AGENT_SHEET)) {
183+
styleSheetService.loadAndRegisterSheet(uri, styleSheetService.AGENT_SHEET);
184+
}
185+
}
186+
187+
applyCustomCSS();
188+
189+
applyCustomCSS();
190+
175191
/**
176192
* Fission-compatible JSProcess implementations.
177193
* Each actor options object takes the form of a ProcessActorOptions dictionary.

browser/components/preferences/main.inc.xhtml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,13 @@
6565
</hbox>
6666
<description class="indent tip-caption" data-l10n-id="r3dfox-theme-desc"/>
6767

68+
<hbox align="center">
69+
<checkbox id="r3dfoxColors"
70+
data-l10n-id="r3dfox-colors"
71+
preference="r3dfox.colors.enabled"/>
72+
</hbox>
73+
<description class="indent tip-caption" data-l10n-id="r3dfox-colors-desc"/>
74+
6875
<hbox align="center">
6976
<checkbox id="r3dfoxlessfog"
7077
data-l10n-id="r3dfox-less-fog"

browser/components/preferences/main.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ Preferences.addAll([
6464
{ id: "widget.non-native-theme.enabled", type: "bool", inverted: true },
6565
{ id: "widget.ev-native-controls-patch.scrollbar-style", type: "int" },
6666
{ id: "widget.non-native-theme.scrollbar.style", type: "int" },
67+
{ id: "r3dfox.colors.enabled", type: "bool" },
6768
{ id: "r3dfox.customizations.enabled", type: "bool" },
6869
{ id: "r3dfox.less.aero.fog", type: "bool" },
6970
{ id: "r3dfox.aero.fog", type: "bool" },

browser/locales/en-US/browser/preferences/preferences.ftl

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,12 @@ r3dfox-fake-scroll-type-desc = This controls the theme of the scrollbar.
160160
r3dfox-theme =
161161
.label = Use r3dfox theme styles
162162
163-
r3dfox-theme-desc = Currently this just enables or disables the red colors in private mode.
163+
r3dfox-theme-desc = This enables or disables the r3dfox theme.
164+
165+
r3dfox-colors =
166+
.label = Use r3dfox colors
167+
168+
r3dfox-colors-desc = This enables or disables the r3dfox colors.
164169
165170
r3dfox-less-fog =
166171
.label = Less intense caption bar fog
Lines changed: 6 additions & 0 deletions
Loading
Lines changed: 6 additions & 0 deletions
Loading
Lines changed: 6 additions & 0 deletions
Loading

browser/themes/shared/jar.inc.mn

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -285,3 +285,10 @@
285285
skin/classic/browser/weather/night-partly-cloudy-with-showers.svg (../shared/weather/night-partly-cloudy-with-showers.svg)
286286
skin/classic/browser/weather/night-partly-cloudy-with-thunderstorms.svg (../shared/weather/night-partly-cloudy-with-thunderstorms.svg)
287287
skin/classic/browser/weather/night-mostly-cloudy-with-flurries.svg (../shared/weather/night-mostly-cloudy-with-flurries.svg)
288+
289+
browser.jar:
290+
% skin browser classic/1.0 %skin/classic/browser/
291+
skin/classic/browser/r3dfox.css (../shared/r3dfox.css)
292+
skin/classic/browser/r3d_center.svg (../shared/icons/r3d_center.svg)
293+
skin/classic/browser/r3d_left_corner.svg (../shared/icons/r3d_left_corner.svg)
294+
skin/classic/browser/r3d_right_corner.svg (../shared/icons/r3d_right_corner.svg)

0 commit comments

Comments
 (0)