This commit is contained in:
ChsBuffer
2021-01-14 20:13:15 +08:00
parent 06049cb06f
commit 5ff26e97b4
2 changed files with 5 additions and 6 deletions

View File

@@ -35,12 +35,12 @@ namespace Netch.Forms
NewVersionLabel.Text = "...";
try
{
DownloadProgressChangedEventHandler OnDownloadProgressChanged()
void OnDownloadProgressChanged(object o1, DownloadProgressChangedEventArgs args)
{
return (_, args) => { BeginInvoke(new Action(() => { NewVersionLabel.Text = $"{args.ProgressPercentage}%"; })); };
BeginInvoke(new Action(() => { NewVersionLabel.Text = $"{args.ProgressPercentage}%"; }));
}
await UpdateChecker.UpdateNetch(OnDownloadProgressChanged());
await UpdateChecker.UpdateNetch(OnDownloadProgressChanged);
}
catch (Exception exception)
{

View File

@@ -72,10 +72,10 @@ namespace Netch.Utils
private static bool _mux;
public static event EventHandler TestDelayFinished;
public static bool TestAllDelay()
public static void TestAllDelay()
{
if (_mux)
return false;
return;
try
{
_mux = true;
@@ -88,7 +88,6 @@ namespace Netch.Utils
{
// ignored
}
return true;
}
#endregion