mirror of
https://git.sr.ht/~eliasnaur/gio
synced 2026-07-07 18:35:34 +00:00
app: [Windows] avoid deadlock when changing window configuration
Some window configurations lead to WM_SIZE messages when changed, which leads to deadlock because our window proc is not re-entrant. Avoid the issues by ignoring redundant messages. Fixes gio#262 Signed-off-by: Elias Naur <mail@eliasnaur.com>
This commit is contained in:
@@ -444,9 +444,11 @@ func (w *window) Wakeup() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (w *window) setStage(s system.Stage) {
|
func (w *window) setStage(s system.Stage) {
|
||||||
|
if s != w.stage {
|
||||||
w.stage = s
|
w.stage = s
|
||||||
w.w.Event(system.StageEvent{Stage: s})
|
w.w.Event(system.StageEvent{Stage: s})
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
func (w *window) draw(sync bool) {
|
func (w *window) draw(sync bool) {
|
||||||
var r windows.Rect
|
var r windows.Rect
|
||||||
|
|||||||
Reference in New Issue
Block a user