I thought it was abovious too.Obviously, I need to test whether the mouse is over the menu or not, like in the comments.
You didn't expect us to deliver you every little detail did you?
If I understand correctly, you want to have the menu stay visible as long as your cursor is above it, even if you made your selection - is that correct?
So testing to see if the mouse button is clicked wont bring much.
But you could try the following:
Qt Code:
void Window::menuSL() { if(myMenu->isUnderMouse()) myMenu->show(); }To copy to clipboard, switch view to plain text mode
and in your event filter, look for QEvent::Leave to hide the menu once the mouse has left it.
Bookmarks