[Qt-interest] How to get selected listitemindex in Qt

Ramesh ramesh.bs at robosoftin.com
Fri Apr 16 11:38:12 CEST 2010


Oh,,
Got it.. but for my case, only one item can be selected at a time..
Multiple selection is not there.. so I can use currentitem() then..

Thank you 
-R

-----Original Message-----
From: qt-interest-bounces at trolltech.com
[mailto:qt-interest-bounces at trolltech.com] On Behalf Of Rainer Wiesenfarth
Sent: Friday, April 16, 2010 3:05 PM
To: qt-interest at trolltech.com
Subject: Re: [Qt-interest] How to get selected listitemindex in Qt


From: Ramesh
> View->currentIndex()  that will give you the current index in
> your selection.
> 
> Is there any disadvantages by doing like this?

Yes! "current" and "selected" are different states, they have nothing in
common.

The current item is the one that was picked (I avoid the term selected here)
and gets the user input. In contrast, an arbitrary number of items can be
selected.

Best Regards / Mit freundlichen Grüßen
Rainer Wiesenfarth

--
INPHO GmbH * Smaragdweg 1 * 70174 Stuttgart * Germany
phone: +49 711 2288 10 * fax: +49 711 2288 111 * web: www.inpho.de place of
business: Stuttgart * managing director: Johannes Saile commercial register:
Stuttgart, HRB 9586 Leader in Photogrammetry and Digital Surface Modelling

-----------------------------------------------
Robosoft Technologies - Come home to Technology

Disclaimer: This email may contain confidential material. If you were not an intended recipient, please notify the sender and delete all copies. Emails to and from our network may be logged and monitored. This email and its attachments are scanned for virus by our scanners and are believed to be safe. However, no warranty is given that this email is free of malicious content or virus.




More information about the Qt-interest-old mailing list