From cbb7aea388133ea71fffad5fde3baad807162d8c Mon Sep 17 00:00:00 2001 From: emkael Date: Sat, 12 Nov 2016 19:28:34 +0100 Subject: * saving config when app is closed with app button, not window button --- src/bidding_data_gui.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/bidding_data_gui.py') diff --git a/src/bidding_data_gui.py b/src/bidding_data_gui.py index a942db5..1547862 100644 --- a/src/bidding_data_gui.py +++ b/src/bidding_data_gui.py @@ -175,6 +175,10 @@ class BiddingGUI(tk.Frame): log.getLogger('config').error('Could not save config file: %s', ex) self.master.destroy() + def on_quit(self): + self.on_close() + self.quit() + # GUI message queue (for background thread interaction) __queue = None @@ -314,7 +318,7 @@ class BiddingGUI(tk.Frame): self, text='OCB?!', command=self.display_info) # application exit button quit_btn = tk.Button( - self, text='Koniec tego dobrego', command=self.quit) + self, text='Koniec tego dobrego', command=self.on_quit) # third and fourth row, leftmost 2/3 of window width, entire cell self.run_btn.grid( row=2, column=0, rowspan=2, columnspan=4, -- cgit v1.2.3