mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-26 19:29:16 +00:00
LibWeb: Add fast_is<T>() for various types stood out in a profile
This commit is contained in:
@@ -125,6 +125,9 @@ public:
|
||||
private:
|
||||
HTMLInputElement(DOM::Document&, DOM::QualifiedName);
|
||||
|
||||
// ^DOM::Node
|
||||
virtual bool is_html_input_element() const final { return true; }
|
||||
|
||||
// ^DOM::EventTarget
|
||||
virtual void did_receive_focus() override;
|
||||
virtual void legacy_pre_activation_behavior() override;
|
||||
@@ -166,3 +169,8 @@ private:
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
namespace Web::DOM {
|
||||
template<>
|
||||
inline bool Node::fast_is<HTML::HTMLInputElement>() const { return is_html_input_element(); }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user