2008-02-09 13:43:23 +01:00
|
|
|
#ifndef __GLGUIWINDOW_H
|
|
|
|
#define __GLGUIWINDOW_H
|
|
|
|
|
|
|
|
#include <iostream>
|
|
|
|
#include <string>
|
|
|
|
#include <vector>
|
2008-09-19 17:34:01 +02:00
|
|
|
#include <SDL.h>
|
|
|
|
#include <SDL_opengl.h>
|
2008-02-09 13:43:23 +01:00
|
|
|
|
2008-08-10 17:14:54 +02:00
|
|
|
#include "../color.h"
|
2008-02-09 13:43:23 +01:00
|
|
|
#include "../gldrawhelper.h"
|
|
|
|
#include "object.h"
|
|
|
|
|
2008-08-10 17:14:54 +02:00
|
|
|
namespace segl {
|
2008-02-09 13:43:23 +01:00
|
|
|
|
|
|
|
class GLGuiWindow : public GLGuiObject {
|
|
|
|
private:
|
|
|
|
bool renderbackground;
|
|
|
|
SDL_Rect pos;
|
2008-08-10 17:14:54 +02:00
|
|
|
Color bgcolor;
|
2008-02-09 13:43:23 +01:00
|
|
|
|
|
|
|
std::vector<GLGuiObject*> items;
|
|
|
|
|
|
|
|
std::vector<GLGuiObject*> highlightable;
|
|
|
|
std::vector<GLGuiObject*> clickable;
|
|
|
|
std::vector<GLGuiObject*> keyboardable;
|
|
|
|
public:
|
2008-08-10 17:14:54 +02:00
|
|
|
GLGuiWindow(SDL_Rect _pos, Color _bgcolor);
|
2008-02-09 13:43:23 +01:00
|
|
|
~GLGuiWindow();
|
|
|
|
|
|
|
|
void addItem(GLGuiObject*);
|
|
|
|
SDL_Rect getPos();
|
|
|
|
void render();
|
|
|
|
};
|
|
|
|
|
2008-08-10 17:14:54 +02:00
|
|
|
} // namespace segl
|
|
|
|
|
2008-02-09 13:43:23 +01:00
|
|
|
#endif
|