diff --git a/crates/gpui/src/platform/windows/platform.rs b/crates/gpui/src/platform/windows/platform.rs index 7f6677973b..e90b2c6ef1 100644 --- a/crates/gpui/src/platform/windows/platform.rs +++ b/crates/gpui/src/platform/windows/platform.rs @@ -33,8 +33,6 @@ use crate::*; pub(crate) struct WindowsPlatform { state: RefCell, raw_window_handles: RwLock>, - // The window handles that are hided by `hide` method. - hidden_windows: RwLock>, // The below members will never change throughout the entire lifecycle of the app. icon: HICON, main_receiver: flume::Receiver, @@ -102,7 +100,6 @@ impl WindowsPlatform { Self { state, raw_window_handles, - hidden_windows: RwLock::new(SmallVec::new()), icon, main_receiver, dispatch_event, @@ -298,26 +295,9 @@ impl Platform for WindowsPlatform { } } - fn activate(&self, _ignoring_other_apps: bool) { - let mut state = self.hidden_windows.write(); - state.iter().for_each(|handle| unsafe { - ShowWindow(*handle, SW_SHOW).ok().log_err(); - }); - state.clear(); - } + fn activate(&self, _ignoring_other_apps: bool) {} - fn hide(&self) { - let mut state = self.hidden_windows.write(); - self.raw_window_handles - .read() - .iter() - .for_each(|handle| unsafe { - if IsWindowVisible(*handle).as_bool() { - state.push(*handle); - ShowWindow(*handle, SW_HIDE).ok().log_err(); - } - }); - } + fn hide(&self) {} // todo(windows) fn hide_other_apps(&self) {