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
|
|
@ -158,12 +158,12 @@ impl SurfaceData {
|
|||
let width = if pending.width > 0 {
|
||||
pending.width as _
|
||||
} else {
|
||||
window.dims.width
|
||||
window.attrs.dims.width
|
||||
};
|
||||
let height = if pending.height > 0 {
|
||||
pending.height as _
|
||||
} else {
|
||||
window.dims.height
|
||||
window.attrs.dims.height
|
||||
};
|
||||
debug!(
|
||||
"configuring {:?}: {}x{}, {width}x{height}",
|
||||
|
|
@ -178,7 +178,7 @@ impl SurfaceData {
|
|||
height: height as _,
|
||||
},
|
||||
);
|
||||
window.dims = WindowDims {
|
||||
window.attrs.dims = WindowDims {
|
||||
x: pending.x as _,
|
||||
y: pending.y as _,
|
||||
width,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue