[turbine/glfw] Ensure window opens with a standard mandatory refresh period

This commit is contained in:
Gary Talent 2025-01-04 23:49:04 -06:00
parent df190c05a0
commit 40938958de

View File

@ -50,6 +50,7 @@ ox::Result<ContextUPtr> init(
glfwInit(); glfwInit();
OX_RETURN_ERROR(initGfx(*ctx)); OX_RETURN_ERROR(initGfx(*ctx));
glfwSetWindowSizeCallback(ctx->window, draw); glfwSetWindowSizeCallback(ctx->window, draw);
ctx->mandatoryRefreshPeriodEnd = ticksMs(*ctx) + config::MandatoryRefreshPeriod;
return ox::UPtr<Context, ContextDeleter>(ctx.release()); return ox::UPtr<Context, ContextDeleter>(ctx.release());
} }