|
@ -570,6 +570,7 @@ when isMainModule: |
|
|
elif (ev.theType == UnmapNotify): |
|
|
elif (ev.theType == UnmapNotify): |
|
|
# Switch focus potentially when a window is unmapped |
|
|
# Switch focus potentially when a window is unmapped |
|
|
windowZipper = windowZipper.zipperRemove(ev.xunmap.window) |
|
|
windowZipper = windowZipper.zipperRemove(ev.xunmap.window) |
|
|
|
|
|
if display.shouldTrackWindow(ev.xunmap.window.addr): |
|
|
let focus = windowZipper.zipperFocus |
|
|
let focus = windowZipper.zipperFocus |
|
|
if focus.isSome: |
|
|
if focus.isSome: |
|
|
discard display.XSetInputFocus(focus.get, RevertToPointerRoot, CurrentTime) |
|
|
discard display.XSetInputFocus(focus.get, RevertToPointerRoot, CurrentTime) |
|
|