mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-04-25 05:55:13 +00:00
Instead of LibGUI and WindowServer building their own copies of the drawing and graphics code, let's it in a separate LibDraw library. This avoids building the code twice, and will encourage better separation of concerns. :^)
24 lines
474 B
C++
24 lines
474 B
C++
#pragma once
|
|
|
|
#include <LibHTML/DOM/Document.h>
|
|
#include <LibDraw/Size.h>
|
|
|
|
class Frame {
|
|
public:
|
|
Frame();
|
|
~Frame();
|
|
|
|
Document* document() { return m_document.ptr(); }
|
|
const Document* document() const { return m_document.ptr(); }
|
|
|
|
void set_document(Document*);
|
|
|
|
void layout();
|
|
|
|
private:
|
|
RefPtr<StyledNode> generate_style_tree();
|
|
RefPtr<LayoutNode> generate_layout_tree(const StyledNode&);
|
|
|
|
RefPtr<Document> m_document;
|
|
Size m_size;
|
|
};
|