#pragma once #include "terminal.h" #include "event.h" #include "mouseEvent.h" #include "keyEvent.h" #include "windowEvent.h" class WindowSDL2 { public: WindowSDL2(); ~WindowSDL2(); void init( std::string, int, int); void shutdown(); void getSize(); const Event* pollEvents(); operator SDL_Window*() { return window; } //private: const Event* createEvent(); int x, y; std::string title; SDL_Window* window = nullptr; SDL_Event event; bool error = false; };