diff options
Diffstat (limited to 'src/modlist.cpp')
| -rw-r--r-- | src/modlist.cpp | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/src/modlist.cpp b/src/modlist.cpp index ee7db894..16d2cd07 100644 --- a/src/modlist.cpp +++ b/src/modlist.cpp @@ -378,16 +378,15 @@ QVariant ModList::data(const QModelIndex &modelIndex, int role) const }
}
return QVariant();
- } else if (role == Qt::TextColorRole) {
+ } else if (role == Qt::ForegroundRole) {
if (modInfo->hasFlag(ModInfo::FLAG_SEPARATOR) && modInfo->getColor().isValid()) {
return Settings::getIdealTextColor(modInfo->getColor());
- }
- return QVariant();
- } else if (role == Qt::ForegroundRole) {
- if (column == COL_NAME) {
+ } else if (column == COL_NAME) {
int highlight = modInfo->getHighlight();
- if (highlight & ModInfo::HIGHLIGHT_IMPORTANT) return QBrush(Qt::darkRed);
- else if (highlight & ModInfo::HIGHLIGHT_INVALID) return QBrush(Qt::darkGray);
+ if (highlight & ModInfo::HIGHLIGHT_IMPORTANT)
+ return QBrush(Qt::darkRed);
+ else if (highlight & ModInfo::HIGHLIGHT_INVALID)
+ return QBrush(Qt::darkGray);
} else if (column == COL_VERSION) {
if (!modInfo->getNewestVersion().isValid()) {
return QVariant();
|
