diff --git a/Plugins/Flow.Launcher.Plugin.Program/Programs/Win32.cs b/Plugins/Flow.Launcher.Plugin.Program/Programs/Win32.cs index 935ae59a8..7f90367ab 100644 --- a/Plugins/Flow.Launcher.Plugin.Program/Programs/Win32.cs +++ b/Plugins/Flow.Launcher.Plugin.Program/Programs/Win32.cs @@ -140,10 +140,19 @@ namespace Flow.Launcher.Plugin.Program.Programs Title = api.GetTranslation("flowlauncher_plugin_program_open_containing_folder"), Action = _ => { + var args = !string.IsNullOrWhiteSpace(Main._settings.CustomizedArgs) + ?Main._settings.CustomizedArgs + .Replace("%s",$"\"{ParentDirectory}\"") + .Replace("%f",$"\"{FullPath}\""): + Main._settings.CustomizedExplorer==Settings.Explorer + ? $"/select,\"{FullPath}\"" + : Settings.ExplorerArgs; + Main.StartProcess(Process.Start, new ProcessStartInfo( - !string.IsNullOrWhiteSpace(Main._settings.CustomizedExplorer) ? Main._settings.CustomizedExplorer:Settings.Explorer, - !string.IsNullOrWhiteSpace(Main._settings.CustomizedArgs)?Main._settings.CustomizedArgs.Replace("%s",$"\"{ParentDirectory}\"").Replace("%f",$"\"{FullPath}\""): - Settings.ExplorerArgs)); + !string.IsNullOrWhiteSpace(Main._settings.CustomizedExplorer) + ? Main._settings.CustomizedExplorer + : Settings.Explorer, + args)); return true; }, IcoPath = "Images/folder.png" diff --git a/Plugins/Flow.Launcher.Plugin.Program/Settings.cs b/Plugins/Flow.Launcher.Plugin.Program/Settings.cs index b10346921..7cb02a852 100644 --- a/Plugins/Flow.Launcher.Plugin.Program/Settings.cs +++ b/Plugins/Flow.Launcher.Plugin.Program/Settings.cs @@ -21,7 +21,7 @@ namespace Flow.Launcher.Plugin.Program internal const string Explorer = "explorer"; - internal const string ExplorerArgs = "/select,%f"; + internal const string ExplorerArgs = "%s"; /// /// Contains user added folder location contents as well as all user disabled applications