Follow-up fix for #9747 - also work correctly when no process is selected after one was selected.