From 90cbc15aa0ddb2a37a812c0ac182143a26acdb1c Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Tue, 22 Feb 2011 09:13:22 -0600 Subject: Changing signature to make more sense, comments by agateau --- libdbusmenu-glib/dbus-menu.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'libdbusmenu-glib/dbus-menu.xml') diff --git a/libdbusmenu-glib/dbus-menu.xml b/libdbusmenu-glib/dbus-menu.xml index da14c63..3856219 100644 --- a/libdbusmenu-glib/dbus-menu.xml +++ b/libdbusmenu-glib/dbus-menu.xml @@ -308,8 +308,8 @@ License version 3 and version 2.1 along with this program. If not, see the ID of the item with a hashtable of names and values for those properties. - - + + -- cgit v1.2.3 From 1f87678080488a467b04164a6a701ed4abcf92ae Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Tue, 22 Feb 2011 09:31:14 -0600 Subject: Changing parameter names to be more descriptive --- libdbusmenu-glib/dbus-menu.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'libdbusmenu-glib/dbus-menu.xml') diff --git a/libdbusmenu-glib/dbus-menu.xml b/libdbusmenu-glib/dbus-menu.xml index 3856219..c0831e5 100644 --- a/libdbusmenu-glib/dbus-menu.xml +++ b/libdbusmenu-glib/dbus-menu.xml @@ -308,8 +308,8 @@ License version 3 and version 2.1 along with this program. If not, see the ID of the item with a hashtable of names and values for those properties. - - + + -- cgit v1.2.3 From 3566852c8b4330cff84f4a7c6bcf18601264f747 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Thu, 24 Feb 2011 13:52:01 -0600 Subject: Set property to status and return it --- libdbusmenu-glib/dbus-menu.xml | 2 +- libdbusmenu-glib/server.c | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) (limited to 'libdbusmenu-glib/dbus-menu.xml') diff --git a/libdbusmenu-glib/dbus-menu.xml b/libdbusmenu-glib/dbus-menu.xml index 829c16e..0d2a2d6 100644 --- a/libdbusmenu-glib/dbus-menu.xml +++ b/libdbusmenu-glib/dbus-menu.xml @@ -179,7 +179,7 @@ License version 3 and version 2.1 along with this program. If not, see - + Tells if the menus are in a normal state or they believe that they could use some attention. Cases for showing them would be if help diff --git a/libdbusmenu-glib/server.c b/libdbusmenu-glib/server.c index e3fd2cd..056d6cb 100644 --- a/libdbusmenu-glib/server.c +++ b/libdbusmenu-glib/server.c @@ -744,6 +744,8 @@ bus_get_prop (GDBusConnection * connection, const gchar * sender, const gchar * return g_variant_new_uint32(DBUSMENU_VERSION_NUMBER); } else if (g_strcmp0(property, "text-direction") == 0) { return g_variant_new_string(dbusmenu_text_direction_get_nick(priv->text_direction)); + } else if (g_strcmp0(property, "status") == 0) { + return g_variant_new_string(dbusmenu_status_get_nick(priv->status)); } else { g_warning("Unknown property '%s'", property); } -- cgit v1.2.3 From 356ee2d0385f8fd22ec60d84620c0eb2df018384 Mon Sep 17 00:00:00 2001 From: Aurelien Gateau Date: Mon, 28 Feb 2011 10:57:36 +0100 Subject: Doc fixes: - Use "@a foo" for arguments, not "@foo" - Rename "recurse" (which sounds boolean) to "recursionDepth" - Removed dbusmenu-qt specific annotations --- libdbusmenu-glib/dbus-menu.xml | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) (limited to 'libdbusmenu-glib/dbus-menu.xml') diff --git a/libdbusmenu-glib/dbus-menu.xml b/libdbusmenu-glib/dbus-menu.xml index c0831e5..ffeca1e 100644 --- a/libdbusmenu-glib/dbus-menu.xml +++ b/libdbusmenu-glib/dbus-menu.xml @@ -177,21 +177,24 @@ License version 3 and version 2.1 along with this program. If not, see Provides the layout and propertiers that are attached to the entries that are in the layout. It only gives the items that are children - of the item that is specified in @parentId. It will return all of the - properties or specific ones depending of the value in @propertyNames. + of the item that is specified in @a parentId. It will return all of the + properties or specific ones depending of the value in @a propertyNames. The format is recursive, where the second 'v' is in the same format - as the original 'a(ia(sv)a(v))'. If the @recursive flag is set to - less than one then the second array will have zero entries. + as the original 'a(ia{sv}av)'. Its content depends on the value + of @a recursionDepth. The ID of the parent node for the layout. For grabbing the layout from the root node use zero. - + - The amount of levels of recursion to use. -1, as value would - deliver all the items under the @parentId. + The amount of levels of recursion to use. This affects the + content of the second variant array. + - -1: deliver all the items under the @a parentId. + - 0: no recursion, the array will be empty. + - n: array will contains items up to 'n' level depth. @@ -206,13 +209,11 @@ License version 3 and version 2.1 along with this program. If not, see with layoutUpdated signals. - The layout as an XML string of IDs. + The layout, as a recursive structure. - - Returns the list of items which are children of @a parentId. @@ -309,7 +310,7 @@ License version 3 and version 2.1 along with this program. If not, see properties. - + -- cgit v1.2.3 From 33b4e34124c38f8159ea4af25f2b3622b3cc392e Mon Sep 17 00:00:00 2001 From: Aurelien Gateau Date: Wed, 2 Mar 2011 12:07:07 +0100 Subject: Rename dbus properties to follow dbus naming conventions - version => Version - text-direction => TextDirection - status => Status --- libdbusmenu-glib/client.c | 10 +++++----- libdbusmenu-glib/dbus-menu.xml | 6 +++--- libdbusmenu-glib/server.c | 10 +++++----- 3 files changed, 13 insertions(+), 13 deletions(-) (limited to 'libdbusmenu-glib/dbus-menu.xml') diff --git a/libdbusmenu-glib/client.c b/libdbusmenu-glib/client.c index d368a0e..8424d6f 100644 --- a/libdbusmenu-glib/client.c +++ b/libdbusmenu-glib/client.c @@ -1026,7 +1026,7 @@ menuproxy_build_cb (GObject * object, GAsyncResult * res, gpointer user_data) } /* Check the text direction if available */ - GVariant * textdir = g_dbus_proxy_get_cached_property(priv->menuproxy, "text-direction"); + GVariant * textdir = g_dbus_proxy_get_cached_property(priv->menuproxy, "TextDirection"); if (textdir != NULL) { GVariant * str = textdir; if (g_variant_is_of_type(str, G_VARIANT_TYPE_VARIANT)) { @@ -1069,10 +1069,10 @@ menuproxy_prop_changed_cb (GDBusProxy * proxy, GVariant * properties, GStrv inva gchar * invalid; gint i = 0; for (invalid = invalidated[i]; invalid != NULL; invalid = invalidated[++i]) { - if (g_strcmp0(invalid, "text-direction") == 0) { + if (g_strcmp0(invalid, "TextDirection") == 0) { priv->text_direction = DBUSMENU_TEXT_DIRECTION_NONE; } - if (g_strcmp0(invalid, "status") == 0) { + if (g_strcmp0(invalid, "Status") == 0) { priv->status = DBUSMENU_STATUS_NORMAL; } } @@ -1082,7 +1082,7 @@ menuproxy_prop_changed_cb (GDBusProxy * proxy, GVariant * properties, GStrv inva gchar * key; GVariant * value; g_variant_iter_init(&iters, properties); while (g_variant_iter_next(&iters, "{sv}", &key, &value)) { - if (g_strcmp0(key, "text-direction") == 0) { + if (g_strcmp0(key, "TextDirection") == 0) { GVariant * str = value; if (g_variant_is_of_type(str, G_VARIANT_TYPE_VARIANT)) { str = g_variant_get_variant(str); @@ -1090,7 +1090,7 @@ menuproxy_prop_changed_cb (GDBusProxy * proxy, GVariant * properties, GStrv inva priv->text_direction = dbusmenu_text_direction_get_value_from_nick(g_variant_get_string(str, NULL)); } - if (g_strcmp0(key, "status") == 0) { + if (g_strcmp0(key, "Status") == 0) { GVariant * str = value; if (g_variant_is_of_type(str, G_VARIANT_TYPE_VARIANT)) { str = g_variant_get_variant(str); diff --git a/libdbusmenu-glib/dbus-menu.xml b/libdbusmenu-glib/dbus-menu.xml index 2352712..b61b5ec 100644 --- a/libdbusmenu-glib/dbus-menu.xml +++ b/libdbusmenu-glib/dbus-menu.xml @@ -164,14 +164,14 @@ License version 3 and version 2.1 along with this program. If not, see ]]> - + Provides the version of the DBusmenu API that this API is implementing. - + Represents the way the text direction of the application. This allows the server to handle mismatches intelligently. For left- @@ -179,7 +179,7 @@ License version 3 and version 2.1 along with this program. If not, see - + Tells if the menus are in a normal state or they believe that they could use some attention. Cases for showing them would be if help diff --git a/libdbusmenu-glib/server.c b/libdbusmenu-glib/server.c index 7c943b2..ebd9193 100644 --- a/libdbusmenu-glib/server.c +++ b/libdbusmenu-glib/server.c @@ -501,7 +501,7 @@ set_property (GObject * obj, guint id, const GValue * value, GParamSpec * pspec) GVariantBuilder params; g_variant_builder_init(¶ms, G_VARIANT_TYPE_ARRAY); g_variant_builder_add_value(¶ms, g_variant_new_string(DBUSMENU_INTERFACE)); - GVariant * dict = g_variant_new_dict_entry(g_variant_new_string("text-direction"), g_variant_new_string(dbusmenu_text_direction_get_nick(priv->text_direction))); + GVariant * dict = g_variant_new_dict_entry(g_variant_new_string("TextDirection"), g_variant_new_string(dbusmenu_text_direction_get_nick(priv->text_direction))); g_variant_builder_add_value(¶ms, g_variant_new_array(NULL, &dict, 1)); g_variant_builder_add_value(¶ms, g_variant_new_array(G_VARIANT_TYPE_STRING, NULL, 0)); GVariant * vparams = g_variant_builder_end(¶ms); @@ -525,7 +525,7 @@ set_property (GObject * obj, guint id, const GValue * value, GParamSpec * pspec) GVariantBuilder params; g_variant_builder_init(¶ms, G_VARIANT_TYPE_ARRAY); g_variant_builder_add_value(¶ms, g_variant_new_string(DBUSMENU_INTERFACE)); - GVariant * dict = g_variant_new_dict_entry(g_variant_new_string("status"), g_variant_new_string(dbusmenu_status_get_nick(instatus))); + GVariant * dict = g_variant_new_dict_entry(g_variant_new_string("Status"), g_variant_new_string(dbusmenu_status_get_nick(instatus))); g_variant_builder_add_value(¶ms, g_variant_new_array(NULL, &dict, 1)); g_variant_builder_add_value(¶ms, g_variant_new_array(G_VARIANT_TYPE_STRING, NULL, 0)); GVariant * vparams = g_variant_builder_end(¶ms); @@ -740,11 +740,11 @@ bus_get_prop (GDBusConnection * connection, const gchar * sender, const gchar * g_return_val_if_fail(g_strcmp0(interface, DBUSMENU_INTERFACE) == 0, NULL); g_return_val_if_fail(g_strcmp0(path, priv->dbusobject) == 0, NULL); - if (g_strcmp0(property, "version") == 0) { + if (g_strcmp0(property, "Version") == 0) { return g_variant_new_uint32(DBUSMENU_VERSION_NUMBER); - } else if (g_strcmp0(property, "text-direction") == 0) { + } else if (g_strcmp0(property, "TextDirection") == 0) { return g_variant_new_string(dbusmenu_text_direction_get_nick(priv->text_direction)); - } else if (g_strcmp0(property, "status") == 0) { + } else if (g_strcmp0(property, "Status") == 0) { return g_variant_new_string(dbusmenu_status_get_nick(priv->status)); } else { g_warning("Unknown property '%s'", property); -- cgit v1.2.3