diff options
author | Ted Gould <ted@gould.cx> | 2010-03-12 14:26:46 -0600 |
---|---|---|
committer | Ted Gould <ted@gould.cx> | 2010-03-12 14:26:46 -0600 |
commit | a92cec4aa9f3b7a014f9ed0e3dc3b2617e4114be (patch) | |
tree | d2b2f0fb4614c9d4afcb2e3188d22405eaeae72f | |
parent | d9427c6a4ecc0a50cac8a674c465631c59ff59f2 (diff) | |
download | ayatana-indicator-session-a92cec4aa9f3b7a014f9ed0e3dc3b2617e4114be.tar.gz ayatana-indicator-session-a92cec4aa9f3b7a014f9ed0e3dc3b2617e4114be.tar.bz2 ayatana-indicator-session-a92cec4aa9f3b7a014f9ed0e3dc3b2617e4114be.zip |
providing a set_name function
-rw-r--r-- | src/session-dbus.c | 12 | ||||
-rw-r--r-- | src/session-dbus.h | 1 |
2 files changed, 13 insertions, 0 deletions
diff --git a/src/session-dbus.c b/src/session-dbus.c index 96b4500..cc12311 100644 --- a/src/session-dbus.c +++ b/src/session-dbus.c @@ -80,3 +80,15 @@ _session_dbus_server_get_icon (SessionDbus * service, gchar ** icon, GError ** e *icon = g_strdup(priv->name); return TRUE; } + +void +session_dbus_set_name (SessionDbus * session, const gchar * name) +{ + SessionDbusPrivate * priv = SESSION_DBUS_GET_PRIVATE(session); + if (priv->name != NULL) { + g_free(priv->name); + priv->name = NULL; + } + priv->name = g_strdup(name); + return; +} diff --git a/src/session-dbus.h b/src/session-dbus.h index be57df7..d606378 100644 --- a/src/session-dbus.h +++ b/src/session-dbus.h @@ -25,6 +25,7 @@ struct _SessionDbus { }; GType session_dbus_get_type (void); +void session_dbus_set_name (SessionDbus * session, const gchar * name); G_END_DECLS |