diff options
author | RĂ¼diger Timm <rt@openoffice.org> | 2004-11-26 19:52:28 +0000 |
---|---|---|
committer | RĂ¼diger Timm <rt@openoffice.org> | 2004-11-26 19:52:28 +0000 |
commit | 2d21573e6c014b88484d8b7bac34955e2f804ec2 (patch) | |
tree | c7615666b7afff3ef9c4817789edc7b392224042 /cppcanvas/inc/cppcanvas | |
parent | b672d1a6a24c27578e7f4d26db8e7ad87cfb070d (diff) |
INTEGRATION: CWS presentationengine01 (1.2.2); FILE MERGED
2004/08/27 18:49:14 thb 1.2.2.6: #110496# Adapted to recent canvas API changes (XSpriteCanvas::updateScreen)
2004/08/19 17:21:08 thb 1.2.2.5: #110496# Switched from deprecated to recommended shared_ptr dynamic cast method
2004/07/20 19:08:43 thb 1.2.2.4: #110496# Unified include statements; removed external prefix from boost includes
2004/06/25 14:01:07 thb 1.2.2.3: #100000# Old boost does not have operator bool on shared_ptr
2004/06/25 10:30:18 thb 1.2.2.2: #110496# Some header cleanups (missing forward declarations), changed Canvas and derived to emulate covariant return types on clone() (not directly possible with shared_ptr)
2004/04/05 15:58:44 thb 1.2.2.1: Resync with canvas01 changes
Diffstat (limited to 'cppcanvas/inc/cppcanvas')
-rw-r--r-- | cppcanvas/inc/cppcanvas/spritecanvas.hxx | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/cppcanvas/inc/cppcanvas/spritecanvas.hxx b/cppcanvas/inc/cppcanvas/spritecanvas.hxx index 536c07b41149..23c27396c725 100644 --- a/cppcanvas/inc/cppcanvas/spritecanvas.hxx +++ b/cppcanvas/inc/cppcanvas/spritecanvas.hxx @@ -2,9 +2,9 @@ * * $RCSfile: spritecanvas.hxx,v $ * - * $Revision: 1.3 $ + * $Revision: 1.4 $ * - * last change: $Author: rt $ $Date: 2004-09-08 16:58:33 $ + * last change: $Author: rt $ $Date: 2004-11-26 20:52:28 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -65,6 +65,9 @@ #ifndef _SAL_TYPES_H_ #include <sal/types.h> #endif +#ifndef _OSL_DIAGNOSE_H_ +#include <osl/diagnose.h> +#endif #ifndef _BGFX_VECTOR_B2DSIZE_HXX #include <basegfx/vector/b2dsize.hxx> @@ -105,12 +108,18 @@ namespace cppcanvas class SpriteCanvas : public virtual BitmapCanvas { public: - virtual bool updateScreen() const = 0; + virtual bool updateScreen( bool bUpdateAll ) const = 0; virtual CustomSpriteSharedPtr createCustomSprite( const ::basegfx::B2DSize& ) const = 0; virtual SpriteSharedPtr createClonedSprite( const SpriteSharedPtr& ) const = 0; - virtual SpriteCanvasSharedPtr cloneSpriteCanvas() const = 0; // shared_ptr does not allow for covariant return types + // shared_ptr does not allow for covariant return types + SpriteCanvasSharedPtr cloneSpriteCanvas() const + { + SpriteCanvasSharedPtr p( ::boost::dynamic_pointer_cast< SpriteCanvas >(this->clone()) ); + OSL_ENSURE(p.get(), "SpriteCanvas::cloneSpriteCanvas(): dynamic cast failed"); + return p; + } virtual ::com::sun::star::uno::Reference< ::drafts::com::sun::star::rendering::XSpriteCanvas > getUNOSpriteCanvas() const = 0; |