[webkit-changes] [WebKit/WebKit] 09180a: [UnifiedPDF] Data detector page overlay installati...

Abrar Rahman Protyasha noreply at github.com
Mon Mar 18 19:44:02 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 09180a88fbc5d0a6862eef0b13382eff0d3fa32c
      https://github.com/WebKit/WebKit/commit/09180a88fbc5d0a6862eef0b13382eff0d3fa32c
  Author: Abrar Rahman Protyasha <a_protyasha at apple.com>
  Date:   2024-03-18 (Mon, 18 Mar 2024)

  Changed paths:
    M Source/WebKit/WebProcess/Plugins/PDF/UnifiedPDF/PDFDataDetectorOverlayController.mm

  Log Message:
  -----------
  [UnifiedPDF] Data detector page overlay installation should be deferred till an active highlight needs to be painted
https://bugs.webkit.org/show_bug.cgi?id=271202
rdar://124976143

Reviewed by Simon Fraser.

This patch makes use of the installIfNeeded idiom to defer
creation/installation of a PageOverlay instance until one is needed to
parent an active highlight or to repaint it. It is a memory optimization
in case the PDF in question has no data detector results.

* Source/WebKit/WebProcess/Plugins/PDF/UnifiedPDF/PDFDataDetectorOverlayController.mm:
(WebKit::PDFDataDetectorOverlayController::handleMouseEvent):
(WebKit::PDFDataDetectorOverlayController::didInvalidateHighlightOverlayRects):

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



To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications


More information about the webkit-changes mailing list