[Libreoffice-commits] core.git: Branch 'libreoffice-6-3' - sd/qa

2019-10-29 Thread Tamas Bunth (via logerrit)
 sd/qa/unit/data/pptx/tdf126324.pptx |binary
 sd/qa/unit/import-tests.cxx |   17 +
 2 files changed, 17 insertions(+)

New commits:
commit bf10253dd556b69fa771320c986c05c653e6d220
Author: Tamas Bunth 
AuthorDate: Tue Oct 29 14:53:05 2019 +0100
Commit: Caolán McNamara 
CommitDate: Tue Oct 29 21:15:37 2019 +0100

tdf#126324 pptx unit test for custom date import

Add unit test for importing custom date field ( element of type
"datetime")

Change-Id: Ifcb5641c99eeb79afe54b801750e68792880c000
Reviewed-on: https://gerrit.libreoffice.org/81684
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/sd/qa/unit/data/pptx/tdf126324.pptx 
b/sd/qa/unit/data/pptx/tdf126324.pptx
new file mode 100644
index ..d5540cdc4de4
Binary files /dev/null and b/sd/qa/unit/data/pptx/tdf126324.pptx differ
diff --git a/sd/qa/unit/import-tests.cxx b/sd/qa/unit/import-tests.cxx
index f083b38bbc58..1d1f5a6a46d1 100644
--- a/sd/qa/unit/import-tests.cxx
+++ b/sd/qa/unit/import-tests.cxx
@@ -195,6 +195,7 @@ public:
 void testTdf116899();
 void testTdf77747();
 void testTdf116266();
+void testTdf126324();
 
 bool checkPattern(sd::DrawDocShellRef const & rDocRef, int nShapeNumber, 
std::vector& rExpected);
 void testPatternImport();
@@ -287,6 +288,7 @@ public:
 CPPUNIT_TEST(testTdf114913);
 CPPUNIT_TEST(testTdf114821);
 CPPUNIT_TEST(testTdf115394);
+CPPUNIT_TEST(testTdf126324);
 CPPUNIT_TEST(testTdf115394PPT);
 CPPUNIT_TEST(testTdf51340);
 CPPUNIT_TEST(testTdf116899);
@@ -2749,6 +2751,21 @@ void SdImportTest::testTdf120028b()
 xDocShRef->DoClose();
 }
 
+void SdImportTest::testTdf126324()
+{
+sd::DrawDocShellRef xDocShRef
+= 
loadURL(m_directories.getURLFromSrc("/sd/qa/unit/data/pptx/tdf126324.pptx"), 
PPTX);
+uno::Reference 
xDoc(xDocShRef->GetDoc()->getUnoModel(),
+ uno::UNO_QUERY);
+CPPUNIT_ASSERT(xDoc.is());
+uno::Reference 
xPage(xDoc->getDrawPages()->getByIndex(0), uno::UNO_QUERY);
+CPPUNIT_ASSERT(xPage.is());
+uno::Reference xShape(getShape(0, xPage));
+CPPUNIT_ASSERT(xShape.is());
+uno::Reference< text::XText > xText = uno::Reference< text::XTextRange>( 
xShape, uno::UNO_QUERY_THROW )->getText();
+CPPUNIT_ASSERT_EQUAL(OUString{"17"}, xText->getString());
+}
+
 void SdImportTest::testDescriptionImport()
 {
 sd::DrawDocShellRef xDocShRef
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: Branch 'libreoffice-6-3' - sd/qa tools/source

2019-10-14 Thread Caolán McNamara (via logerrit)
 sd/qa/unit/data/ppt/pass/ofz14989-1.ppt |binary
 tools/source/zcodec/zcodec.cxx  |2 +-
 2 files changed, 1 insertion(+), 1 deletion(-)

New commits:
commit f77820ba5eab155b630b93a587de39c6d35e0052
Author: Caolán McNamara 
AuthorDate: Fri Oct 11 11:10:18 2019 +0100
Commit: Michael Stahl 
CommitDate: Mon Oct 14 12:22:46 2019 +0200

ofz#14989 Z_NEED_DICT related infinite loop

Change-Id: I31c0d004d717564063c36862f9eef661d18768a9
Reviewed-on: https://gerrit.libreoffice.org/80648
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 
Reviewed-on: https://gerrit.libreoffice.org/80715
Reviewed-by: Michael Stahl 

diff --git a/sd/qa/unit/data/ppt/pass/ofz14989-1.ppt 
b/sd/qa/unit/data/ppt/pass/ofz14989-1.ppt
new file mode 100644
index ..b470ebecdb49
Binary files /dev/null and b/sd/qa/unit/data/ppt/pass/ofz14989-1.ppt differ
diff --git a/tools/source/zcodec/zcodec.cxx b/tools/source/zcodec/zcodec.cxx
index ae1bc812c626..c03345b6934a 100644
--- a/tools/source/zcodec/zcodec.cxx
+++ b/tools/source/zcodec/zcodec.cxx
@@ -159,7 +159,7 @@ long ZCodec::Decompress( SvStream& rIStm, SvStream& rOStm )
 
 }
 err = mbStatus ? inflate(PZSTREAM, Z_NO_FLUSH) : Z_ERRNO;
