/// <summary> /// Extends the menu. /// </summary> /// <remarks> /// </remarks> protected override void ExtendMenu() { // Create menu definition with one tab which contains one group var menuDefinition = new MenuDefinition(this, string.Empty); var tabDefinition = new MenuTabDefinition(this.Caption, "T"); menuDefinition.Add(tabDefinition); var groupDefinition = new MenuGroupDefinition(this, this.Caption); tabDefinition.Add(groupDefinition); // register module specific menu definition // and retrieve associated menu group manager this.MenuService.CreateUIModuleMenu(menuDefinition); IMenuGroupManager groupManager = this.MenuService.GetMenuGroupManager(this.ModuleId); // add commands to the menu group manager if (groupManager != null) { var viewModel = this.Container.Resolve <IFeatureExtractionUIViewModel>(); groupManager.AddCommandTool( viewModel.ToggleCommandA, this.GetImageFromImageFile("Images/TestImage.png")); groupManager.AddCommandTool( viewModel.TriggerCommandB, this.GetImageFromImageFile("Images/TestImage.png")); } }
/// <summary> /// Extends the menu. /// </summary> /// <remarks> /// </remarks> protected override void ExtendMenu() { var menuDefinition = new MenuDefinition(this, string.Empty); var tabDefinition = new MenuTabDefinition("Experiment Setup", "E"); menuDefinition.Add(tabDefinition); var tabDefinition1 = new MenuTabDefinition("Process", "P"); menuDefinition.Add(tabDefinition1); var groupDefinition1 = new MenuGroupDefinition(this, "Workflow"); tabDefinition1.Add(groupDefinition1); var tabDefinition2 = new MenuTabDefinition("Export/Report", "R"); menuDefinition.Add(tabDefinition2); this.MenuService.CreateControllerModuleMenu(menuDefinition); var viewModel = this.Container.Resolve <IProfinderControllerViewModel>(); IMenuGroupManager groupManager = this.MenuService.GetMenuGroupManager(this.ModuleId); if (groupManager != null) { groupManager.AddCommandTool( viewModel.ExperimentSetupCommand, this.GetImageFromImageFile("Images/experiment-setup.png"), this.GetImageFromImageFile("Images/experiment-setup.png")); groupManager.AddCommandTool( viewModel.FeatureExtractionCommand, this.GetImageFromImageFile("Images/feature-extraction.png"), this.GetImageFromImageFile("Images/feature-extraction.png")); groupManager.AddCommandTool( viewModel.StatisticAnalysisCommand, this.GetImageFromImageFile("Images/statistical-analysis.png"), this.GetImageFromImageFile("Images/statistical-analysis.png")); groupManager.AddCommandTool( viewModel.IdentificationCommand, this.GetImageFromImageFile("Images/compound-identification.png"), this.GetImageFromImageFile("Images/compound-identification.png")); groupManager.AddCommandTool( viewModel.ReportCommand, this.GetImageFromImageFile("Images/report-create.png"), this.GetImageFromImageFile("Images/report-create.png")); } }
/// <summary> /// Extends the menu. /// </summary> /// <remarks> /// </remarks> protected override void ExtendMenu() { // Create module menu definition with one group var menuDefinition = new MenuGroupDefinition(this, this.Caption); this.MenuService.CreateControllerModuleMenuGroup(menuDefinition); // register module specific menu definition // and retrieve associated nemu group manager var viewModel = this.Container.Resolve <IControllerModuleViewModel>(); IMenuGroupManager groupManager = this.MenuService.GetMenuGroupManager(this.ModuleId); if (groupManager != null) { groupManager.AddCommandTool( viewModel.ToggleCommandA, this.GetImageFromImageFile("Images/TestImage.png")); groupManager.AddCommandTool( viewModel.TriggerCommandB, this.GetImageFromImageFile("Images/TestImage.png")); } }
/// <summary> /// Extends the menu. /// </summary> /// <remarks> /// </remarks> protected override void ExtendMenu() { // Create menu definition with one tab which contains one group var menuDefinition = new MenuDefinition(this, string.Empty); var tabDefinition = new MenuTabDefinition(this.Caption, "T"); menuDefinition.Add(tabDefinition); var groupDefinition = new MenuGroupDefinition(this, "Display Mode"); tabDefinition.Add(groupDefinition); // register module specific menu definition // and retrieve associated menu group manager this.MenuService.CreateUIModuleMenu(menuDefinition); IMenuGroupManager groupManager = this.MenuService.GetMenuGroupManager(this.ModuleId); // add commands to the menu group manager if (groupManager != null) { var viewModel = this.Container.Resolve <ICompoundChromatogramViewModel>(); groupManager.AddCommandTool( viewModel.ListModeCommand, "List", this.GetImageFromImageFile("Images/ListMode.png")); groupManager.AddCommandTool( viewModel.OverlayModeCommand, "Overlay", this.GetImageFromImageFile("Images/OverlayMode.png")); groupManager.AddCommandTool( viewModel.GroupOverlayModeCommand, "GroupOverlay", this.GetImageFromImageFile("Images/SampleGroup.png")); groupManager.AddCommandTool( viewModel.SampleGroupModeCommand, "Group", this.GetImageFromImageFile("Images/ColorBySampleGroup.png")); groupManager.AddCommandTool( viewModel.ExportCommand, this.GetImageFromImageFile("Images/TestImage.png"), this.GetImageFromImageFile("Images/TestImage.png")); } }