public WeighDataCamerasPresenter(ModalViewManager modal, IEventAggregator eventAgrigator)
        {
            _modalManager = modal;
            _eventAgrigator = eventAgrigator;

            CloseMeCommand = new DelegateCommand<object>(CloseMe);
        }
Beispiel #2
0
        public ShellPresenter(IUnityContainer container,IEventAggregator eventAggregator, ModalViewManager modalViewManager)
        {
            ModalView = modalViewManager;

            ModalView.Show(container.Resolve<Views.ConnectionView>(),ModalViewType.Center);

            eventAggregator.GetEvent<DisconnectEvent>().Subscribe(
                o =>
                {
                    ModalView.Show(container.Resolve<Views.LostConnectView>(), ModalViewType.Center);
                }, true);
        }
 public ConnectionPresenter(StorageService service, AppSettings settings, ModalViewManager modalViewManager)
 {
     _service = service;
     _settings = settings;
     ConnectCommand = new DelegateCommand<object>(
         (o) =>
         {
             _settings.Save();
             _service.Connect();
             if (_service.IsConnect)
             {
                 modalViewManager.Hide();
             }
             HasProblems = !_service.IsConnect;
         });
 }