bump product version to 5.0.4.1
[LibreOffice.git] / sd / source / ui / presenter / PresenterHelper.hxx
blob4f1625bc919bc044136630fb03778954042c9183
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
20 #ifndef INCLUDED_SD_SOURCE_UI_PRESENTER_PRESENTERHELPER_HXX
21 #define INCLUDED_SD_SOURCE_UI_PRESENTER_PRESENTERHELPER_HXX
23 #include <com/sun/star/drawing/XPresenterHelper.hpp>
24 #include <com/sun/star/lang/XInitialization.hpp>
25 #include <com/sun/star/uno/XComponentContext.hpp>
26 #include <cppuhelper/basemutex.hxx>
27 #include <cppuhelper/compbase2.hxx>
28 #include <boost/noncopyable.hpp>
30 namespace sd { namespace presenter {
32 namespace {
33 typedef ::cppu::WeakComponentImplHelper2<
34 css::lang::XInitialization,
35 css::drawing::XPresenterHelper
36 > PresenterHelperInterfaceBase;
39 /** Implementation of the XPresenterHelper interface: functionality that can
40 not be implemented in an extension.
42 class PresenterHelper
43 : private ::boost::noncopyable,
44 private ::cppu::BaseMutex,
45 public PresenterHelperInterfaceBase
47 public:
48 PresenterHelper (const css::uno::Reference<css::uno::XComponentContext>& rxContext);
49 virtual ~PresenterHelper();
51 // XInitialize
53 virtual void SAL_CALL initialize (const css::uno::Sequence<css::uno::Any>& rArguments)
54 throw(css::uno::Exception,css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
56 // XPresenterHelper
58 virtual css::uno::Reference<css::awt::XWindow> SAL_CALL createWindow (
59 const css::uno::Reference<css::awt::XWindow>& rxParentWindow,
60 sal_Bool bCreateSystemChildWindow,
61 sal_Bool bInitiallyVisible,
62 sal_Bool bEnableChildTransparentMode,
63 sal_Bool bEnableParentClip)
64 throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
66 virtual css::uno::Reference<css::rendering::XCanvas> SAL_CALL createSharedCanvas (
67 const css::uno::Reference<css::rendering::XSpriteCanvas>& rxUpdateCanvas,
68 const css::uno::Reference<css::awt::XWindow>& rxUpdateWindow,
69 const css::uno::Reference<css::rendering::XCanvas>& rxSharedCanvas,
70 const css::uno::Reference<css::awt::XWindow>& rxSharedWindow,
71 const css::uno::Reference<css::awt::XWindow>& rxWindow)
72 throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
74 virtual css::uno::Reference<css::rendering::XCanvas> SAL_CALL createCanvas (
75 const css::uno::Reference<css::awt::XWindow>& rxWindow,
76 sal_Int16 nRequestedCanvasFeatures,
77 const OUString& rsOptionalCanvasServiceName)
78 throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
80 virtual void SAL_CALL toTop (
81 const css::uno::Reference<css::awt::XWindow>& rxWindow)
82 throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
84 virtual css::uno::Reference<css::rendering::XBitmap> SAL_CALL loadBitmap (
85 const OUString& rsURL,
86 const css::uno::Reference<css::rendering::XCanvas>& rxCanvas)
87 throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
89 virtual void SAL_CALL captureMouse (const css::uno::Reference<css::awt::XWindow>& rxWindow)
90 throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
92 virtual void SAL_CALL releaseMouse (const css::uno::Reference<css::awt::XWindow>& rxWindow)
93 throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
95 virtual css::awt::Rectangle SAL_CALL getWindowExtentsRelative (
96 const css::uno::Reference<css::awt::XWindow>& rxChildWindow,
97 const css::uno::Reference<css::awt::XWindow>& rxParentWindow)
98 throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
100 private:
101 css::uno::Reference<css::uno::XComponentContext> mxComponentContext;
104 } } // end of namespace ::sd::presenter
106 #endif
108 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */