[Refactor] Move attach and arrow previews from game logic into CardMenu (#7414)

Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
This commit is contained in:
BruebachL 2026-10-31 18:44:08 +01:00 • committed by GitHub
parent 52c5bd2ea3
commit 93c5d85996
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 28 additions and 30 deletions

View file

@ -1417,14 +1417,6 @@ void PlayerActions::actSetPT(QList<CardItem *> selectedCards, const QString &pt)
player->getGame()->getGameEventHandler()->sendGameCommand(prepareGameCommand(commandList), playerid);
}
void PlayerActions::actDrawArrow()
{
auto *card = player->getGame()->getActiveCard();
if (card) {
card->drawArrow(Qt::red);
}
}
void PlayerActions::actIncP(QList<CardItem *> selectedCards)
{
actIncPT(selectedCards, 1, 0);
@ -1516,16 +1508,6 @@ void PlayerActions::actSetAnnotation(QList<CardItem *> selectedCards, const QStr
sendGameCommand(prepareGameCommand(commandList));
}
void PlayerActions::actAttach()
{
auto *card = player->getGame()->getActiveCard();
if (!card) {
return;
}
card->drawAttachArrow();
}
void PlayerActions::actUnattach(QList<CardItem *> selectedCards)
{
QList<const ::google::protobuf::Message *> commandList;