mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-25 06:35:30 +00:00
CLEANUP(contentmodel): Actually, no, I hate while loops
This commit is contained in:
parent
b43743212e
commit
40aee53831
@ -674,8 +674,12 @@ void ContentSelectorModel::ContentModel::setNonUserContent(const QStringList& fi
|
||||
|
||||
int insertPosition = 0;
|
||||
|
||||
while (insertPosition < mFiles.size() && mFiles.at(insertPosition)->builtIn())
|
||||
for (auto* file : mFiles)
|
||||
{
|
||||
if (!file->builtIn())
|
||||
break;
|
||||
++insertPosition;
|
||||
}
|
||||
|
||||
for (const auto& filepath : fileList)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user