mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-26 19:25:39 +00:00
Fix bug #7090 (Segfault in refreshing instant preview when math macro changes)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@36832 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
7ba8c1d542
commit
14cbb6cb3d
@ -721,11 +721,11 @@ void MathMacroTemplate::changeArity(Cursor & cur,
|
||||
{
|
||||
// remove parameter which do not appear anymore in the definition
|
||||
for (int i = numargs_; i > newNumArg; --i)
|
||||
removeParameter(cur, inset_pos, numargs_ - 1, false);
|
||||
removeParameter(cur, inset_pos, numargs_ - 1, true);
|
||||
|
||||
// add missing parameter
|
||||
for (int i = numargs_; i < newNumArg; ++i)
|
||||
insertParameter(cur, inset_pos, numargs_, false, false);
|
||||
insertParameter(cur, inset_pos, numargs_, true, false);
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user