Fixed some oversights in the is_selected logic...