This fixes EZdrummer not producing any sound, as the plugin presumably
schedules some task on the Win32 message loop to load its resources,
which won't happen if this is run from any other thread.
Although it hasn't shown up, this will get rid of the possibility of
off-thread effEditIdle calls causing issues. And since we need some way
to run call this function while the event loop is running anyways, doing
it entirely from a timer similar to how hosts on Windows would do it
seems like the best solution.
Before deferring closing the editor. This still gets rid of that issue
in Wine's X11drv that would result in a double destroy, and it also gets
rid of a delay that would still occur in Carla.
With the new deferred closing behaviour, closing the editor of Vital's
VST2 version would trigger an X11 error in Wine's X11drv. This doesn't
seem to happen with other plugins (or the VST3 version of Vital) and the
fact that this workaround even works is strange to say the least, but at
least it does work.
While this does get rid of artifacts, it can also add a brief moment
where the gray background becomes visible when the window reconfigures
which can look jarring.
This reverts commit 35c7138333.
Instead of serializing the actual `YaMessage`, for the reasons mentioned
in the comments. This was needed to stop iZotope VocalSynth 2 in Ardour
from segfaulting when editing parameters, because that plugin is
apparently being very naughty.
They're exchanging pointers between the processor and the controller
using messages. And not only that, they're storing the message objects
instead of storing the pointers.
I've also tried a lot of other things, but none of the solutions I've
tried work 100% of the time. It sounds like a better idea to have
something that doesn't work consistently than to have something that
inconsistently sort of works. Setting the size in `WM_WINDOWPOSCHANGING`
to (0, 0) fixes the drifting, but the mouse coordinates are still wrong
and `SetWindowPos()` breaks the reparenting.
This reverts commit db2cc5800a.
I think some rounding in Wine is causing this issue, but then again
we're not supposed to send these ConfigureNotify events to the window
directly anyways.