-if ( err < 0 )
+if (err < 0 || err == Z_NEED_DICT)
 {
 mbStatus = false;
 break;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: Branch 'libreoffice-6-3' - sd/qa svx/source

2019-07-31 Thread Xisco Fauli (via logerrit)
 sd/qa/uitest/impress_tests/tdf126605.py |   28 
 svx/source/svdraw/svdedtv1.cxx  |2 --
 2 files changed, 28 insertions(+), 2 deletions(-)

New commits:
commit ab1b1167b52f2fe73da921eb73abc299b497d3c2
Author: Xisco Fauli 
AuthorDate: Tue Jul 30 15:51:58 2019 +0200
Commit: Miklos Vajna 
CommitDate: Wed Jul 31 15:22:43 2019 +0200

tdf#126605: Do not end TextEdit when changing an attribute

otherwise, pTextEditOutlinerView becomes nullptr in
svx/source/svdraw/svdedxv.cxx:2184

Regression from e6c7a018a0cfee395ce2886d41c908a2447ef5cc

Change-Id: I9d0645f637dc92b50d01682d119c0db60238e921
Reviewed-on: https://gerrit.libreoffice.org/76609
Tested-by: Jenkins
Reviewed-by: Xisco Faulí 
Reviewed-by: Miklos Vajna 

diff --git a/sd/qa/uitest/impress_tests/tdf126605.py 
b/sd/qa/uitest/impress_tests/tdf126605.py
new file mode 100644
index ..744324717a6b
--- /dev/null
+++ b/sd/qa/uitest/impress_tests/tdf126605.py
@@ -0,0 +1,28 @@
+# -*- tab-width: 4; indent-tabs-mode: nil; py-indent-offset: 4 -*-
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+
+from uitest.framework import UITestCase
+from libreoffice.uno.propertyvalue import mkPropertyValues
+
+class tdf126605(UITestCase):
+
+   def test_run(self):
+self.ui_test.create_doc_in_start_center("impress")
+xTemplateDlg = self.xUITest.getTopFocusWindow()
+xCancelBtn = xTemplateDlg.getChild("cancel")
+self.ui_test.close_dialog_through_button(xCancelBtn)
+
+xDoc = self.xUITest.getTopFocusWindow()
+xEdit = xDoc.getChild("impress_win")
+xEdit.executeAction("TYPE", mkPropertyValues({"TEXT":"test"}))
+
+# Without the accompanying fix in place, it would crash at this point
+self.xUITest.executeCommand(".uno:ParaRightToLeft")
+self.xUITest.executeCommand(".uno:ParaLeftToRight")
+
+self.ui_test.close_doc()
+
+# vim: set shiftwidth=4 softtabstop=4 expandtab:
diff --git a/svx/source/svdraw/svdedtv1.cxx b/svx/source/svdraw/svdedtv1.cxx
index 44c4b2fe5201..b75099094576 100644
--- a/svx/source/svdraw/svdedtv1.cxx
+++ b/svx/source/svdraw/svdedtv1.cxx
@@ -765,8 +765,6 @@ void SdrEditView::SetNotPersistAttrToMarked(const 
SfxItemSet& rAttr)
 }
 
 const bool bUndo = IsUndoEnabled();
