/// <summary> /// Initializes a new instance of the <see cref="FiniteStateBrowserViewModel"/> class /// </summary> /// <param name="iteration"> /// The iteration. /// </param> /// <param name="session"> /// The session /// </param> /// <param name="thingDialogNavigationService"> /// the <see cref="IThingDialogNavigationService"/> /// </param> /// <param name="panelNavigationService"> /// the <see cref="IPanelNavigationService"/> /// </param> /// <param name="dialogNavigationService"> /// The <see cref="IDialogNavigationService"/> /// </param> /// <param name="pluginSettingsService"> /// The <see cref="IPluginSettingsService"/> used to read and write plugin setting files. /// </param> /// <param name="parameterActualFiniteStateListApplicationBatchService"> /// The <see cref="IParameterActualFiniteStateListApplicationBatchService"/> used to update multiple <see cref="Parameter"/>s to set the <see cref="ActualFiniteStateList"/> in a batch operation /// </param> public FiniteStateBrowserViewModel(Iteration iteration, ISession session, IThingDialogNavigationService thingDialogNavigationService, IPanelNavigationService panelNavigationService, IDialogNavigationService dialogNavigationService, IPluginSettingsService pluginSettingsService, IParameterActualFiniteStateListApplicationBatchService parameterActualFiniteStateListApplicationBatchService) : base(iteration, session, thingDialogNavigationService, panelNavigationService, dialogNavigationService, pluginSettingsService) { this.Caption = $"{PanelCaption}, iteration_{this.Thing.IterationSetup.IterationNumber}"; this.ToolTip = $"{((EngineeringModel)this.Thing.Container).EngineeringModelSetup.Name}\n{this.Thing.IDalUri}\n{this.Session.ActivePerson.Name}"; this.parameterActualFiniteStateListApplicationBatchService = parameterActualFiniteStateListApplicationBatchService; this.UpdatePossibleFiniteStatesList(); this.UpdateActualFiniteStatesList(); this.AddSubscriptions(); this.UpdateProperties(); }
/// <summary> /// Initializes a new instance of the <see cref="EngineeringModelRibbonPart"/> class. /// </summary> /// <param name="order"> /// The order in which the ribbon part is to be presented on the Office Ribbon /// </param> /// <param name="panelNavigationService"> /// An instance of <see cref="IPanelNavigationService"/> that orchestrates navigation of <see cref="IPanelView"/> /// </param> /// <param name="dialogNavigationService"> /// An instance of <see cref="IDialogNavigationService"/> that orchestrates dialog navigation. /// </param> /// <param name="thingDialogNavigationService">The <see cref="IThingDialogNavigationService"/> that handles navigation to dialogs</param> /// <param name="pluginSettingsService"> /// The <see cref="IPluginSettingsService"/> used to read and write plugin setting files. /// </param> /// <param name="parameterActualFiniteStateListApplicationBatchService"> /// The <see cref="IParameterActualFiniteStateListApplicationBatchService"/> used to update multiple <see cref="Parameter"/>s /// to set the <see cref="ActualFiniteStateList"/> in a batch operation /// </param> /// <param name="changeOwnershipBatchService"> /// The <see cref="IChangeOwnershipBatchService"/> used to change the ownership of multiple <see cref="IOwnedThing"/>s in a batch operation /// </param> public EngineeringModelRibbonPart(int order, IPanelNavigationService panelNavigationService, IDialogNavigationService dialogNavigationService, IThingDialogNavigationService thingDialogNavigationService, IPluginSettingsService pluginSettingsService, IParameterSubscriptionBatchService parameterSubscriptionBatchService, IParameterActualFiniteStateListApplicationBatchService parameterActualFiniteStateListApplicationBatchService, IChangeOwnershipBatchService changeOwnershipBatchService) : base(order, panelNavigationService, thingDialogNavigationService, dialogNavigationService, pluginSettingsService) { this.parameterSubscriptionBatchService = parameterSubscriptionBatchService; this.parameterActualFiniteStateListApplicationBatchService = parameterActualFiniteStateListApplicationBatchService; this.changeOwnershipBatchService = changeOwnershipBatchService; this.openElementDefinitionBrowsers = new List <ElementDefinitionsBrowserViewModel>(); this.openOptionBrowsers = new List <OptionBrowserViewModel>(); this.openFiniteStateBrowsers = new List <FiniteStateBrowserViewModel>(); this.openPublicationBrowsers = new List <PublicationBrowserViewModel>(); this.Iterations = new List <Iteration>(); CDPMessageBus.Current.Listen <SessionEvent>().Subscribe(this.SessionChangeEventHandler); CDPMessageBus.Current.Listen <ObjectChangedEvent>(typeof(Iteration)) .ObserveOn(RxApp.MainThreadScheduler) .Subscribe(this.IterationChangeEventHandler); CDPMessageBus.Current.Listen <HidePanelEvent>() .Subscribe(this.CloseHiddenPanel); }
public EngineeringModelModule(IFluentRibbonManager ribbonManager, IPanelNavigationService panelNavigationService, IDialogNavigationService dialogNavigationService, IThingDialogNavigationService thingDialogNavigationService, IPluginSettingsService pluginSettingsService, IParameterSubscriptionBatchService parameterSubscriptionBatchService, IParameterActualFiniteStateListApplicationBatchService parameterActualFiniteStateListApplicationBatchService, IChangeOwnershipBatchService changeOwnershipBatchService) { this.RibbonManager = ribbonManager; this.PanelNavigationService = panelNavigationService; this.DialogNavigationService = dialogNavigationService; this.ThingDialogNavigationService = thingDialogNavigationService; this.PluginSettingsService = pluginSettingsService; this.ParameterSubscriptionBatchService = parameterSubscriptionBatchService; this.ParameterActualFiniteStateListApplicationBatchService = parameterActualFiniteStateListApplicationBatchService; this.ChangeOwnershipBatchService = changeOwnershipBatchService; }