Web Inspector: add instrumentation for ImageBitmapRenderingContext
authorwebkit@devinrousso.com <webkit@devinrousso.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 14 Dec 2017 00:57:35 +0000 (00:57 +0000)
committerwebkit@devinrousso.com <webkit@devinrousso.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 14 Dec 2017 00:57:35 +0000 (00:57 +0000)
commitb7ee1f9113430bd31c0904a6c4e7ba6596b18087
tree814a2b42cb46cd010e1249b4d24dfae9d81ce8e4
parentc28e48de026b308c7b0c413605229566da97f4c9
Web Inspector: add instrumentation for ImageBitmapRenderingContext
https://bugs.webkit.org/show_bug.cgi?id=180736

Reviewed by Joseph Pecoraro.

Source/JavaScriptCore:

* inspector/protocol/Canvas.json:
* inspector/scripts/codegen/generator.py:

Source/WebCore:

Tests: inspector/canvas/create-context-bitmaprenderer.html
       inspector/canvas/requestContent-bitmaprenderer.html
       inspector/canvas/resolveCanvasContext-bitmaprenderer.html

* CMakeLists.txt:
* Sources.txt:
* WebCore.xcodeproj/project.pbxproj:

* html/HTMLCanvasElement.cpp:
(WebCore::HTMLCanvasElement::getContext):
(WebCore::HTMLCanvasElement::createContextBitmapRenderer):
Support passing an optional settings dictionary when creating an ImageBitmapRenderingContext.

* inspector/agents/InspectorCanvasAgent.cpp:
(WebCore::InspectorCanvasAgent::requestContent):
(WebCore::contextAsScriptValue):

* bindings/js/CallTracerTypes.h:

* inspector/InspectorCanvas.h:
* inspector/InspectorCanvas.cpp:
(WebCore::InspectorCanvas::buildObjectForCanvas):
(WebCore::InspectorCanvas::indexForData):
(WebCore::InspectorCanvas::buildAction):
(WebCore::InspectorCanvas::buildArrayForImageBitmap): Deleted.

Source/WebInspectorUI:

* UserInterface/Base/ImageUtilities.js:
(WI.ImageUtilities.promisifyLoad):
(WI.ImageUtilities.imageFromImageBitmap):

* UserInterface/Models/Canvas.js:
(WI.Canvas.fromPayload):
(WI.Canvas.displayNameForContextType):

* UserInterface/Models/NativeFunctionParameters.js:

* UserInterface/Models/Recording.js:
(WI.Recording.displayNameForSwizzleType):
(WI.Recording.prototype.async swizzle):

* UserInterface/Views/RecordingActionTreeElement.js:
(WI.RecordingActionTreeElement._generateDOM):
(WI.RecordingActionTreeElement._generateDOM.createParameterElement):

LayoutTests:

* inspector/canvas/context-attributes-expected.txt:
* inspector/canvas/context-attributes.html:
* inspector/canvas/create-context-bitmaprenderer-expected.txt: Added.
* inspector/canvas/create-context-bitmaprenderer.html: Added.
* inspector/canvas/recording-2d-expected.txt:
* inspector/canvas/recording-2d.html:
* inspector/canvas/requestContent-bitmaprenderer-expected.txt: Added.
* inspector/canvas/requestContent-bitmaprenderer.html: Added.
* inspector/canvas/resolveCanvasContext-bitmaprenderer-expected.txt: Added.
* inspector/canvas/resolveCanvasContext-bitmaprenderer.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@225884 268f45cc-cd09-0410-ab3c-d52691b4dbfc
29 files changed:
LayoutTests/ChangeLog
LayoutTests/inspector/canvas/context-attributes-expected.txt
LayoutTests/inspector/canvas/context-attributes.html
LayoutTests/inspector/canvas/create-context-bitmaprenderer-expected.txt [new file with mode: 0644]
LayoutTests/inspector/canvas/create-context-bitmaprenderer.html [new file with mode: 0644]
LayoutTests/inspector/canvas/recording-2d-expected.txt
LayoutTests/inspector/canvas/recording-2d.html
LayoutTests/inspector/canvas/requestContent-bitmaprenderer-expected.txt [new file with mode: 0644]
LayoutTests/inspector/canvas/requestContent-bitmaprenderer.html [new file with mode: 0644]
LayoutTests/inspector/canvas/resolveCanvasContext-bitmaprenderer-expected.txt [new file with mode: 0644]
LayoutTests/inspector/canvas/resolveCanvasContext-bitmaprenderer.html [new file with mode: 0644]
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/inspector/protocol/Canvas.json
Source/JavaScriptCore/inspector/scripts/codegen/generator.py
Source/WebCore/CMakeLists.txt
Source/WebCore/ChangeLog
Source/WebCore/Sources.txt
Source/WebCore/WebCore.xcodeproj/project.pbxproj
Source/WebCore/bindings/js/CallTracerTypes.h
Source/WebCore/html/HTMLCanvasElement.cpp
Source/WebCore/inspector/InspectorCanvas.cpp
Source/WebCore/inspector/InspectorCanvas.h
Source/WebCore/inspector/agents/InspectorCanvasAgent.cpp
Source/WebInspectorUI/ChangeLog
Source/WebInspectorUI/UserInterface/Base/ImageUtilities.js
Source/WebInspectorUI/UserInterface/Models/Canvas.js
Source/WebInspectorUI/UserInterface/Models/NativeFunctionParameters.js
Source/WebInspectorUI/UserInterface/Models/Recording.js
Source/WebInspectorUI/UserInterface/Views/RecordingActionTreeElement.js