-if( bUndo )
-EndTextEditAllViews();
 
 // TODO: check if WhichRange is necessary.
 const size_t nMarkCount=GetMarkedObjectCount();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: Branch 'libreoffice-6-3' - sd/qa sd/source

2019-07-04 Thread Xisco Fauli (via logerrit)
 sd/qa/unit/data/tdf126197.odp  |binary
 sd/qa/unit/uiimpress.cxx   |   31 +++
 sd/source/ui/view/drviewse.cxx |5 +
 3 files changed, 36 insertions(+)

New commits:
commit e79dbb8c6c4d2cf1ce2cf0ce67c53ed4bb09898b
Author: Xisco Fauli 
AuthorDate: Tue Jul 2 17:36:50 2019 +0200
Commit: Xisco Faulí 
CommitDate: Thu Jul 4 15:24:16 2019 +0200

tdf#126197: EndTextEdit on all views before delete/cut shape

Change-Id: I3da93e5c72ee6f6f99120758e870d654e01a0ec7
Reviewed-on: https://gerrit.libreoffice.org/75001
Tested-by: Jenkins
Reviewed-by: Xisco Faulí 
(cherry picked from commit 80db66c4f345ac469943f871308b14b7f5ed0a11)
Reviewed-on: https://gerrit.libreoffice.org/75079

diff --git a/sd/qa/unit/data/tdf126197.odp b/sd/qa/unit/data/tdf126197.odp
new file mode 100644
index ..cbe5b074464f
Binary files /dev/null and b/sd/qa/unit/data/tdf126197.odp differ
diff --git a/sd/qa/unit/uiimpress.cxx b/sd/qa/unit/uiimpress.cxx
index b8d9017b2cf9..2125820c7c50 100644
--- a/sd/qa/unit/uiimpress.cxx
+++ b/sd/qa/unit/uiimpress.cxx
@@ -120,6 +120,37 @@ CPPUNIT_TEST_FIXTURE(SdUiImpressTest, testTdf111522)
 pViewShell2->GetViewFrame()->GetDispatcher()->Execute(SID_UNDO, 
SfxCallMode::SYNCHRON);
 }
 
