Skip to content

Commit

Permalink
restore compatibility with older Qt versions
Browse files Browse the repository at this point in the history
Signed-off-by: Dirk Thomas <dirk-thomas@users.noreply.github.com>
  • Loading branch information
dirk-thomas committed Jun 4, 2020
1 parent fb0c044 commit 61153ec
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ class ViewControllerTestFixture : public DisplayTestFixture
auto global_point = QPointF();
auto pixel_delta = QPoint();
auto angle_delta = QPoint(delta, 0);
#if (QT_VERSION >= QT_VERSION_CHECK(5, 14, 0))
auto mouseEvent = new QWheelEvent(
point,
global_point,
Expand All @@ -110,6 +111,10 @@ class ViewControllerTestFixture : public DisplayTestFixture
Qt::NoModifier,
Qt::NoScrollPhase,
false);
#else
auto mouseEvent = new QWheelEvent(
point, delta, Qt::NoButton, Qt::NoModifier, Qt::Orientation::Horizontal);
#endif
return {render_panel_.get(), mouseEvent, 0, 0};
}

Expand Down

0 comments on commit 61153ec

Please sign in to comment.