Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WebGPU] Add typedef for performWithMediaPlayerOnMainThread #13943

Conversation

mwyrzykowski
Copy link
Contributor

@mwyrzykowski mwyrzykowski commented May 16, 2023

b2fbc85

[WebGPU] Add typedef for performWithMediaPlayerOnMainThread
https://bugs.webkit.org/show_bug.cgi?id=256866
<radar://109429790>

Reviewed by Myles C. Maxfield.

Make this easier to read with a typedef.

* Source/WebKit/GPUProcess/graphics/WebGPU/RemoteAdapter.cpp:
(WebKit::RemoteAdapter::RemoteAdapter):
* Source/WebKit/GPUProcess/graphics/WebGPU/RemoteAdapter.h:
* Source/WebKit/GPUProcess/graphics/WebGPU/RemoteDevice.cpp:
(WebKit::RemoteDevice::RemoteDevice):
* Source/WebKit/GPUProcess/graphics/WebGPU/RemoteDevice.h:
* Source/WebKit/GPUProcess/graphics/WebGPU/RemoteGPU.cpp:
(WebKit::RemoteGPU::RemoteGPU):
* Source/WebKit/GPUProcess/graphics/WebGPU/RemoteGPU.h:

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

09519cd

Misc iOS, tvOS & watchOS macOS Linux Windows
βœ… πŸ§ͺ style βœ… πŸ›  ios βœ… πŸ›  mac βœ… πŸ›  wpe βœ… πŸ›  wincairo
βœ… πŸ›  ios-sim βœ… πŸ›  mac-AS-debug   πŸ§ͺ wpe-wk2
βœ… πŸ§ͺ webkitperl βœ… πŸ§ͺ ios-wk2 βœ… πŸ§ͺ api-mac βœ… πŸ›  gtk
  πŸ§ͺ ios-wk2-wpt   πŸ§ͺ gtk-wk2
  πŸ§ͺ api-ios βœ… πŸ§ͺ mac-wk2 βœ… πŸ§ͺ api-gtk
βœ… πŸ›  tv   πŸ§ͺ mac-AS-debug-wk2
βœ… πŸ›  tv-sim
βœ… πŸ›  πŸ§ͺ merge βœ… πŸ›  watch
βœ… πŸ›  watch-sim

@mwyrzykowski mwyrzykowski self-assigned this May 16, 2023
@mwyrzykowski mwyrzykowski changed the title ??? [WebGPU] Add typedef for performWithMediaPlayerOnMainThread May 16, 2023
@mwyrzykowski mwyrzykowski added the WebGPU For bugs in WebGPU label May 16, 2023
@webkit-ews-buildbot webkit-ews-buildbot added the merging-blocked Applied to prevent a change from being merged label May 16, 2023
@@ -63,10 +63,12 @@ class ObjectHeap;
struct RequestAdapterOptions;
}

typedef Function<void(WebCore::MediaPlayerIdentifier, Function<void(WebCore::MediaPlayer&)>&&)> PerformWithMediaPlayerOnMainThread;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we generally prefer using PerformWithMediaPlayerOnMainThread = Function<void(WebCore::MediaPlayerIdentifier, Function<void(WebCore::MediaPlayer&)>&&)> rather than typedef

Also, can we break this into two lines?

using MediaPlayerAccessor = Function<void(WebCore::MediaPlayer&)>;
using PerformWithMediaPlayerOnMainThread = Function<void(WebCore::MediaPlayerIdentifier, MediaPlayerAccessor&&)>;

@mwyrzykowski mwyrzykowski removed the merging-blocked Applied to prevent a change from being merged label May 16, 2023
@mwyrzykowski mwyrzykowski force-pushed the eng/WebGPU-Add-typedef-for-performWithMediaPlayerOnMainThread branch from 8c1bcfc to 09519cd Compare May 16, 2023 23:48
@mwyrzykowski mwyrzykowski added the merge-queue Applied to send a pull request to merge-queue label May 17, 2023
https://bugs.webkit.org/show_bug.cgi?id=256866
<radar://109429790>

Reviewed by Myles C. Maxfield.

Make this easier to read with a typedef.

* Source/WebKit/GPUProcess/graphics/WebGPU/RemoteAdapter.cpp:
(WebKit::RemoteAdapter::RemoteAdapter):
* Source/WebKit/GPUProcess/graphics/WebGPU/RemoteAdapter.h:
* Source/WebKit/GPUProcess/graphics/WebGPU/RemoteDevice.cpp:
(WebKit::RemoteDevice::RemoteDevice):
* Source/WebKit/GPUProcess/graphics/WebGPU/RemoteDevice.h:
* Source/WebKit/GPUProcess/graphics/WebGPU/RemoteGPU.cpp:
(WebKit::RemoteGPU::RemoteGPU):
* Source/WebKit/GPUProcess/graphics/WebGPU/RemoteGPU.h:

Canonical link: https://commits.webkit.org/264131@main
@webkit-commit-queue webkit-commit-queue force-pushed the eng/WebGPU-Add-typedef-for-performWithMediaPlayerOnMainThread branch from 09519cd to b2fbc85 Compare May 17, 2023 00:50
@webkit-commit-queue
Copy link
Collaborator

Committed 264131@main (b2fbc85): https://commits.webkit.org/264131@main

Reviewed commits have been landed. Closing PR #13943 and removing active labels.

@webkit-commit-queue webkit-commit-queue merged commit b2fbc85 into WebKit:main May 17, 2023
@webkit-commit-queue webkit-commit-queue removed the merge-queue Applied to send a pull request to merge-queue label May 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
WebGPU For bugs in WebGPU
Projects
None yet
5 participants