changeset 11791:e439530c0c6d

[gaim-migrate @ 14082] I think this is a better fix? committer: Tailor Script <tailor@pidgin.im>
author Mark Doliner <mark@kingant.net>
date Mon, 24 Oct 2005 05:28:56 +0000
parents 53490cc0fccf
children c2abe1e76501
files plugins/spellchk.c
diffstat 1 files changed, 11 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/spellchk.c	Mon Oct 24 05:22:14 2005 +0000
+++ b/plugins/spellchk.c	Mon Oct 24 05:28:56 2005 +0000
@@ -1818,17 +1818,26 @@
 static void add_selected_row_to_list(GtkTreeModel *model, GtkTreePath *path,
 	GtkTreeIter *iter, gpointer data)
 {
+	GtkTreeRowReference *row_reference;
 	GSList **list = (GSList **)data;
-	*list = g_slist_prepend(*list, gtk_tree_path_copy(path));
+	row_reference = gtk_tree_row_reference_new(model, path);
+	*list = g_slist_prepend(*list, row_reference);
 }
 
 static void remove_row(void *data1, gpointer data2)
 {
-	GtkTreePath *path = (GtkTreePath*)data1;
+	GtkTreeRowReference *row_reference;
+	GtkTreePath *path;
 	GtkTreeIter iter;
+
+	row_reference = (GtkTreeRowReference *)data1;
+	path = gtk_tree_row_reference_get_path(row_reference);
+
 	if (gtk_tree_model_get_iter(GTK_TREE_MODEL(model), &iter, path))
 		gtk_list_store_remove(model, &iter);
+
 	gtk_tree_path_free(path);
+	gtk_tree_row_reference_free(row_reference);
 }
 
 static void list_delete()