Compare commits
9 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
cf1ae8f240 | ||
|
|
9b2261918f | ||
|
|
f74071691f | ||
|
|
6d5e02860e | ||
|
|
ffa2acb2f5 | ||
|
|
25b4ff771e | ||
|
|
7a48617fea | ||
|
|
800807b47a | ||
|
|
eaf11c6998 |
23
v2rayN/v2rayN/Forms/MainForm.Designer.cs
generated
23
v2rayN/v2rayN/Forms/MainForm.Designer.cs
generated
@@ -96,6 +96,8 @@
|
|||||||
this.tsbSubSetting = new System.Windows.Forms.ToolStripMenuItem();
|
this.tsbSubSetting = new System.Windows.Forms.ToolStripMenuItem();
|
||||||
this.tsbSubUpdate = new System.Windows.Forms.ToolStripMenuItem();
|
this.tsbSubUpdate = new System.Windows.Forms.ToolStripMenuItem();
|
||||||
this.tsbSubUpdateViaProxy = new System.Windows.Forms.ToolStripMenuItem();
|
this.tsbSubUpdateViaProxy = new System.Windows.Forms.ToolStripMenuItem();
|
||||||
|
this.tsbSubGroupUpdate = new System.Windows.Forms.ToolStripMenuItem();
|
||||||
|
this.tsbSubGroupUpdateViaProxy = new System.Windows.Forms.ToolStripMenuItem();
|
||||||
this.tsbQRCodeSwitch = new System.Windows.Forms.ToolStripButton();
|
this.tsbQRCodeSwitch = new System.Windows.Forms.ToolStripButton();
|
||||||
this.toolStripSeparator8 = new System.Windows.Forms.ToolStripSeparator();
|
this.toolStripSeparator8 = new System.Windows.Forms.ToolStripSeparator();
|
||||||
this.tsbSetting = new System.Windows.Forms.ToolStripDropDownButton();
|
this.tsbSetting = new System.Windows.Forms.ToolStripDropDownButton();
|
||||||
@@ -191,11 +193,11 @@
|
|||||||
this.menuAddServers,
|
this.menuAddServers,
|
||||||
this.menuScanScreen,
|
this.menuScanScreen,
|
||||||
this.toolStripSeparator1,
|
this.toolStripSeparator1,
|
||||||
|
this.menuServerFilter,
|
||||||
this.menuRemoveServer,
|
this.menuRemoveServer,
|
||||||
this.menuRemoveDuplicateServer,
|
this.menuRemoveDuplicateServer,
|
||||||
this.menuCopyServer,
|
this.menuCopyServer,
|
||||||
this.menuSetDefaultServer,
|
this.menuSetDefaultServer,
|
||||||
this.menuServerFilter,
|
|
||||||
this.toolStripSeparator3,
|
this.toolStripSeparator3,
|
||||||
this.menuMoveToGroup,
|
this.menuMoveToGroup,
|
||||||
this.menuMoveEvent,
|
this.menuMoveEvent,
|
||||||
@@ -214,7 +216,6 @@
|
|||||||
this.menuExport2ShareUrl,
|
this.menuExport2ShareUrl,
|
||||||
this.menuExport2SubContent});
|
this.menuExport2SubContent});
|
||||||
this.cmsLv.Name = "cmsLv";
|
this.cmsLv.Name = "cmsLv";
|
||||||
this.cmsLv.OwnerItem = this.tsbServer;
|
|
||||||
resources.ApplyResources(this.cmsLv, "cmsLv");
|
resources.ApplyResources(this.cmsLv, "cmsLv");
|
||||||
//
|
//
|
||||||
// menuAddVmessServer
|
// menuAddVmessServer
|
||||||
@@ -612,7 +613,9 @@
|
|||||||
this.tsbSub.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
|
this.tsbSub.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
|
||||||
this.tsbSubSetting,
|
this.tsbSubSetting,
|
||||||
this.tsbSubUpdate,
|
this.tsbSubUpdate,
|
||||||
this.tsbSubUpdateViaProxy});
|
this.tsbSubUpdateViaProxy,
|
||||||
|
this.tsbSubGroupUpdate,
|
||||||
|
this.tsbSubGroupUpdateViaProxy});
|
||||||
this.tsbSub.Image = global::v2rayN.Properties.Resources.sub;
|
this.tsbSub.Image = global::v2rayN.Properties.Resources.sub;
|
||||||
resources.ApplyResources(this.tsbSub, "tsbSub");
|
resources.ApplyResources(this.tsbSub, "tsbSub");
|
||||||
this.tsbSub.Name = "tsbSub";
|
this.tsbSub.Name = "tsbSub";
|
||||||
@@ -635,6 +638,18 @@
|
|||||||
resources.ApplyResources(this.tsbSubUpdateViaProxy, "tsbSubUpdateViaProxy");
|
resources.ApplyResources(this.tsbSubUpdateViaProxy, "tsbSubUpdateViaProxy");
|
||||||
this.tsbSubUpdateViaProxy.Click += new System.EventHandler(this.tsbSubUpdateViaProxy_Click);
|
this.tsbSubUpdateViaProxy.Click += new System.EventHandler(this.tsbSubUpdateViaProxy_Click);
|
||||||
//
|
//
|
||||||
|
// tsbSubGroupUpdate
|
||||||
|
//
|
||||||
|
this.tsbSubGroupUpdate.Name = "tsbSubGroupUpdate";
|
||||||
|
resources.ApplyResources(this.tsbSubGroupUpdate, "tsbSubGroupUpdate");
|
||||||
|
this.tsbSubGroupUpdate.Click += new System.EventHandler(this.tsbSubGroupUpdate_Click);
|
||||||
|
//
|
||||||
|
// tsbSubGroupUpdateViaProxy
|
||||||
|
//
|
||||||
|
this.tsbSubGroupUpdateViaProxy.Name = "tsbSubGroupUpdateViaProxy";
|
||||||
|
resources.ApplyResources(this.tsbSubGroupUpdateViaProxy, "tsbSubGroupUpdateViaProxy");
|
||||||
|
this.tsbSubGroupUpdateViaProxy.Click += new System.EventHandler(this.tsbSubGroupUpdateViaProxy_Click);
|
||||||
|
//
|
||||||
// tsbQRCodeSwitch
|
// tsbQRCodeSwitch
|
||||||
//
|
//
|
||||||
this.tsbQRCodeSwitch.CheckOnClick = true;
|
this.tsbQRCodeSwitch.CheckOnClick = true;
|
||||||
@@ -981,6 +996,8 @@
|
|||||||
private System.Windows.Forms.ToolStripSeparator toolStripSeparator16;
|
private System.Windows.Forms.ToolStripSeparator toolStripSeparator16;
|
||||||
private System.Windows.Forms.ToolStripMenuItem menuSortServerResult;
|
private System.Windows.Forms.ToolStripMenuItem menuSortServerResult;
|
||||||
private System.Windows.Forms.ToolStripMenuItem tsbCheckUpdateSagerNetCore;
|
private System.Windows.Forms.ToolStripMenuItem tsbCheckUpdateSagerNetCore;
|
||||||
|
private System.Windows.Forms.ToolStripMenuItem tsbSubGroupUpdate;
|
||||||
|
private System.Windows.Forms.ToolStripMenuItem tsbSubGroupUpdateViaProxy;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ namespace v2rayN.Forms
|
|||||||
private List<VmessItem> lstSelecteds = new List<VmessItem>();
|
private List<VmessItem> lstSelecteds = new List<VmessItem>();
|
||||||
private StatisticsHandler statistics;
|
private StatisticsHandler statistics;
|
||||||
private List<VmessItem> lstVmess;
|
private List<VmessItem> lstVmess;
|
||||||
private string groupId = string.Empty;
|
private string _groupId = string.Empty;
|
||||||
private string serverFilter = string.Empty;
|
private string serverFilter = string.Empty;
|
||||||
|
|
||||||
#region Window 事件
|
#region Window 事件
|
||||||
@@ -160,7 +160,15 @@ namespace v2rayN.Forms
|
|||||||
|
|
||||||
if (!config.uiItem.mainLocation.IsEmpty)
|
if (!config.uiItem.mainLocation.IsEmpty)
|
||||||
{
|
{
|
||||||
Location = config.uiItem.mainLocation;
|
if (config.uiItem.mainLocation.X >= SystemInformation.WorkingArea.Width
|
||||||
|
|| config.uiItem.mainLocation.Y >= SystemInformation.WorkingArea.Height)
|
||||||
|
{
|
||||||
|
Location = new Point(0, 0);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Location = config.uiItem.mainLocation;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (!config.uiItem.mainSize.IsEmpty)
|
if (!config.uiItem.mainSize.IsEmpty)
|
||||||
{
|
{
|
||||||
@@ -218,13 +226,17 @@ namespace v2rayN.Forms
|
|||||||
private void RefreshServers()
|
private void RefreshServers()
|
||||||
{
|
{
|
||||||
lstVmess = config.vmess
|
lstVmess = config.vmess
|
||||||
.Where(it => Utils.IsNullOrEmpty(groupId) || it.groupId == groupId)
|
.Where(it => Utils.IsNullOrEmpty(_groupId) || it.groupId == _groupId)
|
||||||
.Where(it => Utils.IsNullOrEmpty(serverFilter) || it.remarks.Contains(serverFilter))
|
.Where(it => Utils.IsNullOrEmpty(serverFilter) || it.remarks.Contains(serverFilter))
|
||||||
.OrderBy(it => it.sort)
|
.OrderBy(it => it.sort)
|
||||||
.ToList();
|
.ToList();
|
||||||
|
|
||||||
ConfigHandler.SetDefaultServer(config, lstVmess);
|
ConfigHandler.SetDefaultServer(config, lstVmess);
|
||||||
RefreshServersView();
|
BeginInvoke(new Action(() =>
|
||||||
|
{
|
||||||
|
RefreshServersView();
|
||||||
|
}));
|
||||||
|
|
||||||
RefreshServersMenu();
|
RefreshServersMenu();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -289,11 +301,11 @@ namespace v2rayN.Forms
|
|||||||
|
|
||||||
for (int k = 0; k < lstVmess.Count; k++)
|
for (int k = 0; k < lstVmess.Count; k++)
|
||||||
{
|
{
|
||||||
string def = string.Empty;
|
string def = (k + 1).ToString();
|
||||||
VmessItem item = lstVmess[k];
|
VmessItem item = lstVmess[k];
|
||||||
if (config.IsActiveNode(item))
|
if (config.IsActiveNode(item))
|
||||||
{
|
{
|
||||||
def = "√";
|
def = Global.CheckMark;
|
||||||
}
|
}
|
||||||
|
|
||||||
ListViewItem lvItem = new ListViewItem(def);
|
ListViewItem lvItem = new ListViewItem(def);
|
||||||
@@ -483,9 +495,9 @@ namespace v2rayN.Forms
|
|||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
groupId = string.Empty;
|
_groupId = string.Empty;
|
||||||
//groupId = tabGroup.TabPages[tabGroup.SelectedIndex].Name;
|
//groupId = tabGroup.TabPages[tabGroup.SelectedIndex].Name;
|
||||||
groupId = tabGroup.SelectedTab.Name;
|
_groupId = tabGroup.SelectedTab.Name;
|
||||||
|
|
||||||
RefreshServers();
|
RefreshServers();
|
||||||
|
|
||||||
@@ -596,7 +608,7 @@ namespace v2rayN.Forms
|
|||||||
fm = new AddServerForm();
|
fm = new AddServerForm();
|
||||||
}
|
}
|
||||||
fm.vmessItem = index >= 0 ? lstVmess[index] : null;
|
fm.vmessItem = index >= 0 ? lstVmess[index] : null;
|
||||||
fm.groupId = groupId;
|
fm.groupId = _groupId;
|
||||||
fm.eConfigType = configType;
|
fm.eConfigType = configType;
|
||||||
if (fm.ShowDialog() == DialogResult.OK)
|
if (fm.ShowDialog() == DialogResult.OK)
|
||||||
{
|
{
|
||||||
@@ -943,13 +955,13 @@ namespace v2rayN.Forms
|
|||||||
{
|
{
|
||||||
if (config.IsActiveNode(lstVmess[k]))
|
if (config.IsActiveNode(lstVmess[k]))
|
||||||
{
|
{
|
||||||
lvServers.Items[k].SubItems[0].Text = "√";
|
lvServers.Items[k].SubItems[0].Text = Global.CheckMark;
|
||||||
lvServers.Items[k].ForeColor = Color.DodgerBlue;
|
lvServers.Items[k].ForeColor = Color.DodgerBlue;
|
||||||
lvServers.Items[k].Font = new Font(lvServers.Font, FontStyle.Bold);
|
lvServers.Items[k].Font = new Font(lvServers.Font, FontStyle.Bold);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
lvServers.Items[k].SubItems[0].Text = "";
|
lvServers.Items[k].SubItems[0].Text = (k + 1).ToString();
|
||||||
lvServers.Items[k].ForeColor = lvServers.ForeColor;
|
lvServers.Items[k].ForeColor = lvServers.ForeColor;
|
||||||
lvServers.Items[k].Font = new Font(lvServers.Font, FontStyle.Regular);
|
lvServers.Items[k].Font = new Font(lvServers.Font, FontStyle.Regular);
|
||||||
}
|
}
|
||||||
@@ -1018,7 +1030,7 @@ namespace v2rayN.Forms
|
|||||||
private void menuAddServers_Click(object sender, EventArgs e)
|
private void menuAddServers_Click(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
string clipboardData = Utils.GetClipboardData();
|
string clipboardData = Utils.GetClipboardData();
|
||||||
int ret = ConfigHandler.AddBatchServers(ref config, clipboardData, "", groupId);
|
int ret = ConfigHandler.AddBatchServers(ref config, clipboardData, "", _groupId);
|
||||||
if (ret > 0)
|
if (ret > 0)
|
||||||
{
|
{
|
||||||
RefreshServers();
|
RefreshServers();
|
||||||
@@ -1048,7 +1060,7 @@ namespace v2rayN.Forms
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
int ret = ConfigHandler.AddBatchServers(ref config, result, "", groupId);
|
int ret = ConfigHandler.AddBatchServers(ref config, result, "", _groupId);
|
||||||
if (ret > 0)
|
if (ret > 0)
|
||||||
{
|
{
|
||||||
RefreshServers();
|
RefreshServers();
|
||||||
@@ -1059,11 +1071,11 @@ namespace v2rayN.Forms
|
|||||||
|
|
||||||
private void menuUpdateSubscriptions_Click(object sender, EventArgs e)
|
private void menuUpdateSubscriptions_Click(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
UpdateSubscriptionProcess(false);
|
UpdateSubscriptionProcess("", false);
|
||||||
}
|
}
|
||||||
private void menuUpdateSubViaProxy_Click(object sender, EventArgs e)
|
private void menuUpdateSubViaProxy_Click(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
UpdateSubscriptionProcess(true);
|
UpdateSubscriptionProcess("", true);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void tsbBackupGuiNConfig_Click(object sender, EventArgs e)
|
private void tsbBackupGuiNConfig_Click(object sender, EventArgs e)
|
||||||
@@ -1145,7 +1157,7 @@ namespace v2rayN.Forms
|
|||||||
if (index >= 0 && index < lvServers.Items.Count && lvServers.Items.Count > 0)
|
if (index >= 0 && index < lvServers.Items.Count && lvServers.Items.Count > 0)
|
||||||
{
|
{
|
||||||
lvServers.Items[index].Selected = true;
|
lvServers.Items[index].Selected = true;
|
||||||
lvServers.SetScrollPosition(index);
|
lvServers.SetScrollPosition(index);
|
||||||
}
|
}
|
||||||
|
|
||||||
SetVisibleCore(true);
|
SetVisibleCore(true);
|
||||||
@@ -1356,7 +1368,7 @@ namespace v2rayN.Forms
|
|||||||
menuExit_Click(null, null);
|
menuExit_Click(null, null);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
(new UpdateHandle()).CheckUpdateGuiN(config, _updateUI);
|
(new UpdateHandle()).CheckUpdateGuiN(config, _updateUI, config.checkPreReleaseUpdate);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void tsbCheckUpdateCore_Click(object sender, EventArgs e)
|
private void tsbCheckUpdateCore_Click(object sender, EventArgs e)
|
||||||
@@ -1404,7 +1416,7 @@ namespace v2rayN.Forms
|
|||||||
AppendText(false, ResUI.MsgUpdateV2rayCoreSuccessfully);
|
AppendText(false, ResUI.MsgUpdateV2rayCoreSuccessfully);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
(new UpdateHandle()).CheckUpdateCore(type, config, _updateUI);
|
(new UpdateHandle()).CheckUpdateCore(type, config, _updateUI, config.checkPreReleaseUpdate);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void tsbCheckUpdateGeo_Click(object sender, EventArgs e)
|
private void tsbCheckUpdateGeo_Click(object sender, EventArgs e)
|
||||||
@@ -1450,18 +1462,18 @@ namespace v2rayN.Forms
|
|||||||
|
|
||||||
private void tsbSubUpdate_Click(object sender, EventArgs e)
|
private void tsbSubUpdate_Click(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
UpdateSubscriptionProcess(false);
|
UpdateSubscriptionProcess("", false);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void tsbSubUpdateViaProxy_Click(object sender, EventArgs e)
|
private void tsbSubUpdateViaProxy_Click(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
UpdateSubscriptionProcess(true);
|
UpdateSubscriptionProcess("", true);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// the subscription update process
|
/// the subscription update process
|
||||||
/// </summary>
|
/// </summary>
|
||||||
private void UpdateSubscriptionProcess(bool blProxy)
|
private void UpdateSubscriptionProcess(string groupId, bool blProxy)
|
||||||
{
|
{
|
||||||
void _updateUI(bool success, string msg)
|
void _updateUI(bool success, string msg)
|
||||||
{
|
{
|
||||||
@@ -1479,7 +1491,7 @@ namespace v2rayN.Forms
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
(new UpdateHandle()).UpdateSubscriptionProcess(config, blProxy, _updateUI);
|
(new UpdateHandle()).UpdateSubscriptionProcess(config, groupId, blProxy, _updateUI);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void tsbQRCodeSwitch_CheckedChanged(object sender, EventArgs e)
|
private void tsbQRCodeSwitch_CheckedChanged(object sender, EventArgs e)
|
||||||
@@ -1569,5 +1581,14 @@ namespace v2rayN.Forms
|
|||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
private void tsbSubGroupUpdate_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
UpdateSubscriptionProcess(_groupId, true);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void tsbSubGroupUpdateViaProxy_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
UpdateSubscriptionProcess(_groupId, true);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -179,6 +179,12 @@
|
|||||||
<data name="toolStripSeparator1.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="toolStripSeparator1.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>352, 6</value>
|
<value>352, 6</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="menuServerFilter.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
|
<value>355, 22</value>
|
||||||
|
</data>
|
||||||
|
<data name="menuServerFilter.Text" xml:space="preserve">
|
||||||
|
<value>Set server filter (Ctrl+F)</value>
|
||||||
|
</data>
|
||||||
<data name="menuRemoveServer.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="menuRemoveServer.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>355, 22</value>
|
<value>355, 22</value>
|
||||||
</data>
|
</data>
|
||||||
@@ -203,12 +209,6 @@
|
|||||||
<data name="menuSetDefaultServer.Text" xml:space="preserve">
|
<data name="menuSetDefaultServer.Text" xml:space="preserve">
|
||||||
<value>Set as active server (Enter)</value>
|
<value>Set as active server (Enter)</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="menuServerFilter.Size" type="System.Drawing.Size, System.Drawing">
|
|
||||||
<value>355, 22</value>
|
|
||||||
</data>
|
|
||||||
<data name="menuServerFilter.Text" xml:space="preserve">
|
|
||||||
<value>Set server filter (Ctrl+F)</value>
|
|
||||||
</data>
|
|
||||||
<data name="toolStripSeparator3.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="toolStripSeparator3.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>352, 6</value>
|
<value>352, 6</value>
|
||||||
</data>
|
</data>
|
||||||
@@ -326,18 +326,6 @@
|
|||||||
<data name="menuExport2SubContent.Text" xml:space="preserve">
|
<data name="menuExport2SubContent.Text" xml:space="preserve">
|
||||||
<value>Export subscription (base64) share to clipboard</value>
|
<value>Export subscription (base64) share to clipboard</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="tsbServer.ImageTransparentColor" type="System.Drawing.Color, System.Drawing">
|
|
||||||
<value>Magenta</value>
|
|
||||||
</data>
|
|
||||||
<data name="tsbServer.Size" type="System.Drawing.Size, System.Drawing">
|
|
||||||
<value>64, 53</value>
|
|
||||||
</data>
|
|
||||||
<data name="tsbServer.Text" xml:space="preserve">
|
|
||||||
<value>Servers</value>
|
|
||||||
</data>
|
|
||||||
<data name="tsbServer.TextImageRelation" type="System.Windows.Forms.TextImageRelation, System.Windows.Forms">
|
|
||||||
<value>ImageAboveText</value>
|
|
||||||
</data>
|
|
||||||
<data name="cmsLv.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="cmsLv.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>356, 644</value>
|
<value>356, 644</value>
|
||||||
</data>
|
</data>
|
||||||
@@ -488,6 +476,18 @@
|
|||||||
<data name=">>scServers.ZOrder" xml:space="preserve">
|
<data name=">>scServers.ZOrder" xml:space="preserve">
|
||||||
<value>0</value>
|
<value>0</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="tsbServer.ImageTransparentColor" type="System.Drawing.Color, System.Drawing">
|
||||||
|
<value>Magenta</value>
|
||||||
|
</data>
|
||||||
|
<data name="tsbServer.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
|
<value>64, 53</value>
|
||||||
|
</data>
|
||||||
|
<data name="tsbServer.Text" xml:space="preserve">
|
||||||
|
<value>Servers</value>
|
||||||
|
</data>
|
||||||
|
<data name="tsbServer.TextImageRelation" type="System.Windows.Forms.TextImageRelation, System.Windows.Forms">
|
||||||
|
<value>ImageAboveText</value>
|
||||||
|
</data>
|
||||||
<data name="scBig.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
|
<data name="scBig.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
|
||||||
<value>Fill</value>
|
<value>Fill</value>
|
||||||
</data>
|
</data>
|
||||||
@@ -717,23 +717,35 @@
|
|||||||
<value>6, 56</value>
|
<value>6, 56</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="tsbSubSetting.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="tsbSubSetting.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>277, 22</value>
|
<value>317, 22</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="tsbSubSetting.Text" xml:space="preserve">
|
<data name="tsbSubSetting.Text" xml:space="preserve">
|
||||||
<value>Settings</value>
|
<value>Settings</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="tsbSubUpdate.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="tsbSubUpdate.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>277, 22</value>
|
<value>317, 22</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="tsbSubUpdate.Text" xml:space="preserve">
|
<data name="tsbSubUpdate.Text" xml:space="preserve">
|
||||||
<value>Update subscription without proxy</value>
|
<value>Update subscription without proxy</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="tsbSubUpdateViaProxy.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="tsbSubUpdateViaProxy.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>277, 22</value>
|
<value>317, 22</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="tsbSubUpdateViaProxy.Text" xml:space="preserve">
|
<data name="tsbSubUpdateViaProxy.Text" xml:space="preserve">
|
||||||
<value>Update subscription with proxy</value>
|
<value>Update subscription with proxy</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="tsbSubGroupUpdate.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
|
<value>317, 22</value>
|
||||||
|
</data>
|
||||||
|
<data name="tsbSubGroupUpdate.Text" xml:space="preserve">
|
||||||
|
<value>Update group subscription without proxy</value>
|
||||||
|
</data>
|
||||||
|
<data name="tsbSubGroupUpdateViaProxy.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
|
<value>317, 22</value>
|
||||||
|
</data>
|
||||||
|
<data name="tsbSubGroupUpdateViaProxy.Text" xml:space="preserve">
|
||||||
|
<value>Update group subscription with proxy</value>
|
||||||
|
</data>
|
||||||
<data name="tsbSub.ImageTransparentColor" type="System.Drawing.Color, System.Drawing">
|
<data name="tsbSub.ImageTransparentColor" type="System.Drawing.Color, System.Drawing">
|
||||||
<value>Magenta</value>
|
<value>Magenta</value>
|
||||||
</data>
|
</data>
|
||||||
@@ -845,6 +857,9 @@
|
|||||||
<data name="tsbCheckUpdateSagerNetCore.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="tsbCheckUpdateSagerNetCore.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>219, 22</value>
|
<value>219, 22</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="tsbCheckUpdateSagerNetCore.Text" xml:space="preserve">
|
||||||
|
<value>Update SagerNet Core</value>
|
||||||
|
</data>
|
||||||
<data name="tsbCheckUpdateXrayCore.Size" type="System.Drawing.Size, System.Drawing">
|
<data name="tsbCheckUpdateXrayCore.Size" type="System.Drawing.Size, System.Drawing">
|
||||||
<value>219, 22</value>
|
<value>219, 22</value>
|
||||||
</data>
|
</data>
|
||||||
@@ -1325,6 +1340,18 @@
|
|||||||
<data name=">>tsbSubUpdateViaProxy.Type" xml:space="preserve">
|
<data name=">>tsbSubUpdateViaProxy.Type" xml:space="preserve">
|
||||||
<value>System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
<value>System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name=">>tsbSubGroupUpdate.Name" xml:space="preserve">
|
||||||
|
<value>tsbSubGroupUpdate</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>tsbSubGroupUpdate.Type" xml:space="preserve">
|
||||||
|
<value>System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>tsbSubGroupUpdateViaProxy.Name" xml:space="preserve">
|
||||||
|
<value>tsbSubGroupUpdateViaProxy</value>
|
||||||
|
</data>
|
||||||
|
<data name=">>tsbSubGroupUpdateViaProxy.Type" xml:space="preserve">
|
||||||
|
<value>System.Windows.Forms.ToolStripMenuItem, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</data>
|
||||||
<data name=">>tsbQRCodeSwitch.Name" xml:space="preserve">
|
<data name=">>tsbQRCodeSwitch.Name" xml:space="preserve">
|
||||||
<value>tsbQRCodeSwitch</value>
|
<value>tsbQRCodeSwitch</value>
|
||||||
</data>
|
</data>
|
||||||
@@ -1523,7 +1550,4 @@
|
|||||||
<data name=">>$this.Type" xml:space="preserve">
|
<data name=">>$this.Type" xml:space="preserve">
|
||||||
<value>v2rayN.Forms.BaseForm, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</value>
|
<value>v2rayN.Forms.BaseForm, v2rayN, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="tsbCheckUpdateSagerNetCore.Text" xml:space="preserve">
|
|
||||||
<value>Update SagerNet Core</value>
|
|
||||||
</data>
|
|
||||||
</root>
|
</root>
|
||||||
@@ -573,4 +573,10 @@
|
|||||||
<data name="tsbCheckUpdateSagerNetCore.Text" xml:space="preserve">
|
<data name="tsbCheckUpdateSagerNetCore.Text" xml:space="preserve">
|
||||||
<value>SagerNet-Core</value>
|
<value>SagerNet-Core</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="tsbSubGroupUpdate.Text" xml:space="preserve">
|
||||||
|
<value>更新当前分组订阅(不通过代理)</value>
|
||||||
|
</data>
|
||||||
|
<data name="tsbSubGroupUpdateViaProxy.Text" xml:space="preserve">
|
||||||
|
<value>更新当前分组订阅(通过代理)</value>
|
||||||
|
</data>
|
||||||
</root>
|
</root>
|
||||||
@@ -26,7 +26,11 @@ namespace v2rayN.Forms
|
|||||||
|
|
||||||
private void MainMsgControl_Load(object sender, EventArgs e)
|
private void MainMsgControl_Load(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
|
_msgFilter = Utils.RegReadValue(Global.MyRegPath, Utils.MainMsgFilterKey, "");
|
||||||
|
if (!Utils.IsNullOrEmpty(_msgFilter))
|
||||||
|
{
|
||||||
|
gbMsgTitle.Text = string.Format(ResUI.MsgInformationTitle, _msgFilter);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#region 提示信息
|
#region 提示信息
|
||||||
@@ -188,6 +192,7 @@ namespace v2rayN.Forms
|
|||||||
{
|
{
|
||||||
_msgFilter = fm.MsgFilter;
|
_msgFilter = fm.MsgFilter;
|
||||||
gbMsgTitle.Text = string.Format(ResUI.MsgInformationTitle, _msgFilter);
|
gbMsgTitle.Text = string.Format(ResUI.MsgInformationTitle, _msgFilter);
|
||||||
|
Utils.RegWriteValue(Global.MyRegPath, Utils.MainMsgFilterKey, _msgFilter);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
51
v2rayN/v2rayN/Forms/OptionSettingForm.Designer.cs
generated
51
v2rayN/v2rayN/Forms/OptionSettingForm.Designer.cs
generated
@@ -108,6 +108,7 @@
|
|||||||
this.panel2 = new System.Windows.Forms.Panel();
|
this.panel2 = new System.Windows.Forms.Panel();
|
||||||
this.btnOK = new System.Windows.Forms.Button();
|
this.btnOK = new System.Windows.Forms.Button();
|
||||||
this.panel1 = new System.Windows.Forms.Panel();
|
this.panel1 = new System.Windows.Forms.Panel();
|
||||||
|
this.chkEnableCheckPreReleaseUpdate = new System.Windows.Forms.CheckBox();
|
||||||
this.tabControl1.SuspendLayout();
|
this.tabControl1.SuspendLayout();
|
||||||
this.tabPage1.SuspendLayout();
|
this.tabPage1.SuspendLayout();
|
||||||
this.groupBox1.SuspendLayout();
|
this.groupBox1.SuspendLayout();
|
||||||
@@ -123,34 +124,33 @@
|
|||||||
//
|
//
|
||||||
// btnClose
|
// btnClose
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.btnClose, "btnClose");
|
|
||||||
this.btnClose.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
this.btnClose.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||||
|
resources.ApplyResources(this.btnClose, "btnClose");
|
||||||
this.btnClose.Name = "btnClose";
|
this.btnClose.Name = "btnClose";
|
||||||
this.btnClose.UseVisualStyleBackColor = true;
|
this.btnClose.UseVisualStyleBackColor = true;
|
||||||
this.btnClose.Click += new System.EventHandler(this.btnClose_Click);
|
this.btnClose.Click += new System.EventHandler(this.btnClose_Click);
|
||||||
//
|
//
|
||||||
// tabControl1
|
// tabControl1
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.tabControl1, "tabControl1");
|
|
||||||
this.tabControl1.Controls.Add(this.tabPage1);
|
this.tabControl1.Controls.Add(this.tabPage1);
|
||||||
this.tabControl1.Controls.Add(this.tabPage2);
|
this.tabControl1.Controls.Add(this.tabPage2);
|
||||||
this.tabControl1.Controls.Add(this.tabPage6);
|
this.tabControl1.Controls.Add(this.tabPage6);
|
||||||
this.tabControl1.Controls.Add(this.tabPage7);
|
this.tabControl1.Controls.Add(this.tabPage7);
|
||||||
this.tabControl1.Controls.Add(this.tabPageCoreType);
|
this.tabControl1.Controls.Add(this.tabPageCoreType);
|
||||||
this.tabControl1.Controls.Add(this.tabPage3);
|
this.tabControl1.Controls.Add(this.tabPage3);
|
||||||
|
resources.ApplyResources(this.tabControl1, "tabControl1");
|
||||||
this.tabControl1.Name = "tabControl1";
|
this.tabControl1.Name = "tabControl1";
|
||||||
this.tabControl1.SelectedIndex = 0;
|
this.tabControl1.SelectedIndex = 0;
|
||||||
//
|
//
|
||||||
// tabPage1
|
// tabPage1
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.tabPage1, "tabPage1");
|
|
||||||
this.tabPage1.Controls.Add(this.groupBox1);
|
this.tabPage1.Controls.Add(this.groupBox1);
|
||||||
|
resources.ApplyResources(this.tabPage1, "tabPage1");
|
||||||
this.tabPage1.Name = "tabPage1";
|
this.tabPage1.Name = "tabPage1";
|
||||||
this.tabPage1.UseVisualStyleBackColor = true;
|
this.tabPage1.UseVisualStyleBackColor = true;
|
||||||
//
|
//
|
||||||
// groupBox1
|
// groupBox1
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.groupBox1, "groupBox1");
|
|
||||||
this.groupBox1.Controls.Add(this.label16);
|
this.groupBox1.Controls.Add(this.label16);
|
||||||
this.groupBox1.Controls.Add(this.label4);
|
this.groupBox1.Controls.Add(this.label4);
|
||||||
this.groupBox1.Controls.Add(this.txtpass);
|
this.groupBox1.Controls.Add(this.txtpass);
|
||||||
@@ -167,6 +167,7 @@
|
|||||||
this.groupBox1.Controls.Add(this.label5);
|
this.groupBox1.Controls.Add(this.label5);
|
||||||
this.groupBox1.Controls.Add(this.txtlocalPort);
|
this.groupBox1.Controls.Add(this.txtlocalPort);
|
||||||
this.groupBox1.Controls.Add(this.label2);
|
this.groupBox1.Controls.Add(this.label2);
|
||||||
|
resources.ApplyResources(this.groupBox1, "groupBox1");
|
||||||
this.groupBox1.Name = "groupBox1";
|
this.groupBox1.Name = "groupBox1";
|
||||||
this.groupBox1.TabStop = false;
|
this.groupBox1.TabStop = false;
|
||||||
//
|
//
|
||||||
@@ -216,8 +217,8 @@
|
|||||||
//
|
//
|
||||||
// cmbprotocol
|
// cmbprotocol
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.cmbprotocol, "cmbprotocol");
|
|
||||||
this.cmbprotocol.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
this.cmbprotocol.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||||
|
resources.ApplyResources(this.cmbprotocol, "cmbprotocol");
|
||||||
this.cmbprotocol.FormattingEnabled = true;
|
this.cmbprotocol.FormattingEnabled = true;
|
||||||
this.cmbprotocol.Items.AddRange(new object[] {
|
this.cmbprotocol.Items.AddRange(new object[] {
|
||||||
resources.GetString("cmbprotocol.Items"),
|
resources.GetString("cmbprotocol.Items"),
|
||||||
@@ -243,7 +244,6 @@
|
|||||||
//
|
//
|
||||||
// cmbloglevel
|
// cmbloglevel
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.cmbloglevel, "cmbloglevel");
|
|
||||||
this.cmbloglevel.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
this.cmbloglevel.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||||
this.cmbloglevel.FormattingEnabled = true;
|
this.cmbloglevel.FormattingEnabled = true;
|
||||||
this.cmbloglevel.Items.AddRange(new object[] {
|
this.cmbloglevel.Items.AddRange(new object[] {
|
||||||
@@ -252,6 +252,7 @@
|
|||||||
resources.GetString("cmbloglevel.Items2"),
|
resources.GetString("cmbloglevel.Items2"),
|
||||||
resources.GetString("cmbloglevel.Items3"),
|
resources.GetString("cmbloglevel.Items3"),
|
||||||
resources.GetString("cmbloglevel.Items4")});
|
resources.GetString("cmbloglevel.Items4")});
|
||||||
|
resources.ApplyResources(this.cmbloglevel, "cmbloglevel");
|
||||||
this.cmbloglevel.Name = "cmbloglevel";
|
this.cmbloglevel.Name = "cmbloglevel";
|
||||||
//
|
//
|
||||||
// label5
|
// label5
|
||||||
@@ -271,18 +272,17 @@
|
|||||||
//
|
//
|
||||||
// tabPage2
|
// tabPage2
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.tabPage2, "tabPage2");
|
|
||||||
this.tabPage2.Controls.Add(this.cmbdomainStrategy4Freedom);
|
this.tabPage2.Controls.Add(this.cmbdomainStrategy4Freedom);
|
||||||
this.tabPage2.Controls.Add(this.label19);
|
this.tabPage2.Controls.Add(this.label19);
|
||||||
this.tabPage2.Controls.Add(this.linkDnsObjectDoc);
|
this.tabPage2.Controls.Add(this.linkDnsObjectDoc);
|
||||||
this.tabPage2.Controls.Add(this.txtremoteDNS);
|
this.tabPage2.Controls.Add(this.txtremoteDNS);
|
||||||
this.tabPage2.Controls.Add(this.label14);
|
this.tabPage2.Controls.Add(this.label14);
|
||||||
|
resources.ApplyResources(this.tabPage2, "tabPage2");
|
||||||
this.tabPage2.Name = "tabPage2";
|
this.tabPage2.Name = "tabPage2";
|
||||||
this.tabPage2.UseVisualStyleBackColor = true;
|
this.tabPage2.UseVisualStyleBackColor = true;
|
||||||
//
|
//
|
||||||
// cmbdomainStrategy4Freedom
|
// cmbdomainStrategy4Freedom
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.cmbdomainStrategy4Freedom, "cmbdomainStrategy4Freedom");
|
|
||||||
this.cmbdomainStrategy4Freedom.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
this.cmbdomainStrategy4Freedom.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||||
this.cmbdomainStrategy4Freedom.FormattingEnabled = true;
|
this.cmbdomainStrategy4Freedom.FormattingEnabled = true;
|
||||||
this.cmbdomainStrategy4Freedom.Items.AddRange(new object[] {
|
this.cmbdomainStrategy4Freedom.Items.AddRange(new object[] {
|
||||||
@@ -290,6 +290,7 @@
|
|||||||
resources.GetString("cmbdomainStrategy4Freedom.Items1"),
|
resources.GetString("cmbdomainStrategy4Freedom.Items1"),
|
||||||
resources.GetString("cmbdomainStrategy4Freedom.Items2"),
|
resources.GetString("cmbdomainStrategy4Freedom.Items2"),
|
||||||
resources.GetString("cmbdomainStrategy4Freedom.Items3")});
|
resources.GetString("cmbdomainStrategy4Freedom.Items3")});
|
||||||
|
resources.ApplyResources(this.cmbdomainStrategy4Freedom, "cmbdomainStrategy4Freedom");
|
||||||
this.cmbdomainStrategy4Freedom.Name = "cmbdomainStrategy4Freedom";
|
this.cmbdomainStrategy4Freedom.Name = "cmbdomainStrategy4Freedom";
|
||||||
//
|
//
|
||||||
// label19
|
// label19
|
||||||
@@ -316,7 +317,6 @@
|
|||||||
//
|
//
|
||||||
// tabPage6
|
// tabPage6
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.tabPage6, "tabPage6");
|
|
||||||
this.tabPage6.Controls.Add(this.chkKcpcongestion);
|
this.tabPage6.Controls.Add(this.chkKcpcongestion);
|
||||||
this.tabPage6.Controls.Add(this.txtKcpwriteBufferSize);
|
this.tabPage6.Controls.Add(this.txtKcpwriteBufferSize);
|
||||||
this.tabPage6.Controls.Add(this.label10);
|
this.tabPage6.Controls.Add(this.label10);
|
||||||
@@ -330,6 +330,7 @@
|
|||||||
this.tabPage6.Controls.Add(this.label7);
|
this.tabPage6.Controls.Add(this.label7);
|
||||||
this.tabPage6.Controls.Add(this.txtKcpmtu);
|
this.tabPage6.Controls.Add(this.txtKcpmtu);
|
||||||
this.tabPage6.Controls.Add(this.label6);
|
this.tabPage6.Controls.Add(this.label6);
|
||||||
|
resources.ApplyResources(this.tabPage6, "tabPage6");
|
||||||
this.tabPage6.Name = "tabPage6";
|
this.tabPage6.Name = "tabPage6";
|
||||||
this.tabPage6.UseVisualStyleBackColor = true;
|
this.tabPage6.UseVisualStyleBackColor = true;
|
||||||
//
|
//
|
||||||
@@ -401,7 +402,7 @@
|
|||||||
//
|
//
|
||||||
// tabPage7
|
// tabPage7
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.tabPage7, "tabPage7");
|
this.tabPage7.Controls.Add(this.chkEnableCheckPreReleaseUpdate);
|
||||||
this.tabPage7.Controls.Add(this.numStatisticsFreshRate);
|
this.tabPage7.Controls.Add(this.numStatisticsFreshRate);
|
||||||
this.tabPage7.Controls.Add(this.txttrayMenuServersLimit);
|
this.tabPage7.Controls.Add(this.txttrayMenuServersLimit);
|
||||||
this.tabPage7.Controls.Add(this.label17);
|
this.tabPage7.Controls.Add(this.label17);
|
||||||
@@ -417,6 +418,7 @@
|
|||||||
this.tabPage7.Controls.Add(this.lbFreshrate);
|
this.tabPage7.Controls.Add(this.lbFreshrate);
|
||||||
this.tabPage7.Controls.Add(this.chkEnableStatistics);
|
this.tabPage7.Controls.Add(this.chkEnableStatistics);
|
||||||
this.tabPage7.Controls.Add(this.chkAutoRun);
|
this.tabPage7.Controls.Add(this.chkAutoRun);
|
||||||
|
resources.ApplyResources(this.tabPage7, "tabPage7");
|
||||||
this.tabPage7.Name = "tabPage7";
|
this.tabPage7.Name = "tabPage7";
|
||||||
this.tabPage7.UseVisualStyleBackColor = true;
|
this.tabPage7.UseVisualStyleBackColor = true;
|
||||||
//
|
//
|
||||||
@@ -505,7 +507,6 @@
|
|||||||
//
|
//
|
||||||
// tabPageCoreType
|
// tabPageCoreType
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.tabPageCoreType, "tabPageCoreType");
|
|
||||||
this.tabPageCoreType.Controls.Add(this.cmbCoreType6);
|
this.tabPageCoreType.Controls.Add(this.cmbCoreType6);
|
||||||
this.tabPageCoreType.Controls.Add(this.labCoreType6);
|
this.tabPageCoreType.Controls.Add(this.labCoreType6);
|
||||||
this.tabPageCoreType.Controls.Add(this.cmbCoreType5);
|
this.tabPageCoreType.Controls.Add(this.cmbCoreType5);
|
||||||
@@ -518,14 +519,15 @@
|
|||||||
this.tabPageCoreType.Controls.Add(this.labCoreType2);
|
this.tabPageCoreType.Controls.Add(this.labCoreType2);
|
||||||
this.tabPageCoreType.Controls.Add(this.cmbCoreType1);
|
this.tabPageCoreType.Controls.Add(this.cmbCoreType1);
|
||||||
this.tabPageCoreType.Controls.Add(this.labCoreType1);
|
this.tabPageCoreType.Controls.Add(this.labCoreType1);
|
||||||
|
resources.ApplyResources(this.tabPageCoreType, "tabPageCoreType");
|
||||||
this.tabPageCoreType.Name = "tabPageCoreType";
|
this.tabPageCoreType.Name = "tabPageCoreType";
|
||||||
this.tabPageCoreType.UseVisualStyleBackColor = true;
|
this.tabPageCoreType.UseVisualStyleBackColor = true;
|
||||||
//
|
//
|
||||||
// cmbCoreType6
|
// cmbCoreType6
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.cmbCoreType6, "cmbCoreType6");
|
|
||||||
this.cmbCoreType6.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
this.cmbCoreType6.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||||
this.cmbCoreType6.FormattingEnabled = true;
|
this.cmbCoreType6.FormattingEnabled = true;
|
||||||
|
resources.ApplyResources(this.cmbCoreType6, "cmbCoreType6");
|
||||||
this.cmbCoreType6.Name = "cmbCoreType6";
|
this.cmbCoreType6.Name = "cmbCoreType6";
|
||||||
//
|
//
|
||||||
// labCoreType6
|
// labCoreType6
|
||||||
@@ -535,9 +537,9 @@
|
|||||||
//
|
//
|
||||||
// cmbCoreType5
|
// cmbCoreType5
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.cmbCoreType5, "cmbCoreType5");
|
|
||||||
this.cmbCoreType5.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
this.cmbCoreType5.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||||
this.cmbCoreType5.FormattingEnabled = true;
|
this.cmbCoreType5.FormattingEnabled = true;
|
||||||
|
resources.ApplyResources(this.cmbCoreType5, "cmbCoreType5");
|
||||||
this.cmbCoreType5.Name = "cmbCoreType5";
|
this.cmbCoreType5.Name = "cmbCoreType5";
|
||||||
//
|
//
|
||||||
// labCoreType5
|
// labCoreType5
|
||||||
@@ -547,9 +549,9 @@
|
|||||||
//
|
//
|
||||||
// cmbCoreType4
|
// cmbCoreType4
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.cmbCoreType4, "cmbCoreType4");
|
|
||||||
this.cmbCoreType4.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
this.cmbCoreType4.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||||
this.cmbCoreType4.FormattingEnabled = true;
|
this.cmbCoreType4.FormattingEnabled = true;
|
||||||
|
resources.ApplyResources(this.cmbCoreType4, "cmbCoreType4");
|
||||||
this.cmbCoreType4.Name = "cmbCoreType4";
|
this.cmbCoreType4.Name = "cmbCoreType4";
|
||||||
//
|
//
|
||||||
// labCoreType4
|
// labCoreType4
|
||||||
@@ -559,9 +561,9 @@
|
|||||||
//
|
//
|
||||||
// cmbCoreType3
|
// cmbCoreType3
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.cmbCoreType3, "cmbCoreType3");
|
|
||||||
this.cmbCoreType3.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
this.cmbCoreType3.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||||
this.cmbCoreType3.FormattingEnabled = true;
|
this.cmbCoreType3.FormattingEnabled = true;
|
||||||
|
resources.ApplyResources(this.cmbCoreType3, "cmbCoreType3");
|
||||||
this.cmbCoreType3.Name = "cmbCoreType3";
|
this.cmbCoreType3.Name = "cmbCoreType3";
|
||||||
//
|
//
|
||||||
// labCoreType3
|
// labCoreType3
|
||||||
@@ -571,9 +573,9 @@
|
|||||||
//
|
//
|
||||||
// cmbCoreType2
|
// cmbCoreType2
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.cmbCoreType2, "cmbCoreType2");
|
|
||||||
this.cmbCoreType2.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
this.cmbCoreType2.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||||
this.cmbCoreType2.FormattingEnabled = true;
|
this.cmbCoreType2.FormattingEnabled = true;
|
||||||
|
resources.ApplyResources(this.cmbCoreType2, "cmbCoreType2");
|
||||||
this.cmbCoreType2.Name = "cmbCoreType2";
|
this.cmbCoreType2.Name = "cmbCoreType2";
|
||||||
//
|
//
|
||||||
// labCoreType2
|
// labCoreType2
|
||||||
@@ -583,9 +585,9 @@
|
|||||||
//
|
//
|
||||||
// cmbCoreType1
|
// cmbCoreType1
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.cmbCoreType1, "cmbCoreType1");
|
|
||||||
this.cmbCoreType1.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
this.cmbCoreType1.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
|
||||||
this.cmbCoreType1.FormattingEnabled = true;
|
this.cmbCoreType1.FormattingEnabled = true;
|
||||||
|
resources.ApplyResources(this.cmbCoreType1, "cmbCoreType1");
|
||||||
this.cmbCoreType1.Name = "cmbCoreType1";
|
this.cmbCoreType1.Name = "cmbCoreType1";
|
||||||
//
|
//
|
||||||
// labCoreType1
|
// labCoreType1
|
||||||
@@ -595,19 +597,19 @@
|
|||||||
//
|
//
|
||||||
// tabPage3
|
// tabPage3
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.tabPage3, "tabPage3");
|
|
||||||
this.tabPage3.Controls.Add(this.groupBox2);
|
this.tabPage3.Controls.Add(this.groupBox2);
|
||||||
|
resources.ApplyResources(this.tabPage3, "tabPage3");
|
||||||
this.tabPage3.Name = "tabPage3";
|
this.tabPage3.Name = "tabPage3";
|
||||||
this.tabPage3.UseVisualStyleBackColor = true;
|
this.tabPage3.UseVisualStyleBackColor = true;
|
||||||
//
|
//
|
||||||
// groupBox2
|
// groupBox2
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.groupBox2, "groupBox2");
|
|
||||||
this.groupBox2.Controls.Add(this.label18);
|
this.groupBox2.Controls.Add(this.label18);
|
||||||
this.groupBox2.Controls.Add(this.cmbSystemProxyAdvancedProtocol);
|
this.groupBox2.Controls.Add(this.cmbSystemProxyAdvancedProtocol);
|
||||||
this.groupBox2.Controls.Add(this.label13);
|
this.groupBox2.Controls.Add(this.label13);
|
||||||
this.groupBox2.Controls.Add(this.label12);
|
this.groupBox2.Controls.Add(this.label12);
|
||||||
this.groupBox2.Controls.Add(this.txtsystemProxyExceptions);
|
this.groupBox2.Controls.Add(this.txtsystemProxyExceptions);
|
||||||
|
resources.ApplyResources(this.groupBox2, "groupBox2");
|
||||||
this.groupBox2.Name = "groupBox2";
|
this.groupBox2.Name = "groupBox2";
|
||||||
this.groupBox2.TabStop = false;
|
this.groupBox2.TabStop = false;
|
||||||
//
|
//
|
||||||
@@ -618,8 +620,8 @@
|
|||||||
//
|
//
|
||||||
// cmbSystemProxyAdvancedProtocol
|
// cmbSystemProxyAdvancedProtocol
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.cmbSystemProxyAdvancedProtocol, "cmbSystemProxyAdvancedProtocol");
|
|
||||||
this.cmbSystemProxyAdvancedProtocol.FormattingEnabled = true;
|
this.cmbSystemProxyAdvancedProtocol.FormattingEnabled = true;
|
||||||
|
resources.ApplyResources(this.cmbSystemProxyAdvancedProtocol, "cmbSystemProxyAdvancedProtocol");
|
||||||
this.cmbSystemProxyAdvancedProtocol.Name = "cmbSystemProxyAdvancedProtocol";
|
this.cmbSystemProxyAdvancedProtocol.Name = "cmbSystemProxyAdvancedProtocol";
|
||||||
//
|
//
|
||||||
// label13
|
// label13
|
||||||
@@ -639,9 +641,9 @@
|
|||||||
//
|
//
|
||||||
// panel2
|
// panel2
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this.panel2, "panel2");
|
|
||||||
this.panel2.Controls.Add(this.btnClose);
|
this.panel2.Controls.Add(this.btnClose);
|
||||||
this.panel2.Controls.Add(this.btnOK);
|
this.panel2.Controls.Add(this.btnOK);
|
||||||
|
resources.ApplyResources(this.panel2, "panel2");
|
||||||
this.panel2.Name = "panel2";
|
this.panel2.Name = "panel2";
|
||||||
//
|
//
|
||||||
// btnOK
|
// btnOK
|
||||||
@@ -656,6 +658,12 @@
|
|||||||
resources.ApplyResources(this.panel1, "panel1");
|
resources.ApplyResources(this.panel1, "panel1");
|
||||||
this.panel1.Name = "panel1";
|
this.panel1.Name = "panel1";
|
||||||
//
|
//
|
||||||
|
// chkEnableCheckPreReleaseUpdate
|
||||||
|
//
|
||||||
|
resources.ApplyResources(this.chkEnableCheckPreReleaseUpdate, "chkEnableCheckPreReleaseUpdate");
|
||||||
|
this.chkEnableCheckPreReleaseUpdate.Name = "chkEnableCheckPreReleaseUpdate";
|
||||||
|
this.chkEnableCheckPreReleaseUpdate.UseVisualStyleBackColor = true;
|
||||||
|
//
|
||||||
// OptionSettingForm
|
// OptionSettingForm
|
||||||
//
|
//
|
||||||
resources.ApplyResources(this, "$this");
|
resources.ApplyResources(this, "$this");
|
||||||
@@ -769,5 +777,6 @@
|
|||||||
private System.Windows.Forms.NumericUpDown numStatisticsFreshRate;
|
private System.Windows.Forms.NumericUpDown numStatisticsFreshRate;
|
||||||
private System.Windows.Forms.ComboBox cmbdomainStrategy4Freedom;
|
private System.Windows.Forms.ComboBox cmbdomainStrategy4Freedom;
|
||||||
private System.Windows.Forms.Label label19;
|
private System.Windows.Forms.Label label19;
|
||||||
|
private System.Windows.Forms.CheckBox chkEnableCheckPreReleaseUpdate;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -98,6 +98,7 @@ namespace v2rayN.Forms
|
|||||||
|
|
||||||
txtautoUpdateInterval.Text = config.autoUpdateInterval.ToString();
|
txtautoUpdateInterval.Text = config.autoUpdateInterval.ToString();
|
||||||
txtautoUpdateSubInterval.Text = config.autoUpdateSubInterval.ToString();
|
txtautoUpdateSubInterval.Text = config.autoUpdateSubInterval.ToString();
|
||||||
|
chkEnableCheckPreReleaseUpdate.Checked = config.checkPreReleaseUpdate;
|
||||||
txttrayMenuServersLimit.Text = config.trayMenuServersLimit.ToString();
|
txttrayMenuServersLimit.Text = config.trayMenuServersLimit.ToString();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -298,6 +299,7 @@ namespace v2rayN.Forms
|
|||||||
|
|
||||||
config.autoUpdateInterval = Utils.ToInt(txtautoUpdateInterval.Text);
|
config.autoUpdateInterval = Utils.ToInt(txtautoUpdateInterval.Text);
|
||||||
config.autoUpdateSubInterval = Utils.ToInt(txtautoUpdateSubInterval.Text);
|
config.autoUpdateSubInterval = Utils.ToInt(txtautoUpdateSubInterval.Text);
|
||||||
|
config.checkPreReleaseUpdate = chkEnableCheckPreReleaseUpdate.Checked;
|
||||||
config.trayMenuServersLimit = Utils.ToInt(txttrayMenuServersLimit.Text);
|
config.trayMenuServersLimit = Utils.ToInt(txttrayMenuServersLimit.Text);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@@ -388,4 +388,7 @@
|
|||||||
<data name="$this.Text" xml:space="preserve">
|
<data name="$this.Text" xml:space="preserve">
|
||||||
<value>参数设置</value>
|
<value>参数设置</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="chkEnableCheckPreReleaseUpdate.Text" xml:space="preserve">
|
||||||
|
<value>检查Pre-Release更新(请谨慎启用)</value>
|
||||||
|
</data>
|
||||||
</root>
|
</root>
|
||||||
@@ -170,7 +170,7 @@ namespace v2rayN.Forms
|
|||||||
string def = string.Empty;
|
string def = string.Empty;
|
||||||
if (config.routingIndex.Equals(k))
|
if (config.routingIndex.Equals(k))
|
||||||
{
|
{
|
||||||
def = "√";
|
def = Global.CheckMark;
|
||||||
}
|
}
|
||||||
|
|
||||||
ListViewItem lvItem = new ListViewItem(def);
|
ListViewItem lvItem = new ListViewItem(def);
|
||||||
|
|||||||
@@ -217,6 +217,7 @@ namespace v2rayN
|
|||||||
public static readonly List<string> domainMatchers = new List<string> { "linear", "mph", "" };
|
public static readonly List<string> domainMatchers = new List<string> { "linear", "mph", "" };
|
||||||
public const string GrpcgunMode = "gun";
|
public const string GrpcgunMode = "gun";
|
||||||
public const string GrpcmultiMode = "multi";
|
public const string GrpcmultiMode = "multi";
|
||||||
|
public const string CheckMark = "√";
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|||||||
@@ -72,7 +72,7 @@ namespace v2rayN.Handler
|
|||||||
{
|
{
|
||||||
coreType = ECoreType.v2rayN,
|
coreType = ECoreType.v2rayN,
|
||||||
coreUrl = Global.NUrl,
|
coreUrl = Global.NUrl,
|
||||||
coreLatestUrl = Global.NUrl + "/latest",
|
coreReleaseApiUrl = Global.NUrl.Replace(@"https://github.com", @"https://api.github.com/repos"),
|
||||||
coreDownloadUrl32 = Global.NUrl + "/download/{0}/v2rayN.zip",
|
coreDownloadUrl32 = Global.NUrl + "/download/{0}/v2rayN.zip",
|
||||||
coreDownloadUrl64 = Global.NUrl + "/download/{0}/v2rayN.zip",
|
coreDownloadUrl64 = Global.NUrl + "/download/{0}/v2rayN.zip",
|
||||||
});
|
});
|
||||||
@@ -83,7 +83,7 @@ namespace v2rayN.Handler
|
|||||||
coreExes = new List<string> { "wv2ray", "v2ray" },
|
coreExes = new List<string> { "wv2ray", "v2ray" },
|
||||||
arguments = "",
|
arguments = "",
|
||||||
coreUrl = Global.v2flyCoreUrl,
|
coreUrl = Global.v2flyCoreUrl,
|
||||||
coreLatestUrl = Global.v2flyCoreUrl + "/latest",
|
coreReleaseApiUrl = Global.v2flyCoreUrl.Replace(@"https://github.com", @"https://api.github.com/repos"),
|
||||||
coreDownloadUrl32 = Global.v2flyCoreUrl + "/download/{0}/v2ray-windows-{1}.zip",
|
coreDownloadUrl32 = Global.v2flyCoreUrl + "/download/{0}/v2ray-windows-{1}.zip",
|
||||||
coreDownloadUrl64 = Global.v2flyCoreUrl + "/download/{0}/v2ray-windows-{1}.zip",
|
coreDownloadUrl64 = Global.v2flyCoreUrl + "/download/{0}/v2ray-windows-{1}.zip",
|
||||||
match = "V2Ray",
|
match = "V2Ray",
|
||||||
@@ -96,7 +96,7 @@ namespace v2rayN.Handler
|
|||||||
coreExes = new List<string> { "v2ray" },
|
coreExes = new List<string> { "v2ray" },
|
||||||
arguments = "run",
|
arguments = "run",
|
||||||
coreUrl = Global.SagerNetCoreUrl,
|
coreUrl = Global.SagerNetCoreUrl,
|
||||||
coreLatestUrl = Global.SagerNetCoreUrl + "/latest",
|
coreReleaseApiUrl = Global.SagerNetCoreUrl.Replace(@"https://github.com", @"https://api.github.com/repos"),
|
||||||
coreDownloadUrl32 = Global.SagerNetCoreUrl + "/download/{0}/v2ray-windows-{1}.zip",
|
coreDownloadUrl32 = Global.SagerNetCoreUrl + "/download/{0}/v2ray-windows-{1}.zip",
|
||||||
coreDownloadUrl64 = Global.SagerNetCoreUrl + "/download/{0}/v2ray-windows-{1}.zip",
|
coreDownloadUrl64 = Global.SagerNetCoreUrl + "/download/{0}/v2ray-windows-{1}.zip",
|
||||||
match = "V2Ray",
|
match = "V2Ray",
|
||||||
@@ -109,7 +109,7 @@ namespace v2rayN.Handler
|
|||||||
coreExes = new List<string> { "xray" },
|
coreExes = new List<string> { "xray" },
|
||||||
arguments = "",
|
arguments = "",
|
||||||
coreUrl = Global.xrayCoreUrl,
|
coreUrl = Global.xrayCoreUrl,
|
||||||
coreLatestUrl = Global.xrayCoreUrl + "/latest",
|
coreReleaseApiUrl = Global.xrayCoreUrl.Replace(@"https://github.com", @"https://api.github.com/repos"),
|
||||||
coreDownloadUrl32 = Global.xrayCoreUrl + "/download/{0}/Xray-windows-{1}.zip",
|
coreDownloadUrl32 = Global.xrayCoreUrl + "/download/{0}/Xray-windows-{1}.zip",
|
||||||
coreDownloadUrl64 = Global.xrayCoreUrl + "/download/{0}/Xray-windows-{1}.zip",
|
coreDownloadUrl64 = Global.xrayCoreUrl + "/download/{0}/Xray-windows-{1}.zip",
|
||||||
match = "Xray",
|
match = "Xray",
|
||||||
@@ -122,7 +122,7 @@ namespace v2rayN.Handler
|
|||||||
coreExes = new List<string> { "clash-windows-amd64-v3", "clash-windows-amd64", "clash-windows-386", "clash" },
|
coreExes = new List<string> { "clash-windows-amd64-v3", "clash-windows-amd64", "clash-windows-386", "clash" },
|
||||||
arguments = "-f config.json",
|
arguments = "-f config.json",
|
||||||
coreUrl = Global.clashCoreUrl,
|
coreUrl = Global.clashCoreUrl,
|
||||||
coreLatestUrl = Global.clashCoreUrl + "/latest",
|
coreReleaseApiUrl = Global.clashCoreUrl.Replace(@"https://github.com", @"https://api.github.com/repos"),
|
||||||
coreDownloadUrl32 = Global.clashCoreUrl + "/download/{0}/clash-windows-386-{0}.zip",
|
coreDownloadUrl32 = Global.clashCoreUrl + "/download/{0}/clash-windows-386-{0}.zip",
|
||||||
coreDownloadUrl64 = Global.clashCoreUrl + "/download/{0}/clash-windows-amd64-{0}.zip",
|
coreDownloadUrl64 = Global.clashCoreUrl + "/download/{0}/clash-windows-amd64-{0}.zip",
|
||||||
match = "v",
|
match = "v",
|
||||||
@@ -135,7 +135,7 @@ namespace v2rayN.Handler
|
|||||||
coreExes = new List<string> { "Clash.Meta-windows-amd64-compatible", "Clash.Meta-windows-amd64", "Clash.Meta-windows-386", "Clash.Meta", "clash" },
|
coreExes = new List<string> { "Clash.Meta-windows-amd64-compatible", "Clash.Meta-windows-amd64", "Clash.Meta-windows-386", "Clash.Meta", "clash" },
|
||||||
arguments = "-f config.json",
|
arguments = "-f config.json",
|
||||||
coreUrl = Global.clashMetaCoreUrl,
|
coreUrl = Global.clashMetaCoreUrl,
|
||||||
coreLatestUrl = Global.clashMetaCoreUrl + "/latest",
|
coreReleaseApiUrl = Global.clashMetaCoreUrl.Replace(@"https://github.com", @"https://api.github.com/repos"),
|
||||||
coreDownloadUrl32 = Global.clashMetaCoreUrl + "/download/{0}/Clash.Meta-windows-386-{0}.zip",
|
coreDownloadUrl32 = Global.clashMetaCoreUrl + "/download/{0}/Clash.Meta-windows-386-{0}.zip",
|
||||||
coreDownloadUrl64 = Global.clashMetaCoreUrl + "/download/{0}/Clash.Meta-windows-amd64-compatible-{0}.zip",
|
coreDownloadUrl64 = Global.clashMetaCoreUrl + "/download/{0}/Clash.Meta-windows-amd64-compatible-{0}.zip",
|
||||||
match = "v",
|
match = "v",
|
||||||
@@ -148,7 +148,7 @@ namespace v2rayN.Handler
|
|||||||
coreExes = new List<string> { "hysteria-tun-windows-6.0-amd64", "hysteria-tun-windows-6.0-386", "hysteria" },
|
coreExes = new List<string> { "hysteria-tun-windows-6.0-amd64", "hysteria-tun-windows-6.0-386", "hysteria" },
|
||||||
arguments = "",
|
arguments = "",
|
||||||
coreUrl = Global.hysteriaCoreUrl,
|
coreUrl = Global.hysteriaCoreUrl,
|
||||||
coreLatestUrl = Global.hysteriaCoreUrl + "/latest",
|
coreReleaseApiUrl = Global.hysteriaCoreUrl.Replace(@"https://github.com", @"https://api.github.com/repos"),
|
||||||
coreDownloadUrl32 = Global.hysteriaCoreUrl + "/download/{0}/hysteria-tun-windows-6.0-386.exe",
|
coreDownloadUrl32 = Global.hysteriaCoreUrl + "/download/{0}/hysteria-tun-windows-6.0-386.exe",
|
||||||
coreDownloadUrl64 = Global.hysteriaCoreUrl + "/download/{0}/hysteria-tun-windows-6.0-amd64.exe",
|
coreDownloadUrl64 = Global.hysteriaCoreUrl + "/download/{0}/hysteria-tun-windows-6.0-amd64.exe",
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -254,7 +254,7 @@ namespace v2rayN.Handler
|
|||||||
{
|
{
|
||||||
if ((dtNow - autoUpdateSubTime).Hours % config.autoUpdateSubInterval == 0)
|
if ((dtNow - autoUpdateSubTime).Hours % config.autoUpdateSubInterval == 0)
|
||||||
{
|
{
|
||||||
updateHandle.UpdateSubscriptionProcess(config, true, (bool success, string msg) =>
|
updateHandle.UpdateSubscriptionProcess(config, "", true, (bool success, string msg) =>
|
||||||
{
|
{
|
||||||
update(success, msg);
|
update(success, msg);
|
||||||
if (success)
|
if (success)
|
||||||
|
|||||||
@@ -1,11 +1,14 @@
|
|||||||
using System;
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
|
using System.Linq;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Text.RegularExpressions;
|
using System.Text.RegularExpressions;
|
||||||
using System.Threading;
|
using System.Threading;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
using Newtonsoft.Json;
|
||||||
using v2rayN.Base;
|
using v2rayN.Base;
|
||||||
using v2rayN.Mode;
|
using v2rayN.Mode;
|
||||||
using v2rayN.Resx;
|
using v2rayN.Resx;
|
||||||
@@ -31,7 +34,7 @@ namespace v2rayN.Handler
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void CheckUpdateGuiN(Config config, Action<bool, string> update)
|
public void CheckUpdateGuiN(Config config, Action<bool, string> update, bool preRelease)
|
||||||
{
|
{
|
||||||
_config = config;
|
_config = config;
|
||||||
_updateFunc = update;
|
_updateFunc = update;
|
||||||
@@ -97,11 +100,11 @@ namespace v2rayN.Handler
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
_updateFunc(false, string.Format(ResUI.MsgStartUpdating, "v2rayN"));
|
_updateFunc(false, string.Format(ResUI.MsgStartUpdating, "v2rayN"));
|
||||||
CheckUpdateAsync(ECoreType.v2rayN);
|
CheckUpdateAsync(ECoreType.v2rayN, preRelease);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public void CheckUpdateCore(ECoreType type, Config config, Action<bool, string> update)
|
public void CheckUpdateCore(ECoreType type, Config config, Action<bool, string> update, bool preRelease)
|
||||||
{
|
{
|
||||||
_config = config;
|
_config = config;
|
||||||
_updateFunc = update;
|
_updateFunc = update;
|
||||||
@@ -152,11 +155,11 @@ namespace v2rayN.Handler
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
_updateFunc(false, string.Format(ResUI.MsgStartUpdating, "Core"));
|
_updateFunc(false, string.Format(ResUI.MsgStartUpdating, "Core"));
|
||||||
CheckUpdateAsync(type);
|
CheckUpdateAsync(type, preRelease);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public void UpdateSubscriptionProcess(Config config, bool blProxy, Action<bool, string> update)
|
public void UpdateSubscriptionProcess(Config config, string groupId, bool blProxy, Action<bool, string> update)
|
||||||
{
|
{
|
||||||
_config = config;
|
_config = config;
|
||||||
_updateFunc = update;
|
_updateFunc = update;
|
||||||
@@ -187,10 +190,15 @@ namespace v2rayN.Handler
|
|||||||
{
|
{
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
if (!Utils.IsNullOrEmpty(groupId) && item.groupId != groupId)
|
||||||
|
{
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
string id = item.id.TrimEx();
|
string id = item.id.TrimEx();
|
||||||
string url = item.url.TrimEx();
|
string url = item.url.TrimEx();
|
||||||
string userAgent = item.userAgent.TrimEx();
|
string userAgent = item.userAgent.TrimEx();
|
||||||
string groupId = item.groupId.TrimEx();
|
//string groupId = item.groupId.TrimEx();
|
||||||
string hashCode = $"{item.remarks}->";
|
string hashCode = $"{item.remarks}->";
|
||||||
if (Utils.IsNullOrEmpty(id) || Utils.IsNullOrEmpty(url))
|
if (Utils.IsNullOrEmpty(id) || Utils.IsNullOrEmpty(url))
|
||||||
{
|
{
|
||||||
@@ -223,7 +231,7 @@ namespace v2rayN.Handler
|
|||||||
_updateFunc(false, $"{hashCode}{result}");
|
_updateFunc(false, $"{hashCode}{result}");
|
||||||
}
|
}
|
||||||
|
|
||||||
int ret = ConfigHandler.AddBatchServers(ref config, result, id, groupId);
|
int ret = ConfigHandler.AddBatchServers(ref config, result, id, item.groupId.TrimEx());
|
||||||
_updateFunc(false,
|
_updateFunc(false,
|
||||||
ret > 0
|
ret > 0
|
||||||
? $"{hashCode}{ResUI.MsgUpdateSubscriptionEnd}"
|
? $"{hashCode}{ResUI.MsgUpdateSubscriptionEnd}"
|
||||||
@@ -305,17 +313,17 @@ namespace v2rayN.Handler
|
|||||||
|
|
||||||
#region private
|
#region private
|
||||||
|
|
||||||
private async void CheckUpdateAsync(ECoreType type)
|
private async void CheckUpdateAsync(ECoreType type, bool preRelease)
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
var coreInfo = LazyConfig.Instance.GetCoreInfo(type);
|
var coreInfo = LazyConfig.Instance.GetCoreInfo(type);
|
||||||
string url = coreInfo.coreLatestUrl;
|
string url = coreInfo.coreReleaseApiUrl;
|
||||||
|
|
||||||
var result = await (new DownloadHandle()).UrlRedirectAsync(url, true);
|
var result = await (new DownloadHandle()).DownloadStringAsync(url, true, "");
|
||||||
if (!Utils.IsNullOrEmpty(result))
|
if (!Utils.IsNullOrEmpty(result))
|
||||||
{
|
{
|
||||||
responseHandler(type, result);
|
responseHandler(type, result, preRelease);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -391,11 +399,20 @@ namespace v2rayN.Handler
|
|||||||
return "";
|
return "";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
private void responseHandler(ECoreType type, string redirectUrl)
|
private void responseHandler(ECoreType type, string gitHubReleaseApi, bool preRelease)
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
string version = redirectUrl.Substring(redirectUrl.LastIndexOf("/", StringComparison.Ordinal) + 1);
|
var gitHubReleases = Utils.FromJson<List<GitHubRelease>>(gitHubReleaseApi);
|
||||||
|
string version;
|
||||||
|
if (preRelease)
|
||||||
|
{
|
||||||
|
version = gitHubReleases!.First().TagName;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
version = gitHubReleases!.First(r => r.Prerelease == false).TagName;
|
||||||
|
}
|
||||||
var coreInfo = LazyConfig.Instance.GetCoreInfo(type);
|
var coreInfo = LazyConfig.Instance.GetCoreInfo(type);
|
||||||
|
|
||||||
string curVersion;
|
string curVersion;
|
||||||
|
|||||||
@@ -137,6 +137,8 @@ namespace v2rayN.Mode
|
|||||||
public int autoUpdateInterval { get; set; } = 0;
|
public int autoUpdateInterval { get; set; } = 0;
|
||||||
|
|
||||||
public int autoUpdateSubInterval { get; set; } = 0;
|
public int autoUpdateSubInterval { get; set; } = 0;
|
||||||
|
|
||||||
|
public bool checkPreReleaseUpdate { get; set; } = false;
|
||||||
|
|
||||||
public bool enableSecurityProtocolTls13
|
public bool enableSecurityProtocolTls13
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ namespace v2rayN.Mode
|
|||||||
|
|
||||||
public string coreUrl { get; set; }
|
public string coreUrl { get; set; }
|
||||||
|
|
||||||
public string coreLatestUrl { get; set; }
|
public string coreReleaseApiUrl { get; set; }
|
||||||
|
|
||||||
public string coreDownloadUrl32 { get; set; }
|
public string coreDownloadUrl32 { get; set; }
|
||||||
|
|
||||||
|
|||||||
70
v2rayN/v2rayN/Mode/GitHubRelease.cs
Normal file
70
v2rayN/v2rayN/Mode/GitHubRelease.cs
Normal file
@@ -0,0 +1,70 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using Newtonsoft.Json;
|
||||||
|
|
||||||
|
namespace v2rayN.Mode
|
||||||
|
{
|
||||||
|
public class GitHubReleaseAsset
|
||||||
|
{
|
||||||
|
[JsonProperty("url")] public string Url { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("id")] public int Id { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("node_id")] public string NodeId { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("name")] public string Name { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("label")] public object Label { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("content_type")] public string ContentType { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("state")] public string State { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("size")] public int Size { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("download_count")] public int DownloadCount { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("created_at")] public DateTime CreatedAt { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("updated_at")] public DateTime UpdatedAt { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("browser_download_url")] public string BrowserDownloadUrl { get; set; }
|
||||||
|
}
|
||||||
|
|
||||||
|
public class GitHubRelease
|
||||||
|
{
|
||||||
|
[JsonProperty("url")] public string Url { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("assets_url")] public string AssetsUrl { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("upload_url")] public string UploadUrl { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("html_url")] public string HtmlUrl { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("id")] public int Id { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("node_id")] public string NodeId { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("tag_name")] public string TagName { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("target_commitish")] public string TargetCommitish { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("name")] public string Name { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("draft")] public bool Draft { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("prerelease")] public bool Prerelease { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("created_at")] public DateTime CreatedAt { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("published_at")] public DateTime PublishedAt { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("assets")] public List<GitHubReleaseAsset> Assets { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("tarball_url")] public string TarballUrl { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("zipball_url")] public string ZipballUrl { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("body")] public string Body { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -32,4 +32,4 @@ using System.Runtime.InteropServices;
|
|||||||
// 方法是按如下所示使用“*”:
|
// 方法是按如下所示使用“*”:
|
||||||
//[assembly: AssemblyVersion("1.0.*")]
|
//[assembly: AssemblyVersion("1.0.*")]
|
||||||
//[assembly: AssemblyVersion("1.0.0")]
|
//[assembly: AssemblyVersion("1.0.0")]
|
||||||
[assembly: AssemblyFileVersion("5.31")]
|
[assembly: AssemblyFileVersion("5.32")]
|
||||||
|
|||||||
@@ -707,6 +707,13 @@ namespace v2rayN
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static string MainMsgFilterKey
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
return $"MainMsgFilter_{GetMD5(StartupPath())}";
|
||||||
|
}
|
||||||
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region 测速
|
#region 测速
|
||||||
|
|||||||
@@ -2,6 +2,7 @@
|
|||||||
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
|
<LangVersion>preview</LangVersion>
|
||||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||||
<ProjectGuid>{0A9785E6-D256-4B73-9757-4EF59955FD1E}</ProjectGuid>
|
<ProjectGuid>{0A9785E6-D256-4B73-9757-4EF59955FD1E}</ProjectGuid>
|
||||||
@@ -209,6 +210,7 @@
|
|||||||
<Compile Include="Mode\ESysProxyType.cs" />
|
<Compile Include="Mode\ESysProxyType.cs" />
|
||||||
<Compile Include="Mode\EMove.cs" />
|
<Compile Include="Mode\EMove.cs" />
|
||||||
<Compile Include="Mode\EServerColName.cs" />
|
<Compile Include="Mode\EServerColName.cs" />
|
||||||
|
<Compile Include="Mode\GitHubRelease.cs" />
|
||||||
<Compile Include="Mode\RoutingItem.cs" />
|
<Compile Include="Mode\RoutingItem.cs" />
|
||||||
<Compile Include="Mode\RulesItem.cs" />
|
<Compile Include="Mode\RulesItem.cs" />
|
||||||
<Compile Include="Mode\ServerStatistics.cs" />
|
<Compile Include="Mode\ServerStatistics.cs" />
|
||||||
|
|||||||
Reference in New Issue
Block a user