windows: fix: mess up full screen mode on config reload

refs: https://github.com/wez/wezterm/issues/3439
This commit is contained in:
Wez Furlong committed 2023-04-08 11:24:25 -07:00
1 parent 5fb6db8774
commit 69ae847273
2 files changed
+12

No files matched your search

+2
View File
@@ -135,6 +135,8 @@ As features stabilize some brief notes about them will accumulate here.
* Wayland: window not repainting consistently when using the keyboard when
using `front_end="WebGpu"`. Thanks to @jokeyrhyme for working through
different iterations of this fix! #3126
* Windows: reloading the config could partially knock the window out of
full screen mode. #3439
### 20230326-111934-3666303c
+10
View File
@@ -306,6 +306,16 @@ fn schedule_apply_decoration(hwnd: HWND, decorations: WindowDecorations) {
}
fn apply_decoration_immediate(hwnd: HWND, decorations: WindowDecorations) {
match rc_from_hwnd(hwnd) {
Some(inner) => {
if inner.borrow().saved_placement.is_some() {
// We are full screen; ignore it for now
return;
}
}
None => return,
};
unsafe {
let orig_style = GetWindowLongW(hwnd, GWL_STYLE);
let style = decorations_to_style(decorations);