little refactor, move some draw code to a function named initScreen. add some code for mouse cursor, but not working now