From 4cac0472d81e5ec002538c5def992aa129781a52 Mon Sep 17 00:00:00 2001 From: Unknown <870709864@qq.com> Date: Thu, 27 Feb 2020 21:22:17 +0800 Subject: [PATCH] fix: fullscreen bug on ubuntu --- QtScrcpy/device/ui/videoform.cpp | 5 ++--- QtScrcpy/dialog.cpp | 5 +++++ 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/QtScrcpy/device/ui/videoform.cpp b/QtScrcpy/device/ui/videoform.cpp index f4996ea..834703d 100644 --- a/QtScrcpy/device/ui/videoform.cpp +++ b/QtScrcpy/device/ui/videoform.cpp @@ -92,10 +92,9 @@ void VideoForm::showToolForm(bool show) { if (!m_toolForm) { m_toolForm = new ToolForm(this, ToolForm::AP_OUTSIDE_RIGHT); - m_toolForm->move(pos().x() + geometry().width(), pos().y() + 30); - connect(m_toolForm, &ToolForm::screenshot, this, &VideoForm::screenshot); } + m_toolForm->move(pos().x() + geometry().width(), pos().y() + 30); m_toolForm->setVisible(show); } @@ -190,7 +189,7 @@ void VideoForm::switchFullScreen() //show(); #endif if (m_skin) { - updateStyleSheet(height() > width()); + updateStyleSheet(m_frameSize.height() > m_frameSize.width()); } showToolForm(true); #ifdef Q_OS_WIN32 diff --git a/QtScrcpy/dialog.cpp b/QtScrcpy/dialog.cpp index f21cd5d..938b6d5 100644 --- a/QtScrcpy/dialog.cpp +++ b/QtScrcpy/dialog.cpp @@ -103,6 +103,11 @@ void Dialog::initUI() // mac need more width setFixedWidth(520); #endif + +#ifdef Q_OS_LINUX + // linux need more width + setFixedWidth(480); +#endif } void Dialog::execAdbCmd()