diff --git a/Plugins/Flow.Launcher.Plugin.Explorer/Languages/en.xaml b/Plugins/Flow.Launcher.Plugin.Explorer/Languages/en.xaml
index 7d0a553a4..2e0f6a67d 100644
--- a/Plugins/Flow.Launcher.Plugin.Explorer/Languages/en.xaml
+++ b/Plugins/Flow.Launcher.Plugin.Explorer/Languages/en.xaml
@@ -98,8 +98,11 @@
Delete
Permanently delete current file
Permanently delete current folder
- Path:
- Name:
+ Name
+ Type
+ Path
+ File
+ Folder
Delete the selected
Run as different user
Run the selected using a different user account
diff --git a/Plugins/Flow.Launcher.Plugin.Explorer/Views/QuickAccessLinkSettings.xaml b/Plugins/Flow.Launcher.Plugin.Explorer/Views/QuickAccessLinkSettings.xaml
index e9ba53618..f35633bc5 100644
--- a/Plugins/Flow.Launcher.Plugin.Explorer/Views/QuickAccessLinkSettings.xaml
+++ b/Plugins/Flow.Launcher.Plugin.Explorer/Views/QuickAccessLinkSettings.xaml
@@ -1,22 +1,23 @@
-
-
-
-
+
+
+
+
@@ -58,55 +59,91 @@
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
-
-
+ IsReadOnly="True"
+ Text="{Binding SelectedPath, Mode=TwoWay}" />
-
-
+ Click="SelectPath_OnClick"
+ Content="{DynamicResource select}" />
+
+
\ No newline at end of file
diff --git a/Plugins/Flow.Launcher.Plugin.Explorer/Views/QuickAccessLinkSettings.xaml.cs b/Plugins/Flow.Launcher.Plugin.Explorer/Views/QuickAccessLinkSettings.xaml.cs
index 36a00e9e5..1e52ea81e 100644
--- a/Plugins/Flow.Launcher.Plugin.Explorer/Views/QuickAccessLinkSettings.xaml.cs
+++ b/Plugins/Flow.Launcher.Plugin.Explorer/Views/QuickAccessLinkSettings.xaml.cs
@@ -49,9 +49,9 @@ public partial class QuickAccessLinkSettings : INotifyPropertyChanged
private bool IsEdit { get; }
private AccessLink SelectedAccessLink { get; }
-
+
public ObservableCollection QuickAccessLinks { get; }
-
+
public QuickAccessLinkSettings(ObservableCollection quickAccessLinks)
{
IsEdit = false;
@@ -96,7 +96,7 @@ public partial class QuickAccessLinkSettings : INotifyPropertyChanged
}
// If editing, update the existing link
- if (IsEdit)
+ if (IsEdit)
{
if (SelectedAccessLink == null) return;
@@ -130,12 +130,30 @@ public partial class QuickAccessLinkSettings : INotifyPropertyChanged
private void SelectPath_OnClick(object commandParameter, RoutedEventArgs e)
{
- var folderBrowserDialog = new FolderBrowserDialog();
+ // Open file or folder selection dialog based on the selected radio button
+ if (IsFileSelected)
+ {
+ var openFileDialog = new Microsoft.Win32.OpenFileDialog
+ {
+ Multiselect = false,
+ CheckFileExists = true,
+ CheckPathExists = true
+ };
- if (folderBrowserDialog.ShowDialog() != System.Windows.Forms.DialogResult.OK)
- return;
+ if (openFileDialog.ShowDialog() == true)
+ {
+ SelectedPath = openFileDialog.FileName;
+ }
+ }
+ else // Folder selection
+ {
+ var folderBrowserDialog = new FolderBrowserDialog();
- SelectedPath = folderBrowserDialog.SelectedPath;
+ if (folderBrowserDialog.ShowDialog() == System.Windows.Forms.DialogResult.OK)
+ {
+ SelectedPath = folderBrowserDialog.SelectedPath;
+ }
+ }
}
public event PropertyChangedEventHandler PropertyChanged;
@@ -144,4 +162,14 @@ public partial class QuickAccessLinkSettings : INotifyPropertyChanged
{
PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
}
+
+ public bool IsFileSelected { get; set; }
+ public bool IsFolderSelected { get; set; }
+
+ public QuickAccessLinkSettings()
+ {
+ IsFolderSelected = true; // Default to folder selection
+ InitializeComponent();
+ DataContext = this;
+ }
}