disable save when document is clean (bug 2313)

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13389 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Jean-Marc Lasgouttes 2006-03-16 13:12:40 +00:00
parent e16b61096d
commit 9ab55cbeb7
2 changed files with 10 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2006-03-16 John Spray <spray@lyx.org>
* lyxfunc.C (getStatus): disable LFUN_MENUWRITE when document is
clean (bug 2313)
2006-03-15 Martin Vermeer <martin.vermeer@hut.fi> 2006-03-15 Martin Vermeer <martin.vermeer@hut.fi>
* CutAndPaste.C (pasteSelectionHelper): comments * CutAndPaste.C (pasteSelectionHelper): comments

View File

@ -540,6 +540,11 @@ FuncStatus LyXFunc::getStatus(FuncRequest const & cmd) const
break; break;
} }
case LFUN_MENUWRITE: {
enable = !view()->buffer()->isClean();
break;
}
// this one is difficult to get right. As a half-baked // this one is difficult to get right. As a half-baked
// solution, we consider only the first action of the sequence // solution, we consider only the first action of the sequence
case LFUN_SEQUENCE: { case LFUN_SEQUENCE: {
@ -559,7 +564,6 @@ FuncStatus LyXFunc::getStatus(FuncRequest const & cmd) const
case LFUN_CANCEL: case LFUN_CANCEL:
case LFUN_META_FAKE: case LFUN_META_FAKE:
case LFUN_CLOSEBUFFER: case LFUN_CLOSEBUFFER:
case LFUN_MENUWRITE:
case LFUN_WRITEAS: case LFUN_WRITEAS:
case LFUN_UPDATE: case LFUN_UPDATE:
case LFUN_PREVIEW: case LFUN_PREVIEW: