Flow.Launcher/Plugins/Flow.Launcher.Plugin.Url/SettingsControl.xaml.cs
2025-09-15 15:18:23 +08:00

27 lines
674 B
C#

using System.Windows;
using System.Windows.Controls;
namespace Flow.Launcher.Plugin.Url;
public partial class SettingsControl : UserControl
{
public Settings Settings { get; } = Main.Settings;
public SettingsControl()
{
InitializeComponent();
}
private void SelectBrowserPath(object sender, RoutedEventArgs e)
{
var dlg = new Microsoft.Win32.OpenFileDialog
{
Filter = Main.Context.API.GetTranslation("flowlauncher_plugin_url_plugin_filter")
};
if (dlg.ShowDialog() == true && !string.IsNullOrEmpty(dlg.FileName))
{
Settings.BrowserPath = dlg.FileName;
}
}
}