1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 05:37:43 +00:00

AK+Everywhere: Rename String to DeprecatedString

We have a new, improved string type coming up in AK (OOM aware, no null
state), and while it's going to use UTF-8, the name UTF8String is a
mouthful - so let's free up the String name by renaming the existing
class.
Making the old one have an annoying name will hopefully also help with
quick adoption :^)
This commit is contained in:
Linus Groh 2022-12-04 18:02:33 +00:00 committed by Andreas Kling
parent f74251606d
commit 6e19ab2bbc
2006 changed files with 11635 additions and 11636 deletions

View file

@ -332,7 +332,7 @@ WebIDL::CallbackType* EventTarget::get_current_value_of_event_handler(FlyString
auto& event_handler = event_handler_iterator->value;
// 3. If eventHandler's value is an internal raw uncompiled handler, then:
if (event_handler->value.has<String>()) {
if (event_handler->value.has<DeprecatedString>()) {
// 1. If eventTarget is an element, then let element be eventTarget, and document be element's node document.
// Otherwise, eventTarget is a Window object, let element be null, and document be eventTarget's associated Document.
JS::GCPtr<Element> element;
@ -355,7 +355,7 @@ WebIDL::CallbackType* EventTarget::get_current_value_of_event_handler(FlyString
return nullptr;
// 3. Let body be the uncompiled script body in eventHandler's value.
auto& body = event_handler->value.get<String>();
auto& body = event_handler->value.get<DeprecatedString>();
// FIXME: 4. Let location be the location where the script body originated, as given by eventHandler's value.
@ -680,7 +680,7 @@ JS::ThrowCompletionOr<void> EventTarget::process_event_handler_for_event(FlyStri
}
// https://html.spec.whatwg.org/multipage/webappapis.html#event-handler-attributes:concept-element-attributes-change-ext
void EventTarget::element_event_handler_attribute_changed(FlyString const& local_name, String const& value)
void EventTarget::element_event_handler_attribute_changed(FlyString const& local_name, DeprecatedString const& value)
{
// NOTE: Step 1 of this algorithm was handled in HTMLElement::parse_attribute.