Ensure cursor is reinitialized on keypress