/* empathy-import-widget.c */
-#include <config.h>
+#include "config.h"
#include "empathy-import-dialog.h"
#include "empathy-import-widget.h"
-#include "empathy-import-pidgin.h"
#define DEBUG_FLAG EMPATHY_DEBUG_OTHER
-#include <libempathy/empathy-debug.h>
-#include <libempathy/empathy-connection-managers.h>
-#include <libempathy/empathy-utils.h>
+#include "empathy-debug.h"
+#include "empathy-utils.h"
-#include <libempathy-gtk/empathy-ui-utils.h>
-
-#include <telepathy-glib/account-manager.h>
-#include <telepathy-glib/util.h>
+#include "empathy-ui-utils.h"
#include <glib/gi18n-lib.h>
{
TpAccountManager *manager;
GtkTreeModel *model;
- GtkTreeIter iter;
GList *l;
EmpathyImportWidgetPriv *priv = GET_PRIV (self);
gint min, natural;
value = g_hash_table_lookup (data->settings, "account");
- accounts = tp_account_manager_get_valid_accounts (manager);
+ accounts = tp_account_manager_dup_valid_accounts (manager);
/* Only set the "Import" cell to be active if there isn't already an
* account set up with the same account id. */
import = !import_widget_account_id_in_list (accounts,
g_value_get_string (value));
- g_list_free (accounts);
-
- gtk_list_store_append (GTK_LIST_STORE (model), &iter);
+ g_list_free_full (accounts, g_object_unref);
- gtk_list_store_set (GTK_LIST_STORE (model), &iter,
+ gtk_list_store_insert_with_values (GTK_LIST_STORE (model), NULL, -1,
COL_IMPORT, import,
COL_PROTOCOL, data->protocol,
COL_NAME, g_value_get_string (value),