The sidebar in view pivot was not hidden when switching from view pivot
to another view. Thus, the sidebar content of view pivot was still in a
dropdown of the sidebar of the new view (when this new view has a
sidebar as well).
Also changed the way of switching between views: we now first hide the
current view before creating and displaying the new one. This prevents
weird rendering in the header as well.
Moreover, the task of hidding/showing the view's buttons is left to the
view instead of the ViewManager.