Changeset d8cf709 in opengl-game for game-gui-glfw.cpp
- Timestamp:
- Feb 13, 2021, 11:41:39 PM (4 years ago)
- Branches:
- feature/imgui-sdl
- Children:
- c6f0793
- Parents:
- 8b823e7
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
game-gui-glfw.cpp
r8b823e7 rd8cf709 79 79 if (glfwWindowShouldClose(window)) { 80 80 UIEvent e; 81 e. type = UI_EVENT_QUIT;81 e.event.type = UI_EVENT_QUIT; 82 82 83 83 s_events.push(e); … … 147 147 void glfw_key_callback(GLFWwindow* window, int key, int scancode, int action, int mods) { 148 148 UIEvent e; 149 e. type = action == GLFW_RELEASE ? UI_EVENT_KEYUP : UI_EVENT_KEYDOWN;150 e. key.keycode = key;149 e.event.type = action == GLFW_RELEASE ? UI_EVENT_KEYUP : UI_EVENT_KEYDOWN; 150 e.event.key.keycode = key; 151 151 152 152 GameGui_GLFW::s_events.push(e); … … 155 155 void glfw_window_size_callback(GLFWwindow* window, int width, int height) { 156 156 UIEvent e; 157 e. type = UI_EVENT_WINDOWRESIZE;158 e. windowResize.width = width;159 e. windowResize.height = height;157 e.event.type = UI_EVENT_WINDOWRESIZE; 158 e.event.windowResize.width = width; 159 e.event.windowResize.height = height; 160 160 161 161 GameGui_GLFW::s_events.push(e);
Note:
See TracChangeset
for help on using the changeset viewer.