Added Application.cleanup method which asks all windows to close

themselves and returns true if they did.
This commit is contained in:
Jack Jansen 1996-12-23 17:22:40 +00:00
parent 81aa0e2888
commit c75e1d052b
1 changed files with 5 additions and 0 deletions

View File

@ -115,6 +115,11 @@ class Application:
def _quit(self, *args):
self.quitting = 1
def cleanup(self):
for w in self._windows.values():
w.do_close()
return self._windows == {}
def appendwindow(self, wid, window):
self._windows[wid] = window