blob: bd75c4a2abab01689d3416352310a0645b831291 (
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
|
#pragma once
#include "uiObject.h"
#include "uiRenderer.h"
#include <SDL2/SDL.h>
#include <vector>
class WindowManager {
public:
WindowManager();
virtual ~WindowManager();
bool initWindow();
void destroyWindow();
SDL_Renderer * getRenderer();
void addUIObject(UIObject * uiObject);
void renderUIObjects();
private:
const int SCREEN_WIDTH = 800;
const int SCREEN_HEIGHT = 600;
SDL_Window * window = nullptr;
SDL_Renderer * renderer = nullptr;
UIRenderer * uiRenderer;
std::vector<UIObject *> uiObjects;
};
|