/src/serenity/Userland/Libraries/LibWeb/HTML/GlobalEventHandlers.cpp
Line | Count | Source |
1 | | /* |
2 | | * Copyright (c) 2021, Andreas Kling <kling@serenityos.org> |
3 | | * |
4 | | * SPDX-License-Identifier: BSD-2-Clause |
5 | | */ |
6 | | |
7 | | #include <LibWeb/DOM/EventTarget.h> |
8 | | #include <LibWeb/HTML/EventNames.h> |
9 | | #include <LibWeb/HTML/GlobalEventHandlers.h> |
10 | | #include <LibWeb/UIEvents/EventNames.h> |
11 | | |
12 | | namespace Web::HTML { |
13 | | |
14 | | #undef __ENUMERATE |
15 | | #define __ENUMERATE(attribute_name, event_name) \ |
16 | | void GlobalEventHandlers::set_##attribute_name(WebIDL::CallbackType* value) \ |
17 | 0 | { \ |
18 | 0 | if (auto event_target = global_event_handlers_to_event_target(event_name)) \ |
19 | 0 | event_target->set_event_handler_attribute(event_name, value); \ |
20 | 0 | } \ Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onabort(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onauxclick(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onblur(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_oncancel(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_oncanplay(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_oncanplaythrough(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onchange(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onclick(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onclose(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_oncontextmenu(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_oncuechange(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_ondblclick(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_ondrag(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_ondragend(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_ondragenter(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_ondragleave(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_ondragover(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_ondragstart(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_ondrop(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_ondurationchange(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onemptied(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onended(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onerror(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onfocus(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onfocusin(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onfocusout(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onformdata(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_oninput(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_oninvalid(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onkeydown(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onkeypress(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onkeyup(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onload(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onloadeddata(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onloadedmetadata(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onloadstart(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onmousedown(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onmouseenter(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onmouseleave(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onmousemove(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onmouseout(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onmouseover(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onmouseup(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onpause(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onplay(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onplaying(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onprogress(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onratechange(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onreset(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onresize(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onscroll(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onsecuritypolicyviolation(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onseeked(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onseeking(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onselect(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onselectionchange(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onslotchange(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onstalled(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onsubmit(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onsuspend(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_ontimeupdate(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_ontoggle(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onvolumechange(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onwaiting(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onwebkitanimationend(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onwebkitanimationiteration(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onwebkitanimationstart(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onwebkittransitionend(Web::WebIDL::CallbackType*) Unexecuted instantiation: Web::HTML::GlobalEventHandlers::set_onwheel(Web::WebIDL::CallbackType*) |
21 | | WebIDL::CallbackType* GlobalEventHandlers::attribute_name() \ |
22 | 0 | { \ |
23 | 0 | if (auto event_target = global_event_handlers_to_event_target(event_name)) \ |
24 | 0 | return event_target->event_handler_attribute(event_name); \ |
25 | 0 | return nullptr; \ |
26 | 0 | } Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onabort() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onauxclick() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onblur() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::oncancel() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::oncanplay() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::oncanplaythrough() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onchange() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onclick() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onclose() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::oncontextmenu() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::oncuechange() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::ondblclick() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::ondrag() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::ondragend() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::ondragenter() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::ondragleave() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::ondragover() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::ondragstart() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::ondrop() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::ondurationchange() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onemptied() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onended() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onerror() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onfocus() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onfocusin() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onfocusout() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onformdata() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::oninput() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::oninvalid() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onkeydown() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onkeypress() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onkeyup() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onload() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onloadeddata() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onloadedmetadata() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onloadstart() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onmousedown() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onmouseenter() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onmouseleave() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onmousemove() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onmouseout() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onmouseover() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onmouseup() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onpause() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onplay() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onplaying() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onprogress() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onratechange() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onreset() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onresize() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onscroll() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onsecuritypolicyviolation() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onseeked() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onseeking() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onselect() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onselectionchange() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onslotchange() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onstalled() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onsubmit() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onsuspend() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::ontimeupdate() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::ontoggle() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onvolumechange() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onwaiting() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onwebkitanimationend() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onwebkitanimationiteration() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onwebkitanimationstart() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onwebkittransitionend() Unexecuted instantiation: Web::HTML::GlobalEventHandlers::onwheel() |
27 | | ENUMERATE_GLOBAL_EVENT_HANDLERS(__ENUMERATE) |
28 | | #undef __ENUMERATE |
29 | | |
30 | 0 | GlobalEventHandlers::~GlobalEventHandlers() = default; |
31 | | } |