Fix bug 5751.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28554 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Richard Heck 2009-02-19 04:18:31 +00:00
parent 45134ce20b
commit e2d20d4386

View File

@ -369,7 +369,13 @@ void InsetNote::string2params(string const & in, InsetNoteParams & params)
Lexer lex; Lexer lex;
lex.setStream(data); lex.setStream(data);
lex.setContext("InsetNote::string2params"); lex.setContext("InsetNote::string2params");
lex >> "note" >> "Note"; lex >> "note";
// There are cases, such as when we are called via getStatus() from
// Dialog::canApply(), where we are just called with "note" rather
// than a full "note Note TYPE".
if (!lex.isOK())
return;
lex >> "Note";
params.read(lex); params.read(lex);
} }