Skip to content
Snippets Groups Projects
Commit 02cc2177 authored by Christian Kamm's avatar Christian Kamm
Browse files

QmlJS: Add completion for "id:".

parent 45415783
No related branches found
No related tags found
No related merge requests found
...@@ -716,6 +716,12 @@ int CodeCompletion::startCompletion(TextEditor::ITextEditable *editor) ...@@ -716,6 +716,12 @@ int CodeCompletion::startCompletion(TextEditor::ITextEditable *editor)
enumerateProperties.setGlobalCompletion(true); enumerateProperties.setGlobalCompletion(true);
enumerateProperties.setEnumerateGeneratedSlots(true); enumerateProperties.setEnumerateGeneratedSlots(true);
// id: is special
TextEditor::CompletionItem idPropertyCompletion(this);
idPropertyCompletion.text = QLatin1String("id: ");
idPropertyCompletion.icon = symbolIcon;
m_completions.append(idPropertyCompletion);
addCompletionsPropertyLhs(enumerateProperties(qmlScopeType), symbolIcon); addCompletionsPropertyLhs(enumerateProperties(qmlScopeType), symbolIcon);
addCompletions(enumerateProperties(context.scopeChain().qmlTypes), symbolIcon); addCompletions(enumerateProperties(context.scopeChain().qmlTypes), symbolIcon);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment