From e96b9146804cbf30ff6d95d9382d6efbfc094187 Mon Sep 17 00:00:00 2001 From: MikeTheWatchGuy Date: Mon, 22 Oct 2018 10:43:32 -0400 Subject: [PATCH] Window.Read with timeout=0 is same as ReadNonBlocking --- PySimpleGUI.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/PySimpleGUI.py b/PySimpleGUI.py index 1510cb4d..bac28798 100644 --- a/PySimpleGUI.py +++ b/PySimpleGUI.py @@ -2748,6 +2748,8 @@ class Window: self.TKroot.quit() # kick the users out of the mainloop def Read(self, timeout=None, timeout_key='_timeout_'): + if timeout == 0: + return self.ReadNonBlocking() self.Timeout = timeout self.TimeoutKey = timeout_key self.NonBlocking = False