]> sigrok.org Git - pulseview.git/blobdiff - pv/prop/int.h
Added auto-commit support to properties
[pulseview.git] / pv / prop / int.h
index 279bedc1c5bb758f2703cdfabc9aae2fe3e34cc4..f4c7387983409749354839538356b8bfc11e9c2d 100644 (file)
@@ -34,6 +34,8 @@ namespace prop {
 
 class Int : public Property
 {
+       Q_OBJECT;
+
 public:
        Int(QString name, QString suffix,
                boost::optional< std::pair<int64_t, int64_t> > range,
@@ -41,10 +43,13 @@ public:
 
        virtual ~Int();
 
-       QWidget* get_widget(QWidget *parent);
+       QWidget* get_widget(QWidget *parent, bool auto_commit);
 
        void commit();
 
+private slots:
+       void on_value_changed(int);
+
 private:
        const QString _suffix;
        const boost::optional< std::pair<int64_t, int64_t> > _range;