forked from qt-creator/qt-creator
QuickFix: Move helpers from QuickFixData to RefactoringFile.
Makes them easy to use everywhere. Also when calling QuickFixData::textOf and friends, it wasn't really clear which file they would run on.
This commit is contained in:
@@ -103,6 +103,14 @@ CppRefactoringFile::CppRefactoringFile(const QString &fileName, CppRefactoringCh
|
||||
: RefactoringFile(fileName, refactoringChanges)
|
||||
{ }
|
||||
|
||||
CppRefactoringFile::CppRefactoringFile(TextEditor::BaseTextEditor *editor, CPlusPlus::Document::Ptr document)
|
||||
: RefactoringFile()
|
||||
, m_cppDocument(document)
|
||||
{
|
||||
m_fileName = document->fileName();
|
||||
m_editor = editor;
|
||||
}
|
||||
|
||||
Document::Ptr CppRefactoringFile::cppDocument() const
|
||||
{
|
||||
if (!m_cppDocument) {
|
||||
|
||||
Reference in New Issue
Block a user