Fixed some oops in cursor render code