Win32: Fix bad content scale on monitor disconnect

The monitor handle could have become invalid just before the call to
GetDpiForMonitor.  It was possible for both window and monitor content
scale queries.

This ensures both that an appropriate error is emitted and that the
retrieved values are zero on error.

Fixes #1615
This commit is contained in:
Camilla Löwy
2021-12-01 17:55:16 +01:00
parent d1efa32983
commit fbfd7e65c8
3 changed files with 16 additions and 1 deletions
+1
View File
@@ -62,6 +62,7 @@ video tutorials.
- Mário Freitas
- GeO4d
- Marcus Geelnard
- ghuser404
- Charles Giessen
- Ryan C. Gordon
- Stephen Gowen