Skip to content

Commit

Permalink
misc
Browse files Browse the repository at this point in the history
  • Loading branch information
maniwani committed Jul 25, 2023
1 parent 6fa1263 commit fc1dc5e
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 7 deletions.
3 changes: 2 additions & 1 deletion crates/bevy_winit/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -671,7 +671,7 @@ pub fn winit_runner(mut app: App) {
// TODO
// Upon resume, check if the new render surfaces are compatible with the
// existing render device. If not (which should basically never happen),
// and *then* try to rebuild the renderer.
// then try to rebuild the renderer.
*control_flow = ControlFlow::Exit;
}
}
Expand Down Expand Up @@ -739,6 +739,7 @@ pub fn winit_runner(mut app: App) {
}
}

// create any new windows
#[cfg(not(target_arch = "wasm32"))]
let (
commands,
Expand Down
4 changes: 2 additions & 2 deletions crates/bevy_winit/src/system.rs
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ use crate::{
/// If any of these entities are missing required components, those will be added with their
/// default values.
#[allow(clippy::too_many_arguments)]
pub(crate) fn create_windows<'a, T>(
event_loop: &EventLoopWindowTarget<T>,
pub(crate) fn create_windows<'a>(
event_loop: &EventLoopWindowTarget<()>,
mut commands: Commands,
windows: impl Iterator<Item = (Entity, Mut<'a, Window>)>,
mut event_writer: EventWriter<WindowCreated>,
Expand Down
2 changes: 0 additions & 2 deletions crates/bevy_winit/src/winit_config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,6 @@ pub struct WinitSettings {

impl WinitSettings {
/// Default settings for games.
///
/// [`Continuous`](UpdateMode::Continuous) if windows have focus.
pub fn game() -> Self {
WinitSettings::default()
}
Expand Down
4 changes: 2 additions & 2 deletions crates/bevy_winit/src/winit_windows.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,9 @@ pub struct WinitWindows {

impl WinitWindows {
/// Creates a `winit` window and associates it with our entity.
pub fn create_window<T>(
pub fn create_window(
&mut self,
event_loop: &winit::event_loop::EventLoopWindowTarget<T>,
event_loop: &winit::event_loop::EventLoopWindowTarget<()>,
entity: Entity,
window: &Window,
adapters: &mut AccessKitAdapters,
Expand Down

0 comments on commit fc1dc5e

Please sign in to comment.