add set_tempo/set_meter() methods to Region

This commit is contained in:
Paul Davis
2025-08-09 20:16:54 -06:00
parent 89a26e224a
commit 95006c085c
2 changed files with 20 additions and 0 deletions

View File

@@ -545,7 +545,9 @@ public:
}
Temporal::Tempo tempo() const { return _tempo; }
void set_tempo (Temporal::Tempo const &);
Temporal::Meter meter() const { return _meter; }
void set_meter (Temporal::Meter const &);
protected:
virtual XMLNode& state () const;

View File

@@ -2508,3 +2508,21 @@ Region::fx_tail_changed (bool)
}
_fx_tail = t;
}
void
Region::set_tempo (Temporal::Tempo const & t)
{
if (_tempo != t) {
_tempo = t;
send_change (Properties::region_tempo);
}
}
void
Region::set_meter (Temporal::Meter const & m)
{
if (_meter != m) {
_meter = m;
send_change (Properties::region_meter);
}
}