From c234df7779b0e43e4433e71933c22f9e703da735 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Wed, 27 Jul 2011 14:49:41 +0100 Subject: Resolves: fdo#36631 don't crash on undo of ole2 insert --- sw/source/core/doc/doclay.cxx | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/sw/source/core/doc/doclay.cxx b/sw/source/core/doc/doclay.cxx index 66a7af4b0c..c4d348aa0b 100644 --- a/sw/source/core/doc/doclay.cxx +++ b/sw/source/core/doc/doclay.cxx @@ -473,7 +473,12 @@ SwFrmFmt *SwDoc::CopyLayoutFmt( const SwFrmFmt& rSource, // sorge dafuer das auch Fly's in Fly's kopiert werden aIdx = *pSttNd->EndOfSectionNode(); + bool bDrawingLayerUndoState = GetIDocumentUndoRedo().DoesDrawUndo(); + //fdo#36631 disable any undo operations associated with the contact + //object itself. They should be managed by SwUndoInsLayFmt. + GetIDocumentUndoRedo().DoDrawUndo(false); pSrcDoc->CopyWithFlyInFly( aRg, 0, aIdx, sal_False, sal_True, sal_True ); + GetIDocumentUndoRedo().DoDrawUndo(bDrawingLayerUndoState); } else { -- cgit v1.2.3