Skip to content

Commit

Permalink
LibWeb: Reschedule HTML event loop processing if navigable needs repaint
Browse files Browse the repository at this point in the history
This is an attempt to fix the hanging CI on macOS caused by some
screenshot requests being stuck unprocessed. With this change, we at
least make sure that the HTML event loop processing, which triggers
repainting, will happen as long as there are navigables that need to be
repainted.
  • Loading branch information
kalenikaliaksandr committed Jul 2, 2024
1 parent 8a7afff commit 72b4d44
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Userland/Libraries/LibWeb/HTML/EventLoop/EventLoop.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,8 @@ void EventLoop::process()
// loop processing.
for_each_fully_active_document_in_docs([&](DOM::Document& document) {
auto navigable = document.navigable();
if (navigable && !navigable->has_a_rendering_opportunity() && navigable->needs_repaint())
schedule();
if (navigable && navigable->has_a_rendering_opportunity())
return;
auto* browsing_context = document.browsing_context();
Expand Down

0 comments on commit 72b4d44

Please sign in to comment.