コード例 #1
0
        protected override void Arrange()
        {
            base.Arrange();

            dependency          = Container.Resolve <ConfigurationSourceDependency>();
            dependency.Cleared += (sender, args) => refreshed = true;
        }
コード例 #2
0
 /// <summary>
 /// Initializes a new <see cref="ConfigurationSourceModel"/>.
 /// </summary>
 /// <param name="lookup">The <see cref="ElementLookup"/> service used for locating elements.</param>
 /// <param name="viewModelDependency">The <see cref="ConfigurationSourceDependency"/> for notifying others of changes in this configuration source.</param>
 /// <param name="builder">The container for building new objects.</param>
 /// <param name="uiService">The user-interface service for presenting dialogs and windows to the user.</param>
 /// <param name="saveOperation">Save operation integration with a host environment.</param>
 public ConfigurationSourceModel(ElementLookup lookup, ConfigurationSourceDependency viewModelDependency, IUnityContainer builder, IUIServiceWpf uiService, SaveOperation saveOperation)
 {
     this.uiService           = uiService;
     this.builder             = builder;
     this.viewModelDependency = viewModelDependency;
     this.lookup         = lookup;
     this.saveOperation  = saveOperation;
     sections            = new ObservableCollection <SectionViewModel>();
     readOnlySectionView = new ReadOnlyObservableCollection <SectionViewModel>(sections);
 }