aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2012-02-16 19:14:16 +0800
committerGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2012-02-17 00:43:30 +0800
commitfe9e5a3cac6397054f984a10916378792ce583ca (patch)
tree3d5903415441159be1c0b75d72bc2446e19a2fc7 /src
parentfea6df61fd35261aeebe2a94128d472e284a7280 (diff)
downloadgsoc2013-empathy-fe9e5a3cac6397054f984a10916378792ce583ca.tar
gsoc2013-empathy-fe9e5a3cac6397054f984a10916378792ce583ca.tar.gz
gsoc2013-empathy-fe9e5a3cac6397054f984a10916378792ce583ca.tar.bz2
gsoc2013-empathy-fe9e5a3cac6397054f984a10916378792ce583ca.tar.lz
gsoc2013-empathy-fe9e5a3cac6397054f984a10916378792ce583ca.tar.xz
gsoc2013-empathy-fe9e5a3cac6397054f984a10916378792ce583ca.tar.zst
gsoc2013-empathy-fe9e5a3cac6397054f984a10916378792ce583ca.zip
Move should_create_salut_account to local-xmpp-assistant-widget
https://bugzilla.gnome.org/show_bug.cgi?id=652669
Diffstat (limited to 'src')
-rw-r--r--src/empathy-account-assistant.c3
-rw-r--r--src/empathy-auto-salut-account-helper.c26
-rw-r--r--src/empathy-auto-salut-account-helper.h2
3 files changed, 2 insertions, 29 deletions
diff --git a/src/empathy-account-assistant.c b/src/empathy-account-assistant.c
index e4ee048b5..00add5ed1 100644
--- a/src/empathy-account-assistant.c
+++ b/src/empathy-account-assistant.c
@@ -35,6 +35,7 @@
#include <libempathy-gtk/empathy-account-widget.h>
#include <libempathy-gtk/empathy-protocol-chooser.h>
+#include <libempathy-gtk/empathy-local-xmpp-assistant-widget.h>
#include <libempathy-gtk/empathy-ui-utils.h>
#define DEBUG_FLAG EMPATHY_DEBUG_ACCOUNT
@@ -1174,7 +1175,7 @@ account_mgr_prepare_cb (GObject *source_object,
return;
}
- if (!should_create_salut_account (manager))
+ if (!empathy_local_xmpp_assistant_widget_should_create_account (manager))
{
DEBUG ("No need to create a Salut account");
priv->display_salut_page = FALSE;
diff --git a/src/empathy-auto-salut-account-helper.c b/src/empathy-auto-salut-account-helper.c
index 409b6936c..d22fe51d4 100644
--- a/src/empathy-auto-salut-account-helper.c
+++ b/src/empathy-auto-salut-account-helper.c
@@ -38,32 +38,6 @@
#include "empathy-auto-salut-account-helper.h"
-/* Salut account creation. The TpAccountManager first argument
- * must already be prepared when calling this function. */
-gboolean
-should_create_salut_account (TpAccountManager *manager)
-{
- gboolean salut_created = FALSE;
- GList *accounts, *l;
-
- accounts = tp_account_manager_get_valid_accounts (manager);
-
- for (l = accounts; l != NULL; l = g_list_next (l))
- {
- TpAccount *account = TP_ACCOUNT (l->data);
-
- if (!tp_strdiff (tp_account_get_protocol (account), "local-xmpp"))
- {
- salut_created = TRUE;
- break;
- }
- }
-
- g_list_free (accounts);
-
- return !salut_created;
-}
-
EmpathyAccountSettings *
create_salut_account_settings (void)
{
diff --git a/src/empathy-auto-salut-account-helper.h b/src/empathy-auto-salut-account-helper.h
index f0409d01d..ad186c840 100644
--- a/src/empathy-auto-salut-account-helper.h
+++ b/src/empathy-auto-salut-account-helper.h
@@ -29,8 +29,6 @@
#include <libempathy/empathy-connection-managers.h>
#include <libempathy/empathy-account-settings.h>
-gboolean should_create_salut_account (TpAccountManager *manager);
-
EmpathyAccountSettings * create_salut_account_settings (void);
#endif