forked from qt-creator/qt-creator
ResourceNodes: Fix paths in copy url/path actions
Simplify qrc:/// to qrc:/, since that's the documented form. Also work around QDir::cleanPath() not cleaning up leading '//' on windows. Task-number: QTCREATORBUG-12299 Change-Id: Ifa75196b8682d4d9e8d5dc6045820000335b26c2 Reviewed-by: Alessandro Portale <alessandro.portale@digia.com>
This commit is contained in:
@@ -161,7 +161,10 @@ void ResourceTopLevelNode::update()
|
||||
// Note: this is wrong, but the qrceditor doesn't allow it either
|
||||
// only aliases need to be unique
|
||||
} else {
|
||||
const QString qrcPath = QDir::cleanPath(prefix + QLatin1Char('/') + alias);
|
||||
QString prefixWithSlash = prefix;
|
||||
if (!prefixWithSlash.endsWith(QLatin1Char('/')))
|
||||
prefixWithSlash.append(QLatin1Char('/'));
|
||||
const QString qrcPath = QDir::cleanPath(prefixWithSlash + alias);
|
||||
fileNames.insert(fileName);
|
||||
filesToAdd[qMakePair(prefix, lang)]
|
||||
<< new ResourceFileNode(fileName, qrcPath, this);
|
||||
|
||||
Reference in New Issue
Block a user