mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-01 07:52:50 +00:00
LibWeb: Rename Element::attribute to Element::deprecated_attribute
This should allow us to add a Element::attribute which returns an Optional<String>. Eventually all callers should be ported to switch from the DeprecatedString version, but in the meantime, this should allow us to port some more IDL interfaces away from DeprecatedString.
This commit is contained in:
parent
da637a527d
commit
0f6782fae6
Notes:
sideshowbarker
2024-07-17 08:43:11 +09:00
Author: https://github.com/shannonbooth
Commit: 0f6782fae6
Pull-request: https://github.com/SerenityOS/serenity/pull/20926
Reviewed-by: https://github.com/awesomekling
Reviewed-by: https://github.com/trflynn89 ✅
42 changed files with 141 additions and 141 deletions
|
@ -46,7 +46,7 @@ Variant<Empty, Element*, JS::Handle<RadioNodeList>> HTMLFormControlsCollection::
|
|||
|
||||
auto collection = collect_matching_elements();
|
||||
for (auto const& element : collection) {
|
||||
if (element->attribute(HTML::AttributeNames::id) != deprecated_name && element->name() != deprecated_name)
|
||||
if (element->deprecated_attribute(HTML::AttributeNames::id) != deprecated_name && element->name() != deprecated_name)
|
||||
continue;
|
||||
|
||||
if (matching_element) {
|
||||
|
@ -71,7 +71,7 @@ Variant<Empty, Element*, JS::Handle<RadioNodeList>> HTMLFormControlsCollection::
|
|||
return false;
|
||||
|
||||
auto const& element = verify_cast<Element>(node);
|
||||
return element.attribute(HTML::AttributeNames::id) == deprecated_name || element.name() == deprecated_name;
|
||||
return element.deprecated_attribute(HTML::AttributeNames::id) == deprecated_name || element.name() == deprecated_name;
|
||||
}));
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue