diff options
author | Benjamin Otte <otte@redhat.com> | 2012-04-09 03:05:12 +0200 |
---|---|---|
committer | Benjamin Otte <otte@redhat.com> | 2012-04-09 03:09:44 +0200 |
commit | 43c56d70ea247b3317c386e22407ad20769d2762 (patch) | |
tree | 33e6055ac8c630e02c8af0b69c3f5b6da388f3f7 /gtk/gtkcssstyleproperty.c | |
parent | 122cde95284f94afc39fa934c4e145a03105fda8 (diff) | |
download | gtk+-43c56d70ea247b3317c386e22407ad20769d2762.tar.gz |
csscustomproperty: Redo RGBA/Color parsing
This fixes custom parse functions returning RGBA values where we
expected symbolic colors.
Diffstat (limited to 'gtk/gtkcssstyleproperty.c')
-rw-r--r-- | gtk/gtkcssstyleproperty.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gtk/gtkcssstyleproperty.c b/gtk/gtkcssstyleproperty.c index cbbe606af9..c9d4e56450 100644 --- a/gtk/gtkcssstyleproperty.c +++ b/gtk/gtkcssstyleproperty.c @@ -464,6 +464,10 @@ _gtk_css_style_property_is_specified_type (GtkCssStyleProperty *property, return TRUE; /* XXX: Someone needs to fix that legacy */ + if ((_gtk_css_value_holds (property->initial_value, GDK_TYPE_RGBA) || + _gtk_css_value_holds (property->initial_value, GDK_TYPE_COLOR)) && + type == GTK_TYPE_GRADIENT) + return TRUE; if (_gtk_css_value_holds (property->initial_value, CAIRO_GOBJECT_TYPE_PATTERN) && type == GTK_TYPE_GRADIENT) return TRUE; |