From 0a759a374445a1974346fa82e7cfe3c9b8822d54 Mon Sep 17 00:00:00 2001
From: "Joachim Wuttke (h)" <j.wuttke@fz-juelich.de>
Date: Fri, 10 Nov 2023 15:11:29 +0100
Subject: [PATCH] shorter name

---
 GUI/View/Mask/MaskGraphicsScene.cpp | 18 +++++++++---------
 GUI/View/Mask/MaskGraphicsScene.h   |  2 +-
 2 files changed, 10 insertions(+), 10 deletions(-)

diff --git a/GUI/View/Mask/MaskGraphicsScene.cpp b/GUI/View/Mask/MaskGraphicsScene.cpp
index 7d4cbb138b4..906e0704cf2 100644
--- a/GUI/View/Mask/MaskGraphicsScene.cpp
+++ b/GUI/View/Mask/MaskGraphicsScene.cpp
@@ -282,7 +282,7 @@ void MaskGraphicsScene::mouseMoveEvent(QGraphicsSceneMouseEvent* event)
 
     if ((m_drawing_in_progress && m_activity == MaskEditorFlags::POLYGON_MODE)
         || ::isLineMode(m_activity)) {
-        m_currentMousePosition = event->scenePos();
+        m_mouse_position = event->scenePos();
         invalidate();
     }
 }
@@ -316,27 +316,27 @@ void MaskGraphicsScene::mouseReleaseEvent(QGraphicsSceneMouseEvent* event)
 
 void MaskGraphicsScene::drawForeground(QPainter* painter, const QRectF&)
 {
-    if (m_currentMousePosition == QPointF())
+    if (m_mouse_position == QPointF())
         return;
 
     if (PolygonDisplay* polygon = currentPolygon()) {
         painter->setPen(QPen(Qt::black, 1, Qt::DashLine));
-        painter->drawLine(QLineF(polygon->lastAddedPoint(), m_currentMousePosition));
+        painter->drawLine(QLineF(polygon->lastAddedPoint(), m_mouse_position));
     } else {
         if (::isLineMode(m_activity)) {
             const QRectF& plot_scene_rectangle = m_adaptor->viewportRectangle();
-            if (!plot_scene_rectangle.contains(m_currentMousePosition))
+            if (!plot_scene_rectangle.contains(m_mouse_position))
                 return;
 
             painter->setPen(QPen(Qt::black, 1, Qt::DashLine));
             if (m_activity == MaskEditorFlags::VERTICAL_LINE_MODE) {
-                QPointF p1(m_currentMousePosition.x(), plot_scene_rectangle.bottom());
-                QPointF p2(m_currentMousePosition.x(), plot_scene_rectangle.top());
+                QPointF p1(m_mouse_position.x(), plot_scene_rectangle.bottom());
+                QPointF p2(m_mouse_position.x(), plot_scene_rectangle.top());
                 painter->drawLine(QLineF(p1, p2));
             }
             if (m_activity == MaskEditorFlags::HORIZONTAL_LINE_MODE) {
-                QPointF p1(plot_scene_rectangle.left(), m_currentMousePosition.y());
-                QPointF p2(plot_scene_rectangle.right(), m_currentMousePosition.y());
+                QPointF p1(plot_scene_rectangle.left(), m_mouse_position.y());
+                QPointF p2(plot_scene_rectangle.right(), m_mouse_position.y());
                 painter->drawLine(QLineF(p1, p2));
             }
         }
@@ -697,7 +697,7 @@ void MaskGraphicsScene::processPolygonItem(QGraphicsSceneMouseEvent* event)
     if (PolygonDisplay* polygon = currentPolygon()) {
         if (polygon->closePolygonIfNecessary()) {
             m_drawing_in_progress = false;
-            m_currentMousePosition = {};
+            m_mouse_position = {};
             return;
         }
     }
diff --git a/GUI/View/Mask/MaskGraphicsScene.h b/GUI/View/Mask/MaskGraphicsScene.h
index dbd41d1c2e6..c0876fb8e4b 100644
--- a/GUI/View/Mask/MaskGraphicsScene.h
+++ b/GUI/View/Mask/MaskGraphicsScene.h
@@ -123,7 +123,7 @@ private:
     bool m_mouse_is_pressed = false;
     Data2DItem* m_data2DItem = nullptr;
     MaskRoot* m_currentItem = nullptr;
-    QPointF m_currentMousePosition;
+    QPointF m_mouse_position;
     bool m_drawing_in_progress;
     MaskEditorFlags::MaskValue m_mask_value;
     MaskEditorFlags::Activity m_activity;
-- 
GitLab