1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 11:48:10 +00:00

LibCore: Big first step towards pluggable Core::EventLoop

The EventLoop is now a wrapper around an EventLoopImplementation.
Our old EventLoop code has moved into EventLoopImplementationUnix and
continues to work as before.

The main difference is that all the separate thread_local variables have
been collected into a file-local ThreadData data structure.

The goal here is to allow running Core::EventLoop with a totally
different backend, such as Qt for Ladybird.
This commit is contained in:
Andreas Kling 2023-04-24 12:25:14 +02:00
parent 3de8dd921e
commit 16c47ccff6
11 changed files with 718 additions and 562 deletions

View file

@ -14,7 +14,6 @@ static RefPtr<Client> s_the = nullptr;
Client& Client::the()
{
if (!s_the || !s_the->is_open()) {
VERIFY(Core::EventLoop::has_been_instantiated());
s_the = Client::try_create().release_value_but_fixme_should_propagate_errors();
}
return *s_the;