Skip to content

Commit

Permalink
RMG: improve handling of reply_players reply in NetplaySessionDialog.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
Rosalie241 committed Jan 21, 2025
1 parent c1db77a commit c93f829
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions Source/RMG/UserInterface/Dialog/Netplay/NetplaySessionDialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -87,18 +87,18 @@ void NetplaySessionDialog::on_webSocket_textMessageReceived(QString message)
for (int i = 0; i < 4; i++)
{
name = names.at(i).toString();
this->listWidget->addItem(name);
if (!name.isEmpty())
{
this->listWidget->addItem(name);
if (this->nickName == name)
{
this->sessionNumber = i + 1;
}
}
if (i == 0)
{
QPushButton* startButton = this->buttonBox->button(QDialogButtonBox::Ok);
startButton->setEnabled(this->nickName == name);
if (i == 0)
{
QPushButton* startButton = this->buttonBox->button(QDialogButtonBox::Ok);
startButton->setEnabled(this->nickName == name);
}
}
}
}
Expand Down

0 comments on commit c93f829

Please sign in to comment.