onGenerateMenuItemIds

Called before the main menu items are set to be ordered. Override this method to add your custom items to the list. You add just the ids and then in onCreateOptionsMenu and onPrepareOptionsMenu you can find your items by id and edit them accordingly.

Return

A final list of item ids, declaring how they're gonna be sorted in the toolbar.

Parameters

menuItems

A list of menu item ids, ordered by how they're gonna appear in the main toolbar.