ChineseChess/ChineseChess.GUI/Services/SystemService.cs
2021-05-30 22:57:53 +08:00

25 lines
549 B
C#

using System.Diagnostics;
using ChineseChess.GUI.Contracts.Services;
namespace ChineseChess.GUI.Services
{
public class SystemService : ISystemService
{
public SystemService()
{
}
public void OpenInWebBrowser(string url)
{
// For more info see https://github.com/dotnet/corefx/issues/10361
var psi = new ProcessStartInfo
{
FileName = url,
UseShellExecute = true
};
Process.Start(psi);
}
}
}