|
|
|
@ -12,6 +12,7 @@ using Lib.Logging.Interfaces; |
|
|
|
using Lib.Logging.Loggers.Factories; |
|
|
|
using Lib.Logging.Loggers.Factories; |
|
|
|
using Lib.Logging.Loggers.Interfaces; |
|
|
|
using Lib.Logging.Loggers.Interfaces; |
|
|
|
using Lib.NotifyIcon; |
|
|
|
using Lib.NotifyIcon; |
|
|
|
|
|
|
|
using Lib.ProcessManaging.Interfaces; |
|
|
|
using LightweightIocContainer.Interfaces; |
|
|
|
using LightweightIocContainer.Interfaces; |
|
|
|
using Mystify.ViewModels; |
|
|
|
using Mystify.ViewModels; |
|
|
|
using Mystify.Views; |
|
|
|
using Mystify.Views; |
|
|
|
@ -26,6 +27,8 @@ namespace Mystify |
|
|
|
private ILog? _log; |
|
|
|
private ILog? _log; |
|
|
|
private ILoggerInitializer? _loggerInitializer; |
|
|
|
private ILoggerInitializer? _loggerInitializer; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private IProcessManager? _processManager; |
|
|
|
|
|
|
|
|
|
|
|
private INotifyIcon? _notifyIcon; |
|
|
|
private INotifyIcon? _notifyIcon; |
|
|
|
|
|
|
|
|
|
|
|
private MainModel? _mainModel; |
|
|
|
private MainModel? _mainModel; |
|
|
|
@ -50,6 +53,9 @@ namespace Mystify |
|
|
|
|
|
|
|
|
|
|
|
await _log.WriteLogHeader<App>(); |
|
|
|
await _log.WriteLogHeader<App>(); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
_processManager = _kernel.Resolve<IProcessManager>(); |
|
|
|
|
|
|
|
_processManager.Initialize(); |
|
|
|
|
|
|
|
|
|
|
|
_mainModel = _kernel.Resolve<MainModel>(); |
|
|
|
_mainModel = _kernel.Resolve<MainModel>(); |
|
|
|
_mainWindow = new MainWindow(); |
|
|
|
_mainWindow = new MainWindow(); |
|
|
|
_mainWindowViewModel = new MainWindowViewModel(_mainModel, _mainWindow); |
|
|
|
_mainWindowViewModel = new MainWindowViewModel(_mainModel, _mainWindow); |
|
|
|
@ -92,6 +98,7 @@ namespace Mystify |
|
|
|
_mainWindow?.Close(); |
|
|
|
_mainWindow?.Close(); |
|
|
|
_mainModel?.Dispose(); |
|
|
|
_mainModel?.Dispose(); |
|
|
|
_notifyIcon?.Remove(); |
|
|
|
_notifyIcon?.Remove(); |
|
|
|
|
|
|
|
_processManager?.Dispose(); |
|
|
|
|
|
|
|
|
|
|
|
if (_log != null) |
|
|
|
if (_log != null) |
|
|
|
await _log.DisposeAsync(); |
|
|
|
await _log.DisposeAsync(); |
|
|
|
|