1 #ifndef CSV_WORLD_DIALOGUESPINBOX_H 2 #define CSV_WORLD_DIALOGUESPINBOX_H 3 4 #include <QSpinBox> 5 #include <QDoubleSpinBox> 6 7 namespace CSVWorld 8 { 9 class DialogueSpinBox : public QSpinBox 10 { 11 Q_OBJECT 12 13 public: 14 15 DialogueSpinBox (QWidget *parent = nullptr); 16 17 protected: 18 19 void focusInEvent(QFocusEvent *event) override; 20 void focusOutEvent(QFocusEvent *event) override; 21 void wheelEvent(QWheelEvent *event) override; 22 }; 23 24 class DialogueDoubleSpinBox : public QDoubleSpinBox 25 { 26 Q_OBJECT 27 28 public: 29 30 DialogueDoubleSpinBox (QWidget *parent = nullptr); 31 32 protected: 33 34 void focusInEvent(QFocusEvent *event) override; 35 void focusOutEvent(QFocusEvent *event) override; 36 void wheelEvent(QWheelEvent *event) override; 37 }; 38 } 39 40 #endif // CSV_WORLD_DIALOGUESPINBOX_H 41