From c22ab4afdf2dfdb8a88351b273aeed3058dc3d28 Mon Sep 17 00:00:00 2001 From: Jeremy Wu Date: Tue, 10 Dec 2019 20:11:12 +1100 Subject: [PATCH] Revert changes to other plugin. Will refactor as a separate PR --- Plugins/Wox.Plugin.Program/Programs/Win32.cs | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/Plugins/Wox.Plugin.Program/Programs/Win32.cs b/Plugins/Wox.Plugin.Program/Programs/Win32.cs index 12b54b524c..36e08a3c46 100644 --- a/Plugins/Wox.Plugin.Program/Programs/Win32.cs +++ b/Plugins/Wox.Plugin.Program/Programs/Win32.cs @@ -10,7 +10,6 @@ using Microsoft.Win32; using Shell; using Wox.Infrastructure; using Wox.Plugin.Program.Logger; -using Wox.Plugin.SharedCommands; namespace Wox.Plugin.Program.Programs { @@ -97,7 +96,14 @@ namespace Wox.Plugin.Program.Programs Title = api.GetTranslation("wox_plugin_program_run_as_administrator"), Action = _ => { - return Main.StartProcess(ShellCommand.SetProcessStartInfo(FullPath, ParentDirectory)); + var info = new ProcessStartInfo + { + FileName = FullPath, + WorkingDirectory = ParentDirectory, + Verb = "runas" + }; + var hide = Main.StartProcess(info); + return hide; }, IcoPath = "Images/cmd.png" },