The previous code used qreals, but it feels clearer to use doubles when
the name of the class contains the word double. The performance loss of
using doubles instead of floats on arm is non-existent in this case.

Signed-off-by: Anton Lundin <[email protected]>
---
 qt-ui/modeldelegates.cpp | 2 +-
 qt-ui/modeldelegates.h   | 6 +++---
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/qt-ui/modeldelegates.cpp b/qt-ui/modeldelegates.cpp
index 8dfc567..b339e7f 100644
--- a/qt-ui/modeldelegates.cpp
+++ b/qt-ui/modeldelegates.cpp
@@ -379,7 +379,7 @@ QWidget *SpinBoxDelegate::createEditor(QWidget *parent, 
const QStyleOptionViewIt
        return w;
 }
 
-DoubleSpinBoxDelegate::DoubleSpinBoxDelegate(qreal min, qreal max, QObject 
*parent):
+DoubleSpinBoxDelegate::DoubleSpinBoxDelegate(double min, double max, QObject 
*parent):
        QStyledItemDelegate(parent),
        min(min),
        max(max)
diff --git a/qt-ui/modeldelegates.h b/qt-ui/modeldelegates.h
index 562111d..bb948d3 100644
--- a/qt-ui/modeldelegates.h
+++ b/qt-ui/modeldelegates.h
@@ -101,11 +101,11 @@ private:
 class DoubleSpinBoxDelegate : public QStyledItemDelegate {
        Q_OBJECT
 public:
-       DoubleSpinBoxDelegate(qreal min, qreal max, QObject *parent = 0);
+       DoubleSpinBoxDelegate(double min, double max, QObject *parent = 0);
        virtual QWidget *createEditor(QWidget *parent, const 
QStyleOptionViewItem &option, const QModelIndex &index) const;
 private:
-       qreal min;
-       qreal max;
+       double min;
+       double max;
 };
 
 #endif // MODELDELEGATES_H
-- 
1.9.1

_______________________________________________
subsurface mailing list
[email protected]
http://lists.hohndel.org/cgi-bin/mailman/listinfo/subsurface

Reply via email to