[Qt-interest] QDockwidget popup menu unexpected show
Christophe THOMAS
oxygen77 at free.fr
Tue Dec 16 22:36:22 CET 2008
Hello all,
I have an application that uses some QDockwidgets, a popup menu is shown
when I right-click on the top of one them and I can hide/show the docked
widgets. This fine for me.
I also have in the QMainWindow an event handler that manages
mouseclicked events of the central widget: mouseClicked(QMouseEvent *)
signal of the central widget connected to a slot of QMainWindow.
In this slot, when right-click is pressed, I show a contextual menu using:
menuPopupBtRight->exec(QCursor::pos());
menuPopupBtRight is a QMenu* which is composed of several actions. For
actions that just execute some simple code everything is going ok, for
others that needs to use a dialog (a custom class or a QMessageBox),
just at the end of the action QDockWidget popup menu is shown.
it looks like the first right-clicked event is send to parent in some
cases and not in others.
thx
Chris
More information about the Qt-interest-old
mailing list