Rewrites the menu items.