fix(window): don't save the geometry of a minimised window
Windows parks a minimised window at -32000,-32000 with a stub size and reports it as not-maximised, so closing OpsLog from the taskbar while minimised stored exactly that. Seen in a log: "window: saving -32000,-32000 237x39 maximised=false". The restore side already rejects both the impossible corner and the below-minimum size, so nothing opened off-screen — but it fell back to the default placement, and the operator silently lost the size, the position and the maximised state they had set. saveWindowState now keeps what was already stored when the window is minimised. Two tests for that: the Wails flag, and the -32000 corner, because a window that is mid-close can sit at that corner with the flag already cleared. A poisoned window.json repairs itself on the next close of an on-screen window.
This commit is contained in:
@@ -20,7 +20,10 @@
|
||||
"match_by": "description"
|
||||
}
|
||||
],
|
||||
"dxcc_filter": null,
|
||||
"dxcc_filter": [
|
||||
15,
|
||||
54
|
||||
],
|
||||
"valid_bands": [
|
||||
"160m",
|
||||
"60m",
|
||||
@@ -43,7 +46,7 @@
|
||||
],
|
||||
"total": 0,
|
||||
"builtin": true,
|
||||
"version": 1
|
||||
"version": 2
|
||||
},
|
||||
"references": [
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user