consolidate the subdir name data path

every path should be separator-fixed

Reviewed-by: dt
This commit is contained in:
Oswald Buddenhagen
2010-06-08 14:02:15 +02:00
parent fc421df12d
commit 6a6e0091c8

View File

@@ -1425,16 +1425,15 @@ QStringList Qt4ProFileNode::subDirsPaths(ProFileReader *reader) const
const QString subDirKey = subDirVar + QLatin1String(".subdir"); const QString subDirKey = subDirVar + QLatin1String(".subdir");
const QString subDirFileKey = subDirVar + QLatin1String(".file"); const QString subDirFileKey = subDirVar + QLatin1String(".file");
if (reader->contains(subDirKey)) if (reader->contains(subDirKey))
realDir = QFileInfo(reader->value(subDirKey)).filePath(); realDir = reader->value(subDirKey);
else if (reader->contains(subDirFileKey)) else if (reader->contains(subDirFileKey))
realDir = QFileInfo(reader->value(subDirFileKey)).filePath(); realDir = reader->value(subDirFileKey);
else else
realDir = subDirVar; realDir = subDirVar;
QFileInfo info(realDir); QFileInfo info(realDir);
if (!info.isAbsolute()) { if (!info.isAbsolute())
info.setFile(m_projectDir + QLatin1Char('/') + realDir); info.setFile(m_projectDir + QLatin1Char('/') + realDir);
realDir = m_projectDir + QLatin1Char('/') + realDir; realDir = info.filePath();
}
QString realFile; QString realFile;
if (info.isDir()) { if (info.isDir()) {