[Qt-interest] How to get index of a QListView when no selection

Aaron Lewis the.warl0ck.1989 at gmail.com
Sun May 22 07:33:53 CEST 2011


Hi,
	How can i get the index of arbitrary entry in a QListView ?

	When there's no selection , currentIndex().row() always returns -1.

	I need to retrieve the contents of the first entry in a QListView , 
	basically i retrieve it withe a custom index , but in this case ,
	how can i find a valid index ?

	Many thanks

-- 
Best Regards,
Aaron Lewis - PGP: 0xDFE6C29E ( http://http://pgp.mit.edu/ )
Finger Print: 9482 448F C7C3 896C 1DFE 7DD3 2492 A7D0 DFE6 C29E



More information about the Qt-interest-old mailing list