mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-07-18 08:22:15 -07:00
set icon size in GameSelector
This commit is contained in:
parent
66b5b0aca1
commit
2e57c95dad
2 changed files with 3 additions and 3 deletions
|
|
@ -50,6 +50,7 @@ GameSelector::GameSelector(AbstractClient *_client,
|
|||
} else {
|
||||
gameListView->setModel(gameListModel);
|
||||
}
|
||||
gameListView->setIconSize(QSize(13, 13));
|
||||
gameListView->setSortingEnabled(true);
|
||||
gameListView->sortByColumn(gameListModel->startTimeColIndex(), Qt::AscendingOrder);
|
||||
gameListView->setAlternatingRowColors(true);
|
||||
|
|
|
|||
|
|
@ -118,11 +118,10 @@ QVariant GamesModel::data(const QModelIndex &index, int role) const
|
|||
case Qt::DisplayRole:
|
||||
return QString::fromStdString(gameentry.creator_info().name());
|
||||
case Qt::DecorationRole: {
|
||||
QPixmap avatarPixmap = UserLevelPixmapGenerator::generatePixmap(
|
||||
13, (UserLevelFlags)gameentry.creator_info().user_level(),
|
||||
return UserLevelPixmapGenerator::generateIcon(
|
||||
13, UserLevelFlags(gameentry.creator_info().user_level()),
|
||||
gameentry.creator_info().pawn_colors(), false,
|
||||
QString::fromStdString(gameentry.creator_info().privlevel()));
|
||||
return QIcon(avatarPixmap);
|
||||
}
|
||||
default:
|
||||
return QVariant();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue