mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-10-19 14:40:18 +00:00
LibWeb: Add tests for Gamepad API by utilising virtual SDL3 joysticks
Some checks failed
CI / macOS, arm64, Sanitizer, Clang (push) Waiting to run
CI / Linux, x86_64, Fuzzers, Clang (push) Waiting to run
CI / Linux, x86_64, Sanitizer, GNU (push) Waiting to run
CI / Linux, x86_64, Sanitizer, Clang (push) Waiting to run
Package the js repl as a binary artifact / Linux, arm64 (push) Waiting to run
Package the js repl as a binary artifact / macOS, arm64 (push) Waiting to run
Package the js repl as a binary artifact / Linux, x86_64 (push) Waiting to run
Run test262 and test-wasm / run_and_update_results (push) Waiting to run
Lint Code / lint (push) Waiting to run
Label PRs with merge conflicts / auto-labeler (push) Waiting to run
Push notes / build (push) Waiting to run
Build Dev Container Image / build (push) Has been cancelled
Some checks failed
CI / macOS, arm64, Sanitizer, Clang (push) Waiting to run
CI / Linux, x86_64, Fuzzers, Clang (push) Waiting to run
CI / Linux, x86_64, Sanitizer, GNU (push) Waiting to run
CI / Linux, x86_64, Sanitizer, Clang (push) Waiting to run
Package the js repl as a binary artifact / Linux, arm64 (push) Waiting to run
Package the js repl as a binary artifact / macOS, arm64 (push) Waiting to run
Package the js repl as a binary artifact / Linux, x86_64 (push) Waiting to run
Run test262 and test-wasm / run_and_update_results (push) Waiting to run
Lint Code / lint (push) Waiting to run
Label PRs with merge conflicts / auto-labeler (push) Waiting to run
Push notes / build (push) Waiting to run
Build Dev Container Image / build (push) Has been cancelled
This commit is contained in:
parent
74e0483ea5
commit
9adf27f009
Notes:
github-actions[bot]
2025-09-01 19:11:51 +00:00
Author: https://github.com/Lubrsi
Commit: 9adf27f009
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5902
Reviewed-by: https://github.com/gmta
Reviewed-by: https://github.com/trflynn89
28 changed files with 897 additions and 0 deletions
|
@ -18,6 +18,7 @@
|
|||
#include <LibWeb/DOMURL/DOMURL.h>
|
||||
#include <LibWeb/HTML/HTMLElement.h>
|
||||
#include <LibWeb/HTML/Window.h>
|
||||
#include <LibWeb/Internals/InternalGamepad.h>
|
||||
#include <LibWeb/Internals/Internals.h>
|
||||
#include <LibWeb/Page/InputEvent.h>
|
||||
#include <LibWeb/Page/Page.h>
|
||||
|
@ -330,4 +331,15 @@ GC::Ptr<DOM::ShadowRoot> Internals::get_shadow_root(GC::Ref<DOM::Element> elemen
|
|||
return element->shadow_root();
|
||||
}
|
||||
|
||||
void Internals::handle_sdl_input_events()
|
||||
{
|
||||
page().handle_sdl_input_events();
|
||||
}
|
||||
|
||||
GC::Ref<InternalGamepad> Internals::connect_virtual_gamepad()
|
||||
{
|
||||
auto& realm = this->realm();
|
||||
return realm.create<InternalGamepad>(realm);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue