Skip to content
Snippets Groups Projects
Commit 5467fc25 authored by Marco Bubke's avatar Marco Bubke
Browse files

Clang: Make ClangAssistProposalModel members private


Change-Id: Ib8089f4afdb72840d97e5286d8be631387e4d2c5
Reviewed-by: default avatarNikolai Kosjar <nikolai.kosjar@theqtcompany.com>
parent ed27414f
No related branches found
No related tags found
No related merge requests found
......@@ -37,13 +37,12 @@ namespace Internal {
ClangAssistProposal::ClangAssistProposal(int cursorPos, TextEditor::GenericProposalModel *model)
: GenericProposal(cursorPos, model)
, m_replaceDotForArrow(static_cast<ClangAssistProposalModel *>(model)->m_replaceDotForArrow)
{
}
bool ClangAssistProposal::isCorrective() const
{
return m_replaceDotForArrow;
return ClangAssistProposalModel::replaceDotForArrow(model());
}
void ClangAssistProposal::makeCorrection(TextEditor::TextEditorWidget *editorWidget)
......
......@@ -44,6 +44,13 @@ const ClangAssistProposalItem &toClangAssistProposalItem(TextEditor::AssistPropo
}
bool ClangAssistProposalModel::replaceDotForArrow(TextEditor::IAssistProposalModel *model)
{
auto clangAssistProposalModel = static_cast<ClangAssistProposalModel*>(model);
return clangAssistProposalModel->m_replaceDotForArrow;
}
bool ClangAssistProposalModel::isSortable(const QString &/*prefix*/) const
{
return true;
......
......@@ -49,6 +49,9 @@ public:
bool isSortable(const QString &prefix) const override;
static bool replaceDotForArrow(IAssistProposalModel *model);
private:
bool m_sortable;
unsigned m_completionOperator;
bool m_replaceDotForArrow;
......
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