Rework card menu handling (#6069)

* extract cardMenu from CardItem

* move cardMenu saving to TabGame

* delete TabGame::updateCardMenu

* move checking to updateCardMenu

* unset activeCard when all cards are unselected
This commit is contained in:
RickyRister 2025-08-15 02:13:28 -03:00 committed by GitHub
parent 1649f30389
commit 03bebbe4c2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 106 additions and 123 deletions

View file

@ -118,6 +118,7 @@ private:
*aPlayerListDockVisible, *aPlayerListDockFloating, *aReplayDockVisible, *aReplayDockFloating;
QAction *aFocusChat;
QList<QAction *> phaseActions;
QAction *aCardMenu;
Player *addPlayer(int playerId, const ServerInfo_User &info);
@ -171,7 +172,7 @@ private slots:
void incrementGameTime();
void adminLockChanged(bool lock);
void newCardAdded(AbstractCardItem *card);
void updateCardMenu(AbstractCardItem *card);
void setCardMenu(QMenu *menu);
void actGameInfo();
void actConcede();