[webkit-changes] [WebKit/WebKit] fd569d: Custom Highlights API painting does not invalidate...

megangardner noreply at github.com
Fri Jan 5 20:04:45 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: fd569defc022c2d1e03658764ac31816e0267ef1
      https://github.com/WebKit/WebKit/commit/fd569defc022c2d1e03658764ac31816e0267ef1
  Author: Megan Gardner <megan_gardner at apple.com>
  Date:   2024-01-05 (Fri, 05 Jan 2024)

  Changed paths:
    A LayoutTests/fast/repaint/highlight-removed-when-cleared-expected.txt
    A LayoutTests/fast/repaint/highlight-removed-when-cleared.html
    M Source/WebCore/Modules/highlight/HighlightRegistry.cpp

  Log Message:
  -----------
  Custom Highlights API painting does not invalidate properly when removing highlights
https://bugs.webkit.org/show_bug.cgi?id=267136
rdar://119531671

Reviewed by Tim Horton.

When clearing the entire highlight registry held on the document, we only
cleared the map of the highlights, which are sets of ranges. This did not
actually clear the highlight sets, and so the ranges were never flagged for
repainting. So when clearing the highlight registry, we need to ensure
that we are clearing each set of highlights specifically.

* LayoutTests/fast/repaint/highlight-removed-when-cleared-expected.txt: Added.
* LayoutTests/fast/repaint/highlight-removed-when-cleared.html: Added.
* Source/WebCore/Modules/highlight/HighlightRegistry.cpp:
(WebCore::HighlightRegistry::clear):

Canonical link: https://commits.webkit.org/272723@main




More information about the webkit-changes mailing list