Web Inspector: Add VisualStyleSelectorSection
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2015-08-10  Devin Rousso  <drousso@apple.com>
2
3         Web Inspector: Invalid selectors can be applied to the stylesheet
4         https://bugs.webkit.org/show_bug.cgi?id=147230
5
6         Reviewed by Timothy Hatcher.
7
8         * inspector/InspectorStyleSheet.cpp:
9         (WebCore::isValidSelectorListString):
10         (WebCore::InspectorStyleSheet::setRuleSelector):
11         Now checks to see that the supplied selector is valid before trying to commit it to the rule.
12         (WebCore::InspectorStyleSheet::addRule):
13         (WebCore::checkStyleRuleSelector): Deleted.
14
15 2015-08-10  James Craig  <jcraig@apple.com>
16
17         AX: Address follow-up comments in bug 145684
18         https://bugs.webkit.org/show_bug.cgi?id=147817
19
20         Reviewed by Dean Jackson.
21
22         Minor cleanup and style updates requested by Dean.
23         Updated Existing Test Expectations.
24
25         * Modules/mediacontrols/mediaControlsApple.css:
26         (video::-webkit-media-show-controls):
27         * Modules/mediacontrols/mediaControlsiOS.css:
28         (video::-webkit-media-show-controls):
29
30 2015-08-07  Antti Koivisto  <antti@apple.com>
31
32         Expand network cache tests to cover memory cache behavior
33         https://bugs.webkit.org/show_bug.cgi?id=147783
34
35         Reviewed by Alexey Proskuryakov.
36
37         To support testing, include memory cache as a possible source type to XHR responses.
38
39         * loader/ResourceLoader.cpp:
40         (WebCore::logResourceResponseSource):
41         * loader/cache/CachedRawResource.cpp:
42         (WebCore::CachedRawResource::didAddClient):
43         * loader/cache/CachedResource.h:
44         (WebCore::CachedResource::revalidationInProgress):
45         * platform/network/ResourceResponseBase.h:
46         * testing/Internals.cpp:
47         (WebCore::Internals::xhrResponseSource):
48
49 2015-08-10  Youenn Fablet  <youenn.fablet@crf.canon.fr>
50
51         Compile warning (-Wsign-compare) on 32-bits at WebCore/platform/FileSystem.cpp
52         https://bugs.webkit.org/show_bug.cgi?id=146414
53
54         Reviewed by Darin Adler.
55
56         No behavioral changes.
57
58         * platform/FileSystem.cpp:
59         (WebCore::MappedFileData::MappedFileData): Making use of convertSafely.
60         * platform/posix/SharedBufferPOSIX.cpp:
61         (WebCore::SharedBuffer::createFromReadingFile): Making use of convertSafely.
62
63 2015-08-10  Youenn Fablet  <youenn.fablet@crf.canon.fr>
64
65         [Streams API] ReadableStreamReader closed promise should use CachedAttribute
66         https://bugs.webkit.org/show_bug.cgi?id=147487
67
68         Reviewed by Darin Adler.
69
70         Covered by existing tests.
71
72         * Modules/streams/ReadableStreamReader.idl: Made closed a CachedAttribute.
73         * bindings/js/JSReadableStreamReaderCustom.cpp:
74         (WebCore::JSReadableStreamReader::closed): Updated according CachedAttribute specific field.
75
76 2015-08-09  Hunseop Jeong  <hs85.jeong@samsung.com>
77
78         [EFL] Use the non-overlay scrollbar
79         https://bugs.webkit.org/show_bug.cgi?id=147725
80
81         Reviewed by Gyuyoung Kim.
82
83         No new tests because there is no behavior change.
84
85         * platform/efl/ScrollbarThemeEfl.cpp:
86         (WebCore::ScrollbarThemeEfl::usesOverlayScrollbars):
87         Changed the condition of the 'usesOverlayScrollbars' to use the
88         setting value.
89         * platform/efl/ScrollbarThemeEfl.h:
90
91 2015-08-09  Chris Dumez  <cdumez@apple.com>
92
93         Page cache doesn't work for pages actively using Geolocation
94         https://bugs.webkit.org/show_bug.cgi?id=147785
95         <rdar://problem/11147901>
96
97         Reviewed by Darin Adler.
98
99         Allow pages actively using Geolocation into the PageCache.
100
101         Tests: fast/history/page-cache-geolocation-active-oneshot.html
102                fast/history/page-cache-geolocation-active-watcher.html
103
104         * Modules/geolocation/Geolocation.cpp:
105         (WebCore::Geolocation::canSuspendForPageCache):
106         (WebCore::Geolocation::suspend): Deleted.
107         * history/PageCache.cpp:
108
109 2015-08-09  Nan Wang  <n_wang@apple.com>
110
111         AX: CSS table display styles can cause malformed, inaccessible AXTables to be exposed to the AX tree
112         https://bugs.webkit.org/show_bug.cgi?id=136415
113         <rdar://problem/22026625>
114
115         Reviewed by Chris Fleizach.
116
117         Applying CSS display styles to tables can end up inserting anonymous RenderTableRows, which is not handled well by the 
118         accessibility code, which treats these as the actual rows. We can address this by diving deeper into anonymous nodes 
119         and finding the real rows and cells we want. In addition, another thing also causing malformed tables is that "grid" 
120         roles are being exposed as AXGrid instead of AXTable.
121
122         Test: accessibility/mac/malformed-table.html
123
124         * accessibility/AccessibilityARIAGrid.cpp:
125         (WebCore::AccessibilityARIAGrid::addRowDescendant):
126         * accessibility/AccessibilityTable.cpp:
127         (WebCore::AccessibilityTable::addChildren):
128         (WebCore::AccessibilityTable::addTableCellChild):
129         (WebCore::AccessibilityTable::addChildrenFromSection):
130         * accessibility/AccessibilityTable.h:
131         * accessibility/AccessibilityTableCell.cpp:
132         (WebCore::AccessibilityTableCell::parentTable):
133         (WebCore::AccessibilityTableCell::rowIndexRange):
134         * accessibility/AccessibilityTableRow.cpp:
135         (WebCore::AccessibilityTableRow::parentTable):
136         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
137         (createAccessibilityRoleMap):
138
139 2015-08-08  Darin Adler  <darin@apple.com>
140
141         Remove -webkit-color-correction CSS property
142         https://bugs.webkit.org/show_bug.cgi?id=147812
143
144         Reviewed by Maciej Stachowiak.
145
146         Covered by existing tests.
147
148         I am doing some general cleanup of handling of color spaces in WebKit.
149         This removes the obsolete web-visible property that allowed clients to
150         get color correction on older Apple platforms where we chose not to do
151         it all the time for performance reasons. Currently, it has no effect on
152         any supported platform.
153
154         Now that this property is removed, a website can detect that it's not
155         there if it uses getComputedStyle, but I don't expect this to have
156         significant compatibility fallout. It's harmless to continue using the
157         property in legacy content or websites that have not been updated, since
158         unknown property names are ignored and it had no effect before anyway.
159
160         * css/CSSComputedStyleDeclaration.cpp: Removed
161         CSSPropertyWebkitColorCorrection from the list of computed properties.
162         (WebCore::ComputedStyleExtractor::propertyValue): Removed the
163         CSSPropertyWebkitColorCorrection case.
164
165         * css/CSSParser.cpp:
166         (WebCore::isValidKeywordPropertyAndValue): Removed the
167         CSSPropertyWebkitColorCorrection case.
168         (WebCore::isKeywordPropertyID): Ditto.
169         (WebCore::CSSParser::parseValue): Ditto.
170
171         * css/CSSPrimitiveValueMappings.h:
172         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Deleted the overload
173         of this that converts a ColorSpace to a CSSPrimitiveValue.
174         (WebCore::CSSPrimitiveValue::operator ColorSpace): Deleted.
175
176         * css/CSSPropertyNames.in: Removed -webkit-color-correction.
177
178         * css/CSSValueKeywords.in: Removed the -webkit-color-correction section,
179         which contained sRGB.
180
181         * css/SVGCSSValueKeywords.in: Uncommented sRGB now that it's not shared
182         with -webkit-color-correction.
183
184         * rendering/style/RenderStyle.h: Removed setColorSpace and initialColorSpace.
185         Kept colorSpace around for now, but it simply returns ColorSpaceSRGB.
186         This prevents us from needing to touch every single call site that passes
187         the color space in to functions in the platform graphics abstraction.
188         We'll touch most of those call sites when we change Color to include the
189         color space and eventually we can delete this.
190
191         * rendering/style/StyleRareInheritedData.cpp: Deleted colorSpace.
192         (WebCore::StyleRareInheritedData::StyleRareInheritedData): Deleted
193         code to initialize colorSpace and to copy colorSpace.
194         (WebCore::StyleRareInheritedData::operator==): Deleted code to compare
195         colorSpace.
196
197 2015-08-09  Eric Carlson  <eric.carlson@apple.com>
198
199         [Mac] Always require ExternalDeviceAutoPlayCandidate flag to AirPlay automatically
200         https://bugs.webkit.org/show_bug.cgi?id=147801
201
202         Reviewed by Dean Jackson.
203
204         Test: http/tests/media/video-media-document-disposition-download.html
205
206         * Modules/mediasession/WebMediaSessionManager.cpp:
207         (WebCore::WebMediaSessionManager::configurePlaybackTargetClients): Don't tell the last element
208           to begin playing to the target unless the ExternalDeviceAutoPlayCandidate flag is set and 
209           it is not currently playing.
210
211 2015-08-09  Myles C. Maxfield  <mmaxfield@apple.com>
212
213         Crash in ComplexTextController when laying out obscure text
214         https://bugs.webkit.org/show_bug.cgi?id=147806
215         <rdar://problem/22102378>
216
217         Reviewed by Darin Adler.
218
219         CTFontDescriptorCopyAttribute(fontDescriptor.get(), kCTFontReferenceURLAttribute) can return nullptr.
220
221         Test: fast/text/crash-obscure-text.html
222
223         * platform/graphics/mac/ComplexTextControllerCoreText.mm:
224         (WebCore::safeCFEqual):
225         (WebCore::ComplexTextController::collectComplexTextRunsForCharacters):
226
227 2015-08-08  Dean Jackson  <dino@apple.com>
228
229         Remove the webkit prefix from CanvasRenderingContext2D imageSmoothingEnabled
230         https://bugs.webkit.org/show_bug.cgi?id=147803
231         <rdar://problem/22200553>
232
233         Reviewed by Sam Weinig.
234
235         Rename webkitImageSmoothingEnabled to imageSmoothingEnabled.
236
237         Updated existing tests, and made sure that the prefixed version is
238         identical to the standard version.
239
240         * html/canvas/CanvasRenderingContext2D.cpp:
241         (WebCore::CanvasRenderingContext2D::imageSmoothingEnabled): Renamed from webkitImageSmoothingEnabled.
242         (WebCore::CanvasRenderingContext2D::setImageSmoothingEnabled): Renamed from setWebkitImageSmoothingEnabled.
243         (WebCore::CanvasRenderingContext2D::webkitImageSmoothingEnabled): Deleted.
244         (WebCore::CanvasRenderingContext2D::setWebkitImageSmoothingEnabled): Deleted.
245         * html/canvas/CanvasRenderingContext2D.h: Rename the methods.
246         * html/canvas/CanvasRenderingContext2D.idl: Add the non-prefixed form, and mark is as the
247         implementation of the prefixed form.
248
249 2015-08-09  Andreas Kling  <akling@apple.com>
250
251         Ref-ify some functions that always succeed in constructing Documents.
252         <https://webkit.org/b/147552>
253
254         Reviewed by Sam Weinig.
255
256         Update some functions involved in the construction of new Document objects
257         to codify that they always construct objects.
258
259         Bonus: DOMImplementation::createCSSStyleSheet().
260
261         * dom/DOMImplementation.cpp:
262         (WebCore::DOMImplementation::createCSSStyleSheet):
263         (WebCore::DOMImplementation::createHTMLDocument):
264         (WebCore::DOMImplementation::createDocument):
265         * dom/DOMImplementation.h:
266         * loader/DocumentWriter.cpp:
267         (WebCore::DocumentWriter::createDocument):
268         (WebCore::DocumentWriter::begin):
269         * loader/DocumentWriter.h:
270         * xml/DOMParser.cpp:
271         (WebCore::DOMParser::parseFromString):
272         * xml/DOMParser.h:
273         * xml/XSLTProcessor.cpp:
274         (WebCore::XSLTProcessor::createDocumentFromSource):
275         * xml/XSLTProcessor.h:
276
277 2015-08-08  Commit Queue  <commit-queue@webkit.org>
278
279         Unreviewed, rolling out r179871.
280         https://bugs.webkit.org/show_bug.cgi?id=147810
281
282         Breaks product images on http://www.apple.com/shop/buy-
283         mac/macbook (Requested by smfr on #webkit).
284
285         Reverted changeset:
286
287         "Render: properly update body's background image"
288         https://bugs.webkit.org/show_bug.cgi?id=140183
289         http://trac.webkit.org/changeset/179871
290
291 2015-08-07  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
292
293         Reduce uses of PassRefPtr in bindings
294         https://bugs.webkit.org/show_bug.cgi?id=147781
295
296         Reviewed by Chris Dumez.
297
298         Use RefPtr when function can return null or an instance. If not, Ref is used.
299
300         * bindings/gobject/GObjectNodeFilterCondition.h:
301         * bindings/gobject/GObjectXPathNSResolver.h:
302         * bindings/gobject/WebKitDOMNodeFilter.cpp:
303         (WebKit::core):
304         * bindings/gobject/WebKitDOMNodeFilterPrivate.h:
305         * bindings/gobject/WebKitDOMXPathNSResolver.cpp:
306         (WebKit::core):
307         * bindings/gobject/WebKitDOMXPathNSResolverPrivate.h:
308         * bindings/js/CallbackFunction.h:
309         (WebCore::createFunctionOnlyCallback):
310         * bindings/js/Dictionary.h:
311         (WebCore::Dictionary::getEventListener):
312         * bindings/js/IDBBindingUtilities.cpp:
313         (WebCore::createIDBKeyFromValue):
314         (WebCore::internalCreateIDBKeyFromScriptValueAndKeyPath):
315         (WebCore::createIDBKeyFromScriptValueAndKeyPath):
316         (WebCore::scriptValueToIDBKey):
317         * bindings/js/IDBBindingUtilities.h:
318         * bindings/js/JSDOMBinding.h:
319         (WebCore::toInt8Array):
320         (WebCore::toInt16Array):
321         (WebCore::toInt32Array):
322         (WebCore::toUint8Array):
323         (WebCore::toUint8ClampedArray):
324         (WebCore::toUint16Array):
325         (WebCore::toUint32Array):
326         (WebCore::toFloat32Array):
327         (WebCore::toFloat64Array):
328         * bindings/js/JSDOMStringListCustom.cpp:
329         (WebCore::JSDOMStringList::toWrapped):
330         * bindings/js/JSDeviceMotionEventCustom.cpp:
331         (WebCore::readAccelerationArgument):
332         (WebCore::readRotationRateArgument):
333         * bindings/js/JSErrorHandler.h:
334         (WebCore::createJSErrorHandler):
335         * bindings/js/JSGeolocationCustom.cpp:
336         (WebCore::createPositionOptions):
337         * bindings/js/JSNodeCustom.cpp:
338         * bindings/js/JSNodeFilterCustom.cpp:
339         (WebCore::JSNodeFilter::toWrapped):
340         * bindings/js/ScriptController.cpp:
341         (WebCore::ScriptController::createWorld):
342         (WebCore::ScriptController::createRootObject):
343         (WebCore::ScriptController::createScriptInstanceForWidget):
344         * bindings/js/ScriptController.h:
345         * bindings/js/ScriptControllerMac.mm:
346         (WebCore::ScriptController::createScriptInstanceForWidget):
347         * bindings/js/SerializedScriptValue.cpp:
348         (WebCore::SerializedScriptValue::create):
349         * bindings/js/SerializedScriptValue.h:
350         * bindings/objc/DOMUIKitExtensions.mm:
351         (-[DOMNode rangeOfContainingParagraph]):
352         * bindings/objc/ObjCNodeFilterCondition.h:
353         * bindings/scripts/CodeGeneratorJS.pm:
354         (GenerateHeader):
355
356 2015-08-07  Myles C. Maxfield  <mmaxfield@apple.com>
357
358         [OS X] Remove dead code from FontCache::createFontPlatformData()
359         https://bugs.webkit.org/show_bug.cgi?id=147804
360
361         Reviewed by Zalan Bujtas.
362
363         CTFontCreateForCSS() always returns the best font.
364
365         No new tests because there is no behavior change.
366
367         * platform/graphics/mac/FontCacheMac.mm:
368         (WebCore::fontWithFamily):
369
370 2015-08-07  Zalan Bujtas  <zalan@apple.com>
371
372         Move painting functions from RenderObject to RenderElement.
373         https://bugs.webkit.org/show_bug.cgi?id=147764
374
375         Reviewed by Simon Fraser.
376
377         Ideally they should live in RenderBoxModelObject, but the current SVG architecture makes is difficult
378         to move them there.
379
380         No change in functionality.
381
382         * platform/graphics/FloatRect.h:
383         (WebCore::FloatRect::FloatRect):
384         * rendering/RenderBoxModelObject.cpp:
385         (WebCore::RenderBoxModelObject::paintOneBorderSide):
386         * rendering/RenderElement.cpp:
387         (WebCore::RenderElement::drawLineForBoxSide):
388         (WebCore::RenderElement::paintFocusRing):
389         (WebCore::RenderElement::paintOutline):
390         * rendering/RenderElement.h:
391         * rendering/RenderInline.cpp:
392         (WebCore::RenderInline::paintOutline):
393         (WebCore::RenderInline::paintOutlineForLine):
394         * rendering/RenderMultiColumnSet.cpp:
395         (WebCore::RenderMultiColumnSet::paintColumnRules):
396         * rendering/RenderObject.cpp:
397         (WebCore::RenderObject::drawLineForBoxSide): Deleted.
398         (WebCore::RenderObject::paintFocusRing): Deleted.
399         (WebCore::RenderObject::paintOutline): Deleted.
400         * rendering/RenderObject.h:
401         * rendering/RenderTableCell.cpp:
402         (WebCore::RenderTableCell::paintCollapsedBorders):
403         * rendering/RenderTableSection.cpp:
404         (WebCore::RenderTableSection::paintRowGroupBorder):
405         * rendering/RenderTheme.h:
406         (WebCore::RenderTheme::paintMenuListButtonDecorations):
407         * rendering/RenderThemeIOS.h:
408         * rendering/RenderThemeIOS.mm:
409         (WebCore::RenderThemeIOS::paintMenuListButtonDecorations):
410         * rendering/RenderThemeMac.h:
411         * rendering/RenderThemeMac.mm:
412         (WebCore::RenderThemeMac::paintMenuListButtonDecorations):
413
414 2015-08-07  James Craig  <jcraig@apple.com>
415
416         REGRESSION(r184722) AX: WebKit video playback toolbar removed from DOM; no longer accessible to VoiceOver
417         https://bugs.webkit.org/show_bug.cgi?id=145684
418
419         Reviewed by Dean Jackson.
420
421         Updated Apple Video controls to add an invisible but focusable button that allows VoiceOver 
422         users (and when unblocked, keyboard users) to re-display the video controls.
423
424         Test: media/video-controls-show-on-kb-or-ax-event.html
425
426         * English.lproj/mediaControlsLocalizedStrings.js:
427         * Modules/mediacontrols/mediaControlsApple.css:
428         (audio::-webkit-media-show-controls):
429         (video::-webkit-media-show-controls):
430         * Modules/mediacontrols/mediaControlsApple.js:
431         (Controller.prototype.createControls):
432         (Controller.prototype.handleFullscreenChange):
433         (Controller.prototype.handleShowControlsClick):
434         (Controller.prototype.handleWrapperMouseMove):
435         (Controller.prototype.updateForShowingControls):
436         (Controller.prototype.showControls):
437         (Controller.prototype.hideControls):
438         (Controller.prototype.setNeedsUpdateForDisplayedWidth):
439         * Modules/mediacontrols/mediaControlsiOS.css:
440         (audio::-webkit-media-show-controls):
441         (video::-webkit-media-show-controls):
442
443 2015-08-07  Alex Christensen  <achristensen@webkit.org>
444
445         Build more testing binaries with CMake on Windows
446         https://bugs.webkit.org/show_bug.cgi?id=147799
447
448         Reviewed by Brent Fulgham.
449
450         * CMakeLists.txt:
451         MockCDM.cpp needs to be part of WebCoreTestSupport, not WebCore.
452         * PlatformWin.cmake:
453         Added files needed for AppleWin port.
454
455 2015-08-07  Anders Carlsson  <andersca@apple.com>
456
457         Being moving away from using SQLTransactionStateMachine in SQLTransactionBackend
458         https://bugs.webkit.org/show_bug.cgi?id=147798
459
460         Reviewed by Geoffrey Garen.
461
462         This is the first step towards getting rid of the state machine so we can ultimately merge SQLTransactionBackend
463         into SQLTransaction.
464
465         Instead of having the state machine run our functions, just run them ourselves where we can. For states that need
466         to be handled in the frontend, call SQLTransaction::requestTransitToState explicitly.
467
468         * Modules/webdatabase/SQLTransactionBackend.cpp:
469         (WebCore::SQLTransactionBackend::stateFunctionFor):
470         (WebCore::SQLTransactionBackend::lockAcquired):
471         (WebCore::SQLTransactionBackend::openTransactionAndPreflight):
472         (WebCore::SQLTransactionBackend::runStatements):
473         (WebCore::SQLTransactionBackend::runCurrentStatement):
474         (WebCore::SQLTransactionBackend::handleCurrentStatementError):
475         (WebCore::SQLTransactionBackend::handleTransactionError):
476         (WebCore::SQLTransactionBackend::postflightAndCommit):
477         (WebCore::SQLTransactionBackend::runCurrentStatementAndGetNextState): Deleted.
478         (WebCore::SQLTransactionBackend::nextStateForCurrentStatementError): Deleted.
479         (WebCore::SQLTransactionBackend::nextStateForTransactionError): Deleted.
480         (WebCore::SQLTransactionBackend::sendToFrontendState): Deleted.
481         * Modules/webdatabase/SQLTransactionBackend.h:
482
483 2015-08-07  Filip Pizlo  <fpizlo@apple.com>
484
485         Lightweight locks should be adaptive
486         https://bugs.webkit.org/show_bug.cgi?id=147545
487
488         Reviewed by Geoffrey Garen.
489
490         * bindings/objc/WebScriptObject.mm:
491         (WebCore::getJSWrapper):
492         (WebCore::addJSWrapper):
493         (WebCore::removeJSWrapper):
494         (WebCore::removeJSWrapperIfRetainCountOne):
495         * platform/audio/mac/CARingBuffer.cpp:
496         (WebCore::CARingBuffer::setCurrentFrameBounds):
497         (WebCore::CARingBuffer::getCurrentFrameBounds):
498         * platform/audio/mac/CARingBuffer.h:
499         * platform/ios/wak/WAKWindow.mm:
500         (-[WAKWindow setExposedScrollViewRect:]):
501         (-[WAKWindow exposedScrollViewRect]):
502
503 2015-08-07  Myles C. Maxfield  <mmaxfield@apple.com>
504
505         Post-review comments on r188146
506         https://bugs.webkit.org/show_bug.cgi?id=147793
507
508         Reviewed by Daniel Bates.
509
510         No new tests because there is no behavior change.
511
512         * platform/graphics/FontCache.h:
513         * platform/graphics/cocoa/FontCacheCoreText.cpp:
514         (WebCore::appendTrueTypeFeature):
515         (WebCore::appendOpenTypeFeature):
516         (WebCore::applyFontFeatureSettings):
517         * platform/graphics/ios/FontCacheIOS.mm:
518         (WebCore::FontCache::getSystemFontFallbackForCharacters):
519         (WebCore::FontCache::createFontPlatformData):
520         * platform/graphics/mac/FontCacheMac.mm:
521         (WebCore::fontWithFamily):
522         (WebCore::FontCache::systemFallbackForCharacters):
523         * platform/graphics/mac/FontCustomPlatformData.cpp:
524         (WebCore::FontCustomPlatformData::fontPlatformData):
525         * rendering/RenderThemeIOS.mm:
526         (WebCore::RenderThemeIOS::updateCachedSystemFontDescription):
527
528 2015-08-07  Myles C. Maxfield  <mmaxfield@apple.com>
529
530         [Cocoa] Font fallback is not language-sensitive
531         https://bugs.webkit.org/show_bug.cgi?id=147390
532
533         Reviewed by Dean Jackson.
534
535         We need to make our font fallback code sensitive to locale.
536
537         This patch rolls r187729 back in. However, only particular versions of iOS and OS X are
538         performant enough to enable this language-sensitivity.
539
540         This patch also applies to iOS.
541
542         Test: fast/text/fallback-language-han.html
543
544         * platform/graphics/mac/FontCacheMac.mm:
545         (WebCore::lookupCTFont):
546         (WebCore::FontCache::systemFallbackForCharacters):
547         * platform/graphics/mac/FontCacheIOS.mm:
548         (WebCore::FontCache::systemFallbackForCharacters):
549
550 2015-08-07  Zalan Bujtas  <zalan@apple.com>
551
552         RenderTheme::volumeSliderOffsetFromMuteButton should take const& RenderBox.
553         https://bugs.webkit.org/show_bug.cgi?id=147731
554
555         Reviewed by Simon Fraser.
556
557         No change in functionality.
558
559         * rendering/RenderMediaControlElements.cpp:
560         (WebCore::RenderMediaVolumeSliderContainer::layout):
561         * rendering/RenderMediaControls.cpp:
562         (WebCore::RenderMediaControls::volumeSliderOffsetFromMuteButton): Deleted.
563         * rendering/RenderMediaControls.h:
564         * rendering/RenderTheme.cpp:
565         (WebCore::RenderTheme::volumeSliderOffsetFromMuteButton):
566         * rendering/RenderTheme.h:
567
568 2015-08-07  Zalan Bujtas  <zalan@apple.com>
569
570         Replace RenderObject::isRooted() logic with isDescendantOf().
571         https://bugs.webkit.org/show_bug.cgi?id=147788
572
573         Reviewed by Simon Fraser.
574
575         And some related cleanups.
576
577         No change in functionality.
578
579         * page/FrameView.cpp:
580         (WebCore::FrameView::scheduleRelayoutOfSubtree):
581         (WebCore::FrameView::extendedBackgroundRectForPainting):
582         * rendering/RenderBox.cpp:
583         (WebCore::RenderBox::paintRootBoxFillLayers):
584         * rendering/RenderElement.cpp:
585         (WebCore::shouldRepaintForImageAnimation):
586         * rendering/RenderObject.cpp:
587         (WebCore::RenderObject::isDescendantOf):
588         (WebCore::scheduleRelayoutForSubtree):
589         (WebCore::RenderObject::repaint):
590         (WebCore::RenderObject::repaintRectangle):
591         (WebCore::RenderObject::repaintSlowRepaintObject):
592         (WebCore::RenderObject::isRooted):
593         * rendering/RenderObject.h:
594         * rendering/RenderView.cpp:
595         (WebCore::RenderView::unextendedBackgroundRect):
596         (WebCore::RenderView::backgroundRect):
597         * rendering/RenderView.h:
598
599 2015-08-07  Zalan Bujtas  <zalan@apple.com>
600
601         Subtree layout code should use RenderElement.
602         https://bugs.webkit.org/show_bug.cgi?id=147694
603
604         Reviewed by Simon Fraser.
605
606         Subtree layout will never begin at a RenderText, so tighten up
607         the code to operate on RenderElements instead of RenderObjects.
608         (This patch is based on webkit.org/b/126878)
609
610         No change in functionality.
611
612         * inspector/InspectorTimelineAgent.cpp:
613         (WebCore::InspectorTimelineAgent::willLayout):
614         * page/FrameView.cpp:
615         (WebCore::FrameView::FrameView): Deleted.
616         (WebCore::FrameView::layoutRoot): Deleted.
617         * page/FrameView.h:
618         * rendering/RenderBox.cpp:
619         (WebCore::RenderBox::computeLogicalWidthInRegion):
620         * rendering/RenderElement.cpp:
621         (WebCore::RenderElement::clearLayoutRootIfNeeded):
622         (WebCore::RenderElement::willBeDestroyed):
623         * rendering/RenderElement.h:
624         * rendering/RenderObject.cpp:
625         (WebCore::RenderObject::clearLayoutRootIfNeeded): Deleted.
626         (WebCore::RenderObject::willBeDestroyed): Deleted.
627         * rendering/RenderObject.h:
628
629 2015-08-07  Wenson Hsieh  <wenson_hsieh@apple.com>
630
631         Temporarily allow programmatic input assistance for adding Gmail account
632         https://bugs.webkit.org/show_bug.cgi?id=147792
633
634         Reviewed by Enrica Casucci.
635         <rdar://problem/22126518>
636
637         Temporary fix for keyboard input sliding out and immediately back in upon user interaction
638         in the Gmail 2-factor authentication page.
639
640         * platform/RuntimeApplicationChecksIOS.h:
641         * platform/RuntimeApplicationChecksIOS.mm:
642         (WebCore::applicationIsGmailAddAccountOnIOS): Added bundle ID for Gmail settings.
643
644 2015-08-07  Andy Estes  <aestes@apple.com>
645
646         Crash when following a Google search link to Twitter with Limit Adult Content enabled
647         https://bugs.webkit.org/show_bug.cgi?id=147651
648
649         Reviewed by Brady Eidson.
650
651         When a loaded CachedRawResource gets a new client, it synthesizes the callbacks that the new client would have
652         received while the resource was loading. Unlike a real network load, it synthesizes these callbacks in a single
653         run loop iteration. When DocumentLoader receives a redirect, and finds substitute data in the app cache for the
654         redirect URL, it schedules a timer that removes DocumentLoader as a client of the CachedRawResource then
655         synthesizes its own set of CachedRawResourceClient callbacks. But since CachedRawResource has already delivered
656         client callbacks before the app cache timer fires, DocumentLoader unexpectedly ends up getting two sets of
657         client callbacks and badness ensues.
658
659         The fix is to let CachedRawResource detect if a redirect will trigger the client to load substitute data. If so,
660         stop delivering client callbacks.
661
662         Layout test to follow.
663
664         * loader/DocumentLoader.cpp:
665         (WebCore::DocumentLoader::syntheticRedirectReceived): If there is valid substitute data, do not continue.
666         * loader/DocumentLoader.h:
667         * loader/cache/CachedRawResource.cpp: Returned early if syntheticRedirectReceived() said not to continue.
668         (WebCore::CachedRawResource::didAddClient):
669         * loader/cache/CachedRawResourceClient.h:
670         (WebCore::CachedRawResourceClient::syntheticRedirectReceived):
671
672 2015-08-06  Dean Jackson  <dino@apple.com>
673
674         Shadows don't draw on fillText when using a gradient fill
675         https://bugs.webkit.org/show_bug.cgi?id=147758
676         <rdar://problem/20860912>
677
678         Reviewed by Myles Maxfield.
679
680         Since we use a mask to render a pattern or gradient
681         into text, any shadow was being clipped out. Change
682         this to draw the shadow before the mask + fill operation,
683         using a technique similar to text-shadow.
684
685         Test: fast/canvas/gradient-text-with-shadow.html
686
687         * html/canvas/CanvasRenderingContext2D.cpp:
688         (WebCore::CanvasRenderingContext2D::drawTextInternal): Get the current shadow
689         style, paint the text with a transformed shadow offset so that we only
690         see the shadow and not the text, then combine with the existing pattern/gradient
691         fill.
692
693 2015-08-07  Myles C. Maxfield  <mmaxfield@apple.com>
694
695         Implement font-feature-settings
696         https://bugs.webkit.org/show_bug.cgi?id=147722
697
698         Reviewed by Simon Fraser.
699
700         Fonts with features are simply modeled as new font objects. Font
701         feature information is contained within FontDescription, and our
702         caches are correctly sensitive to this information. Therefore,
703         we just need to make our font lookup code honor the request to
704         use certain features.
705
706         This patch creates a file, FontCacheCoreText.cpp, which will be the
707         new home of all shared OS X / iOS FontCache code. Over time, I will
708         be moving more and more source into this file, until there is
709         nothing left of FontCacheMac.mm and FontCacheIOS.mm. For now, the
710         only function in this file is the code which applies font features.
711
712         Test: css3/font-feature-settings-preinstalled-fonts.html
713
714         * WebCore.xcodeproj/project.pbxproj: Add FontCacheCoreText.cpp.
715         * platform/graphics/FontCache.h:
716         * platform/graphics/cocoa/FontCacheCoreText.cpp: Added.
717         (WebCore::appendTrueTypeFeature): What the name says.
718         (WebCore::appendOpenTypeFeature): Ditto.
719         (WebCore::applyFontFeatureSettings): Ditto.
720         * platform/graphics/ios/FontCacheIOS.mm:
721         (WebCore::FontCache::getSystemFontFallbackForCharacters): Call
722         applyFontFeatureSettings().
723         (WebCore::FontCache::createFontPlatformData): Ditto.
724         * platform/graphics/mac/FontCacheMac.mm:
725         (WebCore::fontWithFamily): Ditto.
726         (WebCore::FontCache::systemFallbackForCharacters): Ditto.
727         (WebCore::FontCache::createFontPlatformData): Ditto.
728         * platform/graphics/mac/FontCustomPlatformData.cpp:
729         (WebCore::FontCustomPlatformData::fontPlatformData): Ditto.
730         * rendering/RenderThemeIOS.mm:
731         (WebCore::RenderThemeIOS::updateCachedSystemFontDescription):
732         Ditto.
733
734 2015-08-07  Commit Queue  <commit-queue@webkit.org>
735
736         Unreviewed, rolling out r187907.
737         https://bugs.webkit.org/show_bug.cgi?id=147789
738
739         taking a different approach to the fix (Requested by estes on
740         #webkit).
741
742         Reverted changeset:
743
744         "Crash when following a Google search link to Twitter with
745         Limit Adult Content enabled."
746         https://bugs.webkit.org/show_bug.cgi?id=147651
747         http://trac.webkit.org/changeset/187907
748
749 2015-08-07  Alex Christensen  <achristensen@webkit.org>
750
751         Fix WinCairo build after r188130.
752
753         * platform/graphics/win/FontCustomPlatformDataCairo.cpp:
754         (WebCore::FontCustomPlatformData::~FontCustomPlatformData):
755         (WebCore::FontCustomPlatformData::fontPlatformData):
756         I forgot the parameter name.
757
758 2015-08-07  Alex Christensen  <achristensen@webkit.org>
759
760         Fix WinCairo build after r188130.
761
762         * platform/graphics/win/FontCustomPlatformDataCairo.cpp:
763         (WebCore::FontCustomPlatformData::~FontCustomPlatformData):
764         (WebCore::FontCustomPlatformData::fontPlatformData):
765         Update fontPlatformData parameters.
766
767 2015-08-07  Daniel Bates  <dabates@apple.com>
768
769         Attempt to fix the Windows build after <http://trac.webkit.org/changeset/188130>
770         (https://bugs.webkit.org/show_bug.cgi?id=147775)
771
772         Include header FontDescription.h.
773
774         * platform/graphics/win/FontCustomPlatformData.cpp:
775         * platform/graphics/win/FontCustomPlatformDataCairo.cpp:
776
777 2015-08-07  Myles C. Maxfield  <mmaxfield@apple.com>
778
779         Allow FontCustomPlatformData to consult with FontDescription
780         https://bugs.webkit.org/show_bug.cgi?id=147775
781
782         Reviewed by Zalan Bujtas.
783
784         In order to implement font-feature-settings, web fonts need to be
785         able to consult with the set of active font features. Rather than
786         add yet another argument to all the functions in this flow, this
787         patch passes around a reference to the FontDescription itself instead
788         of copies of constituent members of it.
789
790         No new tests because there is no behavior change.
791
792         * css/CSSFontFaceSource.cpp:
793         (WebCore::CSSFontFaceSource::font):
794         * loader/cache/CachedFont.cpp:
795         (WebCore::CachedFont::createFont):
796         (WebCore::CachedFont::platformDataFromCustomData):
797         * loader/cache/CachedFont.h:
798         * loader/cache/CachedSVGFont.cpp:
799         (WebCore::CachedSVGFont::platformDataFromCustomData):
800         * loader/cache/CachedSVGFont.h:
801         * platform/graphics/cairo/FontCustomPlatformData.h:
802         * platform/graphics/freetype/FontCustomPlatformDataFreeType.cpp:
803         (WebCore::FontCustomPlatformData::fontPlatformData):
804         * platform/graphics/freetype/FontPlatformData.h:
805         * platform/graphics/freetype/FontPlatformDataFreeType.cpp:
806         (WebCore::FontPlatformData::FontPlatformData):
807         * platform/graphics/freetype/SimpleFontDataFreeType.cpp:
808         (WebCore::Font::platformCreateScaledFont):
809         * platform/graphics/mac/FontCustomPlatformData.cpp:
810         (WebCore::FontCustomPlatformData::fontPlatformData):
811         * platform/graphics/mac/FontCustomPlatformData.h:
812         * platform/graphics/win/FontCustomPlatformData.cpp:
813         (WebCore::FontCustomPlatformData::fontPlatformData):
814         * platform/graphics/win/FontCustomPlatformData.h:
815
816 2015-08-07  Xabier Rodriguez Calvar  <calvaris@igalia.com>
817
818         [Streams API] Create CountQueuingStrategy object as per spec
819         https://bugs.webkit.org/show_bug.cgi?id=146594
820
821         Reviewed by Geoffrey Garen.
822
823         CountQueuingStrategy is a class part of the Streams API that can be found at
824         https://streams.spec.whatwg.org/#cqs-class. We had it as js at the tests but the spec says we have to provide it
825         natively. The class is implemented in this patch by creating its corresponding IDL with the size method using
826         the [CustomBinding] attribute, that does not create any bindings against the object allowing us full control to
827         do what the spec requires (just returning 1 without any cast check). The constructor sets the highWaterMark
828         property taking it from the argument.
829
830         Covered by current tests
831         (LayoutTests/streams/reference-implementation/count-queuing-strategy.html and
832         LayoutTests/streams/reference-implementation/brand-checks.html).
833
834         * CMakeLists.txt:
835         * DerivedSources.cpp:
836         * DerivedSources.make:
837         * PlatformMac.cmake:
838         * WebCore.vcxproj/WebCore.vcxproj:
839         * WebCore.vcxproj/WebCore.vcxproj.filters:
840         * WebCore.xcodeproj/project.pbxproj:
841         * bindings/js/JSBindingsAllInOne.cpp: Build infrastructure.
842         * Modules/streams/CountQueuingStrategy.h: Added.
843         (WebCore::CountQueuingStrategy::~CountQueuingStrategy): Created empty.
844         (WebCore::CountQueuingStrategy::size): Returns 1.
845         * Modules/streams/CountQueuingStrategy.idl: Added.
846         * bindings/js/JSCountQueuingStrategyCustom.cpp: Added.
847         (WebCore::jsCountQueuingStrategyPrototypeFunctionSize): Calls WebCore::CountQueuingStrategy::size.
848         (WebCore::constructJSCountQueuingStrategy): Constructs the strategy, copies the highWaterMark from the argument
849         and returns it.
850         * bindings/js/JSDOMBinding.h:
851         (WebCore::getPropertyFromObject): Moved from ReadableJSStream.cpp.
852         (WebCore::setPropertyToObject): Added to create a property into an object.
853         * bindings/js/ReadableJSStream.cpp:
854         (WebCore::getPropertyFromObject): Deleted.
855
856 2015-08-07  Brady Eidson  <beidson@apple.com>
857
858         Move concrete KeyedDecoder/Encoder implementations to WebCore.
859         https://bugs.webkit.org/show_bug.cgi?id=147757.
860
861         Rubberstamped by Andy Estes.
862
863         * PlatformEfl.cmake:
864         * PlatformGTK.cmake:
865         * WebCore.xcodeproj/project.pbxproj:
866
867         * platform/KeyedCoding.h:
868         (WebCore::KeyedDecoder::KeyedDecoder): Static constructor to be implemented per-platform.
869         (WebCore::KeyedEncoder::KeyedEncoder): Ditto.
870
871         * platform/cf/KeyedDecoderCF.cpp: Renamed from Source/WebKit2/Shared/cf/KeyedDecoder.cpp.
872         (WebCore::KeyedDecoder::decoder):
873         (WebCore::KeyedDecoderCF::KeyedDecoderCF):
874         (WebCore::KeyedDecoderCF::~KeyedDecoderCF):
875         (WebCore::KeyedDecoderCF::decodeBytes):
876         (WebCore::KeyedDecoderCF::decodeBool):
877         (WebCore::KeyedDecoderCF::decodeUInt32):
878         (WebCore::KeyedDecoderCF::decodeInt32):
879         (WebCore::KeyedDecoderCF::decodeInt64):
880         (WebCore::KeyedDecoderCF::decodeFloat):
881         (WebCore::KeyedDecoderCF::decodeDouble):
882         (WebCore::KeyedDecoderCF::decodeString):
883         (WebCore::KeyedDecoderCF::beginObject):
884         (WebCore::KeyedDecoderCF::endObject):
885         (WebCore::KeyedDecoderCF::beginArray):
886         (WebCore::KeyedDecoderCF::beginArrayElement):
887         (WebCore::KeyedDecoderCF::endArrayElement):
888         (WebCore::KeyedDecoderCF::endArray):
889         * platform/cf/KeyedDecoderCF.h: Renamed from Source/WebKit2/Shared/cf/KeyedDecoder.h.
890         
891         * platform/cf/KeyedEncoderCF.cpp: Renamed from Source/WebKit2/Shared/cf/KeyedEncoder.cpp.
892         (WebCore::KeyedEncoder::encoder):
893         (WebCore::createDictionary):
894         (WebCore::KeyedEncoderCF::KeyedEncoderCF):
895         (WebCore::KeyedEncoderCF::~KeyedEncoderCF):
896         (WebCore::KeyedEncoderCF::encodeBytes):
897         (WebCore::KeyedEncoderCF::encodeBool):
898         (WebCore::KeyedEncoderCF::encodeUInt32):
899         (WebCore::KeyedEncoderCF::encodeInt32):
900         (WebCore::KeyedEncoderCF::encodeInt64):
901         (WebCore::KeyedEncoderCF::encodeFloat):
902         (WebCore::KeyedEncoderCF::encodeDouble):
903         (WebCore::KeyedEncoderCF::encodeString):
904         (WebCore::KeyedEncoderCF::beginObject):
905         (WebCore::KeyedEncoderCF::endObject):
906         (WebCore::KeyedEncoderCF::beginArray):
907         (WebCore::KeyedEncoderCF::beginArrayElement):
908         (WebCore::KeyedEncoderCF::endArrayElement):
909         (WebCore::KeyedEncoderCF::endArray):
910         (WebCore::KeyedEncoderCF::finishEncoding):
911         * platform/cf/KeyedEncoderCF.h: Renamed from Source/WebKit2/Shared/cf/KeyedEncoder.h.
912         
913         * platform/glib/KeyedDecoderGlib.cpp: Renamed from Source/WebKit2/Shared/glib/KeyedDecoder.cpp.
914         (WebCore::KeyedDecoder::decoder):
915         (WebCore::KeyedDecoderGlib::KeyedDecoderGlib):
916         (WebCore::KeyedDecoderGlib::~KeyedDecoderGlib):
917         (WebCore::KeyedDecoderGlib::dictionaryFromGVariant):
918         (WebCore::KeyedDecoderGlib::decodeBytes):
919         (WebCore::KeyedDecoderGlib::decodeSimpleValue):
920         (WebCore::KeyedDecoderGlib::decodeBool):
921         (WebCore::KeyedDecoderGlib::decodeUInt32):
922         (WebCore::KeyedDecoderGlib::decodeInt32):
923         (WebCore::KeyedDecoderGlib::decodeInt64):
924         (WebCore::KeyedDecoderGlib::decodeFloat):
925         (WebCore::KeyedDecoderGlib::decodeDouble):
926         (WebCore::KeyedDecoderGlib::decodeString):
927         (WebCore::KeyedDecoderGlib::beginObject):
928         (WebCore::KeyedDecoderGlib::endObject):
929         (WebCore::KeyedDecoderGlib::beginArray):
930         (WebCore::KeyedDecoderGlib::beginArrayElement):
931         (WebCore::KeyedDecoderGlib::endArrayElement):
932         (WebCore::KeyedDecoderGlib::endArray):
933         * platform/glib/KeyedDecoderGlib.h: Renamed from Source/WebKit2/Shared/glib/KeyedDecoder.h.
934         
935         * platform/glib/KeyedEncoderGlib.cpp: Renamed from Source/WebKit2/Shared/glib/KeyedEncoder.cpp.
936         (WebCore::KeyedEncoder::encoder):
937         (WebCore::KeyedEncoderGlib::KeyedEncoderGlib):
938         (WebCore::KeyedEncoderGlib::~KeyedEncoderGlib):
939         (WebCore::KeyedEncoderGlib::encodeBytes):
940         (WebCore::KeyedEncoderGlib::encodeBool):
941         (WebCore::KeyedEncoderGlib::encodeUInt32):
942         (WebCore::KeyedEncoderGlib::encodeInt32):
943         (WebCore::KeyedEncoderGlib::encodeInt64):
944         (WebCore::KeyedEncoderGlib::encodeFloat):
945         (WebCore::KeyedEncoderGlib::encodeDouble):
946         (WebCore::KeyedEncoderGlib::encodeString):
947         (WebCore::KeyedEncoderGlib::beginObject):
948         (WebCore::KeyedEncoderGlib::endObject):
949         (WebCore::KeyedEncoderGlib::beginArray):
950         (WebCore::KeyedEncoderGlib::beginArrayElement):
951         (WebCore::KeyedEncoderGlib::endArrayElement):
952         (WebCore::KeyedEncoderGlib::endArray):
953         (WebCore::KeyedEncoderGlib::finishEncoding):
954         * platform/glib/KeyedEncoderGlib.h: Renamed from Source/WebKit2/Shared/glib/KeyedEncoder.h.
955
956 2015-08-07  Carlos Garcia Campos  <cgarcia@igalia.com>
957
958         [GStreamer] Do not automatically show PackageKit codec installation notifications
959         https://bugs.webkit.org/show_bug.cgi?id=135973
960
961         Reviewed by Philippe Normand.
962
963         Add description parameter to requestInstallMissingPlugins() that
964         will be used by the API layer.
965
966         * html/HTMLMediaElement.cpp:
967         (WebCore::HTMLMediaElement::requestInstallMissingPlugins):
968         * html/HTMLMediaElement.h:
969         * page/ChromeClient.h:
970         * platform/graphics/MediaPlayer.h:
971         (WebCore::MediaPlayerClient::requestInstallMissingPlugins):
972         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
973         (WebCore::MediaPlayerPrivateGStreamer::handleMessage):
974
975 2015-08-07  Doug Russell  <d_russell@apple.com>
976
977         AX: Bug 147737 is causing test failures in Mavericks WK1
978         https://bugs.webkit.org/show_bug.cgi?id=147763
979
980         Restrict change made in 147737 to ElCapitan+ because it is causing tests
981         to fail in Mavericks.
982
983         Reviewed by Chris Fleizach.
984
985         Fixes failing tests.
986
987         * accessibility/AXObjectCache.cpp:
988         (WebCore::AXObjectCache::setEnhancedUserInterfaceAccessibility):
989
990 2015-08-07  Xabier Rodriguez Calvar  <calvaris@igalia.com>
991
992         Create [CustomBinding] extended IDL attribute
993         https://bugs.webkit.org/show_bug.cgi?id=146593
994
995         Reviewed by Geoffrey Garen.
996
997         Added the [CustomBinding] IDL extended attribute. The idea is that when using this attribute, bindings generate
998         only the signature of the JS functions and we have to implement all the access in the Custom.cpp files, meaning
999         accessing the implementations at our wish.
1000
1001         Added customBindingMethod, customBindingMethodWithArgs to the generator tests.
1002
1003         * bindings/scripts/CodeGeneratorGObject.pm:
1004         (SkipFunction): Skipped [CustomBinding] methods.
1005         * bindings/scripts/CodeGeneratorJS.pm:
1006         (GenerateHeader): Consider CustomBinding as ForwardDeclareInHeader.
1007         (GenerateImplementation): Avoid printing both header and implementation of the function.
1008         * bindings/scripts/CodeGeneratorObjC.pm:
1009         (SkipFunction): Skipped [CustomBinding] methods.
1010         * bindings/scripts/IDLAttributes.txt: Added [CustomBinding] IDL extended attribute.
1011         * bindings/scripts/test/JS/JSTestObj.cpp:
1012         * bindings/scripts/test/TestObj.idl: Added customBindingMethod, customBindingMethodWithArgs and their
1013         expectations.
1014
1015 2015-08-06  Zan Dobersek  <zdobersek@igalia.com>
1016
1017         Source/WebCore/crypto code should pass std::function<> objects through rvalue references
1018         https://bugs.webkit.org/show_bug.cgi?id=147332
1019
1020         Reviewed by Anders Carlsson.
1021
1022         Pass the std::function<> callbacks through CryptoAlgorithm methods via
1023         rvlaue references. This avoids generation of unnecessary move and copy
1024         constructors for std::function<> objects that are being handled.
1025
1026         * crypto/CryptoAlgorithm.cpp:
1027         (WebCore::CryptoAlgorithm::encrypt):
1028         (WebCore::CryptoAlgorithm::decrypt):
1029         (WebCore::CryptoAlgorithm::sign):
1030         (WebCore::CryptoAlgorithm::verify):
1031         (WebCore::CryptoAlgorithm::digest):
1032         (WebCore::CryptoAlgorithm::generateKey):
1033         (WebCore::CryptoAlgorithm::deriveKey):
1034         (WebCore::CryptoAlgorithm::deriveBits):
1035         (WebCore::CryptoAlgorithm::importKey):
1036         (WebCore::CryptoAlgorithm::encryptForWrapKey):
1037         (WebCore::CryptoAlgorithm::decryptForUnwrapKey):
1038         * crypto/CryptoAlgorithm.h:
1039         * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp:
1040         (WebCore::CryptoAlgorithmAES_CBC::encrypt):
1041         (WebCore::CryptoAlgorithmAES_CBC::decrypt):
1042         (WebCore::CryptoAlgorithmAES_CBC::generateKey):
1043         (WebCore::CryptoAlgorithmAES_CBC::importKey):
1044         * crypto/algorithms/CryptoAlgorithmAES_CBC.h:
1045         * crypto/algorithms/CryptoAlgorithmAES_KW.cpp:
1046         (WebCore::CryptoAlgorithmAES_KW::encryptForWrapKey):
1047         (WebCore::CryptoAlgorithmAES_KW::decryptForUnwrapKey):
1048         (WebCore::CryptoAlgorithmAES_KW::generateKey):
1049         (WebCore::CryptoAlgorithmAES_KW::importKey):
1050         * crypto/algorithms/CryptoAlgorithmAES_KW.h:
1051         * crypto/algorithms/CryptoAlgorithmHMAC.cpp:
1052         (WebCore::CryptoAlgorithmHMAC::sign):
1053         (WebCore::CryptoAlgorithmHMAC::verify):
1054         (WebCore::CryptoAlgorithmHMAC::generateKey):
1055         (WebCore::CryptoAlgorithmHMAC::importKey):
1056         * crypto/algorithms/CryptoAlgorithmHMAC.h:
1057         * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp:
1058         (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::encrypt):
1059         (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::decrypt):
1060         (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::generateKey):
1061         (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::importKey):
1062         * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.h:
1063         * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.cpp:
1064         (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::sign):
1065         (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::verify):
1066         (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::generateKey):
1067         (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::importKey):
1068         * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.h:
1069         * crypto/algorithms/CryptoAlgorithmRSA_OAEP.cpp:
1070         (WebCore::CryptoAlgorithmRSA_OAEP::encrypt):
1071         (WebCore::CryptoAlgorithmRSA_OAEP::decrypt):
1072         (WebCore::CryptoAlgorithmRSA_OAEP::generateKey):
1073         (WebCore::CryptoAlgorithmRSA_OAEP::importKey):
1074         * crypto/algorithms/CryptoAlgorithmRSA_OAEP.h:
1075         * crypto/algorithms/CryptoAlgorithmSHA1.cpp:
1076         (WebCore::CryptoAlgorithmSHA1::digest):
1077         * crypto/algorithms/CryptoAlgorithmSHA1.h:
1078         * crypto/algorithms/CryptoAlgorithmSHA224.cpp:
1079         (WebCore::CryptoAlgorithmSHA224::digest):
1080         * crypto/algorithms/CryptoAlgorithmSHA224.h:
1081         * crypto/algorithms/CryptoAlgorithmSHA256.cpp:
1082         (WebCore::CryptoAlgorithmSHA256::digest):
1083         * crypto/algorithms/CryptoAlgorithmSHA256.h:
1084         * crypto/algorithms/CryptoAlgorithmSHA384.cpp:
1085         (WebCore::CryptoAlgorithmSHA384::digest):
1086         * crypto/algorithms/CryptoAlgorithmSHA384.h:
1087         * crypto/algorithms/CryptoAlgorithmSHA512.cpp:
1088         (WebCore::CryptoAlgorithmSHA512::digest):
1089         * crypto/algorithms/CryptoAlgorithmSHA512.h:
1090         * crypto/gnutls/CryptoAlgorithmAES_CBCGnuTLS.cpp:
1091         (WebCore::CryptoAlgorithmAES_CBC::platformEncrypt):
1092         (WebCore::CryptoAlgorithmAES_CBC::platformDecrypt):
1093         * crypto/gnutls/CryptoAlgorithmAES_KWGnuTLS.cpp:
1094         (WebCore::CryptoAlgorithmAES_KW::platformEncrypt):
1095         (WebCore::CryptoAlgorithmAES_KW::platformDecrypt):
1096         * crypto/gnutls/CryptoAlgorithmHMACGnuTLS.cpp:
1097         (WebCore::CryptoAlgorithmHMAC::platformSign):
1098         (WebCore::CryptoAlgorithmHMAC::platformVerify):
1099         * crypto/gnutls/CryptoAlgorithmRSAES_PKCS1_v1_5GnuTLS.cpp:
1100         (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::platformEncrypt):
1101         (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::platformDecrypt):
1102         * crypto/gnutls/CryptoAlgorithmRSASSA_PKCS1_v1_5GnuTLS.cpp:
1103         (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::platformSign):
1104         (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::platformVerify):
1105         * crypto/gnutls/CryptoAlgorithmRSA_OAEPGnuTLS.cpp:
1106         (WebCore::CryptoAlgorithmRSA_OAEP::platformEncrypt):
1107         (WebCore::CryptoAlgorithmRSA_OAEP::platformDecrypt):
1108         * crypto/mac/CryptoAlgorithmAES_CBCMac.cpp:
1109         (WebCore::transformAES_CBC):
1110         (WebCore::CryptoAlgorithmAES_CBC::platformEncrypt):
1111         (WebCore::CryptoAlgorithmAES_CBC::platformDecrypt):
1112         * crypto/mac/CryptoAlgorithmAES_KWMac.cpp:
1113         (WebCore::CryptoAlgorithmAES_KW::platformEncrypt):
1114         (WebCore::CryptoAlgorithmAES_KW::platformDecrypt):
1115         * crypto/mac/CryptoAlgorithmHMACMac.cpp:
1116         (WebCore::CryptoAlgorithmHMAC::platformSign):
1117         (WebCore::CryptoAlgorithmHMAC::platformVerify):
1118         * crypto/mac/CryptoAlgorithmRSAES_PKCS1_v1_5Mac.cpp:
1119         (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::platformEncrypt):
1120         (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::platformDecrypt):
1121         * crypto/mac/CryptoAlgorithmRSASSA_PKCS1_v1_5Mac.cpp:
1122         (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::platformSign):
1123         (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::platformVerify):
1124         * crypto/mac/CryptoAlgorithmRSA_OAEPMac.cpp:
1125         (WebCore::CryptoAlgorithmRSA_OAEP::platformEncrypt):
1126         (WebCore::CryptoAlgorithmRSA_OAEP::platformDecrypt):
1127
1128 2015-08-06  Alex Christensen  <achristensen@webkit.org>
1129
1130         Fix GTK clean build after r187997
1131         https://bugs.webkit.org/show_bug.cgi?id=147723
1132
1133         Reviewed by Gyuyoung Kim.
1134
1135         * CMakeLists.txt:
1136         r187997 made it so WebCoreTestSupport does not link with WebCore, which is necessary to get DumpRenderTree to link.
1137         It also made it so WebCoreTestSupport is no longer dependent on WebCore, which causes it to build at the same time.
1138         This caused problems because WebCoreTestSupport uses headers that are generated for WebCore, such as WebKitFontFamilyNames.h.
1139         Adding a dependency makes it so that WebCoreTestSupport waits until WebCore is done compiling before compiling,
1140         which is what it used to do, but it does not cause linking problems with DumpRenderTree.
1141
1142 2015-08-06  Myles C. Maxfield  <mmaxfield@apple.com>
1143
1144         CSSSegmentedFontFace::fontRanges() does not handle duplicate fonts correctly
1145         https://bugs.webkit.org/show_bug.cgi?id=147765
1146
1147         Reviewed by Filip Pizlo.
1148
1149         CSSSegmentedFontFace::fontRanges() was trying to hash on FontDescriptors by
1150         picking a few specific pieces of data out of the FontDescriptor, computing
1151         a hash on it, and using that unsigned as a key in a HashMap. This has two
1152         problems: it doesn't handle equality correctly, as hash collisions cannot
1153         depend on an equality operator to dedup, and it doesn't hash on all the
1154         members of a FontDescription.
1155
1156         Instead, this HashMap should use FontDescriptionKey, which represents a
1157         FontDescription, and is designed exactly for the purpose of being used as a
1158         key in a HashMap.
1159
1160         No new tests because there is no behavior change (because a problem occurs
1161         when two different FontDescriptions hash to the same value, which is rare).
1162
1163         * css/CSSSegmentedFontFace.cpp:
1164         (WebCore::CSSSegmentedFontFace::fontRanges):
1165         * css/CSSSegmentedFontFace.h:
1166         * platform/graphics/FontCache.h:
1167         (WebCore::FontDescriptionKeyHash::hash):
1168         (WebCore::FontDescriptionKeyHash::equal):
1169
1170 2015-08-06  Myles C. Maxfield  <mmaxfield@apple.com>
1171
1172         [iOS] Remove dead code from FontCache::createFontPlatformData()
1173         https://bugs.webkit.org/show_bug.cgi?id=147762
1174
1175         Reviewed by Andy Estes.
1176
1177         No new tests because there is no behavior change.
1178
1179         * platform/graphics/ios/FontCacheIOS.mm:
1180         (WebCore::FontCache::createFontPlatformData): Deleted.
1181
1182 2015-08-06  Alex Christensen  <achristensen@webkit.org>
1183
1184         Revert part of my "build fix" in r188101.
1185
1186         * CMakeLists.txt:
1187         MockCDM was already conditionally added to WebCore_SOURCES, and that change causes dependency cycles when bug 147723 is fixed.
1188
1189 2015-08-06  Alex Christensen  <achristensen@webkit.org>
1190
1191         [Win] CMake build fix after r188098.
1192
1193         * CMakeLists.txt:
1194         MockCDM is necessary for testing if ENCRYPTED_MEDIA_V2 is enabled.
1195
1196 2015-08-06  Alex Christensen  <achristensen@webkit.org>
1197
1198         [Win] Enable all Windows features in CMake
1199         https://bugs.webkit.org/show_bug.cgi?id=147744
1200
1201         Reviewed by Tim Horton.
1202
1203         * PlatformWin.cmake:
1204         Add a file needed for enabling video.
1205
1206 2015-08-06  Anders Carlsson  <andersca@apple.com>
1207
1208         Rename SQLStatementBackend to SQLStatement
1209         https://bugs.webkit.org/show_bug.cgi?id=147755
1210
1211         Reviewed by Geoffrey Garen.
1212
1213         * CMakeLists.txt:
1214         * Modules/webdatabase/SQLStatement.h: Renamed from Source/WebCore/Modules/webdatabase/SQLStatementBackend.h.
1215         (WebCore::SQLStatement::hasStatementCallback):
1216         (WebCore::SQLStatement::hasStatementErrorCallback):
1217         * Modules/webdatabase/SQLStatementBackend.cpp: Removed.
1218         (WebCore::SQLStatementBackend::SQLStatementBackend): Deleted.
1219         (WebCore::SQLStatementBackend::~SQLStatementBackend): Deleted.
1220         (WebCore::SQLStatementBackend::sqlError): Deleted.
1221         (WebCore::SQLStatementBackend::sqlResultSet): Deleted.
1222         (WebCore::SQLStatementBackend::execute): Deleted.
1223         (WebCore::SQLStatementBackend::performCallback): Deleted.
1224         (WebCore::SQLStatementBackend::setDatabaseDeletedError): Deleted.
1225         (WebCore::SQLStatementBackend::setVersionMismatchedError): Deleted.
1226         (WebCore::SQLStatementBackend::setFailureDueToQuota): Deleted.
1227         (WebCore::SQLStatementBackend::clearFailureDueToQuota): Deleted.
1228         (WebCore::SQLStatementBackend::lastExecutionFailedDueToQuota): Deleted.
1229         * Modules/webdatabase/SQLStatementBackend.h:
1230         (WebCore::SQLStatementBackend::hasStatementCallback): Deleted.
1231         (WebCore::SQLStatementBackend::hasStatementErrorCallback): Deleted.
1232         * Modules/webdatabase/SQLTransaction.cpp:
1233         (WebCore::SQLTransaction::deliverStatementCallback):
1234         (WebCore::SQLTransaction::executeSQL):
1235         * Modules/webdatabase/SQLTransactionBackend.cpp:
1236         (WebCore::SQLTransactionBackend::currentStatement):
1237         (WebCore::SQLTransactionBackend::enqueueStatementBackend):
1238         (WebCore::SQLTransactionBackend::executeSQL):
1239         * Modules/webdatabase/SQLTransactionBackend.h:
1240         * WebCore.vcxproj/WebCore.vcxproj:
1241         * WebCore.vcxproj/WebCore.vcxproj.filters:
1242         * WebCore.xcodeproj/project.pbxproj:
1243
1244 2015-08-06  Myles C. Maxfield  <mmaxfield@apple.com>
1245
1246         Make FontDescriptionKey sensitive to FontFeatureSettings
1247         https://bugs.webkit.org/show_bug.cgi?id=147751
1248
1249         Reviewed by Anders Carlsson.
1250
1251         Just like how FontDescription hashes should be sensitive to locale, they should
1252         also be sensitive to font features.
1253
1254         This patch also fixes operator== for FontDescriptionKey, which was previously
1255         comparing hashes for equality instead of the underlying data. Comparing hashes
1256         for equality is useless inside hashmaps.
1257
1258         This is in preparation for implementing font-feature-settings.
1259
1260         No new tests because there is no behavior change.
1261
1262         * platform/graphics/FontCache.cpp:
1263         (WebCore::FontPlatformDataCacheKey::FontPlatformDataCacheKey):
1264         (WebCore::FontPlatformDataCacheKey::isHashTableDeletedValue):
1265         (WebCore::FontPlatformDataCacheKey::hashTableDeletedSize): Deleted.
1266         * platform/graphics/FontCache.h:
1267         (WebCore::FontDescriptionKey::FontDescriptionKey):
1268         (WebCore::FontDescriptionKey::operator==):
1269         (WebCore::FontDescriptionKey::operator!=):
1270         (WebCore::FontDescriptionKey::isHashTableDeletedValue):
1271         (WebCore::FontDescriptionKey::computeHash):
1272         * platform/graphics/FontFeatureSettings.cpp:
1273         (WebCore::FontFeature::hash):
1274         (WebCore::FontFeatureSettings::hash):
1275         * platform/graphics/FontFeatureSettings.h:
1276
1277 2015-08-06  Anders Carlsson  <andersca@apple.com>
1278
1279         Merge SQLStatement into SQLStatementBackend
1280         https://bugs.webkit.org/show_bug.cgi?id=147754
1281
1282         Reviewed by Geoffrey Garen.
1283
1284         * CMakeLists.txt:
1285         * Modules/webdatabase/Database.h:
1286         * Modules/webdatabase/SQLStatement.cpp: Removed.
1287         (WebCore::SQLStatement::SQLStatement): Deleted.
1288         (WebCore::SQLStatement::setBackend): Deleted.
1289         (WebCore::SQLStatement::hasCallback): Deleted.
1290         (WebCore::SQLStatement::hasErrorCallback): Deleted.
1291         (WebCore::SQLStatement::performCallback): Deleted.
1292         * Modules/webdatabase/SQLStatement.h: Removed.
1293         * Modules/webdatabase/SQLStatementBackend.cpp:
1294         (WebCore::SQLStatementBackend::SQLStatementBackend):
1295         (WebCore::SQLStatementBackend::performCallback):
1296         (WebCore::SQLStatementBackend::frontend): Deleted.
1297         * Modules/webdatabase/SQLStatementBackend.h:
1298         (WebCore::SQLStatementBackend::hasStatementCallback):
1299         (WebCore::SQLStatementBackend::hasStatementErrorCallback):
1300         * Modules/webdatabase/SQLTransaction.cpp:
1301         (WebCore::SQLTransaction::deliverStatementCallback):
1302         (WebCore::SQLTransaction::executeSQL):
1303         * Modules/webdatabase/SQLTransaction.h:
1304         * Modules/webdatabase/SQLTransactionBackend.cpp:
1305         (WebCore::SQLTransactionBackend::currentStatement):
1306         (WebCore::SQLTransactionBackend::executeSQL):
1307         * Modules/webdatabase/SQLTransactionBackend.h:
1308         * WebCore.vcxproj/WebCore.vcxproj:
1309         * WebCore.vcxproj/WebCore.vcxproj.filters:
1310         * WebCore.xcodeproj/project.pbxproj:
1311         * bindings/js/JSSQLTransactionCustom.cpp:
1312
1313 2015-08-06  Chris Dumez  <cdumez@apple.com>
1314
1315         Toggle GPS state based on page visibility to save battery
1316         https://bugs.webkit.org/show_bug.cgi?id=147685
1317
1318         Reviewed by Benjamin Poulain.
1319
1320         Toggle GPS state based on page visibility to save battery. Previously,
1321         if the site you were viewing was watching your position and you
1322         switched tab, the GPS would stay on. This was bad for battery life.
1323
1324         Tests: fast/dom/Geolocation/startUpdatingOnlyWhenPageVisible.html
1325                fast/dom/Geolocation/stopUpdatingForHiddenPage.html
1326
1327         * Modules/geolocation/GeolocationController.cpp:
1328         (WebCore::GeolocationController::addObserver):
1329         (WebCore::GeolocationController::viewStateDidChange):
1330
1331 2015-08-06  Anders Carlsson  <andersca@apple.com>
1332
1333         SQLStatementBackend doesn't need to be refcounted
1334         https://bugs.webkit.org/show_bug.cgi?id=147748
1335
1336         Reviewed by Geoffrey Garen.
1337
1338         There's no shared ownership of SQLStatementBackend so we can just use std::unique_ptr.
1339
1340         * Modules/webdatabase/SQLStatementBackend.cpp:
1341         (WebCore::SQLStatementBackend::create): Deleted.
1342         * Modules/webdatabase/SQLStatementBackend.h:
1343         * Modules/webdatabase/SQLTransactionBackend.cpp:
1344         (WebCore::SQLTransactionBackend::enqueueStatementBackend):
1345         (WebCore::SQLTransactionBackend::executeSQL):
1346         * Modules/webdatabase/SQLTransactionBackend.h:
1347
1348 2015-08-06  Eric Carlson  <eric.carlson@apple.com>
1349
1350         Do not enforce "content-disposition: attachment" sandbox restrictions on a MediaDocument
1351         https://bugs.webkit.org/show_bug.cgi?id=147734
1352         rdar://problem/22028179
1353
1354         Reviewed by Andy Estes.
1355
1356         Test to follow, see https://bugs.webkit.org/show_bug.cgi?id=147735
1357
1358         * dom/Document.cpp:
1359         (WebCore::Document::initSecurityContext): Use applyContentDispositionAttachmentSandbox
1360           instead of setting sandbox flags directly.
1361         (WebCore::Document::shouldEnforceContentDispositionAttachmentSandbox): Don't special
1362           case MediaDocument.
1363         (WebCore::Document::applyContentDispositionAttachmentSandbox): Apply sandbox flags
1364           according to document type.
1365         * dom/Document.h:
1366
1367 2015-08-06  Anders Carlsson  <andersca@apple.com>
1368
1369         Get rid of DatabaseBackendBase
1370         https://bugs.webkit.org/show_bug.cgi?id=147733
1371
1372         Reviewed by Geoffrey Garen.
1373
1374         * CMakeLists.txt:
1375         * Modules/webdatabase/Database.cpp:
1376         (WebCore::Database::Database):
1377         (WebCore::DoneCreatingDatabaseOnExitCaller::DoneCreatingDatabaseOnExitCaller):
1378         (WebCore::DoneCreatingDatabaseOnExitCaller::~DoneCreatingDatabaseOnExitCaller):
1379         * Modules/webdatabase/Database.h:
1380         * Modules/webdatabase/DatabaseBackendBase.cpp: Removed.
1381         (WebCore::DatabaseBackendBase::DatabaseBackendBase): Deleted.
1382         (WebCore::DatabaseBackendBase::~DatabaseBackendBase): Deleted.
1383         * Modules/webdatabase/DatabaseBackendBase.h: Removed.
1384         * Modules/webdatabase/DatabaseManager.cpp:
1385         * Modules/webdatabase/DatabaseManager.h:
1386         * Modules/webdatabase/DatabaseTracker.cpp:
1387         * WebCore.vcxproj/WebCore.vcxproj:
1388         * WebCore.vcxproj/WebCore.vcxproj.filters:
1389         * WebCore.xcodeproj/project.pbxproj:
1390
1391 2015-08-06  Myles C. Maxfield  <mmaxfield@apple.com>
1392
1393         Add comment to CSSParserString
1394         https://bugs.webkit.org/show_bug.cgi?id=147724
1395
1396         Reviewed by Dean Jackson.
1397
1398         No new tests because there is no behavior change.
1399
1400         * css/CSSParserValues.h:
1401
1402 2015-08-06  Myles C. Maxfield  <mmaxfield@apple.com>
1403
1404         Font feature settings comparisons are order-dependent and case-dependent
1405         https://bugs.webkit.org/show_bug.cgi?id=147719
1406
1407         Reviewed by Benjamin Poulain.
1408
1409         We should make our settings vector order-independent and case-independent.
1410
1411         Test: css3/font-feature-settings-parsing.html
1412
1413         * css/CSSParser.cpp:
1414         (WebCore::CSSParser::parseFontFeatureTag):
1415         * css/StyleBuilderConverter.h:
1416         (WebCore::StyleBuilderConverter::convertFontFeatureSettings):
1417         * platform/graphics/FontFeatureSettings.cpp:
1418         (WebCore::FontFeature::FontFeature):
1419         (WebCore::FontFeature::operator==):
1420         (WebCore::FontFeatureSettings::FontFeatureSettings):
1421         * platform/graphics/FontFeatureSettings.h:
1422         (WebCore::FontFeature::FontFeature):
1423         (WebCore::FontFeature::operator==):
1424         (WebCore::FontFeature::operator<):
1425         (WebCore::FontFeatureSettings::insert):
1426         (WebCore::FontFeatureSettings::FontFeatureSettings):
1427         (WebCore::FontFeatureSettings::append): Deleted.
1428
1429 2015-08-06  Doug Russell  <d_russell@apple.com>
1430
1431         AX: AXLoadComplete that comes before AX API access won't fire
1432         https://bugs.webkit.org/show_bug.cgi?id=147737
1433
1434         Reviewed by Chris Fleizach.
1435
1436         Treat setEnhancedUserInterfaceAccessibility() as AX API access and if true,
1437         enableAccessibility().
1438
1439         Test: accessibility/mac/loaded-notification.html
1440
1441         * accessibility/AXObjectCache.cpp:
1442         (WebCore::AXObjectCache::setEnhancedUserInterfaceAccessibility):
1443
1444 2015-08-06  Eric Carlson  <eric.carlson@apple.com>
1445
1446         Do not enforce "content-disposition: attachment" sandbox restrictions on a MediaDocument
1447         https://bugs.webkit.org/show_bug.cgi?id=147734
1448         rdar://problem/22028179
1449
1450         Reviewed by Dean Jackson.
1451
1452         Test to follow, see https://bugs.webkit.org/show_bug.cgi?id=147735
1453
1454         * dom/Document.cpp:
1455         (WebCore::Document::shouldEnforceContentDispositionAttachmentSandbox): Return
1456           early if the Document is a MediaDocument.
1457
1458 2015-08-06  Matt Rajca  <mrajca@apple.com>
1459
1460         Media Session: remove media elements from the ID <-> element map on destruction
1461         https://bugs.webkit.org/show_bug.cgi?id=147707
1462
1463         Reviewed by Eric Carlson.
1464
1465         * html/HTMLMediaElement.cpp:
1466         (WebCore::HTMLMediaElement::~HTMLMediaElement):
1467
1468 2015-08-06  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
1469
1470         [CoordinatedGraphics] Remove unused functions in Coordinated TiledBackingStore
1471         https://bugs.webkit.org/show_bug.cgi?id=147621
1472
1473         Reviewed by Csaba Osztrogonác.
1474
1475         * platform/graphics/texmap/coordinated/TiledBackingStore.cpp: Remove setTileSize() and tileSize().
1476         (WebCore::TiledBackingStore::setTileSize):
1477
1478 2015-08-06  Anders Carlsson  <andersca@apple.com>
1479
1480         Move the last remnants of DatabaseBackendBase to Database
1481         https://bugs.webkit.org/show_bug.cgi?id=147730
1482
1483         Reviewed by Tim Horton.
1484
1485         * Modules/webdatabase/Database.cpp:
1486         (WebCore::Database::Database):
1487         (WebCore::Database::performOpenAndVerify):
1488         * Modules/webdatabase/Database.h:
1489         * Modules/webdatabase/DatabaseBackendBase.cpp:
1490         (WebCore::DatabaseBackendBase::DatabaseBackendBase):
1491         * Modules/webdatabase/DatabaseBackendBase.h:
1492         (WebCore::DatabaseBackendBase::databaseContext): Deleted.
1493         (WebCore::DatabaseBackendBase::setFrontend): Deleted.
1494
1495 2015-08-06  Alex Christensen  <achristensen@webkit.org>
1496
1497         Fix build without ENABLE(VIDEO) after r188030.
1498
1499         * dom/Document.h:
1500         * html/HTMLMediaElement.cpp:
1501         * html/HTMLMediaElement.h:
1502         Move definition of HTMLMediaElementInvalidID to Document.h so it can be used outside of ENABLE(VIDEO) macros.
1503
1504 2015-08-04  Matt Rajca  <mrajca@apple.com>
1505
1506         Media Session: push paused state to the media session focus manager instead of polling
1507         https://bugs.webkit.org/show_bug.cgi?id=147633
1508
1509         Reviewed by Simon Fraser.
1510
1511         * dom/Document.cpp:
1512         (WebCore::Document::updateIsPlayingMedia): If a valid source element ID is passed in, set the 'IsSourcePlaying'
1513          flag accordingly.
1514         * dom/Document.h:
1515         * html/HTMLMediaElement.cpp:
1516         (WebCore::HTMLMediaElement::elementWithID):
1517         (WebCore::HTMLMediaElement::setMuted): Pass along the element ID.
1518         (WebCore::HTMLMediaElement::mediaPlayerCharacteristicChanged): Ditto.
1519         (WebCore::HTMLMediaElement::setPlaying): Ditto.
1520         * html/HTMLMediaElement.h:
1521         * page/ChromeClient.h:
1522         * page/MediaProducer.h:
1523         * page/Page.cpp:
1524         (WebCore::Page::updateIsPlayingMedia): Pass along the source element ID.
1525         (WebCore::Page::isMediaElementPaused): Deleted. We now push media playback state changes instead of polling.
1526         * page/Page.h:
1527
1528 2015-08-05  Myles C. Maxfield  <mmaxfield@apple.com>
1529
1530         CharacterFallbackMapKey should be locale-specific
1531         https://bugs.webkit.org/show_bug.cgi?id=147532
1532
1533         Reviewed by Dean Jackson.
1534
1535         This is in preparation for locale-specific font fallback.
1536
1537         No new tests because there is no behavior change.
1538
1539         * platform/graphics/Font.cpp:
1540         (WebCore::CharacterFallbackMapKey::CharacterFallbackMapKey):
1541         (WebCore::CharacterFallbackMapKey::operator==):
1542         (WebCore::CharacterFallbackMapKeyHash::hash):
1543         (WebCore::Font::systemFallbackFontForCharacter):
1544
1545 2015-08-05  Myles C. Maxfield  <mmaxfield@apple.com>
1546
1547         Expand CharacterFallbackMapKey to a struct
1548         https://bugs.webkit.org/show_bug.cgi?id=147530
1549
1550         Reviewed by Dean Jackson.
1551
1552         This is in prepraration for making this struct locale-specific.
1553
1554         No new tests because there is no behavior change.
1555
1556         * platform/graphics/Font.cpp:
1557         (WebCore::CharacterFallbackMapKey::CharacterFallbackMapKey):
1558         (WebCore::CharacterFallbackMapKey::isHashTableDeletedValue):
1559         (WebCore::CharacterFallbackMapKey::operator==):
1560         (WebCore::CharacterFallbackMapKeyHash::hash):
1561         (WebCore::CharacterFallbackMapKeyHash::equal):
1562         (WebCore::Font::systemFallbackFontForCharacter):
1563
1564 2015-08-05  Chris Dumez  <cdumez@apple.com>
1565
1566         Crash when removing children of a MathMLSelectElement
1567         https://bugs.webkit.org/show_bug.cgi?id=147704
1568         <rdar://problem/21940321>
1569
1570         Reviewed by Ryosuke Niwa.
1571
1572         When MathMLSelectElement::childrenChanged() is called after its
1573         children have been removed, MathMLSelectElement calls
1574         updateSelectedChild() which accesses m_selectedChild. However,
1575         in this case, m_selectedChild is the previously selected child
1576         and it may be destroyed as this point if it was removed. To avoid
1577         this problem, MathMLSelectElement now keep a strong ref to the
1578         currently selected element.
1579
1580         Test: mathml/maction-removeChild.html
1581
1582         * mathml/MathMLSelectElement.h:
1583
1584 2015-08-05  Myles C. Maxfield  <mmaxfield@apple.com>
1585
1586         Migrate FontCascade.cpp to NeverDestroyed
1587         https://bugs.webkit.org/show_bug.cgi?id=147533
1588
1589         Reviewed by Simon Fraser.
1590
1591         No new tests because there is no behavior change.
1592
1593         * platform/graphics/FontCascade.cpp:
1594         (WebCore::fontCascadeCache):
1595
1596 2015-08-05  Tim Horton  <timothy_horton@apple.com>
1597
1598         Try to fix the build
1599
1600         * Modules/webdatabase/Database.cpp:
1601         (WebCore::Database::performOpenAndVerify):
1602         * Modules/webdatabase/Database.h:
1603
1604 2015-08-05  Myles C. Maxfield  <mmaxfield@apple.com>
1605
1606         Delete duplicate forward-declaration
1607         https://bugs.webkit.org/show_bug.cgi?id=147701
1608
1609         Reviewed by Simon Fraser.
1610
1611         No new tests because there is no behavior change.
1612
1613         * platform/spi/cocoa/CoreTextSPI.h:
1614
1615 2015-08-05  Anders Carlsson  <andersca@apple.com>
1616
1617         Move the last DatabaseBackendBase functions over to Database
1618         https://bugs.webkit.org/show_bug.cgi?id=147706
1619
1620         Reviewed by Tim Horton.
1621
1622         * Modules/webdatabase/Database.cpp:
1623         (WebCore::Database::~Database):
1624         (WebCore::Database::setExpectedVersion):
1625         (WebCore::Database::getActualVersionForTransaction):
1626         (WebCore::Database::version):
1627         (WebCore::Database::stringIdentifier):
1628         (WebCore::Database::displayName):
1629         (WebCore::Database::estimatedSize):
1630         (WebCore::Database::fileName):
1631         (WebCore::Database::details):
1632         (WebCore::Database::maximumSize):
1633         (WebCore::Database::databaseDebugName):
1634         * Modules/webdatabase/Database.h:
1635         * Modules/webdatabase/DatabaseBackendBase.cpp:
1636         (WebCore::DatabaseBackendBase::databaseDebugName): Deleted.
1637         (WebCore::DatabaseBackendBase::~DatabaseBackendBase): Deleted.
1638         (WebCore::DatabaseBackendBase::version): Deleted.
1639         (WebCore::DatabaseBackendBase::securityOrigin): Deleted.
1640         (WebCore::DatabaseBackendBase::stringIdentifier): Deleted.
1641         (WebCore::DatabaseBackendBase::displayName): Deleted.
1642         (WebCore::DatabaseBackendBase::estimatedSize): Deleted.
1643         (WebCore::DatabaseBackendBase::fileName): Deleted.
1644         (WebCore::DatabaseBackendBase::details): Deleted.
1645         (WebCore::DatabaseBackendBase::setExpectedVersion): Deleted.
1646         (WebCore::DatabaseBackendBase::getActualVersionForTransaction): Deleted.
1647         (WebCore::DatabaseBackendBase::maximumSize): Deleted.
1648         * Modules/webdatabase/DatabaseBackendBase.h:
1649         (WebCore::DatabaseBackendBase::opened): Deleted.
1650         (WebCore::DatabaseBackendBase::isNew): Deleted.
1651         (WebCore::DatabaseBackendBase::sqliteDatabase): Deleted.
1652         (WebCore::DatabaseBackendBase::expectedVersion): Deleted.
1653         * Modules/webdatabase/SQLTransactionClient.cpp:
1654         (WebCore::SQLTransactionClient::didCommitWriteTransaction):
1655         (WebCore::SQLTransactionClient::didExceedQuota):
1656         * Modules/webdatabase/SQLTransactionClient.h:
1657
1658 2015-08-05  Filip Pizlo  <fpizlo@apple.com>
1659
1660         Unreviewed, roll out http://trac.webkit.org/changeset/187972.
1661
1662         * Modules/webaudio/AsyncAudioDecoder.cpp:
1663         (WebCore::AsyncAudioDecoder::AsyncAudioDecoder):
1664         (WebCore::AsyncAudioDecoder::runLoop):
1665         * Modules/webaudio/AsyncAudioDecoder.h:
1666         * Modules/webaudio/AudioContext.h:
1667         * Modules/webaudio/MediaStreamAudioSource.cpp:
1668         (WebCore::MediaStreamAudioSource::addAudioConsumer):
1669         (WebCore::MediaStreamAudioSource::removeAudioConsumer):
1670         (WebCore::MediaStreamAudioSource::setAudioFormat):
1671         (WebCore::MediaStreamAudioSource::consumeAudio):
1672         * Modules/webaudio/MediaStreamAudioSource.h:
1673         * Modules/webdatabase/Database.cpp:
1674         (WebCore::Database::close):
1675         (WebCore::Database::runTransaction):
1676         (WebCore::Database::inProgressTransactionCompleted):
1677         (WebCore::Database::hasPendingTransaction):
1678         * Modules/webdatabase/DatabaseTask.h:
1679         * Modules/webdatabase/DatabaseThread.cpp:
1680         (WebCore::DatabaseThread::start):
1681         (WebCore::DatabaseThread::databaseThread):
1682         * Modules/webdatabase/DatabaseThread.h:
1683         * Modules/webdatabase/DatabaseTracker.cpp:
1684         (WebCore::DatabaseTracker::setDatabaseDirectoryPath):
1685         (WebCore::DatabaseTracker::canEstablishDatabase):
1686         (WebCore::DatabaseTracker::retryCanEstablishDatabase):
1687         (WebCore::DatabaseTracker::hasEntryForOrigin):
1688         (WebCore::DatabaseTracker::getMaxSizeForDatabase):
1689         (WebCore::DatabaseTracker::closeAllDatabases):
1690         (WebCore::DatabaseTracker::fullPathForDatabase):
1691         (WebCore::DatabaseTracker::origins):
1692         (WebCore::DatabaseTracker::databaseNamesForOrigin):
1693         (WebCore::DatabaseTracker::detailsForNameAndOrigin):
1694         (WebCore::DatabaseTracker::setDatabaseDetails):
1695         (WebCore::DatabaseTracker::doneCreatingDatabase):
1696         (WebCore::DatabaseTracker::addOpenDatabase):
1697         (WebCore::DatabaseTracker::removeOpenDatabase):
1698         (WebCore::DatabaseTracker::getOpenDatabases):
1699         (WebCore::DatabaseTracker::originLockFor):
1700         (WebCore::DatabaseTracker::quotaForOrigin):
1701         (WebCore::DatabaseTracker::setQuota):
1702         (WebCore::DatabaseTracker::deleteOrigin):
1703         (WebCore::DatabaseTracker::deleteDatabase):
1704         (WebCore::DatabaseTracker::deleteDatabaseFile):
1705         (WebCore::DatabaseTracker::removeDeletedOpenedDatabases):
1706         (WebCore::DatabaseTracker::deleteDatabaseFileIfEmpty):
1707         (WebCore::DatabaseTracker::openDatabaseMutex):
1708         (WebCore::DatabaseTracker::setClient):
1709         (WebCore::notificationMutex):
1710         (WebCore::DatabaseTracker::scheduleNotifyDatabaseChanged):
1711         (WebCore::DatabaseTracker::notifyDatabasesChanged):
1712         * Modules/webdatabase/DatabaseTracker.h:
1713         * Modules/webdatabase/OriginLock.h:
1714         * Modules/webdatabase/SQLCallbackWrapper.h:
1715         (WebCore::SQLCallbackWrapper::clear):
1716         (WebCore::SQLCallbackWrapper::unwrap):
1717         (WebCore::SQLCallbackWrapper::hasCallback):
1718         * Modules/webdatabase/SQLTransactionBackend.cpp:
1719         (WebCore::SQLTransactionBackend::doCleanup):
1720         (WebCore::SQLTransactionBackend::enqueueStatementBackend):
1721         (WebCore::SQLTransactionBackend::getNextStatement):
1722         * Modules/webdatabase/SQLTransactionBackend.h:
1723         * bindings/js/WorkerScriptController.cpp:
1724         (WebCore::WorkerScriptController::scheduleExecutionTermination):
1725         (WebCore::WorkerScriptController::isExecutionTerminating):
1726         * bindings/js/WorkerScriptController.h:
1727         * dom/default/PlatformMessagePortChannel.cpp:
1728         (WebCore::MessagePortChannel::postMessageToRemote):
1729         (WebCore::MessagePortChannel::tryGetMessageFromRemote):
1730         (WebCore::MessagePortChannel::isConnectedTo):
1731         (WebCore::MessagePortChannel::hasPendingActivity):
1732         (WebCore::MessagePortChannel::locallyEntangledPort):
1733         (WebCore::PlatformMessagePortChannel::setRemotePort):
1734         (WebCore::PlatformMessagePortChannel::entangledChannel):
1735         (WebCore::PlatformMessagePortChannel::closeInternal):
1736         * dom/default/PlatformMessagePortChannel.h:
1737         * loader/icon/IconDatabase.cpp:
1738         (WebCore::IconDatabase::removeAllIcons):
1739         (WebCore::IconDatabase::synchronousIconForPageURL):
1740         (WebCore::IconDatabase::synchronousNativeIconForPageURL):
1741         (WebCore::IconDatabase::synchronousIconURLForPageURL):
1742         (WebCore::IconDatabase::retainIconForPageURL):
1743         (WebCore::IconDatabase::performRetainIconForPageURL):
1744         (WebCore::IconDatabase::releaseIconForPageURL):
1745         (WebCore::IconDatabase::performReleaseIconForPageURL):
1746         (WebCore::IconDatabase::setIconDataForIconURL):
1747         (WebCore::IconDatabase::setIconURLForPageURL):
1748         (WebCore::IconDatabase::synchronousLoadDecisionForIconURL):
1749         (WebCore::IconDatabase::synchronousIconDataKnownForIconURL):
1750         (WebCore::IconDatabase::pageURLMappingCount):
1751         (WebCore::IconDatabase::retainedPageURLCount):
1752         (WebCore::IconDatabase::iconRecordCount):
1753         (WebCore::IconDatabase::iconRecordCountWithData):
1754         (WebCore::IconDatabase::wakeSyncThread):
1755         (WebCore::IconDatabase::isOpenBesidesMainThreadCallbacks):
1756         (WebCore::IconDatabase::databasePath):
1757         (WebCore::IconDatabase::getOrCreatePageURLRecord):
1758         (WebCore::IconDatabase::iconDatabaseSyncThread):
1759         (WebCore::IconDatabase::performOpenInitialization):
1760         (WebCore::IconDatabase::performURLImport):
1761         (WebCore::IconDatabase::syncThreadMainLoop):
1762         (WebCore::IconDatabase::performPendingRetainAndReleaseOperations):
1763         (WebCore::IconDatabase::readFromDatabase):
1764         (WebCore::IconDatabase::writeToDatabase):
1765         (WebCore::IconDatabase::pruneUnretainedIcons):
1766         (WebCore::IconDatabase::cleanupSyncThread):
1767         * loader/icon/IconDatabase.h:
1768         * page/scrolling/ScrollingTree.cpp:
1769         (WebCore::ScrollingTree::shouldHandleWheelEventSynchronously):
1770         (WebCore::ScrollingTree::commitNewTreeState):
1771         (WebCore::ScrollingTree::setMainFramePinState):
1772         (WebCore::ScrollingTree::mainFrameScrollPosition):
1773         (WebCore::ScrollingTree::setMainFrameScrollPosition):
1774         (WebCore::ScrollingTree::isPointInNonFastScrollableRegion):
1775         (WebCore::ScrollingTree::isRubberBandInProgress):
1776         (WebCore::ScrollingTree::setMainFrameIsRubberBanding):
1777         (WebCore::ScrollingTree::isScrollSnapInProgress):
1778         (WebCore::ScrollingTree::setMainFrameIsScrollSnapping):
1779         (WebCore::ScrollingTree::setCanRubberBandState):
1780         (WebCore::ScrollingTree::rubberBandsAtLeft):
1781         (WebCore::ScrollingTree::rubberBandsAtRight):
1782         (WebCore::ScrollingTree::rubberBandsAtBottom):
1783         (WebCore::ScrollingTree::rubberBandsAtTop):
1784         (WebCore::ScrollingTree::setScrollPinningBehavior):
1785         (WebCore::ScrollingTree::scrollPinningBehavior):
1786         (WebCore::ScrollingTree::willWheelEventStartSwipeGesture):
1787         (WebCore::ScrollingTree::latchedNode):
1788         (WebCore::ScrollingTree::setLatchedNode):
1789         (WebCore::ScrollingTree::clearLatchedNode):
1790         * page/scrolling/ScrollingTree.h:
1791         * platform/MemoryPressureHandler.h:
1792         * platform/audio/HRTFDatabaseLoader.cpp:
1793         (WebCore::HRTFDatabaseLoader::loadAsynchronously):
1794         (WebCore::HRTFDatabaseLoader::waitForLoaderThreadCompletion):
1795         * platform/audio/HRTFDatabaseLoader.h:
1796         * platform/cocoa/MemoryPressureHandlerCocoa.mm:
1797         (WebCore::MemoryPressureHandler::setReceivedMemoryPressure):
1798         (WebCore::MemoryPressureHandler::clearMemoryPressure):
1799         (WebCore::MemoryPressureHandler::shouldWaitForMemoryClearMessage):
1800         (WebCore::MemoryPressureHandler::respondToMemoryPressureIfNeeded):
1801         * platform/graphics/DisplayRefreshMonitor.cpp:
1802         (WebCore::DisplayRefreshMonitor::displayDidRefresh):
1803         * platform/graphics/DisplayRefreshMonitor.h:
1804         (WebCore::DisplayRefreshMonitor::setMonotonicAnimationStartTime):
1805         (WebCore::DisplayRefreshMonitor::mutex):
1806         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
1807         (WebCore::MediaPlayerPrivateAVFoundation::setDelayCallbacks):
1808         (WebCore::MediaPlayerPrivateAVFoundation::clearMainThreadPendingFlag):
1809         (WebCore::MediaPlayerPrivateAVFoundation::dispatchNotification):
1810         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
1811         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
1812         (WebCore::AVFWrapper::callbackContext):
1813         (WebCore::AVFWrapper::~AVFWrapper):
1814         (WebCore::AVFWrapper::mapLock):
1815         (WebCore::AVFWrapper::addToMap):
1816         (WebCore::AVFWrapper::removeFromMap):
1817         (WebCore::AVFWrapper::periodicTimeObserverCallback):
1818         (WebCore::AVFWrapper::processNotification):
1819         (WebCore::AVFWrapper::loadPlayableCompletionCallback):
1820         (WebCore::AVFWrapper::loadMetadataCompletionCallback):
1821         (WebCore::AVFWrapper::seekCompletedCallback):
1822         (WebCore::AVFWrapper::processCue):
1823         (WebCore::AVFWrapper::legibleOutputCallback):
1824         (WebCore::AVFWrapper::processShouldWaitForLoadingOfResource):
1825         (WebCore::AVFWrapper::resourceLoaderShouldWaitForLoadingOfRequestedResource):
1826         * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.cpp:
1827         (WebCore::InbandTextTrackPrivateGStreamer::handleSample):
1828         (WebCore::InbandTextTrackPrivateGStreamer::notifyTrackOfSample):
1829         * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.h:
1830         * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp:
1831         (WebCore::TrackPrivateBaseGStreamer::tagsChanged):
1832         (WebCore::TrackPrivateBaseGStreamer::notifyTrackOfTagsChanged):
1833         * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.h:
1834         * platform/graphics/mac/DisplayRefreshMonitorMac.cpp:
1835         (WebCore::DisplayRefreshMonitorMac::requestRefreshCallback):
1836         (WebCore::DisplayRefreshMonitorMac::displayLinkFired):
1837         * platform/graphics/win/MediaPlayerPrivateMediaFoundation.cpp:
1838         (WebCore::MediaPlayerPrivateMediaFoundation::addListener):
1839         (WebCore::MediaPlayerPrivateMediaFoundation::removeListener):
1840         (WebCore::MediaPlayerPrivateMediaFoundation::notifyDeleted):
1841         (WebCore::MediaPlayerPrivateMediaFoundation::AsyncCallback::Invoke):
1842         (WebCore::MediaPlayerPrivateMediaFoundation::AsyncCallback::onMediaPlayerDeleted):
1843         * platform/graphics/win/MediaPlayerPrivateMediaFoundation.h:
1844         * platform/ios/LegacyTileCache.h:
1845         * platform/ios/LegacyTileCache.mm:
1846         (WebCore::LegacyTileCache::setTilesOpaque):
1847         (WebCore::LegacyTileCache::doLayoutTiles):
1848         (WebCore::LegacyTileCache::setCurrentScale):
1849         (WebCore::LegacyTileCache::commitScaleChange):
1850         (WebCore::LegacyTileCache::layoutTilesNow):
1851         (WebCore::LegacyTileCache::layoutTilesNowForRect):
1852         (WebCore::LegacyTileCache::removeAllNonVisibleTiles):
1853         (WebCore::LegacyTileCache::removeAllTiles):
1854         (WebCore::LegacyTileCache::removeForegroundTiles):
1855         (WebCore::LegacyTileCache::setContentReplacementImage):
1856         (WebCore::LegacyTileCache::contentReplacementImage):
1857         (WebCore::LegacyTileCache::tileCreationTimerFired):
1858         (WebCore::LegacyTileCache::setNeedsDisplayInRect):
1859         (WebCore::LegacyTileCache::updateTilingMode):
1860         (WebCore::LegacyTileCache::setTilingMode):
1861         (WebCore::LegacyTileCache::doPendingRepaints):
1862         (WebCore::LegacyTileCache::flushSavedDisplayRects):
1863         (WebCore::LegacyTileCache::prepareToDraw):
1864         * platform/ios/LegacyTileLayerPool.h:
1865         * platform/ios/LegacyTileLayerPool.mm:
1866         (WebCore::LegacyTileLayerPool::addLayer):
1867         (WebCore::LegacyTileLayerPool::takeLayerWithSize):
1868         (WebCore::LegacyTileLayerPool::setCapacity):
1869         (WebCore::LegacyTileLayerPool::prune):
1870         (WebCore::LegacyTileLayerPool::drain):
1871         * platform/network/curl/CurlDownload.cpp:
1872         (WebCore::CurlDownloadManager::add):
1873         (WebCore::CurlDownloadManager::remove):
1874         (WebCore::CurlDownloadManager::getActiveDownloadCount):
1875         (WebCore::CurlDownloadManager::getPendingDownloadCount):
1876         (WebCore::CurlDownloadManager::stopThreadIfIdle):
1877         (WebCore::CurlDownloadManager::updateHandleList):
1878         (WebCore::CurlDownload::~CurlDownload):
1879         (WebCore::CurlDownload::init):
1880         (WebCore::CurlDownload::getTempPath):
1881         (WebCore::CurlDownload::getUrl):
1882         (WebCore::CurlDownload::getResponse):
1883         (WebCore::CurlDownload::closeFile):
1884         (WebCore::CurlDownload::didReceiveHeader):
1885         (WebCore::CurlDownload::didReceiveData):
1886         (WebCore::CurlDownload::didFail):
1887         * platform/network/curl/CurlDownload.h:
1888         * platform/network/curl/ResourceHandleManager.cpp:
1889         (WebCore::cookieJarPath):
1890         (WebCore::sharedResourceMutex):
1891         (WebCore::curl_lock_callback):
1892         (WebCore::curl_unlock_callback):
1893         * platform/network/ios/QuickLook.mm:
1894         (WebCore::QLDirectoryAttributes):
1895         (qlPreviewConverterDictionaryMutex):
1896         (WebCore::addQLPreviewConverterWithFileForURL):
1897         (WebCore::qlPreviewConverterUTIForURL):
1898         (WebCore::removeQLPreviewConverterForURL):
1899         (WebCore::safeQLURLForDocumentURLAndResourceURL):
1900         * platform/sql/SQLiteDatabase.cpp:
1901         (WebCore::SQLiteDatabase::close):
1902         (WebCore::SQLiteDatabase::maximumSize):
1903         (WebCore::SQLiteDatabase::setMaximumSize):
1904         (WebCore::SQLiteDatabase::pageSize):
1905         (WebCore::SQLiteDatabase::freeSpaceSize):
1906         (WebCore::SQLiteDatabase::totalSize):
1907         (WebCore::SQLiteDatabase::runIncrementalVacuumCommand):
1908         (WebCore::SQLiteDatabase::setAuthorizer):
1909         * platform/sql/SQLiteDatabase.h:
1910         (WebCore::SQLiteDatabase::databaseMutex):
1911         * platform/sql/SQLiteStatement.cpp:
1912         (WebCore::SQLiteStatement::prepare):
1913         (WebCore::SQLiteStatement::step):
1914         * workers/WorkerThread.cpp:
1915         (WebCore::WorkerThread::start):
1916         (WebCore::WorkerThread::workerThread):
1917         (WebCore::WorkerThread::stop):
1918         * workers/WorkerThread.h:
1919
1920 2015-08-05  Anders Carlsson  <andersca@apple.com>
1921
1922         Move more functions from DatabaseBackendBase to Database
1923         https://bugs.webkit.org/show_bug.cgi?id=147705
1924
1925         Reviewed by Tim Horton.
1926
1927         * Modules/webdatabase/Database.cpp:
1928         (WebCore::guidMutex):
1929         (WebCore::guidToVersionMap):
1930         (WebCore::updateGuidVersionMap):
1931         (WebCore::guidToDatabaseMap):
1932         (WebCore::guidForOriginAndName):
1933         (WebCore::Database::Database):
1934         (WebCore::DoneCreatingDatabaseOnExitCaller::DoneCreatingDatabaseOnExitCaller):
1935         (WebCore::DoneCreatingDatabaseOnExitCaller::~DoneCreatingDatabaseOnExitCaller):
1936         (WebCore::DoneCreatingDatabaseOnExitCaller::setOpenSucceeded):
1937         (WebCore::Database::performOpenAndVerify):
1938         (WebCore::Database::closeDatabase):
1939         (WebCore::Database::getCachedVersion):
1940         (WebCore::Database::setCachedVersion):
1941         * Modules/webdatabase/Database.h:
1942         * Modules/webdatabase/DatabaseBackendBase.cpp:
1943         (WebCore::DatabaseBackendBase::version):
1944         (WebCore::formatErrorMessage): Deleted.
1945         (WebCore::guidMutex): Deleted.
1946         (WebCore::guidToVersionMap): Deleted.
1947         (WebCore::updateGuidVersionMap): Deleted.
1948         (WebCore::guidToDatabaseMap): Deleted.
1949         (WebCore::guidForOriginAndName): Deleted.
1950         (WebCore::DatabaseBackendBase::DatabaseBackendBase): Deleted.
1951         (WebCore::DatabaseBackendBase::closeDatabase): Deleted.
1952         (WebCore::DoneCreatingDatabaseOnExitCaller::DoneCreatingDatabaseOnExitCaller): Deleted.
1953         (WebCore::DoneCreatingDatabaseOnExitCaller::~DoneCreatingDatabaseOnExitCaller): Deleted.
1954         (WebCore::DoneCreatingDatabaseOnExitCaller::setOpenSucceeded): Deleted.
1955         (WebCore::DatabaseBackendBase::performOpenAndVerify): Deleted.
1956         (WebCore::DatabaseBackendBase::getCachedVersion): Deleted.
1957         (WebCore::DatabaseBackendBase::setCachedVersion): Deleted.
1958         * Modules/webdatabase/DatabaseBackendBase.h:
1959
1960 2015-08-05  Anders Carlsson  <andersca@apple.com>
1961
1962         Move more functions from DatabaseBackendBase to Database
1963         https://bugs.webkit.org/show_bug.cgi?id=147703
1964
1965         Reviewed by Tim Horton.
1966
1967         * Modules/webdatabase/Database.cpp:
1968         (WebCore::fullyQualifiedInfoTableName):
1969         (WebCore::setTextValueInDatabase):
1970         (WebCore::retrieveTextResultFromDatabase):
1971         (WebCore::Database::getVersionFromDatabase):
1972         (WebCore::Database::setVersionInDatabase):
1973         (WebCore::Database::performGetTableNames):
1974         * Modules/webdatabase/Database.h:
1975         * Modules/webdatabase/DatabaseBackendBase.cpp:
1976         (WebCore::DatabaseBackendBase::performOpenAndVerify):
1977         (WebCore::DatabaseBackendBase::getActualVersionForTransaction):
1978         (WebCore::DatabaseBackendBase::databaseInfoTableName): Deleted.
1979         (WebCore::fullyQualifiedInfoTableName): Deleted.
1980         (WebCore::retrieveTextResultFromDatabase): Deleted.
1981         (WebCore::setTextValueInDatabase): Deleted.
1982         (WebCore::DatabaseBackendBase::getVersionFromDatabase): Deleted.
1983         (WebCore::DatabaseBackendBase::setVersionInDatabase): Deleted.
1984         * Modules/webdatabase/DatabaseBackendBase.h:
1985
1986 2015-08-05  Alex Christensen  <achristensen@webkit.org>
1987
1988         Build DumpRenderTree with CMake.
1989         https://bugs.webkit.org/show_bug.cgi?id=147519
1990
1991         Reviewed by Brent Fulgham.
1992
1993         * CMakeLists.txt:
1994         WebCoreTestSupport is a static library and should not be linked with WebCore.
1995
1996 2015-08-05  Anders Carlsson  <andersca@apple.com>
1997
1998         Move some more DatabaseBackendBase functions to Database
1999         https://bugs.webkit.org/show_bug.cgi?id=147702
2000
2001         Reviewed by Tim Horton.
2002
2003         * Modules/webdatabase/Database.cpp:
2004         (WebCore::formatErrorMessage):
2005         (WebCore::Database::disableAuthorizer):
2006         (WebCore::Database::enableAuthorizer):
2007         (WebCore::Database::setAuthorizerPermissions):
2008         (WebCore::Database::lastActionChangedDatabase):
2009         (WebCore::Database::lastActionWasInsert):
2010         (WebCore::Database::resetDeletes):
2011         (WebCore::Database::hadDeletes):
2012         (WebCore::Database::resetAuthorizer):
2013         (WebCore::Database::incrementalVacuumIfNeeded):
2014         * Modules/webdatabase/Database.h:
2015         * Modules/webdatabase/DatabaseBackendBase.cpp:
2016         (WebCore::DatabaseBackendBase::disableAuthorizer): Deleted.
2017         (WebCore::DatabaseBackendBase::enableAuthorizer): Deleted.
2018         (WebCore::DatabaseBackendBase::setAuthorizerPermissions): Deleted.
2019         (WebCore::DatabaseBackendBase::lastActionChangedDatabase): Deleted.
2020         (WebCore::DatabaseBackendBase::lastActionWasInsert): Deleted.
2021         (WebCore::DatabaseBackendBase::resetDeletes): Deleted.
2022         (WebCore::DatabaseBackendBase::hadDeletes): Deleted.
2023         (WebCore::DatabaseBackendBase::resetAuthorizer): Deleted.
2024         (WebCore::DatabaseBackendBase::incrementalVacuumIfNeeded): Deleted.
2025         * Modules/webdatabase/DatabaseBackendBase.h:
2026
2027 2015-08-05  Zalan Bujtas  <zalan@apple.com>
2028
2029         [Frame flattening] Return early when child RenderView is not available.
2030         https://bugs.webkit.org/show_bug.cgi?id=147697
2031
2032         Reviewed by Simon Fraser.
2033
2034         No change in functionality.
2035
2036         * rendering/RenderFrameBase.cpp:
2037         (WebCore::RenderFrameBase::peformLayoutWithFlattening):
2038
2039 2015-08-05  Anders Carlsson  <andersca@apple.com>
2040
2041         Remove more dead database code
2042         https://bugs.webkit.org/show_bug.cgi?id=147698
2043
2044         Reviewed by Tim Horton.
2045
2046         * Modules/webdatabase/DatabaseBackendBase.cpp:
2047         (WebCore::DatabaseBackendBase::interrupt): Deleted.
2048         (WebCore::DatabaseBackendBase::isInterrupted): Deleted.
2049         * Modules/webdatabase/DatabaseBackendBase.h:
2050         * Modules/webdatabase/SQLStatementBackend.cpp:
2051         (WebCore::SQLStatementBackend::execute):
2052         * Modules/webdatabase/SQLTransaction.cpp:
2053         (WebCore::SQLTransaction::computeNextStateAndCleanupIfNeeded):
2054         * Modules/webdatabase/SQLTransactionBackend.cpp:
2055         (WebCore::SQLTransactionBackend::computeNextStateAndCleanupIfNeeded):
2056         * platform/sql/SQLiteDatabase.cpp:
2057         (WebCore::SQLiteDatabase::setFullsync):
2058         (WebCore::SQLiteDatabase::SQLiteDatabase): Deleted.
2059         (WebCore::SQLiteDatabase::interrupt): Deleted.
2060         (WebCore::SQLiteDatabase::isInterrupted): Deleted.
2061         * platform/sql/SQLiteDatabase.h:
2062         * platform/sql/SQLiteStatement.cpp:
2063         (WebCore::SQLiteStatement::prepare): Deleted.
2064         (WebCore::SQLiteStatement::step): Deleted.
2065
2066 2015-08-05  Anders Carlsson  <andersca@apple.com>
2067
2068         Fix build.
2069
2070         * platform/cf/CoreMediaSoftLink.cpp:
2071         * platform/cf/CoreMediaSoftLink.h:
2072
2073 2015-08-05  Anders Carlsson  <andersca@apple.com>
2074
2075         Fix build.
2076
2077         * platform/graphics/mac/FontCacheMac.mm:
2078         (WebCore::lookupCTFont):
2079
2080 2015-08-05  Anders Carlsson  <andersca@apple.com>
2081
2082         Change openDatabase to return a Database instead of a DatabaseBackendBase
2083         https://bugs.webkit.org/show_bug.cgi?id=147691
2084
2085         Reviewed by Tim Horton.
2086
2087         * Modules/webdatabase/AbstractDatabaseServer.h:
2088         * Modules/webdatabase/Database.cpp:
2089         (WebCore::Database::create): Deleted.
2090         * Modules/webdatabase/Database.h:
2091         * Modules/webdatabase/DatabaseManager.cpp:
2092         (WebCore::DatabaseManager::openDatabaseBackend):
2093         (WebCore::DatabaseManager::openDatabase):
2094         * Modules/webdatabase/DatabaseManager.h:
2095         * Modules/webdatabase/DatabaseServer.cpp:
2096         (WebCore::DatabaseServer::openDatabase):
2097         (WebCore::DatabaseServer::createDatabase):
2098         * Modules/webdatabase/DatabaseServer.h:
2099
2100 2015-08-05  Myles C. Maxfield  <mmaxfield@apple.com>
2101
2102         [OS X] Migrate to CTFontCreateForCharactersWithLanguage from [NSFont findFontLike:forString:withRange:inLanguage]
2103         https://bugs.webkit.org/show_bug.cgi?id=147483
2104
2105         Reviewed by Dean Jackson.
2106
2107         [NSFont findFontLike:forString:withRange:inLanguage] doesn't properly handle its last argument. In
2108         addition, we want to be moving away from NSFont in the first place and on to Core Text. This new
2109         CoreText function correctly handles its language argument, which is required for language-specific
2110         font fallback.
2111
2112         This patch rolls r187707 back in which was rolled out in r187802 due to test flakiness. This patch
2113         fixes the flakiness.
2114
2115         No new tests because there is no behavior change.
2116
2117         * platform/graphics/FontCache.cpp:
2118         (WebCore::FontCache::purgeInactiveFontData):
2119         * platform/graphics/FontCache.h:
2120         (WebCore::FontCache::platformPurgeInactiveFontData):
2121         * platform/graphics/mac/FontCacheMac.mm:
2122         (WebCore::fallbackDedupSet):
2123         (WebCore::FontCache::platformPurgeInactiveFontData):
2124         (WebCore::lookupCTFont):
2125         (WebCore::FontCache::systemFallbackForCharacters):
2126         * platform/spi/cocoa/CoreTextSPI.h:
2127         * platform/spi/mac/NSFontSPI.h:
2128
2129 2015-08-05  Anders Carlsson  <andersca@apple.com>
2130
2131         Get rid of DatabaseBackend as another step towards merging Database and DatabaseBackendBase
2132         https://bugs.webkit.org/show_bug.cgi?id=147687
2133
2134         Reviewed by Tim Horton.
2135
2136         * CMakeLists.txt:
2137         * Modules/webdatabase/ChangeVersionWrapper.cpp:
2138         (WebCore::ChangeVersionWrapper::performPreflight):
2139         (WebCore::ChangeVersionWrapper::performPostflight):
2140         * Modules/webdatabase/Database.cpp:
2141         (WebCore::Database::Database):
2142         (WebCore::Database::close):
2143         (WebCore::Database::from): Deleted.
2144         (WebCore::Database::backend): Deleted.
2145         * Modules/webdatabase/Database.h:
2146         * Modules/webdatabase/DatabaseBackend.cpp: Removed.
2147         (WebCore::DatabaseBackend::DatabaseBackend): Deleted.
2148         * Modules/webdatabase/DatabaseBackend.h: Removed.
2149         * Modules/webdatabase/DatabaseManager.cpp:
2150         * Modules/webdatabase/DatabaseServer.cpp:
2151         * Modules/webdatabase/DatabaseTask.cpp:
2152         (WebCore::DatabaseTask::DatabaseTask):
2153         (WebCore::DatabaseOpenTask::DatabaseOpenTask):
2154         (WebCore::DatabaseOpenTask::doPerformTask):
2155         (WebCore::DatabaseOpenTask::debugTaskName):
2156         (WebCore::DatabaseCloseTask::DatabaseCloseTask):
2157         (WebCore::DatabaseCloseTask::doPerformTask):
2158         (WebCore::DatabaseCloseTask::debugTaskName):
2159         (WebCore::DatabaseTransactionTask::DatabaseTransactionTask):
2160         (WebCore::DatabaseTransactionTask::~DatabaseTransactionTask):
2161         (WebCore::DatabaseTransactionTask::doPerformTask):
2162         (WebCore::DatabaseTransactionTask::debugTaskName):
2163         (WebCore::DatabaseTableNamesTask::DatabaseTableNamesTask):
2164         (WebCore::DatabaseTableNamesTask::doPerformTask):
2165         (WebCore::DatabaseTableNamesTask::debugTaskName):
2166         (WebCore::DatabaseBackend::DatabaseOpenTask::DatabaseOpenTask): Deleted.
2167         (WebCore::DatabaseBackend::DatabaseOpenTask::doPerformTask): Deleted.
2168         (WebCore::DatabaseBackend::DatabaseOpenTask::debugTaskName): Deleted.
2169         (WebCore::DatabaseBackend::DatabaseCloseTask::DatabaseCloseTask): Deleted.
2170         (WebCore::DatabaseBackend::DatabaseCloseTask::doPerformTask): Deleted.
2171         (WebCore::DatabaseBackend::DatabaseCloseTask::debugTaskName): Deleted.
2172         (WebCore::DatabaseBackend::DatabaseTransactionTask::DatabaseTransactionTask): Deleted.
2173         (WebCore::DatabaseBackend::DatabaseTransactionTask::~DatabaseTransactionTask): Deleted.
2174         (WebCore::DatabaseBackend::DatabaseTransactionTask::doPerformTask): Deleted.
2175         (WebCore::DatabaseBackend::DatabaseTransactionTask::debugTaskName): Deleted.
2176         (WebCore::DatabaseBackend::DatabaseTableNamesTask::DatabaseTableNamesTask): Deleted.
2177         (WebCore::DatabaseBackend::DatabaseTableNamesTask::doPerformTask): Deleted.
2178         (WebCore::DatabaseBackend::DatabaseTableNamesTask::debugTaskName): Deleted.
2179         * Modules/webdatabase/DatabaseTask.h:
2180         (WebCore::DatabaseTask::database):
2181         * Modules/webdatabase/SQLStatementBackend.cpp:
2182         (WebCore::SQLStatementBackend::execute):
2183         * Modules/webdatabase/SQLStatementBackend.h:
2184         * Modules/webdatabase/SQLTransactionBackend.cpp:
2185         (WebCore::SQLTransactionBackend::executeSQL):
2186         (WebCore::SQLTransactionBackend::openTransactionAndPreflight):
2187         * WebCore.vcxproj/WebCore.vcxproj:
2188         * WebCore.vcxproj/WebCore.vcxproj.filters:
2189         * WebCore.xcodeproj/project.pbxproj:
2190
2191 2015-08-04  Filip Pizlo  <fpizlo@apple.com>
2192
2193         Rename Mutex to DeprecatedMutex
2194         https://bugs.webkit.org/show_bug.cgi?id=147675
2195
2196         Reviewed by Geoffrey Garen.
2197
2198         No new tests because this is just a renaming.
2199
2200         * Modules/webaudio/AsyncAudioDecoder.cpp:
2201         (WebCore::AsyncAudioDecoder::AsyncAudioDecoder):
2202         (WebCore::AsyncAudioDecoder::runLoop):
2203         * Modules/webaudio/AsyncAudioDecoder.h:
2204         * Modules/webaudio/AudioContext.h:
2205         * Modules/webaudio/MediaStreamAudioSource.cpp:
2206         (WebCore::MediaStreamAudioSource::addAudioConsumer):
2207         (WebCore::MediaStreamAudioSource::removeAudioConsumer):
2208         (WebCore::MediaStreamAudioSource::setAudioFormat):
2209         (WebCore::MediaStreamAudioSource::consumeAudio):
2210         * Modules/webaudio/MediaStreamAudioSource.h:
2211         * Modules/webdatabase/Database.cpp:
2212         (WebCore::Database::close):
2213         (WebCore::Database::runTransaction):
2214         (WebCore::Database::inProgressTransactionCompleted):
2215         (WebCore::Database::hasPendingTransaction):
2216         * Modules/webdatabase/DatabaseBackend.h:
2217         * Modules/webdatabase/DatabaseBackendBase.cpp:
2218         (WebCore::DatabaseBackendBase::performOpenAndVerify):
2219         (WebCore::DatabaseBackendBase::isInterrupted):
2220         * Modules/webdatabase/DatabaseContext.cpp:
2221         (WebCore::DatabaseContext::databaseThread):
2222         (WebCore::DatabaseContext::setPaused):
2223         * Modules/webdatabase/DatabaseContext.h:
2224         * Modules/webdatabase/DatabaseTask.h:
2225         * Modules/webdatabase/DatabaseThread.cpp:
2226         (WebCore::DatabaseThread::start):
2227         (WebCore::DatabaseThread::setPaused):
2228         (WebCore::DatabaseThread::handlePausedQueue):
2229         (WebCore::DatabaseThread::databaseThread):
2230         * Modules/webdatabase/DatabaseThread.h:
2231         * Modules/webdatabase/DatabaseTracker.cpp:
2232         (WebCore::DatabaseTracker::setDatabaseDirectoryPath):
2233         (WebCore::DatabaseTracker::canEstablishDatabase):
2234         (WebCore::DatabaseTracker::retryCanEstablishDatabase):
2235         (WebCore::DatabaseTracker::hasEntryForOrigin):
2236         (WebCore::DatabaseTracker::getMaxSizeForDatabase):
2237         (WebCore::DatabaseTracker::closeAllDatabases):
2238         (WebCore::DatabaseTracker::interruptAllDatabasesForContext):
2239         (WebCore::DatabaseTracker::fullPathForDatabase):
2240         (WebCore::DatabaseTracker::origins):
2241         (WebCore::DatabaseTracker::databaseNamesForOrigin):
2242         (WebCore::DatabaseTracker::detailsForNameAndOrigin):
2243         (WebCore::DatabaseTracker::setDatabaseDetails):
2244         (WebCore::DatabaseTracker::doneCreatingDatabase):
2245         (WebCore::DatabaseTracker::addOpenDatabase):
2246         (WebCore::DatabaseTracker::removeOpenDatabase):
2247         (WebCore::DatabaseTracker::getOpenDatabases):
2248         (WebCore::DatabaseTracker::originLockFor):
2249         (WebCore::DatabaseTracker::quotaForOrigin):
2250         (WebCore::DatabaseTracker::setQuota):
2251         (WebCore::DatabaseTracker::deleteOrigin):
2252         (WebCore::DatabaseTracker::deleteDatabase):
2253         (WebCore::DatabaseTracker::deleteDatabaseFile):
2254         (WebCore::DatabaseTracker::removeDeletedOpenedDatabases):
2255         (WebCore::DatabaseTracker::deleteDatabaseFileIfEmpty):
2256         (WebCore::DatabaseTracker::openDatabaseMutex):
2257         (WebCore::DatabaseTracker::setDatabasesPaused):
2258         (WebCore::DatabaseTracker::setClient):
2259         (WebCore::notificationMutex):
2260         (WebCore::DatabaseTracker::scheduleNotifyDatabaseChanged):
2261         (WebCore::DatabaseTracker::notifyDatabasesChanged):
2262         * Modules/webdatabase/DatabaseTracker.h:
2263         * Modules/webdatabase/OriginLock.h:
2264         * Modules/webdatabase/SQLCallbackWrapper.h:
2265         (WebCore::SQLCallbackWrapper::clear):
2266         (WebCore::SQLCallbackWrapper::unwrap):
2267         (WebCore::SQLCallbackWrapper::hasCallback):
2268         * Modules/webdatabase/SQLTransactionBackend.cpp:
2269         (WebCore::SQLTransactionBackend::doCleanup):
2270         (WebCore::SQLTransactionBackend::enqueueStatementBackend):
2271         (WebCore::SQLTransactionBackend::getNextStatement):
2272         * Modules/webdatabase/SQLTransactionBackend.h:
2273         * bindings/js/WorkerScriptController.cpp:
2274         (WebCore::WorkerScriptController::scheduleExecutionTermination):
2275         (WebCore::WorkerScriptController::isExecutionTerminating):
2276         * bindings/js/WorkerScriptController.h:
2277         * dom/default/PlatformMessagePortChannel.cpp:
2278         (WebCore::MessagePortChannel::postMessageToRemote):
2279         (WebCore::MessagePortChannel::tryGetMessageFromRemote):
2280         (WebCore::MessagePortChannel::isConnectedTo):
2281         (WebCore::MessagePortChannel::hasPendingActivity):
2282         (WebCore::MessagePortChannel::locallyEntangledPort):
2283         (WebCore::PlatformMessagePortChannel::setRemotePort):
2284         (WebCore::PlatformMessagePortChannel::entangledChannel):
2285         (WebCore::PlatformMessagePortChannel::closeInternal):
2286         * dom/default/PlatformMessagePortChannel.h:
2287         * loader/icon/IconDatabase.cpp:
2288         (WebCore::IconDatabase::removeAllIcons):
2289         (WebCore::IconDatabase::synchronousIconForPageURL):
2290         (WebCore::IconDatabase::synchronousNativeIconForPageURL):
2291         (WebCore::IconDatabase::synchronousIconURLForPageURL):
2292         (WebCore::IconDatabase::retainIconForPageURL):
2293         (WebCore::IconDatabase::performRetainIconForPageURL):
2294         (WebCore::IconDatabase::releaseIconForPageURL):
2295         (WebCore::IconDatabase::performReleaseIconForPageURL):
2296         (WebCore::IconDatabase::setIconDataForIconURL):
2297         (WebCore::IconDatabase::setIconURLForPageURL):
2298         (WebCore::IconDatabase::synchronousLoadDecisionForIconURL):
2299         (WebCore::IconDatabase::synchronousIconDataKnownForIconURL):
2300         (WebCore::IconDatabase::pageURLMappingCount):
2301         (WebCore::IconDatabase::retainedPageURLCount):
2302         (WebCore::IconDatabase::iconRecordCount):
2303         (WebCore::IconDatabase::iconRecordCountWithData):
2304         (WebCore::IconDatabase::wakeSyncThread):
2305         (WebCore::IconDatabase::isOpenBesidesMainThreadCallbacks):
2306         (WebCore::IconDatabase::databasePath):
2307         (WebCore::IconDatabase::getOrCreatePageURLRecord):
2308         (WebCore::IconDatabase::iconDatabaseSyncThread):
2309         (WebCore::IconDatabase::performOpenInitialization):
2310         (WebCore::IconDatabase::performURLImport):
2311         (WebCore::IconDatabase::syncThreadMainLoop):
2312         (WebCore::IconDatabase::performPendingRetainAndReleaseOperations):
2313         (WebCore::IconDatabase::readFromDatabase):
2314         (WebCore::IconDatabase::writeToDatabase):
2315         (WebCore::IconDatabase::pruneUnretainedIcons):
2316         (WebCore::IconDatabase::cleanupSyncThread):
2317         * loader/icon/IconDatabase.h:
2318         * page/scrolling/ScrollingTree.cpp:
2319         (WebCore::ScrollingTree::shouldHandleWheelEventSynchronously):
2320         (WebCore::ScrollingTree::commitNewTreeState):
2321         (WebCore::ScrollingTree::setMainFramePinState):
2322         (WebCore::ScrollingTree::mainFrameScrollPosition):
2323         (WebCore::ScrollingTree::setMainFrameScrollPosition):
2324         (WebCore::ScrollingTree::isPointInNonFastScrollableRegion):
2325         (WebCore::ScrollingTree::isRubberBandInProgress):
2326         (WebCore::ScrollingTree::setMainFrameIsRubberBanding):
2327         (WebCore::ScrollingTree::isScrollSnapInProgress):
2328         (WebCore::ScrollingTree::setMainFrameIsScrollSnapping):
2329         (WebCore::ScrollingTree::setCanRubberBandState):
2330         (WebCore::ScrollingTree::rubberBandsAtLeft):
2331         (WebCore::ScrollingTree::rubberBandsAtRight):
2332         (WebCore::ScrollingTree::rubberBandsAtBottom):
2333         (WebCore::ScrollingTree::rubberBandsAtTop):
2334         (WebCore::ScrollingTree::setScrollPinningBehavior):
2335         (WebCore::ScrollingTree::scrollPinningBehavior):
2336         (WebCore::ScrollingTree::willWheelEventStartSwipeGesture):
2337         (WebCore::ScrollingTree::latchedNode):
2338         (WebCore::ScrollingTree::setLatchedNode):
2339         (WebCore::ScrollingTree::clearLatchedNode):
2340         * page/scrolling/ScrollingTree.h:
2341         * platform/MemoryPressureHandler.h:
2342         * platform/audio/HRTFDatabaseLoader.cpp:
2343         (WebCore::HRTFDatabaseLoader::loadAsynchronously):
2344         (WebCore::HRTFDatabaseLoader::waitForLoaderThreadCompletion):
2345         * platform/audio/HRTFDatabaseLoader.h:
2346         * platform/cocoa/MemoryPressureHandlerCocoa.mm:
2347         (WebCore::MemoryPressureHandler::setReceivedMemoryPressure):
2348         (WebCore::MemoryPressureHandler::clearMemoryPressure):
2349         (WebCore::MemoryPressureHandler::shouldWaitForMemoryClearMessage):
2350         (WebCore::MemoryPressureHandler::respondToMemoryPressureIfNeeded):
2351         * platform/graphics/DisplayRefreshMonitor.cpp:
2352         (WebCore::DisplayRefreshMonitor::displayDidRefresh):
2353         * platform/graphics/DisplayRefreshMonitor.h:
2354         (WebCore::DisplayRefreshMonitor::setMonotonicAnimationStartTime):
2355         (WebCore::DisplayRefreshMonitor::mutex):
2356         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
2357         (WebCore::MediaPlayerPrivateAVFoundation::setDelayCallbacks):
2358         (WebCore::MediaPlayerPrivateAVFoundation::clearMainThreadPendingFlag):
2359         (WebCore::MediaPlayerPrivateAVFoundation::dispatchNotification):
2360         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
2361         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
2362         (WebCore::AVFWrapper::callbackContext):
2363         (WebCore::AVFWrapper::~AVFWrapper):
2364         (WebCore::AVFWrapper::mapLock):
2365         (WebCore::AVFWrapper::addToMap):
2366         (WebCore::AVFWrapper::removeFromMap):
2367         (WebCore::AVFWrapper::periodicTimeObserverCallback):
2368         (WebCore::AVFWrapper::processNotification):
2369         (WebCore::AVFWrapper::loadPlayableCompletionCallback):
2370         (WebCore::AVFWrapper::loadMetadataCompletionCallback):
2371         (WebCore::AVFWrapper::seekCompletedCallback):
2372         (WebCore::AVFWrapper::processCue):
2373         (WebCore::AVFWrapper::legibleOutputCallback):
2374         (WebCore::AVFWrapper::processShouldWaitForLoadingOfResource):
2375         (WebCore::AVFWrapper::resourceLoaderShouldWaitForLoadingOfRequestedResource):
2376         * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.cpp:
2377         (WebCore::InbandTextTrackPrivateGStreamer::handleSample):
2378         (WebCore::InbandTextTrackPrivateGStreamer::notifyTrackOfSample):
2379         * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.h:
2380         * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp:
2381         (WebCore::TrackPrivateBaseGStreamer::tagsChanged):
2382         (WebCore::TrackPrivateBaseGStreamer::notifyTrackOfTagsChanged):
2383         * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.h:
2384         * platform/graphics/mac/DisplayRefreshMonitorMac.cpp:
2385         (WebCore::DisplayRefreshMonitorMac::requestRefreshCallback):
2386         (WebCore::DisplayRefreshMonitorMac::displayLinkFired):
2387         * platform/graphics/win/MediaPlayerPrivateMediaFoundation.cpp:
2388         (WebCore::MediaPlayerPrivateMediaFoundation::addListener):
2389         (WebCore::MediaPlayerPrivateMediaFoundation::removeListener):
2390         (WebCore::MediaPlayerPrivateMediaFoundation::notifyDeleted):
2391         (WebCore::MediaPlayerPrivateMediaFoundation::AsyncCallback::Invoke):
2392         (WebCore::MediaPlayerPrivateMediaFoundation::AsyncCallback::onMediaPlayerDeleted):
2393         * platform/graphics/win/MediaPlayerPrivateMediaFoundation.h:
2394         * platform/ios/LegacyTileCache.h:
2395         * platform/ios/LegacyTileCache.mm:
2396         (WebCore::LegacyTileCache::setTilesOpaque):
2397         (WebCore::LegacyTileCache::doLayoutTiles):
2398         (WebCore::LegacyTileCache::setCurrentScale):
2399         (WebCore::LegacyTileCache::commitScaleChange):
2400         (WebCore::LegacyTileCache::layoutTilesNow):
2401         (WebCore::LegacyTileCache::layoutTilesNowForRect):
2402         (WebCore::LegacyTileCache::removeAllNonVisibleTiles):
2403         (WebCore::LegacyTileCache::removeAllTiles):
2404         (WebCore::LegacyTileCache::removeForegroundTiles):
2405         (WebCore::LegacyTileCache::setContentReplacementImage):
2406         (WebCore::LegacyTileCache::contentReplacementImage):
2407         (WebCore::LegacyTileCache::tileCreationTimerFired):
2408         (WebCore::LegacyTileCache::setNeedsDisplayInRect):
2409         (WebCore::LegacyTileCache::updateTilingMode):
2410         (WebCore::LegacyTileCache::setTilingMode):
2411         (WebCore::LegacyTileCache::doPendingRepaints):
2412         (WebCore::LegacyTileCache::flushSavedDisplayRects):
2413         (WebCore::LegacyTileCache::prepareToDraw):
2414         * platform/ios/LegacyTileLayerPool.h:
2415         * platform/ios/LegacyTileLayerPool.mm:
2416         (WebCore::LegacyTileLayerPool::addLayer):
2417         (WebCore::LegacyTileLayerPool::takeLayerWithSize):
2418         (WebCore::LegacyTileLayerPool::setCapacity):
2419         (WebCore::LegacyTileLayerPool::prune):
2420         (WebCore::LegacyTileLayerPool::drain):
2421         * platform/network/curl/CurlDownload.cpp:
2422         (WebCore::CurlDownloadManager::add):
2423         (WebCore::CurlDownloadManager::remove):
2424         (WebCore::CurlDownloadManager::getActiveDownloadCount):
2425         (WebCore::CurlDownloadManager::getPendingDownloadCount):
2426         (WebCore::CurlDownloadManager::stopThreadIfIdle):
2427         (WebCore::CurlDownloadManager::updateHandleList):
2428         (WebCore::CurlDownload::~CurlDownload):
2429         (WebCore::CurlDownload::init):
2430         (WebCore::CurlDownload::getTempPath):
2431         (WebCore::CurlDownload::getUrl):
2432         (WebCore::CurlDownload::getResponse):
2433         (WebCore::CurlDownload::closeFile):
2434         (WebCore::CurlDownload::didReceiveHeader):
2435         (WebCore::CurlDownload::didReceiveData):
2436         (WebCore::CurlDownload::didFail):
2437         * platform/network/curl/CurlDownload.h:
2438         * platform/network/curl/ResourceHandleManager.cpp:
2439         (WebCore::cookieJarPath):
2440         (WebCore::sharedResourceMutex):
2441         (WebCore::curl_lock_callback):
2442         (WebCore::curl_unlock_callback):
2443         * platform/network/ios/QuickLook.mm:
2444         (WebCore::QLDirectoryAttributes):
2445         (qlPreviewConverterDictionaryMutex):
2446         (WebCore::addQLPreviewConverterWithFileForURL):
2447         (WebCore::qlPreviewConverterUTIForURL):
2448         (WebCore::removeQLPreviewConverterForURL):
2449         (WebCore::safeQLURLForDocumentURLAndResourceURL):
2450         * platform/sql/SQLiteDatabase.cpp:
2451         (WebCore::SQLiteDatabase::close):
2452         (WebCore::SQLiteDatabase::interrupt):
2453         (WebCore::SQLiteDatabase::maximumSize):
2454         (WebCore::SQLiteDatabase::setMaximumSize):
2455         (WebCore::SQLiteDatabase::pageSize):
2456         (WebCore::SQLiteDatabase::freeSpaceSize):
2457         (WebCore::SQLiteDatabase::totalSize):
2458         (WebCore::SQLiteDatabase::runIncrementalVacuumCommand):
2459         (WebCore::SQLiteDatabase::setAuthorizer):
2460         * platform/sql/SQLiteDatabase.h:
2461         (WebCore::SQLiteDatabase::databaseMutex):
2462         * platform/sql/SQLiteStatement.cpp:
2463         (WebCore::SQLiteStatement::prepare):
2464         (WebCore::SQLiteStatement::step):
2465         * workers/WorkerThread.cpp:
2466         (WebCore::WorkerThread::start):
2467         (WebCore::WorkerThread::workerThread):
2468         (WebCore::WorkerThread::stop):
2469         * workers/WorkerThread.h:
2470
2471 2015-08-05  Matthew Daiter  <mdaiter@apple.com>
2472
2473         Adding in MediaPrivateMediaStreamEngine to default compile
2474         https://bugs.webkit.org/show_bug.cgi?id=146790
2475         <rdar://problem/21747289>
2476
2477         Reviewed by Eric Carlson.
2478
2479         * WebCore.xcodeproj/project.pbxproj:
2480         * platform/mediastream/MediaStreamPrivate.h:
2481         (WebCore::MediaStreamPrivate::MediaStreamPrivate):
2482
2483 2015-08-05  Matthew Daiter  <mdaiter@apple.com>
2484
2485         Remove m_synchronizer from MediaPlayerPrivateMediaStream
2486         https://bugs.webkit.org/show_bug.cgi?id=147637
2487
2488         Reviewed by Eric Carlson.
2489
2490         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.h:
2491         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:
2492         (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::playInternal): Deleted.
2493
2494 2015-08-05  Wenson Hsieh  <wenson_hsieh@apple.com>
2495
2496         Build fix after 187961
2497
2498         * platform/mac/ThemeMac.mm:
2499         (WebCore::ThemeMac::drawCellOrFocusRingWithViewIntoContext):
2500
2501 2015-08-05  Daniel Bates  <dabates@apple.com>
2502
2503         REGRESSION (r185111): Clicking phone numbers doesn't prompt to call sometimes
2504         https://bugs.webkit.org/show_bug.cgi?id=147678
2505         <rdar://problem/21827815>
2506
2507         Reviewed by Brady Eidson.
2508
2509         Fixes an issue where a non-user-initiated navigation of the main frame to a phone link (tel URL)
2510         may be ignored. The navigation is ignored if the page was reloaded as a result of a web content
2511         process crash, its lifetime exceeded the back-forward cache expiration interval, or a person
2512         quits and opens Safari again, among other scenarios.
2513
2514         * history/HistoryItem.cpp:
2515         (WebCore::HistoryItem::setShouldOpenExternalURLsPolicy): Added.
2516         (WebCore::HistoryItem::shouldOpenExternalURLsPolicy): Added.
2517         * history/HistoryItem.h:
2518         * loader/FrameLoader.cpp:
2519         (WebCore::FrameLoader::loadDifferentDocumentItem): Apply the "should open external URLs" policy
2520         from the history item, if applicable. Also, be more explicit when instantiating a NavigationAction
2521         so as to help make it straightforward to reduce the number of NavigationAction constructors we have
2522         in the future.
2523         * loader/HistoryController.cpp:
2524         (WebCore::HistoryController::saveDocumentState): Save the "should open external URLs" policy to
2525         the history item.
2526         (WebCore::HistoryController::restoreDocumentState): Apply the "should open external URLs" policy
2527         from the history item to the document loader.
2528         (WebCore::HistoryController::initializeItem): Update the "should open external URLs" policy of
2529         the history item to reflect the policy of the document loader associated with the current frame.
2530
2531 2015-08-04  Wenson Hsieh  <wenson_hsieh@apple.com>
2532
2533         Checkboxes and radio buttons should scale when zooming or pinching to zoom
2534         https://bugs.webkit.org/show_bug.cgi?id=147405
2535
2536         Reviewed by Dean Jackson.
2537
2538         Refactors paintButton and paintToggleButton to use a temporary buffer when rendering
2539         if the controls are zoomed. This affects checkboxes, radio buttons, and normal (push)
2540         buttons.
2541
2542         * platform/mac/ThemeMac.h:
2543         * platform/mac/ThemeMac.mm:
2544         (WebCore::paintToggleButton): Refactored to use drawCellOrFocusRingWithViewIntoContext.
2545         (WebCore::paintButton): Refactored to use drawCellOrFocusRingWithViewIntoContext.
2546         (WebCore::ThemeMac::drawCellOrFocusRingWithViewIntoContext): Draws a given button cell
2547             and/or its focus ring into the given context, optionally using an offscreen buffer.
2548             This is a static function in ThemeMac so it can be accessed later on by
2549             RenderThemeMac when painting search fields that scale with zoom.
2550         (WebCore::ThemeMac::paint):
2551         (WebCore::buttonFocusRectOutlineWidth): Deleted. Made this value into a const float.
2552
2553 2015-08-04  Doug Russell  <d_russell@apple.com>
2554
2555         AX: tree item children returned from ranged getter are different from full array of children
2556         https://bugs.webkit.org/show_bug.cgi?id=147660
2557
2558         Reviewed by Chris Fleizach.
2559
2560         Add an isTreeItem() check in ranged element getter so that it matches the logic in 
2561         the getter for the full children array. This prevents returning a row as a child
2562         when only the rows contents should be returned. This prevents navigation issues on
2563         websites without aria outlines.
2564
2565         Test: accessibility/mac/aria-tree-item-children.html
2566
2567         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
2568         (-[WebAccessibilityObjectWrapper accessibilityArrayAttributeValues:index:maxCount:]):
2569
2570 2015-08-04  Anders Carlsson  <andersca@apple.com>
2571
2572         CTTE the database task code
2573         https://bugs.webkit.org/show_bug.cgi?id=147673
2574
2575         Reviewed by Andreas Kling.
2576
2577         * Modules/webdatabase/Database.cpp:
2578         (WebCore::Database::openAndVerifyVersion):
2579         (WebCore::Database::markAsDeletedAndClose):
2580         (WebCore::Database::tableNames):
2581         * Modules/webdatabase/DatabaseTask.cpp:
2582         (WebCore::DatabaseTask::DatabaseTask):
2583         (WebCore::DatabaseTask::performTask):
2584         (WebCore::DatabaseBackend::DatabaseOpenTask::DatabaseOpenTask):
2585         (WebCore::DatabaseBackend::DatabaseOpenTask::doPerformTask):
2586         (WebCore::DatabaseBackend::DatabaseCloseTask::DatabaseCloseTask):
2587         (WebCore::DatabaseBackend::DatabaseCloseTask::doPerformTask):
2588         (WebCore::DatabaseBackend::DatabaseTransactionTask::DatabaseTransactionTask):
2589         (WebCore::DatabaseBackend::DatabaseTableNamesTask::DatabaseTableNamesTask):
2590         (WebCore::DatabaseBackend::DatabaseTableNamesTask::doPerformTask):
2591         * Modules/webdatabase/DatabaseTask.h:
2592         (WebCore::DatabaseTask::database):
2593         * Modules/webdatabase/DatabaseThread.cpp:
2594         (WebCore::SameDatabasePredicate::operator()):
2595
2596 2015-08-04  Brent Fulgham  <bfulgham@apple.com>
2597
2598         REGRESSION (r173784): [Mac] Correct latching error for non-scrollable iframe nested inside scrollable div.
2599         https://bugs.webkit.org/show_bug.cgi?id=147668
2600         <rdar://problem/21870332>
2601
2602         Reviewed by Simon Fraser.
2603
2604         Test: platform/mac/fast/scrolling/scroll-div-with-nested-nonscrollable-iframe.html
2605
2606         When we are wrapping up processing of the wheel event for a given frame, if the current latching context
2607         does NOT apply to the current frame (e.g., because it's latched to an enclosing frame) we should not pass
2608         wheel events directly to the latched elements scrollable container. Instead, we should just give the current
2609         frame an opportunity to perform any custom wheel event handling and return, so that the enclosing (latched)
2610         frame can do the rest of its event handling.
2611         
2612         If we don't do this, we incorrectly ask the enclosing frame to process the event, then return claiming that
2613         we handled the event, preventing the enclosing frame from doing its part of the processing.
2614
2615         * page/mac/EventHandlerMac.mm:
2616         (WebCore::EventHandler::platformCompleteWheelEvent):
2617
2618 2015-08-04  Alex Christensen  <achristensen@webkit.org>
2619
2620         Soft link libGLESv2 and libEGL on Windows again
2621         https://bugs.webkit.org/show_bug.cgi?id=147671
2622
2623         Reviewed by Dean Jackson.
2624
2625         * platform/graphics/PlatformDisplay.cpp:
2626         (WebCore::PlatformDisplay::initializeEGLDisplay):
2627         Fail gracefully if libEGL is not found.
2628
2629 2015-08-04  Anders Carlsson  <andersca@apple.com>
2630
2631         Remove another unused database function
2632         https://bugs.webkit.org/show_bug.cgi?id=147670
2633
2634         Reviewed by Daniel Bates.
2635
2636         This was used back when we had WebSQL support in workers, we can safely remove all these functions now.
2637
2638         * Modules/webdatabase/AbstractDatabaseServer.h:
2639         * Modules/webdatabase/DatabaseManager.cpp:
2640         (WebCore::DatabaseManager::interruptAllDatabasesForContext): Deleted.
2641         * Modules/webdatabase/DatabaseManager.h:
2642         * Modules/webdatabase/DatabaseServer.cpp:
2643         (WebCore::DatabaseServer::interruptAllDatabasesForContext): Deleted.
2644         * Modules/webdatabase/DatabaseServer.h:
2645         * Modules/webdatabase/DatabaseTracker.cpp:
2646         (WebCore::DatabaseTracker::interruptAllDatabasesForContext): Deleted.
2647         * Modules/webdatabase/DatabaseTracker.h:
2648
2649 2015-08-04  Anders Carlsson  <andersca@apple.com>
2650
2651         Remove database thread pause code
2652         https://bugs.webkit.org/show_bug.cgi?id=147669
2653
2654         Reviewed by Daniel Bates.
2655
2656         We now grab power assertions while running SQLite transactions, 
2657         and this code isn't used at all with modern WebKit so let's just get rid of it.
2658
2659         * Modules/webdatabase/DatabaseContext.cpp:
2660         (WebCore::DatabaseContext::DatabaseContext): Deleted.
2661         (WebCore::DatabaseContext::databaseThread): Deleted.
2662         (WebCore::DatabaseContext::setPaused): Deleted.
2663         * Modules/webdatabase/DatabaseContext.h:
2664         * Modules/webdatabase/DatabaseTask.cpp:
2665         (WebCore::Database::DatabaseTransactionTask::shouldPerformWhilePaused): Deleted.
2666         * Modules/webdatabase/DatabaseTask.h:
2667         * Modules/webdatabase/DatabaseThread.cpp:
2668         (WebCore::DatabaseThread::DatabaseThread): Deleted.
2669         (WebCore::DatabaseThread::requestTermination): Deleted.
2670         (WebCore::DatabaseUnpauseTask::DatabaseUnpauseTask): Deleted.
2671         (WebCore::DatabaseUnpauseTask::shouldPerformWhilePaused): Deleted.
2672         (WebCore::DatabaseUnpauseTask::doPerformTask): Deleted.
2673         (WebCore::DatabaseUnpauseTask::debugTaskName): Deleted.
2674         (WebCore::DatabaseThread::setPaused): Deleted.
2675         (WebCore::DatabaseThread::handlePausedQueue): Deleted.
2676         (WebCore::DatabaseThread::databaseThread): Deleted.
2677         * Modules/webdatabase/DatabaseThread.h:
2678         * Modules/webdatabase/DatabaseTracker.cpp:
2679         (WebCore::DatabaseTracker::setDatabasesPaused): Deleted.
2680         * Modules/webdatabase/DatabaseTracker.h:
2681
2682 2015-08-04  Chris Dumez  <cdumez@apple.com>
2683
2684         Subframes with no current HistoryItem should not prevent page-caching
2685         https://bugs.webkit.org/show_bug.cgi?id=147649
2686         <rdar://problem/21614832>
2687
2688         Reviewed by Andreas Kling.
2689
2690         Subframes with no current HistoryItem should not prevent page-caching.
2691         We need one for the main frame as this is the key in the PageCache.
2692         However, there is no reason to require one for subframes.
2693
2694         This is a common reason for page-caching failures nowadays.
2695
2696         Frames do no have a current HistoryItem until something has been loaded in them.
2697
2698         Test: http/tests/navigation/page-cache-iframe-no-current-historyItem.html
2699
2700         * history/PageCache.cpp:
2701         (WebCore::logCanCacheFrameDecision):
2702         (WebCore::PageCache::canCachePageContainingThisFrame):
2703
2704 2015-08-04  Brent Fulgham  <bfulgham@apple.com>
2705
2706         [Win] Build fix after r187908
2707
2708         * platform/win/WindowsTouch.h: If WINVER is set properly, we
2709         don't need these definitions.
2710
2711 2015-08-04  Anders Carlsson  <andersca@apple.com>
2712
2713         Remove an unused Database function
2714         https://bugs.webkit.org/show_bug.cgi?id=147661
2715
2716         Reviewed by Simon Fraser.
2717
2718         * Modules/webdatabase/Database.cpp:
2719         (WebCore::Database::closeImmediately): Deleted.
2720         * Modules/webdatabase/Database.h:
2721
2722 2015-08-04  Brady Eidson  <beidson@apple.com>
2723
2724         Crash when following a Google search link to Twitter with Limit Adult Content enabled.
2725         <rdar://problem/22123707> and https://bugs.webkit.org/show_bug.cgi?id=147651
2726
2727         Reviewed by Sam Weinig.
2728
2729         No new tests (Doesn't occur in a tested config).
2730
2731         For now, we'll skip the application cache for main resource loads if parental controls are enabled.
2732
2733         * loader/DocumentLoader.cpp:
2734         (WebCore::DocumentLoader::willSendRequest):
2735         (WebCore::DocumentLoader::startLoadingMainResource):
2736
2737 2015-08-04  Matthew Daiter  <mdaiter@apple.com>
2738
2739         Added buffer to AVMediaCaptureSource
2740         https://bugs.webkit.org/show_bug.cgi?id=147454
2741         <rdar://problem/22079502>
2742
2743         Reviewed by Jer Noble.
2744
2745         * platform/mediastream/mac/AVMediaCaptureSource.h:
2746         (WebCore::AVMediaCaptureSource::buffer):
2747         (WebCore::AVMediaCaptureSource::setBuffer):
2748         * platform/mediastream/mac/AVVideoCaptureSource.mm:
2749         (WebCore::AVVideoCaptureSource::captureOutputDidOutputSampleBufferFromConnection):
2750
2751 2015-08-04  Matthew Daiter  <mdaiter@apple.com>
2752
2753         Needless assignment of usingDot
2754         https://bugs.webkit.org/show_bug.cgi?id=147514
2755
2756         Reviewed by Eric Carlson.
2757
2758         * platform/graphics/mac/GraphicsContextMac.mm:
2759         (WebCore::GraphicsContext::drawLineForDocumentMarker): Deleted.
2760
2761 2015-08-04  Chris Dumez  <cdumez@apple.com>
2762
2763         shouldParseTelephoneNumbersInNode() does not need to check for Comment nodes
2764         https://bugs.webkit.org/show_bug.cgi?id=147630
2765
2766         Reviewed by Sam Weinig.
2767
2768         shouldParseTelephoneNumbersInNode() does not need to check for Comment
2769         nodes. We already know the input is a ContainerNode and a Comment is
2770         NOT a ContainerNode. Also, we were already doing a isElementNode()
2771         check before calling disallowTelephoneNumberParsing().
2772
2773         I also updated the function to use a for loop for clarity and dropped
2774         the isElementNode() check as calling hasTagName() / isLink() on a
2775         ContainerNode is as fast all calling it on an Element nowadays.
2776
2777         * html/parser/HTMLTreeBuilder.cpp:
2778         (WebCore::disallowTelephoneNumberParsing):
2779         (WebCore::shouldParseTelephoneNumbersInNode):
2780
2781 2015-08-04  Eric Carlson  <eric.carlson@apple.com>
2782
2783         [Mac] Do not require a video track for AirPlay
2784         https://bugs.webkit.org/show_bug.cgi?id=147647
2785
2786         Reviewed by Jer Noble.
2787
2788         * Modules/mediacontrols/mediaControlsApple.js:
2789         (Controller.prototype.handleReadyStateChange): Call updateWirelessTargetAvailable().
2790         (Controller.prototype.updateHasVideo): Don't call updateWirelessTargetAvailable().
2791         (Controller.prototype.updateWirelessTargetAvailable): Don't require video.
2792
2793         * html/HTMLMediaElement.cpp:
2794         (WebCore::HTMLMediaElement::setReadyState): Call updateMediaState when we reach HAVE_METADATA.
2795         (WebCore::HTMLMediaElement::mediaState): Don't require video, only that the file can play.
2796
2797         * html/MediaElementSession.cpp:
2798         (WebCore::MediaElementSession::showPlaybackTargetPicker): Check readyState instead of hasVideo.
2799
2800 2015-08-04  Anders Carlsson  <andersca@apple.com>
2801
2802         Get rid of ReasonForCallingAllowPlugins since it's not used anywhere
2803         https://bugs.webkit.org/show_bug.cgi?id=147648
2804
2805         Reviewed by Andreas Kling.
2806
2807         * dom/DOMImplementation.cpp:
2808         (WebCore::DOMImplementation::createDocument):
2809         * html/HTMLElement.cpp:
2810         (WebCore::HTMLElement::rendererIsNeeded):
2811         * html/parser/HTMLParserOptions.cpp:
2812         (WebCore::HTMLParserOptions::HTMLParserOptions):
2813         * loader/FrameLoaderTypes.h:
2814         * loader/SubframeLoader.cpp:
2815         (WebCore::SubframeLoader::requestPlugin):
2816         (WebCore::SubframeLoader::createJavaAppletWidget):
2817         (WebCore::SubframeLoader::allowPlugins):
2818         * loader/SubframeLoader.h:
2819         * plugins/DOMMimeType.cpp:
2820         (WebCore::DOMMimeType::enabledPlugin):
2821
2822 2015-08-04  Alex Christensen  <achristensen@webkit.org>
2823
2824         Fix debug CMake build on Windows after r187818.
2825
2826         * PlatformWin.cmake:
2827         Debug *AllInOne.cpp object files in WebCore require /bigobj to compile successfully.
2828
2829 2015-08-04  Alexey Proskuryakov  <ap@apple.com>
2830
2831         Implement NPAPI redirect handling
2832         https://bugs.webkit.org/show_bug.cgi?id=138675
2833         rdar://problem/15779101
2834
2835         Patch by Jeffrey Pfau, updated and tweaked by me.
2836
2837         Reviewed by Anders Carlsson.
2838
2839         Test: http/tests/plugins/get-url-redirect-notify.html
2840
2841         * loader/NetscapePlugInStreamLoader.cpp:
2842         (WebCore::NetscapePlugInStreamLoader::init):
2843         (WebCore::NetscapePlugInStreamLoader::willSendRequest):
2844         (WebCore::NetscapePlugInStreamLoader::didReceiveResponse):
2845         * loader/NetscapePlugInStreamLoader.h:
2846         * loader/ResourceLoader.cpp:
2847         (WebCore::ResourceLoader::init):
2848         (WebCore::ResourceLoader::isSubresourceLoader):
2849         (WebCore::ResourceLoader::willSendRequestInternal):
2850         (WebCore::ResourceLoader::willSendRequest):
2851         (WebCore::ResourceLoader::didSendData):
2852         * loader/ResourceLoader.h:
2853         * loader/SubresourceLoader.cpp:
2854         (WebCore::SubresourceLoader::isSubresourceLoader):
2855         (WebCore::SubresourceLoader::willSendRequestInternal):
2856         (WebCore::SubresourceLoader::willSendRequest): Deleted.
2857         * loader/SubresourceLoader.h:
2858         * plugins/npapi.h:
2859         * plugins/npfunctions.h:
2860
2861 2015-08-04  Zalan Bujtas  <zalan@apple.com>
2862
2863         RenderTheme::paint() should take RenderBox instead of RenderObject.
2864         https://bugs.webkit.org/show_bug.cgi?id=147638
2865
2866         Reviewed by Andreas Kling.
2867
2868         No change in functionality.
2869
2870         * rendering/RenderTheme.cpp:
2871         (WebCore::RenderTheme::paint):
2872         (WebCore::RenderTheme::updateControlStatesForRenderer): ->RenderBox too.
2873         (WebCore::RenderTheme::isActive): Remove redundant code.
2874         * rendering/RenderTheme.h:
2875
2876 2015-08-04  Matthew Daiter  <mdaiter@apple.com>
2877
2878         Render to GraphicsContext MediaPlayerPrivateMediaStreamAVFObjC
2879         https://bugs.webkit.org/show_bug.cgi?id=147643
2880
2881         Reviewed by Eric Carlson.
2882
2883         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:
2884         (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::paint):
2885
2886 2015-08-04  Matthew Daiter  <mdaiter@apple.com>
2887
2888         Added ability to create images from buffers for MediaStream paint methods
2889         https://bugs.webkit.org/show_bug.cgi?id=147642
2890
2891         Reviewed by Eric Carlson.
2892
2893         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.h:
2894         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:
2895         (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::createImageFromSampleBuffer):
2896
2897 2015-08-04  Matthew Daiter  <mdaiter@apple.com>
2898
2899         Add image variable rendered by paint methods for MediaStream
2900         https://bugs.webkit.org/show_bug.cgi?id=147645
2901
2902         Reviewed by Eric Carlson.
2903
2904         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.h:
2905
2906 2015-08-04  Zalan Bujtas  <zalan@apple.com>
2907
2908         RenderTheme::baselinePosition() should take RenderBox instead of RenderObject.
2909         https://bugs.webkit.org/show_bug.cgi?id=147632
2910
2911         Reviewed by Andreas Kling.
2912
2913         It eliminates some redundant type checking and casting.
2914
2915         No change in functionality.
2916
2917         * platform/efl/RenderThemeEfl.cpp:
2918         (WebCore::RenderThemeEfl::baselinePosition):
2919         * platform/efl/RenderThemeEfl.h:
2920         * rendering/RenderTheme.cpp:
2921         (WebCore::RenderTheme::baselinePosition):
2922         * rendering/RenderTheme.h:
2923         * rendering/RenderThemeGtk.cpp:
2924         (WebCore::RenderThemeGtk::baselinePosition):
2925         * rendering/RenderThemeGtk.h:
2926         * rendering/RenderThemeIOS.h:
2927         * rendering/RenderThemeIOS.mm:
2928         (WebCore::RenderThemeIOS::baselinePosition):
2929         * rendering/RenderThemeSafari.cpp:
2930         (WebCore::RenderThemeSafari::baselinePosition):
2931         * rendering/RenderThemeSafari.h:
2932
2933 2015-08-04  Alex Christensen  <achristensen@webkit.org>
2934
2935         Enable WebGL on Windows CMake build.
2936         https://bugs.webkit.org/show_bug.cgi?id=143311
2937
2938         Reviewed by Csaba Osztrogonác.
2939
2940         * CMakeLists.txt:
2941         ANGLE is built quite differently on Windows, so I'm not going to touch the existing CMake build system for
2942         ANGLE on Linux, although I think it should eventually be unified more by using ANGLE's OpenGL renderer.
2943         * PlatformWin.cmake:
2944         Added some needed source files and include directories.
2945
2946 2015-08-04  Jeremy Jones  <jeremyj@apple.com>
2947
2948         Implement isPictureInPictureInterrupted.
2949         https://bugs.webkit.org/show_bug.cgi?id=147620
2950
2951         Reviewed by Eric Carlson.
2952
2953         Implement isPictureInPictureInterrupted so setting the property to true pauses playback.
2954         This allows PiP to pause when the device is locked while the app is suspended.
2955
2956         * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
2957         (-[WebAVPlayerController init]):
2958         (-[WebAVPlayerController isPictureInPictureInterrupted]):
2959         (-[WebAVPlayerController setPictureInPictureInterrupted:]):
2960
2961 2015-08-03  Csaba Osztrogonác  <ossy@webkit.org>
2962
2963         Introduce COMPILER(GCC_OR_CLANG) guard and make COMPILER(GCC) true only for GCC
2964         https://bugs.webkit.org/show_bug.cgi?id=146833
2965
2966         Reviewed by Alexey Proskuryakov.
2967
2968         * platform/graphics/cpu/arm/filters/FELightingNEON.cpp:
2969         * platform/graphics/cpu/arm/filters/FELightingNEON.h:
2970         * platform/graphics/filters/FELighting.cpp:
2971         (WebCore::FELighting::platformApply):
2972         * platform/network/efl/NetworkStateNotifierEfl.cpp:
2973         (WebCore::NetworkStateNotifier::readSocketCallback):
2974
2975 2015-08-03  Csaba Osztrogonác  <ossy@webkit.org>
2976
2977         [CMake] Add an option to build AllInOne files
2978         https://bugs.webkit.org/show_bug.cgi?id=102647
2979
2980         Reviewed by Alex Christensen.
2981
2982         * CMakeLists.txt:
2983
2984 2015-08-03  Csaba Osztrogonác  <ossy@webkit.org>
2985
2986         Fix the all-in-one build on Linux after r187659
2987         https://bugs.webkit.org/show_bug.cgi?id=147557
2988
2989         Reviewed by Alex Christensen.
2990
2991         Removed MediaFeatureNames.cpp from the all-in-one build, because it caused build failures on Linux.
2992         Additionally removed css/MediaAllInOne.cpp since it is unused.
2993
2994         * WebCore.vcxproj/WebCore.vcxproj:
2995         * WebCore.vcxproj/WebCore.vcxproj.filters:
2996         * css/CSSAllInOne.cpp:
2997         * css/MediaAllInOne.cpp: Removed.
2998
2999 2015-08-03  Benjamin Poulain  <bpoulain@apple.com>
3000
3001         Returns inconsistent types for el.style.property and el.style.getPropertyValue('color')
3002         https://bugs.webkit.org/show_bug.cgi?id=147549
3003
3004         Reviewed by Andreas Kling.
3005
3006         Kudos to Greg Whitworth for finding this bug.
3007
3008         Test: fast/css/getPropertyValue-returns-empty-on-missing-property.html
3009
3010         * css/CSSStyleDeclaration.idl:
3011         Our definition was wrong.
3012         Current spec: http://www.w3.org/TR/cssom/#dom-cssstyledeclaration-getpropertyvalue
3013         Current draft: https://drafts.csswg.org/cssom/#dom-cssstyledeclaration-getpropertyvalue
3014         Gecko and EdgeHTML follow the spec.
3015
3016 2015-08-03  Myles C. Maxfield  <mmaxfield@apple.com>
3017
3018         Fix crashing Mavericks test
3019
3020         Unreviewed.
3021
3022         * platform/graphics/cocoa/FontPlatformDataCocoa.mm:
3023         (WebCore::FontPlatformData::registeredFont):
3024
3025 2015-08-03  Myles C. Maxfield  <mmaxfield@apple.com>
3026
3027         Unreviewed post-review feedback on r187797
3028
3029         The correct terminology is "registered" instead of "activated."
3030
3031         No new tests because there is no behavior change.
3032
3033         * platform/graphics/FontPlatformData.h:
3034         * platform/graphics/cocoa/FontPlatformDataCocoa.mm:
3035         (WebCore::FontPlatformData::registeredFont):
3036         (WebCore::FontPlatformData::activatedFont): Deleted.
3037
3038 2015-08-03  Myles C. Maxfield  <mmaxfield@apple.com>
3039
3040         Clean up casts between NSFont*s and CTFontRefs
3041         https://bugs.webkit.org/show_bug.cgi?id=147618
3042
3043         Reviewed by Mitz Pettel.
3044
3045         For toll free bridged types, it makes more sense to do a C-style cast, than jump
3046         through hoops for older compilers.
3047
3048         No new tests because there is no behavior change.
3049
3050         * platform/graphics/FontPlatformData.h:
3051         (WebCore::FontPlatformData::nsFont):
3052         (WebCore::FontPlatformData::hash):
3053
3054 2015-08-03  Commit Queue  <commit-queue@webkit.org>
3055
3056         Unreviewed, rolling out r187707, r187709, r187724, and
3057         r187728.
3058         https://bugs.webkit.org/show_bug.cgi?id=147617
3059
3060         fast/text/international/arabic-justify.html is flakey
3061         (Requested by litherum on #webkit).
3062
3063         Reverted changesets:
3064
3065         "[OS X] Migrate to CTFontCreateForCharactersWithLanguage from
3066         [NSFont findFontLike:forString:withRange:inLanguage]"
3067         https://bugs.webkit.org/show_bug.cgi?id=147483
3068         http://trac.webkit.org/changeset/187707
3069
3070         "Fix the build"
3071         http://trac.webkit.org/changeset/187709
3072
3073         "Expand CharacterFallbackMapKey to a struct"
3074         https://bugs.webkit.org/show_bug.cgi?id=147530
3075         http://trac.webkit.org/changeset/187724
3076
3077         "CharacterFallbackMapKey should be locale-specific"
3078         https://bugs.webkit.org/show_bug.cgi?id=147532
3079         http://trac.webkit.org/changeset/187728
3080
3081 2015-08-03  Myles C. Maxfield  <mmaxfield@apple.com>
3082
3083         REGRESSION(r184899): Crash when focusing an input element styled with a web font
3084         https://bugs.webkit.org/show_bug.cgi?id=147616
3085         <rdar://problem/21838271>
3086
3087         Reviewed by Dean Jackson.
3088
3089         NSFontManager can't handle web fonts. We used to pass null to NSFontManager in this case,
3090         but r184899 changed that.
3091
3092         Test: fast/text/input-webfont-focus.html
3093
3094         * platform/graphics/FontPlatformData.h:
3095         * platform/graphics/cocoa/FontPlatformDataCocoa.mm:
3096         (WebCore::FontPlatformData::activatedFont):
3097
3098 2015-08-03  Brent Fulgham  <bfulgham@apple.com>
3099
3100         [Win] Unreviewed build fix.
3101
3102         It turns out that the IFEQ command (at least on Cygwin) does not
3103         understand Wildcards for OS types. Consequently, we should not use
3104         Windows* in makefiles. Luckily, we only need Windows_NT anymore.
3105
3106         * DerivedSources.make: Change Windows* -> Windows_NT to correct build.
3107
3108 2015-08-03  Tim Horton  <timothy_horton@apple.com>
3109
3110         REGRESSION (r186916): TextIndicators for multiline link previews are unreadable/offset/blank
3111         https://bugs.webkit.org/show_bug.cgi?id=147615
3112         <rdar://problem/22116575>
3113
3114         Reviewed by Dean Jackson.
3115
3116         * page/mac/TextIndicatorWindow.mm:
3117         (-[WebTextIndicatorView initWithFrame:textIndicator:margin:offset:]):
3118         No need to offset by the difference between the text bounding rect and the selection bounding rect,
3119         because the snapshot is now (after r186916) taken of exactly the text bounding rect.
3120
3121 2015-08-03  Matt Rajca  <mrajca@apple.com>
3122
3123         Media Session: let UI clients query whether a media element is paused
3124         https://bugs.webkit.org/show_bug.cgi?id=147588
3125
3126         Reviewed by Tim Horton.
3127
3128         * page/Page.cpp:
3129         (WebCore::Page::isMediaElementPaused): Determine if the media element with the given ID is paused.
3130         * page/Page.h:
3131
3132 2015-08-03  Eric Carlson  <eric.carlson@apple.com>
3133
3134         [Mac] Always require user gesture to begin playing to AppleTV automatically
3135         https://bugs.webkit.org/show_bug.cgi?id=147591
3136
3137         Reviewed by Jer Noble.
3138
3139         * html/HTMLMediaElement.cpp:
3140         (WebCore::HTMLMediaElement::mediaState): Don't set the ExternalDeviceAutoPlayCandidate 
3141           flag until the user has explicitly triggered playback.
3142
3143 2015-08-03  Dean Jackson  <dino@apple.com>
3144
3145         Inline video controls overlap each other while playing video in slideover mode
3146         https://bugs.webkit.org/show_bug.cgi?id=147535
3147         <rdar://problem/22026864>
3148
3149         Reviewed by Eric Carlson.
3150
3151         Now that the resizing code is in the shared controller, we need to
3152         make sure to hide the timeline scrubber in iOS when the controls
3153         get too small. This involved adding the dropped class to the timeline,
3154         and rules for hiding to the CSS.
3155
3156         Meanwhile, when the page scale factor is less than one, we use the CSS zoom property
3157         and don't need to factor in the page scale factor when calculating
3158         the size.
3159
3160         * Modules/mediacontrols/mediaControlsApple.js:
3161         (Controller.prototype.updateLayoutForDisplayedWidth): Don't use pageScaleFactor.
3162         * Modules/mediacontrols/mediaControlsiOS.css:
3163         (audio::-webkit-media-controls-panel .dropped): Add display none for this rule.
3164
3165 2015-08-03  Anders Carlsson  <andersca@apple.com>
3166
3167         Safari is failing to remove SQLite Databases via Remove All Website Data
3168         https://bugs.webkit.org/show_bug.cgi?id=147584
3169         rdar://problem/22095006
3170
3171         Reviewed by Brady Eidson.
3172
3173         If we end up deleting every single database for an origin, make sure to also delete the origin.
3174
3175         * Modules/webdatabase/DatabaseTracker.cpp:
3176         (WebCore::DatabaseTracker::deleteDatabasesModifiedSince):
3177
3178 2015-08-03  Zalan Bujtas  <zalan@apple.com>
3179
3180         Move "starting from root" frame flattening logging to the correct place.
3181         https://bugs.webkit.org/show_bug.cgi?id=147571
3182
3183         Reviewed by Simon Fraser.
3184
3185         * page/FrameView.cpp:
3186         (WebCore::FrameView::startLayoutAtMainFrameViewIfNeeded):
3187         (WebCore::FrameView::layout): Deleted.
3188
3189 2015-08-03  Commit Queue  <commit-queue@webkit.org>
3190
3191         Unreviewed, rolling out r187729.
3192         https://bugs.webkit.org/show_bug.cgi?id=147575
3193
3194         10% performance hit (Requested by litherum on #webkit).
3195
3196         Reverted changeset:
3197
3198         "[OS X] Font fallback is not language-sensitive"
3199         https://bugs.webkit.org/show_bug.cgi?id=147390
3200         http://trac.webkit.org/changeset/187729
3201
3202 2015-08-03  Zalan Bujtas  <zalan@apple.com>
3203
3204         ChildWidgetState::ChildWidgetIs* naming is redundant.
3205         https://bugs.webkit.org/show_bug.cgi?id=147565
3206
3207         Reviewed by Simon Fraser.
3208
3209         Since strongly typed enum requires to write out 'ChildWidgetState::ChildWidgetIsDestroyed',
3210         the enumerator list names can be shortened.
3211
3212         No change in behaviour.
3213
3214         * rendering/RenderFrameBase.cpp:
3215         (WebCore::RenderFrameBase::peformLayoutWithFlattening):
3216         * rendering/RenderWidget.cpp:
3217         (WebCore::RenderWidget::updateWidgetPosition):
3218         * rendering/RenderWidget.h:
3219
3220 2015-08-03  Zalan Bujtas  <zalan@apple.com>
3221
3222         Pass ControlStates& to RenderTheme methods instead of ControlStates*
3223         https://bugs.webkit.org/show_bug.cgi?id=147521
3224
3225         Reviewed by Andreas Kling.
3226
3227         No change in functionality.
3228
3229         * platform/Theme.h:
3230         (WebCore::Theme::selectionColor):
3231         (WebCore::Theme::paint):
3232         (WebCore::Theme::inflateControlPaintRect):
3233         * platform/mac/ThemeMac.h:
3234         * platform/mac/ThemeMac.mm:
3235         (WebCore::updateStates):
3236         (WebCore::convertControlStatesToThemeDrawState):
3237         (WebCore::configureToggleButton):
3238         (WebCore::sharedRadioCell):
3239         (WebCore::sharedCheckboxCell):
3240         (WebCore::paintToggleButton):
3241         (WebCore::setUpButtonCell):
3242         (WebCore::button):
3243         (WebCore::paintButton):
3244         (WebCore::paintStepper):
3245         (WebCore::ThemeMac::ensuredView):
3246         (WebCore::ThemeMac::inflateControlPaintRect):
3247         (WebCore::ThemeMac::paint):
3248         * rendering/RenderBox.cpp:
3249         (WebCore::RenderBox::paintBoxDecorations):
3250         * rendering/RenderTheme.cpp:
3251         (WebCore::RenderTheme::paint):
3252         (WebCore::RenderTheme::adjustRepaintRect):
3253         (WebCore::RenderTheme::updateControlStatesForRenderer):
3254         * rendering/RenderTheme.h:
3255         * rendering/RenderThemeMac.mm:
3256         (WebCore::RenderThemeMac::documentViewFor):
3257
3258 2015-08-03  Brady Eidson  <beidson@apple.com>
3259
3260         Crash when signing into twitter calling WebCore::DocumentLoader::responseReceived(WebCore::CachedResource*, WebCore::ResourceResponse const&).
3261         <rdar://problem/22098457> and https://bugs.webkit.org/show_bug.cgi?id=147560
3262
3263         Reviewed by Alexey Proskuryakov.
3264
3265         * loader/DocumentLoader.cpp:
3266         (WebCore::DocumentLoader::willSendRequest): Only grab identifierForLoadWithoutResourceLoader() if there's no ResourceLoader.
3267
3268 2015-08-03  Zalan Bujtas  <zalan@apple.com>
3269
3270         themePainted in RenderBox::paintBoxDecorations() is confusing.
3271         https://bugs.webkit.org/show_bug.cgi?id=147492
3272
3273         Reviewed by Andreas Kling.
3274
3275         What themePainted is supposed to indicate is whether the theme requires additional border and background painting.
3276         Rename it to borderOrBackgroundPaintingIsNeeded.
3277
3278         No change in behaviour.
3279
3280         * rendering/RenderBox.cpp:
3281         (WebCore::RenderBox::paintBoxDecorations):
3282
3283 2015-08-03  Youenn Fablet  <youenn.fablet@crf.canon.fr>
3284
3285         [EFL] http/tests/media/media-stream/disconnected-frame-already.html is crashing after r185903
3286         https://bugs.webkit.org/show_bug.cgi?id=146834
3287
3288         Reviewed by Eric Carlson.
3289
3290         r185903 went to far in removing some tests, in particular whether the current process is related to a frame.
3291         Readded that check.
3292         Refactored the code to remove the need for NavigatorUserMedia class.
3293
3294         Covered by existing tests.
3295
3296         * CMakeLists.txt: Removed NavigatorUserMedia.cpp.
3297         * Modules/mediastream/NavigatorUserMedia.cpp: Removed.
3298         * Modules/mediastream/NavigatorUserMedia.h: Removed.
3299         * WebCore.xcodeproj/project.pbxproj: Ditto.
3300         * bindings/js/JSNavigatorCustom.cpp:
3301         (WebCore::JSNavigator::webkitGetUserMedia): Inlined NavigatorUserMeia::webkitGetUserMedia.
3302
3303 2015-08-03  Youenn Fablet  <youenn.fablet@crf.canon.fr>
3304
3305         JSXMLHttpRequest::visitAdditionalChildren does not need to explicitly mark m_response
3306         https://bugs.webkit.org/show_bug.cgi?id=147488
3307
3308         Reviewed by Andreas Kling.
3309
3310         Covered by existing tests.
3311
3312         * bindings/js/JSXMLHttpRequestCustom.cpp:
3313         (WebCore::JSXMLHttpRequest::visitAdditionalChildren): Removed m_response marking.
3314
3315 2015-08-01  Chris Fleizach  <cfleizach@apple.com>
3316
3317         AX: On some complex sites, iOS instantly crashes once VoiceOver is turned on
3318         https://bugs.webkit.org/show_bug.cgi?id=147529
3319
3320         Reviewed by Dan Bernstein.
3321
3322         Sometimes after focusing on a node, it seems like the entire document is destroyed.
3323         Accessibility the axObjectCache returns nullptr and we crash.
3324
3325         Despite my best efforts, I couldn't make a layout test that reproduced this. It's possible
3326         the entire document needs to be destroyed and replaced with something.
3327
3328         * accessibility/AccessibilityRenderObject.cpp:
3329         (WebCore::AccessibilityRenderObject::setFocused):
3330
3331 2015-08-01  Myles C. Maxfield  <mmaxfield@apple.com>
3332
3333         [OS X] Font fallback is not language-sensitive
3334         https://bugs.webkit.org/show_bug.cgi?id=147390
3335
3336         Reviewed by Dean Jackson.
3337
3338         We need to make our font fallback code sensitive to locale.
3339
3340         Test: fast/text/fallback-language-han.html
3341
3342         * platform/graphics/mac/FontCacheMac.mm:
3343         (WebCore::lookupCTFont):
3344         (WebCore::FontCache::systemFallbackForCharacters):
3345
3346 2015-08-01  Myles C. Maxfield  <mmaxfield@apple.com>
3347
3348         CharacterFallbackMapKey should be locale-specific
3349         https://bugs.webkit.org/show_bug.cgi?id=147532
3350
3351         Reviewed by Dean Jackson.
3352
3353         This is in preparation for locale-specific font fallback.
3354
3355         No new tests because there is no behavior change.
3356
3357         * platform/graphics/Font.cpp:
3358         (WebCore::CharacterFallbackMapKey::CharacterFallbackMapKey):
3359         (WebCore::CharacterFallbackMapKey::operator==):
3360         (WebCore::CharacterFallbackMapKeyHash::hash):
3361         (WebCore::Font::systemFallbackFontForCharacter):
3362
3363 2015-08-01  Myles C. Maxfield  <mmaxfield@apple.com>
3364
3365         Expand CharacterFallbackMapKey to a struct
3366         https://bugs.webkit.org/show_bug.cgi?id=147530
3367
3368         Reviewed by Dean Jackson.
3369
3370         This is in prepraration for making this struct locale-specific.
3371
3372         No new tests because there is no behavior change.
3373
3374         * platform/graphics/Font.cpp:
3375         (WebCore::CharacterFallbackMapKey::CharacterFallbackMapKey):
3376         (WebCore::CharacterFallbackMapKey::isHashTableDeletedValue):
3377         (WebCore::CharacterFallbackMapKey::operator==):
3378         (WebCore::CharacterFallbackMapKeyHash::hash):
3379         (WebCore::CharacterFallbackMapKeyHash::equal):
3380         (WebCore::Font::systemFallbackFontForCharacter):
3381
3382 2015-08-01  Myles C. Maxfield  <mmaxfield@apple.com>
3383
3384         Fix the build after r187721
3385
3386         Unreviewed.
3387
3388         * bindings/js/JSDOMBinding.h:
3389         (WebCore::createWrapper):
3390
3391 2015-08-01  Alex Christensen  <achristensen@webkit.org>
3392
3393         Fix compile errors with VS2015
3394         https://bugs.webkit.org/show_bug.cgi?id=147526
3395
3396         Reviewed by Myles Maxfield.
3397
3398         * bindings/js/JSDOMBinding.h:
3399         (WebCore::createWrapper):
3400         Explicitly call the Ref constructor to avoid unresolved symbols with VS2015.
3401         Otherwise, VS2015 tries to use CSSPrimitiveValue::operator<Ref<CSSPrimitiveValue> > which doesn't exist.
3402
3403 2015-07-27  Matt Rajca  <mrajca@apple.com>
3404
3405         Media Session: inform the UI process when the focused Content media element changes
3406         https://bugs.webkit.org/show_bug.cgi?id=147323
3407
3408         Reviewed by Tim Horton.
3409
3410         * html/HTMLMediaElement.cpp:
3411         (WebCore::HTMLMediaElement::playInternal): Eventually tell the UI process that the focused Content media element changed.
3412         * page/ChromeClient.h:
3413
3414 2015-07-27  Matt Rajca  <mrajca@apple.com>
3415
3416         Media Session: give media elements unique IDs
3417         https://bugs.webkit.org/show_bug.cgi?id=147322
3418
3419         Reviewed by Eric Carlson.
3420
3421         * html/HTMLMediaElement.cpp:
3422         (WebCore::elementIDsToElements): Create a global map of element IDs to elements.
3423         (WebCore::HTMLMediaElement::elementWithID): Retrieve the element with the given ID.
3424         (WebCore::HTMLMediaElement::HTMLMediaElement): Give the element a unique ID.
3425         (WebCore::HTMLMediaElement::playInternal): Removed whitespace.
3426         (WebCore::HTMLMediaElement::pauseInternal): Ditto.
3427         * html/HTMLMediaElement.h:
3428         (WebCore::HTMLMediaElement::elementID):
3429
3430 2015-07-31  Myles C. Maxfield  <mmaxfield@apple.com>
3431
3432         Fix the build
3433
3434         Unreviewed.
3435
3436         * platform/graphics/mac/FontCacheMac.mm:
3437         (WebCore::lookupCTFont):
3438
3439 2015-07-31  Myles C. Maxfield  <mmaxfield@apple.com>
3440
3441         [OS X] Migrate to CTFontCreateForCharactersWithLanguage from [NSFont findFontLike:forString:withRange:inLanguage]
3442         https://bugs.webkit.org/show_bug.cgi?id=147483
3443
3444         Reviewed by Dean Jackson.
3445
3446         [NSFont findFontLike:forString:withRange:inLanguage] doesn't properly handle its last argument. In
3447         addition, we want to be moving away from NSFont in the first place and on to Core Text. This new
3448         CoreText function correctly handles its language argument, which is required for language-specific
3449         font fallback.
3450
3451         No new tests because there is no behavior change.
3452
3453         * platform/graphics/FontCache.cpp:
3454         (WebCore::FontCache::purgeInactiveFontData):
3455         * platform/graphics/FontCache.h:
3456         (WebCore::FontCache::platformPurgeInactiveFontData):
3457         * platform/graphics/mac/FontCacheMac.mm:
3458         (WebCore::fallbackDedupSet):
3459         (WebCore::FontCache::platformPurgeInactiveFontData):
3460         (WebCore::lookupCTFont):
3461         (WebCore::FontCache::systemFallbackForCharacters):
3462         * platform/spi/cocoa/CoreTextSPI.h:
3463         * platform/spi/mac/NSFontSPI.h:
3464
3465 2015-07-31  Chris Dumez  <cdumez@apple.com>
3466
3467         Drop dummy Timer callbacks
3468         https://bugs.webkit.org/show_bug.cgi?id=147516
3469
3470         Reviewed by Alexey Proskuryakov.
3471
3472         Drop dummy Timer callbacks in the code base. A lot of Timer callbacks
3473         do nothing else beside calling a particular method. In such case, we
3474         can use the called method as Timer callback instead.
3475
3476         * css/FontLoader.cpp:
3477         (WebCore::FontLoader::FontLoader):
3478         * css/FontLoader.h:
3479         * dom/Document.cpp:
3480         (WebCore::Document::Document):
3481         (WebCore::Document::styleRecalcTimerFired): Deleted.
3482         (WebCore::Document::domCookieCacheExpiryTimerFired): Deleted.
3483         * dom/Document.h:
3484         * html/MediaController.cpp:
3485         (MediaController::MediaController):
3486         (MediaController::timeupdateTimerFired): Deleted.
3487         * html/MediaController.h:
3488         * loader/cache/CachedResource.cpp:
3489         (WebCore::CachedResource::CachedResource):
3490         * loader/cache/CachedResourceLoader.cpp:
3491         (WebCore::CachedResourceLoader::CachedResourceLoader):
3492         (WebCore::CachedResourceLoader::garbageCollectDocumentResourcesTimerFired): Deleted.