+CPPUNIT_TEST_FIXTURE(SdUiImpressTest, testTdf126197)
+{
+// Load the document and create two new windows.
+mxComponent = 
loadFromDesktop(m_directories.getURLFromSrc("sd/qa/unit/data/tdf126197.odp"));
+auto pImpressDocument = 
dynamic_cast(mxComponent.get());
+sd::ViewShell* pViewShell = 
pImpressDocument->GetDocShell()->GetViewShell();
+pViewShell->GetViewFrame()->GetDispatcher()->Execute(SID_NEWWINDOW, 
SfxCallMode::SYNCHRON);
+sd::ViewShell* pViewShell1 = 
pImpressDocument->GetDocShell()->GetViewShell();
+pViewShell->GetViewFrame()->GetDispatcher()->Execute(SID_NEWWINDOW, 
SfxCallMode::SYNCHRON);
+sd::ViewShell* pViewShell2 = 
pImpressDocument->GetDocShell()->GetViewShell();
+CPPUNIT_ASSERT(pViewShell1 != pViewShell2);
+
+// Start text edit in window 1.
+SdPage* pPage1 = pViewShell1->GetActualPage();
+SdrObject* pShape1 = pPage1->GetObj(0);
+SdrView* pView1 = pViewShell1->GetView();
+pView1->MarkObj(pShape1, pView1->GetSdrPageView());
+pView1->SdrBeginTextEdit(pShape1);
+CPPUNIT_ASSERT(pView1->IsTextEdit());
+
+SdPage* pPage2 = pViewShell2->GetActualPage();
+CPPUNIT_ASSERT_EQUAL(pPage1, pPage2);
+SdrObject* pShape2 = pPage2->GetObj(0);
+CPPUNIT_ASSERT_EQUAL(pShape1, pShape2);
+SdrView* pView2 = pViewShell2->GetView();
+pView2->MarkObj(pShape2, pView2->GetSdrPageView());
+
+// Without the accompanying fix in place, this test would have failed with 
an assertion failure
+// in SdrObjEditView::SdrEndTextEdit()
+pViewShell2->GetViewFrame()->GetDispatcher()->Execute(SID_DELETE, 
SfxCallMode::SYNCHRON);
+}
 CPPUNIT_PLUGIN_IMPLEMENT();
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sd/source/ui/view/drviewse.cxx b/sd/source/ui/view/drviewse.cxx
index 0c9ee3867fec..9cebd8c4f0d8 100644
--- a/sd/source/ui/view/drviewse.cxx
+++ b/sd/source/ui/view/drviewse.cxx
@@ -824,6 +824,10 @@ void DrawViewShell::FuSupport(SfxRequest& rReq)
 }
 else
 {
+//tdf#126197: EndTextEdit in all views if current one is not 
in TextEdit
+if ( !mpDrawView->IsTextEdit() )
+mpDrawView->EndTextEditAllViews();
+
 if(HasCurrentFunction())
 {
 GetCurrentFunction()->DoCut();
@@ -998,6 +1002,7 @@ void DrawViewShell::FuSupport(SfxRequest& rReq)
 }
 else
 {
+mpDrawView->EndTextEditAllViews();
 FuDeleteSelectedObjects();
 }
 rReq.Ignore ();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: Branch 'libreoffice-6-3' - sd/qa svx/source

2019-07-01 Thread Xisco Fauli (via logerrit)
 sd/qa/unit/uiimpress.cxx  |   18 ++
 svx/source/svdraw/svdedxv.cxx |2 +-
 2 files changed, 19 insertions(+), 1 deletion(-)

New commits:
commit 1da42db5f3b8e382cc9ea3345a87e7ce495d44d9
Author: Xisco Fauli 
AuthorDate: Sun Jun 30 19:37:24 2019 +0200
Commit: Xisco Faulí 
CommitDate: Mon Jul 1 12:37:46 2019 +0200

tdf#125824 svx: fix crash with view1 and view2 doing textedit

Similar to 3a874f1c80c37e8b35666e1d73161ff762eb7e4c

Change-Id: I51bffa4d33e82bb90b8a42787f55c12746bcd8c2
Reviewed-on: https://gerrit.libreoffice.org/74931
Tested-by: Jenkins
Reviewed-by: Miklos Vajna 
(cherry picked from commit 091f573728e7951d5dc4ef138117499b7480885f)
Reviewed-on: https://gerrit.libreoffice.org/74948
Reviewed-by: Xisco Faulí 

diff --git a/sd/qa/unit/uiimpress.cxx b/sd/qa/unit/uiimpress.cxx
index 2d3710faa7ed..b8d9017b2cf9 100644
--- a/sd/qa/unit/uiimpress.cxx
+++ b/sd/qa/unit/uiimpress.cxx
@@ -19,6 +19,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -100,6 +101,23 @@ CPPUNIT_TEST_FIXTURE(SdUiImpressTest, testTdf111522)
 // Without the accompanying fix in place, this test would have failed with 
an assertion failure
 // in SdrObjEditView::SdrEndTextEdit() as mpOldTextEditUndoManager was not 
nullptr.
 pViewShell2->GetViewFrame()->GetDispatcher()->Execute(SID_UNDO, 
SfxCallMode::SYNCHRON);
+
+// Start text edit in window 2.
+// tdf#125824
+pView2->MarkObj(pShape2, pView2->GetSdrPageView());
+pView2->SdrBeginTextEdit(pShape2);
+CPPUNIT_ASSERT(pView2->IsTextEdit());
+// Write 'test' inside the shape
+SfxStringItem aInputString(SID_ATTR_CHAR, "test");
+pViewShell2->GetViewFrame()->GetDispatcher()->ExecuteList(SID_ATTR_CHAR, 
SfxCallMode::SYNCHRON,
+  {  
});
+CPPUNIT_ASSERT(pView2->GetTextEditObject());
+EditView& rEditView = pView2->GetTextEditOutlinerView()->GetEditView();
+CPPUNIT_ASSERT_EQUAL(static_cast(4), 
rEditView.GetSelection().nStartPos);
+pView2->SdrEndTextEdit();
+// Without the accompanying fix in place, this test would have failed with 
an assertion failure
+// in SdrObjEditView::SdrEndTextEdit() as mpOldTextEditUndoManager was not 
nullptr.
+pViewShell2->GetViewFrame()->GetDispatcher()->Execute(SID_UNDO, 
SfxCallMode::SYNCHRON);
 }
 
 CPPUNIT_PLUGIN_IMPLEMENT();
