Fix window switching in vty.