From 5357e15966b7936d1134df44b90f347b0f8e1edb Mon Sep 17 00:00:00 2001 From: UkoeHB <37489173+UkoeHB@users.noreply.github.com> Date: Fri, 29 Mar 2024 12:24:11 -0500 Subject: [PATCH] Add Clone to WinitSettings (#12787) # Objective - Allow cloning `WinitSettings`. I use this in [bevy_worldswap](https://github.com/UkoeHB/bevy_worldswap) when synchronizing secondary app window state. ## Solution - Add `Clone` to `WinitSettings`. --- ## Changelog - Added `Clone` to `WinitSettings`. --- crates/bevy_winit/src/winit_config.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/bevy_winit/src/winit_config.rs b/crates/bevy_winit/src/winit_config.rs index f2cb424ec5..3400e86ba2 100644 --- a/crates/bevy_winit/src/winit_config.rs +++ b/crates/bevy_winit/src/winit_config.rs @@ -2,7 +2,7 @@ use bevy_ecs::system::Resource; use bevy_utils::Duration; /// Settings for the [`WinitPlugin`](super::WinitPlugin). -#[derive(Debug, Resource)] +#[derive(Debug, Resource, Clone)] pub struct WinitSettings { /// Determines how frequently the application can update when it has focus. pub focused_mode: UpdateMode,