From 6a6c9006908cb43e0cacca34cc22862582aadba6 Mon Sep 17 00:00:00 2001 From: Sjoerd Simons Date: Thu, 20 Aug 2009 17:57:17 +0100 Subject: Add a function to get the requested global presence from the account manager --- libempathy/empathy-account-manager.c | 16 ++++++++++++++++ libempathy/empathy-account-manager.h | 5 +++++ 2 files changed, 21 insertions(+) diff --git a/libempathy/empathy-account-manager.c b/libempathy/empathy-account-manager.c index 9f0c71003..7624122d8 100644 --- a/libempathy/empathy-account-manager.c +++ b/libempathy/empathy-account-manager.c @@ -865,6 +865,22 @@ empathy_account_manager_request_global_presence ( } } +TpConnectionPresenceType +empathy_account_manager_get_requested_global_presence ( + EmpathyAccountManager *manager, + gchar **status, + gchar **message) +{ + EmpathyAccountManagerPriv *priv = GET_PRIV (manager); + + if (status != NULL) + *status = g_strdup (priv->requested_status); + if (message != NULL) + *message = g_strdup (priv->requested_status_message); + + return priv->requested_presence; +} + TpConnectionPresenceType empathy_account_manager_get_global_presence ( EmpathyAccountManager *manager, diff --git a/libempathy/empathy-account-manager.h b/libempathy/empathy-account-manager.h index 1f73f635e..e0ec93761 100644 --- a/libempathy/empathy-account-manager.h +++ b/libempathy/empathy-account-manager.h @@ -86,6 +86,11 @@ void empathy_account_manager_request_global_presence ( const gchar *status, const gchar *message); +TpConnectionPresenceType empathy_account_manager_get_requested_global_presence ( + EmpathyAccountManager *manager, + gchar **status, + gchar **message); + TpConnectionPresenceType empathy_account_manager_get_global_presence ( EmpathyAccountManager *manager, gchar **status, -- cgit v1.2.3