I was trying to find out how handle double click with left(or any) mouse button. But I can't find any information about it.
Can anybody help me? I don't want to write my own double click handler.
GLFW_REPEAT doesn't work with mouse buttons.
I was trying to find out how handle double click with left(or any) mouse button. But I can't find any information about it.
Can anybody help me? I don't want to write my own double click handler.
GLFW_REPEAT doesn't work with mouse buttons.
What's so wrong about writing your own double click handler?
Just save the time the mouse click happens, e.g. with std::chrono::high_resolution_clock::now()
, and when the next mouse click happens, compare the times. If it is under a specific value, a double click happened.