Re: GtkTreeStore and row deletion

2009-09-02 Thread pwieser

- Kristian Rietveld k...@gtk.org a écrit :

 I don't fully get the problem you are describing.  If I understand it
 correctly, you have a tree model where each node points to a GObject.
 Isn't it the case that when a row is destroyed that contains a
 G_TYPE_OBJECT column, this will unref the value in that column?

Are you affirmative about that ?

It would be great in this case, but appears as undocumented. Or, is it ?
However, in the previous version, when I unreffed the object from my
GSList, I don't have observed that same object be (silently) unreffed
a second time when the row was deleted. I think Gtk would have warned
me in this case...

  PS: if there is no other solution, don't you think that adding a
 gtk_tree_model_row_about_to_delete() before each g_node_destroy()
  could do the trick in a future version ?
 
 That said, yes the current row-deleted signal has its issues and in a
 future version we will certainly be adding a pre-row-deleted signal
 of some sort.
 
 
 regards,
 
 -kris.

Regards
Pierre

ps: sorry for my bad english :)
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

GtkAssistant flow question

2009-07-12 Thread pwieser
Hi,

I have a simple GtkAssistant with :
- one intro page
- two content pages
- one confirm page
- one summary page.

All works fine : the confirm page has 'Cancel' and 'Apply' buttons,
and the summary page has only a 'Close' button.

Of course (or is it only obvious for me ?), I'd wish display on the
summary page the result of the work done when the user has clicked on
the Apply button.

But it appears that the next page is computed, and so the 'prepare'
message is sent, _before_ the 'apply' message is itself emitted.

So, when I handle the prepare message for the summary page, I don't
know what is the result of the operations, as they have not be done
yet.

As a work-around, I have to do the work at the very beginning of the
prepare handler.

And so handling the apply message becomes useless.

IMHO, the usual programmer does want 'apply' its operations before
'preparing' the display of the summary page.

As the GtkAssistant cannot be considered as new (appeared in 2.9 or so),
it is surely not a bug. But I don't understand the rationale behind this.
Could someone explain it to me ? Why this order has it be choosen ?
And how do we should handle the apply message ?

Thanks in advance.
Regards
Pierre
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list