Move some code around to help remote tool later

Signed-off-by: falkTX <falktx@falktx.com>
This commit is contained in:
falkTX 2022-12-24 21:59:04 +00:00
parent 76cdce063c
commit 058ad891d2
No known key found for this signature in database
GPG key ID: CDBAA37ABC74FBA0
11 changed files with 747 additions and 198 deletions

View file

@ -67,40 +67,6 @@ START_NAMESPACE_DISTRHO
// -----------------------------------------------------------------------------------------------------------
bool CardinalPluginContext::addIdleCallback(IdleCallback* const cb) const
{
if (ui == nullptr)
return false;
ui->addIdleCallback(cb);
return true;
}
void CardinalPluginContext::removeIdleCallback(IdleCallback* const cb) const
{
if (ui == nullptr)
return;
ui->removeIdleCallback(cb);
}
void handleHostParameterDrag(const CardinalPluginContext* pcontext, uint index, bool started)
{
DISTRHO_SAFE_ASSERT_RETURN(pcontext->ui != nullptr,);
if (started)
{
pcontext->ui->editParameter(index, true);
pcontext->ui->setParameterValue(index, pcontext->parameters[index]);
}
else
{
pcontext->ui->editParameter(index, false);
}
}
// -----------------------------------------------------------------------------------------------------------
#ifdef DISTRHO_OS_WASM
struct WasmWelcomeDialog : rack::widget::OpaqueWidget
{