[Lobby][DeckView] Always at minimum create main and side deck zone containers. (#7001)

Took 12 minutes

Took 3 seconds

Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
(cherry picked from commit 309e4730a3)
This commit is contained in:
BruebachL 2026-06-15 15:50:04 +02:00 committed by RickyRister
parent 500e6419b2
commit abfbb64a22

View file

@ -360,6 +360,16 @@ void DeckViewScene::rebuildTree()
return;
}
QStringList requiredZones = {DECK_ZONE_MAIN, DECK_ZONE_SIDE};
for (const QString &zoneName : requiredZones) {
if (!cardContainers.contains(zoneName)) {
auto *container = new DeckViewCardContainer(zoneName);
cardContainers.insert(zoneName, container);
addItem(container);
}
}
for (auto *currentZone : deck->getZoneNodes()) {
DeckViewCardContainer *container = cardContainers.value(currentZone->getName(), 0);
if (!container) {