c25de08bd4d72d9545b46217441ff82630a23b35
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2019-04-01  Timothy Hatcher  <timothy@apple.com>
2
3         Unreviewed build fix.
4
5         * crypto/mac/SerializedCryptoKeyWrapMac.mm:
6         (WebCore::createAndStoreMasterKey): Add ALLOW_DEPRECATED_DECLARATIONS_BEGIN/END
7         around SecTrustedApplicationCreateFromPath call.
8
9 2019-04-01  Simon Fraser  <simon.fraser@apple.com>
10
11         Remove some unused iOS scrolling-related code in Frame
12         https://bugs.webkit.org/show_bug.cgi?id=196473
13
14         Reviewed by Zalan Bujtas.
15
16         This code has no callers.
17
18         * page/Frame.cpp:
19         (WebCore::Frame::Frame):
20         (WebCore::Frame::scrollOverflowLayer): Deleted.
21         (WebCore::Frame::overflowAutoScrollTimerFired): Deleted.
22         (WebCore::Frame::startOverflowAutoScroll): Deleted.
23         (WebCore::Frame::checkOverflowScroll): Deleted.
24         * page/Frame.h:
25
26 2019-04-01  Chris Dumez  <cdumez@apple.com>
27
28         Attr nodes are not cloned properly
29         https://bugs.webkit.org/show_bug.cgi?id=196466
30
31         Reviewed by Ryosuke Niwa.
32
33         Attr nodes are not cloned properly according to:
34         - https://dom.spec.whatwg.org/#concept-node-clone
35
36         A cloned Attr node should retain its prefix and namespace.
37
38         Both Gecko and Blink agree with the DOM specification here.
39
40         No new tests, rebaselined existing test.
41
42         * dom/Document.cpp:
43         (WebCore::Document::importNode):
44
45 2019-04-01  Said Abou-Hallawa  <sabouhallawa@apple.com>
46
47         Remove the SVG tear off objects for SVGMatrix, SVGTransfrom, SVGTransformList and SVGAnimatedTransformList
48         https://bugs.webkit.org/show_bug.cgi?id=196086
49
50         Reviewed by Simon Fraser.
51
52         The IDL changes:
53
54         SVGTransform.idl:
55             Remove the NewObject qualifier from matrix attribute. This matches 
56             the specs: https://www.w3.org/TR/SVG11/coords.html#InterfaceSVGTransform.
57             SVGTransform will internally hold an SVGMatrix. A change in this
58             SVGMatrix will affect the container SVGTransform.
59
60         SVGTransformList.idl:
61             Remove the NewObject qualifier from consolidate() method. This matches
62             the specs:
63             https://www.w3.org/TR/SVG11/coords.html#__svg__SVGTransformList__consolidate
64             The method consolidate() should return a reference to the first item
65             in the list after consolidating it.
66
67         Code changes:
68
69         -- SVGMatrix is now a superclass of SVGValueProperty<AffineTransform>.
70            No need for SVGMatrixValue since it was wrapper of AffineTransform.
71
72         -- SVGTransformValue now holds a Ref<SVGMatrix> member in addition to the
73            angle and the rotationCenter. Ref<SVGMatrix> is what SVGTransform.matrix
74            will return. So a change in this matrix will change the owner SVGTransform.
75
76         -- SVGTransform is now the owner of SVGMatrix via its SVGTransformValue.
77
78         -- SVGTransformList is now a superclass of SVGValuePropertyList<SVGTransform>.
79            It is responsible for parsing a String to items of SVGTransform.
80
81         -- SVGAnimatedTransformList is now defined as SVGAnimatedPropertyList<
82            SVGTransformList>.
83
84         Note the ownership chain of these objects is the following:
85
86         -- SVGAnimatedTransformList owns the SVGTransformList via its baseVal 
87            and animVal members.
88
89         -- SVGTransformList owns SVGTransform via its list of items
90
91         -- SVGTransform owns SVGMatrix via its SVGTransformValue.
92
93            So a change in SVGMatrix will propagate to the owner SVGElement through
94            the following ownership chain:
95
96            SVGMatrix
97              |_ SVGTransfrom
98                   |_ SVGTransformList
99                        |_ SVGAmimatedTransformList
100                             |_ SVGElement
101
102         To get the mechanics of this change right, a new accessor, a new animator
103         and animation functions are added for the SVGAnimatedTransformList.
104
105         -- SVGViewSpec used to hold an SVGAnimatedTransformListAttribute for the
106         member m_transform although this member should not be animated. See the
107         comment in the old SVGViewSpec::transform(). This has been changed in this
108         patch. SVGViewSpec now holds Ref<SVGTransformList> which matches the specs:
109         https://www.w3.org/TR/SVG11/types.html#InterfaceSVGViewSpec.
110
111         * Sources.txt:
112         * WebCore.xcodeproj/project.pbxproj:
113         * svg/SVGAnimateElementBase.cpp:
114         (WebCore::SVGAnimateElementBase::attributeAnimationController):
115         (WebCore::SVGAnimateElementBase::hasValidAttributeType const):
116         (WebCore::SVGAnimateElementBase::calculateToAtEndOfDurationValue):
117         (WebCore::SVGAnimateElementBase::calculateFromAndToValues):
118         (WebCore::SVGAnimateElementBase::calculateFromAndByValues):
119         * svg/SVGAnimateElementBase.h:
120         (WebCore::SVGAnimateElementBase::animateRangeString const):
121         * svg/SVGAnimateTransformElement.cpp:
122         (WebCore::SVGAnimateTransformElement::animateRangeString const):
123         * svg/SVGAnimateTransformElement.h:
124                 This change is needed because animating the transform attribute can be
125         written as
126             <animate ... from="translate(100)" to="translate(200)"/>
127         or
128             <animateTransform type="translate" from="100" to="200"/>"
129         So we need to surround the animation range string with the type qualifier
130         for animateTransform.
131
132         * svg/SVGAnimatedTransformList.cpp: Removed.
133         * svg/SVGAnimatedTransformList.h: Removed.
134         * svg/SVGAnimatedType.h: Removed.
135         * svg/SVGAnimatedTypeAnimator.cpp: Removed.
136         * svg/SVGAnimatedTypeAnimator.h: Removed.
137         * svg/SVGAnimationElement.cpp:
138         (WebCore::SVGAnimationElement::adjustForInheritance): Deleted.
139         * svg/SVGAnimationElement.h:
140         (WebCore::SVGAnimationElement::adjustForInheritance): Deleted.
141         (WebCore::SVGAnimationElement::adjustFromToListValues): Deleted.
142         (WebCore::SVGAnimationElement::animateDiscreteType): Deleted.
143         These functions were used by SVGLegacyAttributeAnimationController.
144
145         * svg/SVGAnimatorFactory.h: Removed.
146         * svg/SVGExternalResourcesRequired.h:
147         (WebCore::SVGExternalResourcesRequired::isKnownAttribute):
148         * svg/SVGFEImageElement.h:
149         * svg/SVGFEMorphologyElement.h:
150         * svg/SVGFETileElement.h:
151         * svg/SVGFitToViewBox.h:
152         (WebCore::SVGFitToViewBox::isKnownAttribute):
153         * svg/SVGGradientElement.cpp:
154         (WebCore::SVGGradientElement::SVGGradientElement):
155         (WebCore::SVGGradientElement::parseAttribute):
156         (WebCore::SVGGradientElement::registerAttributes): Deleted.
157         * svg/SVGGradientElement.h:
158         (WebCore::SVGGradientElement::gradientTransform const):
159         (WebCore::SVGGradientElement::gradientTransformAnimated):
160         (WebCore::SVGGradientElement::isKnownAttribute):
161         * svg/SVGGraphicsElement.cpp:
162         (WebCore::SVGGraphicsElement::SVGGraphicsElement):
163         (WebCore::SVGGraphicsElement::animatedLocalTransform const):
164         (WebCore::SVGGraphicsElement::parseAttribute):
165         (WebCore::SVGGraphicsElement::svgAttributeChanged):
166         There is one attribute for this element which is "SVGNames::transformAttr"
167         So there is no need to check for it twice.
168
169         (WebCore::SVGGraphicsElement::registerAttributes): Deleted.
170         * svg/SVGGraphicsElement.h:
171         (WebCore::SVGGraphicsElement::transform const):
172         (WebCore::SVGGraphicsElement::transformAnimated):
173         (WebCore::SVGGraphicsElement::isKnownAttribute): Deleted.
174         * svg/SVGLangSpace.cpp:
175         (WebCore::SVGLangSpace::SVGLangSpace):
176         (WebCore::SVGLangSpace::xmlspace const):
177         (WebCore::SVGLangSpace::isKnownAttribute):
178         (WebCore::SVGLangSpace::svgAttributeChanged):
179         (WebCore::SVGLangSpace::registerAttributes): Deleted.
180         * svg/SVGLangSpace.h:
181         (WebCore::SVGLangSpace::xmllang const):
182         (WebCore::SVGLangSpace::setXmllang):
183         (WebCore::SVGLangSpace::setXmlspace):
184         (WebCore::SVGLangSpace::attributeRegistry): Deleted.
185         (WebCore::SVGLangSpace::isKnownAttribute): Deleted.
186         * svg/SVGLegacyAttributeAnimationController.cpp: Removed.
187         * svg/SVGLegacyAttributeAnimationController.h: Removed.
188         * svg/SVGLinearGradientElement.cpp:
189         (WebCore::setGradientAttributes):
190         * svg/SVGMaskElement.h:
191         * svg/SVGMatrix.h:
192         (WebCore::SVGMatrix::create):
193         (WebCore::SVGMatrix::a const):
194         (WebCore::SVGMatrix::setA):
195         (WebCore::SVGMatrix::b const):
196         (WebCore::SVGMatrix::setB):
197         (WebCore::SVGMatrix::c const):
198         (WebCore::SVGMatrix::setC):
199         (WebCore::SVGMatrix::d const):
200         (WebCore::SVGMatrix::setD):
201         (WebCore::SVGMatrix::e const):
202         (WebCore::SVGMatrix::setE):
203         (WebCore::SVGMatrix::f const):
204         (WebCore::SVGMatrix::setF):
205         (WebCore::SVGMatrix::multiply const):
206         (WebCore::SVGMatrix::inverse const):
207         (WebCore::SVGMatrix::translate const):
208         (WebCore::SVGMatrix::scale const):
209         (WebCore::SVGMatrix::scaleNonUniform const):
210         (WebCore::SVGMatrix::rotate const):
211         (WebCore::SVGMatrix::rotateFromVector const):
212         (WebCore::SVGMatrix::flipX const):
213         (WebCore::SVGMatrix::flipY const):
214         (WebCore::SVGMatrix::skewX const):
215         (WebCore::SVGMatrix::skewY const):
216         * svg/SVGPatternElement.cpp:
217         (WebCore::SVGPatternElement::SVGPatternElement):
218         (WebCore::SVGPatternElement::parseAttribute):
219         (WebCore::SVGPatternElement::svgAttributeChanged):
220         (WebCore::SVGPatternElement::collectPatternAttributes const):
221         (WebCore::SVGPatternElement::localCoordinateSpaceTransform const):
222         (WebCore::SVGPatternElement::registerAttributes): Deleted.
223         * svg/SVGPatternElement.h:
224         * svg/SVGPoint.h:
225         (WebCore::SVGPoint::matrixTransform const):
226         * svg/SVGPolyElement.h:
227         (WebCore::SVGPolyElement::isKnownAttribute): Deleted.
228         * svg/SVGRadialGradientElement.cpp:
229         (WebCore::setGradientAttributes):
230         * svg/SVGSVGElement.cpp:
231         (WebCore::SVGSVGElement::createSVGTransform):
232         (WebCore::SVGSVGElement::createSVGTransformFromMatrix):
233         (WebCore::SVGSVGElement::viewBoxToViewTransform const):
234         * svg/SVGTextElement.cpp:
235         (WebCore::SVGTextElement::animatedLocalTransform const):
236         * svg/SVGTransform.cpp: Removed.
237         * svg/SVGTransform.h:
238         (WebCore::SVGTransform::create):
239         (WebCore::SVGTransform::~SVGTransform):
240         (WebCore::SVGTransform::clone const):
241         (WebCore::SVGTransform::type):
242         (WebCore::SVGTransform::angle):
243         (WebCore::SVGTransform::matrix):
244         (WebCore::SVGTransform::setMatrix):
245         (WebCore::SVGTransform::setTranslate):
246         (WebCore::SVGTransform::setScale):
247         (WebCore::SVGTransform::setRotate):
248         (WebCore::SVGTransform::setSkewX):
249         (WebCore::SVGTransform::setSkewY):
250         (WebCore::SVGTransform::SVGTransform):
251         * svg/SVGTransform.idl:
252         * svg/SVGTransformList.h:
253         * svg/SVGTransformList.idl:
254         * svg/SVGTransformListValues.cpp: Removed.
255         * svg/SVGTransformListValues.h: Removed.
256         * svg/SVGTransformValue.cpp: Removed.
257         * svg/SVGTransformValue.h:
258         (WebCore::SVGTransformValue::SVGTransformValue):
259         (WebCore::SVGTransformValue::operator=):
260         (WebCore::SVGTransformValue::matrix const):
261         (WebCore::SVGTransformValue::rotationCenter const):
262         (WebCore::SVGTransformValue::isValid const):
263         (WebCore::SVGTransformValue::setMatrix):
264         (WebCore::SVGTransformValue::matrixDidChange):
265         (WebCore::SVGTransformValue::translate const):
266         (WebCore::SVGTransformValue::setTranslate):
267         (WebCore::SVGTransformValue::scale const):
268         (WebCore::SVGTransformValue::setScale):
269         (WebCore::SVGTransformValue::setRotate):
270         (WebCore::SVGTransformValue::setSkewX):
271         (WebCore::SVGTransformValue::setSkewY):
272         (WebCore::SVGTransformValue::valueAsString const):
273         (WebCore::SVGTransformValue::prefixForTransfromType):
274         (WebCore::SVGTransformValue::appendNumbers const):
275         (WebCore::SVGTransformValue::appendMatrix const):
276         (WebCore::SVGTransformValue::appendTranslate const):
277         (WebCore::SVGTransformValue::appendScale const):
278         (WebCore::SVGTransformValue::appendRotate const):
279         (WebCore::SVGTransformValue::appendSkewX const):
280         (WebCore::SVGTransformValue::appendSkewY const):
281         (WebCore::SVGTransformValue::matrix): Deleted.
282         * svg/SVGTransformable.cpp:
283         (WebCore::SVGTransformable::parseAndSkipType):
284         (WebCore::parseAndSkipType): Deleted.
285         (WebCore::SVGTransformable::parseTransformAttribute): Deleted.
286         The code of this function was moved to SVGTransformList::parse().
287
288         * svg/SVGTransformable.h:
289         There is no need for enum TransformParsingMode. It was used by 
290         SVGViewSpec::parseViewSpec() to tell SVGTransformable::parseTransformAttribute()
291         not to clear the list. SVGTransfromList now has two parse() functions:
292         one public and the second is private. The public one clear the list
293         before parsing the input String. The private one just does the parsing.
294         SVGViewSpec::parseViewSpec() calls the private once since it is a friend
295         of SVGTransfromList.
296
297         * svg/SVGValue.h: Removed.
298         * svg/SVGViewSpec.cpp:
299         (WebCore::SVGViewSpec::SVGViewSpec):
300         (WebCore::SVGViewSpec::reset):
301         (WebCore::SVGViewSpec::parseViewSpec):
302         (WebCore::SVGViewSpec::registerAttributes): Deleted.
303         (WebCore::SVGViewSpec::transform): Deleted.
304         * svg/SVGViewSpec.h:
305         * svg/properties/SVGAnimatedPropertyAccessorImpl.h:
306         * svg/properties/SVGAnimatedPropertyAnimatorImpl.h:
307         * svg/properties/SVGAnimatedPropertyImpl.h:
308         * svg/properties/SVGAnimatedTransformListPropertyTearOff.h: Removed.
309         * svg/properties/SVGAnimationAdditiveListFunctionImpl.h:
310         (WebCore::SVGAnimationTransformListFunction::progress):
311         * svg/properties/SVGAnimationAdditiveValueFunctionImpl.h:
312         * svg/properties/SVGAttributeRegistry.h:
313         * svg/properties/SVGMatrixTearOff.h: Removed.
314         * svg/properties/SVGPropertyAccessorImpl.h:
315         * svg/properties/SVGPropertyOwnerRegistry.h:
316         (WebCore::SVGPropertyOwnerRegistry::registerProperty):
317
318 2019-04-01  Devin Rousso  <drousso@apple.com>
319
320         Web Inspector: DOMDebugger: breakpoints for attribute modifications still fire when breakpoints are disabled
321         https://bugs.webkit.org/show_bug.cgi?id=196456
322         <rdar://problem/49489747>
323
324         Reviewed by Joseph Pecoraro.
325
326         Test: inspector/dom-debugger/dom-breakpoints.html
327
328         * inspector/agents/InspectorDOMDebuggerAgent.cpp:
329         (WebCore::InspectorDOMDebuggerAgent::didInvalidateStyleAttr):
330         (WebCore::InspectorDOMDebuggerAgent::descriptionForDOMEvent):
331
332 2019-04-01  Wenson Hsieh  <wenson_hsieh@apple.com>
333
334         Unable to copy and paste a PDF from Notes into Mail compose body
335         https://bugs.webkit.org/show_bug.cgi?id=196442
336         <rdar://problem/48573098>
337
338         Reviewed by Tim Horton.
339
340         Refactor some logic for inserting attachment elements upon paste or drop. Currently, we only prefer inserting
341         content as attachment elements if the items are annotated with UIPreferredPresentationStyleAttachment. However,
342         many data sources around the system (both first and third party) have not adopted this API, which makes it
343         difficult to determine whether a given item provider should be treated as a file or not. In this bug in
344         particular, no preferred presentation style is set, so we fail to handle the paste command by inserting an
345         attachment element.
346
347         However, most apps around the system that write file or attachment-like data to the pasteboard will at least
348         offer a suggested name for the file, in the form of -[NSItemProvider suggestedName]. To address this, instead of
349         relying solely on the preferredPresentationStyle, additionally take a suggested name as an indicator that the
350         item is probably a file.
351
352         In fact, Pasteboard::fileContentState already has similar logic to check for either a suggested file name or
353         explicitly specified presentation style. We pull this out into a separate helper method on PasteboardItemInfo,
354         and use it for both Pasteboard::fileContentState and prefersAttachmentRepresentation.
355
356         Tests:  WKAttachmentTestsIOS.InsertPastedContactAsAttachment
357                 WKAttachmentTestsIOS.InsertPastedMapItemAsAttachment
358
359         * editing/cocoa/WebContentReaderCocoa.mm:
360         (WebCore::mimeTypeFromContentType):
361
362         Work around <rdar://problem/49478229> by using the "text/vcard" MIME type to handle "public.vcard". CoreServices
363         currently maps "public.vcard" to "text/directory" when using UTTypeCopyPreferredTagWithClass, despite the SPI
364         -[NSURLFileTypeMappings MIMETypeForExtension:] returning "text/vcard" for a ".vcf" file.
365
366         * platform/PasteboardItemInfo.h:
367         (WebCore::PasteboardItemInfo::canBeTreatedAsAttachmentOrFile const):
368
369         Add a helper method to determine whether the PasteboardItemInfo prefers to be represented as inline data, or an
370         attachment, or neither. This differs slightly from the existing value of preferredPresentationStyle in that we
371         consider having a suggested file name as a strong indicator that the item should be treated as an attachment,
372         even if the presentation style is unspecified.
373
374         * platform/cocoa/PasteboardCocoa.mm:
375         (WebCore::Pasteboard::fileContentState):
376
377         Use PasteboardItemInfo::canBeTreatedAsAttachmentOrFile().
378
379         * platform/ios/PasteboardIOS.mm:
380         (WebCore::prefersAttachmentRepresentation):
381
382         Use PasteboardItemInfo::canBeTreatedAsAttachmentOrFile().
383
384 2019-04-01  Tim Horton  <timothy_horton@apple.com>
385
386         Make UIWKDocumentContext rects per-character instead of per-word
387         https://bugs.webkit.org/show_bug.cgi?id=196459
388
389         Reviewed by Wenson Hsieh.
390
391         No new tests; adjusted expected results of WebKit.DocumentEditingContext.
392
393         * editing/TextIterator.cpp:
394         (WebCore::CharacterIterator::CharacterIterator):
395         * editing/TextIterator.h:
396         (WebCore::CharacterIterator::atEnd const):
397         (WebCore::CharacterIterator::text const):
398         Add WEBCORE_EXPORT to some things.
399         Introduce a CharacterIterator constructor that takes Positions, like one that TextIterator has.
400         Move initializers to the header.
401
402 2019-04-01  Antti Koivisto  <antti@apple.com>
403
404         Update event region when toggling pointer-events:none
405         https://bugs.webkit.org/show_bug.cgi?id=195902
406         <rdar://problem/48988384>
407
408         Reviewed by Simon Fraser.
409
410         Test: fast/scrolling/ios/event-region-pointer-events.html
411
412         Normally paint invalidation requests compositing configuration update whenever anything that would
413         affect event region changes. However mutating 'pointer-events' property does not cause paint invalidation.
414
415         * rendering/RenderElement.cpp:
416         (WebCore::RenderElement::styleWillChange):
417
418         Request compositing update explicitly from the containing layer.
419
420         * rendering/RenderLayer.cpp:
421         (WebCore::RenderLayer::invalidateEventRegion):
422         * rendering/RenderLayer.h:
423
424 2019-04-01  Chris Dumez  <cdumez@apple.com>
425
426         Support "noreferrer" for window.open()
427         https://bugs.webkit.org/show_bug.cgi?id=194533
428
429         Reviewed by Geoffrey Garen.
430
431         Support "noreferrer" for window.open() as per:
432         - https://github.com/whatwg/html/pull/4331
433
434         Tests: imported/w3c/web-platform-tests/html/browsers/the-window-object/apis-for-creating-and-navigating-browsing-contexts-by-name/open-features-tokenization-noreferrer.html
435                http/wpt/html/browsers/the-window-object/window-open-noopener-webkit.html
436
437         * page/DOMWindow.cpp:
438         (WebCore::DOMWindow::createWindow):
439         * page/WindowFeatures.cpp:
440         (WebCore::setWindowFeature):
441         * page/WindowFeatures.h:
442
443 2019-04-01  Said Abou-Hallawa  <sabouhallawa@apple.com>
444
445         SVGMatrix.IDL methods do not conform to the specs
446         https://bugs.webkit.org/show_bug.cgi?id=196263
447
448         Reviewed by Simon Fraser.
449
450         I think there was a misconception about these functions. The specs link
451         is: https://www.w3.org/TR/SVG11/coords.html#InterfaceSVGMatrix.
452
453         Notice that the specs does not state that the SVGMethod methods should
454         raise the exception NO_MODIFICATION_ALLOWED_ERR if the object is read
455         only. Notice setting the attribute 'a' for example may raise this
456         exception. Therefore, I think the specs wanted to make these operations
457         read-only. None of the methods should raise the exception
458         NO_MODIFICATION_ALLOWED_ERR.
459
460         In fact the SVG code was doing the right thing. For example SVGMatrix::scale()
461         was calling SVGMatrixValue::scale() which was making a copy of itself,
462         applying the scale on the copy and then returning the copy. When 
463         SVGMatrix::scale() receives the copy of the SVGMatrixValue it creates and
464         returns a new SVGMatrix object.
465
466         * WebCore.xcodeproj/project.pbxproj:
467         * svg/SVGMatrix.h:
468         (WebCore::SVGMatrix::create):
469         (WebCore::SVGMatrix::a const):
470         (WebCore::SVGMatrix::b const):
471         (WebCore::SVGMatrix::c const):
472         (WebCore::SVGMatrix::d const):
473         (WebCore::SVGMatrix::e const):
474         (WebCore::SVGMatrix::f const):
475         (WebCore::SVGMatrix::multiply const):
476         (WebCore::SVGMatrix::inverse const):
477         (WebCore::SVGMatrix::translate const):
478         (WebCore::SVGMatrix::scale const):
479         (WebCore::SVGMatrix::scaleNonUniform const):
480         (WebCore::SVGMatrix::rotate const):
481         (WebCore::SVGMatrix::rotateFromVector const):
482         (WebCore::SVGMatrix::flipX const):
483         (WebCore::SVGMatrix::flipY const):
484         (WebCore::SVGMatrix::skewX const):
485         (WebCore::SVGMatrix::skewY const):
486         (WebCore::SVGMatrix::a): Deleted.
487         (WebCore::SVGMatrix::b): Deleted.
488         (WebCore::SVGMatrix::c): Deleted.
489         (WebCore::SVGMatrix::d): Deleted.
490         (WebCore::SVGMatrix::e): Deleted.
491         (WebCore::SVGMatrix::f): Deleted.
492         (WebCore::SVGMatrix::multiply): Deleted.
493         (WebCore::SVGMatrix::inverse): Deleted.
494         (WebCore::SVGMatrix::translate): Deleted.
495         (WebCore::SVGMatrix::scale): Deleted.
496         (WebCore::SVGMatrix::scaleNonUniform): Deleted.
497         (WebCore::SVGMatrix::rotate): Deleted.
498         (WebCore::SVGMatrix::rotateFromVector): Deleted.
499         (WebCore::SVGMatrix::flipX): Deleted.
500         (WebCore::SVGMatrix::flipY): Deleted.
501         (WebCore::SVGMatrix::skewX): Deleted.
502         (WebCore::SVGMatrix::skewY): Deleted.
503         (WebCore::SVGMatrix::SVGMatrix): Deleted.
504         * svg/SVGMatrix.idl:
505         * svg/SVGMatrixValue.h: Removed.
506         * svg/SVGTransform.cpp:
507         (WebCore::SVGTransform::matrix):
508         * svg/SVGTransformDistance.cpp:
509         (WebCore::SVGTransformDistance::addToSVGTransform const):
510         * svg/SVGTransformValue.h:
511         (WebCore::SVGTransformValue::matrix const):
512         (WebCore::SVGTransformValue::matrix):
513         (WebCore::SVGTransformValue::svgMatrix): Deleted.
514         (WebCore::operator==): Deleted.
515         (WebCore::operator!=): Deleted.
516         * svg/properties/SVGMatrixTearOff.h:
517         * svg/properties/SVGPropertyTearOff.h:
518         (WebCore::SVGPropertyTearOff::propertyReference const):
519
520 2019-04-01  Simon Fraser  <simon.fraser@apple.com>
521
522         Plumb through a ScrollType value that indicates whether a scroll was a user or programmatic scroll
523         https://bugs.webkit.org/show_bug.cgi?id=196424
524
525         Reviewed by Zalan Bujtas.
526
527         In preparation for fixing webkit.org/b/195584, we need to know if an overflow scroll
528         is programmatic, so plumb through an enum value. The functions touched by this patch are
529         only ever called for programmatic scrolls.
530
531         * dom/Element.cpp:
532         (WebCore::Element::scrollTo):
533         (WebCore::Element::setScrollLeft):
534         (WebCore::Element::setScrollTop):
535         * platform/ScrollTypes.h:
536         * rendering/RenderBox.cpp:
537         (WebCore::RenderBox::setScrollLeft):
538         (WebCore::RenderBox::setScrollTop):
539         * rendering/RenderBox.h:
540         * rendering/RenderLayer.cpp:
541         (WebCore::RenderLayer::scrollToXPosition):
542         (WebCore::RenderLayer::scrollToYPosition):
543         * rendering/RenderLayer.h:
544         * rendering/RenderListBox.cpp:
545         (WebCore::RenderListBox::setScrollLeft):
546         (WebCore::RenderListBox::setScrollTop):
547         * rendering/RenderListBox.h:
548         * rendering/RenderTextControlSingleLine.cpp:
549         (WebCore::RenderTextControlSingleLine::setScrollLeft):
550         (WebCore::RenderTextControlSingleLine::setScrollTop):
551         * rendering/RenderTextControlSingleLine.h:
552
553 2019-04-01  Wenson Hsieh  <wenson_hsieh@apple.com>
554
555         [iOS] Refactor some logic for inserting pasted or dropped virtual card files as attachment elements
556         https://bugs.webkit.org/show_bug.cgi?id=196435
557         Work towards <rdar://problem/48573098>
558
559         Reviewed by Darin Adler.
560
561         Refactor some existing codepaths on iOS for inserting VCard files as attachment elements. Instead of using a
562         separate readVirtualContactFile method for converting a vcard file or data into an attachment element (possibly
563         accompanied by a link), use the existing readFilePaths WebContentReader method.
564
565         To handle links which may accompany the attachment element, add a helper method in PasteboardIOS that reads a
566         titled URL prior to inserting an attachment element, in the case of pasting or dropping a VCF.
567
568         This means we no longer need to handle attachment reading in readPasteboardWebContentDataForType, so we can
569         simply bail before reading "public.vcard" here and defer to reading other data types.
570
571         Covered by existing API tests in WKAttachmentTests and DragAndDropTestsIOS.
572
573         * editing/WebContentReader.h:
574         * editing/cocoa/WebContentReaderCocoa.mm:
575         (WebCore::WebContentReader::readVirtualContactFile): Deleted.
576         * platform/Pasteboard.h:
577         * platform/ios/PasteboardIOS.mm:
578         (WebCore::Pasteboard::readPasteboardWebContentDataForType):
579         (WebCore::readURLAlongsideAttachmentIfNecessary):
580         (WebCore::prefersAttachmentRepresentation):
581         (WebCore::Pasteboard::read):
582         (WebCore::Pasteboard::readRespectingUTIFidelities):
583
584 2019-04-01  Antti Koivisto  <antti@apple.com>
585
586         Trying to scroll the compose pane on gmail.com scrolls the message list behind
587         https://bugs.webkit.org/show_bug.cgi?id=196426
588         <rdar://problem/49402667>
589
590         Reviewed by Darin Adler.
591
592         Test: fast/scrolling/ios/event-region-visibility-hidden.html
593
594         We fail to gather event region from desdendants of non-overflowing elements with 'visibility:hidden'.
595
596         * rendering/RenderBlock.cpp:
597         (WebCore::RenderBlock::paintObject):
598
599         Skip the subtree walk only if the current region covers the box already.
600
601         * rendering/RenderLayer.cpp:
602         (WebCore::RenderLayer::paintList):
603
604         Remove the (wrong) optimization, we bail out quickly on first renderer if possible so this is not high value.
605
606 2019-04-01  Emilio Cobos Álvarez  <emilio@crisal.io>
607
608         Be less strict about closing blocks in attribute and functional pseudo-element selectors.
609         https://bugs.webkit.org/show_bug.cgi?id=142167
610
611         Reviewed by Antti Koivisto.
612
613         This was also an issue for, e.g., "::slotted(foo", turns out.
614
615         This matches Chromium, Firefox, and the spec:
616
617         https://drafts.csswg.org/css-syntax/#parse-error:
618
619         > Certain points in the parsing algorithm are said to be parse errors. The error
620         > handling for parse errors is well-defined: user agents must either act as
621         > described below when encountering such problems, or must abort processing at
622         > the first error that they encounter for which they do not wish to apply the
623         > rules described below.
624
625         https://drafts.csswg.org/css-syntax/#consume-simple-block:
626
627         > <EOF-token>
628         >   This is a parse error. Return the block.
629
630         Tests: web-platform-tests/dom/nodes/selectors.js (and probably others)
631
632         * css/parser/CSSSelectorParser.cpp:
633         (WebCore::CSSSelectorParser::consumeAttribute):
634         (WebCore::CSSSelectorParser::consumePseudo):
635
636 2019-04-01  Pablo Saavedra  <psaavedra@igalia.com>
637
638         Build failure after r243644 in GTK Linux 64-bit stable builds
639         https://bugs.webkit.org/show_bug.cgi?id=196440
640
641         Reviewed by Philippe Normand.
642
643         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
644         (WebCore::MediaPlayerPrivateGStreamerBase::updateTextureMapperFlags):
645
646 2019-03-31  Manuel Rego Casasnovas  <rego@igalia.com>
647
648         Scroll position gets reset when overflow:scroll is inside grid
649         https://bugs.webkit.org/show_bug.cgi?id=196337
650         <rdar://problem/49385784>
651
652         Reviewed by Simon Fraser.
653
654         Fix scroll position when there are changes inside a grid item with "overflow: scroll".
655
656         Test: fast/css-grid-layout/grid-item-content-scroll-position.html
657
658         * rendering/RenderGrid.cpp:
659         (WebCore::RenderGrid::layoutBlock): Use beginUpdateScrollInfoAfterLayoutTransaction()
660         and endAndCommitUpdateScrollInfoAfterLayoutTransaction().
661
662 2019-03-31  Ryosuke Niwa  <rniwa@webkit.org>
663
664         Reduce the size of Node::deref by eliminating an explicit parentNode check
665         https://bugs.webkit.org/show_bug.cgi?id=195776
666
667         Reviewed by Darin Adler.
668
669         Address post-commit review comments.
670
671         * dom/Document.cpp:
672         (WebCore::Document::removedLastRef):
673         * dom/Node.cpp:
674         (WebCore::Node::~Node):
675         (WebCore::Node::removedLastRef):
676         * dom/Node.h:
677         (WebCore::Node::deref):
678         (WebCore::Node::setParentNode):
679
680 2019-03-31  Sam Weinig  <weinig@apple.com>
681
682         Remove more i386 specific configurations
683         https://bugs.webkit.org/show_bug.cgi?id=196430
684
685         Reviewed by Alexey Proskuryakov.
686
687         * Configurations/FeatureDefines.xcconfig:
688         ENABLE_WEB_AUTHN_macosx can now be enabled unconditionally on macOS.
689
690 2019-03-31  Andy Estes  <aestes@apple.com>
691
692         [iOS] WebKit should consult the navigation response policy delegate before previewing a QuickLook document
693         https://bugs.webkit.org/show_bug.cgi?id=196433
694         <rdar://problem/49293305>
695
696         Reviewed by Tim Horton.
697
698         When ResourceLoader would encounter a response with a MIME type that QuickLook supports, the
699         response would be implicitly allowed and a QuickLook preview would be generated. After
700         generating, the client's navigation response policy delegate would be notified of the
701         preview response, but not the underlying response. Notably, the preview response has a URL
702         scheme of "x-apple-ql-id", does not include any underlying HTTP headers, and usually has a
703         MIME type of "text/html" or "application/pdf" rather than the underlying response MIME type.
704
705         To allow clients to make better navigation response policy decisions, this patch changes the
706         above behavior for WKWebView clients that have linked against a version of WebKit that
707         includes this change. Rather than notifying the client's navigation response policy delegate
708         of the preview response, we notify the client of the underlying response. Only if the client
709         responds with a policy of "allow" will the QuickLook preview response be loaded (without
710         another call to the navigation response policy delegate).
711
712         Non-WKWebView clients and clients that have linked against a version of WebKit that does not
713         include this change will retain the original behavior.
714
715         Covered by existing layout tests and new and existing API tests.
716
717         * WebCore.xcodeproj/project.pbxproj:
718         * loader/SubresourceLoader.cpp:
719         (WebCore::SubresourceLoader::shouldCreatePreviewLoaderForResponse const):
720         (WebCore::SubresourceLoader::didReceiveResponse):
721         * loader/ios/PreviewLoader.h:
722         * loader/ios/PreviewLoader.mm:
723         (-[WebPreviewLoader initWithResourceLoader:resourceResponse:]):
724         (-[WebPreviewLoader _loadPreviewIfNeeded]):
725         (-[WebPreviewLoader connection:didReceiveData:lengthReceived:]):
726         (-[WebPreviewLoader connectionDidFinishLoading:]):
727         (-[WebPreviewLoader connection:didFailWithError:]):
728         (WebCore::PreviewLoader::create):
729         (WebCore::PreviewLoader::didReceiveResponse):
730         (-[WebPreviewLoader _sendDidReceiveResponseIfNecessary]): Deleted.
731         (WebCore::PreviewLoader::shouldCreateForMIMEType): Deleted.
732         * page/Settings.yaml:
733         * platform/MIMETypeRegistry.cpp:
734         (WebCore::MIMETypeRegistry::canShowMIMEType):
735         * platform/network/ios/PreviewConverter.h:
736         * platform/network/ios/PreviewConverter.mm:
737         (WebCore::PreviewConverter::supportsMIMEType):
738
739 2019-03-29  Dean Jackson  <dino@apple.com>
740
741         gl.readPixels with type gl.FLOAT does not work
742         https://bugs.webkit.org/show_bug.cgi?id=171432
743         <rdar://problem/31905150>
744
745         Reviewed by Antoine Quint.
746
747         Our validation code was identifying readPixels of
748         type FLOAT as invalid, for three reasons:
749         - we didn't support the FLOAT type at all.
750         - we only allowed the combination of RGBA and
751         UNSIGNED_BYTE in WebGL 1 [*].
752         - if we had a framebuffer of format RGBA, we assumed
753         we could only read into a Uint8 ArrayBuffer.
754
755         [*] This bug isn't completely fixed, so I opened
756         https://bugs.webkit.org/show_bug.cgi?id=196418
757
758         Test: fast/canvas/webgl/readPixels-float.html
759
760         * html/canvas/WebGLRenderingContextBase.cpp:
761         (WebCore::WebGLRenderingContextBase::readPixels):
762         - flip the logic in a conditional that was clearly wrong yet
763           thankfully had no impact.
764         - support type FLOAT when the relevant extension is enabled.
765         - allow FLOAT as a valid type (see new bug above)
766         - create a new macro for CHECK_COMPONENT_COUNT
767         - update the existing macros to not be case statements,
768           so that we can put logic in the switch.
769
770 2019-03-30  Antti Koivisto  <antti@apple.com>
771
772         Try to fix Windows build.
773
774         * platform/graphics/RoundedRect.cpp:
775         (WebCore::approximateAsRegion):
776
777 2019-03-30  Joseph Pecoraro  <pecoraro@apple.com>
778
779         Web Inspector: JSC Sampling Profiler thread not getting subtracted in CPU Usage Timeline
780         https://bugs.webkit.org/show_bug.cgi?id=196419
781         <rdar://problem/49444023>
782
783         Reviewed by Devin Rousso.
784
785         * page/ResourceUsageThread.cpp:
786         (WebCore::ResourceUsageThread::addObserver):
787         We forgot to call the function that would setup platform state
788         allowing us to subtract out the sampling profiler thread.
789
790 2019-03-30  Zalan Bujtas  <zalan@apple.com>
791
792         [ContentChangeObserver] Add iFrame elements to the list of "considered clickable" elements.
793         https://bugs.webkit.org/show_bug.cgi?id=196410
794         <rdar://problem/49436828>
795
796         Reviewed by Simon Fraser.
797
798         163.com constructs an iFrame to display the login pane on hover. This patch ensures that we take iFrames into account while observing for visible content change by considering iFrame elements "clickable".
799         (While iFrames don't necessarily have clickable content, we can't just sit and wait until they are fully loaded.)
800
801         Test: fast/events/touch/ios/content-observation/iframe-is-shown-on-hover.html
802
803         * page/ios/ContentChangeObserver.cpp:
804         (WebCore::ContentChangeObserver::StyleChangeScope::isConsideredClickable const):
805
806 2019-03-30  Antti Koivisto  <antti@apple.com>
807
808         Try to fix Windows build.
809
810         * platform/graphics/Region.cpp:
811         * platform/graphics/RoundedRect.cpp:
812
813 2019-03-30  Antti Koivisto  <antti@apple.com>
814
815         Hit-testing of boxes over scrollers should account for border-radius
816         https://bugs.webkit.org/show_bug.cgi?id=195374
817         <rdar://problem/48649993>
818
819         Reviewed by Simon Fraser.
820
821         Test: fast/scrolling/ios/border-radious-event-region.html
822
823         * page/Frame.h:
824         * platform/graphics/GraphicsLayer.cpp:
825         (WebCore::GraphicsLayer::dumpProperties const):
826
827         Testing support.
828
829         * platform/graphics/GraphicsLayerClient.h:
830         * platform/graphics/RoundedRect.cpp:
831         (WebCore::approximateAsRegion):
832
833         Add a function to approximate RoundedRects as Regions.
834         It cuts away rectangles from the corners following the corner shapes.
835         More rectangles are cut for larger radii.
836
837         * platform/graphics/RoundedRect.h:
838         * rendering/RenderBlock.cpp:
839         (WebCore::RenderBlock::paintObject):
840
841         Use the new interface to get rounded corners right.
842         In rectangle case this takes optimized paths.
843
844         * rendering/RenderLayerCompositor.cpp:
845         (WebCore::RenderLayerCompositor::layerTreeAsText):
846         * testing/Internals.cpp:
847         (WebCore::toLayerTreeFlags):
848         * testing/Internals.h:
849         * testing/Internals.idl:
850
851 2019-03-29  Zalan Bujtas  <zalan@apple.com>
852
853         [ContentChangeObserver] Expand DOM timer observation to 350ms
854         https://bugs.webkit.org/show_bug.cgi?id=196411
855         <rdar://problem/49391144>
856
857         Reviewed by Simon Fraser.
858
859         imdb.com main page has 350ms hover intent timer to bring up the hover menus around the search bar.
860
861         Test: fast/events/touch/ios/content-observation/350ms-hover-intent.html
862
863         * page/ios/ContentChangeObserver.cpp:
864
865 2019-03-29  John Wilander  <wilander@apple.com>
866
867         Move WebResourceLoadStatisticsStore IPC calls from the UI process to the network process
868         https://bugs.webkit.org/show_bug.cgi?id=196407
869         <rdar://problem/47859936>
870
871         Reviewed by Brent Fulgham.
872
873         Test: http/tests/storageAccess/grant-storage-access-under-opener-at-popup-user-gesture.html
874
875         This patch removes old code for the batching into "statistics updated" calls.
876         Since the move of Resource Load Statistics to the network process, all such
877         collection is done directly through dedicated calls to the network process.
878
879         The remaining functionality was renamed to make it more clear, i.e.
880         ResourceLoadObserver::notifyObserver() renamed to
881         ResourceLoadObserver::updateCentralStatisticsStore().
882
883         * loader/ResourceLoadObserver.cpp:
884         (WebCore::ResourceLoadObserver::setStatisticsUpdatedCallback):
885         (WebCore::ResourceLoadObserver::setRequestStorageAccessUnderOpenerCallback):
886         (WebCore::ResourceLoadObserver::logSubresourceLoading):
887         (WebCore::ResourceLoadObserver::logWebSocketLoading):
888         (WebCore::ResourceLoadObserver::logUserInteractionWithReducedTimeResolution):
889         (WebCore::ResourceLoadObserver::requestStorageAccessUnderOpener):
890         (WebCore::ResourceLoadObserver::updateCentralStatisticsStore):
891         (WebCore::ResourceLoadObserver::clearState):
892         (WebCore::ResourceLoadObserver::setNotificationCallback): Deleted.
893         (WebCore::ResourceLoadObserver::ResourceLoadObserver): Deleted.
894         (WebCore::ResourceLoadObserver::scheduleNotificationIfNeeded): Deleted.
895         (WebCore::ResourceLoadObserver::notifyObserver): Deleted.
896         * loader/ResourceLoadObserver.h:
897         * testing/Internals.cpp:
898         (WebCore::Internals::notifyResourceLoadObserver):
899
900 2019-03-29  Chris Dumez  <cdumez@apple.com>
901
902         Make someWindow.frames, .self, .window always return someWindow
903         https://bugs.webkit.org/show_bug.cgi?id=195406
904
905         Reviewed by Alex Christensen.
906
907         Make someWindow.frames, .self, .window always return someWindow. Previously, they
908         would return null when the window would lose its browsing context.
909
910         This aligns our behavior with Firefox and the HTML specification:
911         - https://github.com/whatwg/html/pull/4410
912
913         Chrome has also recently aligned with Firefox and the HTML specification here so
914         it makes sense for WebKit to follow.
915
916         No new tests, rebaselined existing tests.
917
918         * bindings/js/JSDOMWindowCustom.cpp:
919         (WebCore::JSDOMWindow::self const):
920         (WebCore::JSDOMWindow::window const):
921         (WebCore::JSDOMWindow::frames const):
922         * page/DOMWindow.cpp:
923         (WebCore::DOMWindow::focus):
924         * page/DOMWindow.h:
925         * page/DOMWindow.idl:
926
927 2019-03-29  Myles C. Maxfield  <mmaxfield@apple.com>
928
929         Delete WebMetal implementation in favor of WebGPU
930         https://bugs.webkit.org/show_bug.cgi?id=195418
931
932         Reviewed by Dean Jackson.
933
934         WebMetal was only ever intended to be a proof-of-concept, and was never intended to be shipped.
935         Now that our WebGPU implementation is achieving good functionality, we're hitting conflicts
936         because we have both implementations. We should delete the non-standard implementation in favor
937         of the standards-based implementation.
938
939         Deletes relevant tests.
940
941         * CMakeLists.txt:
942         * Configurations/FeatureDefines.xcconfig:
943         * DerivedSources-input.xcfilelist:
944         * DerivedSources-output.xcfilelist:
945         * DerivedSources.make:
946         * Sources.txt:
947         * SourcesCocoa.txt:
948         * WebCore.xcodeproj/project.pbxproj:
949         * bindings/js/JSWebMetalRenderPassAttachmentDescriptorCustom.cpp: Removed.
950         * bindings/js/JSWebMetalRenderingContextCustom.cpp: Removed.
951         * bindings/js/WebCoreBuiltinNames.h:
952         * dom/Document.cpp:
953         (WebCore::Document::getCSSCanvasContext):
954         * dom/Document.h:
955         * dom/Document.idl:
956         * html/HTMLCanvasElement.cpp:
957         (WebCore::HTMLCanvasElement::getContext):
958         (WebCore::HTMLCanvasElement::isWebMetalType): Deleted.
959         (WebCore::HTMLCanvasElement::createContextWebMetal): Deleted.
960         (WebCore::HTMLCanvasElement::getContextWebMetal): Deleted.
961         * html/HTMLCanvasElement.h:
962         * html/HTMLCanvasElement.idl:
963         * html/canvas/CanvasRenderingContext.h:
964         (WebCore::CanvasRenderingContext::isWebGPU const):
965         (WebCore::CanvasRenderingContext::isWebMetal const): Deleted.
966         * html/canvas/WebMetalBuffer.cpp: Removed.
967         * html/canvas/WebMetalBuffer.h: Removed.
968         * html/canvas/WebMetalBuffer.idl: Removed.
969         * html/canvas/WebMetalCommandBuffer.cpp: Removed.
970         * html/canvas/WebMetalCommandBuffer.h: Removed.
971         * html/canvas/WebMetalCommandBuffer.idl: Removed.
972         * html/canvas/WebMetalCommandQueue.cpp: Removed.
973         * html/canvas/WebMetalCommandQueue.h: Removed.
974         * html/canvas/WebMetalCommandQueue.idl: Removed.
975         * html/canvas/WebMetalComputeCommandEncoder.cpp: Removed.
976         * html/canvas/WebMetalComputeCommandEncoder.h: Removed.
977         * html/canvas/WebMetalComputeCommandEncoder.idl: Removed.
978         * html/canvas/WebMetalComputePipelineState.cpp: Removed.
979         * html/canvas/WebMetalComputePipelineState.h: Removed.
980         * html/canvas/WebMetalComputePipelineState.idl: Removed.
981         * html/canvas/WebMetalDepthStencilDescriptor.cpp: Removed.
982         * html/canvas/WebMetalDepthStencilDescriptor.h: Removed.
983         * html/canvas/WebMetalDepthStencilDescriptor.idl: Removed.
984         * html/canvas/WebMetalDepthStencilState.cpp: Removed.
985         * html/canvas/WebMetalDepthStencilState.h: Removed.
986         * html/canvas/WebMetalDepthStencilState.idl: Removed.
987         * html/canvas/WebMetalDrawable.cpp: Removed.
988         * html/canvas/WebMetalDrawable.h: Removed.
989         * html/canvas/WebMetalDrawable.idl: Removed.
990         * html/canvas/WebMetalEnums.cpp: Removed.
991         * html/canvas/WebMetalEnums.h: Removed.
992         * html/canvas/WebMetalEnums.idl: Removed.
993         * html/canvas/WebMetalFunction.cpp: Removed.
994         * html/canvas/WebMetalFunction.h: Removed.
995         * html/canvas/WebMetalFunction.idl: Removed.
996         * html/canvas/WebMetalLibrary.cpp: Removed.
997         * html/canvas/WebMetalLibrary.h: Removed.
998         * html/canvas/WebMetalLibrary.idl: Removed.
999         * html/canvas/WebMetalRenderCommandEncoder.cpp: Removed.
1000         * html/canvas/WebMetalRenderCommandEncoder.h: Removed.
1001         * html/canvas/WebMetalRenderCommandEncoder.idl: Removed.
1002         * html/canvas/WebMetalRenderPassAttachmentDescriptor.cpp: Removed.
1003         * html/canvas/WebMetalRenderPassAttachmentDescriptor.h: Removed.
1004         * html/canvas/WebMetalRenderPassAttachmentDescriptor.idl: Removed.
1005         * html/canvas/WebMetalRenderPassColorAttachmentDescriptor.cpp: Removed.
1006         * html/canvas/WebMetalRenderPassColorAttachmentDescriptor.h: Removed.
1007         * html/canvas/WebMetalRenderPassColorAttachmentDescriptor.idl: Removed.
1008         * html/canvas/WebMetalRenderPassDepthAttachmentDescriptor.cpp: Removed.
1009         * html/canvas/WebMetalRenderPassDepthAttachmentDescriptor.h: Removed.
1010         * html/canvas/WebMetalRenderPassDepthAttachmentDescriptor.idl: Removed.
1011         * html/canvas/WebMetalRenderPassDescriptor.cpp: Removed.
1012         * html/canvas/WebMetalRenderPassDescriptor.h: Removed.
1013         * html/canvas/WebMetalRenderPassDescriptor.idl: Removed.
1014         * html/canvas/WebMetalRenderPipelineColorAttachmentDescriptor.cpp: Removed.
1015         * html/canvas/WebMetalRenderPipelineColorAttachmentDescriptor.h: Removed.
1016         * html/canvas/WebMetalRenderPipelineColorAttachmentDescriptor.idl: Removed.
1017         * html/canvas/WebMetalRenderPipelineDescriptor.cpp: Removed.
1018         * html/canvas/WebMetalRenderPipelineDescriptor.h: Removed.
1019         * html/canvas/WebMetalRenderPipelineDescriptor.idl: Removed.
1020         * html/canvas/WebMetalRenderPipelineState.cpp: Removed.
1021         * html/canvas/WebMetalRenderPipelineState.h: Removed.
1022         * html/canvas/WebMetalRenderPipelineState.idl: Removed.
1023         * html/canvas/WebMetalRenderingContext.cpp: Removed.
1024         * html/canvas/WebMetalRenderingContext.h: Removed.
1025         * html/canvas/WebMetalRenderingContext.idl: Removed.
1026         * html/canvas/WebMetalSize.h: Removed.
1027         * html/canvas/WebMetalSize.idl: Removed.
1028         * html/canvas/WebMetalTexture.cpp: Removed.
1029         * html/canvas/WebMetalTexture.h: Removed.
1030         * html/canvas/WebMetalTexture.idl: Removed.
1031         * html/canvas/WebMetalTextureDescriptor.cpp: Removed.
1032         * html/canvas/WebMetalTextureDescriptor.h: Removed.
1033         * html/canvas/WebMetalTextureDescriptor.idl: Removed.
1034         * inspector/InspectorCanvas.cpp:
1035         (WebCore::InspectorCanvas::buildObjectForCanvas):
1036         * inspector/agents/InspectorCanvasAgent.cpp:
1037         (WebCore::InspectorCanvasAgent::requestContent):
1038         (WebCore::contextAsScriptValue):
1039         * page/RuntimeEnabledFeatures.h:
1040         (WebCore::RuntimeEnabledFeatures::setWebMetalEnabled): Deleted.
1041         (WebCore::RuntimeEnabledFeatures::webMetalEnabled const): Deleted.
1042         * platform/Logging.h:
1043         * platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm:
1044         (WebCore::PlatformCALayerCocoa::layerTypeForPlatformLayer):
1045         (WebCore::PlatformCALayerCocoa::PlatformCALayerCocoa):
1046         * platform/graphics/cocoa/WebMetalLayer.h: Removed.
1047         * platform/graphics/cocoa/WebMetalLayer.mm: Removed.
1048         * platform/graphics/gpu/legacy/GPULegacyBuffer.cpp: Removed.
1049         * platform/graphics/gpu/legacy/GPULegacyBuffer.h: Removed.
1050         * platform/graphics/gpu/legacy/GPULegacyCommandBuffer.cpp: Removed.
1051         * platform/graphics/gpu/legacy/GPULegacyCommandBuffer.h: Removed.
1052         * platform/graphics/gpu/legacy/GPULegacyCommandQueue.cpp: Removed.
1053         * platform/graphics/gpu/legacy/GPULegacyCommandQueue.h: Removed.
1054         * platform/graphics/gpu/legacy/GPULegacyComputeCommandEncoder.cpp: Removed.
1055         * platform/graphics/gpu/legacy/GPULegacyComputeCommandEncoder.h: Removed.
1056         * platform/graphics/gpu/legacy/GPULegacyComputePipelineState.cpp: Removed.
1057         * platform/graphics/gpu/legacy/GPULegacyComputePipelineState.h: Removed.
1058         * platform/graphics/gpu/legacy/GPULegacyDepthStencilDescriptor.cpp: Removed.
1059         * platform/graphics/gpu/legacy/GPULegacyDepthStencilDescriptor.h: Removed.
1060         * platform/graphics/gpu/legacy/GPULegacyDepthStencilState.cpp: Removed.
1061         * platform/graphics/gpu/legacy/GPULegacyDepthStencilState.h: Removed.
1062         * platform/graphics/gpu/legacy/GPULegacyDevice.cpp: Removed.
1063         * platform/graphics/gpu/legacy/GPULegacyDevice.h: Removed.
1064         * platform/graphics/gpu/legacy/GPULegacyDrawable.cpp: Removed.
1065         * platform/graphics/gpu/legacy/GPULegacyDrawable.h: Removed.
1066         * platform/graphics/gpu/legacy/GPULegacyEnums.h: Removed.
1067         * platform/graphics/gpu/legacy/GPULegacyFunction.cpp: Removed.
1068         * platform/graphics/gpu/legacy/GPULegacyFunction.h: Removed.
1069         * platform/graphics/gpu/legacy/GPULegacyLibrary.cpp: Removed.
1070         * platform/graphics/gpu/legacy/GPULegacyLibrary.h: Removed.
1071         * platform/graphics/gpu/legacy/GPULegacyRenderCommandEncoder.cpp: Removed.
1072         * platform/graphics/gpu/legacy/GPULegacyRenderCommandEncoder.h: Removed.
1073         * platform/graphics/gpu/legacy/GPULegacyRenderPassAttachmentDescriptor.cpp: Removed.
1074         * platform/graphics/gpu/legacy/GPULegacyRenderPassAttachmentDescriptor.h: Removed.
1075         * platform/graphics/gpu/legacy/GPULegacyRenderPassColorAttachmentDescriptor.cpp: Removed.
1076         * platform/graphics/gpu/legacy/GPULegacyRenderPassColorAttachmentDescriptor.h: Removed.
1077         * platform/graphics/gpu/legacy/GPULegacyRenderPassDepthAttachmentDescriptor.cpp: Removed.
1078         * platform/graphics/gpu/legacy/GPULegacyRenderPassDepthAttachmentDescriptor.h: Removed.
1079         * platform/graphics/gpu/legacy/GPULegacyRenderPassDescriptor.cpp: Removed.
1080         * platform/graphics/gpu/legacy/GPULegacyRenderPassDescriptor.h: Removed.
1081         * platform/graphics/gpu/legacy/GPULegacyRenderPipelineColorAttachmentDescriptor.cpp: Removed.
1082         * platform/graphics/gpu/legacy/GPULegacyRenderPipelineColorAttachmentDescriptor.h: Removed.
1083         * platform/graphics/gpu/legacy/GPULegacyRenderPipelineDescriptor.cpp: Removed.
1084         * platform/graphics/gpu/legacy/GPULegacyRenderPipelineDescriptor.h: Removed.
1085         * platform/graphics/gpu/legacy/GPULegacyRenderPipelineState.cpp: Removed.
1086         * platform/graphics/gpu/legacy/GPULegacyRenderPipelineState.h: Removed.
1087         * platform/graphics/gpu/legacy/GPULegacySize.h: Removed.
1088         * platform/graphics/gpu/legacy/GPULegacyTexture.cpp: Removed.
1089         * platform/graphics/gpu/legacy/GPULegacyTexture.h: Removed.
1090         * platform/graphics/gpu/legacy/GPULegacyTextureDescriptor.cpp: Removed.
1091         * platform/graphics/gpu/legacy/GPULegacyTextureDescriptor.h: Removed.
1092         * platform/graphics/gpu/legacy/cocoa/GPULegacyBufferMetal.mm: Removed.
1093         * platform/graphics/gpu/legacy/cocoa/GPULegacyCommandBufferMetal.mm: Removed.
1094         * platform/graphics/gpu/legacy/cocoa/GPULegacyCommandQueueMetal.mm: Removed.
1095         * platform/graphics/gpu/legacy/cocoa/GPULegacyComputeCommandEncoderMetal.mm: Removed.
1096         * platform/graphics/gpu/legacy/cocoa/GPULegacyComputePipelineStateMetal.mm: Removed.
1097         * platform/graphics/gpu/legacy/cocoa/GPULegacyDepthStencilDescriptorMetal.mm: Removed.
1098         * platform/graphics/gpu/legacy/cocoa/GPULegacyDepthStencilStateMetal.mm: Removed.
1099         * platform/graphics/gpu/legacy/cocoa/GPULegacyDeviceMetal.mm: Removed.
1100         * platform/graphics/gpu/legacy/cocoa/GPULegacyDrawableMetal.mm: Removed.
1101         * platform/graphics/gpu/legacy/cocoa/GPULegacyFunctionMetal.mm: Removed.
1102         * platform/graphics/gpu/legacy/cocoa/GPULegacyLibraryMetal.mm: Removed.
1103         * platform/graphics/gpu/legacy/cocoa/GPULegacyRenderCommandEncoderMetal.mm: Removed.
1104         * platform/graphics/gpu/legacy/cocoa/GPULegacyRenderPassAttachmentDescriptorMetal.mm: Removed.
1105         * platform/graphics/gpu/legacy/cocoa/GPULegacyRenderPassColorAttachmentDescriptorMetal.mm: Removed.
1106         * platform/graphics/gpu/legacy/cocoa/GPULegacyRenderPassDepthAttachmentDescriptorMetal.mm: Removed.
1107         * platform/graphics/gpu/legacy/cocoa/GPULegacyRenderPassDescriptorMetal.mm: Removed.
1108         * platform/graphics/gpu/legacy/cocoa/GPULegacyRenderPipelineColorAttachmentDescriptorMetal.mm: Removed.
1109         * platform/graphics/gpu/legacy/cocoa/GPULegacyRenderPipelineDescriptorMetal.mm: Removed.
1110         * platform/graphics/gpu/legacy/cocoa/GPULegacyRenderPipelineStateMetal.mm: Removed.
1111         * platform/graphics/gpu/legacy/cocoa/GPULegacyTextureDescriptorMetal.mm: Removed.
1112         * platform/graphics/gpu/legacy/cocoa/GPULegacyTextureMetal.mm: Removed.
1113         * testing/InternalSettings.cpp:
1114         (WebCore::InternalSettings::Backup::Backup):
1115         (WebCore::InternalSettings::Backup::restoreTo):
1116         (WebCore::InternalSettings::setWebMetalEnabled): Deleted.
1117         * testing/InternalSettings.h:
1118         * testing/InternalSettings.idl:
1119
1120 2019-03-29  Devin Rousso  <drousso@apple.com>
1121
1122         Web Inspector: add fast returns for instrumentation hooks that have no affect before a frontend is connected
1123         https://bugs.webkit.org/show_bug.cgi?id=196382
1124         <rdar://problem/49403417>
1125
1126         Reviewed by Joseph Pecoraro.
1127
1128         Ensure that all instrumentation hooks use `FAST_RETURN_IF_NO_FRONTENDS` or check that
1129         `developerExtrasEnabled`. There should be no activity to/from any inspector objects until
1130         developer extras are enabled.
1131
1132         * inspector/InspectorInstrumentation.h:
1133         (WebCore::InspectorInstrumentation::didClearWindowObjectInWorld):
1134         (WebCore::InspectorInstrumentation::scriptExecutionBlockedByCSP):
1135         (WebCore::InspectorInstrumentation::domContentLoadedEventFired):
1136         (WebCore::InspectorInstrumentation::loadEventFired):
1137         (WebCore::InspectorInstrumentation::frameDetachedFromParent):
1138         (WebCore::InspectorInstrumentation::loaderDetachedFromFrame):
1139         (WebCore::InspectorInstrumentation::frameStartedLoading):
1140         (WebCore::InspectorInstrumentation::frameStoppedLoading):
1141         (WebCore::InspectorInstrumentation::frameScheduledNavigation):
1142         (WebCore::InspectorInstrumentation::frameClearedScheduledNavigation):
1143         * inspector/InspectorInstrumentation.cpp:
1144         (WebCore::InspectorInstrumentation::frameWindowDiscardedImpl):
1145         (WebCore::InspectorInstrumentation::didReceiveResourceResponseImpl):
1146         (WebCore::InspectorInstrumentation::didFailLoadingImpl):
1147         (WebCore::InspectorInstrumentation::addMessageToConsoleImpl):
1148         (WebCore::InspectorInstrumentation::consoleCountImpl):
1149         (WebCore::InspectorInstrumentation::startConsoleTimingImpl):
1150         (WebCore::InspectorInstrumentation::stopConsoleTimingImpl):
1151
1152         * inspector/agents/WebConsoleAgent.cpp:
1153         (WebCore::WebConsoleAgent::frameWindowDiscarded):
1154
1155 2019-03-29  Chris Dumez  <cdumez@apple.com>
1156
1157         Set window.closed immediately when close() is invoked
1158         https://bugs.webkit.org/show_bug.cgi?id=195409
1159
1160         Reviewed by Alex Christensen.
1161
1162         Window.closed should return true if it is closing:
1163         - https://html.spec.whatwg.org/#dom-window-closed
1164
1165         Window.close() sets the 'is closing' flag to true synchronously, as per:
1166         - https://html.spec.whatwg.org/#dom-window-close (step 3.1)
1167
1168         No new tests, rebaselined existing tests.
1169
1170         * page/DOMWindow.cpp:
1171         (WebCore::DOMWindow::closed const):
1172
1173 2019-03-29  Zalan Bujtas  <zalan@apple.com>
1174
1175         [Simple line layout] Turn off inline boxtree generation for multiline content
1176         https://bugs.webkit.org/show_bug.cgi?id=196404
1177         <rdar://problem/49234033>
1178
1179         Reviewed by Simon Fraser.
1180
1181         Currently simple line layout can't provide the correct line breaking context to the inline tree when the boxtree is
1182         generated using the simple line runs. This patch limits the generation of such trees to single lines. Multiline content will
1183         go through the "let's layout this content again" codepath.
1184         This patch fixes disappearing content on Questar.
1185
1186         Test: fast/text/simple-line-layout-and-multiline-inlineboxtree.html
1187
1188         * rendering/SimpleLineLayoutFunctions.cpp:
1189         (WebCore::SimpleLineLayout::canUseForLineBoxTree):
1190
1191 2019-03-29  Justin Fan  <justin_fan@apple.com>
1192
1193         [Web GPU] Replace unsigned longs in WebGPU with uint64_t
1194         https://bugs.webkit.org/show_bug.cgi?id=196401
1195
1196         Reviewed by Myles C. Maxfield.
1197
1198         Unsigned long is not guaranteed to be 64 bits on all platforms. In addition, rowPitch is updated
1199         to u32 in the API and the implementation to match.
1200
1201         No new tests. No new behavior.
1202
1203         * Modules/webgpu/WebGPUBuffer.cpp:
1204         (WebCore::WebGPUBuffer::setSubData):
1205         * Modules/webgpu/WebGPUBuffer.h:
1206         * Modules/webgpu/WebGPUBufferBinding.h:
1207         * Modules/webgpu/WebGPUCommandEncoder.cpp:
1208         (WebCore::WebGPUCommandEncoder::copyBufferToBuffer):
1209         * Modules/webgpu/WebGPUCommandEncoder.h:
1210         * Modules/webgpu/WebGPUCommandEncoder.idl:
1211         * Modules/webgpu/WebGPURenderPassEncoder.cpp:
1212         (WebCore::WebGPURenderPassEncoder::setVertexBuffers):
1213         * Modules/webgpu/WebGPURenderPassEncoder.h:
1214         * platform/graphics/gpu/GPUBindGroupLayout.h:
1215         * platform/graphics/gpu/GPUBuffer.h:
1216         (WebCore::GPUBuffer::byteLength const):
1217         * platform/graphics/gpu/GPUBufferBinding.h:
1218         * platform/graphics/gpu/GPUBufferDescriptor.h:
1219         * platform/graphics/gpu/GPUCommandBuffer.h:
1220         * platform/graphics/gpu/GPURenderPassEncoder.h:
1221         * platform/graphics/gpu/GPUVertexAttributeDescriptor.h:
1222         * platform/graphics/gpu/GPUVertexInputDescriptor.h:
1223         * platform/graphics/gpu/cocoa/GPUBufferMetal.mm:
1224         (WebCore::GPUBuffer::GPUBuffer):
1225         (WebCore::GPUBuffer::setSubData):
1226         * platform/graphics/gpu/cocoa/GPUCommandBufferMetal.mm:
1227         (WebCore::GPUCommandBuffer::copyBufferToBuffer):
1228         * platform/graphics/gpu/cocoa/GPURenderPassEncoderMetal.mm:
1229         (WebCore::GPURenderPassEncoder::setVertexBuffers):
1230
1231 2019-03-29  Wenson Hsieh  <wenson_hsieh@apple.com>
1232
1233         REGRESSION (r243250): Text interactions are no longer suppressed when editing in some websites
1234         https://bugs.webkit.org/show_bug.cgi?id=196378
1235         <rdar://problem/49231299>
1236
1237         Reviewed by Simon Fraser.
1238
1239         Enabling async overflow scrolling by default in r243250 exposed an issue with hidden editable area detection
1240         heuristics. Currently, an empty value for RenderLayer::selfClipRect is used to determine whether the layer
1241         enclosing the editable element or form control is completely clipped by a parent (in other words, the clip rect
1242         is empty). With async overflow scrolling, the enclosing layer of the editable element (as seen in the websites
1243         affected by this bug) will now be a clipping root for painting, since it is composited. This means selfClipRect
1244         returns a non-empty rect despite the layer being entirely clipped, which negates the heuristic.
1245
1246         To address this, we adjust the clipping heuristic to instead walk up the layer tree (crossing frame boundaries)
1247         and look for enclosing ancestors with overflow clip. For each layer we find with an overflow clip, compute the
1248         clip rect of the previous layer relative to the ancestor with overflow clip. If the clipping rect is empty, we
1249         know that the layer is hidden.
1250
1251         This isn't a perfect strategy, since it may still report false negatives (reporting a layer as visible when it
1252         is not) in some cases. One such edge case is a series of overflow hidden containers, nested in such a way that
1253         each container is only partially clipped relative to its ancestor, but the deepest layer is completely clipped
1254         relative to the topmost layer. However, this heuristic is relatively cheap (entailing a layer tree walk at
1255         worst) and works for common use cases on the web without risking scenarios in which text selection that
1256         shouldn't be suppressed ends up becoming suppressed.
1257
1258         Test: editing/selection/ios/hide-selection-in-textarea-with-transform.html
1259
1260         * rendering/RenderLayer.cpp:
1261         (WebCore::RenderLayer::isTransparentOrFullyClippedRespectingParentFrames const):
1262
1263 2019-03-29  Takashi Komori  <Takashi.Komori@sony.com>
1264
1265         [Curl] Add Server Trust Evaluation Support.
1266         https://bugs.webkit.org/show_bug.cgi?id=191646
1267
1268         Reviewed by Fujii Hironori.
1269
1270         Tests: http/tests/ssl/iframe-upgrade.https.html
1271                http/tests/ssl/mixedContent/insecure-websocket.html
1272                http/tests/ssl/upgrade-origin-usage.html
1273
1274         * platform/network/curl/AuthenticationChallenge.h:
1275         * platform/network/curl/AuthenticationChallengeCurl.cpp:
1276         (WebCore::AuthenticationChallenge::AuthenticationChallenge):
1277         (WebCore::AuthenticationChallenge::protectionSpaceForPasswordBased):
1278         (WebCore::AuthenticationChallenge::protectionSpaceForServerTrust):
1279         (WebCore::AuthenticationChallenge::protectionSpaceFromHandle): Deleted.
1280         * platform/network/curl/CurlContext.cpp:
1281         (WebCore::CurlHandle::disableServerTrustEvaluation):
1282         * platform/network/curl/CurlContext.h:
1283         * platform/network/curl/CurlRequest.cpp:
1284         (WebCore::CurlRequest::setupTransfer):
1285         * platform/network/curl/CurlRequest.h:
1286         (WebCore::CurlRequest::disableServerTrustEvaluation):
1287
1288 2019-03-29  Ryosuke Niwa  <rniwa@webkit.org>
1289
1290         Pasting a table from Confluence strip of table cell content
1291         https://bugs.webkit.org/show_bug.cgi?id=196390
1292
1293         Reviewed by Antti Koivisto.
1294
1295         The bug was ultimately caused by FrameView of the document we use to sanitize the pasteboard content
1296         having 0px by 0px dimension. This caused div with `overflow-x: auto` surrounding a table to have
1297         the height of 0px. Because StyledMarkupAccumulator::renderedTextRespectingRange uses TextIterator
1298         to serialize a text node and this div was an ancestor of the text node, TextIterator::handleTextNode
1299         ended up exiting early.
1300
1301         Fixed the bug by giving FrameView, which is used to sanitize the content, a dimension of 800px by 600px.
1302
1303         Using TextIteratorIgnoresStyleVisibility is not a great alternative since removing invisible content
1304         during paste is an important privacy feature.
1305
1306         Test: editing/pasteboard/paste-content-with-overflow-auto-parent-across-origin.html
1307
1308         * editing/markup.cpp:
1309         (WebCore::createPageForSanitizingWebContent):
1310
1311 2019-03-29  Antoine Quint  <graouts@apple.com>
1312
1313         WebKitTestRunner crashes when running pointerevents/ios/touch-action-none-in-overflow-scrolling-touch.html
1314         https://bugs.webkit.org/show_bug.cgi?id=196345
1315
1316         Reviewed by Dean Jackson.
1317
1318         An enum used within a WTF::OptionSet needs to have only power-of-two values that are larger than 0.
1319
1320         * platform/TouchAction.h:
1321         * rendering/style/StyleRareNonInheritedData.h:
1322
1323 2019-03-29  Michael Catanzaro  <mcatanzaro@igalia.com>
1324
1325         HTMLInputElement::setEditingValue should not fail if renderer doesn't exist
1326         https://bugs.webkit.org/show_bug.cgi?id=195708
1327
1328         Reviewed by Wenson Hsieh.
1329
1330         HTMLInputElement::setEditingValue currently returns early if the element's renderer() is
1331         null. This is causing the Epiphany password manager to fail to remember passwords on
1332         https://www.geico.com/ except for navigations through page cache.
1333
1334         This check was originally added to avoid some assertion, but I don't know which one, and
1335         there's definitely not any assertion hit nowadays in this case. Probably there are more
1336         guards checking if renderer() is null elsewhere in the code nowadays, closer to where it's
1337         really needed.
1338
1339         Test: fast/forms/editing-value-null-renderer.html
1340
1341         * html/HTMLInputElement.cpp:
1342         (WebCore::HTMLInputElement::setEditingValue):
1343
1344 2019-03-29  Chris Dumez  <cdumez@apple.com>
1345
1346         Unreviewed, rebaseline WPT test after r243638.
1347
1348         * DerivedSources-input.xcfilelist:
1349         * DerivedSources-output.xcfilelist:
1350
1351 2019-03-28  Antoine Quint  <graouts@apple.com>
1352
1353         All PointerEvent.isTrusted is always false.
1354         https://bugs.webkit.org/show_bug.cgi?id=196075
1355         <rdar://problem/49158778>
1356
1357         Reviewed by Chris Dumez.
1358
1359         Test: pointerevents/ios/pointer-events-is-trusted.html
1360
1361         The constructors we were using for some PointerEvent::create() methods were using initializers which are expected to be used with JS APIs
1362         and thus generate untrusted events. We switch to using constructors using dedicated parameters which will set isTrusted to true.
1363
1364         * dom/PointerEvent.cpp:
1365         (WebCore::PointerEvent::create):
1366         (WebCore::PointerEvent::createPointerCancelEvent):
1367         (WebCore::PointerEvent::PointerEvent):
1368         (WebCore::m_isPrimary):
1369         (WebCore::m_pointerType):
1370         * dom/PointerEvent.h:
1371         * page/PointerCaptureController.cpp:
1372         (WebCore::PointerCaptureController::cancelPointer):
1373
1374 2019-03-29  Philippe Normand  <pnormand@igalia.com>
1375
1376         [GStreamer] imxvpudecoder detection and handling
1377         https://bugs.webkit.org/show_bug.cgi?id=196346
1378
1379         Reviewed by Xabier Rodriguez-Calvar.
1380
1381         When the imxvpudecoder is used, the texture sampling of the
1382         directviv-uploaded texture returns an RGB value, so there's no need
1383         to convert it. This patch also includes a refactoring of the
1384         ImageRotation flag handling. The flag is now computed once only
1385         and stored in an instance variable.
1386
1387         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
1388         (WebCore::MediaPlayerPrivateGStreamer::createGSTPlayBin):
1389         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
1390         (WebCore::GstVideoFrameHolder::GstVideoFrameHolder):
1391         (WebCore::MediaPlayerPrivateGStreamerBase::~MediaPlayerPrivateGStreamerBase):
1392         (WebCore::MediaPlayerPrivateGStreamerBase::pushTextureToCompositor):
1393         (WebCore::MediaPlayerPrivateGStreamerBase::flushCurrentBuffer):
1394         (WebCore::MediaPlayerPrivateGStreamerBase::copyVideoTextureToPlatformTexture):
1395         (WebCore::MediaPlayerPrivateGStreamerBase::nativeImageForCurrentTime):
1396         (WebCore::MediaPlayerPrivateGStreamerBase::setVideoSourceOrientation):
1397         (WebCore::MediaPlayerPrivateGStreamerBase::updateTextureMapperFlags):
1398         (WebCore::texMapFlagFromOrientation): Deleted.
1399         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:
1400
1401 2019-03-29  Cathie Chen  <cathiechen@igalia.com>
1402
1403         Implement ResizeObserver.
1404         https://bugs.webkit.org/show_bug.cgi?id=157743
1405
1406         Reviewed by Simon Fraser.
1407
1408         Tests: resize-observer/modify-frametree-in-callback.html
1409                resize-observer/multi-frames.html
1410                resize-observer/observe-element-from-other-frame.html
1411                Imported from WPT by https://bugs.webkit.org/show_bug.cgi?id=193821
1412
1413         The data structure: Document has a ResizeObserver slot. ResizeObserver has a ResizeObservation slot.
1414         ResizeObservation is related to one Element and the last reported size.
1415         On the other hand, Element has a ResizeObservation slot.
1416
1417         At the beginning of willDisplayPage, it will check resize observations for current page if:
1418         1. There is FrameView be layout and there are ResizeObservers in this page.
1419         2. m_resizeObserverTimer has been started by observe() or hasSkippedResizeObservers().
1420         During checkResizeObservations(), we'll gatherDocumentsNeedingResizeObservationCheck() first,
1421         then notifyResizeObservers() for each document. During notifyResizeObservers(), it will gather
1422         the m_activeObservations whose size changed and target element deeper than require depth.
1423         The size changed shallower observations are skipped observations which will be delivered
1424         in the next time. And an ErrorEvent will be reported.
1425         After gathering, deliverResizeObservations create entries and invoke the callbacks with them.
1426
1427         The Element from other document could be observed.
1428
1429         * CMakeLists.txt:
1430         * Configurations/FeatureDefines.xcconfig:
1431         * DerivedSources.make:
1432         * Sources.txt:
1433         * WebCore.xcodeproj/project.pbxproj:
1434         * bindings/js/WebCoreBuiltinNames.h:
1435         * dom/Document.cpp:
1436         (WebCore::Document::getParserLocation const):
1437         (WebCore::Document::addResizeObserver):
1438         (WebCore::Document::removeResizeObserver):
1439         (WebCore::Document::hasResizeObservers):
1440         (WebCore::Document::gatherResizeObservations): Gather m_activeObservations at depth and return the shallowest depth.
1441         (WebCore::Document::deliverResizeObservations): Deliver m_activeObservations, generate ResizeObserverEntries, and invoke the m_callbacks.
1442         (WebCore::Document::hasSkippedResizeObservations const): To determine if Document has the size changed but not delivered observations.
1443         (WebCore::Document::setHasSkippedResizeObservations):
1444         (WebCore::Document::scheduleResizeObservations):
1445         * dom/Document.h:
1446         * dom/Element.cpp:
1447         (WebCore::Element::~Element):
1448         (WebCore::Element::disconnectFromResizeObservers):
1449         (WebCore::Element::ensureResizeObserverData):
1450         (WebCore::Element::resizeObserverData):
1451         * dom/Element.h:
1452         * dom/ElementRareData.cpp:
1453         * dom/ElementRareData.h:
1454         (WebCore::ElementRareData::resizeObserverData):
1455         (WebCore::ElementRareData::setResizeObserverData):
1456         (WebCore::ElementRareData::useTypes const):
1457         * page/FrameView.cpp:
1458         (WebCore::FrameView::didLayout):
1459         * page/FrameViewLayoutContext.cpp:
1460         (WebCore::FrameViewLayoutContext::layoutTimerFired): We need to start a ResizeObserver timer here, because for WK1 this might not trigger flushCompositingChanges.
1461         * page/Page.cpp:
1462         (WebCore::Page::Page):
1463         (WebCore::Page::willDisplayPage):
1464         (WebCore::Page::hasResizeObservers const):
1465         (WebCore::Page::gatherDocumentsNeedingResizeObservationCheck): Gather the documents with resize observers.
1466         (WebCore::Page::checkResizeObservations): Gather documents then notifyResizeObservers for each document.
1467         (WebCore::Page::scheduleResizeObservations):
1468         (WebCore::Page::notifyResizeObservers): Gather m_activeObservations and deliver them. Report ErrorEvent if it has skipped observations.
1469         * page/Page.h:
1470         (WebCore::Page::setNeedsCheckResizeObservations): Page needs to check ResizeObservations if FrameView layout or m_resizeObserverTimer has been started.
1471         (WebCore::Page::needsCheckResizeObservations const):
1472         * page/PageConsoleClient.cpp:
1473         (WebCore::PageConsoleClient::addMessage):
1474         (WebCore::getParserLocationForConsoleMessage): Deleted.
1475         * page/ResizeObservation.cpp: Added.
1476         (WebCore::ResizeObservation::create):
1477         (WebCore::ResizeObservation::ResizeObservation):
1478         (WebCore::ResizeObservation::~ResizeObservation):
1479         (WebCore::ResizeObservation::updateObservationSize):
1480         (WebCore::ResizeObservation::computeObservedSize const):
1481         (WebCore::ResizeObservation::computeTargetLocation const):
1482         (WebCore::ResizeObservation::computeContentRect const):
1483         (WebCore::ResizeObservation::elementSizeChanged const):
1484         (WebCore::ResizeObservation::targetElementDepth const):
1485         * page/ResizeObservation.h: Copied from Tools/DumpRenderTree/TestOptions.h.
1486         (WebCore::ResizeObservation::target const):
1487         * page/ResizeObserver.cpp: Added.
1488         (WebCore::ResizeObserver::create):
1489         (WebCore::ResizeObserver::ResizeObserver):
1490         (WebCore::ResizeObserver::~ResizeObserver):
1491         (WebCore::ResizeObserver::scheduleObservations):
1492         (WebCore::ResizeObserver::observe):
1493         (WebCore::ResizeObserver::unobserve):
1494         (WebCore::ResizeObserver::disconnect):
1495         (WebCore::ResizeObserver::targetDestroyed):
1496         (WebCore::ResizeObserver::gatherObservations):
1497         (WebCore::ResizeObserver::deliverObservations):
1498         (WebCore::ResizeObserver::removeTarget):
1499         (WebCore::ResizeObserver::removeAllTargets):
1500         (WebCore::ResizeObserver::removeObservation):
1501         (WebCore::ResizeObserver::hasPendingActivity const):
1502         (WebCore::ResizeObserver::activeDOMObjectName const):
1503         (WebCore::ResizeObserver::canSuspendForDocumentSuspension const):
1504         (WebCore::ResizeObserver::stop):
1505         * page/ResizeObserver.h: Added.
1506         (WebCore::ResizeObserver::hasObservations const):
1507         (WebCore::ResizeObserver::hasActiveObservations const):
1508         (WebCore::ResizeObserver::maxElementDepth):
1509         (WebCore::ResizeObserver::hasSkippedObservations const):
1510         (WebCore::ResizeObserver::setHasSkippedObservations):
1511         * page/ResizeObserver.idl: Copied from Tools/DumpRenderTree/TestOptions.h.
1512         * page/ResizeObserverCallback.h: Copied from Tools/DumpRenderTree/TestOptions.h.
1513         * page/ResizeObserverCallback.idl: Copied from Tools/DumpRenderTree/TestOptions.h.
1514         * page/ResizeObserverEntry.h: Copied from Tools/DumpRenderTree/TestOptions.h.
1515         (WebCore::ResizeObserverEntry::create):
1516         (WebCore::ResizeObserverEntry::target const):
1517         (WebCore::ResizeObserverEntry::contentRect const):
1518         (WebCore::ResizeObserverEntry::ResizeObserverEntry):
1519         * page/ResizeObserverEntry.idl: Copied from Tools/DumpRenderTree/TestOptions.h.
1520         * page/Settings.yaml:
1521
1522 2019-03-28  Chris Dumez  <cdumez@apple.com>
1523
1524         Support <object>.contentWindow
1525         https://bugs.webkit.org/show_bug.cgi?id=195562
1526
1527         Reviewed by Sam Weinig.
1528
1529         Support <object>.contentWindow as per:
1530         - https://html.spec.whatwg.org/multipage/iframe-embed-object.html#dom-object-contentwindow
1531
1532         No new tests, updated / rebaselined existing tests.
1533
1534         * html/HTMLObjectElement.idl:
1535
1536 2019-03-28  Myles C. Maxfield  <mmaxfield@apple.com>
1537
1538         FontFace constructor throws an exception when there is a name which starts with a number
1539         https://bugs.webkit.org/show_bug.cgi?id=196232
1540         <rdar://problem/49293978>
1541
1542         Reviewed by Ryosuke Niwa.
1543
1544         We were technically following the spec, but Chrome and Firefox are both consistent and it was making a website break.
1545         This is just a short-term fix until the underlying https://bugs.webkit.org/show_bug.cgi?id=196381 is fixed.
1546
1547         Test: fast/text/font-face-family.html
1548
1549         * css/FontFace.cpp:
1550         (WebCore::FontFace::setFamily):
1551
1552 2019-03-28  Justin Fan  <justin_fan@apple.com>
1553
1554         [Web GPU] Replace 'unsigned long' with 'unsigned' when implementing u32 variables
1555         https://bugs.webkit.org/show_bug.cgi?id=194618
1556         <rdar://problem/48055796>
1557
1558         Reviewed by Myles C. Maxfield.
1559
1560         WebIDL for "unsigned" on 64-bit is "unsigned long". Update Web GPU to match.
1561
1562         No new tests; no change in behavior.
1563
1564         * Modules/webgpu/GPUBindGroupLayoutBinding.h:
1565         * Modules/webgpu/WHLSL/Metal/WHLSLVertexBufferIndexCalculator.cpp:
1566         (WebCore::WHLSL::Metal::calculateVertexBufferIndex):
1567         * Modules/webgpu/WHLSL/Metal/WHLSLVertexBufferIndexCalculator.h:
1568         * Modules/webgpu/WebGPUBindGroupBinding.h:
1569         * Modules/webgpu/WebGPUBindGroupDescriptor.cpp:
1570         (WebCore::validateBufferBindingType):
1571         (WebCore::WebGPUBindGroupDescriptor::tryCreateGPUBindGroupDescriptor const):
1572         * Modules/webgpu/WebGPUBuffer.cpp:
1573         (WebCore::WebGPUBuffer::setSubData):
1574         * Modules/webgpu/WebGPUBuffer.h:
1575         * Modules/webgpu/WebGPUBufferBinding.h:
1576         * Modules/webgpu/WebGPURenderPassEncoder.cpp:
1577         (WebCore::WebGPURenderPassEncoder::setVertexBuffers):
1578         (WebCore::WebGPURenderPassEncoder::draw):
1579         * Modules/webgpu/WebGPURenderPassEncoder.h:
1580         * platform/graphics/gpu/GPUBindGroupBinding.h:
1581         * platform/graphics/gpu/GPUBindGroupLayout.h:
1582         * platform/graphics/gpu/GPUBufferBinding.h:
1583         * platform/graphics/gpu/GPUExtent3D.h:
1584         * platform/graphics/gpu/GPULimits.h:
1585         * platform/graphics/gpu/GPURenderPassEncoder.h:
1586         * platform/graphics/gpu/GPUTextureDescriptor.h:
1587         * platform/graphics/gpu/cocoa/GPUBindGroupLayoutMetal.mm:
1588         (WebCore::GPUBindGroupLayout::tryCreate):
1589         * platform/graphics/gpu/cocoa/GPUBindGroupMetal.mm:
1590         (WebCore::GPUBindGroup::tryCreate):
1591         * platform/graphics/gpu/cocoa/GPURenderPassEncoderMetal.mm:
1592         (WebCore::GPURenderPassEncoder::setVertexBuffers):
1593         (WebCore::GPURenderPassEncoder::draw):
1594         * platform/graphics/gpu/cocoa/GPURenderPipelineMetal.mm:
1595         (WebCore::trySetInputStateForPipelineDescriptor):
1596         * platform/graphics/gpu/cocoa/GPUTextureMetal.mm:
1597         (WebCore::storageModeForPixelFormatAndSampleCount):
1598
1599 2019-03-28  Ryosuke Niwa  <rniwa@webkit.org>
1600
1601         getBoundingClientRect always returns empty rect on a collapsed range
1602         https://bugs.webkit.org/show_bug.cgi?id=196380
1603
1604         Reviewed by Wenson Hsieh.
1605
1606         The bug was caused by Range::boundingRect merging rects via FloatRect::unite which ignores empty rects.
1607         Use uniteIfNonZero instead to fix the bug. Note that we can't use uniteEvenIfEmpty because that would
1608         set x, y to always 0, 0 as we would end up merging any rect with the initial empty rect.
1609
1610         Test: fast/dom/Range/getBoundingClientRect-on-collapsed-selection-range.html
1611
1612         * dom/Range.cpp:
1613         (WebCore::Range::boundingRect const):
1614
1615 2019-03-28  Justin Fan  <justin_fan@apple.com>
1616
1617         [Web GPU] Prototype compute pipeline with MSL
1618         https://bugs.webkit.org/show_bug.cgi?id=196107
1619         <rdar://problem/46289650>
1620
1621         Reviewed by Myles Maxfield.
1622
1623         Add GPUComputePassEncoder, GPUComputePipeline, and GPUComputePipelineDescriptor.
1624         Implement everything needed to prototype a compute pipeline in Web GPU using Metal shaders and bound resources.
1625
1626         Test: webgpu/compute-squares.html
1627
1628         Add files and symbols:
1629         * CMakeLists.txt:
1630         * DerivedSources-input.xcfilelist:
1631         * DerivedSources-output.xcfilelist:
1632         * DerivedSources.make:
1633         * Sources.txt:
1634         * SourcesCocoa.txt:
1635         * WebCore.xcodeproj/project.pbxproj:
1636         * bindings/js/WebCoreBuiltinNames.h:
1637
1638         Misc fixes:
1639         * Modules/webgpu/WHLSL/WHLSLNameResolver.h: Missing include.
1640         * Modules/webgpu/WHLSL/WHLSLSynthesizeConstructors.cpp: Missing include.
1641         * Modules/webgpu/WebGPUPipelineStageDescriptor.cpp: Added. Move pipeline stage validation logic here.
1642         (WebCore::WebGPUPipelineStageDescriptor::tryCreateGPUPipelineStageDescriptor const):
1643         * Modules/webgpu/WebGPURenderPipeline.cpp: Remove unnecessary include.
1644         * Modules/webgpu/WebGPURenderPipeline.h:
1645         * Modules/webgpu/WebGPURenderPipelineDescriptor.cpp: Add missing inlcude.
1646         (WebCore::WebGPUPipelineStageDescriptor::tryCreateGPUPipelineStageDescriptor const): Moved to WebGPUPipelineStageDescriptor.cpp.
1647         * platform/graphics/gpu/GPUPipelineDescriptorBase.h: Add missing include.
1648         * platform/graphics/gpu/cocoa/GPURenderPipelineMetal.mm: Add missing include.
1649         (WebCore::GPURenderPipeline::GPURenderPipeline): Remove unecessary ref of GPUPipelineLayout.
1650         * platform/text/mac/TextEncodingRegistryMac.mm: Carbon.h was causing ambiguous reference build errors in this file.
1651
1652         Enable creating a GPUComputePassEncoder from a GPUCommandEncoder:
1653         * Modules/webgpu/WebGPUCommandEncoder.cpp:
1654         (WebCore::WebGPUCommandEncoder::beginRenderPass): No longer passing this WebGPUCommandEncoder to pass encoders.
1655         (WebCore::WebGPUCommandEncoder::beginComputePass): Added.
1656         * Modules/webgpu/WebGPUCommandEncoder.h:
1657         * Modules/webgpu/WebGPUCommandEncoder.idl:
1658
1659         Add GPUComputePassEncoder:
1660         * Modules/webgpu/WebGPUComputePassEncoder.cpp: Added.
1661         (WebCore::WebGPUComputePassEncoder::create):
1662         (WebCore::WebGPUComputePassEncoder::WebGPUComputePassEncoder):
1663         (WebCore::WebGPUComputePassEncoder::setPipeline):
1664         (WebCore::WebGPUComputePassEncoder::dispatch):
1665         (WebCore::WebGPUComputePassEncoder::passEncoder):
1666         (WebCore::WebGPUComputePassEncoder::passEncoder const):
1667         * Modules/webgpu/WebGPUComputePassEncoder.h: Added.
1668         * Modules/webgpu/WebGPUComputePassEncoder.idl: Added.
1669         * platform/graphics/gpu/GPUComputePassEncoder.h: Added.
1670         (WebCore::GPUComputePassEncoder::~GPUComputePassEncoder):
1671         * platform/graphics/gpu/cocoa/GPUComputePassEncoderMetal.mm: Added.
1672         (WebCore::GPUComputePassEncoder::tryCreate):
1673         (WebCore::GPUComputePassEncoder::GPUComputePassEncoder):
1674         (WebCore::GPUComputePassEncoder::setPipeline):
1675         (WebCore::GPUComputePassEncoder::dispatch): Use a default calculation for threadsPerThreadgroup while MSL is still an accepted shader format.
1676         (WebCore::GPUComputePassEncoder::platformPassEncoder const):
1677         (WebCore::GPUComputePassEncoder::useResource):
1678         (WebCore::GPUComputePassEncoder::setComputeBuffer):
1679
1680         Add GPUComputePipeline:
1681         * Modules/webgpu/WebGPUComputePipeline.cpp: Added.
1682         (WebCore::WebGPUComputePipeline::create):
1683         (WebCore::WebGPUComputePipeline::WebGPUComputePipeline):
1684         * Modules/webgpu/WebGPUComputePipeline.h: Added.
1685         (WebCore::WebGPUComputePipeline::computePipeline const):
1686         * Modules/webgpu/WebGPUComputePipeline.idl: Added.
1687         * Modules/webgpu/WebGPUComputePipelineDescriptor.cpp: Added.
1688         (WebCore::WebGPUComputePipelineDescriptor::tryCreateGPUComputePipelineDescriptor const):
1689         * Modules/webgpu/WebGPUComputePipelineDescriptor.h: Added.
1690         * Modules/webgpu/WebGPUComputePipelineDescriptor.idl: Added.
1691         * platform/graphics/gpu/GPUComputePipeline.h: Added.
1692         (WebCore::GPUComputePipeline::platformComputePipeline const):
1693         * platform/graphics/gpu/GPUComputePipelineDescriptor.h: Added.
1694         (WebCore::GPUComputePipelineDescriptor::GPUComputePipelineDescriptor):
1695         * platform/graphics/gpu/cocoa/GPUComputePipelineMetal.mm: Added.
1696         (WebCore::tryCreateMtlComputeFunction):
1697         (WebCore::tryCreateMTLComputePipelineState):
1698         (WebCore::GPUComputePipeline::tryCreate):
1699         (WebCore::GPUComputePipeline::GPUComputePipeline):
1700
1701         Enable creating a GPUComputePipeline from a GPUDevice:
1702         * Modules/webgpu/WebGPUDevice.cpp:
1703         (WebCore::WebGPUDevice::createComputePipeline const):
1704         * Modules/webgpu/WebGPUDevice.h:
1705         * Modules/webgpu/WebGPUDevice.idl:
1706         * platform/graphics/gpu/GPUDevice.cpp:
1707         (WebCore::GPUDevice::tryCreateComputePipeline const):
1708         * platform/graphics/gpu/GPUDevice.h:
1709
1710         No longer unnecessarily ref the WebGPUCommandEncoder when creating pass encoder:
1711         * Modules/webgpu/WebGPUProgrammablePassEncoder.cpp:
1712         (WebCore::WebGPUProgrammablePassEncoder::setBindGroup):
1713         (WebCore::WebGPUProgrammablePassEncoder::WebGPUProgrammablePassEncoder): Deleted.
1714         (WebCore::WebGPUProgrammablePassEncoder::setBindGroup const): Deleted.
1715         * Modules/webgpu/WebGPUProgrammablePassEncoder.h:
1716         * Modules/webgpu/WebGPURenderPassEncoder.cpp:
1717         (WebCore::WebGPURenderPassEncoder::create):
1718         (WebCore::WebGPURenderPassEncoder::WebGPURenderPassEncoder):
1719         (WebCore::WebGPURenderPassEncoder::setPipeline):
1720         (WebCore::WebGPURenderPassEncoder::passEncoder):
1721         (WebCore::WebGPURenderPassEncoder::passEncoder const):
1722         * Modules/webgpu/WebGPURenderPassEncoder.h:
1723
1724         Updates to GPUBindGroup and *setBindGroup for compute function arguments:
1725         * platform/graphics/gpu/GPUBindGroup.h:
1726         (WebCore::GPUBindGroup::vertexArgsBuffer const):
1727         (WebCore::GPUBindGroup::fragmentArgsBuffer const):
1728         (WebCore::GPUBindGroup::computeArgsBuffer const):
1729         (WebCore::GPUBindGroup::vertexArgsBuffer): Deleted. Const-qualified.
1730         (WebCore::GPUBindGroup::fragmentArgsBuffer): Ditto.
1731         * platform/graphics/gpu/cocoa/GPUBindGroupMetal.mm:
1732         (WebCore::tryGetResourceAsMTLSamplerState): Now just returns the MTLSamplerState to reduce reference churning.
1733         (WebCore::GPUBindGroup::tryCreate):
1734         (WebCore::GPUBindGroup::GPUBindGroup):
1735         (WebCore::tryGetResourceAsSampler): Renamed to tryGetResourceAsMTLSamplerState.
1736
1737         Updates to GPUProgrammablePassEncoder and GPURenderPassEncoder:
1738         * platform/graphics/gpu/GPUProgrammablePassEncoder.h:
1739         (WebCore::GPUProgrammablePassEncoder::setVertexBuffer):
1740         (WebCore::GPUProgrammablePassEncoder::setFragmentBuffer):
1741         (WebCore::GPUProgrammablePassEncoder::setComputeBuffer): Added.
1742         * platform/graphics/gpu/GPURenderPassEncoder.h:
1743         (WebCore::GPURenderPassEncoder::~GPURenderPassEncoder):
1744         * platform/graphics/gpu/GPURenderPipeline.h:
1745         * platform/graphics/gpu/cocoa/GPUProgrammablePassEncoderMetal.mm: Remove unecessary include.
1746         (WebCore::GPUProgrammablePassEncoder::endPass): No longer virtual. Delegates shared behavior for derived classes.
1747         (WebCore::GPUProgrammablePassEncoder::setBindGroup):
1748         * platform/graphics/gpu/cocoa/GPURenderPassEncoderMetal.mm:
1749         (WebCore::GPURenderPassEncoder::platformPassEncoder const):
1750         (WebCore::GPURenderPassEncoder::setPipeline):
1751         (WebCore::GPURenderPassEncoder::draw):
1752         (WebCore::GPURenderPassEncoder::useResource): These private overrides are called only by base after checking for encoder existence.
1753         (WebCore::GPURenderPassEncoder::setVertexBuffer): Ditto.
1754         (WebCore::GPURenderPassEncoder::setFragmentBuffer): Ditto.
1755         (WebCore::GPURenderPassEncoder::endPass): Deleted. Now handled by base class.
1756
1757 2019-03-27  Jiewen Tan  <jiewen_tan@apple.com>
1758
1759         IDBRequest::dispatchEvent should check nullability of m_transaction before operations that rely on it to be non null
1760         https://bugs.webkit.org/show_bug.cgi?id=196319
1761         <rdar://problem/49355279>
1762
1763         Reviewed by Alex Christensen.
1764
1765         The test that triggers this crash is on Bug 196276.
1766
1767         * Modules/indexeddb/IDBRequest.cpp:
1768         (WebCore::IDBRequest::dispatchEvent):
1769
1770 2019-03-28  Ryosuke Niwa  <rniwa@webkit.org>
1771
1772         Debug assert in DOMSelection::containsNode when node belongs to a different tree
1773         https://bugs.webkit.org/show_bug.cgi?id=196342
1774
1775         Reviewed by Antti Koivisto.
1776
1777         The assertion was wrong. It's possible for Range::compareBoundaryPoints to return WRONG_DOCUMENT_ERR
1778         when the node and the start container belong to two different trees.
1779
1780         Return false in such a case for now since it's unclear (unspecified) what these methods on Selection
1781         should do with respect to shadow trees, preserving the current behavior of release builds.
1782
1783         Test: editing/selection/containsNode-with-no-common-ancestor.html
1784
1785         * page/DOMSelection.cpp:
1786         (WebCore::DOMSelection::containsNode const):
1787
1788 2019-03-28  Tim Horton  <timothy_horton@apple.com>
1789
1790         Fix the !ENABLE(APPLE_PAY) build
1791
1792         * bindings/js/ScriptController.cpp:
1793         (WebCore::ScriptController::shouldAllowUserAgentScripts const):
1794
1795 2019-03-28  Sihui Liu  <sihui_liu@apple.com>
1796
1797         Crash at IDBDatabaseInfo::infoForExistingObjectStore and IDBDatabaseInfo::infoForExistingObjectStore
1798         https://bugs.webkit.org/show_bug.cgi?id=196120
1799         <rdar://problem/39869767>
1800
1801         Reviewed by Ryosuke Niwa.
1802
1803         No new tests because it is unclear how the crash happens. Added release logging to help debug.
1804
1805         * Modules/indexeddb/server/SQLiteIDBBackingStore.cpp:
1806         (WebCore::IDBServer::SQLiteIDBBackingStore::createIndex):
1807         * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
1808         (WebCore::IDBServer::UniqueIDBDatabase::performCreateIndex):
1809         (WebCore::IDBServer::UniqueIDBDatabase::performPutOrAdd):
1810
1811 2019-03-28  Devin Rousso  <drousso@apple.com>
1812
1813         Web Inspector: Canvas: unbinding a canvas should always remove the agent as an observer
1814         https://bugs.webkit.org/show_bug.cgi?id=196324
1815         <rdar://problem/49357109>
1816
1817         Reviewed by Matt Baker.
1818
1819         No change in functionality.
1820
1821         * html/CanvasBase.cpp:
1822         (WebCore::CanvasBase::notifyObserversCanvasChanged):
1823         (WebCore::CanvasBase::notifyObserversCanvasResized):
1824         (WebCore::CanvasBase::notifyObserversCanvasDestroyed):
1825
1826         * inspector/agents/InspectorCanvasAgent.cpp:
1827         (WebCore::InspectorCanvasAgent::frameNavigated):
1828         (WebCore::InspectorCanvasAgent::bindCanvas):
1829         (WebCore::InspectorCanvasAgent::unbindCanvas):
1830
1831 2019-03-28  Alicia Boya García  <aboya@igalia.com>
1832
1833         [MSE][GStreamer] Remove dead code in MediaPlayerPrivateGStreamer::doSeek()
1834         https://bugs.webkit.org/show_bug.cgi?id=196352
1835
1836         Reviewed by Xabier Rodriguez-Calvar.
1837
1838         MediaPlayerPrivateGStreamerMSE overrides doSeek() and seek(), so this
1839         branch is never reached.
1840
1841         This patch does not introduce behavior changes.
1842
1843         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
1844         (WebCore::MediaPlayerPrivateGStreamer::doSeek):
1845
1846 2019-03-28  Simon Fraser  <simon.fraser@apple.com>
1847
1848         [macOS WK2] Overlays on instagram.com are shifted if you click on a photo after scrolling
1849         https://bugs.webkit.org/show_bug.cgi?id=196330
1850         rdar://problem/49100304
1851
1852         Reviewed by Antti Koivisto.
1853
1854         When we call ScrollingTree::applyLayerPositions() on the main thread after a flush,
1855         we need to ensure that the most recent version of the scrolling tree has been committed,
1856         because it has to have state (like requested scroll position and layout viewport rect)
1857         that match the layer flush.
1858
1859         To fix this we have to have the main thread wait for the commit to complete, so
1860         ThreadedScrollingTree keeps track of a pending commit count, and uses a condition
1861         variable to allow the main thread to safely wait for it to reach zero.
1862
1863         Tracing shows that this works as expected, and the main thread is never blocked for
1864         more than a few tens of microseconds.
1865
1866         Also lock the tree mutex in ScrollingTree::handleWheelEvent(), since we enter the
1867         scrolling tree here and we don't want that racing with applyLayerPositions() on the
1868         main thread.
1869
1870         Test: scrollingcoordinator/mac/fixed-scrolled-body.html
1871
1872         * page/scrolling/ScrollingTree.cpp:
1873         (WebCore::ScrollingTree::handleWheelEvent):
1874         (WebCore::ScrollingTree::applyLayerPositions):
1875         * page/scrolling/ScrollingTree.h:
1876         * page/scrolling/ThreadedScrollingTree.cpp:
1877         (WebCore::ThreadedScrollingTree::commitTreeState):
1878         (WebCore::ThreadedScrollingTree::incrementPendingCommitCount):
1879         (WebCore::ThreadedScrollingTree::decrementPendingCommitCount):
1880         (WebCore::ThreadedScrollingTree::waitForPendingCommits):
1881         (WebCore::ThreadedScrollingTree::applyLayerPositions):
1882         * page/scrolling/ThreadedScrollingTree.h:
1883         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
1884         (WebCore::ScrollingCoordinatorMac::commitTreeState):
1885
1886 2019-03-28  Zalan Bujtas  <zalan@apple.com>
1887
1888         [SimpleLineLayout] Disable SLL when text-underline-position is not auto.
1889         https://bugs.webkit.org/show_bug.cgi?id=196338
1890         <rdar://problem/47975167>
1891
1892         Reviewed by Daniel Bates.
1893
1894         Disable simple line layout unconditionally on non-auto text-underline-position content. We don't support it yet.
1895
1896         Test: fast/text/simple-line-layout-with-text-underline-position.html
1897
1898         * rendering/SimpleLineLayout.cpp:
1899         (WebCore::SimpleLineLayout::canUseForStyle):
1900
1901 2019-03-28  Víctor Manuel Jáquez Leal  <vjaquez@igalia.com>
1902
1903         Silence lot of warnings when compiling with clang
1904         https://bugs.webkit.org/show_bug.cgi?id=196310
1905
1906         Reviewed by Michael Catanzaro.
1907
1908         No change in behavior.
1909
1910         * accessibility/AccessibilityObject.h: add missing override
1911         clause.
1912         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
1913         (webKitWebSrcChangeState): add missing format string to log.
1914         * platform/graphics/texmap/TextureMapperPlatformLayerBuffer.h: add
1915         missing virtual destructor.
1916         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.h:
1917         add missing override clause and remove unused private member.
1918
1919 2019-03-28  Carlos Garcia Campos  <cgarcia@igalia.com>
1920
1921         [FreeType] Incorrect application of glyph positioning in the Y direction
1922         https://bugs.webkit.org/show_bug.cgi?id=161493
1923
1924         Reviewed by Michael Catanzaro.
1925
1926         Use the first glyph origin as the initial advance of every complex text run.
1927
1928         * platform/graphics/cairo/FontCairo.cpp:
1929         (WebCore::FontCascade::drawGlyphs): Update the yOffset using the height advance.
1930         * platform/graphics/cairo/GraphicsContextImplCairo.cpp:
1931         (WebCore::GraphicsContextImplCairo::drawGlyphs): Ditto.
1932         * platform/graphics/harfbuzz/ComplexTextControllerHarfBuzz.cpp:
1933         (WebCore::ComplexTextController::ComplexTextRun::ComplexTextRun): Set the initial advance.
1934
1935 2019-03-27  Ryosuke Niwa  <rniwa@webkit.org>
1936
1937         [macOS] Select element doesn't show popup if select element had lost focus while popup was previosuly shown
1938         https://bugs.webkit.org/show_bug.cgi?id=196336
1939
1940         Reviewed by Tim Horton.
1941
1942         * rendering/RenderMenuList.cpp:
1943         (RenderMenuList::popupDidHide): Added a comment.
1944
1945 2019-03-27  Justin Fan  <justin_fan@apple.com>
1946
1947         [Web GPU] Standardize Web GPU object reference counting and creation logic
1948         https://bugs.webkit.org/show_bug.cgi?id=196183
1949
1950         Reviewed by Dean Jackson.
1951
1952         Make getters return raw refs/pointers and provide const versions if necessary.
1953         All Web GPU objects are non-nullable, but become no-op if invalid, and descriptors are not moved unless needed.
1954
1955         No new tests; no change in behavior.
1956
1957         Getter updates and const qualifications:
1958         * Modules/webgpu/WebGPUAdapter.h:
1959         (WebCore::WebGPUAdapter::options const):
1960         * Modules/webgpu/WebGPUBindGroup.h:
1961         (WebCore::WebGPUBindGroup::bindGroup):
1962         (WebCore::WebGPUBindGroup::bindGroup const): Deleted.
1963         * Modules/webgpu/WebGPUBindGroupDescriptor.cpp:
1964         (WebCore::WebGPUBindGroupDescriptor::tryCreateGPUBindGroupDescriptor const):
1965         * Modules/webgpu/WebGPUBindGroupDescriptor.h:
1966         * Modules/webgpu/WebGPUBindGroupLayout.h:
1967         (WebCore::WebGPUBindGroupLayout::bindGroupLayout const):
1968         * Modules/webgpu/WebGPUBuffer.h:
1969         (WebCore::WebGPUBuffer::buffer):
1970         (WebCore::WebGPUBuffer::buffer const):
1971         * Modules/webgpu/WebGPURenderPassDescriptor.cpp:
1972         (WebCore::WebGPURenderPassDescriptor::tryCreateGPURenderPassDescriptor const):
1973         * Modules/webgpu/WebGPURenderPassEncoder.cpp:
1974         (WebCore::WebGPURenderPassEncoder::setVertexBuffers):
1975         * Modules/webgpu/WebGPUSampler.h:
1976         (WebCore::WebGPUSampler::sampler const):
1977         * Modules/webgpu/WebGPUSwapChain.h:
1978         (WebCore::WebGPUSwapChain::swapChain):
1979         (WebCore::WebGPUSwapChain::swapChain const): Deleted.
1980         * Modules/webgpu/WebGPUTexture.h:
1981         (WebCore::WebGPUTexture::texture):
1982         (WebCore::WebGPUTexture::texture const): Deleted.
1983         * Modules/webgpu/WebGPUTextureView.h:
1984         (WebCore::WebGPUTextureView::texture):
1985         (WebCore::WebGPUTextureView::texture const): Deleted.
1986         * platform/graphics/gpu/GPUBindGroupBinding.h:
1987         * platform/graphics/gpu/GPUBindGroupDescriptor.h:
1988         * platform/graphics/gpu/cocoa/GPUBindGroupMetal.mm:
1989         (WebCore::tryGetResourceAsMTLSamplerState):
1990
1991         Web GPU object creation logic:
1992         * Modules/webgpu/WebGPUCommandEncoder.cpp:
1993         (WebCore::WebGPUBufferCopyView::tryCreateGPUBufferCopyView const):
1994         (WebCore::WebGPUTextureCopyView::tryCreateGPUTextureCopyView const):
1995         (WebCore::WebGPUCommandEncoder::beginRenderPass):
1996         (WebCore::WebGPUCommandEncoder::copyBufferToBuffer):
1997         * Modules/webgpu/WebGPUCommandEncoder.h:
1998         * Modules/webgpu/WebGPUDevice.cpp:
1999         (WebCore::WebGPUDevice::createBuffer const):
2000         (WebCore::WebGPUDevice::createTexture const):
2001         (WebCore::WebGPUDevice::createPipelineLayout const):
2002         (WebCore::WebGPUDevice::createBindGroup const):
2003         (WebCore::WebGPUDevice::createShaderModule const):
2004         (WebCore::WebGPUDevice::createRenderPipeline const):
2005         (WebCore::WebGPUDevice::getQueue const):
2006         * Modules/webgpu/WebGPUDevice.h:
2007         * Modules/webgpu/WebGPUPipelineLayout.cpp:
2008         (WebCore::WebGPUPipelineLayout::create):
2009         (WebCore::WebGPUPipelineLayout::WebGPUPipelineLayout):
2010         * Modules/webgpu/WebGPUPipelineLayout.h:
2011         (WebCore::WebGPUPipelineLayout::pipelineLayout):
2012         * Modules/webgpu/WebGPUPipelineLayoutDescriptor.cpp: 
2013         (WebCore::WebGPUPipelineLayoutDescriptor::tryCreateGPUPipelineLayoutDescriptor const):
2014         * Modules/webgpu/WebGPUPipelineLayoutDescriptor.h:
2015         * Modules/webgpu/WebGPUQueue.cpp:
2016         (WebCore::WebGPUQueue::create):
2017         (WebCore::WebGPUQueue::WebGPUQueue):
2018         (WebCore::WebGPUQueue::submit):
2019         * Modules/webgpu/WebGPUQueue.h:
2020         * Modules/webgpu/WebGPUShaderModule.cpp:
2021         (WebCore::WebGPUShaderModule::create):
2022         (WebCore::WebGPUShaderModule::WebGPUShaderModule):
2023         * Modules/webgpu/WebGPUShaderModule.h:
2024         (WebCore::WebGPUShaderModule::module const):
2025         * platform/graphics/gpu/GPUBuffer.h:
2026         * platform/graphics/gpu/GPUDevice.cpp:
2027         (WebCore::GPUDevice::tryCreateBuffer):
2028         (WebCore::GPUDevice::tryCreateTexture const):
2029         (WebCore::GPUDevice::tryCreateShaderModule const):
2030         (WebCore::GPUDevice::tryCreateRenderPipeline const):
2031         (WebCore::GPUDevice::tryGetQueue const):
2032         (WebCore::GPUDevice::createShaderModule const): Deleted.
2033         (WebCore::GPUDevice::createRenderPipeline const): Deleted.
2034         (WebCore::GPUDevice::getQueue const): Deleted.
2035         * platform/graphics/gpu/GPUDevice.h:
2036         * platform/graphics/gpu/GPUPipelineLayout.cpp:
2037         (WebCore::GPUPipelineLayout::create):
2038         (WebCore::GPUPipelineLayout::GPUPipelineLayout):
2039         * platform/graphics/gpu/GPUPipelineLayout.h:
2040         (WebCore::GPUPipelineLayout::bindGroupLayouts const):
2041         * platform/graphics/gpu/GPUPipelineLayoutDescriptor.h:
2042         * platform/graphics/gpu/GPURenderPipeline.h:
2043         * platform/graphics/gpu/GPUShaderModule.h:
2044         * platform/graphics/gpu/cocoa/GPUBufferMetal.mm:
2045         (WebCore::GPUBuffer::tryCreate):
2046         (WebCore::GPUBuffer::GPUBuffer):
2047         (WebCore::GPUBuffer::setSubData):
2048         * platform/graphics/gpu/cocoa/GPUCommandBufferMetal.mm:
2049         (WebCore::GPUCommandBuffer::tryCreate):
2050         * platform/graphics/gpu/cocoa/GPUDeviceMetal.mm:
2051         (WebCore::GPUDevice::tryCreate):
2052         * platform/graphics/gpu/cocoa/GPURenderPipelineMetal.mm:
2053         (WebCore::GPURenderPipeline::tryCreate):
2054         (WebCore::GPURenderPipeline::GPURenderPipeline):
2055         (WebCore::GPURenderPipeline::create): Deleted.
2056         * platform/graphics/gpu/cocoa/GPUShaderModuleMetal.mm:
2057         (WebCore::GPUShaderModule::tryCreate):
2058         (WebCore::GPUShaderModule::create): Deleted.
2059
2060         Add WebGPUPipelineLayoutDescriptor.cpp to project:
2061         * Sources.txt:
2062         * WebCore.xcodeproj/project.pbxproj:
2063         
2064 2019-03-27  Shawn Roberts  <sroberts@apple.com>
2065
2066         Unreviewed, rolling out r243346.
2067
2068         Causing timeouts in animation tests across 10 builds
2069
2070         Reverted changeset:
2071
2072         "[Web Animations] JS wrapper may be deleted while animation is
2073         yet to dispatch its finish event"
2074         https://bugs.webkit.org/show_bug.cgi?id=196118
2075         https://trac.webkit.org/changeset/243346
2076
2077 2019-03-27  Zalan Bujtas  <zalan@apple.com>
2078
2079         [ContentChangeObserver] Stop using the global _WKContentChange
2080         https://bugs.webkit.org/show_bug.cgi?id=196288
2081         <rdar://problem/49228081>
2082
2083         Reviewed by Simon Fraser.
2084
2085         This patch ensures that activities on frames don't overwrite the observed state on other frames.  
2086         (Unfortunately the global variable is still used in WebKitLegacy (see webkit.org/b/196286)).
2087
2088         Tests: fast/events/touch/ios/content-observation/remove-subframe-while-observing.html
2089                fast/events/touch/ios/content-observation/subframe.html
2090
2091         * page/ios/ContentChangeObserver.cpp:
2092         (WebCore::ContentChangeObserver::observedContentChange const): Deleted.
2093         * page/ios/ContentChangeObserver.h:
2094         (WebCore::ContentChangeObserver::observedContentChange const):
2095         (WebCore::ContentChangeObserver::setHasNoChangeState):
2096         (WebCore::ContentChangeObserver::setHasIndeterminateState):
2097         (WebCore::ContentChangeObserver::setHasVisibleChangeState):
2098         (WebCore::ContentChangeObserver::setObservedContentState):
2099
2100 2019-03-27  Said Abou-Hallawa  <sabouhallawa@apple.com>
2101
2102         Remove the SVG tear off objects for SVGPathSeg, SVGPathSegList and SVGAnimatedPathSegList
2103         https://bugs.webkit.org/show_bug.cgi?id=196085
2104
2105         Reviewed by Simon Fraser.
2106
2107         The SVGPathSegList is similar to the other SVGLists, e.g. SVGNUmberList
2108         and SVGPointList except in two things:
2109
2110         1. Its items can be different but they are derived from the same base 
2111            class SVGPathSeg.
2112
2113         2. The SVGPathSeg items are only used for DOM. When drawing or animating
2114            we have to have an SVGPathByteStream and convert it to a Path. Converting
2115            an SVGPathByteStream to SVGPathSeg items and vice versa is expensive.
2116            Building a Path from an SVGPathByteStream is also expensive. So an extra
2117            care needs to be taken for when these conversions happen.
2118
2119         In addition to handling the SVGPathSeg items, SVGPathSegList will manage
2120         the associated SVGPathByteStream and Path objects. SVGPathSegList will be
2121         lazy in getting updated objects when a change happens. For example, when
2122         the byte stream changes, SVGPathSegList will clear its items and nullify
2123         the Path object. But it will not build any of them until they are explicitly
2124         requested.
2125
2126         Like what was done for other SVG properties when removing their tear off
2127         objects, a new accessor, a new animator and a new animation function will
2128         be added for the SVGAnimatedPathSegList.
2129
2130         All the header files of the concrete classes of SVGPathSeg will be removed
2131         because they are small structures which hold some data items and they provide
2132         setters and getters for these items. Here is the new file structures and
2133         their contents:
2134
2135         -- SVGPathSeg.h still has the class SVGPathSeg which is now a superclass
2136            of SVGProperty. 
2137
2138         -- SVGPathSegValue.h will have the template class SVGPathSegValue which 
2139            holds an std::tuple of packed arguments. It provides setters and getters
2140            for these arguments. SVGPathSegValue.h will also have specialized 
2141            classed derived from SVGPathSegValue and hold different arguments.
2142
2143         -- SVGPathSegImpl.h will have the final concrete SVGPathSeg classes.
2144
2145         Note SVGPathSeg concrete classes do not need to have a reference to the
2146         the context SVGPathElement. SVGPathSeg will be owned by its SVGPathSegList
2147         which will be owned by the SVGAnimatedPathSegList which will be owned by
2148         the SVGPathElement.
2149
2150         * Sources.txt:
2151         * WebCore.xcodeproj/project.pbxproj:
2152         * bindings/js/JSSVGPathSegCustom.cpp:
2153         * bindings/scripts/CodeGenerator.pm:
2154         (IsSVGPathSegTypeName):
2155         (IsSVGPathSegType):
2156         * bindings/scripts/CodeGeneratorJS.pm:
2157         (GenerateHeader):
2158         * rendering/svg/SVGPathData.cpp:
2159         (WebCore::pathFromPathElement):
2160         * svg/SVGAnimatedPath.cpp: Removed.
2161         * svg/SVGAnimatedPath.h: Removed.
2162         * svg/SVGAnimatedType.h:
2163         (WebCore::SVGAnimatedType::type const):
2164         * svg/SVGAnimatorFactory.h:
2165         (WebCore::SVGAnimatorFactory::create):
2166         * svg/SVGPathByteStream.h:
2167         (WebCore::SVGPathByteStream::SVGPathByteStream):
2168         This constructor is used by SVGAnimationPathSegListFunction to convert
2169         the 'form', 'to' and 'toAtEndOfDuration' strings to SVGPathByteStreams.
2170
2171         (WebCore::SVGPathByteStream::resize): Deleted.
2172         (WebCore::SVGPropertyTraits<SVGPathByteStream>::initialValue): Deleted.
2173         (WebCore::SVGPropertyTraits<SVGPathByteStream>::fromString): Deleted.
2174         (WebCore::SVGPropertyTraits<SVGPathByteStream>::parse): Deleted.
2175         (WebCore::SVGPropertyTraits<SVGPathByteStream>::toString): Deleted.
2176         * svg/SVGPathElement.cpp:
2177         (WebCore::SVGPathElement::SVGPathElement):
2178         (WebCore::SVGPathElement::parseAttribute):
2179         (WebCore::SVGPathElement::svgAttributeChanged):
2180         (WebCore::SVGPathElement::getTotalLength const):
2181         (WebCore::SVGPathElement::getPointAtLength const):
2182         (WebCore::SVGPathElement::getPathSegAtLength const):
2183         (WebCore::SVGPathElement::createSVGPathSegClosePath): Deleted.
2184         (WebCore::SVGPathElement::createSVGPathSegMovetoAbs): Deleted.
2185         (WebCore::SVGPathElement::createSVGPathSegMovetoRel): Deleted.
2186         (WebCore::SVGPathElement::createSVGPathSegLinetoAbs): Deleted.
2187         (WebCore::SVGPathElement::createSVGPathSegLinetoRel): Deleted.
2188         (WebCore::SVGPathElement::createSVGPathSegCurvetoCubicAbs): Deleted.
2189         (WebCore::SVGPathElement::createSVGPathSegCurvetoCubicRel): Deleted.
2190         (WebCore::SVGPathElement::createSVGPathSegCurvetoQuadraticAbs): Deleted.
2191         (WebCore::SVGPathElement::createSVGPathSegCurvetoQuadraticRel): Deleted.
2192         (WebCore::SVGPathElement::createSVGPathSegArcAbs): Deleted.
2193         (WebCore::SVGPathElement::createSVGPathSegArcRel): Deleted.
2194         (WebCore::SVGPathElement::createSVGPathSegLinetoHorizontalAbs): Deleted.
2195         (WebCore::SVGPathElement::createSVGPathSegLinetoHorizontalRel): Deleted.
2196         (WebCore::SVGPathElement::createSVGPathSegLinetoVerticalAbs): Deleted.
2197         (WebCore::SVGPathElement::createSVGPathSegLinetoVerticalRel): Deleted.
2198         (WebCore::SVGPathElement::createSVGPathSegCurvetoCubicSmoothAbs): Deleted.
2199         (WebCore::SVGPathElement::createSVGPathSegCurvetoCubicSmoothRel): Deleted.
2200         (WebCore::SVGPathElement::createSVGPathSegCurvetoQuadraticSmoothAbs): Deleted.
2201         (WebCore::SVGPathElement::createSVGPathSegCurvetoQuadraticSmoothRel): Deleted.
2202         The SVGPathSeg creation functions are moved to the header file.
2203
2204         (WebCore::SVGPathElement::registerAttributes): Deleted.
2205         (WebCore::SVGPathElement::pathByteStream const): Deleted.
2206         (WebCore::SVGPathElement::pathForByteStream const): Deleted.
2207         (WebCore::SVGPathElement::lookupOrCreateDWrapper): Deleted.
2208         (WebCore::SVGPathElement::animatedPropertyWillBeDeleted): Deleted.
2209         (WebCore::SVGPathElement::pathSegList): Deleted.
2210         (WebCore::SVGPathElement::normalizedPathSegList): Deleted.
2211         (WebCore::SVGPathElement::animatedPathSegList): Deleted.
2212         (WebCore::SVGPathElement::animatedNormalizedPathSegList): Deleted.
2213         (WebCore::SVGPathElement::approximateMemoryCost const): Deleted.
2214         (WebCore::SVGPathElement::pathSegListChanged): Deleted.
2215         Managing the SVGPathByteStream and the drawing Path objects will be the
2216         responsibility of SVGPathSegList.
2217
2218         * svg/SVGPathElement.h:
2219         * svg/SVGPathSeg.h:
2220         * svg/SVGPathSegArc.h: Removed.
2221         * svg/SVGPathSegArcAbs.h: Removed.
2222         * svg/SVGPathSegArcRel.h: Removed.
2223         * svg/SVGPathSegClosePath.h: Removed.
2224         * svg/SVGPathSegCurvetoCubic.h: Removed.
2225         * svg/SVGPathSegCurvetoCubicAbs.h: Removed.
2226         * svg/SVGPathSegCurvetoCubicRel.h: Removed.
2227         * svg/SVGPathSegCurvetoCubicSmooth.h: Removed.
2228         * svg/SVGPathSegCurvetoCubicSmoothAbs.h: Removed.
2229         * svg/SVGPathSegCurvetoCubicSmoothRel.h: Removed.
2230         * svg/SVGPathSegCurvetoQuadratic.h: Removed.
2231         * svg/SVGPathSegCurvetoQuadraticAbs.h: Removed.
2232         * svg/SVGPathSegCurvetoQuadraticRel.h: Removed.
2233         * svg/SVGPathSegCurvetoQuadraticSmoothAbs.h: Removed.
2234         * svg/SVGPathSegCurvetoQuadraticSmoothRel.h: Removed.
2235         * svg/SVGPathSegImpl.h: Added.
2236         * svg/SVGPathSegLinetoAbs.h: Removed.
2237         * svg/SVGPathSegLinetoHorizontal.h: Removed.
2238         * svg/SVGPathSegLinetoHorizontalAbs.h: Removed.
2239         * svg/SVGPathSegLinetoHorizontalRel.h: Removed.
2240         * svg/SVGPathSegLinetoRel.h: Removed.
2241         * svg/SVGPathSegLinetoVertical.h: Removed.
2242         * svg/SVGPathSegLinetoVerticalAbs.h: Removed.
2243         * svg/SVGPathSegLinetoVerticalRel.h: Removed.
2244         The definition of these classes are now in SVGPathSegImpl.h.
2245
2246         * svg/SVGPathSegList.cpp: Removed.
2247         * svg/SVGPathSegList.h:
2248         * svg/SVGPathSegListBuilder.cpp:
2249         (WebCore::SVGPathSegListBuilder::SVGPathSegListBuilder):
2250         (WebCore::SVGPathSegListBuilder::moveTo):
2251         (WebCore::SVGPathSegListBuilder::lineTo):
2252         (WebCore::SVGPathSegListBuilder::lineToHorizontal):
2253         (WebCore::SVGPathSegListBuilder::lineToVertical):
2254         (WebCore::SVGPathSegListBuilder::curveToCubic):
2255         (WebCore::SVGPathSegListBuilder::curveToCubicSmooth):
2256         (WebCore::SVGPathSegListBuilder::curveToQuadratic):
2257         (WebCore::SVGPathSegListBuilder::curveToQuadraticSmooth):
2258         (WebCore::SVGPathSegListBuilder::arcTo):
2259         (WebCore::SVGPathSegListBuilder::closePath):        
2260         * svg/SVGPathSegListBuilder.h:
2261         The concrete SVGPathSeg classes can now create instances of their classes
2262         without having to go through the SVGPathElement.
2263
2264         * svg/SVGPathSegListSource.cpp:
2265         (WebCore::SVGPathSegListSource::SVGPathSegListSource):
2266         * svg/SVGPathSegListSource.h:
2267         * svg/SVGPathSegListValues.cpp: Removed.
2268         * svg/SVGPathSegListValues.h: Removed.
2269         * svg/SVGPathSegMovetoAbs.h: Removed.
2270         * svg/SVGPathSegMovetoRel.h: Removed.
2271         * svg/SVGPathSegValue.h: Added.
2272         (WebCore::SVGPathSegValue::create):
2273         (WebCore::SVGPathSegValue::clone const):
2274         (WebCore::SVGPathSegValue::SVGPathSegValue):
2275         (WebCore::SVGPathSegValue::argument const):
2276         (WebCore::SVGPathSegValue::setArgument):
2277         (WebCore::SVGPathSegLinetoHorizontal::x const):
2278         (WebCore::SVGPathSegLinetoHorizontal::setX):
2279         (WebCore::SVGPathSegLinetoVertical::y const):
2280         (WebCore::SVGPathSegLinetoVertical::setY):
2281         (WebCore::SVGPathSegSingleCoordinate::x const):
2282         (WebCore::SVGPathSegSingleCoordinate::setX):
2283         (WebCore::SVGPathSegSingleCoordinate::y const):
2284         (WebCore::SVGPathSegSingleCoordinate::setY):
2285         (WebCore::SVGPathSegCurvetoQuadratic::x const):
2286         (WebCore::SVGPathSegCurvetoQuadratic::setX):
2287         (WebCore::SVGPathSegCurvetoQuadratic::y const):
2288         (WebCore::SVGPathSegCurvetoQuadratic::setY):
2289         (WebCore::SVGPathSegCurvetoQuadratic::x1 const):
2290         (WebCore::SVGPathSegCurvetoQuadratic::setX1):
2291         (WebCore::SVGPathSegCurvetoQuadratic::y1 const):
2292         (WebCore::SVGPathSegCurvetoQuadratic::setY1):
2293         (WebCore::SVGPathSegCurvetoCubicSmooth::x const):
2294         (WebCore::SVGPathSegCurvetoCubicSmooth::setX):
2295         (WebCore::SVGPathSegCurvetoCubicSmooth::y const):
2296         (WebCore::SVGPathSegCurvetoCubicSmooth::setY):
2297         (WebCore::SVGPathSegCurvetoCubicSmooth::x2 const):
2298         (WebCore::SVGPathSegCurvetoCubicSmooth::setX2):
2299         (WebCore::SVGPathSegCurvetoCubicSmooth::y2 const):
2300         (WebCore::SVGPathSegCurvetoCubicSmooth::setY2):
2301         (WebCore::SVGPathSegCurvetoCubic::x const):
2302         (WebCore::SVGPathSegCurvetoCubic::setX):
2303         (WebCore::SVGPathSegCurvetoCubic::y const):
2304         (WebCore::SVGPathSegCurvetoCubic::setY):
2305         (WebCore::SVGPathSegCurvetoCubic::x1 const):
2306         (WebCore::SVGPathSegCurvetoCubic::setX1):
2307         (WebCore::SVGPathSegCurvetoCubic::y1 const):
2308         (WebCore::SVGPathSegCurvetoCubic::setY1):
2309         (WebCore::SVGPathSegCurvetoCubic::x2 const):
2310         (WebCore::SVGPathSegCurvetoCubic::setX2):
2311         (WebCore::SVGPathSegCurvetoCubic::y2 const):
2312         (WebCore::SVGPathSegCurvetoCubic::setY2):
2313         (WebCore::SVGPathSegArc::x const):
2314         (WebCore::SVGPathSegArc::setX):
2315         (WebCore::SVGPathSegArc::y const):
2316         (WebCore::SVGPathSegArc::setY):
2317         (WebCore::SVGPathSegArc::r1 const):
2318         (WebCore::SVGPathSegArc::setR1):
2319         (WebCore::SVGPathSegArc::r2 const):
2320         (WebCore::SVGPathSegArc::setR2):
2321         (WebCore::SVGPathSegArc::angle const):
2322         (WebCore::SVGPathSegArc::setAngle):
2323         (WebCore::SVGPathSegArc::largeArcFlag const):
2324         (WebCore::SVGPathSegArc::setLargeArcFlag):
2325         (WebCore::SVGPathSegArc::sweepFlag const):
2326         (WebCore::SVGPathSegArc::setSweepFlag):
2327         * svg/SVGPathSegWithContext.h: Removed.
2328
2329         * svg/SVGPathUtilities.cpp:
2330         (WebCore::buildSVGPathByteStreamFromSVGPathSegList):
2331         (WebCore::buildSVGPathSegListFromByteStream):
2332         (WebCore::buildStringFromByteStream):
2333         (WebCore::buildSVGPathByteStreamFromSVGPathSegListValues): Deleted.
2334         (WebCore::appendSVGPathByteStreamFromSVGPathSeg): Deleted.
2335         (WebCore::buildSVGPathSegListValuesFromByteStream): Deleted.
2336         (WebCore::buildStringFromSVGPathSegListValues): Deleted.
2337         * svg/SVGPathUtilities.h:
2338         Since the class SVGPathSegListValues is removed, all the parsing functions
2339         have now to deal with SVGPathSegList directly.
2340
2341         * svg/SVGPoint.h:
2342         * svg/SVGValue.h:
2343         * svg/properties/SVGAnimatedPathSegListPropertyTearOff.cpp: Removed.
2344         * svg/properties/SVGAnimatedPathSegListPropertyTearOff.h: Removed.
2345         * svg/properties/SVGAnimatedPropertyAccessorImpl.h:
2346         * svg/properties/SVGAnimatedPropertyAnimatorImpl.h:
2347         * svg/properties/SVGAnimatedPropertyImpl.h:
2348         (WebCore::SVGAnimatedPathSegList::create):
2349         (WebCore::SVGAnimatedPathSegList::currentPathByteStream):
2350         (WebCore::SVGAnimatedPathSegList::currentPath):
2351         (WebCore::SVGAnimatedPathSegList::approximateMemoryCost const):
2352         Provides an easy way to access the current SVGPathByteStream and Path
2353         objects from the SVGAnimatedPathSegList.
2354
2355         * svg/properties/SVGAnimationAdditiveValueFunctionImpl.h:
2356         (WebCore::SVGAnimationPathSegListFunction::progress):
2357         * svg/properties/SVGPropertyOwnerRegistry.h:
2358         (WebCore::SVGPropertyOwnerRegistry::registerProperty):
2359
2360 2019-03-27  Ryan Haddad  <ryanhaddad@apple.com>
2361
2362         AVAudioSessionRouteSharingPolicyLongForm has been deprecated
2363         https://bugs.webkit.org/show_bug.cgi?id=196301
2364
2365         Unrereivewed build fix.
2366
2367         * platform/audio/ios/AudioSessionIOS.mm:
2368         (WebCore::AudioSession::setCategory):
2369         (WebCore::AudioSession::routeSharingPolicy const):
2370
2371 2019-03-27  Chris Dumez  <cdumez@apple.com>
2372
2373         XMLHttpRequestUpload's loadstart event not correct initialized
2374         https://bugs.webkit.org/show_bug.cgi?id=196174
2375         <rdar://problem/49191412>
2376
2377         Reviewed by Alex Christensen.
2378
2379         Align progress event firing with the XHR specification.
2380
2381         No new tests, rebaselined existing tests.
2382
2383         * xml/XMLHttpRequest.cpp:
2384         (WebCore::XMLHttpRequest::createRequest):
2385         As per [1], the loadstart event fired on the XMLHttpRequestUpload object should use
2386         loaded=0 and total=`req’s body’s total bytes`.
2387         [1] https://xhr.spec.whatwg.org/#the-send()-method (step 11.2.)
2388
2389         (WebCore::XMLHttpRequest::didSendData):
2390         As per [2], the progress / load / loadend should use loaded=transmitted and total=length.
2391         [2] https://xhr.spec.whatwg.org/#ref-for-process-request-end-of-body (steps 5, 6 and 7)
2392
2393         (WebCore::XMLHttpRequest::didReceiveData):
2394         As per [3], we should fire the readystatechange event *before* the progress event.
2395         This is covered by web-platform-tests/xhr/send-response-event-order.htm which was failing
2396         differently after the other changes in this patch.
2397         [3] https://xhr.spec.whatwg.org/#ref-for-process-response (steps 9.4 and 9.5)
2398
2399         (WebCore::XMLHttpRequest::dispatchErrorEvents):
2400         As per [4], in case of an error, we should fire the provided 'event' and 'loadend' with
2401         loaded=0 and total=0.
2402         [4] https://xhr.spec.whatwg.org/#request-error-steps (steps 7 and 8)
2403
2404         * xml/XMLHttpRequestUpload.cpp:
2405         (WebCore::XMLHttpRequestUpload::dispatchProgressEvent):
2406         * xml/XMLHttpRequestUpload.h:
2407         Simplify XMLHttpRequestUpload. It no longer needs to store loaded / total as data
2408         members now that they are always passed by the call site. lengthComputable is set
2409         to !!total as [5] says to set it to true if length/total is not 0. 
2410         [5] https://xhr.spec.whatwg.org/#concept-event-fire-progress
2411
2412 2019-03-27  Simon Fraser  <simon.fraser@apple.com>
2413
2414         REGRESSION (r242687): Fullscreen YouTube videos show blank white space at top
2415         https://bugs.webkit.org/show_bug.cgi?id=196304
2416         rdar://problem/49175760
2417
2418         Reviewed by Zalan Bujtas.
2419
2420         repositionRelatedLayers() should not short-circuit when topContentInset is zero,
2421         because topContentInset might be changing from non-zero to zero, and then we need
2422         to move layers around.
2423
2424         Test: scrollingcoordinator/mac/top-content-inset-to-zero.html
2425
2426         * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm:
2427         (WebCore::ScrollingTreeFrameScrollingNodeMac::repositionRelatedLayers):
2428
2429 2019-03-26  Simon Fraser  <simon.fraser@apple.com>
2430
2431         [iOS WK2] Fixed elements in frames can be misplaced sometimes
2432         https://bugs.webkit.org/show_bug.cgi?id=196290
2433
2434         Reviewed by Frédéric Wang.
2435
2436         In a page containing position:fixed inside an async-scrolling iframe, if the 
2437         main page is scrolled down, and you reload, then the fixed element in the iframe can
2438         get misplaced or disappear.
2439
2440         The bug was that the reconcileViewportConstrainedLayerPositions() recursive state node
2441         walk would cross frame boundaries, hitting subframe ScrollingStateFixedNodes with a viewport rect
2442         for the main page.
2443
2444         Fix by giving ScrollingStateTree the responsibility for the recursive tree walk, and
2445         have it bail at at frame boundaries.
2446
2447         Test: scrollingcoordinator/ios/fixed-in-frame-layer-reconcile-layer-position.html
2448
2449         * page/scrolling/AsyncScrollingCoordinator.cpp:
2450         (WebCore::AsyncScrollingCoordinator::reconcileViewportConstrainedLayerPositions):
2451         * page/scrolling/ScrollingStateFixedNode.cpp:
2452         (WebCore::ScrollingStateFixedNode::reconcileLayerPositionForViewportRect):
2453         * page/scrolling/ScrollingStateNode.cpp:
2454         (WebCore::ScrollingStateNode::reconcileLayerPositionForViewportRect): Deleted.
2455         * page/scrolling/ScrollingStateNode.h:
2456         (WebCore::ScrollingStateNode::reconcileLayerPositionForViewportRect):
2457         * page/scrolling/ScrollingStateStickyNode.cpp:
2458         (WebCore::ScrollingStateStickyNode::reconcileLayerPositionForViewportRect):
2459         * page/scrolling/ScrollingStateTree.cpp:
2460         (WebCore::ScrollingStateTree::reconcileLayerPositionsRecursive):
2461         (WebCore::ScrollingStateTree::reconcileViewportConstrainedLayerPositions):
2462         * page/scrolling/ScrollingStateTree.h:
2463
2464 2019-03-27  Philippe Normand  <pnormand@igalia.com>
2465
2466         Build failure with gstreamer 1.12.5 if USE_GSTREAMER_GL is enabled
2467         https://bugs.webkit.org/show_bug.cgi?id=196178
2468
2469         Reviewed by Xabier Rodriguez-Calvar.
2470
2471         The gst/gl/gl.h header needs to be included before
2472         GraphicsContext3D.h to avoid declaration conflicts with
2473         OpenGLShims.
2474
2475         Based on a patch from Mike Gorse <mgorse@suse.com>
2476
2477         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
2478         (WebCore::GstVideoFrameHolder::GstVideoFrameHolder):
2479
2480 2019-03-27  Philippe Normand  <pnormand@igalia.com>
2481
2482         [GStreamer] Remove the HLS queue buffering query hack
2483         https://bugs.webkit.org/show_bug.cgi?id=196244
2484
2485         Reviewed by Xabier Rodriguez-Calvar.
2486
2487         Because the http src element now provides network statistics to
2488         the player we can now compute an estimation of the data loading in
2489         case the buffering query isn't handled by any element of the
2490         pipeline.
2491
2492         No new tests, existing HLS tests cover this change.
2493
2494         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
2495         (WebCore::MediaPlayerPrivateGStreamer::fillTimerFired):
2496         (WebCore::findHLSQueue): Deleted.
2497         (WebCore::isHLSProgressing): Deleted.
2498
2499 2019-03-26  Said Abou-Hallawa  <sabouhallawa@apple.com>
2500
2501         Unreviewed Windows build fix
2502         https://bugs.webkit.org/show_bug.cgi?id=196083
2503         <rdar://problem/49121836>
2504
2505         * svg/SVGAnimatorFactory.h:
2506         (WebCore::SVGAnimatorFactory::isSupportedAttributeType):
2507
2508 2019-03-26  Wenson Hsieh  <wenson_hsieh@apple.com>
2509
2510         [Cocoa] Refactor some helper functions for building UserAgent strings
2511         https://bugs.webkit.org/show_bug.cgi?id=195990
2512
2513         Reviewed by Brent Fulgham.
2514
2515         Add an optional argument to standardUserAgentWithApplicationName to request the desktop version of the user
2516         agent in Cocoa platforms. Work towards refactoring some codepaths to make the implementation of the "Request
2517         Desktop Site" feature in Safari a bit more straightforward.
2518
2519         No change in behavior.
2520
2521         * platform/UserAgent.h:
2522         * platform/ios/UserAgentIOS.mm:
2523         (WebCore::standardUserAgentWithApplicationName):
2524
2525         The corresponding macOS version is currently hard-coded — the followup bug webkit.org/b/196275 tracks making
2526         this dynamically fetch the paired macOS version when building for iOS.
2527
2528         * platform/mac/UserAgentMac.mm:
2529         (WebCore::standardUserAgentWithApplicationName):
2530
2531 2019-03-26  Said Abou-Hallawa  <said@apple.com>
2532
2533         Remove the SVG tear off objects for SVGLength, SVGLengthList and SVGAnimatedLengthList
2534         https://bugs.webkit.org/show_bug.cgi?id=196083
2535
2536         Reviewed by Simon Fraser.
2537
2538         -- SVGLength will be a superclass of SVGValueProperty<SVGLengthValue>. It
2539            is a wrapper of SVGLengthValue. It will be provide the DOM methods. It
2540            can setValueAsString() and return valueAsString().
2541
2542         -- SVGLengthList will be a superclass of SVGValuePropertyList<SVGLength>.
2543            The base class will provide all the DOM methods. SVGLengthList will be
2544            responsible for parsing a String to a SVGLength items. It can also 
2545            build a string representing the stored items.
2546
2547         -- SVGAnimatedLengthList will be defined as SVGAnimatedPropertyList<SVGLengthList>.
2548            Like SVGAnimatedPointList, all the required methods and attributes
2549            will be handled by SVGAnimatedPropertyList.
2550
2551         -- SVGAnimatedLengthAccessor and SVGAnimatedLengthListAccessor will be
2552            added to access the members of types SVGAnimatedLength and 
2553            SVGAnimatedLengthList.
2554
2555         -- SVGAnimatedLengthAnimator and SVGAnimatedLengthListAnimator will be
2556            created by the the new accessors to animate attributes of types
2557            SVGAnimatedLength and SVGAnimatedLengthList.
2558
2559         -- SVGAnimationLengthFunction and SVGAnimationLengthListFunction will be
2560            responsible for progressing the animVal() of attributes of types
2561            SVGAnimatedLength and SVGAnimatedLengthList.
2562
2563         -- SVGValuePropertyAnimator is a new template class which can animate a
2564            none reflecting attribute which should be backed by a value property,
2565            e.g. SVGLength.
2566
2567         -- SVGValuePropertyListAnimator is a new template class which can animate a
2568            none reflecting attribute which should be backed by a value property
2569            list, e.g. SVGLengthList.
2570
2571         Notes:
2572
2573             -- SVGElement::isAnimatedStyleAttribute() will return true if the
2574                attribute is known by SVGPropertyAnimatorFactory. Or it's has 
2575                a reflecting SVGAnimatedPropertyLength property and its name is
2576                one of the names listed in isAnimatedStylePropertyAttribute() of
2577                the propertyRegistry() of the SVGElement.
2578
2579             -- SVGElement::commitPropertyChange() has to handle the attributes
2580                for which isAnimatedStylePropertyAttribute() returns true different
2581                from the other ones. styleReclac() needs updated attributes since
2582                it does not access the reflecting properties in the SVGELement.
2583
2584             -- SVGTextContentElement does not need a customized SVGAnimatedLength.
2585                All SVGTextContentElement::textLengthAnimated() needs to know is
2586                whether m_textLength->baseVal() holds an empty SVGLength. If it
2587                does, it sets its value to getComputedTextLength().
2588
2589         * Sources.txt:
2590         * WebCore.xcodeproj/project.pbxproj:
2591         * rendering/svg/SVGTextLayoutAttributesBuilder.cpp:
2592         (WebCore::updateCharacterData):
2593         (WebCore::SVGTextLayoutAttributesBuilder::fillCharacterDataMap):
2594         * svg/SVGAnimateElementBase.cpp:
2595         (WebCore::SVGAnimateElementBase::hasValidAttributeType const):
2596         * svg/SVGAnimatedLength.cpp: Removed.
2597         * svg/SVGAnimatedLength.h: Removed.
2598         * svg/SVGAnimatedLengthList.cpp: Removed.
2599         * svg/SVGAnimatedLengthList.h: Removed.
2600         * svg/SVGAnimatedType.h:
2601         (WebCore::SVGAnimatedType::type const):
2602         * svg/SVGAnimationElement.cpp:
2603         (WebCore::SVGAnimationElement::isTargetAttributeCSSProperty):
2604         (WebCore::inheritsFromProperty):
2605         * svg/SVGAnimatorFactory.h:
2606         (WebCore::SVGAnimatorFactory::isSupportedAttribute):
2607         (WebCore::SVGAnimatorFactory::create):
2608         These changes were required because some of the tests were trying to
2609         animated unsupported attributes. To differentiate between between the
2610         these two cases:
2611             1) the attribute is animate-able by the legacy controller.
2612             2) animating the attribute or the attribute itself is not supported
2613                by the element.
2614
2615         We want SVGAnimatorFactory tell us whether it can create an animator for
2616         a given attribute or not.
2617
2618         * svg/SVGCircleElement.cpp:
2619         (WebCore::SVGCircleElement::SVGCircleElement):
2620         (WebCore::SVGCircleElement::parseAttribute):
2621         (WebCore::SVGCircleElement::svgAttributeChanged):
2622         (WebCore::SVGCircleElement::registerAttributes): Deleted.
2623         * svg/SVGCircleElement.h:
2624         * svg/SVGCursorElement.cpp:
2625         (WebCore::SVGCursorElement::SVGCursorElement):
2626         (WebCore::SVGCursorElement::parseAttribute):
2627         (WebCore::SVGCursorElement::svgAttributeChanged):
2628         (WebCore::SVGCursorElement::registerAttributes): Deleted.
2629         * svg/SVGCursorElement.h:
2630         * svg/SVGElement.cpp:
2631         (WebCore::SVGElement::commitPropertyChange):
2632         (WebCore::SVGElement::isAnimatedStyleAttribute const):
2633         * svg/SVGElement.h:
2634         * svg/SVGEllipseElement.cpp:
2635         (WebCore::SVGEllipseElement::SVGEllipseElement):
2636         (WebCore::SVGEllipseElement::parseAttribute):
2637         (WebCore::SVGEllipseElement::svgAttributeChanged):
2638         (WebCore::SVGEllipseElement::registerAttributes): Deleted.
2639         * svg/SVGEllipseElement.h:
2640         * svg/SVGFilterElement.cpp:
2641         (WebCore::SVGFilterElement::SVGFilterElement):
2642         (WebCore::SVGFilterElement::registerAttributes):
2643         (WebCore::SVGFilterElement::parseAttribute):
2644         * svg/SVGFilterElement.h:
2645         * svg/SVGFilterPrimitiveStandardAttributes.cpp:
2646         (WebCore::SVGFilterPrimitiveStandardAttributes::SVGFilterPrimitiveStandardAttributes):
2647         (WebCore::SVGFilterPrimitiveStandardAttributes::parseAttribute):
2648         (WebCore::SVGFilterPrimitiveStandardAttributes::registerAttributes): Deleted.
2649         * svg/SVGFilterPrimitiveStandardAttributes.h:
2650         (WebCore::SVGFilterPrimitiveStandardAttributes::x const):
2651         (WebCore::SVGFilterPrimitiveStandardAttributes::y const):
2652         (WebCore::SVGFilterPrimitiveStandardAttributes::width const):
2653         (WebCore::SVGFilterPrimitiveStandardAttributes::height const):
2654         (WebCore::SVGFilterPrimitiveStandardAttributes::xAnimated):
2655         (WebCore::SVGFilterPrimitiveStandardAttributes::yAnimated):
2656         (WebCore::SVGFilterPrimitiveStandardAttributes::widthAnimated):
2657         (WebCore::SVGFilterPrimitiveStandardAttributes::heightAnimated):
2658         (WebCore::SVGFilterPrimitiveStandardAttributes::isKnownAttribute): Deleted.
2659         * svg/SVGForeignObjectElement.cpp:
2660         (WebCore::SVGForeignObjectElement::SVGForeignObjectElement):
2661         (WebCore::SVGForeignObjectElement::parseAttribute):
2662         (WebCore::SVGForeignObjectElement::registerAttributes): Deleted.
2663         * svg/SVGForeignObjectElement.h:
2664         * svg/SVGImageElement.cpp:
2665         (WebCore::SVGImageElement::SVGImageElement):
2666         (WebCore::SVGImageElement::parseAttribute):
2667         (WebCore::SVGImageElement::registerAttributes): Deleted.
2668         * svg/SVGImageElement.h:
2669         * svg/SVGLength.h:
2670         (WebCore::SVGLength::create):
2671         (WebCore::SVGLength::clone const):
2672         (WebCore::SVGLength::unitType):
2673         (WebCore::SVGLength::valueForBindings):
2674         (WebCore::SVGLength::setValueForBindings):
2675         (WebCore::SVGLength::valueInSpecifiedUnits):
2676         (WebCore::SVGLength::setValueInSpecifiedUnits):
2677         (WebCore::SVGLength::setValueAsString):
2678         (WebCore::SVGLength::newValueSpecifiedUnits):
2679         (WebCore::SVGLength::convertToSpecifiedUnits):
2680         (WebCore::SVGLength::valueAsString): Deleted.
2681         (WebCore::SVGLength::SVGLength): Deleted.
2682         * svg/SVGLengthList.h:
2683         (WebCore::SVGLengthList::create):
2684         (WebCore::SVGLengthList::lengthMode const):
2685         (WebCore::SVGLengthList::parse):
2686         (WebCore::SVGLengthList::SVGLengthList):
2687         * svg/SVGLengthListValues.cpp: Removed.
2688         * svg/SVGLengthListValues.h: Removed.
2689         * svg/SVGLineElement.cpp:
2690         (WebCore::SVGLineElement::SVGLineElement):
2691         (WebCore::SVGLineElement::parseAttribute):
2692         (WebCore::SVGLineElement::svgAttributeChanged):
2693         (WebCore::SVGLineElement::registerAttributes): Deleted.
2694         * svg/SVGLineElement.h:
2695         * svg/SVGLinearGradientElement.cpp:
2696         (WebCore::SVGLinearGradientElement::SVGLinearGradientElement):
2697         (WebCore::SVGLinearGradientElement::parseAttribute):
2698         (WebCore::SVGLinearGradientElement::svgAttributeChanged):
2699         (WebCore::SVGLinearGradientElement::registerAttributes): Deleted.
2700         * svg/SVGLinearGradientElement.h:
2701         * svg/SVGMarkerElement.cpp:
2702         (WebCore::SVGMarkerElement::SVGMarkerElement):
2703         (WebCore::SVGMarkerElement::registerAttributes):
2704         (WebCore::SVGMarkerElement::parseAttribute):
2705         * svg/SVGMarkerElement.h:
2706         * svg/SVGMaskElement.cpp:
2707         (WebCore::SVGMaskElement::SVGMaskElement):
2708         (WebCore::SVGMaskElement::registerAttributes):
2709         (WebCore::SVGMaskElement::parseAttribute):
2710         (WebCore::SVGMaskElement::svgAttributeChanged):
2711         * svg/SVGMaskElement.h:
2712         * svg/SVGPatternElement.cpp:
2713         (WebCore::SVGPatternElement::SVGPatternElement):
2714         (WebCore::SVGPatternElement::registerAttributes):
2715         (WebCore::SVGPatternElement::parseAttribute):
2716         * svg/SVGPatternElement.h:
2717         * svg/SVGPoint.h:
2718         * svg/SVGRadialGradientElement.cpp:
2719         (WebCore::SVGRadialGradientElement::SVGRadialGradientElement):
2720         (WebCore::SVGRadialGradientElement::parseAttribute):
2721         (WebCore::SVGRadialGradientElement::svgAttributeChanged):
2722         (WebCore::SVGRadialGradientElement::registerAttributes): Deleted.
2723         * svg/SVGRadialGradientElement.h:
2724         * svg/SVGRectElement.cpp:
2725         (WebCore::SVGRectElement::SVGRectElement):
2726         (WebCore::SVGRectElement::parseAttribute):
2727         (WebCore::SVGRectElement::svgAttributeChanged):
2728         (WebCore::SVGRectElement::registerAttributes): Deleted.
2729         * svg/SVGRectElement.h:
2730         * svg/SVGSVGElement.cpp:
2731         (WebCore::SVGSVGElement::SVGSVGElement):
2732         (WebCore::SVGSVGElement::parseAttribute):
2733         (WebCore::SVGSVGElement::svgAttributeChanged):
2734         (WebCore::SVGSVGElement::registerAttributes): Deleted.
2735         * svg/SVGSVGElement.h:
2736         * svg/SVGTextContentElement.cpp:
2737         (WebCore::SVGTextContentElement::SVGTextContentElement):
2738         (WebCore::SVGTextContentElement::registerAttributes):
2739         (WebCore::SVGTextContentElement::parseAttribute):
2740         (WebCore::SVGTextContentElement::svgAttributeChanged):
2741         (WebCore::SVGTextContentElement::textLengthAnimated):
2742         * svg/SVGTextContentElement.h:
2743         (WebCore::SVGTextContentElement::specifiedTextLength const):
2744         (WebCore::SVGTextContentElement::textLength const):
2745         (WebCore::SVGTextContentElement::specifiedTextLength): Deleted.
2746         (WebCore::SVGTextContentElement::textLengthAnimated): Deleted.
2747         (WebCore::SVGTextContentElement::SVGAnimatedCustomLengthAttribute::SVGAnimatedCustomLengthAttribute): Deleted.
2748         (WebCore::SVGTextContentElement::SVGAnimatedCustomLengthAttribute::synchronize): Deleted.
2749         (WebCore::SVGTextContentElement::SVGAnimatedCustomLengthAttribute::animatedProperty): Deleted.
2750         * svg/SVGTextPathElement.cpp:
2751         (WebCore::SVGTextPathElement::SVGTextPathElement):
2752         (WebCore::SVGTextPathElement::registerAttributes):
2753         (WebCore::SVGTextPathElement::parseAttribute):
2754         * svg/SVGTextPathElement.h:
2755         * svg/SVGTextPositioningElement.cpp:
2756         (WebCore::SVGTextPositioningElement::SVGTextPositioningElement):
2757         (WebCore::SVGTextPositioningElement::parseAttribute):
2758         (WebCore::SVGTextPositioningElement::svgAttributeChanged):
2759         (WebCore::SVGTextPositioningElement::registerAttributes): Deleted.
2760         * svg/SVGTextPositioningElement.h:
2761         (WebCore::SVGTextPositioningElement::x const):
2762         (WebCore::SVGTextPositioningElement::y const):
2763         (WebCore::SVGTextPositioningElement::dx const):
2764         (WebCore::SVGTextPositioningElement::dy const):
2765         (WebCore::SVGTextPositioningElement::xAnimated):
2766         (WebCore::SVGTextPositioningElement::yAnimated):
2767         (WebCore::SVGTextPositioningElement::dxAnimated):
2768         (WebCore::SVGTextPositioningElement::dyAnimated):
2769         (WebCore::SVGTextPositioningElement::isKnownAttribute): Deleted.
2770         * svg/SVGUseElement.cpp:
2771         (WebCore::SVGUseElement::SVGUseElement):
2772         (WebCore::SVGUseElement::parseAttribute):
2773         (WebCore::SVGUseElement::svgAttributeChanged):
2774         (WebCore::SVGUseElement::registerAttributes): Deleted.
2775         * svg/SVGUseElement.h:
2776         * svg/SVGValue.h:
2777         * svg/properties/SVGAnimatedPropertyAccessorImpl.h:
2778         * svg/properties/SVGAnimatedPropertyAnimator.h:
2779         * svg/properties/SVGAnimatedPropertyAnimatorImpl.h:
2780         * svg/properties/SVGAnimatedPropertyImpl.h:
2781         * svg/properties/SVGAnimationAdditiveListFunctionImpl.h:
2782         (WebCore::SVGAnimationLengthListFunction::SVGAnimationLengthListFunction):
2783         (WebCore::SVGAnimationLengthListFunction::progress):
2784         (WebCore::SVGAnimationNumberListFunction::progress):
2785         (WebCore::SVGAnimationPointListFunction::progress):
2786         * svg/properties/SVGAnimationAdditiveValueFunctionImpl.h:
2787         (WebCore::SVGAnimationLengthFunction::SVGAnimationLengthFunction):
2788         (WebCore::SVGAnimationLengthFunction::progress):
2789         * svg/properties/SVGAttributeAnimator.cpp:
2790         (WebCore::SVGAttributeAnimator::isAnimatedStylePropertyAniamtor const):
2791         * svg/properties/SVGAttributeAnimator.h:
2792         * svg/properties/SVGAttributeRegistry.h:
2793         * svg/properties/SVGPropertyAnimatorFactory.h:
2794         (WebCore::SVGPropertyAnimatorFactory::createLengthAnimator):
2795         (WebCore::SVGPropertyAnimatorFactory::createLengthListAnimator):
2796         (WebCore::SVGPropertyAnimatorFactory::attributeAnimatorCreator):
2797         * svg/properties/SVGPropertyOwnerRegistry.h:
2798         (WebCore::SVGPropertyOwnerRegistry::registerProperty):
2799         (WebCore::SVGPropertyOwnerRegistry::isAnimatedLengthAttribute):
2800         * svg/properties/SVGPropertyRegistry.h:
2801         * svg/properties/SVGValuePropertyAnimator.h: Added.
2802         (WebCore::SVGValuePropertyAnimator::SVGValuePropertyAnimator):
2803         * svg/properties/SVGValuePropertyAnimatorImpl.h: Added.
2804         * svg/properties/SVGValuePropertyListAnimator.h: Added.
2805         (WebCore::SVGValuePropertyListAnimator::SVGValuePropertyListAnimator):
2806         * svg/properties/SVGValuePropertyListAnimatorImpl.h: Added.
2807
2808 2019-03-26  Simon Fraser  <simon.fraser@apple.com>
2809
2810         [iOS WK2] position:fixed inside oveflow:scroll is jumpy
2811         https://bugs.webkit.org/show_bug.cgi?id=196238
2812
2813         Reviewed by Antti Koivisto.
2814         
2815         We were inadvertently making Positioned nodes for position:fixed, which is unnecessary because
2816         Fixed nodes handle them, and harmful because they introduced unwanted layer movement.
2817
2818         Tests: scrollingcoordinator/ios/fixed-in-overflow-scroll-scrolling-tree.html
2819                scrollingcoordinator/ios/fixed-in-overflow-scroll.html
2820
2821         * rendering/RenderLayerCompositor.cpp:
2822         (WebCore::RenderLayerCompositor::computeCoordinatedPositioningForLayer const):
2823
2824 2019-03-26  Dean Jackson  <dino@apple.com>
2825
2826         vertexAttribPointer must restrict offset parameter
2827         https://bugs.webkit.org/show_bug.cgi?id=196261
2828         <rdar://problem/48458086>
2829
2830         Reviewed by Antoine Quint.
2831
2832         This WebGL function should fail if the offset parameter is
2833         not within [0, max 32-bit int].
2834
2835         Test: fast/canvas/webgl/vertexAttribPointer-with-bad-offset.html
2836
2837         * html/canvas/WebGLRenderingContextBase.cpp:
2838         (WebCore::WebGLRenderingContextBase::vertexAttribPointer):
2839
2840 2019-03-26  Antoine Quint  <graouts@apple.com>
2841
2842         Remove mousemoveEventHandlingPreventsDefault internal setting and quirk
2843         https://bugs.webkit.org/show_bug.cgi?id=196254
2844         <rdar://problem/49124334>
2845
2846         Unreviewed. Fix build broken by previous commit.
2847
2848         * dom/Event.cpp:
2849         * dom/Event.h:
2850         (WebCore::Event::hasEncounteredListener const): Deleted.
2851         (WebCore::Event::setHasEncounteredListener): Deleted.
2852         * dom/EventTarget.cpp:
2853         (WebCore::EventTarget::innerInvokeEventListeners):
2854
2855 2019-03-26  Zalan Bujtas  <zalan@apple.com>
2856
2857         [ContentChangeObserver] Skip anonymous renderers when checking for "willRespondToMouseClickEvents"
2858         https://bugs.webkit.org/show_bug.cgi?id=196259
2859         <rdar://problem/49240029>
2860
2861         Reviewed by Dean Jackson.
2862
2863         Anonymous renderers don't have associated DOM nodes so they can't have event listeners either. Let's skip them.
2864
2865         Test: fast/events/touch/ios/content-observation/crash-on-anonymous-renderer.html
2866
2867         * page/ios/ContentChangeObserver.cpp:
2868         (WebCore::ContentChangeObserver::StyleChangeScope::isConsideredClickable const):
2869
2870 2019-03-26  Antoine Quint  <graouts@apple.com>
2871
2872         Remove mousemoveEventHandlingPreventsDefault internal setting and quirk
2873         https://bugs.webkit.org/show_bug.cgi?id=196254
2874         <rdar://problem/49124334>
2875
2876         Reviewed by Dean Jackson.
2877
2878         * page/Quirks.cpp:
2879         (WebCore::Quirks::shouldMousemoveEventHandlingPreventDefault const): Deleted.
2880         * page/Quirks.h:
2881         * page/RuntimeEnabledFeatures.h:
2882         (WebCore::RuntimeEnabledFeatures::setMouseEventsSimulationEnabled):
2883         (WebCore::RuntimeEnabledFeatures::mousemoveEventHandlingPreventsDefaultEnabled const): Deleted.
2884         (WebCore::RuntimeEnabledFeatures::setMousemoveEventHandlingPreventsDefaultEnabled): Deleted.
2885
2886 2019-03-26  Commit Queue  <commit-queue@webkit.org>
2887
2888         Unreviewed, rolling out r243493.
2889         https://bugs.webkit.org/show_bug.cgi?id=196257
2890
2891         broke the non-gst-gl build (Requested by philn on #webkit).
2892
2893         Reverted changeset:
2894
2895         "Build failure with gstreamer 1.12.5 if USE_GSTREAMER_GL is
2896         enabled"
2897         https://bugs.webkit.org/show_bug.cgi?id=196178
2898         https://trac.webkit.org/changeset/243493
2899
2900 2019-03-26  Mike Gorse  <mgorse@alum.wpi.edu>
2901
2902         Build failure with gstreamer 1.12.5 if USE_GSTREAMER_GL is enabled
2903         https://bugs.webkit.org/show_bug.cgi?id=196178
2904
2905         Reviewed by Philippe Normand.
2906
2907         No new tests (build fix).
2908
2909         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
2910         Include gst/gl/gl.h before including GraphicsContext3D.h.
2911
2912 2019-03-26  Philippe Normand  <pnormand@igalia.com>
2913
2914         [GStreamer] Sound loop with Google Hangouts and WhatsApp notifications
2915         https://bugs.webkit.org/show_bug.cgi?id=189471
2916
2917         Reviewed by Xabier Rodriguez-Calvar.
2918
2919         The media duration is now cached (again). The loop issue was
2920         triggered by the previous version of the code returning positive
2921         infinite duration in didEnd(), followed by the timeupdate event
2922         propagation that would trick the HTMLMediaElement into a new call
2923         to play(). Now the cached duration is updated to current position
2924         at EOS (for forward playback direction only), so the media element
2925         no longer triggers a new play call for those cases.
2926
2927         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
2928         (WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer):
2929         (WebCore::MediaPlayerPrivateGStreamer::loadFull):
2930         (WebCore::MediaPlayerPrivateGStreamer::playbackPosition const):
2931         (WebCore::MediaPlayerPrivateGStreamer::platformDuration const):
2932         (WebCore::MediaPlayerPrivateGStreamer::durationMediaTime const):
2933         (WebCore::MediaPlayerPrivateGStreamer::currentMediaTime const):
2934         (WebCore::MediaPlayerPrivateGStreamer::didEnd):
2935         (WebCore::MediaPlayerPrivateGStreamer::durationChanged):
2936         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
2937         * platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.cpp:
2938         (WebCore::MediaPlayerPrivateGStreamerMSE::currentMediaTime const):
2939
2940 2019-03-26  Antti Koivisto  <antti@apple.com>
2941
2942         Hit-testing on layers overlapping scrollers should hit-test on text boxes
2943         https://bugs.webkit.org/show_bug.cgi?id=195373
2944         <rdar://problem/48649865>
2945
2946         Reviewed by Simon Fraser.
2947
2948         * rendering/InlineFlowBox.cpp:
2949         (WebCore::InlineFlowBox::paint):
2950         * rendering/InlineTextBox.cpp:
2951         (WebCore::InlineTextBox::paint):
2952
2953         Collect event region for overflowing line boxes.
2954
2955         * rendering/SimpleLineLayoutFunctions.cpp:
2956         (WebCore::SimpleLineLayout::paintFlow):
2957
2958         Collect event region for overflowing simple lines.
2959
2960 2019-03-25  Alex Christensen  <achristensen@webkit.org>
2961
2962         Expected shouldn't assume its contained types are copyable
2963         https://bugs.webkit.org/show_bug.cgi?id=195986
2964
2965         Reviewed by JF Bastien.
2966
2967         * contentextensions/ContentExtensionParser.cpp:
2968         (WebCore::ContentExtensions::loadAction):
2969
2970 2019-03-20  Ryosuke Niwa  <rniwa@webkit.org>
2971
2972         Leak of SVGFontFaceElement when RenderStyle holds onto a FontRances which uses it
2973         https://bugs.webkit.org/show_bug.cgi?id=196059
2974
2975         Reviewed by Zalan Bujtas.
2976
2977         SVGFontFaceElement keeps its RenderStyle alive via ElementRareData but RenderStyle can hold onto FontRanges
2978         and therefore CSSFontSource, which in turn keeps SVGFontFaceElement alive, making a reference cycle.
2979
2980         More precisely, there are two reference cycles:
2981         SVGFontFaceElement (1) -> ElementRareData -> StyleInheritedData -> FontCascade -> FontCascadeFonts (2)
2982         FontCascadeFonts (2) -> FontRanges (3)
2983         FontCascadeFonts (2) -> CSSFontSelector -> CSSFontFaceSet -> CSSSegmentedFontFace -> FontRanges (3)
2984         FontRanges (3) -> CSSFontAccessor > CSSFontFace > CSSFontSource -> SVGFontFaceElement (1)
2985
2986         No new tests. Unfortunately, writing a test proved to be intractable. The leak can be reproduced by running
2987         svg/text/text-text-05-t.svg then svg/zoom/page/zoom-img-preserveAspectRatio-support-1.html consecutively.
2988
2989         * css/CSSFontFaceSource.cpp:
2990         (WebCore::CSSFontFaceSource::CSSFontFaceSource):
2991         (WebCore::CSSFontFaceSource::load):
2992         (WebCore::CSSFontFaceSource::font):
2993         (WebCore::CSSFontFaceSource::isSVGFontFaceSource const):
2994         * css/CSSFontFaceSource.h:
2995
2996 2019-03-25  Fujii Hironori  <Hironori.Fujii@sony.com>
2997
2998         Unreviewed, rolling out r243450.
2999
3000         AppleWin and WinCairo port builds get broken.
3001
3002         Reverted changeset:
3003
3004         "Add test for fix of #196095"
3005         https://bugs.webkit.org/show_bug.cgi?id=196097
3006         https://trac.webkit.org/changeset/243450
3007
3008 2019-03-25  Said Abou-Hallawa  <sabouhallawa@apple.com>
3009
3010         Remove the SVG tear off objects for SVGAngle, SVGAnimatedAngle and SVGAnimatedEnumeration
3011         https://bugs.webkit.org/show_bug.cgi?id=196087
3012
3013         Reviewed by Simon Fraser.
3014
3015         In this patch, the tear off objects for SVGAnimatedEnumeration will be 
3016         removed. Because the angle is paired with the orient type so its tear
3017         off objects have to be removed as well. Here is what this patch does:
3018
3019         -- SVGAngle is now a superclass of SVGValueProperty<SVGAngleValue>. Its 
3020         relationship with its owner will be managed by the owner of its base
3021         class SVGProperty.
3022
3023         -- SVGAnimatedAngle is now defined to be SVGAnimatedValueProperty<
3024         SVGAngle>. All the DOM interfaces will be handled by the base class
3025         given its baseVal and animVal are of type SVGAngle.
3026
3027         -- SVGAnimatedEnumeration is now defined to be
3028         SVGAnimatedDecoratedProperty<SVGDecoratedEnumeration, unsigned>.
3029         This can be read: SVGAnimatedEnumeration is an SVGAnimatedProperty which
3030         decorates the "SVGDecoratedEnumeration" type to "unsigned". The reason
3031         for this complication is the IDL of SVGAnimatedEnumeration defines the
3032         baseVal and animVal are of type unsigned. However SVGAnimatedEnumeration
3033         should be able to convert a string to its enum value and vice versa.
3034
3035         -- SVGAnimatedDecoratedProperty is a template class which maps from
3036         DecoratedProperty to DecorationType. The DecoratedProperty is actually
3037         a template class which exposes a property of type DecorationType.
3038
3039         -- SVGDecoratedProperty is an abstract class which manages setting and
3040         getting a property in DecorationType regardless of how it is actually
3041         stored. 
3042
3043         -- SVGDecoratedPrimitive is a superclass of SVGDecoratedProperty which
3044         stores a primitive property whose type is PropertyType but can decorate
3045         it to the callers as DecorationType.
3046
3047         -- SVGDecoratedEnumeration is a superclass of SVGDecoratedPrimitive
3048         which stores a primitive type DecorationType like "BlendMode" but
3049         decorates it as "unsigned"
3050
3051         To get the mechanics of this change correct, new accessors, animators
3052         and animation functions need to be added for SVGAnimatedAngle,
3053         SVGAnimatedEnumeration and SVGAnimatedOrientType. But since angle and
3054         the orient type are paired under a single attribute, a pair accessor and
3055         animator are also needed for the pair { angle, orientType }.
3056
3057         * Sources.txt:
3058         * WebCore.xcodeproj/project.pbxproj:
3059         * svg/SVGAngle.h:
3060         (WebCore::SVGAngle::create):
3061         (WebCore::SVGAngle::unitType):
3062         (WebCore::SVGAngle::setValueForBindings):
3063         (WebCore::SVGAngle::valueForBindings):
3064         (WebCore::SVGAngle::setValueInSpecifiedUnits):
3065         (WebCore::SVGAngle::valueInSpecifiedUnits):
3066         (WebCore::SVGAngle::setValueAsString):
3067         (WebCore::SVGAngle::newValueSpecifiedUnits):
3068         (WebCore::SVGAngle::convertToSpecifiedUnits):
3069         (WebCore::SVGAngle::valueAsString): Deleted.
3070         (WebCore::SVGAngle::SVGAngle): Deleted.
3071         * svg/SVGAnimatedAngle.cpp: Removed.
3072         * svg/SVGAnimatedAngle.h: Removed.
3073         * svg/SVGAnimatedEnumeration.cpp: Removed.
3074         * svg/SVGAnimatedEnumeration.h: Removed.
3075         * svg/SVGAnimatedType.h:
3076         (WebCore::SVGAnimatedType::type const):
3077         * svg/SVGAnimatorFactory.h:
3078         (WebCore::SVGAnimatorFactory::create):
3079         * svg/SVGClipPathElement.cpp:
3080         (WebCore::SVGClipPathElement::SVGClipPathElement):
3081         (WebCore::SVGClipPathElement::parseAttribute):
3082         (WebCore::SVGClipPathElement::svgAttributeChanged):
3083         (WebCore::SVGClipPathElement::registerAttributes): Deleted.
3084         * svg/SVGClipPathElement.h:
3085         * svg/SVGComponentTransferFunctionElement.cpp:
3086         (WebCore::SVGComponentTransferFunctionElement::SVGComponentTransferFunctionElement):
3087         (WebCore::SVGComponentTransferFunctionElement::parseAttribute):
3088         (WebCore::SVGComponentTransferFunctionElement::registerAttributes): Deleted.
3089         * svg/SVGComponentTransferFunctionElement.h:
3090         (WebCore::SVGComponentTransferFunctionElement::type const):
3091         (WebCore::SVGComponentTransferFunctionElement::typeAnimated):
3092         (WebCore::SVGComponentTransferFunctionElement::attributeRegistry): Deleted.
3093         (WebCore::SVGComponentTransferFunctionElement::isKnownAttribute): Deleted.
3094         * svg/SVGElement.cpp:
3095         (WebCore::SVGElement::commitPropertyChange):
3096         * svg/SVGFEBlendElement.cpp:
3097         (WebCore::SVGFEBlendElement::SVGFEBlendElement):
3098         (WebCore::SVGFEBlendElement::parseAttribute):
3099         (WebCore::SVGFEBlendElement::registerAttributes): Deleted.
3100         * svg/SVGFEBlendElement.h:
3101         (WebCore::SVGPropertyTraits<BlendMode>::fromString):
3102         * svg/SVGFEColorMatrixElement.cpp:
3103         (WebCore::SVGFEColorMatrixElement::SVGFEColorMatrixElement):
3104         (WebCore::SVGFEColorMatrixElement::parseAttribute):
3105         (WebCore::SVGFEColorMatrixElement::registerAttributes): Deleted.
3106         * svg/SVGFEColorMatrixElement.h:
3107         * svg/SVGFECompositeElement.cpp:
3108         (WebCore::SVGFECompositeElement::SVGFECompositeElement):
3109         (WebCore::SVGFECompositeElement::parseAttribute):
3110         (WebCore::SVGFECompositeElement::registerAttributes): Deleted.
3111         * svg/SVGFECompositeElement.h:
3112         * svg/SVGFEConvolveMatrixElement.cpp:
3113         (WebCore::SVGFEConvolveMatrixElement::SVGFEConvolveMatrixElement):
3114         (WebCore::SVGFEConvolveMatrixElement::parseAttribute):
3115         (WebCore::SVGFEConvolveMatrixElement::registerAttributes): Deleted.
3116         * svg/SVGFEConvolveMatrixElement.h:
3117         * svg/SVGFEDisplacementMapElement.cpp:
3118         (WebCore::SVGFEDisplacementMapElement::SVGFEDisplacementMapElement):
3119         (WebCore::SVGFEDisplacementMapElement::parseAttribute):
3120         (WebCore::SVGFEDisplacementMapElement::registerAttributes): Deleted.
3121         * svg/SVGFEDisplacementMapElement.h:
3122         * svg/SVGFEGaussianBlurElement.cpp:
3123         (WebCore::SVGFEGaussianBlurElement::SVGFEGaussianBlurElement):
3124         (WebCore::SVGFEGaussianBlurElement::parseAttribute):
3125         (WebCore::SVGFEGaussianBlurElement::svgAttributeChanged):
3126         (WebCore::SVGFEGaussianBlurElement::registerAttributes): Deleted.
3127         * svg/SVGFEGaussianBlurElement.h:
3128         * svg/SVGFEMorphologyElement.cpp:
3129         (WebCore::SVGFEMorphologyElement::SVGFEMorphologyElement):
3130         (WebCore::SVGFEMorphologyElement::parseAttribute):
3131         (WebCore::SVGFEMorphologyElement::registerAttributes): Deleted.
3132         * svg/SVGFEMorphologyElement.h:
3133         * svg/SVGFETurbulenceElement.cpp:
3134         (WebCore::SVGFETurbulenceElement::SVGFETurbulenceElement):
3135         (WebCore::SVGFETurbulenceElement::parseAttribute):
3136         (WebCore::SVGFETurbulenceElement::svgAttributeChanged):
3137         (WebCore::SVGFETurbulenceElement::registerAttributes): Deleted.
3138         * svg/SVGFETurbulenceElement.h:
3139         * svg/SVGFilterElement.cpp:
3140         (WebCore::SVGFilterElement::SVGFilterElement):
3141         (WebCore::SVGFilterElement::registerAttributes):
3142         (WebCore::SVGFilterElement::parseAttribute):
3143         * svg/SVGFilterElement.h:
3144         * svg/SVGGradientElement.cpp:
3145         (WebCore::SVGGradientElement::SVGGradientElement):
3146         (WebCore::SVGGradientElement::registerAttributes):
3147         (WebCore::SVGGradientElement::parseAttribute):
3148         * svg/SVGGradientElement.h:
3149         (WebCore::SVGGradientElement::spreadMethod const):
3150         (WebCore::SVGGradientElement::gradientUnits const):
3151         (WebCore::SVGGradientElement::spreadMethodAnimated):
3152         (WebCore::SVGGradientElement::gradientUnitsAnimated):
3153         * svg/SVGMarkerElement.cpp:
3154         (WebCore::SVGMarkerElement::SVGMarkerElement):
3155         (WebCore::SVGMarkerElement::registerAttributes):
3156         (WebCore::SVGMarkerElement::parseAttribute):
3157         (WebCore::SVGMarkerElement::setOrient):
3158         (WebCore::SVGMarkerElement::setOrientToAngle):
3159         (WebCore::SVGMarkerElement::orientTypeIdentifier): Deleted.
3160         (WebCore::SVGMarkerElement::orientAngleIdentifier): Deleted.
3161         * svg/SVGMarkerElement.h:
3162         * svg/SVGMarkerTypes.h:
3163         (WebCore::SVGPropertyTraits<SVGMarkerOrientType>::autoString):
3164         (WebCore::SVGPropertyTraits<SVGMarkerOrientType>::autoStartReverseString):
3165         (WebCore::SVGPropertyTraits<SVGMarkerOrientType>::fromString):
3166         (WebCore::SVGPropertyTraits<SVGMarkerOrientType>::toString):
3167         * svg/SVGMaskElement.cpp:
3168         (WebCore::SVGMaskElement::SVGMaskElement):
3169         (WebCore::SVGMaskElement::registerAttributes):
3170         (WebCore::SVGMaskElement::parseAttribute):
3171         * svg/SVGMaskElement.h:
3172         * svg/SVGPatternElement.cpp:
3173         (WebCore::SVGPatternElement::SVGPatternElement):
3174         (WebCore::SVGPatternElement::registerAttributes):
3175         (WebCore::SVGPatternElement::parseAttribute):
3176         * svg/SVGPatternElement.h:
3177         * svg/SVGSVGElement.cpp:
3178         * svg/SVGScriptElement.cpp:
3179         * svg/SVGTextContentElement.cpp:
3180         (WebCore::SVGTextContentElement::SVGTextContentElement):
3181         (WebCore::SVGTextContentElement::registerAttributes):
3182         (WebCore::SVGTextContentElement::parseAttribute):
3183         * svg/SVGTextContentElement.h:
3184         (WebCore::SVGTextContentElement::lengthAdjust const):
3185         (WebCore::SVGTextContentElement::lengthAdjustAnimated):
3186         * svg/SVGTextPathElement.cpp:
3187         (WebCore::SVGTextPathElement::SVGTextPathElement):
3188         (WebCore::SVGTextPathElement::registerAttributes):
3189         (WebCore::SVGTextPathElement::parseAttribute):
3190         * svg/SVGTextPathElement.h:
3191         * svg/SVGValue.h:
3192         * svg/properties/SVGAnimatedDecoratedProperty.h: Added.
3193         (WebCore::SVGAnimatedDecoratedProperty::create):
3194         (WebCore::SVGAnimatedDecoratedProperty::SVGAnimatedDecoratedProperty):
3195         (WebCore::SVGAnimatedDecoratedProperty::setBaseVal):
3196         (WebCore::SVGAnimatedDecoratedProperty::setBaseValInternal):
3197         (WebCore::SVGAnimatedDecoratedProperty::baseVal const):
3198         (WebCore::SVGAnimatedDecoratedProperty::setAnimVal):
3199         (WebCore::SVGAnimatedDecoratedProperty::animVal const):
3200         (WebCore::SVGAnimatedDecoratedProperty::currentValue const):
3201         * svg/properties/SVGAnimatedEnumerationPropertyTearOff.h: Removed.
3202         * svg/properties/SVGAnimatedPropertyAccessorImpl.h:
3203         * svg/properties/SVGAnimatedPropertyAnimatorImpl.h:
3204         * svg/properties/SVGAnimatedPropertyImpl.h:
3205         (WebCore::SVGAnimatedOrientType::create):
3206         * svg/properties/SVGAnimatedPropertyPairAccessorImpl.h:
3207         * svg/properties/SVGAnimatedPropertyPairAnimator.h:
3208         (WebCore::SVGAnimatedPropertyPairAnimator::appendAnimatedInstance):
3209         * svg/properties/SVGAnimatedPropertyPairAnimatorImpl.h:
3210         * svg/properties/SVGAnimatedStaticPropertyTearOff.h: Removed.
3211         * svg/properties/SVGAnimationAdditiveValueFunctionImpl.h:
3212         (WebCore::SVGAnimationAngleFunction::progress):
3213         * svg/properties/SVGAnimationDiscreteFunctionImpl.h:
3214         * svg/properties/SVGAttributeRegistry.h:
3215         * svg/properties/SVGDecoratedEnumeration.h: Added.
3216         (WebCore::SVGDecoratedEnumeration::create):
3217         * svg/properties/SVGDecoratedPrimitive.h: Added.
3218         (WebCore::SVGDecoratedPrimitive::SVGDecoratedPrimitive):
3219         * svg/properties/SVGDecoratedProperty.h: Added.
3220         (WebCore::SVGDecoratedProperty::setValue):
3221         (WebCore::SVGDecoratedProperty::value const):
3222         * svg/properties/SVGPropertyOwnerRegistry.h:
3223         (WebCore::SVGPropertyOwnerRegistry::registerProperty):
3224         (WebCore::SVGPropertyOwnerRegistry::isAnimatedLengthAttribute):
3225         * svg/properties/SVGPropertyRegistry.h:
3226         * svg/properties/SVGStaticPropertyTearOff.h: Removed.
3227
3228 2019-03-25  Fujii Hironori  <Hironori.Fujii@sony.com>
3229
3230         [iOS] Break a reference cycle between PreviewLoader and ResourceLoader
3231         https://bugs.webkit.org/show_bug.cgi?id=194964
3232
3233         Unreviewed build fix for WinCairo port.
3234
3235         error C2504: 'CanMakeWeakPtr': base class undefined
3236
3237         * loader/ResourceLoader.h: Added #include <wtf/WeakPtr.h>.
3238
3239 2019-03-25  Andy Estes  <aestes@apple.com>
3240
3241         [iOS] Break a reference cycle between PreviewLoader and ResourceLoader
3242         https://bugs.webkit.org/show_bug.cgi?id=194964
3243         <rdar://problem/48279441>
3244
3245         Reviewed by Alex Christensen.
3246
3247         When a document's QuickLook preview is loaded, a reference cycle is created between
3248         WebPreviewLoader and ResourceLoader. Break the cycle by changing WebPreviewLoader to hold a
3249         WeakPtr to its ResourceLoader ResourceLoader::releaseResources().
3250
3251         Fixes leaks detected by `run-webkit-tests --leaks LayoutTests/quicklook`. Also covered by
3252         existing API tests.
3253
3254         * loader/ResourceLoader.h:
3255         * loader/ios/PreviewLoader.mm:
3256         (-[WebPreviewLoader initWithResourceLoader:resourceResponse:]):
3257         (-[WebPreviewLoader _sendDidReceiveResponseIfNecessary]):
3258         (-[WebPreviewLoader connection:didReceiveData:lengthReceived:]):
3259         (-[WebPreviewLoader connectionDidFinishLoading:]):
3260         (-[WebPreviewLoader connection:didFailWithError:]):
3261
3262 2019-03-25  Alex Christensen  <achristensen@webkit.org>
3263
3264         Enable IPC sending and receiving non-default-constructible types
3265         https://bugs.webkit.org/show_bug.cgi?id=196132
3266
3267         Reviewed by Geoff Garen.
3268
3269         This basically just requires the decoding of std::tuple to return an Optional<std::tuple> instead of
3270         constructing a std::tuple then decoding into it.  I now decode synchronous replies into an Optional<std::tuple>
3271         then move it into the tuple of references where the successfully decoded reply should go.  This required
3272         the synchronous reply types be move constructible and move assignable.
3273
3274         * Modules/indexeddb/shared/IDBRequestData.h:
3275         * Modules/indexeddb/shared/IDBTransactionInfo.h:
3276         * platform/DragImage.h:
3277         * platform/PasteboardWriterData.h:
3278         * platform/audio/mac/CAAudioStreamDescription.h:
3279         * platform/graphics/RemoteVideoSample.h:
3280
3281 2019-03-25  Alex Christensen  <achristensen@webkit.org>
3282
3283         Stop storing raw pointers to Documents
3284         https://bugs.webkit.org/show_bug.cgi?id=196042
3285
3286         Reviewed by Geoff Garen.
3287
3288         Use WeakPtr instead!  This could change some UAF bugs into null dereference crashes.
3289
3290         * css/CSSFontSelector.cpp:
3291         (WebCore::CSSFontSelector::CSSFontSelector):
3292         (WebCore::CSSFontSelector::addFontFaceRule):
3293         (WebCore::CSSFontSelector::fontRangesForFamily):
3294         * css/CSSFontSelector.h:
3295         * css/MediaQueryMatcher.cpp:
3296         (WebCore::MediaQueryMatcher::MediaQueryMatcher):
3297         (WebCore::MediaQueryMatcher::matchMedia):
3298         * css/MediaQueryMatcher.h:
3299         * css/StyleSheetList.cpp:
3300         (WebCore::StyleSheetList::StyleSheetList):
3301         (WebCore::StyleSheetList::ownerNode const):
3302         * css/StyleSheetList.h:
3303         * css/ViewportStyleResolver.cpp:
3304         (WebCore::ViewportStyleResolver::ViewportStyleResolver):
3305         * css/ViewportStyleResolver.h:
3306         * dom/Document.h:
3307         (WebCore::Document::setTemplateDocumentHost):
3308         (WebCore::Document::templateDocumentHost):
3309         * dom/DocumentParser.cpp:
3310         (WebCore::DocumentParser::DocumentParser):
3311         * dom/DocumentParser.h:
3312         (WebCore::DocumentParser::document const):
3313         * dom/ScriptedAnimationController.cpp:
3314         (WebCore::ScriptedAnimationController::ScriptedAnimationController):
3315         * dom/ScriptedAnimationController.h:
3316         * html/parser/HTMLScriptRunner.cpp:
3317         (WebCore::HTMLScriptRunner::HTMLScriptRunner):
3318         (WebCore::HTMLScriptRunner::runScript):
3319         * html/parser/HTMLScriptRunner.h:
3320         * loader/MediaResourceLoader.cpp:
3321         (WebCore::MediaResourceLoader::MediaResourceLoader):
3322         * loader/MediaResourceLoader.h:
3323         * loader/cache/CachedResourceLoader.cpp:
3324         (WebCore::CachedResourceLoader::canRequestInContentDispositionAttachmentSandbox const):
3325         (WebCore::CachedResourceLoader::loadDone):
3326         * loader/cache/CachedResourceLoader.h:
3327         (WebCore::CachedResourceLoader::document const):
3328         (WebCore::CachedResourceLoader::setDocument):
3329
3330 2019-03-25  Truitt Savell  <tsavell@apple.com>
3331
3332         Unreviewed, rolling out r243419.
3333
3334         Caused Mac WK2 testers to crash and become unresponsive.
3335
3336         Reverted changeset:
3337
3338         "[Web GPU] Prototype compute pipeline with MSL"
3339         https://bugs.webkit.org/show_bug.cgi?id=196107
3340         https://trac.webkit.org/changeset/243419
3341
3342 2019-03-25  Truitt Savell  <tsavell@apple.com>
3343
3344         Unreviewed, rolling out r243438.
3345
3346         243319 Caused Mac WK2 testers to crash and become
3347         unresponsive.
3348
3349         Reverted changeset:
3350
3351         "Update WebGPU class names based on sketch.idl"
3352         https://bugs.webkit.org/show_bug.cgi?id=194260
3353         https://trac.webkit.org/changeset/243438
3354
3355 2019-03-25  Eric Carlson  <eric.carlson@apple.com>
3356
3357         Delete MetadataPreloadingNotPermitted, it is unused
3358         https://bugs.webkit.org/show_bug.cgi?id=196202
3359         <rdar://problem/49213611>
3360
3361         Reviewed by Jer Noble.
3362
3363         No new tests, the flat was unused except in an existing test that was removed.
3364
3365         * html/MediaElementSession.cpp:
3366         (WebCore::restrictionNames):
3367         (WebCore::MediaElementSession::effectivePreloadForElement const):
3368         * html/MediaElementSession.h:
3369         * platform/graphics/cg/UTIRegistry.cpp:
3370         (WebCore::defaultSupportedImageTypes):
3371         * testing/Internals.cpp:
3372         (WebCore::Internals::setMediaElementRestrictions):
3373
3374 2019-03-25  Jer Noble  <jer.noble@apple.com>
3375
3376         Test for: 196095 Inband Text Track cues interspersed with Data cues can display out of order.
3377         https://bugs.webkit.org/show_bug.cgi?id=196097
3378
3379         Reviewed by Eric Carlson.
3380
3381         Test: media/track/track-in-band-metadata-display-order.html
3382
3383         Add a method in Internals to create a TextTrackCueGeneric (which can normally only be created
3384         by parsing an in-band media track). This requires adding IDL for TextTrackCueGeneric, and exporting
3385         TextTrackCueGeneric for testing.
3386
3387         Drive-by fixes:
3388
3389         Add runtime logging to MediaControlTextTrackContainerElement. This necessitates modifying the
3390         parentMediaElement() method to take a const Node*, and const_cast that constness away in order to return
3391         a HTMLMediaElement*
3392
3393         TextTrackCue, VTTCue, TextTrackCueGeneric, and DataCue should all use the WTF TypeCasts macros to
3394         enable use of is<> and downcast<>.
3395
3396         * Source/WebCore/CMakeLists.txt:
3397         * DerivedSources-input.xcfilelist:
3398         * DerivedSources-output.xcfilelist:
3399         * DerivedSources.make:
3400         * WebCore.xcodeproj/project.pbxproj:
3401         * html/shadow/MediaControlElementTypes.cpp:
3402         (WebCore::parentMediaElement):
3403         * html/shadow/MediaControlElementTypes.h:
3404         * html/shadow/MediaControlElements.cpp:
3405         (WebCore::MediaControlTextTrackContainerElement::updateDisplay):
3406         (WebCore::MediaControlTextTrackContainerElement::logger const):
3407         (WebCore::MediaControlTextTrackContainerElement::logIdentifier const):
3408         (WebCore::MediaControlTextTrackContainerElement::logChannel const):
3409         * html/shadow/MediaControlElements.h:
3410         * html/track/DataCue.h:
3411         (isType):
3412         * html/track/TextTrackCueGeneric.h:
3413         (isType):
3414         * html/track/TextTrackCueGeneric.idl: Added.
3415         * html/track/VTTCue.h:
3416         (isType):
3417         * testing/Internals.cpp:
3418         (WebCore::Internals::createGenericCue):
3419         * testing/Internals.h:
3420         * testing/Internals.idl:
3421
3422 2019-03-25  Antti Koivisto  <antti@apple.com>
3423
3424         Toggling "display: contents" to "display: none" fails to hide the element
3425         https://bugs.webkit.org/show_bug.cgi?id=188259
3426         <rdar://problem/42886896>
3427
3428         Reviewed by Simon Fraser.
3429
3430         Test: fast/css/display-contents-to-none.html
3431
3432         * style/StyleTreeResolver.cpp:
3433         (WebCore::Style::affectsRenderedSubtree):
3434
3435         An element with 'display:contents' has a rendered subtree.
3436
3437 2019-03-25  Justin Fan  <justin_fan@apple.com>
3438
3439         Update WebGPU class names based on sketch.idl
3440         https://bugs.webkit.org/show_bug.cgi?id=194260
3441
3442         Reviewed by Dean Jackson.
3443
3444         Update all exposed Web GPU interface names to GPU* prefix. 
3445
3446         Existing Web GPU tests updated to expect new names.
3447
3448         * Modules/webgpu/WebGPU.idl:
3449         * Modules/webgpu/WebGPUAdapter.idl:
3450         * Modules/webgpu/WebGPUBindGroup.idl:
3451         * Modules/webgpu/WebGPUBindGroupLayout.idl:
3452         * Modules/webgpu/WebGPUBuffer.idl:
3453         * Modules/webgpu/WebGPUDevice.idl:
3454         * Modules/webgpu/WebGPUInputStepMode.h: Removed.
3455         * Modules/webgpu/WebGPUPipelineLayout.idl:
3456         * Modules/webgpu/WebGPUProgrammablePassEncoder.idl:
3457         * Modules/webgpu/WebGPUQueue.idl:
3458         * Modules/webgpu/WebGPURenderPassEncoder.idl:
3459         * Modules/webgpu/WebGPURenderPipeline.idl:
3460         * Modules/webgpu/WebGPUSampler.idl:
3461         * Modules/webgpu/WebGPUTexture.idl:
3462         * Modules/webgpu/WebGPUTextureView.idl:
3463         * WebCore.xcodeproj/project.pbxproj:
3464         * bindings/js/WebCoreBuiltinNames.h:
3465
3466 2019-03-25  Javier Fernandez  <jfernandez@igalia.com>
3467
3468         A single leading space is not considered as a word break even when word-break: break-all is set
3469         https://bugs.webkit.org/show_bug.cgi?id=195361
3470
3471         Reviewed by Ryosuke Niwa.
3472
3473         We must consider leading white-spaces as potential soft-breaking
3474         opportunities that may avoid breaking in the middle of the word.
3475
3476         However, 'break-word: break-all' [1] implies that we should ignore
3477         previous opportunities and break at any character (among the ones
3478         valid for 'break-all') that prevents the line to overflow. Note,
3479         that these breakable characters are different from the ones
3480         provided by 'line-break: anywhere' [2].
3481
3482         This change is covered by the already existent tests of the CSS
3483         Text 3 suite of the Web Platform Tests.
3484
3485         The word-break-break-all-010.html was precisely designed to cover
3486         the basic issue fixed with this change, verifying that the word is
3487         indeed broken even if a single leading space constitutes a
3488         previous soft-breaking opportunity.
3489
3490         There are other Web Platform Tests. which already pass before this
3491         change, to verify that such leading white-space must be used
3492         instead of breaking the word in any other case, including
3493         overflow-wrap: break-word and even the deprecated word-break:
3494         break-word.
3495
3496            - white-space/pre-wrap-008.html
3497            - white-space/pre-wrap-015.html
3498            - white-space/pre-wrap-016.html
3499            - overflow-wrap/overflow-wrap-break-word-004.html
3500            - overflow-wrap/overflow-wrap-break-word-005.html
3501            - overflow-wrap/overflow-wrap-break-word-007.html
3502            - word-break/word-break-break-all-011.html
3503            - word-break/word-break-break-all-014.html
3504
3505         The reason why the word-break-break-all-010.html passes in Mac
3506         platform is that for that case the SimpleLineLayout codepath is
3507         executed instead, which doesn't have this bug, present in the old
3508         line-breaking logic implemented in the BreakingContext class.
3509
3510         In order to verify the validity of this change, I've added several
3511         tests under fast/text with the SimpleLineLayout disabled.
3512
3513         Tests: fast/text/overflow-wrap-break-word-004.html
3514                fast/text/overflow-wrap-break-word-005.html
3515                fast/text/overflow-wrap-break-word-007.html
3516                fast/text/whitespace/pre-wrap-008.html
3517                fast/text/whitespace/pre-wrap-015.html
3518                fast/text/whitespace/pre-wrap-016.html
3519                fast/text/word-break-break-all-010.html
3520                fast/text/word-break-break-all-011.html
3521                fast/text/word-break-break-all-015.html
3522                imported/w3c/web-platform-tests/css/css-text/overflow-wrap/overflow-wrap-break-word-007.html
3523                imported/w3c/web-platform-tests/css/css-text/white-space/pre-wrap-008.html
3524                imported/w3c/web-platform-tests/css/css-text/word-break/word-break-break-all-015.html
3525
3526         * rendering/line/BreakingContext.h:
3527         (WebCore::BreakingContext::handleText):
3528
3529 2019-03-25  Rob Buis  <rbuis@igalia.com>
3530
3531         Reflect HTMLLinkElement.as according to the spec
3532         https://bugs.webkit.org/show_bug.cgi?id=196189
3533
3534         Reviewed by Youenn Fablet.
3535
3536         The 'as' attribute is an enumerated attribute [1] and should
3537         reflect using a finite set of keywords, so lowercase the as getter
3538         to match the defined set of destinations [2].
3539
3540         Test: imported/w3c/web-platform-tests/preload/reflected-as-value.html
3541
3542         [1] https://html.spec.whatwg.org/#enumerated-attribute
3543         [2] https://fetch.spec.whatwg.org/#concept-request-destination
3544
3545         * html/HTMLLinkElement.cpp:
3546         (WebCore::HTMLLinkElement::as const):
3547
3548 2019-03-25  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
3549
3550         Remove NavigatorContentUtils in WebCore/Modules
3551         https://bugs.webkit.org/show_bug.cgi?id=196070
3552
3553         Reviewed by Alex Christensen.
3554
3555         NavigatorContentUtils was to support the custom scheme spec [1].
3556         However, in WebKit side, no port has supported the feature in
3557         WebKit layer after EFL port was removed. So there has been the
3558         only IDL implementation of the NavigatorContentUtils in WebCore.
3559         So we don't need to keep the implementation in WebCore anymore.
3560
3561         [1] https://html.spec.whatwg.org/multipage/system-state.html#custom-handlers
3562
3563         No new tests because this patch is just to remove the feature.
3564
3565         * CMakeLists.txt:
3566         * Modules/navigatorcontentutils/NavigatorContentUtils.cpp: Removed.
3567         * Modules/navigatorcontentutils/NavigatorContentUtils.h: Removed.
3568         * Modules/navigatorcontentutils/NavigatorContentUtils.idl: Removed.
3569         * Modules/navigatorcontentutils/NavigatorContentUtilsClient.h: Removed.
3570         * Sources.txt:
3571
3572 2019-03-25  Manuel Rego Casasnovas  <rego@igalia.com>
3573
3574         [css-grid] Fix grid container baseline alignment for orthogonal items
3575         https://bugs.webkit.org/show_bug.cgi?id=196141
3576
3577         Reviewed by Javier Fernandez.
3578
3579         Grid container baseline was wrongly computed when done in reference to an orthogonal item.
3580
3581         Test: imported/w3c/web-platform-tests/css/css-grid/alignment/grid-container-baseline-001.html
3582
3583         * rendering/RenderGrid.cpp:
3584         (WebCore::RenderGrid::firstLineBaseline const): Simple change to use logicalTopForChild()
3585         so it takes into account grid container and item writing modes.
3586
3587 2019-03-24  Michael Catanzaro  <mcatanzaro@igalia.com>
3588
3589         Unreviewed, fix -Wpessimizing-move warning
3590         https://bugs.webkit.org/show_bug.cgi?id=195905
3591         <rdar://problem/49121824>
3592
3593         * svg/properties/SVGPropertyList.h:
3594
3595 2019-03-23  Justin Fan  <justin_fan@apple.com>
3596
3597         [Web GPU] Prototype compute pipeline with MSL
3598         https://bugs.webkit.org/show_bug.cgi?id=196107
3599         <rdar://problem/46289650>
3600
3601         Reviewed by Myles Maxfield.
3602
3603         Add GPUComputePassEncoder, GPUComputePipeline, and GPUComputePipelineDescriptor.
3604         Implement everything needed to prototype a compute pipeline in Web GPU using Metal shaders and bound resources.
3605
3606         Test: webgpu/compute-squares.html
3607
3608         Add files and symbols:
3609         * CMakeLists.txt:
3610         * DerivedSources-input.xcfilelist:
3611         * DerivedSources-output.xcfilelist:
3612         * DerivedSources.make:
3613         * Sources.txt:
3614         * SourcesCocoa.txt:
3615         * WebCore.xcodeproj/project.pbxproj:
3616         * bindings/js/WebCoreBuiltinNames.h:
3617
3618         Misc fixes:
3619         * Modules/webgpu/WHLSL/WHLSLNameResolver.h: Missing include.
3620         * Modules/webgpu/WHLSL/WHLSLSynthesizeConstructors.cpp: Missing include.
3621         * Modules/webgpu/WebGPUPipelineStageDescriptor.cpp: Added. Move pipeline stage validation logic here.
3622         (WebCore::WebGPUPipelineStageDescriptor::tryCreateGPUPipelineStageDescriptor const):
3623         * Modules/webgpu/WebGPURenderPipeline.cpp: Remove unnecessary include.
3624         * Modules/webgpu/WebGPURenderPipeline.h:
3625         * Modules/webgpu/WebGPURenderPipelineDescriptor.cpp: Add missing inlcude.
3626         (WebCore::WebGPUPipelineStageDescriptor::tryCreateGPUPipelineStageDescriptor const): Moved to WebGPUPipelineStageDescriptor.cpp.
3627         * platform/graphics/gpu/GPUPipelineDescriptorBase.h: Add missing include.
3628         * platform/graphics/gpu/cocoa/GPURenderPipelineMetal.mm: Add missing include.
3629         (WebCore::GPURenderPipeline::GPURenderPipeline): Remove unecessary ref of GPUPipelineLayout.
3630         * platform/text/mac/TextEncodingRegistryMac.mm: Carbon.h was causing ambiguous reference build errors in this file.
3631
3632         Enable creating a GPUComputePassEncoder from a GPUCommandEncoder:
3633         * Modules/webgpu/WebGPUCommandEncoder.cpp:
3634         (WebCore::WebGPUCommandEncoder::beginRenderPass): No longer passing this WebGPUCommandEncoder to pass encoders.
3635         (WebCore::WebGPUCommandEncoder::beginComputePass): Added.
3636         * Modules/webgpu/WebGPUCommandEncoder.h:
3637         * Modules/webgpu/WebGPUCommandEncoder.idl:
3638
3639         Add GPUComputePassEncoder:
3640         * Modules/webgpu/WebGPUComputePassEncoder.cpp: Added.
3641         (WebCore::WebGPUComputePassEncoder::create):
3642         (WebCore::WebGPUComputePassEncoder::WebGPUComputePassEncoder):
3643         (WebCore::WebGPUComputePassEncoder::setPipeline):
3644         (WebCore::WebGPUComputePassEncoder::dispatch):
3645         (WebCore::WebGPUComputePassEncoder::passEncoder):
3646         (WebCore::WebGPUComputePassEncoder::passEncoder const):
3647         * Modules/webgpu/WebGPUComputePassEncoder.h: Added.
3648         * Modules/webgpu/WebGPUComputePassEncoder.idl: Added.
3649         * platform/graphics/gpu/GPUComputePassEncoder.h: Added.
3650         (WebCore::GPUComputePassEncoder::~GPUComputePassEncoder):
3651         * platform/graphics/gpu/cocoa/GPUComputePassEncoderMetal.mm: Added.
3652         (WebCore::GPUComputePassEncoder::tryCreate):
3653         (WebCore::GPUComputePassEncoder::GPUComputePassEncoder):
3654         (WebCore::GPUComputePassEncoder::setPipeline):
3655         (WebCore::GPUComputePassEncoder::dispatch): Use a default calculation for threadsPerThreadgroup while MSL is still an accepted shader format.
3656         (WebCore::GPUComputePassEncoder::platformPassEncoder const):
3657         (WebCore::GPUComputePassEncoder::useResource):
3658         (WebCore::GPUComputePassEncoder::setComputeBuffer):
3659
3660         Add GPUComputePipeline:
3661         * Modules/webgpu/WebGPUComputePipeline.cpp: Added.
3662         (WebCore::WebGPUComputePipeline::create):
3663         (WebCore::WebGPUComputePipeline::WebGPUComputePipeline):
3664         * Modules/webgpu/WebGPUComputePipeline.h: Added.
3665         (WebCore::WebGPUComputePipeline::computePipeline const):
3666         * Modules/webgpu/WebGPUComputePipeline.idl: Added.
3667         * Modules/webgpu/WebGPUComputePipelineDescriptor.cpp: Added.
3668         (WebCore::WebGPUComputePipelineDescriptor::tryCreateGPUComputePipelineDescriptor const):
3669         * Modules/webgpu/WebGPUComputePipelineDescriptor.h: Added.
3670         * Modules/webgpu/WebGPUComputePipelineDescriptor.idl: Added.
3671         * platform/graphics/gpu/GPUComputePipeline.h: Added.
3672         (WebCore::GPUComputePipeline::platformComputePipeline const):
3673         * platform/graphics/gpu/GPUComputePipelineDescriptor.h: Added.
3674         (WebCore::GPUComputePipelineDescriptor::GPUComputePipelineDescriptor):
3675         * platform/graphics/gpu/cocoa/GPUComputePipelineMetal.mm: Added.
3676         (WebCore::tryCreateMtlComputeFunction):
3677         (WebCore::tryCreateMTLComputePipelineState):
3678         (WebCore::GPUComputePipeline::tryCreate):
3679         (WebCore::GPUComputePipeline::GPUComputePipeline):
3680
3681         Enable creating a GPUComputePipeline from a GPUDevice:
3682         * Modules/webgpu/WebGPUDevice.cpp:
3683         (WebCore::WebGPUDevice::createComputePipeline const):
3684         * Modules/webgpu/WebGPUDevice.h:
3685         * Modules/webgpu/WebGPUDevice.idl:
3686         * platform/graphics/gpu/GPUDevice.cpp:
3687         (WebCore::GPUDevice::tryCreateComputePipeline const):
3688         * platform/graphics/gpu/GPUDevice.h:
3689
3690         No longer unnecessarily ref the WebGPUCommandEncoder when creating pass encoder:
3691         * Modules/webgpu/WebGPUProgrammablePassEncoder.cpp:
3692         (WebCore::WebGPUProgrammablePassEncoder::setBindGroup):
3693         (WebCore::WebGPUProgrammablePassEncoder::WebGPUProgrammablePassEncoder): Deleted.
3694         (WebCore::WebGPUProgrammablePassEncoder::setBindGroup const): Deleted.
3695         * Modules/webgpu/WebGPUProgrammablePassEncoder.h:
3696         * Modules/webgpu/WebGPURenderPassEncoder.cpp:
3697         (WebCore::WebGPURenderPassEncoder::create):
3698         (WebCore::WebGPURenderPassEncoder::WebGPURenderPassEncoder):
3699         (WebCore::WebGPURenderPassEncoder::setPipeline):
3700         (WebCore::WebGPURenderPassEncoder::passEncoder):
3701         (WebCore::WebGPURenderPassEncoder::passEncoder const):
3702         * Modules/webgpu/WebGPURenderPassEncoder.h:
3703
3704         Updates to GPUBindGroup and *setBindGroup for compute function arguments:
3705         * platform/graphics/gpu/GPUBindGroup.h:
3706         (WebCore::GPUBindGroup::vertexArgsBuffer const):
3707         (WebCore::GPUBindGroup::fragmentArgsBuffer const):
3708         (WebCore::GPUBindGroup::computeArgsBuffer const):
3709         (WebCore::GPUBindGroup::vertexArgsBuffer): Deleted. Const-qualified.
3710         (WebCore::GPUBindGroup::fragmentArgsBuffer): Ditto.
3711         * platform/graphics/gpu/cocoa/GPUBindGroupMetal.mm:
3712         (WebCore::tryGetResourceAsMTLSamplerState): Now just returns the MTLSamplerState to reduce reference churning.
3713         (WebCore::GPUBindGroup::tryCreate):
3714         (WebCore::GPUBindGroup::GPUBindGroup):
3715         (WebCore::tryGetResourceAsSampler): Renamed to tryGetResourceAsMTLSamplerState.
3716
3717         Updates to GPUProgrammablePassEncoder and GPURenderPassEncoder:
3718         * platform/graphics/gpu/GPUProgrammablePassEncoder.h:
3719         (WebCore::GPUProgrammablePassEncoder::setVertexBuffer):
3720         (WebCore::GPUProgrammablePassEncoder::setFragmentBuffer):
3721         (WebCore::GPUProgrammablePassEncoder::setComputeBuffer): Added.
3722         * platform/graphics/gpu/GPURenderPassEncoder.h:
3723         (WebCore::GPURenderPassEncoder::~GPURenderPassEncoder):
3724         * platform/graphics/gpu/GPURenderPipeline.h:
3725         * platform/graphics/gpu/cocoa/GPUProgrammablePassEncoderMetal.mm: Remove unecessary include.
3726         (WebCore::GPUProgrammablePassEncoder::endPass): No longer virtual. Delegates shared behavior for derived classes.
3727         (WebCore::GPUProgrammablePassEncoder::setBindGroup):
3728         * platform/graphics/gpu/cocoa/GPURenderPassEncoderMetal.mm:
3729         (WebCore::GPURenderPassEncoder::platformPassEncoder const):
3730         (WebCore::GPURenderPassEncoder::setPipeline):
3731         (WebCore::GPURenderPassEncoder::draw):
3732         (WebCore::GPURenderPassEncoder::useResource): These private overrides are called only by base after checking for encoder existence.
3733         (WebCore::GPURenderPassEncoder::setVertexBuffer): Ditto.
3734         (WebCore::GPURenderPassEncoder::setFragmentBuffer): Ditto.
3735         (WebCore::GPURenderPassEncoder::endPass): Deleted. Now handled by base class.
3736
3737 2019-03-23  Simon Fraser  <simon.fraser@apple.com>
3738
3739         REGRESSION (iOS 8): Scrollbar can't be hidden when webkit-overflow-scrolling is set to touch
3740         https://bugs.webkit.org/show_bug.cgi?id=137043
3741         rdar://problem/16595330
3742
3743         Reviewed by Zalan Bujtas.
3744
3745         Plumb horizontalScrollbarHiddenByStyle/verticalScrollbarHiddenByStyle through ScrollableAreaParameters
3746         to the UI process, and use it to set UIScrollView indicators visible or not.
3747
3748         Tests: fast/scrolling/ios/scrollbar-hiding.html:
3749
3750         * page/scrolling/AsyncScrollingCoordinator.cpp:
3751         (WebCore::AsyncScrollingCoordinator::setScrollingNodeScrollableAreaGeometry):
3752         * page/scrolling/ScrollingCoordinator.cpp:
3753         (WebCore::operator<<):
3754         * page/scrolling/ScrollingCoordinatorTypes.h:
3755         * page/scrolling/ScrollingTreeNode.h:
3756         * page/scrolling/ScrollingTreeOverflowScrollingNode.cpp:
3757         (WebCore::ScrollingTreeOverflowScrollingNode::dumpProperties const):
3758         * page/scrolling/ScrollingTreeScrollingNode.h:
3759         * platform/ScrollableArea.h:
3760         (WebCore::ScrollableArea::horizontalScrollbarHiddenByStyle const):
3761         (WebCore::ScrollableArea::verticalScrollbarHiddenByStyle const):
3762         * rendering/RenderLayer.cpp:
3763         (WebCore::scrollbarHiddenByStyle):
3764         (WebCore::RenderLayer::horizontalScrollbarHiddenByStyle const):
3765         (WebCore::RenderLayer::verticalScrollbarHiddenByStyle const):
3766         * rendering/RenderLayer.h:
3767
3768 2019-03-23  Zalan Bujtas  <zalan@apple.com>
3769
3770         [ContentChangeObserver] Add support for observing opacity.
3771         https://bugs.webkit.org/show_bug.cgi?id=196172
3772
3773         Reviewed by Simon Fraser.
3774
3775         This patch adds support for observing opacity changes. At this point we only track one transition at a time.
3776         if the page registers transition on both left and opacity, the first is getting observed only.
3777
3778         Tests: fast/events/touch/ios/content-observation/opacity-change-happens-on-mousemove-with-opacity-and-left.html
3779                fast/events/touch/ios/content-observation/opacity-change-happens-on-mousemove-with-transition.html
3780                fast/events/touch/ios/content-observation/opacity-change-happens-on-mousemove.html
3781                fast/events/touch/ios/content-observation/opacity-change-happens-on-touchstart-with-transition.html
3782                fast/events/touch/ios/content-observation/opacity-change-happens-on-touchstart.html
3783
3784         * page/ios/ContentChangeObserver.cpp:
3785         (WebCore::isConsideredHidden):
3786         (WebCore::ContentChangeObserver::didAddTransition):
3787         * page/ios/ContentChangeObserver.h:
3788         (WebCore::ContentChangeObserver::isObservedPropertyForTransition const):
3789
3790 2019-03-23  Zalan Bujtas  <zalan@apple.com>
3791
3792         [ContentChangeObserver] Check if the transitioned content is visible at onAnimationEnd
3793         https://bugs.webkit.org/show_bug.cgi?id=196171
3794
3795         Reviewed by Simon Fraser.
3796
3797         At onAnimationEnd we don't yet have the final computed style for the transitioned content.
3798         However the current state (before computing the final style) might already be qualified to be visible.
3799         Introduce "CompletedTransition" to indicate that the transition is all set as far observing is concerned
3800         (as opposed to "EndedTransition" where we still need to observe the content for the final style change).
3801
3802         Test: fast/events/touch/ios/content-observation/10ms-delay-transition-on-touch-start-with-non-0px-end.html
3803
3804         * page/ios/ContentChangeObserver.cpp:
3805         (WebCore::ContentChangeObserver::didFinishTransition):
3806         (WebCore::ContentChangeObserver::adjustObservedState):
3807         * page/ios/ContentChangeObserver.h:
3808
3809 2019-03-23  Carlos Garcia Campos  <cgarcia@igalia.com>
3810
3811         [GTK] Remove build time dependency on Geoclue2
3812         https://bugs.webkit.org/show_bug.cgi?id=195994
3813
3814         Reviewed by Michael Catanzaro.
3815
3816         Remove old Geoclue implementation.
3817
3818         * PlatformGTK.cmake:
3819         * SourcesGTK.txt:
3820         * platform/geoclue/GeolocationProviderGeoclue.cpp: Removed.
3821         * platform/geoclue/GeolocationProviderGeoclue.h: Removed.
3822         * platform/geoclue/GeolocationProviderGeoclueClient.h: Removed.
3823
3824 2019-03-22  Eric Carlson  <eric.carlson@apple.com>
3825
3826         Flaky AVEncoderBitRateKey symbol not found crash on imported/w3c/web-platform-tests/mediacapture-record/MediaRecorder-constructor.html
3827         https://bugs.webkit.org/show_bug.cgi?id=193724
3828         <rdar://problem/47483831>
3829
3830         Reviewed by Jer Noble.
3831
3832         The soft link macros occasionally fail to load constants from AVFoundation.framework
3833         which are actually in one of its sub-frameworks. While we investigate the cause
3834         cause of the failure, ise the SOFT_LINK_CONSTANT_MAY_FAIL so we can detect the failure
3835         and return a local copy of the string instead of crashing.
3836         
3837         No new tests, this should prevent existing tests from crashing.
3838
3839         * platform/mediarecorder/cocoa/MediaRecorderPrivateWriterCocoa.mm:
3840         (WebCore::myAVFormatIDKey):
3841         (WebCore::myAVNumberOfChannelsKey):
3842         (WebCore::myAVSampleRateKey):
3843         (WebCore::myAVEncoderBitRateKey):
3844
3845 2019-03-22  Youenn Fablet  <youenn@apple.com>
3846
3847         REGRESSION: Flaky ASSERTION FAILED: !m_killed seen with http/tests/security/cross-origin-worker-indexeddb.html
3848         https://bugs.webkit.org/show_bug.cgi?id=196024
3849         <rdar://problem/49117272>
3850
3851         Reviewed by Alexey Proskuryakov.
3852
3853         Do not proceed with opening the database if it is being closed.
3854         Speculative fix, this should stop making test crashing on bots.
3855
3856         * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
3857         (WebCore::IDBServer::UniqueIDBDatabase::performCurrentOpenOperation):
3858
3859 2019-03-22  Youenn Fablet  <youenn@apple.com>
3860
3861         storage/indexeddb/closed-cursor-private.html is crashing on debug
3862         https://bugs.webkit.org/show_bug.cgi?id=196101
3863
3864         Reviewed by Alex Christensen.
3865
3866         In case of immediate close for user delete, the transaction might be deleted.
3867         If the request for space is pending, it will be executed with an error as parameter.
3868         In that case, the call to didCommitTransaction will not find any existing transaction.
3869         Speculative fix, test should no longer crash.
3870
3871         * Modules/indexeddb/server/UniqueIDBDatabaseConnection.cpp:
3872         (WebCore::IDBServer::UniqueIDBDatabaseConnection::didCommitTransaction):
3873
3874 2019-03-22  Devin Rousso  <drousso@apple.com>
3875
3876         Web Inspector: Safari Canvas Inspector seems to show the canvas being rendered twice per frame.
3877         https://bugs.webkit.org/show_bug.cgi?id=196082
3878         <rdar://problem/49113496>
3879
3880         Reviewed by Dean Jackson.
3881
3882         Tests: inspector/canvas/recording-2d.html
3883                inspector/canvas/recording-bitmaprenderer.html
3884                inspector/canvas/recording-html-2d.html
3885                inspector/canvas/recording-webgl.html
3886                inspector/canvas/setRecordingAutoCaptureFrameCount.html
3887
3888         WebGL `<canvas>` follow a different "rendering" path such that `HTMLCanvasElement::paint`
3889         isn't called. Previously, there was a 0s timer that was started after the first action of a
3890         frame was recorded (for the case that the `<canvas>` isn't attached to the DOM) that would
3891         automatically stop the recording. It was possible that actions in two different "frame"s
3892         were recorded as part of the same frame, because the WebGL `<canvas>` would instead fall
3893         back to the timer to know when the "frame" had ended.
3894
3895         Now, there is additional instrumentation for the WebGL specific rendering path.
3896         Additionally, replace the 0s timer with a microtask for more "immediate" calling.
3897
3898         * html/HTMLCanvasElement.cpp:
3899         (WebCore::HTMLCanvasElement::paint):
3900         Ensure that the `InspectorInstrumentation` call is last. This matches what we expect, as
3901         before we were instrumenting right before is it about to paint.
3902
3903         * platform/graphics/GraphicsContext3D.h:
3904         (WebCore::GraphicsContext3D::Client::~Client): Added.
3905         (WebCore::GraphicsContext3D::addClient): Added.
3906         (WebCore::GraphicsContext3D::removeClient): Added.
3907         (WebCore::GraphicsContext3D::setWebGLContext): Deleted.
3908         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
3909         (WebCore::GraphicsContext3D::markLayerComposited):
3910         (WebCore::GraphicsContext3D::forceContextLost):
3911         (WebCore::GraphicsContext3D::recycleContext):
3912         (WebCore::GraphicsContext3D::dispatchContextChangedNotification):
3913         * html/canvas/WebGLRenderingContextBase.h:
3914         * html/canvas/WebGLRenderingContextBase.cpp:
3915         (WebCore::WebGLRenderingContextBase::WebGLRenderingContextBase):
3916         (WebCore::WebGLRenderingContextBase::destroyGraphicsContext3D):
3917         (WebCore::WebGLRenderingContextBase::didComposite): Added.
3918         (WebCore::WebGLRenderingContextBase::forceContextLost):
3919         (WebCore::WebGLRenderingContextBase::recycleContext):
3920         (WebCore::WebGLRenderingContextBase::dispatchContextChangedNotification): Added.
3921         (WebCore::WebGLRenderingContextBase::dispatchContextChangedEvent): Deleted.
3922         Introduce a `GraphicsContext3DClient` abstract class, rather than passing the
3923         `WebGLRenderingContextBase` directly to the `GraphicsContext3D` (layering violation).
3924         Notify the client whenever the `GraphicsContext3D` composites, which will in turn notify the
3925         `InspectorCanvasAgent` so that it knows that the "frame" is over.
3926
3927         * inspector/agents/InspectorCanvasAgent.h:
3928         * inspector/agents/InspectorCanvasAgent.cpp:
3929         (WebCore::InspectorCanvasAgent::InspectorCanvasAgent):
3930         (WebCore::InspectorCanvasAgent::requestNode):
3931         (WebCore::InspectorCanvasAgent::requestContent):
3932         (WebCore::InspectorCanvasAgent::requestCSSCanvasClientNodes):
3933         (WebCore::InspectorCanvasAgent::resolveCanvasContext):
3934         (WebCore::InspectorCanvasAgent::startRecording):
3935         (WebCore::InspectorCanvasAgent::stopRecording):
3936         (WebCore::InspectorCanvasAgent::requestShaderSource):
3937         (WebCore::InspectorCanvasAgent::updateShader):
3938         (WebCore::InspectorCanvasAgent::setShaderProgramDisabled):
3939         (WebCore::InspectorCanvasAgent::setShaderProgramHighlighted):
3940         (WebCore::InspectorCanvasAgent::didChangeCSSCanvasClientNodes):
3941         (WebCore::InspectorCanvasAgent::didChangeCanvasMemory):
3942         (WebCore::InspectorCanvasAgent::recordCanvasAction):
3943         (WebCore::InspectorCanvasAgent::canvasDestroyed):
3944         (WebCore::InspectorCanvasAgent::didFinishRecordingCanvasFrame):
3945         (WebCore::InspectorCanvasAgent::consoleStartRecordingCanvas):
3946         (WebCore::InspectorCanvasAgent::didEnableExtension):
3947         (WebCore::InspectorCanvasAgent::didCreateProgram):
3948         (WebCore::InspectorCanvasAgent::willDeleteProgram):
3949         (WebCore::InspectorCanvasAgent::isShaderProgramDisabled):
3950         (WebCore::InspectorCanvasAgent::isShaderProgramHighlighted):
3951         (WebCore::InspectorCanvasAgent::clearCanvasData):