aboutsummaryrefslogtreecommitdiffstats
path: root/libempathy/empathy-account-manager.c
diff options
context:
space:
mode:
authorCosimo Cecchi <cosimo.cecchi@collabora.co.uk>2009-08-01 16:32:39 +0800
committerCosimo Cecchi <cosimo.cecchi@collabora.co.uk>2009-08-01 16:32:39 +0800
commit3e8f25168aadd741ecc0fe8da4d1847eece5ff83 (patch)
tree69b2fc8984c98b9cad38d2ca5e8563da2b9aad8a /libempathy/empathy-account-manager.c
parent41e5b31c1918f40c3ba47bff2dc9ab682fe0391f (diff)
parent87070d25c5f2d9a0ecba73e8ce913eca7f183c79 (diff)
downloadgsoc2013-empathy-3e8f25168aadd741ecc0fe8da4d1847eece5ff83.tar
gsoc2013-empathy-3e8f25168aadd741ecc0fe8da4d1847eece5ff83.tar.gz
gsoc2013-empathy-3e8f25168aadd741ecc0fe8da4d1847eece5ff83.tar.bz2
gsoc2013-empathy-3e8f25168aadd741ecc0fe8da4d1847eece5ff83.tar.lz
gsoc2013-empathy-3e8f25168aadd741ecc0fe8da4d1847eece5ff83.tar.xz
gsoc2013-empathy-3e8f25168aadd741ecc0fe8da4d1847eece5ff83.tar.zst
gsoc2013-empathy-3e8f25168aadd741ecc0fe8da4d1847eece5ff83.zip
Merge branch 'sjoerd-mc5' into mc5
Conflicts: libempathy-gtk/empathy-account-widget.c libempathy-gtk/empathy-protocol-chooser.c
Diffstat (limited to 'libempathy/empathy-account-manager.c')
-rw-r--r--libempathy/empathy-account-manager.c29
1 files changed, 15 insertions, 14 deletions
diff --git a/libempathy/empathy-account-manager.c b/libempathy/empathy-account-manager.c
index b037f5d30..18eff355f 100644
--- a/libempathy/empathy-account-manager.c
+++ b/libempathy/empathy-account-manager.c
@@ -167,6 +167,9 @@ emp_account_manager_update_global_presence (EmpathyAccountManager *manager)
GHashTableIter iter;
gpointer value;
+ /* Make the global presence is equal to the presence of the account with the
+ * highest availability */
+
g_hash_table_iter_init (&iter, priv->accounts);
while (g_hash_table_iter_next (&iter, NULL, &value))
{
@@ -731,8 +734,9 @@ empathy_account_manager_get_count (EmpathyAccountManager *manager)
}
EmpathyAccount *
-empathy_account_manager_get_account (EmpathyAccountManager *manager,
- TpConnection *connection)
+empathy_account_manager_get_account_for_connection (
+ EmpathyAccountManager *manager,
+ TpConnection *connection)
{
EmpathyAccountManagerPriv *priv;
GHashTableIter iter;
@@ -755,18 +759,12 @@ empathy_account_manager_get_account (EmpathyAccountManager *manager,
}
EmpathyAccount *
-empathy_account_manager_lookup (EmpathyAccountManager *manager,
+empathy_account_manager_get_account (EmpathyAccountManager *manager,
const gchar *unique_name)
{
EmpathyAccountManagerPriv *priv = GET_PRIV (manager);
- EmpathyAccount *account;
-
- account = g_hash_table_lookup (priv->accounts, unique_name);
- if (account != NULL)
- g_object_ref (account);
-
- return account;
+ return g_hash_table_lookup (priv->accounts, unique_name);
}
GList *
@@ -914,10 +912,13 @@ empathy_account_manager_created_cb (TpAccountManager *proxy,
void
empathy_account_manager_create_account_async (EmpathyAccountManager *manager,
- const gchar *connection_manager,
- const gchar *protocol, const gchar *display_name,
- GHashTable *parameters, GHashTable *properties,
- GAsyncReadyCallback callback, gpointer user_data)
+ const gchar *connection_manager,
+ const gchar *protocol,
+ const gchar *display_name,
+ GHashTable *parameters,
+ GHashTable *properties,
+ GAsyncReadyCallback callback,
+ gpointer user_data)
{
EmpathyAccountManagerPriv *priv = GET_PRIV (manager);
GSimpleAsyncResult *res;