Skip to content

Commit e96b914

Browse files
Window.Read with timeout=0 is same as ReadNonBlocking
1 parent 2733d80 commit e96b914

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

PySimpleGUI.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2748,6 +2748,8 @@ def _TimeoutAlarmCallback(self):
27482748
self.TKroot.quit() # kick the users out of the mainloop
27492749

27502750
def Read(self, timeout=None, timeout_key='_timeout_'):
2751+
if timeout == 0:
2752+
return self.ReadNonBlocking()
27512753
self.Timeout = timeout
27522754
self.TimeoutKey = timeout_key
27532755
self.NonBlocking = False

0 commit comments

Comments
 (0)