MCPcopy Create free account
hub / github.com/KDE/kdevelop / showStepInSource

Method showStepInSource

kdevplatform/shell/debugcontroller.cpp:384–406  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

382}
383
384void DebugController::showStepInSource(const QUrl& originalUrl, int originalLine)
385{
386 if((Core::self()->setupFlags() & Core::NoUi)) return;
387
388 clearExecutionPoint();
389 qCDebug(SHELL) << "showing debugger step in source:" << originalUrl << originalLine;
390
391 Q_ASSERT(qobject_cast<IDebugSession*>(sender()));
392 const auto [url, line] = static_cast<IDebugSession*>(sender())->convertToLocalUrl({originalUrl, originalLine});
393
394 const auto* const document = ICore::self()->documentController()->openDocument(url, KTextEditor::Cursor(line, 0),
395 IDocumentController::DoNotFocus);
396 if( !document )
397 return;
398
399 auto* const textDocument = document->textDocument();
400 if (!textDocument)
401 return;
402
403 m_lastExecMarkDocument = textDocument;
404 m_lastExecMarkLine = line;
405 textDocument->addMark(line, executionMark);
406}
407
408
409void DebugController::debuggerStateChanged(KDevelop::IDebugSession::DebuggerState state)

Callers

nothing calls this directly

Calls 6

setupFlagsMethod · 0.80
documentControllerMethod · 0.80
CursorClass · 0.50
convertToLocalUrlMethod · 0.45
openDocumentMethod · 0.45
textDocumentMethod · 0.45

Tested by

no test coverage detected