summaryrefslogtreecommitdiff
path: root/sw/source/ui/vba/service.cxx
blob: 33f875bbbb5b42add100785fff3b308d2f1397b9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*
 * This file is part of the LibreOffice project.
 *
 * This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
 *
 * This file incorporates work covered by the following license notice:
 *
 *   Licensed to the Apache Software Foundation (ASF) under one or more
 *   contributor license agreements. See the NOTICE file distributed
 *   with this work for additional information regarding copyright
 *   ownership. The ASF licenses this file to you under the Apache
 *   License, Version 2.0 (the "License"); you may not use this file
 *   except in compliance with the License. You may obtain a copy of
 *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
 */
#include <cppuhelper/implementationentry.hxx>
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
#include <com/sun/star/registry/XRegistryKey.hpp>
#include <osl/diagnose.h>
#include <comphelper/servicedecl.hxx>

// component exports

namespace sdecl = comphelper::service_decl;

namespace globals
{
extern sdecl::ServiceDecl const serviceDecl;
}

namespace document
{
extern sdecl::ServiceDecl const serviceDecl;
}

namespace wrapformat
{
extern sdecl::ServiceDecl const serviceDecl;
}

namespace vbaeventshelper
{
extern sdecl::ServiceDecl const serviceDecl;
}

namespace vbaeventshelper
{
extern sdecl::ServiceDecl const serviceDecl;
}

extern "C" SAL_DLLPUBLIC_EXPORT void * SAL_CALL vbaswobj_component_getFactory(
    const sal_Char * pImplName, void * pServiceManager,
    void * pRegistryKey )
{
    void* pRet = component_getFactoryHelper(pImplName,
            static_cast<css::lang::XMultiServiceFactory *>(pServiceManager),
            static_cast<css::registry::XRegistryKey *>(pRegistryKey),
            globals::serviceDecl, ::document::serviceDecl,
            wrapformat::serviceDecl, vbaeventshelper::serviceDecl );
    OSL_TRACE("Ret is 0x%p", pRet);
    return pRet;
}

