#ifndef WINDOW_H #define WINDOW_H #include #include #include "input/TextInput.h" #include "rendering/WindowOptions.h" class Window final { TextInput& textInput; GLFWwindow* window; public: Window(TextInput& textInput, const WindowOptions& options); ~Window(); Window(const Window&) = delete; Window& operator=(const Window&) = delete; Window(Window&&) = delete; Window& operator=(Window&&) = delete; bool hasError() const; void show(); bool shouldClose() const; void swapBuffers(); void trapCursor(bool trap); Size getSize() const; Size getFramebufferSize() const; bool isKeyDown(int key) const; private: static void keyCallback(GLFWwindow* w, int key, int scancode, int action, int mods); static void charCallback(GLFWwindow* w, unsigned int codepoint); }; #endif