forked from qt-creator/qt-creator
Move IEditor::createNew to IDocument::setContents
The method is for setting the contents, so it belongs to the document, and should be named correspondingly. Change-Id: I40363dc08f11268f530885b512e4a88e8b10d096 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Eike Ziller <eike.ziller@digia.com>
This commit is contained in:
@@ -57,6 +57,18 @@ IDocument::~IDocument()
|
||||
delete m_infoBar;
|
||||
}
|
||||
|
||||
/*!
|
||||
Used for example by EditorManager::openEditorWithContents() to set the contents
|
||||
of this document.
|
||||
Returns if setting the contents was successful.
|
||||
The base implementation does nothing and returns false.
|
||||
*/
|
||||
bool IDocument::setContents(const QByteArray &contents)
|
||||
{
|
||||
Q_UNUSED(contents)
|
||||
return false;
|
||||
}
|
||||
|
||||
IDocument::ReloadBehavior IDocument::reloadBehavior(ChangeTrigger state, ChangeType type) const
|
||||
{
|
||||
if (type == TypePermissions)
|
||||
|
||||
Reference in New Issue
Block a user