// override // Override this method to add your menu items to the context menu protected override void OnGetMenuItems(GetMenuitemsEventArgs e) { var parent = e.Menu.AddItem("Copy Info", "copyInfo", "Copy some information into clipboard"); parent.HasSubMenu = true; //parent.OwnerDraw = true; var item1 = parent.SubMenu.InsertItem("Copy File Path", "copyFilePath", "Copied file path into clipboard.", 0); parent.SubMenu.InsertItem("Copy File Folder", "copyFileFolder", "Copied file folder into clipboard.", 1); parent.SubMenu.InsertItem("Copy File Name", "copyFileName", "Copied file name into clipboard.", 1); }
// override // Override this method to add your menu items to the context menu protected override void OnGetMenuItems(GetMenuitemsEventArgs e) { var parent = e.Menu.AddItem("Assembly", "assembly", "Assembly"); parent.HasSubMenu = true; //parent.OwnerDraw = true; parent.SubMenu.InsertItem("Install to GAC", "installtogac", "Install assembly into GAC", 0); //submenuitem.OwnerDraw = true; parent.SubMenu.InsertItem("Uninstall from GAC", "uninstallfromgac", "Uninstall assembly from GAC", 1); //submenuitem.OwnerDraw = true; }
// override // Override this method to add your menu items to the context menu protected override void OnGetMenuItems(GetMenuitemsEventArgs e) { var parent = e.Menu.AddItem("Solution", "solution", "Solution"); parent.HasSubMenu = true; foreach (var studio in VisualStudio.InstalledStudios) { var studioMenu = parent.SubMenu.AddItem(studio.Version.ToString()); studioMenu.HasSubMenu = true; CreateStudioMenu(studioMenu, studio.Path); } var studioDeafult = parent.SubMenu.AddItem("Default"); studioDeafult.HasSubMenu = true; CreateStudioMenu(studioDeafult, null); }
protected override void OnGetMenuItems(GetMenuitemsEventArgs e) { e.Menu.AddItem("Sample Extension", "sampleverb", "Status/help text"); }