mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-28 11:49:44 +00:00
LibWeb: Add MediaSourceExtensions events
Continuing the boilerplate for these interfaces.
This commit is contained in:
parent
ff791a63fc
commit
66530086a4
Notes:
github-actions[bot]
2024-11-18 10:59:22 +00:00
Author: https://github.com/shannonbooth
Commit: 66530086a4
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/2415
Reviewed-by: https://github.com/Lubrsi ✅
19 changed files with 280 additions and 13 deletions
28
Libraries/LibWeb/MediaSourceExtensions/EventNames.cpp
Normal file
28
Libraries/LibWeb/MediaSourceExtensions/EventNames.cpp
Normal file
|
@ -0,0 +1,28 @@
|
|||
/*
|
||||
* Copyright (c) 2024, Shannon Booth <shannon@serenityos.org>
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
||||
#include <LibWeb/MediaSourceExtensions/EventNames.h>
|
||||
|
||||
namespace Web::MediaSourceExtensions::EventNames {
|
||||
|
||||
#define __ENUMERATE_MEDIA_SOURCE_EXTENSIONS_ATTRIBUTE(name) FlyString name;
|
||||
ENUMERATE_MEDIA_SOURCE_EXTENSIONS_ATTRIBUTES(__ENUMERATE_MEDIA_SOURCE_EXTENSIONS_ATTRIBUTE)
|
||||
#undef __ENUMERATE_MEDIA_SOURCE_EXTENSIONS_ATTRIBUTE
|
||||
|
||||
void initialize_strings()
|
||||
{
|
||||
static bool s_initialized = false;
|
||||
VERIFY(!s_initialized);
|
||||
|
||||
#define __ENUMERATE_MEDIA_SOURCE_EXTENSIONS_ATTRIBUTE(name) \
|
||||
name = #name##_fly_string;
|
||||
ENUMERATE_MEDIA_SOURCE_EXTENSIONS_ATTRIBUTES(__ENUMERATE_MEDIA_SOURCE_EXTENSIONS_ATTRIBUTE)
|
||||
#undef __ENUMERATE_MEDIA_SOURCE_EXTENSIONS_ATTRIBUTE
|
||||
|
||||
s_initialized = true;
|
||||
}
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue