forked from qt-creator/qt-creator
use IEditor::widget() instead of BaseTextEditor::editorWidget() when possible
This commit is contained in:
@@ -64,7 +64,7 @@ Core::Context CMakeEditor::context() const
|
||||
|
||||
Core::IEditor *CMakeEditor::duplicate(QWidget *parent)
|
||||
{
|
||||
CMakeEditorWidget *w = qobject_cast<CMakeEditorWidget*>(editorWidget());
|
||||
CMakeEditorWidget *w = qobject_cast<CMakeEditorWidget*>(widget());
|
||||
CMakeEditorWidget *ret = new CMakeEditorWidget(parent, w->factory(), w->actionHandler());
|
||||
ret->duplicateFrom(w);
|
||||
TextEditor::TextEditorSettings::instance()->initializeEditor(ret);
|
||||
|
||||
Reference in New Issue
Block a user