x11: NewEvents(StartCause::Init) callback at start

Before starting the event loop, invoke callback with
NewEvents(StartCause::Init).
This commit is contained in:
Riku Salminen 2019-07-09 13:02:02 +03:00
parent f5c624bcd6
commit 1ea29b4de0

View file

@ -249,6 +249,12 @@ impl<T: 'static> EventLoop<T> {
let mut control_flow = ControlFlow::default();
let wt = get_xtarget(&self.target);
callback(
crate::event::Event::NewEvents(crate::event::StartCause::Init),
&self.target,
&mut control_flow,
);
loop {
// Empty the event buffer
{