[webkit-changes] [WebKit/WebKit] aaa1eb: Generate IPC serialization for CaptionUserPreferen...

Žan Doberšek noreply at github.com
Mon Nov 20 11:35:23 PST 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: aaa1eb722ad16c0a03c7d09924b8e6611fb65acb
      https://github.com/WebKit/WebKit/commit/aaa1eb722ad16c0a03c7d09924b8e6611fb65acb
  Author: Žan Doberšek <zdobersek at igalia.com>
  Date:   2023-11-20 (Mon, 20 Nov 2023)

  Changed paths:
    M Source/WebCore/Modules/mediacontrols/MediaControlsHost.cpp
    M Source/WebCore/html/HTMLMediaElement.cpp
    M Source/WebCore/page/CaptionUserPreferences.cpp
    M Source/WebCore/page/CaptionUserPreferences.h
    M Source/WebCore/page/CaptionUserPreferencesMediaAF.cpp
    M Source/WebCore/testing/Internals.cpp
    M Source/WebKit/Shared/WebCoreArgumentCoders.serialization.in

  Log Message:
  -----------
  Generate IPC serialization for CaptionUserPreferences::CaptionDisplayMode
https://bugs.webkit.org/show_bug.cgi?id=264402

Reviewed by Chris Dumez.

Move CaptionUserPreferences::CaptionDisplayMode enumeration outside the
CaptionUserPreferences class scope and turn it into a scoped enumeration,
setting up the type alias inside CaptionUserPreferences. Uses of the enumeration
values are adjusted to use the explicit scope.

This enables specifying IPC serialization for this enumeration, avoiding listing
all the enumeration values in the EnumTraits specialization. The latter still
has to remain due to the custom from-string construction.

* Source/WebCore/Modules/mediacontrols/MediaControlsHost.cpp:
(WebCore::MediaControlsHost::captionDisplayMode const):
(WebCore::MediaControlsHost::showMediaControlsContextMenu):
* Source/WebCore/html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::configureTextTrackGroup):
(WebCore::HTMLMediaElement::setSelectedTextTrack):
(WebCore::HTMLMediaElement::mediaPlayerCharacteristicChanged):
(WebCore::HTMLMediaElement::captionPreferencesChanged):
(WebCore::HTMLMediaElement::captionDisplayMode):
* Source/WebCore/page/CaptionUserPreferences.cpp:
(WebCore::CaptionUserPreferences::CaptionUserPreferences):
(WebCore::CaptionUserPreferences::setCaptionDisplayMode):
(WebCore::CaptionUserPreferences::textTrackSelectionScore const):
* Source/WebCore/page/CaptionUserPreferences.h:
* Source/WebCore/page/CaptionUserPreferencesMediaAF.cpp:
(WebCore::CaptionUserPreferencesMediaAF::CaptionUserPreferencesMediaAF):
(WebCore::CaptionUserPreferencesMediaAF::captionDisplayMode const):
(WebCore::CaptionUserPreferencesMediaAF::platformSetCaptionDisplayMode):
(WebCore::CaptionUserPreferencesMediaAF::setCaptionDisplayMode):
(WebCore::CaptionUserPreferencesMediaAF::platformCaptionDisplayMode):
(WebCore::CaptionUserPreferencesMediaAF::setPreferredLanguage):
(WebCore::CaptionUserPreferencesMediaAF::sortedTrackListForMenu):
* Source/WebCore/testing/Internals.cpp:
(WebCore::Internals::resetToConsistentState):
(WebCore::Internals::setCaptionDisplayMode):
* Source/WebKit/Shared/WebCoreArgumentCoders.serialization.in:

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




More information about the webkit-changes mailing list