#ifndef PULSEVIEW_PV_VIEW_SIGNAL_H
#define PULSEVIEW_PV_VIEW_SIGNAL_H
-#include <boost/shared_ptr.hpp>
+#include <memory>
#include <QComboBox>
#include <QWidgetAction>
#include "trace.h"
-struct sr_probe;
+struct sr_channel;
namespace pv {
-class DevInst;
-
namespace data {
class SignalData;
}
+namespace device {
+class DevInst;
+}
+
namespace view {
class Signal : public Trace
Q_OBJECT
protected:
- Signal(boost::shared_ptr<pv::DevInst> dev_inst, sr_probe *const probe);
+ Signal(std::shared_ptr<pv::device::DevInst> dev_inst,
+ const sr_channel *const probe);
public:
/**
*/
void set_name(QString name);
- virtual boost::shared_ptr<pv::data::SignalData> data() const = 0;
+ virtual std::shared_ptr<pv::data::SignalData> data() const = 0;
/**
* Returns true if the trace is visible and enabled.
void enable(bool enable = true);
- const sr_probe* probe() const;
+ const sr_channel* probe() const;
virtual void populate_popup_form(QWidget *parent, QFormLayout *form);
void delete_pressed();
-private slots:
+ bool eventFilter(QObject *obj, QEvent *evt);
+
+private Q_SLOTS:
void on_disable();
protected:
- boost::shared_ptr<pv::DevInst> _dev_inst;
- sr_probe *const _probe;
+ std::shared_ptr<pv::device::DevInst> _dev_inst;
+ const sr_channel *const _probe;
QComboBox *_name_widget;
bool _updating_name_widget;