mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-11-23 05:19:56 +00:00
Windows: Update dpiScale of fonts before recreating them on resize. Fixes #9437
This commit is contained in:
parent
aefad893f8
commit
8a29705165
@ -151,7 +151,7 @@ bool UpdateScreenScale(int width, int height) {
|
||||
|
||||
smallWindow = IsWindowSmall(width, height);
|
||||
if (smallWindow) {
|
||||
g_dpi /= 2;
|
||||
g_dpi /= 2.0f;
|
||||
g_dpi_scale *= 2.0f;
|
||||
}
|
||||
pixel_in_dps = 1.0f / g_dpi_scale;
|
||||
|
@ -351,6 +351,7 @@ void TextDrawer::DrawString(DrawBuffer &target, const char *str, float x, float
|
||||
|
||||
void TextDrawer::RecreateFonts() {
|
||||
for (auto &iter : fontMap_) {
|
||||
iter.second->dpiScale = dpiScale_;
|
||||
iter.second->Create();
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user