mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-07-18 08:22:15 -07:00
Hide groups which have no cards in them.
This commit is contained in:
parent
b51d5a6fd6
commit
4319211b29
1 changed files with 5 additions and 0 deletions
|
|
@ -34,6 +34,11 @@ void OverlappedCardGroupDisplayWidget::updateCardDisplays()
|
||||||
{
|
{
|
||||||
QList<CardInfoPtr> cardsInZone = getCardsMatchingGroup(deckListModel->getCardsAsCardInfoPtrsForZone(zoneName));
|
QList<CardInfoPtr> cardsInZone = getCardsMatchingGroup(deckListModel->getCardsAsCardInfoPtrsForZone(zoneName));
|
||||||
|
|
||||||
|
bool shouldBeVisible = !cardsInZone.isEmpty();
|
||||||
|
if (shouldBeVisible != isVisible()) {
|
||||||
|
setVisible(shouldBeVisible);
|
||||||
|
}
|
||||||
|
|
||||||
QList<CardInfoPictureWithTextOverlayWidget *> existingWidgets =
|
QList<CardInfoPictureWithTextOverlayWidget *> existingWidgets =
|
||||||
overlapWidget->findChildren<CardInfoPictureWithTextOverlayWidget *>();
|
overlapWidget->findChildren<CardInfoPictureWithTextOverlayWidget *>();
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue