MCPcopy Create free account
hub / github.com/audacity/audacity / OnClose

Method OnClose

src/effects/VST/VSTEditor.cpp:592–622  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

590}
591
592void VSTEditor::OnClose()
593{
594
595#ifdef __WXMAC__
596#ifdef __WX_EVTLOOP_BUSY_WAITING__
597 wxEventLoop::SetBusyWaiting(false);
598#endif
599 if (mControl)
600 mControl->Close();
601#endif
602
603 // Tell the instance not to use me anymore - if we do not do this,
604 // hiding the gui and then showing it again *while playing*, would leave
605 // the instance with a dangling pointer to the old owning validator
606 // for a fraction of time, thereby causing a crash.
607 GetInstance().SetOwningValidator(nullptr);
608
609 NeedEditIdle(false);
610
611 mNames.reset();
612 mSliders.reset();
613 mDisplays.reset();
614 mLabels.reset();
615
616 mParent = NULL;
617 mDialog = NULL;
618
619 mAccess.Flush();
620
621 ValidateUI();
622}

Callers

nothing calls this directly

Calls 4

SetOwningValidatorMethod · 0.80
CloseMethod · 0.45
resetMethod · 0.45
FlushMethod · 0.45

Tested by

no test coverage detected