diff --git a/svx/source/svdraw/svdedxv.cxx b/svx/source/svdraw/svdedxv.cxx
index 8935d2702804..cb9deae0ed19 100644
--- a/svx/source/svdraw/svdedxv.cxx
+++ b/svx/source/svdraw/svdedxv.cxx
@@ -1475,7 +1475,7 @@ SdrEndTextEditKind SdrObjEditView::SdrEndTextEdit(bool 
bDontDeleteReally)
 
pTEOutliner->SetBeginPasteOrDropHdl(Link());
 pTEOutliner->SetEndPasteOrDropHdl(Link());
 
-const bool bUndo = IsUndoEnabled();
+const bool bUndo = IsUndoEnabled() && CanDoSdrUndo();
 if( bUndo )
 {
 OUString aObjName(pTEObj->TakeObjNameSingul());
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: Branch 'libreoffice-6-3' - sd/qa svx/source

2019-06-10 Thread Miklos Vajna (via logerrit)
 sd/qa/unit/uiimpress.cxx   |7 +++
 svx/source/svdraw/svddrgmt.cxx |2 +-
 svx/source/svdraw/svdedtv1.cxx |   24 
 3 files changed, 20 insertions(+), 13 deletions(-)

New commits:
commit 79cae65f4725d0a8abd5639dc298002d11b2626c
Author: Miklos Vajna 
AuthorDate: Fri Jun 7 17:20:34 2019 +0200
Commit: Xisco Faulí 
CommitDate: Mon Jun 10 11:57:58 2019 +0200

Related: tdf#111522 svx: fix crash with view1 doing textedit and 
resize/rotate

The two actually affected functions are SdrEditView::RotateMarkedObj()
and SdrDragObjOwn::EndSdrDrag(), but it looks like the other functions
in SdrEditView are safe to be changed the same way.

I expect IsUndoEnabled() can't be changed, though: that would mean there
would be no undo for the text edit itself, either.

If other actions still crash, the pattern is the same: put a breakpoint
on the SdrUndoAction constructor and see the backtrace to find the
function that calls IsUndoEnabled() without calling CanDoSdrUndo() at
the same time.

Change-Id: If9324e311ec6e9f68a951559e903e14bb72ea31c
Reviewed-on: https://gerrit.libreoffice.org/73669
Reviewed-by: Miklos Vajna 
Tested-by: Jenkins
(cherry picked from commit 9870ff897f088563426bee9567dd9cb722c2b929)
Reviewed-on: https://gerrit.libreoffice.org/73748
Reviewed-by: Xisco Faulí 

diff --git a/sd/qa/unit/uiimpress.cxx b/sd/qa/unit/uiimpress.cxx
index 910f4a9dd0c3..2d3710faa7ed 100644
--- a/sd/qa/unit/uiimpress.cxx
+++ b/sd/qa/unit/uiimpress.cxx
@@ -93,6 +93,13 @@ CPPUNIT_TEST_FIXTURE(SdUiImpressTest, testTdf111522)
 // Without the accompanying fix in place, this test would have failed with 
an assertion failure
 // in SdrObjEditView::SdrEndTextEdit() as mpOldTextEditUndoManager was not 
nullptr.
 pViewShell2->GetViewFrame()->GetDispatcher()->Execute(SID_UNDO, 
SfxCallMode::SYNCHRON);
+
+// Rotate the shape in window 2 & undo.
+pView2->MarkObj(pShape2, pView2->GetSdrPageView());
+pView2->RotateMarkedObj(pShape2->GetLastBoundRect().Center(), 
/*nAngle=*/45);
+// Without the accompanying fix in place, this test would have failed with 
an assertion failure
+// in SdrObjEditView::SdrEndTextEdit() as mpOldTextEditUndoManager was not 
nullptr.
+pViewShell2->GetViewFrame()->GetDispatcher()->Execute(SID_UNDO, 
SfxCallMode::SYNCHRON);
 }
 
 CPPUNIT_PLUGIN_IMPLEMENT();
