diff --git a/src/mathed/ChangeLog b/src/mathed/ChangeLog index 9d148cedd4..5df4fb4dc5 100644 --- a/src/mathed/ChangeLog +++ b/src/mathed/ChangeLog @@ -1,3 +1,8 @@ +2005-10-03 Jürgen Spitzmüller + + * math_nestinset.C (doDispatch): use recordUndoInset when deleting whole + cell via LFUN_BACKSPACE (fixes bug 2058). + 2005-09-27 Jürgen Spitzmüller * math_nestinset.C (doDispatch): leave inset to the right when hitting ESC. diff --git a/src/mathed/math_nestinset.C b/src/mathed/math_nestinset.C index 3f1e5a808c..136d9529c2 100644 --- a/src/mathed/math_nestinset.C +++ b/src/mathed/math_nestinset.C @@ -614,7 +614,11 @@ void MathNestInset::doDispatch(LCursor & cur, FuncRequest & cmd) case LFUN_DELETE_WORD_BACKWARD: case LFUN_BACKSPACE: - recordUndo(cur, Undo::ATOMIC); + if (cur.pos() == 0) + // delete whole cell + recordUndoInset(cur, Undo::ATOMIC); + else + recordUndo(cur, Undo::ATOMIC); cur.backspace(); break;