I'm not sure the flags param works? Last I tried to use it, it always returned 0.
The event I'd connect to is wxEVT_RIGHT_DOWN. HitTest() will return the item (as in list row) under mouse of the gadget you received the event from. But I'm not sure it is necessary?
Just connect up the right click mouse event to every gadget you want to check. If you don't want the gadget itself to respond to the event then remove event.Skip()
[edited to correct an error re HitTest()]
The event I'd connect to is wxEVT_RIGHT_DOWN. HitTest() will return the item (as in list row) under mouse of the gadget you received the event from. But I'm not sure it is necessary?
Just connect up the right click mouse event to every gadget you want to check. If you don't want the gadget itself to respond to the event then remove event.Skip()
[edited to correct an error re HitTest()]