fix: mouse back should show previous image

This commit is contained in:
Gary Wang 2021-10-08 22:24:55 +08:00
parent 7a1816cbac
commit 3f327f94dc

View File

@ -300,7 +300,7 @@ void MainWindow::mouseReleaseEvent(QMouseEvent *event)
// Reference:
// [1]: https://codereview.qt-project.org/c/qt/qtbase/+/177475
if (event->button() == Qt::ForwardButton || event->button() == Qt::BackButton) {
event->button() == Qt::BackButton ? galleryNext() : galleryPrev();
event->button() == Qt::BackButton ? galleryPrev() : galleryNext();
event->accept();
}