This will keep the primary action and menu properties of the UIBarButtonItem and apply them to the button. If no primary action is set, the menu will be used as primary action automatically. PiperOrigin-RevId: 321320327