From e20562cf161319dd046bf50732ecdce31d36e0a1 Mon Sep 17 00:00:00 2001 From: Gary Wang Date: Thu, 1 Jul 2021 22:43:11 +0800 Subject: [PATCH] fix: prev and next arrow not vertically centered in some case --- app/mainwindow.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/mainwindow.cpp b/app/mainwindow.cpp index c6dbd6e..a58bb71 100644 --- a/app/mainwindow.cpp +++ b/app/mainwindow.cpp @@ -466,9 +466,9 @@ void MainWindow::closeWindow() void MainWindow::updateWidgetsPosition() { m_closeButton->move(width() - m_closeButton->width(), 0); - m_prevButton->move(25, (height() - m_prevButton->height()) / 2); - m_nextButton->move(width() - m_nextButton->width() - 25, - (height() - m_prevButton->height()) / 2); + m_prevButton->move(25, (height() - m_prevButton->sizeHint().height()) / 2); + m_nextButton->move(width() - m_nextButton->sizeHint().width() - 25, + (height() - m_prevButton->sizeHint().height()) / 2); m_bottomButtonGroup->move((width() - m_bottomButtonGroup->width()) / 2, height() - m_bottomButtonGroup->height()); m_gv->move(width() - m_gv->width(), height() - m_gv->height());