summaryrefslogtreecommitdiff
path: root/src/plugins/debugger/qml/qmlv8debuggerclient.cpp
diff options
context:
space:
mode:
authorEike Ziller <eike.ziller@digia.com>2013-07-18 12:26:23 +0200
committerEike Ziller <eike.ziller@digia.com>2013-07-18 14:51:39 +0200
commit8c2e3fd2cbaeb1178ae3991de794ee6d74c84d85 (patch)
tree475e76bac18c802197b74a8862bded017352c59d /src/plugins/debugger/qml/qmlv8debuggerclient.cpp
parentbc88c0b89e8f61a50ba62c8319114330211337da (diff)
downloadqt-creator-8c2e3fd2cbaeb1178ae3991de794ee6d74c84d85.tar.gz
Fix usage of EditorManager::editorsForFileName
And move to using the corresponding method in document model. Change-Id: I80b12ceab8a91c5393b9c0422d660a8896ae09d8 Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Diffstat (limited to 'src/plugins/debugger/qml/qmlv8debuggerclient.cpp')
-rw-r--r--src/plugins/debugger/qml/qmlv8debuggerclient.cpp7
1 files changed, 1 insertions, 6 deletions
diff --git a/src/plugins/debugger/qml/qmlv8debuggerclient.cpp b/src/plugins/debugger/qml/qmlv8debuggerclient.cpp
index dc03a2890b..1d51afb31f 100644
--- a/src/plugins/debugger/qml/qmlv8debuggerclient.cpp
+++ b/src/plugins/debugger/qml/qmlv8debuggerclient.cpp
@@ -1998,12 +1998,7 @@ void QmlV8DebuggerClient::highlightExceptionCode(int lineNumber,
const QString &filePath,
const QString &errorMessage)
{
- DocumentModel *documentModel = EditorManager::documentModel();
- int index = documentModel->indexOfFilePath(filePath);
- if (index < 0 || !documentModel->documents().at(index)->document)
- return;
- QList<IEditor *> editors = documentModel->editorsForDocument(
- documentModel->documents().at(index)->document);
+ QList<IEditor *> editors = EditorManager::documentModel()->editorsForFilePath(filePath);
// set up the format for the errors
QTextCharFormat errorFormat;