2018-10-10 15:12:38 +02:00
|
|
|
#pragma once
|
|
|
|
|
2018-10-10 16:49:36 +02:00
|
|
|
#include "Object.h"
|
2018-10-14 00:21:42 +02:00
|
|
|
#include "Rect.h"
|
2018-10-10 16:49:36 +02:00
|
|
|
|
|
|
|
class AbstractScreen : public Object {
|
2018-10-10 15:12:38 +02:00
|
|
|
public:
|
|
|
|
virtual ~AbstractScreen();
|
|
|
|
|
2018-12-02 23:41:10 +01:00
|
|
|
int width() const { return m_width; }
|
|
|
|
int height() const { return m_height; }
|
2018-10-10 15:12:38 +02:00
|
|
|
|
|
|
|
static AbstractScreen& the();
|
|
|
|
|
2018-10-14 00:21:42 +02:00
|
|
|
Rect rect() const { return { 0, 0, width(), height() }; }
|
|
|
|
|
2018-10-10 15:12:38 +02:00
|
|
|
protected:
|
|
|
|
AbstractScreen(unsigned width, unsigned height);
|
|
|
|
|
|
|
|
private:
|
2018-12-02 23:41:10 +01:00
|
|
|
int m_width { 0 };
|
|
|
|
int m_height { 0 };
|
2018-10-10 15:12:38 +02:00
|
|
|
};
|
|
|
|
|