diff options
-rw-r--r-- | examples/x-window-focus | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/examples/x-window-focus b/examples/x-window-focus index 5b2a685..81e75d9 100644 --- a/examples/x-window-focus +++ b/examples/x-window-focus @@ -129,7 +129,11 @@ def periodically(year, month, day, hour, minute, second, weekday, fade): # Get window specifications wm_class = window.get_wm_class() - wm_name = window.get_wm_name() + wm_name = None + try: + wm_name = window.get_wm_name() + except: + pass ## Buf in python3-xlib (?) if (wm_class is None) and (wm_name is None): x_display.next_event() return |