OSDN Git Service

QmlDebugger: Always use ',block' argument
authorKai Koehne <kai.koehne@nokia.com>
Wed, 8 Jun 2011 08:54:24 +0000 (10:54 +0200)
committerChristiaan Janssen <christiaan.janssen@nokia.com>
Wed, 8 Jun 2011 12:39:13 +0000 (14:39 +0200)
This will allow e.g. the JS Debugger to catch scripts running at startup.

Change-Id: I00d339b06f1ed2b716c62bd2d53a32c2b20b1ddc
Reviewed-on: http://codereview.qt.nokia.com/377
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Christiaan Janssen <christiaan.janssen@nokia.com>
src/plugins/debugger/debuggerrunner.cpp
src/plugins/qmlprojectmanager/qmlprojectruncontrol.cpp
src/plugins/qt4projectmanager/qt-s60/s60devicerunconfiguration.cpp

index 89d4437..cf83be4 100644 (file)
@@ -745,8 +745,8 @@ static DebuggerStartParameters localStartParameters(RunConfiguration *runConfigu
             sp.environment.set(optimizerKey, _("1"));
         }
 
-        Utils::QtcProcess::addArg(&sp.processArgs, _("-qmljsdebugger=port:")
-                                  + QString::number(sp.qmlServerPort));
+        Utils::QtcProcess::addArg(&sp.processArgs, QString("-qmljsdebugger=port:%1,block").arg(
+                                      sp.qmlServerPort));
     }
 
     // FIXME: If it's not yet build this will be empty and not filled
index 0685af9..07e3167 100644 (file)
@@ -202,7 +202,7 @@ RunControl *QmlProjectRunControlFactory::createDebugRunControl(QmlProjectRunConf
     params.executable = runConfig->observerPath();
     params.qmlServerAddress = "127.0.0.1";
     params.qmlServerPort = runConfig->qmlDebugServerPort();
-    params.processArgs = QLatin1String("-qmljsdebugger=port:") + QString::number(runConfig->qmlDebugServerPort());
+    params.processArgs = QString("-qmljsdebugger=port:%1,block").arg(runConfig->qmlDebugServerPort());
     params.processArgs += QLatin1Char(' ') + runConfig->viewerArguments();
     params.workingDirectory = runConfig->workingDirectory();
     params.environment = runConfig->environment();
index ee61aae..0f36a53 100644 (file)
@@ -313,7 +313,7 @@ QString S60DeviceRunConfiguration::qmlCommandLineArguments() const
         QTC_ASSERT(activeDeployConf, return args);
 
         if (activeDeployConf->communicationChannel() == S60DeployConfiguration::CommunicationCodaTcpConnection)
-            args = QString("-qmljsdebugger=port:%1").arg(qmlDebugServerPort());
+            args = QString("-qmljsdebugger=port:%1,block").arg(qmlDebugServerPort());
         else
             args = QString("-qmljsdebugger=ost");
     }