diff --git a/komorebi/src/process_event.rs b/komorebi/src/process_event.rs index 087d58e7..b71f3bb4 100644 --- a/komorebi/src/process_event.rs +++ b/komorebi/src/process_event.rs @@ -751,6 +751,8 @@ impl WindowManager { serde_json::to_writer_pretty(&file, &known_hwnds)?; + self.known_hwnds = known_hwnds; + notify_subscribers( Notification { event: NotificationEvent::WindowManager(event), diff --git a/komorebi/src/static_config.rs b/komorebi/src/static_config.rs index 0c5aefcf..9d11c5e3 100644 --- a/komorebi/src/static_config.rs +++ b/komorebi/src/static_config.rs @@ -1207,6 +1207,7 @@ impl StaticConfig { pending_move_op: Arc::new(None), already_moved_window_handles: Arc::new(Mutex::new(HashSet::new())), uncloack_to_ignore: 0, + known_hwnds: Vec::new(), }; match value.focus_follows_mouse { diff --git a/komorebi/src/window_manager.rs b/komorebi/src/window_manager.rs index 944b1673..b7973c1b 100644 --- a/komorebi/src/window_manager.rs +++ b/komorebi/src/window_manager.rs @@ -117,6 +117,7 @@ pub struct WindowManager { pub pending_move_op: Arc>, pub already_moved_window_handles: Arc>>, pub uncloack_to_ignore: usize, + pub known_hwnds: Vec, } #[allow(clippy::struct_excessive_bools)] @@ -364,6 +365,7 @@ impl WindowManager { pending_move_op: Arc::new(None), already_moved_window_handles: Arc::new(Mutex::new(HashSet::new())), uncloack_to_ignore: 0, + known_hwnds: Vec::new(), }) }