1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 20:57:35 +00:00

LibWeb: Add type casting helpers for Layout::InlineNode

This commit is contained in:
Andreas Kling 2020-12-03 19:14:41 +01:00
parent 17e9a5e0c5
commit d6c2a61fa1
2 changed files with 8 additions and 0 deletions

View file

@ -35,6 +35,13 @@ public:
InlineNode(DOM::Document&, DOM::Element&, NonnullRefPtr<CSS::StyleProperties>);
virtual ~InlineNode() override;
virtual const char* class_name() const override { return "InlineNode"; }
private:
virtual bool is_inline_node() const final { return true; }
};
}
AK_BEGIN_TYPE_TRAITS(Web::Layout::InlineNode)
static bool is_type(const Web::Layout::Node& layout_node) { return layout_node.is_inline_node(); }
AK_END_TYPE_TRAITS()