mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-09-29 17:32:17 -07:00
Move impl to cpp, fix lifetime issues.
Took 11 minutes Took 2 minutes
This commit is contained in:
parent
961a973772
commit
a9077aa65b
27 changed files with 442 additions and 281 deletions
|
|
@ -310,7 +310,6 @@ void GameSelector::customContextMenu(const QPoint &point)
|
|||
connect(&getGameInfo, &QAction::triggered, this, [=, this]() {
|
||||
const ServerInfo_Game &gameInfo = gameListModel->getGame(index.data(Qt::UserRole).toInt());
|
||||
const QMap<int, QString> &gameTypes = gameListModel->getGameTypes().value(gameInfo.room_id());
|
||||
qWarning() << "Game Id: " << gameInfo.game_id();
|
||||
|
||||
DlgCreateGame dlg(gameInfo, gameTypes, this);
|
||||
dlg.exec();
|
||||
|
|
|
|||
|
|
@ -280,6 +280,7 @@ void TabRoom::processListGamesEvent(const Event_ListGames &event)
|
|||
for (int i = 0; i < gameListSize; ++i) {
|
||||
gameSelector->processGameInfo(event.game_list(i));
|
||||
}
|
||||
emit gameListUpdated();
|
||||
}
|
||||
|
||||
void TabRoom::processJoinRoomEvent(const Event_JoinRoom &event)
|
||||
|
|
|
|||
|
|
@ -78,6 +78,7 @@ signals:
|
|||
void openMessageDialog(const QString &userName, bool focus);
|
||||
void maximizeClient();
|
||||
void notIdle();
|
||||
void gameListUpdated();
|
||||
private slots:
|
||||
void sendMessage();
|
||||
void sayFinished(const Response &response);
|
||||
|
|
|
|||
|
|
@ -587,6 +587,10 @@ void TabSupervisor::actTabServer(bool checked)
|
|||
|
||||
void TabSupervisor::openTabServer()
|
||||
{
|
||||
if (tabServer) {
|
||||
return;
|
||||
}
|
||||
|
||||
tabServer = new TabServer(this, client);
|
||||
connect(tabServer, &TabServer::roomJoined, this, &TabSupervisor::addRoomTab);
|
||||
myAddTab(tabServer, aTabServer);
|
||||
|
|
|
|||
|
|
@ -187,6 +187,7 @@ public slots:
|
|||
void maximizeMainWindow();
|
||||
void actTabVisualDeckStorage(bool checked);
|
||||
void actTabReplays(bool checked);
|
||||
void openTabServer();
|
||||
private slots:
|
||||
void refreshShortcuts();
|
||||
|
||||
|
|
@ -199,7 +200,6 @@ private slots:
|
|||
|
||||
void openTabVisualDeckStorage();
|
||||
void openTabHome();
|
||||
void openTabServer();
|
||||
void openTabAccount();
|
||||
void openTabDeckStorage();
|
||||
void openTabReplays();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue