mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 20:17:44 +00:00
LibWeb: Start filling out BaseAudioContext/AudioContext interfaces
- Fills out both IDLs and implements some basic attributes/methods. - No actual audio processing yet though :^)
This commit is contained in:
parent
30e67721ae
commit
49e6414c58
8 changed files with 407 additions and 8 deletions
|
@ -5,6 +5,7 @@
|
|||
*/
|
||||
|
||||
#include <LibWeb/Bindings/Intrinsics.h>
|
||||
#include <LibWeb/HTML/EventNames.h>
|
||||
#include <LibWeb/WebAudio/BaseAudioContext.h>
|
||||
|
||||
namespace Web::WebAudio {
|
||||
|
@ -24,4 +25,14 @@ JS::ThrowCompletionOr<void> BaseAudioContext::initialize(JS::Realm& realm)
|
|||
return {};
|
||||
}
|
||||
|
||||
void BaseAudioContext::set_onstatechange(WebIDL::CallbackType* event_handler)
|
||||
{
|
||||
set_event_handler_attribute(HTML::EventNames::statechange, event_handler);
|
||||
}
|
||||
|
||||
WebIDL::CallbackType* BaseAudioContext::onstatechange()
|
||||
{
|
||||
return event_handler_attribute(HTML::EventNames::statechange);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue