My app loads a plugin which creates a window (QWidget
), but I can not destroy it when I exit from QMainWindow
, obviously because widget returned from plugin is not a child of QMainWindow
. The issue is that if I make that window to be a child of mainwindow, I get a window on another window. But I need them both to be separated. I did them separated (but main window has no control over window from plugin), in my case I do not know how to close window from plugin when app quits. How can I achieve that?
Asked
Active
Viewed 231 times
0

Bart
- 19,692
- 7
- 68
- 77
1 Answers
1
Just delete it. If you don't assign it a parent, no other widget has ownership. So you should simply be able to destroy it yourself on exit.

Bart
- 19,692
- 7
- 68
- 77