public SettingsWindow(ThemeSwitchService themeSwitchService, StartupHelper startupHelper)
        {
            _themeSwitchService = themeSwitchService;
            _startupHelper      = startupHelper;

            InitializeComponent();

            if (Settings.Default.Enabled)
            {
                EnableThemingCheckbox.IsChecked = true;
                TimePickers.Visibility          = Visibility.Visible;
            }
            else
            {
                EnableThemingCheckbox.IsChecked = false;
                TimePickers.Visibility          = Visibility.Collapsed;
            }

            StartTimePicker.SelectedDateTime = Settings.Default.StartTime;
            EndTimePicker.SelectedDateTime   = Settings.Default.EndTime;

            SaveButton.Visibility = Visibility.Collapsed;

            _observable = new ObservableCollection <string>();
            UpdateObservable();
            KeysListBox.ItemsSource = _observable;

            // TODO: Detect Windows theme switch while window is open
            StartupToggleSwitch.IsOn = Settings.Default.Startup;
        }
        public TrayIconHelper(ThemeSwitchService themeSwitchService, StartupHelper startupHelper, System.Windows.Application app)
        {
            _themeSwitchService = themeSwitchService;
            _startupHelper      = startupHelper;

            var notifyIcon = new NotifyIcon();

            notifyIcon.Icon             = Resource.TrayIcon;
            notifyIcon.Text             = "Auto Dark Mode";
            notifyIcon.MouseDown       += TrayIcon_Click;
            notifyIcon.ContextMenuStrip = new ContextMenuStrip();
            notifyIcon.ContextMenuStrip.Items.Add(_forceDarkMenuItem);
            notifyIcon.ContextMenuStrip.Items.Add(_forceLightMenuItem);
            notifyIcon.ContextMenuStrip.Items.Add(_openConfigMenuItem);
            notifyIcon.ContextMenuStrip.Items.Add(_exitMenuItem);

            _forceDarkMenuItem.Click  += (_, __) => ThemeSwitchHelper.Switch(ThemeSwitchHelper.Mode.Dark);
            _forceLightMenuItem.Click += (_, __) => ThemeSwitchHelper.Switch(ThemeSwitchHelper.Mode.Light);
            _openConfigMenuItem.Click += (_, __) => TrayIcon_Click(this, new MouseEventArgs(MouseButtons.Left, 0, 0, 0, 0));
            _exitMenuItem.Click       += (_, __) => app.Shutdown();

            notifyIcon.Visible = true;
        }