forked from qt-creator/qt-creator
EditorManager: Add OpenEditorFlags to openEditorWithContents
This requires moving the activateEditor call into openEditorWithContents. Remove that line elsewhere when editors are constructed. Keep it when reusing an existing editor though. Change-Id: I872f03e16fde42f3b8adec2cf2344b7cc495cd08 Reviewed-by: Eike Ziller <eike.ziller@digia.com>
This commit is contained in:
committed by
Eike Ziller
parent
d52ee686d1
commit
c9b6897e78
@@ -120,10 +120,10 @@ void SourceAgent::setContent(const QString &filePath, const QString &content)
|
||||
qobject_cast<BaseTextEditorWidget *>(d->editor->widget());
|
||||
if (baseTextEdit)
|
||||
baseTextEdit->setRequestMarkEnabled(true);
|
||||
} else {
|
||||
EditorManager::activateEditor(d->editor);
|
||||
}
|
||||
|
||||
EditorManager::activateEditor(d->editor);
|
||||
|
||||
QPlainTextEdit *plainTextEdit =
|
||||
qobject_cast<QPlainTextEdit *>(d->editor->widget());
|
||||
QTC_ASSERT(plainTextEdit, return);
|
||||
|
||||
Reference in New Issue
Block a user