QWidgetAction remains visible after trigger ()

I have a QWidgetAction that contains a QWidget consisting of QLineEdit and QPushButton. As soon as the user clicks a button, a QWidgetAction will trigger a trigger slot.

Now I have QMenu, which I activate with exec. The problem is that even when the trigger is called (I also connected it to the print function to check), the menu will not be closed.

Regular QActions work well.

Any idea why?

PS As a result of this problem, I came through people with the same problem, but without solutions.

+3
source share

Source: https://habr.com/ru/post/1746360/


All Articles