diff --git a/svx/source/svdraw/svddrgmt.cxx b/svx/source/svdraw/svddrgmt.cxx
index 05d44ce6bf70..f41a7991ccec 100644
--- a/svx/source/svdraw/svddrgmt.cxx
+++ b/svx/source/svdraw/svddrgmt.cxx
@@ -1366,7 +1366,7 @@ bool SdrDragObjOwn::EndSdrDrag(bool /*bCopy*/)
 {
 std::unique_ptr pUndo;
 std::unique_ptr pUndo2;
-const bool bUndo = getSdrDragView().IsUndoEnabled();
+const bool bUndo = getSdrDragView().IsUndoEnabled() && 
getSdrDragView().CanDoSdrUndo();
 
 if( bUndo )
 {
diff --git a/svx/source/svdraw/svdedtv1.cxx b/svx/source/svdraw/svdedtv1.cxx
index 66bc4c15ae69..47e05a0ad5e4 100644
--- a/svx/source/svdraw/svdedtv1.cxx
+++ b/svx/source/svdraw/svdedtv1.cxx
@@ -88,7 +88,7 @@ void SdrEditView::SetMarkedObjRect(const tools::Rectangle& 
rRect)
 long w1=rRect.Right()-x1;
 long h1=rRect.Bottom()-y1;
 
-const bool bUndo = IsUndoEnabled();
+const bool bUndo = IsUndoEnabled() && CanDoSdrUndo();
 if( bUndo )
 BegUndo(ImpGetDescriptionString(STR_EditPosSize));
 
@@ -208,7 +208,7 @@ void SdrEditView::MoveMarkedObj(const Size& rSiz, bool 
bCopy)
 
 void SdrEditView::ResizeMarkedObj(const Point& rRef, const Fraction& xFact, 
const Fraction& yFact, bool bCopy)
 {
-const bool bUndo = IsUndoEnabled();
+const bool bUndo = IsUndoEnabled() && CanDoSdrUndo();
 if( bUndo )
 {
 OUString aStr {ImpGetDescriptionString(STR_EditResize)};
@@ -242,7 +242,7 @@ void SdrEditView::ResizeMultMarkedObj(const Point& rRef,
 const bool bWdh,
 const bool bHgt)
 {
-const bool bUndo = IsUndoEnabled();
+const bool bUndo = IsUndoEnabled() && CanDoSdrUndo();
 if( bUndo )
 {
 BegUndo(ImpGetDescriptionString(STR_EditResize));
@@ -302,7 +302,7 @@ long SdrEditView::GetMarkedObjRotate() const
 
 void SdrEditView::RotateMarkedObj(const Point& rRef, long nAngle, bool bCopy)
 {
-const bool bUndo = IsUndoEnabled();
+const bool bUndo = IsUndoEnabled() && CanDoSdrUndo();
 if( bUndo )
 {
 OUString aStr {ImpGetDescriptionString(STR_EditRotate)};
@@ -357,7 +357,7 @@ void SdrEditView::RotateMarkedObj(const Point& rRef, long 
nAngle, bool bCopy)
 
 void SdrEditView::MirrorMarkedObj(const Point& rRef1, const Point& rRef2, bool 
bCopy)
 {
-const bool bUndo = IsUndoEnabled();
+const bool bUndo = IsUndoEnabled() && CanDoSdrUndo();
 
 if( bUndo )
 {
@@ -456,7 +456,7 @@ long SdrEditView::GetMarkedObjShear() const
 
 void SdrEditView::ShearMarkedObj(const Point& rRef, long nAngle, bool bVShear, 
bool