Consider removed cards.

Took 14 minutes
This commit is contained in:
Lukas Brübach 2026-06-15 00:50:51 +02:00
parent 0cfffdf9df
commit 815baa1ffd
8 changed files with 39 additions and 7 deletions

View file

@ -15,6 +15,17 @@ void CardState::prepareDelete()
attachedCards.first()->setZone(nullptr); // so that it won't try to call reorganizeCards()
attachedCards.first()->setAttachedTo(nullptr);
}
if (getAttachedTo() != nullptr) {
getAttachedTo()->removeAttachedCard(this);
setAttachedTo(nullptr);
}
}
void CardState::deleteLater()
{
prepareDelete();
QObject::deleteLater();
}
void CardState::processCardInfo(const ServerInfo_Card &_info)