name_widget_(nullptr)
{
assert(base_);
+
+ connect(base_.get(), SIGNAL(enabled_changed(bool)),
+ this, SLOT(on_enabled_changed(bool)));
}
void Signal::set_name(QString name)
return base_->enabled();
}
-void Signal::enable(bool enable)
-{
- base_->set_enabled(enable);
-
- if (owner_)
- owner_->extents_changed(true, true);
-}
-
shared_ptr<data::SignalBase> Signal::base() const
{
return base_;
void Signal::on_disable()
{
- enable(false);
+ base_->set_enabled(false);
+}
+
+void Signal::on_enabled_changed(bool enabled)
+{
+ (void)enabled;
+
+ if (owner_)
+ owner_->extents_changed(true, true);
}
} // namespace view
*/
bool enabled() const;
- void enable(bool enable = true);
-
std::shared_ptr<data::SignalBase> base() const;
/**
void on_disable();
+ void on_enabled_changed(bool enabled);
+
protected:
pv::Session &session_;