aboutsummaryrefslogtreecommitdiff
path: root/src/title-widget.c
diff options
context:
space:
mode:
authorConor Curran <conor.curran@canonical.com>2011-01-11 12:12:30 -0600
committerConor Curran <conor.curran@canonical.com>2011-01-11 12:12:30 -0600
commitd8da7cdced255ac430caa78b9e6d24d9476e76d8 (patch)
tree376066b4c491b77c72f3073918eec7cca8be8e65 /src/title-widget.c
parent714c7c49776e8a341254a3e4297b465d181206cd (diff)
parent259057b02fe5c6b777a438331defa2dda628dfd2 (diff)
downloadayatana-indicator-sound-d8da7cdced255ac430caa78b9e6d24d9476e76d8.tar.gz
ayatana-indicator-sound-d8da7cdced255ac430caa78b9e6d24d9476e76d8.tar.bz2
ayatana-indicator-sound-d8da7cdced255ac430caa78b9e6d24d9476e76d8.zip
merged the dreaded gdbus port
Diffstat (limited to 'src/title-widget.c')
-rw-r--r--src/title-widget.c17
1 files changed, 8 insertions, 9 deletions
diff --git a/src/title-widget.c b/src/title-widget.c
index 08b4b81..675c59f 100644
--- a/src/title-widget.c
+++ b/src/title-widget.c
@@ -49,7 +49,7 @@ static gboolean title_widget_button_press_event (GtkWidget *menuitem,
// Dbusmenuitem properties update callback
static void title_widget_property_update(DbusmenuMenuitem* item, gchar* property,
- GValue* value, gpointer userdata);
+ GVariant* value, gpointer userdata);
static void title_widget_set_twin_item( TitleWidget* self,
DbusmenuMenuitem* twin_item);
static gboolean title_widget_triangle_draw_cb (GtkWidget *widget,
@@ -138,24 +138,23 @@ title_widget_button_press_event (GtkWidget *menuitem,
//g_debug("TitleWidget::menu_press_event");
TitleWidgetPrivate * priv = TITLE_WIDGET_GET_PRIVATE(menuitem);
- GValue value = {0};
- g_value_init(&value, G_TYPE_BOOLEAN);
-
- g_value_set_boolean(&value, TRUE);
- dbusmenu_menuitem_handle_event (priv->twin_item, "Title menu event", &value, 0);
-
+ GVariant* new_title_event = g_variant_new_boolean(TRUE);
+ dbusmenu_menuitem_handle_event (priv->twin_item,
+ "Title menu event",
+ new_title_event,
+ 0);
return FALSE;
}
static void
title_widget_property_update(DbusmenuMenuitem* item, gchar* property,
- GValue* value, gpointer userdata)
+ GVariant* value, gpointer userdata)
{
g_return_if_fail (IS_TITLE_WIDGET (userdata));
TitleWidget* mitem = TITLE_WIDGET(userdata);
if(g_ascii_strcasecmp(DBUSMENU_TITLE_MENUITEM_NAME, property) == 0){
gtk_menu_item_set_label (GTK_MENU_ITEM(mitem),
- g_value_get_string(value));
+ g_variant_get_string(value, NULL));
}
else if(g_ascii_strcasecmp(DBUSMENU_TITLE_MENUITEM_ICON, property) == 0){
title_widget_set_icon (mitem);