mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 14:38:11 +00:00
LibWeb: Add non-const version of paintable_box() in DOM::Node
This commit is contained in:
parent
6868ace8f4
commit
c985a1b2af
5 changed files with 16 additions and 6 deletions
|
@ -1454,6 +1454,15 @@ Painting::PaintableBox const* Node::paintable_box() const
|
|||
return static_cast<Layout::Box const&>(*layout_node()).paintable_box();
|
||||
}
|
||||
|
||||
Painting::PaintableBox* Node::paintable_box()
|
||||
{
|
||||
if (!layout_node())
|
||||
return nullptr;
|
||||
if (!layout_node()->is_box())
|
||||
return nullptr;
|
||||
return static_cast<Layout::Box&>(*layout_node()).paintable_box();
|
||||
}
|
||||
|
||||
// https://dom.spec.whatwg.org/#queue-a-mutation-record
|
||||
void Node::queue_mutation_record(FlyString const& type, DeprecatedString attribute_name, DeprecatedString attribute_namespace, DeprecatedString old_value, Vector<JS::Handle<Node>> added_nodes, Vector<JS::Handle<Node>> removed_nodes, Node* previous_sibling, Node* next_sibling) const
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue