Add WakeUp event to App (#19212)
# Objective - The WakeUp event is never added to the app. If you need to use that event you currently need to add it yourself. ## Solution - Add the WakeUp event to the App in the WinitPlugin ## Testing - I tested the window_setting example and it compiled and worked
This commit is contained in:
parent
7ab00ca185
commit
2dc6337875
@ -108,8 +108,9 @@ struct WinitAppRunnerState<T: Event> {
|
||||
|
||||
impl<T: Event> WinitAppRunnerState<T> {
|
||||
fn new(mut app: App) -> Self {
|
||||
app.add_event::<T>();
|
||||
#[cfg(feature = "custom_cursor")]
|
||||
app.add_event::<T>().init_resource::<CustomCursorCache>();
|
||||
app.init_resource::<CustomCursorCache>();
|
||||
|
||||
let event_writer_system_state: SystemState<(
|
||||
EventWriter<WindowResized>,
|
||||
|
Loading…
Reference in New Issue
Block a user