QListView and selecting item on click event
I have custom QListView with items. In each item I insert custom widget. The issue is that I can't select an item on click. Its working when I press it and drag it a bit (like few pixels on the screen), then the item is selected.
If I remove widget from the items its working just fine.
I have tried re implement this http://doc.trolltech.com/4.6/qobject...allEventFilter
same issue, no click signal is emited !?!?!?!
I was experimenting with all options focusing, selection on both QList and QWidgets.
Had someone this issue before.
Re: QListView and selecting item on click event
to select an item, you need to click on the item area which in not occupied by the widget.
If your custom widget occupies the complete item area, then you cannot select the item, you need to capture the mouse click event and pass it on to the item.
Re: QListView and selecting item on click event
How to get to the item from the widget perspective, widget has not idea where it lives
Re: QListView and selecting item on click event
in your custom widget you need ignore the mouse click so that it is forwaded to the cusom widget's parent