diff options
Diffstat (limited to 'src/dotwm.rs')
-rw-r--r-- | src/dotwm.rs | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/dotwm.rs b/src/dotwm.rs index fd28765..248e969 100644 --- a/src/dotwm.rs +++ b/src/dotwm.rs @@ -171,10 +171,18 @@ impl DotWM { } /// Find a given window and returns it's position on the window_list. - pub fn find_window(&self, w: xlib::Window) -> Option<usize> { + pub fn window_idx(&self, w: xlib::Window) -> Option<usize> { + self.current_desktop().window_idx(w) + } + + pub fn find_window(&self, w: xlib::Window) -> Option<&XWindow> { self.current_desktop().find_window(w) } + pub fn find_window_mut(&mut self, w: xlib::Window) -> Option<&mut XWindow> { + self.current_desktop_mut().find_window_mut(w) + } + /// Focus the next window. /// /// There're 3 posibilities. There's no window, there's one window or there |