forked from qt-creator/qt-creator
TextEditor: Move more code into RefactoringFile
We want to get rid of RefactoringChangesData. Change-Id: Ia428563a0ff70ec9660761beac3eb7168b8e9eca Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
@@ -73,9 +73,7 @@
|
||||
#include <QRegularExpression>
|
||||
|
||||
#include <cmath>
|
||||
#include <new>
|
||||
#include <optional>
|
||||
#include <set>
|
||||
#include <unordered_map>
|
||||
#include <utility>
|
||||
|
||||
@@ -770,10 +768,9 @@ QList<Text::Range> ClangdClient::additionalDocumentHighlights(
|
||||
qobject_cast<CppEditor::CppEditorWidget *>(editorWidget), cursor);
|
||||
}
|
||||
|
||||
RefactoringChangesData *ClangdClient::createRefactoringChangesBackend() const
|
||||
RefactoringFilePtr ClangdClient::createRefactoringFile(const FilePath &filePath) const
|
||||
{
|
||||
return new CppEditor::CppRefactoringChangesData(
|
||||
CppEditor::CppModelManager::snapshot());
|
||||
return CppEditor::CppRefactoringChanges(CppEditor::CppModelManager::snapshot()).file(filePath);
|
||||
}
|
||||
|
||||
QVersionNumber ClangdClient::versionNumber() const
|
||||
|
||||
@@ -141,7 +141,8 @@ private:
|
||||
QTextCursor adjustedCursorForHighlighting(const QTextCursor &cursor,
|
||||
TextEditor::TextDocument *doc) override;
|
||||
const CustomInspectorTabs createCustomInspectorTabs() override;
|
||||
TextEditor::RefactoringChangesData *createRefactoringChangesBackend() const override;
|
||||
TextEditor::RefactoringFilePtr createRefactoringFile(
|
||||
const Utils::FilePath &filePath) const override;
|
||||
LanguageClient::DiagnosticManager *createDiagnosticManager() override;
|
||||
LanguageClient::LanguageClientOutlineItem *createOutlineItem(
|
||||
const LanguageServerProtocol::DocumentSymbol &symbol) override;
|
||||
|
||||
Reference in New Issue
Block a user