AppKit.NSMenu CreateNSMenu (FixMenuDescriptor entrySet) { var menu = new AppKit.NSMenu (); foreach (var item in entrySet.Items) { if (item == FixMenuEntry.Separator) { menu.AddItem (AppKit.NSMenuItem.SeparatorItem); continue; } var subMenu = item as FixMenuDescriptor; if (subMenu != null) { var gtkSubMenu = new AppKit.NSMenuItem (item.Label.Replace ("_", "")); gtkSubMenu.Submenu = CreateNSMenu (subMenu); menu.AddItem (gtkSubMenu); continue; } var menuItem = new AppKit.NSMenuItem (item.Label.Replace ("_", "")); menuItem.Activated += delegate { item.Action (); }; menu.AddItem (menuItem); } return menu; }
AppKit.NSMenu CreateNSMenu(FixMenuDescriptor entrySet) { var menu = new AppKit.NSMenu(); foreach (var item in entrySet.Items) { if (item == FixMenuEntry.Separator) { menu.AddItem(AppKit.NSMenuItem.SeparatorItem); continue; } var subMenu = item as FixMenuDescriptor; if (subMenu != null) { var gtkSubMenu = new AppKit.NSMenuItem(item.Label.Replace("_", "")); gtkSubMenu.Submenu = CreateNSMenu(subMenu); menu.AddItem(gtkSubMenu); continue; } var menuItem = new AppKit.NSMenuItem(item.Label.Replace("_", "")); menuItem.Activated += delegate { item.Action(); }; menu.AddItem(menuItem); } return(menu); }
void ReleaseDesignerOutlets() { if (statusMenu != null) { statusMenu.Dispose(); statusMenu = null; } }
void ReleaseDesignerOutlets() { if (MainMenu != null) { MainMenu.Dispose(); MainMenu = null; } }
void ReleaseDesignerOutlets() { if (editMenu != null) { editMenu.Dispose(); editMenu = null; } }
void ReleaseDesignerOutlets() { if (dbNavOutlineView != null) { dbNavOutlineView.Dispose(); dbNavOutlineView = null; } if (dbVavMenu != null) { dbVavMenu.Dispose(); dbVavMenu = null; } }
void ReleaseDesignerOutlets() { if (SystemTrayStatusMenu != null) { SystemTrayStatusMenu.Dispose(); SystemTrayStatusMenu = null; } if (MyMainMenu != null) { MyMainMenu.Dispose(); MyMainMenu = null; } }
public virtual override void SetSubmenu(AppKit.NSMenu aMenu, AppKit.NSMenuItem anItem) { }
public static override void PopUpContextMenu(AppKit.NSMenu menu, AppKit.NSEvent theEvent, AppKit.NSView view, AppKit.NSFont font) { }
public virtual override nint IndexOfItem(AppKit.NSMenu submenu) { throw new NotImplementedException(); }
public override void MenuDidClose(AppKit.NSMenu menu) { data.SuppressTooltips = false; }
public override void MenuWillHighlightItem(AppKit.NSMenu menu, AppKit.NSMenuItem item) { }
void ReleaseDesignerOutlets () { if (EditMenu != null) { EditMenu.Dispose (); EditMenu = null; } }