mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-23 02:14:50 +00:00
A better fix for bug 675:
http://bugzilla.lyx.org/show_bug.cgi?id=675 The former one also disabled cross-reference insertion. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17008 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
bda886f39e
commit
969ab85d98
@ -199,10 +199,14 @@ bool InsetCaption::getStatus(LCursor & cur, FuncRequest const & cmd,
|
||||
status.enabled(false);
|
||||
return true;
|
||||
|
||||
case LFUN_DIALOG_SHOW_NEW_INSET:
|
||||
case LFUN_INSET_INSERT: {
|
||||
string const name = cmd.getArg(0);
|
||||
if (name == "graphics"
|
||||
|| name == "include") {
|
||||
if (name == "float"
|
||||
|| name == "graphics"
|
||||
|| name == "include"
|
||||
|| name == "wrap"
|
||||
) {
|
||||
status.enabled(false);
|
||||
return true;
|
||||
}
|
||||
|
@ -576,8 +576,12 @@ FuncStatus LyXFunc::getStatus(FuncRequest const & cmd) const
|
||||
}
|
||||
|
||||
case LFUN_DIALOG_SHOW_NEW_INSET:
|
||||
enable = cur.inset().lyxCode() != InsetBase::ERT_CODE
|
||||
&& cur.inset().lyxCode() != InsetBase::CAPTION_CODE;
|
||||
enable = cur.inset().lyxCode() != InsetBase::ERT_CODE;
|
||||
if (cur.inset().lyxCode() == InsetBase::CAPTION_CODE) {
|
||||
FuncStatus flag;
|
||||
if (cur.inset().getStatus(cur, cmd, flag))
|
||||
return flag;
|
||||
}
|
||||
break;
|
||||
|
||||
case LFUN_DIALOG_UPDATE: {
|
||||
|
Loading…
Reference in New Issue
Block a user