aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/debugger/breakhandler.cpp
diff options
context:
space:
mode:
authorEike Ziller <[email protected]>2015-05-07 14:42:46 +0200
committerEike Ziller <[email protected]>2015-05-07 14:42:46 +0200
commit4058ff6fe96e1a2e049700dfc7a5e7a120f29068 (patch)
tree7106e67beabbf4309b9616475f70b73192d4a867 /src/plugins/debugger/breakhandler.cpp
parentfa704e0b8430da14ba86015e143a094286835934 (diff)
parent13a947d119c4722461759f1aeb6b61e93e9be210 (diff)
Merge remote-tracking branch 'origin/3.4'
Conflicts: src/libs/extensionsystem/pluginview.cpp Change-Id: I410156c1003d5dc81e915110c6d432bcd71da010
Diffstat (limited to 'src/plugins/debugger/breakhandler.cpp')
-rw-r--r--src/plugins/debugger/breakhandler.cpp19
1 files changed, 16 insertions, 3 deletions
diff --git a/src/plugins/debugger/breakhandler.cpp b/src/plugins/debugger/breakhandler.cpp
index 78ca7a69482..21d49a868c4 100644
--- a/src/plugins/debugger/breakhandler.cpp
+++ b/src/plugins/debugger/breakhandler.cpp
@@ -33,11 +33,18 @@
#include "debuggeractions.h"
#include "debuggercore.h"
#include "debuggerengine.h"
+#include "debuggerinternalconstants.h"
#include "debuggerstringutils.h"
#include "simplifytype.h"
+#include <coreplugin/coreconstants.h>
+#include <coreplugin/coreplugin.h>
+#include <coreplugin/editormanager/editormanager.h>
+#include <coreplugin/idocument.h>
+
#include <extensionsystem/invoker.h>
#include <texteditor/textmark.h>
+#include <texteditor/texteditor.h>
#include <utils/hostosinfo.h>
#include <utils/qtcassert.h>
#include <utils/fileutils.h>
@@ -50,6 +57,7 @@
#include <QDir>
#include <QDebug>
+using namespace Core;
using namespace Utils;
namespace Debugger {
@@ -1171,10 +1179,15 @@ void BreakHandler::timerEvent(QTimerEvent *event)
void Breakpoint::gotoLocation() const
{
if (DebuggerEngine *engine = currentEngine()) {
- if (b->m_params.type == BreakpointByAddress)
+ if (b->m_params.type == BreakpointByAddress) {
engine->gotoLocation(b->m_params.address);
- else
- engine->gotoLocation(Location(b->markerFileName(), b->markerLineNumber(), false));
+ } else {
+ // Don't use gotoLocation as this ends up in disassembly
+ // if OperateByInstruction is on.
+ const QString file = QDir::cleanPath(b->markerFileName());
+ IEditor *editor = EditorManager::openEditor(file);
+ editor->gotoLine(b->markerLineNumber(), 0);
+ }
}
}