Search
j0ke.net Open Build Service
>
Projects
>
home:netmax
:
playground
>
opt-libqt4-sql-plugins
> rcc-stable-dirlisting.diff
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File rcc-stable-dirlisting.diff of Package opt-libqt4-sql-plugins
diff --git a/src/tools/rcc/rcc.cpp b/src/tools/rcc/rcc.cpp index 1f6e58f..51cdd18 100644 --- a/src/tools/rcc/rcc.cpp +++ b/src/tools/rcc/rcc.cpp @@ -477,24 +477,30 @@ bool RCCResourceLibrary::interpretResourceFile(QIODevice *inputDevice, if (!alias.endsWith(slash)) alias += slash; QDirIterator it(dir, QDirIterator::FollowSymlinks|QDirIterator::Subdirectories); + QStringList fileList; while (it.hasNext()) { - it.next(); - QFileInfo child(it.fileInfo()); - if (child.fileName() != QLatin1String(".") && child.fileName() != QLatin1String("..")) { - const bool arc = - addFile(alias + child.fileName(), - RCCFileInfo(child.fileName(), - child, - language, - country, - RCCFileInfo::NoFlags, - compressLevel, - compressThreshold) - ); - if (!arc) - m_failedResources.push_back(child.fileName()); + QString child = it.next(); + if (!child.endsWith(QLatin1String(".")) + && !child.endsWith(QLatin1String(".."))) { + fileList << it.filePath(); } } + fileList.sort(); + for (QStringListIterator it(fileList); it.hasNext();) { + QFileInfo child(it.next()); + const bool arc = + addFile(alias + child.fileName(), + RCCFileInfo(child.fileName(), + child, + language, + country, + RCCFileInfo::NoFlags, + compressLevel, + compressThreshold) + ); + if (!arc) + m_failedResources.push_back(child.fileName()); + } } } }