From c8dee9bfa8b6afbb4624ab2a5084c102ccf3d98f Mon Sep 17 00:00:00 2001 From: Kurt Zenker Date: Tue, 12 Dec 2006 15:27:52 +0000 Subject: INTEGRATION: CWS sdwarningsbegone (1.2.236); FILE MERGED 2006/11/22 12:40:36 cl 1.2.236.1: #i69285# warning free code changes for unxlngi6.pro --- sd/inc/undo/undomanager.hxx | 7 +++-- sd/inc/undo/undoobjects.hxx | 67 ++++++++++++++++++++------------------------- 2 files changed, 35 insertions(+), 39 deletions(-) (limited to 'sd/inc/undo') diff --git a/sd/inc/undo/undomanager.hxx b/sd/inc/undo/undomanager.hxx index ca37e335b526..01ee615e72d9 100644 --- a/sd/inc/undo/undomanager.hxx +++ b/sd/inc/undo/undomanager.hxx @@ -4,9 +4,9 @@ * * $RCSfile: undomanager.hxx,v $ * - * $Revision: 1.2 $ + * $Revision: 1.3 $ * - * last change: $Author: rt $ $Date: 2006-01-10 14:24:11 $ + * last change: $Author: kz $ $Date: 2006-12-12 16:27:29 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -64,6 +64,9 @@ public: virtual BOOL Redo( USHORT nCount=1 ); private: + using SfxUndoManager::Undo; + using SfxUndoManager::Redo; + int mnListLevel; ScopeLock maIsInUndoLock; }; diff --git a/sd/inc/undo/undoobjects.hxx b/sd/inc/undo/undoobjects.hxx index 1fa454f129b8..2a7664afd326 100644 --- a/sd/inc/undo/undoobjects.hxx +++ b/sd/inc/undo/undoobjects.hxx @@ -4,9 +4,9 @@ * * $RCSfile: undoobjects.hxx,v $ * - * $Revision: 1.2 $ + * $Revision: 1.3 $ * - * last change: $Author: rt $ $Date: 2006-01-10 14:24:25 $ + * last change: $Author: kz $ $Date: 2006-12-12 16:27:52 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -36,16 +36,10 @@ #ifndef _SD_UNDOOBJECTS_HXX #define _SD_UNDOOBJECTS_HXX -#ifndef _SVDUNDO_HXX #include -#endif -#ifndef _SDR_OBJECTUSER_HXX -#include -#endif - -#ifndef _PRESENTATION_HXX +#include +#include #include "pres.hxx" -#endif class SdrObjUserCall; class SdPage; @@ -56,21 +50,6 @@ namespace sd /////////////////////////////////////////////////////////////////////// -class UndoShapeWatcher : public sdr::ObjectUser -{ -public: - UndoShapeWatcher( SdrObject& rObject ); - ~UndoShapeWatcher(); - -protected: - SdrObject* mpObjectSafe; - -private: - virtual void ObjectInDestruction(const SdrObject& rObject); -}; - -/////////////////////////////////////////////////////////////////////// - class UndoRemovePresObjectImpl { protected: @@ -88,40 +67,49 @@ private: /////////////////////////////////////////////////////////////////////// -class UndoRemoveObject : public SdrUndoRemoveObj, public UndoRemovePresObjectImpl, public UndoShapeWatcher +class UndoRemoveObject : public SdrUndoRemoveObj, public UndoRemovePresObjectImpl { public: UndoRemoveObject( SdrObject& rObject, bool bOrdNumDirect ); virtual void Undo(); virtual void Redo(); + +private: + SdrObjectWeakRef mxSdrObject; }; /////////////////////////////////////////////////////////////////////// -class UndoDeleteObject : public SdrUndoDelObj, public UndoRemovePresObjectImpl, public UndoShapeWatcher +class UndoDeleteObject : public SdrUndoDelObj, public UndoRemovePresObjectImpl { public: UndoDeleteObject( SdrObject& rObject, bool bOrdNumDirect ); virtual void Undo(); virtual void Redo(); + +private: + SdrObjectWeakRef mxSdrObject; }; /////////////////////////////////////////////////////////////////////// -class UndoReplaceObject : public SdrUndoReplaceObj, public UndoRemovePresObjectImpl, public UndoShapeWatcher +class UndoReplaceObject : public SdrUndoReplaceObj, public UndoRemovePresObjectImpl { public: UndoReplaceObject( SdrObject& rOldObject, SdrObject& rNewObject, bool bOrdNumDirect ); virtual void Undo(); virtual void Redo(); + +private: + SdrObjectWeakRef mxSdrObject; }; /////////////////////////////////////////////////////////////////////// -class UndoObjectSetText : public SdrUndoObjSetText, public UndoShapeWatcher +class UndoObjectSetText : public SdrUndoObjSetText { public: UndoObjectSetText( SdrObject& rNewObj ); @@ -133,12 +121,13 @@ public: private: SfxUndoAction* mpUndoAnimation; bool mbNewEmptyPresObj; + SdrObjectWeakRef mxSdrObject; }; ////////////////////////////////////////////////////////////////////////////// // Undo for SdrObject::SetUserCall() -class UndoObjectUserCall : public SdrUndoObj, public UndoShapeWatcher +class UndoObjectUserCall : public SdrUndoObj { public: UndoObjectUserCall(SdrObject& rNewObj); @@ -149,12 +138,13 @@ public: protected: SdrObjUserCall* mpOldUserCall; SdrObjUserCall* mpNewUserCall; + SdrObjectWeakRef mxSdrObject; }; ////////////////////////////////////////////////////////////////////////////// // Undo for SdPage::InsertPresObj() and SdPage::RemovePresObj() -class UndoObjectPresentationKind : public SdrUndoObj, public UndoShapeWatcher +class UndoObjectPresentationKind : public SdrUndoObj { public: UndoObjectPresentationKind(SdrObject& rObject); @@ -165,7 +155,8 @@ public: protected: PresObjKind meOldKind; PresObjKind meNewKind; - SdPage* mpPage; + SdrPageWeakRef mxPage; + SdrObjectWeakRef mxSdrObject; }; ////////////////////////////////////////////////////////////////////////////// @@ -181,12 +172,12 @@ public: virtual void Redo(); protected: - SdPage& mrPage; + SdrPageWeakRef mxPage; }; ////////////////////////////////////////////////////////////////////////////// -class UndoGeoObject : public SdrUndoGeoObj, public UndoShapeWatcher +class UndoGeoObject : public SdrUndoGeoObj { public: UndoGeoObject( SdrObject& rNewObj ); @@ -195,12 +186,13 @@ public: virtual void Redo(); protected: - SdPage* mpPage; + SdrPageWeakRef mxPage; + SdrObjectWeakRef mxSdrObject; }; ////////////////////////////////////////////////////////////////////////////// -class UndoAttrObject : public SdrUndoAttrObj, public UndoShapeWatcher +class UndoAttrObject : public SdrUndoAttrObj { public: UndoAttrObject( SdrObject& rObject, bool bStyleSheet1, bool bSaveText ); @@ -209,7 +201,8 @@ public: virtual void Redo(); protected: - SdPage* mpPage; + SdrPageWeakRef mxPage; + SdrObjectWeakRef mxSdrObject; }; } // namespace sd -- cgit