LibWeb: Make ARIAMixin::to_element return a reference

Let's avoid confusion on whether this method can return null. It can't.
This also adds a non-const override, as that will be needed soon.
This commit is contained in:
Timothy Flynn 2025-04-24 11:18:07 -04:00 committed by Tim Ledbetter
commit a7b1f2c800
Notes: github-actions[bot] 2025-04-25 00:21:34 +00:00
3 changed files with 18 additions and 16 deletions

View file

@ -330,7 +330,8 @@ public:
virtual bool include_in_accessibility_tree() const override;
virtual Element const* to_element() const override { return this; }
virtual Element& to_element() override { return *this; }
virtual Element const& to_element() const override { return *this; }
bool is_hidden() const;
bool has_hidden_ancestor() const;