struct_marshallers.cpp

Absolute File Name:/home/qt/qt5_coco/qt5/qtbase/src/platformsupport/linuxaccessibility/struct_marshallers.cpp
Source codeSwitch to Preprocessed file
LineSourceCount
1/****************************************************************************-
2**-
3** Copyright (C) 2015 The Qt Company Ltd.-
4** Contact: http://www.qt.io/licensing/-
5**-
6** This file is part of the QtGui module of the Qt Toolkit.-
7**-
8** $QT_BEGIN_LICENSE:LGPL21$-
9** Commercial License Usage-
10** Licensees holding valid commercial Qt licenses may use this file in-
11** accordance with the commercial license agreement provided with the-
12** Software or, alternatively, in accordance with the terms contained in-
13** a written agreement between you and The Qt Company. For licensing terms-
14** and conditions see http://www.qt.io/terms-conditions. For further-
15** information use the contact form at http://www.qt.io/contact-us.-
16**-
17** GNU Lesser General Public License Usage-
18** Alternatively, this file may be used under the terms of the GNU Lesser-
19** General Public License version 2.1 or version 3 as published by the Free-
20** Software Foundation and appearing in the file LICENSE.LGPLv21 and-
21** LICENSE.LGPLv3 included in the packaging of this file. Please review the-
22** following information to ensure the GNU Lesser General Public License-
23** requirements will be met: https://www.gnu.org/licenses/lgpl.html and-
24** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.-
25**-
26** As a special exception, The Qt Company gives you certain additional-
27** rights. These rights are described in The Qt Company LGPL Exception-
28** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.-
29**-
30** $QT_END_LICENSE$-
31**-
32****************************************************************************/-
33-
34-
35#include "struct_marshallers_p.h"-
36-
37#include <atspi/atspi-constants.h>-
38#include <QtCore/qdebug.h>-
39#include <QtDBus/qdbusmetatype.h>-
40-
41#include "bridge_p.h"-
42-
43#ifndef QT_NO_ACCESSIBILITY-
44QT_BEGIN_NAMESPACE-
45-
46QSpiObjectReference::QSpiObjectReference()-
47 : path(QDBusObjectPath(ATSPI_DBUS_PATH_NULL))-
48{}
never executed: end of block
0
49-
50/* QSpiAccessibleCacheArray */-
51/*---------------------------------------------------------------------------*/-
52-
53QDBusArgument &operator<<(QDBusArgument &argument, const QSpiAccessibleCacheItem &item)-
54{-
55 argument.beginStructure();-
56 argument << item.path;-
57 argument << item.application;-
58 argument << item.parent;-
59 argument << item.children;-
60 argument << item.supportedInterfaces;-
61 argument << item.name;-
62 argument << item.role;-
63 argument << item.description;-
64 argument << item.state;-
65 argument.endStructure();-
66 return argument;
never executed: return argument;
0
67}-
68-
69const QDBusArgument &operator>>(const QDBusArgument &argument, QSpiAccessibleCacheItem &item)-
70{-
71 argument.beginStructure();-
72 argument >> item.path;-
73 argument >> item.application;-
74 argument >> item.parent;-
75 argument >> item.children;-
76 argument >> item.supportedInterfaces;-
77 argument >> item.name;-
78 argument >> item.role;-
79 argument >> item.description;-
80 argument >> item.state;-
81 argument.endStructure();-
82 return argument;
never executed: return argument;
0
83}-
84-
85/* QSpiObjectReference */-
86/*---------------------------------------------------------------------------*/-
87-
88QDBusArgument &operator<<(QDBusArgument &argument, const QSpiObjectReference &address)-
89{-
90 argument.beginStructure();-
91 argument << address.service;-
92 argument << address.path;-
93 argument.endStructure();-
94 return argument;
never executed: return argument;
0
95}-
96-
97const QDBusArgument &operator>>(const QDBusArgument &argument, QSpiObjectReference &address)-
98{-
99 argument.beginStructure();-
100 argument >> address.service;-
101 argument >> address.path;-
102 argument.endStructure();-
103 return argument;
never executed: return argument;
0
104}-
105-
106/* QSpiAction */-
107/*---------------------------------------------------------------------------*/-
108-
109QDBusArgument &operator<<(QDBusArgument &argument, const QSpiAction &action)-
110{-
111 argument.beginStructure();-
112 argument << action.name;-
113 argument << action.description;-
114 argument << action.keyBinding;-
115 argument.endStructure();-
116 return argument;
never executed: return argument;
0
117}-
118-
119const QDBusArgument &operator>>(const QDBusArgument &argument, QSpiAction &action)-
120{-
121 argument.beginStructure();-
122 argument >> action.name;-
123 argument >> action.description;-
124 argument >> action.keyBinding;-
125 argument.endStructure();-
126 return argument;
never executed: return argument;
0
127}-
128-
129-
130QDBusArgument &operator<<(QDBusArgument &argument, const QSpiEventListener &ev)-
131{-
132 argument.beginStructure();-
133 argument << ev.listenerAddress;-
134 argument << ev.eventName;-
135 argument.endStructure();-
136 return argument;
never executed: return argument;
0
137}-
138-
139const QDBusArgument &operator>>(const QDBusArgument &argument, QSpiEventListener &ev)-
140{-
141 argument.beginStructure();-
142 argument >> ev.listenerAddress;-
143 argument >> ev.eventName;-
144 argument.endStructure();-
145 return argument;
never executed: return argument;
0
146}-
147-
148/* QSpiAppUpdate */-
149/*---------------------------------------------------------------------------*/-
150-
151QDBusArgument &operator<<(QDBusArgument &argument, const QSpiAppUpdate &update) {-
152 argument.beginStructure();-
153 argument << update.type << update.address;-
154 argument.endStructure();-
155 return argument;
never executed: return argument;
0
156}-
157-
158const QDBusArgument &operator>>(const QDBusArgument &argument, QSpiAppUpdate &update) {-
159 argument.beginStructure();-
160 argument >> update.type >> update.address;-
161 argument.endStructure();-
162 return argument;
never executed: return argument;
0
163}-
164-
165/* QSpiRelationArrayEntry */-
166/*---------------------------------------------------------------------------*/-
167-
168QDBusArgument &operator<<(QDBusArgument &argument, const QSpiRelationArrayEntry &entry) {-
169 argument.beginStructure();-
170 argument << entry.first << entry.second;-
171 argument.endStructure();-
172 return argument;
never executed: return argument;
0
173}-
174-
175const QDBusArgument &operator>>(const QDBusArgument &argument, QSpiRelationArrayEntry &entry) {-
176 argument.beginStructure();-
177 argument >> entry.first >> entry.second;-
178 argument.endStructure();-
179 return argument;
never executed: return argument;
0
180}-
181-
182/* QSpiDeviceEvent */-
183/*---------------------------------------------------------------------------*/-
184-
185QDBusArgument &operator<<(QDBusArgument &argument, const QSpiDeviceEvent &event) {-
186 argument.beginStructure();-
187 argument << event.type-
188 << event.id-
189 << event.hardwareCode-
190 << event.modifiers-
191 << event.timestamp-
192 << event.text-
193 << event.isText;-
194 argument.endStructure();-
195 return argument;
never executed: return argument;
0
196}-
197-
198const QDBusArgument &operator>>(const QDBusArgument &argument, QSpiDeviceEvent &event) {-
199 argument.beginStructure();-
200 argument >> event.type-
201 >> event.id-
202 >> event.hardwareCode-
203 >> event.modifiers-
204 >> event.timestamp-
205 >> event.text-
206 >> event.isText;-
207 argument.endStructure();-
208 return argument;
never executed: return argument;
0
209}-
210-
211void qSpiInitializeStructTypes()-
212{-
213 qDBusRegisterMetaType<QSpiIntList>();-
214 qDBusRegisterMetaType<QSpiUIntList>();-
215 qDBusRegisterMetaType<QSpiAccessibleCacheItem>();-
216 qDBusRegisterMetaType<QSpiAccessibleCacheArray>();-
217 qDBusRegisterMetaType<QSpiObjectReference>();-
218 qDBusRegisterMetaType<QSpiObjectReferenceArray>();-
219 qDBusRegisterMetaType<QSpiAttributeSet>();-
220 qDBusRegisterMetaType<QSpiAction>();-
221 qDBusRegisterMetaType<QSpiActionArray>();-
222 qDBusRegisterMetaType<QSpiEventListener>();-
223 qDBusRegisterMetaType<QSpiEventListenerArray>();-
224 qDBusRegisterMetaType<QSpiDeviceEvent>();-
225 qDBusRegisterMetaType<QSpiAppUpdate>();-
226 qDBusRegisterMetaType<QSpiRelationArrayEntry>();-
227 qDBusRegisterMetaType<QSpiRelationArray>();-
228}
never executed: end of block
0
229-
230QT_END_NAMESPACE-
231#endif //QT_NO_ACCESSIBILITY-
Source codeSwitch to Preprocessed file

Generated by Squish Coco Non-Commercial 4.3.0-BETA-master-30-08-2018-4cb69e9