Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: e24c704e89a1182de0db8f9373f9c50668b9b4d2
      
https://github.com/WebKit/WebKit/commit/e24c704e89a1182de0db8f9373f9c50668b9b4d2
  Author: Josh Hernandez <[email protected]>
  Date:   2026-07-01 (Wed, 01 Jul 2026)

  Changed paths:
    M LayoutTests/media/track/text-track-find.html
    M Source/WTF/Scripts/Preferences/UnifiedWebPreferences.yaml
    M Source/WebCore/Headers.cmake
    M Source/WebCore/dom/Document.cpp
    M Source/WebCore/page/CueMatch.h
    M Source/WebKit/WebProcess/WebPage/FindController.cpp
    M Source/WebKit/WebProcess/WebPage/FindController.h

  Log Message:
  -----------
  Include video caption cues in Find-in-Page navigation on macOS
https://bugs.webkit.org/show_bug.cgi?id=317672
rdar://180430525

Reviewed by Megan Gardner.

Extend Find-in-Page on macOS so that a search also matches text in
showing WebVTT caption/subtitle cues. Navigating to a cue match seeks the
associated media element to the cue's start time and scrolls it into
view, so Cmd+F / Cmd+G can step through spoken dialogue the same way it
steps through page text.

DOM text matches and cue matches are unified through a FindMatch variant
(SimpleRange or CueMatch) and merged in document order, so the find
cursor and next/previous navigation move across both kinds of match in a
single ordered sequence.

The behavior is gated behind the new FindInVideoEnabled feature flag,
which defaults to off.

* LayoutTests/media/track/text-track-find.html:
* Source/WTF/Scripts/Preferences/UnifiedWebPreferences.yaml:
* Source/WebCore/Headers.cmake:
* Source/WebCore/dom/Document.cpp:
(WebCore::Document::findCueMatches):
* Source/WebCore/page/CueMatch.h:
* Source/WebKit/WebProcess/WebPage/FindController.cpp:
(WebKit::mergeByDocumentOrder):
(WebKit::indexOfCursor):
(WebKit::FindController::countStringMatches):
(WebKit::FindController::applyFindMatch):
(WebKit::FindController::markMatches):
(WebKit::FindController::getMatchCount):
(WebKit::FindController::findString):
(WebKit::FindController::updateFindUIAfterIncrementalFind):
(WebKit::indexClosestToSelection):
* Source/WebKit/WebProcess/WebPage/FindController.h:

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



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

Reply via email to