From 626c31beb32fabf3360d79dac335e7b2778d4f86 Mon Sep 17 00:00:00 2001 From: Robbert van der Helm Date: Thu, 20 May 2021 14:00:03 +0200 Subject: [PATCH] Update documentation on mutual recursion functions --- src/plugin/bridges/vst3.h | 4 ++-- src/wine-host/bridges/vst3.h | 12 ++++-------- 2 files changed, 6 insertions(+), 10 deletions(-) diff --git a/src/plugin/bridges/vst3.h b/src/plugin/bridges/vst3.h index ba52d7fc..1fed94f9 100644 --- a/src/plugin/bridges/vst3.h +++ b/src/plugin/bridges/vst3.h @@ -156,10 +156,10 @@ class Vst3PluginBridge : PluginBridge> { /** * If `send_mutually_recursive_message()` is currently being called, then - * run `cb` on the thread that's currently calling that function and return + * run `fn` on the thread that's currently calling that function and return * the result of the call. If there's currently no mutually recursive * function call going on, this will return an `std::nullopt`, and the - * caller should call `cb` itself. + * caller should call `fn` itself. * * @return The result of calling `fn`, if `fn` was called. * diff --git a/src/wine-host/bridges/vst3.h b/src/wine-host/bridges/vst3.h index 03e793d6..a7aa90bc 100644 --- a/src/wine-host/bridges/vst3.h +++ b/src/wine-host/bridges/vst3.h @@ -254,10 +254,10 @@ class Vst3Bridge : public HostBridge { /** * Spawn a new thread and call `send_message()` from there, and then handle - * functions passed by calls to `do_mutual_recursion_on_gui_thread()` on - * this thread until the original message we're trying to send has - * succeeded. This is a very specific solution to a very specific problem. - * When a plugin wants to resize itself, it will call + * functions passed by calls to `do_mutual_recursion_on_gui_thread()` and + * `do_mutual_recursion_on_off_thread()` on this thread until we get a + * response back. This is a very specific solution to a very specific + * problem. When a plugin wants to resize itself, it will call * `IPlugFrame::resizeView()` from within the WIn32 message loop. The host * will then call `IPlugView::onSize()` on the plugin's `IPlugView` to * actually resize the plugin. The issue is that that call to @@ -275,10 +275,6 @@ class Vst3Bridge : public HostBridge { * context. * * We apply the same trick in `Vst3HostBridge`. - * - * TODO: Maybe trim down the documentation for all of these mutual recursion - * functions now that we're handling the nasty bits in - * `MutualRecursionHelper`. */ template typename T::Response send_mutually_recursive_message(const T& object) {