From 244da05e70e7e1f35ea7a5db305ef87b2a1b41e1 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Fri, 17 Apr 2020 08:28:09 +0800 Subject: [PATCH 01/45] don't right align for testResults --- v2rayN/v2rayN/Forms/MainForm.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index a6b79333..b0d906ea 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -188,7 +188,7 @@ namespace v2rayN.Forms lvServers.Columns.Add(UIRes.I18N("LvEncryptionMethod"), 90); lvServers.Columns.Add(UIRes.I18N("LvTransportProtocol"), 70); lvServers.Columns.Add(UIRes.I18N("LvSubscription"), 50); - lvServers.Columns.Add(UIRes.I18N("LvTestResults"), 70, HorizontalAlignment.Right); + lvServers.Columns.Add(UIRes.I18N("LvTestResults"), 70); if (statistics != null && statistics.Enable) { From 1722e50402b47c6773e87caf98784a587ec6b974 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Fri, 17 Apr 2020 15:33:28 +0800 Subject: [PATCH 02/45] resort resx --- v2rayN/v2rayN/Forms/MainForm.resx | 2178 ++++++++--------- v2rayN/v2rayN/Forms/MainForm.zh-Hans.resx | 468 ++-- v2rayN/v2rayN/Forms/QRCodeControl.resx | 76 +- .../v2rayN/Properties/Resources.Designer.cs | 2 +- v2rayN/v2rayN/Properties/Resources.resx | 84 +- 5 files changed, 1404 insertions(+), 1404 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.resx b/v2rayN/v2rayN/Forms/MainForm.resx index 82105967..28fe8826 100644 --- a/v2rayN/v2rayN/Forms/MainForm.resx +++ b/v2rayN/v2rayN/Forms/MainForm.resx @@ -118,193 +118,131 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - Fill - - - 3, 17 - 327, 17 - - 355, 22 + + + 17, 17 + + + 137, 17 + + + 498, 17 + + + 228, 18 + + + 409, 17 + + + True + + + 108 + + + 6, 12 - - Add [VMess] server + + 952, 593 - - 355, 22 + + 4, 4, 4, 4 - - Add [Shadowsocks] server + + MainForm - - 355, 22 + + v2rayN - - Add [Socks] server + + v2rayN.Forms.BaseForm, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null - - 355, 22 + + bgwScan - - Add a custom configuration server - - - 355, 22 - - - Import bulk URL from clipboard (Ctrl+V) - - - 355, 22 - - - Scan QR code on the screen (Ctrl+S) - - - 352, 6 - - - 355, 22 - - - Remove selected servers (Delete) - - - 355, 22 - - - Remove duplicate servers - - - 355, 22 - - - Clone selected server - - - 355, 22 - - - Set as active server (Enter) - - - 352, 6 - - - 355, 22 - - - Move to top (T) - - - 355, 22 - - - Up (U) - - - 355, 22 - - - Down (D) - - - 355, 22 - - - Move to bottom (B) - - - 355, 22 - - - Select All (Ctrl+A) - - - 352, 6 - - - 355, 22 - - - Test servers ping (Ctrl+P) - - - 355, 22 - - - Test servers with tcping (Ctrl+O) - - - 355, 22 - - - Test servers real delay (Ctrl+R) - - - 355, 22 - - - Test servers download speed (Ctrl+T) - - - 355, 22 - - - Test current service status - - - 352, 6 - - - 355, 22 - - - Export selected server for client configuration - - - 355, 22 - - - Export selected server for server configuration - - - 355, 22 - - - Export share URLs to clipboard (Ctrl+C) - - - 355, 22 - - - Export subscription (base64) share to clipboard - - - Magenta - - - 64, 53 - - - Servers - - - ImageAboveText - - - 356, 556 + + System.ComponentModel.BackgroundWorker, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 cmsLv + + 356, 556 + System.Windows.Forms.ContextMenuStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + NoControl + + + cmsMain + + + 265, 164 + + + System.Windows.Forms.ContextMenuStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + Fill + + + 0, 66 + + + groupBox1 + + + $this + + + 952, 351 + + + 0 + + + Servers list + + + System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 2 + + + Bottom + + + 0, 417 + + + groupBox2 + + + $this + + + 952, 176 + + + 3 + + + Informations + + + System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 3 + Fill @@ -328,36 +266,503 @@ 0, 0 - - 686, 331 - - - - 0 - lvServers - - v2rayN.Base.ListViewFlickerFree, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null - scMain.Panel1 + + 686, 331 + + + 0 + + + v2rayN.Base.ListViewFlickerFree, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + 0 - - scMain.Panel1 + + menuAddCustomServer - - System.Windows.Forms.SplitterPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 355, 22 - - scMain + + Add a custom configuration server - - 0 + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuAddServers + + + 355, 22 + + + Import bulk URL from clipboard (Ctrl+V) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuAddServers2 + + + 264, 22 + + + Import bulk URL from clipboard + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuAddShadowsocksServer + + + 355, 22 + + + Add [Shadowsocks] server + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuAddSocksServer + + + 355, 22 + + + Add [Socks] server + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuAddVmessServer + + + 355, 22 + + + Add [VMess] server + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuCopyPACUrl + + + 264, 22 + + + Copy local PAC URL + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuCopyServer + + + 355, 22 + + + Clone selected server + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuExit + + + 264, 22 + + + Exit + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuExport2ClientConfig + + + 355, 22 + + + Export selected server for client configuration + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuExport2ServerConfig + + + 355, 22 + + + Export selected server for server configuration + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuExport2ShareUrl + + + 355, 22 + + + Export share URLs to clipboard (Ctrl+C) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuExport2SubContent + + + 355, 22 + + + Export subscription (base64) share to clipboard + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuGlobal + + + 411, 22 + + + Open Http proxy and set the system proxy (global mode) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuGlobalPAC + + + 411, 22 + + + Open PAC and set the system proxy (PAC mode) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuKeep + + + 411, 22 + + + Only open Http proxy and clear the proxy settings + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuKeepNothing + + + 411, 22 + + + Only open Http proxy and do nothing + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuKeepPAC + + + 411, 22 + + + Only open PAC and clear the proxy settings + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuKeepPACNothing + + + 411, 22 + + + Only open PAC and do nothing + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuMoveBottom + + + 355, 22 + + + Move to bottom (B) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuMoveDown + + + 355, 22 + + + Down (D) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuMoveTop + + + 355, 22 + + + Move to top (T) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuMoveUp + + + 355, 22 + + + Up (U) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuNotEnabledHttp + + + 411, 22 + + + Not Enabled Http Proxy + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuPingServer + + + 355, 22 + + + Test servers ping (Ctrl+P) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuRealPingServer + + + 355, 22 + + + Test servers real delay (Ctrl+R) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuRemoveDuplicateServer + + + 355, 22 + + + Remove duplicate servers + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuRemoveServer + + + 355, 22 + + + Remove selected servers (Delete) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuScanScreen + + + 355, 22 + + + Scan QR code on the screen (Ctrl+S) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuScanScreen2 + + + 264, 22 + + + Scan QR code on the screen + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuSelectAll + + + 355, 22 + + + Select All (Ctrl+A) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuServers + + + 264, 22 + + + Server + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuSetDefaultServer + + + 355, 22 + + + Set as active server (Enter) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuSpeedServer + + + 355, 22 + + + Test servers download speed (Ctrl+T) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuSysAgentMode + + + 264, 22 + + + Http proxy + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuTcpingServer + + + 355, 22 + + + Test servers with tcping (Ctrl+O) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuUpdateSubscriptions + + + 264, 22 + + + Update subscriptions + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + notifyMain + + + v2rayN + + + System.Windows.Forms.NotifyIcon, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + True + + + Top + + + 0, 56 + + + panel1 + + + $this + + + 952, 10 + + + 2 + + + System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 4 Fill @@ -365,39 +770,63 @@ 0, 0 + + qrCodeControl + + + scMain.Panel2 + 256, 331 2 - - qrCodeControl - v2rayN.Forms.QRCodeControl, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null - - scMain.Panel2 - 0 + + Fill + + + 3, 17 + + + scMain + + + scMain.Panel1 + + + scMain + + + System.Windows.Forms.SplitterPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + scMain.Panel2 - - System.Windows.Forms.SplitterPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - scMain + + System.Windows.Forms.SplitterPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + 1 100 + + groupBox1 + 946, 331 @@ -407,248 +836,128 @@ 0 - - scMain - System.Windows.Forms.SplitContainer, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - groupBox1 - 0 - - 17, 17 - - - 137, 17 - - - NoControl + + 3, 151 - - 411, 22 + + ssMain - - Not Enabled Http Proxy - - - 411, 22 - - - Open Http proxy and set the system proxy (global mode) - - - 411, 22 - - - Open PAC and set the system proxy (PAC mode) - - - 411, 22 - - - Only open Http proxy and clear the proxy settings - - - 411, 22 - - - Only open PAC and clear the proxy settings - - - 411, 22 - - - Only open Http proxy and do nothing - - - 411, 22 - - - Only open PAC and do nothing - - - 264, 22 - - - Http proxy - - - 264, 22 - - - Server - - - 264, 22 - - - Import bulk URL from clipboard - - - 264, 22 - - - Scan QR code on the screen - - - 264, 22 - - - Copy local PAC URL - - - 264, 22 - - - Update subscriptions - - - 261, 6 - - - 264, 22 - - - Exit - - - 265, 164 - - - cmsMain - - - System.Windows.Forms.ContextMenuStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - v2rayN - - - True - - - 498, 17 - - - Fill - - - 0, 66 - - - 952, 351 - - - 0 - - - Servers list - - - groupBox1 - - - System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - $this - - - 2 - - - Fill - - - 3, 17 - - - 0 - - - True - - - Vertical - - - 946, 134 - - - 3 - - - txtMsgBox - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - + groupBox2 - + + 946, 22 + + 0 - - 228, 18 - - - 微软雅黑, 8pt + + statusStrip1 - - 52, 17 + + System.Windows.Forms.StatusStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - SOCKS5: - - - 0, 17 + + 1 微软雅黑, 8pt + + toolSslBlank1 + 195, 17 + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 微软雅黑, 8pt + + + toolSslBlank2 + + + 195, 17 + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 微软雅黑, 8pt + + + toolSslBlank3 + + + 195, 17 + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslBlank4 + + + 0, 17 + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslHttpPort + + + 0, 17 + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + 微软雅黑, 8pt + + toolSslHttpPortLab + 39, 17 HTTP: - + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslPacPort + + 0, 17 - - 微软雅黑, 8pt - - - 195, 17 + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 微软雅黑, 8pt + + toolSslPacPortLab + 33, 17 PAC: - - 0, 17 - - - 微软雅黑, 8pt - - - 195, 17 + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 False @@ -656,6 +965,9 @@ 微软雅黑, 8pt + + toolSslServerSpeed + No @@ -668,117 +980,337 @@ MiddleRight - + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslSocksPort + + 0, 17 - - 3, 151 + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 946, 22 + + 微软雅黑, 8pt - - 0 + + toolSslSocksPortLab - - statusStrip1 + + 52, 17 - - ssMain + + SOCKS5: - - System.Windows.Forms.StatusStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - groupBox2 + + toolStripSeparator1 - - 1 + + 352, 6 - - Bottom + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 0, 417 + + toolStripSeparator10 - - 952, 176 + + 6, 56 - - 3 + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - Informations + + toolStripSeparator11 - - groupBox2 + + 6, 56 - - System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - $this + + toolStripSeparator12 - - 3 + + 184, 6 - - Top + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 0, 56 + + toolStripSeparator13 - - 952, 10 + + 390, 6 - - 2 + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - panel1 + + toolStripSeparator2 - - System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 261, 6 - - $this + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 4 + + toolStripSeparator3 + + + 352, 6 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator4 - - 409, 17 - 6, 56 - - 125, 22 + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - Settings + + toolStripSeparator5 - - 125, 22 + + 6, 56 - - Updates + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - + + toolStripSeparator6 + + + 352, 6 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator7 + + + 6, 56 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator8 + + + 6, 56 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator9 + + + 352, 6 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbAbout + + + 187, 22 + + + v2rayN Project + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbCheckClearPACList + + + 393, 22 + + + Simplify PAC (need to set Core route) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + Magenta - - 99, 53 + + tsbCheckUpdate - - Subscriptions + + 128, 53 - + + Check for updates + + ImageAboveText + + System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbCheckUpdateCore + + + 393, 22 + + + Update v2rayCore + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbCheckUpdateN + + + 393, 22 + + + v2rayN (this software) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbCheckUpdatePACList + + + 393, 22 + + + Check for updated PAC (need the HTTP proxy are ON) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + + iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8 + YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAySURBVFhH7c6xDQAgCEVBRnVTHU2ZABuMxV3yOvJDAAA/ + GqfZVG6X8mg1dfUAAPBQxAZd0SJruVXHWwAAAABJRU5ErkJggg== + + + + Magenta + + + tsbClose + + + 52, 53 + + + Close + + + ImageAboveText + + + System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + Magenta + + + tsbHelp + + + 48, 53 + + + Help + + + ImageAboveText + + + System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbLanguageDef + + + 187, 22 + + + Language-[English] + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbLanguageZhHans + + + 187, 22 + + + 语言-[中文简体] + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + Magenta + + + tsbOptionSetting + + + 58, 53 + + + Settings + + + ImageAboveText + + + System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + Magenta + + + tsbPromotion + + + 89, 53 + + + Promotion + + + ImageAboveText + + + System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + Magenta + + tsbQRCodeSwitch + 45, 53 @@ -791,23 +1323,8 @@ ImageAboveText - - 6, 56 - - - Magenta - - - 58, 53 - - - Settings - - - ImageAboveText - - - 6, 56 + + System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -826,6 +1343,9 @@ Magenta + + tsbReload + 97, 53 @@ -835,665 +1355,145 @@ ImageAboveText - - 6, 56 + + System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 393, 22 - - - v2rayN (this software) - - - 393, 22 - - - Update v2rayCore - - - 393, 22 - - - Check for updated PAC (need the HTTP proxy are ON) - - - 390, 6 - - - 393, 22 - - - Simplify PAC (need to set Core route) - - + Magenta - - 128, 53 - - - Check for updates - - - ImageAboveText - - - 6, 56 - - - 187, 22 - - - v2rayN Project - - - 187, 22 - - - V2Ray Website - - - 184, 6 - - - 187, 22 - - - Language-[English] - - - 187, 22 - - - 语言-[中文简体] - - - Magenta - - - 48, 53 - - - Help - - - ImageAboveText - - - Magenta - - - 89, 53 - - - Promotion - - - ImageAboveText - - - 6, 56 - - - - iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8 - YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAySURBVFhH7c6xDQAgCEVBRnVTHU2ZABuMxV3yOvJDAAA/ - GqfZVG6X8mg1dfUAAPBQxAZd0SJruVXHWwAAAABJRU5ErkJggg== - - - - Magenta - - - 52, 53 - - - Close - - - ImageAboveText - - - 0, 0 - - - 952, 56 - - - 1 - - - tsMain - - - System.Windows.Forms.ToolStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - $this - - - 5 - - - True - - - 108 - - - 6, 12 - - - 952, 593 - - - 4, 4, 4, 4 - - - v2rayN - - - menuAddVmessServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuAddShadowsocksServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuAddSocksServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuAddCustomServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuAddServers - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuScanScreen - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator1 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuRemoveServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuRemoveDuplicateServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuCopyServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuSetDefaultServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator3 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuMoveTop - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuMoveUp - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuMoveDown - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuMoveBottom - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuSelectAll - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator9 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuPingServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuTcpingServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuRealPingServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuSpeedServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbTestMe - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator6 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuExport2ClientConfig - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuExport2ServerConfig - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuExport2ShareUrl - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuExport2SubContent - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - tsbServer + + 64, 53 + + + Servers + + + ImageAboveText + System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - notifyMain - - - System.Windows.Forms.NotifyIcon, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuSysAgentMode - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuNotEnabledHttp - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuGlobal - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuGlobalPAC - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuKeep - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuKeepPAC - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuKeepNothing - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuKeepPACNothing - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuServers - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuAddServers2 - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuScanScreen2 - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuCopyPACUrl - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuUpdateSubscriptions - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator2 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuExit - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - bgwScan - - - System.ComponentModel.BackgroundWorker, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslSocksPortLab - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslSocksPort - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslBlank1 - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslHttpPortLab - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslHttpPort - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslBlank2 - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslPacPortLab - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslPacPort - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslBlank3 - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslServerSpeed - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslBlank4 - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator4 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + Magenta tsbSub + + 99, 53 + + + Subscriptions + + + ImageAboveText + System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 tsbSubSetting + + 125, 22 + + + Settings + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 tsbSubUpdate + + 125, 22 + + + Updates + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tsbQRCodeSwitch + + tsbTestMe - - System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 355, 22 - - toolStripSeparator8 + + Test current service status - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbOptionSetting - - - System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator5 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbReload - - - System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator7 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbCheckUpdate - - - System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbCheckUpdateN - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbCheckUpdateCore - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbCheckUpdatePACList - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator13 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbCheckClearPACList - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator10 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbHelp - - - System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbAbout - - + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 tsbV2rayWebsite + + 187, 22 + + + V2Ray Website + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - toolStripSeparator12 + + 0, 0 - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + tsMain - - tsbLanguageDef + + $this - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 952, 56 - - tsbLanguageZhHans + + 1 - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.ToolStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tsbPromotion + + 5 - - System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + Fill - - toolStripSeparator11 + + 3, 17 - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 0 - - tsbClose + + True - - System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + txtMsgBox - - MainForm + + groupBox2 - - v2rayN.Forms.BaseForm, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + + Vertical + + + 946, 134 + + + 3 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 \ No newline at end of file diff --git a/v2rayN/v2rayN/Forms/MainForm.zh-Hans.resx b/v2rayN/v2rayN/Forms/MainForm.zh-Hans.resx index 21164412..3268c19e 100644 --- a/v2rayN/v2rayN/Forms/MainForm.zh-Hans.resx +++ b/v2rayN/v2rayN/Forms/MainForm.zh-Hans.resx @@ -118,23 +118,34 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 300, 22 + + 301, 534 - - 添加[VMess]服务器 + + 196, 164 - - 300, 22 + + 服务器列表 - - 添加[Shadowsocks]服务器 + + 信息 - - 300, 22 - - - 添加[Socks]服务器 + + + AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w + LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkMAwAAAFFTeXN0 + ZW0uRHJhd2luZywgVmVyc2lvbj00LjAuMC4wLCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2Vu + PWIwM2Y1ZjdmMTFkNTBhM2EFAQAAACFTeXN0ZW0uV2luZG93cy5Gb3Jtcy5MaXN0Vmlld0l0ZW0HAAAA + BFRleHQKSW1hZ2VJbmRleAlCYWNrQ29sb3IHQ2hlY2tlZARGb250CUZvcmVDb2xvchdVc2VJdGVtU3R5 + bGVGb3JTdWJJdGVtcwEABAAEBAAIFFN5c3RlbS5EcmF3aW5nLkNvbG9yAwAAAAETU3lzdGVtLkRyYXdp + bmcuRm9udAMAAAAUU3lzdGVtLkRyYXdpbmcuQ29sb3IDAAAAAQIAAAAGBAAAAAD/////Bfv///8UU3lz + dGVtLkRyYXdpbmcuQ29sb3IEAAAABG5hbWUFdmFsdWUKa25vd25Db2xvcgVzdGF0ZQEAAAAJBwcDAAAA + CgAAAAAAAAAAGAABAAAJBgAAAAH5////+////woAAAAAAAAAABoAAQABBQYAAAATU3lzdGVtLkRyYXdp + bmcuRm9udAQAAAAETmFtZQRTaXplBVN0eWxlBFVuaXQBAAQECxhTeXN0ZW0uRHJhd2luZy5Gb250U3R5 + bGUDAAAAG1N5c3RlbS5EcmF3aW5nLkdyYXBoaWNzVW5pdAMAAAADAAAABggAAAAG5a6L5L2TAAAQQQX3 + ////GFN5c3RlbS5EcmF3aW5nLkZvbnRTdHlsZQEAAAAHdmFsdWVfXwAIAwAAAAAAAAAF9v///xtTeXN0 + ZW0uRHJhd2luZy5HcmFwaGljc1VuaXQBAAAAB3ZhbHVlX18ACAMAAAADAAAACw== + 300, 22 @@ -148,26 +159,35 @@ 从剪贴板导入批量URL (Ctrl+V) - + + 195, 22 + + + 从剪贴板导入批量URL + + 300, 22 - - 扫描屏幕上的二维码 (Ctrl+S) + + 添加[Shadowsocks]服务器 - - 297, 6 - - + 300, 22 - - 移除所选服务器(多选) (Delete) + + 添加[Socks]服务器 - + 300, 22 - - 移除重复的服务器 + + 添加[VMess]服务器 + + + 195, 22 + + + 复制本地PAC网址 300, 22 @@ -175,74 +195,11 @@ 克隆所选服务器 - - 300, 22 + + 195, 22 - - 设为活动服务器 (Enter) - - - 297, 6 - - - 300, 22 - - - 上移至顶 (T) - - - 300, 22 - - - 上移 (U) - - - 300, 22 - - - 下移 (D) - - - 300, 22 - - - 下移至底 (B) - - - 300, 22 - - - 全选 (Ctrl+A) - - - 297, 6 - - - 300, 22 - - - 测试服务器延迟Ping(多选) (Ctrl+P) - - - 300, 22 - - - 测试服务器延迟Tcping(多选) (Ctrl+O) - - - 300, 22 - - - 测试服务器真连接延迟(多选) (Ctrl+R) - - - 300, 22 - - - 测试服务器速度(多选) (Ctrl+T) - - - 297, 6 + + 退出 300, 22 @@ -268,38 +225,6 @@ 批量导出订阅内容至剪贴板(多选) - - 73, 53 - - - 服务器 - - - 301, 534 - - - - AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w - LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkMAwAAAFFTeXN0 - ZW0uRHJhd2luZywgVmVyc2lvbj00LjAuMC4wLCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2Vu - PWIwM2Y1ZjdmMTFkNTBhM2EFAQAAACFTeXN0ZW0uV2luZG93cy5Gb3Jtcy5MaXN0Vmlld0l0ZW0HAAAA - BFRleHQKSW1hZ2VJbmRleAlCYWNrQ29sb3IHQ2hlY2tlZARGb250CUZvcmVDb2xvchdVc2VJdGVtU3R5 - bGVGb3JTdWJJdGVtcwEABAAEBAAIFFN5c3RlbS5EcmF3aW5nLkNvbG9yAwAAAAETU3lzdGVtLkRyYXdp - bmcuRm9udAMAAAAUU3lzdGVtLkRyYXdpbmcuQ29sb3IDAAAAAQIAAAAGBAAAAAD/////Bfv///8UU3lz - dGVtLkRyYXdpbmcuQ29sb3IEAAAABG5hbWUFdmFsdWUKa25vd25Db2xvcgVzdGF0ZQEAAAAJBwcDAAAA - CgAAAAAAAAAAGAABAAAJBgAAAAH5////+////woAAAAAAAAAABoAAQABBQYAAAATU3lzdGVtLkRyYXdp - bmcuRm9udAQAAAAETmFtZQRTaXplBVN0eWxlBFVuaXQBAAQECxhTeXN0ZW0uRHJhd2luZy5Gb250U3R5 - bGUDAAAAG1N5c3RlbS5EcmF3aW5nLkdyYXBoaWNzVW5pdAMAAAADAAAABggAAAAG5a6L5L2TAAAQQQX3 - ////GFN5c3RlbS5EcmF3aW5nLkZvbnRTdHlsZQEAAAAHdmFsdWVfXwAIAwAAAAAAAAAF9v///xtTeXN0 - ZW0uRHJhd2luZy5HcmFwaGljc1VuaXQBAAAAB3ZhbHVlX18ACAMAAAADAAAACw== - - - - 316, 22 - - - 关闭Http代理 - 316, 22 @@ -318,41 +243,83 @@ 仅开启Http代理,并清除系统代理 - - 316, 22 - - - 仅开启PAC,并清除系统代理 - 316, 22 仅开启Http代理,不改变系统代理 + + 316, 22 + + + 仅开启PAC,并清除系统代理 + 316, 22 仅开启PAC,不改变系统代理 - - 195, 22 + + 300, 22 - - Http代理 + + 下移至底 (B) - - 195, 22 + + 300, 22 - - 服务器 + + 下移 (D) - - 195, 22 + + 300, 22 - - 从剪贴板导入批量URL + + 上移至顶 (T) + + + 300, 22 + + + 上移 (U) + + + 316, 22 + + + 关闭Http代理 + + + 300, 22 + + + 测试服务器延迟Ping(多选) (Ctrl+P) + + + 300, 22 + + + 测试服务器真连接延迟(多选) (Ctrl+R) + + + 300, 22 + + + 移除重复的服务器 + + + 300, 22 + + + 移除所选服务器(多选) (Delete) + + + 300, 22 + + + 扫描屏幕上的二维码 (Ctrl+S) 195, 22 @@ -360,11 +327,41 @@ 扫描屏幕上的二维码 - + + 300, 22 + + + 全选 (Ctrl+A) + + 195, 22 - - 复制本地PAC网址 + + 服务器 + + + 300, 22 + + + 设为活动服务器 (Enter) + + + 300, 22 + + + 测试服务器速度(多选) (Ctrl+T) + + + 195, 22 + + + Http代理 + + + 300, 22 + + + 测试服务器延迟Tcping(多选) (Ctrl+O) 195, 22 @@ -372,44 +369,78 @@ 更新订阅 - - 192, 6 - - - 195, 22 - - - 退出 - - - 196, 164 - - - 服务器列表 - 网速显示未启用 - - 信息 + + 297, 6 - - 124, 22 + + 220, 6 - - 订阅设置 + + 192, 6 - - 124, 22 + + 297, 6 - - 更新订阅 + + 297, 6 - - 61, 53 + + 297, 6 - - 订阅 + + v2rayN 项目 + + + 223, 22 + + + 简化PAC (请设置Core路由) + + + 85, 53 + + + 检查更新 + + + 223, 22 + + + v2rayCore + + + 223, 22 + + + v2rayN + + + 223, 22 + + + PAC + + + + iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO + wwAADsMBx2+oZAAAADJJREFUWEftzrENACAIRUFGdVMdTZkAG4zFXfI68kMAAD8ap9lUbpfyaDV19QAA + 8FDEBl3RImu5VcdbAAAAAElFTkSuQmCC + + + + 76, 53 + + + 关闭窗口 + + + 69, 53 + + + 帮助 76, 53 @@ -417,17 +448,26 @@ 参数设置 + + 68, 53 + + + 推广 + + + 分享 + 148, 22 重启服务 - - 148, 22 + + 73, 53 - - 测试当前服务状态 + + 服务器 @@ -446,71 +486,31 @@ 当前服务 - - 223, 22 + + 61, 53 - - v2rayN + + 订阅 - - 223, 22 + + 124, 22 - - v2rayCore + + 订阅设置 - - 223, 22 + + 124, 22 - - PAC + + 更新订阅 - - 220, 6 + + 148, 22 - - 223, 22 - - - 简化PAC (请设置Core路由) - - - 85, 53 - - - 检查更新 - - - v2rayN 项目 + + 测试当前服务状态 V2Ray 官网 - - 69, 53 - - - 帮助 - - - 68, 53 - - - 推广 - - - - iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO - wwAADsMBx2+oZAAAADJJREFUWEftzrENACAIRUFGdVMdTZkAG4zFXfI68kMAAD8ap9lUbpfyaDV19QAA - 8FDEBl3RImu5VcdbAAAAAElFTkSuQmCC - - - - 76, 53 - - - 关闭窗口 - - - 分享 - \ No newline at end of file diff --git a/v2rayN/v2rayN/Forms/QRCodeControl.resx b/v2rayN/v2rayN/Forms/QRCodeControl.resx index a6ceff05..2f13a849 100644 --- a/v2rayN/v2rayN/Forms/QRCodeControl.resx +++ b/v2rayN/v2rayN/Forms/QRCodeControl.resx @@ -118,34 +118,22 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - Bottom - - - 0, 371 - - + True + + + 6, 12 - - 356, 70 + + QRCodeControl - - 0 + + 356, 441 - - txtUrl - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - $this - - - 1 + + System.Windows.Forms.UserControl, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 Fill @@ -153,6 +141,12 @@ 0, 0 + + picQRCode + + + $this + 356, 371 @@ -162,31 +156,37 @@ 24 - - picQRCode - System.Windows.Forms.PictureBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - $this - 0 - + + Bottom + + + 0, 371 + + True - - - 6, 12 - - 356, 441 + + txtUrl - - QRCodeControl + + $this - - System.Windows.Forms.UserControl, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 356, 70 + + + 0 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 1 \ No newline at end of file diff --git a/v2rayN/v2rayN/Properties/Resources.Designer.cs b/v2rayN/v2rayN/Properties/Resources.Designer.cs index f21638d7..1bffa5a1 100644 --- a/v2rayN/v2rayN/Properties/Resources.Designer.cs +++ b/v2rayN/v2rayN/Properties/Resources.Designer.cs @@ -19,7 +19,7 @@ namespace v2rayN.Properties { // 类通过类似于 ResGen 或 Visual Studio 的工具自动生成的。 // 若要添加或移除成员,请编辑 .ResX 文件,然后重新运行 ResGen // (以 /str 作为命令选项),或重新生成 VS 项目。 - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "15.0.0.0")] + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "16.0.0.0")] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] internal class Resources { diff --git a/v2rayN/v2rayN/Properties/Resources.resx b/v2rayN/v2rayN/Properties/Resources.resx index 706454a0..ebe3751a 100644 --- a/v2rayN/v2rayN/Properties/Resources.resx +++ b/v2rayN/v2rayN/Properties/Resources.resx @@ -118,55 +118,55 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - ..\resources\privoxy.exe.gz;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - ..\Resources\about.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\Resources\option.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\Resources\restart.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\resources\sysproxy.exe.gz;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - ..\resources\sub.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\Resources\server.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\Resources\notify.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\resources\checkupdate.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\resources\promotion.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\resources\sysproxy64.exe.gz;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - ..\resources\privoxy_conf.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;gb2312 - - - ..\Resources\minimize.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\Resources\pac.txt.gz;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - ..\resources\help.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - ..\Resources\abp.js.gz;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + ..\resources\checkupdate.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\resources\help.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\minimize.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\notify.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\option.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\pac.txt.gz;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + ..\resources\privoxy_conf.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;gb2312 + + + ..\resources\privoxy.exe.gz;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + ..\resources\promotion.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\restart.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\server.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\resources\share.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\resources\sub.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\resources\sysproxy64.exe.gz;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + ..\resources\sysproxy.exe.gz;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + \ No newline at end of file From 2708ff7c1a6ceed94c85e469ce1c3aa9cfacb8f1 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Fri, 17 Apr 2020 08:53:04 +0800 Subject: [PATCH 03/45] Showing latency on status bar --- v2rayN/v2rayN/Forms/MainForm.Designer.cs | 37 ++++++++++------ v2rayN/v2rayN/Forms/MainForm.cs | 53 ++++++++++++++++++++--- v2rayN/v2rayN/Forms/MainForm.resx | 53 ++++++++++++++++------- v2rayN/v2rayN/Handler/SpeedtestHandler.cs | 31 ++++++------- 4 files changed, 120 insertions(+), 54 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.Designer.cs b/v2rayN/v2rayN/Forms/MainForm.Designer.cs index 4e516b81..0511b147 100644 --- a/v2rayN/v2rayN/Forms/MainForm.Designer.cs +++ b/v2rayN/v2rayN/Forms/MainForm.Designer.cs @@ -55,14 +55,14 @@ this.menuTcpingServer = new System.Windows.Forms.ToolStripMenuItem(); this.menuRealPingServer = new System.Windows.Forms.ToolStripMenuItem(); this.menuSpeedServer = new System.Windows.Forms.ToolStripMenuItem(); - this.tsbTestMe = new System.Windows.Forms.ToolStripMenuItem(); + this.menuTestMe = new System.Windows.Forms.ToolStripMenuItem(); this.toolStripSeparator6 = new System.Windows.Forms.ToolStripSeparator(); this.menuExport2ClientConfig = new System.Windows.Forms.ToolStripMenuItem(); this.menuExport2ServerConfig = new System.Windows.Forms.ToolStripMenuItem(); this.menuExport2ShareUrl = new System.Windows.Forms.ToolStripMenuItem(); this.menuExport2SubContent = new System.Windows.Forms.ToolStripMenuItem(); - this.tsbServer = new System.Windows.Forms.ToolStripDropDownButton(); this.qrCodeControl = new v2rayN.Forms.QRCodeControl(); + this.tsbServer = new System.Windows.Forms.ToolStripDropDownButton(); this.notifyMain = new System.Windows.Forms.NotifyIcon(this.components); this.cmsMain = new System.Windows.Forms.ContextMenuStrip(this.components); this.menuSysAgentMode = new System.Windows.Forms.ToolStripMenuItem(); @@ -94,6 +94,7 @@ this.toolSslPacPortLab = new System.Windows.Forms.ToolStripStatusLabel(); this.toolSslPacPort = new System.Windows.Forms.ToolStripStatusLabel(); this.toolSslBlank3 = new System.Windows.Forms.ToolStripStatusLabel(); + this.toolSslServerLatency = new System.Windows.Forms.ToolStripStatusLabel(); this.toolSslServerSpeed = new System.Windows.Forms.ToolStripStatusLabel(); this.toolSslBlank4 = new System.Windows.Forms.ToolStripStatusLabel(); this.panel1 = new System.Windows.Forms.Panel(); @@ -196,7 +197,7 @@ this.menuTcpingServer, this.menuRealPingServer, this.menuSpeedServer, - this.tsbTestMe, + this.menuTestMe, this.toolStripSeparator6, this.menuExport2ClientConfig, this.menuExport2ServerConfig, @@ -335,11 +336,11 @@ resources.ApplyResources(this.menuSpeedServer, "menuSpeedServer"); this.menuSpeedServer.Click += new System.EventHandler(this.menuSpeedServer_Click); // - // tsbTestMe + // menuTestMe // - this.tsbTestMe.Name = "tsbTestMe"; - resources.ApplyResources(this.tsbTestMe, "tsbTestMe"); - this.tsbTestMe.Click += new System.EventHandler(this.tsbTestMe_Click); + this.menuTestMe.Name = "menuTestMe"; + resources.ApplyResources(this.menuTestMe, "menuTestMe"); + this.menuTestMe.Click += new System.EventHandler(this.menuTestMe_Click); // // toolStripSeparator6 // @@ -370,6 +371,11 @@ resources.ApplyResources(this.menuExport2SubContent, "menuExport2SubContent"); this.menuExport2SubContent.Click += new System.EventHandler(this.menuExport2SubContent_Click); // + // qrCodeControl + // + resources.ApplyResources(this.qrCodeControl, "qrCodeControl"); + this.qrCodeControl.Name = "qrCodeControl"; + // // tsbServer // this.tsbServer.DropDown = this.cmsLv; @@ -377,11 +383,6 @@ resources.ApplyResources(this.tsbServer, "tsbServer"); this.tsbServer.Name = "tsbServer"; // - // qrCodeControl - // - resources.ApplyResources(this.qrCodeControl, "qrCodeControl"); - this.qrCodeControl.Name = "qrCodeControl"; - // // notifyMain // this.notifyMain.ContextMenuStrip = this.cmsMain; @@ -543,6 +544,7 @@ this.toolSslPacPortLab, this.toolSslPacPort, this.toolSslBlank3, + this.toolSslServerLatency, this.toolSslServerSpeed, this.toolSslBlank4}); resources.ApplyResources(this.ssMain, "ssMain"); @@ -597,11 +599,19 @@ this.toolSslBlank3.Name = "toolSslBlank3"; this.toolSslBlank3.Spring = true; // + // toolSslServerLatency + // + resources.ApplyResources(this.toolSslServerLatency, "toolSslServerLatency"); + this.toolSslServerLatency.Name = "toolSslServerLatency"; + this.toolSslServerLatency.Spring = true; + this.toolSslServerLatency.Click += new System.EventHandler(this.toolSslServerLatency_Click); + // // toolSslServerSpeed // resources.ApplyResources(this.toolSslServerSpeed, "toolSslServerSpeed"); this.toolSslServerSpeed.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; this.toolSslServerSpeed.Name = "toolSslServerSpeed"; + this.toolSslServerSpeed.Click += new System.EventHandler(this.toolSslServerSpeed_Click); // // toolSslBlank4 // @@ -932,9 +942,10 @@ private System.Windows.Forms.ToolStripMenuItem tsbV2rayWebsite; private System.Windows.Forms.ToolStripMenuItem menuKeepNothing; private System.Windows.Forms.ToolStripMenuItem menuKeepPACNothing; - private System.Windows.Forms.ToolStripMenuItem tsbTestMe; + private System.Windows.Forms.ToolStripMenuItem menuTestMe; private System.Windows.Forms.ToolStripButton tsbReload; private System.Windows.Forms.ToolStripButton tsbQRCodeSwitch; + private System.Windows.Forms.ToolStripStatusLabel toolSslServerLatency; } } diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index b0d906ea..15ca5b08 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -11,6 +11,7 @@ using v2rayN.Tool; using System.Diagnostics; using System.Drawing; using System.Net; +using System.Threading.Tasks; namespace v2rayN.Forms { @@ -379,8 +380,23 @@ namespace v2rayN.Forms #endregion - #region v2ray 操作 + public static Task autoLatencyRefreshTask; + private void autoLatencyRefresh() + { + if (config.listenerType != ListenerType.noHttpProxy) + { + if (autoLatencyRefreshTask == null || autoLatencyRefreshTask.IsCompleted) + { + autoLatencyRefreshTask = Task.Run(async delegate + { + await Task.Delay(2000); + toolSslServerLatencyRefresh(); + }); + } + } + } + #region v2ray 操作 /// /// 载入V2ray /// @@ -400,6 +416,8 @@ namespace v2rayN.Forms ChangePACButtonStatus(config.listenerType); tsbReload.Enabled = true; + + autoLatencyRefresh(); } /// @@ -674,15 +692,15 @@ namespace v2rayN.Forms SpeedtestHandler statistics = new SpeedtestHandler(ref config, ref v2rayHandler, lvSelecteds, actionType, UpdateSpeedtestHandler); } - private void tsbTestMe_Click(object sender, EventArgs e) + private async void menuTestMe_Click(object sender, EventArgs e) { - string result = httpProxyTest() + "ms"; + string result = await httpProxyTest() + "ms"; AppendText(false, string.Format(UIRes.I18N("TestMeOutput"), result)); } - private int httpProxyTest() + private async Task httpProxyTest() { SpeedtestHandler statistics = new SpeedtestHandler(ref config, ref v2rayHandler, lvSelecteds, "", UpdateSpeedtestHandler); - return statistics.RunAvailabilityCheck(); + return await Task.Run(() => statistics.RunAvailabilityCheck()); } private void menuExport2ClientConfig_Click(object sender, EventArgs e) @@ -783,6 +801,7 @@ namespace v2rayN.Forms //刷新 RefreshServers(); LoadV2ray(); + toolSslServerLatencySet(); } return 0; } @@ -1220,11 +1239,11 @@ namespace v2rayN.Forms #region CheckUpdate - private void askToDownload(DownloadHandle downloadHandle, string url) + private async void askToDownload(DownloadHandle downloadHandle, string url) { if (UI.ShowYesNo(string.Format(UIRes.I18N("DownloadYesNo"), url)) == DialogResult.Yes) { - if (httpProxyTest() > 0) + if (await httpProxyTest() > 0) { int httpPort = config.GetLocalPort(Global.InboundHttp); WebProxy webProxy = new WebProxy(Global.Loopback, httpPort); @@ -1566,5 +1585,25 @@ namespace v2rayN.Forms #endregion + + private async void toolSslServerLatencyRefresh() + { + toolSslServerLatencySet("Measuring..."); + string result = await httpProxyTest() + "ms"; + toolSslServerLatencySet(result); + } + private void toolSslServerLatencySet(string text = "") + { + toolSslServerLatency.Text = "Latency: " + text; + } + private void toolSslServerLatency_Click(object sender, EventArgs e) + { + toolSslServerLatencyRefresh(); + } + + private void toolSslServerSpeed_Click(object sender, EventArgs e) + { + //toolSslServerLatencyRefresh(); + } } } diff --git a/v2rayN/v2rayN/Forms/MainForm.resx b/v2rayN/v2rayN/Forms/MainForm.resx index 28fe8826..62f3cdd2 100644 --- a/v2rayN/v2rayN/Forms/MainForm.resx +++ b/v2rayN/v2rayN/Forms/MainForm.resx @@ -716,6 +716,18 @@ System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + menuTestMe + + + 355, 22 + + + Test current service status + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + menuUpdateSubscriptions @@ -873,7 +885,7 @@ toolSslBlank1 - 195, 17 + 152, 17 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -885,7 +897,7 @@ toolSslBlank2 - 195, 17 + 152, 17 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -897,7 +909,7 @@ toolSslBlank3 - 195, 17 + 152, 17 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -959,6 +971,27 @@ System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + False + + + toolSslServerLatency + + + 144, 17 + + + Latency: + + + MiddleLeft + + + The http proxy's latency time. + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + False @@ -972,7 +1005,7 @@ No - 220, 17 + 200, 17 SPEED Disabled @@ -1418,18 +1451,6 @@ System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tsbTestMe - - - 355, 22 - - - Test current service status - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - tsbV2rayWebsite diff --git a/v2rayN/v2rayN/Handler/SpeedtestHandler.cs b/v2rayN/v2rayN/Handler/SpeedtestHandler.cs index 303034b9..519b51e2 100644 --- a/v2rayN/v2rayN/Handler/SpeedtestHandler.cs +++ b/v2rayN/v2rayN/Handler/SpeedtestHandler.cs @@ -145,29 +145,24 @@ namespace v2rayN.Handler } } - public int RunAvailabilityCheck() // alias: isLive + public async Task RunAvailabilityCheck() // alias: isLive { try { int httpPort = _config.GetLocalPort(Global.InboundHttp); - - Task t = Task.Run(() => + try { - try - { - WebProxy webProxy = new WebProxy(Global.Loopback, httpPort); - int responseTime = -1; - string status = GetRealPingTime(Global.AvailabilityTestUrl, webProxy, out responseTime); - bool noError = Utils.IsNullOrEmpty(status); - return noError ? responseTime : -1; - } - catch (Exception ex) - { - Utils.SaveLog(ex.Message, ex); - return -1; - } - }); - return t.Result; + WebProxy webProxy = new WebProxy(Global.Loopback, httpPort); + int responseTime = -1; + string status = GetRealPingTime(Global.AvailabilityTestUrl, webProxy, out responseTime); + bool noError = Utils.IsNullOrEmpty(status); + return noError ? responseTime : -1; + } + catch (Exception ex) + { + Utils.SaveLog(ex.Message, ex); + return -1; + } } catch (Exception ex) { From c837ba5482235de8fb1f8aa723bcfd271d325d17 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Fri, 17 Apr 2020 12:54:56 +0800 Subject: [PATCH 04/45] Showing routingMode on status bar --- v2rayN/v2rayN/Forms/MainForm.Designer.cs | 35 +- v2rayN/v2rayN/Forms/MainForm.cs | 31 +- v2rayN/v2rayN/Forms/MainForm.resx | 2226 +++++++++-------- v2rayN/v2rayN/Forms/MainForm.zh-Hans.resx | 12 + .../Forms/OptionSettingForm.Designer.cs | 166 +- v2rayN/v2rayN/Forms/OptionSettingForm.cs | 21 +- v2rayN/v2rayN/Forms/OptionSettingForm.resx | 1598 +++++++++++- .../Forms/OptionSettingForm.zh-Hans.resx | 24 +- v2rayN/v2rayN/Handler/ConfigHandler.cs | 4 - v2rayN/v2rayN/Handler/SpeedtestHandler.cs | 2 +- v2rayN/v2rayN/Handler/V2rayConfigHandler.cs | 8 +- v2rayN/v2rayN/Mode/Config.cs | 2 +- v2rayN/v2rayN/Resx/ResUI.Designer.cs | 54 + v2rayN/v2rayN/Resx/ResUI.resx | 18 + v2rayN/v2rayN/Resx/ResUI.zh-Hans.resx | 18 + 15 files changed, 2935 insertions(+), 1284 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.Designer.cs b/v2rayN/v2rayN/Forms/MainForm.Designer.cs index 0511b147..7e1faaf3 100644 --- a/v2rayN/v2rayN/Forms/MainForm.Designer.cs +++ b/v2rayN/v2rayN/Forms/MainForm.Designer.cs @@ -61,8 +61,8 @@ this.menuExport2ServerConfig = new System.Windows.Forms.ToolStripMenuItem(); this.menuExport2ShareUrl = new System.Windows.Forms.ToolStripMenuItem(); this.menuExport2SubContent = new System.Windows.Forms.ToolStripMenuItem(); - this.qrCodeControl = new v2rayN.Forms.QRCodeControl(); this.tsbServer = new System.Windows.Forms.ToolStripDropDownButton(); + this.qrCodeControl = new v2rayN.Forms.QRCodeControl(); this.notifyMain = new System.Windows.Forms.NotifyIcon(this.components); this.cmsMain = new System.Windows.Forms.ContextMenuStrip(this.components); this.menuSysAgentMode = new System.Windows.Forms.ToolStripMenuItem(); @@ -94,6 +94,7 @@ this.toolSslPacPortLab = new System.Windows.Forms.ToolStripStatusLabel(); this.toolSslPacPort = new System.Windows.Forms.ToolStripStatusLabel(); this.toolSslBlank3 = new System.Windows.Forms.ToolStripStatusLabel(); + this.toolSslRouting = new System.Windows.Forms.ToolStripStatusLabel(); this.toolSslServerLatency = new System.Windows.Forms.ToolStripStatusLabel(); this.toolSslServerSpeed = new System.Windows.Forms.ToolStripStatusLabel(); this.toolSslBlank4 = new System.Windows.Forms.ToolStripStatusLabel(); @@ -371,11 +372,6 @@ resources.ApplyResources(this.menuExport2SubContent, "menuExport2SubContent"); this.menuExport2SubContent.Click += new System.EventHandler(this.menuExport2SubContent_Click); // - // qrCodeControl - // - resources.ApplyResources(this.qrCodeControl, "qrCodeControl"); - this.qrCodeControl.Name = "qrCodeControl"; - // // tsbServer // this.tsbServer.DropDown = this.cmsLv; @@ -383,6 +379,11 @@ resources.ApplyResources(this.tsbServer, "tsbServer"); this.tsbServer.Name = "tsbServer"; // + // qrCodeControl + // + resources.ApplyResources(this.qrCodeControl, "qrCodeControl"); + this.qrCodeControl.Name = "qrCodeControl"; + // // notifyMain // this.notifyMain.ContextMenuStrip = this.cmsMain; @@ -544,6 +545,7 @@ this.toolSslPacPortLab, this.toolSslPacPort, this.toolSslBlank3, + this.toolSslRouting, this.toolSslServerLatency, this.toolSslServerSpeed, this.toolSslBlank4}); @@ -563,6 +565,7 @@ // // toolSslBlank1 // + this.toolSslBlank1.AutoToolTip = true; resources.ApplyResources(this.toolSslBlank1, "toolSslBlank1"); this.toolSslBlank1.Name = "toolSslBlank1"; this.toolSslBlank1.Spring = true; @@ -579,6 +582,7 @@ // // toolSslBlank2 // + this.toolSslBlank2.AutoToolTip = true; resources.ApplyResources(this.toolSslBlank2, "toolSslBlank2"); this.toolSslBlank2.Name = "toolSslBlank2"; this.toolSslBlank2.Spring = true; @@ -595,21 +599,37 @@ // // toolSslBlank3 // + this.toolSslBlank3.AutoToolTip = true; resources.ApplyResources(this.toolSslBlank3, "toolSslBlank3"); this.toolSslBlank3.Name = "toolSslBlank3"; this.toolSslBlank3.Spring = true; // + // toolSslRouting + // + resources.ApplyResources(this.toolSslRouting, "toolSslRouting"); + this.toolSslRouting.AutoToolTip = true; + this.toolSslRouting.IsLink = true; + this.toolSslRouting.LinkBehavior = System.Windows.Forms.LinkBehavior.NeverUnderline; + this.toolSslRouting.LinkColor = System.Drawing.SystemColors.ControlText; + this.toolSslRouting.Margin = new System.Windows.Forms.Padding(0, 3, 8, 2); + this.toolSslRouting.Name = "toolSslRouting"; + this.toolSslRouting.Spring = true; + this.toolSslRouting.Click += new System.EventHandler(this.toolSslRouting_Click); + // // toolSslServerLatency // resources.ApplyResources(this.toolSslServerLatency, "toolSslServerLatency"); + this.toolSslServerLatency.IsLink = true; + this.toolSslServerLatency.LinkBehavior = System.Windows.Forms.LinkBehavior.NeverUnderline; + this.toolSslServerLatency.LinkColor = System.Drawing.SystemColors.ControlText; this.toolSslServerLatency.Name = "toolSslServerLatency"; this.toolSslServerLatency.Spring = true; this.toolSslServerLatency.Click += new System.EventHandler(this.toolSslServerLatency_Click); // // toolSslServerSpeed // - resources.ApplyResources(this.toolSslServerSpeed, "toolSslServerSpeed"); this.toolSslServerSpeed.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; + resources.ApplyResources(this.toolSslServerSpeed, "toolSslServerSpeed"); this.toolSslServerSpeed.Name = "toolSslServerSpeed"; this.toolSslServerSpeed.Click += new System.EventHandler(this.toolSslServerSpeed_Click); // @@ -946,6 +966,7 @@ private System.Windows.Forms.ToolStripButton tsbReload; private System.Windows.Forms.ToolStripButton tsbQRCodeSwitch; private System.Windows.Forms.ToolStripStatusLabel toolSslServerLatency; + private System.Windows.Forms.ToolStripStatusLabel toolSslRouting; } } diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 15ca5b08..dec787c1 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -368,6 +368,24 @@ namespace v2rayN.Forms } } + string routingStatus = ""; + switch (config.routingMode) + { + case 0: + routingStatus = UIRes.I18N("RoutingModeGlobal"); + break; + case 1: + routingStatus = UIRes.I18N("RoutingModeBypassLAN"); + break; + case 2: + routingStatus = UIRes.I18N("RoutingModeBypassCN"); + break; + case 3: + routingStatus = UIRes.I18N("RoutingModeBypassLANCN"); + break; + } + toolSslRouting.Text = routingStatus; + notifyMain.Icon = MainFormHandler.Instance.GetNotifyIcon(config, this.Icon); } private void ssMain_ItemClicked(object sender, ToolStripItemClickedEventArgs e) @@ -762,7 +780,9 @@ namespace v2rayN.Forms private void tsbOptionSetting_Click(object sender, EventArgs e) { - OptionSettingForm fm = new OptionSettingForm(); + string tab = ""; + if (sender == toolSslRouting) tab = "tabPreDefinedRules"; + OptionSettingForm fm = new OptionSettingForm(tab); if (fm.ShowDialog() == DialogResult.OK) { //刷新 @@ -1588,13 +1608,13 @@ namespace v2rayN.Forms private async void toolSslServerLatencyRefresh() { - toolSslServerLatencySet("Measuring..."); + toolSslServerLatencySet(UIRes.I18N("ServerLatencyChecking")); string result = await httpProxyTest() + "ms"; toolSslServerLatencySet(result); } private void toolSslServerLatencySet(string text = "") { - toolSslServerLatency.Text = "Latency: " + text; + toolSslServerLatency.Text = string.Format(UIRes.I18N("toolSslServerLatency"), text); } private void toolSslServerLatency_Click(object sender, EventArgs e) { @@ -1605,5 +1625,10 @@ namespace v2rayN.Forms { //toolSslServerLatencyRefresh(); } + + private void toolSslRouting_Click(object sender, EventArgs e) + { + tsbOptionSetting_Click(toolSslRouting, null); + } } } diff --git a/v2rayN/v2rayN/Forms/MainForm.resx b/v2rayN/v2rayN/Forms/MainForm.resx index 62f3cdd2..86cd8eef 100644 --- a/v2rayN/v2rayN/Forms/MainForm.resx +++ b/v2rayN/v2rayN/Forms/MainForm.resx @@ -118,131 +118,193 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + Fill + + + 3, 17 + 327, 17 - - - 17, 17 - - - 137, 17 - - - 498, 17 - - - 228, 18 - - - 409, 17 - - - True - - - 108 - - - 6, 12 + + 355, 22 - - 952, 593 + + Add [VMess] server - - 4, 4, 4, 4 + + 355, 22 - - MainForm + + Add [Shadowsocks] server - - v2rayN + + 355, 22 - - v2rayN.Forms.BaseForm, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + + Add [Socks] server - - bgwScan + + 355, 22 - - System.ComponentModel.BackgroundWorker, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + Add a custom configuration server - - cmsLv + + 355, 22 + + + Import bulk URL from clipboard (Ctrl+V) + + + 355, 22 + + + Scan QR code on the screen (Ctrl+S) + + + 352, 6 + + + 355, 22 + + + Remove selected servers (Delete) + + + 355, 22 + + + Remove duplicate servers + + + 355, 22 + + + Clone selected server + + + 355, 22 + + + Set as active server (Enter) + + + 352, 6 + + + 355, 22 + + + Move to top (T) + + + 355, 22 + + + Up (U) + + + 355, 22 + + + Down (D) + + + 355, 22 + + + Move to bottom (B) + + + 355, 22 + + + Select All (Ctrl+A) + + + 352, 6 + + + 355, 22 + + + Test servers ping (Ctrl+P) + + + 355, 22 + + + Test servers with tcping (Ctrl+O) + + + 355, 22 + + + Test servers real delay (Ctrl+R) + + + 355, 22 + + + Test servers download speed (Ctrl+T) + + + 355, 22 + + + Test current service status + + + 352, 6 + + + 355, 22 + + + Export selected server for client configuration + + + 355, 22 + + + Export selected server for server configuration + + + 355, 22 + + + Export share URLs to clipboard (Ctrl+C) + + + 355, 22 + + + Export subscription (base64) share to clipboard + + + Magenta + + + 64, 53 + + + Servers + + + ImageAboveText 356, 556 + + cmsLv + System.Windows.Forms.ContextMenuStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - NoControl - - - cmsMain - - - 265, 164 - - - System.Windows.Forms.ContextMenuStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - Fill - - - 0, 66 - - - groupBox1 - - - $this - - - 952, 351 - - - 0 - - - Servers list - - - System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 2 - - - Bottom - - - 0, 417 - - - groupBox2 - - - $this - - - 952, 176 - - - 3 - - - Informations - - - System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 3 - Fill @@ -266,515 +328,36 @@ 0, 0 - - lvServers - - - scMain.Panel1 - 686, 331 + 0 + + lvServers + v2rayN.Base.ListViewFlickerFree, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + + scMain.Panel1 + 0 - - menuAddCustomServer + + scMain.Panel1 - - 355, 22 + + System.Windows.Forms.SplitterPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - Add a custom configuration server + + scMain - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuAddServers - - - 355, 22 - - - Import bulk URL from clipboard (Ctrl+V) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuAddServers2 - - - 264, 22 - - - Import bulk URL from clipboard - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuAddShadowsocksServer - - - 355, 22 - - - Add [Shadowsocks] server - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuAddSocksServer - - - 355, 22 - - - Add [Socks] server - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuAddVmessServer - - - 355, 22 - - - Add [VMess] server - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuCopyPACUrl - - - 264, 22 - - - Copy local PAC URL - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuCopyServer - - - 355, 22 - - - Clone selected server - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuExit - - - 264, 22 - - - Exit - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuExport2ClientConfig - - - 355, 22 - - - Export selected server for client configuration - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuExport2ServerConfig - - - 355, 22 - - - Export selected server for server configuration - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuExport2ShareUrl - - - 355, 22 - - - Export share URLs to clipboard (Ctrl+C) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuExport2SubContent - - - 355, 22 - - - Export subscription (base64) share to clipboard - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuGlobal - - - 411, 22 - - - Open Http proxy and set the system proxy (global mode) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuGlobalPAC - - - 411, 22 - - - Open PAC and set the system proxy (PAC mode) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuKeep - - - 411, 22 - - - Only open Http proxy and clear the proxy settings - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuKeepNothing - - - 411, 22 - - - Only open Http proxy and do nothing - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuKeepPAC - - - 411, 22 - - - Only open PAC and clear the proxy settings - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuKeepPACNothing - - - 411, 22 - - - Only open PAC and do nothing - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuMoveBottom - - - 355, 22 - - - Move to bottom (B) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuMoveDown - - - 355, 22 - - - Down (D) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuMoveTop - - - 355, 22 - - - Move to top (T) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuMoveUp - - - 355, 22 - - - Up (U) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuNotEnabledHttp - - - 411, 22 - - - Not Enabled Http Proxy - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuPingServer - - - 355, 22 - - - Test servers ping (Ctrl+P) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuRealPingServer - - - 355, 22 - - - Test servers real delay (Ctrl+R) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuRemoveDuplicateServer - - - 355, 22 - - - Remove duplicate servers - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuRemoveServer - - - 355, 22 - - - Remove selected servers (Delete) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuScanScreen - - - 355, 22 - - - Scan QR code on the screen (Ctrl+S) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuScanScreen2 - - - 264, 22 - - - Scan QR code on the screen - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuSelectAll - - - 355, 22 - - - Select All (Ctrl+A) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuServers - - - 264, 22 - - - Server - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuSetDefaultServer - - - 355, 22 - - - Set as active server (Enter) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuSpeedServer - - - 355, 22 - - - Test servers download speed (Ctrl+T) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuSysAgentMode - - - 264, 22 - - - Http proxy - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuTcpingServer - - - 355, 22 - - - Test servers with tcping (Ctrl+O) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuTestMe - - - 355, 22 - - - Test current service status - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuUpdateSubscriptions - - - 264, 22 - - - Update subscriptions - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - notifyMain - - - v2rayN - - - System.Windows.Forms.NotifyIcon, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - True - - - Top - - - 0, 56 - - - panel1 - - - $this - - - 952, 10 - - - 2 - - - System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 4 + + 0 Fill @@ -782,63 +365,39 @@ 0, 0 - - qrCodeControl - - - scMain.Panel2 - 256, 331 2 + + qrCodeControl + v2rayN.Forms.QRCodeControl, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + + scMain.Panel2 + 0 - - Fill - - - 3, 17 - - - scMain - - - scMain.Panel1 - - - scMain - - - System.Windows.Forms.SplitterPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 0 - scMain.Panel2 - - scMain - System.Windows.Forms.SplitterPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + scMain + 1 100 - - groupBox1 - 946, 331 @@ -848,137 +407,263 @@ 0 + + scMain + System.Windows.Forms.SplitContainer, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + groupBox1 + 0 - - 3, 151 + + 17, 17 + + + 137, 17 + + + NoControl - - ssMain + + 265, 164 - - groupBox2 + + cmsMain - - 946, 22 + + System.Windows.Forms.ContextMenuStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - + + v2rayN + + + True + + + 264, 22 + + + Http proxy + + + 411, 22 + + + Not Enabled Http Proxy + + + 411, 22 + + + Open Http proxy and set the system proxy (global mode) + + + 411, 22 + + + Open PAC and set the system proxy (PAC mode) + + + 411, 22 + + + Only open Http proxy and clear the proxy settings + + + 411, 22 + + + Only open PAC and clear the proxy settings + + + 411, 22 + + + Only open Http proxy and do nothing + + + 411, 22 + + + Only open PAC and do nothing + + + 264, 22 + + + Server + + + 264, 22 + + + Import bulk URL from clipboard + + + 264, 22 + + + Scan QR code on the screen + + + 264, 22 + + + Copy local PAC URL + + + 264, 22 + + + Update subscriptions + + + 261, 6 + + + 264, 22 + + + Exit + + + 498, 17 + + + Fill + + + 0, 66 + + + 952, 351 + + 0 - - statusStrip1 + + Servers list - - System.Windows.Forms.StatusStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + groupBox1 - - 1 + + System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + $this + + + 2 + + + Fill + + + 3, 17 + + + 0 + + + True + + + Vertical + + + 946, 134 + + + 3 + + + txtMsgBox + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + groupBox2 + + + 0 + + + 228, 18 + + + 微软雅黑, 8pt + + + 52, 17 + + + SOCKS5: + + + 0, 17 微软雅黑, 8pt - - toolSslBlank1 - - 152, 17 - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 微软雅黑, 8pt - - - toolSslBlank2 - - - 152, 17 - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 微软雅黑, 8pt - - - toolSslBlank3 - - - 152, 17 - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslBlank4 - - - 0, 17 - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslHttpPort - - - 0, 17 - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + 137, 17 微软雅黑, 8pt - - toolSslHttpPortLab - 39, 17 HTTP: - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslPacPort - - + 0, 17 - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 微软雅黑, 8pt + + + 137, 17 微软雅黑, 8pt - - toolSslPacPortLab - 33, 17 PAC: - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 0, 17 + + + 微软雅黑, 8pt + + + 137, 17 + + + False + + + 129, 17 + + + Routing Mode False - - toolSslServerLatency - - 144, 17 + 137, 17 Latency: @@ -989,23 +674,14 @@ The http proxy's latency time. - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - False - 微软雅黑, 8pt - - toolSslServerSpeed - No - 200, 17 + 89, 17 SPEED Disabled @@ -1013,337 +689,138 @@ MiddleRight - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslSocksPort - - + 0, 17 - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 3, 151 - - 微软雅黑, 8pt + + 946, 22 - - toolSslSocksPortLab + + 0 - - 52, 17 + + statusStrip1 - - SOCKS5: + + ssMain - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.StatusStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - toolStripSeparator1 + + groupBox2 - - 352, 6 + + 1 - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + Bottom - - toolStripSeparator10 + + 0, 417 - - 6, 56 + + 952, 176 - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 3 - - toolStripSeparator11 + + Informations - - 6, 56 + + groupBox2 - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - toolStripSeparator12 + + $this - - 184, 6 + + 3 - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + Top - - toolStripSeparator13 + + 0, 56 - - 390, 6 + + 952, 10 - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 2 - - toolStripSeparator2 + + panel1 - - 261, 6 + + System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + $this - - toolStripSeparator3 + + 4 - - 352, 6 + + 409, 17 + + + 0, 0 - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 952, 56 - - toolStripSeparator4 + + 1 + + + tsMain + + + System.Windows.Forms.ToolStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + $this + + + 5 6, 56 - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator5 - - - 6, 56 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator6 - - - 352, 6 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator7 - - - 6, 56 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator8 - - - 6, 56 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator9 - - - 352, 6 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbAbout - - - 187, 22 - - - v2rayN Project - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbCheckClearPACList - - - 393, 22 - - - Simplify PAC (need to set Core route) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - + Magenta - - tsbCheckUpdate + + 99, 53 - - 128, 53 + + Subscriptions - - Check for updates - - + ImageAboveText - - System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 125, 22 - - tsbCheckUpdateCore - - - 393, 22 - - - Update v2rayCore - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbCheckUpdateN - - - 393, 22 - - - v2rayN (this software) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbCheckUpdatePACList - - - 393, 22 - - - Check for updated PAC (need the HTTP proxy are ON) - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - - iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8 - YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAySURBVFhH7c6xDQAgCEVBRnVTHU2ZABuMxV3yOvJDAAA/ - GqfZVG6X8mg1dfUAAPBQxAZd0SJruVXHWwAAAABJRU5ErkJggg== - - - - Magenta - - - tsbClose - - - 52, 53 - - - Close - - - ImageAboveText - - - System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - Magenta - - - tsbHelp - - - 48, 53 - - - Help - - - ImageAboveText - - - System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbLanguageDef - - - 187, 22 - - - Language-[English] - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbLanguageZhHans - - - 187, 22 - - - 语言-[中文简体] - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - Magenta - - - tsbOptionSetting - - - 58, 53 - - + Settings - - ImageAboveText + + 125, 22 - - System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - Magenta - - - tsbPromotion - - - 89, 53 - - - Promotion - - - ImageAboveText - - - System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + Updates Magenta - - tsbQRCodeSwitch - 45, 53 @@ -1356,8 +833,23 @@ ImageAboveText - - System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 6, 56 + + + Magenta + + + 58, 53 + + + Settings + + + ImageAboveText + + + 6, 56 @@ -1376,9 +868,6 @@ Magenta - - tsbReload - 97, 53 @@ -1388,71 +877,68 @@ ImageAboveText - - System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 6, 56 - + Magenta - - tsbServer + + 128, 53 - - 64, 53 + + Check for updates - - Servers - - + ImageAboveText - - System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 393, 22 - + + v2rayN (this software) + + + 393, 22 + + + Update v2rayCore + + + 393, 22 + + + Check for updated PAC (need the HTTP proxy are ON) + + + 390, 6 + + + 393, 22 + + + Simplify PAC (need to set Core route) + + + 6, 56 + + Magenta - - tsbSub + + 48, 53 - - 99, 53 + + Help - - Subscriptions - - + ImageAboveText - - System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 187, 22 - - tsbSubSetting - - - 125, 22 - - - Settings - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbSubUpdate - - - 125, 22 - - - Updates - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbV2rayWebsite + + v2rayN Project 187, 22 @@ -1460,61 +946,587 @@ V2Ray Website + + 184, 6 + + + 187, 22 + + + Language-[English] + + + 187, 22 + + + 语言-[中文简体] + + + Magenta + + + 89, 53 + + + Promotion + + + ImageAboveText + + + 6, 56 + + + + iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8 + YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAySURBVFhH7c6xDQAgCEVBRnVTHU2ZABuMxV3yOvJDAAA/ + GqfZVG6X8mg1dfUAAPBQxAZd0SJruVXHWwAAAABJRU5ErkJggg== + + + + Magenta + + + 52, 53 + + + Close + + + ImageAboveText + + + True + + + 108 + + + 6, 12 + + + 952, 593 + + + 4, 4, 4, 4 + + + v2rayN + + + menuAddVmessServer + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuAddShadowsocksServer + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuAddSocksServer + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuAddCustomServer + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuAddServers + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuScanScreen + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator1 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuRemoveServer + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuRemoveDuplicateServer + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuCopyServer + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuSetDefaultServer + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator3 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuMoveTop + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuMoveUp + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuMoveDown + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuMoveBottom + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuSelectAll + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator9 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuPingServer + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuTcpingServer + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuRealPingServer + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuSpeedServer + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuTestMe + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator6 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuExport2ClientConfig + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuExport2ServerConfig + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuExport2ShareUrl + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuExport2SubContent + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbServer + + + System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + notifyMain + + + System.Windows.Forms.NotifyIcon, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuSysAgentMode + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuNotEnabledHttp + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuGlobal + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuGlobalPAC + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuKeep + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuKeepPAC + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuKeepNothing + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuKeepPACNothing + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuServers + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuAddServers2 + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuScanScreen2 + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuCopyPACUrl + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuUpdateSubscriptions + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator2 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuExit + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + bgwScan + + + System.ComponentModel.BackgroundWorker, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslSocksPortLab + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslSocksPort + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslBlank1 + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslHttpPortLab + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslHttpPort + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslBlank2 + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslPacPortLab + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslPacPort + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslBlank3 + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslRouting + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslServerLatency + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslServerSpeed + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslBlank4 + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator4 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbSub + + + System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbSubSetting + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbSubUpdate + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbQRCodeSwitch + + + System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator8 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbOptionSetting + + + System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator5 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbReload + + + System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator7 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbCheckUpdate + + + System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbCheckUpdateN + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbCheckUpdateCore + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbCheckUpdatePACList + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator13 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbCheckClearPACList + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator10 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbHelp + + + System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbAbout + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbV2rayWebsite + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 0, 0 + + toolStripSeparator12 - - tsMain + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - $this + + tsbLanguageDef - - 952, 56 + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 1 + + tsbLanguageZhHans - - System.Windows.Forms.ToolStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 5 + + tsbPromotion - - Fill + + System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 3, 17 + + toolStripSeparator11 - - 0 + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - True + + tsbClose - - txtMsgBox + + System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - groupBox2 + + MainForm - - Vertical - - - 946, 134 - - - 3 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 0 + + v2rayN.Forms.BaseForm, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null \ No newline at end of file diff --git a/v2rayN/v2rayN/Forms/MainForm.zh-Hans.resx b/v2rayN/v2rayN/Forms/MainForm.zh-Hans.resx index 3268c19e..71c3ad06 100644 --- a/v2rayN/v2rayN/Forms/MainForm.zh-Hans.resx +++ b/v2rayN/v2rayN/Forms/MainForm.zh-Hans.resx @@ -363,12 +363,24 @@ 测试服务器延迟Tcping(多选) (Ctrl+O) + + 测试当前服务节点状态 + 195, 22 更新订阅 + + 路由模式 + + + 延迟: + + + 当前 HTTP 代理的访问延迟。 + 网速显示未启用 diff --git a/v2rayN/v2rayN/Forms/OptionSettingForm.Designer.cs b/v2rayN/v2rayN/Forms/OptionSettingForm.Designer.cs index 7c009fc6..6f80e585 100644 --- a/v2rayN/v2rayN/Forms/OptionSettingForm.Designer.cs +++ b/v2rayN/v2rayN/Forms/OptionSettingForm.Designer.cs @@ -31,7 +31,7 @@ System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(OptionSettingForm)); this.btnClose = new System.Windows.Forms.Button(); this.tabControl1 = new System.Windows.Forms.TabControl(); - this.tabPage1 = new System.Windows.Forms.TabPage(); + this.tabBasic = new System.Windows.Forms.TabPage(); this.groupBox1 = new System.Windows.Forms.GroupBox(); this.label16 = new System.Windows.Forms.Label(); this.cmblistenerType = new System.Windows.Forms.ComboBox(); @@ -53,7 +53,7 @@ this.label5 = new System.Windows.Forms.Label(); this.txtlocalPort = new System.Windows.Forms.TextBox(); this.label2 = new System.Windows.Forms.Label(); - this.tabPage2 = new System.Windows.Forms.TabPage(); + this.tabRouting = new System.Windows.Forms.TabPage(); this.groupBox2 = new System.Windows.Forms.GroupBox(); this.tabControl2 = new System.Windows.Forms.TabControl(); this.tabPage3 = new System.Windows.Forms.TabPage(); @@ -62,14 +62,14 @@ this.txtUserdirect = new System.Windows.Forms.TextBox(); this.tabPage5 = new System.Windows.Forms.TabPage(); this.txtUserblock = new System.Windows.Forms.TextBox(); - this.tabPage8 = new System.Windows.Forms.TabPage(); + this.tabPreDefinedRules = new System.Windows.Forms.TabPage(); this.cmbroutingMode = new System.Windows.Forms.ComboBox(); this.panel3 = new System.Windows.Forms.Panel(); this.linkLabelRoutingDoc = new System.Windows.Forms.LinkLabel(); this.btnSetDefRountingRule = new System.Windows.Forms.Button(); this.labRoutingTips = new System.Windows.Forms.Label(); this.cmbdomainStrategy = new System.Windows.Forms.ComboBox(); - this.tabPage6 = new System.Windows.Forms.TabPage(); + this.tabKCP = new System.Windows.Forms.TabPage(); this.chkKcpcongestion = new System.Windows.Forms.CheckBox(); this.txtKcpwriteBufferSize = new System.Windows.Forms.TextBox(); this.label10 = new System.Windows.Forms.Label(); @@ -83,7 +83,7 @@ this.label7 = new System.Windows.Forms.Label(); this.txtKcpmtu = new System.Windows.Forms.TextBox(); this.label6 = new System.Windows.Forms.Label(); - this.tabPage7 = new System.Windows.Forms.TabPage(); + this.tabGUI = new System.Windows.Forms.TabPage(); this.chkKeepOlderDedupl = new System.Windows.Forms.CheckBox(); this.cbFreshrate = new System.Windows.Forms.ComboBox(); this.lbFreshrate = new System.Windows.Forms.Label(); @@ -92,7 +92,7 @@ this.txturlGFWList = new System.Windows.Forms.TextBox(); this.label13 = new System.Windows.Forms.Label(); this.chkAutoRun = new System.Windows.Forms.CheckBox(); - this.tabPage9 = new System.Windows.Forms.TabPage(); + this.tabUserPAC = new System.Windows.Forms.TabPage(); this.txtuserPacRule = new System.Windows.Forms.TextBox(); this.panel4 = new System.Windows.Forms.Panel(); this.label4 = new System.Windows.Forms.Label(); @@ -100,19 +100,19 @@ this.btnOK = new System.Windows.Forms.Button(); this.panel1 = new System.Windows.Forms.Panel(); this.tabControl1.SuspendLayout(); - this.tabPage1.SuspendLayout(); + this.tabBasic.SuspendLayout(); this.groupBox1.SuspendLayout(); - this.tabPage2.SuspendLayout(); + this.tabRouting.SuspendLayout(); this.groupBox2.SuspendLayout(); this.tabControl2.SuspendLayout(); this.tabPage3.SuspendLayout(); this.tabPage4.SuspendLayout(); this.tabPage5.SuspendLayout(); - this.tabPage8.SuspendLayout(); + this.tabPreDefinedRules.SuspendLayout(); this.panel3.SuspendLayout(); - this.tabPage6.SuspendLayout(); - this.tabPage7.SuspendLayout(); - this.tabPage9.SuspendLayout(); + this.tabKCP.SuspendLayout(); + this.tabGUI.SuspendLayout(); + this.tabUserPAC.SuspendLayout(); this.panel4.SuspendLayout(); this.panel2.SuspendLayout(); this.SuspendLayout(); @@ -127,21 +127,21 @@ // // tabControl1 // - this.tabControl1.Controls.Add(this.tabPage1); - this.tabControl1.Controls.Add(this.tabPage2); - this.tabControl1.Controls.Add(this.tabPage6); - this.tabControl1.Controls.Add(this.tabPage7); - this.tabControl1.Controls.Add(this.tabPage9); + this.tabControl1.Controls.Add(this.tabBasic); + this.tabControl1.Controls.Add(this.tabRouting); + this.tabControl1.Controls.Add(this.tabKCP); + this.tabControl1.Controls.Add(this.tabGUI); + this.tabControl1.Controls.Add(this.tabUserPAC); resources.ApplyResources(this.tabControl1, "tabControl1"); this.tabControl1.Name = "tabControl1"; this.tabControl1.SelectedIndex = 0; // - // tabPage1 + // tabBasic // - this.tabPage1.Controls.Add(this.groupBox1); - resources.ApplyResources(this.tabPage1, "tabPage1"); - this.tabPage1.Name = "tabPage1"; - this.tabPage1.UseVisualStyleBackColor = true; + this.tabBasic.Controls.Add(this.groupBox1); + resources.ApplyResources(this.tabBasic, "tabBasic"); + this.tabBasic.Name = "tabBasic"; + this.tabBasic.UseVisualStyleBackColor = true; // // groupBox1 // @@ -305,12 +305,12 @@ resources.ApplyResources(this.label2, "label2"); this.label2.Name = "label2"; // - // tabPage2 + // tabRouting // - this.tabPage2.Controls.Add(this.groupBox2); - resources.ApplyResources(this.tabPage2, "tabPage2"); - this.tabPage2.Name = "tabPage2"; - this.tabPage2.UseVisualStyleBackColor = true; + this.tabRouting.Controls.Add(this.groupBox2); + resources.ApplyResources(this.tabRouting, "tabRouting"); + this.tabRouting.Name = "tabRouting"; + this.tabRouting.UseVisualStyleBackColor = true; // // groupBox2 // @@ -325,7 +325,7 @@ this.tabControl2.Controls.Add(this.tabPage3); this.tabControl2.Controls.Add(this.tabPage4); this.tabControl2.Controls.Add(this.tabPage5); - this.tabControl2.Controls.Add(this.tabPage8); + this.tabControl2.Controls.Add(this.tabPreDefinedRules); resources.ApplyResources(this.tabControl2, "tabControl2"); this.tabControl2.Name = "tabControl2"; this.tabControl2.SelectedIndex = 0; @@ -366,12 +366,12 @@ resources.ApplyResources(this.txtUserblock, "txtUserblock"); this.txtUserblock.Name = "txtUserblock"; // - // tabPage8 + // tabPreDefinedRules // - this.tabPage8.Controls.Add(this.cmbroutingMode); - resources.ApplyResources(this.tabPage8, "tabPage8"); - this.tabPage8.Name = "tabPage8"; - this.tabPage8.UseVisualStyleBackColor = true; + this.tabPreDefinedRules.Controls.Add(this.cmbroutingMode); + resources.ApplyResources(this.tabPreDefinedRules, "tabPreDefinedRules"); + this.tabPreDefinedRules.Name = "tabPreDefinedRules"; + this.tabPreDefinedRules.UseVisualStyleBackColor = true; // // cmbroutingMode // @@ -425,24 +425,24 @@ resources.ApplyResources(this.cmbdomainStrategy, "cmbdomainStrategy"); this.cmbdomainStrategy.Name = "cmbdomainStrategy"; // - // tabPage6 + // tabKCP // - this.tabPage6.Controls.Add(this.chkKcpcongestion); - this.tabPage6.Controls.Add(this.txtKcpwriteBufferSize); - this.tabPage6.Controls.Add(this.label10); - this.tabPage6.Controls.Add(this.txtKcpreadBufferSize); - this.tabPage6.Controls.Add(this.label11); - this.tabPage6.Controls.Add(this.txtKcpdownlinkCapacity); - this.tabPage6.Controls.Add(this.label8); - this.tabPage6.Controls.Add(this.txtKcpuplinkCapacity); - this.tabPage6.Controls.Add(this.label9); - this.tabPage6.Controls.Add(this.txtKcptti); - this.tabPage6.Controls.Add(this.label7); - this.tabPage6.Controls.Add(this.txtKcpmtu); - this.tabPage6.Controls.Add(this.label6); - resources.ApplyResources(this.tabPage6, "tabPage6"); - this.tabPage6.Name = "tabPage6"; - this.tabPage6.UseVisualStyleBackColor = true; + this.tabKCP.Controls.Add(this.chkKcpcongestion); + this.tabKCP.Controls.Add(this.txtKcpwriteBufferSize); + this.tabKCP.Controls.Add(this.label10); + this.tabKCP.Controls.Add(this.txtKcpreadBufferSize); + this.tabKCP.Controls.Add(this.label11); + this.tabKCP.Controls.Add(this.txtKcpdownlinkCapacity); + this.tabKCP.Controls.Add(this.label8); + this.tabKCP.Controls.Add(this.txtKcpuplinkCapacity); + this.tabKCP.Controls.Add(this.label9); + this.tabKCP.Controls.Add(this.txtKcptti); + this.tabKCP.Controls.Add(this.label7); + this.tabKCP.Controls.Add(this.txtKcpmtu); + this.tabKCP.Controls.Add(this.label6); + resources.ApplyResources(this.tabKCP, "tabKCP"); + this.tabKCP.Name = "tabKCP"; + this.tabKCP.UseVisualStyleBackColor = true; // // chkKcpcongestion // @@ -510,19 +510,19 @@ resources.ApplyResources(this.label6, "label6"); this.label6.Name = "label6"; // - // tabPage7 + // tabGUI // - this.tabPage7.Controls.Add(this.chkKeepOlderDedupl); - this.tabPage7.Controls.Add(this.cbFreshrate); - this.tabPage7.Controls.Add(this.lbFreshrate); - this.tabPage7.Controls.Add(this.chkEnableStatistics); - this.tabPage7.Controls.Add(this.chkAllowLANConn); - this.tabPage7.Controls.Add(this.txturlGFWList); - this.tabPage7.Controls.Add(this.label13); - this.tabPage7.Controls.Add(this.chkAutoRun); - resources.ApplyResources(this.tabPage7, "tabPage7"); - this.tabPage7.Name = "tabPage7"; - this.tabPage7.UseVisualStyleBackColor = true; + this.tabGUI.Controls.Add(this.chkKeepOlderDedupl); + this.tabGUI.Controls.Add(this.cbFreshrate); + this.tabGUI.Controls.Add(this.lbFreshrate); + this.tabGUI.Controls.Add(this.chkEnableStatistics); + this.tabGUI.Controls.Add(this.chkAllowLANConn); + this.tabGUI.Controls.Add(this.txturlGFWList); + this.tabGUI.Controls.Add(this.label13); + this.tabGUI.Controls.Add(this.chkAutoRun); + resources.ApplyResources(this.tabGUI, "tabGUI"); + this.tabGUI.Name = "tabGUI"; + this.tabGUI.UseVisualStyleBackColor = true; // // chkKeepOlderDedupl // @@ -570,13 +570,13 @@ this.chkAutoRun.Name = "chkAutoRun"; this.chkAutoRun.UseVisualStyleBackColor = true; // - // tabPage9 + // tabUserPAC // - this.tabPage9.Controls.Add(this.txtuserPacRule); - this.tabPage9.Controls.Add(this.panel4); - resources.ApplyResources(this.tabPage9, "tabPage9"); - this.tabPage9.Name = "tabPage9"; - this.tabPage9.UseVisualStyleBackColor = true; + this.tabUserPAC.Controls.Add(this.txtuserPacRule); + this.tabUserPAC.Controls.Add(this.panel4); + resources.ApplyResources(this.tabUserPAC, "tabUserPAC"); + this.tabUserPAC.Name = "tabUserPAC"; + this.tabUserPAC.UseVisualStyleBackColor = true; // // txtuserPacRule // @@ -626,10 +626,10 @@ this.Name = "OptionSettingForm"; this.Load += new System.EventHandler(this.OptionSettingForm_Load); this.tabControl1.ResumeLayout(false); - this.tabPage1.ResumeLayout(false); + this.tabBasic.ResumeLayout(false); this.groupBox1.ResumeLayout(false); this.groupBox1.PerformLayout(); - this.tabPage2.ResumeLayout(false); + this.tabRouting.ResumeLayout(false); this.groupBox2.ResumeLayout(false); this.tabControl2.ResumeLayout(false); this.tabPage3.ResumeLayout(false); @@ -638,15 +638,15 @@ this.tabPage4.PerformLayout(); this.tabPage5.ResumeLayout(false); this.tabPage5.PerformLayout(); - this.tabPage8.ResumeLayout(false); + this.tabPreDefinedRules.ResumeLayout(false); this.panel3.ResumeLayout(false); this.panel3.PerformLayout(); - this.tabPage6.ResumeLayout(false); - this.tabPage6.PerformLayout(); - this.tabPage7.ResumeLayout(false); - this.tabPage7.PerformLayout(); - this.tabPage9.ResumeLayout(false); - this.tabPage9.PerformLayout(); + this.tabKCP.ResumeLayout(false); + this.tabKCP.PerformLayout(); + this.tabGUI.ResumeLayout(false); + this.tabGUI.PerformLayout(); + this.tabUserPAC.ResumeLayout(false); + this.tabUserPAC.PerformLayout(); this.panel4.ResumeLayout(false); this.panel2.ResumeLayout(false); this.ResumeLayout(false); @@ -666,8 +666,8 @@ private System.Windows.Forms.CheckBox chkudpEnabled; private System.Windows.Forms.Panel panel1; private System.Windows.Forms.TabControl tabControl1; - private System.Windows.Forms.TabPage tabPage1; - private System.Windows.Forms.TabPage tabPage2; + private System.Windows.Forms.TabPage tabBasic; + private System.Windows.Forms.TabPage tabRouting; private System.Windows.Forms.Panel panel2; private System.Windows.Forms.GroupBox groupBox2; private System.Windows.Forms.ComboBox cmbprotocol; @@ -686,7 +686,7 @@ private System.Windows.Forms.TabPage tabPage5; private System.Windows.Forms.TextBox txtUserdirect; private System.Windows.Forms.TextBox txtUserblock; - private System.Windows.Forms.TabPage tabPage6; + private System.Windows.Forms.TabPage tabKCP; private System.Windows.Forms.TextBox txtKcpmtu; private System.Windows.Forms.Label label6; private System.Windows.Forms.TextBox txtKcptti; @@ -700,7 +700,7 @@ private System.Windows.Forms.TextBox txtKcpuplinkCapacity; private System.Windows.Forms.Label label9; private System.Windows.Forms.CheckBox chkKcpcongestion; - private System.Windows.Forms.TabPage tabPage7; + private System.Windows.Forms.TabPage tabGUI; private System.Windows.Forms.CheckBox chkAutoRun; private System.Windows.Forms.Label label13; private System.Windows.Forms.TextBox txturlGFWList; @@ -718,8 +718,8 @@ private System.Windows.Forms.Label lbFreshrate; private System.Windows.Forms.Label label16; private System.Windows.Forms.ComboBox cmblistenerType; - private System.Windows.Forms.TabPage tabPage8; - private System.Windows.Forms.TabPage tabPage9; + private System.Windows.Forms.TabPage tabPreDefinedRules; + private System.Windows.Forms.TabPage tabUserPAC; private System.Windows.Forms.TextBox txtuserPacRule; private System.Windows.Forms.Panel panel4; private System.Windows.Forms.Label label4; diff --git a/v2rayN/v2rayN/Forms/OptionSettingForm.cs b/v2rayN/v2rayN/Forms/OptionSettingForm.cs index 6fa88f50..5d69093d 100644 --- a/v2rayN/v2rayN/Forms/OptionSettingForm.cs +++ b/v2rayN/v2rayN/Forms/OptionSettingForm.cs @@ -9,8 +9,10 @@ namespace v2rayN.Forms { public partial class OptionSettingForm : BaseForm { - public OptionSettingForm() + private string _tabOpened; + public OptionSettingForm(string tabOpened = "") { + _tabOpened = tabOpened; InitializeComponent(); } @@ -25,6 +27,18 @@ namespace v2rayN.Forms InitGUI(); InitUserPAC(); + + var tab = tabControl1.TabPages[_tabOpened]; + var tab2 = tabControl2.TabPages[_tabOpened]; + if (tab != null) + { + tabControl1.SelectedTab = tab; + } + if (tab2 != null) + { + tabControl1.SelectedTab = tabRouting; + tabControl2.SelectedTab = tab2; + } } /// @@ -78,8 +92,7 @@ namespace v2rayN.Forms { //路由 cmbdomainStrategy.Text = config.domainStrategy; - int.TryParse(config.routingMode, out int routingMode); - cmbroutingMode.SelectedIndex = routingMode; + cmbroutingMode.SelectedIndex = config.routingMode; txtUseragent.Text = Utils.List2String(config.useragent, true); txtUserdirect.Text = Utils.List2String(config.userdirect, true); @@ -276,7 +289,7 @@ namespace v2rayN.Forms { //路由 string domainStrategy = cmbdomainStrategy.Text; - string routingMode = cmbroutingMode.SelectedIndex.ToString(); + int routingMode = cmbroutingMode.SelectedIndex; string useragent = txtUseragent.Text.TrimEx(); string userdirect = txtUserdirect.Text.TrimEx(); diff --git a/v2rayN/v2rayN/Forms/OptionSettingForm.resx b/v2rayN/v2rayN/Forms/OptionSettingForm.resx index 7f8ef414..90244957 100644 --- a/v2rayN/v2rayN/Forms/OptionSettingForm.resx +++ b/v2rayN/v2rayN/Forms/OptionSettingForm.resx @@ -120,24 +120,36 @@ + + True + 6, 12 662, 675 - - True - 4, 4, 4, 4 + + OptionSettingForm + Settings + + v2rayN.Forms.BaseForm, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + 355, 16 + + btnClose + + + panel2 + 75, 23 @@ -147,9 +159,27 @@ &Cancel + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + 267, 16 + + btnOK + + + btnOK + + + panel2 + + + panel2 + 75, 23 @@ -159,6 +189,18 @@ &OK + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 1 + + + 1 + Top, Right @@ -168,6 +210,18 @@ 322, 10 + + btnSetDefRountingRule + + + btnSetDefRountingRule + + + panel3 + + + panel3 + 229, 23 @@ -177,21 +231,69 @@ Set default custom routing rules + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 1 + + + 1 + 161, 84 + + cbFreshrate + + + cbFreshrate + + + tabGUI + + + tabGUI + 58, 20 32 + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 1 + + + 1 + True 15, 63 + + chkAllowIn2 + + + chkAllowIn2 + + + groupBox1 + + + groupBox1 + 120, 16 @@ -201,15 +303,39 @@ listening port 2 + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + False + + 7 + + + 7 + True 15, 38 + + chkAllowLANConn + + + chkAllowLANConn + + + tabGUI + + + tabGUI + 204, 16 @@ -219,12 +345,36 @@ Allow connections from the LAN + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 4 + + + 4 + True 15, 16 + + chkAutoRun + + + chkAutoRun + + + tabGUI + + + tabGUI + 246, 16 @@ -234,6 +384,18 @@ Automatically start at system startup + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 7 + + + 7 + True @@ -243,6 +405,18 @@ 15, 62 + + chkEnableStatistics + + + chkEnableStatistics + + + tabGUI + + + tabGUI + 576, 16 @@ -252,12 +426,36 @@ Enable Statistics (Realtime netspeed and traffic records. Require restart the v2rayN client) + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 3 + + + 3 + True 20, 143 + + chkKcpcongestion + + + chkKcpcongestion + + + tabKCP + + + tabKCP + 84, 16 @@ -267,6 +465,18 @@ congestion + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + + + 0 + True @@ -276,6 +486,18 @@ 15, 110 + + chkKeepOlderDedupl + + + chkKeepOlderDedupl + + + tabGUI + + + tabGUI + 198, 16 @@ -285,12 +507,36 @@ Keep older when deduplication + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + + + 0 + True 15, 160 + + chklogEnabled + + + chklogEnabled + + + groupBox1 + + + groupBox1 + 126, 16 @@ -300,12 +546,36 @@ Record local logs + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 15 + + + 15 + True 15, 129 + + chkmuxEnabled + + + chkmuxEnabled + + + groupBox1 + + + groupBox1 + 174, 16 @@ -315,6 +585,18 @@ Turn on Mux Multiplexing + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 6 + + + 6 + True @@ -324,6 +606,18 @@ 468, 27 + + chksniffingEnabled + + + chksniffingEnabled + + + groupBox1 + + + groupBox1 + 120, 16 @@ -333,6 +627,18 @@ Turn on Sniffing + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 3 + + + 3 + True @@ -342,6 +648,18 @@ 468, 60 + + chksniffingEnabled2 + + + chksniffingEnabled2 + + + groupBox1 + + + groupBox1 + 120, 16 @@ -351,15 +669,39 @@ Turn on Sniffing + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + False + + 2 + + + 2 + True 369, 27 + + chkudpEnabled + + + chkudpEnabled + + + groupBox1 + + + groupBox1 + 84, 16 @@ -369,12 +711,36 @@ Enable UDP + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 14 + + + 14 + True 369, 62 + + chkudpEnabled2 + + + chkudpEnabled2 + + + groupBox1 + + + groupBox1 + 84, 16 @@ -384,9 +750,21 @@ Enable UDP + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + False + + 8 + + + 8 + AsIs @@ -399,12 +777,36 @@ 115, 10 + + cmbdomainStrategy + + + cmbdomainStrategy + + + panel3 + + + panel3 + 165, 20 16 + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 3 + + + 3 + Not Enabled Http Proxy @@ -429,12 +831,36 @@ 124, 94 + + cmblistenerType + + + cmblistenerType + + + groupBox1 + + + groupBox1 + 464, 20 33 + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 1 + + + 1 + debug @@ -453,12 +879,36 @@ 257, 158 + + cmbloglevel + + + cmbloglevel + + + groupBox1 + + + groupBox1 + 97, 20 6 + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 16 + + + 16 + False @@ -471,12 +921,36 @@ 257, 25 + + cmbprotocol + + + cmbprotocol + + + groupBox1 + + + groupBox1 + 97, 20 12 + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 12 + + + 12 + socks @@ -486,15 +960,39 @@ 257, 60 + + cmbprotocol2 + + + cmbprotocol2 + + + groupBox1 + + + groupBox1 + 97, 20 17 + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + False + + 9 + + + 9 + Global @@ -510,42 +1008,102 @@ 21, 17 + + cmbroutingMode + + + tabPreDefinedRules + 255, 20 14 + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + Fill 3, 3 + + groupBox1 + + + groupBox1 + + + tabBasic + + + tabBasic + 648, 573 6 + + System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + + + 0 + Fill 3, 3 + + groupBox2 + + + tabRouting + 648, 573 12 + + System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + True 206, 29 + + label1 + + + label1 + + + groupBox1 + + + groupBox1 + 53, 12 @@ -555,12 +1113,36 @@ protocol + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 13 + + + 13 + True 236, 104 + + label10 + + + label10 + + + tabKCP + + + tabKCP + 95, 12 @@ -570,12 +1152,36 @@ writeBufferSize + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 2 + + + 2 + True 18, 104 + + label11 + + + label11 + + + tabKCP + + + tabKCP + 89, 12 @@ -585,12 +1191,36 @@ readBufferSize + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 4 + + + 4 + True 30, 176 + + label13 + + + label13 + + + tabGUI + + + tabGUI + 431, 12 @@ -600,12 +1230,36 @@ Custom GFWList address (please fill in the blank without customization) + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 6 + + + 6 + True 33, 204 + + label14 + + + label14 + + + groupBox1 + + + groupBox1 + 281, 12 @@ -615,6 +1269,18 @@ Custom DNS (multiple, separated by commas (,)) + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 5 + + + 5 + True @@ -624,6 +1290,18 @@ 42, 98 + + label16 + + + label16 + + + groupBox1 + + + groupBox1 + 65, 12 @@ -633,12 +1311,36 @@ Http proxy + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + + + 0 + True 33, 29 + + label2 + + + label2 + + + groupBox1 + + + groupBox1 + 89, 12 @@ -648,12 +1350,36 @@ Listening port + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 19 + + + 19 + True 206, 64 + + label3 + + + label3 + + + groupBox1 + + + groupBox1 + 53, 12 @@ -663,15 +1389,39 @@ protocol + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + False + + 10 + + + 10 + NoControl 5, 11 + + label4 + + + label4 + + + panel4 + + + panel4 + 598, 16 @@ -681,12 +1431,36 @@ *Set user pac rules, separated by commas (,) + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + + + 0 + True 193, 162 + + label5 + + + label5 + + + groupBox1 + + + groupBox1 + 59, 12 @@ -696,12 +1470,36 @@ Log level + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 17 + + + 17 + True 18, 28 + + label6 + + + label6 + + + tabKCP + + + tabKCP + 23, 12 @@ -711,12 +1509,36 @@ mtu + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 12 + + + 12 + True 236, 28 + + label7 + + + label7 + + + tabKCP + + + tabKCP + 23, 12 @@ -726,12 +1548,36 @@ tti + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 10 + + + 10 + True 236, 66 + + label8 + + + label8 + + + tabKCP + + + tabKCP + 101, 12 @@ -741,12 +1587,36 @@ downlinkCapacity + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 6 + + + 6 + True 18, 66 + + label9 + + + label9 + + + tabKCP + + + tabKCP + 89, 12 @@ -756,9 +1626,33 @@ uplinkCapacity + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 8 + + + 8 + 5, 45 + + labRoutingTips + + + labRoutingTips + + + panel3 + + + panel3 + 598, 16 @@ -768,6 +1662,18 @@ *Set the rules, separated by commas (,); support Domain (pure string / regular / subdomain) and IP + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 2 + + + 2 + True @@ -777,6 +1683,18 @@ 30, 87 + + lbFreshrate + + + lbFreshrate + + + tabGUI + + + tabGUI + 125, 12 @@ -786,6 +1704,18 @@ Statistics freshrate + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 2 + + + 2 + True @@ -795,6 +1725,18 @@ 0, 0, 0, 0 + + linkLabelRoutingDoc + + + linkLabelRoutingDoc + + + panel3 + + + panel3 + 95, 12 @@ -804,114 +1746,267 @@ Domain strategy + + System.Windows.Forms.LinkLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.LinkLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + + + 0 + Top 0, 0 + + panel1 + + + $this + 662, 10 9 + + System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 2 + Bottom 0, 615 + + panel2 + + + $this + 662, 60 11 + + System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 1 + Top 3, 17 + + panel3 + + + groupBox2 + 642, 67 19 + + System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 1 + Top 3, 3 + + panel4 + + + panel4 + + + tabUserPAC + + + tabUserPAC + 648, 37 20 + + System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 1 + + + 1 + + + 4, 22 + + + tabBasic + + + 3, 3, 3, 3 + + + tabControl1 + + + 654, 579 + + + 0 + + + Core: basic settings + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + Fill 0, 10 + + tabControl1 + + + $this + 662, 605 10 + + System.Windows.Forms.TabControl, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + Fill 3, 84 + + tabControl2 + + + groupBox2 + 642, 486 12 - - 4, 22 + + System.Windows.Forms.TabControl, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 3, 3, 3, 3 - - - 654, 579 - - + 0 - - Core: basic settings - - + 4, 22 - + + tabGUI + + 3, 3, 3, 3 - + + tabControl1 + + 654, 579 - - 1 + + 3 - - Core: Routing settings + + v2rayN settings + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 3 + + + 4, 22 + + + tabKCP + + + 3, 3, 3, 3 + + + tabControl1 + + + 654, 579 + + + 2 + + + Core: KCP settings + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 2 4, 22 + + tabPage3 + 3, 3, 3, 3 + + tabControl2 + 634, 460 @@ -921,12 +2016,24 @@ 1.Proxy Domain or IP + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + 4, 22 + + tabPage4 + 3, 3, 3, 3 + + tabControl2 + 634, 460 @@ -936,12 +2043,24 @@ 2.Direct Domain or IP + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 1 + 4, 22 + + tabPage5 + 3, 3, 3, 3 + + tabControl2 + 634, 460 @@ -951,165 +2070,432 @@ 3.Block Domain or IP - - 4, 22 + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 3, 3, 3, 3 - - - 654, 579 - - + 2 - - Core: KCP settings - - + 4, 22 - + + tabPreDefinedRules + + 3, 3, 3, 3 - - 654, 579 + + tabControl2 - - 3 - - - v2rayN settings - - - 4, 22 - - - 3, 3, 3, 3 - - + 634, 460 - + 3 - + 4.Pre-defined rules - + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 3 + + 4, 22 - + + tabRouting + + 3, 3, 3, 3 - + + tabControl1 + + 654, 579 - + + 1 + + + Core: Routing settings + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 1 + + + 4, 22 + + + tabUserPAC + + + 3, 3, 3, 3 + + + tabControl1 + + + 654, 579 + + 4 - + User PAC settings + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 4 + 345, 62 + + txtKcpdownlinkCapacity + + + txtKcpdownlinkCapacity + + + tabKCP + + + tabKCP + 94, 21 11 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 5 + + + 5 + 111, 24 + + txtKcpmtu + + + txtKcpmtu + + + tabKCP + + + tabKCP + 94, 21 5 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 11 + + + 11 + 111, 100 + + txtKcpreadBufferSize + + + txtKcpreadBufferSize + + + tabKCP + + + tabKCP + 94, 21 13 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 3 + + + 3 + 345, 24 + + txtKcptti + + + txtKcptti + + + tabKCP + + + tabKCP + 94, 21 7 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 9 + + + 9 + 111, 62 + + txtKcpuplinkCapacity + + + txtKcpuplinkCapacity + + + tabKCP + + + tabKCP + 94, 21 9 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 7 + + + 7 + 345, 100 + + txtKcpwriteBufferSize + + + txtKcpwriteBufferSize + + + tabKCP + + + tabKCP + 94, 21 15 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 1 + + + 1 + 124, 25 + + txtlocalPort + + + txtlocalPort + + + groupBox1 + + + groupBox1 + 78, 21 3 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 18 + + + 18 + 124, 60 + + txtlocalPort2 + + + txtlocalPort2 + + + groupBox1 + + + groupBox1 + 78, 21 14 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + False + + 11 + + + 11 + 33, 228 True + + txtremoteDNS + + + txtremoteDNS + + + groupBox1 + + + groupBox1 + 555, 100 30 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 4 + + + 4 + 32, 205 True + + txturlGFWList + + + txturlGFWList + + + tabGUI + + + tabGUI + 541, 100 28 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 5 + + + 5 + Fill @@ -1122,6 +2508,18 @@ True + + txtUseragent + + + txtUseragent + + + tabPage3 + + + tabPage3 + Vertical @@ -1131,6 +2529,18 @@ 0 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + + + 0 + Fill @@ -1143,6 +2553,18 @@ True + + txtUserblock + + + txtUserblock + + + tabPage5 + + + tabPage5 + Vertical @@ -1152,6 +2574,18 @@ 1 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + + + 0 + Fill @@ -1164,6 +2598,18 @@ True + + txtUserdirect + + + txtUserdirect + + + tabPage4 + + + tabPage4 + Vertical @@ -1173,6 +2619,18 @@ 1 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + + + 0 + Fill @@ -1185,6 +2643,18 @@ True + + txtuserPacRule + + + txtuserPacRule + + + tabUserPAC + + + tabUserPAC + Vertical @@ -1194,4 +2664,16 @@ 21 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + + + 0 + \ No newline at end of file diff --git a/v2rayN/v2rayN/Forms/OptionSettingForm.zh-Hans.resx b/v2rayN/v2rayN/Forms/OptionSettingForm.zh-Hans.resx index 1509bce5..b2ecd834 100644 --- a/v2rayN/v2rayN/Forms/OptionSettingForm.zh-Hans.resx +++ b/v2rayN/v2rayN/Forms/OptionSettingForm.zh-Hans.resx @@ -312,17 +312,20 @@ 642, 72 + + Core:基础设置 + 3, 89 642, 481 - - Core:基础设置 + + v2rayN设置 - - Core:路由设置 + + Core:KCP设置 634, 455 @@ -342,19 +345,16 @@ 3.阻止的Domain或IP - - Core:KCP设置 - - - v2rayN设置 - 634, 455 - + 4.预定义规则 - + + Core:路由设置 + + 用户PAC设置 diff --git a/v2rayN/v2rayN/Handler/ConfigHandler.cs b/v2rayN/v2rayN/Handler/ConfigHandler.cs index c6748e56..3dae84b1 100644 --- a/v2rayN/v2rayN/Handler/ConfigHandler.cs +++ b/v2rayN/v2rayN/Handler/ConfigHandler.cs @@ -85,10 +85,6 @@ namespace v2rayN.Handler { config.domainStrategy = "IPIfNonMatch"; } - if (Utils.IsNullOrEmpty(config.routingMode)) - { - config.routingMode = "0"; - } if (config.useragent == null) { config.useragent = new List(); diff --git a/v2rayN/v2rayN/Handler/SpeedtestHandler.cs b/v2rayN/v2rayN/Handler/SpeedtestHandler.cs index 519b51e2..f14296dc 100644 --- a/v2rayN/v2rayN/Handler/SpeedtestHandler.cs +++ b/v2rayN/v2rayN/Handler/SpeedtestHandler.cs @@ -145,7 +145,7 @@ namespace v2rayN.Handler } } - public async Task RunAvailabilityCheck() // alias: isLive + public int RunAvailabilityCheck() // alias: isLive { try { diff --git a/v2rayN/v2rayN/Handler/V2rayConfigHandler.cs b/v2rayN/v2rayN/Handler/V2rayConfigHandler.cs index 9ea93933..1296112a 100644 --- a/v2rayN/v2rayN/Handler/V2rayConfigHandler.cs +++ b/v2rayN/v2rayN/Handler/V2rayConfigHandler.cs @@ -195,15 +195,15 @@ namespace v2rayN.Handler switch (config.routingMode) { - case "0": + case 0: break; - case "1": + case 1: routingGeo("ip", "private", Global.directTag, ref v2rayConfig); break; - case "2": + case 2: routingGeo("", "cn", Global.directTag, ref v2rayConfig); break; - case "3": + case 3: routingGeo("ip", "private", Global.directTag, ref v2rayConfig); routingGeo("", "cn", Global.directTag, ref v2rayConfig); break; diff --git a/v2rayN/v2rayN/Mode/Config.cs b/v2rayN/v2rayN/Mode/Config.cs index 515114df..d48da6ee 100644 --- a/v2rayN/v2rayN/Mode/Config.cs +++ b/v2rayN/v2rayN/Mode/Config.cs @@ -71,7 +71,7 @@ namespace v2rayN.Mode /// /// 路由模式 /// - public string routingMode + public int routingMode { get; set; } diff --git a/v2rayN/v2rayN/Resx/ResUI.Designer.cs b/v2rayN/v2rayN/Resx/ResUI.Designer.cs index b5b956d6..916fc039 100644 --- a/v2rayN/v2rayN/Resx/ResUI.Designer.cs +++ b/v2rayN/v2rayN/Resx/ResUI.Designer.cs @@ -690,6 +690,42 @@ namespace v2rayN.Resx { } } + /// + /// 查找类似 Bypass CN 的本地化字符串。 + /// + internal static string RoutingModeBypassCN { + get { + return ResourceManager.GetString("RoutingModeBypassCN", resourceCulture); + } + } + + /// + /// 查找类似 Bypass LAN 的本地化字符串。 + /// + internal static string RoutingModeBypassLAN { + get { + return ResourceManager.GetString("RoutingModeBypassLAN", resourceCulture); + } + } + + /// + /// 查找类似 Bypass LAN+CN 的本地化字符串。 + /// + internal static string RoutingModeBypassLANCN { + get { + return ResourceManager.GetString("RoutingModeBypassLANCN", resourceCulture); + } + } + + /// + /// 查找类似 Global 的本地化字符串。 + /// + internal static string RoutingModeGlobal { + get { + return ResourceManager.GetString("RoutingModeGlobal", resourceCulture); + } + } + /// /// 查找类似 The client configuration file is saved at: {0} 的本地化字符串。 /// @@ -708,6 +744,15 @@ namespace v2rayN.Resx { } } + /// + /// 查找类似 ... 的本地化字符串。 + /// + internal static string ServerLatencyChecking { + get { + return ResourceManager.GetString("ServerLatencyChecking", resourceCulture); + } + } + /// /// 查找类似 SlowFresh 的本地化字符串。 /// @@ -789,5 +834,14 @@ namespace v2rayN.Resx { return ResourceManager.GetString("TestMeOutput", resourceCulture); } } + + /// + /// 查找类似 Latency: {0} 的本地化字符串。 + /// + internal static string toolSslServerLatency { + get { + return ResourceManager.GetString("toolSslServerLatency", resourceCulture); + } + } } } diff --git a/v2rayN/v2rayN/Resx/ResUI.resx b/v2rayN/v2rayN/Resx/ResUI.resx index 50d37abe..9066ae09 100644 --- a/v2rayN/v2rayN/Resx/ResUI.resx +++ b/v2rayN/v2rayN/Resx/ResUI.resx @@ -327,12 +327,27 @@ Are you sure to remove the server? + + Bypass CN + + + Bypass LAN + + + Bypass LAN+CN + + + Global + The client configuration file is saved at: {0} The server configuration file is saved at: {0} + + ... + SlowFresh @@ -361,4 +376,7 @@ The ping of current service: {0} + + Latency: {0} + \ No newline at end of file diff --git a/v2rayN/v2rayN/Resx/ResUI.zh-Hans.resx b/v2rayN/v2rayN/Resx/ResUI.zh-Hans.resx index 4b312497..c88b54ae 100644 --- a/v2rayN/v2rayN/Resx/ResUI.zh-Hans.resx +++ b/v2rayN/v2rayN/Resx/ResUI.zh-Hans.resx @@ -327,12 +327,27 @@ 是否确定移除服务器? + + 绕过大陆 + + + 绕过局域网 + + + 绕过局域网和大陆 + + + 路由: 全局 + 客户端配置文件保存在:{0} 服务端配置文件保存在:{0} + + ... + @@ -361,4 +376,7 @@ 当前服务的真连接延迟: {0} + + 延迟: {0} + \ No newline at end of file From f48468029e0b86935d10dc7374d27dcde66f3fb7 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Fri, 17 Apr 2020 14:47:05 +0800 Subject: [PATCH 05/45] Add InterlaceColoring option --- v2rayN/v2rayN/Forms/MainForm.cs | 6 +- .../Forms/OptionSettingForm.Designer.cs | 9 + v2rayN/v2rayN/Forms/OptionSettingForm.cs | 5 +- v2rayN/v2rayN/Forms/OptionSettingForm.resx | 3868 +++++++---------- .../Forms/OptionSettingForm.zh-Hans.resx | 3 + v2rayN/v2rayN/Mode/Config.cs | 8 + 6 files changed, 1656 insertions(+), 2243 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index dec787c1..3178fee1 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -256,14 +256,14 @@ namespace v2rayN.Forms _addSubItem(lvItem, EServerColName.totalUp.ToString(), totalUp); } - if (k % 2 == 1) // 隔行着色 + if (config.interlaceColoring && k % 2 == 1) // 隔行着色 { - lvItem.BackColor = Color.WhiteSmoke; + lvItem.BackColor = SystemColors.Control; } if (config.index.Equals(k)) { //lvItem.Checked = true; - lvItem.ForeColor = Color.DodgerBlue; + lvItem.ForeColor = SystemColors.MenuHighlight; lvItem.Font = new Font(lvItem.Font, FontStyle.Bold); } diff --git a/v2rayN/v2rayN/Forms/OptionSettingForm.Designer.cs b/v2rayN/v2rayN/Forms/OptionSettingForm.Designer.cs index 6f80e585..eca9c7d4 100644 --- a/v2rayN/v2rayN/Forms/OptionSettingForm.Designer.cs +++ b/v2rayN/v2rayN/Forms/OptionSettingForm.Designer.cs @@ -99,6 +99,7 @@ this.panel2 = new System.Windows.Forms.Panel(); this.btnOK = new System.Windows.Forms.Button(); this.panel1 = new System.Windows.Forms.Panel(); + this.chkInterlaceColoring = new System.Windows.Forms.CheckBox(); this.tabControl1.SuspendLayout(); this.tabBasic.SuspendLayout(); this.groupBox1.SuspendLayout(); @@ -512,6 +513,7 @@ // // tabGUI // + this.tabGUI.Controls.Add(this.chkInterlaceColoring); this.tabGUI.Controls.Add(this.chkKeepOlderDedupl); this.tabGUI.Controls.Add(this.cbFreshrate); this.tabGUI.Controls.Add(this.lbFreshrate); @@ -614,6 +616,12 @@ resources.ApplyResources(this.panel1, "panel1"); this.panel1.Name = "panel1"; // + // chkInterlaceColoring + // + resources.ApplyResources(this.chkInterlaceColoring, "chkInterlaceColoring"); + this.chkInterlaceColoring.Name = "chkInterlaceColoring"; + this.chkInterlaceColoring.UseVisualStyleBackColor = true; + // // OptionSettingForm // resources.ApplyResources(this, "$this"); @@ -725,5 +733,6 @@ private System.Windows.Forms.Label label4; private System.Windows.Forms.CheckBox chkKeepOlderDedupl; private System.Windows.Forms.LinkLabel linkLabelRoutingDoc; + private System.Windows.Forms.CheckBox chkInterlaceColoring; } } \ No newline at end of file diff --git a/v2rayN/v2rayN/Forms/OptionSettingForm.cs b/v2rayN/v2rayN/Forms/OptionSettingForm.cs index 5d69093d..f5d87e23 100644 --- a/v2rayN/v2rayN/Forms/OptionSettingForm.cs +++ b/v2rayN/v2rayN/Forms/OptionSettingForm.cs @@ -127,9 +127,7 @@ namespace v2rayN.Forms chkAllowLANConn.Checked = config.allowLANConn; chkEnableStatistics.Checked = config.enableStatistics; chkKeepOlderDedupl.Checked = config.keepOlderDedupl; - - - + chkInterlaceColoring.Checked = config.interlaceColoring; ComboItem[] cbSource = new ComboItem[] { @@ -358,6 +356,7 @@ namespace v2rayN.Forms config.enableStatistics = chkEnableStatistics.Checked; config.statisticsFreshRate = (int)cbFreshrate.SelectedValue; config.keepOlderDedupl = chkKeepOlderDedupl.Checked; + config.interlaceColoring = chkInterlaceColoring.Checked; //if(lastEnableStatistics != config.enableStatistics) //{ diff --git a/v2rayN/v2rayN/Forms/OptionSettingForm.resx b/v2rayN/v2rayN/Forms/OptionSettingForm.resx index 90244957..c3fee9f9 100644 --- a/v2rayN/v2rayN/Forms/OptionSettingForm.resx +++ b/v2rayN/v2rayN/Forms/OptionSettingForm.resx @@ -118,695 +118,62 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - - True - - - 6, 12 - - - 662, 675 - - - 4, 4, 4, 4 - - - OptionSettingForm - - - Settings - - - v2rayN.Forms.BaseForm, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null - 355, 16 - - btnClose - - - panel2 - 75, 23 + 7 &Cancel + + btnClose + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + panel2 + 0 - - 267, 16 - - - btnOK - - - btnOK - - - panel2 - - - panel2 - - - 75, 23 - - - 8 - - - &OK - - - System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 1 - - - 1 - - - Top, Right - - + True - - 322, 10 - - - btnSetDefRountingRule - - - btnSetDefRountingRule - - - panel3 - - - panel3 - - - 229, 23 - - - 18 - - - Set default custom routing rules - - - System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 1 - - - 1 - - - 161, 84 - - - cbFreshrate - - - cbFreshrate - - - tabGUI - - - tabGUI - - - 58, 20 - - - 32 - - - System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 1 - - - 1 - - - True - - - 15, 63 - - - chkAllowIn2 - - - chkAllowIn2 - - - groupBox1 - - - groupBox1 - - - 120, 16 - - - 19 - - - listening port 2 - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - False - - - 7 - - - 7 - - - True - - - 15, 38 - - - chkAllowLANConn - - - chkAllowLANConn - - - tabGUI - - - tabGUI - - - 204, 16 - - - 29 - - - Allow connections from the LAN - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 4 - - - 4 - - - True - - - 15, 16 - - - chkAutoRun - - - chkAutoRun - - - tabGUI - - - tabGUI - - - 246, 16 - - - 23 - - - Automatically start at system startup - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 7 - - - 7 - - - True - - + + NoControl - - 15, 62 + + 42, 98 - - chkEnableStatistics + + 65, 12 - - chkEnableStatistics + + 34 - - tabGUI + + Http proxy - - tabGUI + + label16 - - 576, 16 + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 29 + + groupBox1 - - Enable Statistics (Realtime netspeed and traffic records. Require restart the v2rayN client) - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 3 - - - 3 - - - True - - - 20, 143 - - - chkKcpcongestion - - - chkKcpcongestion - - - tabKCP - - - tabKCP - - - 84, 16 - - - 20 - - - congestion - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - + 0 - - 0 - - - True - - - NoControl - - - 15, 110 - - - chkKeepOlderDedupl - - - chkKeepOlderDedupl - - - tabGUI - - - tabGUI - - - 198, 16 - - - 33 - - - Keep older when deduplication - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 0 - - - 0 - - - True - - - 15, 160 - - - chklogEnabled - - - chklogEnabled - - - groupBox1 - - - groupBox1 - - - 126, 16 - - - 9 - - - Record local logs - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 15 - - - 15 - - - True - - - 15, 129 - - - chkmuxEnabled - - - chkmuxEnabled - - - groupBox1 - - - groupBox1 - - - 174, 16 - - - 20 - - - Turn on Mux Multiplexing - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 6 - - - 6 - - - True - - - NoControl - - - 468, 27 - - - chksniffingEnabled - - - chksniffingEnabled - - - groupBox1 - - - groupBox1 - - - 120, 16 - - - 31 - - - Turn on Sniffing - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 3 - - - 3 - - - True - - - NoControl - - - 468, 60 - - - chksniffingEnabled2 - - - chksniffingEnabled2 - - - groupBox1 - - - groupBox1 - - - 120, 16 - - - 32 - - - Turn on Sniffing - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - False - - - 2 - - - 2 - - - True - - - 369, 27 - - - chkudpEnabled - - - chkudpEnabled - - - groupBox1 - - - groupBox1 - - - 84, 16 - - - 10 - - - Enable UDP - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 14 - - - 14 - - - True - - - 369, 62 - - - chkudpEnabled2 - - - chkudpEnabled2 - - - groupBox1 - - - groupBox1 - - - 84, 16 - - - 18 - - - Enable UDP - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - False - - - 8 - - - 8 - - - AsIs - - - IPIfNonMatch - - - IPOnDemand - - - 115, 10 - - - cmbdomainStrategy - - - cmbdomainStrategy - - - panel3 - - - panel3 - - - 165, 20 - - - 16 - - - System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 3 - - - 3 - Not Enabled Http Proxy @@ -831,36 +198,420 @@ 124, 94 - - cmblistenerType - - - cmblistenerType - - - groupBox1 - - - groupBox1 - 464, 20 33 - - System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + cmblistenerType System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 1 + + groupBox1 1 + + True + + + NoControl + + + 468, 60 + + + 120, 16 + + + 32 + + + Turn on Sniffing + + + False + + + chksniffingEnabled2 + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + groupBox1 + + + 2 + + + True + + + NoControl + + + 468, 27 + + + 120, 16 + + + 31 + + + Turn on Sniffing + + + chksniffingEnabled + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + groupBox1 + + + 3 + + + 33, 228 + + + True + + + 555, 100 + + + 30 + + + txtremoteDNS + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + groupBox1 + + + 4 + + + True + + + 33, 204 + + + 281, 12 + + + 29 + + + Custom DNS (multiple, separated by commas (,)) + + + label14 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + groupBox1 + + + 5 + + + True + + + 15, 129 + + + 174, 16 + + + 20 + + + Turn on Mux Multiplexing + + + chkmuxEnabled + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + groupBox1 + + + 6 + + + True + + + 15, 63 + + + 120, 16 + + + 19 + + + listening port 2 + + + False + + + chkAllowIn2 + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + groupBox1 + + + 7 + + + True + + + 369, 62 + + + 84, 16 + + + 18 + + + Enable UDP + + + False + + + chkudpEnabled2 + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + groupBox1 + + + 8 + + + socks + + + http + + + 257, 60 + + + 97, 20 + + + 17 + + + False + + + cmbprotocol2 + + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + groupBox1 + + + 9 + + + True + + + 206, 64 + + + 53, 12 + + + 16 + + + protocol + + + False + + + label3 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + groupBox1 + + + 10 + + + 124, 60 + + + 78, 21 + + + 14 + + + False + + + txtlocalPort2 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + groupBox1 + + + 11 + + + False + + + socks + + + http + + + 257, 25 + + + 97, 20 + + + 12 + + + cmbprotocol + + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + groupBox1 + + + 12 + + + True + + + 206, 29 + + + 53, 12 + + + 11 + + + protocol + + + label1 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + groupBox1 + + + 13 + + + True + + + 369, 27 + + + 84, 16 + + + 10 + + + Enable UDP + + + chkudpEnabled + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + groupBox1 + + + 14 + + + True + + + 15, 160 + + + 126, 16 + + + 9 + + + Record local logs + + + chklogEnabled + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + groupBox1 + + + 15 + debug @@ -879,119 +630,329 @@ 257, 158 - - cmbloglevel - - - cmbloglevel - - - groupBox1 - - - groupBox1 - 97, 20 6 - - System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + cmbloglevel System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 16 + + groupBox1 16 - - False + + True - - socks + + 193, 162 - - http + + 59, 12 - - 257, 25 + + 8 - - cmbprotocol + + Log level - - cmbprotocol + + label5 - + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + groupBox1 - - groupBox1 - - - 97, 20 - - - 12 - - - System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 12 - - - 12 - - - socks - - - http - - - 257, 60 - - - cmbprotocol2 - - - cmbprotocol2 - - - groupBox1 - - - groupBox1 - - - 97, 20 - - + 17 - - System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 124, 25 - - System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 78, 21 - - False + + 3 - - 9 + + txtlocalPort - - 9 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + groupBox1 + + + 18 + + + True + + + 33, 29 + + + 89, 12 + + + 2 + + + Listening port + + + label2 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + groupBox1 + + + 19 + + + Fill + + + 3, 3 + + + 648, 573 + + + 6 + + + groupBox1 + + + System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabBasic + + + 0 + + + 4, 22 + + + 3, 3, 3, 3 + + + 654, 579 + + + 0 + + + Core: basic settings + + + tabBasic + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabControl1 + + + 0 + + + Fill + + + 3, 3 + + + 0 + + + True + + + Vertical + + + 628, 454 + + + 0 + + + txtUseragent + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabPage3 + + + 0 + + + 4, 22 + + + 3, 3, 3, 3 + + + 634, 460 + + + 0 + + + 1.Proxy Domain or IP + + + tabPage3 + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabControl2 + + + 0 + + + Fill + + + 3, 3 + + + 0 + + + True + + + Vertical + + + 628, 454 + + + 1 + + + txtUserdirect + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabPage4 + + + 0 + + + 4, 22 + + + 3, 3, 3, 3 + + + 634, 460 + + + 1 + + + 2.Direct Domain or IP + + + tabPage4 + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabControl2 + + + 1 + + + Fill + + + 3, 3 + + + 0 + + + True + + + Vertical + + + 628, 454 + + + 1 + + + txtUserblock + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabPage5 + + + 0 + + + 4, 22 + + + 3, 3, 3, 3 + + + 634, 460 + + + 2 + + + 3.Block Domain or IP + + + tabPage5 + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabControl2 + + + 2 Global @@ -1008,651 +969,138 @@ 21, 17 - - cmbroutingMode - - - tabPreDefinedRules - 255, 20 14 + + cmbroutingMode + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + tabPreDefinedRules + 0 - + + 4, 22 + + + 3, 3, 3, 3 + + + 634, 460 + + + 3 + + + 4.Pre-defined rules + + + tabPreDefinedRules + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabControl2 + + + 3 + + Fill - - 3, 3 + + 3, 84 - - groupBox1 + + 642, 486 - - groupBox1 + + 12 - - tabBasic + + tabControl2 - - tabBasic + + System.Windows.Forms.TabControl, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 648, 573 - - - 6 - - - System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 0 - - - 0 - - - Fill - - - 3, 3 - - + groupBox2 - - tabRouting - - - 648, 573 - - - 12 - - - System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - + 0 - + True - - 206, 29 + + 5, 14 - - label1 + + 0, 0, 0, 0 - - label1 - - - groupBox1 - - - groupBox1 - - - 53, 12 - - - 11 - - - protocol - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 13 - - - 13 - - - True - - - 236, 104 - - - label10 - - - label10 - - - tabKCP - - - tabKCP - - + 95, 12 - - 14 - - - writeBufferSize - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 2 - - - 2 - - - True - - - 18, 104 - - - label11 - - - label11 - - - tabKCP - - - tabKCP - - - 89, 12 - - - 12 - - - readBufferSize - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 4 - - - 4 - - - True - - - 30, 176 - - - label13 - - - label13 - - - tabGUI - - - tabGUI - - - 431, 12 - - - 27 - - - Custom GFWList address (please fill in the blank without customization) - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 6 - - - 6 - - - True - - - 33, 204 - - - label14 - - - label14 - - - groupBox1 - - - groupBox1 - - - 281, 12 - - - 29 - - - Custom DNS (multiple, separated by commas (,)) - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 5 - - - 5 - - - True - - - NoControl - - - 42, 98 - - - label16 - - - label16 - - - groupBox1 - - - groupBox1 - - - 65, 12 - - - 34 - - - Http proxy - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 0 - - - 0 - - - True - - - 33, 29 - - - label2 - - - label2 - - - groupBox1 - - - groupBox1 - - - 89, 12 - - - 2 - - - Listening port - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - + 19 - - 19 + + Domain strategy - - True + + linkLabelRoutingDoc - - 206, 64 + + System.Windows.Forms.LinkLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - label3 + + panel3 - - label3 - - - groupBox1 - - - groupBox1 - - - 53, 12 - - - 16 - - - protocol - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - False - - - 10 - - - 10 - - - NoControl - - - 5, 11 - - - label4 - - - label4 - - - panel4 - - - panel4 - - - 598, 16 - - - 13 - - - *Set user pac rules, separated by commas (,) - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - + 0 - - 0 + + Top, Right - + True - - 193, 162 + + 322, 10 - - label5 + + 229, 23 - - label5 + + 18 - - groupBox1 + + Set default custom routing rules - - groupBox1 + + btnSetDefRountingRule - - 59, 12 + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 8 + + panel3 - - Log level - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 17 - - - 17 - - - True - - - 18, 28 - - - label6 - - - label6 - - - tabKCP - - - tabKCP - - - 23, 12 - - - 4 - - - mtu - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 12 - - - 12 - - - True - - - 236, 28 - - - label7 - - - label7 - - - tabKCP - - - tabKCP - - - 23, 12 - - - 6 - - - tti - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 10 - - - 10 - - - True - - - 236, 66 - - - label8 - - - label8 - - - tabKCP - - - tabKCP - - - 101, 12 - - - 10 - - - downlinkCapacity - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 6 - - - 6 - - - True - - - 18, 66 - - - label9 - - - label9 - - - tabKCP - - - tabKCP - - - 89, 12 - - - 8 - - - uplinkCapacity - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 8 - - - 8 + + 1 5, 45 - - labRoutingTips - - - labRoutingTips - - - panel3 - - - panel3 - 598, 16 @@ -1662,16 +1110,544 @@ *Set the rules, separated by commas (,); support Domain (pure string / regular / subdomain) and IP - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + labRoutingTips System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + panel3 + 2 - + + AsIs + + + IPIfNonMatch + + + IPOnDemand + + + 115, 10 + + + 165, 20 + + + 16 + + + cmbdomainStrategy + + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + panel3 + + + 3 + + + Top + + + 3, 17 + + + 642, 67 + + + 19 + + + panel3 + + + System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + groupBox2 + + + 1 + + + Fill + + + 3, 3 + + + 648, 573 + + + 12 + + + groupBox2 + + + System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabRouting + + + 0 + + + 4, 22 + + + 3, 3, 3, 3 + + + 654, 579 + + + 1 + + + Core: Routing settings + + + tabRouting + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabControl1 + + + 1 + + + True + + + 20, 143 + + + 84, 16 + + + 20 + + + congestion + + + chkKcpcongestion + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabKCP + + + 0 + + + 345, 100 + + + 94, 21 + + + 15 + + + txtKcpwriteBufferSize + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabKCP + + + 1 + + + True + + + 236, 104 + + + 95, 12 + + + 14 + + + writeBufferSize + + + label10 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabKCP + + + 2 + + + 111, 100 + + + 94, 21 + + + 13 + + + txtKcpreadBufferSize + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabKCP + + + 3 + + + True + + + 18, 104 + + + 89, 12 + + + 12 + + + readBufferSize + + + label11 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabKCP + + + 4 + + + 345, 62 + + + 94, 21 + + + 11 + + + txtKcpdownlinkCapacity + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabKCP + + + 5 + + + True + + + 236, 66 + + + 101, 12 + + + 10 + + + downlinkCapacity + + + label8 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabKCP + + + 6 + + + 111, 62 + + + 94, 21 + + + 9 + + + txtKcpuplinkCapacity + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabKCP + + + 7 + + + True + + + 18, 66 + + + 89, 12 + + + 8 + + + uplinkCapacity + + + label9 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabKCP + + + 8 + + + 345, 24 + + + 94, 21 + + + 7 + + + txtKcptti + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabKCP + + + 9 + + + True + + + 236, 28 + + + 23, 12 + + + 6 + + + tti + + + label7 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabKCP + + + 10 + + + 111, 24 + + + 94, 21 + + + 5 + + + txtKcpmtu + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabKCP + + + 11 + + + True + + + 18, 28 + + + 23, 12 + + + 4 + + + mtu + + + label6 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabKCP + + + 12 + + + 4, 22 + + + 3, 3, 3, 3 + + + 654, 579 + + + 2 + + + Core: KCP settings + + + tabKCP + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabControl1 + + + 2 + + + True + + + NoControl + + + 15, 132 + + + 132, 16 + + + 34 + + + Interlace coloring + + + chkInterlaceColoring + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabGUI + + + 0 + + + True + + + NoControl + + + 15, 110 + + + 198, 16 + + + 33 + + + Keep older when deduplication + + + chkKeepOlderDedupl + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabGUI + + + 1 + + + 161, 84 + + + 58, 20 + + + 32 + + + cbFreshrate + + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabGUI + + 2 @@ -1683,18 +1659,6 @@ 30, 87 - - lbFreshrate - - - lbFreshrate - - - tabGUI - - - tabGUI - 125, 12 @@ -1704,255 +1668,159 @@ Statistics freshrate - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + lbFreshrate System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 2 + + tabGUI - 2 + 3 - + True - - 5, 14 + + NoControl - - 0, 0, 0, 0 + + 15, 62 - - linkLabelRoutingDoc + + 576, 16 - - linkLabelRoutingDoc + + 29 - - panel3 + + Enable Statistics (Realtime netspeed and traffic records. Require restart the v2rayN client) - - panel3 + + chkEnableStatistics - - 95, 12 + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 19 + + tabGUI - - Domain strategy + + 4 - - System.Windows.Forms.LinkLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + True - - System.Windows.Forms.LinkLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 15, 38 - - 0 + + 204, 16 - - 0 + + 29 - - Top + + Allow connections from the LAN - - 0, 0 + + chkAllowLANConn - - panel1 + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - $this + + tabGUI - - 662, 10 + + 5 - - 9 + + 32, 205 - - System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + True - - 2 + + 541, 100 - - Bottom + + 28 - - 0, 615 + + txturlGFWList - - panel2 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - $this + + tabGUI - - 662, 60 + + 6 - - 11 + + True - - System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 30, 176 - - 1 + + 431, 12 - - Top + + 27 - - 3, 17 + + Custom GFWList address (please fill in the blank without customization) - - panel3 + + label13 - - groupBox2 + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 642, 67 + + tabGUI - - 19 + + 7 - - System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + True - - 1 + + 15, 16 - - Top + + 246, 16 - - 3, 3 + + 23 - - panel4 + + Automatically start at system startup - - panel4 + + chkAutoRun - - tabUserPAC + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tabUserPAC + + tabGUI - - 648, 37 - - - 20 - - - System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 1 - - - 1 - - - 4, 22 - - - tabBasic - - - 3, 3, 3, 3 - - - tabControl1 - - - 654, 579 - - - 0 - - - Core: basic settings - - - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 0 - - - Fill - - - 0, 10 - - - tabControl1 - - - $this - - - 662, 605 - - - 10 - - - System.Windows.Forms.TabControl, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 0 - - - Fill - - - 3, 84 - - - tabControl2 - - - groupBox2 - - - 642, 486 - - - 12 - - - System.Windows.Forms.TabControl, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 0 + + 8 4, 22 - - tabGUI - 3, 3, 3, 3 - - tabControl1 - 654, 579 @@ -1962,675 +1830,18 @@ v2rayN settings + + tabGUI + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + tabControl1 + 3 - - 4, 22 - - - tabKCP - - - 3, 3, 3, 3 - - - tabControl1 - - - 654, 579 - - - 2 - - - Core: KCP settings - - - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 2 - - - 4, 22 - - - tabPage3 - - - 3, 3, 3, 3 - - - tabControl2 - - - 634, 460 - - - 0 - - - 1.Proxy Domain or IP - - - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 0 - - - 4, 22 - - - tabPage4 - - - 3, 3, 3, 3 - - - tabControl2 - - - 634, 460 - - - 1 - - - 2.Direct Domain or IP - - - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 1 - - - 4, 22 - - - tabPage5 - - - 3, 3, 3, 3 - - - tabControl2 - - - 634, 460 - - - 2 - - - 3.Block Domain or IP - - - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 2 - - - 4, 22 - - - tabPreDefinedRules - - - 3, 3, 3, 3 - - - tabControl2 - - - 634, 460 - - - 3 - - - 4.Pre-defined rules - - - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 3 - - - 4, 22 - - - tabRouting - - - 3, 3, 3, 3 - - - tabControl1 - - - 654, 579 - - - 1 - - - Core: Routing settings - - - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 1 - - - 4, 22 - - - tabUserPAC - - - 3, 3, 3, 3 - - - tabControl1 - - - 654, 579 - - - 4 - - - User PAC settings - - - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 4 - - - 345, 62 - - - txtKcpdownlinkCapacity - - - txtKcpdownlinkCapacity - - - tabKCP - - - tabKCP - - - 94, 21 - - - 11 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 5 - - - 5 - - - 111, 24 - - - txtKcpmtu - - - txtKcpmtu - - - tabKCP - - - tabKCP - - - 94, 21 - - - 5 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 11 - - - 11 - - - 111, 100 - - - txtKcpreadBufferSize - - - txtKcpreadBufferSize - - - tabKCP - - - tabKCP - - - 94, 21 - - - 13 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 3 - - - 3 - - - 345, 24 - - - txtKcptti - - - txtKcptti - - - tabKCP - - - tabKCP - - - 94, 21 - - - 7 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 9 - - - 9 - - - 111, 62 - - - txtKcpuplinkCapacity - - - txtKcpuplinkCapacity - - - tabKCP - - - tabKCP - - - 94, 21 - - - 9 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 7 - - - 7 - - - 345, 100 - - - txtKcpwriteBufferSize - - - txtKcpwriteBufferSize - - - tabKCP - - - tabKCP - - - 94, 21 - - - 15 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 1 - - - 1 - - - 124, 25 - - - txtlocalPort - - - txtlocalPort - - - groupBox1 - - - groupBox1 - - - 78, 21 - - - 3 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 18 - - - 18 - - - 124, 60 - - - txtlocalPort2 - - - txtlocalPort2 - - - groupBox1 - - - groupBox1 - - - 78, 21 - - - 14 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - False - - - 11 - - - 11 - - - 33, 228 - - - True - - - txtremoteDNS - - - txtremoteDNS - - - groupBox1 - - - groupBox1 - - - 555, 100 - - - 30 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 4 - - - 4 - - - 32, 205 - - - True - - - txturlGFWList - - - txturlGFWList - - - tabGUI - - - tabGUI - - - 541, 100 - - - 28 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 5 - - - 5 - - - Fill - - - 3, 3 - - - 0 - - - True - - - txtUseragent - - - txtUseragent - - - tabPage3 - - - tabPage3 - - - Vertical - - - 628, 454 - - - 0 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 0 - - - 0 - - - Fill - - - 3, 3 - - - 0 - - - True - - - txtUserblock - - - txtUserblock - - - tabPage5 - - - tabPage5 - - - Vertical - - - 628, 454 - - - 1 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 0 - - - 0 - - - Fill - - - 3, 3 - - - 0 - - - True - - - txtUserdirect - - - txtUserdirect - - - tabPage4 - - - tabPage4 - - - Vertical - - - 628, 454 - - - 1 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 0 - - - 0 - Fill @@ -2643,18 +1854,6 @@ True - - txtuserPacRule - - - txtuserPacRule - - - tabUserPAC - - - tabUserPAC - Vertical @@ -2664,16 +1863,211 @@ 21 - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + txtuserPacRule System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 0 + + tabUserPAC 0 + + NoControl + + + 5, 11 + + + 598, 16 + + + 13 + + + *Set user pac rules, separated by commas (,) + + + label4 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + panel4 + + + 0 + + + Top + + + 3, 3 + + + 648, 37 + + + 20 + + + panel4 + + + System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabUserPAC + + + 1 + + + 4, 22 + + + 3, 3, 3, 3 + + + 654, 579 + + + 4 + + + User PAC settings + + + tabUserPAC + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tabControl1 + + + 4 + + + Fill + + + 0, 10 + + + 662, 605 + + + 10 + + + tabControl1 + + + System.Windows.Forms.TabControl, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + $this + + + 0 + + + 267, 16 + + + 75, 23 + + + 8 + + + &OK + + + btnOK + + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + panel2 + + + 1 + + + Bottom + + + 0, 615 + + + 662, 60 + + + 11 + + + panel2 + + + System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + $this + + + 1 + + + Top + + + 0, 0 + + + 662, 10 + + + 9 + + + panel1 + + + System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + $this + + + 2 + + + True + + + 6, 12 + + + 662, 675 + + + 4, 4, 4, 4 + + + Settings + + + OptionSettingForm + + + v2rayN.Forms.BaseForm, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + \ No newline at end of file diff --git a/v2rayN/v2rayN/Forms/OptionSettingForm.zh-Hans.resx b/v2rayN/v2rayN/Forms/OptionSettingForm.zh-Hans.resx index b2ecd834..b45cc3c5 100644 --- a/v2rayN/v2rayN/Forms/OptionSettingForm.zh-Hans.resx +++ b/v2rayN/v2rayN/Forms/OptionSettingForm.zh-Hans.resx @@ -164,6 +164,9 @@ 启用统计(实时网速显示和使用流量显示,需要重启v2rayN客户端) + + 隔行着色 + 去重时保留序号较小的项 diff --git a/v2rayN/v2rayN/Mode/Config.cs b/v2rayN/v2rayN/Mode/Config.cs index d48da6ee..0e213609 100644 --- a/v2rayN/v2rayN/Mode/Config.cs +++ b/v2rayN/v2rayN/Mode/Config.cs @@ -162,6 +162,14 @@ namespace v2rayN.Mode get; set; } + /// + /// 服务器列表隔行着色 + /// + public bool interlaceColoring + { + get; set; + } + /// /// 视图刷新率 /// From 5b3f09aaf771cf5695e1322f7ae7f63c5349a2f0 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Fri, 17 Apr 2020 15:27:09 +0800 Subject: [PATCH 06/45] refine UserPAC setting --- v2rayN/v2rayN/Forms/OptionSettingForm.cs | 2 +- v2rayN/v2rayN/Forms/OptionSettingForm.zh-Hans.resx | 2 +- v2rayN/v2rayN/Tool/Utils.cs | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/v2rayN/v2rayN/Forms/OptionSettingForm.cs b/v2rayN/v2rayN/Forms/OptionSettingForm.cs index f5d87e23..1d4394a8 100644 --- a/v2rayN/v2rayN/Forms/OptionSettingForm.cs +++ b/v2rayN/v2rayN/Forms/OptionSettingForm.cs @@ -373,7 +373,7 @@ namespace v2rayN.Forms private int SaveUserPAC() { string userPacRule = txtuserPacRule.Text.TrimEx(); - userPacRule = userPacRule.Replace("\"", ""); + userPacRule = userPacRule.Replace("\"", "").Replace("'", ""); config.userPacRule = Utils.String2List(userPacRule); diff --git a/v2rayN/v2rayN/Forms/OptionSettingForm.zh-Hans.resx b/v2rayN/v2rayN/Forms/OptionSettingForm.zh-Hans.resx index b45cc3c5..293a96d7 100644 --- a/v2rayN/v2rayN/Forms/OptionSettingForm.zh-Hans.resx +++ b/v2rayN/v2rayN/Forms/OptionSettingForm.zh-Hans.resx @@ -282,7 +282,7 @@ 协议 - *设置用户PAC规则,用逗号(,)隔开 + *用户PAC内的自定条目。用逗号(,)或换行隔开的匹配模式(pattern)。英文单引号、双引号将被忽略。 53, 12 diff --git a/v2rayN/v2rayN/Tool/Utils.cs b/v2rayN/v2rayN/Tool/Utils.cs index 09c023de..06dc979b 100644 --- a/v2rayN/v2rayN/Tool/Utils.cs +++ b/v2rayN/v2rayN/Tool/Utils.cs @@ -168,7 +168,7 @@ namespace v2rayN } } /// - /// 逗号分隔的字符串,转List + /// 换行或逗号分隔的字符串,转List /// /// /// @@ -176,7 +176,7 @@ namespace v2rayN { try { - str = str.Replace(Environment.NewLine, ""); + str = str.Replace("\r", ",").Replace("\n", ","); // 用户复制的可能是\r、\n或\r\n return new List(str.Split(new string[] { "," }, StringSplitOptions.RemoveEmptyEntries)); } catch From a0b0ad53d211c418590099ac83545e3359f48ca3 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Fri, 17 Apr 2020 08:49:12 +0800 Subject: [PATCH 07/45] RefreshTaryIcon while DisplaySettingsChanged --- v2rayN/v2rayN/Forms/MainForm.cs | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 3178fee1..87324743 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -55,6 +55,8 @@ namespace v2rayN.Forms { statistics = new StatisticsHandler(config, UpdateStatisticsHandler); } + + Microsoft.Win32.SystemEvents.DisplaySettingsChanged += new EventHandler(SystemEvents_DisplaySettingsChanged); } private void MainForm_VisibleChanged(object sender, EventArgs e) @@ -342,6 +344,10 @@ namespace v2rayN.Forms //qrCodeControl.showQRCode(index, config); } + private void RefreshTaryIcon() + { + notifyMain.Icon = MainFormHandler.Instance.GetNotifyIcon(config, this.Icon); + } private void DisplayToolStatus() { toolSslSocksPort.Text = @@ -386,7 +392,7 @@ namespace v2rayN.Forms } toolSslRouting.Text = routingStatus; - notifyMain.Icon = MainFormHandler.Instance.GetNotifyIcon(config, this.Icon); + RefreshTaryIcon(); } private void ssMain_ItemClicked(object sender, ToolStripItemClickedEventArgs e) { @@ -1602,7 +1608,12 @@ namespace v2rayN.Forms } + #endregion + private void SystemEvents_DisplaySettingsChanged(object sender, EventArgs e) + { + RefreshTaryIcon(); + } From 1e088f851b4306d0e97b33300ba05e6da6f9f1b4 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Fri, 17 Apr 2020 16:29:25 +0800 Subject: [PATCH 08/45] resort --- v2rayN/v2rayN/Forms/MainForm.resx | 2204 +++++++------- v2rayN/v2rayN/Forms/OptionSettingForm.resx | 3040 ++++++++++---------- 2 files changed, 2622 insertions(+), 2622 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.resx b/v2rayN/v2rayN/Forms/MainForm.resx index 86cd8eef..552aebaa 100644 --- a/v2rayN/v2rayN/Forms/MainForm.resx +++ b/v2rayN/v2rayN/Forms/MainForm.resx @@ -118,193 +118,131 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - Fill - - - 3, 17 - 327, 17 - - 355, 22 + + + 17, 17 + + + 137, 17 + + + 498, 17 + + + 228, 18 + + + 409, 17 + + + True + + + 108 + + + 6, 12 - - Add [VMess] server + + 952, 593 - - 355, 22 + + 4, 4, 4, 4 - - Add [Shadowsocks] server + + MainForm - - 355, 22 + + v2rayN - - Add [Socks] server + + v2rayN.Forms.BaseForm, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null - - 355, 22 + + bgwScan - - Add a custom configuration server - - - 355, 22 - - - Import bulk URL from clipboard (Ctrl+V) - - - 355, 22 - - - Scan QR code on the screen (Ctrl+S) - - - 352, 6 - - - 355, 22 - - - Remove selected servers (Delete) - - - 355, 22 - - - Remove duplicate servers - - - 355, 22 - - - Clone selected server - - - 355, 22 - - - Set as active server (Enter) - - - 352, 6 - - - 355, 22 - - - Move to top (T) - - - 355, 22 - - - Up (U) - - - 355, 22 - - - Down (D) - - - 355, 22 - - - Move to bottom (B) - - - 355, 22 - - - Select All (Ctrl+A) - - - 352, 6 - - - 355, 22 - - - Test servers ping (Ctrl+P) - - - 355, 22 - - - Test servers with tcping (Ctrl+O) - - - 355, 22 - - - Test servers real delay (Ctrl+R) - - - 355, 22 - - - Test servers download speed (Ctrl+T) - - - 355, 22 - - - Test current service status - - - 352, 6 - - - 355, 22 - - - Export selected server for client configuration - - - 355, 22 - - - Export selected server for server configuration - - - 355, 22 - - - Export share URLs to clipboard (Ctrl+C) - - - 355, 22 - - - Export subscription (base64) share to clipboard - - - Magenta - - - 64, 53 - - - Servers - - - ImageAboveText - - - 356, 556 + + System.ComponentModel.BackgroundWorker, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 cmsLv + + 356, 556 + System.Windows.Forms.ContextMenuStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + NoControl + + + cmsMain + + + 265, 164 + + + System.Windows.Forms.ContextMenuStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + Fill + + + 0, 66 + + + groupBox1 + + + $this + + + 952, 351 + + + 0 + + + Servers list + + + System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 2 + + + Bottom + + + 0, 417 + + + groupBox2 + + + $this + + + 952, 176 + + + 3 + + + Informations + + + System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 3 + Fill @@ -328,36 +266,515 @@ 0, 0 - - 686, 331 - - - - 0 - lvServers - - v2rayN.Base.ListViewFlickerFree, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null - scMain.Panel1 + + 686, 331 + + + 0 + + + v2rayN.Base.ListViewFlickerFree, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + 0 - - scMain.Panel1 + + menuAddCustomServer - - System.Windows.Forms.SplitterPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 355, 22 - - scMain + + Add a custom configuration server - - 0 + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuAddServers + + + 355, 22 + + + Import bulk URL from clipboard (Ctrl+V) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuAddServers2 + + + 264, 22 + + + Import bulk URL from clipboard + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuAddShadowsocksServer + + + 355, 22 + + + Add [Shadowsocks] server + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuAddSocksServer + + + 355, 22 + + + Add [Socks] server + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuAddVmessServer + + + 355, 22 + + + Add [VMess] server + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuCopyPACUrl + + + 264, 22 + + + Copy local PAC URL + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuCopyServer + + + 355, 22 + + + Clone selected server + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuExit + + + 264, 22 + + + Exit + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuExport2ClientConfig + + + 355, 22 + + + Export selected server for client configuration + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuExport2ServerConfig + + + 355, 22 + + + Export selected server for server configuration + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuExport2ShareUrl + + + 355, 22 + + + Export share URLs to clipboard (Ctrl+C) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuExport2SubContent + + + 355, 22 + + + Export subscription (base64) share to clipboard + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuGlobal + + + 411, 22 + + + Open Http proxy and set the system proxy (global mode) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuGlobalPAC + + + 411, 22 + + + Open PAC and set the system proxy (PAC mode) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuKeep + + + 411, 22 + + + Only open Http proxy and clear the proxy settings + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuKeepNothing + + + 411, 22 + + + Only open Http proxy and do nothing + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuKeepPAC + + + 411, 22 + + + Only open PAC and clear the proxy settings + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuKeepPACNothing + + + 411, 22 + + + Only open PAC and do nothing + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuMoveBottom + + + 355, 22 + + + Move to bottom (B) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuMoveDown + + + 355, 22 + + + Down (D) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuMoveTop + + + 355, 22 + + + Move to top (T) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuMoveUp + + + 355, 22 + + + Up (U) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuNotEnabledHttp + + + 411, 22 + + + Not Enabled Http Proxy + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuPingServer + + + 355, 22 + + + Test servers ping (Ctrl+P) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuRealPingServer + + + 355, 22 + + + Test servers real delay (Ctrl+R) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuRemoveDuplicateServer + + + 355, 22 + + + Remove duplicate servers + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuRemoveServer + + + 355, 22 + + + Remove selected servers (Delete) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuScanScreen + + + 355, 22 + + + Scan QR code on the screen (Ctrl+S) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuScanScreen2 + + + 264, 22 + + + Scan QR code on the screen + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuSelectAll + + + 355, 22 + + + Select All (Ctrl+A) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuServers + + + 264, 22 + + + Server + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuSetDefaultServer + + + 355, 22 + + + Set as active server (Enter) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuSpeedServer + + + 355, 22 + + + Test servers download speed (Ctrl+T) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuSysAgentMode + + + 264, 22 + + + Http proxy + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuTcpingServer + + + 355, 22 + + + Test servers with tcping (Ctrl+O) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuTestMe + + + 355, 22 + + + Test current service status + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + menuUpdateSubscriptions + + + 264, 22 + + + Update subscriptions + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + notifyMain + + + v2rayN + + + System.Windows.Forms.NotifyIcon, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + True + + + Top + + + 0, 56 + + + panel1 + + + $this + + + 952, 10 + + + 2 + + + System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 4 Fill @@ -365,39 +782,63 @@ 0, 0 + + qrCodeControl + + + scMain.Panel2 + 256, 331 2 - - qrCodeControl - v2rayN.Forms.QRCodeControl, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null - - scMain.Panel2 - 0 + + Fill + + + 3, 17 + + + scMain + + + scMain.Panel1 + + + scMain + + + System.Windows.Forms.SplitterPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + scMain.Panel2 - - System.Windows.Forms.SplitterPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - scMain + + System.Windows.Forms.SplitterPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + 1 100 + + groupBox1 + 946, 331 @@ -407,261 +848,150 @@ 0 - - scMain - System.Windows.Forms.SplitContainer, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - groupBox1 - 0 - - 17, 17 - - - 137, 17 - - - NoControl + + 3, 151 - - 265, 164 + + ssMain - - cmsMain - - - System.Windows.Forms.ContextMenuStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - v2rayN - - - True - - - 264, 22 - - - Http proxy - - - 411, 22 - - - Not Enabled Http Proxy - - - 411, 22 - - - Open Http proxy and set the system proxy (global mode) - - - 411, 22 - - - Open PAC and set the system proxy (PAC mode) - - - 411, 22 - - - Only open Http proxy and clear the proxy settings - - - 411, 22 - - - Only open PAC and clear the proxy settings - - - 411, 22 - - - Only open Http proxy and do nothing - - - 411, 22 - - - Only open PAC and do nothing - - - 264, 22 - - - Server - - - 264, 22 - - - Import bulk URL from clipboard - - - 264, 22 - - - Scan QR code on the screen - - - 264, 22 - - - Copy local PAC URL - - - 264, 22 - - - Update subscriptions - - - 261, 6 - - - 264, 22 - - - Exit - - - 498, 17 - - - Fill - - - 0, 66 - - - 952, 351 - - - 0 - - - Servers list - - - groupBox1 - - - System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - $this - - - 2 - - - Fill - - - 3, 17 - - - 0 - - - True - - - Vertical - - - 946, 134 - - - 3 - - - txtMsgBox - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - + groupBox2 - + + 946, 22 + + 0 - - 228, 18 - - - 微软雅黑, 8pt + + statusStrip1 - - 52, 17 + + System.Windows.Forms.StatusStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - SOCKS5: - - - 0, 17 + + 1 微软雅黑, 8pt + + toolSslBlank1 + 137, 17 + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 微软雅黑, 8pt + + + toolSslBlank2 + + + 137, 17 + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 微软雅黑, 8pt + + + toolSslBlank3 + + + 137, 17 + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslBlank4 + + + 0, 17 + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslHttpPort + + + 0, 17 + + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + 微软雅黑, 8pt + + toolSslHttpPortLab + 39, 17 HTTP: - + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslPacPort + + 0, 17 - - 微软雅黑, 8pt - - - 137, 17 + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 微软雅黑, 8pt + + toolSslPacPortLab + 33, 17 PAC: - - 0, 17 - - - 微软雅黑, 8pt - - - 137, 17 + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 False + + toolSslRouting + 129, 17 Routing Mode + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + False + + toolSslServerLatency + 137, 17 @@ -674,9 +1004,15 @@ The http proxy's latency time. + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + 微软雅黑, 8pt + + toolSslServerSpeed + No @@ -689,138 +1025,337 @@ MiddleRight - + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolSslSocksPort + + 0, 17 - - 3, 151 + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 946, 22 + + 微软雅黑, 8pt - - 0 + + toolSslSocksPortLab - - statusStrip1 + + 52, 17 - - ssMain + + SOCKS5: - - System.Windows.Forms.StatusStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - groupBox2 + + toolStripSeparator1 - - 1 + + 352, 6 - - Bottom + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 0, 417 + + toolStripSeparator10 - - 952, 176 + + 6, 56 - - 3 + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - Informations + + toolStripSeparator11 - - groupBox2 + + 6, 56 - - System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - $this + + toolStripSeparator12 - - 3 + + 184, 6 - - Top + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 0, 56 + + toolStripSeparator13 - - 952, 10 + + 390, 6 - - 2 + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - panel1 + + toolStripSeparator2 - - System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 261, 6 - - $this + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 4 + + toolStripSeparator3 - - 409, 17 - - - 0, 0 + + 352, 6 - - 952, 56 + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 1 - - - tsMain - - - System.Windows.Forms.ToolStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - $this - - - 5 + + toolStripSeparator4 6, 56 - + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator5 + + + 6, 56 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator6 + + + 352, 6 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator7 + + + 6, 56 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator8 + + + 6, 56 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + toolStripSeparator9 + + + 352, 6 + + + System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbAbout + + + 187, 22 + + + v2rayN Project + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbCheckClearPACList + + + 393, 22 + + + Simplify PAC (need to set Core route) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + Magenta - - 99, 53 + + tsbCheckUpdate - - Subscriptions + + 128, 53 - + + Check for updates + + ImageAboveText - - 125, 22 + + System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - + + tsbCheckUpdateCore + + + 393, 22 + + + Update v2rayCore + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbCheckUpdateN + + + 393, 22 + + + v2rayN (this software) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbCheckUpdatePACList + + + 393, 22 + + + Check for updated PAC (need the HTTP proxy are ON) + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + + iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8 + YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAySURBVFhH7c6xDQAgCEVBRnVTHU2ZABuMxV3yOvJDAAA/ + GqfZVG6X8mg1dfUAAPBQxAZd0SJruVXHWwAAAABJRU5ErkJggg== + + + + Magenta + + + tsbClose + + + 52, 53 + + + Close + + + ImageAboveText + + + System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + Magenta + + + tsbHelp + + + 48, 53 + + + Help + + + ImageAboveText + + + System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbLanguageDef + + + 187, 22 + + + Language-[English] + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + tsbLanguageZhHans + + + 187, 22 + + + 语言-[中文简体] + + + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + Magenta + + + tsbOptionSetting + + + 58, 53 + + Settings - - 125, 22 + + ImageAboveText - - Updates + + System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + Magenta + + + tsbPromotion + + + 89, 53 + + + Promotion + + + ImageAboveText + + + System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 Magenta + + tsbQRCodeSwitch + 45, 53 @@ -833,23 +1368,8 @@ ImageAboveText - - 6, 56 - - - Magenta - - - 58, 53 - - - Settings - - - ImageAboveText - - - 6, 56 + + System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -868,6 +1388,9 @@ Magenta + + tsbReload + 97, 53 @@ -877,656 +1400,133 @@ ImageAboveText - - 6, 56 + + System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - + Magenta - - 128, 53 - - - Check for updates - - - ImageAboveText - - - 393, 22 - - - v2rayN (this software) - - - 393, 22 - - - Update v2rayCore - - - 393, 22 - - - Check for updated PAC (need the HTTP proxy are ON) - - - 390, 6 - - - 393, 22 - - - Simplify PAC (need to set Core route) - - - 6, 56 - - - Magenta - - - 48, 53 - - - Help - - - ImageAboveText - - - 187, 22 - - - v2rayN Project - - - 187, 22 - - - V2Ray Website - - - 184, 6 - - - 187, 22 - - - Language-[English] - - - 187, 22 - - - 语言-[中文简体] - - - Magenta - - - 89, 53 - - - Promotion - - - ImageAboveText - - - 6, 56 - - - - iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8 - YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAySURBVFhH7c6xDQAgCEVBRnVTHU2ZABuMxV3yOvJDAAA/ - GqfZVG6X8mg1dfUAAPBQxAZd0SJruVXHWwAAAABJRU5ErkJggg== - - - - Magenta - - - 52, 53 - - - Close - - - ImageAboveText - - - True - - - 108 - - - 6, 12 - - - 952, 593 - - - 4, 4, 4, 4 - - - v2rayN - - - menuAddVmessServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuAddShadowsocksServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuAddSocksServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuAddCustomServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuAddServers - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuScanScreen - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator1 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuRemoveServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuRemoveDuplicateServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuCopyServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuSetDefaultServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator3 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuMoveTop - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuMoveUp - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuMoveDown - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuMoveBottom - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuSelectAll - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator9 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuPingServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuTcpingServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuRealPingServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuSpeedServer - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuTestMe - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator6 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuExport2ClientConfig - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuExport2ServerConfig - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuExport2ShareUrl - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuExport2SubContent - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - tsbServer + + 64, 53 + + + Servers + + + ImageAboveText + System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - notifyMain - - - System.Windows.Forms.NotifyIcon, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuSysAgentMode - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuNotEnabledHttp - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuGlobal - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuGlobalPAC - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuKeep - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuKeepPAC - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuKeepNothing - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuKeepPACNothing - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuServers - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuAddServers2 - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuScanScreen2 - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuCopyPACUrl - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuUpdateSubscriptions - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator2 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - menuExit - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - bgwScan - - - System.ComponentModel.BackgroundWorker, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslSocksPortLab - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslSocksPort - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslBlank1 - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslHttpPortLab - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslHttpPort - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslBlank2 - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslPacPortLab - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslPacPort - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslBlank3 - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslRouting - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslServerLatency - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslServerSpeed - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolSslBlank4 - - - System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator4 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + Magenta tsbSub + + 99, 53 + + + Subscriptions + + + ImageAboveText + System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 tsbSubSetting + + 125, 22 + + + Settings + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 tsbSubUpdate + + 125, 22 + + + Updates + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tsbQRCodeSwitch - - - System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator8 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbOptionSetting - - - System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator5 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbReload - - - System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator7 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbCheckUpdate - - - System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbCheckUpdateN - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbCheckUpdateCore - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbCheckUpdatePACList - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator13 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbCheckClearPACList - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - toolStripSeparator10 - - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbHelp - - - System.Windows.Forms.ToolStripDropDownButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tsbAbout - - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - tsbV2rayWebsite + + 187, 22 + + + V2Ray Website + System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - toolStripSeparator12 + + 0, 0 - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + tsMain - - tsbLanguageDef + + $this - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 952, 56 - - tsbLanguageZhHans + + 1 - - System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.ToolStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tsbPromotion + + 5 - - System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + Fill - - toolStripSeparator11 + + 3, 17 - - System.Windows.Forms.ToolStripSeparator, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 0 - - tsbClose + + True - - System.Windows.Forms.ToolStripButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + txtMsgBox - - MainForm + + groupBox2 - - v2rayN.Forms.BaseForm, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + + Vertical + + + 946, 134 + + + 3 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 \ No newline at end of file diff --git a/v2rayN/v2rayN/Forms/OptionSettingForm.resx b/v2rayN/v2rayN/Forms/OptionSettingForm.resx index c3fee9f9..ea494864 100644 --- a/v2rayN/v2rayN/Forms/OptionSettingForm.resx +++ b/v2rayN/v2rayN/Forms/OptionSettingForm.resx @@ -118,62 +118,533 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + + True + + + 6, 12 + + + 662, 675 + + + 4, 4, 4, 4 + + + OptionSettingForm + + + Settings + + + v2rayN.Forms.BaseForm, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null + 355, 16 + + btnClose + + + panel2 + 75, 23 - 7 &Cancel - - btnClose - System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - panel2 - 0 - + + 267, 16 + + + btnOK + + + panel2 + + + 75, 23 + + + 8 + + + &OK + + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 1 + + + Top, Right + + True - - - NoControl + + 322, 10 - - 42, 98 + + btnSetDefRountingRule - - 65, 12 + + panel3 - - 34 + + 229, 23 - - Http proxy + + 18 - - label16 + + Set default custom routing rules - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - + + 1 + + + 161, 84 + + + cbFreshrate + + + tabGUI + + + 58, 20 + + + 32 + + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 2 + + + True + + + 15, 63 + + + chkAllowIn2 + + groupBox1 - + + 120, 16 + + + 19 + + + listening port 2 + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + False + + + 7 + + + True + + + 15, 38 + + + chkAllowLANConn + + + tabGUI + + + 204, 16 + + + 29 + + + Allow connections from the LAN + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 5 + + + True + + + 15, 16 + + + chkAutoRun + + + tabGUI + + + 246, 16 + + + 23 + + + Automatically start at system startup + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 8 + + + True + + + NoControl + + + 15, 62 + + + chkEnableStatistics + + + tabGUI + + + 576, 16 + + + 29 + + + Enable Statistics (Realtime netspeed and traffic records. Require restart the v2rayN client) + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 4 + + + True + + + NoControl + + + 15, 132 + + + chkInterlaceColoring + + + tabGUI + + + 132, 16 + + + 34 + + + Interlace coloring + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 0 + + True + + + 20, 143 + + + chkKcpcongestion + + + tabKCP + + + 84, 16 + + + 20 + + + congestion + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + + + True + + + NoControl + + + 15, 110 + + + chkKeepOlderDedupl + + + tabGUI + + + 198, 16 + + + 33 + + + Keep older when deduplication + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 1 + + + True + + + 15, 160 + + + chklogEnabled + + + groupBox1 + + + 126, 16 + + + 9 + + + Record local logs + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 15 + + + True + + + 15, 129 + + + chkmuxEnabled + + + groupBox1 + + + 174, 16 + + + 20 + + + Turn on Mux Multiplexing + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 6 + + + True + + + NoControl + + + 468, 27 + + + chksniffingEnabled + + + groupBox1 + + + 120, 16 + + + 31 + + + Turn on Sniffing + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 3 + + + True + + + NoControl + + + 468, 60 + + + chksniffingEnabled2 + + + groupBox1 + + + 120, 16 + + + 32 + + + Turn on Sniffing + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + False + + + 2 + + + True + + + 369, 27 + + + chkudpEnabled + + + groupBox1 + + + 84, 16 + + + 10 + + + Enable UDP + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 14 + + + True + + + 369, 62 + + + chkudpEnabled2 + + + groupBox1 + + + 84, 16 + + + 18 + + + Enable UDP + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + False + + + 8 + + + AsIs + + + IPIfNonMatch + + + IPOnDemand + + + 115, 10 + + + cmbdomainStrategy + + + panel3 + + + 165, 20 + + + 16 + + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 3 + Not Enabled Http Proxy @@ -198,420 +669,24 @@ 124, 94 + + cmblistenerType + + + groupBox1 + 464, 20 33 - - cmblistenerType - System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - groupBox1 - 1 - - True - - - NoControl - - - 468, 60 - - - 120, 16 - - - 32 - - - Turn on Sniffing - - - False - - - chksniffingEnabled2 - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - groupBox1 - - - 2 - - - True - - - NoControl - - - 468, 27 - - - 120, 16 - - - 31 - - - Turn on Sniffing - - - chksniffingEnabled - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - groupBox1 - - - 3 - - - 33, 228 - - - True - - - 555, 100 - - - 30 - - - txtremoteDNS - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - groupBox1 - - - 4 - - - True - - - 33, 204 - - - 281, 12 - - - 29 - - - Custom DNS (multiple, separated by commas (,)) - - - label14 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - groupBox1 - - - 5 - - - True - - - 15, 129 - - - 174, 16 - - - 20 - - - Turn on Mux Multiplexing - - - chkmuxEnabled - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - groupBox1 - - - 6 - - - True - - - 15, 63 - - - 120, 16 - - - 19 - - - listening port 2 - - - False - - - chkAllowIn2 - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - groupBox1 - - - 7 - - - True - - - 369, 62 - - - 84, 16 - - - 18 - - - Enable UDP - - - False - - - chkudpEnabled2 - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - groupBox1 - - - 8 - - - socks - - - http - - - 257, 60 - - - 97, 20 - - - 17 - - - False - - - cmbprotocol2 - - - System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - groupBox1 - - - 9 - - - True - - - 206, 64 - - - 53, 12 - - - 16 - - - protocol - - - False - - - label3 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - groupBox1 - - - 10 - - - 124, 60 - - - 78, 21 - - - 14 - - - False - - - txtlocalPort2 - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - groupBox1 - - - 11 - - - False - - - socks - - - http - - - 257, 25 - - - 97, 20 - - - 12 - - - cmbprotocol - - - System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - groupBox1 - - - 12 - - - True - - - 206, 29 - - - 53, 12 - - - 11 - - - protocol - - - label1 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - groupBox1 - - - 13 - - - True - - - 369, 27 - - - 84, 16 - - - 10 - - - Enable UDP - - - chkudpEnabled - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - groupBox1 - - - 14 - - - True - - - 15, 160 - - - 126, 16 - - - 9 - - - Record local logs - - - chklogEnabled - - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - groupBox1 - - - 15 - debug @@ -630,329 +705,83 @@ 257, 158 + + cmbloglevel + + + groupBox1 + 97, 20 6 - - cmbloglevel - System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - groupBox1 - 16 - - True + + False - - 193, 162 + + socks - - 59, 12 + + http - - 8 + + 257, 25 - - Log level + + cmbprotocol - - label5 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - + groupBox1 - + + 97, 20 + + + 12 + + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 12 + + + socks + + + http + + + 257, 60 + + + cmbprotocol2 + + + groupBox1 + + + 97, 20 + + 17 - - 124, 25 + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 78, 21 + + False - - 3 - - - txtlocalPort - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - groupBox1 - - - 18 - - - True - - - 33, 29 - - - 89, 12 - - - 2 - - - Listening port - - - label2 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - groupBox1 - - - 19 - - - Fill - - - 3, 3 - - - 648, 573 - - - 6 - - - groupBox1 - - - System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tabBasic - - - 0 - - - 4, 22 - - - 3, 3, 3, 3 - - - 654, 579 - - - 0 - - - Core: basic settings - - - tabBasic - - - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tabControl1 - - - 0 - - - Fill - - - 3, 3 - - - 0 - - - True - - - Vertical - - - 628, 454 - - - 0 - - - txtUseragent - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tabPage3 - - - 0 - - - 4, 22 - - - 3, 3, 3, 3 - - - 634, 460 - - - 0 - - - 1.Proxy Domain or IP - - - tabPage3 - - - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tabControl2 - - - 0 - - - Fill - - - 3, 3 - - - 0 - - - True - - - Vertical - - - 628, 454 - - - 1 - - - txtUserdirect - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tabPage4 - - - 0 - - - 4, 22 - - - 3, 3, 3, 3 - - - 634, 460 - - - 1 - - - 2.Direct Domain or IP - - - tabPage4 - - - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tabControl2 - - - 1 - - - Fill - - - 3, 3 - - - 0 - - - True - - - Vertical - - - 628, 454 - - - 1 - - - txtUserblock - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tabPage5 - - - 0 - - - 4, 22 - - - 3, 3, 3, 3 - - - 634, 460 - - - 2 - - - 3.Block Domain or IP - - - tabPage5 - - - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tabControl2 - - - 2 + + 9 Global @@ -969,311 +798,98 @@ 21, 17 + + cmbroutingMode + + + tabPreDefinedRules + 255, 20 14 - - cmbroutingMode - System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tabPreDefinedRules - 0 - - 4, 22 - - - 3, 3, 3, 3 - - - 634, 460 - - - 3 - - - 4.Pre-defined rules - - - tabPreDefinedRules - - - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tabControl2 - - - 3 - - + Fill - - 3, 84 + + 3, 3 - - 642, 486 + + groupBox1 - - 12 + + tabBasic - - tabControl2 + + 648, 573 - - System.Windows.Forms.TabControl, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 6 - - groupBox2 + + System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - + 0 - - True - - - 5, 14 - - - 0, 0, 0, 0 - - - 95, 12 - - - 19 - - - Domain strategy - - - linkLabelRoutingDoc - - - System.Windows.Forms.LinkLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - panel3 - - - 0 - - - Top, Right - - - True - - - 322, 10 - - - 229, 23 - - - 18 - - - Set default custom routing rules - - - btnSetDefRountingRule - - - System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - panel3 - - - 1 - - - 5, 45 - - - 598, 16 - - - 13 - - - *Set the rules, separated by commas (,); support Domain (pure string / regular / subdomain) and IP - - - labRoutingTips - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - panel3 - - - 2 - - - AsIs - - - IPIfNonMatch - - - IPOnDemand - - - 115, 10 - - - 165, 20 - - - 16 - - - cmbdomainStrategy - - - System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - panel3 - - - 3 - - - Top - - - 3, 17 - - - 642, 67 - - - 19 - - - panel3 - - - System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - groupBox2 - - - 1 - Fill 3, 3 + + groupBox2 + + + tabRouting + 648, 573 12 - - groupBox2 - System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tabRouting - 0 - - 4, 22 - - - 3, 3, 3, 3 - - - 654, 579 - - - 1 - - - Core: Routing settings - - - tabRouting - - - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tabControl1 - - - 1 - - + True - - 20, 143 + + 206, 29 - - 84, 16 + + label1 - - 20 + + groupBox1 - - congestion + + 53, 12 - - chkKcpcongestion + + 11 - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + protocol - - tabKCP + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 0 - - - 345, 100 - - - 94, 21 - - - 15 - - - txtKcpwriteBufferSize - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tabKCP - - - 1 + + 13 True @@ -1281,6 +897,12 @@ 236, 104 + + label10 + + + tabKCP + 95, 12 @@ -1290,45 +912,24 @@ writeBufferSize - - label10 - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tabKCP - 2 - - 111, 100 - - - 94, 21 - - - 13 - - - txtKcpreadBufferSize - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tabKCP - - - 3 - True 18, 104 + + label11 + + + tabKCP + 89, 12 @@ -1338,182 +939,206 @@ readBufferSize - - label11 - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tabKCP - 4 - - 345, 62 - - - 94, 21 - - - 11 - - - txtKcpdownlinkCapacity - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tabKCP - - - 5 - - + True - - 236, 66 + + 30, 176 - - 101, 12 + + label13 - - 10 + + tabGUI - - downlinkCapacity + + 431, 12 - - label8 + + 27 - + + Custom GFWList address (please fill in the blank without customization) + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tabKCP - - - 6 - - - 111, 62 - - - 94, 21 - - - 9 - - - txtKcpuplinkCapacity - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tabKCP - - + 7 - + True - - 18, 66 + + 33, 204 - + + label14 + + + groupBox1 + + + 281, 12 + + + 29 + + + Custom DNS (multiple, separated by commas (,)) + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 5 + + + True + + + NoControl + + + 42, 98 + + + label16 + + + groupBox1 + + + 65, 12 + + + 34 + + + Http proxy + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + + + True + + + 33, 29 + + + label2 + + + groupBox1 + + 89, 12 - - 8 + + 2 - - uplinkCapacity + + Listening port - - label9 - - + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tabKCP + + 19 - - 8 - - - 345, 24 - - - 94, 21 - - - 7 - - - txtKcptti - - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tabKCP - - - 9 - - + True - - 236, 28 + + 206, 64 - - 23, 12 + + label3 - - 6 + + groupBox1 - - tti + + 53, 12 - - label7 + + 16 - + + protocol + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tabKCP + + False - + 10 - - 111, 24 + + NoControl - - 94, 21 + + 5, 11 - - 5 + + label4 - - txtKcpmtu + + panel4 - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 598, 16 - - tabKCP + + 13 - - 11 + + *Set user pac rules, separated by commas (,) + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + + + True + + + 193, 162 + + + label5 + + + groupBox1 + + + 59, 12 + + + 8 + + + Log level + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 17 True @@ -1521,6 +1146,12 @@ 18, 28 + + label6 + + + tabKCP + 23, 12 @@ -1530,124 +1161,115 @@ mtu - - label6 - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tabKCP - 12 - - 4, 22 + + True - - 3, 3, 3, 3 + + 236, 28 - - 654, 579 + + label7 - - 2 - - - Core: KCP settings - - + tabKCP - - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 23, 12 - - tabControl1 + + 6 - - 2 + + tti - + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 10 + + True - - NoControl + + 236, 66 - - 15, 132 + + label8 - - 132, 16 + + tabKCP - - 34 + + 101, 12 - - Interlace coloring + + 10 - - chkInterlaceColoring + + downlinkCapacity - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tabGUI + + 6 - - 0 - - + True - - NoControl + + 18, 66 - - 15, 110 + + label9 - - 198, 16 + + tabKCP - - 33 + + 89, 12 - - Keep older when deduplication + + 8 - - chkKeepOlderDedupl + + uplinkCapacity - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tabGUI + + 8 - - 1 + + 5, 45 - - 161, 84 + + labRoutingTips - - 58, 20 + + panel3 - - 32 + + 598, 16 - - cbFreshrate + + 13 - - System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + *Set the rules, separated by commas (,); support Domain (pure string / regular / subdomain) and IP - - tabGUI + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - + 2 @@ -1659,6 +1281,12 @@ 30, 87 + + lbFreshrate + + + tabGUI + 125, 12 @@ -1668,159 +1296,225 @@ Statistics freshrate - - lbFreshrate - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tabGUI - 3 - + True - - NoControl + + 5, 14 - - 15, 62 + + 0, 0, 0, 0 - - 576, 16 + + linkLabelRoutingDoc - - 29 + + panel3 - - Enable Statistics (Realtime netspeed and traffic records. Require restart the v2rayN client) + + 95, 12 - - chkEnableStatistics + + 19 - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + Domain strategy - - tabGUI + + System.Windows.Forms.LinkLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 4 + + 0 - - True + + Top - - 15, 38 + + 0, 0 - - 204, 16 + + panel1 - - 29 + + $this - - Allow connections from the LAN + + 662, 10 - - chkAllowLANConn + + 9 - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tabGUI + + 2 - - 5 + + Bottom - - 32, 205 + + 0, 615 - - True + + panel2 - - 541, 100 + + $this - - 28 + + 662, 60 - - txturlGFWList + + 11 - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tabGUI + + 1 - - 6 + + Top - - True + + 3, 17 - - 30, 176 + + panel3 - - 431, 12 + + groupBox2 - - 27 + + 642, 67 - - Custom GFWList address (please fill in the blank without customization) + + 19 - - label13 + + System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 1 - - tabGUI + + Top - - 7 + + 3, 3 - - True + + panel4 - - 15, 16 + + tabUserPAC - - 246, 16 + + 648, 37 - - 23 + + 20 - - Automatically start at system startup + + System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - chkAutoRun + + 1 - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 4, 22 - - tabGUI + + tabBasic - - 8 + + 3, 3, 3, 3 + + + tabControl1 + + + 654, 579 + + + 0 + + + Core: basic settings + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + + + Fill + + + 0, 10 + + + tabControl1 + + + $this + + + 662, 605 + + + 10 + + + System.Windows.Forms.TabControl, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + + + Fill + + + 3, 84 + + + tabControl2 + + + groupBox2 + + + 642, 486 + + + 12 + + + System.Windows.Forms.TabControl, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 4, 22 + + tabGUI + 3, 3, 3, 3 + + tabControl1 + 654, 579 @@ -1830,18 +1524,519 @@ v2rayN settings - - tabGUI - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tabControl1 - 3 + + 4, 22 + + + tabKCP + + + 3, 3, 3, 3 + + + tabControl1 + + + 654, 579 + + + 2 + + + Core: KCP settings + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 2 + + + 4, 22 + + + tabPage3 + + + 3, 3, 3, 3 + + + tabControl2 + + + 634, 460 + + + 0 + + + 1.Proxy Domain or IP + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + + + 4, 22 + + + tabPage4 + + + 3, 3, 3, 3 + + + tabControl2 + + + 634, 460 + + + 1 + + + 2.Direct Domain or IP + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 1 + + + 4, 22 + + + tabPage5 + + + 3, 3, 3, 3 + + + tabControl2 + + + 634, 460 + + + 2 + + + 3.Block Domain or IP + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 2 + + + 4, 22 + + + tabPreDefinedRules + + + 3, 3, 3, 3 + + + tabControl2 + + + 634, 460 + + + 3 + + + 4.Pre-defined rules + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 3 + + + 4, 22 + + + tabRouting + + + 3, 3, 3, 3 + + + tabControl1 + + + 654, 579 + + + 1 + + + Core: Routing settings + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 1 + + + 4, 22 + + + tabUserPAC + + + 3, 3, 3, 3 + + + tabControl1 + + + 654, 579 + + + 4 + + + User PAC settings + + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 4 + + + 345, 62 + + + txtKcpdownlinkCapacity + + + tabKCP + + + 94, 21 + + + 11 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 5 + + + 111, 24 + + + txtKcpmtu + + + tabKCP + + + 94, 21 + + + 5 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 11 + + + 111, 100 + + + txtKcpreadBufferSize + + + tabKCP + + + 94, 21 + + + 13 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 3 + + + 345, 24 + + + txtKcptti + + + tabKCP + + + 94, 21 + + + 7 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 9 + + + 111, 62 + + + txtKcpuplinkCapacity + + + tabKCP + + + 94, 21 + + + 9 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 7 + + + 345, 100 + + + txtKcpwriteBufferSize + + + tabKCP + + + 94, 21 + + + 15 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 1 + + + 124, 25 + + + txtlocalPort + + + groupBox1 + + + 78, 21 + + + 3 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 18 + + + 124, 60 + + + txtlocalPort2 + + + groupBox1 + + + 78, 21 + + + 14 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + False + + + 11 + + + 33, 228 + + + True + + + txtremoteDNS + + + groupBox1 + + + 555, 100 + + + 30 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 4 + + + 32, 205 + + + True + + + txturlGFWList + + + tabGUI + + + 541, 100 + + + 28 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 6 + + + Fill + + + 3, 3 + + + 0 + + + True + + + txtUseragent + + + tabPage3 + + + Vertical + + + 628, 454 + + + 0 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + + + Fill + + + 3, 3 + + + 0 + + + True + + + txtUserblock + + + tabPage5 + + + Vertical + + + 628, 454 + + + 1 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + + + Fill + + + 3, 3 + + + 0 + + + True + + + txtUserdirect + + + tabPage4 + + + Vertical + + + 628, 454 + + + 1 + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 0 + Fill @@ -1854,6 +2049,12 @@ True + + txtuserPacRule + + + tabUserPAC + Vertical @@ -1863,211 +2064,10 @@ 21 - - txtuserPacRule - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - tabUserPAC - 0 - - NoControl - - - 5, 11 - - - 598, 16 - - - 13 - - - *Set user pac rules, separated by commas (,) - - - label4 - - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - panel4 - - - 0 - - - Top - - - 3, 3 - - - 648, 37 - - - 20 - - - panel4 - - - System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tabUserPAC - - - 1 - - - 4, 22 - - - 3, 3, 3, 3 - - - 654, 579 - - - 4 - - - User PAC settings - - - tabUserPAC - - - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - tabControl1 - - - 4 - - - Fill - - - 0, 10 - - - 662, 605 - - - 10 - - - tabControl1 - - - System.Windows.Forms.TabControl, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - $this - - - 0 - - - 267, 16 - - - 75, 23 - - - 8 - - - &OK - - - btnOK - - - System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - panel2 - - - 1 - - - Bottom - - - 0, 615 - - - 662, 60 - - - 11 - - - panel2 - - - System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - $this - - - 1 - - - Top - - - 0, 0 - - - 662, 10 - - - 9 - - - panel1 - - - System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - $this - - - 2 - - - True - - - 6, 12 - - - 662, 675 - - - 4, 4, 4, 4 - - - Settings - - - OptionSettingForm - - - v2rayN.Forms.BaseForm, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null - \ No newline at end of file From 910be7f471bd2558471fe37c9fb164cc04664283 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Fri, 17 Apr 2020 16:31:19 +0800 Subject: [PATCH 09/45] fixing layout --- v2rayN/v2rayN/Forms/MainForm.Designer.cs | 45 +++++++++++++++++------ v2rayN/v2rayN/Forms/MainForm.resx | 47 +++++------------------- 2 files changed, 44 insertions(+), 48 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.Designer.cs b/v2rayN/v2rayN/Forms/MainForm.Designer.cs index 7e1faaf3..f4b06e04 100644 --- a/v2rayN/v2rayN/Forms/MainForm.Designer.cs +++ b/v2rayN/v2rayN/Forms/MainForm.Designer.cs @@ -535,6 +535,7 @@ // // ssMain // + this.ssMain.AllowItemReorder = true; this.ssMain.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { this.toolSslSocksPortLab, this.toolSslSocksPort, @@ -551,86 +552,108 @@ this.toolSslBlank4}); resources.ApplyResources(this.ssMain, "ssMain"); this.ssMain.Name = "ssMain"; + this.ssMain.ShowItemToolTips = true; + this.ssMain.TabStop = true; this.ssMain.ItemClicked += new System.Windows.Forms.ToolStripItemClickedEventHandler(this.ssMain_ItemClicked); // // toolSslSocksPortLab // - resources.ApplyResources(this.toolSslSocksPortLab, "toolSslSocksPortLab"); + this.toolSslSocksPortLab.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; this.toolSslSocksPortLab.Name = "toolSslSocksPortLab"; + this.toolSslSocksPortLab.Overflow = System.Windows.Forms.ToolStripItemOverflow.Never; + resources.ApplyResources(this.toolSslSocksPortLab, "toolSslSocksPortLab"); // // toolSslSocksPort // + this.toolSslSocksPort.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; this.toolSslSocksPort.Name = "toolSslSocksPort"; + this.toolSslSocksPort.Overflow = System.Windows.Forms.ToolStripItemOverflow.Never; resources.ApplyResources(this.toolSslSocksPort, "toolSslSocksPort"); // // toolSslBlank1 // this.toolSslBlank1.AutoToolTip = true; - resources.ApplyResources(this.toolSslBlank1, "toolSslBlank1"); + this.toolSslBlank1.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; this.toolSslBlank1.Name = "toolSslBlank1"; + this.toolSslBlank1.Overflow = System.Windows.Forms.ToolStripItemOverflow.Never; + resources.ApplyResources(this.toolSslBlank1, "toolSslBlank1"); this.toolSslBlank1.Spring = true; // // toolSslHttpPortLab // - resources.ApplyResources(this.toolSslHttpPortLab, "toolSslHttpPortLab"); + this.toolSslHttpPortLab.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; this.toolSslHttpPortLab.Name = "toolSslHttpPortLab"; + this.toolSslHttpPortLab.Overflow = System.Windows.Forms.ToolStripItemOverflow.Never; + resources.ApplyResources(this.toolSslHttpPortLab, "toolSslHttpPortLab"); // // toolSslHttpPort // + this.toolSslHttpPort.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; this.toolSslHttpPort.Name = "toolSslHttpPort"; + this.toolSslHttpPort.Overflow = System.Windows.Forms.ToolStripItemOverflow.Never; resources.ApplyResources(this.toolSslHttpPort, "toolSslHttpPort"); // // toolSslBlank2 // this.toolSslBlank2.AutoToolTip = true; - resources.ApplyResources(this.toolSslBlank2, "toolSslBlank2"); + this.toolSslBlank2.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; this.toolSslBlank2.Name = "toolSslBlank2"; + this.toolSslBlank2.Overflow = System.Windows.Forms.ToolStripItemOverflow.Never; + resources.ApplyResources(this.toolSslBlank2, "toolSslBlank2"); this.toolSslBlank2.Spring = true; // // toolSslPacPortLab // - resources.ApplyResources(this.toolSslPacPortLab, "toolSslPacPortLab"); + this.toolSslPacPortLab.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; this.toolSslPacPortLab.Name = "toolSslPacPortLab"; + this.toolSslPacPortLab.Overflow = System.Windows.Forms.ToolStripItemOverflow.Never; + resources.ApplyResources(this.toolSslPacPortLab, "toolSslPacPortLab"); // // toolSslPacPort // + this.toolSslPacPort.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; this.toolSslPacPort.Name = "toolSslPacPort"; + this.toolSslPacPort.Overflow = System.Windows.Forms.ToolStripItemOverflow.Never; resources.ApplyResources(this.toolSslPacPort, "toolSslPacPort"); // // toolSslBlank3 // this.toolSslBlank3.AutoToolTip = true; - resources.ApplyResources(this.toolSslBlank3, "toolSslBlank3"); + this.toolSslBlank3.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; this.toolSslBlank3.Name = "toolSslBlank3"; + this.toolSslBlank3.Overflow = System.Windows.Forms.ToolStripItemOverflow.Never; + resources.ApplyResources(this.toolSslBlank3, "toolSslBlank3"); this.toolSslBlank3.Spring = true; // // toolSslRouting // - resources.ApplyResources(this.toolSslRouting, "toolSslRouting"); this.toolSslRouting.AutoToolTip = true; + this.toolSslRouting.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; this.toolSslRouting.IsLink = true; this.toolSslRouting.LinkBehavior = System.Windows.Forms.LinkBehavior.NeverUnderline; this.toolSslRouting.LinkColor = System.Drawing.SystemColors.ControlText; - this.toolSslRouting.Margin = new System.Windows.Forms.Padding(0, 3, 8, 2); + this.toolSslRouting.Margin = new System.Windows.Forms.Padding(0, 3, 5, 2); this.toolSslRouting.Name = "toolSslRouting"; - this.toolSslRouting.Spring = true; + this.toolSslRouting.Overflow = System.Windows.Forms.ToolStripItemOverflow.Never; + resources.ApplyResources(this.toolSslRouting, "toolSslRouting"); this.toolSslRouting.Click += new System.EventHandler(this.toolSslRouting_Click); // // toolSslServerLatency // resources.ApplyResources(this.toolSslServerLatency, "toolSslServerLatency"); + this.toolSslServerLatency.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; this.toolSslServerLatency.IsLink = true; this.toolSslServerLatency.LinkBehavior = System.Windows.Forms.LinkBehavior.NeverUnderline; this.toolSslServerLatency.LinkColor = System.Drawing.SystemColors.ControlText; + this.toolSslServerLatency.Margin = new System.Windows.Forms.Padding(0, 3, 5, 2); this.toolSslServerLatency.Name = "toolSslServerLatency"; - this.toolSslServerLatency.Spring = true; this.toolSslServerLatency.Click += new System.EventHandler(this.toolSslServerLatency_Click); // // toolSslServerSpeed // this.toolSslServerSpeed.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; - resources.ApplyResources(this.toolSslServerSpeed, "toolSslServerSpeed"); this.toolSslServerSpeed.Name = "toolSslServerSpeed"; + resources.ApplyResources(this.toolSslServerSpeed, "toolSslServerSpeed"); this.toolSslServerSpeed.Click += new System.EventHandler(this.toolSslServerSpeed_Click); // // toolSslBlank4 diff --git a/v2rayN/v2rayN/Forms/MainForm.resx b/v2rayN/v2rayN/Forms/MainForm.resx index 552aebaa..d178e652 100644 --- a/v2rayN/v2rayN/Forms/MainForm.resx +++ b/v2rayN/v2rayN/Forms/MainForm.resx @@ -867,7 +867,7 @@ 946, 22 - 0 + 6 statusStrip1 @@ -878,38 +878,29 @@ 1 - - 微软雅黑, 8pt - toolSslBlank1 - 137, 17 + 161, 17 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 微软雅黑, 8pt - toolSslBlank2 - 137, 17 + 161, 17 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 微软雅黑, 8pt - toolSslBlank3 - 137, 17 + 161, 17 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -932,14 +923,11 @@ System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 微软雅黑, 8pt - toolSslHttpPortLab - 39, 17 + 41, 17 HTTP: @@ -956,14 +944,11 @@ System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 微软雅黑, 8pt - toolSslPacPortLab - 33, 17 + 34, 17 PAC: @@ -971,14 +956,11 @@ System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - False - toolSslRouting - 129, 17 + 92, 17 Routing Mode @@ -993,7 +975,7 @@ toolSslServerLatency - 137, 17 + 80, 17 Latency: @@ -1007,17 +989,11 @@ System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 微软雅黑, 8pt - toolSslServerSpeed - - No - - 89, 17 + 100, 17 SPEED Disabled @@ -1037,14 +1013,11 @@ System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 微软雅黑, 8pt - toolSslSocksPortLab - 52, 17 + 58, 17 SOCKS5: From 4e449811e7365d347921d98c89c1675a36f6d452 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Fri, 17 Apr 2020 19:31:48 +0800 Subject: [PATCH 10/45] simplify --- v2rayN/v2rayN/Forms/MainForm.cs | 38 +++++++++++++++------------- v2rayN/v2rayN/Mode/EServerColName.cs | 21 --------------- v2rayN/v2rayN/v2rayN.csproj | 1 - 3 files changed, 21 insertions(+), 39 deletions(-) delete mode 100644 v2rayN/v2rayN/Mode/EServerColName.cs diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 87324743..59f57478 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -126,7 +126,9 @@ namespace v2rayN.Forms // break; // } //} + #endregion + #region 窗口大小和列宽等取/存 private void RestoreUI() { scMain.Panel2Collapsed = true; @@ -137,10 +139,10 @@ namespace v2rayN.Forms this.Height = config.uiItem.mainSize.Height; } - for (int k = 0; k < lvServers.Columns.Count; k++) + foreach (ColumnHeader c in lvServers.Columns) { - var width = ConfigHandler.GetformMainLvColWidth(ref config, ((EServerColName)k).ToString(), lvServers.Columns[k].Width); - lvServers.Columns[k].Width = width; + var width = ConfigHandler.GetformMainLvColWidth(ref config, c.Name, c.Width); + c.Width = width; } } @@ -148,9 +150,9 @@ namespace v2rayN.Forms { config.uiItem.mainSize = new Size(this.Width, this.Height); - for (int k = 0; k < lvServers.Columns.Count; k++) + foreach (ColumnHeader c in lvServers.Columns) { - ConfigHandler.AddformMainLvColWidth(ref config, ((EServerColName)k).ToString(), lvServers.Columns[k].Width); + ConfigHandler.AddformMainLvColWidth(ref config, c.Name, c.Width); } } @@ -242,20 +244,22 @@ namespace v2rayN.Forms } } ListViewItem lvItem = new ListViewItem(def); - _addSubItem(lvItem, EServerColName.type.ToString(), ((EConfigType)item.configType).ToString()); - _addSubItem(lvItem, EServerColName.remarks.ToString(), item.remarks); - _addSubItem(lvItem, EServerColName.address.ToString(), item.address); - _addSubItem(lvItem, EServerColName.port.ToString(), item.port.ToString()); - _addSubItem(lvItem, EServerColName.security.ToString(), item.security); - _addSubItem(lvItem, EServerColName.network.ToString(), item.network); - _addSubItem(lvItem, EServerColName.subRemarks.ToString(), item.getSubRemarks(config)); - _addSubItem(lvItem, EServerColName.testResult.ToString(), item.testResult); + _addSubItem(lvItem, "type", ((EConfigType)item.configType).ToString()); + _addSubItem(lvItem, "remarks", item.remarks); + _addSubItem(lvItem, "address", item.address); + _addSubItem(lvItem, "port", item.port.ToString()); + //_addSubItem(lvItem, "id", item.id); + //_addSubItem(lvItem, "alterId", item.alterId.ToString()); + _addSubItem(lvItem, "security", item.security); + _addSubItem(lvItem, "network", item.network); + _addSubItem(lvItem, "SubRemarks", item.getSubRemarks(config)); + _addSubItem(lvItem, "testResult", item.testResult); if (stats) { - _addSubItem(lvItem, EServerColName.todayDown.ToString(), todayDown); - _addSubItem(lvItem, EServerColName.todayUp.ToString(), todayUp); - _addSubItem(lvItem, EServerColName.totalDown.ToString(), totalDown); - _addSubItem(lvItem, EServerColName.totalUp.ToString(), totalUp); + _addSubItem(lvItem, "todayDown", todayDown); + _addSubItem(lvItem, "todayUp", todayUp); + _addSubItem(lvItem, "totalDown", totalDown); + _addSubItem(lvItem, "totalUp", totalUp); } if (config.interlaceColoring && k % 2 == 1) // 隔行着色 diff --git a/v2rayN/v2rayN/Mode/EServerColName.cs b/v2rayN/v2rayN/Mode/EServerColName.cs deleted file mode 100644 index b92138ef..00000000 --- a/v2rayN/v2rayN/Mode/EServerColName.cs +++ /dev/null @@ -1,21 +0,0 @@ - -namespace v2rayN.Mode -{ - public enum EServerColName - { - def = 0, - type, - remarks, - address, - port, - security, - network, - subRemarks, - testResult, - - todayDown, - todayUp, - totalDown, - totalUp - } -} \ No newline at end of file diff --git a/v2rayN/v2rayN/v2rayN.csproj b/v2rayN/v2rayN/v2rayN.csproj index 65075779..f77dea03 100644 --- a/v2rayN/v2rayN/v2rayN.csproj +++ b/v2rayN/v2rayN/v2rayN.csproj @@ -157,7 +157,6 @@ - From f3e6bd2736876559a2ff9eedbbf45045eeb5ac13 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Fri, 17 Apr 2020 19:45:37 +0800 Subject: [PATCH 11/45] refine code --- v2rayN/v2rayN/Forms/MainForm.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 59f57478..79447b54 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -210,9 +210,9 @@ namespace v2rayN.Forms /// private void RefreshServersView() { - lvServers.BeginUpdate(); lvServers.Items.Clear(); + List lst = new List(); for (int k = 0; k < config.vmess.Count; k++) { string def = string.Empty; @@ -273,9 +273,9 @@ namespace v2rayN.Forms lvItem.Font = new Font(lvItem.Font, FontStyle.Bold); } - if (lvItem != null) lvServers.Items.Add(lvItem); + if (lvItem != null) lst.Add(lvItem); } - lvServers.EndUpdate(); + lvServers.Items.AddRange(lst.ToArray()); //if (lvServers.Items.Count > 0) //{ From 3b1a2287d52b359619dfbaad695a326b11e9d8b5 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Fri, 17 Apr 2020 20:21:56 +0800 Subject: [PATCH 12/45] cleanup code --- v2rayN/v2rayN/Forms/MainForm.cs | 7 ------- 1 file changed, 7 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 79447b54..3a5c1d69 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -178,13 +178,6 @@ namespace v2rayN.Forms lvServers.BeginUpdate(); lvServers.Items.Clear(); - lvServers.GridLines = true; - lvServers.FullRowSelect = true; - lvServers.View = View.Details; - lvServers.Scrollable = true; - lvServers.MultiSelect = true; - lvServers.HeaderStyle = ColumnHeaderStyle.Nonclickable; - lvServers.Columns.Add("", 30); lvServers.Columns.Add(UIRes.I18N("LvServiceType"), 80); lvServers.Columns.Add(UIRes.I18N("LvAlias"), 100); From 1c04b752cdfadb4c1886d76cc47a2339cee73aea Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 08:57:53 +0800 Subject: [PATCH 13/45] fix typo --- v2rayN/v2rayN/Handler/MainFormHandler.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/v2rayN/v2rayN/Handler/MainFormHandler.cs b/v2rayN/v2rayN/Handler/MainFormHandler.cs index 83865d92..d99fd3de 100644 --- a/v2rayN/v2rayN/Handler/MainFormHandler.cs +++ b/v2rayN/v2rayN/Handler/MainFormHandler.cs @@ -97,11 +97,11 @@ namespace v2rayN.Handler configCopy.index = index; if (V2rayConfigHandler.Export2ClientConfig(configCopy, fileName, out string msg) != 0) { - UI.Show(msg); + UI.ShowWarning(msg); } else { - UI.ShowWarning(string.Format(UIRes.I18N("SaveClientConfigurationIn"), fileName)); + UI.Show(string.Format(UIRes.I18N("SaveClientConfigurationIn"), fileName)); } } @@ -137,11 +137,11 @@ namespace v2rayN.Handler configCopy.index = index; if (V2rayConfigHandler.Export2ServerConfig(configCopy, fileName, out string msg) != 0) { - UI.Show(msg); + UI.ShowWarning(msg); } else { - UI.ShowWarning(string.Format(UIRes.I18N("SaveServerConfigurationIn"), fileName)); + UI.Show(string.Format(UIRes.I18N("SaveServerConfigurationIn"), fileName)); } } From fbfbc811d4750e27e0da0d73d3daa6bc92c24265 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 10:16:29 +0800 Subject: [PATCH 14/45] refine UI performance --- v2rayN/v2rayN/Forms/MainForm.cs | 73 +++++++++++++++----------- v2rayN/v2rayN/Global.cs | 2 +- v2rayN/v2rayN/Handler/ConfigHandler.cs | 14 ++--- v2rayN/v2rayN/Handler/V2rayHandler.cs | 20 ++++--- 4 files changed, 56 insertions(+), 53 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 3a5c1d69..0b2c9756 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -34,14 +34,7 @@ namespace v2rayN.Forms Application.ApplicationExit += (sender, args) => { - v2rayHandler.V2rayStop(); - - HttpProxyHandle.CloseHttpAgent(config); - PACServerHandle.Stop(); - - ConfigHandler.SaveConfig(ref config); - statistics?.SaveToFile(); - statistics?.Close(); + Closes(); }; } @@ -347,6 +340,7 @@ namespace v2rayN.Forms } private void DisplayToolStatus() { + ssMain.SuspendLayout(); toolSslSocksPort.Text = toolSslHttpPort.Text = toolSslPacPort.Text = "OFF"; @@ -388,6 +382,7 @@ namespace v2rayN.Forms break; } toolSslRouting.Text = routingStatus; + ssMain.ResumeLayout(); RefreshTaryIcon(); } @@ -411,7 +406,10 @@ namespace v2rayN.Forms autoLatencyRefreshTask = Task.Run(async delegate { await Task.Delay(2000); - toolSslServerLatencyRefresh(); + this.Invoke((MethodInvoker)(delegate + { + toolSslServerLatencyRefresh(); + })); }); } } @@ -421,37 +419,42 @@ namespace v2rayN.Forms /// /// 载入V2ray /// - private void LoadV2ray() + private async void LoadV2ray() { - tsbReload.Enabled = false; - - if (Global.reloadV2ray) + this.Invoke((MethodInvoker)(delegate { - ClearMsg(); - } - v2rayHandler.LoadV2ray(config); + tsbReload.Enabled = false; + + if (Global.reloadV2ray) + { + ClearMsg(); + } + })); + await v2rayHandler.LoadV2ray(config); Global.reloadV2ray = false; - ConfigHandler.SaveConfig(ref config, false); + ChangePACButtonStatus(config.listenerType); + //ConfigHandler.SaveConfig(ref config, false); // ChangePACButtonStatus does it. statistics?.SaveToFile(); - ChangePACButtonStatus(config.listenerType); + this.Invoke((MethodInvoker)(delegate + { + tsbReload.Enabled = true; - tsbReload.Enabled = true; - - autoLatencyRefresh(); + autoLatencyRefresh(); + })); } /// - /// 关闭V2ray + /// 关闭相关组件 /// - private void CloseV2ray() + private void Closes() { - ConfigHandler.SaveConfig(ref config, false); + //ConfigHandler.SaveConfig(ref config, false); // ChangePACButtonStatus does it. + Task.Run(() => ChangePACButtonStatus(ListenerType.noHttpProxy)); + Task.Run(() => v2rayHandler.V2rayStop()); + Task.Run(() => PACServerHandle.Stop()); statistics?.SaveToFile(); - - ChangePACButtonStatus(0); - - v2rayHandler.V2rayStop(); + statistics?.Close(); } #endregion @@ -785,13 +788,18 @@ namespace v2rayN.Forms { string tab = ""; if (sender == toolSslRouting) tab = "tabPreDefinedRules"; + OptionSettingForm fm = new OptionSettingForm(tab); if (fm.ShowDialog() == DialogResult.OK) { //刷新 RefreshServers(); - LoadV2ray(); - HttpProxyHandle.RestartHttpAgent(config, true); + //Application.DoEvents(); + Task.Run(() => + { + LoadV2ray(); + HttpProxyHandle.RestartHttpAgent(config, true); + }); } } @@ -1253,7 +1261,8 @@ namespace v2rayN.Forms item.Checked = ((int)type == k); } - ConfigHandler.SaveConfig(ref config, false); + Global.reloadV2ray = false; + ConfigHandler.SaveConfig(ref config); DisplayToolStatus(); } @@ -1369,7 +1378,7 @@ namespace v2rayN.Forms try { - CloseV2ray(); + Closes(); string fileName = downloadHandle.DownloadFileName; fileName = Utils.GetPath(fileName); diff --git a/v2rayN/v2rayN/Global.cs b/v2rayN/v2rayN/Global.cs index 58ed9d5a..862910fa 100644 --- a/v2rayN/v2rayN/Global.cs +++ b/v2rayN/v2rayN/Global.cs @@ -171,7 +171,7 @@ namespace v2rayN #region 全局变量 /// - /// 是否需要重启服务V2ray + /// 是否需要重启服务V2ray。如果为假,LoadV2ray()不做任何事。 /// public static bool reloadV2ray { diff --git a/v2rayN/v2rayN/Handler/ConfigHandler.cs b/v2rayN/v2rayN/Handler/ConfigHandler.cs index 3dae84b1..ec9b4d92 100644 --- a/v2rayN/v2rayN/Handler/ConfigHandler.cs +++ b/v2rayN/v2rayN/Handler/ConfigHandler.cs @@ -334,26 +334,22 @@ namespace v2rayN.Handler } /// - /// 保参数 + /// 保存参数 /// /// /// - public static int SaveConfig(ref Config config, bool reload = true) + public static int SaveConfig(ref Config config) { - Global.reloadV2ray = reload; - - ToJsonFile(config); - - return 0; + return ToJsonFile(config); } /// /// 存储文件 /// /// - private static void ToJsonFile(Config config) + private static int ToJsonFile(Config config) { - Utils.ToJsonFile(config, Utils.GetPath(configRes)); + return Utils.ToJsonFile(config, Utils.GetPath(configRes)); } /// diff --git a/v2rayN/v2rayN/Handler/V2rayHandler.cs b/v2rayN/v2rayN/Handler/V2rayHandler.cs index e367bef2..d3df7118 100644 --- a/v2rayN/v2rayN/Handler/V2rayHandler.cs +++ b/v2rayN/v2rayN/Handler/V2rayHandler.cs @@ -3,6 +3,7 @@ using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Text; +using System.Threading.Tasks; using v2rayN.Mode; namespace v2rayN.Handler @@ -38,21 +39,18 @@ namespace v2rayN.Handler /// /// 载入V2ray /// - public void LoadV2ray(Config config) + public Task LoadV2ray(Config config) { - if (Global.reloadV2ray) + return Task.Run(() => { + if (!Global.reloadV2ray) return; + string fileName = Utils.GetPath(v2rayConfigRes); - if (V2rayConfigHandler.GenerateClientConfig(config, fileName, false, out string msg) != 0) - { - ShowMsg(false, msg); - } - else - { - ShowMsg(true, msg); + bool bOk = V2rayConfigHandler.GenerateClientConfig(config, fileName, false, out string msg) == 0; + ShowMsg(bOk, msg); + if (bOk) V2rayRestart(); - } - } + }); } /// From 9538a67be198699fc9bcc35e855df69337a67163 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 10:42:08 +0800 Subject: [PATCH 15/45] Revert "simplify" This reverts commit 4e449811e7365d347921d98c89c1675a36f6d452. The "Name" looks not work... --- v2rayN/v2rayN/Forms/MainForm.cs | 38 +++++++++++++--------------- v2rayN/v2rayN/Mode/EServerColName.cs | 21 +++++++++++++++ v2rayN/v2rayN/v2rayN.csproj | 1 + 3 files changed, 39 insertions(+), 21 deletions(-) create mode 100644 v2rayN/v2rayN/Mode/EServerColName.cs diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 0b2c9756..1c40611a 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -119,9 +119,7 @@ namespace v2rayN.Forms // break; // } //} - #endregion - #region 窗口大小和列宽等取/存 private void RestoreUI() { scMain.Panel2Collapsed = true; @@ -132,10 +130,10 @@ namespace v2rayN.Forms this.Height = config.uiItem.mainSize.Height; } - foreach (ColumnHeader c in lvServers.Columns) + for (int k = 0; k < lvServers.Columns.Count; k++) { - var width = ConfigHandler.GetformMainLvColWidth(ref config, c.Name, c.Width); - c.Width = width; + var width = ConfigHandler.GetformMainLvColWidth(ref config, ((EServerColName)k).ToString(), lvServers.Columns[k].Width); + lvServers.Columns[k].Width = width; } } @@ -143,9 +141,9 @@ namespace v2rayN.Forms { config.uiItem.mainSize = new Size(this.Width, this.Height); - foreach (ColumnHeader c in lvServers.Columns) + for (int k = 0; k < lvServers.Columns.Count; k++) { - ConfigHandler.AddformMainLvColWidth(ref config, c.Name, c.Width); + ConfigHandler.AddformMainLvColWidth(ref config, ((EServerColName)k).ToString(), lvServers.Columns[k].Width); } } @@ -230,22 +228,20 @@ namespace v2rayN.Forms } } ListViewItem lvItem = new ListViewItem(def); - _addSubItem(lvItem, "type", ((EConfigType)item.configType).ToString()); - _addSubItem(lvItem, "remarks", item.remarks); - _addSubItem(lvItem, "address", item.address); - _addSubItem(lvItem, "port", item.port.ToString()); - //_addSubItem(lvItem, "id", item.id); - //_addSubItem(lvItem, "alterId", item.alterId.ToString()); - _addSubItem(lvItem, "security", item.security); - _addSubItem(lvItem, "network", item.network); - _addSubItem(lvItem, "SubRemarks", item.getSubRemarks(config)); - _addSubItem(lvItem, "testResult", item.testResult); + _addSubItem(lvItem, EServerColName.type.ToString(), ((EConfigType)item.configType).ToString()); + _addSubItem(lvItem, EServerColName.remarks.ToString(), item.remarks); + _addSubItem(lvItem, EServerColName.address.ToString(), item.address); + _addSubItem(lvItem, EServerColName.port.ToString(), item.port.ToString()); + _addSubItem(lvItem, EServerColName.security.ToString(), item.security); + _addSubItem(lvItem, EServerColName.network.ToString(), item.network); + _addSubItem(lvItem, EServerColName.subRemarks.ToString(), item.getSubRemarks(config)); + _addSubItem(lvItem, EServerColName.testResult.ToString(), item.testResult); if (stats) { - _addSubItem(lvItem, "todayDown", todayDown); - _addSubItem(lvItem, "todayUp", todayUp); - _addSubItem(lvItem, "totalDown", totalDown); - _addSubItem(lvItem, "totalUp", totalUp); + _addSubItem(lvItem, EServerColName.todayDown.ToString(), todayDown); + _addSubItem(lvItem, EServerColName.todayUp.ToString(), todayUp); + _addSubItem(lvItem, EServerColName.totalDown.ToString(), totalDown); + _addSubItem(lvItem, EServerColName.totalUp.ToString(), totalUp); } if (config.interlaceColoring && k % 2 == 1) // 隔行着色 diff --git a/v2rayN/v2rayN/Mode/EServerColName.cs b/v2rayN/v2rayN/Mode/EServerColName.cs new file mode 100644 index 00000000..b92138ef --- /dev/null +++ b/v2rayN/v2rayN/Mode/EServerColName.cs @@ -0,0 +1,21 @@ + +namespace v2rayN.Mode +{ + public enum EServerColName + { + def = 0, + type, + remarks, + address, + port, + security, + network, + subRemarks, + testResult, + + todayDown, + todayUp, + totalDown, + totalUp + } +} \ No newline at end of file diff --git a/v2rayN/v2rayN/v2rayN.csproj b/v2rayN/v2rayN/v2rayN.csproj index f77dea03..65075779 100644 --- a/v2rayN/v2rayN/v2rayN.csproj +++ b/v2rayN/v2rayN/v2rayN.csproj @@ -157,6 +157,7 @@ + From b1773dab9063231e39cf1cd44b1323fe2164142b Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 11:12:09 +0800 Subject: [PATCH 16/45] bug fixes --- v2rayN/v2rayN/Base/HttpWebServerB.cs | 2 +- v2rayN/v2rayN/Forms/MainForm.Designer.cs | 1 - v2rayN/v2rayN/Forms/MainForm.cs | 26 +++++++++++++++++------- 3 files changed, 20 insertions(+), 9 deletions(-) diff --git a/v2rayN/v2rayN/Base/HttpWebServerB.cs b/v2rayN/v2rayN/Base/HttpWebServerB.cs index fcbca1dd..6434b9ea 100644 --- a/v2rayN/v2rayN/Base/HttpWebServerB.cs +++ b/v2rayN/v2rayN/Base/HttpWebServerB.cs @@ -41,7 +41,7 @@ namespace v2rayN.Base listener.Start(); Utils.SaveLog("WebserverB running..."); - while (true) + while (true && listener != null) { if (!listener.Pending()) { diff --git a/v2rayN/v2rayN/Forms/MainForm.Designer.cs b/v2rayN/v2rayN/Forms/MainForm.Designer.cs index f4b06e04..9b2db76a 100644 --- a/v2rayN/v2rayN/Forms/MainForm.Designer.cs +++ b/v2rayN/v2rayN/Forms/MainForm.Designer.cs @@ -163,7 +163,6 @@ this.lvServers.HideSelection = false; this.lvServers.Items.AddRange(new System.Windows.Forms.ListViewItem[] { ((System.Windows.Forms.ListViewItem)(resources.GetObject("lvServers.Items")))}); - this.lvServers.MultiSelect = false; this.lvServers.Name = "lvServers"; this.lvServers.UseCompatibleStateImageBehavior = false; this.lvServers.View = System.Windows.Forms.View.Details; diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 1c40611a..59cb17a2 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -445,12 +445,19 @@ namespace v2rayN.Forms /// private void Closes() { - //ConfigHandler.SaveConfig(ref config, false); // ChangePACButtonStatus does it. - Task.Run(() => ChangePACButtonStatus(ListenerType.noHttpProxy)); - Task.Run(() => v2rayHandler.V2rayStop()); - Task.Run(() => PACServerHandle.Stop()); - statistics?.SaveToFile(); - statistics?.Close(); + List tasks = new List + { + Task.Run(() => ConfigHandler.SaveConfig(ref config)), + Task.Run(() => HttpProxyHandle.CloseHttpAgent(config)), + Task.Run(() => v2rayHandler.V2rayStop()), + Task.Run(() => PACServerHandle.Stop()), + Task.Run(() => + { + statistics?.SaveToFile(); + statistics?.Close(); + }) + }; + Task.WaitAll(tasks.ToArray()); } #endregion @@ -1130,6 +1137,7 @@ namespace v2rayN.Forms int index = statistics.FindIndex(item_ => item_.itemId == config.vmess[i].getItemId()); if (index != -1) { + if (lvServers == null) return; // The app is exiting. lvServers.Invoke((MethodInvoker)delegate { lvServers.BeginUpdate(); @@ -1259,7 +1267,11 @@ namespace v2rayN.Forms Global.reloadV2ray = false; ConfigHandler.SaveConfig(ref config); - DisplayToolStatus(); + + this.Invoke((MethodInvoker)(delegate + { + DisplayToolStatus(); + })); } #endregion From da2b0f7dd4be15284a41c453552cdba85188279b Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 11:46:25 +0800 Subject: [PATCH 17/45] BorderSides on status bar --- v2rayN/v2rayN/Forms/MainForm.Designer.cs | 10 ++++++++ v2rayN/v2rayN/Forms/MainForm.resx | 32 ++++++++++++------------ 2 files changed, 26 insertions(+), 16 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.Designer.cs b/v2rayN/v2rayN/Forms/MainForm.Designer.cs index 9b2db76a..b8d03aca 100644 --- a/v2rayN/v2rayN/Forms/MainForm.Designer.cs +++ b/v2rayN/v2rayN/Forms/MainForm.Designer.cs @@ -572,6 +572,8 @@ // toolSslBlank1 // this.toolSslBlank1.AutoToolTip = true; + this.toolSslBlank1.BorderSides = System.Windows.Forms.ToolStripStatusLabelBorderSides.Right; + this.toolSslBlank1.BorderStyle = System.Windows.Forms.Border3DStyle.SunkenInner; this.toolSslBlank1.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; this.toolSslBlank1.Name = "toolSslBlank1"; this.toolSslBlank1.Overflow = System.Windows.Forms.ToolStripItemOverflow.Never; @@ -595,6 +597,8 @@ // toolSslBlank2 // this.toolSslBlank2.AutoToolTip = true; + this.toolSslBlank2.BorderSides = System.Windows.Forms.ToolStripStatusLabelBorderSides.Right; + this.toolSslBlank2.BorderStyle = System.Windows.Forms.Border3DStyle.SunkenInner; this.toolSslBlank2.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; this.toolSslBlank2.Name = "toolSslBlank2"; this.toolSslBlank2.Overflow = System.Windows.Forms.ToolStripItemOverflow.Never; @@ -618,6 +622,8 @@ // toolSslBlank3 // this.toolSslBlank3.AutoToolTip = true; + this.toolSslBlank3.BorderSides = System.Windows.Forms.ToolStripStatusLabelBorderSides.Right; + this.toolSslBlank3.BorderStyle = System.Windows.Forms.Border3DStyle.SunkenInner; this.toolSslBlank3.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; this.toolSslBlank3.Name = "toolSslBlank3"; this.toolSslBlank3.Overflow = System.Windows.Forms.ToolStripItemOverflow.Never; @@ -627,6 +633,8 @@ // toolSslRouting // this.toolSslRouting.AutoToolTip = true; + this.toolSslRouting.BorderSides = System.Windows.Forms.ToolStripStatusLabelBorderSides.Right; + this.toolSslRouting.BorderStyle = System.Windows.Forms.Border3DStyle.SunkenInner; this.toolSslRouting.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; this.toolSslRouting.IsLink = true; this.toolSslRouting.LinkBehavior = System.Windows.Forms.LinkBehavior.NeverUnderline; @@ -640,6 +648,8 @@ // toolSslServerLatency // resources.ApplyResources(this.toolSslServerLatency, "toolSslServerLatency"); + this.toolSslServerLatency.BorderSides = System.Windows.Forms.ToolStripStatusLabelBorderSides.Right; + this.toolSslServerLatency.BorderStyle = System.Windows.Forms.Border3DStyle.SunkenInner; this.toolSslServerLatency.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; this.toolSslServerLatency.IsLink = true; this.toolSslServerLatency.LinkBehavior = System.Windows.Forms.LinkBehavior.NeverUnderline; diff --git a/v2rayN/v2rayN/Forms/MainForm.resx b/v2rayN/v2rayN/Forms/MainForm.resx index d178e652..6a15bb40 100644 --- a/v2rayN/v2rayN/Forms/MainForm.resx +++ b/v2rayN/v2rayN/Forms/MainForm.resx @@ -855,7 +855,7 @@ 0 - 3, 151 + 3, 147 ssMain @@ -864,7 +864,7 @@ groupBox2 - 946, 22 + 946, 26 6 @@ -882,7 +882,7 @@ toolSslBlank1 - 161, 17 + 170, 21 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -891,7 +891,7 @@ toolSslBlank2 - 161, 17 + 170, 21 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -900,7 +900,7 @@ toolSslBlank3 - 161, 17 + 170, 21 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -909,7 +909,7 @@ toolSslBlank4 - 0, 17 + 0, 21 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -918,7 +918,7 @@ toolSslHttpPort - 0, 17 + 0, 21 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -927,7 +927,7 @@ toolSslHttpPortLab - 41, 17 + 41, 21 HTTP: @@ -939,7 +939,7 @@ toolSslPacPort - 0, 17 + 0, 21 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -948,7 +948,7 @@ toolSslPacPortLab - 34, 17 + 34, 21 PAC: @@ -960,7 +960,7 @@ toolSslRouting - 92, 17 + 96, 21 Routing Mode @@ -975,7 +975,7 @@ toolSslServerLatency - 80, 17 + 80, 21 Latency: @@ -993,7 +993,7 @@ toolSslServerSpeed - 100, 17 + 100, 21 SPEED Disabled @@ -1008,7 +1008,7 @@ toolSslSocksPort - 0, 17 + 0, 21 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -1017,7 +1017,7 @@ toolSslSocksPortLab - 58, 17 + 58, 21 SOCKS5: @@ -1491,7 +1491,7 @@ Vertical - 946, 134 + 946, 130 3 From 8813d66274bcda47f5b956547fcf7ac5a55f49c8 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 11:57:22 +0800 Subject: [PATCH 18/45] no font specified --- v2rayN/v2rayUpgrade/MainForm.Designer.cs | 2 -- 1 file changed, 2 deletions(-) diff --git a/v2rayN/v2rayUpgrade/MainForm.Designer.cs b/v2rayN/v2rayUpgrade/MainForm.Designer.cs index b9f9ad18..9bba08f1 100644 --- a/v2rayN/v2rayUpgrade/MainForm.Designer.cs +++ b/v2rayN/v2rayUpgrade/MainForm.Designer.cs @@ -60,7 +60,6 @@ // label1 // this.label1.AutoSize = true; - this.label1.Font = new System.Drawing.Font("宋体", 11F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.label1.Location = new System.Drawing.Point(79, 64); this.label1.Name = "label1"; this.label1.Size = new System.Drawing.Size(205, 15); @@ -70,7 +69,6 @@ // label2 // this.label2.AutoSize = true; - this.label2.Font = new System.Drawing.Font("宋体", 11F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.label2.Location = new System.Drawing.Point(79, 37); this.label2.Name = "label2"; this.label2.Size = new System.Drawing.Size(471, 15); From ca9840abf42fbfb079ea7b1c2a76a295a3299bdc Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 13:21:47 +0800 Subject: [PATCH 19/45] code style --- v2rayN/v2rayN/Base/WebClientEx.cs | 5 +- v2rayN/v2rayN/Forms/OptionSettingForm.cs | 10 +- v2rayN/v2rayN/Global.cs | 40 +-- v2rayN/v2rayN/Handler/StatisticsHandler.cs | 10 +- .../v2rayN/HttpProxyHandler/PrivoxyHandler.cs | 5 +- v2rayN/v2rayN/Mode/Config.cs | 289 ++++-------------- v2rayN/v2rayN/Mode/ServerStatistics.cs | 35 +-- v2rayN/v2rayN/Mode/VmessQRCode.cs | 22 +- 8 files changed, 89 insertions(+), 327 deletions(-) diff --git a/v2rayN/v2rayN/Base/WebClientEx.cs b/v2rayN/v2rayN/Base/WebClientEx.cs index 096826cc..e581575c 100644 --- a/v2rayN/v2rayN/Base/WebClientEx.cs +++ b/v2rayN/v2rayN/Base/WebClientEx.cs @@ -5,10 +5,7 @@ namespace v2rayN.Base { class WebClientEx : WebClient { - public int Timeout - { - get; set; - } + public int Timeout { get; set; } public WebClientEx(int timeout = 3000) { Timeout = timeout; diff --git a/v2rayN/v2rayN/Forms/OptionSettingForm.cs b/v2rayN/v2rayN/Forms/OptionSettingForm.cs index 1d4394a8..4d16a860 100644 --- a/v2rayN/v2rayN/Forms/OptionSettingForm.cs +++ b/v2rayN/v2rayN/Forms/OptionSettingForm.cs @@ -458,13 +458,7 @@ namespace v2rayN.Forms class ComboItem { - public int ID - { - get; set; - } - public string Text - { - get; set; - } + public int ID { get; set; } + public string Text { get; set; } } } diff --git a/v2rayN/v2rayN/Global.cs b/v2rayN/v2rayN/Global.cs index 862910fa..3d1e6137 100644 --- a/v2rayN/v2rayN/Global.cs +++ b/v2rayN/v2rayN/Global.cs @@ -173,59 +173,35 @@ namespace v2rayN /// /// 是否需要重启服务V2ray。如果为假,LoadV2ray()不做任何事。 /// - public static bool reloadV2ray - { - get; set; - } + public static bool reloadV2ray { get; set; } /// /// 是否开启全局代理(http) /// - public static bool sysAgent - { - get; set; - } + public static bool sysAgent { get; set; } /// /// socks端口 /// - public static int socksPort - { - get; set; - } + public static int socksPort { get; set; } /// /// http端口 /// - public static int httpPort - { - get; set; - } + public static int httpPort { get; set; } /// /// PAC端口 /// - public static int pacPort - { - get; set; - } + public static int pacPort { get; set; } /// /// /// - public static int statePort - { - get; set; - } + public static int statePort { get; set; } - public static Job processJob - { - get; set; - } - public static System.Threading.Mutex mutexObj - { - get; set; - } + public static Job processJob { get; set; } + public static System.Threading.Mutex mutexObj { get; set; } #endregion diff --git a/v2rayN/v2rayN/Handler/StatisticsHandler.cs b/v2rayN/v2rayN/Handler/StatisticsHandler.cs index ab4d4a6a..bed9298b 100644 --- a/v2rayN/v2rayN/Handler/StatisticsHandler.cs +++ b/v2rayN/v2rayN/Handler/StatisticsHandler.cs @@ -20,15 +20,9 @@ namespace v2rayN.Handler Action> updateFunc_; - public bool Enable - { - get; set; - } + public bool Enable { get; set; } - public bool UpdateUI - { - get; set; - } + public bool UpdateUI { get; set; } public List Statistic { diff --git a/v2rayN/v2rayN/HttpProxyHandler/PrivoxyHandler.cs b/v2rayN/v2rayN/HttpProxyHandler/PrivoxyHandler.cs index f738a318..310054f0 100644 --- a/v2rayN/v2rayN/HttpProxyHandler/PrivoxyHandler.cs +++ b/v2rayN/v2rayN/HttpProxyHandler/PrivoxyHandler.cs @@ -55,10 +55,7 @@ namespace v2rayN.HttpProxyHandler } } - public int RunningPort - { - get; set; - } + public int RunningPort { get; set; } public void Restart(int localPort, Config config) { diff --git a/v2rayN/v2rayN/Mode/Config.cs b/v2rayN/v2rayN/Mode/Config.cs index 0e213609..65f74893 100644 --- a/v2rayN/v2rayN/Mode/Config.cs +++ b/v2rayN/v2rayN/Mode/Config.cs @@ -15,205 +15,127 @@ namespace v2rayN.Mode /// /// 本地监听 /// - public List inbound - { - get; set; - } + public List inbound { get; set; } /// /// 允许日志 /// - public bool logEnabled - { - get; set; - } + public bool logEnabled { get; set; } /// /// 日志等级 /// - public string loglevel - { - get; set; - } + public string loglevel { get; set; } /// /// 活动配置序号 /// - public int index - { - get; set; - } + public int index { get; set; } /// /// vmess服务器信息 /// - public List vmess - { - get; set; - } + public List vmess { get; set; } /// /// 允许Mux多路复用 /// - public bool muxEnabled - { - get; set; - } + public bool muxEnabled { get; set; } /// /// 域名解析策略 /// - public string domainStrategy - { - get; set; - } + public string domainStrategy { get; set; } /// /// 路由模式 /// - public int routingMode - { - get; set; - } + public int routingMode { get; set; } /// /// 用户自定义需代理的网址或ip /// - public List useragent - { - get; set; - } + public List useragent { get; set; } /// /// 用户自定义直连的网址或ip /// - public List userdirect - { - get; set; - } + public List userdirect { get; set; } /// /// 用户自定义阻止的网址或ip /// - public List userblock - { - get; set; - } + public List userblock { get; set; } /// /// KcpItem /// - public KcpItem kcpItem - { - get; set; - } + public KcpItem kcpItem { get; set; } /// /// 监听状态 /// - public ListenerType listenerType - { - get; set; - } + public ListenerType listenerType { get; set; } /// /// 自定义服务器下载测速url /// - public string speedTestUrl - { - get; set; - } + public string speedTestUrl { get; set; } /// /// 自定义“服务器真连接延迟”测试url /// - public string speedPingTestUrl - { - get; set; - } + public string speedPingTestUrl { get; set; } /// /// 自定义GFWList url /// - public string urlGFWList - { - get; set; - } + public string urlGFWList { get; set; } /// /// 允许来自局域网的连接 /// - public bool allowLANConn - { - get; set; - } + public bool allowLANConn { get; set; } /// /// 启用实时网速和流量统计 /// - public bool enableStatistics - { - get; set; - } + public bool enableStatistics { get; set; } /// /// 去重时优先保留较旧(顶部)节点 /// - public bool keepOlderDedupl - { - get; set; - } + public bool keepOlderDedupl { get; set; } /// /// 服务器列表隔行着色 /// - public bool interlaceColoring - { - get; set; - } + public bool interlaceColoring { get; set; } /// /// 视图刷新率 /// - public int statisticsFreshRate - { - get; set; - } + public int statisticsFreshRate { get; set; } /// /// 自定义远程DNS /// - public string remoteDNS - { - get; set; - } + public string remoteDNS { get; set; } /// /// 是否允许不安全连接 /// - public string defaultAllowInsecure - { - get; set; - } + public string defaultAllowInsecure { get; set; } /// /// 订阅 /// - public List subItem - { - get; set; - } + public List subItem { get; set; } /// /// UI /// - public UIItem uiItem - { - get; set; - } + public UIItem uiItem { get; set; } - public List userPacRule - { - get; set; - } + public List userPacRule { get; set; } #region 函数 @@ -467,125 +389,77 @@ namespace v2rayN.Mode /// /// 版本(现在=2) /// - public int configVersion - { - get; set; - } + public int configVersion { get; set; } /// /// 远程服务器地址 /// - public string address - { - get; set; - } + public string address { get; set; } /// /// 远程服务器端口 /// - public int port - { - get; set; - } + public int port { get; set; } /// /// 远程服务器ID /// - public string id - { - get; set; - } + public string id { get; set; } /// /// 远程服务器额外ID /// - public int alterId - { - get; set; - } + public int alterId { get; set; } /// /// 本地安全策略 /// - public string security - { - get; set; - } + public string security { get; set; } /// /// tcp,kcp,ws,h2,quic /// - public string network - { - get; set; - } + public string network { get; set; } /// /// 备注或别名 /// - public string remarks - { - get; set; - } + public string remarks { get; set; } /// /// 伪装类型 /// - public string headerType - { - get; set; - } + public string headerType { get; set; } /// /// 伪装的域名 /// - public string requestHost - { - get; set; - } + public string requestHost { get; set; } /// /// ws h2 path /// - public string path - { - get; set; - } + public string path { get; set; } /// /// 底层传输安全 /// - public string streamSecurity - { - get; set; - } + public string streamSecurity { get; set; } /// /// 是否允许不安全连接(用于客户端) /// - public string allowInsecure - { - get; set; - } + public string allowInsecure { get; set; } /// /// config type(1=normal,2=custom) /// - public int configType - { - get; set; - } + public int configType { get; set; } /// /// /// - public string testResult - { - get; set; - } + public string testResult { get; set; } /// /// SubItem id /// - public string subid - { - get; set; - } + public string subid { get; set; } } [Serializable] @@ -594,26 +468,17 @@ namespace v2rayN.Mode /// /// 本地监听端口 /// - public int localPort - { - get; set; - } + public int localPort { get; set; } /// /// 协议,默认为socks /// - public string protocol - { - get; set; - } + public string protocol { get; set; } /// /// 允许udp /// - public bool udpEnabled - { - get; set; - } + public bool udpEnabled { get; set; } /// /// 开启流量探测 @@ -627,52 +492,31 @@ namespace v2rayN.Mode /// /// /// - public int mtu - { - get; set; - } + public int mtu { get; set; } /// /// /// - public int tti - { - get; set; - } + public int tti { get; set; } /// /// /// - public int uplinkCapacity - { - get; set; - } + public int uplinkCapacity { get; set; } /// /// /// - public int downlinkCapacity - { - get; set; - } + public int downlinkCapacity { get; set; } /// /// /// - public bool congestion - { - get; set; - } + public bool congestion { get; set; } /// /// /// - public int readBufferSize - { - get; set; - } + public int readBufferSize { get; set; } /// /// /// - public int writeBufferSize - { - get; set; - } + public int writeBufferSize { get; set; } } @@ -682,27 +526,15 @@ namespace v2rayN.Mode /// /// /// - public string id - { - get; set; - } - + public string id { get; set; } /// /// 备注 /// - public string remarks - { - get; set; - } - + public string remarks { get; set; } /// /// url /// - public string url - { - get; set; - } - + public string url { get; set; } /// /// enable /// @@ -714,14 +546,7 @@ namespace v2rayN.Mode { - public System.Drawing.Size mainSize - { - get; set; - } - - public Dictionary mainLvColWidth - { - get; set; - } + public System.Drawing.Size mainSize { get; set; } + public Dictionary mainLvColWidth { get; set; } } } diff --git a/v2rayN/v2rayN/Mode/ServerStatistics.cs b/v2rayN/v2rayN/Mode/ServerStatistics.cs index e4a42a5a..f6c655d2 100644 --- a/v2rayN/v2rayN/Mode/ServerStatistics.cs +++ b/v2rayN/v2rayN/Mode/ServerStatistics.cs @@ -6,38 +6,17 @@ namespace v2rayN.Mode [Serializable] public class ServerStatistics { - public List server - { - get; set; - } + public List server { get; set; } } [Serializable] public class ServerStatItem { - public string itemId - { - get; set; - } - public ulong totalUp - { - get; set; - } - public ulong totalDown - { - get; set; - } - public ulong todayUp - { - get; set; - } - public ulong todayDown - { - get; set; - } - public long dateNow - { - get; set; - } + public string itemId { get; set; } + public ulong totalUp { get; set; } + public ulong totalDown { get; set; } + public ulong todayUp { get; set; } + public ulong todayDown { get; set; } + public long dateNow { get; set; } } } diff --git a/v2rayN/v2rayN/Mode/VmessQRCode.cs b/v2rayN/v2rayN/Mode/VmessQRCode.cs index 0a9cc8ab..4c5cb520 100644 --- a/v2rayN/v2rayN/Mode/VmessQRCode.cs +++ b/v2rayN/v2rayN/Mode/VmessQRCode.cs @@ -8,46 +8,46 @@ namespace v2rayN.Mode /// /// 版本 /// - public string v { get; set; } = string.Empty; + public string v { get; set; } /// /// 备注 /// - public string ps { get; set; } = string.Empty; + public string ps { get; set; } /// /// 远程服务器地址 /// - public string add { get; set; } = string.Empty; + public string add { get; set; } /// /// 远程服务器端口 /// - public string port { get; set; } = string.Empty; + public string port { get; set; } /// /// 远程服务器ID /// - public string id { get; set; } = string.Empty; + public string id { get; set; } /// /// 远程服务器额外ID /// - public string aid { get; set; } = string.Empty; + public string aid { get; set; } /// /// 传输协议tcp,kcp,ws /// - public string net { get; set; } = string.Empty; + public string net { get; set; } /// /// 伪装类型 /// - public string type { get; set; } = string.Empty; + public string type { get; set; } /// /// 伪装的域名 /// - public string host { get; set; } = string.Empty; + public string host { get; set; } /// /// path /// - public string path { get; set; } = string.Empty; + public string path { get; set; } /// /// 底层传输安全 /// - public string tls { get; set; } = string.Empty; + public string tls { get; set; } } } From 28826cad1bd8758405275580123fe818ed75e0fc Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 14:33:30 +0800 Subject: [PATCH 20/45] refine code --- v2rayN/v2rayN.sln | 7 ++-- v2rayN/v2rayN/Forms/MainForm.Designer.cs | 1 - v2rayN/v2rayN/Forms/MainForm.cs | 49 ++++++------------------ v2rayN/v2rayN/Properties/Resources.resx | 6 +-- 4 files changed, 18 insertions(+), 45 deletions(-) diff --git a/v2rayN/v2rayN.sln b/v2rayN/v2rayN.sln index 64cf71f4..f4dc9d50 100644 --- a/v2rayN/v2rayN.sln +++ b/v2rayN/v2rayN.sln @@ -1,7 +1,7 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 15 -VisualStudioVersion = 15.0.28010.2050 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.29926.136 MinimumVisualStudioVersion = 10.0.40219.1 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "v2rayN", "v2rayN\v2rayN.csproj", "{0A9785E6-D256-4B73-9757-4EF59955FD1E}" EndProject @@ -35,7 +35,8 @@ Global HideSolutionNode = FALSE EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution - RESX_SortFileContentOnSave = True + RESX_ResXSortingComparison = CurrentCulture SolutionGuid = {56B88873-C9CC-4069-A1E5-DABD6C6E865E} + RESX_SortFileContentOnSave = True EndGlobalSection EndGlobal diff --git a/v2rayN/v2rayN/Forms/MainForm.Designer.cs b/v2rayN/v2rayN/Forms/MainForm.Designer.cs index b8d03aca..6aabf5cc 100644 --- a/v2rayN/v2rayN/Forms/MainForm.Designer.cs +++ b/v2rayN/v2rayN/Forms/MainForm.Designer.cs @@ -167,7 +167,6 @@ this.lvServers.UseCompatibleStateImageBehavior = false; this.lvServers.View = System.Windows.Forms.View.Details; this.lvServers.SelectedIndexChanged += new System.EventHandler(this.lvServers_SelectedIndexChanged); - this.lvServers.Click += new System.EventHandler(this.lvServers_Click); this.lvServers.DoubleClick += new System.EventHandler(this.lvServers_DoubleClick); this.lvServers.KeyDown += new System.Windows.Forms.KeyEventHandler(this.lvServers_KeyDown); // diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 59cb17a2..4a0f04b9 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -312,24 +312,18 @@ namespace v2rayN.Forms private void lvServers_SelectedIndexChanged(object sender, EventArgs e) { - int index = -1; - try - { - if (lvServers.SelectedIndices.Count > 0) - { - index = lvServers.SelectedIndices[0]; - } - } - catch - { - } - if (index < 0) - { - return; - } - //qrCodeControl.showQRCode(index, config); + RefreshQRCodePanel(); } + private void RefreshQRCodePanel() + { + if (scMain.Panel2Collapsed) return; // saving cpu. + if (lvServers.SelectedIndices.Count > 0) + { + int index = lvServers.SelectedIndices[0]; + qrCodeControl.showQRCode(index, config); + } + } private void RefreshTaryIcon() { notifyMain.Icon = MainFormHandler.Instance.GetNotifyIcon(config, this.Icon); @@ -464,26 +458,6 @@ namespace v2rayN.Forms #region 功能按钮 - private void lvServers_Click(object sender, EventArgs e) - { - int index = -1; - try - { - if (lvServers.SelectedIndices.Count > 0) - { - index = lvServers.SelectedIndices[0]; - } - } - catch - { - } - if (index < 0) - { - return; - } - qrCodeControl.showQRCode(index, config); - } - private void lvServers_DoubleClick(object sender, EventArgs e) { int index = GetLvSelectedIndex(); @@ -1601,6 +1575,7 @@ namespace v2rayN.Forms { bool bShow = tsbQRCodeSwitch.Checked; scMain.Panel2Collapsed = !bShow; + RefreshQRCodePanel(); } #endregion @@ -1629,8 +1604,6 @@ namespace v2rayN.Forms RefreshTaryIcon(); } - - private async void toolSslServerLatencyRefresh() { toolSslServerLatencySet(UIRes.I18N("ServerLatencyChecking")); diff --git a/v2rayN/v2rayN/Properties/Resources.resx b/v2rayN/v2rayN/Properties/Resources.resx index ebe3751a..7cd3b257 100644 --- a/v2rayN/v2rayN/Properties/Resources.resx +++ b/v2rayN/v2rayN/Properties/Resources.resx @@ -163,10 +163,10 @@ ..\resources\sub.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\resources\sysproxy64.exe.gz;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - ..\resources\sysproxy.exe.gz;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + ..\resources\sysproxy64.exe.gz;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + \ No newline at end of file From efaec3ee17edbea705775fc190514823feb50b0c Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 14:49:32 +0800 Subject: [PATCH 21/45] refine info --- v2rayN/v2rayN/Forms/MainForm.Designer.cs | 1 - v2rayN/v2rayN/Forms/MainForm.resx | 11 +++++++---- v2rayN/v2rayN/Forms/MainForm.zh-Hans.resx | 5 ++++- v2rayN/v2rayN/Resx/ResUI.Designer.cs | 2 +- v2rayN/v2rayN/Resx/ResUI.resx | 2 +- v2rayN/v2rayN/Resx/ResUI.zh-Hans.resx | 2 +- 6 files changed, 14 insertions(+), 9 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.Designer.cs b/v2rayN/v2rayN/Forms/MainForm.Designer.cs index 6aabf5cc..86899312 100644 --- a/v2rayN/v2rayN/Forms/MainForm.Designer.cs +++ b/v2rayN/v2rayN/Forms/MainForm.Designer.cs @@ -631,7 +631,6 @@ // // toolSslRouting // - this.toolSslRouting.AutoToolTip = true; this.toolSslRouting.BorderSides = System.Windows.Forms.ToolStripStatusLabelBorderSides.Right; this.toolSslRouting.BorderStyle = System.Windows.Forms.Border3DStyle.SunkenInner; this.toolSslRouting.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Text; diff --git a/v2rayN/v2rayN/Forms/MainForm.resx b/v2rayN/v2rayN/Forms/MainForm.resx index 6a15bb40..43d513f5 100644 --- a/v2rayN/v2rayN/Forms/MainForm.resx +++ b/v2rayN/v2rayN/Forms/MainForm.resx @@ -882,7 +882,7 @@ toolSslBlank1 - 170, 21 + 160, 21 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -891,7 +891,7 @@ toolSslBlank2 - 170, 21 + 160, 21 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -900,7 +900,7 @@ toolSslBlank3 - 170, 21 + 160, 21 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -965,6 +965,9 @@ Routing Mode + + The Core's routing mode + System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -1161,7 +1164,7 @@ 393, 22 - Simplify PAC (need to set Core route) + Make PAC pass-through to Core route rules System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 diff --git a/v2rayN/v2rayN/Forms/MainForm.zh-Hans.resx b/v2rayN/v2rayN/Forms/MainForm.zh-Hans.resx index 71c3ad06..b8045d6f 100644 --- a/v2rayN/v2rayN/Forms/MainForm.zh-Hans.resx +++ b/v2rayN/v2rayN/Forms/MainForm.zh-Hans.resx @@ -375,6 +375,9 @@ 路由模式 + + Core 路由模式(预定义规则) + 延迟: @@ -409,7 +412,7 @@ 223, 22 - 简化PAC (请设置Core路由) + 将PAC改为直连Core,按路由规则处理 85, 53 diff --git a/v2rayN/v2rayN/Resx/ResUI.Designer.cs b/v2rayN/v2rayN/Resx/ResUI.Designer.cs index 916fc039..04d27e9e 100644 --- a/v2rayN/v2rayN/Resx/ResUI.Designer.cs +++ b/v2rayN/v2rayN/Resx/ResUI.Designer.cs @@ -484,7 +484,7 @@ namespace v2rayN.Resx { } /// - /// 查找类似 Simplify PAC Success 的本地化字符串。 + /// 查找类似 Write PAC success 的本地化字符串。 /// internal static string MsgSimplifyPAC { get { diff --git a/v2rayN/v2rayN/Resx/ResUI.resx b/v2rayN/v2rayN/Resx/ResUI.resx index 9066ae09..fc9d5ab3 100644 --- a/v2rayN/v2rayN/Resx/ResUI.resx +++ b/v2rayN/v2rayN/Resx/ResUI.resx @@ -259,7 +259,7 @@ Resolve {0} successfully - Simplify PAC Success + Write PAC success Start getting subscriptions diff --git a/v2rayN/v2rayN/Resx/ResUI.zh-Hans.resx b/v2rayN/v2rayN/Resx/ResUI.zh-Hans.resx index c88b54ae..431b9663 100644 --- a/v2rayN/v2rayN/Resx/ResUI.zh-Hans.resx +++ b/v2rayN/v2rayN/Resx/ResUI.zh-Hans.resx @@ -259,7 +259,7 @@ 解析{0}成功 - 简化PAC成功 + 成功写入PAC 开始获取订阅内容 From 32b98524ff7726fa2241913a26c12612f9bdf736 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 14:55:23 +0800 Subject: [PATCH 22/45] fix crash --- v2rayN/v2rayN/Forms/MainForm.cs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 4a0f04b9..1b5a03da 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -1103,8 +1103,10 @@ namespace v2rayN.Forms { up /= (ulong)(config.statisticsFreshRate / 1000f); down /= (ulong)(config.statisticsFreshRate / 1000f); - toolSslServerSpeed.Text = string.Format("{0}/s↑ | {1}/s↓", Utils.HumanFy(up), Utils.HumanFy(down)); - + this.Invoke((MethodInvoker)(delegate + { + toolSslServerSpeed.Text = string.Format("{0}/s↑ | {1}/s↓", Utils.HumanFy(up), Utils.HumanFy(down)); + })); List datas = new List(); for (int i = 0; i < config.vmess.Count; i++) { From f9c7556c540fe57510e53ceab0e04017418f71c5 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 15:08:53 +0800 Subject: [PATCH 23/45] Take multi-size icon file --- v2rayN/v2rayN/v2rayN.ico | Bin 67646 -> 82726 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/v2rayN/v2rayN/v2rayN.ico b/v2rayN/v2rayN/v2rayN.ico index 2a2f85a92ab846518d590b2ca8aa5fb0a1afe904..4b988da4a5680a77d5d64000d0c0c95cf26e2462 100644 GIT binary patch literal 82726 zcmeHQ2YeJo7r(vBT`K97k_IG!gj7NZ=`tGSyU$D3vr#eZTXoQ1B}+xM;WcHaczr0baX^;L2yIxK=4BF zMyQKW523y~G(b#&rRf>vp}h1Cy-Q_KSyU#KO?6ORj3=0!Aebya(_w)1Io7|$^v38X z(1~b9^z-E~7)m*=p-jd#mPxrF#36Dku8Be>3$>AJLKv0k2<)OUlcN$X}R2G$~ zE}QBgo}fC#{J`V`gAWeR1Z4yudlRM$-~5G(`}!A39=FA&TGyX99o3=r<9ualgmv6#kdf#!J70R1wM z`Y8HrQ!AM)45)4w})bliuzUIQ;pP z`meNX;?{x6q_U|Fs*CERx(Nn?1+dXL!gzsTC720zYJ-IjfCK}7jP9g&QGaqmpmDgq zR4NIyl1hUiqeFrJaL^*s)5R{nb(Ck9K2P|)4mwZ%?9H&XOGiZR_;y_LlN%<*UE4A> z{=x4v67qJ=Of1|xCt3OTyk!2s{1pD+f)xJHLUq73rT60*@)Yfwl~l0fvxL0NsjVLT zI;G{c@6uyWE*lZG-6pte}}07xj~ zr%iVnU%fE)`jWh*zQ#$oFl)J0RA60)#Ag%hy+r+b*4xe2t^Oe92xxu%chGFloFsw1 zM;4{>$1~E@A(cOtp$SS{mlcG($C01Ce-vdAf9yrsJ3ddy+c>4=^);hoj?5kuzK(eA znZ&w11AH73t>yA)f>A9O8WHT&1_Wx0g%5xP9Y1ZlldkPeI+vA<3&QvtDwE10d|d6~ zyC>IsY3$1(pDY{}vH8adEiP`G-YSp!G|~FlV$f?znv&=yqP0=41)e}1R2S6=S)$wy z+42)$Su`|a%a~rlpFW#Z?G{1Ztaw4}b*xi0(|Uqd67HO6u=^ zgfsN{P#c9+WK<)UHWxWdjJvxaZ}0AzouumLf=sVAdY8#(G+vNgz&N4Y_;Jg7O94BLQLUpr zJ5!siWYRG3L1StwwOQSE!a;4)4OpKiIY{!bF8W79%-xz=E36_?BRx8N*gItESMNt3 z+A_6OF7+#Qf2_`a&R{S!7GT{!Kbg;*)+%=u+A{X#;Au(W?j67f7#E~8Z)iwuSL1+i z!DIn0AIqP1pZCNKlJ&5)NW)`;UE7ZC88qRm_hSxjoz^Ok^exDDlaA*Vkn@Jpy;MHP z1SQQgwnA4~`Cjy)Q9Xht#ss;xmC2;x)ONxFsO^bBa`17L1&sDICnjCk2Xm!HGEUmm z-PtB~VCR50F&E#u`P29ZG&eH`UCdnvjSa-po6yFELnF5J@8I{Ao0Cl};ec>KI8oz< zaP&Bh2V!~e23tu3veR*#wAquf-km;sBkapxK8m}x4|6L)hp#?e&TM?QZ*DTbeq!A9 zPyf?&WxE)!F2F@N;e>Dl+LLYhaTyPY_GAMiJGlqOJbx=G7gE>VHg-t2hC^1p7rhsD zmO|BB{n6CvOeH6%&D8egBcuL)qf5Xr*q~zxH-sa?6$0Uma7Q?-i9dpy>|Qjkd0|Z@ zP|8U|VV7+)V_?|AUnj@iRO@y%Nv|`ij3C{BbVSI%TT@yaf&vM-V?Yr)`%Em*VY30yTJ zoq%u$+S9sHP2vHfJ?XJd1V6^L#16m zc(87Ki_0TkXq@g+M-c;^0PBl_oq%}YQI-RY_9XM`D&$;H!@3SFr@kKg*?&K7d6VYA z7TW8kyH`px~x{hBOl;#VgDbHhf2Tf(s#*N@6rK(-xWj)#8lrGO1T zEYLB2?mNwvY@gmLht@_cw67cv2zRg-J%pWLSySIS3D$C9?SSS5kILMTXis))JJ8+} zbJxJ2`VKAT3<{rzwXhuUuw|?-r=OSCHwcHYi{?yut;s_8J+veo6Rrv8YTOeIs^iCO zy0(DF4Zd*!9!@rqkohw(zq@DY_m%7Oy7+-``M*!%?@#F4WTv~LO%&mpa1Nr=8gg~n zikZIWESE|fV9weUW7TMk_cv+m($x;jy~^W-a0;8*?NKi_P6w_-3Fn|at)*1QoPdq_ zb+Cq27a@4u%Rz%MR$a8vzVb9KuYb_I0KP_-2R|D)L=K!=S#dNcVEUlB#sMbx?O>n4 z8ZOsxKqvp_ew*C#_#v!smDdK#^Q!R&*-+MuX@0V2>-sOr@NEKoN|-KSu5p0mzBTOB zgPp$32pIF(cl6+G&IjaNbj}#n)^WUHk4(r}<7-&KM@kA3gAHb#2 zf7JICutP!T$ z`7qA7NF`GLkNSr6|LcpyYviwGnzm!Di0Hp_E?=1ckk7k+jla14Q$A}&M-$a&s&<&Z zT#N(C4U^+;40(kaZ22lBPNpjDt;2vKbJ33 zD*4=7=lM%Jrb8|~W#Iv>IR^PrEgKoNBQ4TB3Ev-jt7&B{86b@NHVUb$wOr`QIQg%h|j(K5C89`ao~X`O<1?-`>e5LCixb_zx?6&z9AD~8w?;? zK?aar&=`7v40a}a*qgn3wXT;6Kcxevllu(!V)~>1gZ3=sTtCJCyJb9od|7)74~XOd z`B$tR+x*DWab9gm2EabZ^Z>9yrGLafa$9T8St{lHSB{FB3?KG<_;HvR_xkByR9ML8 zT+8Cm{W=^x(9Xngn7WQ5j{#5nrTy`F z;z5!%kY6Uy`Ng;>gZ^q+@Zj=c{-57Q^2e99weWzdKPqW1j(rb~c2DwY2fBNxX-B$y zWq!mrR`xbBM{BvX0etn-A!G8$XW7`}SLyP~r+-mlK7aqhKK|@aZ}P{Mw6^d7cz|ew zJrMFC118%lq`pKuq9HPjl>h@Rwm$7K4(40}`TYZv9-(%PDHBN~GKm5~857<%oc63z!Y{~PH0ch$1r41LXj{;wVf z3JY@iJ7>4@XTI-i2DrpL`siN62jl+OUO_{#F62Wr1pR3)SdpKg_t{y=onnJsf>GYL z>b`FV*-v;ioc<&S3JdbU1KapB>;8jxO*t=pbZIUcLzQF?STZ7VeOQ2FQ+v6Bd_*d$ z2Xc0{9DRrCI_cGrj+pPCHDBMaIQ<14$a}!w%KC*r{Y|f0F9&FC2>#>$!Y|`lqM@yd zmKD(fWNvj7_KtRPpC8A^jz@X4AUE zOf0}&cAq%e%j*#>!3Tzp0i4`QVr69|sRQ4R5ZL)Qnz!#)uKzP0D0p~>zj1gifAZ_+ zYBdj#9*BL>wzUX$3024?b%>_m0YhW}hkmbskEzS_0ZltV@4HxY=udV+C13FHE`R;t z>e|f%$H1@l%pV;DqV~f*F=-VTf`Qq!!$p2y+ zG4VkD{pv(|X0qZ|%alC&A-&D}v0i%C;Iv`ii1KI-e zVy~(furI+i^N;;i(f`C_K=F0%-HZICKW5ZA9w6FbFST2+1@#6^>-f0K%hLh4hF%WV z4%Twl|9%`l8t)gvo?>R%Z+!X}6&3OiZ)OWVM5=Y;+My4CeoE{qQ8??ZW|N%k6z+kZ z_GAk#YYxCU+gRJAg}c|o*uOkWCHo%(`a>3A-I#bl0hJAf0bQ8Jr;lm9$Y=f|GPOI>&9)Wp|d=T-Dw{Y8#@(^!3L#&^$0rej5QEs0IEbi_>`cYi7UJ!MByYmBOx`v%Ov&(9gq8W{>qE$cv899dACC^rv-0 zVcmESe{RFD$9~i#~se!kE1mLhd(|` z_!x2nb3gOISGpe4_kSiA$ammw_748^_pd&-W5M5ZlZ$XB(q}|lKVN~yy5;~}XkBNy zgPq(7XC=)A{i|W#$N0^B^jD1qc`Dz5Z(qSU_t?n+;X6Ut^D-Q4<*p&#PWpU7xRwn) z9YZH z5x&lfUajkU!Qbb*+D3okfdcptT|cx2>&7pbS>I)H&m^(n7yiSC&DXb&@vI-=>!O$b zP3k%+26puK**`z!=h{er!FM3{9)IJ=cl^oKkB$F`aBkB22`&EHt(CWLQ_z@nJp}C^ z7vI!TKBQYf;w5s+azf#4soM@aHV_ z7yL(ZZu8gnF9#2Ft?6TdivAz9*xa*qUB9Ge&ZPh8{5AJ?vl`Yt&>OyEwN(C#?8MLq z^6p*XFaI@*KOyWpP-E8&8T~i*NUhr-Ho#3U{nMIwS-siW-vfRhwNn3MHi6<;$>-g@ zEbu_qiWLvwwl8r~_uUm6pE9@)hjPD0l*39u=wNF4X{Yv)d z%HDr?>l}Y!>tyx512s+#2=hPa|7+VtdwO(;sH>O$eZr$;jl3M}U@w}Zrhhe!eVG4a z|0lNpOZjwz&u{L1p|8@~PWkyO&KKl6K>JZ0uX%e@+hlKS#JOr)gSOUP6Fl|$0LMny(Y#Q;b7s!D=o5UVrfJ~{N{SWldxthhF`QbHT zP50ivdxZ5plkmXRg5h>6Zm!*Htr+9Jo+~f+Z|MUj^ zYtH(wn*OK1dqr5wJ@?CC{@y=3h3`UXE@xCez`g?yE*;|k`So3#H(xV+h_IfMvv^p< z>;7KWif0n&*j?SfH#;}rLK@i0GpDv{5Bk>}{|^oQ```>woEMG#AhNM91br7?m{0o$ z8JheB>ZLz%g{#CxhV!Swu*cKs8sq<0 zg8u4p89Z=y-Ru0FGh2l3LXFJ>wC}*Z^Sj_b@&?AUM|aJT=$|<)K6~P;A<^{|u6lJp zjYM#fNEZwa_lDnK&GG-#MSnqeNfUH}TUi@~`GN6y0Q(MPZx?)sO8YQWm+n-uUh@CM zKEZ$D%z%1!zUA)&(kaD3iv438F=tp>qx(P8UE$Yr`rF?8&138EUFdD2j|KG2`Ry~A z{ORv7_B?`efaZQbj&JexfR6soJ)U&ZtNXM5zvT5eu3e;;0&BpdK>s50AvZs7S5E&I zXs}rKyo~k|zjk0HpAWmfQT0JuH_pet11C1{XTIxez}%)}|1>3Tk1t78?wgxbguR+S zObGF?`J_i=x%A&Mw3DD8;QNox7(1@li0}XO%KwtMKKXTb6%RbPZe%$?_NRON&ExCg zJMjD?!vmn75_G(^tw8 z*i)K#pyGDGvfd#ZB<(wJYR!v}1`pu-Px$g4oAp*$w3xQ#U61J!DqS`_(&fmal(j^E z^N#_hqd)Nhohfl;&qCqb;Iimh@n_g~Am=83{lHi1Z_Z1~AI5{`h>2#jALNEfE!K^E zp^@i^r$fq>{fsZBj`ScoA%!2vyP!YW0nMxfn3n#u9|W!GUi|%2tQlMqz74E6t@X(c z8Vl}1#w_4Z2J3#AK)pc$K(F|wvT+0|1**@Oi!{ENJVGNms z`ysuB2fhQ_Xnq~QJoIP#4F0?MLt*`>5Vl=o@#DV$&PlxRK8W$uWQY0Q4_3?-*b%`m5ytz5~6m^&{cCP}(cNm^_es`#i>( zsls_C#q!OxV*=^@n77h267~5>Vb*^Ued!OMjvZ?ITWm z%G18$^i7a4d4PO~E^LGU$d~3jy99f|pI<&QDvjuQcl?k_(f_mVExGj*;#@HX2=f5o z$xM16=wHG0e_H=7%l>0X-yw(ZKY43I&f%?joUGvoIclvZ~^?d{FKZfuC z!E*M;*M)Ba>Fg2`^e5+|62GYN1PY!XokoggR3*TcIB#Vtne;NzG1GIj8H~V+P>NnJm1mCp# zmkz4-o-mQ`z!BJduwVDy`9s13;$thW_Yuv-zg_P>$9?%utPJ~si~#-fXYxuYZfbkMTAi>oWAsMaghm_#Vrk{%2(R3vkoA5!Q5Wo%j{&$M+!zjO0T=d(hC? zCFDP1|fpy_GF^--BkG1 zj?0nztlyb}{=~n;12|WJ_7$gZ0}bLu22&X^?LBe#pTE>+ml)5sLi_#w{#mP|Uyh23 z64S1#*Sq`whnxO-6FKa`W7RUCoW5ON-^X(e{m)jtZ<&hzY8ggrhc^y?E66Eh$pK;C zfpdRA*BD?FA0p^|Jm!1_u=h?J@U*XDdDpH+>-)q%?Imrwy>pX8j3xtW5dCR9IJKq+ z)^@&DuOAy{EFk^z_UTPHyQE*0`xEtj%=wP2dOs%YCC7F~r9G1$+h)YdP|q;PfZQtU z0X2;N!~-X>c6jyg<-*?5#*qU!vw(aDPW~4@Dz8+Y2cVOo@8{t>?)Rn+Y^?YD4o1hS z#D^B7`9TJ3sq$PvL;q~yd{^D$zqUT0I}Pk`6 z0sQI7hpG@bsC0lFrFoUmhrm~c(6K6cPOR*LwVgS_x>2QJ)@pCwy{oD-3%=?G_$$-~ z^6$U->*TnXdNz)d{_@TfCXxM&H@3dthWqpLggUSXECvrKt1=GIJ{uQzOhtcMSjDgi zd;5ND#_#p9evCck>06*Hdlpm?_TskF`PQe_V*eS#=`Yy&u)p83jG+-u>xWg%*28FQ zNQ}MZ!!Zu*tJ*jK-xBP@O7mbLJ+@G6#3jW!xdp%Rn>@r^$9~}Fn3wR){C+L5fc)&t`)ARw%wfF-IQm*_y zBcb==en}Pg>C;6#Bi%c)AjKMepKOD7EV_V6=nsGHl)F2>NF1>)J(kY#c%**Id!};x z<|I3U2R;E01xgL7ltLHpU@0n41g2)d2B z9~JDKn>263YT`S=cJ>9%PJb&WwAbCr>mk>(Bh z&p~)-84D`T2Q<%v9{mu$m-BFrtB<+pX3TnyEKG9;AAAZPxQk$!8yYwske(0v-#xS- zW$GWFC3zT=Cgv{d@PbrF(4M{{6y}C%zP8K}b@PIf?7Fb0TmkKe|1l%c$=viZc6}Ky zrf@swBr6~XdVvQ{3Ua_=D=y9d(D5-&qTi>T#60iiU#G-bf8DpuBVpgEDo<<}lExid zlqN&_QbB*(SEzv6YOxck^a8?#8Yf#1FHTMSdv20!)9|*B1?{zY2Xde>+ByqCr4xYf zYcU@PeO`@=S&;jUwej^hra^Ce$hlY1?)?Zw;Qw031Jq_}JK=zEK{$CFX|1nKe}39p zhIU6F&^}`~5#Ym7D`Wxd^R&O_Qo;e@LLZ(U*ZaSYQu!(!UD(lYziEWSK}%lG4TP-6>5@>fO$N9M@q1# zQ5%Tv6R2(3OWO8dn>vNd~jxInpM`4RNt&6t@{CwKOme( zp!ovXNtivkI{87>&j}V4%}Jjp7y&E6oa#$$AUfV#^_)f4SCFCkrNacAZ5+~`%UaUL z6?jcX_z;2o4X-1p#|M>cFw+2IYBa_GC{CWifBz`Qyo+n)k$@~N3ak~ z1e+ePEw_z?0erra9ZqFZ z+2>Yt(Aa9IZi2ydEwq$uC#Rj74#$_KxnwPE z<9=dkYcC3PE!@L1%0qcsz2Y+H9@W9me?#+}<+H?(9tL*LEZ+N!pFfDp`MMYPS8+KHtzRcTEDs-&g>_3ILex&Wbe%HyXhKwX?f zqAoC#y{|4XouxTdewI{Mpe#<0qYRqr)D>!~Q&*^|PF-Pk@%z^Fer9o603f|MEdWrQ z6aWxaFOiHZQM~|w2pl0T0!IKy1dafZb~;;J9{|)&XNsQ#;B;{s0GF8tQ;4%ugS65m znui8zr%N;s4Jmro0hmH*5kTW8EdoGD zmP)5H00eME7*UTOnhO0??`tYdQKgI6`&(3LO$F*Czf_e$&eE4vX)l(}SEXNJX=OUy z;Ks4EibiT^=w=Q*e@F9}SN6fF?Bj~l{Ju=tFj10MX3E5m#gEFl4na+k2&e&@1^eS) zB1t!)7h-ZVH?Db*lPtc8i=v*pjco%DTYFzm+dArCU*E&VHX+ni5f|btYZK|NnTHF2 zRns5f;bIy)DH?d#INICDyyP;@-_}~z#MMy|8;aS;fRui z>lCn$)FtdAc6!-}s2%CZ(>=NFy8%A-DfBLt5#sA$`*fWC^W%+0o{lZOxKKX_Te%hI zqSUe|qkm&%~B zdbO=T+QmU0;o+ok=@{o})b*z1a90KR)+aW|r3=oB-*s?)av{NEypXCyI|^|w#jfba z&Rwalv`9CFG5Dr+l$(v6wXEU5PW}@?^Sca>EXMkuPTU%LUn`&T&o2`0{^x1GN$Bg1 z(9f#$J${=gcN^C_^5BnN4OzZ_esZ3;E)&5o;9@`a3`IZxlIm_>$u>OE+(Y5!C~rJ{ zK-1OuZl%b0ykZ#NQJquzHCcl;G=8duM}>H)?-LDV;2B?>cf9QIqLd=SI|~f&EEdzG zGS_9jLv0xUO7NEiOaBhOn)Ri!`o(~beq4aJo%7Icfgc`RkenxmQ(TwozG^>7ah{4^ zi_6q?O}sR)qu+!;A3K+~y7-qXTZ!M2nz=rK^J(vDmnTkVt?Z(tb0TO@#EQZ!&Mz)g z-!^IuRAYLji zvwZxsyco*{eA2&(Mh=a9p`rZCkx}#Uyz20S7PN0Rov(;JQ_JNg1{1{wUMpt|2wgn# z`Gy*uV&Kz$_Lw7O8p=C*`G@flwITPO^1{~1O6=uobYA*Cz4`Y3Px)&0haA>D&>iD+ zR(Uum#!ngi1K1fa73Ae8&*NMx>zQeG0Ntv;Vjee=IFOxw_herfL_FOY2|7c_q+K_wiiZc7>K}O>v>??lb zi#I|WG5A-#9~FST->;bh|BRRN?q5^V`D@zv)=m=+%Y%d9pF1e5A%j0-ScDJoUnTy5 z9>Etpyvq~b8O$ZGiZ|>+!1aPeJYj z<%Mk@D<9ta2jf{$@tB78hM~;)L?#*Ut;QR9vRv@@M0exUHK$X{nhD z0RP6~20v_S9QyEYj0Oa2F}$kl;~tL$2ICI#j<)CN6rsgS>!^@|d1C{-VWSyL}~ z6aDsouyK{(9o7cyJN`2A>Yu-04||;LpagH=tizGujbie&>%CR5n$Fn~CYv0#SYts+uJd926mIbS>XMkUU zFc;-loBbBB7eTj~zjsceX0E6UR(BVH2In&73h_+DkMOT7br$Gtr4lQs|VR|$4T7nG*}{KF8?r&Vy92!4VcYgDPj zAVVs}GYn>3G0KiX8-7QO^*aM)je-0|WeR04PL0u3x3TV_9@TZDY{j{4o+RF*Mds!SQsmpIg4AF#ZP zJ-p^3&O|tYa0&NsP@rq|Jv>XBgKN?g>(jfHsnb;N048dS0>Kfmc>_*A3Un>pQ$2g6 zU^W#l3@sOqXYk&F!zbLY#!(EfDL;y{B@%0jGs#;GaXS2nD5iq(CwOa(lSl-osuYPt zaJKT3NCdAh?0&=IY|3vfk+3+E(pU-Aj??KrC}XNPlgigoZ#LZ*!N=fcF>4oVCyQD8 zfeHa18vJCd@rDAN@Q~cxQYhAhY&h#tntl>V2wwL`NJY^2X*nZNh2OZB8_Td(Ydff` zzq7ZiwKsgR8c^_Yv-TeRY=HBiXZ&r)zY=87dUQp=7}(L*D!!?+Ye)l!;I`2oeXve2 zWkR3eucrQ|={gE@4d03>^o;VfLf$tz`&HT31#Phk^sxKBLujrca^Y zYvvT{F<qCC?Fg#MHe>e8d3k6pmTK0%d&1MB-X5rK|juwj3_WopZdhZiLqtm{$U z%~RtqPV5`JCOpuw*@Qkp8k>|Mc<&VNS*L4)_ggp{`g9rX)o#BgEy9iR=Z{*P?i}y+ zHrCNftgY#TV@%IR_Q>B0bHdBea}91YgHt;`0$gD2_cDB+UdCE*nR?$eoLSy2(R(0h zc$wP3+M%Lv@w`u!E=7M`?bqBR7=VK}rVnURYK@d|F=tRH*Dl(<@&7)KJ4Njl*MDqj zds>IqlvSDfsZ640>qxhtx$lIP8moqN5AcNTeuXyvC=Hva^5%)(lqXg{r!{ZYGY>68 zH^lnhs-fKiytL{6Qd-@Pu>W4rSARb2h&PV?gf-OGRe~XNTKt9X$=;pB^)DRK%xc+) z$Zt@$fOmpHjDKo>VS&ol2U`qJJ|>Jebj7;vu`-DtXTKfx{i31a8a}|9mHXfGlJu_g zsOuN(L-{#(lvnpHuhRM-Y(>`xcJdR}$+mpjl3O?=ybEB~=$H&v)(&y|Rd%%k>Rm9@u;OVk&>y>rJ1{oZ6E6eq4+UcIWr$p1vS%KeLVH-M_B9^v7p<-_chVyFY($ zv(c~@%f1~KWBt>F*oC@aW%o+8U%i%7P>_eUktsa&PnMTr@io<_E4})I=*4SBN89{1 zxrH6@u!_N@E7sM1hKGlDE-24$POmT?ewo-}_4*01_M4}+w1W+3r7jrRJ#qU5n|FcA zW=t>;KhPS{KO0ApZ-CHN_Fh>rY~5e|inhZ?SAlhs`MTQ8?upxL9iwBGa9hnRS4jfSLRc)9V+}iC|^?UdTE^Vj0nYDo@*{rhn3U+UtbNvsUt&R2< zukVY?h7aGhKR$0&LLYz+5%qym@|R>SwTG>>5dOt-=LF8bzJB;S!h>clhOR*$<*9Fa zl^Qc?9K`s(nzfz9hZiQNq5ks(Ckw~1enWQg0+DT=;h*IZV%Tl3?q8wI%eh@l5A=}- zSB_%Ld|p!?<=sC&>HN-FiLF_^ECyVT2#bJo4IiSNe9rZg!rCk0l-6Kx9QmF{_^exlvlt%<$ZYT9Dj9h2G($%W_VEUnwgM+GnaJQGq6_g3HwhL;1uay1P`-8 zu(%jUCGeo)d4jFPJL)_|@a4|hJ1?!&*w1i4@v$Xsdmw*_HFtWS@uDHIt~`epBwswR zu-!}Ix^!Iwx6-2-X-~uV{vzrX;X!|!)$J=mXVJYP(DmYh1*sj6EbpvyeM}pUtQDQ5 zS<5^0Ks$&Q8h)T_U2W68FUmvjW*uApbdO^zo-wFyF)YwIJyF(T(4YE6MQ}lR&(pid zmOfFXGpJAwY%VEjDC;Z4V)-*Jub+xx);t z7q$D{=K>p`S(@LH5z%(=Gu;LLgggcxt9e;mhU%FLCaNc6Sh!}+`f&|pL_SJYRttt`T5P`b(R6&gzh*a zBU0D<-Jjd|Ua2y0Zgv#T)skWE_79aoG&-^BSpk3lW_~2l@fxk+0~h3D zn*GaQO&O^7{Qd=Lf=vwX4-?+UT7K@mtMD1P1wY7iP2MXQtLfgu+ZU9lpg&RGJ#&iJ zIFBuR3jI8FhqxWu*MLn^-ob^bJB}>tq?ug9MKKl4iZ>9Ws8nb)3>9aF zhz1nvb;MhU_(%-O!-zR(l!(kEN)&@4H8!}aV(E%oND1MI=5PKFo*qOyiy;cUwrL z$sjRvegv~_C2{E-(;zW#(P(Df)`O;1^CJd{o0F%&iOfWnx4jc1f1ffHvS&>kWMq5Q z01ee4EN@3AMjY8247tAv9Axy%*+d!Hx}DwV9}F=28C4k})#W_R^8V0?Qc2nqsuCu> zpP9h&$_Q^=5KCC@Iz1A2M+9^1YDc;ItO?H7hO5d*X>lBJyW3Gpjy0*uDCw1XVa&0Y z@XODJ5ta|Foea%I7FO`qC6wQNZ3>hwixK?x{9rg%E3<eWP6 zP;m*R{pl7}8E5!1KNId2t_98uS@A(P8aUqw|H{w8>(-^J5-nxV9m@)<&Y`qo_9Lni zBb6^Uv%(s}#mQ3%%kOQDg0tn1vf_8$C|4GYfj6zARplwEId2{-u63hSw>n-`VuQKk zb>N$~QJgh!e&@6a&fUinSoeErB49ckOML;VQWmJnG-+q*G^W;_K*^T)q^ekCcUBU# zTAybn$Bv-<{)%UzCOv_8126joZl5#)ccrq@f&O4g4Vez2AuX|_^^T}1;Kt~GFaPWieG!0U6_(ND6- zZI|jH>~>YjlU;T*oGvi4qZhJJ{&0gC+zz@C1%^iA&uo}Mo;Yi0Rm66lgO4}P1QJxG z*w9un0otm@L(`jK%-yyS4gdaVG+eG34_7LqRYf)Ghu#qd{8j{fwC*`}=5i7S)vrka z-Wx$zoCGRBnSoz>6!^RiK)L>J(Ku^R)KL}>0Wgw8F)3- zu7;X3jos)9p)8zf9-^9Rcg@(WJq3L?jc`0?I__CKiS_;!(MS`W5CR!E-TpmtQ%MYT zw}i6Zzac&UEulaJ34NXoSN|G%TTQqrA=>%<-+PQS>X;Kx$uPG+dF3`b6Vdi$<4<6V z6K}N}{eVioI~)5oGQ1B%^^0Mzf~&U0aC`r+kpHQ|Ijr|wD8I?zc0~#bo|8^?v|uE8 zUQf43w7tK@t+Qr2L%uv=q*2HH8W~2DXZ>6NTHlU_zf{HnKmL+4?5oP3(x_v>du+&l z2HBUc1pdbF$k8&aAGIAEF*BUwZWo5q2m%XU*GpG2ci%!Zwb_&5*7{7ivSkkN;vD>9 z?`rzfd5D}YcgFTDH_@G?-(C|4Ug*M3*wZ?4kcCnFKq@`rqkxyLKwh&1dHMn1?$4pY zmH|~cQRvzg4wnv0b*6k96GbBkEO?;{JDyfS<)w9{8L0a?kV=l%pt|}23NCI1wYQf* z_m25+-WiMEmeZ}e7~@R&J|>(-5Loa+7k1v$AQ!B)Z|Oaqe-xHv;?OZ205T=!{d`9m zLZlaQPBIykRN}Y*eJa3Jj0(Ifc=54m2E<8$E*(%OX^Dt+n$Zt~MQ7Gt6f^1`N6@zU z;Yh8;4@0yIez;njDB_YUB|119C z$F*V>cSk$ykB^C@gSG4a7!qXmHSp6``Qd0SawrA|wfYJMZ5j#lzV_uFvzH@FonG*P^7>VgCV%yXr;& From 6f51d447c75c7014a53afe8a54e1e63f93dedfbc Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 15:42:41 +0800 Subject: [PATCH 24/45] Get real config index --- v2rayN/v2rayN/Forms/MainForm.cs | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 1b5a03da..478a1f73 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -228,6 +228,7 @@ namespace v2rayN.Forms } } ListViewItem lvItem = new ListViewItem(def); + lvItem.Tag = k; _addSubItem(lvItem, EServerColName.type.ToString(), ((EConfigType)item.configType).ToString()); _addSubItem(lvItem, EServerColName.remarks.ToString(), item.remarks); _addSubItem(lvItem, EServerColName.address.ToString(), item.address); @@ -815,7 +816,10 @@ namespace v2rayN.Forms } /// - /// 取得ListView选中的行 + /// 获取服务器列表选中行的配置项(config)索引(index) + /// + /// 返回值对应首个选中项,出错时返回-1 + /// 多选选中请在调用此函数后检查 lvSelecteds /// /// private int GetLvSelectedIndex() @@ -830,9 +834,11 @@ namespace v2rayN.Forms return index; } - index = lvServers.SelectedIndices[0]; - foreach (int i in lvServers.SelectedIndices) + index = Convert.ToInt32(lvServers.SelectedItems[0].Tag); + + foreach (int item in lvServers.SelectedIndices) { + int i = Convert.ToInt32(lvServers.Items[item].Tag); lvSelecteds.Add(i); } return index; From 621565f4a42bf4a4e4829ab0733306d16fc3641d Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 16:10:00 +0800 Subject: [PATCH 25/45] restyle --- v2rayN/v2rayN/Forms/MainForm.cs | 45 +++++++++++++-------------------- 1 file changed, 18 insertions(+), 27 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 478a1f73..fab8644c 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -461,11 +461,8 @@ namespace v2rayN.Forms private void lvServers_DoubleClick(object sender, EventArgs e) { - int index = GetLvSelectedIndex(); - if (index < 0) - { - return; - } + int index = GetServerListSelectedConfigIndex(); + if (index < 0) return; if (config.vmess[index].configType == (int)EConfigType.Vmess) { @@ -594,11 +591,9 @@ namespace v2rayN.Forms private void menuRemoveServer_Click(object sender, EventArgs e) { - int index = GetLvSelectedIndex(); - if (index < 0) - { - return; - } + int index = GetServerListSelectedConfigIndex(); + if (index < 0) return; + if (UI.ShowYesNo(UIRes.I18N("RemoveServer")) == DialogResult.No) { return; @@ -630,11 +625,9 @@ namespace v2rayN.Forms private void menuCopyServer_Click(object sender, EventArgs e) { - int index = GetLvSelectedIndex(); - if (index < 0) - { - return; - } + int index = GetServerListSelectedConfigIndex(); + if (index < 0) return; + if (ConfigHandler.CopyServer(ref config, index) == 0) { //刷新 @@ -644,11 +637,9 @@ namespace v2rayN.Forms private void menuSetDefaultServer_Click(object sender, EventArgs e) { - int index = GetLvSelectedIndex(); - if (index < 0) - { - return; - } + int index = GetServerListSelectedConfigIndex(); + if (index < 0) return; + SetDefaultServer(index); } @@ -689,7 +680,7 @@ namespace v2rayN.Forms } private void Speedtest(string actionType) { - if (GetLvSelectedIndex() < 0) return; + if (GetServerListSelectedConfigIndex() < 0) return; ClearTestResult(); SpeedtestHandler statistics = new SpeedtestHandler(ref config, ref v2rayHandler, lvSelecteds, actionType, UpdateSpeedtestHandler); } @@ -707,19 +698,19 @@ namespace v2rayN.Forms private void menuExport2ClientConfig_Click(object sender, EventArgs e) { - int index = GetLvSelectedIndex(); + int index = GetServerListSelectedConfigIndex(); MainFormHandler.Instance.Export2ClientConfig(index, config); } private void menuExport2ServerConfig_Click(object sender, EventArgs e) { - int index = GetLvSelectedIndex(); + int index = GetServerListSelectedConfigIndex(); MainFormHandler.Instance.Export2ServerConfig(index, config); } private void menuExport2ShareUrl_Click(object sender, EventArgs e) { - GetLvSelectedIndex(); + GetServerListSelectedConfigIndex(); StringBuilder sb = new StringBuilder(); foreach (int v in lvSelecteds) @@ -742,7 +733,7 @@ namespace v2rayN.Forms private void menuExport2SubContent_Click(object sender, EventArgs e) { - GetLvSelectedIndex(); + GetServerListSelectedConfigIndex(); StringBuilder sb = new StringBuilder(); foreach (int v in lvSelecteds) @@ -822,7 +813,7 @@ namespace v2rayN.Forms /// 多选选中请在调用此函数后检查 lvSelecteds /// /// - private int GetLvSelectedIndex() + private int GetServerListSelectedConfigIndex() { int index = -1; lvSelecteds.Clear(); @@ -1166,7 +1157,7 @@ namespace v2rayN.Forms private void MoveServer(EMove eMove) { - int index = GetLvSelectedIndex(); + int index = GetServerListSelectedConfigIndex(); if (index < 0) { UI.Show(UIRes.I18N("PleaseSelectServer")); From 301d1dd99884e91b853c4c440a05760f5270fba3 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 16:16:19 +0800 Subject: [PATCH 26/45] fixes --- v2rayN/v2rayN/Forms/MainForm.cs | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index fab8644c..7ed2796b 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -18,7 +18,7 @@ namespace v2rayN.Forms public partial class MainForm : BaseForm { private V2rayHandler v2rayHandler; - private List lvSelecteds = new List(); + private List lvSelecteds = new List(); // 使用前需用 GetServerListSelectedConfigIndex 更新 private StatisticsHandler statistics = null; #region Window 事件 @@ -319,11 +319,10 @@ namespace v2rayN.Forms private void RefreshQRCodePanel() { if (scMain.Panel2Collapsed) return; // saving cpu. - if (lvServers.SelectedIndices.Count > 0) - { - int index = lvServers.SelectedIndices[0]; - qrCodeControl.showQRCode(index, config); - } + + int index = GetServerListSelectedConfigIndex(); + if (index < 0) return; + qrCodeControl.showQRCode(index, config); } private void RefreshTaryIcon() { @@ -590,7 +589,6 @@ namespace v2rayN.Forms private void menuRemoveServer_Click(object sender, EventArgs e) { - int index = GetServerListSelectedConfigIndex(); if (index < 0) return; From 0a8e822f354e64912c6c7ff03bdfafca35b589b9 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 16:23:16 +0800 Subject: [PATCH 27/45] simplify again & store Tag for sort --- v2rayN/v2rayN/Forms/MainForm.cs | 76 +++++++++++++++++---------------- 1 file changed, 39 insertions(+), 37 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 7ed2796b..c0d08b49 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -119,7 +119,9 @@ namespace v2rayN.Forms // break; // } //} + #endregion + #region 窗口大小和列宽等取/存 private void RestoreUI() { scMain.Panel2Collapsed = true; @@ -130,10 +132,10 @@ namespace v2rayN.Forms this.Height = config.uiItem.mainSize.Height; } - for (int k = 0; k < lvServers.Columns.Count; k++) + foreach (ColumnHeader c in lvServers.Columns) { - var width = ConfigHandler.GetformMainLvColWidth(ref config, ((EServerColName)k).ToString(), lvServers.Columns[k].Width); - lvServers.Columns[k].Width = width; + var width = ConfigHandler.GetformMainLvColWidth(ref config, c.Name, c.Width); + c.Width = width; } } @@ -141,9 +143,9 @@ namespace v2rayN.Forms { config.uiItem.mainSize = new Size(this.Width, this.Height); - for (int k = 0; k < lvServers.Columns.Count; k++) + foreach (ColumnHeader c in lvServers.Columns) { - ConfigHandler.AddformMainLvColWidth(ref config, ((EServerColName)k).ToString(), lvServers.Columns[k].Width); + ConfigHandler.AddformMainLvColWidth(ref config, c.Name, c.Width); } } @@ -169,22 +171,22 @@ namespace v2rayN.Forms lvServers.BeginUpdate(); lvServers.Items.Clear(); - lvServers.Columns.Add("", 30); - lvServers.Columns.Add(UIRes.I18N("LvServiceType"), 80); - lvServers.Columns.Add(UIRes.I18N("LvAlias"), 100); - lvServers.Columns.Add(UIRes.I18N("LvAddress"), 120); - lvServers.Columns.Add(UIRes.I18N("LvPort"), 50); - lvServers.Columns.Add(UIRes.I18N("LvEncryptionMethod"), 90); - lvServers.Columns.Add(UIRes.I18N("LvTransportProtocol"), 70); - lvServers.Columns.Add(UIRes.I18N("LvSubscription"), 50); - lvServers.Columns.Add(UIRes.I18N("LvTestResults"), 70); + lvServers.Columns.Add(EServerColName.def.ToString(), "", 30); + lvServers.Columns.Add(EServerColName.type.ToString(), UIRes.I18N("LvServiceType"), 80); + lvServers.Columns.Add(EServerColName.remarks.ToString(), UIRes.I18N("LvAlias"), 100); + lvServers.Columns.Add(EServerColName.address.ToString(), UIRes.I18N("LvAddress"), 120); + lvServers.Columns.Add(EServerColName.port.ToString(), UIRes.I18N("LvPort"), 50); + lvServers.Columns.Add(EServerColName.security.ToString(), UIRes.I18N("LvEncryptionMethod"), 90); + lvServers.Columns.Add(EServerColName.network.ToString(), UIRes.I18N("LvTransportProtocol"), 70); + lvServers.Columns.Add(EServerColName.subRemarks.ToString(), UIRes.I18N("LvSubscription"), 50); + lvServers.Columns.Add(EServerColName.testResult.ToString(), UIRes.I18N("LvTestResults"), 70); if (statistics != null && statistics.Enable) { - lvServers.Columns.Add(UIRes.I18N("LvTodayDownloadDataAmount"), 70); - lvServers.Columns.Add(UIRes.I18N("LvTodayUploadDataAmount"), 70); - lvServers.Columns.Add(UIRes.I18N("LvTotalDownloadDataAmount"), 70); - lvServers.Columns.Add(UIRes.I18N("LvTotalUploadDataAmount"), 70); + lvServers.Columns.Add(EServerColName.todayDown.ToString(), UIRes.I18N("LvTodayDownloadDataAmount"), 70); + lvServers.Columns.Add(EServerColName.todayUp.ToString(), UIRes.I18N("LvTodayUploadDataAmount"), 70); + lvServers.Columns.Add(EServerColName.totalDown.ToString(), UIRes.I18N("LvTotalDownloadDataAmount"), 70); + lvServers.Columns.Add(EServerColName.totalUp.ToString(), UIRes.I18N("LvTotalUploadDataAmount"), 70); } lvServers.EndUpdate(); } @@ -211,10 +213,23 @@ namespace v2rayN.Forms VmessItem item = config.vmess[k]; - void _addSubItem(ListViewItem i, string name, string text) + void _addSubItem(ListViewItem i, string name, string text, object tag = null) { - i.SubItems.Add(new ListViewItem.ListViewSubItem() { Name = name, Text = text }); + var n = new ListViewItem.ListViewSubItem() { Text = text }; + n.Name = name; // new don't accept it. + n.Tag = tag; + i.SubItems.Add(n); } + ListViewItem lvItem = new ListViewItem(def); + lvItem.Tag = k; // the Tag of items is config's index. + _addSubItem(lvItem, EServerColName.type.ToString(), ((EConfigType)item.configType).ToString()); + _addSubItem(lvItem, EServerColName.remarks.ToString(), item.remarks); + _addSubItem(lvItem, EServerColName.address.ToString(), item.address); + _addSubItem(lvItem, EServerColName.port.ToString(), item.port.ToString()); + _addSubItem(lvItem, EServerColName.security.ToString(), item.security); + _addSubItem(lvItem, EServerColName.network.ToString(), item.network); + _addSubItem(lvItem, EServerColName.subRemarks.ToString(), item.getSubRemarks(config)); + _addSubItem(lvItem, EServerColName.testResult.ToString(), item.testResult); bool stats = statistics != null && statistics.Enable; if (stats) { @@ -226,23 +241,10 @@ namespace v2rayN.Forms todayUp = Utils.HumanFy(sItem.todayUp); todayDown = Utils.HumanFy(sItem.todayDown); } - } - ListViewItem lvItem = new ListViewItem(def); - lvItem.Tag = k; - _addSubItem(lvItem, EServerColName.type.ToString(), ((EConfigType)item.configType).ToString()); - _addSubItem(lvItem, EServerColName.remarks.ToString(), item.remarks); - _addSubItem(lvItem, EServerColName.address.ToString(), item.address); - _addSubItem(lvItem, EServerColName.port.ToString(), item.port.ToString()); - _addSubItem(lvItem, EServerColName.security.ToString(), item.security); - _addSubItem(lvItem, EServerColName.network.ToString(), item.network); - _addSubItem(lvItem, EServerColName.subRemarks.ToString(), item.getSubRemarks(config)); - _addSubItem(lvItem, EServerColName.testResult.ToString(), item.testResult); - if (stats) - { - _addSubItem(lvItem, EServerColName.todayDown.ToString(), todayDown); - _addSubItem(lvItem, EServerColName.todayUp.ToString(), todayUp); - _addSubItem(lvItem, EServerColName.totalDown.ToString(), totalDown); - _addSubItem(lvItem, EServerColName.totalUp.ToString(), totalUp); + _addSubItem(lvItem, EServerColName.todayDown.ToString(), todayDown, sItem.todayDown); + _addSubItem(lvItem, EServerColName.todayUp.ToString(), todayUp, sItem.todayUp); + _addSubItem(lvItem, EServerColName.totalDown.ToString(), totalDown, sItem.totalDown); + _addSubItem(lvItem, EServerColName.totalUp.ToString(), totalUp, sItem.totalUp); } if (config.interlaceColoring && k % 2 == 1) // 隔行着色 From 414ac3225aae5d0cf7edc9b8f222ec5b585fe1c4 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 17:28:55 +0800 Subject: [PATCH 28/45] Merge branch 'billpareto_sort' into itemIndex --- v2rayN/v2rayN/Base/ListViewSort.cs | 31 ++++++++++++++++++++++++++++++ v2rayN/v2rayN/Forms/MainForm.cs | 16 +++++++++++++++ v2rayN/v2rayN/v2rayN.csproj | 1 + 3 files changed, 48 insertions(+) create mode 100644 v2rayN/v2rayN/Base/ListViewSort.cs diff --git a/v2rayN/v2rayN/Base/ListViewSort.cs b/v2rayN/v2rayN/Base/ListViewSort.cs new file mode 100644 index 00000000..fded9bed --- /dev/null +++ b/v2rayN/v2rayN/Base/ListViewSort.cs @@ -0,0 +1,31 @@ +using System; +using System.Collections; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace v2rayN.Base +{ + public class ListViewSort : IComparer + { + private int col; + private bool descK; + public ListViewSort() + { + col = 0; + } + public ListViewSort(int column, object Desc) + { + descK = (bool)Desc; + col = column; //当前列,0,1,2...,参数由ListView控件的ColumnClick事件传递 + } + public int Compare(object x, object y) + { + int tempInt = String.Compare(((ListViewItem)x).SubItems[col].Text, ((ListViewItem)y).SubItems[col].Text); + if (descK) return -tempInt; + else return tempInt; + } + } +} diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index c0d08b49..ef48980e 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -182,6 +182,9 @@ namespace v2rayN.Forms lvServers.Columns.Add(EServerColName.testResult.ToString(), UIRes.I18N("LvTestResults"), 70); if (statistics != null && statistics.Enable) + lvServers.HeaderStyle = ColumnHeaderStyle.Clickable; + this.lvServers.AllowColumnReorder = true; + { lvServers.Columns.Add(EServerColName.todayDown.ToString(), UIRes.I18N("LvTodayDownloadDataAmount"), 70); lvServers.Columns.Add(EServerColName.todayUp.ToString(), UIRes.I18N("LvTodayUploadDataAmount"), 70); @@ -1627,5 +1630,18 @@ namespace v2rayN.Forms { tsbOptionSetting_Click(toolSslRouting, null); } + + private void lvServers_ColumnClick(object sender, ColumnClickEventArgs e) + { + if (lvServers.Columns[e.Column].Tag == null) + lvServers.Columns[e.Column].Tag = true; + bool flag = (bool)lvServers.Columns[e.Column].Tag; + if (flag) + lvServers.Columns[e.Column].Tag = false; + else + lvServers.Columns[e.Column].Tag = true; + lvServers.ListViewItemSorter = new ListViewSort(e.Column, lvServers.Columns[e.Column].Tag); + lvServers.Sort();//对列表进行自定义排序 + } } } diff --git a/v2rayN/v2rayN/v2rayN.csproj b/v2rayN/v2rayN/v2rayN.csproj index 65075779..c0ebf9e1 100644 --- a/v2rayN/v2rayN/v2rayN.csproj +++ b/v2rayN/v2rayN/v2rayN.csproj @@ -97,6 +97,7 @@ + Form From 05efff10da3d436174d512d842cad4cbd57bd00e Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 17:31:18 +0800 Subject: [PATCH 29/45] sort now works --- v2rayN/v2rayN/Base/ListViewSort.cs | 65 +++++++++++++++--------- v2rayN/v2rayN/Forms/MainForm.Designer.cs | 3 +- v2rayN/v2rayN/Forms/MainForm.cs | 57 ++++++++++++++------- v2rayN/v2rayN/Global.cs | 10 ++++ 4 files changed, 93 insertions(+), 42 deletions(-) diff --git a/v2rayN/v2rayN/Base/ListViewSort.cs b/v2rayN/v2rayN/Base/ListViewSort.cs index fded9bed..004985f5 100644 --- a/v2rayN/v2rayN/Base/ListViewSort.cs +++ b/v2rayN/v2rayN/Base/ListViewSort.cs @@ -1,31 +1,50 @@ -using System; -using System.Collections; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using System.Windows.Forms; +using System.Windows.Forms; namespace v2rayN.Base { - public class ListViewSort : IComparer + + // ref: https://stackoverflow.com/questions/1214289/how-do-i-sort-integers-in-a-listview + class Sorter : System.Collections.IComparer { - private int col; - private bool descK; - public ListViewSort() + public int Column = 0; + public int Sorting = 0; + public int Compare(object x, object y) // IComparer Member { - col = 0; - } - public ListViewSort(int column, object Desc) - { - descK = (bool)Desc; - col = column; //当前列,0,1,2...,参数由ListView控件的ColumnClick事件传递 - } - public int Compare(object x, object y) - { - int tempInt = String.Compare(((ListViewItem)x).SubItems[col].Text, ((ListViewItem)y).SubItems[col].Text); - if (descK) return -tempInt; - else return tempInt; + if (!(x is ListViewItem) || !(y is ListViewItem)) + return (0); + + ListViewItem l1 = (ListViewItem)x; + ListViewItem l2 = (ListViewItem)y; + + int doIntSort = Sorting; + if (doIntSort > 0) // Tag will be number + { + ulong.TryParse(l1.SubItems[Column].Tag?.ToString(), out ulong fl1); + ulong.TryParse(l2.SubItems[Column].Tag?.ToString(), out ulong fl2); + + if (doIntSort == 1) + { + return fl1.CompareTo(fl2); + } + else + { + return fl2.CompareTo(fl1); + } + } + else + { + string str1 = l1.SubItems[Column].Text; + string str2 = l2.SubItems[Column].Text; + + if (doIntSort == -1) + { + return str1.CompareTo(str2); + } + else + { + return str2.CompareTo(str1); + } + } } } } diff --git a/v2rayN/v2rayN/Forms/MainForm.Designer.cs b/v2rayN/v2rayN/Forms/MainForm.Designer.cs index 86899312..0fae5057 100644 --- a/v2rayN/v2rayN/Forms/MainForm.Designer.cs +++ b/v2rayN/v2rayN/Forms/MainForm.Designer.cs @@ -155,17 +155,18 @@ // // lvServers // + this.lvServers.AllowColumnReorder = true; this.lvServers.ContextMenuStrip = this.cmsLv; resources.ApplyResources(this.lvServers, "lvServers"); this.lvServers.FullRowSelect = true; this.lvServers.GridLines = true; - this.lvServers.HeaderStyle = System.Windows.Forms.ColumnHeaderStyle.Nonclickable; this.lvServers.HideSelection = false; this.lvServers.Items.AddRange(new System.Windows.Forms.ListViewItem[] { ((System.Windows.Forms.ListViewItem)(resources.GetObject("lvServers.Items")))}); this.lvServers.Name = "lvServers"; this.lvServers.UseCompatibleStateImageBehavior = false; this.lvServers.View = System.Windows.Forms.View.Details; + this.lvServers.ColumnClick += new System.Windows.Forms.ColumnClickEventHandler(this.lvServers_ColumnClick); this.lvServers.SelectedIndexChanged += new System.EventHandler(this.lvServers_SelectedIndexChanged); this.lvServers.DoubleClick += new System.EventHandler(this.lvServers_DoubleClick); this.lvServers.KeyDown += new System.Windows.Forms.KeyEventHandler(this.lvServers_KeyDown); diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index ef48980e..9980d6b6 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -168,6 +168,8 @@ namespace v2rayN.Forms /// private void InitServersView() { + lvServers.ListViewItemSorter = new Sorter(); + lvServers.BeginUpdate(); lvServers.Items.Clear(); @@ -181,15 +183,18 @@ namespace v2rayN.Forms lvServers.Columns.Add(EServerColName.subRemarks.ToString(), UIRes.I18N("LvSubscription"), 50); lvServers.Columns.Add(EServerColName.testResult.ToString(), UIRes.I18N("LvTestResults"), 70); + lvServers.Columns[EServerColName.port.ToString()].Tag = Global.sortMode.Numeric.ToString(); if (statistics != null && statistics.Enable) - lvServers.HeaderStyle = ColumnHeaderStyle.Clickable; - this.lvServers.AllowColumnReorder = true; - { lvServers.Columns.Add(EServerColName.todayDown.ToString(), UIRes.I18N("LvTodayDownloadDataAmount"), 70); lvServers.Columns.Add(EServerColName.todayUp.ToString(), UIRes.I18N("LvTodayUploadDataAmount"), 70); lvServers.Columns.Add(EServerColName.totalDown.ToString(), UIRes.I18N("LvTotalDownloadDataAmount"), 70); lvServers.Columns.Add(EServerColName.totalUp.ToString(), UIRes.I18N("LvTotalUploadDataAmount"), 70); + + lvServers.Columns[EServerColName.todayDown.ToString()].Tag = Global.sortMode.Numeric.ToString(); + lvServers.Columns[EServerColName.todayUp.ToString()].Tag = Global.sortMode.Numeric.ToString(); + lvServers.Columns[EServerColName.totalDown.ToString()].Tag = Global.sortMode.Numeric.ToString(); + lvServers.Columns[EServerColName.totalUp.ToString()].Tag = Global.sortMode.Numeric.ToString(); } lvServers.EndUpdate(); } @@ -220,11 +225,11 @@ namespace v2rayN.Forms { var n = new ListViewItem.ListViewSubItem() { Text = text }; n.Name = name; // new don't accept it. - n.Tag = tag; + n.Tag = tag; // cell's data store. i.SubItems.Add(n); } ListViewItem lvItem = new ListViewItem(def); - lvItem.Tag = k; // the Tag of items is config's index. + lvItem.Tag = k; // the Tag of line is config's index. _addSubItem(lvItem, EServerColName.type.ToString(), ((EConfigType)item.configType).ToString()); _addSubItem(lvItem, EServerColName.remarks.ToString(), item.remarks); _addSubItem(lvItem, EServerColName.address.ToString(), item.address); @@ -244,10 +249,10 @@ namespace v2rayN.Forms todayUp = Utils.HumanFy(sItem.todayUp); todayDown = Utils.HumanFy(sItem.todayDown); } - _addSubItem(lvItem, EServerColName.todayDown.ToString(), todayDown, sItem.todayDown); - _addSubItem(lvItem, EServerColName.todayUp.ToString(), todayUp, sItem.todayUp); - _addSubItem(lvItem, EServerColName.totalDown.ToString(), totalDown, sItem.totalDown); - _addSubItem(lvItem, EServerColName.totalUp.ToString(), totalUp, sItem.totalUp); + _addSubItem(lvItem, EServerColName.todayDown.ToString(), todayDown, sItem?.todayDown); + _addSubItem(lvItem, EServerColName.todayUp.ToString(), todayUp, sItem?.todayUp); + _addSubItem(lvItem, EServerColName.totalDown.ToString(), totalDown, sItem?.totalDown); + _addSubItem(lvItem, EServerColName.totalUp.ToString(), totalUp, sItem?.totalUp); } if (config.interlaceColoring && k % 2 == 1) // 隔行着色 @@ -1633,15 +1638,31 @@ namespace v2rayN.Forms private void lvServers_ColumnClick(object sender, ColumnClickEventArgs e) { - if (lvServers.Columns[e.Column].Tag == null) - lvServers.Columns[e.Column].Tag = true; - bool flag = (bool)lvServers.Columns[e.Column].Tag; - if (flag) - lvServers.Columns[e.Column].Tag = false; - else - lvServers.Columns[e.Column].Tag = true; - lvServers.ListViewItemSorter = new ListViewSort(e.Column, lvServers.Columns[e.Column].Tag); - lvServers.Sort();//对列表进行自定义排序 + Sorter s = (Sorter)lvServers.ListViewItemSorter; + s.Column = e.Column; + + int doIntSort; + if (lvServers.Columns[e.Column].Tag?.ToString() == Global.sortMode.Numeric.ToString()) // 数字正序 + { + lvServers.Columns[e.Column].Tag = Global.sortMode.NumericB.ToString(); + doIntSort = 1; + } + else if (lvServers.Columns[e.Column].Tag?.ToString() == Global.sortMode.NumericB.ToString()) // 数字倒序 + { + lvServers.Columns[e.Column].Tag = Global.sortMode.Numeric.ToString(); + doIntSort = 2; + } + else // 非数字 + { + bool bGo = bool.TryParse(lvServers.Columns[e.Column].Tag?.ToString(), out bool bOk); + // 首个转换将失败,如果Tag是null或其他。 + bool flag = bOk ? bGo : false; + lvServers.Columns[e.Column].Tag = !flag; // 首次则赋值true。 + doIntSort = flag ? -1 : -2; // -1正序 -2倒序 + } + s.Sorting = doIntSort; + + lvServers.Sort(); } } } diff --git a/v2rayN/v2rayN/Global.cs b/v2rayN/v2rayN/Global.cs index 3d1e6137..5fc9a175 100644 --- a/v2rayN/v2rayN/Global.cs +++ b/v2rayN/v2rayN/Global.cs @@ -156,6 +156,16 @@ namespace v2rayN /// public const string CustomIconName = "v2rayN.ico"; + /// + /// 表格列的排序方式 + /// + public enum sortMode + { + Numeric, + NumericB, + // More, like natural numbers, string length, visual length, etc. + } + public enum StatisticsFreshRate { quick = 1000, From 57bcf8a1a73e036abfadf3e907dce3a96ec89930 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 20:08:33 +0800 Subject: [PATCH 30/45] reInterlaceColoring --- v2rayN/v2rayN/Forms/MainForm.cs | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 9980d6b6..5921e6f2 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -1663,6 +1663,18 @@ namespace v2rayN.Forms s.Sorting = doIntSort; lvServers.Sort(); + reInterlaceColoring(); + } + private void reInterlaceColoring() + { + if (!config.interlaceColoring) return; + for (int k = 0; k < lvServers.Items.Count; k++) + { + if (config.interlaceColoring && k % 2 == 1) + lvServers.Items[k].BackColor = SystemColors.Control; + else + lvServers.Items[k].BackColor = lvServers.BackColor; + } } } } From 8cf66da07cd798819d17653df802cb0dabef75c4 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 20:16:58 +0800 Subject: [PATCH 31/45] refine StorageUI --- v2rayN/v2rayN/Forms/MainForm.Designer.cs | 2 ++ v2rayN/v2rayN/Forms/MainForm.cs | 13 ++++++++++++- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.Designer.cs b/v2rayN/v2rayN/Forms/MainForm.Designer.cs index 0fae5057..72592c43 100644 --- a/v2rayN/v2rayN/Forms/MainForm.Designer.cs +++ b/v2rayN/v2rayN/Forms/MainForm.Designer.cs @@ -167,6 +167,7 @@ this.lvServers.UseCompatibleStateImageBehavior = false; this.lvServers.View = System.Windows.Forms.View.Details; this.lvServers.ColumnClick += new System.Windows.Forms.ColumnClickEventHandler(this.lvServers_ColumnClick); + this.lvServers.ColumnWidthChanged += new System.Windows.Forms.ColumnWidthChangedEventHandler(this.lvServers_ColumnWidthChanged); this.lvServers.SelectedIndexChanged += new System.EventHandler(this.lvServers_SelectedIndexChanged); this.lvServers.DoubleClick += new System.EventHandler(this.lvServers_DoubleClick); this.lvServers.KeyDown += new System.Windows.Forms.KeyEventHandler(this.lvServers_KeyDown); @@ -880,6 +881,7 @@ this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.MainForm_FormClosing); this.Load += new System.EventHandler(this.MainForm_Load); this.Shown += new System.EventHandler(this.MainForm_Shown); + this.ResizeEnd += new System.EventHandler(this.MainForm_ResizeEnd); this.VisibleChanged += new System.EventHandler(this.MainForm_VisibleChanged); this.Resize += new System.EventHandler(this.MainForm_Resize); this.scMain.Panel1.ResumeLayout(false); diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 5921e6f2..d6331f58 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -81,7 +81,6 @@ namespace v2rayN.Forms { if (e.CloseReason == CloseReason.UserClosing) { - StorageUI(); e.Cancel = true; HideForm(); return; @@ -139,6 +138,7 @@ namespace v2rayN.Forms } } + // Deprecated. private void StorageUI() { config.uiItem.mainSize = new Size(this.Width, this.Height); @@ -1676,5 +1676,16 @@ namespace v2rayN.Forms lvServers.Items[k].BackColor = lvServers.BackColor; } } + + private void lvServers_ColumnWidthChanged(object sender, ColumnWidthChangedEventArgs e) + { + ColumnHeader c = lvServers.Columns[e.ColumnIndex]; + ConfigHandler.AddformMainLvColWidth(ref config, c.Name, c.Width); + } + + private void MainForm_ResizeEnd(object sender, EventArgs e) + { + config.uiItem.mainSize = new Size(this.Width, this.Height); + } } } From 46c887537e891c925de9d0739a7eac8f6f55adcc Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 20:43:25 +0800 Subject: [PATCH 32/45] remember columns order --- v2rayN/v2rayN/Forms/MainForm.Designer.cs | 1 + v2rayN/v2rayN/Forms/MainForm.cs | 20 ++++++++++++++++++++ v2rayN/v2rayN/Forms/MainForm.resx | 6 +++--- v2rayN/v2rayN/Mode/Config.cs | 3 +-- 4 files changed, 25 insertions(+), 5 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.Designer.cs b/v2rayN/v2rayN/Forms/MainForm.Designer.cs index 72592c43..aff2d35f 100644 --- a/v2rayN/v2rayN/Forms/MainForm.Designer.cs +++ b/v2rayN/v2rayN/Forms/MainForm.Designer.cs @@ -167,6 +167,7 @@ this.lvServers.UseCompatibleStateImageBehavior = false; this.lvServers.View = System.Windows.Forms.View.Details; this.lvServers.ColumnClick += new System.Windows.Forms.ColumnClickEventHandler(this.lvServers_ColumnClick); + this.lvServers.ColumnReordered += new System.Windows.Forms.ColumnReorderedEventHandler(this.lvServers_ColumnReordered); this.lvServers.ColumnWidthChanged += new System.Windows.Forms.ColumnWidthChangedEventHandler(this.lvServers_ColumnWidthChanged); this.lvServers.SelectedIndexChanged += new System.EventHandler(this.lvServers_SelectedIndexChanged); this.lvServers.DoubleClick += new System.EventHandler(this.lvServers_DoubleClick); diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index d6331f58..e8344603 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -12,6 +12,7 @@ using System.Diagnostics; using System.Drawing; using System.Net; using System.Threading.Tasks; +using System.Linq; namespace v2rayN.Forms { @@ -196,6 +197,13 @@ namespace v2rayN.Forms lvServers.Columns[EServerColName.totalDown.ToString()].Tag = Global.sortMode.Numeric.ToString(); lvServers.Columns[EServerColName.totalUp.ToString()].Tag = Global.sortMode.Numeric.ToString(); } + + foreach (ColumnHeader c in lvServers.Columns) + { + if (config.uiItem.mainLvColLayout == null) break; + int i = config.uiItem.mainLvColLayout.IndexOf(c.Name); + if (i >= 0) c.DisplayIndex = i; + } lvServers.EndUpdate(); } @@ -1681,11 +1689,23 @@ namespace v2rayN.Forms { ColumnHeader c = lvServers.Columns[e.ColumnIndex]; ConfigHandler.AddformMainLvColWidth(ref config, c.Name, c.Width); + Task.Run(() => ConfigHandler.SaveConfig(ref config)); } private void MainForm_ResizeEnd(object sender, EventArgs e) { config.uiItem.mainSize = new Size(this.Width, this.Height); + Task.Run(() => ConfigHandler.SaveConfig(ref config)); + } + + private async void lvServers_ColumnReordered(object sender, ColumnReorderedEventArgs e) + { + await Task.Delay(500); + var names = (from col in lvServers.Columns.Cast() + orderby col.DisplayIndex + select col.Name).ToList(); + config.uiItem.mainLvColLayout = names; + _ = Task.Run(() => ConfigHandler.SaveConfig(ref config)); } } } diff --git a/v2rayN/v2rayN/Forms/MainForm.resx b/v2rayN/v2rayN/Forms/MainForm.resx index 43d513f5..2fa0a97a 100644 --- a/v2rayN/v2rayN/Forms/MainForm.resx +++ b/v2rayN/v2rayN/Forms/MainForm.resx @@ -882,7 +882,7 @@ toolSslBlank1 - 160, 21 + 170, 21 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -891,7 +891,7 @@ toolSslBlank2 - 160, 21 + 170, 21 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -900,7 +900,7 @@ toolSslBlank3 - 160, 21 + 170, 21 System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 diff --git a/v2rayN/v2rayN/Mode/Config.cs b/v2rayN/v2rayN/Mode/Config.cs index 65f74893..d473462f 100644 --- a/v2rayN/v2rayN/Mode/Config.cs +++ b/v2rayN/v2rayN/Mode/Config.cs @@ -544,9 +544,8 @@ namespace v2rayN.Mode [Serializable] public class UIItem { - - public System.Drawing.Size mainSize { get; set; } public Dictionary mainLvColWidth { get; set; } + public List mainLvColLayout { get; set; } } } From 219f544a43503ea422ec3873ce161524efc7de53 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 20:55:25 +0800 Subject: [PATCH 33/45] refine code --- v2rayN/v2rayN/Forms/MainForm.cs | 12 ++++---- v2rayN/v2rayN/Forms/OptionSettingForm.cs | 2 +- v2rayN/v2rayN/Handler/ConfigHandler.cs | 36 ++++++++++-------------- 3 files changed, 22 insertions(+), 28 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index e8344603..abcda592 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -441,7 +441,7 @@ namespace v2rayN.Forms await v2rayHandler.LoadV2ray(config); Global.reloadV2ray = false; ChangePACButtonStatus(config.listenerType); - //ConfigHandler.SaveConfig(ref config, false); // ChangePACButtonStatus does it. + //ConfigHandler.SaveConfigToFile(ref config, false); // ChangePACButtonStatus does it. statistics?.SaveToFile(); this.Invoke((MethodInvoker)(delegate @@ -459,7 +459,7 @@ namespace v2rayN.Forms { List tasks = new List { - Task.Run(() => ConfigHandler.SaveConfig(ref config)), + Task.Run(() => ConfigHandler.SaveConfigToFile(ref config)), Task.Run(() => HttpProxyHandle.CloseHttpAgent(config)), Task.Run(() => v2rayHandler.V2rayStop()), Task.Run(() => PACServerHandle.Stop()), @@ -1255,7 +1255,7 @@ namespace v2rayN.Forms } Global.reloadV2ray = false; - ConfigHandler.SaveConfig(ref config); + ConfigHandler.SaveConfigToFile(ref config); this.Invoke((MethodInvoker)(delegate { @@ -1689,13 +1689,13 @@ namespace v2rayN.Forms { ColumnHeader c = lvServers.Columns[e.ColumnIndex]; ConfigHandler.AddformMainLvColWidth(ref config, c.Name, c.Width); - Task.Run(() => ConfigHandler.SaveConfig(ref config)); + Task.Run(() => ConfigHandler.SaveConfigToFile(ref config)); } private void MainForm_ResizeEnd(object sender, EventArgs e) { config.uiItem.mainSize = new Size(this.Width, this.Height); - Task.Run(() => ConfigHandler.SaveConfig(ref config)); + Task.Run(() => ConfigHandler.SaveConfigToFile(ref config)); } private async void lvServers_ColumnReordered(object sender, ColumnReorderedEventArgs e) @@ -1705,7 +1705,7 @@ namespace v2rayN.Forms orderby col.DisplayIndex select col.Name).ToList(); config.uiItem.mainLvColLayout = names; - _ = Task.Run(() => ConfigHandler.SaveConfig(ref config)); + _ = Task.Run(() => ConfigHandler.SaveConfigToFile(ref config)); } } } diff --git a/v2rayN/v2rayN/Forms/OptionSettingForm.cs b/v2rayN/v2rayN/Forms/OptionSettingForm.cs index 4d16a860..6ef6a395 100644 --- a/v2rayN/v2rayN/Forms/OptionSettingForm.cs +++ b/v2rayN/v2rayN/Forms/OptionSettingForm.cs @@ -187,7 +187,7 @@ namespace v2rayN.Forms return; } - if (ConfigHandler.SaveConfig(ref config) == 0) + if (ConfigHandler.SaveConfigToFile(ref config) == 0) { this.DialogResult = DialogResult.OK; } diff --git a/v2rayN/v2rayN/Handler/ConfigHandler.cs b/v2rayN/v2rayN/Handler/ConfigHandler.cs index ec9b4d92..dba4aad4 100644 --- a/v2rayN/v2rayN/Handler/ConfigHandler.cs +++ b/v2rayN/v2rayN/Handler/ConfigHandler.cs @@ -223,7 +223,7 @@ namespace v2rayN.Handler } } - ToJsonFile(config); + SaveConfigToFile(config); return 0; } @@ -264,7 +264,7 @@ namespace v2rayN.Handler Global.reloadV2ray = true; } - ToJsonFile(config); + SaveConfigToFile(config); return 0; } @@ -302,7 +302,7 @@ namespace v2rayN.Handler config.vmess.Insert(index + 1, vmessItem); // 插入到下一项 - ToJsonFile(config); + SaveConfigToFile(config); return 0; } @@ -328,26 +328,20 @@ namespace v2rayN.Handler config.index = index; Global.reloadV2ray = true; - ToJsonFile(config); + SaveConfigToFile(config); return 0; } /// - /// 保存参数 + /// 保存设置文件 /// /// - /// - public static int SaveConfig(ref Config config) + public static int SaveConfigToFile(ref Config config) { - return ToJsonFile(config); + return Utils.ToJsonFile(config, Utils.GetPath(configRes)); } - - /// - /// 存储文件 - /// - /// - private static int ToJsonFile(Config config) + public static int SaveConfigToFile(Config config) { return Utils.ToJsonFile(config, Utils.GetPath(configRes)); } @@ -533,7 +527,7 @@ namespace v2rayN.Handler } Global.reloadV2ray = true; - ToJsonFile(config); + SaveConfigToFile(config); return 0; } @@ -572,7 +566,7 @@ namespace v2rayN.Handler Global.reloadV2ray = true; } - ToJsonFile(config); + SaveConfigToFile(config); return 0; } @@ -593,7 +587,7 @@ namespace v2rayN.Handler Global.reloadV2ray = true; } - ToJsonFile(config); + SaveConfigToFile(config); return 0; } @@ -634,7 +628,7 @@ namespace v2rayN.Handler } } - ToJsonFile(config); + SaveConfigToFile(config); return 0; } @@ -673,7 +667,7 @@ namespace v2rayN.Handler } } - ToJsonFile(config); + SaveConfigToFile(config); return 0; } @@ -854,7 +848,7 @@ namespace v2rayN.Handler } } - ToJsonFile(config); + SaveConfigToFile(config); return 0; } @@ -878,7 +872,7 @@ namespace v2rayN.Handler } } - ToJsonFile(config); + SaveConfigToFile(config); return 0; } From 8a87318b68ebed631064e75e63b1eeb7dbfae6ff Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 22:42:32 +0800 Subject: [PATCH 34/45] fixes SetTestResult --- v2rayN/v2rayN/Forms/MainForm.cs | 30 ++++++++++++++++++++++++++---- 1 file changed, 26 insertions(+), 4 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index abcda592..bcf4e564 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -855,6 +855,27 @@ namespace v2rayN.Forms return index; } } + /// + /// 获取服务器列表表示指定配置项的所有行的索引 + /// 基于列表项的Tag属性 + /// + /// 出错时返回空。 + /// + /// + private List GetServerListItemsByConfigIndex(int configIndex) + { + var l = new List(); + foreach (ListViewItem item in lvServers.Items) + { + string tagStr = item.Tag?.ToString(); + if (int.TryParse(tagStr, out int tagInt) + && tagInt == configIndex) + { + l.Add(item.Index); + } + } + return l; + } private void menuAddCustomServer_Click(object sender, EventArgs e) { @@ -1087,12 +1108,13 @@ namespace v2rayN.Forms #region 后台测速 - private void SetTestResult(int k, string txt) + private void SetTestResult(int configIndex, string txt) { - if (k < lvServers.Items.Count) + var l = GetServerListItemsByConfigIndex(configIndex); + if (l.Count > 0) { - config.vmess[k].testResult = txt; - lvServers.Items[k].SubItems["testResult"].Text = txt; + config.vmess[configIndex].testResult = txt; + l.ForEach((listIndex) => lvServers.Items[listIndex].SubItems["testResult"].Text = txt); } } private void ClearTestResult() From cb24a909ae8e5c5d9e30075bc8427cb03d6e388a Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sat, 18 Apr 2020 22:51:16 +0800 Subject: [PATCH 35/45] function rename --- v2rayN/v2rayN/Forms/MainForm.cs | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index bcf4e564..62bb3ee7 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -338,7 +338,7 @@ namespace v2rayN.Forms { if (scMain.Panel2Collapsed) return; // saving cpu. - int index = GetServerListSelectedConfigIndex(); + int index = GetConfigIndexFromServerListSelected(); if (index < 0) return; qrCodeControl.showQRCode(index, config); } @@ -478,7 +478,7 @@ namespace v2rayN.Forms private void lvServers_DoubleClick(object sender, EventArgs e) { - int index = GetServerListSelectedConfigIndex(); + int index = GetConfigIndexFromServerListSelected(); if (index < 0) return; if (config.vmess[index].configType == (int)EConfigType.Vmess) @@ -607,7 +607,7 @@ namespace v2rayN.Forms private void menuRemoveServer_Click(object sender, EventArgs e) { - int index = GetServerListSelectedConfigIndex(); + int index = GetConfigIndexFromServerListSelected(); if (index < 0) return; if (UI.ShowYesNo(UIRes.I18N("RemoveServer")) == DialogResult.No) @@ -641,7 +641,7 @@ namespace v2rayN.Forms private void menuCopyServer_Click(object sender, EventArgs e) { - int index = GetServerListSelectedConfigIndex(); + int index = GetConfigIndexFromServerListSelected(); if (index < 0) return; if (ConfigHandler.CopyServer(ref config, index) == 0) @@ -653,7 +653,7 @@ namespace v2rayN.Forms private void menuSetDefaultServer_Click(object sender, EventArgs e) { - int index = GetServerListSelectedConfigIndex(); + int index = GetConfigIndexFromServerListSelected(); if (index < 0) return; SetDefaultServer(index); @@ -696,7 +696,7 @@ namespace v2rayN.Forms } private void Speedtest(string actionType) { - if (GetServerListSelectedConfigIndex() < 0) return; + if (GetConfigIndexFromServerListSelected() < 0) return; ClearTestResult(); SpeedtestHandler statistics = new SpeedtestHandler(ref config, ref v2rayHandler, lvSelecteds, actionType, UpdateSpeedtestHandler); } @@ -714,19 +714,19 @@ namespace v2rayN.Forms private void menuExport2ClientConfig_Click(object sender, EventArgs e) { - int index = GetServerListSelectedConfigIndex(); + int index = GetConfigIndexFromServerListSelected(); MainFormHandler.Instance.Export2ClientConfig(index, config); } private void menuExport2ServerConfig_Click(object sender, EventArgs e) { - int index = GetServerListSelectedConfigIndex(); + int index = GetConfigIndexFromServerListSelected(); MainFormHandler.Instance.Export2ServerConfig(index, config); } private void menuExport2ShareUrl_Click(object sender, EventArgs e) { - GetServerListSelectedConfigIndex(); + GetConfigIndexFromServerListSelected(); StringBuilder sb = new StringBuilder(); foreach (int v in lvSelecteds) @@ -749,7 +749,7 @@ namespace v2rayN.Forms private void menuExport2SubContent_Click(object sender, EventArgs e) { - GetServerListSelectedConfigIndex(); + GetConfigIndexFromServerListSelected(); StringBuilder sb = new StringBuilder(); foreach (int v in lvSelecteds) @@ -825,11 +825,11 @@ namespace v2rayN.Forms /// /// 获取服务器列表选中行的配置项(config)索引(index) /// - /// 返回值对应首个选中项,出错时返回-1 - /// 多选选中请在调用此函数后检查 lvSelecteds + /// 返回值对应首个选中项,无选中或出错时返回-1 + /// 访问多选请在调用此函数后访问 lvSelecteds /// /// - private int GetServerListSelectedConfigIndex() + private int GetConfigIndexFromServerListSelected() { int index = -1; lvSelecteds.Clear(); @@ -1195,7 +1195,7 @@ namespace v2rayN.Forms private void MoveServer(EMove eMove) { - int index = GetServerListSelectedConfigIndex(); + int index = GetConfigIndexFromServerListSelected(); if (index < 0) { UI.Show(UIRes.I18N("PleaseSelectServer")); From a81254dfffd80925c2e166b201b6dda4ef367ddd Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sun, 19 Apr 2020 00:06:00 +0800 Subject: [PATCH 36/45] fix port sort --- v2rayN/v2rayN/Forms/MainForm.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 62bb3ee7..1bd07d82 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -241,7 +241,7 @@ namespace v2rayN.Forms _addSubItem(lvItem, EServerColName.type.ToString(), ((EConfigType)item.configType).ToString()); _addSubItem(lvItem, EServerColName.remarks.ToString(), item.remarks); _addSubItem(lvItem, EServerColName.address.ToString(), item.address); - _addSubItem(lvItem, EServerColName.port.ToString(), item.port.ToString()); + _addSubItem(lvItem, EServerColName.port.ToString(), item.port.ToString(), item.port); _addSubItem(lvItem, EServerColName.security.ToString(), item.security); _addSubItem(lvItem, EServerColName.network.ToString(), item.network); _addSubItem(lvItem, EServerColName.subRemarks.ToString(), item.getSubRemarks(config)); From be7d76947b7e7db88da8528b6ddd72c4de89d184 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sun, 19 Apr 2020 00:19:01 +0800 Subject: [PATCH 37/45] Simple and refined sorting effect --- v2rayN/v2rayN/Base/ListViewSort.cs | 13 +++++++++++-- v2rayN/v2rayN/Forms/MainForm.cs | 28 ++++++++++++++-------------- v2rayN/v2rayN/Global.cs | 1 - 3 files changed, 25 insertions(+), 17 deletions(-) diff --git a/v2rayN/v2rayN/Base/ListViewSort.cs b/v2rayN/v2rayN/Base/ListViewSort.cs index 004985f5..362c206b 100644 --- a/v2rayN/v2rayN/Base/ListViewSort.cs +++ b/v2rayN/v2rayN/Base/ListViewSort.cs @@ -19,8 +19,17 @@ namespace v2rayN.Base int doIntSort = Sorting; if (doIntSort > 0) // Tag will be number { - ulong.TryParse(l1.SubItems[Column].Tag?.ToString(), out ulong fl1); - ulong.TryParse(l2.SubItems[Column].Tag?.ToString(), out ulong fl2); + var data1 = l1.SubItems[Column].Tag; + var data2 = l2.SubItems[Column].Tag; + if(data1 == null & data2 == null) + { + data1 = l1.SubItems[Column].Text; + data2 = l2.SubItems[Column].Text; + System.Diagnostics.Debug.WriteLine("Tag missing?"); + } + + ulong.TryParse(data1.ToString(), out ulong fl1); + ulong.TryParse(data2.ToString(), out ulong fl2); if (doIntSort == 1) { diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 1bd07d82..dcef6554 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -1666,30 +1666,30 @@ namespace v2rayN.Forms tsbOptionSetting_Click(toolSslRouting, null); } + private int lastSortedColIndex = -1; + private bool lastSortedColDirection = false; private void lvServers_ColumnClick(object sender, ColumnClickEventArgs e) { Sorter s = (Sorter)lvServers.ListViewItemSorter; s.Column = e.Column; int doIntSort; - if (lvServers.Columns[e.Column].Tag?.ToString() == Global.sortMode.Numeric.ToString()) // 数字正序 + bool isNum = lvServers.Columns[e.Column].Tag?.ToString() == Global.sortMode.Numeric.ToString(); + if (lastSortedColIndex < 0 // 首次 + || (lastSortedColIndex >= 0 && lastSortedColIndex != e.Column) // 排序了其他列 + || (lastSortedColIndex == e.Column && !lastSortedColDirection) // 已排序 + ) { - lvServers.Columns[e.Column].Tag = Global.sortMode.NumericB.ToString(); - doIntSort = 1; + lastSortedColDirection = true; + doIntSort = isNum ? 1 : -1; // 正序 } - else if (lvServers.Columns[e.Column].Tag?.ToString() == Global.sortMode.NumericB.ToString()) // 数字倒序 + else { - lvServers.Columns[e.Column].Tag = Global.sortMode.Numeric.ToString(); - doIntSort = 2; - } - else // 非数字 - { - bool bGo = bool.TryParse(lvServers.Columns[e.Column].Tag?.ToString(), out bool bOk); - // 首个转换将失败,如果Tag是null或其他。 - bool flag = bOk ? bGo : false; - lvServers.Columns[e.Column].Tag = !flag; // 首次则赋值true。 - doIntSort = flag ? -1 : -2; // -1正序 -2倒序 + lastSortedColDirection = false; + doIntSort = isNum ? 2 : -2; // 倒序 } + lastSortedColIndex = e.Column; + s.Sorting = doIntSort; lvServers.Sort(); diff --git a/v2rayN/v2rayN/Global.cs b/v2rayN/v2rayN/Global.cs index 5fc9a175..4fbd61e4 100644 --- a/v2rayN/v2rayN/Global.cs +++ b/v2rayN/v2rayN/Global.cs @@ -162,7 +162,6 @@ namespace v2rayN public enum sortMode { Numeric, - NumericB, // More, like natural numbers, string length, visual length, etc. } From 2c02285def8be47d31ee9b297625d7e8563eb311 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sun, 19 Apr 2020 00:58:55 +0800 Subject: [PATCH 38/45] refine GFWLIST_URL option --- v2rayN/v2rayN/Forms/MainForm.cs | 3 ++- v2rayN/v2rayN/Forms/OptionSettingForm.resx | 9 +++------ v2rayN/v2rayN/Forms/OptionSettingForm.zh-Hans.resx | 2 +- v2rayN/v2rayN/Handler/ConfigHandler.cs | 4 ---- v2rayN/v2rayN/Mode/Config.cs | 2 +- 5 files changed, 7 insertions(+), 13 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index dcef6554..aeaeabb4 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -1460,7 +1460,8 @@ namespace v2rayN.Forms }; } AppendText(false, UIRes.I18N("MsgStartUpdatingPAC")); - pacListHandle.WebDownloadString(config.urlGFWList); + string url = Utils.IsNullOrEmpty(config.urlGFWList) ? Global.GFWLIST_URL : config.urlGFWList; + pacListHandle.WebDownloadString(url); } private void tsbCheckClearPACList_Click(object sender, EventArgs e) diff --git a/v2rayN/v2rayN/Forms/OptionSettingForm.resx b/v2rayN/v2rayN/Forms/OptionSettingForm.resx index ea494864..7e082631 100644 --- a/v2rayN/v2rayN/Forms/OptionSettingForm.resx +++ b/v2rayN/v2rayN/Forms/OptionSettingForm.resx @@ -964,7 +964,7 @@ 27 - Custom GFWList address (please fill in the blank without customization) + Custom GFWList address (use default value if leave blank) System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 @@ -1915,10 +1915,7 @@ 4 - 32, 205 - - - True + 32, 200 txturlGFWList @@ -1927,7 +1924,7 @@ tabGUI - 541, 100 + 541, 21 28 diff --git a/v2rayN/v2rayN/Forms/OptionSettingForm.zh-Hans.resx b/v2rayN/v2rayN/Forms/OptionSettingForm.zh-Hans.resx index 293a96d7..b7968de4 100644 --- a/v2rayN/v2rayN/Forms/OptionSettingForm.zh-Hans.resx +++ b/v2rayN/v2rayN/Forms/OptionSettingForm.zh-Hans.resx @@ -252,7 +252,7 @@ 227, 12 - 自定义GFWList地址(不需自定义请填空白) + 自定义GFWList地址(留空则使用默认值) 191, 12 diff --git a/v2rayN/v2rayN/Handler/ConfigHandler.cs b/v2rayN/v2rayN/Handler/ConfigHandler.cs index dba4aad4..51301432 100644 --- a/v2rayN/v2rayN/Handler/ConfigHandler.cs +++ b/v2rayN/v2rayN/Handler/ConfigHandler.cs @@ -133,10 +133,6 @@ namespace v2rayN.Handler { config.speedPingTestUrl = Global.SpeedPingTestUrl; } - if (Utils.IsNullOrEmpty(config.urlGFWList)) - { - config.urlGFWList = Global.GFWLIST_URL; - } //if (Utils.IsNullOrEmpty(config.remoteDNS)) //{ // config.remoteDNS = "1.1.1.1"; diff --git a/v2rayN/v2rayN/Mode/Config.cs b/v2rayN/v2rayN/Mode/Config.cs index d473462f..0003fe03 100644 --- a/v2rayN/v2rayN/Mode/Config.cs +++ b/v2rayN/v2rayN/Mode/Config.cs @@ -86,7 +86,7 @@ namespace v2rayN.Mode /// public string speedPingTestUrl { get; set; } /// - /// 自定义GFWList url + /// 自定义GFWList url。空白则使用 Global.GFWLIST_URL /// public string urlGFWList { get; set; } From f4b885dce5c638e8ff041c0b99e21aa1c8ce4b12 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sun, 19 Apr 2020 01:08:21 +0800 Subject: [PATCH 39/45] subSetting speed up --- v2rayN/v2rayN/Forms/SubSettingForm.cs | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/v2rayN/v2rayN/Forms/SubSettingForm.cs b/v2rayN/v2rayN/Forms/SubSettingForm.cs index c8e7725b..f56b279e 100644 --- a/v2rayN/v2rayN/Forms/SubSettingForm.cs +++ b/v2rayN/v2rayN/Forms/SubSettingForm.cs @@ -8,8 +8,6 @@ namespace v2rayN.Forms { public partial class SubSettingForm : BaseForm { - List lstControls = new List(); - public SubSettingForm() { InitializeComponent(); @@ -30,8 +28,8 @@ namespace v2rayN.Forms /// private void RefreshSubsView() { + panCon.SuspendLayout(); panCon.Controls.Clear(); - lstControls.Clear(); for (int k = config.subItem.Count - 1; k >= 0; k--) { @@ -56,9 +54,8 @@ namespace v2rayN.Forms panCon.Controls.Add(control); panCon.Controls.SetChildIndex(control, 0); - - lstControls.Add(control); } + panCon.ResumeLayout(); } private void Control_OnButtonClicked(object sender, EventArgs e) From dee4b197752042086898cb29c3979a24573b613c Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sun, 19 Apr 2020 03:26:14 +0800 Subject: [PATCH 40/45] fixes sort the traffics may not work... --- v2rayN/v2rayN/Base/ListViewSort.cs | 27 +++++---------------------- 1 file changed, 5 insertions(+), 22 deletions(-) diff --git a/v2rayN/v2rayN/Base/ListViewSort.cs b/v2rayN/v2rayN/Base/ListViewSort.cs index 362c206b..4ea29705 100644 --- a/v2rayN/v2rayN/Base/ListViewSort.cs +++ b/v2rayN/v2rayN/Base/ListViewSort.cs @@ -17,42 +17,25 @@ namespace v2rayN.Base ListViewItem l2 = (ListViewItem)y; int doIntSort = Sorting; - if (doIntSort > 0) // Tag will be number + if (doIntSort > 0 // Tag will be number + && (ulong.TryParse(l1.SubItems[Column].Tag?.ToString(), out ulong fl1) + && ulong.TryParse(l2.SubItems[Column].Tag?.ToString(), out ulong fl2)) // fallback to text + ) { - var data1 = l1.SubItems[Column].Tag; - var data2 = l2.SubItems[Column].Tag; - if(data1 == null & data2 == null) - { - data1 = l1.SubItems[Column].Text; - data2 = l2.SubItems[Column].Text; - System.Diagnostics.Debug.WriteLine("Tag missing?"); - } - - ulong.TryParse(data1.ToString(), out ulong fl1); - ulong.TryParse(data2.ToString(), out ulong fl2); - if (doIntSort == 1) - { return fl1.CompareTo(fl2); - } else - { return fl2.CompareTo(fl1); - } } else { string str1 = l1.SubItems[Column].Text; string str2 = l2.SubItems[Column].Text; - if (doIntSort == -1) - { + if (doIntSort == -1 || doIntSort == 1) return str1.CompareTo(str2); - } else - { return str2.CompareTo(str1); - } } } } From a822fa976673c09e80f5222cef254fa64a6653f2 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sun, 19 Apr 2020 04:11:21 +0800 Subject: [PATCH 41/45] fixes crashes --- v2rayN/v2rayN/Forms/MainForm.cs | 1 + v2rayN/v2rayN/Handler/V2rayHandler.cs | 1 + v2rayN/v2rayN/HttpProxyHandler/PrivoxyHandler.cs | 1 + 3 files changed, 3 insertions(+) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index aeaeabb4..51cc08f8 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -413,6 +413,7 @@ namespace v2rayN.Forms { autoLatencyRefreshTask = Task.Run(async delegate { + if (!this.IsHandleCreated) return; // the GUI app is exiting. await Task.Delay(2000); this.Invoke((MethodInvoker)(delegate { diff --git a/v2rayN/v2rayN/Handler/V2rayHandler.cs b/v2rayN/v2rayN/Handler/V2rayHandler.cs index d3df7118..6967eec5 100644 --- a/v2rayN/v2rayN/Handler/V2rayHandler.cs +++ b/v2rayN/v2rayN/Handler/V2rayHandler.cs @@ -303,6 +303,7 @@ namespace v2rayN.Handler { try { + if (p.HasExited) return; p.CloseMainWindow(); p.WaitForExit(100); if (!p.HasExited) diff --git a/v2rayN/v2rayN/HttpProxyHandler/PrivoxyHandler.cs b/v2rayN/v2rayN/HttpProxyHandler/PrivoxyHandler.cs index 310054f0..771eb8a0 100644 --- a/v2rayN/v2rayN/HttpProxyHandler/PrivoxyHandler.cs +++ b/v2rayN/v2rayN/HttpProxyHandler/PrivoxyHandler.cs @@ -138,6 +138,7 @@ namespace v2rayN.HttpProxyHandler { try { + if (p.HasExited) return; // someting, while the GUI app is exiting. p.CloseMainWindow(); p.WaitForExit(100); if (!p.HasExited) From 9549d17b037fc7c96fad5541fdae7d5d39298173 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sun, 19 Apr 2020 05:56:09 +0800 Subject: [PATCH 42/45] fixes stats showing --- v2rayN/v2rayN/Forms/MainForm.cs | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 51cc08f8..f264e43d 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -1143,21 +1143,24 @@ namespace v2rayN.Forms { toolSslServerSpeed.Text = string.Format("{0}/s↑ | {1}/s↓", Utils.HumanFy(up), Utils.HumanFy(down)); })); - List datas = new List(); for (int i = 0; i < config.vmess.Count; i++) { - int index = statistics.FindIndex(item_ => item_.itemId == config.vmess[i].getItemId()); - if (index != -1) + int statsIndex = statistics.FindIndex(item_ => item_.itemId == config.vmess[i].getItemId()); + List l = GetServerListItemsByConfigIndex(i); + + if (statsIndex != -1 && l.Count > 0) { - if (lvServers == null) return; // The app is exiting. - lvServers.Invoke((MethodInvoker)delegate + this?.Invoke((MethodInvoker)delegate { lvServers.BeginUpdate(); - lvServers.Items[i].SubItems["todayDown"].Text = Utils.HumanFy(statistics[index].todayDown); - lvServers.Items[i].SubItems["todayUp"].Text = Utils.HumanFy(statistics[index].todayUp); - lvServers.Items[i].SubItems["totalDown"].Text = Utils.HumanFy(statistics[index].totalDown); - lvServers.Items[i].SubItems["totalUp"].Text = Utils.HumanFy(statistics[index].totalUp); + l.ForEach((listIndex) => + { + lvServers.Items[listIndex].SubItems["todayDown"].Text = Utils.HumanFy(statistics[statsIndex].todayDown); + lvServers.Items[listIndex].SubItems["todayUp"].Text = Utils.HumanFy(statistics[statsIndex].todayUp); + lvServers.Items[listIndex].SubItems["totalDown"].Text = Utils.HumanFy(statistics[statsIndex].totalDown); + lvServers.Items[listIndex].SubItems["totalUp"].Text = Utils.HumanFy(statistics[statsIndex].totalUp); + }); lvServers.EndUpdate(); }); From 56559e6509bf4519b27f887fc016a644b59913f0 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sun, 19 Apr 2020 06:22:51 +0800 Subject: [PATCH 43/45] treat index in menuRemoveDuplicateServer --- v2rayN/v2rayN/Forms/MainForm.cs | 10 ++++++++++ v2rayN/v2rayN/Tool/Utils.cs | 4 ++++ 2 files changed, 14 insertions(+) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index f264e43d..7d8cda03 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -627,12 +627,22 @@ namespace v2rayN.Forms private void menuRemoveDuplicateServer_Click(object sender, EventArgs e) { + VmessItem activeVm = null; + if (config.index >= 0) { + activeVm = config.vmess[config.index]; + } Utils.DedupServerList(config.vmess, out List servers, config.keepOlderDedupl); int oldCount = config.vmess.Count; int newCount = servers.Count; if (servers != null) { config.vmess = servers; + + if (activeVm != null) + { + int index = Utils.ServerVmIndexof(config.vmess, activeVm); + if (index >= 0) config.index = index; // restore to the correct value + } } //刷新 RefreshServers(); diff --git a/v2rayN/v2rayN/Tool/Utils.cs b/v2rayN/v2rayN/Tool/Utils.cs index 06dc979b..7ca0dd12 100644 --- a/v2rayN/v2rayN/Tool/Utils.cs +++ b/v2rayN/v2rayN/Tool/Utils.cs @@ -318,6 +318,10 @@ namespace v2rayN return $"{string.Format("{0:f1}", result)} {unit}"; } + public static int ServerVmIndexof(List source, Mode.VmessItem findIt) + { + return source.IndexOf(findIt); + } public static void DedupServerList(List source, out List result, bool keepOlder) { List list = new List(); From 20498ce45363af8425437b871937b52dd2a1b979 Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sun, 19 Apr 2020 02:39:17 +0800 Subject: [PATCH 44/45] refine message --- v2rayN/v2rayN/Forms/MainForm.cs | 2 +- v2rayN/v2rayN/Resx/ResUI.zh-Hans.resx | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/v2rayN/v2rayN/Forms/MainForm.cs b/v2rayN/v2rayN/Forms/MainForm.cs index 7d8cda03..0f6ecc3d 100644 --- a/v2rayN/v2rayN/Forms/MainForm.cs +++ b/v2rayN/v2rayN/Forms/MainForm.cs @@ -1588,7 +1588,7 @@ namespace v2rayN.Forms { if (args.Success) { - AppendText(false, $"{hashCode}{UIRes.I18N("MsgGetSubscriptionSuccessfully")}"); + //AppendText(false, $"{hashCode}{UIRes.I18N("MsgGetSubscriptionSuccessfully")}"); string result = Utils.Base64Decode(args.Msg); if (Utils.IsNullOrEmpty(result)) { diff --git a/v2rayN/v2rayN/Resx/ResUI.zh-Hans.resx b/v2rayN/v2rayN/Resx/ResUI.zh-Hans.resx index 431b9663..97d4f0df 100644 --- a/v2rayN/v2rayN/Resx/ResUI.zh-Hans.resx +++ b/v2rayN/v2rayN/Resx/ResUI.zh-Hans.resx @@ -274,13 +274,13 @@ 订阅内容解码失败(非BASE64码) - 正在解压...... + 正在解压... - 更新订阅结束 + 订阅内容已更新 - 更新订阅开始 + 开始更新订阅 更新V2rayCore成功 From aa3094f79610297930bfc5342fac6a5d1d912b9d Mon Sep 17 00:00:00 2001 From: YFdyh000 Date: Sun, 19 Apr 2020 04:11:30 +0800 Subject: [PATCH 45/45] try to speed up --- .../HttpProxyHandler/HttpProxyHandle.cs | 50 ++++++++++--------- 1 file changed, 27 insertions(+), 23 deletions(-) diff --git a/v2rayN/v2rayN/HttpProxyHandler/HttpProxyHandle.cs b/v2rayN/v2rayN/HttpProxyHandler/HttpProxyHandle.cs index 0236c5a8..142eca51 100644 --- a/v2rayN/v2rayN/HttpProxyHandler/HttpProxyHandle.cs +++ b/v2rayN/v2rayN/HttpProxyHandler/HttpProxyHandle.cs @@ -1,4 +1,5 @@ using System; +using System.Threading.Tasks; using v2rayN.Mode; namespace v2rayN.HttpProxyHandler @@ -148,33 +149,36 @@ namespace v2rayN.HttpProxyHandler /// /// /// - public static void RestartHttpAgent(Config config, bool forced) + public static Task RestartHttpAgent(Config config, bool forced) { - bool isRestart = false; - if (config.listenerType == ListenerType.noHttpProxy) - { - // 关闭http proxy时,直接返回 - return; - } - //强制重启或者socks端口变化 - if (forced) - { - isRestart = true; - } - else - { - int localPort = config.GetLocalPort(Global.InboundSocks); - if (localPort != Global.socksPort) + return Task.Run(() => + { + bool isRestart = false; + if (config.listenerType == ListenerType.noHttpProxy) + { + // 关闭http proxy时,直接返回 + return; + } + //强制重启或者socks端口变化 + if (forced) { isRestart = true; } - } - if (isRestart) - { - CloseHttpAgent(config); - StartHttpAgent(config); - } - Update(config, false); + else + { + int localPort = config.GetLocalPort(Global.InboundSocks); + if (localPort != Global.socksPort) + { + isRestart = true; + } + } + if (isRestart) + { + CloseHttpAgent(config); + StartHttpAgent(config); + } + Update(config, false); + }); } public static string GetPacUrl()