From b0a3273bac30aac9ec7d36fd854c4fbcd99039ac Mon Sep 17 00:00:00 2001 From: Jean-Marc Lasgouttes Date: Thu, 18 Sep 2008 13:44:54 +0000 Subject: [PATCH] BufferView::mouseDispatch: make sure to create an undo group git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@26440 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/BufferView.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/BufferView.cpp b/src/BufferView.cpp index 42420b92d1..b2e21ba79d 100644 --- a/src/BufferView.cpp +++ b/src/BufferView.cpp @@ -1617,6 +1617,8 @@ void BufferView::mouseEventDispatch(FuncRequest const & cmd0) // Put anchor at the same position. cur.resetAnchor(); + cur.beginUndoGroup(); + // Try to dispatch to an non-editable inset near this position // via the temp cursor. If the inset wishes to change the real // cursor it has to do so explicitly by using @@ -1629,6 +1631,8 @@ void BufferView::mouseEventDispatch(FuncRequest const & cmd0) if (!inset || !cur.result().dispatched()) cur.dispatch(cmd); + cur.endUndoGroup(); + // Notify left insets if (cur != old) { old.fixIfBroken(); -- 2.39.5