Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 012c7fc8787cf44798f92c07ac4efe4a1105aac0
      
https://github.com/WebKit/WebKit/commit/012c7fc8787cf44798f92c07ac4efe4a1105aac0
  Author: Ahmad Saleem <[email protected]>
  Date:   2026-06-28 (Sun, 28 Jun 2026)

  Changed paths:
    M 
Source/WebCore/platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp

  Log Message:
  -----------
  [AVFoundation] De-duplicate the ARGB color-extraction blocks in 
processCueAttributes()
https://bugs.webkit.org/show_bug.cgi?id=318063
rdar://180858531

Reviewed by Eric Carlson.

The handlers for the ForegroundColorARGB, BackgroundColorARGB, and
CharacterBackgroundColorARGB markup attributes in processCueAttributes()
were byte-identical except for the InbandGenericCue setter they called:
each cast the value to a CFArrayRef, ran it through
makeSimpleColorFromARGBCFArray(), and applied the result.

Extract the shared logic into an applyColorAttribute() lambda that takes
a pointer-to-member setter, collapsing three ~11-line blocks into one
helper plus three one-line dispatches. No change in behavior.

* Source/WebCore/platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
(WebCore::InbandTextTrackPrivateAVF::processCueAttributes):

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



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

Reply via email to