def do_quit(self): if self.window is not None: windowFrame = self.window.nswindow.frame() windowFrame.size.height -= 22 app.config.set(prefs.LEFT_VIEW_SIZE, self.window.splitter.get_left_width()) app.config.set(prefs.MAIN_WINDOW_FRAME, NSStringFromRect(windowFrame)) app.config.save() Application.do_quit(self)