Make build settings dialog a child of main gui, and ensure only one instance can be open for each build

This commit is contained in:
Veronica Berglyd Olsen
2023-08-06 23:04:59 +02:00
parent 4951e4f8fe
commit 28263dcbac
3 changed files with 32 additions and 12 deletions
+12 -2
View File
@@ -69,8 +69,8 @@ class GuiBuildSettings(QDialog):
newSettingsReady = pyqtSignal(BuildSettings)
def __init__(self, parent: QWidget, mainGui: GuiMain, build: BuildSettings) -> None:
super().__init__(parent=parent)
def __init__(self, mainGui: GuiMain, build: BuildSettings) -> None:
super().__init__(parent=mainGui)
logger.debug("Create: GuiBuildSettings")
self.setObjectName("GuiBuildSettings")
@@ -171,6 +171,7 @@ class GuiBuildSettings(QDialog):
def __del__(self) -> None: # pragma: no cover
logger.debug("Delete: GuiBuildSettings")
return
def loadContent(self) -> None:
"""Populate the child widgets."""
@@ -182,6 +183,15 @@ class GuiBuildSettings(QDialog):
self.optTabOutput.loadContent()
return
##
# Properties
##
@property
def buildID(self) -> str:
"""The build ID of the build of the dialog."""
return self._build.buildID
##
# Private Slots
##