public MainViewModel(IManuscriptService manuscriptService, IEventAggregator eventAggregator, IWindowsDialogService windowsDialogService, IRegionManager regionManager) { CreateNewProjectCommand = new CreateNewProjectCommand(manuscriptService, eventAggregator, windowsDialogService); OpenExistingProjectCommand = new OpenExistingProjectCommand(manuscriptService, eventAggregator, windowsDialogService); SaveProjectCommand = new SaveProjectCommand(manuscriptService, windowsDialogService); ApplicationShutdownCommand = new ApplicationShutdownCommand(); _manuscriptService = manuscriptService; _eventAggregator = eventAggregator; _windowsDialogService = windowsDialogService; _regionManager = regionManager; }
public ManuscriptProjectViewModel(IManuscriptProject manuscriptProject, IRegionManager regionManager, IManuscriptService manuscriptService, IWindowsDialogService windowsDialogService) { _regionManager = regionManager; _manuscriptService = manuscriptService; _windowsDialogService = windowsDialogService; Name = manuscriptProject.Name; Categories = ToObservableCollection(manuscriptProject.Categories); Id = manuscriptProject.Id; foreach (var ctg in manuscriptProject.Categories) { ctg.CollectionChanged += OnProjectCategoryItemsChanged; foreach (var item in ctg.Items) { item.CollectionChanged += OnProjectItemReferencesChanged; } } }
public OpenExistingProjectCommand(IManuscriptService manuscriptService, IEventAggregator eventAggregator, IWindowsDialogService windowsDialogService) { _manuscriptService = manuscriptService; _eventAggregator = eventAggregator; _windowsDialogService = windowsDialogService; }
public ProjectStructureViewModel(IManuscriptService manuscriptService, IWindowsDialogService windowsDialogService) { GetCategoryItemsCommand = new DelegateCommand <ProjectCategoryViewModel>(GetCategoryItems); AddNewManuscriptItemCommand = new AddNewManuscriptItemCommand(manuscriptService); AddExistingManuscriptItemCommand = new AddExistingManuscriptItemCommand(manuscriptService, windowsDialogService); }
public SaveProjectCommand(IManuscriptService manuscriptService, IWindowsDialogService windowsDialogService) { _manuscriptService = manuscriptService; _windowsDialogService = windowsDialogService; }
public AddItemReferenceCommand(IManuscriptService manuscriptService, IWindowsDialogService windowsDialogService) { _manuscriptService = manuscriptService; _windowsDialogService = windowsDialogService; }
public CreateNewProjectCommand(IManuscriptService manuscriptService, IEventAggregator eventAggregator, IWindowsDialogService windowsDialogService) { _manuscriptService = manuscriptService; _eventAggregator = eventAggregator; _windowsDialogService = windowsDialogService; }
public AddExistingManuscriptItemCommand(IManuscriptService manuscriptService, IWindowsDialogService windowsDialogService) { _manuscriptService = manuscriptService; _windowsDialogService = windowsDialogService; }
public ProjectItemViewModel(string name, int ctgId, int id, string source, ObservableCollection <ProjectItemReferenceViewModel> references, IRegionManager regionManager, IManuscriptService manuscriptService, IWindowsDialogService windowsDialogService) { _name = name; _references = references; CtgId = ctgId; Id = id; Source = source; AddItemReferenceCommand = new AddItemReferenceCommand(manuscriptService, windowsDialogService); RemoveManuscriptItemCommand = new RemoveManuscriptItemCommand(manuscriptService); LoadContentCommand = new LoadContentCommand(regionManager); }