tempo display: basics of updating MIDI during tempo-related drag operations
This commit is contained in:
@@ -1730,6 +1730,8 @@ private:
|
||||
Temporal::TempoMap::WritableSharedPtr begin_tempo_map_edit ();
|
||||
void abort_tempo_map_edit ();
|
||||
void commit_tempo_map_edit (Temporal::TempoMap::WritableSharedPtr&);
|
||||
void mid_tempo_per_track_update (TimeAxisView&);
|
||||
void mid_tempo_per_region_update (RegionView*);
|
||||
bool ignore_map_change;
|
||||
|
||||
enum MidTempoChanges {
|
||||
|
||||
@@ -57,6 +57,7 @@
|
||||
#include "gui_thread.h"
|
||||
#include "time_axis_view.h"
|
||||
#include "grid_lines.h"
|
||||
#include "region_view.h"
|
||||
#include "ui_config.h"
|
||||
|
||||
#include "pbd/i18n.h"
|
||||
@@ -761,4 +762,31 @@ Editor::mid_tempo_change (MidTempoChanges what_changed)
|
||||
|
||||
update_tempo_based_rulers ();
|
||||
maybe_draw_grid_lines ();
|
||||
|
||||
foreach_time_axis_view (sigc::mem_fun (*this, &Editor::mid_tempo_per_track_update));
|
||||
|
||||
}
|
||||
|
||||
void
|
||||
Editor::mid_tempo_per_track_update (TimeAxisView& tav)
|
||||
{
|
||||
MidiTimeAxisView* mtav = dynamic_cast<MidiTimeAxisView*> (&tav);
|
||||
|
||||
if (!mtav) {
|
||||
return;
|
||||
}
|
||||
|
||||
MidiStreamView* msv = mtav->midi_view();
|
||||
|
||||
if (!msv) {
|
||||
return;
|
||||
}
|
||||
|
||||
msv->foreach_regionview (sigc::mem_fun (*this, &Editor::mid_tempo_per_region_update));
|
||||
}
|
||||
|
||||
void
|
||||
Editor::mid_tempo_per_region_update (RegionView* rv)
|
||||
{
|
||||
rv->redisplay (true);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user