From ed0f1486704faa50330f3b61ff93553f396405af 2018-01-15 11:23:41 From: Alexandre Leroux Date: 2018-01-15 11:23:41 Subject: [PATCH] Fix the problem of calling the zoom at wheel event on the color scale --- diff --git a/gui/src/Visualization/VisualizationGraphWidget.cpp b/gui/src/Visualization/VisualizationGraphWidget.cpp index c77b9a6..6f5b3f9 100644 --- a/gui/src/Visualization/VisualizationGraphWidget.cpp +++ b/gui/src/Visualization/VisualizationGraphWidget.cpp @@ -879,6 +879,11 @@ void VisualizationGraphWidget::onMouseMove(QMouseEvent *event) noexcept void VisualizationGraphWidget::onMouseWheel(QWheelEvent *event) noexcept { + // Processes event only if the wheel occurs on axis rect + if (!dynamic_cast(ui->widget->layoutElementAt(event->posF()))) { + return; + } + auto value = event->angleDelta().x() + event->angleDelta().y(); if (value != 0) {