Skip to content

Commit

Permalink
Gui: [skip ci] avoid adding a wrong file name to the recent files list
Browse files Browse the repository at this point in the history
  • Loading branch information
wwmayer committed Dec 18, 2020
1 parent 8462fc1 commit 126c584
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Gui/Document.cpp
Expand Up @@ -1189,6 +1189,8 @@ bool Document::saveAs(void)
escapedstr = Base::Tools::escapeEncodeFilename(escapedstr);
Command::doCommand(Command::Doc,"App.getDocument(\"%s\").saveAs(u\"%s\")"
, DocName, escapedstr.c_str());
// App::Document::saveAs() may modify the passed file name
fi.setFile(QString::fromUtf8(d->_pcDocument->FileName.getValue()));
setModified(false);
getMainWindow()->appendRecentFile(fi.filePath());
}
Expand Down

0 comments on commit 126c584

Please sign in to comment.