Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
887dd8da3b | ||
|
|
731db2541d | ||
|
|
bfdc0a2e77 |
@@ -5,6 +5,7 @@ using System.Diagnostics;
|
||||
using System.Drawing;
|
||||
using System.Text;
|
||||
using System.Text.RegularExpressions;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
using v2rayN.Base;
|
||||
using v2rayN.Handler;
|
||||
@@ -131,6 +132,7 @@ namespace v2rayN.Forms
|
||||
SysProxyHandle.UpdateSysProxy(config, true);
|
||||
}
|
||||
|
||||
StorageUI();
|
||||
ConfigHandler.SaveConfig(ref config);
|
||||
statistics?.SaveToFile();
|
||||
statistics?.Close();
|
||||
@@ -170,7 +172,7 @@ namespace v2rayN.Forms
|
||||
switch (Utils.ToInt(e.Name))
|
||||
{
|
||||
case (int)EGlobalHotkey.ShowForm:
|
||||
ShowForm();
|
||||
if (this.ShowInTaskbar) HideForm(); else ShowForm();
|
||||
break;
|
||||
case (int)EGlobalHotkey.SystemProxyClear:
|
||||
SetListenerType(ESysProxyType.ForcedClear);
|
||||
@@ -462,7 +464,7 @@ namespace v2rayN.Forms
|
||||
/// <summary>
|
||||
/// 载入V2ray
|
||||
/// </summary>
|
||||
private void LoadV2ray()
|
||||
async Task LoadV2ray()
|
||||
{
|
||||
tsbReload.Enabled = false;
|
||||
|
||||
@@ -470,7 +472,11 @@ namespace v2rayN.Forms
|
||||
{
|
||||
ClearMsg();
|
||||
}
|
||||
v2rayHandler.LoadV2ray(config);
|
||||
await Task.Run(() =>
|
||||
{
|
||||
v2rayHandler.LoadV2ray(config);
|
||||
});
|
||||
|
||||
Global.reloadV2ray = false;
|
||||
ConfigHandler.SaveConfig(ref config, false);
|
||||
statistics?.SaveToFile();
|
||||
@@ -834,6 +840,7 @@ namespace v2rayN.Forms
|
||||
|
||||
private void tsbClose_Click(object sender, EventArgs e)
|
||||
{
|
||||
StorageUI();
|
||||
HideForm();
|
||||
//this.WindowState = FormWindowState.Minimized;
|
||||
}
|
||||
|
||||
@@ -32,4 +32,4 @@ using System.Runtime.InteropServices;
|
||||
// 方法是按如下所示使用“*”:
|
||||
//[assembly: AssemblyVersion("1.0.*")]
|
||||
//[assembly: AssemblyVersion("1.0.0")]
|
||||
[assembly: AssemblyFileVersion("4.35")]
|
||||
[assembly: AssemblyFileVersion("4.36")]
|
||||
|
||||
@@ -719,16 +719,14 @@ namespace v2rayN
|
||||
{
|
||||
if (enableSecurityProtocolTls13)
|
||||
{
|
||||
ServicePointManager.SecurityProtocol = SecurityProtocolType.Ssl3
|
||||
| SecurityProtocolType.Tls
|
||||
ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls
|
||||
| SecurityProtocolType.Tls11
|
||||
| SecurityProtocolType.Tls12
|
||||
| SecurityProtocolType.Tls13;
|
||||
}
|
||||
else
|
||||
{
|
||||
ServicePointManager.SecurityProtocol = SecurityProtocolType.Ssl3
|
||||
| SecurityProtocolType.Tls
|
||||
ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls
|
||||
| SecurityProtocolType.Tls11
|
||||
| SecurityProtocolType.Tls12;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user