mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 10:18:11 +00:00
LibGUI: Add forwarding header
This patch adds <LibGUI/Forward.h> and uses it a bunch. It also dragged various header dependency reduction changes into it.
This commit is contained in:
parent
2e6ab58117
commit
2143da6434
115 changed files with 220 additions and 338 deletions
|
@ -26,28 +26,29 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#include <LibGUI/Forward.h>
|
||||
#include <LibGUI/Layout.h>
|
||||
#include <LibGUI/Widget.h>
|
||||
#include <LibGfx/Orientation.h>
|
||||
|
||||
namespace GUI {
|
||||
|
||||
class BoxLayout : public Layout {
|
||||
public:
|
||||
explicit BoxLayout(Orientation);
|
||||
explicit BoxLayout(Gfx::Orientation);
|
||||
virtual ~BoxLayout() override {}
|
||||
|
||||
Orientation orientation() const { return m_orientation; }
|
||||
Gfx::Orientation orientation() const { return m_orientation; }
|
||||
|
||||
virtual void run(Widget&) override;
|
||||
|
||||
private:
|
||||
Orientation m_orientation;
|
||||
Gfx::Orientation m_orientation;
|
||||
};
|
||||
|
||||
class VerticalBoxLayout final : public BoxLayout {
|
||||
public:
|
||||
explicit VerticalBoxLayout()
|
||||
: BoxLayout(Orientation::Vertical)
|
||||
: BoxLayout(Gfx::Orientation::Vertical)
|
||||
{
|
||||
}
|
||||
virtual ~VerticalBoxLayout() override {}
|
||||
|
@ -56,7 +57,7 @@ public:
|
|||
class HorizontalBoxLayout final : public BoxLayout {
|
||||
public:
|
||||
explicit HorizontalBoxLayout()
|
||||
: BoxLayout(Orientation::Horizontal)
|
||||
: BoxLayout(Gfx::Orientation::Horizontal)
|
||||
{
|
||||
}
|
||||
virtual ~HorizontalBoxLayout() override {}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue