mirror of
https://github.com/microsoft/PowerToys.git
synced 2024-12-14 19:49:15 +08:00
Reverse changes made to new browser window call
This commit is contained in:
parent
b565d1ab76
commit
3e292d7604
@ -17,12 +17,19 @@ namespace Wox.Plugin.SharedCommands
|
||||
.Split(new[] { Path.DirectorySeparatorChar }, StringSplitOptions.None)
|
||||
.Last();
|
||||
|
||||
var selectedBrowserPath = string.IsNullOrEmpty(browserExecutableName) ? "chrome" : browserPath;
|
||||
var browser = string.IsNullOrEmpty(browserExecutableName) ? "chrome" : browserPath;
|
||||
|
||||
// Internet Explorer will open url in new browser window, and does not take the --new-window parameter
|
||||
var browserArguements = browserExecutableName == "iexplore.exe" ? "" : "--new-window ";
|
||||
var browserArguements = browserExecutableName == "iexplore.exe" ? url : "--new-window " + url;
|
||||
|
||||
OpenWebSearch(selectedBrowserPath, browserArguements, url);
|
||||
try
|
||||
{
|
||||
Process.Start(browser, browserArguements);
|
||||
}
|
||||
catch (System.ComponentModel.Win32Exception)
|
||||
{
|
||||
Process.Start(url);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
Loading…
Reference in New Issue
Block a user