adopted new GLFW api