Use document instead of widget in TextEditor::RefactoringChangesData

Change-Id: I938041c9774fbebd1edc6dc29ccfa569bae94f70
Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
This commit is contained in:
Eike Ziller
2014-01-17 14:59:20 +01:00
parent 7be1f1064e
commit dcba4a2715
6 changed files with 22 additions and 19 deletions

View File

@@ -51,10 +51,10 @@ public:
virtual void indentSelection(const QTextCursor &selection,
const QString &fileName,
const TextEditor::BaseTextEditorWidget *textEditor) const
const TextEditor::BaseTextDocument *textDocument) const
{
const TextEditor::TabSettings &tabSettings =
ProjectExplorer::actualTabSettings(fileName, textEditor);
ProjectExplorer::actualTabSettings(fileName, textDocument);
CppQtStyleIndenter indenter;
indenter.indent(selection.document(), selection, QChar::Null, tabSettings);
@@ -62,10 +62,10 @@ public:
virtual void reindentSelection(const QTextCursor &selection,
const QString &fileName,
const TextEditor::BaseTextEditorWidget *textEditor) const
const TextEditor::BaseTextDocument *textDocument) const
{
const TextEditor::TabSettings &tabSettings =
ProjectExplorer::actualTabSettings(fileName, textEditor);
ProjectExplorer::actualTabSettings(fileName, textDocument);
CppQtStyleIndenter indenter;
indenter.reindent(selection.document(), selection, tabSettings);