MenuItem.from_model


Description:

[ CCode ( has_construct_function = false ) ]
[ Version ( since = "2.34" ) ]
public MenuItem.from_model (MenuModel model, int item_index)

Creates a MenuItem as an exact copy of an existing menu item in a MenuModel.

item_index must be valid (ie: be sure to call get_n_items first).

Parameters:

model

a MenuModel

item_index

the index of an item in model

Returns:

a new MenuItem.