Trace(QString::fromUtf8(channel->name().c_str())),
session_(session),
channel_(channel),
+ items_(),
name_widget_(nullptr),
updating_name_widget_(false)
{
return channel_;
}
+const ViewItemOwner::item_list& Signal::child_items() const
+{
+ return items_;
+}
+
void Signal::populate_popup_form(QWidget *parent, QFormLayout *form)
{
name_widget_ = new QComboBox(parent);
#include <stdint.h>
#include "trace.hpp"
+#include "viewitemowner.hpp"
namespace sigrok {
class Channel;
namespace view {
-class Signal : public Trace
+class Signal : public Trace, public ViewItemOwner
{
Q_OBJECT
std::shared_ptr<sigrok::Channel> channel() const;
+ /**
+ * Returns a list of row items owned by this object.
+ */
+ const item_list& child_items() const;
+
virtual void populate_popup_form(QWidget *parent, QFormLayout *form);
QMenu* create_context_menu(QWidget *parent);
pv::Session &session_;
std::shared_ptr<sigrok::Channel> channel_;
+ const item_list items_;
+
QComboBox *name_widget_;
bool updating_name_widget_;
};