From 48f1f085378e84d802d928de53a405dff0cc0bcd Mon Sep 17 00:00:00 2001 From: AnyOldName3 Date: Sun, 7 Apr 2024 22:12:39 +0100 Subject: [PATCH] Hide things that depend on present-but-inactive game files https://gitlab.com/OpenMW/openmw/-/merge_requests/3925#note_1843962919 --- components/contentselector/model/contentmodel.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/components/contentselector/model/contentmodel.cpp b/components/contentselector/model/contentmodel.cpp index 66fde2063f..8e7b77d308 100644 --- a/components/contentselector/model/contentmodel.cpp +++ b/components/contentselector/model/contentmodel.cpp @@ -110,7 +110,7 @@ Qt::ItemFlags ContentSelectorModel::ContentModel::flags(const QModelIndex& index return Qt::NoItemFlags; if (file->builtIn() || file->fromAnotherConfigFile()) - return Qt::NoItemFlags; + return Qt::ItemIsEnabled; // game files can always be checked if (file == mGameFile) @@ -228,7 +228,7 @@ QVariant ContentSelectorModel::ContentModel::data(const QModelIndex& index, int { if (file == mGameFile) return ContentType_GameFile; - else + else if (flags(index)) return ContentType_Addon; break;