forked from qt-creator/qt-creator
Core: Avoid copy in IDocument::filePath()
Change-Id: I40d5ebc73856e85e36080b94e071edef15242666 Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
This commit is contained in:
committed by
Orgad Shaneh
parent
a5c0b56832
commit
c273a47dcb
@@ -129,7 +129,7 @@ bool IDocument::setContents(const QByteArray &contents)
|
||||
return false;
|
||||
}
|
||||
|
||||
Utils::FileName IDocument::filePath() const
|
||||
const Utils::FileName &IDocument::filePath() const
|
||||
{
|
||||
return d->filePath;
|
||||
}
|
||||
|
@@ -89,7 +89,7 @@ public:
|
||||
virtual bool save(QString *errorString, const QString &fileName = QString(), bool autoSave = false) = 0;
|
||||
virtual bool setContents(const QByteArray &contents);
|
||||
|
||||
Utils::FileName filePath() const;
|
||||
const Utils::FileName &filePath() const;
|
||||
virtual void setFilePath(const Utils::FileName &filePath);
|
||||
QString displayName() const;
|
||||
void setPreferredDisplayName(const QString &name);
|
||||
|
Reference in New Issue
Block a user