Control ModifierKey to Test Selected Server

This commit is contained in:
ChsBuffer
2021-02-26 13:29:52 +08:00
parent 7ad89e7803
commit 146f2013ee

View File

@@ -742,7 +742,14 @@ namespace Netch.Forms
Enabled = false;
StatusText(i18N.Translate("Testing"));
if (IsWaiting())
if (!IsWaiting() || ModifierKeys == Keys.Control)
{
(ServerComboBox.SelectedItem as Server)?.Test();
ServerComboBox.Refresh();
Enabled = true;
StatusText();
}
else
{
ServerHelper.DelayTestHelper.TestDelayFinished += OnTestDelayFinished;
_ = Task.Run(ServerHelper.DelayTestHelper.TestAllDelay);
@@ -756,13 +763,6 @@ namespace Netch.Forms
StatusText();
}
}
else
{
(ServerComboBox.SelectedItem as Server)?.Test();
ServerComboBox.Refresh();
Enabled = true;
StatusText();
}
}
private void CopyLinkPictureBox_Click(object sender, EventArgs e)