Call Buffer::saveCheckSum() from Buffer::setFileName(). This fixes the bug that if the user wants to overwrite an already existing file, LyX asks whether he want to overwrite the existing file _and_ whether he wants to overwrite an externally modified file.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@36376 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Vincent van Ravesteijn 2010-11-18 17:56:00 +00:00
parent 1f38406536
commit b3d7a10410

View File

@ -646,6 +646,7 @@ void Buffer::setFileName(FileName const & fname)
{
d->filename = fname;
setReadonly(d->filename.isReadOnly());
saveCheckSum();
updateTitles();
}
@ -4166,7 +4167,6 @@ bool Buffer::saveAs(FileName const & fn)
// reset the old filename and unnamed state
setFileName(old_name);
setUnnamed(old_unnamed);
saveCheckSum();
return false;
}
}