diff options
| author | Ted Gould <ted@gould.cx> | 2010-11-17 20:12:53 -0600 |
|---|---|---|
| committer | Ted Gould <ted@gould.cx> | 2010-11-17 20:12:53 -0600 |
| commit | 17af43e09f01979a4ab660bbd2a60d9212a8ef13 (patch) | |
| tree | 853f797cb3b1b2ac8876e9cfb0bc3a99eb6b983e /libdbusmenu-glib/server.c | |
| parent | 353802f51c23447bcc905767014dcc37b5b76e20 (diff) | |
| download | libdbusmenu-17af43e09f01979a4ab660bbd2a60d9212a8ef13.tar.gz libdbusmenu-17af43e09f01979a4ab660bbd2a60d9212a8ef13.tar.bz2 libdbusmenu-17af43e09f01979a4ab660bbd2a60d9212a8ef13.zip | |
Removing the set_value and get_value functions from being used elsewhere in -glib
Diffstat (limited to 'libdbusmenu-glib/server.c')
| -rw-r--r-- | libdbusmenu-glib/server.c | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/libdbusmenu-glib/server.c b/libdbusmenu-glib/server.c index 63d237f..4fdd6f8 100644 --- a/libdbusmenu-glib/server.c +++ b/libdbusmenu-glib/server.c @@ -815,8 +815,8 @@ bus_get_property (DbusmenuServer * server, GVariant * params, GDBusMethodInvocat return; } - const GValue * prop = dbusmenu_menuitem_property_get_value(mi, property); - if (prop == NULL) { + GVariant * variant = dbusmenu_menuitem_property_get_variant(mi, property); + if (variant == NULL) { g_dbus_method_invocation_return_error(invocation, error_quark(), INVALID_PROPERTY_NAME, @@ -826,16 +826,7 @@ bus_get_property (DbusmenuServer * server, GVariant * params, GDBusMethodInvocat return; } - GValue vval = {0}; - g_value_init(&vval, G_TYPE_VARIANT); - - if (!g_value_transform(prop, &vval)) { - g_warning("Unable to convert property '%s' value from type '%s' to variant", property, G_VALUE_TYPE_NAME(prop)); - } - - g_dbus_method_invocation_return_value(invocation, g_value_get_variant(&vval)); - g_value_unset(&vval); - + g_dbus_method_invocation_return_value(invocation, variant); return; } |
