From db1174b6b8d28c0ec9e543e02a413ded0a326aad Mon Sep 17 00:00:00 2001 From: hjk Date: Fri, 25 May 2018 15:12:34 +0200 Subject: [PATCH] Debugger: Remove a parameter with fixed value Internal::displayDebugger's updateEngine parameter was always true. Change-Id: I27e91b7327ef7f4ccfb7718ad47fe5316660ea17 Reviewed-by: Christian Stenger --- src/plugins/debugger/debuggercore.h | 2 +- src/plugins/debugger/debuggerplugin.cpp | 11 +++++------ src/plugins/debugger/snapshothandler.cpp | 2 +- 3 files changed, 7 insertions(+), 8 deletions(-) diff --git a/src/plugins/debugger/debuggercore.h b/src/plugins/debugger/debuggercore.h index 57f9476bf88..db77a8e5a7a 100644 --- a/src/plugins/debugger/debuggercore.h +++ b/src/plugins/debugger/debuggercore.h @@ -77,7 +77,7 @@ void showMessage(const QString &msg, int channel, int timeout = -1); bool isReverseDebugging(); void runControlStarted(DebuggerRunTool *runTool); void runControlFinished(DebuggerRunTool *runTool); -void displayDebugger(DebuggerRunTool *runTool, bool updateEngine); +void displayDebugger(DebuggerRunTool *runTool); void synchronizeBreakpoints(); void saveModeToRestore(); diff --git a/src/plugins/debugger/debuggerplugin.cpp b/src/plugins/debugger/debuggerplugin.cpp index f92b55d6ea9..41105707043 100644 --- a/src/plugins/debugger/debuggerplugin.cpp +++ b/src/plugins/debugger/debuggerplugin.cpp @@ -747,7 +747,7 @@ public: void runControlFinished(DebuggerRunTool *runTool); void remoteCommand(const QStringList &options); - void displayDebugger(DebuggerRunTool *runTool, bool updateEngine = true); + void displayDebugger(DebuggerRunTool *runTool); void dumpLog(); void cleanupViews(); @@ -2379,7 +2379,7 @@ void DebuggerPluginPrivate::requestMark(TextEditorWidget *widget, int lineNumber } // If updateEngine is set, the engine will update its threads/modules and so forth. -void DebuggerPluginPrivate::displayDebugger(DebuggerRunTool *runTool, bool updateEngine) +void DebuggerPluginPrivate::displayDebugger(DebuggerRunTool *runTool) { QTC_ASSERT(runTool, return); DebuggerEngine *engine = runTool ? runTool->engine() : dummyEngine(); @@ -2387,8 +2387,7 @@ void DebuggerPluginPrivate::displayDebugger(DebuggerRunTool *runTool, bool updat disconnectEngine(); connectEngine(runTool); - if (updateEngine) - engine->updateAll(); + engine->updateAll(); engine->updateViews(); } @@ -3197,9 +3196,9 @@ void runControlFinished(DebuggerRunTool *runTool) dd->runControlFinished(runTool); } -void displayDebugger(DebuggerRunTool *runTool, bool updateEngine) +void displayDebugger(DebuggerRunTool *runTool) { - dd->displayDebugger(runTool, updateEngine); + dd->displayDebugger(runTool); } void synchronizeBreakpoints() diff --git a/src/plugins/debugger/snapshothandler.cpp b/src/plugins/debugger/snapshothandler.cpp index 61e5d4e181f..225e572017b 100644 --- a/src/plugins/debugger/snapshothandler.cpp +++ b/src/plugins/debugger/snapshothandler.cpp @@ -207,7 +207,7 @@ void SnapshotHandler::activateSnapshot(int index) beginResetModel(); m_currentIndex = index; //qDebug() << "ACTIVATING INDEX: " << m_currentIndex << " OF " << size(); - Internal::displayDebugger(at(index), true); + Internal::displayDebugger(at(index)); endResetModel(); }