forked from qt-creator/qt-creator
TextEditor: Fix requesting more proposals than needed
Since
commit d61d29cf16
Introduce a basic client for the language server protocol
extra proprosals were requested in the fragile case on a change
notification, e.g. for function signature completion. Restrict this to
the language client proposal, as it was actually intended.
The language client does not support prefixes, so introduce this concept
for deciding whether to request new proposals or not.
Done-with: David Schulz
Change-Id: Ibc1ad82dbeeea93b85f279c59b8c7289fe6ec726
Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
@@ -90,6 +90,11 @@ bool IAssistProposal::isFragile() const
|
||||
return m_isFragile;
|
||||
}
|
||||
|
||||
bool IAssistProposal::supportsPrefix() const
|
||||
{
|
||||
return m_supportsPrefix;
|
||||
}
|
||||
|
||||
/*!
|
||||
\fn bool TextEditor::IAssistProposal::isCorrective() const
|
||||
|
||||
@@ -120,6 +125,11 @@ void IAssistProposal::setFragile(bool fragile)
|
||||
m_isFragile = fragile;
|
||||
}
|
||||
|
||||
void IAssistProposal::setSupportsPrefix(bool supportsPrefix)
|
||||
{
|
||||
m_supportsPrefix = supportsPrefix;
|
||||
}
|
||||
|
||||
/*!
|
||||
\fn IAssistModel *TextEditor::IAssistProposal::model() const
|
||||
|
||||
|
||||
Reference in New Issue
Block a user