diff options
-rw-r--r-- | libs/ardour/ardour/session.h | 2 | ||||
-rw-r--r-- | libs/ardour/session.cc | 23 |
2 files changed, 8 insertions, 17 deletions
diff --git a/libs/ardour/ardour/session.h b/libs/ardour/ardour/session.h index 3c01725740..807c2686eb 100644 --- a/libs/ardour/ardour/session.h +++ b/libs/ardour/ardour/session.h @@ -2033,8 +2033,6 @@ private: void rt_set_controls (boost::shared_ptr<ControlList>, double val, PBD::Controllable::GroupControlDisposition group_override); void rt_clear_all_solo_state (boost::shared_ptr<RouteList>, bool yn, PBD::Controllable::GroupControlDisposition group_override); - void set_session_range_location (samplepos_t, samplepos_t); - void setup_midi_machine_control (); void step_edit_status_change (bool); diff --git a/libs/ardour/session.cc b/libs/ardour/session.cc index 6b988be098..03891d4c47 100644 --- a/libs/ardour/session.cc +++ b/libs/ardour/session.cc @@ -1512,18 +1512,18 @@ Session::set_auto_punch_location (Location* location) void Session::set_session_extents (samplepos_t start, samplepos_t end) { - Location* existing; - if ((existing = _locations->session_range_location()) == 0) { - //if there is no existing session, we need to make a new session location (should never happen) - existing = new Location (*this, 0, 0, _("session"), Location::IsSessionRange, 0); - } - if (end <= start) { error << _("Session: you can't use that location for session start/end)") << endmsg; return; } - existing->set( start, end ); + Location* existing; + if ((existing = _locations->session_range_location()) == 0) { + _session_range_location = new Location (*this, start, end, _("session"), Location::IsSessionRange, 0); + _locations->add (_session_range_location); + } else { + existing->set( start, end ); + } set_dirty(); } @@ -4176,7 +4176,7 @@ Session::maybe_update_session_range (samplepos_t a, samplepos_t b) if (_session_range_location == 0) { - set_session_range_location (a, b + session_end_marker_shift_samples); + set_session_extents (a, b + session_end_marker_shift_samples); } else { @@ -6112,13 +6112,6 @@ Session::current_end_sample () const } void -Session::set_session_range_location (samplepos_t start, samplepos_t end) -{ - _session_range_location = new Location (*this, start, end, _("session"), Location::IsSessionRange, 0); - _locations->add (_session_range_location); -} - -void Session::step_edit_status_change (bool yn) { bool send = false; |