diff options
author | Ryan Lortie <desrt@desrt.ca> | 2011-03-22 11:43:21 -0400 |
---|---|---|
committer | Ryan Lortie <desrt@desrt.ca> | 2011-03-22 12:01:34 -0400 |
commit | 9b0ee770b1ad9eb9bc26d9aa11e4c0366fe8703e (patch) | |
tree | 26c268c4f8b564ae80d1ac49e6ecf3c55d6fa66b | |
parent | 91f00fbe2fa0774894d403c6433b4adebab537f2 (diff) | |
download | dconf-9b0ee770b1ad9eb9bc26d9aa11e4c0366fe8703e.tar.gz |
editor: Trivial fix for 'flags'
The code will fail badly if it encounters a 'flags' key in a schema, so
add a very minimal workaround to deal with that.
-rw-r--r-- | editor/dconf-schema.vala | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/editor/dconf-schema.vala b/editor/dconf-schema.vala index b074223..2b34e28 100644 --- a/editor/dconf-schema.vala +++ b/editor/dconf-schema.vala @@ -28,6 +28,9 @@ public class SchemaKey type = "s"; enum_name = prop->children->content; } + else if (prop->name == "flags") + /* TODO: support this properly */ + type = "as"; else warning ("Unknown property on <key>, %s", prop->name); } @@ -84,7 +87,7 @@ public class SchemaKey Variant v; try { - v = new Variant(type, value); + v = new Variant.string (value); choices.append (new SchemaChoice(value, v)); } catch (VariantParseError e) @@ -130,7 +133,7 @@ public class SchemaKey Variant v; try { - v = new Variant(type, target); + v = new Variant.string (target); choices.append (new SchemaChoice(value, v)); } catch (VariantParseError e) |