forked from M-Labs/artiq
browser,dashboard: delete MDI subwindows when they are closed
This commit is contained in:
parent
692dc0803b
commit
2998372d08
|
@ -507,6 +507,7 @@ class ExperimentsArea(QtWidgets.QMdiArea):
|
||||||
exc_info=True)
|
exc_info=True)
|
||||||
dock = _ExperimentDock(self, expurl, {})
|
dock = _ExperimentDock(self, expurl, {})
|
||||||
asyncio.ensure_future(dock._recompute_arguments())
|
asyncio.ensure_future(dock._recompute_arguments())
|
||||||
|
dock.setAttribute(QtCore.Qt.WA_DeleteOnClose)
|
||||||
self.addSubWindow(dock)
|
self.addSubWindow(dock)
|
||||||
dock.show()
|
dock.show()
|
||||||
dock.sigClosed.connect(partial(self.on_dock_closed, dock))
|
dock.sigClosed.connect(partial(self.on_dock_closed, dock))
|
||||||
|
|
|
@ -562,6 +562,7 @@ class ExperimentManager:
|
||||||
del self.submission_arguments[expurl]
|
del self.submission_arguments[expurl]
|
||||||
dock = _ExperimentDock(self, expurl)
|
dock = _ExperimentDock(self, expurl)
|
||||||
self.open_experiments[expurl] = dock
|
self.open_experiments[expurl] = dock
|
||||||
|
dock.setAttribute(QtCore.Qt.WA_DeleteOnClose)
|
||||||
self.main_window.centralWidget().addSubWindow(dock)
|
self.main_window.centralWidget().addSubWindow(dock)
|
||||||
dock.show()
|
dock.show()
|
||||||
dock.sigClosed.connect(partial(self.on_dock_closed, expurl))
|
dock.sigClosed.connect(partial(self.on_dock_closed, expurl))
|
||||||
|
|
Loading…
Reference in New Issue