forked from qt-creator/qt-creator
Make IDocument::fileName a member with setter.
Instead of requiring subclasses to implement a method. Also renames IDocument::rename to IDocument::setFileName, since it doesn't really rename any files or such. Change-Id: I1344025c24d2f74a6a983e04fb0a5245f1f37aad Reviewed-by: Daniel Teske <daniel.teske@digia.com> Reviewed-by: Eike Ziller <eike.ziller@digia.com>
This commit is contained in:
@@ -48,7 +48,6 @@ public:
|
||||
explicit DiffEditorFile(const QString &mimeType,
|
||||
QObject *parent = 0);
|
||||
|
||||
QString fileName() const { return m_fileName; }
|
||||
QString defaultPath() const { return QString(); }
|
||||
QString suggestedFileName() const { return QString(); }
|
||||
|
||||
@@ -58,9 +57,7 @@ public:
|
||||
bool save(QString *errorString, const QString &fileName, bool autoSave);
|
||||
ReloadBehavior reloadBehavior(ChangeTrigger state, ChangeType type) const;
|
||||
bool reload(QString *errorString, ReloadFlag flag, ChangeType type);
|
||||
void rename(const QString &newName);
|
||||
|
||||
void setFileName(const QString &name);
|
||||
void setModified(bool modified = true);
|
||||
|
||||
signals:
|
||||
@@ -69,7 +66,6 @@ signals:
|
||||
private:
|
||||
const QString m_mimeType;
|
||||
bool m_modified;
|
||||
QString m_fileName;
|
||||
};
|
||||
|
||||
} // namespace Internal
|
||||
|
||||
Reference in New Issue
Block a user