From c0ab3f7fbbecf490e197dc345beea8d1f7c8418c Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Fri, 3 Feb 2006 23:07:15 +0000 Subject: [PATCH] Allow Save Settings to save even when AutoSave is turned off git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@37288 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- wxPython/wx/py/crust.py | 6 +++--- wxPython/wx/py/shell.py | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/wxPython/wx/py/crust.py b/wxPython/wx/py/crust.py index dc161d603b..371638f604 100644 --- a/wxPython/wx/py/crust.py +++ b/wxPython/wx/py/crust.py @@ -291,17 +291,17 @@ class CrustFrame(frame.Frame, frame.ShellFrameMixin): self.crust.LoadSettings(self.config) - def SaveSettings(self): + def SaveSettings(self, force=False): if self.config is not None: frame.ShellFrameMixin.SaveSettings(self) - if self.autoSaveSettings: + if self.autoSaveSettings or force: frame.Frame.SaveSettings(self, self.config) self.crust.SaveSettings(self.config) def DoSaveSettings(self): if self.config is not None: - self.SaveSettings() + self.SaveSettings(force=True) self.config.Flush() diff --git a/wxPython/wx/py/shell.py b/wxPython/wx/py/shell.py index a0cdcf88a2..e45ff175ee 100644 --- a/wxPython/wx/py/shell.py +++ b/wxPython/wx/py/shell.py @@ -106,16 +106,16 @@ class ShellFrame(frame.Frame, frame.ShellFrameMixin): frame.Frame.LoadSettings(self, self.config) self.shell.LoadSettings(self.config) - def SaveSettings(self): + def SaveSettings(self, force=False): if self.config is not None: frame.ShellFrameMixin.SaveSettings(self) - if self.autoSaveSettings: + if self.autoSaveSettings or force: frame.Frame.SaveSettings(self, self.config) self.shell.SaveSettings(self.config) def DoSaveSettings(self): if self.config is not None: - self.SaveSettings() + self.SaveSettings(force=True) self.config.Flush() -- 2.47.2