aboutsummaryrefslogtreecommitdiff
path: root/libdbusmenu-gtk
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2010-12-02 13:52:54 -0600
committerTed Gould <ted@gould.cx>2010-12-02 13:52:54 -0600
commit9dba82584abf181777b7bed4cca8202cf6652ff6 (patch)
tree434ece9468bbe30cfad8e4612b09f6009c11f392 /libdbusmenu-gtk
parent4bf64d184cb6eb7ac89d91705e947aedd2aa981a (diff)
downloadlibdbusmenu-9dba82584abf181777b7bed4cca8202cf6652ff6.tar.gz
libdbusmenu-9dba82584abf181777b7bed4cca8202cf6652ff6.tar.bz2
libdbusmenu-9dba82584abf181777b7bed4cca8202cf6652ff6.zip
Removing a GValue to use the direct functions
Diffstat (limited to 'libdbusmenu-gtk')
-rw-r--r--libdbusmenu-gtk/genericmenuitem.c11
1 files changed, 2 insertions, 9 deletions
diff --git a/libdbusmenu-gtk/genericmenuitem.c b/libdbusmenu-gtk/genericmenuitem.c
index 990ca82..61881ef 100644
--- a/libdbusmenu-gtk/genericmenuitem.c
+++ b/libdbusmenu-gtk/genericmenuitem.c
@@ -291,7 +291,6 @@ genericmenuitem_set_check_type (Genericmenuitem * item, GenericmenuitemCheckType
}
item->priv->check_type = check_type;
- GValue value = {0};
switch (item->priv->check_type) {
case GENERICMENUITEM_CHECK_TYPE_NONE:
@@ -300,22 +299,16 @@ genericmenuitem_set_check_type (Genericmenuitem * item, GenericmenuitemCheckType
check on the item. */
break;
case GENERICMENUITEM_CHECK_TYPE_CHECKBOX:
- g_value_init(&value, G_TYPE_BOOLEAN);
- g_value_set_boolean(&value, FALSE);
- g_object_set_property(G_OBJECT(item), "draw-as-radio", &value);
+ gtk_check_menu_item_set_draw_as_radio(GTK_CHECK_MENU_ITEM(item), FALSE);
break;
case GENERICMENUITEM_CHECK_TYPE_RADIO:
- g_value_init(&value, G_TYPE_BOOLEAN);
- g_value_set_boolean(&value, TRUE);
- g_object_set_property(G_OBJECT(item), "draw-as-radio", &value);
+ gtk_check_menu_item_set_draw_as_radio(GTK_CHECK_MENU_ITEM(item), TRUE);
break;
default:
g_warning("Generic Menuitem invalid check type: %d", check_type);
return;
}
- g_value_unset(&value);
-
gtk_widget_queue_draw(GTK_WIDGET(item));
return;