RESOLVED FIXED 221431
[Mac] Connect MediaSession with MediaRemote and NowPlaying
https://bugs.webkit.org/show_bug.cgi?id=221431
Summary [Mac] Connect MediaSession with MediaRemote and NowPlaying
Eric Carlson
Reported 2021-02-04 15:35:28 PST
Connect MediaSession with MediaRemote and NowPlaying
Attachments
Patch (93.34 KB, patch)
2021-02-04 16:01 PST, Eric Carlson
no flags
Patch (91.77 KB, patch)
2021-02-04 16:45 PST, Eric Carlson
ews-feeder: commit-queue-
Patch (91.83 KB, patch)
2021-02-04 17:35 PST, Eric Carlson
ews-feeder: commit-queue-
Patch (91.79 KB, patch)
2021-02-04 17:42 PST, Eric Carlson
ews-feeder: commit-queue-
Patch (92.10 KB, patch)
2021-02-04 17:54 PST, Eric Carlson
no flags
Patch (91.71 KB, patch)
2021-02-05 04:48 PST, Eric Carlson
ews-feeder: commit-queue-
Patch (91.75 KB, patch)
2021-02-05 05:13 PST, Eric Carlson
no flags
Patch (91.79 KB, patch)
2021-02-05 10:33 PST, Eric Carlson
no flags
Patch for landing (91.55 KB, patch)
2021-02-05 14:25 PST, Eric Carlson
no flags
Patch (1.67 KB, patch)
2021-02-08 13:14 PST, Eric Carlson
no flags
Patch (2.78 KB, patch)
2021-02-08 17:17 PST, Eric Carlson
no flags
Patch (2.40 KB, patch)
2021-02-09 08:19 PST, Eric Carlson
ews-feeder: commit-queue-
Patch (2.40 KB, patch)
2021-02-09 08:29 PST, Eric Carlson
no flags
Radar WebKit Bug Importer
Comment 1 2021-02-04 15:35:36 PST
Eric Carlson
Comment 2 2021-02-04 16:01:22 PST
Eric Carlson
Comment 3 2021-02-04 16:45:33 PST
Eric Carlson
Comment 4 2021-02-04 17:35:23 PST
Eric Carlson
Comment 5 2021-02-04 17:42:40 PST
Eric Carlson
Comment 6 2021-02-04 17:54:38 PST
Eric Carlson
Comment 7 2021-02-05 04:48:48 PST
Eric Carlson
Comment 8 2021-02-05 05:13:38 PST
Eric Carlson
Comment 9 2021-02-05 10:33:29 PST
Jer Noble
Comment 10 2021-02-05 11:02:40 PST
View in context: https://bugs.webkit.org/attachment.cgi?id=419392&action=review r=me, with just a couple nits. > Source/WebCore/Modules/mediasession/MediaSession.cpp:54 > + static const MapEntry entries[] = { I think this could be `constexpr` rather than just `const`. > Source/WebCore/Modules/mediasession/MediaSession.cpp:68 > + HashMap<MediaSessionAction, PlatformMediaSession::RemoteControlCommandType, WTF::IntHash<MediaSessionAction>, WTF::StrongEnumHashTraits<MediaSessionAction>> map; > + for (auto& entry : entries) > + map.add(entry.action, entry.command); > + return map; I _think_ this whole section could just be written as: using ActionToCommandMap = HashMap<MediaSessionAction, PlatformMediaSession::RemoteControlCommandType, WTF::IntHash<MediaSessionAction>, WTF::StrongEnumHashTraits<MediaSessionAction>>; return ActionToCommandMap { { MediaSessionAction::Play, PlatformMediaSession::PlayCommand }, ... }; Since HashMap has a constructor that takes an initializer list, but NBD. > Source/WebCore/platform/mac/RemoteCommandListenerMac.mm:45 > + static const MapEntry entries[] = { Same comment about `constexpr` and maybe just using an initializer list here.
Eric Carlson
Comment 11 2021-02-05 14:25:53 PST
Created attachment 419462 [details] Patch for landing
EWS
Comment 12 2021-02-05 15:19:02 PST
Committed r272445: <https://trac.webkit.org/changeset/272445> All reviewed patches have been landed. Closing bug and clearing flags on attachment 419462 [details].
Eric Carlson
Comment 13 2021-02-08 13:14:45 PST
Reopening to attach new patch.
Eric Carlson
Comment 14 2021-02-08 13:14:47 PST
EWS
Comment 15 2021-02-08 13:47:00 PST
Committed r272547: <https://commits.webkit.org/r272547> All reviewed patches have been landed. Closing bug and clearing flags on attachment 419618 [details].
Eric Carlson
Comment 16 2021-02-08 17:17:05 PST
Reopening to attach new patch.
Eric Carlson
Comment 17 2021-02-08 17:17:07 PST
EWS
Comment 18 2021-02-08 17:47:09 PST
Committed r272563: <https://commits.webkit.org/r272563> All reviewed patches have been landed. Closing bug and clearing flags on attachment 419657 [details].
Eric Carlson
Comment 19 2021-02-09 08:19:51 PST
Reopening to attach new patch.
Eric Carlson
Comment 20 2021-02-09 08:19:53 PST
EWS
Comment 21 2021-02-09 08:21:09 PST
/Volumes/Data/worker/Commit-Queue/build/Source/WebCore/ChangeLog neither lists a valid reviewer nor contains the string "Unreviewed" or "Rubber stamp" (case insensitive).
Eric Carlson
Comment 22 2021-02-09 08:29:30 PST
EWS
Comment 23 2021-02-09 09:20:46 PST
commit-queue failed to commit attachment 419719 [details] to WebKit repository. To retry, please set cq+ flag again.
EWS
Comment 24 2021-02-09 10:33:31 PST
Committed r272589: <https://commits.webkit.org/r272589> All reviewed patches have been landed. Closing bug and clearing flags on attachment 419719 [details].
Alex Christensen
Comment 25 2021-02-09 14:51:15 PST
Note You need to log in before you can comment on or make changes to this bug.