forked from qt-creator/qt-creator
IDocument: Rename defaultPath and suggestedFileName
To fallbackSaveAsPath and fallbackSaveAsFileName. That makes it clearer what they are for, and that they actually belong to each other. Change-Id: Ie5b83b9db77d39a7fe9e979cc8f22b7f5b9101a3 Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
This commit is contained in:
@@ -559,7 +559,7 @@ static bool saveModifiedFilesHelper(const QList<IDocument *> &documents,
|
||||
if (document && document->isModified()) {
|
||||
QString name = document->filePath().toString();
|
||||
if (name.isEmpty())
|
||||
name = document->suggestedFileName();
|
||||
name = document->fallbackSaveAsFileName();
|
||||
|
||||
// There can be several IDocuments pointing to the same file
|
||||
// Prefer one that is not readonly
|
||||
@@ -719,8 +719,8 @@ QString DocumentManager::getSaveAsFileName(const IDocument *document, const QStr
|
||||
QString path;
|
||||
QString fileName;
|
||||
if (absoluteFilePath.isEmpty()) {
|
||||
fileName = document->suggestedFileName();
|
||||
const QString defaultPath = document->defaultPath();
|
||||
fileName = document->fallbackSaveAsFileName();
|
||||
const QString defaultPath = document->fallbackSaveAsPath();
|
||||
if (!defaultPath.isEmpty())
|
||||
path = defaultPath;
|
||||
} else {
|
||||
|
Reference in New Issue
Block a user