aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristiaan Janssen <christiaan.janssen@nokia.com>2010-11-24 16:28:05 +0100
committerChristiaan Janssen <christiaan.janssen@nokia.com>2010-11-24 16:28:25 +0100
commit6f334c9b529f8e97965c954352e485d21bb5058f (patch)
treeb89fc94f86c828b27257fe5e030d2eeccf49f445
parenta5ddef5d5cbe1b30e8bf80a416c5624bff3a9dda (diff)
QmlDebugger: fixing Qml breakpoints not working on OSX
Reviewed-by: Kai Koehne
-rw-r--r--src/plugins/debugger/qml/qmlengine.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/plugins/debugger/qml/qmlengine.cpp b/src/plugins/debugger/qml/qmlengine.cpp
index 8a0e3805cd..1020419c1a 100644
--- a/src/plugins/debugger/qml/qmlengine.cpp
+++ b/src/plugins/debugger/qml/qmlengine.cpp
@@ -449,8 +449,15 @@ void QmlEngine::attemptBreakpointSynchronization()
for (int index = 0; index != handler->size(); ++index) {
Internal::BreakpointData *data = handler->at(index);
QString processedFilename = data->fileName;
+#ifdef Q_OS_MACX
+ // Qt Quick Applications by default copy the qml directory to buildDir()/X.app/Contents/Resources
+ const QString applicationBundleDir
+ = QFileInfo(startParameters().executable).absolutePath() + "/../..";
+ processedFilename = mangleFilenamePaths(data->fileName, startParameters().projectDir, applicationBundleDir + "/Contents/Resources");
+#endif
if (isShadowBuildProject())
- processedFilename = toShadowBuildFilename(data->fileName);
+ processedFilename = toShadowBuildFilename(processedFilename);
+
breakList << qMakePair(processedFilename, data->lineNumber);
}