1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 12:07:45 +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

@ -106,10 +106,7 @@ ErrorOr<void> ConnectionBase::post_message(MessageBuffer buffer)
dbgln("LibIPC::Connection FIXME Warning, needed {} writes needed to send message of size {}B, this is pretty bad, as it spins on the EventLoop", writes_done, initial_size);
}
// Note: This disables responsiveness detection when an event loop is absent.
// There are no users which both need this feature but don't have an event loop.
if (Core::EventLoop::has_been_instantiated())
m_responsiveness_timer->start();
m_responsiveness_timer->start();
return {};
}