REGRESSION(r239636): ImageDecoder::setEncodedDataStatusChangeCallback() can be called...
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2019-01-07  Zan Dobersek  <zdobersek@igalia.com>
2
3         REGRESSION(r239636): ImageDecoder::setEncodedDataStatusChangeCallback() can be called on a null decoder
4         https://bugs.webkit.org/show_bug.cgi?id=193187
5
6         Reviewed by Philippe Normand.
7
8         * platform/graphics/ImageSource.cpp:
9         (WebCore::ImageSource::ensureDecoderAvailable): Bail before calling the
10         setEncodedDataStatusChangeCallback() method when the returned
11         ImageDecoder object is null.
12
13 2019-01-06  Zan Dobersek  <zdobersek@igalia.com>
14
15         [Nicosia] Take over CoordinatedGraphics-named implementation of async scrolling classes
16         https://bugs.webkit.org/show_bug.cgi?id=193133
17
18         Reviewed by Michael Catanzaro.
19
20         Move the CoordinatedGraphics-specific files under
21         page/scrolling/coordinatedgraphics/ to page/scrolling/nicosia/, along
22         with renaming the files and classes accordingly. Implementation will
23         only depend on the Nicosia-specific layer structure and is not specific
24         to the CoordinatedGraphics system.
25
26         * PlatformPlayStation.cmake:
27         * SourcesGTK.txt:
28         * SourcesWPE.txt:
29         * page/scrolling/nicosia/ScrollingCoordinatorNicosia.cpp: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp.
30         * page/scrolling/nicosia/ScrollingCoordinatorNicosia.h: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.h.
31         * page/scrolling/nicosia/ScrollingStateNodeNicosia.cpp: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingStateNodeCoordinatedGraphics.cpp.
32         * page/scrolling/nicosia/ScrollingTreeFixedNode.cpp: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFixedNode.cpp.
33         * page/scrolling/nicosia/ScrollingTreeFixedNode.h: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFixedNode.h.
34         * page/scrolling/nicosia/ScrollingTreeFrameScrollingNodeNicosia.cpp: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFrameScrollingNodeCoordinatedGraphics.cpp.
35         * page/scrolling/nicosia/ScrollingTreeFrameScrollingNodeNicosia.h: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFrameScrollingNodeCoordinatedGraphics.h.
36         * page/scrolling/nicosia/ScrollingTreeNicosia.cpp: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeCoordinatedGraphics.cpp.
37         * page/scrolling/nicosia/ScrollingTreeNicosia.h: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeCoordinatedGraphics.h.
38         * page/scrolling/nicosia/ScrollingTreeStickyNode.cpp: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeStickyNode.cpp.
39         * page/scrolling/nicosia/ScrollingTreeStickyNode.h: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeStickyNode.h.
40         * platform/TextureMapper.cmake:
41
42 2019-01-06  Jiewen Tan  <jiewen_tan@apple.com>
43
44         [WebAuthN] Import U2F command/response converters from Chromium
45         https://bugs.webkit.org/show_bug.cgi?id=193150
46         <rdar://problem/47054028>
47
48         Reviewed by Brent Fulgham.
49
50         This patch imports Chromium's U2F command/response converters:
51         https://fidoalliance.org/specs/fido-v2.0-id-20180227/fido-client-to-authenticator-protocol-v2.0-id-20180227.html#u2f-interoperability
52         1. It directly imports the following files and suit them to WebKit's coding style:
53         https://cs.chromium.org/chromium/src/device/fido/u2f_command_constructor.cc?l=1&rcl=db624110317d01efa78cd32e7be1524190e1beb0
54         https://cs.chromium.org/chromium/src/device/fido/u2f_command_constructor.h?rcl=db624110317d01efa78cd32e7be1524190e1beb0
55         https://cs.chromium.org/chromium/src/device/fido/u2f_command_constructor_unittest.cc?rcl=db624110317d01efa78cd32e7be1524190e1beb0
56         2. It gathers the following methods into U2fResponseConverter:
57         AuthenticatorMakeCredentialResponse::CreateFromU2fRegisterResponse()
58         AuthenticatorGetAssertionResponse::CreateFromU2fSignResponse()
59         3. It also updates FidoConstants.h, FidoTestData.h and CtapResponseTest.cpp accordingly.
60
61         Besides importing stuff from Chroimum, it also gathers a bunch of constants and helper functions into WebAuthenticationConstants.h
62         and WebAuthenticationUtils.h. It also fixes Bug 183534: 2) and 7).
63
64         Covered by API tests.
65
66         * Modules/webauthn/AuthenticatorCoordinator.cpp:
67         (WebCore::AuthenticatorCoordinatorInternal::produceClientDataJsonHash):
68         * Modules/webauthn/WebAuthenticationConstants.h: Copied from Source/WebCore/Modules/webauthn/COSEConstants.h.
69         * Modules/webauthn/WebAuthenticationUtils.cpp: Added.
70         (WebCore::convertBytesToVector):
71         (WebCore::produceRpIdHash):
72         (WebCore::encodeES256PublicKeyAsCBOR):
73         (WebCore::buildAttestedCredentialData):
74         (WebCore::buildAuthData):
75         (WebCore::buildAttestationObject):
76         * Modules/webauthn/WebAuthenticationUtils.h: Renamed from Source/WebCore/Modules/webauthn/COSEConstants.h.
77         * Modules/webauthn/fido/DeviceResponseConverter.cpp:
78         (fido::getCredentialId):
79         (fido::readCTAPGetInfoResponse):
80         * Modules/webauthn/fido/FidoConstants.h:
81         * Modules/webauthn/fido/U2fCommandConstructor.cpp: Added.
82         (fido::WebCore::constructU2fRegisterCommand):
83         (fido::WebCore::constructU2fSignCommand):
84         (fido::isConvertibleToU2fRegisterCommand):
85         (fido::isConvertibleToU2fSignCommand):
86         (fido::convertToU2fRegisterCommand):
87         (fido::convertToU2fCheckOnlySignCommand):
88         (fido::convertToU2fSignCommand):
89         (fido::constructBogusU2fRegistrationCommand):
90         * Modules/webauthn/fido/U2fCommandConstructor.h: Added.
91         * Modules/webauthn/fido/U2fResponseConverter.cpp: Added.
92         (fido::WebCore::extractECPublicKeyFromU2fRegistrationResponse):
93         (fido::WebCore::extractCredentialIdFromU2fRegistrationResponse):
94         (fido::WebCore::createAttestedCredentialDataFromU2fRegisterResponse):
95         (fido::WebCore::parseX509Length):
96         (fido::WebCore::createFidoAttestationStatementFromU2fRegisterResponse):
97         (fido::readU2fRegisterResponse):
98         (fido::readFromU2fSignResponse):
99         * Modules/webauthn/fido/U2fResponseConverter.h: Added.
100         * Modules/webgpu/WebGPUCommandBuffer.cpp:
101         * Sources.txt:
102         * WebCore.xcodeproj/project.pbxproj:
103
104 2019-01-06  David Kilzer  <ddkilzer@apple.com>
105
106         Leak of WTF::Function objects in WebCore::CryptoKeyRSA::generatePair() (64-80 bytes each) in com.apple.WebKit.WebContent running WebKit layout tests
107         <https://webkit.org/b/193177>
108         <rdar://problem/47072196>
109
110         Reviewed by Saam Barati.
111
112         * crypto/mac/CryptoKeyRSAMac.cpp:
113         (WebCore::CryptoKeyRSA::generatePair): Fix the leak by changing
114         raw pointers to heap-allocated __block variables to hold the
115         WTF::Function objects until they are consumed within the block
116         passed to dispatch_async().  The __block variables act like
117         captured variables in a C++ lambda and have the same lifetime as
118         the block that they are captured in.  Note that we would have to
119         convert the source file from C++ to Objective-C++ to use a C++
120         lambda functor with dispatch_async(), which creates its own
121         issue because the comipiler requires a copy constructor to
122         convert the C++ lambda to a block functor, but the copy
123         constructor for the C++ lambda is implicitly deleted because the
124         WTF::Function copy constructor is explicitly deleted.  Whew!
125
126 2019-01-06  Pablo Saavedra  <psaavedra@igalia.com>
127
128         [WPE][GTK] Building with ENABLE_VIDEO=OFF fails trying to use Document MediaPlayback functions.
129         https://bugs.webkit.org/show_bug.cgi?id=193174
130
131         Reviewed by Michael Catanzaro.
132
133         * page/Page.cpp:
134         (WebCore::Page::stopAllMediaPlayback):
135         (WebCore::Page::suspendAllMediaPlayback):
136         (WebCore::Page::resumeAllMediaPlayback):
137
138 2019-01-05  David Kilzer  <ddkilzer@apple.com>
139
140         Leak of two CCRSACryptorRef (4.0 Kbytes/1 page each) in com.apple.WebKit.WebContent running WebKit layout tests
141         <https://webkit.org/b/193154>
142         <rdar://problem/47052993>
143
144         Reviewed by Brent Fulgham.
145
146         Broadly:
147         - Fix leaks by switching from using raw pointers to using
148           std::unique_ptr<>.
149         - Introduce PlatformRSAKeyContainer type to handle different
150           std::unique_ptr<> on each platform.
151         - Get rid of custom CryptoKeyRSA destructors since the
152           std::unique_ptr<> handles that with a Deleter.
153         - Initialize stack variables to nullptr.
154
155         * crypto/gcrypt/CryptoKeyRSAGCrypt.cpp:
156         (WebCore::CryptoKeyRSA::create):
157         (WebCore::CryptoKeyRSA::CryptoKeyRSA):
158         (WebCore::CryptoKeyRSA::keySizeInBits const):
159         (WebCore::CryptoKeyRSA::generatePair):
160         (WebCore::CryptoKeyRSA::importSpki):
161         (WebCore::CryptoKeyRSA::importPkcs8):
162         (WebCore::CryptoKeyRSA::exportSpki const):
163         (WebCore::CryptoKeyRSA::exportPkcs8 const):
164         (WebCore::CryptoKeyRSA::algorithm const):
165         (WebCore::CryptoKeyRSA::exportData const):
166         (WebCore::CryptoKeyRSA::~CryptoKeyRSA): Deleted.
167         * crypto/keys/CryptoKeyRSA.h:
168         (WebCore::CCRSACryptorRefDeleter::operator() const):
169         * crypto/mac/CryptoKeyRSAMac.cpp:
170         (WebCore::getPublicKeyComponents):
171         (WebCore::getPrivateKeyComponents):
172         (WebCore::CryptoKeyRSA::CryptoKeyRSA):
173         (WebCore::CryptoKeyRSA::create):
174         (WebCore::CryptoKeyRSA::exportData const):
175         (WebCore::CryptoKeyRSA::generatePair):
176         (WebCore::CryptoKeyRSA::importSpki):
177         (WebCore::CryptoKeyRSA::importPkcs8):
178         (WebCore::CryptoKeyRSA::~CryptoKeyRSA): Deleted.
179
180 2019-01-05  Zalan Bujtas  <zalan@apple.com>
181
182         Incorrect clipping across compositing boundary.
183         https://bugs.webkit.org/show_bug.cgi?id=193172
184         <rdar://problem/44693008>
185
186         Reviewed by Simon Fraser.
187
188         Use temporary cliprect type when crossing compositing boundary to prevent cliprect caching.
189
190         The issue here is that RenderLayer::backgroundClipRect() could cross compositing boundary by calling parentClipRects() which triggers
191         clip rect update using the wrong painting root. This happens when the layer hierarchy and the compositing context do not match.
192         For clip rect computation, we need to climb up on the layer hierarchy (calling parent layer's cliprect functions)
193         but we also need to make sure that the computed cliprects on any given layer are cached only when the painting root is correct.
194         It ensures that when we paint a layer (with the painting root as entry point), the cached cliprects are always based on its onw painting root. 
195
196         Test: compositing/clipping/cached-cliprect-with-compositing-boundary.html
197
198         * rendering/RenderLayer.cpp:
199         (WebCore::RenderLayer::calculateClipRects const):
200
201 2019-01-05  Youenn Fablet  <youenn@apple.com>
202
203         Service Worker fetch should obey its referrer policy
204         https://bugs.webkit.org/show_bug.cgi?id=193152
205
206         Reviewed by Chris Dumez.
207
208         Pass referrer policy retrieved when fetching the service worker script to the SWServer.
209         The SWServer then stores it persistently and sends it to the manager creating service workers.
210         This manager will then set the referrer policy on the dummy Document of the corresponding service worker.
211
212         Covered by rebased test.
213
214         * workers/WorkerScriptLoader.cpp:
215         (WebCore::WorkerScriptLoader::didReceiveResponse):
216         * workers/WorkerScriptLoader.h:
217         (WebCore::WorkerScriptLoader::referrerPolicy const):
218         * workers/service/SWClientConnection.cpp:
219         (WebCore::SWClientConnection::failedFetchingScript):
220         * workers/service/ServiceWorkerContainer.cpp:
221         (WebCore::ServiceWorkerContainer::jobFinishedLoadingScript):
222         * workers/service/ServiceWorkerContainer.h:
223         * workers/service/ServiceWorkerContextData.cpp:
224         (WebCore::ServiceWorkerContextData::isolatedCopy const):
225         * workers/service/ServiceWorkerContextData.h:
226         (WebCore::ServiceWorkerContextData::encode const):
227         (WebCore::ServiceWorkerContextData::decode):
228         * workers/service/ServiceWorkerFetchResult.h:
229         (WebCore::ServiceWorkerFetchResult::encode const):
230         (WebCore::ServiceWorkerFetchResult::decode):
231         * workers/service/ServiceWorkerJob.cpp:
232         (WebCore::ServiceWorkerJob::notifyFinished):
233         * workers/service/ServiceWorkerJobClient.h:
234         * workers/service/context/ServiceWorkerThreadProxy.cpp:
235         (WebCore::createPageForServiceWorker):
236         * workers/service/server/RegistrationDatabase.cpp:
237         (WebCore::recordsTableSchema):
238         (WebCore::RegistrationDatabase::doPushChanges):
239         (WebCore::RegistrationDatabase::importRecords):
240         * workers/service/server/SWServer.cpp:
241         (WebCore::SWServer::addRegistrationFromStore):
242         (WebCore::SWServer::updateWorker):
243         (WebCore::SWServer::installContextData):
244         * workers/service/server/SWServer.h:
245         * workers/service/server/SWServerJobQueue.cpp:
246         (WebCore::SWServerJobQueue::scriptFetchFinished):
247         * workers/service/server/SWServerWorker.cpp:
248         (WebCore::SWServerWorker::SWServerWorker):
249         (WebCore::SWServerWorker::contextData const):
250         * workers/service/server/SWServerWorker.h:
251
252 2019-01-04  Simon Fraser  <simon.fraser@apple.com>
253
254         Factor legacy WK1 code for fixed and scrolling layers into their own helper class
255         https://bugs.webkit.org/show_bug.cgi?id=193165
256
257         Reviewed by Frédéric Wang.
258
259         RenderLayerCompositor has some code to handle registration of viewport-constrained
260         and scrolling layers which is specific to iOS WK1. To reduce pollution, move this
261         into its own helper class called LegacyWebKitScrollingLayerCoordinator, which is only
262         allocated for iOS WK1.
263         
264         iOS WK1 never has a ScrollingCoordinator, so rather than the check for scrollingCoordinator(),
265         we know that we only made a LegacyWebKitScrollingLayerCoordinator when there's a platform widget
266         (i.e. WK1).
267         
268         * page/ChromeClient.h:
269         * rendering/RenderLayerCompositor.cpp:
270         (WebCore::RenderLayerCompositor::RenderLayerCompositor):
271         (WebCore::RenderLayerCompositor::updateCustomLayersAfterFlush):
272         (WebCore::RenderLayerCompositor::didFlushChangesForLayer):
273         (WebCore::RenderLayerCompositor::setIsInWindow):
274         (WebCore::RenderLayerCompositor::willRemoveScrollingLayerWithBacking): No longer check the page cache state; now we
275         destroy the render tree of pages in the page cache, so we should never hit this code path.
276         (WebCore::RenderLayerCompositor::didAddScrollingLayer):
277         (WebCore::LegacyWebKitScrollingLayerCoordinator::registerAllViewportConstrainedLayers):
278         (WebCore::LegacyWebKitScrollingLayerCoordinator::unregisterAllViewportConstrainedLayers):
279         (WebCore::scrollbarHasDisplayNone):
280         (WebCore::LegacyWebKitScrollingLayerCoordinator::updateScrollingLayer):
281         (WebCore::LegacyWebKitScrollingLayerCoordinator::registerAllScrollingLayers):
282         (WebCore::LegacyWebKitScrollingLayerCoordinator::registerScrollingLayersNeedingUpdate):
283         (WebCore::LegacyWebKitScrollingLayerCoordinator::unregisterAllScrollingLayers):
284         (WebCore::LegacyWebKitScrollingLayerCoordinator::addScrollingLayer):
285         (WebCore::LegacyWebKitScrollingLayerCoordinator::removeScrollingLayer):
286         (WebCore::LegacyWebKitScrollingLayerCoordinator::didFlushChangesForLayer):
287         (WebCore::updateScrollingLayerWithClient): Deleted.
288         (WebCore::RenderLayerCompositor::registerAllViewportConstrainedLayers): Deleted.
289         (WebCore::RenderLayerCompositor::unregisterAllViewportConstrainedLayers): Deleted.
290         (WebCore::RenderLayerCompositor::registerAllScrollingLayers): Deleted.
291         (WebCore::RenderLayerCompositor::unregisterAllScrollingLayers): Deleted.
292         * rendering/RenderLayerCompositor.h:
293         (WebCore::LegacyWebKitScrollingLayerCoordinator::LegacyWebKitScrollingLayerCoordinator):
294         * workers/service/ServiceWorkerContainer.cpp:
295         (WebCore::ServiceWorkerContainer::~ServiceWorkerContainer):
296
297 2019-01-05  Zalan Bujtas  <zalan@apple.com>
298
299         [LFC] VerticalMargin should only have the used values.
300         https://bugs.webkit.org/show_bug.cgi?id=193168
301
302         Reviewed by Antti Koivisto.
303
304         Split VerticalMargin into ComputedVerticalMargin and UsedVerticalMargin.
305         ComputedVerticalMargin holds the computed (optional) values while UsedVerticalMargin holds both the
306         collapsed (optional) and the non-collapsed values.
307
308         * layout/FormattingContext.cpp:
309         (WebCore::Layout::FormattingContext::computeOutOfFlowVerticalGeometry const):
310         * layout/FormattingContext.h:
311         * layout/FormattingContextGeometry.cpp:
312         (WebCore::Layout::FormattingContext::Geometry::outOfFlowNonReplacedVerticalGeometry):
313         (WebCore::Layout::FormattingContext::Geometry::outOfFlowReplacedVerticalGeometry):
314         (WebCore::Layout::FormattingContext::Geometry::complicatedCases):
315         (WebCore::Layout::FormattingContext::Geometry::inlineReplacedHeightAndMargin):
316         (WebCore::Layout::FormattingContext::Geometry::inlineReplacedWidthAndMargin):
317         (WebCore::Layout::FormattingContext::Geometry::computedVerticalMargin):
318         (WebCore::Layout::FormattingContext::Geometry::computedNonCollapsedVerticalMarginValue): Deleted.
319         * layout/FormattingContextQuirks.cpp:
320         (WebCore::Layout::FormattingContext::Quirks::heightValueOfNearestContainingBlockWithFixedHeight):
321         * layout/LayoutUnits.h:
322         * layout/MarginTypes.h:
323         (WebCore::Layout::UsedVerticalMargin::before const):
324         (WebCore::Layout::UsedVerticalMargin::after const):
325         (WebCore::Layout::UsedVerticalMargin::nonCollapsedValues const):
326         (WebCore::Layout::UsedVerticalMargin::collapsedValues const):
327         (WebCore::Layout::UsedVerticalMargin::hasCollapsedValues const):
328         (WebCore::Layout::UsedVerticalMargin::setCollapsedValues):
329         (WebCore::Layout::UsedVerticalMargin::UsedVerticalMargin):
330         (WebCore::Layout::VerticalMargin::nonCollapsedValues const): Deleted.
331         (WebCore::Layout::VerticalMargin::collapsedValues const): Deleted.
332         (WebCore::Layout::VerticalMargin::setCollapsedValues): Deleted.
333         (WebCore::Layout::VerticalMargin::VerticalMargin): Deleted.
334         (WebCore::Layout::VerticalMargin::usedValues const): Deleted.
335         * layout/blockformatting/BlockFormattingContext.cpp:
336         (WebCore::Layout::BlockFormattingContext::computeHeightAndMargin const):
337         * layout/blockformatting/BlockFormattingContextGeometry.cpp:
338         (WebCore::Layout::BlockFormattingContext::Geometry::inFlowNonReplacedHeightAndMargin):
339         (WebCore::Layout::BlockFormattingContext::Geometry::inFlowHeightAndMargin):
340         * layout/blockformatting/BlockFormattingContextQuirks.cpp:
341         (WebCore::Layout::BlockFormattingContext::Quirks::stretchedHeight):
342         * layout/blockformatting/BlockMarginCollapse.cpp:
343         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::computedNonCollapsedMarginBefore):
344         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::computedNonCollapsedMarginAfter):
345         * layout/displaytree/DisplayBox.h:
346         (WebCore::Display::Box::setVerticalMargin):
347         (WebCore::Display::Box::verticalMargin const):
348         (WebCore::Display::Box::marginBefore const):
349         (WebCore::Display::Box::marginAfter const):
350         * layout/floats/FloatingContext.cpp:
351         (WebCore::Layout::FloatingContext::verticalPositionWithClearance const):
352         * layout/inlineformatting/InlineFormattingContext.cpp:
353         (WebCore::Layout::InlineFormattingContext::computeHeightAndMargin const):
354
355 2019-01-04  Daniel Bates  <dabates@apple.com>
356
357         REGRESSION (r238522): Erratic scrolling on Google flights search result page and vrbo.com
358         https://bugs.webkit.org/show_bug.cgi?id=192996
359         <rdar://problem/46573552>
360
361         Reviewed by Simon Fraser.
362
363         Only scroll a text field if its inner text size changes and it is the currently active and
364         focused element on the page.
365
366         Test: fast/scrolling/page-should-not-scroll-on-unfocused-text-field-layout.html
367
368         * rendering/RenderTextControlSingleLine.cpp:
369         (WebCore::RenderTextControlSingleLine::layout):
370
371 2019-01-04  Alex Christensen  <achristensen@webkit.org>
372
373         Progress towards fixing Mac CMake build
374         https://bugs.webkit.org/show_bug.cgi?id=193105
375
376         Reviewed by Don Olmstead.
377
378         * PlatformMac.cmake:
379         * Sources.txt:
380         * SourcesCocoa.txt:
381         * WebCore.xcodeproj/project.pbxproj:
382         * platform/graphics/gpu/GPURenderPassEncoder.h:
383
384 2019-01-04  Zalan Bujtas  <zalan@apple.com>
385
386         [iOS] ERROR: post-layout: dirty renderer(s) in WebCore::RenderTreeNeedsLayoutChecker::~RenderTreeNeedsLayoutChecker()
387         https://bugs.webkit.org/show_bug.cgi?id=189608
388         <rdar://problem/44473299>
389
390         Reviewed by Simon Fraser.
391
392         When a frameset/iframe is hidden and we skip layout, clear the dirty flag on its subtree as well.
393
394         Covered by fast/frames/invalid-frameset.html.
395
396         * rendering/RenderFrameSet.cpp:
397         (WebCore::clearSiblingSubtrees):
398         (WebCore::RenderFrameSet::positionFrames):
399         (WebCore::RenderFrameSet::positionFramesWithFlattening):
400
401 2019-01-04  Youenn Fablet  <youenn@apple.com>
402
403         [Fetch API] Implement abortable fetch
404         https://bugs.webkit.org/show_bug.cgi?id=174980
405         <rdar://problem/46861402>
406
407         Reviewed by Chris Dumez.
408
409         Add an AbortSignal to FetchRequest.
410
411         Add support for AbortSignal algorithm.
412         The fetch request signal is added an algorithm to abort the fetch.
413         Update clone algorithm to let signal of the cloned request be following the origin request.
414
415         Update ReadableStream error handling to return an exception instead of a string.
416         This allows passing an AbortError instead of a TypeError as previously done.
417
418         Update FetchBodyOwner to store a loading error either as an exception or as a resource error.
419         The latter is used for passing the error from service worker back to the page.
420         The former is used to pass it to ReadableStream or body accessors.
421
422         Covered by enabled tests.
423
424         * Modules/cache/DOMCache.cpp:
425         (WebCore::DOMCache::put):
426         * Modules/fetch/FetchBody.cpp:
427         (WebCore::FetchBody::consumeAsStream):
428         (WebCore::FetchBody::loadingFailed):
429         * Modules/fetch/FetchBody.h:
430         * Modules/fetch/FetchBodyConsumer.cpp:
431         (WebCore::FetchBodyConsumer::loadingFailed):
432         * Modules/fetch/FetchBodyConsumer.h:
433         * Modules/fetch/FetchBodyOwner.cpp:
434         (WebCore::FetchBodyOwner::arrayBuffer):
435         (WebCore::FetchBodyOwner::blob):
436         (WebCore::FetchBodyOwner::cloneBody):
437         (WebCore::FetchBodyOwner::formData):
438         (WebCore::FetchBodyOwner::json):
439         (WebCore::FetchBodyOwner::text):
440         (WebCore::FetchBodyOwner::loadBlob):
441         (WebCore::FetchBodyOwner::blobLoadingFailed):
442         (WebCore::FetchBodyOwner::consumeBodyAsStream):
443         (WebCore::FetchBodyOwner::setLoadingError):
444         * Modules/fetch/FetchBodyOwner.h:
445         (WebCore::FetchBodyOwner::loadingError const):
446         (WebCore::FetchBodyOwner::loadingException const):
447         * Modules/fetch/FetchBodySource.cpp:
448         (WebCore::FetchBodySource::error):
449         * Modules/fetch/FetchBodySource.h:
450         * Modules/fetch/FetchRequest.cpp:
451         (WebCore::FetchRequest::initializeWith):
452         (WebCore::FetchRequest::clone):
453         * Modules/fetch/FetchRequest.h:
454         (WebCore::FetchRequest::FetchRequest):
455         * Modules/fetch/FetchRequest.idl:
456         * Modules/fetch/FetchRequestInit.h:
457         (WebCore::FetchRequestInit::hasMembers const):
458         * Modules/fetch/FetchRequestInit.idl:
459         * Modules/fetch/FetchResponse.cpp:
460         (WebCore::FetchResponse::clone):
461         (WebCore::FetchResponse::fetch):
462         (WebCore::FetchResponse::BodyLoader::didFail):
463         * Modules/fetch/FetchResponse.h:
464         * bindings/js/ReadableStreamDefaultController.h:
465         (WebCore::ReadableStreamDefaultController::error):
466         * dom/AbortSignal.cpp:
467         (WebCore::AbortSignal::abort):
468         (WebCore::AbortSignal::follow):
469         * dom/AbortSignal.h:
470
471 2019-01-04  Brent Fulgham  <bfulgham@apple.com>
472
473         Parsed protocol of javascript URLs with embedded newlines and carriage returns do not match parsed protocol in Chrome and Firefox
474         https://bugs.webkit.org/show_bug.cgi?id=193155
475         <rdar://problem/40230982>
476
477         Reviewed by Chris Dumez.
478
479         Test: fast/loader/comment-only-javascript-url.html
480
481         Make a special case for URLs beginning with 'javascript:'. We should always
482         treat these as JS URLs, even if the content contained within the URL
483         string might match other parts of the URL parsing spec.
484
485         * html/URLUtils.h:
486         (WebCore::URLUtils<T>::protocol const):
487
488 2019-01-04  Jer Noble  <jer.noble@apple.com>
489
490         [WebKitLegacy] Media playback pauses on scroll
491         https://bugs.webkit.org/show_bug.cgi?id=192829
492
493         Reviewed by Eric Carlson.
494
495         New API tests:
496             WebKitLegacy.ScrollingDoesNotPauseMedia
497             WKWebView.StopAllMediaPlayback
498             WKWebView.SuspendResumeAllMediaPlayback
499
500         Do not use suspendActiveDOMObjects(ReasonForSuspension::PageWillBeSuspended) to pause
501         video. Roll back the changes to HTMLMediaElement, and introduce a new set of Page calls
502         suspendAllMediaPlayback() & resumeAllMediaPlayback() which replaces the removed bahavior.
503
504         * dom/Document.cpp:
505         (WebCore::Document::~Document):
506         (WebCore::Document::stopAllMediaPlayback):
507         (WebCore::Document::suspendAllMediaPlayback):
508         (WebCore::Document::resumeAllMediaPlayback):
509         * dom/Document.h:
510         * html/HTMLMediaElement.cpp:
511         (WebCore::HTMLMediaElement::HTMLMediaElement):
512         (WebCore::HTMLMediaElement::parseAttribute):
513         (WebCore::HTMLMediaElement::didFinishInsertingNode):
514         (WebCore::HTMLMediaElement::setSrcObject):
515         (WebCore::HTMLMediaElement::updateActiveTextTrackCues):
516         (WebCore::HTMLMediaElement::suspend):
517         (WebCore::HTMLMediaElement::resume):
518         (WebCore::HTMLMediaElement::webkitCurrentPlaybackTargetIsWireless const):
519         * html/HTMLMediaElement.h:
520         (WebCore::HTMLMediaElement::webkitCurrentPlaybackTargetIsWireless const): Deleted.
521         * html/MediaElementSession.cpp:
522         (WebCore::MediaElementSession::playbackPermitted const):
523         * page/Page.cpp:
524         (WebCore::Page::stopAllMediaPlayback):
525         (WebCore::Page::suspendAllMediaPlayback):
526         (WebCore::Page::resumeAllMediaPlayback):
527         * page/Page.h:
528         (WebCore::Page::mediaPlaybackIsSuspended):
529         * platform/audio/PlatformMediaSession.h:
530         * platform/audio/PlatformMediaSessionManager.cpp:
531         (WebCore::PlatformMediaSessionManager::suspendAllMediaPlaybackForDocument):
532         (WebCore::PlatformMediaSessionManager::resumeAllMediaPlaybackForDocument):
533         * platform/audio/PlatformMediaSessionManager.h:
534
535 2019-01-04  Chris Dumez  <cdumez@apple.com>
536
537         Add support for toggling device orientation API support per site
538         https://bugs.webkit.org/show_bug.cgi?id=193143
539         <rdar://problem/46605724>
540
541         Reviewed by Alex Christensen.
542
543         Add support for toggling device orientation API support per site via _WKWebsitePolicies.
544
545         * dom/Document.cpp:
546         (WebCore::Document::simulateDeviceOrientationChange):
547         * dom/Document.h:
548         * loader/DocumentLoader.h:
549         (WebCore::DocumentLoader::deviceOrientationEventEnabled const):
550         (WebCore::DocumentLoader::setDeviceOrientationEventEnabled):
551         * page/DOMWindow.cpp:
552         (WebCore::DOMWindow::addEventListener):
553
554 2019-01-04  Jer Noble  <jer.noble@apple.com>
555
556         Web Content process main thread blocked beneath ImageDecoderAVFObjC::readSamples for many seconds on imgur.com
557         https://bugs.webkit.org/show_bug.cgi?id=191806
558         <rdar://problem/46151477>
559
560         Reviewed by Dean Jackson.
561
562         Test: http/tests/images/mp4-partial-load.html
563
564         Rather than use an AVAssetReaderTrackOutput, which will load both sample metadata and sample data
565         synchronously when a sample is requested, use AVAssetReaderSampleReferenceOutput, which only loads
566         sample metadata, including the byte offset and byte length of the sample data. By waiting until the
567         AVAsset signals that it's own metadata is loaded, we can safely parse all the sample metadata without
568         blocking on network loads. Once enough data is loaded, we can replace the byte reference and offset
569         attachements in the sample with actual data, and mark the sample as "complete".
570
571         Because the existing ImageSource assumes that image data parsing will occur synchronously, and that
572         synchronous parsing could cause a hang if the metadata is not loaded, add a new callback method which
573         allows the ImageSource to be notified when the encodedDataStatus changes. The ImageSource notifies the
574         CacheImage, which notifies the RenderImage, and thus the asynchronous parsing will kick off the
575         renderer's animation loop.
576
577         * loader/cache/CachedImage.cpp:
578         (WebCore::CachedImage::CachedImageObserver::encodedDataStatusChanged):
579         (WebCore::CachedImage::encodedDataStatusChanged):
580         * loader/cache/CachedImage.h:
581         * platform/graphics/ImageDecoder.h:
582         (WebCore::ImageDecoder::setEncodedDataStatusChangeCallback):
583         * platform/graphics/ImageObserver.h:
584         (WebCore::ImageObserver::encodedDataStatusChanged):
585         * platform/graphics/ImageSource.cpp:
586         (WebCore::ImageSource::ensureDecoderAvailable):
587         (WebCore::ImageSource::encodedDataStatusChanged):
588         (WebCore::ImageSource::frameDecodingStatusAtIndex):
589         * platform/graphics/ImageSource.h:
590         * platform/graphics/avfoundation/objc/ImageDecoderAVFObjC.h:
591         * platform/graphics/avfoundation/objc/ImageDecoderAVFObjC.mm:
592         (-[WebCoreSharedBufferResourceLoaderDelegate data]):
593         (WebCore::ImageDecoderAVFObjCSample::byteRange const):
594         (WebCore::ImageDecoderAVFObjC::readSamples):
595         (WebCore::ImageDecoderAVFObjC::setEncodedDataStatusChangeCallback):
596         (WebCore::ImageDecoderAVFObjC::encodedDataStatus const):
597         (WebCore::ImageDecoderAVFObjC::frameIsCompleteAtIndex const):
598         (WebCore::ImageDecoderAVFObjC::createFrameImageAtIndex):
599         (WebCore::ImageDecoderAVFObjC::sampleIsComplete const):
600
601 2019-01-04  Youenn Fablet  <youenn@apple.com>
602
603         CSP violation reports should bypass CSP checks
604         https://bugs.webkit.org/show_bug.cgi?id=192857
605         <rdar://problem/46887236>
606
607         Reviewed by Chris Dumez.
608
609         For ping loads, pass the option to do CSP checks from PingLoader to LoaderStrategy.
610         This new option is unused by WebKit Legacy.
611         It is used by WebKit loader strategy to only send any CSP response header to network process
612         in case CSP checks should be done.
613
614         This option is used to disable CSP checks for Ping Loads that report CSP violations.
615
616         Test: http/wpt/fetch/csp-reports-bypass-csp-checks.html
617
618         * loader/LoaderStrategy.h:
619         * loader/PingLoader.cpp:
620         (WebCore::PingLoader::loadImage):
621         (WebCore::PingLoader::sendPing):
622         (WebCore::PingLoader::sendViolationReport):
623         (WebCore::PingLoader::startPingLoad):
624         * loader/PingLoader.h:
625         * loader/cache/CachedResource.cpp:
626         (WebCore::CachedResource::load):
627
628 2019-01-04  Wenson Hsieh  <wenson_hsieh@apple.com>
629
630         [Cocoa] Merge WebEditCommandProxy::nameForEditAction and undoNameForEditAction into a single function
631         https://bugs.webkit.org/show_bug.cgi?id=193129
632
633         Reviewed by Tim Horton.
634
635         Adds a new helper function that returns the undo/redo name for a given EditAction. No change in behavior.
636
637         * Sources.txt:
638         * WebCore.xcodeproj/project.pbxproj:
639         * editing/EditAction.cpp: Copied from Source/WebKit/UIProcess/WebEditCommandProxy.cpp.
640         (WebCore::nameForUndoRedo):
641         * editing/EditAction.h:
642         * editing/Editor.cpp:
643
644 2019-01-03  Matt Rajca  <mrajca@apple.com>
645
646         Make DidPlayMediaPreventedFromPlaying autoplay event more generic.
647         https://bugs.webkit.org/show_bug.cgi?id=193128
648         rdar://34554231
649
650         Reviewed by Jer Noble.
651
652         Today, the "DidPlayMediaPreventedFromPlaying" autoplay event is only sent for
653         media prevented from autoplaying. It could be generalized to a "DidPlayMediaWithUserGesture"
654         event along with a flag that indicates whether or not autoplay was actually prevented.
655         Moreover, we can include a flag that indicates whether the media element in question
656         is main content. Clients will then know in more cases when media was played with a user
657         gesture, whether or not it has audio, as well as its main content status. While the main
658         content heuristics may not be perfect, they covered the top 20 video-centric websites that
659         this was tested with and are meant to be used by clients for data evaluation purposes.
660
661         As part of this, the PlaybackWithoutUserGesture enum was renamed to AutoplayEventPlaybackState
662         since it now also applies to cases where there is a user gesture. The
663         `m_playbackWithoutUserGestureStartedTime` member variable was also removed in favor of
664         `playbackStartedTime` which also covers all the cases we care about.
665
666         Tests: existing API tests were updated to reflect the new names. New API tests
667         were added for the new case in which the "DidPlayMediaWithUserGesture" event is sent.
668
669         * html/HTMLMediaElement.cpp:
670         (WebCore::convertEnumerationToString): Update to new enum cases.
671         (WebCore::HTMLMediaElement::setReadyState): Ditto.
672         (WebCore::HTMLMediaElement::play): Ditto.
673         (WebCore::HTMLMediaElement::playInternal): Also cover the case where
674          playback was not prevented but there was a user gesture.
675         (WebCore::HTMLMediaElement::pauseInternal): Use new name.
676         (WebCore::HTMLMediaElement::setVolume): Use new name.
677         (WebCore::HTMLMediaElement::playbackProgressTimerFired): Dispatch the
678          DidPlayMediaWithUserGesture event when playback was started with a user
679          gesture as well.
680         (WebCore::HTMLMediaElement::mediaPlayerDidAddAudioTrack): Use new name.
681         (WebCore::HTMLMediaElement::mediaPlayerTimeChanged): Ditto.
682         (WebCore::HTMLMediaElement::mediaPlayerCharacteristicChanged): Ditto.
683         (WebCore::HTMLMediaElement::stopWithoutDestroyingMediaPlayer): Ditto.
684         (WebCore::HTMLMediaElement::handleAutoplayEvent): Pass along new media state.
685         (WebCore::HTMLMediaElement::userDidInterfereWithAutoplay): Use new name.
686         (WebCore::HTMLMediaElement::setAutoplayEventPlaybackState): Stop setting
687          m_playbackWithoutUserGestureStartedTime in favor of using playbackStartedTime.
688         (WebCore::HTMLMediaElement::updateShouldPlay): Use new name.
689         (WebCore::HTMLMediaElement::setPlaybackWithoutUserGesture): Renamed.
690         * html/HTMLMediaElement.h:
691         (WTF::LogArgument<WebCore::HTMLMediaElement::AutoplayEventPlaybackState>::toString): Renamed from...
692         (WTF::LogArgument<WebCore::HTMLMediaElement::PlaybackWithoutUserGesture>::toString):
693         * html/MediaElementSession.cpp:
694         (WebCore::MediaElementSession::isMainContentForPurposesOfAutoplayEvents const): Don't
695          do the hit testing check for the purposes of autoplay events. It seems to fail on the
696          basic Vimeo player due to overlapping divs.
697         (WebCore::isElementMainContentForPurposesOfAutoplay):
698         (WebCore::MediaElementSession::updateIsMainContent const): Keep the existing behavior
699          here of hit testing.
700         (WebCore::isMainContentForPurposesOfAutoplay): Renamed.
701         * html/MediaElementSession.h:
702         * page/AutoplayEvent.h:
703
704 2019-01-04  Youenn Fablet  <youenn@apple.com>
705
706         Crash in WebCore::ServiceWorkerGlobalScope
707         https://bugs.webkit.org/show_bug.cgi?id=192513
708         <rdar://problem/46563880>
709
710         Reviewed by Alex Christensen.
711
712         Store the identifier in its own variable to make sure we do not use workerThread after being moved.
713
714         * workers/service/ServiceWorkerGlobalScope.cpp:
715         (WebCore::ServiceWorkerGlobalScope::skipWaiting):
716
717 2019-01-04  Chris Fleizach  <cfleizach@apple.com>
718
719         AX: String check: "Rule" does not reflect the meaning of the <hr> html tag
720         https://bugs.webkit.org/show_bug.cgi?id=193041
721         <rdar://problem/46954090>
722
723         Reviewed by Zalan Bujtas.
724
725         * en.lproj/Localizable.strings:
726         * platform/cocoa/LocalizedStringsCocoa.mm:
727         (WebCore::AXHorizontalRuleDescriptionText):
728
729 2019-01-04  Zalan Bujtas  <zalan@apple.com>
730
731         [LFC] ComputedHorizontalMargin should have optional members
732         https://bugs.webkit.org/show_bug.cgi?id=193131
733
734         Reviewed by Antti Koivisto.
735
736         Split HorizontalMargin into UsedHorizontalMargin and ComputedHorizontalMargin. ComputedHorizontalMargin's members are optional.
737         (see computed vs used values)
738
739         * layout/FormattingContext.h:
740         * layout/FormattingContextGeometry.cpp:
741         (WebCore::Layout::FormattingContext::Geometry::outOfFlowNonReplacedHorizontalGeometry):
742         (WebCore::Layout::FormattingContext::Geometry::outOfFlowReplacedHorizontalGeometry):
743         (WebCore::Layout::FormattingContext::Geometry::floatingNonReplacedWidthAndMargin):
744         (WebCore::Layout::FormattingContext::Geometry::floatingReplacedWidthAndMargin):
745         (WebCore::Layout::FormattingContext::Geometry::inlineReplacedWidthAndMargin):
746         (WebCore::Layout::FormattingContext::Geometry::computedHorizontalMargin):
747         (WebCore::Layout::FormattingContext::Geometry::computedNonCollapsedHorizontalMarginValue): Deleted.
748         * layout/LayoutUnits.h:
749         * layout/MarginTypes.h:
750         * layout/Verification.cpp:
751         (WebCore::Layout::outputMismatchingBlockBoxInformationIfNeeded):
752         * layout/blockformatting/BlockFormattingContextGeometry.cpp:
753         (WebCore::Layout::BlockFormattingContext::Geometry::inFlowNonReplacedWidthAndMargin):
754         * layout/displaytree/DisplayBox.h:
755         (WebCore::Display::Box::setHorizontalMargin):
756         (WebCore::Display::Box::setHorizontalComputedMargin):
757         (WebCore::Display::Box::computedMarginStart const):
758         (WebCore::Display::Box::computedMarginEnd const):
759         * layout/floats/FloatAvoider.h:
760         (WebCore::Layout::FloatAvoider::marginStart const):
761         (WebCore::Layout::FloatAvoider::marginEnd const):
762         * layout/inlineformatting/InlineFormattingContext.cpp:
763         (WebCore::Layout::InlineFormattingContext::collectInlineContentForSubtree const):
764         * layout/inlineformatting/InlineFormattingContextGeometry.cpp:
765         (WebCore::Layout::InlineFormattingContext::Geometry::inlineBlockWidthAndMargin):
766
767 2019-01-04  Zalan Bujtas  <zalan@apple.com>
768
769         [LFC][BFC] Use computedValue and usedValue consistently
770         https://bugs.webkit.org/show_bug.cgi?id=193059
771
772         Reviewed by Antti Koivisto.
773
774         https://www.w3.org/TR/CSS22/cascade.html#value-stages
775
776         6.1.2 Computed values
777         Specified values are resolved to computed values during the cascade; for example URIs are made absolute and 'em' and 'ex' units
778         are computed to pixel or absolute lengths. Computing a value never requires the user agent to render the document...
779
780         6.1.3 Used values
781         Computed values are processed as far as possible without formatting the document. Some values, however, can only be determined when the document
782         is being laid out. For example, if the width of an element is set to be a certain percentage of its containing block, the width cannot be determined
783         until the width of the containing block has been determined. The used value is the result of taking the computed value and resolving any remaining
784         dependencies into an absolute value.
785
786         * layout/FormattingContext.cpp:
787         (WebCore::Layout::FormattingContext::computeOutOfFlowHorizontalGeometry const):
788         * layout/FormattingContextGeometry.cpp:
789         (WebCore::Layout::FormattingContext::Geometry::outOfFlowNonReplacedHorizontalGeometry):
790         (WebCore::Layout::FormattingContext::Geometry::outOfFlowReplacedVerticalGeometry):
791         (WebCore::Layout::FormattingContext::Geometry::outOfFlowReplacedHorizontalGeometry):
792         (WebCore::Layout::FormattingContext::Geometry::complicatedCases):
793         (WebCore::Layout::FormattingContext::Geometry::inlineReplacedWidthAndMargin):
794         * layout/LayoutState.cpp:
795         (WebCore::Layout::LayoutState::LayoutState):
796         * layout/LayoutUnits.h:
797         * layout/Verification.cpp:
798         (WebCore::Layout::outputMismatchingBlockBoxInformationIfNeeded):
799         * layout/blockformatting/BlockFormattingContext.cpp:
800         (WebCore::Layout::BlockFormattingContext::computeWidthAndMargin const):
801         * layout/blockformatting/BlockFormattingContextGeometry.cpp:
802         (WebCore::Layout::BlockFormattingContext::Geometry::inFlowNonReplacedWidthAndMargin):
803         (WebCore::Layout::BlockFormattingContext::Geometry::inFlowReplacedWidthAndMargin):
804         * layout/displaytree/DisplayBox.cpp:
805         (WebCore::Display::Box::Box):
806         * layout/displaytree/DisplayBox.h:
807         (WebCore::Display::Box::setHasValidHorizontalComputedMargin):
808         (WebCore::Display::Box::setHorizontalComputedMargin):
809         (WebCore::Display::Box::computedMarginStart const):
810         (WebCore::Display::Box::computedMarginEnd const):
811         (WebCore::Display::Box::setHasValidHorizontalNonComputedMargin): Deleted.
812         (WebCore::Display::Box::setHorizontalNonComputedMargin): Deleted.
813         (WebCore::Display::Box::nonComputedMarginStart const): Deleted.
814         (WebCore::Display::Box::nonComputedMarginEnd const): Deleted.
815         * layout/floats/FloatAvoider.h:
816         (WebCore::Layout::FloatAvoider::marginStart const):
817         (WebCore::Layout::FloatAvoider::marginEnd const):
818         * layout/inlineformatting/InlineFormattingContext.cpp:
819         (WebCore::Layout::InlineFormattingContext::computeWidthAndMargin const):
820
821 2019-01-03  Zalan Bujtas  <zalan@apple.com>
822
823         REGRESSION: -webkit-appearance test case crashes
824         https://bugs.webkit.org/show_bug.cgi?id=189302
825         <rdar://problem/44143049>
826
827         Reviewed by Wenson Hsieh.
828
829         The painting and the layout positions of the cancel button need to match in order to be able to interact with it.
830         This patch removes the previous position inlining attempts.
831
832         Test: fast/forms/webkit-appearance-searchfield-cancel-button-crash.html
833
834         * rendering/RenderThemeMac.mm:
835         (WebCore::RenderThemeMac::paintSearchFieldCancelButton):
836
837 2019-01-03  David Kilzer  <ddkilzer@apple.com>
838
839         Leak of WebCore::LibWebRTCCertificateGenerator::RTCCertificateGeneratorCallback (48 bytes) in com.apple.WebKit.WebContent running WebKit layout tests
840         <https://webkit.org/b/193122>
841         <rdar://problem/47022987>
842
843         Reviewed by Youenn Fablet.
844
845         * Modules/mediastream/libwebrtc/LibWebRTCCertificateGenerator.cpp:
846         (WebCore::LibWebRTCCertificateGenerator::RTCCertificateGeneratorCallback::AddRef const):
847         (WebCore::LibWebRTCCertificateGenerator::RTCCertificateGeneratorCallback::Release const):
848         - Remove `final` keyword so that
849           `new rtc::RefCountedObject<RTCCertificateGeneratorCallback>()`
850           can be called.
851         (WebCore::LibWebRTCCertificateGenerator::generateCertificate):
852         - To fix the leak call
853           `new rtc::RefCountedObject<RTCCertificateGeneratorCallback>()`
854           to create the object.
855
856 2019-01-03  Simon Fraser  <simon.fraser@apple.com>
857
858         REGRESSION (r238090): After showing the Find banner or tab bar, hit tests are vertically offset (or painting is not offset)
859         https://bugs.webkit.org/show_bug.cgi?id=193124
860         rdar://problem/46755409
861
862         Reviewed by Tim Horton.
863
864         Top content inset feeds into scrolling tree geometry, so when it changes we need to trigger
865         an update of the root scrolling node, which happens via RenderLayerBacking::updateGeometry().
866         So set a dirty bit on the root layer in frameViewDidChangeSize(), which is called from the code
867         path that runs when top content inset changes.
868
869         Find banner behavior is not easily testable. platform/mac/fast/events/content-inset-hit-testing.html did not detect the regression.
870
871         * rendering/RenderLayerCompositor.cpp:
872         (WebCore::RenderLayerCompositor::frameViewDidChangeSize):
873
874 2019-01-03  Chris Dumez  <cdumez@apple.com>
875
876         Potential infinite recursion in isFrameFamiliarWith(Frame&, Frame&)
877         https://bugs.webkit.org/show_bug.cgi?id=192997
878         <rdar://problem/46217271>
879
880         Reviewed by Antti Koivisto.
881
882         isFrameFamiliarWith(Frame&, Frame&) was called recursively using the passed frames' openers.
883         The issue is that a Frame can be its opener. There could also be a cycle in the opener chain.
884
885         To address the issue, simplify isFrameFamiliarWith() so that it is no longer recursive. We now
886         only check if the frames belong to the same pages or if their openers do. We no longer check
887         openers' opener and up.
888
889         Note that this function is used to check if a frame is allowed to target another. In practice,
890         it is unlikely to be useful to navigate an opener's opener and an openee's openee.
891
892         Tests: fast/dom/Window/window-open-opener-cycle.html
893                fast/dom/Window/window-open-self-as-opener.html
894
895         * page/FrameTree.cpp:
896         (WebCore::isFrameFamiliarWith):
897
898 2019-01-02  Simon Fraser  <simon.fraser@apple.com>
899
900         REGRESSION (r239306): Don't disable font smoothing in transparent layers on macOS Mojave and later
901         https://bugs.webkit.org/show_bug.cgi?id=193095
902         <rdar://problem/47014944>
903
904         Reviewed by Zalan Bujtas.
905         
906         In r239306 we stopped making CALayers for font-smoothed text when not necessary on macOS Mojave
907         and later. However, we still turned off smoothing for non-opaque layers (setShouldSmoothFonts(false)),
908         which continues to affect the appearance of text.
909         
910         Fix by only calling setShouldSmoothFonts(false) when the OS supports font smoothing.
911
912         Test: compositing/contents-format/subpixel-antialiased-text.html
913
914         * platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm:
915         (WebCore::PlatformCALayer::drawLayerContents):
916
917 2019-01-02  David Kilzer  <ddkilzer@apple.com>
918
919         Leak of CMSampleBuffer (752 bytes) in com.apple.WebKit.WebContent running WebKit layout tests
920         <https://webkit.org/b/193016>
921         <rdar://problem/46925703>
922
923         Reviewed by Simon Fraser.
924
925         * platform/mediarecorder/cocoa/MediaRecorderPrivateWriterCocoa.mm:
926         (WebCore::copySampleBufferWithCurrentTimeStamp):
927         - Change to return RetainPtr<CMSampleBufferRef>.
928         - Check return value of CMSampleBufferCreateCopyWithNewTiming().
929         (WebCore::MediaRecorderPrivateWriter::appendVideoSampleBuffer):
930         - Check return value of copySampleBufferWithCurrentTimeStamp().
931         - Fix leak by using RetainPtr<CMSampleBufferRef> returned from
932           copySampleBufferWithCurrentTimeStamp() instead of leaking
933           `bufferWithCurrentTime` by using retainPtr().
934         (WebCore::createAudioFormatDescription):
935         - Extract method from appendAudioSampleBuffer() to return
936           RetainPtr<CMFormatDescriptionRef> after calling
937           CMAudioFormatDescriptionCreate().
938         - Check return value of CMAudioFormatDescriptionCreate().
939         (WebCore::createAudioSampleBufferWithPacketDescriptions):
940         - Extract method from appendAudioSampleBuffer() to return
941           RetainPtr<CMSampleBufferRef> after calling
942           CMAudioSampleBufferCreateWithPacketDescriptions().
943         (WebCore::MediaRecorderPrivateWriter::appendAudioSampleBuffer):
944         - Check return values of createAudioFormatDescription() and
945           createAudioSampleBufferWithPacketDescriptions().
946         - Fix leaks by extracting code into helper methods that return
947           RetainPtr<> objects instead of leaking CMFormatDescriptionRef
948           directly or leaking `sampleBuffer` by using retainPtr().
949
950 2019-01-02  Wenson Hsieh  <wenson_hsieh@apple.com>
951
952         Add support for using the current text selection as the find string on iOS
953         https://bugs.webkit.org/show_bug.cgi?id=193034
954         <rdar://problem/45138739>
955
956         Reviewed by Tim Horton.
957
958         Add support for "TakeFindStringFromSelection" on iOS. Unlike macOS, iOS does not have a notion of a "find
959         pasteboard" like macOS; instead, we handle this editing command by sending the selection string to the UI
960         process, where it is exposed via WebKit SPI so that clients that present find-in-page UI (i.e. MobileSafari) are
961         able to trigger find-in-page with this string.
962
963         Test: WebKit.UseSelectionAsFindString
964
965         * editing/Editor.cpp:
966         (WebCore::Editor::canCopyExcludingStandaloneImages const):
967
968         Make this helper function cross-platform.
969
970         * editing/Editor.h:
971         * editing/EditorCommand.cpp:
972         (WebCore::createCommandMap):
973         * editing/cocoa/EditorCocoa.mm:
974         (WebCore::Editor::takeFindStringFromSelection):
975
976         Move this from EditorMac to EditorCocoa, and implement it on iOS by calling into the editor client to update the
977         find string (see WebKit/ChangeLog for more details).
978
979         * editing/mac/EditorMac.mm:
980         (WebCore::Editor::canCopyExcludingStandaloneImages): Deleted.
981         (WebCore::Editor::takeFindStringFromSelection): Deleted.
982         * loader/EmptyClients.cpp:
983         * page/EditorClient.h:
984
985         Add a new editor client method to send the string for find-in-page to the UI process.
986
987 2019-01-02  Devin Rousso  <webkit@devinrousso.com>
988
989         Web Inspector: Implement `queryObjects` Command Line API
990         https://bugs.webkit.org/show_bug.cgi?id=176766
991         <rdar://problem/34890689>
992
993         Reviewed by Joseph Pecoraro.
994
995         Test: inspector/console/queryObjects.html
996
997         * inspector/CommandLineAPIModuleSource.js:
998         (CommandLineAPI):
999         (CommandLineAPIImpl.prototype.queryObjects): Added.
1000
1001 2019-01-02  Charles Vazac  <cvazac@gmail.com>
1002
1003         Fix resourcetimingbufferfull bubbles attribute
1004         https://bugs.webkit.org/show_bug.cgi?id=193087
1005
1006         Reviewed by Chris Dumez.
1007
1008         This change is covered by web-platform-tests [1].
1009
1010         [1] https://github.com/web-platform-tests/wpt/blob/master/resource-timing/buffer-full-when-populate-entries.html#L20
1011
1012         * page/Performance.cpp:
1013         (WebCore::Performance::resourceTimingBufferFullTimerFired):
1014
1015 2019-01-02  Simon Fraser  <simon.fraser@apple.com>
1016
1017         Rename LayerScrollCoordinationRole to ScrollCoordinationRole and make an enum class
1018         https://bugs.webkit.org/show_bug.cgi?id=193010
1019
1020         Reviewed by Zalan Bujtas.
1021
1022         Move the enum LayerScrollCoordinationRole from RenderLayer.h to RenderLayerCompositor.h,
1023         and make it an enum class.
1024
1025         * page/FrameView.cpp:
1026         (WebCore::FrameView::scrollLayerID const):
1027         * rendering/RenderLayer.h:
1028         * rendering/RenderLayerBacking.cpp:
1029         (WebCore::RenderLayerBacking::~RenderLayerBacking):
1030         (WebCore::RenderLayerBacking::detachFromScrollingCoordinator):
1031         (WebCore::operator<<):
1032         * rendering/RenderLayerBacking.h:
1033         * rendering/RenderLayerCompositor.cpp:
1034         (WebCore::RenderLayerCompositor::updateScrollCoordinatedStatus):
1035         (WebCore::RenderLayerCompositor::removeFromScrollCoordinatedLayers):
1036         (WebCore::scrollCoordinationRoleForNodeType):
1037         (WebCore::RenderLayerCompositor::attachScrollingNode):
1038         (WebCore::RenderLayerCompositor::detachScrollCoordinatedLayer):
1039         (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
1040         (WebCore::RenderLayerCompositor::willRemoveScrollingLayerWithBacking):
1041         * rendering/RenderLayerCompositor.h:
1042
1043 2019-01-02  Simon Fraser  <simon.fraser@apple.com>
1044
1045         Don't spin up a CalcParser if the current token is not a function token
1046         https://bugs.webkit.org/show_bug.cgi?id=193067
1047
1048         Reviewed by Zalan Bujtas.
1049
1050         Various functions in CSSPropertyParserHelpers fall back to trying to parse
1051         a calc expression if the normal parsing fails. Don't do this unless the
1052         current token is a function token, which should be slightly more efficient.
1053
1054         * css/parser/CSSPropertyParserHelpers.cpp:
1055         (WebCore::CSSPropertyParserHelpers::consumeInteger):
1056         (WebCore::CSSPropertyParserHelpers::consumePositiveIntegerRaw):
1057         (WebCore::CSSPropertyParserHelpers::consumeNumberRaw):
1058         (WebCore::CSSPropertyParserHelpers::consumeNumber):
1059         (WebCore::CSSPropertyParserHelpers::consumeFontWeightNumber):
1060         (WebCore::CSSPropertyParserHelpers::consumeLength):
1061         (WebCore::CSSPropertyParserHelpers::consumePercent):
1062         (WebCore::CSSPropertyParserHelpers::consumeLengthOrPercent):
1063         (WebCore::CSSPropertyParserHelpers::consumeAngle):
1064         (WebCore::CSSPropertyParserHelpers::consumeAngleOrPercent):
1065         (WebCore::CSSPropertyParserHelpers::consumeTime):
1066
1067 2019-01-02  Simon Fraser  <simon.fraser@apple.com>
1068
1069         Support css-color-4 rgb functions
1070         https://bugs.webkit.org/show_bug.cgi?id=192321
1071
1072         Reviewed by Zalan Bujtas.
1073         
1074         Support the new rgb()/rgba() syntax described in https://drafts.csswg.org/css-color/#rgb-functions.
1075         The differences are:
1076         1. There is a new comma-free syntax, where the optional alpha is separated by a slash:
1077             rgb(128 34 56)
1078             rgb(128 34 56 / 50%)
1079         2. Floating point values are allowed, and rounded:
1080             rgb(128.5 34.2 56.5) becomes rgb(129 34 57)
1081         3. rgba() is a pure alias for rgb(), so these are equivalent:
1082             rgb(128 34 56 / 50%)
1083             rgba(128 34 56 / 50%)
1084             
1085         hsl()/hsla() parsing was already updated to this new syntax in r230861.
1086
1087         Tested by tests in imported/w3c/web-platform-tests/css/css-color/
1088
1089         * css/parser/CSSPropertyParserHelpers.cpp:
1090         (WebCore::CSSPropertyParserHelpers::clampRGBComponent):
1091         (WebCore::CSSPropertyParserHelpers::parseRGBParameters):
1092         (WebCore::CSSPropertyParserHelpers::parseColorFunction):
1093
1094 2019-01-02  Simon Fraser  <simon.fraser@apple.com>
1095
1096         Handle calc() expressions in gradient color stops
1097         https://bugs.webkit.org/show_bug.cgi?id=193066
1098         rdar://problem/46961985
1099
1100         Reviewed by Sam Weinig.
1101         
1102         Fix two issues that prevented calc() expressions from working in conic-gradient color stops,
1103         for the angle or percent value. First, consumeAngleOrPercent() needs to look for CalculationCategory::Percent
1104         calc values as well as angle ones.
1105
1106         Second, CSSPrimitiveValue::isAngle() needs to use primitiveType() (which takes calc into account),
1107         just as isPx() etc do.
1108
1109         Test: fast/gradients/conic-calc-stop-position.html
1110
1111         * css/CSSPrimitiveValue.h:
1112         (WebCore::CSSPrimitiveValue::isAngle const):
1113         * css/parser/CSSPropertyParserHelpers.cpp:
1114         (WebCore::CSSPropertyParserHelpers::consumeAngleOrPercent):
1115         (WebCore::CSSPropertyParserHelpers::consumeGradientColorStops):
1116
1117 2018-12-31  Keith Miller  <keith_miller@apple.com>
1118
1119         SourceProviders should use an actual URL instead of a string
1120         https://bugs.webkit.org/show_bug.cgi?id=192734
1121
1122         Reviewed by Yusuke Suzuki.
1123
1124         Remove ScriptSourceCode's URL member and make the url() method
1125         reference the URL on the SourceProvider. Also, avoid some
1126         ref count churn.
1127
1128         Additionally, this patch fixes an existing bug in
1129         WorkletGlobalScope() that would use a ScriptSourceCode after
1130         WTFMoving it.
1131
1132         * bindings/js/CachedScriptSourceProvider.h:
1133         (WebCore::CachedScriptSourceProvider::CachedScriptSourceProvider):
1134         * bindings/js/ScheduledAction.cpp:
1135         (WebCore::ScheduledAction::execute):
1136         * bindings/js/ScriptController.cpp:
1137         (WebCore::ScriptController::executeScriptInWorld):
1138         (WebCore::ScriptController::executeScript):
1139         * bindings/js/ScriptSourceCode.h:
1140         (WebCore::ScriptSourceCode::ScriptSourceCode):
1141         (WebCore::ScriptSourceCode::m_code):
1142         (WebCore::ScriptSourceCode::url const):
1143         (WebCore::ScriptSourceCode::m_url): Deleted.
1144         * dom/ScriptElement.cpp:
1145         (WebCore::ScriptElement::prepareScript):
1146         (WebCore::ScriptElement::requestModuleScript):
1147         (WebCore::ScriptElement::executePendingScript):
1148         * html/HTMLMediaElement.cpp:
1149         (WebCore::HTMLMediaElement::ensureMediaControlsInjectedScript):
1150         * page/Frame.cpp:
1151         (WebCore::Frame::injectUserScriptImmediately):
1152         * workers/WorkerGlobalScope.cpp:
1153         (WebCore::WorkerGlobalScope::importScripts):
1154         * workers/WorkerThread.cpp:
1155         (WebCore::WorkerThread::workerThread):
1156         * worklets/WorkletGlobalScope.cpp:
1157         (WebCore::WorkletGlobalScope::WorkletGlobalScope):
1158         * xml/parser/XMLDocumentParserLibxml2.cpp:
1159         (WebCore::XMLDocumentParser::endElementNs):
1160
1161 2019-01-01  Jeff Miller  <jeffm@apple.com>
1162
1163         Update user-visible copyright strings to include 2019
1164         https://bugs.webkit.org/show_bug.cgi?id=192811
1165
1166         Reviewed by Mark Lam.
1167
1168         * Info.plist:
1169
1170 2018-12-30  David Kilzer  <ddkilzer@apple.com>
1171
1172         clang-tidy: Save 8 padding bytes on WebCore::BorderEdge
1173         <https://webkit.org/b/193058>
1174         <rdar://problem/46979275>
1175
1176         Reviewed by Yusuke Suzuki.
1177
1178         * rendering/BorderEdge.cpp:
1179         (WebCore::BorderEdge::BorderEdge): Reorder initialization to
1180         match new instance variable order.
1181         * rendering/BorderEdge.h: Reorder instance variables to save
1182         8 padding bytes.
1183
1184 2018-12-28  Yusuke Suzuki  <yusukesuzuki@slowstart.org>
1185
1186         [JSC] Remove one indirection in JSObject::toStringName
1187         https://bugs.webkit.org/show_bug.cgi?id=193037
1188
1189         Reviewed by Keith Miller.
1190
1191         Use old JSObject::toStringName function here.
1192
1193         * bindings/js/JSDOMConstructorBase.cpp:
1194         (WebCore::JSDOMConstructorBase::className):
1195         (WebCore::JSDOMConstructorBase::toStringName):
1196         * bindings/js/JSDOMConstructorBase.h:
1197         (WebCore::JSDOMConstructorBase::className): Deleted.
1198
1199 2018-12-27  Alex Christensen  <achristensen@webkit.org>
1200
1201         Resurrect Mac CMake build
1202         https://bugs.webkit.org/show_bug.cgi?id=192658
1203
1204         Reviewed by Yusuke Suzuki.
1205
1206         This makes it so JSC and most of WebCore builds.
1207         WebCore's use of ARC seems inconsistent, so I'll fix that later.
1208
1209         * PlatformMac.cmake:
1210         * config.h:
1211
1212 2018-12-26  Jim Mason  <jmason@ibinx.com>
1213
1214         [FreeType] Restore conditional compilation logic for recent HarfBuzz refactoring
1215         https://bugs.webkit.org/show_bug.cgi?id=193036
1216
1217         Reviewed by Michael Catanzaro.
1218
1219         * platform/graphics/FontPlatformData.h:
1220         * platform/graphics/freetype/FontPlatformDataFreeType.cpp:
1221
1222 2018-12-24  Fujii Hironori  <Hironori.Fujii@sony.com>
1223
1224         Remove "using namespace std;"
1225         https://bugs.webkit.org/show_bug.cgi?id=192973
1226         <rdar://problem/46937309>
1227
1228         Unreviewed Windows port Debug builds fix.
1229
1230         No new tests since no behavior changes.
1231
1232         * accessibility/win/AXObjectCacheWin.cpp:
1233         (WebCore::AXObjectCache::postPlatformNotification): Add "std::" prefix to numeric_limits in ASSERT macro.
1234
1235 2018-12-24  Fujii Hironori  <Hironori.Fujii@sony.com>
1236
1237         Remove "using namespace std;"
1238         https://bugs.webkit.org/show_bug.cgi?id=192973
1239
1240         Reviewed by Alex Christensen.
1241
1242         Removed "using namespace std" statement, and use std:: prefix.
1243
1244         No new tests since no behavior changes.
1245
1246         * accessibility/win/AXObjectCacheWin.cpp:
1247         * platform/graphics/GraphicsContext3DPrivate.cpp:
1248         * platform/graphics/cairo/ImageBufferCairo.cpp:
1249         * platform/graphics/win/FontPlatformDataCairoWin.cpp:
1250         * platform/graphics/win/FontWin.cpp:
1251         (WebCore::FontCascade::floatWidthForComplexText const):
1252         * platform/graphics/win/GraphicsContextCGWin.cpp:
1253         * platform/graphics/win/GraphicsContextCairoWin.cpp:
1254         * platform/graphics/win/GraphicsContextDirect2D.cpp:
1255         * platform/graphics/win/GraphicsContextWin.cpp:
1256         * platform/graphics/win/SimpleFontDataCGWin.cpp:
1257         * platform/graphics/win/UniscribeController.cpp:
1258         (WebCore::UniscribeController::UniscribeController):
1259         (WebCore::UniscribeController::shapeAndPlaceItem):
1260         * platform/image-decoders/ScalableImageDecoder.cpp:
1261         * platform/text/LocaleICU.cpp:
1262         * platform/text/win/LocaleWin.cpp:
1263         * platform/win/ScrollbarThemeWin.cpp:
1264         * rendering/RenderRubyRun.cpp:
1265         (WebCore::RenderRubyRun::layoutBlock):
1266         * rendering/RenderThemeWin.cpp:
1267         (WebCore::RenderThemeWin::adjustMenuListButtonStyle const):
1268         (WebCore::RenderThemeWin::paintSearchFieldCancelButton):
1269         (WebCore::RenderThemeWin::adjustSearchFieldCancelButtonStyle const):
1270         (WebCore::RenderThemeWin::adjustSearchFieldResultsDecorationPartStyle const):
1271         (WebCore::RenderThemeWin::paintSearchFieldResultsDecorationPart):
1272         (WebCore::RenderThemeWin::adjustSearchFieldResultsButtonStyle const):
1273         (WebCore::RenderThemeWin::paintSearchFieldResultsButton):
1274
1275 2018-12-24  Simon Fraser  <simon.fraser@apple.com>
1276
1277         Change ScrollingNodeType to an enum class
1278         https://bugs.webkit.org/show_bug.cgi?id=193009
1279
1280         Reviewed by Zalan Bujtas.
1281
1282         Change the ScrollingNodeType enum to an enum class.
1283         
1284         No behavior change.
1285
1286         * page/scrolling/AsyncScrollingCoordinator.cpp:
1287         (WebCore::AsyncScrollingCoordinator::ensureRootStateNodeForFrameView):
1288         * page/scrolling/ScrollingCoordinator.cpp:
1289         (WebCore::operator<<):
1290         * page/scrolling/ScrollingCoordinator.h:
1291         * page/scrolling/ScrollingStateFixedNode.cpp:
1292         (WebCore::ScrollingStateFixedNode::ScrollingStateFixedNode):
1293         * page/scrolling/ScrollingStateNode.h:
1294         (WebCore::ScrollingStateNode::isFixedNode const):
1295         (WebCore::ScrollingStateNode::isStickyNode const):
1296         (WebCore::ScrollingStateNode::isFrameScrollingNode const):
1297         (WebCore::ScrollingStateNode::isOverflowScrollingNode const):
1298         * page/scrolling/ScrollingStateOverflowScrollingNode.cpp:
1299         (WebCore::ScrollingStateOverflowScrollingNode::ScrollingStateOverflowScrollingNode):
1300         * page/scrolling/ScrollingStateStickyNode.cpp:
1301         (WebCore::ScrollingStateStickyNode::ScrollingStateStickyNode):
1302         * page/scrolling/ScrollingStateTree.cpp:
1303         (WebCore::ScrollingStateTree::createNode):
1304         (WebCore::ScrollingStateTree::attachNode):
1305         * page/scrolling/ScrollingTreeNode.h:
1306         (WebCore::ScrollingTreeNode::isFixedNode const):
1307         (WebCore::ScrollingTreeNode::isStickyNode const):
1308         (WebCore::ScrollingTreeNode::isFrameScrollingNode const):
1309         (WebCore::ScrollingTreeNode::isOverflowScrollingNode const):
1310         * page/scrolling/ScrollingTreeOverflowScrollingNode.cpp:
1311         (WebCore::ScrollingTreeOverflowScrollingNode::ScrollingTreeOverflowScrollingNode):
1312         * page/scrolling/ios/ScrollingTreeIOS.cpp:
1313         (WebCore::ScrollingTreeIOS::createScrollingTreeNode):
1314         * page/scrolling/mac/ScrollingTreeFixedNode.mm:
1315         (WebCore::ScrollingTreeFixedNode::ScrollingTreeFixedNode):
1316         * page/scrolling/mac/ScrollingTreeMac.cpp:
1317         (ScrollingTreeMac::createScrollingTreeNode):
1318         * page/scrolling/mac/ScrollingTreeStickyNode.mm:
1319         (WebCore::ScrollingTreeStickyNode::ScrollingTreeStickyNode):
1320         * platform/graphics/GraphicsLayerClient.h:
1321         * rendering/RenderLayerCompositor.cpp:
1322         (WebCore::RenderLayerCompositor::reattachSubframeScrollLayers):
1323         (WebCore::scrollCoordinationRoleForNodeType):
1324         (WebCore::RenderLayerCompositor::updateScrollCoordinationForThisFrame):
1325         (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
1326
1327 2018-12-22  Carlos Garcia Campos  <cgarcia@igalia.com>
1328
1329         [HarfBuzz] Width not correctly reported as 0 for zero font size
1330         https://bugs.webkit.org/show_bug.cgi?id=192986
1331
1332         Reviewed by Michael Catanzaro.
1333
1334         Fixes test fast/text/font-size-zero.html
1335
1336         * platform/graphics/harfbuzz/ComplexTextControllerHarfBuzz.cpp:
1337         (WebCore::ComplexTextController::ComplexTextRun::ComplexTextRun): Use empty advances for glyphs when the font
1338         size is zero.
1339
1340 2018-12-20  Yusuke Suzuki  <yusukesuzuki@slowstart.org>
1341
1342         Use Ref<> as much as possible
1343         https://bugs.webkit.org/show_bug.cgi?id=192808
1344
1345         Reviewed by Alex Christensen.
1346
1347         * Modules/encryptedmedia/NavigatorEME.cpp:
1348         (WebCore::NavigatorEME::requestMediaKeySystemAccess):
1349         * Modules/fetch/FetchBody.cpp:
1350         (WebCore::FetchBody::bodyAsFormData const):
1351         * Modules/geolocation/Geolocation.cpp:
1352         (WebCore::Geolocation::getCurrentPosition):
1353         (WebCore::Geolocation::watchPosition):
1354         * Modules/indexeddb/IDBDatabase.cpp:
1355         (WebCore::IDBDatabase::objectStoreNames const):
1356         * Modules/indexeddb/IDBDatabase.h:
1357         * Modules/indexeddb/IDBObjectStore.cpp:
1358         (WebCore::IDBObjectStore::indexNames const):
1359         * Modules/indexeddb/IDBObjectStore.h:
1360         * Modules/indexeddb/IDBTransaction.cpp:
1361         (WebCore::IDBTransaction::scheduleOperation):
1362         * Modules/indexeddb/IDBTransaction.h:
1363         * Modules/indexeddb/client/TransactionOperation.h:
1364         (WebCore::IDBClient::createTransactionOperation):
1365         * Modules/mediastream/MediaDevices.cpp:
1366         (WebCore::MediaDevices::getUserMedia const):
1367         (WebCore::MediaDevices::getDisplayMedia const):
1368         * Modules/mediastream/UserMediaRequest.cpp:
1369         (WebCore::UserMediaRequest::create):
1370         * Modules/mediastream/UserMediaRequest.h:
1371         * Modules/webaudio/AudioParam.cpp:
1372         (WebCore::AudioParam::calculateFinalValues):
1373         * Modules/webaudio/ScriptProcessorNode.cpp:
1374         (WebCore::ScriptProcessorNode::initialize):
1375         * Modules/webdatabase/SQLStatement.cpp:
1376         (WebCore::SQLStatement::execute):
1377         * Modules/webgpu/WebGPU.cpp:
1378         (WebCore::WebGPU::requestAdapter const):
1379         * Modules/webgpu/WebGPUAdapter.cpp:
1380         (WebCore::WebGPUAdapter::create):
1381         * Modules/webgpu/WebGPUAdapter.h:
1382         * Modules/webgpu/WebGPUBuffer.cpp:
1383         (WebCore::WebGPUBuffer::create):
1384         * Modules/webgpu/WebGPUBuffer.h:
1385         * Modules/webgpu/WebGPUCommandBuffer.cpp:
1386         (WebCore::WebGPUCommandBuffer::create):
1387         (WebCore::WebGPUCommandBuffer::beginRenderPass):
1388         * Modules/webgpu/WebGPUCommandBuffer.h:
1389         * Modules/webgpu/WebGPUDevice.cpp:
1390         (WebCore::WebGPUDevice::create):
1391         (WebCore::WebGPUDevice::createBuffer const):
1392         (WebCore::WebGPUDevice::createShaderModule const):
1393         (WebCore::WebGPUDevice::createRenderPipeline const):
1394         (WebCore::WebGPUDevice::createCommandBuffer const):
1395         * Modules/webgpu/WebGPURenderPassEncoder.cpp:
1396         (WebCore::WebGPURenderPassEncoder::create):
1397         * Modules/webgpu/WebGPURenderPassEncoder.h:
1398         * Modules/webgpu/WebGPURenderPipeline.cpp:
1399         (WebCore::WebGPURenderPipeline::create):
1400         * Modules/webgpu/WebGPURenderPipeline.h:
1401         * Modules/webgpu/WebGPUShaderModule.cpp:
1402         (WebCore::WebGPUShaderModule::create):
1403         * Modules/webgpu/WebGPUShaderModule.h:
1404         * Modules/webgpu/WebGPUTexture.cpp:
1405         (WebCore::WebGPUTexture::createDefaultTextureView):
1406         * Modules/webgpu/WebGPUTextureView.cpp:
1407         (WebCore::WebGPUTextureView::create):
1408         * Modules/webgpu/WebGPUTextureView.h:
1409         * accessibility/AXObjectCache.cpp:
1410         (WebCore::AXObjectCache::rangeMatchesTextNearRange):
1411         * accessibility/atk/AXObjectCacheAtk.cpp:
1412         (WebCore::AXObjectCache::nodeTextChangePlatformNotification):
1413         * accessibility/atk/WebKitAccessibleHyperlink.cpp:
1414         (webkitAccessibleHyperlinkGetStartIndex):
1415         (webkitAccessibleHyperlinkGetEndIndex):
1416         * accessibility/atk/WebKitAccessibleInterfaceText.cpp:
1417         (getSelectionOffsetsForObject):
1418         * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
1419         (-[WebAccessibilityObjectWrapper _convertToNSRange:]):
1420         * bindings/js/JSDOMGlobalObjectTask.cpp:
1421         * bindings/js/JSDOMWindowBase.cpp:
1422         (WebCore::JSDOMWindowBase::queueTaskToEventLoop):
1423         * bindings/js/JSWorkerGlobalScopeBase.cpp:
1424         (WebCore::JSWorkerGlobalScopeBase::queueTaskToEventLoop):
1425         * bindings/js/ScriptControllerMac.mm:
1426         (WebCore::ScriptController::createScriptInstanceForWidget):
1427         * bindings/js/SerializedScriptValue.cpp:
1428         (WebCore::CloneDeserializer::readTerminal):
1429         (WebCore::SerializedScriptValue::create):
1430         * bridge/objc/objc_instance.h:
1431         * bridge/objc/objc_instance.mm:
1432         (ObjcInstance::create):
1433         * css/CSSComputedStyleDeclaration.cpp:
1434         (WebCore::ComputedStyleExtractor::currentColorOrValidColor const):
1435         (WebCore::ComputedStyleExtractor::getCSSPropertyValuesForShorthandProperties):
1436         (WebCore::ComputedStyleExtractor::getCSSPropertyValuesForGridShorthand):
1437         (WebCore::ComputedStyleExtractor::getBackgroundShorthandValue):
1438         * css/CSSComputedStyleDeclaration.h:
1439         * css/CSSFontFaceSource.cpp:
1440         (WebCore::CSSFontFaceSource::load):
1441         * css/CSSStyleSheet.cpp:
1442         (WebCore::CSSStyleSheet::rules):
1443         * css/FontFace.cpp:
1444         (WebCore::FontFace::unicodeRange const):
1445         (WebCore::FontFace::featureSettings const):
1446         * css/InspectorCSSOMWrappers.cpp:
1447         (WebCore::InspectorCSSOMWrappers::collectFromStyleSheetContents):
1448         * css/SVGCSSComputedStyleDeclaration.cpp:
1449         (WebCore::strokeDashArrayToCSSValueList):
1450         (WebCore::ComputedStyleExtractor::adjustSVGPaintForCurrentColor const):
1451         * css/StyleResolver.cpp:
1452         (WebCore::StyleResolver::createFilterOperations):
1453         * css/StyleRule.cpp:
1454         (WebCore::StyleRuleBase::createCSSOMWrapper const):
1455         * css/StyleRule.h:
1456         * dom/ChildListMutationScope.cpp:
1457         (WebCore::ChildListMutationAccumulator::getOrCreate):
1458         * dom/ChildListMutationScope.h:
1459         * dom/DocumentMarkerController.cpp:
1460         (WebCore::updateRenderedRectsForMarker):
1461         * dom/InlineStyleSheetOwner.cpp:
1462         (WebCore::InlineStyleSheetOwner::createSheet):
1463         * dom/PointerEvent.h:
1464         * dom/UserGestureIndicator.h:
1465         (WebCore::UserGestureToken::create):
1466         * editing/AlternativeTextController.cpp:
1467         (WebCore::AlternativeTextController::applyAlternativeTextToRange):
1468         (WebCore::AlternativeTextController::respondToUnappliedSpellCorrection):
1469         (WebCore::AlternativeTextController::respondToUnappliedEditing):
1470         (WebCore::AlternativeTextController::markPrecedingWhitespaceForDeletedAutocorrectionAfterCommand):
1471         (WebCore::AlternativeTextController::respondToMarkerAtEndOfWord):
1472         * editing/ApplyStyleCommand.cpp:
1473         (WebCore::ApplyStyleCommand::applyBlockStyle):
1474         (WebCore::ApplyStyleCommand::pushDownInlineStyleAroundNode):
1475         * editing/CompositeEditCommand.cpp:
1476         (WebCore::CompositeEditCommand::targetRanges const):
1477         (WebCore::CompositeEditCommand::replaceTextInNodePreservingMarkers):
1478         (WebCore::CompositeEditCommand::moveParagraphs):
1479         * editing/DeleteSelectionCommand.cpp:
1480         (WebCore::DeleteSelectionCommand::mergeParagraphs):
1481         * editing/Editing.cpp:
1482         (WebCore::visiblePositionForIndexUsingCharacterIterator):
1483         * editing/EditingStyle.cpp:
1484         (WebCore::EditingStyle::removeStyleConflictingWithStyleOfNode):
1485         (WebCore::EditingStyle::conflictsWithInlineStyleOfElement const):
1486         (WebCore::EditingStyle::prepareToApplyAt):
1487         (WebCore::EditingStyle::mergeInlineAndImplicitStyleOfElement):
1488         (WebCore::EditingStyle::mergeStyleFromRulesForSerialization):
1489         (WebCore::EditingStyle::removeStyleFromRulesAndContext):
1490         (WebCore::extractPropertiesNotIn):
1491         * editing/Editor.cpp:
1492         (WebCore::Editor::setBaseWritingDirection):
1493         (WebCore::Editor::setComposition):
1494         * editing/EditorCommand.cpp:
1495         (WebCore::executeApplyParagraphStyle):
1496         (WebCore::executeMakeTextWritingDirectionLeftToRight):
1497         (WebCore::executeMakeTextWritingDirectionNatural):
1498         (WebCore::executeMakeTextWritingDirectionRightToLeft):
1499         * editing/FormatBlockCommand.cpp:
1500         (WebCore::FormatBlockCommand::formatRange):
1501         * editing/RemoveFormatCommand.cpp:
1502         (WebCore::RemoveFormatCommand::doApply):
1503         * editing/ReplaceRangeWithTextCommand.cpp:
1504         (WebCore::ReplaceRangeWithTextCommand::targetRanges const):
1505         * editing/ReplaceSelectionCommand.cpp:
1506         (WebCore::ReplaceSelectionCommand::removeRedundantStylesAndKeepStyleSpanInline):
1507         (WebCore::handleStyleSpansBeforeInsertion):
1508         (WebCore::ReplaceSelectionCommand::handleStyleSpans):
1509         * editing/SpellingCorrectionCommand.cpp:
1510         (WebCore::SpellingCorrectionCommand::targetRanges const):
1511         * editing/TextCheckingHelper.cpp:
1512         (WebCore::TextCheckingHelper::findFirstMisspellingOrBadGrammar):
1513         * editing/TypingCommand.cpp:
1514         (WebCore::TypingCommand::insertText):
1515         (WebCore::TypingCommand::willAddTypingToOpenCommand):
1516         * editing/VisibleUnits.cpp:
1517         (WebCore::distanceBetweenPositions):
1518         * editing/cocoa/EditorCocoa.mm:
1519         (WebCore::Editor::selectionInWebArchiveFormat):
1520         * editing/ios/DictationCommandIOS.cpp:
1521         (WebCore::DictationCommandIOS::doApply):
1522         * editing/ios/EditorIOS.mm:
1523         (WebCore::Editor::setTextAlignmentForChangedBaseWritingDirection):
1524         (WebCore::Editor::removeUnchangeableStyles):
1525         (WebCore::Editor::writeImageToPasteboard):
1526         * editing/mac/EditorMac.mm:
1527         (WebCore::Editor::replaceNodeFromPasteboard):
1528         (WebCore::Editor::imageInWebArchiveFormat):
1529         * editing/markup.cpp:
1530         (WebCore::styleFromMatchedRulesAndInlineDecl):
1531         (WebCore::createFragmentForTransformToFragment):
1532         * fileapi/FileReaderLoader.cpp:
1533         (WebCore::FileReaderLoader::didFinishLoading):
1534         * html/FTPDirectoryDocument.cpp:
1535         (WebCore::createTemplateDocumentData):
1536         * html/HTMLMediaElement.cpp:
1537         (WebCore::HTMLMediaElement::scheduleEvent):
1538         (WebCore::HTMLMediaElement::createMediaControls):
1539         * html/HTMLTableElement.cpp:
1540         (WebCore::HTMLTableElement::createSharedCellStyle):
1541         * html/HTMLTableElement.h:
1542         * html/URLUtils.h:
1543         (WebCore::URLUtils<T>::origin const):
1544         * html/parser/HTMLConstructionSite.cpp:
1545         (WebCore::HTMLConstructionSite::createHTMLElementOrFindCustomElementInterface):
1546         * html/shadow/TextControlInnerElements.cpp:
1547         (WebCore::TextControlInnerElement::resolveCustomStyle):
1548         * html/track/WebVTTParser.cpp:
1549         (WebCore::WebVTTParser::createNewCue):
1550         * inspector/DOMPatchSupport.cpp:
1551         * inspector/InspectorCanvas.cpp:
1552         (WebCore::InspectorCanvas::buildInitialState):
1553         (WebCore::InspectorCanvas::buildAction):
1554         * inspector/InspectorFrontendClientLocal.cpp:
1555         (WebCore::InspectorFrontendClientLocal::openInNewTab):
1556         * inspector/InspectorStyleSheet.cpp:
1557         (WebCore::asCSSRuleList):
1558         (WebCore::InspectorStyle::styleWithProperties const):
1559         (WebCore::InspectorStyleSheet::ensureSourceData):
1560         * inspector/agents/InspectorCanvasAgent.cpp:
1561         (WebCore::InspectorCanvasAgent::didCreateCanvasRenderingContext):
1562         * inspector/agents/InspectorIndexedDBAgent.cpp:
1563         (WebCore::Inspector::keyPathFromIDBKeyPath):
1564         * inspector/agents/InspectorPageAgent.cpp:
1565         (WebCore::InspectorPageAgent::archive):
1566         * loader/EmptyClients.cpp:
1567         (WebCore::EmptyStorageNamespaceProvider::createSessionStorageNamespace):
1568         (WebCore::EmptyStorageNamespaceProvider::createLocalStorageNamespace):
1569         (WebCore::EmptyStorageNamespaceProvider::createEphemeralLocalStorageNamespace):
1570         (WebCore::EmptyStorageNamespaceProvider::createTransientLocalStorageNamespace):
1571         * loader/FrameLoader.cpp:
1572         (WebCore::FrameLoader::loadURL):
1573         (WebCore::FrameLoader::shouldInterruptLoadForXFrameOptions):
1574         (WebCore::FrameLoader::loadDifferentDocumentItem):
1575         * loader/WorkerThreadableLoader.cpp:
1576         (WebCore::WorkerThreadableLoader::loadResourceSynchronously):
1577         * loader/archive/mhtml/MHTMLParser.cpp:
1578         (WebCore::MHTMLParser::addResourceToArchive):
1579         (WebCore::MHTMLParser::parseNextPart):
1580         * loader/cache/MemoryCache.cpp:
1581         (WebCore::MemoryCache::addImageToCache):
1582         (WebCore::MemoryCache::removeResourcesWithOrigin):
1583         * page/DOMWindow.cpp:
1584         (WebCore::DOMWindow::getMatchedCSSRules const):
1585         (WebCore::DOMWindow::createWindow):
1586         * page/EventHandler.cpp:
1587         (WebCore::textDistance):
1588         * page/Page.cpp:
1589         (WebCore::Page::userStyleSheet const):
1590         * page/animation/CSSPropertyAnimation.cpp:
1591         (WebCore::blendFilterOperations):
1592         * page/ios/FrameIOS.mm:
1593         (WebCore::Frame::initWithSimpleHTMLDocument):
1594         (WebCore::Frame::interpretationsForCurrentRoot const):
1595         * page/mac/ServicesOverlayController.mm:
1596         (WebCore::ServicesOverlayController::Highlight::fadeIn):
1597         (WebCore::ServicesOverlayController::Highlight::fadeOut):
1598         * platform/SharedBuffer.cpp:
1599         (WebCore::SharedBuffer::tryCreateArrayBuffer const):
1600         * platform/audio/HRTFElevation.cpp:
1601         (WebCore::HRTFElevation::calculateKernelsForAzimuthElevation):
1602         * platform/audio/SincResampler.cpp:
1603         (WebCore::SincResampler::consumeSource):
1604         * platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
1605         (WebCore::AudioFileReader::createBus):
1606         * platform/audio/mac/AudioFileReaderMac.cpp:
1607         (WebCore::AudioFileReader::createBus):
1608         * platform/graphics/Icon.h:
1609         (WebCore::Icon::create):
1610         * platform/graphics/InbandTextTrackPrivate.h:
1611         (WebCore::InbandTextTrackPrivate::create):
1612         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
1613         (WebCore::AVFWrapper::shouldWaitForLoadingOfResource):
1614         * platform/graphics/avfoundation/objc/AudioTrackPrivateMediaSourceAVFObjC.h:
1615         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
1616         (WebCore::fulfillRequestWithKeyData):
1617         (WebCore::MediaPlayerPrivateAVFoundationObjC::shouldWaitForLoadingOfResource):
1618         * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.h:
1619         * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm:
1620         (WebCore::MediaSourcePrivateAVFObjC::create):
1621         (WebCore::MediaSourcePrivateAVFObjC::addSourceBuffer):
1622         * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h:
1623         * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
1624         (WebCore::SourceBufferPrivateAVFObjC::create):
1625         (WebCore::SourceBufferPrivateAVFObjC::didParseStreamDataAsAsset):
1626         * platform/graphics/avfoundation/objc/VideoTrackPrivateMediaSourceAVFObjC.h:
1627         * platform/graphics/ca/TileController.cpp:
1628         (WebCore::TileController::createTileLayer):
1629         * platform/graphics/ca/TileController.h:
1630         * platform/graphics/ca/win/CACFLayerTreeHost.cpp:
1631         (WebCore::CACFLayerTreeHost::acceleratedCompositingAvailable):
1632         (WebCore::CACFLayerTreeHost::create):
1633         * platform/graphics/gpu/cocoa/GPUBufferMetal.mm:
1634         (WebCore::GPUBuffer::create):
1635         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
1636         (WebCore::MediaPlayerPrivateGStreamer::updateTracks):
1637         (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfVideo):
1638         (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfAudio):
1639         (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfText):
1640         (WebCore::MediaPlayerPrivateGStreamer::handleMessage):
1641         (WebCore::MediaPlayerPrivateGStreamer::processMpegTsSection):
1642         (WebCore::MediaPlayerPrivateGStreamer::loadNextLocation):
1643         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
1644         (WebCore::MediaPlayerPrivateGStreamerBase::paint):
1645         * platform/graphics/gstreamer/mse/AppendPipeline.cpp:
1646         (WebCore::AppendPipeline::appsinkNewSample):
1647         * platform/graphics/iso/ISOProtectionSystemSpecificHeaderBox.cpp:
1648         (WebCore::ISOProtectionSystemSpecificHeaderBox::parse):
1649         * platform/graphics/iso/ISOTrackEncryptionBox.cpp:
1650         (WebCore::ISOTrackEncryptionBox::parse):
1651         * platform/graphics/texmap/TextureMapperAnimation.cpp:
1652         (WebCore::applyFilterAnimation):
1653         * platform/graphics/texmap/TextureMapperPlatformLayerBuffer.cpp:
1654         (WebCore::TextureMapperPlatformLayerBuffer::clone):
1655         * platform/graphics/transforms/TransformOperations.cpp:
1656         (WebCore::TransformOperations::blendByMatchingOperations const):
1657         * platform/image-decoders/ico/ICOImageDecoder.cpp:
1658         (WebCore::ICOImageDecoder::setDataForPNGDecoderAtIndex):
1659         * platform/mock/mediasource/MockBox.cpp:
1660         (WebCore::MockInitializationBox::MockInitializationBox):
1661         * platform/mock/mediasource/MockSourceBufferPrivate.cpp:
1662         (WebCore::MockSourceBufferPrivate::create):
1663         (WebCore::MockSourceBufferPrivate::append):
1664         * platform/mock/mediasource/MockSourceBufferPrivate.h:
1665         * platform/mock/mediasource/MockTracks.h:
1666         (WebCore::MockTextTrackPrivate::create):
1667         (WebCore::MockVideoTrackPrivate::create):
1668         * platform/network/FormData.h:
1669         (WebCore::FormData::decode):
1670         * platform/network/cocoa/CookieStorageObserver.h:
1671         * platform/network/cocoa/CookieStorageObserver.mm:
1672         (WebCore::CookieStorageObserver::create):
1673         * platform/network/soup/ResourceRequestSoup.cpp:
1674         (WebCore::appendEncodedBlobItemToSoupMessageBody):
1675         (WebCore::ResourceRequest::updateSoupMessageBody const):
1676         * platform/text/hyphen/HyphenationLibHyphen.cpp:
1677         (WebCore::HyphenationDictionary::createNull):
1678         (WebCore::HyphenationDictionary::create):
1679         * platform/win/SearchPopupMenuWin.cpp:
1680         (WebCore::SearchPopupMenuWin::SearchPopupMenuWin):
1681         (WebCore::SearchPopupMenuWin::popupMenu):
1682         * platform/win/SearchPopupMenuWin.h:
1683         * rendering/RenderThemeIOS.mm:
1684         (WebCore::applyCommonButtonPaddingToStyle):
1685         (WebCore::RenderThemeIOS::paintProgressBar):
1686         (WebCore::RenderThemeIOS::adjustButtonStyle const):
1687         (WebCore::paintAttachmentIcon):
1688         * rendering/svg/SVGRenderTreeAsText.cpp:
1689         (WebCore::writeSVGResourceContainer):
1690         * storage/Storage.cpp:
1691         (WebCore::Storage::create):
1692         (WebCore::Storage::Storage):
1693         * storage/Storage.h:
1694         (WebCore::Storage::area const):
1695         * storage/StorageNamespace.h:
1696         * storage/StorageNamespaceProvider.cpp:
1697         (WebCore::StorageNamespaceProvider::localStorageArea):
1698         * storage/StorageNamespaceProvider.h:
1699         * svg/SVGElement.cpp:
1700         (WebCore::SVGElement::getPresentationAttribute):
1701         * svg/SVGFEBlendElement.cpp:
1702         (WebCore::SVGFEBlendElement::build):
1703         * svg/SVGFEColorMatrixElement.cpp:
1704         (WebCore::SVGFEColorMatrixElement::build):
1705         * svg/SVGFEComponentTransferElement.cpp:
1706         (WebCore::SVGFEComponentTransferElement::build):
1707         * svg/SVGFECompositeElement.cpp:
1708         (WebCore::SVGFECompositeElement::build):
1709         * svg/SVGFEDiffuseLightingElement.cpp:
1710         (WebCore::SVGFEDiffuseLightingElement::build):
1711         * svg/SVGFEDisplacementMapElement.cpp:
1712         (WebCore::SVGFEDisplacementMapElement::build):
1713         * svg/SVGFEDropShadowElement.cpp:
1714         (WebCore::SVGFEDropShadowElement::build):
1715         * svg/SVGFEGaussianBlurElement.cpp:
1716         (WebCore::SVGFEGaussianBlurElement::build):
1717         * svg/SVGFEMergeElement.cpp:
1718         (WebCore::SVGFEMergeElement::build):
1719         * svg/SVGFEMorphologyElement.cpp:
1720         (WebCore::SVGFEMorphologyElement::build):
1721         * svg/SVGFEOffsetElement.cpp:
1722         (WebCore::SVGFEOffsetElement::build):
1723         * svg/SVGFESpecularLightingElement.cpp:
1724         (WebCore::SVGFESpecularLightingElement::build):
1725         * svg/SVGFETileElement.cpp:
1726         (WebCore::SVGFETileElement::build):
1727         * testing/GCObservation.h:
1728         * xml/XSLTProcessor.cpp:
1729         (WebCore::XSLTProcessor::createDocumentFromSource):
1730         * xml/parser/XMLDocumentParser.cpp:
1731         (WebCore::XMLDocumentParser::parseDocumentFragment):
1732
1733 2018-12-21  Chris Dumez  <cdumez@apple.com>
1734
1735         navigator.userAgent in service workers does not reflect customUserAgent set by client
1736         https://bugs.webkit.org/show_bug.cgi?id=192951
1737
1738         Reviewed by Youenn Fablet.
1739
1740         Whenever a service worker client registers itself, also pass its effective user agent.
1741         In the network process, for each origin, we store the latest client's user agent and
1742         use it when starting the service worker.
1743
1744         * dom/Document.cpp:
1745         (WebCore::Document::setServiceWorkerConnection):
1746         * loader/DocumentLoader.cpp:
1747         (WebCore::DocumentLoader::registerTemporaryServiceWorkerClient):
1748         * workers/service/SWClientConnection.h:
1749         * workers/service/server/SWServer.cpp:
1750         (WebCore::SWServer::serviceWorkerClientUserAgent const):
1751         (WebCore::SWServer::installContextData):
1752         (WebCore::SWServer::runServiceWorker):
1753         (WebCore::SWServer::registerServiceWorkerClient):
1754         * workers/service/server/SWServer.h:
1755         * workers/service/server/SWServerToContextConnection.h:
1756         * workers/service/server/SWServerWorker.cpp:
1757         (WebCore::SWServerWorker::userAgent const):
1758         * workers/service/server/SWServerWorker.h:
1759
1760 2018-12-21  Youenn Fablet  <youenn@apple.com>
1761
1762         RTCRtpSender.setParameters() does set active parameter
1763         https://bugs.webkit.org/show_bug.cgi?id=192848
1764
1765         Reviewed by Eric Carlson.
1766
1767         Covered by updated test.
1768
1769         * Modules/mediastream/libwebrtc/LibWebRTCUtils.cpp:
1770         (WebCore::updateRTCRtpSendParameters):
1771         The routine was updating the local value, not the out parameter.
1772
1773 2018-12-21  Eric Carlson  <eric.carlson@apple.com>
1774
1775         'ended' Event doesn't fire on MediaStreamTrack when a USB camera is unplugged
1776         https://bugs.webkit.org/show_bug.cgi?id=187896
1777         <rdar://problem/42681445>
1778
1779         Reviewed by Jer Noble.
1780
1781         No new tests, tested manually.
1782
1783         * platform/mediastream/mac/AVVideoCaptureSource.h:
1784         * platform/mediastream/mac/AVVideoCaptureSource.mm:
1785         (WebCore::AVVideoCaptureSource::deviceDisconnected):
1786         (-[WebCoreAVVideoCaptureSourceObserver addNotificationObservers]):
1787         (-[WebCoreAVVideoCaptureSourceObserver removeNotificationObservers]):
1788         (-[WebCoreAVVideoCaptureSourceObserver deviceConnectedDidChange:]):
1789         * platform/mediastream/mac/CoreAudioCaptureDeviceManager.cpp:
1790         (WebCore::deviceHasInputStreams):
1791         (WebCore::isValidCaptureDevice):
1792         (WebCore::CoreAudioCaptureDeviceManager::coreAudioCaptureDevices):
1793         (WebCore::CoreAudioCaptureDeviceManager::refreshAudioCaptureDevices):
1794         (WebCore::CoreAudioCaptureDeviceManager::devicesChanged): Deleted.
1795         * platform/mediastream/mac/CoreAudioCaptureDeviceManager.h:
1796         * platform/mediastream/mac/CoreAudioCaptureSource.cpp:
1797         (WebCore::CoreAudioSharedUnit::setCaptureDevice):
1798         (WebCore::CoreAudioSharedUnit::devicesChanged):
1799         (WebCore::CoreAudioSharedUnit::startProducingData):
1800         (WebCore::CoreAudioSharedUnit::startInternal):
1801         (WebCore::CoreAudioSharedUnit::verifyIsCapturing):
1802         (WebCore::CoreAudioSharedUnit::captureFailed):
1803         (WebCore::CoreAudioCaptureSourceFactory::devicesChanged):
1804         (WebCore::CoreAudioCaptureSource::CoreAudioCaptureSource):
1805         (WebCore::CoreAudioSharedUnit::setCaptureDeviceID): Deleted.
1806         * platform/mediastream/mac/CoreAudioCaptureSource.h:
1807
1808 2018-12-20  Ryosuke Niwa  <rniwa@webkit.org>
1809
1810         REGRESSION(r239353): iOS WK1 Assertion failure in notifyChildNodeRemoved while running
1811         TestWebKitAPI.QuickLook.LegacyQuickLookContent
1812         https://bugs.webkit.org/show_bug.cgi?id=192859
1813         <rdar://problem/46887237>
1814
1815         Reviewed by Antti Koivisto.
1816
1817         After r239353, ScriptDisallowedScope::InMainThread::isScriptAllowed() may return false when the web thread
1818         is inside a delegate callback even when there is a ScriptDisallowedScope defined.
1819
1820         Replace the existign debug assertions which assert !ScriptDisallowedScope::InMainThread::isScriptAllowed()
1821         by a newly added ScriptDisallowedScope::InMainThread::hasDisallowedScope to avoid hitting this assertion.
1822
1823         Tests: TestWebKitAPI.QuickLook.LegacyQuickLookContent
1824
1825         * dom/ContainerNodeAlgorithms.cpp:
1826         (WebCore::notifyChildNodeInserted):
1827         (WebCore::notifyChildNodeRemoved):
1828         * dom/Document.cpp:
1829         (WebCore::Document::nodeChildrenWillBeRemoved):
1830         (WebCore::Document::nodeWillBeRemoved):
1831         * dom/ScriptDisallowedScope.h:
1832         (WebCore::ScriptDisallowedScope::InMainThread::hasDisallowedScope):
1833         * html/HTMLFormElement.cpp:
1834         (WebCore:: const):
1835
1836 2018-12-21  Joseph Pecoraro  <pecoraro@apple.com>
1837
1838         Update status of some WebCore features in features.json
1839         https://bugs.webkit.org/show_bug.cgi?id=192998
1840
1841         Reviewed by Tim Horton.
1842
1843         * features.json:
1844         - Variation Fonts: Supported
1845         - Conic Gradients: Supported in Preview
1846         - Web Share: Supported in Preview
1847         - <datalist>: Supported in Preview
1848         - Intersection Observers: Supported in Preview
1849
1850 2018-12-21  Zalan Bujtas  <zalan@apple.com>
1851
1852         [iOS] Using file upload can trigger a crash under RenderThemeIOS::paintFileUploadIconDecorations()
1853         https://bugs.webkit.org/show_bug.cgi?id=192357
1854         <rdar://problem/42852260>
1855
1856         Reviewed by Simon Fraser.
1857
1858         Do not try to paint the file picker when painting is disabled.
1859
1860         * rendering/RenderFileUploadControl.cpp:
1861         (WebCore::RenderFileUploadControl::paintObject):
1862
1863 2018-12-21  Jiewen Tan  <jiewen_tan@apple.com>
1864
1865         [WebAuthN] userPresence should always be true
1866         https://bugs.webkit.org/show_bug.cgi?id=192835
1867         <rdar://problem/46538788>
1868
1869         Reviewed by Brent Fulgham.
1870
1871         In the current spec as of 7 August 2018, userPresence is suggested to set to the inverse of userVerification.
1872         This doesn't comply with the CTAP spec. Details in: https://github.com/w3c/webauthn/issues/1123.
1873         After discussing with other members of the working group, we decided to make userPresence always default to true.
1874
1875         Covered by exisiting tests.
1876
1877         * Modules/webauthn/fido/DeviceRequestConverter.cpp:
1878         (fido::encodeGetAssertionRequestAsCBOR):
1879
1880 2018-12-21  Jiewen Tan  <jiewen_tan@apple.com>
1881
1882         [WebAuthN] Import an APDU coder from Chromium
1883         https://bugs.webkit.org/show_bug.cgi?id=192949
1884         <rdar://problem/46879933>
1885
1886         Reviewed by Brent Fulgham.
1887
1888         This patch imports an APDU coder from Chromium. Here is the documentation:
1889         https://fidoalliance.org/specs/fido-u2f-v1.2-ps-20170411/fido-u2f-raw-message-formats-v1.2-ps-20170411.html#u2f-message-framing
1890         APDU is a binary format to frame any U2F requests/responses into binaries. It is equivalent to CBOR in CTAP2.
1891
1892         Here is a list of files that are imported from Chromium:
1893         https://cs.chromium.org/chromium/src/components/apdu/apdu_command.cc?rcl=a2f290c10d132f53518e7f99d5635ee814ff8090
1894         https://cs.chromium.org/chromium/src/components/apdu/apdu_command.h?rcl=867b103481f6f4ccc79a69bba16c11eefac3cdb6
1895         https://cs.chromium.org/chromium/src/components/apdu/apdu_response.cc?rcl=867b103481f6f4ccc79a69bba16c11eefac3cdb6
1896         https://cs.chromium.org/chromium/src/components/apdu/apdu_response.h?rcl=867b103481f6f4ccc79a69bba16c11eefac3cdb6
1897         https://cs.chromium.org/chromium/src/components/apdu/apdu_unittest.cc?rcl=867b103481f6f4ccc79a69bba16c11eefac3cdb6
1898
1899         Covered by API tests.
1900
1901         * Modules/webauthn/apdu/ApduCommand.cpp: Added.
1902         (apdu::ApduCommand::createFromMessage):
1903         (apdu::ApduCommand::ApduCommand):
1904         (apdu::ApduCommand::getEncodedCommand const):
1905         * Modules/webauthn/apdu/ApduCommand.h: Added.
1906         * Modules/webauthn/apdu/ApduResponse.cpp: Added.
1907         (apdu::ApduResponse::createFromMessage):
1908         (apdu::ApduResponse::ApduResponse):
1909         (apdu::ApduResponse::getEncodedResponse const):
1910         * Modules/webauthn/apdu/ApduResponse.h: Added.
1911         * Sources.txt:
1912         * WebCore.xcodeproj/project.pbxproj:
1913
1914 2018-12-21  Jer Noble  <jer.noble@apple.com>
1915
1916         Convert raw CDMSessionMediaSourceAVFObjC pointer in MediaPlayerPrivateMediaSourceAVFObjC
1917         https://bugs.webkit.org/show_bug.cgi?id=192985
1918         <rdar://problem/46750743>
1919
1920         Reviewed by Eric Carlson.
1921
1922         Make m_session a RefPtr; drive-by fix: make m_mediaElement in WebKitMediaKeys a WeakPtr.
1923
1924         * Modules/encryptedmedia/legacy/WebKitMediaKeys.cpp:
1925         (WebCore::WebKitMediaKeys::setMediaElement):
1926         * Modules/encryptedmedia/legacy/WebKitMediaKeys.h:
1927         * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.h:
1928         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
1929         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
1930         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::MediaPlayerPrivateMediaSourceAVFObjC):
1931         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::setCDMSession):
1932
1933 2018-12-21  Justin Michaud  <justin_michaud@apple.com>
1934
1935         CSS variables don't work for colors in "border" property
1936         https://bugs.webkit.org/show_bug.cgi?id=192922
1937
1938         Reviewed by Simon Fraser.
1939
1940         ParseColorFunction no longer consumes anything if the color was not valid.
1941
1942         Test: css-custom-properties-api/border-variable-parsing.html
1943
1944         * css/parser/CSSPropertyParserHelpers.cpp:
1945         (WebCore::CSSPropertyParserHelpers::parseColorFunction):
1946
1947 2018-12-21  Justin Fan  <justin_fan@apple.com>
1948
1949         [WebGPU] GPUBindGroupLayout refactoring: no HashMap, and failure logging
1950         https://bugs.webkit.org/show_bug.cgi?id=192990
1951
1952         Reviewed by Myles C. Maxfield.
1953
1954         Refactor away the unnecessary HashMaps when creating MTLArgumentEncoders in GPUBindGroupLayout creation.
1955         Also update GPUBindGroupLayout::create -> tryCreate, in order to better handle Objective-C exceptions.
1956
1957         No new tests; no change in behavior.
1958
1959         * Modules/webgpu/WebGPUBindGroupLayout.cpp:
1960         (WebCore::WebGPUBindGroupLayout::create):
1961         (WebCore::WebGPUBindGroupLayout::WebGPUBindGroupLayout):
1962         * Modules/webgpu/WebGPUBindGroupLayout.h:
1963         (WebCore::WebGPUBindGroupLayout::bindGroupLayout const):
1964         * Modules/webgpu/WebGPUDevice.cpp:
1965         (WebCore::WebGPUDevice::createBindGroupLayout const):
1966         * platform/graphics/gpu/GPUBindGroupLayout.h:
1967         * platform/graphics/gpu/GPUDevice.cpp:
1968         (WebCore::GPUDevice::tryCreateBindGroupLayout const): Renamed from ::create*. Now returning a RefPtr. 
1969         (WebCore::GPUDevice::createBindGroupLayout const): Deleted.
1970         * platform/graphics/gpu/GPUDevice.h:
1971         * platform/graphics/gpu/cocoa/GPUBindGroupLayoutMetal.mm:
1972         (WebCore::appendArgumentToArray):
1973         (WebCore::newEncoder):
1974         (WebCore::GPUBindGroupLayout::tryCreate): Renamed from ::create. Now returning a RefPtr.
1975         (WebCore::GPUBindGroupLayout::GPUBindGroupLayout):
1976         (WebCore::appendArgumentToArrayInMap): Deleted.
1977         (WebCore::GPUBindGroupLayout::create): Deleted.
1978
1979         Deleted unneeded GPUBindGroupLayout.cpp:
1980         * Sources.txt:
1981         * WebCore.xcodeproj/project.pbxproj:
1982         * platform/graphics/gpu/GPUBindGroupLayout.cpp: Removed.
1983
1984 2018-12-21  Alejandro G. Castro  <alex@igalia.com>
1985
1986         [GTK][WPE] Add DeviceIdHashSaltStorage disk persistence
1987         https://bugs.webkit.org/show_bug.cgi?id=190466
1988
1989         Reviewed by Youenn Fablet.
1990
1991         Added persistency to the DeviceIdHashSaltStorage.
1992
1993         * platform/glib/FileSystemGlib.cpp:
1994         (WebCore::FileSystem::getFileSize): Implemented this function to
1995         allow sharing code with the statistics storage class.
1996         * platform/glib/KeyedDecoderGlib.cpp:
1997         (WebCore::KeyedDecoderGlib::dictionaryFromGVariant): Added a
1998         condition to control situations where the key is empty, it can
1999         happen if the user modifies the file in the disk.
2000         * Modules/indexeddb/shared/IDBResourceIdentifier.cpp: Add include
2001         to make work compilation with debug, unified builds.
2002
2003 2018-12-21  Zalan Bujtas  <zalan@apple.com>
2004
2005         Synchronous media query evaluation could destroy current Frame/FrameView.
2006         https://bugs.webkit.org/show_bug.cgi?id=192781
2007         <rdar://problem/34416793>
2008
2009         Reviewed by Chris Dumez.
2010
2011         Protect Frame and FrameView when coming back from printing and check if the current Frame/FrameView/FrameLoader objects are still valid.
2012
2013         Test: printing/print-with-media-query-destory.html
2014
2015         * loader/DocumentLoader.cpp:
2016         (WebCore::DocumentLoader::finishedLoading):
2017         * page/Frame.cpp:
2018         (WebCore::Frame::setPrinting):
2019         * page/FrameView.cpp:
2020         (WebCore::FrameView::forceLayoutForPagination):
2021         * page/PrintContext.cpp:
2022         (WebCore::PrintContext::PrintContext):
2023         (WebCore::PrintContext::computePageRects):
2024         (WebCore::PrintContext::computePageRectsWithPageSizeInternal):
2025         (WebCore::PrintContext::begin):
2026         (WebCore::PrintContext::computeAutomaticScaleFactor):
2027         (WebCore::PrintContext::spoolPage):
2028         (WebCore::PrintContext::spoolRect):
2029         (WebCore::PrintContext::end):
2030         * page/PrintContext.h:
2031         (WebCore::PrintContext::frame const): Deleted.
2032
2033 2018-12-21  Wenson Hsieh  <wenson_hsieh@apple.com>
2034
2035         Setting the file wrapper and content type of an attachment to a PDF should update its image
2036         https://bugs.webkit.org/show_bug.cgi?id=192984
2037         <rdar://problem/46798028>
2038
2039         Reviewed by Tim Horton.
2040
2041         Allow PDF data to be used to update enclosing image elements when setting the file wrapper for an attachment.
2042         Covered by a new API test: WKAttachmentTests.SetFileWrapperForPDFImageAttachment.
2043
2044         * html/HTMLAttachmentElement.cpp:
2045         (WebCore::mimeTypeIsSuitableForInlineImageAttachment):
2046         (WebCore::HTMLAttachmentElement::updateEnclosingImageWithData):
2047
2048 2018-12-21  Justin Michaud  <justin_michaud@apple.com>
2049
2050         Repeated background images with zero size should display the background color
2051         https://bugs.webkit.org/show_bug.cgi?id=192962
2052
2053         Reviewed by Antti Koivisto.
2054
2055         Test: fast/backgrounds/background-repeat-with-zero-size.html
2056
2057         * platform/LengthSize.h:
2058         (WebCore::LengthSize::isEmpty const):
2059         * rendering/RenderBoxModelObject.cpp:
2060         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
2061         * rendering/style/FillLayer.h:
2062         (WebCore::FillLayer::isEmpty const):
2063
2064 2018-12-21  Manuel Rego Casasnovas  <rego@igalia.com>
2065
2066         [css-grid] Fix percentages in relative offsets for grid items
2067         https://bugs.webkit.org/show_bug.cgi?id=190492
2068
2069         Reviewed by Sergio Villar Senin.
2070
2071         The method RenderBoxModelObject::relativePositionOffset() was not considering the case of grid items,
2072         where the containing block is the grid area.
2073         The patch modifies the method so the new code uses overrideContainingBlockContentWidth|Height when required.
2074
2075         Test: imported/w3c/web-platform-tests/css/css-grid/grid-items/grid-items-relative-offsets-002.html
2076
2077         * rendering/RenderBox.cpp: Implement the physical versions of the already existent methods.
2078         (WebCore::RenderBox::overrideContainingBlockContentWidth const):
2079         (WebCore::RenderBox::overrideContainingBlockContentHeight const):
2080         (WebCore::RenderBox::hasOverrideContainingBlockContentWidth const):
2081         (WebCore::RenderBox::hasOverrideContainingBlockContentHeight const):
2082         * rendering/RenderBox.h:
2083         * rendering/RenderBoxModelObject.cpp:
2084         (WebCore::RenderBoxModelObject::relativePositionOffset const): Modified method
2085         to take into account overrideContainingBlockContentWidth|Height for grid items.
2086         * rendering/RenderBoxModelObject.h: Added new headers for physical virtual methods
2087         that will be overridden in RenderBox.
2088         (WebCore::RenderBoxModelObject::overrideContainingBlockContentWidth const):
2089         (WebCore::RenderBoxModelObject::overrideContainingBlockContentHeight const):
2090         (WebCore::RenderBoxModelObject::hasOverrideContainingBlockContentWidth const):
2091         (WebCore::RenderBoxModelObject::hasOverrideContainingBlockContentHeight const):
2092
2093 2018-12-20  Justin Fan  <justin_fan@apple.com>
2094
2095         [WebGPU] Convert WebGPUBindGroups into MTLArgumentEncoders
2096         https://bugs.webkit.org/show_bug.cgi?id=192956
2097
2098         Reviewed by Myles Maxfield.
2099
2100         No testable behavior change. Existing tests cover possible crashing.
2101
2102         Add GPUBindGroupLayoutMetal.mm:
2103         * SourcesCocoa.txt:
2104         * WebCore.xcodeproj/project.pbxproj:
2105
2106         Flesh out GPUBindGroupLayout::create:
2107         * platform/graphics/gpu/GPUBindGroupLayout.cpp:
2108         * platform/graphics/gpu/GPUBindGroupLayout.h:
2109         * platform/graphics/gpu/GPUDevice.cpp:
2110         (WebCore::GPUDevice::createBindGroupLayout const):
2111         * platform/graphics/gpu/cocoa/GPUBindGroupLayoutMetal.mm: Added.
2112         (WebCore::appendArgumentToArrayInMap): Added.
2113         (WebCore::GPUBindGroupLayout::create):
2114         (WebCore::GPUBindGroupLayout::GPUBindGroupLayout):
2115         (WebCore::MTLDataTypeForBindingType): Added.
2116
2117 2018-12-20  Michael Catanzaro  <mcatanzaro@igalia.com>
2118
2119         Unreviewed, remove stray #pragma once added to .cpp file
2120
2121         * svg/properties/SVGAttributeOwnerProxy.cpp:
2122
2123 2018-12-20  Justin Michaud  <justin_michaud@apple.com>
2124
2125         Adding runtime-enabled attribute to Element prevents inlining property access
2126         https://bugs.webkit.org/show_bug.cgi?id=192901
2127
2128         Add a call to flattenDictionaryObject after disabling runtime-enabled attributes.
2129
2130         Reviewed by Ryosuke Niwa.
2131
2132         * bindings/scripts/CodeGeneratorJS.pm:
2133         (GenerateImplementation):
2134         * bindings/scripts/test/JS/JSTestEnabledBySetting.cpp:
2135         (WebCore::JSTestEnabledBySettingPrototype::finishCreation):
2136         * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
2137         (WebCore::JSTestGenerateIsReachablePrototype::finishCreation):
2138         * bindings/scripts/test/JS/JSTestNode.cpp:
2139         (WebCore::JSTestNodePrototype::finishCreation):
2140         * bindings/scripts/test/JS/JSTestObj.cpp:
2141         (WebCore::JSTestObjPrototype::finishCreation):
2142
2143 2018-12-20  Chris Dumez  <cdumez@apple.com>
2144
2145         Use Optional::hasValue() instead of Optional::has_value()
2146         https://bugs.webkit.org/show_bug.cgi?id=192948
2147
2148         Reviewed by Tim Horton.
2149
2150         * bindings/js/DOMPromiseProxy.h:
2151         (WebCore::DOMPromiseProxy<IDLType>::isFulfilled const):
2152         (WebCore::DOMPromiseProxy<IDLVoid>::isFulfilled const):
2153         (WebCore::DOMPromiseProxyWithResolveCallback<IDLType>::isFulfilled const):
2154         * dom/DataTransferItemList.h:
2155         (WebCore::DataTransferItemList::hasItems const):
2156         * dom/EventTarget.cpp:
2157         (WebCore::EventTarget::addEventListener):
2158         * html/HTMLMediaElement.cpp:
2159         (WebCore::HTMLMediaElement::captionDisplayMode):
2160         * platform/graphics/MediaPlayer.cpp:
2161         (WebCore::MediaPlayer::wouldTaintOrigin const):
2162         * platform/graphics/gstreamer/mse/AppendPipeline.cpp:
2163         (WebCore::AppendPipeline::parseDemuxerSrcPadCaps):
2164         * platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.cpp:
2165         (WebCore::MediaPlayerPrivateGStreamerMSE::trackDetected):
2166         * platform/graphics/gstreamer/mse/WebKitMediaSourceGStreamer.cpp:
2167         (webKitMediaSrcUpdatePresentationSize):
2168         * platform/mac/NSScrollerImpDetails.mm:
2169         (WebCore::ScrollerStyle::recommendedScrollerStyle):
2170         * rendering/RenderListItem.cpp:
2171         (WebCore::RenderListItem::setExplicitValue):
2172
2173 2018-12-20  Chris Dumez  <cdumez@apple.com>
2174
2175         Move HTTPS_UPGRADE code behind a runtime flag, off by default
2176         https://bugs.webkit.org/show_bug.cgi?id=192937
2177
2178         Reviewed by Youenn Fablet.
2179
2180         Move HTTPS_UPGRADE code behind a runtime flag, off by default and drop the build time flag.
2181
2182         * page/Settings.yaml:
2183
2184 2018-12-20  Youenn Fablet  <youenn@apple.com>
2185
2186         Remove custom constructors of ReadableStreamDefaultReader and ReadableStreamBYOBReader
2187         https://bugs.webkit.org/show_bug.cgi?id=192838
2188
2189         Reviewed by Chris Dumez.
2190
2191         Generate constructor code in case of a Private but not Public constructor.
2192         Make sure this is correctly exposed in global objects.
2193         Add JS built-in constructor implementations for those two objects.
2194
2195         Also add JS built-in constructors for controller and byob request.
2196         To keep existing behavior, JS built-ins calling these constructors need to pass
2197         an additional parameter that allows making the difference between a JS builtin caller or a JS caller.
2198         In the latter case, the constructor will throw.
2199
2200         Covered by existing tests, no observable change of behavior.
2201
2202         * Modules/streams/ReadableByteStreamController.idl:
2203         * Modules/streams/ReadableByteStreamController.js:
2204         (initializeReadableByteStreamController):
2205         (getter.byobRequest):
2206         * Modules/streams/ReadableByteStreamInternals.js:
2207         (privateInitializeReadableByteStreamController): Deleted.
2208         (privateInitializeReadableStreamBYOBRequest): Deleted.
2209         * Modules/streams/ReadableStream.js:
2210         (initializeReadableStream):
2211         * Modules/streams/ReadableStreamBYOBReader.js:
2212         (initializeReadableStreamBYOBReader):
2213         * Modules/streams/ReadableStreamBYOBRequest.idl:
2214         * Modules/streams/ReadableStreamBYOBRequest.js:
2215         (initializeReadableStreamBYOBRequest):
2216         * Modules/streams/ReadableStreamDefaultController.idl:
2217         * Modules/streams/ReadableStreamDefaultController.js:
2218         (initializeReadableStreamDefaultController):
2219         (enqueue):
2220         * Modules/streams/ReadableStreamDefaultReader.js:
2221         (initializeReadableStreamDefaultReader):
2222         * Modules/streams/ReadableStreamInternals.js:
2223         (readableStreamDefaultControllerError): Deleted.
2224         * Sources.txt:
2225         * UnifiedSources-input.xcfilelist:
2226         * WebCore.xcodeproj/project.pbxproj:
2227         * bindings/js/JSDOMBuiltinConstructor.h:
2228         * bindings/js/JSDOMGlobalObject.cpp:
2229         (WebCore::JSDOMGlobalObject::addBuiltinGlobals):
2230         * bindings/js/JSReadableStreamPrivateConstructors.cpp: Removed.
2231         * bindings/js/JSReadableStreamPrivateConstructors.h: Removed.
2232         * bindings/scripts/CodeGeneratorJS.pm:
2233         (GeneratePropertiesHashTable):
2234         * bindings/scripts/preprocess-idls.pl:
2235         (shouldExposeInterface):
2236
2237 2018-12-20  Jiewen Tan  <jiewen_tan@apple.com>
2238
2239         [WebAuthN] Remove hash from Client Data
2240         https://bugs.webkit.org/show_bug.cgi?id=192727
2241         <rdar://problem/46746673>
2242
2243         Reviewed by Brent Fulgham.
2244
2245         The hash algorithm for hashing the client data is enforced to SHA_256 in the latest spec:
2246         https://www.w3.org/TR/webauthn/#sec-client-data. Therefore, we should remove it.
2247
2248         Covered by existing tests.
2249
2250         * Modules/webauthn/AuthenticatorCoordinator.cpp:
2251         (WebCore::AuthenticatorCoordinatorInternal::produceClientDataJson):
2252
2253 2018-12-20  Jiewen Tan  <jiewen_tan@apple.com>
2254
2255         [WebAuthN] Add a runtime flag for local authenticator
2256         https://bugs.webkit.org/show_bug.cgi?id=192792
2257         <rdar://problem/46798738>
2258
2259         Reviewed by Brent Fulgham.
2260
2261         No tests.
2262
2263         This patch adds a runtime flag for local authenticator and removes ways to
2264         set the runtime flag for web authentication in LegacyWebKit.
2265
2266         * page/RuntimeEnabledFeatures.h:
2267         (WebCore::RuntimeEnabledFeatures::setWebAuthenticationLocalAuthenticatorEnabled):
2268         (WebCore::RuntimeEnabledFeatures::webAuthenticationLocalAuthenticatorEnabled const):
2269
2270 2018-12-20  Jeremy Jones  <jeremyj@apple.com>
2271
2272         Pointer lock causes abandoned documents
2273         https://bugs.webkit.org/show_bug.cgi?id=188727
2274         rdar://problem/44248197
2275         
2276         Reviewed by Simon Fraser.
2277
2278         Fixes --world-leaks in these tests:
2279
2280         pointer-lock/locked-element-removed-from-dom.html
2281         pointer-lock/mouse-event-delivery.html
2282         fast/shadow-dom/pointerlockelement-in-slot.html
2283
2284         PointerLockController now uses WeakPtr instead of RefPtr because it has no need to extend the lifetime of a document.
2285
2286         * page/PointerLockController.cpp:
2287         (WebCore::PointerLockController::elementRemoved):
2288         (WebCore::PointerLockController::documentDetached):
2289         (WebCore::PointerLockController::didAcquirePointerLock):
2290         * page/PointerLockController.h:
2291
2292 2018-12-20  Chris Dumez  <cdumez@apple.com>
2293
2294         Use Optional::valueOr() instead of Optional::value_or()
2295         https://bugs.webkit.org/show_bug.cgi?id=192933
2296
2297         Reviewed by Geoffrey Garen.
2298
2299         * Modules/applepay/paymentrequest/ApplePayPaymentHandler.cpp:
2300         (WebCore::convert):
2301         (WebCore::ApplePayPaymentHandler::didAuthorizePayment):
2302         * Modules/encryptedmedia/MediaKeySession.cpp:
2303         (WebCore::MediaKeySession::load):
2304         * Modules/indexeddb/IDBDatabaseIdentifier.h:
2305         (WebCore::IDBDatabaseIdentifier::hash const):
2306         * Modules/indexeddb/IDBFactory.cpp:
2307         (WebCore::IDBFactory::open):
2308         * Modules/mediastream/MediaStreamTrack.cpp:
2309         (WebCore::MediaStreamTrack::applyConstraints):
2310         * Modules/mediastream/RTCDTMFSender.cpp:
2311         (WebCore::RTCDTMFSender::insertDTMF):
2312         * Modules/webdatabase/SQLTransaction.cpp:
2313         (WebCore::SQLTransaction::executeSql):
2314         * Modules/webvr/VRFrameData.cpp:
2315         (WebCore::VRFrameData::update):
2316         * animation/AnimationTimeline.cpp:
2317         (WebCore::AnimationTimeline::updateCSSTransitionsForElement):
2318         * animation/DeclarativeAnimation.cpp:
2319         (WebCore::DeclarativeAnimation::cancel):
2320         (WebCore::DeclarativeAnimation::invalidateDOMEvents):
2321         * animation/KeyframeEffect.cpp:
2322         (WebCore::computeMissingKeyframeOffsets):
2323         (WebCore::KeyframeEffect::applyPendingAcceleratedActions):
2324         * animation/WebAnimation.cpp:
2325         (WebCore::WebAnimation::runPendingPlayTask):
2326         (WebCore::WebAnimation::runPendingPauseTask):
2327         * bindings/js/SerializedScriptValue.cpp:
2328         (WebCore::CloneSerializer::write):
2329         * crypto/algorithms/CryptoAlgorithmHMAC.cpp:
2330         (WebCore::CryptoAlgorithmHMAC::generateKey):
2331         (WebCore::CryptoAlgorithmHMAC::importKey):
2332         * crypto/gcrypt/CryptoAlgorithmAES_GCMGCrypt.cpp:
2333         (WebCore::CryptoAlgorithmAES_GCM::platformEncrypt):
2334         (WebCore::CryptoAlgorithmAES_GCM::platformDecrypt):
2335         * crypto/gcrypt/CryptoKeyRSAGCrypt.cpp:
2336         (WebCore::CryptoKeyRSA::importSpki):
2337         (WebCore::CryptoKeyRSA::importPkcs8):
2338         * crypto/keys/CryptoKeyRSA.cpp:
2339         (WebCore::CryptoKeyRSA::importJwk):
2340         * crypto/mac/CryptoAlgorithmAES_GCMMac.cpp:
2341         (WebCore::CryptoAlgorithmAES_GCM::platformEncrypt):
2342         (WebCore::CryptoAlgorithmAES_GCM::platformDecrypt):
2343         * crypto/mac/CryptoKeyRSAMac.cpp:
2344         (WebCore::CryptoKeyRSA::importSpki):
2345         (WebCore::CryptoKeyRSA::importPkcs8):
2346         * css/CSSComputedStyleDeclaration.cpp:
2347         (WebCore::counterToCSSValue):
2348         * css/CSSFontFace.cpp:
2349         (WebCore::calculateItalicRange):
2350         * css/CSSPrimitiveValue.cpp:
2351         (WebCore::CSSPrimitiveValue::doubleValue const):
2352         * css/CSSStyleSheet.cpp:
2353         (WebCore::CSSStyleSheet::addRule):
2354         * css/DOMMatrix.cpp:
2355         (WebCore::DOMMatrix::rotateSelf):
2356         * css/DOMMatrixReadOnly.cpp:
2357         (WebCore::DOMMatrixReadOnly::validateAndFixup):
2358         * css/StyleBuilderCustom.h:
2359         (WebCore::StyleBuilderCustom::applyValueCounter):
2360         * css/parser/MediaQueryParser.cpp:
2361         (WebCore::MediaQueryParser::commitMediaQuery):
2362         * dom/Document.h:
2363         (WebCore::Document::referrerPolicy const):
2364         * dom/Element.cpp:
2365         (WebCore::toScrollAlignment):
2366         * dom/EventTarget.cpp:
2367         (WebCore::EventTarget::addEventListener):
2368         * dom/MutationObserver.cpp:
2369         (WebCore::MutationObserver::observe):
2370         * editing/cocoa/FontAttributeChangesCocoa.mm:
2371         (WebCore::FontChanges::platformFontFamilyNameForCSS const):
2372         * fileapi/File.cpp:
2373         (WebCore::File::File):
2374         * html/DOMTokenList.cpp:
2375         (WebCore::DOMTokenList::toggle):
2376         * html/HTMLOListElement.h:
2377         * html/ImageBitmap.cpp:
2378         (WebCore::croppedSourceRectangleWithFormatting):
2379         * html/canvas/CanvasPattern.cpp:
2380         (WebCore::CanvasPattern::setTransform):
2381         * html/canvas/CanvasRenderingContext2DBase.cpp:
2382         (WebCore::CanvasRenderingContext2DBase::setTransform):
2383         (WebCore::CanvasRenderingContext2DBase::isPointInPathInternal):
2384         (WebCore::CanvasRenderingContext2DBase::isPointInStrokeInternal):
2385         * html/canvas/Path2D.cpp:
2386         (WebCore::Path2D::addPath):
2387         * inspector/InspectorCanvas.cpp:
2388         (WebCore::InspectorCanvas::buildAction):
2389         * inspector/InspectorFrontendHost.cpp:
2390         (WebCore::populateContextMenu):
2391         * layout/FormattingContext.cpp:
2392         (WebCore::Layout::FormattingContext::validateGeometryConstraintsAfterLayout const):
2393         * layout/FormattingContextGeometry.cpp:
2394         (WebCore::Layout::FormattingContext::Geometry::outOfFlowNonReplacedVerticalGeometry):
2395         (WebCore::Layout::FormattingContext::Geometry::outOfFlowNonReplacedHorizontalGeometry):
2396         (WebCore::Layout::FormattingContext::Geometry::outOfFlowReplacedVerticalGeometry):
2397         (WebCore::Layout::FormattingContext::Geometry::outOfFlowReplacedHorizontalGeometry):
2398         (WebCore::Layout::FormattingContext::Geometry::complicatedCases):
2399         (WebCore::Layout::FormattingContext::Geometry::inlineReplacedWidthAndMargin):
2400         (WebCore::Layout::FormattingContext::Geometry::inFlowPositionedPositionOffset):
2401         (WebCore::Layout::FormattingContext::Geometry::computedNonCollapsedHorizontalMarginValue):
2402         (WebCore::Layout::FormattingContext::Geometry::computedNonCollapsedVerticalMarginValue):
2403         * layout/FormattingContextQuirks.cpp:
2404         (WebCore::Layout::FormattingContext::Quirks::heightValueOfNearestContainingBlockWithFixedHeight):
2405         * layout/MarginTypes.h:
2406         (WebCore::Layout::VerticalMargin::usedValues const):
2407         * layout/blockformatting/BlockFormattingContextGeometry.cpp:
2408         (WebCore::Layout::BlockFormattingContext::Geometry::inFlowNonReplacedHeightAndMargin):
2409         (WebCore::Layout::BlockFormattingContext::Geometry::inFlowNonReplacedWidthAndMargin):
2410         (WebCore::Layout::BlockFormattingContext::Geometry::instrinsicWidthConstraints):
2411         * layout/blockformatting/BlockFormattingContextQuirks.cpp:
2412         (WebCore::Layout::BlockFormattingContext::Quirks::stretchedHeight):
2413         * layout/displaytree/DisplayBox.h:
2414         (WebCore::Display::Box::width const):
2415         (WebCore::Display::Box::height const):
2416         (WebCore::Display::Box::contentBoxTop const):
2417         (WebCore::Display::Box::contentBoxLeft const):
2418         * layout/floats/FloatingContext.cpp:
2419         (WebCore::Layout::Iterator::set):
2420         * layout/inlineformatting/InlineFormattingContext.cpp:
2421         (WebCore::Layout::InlineFormattingContext::appendContentToLine const):
2422         (WebCore::Layout::InlineFormattingContext::placeInFlowPositionedChildren const):
2423         * loader/FrameLoader.cpp:
2424         (WebCore::FrameLoader::urlSelected):
2425         * loader/NavigationAction.cpp:
2426         * page/FrameView.cpp:
2427         (WebCore::FrameView::setLayoutViewportOverrideRect):
2428         (WebCore::FrameView::documentToAbsoluteScaleFactor const):
2429         (WebCore::FrameView::viewportSizeForCSSViewportUnits const):
2430         * page/Page.cpp:
2431         (WebCore::Page::setLowPowerModeEnabledOverrideForTesting):
2432         * page/SecurityOriginData.cpp:
2433         (WebCore::SecurityOriginData::databaseIdentifier const):
2434         * page/SecurityOriginData.h:
2435         (WebCore::SecurityOriginDataHash::hash):
2436         * page/SecurityOriginHash.h:
2437         (WebCore::SecurityOriginHash::hash):
2438         * page/ViewportConfiguration.cpp:
2439         (WebCore::ViewportConfiguration::setViewLayoutSize):
2440         * page/WindowFeatures.cpp:
2441         (WebCore::parseDialogFeatures):
2442         * page/animation/AnimationBase.cpp:
2443         (WebCore::AnimationBase::updateStateMachine):
2444         (WebCore::AnimationBase::fireAnimationEventsIfNeeded):
2445         (WebCore::AnimationBase::getTimeToNextEvent const):
2446         (WebCore::AnimationBase::freezeAtTime):
2447         (WebCore::AnimationBase::getElapsedTime const):
2448         * page/animation/CSSAnimationController.cpp:
2449         (WebCore::CSSAnimationControllerPrivate::updateAnimationTimer):
2450         * page/cocoa/ResourceUsageThreadCocoa.mm:
2451         (WebCore::ResourceUsageThread::platformThreadBody):
2452         * page/linux/ResourceUsageThreadLinux.cpp:
2453         (WebCore::ResourceUsageThread::platformThreadBody):
2454         * platform/graphics/ComplexTextController.cpp:
2455         (WebCore::ComplexTextController::offsetForPosition):
2456         * platform/graphics/FontCache.h:
2457         (WebCore::FontDescriptionKey::computeHash const):
2458         * platform/graphics/FontCascade.cpp:
2459         (WebCore::FontCascade::drawText const):
2460         (WebCore::FontCascade::drawEmphasisMarks const):
2461         (WebCore::FontCascade::displayListForTextRun const):
2462         (WebCore::FontCascade::adjustSelectionRectForText const):
2463         (WebCore::FontCascade::codePath const):
2464         * platform/graphics/FontSelectionAlgorithm.cpp:
2465         (WebCore::FontSelectionAlgorithm::styleDistance const):
2466         * platform/graphics/FontSelectionAlgorithm.h:
2467         (WebCore::operator<<):
2468         (WebCore::FontSelectionSpecifiedCapabilities::computeWeight const):
2469         (WebCore::FontSelectionSpecifiedCapabilities::computeWidth const):
2470         (WebCore::FontSelectionSpecifiedCapabilities::computeSlope const):
2471         * platform/graphics/ShadowBlur.cpp:
2472         (WebCore::ShadowBlur::calculateLayerBoundingRect):
2473         * platform/graphics/avfoundation/cf/WebCoreAVCFResourceLoader.cpp:
2474         (WebCore::WebCoreAVCFResourceLoader::startLoading):
2475         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
2476         (WebCore::MediaPlayerPrivateAVFoundationObjC::paintWithVideoOutput):
2477         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:
2478         (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::paintCurrentFrameInContext):
2479         * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
2480         (WebCore::SourceBufferPrivateAVFObjC::naturalSize):
2481         * platform/graphics/ca/GraphicsLayerCA.cpp:
2482         (WebCore::GraphicsLayerCA::setVisibleAndCoverageRects):
2483         * platform/graphics/cocoa/FontCacheCoreText.cpp:
2484         (WebCore::preparePlatformFont):
2485         * platform/graphics/filters/FETurbulence.cpp:
2486         (WebCore::FETurbulence::fillRegion const):
2487         * platform/graphics/gstreamer/GStreamerCommon.cpp:
2488         (WebCore::initializeGStreamer):
2489         * platform/graphics/texmap/TextureMapperLayer.cpp:
2490         (WebCore::TextureMapperLayer::paintSelfAndChildrenWithReplica):
2491         (WebCore::TextureMapperLayer::replicaTransform):
2492         (WebCore::TextureMapperLayer::syncAnimations):
2493         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
2494         (WebCore::CoordinatedGraphicsLayer::transformedVisibleRect):
2495         (WebCore::CoordinatedGraphicsLayer::computeTransformedVisibleRect):
2496         * platform/graphics/transforms/TransformState.cpp:
2497         (WebCore::TransformState::mappedPoint const):
2498         (WebCore::TransformState::mapQuad const):
2499         (WebCore::TransformState::flattenWithTransform):
2500         * platform/network/CacheValidation.cpp:
2501         (WebCore::computeCurrentAge):
2502         (WebCore::computeFreshnessLifetimeForHTTPFamily):
2503         * platform/network/NetworkStateNotifier.cpp:
2504         (WebCore::NetworkStateNotifier::onLine):
2505         * rendering/FloatingObjects.cpp:
2506         (WebCore::FindNextFloatLogicalBottomAdapter::nextLogicalBottom const):
2507         (WebCore::FindNextFloatLogicalBottomAdapter::nextShapeLogicalBottom const):
2508         * rendering/GridBaselineAlignment.cpp:
2509         (WebCore::GridBaselineAlignment::ascentForChild const):
2510         * rendering/GridTrackSizingAlgorithm.cpp:
2511         (WebCore::GridTrack::setGrowthLimit):
2512         (WebCore::GridTrackSizingAlgorithm::initialBaseSize const):
2513         (WebCore::GridTrackSizingAlgorithm::initialGrowthLimit const):
2514         (WebCore::GridTrackSizingAlgorithm::sizeTrackToFitNonSpanningItem):
2515         (WebCore::sortByGridTrackGrowthPotential):
2516         (WebCore::GridTrackSizingAlgorithm::estimatedGridAreaBreadthForChild const):
2517         (WebCore::GridTrackSizingAlgorithmStrategy::minSizeForChild const):
2518         (WebCore::GridTrackSizingAlgorithm::initializeTrackSizes):
2519         * rendering/PaintInfo.h:
2520         (WebCore::PaintInfo::applyTransform):
2521         * rendering/RenderBox.cpp:
2522         (WebCore::RenderBox::computeLogicalHeight const):
2523         * rendering/RenderCounter.cpp:
2524         (WebCore::planCounter):
2525         * rendering/RenderDeprecatedFlexibleBox.cpp:
2526         (WebCore::RenderDeprecatedFlexibleBox::layoutHorizontalBox):
2527         * rendering/RenderFlexibleBox.cpp:
2528         (WebCore::RenderFlexibleBox::baselinePosition const):
2529         (WebCore::RenderFlexibleBox::marginBoxAscentForChild):
2530         (WebCore::RenderFlexibleBox::adjustChildSizeForMinAndMax):
2531         * rendering/RenderGrid.cpp:
2532         (WebCore::RenderGrid::gridGap const):
2533         (WebCore::RenderGrid::baselinePosition const):
2534         * rendering/RenderLayer.cpp:
2535         (WebCore::RenderLayer::paintLayerByApplyingTransform):
2536         * rendering/RenderListBox.cpp:
2537         (WebCore::RenderListBox::paintItem):
2538         (WebCore::RenderListBox::listIndexIsVisible):
2539         * rendering/RenderMultiColumnSet.cpp:
2540         (WebCore::RenderMultiColumnSet::calculateMaxColumnHeight const):
2541         * rendering/RenderTable.cpp:
2542         (WebCore::RenderTable::convertStyleLogicalHeightToComputedHeight):
2543         * rendering/RenderTableCell.cpp:
2544         (WebCore::RenderTableCell::cellBaselinePosition const):
2545         * rendering/RenderTableSection.cpp:
2546         (WebCore::RenderTableSection::firstLineBaseline const):
2547         * rendering/RenderText.cpp:
2548         (WebCore::RenderText::computePreferredLogicalWidths):
2549         (WebCore::RenderText::previousOffset const):
2550         (WebCore::RenderText::previousOffsetForBackwardDeletion const):
2551         (WebCore::RenderText::nextOffset const):
2552         (WebCore::RenderText::stringView const):
2553         * rendering/RenderView.cpp:
2554         (WebCore::RenderView::layout):
2555         * rendering/mathml/RenderMathMLBlock.cpp:
2556         (WebCore::RenderMathMLBlock::baselinePosition const):
2557         * rendering/mathml/RenderMathMLBlock.h:
2558         (WebCore::RenderMathMLBlock::ascentForChild):
2559         * rendering/style/GridPosition.cpp:
2560         (WebCore::GridPosition::max):
2561         * rendering/style/TextUnderlineOffset.h:
2562         (WebCore::TextUnderlineOffset::lengthOr const):
2563         * rendering/svg/RenderSVGContainer.cpp:
2564         (WebCore::RenderSVGContainer::nodeAtFloatPoint):
2565         * rendering/svg/RenderSVGForeignObject.cpp:
2566         (WebCore::RenderSVGForeignObject::nodeAtFloatPoint):
2567         * rendering/svg/RenderSVGImage.cpp:
2568         (WebCore::RenderSVGImage::nodeAtFloatPoint):
2569         * rendering/svg/RenderSVGResourceClipper.cpp:
2570         (WebCore::RenderSVGResourceClipper::hitTestClipContent):
2571         * rendering/svg/RenderSVGResourceFilter.cpp:
2572         (WebCore::RenderSVGResourceFilter::postApplyResource):
2573         * rendering/svg/RenderSVGRoot.cpp:
2574         (WebCore::RenderSVGRoot::nodeAtPoint):
2575         * rendering/svg/RenderSVGShape.cpp:
2576         (WebCore::RenderSVGShape::nodeAtFloatPoint):
2577         * rendering/svg/RenderSVGText.cpp:
2578         (WebCore::RenderSVGText::nodeAtFloatPoint):
2579         * rendering/svg/SVGRenderingContext.cpp:
2580         (WebCore::SVGRenderingContext::clipToImageBuffer):
2581         * svg/SVGToOTFFontConversion.cpp:
2582         (WebCore::SVGToOTFFontConverter::processGlyphElement):
2583         (WebCore::SVGToOTFFontConverter::SVGToOTFFontConverter):
2584
2585 2018-12-20  Jer Noble  <jer.noble@apple.com>
2586
2587         REGRESSION (r239419): heap-use-after-free in AudioSourceProviderAVFObjC::finalizeCallback()
2588         https://bugs.webkit.org/show_bug.cgi?id=192941
2589         <rdar://problem/46874096>
2590
2591         Reviewed by Brent Fulgham.
2592
2593         Don't delete the locked lock before unlocking the lock. 
2594
2595         * platform/graphics/avfoundation/AudioSourceProviderAVFObjC.mm:
2596         (WebCore::AudioSourceProviderAVFObjC::finalizeCallback):
2597
2598 2018-12-20  Keith Rollin  <krollin@apple.com>
2599
2600         Improve release-level page-load logging
2601         https://bugs.webkit.org/show_bug.cgi?id=192872
2602         <rdar://problem/46850309>
2603
2604         Reviewed by Chris Dumez.
2605
2606         There are a number of reported bugs that are difficult or impossible
2607         to track down with our current level of logging. Additionally, some
2608         software groups lower in the page-loading stack have requested logging
2609         sufficient for tracking a user-visible error message down to the
2610         requested resource that caused the message. Add more-comprehensive
2611         logging to address these issues/requests.
2612
2613         No new tests -- no changed functionality.
2614
2615         * loader/DocumentLoader.cpp:
2616         (WebCore::DocumentLoader::setMainDocumentError):
2617         (WebCore::DocumentLoader::mainReceivedError):
2618         (WebCore::DocumentLoader::stopLoading):
2619         (WebCore::DocumentLoader::notifyFinished):
2620         (WebCore::DocumentLoader::willSendRequest):
2621         (WebCore::DocumentLoader::continueAfterContentPolicy):
2622         (WebCore::DocumentLoader::startLoadingMainResource):
2623         (WebCore::DocumentLoader::loadMainResource):
2624         (WebCore::DocumentLoader::cancelMainResourceLoad):
2625         * loader/FrameLoader.cpp:
2626         (WebCore::FrameLoader::urlSelected):
2627         (WebCore::FrameLoader::loadURLIntoChildFrame):
2628         (WebCore::FrameLoader::loadArchive):
2629         (WebCore::FrameLoader::loadInSameDocument):
2630         (WebCore::FrameLoader::loadFrameRequest):
2631         (WebCore::FrameLoader::loadURL):
2632         (WebCore::FrameLoader::load):
2633         (WebCore::FrameLoader::loadWithNavigationAction):
2634         (WebCore::FrameLoader::loadWithDocumentLoader):
2635         (WebCore::FrameLoader::reloadWithOverrideEncoding):
2636         (WebCore::FrameLoader::reload):
2637         (WebCore::FrameLoader::setState):
2638         (WebCore::FrameLoader::checkLoadCompleteForThisFrame):
2639         (WebCore::FrameLoader::loadPostRequest):
2640         (WebCore::FrameLoader::continueLoadAfterNavigationPolicy):
2641         (WebCore::FrameLoader::loadDifferentDocumentItem):
2642         * loader/ProgressTracker.cpp:
2643         (WebCore::ProgressItem::ProgressItem):
2644         (WebCore::ProgressTracker::reset):
2645         (WebCore::ProgressTracker::progressStarted):
2646         (WebCore::ProgressTracker::progressCompleted):
2647         (WebCore::ProgressTracker::finalProgressComplete):
2648         (WebCore::ProgressTracker::incrementProgress):
2649         (WebCore::ProgressTracker::completeProgress):
2650         (WebCore::ProgressTracker::isAlwaysOnLoggingAllowed const):
2651         * loader/ProgressTracker.h:
2652         * loader/ResourceLoader.cpp:
2653         (WebCore::ResourceLoader::loadDataURL):
2654         (WebCore::ResourceLoader::willSendRequestInternal):
2655         (WebCore::ResourceLoader::didFinishLoading):
2656         (WebCore::ResourceLoader::didFail):
2657         (WebCore::ResourceLoader::willSendRequestAsync):
2658         (WebCore::ResourceLoader::wasBlocked):
2659         (WebCore::ResourceLoader::cannotShowURL):
2660         * loader/SubresourceLoader.cpp:
2661         (WebCore::SubresourceLoader::willSendRequestInternal):
2662         (WebCore::=):
2663         (WebCore::SubresourceLoader::didReceiveResponse):
2664         (WebCore::SubresourceLoader::didFinishLoading):
2665         (WebCore::SubresourceLoader::didFail):
2666         (WebCore::SubresourceLoader::willCancel):
2667         * loader/cache/CachedResource.cpp:
2668         (WebCore::CachedResource::load):
2669
2670 2018-12-20  Jeremy Jones  <jeremyj@apple.com>
2671
2672         Switch tabs before retuning PiP video to inline.
2673         https://bugs.webkit.org/show_bug.cgi?id=192767
2674         rdar://problem/46006046
2675
2676         Reviewed by Jer Noble.
2677
2678         No new tests because this code path only happens with a user action on system UI.
2679
2680         When exiting PiP, notify the fullscreen change observer so it can restore client UI state before exiting.
2681
2682         * platform/mac/VideoFullscreenInterfaceMac.mm:
2683         (-[WebVideoFullscreenInterfaceMacObjC pipShouldClose:]):
2684
2685 2018-12-19  Michael Catanzaro  <mcatanzaro@igalia.com>
2686
2687         Unreviewed, fix GTK build after r239410
2688
2689         It added a new file to the build, breaking the unified sources magic that obscured a bug in
2690         URLSoup.h. It forward-declares URL, but this never worked unless the URL.h header was
2691         included via another source file in the unified source bundle.
2692
2693         * platform/network/soup/URLSoup.h:
2694
2695 2018-12-19  Chris Dumez  <cdumez@apple.com>
2696
2697         wtf/Optional.h: move-constructor and move-assignment operator should disengage the value being moved from
2698         https://bugs.webkit.org/show_bug.cgi?id=192728
2699         <rdar://problem/46746779>
2700
2701         Reviewed by Geoff Garen.
2702
2703         * Modules/*:
2704         * animation/*:
2705         * bindings/*:
2706         * crypto/*:
2707         * css/*:
2708         * dom/*:
2709         * editing/*:
2710         * fileapi/*:
2711         * html/*:
2712         * inspector/*:
2713         * layout/*:
2714         * loader/*:
2715         * mathml/*:
2716         * page/*:
2717         * platform/*:
2718         * plugins/*:
2719         * rendering/*:
2720         * testing/*:
2721         * workers/*:
2722         * xml/*:
2723
2724 2018-12-19  Jer Noble  <jer.noble@apple.com>
2725
2726         Leak of MTAudioProcessingTap (304 bytes) in com.apple.WebKit.WebContent running WebKit layout tests
2727         https://bugs.webkit.org/show_bug.cgi?id=192896
2728         <rdar://46732186>
2729
2730         Reviewed by Eric Carlson.
2731
2732         * platform/graphics/avfoundation/AudioSourceProviderAVFObjC.mm:
2733         (WebCore::AudioSourceProviderAVFObjC::initCallback):
2734
2735 2018-12-19  Timothy Hatcher  <timothy@apple.com>
2736
2737         REGRESSION (r232991): Switching to dark mode in Mail does not update the message view to be transparent
2738         https://bugs.webkit.org/show_bug.cgi?id=188891
2739         rdar://problem/42344352
2740
2741         Reviewed by Simon Fraser.
2742
2743         * rendering/RenderLayerCompositor.cpp:
2744         (WebCore::RenderLayerCompositor::rootBackgroundColorOrTransparencyChanged):
2745         Don't return early when m_layerForOverhangAreas is null to avoid skipping
2746         setRootLayerConfigurationNeedsUpdate() and scheduleCompositingLayerUpdate().
2747
2748 2018-12-19  Justin Fan  <justin_fan@apple.com>
2749
2750         [WebGPU] Add stubs for WebGPUPipelineLayout/Descriptor and device::createPipelineLayout
2751         https://bugs.webkit.org/show_bug.cgi?id=192843
2752         <rdar://problem/46820395>
2753
2754         Reviewed by Myles Maxfield.
2755
2756         Test: webgpu/pipeline-layouts.html
2757
2758         Implement the emtpy WebGPUPipelineLayout interface, and enable creation via WebGPUDevice::createPipelineLayout:
2759         * Modules/webgpu/WebGPUBindGroupLayout.cpp:
2760         (WebCore::WebGPUBindGroupLayout::WebGPUBindGroupLayout):
2761         * Modules/webgpu/WebGPUBindGroupLayout.h:
2762         (WebCore::WebGPUBindGroupLayout::bindGroupLayout const): Added getter.
2763         * Modules/webgpu/WebGPUDevice.cpp:
2764         (WebCore::WebGPUDevice::createPipelineLayout const): Added.
2765         * Modules/webgpu/WebGPUDevice.h:
2766         * Modules/webgpu/WebGPUDevice.idl: Enable createPipelineLayout.
2767         * Modules/webgpu/WebGPUPipelineLayout.cpp: Added.
2768         (WebCore::WebGPUPipelineLayout::create):
2769         (WebCore::WebGPUPipelineLayout::WebGPUPipelineLayout):
2770         * Modules/webgpu/WebGPUPipelineLayout.h: Added.
2771         * Modules/webgpu/WebGPUPipelineLayout.idl: Added.
2772         * Modules/webgpu/WebGPUPipelineLayoutDescriptor.h: Added.
2773         * Modules/webgpu/WebGPUPipelineLayoutDescriptor.idl: Added.
2774         * platform/graphics/gpu/GPUDevice.cpp:
2775         (WebCore::GPUDevice::createPipelineLayout const): Added.
2776         * platform/graphics/gpu/GPUDevice.h:
2777         * platform/graphics/gpu/GPUPipelineLayout.cpp: Added.
2778         (WebCore::GPUPipelineLayout::create):
2779         (WebCore::GPUPipelineLayout::GPUPipelineLayout):
2780         * platform/graphics/gpu/GPUPipelineLayout.h: Added.
2781         * platform/graphics/gpu/GPUPipelineLayoutDescriptor.h: Added.
2782
2783         Add files and symbols to project:
2784         * CMakeLists.txt:
2785         * DerivedSources.make:
2786         * Sources.txt:
2787         * WebCore.xcodeproj/project.pbxproj:
2788         * bindings/js/WebCoreBuiltinNames.h:
2789
2790         Add missing include:
2791         * Modules/webgpu/WebGPUQueue.h:
2792
2793 2018-12-18  Ryosuke Niwa  <rniwa@webkit.org>
2794
2795         SVGUseElement::findTarget should return nullptr when there is a cycle
2796         https://bugs.webkit.org/show_bug.cgi?id=192840
2797
2798         Reviewed by Tim Horton.
2799
2800         r233366 added an early return to updateShadowTree() when there is a cycle between an use element and its target.
2801         Consolidate this cycle detection code with the one in SVGUseElement::findTarget which detected cycles when
2802         the SVG use element itself had a corresponding element.
2803
2804         No new tests since there should be no behavioral change.
2805
2806         * svg/SVGUseElement.cpp:
2807         (WebCore::SVGUseElement::updateShadowTree):
2808         (WebCore::SVGUseElement::findTarget const):
2809
2810 2018-12-19  Myles C. Maxfield  <mmaxfield@apple.com>
2811
2812         [WHLSL] Add a handwritten lexer
2813         https://bugs.webkit.org/show_bug.cgi?id=192294
2814
2815         Reviewed by Jon Lee.
2816
2817         This is infrastructure necessary for https://bugs.webkit.org/show_bug.cgi?id=192355. The
2818         implementation matches the lexing rules in the spec (specifically, the rules that start
2819         with an uppercase letter). The spec is at
2820         https://github.com/gpuweb/WHLSL/blob/master/Spec/WHLSL.g4.
2821
2822         This patch also modifies the lexer according to https://github.com/gpuweb/WHLSL/pull/283.
2823
2824         No new tests because the lexer isn't hooked up yet; there are tests in the parser,
2825         once that gets committed.
2826
2827         * Modules/webgpu/WHLSL/WHLSLLexer.cpp: Added.
2828         (WebCore::WHLSL::Lexer::Token::typeName):
2829         (WebCore::WHLSL::Lexer::recognizeKeyword):
2830         (WebCore::WHLSL::Lexer::consumeTokenFromStream):
2831         (WebCore::WHLSL::Lexer::skipWhitespaceAndComments):
2832         (WebCore::WHLSL::isWhitespace):
2833         (WebCore::WHLSL::isNewline):
2834         (WebCore::WHLSL::Lexer::skipWhitespace):
2835         (WebCore::WHLSL::Lexer::skipLineComment):
2836         (WebCore::WHLSL::Lexer::skipLongComment):
2837         (WebCore::WHLSL::Lexer::coreDecimalIntLiteral const):
2838         (WebCore::WHLSL::Lexer::decimalIntLiteral const):
2839         (WebCore::WHLSL::Lexer::decimalUintLiteral const):
2840         (WebCore::WHLSL::isHexadecimalCharacter):
2841         (WebCore::WHLSL::Lexer::coreHexadecimalIntLiteral const):
2842         (WebCore::WHLSL::Lexer::hexadecimalIntLiteral const):
2843         (WebCore::WHLSL::Lexer::hexadecimalUintLiteral const):
2844         (WebCore::WHLSL::Lexer::intLiteral const):
2845         (WebCore::WHLSL::Lexer::uintLiteral const):
2846         (WebCore::WHLSL::Lexer::digit const):
2847         (WebCore::WHLSL::Lexer::digitStar const):
2848         (WebCore::WHLSL::Lexer::character const):
2849         (WebCore::WHLSL::Lexer::coreFloatLiteralType1 const):
2850         (WebCore::WHLSL::Lexer::coreFloatLiteral const):
2851         (WebCore::WHLSL::Lexer::floatLiteral const):
2852         (WebCore::WHLSL::Lexer::validIdentifier const):
2853         (WebCore::WHLSL::Lexer::identifier const):
2854         (WebCore::WHLSL::Lexer::operatorName const):
2855         * Modules/webgpu/WHLSL/WHLSLLexer.h: Added.
2856         (WebCore::WHLSL::Lexer::Lexer):
2857         (WebCore::WHLSL::Lexer::consumeToken):
2858         (WebCore::WHLSL::Lexer::unconsumeToken):
2859         (WebCore::WHLSL::Lexer::state const):
2860         (WebCore::WHLSL::Lexer::setState):
2861         (WebCore::WHLSL::Lexer::isFullyConsumed const):
2862         (WebCore::WHLSL::Lexer::errorString):
2863         (WebCore::WHLSL::Lexer::string const):
2864         (WebCore::WHLSL::Lexer::anyCharacter const):
2865         * Sources.txt:
2866         * WebCore.xcodeproj/project.pbxproj:
2867
2868 2018-12-18  Simon Fraser  <simon.fraser@apple.com>
2869
2870         Web Inspector: Timelines: correctly label Intersection Observer callbacks
2871         https://bugs.webkit.org/show_bug.cgi?id=192669
2872         <rdar://problem/46702490>
2873
2874         Reviewed by Joseph Pecoraro.
2875
2876         Add InspectorInstrumentation::willFireObserverCallback() and use it to wrap calls
2877         to Intersection Observer, Performance Observer and Mutation Observer callbacks so 
2878         that they get correctly labeled in the Inspector timeline.
2879
2880         * dom/MutationObserver.cpp:
2881         (WebCore::MutationObserver::deliver):
2882         * en.lproj/Localizable.strings:
2883         * inspector/InspectorInstrumentation.cpp:
2884         (WebCore::InspectorInstrumentation::willFireObserverCallbackImpl):
2885         (WebCore::InspectorInstrumentation::didFireObserverCallbackImpl):
2886         * inspector/InspectorInstrumentation.h:
2887         (WebCore::InspectorInstrumentation::willFireObserverCallback):
2888         (WebCore::InspectorInstrumentation::didFireObserverCallback):
2889         * inspector/TimelineRecordFactory.cpp:
2890         (WebCore::TimelineRecordFactory::createObserverCallbackData):
2891         * inspector/TimelineRecordFactory.h:
2892         * inspector/agents/InspectorTimelineAgent.cpp:
2893         (WebCore::InspectorTimelineAgent::willFireObserverCallback):
2894         (WebCore::InspectorTimelineAgent::didFireObserverCallback):
2895         (WebCore::toProtocol):
2896         * inspector/agents/InspectorTimelineAgent.h:
2897         * page/IntersectionObserver.cpp:
2898         (WebCore::IntersectionObserver::notify):
2899         * page/PerformanceObserver.cpp:
2900         (WebCore::PerformanceObserver::deliver):
2901
2902 2018-12-19  Claudio Saavedra  <csaavedra@igalia.com>
2903
2904         ContentExtensions: DFANode.cpp:66:44: error: narrowing conversion of '-1' from 'int' to 'char' inside { }
2905         https://bugs.webkit.org/show_bug.cgi?id=192854
2906
2907         Reviewed by Alex Christensen.
2908
2909         * contentextensions/DFANode.h: Define CharRange's chars as signed
2910
2911 2018-12-19  Youenn Fablet  <youenn@apple.com>
2912
2913         Remove RTCRtpTransceiver.setDirection
2914         https://bugs.webkit.org/show_bug.cgi?id=192869
2915
2916         Reviewed by Alex Christensen.
2917
2918         Covered by rebased test.
2919
2920         * Modules/mediastream/RTCRtpTransceiver.idl:
2921
2922 2018-12-19  Jer Noble  <jer.noble@apple.com>
2923
2924         Force synchronous decode in WebCoreDecompressionSession::decodeSampleSync()
2925         https://bugs.webkit.org/show_bug.cgi?id=192856
2926         <rdar://problem/46843245>
2927
2928         Reviewed by Alex Christensen.
2929
2930         Some decoders exposed through VideoToolbox will decode asynchronously even when 
2931         kVTDecodeInfo_Asynchronous is not set. Force synchronous behavior with a Semaphore.
2932
2933         * platform/graphics/cocoa/WebCoreDecompressionSession.mm:
2934         (WebCore::WebCoreDecompressionSession::decodeSampleSync):
2935
2936 2018-12-19  Megan Gardner  <megan_gardner@apple.com>
2937
2938         Allow clients to set the navigator platform
2939         https://bugs.webkit.org/show_bug.cgi?id=192735
2940
2941         Reviewed by Tim Horton.
2942
2943         Expanded TestWebKitAPI/Tests/WebKitCocoa/WebsitePolicies.mm.
2944
2945         Lots of piping to allow the setting of a custom navigator platform.
2946
2947         * loader/DocumentLoader.h:
2948         (WebCore::DocumentLoader::setCustomNavigatorPlatform):
2949         (WebCore::DocumentLoader::customNavigatorPlatform const):
2950         * loader/FrameLoader.cpp:
2951         (WebCore::FrameLoader::navigatorPlatform const):
2952         * loader/FrameLoader.h:
2953         * page/Navigator.cpp:
2954         (WebCore::Navigator::platform const):
2955         * page/Navigator.h:
2956         * page/NavigatorBase.cpp:
2957         (WebCore::NavigatorBase::platform const):
2958         (WebCore::NavigatorBase::platform): Deleted.
2959         * page/NavigatorBase.h:
2960
2961 2018-12-19  Ryan Haddad  <ryanhaddad@apple.com>
2962
2963         Unreviewed, rolling out r239347.
2964
2965         Caused the leaks bot to hit an exception and the new test
2966         crashes on certain configurations.
2967
2968         Reverted changeset:
2969
2970         "Synchronous media query evaluation could destroy current
2971         Frame/FrameView."
2972         https://bugs.webkit.org/show_bug.cgi?id=192781
2973         https://trac.webkit.org/changeset/239347
2974
2975 2018-12-19  Truitt Savell  <tsavell@apple.com>
2976
2977         Unreviewed, rolling out r239358.
2978
2979         Revision caused imported/w3c/web-platform-tests/IndexedDB/ to
2980         crash on Debug bots
2981
2982         Reverted changeset:
2983
2984         "Clean up IndexedDB files between tests"
2985         https://bugs.webkit.org/show_bug.cgi?id=192796
2986         https://trac.webkit.org/changeset/239358
2987
2988 2018-12-19  Don Olmstead  <don.olmstead@sony.com>
2989
2990         Sync some include directories in WebCore
2991         https://bugs.webkit.org/show_bug.cgi?id=192819
2992
2993         Reviewed by Michael Catanzaro.
2994
2995         Added missing include directories around features that have only been enabled on
2996         Apple ports. Removes obsolete directories from list and moves harfbuzz directories
2997         into the freetype cmake file.
2998
2999         * CMakeLists.txt:
3000         * platform/FreeType.cmake:
3001
3002 2018-12-19  Alicia Boya García  <aboya@igalia.com>
3003
3004         [MSE] Remove unused method: stopAskingForMoreSamples()
3005         https://bugs.webkit.org/show_bug.cgi?id=192754
3006
3007         Reviewed by Xabier Rodriguez-Calvar.
3008
3009         The stopAskingForMoreSamples() method from SourceBufferPrivate is not
3010         being used by anyone. SourceBuffer is not calling it and no
3011         SourceBufferPrivate is implementing it. Let's remove that noise.
3012
3013         * platform/graphics/SourceBufferPrivate.h:
3014         (WebCore::SourceBufferPrivate::setActive):
3015         (WebCore::SourceBufferPrivate::stopAskingForMoreSamples): Deleted.
3016         * platform/graphics/gstreamer/mse/SourceBufferPrivateGStreamer.cpp:
3017         (WebCore::SourceBufferPrivateGStreamer::stopAskingForMoreSamples): Deleted.
3018         * platform/graphics/gstreamer/mse/SourceBufferPrivateGStreamer.h:
3019
3020 2018-12-19  Alicia Boya García  <aboya@igalia.com>
3021
3022         [MSE] Remove dead code: sourceBufferPrivateSeekToTime()
3023         https://bugs.webkit.org/show_bug.cgi?id=192827
3024
3025         Reviewed by Xabier Rodriguez-Calvar.
3026
3027         This patch makes two dead code removal changes in
3028         SourceBufferPrivateClient:
3029
3030         First, sourceBufferPrivateFastSeekTimeForMediaTime() is made pure
3031         virtual in SourceBufferPrivateClient. Since SourceBufferPrivateClient
3032         is only inherited by SourceBuffer, it makes no sense to have default
3033         implementations there (they will never be used), moreso it being a
3034         client interface.
3035
3036         Second, sourceBufferPrivateSeekToTime() is removed entirely. It used
3037         to had an empty implementation, which SourceBuffer did not overwrite,
3038         therefore making any calls to it useless.
3039
3040         All calls to sourceBufferPrivateSeekToTime() have been removed:
3041
3042         SourceBufferPrivateAVFObjC::seekToTime(), which was also dead code
3043         itself, used to call this method. This patch deletes it completely.
3044
3045         MockSourceBufferPrivate::seekToTime(), which only called this empty
3046         method, has also been removed along with its only usage in
3047         MockMediaSourcePrivate::seekToTime().
3048
3049         * platform/graphics/SourceBufferPrivateClient.h:
3050         (WebCore::SourceBufferPrivateClient::sourceBufferPrivateFastSeekTimeForMediaTime): Deleted.
3051         (WebCore::SourceBufferPrivateClient::sourceBufferPrivateSeekToTime): Deleted.
3052         * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h:
3053         * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
3054         (WebCore::SourceBufferPrivateAVFObjC::seekToTime): Deleted.
3055         * platform/mock/mediasource/MockMediaSourcePrivate.cpp:
3056         (WebCore::MockMediaSourcePrivate::seekToTime):
3057         * platform/mock/mediasource/MockSourceBufferPrivate.cpp:
3058         (WebCore::MockSourceBufferPrivate::seekToTime): Deleted.
3059         * platform/mock/mediasource/MockSourceBufferPrivate.h:
3060
3061 2018-12-19  Xabier Rodriguez Calvar  <calvaris@igalia.com>
3062
3063         [EME] MediaKeySystemConfiguration distinctiveIdentifier and persistentState should default to optional
3064         https://bugs.webkit.org/show_bug.cgi?id=192815
3065
3066         Reviewed by Jer Noble.
3067
3068         https://www.w3.org/TR/encrypted-media/#dom-mediakeysystemconfiguration
3069         says that distinctiveIdentifier and persistentState default to
3070         optional. Our implementation does not define a default leaving it
3071         to the first option of the enum, which currently is Required.
3072
3073         * platform/encryptedmedia/CDMKeySystemConfiguration.h:
3074
3075 2018-12-19  Rob Buis  <rbuis@igalia.com>
3076
3077         Merge parseAccessControlExposeHeadersAllowList into parseAccessControlAllowList
3078         https://bugs.webkit.org/show_bug.cgi?id=192288
3079
3080         Reviewed by Frédéric Wang.
3081
3082         Prefer return value to out parameter for parseAccessControlAllowList.
3083
3084         * loader/CrossOriginPreflightResultCache.cpp:
3085         (WebCore::CrossOriginPreflightResultCacheItem::parse):
3086         * platform/network/HTTPParsers.h:
3087         (WebCore::parseAccessControlAllowList):
3088         * platform/network/ResourceResponseBase.cpp:
3089         (WebCore::ResourceResponseBase::filter):
3090         (WebCore::ResourceResponseBase::sanitizeHTTPHeaderFieldsAccordingToTainting):
3091
3092 2018-12-18  Zan Dobersek  <zdobersek@igalia.com>
3093
3094         REGRESSION(r235165): [GTK][WPE] Garbled rendering on GitLab
3095         https://bugs.webkit.org/show_bug.cgi?id=192230
3096
3097         Reviewed by Carlos Garcia Campos.
3098
3099         Single tile can after r235165 be assigned multiple content updates
3100         without a commit occurring between each update, whereas before these
3101         commits were done for each update.
3102
3103         To avoid repeating updates for a single tile purging information about
3104         the previous update, these updates are now accumulated inside a Vector
3105         and then iterated over during the commit phase.
3106
3107         * platform/graphics/texmap/coordinated/CoordinatedBackingStore.cpp:
3108         (WebCore::CoordinatedBackingStoreTile::addUpdate):
3109         (WebCore::CoordinatedBackingStoreTile::swapBuffers):
3110         (WebCore::CoordinatedBackingStore::updateTile):
3111         (WebCore::CoordinatedBackingStoreTile::setBackBuffer): Deleted.
3112         * platform/graphics/texmap/coordinated/CoordinatedBackingStore.h:
3113         (WebCore::CoordinatedBackingStoreTile::scale const):
3114
3115 2018-12-18  Wenson Hsieh  <wenson_hsieh@apple.com>
3116
3117         [iOS] A copied text selection is pasted as a web archive attachment in the entry view in Messages
3118         https://bugs.webkit.org/show_bug.cgi?id=192842
3119         <rdar://problem/46823586>
3120
3121         Reviewed by Tim Horton.
3122
3123         Temporarily revert a behavior change introduced by r238661, where we now add "com.apple.webarchive" as a
3124         registered UTI when dragging or copying a text selection. This broke the Messages app on iOS, which currently
3125         inserts a copied or dragged text selection from WebKit-based views as a web archive file attachment. A fix for
3126         this is internally tracked in <rdar://problem/46830277>.
3127
3128         * platform/ios/PlatformPasteboardIOS.mm:
3129         (WebCore::PlatformPasteboard::write):
3130
3131 2018-12-18  Michael Catanzaro  <mcatanzaro@igalia.com>
3132
3133         Unreviewed, add a missing UNUSED_PARAM()
3134
3135         * Modules/mediarecorder/MediaRecorder.cpp:
3136         (WebCore::MediaRecorder::getPrivateImpl):
3137
3138 2018-12-18  Justin Michaud  <justin_michaud@apple.com>
3139
3140         Update CSS Properties and Values API to use new cycle fallback behaviour
3141         https://bugs.webkit.org/show_bug.cgi?id=192800
3142
3143         Reviewed by Antti Koivisto.
3144
3145         Make CSS variables that are registered and involved in a cycle be treated as invalid. This also fixes a crash in the
3146         wpt tests where relative units and calc() in a registered property's initial value would break things instead of failing. 
3147
3148         * css/CSSCustomPropertyValue.h:
3149         * css/CSSVariableReferenceValue.cpp:
3150         (WebCore::resolveVariableReference):
3151         * css/DOMCSSRegisterCustomProperty.cpp:
3152         (WebCore::DOMCSSRegisterCustomProperty::registerProperty):
3153         * css/StyleResolver.cpp:
3154         (WebCore::StyleResolver::applyCascadedCustomProperty):
3155         * css/parser/CSSPropertyParser.cpp:
3156         (WebCore::CSSPropertyParser::parseTypedCustomPropertyValue):
3157
3158 2018-12-18  Daniel Bates  <dabates@apple.com>
3159
3160         Wrong value for key property in keydown and keyup events generated holding Control key
3161         https://bugs.webkit.org/show_bug.cgi?id=192788
3162         <rdar://problem/46795214>
3163
3164         Reviewed by Wenson Hsieh.
3165
3166         Similar to what we do on Mac, compute the DOM key property from the characters ignoring
3167         modifier keys input string when the Control key is held down.
3168
3169         * platform/ios/PlatformEventFactoryIOS.mm:
3170         (WebCore::keyForKeyEvent):
3171         * platform/mac/PlatformEventFactoryMac.mm:
3172         (WebCore::keyForKeyEvent):
3173
3174 2018-12-18  Sihui Liu  <sihui_liu@apple.com>
3175
3176         Clean up IndexedDB files between tests
3177         https://bugs.webkit.org/show_bug.cgi?id=192796
3178
3179         Reviewed by Geoffrey Garen.
3180
3181         We should clean up the IndexedDB files between tests to make sure each test is independent of others.
3182
3183         This patch also fixes some issues in IDB.
3184
3185         Covered by existing tests.
3186
3187         * Modules/indexeddb/server/IDBServer.cpp:
3188         (WebCore::IDBServer::IDBServer::closeAndDeleteDatabasesModifiedSince):
3189         We should shut down all open databases instead of databases from open database connections before deleting 
3190         files, because database starts accessing files before connection to database is established.
3191
3192         * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
3193         (WebCore::IDBServer::UniqueIDBDatabase::shutdownForClose):
3194         We should shutdown database after tasks in queue are completed, because tasks have pointer of UniqueIDBDatabase 
3195         and UniqueIDBDatabase can be destructed after shutdown.
3196
3197         (WebCore::IDBServer::UniqueIDBDatabase::didDeleteBackingStore):
3198         didDeleteBackingStore can be posted to main thread after immediateCloseForUserDelete, and timer should not be 
3199         invoked during the hard close.
3200
3201         (WebCore::IDBServer::UniqueIDBDatabase::handleDatabaseOperations):
3202         Tasks like didOpenBackingStore could be posted from database thread to main thread after 
3203         immediateCloseForUserDelete, but we know the backing store will be deleted soon, so no need to handle any 
3204         database operation. 
3205
3206         (WebCore::IDBServer::UniqueIDBDatabase::performPrefetchCursor):
3207         performPrefetchCursor needs to be aware of whether UniqueIDBDatabase is being closed, so that it will not access 
3208         m_backingStore when m_backingStore may already be deleted. 
3209
3210         (WebCore::IDBServer::UniqueIDBDatabase::immediateCloseForUserDelete):
3211         immediateCloseForUserDelete does not handle transactions that are in the process of commit or abort. 
3212         m_objectStoreTransactionCounts and m_objectStoreWriteTransactions may be used by those transactions in 
3213         transactionCompleted, so they do not need to be cleared here.
3214
3215 2018-12-18  Myles C. Maxfield  <mmaxfield@apple.com>
3216
3217         Thick overlines and line-throughs grow in the wrong direction
3218         https://bugs.webkit.org/show_bug.cgi?id=192264
3219
3220         Reviewed by Dean Jackson.
3221
3222         Overlines should grow upward, and line-throughs should stay centered.
3223
3224         Test: fast/css3-text/css3-text-decoration/text-decoration-thicknes-overline-grow-direction.html
3225
3226         * rendering/TextDecorationPainter.cpp:
3227         (WebCore::TextDecorationPainter::paintTextDecoration):
3228         * style/InlineTextBoxStyle.cpp:
3229         (WebCore::visualOverflowForDecorations):
3230
3231 2018-12-18  Ryosuke Niwa  <rniwa@webkit.org>
3232
3233         Some iOS app crash in FrameLoader::checkCompleted
3234         https://bugs.webkit.org/show_bug.cgi?id=192804
3235         <rdar://problem/44240573>
3236
3237         Reviewed by Tim Horton.
3238
3239         It's possible for the main thread to call into WebCore / UIWebView selectors while Web thread
3240         is trying to send a delegate message. Disable the release assertion while this is happening
3241         so that iOS app would not crash.
3242
3243         Unfortunately no new test as there is no way to easily test UIWebView in iOS,
3244         and this requires a race between the web thread & the main thread.
3245
3246         * dom/ScriptDisallowedScope.h:
3247         (WebCore::ScriptDisallowedScope::InMainThread::isScriptAllowed):
3248         * platform/ios/wak/WebCoreThread.h:
3249         * platform/ios/wak/WebCoreThread.mm:
3250         (WebThreadDelegateMessageScope::WebThreadDelegateMessageScope):
3251         (WebThreadDelegateMessageScope::~WebThreadDelegateMessageScope):
3252         (SendDelegateMessage):
3253
3254 2018-12-18  David Kilzer  <ddkilzer@apple.com>
3255
3256         clang-tidy: Use const reference for MediaTime parameter to prevent object copy
3257         <https://webkit.org/b/192814>
3258
3259         Reviewed by Mark Lam.
3260
3261         * bindings/js/JSDOMConvertNumbers.h:
3262         (WebCore::JSConverter<IDLUnrestrictedDouble>::convert):
3263
3264 2018-12-18  Justin Fan  <justin_fan@apple.com>
3265
3266         [WebGPU] BindGroupLayout and Device::createBindGroupLayout
3267         https://bugs.webkit.org/show_bug.cgi?id=192817
3268
3269         Reviewed by Dean Jackson.
3270
3271         Update bind-group-layouts to test new functionality.
3272
3273         Implement the emtpy WebGPUBindGroupLayout interface, and enable creation via WebGPUDevice::createBindGroupLayout:
3274         * Modules/webgpu/WebGPUBindGroupLayout.cpp: Added.
3275         (WebCore::WebGPUBindGroupLayout::create):
3276         (WebCore::WebGPUBindGroupLayout::WebGPUBindGroupLayout):
3277         * Modules/webgpu/WebGPUBindGroupLayout.h: Added.
3278         * Modules/webgpu/WebGPUBindGroupLayout.idl: Added. Empty interface for now.
3279         * Modules/webgpu/WebGPUDevice.cpp:
3280         (WebCore::WebGPUDevice::createBindGroupLayout const): Added.
3281         * Modules/webgpu/WebGPUDevice.h:
3282         * Modules/webgpu/WebGPUDevice.idl:
3283         * platform/graphics/gpu/GPUBindGroupLayout.cpp: Added.
3284         (WebCore::GPUBindGroupLayout::tryCreate):
3285         (WebCore::GPUBindGroupLayout::GPUBindGroupLayout):
3286         * platform/graphics/gpu/GPUBindGroupLayout.h: Added.
3287         * platform/graphics/gpu/GPUDevice.cpp:
3288         (WebCore::GPUDevice::tryCreateBindGroupLayout const): Added.
3289         * platform/graphics/gpu/GPUDevice.h:
3290
3291         Add files and symbols to project:
3292         * CMakeLists.txt:
3293         * DerivedSources.make:
3294         * Sources.txt:
3295         * WebCore.xcodeproj/project.pbxproj:
3296         * bindings/js/WebCoreBuiltinNames.h:
3297
3298         Missing includes that were previously provided via UnifiedSources:
3299         * platform/mediarecorder/cocoa/MediaRecorderPrivateWriterCocoa.h:
3300         * platform/sql/SQLiteFileSystem.h:
3301
3302 2018-12-18  Youenn Fablet  <youenn@apple.com>
3303
3304         Make ReadableStreamXX constructs use PrivateIdentifier
3305         https://bugs.webkit.org/show_bug.cgi?id=192771
3306
3307         Reviewed by Chris Dumez.
3308
3309         PrivateIdentifier is a better name for making sure a given construct does not show up in the global scope.
3310         Covered by existing binding tests.
3311
3312         * Modules/streams/ReadableByteStreamController.idl:
3313         * Modules/streams/ReadableStreamBYOBReader.idl:
3314         * Modules/streams/ReadableStreamBYOBRequest.idl:
3315         * Modules/streams/ReadableStreamDefaultController.idl:
3316         * Modules/streams/ReadableStreamDefaultReader.idl:
3317         * bindings/scripts/CodeGeneratorJS.pm:
3318         (NeedsConstructorProperty):
3319         * bindings/scripts/preprocess-idls.pl:
3320         (shouldExposeInterface):
3321         * bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp: Removed.
3322         * bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.h: Removed.
3323         * bindings/scripts/test/TestCustomConstructor.idl: Removed.
3324
3325 2018-12-18  Zalan Bujtas  <zalan@apple.com>
3326
3327         Synchronous media query evaluation could destroy current Frame/FrameView.
3328         https://bugs.webkit.org/show_bug.cgi?id=192781
3329         <rdar://problem/34416793>
3330
3331         Reviewed by Chris Dumez.
3332
3333         Protect Frame and FrameView when coming back from printing and check if the current Frame/FrameView/FrameLoader objects are still valid.
3334
3335         Test: printing/print-with-media-query-destory.html
3336
3337         * loader/DocumentLoader.cpp:
3338         (WebCore::DocumentLoader::finishedLoading):
3339         * page/Frame.cpp:
3340         (WebCore::Frame::setPrinting):
3341         * page/FrameView.cpp:
3342         (WebCore::FrameView::forceLayoutForPagination):
3343
3344 2018-12-18  Joseph Pecoraro  <pecoraro@apple.com>
3345
3346         Web Inspector: m3u8 content not shown, it should be text
3347         https://bugs.webkit.org/show_bug.cgi?id=192731
3348         <rdar://problem/46747728>
3349
3350         Reviewed by Devin Rousso.
3351
3352         * inspector/NetworkResourcesData.cpp:
3353         (WebCore::NetworkResourcesData::setResourceContent):
3354         Don't clobber data if setting empty content on a resource that has content.
3355
3356         * inspector/agents/InspectorNetworkAgent.cpp:
3357         (WebCore::InspectorNetworkAgent::shouldTreatAsText):
3358         Additional non-"text/" mime types that can be treated as text.
3359
3360         * platform/MIMETypeRegistry.cpp:
3361         (WebCore::MIMETypeRegistry::isTextMediaPlaylistMIMEType):
3362         * platform/MIMETypeRegistry.h:
3363         Detect media playlist mime types that are text (m3u8/m3u).
3364
3365 2018-12-18  Daniel Bates  <dabates@apple.com>
3366
3367         Remove <meta http-equiv=set-cookie> support
3368         https://bugs.webkit.org/show_bug.cgi?id=185077
3369         <rdar://problem/41791397>
3370
3371         Reviewed by Brent Fulgham.
3372
3373         Remove support for the HTTP-equiv. pragma Set-Cookie to set a cookie. In <https://github.com/whatwg/html/pull/3649>
3374         the HTML living standard was ammended to define this pragma as no-op. Chrome and Edge have also
3375         removed support for this pragma and Firefox has an open bug to remove it.
3376
3377         * dom/Document.cpp:
3378         (WebCore::Document::processHttpEquiv): Emit a message that the Set-Cookie pragma is obsolete and
3379         was ignored instead of setting the cookie.
3380         * html/parser/XSSAuditor.cpp:
3381         (WebCore::isDangerousHTTPEquiv): We no longer need to consider the Set-Cookie pragma
3382         as dangerous and erase attribute http-equiv when we find it because we no longer honor
3383         this pragma.
3384
3385 2018-12-18  Justin Michaud  <justin_michaud@apple.com>
3386
3387         CSS Typed OM should expose attributeStyleMap
3388         https://bugs.webkit.org/show_bug.cgi?id=192671
3389
3390         Reviewed by Ryosuke Niwa.
3391
3392         Exposes element.attributeStyleMap, adds a stub for the StylePropertyMap class, and updates the existing
3393         TypedOMCSSImageValue to not require a RenderObject so that it can still work inside attributeStyleMap.
3394
3395         Test: css-typedom/attributeStyleMap.html
3396
3397         * CMakeLists.txt:
3398         * DerivedSources.make:
3399         * Sources.txt:
3400         * WebCore.xcodeproj/project.pbxproj:
3401         * bindings/js/WebCoreBuiltinNames.h:
3402         * css/ElementCSSInlineStyle.idl:
3403         * css/typedom/StylePropertyMap.h: Copied from Source/WebCore/css/typedom/StylePropertyMapReadOnly.h.
3404         * css/typedom/StylePropertyMap.idl: Copied from Source/WebCore/css/typedom/StylePropertyMapReadOnly.idl.
3405         * css/typedom/StylePropertyMapReadOnly.cpp: Added.
3406         (WebCore::StylePropertyMapReadOnly::reifyValue):
3407         (WebCore::StylePropertyMapReadOnly::customPropertyValueOrDefault):
3408         * css/typedom/StylePropertyMapReadOnly.h:
3409         (WebCore::StylePropertyMapReadOnly::create): Deleted.
3410         (WebCore::StylePropertyMapReadOnly::get const): Deleted.
3411         (WebCore::StylePropertyMapReadOnly::StylePropertyMapReadOnly): Deleted.
3412         * css/typedom/StylePropertyMapReadOnly.idl:
3413         * css/typedom/TypedOMCSSImageValue.h:
3414         * dom/Element.cpp:
3415         (WebCore::Element::attributeStyleMap):
3416         (WebCore::Element::setAttributeStyleMap):
3417         * dom/Element.h:
3418         * dom/ElementRareData.cpp:
3419         * dom/ElementRareData.h:
3420         (WebCore::ElementRareData::attributeStyleMap):
3421         (WebCore::ElementRareData::setAttributeStyleMap):
3422         * dom/StyledElement.cpp:
3423         (WebCore::StyledElement::ensureAttributeStyleMap):
3424         * dom/StyledElement.h:
3425         * html/canvas/CanvasRenderingContext2DBase.cpp:
3426         (WebCore::size):
3427         (WebCore::CanvasRenderingContext2DBase::drawImage):
3428         * platform/graphics/CustomPaintImage.cpp:
3429         (WebCore::extractComputedProperty):
3430         (WebCore::CustomPaintImage::doCustomPaint):
3431
3432 2018-12-18  Wenson Hsieh  <wenson_hsieh@apple.com>
3433
3434         Calling setValue() while typing should invoke -textDidChangeInTextField in the injected bundle
3435         https://bugs.webkit.org/show_bug.cgi?id=192785
3436         <rdar://problem/45321184>
3437
3438         Reviewed by Tim Horton.
3439
3440         Makes a minor adjustment in `TextFieldInputType::setValue` to consider value changes as "user editing", if we're
3441         currently processing a keystroke from the user. This is useful for certain private clients, such as Safari, that
3442         need to know when the user is typing in a text form control, but the page is preventing default text insertion
3443         behavior and instead updating values programmatically.
3444
3445         Test: fast/forms/call-text-did-change-in-text-field-when-typing.html
3446
3447         * html/TextFieldInputType.cpp:
3448         (WebCore::TextFieldInputType::setValue):
3449
3450 2018-12-18  Zalan Bujtas  <zalan@apple.com>
3451
3452         [LFC][BFC][MarginCollapsing] Implement marginBeforeCollapsesWithParentMarginAfter
3453         https://bugs.webkit.org/show_bug.cgi?id=192801
3454
3455         Reviewed by Antti Koivisto.
3456
3457         * layout/blockformatting/BlockFormattingContext.h:
3458         * layout/blockformatting/BlockFormattingContextGeometry.cpp:
3459         (WebCore::Layout::BlockFormattingContext::Geometry::inFlowNonReplacedHeightAndMargin):
3460         * layout/blockformatting/BlockMarginCollapse.cpp:
3461         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginBeforeCollapsesWithParentMarginAfter):
3462
3463 2018-12-18  Zalan Bujtas  <zalan@apple.com>
3464
3465         [LFC][BFC][MarginCollapsing] Implement marginAfterCollapsesWithSiblingMarginBeforeWithClearance
3466         https://bugs.webkit.org/show_bug.cgi?id=192799
3467
3468         Reviewed by Antti Koivisto.
3469
3470         * layout/blockformatting/BlockFormattingContext.h:
3471         * layout/blockformatting/BlockMarginCollapse.cpp:
3472         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginAfterCollapsesWithSiblingMarginBeforeWithClearance):
3473         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginAfterCollapsesWithParentMarginAfter):
3474
3475 2018-12-18  Zalan Bujtas  <zalan@apple.com>
3476
3477         [LFC][BFC][MarginCollapsing] Implement marginAfterCollapsesWithParentMarginBefore
3478         https://bugs.webkit.org/show_bug.cgi?id=192798
3479
3480         Reviewed by Antti Koivisto.
3481
3482         * layout/blockformatting/BlockFormattingContext.h:
3483         * layout/blockformatting/BlockFormattingContextGeometry.cpp:
3484         (WebCore::Layout::BlockFormattingContext::Geometry::inFlowNonReplacedHeightAndMargin):
3485         * layout/blockformatting/BlockMarginCollapse.cpp:
3486         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::collapsedMarginAfterFromLastChild):
3487         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginAfterCollapsesWithParentMarginBefore):
3488         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginAfterCollapsesWithParentMarginAfter):
3489         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginAfter):
3490
3491 2018-12-18  Zalan Bujtas  <zalan@apple.com>
3492
3493         [LFC][BFC][MarginCollapsing] Expand marginsCollapseThrough collapsing logic
3494         https://bugs.webkit.org/show_bug.cgi?id=192794
3495
3496         Reviewed by Antti Koivisto.
3497
3498         * layout/blockformatting/BlockFormattingContext.h:
3499         * layout/blockformatting/BlockMarginCollapse.cpp:
3500         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginsCollapseThrough):
3501         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginBefore):
3502         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginAfter):
3503
3504 2018-12-18  Zalan Bujtas  <zalan@apple.com>
3505
3506         [LFC][BFC][MarginCollapsing] Expand marginAfterCollapsesWithNextSibling and marginBeforeCollapsesWithPreviousSibling collapsing logic
3507         https://bugs.webkit.org/show_bug.cgi?id=192791
3508
3509         Reviewed by Antti Koivisto.
3510
3511         * layout/blockformatting/BlockMarginCollapse.cpp:
3512         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginBeforeCollapsesWithPreviousSibling):
3513         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginAfterCollapsesWithNextSibling):
3514
3515 2018-12-18  Zalan Bujtas  <zalan@apple.com>
3516
3517         [LFC][BFC][MarginCollapsing] Expand marginAfterCollapsesWithParentMarginAfter and marginBeforeCollapsesWithParentMarginBefore collapsing logic
3518         https://bugs.webkit.org/show_bug.cgi?id=192787
3519
3520         Reviewed by Antti Koivisto.
3521
3522         * layout/blockformatting/BlockFormattingContext.h:
3523         * layout/blockformatting/BlockMarginCollapse.cpp:
3524         (WebCore::Layout::hasClearance):
3525         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginBeforeCollapsesWithParentMarginBefore):
3526         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginAfterCollapsesWithSiblingMarginBeforeWithClearance):
3527         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginAfterCollapsesWithParentMarginBefore):
3528         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginAfterCollapsesWithParentMarginAfter):
3529
3530 2018-12-17  Fujii Hironori  <Hironori.Fujii@sony.com>
3531
3532         [Win][Clang] Fix compilation warnings WebCore/platform/graphics directory
3533         https://bugs.webkit.org/show_bug.cgi?id=192752
3534
3535         Reviewed by Don Olmstead.
3536
3537         No new tests, no behavior changes.
3538
3539         * platform/graphics/win/DIBPixelData.cpp:
3540         Enclosed bitmapType and bitmapPixelsPerMeter with #ifndef NDEBUG.
3541         * platform/graphics/win/FontPlatformDataWin.cpp:
3542         (WebCore::FontPlatformData::openTypeTable const): Use ASSERT_UNUSED instead of ASSERT.
3543         * platform/graphics/win/GraphicsContextWin.cpp: Removed unused variable 'deg2rad'.
3544         * platform/graphics/win/MediaPlayerPrivateMediaFoundation.cpp:
3545         Removed unused soft links MFCreateSampleGrabberSinkActivate, MFCreateMemoryBuffer and MFCreateSample.
3546         (WebCore::MediaPlayerPrivateMediaFoundation::MediaPlayerPrivateMediaFoundation):
3547         Reorder the initializer list.
3548         (WebCore::MediaPlayerPrivateMediaFoundation::seek): Use ASSERT_UNUSED instead of ASSERT.
3549         (WebCore::MediaPlayerPrivateMediaFoundation::setAllChannelVolumes): Ditto.
3550         (WebCore::MediaPlayerPrivateMediaFoundation::createSession): Ditto.
3551         (WebCore::MediaPlayerPrivateMediaFoundation::endSession): Ditto.
3552         (WebCore::MediaPlayerPrivateMediaFoundation::onCreatedMediaSource): Ditto.
3553         (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::paintCurrentFrame): Added default case.
3554         * platform/graphics/win/SimpleFontDataCairoWin.cpp:
3555         (WebCore::Font::platformBoundsForGlyph const): Use inner braces to initialize subobjects of MAT2.
3556         * platform/graphics/win/SimpleFontDataWin.cpp: Removed unused 'cSmallCapsFontSizeMultiplier'.
3557         (WebCore::Font::initGDIFont): Use inner braces to initialize subobjects of MAT2.
3558         (WebCore::Font::boundsForGDIGlyph const): Ditto.
3559         (WebCore::Font::widthForGDIGlyph const): Ditto.
3560         * platform/graphics/win/UniscribeController.cpp:
3561         (WebCore::UniscribeController::UniscribeController):
3562         Reorder the initializer list.
3563         (WebCore::UniscribeController::offsetForPosition): Use parentheses to combine && and ||.
3564         (WebCore::UniscribeController::shapeAndPlaceItem): Removed unused 'glyphCount'.
3565
3566 2018-12-17  Eric Carlson  <eric.carlson@apple.com>
3567
3568         [MediaStream] A stream's first video frame should be rendered
3569         https://bugs.webkit.org/show_bug.cgi?id=192629
3570         <rdar://problem/46664353>
3571
3572         Reviewed by Youenn Fablet.
3573
3574         Test: fast/mediastream/media-stream-renders-first-frame.html
3575
3576         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.h:
3577         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:
3578         (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::enqueueVideoSample):
3579         (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::ensureLayers):
3580         (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::currentDisplayMode const):
3581         (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::updateDisplayMode):
3582         (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::play):
3583         (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::currentReadyState):
3584         (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::characteristicsChanged):
3585         (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::checkSelectedVideoTrack):
3586         (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::paintCurrentFrameInContext):
3587         * platform/mediastream/RealtimeMediaSource.cpp:
3588         (WebCore::RealtimeMediaSource::size const):
3589         * platform/mediastream/mac/AVVideoCaptureSource.mm:
3590         (WebCore::AVVideoCaptureSource::processNewFrame):
3591         * platform/mediastream/mac/RealtimeIncomingVideoSourceCocoa.mm:
3592         (WebCore::RealtimeIncomingVideoSourceCocoa::processNewSample):
3593
3594 2018-12-17  Justin Michaud  <justin_michaud@apple.com>
3595
3596         Bindings generator should support Conditional= along with CachedAttribute
3597         https://bugs.webkit.org/show_bug.cgi?id=192721
3598
3599         Reviewed by Ryosuke Niwa.
3600
3601         Fix a bug where specifying both attributes causes compilation errors because the compile-time
3602         condition is not included in the derived code.
3603
3604         * bindings/scripts/CodeGeneratorJS.pm:
3605         (GenerateImplementation):
3606         * bindings/scripts/test/JS/JSTestObj.cpp:
3607         (WebCore::jsTestObjCachedAttribute3Getter):
3608         (WebCore::jsTestObjCachedAttribute3):
3609         (WebCore::JSTestObj::visitChildren):
3610         * bindings/scripts/test/JS/JSTestObj.h:
3611         * bindings/scripts/test/TestObj.idl:
3612
3613 2018-12-17  David Kilzer  <ddkilzer@apple.com>
3614
3615         clang-tidy: Fix unnecessary object copy in CPUMonitor::setCPULimit()
3616         <https://webkit.org/b/192707>
3617         <rdar://problem/46734926>
3618
3619         Reviewed by Daniel Bates.
3620
3621         * platform/CPUMonitor.cpp:
3622         (WebCore::CPUMonitor::setCPULimit):
3623         * platform/CPUMonitor.h:
3624         (WebCore::CPUMonitor::setCPULimit):
3625         - Change parameter to const reference to fix unnecessary copies.
3626
3627 2018-12-17  Ryosuke Niwa  <rniwa@webkit.org>
3628
3629         offsetLeft and offsetParent should adjust across shadow boundaries
3630         https://bugs.webkit.org/show_bug.cgi?id=157437
3631         <rdar://problem/26154021>
3632
3633         Reviewed by Simon Fraser.
3634
3635         Update the WebKit's treatment of shadow boundaries in offsetLeft, offsetTop, and offsetParent to match
3636         the latest discussion in CSS WG. See https://github.com/w3c/webcomponents/issues/497
3637         and https://github.com/w3c/webcomponents/issues/763
3638
3639         The latest consensus is to use the retargeting algorithm (https://dom.spec.whatwg.org/#retarget).
3640         In practice, this would mean that we need to keep walking up the offset parent ancestors until we find
3641         the one which is in the same tree as a shadow-inclusive ancestor of the context object.
3642
3643         For example, if a node (the context object of offsetTop, offsetLeft, offsetParent) was assigned to a slot
3644         inside a shadow tree and its offset parent was in the shadow tree, we need to walk up to its offset parent,
3645         then its offset parent, etc... until we find the offset parent in the same tree as the context object.
3646
3647         Note it's possible that the context object is inside a shadow tree which does not have its own offset parent.
3648         (e.g. all elements have position: static) For this reason, we need to consider not just offset parent in
3649         the same tree as the context object but as well as any offset parent which is in its ancestor trees.
3650
3651         Test: fast/shadow-dom/offsetParent-across-shadow-boundaries.html
3652
3653         * dom/Element.cpp:
3654         (WebCore::adjustOffsetForZoomAndSubpixelLayout): Extracted to share code between offsetLeft and offsetTop.
3655         (WebCore::collectAncestorTreeScopeAsHashSet): Added.
3656         (WebCore::Element::offsetLeftForBindings): Added. Sums up offsetLeft's until it finds the first offset parent
3657         which is a shadow-including ancestor (https://dom.spec.whatwg.org/#concept-shadow-including-ancestor).
3658         (WebCore::Element::offsetLeft): Now uses adjustOffsetForZoomAndSubpixelLayout.
3659         (WebCore::Element::offsetTopForBindings): Added. Like offsetLeftForBindings, this function sums up offsetTop's
3660         until it finds the first offset parent which is a shadow-including ancestor.
3661         (WebCore::Element::offsetTop): Now uses adjustOffsetForZoomAndSubpixelLayout.
3662         (WebCore::Element::offsetParentForBindings): Renamed from bindingsOffsetParent to be consistent with other
3663         functions meant to be used for bindings code.
3664         * dom/Element.h:
3665         * html/HTMLElement.idl:
3666
3667 2018-12-17  Simon Fraser  <simon.fraser@apple.com>
3668
3669         Don't use more expensive layer backing store formats when subpixel text antialiasing is not enabled
3670         https://bugs.webkit.org/show_bug.cgi?id=192780
3671         rdar://problem/43394387
3672
3673         Reviewed by Tim Horton.
3674         
3675         macOS Mojave disabled text subpixel antialiasing by default, so we no longer need to use the
3676         memory-hungry "linear glyph mask" CALayer backing store formats for non-opaque with text in them.
3677         
3678         Add FontCascade::isSubpixelAntialiasingAvailable() which reports whether subpixel antialiasing is available,
3679         and consult it when making decisions that affect layer backing store format.
3680
3681         Tested by new results for existing tests.
3682
3683         * platform/graphics/FontCascade.cpp:
3684         (WebCore::FontCascade::isSubpixelAntialiasingAvailable):
3685         * platform/graphics/FontCascade.h:
3686         * platform/graphics/cocoa/FontCascadeCocoa.mm:
3687         (WebCore::FontCascade::isSubpixelAntialiasingAvailable): CGFontRenderingGetFontSmoothingDisabled() isn't super cheap, so fetch
3688         it once.
3689         * rendering/RenderLayerBacking.cpp:
3690         (WebCore::RenderLayerBacking::updateAfterDescendants):
3691         * testing/Internals.cpp:
3692         (WebCore::Internals::setFontSmoothingEnabled): Remove a WebCore::
3693
3694 2018-12-17  Daniel Bates  <dabates@apple.com>
3695
3696         Make DocumentMarker::allMarkers() constexpr
3697         https://bugs.webkit.org/show_bug.cgi?id=192634
3698
3699         Reviewed by Simon Fraser.
3700
3701         The result of DocumentMarker::allMarkers() can be computed at compile time. We should annotate
3702         it constexpr to do just that.
3703
3704         * dom/DocumentMarker.h:
3705         (WebCore::DocumentMarker::allMarkers):
3706
3707 2018-12-17  Justin Fan  <justin_fan@apple.com>
3708
3709         [WebGPU] Implement WebGPUBindGroupLayoutDescriptor and its supporting dictionaries
3710         https://bugs.webkit.org/show_bug.cgi?id=192726
3711
3712         Reviewed by Myles C. Maxfield.
3713
3714         Test: webgpu/bind-group-layouts.html
3715         Implement the WebGPUBindGroupLayoutDescriptor struct and its sub-structs:
3716         * Modules/streams/WebGPUBindGroupLayoutDescriptor.h: Added.
3717         * Modules/streams/WebGPUBindGroupLayoutDescriptor.idl: Added.
3718         * Modules/webgpu/WebGPUBindGroupLayoutBinding.h: Added.
3719         * Modules/webgpu/WebGPUBindGroupLayoutBinding.idl: Added.
3720         * Modules/webgpu/WebGPUShaderStageBit.h: Added.
3721         * Modules/webgpu/WebGPUShaderStageBit.idl: Added.
3722         * platform/graphics/gpu/GPUBindGroupLayoutBinding.h: Added.
3723         * platform/graphics/gpu/GPUBindGroupLayoutDescriptor.h: Added.
3724
3725         Add the new symbols and files to the project:
3726         * CMakeLists.txt:
3727         * DerivedSources.make:
3728         * Sources.txt:
3729         * WebCore.xcodeproj/project.pbxproj:
3730         * bindings/js/WebCoreBuiltinNames.h:
3731
3732         Small FIXME update for later:
3733         * platform/graphics/gpu/cocoa/GPURenderPassEncoderMetal.mm:
3734         (WebCore::GPURenderPassEncoder::setVertexBuffers):
3735
3736 2018-12-17  Zalan Bujtas  <zalan@apple.com>
3737
3738         Unreviewed build fix.
3739
3740         * page/ios/FrameIOS.mm:
3741         (WebCore::Frame::interpretationsForCurrentRoot const):
3742
3743 2018-12-17  Zalan Bujtas  <zalan@apple.com>
3744
3745         Reproducible ASSERTion failure when toggling layer borders with find-in-page up
3746         https://bugs.webkit.org/show_bug.cgi?id=192762
3747         <rdar://problem/46676873>
3748
3749         Reviewed by Simon Fraser.
3750
3751         DocumentMarkerController::markersFor() should take a reference instead of a Node*.
3752
3753         Test: editing/document-marker-null-check.html
3754
3755         * dom/DocumentMarkerController.cpp:
3756         (DocumentMarkerController::hasMarkers):
3757         * dom/DocumentMarkerController.h:
3758         * editing/AlternativeTextController.cpp:
3759         (WebCore::AlternativeTextController::respondToChangedSelection):
3760         * editing/Editor.cpp:
3761         (WebCore::Editor::selectionStartHasMarkerFor const):
3762         * rendering/InlineTextBox.cpp:
3763         (WebCore::InlineTextBox::collectMarkedTextsForDocumentMarkers const):
3764         * rendering/RenderReplaced.cpp:
3765         (WebCore::RenderReplaced::paint):
3766         * rendering/RenderText.cpp:
3767         (WebCore::RenderText::draggedContentRangesBetweenOffsets const):
3768         * rendering/SimpleLineLayout.cpp:
3769         (WebCore::SimpleLineLayout::canUseForWithReason):
3770         * testing/Internals.cpp:
3771         (WebCore::Internals::markerCountForNode):
3772
3773 2018-12-17  Commit Queue  <commit-queue@webkit.org>
3774
3775         Unreviewed, rolling out r239265 and r239274.
3776         https://bugs.webkit.org/show_bug.cgi?id=192765
3777
3778         unorm_normalize is deprecated, and broke an internal build
3779         (Requested by Truitt on #webkit).
3780
3781         Reverted changesets:
3782
3783         "[GTK][WPE] Need a function to convert internal URI to display
3784         ("pretty") URI"
3785         https://bugs.webkit.org/show_bug.cgi?id=174816
3786         https://trac.webkit.org/changeset/239265
3787
3788         "Fix the Apple Internal Mac build with a newer SDK"
3789         https://trac.webkit.org/changeset/239274
3790
3791 2018-12-17  Daniel Bates  <dabates@apple.com>
3792
3793         [iOS] Remove -[WebEvent initWithKeyEventType:...:characterSet:]
3794         https://bugs.webkit.org/show_bug.cgi?id=192633
3795
3796         Reviewed by Wenson Hsieh.
3797
3798         UIKit has long adopted the newer -[WebEvent initWithKeyEventType:] initializer that takes an
3799         input manager hint. We no longer need to keep the variant -[WebEvent initWithKeyEventType:...:characterSet:]
3800         for binary compatibility.
3801
3802         * platform/ios/WebEvent.h:
3803         * platform/ios/WebEvent.mm:
3804         (-[WebEvent initWithKeyEventType:timeStamp:characters:charactersIgnoringModifiers:modifiers:isRepeating:withFlags:keyCode:isTabKey:characterSet:]): Deleted.
3805
3806 2018-12-17  Matt Lewis  <jlewis3@apple.com>
3807
3808         Unreviewed, rolling out r239254.
3809
3810         This broke the Windows 10 Debug build
3811
3812         Reverted changeset:
3813
3814         "Replace many uses of String::format with more type-safe
3815         alternatives"
3816         https://bugs.webkit.org/show_bug.cgi?id=192742
3817         https://trac.webkit.org/changeset/239254
3818
3819 2018-12-17  Antoine Quint  <graouts@apple.com>
3820
3821         [Web Animations] Remove the redundant m_scheduledMicrotask from WebAnimation
3822         https://bugs.webkit.org/show_bug.cgi?id=192758
3823
3824         Reviewed by Dean Jackson.
3825
3826         We tracked whether we had a pending microtask twice so we remove the m_scheduledMicrotask flag as m_finishNotificationStepsMicrotaskPending
3827         gives us enough information as it is. Additionally, we remove the scheduleMicrotaskIfNeeded() and performMicrotask() functions since there is
3828         less bookkeeping to perform.
3829
3830         No new test since there is no user-observable change.
3831
3832         * animation/WebAnimation.cpp:
3833         (WebCore::WebAnimation::updateFinishedState):
3834         (WebCore::WebAnimation::scheduleMicrotaskIfNeeded): Deleted.
3835         (WebCore::WebAnimation::performMicrotask): Deleted.
3836         * animation/WebAnimation.h:
3837
3838 2018-12-17  Antoine Quint  <graouts@apple.com>
3839
3840         [Web Animations] Ensure we don't update an animation's finished state twice when updating animations
3841         https://bugs.webkit.org/show_bug.cgi?id=192757
3842
3843         Reviewed by Dean Jackson.
3844
3845         When animations are udpated and DocumentTimeline::updateAnimationsAndSendEvents() is called, we used to update an animation's finished state
3846         twice since we'd do it once when calling tick() and once again when calling resolve() in the ensuing style invalidation. We now keep track of
3847         whether we've already updated an animation's finished state during animation update in the call to tick() and avoid updating in the immediate
3848         next call to resolve(), unless any of the timing properties have changed in the meantime.
3849
3850         No new test since there is no user-observable change.
3851
3852         * animation/WebAnimation.cpp:
3853         (WebCore::WebAnimation::timingDidChange):
3854         (WebCore::WebAnimation::tick):
3855         (WebCore::WebAnimation::resolve):
3856         * animation/WebAnimation.h:
3857
3858 2018-12-17  Simon Fraser  <simon.fraser@apple.com>
3859
3860         REGRESSION (r233268): Elements animated in from offscreen sometimes don't display
3861         https://bugs.webkit.org/show_bug.cgi?id=192725
3862         rdar://problem/46011418
3863
3864         Reviewed by Antoine Quint.
3865
3866         There were two problems with backing store attachment and animation.
3867         
3868         First, animations are an input into the "backing store attached" logic, so when they change
3869         we should set the CoverageRectChanged bit on GraphicsLayerCA.
3870         
3871         Secondly, when an ancestor has unknown animation extent, all its descendants need to
3872         get backing store, so we need to set childCommitState.ancestorWithTransformAnimationIntersectsCoverageRect when
3873         the current layer has no animation extent.
3874
3875         Tests: compositing/backing/animate-into-view-with-descendant.html
3876                compositing/backing/animate-into-view.html
3877
3878         * platform/graphics/ca/GraphicsLayerCA.cpp:
3879         (WebCore::GraphicsLayerCA::addAnimation):
3880         (WebCore::GraphicsLayerCA::removeAnimation):
3881         (WebCore::GraphicsLayerCA::recursiveCommitChanges):
3882
3883 2018-12-17  Zalan Bujtas  <zalan@apple.com>
3884
3885         [LFC][BFC][MarginCollapsing] Unify margin collapse function naming
3886         https://bugs.webkit.org/show_bug.cgi?id=192747
3887
3888         Reviewed by Antti Koivisto.
3889
3890         Rename some margin collapse getters.
3891
3892         * layout/blockformatting/BlockFormattingContext.h:
3893         * layout/blockformatting/BlockFormattingContextGeometry.cpp:
3894         (WebCore::Layout::BlockFormattingContext::Geometry::inFlowNonReplacedHeightAndMargin):
3895         * layout/blockformatting/BlockMarginCollapse.cpp:
3896         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::computedNonCollapsedMarginBefore):
3897         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::computedNonCollapsedMarginAfter):
3898         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::nonCollapsedMarginBefore):
3899         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::nonCollapsedMarginAfter):
3900         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::collapsedMarginBeforeFromFirstChild):
3901         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::collapsedMarginAfterFromLastChild):
3902         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginBeforeCollapsesWithParentMarginAfter):
3903         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginBeforeCollapsesWithParentMarginBefore):
3904         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginAfterCollapsesWithParentMarginAfter):
3905         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginBeforeCollapsesWithPreviousSibling):
3906         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginAfterCollapsesWithNextSibling):
3907         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginsCollapseThrough):
3908         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginBefore):
3909         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::marginAfter):
3910         (WebCore::Layout::isMarginBeforeCollapsedWithSibling): Deleted.
3911         (WebCore::Layout::isMarginAfterCollapsedWithSibling): Deleted.
3912         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::isMarginBeforeCollapsedWithParent): Deleted.
3913         (WebCore::Layout::isMarginAfterCollapsedThrough): Deleted.
3914         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::isMarginAfterCollapsedWithParent): Deleted.
3915         (WebCore::Layout::BlockFormattingContext::Geometry::MarginCollapse::isMarginBeforeCollapsedWithParentMarginAfter): Deleted.
3916
3917 2018-12-17  David Kilzer  <ddkilzer@apple.com>
3918
3919         clang-tidy: loop variable is copied but only used as const reference in WebCore, WebKit, Tools
3920         <https://webkit.org/b/192751>
3921         <rdar://problem/46771623>
3922
3923         Reviewed by Daniel Bates.
3924
3925         Change loop variables to const references to avoid unnecessary
3926         copies.
3927
3928         * Modules/indexeddb/server/MemoryBackingStoreTransaction.cpp:
3929         (WebCore::IDBServer::MemoryBackingStoreTransaction::abort):
3930         * Modules/indexeddb/server/MemoryObjectStore.cpp:
3931         (WebCore::IDBServer::MemoryObjectStore::populateIndexWithExistingRecords):
3932         * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
3933         (WebCore::IDBServer::UniqueIDBDatabase::maybeNotifyConnectionsOfVersionChange):
3934         * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp:
3935         (WebCore::IDBServer::UniqueIDBDatabaseTransaction::objectStoreIdentifiers):
3936         * Modules/indexeddb/shared/IDBDatabaseInfo.cpp:
3937         (WebCore::IDBDatabaseInfo::IDBDatabaseInfo):
3938         (WebCore::IDBDatabaseInfo::loggingString const):
3939         * Modules/mediasource/SourceBuffer.cpp:
3940         (WebCore::removeSamplesFromTrackBuffer):
3941         * accessibility/AccessibilityRenderObject.cpp:
3942         (WebCore::AccessibilityRenderObject::targetElementForActiveDescendant const):
3943         * accessibility/AccessibilityTableRow.cpp:
3944         (WebCore::AccessibilityTableRow::headerObject):
3945         * animation/KeyframeEffect.cpp:
3946         (WebCore::KeyframeEffect::computedNeedsForcedLayout):
3947         * crypto/keys/CryptoKeyRSA.cpp:
3948         (WebCore::CryptoKeyRSA::importJwk):
3949         (WebCore::CryptoKeyRSA::exportJwk const):
3950         * css/CSSComputedStyleDeclaration.cpp:
3951         (WebCore::OrderedNamedLinesCollector::appendLines const):
3952         * dom/DataTransfer.cpp:
3953         (WebCore::readURLsFromPasteboardAsString):
3954         * dom/TreeScope.cpp:
3955         (WebCore::TreeScope::elementsFromPoint):
3956         * html/track/WebVTTParser.cpp:
3957         (WebCore::WebVTTParser::checkAndStoreRegion):
3958         * inspector/agents/InspectorTimelineAgent.cpp:
3959         (WebCore::InspectorTimelineAgent::setInstruments):
3960         * page/Page.cpp:
3961         (WebCore::Page::updateIntersectionObservations):
3962         * page/TextIndicator.cpp:
3963         (WebCore::estimatedBackgroundColorForRange):
3964         * page/animation/KeyframeAnimation.cpp:
3965         (WebCore::KeyframeAnimation::computeLayoutDependency):
3966         * platform/graphics/DisplayRefreshMonitorManager.cpp:
3967         (WebCore::DisplayRefreshMonitorManager::displayWasUpdated):
3968         * platform/graphics/ca/GraphicsLayerCA.cpp:
3969         (WebCore::GraphicsLayerCA::moveOrCopyAnimations):
3970         (WebCore::GraphicsLayerCA::updateAnimations):
3971         (WebCore::GraphicsLayerCA::isRunningTransformAnimation const):
3972         * platform/graphics/mac/ImageMac.mm:
3973         (WebCore::BitmapImage::tiffRepresentation):
3974         * rendering/HitTestResult.cpp:
3975         (WebCore::HitTestResult::append):
3976         * testing/Internals.cpp:
3977         (WebCore::Internals::acceleratedAnimationsForElement):
3978
3979 2018-12-17  Ms2ger  <Ms2ger@igalia.com>
3980
3981         [GTK][WPE] Need a function to convert internal URI to display ("pretty") URI
3982         https://bugs.webkit.org/show_bug.cgi?id=174816
3983