How to do item in QListView selected as I would click on him? Way I tried to do this I have selection but like not-active one. Without Blue highlight only grey one.
To be mroe detailed:
- Make QListView
- AddSomeItems
- Run app
- Move mouse to any item
- Select it
- Now its, selected and ALSO blue. This is what I want to do with item before I run application. If it is possible of course. (selectable + hover + focus?)
I want to have it without clicking
I tried many ways:
view->clicked(selectedIndex);
view->selectionModel()->select( selectedIndex, QItemSelectionModel::Select )
view->setCurrentIndex(selectedIndex);
view->clicked(selectedIndex);
and others, any help needed