@@ -16,8 +16,7 @@ namespace Shadowsocks.Controller | |||||
} | } | ||||
} | } | ||||
internal class PipeServer | |||||
internal class NamedPipeServer | |||||
{ | { | ||||
public event EventHandler<RequestAddUrlEventArgs> AddUrlRequested; | public event EventHandler<RequestAddUrlEventArgs> AddUrlRequested; | ||||
public async void Run(string path) | public async void Run(string path) |
@@ -148,9 +148,9 @@ namespace Shadowsocks | |||||
HotKeys.Init(MainController); | HotKeys.Init(MainController); | ||||
MainController.Start(); | MainController.Start(); | ||||
PipeServer pipeServer = new PipeServer(); | |||||
Task.Run(() => pipeServer.Run(pipename)); | |||||
pipeServer.AddUrlRequested += (_1, e) => MainController.AskAddServerBySSURL(e.Url); | |||||
NamedPipeServer namedPipeServer = new NamedPipeServer(); | |||||
Task.Run(() => namedPipeServer.Run(pipename)); | |||||
namedPipeServer.AddUrlRequested += (_1, e) => MainController.AskAddServerBySSURL(e.Url); | |||||
if (!addedUrl.IsNullOrEmpty()) | if (!addedUrl.IsNullOrEmpty()) | ||||
{ | { | ||||
MainController.AskAddServerBySSURL(addedUrl); | MainController.AskAddServerBySSURL(addedUrl); | ||||
@@ -113,8 +113,8 @@ | |||||
<Compile Include="Controller\HotkeyReg.cs" /> | <Compile Include="Controller\HotkeyReg.cs" /> | ||||
<Compile Include="Controller\LoggerExtension.cs" /> | <Compile Include="Controller\LoggerExtension.cs" /> | ||||
<Compile Include="Controller\Service\PACDaemon.cs" /> | <Compile Include="Controller\Service\PACDaemon.cs" /> | ||||
<Compile Include="Controller\Service\PipeServer.cs" /> | |||||
<Compile Include="Controller\System\ProtocolHandler.cs" /> | |||||
<Compile Include="Controller\Service\NamedPipeServer.cs" /> | |||||
<Compile Include="Controller\System\ProtocolHandler.cs" /> | |||||
<Compile Include="Controller\System\Hotkeys\HotkeyCallbacks.cs" /> | <Compile Include="Controller\System\Hotkeys\HotkeyCallbacks.cs" /> | ||||
<Compile Include="Encryption\AEAD\AEADEncryptor.cs" /> | <Compile Include="Encryption\AEAD\AEADEncryptor.cs" /> | ||||
<Compile Include="Encryption\AEAD\AEADMbedTLSEncryptor.cs" /> | <Compile Include="Encryption\AEAD\AEADMbedTLSEncryptor.cs" /> | ||||