From 9477255847d3cc4dacd3c654684cea4327d1c756 Mon Sep 17 00:00:00 2001 From: "shaver%mozilla.org" Date: Sat, 9 Apr 2005 23:39:13 +0000 Subject: [PATCH] Infrastructure for skins for both chrome://calendar/ (shared) and chrome://lightning/ (specialized). Currently makes a lightning-afflicted Thunderbird pretty unhappy, because calendar.css overrides a lot of Tbird UI CSS rules, but Pav's all over that. r=vlad, NPTOB. --- calendar/lightning/Makefile.in | 12 ++++++++++++ calendar/lightning/chrome.manifest | 8 ++++++-- calendar/lightning/content/lightning-widgets.css | 1 + .../lightning/content/messenger-overlay-sidebar.xul | 1 + calendar/lightning/jar.mn | 5 +++++ calendar/lightning/themes/pinstripe/lightning.css | 2 ++ calendar/lightning/themes/winstripe/lightning.css | 2 ++ 7 files changed, 29 insertions(+), 2 deletions(-) create mode 100644 calendar/lightning/content/lightning-widgets.css create mode 100644 calendar/lightning/themes/pinstripe/lightning.css create mode 100644 calendar/lightning/themes/winstripe/lightning.css diff --git a/calendar/lightning/Makefile.in b/calendar/lightning/Makefile.in index 4fa312a6d8b..7abf9cca43f 100644 --- a/calendar/lightning/Makefile.in +++ b/calendar/lightning/Makefile.in @@ -49,4 +49,16 @@ XPI_INSTALL_EXTRAS = $(srcdir)/chrome.manifest XPI_PKGNAME = lightning DIRS = ../../db/sqlite3/src ../../storage ../libical ../base ../providers +# Select a theme from which to pull our skin goodness +# OS X: pinstripe +# Others: winstripe + +ifneq (,$(filter mac cocoa,$(MOZ_WIDGET_TOOLKIT))) +THEME=pinstripe +else +THEME=winstripe +endif + +DEFINES += -DTHEME=$(THEME) + include $(topsrcdir)/config/rules.mk diff --git a/calendar/lightning/chrome.manifest b/calendar/lightning/chrome.manifest index 8642b23f776..2cfc2442fac 100644 --- a/calendar/lightning/chrome.manifest +++ b/calendar/lightning/chrome.manifest @@ -1,5 +1,9 @@ content lightning jar:chrome/lightning.jar!/content/lightning/ -content calendar jar:chrome/calendar.jar!/content/calendar/ locale lightning en-US jar:chrome/en-US.jar!/locale/en-US/lightning/ -locale calendar en-US jar:chrome/calendar-en-US.jar!/locale/en-US/calendar/ overlay chrome://messenger/content/messenger.xul chrome://lightning/content/messenger-overlay-sidebar.xul +skin lightning classic/1.0 jar:chrome/classic.jar!/skin/classic/lightning/ + +# shared pieces for chrome://calendar/ +content calendar jar:chrome/calendar.jar!/content/calendar/ +locale calendar en-US jar:chrome/calendar-en-US.jar!/locale/en-US/calendar/ +skin calendar classic/1.0 jar:chrome/classic.jar!/skin/classic/calendar/ diff --git a/calendar/lightning/content/lightning-widgets.css b/calendar/lightning/content/lightning-widgets.css new file mode 100644 index 00000000000..d0b5bae3f1b --- /dev/null +++ b/calendar/lightning/content/lightning-widgets.css @@ -0,0 +1 @@ +// XBL and other rules required for use of Lightning widgets go here. diff --git a/calendar/lightning/content/messenger-overlay-sidebar.xul b/calendar/lightning/content/messenger-overlay-sidebar.xul index 49b71c1504a..7f6bd7ac13d 100644 --- a/calendar/lightning/content/messenger-overlay-sidebar.xul +++ b/calendar/lightning/content/messenger-overlay-sidebar.xul @@ -3,6 +3,7 @@ + diff --git a/calendar/lightning/jar.mn b/calendar/lightning/jar.mn index 35edc744025..02db25cabe5 100644 --- a/calendar/lightning/jar.mn +++ b/calendar/lightning/jar.mn @@ -6,6 +6,7 @@ lightning.jar: content/lightning/weekView.xul (content/weekView.xul) content/lightning/weekView.js (content/weekView.js) content/lightning/calendarView.js (content/calendarView.js) + content/lightning/lightning-widgets.css (content/lightning-widgets.css) en-US.jar: locale/en-US/lightning/lightning.dtd (locale/lightning.dtd) @@ -18,3 +19,7 @@ calendar.jar: calendar-en-US.jar: locale/en-US/calendar/global.dtd (/calendar/resources/locale/en-US/global.dtd) locale/en-US/calendar/calendar.dtd (/calendar/resources/locale/en-US/calendar.dtd) + +classic.jar: +#expand skin/classic/calendar/calendar.css (/calendar/sunbird/themes/__THEME__/sunbird/calendar.css) +#expand skin/classic/lightning/lightning.css (themes/__THEME__/lightning.css) diff --git a/calendar/lightning/themes/pinstripe/lightning.css b/calendar/lightning/themes/pinstripe/lightning.css new file mode 100644 index 00000000000..b642ebb38c2 --- /dev/null +++ b/calendar/lightning/themes/pinstripe/lightning.css @@ -0,0 +1,2 @@ +// Skin-domain style rules for lightning UI (pinstripe version) + diff --git a/calendar/lightning/themes/winstripe/lightning.css b/calendar/lightning/themes/winstripe/lightning.css new file mode 100644 index 00000000000..b1f13ad8549 --- /dev/null +++ b/calendar/lightning/themes/winstripe/lightning.css @@ -0,0 +1,2 @@ +// Skin-domain style rules for lightning UI (winstripe version) +