Cleanup r40377

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@40379 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Vincent van Ravesteijn 2011-12-05 13:41:15 +00:00
parent 467c955507
commit 7d98d770b1
2 changed files with 3 additions and 8 deletions

View File

@ -1036,13 +1036,12 @@ bool BufferView::getStatus(FuncRequest const & cmd, FuncStatus & flag)
break;
case LFUN_FILE_INSERT_PLAINTEXT_PARA:
case LFUN_FILE_INSERT_PLAINTEXT: {
bool enabled = true;
docstring const fname = cmd.argument();
if (!FileName::isAbsolute(to_utf8(fname))) {
flag.message(_("Absolute filename expected."));
return false;
}
flag.setEnabled(enabled && cur.inTexted());
flag.setEnabled(cur.inTexted());
break;
}
case LFUN_FILE_INSERT:

View File

@ -1868,13 +1868,9 @@ bool GuiView::getStatus(FuncRequest const & cmd, FuncStatus & flag)
break;
case LFUN_FILE_INSERT_PLAINTEXT:
case LFUN_FILE_INSERT_PLAINTEXT_PARA: {
if (BufferView const * bv = documentBufferView())
enable = bv->cursor().inTexted();
else
enable = false;
case LFUN_FILE_INSERT_PLAINTEXT_PARA:
enable = documentBufferView() && documentBufferView()->cursor().inTexted();
break;
}
default:
return false;