Fix view restoration problem
Extract common tab setup code
Remove unnecessary setupViews method
Fix #248: rearrange menu items