VST3: Allow IRunLoop to query itself

For whatever reason renoise_redux.vst3 requires this, and
otherwise complains that the host does not implement IRunLoop
interface, which the plugin already successfully retrieved
to make this query in the first place.
This commit is contained in:
Robin Gareus 2025-07-24 13:42:51 +02:00
parent 361d0374dc
commit 0759c34b7d
No known key found for this signature in database
GPG key ID: A090BCE02CF57F04

View file

@ -82,6 +82,8 @@ DEF_CLASS_IID (Presonus::IPlugInViewScaling)
#if SMTG_OS_LINUX
DEF_CLASS_IID (Linux::IRunLoop);
DEF_CLASS_IID (Linux::ITimerHandler);
DEF_CLASS_IID (Linux::IEventHandler);
class AVST3Runloop : public Linux::IRunLoop
{
@ -212,7 +214,14 @@ public:
uint32 PLUGIN_API addRef () SMTG_OVERRIDE { return 1; }
uint32 PLUGIN_API release () SMTG_OVERRIDE { return 1; }
tresult queryInterface (const TUID, void**) SMTG_OVERRIDE { return kNoInterface; }
tresult queryInterface (const TUID iid, void** obj) SMTG_OVERRIDE {
if (FUnknownPrivate::iidEqual (iid, Linux::IRunLoop::iid)) {
*obj = this;
return kResultOk;
}
return kNoInterface;
}
private:
Glib::Threads::Mutex _lock;