mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-04-27 07:48:01 -07:00
Sort VDE groups internally (#6102)
This commit is contained in:
parent
bd65aae81e
commit
7f842bb1e8
11 changed files with 181 additions and 111 deletions
|
|
@ -142,6 +142,8 @@ QVariant DeckListModel::data(const QModelIndex &index, int role) const
|
|||
return {};
|
||||
}
|
||||
}
|
||||
case Qt::UserRole + 1:
|
||||
return false;
|
||||
case Qt::BackgroundRole: {
|
||||
int color = 90 + 60 * node->depth();
|
||||
return QBrush(QColor(color, 255, color));
|
||||
|
|
@ -171,6 +173,8 @@ QVariant DeckListModel::data(const QModelIndex &index, int role) const
|
|||
return {};
|
||||
}
|
||||
}
|
||||
case Qt::UserRole + 1:
|
||||
return true;
|
||||
case Qt::BackgroundRole: {
|
||||
int color = 255 - (index.row() % 2) * 30;
|
||||
return QBrush(QColor(color, color, color));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue