From f3bff01b48fb3a8e1b45faaf48aa7cac9af00b9d Mon Sep 17 00:00:00 2001 From: youmo233 Date: Fri, 19 Jan 2024 18:57:45 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A7=A3=E5=86=B3=E6=97=8B=E8=BD=AC=E5=90=8E?= =?UTF-8?q?=E9=BC=A0=E6=A0=87=E8=BE=B9=E7=95=8C=E7=A7=BB=E5=8A=A8=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: youmo233 --- service/window_manager/src/input_windows_manager.cpp | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/service/window_manager/src/input_windows_manager.cpp b/service/window_manager/src/input_windows_manager.cpp index d7c1916e0d..27f6dccbc2 100644 --- a/service/window_manager/src/input_windows_manager.cpp +++ b/service/window_manager/src/input_windows_manager.cpp @@ -2253,15 +2253,8 @@ void InputWindowsManager::UpdateAndAdjustMouseLocation(int32_t& displayId, doubl displayInfo = GetPhysicalDisplay(displayId); CHKPV(displayInfo); } - int32_t width = 0; - int32_t height = 0; - if (displayInfo->direction == DIRECTION0 || displayInfo->direction == DIRECTION180) { - width = displayInfo->width; - height = displayInfo->height; - } else { - height = displayInfo->width; - width = displayInfo->height; - } + int32_t width = displayInfo->width; + int32_t height = displayInfo->height; if (integerX < 0) { integerX = 0; } -- Gitee