mirror of
https://github.com/barry-ran/QtScrcpy.git
synced 2025-04-22 20:44:59 +00:00
窗口居中
This commit is contained in:
parent
accd23172a
commit
d1ddf7ec0c
1 changed files with 1 additions and 2 deletions
|
@ -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()) {
|
||||
|
|
Loading…
Add table
Reference in a new issue