Exemplo n.º 1
0
        public TrayController(ISettingsProvider settingsService,
                              IBatteryController batteryController)
        {
            _settingsService   = settingsService;
            _batteryController = batteryController;

            InitializeTrayIcon();

            _batteryController.BatteryProviderChanged += _batteryControllerBatteryProviderChanged;
            ChangeBatteryProvider(_batteryController.CurrentBatteryProvider);
        }
Exemplo n.º 2
0
        public ApplicationController(IExportLifetimeService exportLifetimeService,
                                     ITrayController trayController,
                                     IAsyncEventSource eventSource,
                                     IBatteryController batteryController,
                                     ExportFactory <MainWindowViewModel> mainWindowFactory)
        {
            _eventSource           = eventSource;
            _trayController        = trayController;
            _batteryController     = batteryController;
            _exportLifetimeService = exportLifetimeService;
            _mainWindowFactory     = mainWindowFactory;

            _trayController.OpenNetworkSettingsRequested += OnOpenNetworkSettingsRequested;
            _trayController.OpenActionsRequested         += OnOpenActionsRequested;
        }