Merge pull request #1964 from bungoboingo/feat/multi-window-support

[Feature] 🪟 Multi Window 🪟 .. redux!
This commit is contained in:
Héctor Ramón 2023-12-05 01:03:09 +01:00 committed by GitHub
commit fc285d3e46
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
59 changed files with 3020 additions and 761 deletions

View file

@ -109,7 +109,7 @@ where
Some(Event::Keyboard(keyboard_event))
}
core::Event::Touch(touch_event) => Some(Event::Touch(touch_event)),
core::Event::Window(window::Event::RedrawRequested(instant)) => {
core::Event::Window(_, window::Event::RedrawRequested(instant)) => {
Some(Event::RedrawRequested(instant))
}
_ => None,

View file

@ -1003,14 +1003,14 @@ where
state.keyboard_modifiers = modifiers;
}
Event::Window(window::Event::Unfocused) => {
Event::Window(_, window::Event::Unfocused) => {
let state = state();
if let Some(focus) = &mut state.is_focused {
focus.is_window_focused = false;
}
}
Event::Window(window::Event::Focused) => {
Event::Window(_, window::Event::Focused) => {
let state = state();
if let Some(focus) = &mut state.is_focused {
@ -1020,7 +1020,7 @@ where
shell.request_redraw(window::RedrawRequest::NextFrame);
}
}
Event::Window(window::Event::RedrawRequested(now)) => {
Event::Window(_, window::Event::RedrawRequested(now)) => {
let state = state();
if let Some(focus) = &mut state.is_focused {