forked from teamnwah/openmw-tes3coop
[Browser] Do not allow to connect to unreachable servers
This commit is contained in:
parent
f8c6ed8028
commit
4082cddde5
1 changed files with 3 additions and 1 deletions
|
@ -36,7 +36,9 @@ void ServerInfoDialog::refresh()
|
||||||
{
|
{
|
||||||
leAddr->setText(sd.first.ToString(true, ':'));
|
leAddr->setText(sd.first.ToString(true, ':'));
|
||||||
lblName->setText(sd.second.GetName());
|
lblName->setText(sd.second.GetName());
|
||||||
lblPing->setNum((int) PingRakNetServer(sd.first.ToString(false), sd.first.GetPort()));
|
int ping = PingRakNetServer(sd.first.ToString(false), sd.first.GetPort());
|
||||||
|
lblPing->setNum(ping);
|
||||||
|
btnConnect->setDisabled(ping == PING_UNREACHABLE);
|
||||||
|
|
||||||
listPlayers->clear();
|
listPlayers->clear();
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue