mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-10-11 18:49:22 +00:00
LibJS+LibWeb+WebContent: Port JS::PropertyKey to UTF-16
This has quite a lot of fall out. But the majority of it is just type or UDL substitution, where the changes just fall through to other function calls. By changing property key storage to UTF-16, the main affected areas are: * NativeFunction names must now be UTF-16 * Bytecode identifiers must now be UTF-16 * Module/binding names must now be UTF-16
This commit is contained in:
parent
cd276235d7
commit
0efa98a57a
Notes:
github-actions[bot]
2025-08-05 11:08:30 +00:00
Author: https://github.com/trflynn89
Commit: 0efa98a57a
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5698
131 changed files with 766 additions and 726 deletions
|
@ -23,7 +23,7 @@ JS::ThrowCompletionOr<WebGLContextAttributes> convert_value_to_context_attribute
|
|||
if (value.is_nullish())
|
||||
alpha = JS::js_undefined();
|
||||
else
|
||||
alpha = TRY(value.as_object().get("alpha"_fly_string));
|
||||
alpha = TRY(value.as_object().get("alpha"_utf16_fly_string));
|
||||
|
||||
bool alpha_value;
|
||||
if (!alpha.is_undefined())
|
||||
|
@ -37,7 +37,7 @@ JS::ThrowCompletionOr<WebGLContextAttributes> convert_value_to_context_attribute
|
|||
if (value.is_nullish())
|
||||
antialias = JS::js_undefined();
|
||||
else
|
||||
antialias = TRY(value.as_object().get("antialias"_fly_string));
|
||||
antialias = TRY(value.as_object().get("antialias"_utf16_fly_string));
|
||||
|
||||
bool antialias_value;
|
||||
if (!antialias.is_undefined())
|
||||
|
@ -51,7 +51,7 @@ JS::ThrowCompletionOr<WebGLContextAttributes> convert_value_to_context_attribute
|
|||
if (value.is_nullish())
|
||||
depth = JS::js_undefined();
|
||||
else
|
||||
depth = TRY(value.as_object().get("depth"_fly_string));
|
||||
depth = TRY(value.as_object().get("depth"_utf16_fly_string));
|
||||
|
||||
bool depth_value;
|
||||
if (!depth.is_undefined())
|
||||
|
@ -65,7 +65,7 @@ JS::ThrowCompletionOr<WebGLContextAttributes> convert_value_to_context_attribute
|
|||
if (value.is_nullish())
|
||||
desynchronized = JS::js_undefined();
|
||||
else
|
||||
desynchronized = TRY(value.as_object().get("desynchronized"_fly_string));
|
||||
desynchronized = TRY(value.as_object().get("desynchronized"_utf16_fly_string));
|
||||
|
||||
bool desynchronized_value;
|
||||
|
||||
|
@ -80,7 +80,7 @@ JS::ThrowCompletionOr<WebGLContextAttributes> convert_value_to_context_attribute
|
|||
if (value.is_nullish())
|
||||
fail_if_major_performance_caveat = JS::js_undefined();
|
||||
else
|
||||
fail_if_major_performance_caveat = TRY(value.as_object().get("failIfMajorPerformanceCaveat"_fly_string));
|
||||
fail_if_major_performance_caveat = TRY(value.as_object().get("failIfMajorPerformanceCaveat"_utf16_fly_string));
|
||||
|
||||
bool fail_if_major_performance_caveat_value;
|
||||
if (!fail_if_major_performance_caveat.is_undefined())
|
||||
|
@ -94,7 +94,7 @@ JS::ThrowCompletionOr<WebGLContextAttributes> convert_value_to_context_attribute
|
|||
if (value.is_nullish())
|
||||
power_preference = JS::js_undefined();
|
||||
else
|
||||
power_preference = TRY(value.as_object().get("powerPreference"_fly_string));
|
||||
power_preference = TRY(value.as_object().get("powerPreference"_utf16_fly_string));
|
||||
|
||||
Bindings::WebGLPowerPreference power_preference_value { Bindings::WebGLPowerPreference::Default };
|
||||
|
||||
|
@ -117,7 +117,7 @@ JS::ThrowCompletionOr<WebGLContextAttributes> convert_value_to_context_attribute
|
|||
if (value.is_nullish())
|
||||
premultiplied_alpha = JS::js_undefined();
|
||||
else
|
||||
premultiplied_alpha = TRY(value.as_object().get("premultipliedAlpha"_fly_string));
|
||||
premultiplied_alpha = TRY(value.as_object().get("premultipliedAlpha"_utf16_fly_string));
|
||||
|
||||
bool premultiplied_alpha_value;
|
||||
|
||||
|
@ -132,7 +132,7 @@ JS::ThrowCompletionOr<WebGLContextAttributes> convert_value_to_context_attribute
|
|||
if (value.is_nullish())
|
||||
preserve_drawing_buffer = JS::js_undefined();
|
||||
else
|
||||
preserve_drawing_buffer = TRY(value.as_object().get("preserveDrawingBuffer"_fly_string));
|
||||
preserve_drawing_buffer = TRY(value.as_object().get("preserveDrawingBuffer"_utf16_fly_string));
|
||||
|
||||
bool preserve_drawing_buffer_value;
|
||||
if (!preserve_drawing_buffer.is_undefined())
|
||||
|
@ -146,7 +146,7 @@ JS::ThrowCompletionOr<WebGLContextAttributes> convert_value_to_context_attribute
|
|||
if (value.is_nullish())
|
||||
stencil = JS::js_undefined();
|
||||
else
|
||||
stencil = TRY(value.as_object().get("stencil"_fly_string));
|
||||
stencil = TRY(value.as_object().get("stencil"_utf16_fly_string));
|
||||
|
||||
bool stencil_value;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue