Reorderable treeview and rows-reordered signal

Hi.

I use a reorderable Gtk::TreeView. I want to call a method when the list
is reordered. I connect the rows-reordered signal of the model (a
Gtk::ListStore).
I can reoder the list but it seems that the rows-reordered is not send.
I post an example (see attachment).

How can I call a method when the list is reordered?

Hi,

In [email protected]
“[ruby-gnome2-devel-en] reorderable treeview and rows-reordered
signal” on Mon, 19 Jan 2009 19:29:42 +0100,
Vincent C. [email protected] wrote:

I use a reorderable Gtk::TreeView. I want to call a method when the list
is reordered. I connect the rows-reordered signal of the model (a
Gtk::ListStore).
I can reoder the list but it seems that the rows-reordered is not send.
I post an example (see attachment).

How can I call a method when the list is reordered?

Attachments:
http://www.ruby-forum.com/attachment/3177/es.rb

Use ‘row-inserted’ and ‘row-deleted’ instead.

http://library.gnome.org/devel/gtk/stable/GtkTreeModel.html#GtkTreeModel-rows-reordered

Note that this signal is not emitted when rows are
reordered by DND, since this is implemented by removing
and then reinserting the row.

Thanks,

kou

Thank you very much. I will use these two signals.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs