From 52df6c289e15012c3a267dd2b3c8a6f30c2f1f1c Mon Sep 17 00:00:00 2001 From: Barry <870709864@qq.com> Date: Mon, 12 Nov 2018 20:12:25 +0800 Subject: [PATCH] =?UTF-8?q?=E7=AA=97=E5=8F=A3=E5=B1=85=E4=B8=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/videoform.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/videoform.cpp b/src/videoform.cpp index 1efbae4..b6d2107 100644 --- a/src/videoform.cpp +++ b/src/videoform.cpp @@ -87,8 +87,7 @@ void VideoForm::updateShowSize(const QSize &newSize) showSize.setHeight(qMin(newSize.height(), screenRect.height() - 100)); // 窗口居中 - move(screenRect.center() - geometry().center()); - qDebug() << screenRect.center() << geometry().center(); + move(screenRect.center() - QRect(0, 0, showSize.width(), showSize.height()).center()); } if (showSize != size()) {