Fix for Radio Buttons not being correct after loading from disk, Experimental Finalize that calls read(timeout=1)
This commit is contained in:
parent
fa8de0e8f1
commit
52e9852c4f
|
@ -1,5 +1,5 @@
|
||||||
#!/usr/bin/python3
|
#!/usr/bin/python3
|
||||||
version = __version__ = "4.5.0.23 Unreleased Mac Buttons. Element size get/set. Screen Size. hide/unhide row. Button rebinding. Element.expand"
|
version = __version__ = "4.5.0.24 Unreleased Mac Buttons. Element size get/set. Screen Size. hide/unhide row, Button rebinding, Element.expand, Experimental Finalize"
|
||||||
|
|
||||||
|
|
||||||
# 888888ba .d88888b oo dP .88888. dP dP dP
|
# 888888ba .d88888b oo dP .88888. dP dP dP
|
||||||
|
@ -627,6 +627,7 @@ class Element():
|
||||||
:param event:
|
:param event:
|
||||||
|
|
||||||
"""
|
"""
|
||||||
|
print(f'In return handler. event = {event}')
|
||||||
MyForm = self.ParentForm
|
MyForm = self.ParentForm
|
||||||
button_element = self._FindReturnKeyBoundButton(MyForm)
|
button_element = self._FindReturnKeyBoundButton(MyForm)
|
||||||
if button_element is not None:
|
if button_element is not None:
|
||||||
|
@ -1378,7 +1379,8 @@ class Radio(Element):
|
||||||
return
|
return
|
||||||
if value is not None:
|
if value is not None:
|
||||||
try:
|
try:
|
||||||
self.TKIntVar.set(self.EncodedRadioValue)
|
if value:
|
||||||
|
self.TKIntVar.set(self.EncodedRadioValue)
|
||||||
except:
|
except:
|
||||||
pass
|
pass
|
||||||
self.InitialState = value
|
self.InitialState = value
|
||||||
|
@ -5707,6 +5709,9 @@ class Window:
|
||||||
|
|
||||||
if self.TKrootDestroyed:
|
if self.TKrootDestroyed:
|
||||||
return self
|
return self
|
||||||
|
self.Read(timeout=1)
|
||||||
|
return self
|
||||||
|
# OLD CODE FOLLOWS
|
||||||
if not self.Shown:
|
if not self.Shown:
|
||||||
self._Show(non_blocking=True)
|
self._Show(non_blocking=True)
|
||||||
try:
|
try:
|
||||||
|
|
Loading…
Reference in New Issue