HOWTO get a ComboBox in a TableView to activate on a single click?
I have placed a ComboBox in a TableView. Currently the user needs to double click to get it into edit mode. What do I need to do get it into Edit mode with a single click?
You can try the following approach.
1. For your tableView change the editTrigger
2. Then you need to override the Flags function for your model. For eg i have :
- class MyStandardItemModel : public QStandardItemModel
and in the implementation file you can write:
This worked for me :)
Thank you! You provided me with the road map I needed to get my results. What I did differently was how I handled the flags. The key was to only enable the edit on the columns I wanted to allow editing. Works like a champ, thank you!!!