MCPcopy Create free account
hub / github.com/DISTRHO/Cardinal / widgetDestroyed

Method widgetDestroyed

plugins/Cardinal/src/Carla.cpp:581–605  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

579 }
580
581 void widgetDestroyed()
582 {
583 if (module == nullptr || module->pcontext == nullptr || module->fCarlaHostHandle == nullptr)
584 return;
585
586 const CarlaHostHandle handle = module->fCarlaHostHandle;
587 const CardinalPluginContext* const pcontext = module->pcontext;
588
589 module->fUI = nullptr;
590
591 if (visible)
592 {
593 visible = false;
594 module->fCarlaPluginDescriptor->ui_show(module->fCarlaPluginHandle, false);
595 }
596
597 if (idleCallbackActive)
598 {
599 idleCallbackActive = false;
600 pcontext->removeIdleCallback(this);
601 }
602
603 module->fCarlaHostDescriptor.uiParentId = 0;
604 carla_set_engine_option(handle, ENGINE_OPTION_FRONTEND_WIN_ID, 0, "0");
605 }
606
607 void idleCallback() override
608 {

Callers

nothing calls this directly

Calls 1

removeIdleCallbackMethod · 0.45

Tested by

no test coverage detected