Updated the Curses handling routines