2 Attachment(s)
I want to edit listview's item using contextmenu. How to?
I can edit listview's item when I doubleclicked item.
I using code
AND I want to editing item by contextmenu.
I want to :
when I select rename action,
item's state change editable, like this:
Attachment 8090 -> Attachment 8089
How to I want DO? :confused:
It's so hard...
PLEASE HELP ME!
Re: I want to edit listview's item using contextmenu. How to?
You will have to create an editor that can do it for you and you have to make a deligate
Then you have to attach deligate to the view by calling setItemDelegate(your deligate here);
here you can find some more information here http://www.qtrac.eu/aqpbook.html
download the source from here http://www.qtrac.eu/aqpbook.zip (this is the source used in the book) and take a look at the Zipcodes1 example
Re: I want to edit listview's item using contextmenu. How to?
Then after that
use
Renames the file currently specified by fileName() to newName. Returns true if successful; otherwise returns false.
If a file with the name newName already exists, rename() returns false (i.e., QFile will not overwrite it).
The file is closed before it is renamed.