Line data Source code
1 : //
2 : // Automatically generated by ipdlc.
3 : // Edit at your own risk
4 : //
5 :
6 :
7 : #include "mozilla/dom/GamepadEventTypes.h"
8 :
9 :
10 : //-----------------------------------------------------------------------------
11 : // Method definitions for the IPDL type |struct GamepadAdded|
12 : //
13 : namespace mozilla {
14 : namespace dom {
15 0 : MOZ_IMPLICIT GamepadAdded::GamepadAdded() :
16 : id_(),
17 : index_(),
18 : mapping_(),
19 : hand_(),
20 : service_type_(),
21 : num_buttons_(),
22 : num_axes_(),
23 0 : num_haptics_()
24 : {
25 0 : Init();
26 0 : }
27 :
28 0 : GamepadAdded::~GamepadAdded()
29 : {
30 0 : }
31 :
32 0 : auto GamepadAdded::operator==(const GamepadAdded& _o) const -> bool
33 : {
34 0 : if ((!((id()) == ((_o).id())))) {
35 0 : return false;
36 : }
37 0 : if ((!((index()) == ((_o).index())))) {
38 0 : return false;
39 : }
40 0 : if ((!((mapping()) == ((_o).mapping())))) {
41 0 : return false;
42 : }
43 0 : if ((!((hand()) == ((_o).hand())))) {
44 0 : return false;
45 : }
46 0 : if ((!((service_type()) == ((_o).service_type())))) {
47 0 : return false;
48 : }
49 0 : if ((!((num_buttons()) == ((_o).num_buttons())))) {
50 0 : return false;
51 : }
52 0 : if ((!((num_axes()) == ((_o).num_axes())))) {
53 0 : return false;
54 : }
55 0 : if ((!((num_haptics()) == ((_o).num_haptics())))) {
56 0 : return false;
57 : }
58 0 : return true;
59 : }
60 :
61 0 : auto GamepadAdded::operator!=(const GamepadAdded& _o) const -> bool
62 : {
63 0 : return (!(operator==(_o)));
64 : }
65 :
66 0 : auto GamepadAdded::Init() -> void
67 : {
68 0 : }
69 :
70 0 : auto GamepadAdded::Assign(
71 : const nsString& _id,
72 : const uint32_t& _index,
73 : const GamepadMappingType& _mapping,
74 : const GamepadHand& _hand,
75 : const GamepadServiceType& _service_type,
76 : const uint32_t& _num_buttons,
77 : const uint32_t& _num_axes,
78 : const uint32_t& _num_haptics) -> void
79 : {
80 0 : id_ = _id;
81 0 : index_ = _index;
82 0 : mapping_ = _mapping;
83 0 : hand_ = _hand;
84 0 : service_type_ = _service_type;
85 0 : num_buttons_ = _num_buttons;
86 0 : num_axes_ = _num_axes;
87 0 : num_haptics_ = _num_haptics;
88 0 : }
89 :
90 : } // namespace dom
91 : } // namespace mozilla
92 :
93 : //-----------------------------------------------------------------------------
94 : // Method definitions for the IPDL type |struct GamepadRemoved|
95 : //
96 : namespace mozilla {
97 : namespace dom {
98 0 : MOZ_IMPLICIT GamepadRemoved::GamepadRemoved() :
99 : index_(),
100 0 : service_type_()
101 : {
102 0 : Init();
103 0 : }
104 :
105 0 : GamepadRemoved::~GamepadRemoved()
106 : {
107 0 : }
108 :
109 0 : auto GamepadRemoved::operator==(const GamepadRemoved& _o) const -> bool
110 : {
111 0 : if ((!((index()) == ((_o).index())))) {
112 0 : return false;
113 : }
114 0 : if ((!((service_type()) == ((_o).service_type())))) {
115 0 : return false;
116 : }
117 0 : return true;
118 : }
119 :
120 0 : auto GamepadRemoved::operator!=(const GamepadRemoved& _o) const -> bool
121 : {
122 0 : return (!(operator==(_o)));
123 : }
124 :
125 0 : auto GamepadRemoved::Init() -> void
126 : {
127 0 : }
128 :
129 0 : auto GamepadRemoved::Assign(
130 : const uint32_t& _index,
131 : const GamepadServiceType& _service_type) -> void
132 : {
133 0 : index_ = _index;
134 0 : service_type_ = _service_type;
135 0 : }
136 :
137 : } // namespace dom
138 : } // namespace mozilla
139 :
140 : //-----------------------------------------------------------------------------
141 : // Method definitions for the IPDL type |struct GamepadAxisInformation|
142 : //
143 : namespace mozilla {
144 : namespace dom {
145 0 : MOZ_IMPLICIT GamepadAxisInformation::GamepadAxisInformation() :
146 : index_(),
147 : service_type_(),
148 : axis_(),
149 0 : value_()
150 : {
151 0 : Init();
152 0 : }
153 :
154 0 : GamepadAxisInformation::~GamepadAxisInformation()
155 : {
156 0 : }
157 :
158 0 : auto GamepadAxisInformation::operator==(const GamepadAxisInformation& _o) const -> bool
159 : {
160 0 : if ((!((index()) == ((_o).index())))) {
161 0 : return false;
162 : }
163 0 : if ((!((service_type()) == ((_o).service_type())))) {
164 0 : return false;
165 : }
166 0 : if ((!((axis()) == ((_o).axis())))) {
167 0 : return false;
168 : }
169 0 : if ((!((value()) == ((_o).value())))) {
170 0 : return false;
171 : }
172 0 : return true;
173 : }
174 :
175 0 : auto GamepadAxisInformation::operator!=(const GamepadAxisInformation& _o) const -> bool
176 : {
177 0 : return (!(operator==(_o)));
178 : }
179 :
180 0 : auto GamepadAxisInformation::Init() -> void
181 : {
182 0 : }
183 :
184 0 : auto GamepadAxisInformation::Assign(
185 : const uint32_t& _index,
186 : const GamepadServiceType& _service_type,
187 : const uint32_t& _axis,
188 : const double& _value) -> void
189 : {
190 0 : index_ = _index;
191 0 : service_type_ = _service_type;
192 0 : axis_ = _axis;
193 0 : value_ = _value;
194 0 : }
195 :
196 : } // namespace dom
197 : } // namespace mozilla
198 :
199 : //-----------------------------------------------------------------------------
200 : // Method definitions for the IPDL type |struct GamepadButtonInformation|
201 : //
202 : namespace mozilla {
203 : namespace dom {
204 0 : MOZ_IMPLICIT GamepadButtonInformation::GamepadButtonInformation() :
205 : index_(),
206 : service_type_(),
207 : button_(),
208 : value_(),
209 : pressed_(),
210 0 : touched_()
211 : {
212 0 : Init();
213 0 : }
214 :
215 0 : GamepadButtonInformation::~GamepadButtonInformation()
216 : {
217 0 : }
218 :
219 0 : auto GamepadButtonInformation::operator==(const GamepadButtonInformation& _o) const -> bool
220 : {
221 0 : if ((!((index()) == ((_o).index())))) {
222 0 : return false;
223 : }
224 0 : if ((!((service_type()) == ((_o).service_type())))) {
225 0 : return false;
226 : }
227 0 : if ((!((button()) == ((_o).button())))) {
228 0 : return false;
229 : }
230 0 : if ((!((value()) == ((_o).value())))) {
231 0 : return false;
232 : }
233 0 : if ((!((pressed()) == ((_o).pressed())))) {
234 0 : return false;
235 : }
236 0 : if ((!((touched()) == ((_o).touched())))) {
237 0 : return false;
238 : }
239 0 : return true;
240 : }
241 :
242 0 : auto GamepadButtonInformation::operator!=(const GamepadButtonInformation& _o) const -> bool
243 : {
244 0 : return (!(operator==(_o)));
245 : }
246 :
247 0 : auto GamepadButtonInformation::Init() -> void
248 : {
249 0 : }
250 :
251 0 : auto GamepadButtonInformation::Assign(
252 : const uint32_t& _index,
253 : const GamepadServiceType& _service_type,
254 : const uint32_t& _button,
255 : const double& _value,
256 : const bool& _pressed,
257 : const bool& _touched) -> void
258 : {
259 0 : index_ = _index;
260 0 : service_type_ = _service_type;
261 0 : button_ = _button;
262 0 : value_ = _value;
263 0 : pressed_ = _pressed;
264 0 : touched_ = _touched;
265 0 : }
266 :
267 : } // namespace dom
268 : } // namespace mozilla
269 :
270 : //-----------------------------------------------------------------------------
271 : // Method definitions for the IPDL type |struct GamepadPoseInformation|
272 : //
273 : namespace mozilla {
274 : namespace dom {
275 0 : MOZ_IMPLICIT GamepadPoseInformation::GamepadPoseInformation() :
276 : index_(),
277 : service_type_(),
278 0 : pose_state_()
279 : {
280 0 : Init();
281 0 : }
282 :
283 0 : GamepadPoseInformation::~GamepadPoseInformation()
284 : {
285 0 : }
286 :
287 0 : auto GamepadPoseInformation::operator==(const GamepadPoseInformation& _o) const -> bool
288 : {
289 0 : if ((!((index()) == ((_o).index())))) {
290 0 : return false;
291 : }
292 0 : if ((!((service_type()) == ((_o).service_type())))) {
293 0 : return false;
294 : }
295 0 : if ((!((pose_state()) == ((_o).pose_state())))) {
296 0 : return false;
297 : }
298 0 : return true;
299 : }
300 :
301 0 : auto GamepadPoseInformation::operator!=(const GamepadPoseInformation& _o) const -> bool
302 : {
303 0 : return (!(operator==(_o)));
304 : }
305 :
306 0 : auto GamepadPoseInformation::Init() -> void
307 : {
308 0 : }
309 :
310 0 : auto GamepadPoseInformation::Assign(
311 : const uint32_t& _index,
312 : const GamepadServiceType& _service_type,
313 : const GamepadPoseState& _pose_state) -> void
314 : {
315 0 : index_ = _index;
316 0 : service_type_ = _service_type;
317 0 : pose_state_ = _pose_state;
318 0 : }
319 :
320 : } // namespace dom
321 : } // namespace mozilla
322 :
323 : //-----------------------------------------------------------------------------
324 : // Method definitions for the IPDL type |struct GamepadHandInformation|
325 : //
326 : namespace mozilla {
327 : namespace dom {
328 0 : MOZ_IMPLICIT GamepadHandInformation::GamepadHandInformation() :
329 : index_(),
330 : service_type_(),
331 0 : hand_()
332 : {
333 0 : Init();
334 0 : }
335 :
336 0 : GamepadHandInformation::~GamepadHandInformation()
337 : {
338 0 : }
339 :
340 0 : auto GamepadHandInformation::operator==(const GamepadHandInformation& _o) const -> bool
341 : {
342 0 : if ((!((index()) == ((_o).index())))) {
343 0 : return false;
344 : }
345 0 : if ((!((service_type()) == ((_o).service_type())))) {
346 0 : return false;
347 : }
348 0 : if ((!((hand()) == ((_o).hand())))) {
349 0 : return false;
350 : }
351 0 : return true;
352 : }
353 :
354 0 : auto GamepadHandInformation::operator!=(const GamepadHandInformation& _o) const -> bool
355 : {
356 0 : return (!(operator==(_o)));
357 : }
358 :
359 0 : auto GamepadHandInformation::Init() -> void
360 : {
361 0 : }
362 :
363 0 : auto GamepadHandInformation::Assign(
364 : const uint32_t& _index,
365 : const GamepadServiceType& _service_type,
366 : const GamepadHand& _hand) -> void
367 : {
368 0 : index_ = _index;
369 0 : service_type_ = _service_type;
370 0 : hand_ = _hand;
371 0 : }
372 :
373 : } // namespace dom
374 : } // namespace mozilla
375 :
376 : //-----------------------------------------------------------------------------
377 : // Method definitions for the IPDL type |union GamepadChangeEvent|
378 : //
379 : namespace mozilla {
380 : namespace dom {
381 0 : auto GamepadChangeEvent::MaybeDestroy(Type aNewType) -> bool
382 : {
383 0 : if ((mType) == (T__None)) {
384 0 : return true;
385 : }
386 0 : if ((mType) == (aNewType)) {
387 0 : return false;
388 : }
389 0 : switch (mType) {
390 : case TGamepadAdded:
391 : {
392 0 : (ptr_GamepadAdded())->~GamepadAdded__tdef();
393 0 : break;
394 : }
395 : case TGamepadRemoved:
396 : {
397 0 : (ptr_GamepadRemoved())->~GamepadRemoved__tdef();
398 0 : break;
399 : }
400 : case TGamepadAxisInformation:
401 : {
402 0 : (ptr_GamepadAxisInformation())->~GamepadAxisInformation__tdef();
403 0 : break;
404 : }
405 : case TGamepadButtonInformation:
406 : {
407 0 : (ptr_GamepadButtonInformation())->~GamepadButtonInformation__tdef();
408 0 : break;
409 : }
410 : case TGamepadPoseInformation:
411 : {
412 0 : (ptr_GamepadPoseInformation())->~GamepadPoseInformation__tdef();
413 0 : break;
414 : }
415 : case TGamepadHandInformation:
416 : {
417 0 : (ptr_GamepadHandInformation())->~GamepadHandInformation__tdef();
418 0 : break;
419 : }
420 : default:
421 : {
422 0 : mozilla::ipc::LogicError("not reached");
423 0 : break;
424 : }
425 : }
426 0 : return true;
427 : }
428 :
429 0 : MOZ_IMPLICIT GamepadChangeEvent::GamepadChangeEvent(const GamepadAdded& aOther)
430 : {
431 0 : new (mozilla::KnownNotNull, ptr_GamepadAdded()) GamepadAdded(aOther);
432 0 : mType = TGamepadAdded;
433 0 : }
434 :
435 0 : MOZ_IMPLICIT GamepadChangeEvent::GamepadChangeEvent(const GamepadRemoved& aOther)
436 : {
437 0 : new (mozilla::KnownNotNull, ptr_GamepadRemoved()) GamepadRemoved(aOther);
438 0 : mType = TGamepadRemoved;
439 0 : }
440 :
441 0 : MOZ_IMPLICIT GamepadChangeEvent::GamepadChangeEvent(const GamepadAxisInformation& aOther)
442 : {
443 0 : new (mozilla::KnownNotNull, ptr_GamepadAxisInformation()) GamepadAxisInformation(aOther);
444 0 : mType = TGamepadAxisInformation;
445 0 : }
446 :
447 0 : MOZ_IMPLICIT GamepadChangeEvent::GamepadChangeEvent(const GamepadButtonInformation& aOther)
448 : {
449 0 : new (mozilla::KnownNotNull, ptr_GamepadButtonInformation()) GamepadButtonInformation(aOther);
450 0 : mType = TGamepadButtonInformation;
451 0 : }
452 :
453 0 : MOZ_IMPLICIT GamepadChangeEvent::GamepadChangeEvent(const GamepadPoseInformation& aOther)
454 : {
455 0 : new (mozilla::KnownNotNull, ptr_GamepadPoseInformation()) GamepadPoseInformation(aOther);
456 0 : mType = TGamepadPoseInformation;
457 0 : }
458 :
459 0 : MOZ_IMPLICIT GamepadChangeEvent::GamepadChangeEvent(const GamepadHandInformation& aOther)
460 : {
461 0 : new (mozilla::KnownNotNull, ptr_GamepadHandInformation()) GamepadHandInformation(aOther);
462 0 : mType = TGamepadHandInformation;
463 0 : }
464 :
465 0 : MOZ_IMPLICIT GamepadChangeEvent::GamepadChangeEvent(const GamepadChangeEvent& aOther)
466 : {
467 0 : (aOther).AssertSanity();
468 0 : switch ((aOther).type()) {
469 : case TGamepadAdded:
470 : {
471 0 : new (mozilla::KnownNotNull, ptr_GamepadAdded()) GamepadAdded((aOther).get_GamepadAdded());
472 0 : break;
473 : }
474 : case TGamepadRemoved:
475 : {
476 0 : new (mozilla::KnownNotNull, ptr_GamepadRemoved()) GamepadRemoved((aOther).get_GamepadRemoved());
477 0 : break;
478 : }
479 : case TGamepadAxisInformation:
480 : {
481 0 : new (mozilla::KnownNotNull, ptr_GamepadAxisInformation()) GamepadAxisInformation((aOther).get_GamepadAxisInformation());
482 0 : break;
483 : }
484 : case TGamepadButtonInformation:
485 : {
486 0 : new (mozilla::KnownNotNull, ptr_GamepadButtonInformation()) GamepadButtonInformation((aOther).get_GamepadButtonInformation());
487 0 : break;
488 : }
489 : case TGamepadPoseInformation:
490 : {
491 0 : new (mozilla::KnownNotNull, ptr_GamepadPoseInformation()) GamepadPoseInformation((aOther).get_GamepadPoseInformation());
492 0 : break;
493 : }
494 : case TGamepadHandInformation:
495 : {
496 0 : new (mozilla::KnownNotNull, ptr_GamepadHandInformation()) GamepadHandInformation((aOther).get_GamepadHandInformation());
497 0 : break;
498 : }
499 : case T__None:
500 : {
501 0 : break;
502 : }
503 : default:
504 : {
505 0 : mozilla::ipc::LogicError("unreached");
506 0 : return;
507 : }
508 : }
509 0 : mType = (aOther).type();
510 : }
511 :
512 0 : GamepadChangeEvent::~GamepadChangeEvent()
513 : {
514 0 : static_cast<void>(MaybeDestroy(T__None));
515 0 : }
516 :
517 0 : auto GamepadChangeEvent::operator=(const GamepadAdded& aRhs) -> GamepadChangeEvent&
518 : {
519 0 : if (MaybeDestroy(TGamepadAdded)) {
520 0 : new (mozilla::KnownNotNull, ptr_GamepadAdded()) GamepadAdded;
521 : }
522 0 : (*(ptr_GamepadAdded())) = aRhs;
523 0 : mType = TGamepadAdded;
524 0 : return (*(this));
525 : }
526 :
527 0 : auto GamepadChangeEvent::operator=(const GamepadRemoved& aRhs) -> GamepadChangeEvent&
528 : {
529 0 : if (MaybeDestroy(TGamepadRemoved)) {
530 0 : new (mozilla::KnownNotNull, ptr_GamepadRemoved()) GamepadRemoved;
531 : }
532 0 : (*(ptr_GamepadRemoved())) = aRhs;
533 0 : mType = TGamepadRemoved;
534 0 : return (*(this));
535 : }
536 :
537 0 : auto GamepadChangeEvent::operator=(const GamepadAxisInformation& aRhs) -> GamepadChangeEvent&
538 : {
539 0 : if (MaybeDestroy(TGamepadAxisInformation)) {
540 0 : new (mozilla::KnownNotNull, ptr_GamepadAxisInformation()) GamepadAxisInformation;
541 : }
542 0 : (*(ptr_GamepadAxisInformation())) = aRhs;
543 0 : mType = TGamepadAxisInformation;
544 0 : return (*(this));
545 : }
546 :
547 0 : auto GamepadChangeEvent::operator=(const GamepadButtonInformation& aRhs) -> GamepadChangeEvent&
548 : {
549 0 : if (MaybeDestroy(TGamepadButtonInformation)) {
550 0 : new (mozilla::KnownNotNull, ptr_GamepadButtonInformation()) GamepadButtonInformation;
551 : }
552 0 : (*(ptr_GamepadButtonInformation())) = aRhs;
553 0 : mType = TGamepadButtonInformation;
554 0 : return (*(this));
555 : }
556 :
557 0 : auto GamepadChangeEvent::operator=(const GamepadPoseInformation& aRhs) -> GamepadChangeEvent&
558 : {
559 0 : if (MaybeDestroy(TGamepadPoseInformation)) {
560 0 : new (mozilla::KnownNotNull, ptr_GamepadPoseInformation()) GamepadPoseInformation;
561 : }
562 0 : (*(ptr_GamepadPoseInformation())) = aRhs;
563 0 : mType = TGamepadPoseInformation;
564 0 : return (*(this));
565 : }
566 :
567 0 : auto GamepadChangeEvent::operator=(const GamepadHandInformation& aRhs) -> GamepadChangeEvent&
568 : {
569 0 : if (MaybeDestroy(TGamepadHandInformation)) {
570 0 : new (mozilla::KnownNotNull, ptr_GamepadHandInformation()) GamepadHandInformation;
571 : }
572 0 : (*(ptr_GamepadHandInformation())) = aRhs;
573 0 : mType = TGamepadHandInformation;
574 0 : return (*(this));
575 : }
576 :
577 0 : auto GamepadChangeEvent::operator=(const GamepadChangeEvent& aRhs) -> GamepadChangeEvent&
578 : {
579 0 : (aRhs).AssertSanity();
580 0 : Type t = (aRhs).type();
581 0 : switch (t) {
582 : case TGamepadAdded:
583 : {
584 0 : if (MaybeDestroy(t)) {
585 0 : new (mozilla::KnownNotNull, ptr_GamepadAdded()) GamepadAdded;
586 : }
587 0 : (*(ptr_GamepadAdded())) = (aRhs).get_GamepadAdded();
588 0 : break;
589 : }
590 : case TGamepadRemoved:
591 : {
592 0 : if (MaybeDestroy(t)) {
593 0 : new (mozilla::KnownNotNull, ptr_GamepadRemoved()) GamepadRemoved;
594 : }
595 0 : (*(ptr_GamepadRemoved())) = (aRhs).get_GamepadRemoved();
596 0 : break;
597 : }
598 : case TGamepadAxisInformation:
599 : {
600 0 : if (MaybeDestroy(t)) {
601 0 : new (mozilla::KnownNotNull, ptr_GamepadAxisInformation()) GamepadAxisInformation;
602 : }
603 0 : (*(ptr_GamepadAxisInformation())) = (aRhs).get_GamepadAxisInformation();
604 0 : break;
605 : }
606 : case TGamepadButtonInformation:
607 : {
608 0 : if (MaybeDestroy(t)) {
609 0 : new (mozilla::KnownNotNull, ptr_GamepadButtonInformation()) GamepadButtonInformation;
610 : }
611 0 : (*(ptr_GamepadButtonInformation())) = (aRhs).get_GamepadButtonInformation();
612 0 : break;
613 : }
614 : case TGamepadPoseInformation:
615 : {
616 0 : if (MaybeDestroy(t)) {
617 0 : new (mozilla::KnownNotNull, ptr_GamepadPoseInformation()) GamepadPoseInformation;
618 : }
619 0 : (*(ptr_GamepadPoseInformation())) = (aRhs).get_GamepadPoseInformation();
620 0 : break;
621 : }
622 : case TGamepadHandInformation:
623 : {
624 0 : if (MaybeDestroy(t)) {
625 0 : new (mozilla::KnownNotNull, ptr_GamepadHandInformation()) GamepadHandInformation;
626 : }
627 0 : (*(ptr_GamepadHandInformation())) = (aRhs).get_GamepadHandInformation();
628 0 : break;
629 : }
630 : case T__None:
631 : {
632 0 : static_cast<void>(MaybeDestroy(t));
633 0 : break;
634 : }
635 : default:
636 : {
637 0 : mozilla::ipc::LogicError("unreached");
638 0 : break;
639 : }
640 : }
641 0 : mType = t;
642 0 : return (*(this));
643 : }
644 :
645 0 : auto GamepadChangeEvent::operator==(const GamepadAdded& aRhs) const -> bool
646 : {
647 0 : return (get_GamepadAdded()) == (aRhs);
648 : }
649 :
650 0 : auto GamepadChangeEvent::operator==(const GamepadRemoved& aRhs) const -> bool
651 : {
652 0 : return (get_GamepadRemoved()) == (aRhs);
653 : }
654 :
655 0 : auto GamepadChangeEvent::operator==(const GamepadAxisInformation& aRhs) const -> bool
656 : {
657 0 : return (get_GamepadAxisInformation()) == (aRhs);
658 : }
659 :
660 0 : auto GamepadChangeEvent::operator==(const GamepadButtonInformation& aRhs) const -> bool
661 : {
662 0 : return (get_GamepadButtonInformation()) == (aRhs);
663 : }
664 :
665 0 : auto GamepadChangeEvent::operator==(const GamepadPoseInformation& aRhs) const -> bool
666 : {
667 0 : return (get_GamepadPoseInformation()) == (aRhs);
668 : }
669 :
670 0 : auto GamepadChangeEvent::operator==(const GamepadHandInformation& aRhs) const -> bool
671 : {
672 0 : return (get_GamepadHandInformation()) == (aRhs);
673 : }
674 :
675 0 : auto GamepadChangeEvent::operator==(const GamepadChangeEvent& aRhs) const -> bool
676 : {
677 0 : if ((type()) != ((aRhs).type())) {
678 0 : return false;
679 : }
680 :
681 0 : switch (type()) {
682 : case TGamepadAdded:
683 : {
684 0 : return (get_GamepadAdded()) == ((aRhs).get_GamepadAdded());
685 : }
686 : case TGamepadRemoved:
687 : {
688 0 : return (get_GamepadRemoved()) == ((aRhs).get_GamepadRemoved());
689 : }
690 : case TGamepadAxisInformation:
691 : {
692 0 : return (get_GamepadAxisInformation()) == ((aRhs).get_GamepadAxisInformation());
693 : }
694 : case TGamepadButtonInformation:
695 : {
696 0 : return (get_GamepadButtonInformation()) == ((aRhs).get_GamepadButtonInformation());
697 : }
698 : case TGamepadPoseInformation:
699 : {
700 0 : return (get_GamepadPoseInformation()) == ((aRhs).get_GamepadPoseInformation());
701 : }
702 : case TGamepadHandInformation:
703 : {
704 0 : return (get_GamepadHandInformation()) == ((aRhs).get_GamepadHandInformation());
705 : }
706 : default:
707 : {
708 0 : mozilla::ipc::LogicError("unreached");
709 0 : return false;
710 : }
711 : }
712 : }
713 :
714 0 : auto GamepadChangeEvent::get(GamepadAdded* aOutValue) const -> void
715 : {
716 0 : (*(aOutValue)) = get_GamepadAdded();
717 0 : }
718 :
719 0 : auto GamepadChangeEvent::get(GamepadRemoved* aOutValue) const -> void
720 : {
721 0 : (*(aOutValue)) = get_GamepadRemoved();
722 0 : }
723 :
724 0 : auto GamepadChangeEvent::get(GamepadAxisInformation* aOutValue) const -> void
725 : {
726 0 : (*(aOutValue)) = get_GamepadAxisInformation();
727 0 : }
728 :
729 0 : auto GamepadChangeEvent::get(GamepadButtonInformation* aOutValue) const -> void
730 : {
731 0 : (*(aOutValue)) = get_GamepadButtonInformation();
732 0 : }
733 :
734 0 : auto GamepadChangeEvent::get(GamepadPoseInformation* aOutValue) const -> void
735 : {
736 0 : (*(aOutValue)) = get_GamepadPoseInformation();
737 0 : }
738 :
739 0 : auto GamepadChangeEvent::get(GamepadHandInformation* aOutValue) const -> void
740 : {
741 0 : (*(aOutValue)) = get_GamepadHandInformation();
742 0 : }
743 :
744 : } // namespace dom
745 : } // namespace mozilla
|