/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
nvasBitmap)" d6a70bb641b96e8e5616448c2378131ed62658b4 "loplugin:unocast (basegfx::unotools::UnoPolyPolygon)" 5a14f009e6782c077463c8cbb8e9cea3d7950107 "loplugin:unocast (xmlsecurity::Certificate)" 99009c9535dfa3e0d838989ccc7d84bfa2320ff4 "loplugin:unocast (sd::Annotation)" 0c7585c5fa78887e5459885ed744e8044fd76137 "loplugin:unocast (sd::TextApiObject)" 24e14afd1bfcaed6c200ab081973fba7e47267ca "loplugin:unocast (SignatureVerifierImpl)" 1a7ad0c10d286ce9ae2700ceb2fd50eed1fb43a4 "loplugin:unocast (pcr::PropertyEventTranslation)" a97e2d2702d9a6f37775ccee2c08c4f3b2479c4b "loplugin:unocast (RangePageBreaks)" 19dfdf86ad1f5b08041d8b7a9f196caf881231ab "iloplugin:unocast (pcr::OFormattedNumericControl)" f9785ea595fd8e911f6370e836fa579225b9e571 "loplugin:unocast (frm::OInterfaceContainer)" 5e5f40a4a92a31b0932c690219d002fcf18598cf "loplugin:unocast (ScVbaShapes)" 27b35b2c215b4832d4378ec3a7ecbba926552d06 "loplugin:unocast (ScVbaShapeRange)" cb3108f860065928552a86cf8acc4b3a95718ecf "cid#1517812 Dereference null return value" feba0ddb1521d1142560fe54b7d7696ee910237f "loplugin:unocast (weld::TransportAsXWindow)" 4d6c23216559eb48f9943bb49d6e475a6d64ba15 "loplugin:unocast (oox::ForumlaImExportBase)" 4844c096a8ab6a9a620c410a0949d4499f12a504 "loplugin:unocast (cairocanvas::SurfaceProvider)" 9a0b523e0a84d403b9092176ccec4b3e3efe42d0 "loplugin:unocast (cairocanvas::CanvasBitmap)" 8a5648d8e59b4b007dbbf3824777c19a21efc61e "loplugin:unocast (cairocanvas::TextLayout)" 28c27a0623bc78a0590858f97d03b620985bc84c "loplugin:unocast (cairocanvas::CanvasFont)" 53bc223cb3288e32a417696ee61c29e5f01f209d "loplugin:unocast (cairocanvas::RepaintTarget)" 5f70b0b9f6bc4ab145ddbd9155590ed4a3b1b9ec "loplugin:unocast (SvXMLImport)" 068187a898cdd2e26e9b16c348ecc1ed2dee3f29 "loplugin:unocast (VCLXWindow)" 88b4f966202717cd4ad38a30a8eda22c3e69ed35 "loplugin:unocast (sfx2::sidebar::SidebarController)" f1b7a69b280aefe2f1b3b0f32193494fd765f2bd "loplugin:unocast (SvxLineStyleToolBoxControl)" ba76f0ba7e8de4d2953739c952004b7d9af47197 "loplugin:unocast (i18npool::Calendar_gregorian)" 840154daf934d8df52ead1cb7acd798c4d30f007 "loplugin:unocast (framework::AddonsToolBarWrapper)" b0e9c4c5f063cefa9557810e3349bdb9c7493091 "loplugin:unocast (GrammarCheckingIterator)" 8ee6cfc9655ce9de4617cea1a0d9cb9d7a4fbfac "loplugin:unocast (ucb::ucp::ext::Content)" 5b8cd77c112bc8c0e92b8fec215c3c8e802bbc0a "loplugin:unocast (basic::SfxScriptLibraryContainer)" 9e73ff9fce12e102bb3c3cea8d8bb96c88f2c9ad "loplugin:unocast (sdext::presenter::PresenterNotesView)" a98acca8fbc38d3fd5600ae5056a8e42b6d8a40d "loplugin:unocast (SelectionChangeHandler)" c0b59ad6e35b0cb0dea0821e95f95569739078c1 "Consistently use comphelper::getSomethingImpl<I>(aIdentifier, this)" 276e3ccbdd3259ec3daf8a1a98fa7f406b14e21c "loplugin:unocast (vclcanvas::RepaintTarget)" Change-Id: I37c73e3422a5154bf6cb647640d2d3f23db8bc34 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145063 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com> 2022-12-18loplugin:unocast (cairocanvas::CanvasBitmap)Stephan Bergmann (See the upcoming commit introducing that loplugin:unocast on why such dynamic_casts from UNO types are dangerous.) Change-Id: I6044567e4027fe1fdc361917d5233157d4ce98d3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/144399 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com> 2022-12-17loplugin:unocast (cairocanvas::RepaintTarget)Stephan Bergmann (See the upcoming commit introducing that loplugin:unocast on why such dynamic_casts from UNO types are dangerous.) Change-Id: Ida4ccf961301cf50396e80d9bbdc4b9925bd81f7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/144350 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com> 2022-05-21clang-tidy modernize-pass-by-value in canvasNoel Grandin Change-Id: Ib6e1b6182d83b09dbf5e2aeb9cf3e4ca11d9f48b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134712 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2020-11-01Transport Pixmap from GetNativeSurfaceHandle via css::uno::Any as sal_Int64Stephan Bergmann The values returned from GetNativeSurfaceHandle are only used in cairocanvas::CanvasBitmap::getFastPropertyValue (canvas/source/cairo/cairo_canvasbitmap.cxx), whose consumers in turn are (at least the ones I could identify): * OGLTransitionerImpl::setSlides (slideshow/source/engine/opengl/TransitionerImpl.cxx), passing the values on to X11SalObject::SetLeaveEnterBackgrounds, which extracts the Pixmap value to pass it on to XSetWindowBackgroundPixmap. * X11SalBitmap::Create (vcl/unx/generic/gdi/salbmp.cxx), which extracts the Pixmap value to pass it on to X11SalBitmap::ImplCreateFromDrawable (as a Drawable) and to XFreePixmap. While Pixmap XIDs are apparently 32-bit in the X11 protocol, see e.g. <https://www.x.org/releases/X11R7.7/doc/xproto/x11protocol.html>, Xlib and the underlying /usr/include/X11/Xdefs.h appear to be somewhat confused whether the typedef for XID should be unsigned long (presumably stemming from times when long was universally 32-bit) or CARD32, see e.g. <https://gitlab.freedesktop.org /xorg/proto/xorgproto/-/blob/master/include/X11/Xdefs.h>. So conservatively stick to a 64-bit type here, even if it should only ever contain 32-bit values. Change-Id: I26c3a2ff74cef092042a6e3648cd9a6f4a9e3aac Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105144 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com> 2020-03-23tdf#124176 Use pragma once instead of include guardsgokaysatir Change-Id: I3077e6e3a043401e66cd527c5f69b8571e8b25d5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90915 Tested-by: Jenkins Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com> 2020-02-12move some canvas/ headers inside the moduleNoel Grandin Change-Id: Iaa00cff88ad756b7e084cc68fe744d387328180b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88360 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> 2019-10-30tdf#42949 Fix IWYU warnings in canvas/source/*/*hxxGabor Kelemen Except directx/ Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: I4504e087edfd837a3a91df49e296bbf40778b030 Reviewed-on: https://gerrit.libreoffice.org/81586 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com> 2017-01-27Fix comments to match realityTor Lillqvist Change-Id: I99b49a3c8472b063316baeebdaa89119832a2a1b 2017-01-26Remove dynamic exception specificationsStephan Bergmann ...(for now, from LIBO_INTERNAL_CODE only). See the mail thread starting at <https://lists.freedesktop.org/archives/libreoffice/2017-January/076665.html> "Dynamic Exception Specifications" for details. Most changes have been done automatically by the rewriting loplugin:dynexcspec (after enabling the rewriting mode, to be committed shortly). The way it only removes exception specs from declarations if it also sees a definition, it identified some dead declarations-w/o-definitions (that have been removed manually) and some cases where a definition appeared in multiple include files (which have also been cleaned up manually). There's also been cases of macro paramters (that were used to abstract over exception specs) that have become unused now (and been removed). Furthermore, some code needed to be cleaned up manually (avmedia/source/quicktime/ and connectivity/source/drivers/kab/), as I had no configurations available that would actually build that code. Missing @throws documentation has not been applied in such manual clean-up. Change-Id: I3408691256c9b0c12bc5332de976743626e13960 Reviewed-on: https://gerrit.libreoffice.org/33574 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com> 2016-08-05loplugin:countusersofdefaultparams in canvas,chart2Noel Grandin Change-Id: Id66a706171b73affeb508812744028d9f30133af Reviewed-on: https://gerrit.libreoffice.org/27868 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com> 2016-06-03loplugin:constantparamsNoel Grandin Change-Id: Ib162ba9297b9d900ea42c7e5216e152d3e58a361 Reviewed-on: https://gerrit.libreoffice.org/25769 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>