Move cursor draw logic around