Refactoring tab menus.