move test guis to GUImodules and separate utils from modules
This commit is contained in:
@@ -2,15 +2,22 @@
|
|||||||
#define GUIMODULE_H
|
#define GUIMODULE_H
|
||||||
|
|
||||||
#include "Module.h"
|
#include "Module.h"
|
||||||
|
#include "Window/Window.h"
|
||||||
|
|
||||||
class GuiModule : Module {
|
class GuiModule : Module {
|
||||||
|
|
||||||
public:
|
public:
|
||||||
typedef GuiModule* create_t();
|
typedef GuiModule* create_t();
|
||||||
typedef void destroy_t(GuiModule*);
|
|
||||||
|
|
||||||
|
GuiModule(void* h, App& a) : Module(h, a) {
|
||||||
|
deps["Window"] = "";
|
||||||
|
}
|
||||||
virtual ~GuiModule() {}
|
virtual ~GuiModule() {}
|
||||||
|
virtual void load() = 0;
|
||||||
virtual void run() = 0;
|
virtual void run() = 0;
|
||||||
|
|
||||||
|
private:
|
||||||
|
Window window;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,10 +1,10 @@
|
|||||||
#include "Archimedes.h"
|
#include "Window/Window.h"
|
||||||
|
|
||||||
#define GLEW_STATIC
|
#define GLEW_STATIC
|
||||||
#include <GL/glew.h>
|
#include <GL/glew.h>
|
||||||
#include <GLFW/glfw3.h>
|
#include <GLFW/glfw3.h>
|
||||||
|
|
||||||
class Window {
|
class WindowGLFW : public Window {
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
13
utils/Window/Window.h
Normal file
13
utils/Window/Window.h
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
#include "Archimedes.h"
|
||||||
|
|
||||||
|
class Window {
|
||||||
|
|
||||||
|
public:
|
||||||
|
|
||||||
|
virtual ~Window() {};
|
||||||
|
|
||||||
|
virtual bool shouldClose() = 0;
|
||||||
|
|
||||||
|
virtual void doFrame() = 0;
|
||||||
|
|
||||||
|
};
|
||||||
Reference in New Issue
Block a user