1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-15 20:54:57 +00:00
serenity/Libraries/LibHTML/DOM/Text.cpp
Andreas Kling f4f5ede10a LibHTML: Simplify Node::create_layout_node()
There's no need to pass the StyleResolver to this function. Nodes that
need it can just get it from the document.
2019-10-15 15:06:16 +02:00

16 lines
322 B
C++

#include <LibHTML/DOM/Text.h>
#include <LibHTML/Layout/LayoutText.h>
Text::Text(Document& document, const String& data)
: CharacterData(document, NodeType::TEXT_NODE, data)
{
}
Text::~Text()
{
}
RefPtr<LayoutNode> Text::create_layout_node(const StyleProperties*) const
{
return adopt(*new LayoutText(*this));
}