Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: de9f264928a4dceb1b3c975d2c8a63fa15f4f422
      
https://github.com/WebKit/WebKit/commit/de9f264928a4dceb1b3c975d2c8a63fa15f4f422
  Author: Devin Rousso <[email protected]>
  Date:   2025-11-09 (Sun, 09 Nov 2025)

  Changed paths:
    M LayoutTests/inspector/console/console-screenshot.html
    M LayoutTests/inspector/worker/console-basic-subworker.html
    M LayoutTests/inspector/worker/console-basic.html
    A LayoutTests/inspector/worker/console-screenshot-expected.txt
    A LayoutTests/inspector/worker/console-screenshot.html
    M LayoutTests/inspector/worker/resources/worker-console.js
    M Source/WebCore/page/FrameConsoleClient.cpp
    M Source/WebCore/workers/WorkerConsoleClient.cpp

  Log Message:
  -----------
  Web Inspector: support console screenshots in a Worker
https://bugs.webkit.org/show_bug.cgi?id=243361
<rdar://problem/98223234>

Reviewed by Darin Adler.

This will be very useful for developers that are working with `Blob` inside a 
`Worker` and don't have an easy way of visualizing it (e.g. 
sending/transferring to the webpage for rendering via the DOM).

* Source/WebCore/workers/WorkerConsoleClient.cpp:
(WebCore::canvasRenderingContext): Added.
(WebCore::WorkerConsoleClient::screenshot):
Support `ImageData`, `ImageBitmap`, `OffscreenCanvas`, all the different types 
of `CanvasRenderingContext`, and valid base64 `data:` URL strings.

* LayoutTests/inspector/console/console-screenshot.html:
* LayoutTests/inspector/worker/console-basic.html:
* LayoutTests/inspector/worker/console-basic-subworker.html:
* LayoutTests/inspector/worker/console-screenshot.html: Added.
* LayoutTests/inspector/worker/console-screenshot-expected.txt: Added.
* LayoutTests/inspector/worker/resources/worker-console.js:
(onmessage):

* Source/WebCore/page/FrameConsoleClient.cpp:
(WebCore::FrameConsoleClient::screenshot):

Drive-by: add some comments to clarify what each argument means.
Canonical link: https://commits.webkit.org/302778@main



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

Reply via email to