[Gtk-sharp-list] right click mouse - question
mf74 at gmx.de
Mon May 9 04:32:05 EDT 2011
Not sure what you want to say with iter versurs "rows item".
However, there is something that I think does what you want - no reason
to get angry anyways :-)
-> This contains the selected "rows" = item(s) of the tree view
So, if you want the iter, this is one option:
// TreeView tv; -- for example
if ( tv.Selection.CountSelectedRows() > 0 ) // make sure
something is selected ... otherwise you get an exception below
tv.Model.GetIter( out iter, tv.Selection.GetSelectedRows()
); // get the iter of the first selected row - probably the ONLY
// ignore or do something to handle the case that nothing is
This works in so far, as it gives you the iter of the item that was
right-clicked if you use it in that context...
Am 09.05.2011 09:13, schrieb luca:
> i wanna just enabling right click on TreeIter, not on rows item (read only
> treeview on "right side" of tree)
> the fact that that there is no "Tree.treestore.getSelectedIter (or something
> like that, and the fact that on left click on the tree on a treeIter make
> expand the tree as standard behaviour) make me angry.
More information about the Gtk-sharp-list