diff options
Diffstat (limited to 'canvas/source/vcl')
39 files changed, 195 insertions, 117 deletions
diff --git a/canvas/source/vcl/backbuffer.cxx b/canvas/source/vcl/backbuffer.cxx index 36888d038ceb..0cb4556fb851 100644 --- a/canvas/source/vcl/backbuffer.cxx +++ b/canvas/source/vcl/backbuffer.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -69,3 +70,5 @@ namespace vclcanvas } } + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/backbuffer.hxx b/canvas/source/vcl/backbuffer.hxx index 4f4dfa1f638c..a359bcfaa3b8 100644 --- a/canvas/source/vcl/backbuffer.hxx +++ b/canvas/source/vcl/backbuffer.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -65,3 +66,5 @@ namespace vclcanvas } #endif /* #ifndef _VCLCANVAS_BACKBUFFER_HXX_ */ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/bitmapbackbuffer.cxx b/canvas/source/vcl/bitmapbackbuffer.cxx index 53bb67dc32c2..37130b575dc1 100644 --- a/canvas/source/vcl/bitmapbackbuffer.cxx +++ b/canvas/source/vcl/bitmapbackbuffer.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -31,7 +32,7 @@ #include "bitmapbackbuffer.hxx" #include <osl/mutex.hxx> -#include <vos/mutex.hxx> +#include <osl/mutex.hxx> #include <vcl/svapp.hxx> #include <vcl/bitmapex.hxx> @@ -54,7 +55,7 @@ namespace vclcanvas { // make sure solar mutex is held on deletion (other methods // are supposed to be called with already locked solar mutex) - ::vos::OGuard aGuard( Application::GetSolarMutex() ); + SolarMutexGuard aGuard; if( mpVDev ) delete mpVDev; @@ -163,3 +164,4 @@ namespace vclcanvas } } +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/bitmapbackbuffer.hxx b/canvas/source/vcl/bitmapbackbuffer.hxx index 96dd525b98a4..dcb9038f8ee9 100644 --- a/canvas/source/vcl/bitmapbackbuffer.hxx +++ b/canvas/source/vcl/bitmapbackbuffer.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -102,3 +103,4 @@ namespace vclcanvas #endif /* #ifndef _VCLCANVAS_BITMAPBACKBUFFER_HXX_ */ +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/cachedbitmap.cxx b/canvas/source/vcl/cachedbitmap.cxx index 70ca3a3e67ed..964e02414a5b 100644 --- a/canvas/source/vcl/cachedbitmap.cxx +++ b/canvas/source/vcl/cachedbitmap.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -102,3 +103,5 @@ namespace vclcanvas return rendering::RepaintResult::REDRAWN; } } + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/cachedbitmap.hxx b/canvas/source/vcl/cachedbitmap.hxx index c45720c086c8..9b4ea2b3af7e 100644 --- a/canvas/source/vcl/cachedbitmap.hxx +++ b/canvas/source/vcl/cachedbitmap.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -76,3 +77,5 @@ namespace vclcanvas } #endif /* _VCLCANVAS_CACHEDBITMAP_HXX */ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/canvas.cxx b/canvas/source/vcl/canvas.cxx index 837c064b4411..c3dd0c569f89 100644 --- a/canvas/source/vcl/canvas.cxx +++ b/canvas/source/vcl/canvas.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -97,7 +98,7 @@ namespace vclcanvas 4: XWindow for creating Window (or empty for VirtualDevice) 5: SystemGraphicsData as a streamed Any */ - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; VERBOSE_TRACE( "VCLCanvas::initialize called" ); @@ -132,14 +133,14 @@ namespace vclcanvas OSL_TRACE( "Canvas destroyed" ); } - void SAL_CALL Canvas::disposing() + void Canvas::disposeThis() { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; mxComponentContext.clear(); // forward to parent - CanvasBaseT::disposing(); + CanvasBaseT::disposeThis(); } ::rtl::OUString SAL_CALL Canvas::getServiceName( ) throw (::com::sun::star::uno::RuntimeException) @@ -154,8 +155,10 @@ namespace vclcanvas const ::Size& rSz, const GraphicAttr& rAttr ) const { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; return maCanvasHelper.repaint( rGrf, viewState, renderState, rPt, rSz, rAttr ); } } + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/canvas.hxx b/canvas/source/vcl/canvas.hxx index adda8d8eea40..16d5c5abd5b3 100644 --- a/canvas/source/vcl/canvas.hxx +++ b/canvas/source/vcl/canvas.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -42,7 +43,7 @@ #include <cppuhelper/compbase7.hxx> #include <comphelper/uno3.hxx> -#include <canvas/base/basemutexhelper.hxx> +#include <canvas/base/disambiguationhelper.hxx> #include <canvas/base/integerbitmapbase.hxx> #include <canvas/base/graphicdevicebase.hxx> @@ -63,7 +64,7 @@ namespace vclcanvas ::com::sun::star::util::XUpdatable, ::com::sun::star::beans::XPropertySet, ::com::sun::star::lang::XServiceName > GraphicDeviceBase_Base; - typedef ::canvas::GraphicDeviceBase< ::canvas::BaseMutexHelper< GraphicDeviceBase_Base >, + typedef ::canvas::GraphicDeviceBase< ::canvas::DisambiguationHelper< GraphicDeviceBase_Base >, DeviceHelper, tools::LocalGuard, ::cppu::OWeakObject > CanvasBase_Base; @@ -95,12 +96,8 @@ namespace vclcanvas /// For resource tracking ~Canvas(); -#if defined __SUNPRO_CC - using CanvasBaseT::disposing; -#endif - /// Dispose all internal references - virtual void SAL_CALL disposing(); + virtual void disposeThis(); // Forwarding the XComponent implementation to the // cppu::ImplHelper templated base @@ -129,3 +126,5 @@ namespace vclcanvas } #endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/canvasbitmap.cxx b/canvas/source/vcl/canvasbitmap.cxx index 2b244602e3fd..84f5a8db58c3 100644 --- a/canvas/source/vcl/canvasbitmap.cxx +++ b/canvas/source/vcl/canvasbitmap.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -81,12 +82,6 @@ namespace vclcanvas maCanvasHelper.init( rBitmap, rDevice, rOutDevProvider ); } - void SAL_CALL CanvasBitmap::disposing() - { - // forward to base - CanvasBitmap_Base::disposing(); - } - #define IMPLEMENTATION_NAME "VCLCanvas.CanvasBitmap" #define SERVICE_NAME "com.sun.star.rendering.CanvasBitmap" @@ -110,7 +105,7 @@ namespace vclcanvas BitmapEx CanvasBitmap::getBitmap() const { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; // TODO(T3): Rework to use shared_ptr all over the place for // BmpEx. This is highly un-threadsafe @@ -124,7 +119,7 @@ namespace vclcanvas const ::Size& rSz, const GraphicAttr& rAttr ) const { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; mbSurfaceDirty = true; @@ -142,3 +137,5 @@ namespace vclcanvas return uno::Any( sal_Int64(0) ); } } + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/canvasbitmap.hxx b/canvas/source/vcl/canvasbitmap.hxx index 6440b830c3ee..540b190b76a1 100644 --- a/canvas/source/vcl/canvasbitmap.hxx +++ b/canvas/source/vcl/canvasbitmap.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -56,7 +57,7 @@ namespace vclcanvas ::com::sun::star::rendering::XIntegerBitmap, ::com::sun::star::lang::XServiceInfo, ::com::sun::star::beans::XFastPropertySet > CanvasBitmapBase_Base; - typedef ::canvas::IntegerBitmapBase< ::canvas::BaseMutexHelper< CanvasBitmapBase_Base >, + typedef ::canvas::IntegerBitmapBase< ::canvas::DisambiguationHelper< CanvasBitmapBase_Base >, CanvasBitmapHelper, tools::LocalGuard, ::cppu::OWeakObject > CanvasBitmap_Base; @@ -86,9 +87,6 @@ namespace vclcanvas ::com::sun::star::rendering::XGraphicDevice& rDevice, const OutDevProviderSharedPtr& rOutDevProvider ); - // overridden because of mpDevice - virtual void SAL_CALL disposing(); - // XServiceInfo virtual ::rtl::OUString SAL_CALL getImplementationName( ) throw (::com::sun::star::uno::RuntimeException); virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) throw (::com::sun::star::uno::RuntimeException); @@ -127,3 +125,5 @@ namespace vclcanvas } #endif /* _VCLCANVAS_CANVASBITMAP_HXX */ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/canvasbitmaphelper.cxx b/canvas/source/vcl/canvasbitmaphelper.cxx index 5b8f9fd84d94..2c5a9ff0f220 100644 --- a/canvas/source/vcl/canvasbitmaphelper.cxx +++ b/canvas/source/vcl/canvasbitmaphelper.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -148,9 +149,8 @@ namespace vclcanvas Bitmap aBitmap( mpBackBuffer->getBitmapReference().GetBitmap() ); Bitmap aAlpha( mpBackBuffer->getBitmapReference().GetAlpha().GetBitmap() ); - ScopedBitmapReadAccess pReadAccess( aBitmap.AcquireReadAccess(), - aBitmap ); - ScopedBitmapReadAccess pAlphaReadAccess( aAlpha.IsEmpty() ? + Bitmap::ScopedReadAccess pReadAccess( aBitmap ); + Bitmap::ScopedReadAccess pAlphaReadAccess( aAlpha.IsEmpty() ? (BitmapReadAccess*)NULL : aAlpha.AcquireReadAccess(), aAlpha ); @@ -228,9 +228,8 @@ namespace vclcanvas // actually changed a pixel { - ScopedBitmapWriteAccess pWriteAccess( aBitmap.AcquireWriteAccess(), - aBitmap ); - ScopedBitmapWriteAccess pAlphaWriteAccess( aAlpha.IsEmpty() ? + Bitmap::ScopedWriteAccess pWriteAccess( aBitmap ); + Bitmap::ScopedWriteAccess pAlphaWriteAccess( aAlpha.IsEmpty() ? (BitmapWriteAccess*)NULL : aAlpha.AcquireWriteAccess(), aAlpha ); @@ -470,9 +469,8 @@ namespace vclcanvas // actually changed a pixel { - ScopedBitmapWriteAccess pWriteAccess( aBitmap.AcquireWriteAccess(), - aBitmap ); - ScopedBitmapWriteAccess pAlphaWriteAccess( aAlpha.IsEmpty() ? + Bitmap::ScopedWriteAccess pWriteAccess( aBitmap ); + Bitmap::ScopedWriteAccess pAlphaWriteAccess( aAlpha.IsEmpty() ? (BitmapWriteAccess*)NULL : aAlpha.AcquireWriteAccess(), aAlpha ); @@ -524,9 +522,8 @@ namespace vclcanvas Bitmap aBitmap( mpBackBuffer->getBitmapReference().GetBitmap() ); Bitmap aAlpha( mpBackBuffer->getBitmapReference().GetAlpha().GetBitmap() ); - ScopedBitmapReadAccess pReadAccess( aBitmap.AcquireReadAccess(), - aBitmap ); - ScopedBitmapReadAccess pAlphaReadAccess( aAlpha.IsEmpty() ? + Bitmap::ScopedReadAccess pReadAccess( aBitmap ); + Bitmap::ScopedReadAccess pAlphaReadAccess( aAlpha.IsEmpty() ? (BitmapReadAccess*)NULL : aAlpha.AcquireReadAccess(), aAlpha ); ENSURE_OR_THROW( pReadAccess.get() != NULL, @@ -565,3 +562,5 @@ namespace vclcanvas } } + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/canvasbitmaphelper.hxx b/canvas/source/vcl/canvasbitmaphelper.hxx index 196d53d7b58a..f49acdd19c16 100644 --- a/canvas/source/vcl/canvasbitmaphelper.hxx +++ b/canvas/source/vcl/canvasbitmaphelper.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -127,3 +128,5 @@ namespace vclcanvas } #endif /* _VCLCANVAS_CANVASBITMAPHELPER_HXX_ */ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/canvascustomsprite.cxx b/canvas/source/vcl/canvascustomsprite.cxx index a55109a9749f..2fcf6311485b 100644 --- a/canvas/source/vcl/canvascustomsprite.cxx +++ b/canvas/source/vcl/canvascustomsprite.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -128,14 +129,6 @@ namespace vclcanvas maCanvasHelper.clear(); } - void SAL_CALL CanvasCustomSprite::disposing() - { - tools::LocalGuard aGuard; - - // forward to parent - CanvasCustomSpriteBaseT::disposing(); - } - #define IMPLEMENTATION_NAME "VCLCanvas.CanvasCustomSprite" #define SERVICE_NAME "com.sun.star.rendering.CanvasCustomSprite" @@ -161,7 +154,7 @@ namespace vclcanvas void CanvasCustomSprite::redraw( OutputDevice& rOutDev, bool bBufferedUpdate ) const { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; redraw( rOutDev, maSpriteHelper.getPosPixel(), bBufferedUpdate ); } @@ -170,7 +163,7 @@ namespace vclcanvas const ::basegfx::B2DPoint& rOrigOutputPos, bool bBufferedUpdate ) const { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; maSpriteHelper.redraw( rOutDev, rOrigOutputPos, @@ -187,7 +180,7 @@ namespace vclcanvas const ::Size& rSz, const GraphicAttr& rAttr ) const { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; mbSurfaceDirty = true; @@ -195,3 +188,5 @@ namespace vclcanvas } } + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/canvascustomsprite.hxx b/canvas/source/vcl/canvascustomsprite.hxx index 21202b75368d..6acaddafd545 100644 --- a/canvas/source/vcl/canvascustomsprite.hxx +++ b/canvas/source/vcl/canvascustomsprite.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -40,7 +41,7 @@ #include <vcl/virdev.hxx> #include <canvas/vclwrapper.hxx> -#include <canvas/base/basemutexhelper.hxx> +#include <canvas/base/disambiguationhelper.hxx> #include <canvas/base/spritesurface.hxx> #include <canvas/base/canvascustomspritebase.hxx> @@ -76,7 +77,7 @@ namespace vclcanvas remain a base class that provides implementation, not to enforce any specific interface on its derivees. */ - class CanvasCustomSpriteSpriteBase_Base : public ::canvas::BaseMutexHelper< CanvasCustomSpriteBase_Base >, + class CanvasCustomSpriteSpriteBase_Base : public ::canvas::DisambiguationHelper< CanvasCustomSpriteBase_Base >, public Sprite { }; @@ -99,8 +100,6 @@ namespace vclcanvas const OutDevProviderSharedPtr& rOutDevProvider, bool bShowSpriteBounds ); - virtual void SAL_CALL disposing(); - // Forwarding the XComponent implementation to the // cppu::ImplHelper templated base // Classname Base doing refcount Base implementing the XComponent interface @@ -131,3 +130,5 @@ namespace vclcanvas } #endif /* _VCLCANVAS_CANVASCUSTOMSPRITE_HXX */ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/canvasfont.cxx b/canvas/source/vcl/canvasfont.cxx index 9f10c788bd24..4d1cb2b087c3 100644 --- a/canvas/source/vcl/canvasfont.cxx +++ b/canvas/source/vcl/canvasfont.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -97,7 +98,7 @@ namespace vclcanvas void SAL_CALL CanvasFont::disposing() { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; mpOutDevProvider.reset(); mpRefDevice.clear(); @@ -105,7 +106,7 @@ namespace vclcanvas uno::Reference< rendering::XTextLayout > SAL_CALL CanvasFont::createTextLayout( const rendering::StringContext& aText, sal_Int8 nDirection, sal_Int64 nRandomSeed ) throw (uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; if( !mpRefDevice.is() ) return uno::Reference< rendering::XTextLayout >(); // we're disposed @@ -120,14 +121,14 @@ namespace vclcanvas rendering::FontRequest SAL_CALL CanvasFont::getFontRequest( ) throw (uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; return maFontRequest; } rendering::FontMetrics SAL_CALL CanvasFont::getFontMetrics( ) throw (uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; OutputDevice& rOutDev = mpOutDevProvider->getOutDev(); VirtualDevice aVDev( rOutDev ); @@ -146,7 +147,7 @@ namespace vclcanvas uno::Sequence< double > SAL_CALL CanvasFont::getAvailableSizes( ) throw (uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; // TODO(F1) return uno::Sequence< double >(); @@ -154,7 +155,7 @@ namespace vclcanvas uno::Sequence< beans::PropertyValue > SAL_CALL CanvasFont::getExtraFontProperties( ) throw (uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; // TODO(F1) return uno::Sequence< beans::PropertyValue >(); @@ -186,3 +187,5 @@ namespace vclcanvas return *maFont; } } + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/canvasfont.hxx b/canvas/source/vcl/canvasfont.hxx index e0c9a567a29a..44cc9631f4f9 100644 --- a/canvas/source/vcl/canvasfont.hxx +++ b/canvas/source/vcl/canvasfont.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -98,3 +99,5 @@ namespace vclcanvas } #endif /* _VCLCANVAS_CANVASFONT_HXX */ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/canvashelper.cxx b/canvas/source/vcl/canvashelper.cxx index e135ec494fdf..38185d812fb5 100644 --- a/canvas/source/vcl/canvashelper.cxx +++ b/canvas/source/vcl/canvashelper.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -156,8 +157,8 @@ namespace vclcanvas tools::OutDevStateKeeper aStateKeeper( mpProtectedOutDev ); rOutDev.EnableMapMode( sal_False ); - rOutDev.SetLineColor( COL_WHITE ); - rOutDev.SetFillColor( COL_WHITE ); + rOutDev.SetLineColor( COL_TRANSPARENT ); + rOutDev.SetFillColor( COL_TRANSPARENT ); rOutDev.DrawRect( Rectangle( Point(), rOutDev.GetOutputSizePixel()) ); @@ -167,8 +168,8 @@ namespace vclcanvas rOutDev2.SetDrawMode( DRAWMODE_DEFAULT ); rOutDev2.EnableMapMode( sal_False ); - rOutDev2.SetLineColor( COL_WHITE ); - rOutDev2.SetFillColor( COL_WHITE ); + rOutDev2.SetLineColor( COL_TRANSPARENT ); + rOutDev2.SetFillColor( COL_TRANSPARENT ); rOutDev2.DrawRect( Rectangle( Point(), rOutDev2.GetOutputSizePixel()) ); rOutDev2.SetDrawMode( DRAWMODE_BLACKLINE | DRAWMODE_BLACKFILL | DRAWMODE_BLACKTEXT | @@ -947,8 +948,7 @@ namespace vclcanvas Bitmap aBitmap( rOutDev.GetBitmap(aRect.TopLeft(), aRect.GetSize()) ); - ScopedBitmapReadAccess pReadAccess( aBitmap.AcquireReadAccess(), - aBitmap ); + Bitmap::ScopedReadAccess pReadAccess( aBitmap ); ENSURE_OR_THROW( pReadAccess.get() != NULL, "Could not acquire read access to OutDev bitmap" ); @@ -1013,8 +1013,7 @@ namespace vclcanvas Bitmap aTmpBitmap( rOutDev.GetBitmap( aEmptyPoint, aSize ) ); - ScopedBitmapReadAccess pReadAccess( aTmpBitmap.AcquireReadAccess(), - aTmpBitmap ); + Bitmap::ScopedReadAccess pReadAccess( aTmpBitmap ); pPalette = &pReadAccess->GetPalette(); } @@ -1025,8 +1024,7 @@ namespace vclcanvas bool bCopyBack( false ); // only copy something back, if we // actually changed some pixel { - ScopedBitmapWriteAccess pWriteAccess( aBitmap.AcquireWriteAccess(), - aBitmap ); + Bitmap::ScopedWriteAccess pWriteAccess( aBitmap ); ENSURE_OR_THROW( pWriteAccess.get() != NULL, "Could not acquire write access to OutDev bitmap" ); @@ -1426,3 +1424,5 @@ namespace vclcanvas } } + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/canvashelper.hxx b/canvas/source/vcl/canvashelper.hxx index ef5eafa0c9ef..ebc0d58624c7 100644 --- a/canvas/source/vcl/canvashelper.hxx +++ b/canvas/source/vcl/canvashelper.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -342,3 +343,5 @@ namespace vclcanvas } #endif /* _VCLCANVAS_CANVASHELPER_HXX_ */ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/canvashelper_texturefill.cxx b/canvas/source/vcl/canvashelper_texturefill.cxx index 00eb7c1ba071..e7ffe0e41356 100644 --- a/canvas/source/vcl/canvashelper_texturefill.cxx +++ b/canvas/source/vcl/canvashelper_texturefill.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -1184,3 +1185,5 @@ namespace vclcanvas } } + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/devicehelper.cxx b/canvas/source/vcl/devicehelper.cxx index 699a2ebfe9b8..96b14e2cfb73 100644 --- a/canvas/source/vcl/devicehelper.cxx +++ b/canvas/source/vcl/devicehelper.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -240,3 +241,5 @@ namespace vclcanvas } } + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/devicehelper.hxx b/canvas/source/vcl/devicehelper.hxx index aa17e98b8070..1c2d7b930320 100644 --- a/canvas/source/vcl/devicehelper.hxx +++ b/canvas/source/vcl/devicehelper.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -101,3 +102,5 @@ namespace vclcanvas } #endif /* _VCLCANVAS_DEVICEHELPER_HXX */ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/impltools.cxx b/canvas/source/vcl/impltools.cxx index 97a825f48f01..a8187766e15b 100644 --- a/canvas/source/vcl/impltools.cxx +++ b/canvas/source/vcl/impltools.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -59,6 +60,7 @@ #include <basegfx/numeric/ftools.hxx> #include <canvas/canvastools.hxx> +#include <o3tl/compat_functional.hxx> #include "impltools.hxx" #include "canvasbitmap.hxx" @@ -275,9 +277,8 @@ namespace vclcanvas aSrcAlpha = rBitmap.GetMask(); } - ScopedBitmapReadAccess pReadAccess( aSrcBitmap.AcquireReadAccess(), - aSrcBitmap ); - ScopedBitmapReadAccess pAlphaReadAccess( rBitmap.IsTransparent() ? + Bitmap::ScopedReadAccess pReadAccess( aSrcBitmap ); + Bitmap::ScopedReadAccess pAlphaReadAccess( rBitmap.IsTransparent() ? aSrcAlpha.AcquireReadAccess() : (BitmapReadAccess*)NULL, aSrcAlpha ); @@ -301,7 +302,7 @@ namespace vclcanvas { // source already has alpha channel - 1:1 mapping, // i.e. aAlphaMap[0]=0,...,aAlphaMap[255]=255. - ::std::iota( aAlphaMap, &aAlphaMap[256], 0 ); + ::o3tl::iota( aAlphaMap, &aAlphaMap[256], 0 ); } else { @@ -332,10 +333,8 @@ namespace vclcanvas // copy-constructing the resulting bitmap. This will // rule out the possibility that cached accessor data // is not yet written back. - ScopedBitmapWriteAccess pWriteAccess( aDstBitmap.AcquireWriteAccess(), - aDstBitmap ); - ScopedBitmapWriteAccess pAlphaWriteAccess( aDstAlpha.AcquireWriteAccess(), - aDstAlpha ); + Bitmap::ScopedWriteAccess pWriteAccess( aDstBitmap ); + Bitmap::ScopedWriteAccess pAlphaWriteAccess( aDstAlpha ); if( pWriteAccess.get() != NULL && @@ -542,3 +541,5 @@ namespace vclcanvas } } } + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/impltools.hxx b/canvas/source/vcl/impltools.hxx index e79ddb8496df..8b9293acb44d 100644 --- a/canvas/source/vcl/impltools.hxx +++ b/canvas/source/vcl/impltools.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -29,10 +30,11 @@ #define _VCLCANVAS_TOOLS_HXX #include <osl/mutex.hxx> -#include <vos/mutex.hxx> +#include <osl/mutex.hxx> #include <vcl/svapp.hxx> #include <vcl/outdev.hxx> +#include <vcl/solarmutex.hxx> #include <basegfx/polygon/b2dpolypolygon.hxx> @@ -122,18 +124,18 @@ namespace vclcanvas { public: LocalGuard() : - aGuard( Application::GetSolarMutex() ) + aSolarGuard() { } /// To be compatible with CanvasBase mutex concept LocalGuard( const ::osl::Mutex& ) : - aGuard( Application::GetSolarMutex() ) + aSolarGuard() { } private: - ::vos::OGuard aGuard; + SolarMutexGuard aSolarGuard; }; class OutDevStateKeeper @@ -199,3 +201,5 @@ namespace vclcanvas } #endif /* _VCLCANVAS_TOOLS_HXX */ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/outdevprovider.hxx b/canvas/source/vcl/outdevprovider.hxx index dd5f870c7d9c..2d41980c8569 100644 --- a/canvas/source/vcl/outdevprovider.hxx +++ b/canvas/source/vcl/outdevprovider.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -59,3 +60,5 @@ namespace vclcanvas } #endif /* _VCLCANVAS_OUTDEVPROVIDER_HXX */ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/repainttarget.hxx b/canvas/source/vcl/repainttarget.hxx index ce2037bf5b67..5ca0c4dea198 100644 --- a/canvas/source/vcl/repainttarget.hxx +++ b/canvas/source/vcl/repainttarget.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -61,3 +62,5 @@ namespace vclcanvas } #endif /* _VCLCANVAS_REPAINTTARGET_HXX */ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/services.cxx b/canvas/source/vcl/services.cxx index e8cd2379a38f..f482c841ea74 100644 --- a/canvas/source/vcl/services.cxx +++ b/canvas/source/vcl/services.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -88,3 +89,5 @@ namespace vclcanvas // The C shared lib entry points COMPHELPER_SERVICEDECL_EXPORTS2(vclcanvas::vclCanvasDecl, vclcanvas::vclSpriteCanvasDecl) + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/sprite.hxx b/canvas/source/vcl/sprite.hxx index 29ff80239e02..b2713eb4486d 100644 --- a/canvas/source/vcl/sprite.hxx +++ b/canvas/source/vcl/sprite.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -69,3 +70,5 @@ namespace vclcanvas } #endif /* INCLUDED_VCLCANVAS_SPRITE_HXX */ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/spritecanvas.cxx b/canvas/source/vcl/spritecanvas.cxx index c08529d3cb35..14c2446dcab7 100644 --- a/canvas/source/vcl/spritecanvas.cxx +++ b/canvas/source/vcl/spritecanvas.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -63,7 +64,7 @@ namespace vclcanvas void SpriteCanvas::initialize() { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; // #i64742# Only call initialize when not in probe mode if( maArguments.getLength() == 0 ) @@ -128,14 +129,14 @@ namespace vclcanvas } - void SAL_CALL SpriteCanvas::disposing() + void SpriteCanvas::disposeThis() { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; mxComponentContext.clear(); // forward to parent - SpriteCanvasBaseT::disposing(); + SpriteCanvasBaseT::disposeThis(); } ::sal_Bool SAL_CALL SpriteCanvas::showBuffer( ::sal_Bool bUpdateAll ) throw (uno::RuntimeException) @@ -150,7 +151,7 @@ namespace vclcanvas sal_Bool SAL_CALL SpriteCanvas::updateScreen( sal_Bool bUpdateAll ) throw (uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; // avoid repaints on hidden window (hidden: not mapped to // screen). Return failure, since the screen really has _not_ @@ -171,8 +172,10 @@ namespace vclcanvas const ::Size& rSz, const GraphicAttr& rAttr ) const { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; return maCanvasHelper.repaint( rGrf, viewState, renderState, rPt, rSz, rAttr ); } } + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/spritecanvas.hxx b/canvas/source/vcl/spritecanvas.hxx index db4b05ddb9b2..26500fc93552 100644 --- a/canvas/source/vcl/spritecanvas.hxx +++ b/canvas/source/vcl/spritecanvas.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -44,7 +45,7 @@ #include <comphelper/uno3.hxx> #include <canvas/base/spritecanvasbase.hxx> -#include <canvas/base/basemutexhelper.hxx> +#include <canvas/base/disambiguationhelper.hxx> #include <canvas/base/bufferedgraphicdevicebase.hxx> #include "spritecanvashelper.hxx" @@ -67,7 +68,7 @@ namespace vclcanvas ::com::sun::star::util::XUpdatable, ::com::sun::star::beans::XPropertySet, ::com::sun::star::lang::XServiceName > WindowGraphicDeviceBase_Base; - typedef ::canvas::BufferedGraphicDeviceBase< ::canvas::BaseMutexHelper< WindowGraphicDeviceBase_Base >, + typedef ::canvas::BufferedGraphicDeviceBase< ::canvas::DisambiguationHelper< WindowGraphicDeviceBase_Base >, SpriteDeviceHelper, tools::LocalGuard, ::cppu::OWeakObject > SpriteCanvasBase_Base; @@ -122,12 +123,8 @@ namespace vclcanvas /// For resource tracking ~SpriteCanvas(); -#if defined __SUNPRO_CC - using SpriteCanvasBaseT::disposing; -#endif - /// Dispose all internal references - virtual void SAL_CALL disposing(); + virtual void disposeThis(); // Forwarding the XComponent implementation to the // cppu::ImplHelper templated base @@ -170,3 +167,5 @@ namespace vclcanvas } #endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/spritecanvashelper.cxx b/canvas/source/vcl/spritecanvashelper.cxx index 50f02e6b5888..ac75508809fe 100644 --- a/canvas/source/vcl/spritecanvashelper.cxx +++ b/canvas/source/vcl/spritecanvashelper.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -716,3 +717,5 @@ namespace vclcanvas } } } + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/spritecanvashelper.hxx b/canvas/source/vcl/spritecanvashelper.hxx index bc80f4359e5b..b0b717f18697 100644 --- a/canvas/source/vcl/spritecanvashelper.hxx +++ b/canvas/source/vcl/spritecanvashelper.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -177,3 +178,4 @@ namespace vclcanvas #endif /* _VCLCANVAS_SPRITECANVASHELPER_HXX_ */ +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/spritedevicehelper.cxx b/canvas/source/vcl/spritedevicehelper.cxx index 6aa6de0bac97..20129ea3fe16 100644 --- a/canvas/source/vcl/spritedevicehelper.cxx +++ b/canvas/source/vcl/spritedevicehelper.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -88,13 +89,13 @@ namespace vclcanvas ::sal_Bool SpriteDeviceHelper::showBuffer( bool, ::sal_Bool ) { - OSL_ENSURE(false,"Not supposed to be called, handled by SpriteCanvas"); + OSL_FAIL("Not supposed to be called, handled by SpriteCanvas"); return sal_False; } ::sal_Bool SpriteDeviceHelper::switchBuffer( bool, ::sal_Bool ) { - OSL_ENSURE(false,"Not supposed to be called, handled by SpriteCanvas"); + OSL_FAIL("Not supposed to be called, handled by SpriteCanvas"); return sal_False; } @@ -156,3 +157,5 @@ namespace vclcanvas } } + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/spritedevicehelper.hxx b/canvas/source/vcl/spritedevicehelper.hxx index eaedbc8ca5ac..2034748cdb1f 100644 --- a/canvas/source/vcl/spritedevicehelper.hxx +++ b/canvas/source/vcl/spritedevicehelper.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -80,3 +81,5 @@ namespace vclcanvas } #endif /* _VCLCANVAS_SPRITEDEVICEHELPER_HXX */ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/spritehelper.cxx b/canvas/source/vcl/spritehelper.cxx index af1a2f9ccd4d..e4226fac1f16 100755..100644 --- a/canvas/source/vcl/spritehelper.cxx +++ b/canvas/source/vcl/spritehelper.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -166,8 +167,7 @@ namespace vclcanvas #ifndef QUARTZ if( aMask.GetBitCount() != 1 ) { - OSL_ENSURE(false, - "CanvasCustomSprite::redraw(): Mask bitmap is not " + OSL_FAIL("CanvasCustomSprite::redraw(): Mask bitmap is not " "monochrome (performance!)"); aMask.MakeMono(255); } @@ -428,3 +428,5 @@ namespace vclcanvas } } + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/spritehelper.hxx b/canvas/source/vcl/spritehelper.hxx index 67aa588dff6e..c40666c57e40 100644 --- a/canvas/source/vcl/spritehelper.hxx +++ b/canvas/source/vcl/spritehelper.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -119,3 +120,5 @@ namespace vclcanvas } #endif /* _VCLCANVAS_SPRITEHELPER_HXX */ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/textlayout.cxx b/canvas/source/vcl/textlayout.cxx index 19b0f7cea4ce..08cdd66abe00 100644 --- a/canvas/source/vcl/textlayout.cxx +++ b/canvas/source/vcl/textlayout.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -103,7 +104,7 @@ namespace vclcanvas void SAL_CALL TextLayout::disposing() { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; mpOutDevProvider.reset(); mxDevice.clear(); @@ -113,7 +114,7 @@ namespace vclcanvas // XTextLayout uno::Sequence< uno::Reference< rendering::XPolyPolygon2D > > SAL_CALL TextLayout::queryTextShapes( ) throw (uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; OutputDevice& rOutDev = mpOutDevProvider->getOutDev(); VirtualDevice aVDev( rOutDev ); @@ -165,7 +166,7 @@ namespace vclcanvas uno::Sequence< geometry::RealRectangle2D > SAL_CALL TextLayout::queryInkMeasures( ) throw (uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; OutputDevice& rOutDev = mpOutDevProvider->getOutDev(); @@ -217,7 +218,7 @@ namespace vclcanvas uno::Sequence< geometry::RealRectangle2D > SAL_CALL TextLayout::queryMeasures( ) throw (uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; // TODO(F1) return uno::Sequence< geometry::RealRectangle2D >(); @@ -225,14 +226,14 @@ namespace vclcanvas uno::Sequence< double > SAL_CALL TextLayout::queryLogicalAdvancements( ) throw (uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; return maLogicalAdvancements; } void SAL_CALL TextLayout::applyLogicalAdvancements( const uno::Sequence< double >& aAdvancements ) throw (lang::IllegalArgumentException, uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; ENSURE_ARG_OR_THROW( aAdvancements.getLength() == maText.Length, "TextLayout::applyLogicalAdvancements(): mismatching number of advancements" ); @@ -242,7 +243,7 @@ namespace vclcanvas geometry::RealRectangle2D SAL_CALL TextLayout::queryTextBounds( ) throw (uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; if( !mpOutDevProvider ) return geometry::RealRectangle2D(); @@ -280,7 +281,7 @@ namespace vclcanvas double SAL_CALL TextLayout::justify( double nSize ) throw (lang::IllegalArgumentException, uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; (void)nSize; @@ -291,7 +292,7 @@ namespace vclcanvas double SAL_CALL TextLayout::combinedJustify( const uno::Sequence< uno::Reference< rendering::XTextLayout > >& aNextLayouts, double nSize ) throw (lang::IllegalArgumentException, uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; (void)aNextLayouts; (void)nSize; @@ -302,7 +303,7 @@ namespace vclcanvas rendering::TextHit SAL_CALL TextLayout::getTextHit( const geometry::RealPoint2D& aHitPoint ) throw (uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; (void)aHitPoint; @@ -312,7 +313,7 @@ namespace vclcanvas rendering::Caret SAL_CALL TextLayout::getCaret( sal_Int32 nInsertionIndex, sal_Bool bExcludeLigatures ) throw (lang::IndexOutOfBoundsException, uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; (void)nInsertionIndex; (void)bExcludeLigatures; @@ -323,7 +324,7 @@ namespace vclcanvas sal_Int32 SAL_CALL TextLayout::getNextInsertionIndex( sal_Int32 nStartIndex, sal_Int32 nCaretAdvancement, sal_Bool bExcludeLigatures ) throw (lang::IndexOutOfBoundsException, uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; (void)nStartIndex; (void)nCaretAdvancement; @@ -335,7 +336,7 @@ namespace vclcanvas uno::Reference< rendering::XPolyPolygon2D > SAL_CALL TextLayout::queryVisualHighlighting( sal_Int32 nStartIndex, sal_Int32 nEndIndex ) throw (lang::IndexOutOfBoundsException, uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; (void)nStartIndex; (void)nEndIndex; @@ -346,7 +347,7 @@ namespace vclcanvas uno::Reference< rendering::XPolyPolygon2D > SAL_CALL TextLayout::queryLogicalHighlighting( sal_Int32 nStartIndex, sal_Int32 nEndIndex ) throw (lang::IndexOutOfBoundsException, uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; (void)nStartIndex; (void)nEndIndex; @@ -357,7 +358,7 @@ namespace vclcanvas double SAL_CALL TextLayout::getBaselineOffset( ) throw (uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; // TODO(F1) return 0.0; @@ -365,21 +366,21 @@ namespace vclcanvas sal_Int8 SAL_CALL TextLayout::getMainTextDirection( ) throw (uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; return mnTextDirection; } uno::Reference< rendering::XCanvasFont > SAL_CALL TextLayout::getFont( ) throw (uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; return mpFont.getRef(); } rendering::StringContext SAL_CALL TextLayout::getText( ) throw (uno::RuntimeException) { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; return maText; } @@ -389,7 +390,7 @@ namespace vclcanvas const rendering::ViewState& viewState, const rendering::RenderState& renderState ) const { - tools::LocalGuard aGuard; + SolarMutexGuard aGuard; setupLayoutMode( rOutDev, mnTextDirection ); @@ -494,3 +495,5 @@ namespace vclcanvas return aRet; } } + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/textlayout.hxx b/canvas/source/vcl/textlayout.hxx index ad443ae76376..faca5c001cac 100644 --- a/canvas/source/vcl/textlayout.hxx +++ b/canvas/source/vcl/textlayout.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -113,3 +114,5 @@ namespace vclcanvas } #endif /* _VCLCANVAS_TEXTLAYOUT_HXX */ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/windowoutdevholder.cxx b/canvas/source/vcl/windowoutdevholder.cxx index 9515912a1d93..414cc3c9d4ed 100644 --- a/canvas/source/vcl/windowoutdevholder.cxx +++ b/canvas/source/vcl/windowoutdevholder.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -55,3 +56,5 @@ namespace vclcanvas mrOutputWindow( windowFromXWin(xWin) ) {} } + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/canvas/source/vcl/windowoutdevholder.hxx b/canvas/source/vcl/windowoutdevholder.hxx index ae20a49462e1..4687b1d2e421 100644 --- a/canvas/source/vcl/windowoutdevholder.hxx +++ b/canvas/source/vcl/windowoutdevholder.hxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -64,3 +65,5 @@ namespace vclcanvas } #endif /* _VCLCANVAS_WINDOWOUTDEVHOLDER_HXX */ + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |