mirror of
https://github.com/2dust/v2rayN.git
synced 2025-08-29 14:26:20 +00:00
清理速度测试结果, 清理延迟测试结果
This commit is contained in:
parent
2652beed88
commit
e23ae91347
8 changed files with 60 additions and 1 deletions
|
@ -54,11 +54,13 @@ namespace v2rayN.Handler
|
|||
case ESpeedActionType.Ping:
|
||||
case ESpeedActionType.Tcping:
|
||||
case ESpeedActionType.Realping:
|
||||
case ESpeedActionType.ClearDelay:
|
||||
UpdateFunc(it.indexId, ResUI.Speedtesting, "");
|
||||
ProfileExHandler.Instance.SetTestDelay(it.indexId, "0");
|
||||
break;
|
||||
|
||||
case ESpeedActionType.Speedtest:
|
||||
case ESpeedActionType.ClearSpeed:
|
||||
UpdateFunc(it.indexId, "", ResUI.SpeedtestingWait);
|
||||
ProfileExHandler.Instance.SetTestSpeed(it.indexId, "0");
|
||||
break;
|
||||
|
|
|
@ -6,6 +6,8 @@
|
|||
Tcping,
|
||||
Realping,
|
||||
Speedtest,
|
||||
Mixedtest
|
||||
Mixedtest,
|
||||
ClearDelay,
|
||||
ClearSpeed
|
||||
}
|
||||
}
|
18
v2rayN/v2rayN/Resx/ResUI.Designer.cs
generated
18
v2rayN/v2rayN/Resx/ResUI.Designer.cs
generated
|
@ -663,6 +663,15 @@ namespace v2rayN.Resx {
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 查找类似 Clear Delay Result 的本地化字符串。
|
||||
/// </summary>
|
||||
public static string menuClearDelayResult {
|
||||
get {
|
||||
return ResourceManager.GetString("menuClearDelayResult", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 查找类似 Clear all service statistics 的本地化字符串。
|
||||
/// </summary>
|
||||
|
@ -672,6 +681,15 @@ namespace v2rayN.Resx {
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 查找类似 Clear Speed Result 的本地化字符串。
|
||||
/// </summary>
|
||||
public static string menuClearSpeedResult {
|
||||
get {
|
||||
return ResourceManager.GetString("menuClearSpeedResult", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 查找类似 Close 的本地化字符串。
|
||||
/// </summary>
|
||||
|
|
|
@ -1138,4 +1138,10 @@
|
|||
<data name="TbRoutingRuleDomain" xml:space="preserve">
|
||||
<value>Domain</value>
|
||||
</data>
|
||||
<data name="menuClearDelayResult" xml:space="preserve">
|
||||
<value>Clear Delay Result</value>
|
||||
</data>
|
||||
<data name="menuClearSpeedResult" xml:space="preserve">
|
||||
<value>Clear Speed Result</value>
|
||||
</data>
|
||||
</root>
|
|
@ -1135,4 +1135,10 @@
|
|||
<data name="TbRoutingRuleIP" xml:space="preserve">
|
||||
<value>IP 或 IP CIDR</value>
|
||||
</data>
|
||||
<data name="menuClearDelayResult" xml:space="preserve">
|
||||
<value>清除延时测试结果</value>
|
||||
</data>
|
||||
<data name="menuClearSpeedResult" xml:space="preserve">
|
||||
<value>清除速度测试结果</value>
|
||||
</data>
|
||||
</root>
|
|
@ -118,6 +118,10 @@ namespace v2rayN.ViewModels
|
|||
public ReactiveCommand<Unit, Unit> SpeedServerCmd { get; }
|
||||
public ReactiveCommand<Unit, Unit> SortServerResultCmd { get; }
|
||||
|
||||
// clear server test result
|
||||
public ReactiveCommand<Unit, Unit> ClearDelayResultCmd { get; }
|
||||
public ReactiveCommand<Unit, Unit> ClearSpeedResultCmd { get; }
|
||||
|
||||
//servers export
|
||||
public ReactiveCommand<Unit, Unit> Export2ClientConfigCmd { get; }
|
||||
|
||||
|
@ -417,6 +421,15 @@ namespace v2rayN.ViewModels
|
|||
{
|
||||
SortServer(EServerColName.delayVal.ToString());
|
||||
});
|
||||
//clear server test result
|
||||
ClearDelayResultCmd = ReactiveCommand.Create(() =>
|
||||
{
|
||||
ServerSpeedtest(ESpeedActionType.ClearDelay);
|
||||
}, canEditRemove);
|
||||
ClearSpeedResultCmd = ReactiveCommand.Create(() =>
|
||||
{
|
||||
ServerSpeedtest(ESpeedActionType.ClearSpeed);
|
||||
}, canEditRemove);
|
||||
//servers export
|
||||
Export2ClientConfigCmd = ReactiveCommand.Create(() =>
|
||||
{
|
||||
|
|
|
@ -577,6 +577,14 @@
|
|||
x:Name="menuSortServerResult"
|
||||
Height="{StaticResource MenuItemHeight}"
|
||||
Header="{x:Static resx:ResUI.menuSortServerResult}" />
|
||||
<MenuItem
|
||||
x:Name="menuClearDelayResult"
|
||||
Height="{StaticResource MenuItemHeight}"
|
||||
Header="{x:Static resx:ResUI.menuClearDelayResult}" />
|
||||
<MenuItem
|
||||
x:Name="menuClearSpeedResult"
|
||||
Height="{StaticResource MenuItemHeight}"
|
||||
Header="{x:Static resx:ResUI.menuClearSpeedResult}" />
|
||||
<Separator />
|
||||
<MenuItem
|
||||
x:Name="menuMoveToGroup"
|
||||
|
|
|
@ -115,6 +115,10 @@ namespace v2rayN.Views
|
|||
this.BindCommand(ViewModel, vm => vm.SpeedServerCmd, v => v.menuSpeedServer).DisposeWith(disposables);
|
||||
this.BindCommand(ViewModel, vm => vm.SortServerResultCmd, v => v.menuSortServerResult).DisposeWith(disposables);
|
||||
|
||||
// clear server test result
|
||||
this.BindCommand(ViewModel, vm => vm.ClearDelayResultCmd, v => v.menuClearDelayResult).DisposeWith(disposables);
|
||||
this.BindCommand(ViewModel, vm => vm.ClearSpeedResultCmd, v => v.menuClearSpeedResult).DisposeWith(disposables);
|
||||
|
||||
//servers export
|
||||
this.BindCommand(ViewModel, vm => vm.Export2ClientConfigCmd, v => v.menuExport2ClientConfig).DisposeWith(disposables);
|
||||
this.BindCommand(ViewModel, vm => vm.Export2ShareUrlCmd, v => v.menuExport2ShareUrl).DisposeWith(disposables);
|
||||
|
|
Loading…
Reference in a new issue