From f016b8125f37ce48c62259d1ab975e1e023268d6 Mon Sep 17 00:00:00 2001 From: Zzaphkiel Date: Mon, 5 Aug 2024 15:52:18 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E4=BA=86=E7=94=B1=E6=98=BE?= =?UTF-8?q?=E7=A4=BA=E5=99=A8=E5=88=86=E8=BE=A8=E7=8E=87=E8=BF=87=E4=BD=8E?= =?UTF-8?q?=E5=BC=95=E5=8F=91=E7=9A=84=E6=97=A0=E9=99=90=E7=AA=97=E5=8F=A3?= =?UTF-8?q?=E5=A4=A7=E5=B0=8F=E8=AD=A6=E5=91=8A=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/view/main_window.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/app/view/main_window.py b/app/view/main_window.py index 1b02022..3243cf2 100644 --- a/app/view/main_window.py +++ b/app/view/main_window.py @@ -948,8 +948,11 @@ async def __onGameEnd(self): asyncio.create_task(self.gameInfoInterface.clear()) def __checkWindowSize(self): + if (dpi := self.devicePixelRatioF()) == 1.0: + return + w, h = win32api.GetSystemMetrics(0), win32api.GetSystemMetrics(1) - size: QSize = self.size() * self.devicePixelRatioF() + size: QSize = self.size() * dpi if size.width() < w and size.height() < h: return