Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: Lifecycle callbacks for the webview #65

Open
giohappy opened this issue May 16, 2024 · 0 comments
Open

Feature Request: Lifecycle callbacks for the webview #65

giohappy opened this issue May 16, 2024 · 0 comments

Comments

@giohappy
Copy link

For the moment the only way to respond to the lifecycle events of the webview component are the standard connectedCallback and disconnectedCallback for Web Components.

These callbacks are triggered outside the control of Cmajor. They rely on the underlying webview engine, and they cannot be used reliably since there are many factors that may trigger ot not them. In particular, from my tests, the disconnectedCallback is never triggered when the plugins'UI is hidden inside a VST/CLAP host, or when the plugin is removed.

There are cases where having control on the UI being closed or hidden is critical. Cleanup routines, like removing patch listeneres, or stored status saving.

A more reliable solution would be if Cmajor provided dedicated callbacks, connected to the plugin's editor lifecycle.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant