Handle reparented windows correctly
Also refactored to avoid dealing with window properties until a window is actually mapped. Fixes #10
This commit is contained in:
parent
b8bd07ce93
commit
3afc9ffa9d
6 changed files with 456 additions and 164 deletions
|
|
@ -118,7 +118,7 @@ impl Compositor {
|
|||
}
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
#[derive(Debug, Default)]
|
||||
struct WindowData {
|
||||
mapped: bool,
|
||||
fullscreen: bool,
|
||||
|
|
@ -135,7 +135,7 @@ impl FakeXConnection {
|
|||
fn window(&mut self, window: Window) -> &mut WindowData {
|
||||
self.windows
|
||||
.get_mut(&window)
|
||||
.expect("Unknown window: {window:?}")
|
||||
.expect(&format!("Unknown window: {window:?}"))
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue