1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 05:48:12 +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

@ -56,17 +56,17 @@ public:
#undef __ENUMERATE_HTML_INPUT_TYPE_ATTRIBUTE
};
String type() const;
DeprecatedString type() const;
TypeAttributeState type_state() const { return m_type; }
void set_type(String const&);
void set_type(DeprecatedString const&);
String default_value() const { return attribute(HTML::AttributeNames::value); }
String name() const { return attribute(HTML::AttributeNames::name); }
DeprecatedString default_value() const { return attribute(HTML::AttributeNames::value); }
DeprecatedString name() const { return attribute(HTML::AttributeNames::name); }
String value() const;
WebIDL::ExceptionOr<void> set_value(String);
DeprecatedString value() const;
WebIDL::ExceptionOr<void> set_value(DeprecatedString);
Optional<String> placeholder_value() const;
Optional<DeprecatedString> placeholder_value() const;
bool checked() const { return m_checked; }
enum class ChangeSource {
@ -94,7 +94,7 @@ public:
virtual bool is_focusable() const override { return m_type != TypeAttributeState::Hidden; }
// ^HTMLElement
virtual void parse_attribute(FlyString const&, String const&) override;
virtual void parse_attribute(FlyString const&, DeprecatedString const&) override;
virtual void did_remove_attribute(FlyString const&) override;
// ^FormAssociatedElement
@ -136,7 +136,7 @@ private:
void set_checked_within_group();
// https://html.spec.whatwg.org/multipage/input.html#value-sanitization-algorithm
String value_sanitization_algorithm(String) const;
DeprecatedString value_sanitization_algorithm(DeprecatedString) const;
JS::GCPtr<DOM::Text> m_text_node;
bool m_checked { false };
@ -155,7 +155,7 @@ private:
JS::GCPtr<FileAPI::FileList> m_selected_files;
TypeAttributeState m_type { TypeAttributeState::Text };
String m_value;
DeprecatedString m_value;
};
}