mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-01 05:39:11 +00:00
LibWeb: Make PseudoElement a class in its own right
It's getting a bit large and complicated to be a struct hidden in DOM::Element.
This commit is contained in:
parent
e56146edec
commit
e7c2f0dd52
Notes:
github-actions[bot]
2025-06-19 11:37:51 +00:00
Author: https://github.com/AtkinsSJ
Commit: e7c2f0dd52
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5132
Reviewed-by: https://github.com/tcl3
6 changed files with 96 additions and 48 deletions
26
Libraries/LibWeb/DOM/PseudoElement.cpp
Normal file
26
Libraries/LibWeb/DOM/PseudoElement.cpp
Normal file
|
@ -0,0 +1,26 @@
|
|||
/*
|
||||
* Copyright (c) 2025, Sam Atkins <sam@ladybird.org>
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
||||
#include <LibWeb/CSS/CascadedProperties.h>
|
||||
#include <LibWeb/CSS/ComputedProperties.h>
|
||||
#include <LibWeb/DOM/PseudoElement.h>
|
||||
#include <LibWeb/Layout/Node.h>
|
||||
|
||||
namespace Web::DOM {
|
||||
|
||||
GC_DEFINE_ALLOCATOR(PseudoElement);
|
||||
GC_DEFINE_ALLOCATOR(PseudoElementTreeNode);
|
||||
|
||||
void PseudoElement::visit_edges(JS::Cell::Visitor& visitor)
|
||||
{
|
||||
Base::visit_edges(visitor);
|
||||
|
||||
visitor.visit(m_cascaded_properties);
|
||||
visitor.visit(m_computed_properties);
|
||||
visitor.visit(m_layout_node);
|
||||
}
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue