Mark CanvasPath operations' parameters as mandatory when they should be
https://bugs.webkit.org/show_bug.cgi?id=161014
Reviewed by Sam Weinig.
LayoutTests/imported/w3c:
Rebaseline W3C test now that more checks are passing.
* web-platform-tests/html/dom/interfaces-expected.txt:
Source/WebCore:
Mark CanvasPath operations as mandatory when they should be:
- https://html.spec.whatwg.org/multipage/scripting.html#canvaspath
This patch moves the CanvasPath methods from CanvasRenderingContext2D
and Path2D to a new CanvasPath interface, to avoid duplication and
match the specification.
The parameters were correctly marked as mandatory in WebKit on
CanvasRenderingContext2D but not on Path2D.
Those parameters are correctly marked as mandatory in Chrome and Firefox.
No new tests, rebaselined existing test.
* CMakeLists.txt:
* DerivedSources.make:
* WebCore.xcodeproj/project.pbxproj:
* html/canvas/CanvasPath.cpp: Renamed from Source/WebCore/html/canvas/CanvasPathMethods.cpp.
(WebCore::CanvasPath::closePath):
(WebCore::CanvasPath::moveTo):
(WebCore::CanvasPath::lineTo):
(WebCore::CanvasPath::quadraticCurveTo):
(WebCore::CanvasPath::bezierCurveTo):
(WebCore::CanvasPath::arcTo):
(WebCore::normalizeAngles):
(WebCore::CanvasPath::arc):
(WebCore::CanvasPath::ellipse):
(WebCore::CanvasPath::rect):
* html/canvas/CanvasPath.h: Renamed from Source/WebCore/html/canvas/CanvasPathMethods.h.
(WebCore::CanvasPath::~CanvasPath):
(WebCore::CanvasPath::CanvasPath):
(WebCore::CanvasPath::hasInvertibleTransform):
* html/canvas/CanvasPath.idl: Added.
* html/canvas/CanvasRenderingContext2D.h:
* html/canvas/CanvasRenderingContext2D.idl:
* html/canvas/DOMPath.h:
* html/canvas/DOMPath.idl:
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@204669 268f45cc-cd09-0410-ab3c-d52691b4dbfc
13 files changed