From 112251b5851fc661f01b4f8cce056c233df7dbd9 Mon Sep 17 00:00:00 2001 From: Mike Walters Date: Sun, 29 Jan 2017 01:06:47 +0000 Subject: [PATCH] Process cursor mouse events last --- plotview.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/plotview.cpp b/plotview.cpp index 0017d04..55758f7 100644 --- a/plotview.cpp +++ b/plotview.cpp @@ -156,10 +156,6 @@ bool PlotView::eventFilter(QObject * obj, QEvent *event) QMouseEvent *mouseEvent = static_cast(event); - if (cursorsEnabled) - if (cursors.mouseEvent(event->type(), *mouseEvent)) - return true; - int plotY = -verticalScrollBar()->value(); for (auto&& plot : plots) { bool result = plot->mouseEvent( @@ -176,6 +172,10 @@ bool PlotView::eventFilter(QObject * obj, QEvent *event) return true; plotY += plot->height(); } + + if (cursorsEnabled) + if (cursors.mouseEvent(event->type(), *mouseEvent)) + return true; } // Handle wheel events for zooming