Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src-tauri/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions src-tauri/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,9 @@ dirs = "5"
# check falls back to webpki-roots. macOS/Windows keep the platform verifier.
webpki-roots = "0.26"
rustls = { version = "0.23", default-features = false, features = ["ring", "std", "tls12"] }
# Plugin editor windows are realized by hand before a plugin view is parented
# into them; same gtk that tauri already links.
gtk = "0.18"

[target.'cfg(unix)'.dependencies]
# Fatal-signal crash persistence; Linux VST3 hosting also uses dlopen and poll.
Expand Down
14 changes: 14 additions & 0 deletions src-tauri/src/audio/plugins/editor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,20 @@ pub fn open(node_id: &str, title: &str) -> Result<(), String> {
.unwrap()
.insert(node_id.to_string(), window.clone());

// GTK creates the native window on realize, which a hidden window has not
// been through; without it there is no handle to parent the plugin view to.
#[cfg(target_os = "linux")]
{
use gtk::prelude::WidgetExt;
match window.gtk_window() {
Ok(gtk_window) => gtk_window.realize(),
Err(e) => {
close_window(node_id);
return Err(format!("editor window for {node_id}: {e}"));
}
}
}

let embedded = match super::registry::for_node(node_id) {
Some(host) => host.embed_editor(node_id, &window),
None => Err(format!("{node_id}: no plugin is running on this node")),
Expand Down