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 <mutationevent.hxx>
21 :
22 : namespace DOM { namespace events
23 : {
24 0 : CMutationEvent::CMutationEvent()
25 : : CMutationEvent_Base()
26 0 : , m_attrChangeType(AttrChangeType_MODIFICATION)
27 : {
28 0 : }
29 :
30 0 : CMutationEvent::~CMutationEvent()
31 : {
32 0 : }
33 :
34 0 : Reference< XNode > SAL_CALL CMutationEvent::getRelatedNode() throw (RuntimeException, std::exception)
35 : {
36 0 : ::osl::MutexGuard const g(m_Mutex);
37 0 : return m_relatedNode;
38 : }
39 :
40 0 : OUString SAL_CALL CMutationEvent::getPrevValue() throw (RuntimeException, std::exception)
41 : {
42 0 : ::osl::MutexGuard const g(m_Mutex);
43 0 : return m_prevValue;
44 : }
45 :
46 0 : OUString SAL_CALL CMutationEvent::getNewValue() throw (RuntimeException, std::exception)
47 : {
48 0 : ::osl::MutexGuard const g(m_Mutex);
49 0 : return m_newValue;
50 : }
51 :
52 0 : OUString SAL_CALL CMutationEvent::getAttrName() throw (RuntimeException, std::exception)
53 : {
54 0 : ::osl::MutexGuard const g(m_Mutex);
55 0 : return m_attrName;
56 : }
57 :
58 0 : AttrChangeType SAL_CALL CMutationEvent::getAttrChange() throw (RuntimeException, std::exception)
59 : {
60 0 : ::osl::MutexGuard const g(m_Mutex);
61 0 : return m_attrChangeType;
62 : }
63 :
64 0 : void SAL_CALL CMutationEvent::initMutationEvent(const OUString& typeArg,
65 : sal_Bool canBubbleArg, sal_Bool cancelableArg,
66 : const Reference< XNode >& relatedNodeArg, const OUString& prevValueArg,
67 : const OUString& newValueArg, const OUString& attrNameArg,
68 : AttrChangeType attrChangeArg) throw (RuntimeException, std::exception)
69 : {
70 0 : ::osl::MutexGuard const g(m_Mutex);
71 :
72 0 : CEvent::initEvent(typeArg, canBubbleArg, cancelableArg);
73 0 : m_relatedNode = relatedNodeArg;
74 0 : m_prevValue = prevValueArg;
75 0 : m_newValue = newValueArg;
76 0 : m_attrName = attrNameArg;
77 0 : m_attrChangeType = attrChangeArg;
78 0 : }
79 :
80 : // delegate to CEvent, since we are inheriting from CEvent and XEvent
81 0 : OUString SAL_CALL CMutationEvent::getType() throw (RuntimeException, std::exception)
82 : {
83 0 : return CEvent::getType();
84 : }
85 :
86 0 : Reference< XEventTarget > SAL_CALL CMutationEvent::getTarget() throw (RuntimeException, std::exception)
87 : {
88 0 : return CEvent::getTarget();
89 : }
90 :
91 0 : Reference< XEventTarget > SAL_CALL CMutationEvent::getCurrentTarget() throw (RuntimeException, std::exception)
92 : {
93 0 : return CEvent::getCurrentTarget();
94 : }
95 :
96 0 : PhaseType SAL_CALL CMutationEvent::getEventPhase() throw (RuntimeException, std::exception)
97 : {
98 0 : return CEvent::getEventPhase();
99 : }
100 :
101 0 : sal_Bool SAL_CALL CMutationEvent::getBubbles() throw (RuntimeException, std::exception)
102 : {
103 0 : return CEvent::getBubbles();
104 : }
105 :
106 0 : sal_Bool SAL_CALL CMutationEvent::getCancelable() throw (RuntimeException, std::exception)
107 : {
108 0 : return CEvent::getCancelable();
109 : }
110 :
111 0 : com::sun::star::util::Time SAL_CALL CMutationEvent::getTimeStamp() throw (RuntimeException, std::exception)
112 : {
113 0 : return CEvent::getTimeStamp();
114 : }
115 :
116 0 : void SAL_CALL CMutationEvent::stopPropagation() throw (RuntimeException, std::exception)
117 : {
118 0 : CEvent::stopPropagation();
119 0 : }
120 0 : void SAL_CALL CMutationEvent::preventDefault() throw (RuntimeException, std::exception)
121 : {
122 0 : CEvent::preventDefault();
123 0 : }
124 :
125 0 : void SAL_CALL CMutationEvent::initEvent(const OUString& eventTypeArg, sal_Bool canBubbleArg,
126 : sal_Bool cancelableArg) throw (RuntimeException, std::exception)
127 : {
128 : // base initializer
129 0 : CEvent::initEvent(eventTypeArg, canBubbleArg, cancelableArg);
130 0 : }
131 : }}
132 :
133 : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|