mirror of
https://github.com/microsoft/PowerToys.git
synced 2024-12-16 04:29:16 +08:00
33 lines
937 B
C#
33 lines
937 B
C#
|
using System.Windows;
|
||
|
using System.Windows.Controls;
|
||
|
using Wox.Plugin.BrowserBookmark.Models;
|
||
|
|
||
|
namespace Wox.Plugin.BrowserBookmark.Views
|
||
|
{
|
||
|
/// <summary>
|
||
|
/// Interaction logic for BrowserBookmark.xaml
|
||
|
/// </summary>
|
||
|
public partial class SettingsControl : UserControl
|
||
|
{
|
||
|
private readonly Settings _settings;
|
||
|
|
||
|
public SettingsControl(Settings settings)
|
||
|
{
|
||
|
InitializeComponent();
|
||
|
_settings = settings;
|
||
|
NewWindowBrowser.IsChecked = _settings.OpenInNewBrowserWindow;
|
||
|
NewTabInBrowser.IsChecked = !_settings.OpenInNewBrowserWindow;
|
||
|
}
|
||
|
|
||
|
private void OnNewBrowserWindowClick(object sender, RoutedEventArgs e)
|
||
|
{
|
||
|
_settings.OpenInNewBrowserWindow = true;
|
||
|
}
|
||
|
|
||
|
private void OnNewTabClick(object sender, RoutedEventArgs e)
|
||
|
{
|
||
|
_settings.OpenInNewBrowserWindow = false;
|
||
|
}
|
||
|
}
|
||
|
}
|