From 09b546cf9c1d0d9f78066e70a0348c7678cdcb14 Mon Sep 17 00:00:00 2001 From: Thorsten Behrens Date: Fri, 8 Apr 2011 16:44:28 +0200 Subject: Fix overloaded-virtual warning in canvas With enabled -Woverloaded-virtual gcc warning (see http://lists.freedesktop.org/archives/libreoffice/2011-March/009567.html), canvas exposed a nasty clash between WeakComponentImplHelper::disposing and XEventListener::disposing. Fixed by overriding *once* in baseclass, and then calling disambiguated, renamed methods. --- canvas/source/cairo/cairo_spritecanvas.hxx | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) (limited to 'canvas/source/cairo/cairo_spritecanvas.hxx') diff --git a/canvas/source/cairo/cairo_spritecanvas.hxx b/canvas/source/cairo/cairo_spritecanvas.hxx index 54cd3a181cec..b64fd1474c6e 100644 --- a/canvas/source/cairo/cairo_spritecanvas.hxx +++ b/canvas/source/cairo/cairo_spritecanvas.hxx @@ -45,7 +45,7 @@ #include #include -#include +#include #include #include @@ -69,7 +69,7 @@ namespace cairocanvas ::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, ::osl::MutexGuard, ::cppu::OWeakObject > SpriteCanvasBase_Base; @@ -121,12 +121,8 @@ namespace cairocanvas void initialize(); -#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 -- cgit