fix bug, add more check to clear the selected item when not multi row selected is enabled