finished selection functionality