blob: 73e35b06653a487d4a626287455c6d1d46290feb (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
#include <LibHTML/Frame.h>
#include <LibHTML/Layout/LayoutNode.h>
Frame::Frame()
: m_size(800, 600)
{
}
Frame::~Frame()
{
}
void Frame::set_document(Document* document)
{
m_document = document;
}
void Frame::layout()
{
if (!m_document)
return;
if (!m_document->layout_node())
m_document->create_layout_node();
ASSERT(m_document->layout_node());
m_document->layout_node()->style().size().set_width(m_size.width());
m_document->layout_node()->layout();
}
|