LibWeb: Reset cursor blink cycle, even if there's no viewport paintable

If we programmatically set a selection in an editable element during
document load, we failed to start the cursor blink cycle timer. The
cursor blink logic already takes care of us not having the paintable
yet, so start it unconditionally.
This commit is contained in:
Jelle Raaijmakers 2025-08-20 11:46:57 +02:00 committed by Jelle Raaijmakers
commit cd08b3b6f4
Notes: github-actions[bot] 2025-08-20 10:37:22 +00:00

View file

@ -104,8 +104,8 @@ void Range::update_associated_selection()
return;
auto& document = m_start_container->document();
document.reset_cursor_blink_cycle();
if (auto* viewport = document.paintable()) {
document.reset_cursor_blink_cycle();
viewport->recompute_selection_states(*this);
viewport->set_needs_display();
}