summaryrefslogtreecommitdiff
path: root/sd/source/ui/view/unmodpg.cxx
diff options
context:
space:
mode:
authorArmin Weiss <aw@openoffice.org>2001-11-13 17:11:53 +0000
committerArmin Weiss <aw@openoffice.org>2001-11-13 17:11:53 +0000
commitee1d4093e467f106a87deefe6849ada64e8ba8eb (patch)
tree555056e2c9d89299b18cc84e0e2970506eec156b /sd/source/ui/view/unmodpg.cxx
parent7a01a1d1a07cbef23991ebe3ae2234439182fdfe (diff)
#94637# invalidate Selection, there could be objects deleted in tis UNDO which are no longer allowed to be selected then.
Diffstat (limited to 'sd/source/ui/view/unmodpg.cxx')
-rw-r--r--sd/source/ui/view/unmodpg.cxx34
1 files changed, 32 insertions, 2 deletions
diff --git a/sd/source/ui/view/unmodpg.cxx b/sd/source/ui/view/unmodpg.cxx
index a2e0dd9923cb..c8aad3feaced 100644
--- a/sd/source/ui/view/unmodpg.cxx
+++ b/sd/source/ui/view/unmodpg.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: unmodpg.cxx,v $
*
- * $Revision: 1.4 $
+ * $Revision: 1.5 $
*
- * last change: $Author: ka $ $Date: 2001-10-22 13:36:57 $
+ * last change: $Author: aw $ $Date: 2001-11-13 18:11:53 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -133,8 +133,26 @@ ModifyPageUndoAction::ModifyPageUndoAction(
|*
\************************************************************************/
+#ifndef _SVDVITER_HXX
+#include <svx/svdviter.hxx>
+#endif
+#ifndef _SVDVIEW_HXX
+#include <svx/svdview.hxx>
+#endif
void ModifyPageUndoAction::Undo()
{
+ // #94637# invalidate Selection, there could be objects deleted in tis UNDO
+ // which are no longer allowed to be selected then.
+ SdrViewIter aIter(pPage);
+ SdrView* pView = aIter.FirstView();
+
+ while(pView)
+ {
+ if(pView->HasMarked())
+ pView->UnmarkAll();
+ pView = aIter.NextView();
+ }
+
pPage->SetAutoLayout(eOldAutoLayout, TRUE);
if (!pPage->IsMasterPage())
@@ -183,6 +201,18 @@ void ModifyPageUndoAction::Undo()
void ModifyPageUndoAction::Redo()
{
+ // #94637# invalidate Selection, there could be objects deleted in tis UNDO
+ // which are no longer allowed to be selected then.
+ SdrViewIter aIter(pPage);
+ SdrView* pView = aIter.FirstView();
+
+ while(pView)
+ {
+ if(pView->HasMarked())
+ pView->UnmarkAll();
+ pView = aIter.NextView();
+ }
+
pPage->SetAutoLayout(eNewAutoLayout, TRUE);
if (!pPage->IsMasterPage())