render: call wl_display_flush() right after wl_surface_commit()

This groups the two calls, for readability.
This commit is contained in:
Daniel Eklöf 2020-01-01 11:19:39 +01:00
parent 9ba702ce00
commit bd8c81547f
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F

View file

@ -819,7 +819,6 @@ grid_render(struct terminal *term)
wl_surface_set_buffer_scale(term->window->surface, term->scale);
if (term->wl->presentation != NULL && term->render.presentation_timings) {
clock_gettime(term->wl->presentation_clock_id, &term->render.commit_time);
@ -835,6 +834,7 @@ grid_render(struct terminal *term)
}
wl_surface_commit(term->window->surface);
wl_display_flush(term->wl->display);
#if TIME_FRAME_RENDERING
struct timeval end_time;
@ -845,7 +845,6 @@ grid_render(struct terminal *term)
LOG_INFO("frame rendered in %lds %ldus",
render_time.tv_sec, render_time.tv_usec);
#endif
wl_display_flush(term->wl->display);
}
static void