Пример #1
0
        internal MainViewModel(MainWindow control)
        {
            view = control;
            control.DataContext = this;
            workflowController = new WorkFlowController();
            workflowController.Initialize(PopulateMessage);
            setting = workflowController.Settings;
            manualPictureCombiner = workflowController.ManualPictureCombiner;

            ApplySettingCommand = new RelayCommand(ApplySettingCommand_Executed);
            FullScanCommand = new RelayCommand(FullScanCommand_Executed, CanDoFullScan);
        }
Пример #2
0
        public void Initialize(MessageProcessor messageHandler)
        {
            //ViewModel require Settings and ManualPictureCombiner
            this.SettingManager = new SettingManager();
            SettingManager.ReadSettings(Settings);

            MessageDispatcher = new MessageDispatcher();
            MessageDispatcher.MessageHandler += messageHandler;

            photoModifier         = new PhotoModifier(Settings);
            fileWriter            = new FileWriter(Settings, MessageDispatcher);
            ManualPictureCombiner = new ManualPictureCombiner(photoModifier, fileWriter, MessageDispatcher);
            FolderScanner         = new FolderScanner(MessageDispatcher);
            FolderScanner.InitVisitors(Settings);
            FolderScanner.NewPhotoGoupHandler = HandlePictureGroup;
        }
Пример #3
0
        public void Initialize(MessageProcessor messageHandler)
        {
            //ViewModel require Settings and ManualPictureCombiner
            this.SettingManager = new SettingManager();
            SettingManager.ReadSettings(Settings);

            MessageDispatcher = new MessageDispatcher();
            MessageDispatcher.MessageHandler += messageHandler;

            photoModifier = new PhotoModifier(Settings);
            fileWriter = new FileWriter(Settings, MessageDispatcher);
            ManualPictureCombiner = new ManualPictureCombiner(photoModifier, fileWriter, MessageDispatcher);
            FolderScanner = new FolderScanner(MessageDispatcher);
            FolderScanner.InitVisitors(Settings);
            FolderScanner.NewPhotoGoupHandler = HandlePictureGroup;
        }