Ejemplo n.º 1
0
        public void ToolsHistoryClick(Func <WorkUnitHistoryPresenter> presenterFactory)
        {
            try
            {
                if (_historyPresenter is null)
                {
                    _historyPresenter         = presenterFactory();
                    _historyPresenter.Closed += (s, e) => _historyPresenter = null;
                }
                _historyPresenter?.Show();
            }
            catch (Exception ex)
            {
                Logger.Error(ex.Message, ex);
                MessageBox.ShowError(Form, ex.Message, Core.Application.NameAndVersion);

                _historyPresenter?.Dispose();
                _historyPresenter = null;
            }
        }
Ejemplo n.º 2
0
 private void ConstructSystem()
 {
     Console.WriteLine("Construct system");
     _formPresenter = _container.Resolve<IFormPresenter>();
     //var formVisibilityModel = _container.Resolve<IToggleModel>();
     //_formPresenter.SetModel(formVisibilityModel);
 }
Ejemplo n.º 3
0
 private void DestroySystem()
 {
     Console.WriteLine("Destroy system");
     //_formPresenter.UnsetModel();
     //_container.Release(_formPresenter);
     _formPresenter = null;
 }