From 96341667af917b9a975a446c657b666056238b89 Mon Sep 17 00:00:00 2001 From: MikeTheWatchGuy Date: Wed, 5 Sep 2018 12:43:41 -0400 Subject: [PATCH] Fix for button target being None, None instead of 0,0 --- PySimpleGUI.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/PySimpleGUI.py b/PySimpleGUI.py index 897778d6..c7572a98 100644 --- a/PySimpleGUI.py +++ b/PySimpleGUI.py @@ -825,9 +825,9 @@ class Button(Element): if target[1] < 0: target[1] = self.Position[1] + target[1] strvar = None - if target == (0,0) or target[0] == None: + if target == (None, None): strvar = self.TKStringVar - elif target[0] != None: + else: if target[0] < 0: target = [self.Position[0] + target[0], target[1]] target_element = self.ParentForm._GetElementAtLocation(target)