From 05d1eb745ed1a02334ba35a736da1acb3f5ae220 Mon Sep 17 00:00:00 2001 From: Ethan Dalool Date: Sun, 4 Jul 2021 22:22:10 -0700 Subject: [PATCH] Bind escape button to quit. --- PGUI.pyw | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/PGUI.pyw b/PGUI.pyw index 74852dc..8e2a848 100644 --- a/PGUI.pyw +++ b/PGUI.pyw @@ -28,6 +28,7 @@ class PGUILauncher(tkinter.ttk.Frame): self.filter_entry = tkinter.Entry(self, textvariable=self.filter_var) self.filter_entry.grid(row=0, column=0, columnspan=999, sticky='ew') self.filter_entry.bind('', self.launch_filtered) + self.filter_entry.bind('', self.quit) self.filter_entry.focus() x = 0 @@ -80,6 +81,9 @@ class PGUILauncher(tkinter.ttk.Frame): subprocess.Popen(command, shell=True) self.quit() + def quit(self, *args): + return super().quit() + def main(argv): root = tkinter.Tk()