mirror of
https://git.lyx.org/repos/lyx.git
synced 2025-01-09 18:52:46 +00:00
Small simplification
This commit is contained in:
parent
8bbd4c5e58
commit
2662386077
@ -2436,12 +2436,7 @@ bool GuiView::saveBuffer(Buffer & b, FileName const & fn)
|
|||||||
if (fn.empty() && b.isUnnamed())
|
if (fn.empty() && b.isUnnamed())
|
||||||
return renameBuffer(b, docstring());
|
return renameBuffer(b, docstring());
|
||||||
|
|
||||||
bool success;
|
bool const success = (fn.empty() ? b.save() : b.saveAs(fn));
|
||||||
if (fn.empty())
|
|
||||||
success = b.save();
|
|
||||||
else
|
|
||||||
success = b.saveAs(fn);
|
|
||||||
|
|
||||||
if (success) {
|
if (success) {
|
||||||
theSession().lastFiles().add(b.fileName());
|
theSession().lastFiles().add(b.fileName());
|
||||||
return true;
|
return true;
|
||||||
|
Loading…
Reference in New Issue
Block a user