diff options
author | Sjoerd Simons <sjoerd.simons@collabora.co.uk> | 2009-06-26 21:43:26 +0800 |
---|---|---|
committer | Sjoerd Simons <sjoerd.simons@collabora.co.uk> | 2009-07-01 21:19:40 +0800 |
commit | f3d6fcb79762ff484c8b7221cec1079b0dad7fb7 (patch) | |
tree | bdbd6a83e5f4a97b239e1aaca86bf152c079b1bf /libempathy-gtk/empathy-contact-list-view.c | |
parent | 370bb92f2ce8ccd70bd694a6ab4ba78abeb448f9 (diff) | |
download | gsoc2013-empathy-f3d6fcb79762ff484c8b7221cec1079b0dad7fb7.tar gsoc2013-empathy-f3d6fcb79762ff484c8b7221cec1079b0dad7fb7.tar.gz gsoc2013-empathy-f3d6fcb79762ff484c8b7221cec1079b0dad7fb7.tar.bz2 gsoc2013-empathy-f3d6fcb79762ff484c8b7221cec1079b0dad7fb7.tar.lz gsoc2013-empathy-f3d6fcb79762ff484c8b7221cec1079b0dad7fb7.tar.xz gsoc2013-empathy-f3d6fcb79762ff484c8b7221cec1079b0dad7fb7.tar.zst gsoc2013-empathy-f3d6fcb79762ff484c8b7221cec1079b0dad7fb7.zip |
Port libempathy-gtk to EmpathyAccount
Diffstat (limited to 'libempathy-gtk/empathy-contact-list-view.c')
-rw-r--r-- | libempathy-gtk/empathy-contact-list-view.c | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/libempathy-gtk/empathy-contact-list-view.c b/libempathy-gtk/empathy-contact-list-view.c index 61db60cdf..f7b506e7c 100644 --- a/libempathy-gtk/empathy-contact-list-view.c +++ b/libempathy-gtk/empathy-contact-list-view.c @@ -32,7 +32,6 @@ #include <gtk/gtk.h> #include <telepathy-glib/util.h> -#include <libmissioncontrol/mc-account.h> #include <libempathy/empathy-account-manager.h> #include <libempathy/empathy-call-factory.h> @@ -247,7 +246,7 @@ contact_list_view_drag_data_received (GtkWidget *view, EmpathyContactListViewPriv *priv; EmpathyAccountManager *account_manager; EmpathyTpContactFactory *factory = NULL; - McAccount *account; + EmpathyAccount *account; GtkTreeModel *model; GtkTreeViewDropPosition position; GtkTreePath *path; @@ -302,19 +301,17 @@ contact_list_view_drag_data_received (GtkWidget *view, strv = g_strsplit (id, "/", 2); account_id = strv[0]; contact_id = strv[1]; - account = mc_account_lookup (account_id); + account_manager = empathy_account_manager_dup_singleton (); + account = empathy_account_manager_lookup (account_manager, account_id); if (account) { TpConnection *connection; - /* FIXME: We assume we have already an account manager */ - account_manager = empathy_account_manager_dup_singleton (); - connection = empathy_account_manager_get_connection (account_manager, - account); + connection = empathy_account_get_connection (account); if (connection) { factory = empathy_tp_contact_factory_dup_singleton (connection); } - g_object_unref (account_manager); } + g_object_unref (account_manager); if (!factory) { DEBUG ("Failed to get factory for account '%s'", account_id); @@ -451,7 +448,7 @@ contact_list_view_drag_data_get (GtkWidget *widget, GtkTreeIter iter; GtkTreeModel *model; EmpathyContact *contact; - McAccount *account; + EmpathyAccount *account; const gchar *contact_id; const gchar *account_id; gchar *str; @@ -481,7 +478,7 @@ contact_list_view_drag_data_get (GtkWidget *widget, } account = empathy_contact_get_account (contact); - account_id = mc_account_get_unique_name (account); + account_id = empathy_account_get_unique_name (account); contact_id = empathy_contact_get_id (contact); g_object_unref (contact); str = g_strconcat (account_id, "/", contact_id, NULL); |