mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2025-01-14 06:10:21 +00:00
GtkCssProvider: Handle the "none" keyword to unset properties.
This commit is contained in:
parent
c57fdf4c75
commit
65abcb722e
@ -2644,7 +2644,12 @@ parse_rule (GtkCssProvider *css_provider,
|
||||
val = g_slice_new0 (GValue);
|
||||
g_value_init (val, prop_type);
|
||||
|
||||
if (prop_type == G_TYPE_STRING)
|
||||
if (strcmp (value_str, "none") == 0)
|
||||
{
|
||||
/* Remove/unset the current value */
|
||||
g_hash_table_remove (priv->cur_properties, prop);
|
||||
}
|
||||
else if (prop_type == G_TYPE_STRING)
|
||||
{
|
||||
g_value_set_string (val, value_str);
|
||||
g_hash_table_insert (priv->cur_properties, prop, val);
|
||||
|
Loading…
Reference in New Issue
Block a user