Re: Help removing GtkListStore rows

2004-05-04 Thread Jan-Marek Glogowski
> On Sun, 2004-05-02 at 05:09, Jan-Marek Glogowski wrote: > > Hi > > > > 1. You have a memory leak: The string from gtk_tree_path_to_string must be > >g_free()'d. > No, he did that with: > gtk_tree_path_free (path); >From the GTK+ docs: gchar* gtk_tree_path_to_string (GtkTreePath *path); G

Re: Help removing GtkListStore rows

2004-05-03 Thread Nils O.
On Sun, 2004-05-02 at 05:09, Jan-Marek Glogowski wrote: > Hi > > 1. You have a memory leak: The string from gtk_tree_path_to_string must be >g_free()'d. No, he did that with: gtk_tree_path_free (path); > 2. I think you can't cast a "store" ("model") into a "view", otherwise >using one s

Re: Help removing GtkListStore rows

2004-05-02 Thread LordGolem
I've modified the function, but the problem persists. I suppose the problem isn't in this function but somewhere else, even if all the other related functions work. Here is the new version of the func based on the "fixed remove function" from treestoretest.c: static void rem_item () { Files *t

Re: Help removing GtkListStore rows

2004-05-02 Thread Jan-Marek Glogowski
Ok A fixed "remove" function from the treestoretest.c example: static void iter_remove (GtkWidget *button, GtkTreeView *tree_view) { GtkTreeIter selected, selected_sort; GtkTreeModel *model; GtkTreeModelSort *model_sort; GtkTreePath *path_sort, *path; if(

Re: Help removing GtkListStore rows

2004-05-02 Thread LordGolem
Il dom, 2004-05-02 alle 05:09, Jan-Marek Glogowski ha scritto: > Hi > > 1. You have a memory leak: The string from gtk_tree_path_to_string must be >g_free()'d. The seg fault persists... > 2. I think you can't cast a "store" ("model") into a "view", otherwise >using one store for multiple

Re: Help removing GtkListStore rows

2004-05-01 Thread Jan-Marek Glogowski
Hi 1. You have a memory leak: The string from gtk_tree_path_to_string must be g_free()'d. 2. I think you can't cast a "store" ("model") into a "view", otherwise using one store for multiple views wouldn't be possible. HTH Jan-Marek ___ gtk-list

Help removing GtkListStore rows

2004-05-01 Thread LordGolem
I'm porting an app I wrote from gtk 1.2 to grk 2.2. I have to convert old GtkCList to GtkListStore. I'm in throuble removing rows from the list. In the app, when the user hits a button it removes the currently selected row. Here is the function connected to the button: static void rem_item () {

Help removing GtkListStore rows

2004-05-01 Thread LordGolem
I'm porting an app I wrote from gtk 1.2 to grk 2.2. I have to convert old GtkCList to GtkListStore. I'm in throuble removing rows from the list. In the app, when the user hits a button it removes the currently selected row. Here is the function connected to the button: static void rem_item () {