From bf15ae65a11243266cd958adb8ac795c232b4ba6 Mon Sep 17 00:00:00 2001 From: Kurt Zenker Date: Tue, 24 Jun 2008 10:00:44 +0000 Subject: INTEGRATION: CWS canvas05 (1.3.56); FILE MERGED 2008/04/21 07:28:23 thb 1.3.56.4: RESYNC: (1.3-1.4); FILE MERGED 2008/04/09 14:33:12 thb 1.3.56.3: Gave back vclcanvas the window surface; made cairocanvas consistent with rest (regarding setWindow) 2007/12/20 22:18:59 thb 1.3.56.2: #i81092# #i78888# #i78925# #i79258# #i79437# #i84784# Large canvas rework, completing various areas such as color spaces, bitmap data access, true sprite and non-sprite implementations, and upstreaming the canvas parts of rodos emf+ rendering 2007/10/01 13:02:04 thb 1.3.56.1: #i78888# #i78925# #i79258# #i79437# Merge from CWS picom --- canvas/source/vcl/devicehelper.hxx | 42 +++++++++++--------------------------- 1 file changed, 12 insertions(+), 30 deletions(-) (limited to 'canvas') diff --git a/canvas/source/vcl/devicehelper.hxx b/canvas/source/vcl/devicehelper.hxx index 11b6d024487c..87d5d31ebffc 100644 --- a/canvas/source/vcl/devicehelper.hxx +++ b/canvas/source/vcl/devicehelper.hxx @@ -7,7 +7,7 @@ * OpenOffice.org - a multi-platform office productivity suite * * $RCSfile: devicehelper.hxx,v $ - * $Revision: 1.4 $ + * $Revision: 1.5 $ * * This file is part of OpenOffice.org. * @@ -39,7 +39,7 @@ #include #include -#include "backbuffer.hxx" +#include "outdevprovider.hxx" #include @@ -48,16 +48,14 @@ namespace vclcanvas { - class SpriteCanvas; - class SpriteCanvasHelper; + class Canvas; class DeviceHelper : private ::boost::noncopyable { public: DeviceHelper(); - void init( Window& rOutputWindow, - SpriteCanvas& rSpriteCanvas ); + void init( const OutDevProviderSharedPtr& rOutDev ); /// Dispose all internal references void disposing(); @@ -86,39 +84,23 @@ namespace vclcanvas sal_Bool hasFullScreenMode( ); sal_Bool enterFullScreenMode( sal_Bool bEnter ); - ::sal_Int32 createBuffers( ::sal_Int32 nBuffers ); - void destroyBuffers( ); - ::sal_Bool showBuffer( ::sal_Bool bUpdateAll ); - ::sal_Bool switchBuffer( ::sal_Bool bUpdateAll ); - - OutputDevice* getOutDev() const { return mpOutputWindow; } + ::com::sun::star::uno::Any isAccelerated() const; ::com::sun::star::uno::Any getDeviceHandle() const; ::com::sun::star::uno::Any getSurfaceHandle() const; + ::com::sun::star::uno::Reference< + ::com::sun::star::rendering::XColorSpace > getColorSpace() const; + + OutDevProviderSharedPtr getOutDev() const { return mpOutDev; } /** called when DumpScreenContent property is enabled on XGraphicDevice, and writes out bitmaps of current screen. */ void dumpScreenContent() const; - BackBufferSharedPtr getBackBuffer() const { return mpBackBuffer; } - - void notifySizeUpdate( const ::com::sun::star::awt::Rectangle& rBounds ); - private: - // TODO(Q2): Lifetime issue. Though WindowGraphicDeviceBase - // now listenes to the window component, I still consider - // holding a naked ptr unsafe here (especially as we pass it - // around via getOutDev). This _only_ works reliably, if - // disposing the SpriteCanvas correctly disposes all entities - // which hold this pointer. - Window* mpOutputWindow; - - /// Pointer to sprite canvas (owner of this helper), needed to create bitmaps - SpriteCanvas* mpSpriteCanvas; - - /// This buffer holds the background content for all associated canvases - BackBufferSharedPtr mpBackBuffer; + /// For retrieving device info + OutDevProviderSharedPtr mpOutDev; }; } -#endif /* _VCLCANVAS_WINDOWGRAPHICDEVICE_HXX */ +#endif /* _VCLCANVAS_DEVICEHELPER_HXX */ -- cgit