|
@@ -269,8 +269,8 @@ static void error_callback(int error, const char* description)
|
|
|
static void window_pos_callback(GLFWwindow* window, int x, int y)
|
|
|
{
|
|
|
Slot* slot = glfwGetWindowUserPointer(window);
|
|
|
- printf("%08x to %i at %0.3f (event time: %0.3f): Window position: %i %i\n",
|
|
|
- counter++, slot->number, glfwGetTime(), glfwGetEventTime(), x, y);
|
|
|
+ printf("%08x to %i at %0.3f: Window position: %i %i\n",
|
|
|
+ counter++, slot->number, glfwGetTime(), x, y);
|
|
|
}
|
|
|
|
|
|
static void window_size_callback(GLFWwindow* window, int width, int height)
|
|
@@ -336,33 +336,35 @@ static void window_maximize_callback(GLFWwindow* window, int maximized)
|
|
|
static void mouse_button_callback(GLFWwindow* window, int button, int action, int mods)
|
|
|
{
|
|
|
Slot* slot = glfwGetWindowUserPointer(window);
|
|
|
- printf("%08x to %i at %0.3f (event time: %0.3f): Mouse button %i (%s) (with%s) was %s\n",
|
|
|
- counter++, slot->number, glfwGetTime(), glfwGetEventTime(), button,
|
|
|
+ printf("%08x to %i at %0.3f: Mouse button %i (%s) (with%s) was %s at %0.3f\n",
|
|
|
+ counter++, slot->number, glfwGetTime(), button,
|
|
|
get_button_name(button),
|
|
|
get_mods_name(mods),
|
|
|
- get_action_name(action));
|
|
|
+ get_action_name(action),
|
|
|
+ glfwGetEventTime());
|
|
|
}
|
|
|
|
|
|
static void cursor_position_callback(GLFWwindow* window, double x, double y)
|
|
|
{
|
|
|
Slot* slot = glfwGetWindowUserPointer(window);
|
|
|
- printf("%08x to %i at %0.3f (event time: %0.3f): Cursor position: %f %f\n",
|
|
|
- counter++, slot->number, glfwGetTime(), glfwGetEventTime(), x, y);
|
|
|
+ printf("%08x to %i at %0.3f: Cursor position: %f %f at %0.3f\n",
|
|
|
+ counter++, slot->number, glfwGetTime(), x, y, glfwGetEventTime());
|
|
|
}
|
|
|
|
|
|
static void cursor_enter_callback(GLFWwindow* window, int entered)
|
|
|
{
|
|
|
Slot* slot = glfwGetWindowUserPointer(window);
|
|
|
- printf("%08x to %i at %0.3f: Cursor %s window\n",
|
|
|
+ printf("%08x to %i at %0.3f: Cursor %s window at %0.3f\n",
|
|
|
counter++, slot->number, glfwGetTime(),
|
|
|
- entered ? "entered" : "left");
|
|
|
+ entered ? "entered" : "left",
|
|
|
+ glfwGetEventTime());
|
|
|
}
|
|
|
|
|
|
static void scroll_callback(GLFWwindow* window, double x, double y)
|
|
|
{
|
|
|
Slot* slot = glfwGetWindowUserPointer(window);
|
|
|
- printf("%08x to %i at %0.3f: Scroll: %0.3f %0.3f\n",
|
|
|
- counter++, slot->number, glfwGetTime(), x, y);
|
|
|
+ printf("%08x to %i at %0.3f: Scroll: %0.3f %0.3f at %0.3f\n",
|
|
|
+ counter++, slot->number, glfwGetTime(), x, y, glfwGetEventTime());
|
|
|
}
|
|
|
|
|
|
static void key_callback(GLFWwindow* window, int key, int scancode, int action, int mods)
|
|
@@ -372,20 +374,22 @@ static void key_callback(GLFWwindow* window, int key, int scancode, int action,
|
|
|
|
|
|
if (name)
|
|
|
{
|
|
|
- printf("%08x to %i at %0.3f (event time: %0.3f): Key 0x%04x Scancode 0x%04x (%s) (%s) (with%s) was %s\n",
|
|
|
- counter++, slot->number, glfwGetTime(), glfwGetEventTime(), key, scancode,
|
|
|
+ printf("%08x to %i at %0.3f: Key 0x%04x Scancode 0x%04x (%s) (%s) (with%s) was %s at %0.3f\n",
|
|
|
+ counter++, slot->number, glfwGetTime(), key, scancode,
|
|
|
get_key_name(key),
|
|
|
name,
|
|
|
get_mods_name(mods),
|
|
|
- get_action_name(action));
|
|
|
+ get_action_name(action),
|
|
|
+ glfwGetEventTime());
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
- printf("%08x to %i at %0.3f (event time: %0.3f): Key 0x%04x Scancode 0x%04x (%s) (with%s) was %s\n",
|
|
|
- counter++, slot->number, glfwGetTime(), glfwGetEventTime(), key, scancode,
|
|
|
+ printf("%08x to %i at %0.3f: Key 0x%04x Scancode 0x%04x (%s) (with%s) was %s at %0.3f\n",
|
|
|
+ counter++, slot->number, glfwGetTime(), key, scancode,
|
|
|
get_key_name(key),
|
|
|
get_mods_name(mods),
|
|
|
- get_action_name(action));
|
|
|
+ get_action_name(action),
|
|
|
+ glfwGetEventTime());
|
|
|
}
|
|
|
|
|
|
if (action != GLFW_PRESS)
|
|
@@ -406,8 +410,8 @@ static void key_callback(GLFWwindow* window, int key, int scancode, int action,
|
|
|
static void char_callback(GLFWwindow* window, unsigned int codepoint)
|
|
|
{
|
|
|
Slot* slot = glfwGetWindowUserPointer(window);
|
|
|
- printf("%08x to %i at %0.3f (event time: %0.3f): Character 0x%08x (%s) input\n",
|
|
|
- counter++, slot->number, glfwGetTime(), glfwGetEventTime(), codepoint,
|
|
|
+ printf("%08x to %i at %0.3f: Character 0x%08x (%s) input\n",
|
|
|
+ counter++, slot->number, glfwGetTime(), codepoint,
|
|
|
get_character_string(codepoint));
|
|
|
}
|
|
|
|