13
0

triggerbox: new API to set from region (selection)

This commit is contained in:
Paul Davis 2021-10-24 09:25:11 -06:00
parent 600e0b21e8
commit 7339aa7c0d
2 changed files with 11 additions and 0 deletions

View File

@ -346,6 +346,7 @@ class LIBARDOUR_API TriggerBox : public Processor
int set_state (const XMLNode&, int version);
int set_from_path (uint64_t slot, std::string const & path);
int set_from_selection (uint64_t slot, boost::shared_ptr<Region>);
DataType data_type() const { return _data_type; }

View File

@ -1285,6 +1285,16 @@ TriggerBox::get_next_trigger ()
return 0;
}
int
TriggerBox::set_from_selection (uint64_t slot, boost::shared_ptr<Region> region)
{
if (slot >= all_triggers.size()) {
return 0;
}
return all_triggers[slot]->set_region (region);
}
int
TriggerBox::set_from_path (uint64_t slot, std::string const & path)
{