Exemplo n.º 1
0
        public MainWindowVM(IImgService imgService, IImageFileSelector imageFileSelector, IDirectorySelector directorySelector, IAlertPresenter alertPresenter)
        {
            Contract.Requires(imgService != null);
            Contract.Requires(imageFileSelector != null);
            Contract.Requires(directorySelector != null);
            Contract.Requires(alertPresenter != null);

            this.imgService        = imgService;
            this.imageFileSelector = imageFileSelector;
            this.directorySelector = directorySelector;
            this.alertPresenter    = alertPresenter;

            Images = new ObservableCollection <ImageVM>();
            ReloadImages();
        }
Exemplo n.º 2
0
        void ConstructUseCases(IAuthController authController,
                               ILoginPresenter loginPresenter,
                               IAlertPresenter alertPresenter,
                               IUserAccountRepository userAccountRepository)
        {
            sceneUseCase = new SceneTransitionUseCase();
            alertUseCase = new AlertUseCase(alertPresenter, this);
            var authDelegates = new IAuthResultDelegate[] {
                alertUseCase as IAuthResultDelegate,
                sceneUseCase as IAuthResultDelegate
            };

            authUseCase = new AuthUseCase(loginPresenter,
                                          authController,
                                          userAccountRepository,
                                          authDelegates, this);
        }
Exemplo n.º 3
0
 public AlertUseCase(IAlertPresenter presenter, Component component)
 {
     this.presenter      = presenter;
     disposableComponent = component;
 }