From 08822da460a1f5cd3648e47c3e4566acd2942670 Mon Sep 17 00:00:00 2001 From: Jonathan Harris Date: Wed, 12 Oct 2016 10:57:55 +0100 Subject: [PATCH] Bind update button instead of using command Fixes #145 --- EDMarketConnector.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/EDMarketConnector.py b/EDMarketConnector.py index 2efa545f..ac5bab2a 100755 --- a/EDMarketConnector.py +++ b/EDMarketConnector.py @@ -114,7 +114,7 @@ class AppWindow: if appitem: appitem.grid(columnspan=2, sticky=tk.W) - self.button = ttk.Button(frame, text=_('Update'), width=28, command=self.getandsend, default=tk.ACTIVE, state=tk.DISABLED) # Update button in main window + self.button = ttk.Button(frame, text=_('Update'), width=28, default=tk.ACTIVE, state=tk.DISABLED) # Update button in main window self.theme_button = tk.Label(frame, width = platform == 'darwin' and 32 or 28, state=tk.DISABLED) self.status = tk.Label(frame, name='status', anchor=tk.W) @@ -123,6 +123,7 @@ class AppWindow: self.theme_button.grid(row=row, columnspan=2, sticky=tk.NSEW) theme.register_alternate((self.button, self.theme_button), {'row':row, 'columnspan':2, 'sticky':tk.NSEW}) self.status.grid(columnspan=2, sticky=tk.EW) + self.button.bind('', self.getandsend) theme.button_bind(self.theme_button, self.getandsend) for child in frame.winfo_children():