diff options
author | Orgad Shaneh <orgad.shaneh@audiocodes.com> | 2015-02-26 08:42:05 +0200 |
---|---|---|
committer | Orgad Shaneh <orgads@gmail.com> | 2015-02-27 15:11:02 +0000 |
commit | 1a37605f919a761892cb4c4759265956e0efa453 (patch) | |
tree | 2e2868c1f096ea2c256be475b68fb8970d646cfb /src/plugins/cpptools/cppcompletionassist.h | |
parent | 2ffe50c208cd62db81ec0f0bb3354158ad4d2268 (diff) |
CppTools: Move languageFeatures around in CompletionAssist...
... from InternalCppCompletionAssistProcessor to CppCompletionAssistInterface
Change-Id: I769fd86a387f1087f37b56fe114bdf132f1b0be7
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
Diffstat (limited to 'src/plugins/cpptools/cppcompletionassist.h')
-rw-r--r-- | src/plugins/cpptools/cppcompletionassist.h | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/plugins/cpptools/cppcompletionassist.h b/src/plugins/cpptools/cppcompletionassist.h index 0b009e07ea..585d66eb0c 100644 --- a/src/plugins/cpptools/cppcompletionassist.h +++ b/src/plugins/cpptools/cppcompletionassist.h @@ -92,7 +92,7 @@ public: TextEditor::AssistInterface *createAssistInterface( const QString &filePath, QTextDocument *document, - bool isObjCEnabled, + const CPlusPlus::LanguageFeatures &languageFeatures, int position, TextEditor::AssistReason reason) const Q_DECL_OVERRIDE; }; @@ -162,7 +162,6 @@ private: CompleteQt5SlotTrigger }; - CPlusPlus::LanguageFeatures m_languageFeatures; QScopedPointer<const CppCompletionAssistInterface> m_interface; QScopedPointer<CppAssistProposalModel> m_model; }; @@ -172,14 +171,14 @@ class CppCompletionAssistInterface : public TextEditor::AssistInterface public: CppCompletionAssistInterface(const QString &filePath, QTextDocument *textDocument, - bool isObjCEnabled, + const CPlusPlus::LanguageFeatures &languageFeatures, int position, TextEditor::AssistReason reason, const WorkingCopy &workingCopy) : TextEditor::AssistInterface(textDocument, position, filePath, reason) - , m_isObjCEnabled(isObjCEnabled) , m_gotCppSpecifics(false) , m_workingCopy(workingCopy) + , m_languageFeatures(languageFeatures) {} CppCompletionAssistInterface(const QString &filePath, @@ -187,28 +186,29 @@ public: int position, TextEditor::AssistReason reason, const CPlusPlus::Snapshot &snapshot, - const ProjectPart::HeaderPaths &headerPaths) + const ProjectPart::HeaderPaths &headerPaths, + const CPlusPlus::LanguageFeatures &features) : TextEditor::AssistInterface(textDocument, position, filePath, reason) - , m_isObjCEnabled(false) , m_gotCppSpecifics(true) , m_snapshot(snapshot) , m_headerPaths(headerPaths) + , m_languageFeatures(features) {} - bool isObjCEnabled() const { return m_isObjCEnabled; } - const CPlusPlus::Snapshot &snapshot() const { getCppSpecifics(); return m_snapshot; } const ProjectPart::HeaderPaths &headerPaths() const { getCppSpecifics(); return m_headerPaths; } + CPlusPlus::LanguageFeatures languageFeatures() const + { getCppSpecifics(); return m_languageFeatures; } private: void getCppSpecifics() const; - mutable bool m_isObjCEnabled; mutable bool m_gotCppSpecifics; WorkingCopy m_workingCopy; mutable CPlusPlus::Snapshot m_snapshot; mutable ProjectPart::HeaderPaths m_headerPaths; + mutable CPlusPlus::LanguageFeatures m_languageFeatures; }; } // Internal |