Significant improvements to dialog tests

This commit is contained in:
Veronica K. B. Olsen
2020-09-28 18:17:14 +02:00
parent bd5c011cd9
commit fc096ddb0b
17 changed files with 286 additions and 113 deletions
+13 -3
View File
@@ -124,13 +124,25 @@ class GuiProjectSettings(PagedDialog):
newList = self.tabReplace.getNewList()
self.theProject.setAutoReplace(newList)
self._doClose()
self._saveGuiSettings()
self.accept()
return
def _doClose(self):
"""Save settings and close the dialog.
"""
self._saveGuiSettings()
self.reject()
return
##
# Internal Functions
##
def _saveGuiSettings(self):
"""Save GUI settings.
"""
winWidth = self.mainConf.rpxInt(self.width())
winHeight = self.mainConf.rpxInt(self.height())
replaceColW = self.mainConf.rpxInt(self.tabReplace.listBox.columnWidth(0))
@@ -139,8 +151,6 @@ class GuiProjectSettings(PagedDialog):
self.optState.setValue("GuiProjectSettings", "winHeight", winHeight)
self.optState.setValue("GuiProjectSettings", "replaceColW", replaceColW)
self.close()
return
# END Class GuiProjectSettings