Added functionality to change cursor.