wayland: commit the empty surface at init (#309)

This should trigger the compositor's mechanism for sending a
configure event, which should most of the time be processed
before any winit user actually tries to draw.
This commit is contained in:
Victor Berger 2017-10-08 15:51:48 +02:00 committed by tomaka
parent 3f33cd1929
commit 3d8c94bae5

View file

@ -76,6 +76,10 @@ impl Window {
decorated_id decorated_id
}; };
// send our configuration to the compositor
// if we're in xdg mode, no buffer is attached yet, so this
// is fine (and more or less required actually)
surface.commit();
let me = Window { let me = Window {
ctxt: ctxt, ctxt: ctxt,
cleanup_signal: cleanup_signal, cleanup_signal: cleanup_signal,