Clang: use local renaming based on ClangCodeModel

Provide refactoring engine for ClangCodeModel and
implement missing methods.

Change-Id: If5c913e0c5a7941cd2ced54d0fcfa4d625eadc93
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
This commit is contained in:
Ivan Donchevskii
2017-09-26 16:00:30 +02:00
parent 94e818dc82
commit 32bae7ef6c
30 changed files with 275 additions and 21 deletions

View File

@@ -42,7 +42,10 @@ QT_END_NAMESPACE
namespace Core { class IDocument; }
namespace TextEditor { class TextEditorWidget; }
namespace CppTools { class FollowSymbolInterface; }
namespace CppTools {
class FollowSymbolInterface;
class RefactoringEngineInterface;
} // namespace CppTools
namespace ClangCodeModel {
namespace Internal {
@@ -61,6 +64,7 @@ public:
CppTools::BaseEditorDocumentProcessor *editorDocumentProcessor(
TextEditor::TextDocument *baseTextDocument) override;
CppTools::FollowSymbolInterface &followSymbolInterface() override;
CppTools::RefactoringEngineInterface &refactoringEngineInterface() override;
BackendCommunicator &communicator();
QString dummyUiHeaderOnDiskDirPath() const;
@@ -105,6 +109,7 @@ private:
BackendCommunicator m_communicator;
ClangCompletionAssistProvider m_completionAssistProvider;
std::unique_ptr<CppTools::FollowSymbolInterface> m_followSymbol;
std::unique_ptr<CppTools::RefactoringEngineInterface> m_refactoringEngine;
};
class ModelManagerSupportProviderClang : public CppTools::ModelManagerSupportProvider