gg: window_size: normalize dpi scaling (#8738)
parent
0520b755f4
commit
94429c8fd8
|
@ -709,7 +709,8 @@ pub fn screen_size() Size {
|
||||||
|
|
||||||
// window_size returns the `Size` of the active window
|
// window_size returns the `Size` of the active window
|
||||||
pub fn window_size() Size {
|
pub fn window_size() Size {
|
||||||
return Size{sapp.width(), sapp.height()}
|
s := sapp.dpi_scale()
|
||||||
|
return Size{int(sapp.width() / s), int(sapp.height() / s)}
|
||||||
}
|
}
|
||||||
|
|
||||||
fn C.WaitMessage()
|
fn C.WaitMessage()
|
||||||
|
|
Loading…
Reference in New Issue