Maybe this should be in the Cursor class. Looks good though.