From f7afcc31feaff19fcc97ffe45453e450218ae31d Mon Sep 17 00:00:00 2001 From: Jean-Marc Lasgouttes Date: Fri, 21 Apr 2023 14:42:51 +0200 Subject: [PATCH] Fix undo with cell-plit This function modifies several cells. Fixes bug #12746. --- src/mathed/InsetMathGrid.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/mathed/InsetMathGrid.cpp b/src/mathed/InsetMathGrid.cpp index 65cd6621be..3adec0ca2b 100644 --- a/src/mathed/InsetMathGrid.cpp +++ b/src/mathed/InsetMathGrid.cpp @@ -1413,7 +1413,8 @@ void InsetMathGrid::doDispatch(Cursor & cur, FuncRequest & cmd) break; case LFUN_CELL_SPLIT: - cur.recordUndo(); + // undo needs to cover two cells + cur.recordUndoInset(); splitCell(cur); break; -- 2.39.5