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