2022-04-15 22:00:13 +02:00
|
|
|
#ifndef BILLYSHEET_GUI_DATA_INTERFACE_HPP
|
|
|
|
#define BILLYSHEET_GUI_DATA_INTERFACE_HPP
|
|
|
|
|
|
|
|
#include <GLFW/glfw3.h>
|
|
|
|
|
|
|
|
namespace gui {
|
2024-01-28 20:31:50 +01:00
|
|
|
class GuiDataInterface {
|
|
|
|
public:
|
|
|
|
GuiDataInterface() noexcept = default;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual ~GuiDataInterface() noexcept = default;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual void key_callback(GLFWwindow *window, int key, int scancode, int action, int mods) = 0;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual void character_callback(GLFWwindow *window, unsigned int codepoint) = 0;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual void cursor_position_callback(GLFWwindow *window, double xpos, double ypos) = 0;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual void cursor_enter_callback(GLFWwindow *window, int entered) = 0;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual void mouse_button_callback(GLFWwindow *window, int button, int action, int mods) = 0;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual void scroll_callback(GLFWwindow *window, double xoffset, double yoffset) = 0;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual void joystick_callback(int jid, int event) = 0;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual void drop_callback(GLFWwindow *window, int count, const char **paths) = 0;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual void window_close_callback(GLFWwindow *window) = 0;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual void window_size_callback(GLFWwindow *window, int width, int height) = 0;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual void framebuffer_size_callback(GLFWwindow *window, int width, int height) = 0;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual void window_content_scale_callback(GLFWwindow *window, float xscale, float yscale) = 0;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual void window_pos_callback(GLFWwindow *window, int xpos, int ypos) = 0;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual void window_iconify_callback(GLFWwindow *window, int iconified) = 0;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual void window_maximize_callback(GLFWwindow *window, int maximized) = 0;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual void window_focus_callback(GLFWwindow *window, int focused) = 0;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual void window_refresh_callback(GLFWwindow *window) = 0;
|
2022-04-15 22:00:13 +02:00
|
|
|
|
2024-01-28 20:31:50 +01:00
|
|
|
virtual void error_callback(int error, const char *message) = 0;
|
|
|
|
};
|
2022-04-15 22:00:13 +02:00
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
#endif //BILLYSHEET_GUI_DATA_INTERFACE_HPP
|