mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-01-21 17:13:22 -08:00
Ensure the whole table gets refreshed when updating prices
This commit is contained in:
@@ -472,13 +472,7 @@ void DeckListModel::printDeckList(QPrinter *printer)
|
||||
doc.print(printer);
|
||||
}
|
||||
|
||||
void DeckListModel::pricesUpdated(InnerDecklistNode *node)
|
||||
void DeckListModel::pricesUpdated()
|
||||
{
|
||||
if (!node)
|
||||
node = root;
|
||||
|
||||
if (node->isEmpty())
|
||||
return;
|
||||
|
||||
emit dataChanged(createIndex(0, 2, node->at(0)), createIndex(node->size() - 1, 2, node->last()));
|
||||
emit layoutChanged();
|
||||
}
|
||||
|
||||
@@ -51,7 +51,7 @@ public:
|
||||
void cleanList();
|
||||
DeckLoader *getDeckList() const { return deckList; }
|
||||
void setDeckList(DeckLoader *_deck);
|
||||
void pricesUpdated(InnerDecklistNode *node = 0);
|
||||
void pricesUpdated();
|
||||
private:
|
||||
DeckLoader *deckList;
|
||||
InnerDecklistNode *root;
|
||||
|
||||
Reference in New Issue
Block a user