From 890b4d79800f61450e903f1b6408431243a94793 Mon Sep 17 00:00:00 2001 From: MacDue Date: Sun, 29 Jan 2023 19:12:00 +0100 Subject: LibWeb: Replace ARIA role static FlyStrings with an enum This replaces the FlyStrings for ARIA roles that were constructed in a [[gnu::constructor]] with a single enum. I came across this as the DOM inspector was crashing due to a null FlyString for an ARIA role. After fixing that, I was confused as to why these roles were not an enum. Looking at the spec there's a fixed list of roles and switching from references to static strings to an enum was pretty much an exercise in find and replace :). No functional changes (outside of fixing the mentioned crash). --- Userland/Libraries/LibWeb/HTML/HTMLOptionElement.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Userland/Libraries/LibWeb/HTML/HTMLOptionElement.h') diff --git a/Userland/Libraries/LibWeb/HTML/HTMLOptionElement.h b/Userland/Libraries/LibWeb/HTML/HTMLOptionElement.h index 9633a7c85b..c6d8228c92 100644 --- a/Userland/Libraries/LibWeb/HTML/HTMLOptionElement.h +++ b/Userland/Libraries/LibWeb/HTML/HTMLOptionElement.h @@ -30,7 +30,7 @@ public: bool disabled() const; - virtual DeprecatedFlyString default_role() const override; + virtual Optional default_role() const override; private: friend class Bindings::OptionConstructor; -- cgit v1.2.3