diff options
author | Ulf Hermann <ulf.hermann@qt.io> | 2017-01-30 14:59:10 +0100 |
---|---|---|
committer | Ulf Hermann <ulf.hermann@qt.io> | 2017-01-30 15:34:46 +0000 |
commit | c70b689526bc2f7b9d48a8822b080489d3d0c975 (patch) | |
tree | 11203dcd3de38ecffe9c6996e4385fe566f24971 /src/plugins/qmljstools/qmljsmodelmanager.cpp | |
parent | 1dd407736a95fe5dfe982170f48b1e6cd74a8b32 (diff) |
Unify projectexplorer language IDs
We don't need two IDs for C++ and the QmlJS ID should look the same as
as the others.
Change-Id: Ib9747f6b36a90bb652951d85eec69666615670c4
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
Diffstat (limited to 'src/plugins/qmljstools/qmljsmodelmanager.cpp')
-rw-r--r-- | src/plugins/qmljstools/qmljsmodelmanager.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/plugins/qmljstools/qmljsmodelmanager.cpp b/src/plugins/qmljstools/qmljsmodelmanager.cpp index 1858c286313..16d15038796 100644 --- a/src/plugins/qmljstools/qmljsmodelmanager.cpp +++ b/src/plugins/qmljstools/qmljsmodelmanager.cpp @@ -257,8 +257,11 @@ ModelManagerInterface::WorkingCopy ModelManager::workingCopyInternal() const const QString key = document->filePath().toString(); if (TextEditor::TextDocument *textDocument = qobject_cast<TextEditor::TextDocument *>(document)) { // TODO the language should be a property on the document, not the editor - if (DocumentModel::editorsForDocument(document).first()->context().contains(ProjectExplorer::Constants::LANG_QMLJS)) - workingCopy.insert(key, textDocument->plainText(), textDocument->document()->revision()); + if (DocumentModel::editorsForDocument(document).first() + ->context().contains(ProjectExplorer::Constants::QMLJS_LANGUAGE_ID)) { + workingCopy.insert(key, textDocument->plainText(), + textDocument->document()->revision()); + } } } |