From b49b8fcfe50d14e5519c53747d9d0a3c2719aaa8 Mon Sep 17 00:00:00 2001
From: "Joachim Wuttke (o)" <j.wuttke@fz-juelich.de>
Date: Tue, 10 Oct 2023 14:35:36 +0200
Subject: [PATCH] DoubleSpinBox::m_valueProperty now const

---
 GUI/View/Numeric/DoubleSpinBox.cpp | 2 +-
 GUI/View/Numeric/DoubleSpinBox.h   | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/GUI/View/Numeric/DoubleSpinBox.cpp b/GUI/View/Numeric/DoubleSpinBox.cpp
index c05af8522d2..eb6b067f540 100644
--- a/GUI/View/Numeric/DoubleSpinBox.cpp
+++ b/GUI/View/Numeric/DoubleSpinBox.cpp
@@ -16,7 +16,7 @@
 #include "GUI/View/Numeric/NumberUtil.h"
 #include <QWheelEvent>
 
-DoubleSpinBox::DoubleSpinBox(DoubleProperty& d, bool easyScrollable, QWidget* parent)
+DoubleSpinBox::DoubleSpinBox(const DoubleProperty& d, bool easyScrollable, QWidget* parent)
     : QDoubleSpinBox(parent)
     , m_valueProperty(d)
     , m_easyScrollable(easyScrollable)
diff --git a/GUI/View/Numeric/DoubleSpinBox.h b/GUI/View/Numeric/DoubleSpinBox.h
index f0592914ac6..d891e84a74b 100644
--- a/GUI/View/Numeric/DoubleSpinBox.h
+++ b/GUI/View/Numeric/DoubleSpinBox.h
@@ -27,7 +27,7 @@ public:
     //! policy). Furthermore, the spin box will prohibit accidental changes by the mouse wheel.
     //! Otherwise it would be dangerous if the spin box is on a scrollable form - unintended and
     //! unnoticed changes would take place when just scrolling through the form.
-    DoubleSpinBox(DoubleProperty& d, bool easyScrollable = false, QWidget* parent = nullptr);
+    DoubleSpinBox(const DoubleProperty& d, bool easyScrollable = false, QWidget* parent = nullptr);
 
     //! Set the value
     void setBaseValue(double value);
@@ -47,7 +47,7 @@ private:
     void wheelEvent(QWheelEvent* event) override;
     void onDisplayValueChanged(double newDisplayValue);
 
-    DoubleProperty& m_valueProperty;
+    const DoubleProperty& m_valueProperty;
     bool m_easyScrollable;
 };
 
-- 
GitLab