diff --git a/crates/layout/src/window_controls.rs b/crates/layout/src/window_controls.rs index a4745e8..355bcf2 100644 --- a/crates/layout/src/window_controls.rs +++ b/crates/layout/src/window_controls.rs @@ -20,7 +20,7 @@ use gpui_native_theme::ActiveTheme as _; #[cfg(target_os = "linux")] use gpui::Decorations; #[cfg(target_os = "windows")] -use gpui::rgba; +use gpui::{SharedString, px, rgba}; /// macOS traffic-lights zone: the pad a leading titlebar strip reserves. pub const TRAFFIC_LIGHT_PAD: f32 = 78.0; @@ -52,13 +52,13 @@ impl RenderOnce for WindowControls { let id = self.id.clone(); #[cfg(target_os = "macos")] - { + let controls = { let _ = (id, window, cx); div() - } + }; #[cfg(target_os = "windows")] - { + let controls = { let controls = window.window_controls(); div() .flex_none() @@ -97,10 +97,10 @@ impl RenderOnce for WindowControls { true, true, )) - } + }; #[cfg(target_os = "linux")] - { + let controls = { let _ = id; let controls = window.window_controls(); let client_decorated = @@ -143,7 +143,9 @@ impl RenderOnce for WindowControls { |window, _cx| window.remove_window(), )) }) - } + }; + + controls } }