1
0
Fork 0
Commit graph

29 commits

Author SHA1 Message Date
Robbert van der Helm
164e8bd402 Update the windows dependency version 2023-03-01 22:34:46 +01:00
Robbert van der Helm
42a7bb37b4 Revert event loop APIs to use Weak instead of Arc
Previously the plugin wouldn't get dropped because the event loops kept
them alive. These APIs used Weak instead of Arc in the past precisely to
prevent this issue. Not sure why I changed that.
2023-02-23 21:45:09 +01:00
Robbert van der Helm
4564bf9027 Fix reference counts for background worker threads
We would decrement this on drop, but never increment it on clone. Oops.
2023-02-23 21:30:09 +01:00
Robbert van der Helm
47b75fd020 Fix missing generic arguments on BackgroundThread 2023-01-06 17:59:33 +01:00
Robbert van der Helm
28cd25d501 Implement Linux event loop using BackgroundThread
This reduces duplication a lot.
2023-01-06 17:53:07 +01:00
Robbert van der Helm
5c9be077e7 Allow BackgroundThread sharing between instances
This removes the need for every instance to have its own background
thread.
2023-01-06 17:51:38 +01:00
Robbert van der Helm
935bf6f7f3 Fix allocation failures in BackgroundThread 2023-01-06 16:03:48 +01:00
Robbert van der Helm
c0e9b29bf4 Remove macOS deprecation warning from event loop 2023-01-06 15:58:01 +01:00
Robbert van der Helm
d5006d109e Code style cleanup for macOS event loop 2023-01-06 15:46:29 +01:00
max
1e83730ba9 rename variable 2023-01-02 19:30:31 +02:00
max
edca84a42c address comments 2023-01-02 19:29:13 +02:00
max
1fbe3efb79 update comment 2023-01-01 20:22:17 +02:00
max
9fd88ffd48 initial event loop implementation for macOS 2023-01-01 20:14:55 +02:00
Robbert van der Helm
028aeed18e Add a schedule_background() EventLoop method 2022-10-23 16:19:49 +02:00
Robbert van der Helm
520eba71ca Add a simple background thread task runner
This can be used by the Windows event loop, the future macOS event loop,
and the CLAP event loop.
2022-10-23 16:14:35 +02:00
Robbert van der Helm
dbb97f0534 Use channels for Windows event loop
Instead of an `ArrayQueue`. Since this doesn't need to both send and
receive on the same object.
2022-10-23 15:52:14 +02:00
Robbert van der Helm
31cda78201 Rename do_maybe_async() to schedule_gui() 2022-10-23 15:48:27 +02:00
Robbert van der Helm
4524719128 Add an is_gui_thread flag to MainThreadExecutor
We'll also use the EventLoop for running background tasks completely
decoupled from the GUI.
2022-10-23 15:48:27 +02:00
Robbert van der Helm
967426453a Clean up EventLoop API
By taking an `Arc<T>` instead of a `Weak<T>`. The `Weak` is only needed
for the background threads.
2022-10-23 15:48:27 +02:00
Simon Leiner
0caef90b1a Fix typos in comments 2022-09-29 15:13:43 +02:00
Simon Leiner
f4995abf88 Fix typos in documentation 2022-09-29 15:13:43 +02:00
Robbert van der Helm
2f87a79d3e Wait for the Windows event loop to shut down
This fixes crashes when removing the instance and immediately unloading
the module. `DestroyWindow()` is synchronous while `CloseWindow()`
merely posts a message to close the window.
2022-08-29 13:59:28 +02:00
Robbert van der Helm
c91b74355f Let rustfmt handle string wrapping 2022-07-03 16:52:38 +02:00
Robbert van der Helm
12a4440af0 Remove unnecessary use statement 2022-06-08 02:08:51 +02:00
Robbert van der Helm
b32cd27e8c Move FIR filters to their own module 2022-06-07 15:19:18 +02:00
Robbert van der Helm
89afa8bf00 Use nih_trace!() for lesser important messages
Like the missing CLAP extensions.
2022-06-07 14:18:56 +02:00
Robbert van der Helm
b9412657c1 Fix allocation error from thread locals 2022-03-08 14:07:29 +01:00
Robbert van der Helm
f581294d7b Update rustdoc formatting for links
Apparently it showed this text verbatim, and not in monospace.
2022-03-03 23:05:12 +01:00
Robbert van der Helm
b209c9caf3 Move the event loop to its own module
Now that the context module is becoming larger and larger.
2022-02-28 12:57:01 +01:00