Fix tree mode row selection when collapsing row