1// Aseprite UI Library
2// Copyright (C) 2001-2013 David Capello
3//
4// This file is released under the terms of the MIT license.
5// Read LICENSE.txt for more information.
6
7#ifndef UI_VIEWPORT_H_INCLUDED
8#define UI_VIEWPORT_H_INCLUDED
9#pragma once
10
11#include "ui/widget.h"
12
13namespace ui {
14
15 class Viewport : public Widget {
16 public:
17 Viewport();
18
19 gfx::Size calculateNeededSize();
20
21 protected:
22 // Events
23 void onResize(ResizeEvent& ev) override;
24 void onSizeHint(SizeHintEvent& ev) override;
25 void onPaint(PaintEvent& ev) override;
26 };
27
28} // namespace ui
29
30#endif
31