Debugger: Reduce line noise

Move some function out of the DebuggerCore "namespace", to avoid one
indirection and removes clutter in the calling code.

Change-Id: I1c870d5c7eeade32fa63dedf581490fbb090cd6a
Reviewed-by: Christian Stenger <christian.stenger@digia.com>
Reviewed-by: hjk <hjk121@nokiamail.com>
This commit is contained in:
hjk
2014-07-28 14:23:52 +02:00
parent 15fcdabc1d
commit 5ac407eecc
30 changed files with 286 additions and 325 deletions

View File

@@ -38,9 +38,8 @@
#include <utils/savedaction.h>
#include <QDebug>
#include <QProcess>
#include <QMenu>
#include <QProcess>
#include <QResizeEvent>
@@ -63,7 +62,7 @@ ModulesTreeView::ModulesTreeView()
void ModulesTreeView::moduleActivated(const QModelIndex &index)
{
DebuggerEngine *engine = debuggerCore()->currentEngine();
DebuggerEngine *engine = currentEngine();
QTC_ASSERT(engine, return);
if (index.isValid())
engine->gotoLocation(index.sibling(index.row(), 1).data().toString());
@@ -81,7 +80,7 @@ void ModulesTreeView::contextMenuEvent(QContextMenuEvent *ev)
fileName = index.sibling(index.row(), 1).data().toString();
}
DebuggerEngine *engine = debuggerCore()->currentEngine();
DebuggerEngine *engine = currentEngine();
QTC_ASSERT(engine, return);
const bool enabled = engine->debuggerActionsEnabled();
const bool canReload = engine->hasCapability(ReloadModuleCapability);
@@ -150,7 +149,7 @@ void ModulesTreeView::contextMenuEvent(QContextMenuEvent *ev)
menu.addAction(actShowModuleSymbols);
menu.addAction(actShowModuleSections);
menu.addSeparator();
menu.addAction(debuggerCore()->action(SettingsDialog));
menu.addAction(action(SettingsDialog));
QAction *act = menu.exec(ev->globalPos());