diff --git a/gtk2_ardour/editor_markers.cc b/gtk2_ardour/editor_markers.cc index 1b11539340..e2ce0f2879 100644 --- a/gtk2_ardour/editor_markers.cc +++ b/gtk2_ardour/editor_markers.cc @@ -177,7 +177,7 @@ Editor::add_new_location_internal (Location* location) } location->name_changed.connect (*this, invalidator (*this), boost::bind (&Editor::location_changed, this, _1), gui_context()); - location->position_time_domain_changed.connect (*this, invalidator (*this), boost::bind (&Editor::location_changed, this, _1), gui_context()); + location->TimeDomainChanged.connect (*this, invalidator (*this), boost::bind (&Editor::location_changed, this, location), gui_context()); location->FlagsChanged.connect (*this, invalidator (*this), boost::bind (&Editor::location_flags_changed, this, location), gui_context()); pair newpair; diff --git a/libs/ardour/ardour/location.h b/libs/ardour/ardour/location.h index bca14616b8..7569094a31 100644 --- a/libs/ardour/ardour/location.h +++ b/libs/ardour/ardour/location.h @@ -130,7 +130,6 @@ public: static PBD::Signal1 start_changed; static PBD::Signal1 flags_changed; static PBD::Signal1 lock_changed; - static PBD::Signal1 position_time_domain_changed; /* this is sent only when both start and end change at the same time */ static PBD::Signal1 changed; diff --git a/libs/ardour/location.cc b/libs/ardour/location.cc index e93fca4f06..d68dc24247 100644 --- a/libs/ardour/location.cc +++ b/libs/ardour/location.cc @@ -61,7 +61,6 @@ PBD::Signal1 Location::end_changed; PBD::Signal1 Location::start_changed; PBD::Signal1 Location::flags_changed; PBD::Signal1 Location::lock_changed; -PBD::Signal1 Location::position_time_domain_changed; PBD::Signal1 Location::changed; Location::Location (Session& s) @@ -650,15 +649,9 @@ Location::set_position_time_domain (TimeDomain domain) return; } - if (domain == Temporal::BeatTime) { - _start = timepos_t (_start.beats()); - _end = timepos_t (_end.beats()); - } else { - _start = timepos_t (_start.samples()); - _end = timepos_t (_end.samples()); - } + _start.set_time_domain (domain); + _end.set_time_domain (domain); - position_time_domain_changed (this); /* EMIT SIGNAL */ TimeDomainChanged (); /* EMIT SIGNAL */ } diff --git a/libs/ardour/session.cc b/libs/ardour/session.cc index 8cafa213dc..ca3b91e69e 100644 --- a/libs/ardour/session.cc +++ b/libs/ardour/session.cc @@ -1932,8 +1932,7 @@ Session::location_added (Location *location) location->EndChanged.connect_same_thread (skip_update_connections, boost::bind (&Session::update_marks, this, location)); location->Changed.connect_same_thread (skip_update_connections, boost::bind (&Session::update_marks, this, location)); location->FlagsChanged.connect_same_thread (skip_update_connections, boost::bind (&Session::update_marks, this, location)); -#warning NUTEMPO can locations have their lock style changed and how - // location->PositionLockStyleChanged.connect_same_thread (skip_update_connections, boost::bind (&Session::update_marks, this, location)); + location->TimeDomainChanged.connect_same_thread (skip_update_connections, boost::bind (&Session::update_marks, this, location)); } if (location->is_range_marker()) { @@ -1943,8 +1942,7 @@ Session::location_added (Location *location) location->EndChanged.connect_same_thread (skip_update_connections, boost::bind (&Session::update_marks, this, location)); location->Changed.connect_same_thread (skip_update_connections, boost::bind (&Session::update_marks, this, location)); location->FlagsChanged.connect_same_thread (skip_update_connections, boost::bind (&Session::update_marks, this, location)); -#warning NUTEMPO can locations have their lock style changed and how - // location->PositionLockStyleChanged.connect_same_thread (skip_update_connections, boost::bind (&Session::update_marks, this, location)); + location->TimeDomainChanged.connect_same_thread (skip_update_connections, boost::bind (&Session::update_marks, this, location)); } if (location->is_skip()) { @@ -1954,8 +1952,7 @@ Session::location_added (Location *location) location->EndChanged.connect_same_thread (skip_update_connections, boost::bind (&Session::update_skips, this, location, true)); location->Changed.connect_same_thread (skip_update_connections, boost::bind (&Session::update_skips, this, location, true)); location->FlagsChanged.connect_same_thread (skip_update_connections, boost::bind (&Session::update_skips, this, location, false)); -#warning NUTEMPO can locations have their lock style changed and how - // location->PositionLockStyleChanged.connect_same_thread (skip_update_connections, boost::bind (&Session::update_marks, this, location)); + location->TimeDomainChanged.connect_same_thread (skip_update_connections, boost::bind (&Session::update_marks, this, location)); update_skips (location, true); }