Skip to content
  • eric.carlson@apple.com's avatar
    Allow ports to override text track rendering style · 68e8da75
    eric.carlson@apple.com authored
    https://bugs.webkit.org/show_bug.cgi?id=97800
    <rdar://problem/12044964>
    
    Reviewed by Maciej Stachowiak.
    
    Source/WebCore:
    
    * WebCore.exp.in: Export new WebkitSystemInterface functions.
    * WebCore.xcodeproj/project.pbxproj: Add CaptionUserPreferences.h, CaptionUserPreferencesMac.mm,
        and CaptionUserPreferencesMac.h.
    
    * css/mediaControls.css: Rearrange the caption CSS so it is possible to style the cue window,
        background, and text independently.
    
    * html/HTMLMediaElement.cpp:
    (WebCore::HTMLMediaElement::HTMLMediaElement): Initialize m_disableCaptions with theme->userPrefersCaptions().
    (WebCore::HTMLMediaElement::attach): Register for caption preferences change callbacks.
    (WebCore::HTMLMediaElement::detach): Unregister for caption preferences change callbacks.
    (WebCore::HTMLMediaElement::userPrefersCaptions): Return theme->userPrefersCaptions().
    (WebCore::HTMLMediaElement::userIsInterestedInThisTrackKind): Consider userPrefersCaptions().
    (WebCore::HTMLMed...
    68e8da75