CppTools: Break TextDocument dependency of BaseEditorDocumentProcessor

BaseEditorDocumentProcessor was holding a TextEditor::TextDocument but
only used the QTextDocument and the file path.

Change-Id: I349cc95d973adeaf9f94638d84333f592c14e7f9
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
This commit is contained in:
Marco Bubke
2016-01-11 20:40:05 +01:00
parent 369b1f7f38
commit 0fca74d501
4 changed files with 14 additions and 19 deletions

View File

@@ -45,9 +45,10 @@ namespace CppTools {
semantic calculations) after a text document has changed.
*/
BaseEditorDocumentProcessor::BaseEditorDocumentProcessor(
TextEditor::TextDocument *document)
: m_baseTextDocument(document)
BaseEditorDocumentProcessor::BaseEditorDocumentProcessor(QTextDocument *textDocument,
const QString &filePath)
: m_filePath(filePath),
m_textDocument(textDocument)
{
}
@@ -55,11 +56,6 @@ BaseEditorDocumentProcessor::~BaseEditorDocumentProcessor()
{
}
TextEditor::TextDocument *BaseEditorDocumentProcessor::baseTextDocument() const
{
return m_baseTextDocument;
}
TextEditor::QuickFixOperations
BaseEditorDocumentProcessor::extraRefactoringOperations(const TextEditor::AssistInterface &)
{