Commit b09bab9
committed
@
fix(screen-adapter): debounce resize handler to prevent black flicker on web
The window resize event listener in _registerEvent() was calling
_resizeFrame() synchronously on every resize event. During continuous
window dragging, this triggered dozens of swapchain/backbuffer
reallocations per second, each producing a blank (black) frame.
This change debounces the resize handler using the same EVENT_TIMEOUT
(200ms) and setTimeout pattern already used by the orientation change
handler. It also adds the handleResizeEvent guard to the DPR
matchMedia listener, which was previously bypassing it.
Fixes: #19182
@1 parent ab66819 commit b09bab9
1 file changed
Lines changed: 11 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
183 | 183 | | |
184 | 184 | | |
185 | 185 | | |
| 186 | + | |
186 | 187 | | |
187 | 188 | | |
188 | 189 | | |
| |||
381 | 382 | | |
382 | 383 | | |
383 | 384 | | |
384 | | - | |
| 385 | + | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
385 | 392 | | |
386 | 393 | | |
387 | 394 | | |
388 | 395 | | |
389 | 396 | | |
390 | 397 | | |
| 398 | + | |
| 399 | + | |
| 400 | + | |
391 | 401 | | |
392 | 402 | | |
393 | 403 | | |
| |||
0 commit comments