QmlDebug: Fix handling of QML stack trace locations on Windows

Remove leading slash.
This commit is contained in:
Kai Koehne
2011-03-28 12:30:18 +02:00
parent 41a558643d
commit 37076b33fe

View File

@@ -762,11 +762,12 @@ QString QmlEngine::toFileInProject(const QString &fileUrl)
if (fileUrl.isEmpty())
return fileUrl;
const QString path = QUrl(fileUrl).path();
const QString path = QUrl(fileUrl).toLocalFile();
if (path.isEmpty())
return fileUrl;
// Try to find shadow-build file in source dir first
if (!QUrl(fileUrl).toLocalFile().isEmpty()
&& isShadowBuildProject()) {
if (isShadowBuildProject()) {
const QString sourcePath = fromShadowBuildFilename(path);
if (QFileInfo(sourcePath).exists())
return sourcePath;