mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-10 00:34:59 +01:00
RouteUI connects to Route's PropertyChange signal; derived types implement route_property_changed()
This commit is contained in:
parent
c0e5265b14
commit
518f7f9892
6 changed files with 23 additions and 18 deletions
|
|
@ -293,7 +293,6 @@ MeterStrip::MeterStrip (Session* sess, boost::shared_ptr<ARDOUR::Route> rt)
|
|||
meter_ticks2_area.signal_expose_event().connect (sigc::mem_fun(*this, &MeterStrip::meter_ticks2_expose));
|
||||
|
||||
_route->DropReferences.connect (meter_route_connections, invalidator (*this), boost::bind (&MeterStrip::self_delete, this), gui_context());
|
||||
_route->PropertyChanged.connect (meter_route_connections, invalidator (*this), boost::bind (&MeterStrip::strip_property_changed, this, _1), gui_context());
|
||||
|
||||
peak_display.signal_button_release_event().connect (sigc::mem_fun(*this, &MeterStrip::peak_button_release), false);
|
||||
name_label.signal_button_release_event().connect (sigc::mem_fun(*this, &MeterStrip::name_label_button_release), false);
|
||||
|
|
@ -388,7 +387,7 @@ MeterStrip::set_button_names()
|
|||
}
|
||||
|
||||
void
|
||||
MeterStrip::strip_property_changed (const PropertyChange& what_changed)
|
||||
MeterStrip::route_property_changed (const PropertyChange& what_changed)
|
||||
{
|
||||
if (!what_changed.contains (ARDOUR::Properties::name)) {
|
||||
return;
|
||||
|
|
|
|||
|
|
@ -133,7 +133,7 @@ class MeterStrip : public Gtk::VBox, public AxisView, public RouteUI
|
|||
|
||||
LevelMeterHBox *level_meter;
|
||||
|
||||
void strip_property_changed (const PBD::PropertyChange&);
|
||||
void route_property_changed (const PBD::PropertyChange&);
|
||||
void meter_configuration_changed (ARDOUR::ChanCount);
|
||||
void meter_type_changed (ARDOUR::MeterType);
|
||||
void update_background (ARDOUR::MeterType);
|
||||
|
|
|
|||
|
|
@ -649,7 +649,6 @@ MixerStrip::set_route (boost::shared_ptr<Route> rt)
|
|||
}
|
||||
|
||||
_route->comment_changed.connect (route_connections, invalidator (*this), boost::bind (&MixerStrip::setup_comment_button, this), gui_context());
|
||||
_route->PropertyChanged.connect (route_connections, invalidator (*this), boost::bind (&MixerStrip::property_changed, this, _1), gui_context());
|
||||
|
||||
_route->gain_control()->MasterStatusChange.connect (route_connections,
|
||||
invalidator (*this),
|
||||
|
|
@ -1750,10 +1749,8 @@ MixerStrip::set_selected (bool yn)
|
|||
}
|
||||
|
||||
void
|
||||
MixerStrip::property_changed (const PropertyChange& what_changed)
|
||||
MixerStrip::route_property_changed (const PropertyChange& what_changed)
|
||||
{
|
||||
RouteUI::property_changed (what_changed);
|
||||
|
||||
if (what_changed.contains (ARDOUR::Properties::name)) {
|
||||
name_changed ();
|
||||
}
|
||||
|
|
@ -2626,6 +2623,16 @@ MixerStrip::update_track_number_visibility ()
|
|||
}
|
||||
}
|
||||
|
||||
bool
|
||||
MixerStrip::is_selected () const
|
||||
{
|
||||
if (!_route) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return _route->presentation_info().selected();
|
||||
}
|
||||
|
||||
Gdk::Color
|
||||
MixerStrip::color () const
|
||||
{
|
||||
|
|
|
|||
|
|
@ -275,7 +275,7 @@ class MixerStrip : public AxisView, public RouteUI, public Gtk::EventBox
|
|||
void route_color_changed ();
|
||||
void show_passthru_color ();
|
||||
|
||||
void property_changed (const PBD::PropertyChange&);
|
||||
void route_property_changed (const PBD::PropertyChange&);
|
||||
void name_button_resized (Gtk::Allocation&);
|
||||
void name_changed ();
|
||||
void update_speed_display ();
|
||||
|
|
|
|||
|
|
@ -128,6 +128,14 @@ RouteTimeAxisView::RouteTimeAxisView (PublicEditor& ed, Session* sess, ArdourCan
|
|||
parameter_changed ("editor-stereo-only-meters");
|
||||
}
|
||||
|
||||
void
|
||||
RouteTimeAxisView::route_property_changed (const PBD::PropertyChange& what_changed)
|
||||
{
|
||||
if (what_changed.contains (ARDOUR::Properties::name)) {
|
||||
label_view ();
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
RouteTimeAxisView::set_route (boost::shared_ptr<Route> rt)
|
||||
{
|
||||
|
|
@ -291,7 +299,6 @@ RouteTimeAxisView::set_route (boost::shared_ptr<Route> rt)
|
|||
_y_position = -1;
|
||||
|
||||
_route->processors_changed.connect (*this, invalidator (*this), boost::bind (&RouteTimeAxisView::processors_changed, this, _1), gui_context());
|
||||
_route->PropertyChanged.connect (*this, invalidator (*this), boost::bind (&RouteTimeAxisView::route_property_changed, this, _1), gui_context());
|
||||
|
||||
if (is_track()) {
|
||||
|
||||
|
|
@ -457,14 +464,6 @@ RouteTimeAxisView::parameter_changed (string const & p)
|
|||
}
|
||||
}
|
||||
|
||||
void
|
||||
RouteTimeAxisView::route_property_changed (const PropertyChange& what_changed)
|
||||
{
|
||||
if (what_changed.contains (ARDOUR::Properties::name)) {
|
||||
label_view ();
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
RouteTimeAxisView::take_name_changed (void *src)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -211,7 +211,7 @@ class RouteUI : public virtual AxisView
|
|||
void manage_pins ();
|
||||
void maybe_add_route_print_mgr ();
|
||||
|
||||
virtual void property_changed (const PBD::PropertyChange&);
|
||||
virtual void route_property_changed (const PBD::PropertyChange&) = 0;
|
||||
void route_removed ();
|
||||
|
||||
virtual void route_active_changed () {}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue