Correctly show and hide view items