[][src]Trait winit::platform::desktop::EventLoopExtDesktop

pub trait EventLoopExtDesktop {
    type UserEvent;
    fn run_return<F>(&mut self, event_handler: F)
    where
        F: FnMut(Event<Self::UserEvent>, &EventLoopWindowTarget<Self::UserEvent>, &mut ControlFlow)
; }

Additional methods on EventLoop that are specific to desktop platforms.

Associated Types

type UserEvent

A type provided by the user that can be passed through Event::UserEvent.

Loading content...

Required methods

fn run_return<F>(&mut self, event_handler: F) where
    F: FnMut(Event<Self::UserEvent>, &EventLoopWindowTarget<Self::UserEvent>, &mut ControlFlow), 

Initializes the winit event loop.

Unlike run, this function accepts non-'static (i.e. non-move) closures and returns control flow to the caller when control_flow is set to ControlFlow::Exit.

Loading content...

Implementors

impl<T> EventLoopExtDesktop for EventLoop<T>[src]

type UserEvent = T

Loading content...