예제 #1
0
        public ConfiguratorViewModel(JsonManager jsonManager)
        {
            _stateManager = new ConfiguratorStateManager(jsonManager, _logger);

            _logger = new Common.IO.Logger(Paths.ConfiguratorLogFileName);

            TryLoadLastAppState();

            ApplyCommand = new DelegateCommand(Apply);
            ExitCommand  = new DelegateCommand(Application.Current.Shutdown);
        }
예제 #2
0
        public InjectorView()
        {
            try
            {
                InitializeComponent();
            }
            catch (Exception e)
            {
                var logger = new Common.IO.Logger(Common.Paths.InjectorLogFileName);

                logger.Log("InjectorView init failed.");
                logger.Log(e);

                Application.Current.Shutdown(2);
            }
        }
예제 #3
0
        public JsonFileLoader(JsonManager jsonManager, Common.IO.Logger logger = null)
        {
            _logger = logger;

            InitializeManagers(jsonManager);
        }