Don't print the error message about wm_overrideredirect while hiding the hidden master root if running on a Mac

This commit is contained in:
PySimpleGUI 2021-11-30 12:10:52 -05:00
parent fe8737dba4
commit f8a8e5bba0
1 changed files with 5 additions and 2 deletions

View File

@ -1,5 +1,5 @@
#!/usr/bin/python3 #!/usr/bin/python3
version = __version__ = "4.55.1.8 Unreleased" version = __version__ = "4.55.1.9 Unreleased"
_change_log = """ _change_log = """
Changelog since 4.55.1 released to PyPI on 7-Nov-2021 Changelog since 4.55.1 released to PyPI on 7-Nov-2021
@ -31,6 +31,8 @@ _change_log = """
Better auto-sizing of Columns for Tables. Better auto-sizing of Columns for Tables.
Better sizing of the row number column using the font for the header in the calculation Better sizing of the row number column using the font for the header in the calculation
Use the column heading font to help determine if the header will be what determines the width instead of the data in the column Use the column heading font to help determine if the header will be what determines the width instead of the data in the column
4.55.1.9
Don't print the error message about wm_overrideredirect while hiding the master root if running on a Mac.
""" """
__version__ = version.split()[0] # For PEP 396 and PEP 345 __version__ = version.split()[0] # For PEP 396 and PEP 345
@ -15638,6 +15640,7 @@ def StartupTK(window):
try: try:
Window.hidden_master_root.wm_overrideredirect(True) Window.hidden_master_root.wm_overrideredirect(True)
except Exception as e: except Exception as e:
if not running_mac():
print('* Error performing wm_overrideredirect while hiding the hidden master root*', e) print('* Error performing wm_overrideredirect while hiding the hidden master root*', e)
Window.hidden_master_root.withdraw() Window.hidden_master_root.withdraw()
# root = tk.Toplevel(Window.hidden_master_root) # This code caused problems when running with timeout=0 and closed with X # root = tk.Toplevel(Window.hidden_master_root) # This code caused problems when running with timeout=0 and closed with X