diff options
author | Matthias Clasen <mclasen@redhat.com> | 2016-01-13 16:17:44 -0500 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2016-01-13 16:17:44 -0500 |
commit | 1009c88186c9473aed3ff4dbbb6f851254b5bf74 (patch) | |
tree | 2a3b79afc76062ed96e9b313a8d0f94169b504db /gtk/gtkcssimageicontheme.c | |
parent | 34c263683c1d6cb1d08f2fc9b7d3c66839c7b7db (diff) | |
download | gtk+-1009c88186c9473aed3ff4dbbb6f851254b5bf74.tar.gz |
Make -gtk-icontheme() use -gtk-icon-palette
This makes it possible to recolor themed icons with -gtk-icon-palette,
regardless whether they are loaded by the theme or the application.
Diffstat (limited to 'gtk/gtkcssimageicontheme.c')
-rw-r--r-- | gtk/gtkcssimageicontheme.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/gtk/gtkcssimageicontheme.c b/gtk/gtkcssimageicontheme.c index 73c8a628a1..4451e1904a 100644 --- a/gtk/gtkcssimageicontheme.c +++ b/gtk/gtkcssimageicontheme.c @@ -27,6 +27,7 @@ #include "gtkcssrgbavalueprivate.h" #include "gtksettingsprivate.h" #include "gtkstyleproviderprivate.h" +#include "gtkiconthemeprivate.h" G_DEFINE_TYPE (GtkCssImageIconTheme, _gtk_css_image_icon_theme, GTK_TYPE_CSS_IMAGE) @@ -66,7 +67,9 @@ gtk_css_image_icon_theme_draw (GtkCssImage *image, pixbuf = gtk_icon_info_load_symbolic (icon_info, &icon_theme->color, - NULL, NULL, NULL, + &icon_theme->success, + &icon_theme->warning, + &icon_theme->error, NULL, &error); if (pixbuf == NULL) @@ -139,7 +142,7 @@ gtk_css_image_icon_theme_compute (GtkCssImage *image, copy->name = g_strdup (icon_theme->name); copy->icon_theme = gtk_css_icon_theme_value_get_icon_theme (gtk_css_style_get_value (style, GTK_CSS_PROPERTY_ICON_THEME)); copy->scale = _gtk_style_provider_private_get_scale (provider); - copy->color = *_gtk_css_rgba_value_get_rgba (gtk_css_style_get_value (style, GTK_CSS_PROPERTY_COLOR)); + gtk_icon_theme_lookup_symbolic_colors (style, ©->color, ©->success, ©->warning, ©->error); return GTK_CSS_IMAGE (copy); } |