Skip to content

Commit b93cebf

Browse files
committed
Fix 'BadWindow' x11 errors in wxpython.py example (cztomczak#334)
1 parent c5951b6 commit b93cebf

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

examples/wxpython.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,12 @@ def __init__(self):
6464
title='wxPython example', size=(WIDTH, HEIGHT))
6565
self.browser = None
6666

67+
# Must ignore X11 errors like 'BadWindow' and others by
68+
# installing X11 error handlers. This must be done after
69+
# wx was intialized.
70+
if LINUX:
71+
WindowUtils.InstallX11ErrorHandlers()
72+
6773
global g_count_windows
6874
g_count_windows += 1
6975

0 commit comments

Comments
 (0)