diff options
author | Thierry Vignaud <thierry.vignaud@gmail.com> | 2013-12-03 11:33:09 +0100 |
---|---|---|
committer | Thierry Vignaud <thierry.vignaud@gmail.com> | 2015-12-20 10:25:03 +0100 |
commit | 11fdd1884b3e64d941be8fc617262b33ef0855e1 (patch) | |
tree | 4b010708b5a050f1b8c98d95cb9cdaa2cc3965ba | |
parent | f5e08315f4fa329ff0ade7285045881507ed3d5c (diff) | |
download | control-center-11fdd1884b3e64d941be8fc617262b33ef0855e1.tar control-center-11fdd1884b3e64d941be8fc617262b33ef0855e1.tar.gz control-center-11fdd1884b3e64d941be8fc617262b33ef0855e1.tar.bz2 control-center-11fdd1884b3e64d941be8fc617262b33ef0855e1.tar.xz control-center-11fdd1884b3e64d941be8fc617262b33ef0855e1.zip |
switch from RC files to CSS
-rw-r--r-- | Makefile | 2 | ||||
-rwxr-xr-x | control-center | 6 | ||||
-rw-r--r-- | control-center.css (renamed from control-center.rc) | 17 |
3 files changed, 13 insertions, 12 deletions
@@ -27,7 +27,7 @@ install: all find -name '*.p[lm]' -o -name control-center -o -name drakconf | xargs perl -pi -e 's/\s*use\s+(diagnostics|vars|strict).*//g' install -d $(DESTDIR)/usr/{bin,sbin,libexec,share/icons} install -d $(mcc_dir)/themes/default/ - install -m644 control-center.rc $(mcc_dir)/themes/default/gtkrc + install -m644 control-center.css $(mcc_dir)/themes/default/mcc.css install -m755 $(NAME) $(DESTDIR)/usr/libexec/ install -m755 wrapper $(DESTDIR)/usr/bin/$(NAME) install -m755 menus_launcher.pl $(DESTDIR)/usr/sbin/ diff --git a/control-center b/control-center index 348569bd..3e349773 100755 --- a/control-center +++ b/control-center @@ -87,8 +87,10 @@ add_icon_path("$themes_dir/$theme/"); add_icon_path("$themes_dir/default") if $theme ne 'default'; # fall back if theme miss some icons mygtk3::import_style_ressources(); -my $rc = find { -r $_ } ("$themes_dir/$theme/gtkrc", if_($theme ne 'default', "$themes_dir/default/gtkrc")); -Gtk3::Rc->parse($rc) if -r $rc; +my $css = find { -r $_ } ("$themes_dir/$theme/mcc.css", if_($theme ne 'default', "$themes_dir/default/mcc.css")); +my $pl = Gtk3::CssProvider->new; +$pl->load_from_path($css); +my $cx = Gtk3::StyleContext::add_provider_for_screen(Gtk3::Gdk::Screen::get_default(), $pl, Gtk3::STYLE_PROVIDER_PRIORITY_APPLICATION); my $branding = N("Mageia"); my $product_id = common::parse_LDAP_namespace_structure(cat_('/etc/product.id')); diff --git a/control-center.rc b/control-center.css index cb875aa9..e5ddf143 100644 --- a/control-center.rc +++ b/control-center.css @@ -1,4 +1,5 @@ -# gtkrc -- gtkrc for MCC themes +/* +# CSS for MCC themes # # Copyright (C) 2000, 2001 Eazel, Inc. # @@ -19,17 +20,15 @@ # $Id: control-center.rc 246590 2008-09-24 23:53:24Z tv $ # # Authors: Thierry Vignaud <tvignaud@mandrakesoft.com> +*/ - +/* # Default style for mcc specific widgets (mainly main_window and # scrolled windows per mcc category +*/ -style "focus" -{ - GtkWidget::interior_focus=0 - GtkWidget::focus-line-width=0 +GtkTextView, focus * { + -GtkTreeView-interior-focus: 0; + -GtkTreeView-focus-line-width: 0; } -class "GtkTextView" style "focus" -widget "*focus*" style "focus" - |