Commit 0a0a1a20 authored by Carlos Garnacho's avatar Carlos Garnacho
Browse files

GtkCssProvider: Make it able to parse enums.

parent d03caa46
......@@ -2314,6 +2314,17 @@ css_provider_parse_value (GtkCssProvider *css_provider,
else
parsed = FALSE;
}
else if (G_TYPE_IS_ENUM (type))
{
GEnumClass *class;
GEnumValue *enum_value;
class = g_type_class_ref (type);
enum_value = g_enum_get_value_by_nick (class, value_str);
g_value_set_enum (value, enum_value->value);
g_type_class_unref (class);
}
else if (type == GTK_TYPE_9SLICE)
{
Gtk9Slice *slice;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment