diff --git a/cockatrice/src/tab_server.cpp b/cockatrice/src/tab_server.cpp index 787b08d8..a85fe1c0 100644 --- a/cockatrice/src/tab_server.cpp +++ b/cockatrice/src/tab_server.cpp @@ -168,7 +168,12 @@ void TabServer::retranslateUi() void TabServer::processServerMessageEvent(const Event_ServerMessage &event) { serverInfoBox->setHtml(QString::fromStdString(event.message())); - emit userEvent(); + if (shouldEmitUpdate) { + // prevent the initial server message from taking attention from ping icon + emit userEvent(); + } else { + shouldEmitUpdate = true; + } } void TabServer::joinRoom(int id, bool setCurrent) diff --git a/cockatrice/src/tab_server.h b/cockatrice/src/tab_server.h index baa8b6a6..e52d715c 100644 --- a/cockatrice/src/tab_server.h +++ b/cockatrice/src/tab_server.h @@ -47,6 +47,7 @@ private: AbstractClient *client; RoomSelector *roomSelector; QTextBrowser *serverInfoBox; + bool shouldEmitUpdate = false; public: TabServer(TabSupervisor *_tabSupervisor, AbstractClient *_client, QWidget *parent = 0); void retranslateUi();