Right-click tree view -> get new selected row, not previous
| From: | Christian Weiske | Date: | Wed, 19 Apr 2006 17:31:27 +0000 |
| Subject: | Right-click tree view -> get new selected row, not previous | ||
| Groups: | php.gtk.general | ||
| Request: | Send a blank email to php-gtk-general+get-6884@lists.php.net to get a copy of this message | ||
Hello all,
I have a GtkTreeView and connect "button-press-event" to show a context
menu for the currently selected row.
The popup works, but I get the previously selected row only - not the
one that is (newly) selected when I right-click the list.
An example code is here:
http://xml.cweiske.de/rightclicktree.phps
Just run it and right-click a not selected item; the popup will show the
value of the selection - which is always the old one, not the new selection.
Does anyone know how to get the new selection data?
connect_after doesn't work here.
---------
While writing this mail the idea to use "button-release-event" crossed
my mind and it works. Thanks for reading :)
--
Regards/MfG,
Christian Weiske
Attachment: [application/pgp-signature] OpenPGP digital signature signature.asc
Attachment: [application/pgp-signature] OpenPGP digital signature signature.asc