Selected tab fix

Fixed that the selected tab would not reset when tapping on the
background