Sync maximized state from top-level configure event for a wayland window (#11003)
* Otherwise is_maximized always returns `true`
Release Notes:
- Fixed maximized state. Tested with a dummy maximize/restore button
with the `zoom()` (not implemented yet). Without the right `maximized`,
in toggle zoom function is not possible to call `set_maximized()` or
`unset_maximized()`.
```rust
fn zoom(&self) {
if self.is_maximized() {
self.borrow_mut().toplevel.unset_maximized();
} else {
self.borrow_mut().toplevel.set_maximized();
}
}
```
This commit is contained in:
@@ -322,7 +322,7 @@ impl WaylandWindowStatePtr {
|
||||
self.resize(width, height);
|
||||
self.set_fullscreen(fullscreen);
|
||||
let mut state = self.state.borrow_mut();
|
||||
state.maximized = true;
|
||||
state.maximized = maximized;
|
||||
|
||||
false
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user