From bc1f091698889b8d531113d4b336e9099e2f133a Mon Sep 17 00:00:00 2001
From: hjk <qthjk@ovi.com>
Date: Fri, 27 Jul 2012 17:29:11 +0200
Subject: [PATCH] valgrind: use common data from RunConfiguration base class

Only display name for now.

Change-Id: I6f404e175c0eca82b39055283b4432d9eae10709
Reviewed-by: hjk <qthjk@ovi.com>
---
 src/plugins/valgrind/valgrindtool.cpp | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/src/plugins/valgrind/valgrindtool.cpp b/src/plugins/valgrind/valgrindtool.cpp
index 013dd6c1322..ac1a27e8519 100644
--- a/src/plugins/valgrind/valgrindtool.cpp
+++ b/src/plugins/valgrind/valgrindtool.cpp
@@ -62,6 +62,7 @@ Analyzer::AnalyzerStartParameters ValgrindTool::createStartParameters(
     Q_UNUSED(mode);
 
     Analyzer::AnalyzerStartParameters sp;
+    sp.displayName = runConfiguration->displayName();
     if (LocalApplicationRunConfiguration *rc1 =
             qobject_cast<LocalApplicationRunConfiguration *>(runConfiguration)) {
         sp.startMode = Analyzer::StartLocal;
@@ -69,17 +70,15 @@ Analyzer::AnalyzerStartParameters ValgrindTool::createStartParameters(
         sp.workingDirectory = rc1->workingDirectory();
         sp.debuggee = rc1->executable();
         sp.debuggeeArgs = rc1->commandLineArguments();
-        sp.displayName = rc1->displayName();
         sp.connParams.host = QLatin1String("localhost");
         sp.connParams.port = rc1->debuggerAspect()->qmlDebugServerPort();
     } else if (RemoteLinuxRunConfiguration *rc2 =
                qobject_cast<RemoteLinuxRunConfiguration *>(runConfiguration)) {
         sp.startMode = Analyzer::StartRemote;
         sp.debuggee = rc2->remoteExecutableFilePath();
-        sp.debuggeeArgs = rc2->arguments();
         sp.connParams = ProjectExplorer::DeviceProfileInformation::device(rc2->target()->profile())->sshParameters();
         sp.analyzerCmdPrefix = rc2->commandPrefix();
-        sp.displayName = rc2->displayName();
+        sp.debuggeeArgs = rc2->arguments();
     } else {
         // Might be S60DeviceRunfiguration, or something else ...
         //sp.startMode = StartRemote;
-- 
GitLab