fix (some) editing based on tempo & meter marks

After beginning an edit operation with TempoMap::write_copy(), the tempoPoint and meterPoint objects
referenced by markers are incorrect, since they refer to the original map, not the copy we are working
on. Fix this with Editor::reassociate_metric_markers()

Some instances requiring this fix may still remain
This commit is contained in:
Paul Davis 2021-04-04 17:56:58 -06:00
parent 5838bcbe7c
commit 7938d8de4f
6 changed files with 90 additions and 23 deletions

View file

@ -1396,7 +1396,9 @@ Editor::set_session (Session *t)
restore_ruler_visibility ();
//tempo_map_changed (PropertyChange (0));
TempoMap::use()->apply_with_metrics (*this, &Editor::draw_metric_marks);
TempoMap::Metrics metrics;
TempoMap::use()->get_metrics (metrics);
draw_metric_marks (metrics);
for (TrackViewList::iterator i = track_views.begin(); i != track_views.end(); ++i) {
(static_cast<TimeAxisView*>(*i))->set_samples_per_pixel (samples_per_pixel);