mirror of
https://github.com/robbert-vdh/yabridge.git
synced 2026-06-10 14:22:16 +02:00
Implement IUnitHandler::notifyProgramListChange
With this IUnitHandler has been fully implemented.
This commit is contained in:
@@ -154,7 +154,8 @@ using CallbackRequest = std::variant<WantsConfiguration,
|
||||
YaConnectionPoint::Notify,
|
||||
YaHostApplication::GetName,
|
||||
YaPlugFrame::ResizeView,
|
||||
YaUnitHandler::NotifyUnitSelection>;
|
||||
YaUnitHandler::NotifyUnitSelection,
|
||||
YaUnitHandler::NotifyProgramListChange>;
|
||||
|
||||
template <typename S>
|
||||
void serialize(S& s, CallbackRequest& payload) {
|
||||
|
||||
@@ -82,6 +82,28 @@ class YaUnitHandler : public Steinberg::Vst::IUnitHandler {
|
||||
|
||||
virtual tresult PLUGIN_API
|
||||
notifyUnitSelection(Steinberg::Vst::UnitID unitId) override = 0;
|
||||
|
||||
/**
|
||||
* Message to pass through a call to
|
||||
* `IUnitHandler::notifyProgramListChange(list_id, program_index)` to the
|
||||
* unit handler provided by the host.
|
||||
*/
|
||||
struct NotifyProgramListChange {
|
||||
using Response = UniversalTResult;
|
||||
|
||||
native_size_t owner_instance_id;
|
||||
|
||||
Steinberg::Vst::ProgramListID list_id;
|
||||
int32 program_index;
|
||||
|
||||
template <typename S>
|
||||
void serialize(S& s) {
|
||||
s.value8b(owner_instance_id);
|
||||
s.value4b(list_id);
|
||||
s.value4b(program_index);
|
||||
}
|
||||
};
|
||||
|
||||
virtual tresult PLUGIN_API
|
||||
notifyProgramListChange(Steinberg::Vst::ProgramListID listId,
|
||||
int32 programIndex) override = 0;
|
||||
|
||||
Reference in New Issue
Block a user