Crash in RadioButtonGroups::requiredStateChanged
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2020-03-26  Ryosuke Niwa  <rniwa@webkit.org>
2
3         Crash in RadioButtonGroups::requiredStateChanged
4         https://bugs.webkit.org/show_bug.cgi?id=209585
5
6         Reviewed by Zalan Bujtas.
7
8         Like r254722, radio group could be null in RadioButtonGroups::requiredStateChanged. Added a null check.
9
10         Test: fast/forms/update-required-state-on-radio-before-finalizing-tree-insertion-crash.html
11
12         * dom/RadioButtonGroups.cpp:
13         (WebCore::RadioButtonGroups::requiredStateChanged):
14
15 2020-03-26  Charlie Turner  <cturner@igalia.com>
16
17         [GStreamer] Fix missing NULL-check in setSyncOnClock
18         https://bugs.webkit.org/show_bug.cgi?id=209609
19
20         Unreviewed, simple fix.
21
22         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
23         (WebCore::setSyncOnClock): Some systems are configured so that
24         audio sinks are not available. Make sure not to crash when asking
25         to sync with a NULL sink.
26
27 2020-03-26  Chris Dumez  <cdumez@apple.com>
28
29         REGRESSION: ASSERTION FAILED: m_wrapper on storage/indexeddb/modern/abort-requests tests
30         https://bugs.webkit.org/show_bug.cgi?id=209499
31         <rdar://problem/60842165>
32
33         Reviewed by Alex Christensen.
34
35         IDBTransaction::hasPendingActivity() was failing to consult ActiveDOMObject::hasPendingActivity()
36         so the JS wrapper would get garbage collected even though the ActiveDOMObject base class was
37         aware of some pending activity.
38
39         No new tests, unskipped existing tests.
40
41         * Modules/indexeddb/IDBTransaction.cpp:
42         (WebCore::IDBTransaction::hasPendingActivity const):
43
44 2020-03-25  Ryosuke Niwa  <rniwa@webkit.org>
45
46         Sequential focus navigation can't get out of a descendent of a slot element in a document tree
47         https://bugs.webkit.org/show_bug.cgi?id=199633
48
49         Reviewed by Darin Adler.
50
51         The bug was caused by slot element outside a shadow tree not being treated as a focus navigation
52         scope owner as specified in the HTML5 specification:
53         https://html.spec.whatwg.org/multipage/interaction.html#focus-navigation-scope-owner
54
55         Fixed the bug by treating it as such unless custom focusing behavior is used.
56
57         Test: fast/shadow-dom/focus-across-slot-outside-shadow-tree.html
58
59         * page/FocusController.cpp:
60         (WebCore::isFocusScopeOwner):
61
62 2020-03-26  Kate Cheney  <katherine_cheney@apple.com>
63
64         ScopeRuleSets::initializeUserStyle() should not add console logging if there are no injected user style sheets
65         https://bugs.webkit.org/show_bug.cgi?id=209548
66         <rdar://problem/60851745>
67
68         Reviewed by Darin Adler.
69
70         Logging when there are no injected user style sheets is unnecessary and confusing.
71
72         * style/StyleScopeRuleSets.cpp:
73         (WebCore::Style::ScopeRuleSets::initializeUserStyle):
74
75 2020-03-26  Alexey Proskuryakov  <ap@apple.com>
76
77         REGRESSION(r259042): It creates some test failures (Requested by youenn on #webkit).
78         Roll back the patch.
79
80 2020-03-26  Antti Koivisto  <antti@apple.com>
81
82         REGRESSION (r254669): Expand media button doesn't work on first try on photos on reddit.com
83         https://bugs.webkit.org/show_bug.cgi?id=209590
84         <rdar://problem/60461809>
85
86         Reviewed by Darin Adler.
87
88         Image intrinsic size computed from width/height attributes is ignored during preferred width computation
89         (used for float sizing in this case). This creates a mismatch between layout and preferred width computation,
90         causing the final image size to be miscomputed.
91
92         Test: fast/images/preferred-width-computation-with-attribute-intrinsic-size.html
93
94         * rendering/RenderReplaced.cpp:
95         (WebCore::RenderReplaced::computePreferredLogicalWidths const):
96
97         Compute attribute based intrinsic size already during preferred width computation if needed.
98
99 2020-03-26  Nikos Mouchtaris  <nmouchtaris@apple.com>
100
101         Remove manual redacting of billing contact after wallet fix for rdar://problem/59075234
102         https://bugs.webkit.org/show_bug.cgi?id=209557
103         <rdar://problem/60883506>
104
105         Reviewed by Andy Estes.
106
107         Removed manual redaction of billing address after wallet fixed
108         their redaction code.
109
110         No new tests. Current tests cover this functionality.
111
112         * Modules/applepay/cocoa/PaymentMethodCocoa.mm:
113         (WebCore::convert):
114
115 2020-03-26  Per Arne Vollan  <pvollan@apple.com>
116
117         [iOS] Adopt ScreenProperties class.
118         https://bugs.webkit.org/show_bug.cgi?id=191767
119
120         Reviewed by Brent Fulgham.
121
122         On macOS, the ScreenProperties class is used to collect screen properties in the UI process
123         and forward these to the Web process. We should also do this on iOS, in order to be able
124         to block frontboard services.
125  
126         No new tests. Covered by existing tests.
127
128         * Sources.txt:
129         * platform/PlatformScreen.h:
130         * platform/ScreenProperties.h:
131         (WebCore::ScreenData::encode const):
132         (WebCore::ScreenData::decode):
133         * platform/ios/PlatformScreenIOS.mm:
134         (WebCore::screenIsMonochrome):
135         (WebCore::screenHasInvertedColors):
136         (WebCore::screenSupportsExtendedColor):
137         (WebCore::collectScreenProperties):
138         * platform/mac/PlatformScreenMac.mm:
139         (WebCore::primaryOpenGLDisplayMask):
140         (WebCore::displayMaskForDisplay):
141         (WebCore::primaryGPUID):
142         (WebCore::gpuIDForDisplay):
143         (WebCore::screenIsMonochrome):
144         (WebCore::screenHasInvertedColors):
145         (WebCore::screenDepth):
146         (WebCore::screenDepthPerComponent):
147         (WebCore::screenRectForDisplay):
148         (WebCore::screenRect):
149         (WebCore::screenAvailableRect):
150         (WebCore::screenColorSpace):
151         (WebCore::screenSupportsExtendedColor):
152         (WebCore::screenProperties): Deleted.
153         (WebCore::primaryScreenDisplayID): Deleted.
154         (WebCore::setScreenProperties): Deleted.
155         (WebCore::screenData): Deleted.
156         (WebCore::getScreenProperties): Deleted.
157
158 2020-03-26  Rob Buis  <rbuis@igalia.com>
159
160         Take into account referrer-policy in append Origin header algorithm
161         https://bugs.webkit.org/show_bug.cgi?id=209066
162
163         Reviewed by Youenn Fablet.
164
165         Start taking into account referrer-policy in more places when we
166         append the origin header [1]. To prevent computing SecurityOrigin
167         needlessly add a helper function doesRequestNeedHTTPOriginHeader.
168
169         [1] https://fetch.spec.whatwg.org/#append-a-request-origin-header
170
171         * loader/FormSubmission.cpp:
172         (WebCore::FormSubmission::populateFrameLoadRequest):
173         * loader/FrameLoader.cpp:
174         (WebCore::FrameLoader::addExtraFieldsToRequest):
175         (WebCore::FrameLoader::loadResourceSynchronously):
176         (WebCore::FrameLoader::loadDifferentDocumentItem):
177         (WebCore::FrameLoader::addHTTPOriginIfNeeded): Deleted.
178         * loader/FrameLoader.h:
179         * loader/NavigationScheduler.cpp:
180         * loader/PingLoader.cpp:
181         (WebCore::PingLoader::sendPing):
182         * loader/SubresourceLoader.cpp:
183         (WebCore::SubresourceLoader::checkRedirectionCrossOriginAccessControl):
184         * loader/cache/CachedResourceRequest.cpp:
185         (WebCore::CachedResourceRequest::updateReferrerOriginAndUserAgentHeaders):
186         * platform/network/ResourceRequestBase.cpp:
187         (WebCore::doesRequestNeedHTTPOriginHeader):
188         * platform/network/ResourceRequestBase.h:
189
190 2020-03-25  Sihui Liu  <sihui_liu@apple.com>
191
192         IndexedDB: destroy UniqueIDBDatabase when it's not used
193         https://bugs.webkit.org/show_bug.cgi?id=209532
194
195         Reviewed by Geoffrey Garen.
196
197         Reviewed by Geoffrey Garen.
198
199         When all connections of a UniqueIDBDatabase object are closed and there are no pending reuqests, the 
200         object may not be used any more. We should delete it for better memory use.
201
202         * Modules/indexeddb/server/IDBServer.cpp:
203         (WebCore::IDBServer::IDBServer::removeUniqueIDBDatabase):
204         (WebCore::IDBServer::IDBServer::closeAndTakeUniqueIDBDatabase): Deleted.
205         * Modules/indexeddb/server/IDBServer.h:
206         * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
207         (WebCore::IDBServer::UniqueIDBDatabase::handleDelete):
208         (WebCore::IDBServer::UniqueIDBDatabase::connectionClosedFromClient):
209         (WebCore::IDBServer::UniqueIDBDatabase::tryCloseAndRemoveFromServer):
210         * Modules/indexeddb/server/UniqueIDBDatabase.h:
211
212 2020-03-25  Said Abou-Hallawa  <sabouhallawa@apple.com>
213
214         [ macOS ] svg/custom/textPath-change-id-pattern.svg is flakey failing
215         https://bugs.webkit.org/show_bug.cgi?id=208532
216
217         Reviewed by Darin Adler.
218
219         In this layout test, the id of a <path> element changes. This <path> is
220         referenced by a <textPath> element which is a child of a <pattern> element.
221         The <pattern> element is used to fill a <rect> element.
222
223         This patch ensures all clients (<rect>) of the resource ancestor (<pattern>)
224         of any sub-resource (<textPath>) is marked for repaint when the id of a
225         sub-sub-resource (<path>) changes.
226
227         * rendering/svg/RenderSVGResourceContainer.cpp:
228         (WebCore::RenderSVGResourceContainer::markAllClientsForRepaint):
229         * rendering/svg/RenderSVGResourceContainer.h:
230         * svg/SVGElement.cpp:
231         (WebCore::SVGElement::buildPendingResourcesIfNeeded):
232         (WebCore::SVGElement::invalidateInstances):
233         Unrelated change. This is a leftover from r179807 which was converting a
234         "do { } while();" statement to "while() { }" statement.
235
236 2020-03-25  Jack Lee  <shihchieh_lee@apple.com>
237
238         Nullptr crash in WebCore::Node::isDescendantOf when inserting list
239         https://bugs.webkit.org/show_bug.cgi?id=209529
240         <rdar://problem/60693542>
241
242         Reviewed by Darin Adler.
243
244         The visible positions may be null if the DOM tree is altered before an edit command is applied. 
245         Add null check for visible positions at the beginning of InsertListCommand::doApply.
246
247         Test: editing/inserting/insert-list-during-node-removal-crash.html
248
249         * editing/InsertListCommand.cpp:
250         (WebCore::InsertListCommand::doApply):
251
252 2020-03-25  Alexey Shvayka  <shvaikalesh@gmail.com>
253
254         Invalid numeric and named references should be early syntax errors
255         https://bugs.webkit.org/show_bug.cgi?id=178175
256
257         Reviewed by Ross Kirsling.
258
259         Accounts for changes of YarrParser's Delegate interface, no behavioral changes.
260         resetForReparsing() is never called because we disable numeric backrefences
261         and named forward references (see arguments of Yarr::parse() call).
262
263         Test: TestWebKitAPI.ContentExtensionTest.ParsingFailures
264
265         * contentextensions/URLFilterParser.cpp:
266         (WebCore::ContentExtensions::PatternParser::resetForReparsing):
267         (WebCore::ContentExtensions::URLFilterParser::addPattern):
268         (WebCore::ContentExtensions::PatternParser::isValidNamedForwardReference): Deleted.
269
270 2020-03-25  Pinki Gyanchandani  <pgyanchandani@apple.com>
271
272         CanvasRenderingContext2D.putImageData() should not process neutered ImageData
273         https://bugs.webkit.org/show_bug.cgi?id=208303
274
275         Reviewed by Said Abou-Hallawa.
276
277         Test: fast/canvas/canvas-putImageData-neutered-ImageData.html
278
279         The crash happens when putImageData is called on a neutered ImageData object. 
280         Added a check to exit from CanvasRenderingContext2D.putImageData() function when ImageData object is neutered.
281
282         * html/canvas/CanvasRenderingContext2DBase.cpp:
283         (WebCore::CanvasRenderingContext2DBase::putImageData):
284
285 2020-03-25  Chris Dumez  <cdumez@apple.com>
286
287         Use JSC::EnsureStillAliveScope RAII object in the generated bindings code
288         https://bugs.webkit.org/show_bug.cgi?id=209552
289
290         Reviewed by Yusuke Suzuki.
291
292         Use JSC::EnsureStillAliveScope RAII object in the generated bindings code
293         instead of explicit ensureStillAlive() calls. This makes the bindings
294         generator code simpler and results in nicer generated code too.
295
296         * bindings/scripts/CodeGeneratorJS.pm:
297         (GenerateParametersCheck):
298         (GenerateWriteBarriersForArguments):
299         (GenerateImplementationFunctionCall):
300         (GenerateEnsureStillAliveCallsForArguments): Deleted.
301         * bindings/scripts/test/JS/JSMapLike.cpp:
302         (WebCore::jsMapLikePrototypeFunctionGetBody):
303         (WebCore::jsMapLikePrototypeFunctionHasBody):
304         (WebCore::jsMapLikePrototypeFunctionForEachBody):
305         (WebCore::jsMapLikePrototypeFunctionSetBody):
306         (WebCore::jsMapLikePrototypeFunctionDeleteBody):
307         * bindings/scripts/test/JS/JSReadOnlyMapLike.cpp:
308         (WebCore::jsReadOnlyMapLikePrototypeFunctionGetBody):
309         (WebCore::jsReadOnlyMapLikePrototypeFunctionHasBody):
310         (WebCore::jsReadOnlyMapLikePrototypeFunctionForEachBody):
311         * bindings/scripts/test/JS/JSReadOnlySetLike.cpp:
312         (WebCore::jsReadOnlySetLikePrototypeFunctionHasBody):
313         (WebCore::jsReadOnlySetLikePrototypeFunctionForEachBody):
314         * bindings/scripts/test/JS/JSSetLike.cpp:
315         (WebCore::jsSetLikePrototypeFunctionHasBody):
316         (WebCore::jsSetLikePrototypeFunctionForEachBody):
317         (WebCore::jsSetLikePrototypeFunctionAddBody):
318         (WebCore::jsSetLikePrototypeFunctionDeleteBody):
319         * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
320         (WebCore::jsTestActiveDOMObjectPrototypeFunctionExcitingFunctionBody):
321         (WebCore::jsTestActiveDOMObjectPrototypeFunctionPostMessageBody):
322         (WebCore::jsTestActiveDOMObjectPrototypeFunctionOverloadedMethod1Body):
323         (WebCore::jsTestActiveDOMObjectPrototypeFunctionOverloadedMethod2Body):
324         * bindings/scripts/test/JS/JSTestCallTracer.cpp:
325         (WebCore::jsTestCallTracerPrototypeFunctionTestOperationWithArgumentsBody):
326         (WebCore::jsTestCallTracerPrototypeFunctionTestOperationWithNullableArgumentBody):
327         (WebCore::jsTestCallTracerPrototypeFunctionTestOperationWithVariantArgumentBody):
328         (WebCore::jsTestCallTracerPrototypeFunctionTestOperationWithNullableVariantArgumentBody):
329         (WebCore::jsTestCallTracerPrototypeFunctionTestOperationWithOptionalVariantArgumentBody):
330         (WebCore::jsTestCallTracerPrototypeFunctionTestOperationWithDefaultVariantArgumentBody):
331         * bindings/scripts/test/JS/JSTestDOMJIT.cpp:
332         (WebCore::jsTestDOMJITPrototypeFunctionGetAttributeBody):
333         (WebCore::jsTestDOMJITPrototypeFunctionItemBody):
334         (WebCore::jsTestDOMJITPrototypeFunctionGetElementByIdBody):
335         (WebCore::jsTestDOMJITPrototypeFunctionGetElementsByNameBody):
336         * bindings/scripts/test/JS/JSTestEnabledBySetting.cpp:
337         (WebCore::jsTestEnabledBySettingPrototypeFunctionEnabledBySettingOperationBody):
338         * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
339         (WebCore::JSTestEventConstructorConstructor::construct):
340         * bindings/scripts/test/JS/JSTestEventTarget.cpp:
341         (WebCore::jsTestEventTargetPrototypeFunctionItemBody):
342         * bindings/scripts/test/JS/JSTestGlobalObject.cpp:
343         (WebCore::jsTestGlobalObjectInstanceFunctionRegularOperationBody):
344         (WebCore::jsTestGlobalObjectInstanceFunctionEnabledAtRuntimeOperation1Body):
345         (WebCore::jsTestGlobalObjectInstanceFunctionEnabledAtRuntimeOperation2Body):
346         (WebCore::jsTestGlobalObjectConstructorFunctionEnabledAtRuntimeOperationStaticBody):
347         (WebCore::jsTestGlobalObjectInstanceFunctionEnabledInSpecificWorldBody):
348         (WebCore::jsTestGlobalObjectInstanceFunctionEnabledInSpecificWorldWhenRuntimeFeatureEnabledBody):
349         (WebCore::jsTestGlobalObjectInstanceFunctionEnabledInSpecificWorldWhenRuntimeFeaturesEnabledBody):
350         * bindings/scripts/test/JS/JSTestIndexedSetterWithIdentifier.cpp:
351         (WebCore::jsTestIndexedSetterWithIdentifierPrototypeFunctionIndexedSetterBody):
352         * bindings/scripts/test/JS/JSTestInterface.cpp:
353         (WebCore::JSTestInterfaceConstructor::construct):
354         (WebCore::jsTestInterfacePrototypeFunctionImplementsMethod2Body):
355         (WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod2Body):
356         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
357         (WebCore::jsTestMediaQueryListListenerPrototypeFunctionMethodBody):
358         * bindings/scripts/test/JS/JSTestNamedAndIndexedSetterWithIdentifier.cpp:
359         (WebCore::jsTestNamedAndIndexedSetterWithIdentifierPrototypeFunctionNamedSetterBody):
360         (WebCore::jsTestNamedAndIndexedSetterWithIdentifierPrototypeFunctionIndexedSetterBody):
361         * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
362         (WebCore::JSTestNamedConstructorNamedConstructor::construct):
363         * bindings/scripts/test/JS/JSTestNamedDeleterWithIdentifier.cpp:
364         (WebCore::jsTestNamedDeleterWithIdentifierPrototypeFunctionNamedDeleterBody):
365         * bindings/scripts/test/JS/JSTestNamedGetterWithIdentifier.cpp:
366         (WebCore::jsTestNamedGetterWithIdentifierPrototypeFunctionGetterNameBody):
367         * bindings/scripts/test/JS/JSTestNamedSetterWithIdentifier.cpp:
368         (WebCore::jsTestNamedSetterWithIdentifierPrototypeFunctionNamedSetterBody):
369         * bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetter.cpp:
370         (WebCore::jsTestNamedSetterWithIndexedGetterPrototypeFunctionNamedSetterBody):
371         (WebCore::jsTestNamedSetterWithIndexedGetterPrototypeFunctionIndexedSetterBody):
372         * bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetterAndSetter.cpp:
373         (WebCore::jsTestNamedSetterWithIndexedGetterAndSetterPrototypeFunctionNamedSetterBody):
374         (WebCore::jsTestNamedSetterWithIndexedGetterAndSetterPrototypeFunctionIndexedSetter1Body):
375         (WebCore::jsTestNamedSetterWithIndexedGetterAndSetterPrototypeFunctionIndexedSetter2Body):
376         * bindings/scripts/test/JS/JSTestObj.cpp:
377         (WebCore::JSTestObjConstructor::construct):
378         (WebCore::callJSTestObj1):
379         (WebCore::callJSTestObj2):
380         (WebCore::jsTestObjPrototypeFunctionEnabledAtRuntimeOperation1Body):
381         (WebCore::jsTestObjPrototypeFunctionEnabledAtRuntimeOperation2Body):
382         (WebCore::jsTestObjConstructorFunctionEnabledAtRuntimeOperationStaticBody):
383         (WebCore::jsTestObjPrototypeFunctionEnabledInSpecificWorldWhenRuntimeFeatureEnabledBody):
384         (WebCore::jsTestObjPrototypeFunctionWorldSpecificMethodBody):
385         (WebCore::jsTestObjPrototypeFunctionVoidMethodWithArgsBody):
386         (WebCore::jsTestObjPrototypeFunctionByteMethodWithArgsBody):
387         (WebCore::jsTestObjPrototypeFunctionOctetMethodWithArgsBody):
388         (WebCore::jsTestObjPrototypeFunctionLongMethodWithArgsBody):
389         (WebCore::jsTestObjPrototypeFunctionObjMethodWithArgsBody):
390         (WebCore::jsTestObjPrototypeFunctionMethodWithArgTreatingNullAsEmptyStringBody):
391         (WebCore::jsTestObjPrototypeFunctionMethodWithXPathNSResolverParameterBody):
392         (WebCore::jsTestObjPrototypeFunctionNullableStringSpecialMethodBody):
393         (WebCore::jsTestObjPrototypeFunctionMethodWithEnumArgBody):
394         (WebCore::jsTestObjPrototypeFunctionMethodWithStandaloneEnumArgBody):
395         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalEnumArgBody):
396         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalEnumArgAndDefaultValueBody):
397         (WebCore::jsTestObjPrototypeFunctionMethodThatRequiresAllArgsAndThrowsBody):
398         (WebCore::jsTestObjPrototypeFunctionMethodWithUSVStringArgBody):
399         (WebCore::jsTestObjPrototypeFunctionMethodWithNullableUSVStringArgBody):
400         (WebCore::jsTestObjPrototypeFunctionMethodWithUSVStringArgTreatingNullAsEmptyStringBody):
401         (WebCore::jsTestObjPrototypeFunctionMethodWithByteStringArgBody):
402         (WebCore::jsTestObjPrototypeFunctionMethodWithNullableByteStringArgBody):
403         (WebCore::jsTestObjPrototypeFunctionMethodWithByteStringArgTreatingNullAsEmptyStringBody):
404         (WebCore::jsTestObjPrototypeFunctionSerializedValueBody):
405         (WebCore::jsTestObjPrototypeFunctionMethodWithRecordBody):
406         (WebCore::jsTestObjPrototypeFunctionPrivateMethodBody):
407         (WebCore::jsTestObjPrototypeFunctionPublicAndPrivateMethodBody):
408         (WebCore::jsTestObjPrototypeFunctionAddEventListenerBody):
409         (WebCore::jsTestObjPrototypeFunctionRemoveEventListenerBody):
410         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalArgBody):
411         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalArgAndDefaultValueBody):
412         (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndOptionalArgBody):
413         (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndTwoOptionalArgsBody):
414         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringBody):
415         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalUSVStringBody):
416         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalAtomStringBody):
417         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringAndDefaultValueBody):
418         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalAtomStringAndDefaultValueBody):
419         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsNullBody):
420         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsUndefinedBody):
421         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalAtomStringIsNullBody):
422         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsEmptyStringBody):
423         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalUSVStringIsEmptyStringBody):
424         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalAtomStringIsEmptyStringBody):
425         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalDoubleIsNaNBody):
426         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalFloatIsNaNBody):
427         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalLongLongBody):
428         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalLongLongIsZeroBody):
429         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalUnsignedLongLongBody):
430         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalUnsignedLongLongIsZeroBody):
431         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalSequenceBody):
432         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalSequenceIsEmptyBody):
433         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalBooleanBody):
434         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalBooleanIsFalseBody):
435         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalAnyBody):
436         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalObjectBody):
437         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalNullableWrapperBody):
438         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalNullableWrapperIsNullBody):
439         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalXPathNSResolverBody):
440         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalRecordBody):
441         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalPromiseBody):
442         (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackArgBody):
443         (WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackArgBody):
444         (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackAndOptionalArgBody):
445         (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackFunctionArgBody):
446         (WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackFunctionArgBody):
447         (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackFunctionAndOptionalArgBody):
448         (WebCore::jsTestObjConstructorFunctionStaticMethodWithCallbackAndOptionalArgBody):
449         (WebCore::jsTestObjConstructorFunctionStaticMethodWithCallbackArgBody):
450         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod1Body):
451         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod2Body):
452         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod3Body):
453         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod4Body):
454         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod5Body):
455         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod6Body):
456         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod7Body):
457         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod8Body):
458         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod9Body):
459         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod10Body):
460         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod11Body):
461         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod12Body):
462         (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithOptionalParameter1Body):
463         (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithOptionalParameter2Body):
464         (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithDistinguishingUnion1Body):
465         (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithDistinguishingUnion2Body):
466         (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWith2DistinguishingUnions1Body):
467         (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWith2DistinguishingUnions2Body):
468         (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithNonDistinguishingUnion1Body):
469         (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithNonDistinguishingUnion2Body):
470         (WebCore::jsTestObjPrototypeFunctionOverloadWithNullableUnion1Body):
471         (WebCore::jsTestObjPrototypeFunctionOverloadWithNullableUnion2Body):
472         (WebCore::jsTestObjPrototypeFunctionOverloadWithOptionalUnion1Body):
473         (WebCore::jsTestObjPrototypeFunctionOverloadWithOptionalUnion2Body):
474         (WebCore::jsTestObjPrototypeFunctionOverloadWithNullableNonDistinguishingParameter1Body):
475         (WebCore::jsTestObjPrototypeFunctionOverloadWithNullableNonDistinguishingParameter2Body):
476         (WebCore::jsTestObjConstructorFunctionClassMethodWithOptionalBody):
477         (WebCore::jsTestObjConstructorFunctionOverloadedMethod11Body):
478         (WebCore::jsTestObjConstructorFunctionOverloadedMethod12Body):
479         (WebCore::jsTestObjPrototypeFunctionClassMethodWithClampBody):
480         (WebCore::jsTestObjPrototypeFunctionClassMethodWithClampOnOptionalBody):
481         (WebCore::jsTestObjPrototypeFunctionClassMethodWithEnforceRangeBody):
482         (WebCore::jsTestObjPrototypeFunctionClassMethodWithEnforceRangeOnOptionalBody):
483         (WebCore::jsTestObjPrototypeFunctionMethodWithUnsignedLongSequenceBody):
484         (WebCore::jsTestObjPrototypeFunctionStringArrayFunctionBody):
485         (WebCore::jsTestObjPrototypeFunctionDomStringListFunctionBody):
486         (WebCore::jsTestObjPrototypeFunctionOperationWithOptionalUnionParameterBody):
487         (WebCore::jsTestObjPrototypeFunctionMethodWithAndWithoutNullableSequenceBody):
488         (WebCore::jsTestObjPrototypeFunctionGetElementByIdBody):
489         (WebCore::jsTestObjPrototypeFunctionConvert1Body):
490         (WebCore::jsTestObjPrototypeFunctionConvert2Body):
491         (WebCore::jsTestObjPrototypeFunctionConvert3Body):
492         (WebCore::jsTestObjPrototypeFunctionConvert4Body):
493         (WebCore::jsTestObjPrototypeFunctionVariadicStringMethodBody):
494         (WebCore::jsTestObjPrototypeFunctionVariadicDoubleMethodBody):
495         (WebCore::jsTestObjPrototypeFunctionVariadicNodeMethodBody):
496         (WebCore::jsTestObjPrototypeFunctionVariadicUnionMethodBody):
497         (WebCore::jsTestObjPrototypeFunctionAnyBody):
498         (WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithFloatArgumentBody):
499         (WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithOptionalIntArgumentBody):
500         (WebCore::jsTestObjPrototypeFunctionTestPromiseOverloadedFunction1Body):
501         (WebCore::jsTestObjPrototypeFunctionTestPromiseOverloadedFunction2Body):
502         (WebCore::jsTestObjPrototypeFunctionConditionalOverload1Body):
503         (WebCore::jsTestObjPrototypeFunctionConditionalOverload2Body):
504         (WebCore::jsTestObjPrototypeFunctionSingleConditionalOverload1Body):
505         (WebCore::jsTestObjPrototypeFunctionSingleConditionalOverload2Body):
506         (WebCore::jsTestObjPrototypeFunctionAttachShadowRootBody):
507         (WebCore::jsTestObjPrototypeFunctionOperationWithExternalDictionaryParameterBody):
508         (WebCore::jsTestObjPrototypeFunctionBufferSourceParameterBody):
509         (WebCore::jsTestObjPrototypeFunctionLegacyCallerNamedBody):
510         (WebCore::jsTestObjPrototypeFunctionTestReturnValueOptimizationBody):
511         (WebCore::jsTestObjPrototypeFunctionTestReturnValueOptimizationWithExceptionBody):
512         * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
513         (WebCore::constructJSTestOverloadedConstructors1):
514         (WebCore::constructJSTestOverloadedConstructors2):
515         (WebCore::constructJSTestOverloadedConstructors3):
516         (WebCore::constructJSTestOverloadedConstructors4):
517         * bindings/scripts/test/JS/JSTestOverloadedConstructorsWithSequence.cpp:
518         (WebCore::constructJSTestOverloadedConstructorsWithSequence1):
519         (WebCore::constructJSTestOverloadedConstructorsWithSequence2):
520         * bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp:
521         (WebCore::jsTestOverrideBuiltinsPrototypeFunctionNamedItemBody):
522         * bindings/scripts/test/JS/JSTestPromiseRejectionEvent.cpp:
523         (WebCore::JSTestPromiseRejectionEventConstructor::construct):
524         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
525         (WebCore::jsTestSerializedScriptValueInterfacePrototypeFunctionFunctionBody):
526         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
527         (WebCore::JSTestTypedefsConstructor::construct):
528         (WebCore::jsTestTypedefsPrototypeFunctionFuncBody):
529         (WebCore::jsTestTypedefsPrototypeFunctionSetShadowBody):
530         (WebCore::jsTestTypedefsPrototypeFunctionMethodWithSequenceArgBody):
531         (WebCore::jsTestTypedefsPrototypeFunctionNullableSequenceArgBody):
532         (WebCore::jsTestTypedefsPrototypeFunctionSequenceOfNullablesArgBody):
533         (WebCore::jsTestTypedefsPrototypeFunctionNullableSequenceOfNullablesArgBody):
534         (WebCore::jsTestTypedefsPrototypeFunctionNullableSequenceOfUnionsArgBody):
535         (WebCore::jsTestTypedefsPrototypeFunctionUnionArgBody):
536         (WebCore::jsTestTypedefsPrototypeFunctionFuncWithClampBody):
537         (WebCore::jsTestTypedefsPrototypeFunctionFuncWithClampInTypedefBody):
538         (WebCore::jsTestTypedefsPrototypeFunctionStringSequenceFunctionBody):
539         (WebCore::jsTestTypedefsPrototypeFunctionStringSequenceFunction2Body):
540         (WebCore::jsTestTypedefsPrototypeFunctionCallWithSequenceThatRequiresIncludeBody):
541
542 2020-03-25  Wenson Hsieh  <wenson_hsieh@apple.com>
543
544         Unreviewed, fix the watchOS build after r259008
545
546         Put a call to Pasteboard::nameOfDragPasteboard behind ENABLE(DRAG_SUPPORT); additionally, update an out-of-date
547         comment to reflect the fact that arbitrary UIPasteboards can be converted to a list of NSItemProviders, whose
548         data can be traversed in fidelity order.
549
550         * platform/ios/PasteboardIOS.mm:
551         (WebCore::Pasteboard::respectsUTIFidelities const):
552
553 2020-03-25  Simon Fraser  <simon.fraser@apple.com>
554
555         Flashing and partly visible elements
556         https://bugs.webkit.org/show_bug.cgi?id=204605
557
558         Reviewed by Zalan Bujtas.
559
560         If, during a compositing update, a layer becomes non-composited, then we repaint its
561         location in its new target compositing layer. However, that layer might be in the list
562         of BackingSharingState's layers that may paint into backing provided by some ancestor,
563         so they'd be in a limbo state where their repaint target was unknown. We'd erroneously
564         repaint in some ancestor, resulting in missing content.
565
566         Fix by having BackingSharingState track a set of layers that can't be repainted currently
567         because their ancestor chain contains a maybe-sharing layer, and repaint them when
568         the backing sharing state is resolved.
569
570         This is only an issue during RenderLayerCompositor::computeCompositingRequirements()
571         when the backing sharing state is being computed, so most repaints are not affected.
572
573         Test: compositing/shared-backing/repaint-into-shared-backing.html
574
575         * rendering/RenderLayerCompositor.cpp:
576         (WebCore::RenderLayerCompositor::BackingSharingState::isPotentialBackingSharingLayer const):
577         (WebCore::RenderLayerCompositor::BackingSharingState::addLayerNeedingRepaint):
578         (WebCore::RenderLayerCompositor::BackingSharingState::endBackingSharingSequence):
579         (WebCore::RenderLayerCompositor::BackingSharingState::issuePendingRepaints):
580         (WebCore::RenderLayerCompositor::computeCompositingRequirements):
581         (WebCore::RenderLayerCompositor::updateBacking):
582         (WebCore::RenderLayerCompositor::updateLayerCompositingState):
583         (WebCore::RenderLayerCompositor::layerRepaintTargetsBackingSharingLayer const):
584         * rendering/RenderLayerCompositor.h:
585
586 2020-03-25  Chris Dumez  <cdumez@apple.com>
587
588         Event listeners registered with 'once' option may get garbage collected too soon
589         https://bugs.webkit.org/show_bug.cgi?id=209504
590         <rdar://problem/60541567>
591
592         Reviewed by Yusuke Suzuki.
593
594         In EventTarget::innerInvokeEventListeners, if the listener we're about to call is a one-time
595         listener (has 'once' flag set), we would first unregister the event listener and then call
596         it, as per the DOM specification. However, once unregistered, the event listener is no longer
597         visited for GC purposes and its internal JS Function may get garbage collected before we get
598         a chance to call it.
599
600         To address the issue, we now make sure the JS Function (and its wrapper) stay alive for the
601         duration of the scope using ensureStillAliveHere().
602
603         Test: http/tests/inspector/network/har/har-page-aggressive-gc.html
604
605         * bindings/js/JSEventListener.h:
606         * dom/EventListener.h:
607         (WebCore::EventListener::jsFunction const):
608         (WebCore::EventListener::wrapper const):
609         * dom/EventTarget.cpp:
610         (WebCore::EventTarget::innerInvokeEventListeners):
611
612 2020-03-25  Wenson Hsieh  <wenson_hsieh@apple.com>
613
614         Rename "data interaction pasteboard" to "drag and drop pasteboard"
615         https://bugs.webkit.org/show_bug.cgi?id=209556
616
617         Reviewed by Tim Horton.
618
619         "Data interaction" is an obsolete term for drag and drop on iOS, and was meant only to be used early on in
620         development. Replace this with the more descriptive name "drag and drop pasteboard", and additionally hide the
621         name behind a Cocoa-only Pasteboard helper method so that each call site won't need to repeat the string.
622
623         * platform/Pasteboard.h:
624         * platform/cocoa/DragDataCocoa.mm:
625         (WebCore::DragData::DragData):
626         * platform/ios/PasteboardIOS.mm:
627         (WebCore::Pasteboard::nameOfDragPasteboard):
628         (WebCore::Pasteboard::createForDragAndDrop):
629         (WebCore::Pasteboard::respectsUTIFidelities const):
630         * platform/ios/PlatformPasteboardIOS.mm:
631         (WebCore::PlatformPasteboard::PlatformPasteboard):
632         * platform/mac/PasteboardMac.mm:
633         (WebCore::Pasteboard::nameOfDragPasteboard):
634
635 2020-03-25  Frank Yang  <guowei_yang@apple.com>
636
637         Unprefix -webkit-text-orientation
638         https://bugs.webkit.org/show_bug.cgi?id=196139
639
640         Reviewed by Myles C. Maxfield
641
642         In order to unprefix -webkit-text-orientation to be text-orientation, 
643         a new property, "text-orientation" is added to CSSProperties.json. 
644         I didn't use alias because the prefixed version still supports non-standard values, 
645         and we want the unprefixed version to strictly follow the specs.
646         However only adding a new property is not enough because -webkit-text-orientation
647         is a high-priority property, and without extra logic, the CSS property 
648         "last-one-wins" ordering rule cannot be enforced because high-priority properties 
649         are applied to elements in the order they appear in the generated CSSPropertyNames.cpp file. 
650         Therefore a codegen flag, "related-property" is added to both 
651         -webkit-text-orientation and text-orientation to point to each other, 
652         so that when applying high priorities, the algorithm will know that the 
653         two properties are modifying the same style of the element (in our case, text orientation)
654         and thus the CSS property "last-one-wins" ordering rule will take effect. 
655
656         This code change also helps future developments when we want to unprefix other high-priority properties.
657
658         Tests: fast/text/orientation-inheritance.html
659                fast/text/orientation-mixed-unprefix.html
660                fast/text/orientation-sideways-prefix-unprefix.html
661                fast/text/orientation-sideways-unprefix.html
662                fast/text/orientation-upright-unprefix.html
663                fast/text/test-orientation-parsing-001.html
664                fast/text/text-orientation-parse-competition.html
665                fast/text/text-orientation-parse.html
666                imported/w3c/web-platform-tests/css/css-writing-modes/text-orientation-parsing-001.html
667
668         * css/CSSComputedStyleDeclaration.cpp: 
669             - added support for parsing "text-orientation"
670         (WebCore::ComputedStyleExtractor::valueForPropertyInStyle):
671             - added a new RenderStyle, CSSPropertyTextOrientation 
672         * css/CSSProperties.json: 
673             - added a new codegen property, "related-property"
674         * css/makeprop.pl: 
675             - added new rules for generating code to parse related properties
676         (addProperty):
677             - inserts new rule in the generated code to parse related properties
678         * css/parser/CSSParserFastPaths.cpp:
679             - Specified the CSS property values that the unprefixed "text-orientation" can take
680         (WebCore::CSSParserFastPaths::isValidKeywordPropertyAndValue):
681             - Only supports the standard values for text-orientation
682         (WebCore::CSSParserFastPaths::isKeywordPropertyID):
683             - Added switch case value CSSPropertyTextOrientation
684         * css/parser/CSSParserImpl.cpp: 
685             - Added rules to treat related properties differently
686         (WebCore::filterProperties):
687             - For related rules that are also high priority, 
688               if we saw one in the property list, we will mark all the related property 
689               as seen, in order to enforce the "last-one-wins" ordering rule
690         * style/StyleBuilderCustom.h:
691         (WebCore::Style::BuilderCustom::applyValueTextOrientation):
692             - added functionality to parse the newly added "text-orientation" property
693
694 2020-03-25  Simon Fraser  <simon.fraser@apple.com>
695
696         Remove CompositingChangeRepaint which was always CompositingChangeRepaintNow
697         https://bugs.webkit.org/show_bug.cgi?id=209551
698
699         Reviewed by Zalan Bujtas.
700
701         All callers to updateBacking() passed CompositingChangeRepaintNow, so remove this argument
702         and the enum.
703
704         No behavior change.
705
706         * rendering/RenderLayerCompositor.cpp:
707         (WebCore::RenderLayerCompositor::computeCompositingRequirements):
708         (WebCore::RenderLayerCompositor::layerStyleChanged):
709         (WebCore::RenderLayerCompositor::updateBacking):
710         (WebCore::RenderLayerCompositor::updateLayerCompositingState):
711         * rendering/RenderLayerCompositor.h:
712
713 2020-03-25  Sergio Villar Senin  <svillar@igalia.com>
714
715         Unreviewed build fix for GTK.
716
717         In wkb.ug/209536 we replaced ENABLE_WEBGL by ENABLE_WEBXR for cmake
718         builds. We just forgot to do it the same for derived sources.
719
720         * Sources.txt: replaced ENABLE_WEBGL by ENABLE_WEBXR.
721
722 2020-03-25  youenn fablet  <youenn@apple.com>
723
724         Fix build after https://trac.webkit.org/changeset/258977/webkit
725         https://bugs.webkit.org/show_bug.cgi?id=209545
726
727         Unreviewed.
728
729         * dom/Document.cpp:
730         (WebCore::Document::visibilityStateChanged):
731         Add ENABLE(MEDIA_STREAM) compilation flag.
732
733 2020-03-25  Frank Yang  <guowei_yang@apple.com>
734
735         WebKit uses Alphabetic Baseline when "-webkit-text-orientation" is "mixed" in Vertical Writing Mode
736         https://bugs.webkit.org/show_bug.cgi?id=208824
737
738         Reviewed by Myles C. Maxfield.
739
740         According to the CSS documentation, https://drafts.csswg.org/css-writing-modes/#text-orientation and 
741         https://drafts.csswg.org/css-writing-modes/#text-baselines "In vertical typographic mode, 
742         the central baseline is used as the dominant baseline when text-orientation is mixed or upright. 
743         Otherwise the alphabetic baseline is used." 
744
745         However, InlineFlowBox::requiresIdeographicsBaseline returns true only when text orientation is 
746         "upright", meaning it applies the same baseline for mixed and sideways text orientation.
747         Therefore, a new clause is added to check if text-orientation is "mixed" 
748
749         Currently in our implementation, text orientation is determinted by the following:
750                 - mixed:    FontDescription returns Vertical   and   nonCJKGlyphOrientation returns Mixed
751                 - upright:  FontDescription returns Vertical   and   nonCJKGlyphOrientation returns Upright
752                 - sideways: FontDescription returns Horizontal and   nonCJKGlyphOrientation returns Mixed
753         Original code only checks if FontDescription returns Vertical and nonCJKGlyphOrientation returns Mixed, which
754         is only checking if text orientation is "upright", and returns true for requiresIdeographicBaseline, treating        
755         "mixed" and "sideways" the same, requesting alphabetic baseline, which is incorrect.
756
757         Therefore, to correct this bahavior, change the code so that requiresIdeographicsBaseline returns true either 
758         when text-orientation is "mixed" or "upright". Equivalently, we return true when FontDescription returns Vertical
759         false otherwise. 
760
761         Test: imported/w3c/web-platform-tests/css/css-writing-modes/
762
763         * rendering/InlineFlowBox.cpp:
764         (WebCore::InlineFlowBox::requiresIdeographicBaseline const):
765
766 2020-03-25  Sergio Villar Senin  <svillar@igalia.com>
767
768         Use ENABLE_WEBXR to guard WebXR IDL files in CMakeLists.txt
769         https://bugs.webkit.org/show_bug.cgi?id=209536
770
771         Reviewed by Darin Adler.
772
773         * CMakeLists.txt: replaced ENABLE_WEBGL by ENABLE_WEBXR.
774
775 2020-03-25  Kate Cheney  <katherine_cheney@apple.com>
776
777         App-bound domain checks should provide more debugging details at script evaluation sites
778         https://bugs.webkit.org/show_bug.cgi?id=209521
779         <rdar://problem/60837954>
780
781         Reviewed by Chris Dumez.
782
783         * bindings/js/ScriptController.cpp:
784         (WebCore::ScriptController::executeScriptInWorld):
785         Return makeUnexpected object with an error message instead of null to
786         provide more details as to why the executeScriptInWorld()
787         call was not completed. Also add console logging and release logging.
788  
789         * page/Frame.cpp:
790         (WebCore::Frame::injectUserScriptImmediately):
791         There is no option to return an exception here, so this patch adds
792         console logging and release logging.
793
794 2020-03-25  Simon Fraser  <simon.fraser@apple.com>
795
796         REGRESSION (r251385): box-shadow interferes with backdrop-filter
797         https://bugs.webkit.org/show_bug.cgi?id=208070
798         <rdar://problem/59683152>
799
800         Reviewed by Dean Jackson.
801
802         updateClippingStrategy() compares the rounded rect passed in with the geometry
803         of the first layer argument, so the rect needs to have a zero origin. We do
804         the same computation in GraphicsLayerCA::updateContentsRects().
805
806         Test: compositing/filters/backdrop-filter-rect.html
807
808         * platform/graphics/ca/GraphicsLayerCA.cpp:
809         (WebCore::GraphicsLayerCA::updateBackdropFiltersRect):
810
811 2020-03-25  Wenson Hsieh  <wenson_hsieh@apple.com>
812
813         Avoid querying pasteboard strings while dragging content over a potential drop target
814         https://bugs.webkit.org/show_bug.cgi?id=209531
815
816         Reviewed by Tim Horton and Ryosuke Niwa.
817
818         A couple of places in WebCore currently use PasteboardStrategy::stringForType() to query for pasteboard URL
819         strings. These call sites attempt to read URL strings (using both readString and stringForType) for the purposes
820         of checking whether or not we should avoid exposing the URL string to web content (note that in the case of
821         containsPlainText, we actually check whether or not the string is empty, which depends on whether or not the
822         string is safe to expose to the web -- e.g., not a file URL).
823
824         This is incompatible with some changes in the near future which will prevent the web content process from
825         reading any data from the pasteboard, if a paste or drop action has not yet been performed. To address this
826         issue, we introduce an alternate PasteboardStrategy method, containsStringSafeForDOMToReadForType, which returns
827         (for a given platform pasteboard type) whether or not a string that can be safely exposed to bindings exists.
828
829         Rather than allow the web process to read the entire string, limit it to just this true/false answer.
830
831         * platform/PasteboardStrategy.h:
832         * platform/PlatformPasteboard.h:
833         * platform/cocoa/DragDataCocoa.mm:
834         (WebCore::DragData::containsPlainText const):
835
836         Use containsStringSafeForDOMToReadForType instead of stringForType.
837
838         * platform/cocoa/PasteboardCocoa.mm:
839         (WebCore::Pasteboard::fileContentState):
840
841         Use containsStringSafeForDOMToReadForType instead of readString.
842
843         * platform/cocoa/PlatformPasteboardCocoa.mm:
844         (WebCore::PlatformPasteboard::containsStringSafeForDOMToReadForType const):
845
846 2020-03-25  Ting-Wei Lan  <lantw44@gmail.com>
847
848         [GTK] Add user agent quirk for auth.mayohr.com
849         https://bugs.webkit.org/show_bug.cgi?id=209378
850
851         Reviewed by Michael Catanzaro.
852
853         This site blocks the login page completely and asks the user to download
854         Google Chrome when using our standard user agent. It only blocks the
855         login page. After logging in, it works fine without user agent quirks.
856
857         Note that it is required to hide Version/X from the user agent string
858         for the site to recognize it as a valid Chrome user agent. Since Chrome
859         itself does not use Version/X, it should be safe to modify the existing
860         quirk instead of adding a new one to handle it.
861
862         * platform/UserAgentQuirks.cpp:
863         (WebCore::urlRequiresChromeBrowser):
864         (WebCore::urlRequiresNoSafariVersion):
865         (WebCore::UserAgentQuirks::quirksForURL):
866         (WebCore::UserAgentQuirks::stringForQuirk):
867         * platform/UserAgentQuirks.h:
868         * platform/glib/UserAgentGLib.cpp:
869         (WebCore::buildUserAgentString):
870
871 2020-03-25  Youenn Fablet  <youenn@apple.com>
872
873         Audio fails to capture stream in WebRTC if AudioSession gets interrupted
874         https://bugs.webkit.org/show_bug.cgi?id=208516
875         <rdar://problem/60020467>
876
877         Reviewed by Eric Carlson.
878
879         In case of page going to hidden, continue calling each capture factory to mute the corresponding sources if needed.
880         In case of page being visible again, reset all tracks according page muted state. This allows restarting tracks that have been
881         muted while page was hidden (video tracks or suspended audio tracks).
882
883         Since tracks can go to muted when visibility changes, we no longer return early when setting the muted state of a page to the same value.
884         Instead we apply it which ensures we comply with what UIProcess wants.
885
886         We start removing the concept of a RealtimeMediaSource be interrupted. Instead we use muting of sources.
887         This allows UIProcess or the page to override any muted state, for instance if page goes in foreground again.
888
889         We update the AudioSharedUnit to allow restarting capture even if suspended.
890         This ensures that we are able to restart capturing even if we do not receive the audio session end of interruption.
891         Also, this notification sometimes takes a long time to happen and we do not want to wait for it when user is interacting with the page.
892         A future refactoring will further remove RealtimeMediaSource interrupted-related code.
893
894         Manually tested.
895
896         * dom/Document.cpp:
897         (WebCore::Document::visibilityStateChanged):
898         * page/Page.cpp:
899         (WebCore::Page::setMuted):
900         * platform/audio/PlatformMediaSessionManager.h:
901         (WebCore::PlatformMediaSessionManager::isInterrupted const):
902         * platform/mediastream/RealtimeMediaSource.cpp:
903         (WebCore::RealtimeMediaSource::setInterrupted):
904         (WebCore::RealtimeMediaSource::setMuted):
905         * platform/mediastream/mac/BaseAudioSharedUnit.cpp:
906         (WebCore::BaseAudioSharedUnit::startProducingData):
907         (WebCore::BaseAudioSharedUnit::resume):
908         (WebCore::BaseAudioSharedUnit::suspend):
909
910 2020-03-25  Charlie Turner  <cturner@igalia.com>
911
912         [GStreamer] Remove noisy warning about broken LC support
913         https://bugs.webkit.org/show_bug.cgi?id=209472
914
915         Reviewed by Philippe Normand.
916
917         * platform/graphics/gstreamer/GStreamerCommon.cpp:
918         (WebCore::initializeGStreamer): There's no seemingly nice way of
919         ensuring this message is issued once in WebKit the
920         lifetime. Issuing multiple times is upsetting users. We can't rely
921         on Gst logging at this point, and there's no established story of
922         using the LOG_CHANNEL stuff on WPE/GTK ports for suppressible
923         WebKit message AFAICT.
924
925 2020-03-24  Andres Gonzalez  <andresg_22@apple.com>
926
927         Avoid multiple unnecessary updates of the IsolatedTree.
928         https://bugs.webkit.org/show_bug.cgi?id=209409
929
930         Reviewed by Chris Fleizach.
931
932         AXObjectCache::notificationPostTimerFired was updating the isolated tree
933         in every single notification, causing a big performance hit.
934         This change filters out repeated notifications for the same node, thus
935         reducing significantly the number of times the isolated tree is updated.
936
937         * accessibility/AXObjectCache.cpp:
938         (WebCore::AXObjectCache::notificationPostTimerFired):
939         (WebCore::AXObjectCache::postNotification):
940         (WebCore::AXObjectCache::postTextStateChangeNotification):
941         (WebCore::AXObjectCache::generateIsolatedTree):
942         (WebCore::AXObjectCache::updateIsolatedTree):
943         (WebCore::appendIfNotContainsMatching): Helper function that might be
944         added to WTF::Vector.
945         (WebCore::createIsolatedTreeHierarchy): Became AXIsolatedTree::createSubtree
946         * accessibility/AXObjectCache.h:
947         * accessibility/AccessibilityObjectInterface.h:
948         (WebCore::AXCoreObject::childrenIDs):
949         * accessibility/isolatedtree/AXIsolatedTree.cpp:
950         (WebCore::AXIsolatedTree::removeTreeForPageID):
951         (WebCore::AXIsolatedTree::generateSubtree):
952         (WebCore::AXIsolatedTree::createSubtree):
953         (WebCore::AXIsolatedTree::updateNode): Updates only the given node.
954         (WebCore::AXIsolatedTree::updateSubtree): Recreates the entire subtree.
955         (WebCore::AXIsolatedTree::updateChildren): Updates the associated object,
956         recreating only the children that are added and removing the ones that
957         are no longer present in the AX tree.
958         (WebCore::AXIsolatedTree::removeNode):
959         (WebCore::AXIsolatedTree::removeSubtree):
960         (WebCore::AXIsolatedTree::appendNodeChanges):
961         (WebCore::AXIsolatedTree::applyPendingChanges):
962         * accessibility/isolatedtree/AXIsolatedTree.h:
963
964 2020-03-24  John Wilander  <wilander@apple.com>
965
966         Build fix for deprecated DDHighlightCreateWithRectsInVisibleRectWithStyleAndDirection
967         https://bugs.webkit.org/show_bug.cgi?id=209530
968         <rdar://problem/60855794>
969
970         Unreviewed build fix. Solution suggested by Darin Adler.
971
972         * page/mac/ServicesOverlayController.mm:
973         (WebCore::ServicesOverlayController::buildPhoneNumberHighlights):
974             Use of DDHighlightCreateWithRectsInVisibleRectWithStyleAndDirection put between
975             ALLOW_DEPRECATED_DECLARATIONS_BEGIN and ALLOW_DEPRECATED_DECLARATIONS_END.
976         (WebCore::ServicesOverlayController::buildSelectionHighlight):
977             Use of DDHighlightCreateWithRectsInVisibleRectWithStyleAndDirection put between
978             ALLOW_DEPRECATED_DECLARATIONS_BEGIN and ALLOW_DEPRECATED_DECLARATIONS_END.
979
980 2020-03-24  Zalan Bujtas  <zalan@apple.com>
981
982         [MultiColumn] Infinite recursion in RenderBlockFlow::relayoutToAvoidWidows
983         https://bugs.webkit.org/show_bug.cgi?id=209527
984         <rdar://problem/56993589>
985
986         Reviewed by Simon Fraser.
987
988         This patch expands on r204980. This is yet another case when we can't possibly accommodate widows in the current column.
989
990         Test: fast/multicol/page-cant-accommodate-widow-crash.html
991
992         * rendering/RenderBlockFlow.cpp:
993         (WebCore::RenderBlockFlow::adjustLinePositionForPagination):
994
995 2020-03-24  Wenson Hsieh  <wenson_hsieh@apple.com>
996
997         Rename DragDataMac and DragImageMac to DragDataCocoa and DragImageCocoa
998         https://bugs.webkit.org/show_bug.cgi?id=209523
999
1000         Reviewed by Megan Gardner.
1001
1002         Rename DragDataMac to DragDataCocoa, and DragImageMac to DragImageCocoa. These files contain logic relevant to
1003         both macOS and iOS, and as such, belong in platform/cocoa rather than platform/mac.
1004
1005         No change in behavior.
1006
1007         * SourcesCocoa.txt:
1008         * WebCore.xcodeproj/project.pbxproj:
1009         * platform/cocoa/DragDataCocoa.mm: Renamed from Source/WebCore/platform/mac/DragDataMac.mm.
1010         (WebCore::rtfPasteboardType):
1011         (WebCore::rtfdPasteboardType):
1012         (WebCore::stringPasteboardType):
1013         (WebCore::urlPasteboardType):
1014         (WebCore::htmlPasteboardType):
1015         (WebCore::colorPasteboardType):
1016         (WebCore::pdfPasteboardType):
1017         (WebCore::tiffPasteboardType):
1018         (WebCore::DragData::DragData):
1019         (WebCore::DragData::containsURLTypeIdentifier const):
1020         (WebCore::DragData::canSmartReplace const):
1021         (WebCore::DragData::containsColor const):
1022         (WebCore::DragData::containsFiles const):
1023         (WebCore::DragData::numberOfFiles const):
1024         (WebCore::DragData::asFilenames const):
1025         (WebCore::DragData::containsPlainText const):
1026         (WebCore::DragData::asPlainText const):
1027         (WebCore::DragData::asColor const):
1028         (WebCore::DragData::containsCompatibleContent const):
1029         (WebCore::DragData::containsPromise const):
1030         (WebCore::DragData::containsURL const):
1031         (WebCore::DragData::asURL const):
1032         * platform/cocoa/DragImageCocoa.mm: Renamed from Source/WebCore/platform/mac/DragImageMac.mm.
1033         (WebCore::dragImageSize):
1034         (WebCore::deleteDragImage):
1035         (WebCore::scaleDragImage):
1036         (WebCore::dissolveDragImageToFraction):
1037         (WebCore::createDragImageFromImage):
1038         (WebCore::createDragImageIconForCachedImageFilename):
1039         (WebCore::dragOffsetForLinkDragImage):
1040         (WebCore::anchorPointForLinkDragImage):
1041         (WebCore::LinkImageLayout::LinkImageLayout):
1042         (WebCore::createDragImageForLink):
1043         (WebCore::createDragImageForColor):
1044         * platform/graphics/gpu/cocoa/GPUShaderModuleMetal.mm:
1045
1046         Unrelated build fix due to changing unified sources.
1047
1048 2020-03-24  Jer Noble  <jer.noble@apple.com>
1049
1050         REGRESSION(r258314): Leak in MediaPlayerPrivateMediaSourceAVFObjC::updateLastPixelBuffer()
1051         https://bugs.webkit.org/show_bug.cgi?id=209519
1052
1053         Reviewed by Eric Carlson.
1054
1055         Obey the "copy" rule and adopt the results of -copyPixelBufferForSourceTime:sourceTimeForDisplay:.
1056
1057         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
1058         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::updateLastPixelBuffer):
1059
1060 2020-03-24  Jiewen Tan  <jiewen_tan@apple.com>
1061
1062         [WebAuthn] Customize a bit more on the macOS LocalAuthentication prompt
1063         https://bugs.webkit.org/show_bug.cgi?id=208703
1064         <rdar://problem/60136974>
1065
1066         Reviewed by Brent Fulgham.
1067
1068         Part 2.
1069
1070         This patch adds a different LocalAuthentication prompt title for getAssertion.
1071         It also polishes the text used for makeCredential.
1072
1073         Besides that, it also enhances the iOS title strings.
1074
1075         * en.lproj/Localizable.strings:
1076         * platform/LocalizedStrings.cpp:
1077         (WebCore::getAssertionTouchIDPromptTitle):
1078         * platform/LocalizedStrings.h:
1079
1080 2020-03-24  Chris Dumez  <cdumez@apple.com>
1081
1082         Function passed to addEventListener may get garbage collected before the event listener is even added
1083         https://bugs.webkit.org/show_bug.cgi?id=209445
1084
1085         Reviewed by Yusuke Suzuki.
1086
1087         Function passed to addEventListener may get garbage collected before the event listener is even added.
1088         The issue is that the JS bindings for addEventListener() would first create a JSEventListener to store
1089         the JSC Function that was passed in and then add this JSEventListener as an event listener on the
1090         EventTarget. The JSC function held by JSEventListener is supposed to get visited by
1091         JSEventListener::visitJSFunction() which gets called by EventTarget::visitJSEventListeners() which
1092         gets called every time an EventTarget wrapper gets visited. The issue is that when the JSEventListener
1093         gets created, the JSEventListener is not yet connected to its EventTarget and thus
1094         EventTarget::visitJSEventListeners() would not visit it. However, the constructor of JSEventListener
1095         would issue a write barrier on that JSC Function.
1096
1097         Several changes were made to address this issue in the generated bindings:
1098         1. We now create a local variable (named argumentX, X being argument index) for each argument that gets
1099            passed in to an operation
1100         2. At the end of the operation implementation, we call ensureStillAliveHere() on each JSValue argument
1101            to make sure they stay alive until the end of the operation
1102         3. For EventListeners / EventHandlers, we also issue a write barrier at the end of the operation
1103            implementation, when it is safe to do so. Now that we do this here in the bindings, I dropped the
1104            code in the JSEventListener constructor to issue the write barrier (as this was too early).
1105
1106         * bindings/js/JSEventListener.cpp:
1107         (WebCore::JSEventListener::JSEventListener):
1108         * bindings/scripts/CodeGeneratorJS.pm:
1109         (GetOperationReturnedParameterName):
1110         (GenerateAttributeSetterBodyDefinition):
1111         (GenerateParametersCheck):
1112         (GenerateEnsureStillAliveCallsForArguments):
1113         (GenerateImplementationFunctionCall):
1114         * bindings/scripts/test/JS/JSMapLike.cpp:
1115         (WebCore::jsMapLikePrototypeFunctionGetBody):
1116         (WebCore::jsMapLikePrototypeFunctionHasBody):
1117         (WebCore::jsMapLikePrototypeFunctionEntriesBody):
1118         (WebCore::jsMapLikePrototypeFunctionKeysBody):
1119         (WebCore::jsMapLikePrototypeFunctionValuesBody):
1120         (WebCore::jsMapLikePrototypeFunctionForEachBody):
1121         (WebCore::jsMapLikePrototypeFunctionSetBody):
1122         (WebCore::jsMapLikePrototypeFunctionDeleteBody):
1123         * bindings/scripts/test/JS/JSReadOnlyMapLike.cpp:
1124         (WebCore::jsReadOnlyMapLikePrototypeFunctionGetBody):
1125         (WebCore::jsReadOnlyMapLikePrototypeFunctionHasBody):
1126         (WebCore::jsReadOnlyMapLikePrototypeFunctionEntriesBody):
1127         (WebCore::jsReadOnlyMapLikePrototypeFunctionKeysBody):
1128         (WebCore::jsReadOnlyMapLikePrototypeFunctionValuesBody):
1129         (WebCore::jsReadOnlyMapLikePrototypeFunctionForEachBody):
1130         * bindings/scripts/test/JS/JSReadOnlySetLike.cpp:
1131         (WebCore::jsReadOnlySetLikePrototypeFunctionHasBody):
1132         (WebCore::jsReadOnlySetLikePrototypeFunctionEntriesBody):
1133         (WebCore::jsReadOnlySetLikePrototypeFunctionKeysBody):
1134         (WebCore::jsReadOnlySetLikePrototypeFunctionValuesBody):
1135         (WebCore::jsReadOnlySetLikePrototypeFunctionForEachBody):
1136         * bindings/scripts/test/JS/JSSetLike.cpp:
1137         (WebCore::jsSetLikePrototypeFunctionHasBody):
1138         (WebCore::jsSetLikePrototypeFunctionEntriesBody):
1139         (WebCore::jsSetLikePrototypeFunctionKeysBody):
1140         (WebCore::jsSetLikePrototypeFunctionValuesBody):
1141         (WebCore::jsSetLikePrototypeFunctionForEachBody):
1142         (WebCore::jsSetLikePrototypeFunctionAddBody):
1143         (WebCore::jsSetLikePrototypeFunctionDeleteBody):
1144         * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
1145         (WebCore::jsTestActiveDOMObjectPrototypeFunctionExcitingFunctionBody):
1146         (WebCore::jsTestActiveDOMObjectPrototypeFunctionPostMessageBody):
1147         (WebCore::jsTestActiveDOMObjectPrototypeFunctionOverloadedMethod1Body):
1148         (WebCore::jsTestActiveDOMObjectPrototypeFunctionOverloadedMethod2Body):
1149         * bindings/scripts/test/JS/JSTestCEReactionsStringifier.cpp:
1150         (WebCore::jsTestCEReactionsStringifierPrototypeFunctionToStringBody):
1151         * bindings/scripts/test/JS/JSTestCallTracer.cpp:
1152         (WebCore::jsTestCallTracerPrototypeFunctionTestOperationWithArgumentsBody):
1153         (WebCore::jsTestCallTracerPrototypeFunctionTestOperationWithNullableArgumentBody):
1154         (WebCore::jsTestCallTracerPrototypeFunctionTestOperationWithVariantArgumentBody):
1155         (WebCore::jsTestCallTracerPrototypeFunctionTestOperationWithNullableVariantArgumentBody):
1156         (WebCore::jsTestCallTracerPrototypeFunctionTestOperationWithOptionalVariantArgumentBody):
1157         (WebCore::jsTestCallTracerPrototypeFunctionTestOperationWithDefaultVariantArgumentBody):
1158         * bindings/scripts/test/JS/JSTestDOMJIT.cpp:
1159         (WebCore::jsTestDOMJITPrototypeFunctionGetAttributeBody):
1160         (WebCore::jsTestDOMJITPrototypeFunctionItemBody):
1161         (WebCore::jsTestDOMJITPrototypeFunctionHasAttributeBody):
1162         (WebCore::jsTestDOMJITPrototypeFunctionGetElementByIdBody):
1163         (WebCore::jsTestDOMJITPrototypeFunctionGetElementsByNameBody):
1164         * bindings/scripts/test/JS/JSTestEnabledBySetting.cpp:
1165         (WebCore::jsTestEnabledBySettingPrototypeFunctionEnabledBySettingOperationBody):
1166         * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
1167         (WebCore::JSTestEventConstructorConstructor::construct):
1168         * bindings/scripts/test/JS/JSTestEventTarget.cpp:
1169         (WebCore::jsTestEventTargetPrototypeFunctionItemBody):
1170         * bindings/scripts/test/JS/JSTestGlobalObject.cpp:
1171         (WebCore::jsTestGlobalObjectInstanceFunctionRegularOperationBody):
1172         (WebCore::jsTestGlobalObjectInstanceFunctionEnabledAtRuntimeOperation1Body):
1173         (WebCore::jsTestGlobalObjectInstanceFunctionEnabledAtRuntimeOperation2Body):
1174         (WebCore::jsTestGlobalObjectConstructorFunctionEnabledAtRuntimeOperationStaticBody):
1175         (WebCore::jsTestGlobalObjectInstanceFunctionEnabledInSpecificWorldBody):
1176         (WebCore::jsTestGlobalObjectInstanceFunctionEnabledInSpecificWorldWhenRuntimeFeatureEnabledBody):
1177         (WebCore::jsTestGlobalObjectInstanceFunctionEnabledInSpecificWorldWhenRuntimeFeaturesEnabledBody):
1178         (WebCore::jsTestGlobalObjectInstanceFunctionGetSecretBooleanBody):
1179         (WebCore::jsTestGlobalObjectInstanceFunctionTestFeatureGetSecretBooleanBody):
1180         * bindings/scripts/test/JS/JSTestIndexedSetterWithIdentifier.cpp:
1181         (WebCore::jsTestIndexedSetterWithIdentifierPrototypeFunctionIndexedSetterBody):
1182         * bindings/scripts/test/JS/JSTestInterface.cpp:
1183         (WebCore::JSTestInterfaceConstructor::construct):
1184         (WebCore::jsTestInterfacePrototypeFunctionImplementsMethod2Body):
1185         (WebCore::jsTestInterfacePrototypeFunctionTakeNodesBody):
1186         (WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod2Body):
1187         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
1188         (WebCore::jsTestMediaQueryListListenerPrototypeFunctionMethodBody):
1189         * bindings/scripts/test/JS/JSTestNamedAndIndexedSetterWithIdentifier.cpp:
1190         (WebCore::jsTestNamedAndIndexedSetterWithIdentifierPrototypeFunctionNamedSetterBody):
1191         (WebCore::jsTestNamedAndIndexedSetterWithIdentifierPrototypeFunctionIndexedSetterBody):
1192         * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
1193         (WebCore::JSTestNamedConstructorNamedConstructor::construct):
1194         * bindings/scripts/test/JS/JSTestNamedDeleterWithIdentifier.cpp:
1195         (WebCore::jsTestNamedDeleterWithIdentifierPrototypeFunctionNamedDeleterBody):
1196         * bindings/scripts/test/JS/JSTestNamedGetterWithIdentifier.cpp:
1197         (WebCore::jsTestNamedGetterWithIdentifierPrototypeFunctionGetterNameBody):
1198         * bindings/scripts/test/JS/JSTestNamedSetterWithIdentifier.cpp:
1199         (WebCore::jsTestNamedSetterWithIdentifierPrototypeFunctionNamedSetterBody):
1200         * bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetter.cpp:
1201         (WebCore::jsTestNamedSetterWithIndexedGetterPrototypeFunctionNamedSetterBody):
1202         (WebCore::jsTestNamedSetterWithIndexedGetterPrototypeFunctionIndexedSetterBody):
1203         * bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetterAndSetter.cpp:
1204         (WebCore::jsTestNamedSetterWithIndexedGetterAndSetterPrototypeFunctionNamedSetterBody):
1205         (WebCore::jsTestNamedSetterWithIndexedGetterAndSetterPrototypeFunctionIndexedSetter1Body):
1206         (WebCore::jsTestNamedSetterWithIndexedGetterAndSetterPrototypeFunctionIndexedSetter2Body):
1207         * bindings/scripts/test/JS/JSTestNode.cpp:
1208         (WebCore::jsTestNodePrototypeFunctionGetSecretBooleanBody):
1209         (WebCore::jsTestNodePrototypeFunctionTestFeatureGetSecretBooleanBody):
1210         * bindings/scripts/test/JS/JSTestObj.cpp:
1211         (WebCore::JSTestObjConstructor::construct):
1212         (WebCore::callJSTestObj1):
1213         (WebCore::callJSTestObj2):
1214         (WebCore::setJSTestObjOnfooSetter):
1215         (WebCore::setJSTestObjOnwebkitfooSetter):
1216         (WebCore::jsTestObjPrototypeFunctionEnabledAtRuntimeOperation1Body):
1217         (WebCore::jsTestObjPrototypeFunctionEnabledAtRuntimeOperation2Body):
1218         (WebCore::jsTestObjConstructorFunctionEnabledAtRuntimeOperationStaticBody):
1219         (WebCore::jsTestObjPrototypeFunctionEnabledInSpecificWorldWhenRuntimeFeatureEnabledBody):
1220         (WebCore::jsTestObjPrototypeFunctionWorldSpecificMethodBody):
1221         (WebCore::jsTestObjPrototypeFunctionGetSecretBooleanBody):
1222         (WebCore::jsTestObjPrototypeFunctionTestFeatureGetSecretBooleanBody):
1223         (WebCore::jsTestObjPrototypeFunctionVoidMethodWithArgsBody):
1224         (WebCore::jsTestObjPrototypeFunctionByteMethodBody):
1225         (WebCore::jsTestObjPrototypeFunctionByteMethodWithArgsBody):
1226         (WebCore::jsTestObjPrototypeFunctionOctetMethodBody):
1227         (WebCore::jsTestObjPrototypeFunctionOctetMethodWithArgsBody):
1228         (WebCore::jsTestObjPrototypeFunctionLongMethodBody):
1229         (WebCore::jsTestObjPrototypeFunctionLongMethodWithArgsBody):
1230         (WebCore::jsTestObjPrototypeFunctionObjMethodBody):
1231         (WebCore::jsTestObjPrototypeFunctionObjMethodWithArgsBody):
1232         (WebCore::jsTestObjInstanceFunctionUnforgeableMethodBody):
1233         (WebCore::jsTestObjPrototypeFunctionMethodWithArgTreatingNullAsEmptyStringBody):
1234         (WebCore::jsTestObjPrototypeFunctionMethodWithXPathNSResolverParameterBody):
1235         (WebCore::jsTestObjPrototypeFunctionNullableStringMethodBody):
1236         (WebCore::jsTestObjConstructorFunctionNullableStringStaticMethodBody):
1237         (WebCore::jsTestObjPrototypeFunctionNullableStringSpecialMethodBody):
1238         (WebCore::jsTestObjPrototypeFunctionMethodWithEnumArgBody):
1239         (WebCore::jsTestObjPrototypeFunctionMethodWithStandaloneEnumArgBody):
1240         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalEnumArgBody):
1241         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalEnumArgAndDefaultValueBody):
1242         (WebCore::jsTestObjPrototypeFunctionMethodThatRequiresAllArgsAndThrowsBody):
1243         (WebCore::jsTestObjPrototypeFunctionMethodWithUSVStringArgBody):
1244         (WebCore::jsTestObjPrototypeFunctionMethodWithNullableUSVStringArgBody):
1245         (WebCore::jsTestObjPrototypeFunctionMethodWithUSVStringArgTreatingNullAsEmptyStringBody):
1246         (WebCore::jsTestObjPrototypeFunctionMethodWithByteStringArgBody):
1247         (WebCore::jsTestObjPrototypeFunctionMethodWithNullableByteStringArgBody):
1248         (WebCore::jsTestObjPrototypeFunctionMethodWithByteStringArgTreatingNullAsEmptyStringBody):
1249         (WebCore::jsTestObjPrototypeFunctionSerializedValueBody):
1250         (WebCore::jsTestObjPrototypeFunctionMethodWithRecordBody):
1251         (WebCore::jsTestObjPrototypeFunctionMethodWithExceptionReturningLongBody):
1252         (WebCore::jsTestObjPrototypeFunctionMethodWithExceptionReturningObjectBody):
1253         (WebCore::jsTestObjPrototypeFunctionPrivateMethodBody):
1254         (WebCore::jsTestObjPrototypeFunctionPublicAndPrivateMethodBody):
1255         (WebCore::jsTestObjPrototypeFunctionAddEventListenerBody):
1256         (WebCore::jsTestObjPrototypeFunctionRemoveEventListenerBody):
1257         (WebCore::jsTestObjPrototypeFunctionWithExecStateObjBody):
1258         (WebCore::jsTestObjPrototypeFunctionWithExecStateObjExceptionBody):
1259         (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndExecStateObjExceptionBody):
1260         (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndExecStateWithSpacesBody):
1261         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalArgBody):
1262         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalArgAndDefaultValueBody):
1263         (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndOptionalArgBody):
1264         (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndTwoOptionalArgsBody):
1265         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringBody):
1266         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalUSVStringBody):
1267         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalAtomStringBody):
1268         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringAndDefaultValueBody):
1269         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalAtomStringAndDefaultValueBody):
1270         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsNullBody):
1271         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsUndefinedBody):
1272         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalAtomStringIsNullBody):
1273         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsEmptyStringBody):
1274         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalUSVStringIsEmptyStringBody):
1275         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalAtomStringIsEmptyStringBody):
1276         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalDoubleIsNaNBody):
1277         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalFloatIsNaNBody):
1278         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalLongLongBody):
1279         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalLongLongIsZeroBody):
1280         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalUnsignedLongLongBody):
1281         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalUnsignedLongLongIsZeroBody):
1282         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalSequenceBody):
1283         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalSequenceIsEmptyBody):
1284         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalBooleanBody):
1285         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalBooleanIsFalseBody):
1286         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalAnyBody):
1287         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalObjectBody):
1288         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalNullableWrapperBody):
1289         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalNullableWrapperIsNullBody):
1290         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalXPathNSResolverBody):
1291         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalRecordBody):
1292         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalPromiseBody):
1293         (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackArgBody):
1294         (WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackArgBody):
1295         (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackAndOptionalArgBody):
1296         (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackFunctionArgBody):
1297         (WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackFunctionArgBody):
1298         (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackFunctionAndOptionalArgBody):
1299         (WebCore::jsTestObjConstructorFunctionStaticMethodWithCallbackAndOptionalArgBody):
1300         (WebCore::jsTestObjConstructorFunctionStaticMethodWithCallbackArgBody):
1301         (WebCore::jsTestObjPrototypeFunctionConditionalMethod1Body):
1302         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod1Body):
1303         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod2Body):
1304         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod3Body):
1305         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod4Body):
1306         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod5Body):
1307         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod6Body):
1308         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod7Body):
1309         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod8Body):
1310         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod9Body):
1311         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod10Body):
1312         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod11Body):
1313         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod12Body):
1314         (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithOptionalParameter1Body):
1315         (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithOptionalParameter2Body):
1316         (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithDistinguishingUnion1Body):
1317         (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithDistinguishingUnion2Body):
1318         (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWith2DistinguishingUnions1Body):
1319         (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWith2DistinguishingUnions2Body):
1320         (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithNonDistinguishingUnion1Body):
1321         (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithNonDistinguishingUnion2Body):
1322         (WebCore::jsTestObjPrototypeFunctionOverloadWithNullableUnion1Body):
1323         (WebCore::jsTestObjPrototypeFunctionOverloadWithNullableUnion2Body):
1324         (WebCore::jsTestObjPrototypeFunctionOverloadWithOptionalUnion1Body):
1325         (WebCore::jsTestObjPrototypeFunctionOverloadWithOptionalUnion2Body):
1326         (WebCore::jsTestObjPrototypeFunctionOverloadWithNullableNonDistinguishingParameter1Body):
1327         (WebCore::jsTestObjPrototypeFunctionOverloadWithNullableNonDistinguishingParameter2Body):
1328         (WebCore::jsTestObjConstructorFunctionClassMethodWithOptionalBody):
1329         (WebCore::jsTestObjConstructorFunctionOverloadedMethod11Body):
1330         (WebCore::jsTestObjConstructorFunctionOverloadedMethod12Body):
1331         (WebCore::jsTestObjPrototypeFunctionClassMethodWithClampBody):
1332         (WebCore::jsTestObjPrototypeFunctionClassMethodWithClampOnOptionalBody):
1333         (WebCore::jsTestObjPrototypeFunctionClassMethodWithEnforceRangeBody):
1334         (WebCore::jsTestObjPrototypeFunctionClassMethodWithEnforceRangeOnOptionalBody):
1335         (WebCore::jsTestObjPrototypeFunctionMethodWithUnsignedLongSequenceBody):
1336         (WebCore::jsTestObjPrototypeFunctionStringArrayFunctionBody):
1337         (WebCore::jsTestObjPrototypeFunctionDomStringListFunctionBody):
1338         (WebCore::jsTestObjPrototypeFunctionOperationWithOptionalUnionParameterBody):
1339         (WebCore::jsTestObjPrototypeFunctionMethodWithAndWithoutNullableSequenceBody):
1340         (WebCore::jsTestObjPrototypeFunctionGetElementByIdBody):
1341         (WebCore::jsTestObjPrototypeFunctionGetSVGDocumentBody):
1342         (WebCore::jsTestObjPrototypeFunctionConvert1Body):
1343         (WebCore::jsTestObjPrototypeFunctionConvert2Body):
1344         (WebCore::jsTestObjPrototypeFunctionConvert3Body):
1345         (WebCore::jsTestObjPrototypeFunctionConvert4Body):
1346         (WebCore::jsTestObjPrototypeFunctionMutablePointFunctionBody):
1347         (WebCore::jsTestObjPrototypeFunctionVariadicStringMethodBody):
1348         (WebCore::jsTestObjPrototypeFunctionVariadicDoubleMethodBody):
1349         (WebCore::jsTestObjPrototypeFunctionVariadicNodeMethodBody):
1350         (WebCore::jsTestObjPrototypeFunctionVariadicUnionMethodBody):
1351         (WebCore::jsTestObjPrototypeFunctionAnyBody):
1352         (WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithFloatArgumentBody):
1353         (WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithOptionalIntArgumentBody):
1354         (WebCore::jsTestObjPrototypeFunctionTestPromiseOverloadedFunction1Body):
1355         (WebCore::jsTestObjPrototypeFunctionTestPromiseOverloadedFunction2Body):
1356         (WebCore::jsTestObjPrototypeFunctionTestReturnsOwnPromiseAndPromiseProxyFunctionBody):
1357         (WebCore::jsTestObjPrototypeFunctionConditionalOverload1Body):
1358         (WebCore::jsTestObjPrototypeFunctionConditionalOverload2Body):
1359         (WebCore::jsTestObjPrototypeFunctionSingleConditionalOverload1Body):
1360         (WebCore::jsTestObjPrototypeFunctionSingleConditionalOverload2Body):
1361         (WebCore::jsTestObjPrototypeFunctionAttachShadowRootBody):
1362         (WebCore::jsTestObjPrototypeFunctionOperationWithExternalDictionaryParameterBody):
1363         (WebCore::jsTestObjPrototypeFunctionBufferSourceParameterBody):
1364         (WebCore::jsTestObjPrototypeFunctionLegacyCallerNamedBody):
1365         (WebCore::jsTestObjPrototypeFunctionTestReturnValueOptimizationBody):
1366         (WebCore::jsTestObjPrototypeFunctionTestReturnValueOptimizationWithExceptionBody):
1367         (WebCore::jsTestObjPrototypeFunctionToStringBody):
1368         * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
1369         (WebCore::constructJSTestOverloadedConstructors1):
1370         (WebCore::constructJSTestOverloadedConstructors2):
1371         (WebCore::constructJSTestOverloadedConstructors3):
1372         (WebCore::constructJSTestOverloadedConstructors4):
1373         * bindings/scripts/test/JS/JSTestOverloadedConstructorsWithSequence.cpp:
1374         (WebCore::constructJSTestOverloadedConstructorsWithSequence1):
1375         (WebCore::constructJSTestOverloadedConstructorsWithSequence2):
1376         * bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp:
1377         (WebCore::jsTestOverrideBuiltinsPrototypeFunctionNamedItemBody):
1378         * bindings/scripts/test/JS/JSTestPromiseRejectionEvent.cpp:
1379         (WebCore::JSTestPromiseRejectionEventConstructor::construct):
1380         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
1381         (WebCore::jsTestSerializedScriptValueInterfacePrototypeFunctionFunctionBody):
1382         (WebCore::jsTestSerializedScriptValueInterfacePrototypeFunctionFunctionReturningBody):
1383         * bindings/scripts/test/JS/JSTestStringifier.cpp:
1384         (WebCore::jsTestStringifierPrototypeFunctionToStringBody):
1385         * bindings/scripts/test/JS/JSTestStringifierAnonymousOperation.cpp:
1386         (WebCore::jsTestStringifierAnonymousOperationPrototypeFunctionToStringBody):
1387         * bindings/scripts/test/JS/JSTestStringifierNamedOperation.cpp:
1388         (WebCore::jsTestStringifierNamedOperationPrototypeFunctionIdentifierBody):
1389         (WebCore::jsTestStringifierNamedOperationPrototypeFunctionToStringBody):
1390         * bindings/scripts/test/JS/JSTestStringifierOperationImplementedAs.cpp:
1391         (WebCore::jsTestStringifierOperationImplementedAsPrototypeFunctionIdentifierBody):
1392         (WebCore::jsTestStringifierOperationImplementedAsPrototypeFunctionToStringBody):
1393         * bindings/scripts/test/JS/JSTestStringifierOperationNamedToString.cpp:
1394         (WebCore::jsTestStringifierOperationNamedToStringPrototypeFunctionToStringBody):
1395         * bindings/scripts/test/JS/JSTestStringifierReadOnlyAttribute.cpp:
1396         (WebCore::jsTestStringifierReadOnlyAttributePrototypeFunctionToStringBody):
1397         * bindings/scripts/test/JS/JSTestStringifierReadWriteAttribute.cpp:
1398         (WebCore::jsTestStringifierReadWriteAttributePrototypeFunctionToStringBody):
1399         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
1400         (WebCore::JSTestTypedefsConstructor::construct):
1401         (WebCore::jsTestTypedefsPrototypeFunctionFuncBody):
1402         (WebCore::jsTestTypedefsPrototypeFunctionSetShadowBody):
1403         (WebCore::jsTestTypedefsPrototypeFunctionMethodWithSequenceArgBody):
1404         (WebCore::jsTestTypedefsPrototypeFunctionNullableSequenceArgBody):
1405         (WebCore::jsTestTypedefsPrototypeFunctionSequenceOfNullablesArgBody):
1406         (WebCore::jsTestTypedefsPrototypeFunctionNullableSequenceOfNullablesArgBody):
1407         (WebCore::jsTestTypedefsPrototypeFunctionNullableSequenceOfUnionsArgBody):
1408         (WebCore::jsTestTypedefsPrototypeFunctionUnionArgBody):
1409         (WebCore::jsTestTypedefsPrototypeFunctionFuncWithClampBody):
1410         (WebCore::jsTestTypedefsPrototypeFunctionFuncWithClampInTypedefBody):
1411         (WebCore::jsTestTypedefsPrototypeFunctionPointFunctionBody):
1412         (WebCore::jsTestTypedefsPrototypeFunctionStringSequenceFunctionBody):
1413         (WebCore::jsTestTypedefsPrototypeFunctionStringSequenceFunction2Body):
1414         (WebCore::jsTestTypedefsPrototypeFunctionCallWithSequenceThatRequiresIncludeBody):
1415
1416 2020-03-24  Alex Christensen  <achristensen@webkit.org>
1417
1418         Add console message when legacy TLS is used
1419         https://bugs.webkit.org/show_bug.cgi?id=209444
1420
1421         Reviewed by Darin Adler.
1422
1423         * loader/ResourceLoader.cpp:
1424         (WebCore::ResourceLoader::didReceiveResponse):
1425         Indent less, add host to inspector, add release logging without host.
1426
1427 2020-03-24  Antoine Quint  <graouts@apple.com>
1428
1429         [Web Animations] Clean timeline headers up
1430         https://bugs.webkit.org/show_bug.cgi?id=209482
1431
1432         Reviewed by Antti Koivisto.
1433
1434         The AnimationTimeline::removeAnimationsForElement() method isn't used and DocumentTimeline::applyPendingAcceleratedAnimations()
1435         is only used internally in DocumentTimeline so it can be made private.
1436
1437         * animation/AnimationTimeline.cpp:
1438         (WebCore::AnimationTimeline::removeAnimationsForElement): Deleted.
1439         * animation/AnimationTimeline.h:
1440         * animation/DocumentTimeline.h:
1441
1442 2020-03-24  Antoine Quint  <graouts@apple.com>
1443
1444         [iOS+macOS Debug] ASSERTION FAILED: m_effects.isEmpty() in WebCore::KeyframeEffectStack::~KeyframeEffectStack()
1445         https://bugs.webkit.org/show_bug.cgi?id=208718
1446         <rdar://problem/59956433>
1447
1448         Reviewed by Darin Adler.
1449
1450         This assertion is only valid in the case where elements with relevant animations are still alive when the document is
1451         torn down. However, it's fine to have an Element be destroyed with a relevant animation while its document is still alive.
1452
1453         * animation/KeyframeEffectStack.cpp:
1454         (WebCore::KeyframeEffectStack::~KeyframeEffectStack):
1455
1456 2020-03-23  Simon Fraser  <simon.fraser@apple.com>
1457
1458         Safari jetsams with repeated drawImage/getImageData
1459         https://bugs.webkit.org/show_bug.cgi?id=207957
1460
1461         Reviewed by Tim Horton.
1462
1463         SubimageCacheWithTimer used a DeferrableOneShotTimer to clear itself, but if content
1464         adds an entry to the cache on every frame (as might content drawing video frames into a canvas)
1465         then the cache was never cleared. Nor was it cleared via a memory warning.
1466
1467         Fix by tracking cache entries by age, and using a repeating timer to prune old images
1468         from the cache. Also hook up the cache to the memory pressure handler, which clears it.
1469
1470         Reduce the timer frequency from 1s to 500ms, since that was observed to reduce the memory use
1471         on the provided testcase from ~600M to ~350M, making jetsam less likely.
1472
1473         Rename m_images to m_imageCounts to make its role clearer.
1474
1475         * page/cocoa/MemoryReleaseCocoa.mm:
1476         (WebCore::platformReleaseMemory):
1477         * platform/graphics/cg/SubimageCacheWithTimer.cpp:
1478         (WebCore::SubimageCacheWithTimer::clear):
1479         (WebCore::SubimageCacheAdder::translate):
1480         (WebCore::SubimageCacheWithTimer::SubimageCacheWithTimer):
1481         (WebCore::SubimageCacheWithTimer::pruneCacheTimerFired):
1482         (WebCore::SubimageCacheWithTimer::prune):
1483         (WebCore::SubimageCacheWithTimer::subimage):
1484         (WebCore::SubimageCacheWithTimer::clearImageAndSubimages):
1485         (WebCore::SubimageCacheWithTimer::clearAll):
1486         (WebCore::SubimageCacheWithTimer::invalidateCacheTimerFired): Deleted.
1487         * platform/graphics/cg/SubimageCacheWithTimer.h:
1488
1489 2020-03-23  Stephan Szabo  <stephan.szabo@sony.com>
1490
1491         [WinCairo][PlayStation] Failure to build with ENABLE_XSLT=OFF
1492         https://bugs.webkit.org/show_bug.cgi?id=209454
1493
1494         Reviewed by Ross Kirsling.
1495
1496         No new tests, build fix.
1497
1498         * xml/parser/XMLDocumentParserLibxml2.cpp:
1499
1500 2020-03-23  Zalan Bujtas  <zalan@apple.com>
1501
1502         becu.org: Placeholder text "Search" is cut off
1503         https://bugs.webkit.org/show_bug.cgi?id=209447
1504         <rdar://problem/45951728>
1505
1506         Reviewed by Simon Fraser.
1507
1508         'line-height: initial' ensures that that the placeholder text is visible and properly positioned when the input itself has
1509         incompatible values. This is also what Chrome has in their UA stylesheet.
1510
1511         Test: fast/forms/placeholder-content-line-height.html
1512
1513         * css/html.css:
1514         (input::placeholder):
1515
1516 2020-03-23  Simon Fraser  <simon.fraser@apple.com>
1517
1518         [mac-wk1] fast/scrolling/arrow-key-scroll-in-rtl-document.html is a flaky timeout
1519         https://bugs.webkit.org/show_bug.cgi?id=209427
1520
1521         Reviewed by Wenson Hsieh.
1522
1523         In WebKit1, arrow-key scrolls are instantaneous, so scrolling is complete before the test
1524         registers the 'monitor wheel events' callback. However, nothing triggers a subsequent rendering
1525         update, so the test never completes.
1526
1527         Fix by having WheelEventTestMonitor::setTestCallbackAndStartMonitoring() trigger a rendering
1528         update.
1529
1530         * page/WheelEventTestMonitor.cpp:
1531         (WebCore::WheelEventTestMonitor::setTestCallbackAndStartMonitoring):
1532
1533 2020-03-23  Zalan Bujtas  <zalan@apple.com>
1534
1535         [LFC] Layout::Box::initialContainingBlock() should return const InitialContainingBlock&
1536         https://bugs.webkit.org/show_bug.cgi?id=209406
1537         <rdar://problem/60749715>
1538
1539         Reviewed by Antti Koivisto.
1540
1541         Use is<InitialContainingBlock> where applicable.
1542
1543         * layout/FormattingContext.cpp:
1544         (WebCore::Layout::FormattingContext::geometryForBox const):
1545         (WebCore::Layout::FormattingContext::collectOutOfFlowDescendantsIfNeeded):
1546         * layout/FormattingContextQuirks.cpp:
1547         (WebCore::Layout::FormattingContext::Quirks::heightValueOfNearestContainingBlockWithFixedHeight):
1548         * layout/blockformatting/BlockFormattingContextQuirks.cpp:
1549         * layout/displaytree/DisplayPainter.cpp:
1550         (WebCore::Display::absoluteDisplayBox):
1551         * layout/invalidation/InvalidationState.cpp:
1552         (WebCore::Layout::InvalidationState::markNeedsUpdate):
1553         * layout/layouttree/LayoutBox.cpp:
1554         (WebCore::Layout::Box::establishesBlockFormattingContext const):
1555         (WebCore::Layout::Box::containingBlock const):
1556         (WebCore::Layout::Box::formattingContextRoot const):
1557         (WebCore::Layout::Box::initialContainingBlock const):
1558         (WebCore::Layout::Box::isInFormattingContextOf const):
1559         (WebCore::Layout::Box::isOverflowVisible const):
1560         * layout/layouttree/LayoutBox.h:
1561         (WebCore::Layout::Box::isInitialContainingBlock const):
1562         (WebCore::Layout::Box::isInlineTextBox const):
1563         (WebCore::Layout::Box::isLineBreakBox const):
1564         (WebCore::Layout::Box::isReplacedBox const):
1565         * layout/layouttree/LayoutInitialContainingBlock.cpp:
1566         (WebCore::Layout::InitialContainingBlock::InitialContainingBlock):
1567         * layout/layouttree/LayoutInlineTextBox.cpp:
1568         (WebCore::Layout::InlineTextBox::InlineTextBox):
1569         * layout/layouttree/LayoutLineBreakBox.cpp:
1570         (WebCore::Layout::LineBreakBox::LineBreakBox):
1571         * layout/layouttree/LayoutReplacedBox.cpp:
1572         (WebCore::Layout::ReplacedBox::ReplacedBox):
1573         * layout/layouttree/LayoutTreeBuilder.cpp:
1574         (WebCore::Layout::outputLayoutBox):
1575
1576 2020-03-23  Justin Fan  <justin_fan@apple.com>
1577
1578         [ Mac wk2 Debug ] webgpu/whlsl/vector-compare.html is flaky crashing.
1579         https://bugs.webkit.org/show_bug.cgi?id=209024
1580
1581         Reviewed by Myles C. Maxfield.
1582
1583         Prevent GPUBindGroup destructor from accidentally dereferencing GPUBindGroupAllocator too many times
1584         if the owning GPUDevice has already been destroyed. A GPUBindGroupAllocator should reset whenever its
1585         spawned GPUBindGroups are all cleaned up. 
1586
1587         Covered by existing tests.
1588
1589         * platform/graphics/gpu/GPUBindGroupAllocator.h:
1590         * platform/graphics/gpu/cocoa/GPUBindGroupAllocatorMetal.mm:
1591         (WebCore::GPUBindGroupAllocator::allocateAndSetEncoders):
1592         (WebCore::GPUBindGroupAllocator::tryReset):
1593         * platform/graphics/gpu/cocoa/GPUBindGroupMetal.mm:
1594         (WebCore::GPUBindGroup::~GPUBindGroup):
1595
1596 2020-03-23  Wenson Hsieh  <wenson_hsieh@apple.com>
1597
1598         Remove the unused method PasteboardStrategy::uniqueName()
1599         https://bugs.webkit.org/show_bug.cgi?id=209452
1600
1601         Reviewed by Tim Horton.
1602
1603         This was introduced in <https://trac.webkit.org/r107844>, where it was used in the implementation of
1604         Editor::newGeneralClipboard. However, this was subsequently removed in <https://trac.webkit.org/r150351>.
1605
1606         No change in behavior.
1607
1608         * platform/PasteboardStrategy.h:
1609         * platform/PlatformPasteboard.h:
1610         * platform/ios/PlatformPasteboardIOS.mm:
1611         (WebCore::PlatformPasteboard::uniqueName): Deleted.
1612         * platform/mac/PlatformPasteboardMac.mm:
1613         (WebCore::PlatformPasteboard::uniqueName): Deleted.
1614
1615 2020-03-23  Alex Christensen  <achristensen@webkit.org>
1616
1617         Add console message when legacy TLS is used
1618         https://bugs.webkit.org/show_bug.cgi?id=209444
1619
1620         Reviewed by Darin Adler.
1621
1622         * loader/ResourceLoader.cpp:
1623         (WebCore::ResourceLoader::didReceiveResponse):
1624
1625 2020-03-23  John Wilander  <wilander@apple.com>
1626
1627         Add the capability to change all of a website's cookies to SameSite=Strict
1628         https://bugs.webkit.org/show_bug.cgi?id=209369
1629         <rdar://problem/60710690>
1630
1631         Reviewed by Alex Christensen and David Kilzer.
1632
1633         Test: http/tests/resourceLoadStatistics/set-all-cookies-to-same-site-strict.html
1634
1635         * platform/network/NetworkStorageSession.cpp:
1636         (WebCore::NetworkStorageSession::setAllCookiesToSameSiteStrict):
1637             Stub function for non-Cocoa platforms.
1638         * platform/network/NetworkStorageSession.h:
1639         * platform/network/cocoa/NetworkStorageSessionCocoa.mm:
1640         (WebCore::NetworkStorageSession::setAllCookiesToSameSiteStrict):
1641         * testing/Internals.h:
1642             Added code to expose SameSite=None and path properties of cookies.
1643             However, they don't seem to carry over so I'll have to revisit the
1644             internal workings.
1645
1646 2020-03-23  Michael Catanzaro  <mcatanzaro@gnome.org>
1647
1648         [WPE][GTK] Allow distributors to brand user agent
1649         https://bugs.webkit.org/show_bug.cgi?id=162611
1650
1651         Unreviewed, un-break my previous commit.
1652
1653         * platform/glib/UserAgentGLib.cpp:
1654         (WebCore::standardUserAgent):
1655
1656 2020-03-23  Simon Fraser  <simon.fraser@apple.com>
1657
1658         [iOS WK2] compositing/overflow/dynamic-composited-scrolling-status.html asserts
1659         https://bugs.webkit.org/show_bug.cgi?id=209440
1660         <rdar://problem/60705261>
1661
1662         Reviewed by Wenson Hsieh.
1663
1664         nonFastScrollableRectsForTesting() needs to eagerly update event regions after r258528,
1665         as we do for touchEventRectsForEventForTesting().
1666
1667         Also renamed the function so it's clear that it's for testing only.
1668
1669         * page/Page.cpp:
1670         (WebCore::Page::nonFastScrollableRectsForTesting):
1671         (WebCore::Page::nonFastScrollableRects): Deleted.
1672         * page/Page.h:
1673         * testing/Internals.cpp:
1674         (WebCore::Internals::nonFastScrollableRects const):
1675
1676 2020-03-24  James Darpinian  <jdarpinian@chromium.org>
1677
1678         Set important EGL context attributes
1679         https://bugs.webkit.org/show_bug.cgi?id=208724
1680
1681         Reviewed by Dean Jackson.
1682
1683         Re-landing this change after r258875.
1684
1685         These EGL context attributes are important to make ANGLE's validation correct for
1686         WebGL contexts. ROBUST_RESOURCE_INITIALIZATION is especially important; the lack
1687         of it may be a root cause of some of the test flakiness we have seen. With this
1688         change WebKit's EGL context attributes now match Chromium's for ANGLE/WebGL
1689         contexts.
1690
1691         * platform/graphics/cocoa/GraphicsContextGLOpenGLCocoa.mm:
1692         (WebCore::GraphicsContextGLOpenGL::GraphicsContextGLOpenGL):
1693
1694 2020-03-23  Michael Catanzaro  <mcatanzaro@gnome.org>
1695
1696         [GTK] Allow distributors to brand user agent
1697         https://bugs.webkit.org/show_bug.cgi?id=162611
1698
1699         Reviewed by Adrian Perez de Castro.
1700
1701         * platform/glib/UserAgentGLib.cpp:
1702         (WebCore::buildUserAgentString):
1703
1704 2020-03-23  Dean Jackson  <dino@apple.com>
1705
1706         [WebGL] Skip vertexAttrib0 simulation when using ANGLE
1707         https://bugs.webkit.org/show_bug.cgi?id=209416
1708         <rdar://problem/60765734>
1709
1710         Reviewed by Antoine Quint.
1711
1712         When using ANGLE as a backend, we do not need to simulate a
1713         missing vertexAttrib0 at the WebGL layer, since ANGLE will
1714         handle it for us.
1715
1716         This causes a couple of tests to begin passing (they were marked as
1717         failures). It also allows us to re-land r258025, which was rolled
1718         out in r258226.
1719
1720         * html/canvas/WebGL2RenderingContext.cpp: Wrap any code that does vertexAttrib0
1721         simulation in a !USE(ANGLE).
1722         (WebCore::WebGL2RenderingContext::initializeVertexArrayObjects):
1723         * html/canvas/WebGLRenderingContext.cpp:
1724         (WebCore::WebGLRenderingContext::initializeVertexArrayObjects):
1725         * html/canvas/WebGLRenderingContextBase.cpp:
1726         (WebCore::WebGLRenderingContextBase::~WebGLRenderingContextBase):
1727         (WebCore::WebGLRenderingContextBase::disableVertexAttribArray):
1728         (WebCore::WebGLRenderingContextBase::validateDrawArrays):
1729         (WebCore::WebGLRenderingContextBase::validateDrawElements):
1730         (WebCore::WebGLRenderingContextBase::drawArrays):
1731         (WebCore::WebGLRenderingContextBase::drawElements):
1732         (WebCore::WebGLRenderingContextBase::getActiveUniform):
1733         (WebCore::WebGLRenderingContextBase::getVertexAttrib):
1734         (WebCore::WebGLRenderingContextBase::vertexAttribfImpl):
1735         (WebCore::WebGLRenderingContextBase::vertexAttribfvImpl):
1736         * html/canvas/WebGLRenderingContextBase.h:
1737         * html/canvas/WebGLVertexArrayObjectBase.cpp:
1738         (WebCore::WebGLVertexArrayObjectBase::unbindBuffer):
1739
1740 2020-03-23  Darin Adler  <darin@apple.com>
1741
1742         Change TextIterator::rangeLength to not require a live range
1743         https://bugs.webkit.org/show_bug.cgi?id=209207
1744
1745         Reviewed by Antti Koivisto.
1746
1747         - Renamed TextIterator::rangeLength to characterCount.
1748
1749         * accessibility/AXObjectCache.cpp:
1750         (WebCore::AXObjectCache::rangeMatchesTextNearRange): Use characterCount.
1751         (WebCore::resetNodeAndOffsetForReplacedNode): Ditto.
1752         (WebCore::AXObjectCache::nextCharacterOffset): Ditto.
1753         * accessibility/atk/AXObjectCacheAtk.cpp:
1754         (WebCore::AXObjectCache::nodeTextChangePlatformNotification): Ditto.
1755         * accessibility/atk/WebKitAccessibleHyperlink.cpp:
1756         (rangeLengthForObject): Ditto.
1757         * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
1758         (-[WebAccessibilityObjectWrapper _convertToNSRange:]): Ditto.
1759
1760         * dom/SimpleRange.h: Export another constructor.
1761
1762         * editing/AlternativeTextController.cpp:
1763         (WebCore::AlternativeTextController::applyAlternativeTextToRange):
1764         Use characterCount.
1765         * editing/ApplyStyleCommand.cpp:
1766         (WebCore::ApplyStyleCommand::applyBlockStyle): Ditto.
1767         * editing/CompositeEditCommand.cpp:
1768         (WebCore::CompositeEditCommand::moveParagraphs): Ditto.
1769         * editing/Editing.cpp:
1770         (WebCore::indexForVisiblePosition): Ditto.
1771         * editing/TextCheckingHelper.cpp:
1772         (WebCore::TextCheckingParagraph::rangeLength const): Ditto.
1773         (WebCore::TextCheckingParagraph::offsetTo const): Ditto.
1774         (WebCore::TextCheckingParagraph::checkingStart const): Ditto.
1775         (WebCore::TextCheckingParagraph::checkingEnd const): Ditto.
1776         (WebCore::TextCheckingParagraph::checkingLength const): Ditto.
1777         (WebCore::TextCheckingParagraph::automaticReplacementStart const): Ditto.
1778         (WebCore::TextCheckingParagraph::automaticReplacementLength const): Ditto.
1779         (WebCore::TextCheckingHelper::findFirstMisspellingOrBadGrammar): Ditto.
1780         (WebCore::TextCheckingHelper::isUngrammatical const): Ditto.
1781
1782         * editing/TextIterator.cpp:
1783         (WebCore::TextIterator::rangeLength): Deleted.
1784         (WebCore::characterCount): Like the baove but the argument is SimpleRange
1785         and return is CharacterCount. Even though each individual node is limited
1786         to 32-bit size, ranges covering multiple nodes could have a count of
1787         characters that exceeds 32 bits, so CharacterCount is size_t.
1788         (WebCore::TextIterator::getLocationAndLengthFromRange): Use characterCount.
1789
1790         * editing/TextIterator.h: Added characterCount function,
1791         CharacterCount and CharacterRange types. Removed TextIterator::rangeLength.
1792         Added FIXME comments about the next steps.
1793
1794         * editing/VisiblePosition.cpp:
1795         (WebCore::makeBoundaryPoint): Added.
1796         * editing/VisiblePosition.h: Added makeBoundaryPoint. Also removed
1797         extraneous forward declarations and moved some function bodies out of the
1798         class definition.
1799
1800         * editing/VisibleUnits.cpp:
1801         (WebCore::distanceBetweenPositions): Changed return type to ptrdiff_t.
1802         Use characterCount.
1803         * editing/VisibleUnits.h: Updated for the above.
1804
1805         * editing/cocoa/DataDetection.mm:
1806         (WebCore::detectItemAtPositionWithRange): Use characterCount.
1807         * editing/cocoa/DictionaryLookup.mm:
1808         (WebCore::DictionaryLookup::rangeForSelection): Ditto.
1809         (WebCore::DictionaryLookup::rangeAtHitTestResult): Ditto.
1810         * editing/ios/DictationCommandIOS.cpp:
1811         (WebCore::DictationCommandIOS::doApply): Ditto.
1812         * editing/mac/DictionaryLookupLegacy.mm:
1813         (WebCore::DictionaryLookup::rangeForSelection): Ditto.
1814         (WebCore::DictionaryLookup::rangeAtHitTestResult): Ditto.
1815         * page/EventHandler.cpp:
1816         (WebCore::textDistance): Ditto.
1817
1818 2020-03-23  youenn fablet  <youenn@apple.com>
1819
1820         Rename blankURL to aboutBlankURL
1821         https://bugs.webkit.org/show_bug.cgi?id=209344
1822
1823         Reviewed by Darin Adler.
1824
1825         No change of behavior.
1826
1827         * dom/Document.cpp:
1828         (WebCore::Document::setURL):
1829         (WebCore::Document::completeURL const):
1830         (WebCore::Document::ensureTemplateDocument):
1831         * dom/Document.h:
1832         (WebCore::Document::urlForBindings const):
1833         * dom/InlineStyleSheetOwner.cpp:
1834         (WebCore::parserContextForElement):
1835         * dom/Node.cpp:
1836         (WebCore::Node::baseURI const):
1837         * editing/cocoa/WebContentReaderCocoa.mm:
1838         (WebCore::WebContentReader::readWebArchive):
1839         * editing/markup.cpp:
1840         (WebCore::createFragmentFromMarkup):
1841         * html/DOMURL.cpp:
1842         (WebCore::DOMURL::create):
1843         * html/HTMLFrameElementBase.cpp:
1844         (WebCore::HTMLFrameElementBase::openURL):
1845         (WebCore::HTMLFrameElementBase::location const):
1846         * html/parser/XSSAuditor.cpp:
1847         (WebCore::XSSAuditor::filterScriptToken):
1848         (WebCore::XSSAuditor::filterObjectToken):
1849         (WebCore::XSSAuditor::filterParamToken):
1850         (WebCore::XSSAuditor::filterEmbedToken):
1851         (WebCore::XSSAuditor::filterFormToken):
1852         (WebCore::XSSAuditor::filterInputToken):
1853         (WebCore::XSSAuditor::filterButtonToken):
1854         (WebCore::XSSAuditor::isLikelySafeResource):
1855         * loader/DocumentLoader.cpp:
1856         (WebCore::DocumentLoader::maybeLoadEmpty):
1857         * loader/DocumentLoader.h:
1858         (WebCore::DocumentLoader::serverRedirectSourceForHistory const):
1859         * loader/FrameLoader.cpp:
1860         (WebCore::FrameLoader::loadWithDocumentLoader):
1861         * loader/HistoryController.cpp:
1862         (WebCore::HistoryController::currentItemShouldBeReplaced const):
1863         (WebCore::HistoryController::initializeItem):
1864         * loader/SubframeLoader.cpp:
1865         (WebCore::SubframeLoader::requestFrame):
1866         * loader/archive/cf/LegacyWebArchive.cpp:
1867         (WebCore::LegacyWebArchive::createFromSelection):
1868         * page/Location.cpp:
1869         (WebCore::Location::url const):
1870         * page/SecurityPolicy.cpp:
1871         (WebCore::SecurityPolicy::shouldInheritSecurityOriginFromOwner):
1872         * platform/win/ClipboardUtilitiesWin.cpp:
1873         (WebCore::markupToCFHTML):
1874         * svg/SVGImageLoader.cpp:
1875         (WebCore::SVGImageLoader::sourceURI const):
1876
1877 2020-03-23  youenn fablet  <youenn@apple.com>
1878
1879         Remove DOMCache::m_records
1880         https://bugs.webkit.org/show_bug.cgi?id=209425
1881
1882         Reviewed by Alex Christensen.
1883
1884         We do not need to keep references of FetchRequest and FetchResponse since we clone them before exposing them.
1885         For that reason, remove m_records and directly use records given from the CacheStorageConnection.
1886         Minor refactoring to modernize/improve code readability.
1887
1888         This is a first step towards a future refactoring that will reduce the sending of records from network process to web process
1889         based on the request parameters: record filtering will be done in network process instead of web process.
1890
1891         No change of behavior.
1892
1893         * Modules/cache/DOMCache.cpp:
1894         (WebCore::createResponse):
1895         (WebCore::DOMCache::doMatch):
1896         (WebCore::DOMCache::cloneResponses):
1897         (WebCore::DOMCache::matchAll):
1898         (WebCore::createRequest):
1899         (WebCore::DOMCache::keys):
1900         (WebCore::DOMCache::retrieveRecords):
1901         (WebCore::DOMCache::queryCache):
1902         (WebCore::DOMCache::queryCacheWithTargetStorage):
1903         (WebCore::DOMCache::batchDeleteOperation):
1904         (WebCore::DOMCache::batchPutOperation):
1905         (WebCore::copyRequestRef): Deleted.
1906         (WebCore::queryCacheMatch): Deleted.
1907         (WebCore::DOMCache::updateRecords): Deleted.
1908         * Modules/cache/DOMCache.h:
1909
1910 2020-03-23  Rob Buis  <rbuis@igalia.com>
1911
1912         XMLHttpRequest: getAllResponseHeaders() sorting
1913         https://bugs.webkit.org/show_bug.cgi?id=200565
1914
1915         Reviewed by Darin Adler.
1916
1917         Sort headers using the ASCII-uppercase header name as key but use ASCII-lowercase header
1918         names in the string result.
1919
1920         Nehavior matches Firefox and Chrome.
1921
1922         Test: imported/web-platform-tests/xhr/getallresponseheaders.htm
1923
1924         [1] https://xhr.spec.whatwg.org/#dom-xmlhttprequest-getallresponseheaders
1925
1926         * xml/XMLHttpRequest.cpp:
1927         (WebCore::XMLHttpRequest::getAllResponseHeaders const):
1928
1929 2020-03-23  Truitt Savell  <tsavell@apple.com>
1930
1931         Unreviewed, reverting r258847.
1932
1933         Broke testing on Mac Debug with an Assert
1934
1935         Reverted changeset:
1936
1937         "[LFC] Layout::Box::initialContainingBlock() should return
1938         const InitialContainingBlock&"
1939         https://bugs.webkit.org/show_bug.cgi?id=209406
1940         https://trac.webkit.org/changeset/258847
1941
1942 2020-03-23  Kate Cheney  <katherine_cheney@apple.com>
1943
1944         Add checks for app-bound navigations when evaluating user style sheets
1945         https://bugs.webkit.org/show_bug.cgi?id=209368
1946         <rdar://problem/60204230>
1947
1948         Reviewed by Brent Fulgham.
1949
1950         * page/Page.cpp:
1951         (WebCore::Page::injectUserStyleSheet):
1952         If the style sheet is for a specific WebView, it will have a pageID
1953         and we can check for app-bound navigation in the page object.
1954
1955         * style/StyleScopeRuleSets.cpp:
1956         (WebCore::Style::ScopeRuleSets::initializeUserStyle):
1957         If the user style sheet is being applied to all WebViews, we can check for 
1958         for a page's existence and navigation state here before the style sheet is
1959         updated.
1960
1961 2020-03-23  Antoine Quint  <graouts@apple.com>
1962
1963         DocumentTimeline / CSSTransition objects are leaking on CNN.com
1964         https://bugs.webkit.org/show_bug.cgi?id=208069
1965         <rdar://problem/59680143>
1966
1967         Reviewed by Darin Adler.
1968
1969         Integrating post-commit review feedback from Darin. 
1970
1971         * testing/Internals.cpp:
1972         (WebCore::Internals::animationWithIdExists const):
1973
1974 2020-03-23  Chris Dumez  <cdumez@apple.com>
1975
1976         Port window.postMessage to the HTML event loop
1977         https://bugs.webkit.org/show_bug.cgi?id=209359
1978
1979         Reviewed by Alex Christensen.
1980
1981         Port window.postMessage to the HTML event loop instead of using a 0-timer.
1982
1983         * inspector/InspectorInstrumentation.cpp:
1984         (WebCore::InspectorInstrumentation::willPostMessageImpl):
1985         (WebCore::InspectorInstrumentation::didPostMessageImpl):
1986         (WebCore::InspectorInstrumentation::didFailPostMessageImpl):
1987         (WebCore::InspectorInstrumentation::willDispatchPostMessageImpl):
1988         (WebCore::InspectorInstrumentation::didDispatchPostMessageImpl):
1989         * inspector/InspectorInstrumentation.h:
1990         (WebCore::InspectorInstrumentation::willPostMessage):
1991         (WebCore::InspectorInstrumentation::didPostMessage):
1992         (WebCore::InspectorInstrumentation::didFailPostMessage):
1993         (WebCore::InspectorInstrumentation::willDispatchPostMessage):
1994         (WebCore::InspectorInstrumentation::didDispatchPostMessage):
1995         * inspector/agents/WebDebuggerAgent.cpp:
1996         (WebCore::WebDebuggerAgent::willPostMessage):
1997         (WebCore::WebDebuggerAgent::didPostMessage):
1998         (WebCore::WebDebuggerAgent::didFailPostMessage):
1999         (WebCore::WebDebuggerAgent::willDispatchPostMessage):
2000         (WebCore::WebDebuggerAgent::didDispatchPostMessage):
2001         (WebCore::WebDebuggerAgent::didClearAsyncStackTraceData):
2002         * inspector/agents/WebDebuggerAgent.h:
2003         * page/DOMWindow.cpp:
2004         (WebCore::DOMWindow::postMessage):
2005         (WebCore::PostMessageTimer::PostMessageTimer): Deleted.
2006         (WebCore::PostMessageTimer::event): Deleted.
2007         (WebCore::PostMessageTimer::targetOrigin const): Deleted.
2008         (WebCore::PostMessageTimer::stackTrace const): Deleted.
2009         (WebCore::DOMWindow::postMessageTimerFired): Deleted.
2010         * page/DOMWindow.h:
2011
2012 2020-03-23  Zalan Bujtas  <zalan@apple.com>
2013
2014         [LFC] Layout::Box::initialContainingBlock() should return const InitialContainingBlock&
2015         https://bugs.webkit.org/show_bug.cgi?id=209406
2016         <rdar://problem/60749715>
2017
2018         Reviewed by Antti Koivisto.
2019
2020         Use is<InitialContainingBlock> where applicable.
2021
2022         * layout/FormattingContext.cpp:
2023         (WebCore::Layout::FormattingContext::geometryForBox const):
2024         (WebCore::Layout::FormattingContext::collectOutOfFlowDescendantsIfNeeded):
2025         * layout/FormattingContextQuirks.cpp:
2026         (WebCore::Layout::FormattingContext::Quirks::heightValueOfNearestContainingBlockWithFixedHeight):
2027         * layout/blockformatting/BlockFormattingContextQuirks.cpp:
2028         * layout/displaytree/DisplayPainter.cpp:
2029         (WebCore::Display::absoluteDisplayBox):
2030         * layout/invalidation/InvalidationState.cpp:
2031         (WebCore::Layout::InvalidationState::markNeedsUpdate):
2032         * layout/layouttree/LayoutBox.cpp:
2033         (WebCore::Layout::Box::establishesBlockFormattingContext const):
2034         (WebCore::Layout::Box::containingBlock const):
2035         (WebCore::Layout::Box::formattingContextRoot const):
2036         (WebCore::Layout::Box::initialContainingBlock const):
2037         (WebCore::Layout::Box::isInFormattingContextOf const):
2038         (WebCore::Layout::Box::isOverflowVisible const):
2039         * layout/layouttree/LayoutBox.h:
2040         (WebCore::Layout::Box::isInitialContainingBlock const):
2041         (WebCore::Layout::Box::isInlineTextBox const):
2042         (WebCore::Layout::Box::isLineBreakBox const):
2043         (WebCore::Layout::Box::isReplacedBox const):
2044         * layout/layouttree/LayoutInitialContainingBlock.cpp:
2045         (WebCore::Layout::InitialContainingBlock::InitialContainingBlock):
2046         * layout/layouttree/LayoutInlineTextBox.cpp:
2047         (WebCore::Layout::InlineTextBox::InlineTextBox):
2048         * layout/layouttree/LayoutLineBreakBox.cpp:
2049         (WebCore::Layout::LineBreakBox::LineBreakBox):
2050         * layout/layouttree/LayoutReplacedBox.cpp:
2051         (WebCore::Layout::ReplacedBox::ReplacedBox):
2052         * layout/layouttree/LayoutTreeBuilder.cpp:
2053         (WebCore::Layout::outputLayoutBox):
2054
2055 2020-03-23  Jer Noble  <jer.noble@apple.com>
2056
2057         [MSE] Handle the case where AVStreamDataParser packages sync and non-sync samples together in a CMSampleBufferRef.
2058         https://bugs.webkit.org/show_bug.cgi?id=209365
2059         <rdar://problem/60625209>
2060
2061         Reviewed by Eric Carlson.
2062
2063         AVStreamDataParser will package together muliple samples into a single CMSampleBufferRef for efficiency's sake. When
2064         this occurs, it may include sync and non-sync samples together into the same CMSampleBufferRef, which is problematic
2065         as we consider a CMSampleBufferRef to be "sync" only when every sample inside the buffer is also sync.
2066
2067         To handle this scenario, when receiving a CMSampleBufferRef from AVStreamDataParser, first check whether that buffer
2068         is "homogeneous", meaning every sample within the buffer has the same effective MediaSample flags. Then, if the buffer
2069         is not homogenous, break the buffer into muliple homogenious CMSampleBufferRefs. Then, each of those resulting buffers
2070         is passed up to SourceBuffer as a MediaSample individually.
2071
2072         * platform/graphics/avfoundation/objc/MediaSampleAVFObjC.h:
2073         * platform/graphics/avfoundation/objc/MediaSampleAVFObjC.mm:
2074         (WebCore::isCMSampleBufferAttachmentRandomAccess):
2075         (WebCore::isCMSampleBufferRandomAccess):
2076         (WebCore::isCMSampleBufferAttachmentNonDisplaying):
2077         (WebCore::isCMSampleBufferNonDisplaying):
2078         (WebCore::MediaSampleAVFObjC::flags const):
2079         (WebCore::MediaSampleAVFObjC::isHomogeneous const):
2080         (WebCore::MediaSampleAVFObjC::divideIntoHomogeneousSamples):
2081         * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
2082         (WebCore::SourceBufferPrivateAVFObjC::processCodedFrame):
2083
2084 2020-03-23  Alicia Boya García  <aboya@igalia.com>
2085
2086         [MSE][GStreamer] Clean and explain first sample PTS hack
2087         https://bugs.webkit.org/show_bug.cgi?id=209335
2088
2089         Reviewed by Philippe Normand.
2090
2091         MediaSample::applyPtsOffset() had a rather confusing name, so it has
2092         been changed to something more descriptive of its actual function:
2093         extendToTheBeginning().
2094
2095         Also, its only argument has been removed, as it's always zero.
2096
2097         An explanation of the hack has also been added.
2098
2099         This patch introduces no behavior changes.
2100
2101         * platform/graphics/gstreamer/MediaSampleGStreamer.cpp:
2102         (WebCore::MediaSampleGStreamer::extendToTheBeginning):
2103         (WebCore::MediaSampleGStreamer::applyPtsOffset): Deleted.
2104         * platform/graphics/gstreamer/MediaSampleGStreamer.h:
2105         * platform/graphics/gstreamer/mse/AppendPipeline.cpp:
2106         (WebCore::AppendPipeline::appsinkNewSample):
2107
2108 2020-03-23  Zalan Bujtas  <zalan@apple.com>
2109
2110         [LFC] Remove unused LayoutAncestorIterator class
2111         https://bugs.webkit.org/show_bug.cgi?id=209401
2112         <rdar://problem/60743144>
2113
2114         Reviewed by Sam Weinig.
2115
2116         * WebCore.xcodeproj/project.pbxproj:
2117         * layout/blockformatting/BlockFormattingContextGeometry.cpp:
2118         * layout/displaytree/DisplayPainter.cpp:
2119         * layout/layouttree/LayoutAncestorIterator.h: Removed.
2120         * layout/layouttree/LayoutChildIterator.h:
2121         (WebCore::Layout::LayoutChildIteratorAdapter<T>::last const): Deleted.
2122         * layout/layouttree/LayoutIterator.h:
2123         (WebCore::Layout::LayoutBoxTraversal::nextSkippingChildren): Deleted.
2124         (WebCore::Layout::Traversal::lastChild): Deleted.
2125         (WebCore::Layout::Traversal::previousSibling): Deleted.
2126         (WebCore::Layout::Traversal::findAncestorOfType): Deleted.
2127         (WebCore::Layout::LayoutIterator<T>::traversePreviousSibling): Deleted.
2128         (WebCore::Layout::LayoutIterator<T>::traverseAncestor): Deleted.
2129         * layout/layouttree/LayoutTreeBuilder.cpp:
2130
2131 2020-03-23  Antoine Quint  <graouts@apple.com>
2132
2133         [Web Animations] Refactor cancelDeclarativeAnimationsForElement and willDestroyRendererForElement on AnimationTimeline
2134         https://bugs.webkit.org/show_bug.cgi?id=209423
2135
2136         Reviewed by Antti Koivisto.
2137
2138         The methods cancelDeclarativeAnimationsForElement and willDestroyRendererForElement on AnimationTimeline did the same
2139         thing save for the argument passed to WebAnimation::cancel(). We now refactor those two methods into a single
2140         cancelDeclarativeAnimationsForElement method with an argument to set whether cancelation should be silent.
2141         As a result, we also change WebAnimation::cancel() to have a single flavor instead of one without an argument and one
2142         with the silent argument.
2143
2144         No test because there is no change in visible behavior.
2145
2146         * animation/AnimationTimeline.cpp:
2147         (WebCore::AnimationTimeline::elementWasRemoved):
2148         (WebCore::AnimationTimeline::cancelDeclarativeAnimationsForElement):
2149         (WebCore::AnimationTimeline::willDestroyRendererForElement): Deleted.
2150         * animation/AnimationTimeline.h:
2151         * animation/DeclarativeAnimation.cpp:
2152         (WebCore::DeclarativeAnimation::cancel):
2153         * animation/DeclarativeAnimation.h:
2154         * animation/WebAnimation.cpp:
2155         * animation/WebAnimation.h:
2156         * rendering/updating/RenderTreeUpdater.cpp:
2157         (WebCore::RenderTreeUpdater::tearDownRenderers):
2158
2159 2020-03-23  Youenn Fablet  <youenn@apple.com>
2160
2161         AudioTrackPrivateMediaStream recovers from a muted track very late
2162         https://bugs.webkit.org/show_bug.cgi?id=209411
2163
2164         Reviewed by Eric Carlson.
2165
2166         In case of a muted track, the AudioSampleDataSource is not pushed any new sample.
2167         When unmuting the tracks, pulled samples will be zeroes for some time until the newly pushed samples are used.
2168         To fix this, we pause the audio player whenever muted/disabled/ended and restart playing when unmuted/enabled.
2169         Manually tested.
2170
2171         * platform/mediastream/AudioTrackPrivateMediaStream.cpp:
2172         (WebCore::AudioTrackPrivateMediaStream::updateRendererMutedState):
2173
2174 2020-03-23  Youenn Fablet  <youenn@apple.com>
2175
2176         AudioMediaStreamTrackRendererCocoa does not recover from AudioSession interruption
2177         https://bugs.webkit.org/show_bug.cgi?id=209412
2178
2179         Reviewed by Eric Carlson.
2180
2181         In case there is an AudioSession interruption, like the app is in the background
2182         and another app starts to play audio, AudioMediaStreamTrackRendererCocoa will not restart playing audio.
2183         Fix this by clearing the AudioUnit when starting since the renderer is paused during the interruption.
2184         This ensures resuming from the interruption in a clean state.
2185
2186         Manually tested.
2187
2188         * platform/mediastream/mac/AudioMediaStreamTrackRendererCocoa.cpp:
2189         (WebCore::AudioMediaStreamTrackRendererCocoa::start):
2190
2191 2020-03-23  youenn fablet  <youenn@apple.com>
2192
2193         MediaDevices::refreshDevices should take device type into account
2194         https://bugs.webkit.org/show_bug.cgi?id=209417
2195         <rdar://problem/60521332>
2196
2197         Reviewed by Eric Carlson.
2198
2199         Now that we set deviceId to the empty string when media capture is not granted,
2200         we can have two devices with the same ID. We also need to handle the device type.
2201
2202         * Modules/mediastream/MediaDevices.cpp:
2203         (WebCore::MediaDevices::refreshDevices):
2204
2205 2020-03-23  Zalan Bujtas  <zalan@apple.com>
2206
2207         [LFC] Box::establishesBlockFormattingContext should check isInitialContainingBlock
2208         https://bugs.webkit.org/show_bug.cgi?id=209390
2209         <rdar://problem/60735021>
2210
2211         Reviewed by Antti Koivisto.
2212
2213         It's more correct to call isInitialContainingBlock() to check if the current box is the ICB.
2214
2215         * layout/layouttree/LayoutBox.cpp:
2216         (WebCore::Layout::Box::establishesBlockFormattingContext const):
2217         (WebCore::Layout::Box::initialContainingBlock const):
2218
2219 2020-03-23  Antoine Quint  <graouts@apple.com>
2220
2221         [Web Animations] ElementAnimationRareData is created too frequently
2222         https://bugs.webkit.org/show_bug.cgi?id=209415
2223
2224         Reviewed by Antti Koivisto.
2225
2226         The various accessors on Element to access transitions and animations will ensure there is a backing
2227         ElementAnimationRareData object. However, in a lot of cases, such as when we consider whether CSS
2228         Transitions should be created, updated or removed under AnimationTimeline::updateCSSTransitionsForElement(),
2229         we end up not needing to actually access the data structures on ElementAnimationRareData.
2230
2231         We now make the various methods on Element to access transitions and animations `const T*` and add ensure*()
2232         methods to access the collections for modification. We also add methods to query whether there are running or
2233         completed transitions at all or for a given property.
2234
2235         No test because there is no change in visible behavior.
2236
2237         * animation/AnimationTimeline.cpp:
2238         (WebCore::AnimationTimeline::animationWasAddedToElement):
2239         (WebCore::AnimationTimeline::animationWasRemovedFromElement):
2240         (WebCore::AnimationTimeline::removeDeclarativeAnimationFromListsForOwningElement):
2241         (WebCore::AnimationTimeline::animationsForElement const):
2242         (WebCore::AnimationTimeline::willDestroyRendererForElement):
2243         (WebCore::AnimationTimeline::cancelDeclarativeAnimationsForElement):
2244         (WebCore::AnimationTimeline::updateCSSTransitionsForElementAndProperty):
2245         (WebCore::AnimationTimeline::updateCSSTransitionsForElement):
2246         * animation/AnimationTimeline.h:
2247         * animation/DocumentTimeline.cpp:
2248         (WebCore::DocumentTimeline::transitionDidComplete):
2249         * dom/Element.cpp:
2250         (WebCore::Element::webAnimations const):
2251         (WebCore::Element::cssAnimations const):
2252         (WebCore::Element::transitions const):
2253         (WebCore::Element::hasCompletedTransitionsForProperty const):
2254         (WebCore::Element::hasRunningTransitionsForProperty const):
2255         (WebCore::Element::hasRunningTransitions const):
2256         (WebCore::Element::ensureWebAnimations):
2257         (WebCore::Element::ensureCSSAnimations):
2258         (WebCore::Element::ensureTransitions):
2259         (WebCore::Element::ensureCompletedTransitionsByProperty):
2260         (WebCore::Element::ensureRunningTransitionsByProperty):
2261         (WebCore::Element::webAnimations): Deleted.
2262         (WebCore::Element::cssAnimations): Deleted.
2263         (WebCore::Element::transitions): Deleted.
2264         (WebCore::Element::completedTransitionsByProperty): Deleted.
2265         (WebCore::Element::runningTransitionsByProperty): Deleted.
2266         * dom/Element.h:
2267
2268 2020-03-23  Charlie Turner  <cturner@igalia.com>
2269
2270         [GStreamer] Fail gracefully in the absence of a WebVTT encoder.
2271         https://bugs.webkit.org/show_bug.cgi?id=209290
2272
2273         Reviewed by Philippe Normand.
2274
2275         Covered by existing tests.
2276
2277         * platform/graphics/gstreamer/GStreamerCommon.cpp:
2278         (WebCore::initializeGStreamer): Gets rid of "plugin not found"
2279         errors. It's not an error to have potentially broken AAC decoders,
2280         but it's nice to give a clear warning.
2281         * platform/graphics/gstreamer/TextCombinerGStreamer.cpp:
2282         (webkit_text_combiner_class_init):
2283         (webkitTextCombinerNew): Check for the "subenc" *plugin*. This
2284         check indirectly tells us the "webvttenc" *element* will exist.
2285
2286 2020-03-23  Carlos Garcia Campos  <cgarcia@igalia.com>
2287
2288         [WPE] AsyncScrolling: horizontal scrolling is inverted
2289         https://bugs.webkit.org/show_bug.cgi?id=208638
2290
2291         Reviewed by Adrian Perez de Castro.
2292
2293         Scrolling down should scroll to the right and up to the left..
2294
2295         * page/scrolling/nicosia/ScrollingTreeFrameScrollingNodeNicosia.cpp:
2296         (WebCore::ScrollingTreeFrameScrollingNodeNicosia::handleWheelEvent): Invert also the x axis.
2297         * page/scrolling/nicosia/ScrollingTreeOverflowScrollingNodeNicosia.cpp:
2298         (WebCore::ScrollingTreeOverflowScrollingNodeNicosia::handleWheelEvent): Ditto.
2299
2300 2020-03-23  Antoine Quint  <graouts@apple.com>
2301
2302         [Web Animations] Fix the typo for ElementAnimationRareData::completedTransitionByProperty()
2303         https://bugs.webkit.org/show_bug.cgi?id=209413
2304
2305         Reviewed by Antti Koivisto.
2306
2307         There can be several completed transitions by property, so renaming this property to completedTransitionsByProperty.
2308
2309         * animation/AnimationTimeline.cpp:
2310         (WebCore::AnimationTimeline::removeDeclarativeAnimationFromListsForOwningElement):
2311         (WebCore::AnimationTimeline::updateCSSTransitionsForElement):
2312         * animation/DocumentTimeline.cpp:
2313         (WebCore::DocumentTimeline::transitionDidComplete):
2314         * animation/ElementAnimationRareData.h:
2315         (WebCore::ElementAnimationRareData::completedTransitionsByProperty):
2316         (WebCore::ElementAnimationRareData::completedTransitionByProperty): Deleted.
2317         * dom/Element.cpp:
2318         (WebCore::Element::completedTransitionsByProperty):
2319         (WebCore::Element::completedTransitionByProperty): Deleted.
2320         * dom/Element.h:
2321
2322 2020-03-22  Antoine Quint  <graouts@apple.com>
2323
2324         DocumentTimeline / CSSTransition objects are leaking on CNN.com
2325         https://bugs.webkit.org/show_bug.cgi?id=208069
2326         <rdar://problem/59680143>
2327
2328         Reviewed by Simon Fraser, Geoffrey Garen and Darin Adler.
2329
2330         Test: webanimations/leak-css-animation.html
2331
2332         We add a test feature that lets use query the availability of a given WebAnimation by its "id" property in the WebAnimation::instances list.
2333         We also fix some build issues that appeared with a change in UnifiedSources order.
2334
2335         * animation/ElementAnimationRareData.cpp:
2336         (WebCore::ElementAnimationRareData::setAnimationsCreatedByMarkup):
2337         * animation/ElementAnimationRareData.h:
2338         (WebCore::ElementAnimationRareData::setAnimationsCreatedByMarkup): Deleted.
2339         * animation/WebAnimation.h:
2340         * testing/Internals.cpp:
2341         (WebCore::Internals::animationWithIdExists const):
2342         * testing/Internals.h:
2343         * testing/Internals.idl:
2344
2345 2020-03-22  Antoine Quint  <graouts@apple.com>
2346
2347         [ Mac ] imported/w3c/web-platform-tests/web-animations/timing-model/timelines/update-and-send-events-replacement.html is flaky failing.
2348         https://bugs.webkit.org/show_bug.cgi?id=209239
2349         <rdar://problem/60591358>
2350
2351         Reviewed by Simon Fraser.
2352
2353         This test was made flaky by r257417, the initial fix for webkit.org/b/208069. A new, appropriate fix for that bug is in the works. In the
2354         meantime we revert r257417 in this patch.
2355
2356         The reason this test became flaky is that it features the following code:
2357
2358             animB.timeline = new DocumentTimeline({
2359               originTime:
2360                 document.timeline.currentTime - 100 * MS_PER_SEC - animB.startTime,
2361             });
2362
2363         In this case the only reference to the created DocumentTimeline is through `animB.timeline`. But because r257417 made the timeline reference from
2364         WebAnimation a weak reference, in some cases, if GC kicks in, the timeline would be dereferenced and the test would fail. We restore that relationship
2365         to its previous state, which is a strong reference.
2366
2367         * animation/WebAnimation.cpp:
2368         (WebCore::WebAnimation::setTimeline):
2369         (WebCore::WebAnimation::setTimelineInternal):
2370         (WebCore::WebAnimation::enqueueAnimationEvent):
2371         (WebCore::WebAnimation::acceleratedStateDidChange):
2372         (WebCore::WebAnimation::timeline const): Deleted.
2373         * animation/WebAnimation.h:
2374         (WebCore::WebAnimation::timeline const):
2375
2376 2020-03-22  Zalan Bujtas  <zalan@apple.com>
2377
2378         [LFC] Introduce InitialContainingBox class
2379         https://bugs.webkit.org/show_bug.cgi?id=209399
2380         <rdar://problem/60741767>
2381
2382         Reviewed by Antti Koivisto.
2383
2384         ICB is the top level containing block. This helps to make sure we don't accidentally call parent() on the ICB.
2385         This is also a preparation for "const Box& Layout::Box::parent()".
2386
2387         * Sources.txt:
2388         * WebCore.xcodeproj/project.pbxproj:
2389         * layout/integration/LayoutIntegrationBoxTree.cpp:
2390         (WebCore::LayoutIntegration::BoxTree::BoxTree):
2391         (): Deleted.
2392         * layout/integration/LayoutIntegrationBoxTree.h:
2393         (WebCore::LayoutIntegration::BoxTree::rootLayoutBox const):
2394         (WebCore::LayoutIntegration::BoxTree::rootLayoutBox):
2395         * layout/layouttree/LayoutBox.cpp:
2396         (WebCore::Layout::Box::isInitialContainingBlock const): Deleted.
2397         * layout/layouttree/LayoutBox.h:
2398         (WebCore::Layout::Box::isInitialContainingBlock const):
2399         * layout/layouttree/LayoutContainerBox.h:
2400         * layout/layouttree/LayoutTreeBuilder.cpp:
2401         (WebCore::Layout::TreeBuilder::buildLayoutTree):
2402
2403 2020-03-22  Zalan Bujtas  <zalan@apple.com>
2404
2405         [LFC] Layout::Box::containingBlock should return a const ContainerBox&
2406         https://bugs.webkit.org/show_bug.cgi?id=209381
2407         <rdar://problem/60732278>
2408
2409         Reviewed by Antti Koivisto.
2410
2411         Layout tree is immutable during layout, so every box should be able to return a valid containing block (except the ICB).
2412         (This patch also removes the unused isDescendantOf() function and renames isDescendantOfFormattingRoot to isInFormattingContextOf).
2413
2414         * layout/FormattingContext.cpp:
2415         (WebCore::Layout::FormattingContext::layoutOutOfFlowContent):
2416         (WebCore::Layout::FormattingContext::validateGeometryConstraintsAfterLayout const):
2417         * layout/FormattingContextGeometry.cpp:
2418         (WebCore::Layout::isHeightAuto):
2419         (WebCore::Layout::FormattingContext::Geometry::computedHeightValue const):
2420         (WebCore::Layout::FormattingContext::Geometry::staticVerticalPositionForOutOfFlowPositioned const):
2421         (WebCore::Layout::FormattingContext::Geometry::staticHorizontalPositionForOutOfFlowPositioned const):
2422         (WebCore::Layout::FormattingContext::Geometry::outOfFlowNonReplacedHorizontalGeometry):
2423         (WebCore::Layout::FormattingContext::Geometry::outOfFlowReplacedHorizontalGeometry const):
2424         (WebCore::Layout::FormattingContext::Geometry::inFlowPositionedPositionOffset const):
2425         * layout/FormattingContextQuirks.cpp:
2426         (WebCore::Layout::FormattingContext::Quirks::heightValueOfNearestContainingBlockWithFixedHeight):
2427         * layout/Verification.cpp:
2428         (WebCore::Layout::outputMismatchingBlockBoxInformationIfNeeded):
2429         * layout/blockformatting/BlockFormattingContext.cpp:
2430         (WebCore::Layout::BlockFormattingContext::layoutInFlowContent):
2431         (WebCore::Layout::BlockFormattingContext::usedAvailableWidthForFloatAvoider):
2432         (WebCore::Layout::BlockFormattingContext::precomputeVerticalPositionForAncestors):
2433         (WebCore::Layout::BlockFormattingContext::precomputeVerticalPositionForBoxAndAncestors):
2434         (WebCore::Layout::BlockFormattingContext::verticalPositionWithMargin const):
2435         * layout/blockformatting/BlockFormattingContextGeometry.cpp:
2436         (WebCore::Layout::BlockFormattingContext::Geometry::inFlowNonReplacedWidthAndMargin const):
2437         * layout/blockformatting/BlockFormattingContextQuirks.cpp:
2438         (WebCore::Layout::BlockFormattingContext::Quirks::stretchedInFlowHeight):
2439         (WebCore::Layout::initialContainingBlock): Deleted.
2440         * layout/blockformatting/BlockMarginCollapse.cpp:
2441         (WebCore::Layout::BlockFormattingContext::MarginCollapse::marginsCollapseThrough const):
2442         * layout/blockformatting/PrecomputedBlockMarginCollapse.cpp:
2443         (WebCore::Layout::BlockFormattingContext::MarginCollapse::precomputedPositiveNegativeValues const):
2444         * layout/displaytree/DisplayPainter.cpp:
2445         (WebCore::Display::absoluteDisplayBox):
2446         * layout/floats/FloatingContext.cpp:
2447         (WebCore::Layout::FloatingContext::verticalPositionWithClearance const):
2448         (WebCore::Layout::FloatingContext::absoluteDisplayBoxCoordinates const):
2449         (WebCore::Layout::FloatingContext::mapToFloatingStateRoot const):
2450         (WebCore::Layout::FloatingContext::mapTopToFloatingStateRoot const):
2451         (WebCore::Layout::FloatingContext::mapPointFromFormattingContextRootToFloatingStateRoot const):
2452         * layout/floats/FloatingState.cpp:
2453         (WebCore::Layout::FloatingState::bottom const):
2454         (WebCore::Layout::FloatingState::top const):
2455         * layout/floats/FloatingState.h:
2456         (WebCore::Layout::FloatingState::FloatItem::isInFormattingContextOf const):
2457         (WebCore::Layout::FloatingState::FloatItem::isDescendantOfFormattingRoot const): Deleted.
2458         * layout/layouttree/LayoutBox.cpp:
2459         (WebCore::Layout::Box::containingBlock const):
2460         (WebCore::Layout::Box::formattingContextRoot const):
2461         (WebCore::Layout::Box::isInFormattingContextOf const):
2462         (WebCore::Layout::Box::isDescendantOf const): Deleted.
2463         (WebCore::Layout::Box::isContainingBlockDescendantOf const): Deleted.
2464         * layout/layouttree/LayoutBox.h:
2465
2466 2020-03-21  Said Abou-Hallawa  <sabouhallawa@apple.com>
2467
2468         An animated PNG plays the frames one time more than the image loopCount
2469         https://bugs.webkit.org/show_bug.cgi?id=205640
2470
2471         Reviewed by Darin Adler.
2472
2473         Make the repetitionCount calculation for GIFs different from it for other
2474         image formats.
2475
2476         Tests: fast/images/animated-gif-loop-count.html
2477                fast/images/animated-png-loop-count.html
2478
2479         * platform/graphics/cg/ImageDecoderCG.cpp:
2480         (WebCore::ImageDecoderCG::repetitionCount const):
2481         * platform/graphics/cg/UTIRegistry.cpp:
2482         (WebCore::isGIFImageType):
2483         * platform/graphics/cg/UTIRegistry.h:
2484
2485 2020-03-21  Jack Lee  <shihchieh_lee@apple.com>
2486
2487         Nullptr crash in RenderObject::RenderObjectBitfields::isBox when current renderer is the RenderView
2488         https://bugs.webkit.org/show_bug.cgi?id=209251
2489         <rdar://problem/60103614>
2490
2491         Reviewed by Darin Adler.
2492
2493         In this case, which is a valid scenario, we are looking for sibling of an AccessibilityRenderObject through the parent of its renderer, which happens to be of <RenderView>. Since <RenderView> has no parent, we need to skip calling isInlineWithContinuation with a null parent, by adding null check.
2494
2495         Test: fast/frames/iframe-empty-doc-crash.html
2496
2497         * accessibility/AccessibilityRenderObject.cpp:
2498         (WebCore::AccessibilityRenderObject::nextSibling const):
2499
2500 2020-03-21  Philippe Normand  <pnormand@igalia.com>
2501
2502         Make the MediaSample::toJSONString method generic
2503         https://bugs.webkit.org/show_bug.cgi?id=209287
2504
2505         Reviewed by Eric Carlson.
2506
2507         It is generic and thus can be shared to sub-classes.
2508
2509         * platform/MediaSample.h:
2510         (WebCore::MediaSample::toJSONString const):
2511         * platform/graphics/avfoundation/objc/MediaSampleAVFObjC.h:
2512         * platform/graphics/avfoundation/objc/MediaSampleAVFObjC.mm:
2513
2514 2020-03-21  Zalan Bujtas  <zalan@apple.com>
2515
2516         telerik.com: Placeholder text is misaligned in search text box
2517         https://bugs.webkit.org/show_bug.cgi?id=209371
2518         <rdar://problem/45945564>
2519
2520         Reviewed by Antti Koivisto.
2521
2522         Let the placeholder box do its own vertical positioning/sizing.
2523         The placeholder box's height is currently set to the height of the editable renderer (sibling box), so when the ::placeholder has
2524         a large font-size set, the text is oddly positioned and gets cut off (the placeholder box has 'overflow: hidden' UA style).
2525         This patch makes the placeholder box center aligned and sized based on the used size (matches both Chrome and FF).
2526
2527         Test: fast/forms/placeholder-content-center.html
2528
2529         * rendering/RenderTextControlSingleLine.cpp:
2530         (WebCore::RenderTextControlSingleLine::layout):
2531
2532 2020-03-20  Simon Fraser  <simon.fraser@apple.com>
2533
2534         REGRESSION (r258679): [ Mac ] fast/scrolling/arrow-key-scroll-in-rtl-document.html is failing and timing out
2535         https://bugs.webkit.org/show_bug.cgi?id=209299
2536
2537         Reviewed by Daniel Bates.
2538
2539         fast/scrolling/arrow-key-scroll-in-rtl-document.html is unusual in that it uses monitorWheelEvents()
2540         but then issues arrow key presses.
2541
2542         WebCore responds to arrow keys via WebEditorClient::handleKeyboardEvent() calling down into
2543         WebPage::scroll() which ends up in FrameView::requestScrollPositionUpdate() and bounces to the
2544         scrolling thread. This isn't tracked by existing 'defer' reasons on WheelEventTestMonitor, so add a
2545         new defer reason that covers the period for adding the requested scroll go the scrolling state tree,
2546         and responding to it in the scrolling thread.
2547
2548         * page/WheelEventTestMonitor.cpp:
2549         (WebCore::operator<<):
2550         * page/WheelEventTestMonitor.h:
2551         * page/scrolling/AsyncScrollingCoordinator.cpp:
2552         (WebCore::AsyncScrollingCoordinator::requestScrollPositionUpdate):
2553         * page/scrolling/ThreadedScrollingTree.cpp:
2554         (WebCore::ThreadedScrollingTree::scrollingTreeNodeRequestsScroll):
2555         * page/scrolling/ThreadedScrollingTree.h:
2556
2557 2020-03-20  David Kilzer  <ddkilzer@apple.com>
2558
2559         Content-Type & Nosniff Ignored on XML External Entity Resources
2560         <https://webkit.org/b/191171>
2561         <rdar://problem/45763222>
2562
2563         Reviewed by Darin Adler.
2564
2565         Test: http/tests/security/contentTypeOptions/nosniff-xml-external-entity.xhtml
2566
2567         * platform/MIMETypeRegistry.cpp:
2568         (WebCore::MIMETypeRegistry::isXMLEntityMIMEType): Add.
2569         * platform/MIMETypeRegistry.h:
2570         (WebCore::MIMETypeRegistry::isXMLEntityMIMEType): Add.
2571         - Checks for XML external entity MIME types.
2572
2573         * xml/parser/XMLDocumentParserLibxml2.cpp:
2574         (WebCore::externalEntityMimeTypeAllowedByNosniff): Add.
2575         - Checks whether the MIME type is valid based on the presence of
2576           the "X-Content-Type-Options: nosniff" header.
2577         (WebCore::openFunc):
2578         - Drop the contents of the resource that was returned and print
2579           an error message to the Web Inspector console if
2580           externalEntityMimeTypeAllowedByNosniff() says the MIME type is
2581           not allowed.
2582
2583 2020-03-20  Alex Christensen  <achristensen@webkit.org>
2584
2585         CORS-disabling SPI introduced in r253978 should make responses non-opaque
2586         https://bugs.webkit.org/show_bug.cgi?id=209351
2587         <rdar://problem/60024850>
2588
2589         Reviewed by Chris Dumez.
2590
2591         Covered by making the API test actually check that response content is readable.
2592
2593         * loader/DocumentThreadableLoader.cpp:
2594         (WebCore::DocumentThreadableLoader::responseReceived):
2595
2596 2020-03-20  Jer Noble  <jer.noble@apple.com>
2597
2598         Ensure media cache directory is created before passing to AVURLAsset.
2599         https://bugs.webkit.org/show_bug.cgi?id=209341
2600
2601         Reviewed by Eric Carlson.
2602
2603         Sandbox changes require the media cache directory to be created before passing to
2604         AVFoundation, to ensure that a sandbox extension is allowed to be created for that
2605         directory.
2606
2607         When the mediaCacheDirectory is empty or null, no longer specify a temporary directory. This
2608         allows clients to disable caching by specifying an empty string for the cache directory.
2609         Since now assetCacheForPath() can return nil, update all the call sites to handle that
2610         possibility. Add a new method, ensureAssetCacheExistsAtPath() which tries to create a
2611         directory at the specified path, and returns nil if that is not possible. This ensures the
2612         cache path exists before adding the AVAssetCache to the AVURLAsset options dictionary.
2613
2614         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
2615         (WebCore::assetCacheForPath):
2616         (WebCore::ensureAssetCacheExistsForPath):
2617         (WebCore::MediaPlayerPrivateAVFoundationObjC::originsInMediaCache):
2618         (WebCore::MediaPlayerPrivateAVFoundationObjC::clearMediaCache):
2619         (WebCore::MediaPlayerPrivateAVFoundationObjC::clearMediaCacheForOrigins):
2620         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL):
2621
2622 2020-03-20  David Kilzer  <ddkilzer@apple.com>
2623
2624         Fix name of "X-Content-Type:" HTTP header in console logging
2625         <https://webkit.org/b/209348>
2626
2627         Reviewed by Devin Rousso.
2628
2629         * css/StyleSheetContents.cpp:
2630         (WebCore::StyleSheetContents::parseAuthorStyleSheet):
2631         * dom/LoadableClassicScript.cpp:
2632         (WebCore::LoadableClassicScript::notifyFinished):
2633         * workers/WorkerScriptLoader.cpp:
2634         (WebCore::WorkerScriptLoader::validateWorkerResponse):
2635         - Change "X-Content-Type:" to "X-Content-Type-Options:" to fix
2636           the name of the header.
2637
2638 2020-03-20  Ali Juma  <ajuma@chromium.org>
2639
2640         Intersection Observer intersections are wrong with zooming
2641         https://bugs.webkit.org/show_bug.cgi?id=209264
2642
2643         Reviewed by Simon Fraser.
2644
2645         An IntersectionObserver's rootMargin is expressed in CSS pixels,
2646         but we weren't accounting for page zoom. Fix this by multiplying
2647         the root margin by the zoom factor.
2648
2649         Test: intersection-observer/root-margin-with-zoom.html
2650
2651         * dom/Document.cpp:
2652         (WebCore::expandRootBoundsWithRootMargin):
2653         (WebCore::computeIntersectionState):
2654
2655 2020-03-20  Don Olmstead  <don.olmstead@sony.com>
2656
2657         [GPUP] Add PlatformLayerContainer to hold pointer to PlatformLayer
2658         https://bugs.webkit.org/show_bug.cgi?id=208963
2659
2660         Reviewed by Eric Carlson.
2661
2662         Add a PlatformLayerContainer definition for use within the GPU Process code.
2663         Migrate to using over typedef in the file.
2664
2665         * platform/graphics/PlatformLayer.h:
2666
2667 2020-03-20  Andres Gonzalez  <andresg_22@apple.com>
2668
2669         Isolated tree updates must happen after AXObject has finished handling notifications.
2670         https://bugs.webkit.org/show_bug.cgi?id=209354
2671
2672         Reviewed by Chris Fleizach.
2673
2674         Isolated tree updates were happening in AXObjectCache::postNotification,
2675         but that is too early because the AXObject tree is updated during
2676         notificationPostTimerFired. Thus, moved the updates to after all
2677         AXObject tree updates have been done.
2678         In addition, fixed the check for replacement of the IsolatedObject in
2679         AXIsolatedTree::applyPendingChanges, which now happens only if the old
2680         and new objects have the same platform wrapper.
2681
2682         * accessibility/AXObjectCache.cpp:
2683         (WebCore::AXObjectCache::notificationPostTimerFired):
2684         (WebCore::AXObjectCache::postNotification):
2685         * accessibility/isolatedtree/AXIsolatedTree.cpp:
2686         (WebCore::AXIsolatedTree::applyPendingChanges):
2687
2688 2020-03-20  Andres Gonzalez  <andresg_22@apple.com>
2689
2690         Fix for retrieving focus in isolated tree mode.
2691         https://bugs.webkit.org/show_bug.cgi?id=209336
2692
2693         Reviewed by Chris Fleizach.
2694
2695         Focused object requests can come on the secondary thread before the
2696         isolated tree has been generated. Thus, AXObjectCache::isolatedTreeFocusedObject
2697         needs to generate the isolated tree if it doesn't exist, similar to
2698         isolatedTreeRootObject.
2699
2700         * accessibility/AXObjectCache.cpp:
2701         (WebCore::AXObjectCache::isolatedTreeFocusedObject):
2702         (WebCore::AXObjectCache::focusedUIElementForPage):
2703         (WebCore::AXObjectCache::getOrCreateIsolatedTree const):
2704         (WebCore::AXObjectCache::isolatedTreeRootObject):
2705         * accessibility/AXObjectCache.h:
2706         * accessibility/isolatedtree/AXIsolatedObject.cpp:
2707         (WebCore::AXIsolatedObject::focusedUIElement const):
2708         * accessibility/isolatedtree/AXIsolatedTree.h:
2709         m_pendingFocusedNodeID wasn't being initialized, which was causing
2710         random crashes when accessing the HashMap of isolated objects for a
2711         spurious AXID.
2712
2713 2020-03-20  Tim Horton  <timothy_horton@apple.com>
2714
2715         Upstream a variety of Cocoa-platform HAVE and ENABLE macros
2716         https://bugs.webkit.org/show_bug.cgi?id=209307
2717
2718         Reviewed by Andy Estes.
2719
2720         * Configurations/FeatureDefines.xcconfig:
2721
2722 2020-03-20  youenn fablet  <youenn@apple.com>
2723
2724         Add routines to check about:blank and about:srcdoc URLs
2725         https://bugs.webkit.org/show_bug.cgi?id=209174
2726
2727         Reviewed by Alex Christensen.
2728
2729         * Modules/fetch/FetchRequest.cpp:
2730         (WebCore::computeReferrer):
2731         * dom/Document.cpp:
2732         (WebCore::isURLPotentiallyTrustworthy):
2733         * html/HTMLFrameElementBase.cpp:
2734         (WebCore::HTMLFrameElementBase::location const):
2735         * loader/FrameLoader.cpp:
2736         (WebCore::FrameLoader::shouldTreatURLAsSrcdocDocument const):
2737         * page/SecurityPolicy.cpp:
2738         (WebCore::SecurityPolicy::shouldInheritSecurityOriginFromOwner):
2739
2740 2020-03-20  Chris Dumez  <cdumez@apple.com>
2741
2742         [iOS] Articles on NYTimes.com get truncated when switching between MobileSafari and another app
2743         https://bugs.webkit.org/show_bug.cgi?id=209321
2744         <rdar://problem/59763843>
2745
2746         Reviewed by Tim Horton.
2747
2748         Articles on NYTimes.com get truncated when switching between MobileSafari and another app
2749         (multitasking). The reason is that when you home out of MobileSafari, snapshots of the
2750         web view are taken at various sizes and we were firing 5 resizes events at the page as a
2751         result. Those resize events were confusing the logic on NYTimes.com and causing it to
2752         truncate the article.
2753
2754         To address the issue, we stop firing resize events at the page if the resize is happening
2755         during the snapshotting sequence.
2756
2757         * page/FrameView.cpp:
2758         (WebCore::FrameView::sendResizeEventIfNeeded):
2759         * page/Page.h:
2760         (WebCore::Page::shouldFireResizeEvents const):
2761         (WebCore::Page::setShouldFireResizeEvents):
2762
2763 2020-03-20  Jacob Uphoff  <jacob_uphoff@apple.com>
2764
2765         Unreviewed, reverting r258748.
2766
2767         This commit broke the Catalina build
2768
2769         Reverted changeset:
2770
2771         "Upstream a variety of Cocoa-platform HAVE and ENABLE macros"
2772         https://bugs.webkit.org/show_bug.cgi?id=209307
2773         https://trac.webkit.org/changeset/258748
2774
2775 2020-03-20  Zalan Bujtas  <zalan@apple.com>
2776
2777         [LFC][IFC] Avoid infinite loop when stuck on partial content
2778         https://bugs.webkit.org/show_bug.cgi?id=209312
2779         <rdar://problem/59954605>
2780
2781         Reviewed by Simon Fraser.
2782
2783         Speculative fix to address infinite loop/running out of inline run vector capacity at InlineFormattingContext::setDisplayBoxesForLine.
2784         (Checking if we managed to progress on the content while having partial runs.)
2785
2786         * layout/inlineformatting/InlineFormattingContext.cpp:
2787         (WebCore::Layout::InlineFormattingContext::lineLayout):
2788         * layout/inlineformatting/LineLayoutContext.cpp:
2789         (WebCore::Layout::LineLayoutContext::nextContentForLine):
2790         (WebCore::Layout::LineLayoutContext::handleFloatsAndInlineContent):
2791
2792 2020-03-20  Philippe Normand  <pnormand@igalia.com>
2793
2794         [GStreamer] White-list vp09 in the codec registry
2795         https://bugs.webkit.org/show_bug.cgi?id=209288
2796
2797         Reviewed by Xabier Rodriguez-Calvar.
2798
2799         * platform/graphics/gstreamer/GStreamerRegistryScanner.cpp:
2800         (WebCore::GStreamerRegistryScanner::initialize):
2801
2802 2020-03-20  Jack Lee  <shihchieh_lee@apple.com>
2803
2804         Nullptr crash in RenderObject::RenderObjectBitfields::isBox when current renderer is the RenderView
2805         https://bugs.webkit.org/show_bug.cgi?id=209251
2806         <rdar://problem/60103614>
2807
2808         Reviewed by Antti Koivisto.
2809
2810         It’s perfectly fine to call AccessibilityRenderObject::nextSibling on the RenderView (empty document) and since the RenderView has no sibling, let’s just early return with nullptr.
2811
2812         Test: fast/frames/iframe-empty-doc-crash.html
2813
2814         * accessibility/AccessibilityRenderObject.cpp:
2815         (WebCore::AccessibilityRenderObject::nextSibling const):
2816
2817 2020-03-20  Mike Gorse  <mgorse@suse.com>
2818
2819         Fix build with gstreamer 1.12
2820         https://bugs.webkit.org/show_bug.cgi?id=209296
2821
2822         Reviewed by Philippe Normand.
2823
2824         No new tests (build fix only).
2825
2826         * platform/graphics/gstreamer/GLVideoSinkGStreamer.cpp:
2827         (webKitGLVideoSinkChangeState): Add GST_VERSION_CHECK around check for
2828         GST_STATE_CHANGE_READY_TO_READY.
2829
2830 2020-03-20  Philippe Normand  <pnormand@igalia.com>
2831
2832         [Unix] Allow runtime release logging levels configuration
2833         https://bugs.webkit.org/show_bug.cgi?id=209286
2834
2835         Reviewed by Adrian Perez de Castro.
2836
2837         Setting to a comma-separated list like in this example should now work as expected:
2838
2839         WEBKIT_DEBUG="Media=debug,MediaSource=info" run-minibrowser --gtk ...
2840
2841         * platform/unix/LoggingUnix.cpp:
2842         (WebCore::logLevelString):
2843
2844 2020-03-19  Simon Fraser  <simon.fraser@apple.com>
2845
2846         Some scroll snapping tests are still flaky
2847         https://bugs.webkit.org/show_bug.cgi?id=165196
2848
2849         Reviewed by Wenson Hsieh.
2850
2851         WheelEventTestMonitor could trigger too early if the main thread was bogged down, delaying
2852         the firing of the m_updateNodeScrollPositionTimer scheduled from
2853         AsyncScrollingCoordinator::scheduleUpdateScrollPositionAfterAsyncScroll().
2854
2855         Fix by extending the life of the "ScrollingThreadSyncNeeded" reason until after the m_updateNodeScrollPositionTimer
2856         has fired
2857
2858         Fixes flakiness of tiled-drawing/scrolling/scroll-snap/scroll-snap-mandatory-mainframe-slow-vertical.html
2859         and others.
2860
2861         * page/scrolling/AsyncScrollingCoordinator.cpp:
2862         (WebCore::AsyncScrollingCoordinator::noteScrollingThreadSyncCompleteForNode):
2863         (WebCore::AsyncScrollingCoordinator::scheduleUpdateScrollPositionAfterAsyncScroll):
2864         (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScrollTimerFired):
2865         * page/scrolling/AsyncScrollingCoordinator.h:
2866         * page/scrolling/ThreadedScrollingTree.cpp:
2867         (WebCore::ThreadedScrollingTree::scrollingTreeNodeDidScroll):
2868
2869 2020-03-19  Peng Liu  <peng.liu6@apple.com>
2870
2871         Safari video gravity changes performance improvements
2872         https://bugs.webkit.org/show_bug.cgi?id=209316
2873
2874         Reviewed by Eric Carlson.
2875
2876         Remove an unnecessary (and harmful) call of setVideoLayerFrame in WebAVPlayerLayer:layoutSublayers.
2877
2878         When a video with the gravity AVLayerVideoGravityResizeAspectFill needs to enter the
2879         picture-in-picture mode from fullscreen, the extra call of setVideoLayerFrame will send
2880         an extra IPC message to the Web process to set the video layer bounds. So the [CATransaction commit]
2881         will need to wait for three property changes to complete - two in the Web process, and one in the
2882         UI process. The interval of the two property changes in the Web process is over 100 ms, because we
2883         delay the call of resolveBounds (which calls the second setVideoLayerFrame) at least 100 ms
2884         in WebAVPlayerLayer:layoutSublayers. That leads to long durations of core animation commits.
2885         In the test, the longest duration of commits is over 500 ms. After applying this patch,
2886         the longest duration in the test is about 50 ms.
2887
2888         * platform/ios/VideoFullscreenInterfaceAVKit.mm:
2889         (-[WebAVPlayerLayer layoutSublayers]):
2890
2891 2020-03-19  Tim Horton  <timothy_horton@apple.com>
2892
2893         Upstream a variety of Cocoa-platform HAVE and ENABLE macros
2894         https://bugs.webkit.org/show_bug.cgi?id=209307
2895
2896         Reviewed by Andy Estes.
2897
2898         * Configurations/FeatureDefines.xcconfig:
2899
2900 2020-03-19  Sunny He  <sunny_he@apple.com>
2901
2902         ScriptDisallowedScope should disable isEventAllowedInMainThread and isEventDispatchAllowedInSubtree asserts in WebKit1
2903         https://bugs.webkit.org/show_bug.cgi?id=209165
2904
2905         Reviewed by Ryosuke Niwa.
2906
2907         Under very intricate sequences of event dispatch in WebKit1, it is
2908         possible for security asserts to be triggered even if there is no
2909         underlying security issue soley due to the design patterns of
2910         WebKit1.
2911
2912         No new tests since the conditions for reproduction are very delicate
2913         and difficult to reliably capture in a test case.
2914
2915         * dom/ScriptDisallowedScope.h:
2916         (WebCore::ScriptDisallowedScope::isEventAllowedInMainThread):
2917         (WebCore::ScriptDisallowedScope::InMainThread::isEventDispatchAllowedInSubtree):
2918
2919 2020-03-19  Tim Horton  <timothy_horton@apple.com>
2920
2921         Upstream the definition of HAVE_READ_ONLY_SYSTEM_VOLUME
2922         https://bugs.webkit.org/show_bug.cgi?id=209305
2923
2924         Reviewed by Andy Estes.
2925
2926         * platform/mac/BlacklistUpdater.mm:
2927
2928 2020-03-19  Javier Fernandez  <jfernandez@igalia.com>
2929
2930         [css-grid] Changes in grid or elements inside the grid affects margin on other elements in the grid
2931         https://bugs.webkit.org/show_bug.cgi?id=209203
2932
2933         Reviewed by Darin Adler.
2934
2935         We should ignore the previously computed auto margins wheneven a relayout is performed.
2936
2937         Tests: imported/w3c/web-platform-tests/css/css-grid/alignment/grid-block-axis-alignment-auto-margins-001.html
2938                imported/w3c/web-platform-tests/css/css-grid/alignment/grid-block-axis-alignment-auto-margins-002.html
2939                imported/w3c/web-platform-tests/css/css-grid/alignment/grid-block-axis-alignment-auto-margins-003.html
2940                imported/w3c/web-platform-tests/css/css-grid/alignment/grid-block-axis-alignment-auto-margins-004.html
2941                imported/w3c/web-platform-tests/css/css-grid/alignment/grid-block-axis-alignment-auto-margins-005.html
2942                imported/w3c/web-platform-tests/css/css-grid/alignment/grid-block-axis-alignment-auto-margins-006.html
2943                imported/w3c/web-platform-tests/css/css-grid/alignment/grid-block-axis-alignment-auto-margins-007.html
2944                imported/w3c/web-platform-tests/css/css-grid/alignment/grid-block-axis-alignment-auto-margins-008.html
2945                imported/w3c/web-platform-tests/css/css-grid/alignment/grid-inline-axis-alignment-auto-margins-001.html
2946                imported/w3c/web-platform-tests/css/css-grid/alignment/grid-inline-axis-alignment-auto-margins-002.html
2947                imported/w3c/web-platform-tests/css/css-grid/alignment/grid-inline-axis-alignment-auto-margins-003.html
2948                imported/w3c/web-platform-tests/css/css-grid/alignment/grid-inline-axis-alignment-auto-margins-004.html
2949                imported/w3c/web-platform-tests/css/css-grid/alignment/grid-inline-axis-alignment-auto-margins-005.html
2950                imported/w3c/web-platform-tests/css/css-grid/alignment/grid-inline-axis-alignment-auto-margins-006.html
2951                imported/w3c/web-platform-tests/css/css-grid/alignment/grid-inline-axis-alignment-auto-margins-007.html
2952                imported/w3c/web-platform-tests/css/css-grid/alignment/grid-inline-axis-alignment-auto-margins-008.html
2953
2954         * rendering/RenderGrid.cpp:
2955         (WebCore::RenderGrid::updateAutoMarginsInRowAxisIfNeeded):
2956         (WebCore::RenderGrid::updateAutoMarginsInColumnAxisIfNeeded):
2957
2958 2020-03-19  Andres Gonzalez  <andresg_22@apple.com>
2959
2960         Remove caching of isOnScreen since it is not used.
2961         https://bugs.webkit.org/show_bug.cgi?id=209306
2962
2963         Reviewed by Chris Fleizach.
2964
2965         AXIsolatedObject was caching isOnScreen and it wasn't used. It has a
2966         performance impact since it needs to run on the main thread. thus this
2967         change removes it from the cache.
2968
2969         * accessibility/AccessibilityObjectInterface.h:
2970         * accessibility/isolatedtree/AXIsolatedObject.cpp:
2971         (WebCore::AXIsolatedObject::initializeAttributeData):
2972         * accessibility/isolatedtree/AXIsolatedObject.h:
2973
2974 2020-03-19  Andres Gonzalez  <andresg_22@apple.com>
2975
2976         URL needs to be isolatedCopied when cached in AXIsolatedObject.
2977         https://bugs.webkit.org/show_bug.cgi?id=209298
2978
2979         Reviewed by Chris Fleizach.
2980
2981         AXIsolatedObject needs to isolatedCopy the URL property in order to use
2982         it on the secondary thread.
2983
2984         * accessibility/isolatedtree/AXIsolatedObject.cpp:
2985         (WebCore::AXIsolatedObject::initializeAttributeData):
2986
2987 2020-03-19  Takashi Komori  <Takashi.Komori@sony.com>
2988
2989         [Curl] Add an API returns description of verification errors.
2990         https://bugs.webkit.org/show_bug.cgi?id=208913
2991
2992         Reviewed by Fujii Hironori.
2993
2994         WKCertificateInfoCopyVerificationErrorDescription returns the description of SSL verification error as human readable string.
2995         Browser can display more precise error information with this API.
2996
2997         API Test: Curl.CertificateAPI
2998
2999         * platform/network/curl/CertificateInfo.h:
3000         * platform/network/curl/CertificateInfoCurl.cpp:
3001         (WebCore::CertificateInfo::verificationErrorDescription const):
3002
3003 2020-03-19  Tim Horton  <timothy_horton@apple.com>
3004
3005         Implement support for cursor interactions on iPad
3006         https://bugs.webkit.org/show_bug.cgi?id=209268
3007
3008         Reviewed by Darin Adler.
3009
3010         No new tests in this patch, just upstreaming. Will attempt to enable
3011         some macOS mouse event tests on iOS in the future, though.
3012
3013         * platform/RuntimeApplicationChecks.h:
3014         * platform/cocoa/RuntimeApplicationChecksCocoa.mm:
3015         (WebCore::IOSApplication::isNews):
3016         (WebCore::IOSApplication::isStocks):
3017         (WebCore::IOSApplication::isFeedly):
3018         Add some bundle ID checks needed in WebKit.
3019
3020 2020-03-19  Andres Gonzalez  <andresg_22@apple.com>
3021
3022         AXIsolatedObject implementation of the title method.
3023         https://bugs.webkit.org/show_bug.cgi?id=209291
3024
3025         Reviewed by Chris Fleizach.
3026
3027         - Implements AXIsolatedObgject::title.
3028         - Modified implementation of AXIsolatedObject::titleAttributeValue to
3029         use its appropriate key.
3030
3031         * accessibility/isolatedtree/AXIsolatedObject.cpp:
3032         (WebCore::AXIsolatedObject::initializeAttributeData):
3033         (WebCore::AXIsolatedObject::title const): Deleted.
3034         * accessibility/isolatedtree/AXIsolatedObject.h:
3035
3036 2020-03-19  Chris Fleizach  <cfleizach@apple.com>
3037
3038         AX: VO and safari: can't press the play button
3039         https://bugs.webkit.org/show_bug.cgi?id=209249
3040
3041         Reviewed by Darin Adler.
3042
3043         Test: accessibility/ios-simulator/has-touch-event-listener-with-shadow.html
3044
3045         If a node is in a shadowRoot, going up the node parent tree will stop and not check the entire tree for touch event listeners
3046         and a touch event won't be dispatched. We need to change to use the parentInComposedTree instead to go up the chain.
3047
3048         * accessibility/ios/AccessibilityObjectIOS.mm:
3049         (WebCore::AccessibilityObject::hasTouchEventListener const):
3050
3051 2020-03-19  Andres Gonzalez  <andresg_22@apple.com>
3052
3053         [WebAccessibilityObjectWrapper remoteAccessibilityParentObject] must run on the main thread.
3054         https://bugs.webkit.org/show_bug.cgi?id=209284
3055
3056         Reviewed by Chris Fleizach.
3057
3058         - Dispatch [WebAccessibilityObjectWrapper remoteAccessibilityParentObject] to the main thread.
3059         - [WebAccessibilityObjectWrapper windowElement:] must then call it outside the dispatched lambda.
3060
3061         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
3062         (-[WebAccessibilityObjectWrapper remoteAccessibilityParentObject]):
3063         (-[WebAccessibilityObjectWrapper windowElement:]):
3064
3065 2020-03-19  Antoine Quint  <graouts@apple.com>
3066
3067         [Web Animations] Mark promises as handled when rejected
3068         https://bugs.webkit.org/show_bug.cgi?id=209240
3069         <rdar://problem/60592305>
3070
3071         Reviewed by Youenn Fablet.
3072
3073         Implementing the spec change discussed in https://github.com/w3c/csswg-drafts/issues/4556.
3074
3075         * animation/WebAnimation.cpp:
3076         (WebCore::WebAnimation::cancel):
3077         (WebCore::WebAnimation::resetPendingTasks):
3078
3079 2020-03-19  Charlie Turner  <cturner@igalia.com>
3080
3081         Fix many warnings with Clang 7.0 on GTK x86-64 in Debug.
3082         https://bugs.webkit.org/show_bug.cgi?id=209146
3083
3084         Reviewed by Darin Adler.
3085
3086         Warning fixes, no new tests.
3087
3088         * Modules/encryptedmedia/MediaKeys.cpp:
3089         (WebCore::MediaKeys::MediaKeys):
3090         * Modules/webaudio/MediaStreamAudioSource.h: The m_numberOfFrames ivar
3091         is platform-specific.
3092         * loader/cache/CachedResource.cpp:
3093         (WebCore::CachedResource::load):
3094         * platform/graphics/texmap/TextureMapperGL.cpp:
3095         (WebCore::TextureMapperGLData::getStaticVBO):
3096         * platform/mediastream/RealtimeVideoSource.h:
3097         * platform/mediastream/gstreamer/GStreamerAudioCapturer.h: There are
3098         still virtual methods in this class, but no virtual destructor. Since
3099         this won't be subclassed further (I doubt, anyway!) lets make it final
3100         and plug the bug.
3101         * platform/mediastream/gstreamer/GStreamerVideoCaptureSource.cpp:
3102         * platform/mediastream/gstreamer/GStreamerVideoCapturer.h: See
3103         AudioCapturer.
3104         * platform/mediastream/libwebrtc/GStreamerVideoDecoderFactory.cpp:
3105         (WebCore::GStreamerVideoDecoder::RegisterDecodeCompleteCallback): Deleted.
3106         (WebCore::GStreamerVideoDecoder::ImplementationName const): Deleted.
3107         * platform/mediastream/libwebrtc/GStreamerVideoEncoder.cpp:
3108         * platform/mediastream/libwebrtc/GStreamerVideoEncoderFactory.cpp: The
3109         encoder was being used uninitialized, and hence codec support can not
3110         be working as intended. Fix that bug.
3111         (WebCore::GStreamerVideoEncoder::AddCodecIfSupported):
3112         (WebCore::GStreamerVideoEncoder::InitEncode): Deleted.
3113         (WebCore::GStreamerVideoEncoder::GetEncoderInfo const): Deleted.
3114         * platform/mediastream/libwebrtc/GStreamerVideoEncoderFactory.h:
3115         * platform/network/soup/NetworkStorageSessionSoup.cpp:
3116         (WebCore::NetworkStorageSession::setCookies):
3117         * rendering/RenderLayerBacking.h: Condition the bear trap on Cocoa
3118         platform where the crash is being seen. On GTK these traps generate
3119         warning spam and we don't see the crash here.
3120         * rendering/RenderThemeAdwaita.h:
3121         * testing/Internals.cpp:
3122         (WebCore::Internals::readPreferenceInteger):
3123         (WebCore::Internals::encodedPreferenceValue):
3124         (WebCore::Internals::getUTIFromMIMEType):
3125         (WebCore::Internals::getUTIFromTag):
3126
3127 2020-03-19  Antoine Quint  <graouts@apple.com>
3128
3129         onwebkit{animation, transition}XX handlers missing from Document
3130         https://bugs.webkit.org/show_bug.cgi?id=206170
3131         <rdar://problem/58596373>
3132
3133         Reviewed by Youenn Fablet.
3134
3135         We now specify the non-standard CSS Animations and CSS Transitions event handlers on DocumentAndElementEventHandlers.idl rather than Element.idl
3136         such that they specified on both Element and Document.
3137
3138         * dom/DocumentAndElementEventHandlers.idl:
3139         * dom/Element.idl:
3140
3141 2020-03-19  Carlos Garcia Campos  <cgarcia@igalia.com>
3142
3143         [GTK][WPE] Media controls numeric position value is not automatically updated during playback
3144         https://bugs.webkit.org/show_bug.cgi?id=209051
3145
3146         Reviewed by Philippe Normand.
3147
3148         The time label is not updated because updateTime() thinks the media controls are hidden when not hovered, but
3149         for audio elements the controls are always visible.
3150
3151         * Modules/mediacontrols/mediaControlsAdwaita.js:
3152         (Controller.prototype.controlsAreAlwaysVisible): Return true for audio elements.
3153
3154 2020-03-19  Enrique Ocaña González  <eocanha@igalia.com>
3155
3156         [GTK] media/track/track-automatic-subtitles.html is timing out
3157         https://bugs.webkit.org/show_bug.cgi?id=116957
3158
3159         Reviewed by Adrian Perez de Castro.
3160
3161         Moved CaptionUserPreferencesMediaAF::textTrackSelectionScore() implementation
3162         to the CaptionUserPreferencesMedia superclass.
3163
3164         Tested by existing test.
3165
3166         * page/CaptionUserPreferences.cpp:
3167         (WebCore::CaptionUserPreferences::textTrackSelectionScore const):
3168         * page/CaptionUserPreferencesMediaAF.cpp:
3169         * page/CaptionUserPreferencesMediaAF.h:
3170
3171 2020-03-19  Philippe Normand  <pnormand@igalia.com>
3172
3173         [GTK][WPE] Unreviewed, build fixes after r258547 when disabling release logging support
3174
3175         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
3176         (WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer):
3177         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
3178         * platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.h:
3179
3180 2020-03-19  youenn fablet  <youenn@apple.com>
3181
3182         Make URL::path() return a StringView
3183         https://bugs.webkit.org/show_bug.cgi?id=209173
3184
3185         Reviewed by Alex Christensen.
3186
3187         Update code according new path return type.
3188
3189         * Modules/plugins/YouTubePluginReplacement.cpp:
3190         (WebCore::processAndCreateYouTubeURL):
3191         (WebCore::YouTubePluginReplacement::youTubeURLFromAbsoluteURL):
3192         * html/Autofill.cpp:
3193         (WebCore::AutofillData::createFromHTMLFormControlElement):
3194         * html/URLUtils.h:
3195         (WebCore::URLUtils<T>::pathname const):
3196         * loader/FormSubmission.cpp:
3197         (WebCore::appendMailtoPostFormDataToURL):
3198         * loader/appcache/ManifestParser.cpp:
3199         (WebCore::manifestPath):
3200         * page/Location.cpp:
3201         (WebCore::Location::pathname const):
3202         * page/UserContentURLPattern.cpp:
3203         (WebCore::MatchTester::MatchTester):
3204         (WebCore::UserContentURLPattern::matchesPath const):
3205         * page/csp/ContentSecurityPolicySource.cpp:
3206         (WebCore::ContentSecurityPolicySource::pathMatches const):
3207         * platform/network/curl/CookieJarDB.cpp:
3208         (WebCore::CookieJarDB::searchCookies):
3209         (WebCore::CookieJarDB::deleteCookie):
3210         * platform/network/curl/CookieUtil.cpp:
3211         (WebCore::CookieUtil::defaultPathForURL):
3212         * platform/network/curl/CurlRequest.cpp:
3213         (WebCore::CurlRequest::invokeDidReceiveResponseForFile):
3214         * platform/text/TextEncoding.cpp:
3215         (WebCore::decodeURLEscapeSequences):
3216         * platform/text/TextEncoding.h:
3217         * workers/WorkerLocation.cpp:
3218         (WebCore::WorkerLocation::pathname const):
3219         * workers/service/ServiceWorkerContainer.cpp:
3220         (WebCore::ServiceWorkerContainer::addRegistration):
3221         * workers/service/ServiceWorkerJob.cpp:
3222         (WebCore::ServiceWorkerJob::validateServiceWorkerResponse):
3223         * workers/service/server/RegistrationDatabase.cpp:
3224         (WebCore::RegistrationDatabase::doPushChanges):
3225
3226 2020-03-18  Peng Liu  <peng.liu6@apple.com>
3227
3228         The value of [AVPlayerViewController isPictureInPicturePossible] is NO in the first attempt to enter PiP
3229         https://bugs.webkit.org/show_bug.cgi?id=204979
3230
3231         Reviewed by Jer Noble.
3232
3233         A follow-up patch to fix build failures.
3234         This patch also removes a meaningless line in the dealloc of WebAVPlayerViewController.
3235
3236         * platform/ios/VideoFullscreenInterfaceAVKit.mm:
3237         (-[WebAVPlayerViewController initWithFullscreenInterface:]):
3238         (-[WebAVPlayerViewController dealloc]):
3239         (VideoFullscreenInterfaceAVKit::doEnterFullscreen):
3240
3241 2020-03-18  Andres Gonzalez  <andresg_22@apple.com>
3242
3243         Use helper function retainPtr(T*) instead of creating one.
3244         https://bugs.webkit.org/show_bug.cgi?id=209269
3245
3246         Reviewed by Chris Fleizach.
3247
3248         This is acorrection to patch in bug: https://bugs.webkit.org/show_bug.cgi?id=209247.
3249         Use the existing retainPtr helper funtion instead of creating a new helper.
3250
3251         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
3252         (-[WebAccessibilityObjectWrapper attachmentView]):
3253         (-[WebAccessibilityObjectWrapper doAXAttributedStringForTextMarkerRange:spellCheck:]):
3254         (-[WebAccessibilityObjectWrapper textMarkerRangeFromVisiblePositions:endPosition:]):
3255         (-[WebAccessibilityObjectWrapper associatedPluginParent]):
3256         (-[WebAccessibilityObjectWrapper windowElement:]):
3257         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
3258         (-[WebAccessibilityObjectWrapper accessibilityShowContextMenu]):
3259         (-[WebAccessibilityObjectWrapper textMarkerRangeAtTextMarker:forUnit:]):
3260         (-[WebAccessibilityObjectWrapper lineTextMarkerRangeForTextMarker:forUnit:]):
3261         (-[WebAccessibilityObjectWrapper textMarkerForTextMarker:atUnit:]):
3262         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:forParameter:]):
3263         (retainWrapper): Deleted.
3264
3265 2020-03-18  Zalan Bujtas  <zalan@apple.com>
3266
3267         [Multicolumn] RenderListItem::positionListMarker should not fail when the list marker is inside a spanner.
3268         https://bugs.webkit.org/show_bug.cgi?id=209262
3269         <rdar://problem/58447665>
3270
3271         Reviewed by Simon Fraser.
3272
3273         When the list marker is in a column spanner and as a result it gets moved under the column flow, the
3274         normal "let's find the list item by walking up on the ancestor chain" does not work anymore.
3275         We need to check if this list marker is inside a spanner and climb up on the ancestor chain by
3276         using the spanner placeholder position (see RenderListMarker::parentBox).
3277         This patch also moves the marker's overflow computation from the list item to the marker.
3278
3279         Test: fast/multicol/list-item-marker-inside-column-spanner.html
3280
3281         * rendering/RenderListItem.cpp:
3282         (WebCore::RenderListItem::addOverflowFromChildren):
3283         (WebCore::RenderListItem::positionListMarker): Deleted.
3284         * rendering/RenderListMarker.cpp:
3285         (WebCore::RenderListMarker::parentBox):
3286         (WebCore::RenderListMarker::addOverflowFromListMarker):
3287         (WebCore::RenderListMarker::layout):
3288         * rendering/RenderListMarker.h:
3289
3290 2020-03-18  Simon Fraser  <simon.fraser@apple.com>
3291
3292         eventSender.monitorWheelEvents() is very fragile
3293         https://bugs.webkit.org/show_bug.cgi?id=197819
3294         <rdar://problem/51319456>
3295
3296         Reviewed by Tim Horton.
3297
3298         Deflake tests using eventSender.monitorWheelEvents() by fixing several causes of flakiness,
3299         adding back changes from r257844 that were reverted in r258558.
3300         
3301         First, have EventSendingController keep track of whether it's seen then "end" event
3302         for the scrolling and momentum phases, and pass this down to WheelEventTestMonitor, which
3303         now waits until it sees these, which prevents premature triggering which was a common cause of
3304         failure before.
3305         
3306         Second, remove WheelEventTestMonitor's 1/60s timer and instead have WheelEventTestMonitor test
3307         for completion in a callout from the end of Page::updateRendering(), which makes it test
3308         and fire at a more consistent time.
3309         
3310         Third, push WheelEventTestMonitor to the ScrollingTree, so that reasons for deferral
3311         can be added on the scrolling thread. This fixes an issue where the RunLoop::main().dispatch()
3312         used to send the "ScrollingThreadSyncNeeded" reason to the main thread would get delayed,
3313         also resulting in a premature trigger.
3314
3315         * Modules/applepay/ApplePaySession.cpp: Unified sources!
3316         * dom/WindowEventLoop.cpp: Unified sources!
3317         * page/EventHandler.cpp:
3318         (WebCore::EventHandler::handleWheelEvent):
3319         * page/FrameView.cpp:
3320         (WebCore::FrameView::scrollOffsetChangedViaPlatformWidgetImpl):
3321         * page/Page.cpp:
3322         (WebCore::Page::doAfterUpdateRendering):
3323         (WebCore::Page::wheelEventTestMonitor const):
3324         (WebCore::Page::clearWheelEventTestMonitor):
3325         (WebCore::Page::isMonitoringWheelEvents const):
3326         (WebCore::Page::ensureWheelEventTestMonitor):
3327         * page/Page.h:
3328         (WebCore::Page::wheelEventTestMonitor const): Deleted.
3329         (WebCore::Page::clearWheelEventTestMonitor): Deleted.
3330         (WebCore::Page::isMonitoringWheelEvents const): Deleted.
3331         * page/WheelEventTestMonitor.cpp:
3332         (WebCore::WheelEventTestMonitor::WheelEventTestMonitor):
3333         (WebCore::WheelEventTestMonitor::clearAllTestDeferrals):
3334         (WebCore::WheelEventTestMonitor::setTestCallbackAndStartMonitoring):
3335         (WebCore::WheelEventTestMonitor::deferForReason):
3336         (WebCore::WheelEventTestMonitor::removeDeferralForReason):
3337         (WebCore::WheelEventTestMonitor::receivedWheelEvent):
3338         (WebCore::WheelEventTestMonitor::scheduleCallbackCheck):
3339         (WebCore::WheelEventTestMonitor::checkShouldFireCallbacks):
3340         (WebCore::operator<<):
3341         (WebCore::WheelEventTestMonitor::setTestCallbackAndStartNotificationTimer): Deleted.
3342         (WebCore::WheelEventTestMonitor::triggerTestTimerFired): Deleted.
3343         * page/WheelEventTestMonitor.h:
3344         (WebCore::WheelEventTestMonitorCompletionDeferrer::WheelEventTestMonitorCompletionDeferrer):
3345         (WebCore::WheelEventTestMonitorCompletionDeferrer::~WheelEventTestMonitorCompletionDeferrer):
3346         * page/scrolling/AsyncScrollingCoordinator.cpp:
3347         (WebCore::AsyncScrollingCoordinator::frameViewLayoutUpdated):
3348         (WebCore::AsyncScrollingCoordinator::deferWheelEventTestCompletionForReason const): Deleted.
3349         (WebCore::AsyncScrollingCoordinator::removeWheelEventTestCompletionDeferralForReason const): Deleted.
3350         * page/scrolling/AsyncScrollingCoordinator.h:
3351         * page/scrolling/ScrollingCoordinator.h:
3352         (WebCore::ScrollingCoordinator::startMonitoringWheelEvents):
3353         (WebCore::ScrollingCoordinator::stopMonitoringWheelEvents):
3354         * page/scrolling/ScrollingTree.cpp:
3355         (WebCore::ScrollingTree::handleWheelEvent):
3356         * page/scrolling/ScrollingTree.h:
3357         (WebCore::ScrollingTree::setWheelEventTestMonitor):
3358         (WebCore::ScrollingTree::receivedWheelEvent):
3359         * page/scrolling/ThreadedScrollingTree.cpp:
3360         (WebCore::ThreadedScrollingTree::scrollingTreeNodeDidScroll):
3361         (WebCore::ThreadedScrollingTree::deferWheelEventTestCompletionForReason): Deleted.
3362         (WebCore::ThreadedScrollingTree::removeWheelEventTestCompletionDeferralForReason): Deleted.
3363         * page/scrolling/ThreadedScrollingTree.h:
3364         * page/scrolling/mac/ScrollingCoordinatorMac.h:
3365         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
3366         (WebCore::ScrollingCoordinatorMac::startMonitoringWheelEvents):
3367         (WebCore::ScrollingCoordinatorMac::stopMonitoringWheelEvents):
3368         * page/scrolling/mac/ScrollingTreeMac.h:
3369         * page/scrolling/mac/ScrollingTreeMac.mm:
3370         (ScrollingTreeMac::setWheelEventTestMonitor):
3371         (ScrollingTreeMac::receivedWheelEvent):
3372         (ScrollingTreeMac::deferWheelEventTestCompletionForReason):
3373         (ScrollingTreeMac::removeWheelEventTestCompletionDeferralForReason):
3374         * page/scrolling/mac/ScrollingTreeScrollingNodeDelegateMac.mm:
3375         (WebCore::ScrollingTreeScrollingNodeDelegateMac::deferWheelEventTestCompletionForReason const):
3376         (WebCore::ScrollingTreeScrollingNodeDelegateMac::removeWheelEventTestCompletionDeferralForReason const):
3377         * testing/js/WebCoreTestSupport.cpp:
3378         (WebCoreTestSupport::setWheelEventMonitorTestCallbackAndStartMonitoring):
3379         (WebCoreTestSupport::setTestCallbackAndStartNotificationTimer): Deleted.
3380         * testing/js/WebCoreTestSupport.h:
3381