Line data Source code
1 : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 : /*
3 : * This file is part of the LibreOffice project.
4 : *
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/.
8 : *
9 : * This file incorporates work covered by the following license notice:
10 : *
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 .
18 : */
19 :
20 : #include <uievent.hxx>
21 :
22 : namespace DOM { namespace events
23 : {
24 0 : CUIEvent::CUIEvent()
25 : : CUIEvent_Base()
26 0 : , m_detail(0)
27 : {
28 0 : }
29 :
30 : Reference< XAbstractView > SAL_CALL
31 0 : CUIEvent::getView() throw(RuntimeException, std::exception)
32 : {
33 0 : ::osl::MutexGuard const g(m_Mutex);
34 0 : return m_view;
35 : }
36 :
37 0 : sal_Int32 SAL_CALL CUIEvent::getDetail() throw(RuntimeException, std::exception)
38 : {
39 0 : ::osl::MutexGuard const g(m_Mutex);
40 0 : return m_detail;
41 : }
42 :
43 0 : void SAL_CALL CUIEvent::initUIEvent(const OUString& typeArg,
44 : sal_Bool canBubbleArg,
45 : sal_Bool cancelableArg,
46 : const Reference< XAbstractView >& viewArg,
47 : sal_Int32 detailArg) throw(RuntimeException, std::exception)
48 : {
49 0 : ::osl::MutexGuard const g(m_Mutex);
50 :
51 0 : CEvent::initEvent(typeArg, canBubbleArg, cancelableArg);
52 0 : m_view = viewArg;
53 0 : m_detail = detailArg;
54 0 : }
55 :
56 :
57 : // delegate to CEvent, since we are inheriting from CEvent and XEvent
58 0 : OUString SAL_CALL CUIEvent::getType() throw (RuntimeException, std::exception)
59 : {
60 0 : return CEvent::getType();
61 : }
62 :
63 0 : Reference< XEventTarget > SAL_CALL CUIEvent::getTarget() throw (RuntimeException, std::exception)
64 : {
65 0 : return CEvent::getTarget();
66 : }
67 :
68 0 : Reference< XEventTarget > SAL_CALL CUIEvent::getCurrentTarget() throw (RuntimeException, std::exception)
69 : {
70 0 : return CEvent::getCurrentTarget();
71 : }
72 :
73 0 : PhaseType SAL_CALL CUIEvent::getEventPhase() throw (RuntimeException, std::exception)
74 : {
75 0 : return CEvent::getEventPhase();
76 : }
77 :
78 0 : sal_Bool SAL_CALL CUIEvent::getBubbles() throw (RuntimeException, std::exception)
79 : {
80 0 : return CEvent::getBubbles();
81 : }
82 :
83 0 : sal_Bool SAL_CALL CUIEvent::getCancelable() throw (RuntimeException, std::exception)
84 : {
85 : // mutation events cannot be canceled
86 0 : return sal_False;
87 : }
88 :
89 0 : com::sun::star::util::Time SAL_CALL CUIEvent::getTimeStamp() throw (RuntimeException, std::exception)
90 : {
91 0 : return CEvent::getTimeStamp();
92 : }
93 :
94 0 : void SAL_CALL CUIEvent::stopPropagation() throw (RuntimeException, std::exception)
95 : {
96 0 : CEvent::stopPropagation();
97 0 : }
98 0 : void SAL_CALL CUIEvent::preventDefault() throw (RuntimeException, std::exception)
99 : {
100 0 : CEvent::preventDefault();
101 0 : }
102 :
103 0 : void SAL_CALL CUIEvent::initEvent(const OUString& eventTypeArg, sal_Bool canBubbleArg,
104 : sal_Bool cancelableArg) throw (RuntimeException, std::exception)
105 : {
106 : // base initializer
107 0 : CEvent::initEvent(eventTypeArg, canBubbleArg, cancelableArg);
108 0 : }
109 : }}
110 :
111 : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|