/// <summary> /// 添加子菜单信息 /// </summary> /// <param name="data"></param> /// <param name="isUnique">子菜单是否需要检测已经添加</param> public void AddChildMenuData(MenuData data, bool isUnique = true) { if (isUnique && ChildMenus.Contains(data)) { return; } ChildMenus.Add(data); data.Parent = this; }
public void AddChildMenu(PopUpMenu child) { ChildMenus.Add(child); child.Parent = this; }
/// <summary> /// 子メニューにメニューを追加する /// </summary> /// <param name="menu"></param> public void AddChild(Menu menu) { ChildMenus.Add(menu); }
public void AddMenuItem(LtInfoMenuItem menuItemToAdd) { Check.Require(!HasUrl, "You cannot add children to a menu item that is a link!"); ChildMenus.Add(menuItemToAdd); }