private void MyAppExit(bool blWindowsShutDown) { try { Utils.SaveLog("MyAppExit Begin"); StorageUI(); ConfigHandler.SaveConfig(ref config); //HttpProxyHandle.CloseHttpAgent(config); if (blWindowsShutDown) { SysProxyHandle.ResetIEProxy4WindowsShutDown(); } else { SysProxyHandle.UpdateSysProxy(config, true); } statistics?.SaveToFile(); statistics?.Close(); v2rayHandler.V2rayStop(); Utils.SaveLog("MyAppExit End"); } catch { } }
private void MyAppExit() { try { v2rayHandler.V2rayStop(); //HttpProxyHandle.CloseHttpAgent(config); HttpProxyHandle.UpdateSysProxy(config, true); ConfigHandler.SaveConfig(ref config); statistics?.SaveToFile(); statistics?.Close(); } catch { } }
/// <summary> /// 关闭V2ray /// </summary> private void CloseV2ray() { ConfigHandler.ToJsonFile(config); ChangePACButtonStatus(0); //ChangeSysAgent(false); v2rayHandler.V2rayStop(); }