diff options
Diffstat (limited to 'canvas/source/vcl/canvas.cxx')
-rw-r--r-- | canvas/source/vcl/canvas.cxx | 21 |
1 files changed, 16 insertions, 5 deletions
diff --git a/canvas/source/vcl/canvas.cxx b/canvas/source/vcl/canvas.cxx index 2ad0a61fc9fd..4a3b6f8d766b 100644 --- a/canvas/source/vcl/canvas.cxx +++ b/canvas/source/vcl/canvas.cxx @@ -23,9 +23,9 @@ #include <com/sun/star/lang/NoSupportException.hpp> #include <sal/log.hxx> -#include <tools/diagnose_ex.h> +#include <comphelper/diagnose_ex.hxx> +#include <cppuhelper/supportsservice.hxx> #include <vcl/outdev.hxx> -#include <vcl/window.hxx> #include "outdevholder.hxx" @@ -94,7 +94,19 @@ namespace vclcanvas OUString SAL_CALL Canvas::getServiceName( ) { - return "com.sun.star.rendering.Canvas.VCL"; + return u"com.sun.star.rendering.Canvas.VCL"_ustr; + } + + OUString Canvas::getImplementationName() { + return u"com.sun.star.comp.rendering.Canvas.VCL"_ustr; + } + + sal_Bool Canvas::supportsService(OUString const & ServiceName) { + return cppu::supportsService(this, ServiceName); + } + + css::uno::Sequence<OUString> Canvas::getSupportedServiceNames() { + return {getServiceName()}; } bool Canvas::repaint( const GraphicObjectSharedPtr& rGrf, @@ -115,9 +127,8 @@ com_sun_star_comp_rendering_Canvas_VCL_get_implementation( css::uno::XComponentContext* context, css::uno::Sequence<css::uno::Any> const& args) { rtl::Reference<vclcanvas::Canvas> p = new vclcanvas::Canvas(args, context); - cppu::acquire(p.get()); p->initialize(); - return static_cast<cppu::OWeakObject*>(p.get()); + return cppu::acquire(p.get()); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |