diff options
author | Ted Gould <ted@gould.cx> | 2011-02-16 23:03:27 -0600 |
---|---|---|
committer | Ted Gould <ted@gould.cx> | 2011-02-16 23:03:27 -0600 |
commit | 15d2b9c0957d1ad2c45c6361866fbb5ea66ec0df (patch) | |
tree | 365d38f24cdba0854dac09f4a0ba4b0c0a4bc9b8 | |
parent | 80845fd8f04b15f2932fadcd372523ca21365f83 (diff) | |
download | libdbusmenu-15d2b9c0957d1ad2c45c6361866fbb5ea66ec0df.tar.gz libdbusmenu-15d2b9c0957d1ad2c45c6361866fbb5ea66ec0df.tar.bz2 libdbusmenu-15d2b9c0957d1ad2c45c6361866fbb5ea66ec0df.zip |
Adding a property for text direction
-rw-r--r-- | libdbusmenu-glib/server.c | 9 | ||||
-rw-r--r-- | libdbusmenu-glib/server.h | 1 |
2 files changed, 9 insertions, 1 deletions
diff --git a/libdbusmenu-glib/server.c b/libdbusmenu-glib/server.c index 777e4ef..5946db1 100644 --- a/libdbusmenu-glib/server.c +++ b/libdbusmenu-glib/server.c @@ -35,6 +35,7 @@ License version 3 and version 2.1 along with this program. If not, see #include "menuitem-private.h" #include "server.h" #include "server-marshal.h" +#include "enum-types.h" #include "dbus-menu-clean.xml.h" @@ -74,7 +75,8 @@ enum { PROP_0, PROP_DBUS_OBJECT, PROP_ROOT_NODE, - PROP_VERSION + PROP_VERSION, + PROP_TEXT_DIRECTION }; /* Errors */ @@ -285,6 +287,11 @@ dbusmenu_server_class_init (DbusmenuServerClass *class) "The version of the DBusmenu API that we're implementing.", DBUSMENU_VERSION_NUMBER, DBUSMENU_VERSION_NUMBER, DBUSMENU_VERSION_NUMBER, G_PARAM_READABLE | G_PARAM_STATIC_STRINGS)); + g_object_class_install_property (object_class, PROP_TEXT_DIRECTION, + g_param_spec_enum(DBUSMENU_SERVER_PROP_TEXT_DIRECTION, "The default direction of text", + "The object that represents this set of menus on DBus", + DBUSMENU_TYPE_TEXT_DIRECTION, DBUSMENU_TEXT_DIRECTION_NONE, + G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS)); if (dbusmenu_node_info == NULL) { GError * error = NULL; diff --git a/libdbusmenu-glib/server.h b/libdbusmenu-glib/server.h index 99216ea..d7a0281 100644 --- a/libdbusmenu-glib/server.h +++ b/libdbusmenu-glib/server.h @@ -53,6 +53,7 @@ G_BEGIN_DECLS #define DBUSMENU_SERVER_PROP_DBUS_OBJECT "dbus-object" #define DBUSMENU_SERVER_PROP_ROOT_NODE "root-node" #define DBUSMENU_SERVER_PROP_VERSION "version" +#define DBUSMENU_SERVER_PROP_TEXT_DIRECTION "text-direction" typedef struct _DbusmenuServerPrivate DbusmenuServerPrivate; |