Remove unused definitions of WEBKIT_VERSION_MIN_REQUIRED
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2015-05-23  Dan Bernstein  <mitz@apple.com>
2
3         Remove unused definitions of WEBKIT_VERSION_MIN_REQUIRED
4         https://bugs.webkit.org/show_bug.cgi?id=145345
5
6         Reviewed by Sam Weinig.
7
8         * Configurations/WebCore.xcconfig: Also changed to use $(inherited).
9
10 2015-05-24  Hunseop Jeong  <hs85.jeong@samsung.com>
11
12         Use modern for-loops in WebCore/svg.
13         https://bugs.webkit.org/show_bug.cgi?id=145209
14
15         Reviewed by Darin Adler.
16
17         No new tests, no behavior changes.
18
19         * svg/SVGAnimateElementBase.cpp:
20         (WebCore::propertyTypesAreConsistent):
21         * svg/SVGAnimatedPath.cpp:
22         (WebCore::SVGAnimatedPathAnimator::startAnimValAnimation):
23         * svg/SVGAnimatedTypeAnimator.h:
24         (WebCore::SVGAnimatedTypeAnimator::executeAction):
25         * svg/SVGAnimationElement.cpp:
26         (WebCore::SVGAnimationElement::parseAttribute):
27         * svg/SVGCursorElement.cpp:
28         (WebCore::SVGCursorElement::~SVGCursorElement):
29         * svg/SVGDocumentExtensions.cpp:
30         (WebCore::SVGDocumentExtensions::pauseAnimations):
31         (WebCore::SVGDocumentExtensions::unpauseAnimations):
32         (WebCore::SVGDocumentExtensions::dispatchSVGLoadEventToOutermostSVGElements):
33         (WebCore::SVGDocumentExtensions::isElementWithPendingResources):
34         (WebCore::SVGDocumentExtensions::removeElementFromPendingResources):
35         (WebCore::SVGDocumentExtensions::removeAllTargetReferencesForElement):
36         * svg/SVGElement.cpp:
37         (WebCore::populateAttributeNameToCSSPropertyIDMap):
38         (WebCore::populateAttributeNameToAnimatedPropertyTypeMap):
39         (WebCore::populateCSSPropertyWithSVGDOMNameToAnimatedPropertyTypeMap):
40         (WebCore::hasLoadListener):
41         * svg/SVGFontData.cpp:
42         (WebCore::SVGFontData::applySVGGlyphSelection):
43         * svg/SVGFontElement.cpp:
44         (WebCore::SVGFontElement::registerLigaturesInGlyphCache):
45         (WebCore::SVGKerningMap::insert):
46         (WebCore::stringMatchesUnicodeRange):
47         * svg/SVGPathByteStream.h:
48         (WebCore::SVGPathByteStream::append):
49         * svg/animation/SMILTimeContainer.cpp:
50         (WebCore::SMILTimeContainer::setElapsed):
51         (WebCore::SMILTimeContainer::updateAnimations):
52         * svg/animation/SVGSMILElement.cpp:
53         (WebCore::SVGSMILElement::parseBeginOrEnd):
54         (WebCore::SVGSMILElement::connectConditions):
55         (WebCore::SVGSMILElement::disconnectConditions):
56         (WebCore::SVGSMILElement::notifyDependentsIntervalChanged):
57         (WebCore::SVGSMILElement::createInstanceTimesFromSyncbase):
58         * svg/graphics/filters/SVGFilterBuilder.cpp:
59         (WebCore::SVGFilterBuilder::clearResultsRecursive):
60         * svg/graphics/filters/SVGFilterBuilder.h:
61         (WebCore::SVGFilterBuilder::addBuiltinEffects):
62         * svg/properties/SVGAnimatedProperty.cpp:
63         (WebCore::SVGAnimatedProperty::~SVGAnimatedProperty):
64         * svg/properties/SVGListProperty.h:
65         (WebCore::SVGListProperty::detachListWrappersAndResize):
66         * svg/properties/SVGPathSegListPropertyTearOff.cpp:
67         (WebCore::SVGPathSegListPropertyTearOff::clearContextAndRoles):
68
69 2015-05-24  Jeremy Jones  <jeremyj@apple.com>
70
71         Register media MIME types as supported by HTML view in WebKit1.
72         https://bugs.webkit.org/show_bug.cgi?id=145356
73
74         Reviewed by Eric Carlson.
75
76         getSupportedMediaMIMETypes is now used in WebKit1.
77
78         * platform/MIMETypeRegistry.h: Export getSupportedMediaMIMETypes.
79
80 2015-05-23  Antti Koivisto  <antti@apple.com>
81
82         Permanent redirects should have long implicit cache lifetime
83         https://bugs.webkit.org/show_bug.cgi?id=145348
84         rdar://problem/20680519
85
86         Reviewed by Sam Weinig.
87
88         301 Moved Permanently response that doesn't specify explicit lifetime should have long implicit lifetime.
89         This matches other browsers.
90
91         * platform/network/CacheValidation.cpp:
92         (WebCore::computeFreshnessLifetimeForHTTPFamily):
93
94             Give 301 Moved Permanently (and similarly semantically permanent 410 Gone) long implicit lifetime.
95
96         (WebCore::updateRedirectChainStatus):
97
98 2015-05-23  Myles C. Maxfield  <mmaxfield@apple.com>
99
100         Cleanup after r184796
101         https://bugs.webkit.org/show_bug.cgi?id=145333
102
103         Reviewed by Alexey Proskuryakov.
104
105         No new tests because there is no behavior change.
106
107         * platform/graphics/cocoa/FontCascadeCocoa.mm:
108         (WebCore::RenderingStyleSaver::RenderingStyleSaver): Deleted.
109         (WebCore::RenderingStyleSaver::~RenderingStyleSaver): Deleted.
110
111 2015-05-23  Yusuke Suzuki  <utatane.tea@gmail.com>
112
113         Introduce UniquedStringImpl and SymbolImpl to separate symbolic strings from AtomicStringImpl
114         https://bugs.webkit.org/show_bug.cgi?id=144848
115
116         Reviewed by Darin Adler.
117
118         Use UniquedStringImpl, SymbolImpl and AtomicStringImpl.
119
120         * bindings/js/JSDOMWindowCustom.cpp:
121         (WebCore::JSDOMWindow::getOwnPropertySlotByIndex):
122         * bindings/js/SerializedScriptValue.cpp:
123         (WebCore::CloneSerializer::write):
124
125 2015-05-23  Zalan Bujtas  <zalan@apple.com>
126
127         Simple line layout: Ignore -webkit-flow-*content while collecting text content for innerText.
128         https://bugs.webkit.org/show_bug.cgi?id=145344
129         rdar://problem/20959522
130
131         Reviewed by Antti Koivisto.
132
133         This patch ensures that when a -webkit-flow-into content is present in a simple line layout container,
134         we skip it while collecting the text content for innerText.
135         It's not always guaranteed that a simple line layout container only contains simple text nodes. In such cases,
136         we need to ensure that text offset computing only takes the simple text nodes into account.
137
138         Test: fast/text/simple-line-layout-inner-text-with-flow-content.html
139
140         * editing/TextIterator.cpp:
141         (WebCore::TextIterator::handleTextNode):
142         * editing/TextIterator.h:
143
144 2015-05-22  Mark Lam  <mark.lam@apple.com>
145
146         Document::ensurePlugInsInjectedScript() should evaluate the injected script on its own frame.
147         https://bugs.webkit.org/show_bug.cgi?id=145328
148
149         Reviewed by Jon Lee.
150
151         trac.webkit.org/r184329 fixed HTMLPlugInImageElement::didAddUserAgentShadowRoot()
152         to use the document's frame instead of the page's main frame.  However,
153         Document::ensurePlugInsInjectedScript() is still evaluating the injected script on
154         the main frame.
155
156         As a result, HTMLPlugInImageElement::didAddUserAgentShadowRoot()'s attempt to get
157         the injected createOverlay function from the document frame's global object will
158         fail.  Fixing Document::ensurePlugInsInjectedScript() to evaluating the injected
159         script on the document's frame fixes the issue.
160
161         No new tests.
162
163         * dom/Document.cpp:
164         (WebCore::Document::ensurePlugInsInjectedScript):
165
166 2015-05-22  Eric Carlson  <eric.carlson@apple.com>
167
168         MediaPlayer doesn't need isPlayingToWirelessPlaybackTarget and isCurrentPlaybackTargetWireless
169         https://bugs.webkit.org/show_bug.cgi?id=145325
170
171         Reviewed by Brent Fulgham.
172
173         * html/HTMLMediaElement.cpp:
174         (WebCore::HTMLMediaElement::webkitCurrentPlaybackTargetIsWireless): Call isCurrentPlaybackTargetWireless
175         directly.
176         (WebCore::HTMLMediaElement::wirelessRoutesAvailableDidChange): Ditto.
177         (WebCore::HTMLMediaElement::isPlayingToWirelessPlaybackTarget): Ditto.
178         (WebCore::HTMLMediaElement::mediaState): Ditto.
179
180         * html/HTMLMediaSession.cpp:
181         (WebCore::HTMLMediaSession::currentPlaybackTargetIsWireless): Deleted.
182         * html/HTMLMediaSession.h:
183
184         * platform/graphics/MediaPlayer.cpp:
185         (WebCore::MediaPlayer::isPlayingToWirelessPlaybackTarget): Deleted.
186         * platform/graphics/MediaPlayer.h:
187
188         * platform/graphics/MediaPlayerPrivate.h:
189         (WebCore::MediaPlayerPrivateInterface::isPlayingToWirelessPlaybackTarget): Deleted.
190
191         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
192         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
193         (WebCore::MediaPlayerPrivateAVFoundationObjC::isPlayingToWirelessPlaybackTarget): Deleted.
194
195         * platform/ios/WebVideoFullscreenModelVideoElement.mm:
196         (WebVideoFullscreenModelVideoElement::updateForEventName): Call webkitCurrentPlaybackTargetIsWireless.
197
198 2015-05-22  Jon Lee  <jonlee@apple.com>
199
200         Rename MediaPlaybackAllowsInline
201         https://bugs.webkit.org/show_bug.cgi?id=145315
202
203         Reviewed by Eric Carlson.
204
205         Our API uses allowsInlineMediaPlayback. Our symbols should reflect the same.
206
207         * page/Settings.cpp: Update the static variable name as well as the setting.
208         * page/Settings.in: Ditto.
209
210         * Modules/mediacontrols/MediaControlsHost.idl: Rename to allowsInlineMediaPlayback.
211         Affects the media controls code.
212         * Modules/mediacontrols/MediaControlsHost.h:
213         * Modules/mediacontrols/MediaControlsHost.cpp:
214         (WebCore::MediaControlsHost::allowsInlineMediaPlayback):
215         (WebCore::MediaControlsHost::mediaPlaybackAllowsInline): Deleted.
216
217         Update to use the new name in the media controls.
218         * Modules/mediacontrols/mediaControlsApple.js:
219         (Controller.prototype.shouldHaveControls):
220         * Modules/mediacontrols/mediaControlsiOS.js:
221         (ControllerIOS.prototype.shouldHaveStartPlaybackButton):
222
223         * css/MediaQueryEvaluator.cpp:
224         (WebCore::video_playable_inlineMediaFeatureEval):
225         * html/HTMLMediaSession.cpp:
226         (WebCore::HTMLMediaSession::requiresFullscreenForVideoPlayback):
227
228 2015-05-22  Jon Lee  <jonlee@apple.com>
229
230         Rename MediaPlaybackAllowsAirPlay
231         https://bugs.webkit.org/show_bug.cgi?id=145316
232
233         Reviewed by Eric Carlson.
234
235         In preparation for an API rename, update internal symbols from mediaPlaybackAllowsAirPlay
236         to allowsAirPlayForMediaPlayback.
237
238         * page/Settings.in: Update the setting name.
239
240         * html/HTMLMediaSession.cpp:
241         (WebCore::HTMLMediaSession::wirelessVideoPlaybackDisabled): Update the call to settings.
242         * testing/InternalSettings.h: Update the name of the member variable.
243         * testing/InternalSettings.cpp: Update the names and calls to settings.
244         (WebCore::InternalSettings::Backup::Backup):
245         (WebCore::InternalSettings::InternalSettings):
246         (WebCore::InternalSettings::resetToConsistentState):
247         (WebCore::InternalSettings::setWirelessPlaybackDisabled):
248
249 2015-05-22  Jon Lee  <jonlee@apple.com>
250
251         Rename MediaPlaybackRequiresUserGesture
252         https://bugs.webkit.org/show_bug.cgi?id=145314
253
254         Reviewed by Anders Carlsson.
255
256         In preparation for an API rename, update internal symbols from mediaPlaybackRequiresUserGesture
257         to requiresUserGestureForMediaPlayback.
258
259         * page/Settings.cpp: update static const default variable name.
260         * page/Settings.in: update the setting name and static const default variable name.
261
262         * Modules/webaudio/AudioContext.cpp:
263         (WebCore::AudioContext::constructCommon): Update settings call.
264         * html/HTMLMediaElement.cpp:
265         (WebCore::HTMLMediaElement::HTMLMediaElement): Ditto.
266
267 2015-05-22  Joanmarie Diggs  <jdiggs@igalia.com>
268
269         AX: Figure out why list-detection2.html test fails on GTK
270         https://bugs.webkit.org/show_bug.cgi?id=145273
271
272         Reviewed by Chris Fleizach.
273
274         Only consider the text under the pseudo element for GTK and EFL.
275         The other platforms expose rendered text content through their
276         own accessible objects. This will fix the crash on Windows until
277         it can be looked into properly.
278
279         No new tests. This should stop list-detection2.html to stop crashing on Windows.
280
281         * accessibility/AccessibilityList.cpp:
282         (WebCore::AccessibilityList::childHasPseudoVisibleListItemMarkers):
283
284 2015-05-22  Jer Noble  <jer.noble@apple.com>
285
286         [Mac] Audio tracks tagged as 'describes-video' are not automatically selected when that system accessibility option is set.
287         https://bugs.webkit.org/show_bug.cgi?id=145228
288
289         Reviewed by Eric Carlson.
290
291         Tests: http/tests/media/hls/hls-accessiblity-describes-video.html
292                media/accessiblity-describes-video.html
293
294         Add support to CaptionUserPreferences to return the user's preferred audio characteristics,
295         including "public.accessibility.describes-video". When the media accessibility options change,
296         trigger the HTMLMediaElement to update the list of tracks, and chose a new audio track if
297         appropriate. Manually filter those tracks matching the requested characteristics in
298         MediaSelectionGroupAVFObjC.  Allow these characteristics to be overrided by Internals for
299         testing purposes.
300
301         * html/HTMLMediaElement.cpp:
302         (WebCore::HTMLMediaElement::captionPreferencesChanged): Call tracksChanged().
303         (WebCore::HTMLMediaElement::mediaPlayerPreferredAudioCharacteristics): Pass through to the page's caption preferences.
304         * html/HTMLMediaElement.h:
305         * page/CaptionUserPreferences.cpp:
306         (WebCore::CaptionUserPreferences::setPreferredAudioCharacteristic): Simple setter.
307         (WebCore::CaptionUserPreferences::preferredAudioCharacteristics): Simple getter.
308         * page/CaptionUserPreferences.h:
309         * page/CaptionUserPreferencesMediaAF.cpp:
310         (WebCore::CaptionUserPreferencesMediaAF::~CaptionUserPreferencesMediaAF): Unregister for audio characteristics change notifications.
311         (WebCore::CaptionUserPreferencesMediaAF::setInterestedInCaptionPreferenceChanges): Register for same.
312         (WebCore::CaptionUserPreferencesMediaAF::setPreferredAudioCharacteristic): If in testing mode, pass to superclass; otherwise no-op.
313         (WebCore::CaptionUserPreferencesMediaAF::preferredAudioCharacteristics): If in testing mode, pass to superclass;
314             otherwise, ask the media accessibility framework.
315         * page/CaptionUserPreferencesMediaAF.h:
316         * platform/graphics/MediaPlayer.cpp:
317         (WebCore::MediaPlayer::tracksChanged): Pass through to m_private.
318         (WebCore::MediaPlayer::preferredAudioCharacteristics): Pass through to HTMLMediaElement.
319         * platform/graphics/MediaPlayer.h:
320         (WebCore::MediaPlayerClient::mediaPlayerPreferredAudioCharacteristics): Added; return empty vector by default.
321         * platform/graphics/MediaPlayerPrivate.h:
322         (WebCore::MediaPlayerPrivateInterface::tracksChanged): Added; no-op by default.
323         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
324         * platform/graphics/avfoundation/MediaSelectionGroupAVFObjC.h:
325         * platform/graphics/avfoundation/MediaSelectionGroupAVFObjC.mm:
326         (WebCore::MediaSelectionGroupAVFObjC::create): Added characteristics parameter.
327         (WebCore::MediaSelectionGroupAVFObjC::MediaSelectionGroupAVFObjC): Ditto.
328         (WebCore::MediaSelectionGroupAVFObjC::updateOptions): Add an additional filter against the
329             passed-in characteristics.
330         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
331         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
332         (WebCore::determineChangedTracksFromNewTracksAndOldItems): Pass the characteristics to the media selection group.
333         (WebCore::MediaPlayerPrivateAVFoundationObjC::updateAudioTracks): Pass in the user's preferred characteristics.
334         (WebCore::MediaPlayerPrivateAVFoundationObjC::updateVideoTracks): Pass in an empty vector.
335         * testing/Internals.cpp:
336         (WebCore::Internals::userPreferredAudioCharacteristics): Added; return the current setting.
337         (WebCore::Internals::setUserPreferredAudioCharacteristic): Added; pass through to CaptionUserPreferences.
338         * testing/Internals.h:
339         * testing/Internals.idl:
340
341         Add soft link macros which account for a possible failure to look up constants.
342
343         * platform/cf/MediaAccessibilitySoftLink.cpp:
344         * platform/cf/MediaAccessibilitySoftLink.h:
345         * platform/mac/SoftLinking.h:
346         * platform/win/SoftLinking.h:
347
348 2015-05-22  Myles C. Maxfield  <mmaxfield@apple.com>
349
350         [Cocoa] Use CTFontDrawGlyphs() instead of CGContextShowGlyphsWithAdvances()/CGContextShowGlyphsAtPositions()
351         https://bugs.webkit.org/show_bug.cgi?id=145234
352
353         Reviewed by Enrica Casucci.
354
355         Eventually, we want to migrate entirely off of text-related CoreGraphics calls
356         and onto CoreText calls (in order to reduce complexity as well as eventually
357         removing the need for FontPlatformData to hold a CGFontRef). There is an
358         equivalent call to CGContextShowGlyphsWithAdvances() and
359         CGContextShowGlyphsAtPositions(), namely, CTFontDrawGlyphs(), which we have
360         found is as performant as its CoreGraphics counterparts. This patch simply
361         migrates these two CG calls to its CT counterpart.
362
363         Performance was measured on a iPhone 4s as well as a Mid 2010 Mac Pro.
364
365         No new tests because there is no behavior change.
366
367         * platform/graphics/cocoa/FontCascadeCocoa.mm:
368         (WebCore::showGlyphsWithAdvances):
369         (WebCore::FontCascade::drawGlyphs):
370
371 2015-05-22  Eric Carlson  <eric.carlson@apple.com>
372
373         [Mac] Don't show default controls after playing to wireless target
374         https://bugs.webkit.org/show_bug.cgi?id=145317
375
376         Reviewed by Dean Jackson.
377
378         * Modules/mediacontrols/mediaControlsApple.js:
379         (Controller.prototype.handlePanelTransitionEnd): Don't show controls unless the video
380         element has the 'controls' attribute.
381         (Controller.prototype.setPlaying): Check this.video.controls directly because we never want
382         to show controls unless the attribute is present.
383         (Controller.prototype.showControls): Ditto.
384         (Controller.prototype.updateWirelessPlaybackStatus): Call reconnectControls.
385         (Controller.prototype.handleWirelessPlaybackChange): Don't call reconnectControls, it will
386         happen in updateWirelessPlaybackStatus.
387         (Controller.prototype.showInlinePlaybackPlaceholderOnly): Deleted.
388
389 2015-05-22  Chris Dumez  <cdumez@apple.com>
390
391         [CG] Regression(r78652): Partially decoded images are not properly removed from MemoryCache when pruning
392         https://bugs.webkit.org/show_bug.cgi?id=145310
393
394         Reviewed by Antti Koivisto.
395
396         r78652 added partially decoded images to the MemoryCache's list of live
397         decoded resources so that they can be pruned on memory pressure. This
398         was needed because CG decodes part of the image to determine its
399         properties (e.g. its size). On memory pressure, we call
400         BitmapImage::destroyDecodedData() which clears the ImageSource and
401         frees up this extra decoded data.
402
403         However, we would fail to remove such partially decoded images from the
404         MemoryCache's list of live resources when pruning. This is because
405         BitmapImage::destroyMetadataAndNotify() fails to take into account the
406         decoded properties size when no frame has been cleared. We would thus
407         fail to detect a decoded size change and not call
408         CachedImage::decodedSizeChanged(). As a result, the CachedImage's
409         decoded size is not reset to 0 and we don't remove it from live decoded
410         resources.
411
412         This patch updates BitmapImage::destroyMetadataAndNotify() to account
413         for m_decodedPropertiesSize even if frameBytesCleared is 0. This way,
414         images for which we have't decoded any frames yet will correctly report
415         that we cleared the decoded data used to determine the image properties
416         and their decoded size will be properly reset to 0. As a result, these
417         will be removed from the MemoryCache's list of live decoded resources.
418
419         * platform/graphics/BitmapImage.cpp:
420         (WebCore::BitmapImage::destroyDecodedData):
421         (WebCore::BitmapImage::destroyMetadataAndNotify):
422         (WebCore::BitmapImage::dataChanged):
423         * platform/graphics/BitmapImage.h:
424
425 2015-05-22  Joseph Pecoraro  <pecoraro@apple.com>
426
427         Web Inspector: Unable to get cursor in new Rule section after creating multiple New Rules
428         https://bugs.webkit.org/show_bug.cgi?id=145294
429
430         Reviewed by Timothy Hatcher.
431
432         * inspector/InspectorStyleSheet.cpp:
433         (WebCore::InspectorStyleSheet::ensureParsedDataReady):
434         Allow stylesheets with mutations for the inspector stylesheet
435         which we control mutations of.
436
437 2015-05-22  Eric Carlson  <eric.carlson@apple.com>
438
439         [Mac] Device picker menu should be persistent
440         https://bugs.webkit.org/show_bug.cgi?id=145311
441
442         Reviewed by Brent Fulgham.
443
444         * Modules/mediasession/WebMediaSessionManager.cpp:
445         (WebCore::WebMediaSessionManager::addPlaybackTargetPickerClient): Add logging.
446         (WebCore::WebMediaSessionManager::removePlaybackTargetPickerClient): Ditto.
447         (WebCore::WebMediaSessionManager::removeAllPlaybackTargetPickerClients): Ditto.
448         (WebCore::WebMediaSessionManager::showPlaybackTargetPicker): Ditto.
449         (WebCore::WebMediaSessionManager::clientStateDidChange): Ditto.
450         (WebCore::WebMediaSessionManager::externalOutputDeviceAvailableDidChange): Ditto.
451         (WebCore::WebMediaSessionManager::configurePlaybackTargetMonitoring): Ditto.
452
453         * html/HTMLMediaElement.cpp:
454         (WebCore::HTMLMediaElement::mediaState): Don't set ExternalDeviceAutoPlayCandidate unless
455         there is an event listener.
456
457         * platform/graphics/avfoundation/objc/MediaPlaybackTargetPickerMac.mm:
458         (WebCore::MediaPlaybackTargetPickerMac::~MediaPlaybackTargetPickerMac): Release the menu
459         controller and remove observers.
460         (WebCore::MediaPlaybackTargetPickerMac::create): Add logging.
461         (WebCore::MediaPlaybackTargetPickerMac::pendingActionTimerFired): Ditto.
462         (WebCore::MediaPlaybackTargetPickerMac::availableDevicesDidChange): Ditto.
463         (WebCore::MediaPlaybackTargetPickerMac::devicePicker): Ditto.
464         (WebCore::MediaPlaybackTargetPickerMac::showPlaybackTargetPicker): Ditto.
465         (WebCore::MediaPlaybackTargetPickerMac::addPendingAction): Start the timer after
466         a brief pause to debounce multiple identical notifications. 
467         (WebCore::MediaPlaybackTargetPickerMac::currentDeviceDidChange): Add logging.
468         (WebCore::MediaPlaybackTargetPickerMac::startingMonitoringPlaybackTargets): Add logging.
469         (WebCore::MediaPlaybackTargetPickerMac::stopMonitoringPlaybackTargets): Don't release
470         the menu controller delegate.
471         (-[WebAVOutputDeviceMenuControllerHelper observeValueForKeyPath:ofObject:change:context:]): Add logging.
472
473         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
474         (WebCore::MediaPlayerPrivateAVFoundationObjC::setWirelessPlaybackTarget): Update logging.
475         (WebCore::MediaPlayerPrivateAVFoundationObjC::setShouldPlayToPlaybackTarget): Ditto.
476
477 2015-05-22  Alexey Proskuryakov  <ap@apple.com>
478
479         Build fix. Added a platform ifdef.
480
481         * platform/network/cf/ResourceRequestCFNet.cpp:
482         (WebCore::ResourceRequest::isUserInitiatedKey):
483
484 2015-05-22  Tim Horton  <timothy_horton@apple.com>
485
486         Remove action menu support
487         https://bugs.webkit.org/show_bug.cgi?id=145305
488         <rdar://problem/21070771>
489
490         Reviewed by Anders Carlsson.
491
492         * WebCore.xcodeproj/project.pbxproj:
493         * platform/spi/mac/NSMenuSPI.h:
494         * platform/spi/mac/NSViewSPI.h: Removed.
495         Remove some SPI.
496
497 2015-05-22  Antti Koivisto  <antti@apple.com>
498
499         MaskImageOperation code does not manage CachedImageClients correctly
500         https://bugs.webkit.org/show_bug.cgi?id=145276
501         rdar://problem/20959822
502
503         * rendering/RenderLayerMaskImageInfo.cpp:
504         (WebCore::RenderLayer::MaskImageInfo::removeMaskImageClients):
505
506             Followup fix: clear m_maskImageOperations vector.
507
508 2015-05-22  Brady Eidson  <beidson@apple.com>
509
510         Rework how the ResourceRequest user initiated property key is used.
511         Followup to https://bugs.webkit.org/show_bug.cgi?id=145281
512
513         Reviewed by Dan Bernstein.
514
515         * platform/mac/WebCoreSystemInterface.h:
516
517         * platform/network/cf/ResourceRequest.h:
518         * platform/network/cf/ResourceRequestCFNet.cpp:
519         (WebCore::ResourceRequest::doUpdatePlatformRequest):
520         (WebCore::ResourceRequest::doUpdateResourceRequest):
521         (WebCore::ResourceRequest::isUserInitiatedKey):
522
523         * platform/network/cocoa/ResourceRequestCocoa.mm:
524         (WebCore::ResourceRequest::doUpdateResourceRequest):
525         (WebCore::ResourceRequest::doUpdatePlatformRequest):
526
527 2015-05-22  Zalan Bujtas  <zalan@apple.com>
528
529         Unreviewed build fix for ENABLE(TREE_DEBUGGING)
530
531         * editing/VisibleSelection.h:
532         * html/parser/HTMLElementStack.h:
533         * html/parser/HTMLFormattingElementList.h:
534
535 2015-05-22  Joanmarie Diggs  <jdiggs@igalia.com>
536
537         AX: Figure out why list-detection2.html test fails on GTK
538         https://bugs.webkit.org/show_bug.cgi?id=145273
539
540         Reviewed by Chris Fleizach.
541
542         Platforms which expose rendered text content through the parent element "ignore" the
543         child renderers. This was causing AccessibilityList::childHasPseudoVisibleListItemMarker
544         to fail, which in turn caused the list detection heuristic to fail. Therefore add one
545         final check to this method to look for non-empty, non-whitespace text under the ::before
546         pseudo element.
547
548         No new tests; list-detection2.html now passes on GTK.
549
550         * accessibility/AccessibilityList.cpp:
551         (WebCore::AccessibilityList::childHasPseudoVisibleListItemMarkers):
552
553 2015-05-21  Jer Noble  <jer.noble@apple.com>
554
555         [iOS] Tell AVPlayerLayer when we enter optimized fullscreen mode.
556         https://bugs.webkit.org/show_bug.cgi?id=145289
557
558         Reviewed by Eric Carlson.
559
560         AVFoundation would normally already know that its AVPlayerLayer is in optimized
561         fullscreen mode, but because of the WebProcess/UIProcess split, they need to be
562         told explicitly in the WebProcess when the UIProcess enters optimized fullscreen
563         mode.
564
565         * html/HTMLMediaElement.h:
566         * html/HTMLVideoElement.cpp:
567         (WebCore::HTMLVideoElement::fullscreenModeChanged): Pass to private().
568         * platform/graphics/MediaPlayer.cpp:
569         (WebCore::MediaPlayer::setVideoFullscreenMode): Pass to m_private.
570         (WebCore::MediaPlayer::fullscreenMode): Pass to m_client.
571         * platform/graphics/MediaPlayer.h:
572         (WebCore::MediaPlayerClient::mediaPlayerFullscreenMode): Default implementation returns None.
573         * platform/graphics/MediaPlayerPrivate.h:
574         (WebCore::MediaPlayerPrivateInterface::setVideoFullscreenMode): Default implementation is a no-op.
575         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
576         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
577         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerLayer): Get the fullscreen
578             mode from MediaPlayer and tell the AVPlayerLayer if the mode is optimized.
579         (WebCore::MediaPlayerPrivateAVFoundationObjC::setVideoFullscreenMode):
580             Ditto.
581         * platform/spi/mac/AVFoundationSPI.h:
582
583 2015-05-21  Joanmarie Diggs  <jdiggs@igalia.com>
584
585         AX: [GTK] Implement computedRoleString in AccessibilityUIElement
586         https://bugs.webkit.org/show_bug.cgi?id=128420
587
588         Reviewed by Chris Fleizach.
589
590         Expose all ARIA roles (not just landmark-related roles) via an "xml-roles" AtkObject
591         attribute as per http://www.w3.org/TR/core-aam-1.1/#roleMappingGeneralRules
592
593         Expose non-empty computed role strings via AtkObject attribute named "computed-role".
594         Currently the computed role and the ARIA role value happen to be the same string, but
595         that might not always be the case. And AtkObject attributes are cheap.
596
597         Test: platform/gtk/accessibility/xml-roles-exposed.html.
598
599         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
600         (webkitAccessibleGetAttributes):
601
602 2015-05-21  Antti Koivisto  <antti@apple.com>
603
604         MaskImageOperation code does not manage CachedImageClients correctly
605         https://bugs.webkit.org/show_bug.cgi?id=145276
606         rdar://problem/20959822
607
608         Reviewed by Andreas Kling.
609
610         Test: css3/masking/mask-image-client-crash.html
611
612         * platform/graphics/MaskImageOperation.cpp:
613         (WebCore::MaskImageOperation::isMaskLoaded):
614         (WebCore::MaskImageOperation::setImage):
615
616             If image changes transfer the clients to the new image.
617
618         (WebCore::MaskImageOperation::setRenderLayerImageClient):
619
620             Always use setImage.
621
622         (WebCore::MaskImageOperation::notifyFinished):
623         * platform/graphics/MaskImageOperation.h:
624         * rendering/RenderLayer.cpp:
625         (WebCore::RenderLayer::calculateClipRects):
626         * rendering/RenderLayer.h:
627         * rendering/RenderLayerMaskImageInfo.cpp:
628         (WebCore::RenderLayer::MaskImageInfo::~MaskImageInfo):
629         (WebCore::RenderLayer::MaskImageInfo::updateMaskImageClients):
630
631             Store the MaskImageOperations where we added clients.
632
633         (WebCore::RenderLayer::MaskImageInfo::removeMaskImageClients):
634
635             Make sure we remove the clients from the same MaskImageOperations we added them to.
636
637         * rendering/RenderLayerMaskImageInfo.h:
638
639 2015-05-21  Daniel Bates  <dabates@apple.com>
640
641         Update Autofill button icon
642         https://bugs.webkit.org/show_bug.cgi?id=145191
643         <rdar://problem/20178942>
644
645         Reviewed by Jessie Berlin.
646
647         * css/html.css:
648         (input::-webkit-auto-fill-button):
649         (input::-webkit-auto-fill-button:active):
650         (input::-webkit-auto-fill-button:hover):
651
652 2015-05-21  Brady Eidson  <beidson@apple.com>
653
654         Add an "initiated by user gesture" flag to ResourceRequest.
655         https://bugs.webkit.org/show_bug.cgi?id=145281
656
657         Reviewed by Alex Christensen.
658
659         Allow WebKit to tell WebCore what the new property key is:
660         * platform/ios/WebCoreSystemInterfaceIOS.mm:
661         * platform/mac/WebCoreSystemInterface.h:
662         * platform/mac/WebCoreSystemInterface.mm:
663
664         Add the flag to ResourceRequest, and make sure it encodes/decodes:
665         * platform/network/ResourceRequestBase.h:
666         (WebCore::ResourceRequestBase::initiatedByUserGesture):
667         (WebCore::ResourceRequestBase::setInitiatedByUserGesture):
668         (WebCore::ResourceRequestBase::encodeWithoutPlatformData):
669         (WebCore::ResourceRequestBase::decodeWithoutPlatformData):
670
671         Set/get the property on native CFURLRequestRefs:
672         * platform/network/cf/ResourceRequestCFNet.cpp:
673         (WebCore::ResourceRequest::doUpdatePlatformRequest):
674         (WebCore::ResourceRequest::doUpdateResourceRequest):
675
676         Set/get the property on native NSURLRequests:
677         * platform/network/cocoa/ResourceRequestCocoa.mm:
678         (WebCore::ResourceRequest::doUpdateResourceRequest):
679         (WebCore::ResourceRequest::doUpdatePlatformRequest):
680
681 2015-05-21  Daniel Bates  <dabates@apple.com>
682
683         Rollout <http://trac.webkit.org/changeset/183909>
684         (https://bugs.webkit.org/show_bug.cgi?id=144657)
685
686         Revert <http://trac.webkit.org/changeset/183909> since pausing the database
687         thread prevents in-progress transactions from completing. We need to think
688         about this change some more.
689
690         * Modules/webdatabase/AbstractDatabaseServer.h:
691         * Modules/webdatabase/DatabaseManager.cpp:
692         (WebCore::DatabaseManager::setPauseAllDatabases): Deleted.
693         * Modules/webdatabase/DatabaseManager.h:
694         * Modules/webdatabase/DatabaseServer.cpp:
695         (WebCore::DatabaseServer::setPauseAllDatabases): Deleted.
696         * Modules/webdatabase/DatabaseServer.h:
697
698 2015-05-21  Jake Nielsen  <jacob_nielsen@apple.com>
699
700         r184718 and r184725 caused four tests to begin crashing
701
702         Unreviewed rollback.
703
704         Tests that started crashing:
705
706         svg/carto.net/textbox.svg svg/custom/tref-clone-crash.html svg/custom/use-animation-in-fill.html svg/custom/use-multiple-on-nested-disallowed-font.html
707
708         * svg/SVGAnimateElementBase.cpp:
709         (WebCore::propertyTypesAreConsistent):
710         * svg/SVGAnimatedPath.cpp:
711         (WebCore::SVGAnimatedPathAnimator::startAnimValAnimation):
712         * svg/SVGAnimatedTypeAnimator.h:
713         (WebCore::SVGAnimatedTypeAnimator::executeAction):
714         * svg/SVGAnimationElement.cpp:
715         (WebCore::SVGAnimationElement::parseAttribute):
716         * svg/SVGCursorElement.cpp:
717         (WebCore::SVGCursorElement::~SVGCursorElement):
718         (WebCore::SVGCursorElement::isSupportedAttribute):
719         * svg/SVGDocumentExtensions.cpp:
720         (WebCore::SVGDocumentExtensions::pauseAnimations):
721         (WebCore::SVGDocumentExtensions::unpauseAnimations):
722         (WebCore::SVGDocumentExtensions::dispatchSVGLoadEventToOutermostSVGElements):
723         (WebCore::SVGDocumentExtensions::isElementWithPendingResources):
724         (WebCore::SVGDocumentExtensions::removeElementFromPendingResources):
725         (WebCore::SVGDocumentExtensions::removeAllTargetReferencesForElement):
726         (WebCore::SVGDocumentExtensions::rebuildElements):
727         * svg/SVGElement.cpp:
728         (WebCore::populateAttributeNameToCSSPropertyIDMap):
729         (WebCore::populateAttributeNameToAnimatedPropertyTypeMap):
730         (WebCore::attributeNameToAnimatedPropertyTypeMap):
731         (WebCore::populateCSSPropertyWithSVGDOMNameToAnimatedPropertyTypeMap):
732         (WebCore::cssPropertyWithSVGDOMNameToAnimatedPropertyTypeMap):
733         (WebCore::hasLoadListener):
734         * svg/SVGFontData.cpp:
735         (WebCore::SVGFontData::applySVGGlyphSelection):
736         * svg/SVGFontElement.cpp:
737         (WebCore::SVGFontElement::registerLigaturesInGlyphCache):
738         (WebCore::SVGKerningMap::insert):
739         (WebCore::stringMatchesUnicodeRange):
740         * svg/SVGPathByteStream.h:
741         (WebCore::SVGPathByteStream::begin):
742         (WebCore::SVGPathByteStream::end):
743         (WebCore::SVGPathByteStream::append):
744         (WebCore::SVGPathByteStream::clear):
745         (WebCore::SVGPathByteStream::isEmpty):
746         * svg/SVGPathUtilities.cpp:
747         (WebCore::appendSVGPathByteStreamFromSVGPathSeg):
748         * svg/animation/SMILTimeContainer.cpp:
749         (WebCore::SMILTimeContainer::setElapsed):
750         (WebCore::SMILTimeContainer::updateAnimations):
751         * svg/animation/SVGSMILElement.cpp:
752         (WebCore::SVGSMILElement::parseBeginOrEnd):
753         (WebCore::SVGSMILElement::connectConditions):
754         (WebCore::SVGSMILElement::disconnectConditions):
755         (WebCore::SVGSMILElement::notifyDependentsIntervalChanged):
756         (WebCore::SVGSMILElement::createInstanceTimesFromSyncbase):
757         * svg/graphics/filters/SVGFilterBuilder.cpp:
758         (WebCore::SVGFilterBuilder::clearResultsRecursive):
759         * svg/graphics/filters/SVGFilterBuilder.h:
760         (WebCore::SVGFilterBuilder::addBuiltinEffects):
761         * svg/properties/SVGAnimatedProperty.cpp:
762         (WebCore::SVGAnimatedProperty::~SVGAnimatedProperty):
763         * svg/properties/SVGListProperty.h:
764         (WebCore::SVGListProperty::detachListWrappersAndResize):
765         * svg/properties/SVGPathSegListPropertyTearOff.cpp:
766         (WebCore::SVGPathSegListPropertyTearOff::clearContextAndRoles):
767
768 2015-05-21  Brent Fulgham  <bfulgham@apple.com>
769
770         Scroll-snap points needs to be updated during programmatic scrolls
771         https://bugs.webkit.org/show_bug.cgi?id=145216
772         <rdar://problem/21051039>
773
774         Reviewed by Dean Jackson.
775
776         Whenever we adjust the current scroll position, make sure we also update the current
777         active scroll snap offset index (if applicable).
778
779         * platform/ScrollAnimator.cpp:
780         (WebCore::ScrollAnimator::scrollToOffsetWithoutAnimation): Call the new 'updateActiveScrollSnapIndexForOffset'
781         method after moving to a new position.
782         (WebCore::ScrollAnimator::setCurrentPosition): Ditto.
783         (WebCore::ScrollAnimator::updateActiveScrollSnapIndexForOffset): New method. Asks the scroll controller to
784         identify the closest scroll snap offset index. If it finds something relevant, update the ScrollableArea state
785         to track these new values.
786         * platform/ScrollAnimator.h:
787         * platform/cocoa/ScrollController.h:
788         (WebCore::ScrollController::activeScrollSnapIndexDidChange):
789         (WebCore::ScrollController::setScrollSnapIndexDidChange):
790         * platform/cocoa/ScrollController.mm:
791         (WebCore::ScrollController::setNearestScrollSnapIndexForAxisAndOffset): Added. Find the closest relevant scroll snap offset
792         index for the given scroll offset, and update the internal scroll snap state to reflect it.
793         (WebCore::ScrollController::setActiveScrollSnapIndicesForOffset): Given the x and y offset for a scroll,
794         set the relevant scroll snap offset indices.
795         * platform/mac/ScrollAnimatorMac.mm:
796         (WebCore::ScrollAnimatorMac::immediateScrollTo): Call the new 'updateActiveScrollSnapIndexForOffset' method
797         after moving to a new position.
798         (WebCore::ScrollAnimatorMac::immediateScrollBy): Ditto.
799
800 2015-05-21  Matt Baker  <mattbaker@apple.com>
801
802         Unreviewed build fix.
803
804         * svg/SVGAnimateElementBase.cpp:
805         (WebCore::propertyTypesAreConsistent): should be type.properties, not type.properties().
806
807 2015-05-21  Xabier Rodriguez Calvar  <calvaris@igalia.com> and Youenn Fablet <youenn.fablet@crf.canon.fr>
808
809         [Streams API] Remove ReadableStreamReader closed promise internal slot
810         https://bugs.webkit.org/show_bug.cgi?id=145215
811
812         Reviewed by Darin Adler.
813
814         Using the new JSPromiseDeferred member generated by binding generator to handle closed promise attribute.
815         Removed internal slots routines previously used to ensure persistency of the promise.
816
817         Existing tests cover the changes.
818
819         * bindings/js/JSReadableStreamReaderCustom.cpp:
820         (WebCore::JSReadableStreamReader::closed):
821         (WebCore::JSReadableStreamReader::cancel): Deleted.
822         (WebCore::JSReadableStreamReader::releaseLock): Deleted.
823         * bindings/js/ReadableJSStream.cpp:
824         (WebCore::getPropertyFromObject): Deleted.
825         (WebCore::callFunction): Deleted.
826         (WebCore::ReadableJSStream::Source::create): Deleted.
827         (WebCore::ReadableJSStream::Source::Source): Deleted.
828         * bindings/js/ReadableJSStream.h:
829
830 2015-05-21  Roger Fong  <roger_fong@apple.com>
831
832         Media Controls stop updating after hovering for a few seconds.
833         https://bugs.webkit.org/show_bug.cgi?id=144770.
834         <rdar://problem/19823121>
835
836         Reviewed by Jer Noble.
837
838         * Modules/mediacontrols/mediaControlsApple.js:
839         (Controller.prototype.createBase):
840         We should never hide controls immediately as a result of mousing out of the controls.
841         It should only happen when the mouse leaves the video entirely.
842         (Controller.prototype.updateTimelineMetricsIfNeeded):
843         Don’t update if controls are hidden, timeline dimensions will be 0.
844         (Controller.prototype.handlePanelTransitionEnd): 
845         Instead of adjusting visibility via adding and removing classes,
846         remove controls entirely from the tree.
847         (Controller.prototype.showControls):
848         Add controls back into the tree when showing controls.
849         (Controller.prototype.updateForShowingControls):
850         Helper method for showControls.
851         (Controller.prototype.controlsAreHidden):
852         Controls also hidden if removed from tree.
853
854         Remove forceUpdate logic, no longer necessary.
855         (Controller.prototype.handleDurationChange): 
856         (Controller.prototype.updateProgress):
857         (Controller.prototype.updateTime):
858
859         Override methods to use add and remove panelContainer for iOS.
860         * Modules/mediacontrols/mediaControlsiOS.js:
861         (ControllerIOS.prototype.handlePanelTransitionEnd):
862         (ControllerIOS.prototype.showControls):
863         (ControllerIOS.prototype.controlsAreHidden):
864
865 2015-05-21  Chris Dumez  <cdumez@apple.com>
866
867         Regression(r179293): We no longer call destroyDecodedData() on CachedResources on memory pressure
868         https://bugs.webkit.org/show_bug.cgi?id=145270
869         <rdar://problem/20734901>
870
871         Reviewed by Andreas Kling.
872
873         We no longer call destroyDecodedData() on CachedResources on memory
874         pressure after r179293. In r179293, we started calling
875         MemoryCache::evictResources() on memory pressure instead of
876         MemoryCache::pruneToPercentage(0). However, unlike
877         MemoryCache::pruneToPercentage(), it appears
878         MemoryCache::evictResources() removes the CachedResources from the
879         memory cache without calling destroyDecodedData() on them.
880         This caused a regression on Membuster.
881
882         This patch now calls MemoryCache::pruneLiveResourcesToSize(0) on
883         critical memory pressure, instead of evictResources(). We don't need to
884         call pruneDeadResourcesToSize(0) here because the non-critical memory
885         pressure handler already takes care of this.
886
887         During local testing, this change seemed to decrease the overall memory
888         usage of WebProcesses by ~10MB on Membuster (tested on Yosemite).
889
890         * platform/MemoryPressureHandler.cpp:
891         (WebCore::MemoryPressureHandler::releaseNoncriticalMemory):
892         (WebCore::MemoryPressureHandler::releaseCriticalMemory):
893
894 2015-05-21  Said Abou-Hallawa  <sabouhallawa@apple.com>
895
896         SVG as image uses very tiny default font-size
897         https://bugs.webkit.org/show_bug.cgi?id=68090
898
899         Reviewed by Darin Adler.
900
901         When loading a document, WebKit creates a Page object and then changes its setting
902         from the browser's preferences. This is true for interactive resources also, such as a
903         stand-alone SVG or an SVG embedded in an <object> tag for example. For non-interactive
904         resources, like an SVG embedded in an <img> tag for example, this function is called
905         after loading the resource is finished. This function creates an artificial page and
906         fabricates a scoped settings for it. This turns out to be problematic for cases like
907         the default font size because its initial value is zero. We cannot go from WebCore to
908         WebKit to ask for the global settings. But we can inherit the global settings from the
909         the master page. This is not the best solution because of two reasons. (1) Once the
910         resource is cached and the styles for the text elements are calculated, nothing can
911         change the values of styles except removing the resource itself from the cache if the
912         browser's preferences change. Also there is no mechanism to notify this artificial
913         page if the browser's preferences change. (2) An image like a non-interactive SVG,
914         should be displayed the same way regardless of the browser's preferences. A user may
915         be able to change the default font size for other text. But this should not affect
916         images even if they are vector images like SVG. An easy and more agreeable solution
917         is to hard-code the default font size for this case and do not depend on the global
918         settings at all.
919
920         Test: svg/text/text-default-font-size.html
921
922         * page/Settings.in: Set the initial value of the setting defaultFontSize to be 16.
923         
924 2015-05-21  Hunseop Jeong  <hs85.jeong@samsung.com>
925
926         Use modern for-loops in WebCore/svg.
927         https://bugs.webkit.org/show_bug.cgi?id=145209
928
929         Reviewed by Darin Adler.
930
931         No new tests, no new tests.
932
933         * svg/SVGAnimateElementBase.cpp:
934         (WebCore::propertyTypesAreConsistent):
935         * svg/SVGAnimatedPath.cpp:
936         (WebCore::SVGAnimatedPathAnimator::startAnimValAnimation):
937         * svg/SVGAnimatedTypeAnimator.h:
938         (WebCore::SVGAnimatedTypeAnimator::executeAction):
939         * svg/SVGAnimationElement.cpp:
940         (WebCore::SVGAnimationElement::parseAttribute):
941         * svg/SVGCursorElement.cpp:
942         (WebCore::SVGCursorElement::~SVGCursorElement):
943         * svg/SVGDocumentExtensions.cpp:
944         (WebCore::SVGDocumentExtensions::pauseAnimations):
945         (WebCore::SVGDocumentExtensions::unpauseAnimations):
946         (WebCore::SVGDocumentExtensions::dispatchSVGLoadEventToOutermostSVGElements):
947         (WebCore::SVGDocumentExtensions::isElementWithPendingResources):
948         (WebCore::SVGDocumentExtensions::removeElementFromPendingResources):
949         (WebCore::SVGDocumentExtensions::removeAllTargetReferencesForElement):
950         * svg/SVGElement.cpp:
951         (WebCore::populateAttributeNameToCSSPropertyIDMap):
952         (WebCore::populateAttributeNameToAnimatedPropertyTypeMap):
953         (WebCore::populateCSSPropertyWithSVGDOMNameToAnimatedPropertyTypeMap):
954         (WebCore::hasLoadListener):
955         * svg/SVGFontData.cpp:
956         (WebCore::SVGFontData::applySVGGlyphSelection):
957         * svg/SVGFontElement.cpp:
958         (WebCore::SVGFontElement::registerLigaturesInGlyphCache):
959         (WebCore::SVGKerningMap::insert):
960         (WebCore::stringMatchesUnicodeRange):
961         * svg/SVGPathByteStream.h:
962         (WebCore::SVGPathByteStream::append):
963         * svg/animation/SMILTimeContainer.cpp:
964         (WebCore::SMILTimeContainer::setElapsed):
965         (WebCore::SMILTimeContainer::updateAnimations):
966         * svg/animation/SVGSMILElement.cpp:
967         (WebCore::SVGSMILElement::parseBeginOrEnd):
968         (WebCore::SVGSMILElement::connectConditions):
969         (WebCore::SVGSMILElement::disconnectConditions):
970         (WebCore::SVGSMILElement::notifyDependentsIntervalChanged):
971         (WebCore::SVGSMILElement::createInstanceTimesFromSyncbase):
972         * svg/graphics/filters/SVGFilterBuilder.cpp:
973         (WebCore::SVGFilterBuilder::clearResultsRecursive):
974         * svg/graphics/filters/SVGFilterBuilder.h:
975         (WebCore::SVGFilterBuilder::addBuiltinEffects):
976         * svg/properties/SVGAnimatedProperty.cpp:
977         (WebCore::SVGAnimatedProperty::~SVGAnimatedProperty):
978         * svg/properties/SVGListProperty.h:
979         (WebCore::SVGListProperty::detachListWrappersAndResize):
980         * svg/properties/SVGPathSegListPropertyTearOff.cpp:
981         (WebCore::SVGPathSegListPropertyTearOff::clearContextAndRoles):
982
983 2015-05-21  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
984
985         Purge PassRefPtr in WebCore/Modules
986         https://bugs.webkit.org/show_bug.cgi?id=145112
987
988         Reviewed by Darin Adler.
989
990         As a step to remove PassRefPtr, this patch replaces PassRefPtr with Ref or RefPtr
991         depends on null of return value.
992
993         No new tests, no behavior changes.
994
995         * Modules/encryptedmedia/MediaKeySession.cpp:
996         (WebCore::MediaKeySession::create):
997         * Modules/encryptedmedia/MediaKeySession.h:
998         * Modules/encryptedmedia/MediaKeys.cpp:
999         (WebCore::MediaKeys::create):
1000         (WebCore::MediaKeys::createSession):
1001         * Modules/encryptedmedia/MediaKeys.h:
1002         * Modules/gamepad/Gamepad.h:
1003         * Modules/gamepad/NavigatorGamepad.cpp:
1004         (WebCore::NavigatorGamepad::gamepadFromPlatformGamepad):
1005         * Modules/gamepad/deprecated/Gamepad.h:
1006         * Modules/geolocation/GeolocationError.h:
1007         (WebCore::GeolocationError::create):
1008         * Modules/geolocation/GeolocationPosition.h:
1009         (WebCore::GeolocationPosition::create):
1010         * Modules/geolocation/Geoposition.h:
1011         (WebCore::Geoposition::create):
1012         * Modules/geolocation/PositionError.h:
1013         (WebCore::PositionError::create):
1014         * Modules/geolocation/PositionOptions.h:
1015         (WebCore::PositionOptions::create):
1016         * Modules/mediacontrols/MediaControlsHost.cpp:
1017         (WebCore::MediaControlsHost::create):
1018         * Modules/mediacontrols/MediaControlsHost.h:
1019         * Modules/mediasource/MediaSource.cpp:
1020         (WebCore::MediaSource::create):
1021         * Modules/mediasource/MediaSource.h:
1022         * Modules/mediastream/RTCDataChannel.cpp:
1023         (WebCore::RTCDataChannel::create):
1024         * Modules/mediastream/RTCDataChannel.h:
1025         * Modules/mediastream/RTCIceCandidate.cpp:
1026         (WebCore::RTCIceCandidate::create):
1027         * Modules/mediastream/RTCIceCandidate.h:
1028         * Modules/webaudio/OfflineAudioContext.cpp:
1029         (WebCore::OfflineAudioContext::create):
1030         * Modules/webaudio/OfflineAudioContext.h:
1031         * Modules/webaudio/OfflineAudioDestinationNode.h:
1032         (WebCore::OfflineAudioDestinationNode::create):
1033         * Modules/webaudio/OscillatorNode.cpp:
1034         (WebCore::OscillatorNode::create):
1035         * Modules/webaudio/OscillatorNode.h:
1036         * Modules/webdatabase/Database.cpp:
1037         (WebCore::Database::runTransaction):
1038         * Modules/webdatabase/DatabaseTracker.cpp:
1039         (WebCore::DatabaseTracker::originLockFor):
1040         * Modules/webdatabase/DatabaseTracker.h:
1041         * Modules/webdatabase/SQLError.h:
1042         (WebCore::SQLError::create):
1043         * Modules/webdatabase/SQLResultSet.h:
1044         (WebCore::SQLResultSet::create):
1045         * Modules/webdatabase/SQLResultSetRowList.h:
1046         (WebCore::SQLResultSetRowList::create):
1047         * Modules/webdatabase/SQLStatementBackend.cpp:
1048         (WebCore::SQLStatementBackend::create):
1049         * Modules/webdatabase/SQLStatementBackend.h:
1050         * Modules/webdatabase/SQLTransactionBackend.cpp:
1051         (WebCore::SQLTransactionBackend::create):
1052         * Modules/webdatabase/SQLTransactionBackend.h:
1053         * Modules/websockets/ThreadableWebSocketChannelClientWrapper.cpp:
1054         (WebCore::ThreadableWebSocketChannelClientWrapper::create):
1055         * Modules/websockets/ThreadableWebSocketChannelClientWrapper.h:
1056         * Modules/websockets/WebSocket.cpp:
1057         (WebCore::WebSocket::create):
1058         * Modules/websockets/WebSocket.h:
1059         * Modules/websockets/WebSocketChannel.h:
1060         (WebCore::WebSocketChannel::create):
1061         * Modules/websockets/WorkerThreadableWebSocketChannel.h:
1062         (WebCore::WorkerThreadableWebSocketChannel::create):
1063         (WebCore::WorkerThreadableWebSocketChannel::Bridge::create):
1064         * editing/InsertListCommand.h:
1065         (WebCore::InsertListCommand::create):
1066         * workers/Worker.cpp:
1067         (WebCore::Worker::create):
1068         * workers/Worker.h:
1069         * xml/XPathExpression.cpp:
1070         (WebCore::XPathExpression::createExpression):
1071         (WebCore::XPathExpression::evaluate):
1072         * xml/XPathExpression.h:
1073
1074 2015-05-20  Commit Queue  <commit-queue@webkit.org>
1075
1076         Unreviewed, rolling out r184667 and r184682.
1077         https://bugs.webkit.org/show_bug.cgi?id=145245
1078
1079         Broke media/media-controls-timeline-updates.html on WebKit2
1080         (Requested by ap on #webkit).
1081
1082         Reverted changesets:
1083
1084         "Media Controls stop updating after hovering for a few
1085         seconds."
1086         https://bugs.webkit.org/show_bug.cgi?id=144770
1087         http://trac.webkit.org/changeset/184667
1088
1089         "Unreviewed. Media Controls stop updating after hovering for a
1090         few seconds."
1091         https://bugs.webkit.org/show_bug.cgi?id=144770
1092         http://trac.webkit.org/changeset/184682
1093
1094 2015-05-20  Jon Lee  <jonlee@apple.com>
1095
1096         [iOS] Update optimized fullscreen controls artwork
1097         https://bugs.webkit.org/show_bug.cgi?id=145208
1098         rdar://problem/21034032
1099
1100         Reviewed by Jer Noble.
1101
1102         Update the artwork when media goes into optimized fullscreen. Add a new UI part
1103         representing return-from-optimized.
1104
1105         * Modules/mediacontrols/MediaControlsHost.cpp:
1106         (WebCore::MediaControlsHost::mediaUIImageData): Return data for the return button.
1107         * Modules/mediacontrols/MediaControlsHost.idl: Add a new part ID.
1108         * Modules/mediacontrols/mediaControlsApple.js: Add a new ClassName to apply to the
1109         button when in the proper state.
1110         * Modules/mediacontrols/mediaControlsiOS.js:
1111         (ControllerIOS.prototype.handlePresentationModeChange): Add the ClassName when the
1112         video goes into optimized fullscreen mode. Remove it otherwise.
1113         * platform/ios/WebCoreSystemInterfaceIOS.h:
1114         * rendering/RenderThemeIOS.mm:
1115         (WebCore::RenderThemeIOS::mediaControlsStyleSheet): Add the return button data to the
1116         stylesheet.
1117
1118 2015-05-20  Alex Christensen  <achristensen@webkit.org>
1119
1120         [ContentExtensions] Properly initialize ActionKey.state
1121         https://bugs.webkit.org/show_bug.cgi?id=145237
1122         rdar://problem/20716683
1123
1124         Reviewed by Benjamin Poulain.
1125
1126         * contentextensions/DFAMinimizer.cpp:
1127         Initialize ActionKey.state to Valid if it is a valid ActionKey.
1128         Inlining can now be done safely.
1129
1130 2015-05-20  Roger Fong  <roger_fong@apple.com>
1131
1132         Unreviewed. Media Controls stop updating after hovering for a few seconds.
1133         https://bugs.webkit.org/show_bug.cgi?id=144770.
1134         <rdar://problem/19823121>
1135
1136         Followup to r184667.
1137         * Modules/mediacontrols/mediaControlsApple.js:
1138         (Controller.prototype.showControls):
1139         Only put controls back into the tree if they don’t yet exist in the tree.
1140         Otherwise we interrupt operations like scrubbing.
1141
1142 2015-05-20  Enrica Casucci  <enrica@apple.com>
1143
1144         [iOS] Using CSS viewport units causes incorrect layout.
1145         https://bugs.webkit.org/show_bug.cgi?id=145225
1146         rdar://problem/20924495
1147
1148         Reviewed by Benjamin Poulain.
1149
1150         * page/ViewportConfiguration.cpp:
1151         (WebCore::ViewportConfiguration::initialScaleFromSize):
1152         (WebCore::ViewportConfiguration::initialScale):
1153         (WebCore::ViewportConfiguration::initialScaleIgnoringContentSize):
1154         * page/ViewportConfiguration.h:
1155         (WebCore::ViewportConfiguration::initialScaleFromSize):
1156         (WebCore::ViewportConfiguration::initialScaleIgnoringContentSize):
1157
1158 2015-05-20  Chris Fleizach  <cfleizach@apple.com>
1159
1160         AX: improve list heuristics (presentational use versus actual lists)
1161         https://bugs.webkit.org/show_bug.cgi?id=134187
1162
1163         Reviewed by Darin Adler.
1164
1165         Improve heuristics for list detection by:
1166             1. Not exposing lists without list markers (unless explicitly marked as lists)
1167             2. Recognizing css: before-content as list markers
1168
1169         Test: accessibility/list-detection2.html
1170
1171         * accessibility/AccessibilityList.cpp:
1172         (WebCore::AccessibilityList::isDescriptionList):
1173         (WebCore::AccessibilityList::childHasPseudoVisibleListItemMarkers):
1174         (WebCore::AccessibilityList::determineAccessibilityRole):
1175         * accessibility/AccessibilityList.h:
1176
1177 2015-05-20  Antti Koivisto  <antti@apple.com>
1178
1179         REGRESSION (r172591): Can no longer style <optgroup> with colors (LayoutTests/fast/forms/select/optgroup-rendering.html)
1180         https://bugs.webkit.org/show_bug.cgi?id=145227
1181         rdar://problem/20967472
1182
1183         Reviewed by Darin Adler.
1184
1185         Test: fast/forms/select/select-painting.html
1186
1187         Use computedStyle() consistently for option and optgroup items.
1188
1189         * rendering/RenderListBox.cpp:
1190         (WebCore::RenderListBox::paintItemForeground):
1191         (WebCore::RenderListBox::paintItemBackground):
1192
1193             We can always use computedStyle() and it can't be null. If there was renderer style it would return that.
1194
1195         * rendering/RenderMenuList.cpp:
1196         (RenderMenuList::itemStyle):
1197         (RenderMenuList::getItemBackgroundColor):
1198
1199 2015-05-19  Jer Noble  <jer.noble@apple.com>
1200
1201         Touching HTMLMediaElement.h or MediaPlayer.h causes a world rebuild.
1202         https://bugs.webkit.org/show_bug.cgi?id=145193
1203
1204         Reviewed by Eric Carlson.
1205
1206         HTMLMediaElement.h and MediaPlayer.h are included in a number of headers solely for access to the enums
1207         defined within the classes contained within. Move these enums into their own--otherwise empty--classes.
1208         Then add `using` declarations to pull those inherited enums back into the namespace of HTMLMediaElement
1209         and MediaPlayer.
1210
1211         Classes and headers which do not need to directly include HTMLMediaElement.h can now include HTMLMediaElementEnums.h
1212         instead; the same goes for MediaPlayer.h and MediaPlayerEnums.h.
1213
1214         * WebCore.xcodeproj/project.pbxproj: Add new files to project.
1215         * html/HTMLMediaElement.cpp:
1216         (WebCore::HTMLMediaElement::TrackGroup::TrackGroup): Move definition here from the header.
1217         * html/HTMLMediaElement.h:
1218         (WebCore::HTMLMediaElement::videoFullscreenGravity): MediaPlayer -> MediaPlayerEnums.
1219         (WebCore::HTMLMediaElement::preloadValue): Ditto.
1220         (WebCore::HTMLMediaElement::TrackGroup::TrackGroup): Deleted; moved to implementation file.
1221         * html/HTMLMediaElementEnums.h: Added.
1222         * html/MediaControllerInterface.h: Inherit from HTMLMediaElementEnums.
1223         * page/ChromeClient.h: HTMLMediaElement -> HTMLMediaElementEnums.
1224         * platform/graphics/MediaPlayer.h: MediaPlayer -> MediaPlayerEnums.
1225         * platform/graphics/MediaPlayerEnums.h: Added.
1226         * platform/ios/WebVideoFullscreenControllerAVKit.h:
1227         * platform/ios/WebVideoFullscreenControllerAVKit.mm:
1228         (-[WebVideoFullscreenController enterFullscreen:mode:]): HTMLMediaElement -> HTMLMediaElementEnums.
1229         * platform/ios/WebVideoFullscreenInterfaceAVKit.h:
1230         * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
1231         (WebVideoFullscreenInterfaceAVKit::setupFullscreen): Ditto.
1232         (WebVideoFullscreenInterfaceAVKit::setupFullscreenInternal): Ditto.
1233         (WebVideoFullscreenInterfaceAVKit::enterFullscreen): Ditto.
1234         (WebVideoFullscreenInterfaceAVKit::exitFullscreenInternal): Ditto.
1235         (WebVideoFullscreenInterfaceAVKit::cleanupFullscreenInternal): Ditto.
1236         (WebVideoFullscreenInterfaceAVKit::requestHideAndExitFullscreen): Ditto.
1237         (WebVideoFullscreenInterfaceAVKit::mayAutomaticallyShowVideoOptimized): Ditto.
1238         (WebVideoFullscreenInterfaceAVKit::willStartOptimizedFullscreen): Ditto.
1239         (WebVideoFullscreenInterfaceAVKit::didStopOptimizedFullscreen): Ditto.
1240         (WebVideoFullscreenInterfaceAVKit::didCancelOptimizedFullscreen): Ditto.
1241         (WebVideoFullscreenInterfaceAVKit::setMode): Ditto.
1242         (WebVideoFullscreenInterfaceAVKit::clearMode): Ditto.
1243         * platform/ios/WebVideoFullscreenModel.h:
1244         * platform/ios/WebVideoFullscreenModelVideoElement.h:
1245         * platform/ios/WebVideoFullscreenModelVideoElement.mm:
1246         (WebVideoFullscreenModelVideoElement::setVideoElement): Ditto.
1247         (WebVideoFullscreenModelVideoElement::fullscreenModeChanged): Ditto.
1248
1249 2015-05-20  Roger Fong  <roger_fong@apple.com>
1250
1251         Media Controls stop updating after hovering for a few seconds.
1252         https://bugs.webkit.org/show_bug.cgi?id=144770.
1253         <rdar://problem/19823121>
1254
1255         Reviewed by Jer Noble.
1256
1257         * Modules/mediacontrols/mediaControlsApple.js:
1258         (Controller.prototype.createBase):
1259         We should never hide controls immediately as a result of mousing out of the controls.
1260         It should only happen when the mouse leaves the video entirely.
1261         (Controller.prototype.updateTimelineMetricsIfNeeded):
1262         Don’t update if controls are hidden, timeline dimensions will be 0.
1263         (Controller.prototype.handlePanelTransitionEnd): 
1264         Instead of adjusting visibility via adding and removing classes,
1265         remove controls entirely from the tree.
1266         (Controller.prototype.showControls):
1267         Add controls back into the tree when showing controls.
1268         (Controller.prototype.updateForShowingControls):
1269         Helper method for showControls.
1270         (Controller.prototype.controlsAreHidden):
1271         Controls also hidden if removed from tree.
1272
1273         Remove forceUpdate logic, no longer necessary.
1274         (Controller.prototype.handleDurationChange): 
1275         (Controller.prototype.updateProgress):
1276         (Controller.prototype.updateTime):
1277
1278         Override methods to use add and remove panelContainer for iOS.
1279         * Modules/mediacontrols/mediaControlsiOS.js:
1280         (ControllerIOS.prototype.handlePanelTransitionEnd):
1281         (ControllerIOS.prototype.showControls):
1282         (ControllerIOS.prototype.controlsAreHidden):
1283
1284 2015-05-20  Eric Carlson  <eric.carlson@apple.com>
1285
1286         [Mac] inform media session of all state changes
1287         https://bugs.webkit.org/show_bug.cgi?id=145222
1288
1289         Reviewed by Dean Jackson.
1290
1291         * html/HTMLMediaElement.cpp:
1292         (WebCore::HTMLMediaElement::~HTMLMediaElement): Call updateMediaState.
1293         (WebCore::HTMLMediaElement::mediaPlayerEngineUpdated): Ditto.
1294         (WebCore::HTMLMediaElement::mediaPlayerFirstVideoFrameAvailable): Ditto.
1295         (WebCore::HTMLMediaElement::removeEventListener): Ditto.
1296         (WebCore::HTMLMediaElement::enqueuePlaybackTargetAvailabilityChangedEvent): Ditto.
1297
1298 2015-05-20  Daniel Bates  <dabates@apple.com>
1299
1300         AX: AutoFill button is not accessible with VoiceOver
1301         https://bugs.webkit.org/show_bug.cgi?id=145200
1302         <rdar://problem/20507480>
1303
1304         Reviewed by Chris Fleizach.
1305
1306         Add ARIA label and role attributes to the AutoFill button markup so that VoiceOver
1307         can identify and interact with it.
1308
1309         Test: accessibility/input-auto-fill-button.html
1310
1311         * English.lproj/Localizable.strings: Add placeholder localized string for AutoFill button.
1312         * html/TextFieldInputType.cpp:
1313         (WebCore::TextFieldInputType::createAutoFillButton): Add ARIA label and role attributes.
1314         * platform/LocalizedStrings.cpp:
1315         (WebCore::AXAutoFillButtonText): Added; returns the localized string for the AutoFill button.
1316         * platform/LocalizedStrings.h:
1317         * platform/efl/LocalizedStringsEfl.cpp:
1318         (WebCore::AXAutoFillButtonText): Ditto.
1319         * platform/gtk/LocalizedStringsGtk.cpp:
1320         (WebCore::AXAutoFillButtonText): Ditto.
1321
1322 2015-05-20  Dean Jackson  <dino@apple.com>
1323
1324         Label text for default buttons don’t have the correct white color
1325         https://bugs.webkit.org/show_bug.cgi?id=145221
1326         <rdar://problem/20985817>
1327
1328         Follow-up commit. After discussion with the AppKit team, we've
1329         concluded that a solid white is the color that best matches
1330         the system.
1331
1332         * rendering/RenderThemeMac.mm:
1333         (WebCore::RenderThemeMac::systemColor): Use Color::white.
1334
1335 2015-05-20  Dean Jackson  <dino@apple.com>
1336
1337         Label text for default buttons don’t have the correct white color
1338         https://bugs.webkit.org/show_bug.cgi?id=145221
1339         <rdar://problem/20985817>
1340
1341         Reviewed by Tim Horton.
1342
1343         Use a 85% solid white for the active text color on buttons.
1344
1345         As has been disappointingly pointed out in other patches, we don't
1346         have a good way to test ActiveButtonText since it only applies at
1347         paint time.
1348
1349         * rendering/RenderThemeMac.mm:
1350         (WebCore::RenderThemeMac::systemColor): Move to an 85% solid white.
1351
1352 2015-05-20  Alexey Proskuryakov  <ap@apple.com>
1353
1354         ThreadableLoaderOptions::isolatedCopy() doesn't produce a copy that is safe for sending to another thread
1355         https://bugs.webkit.org/show_bug.cgi?id=145217
1356
1357         Reviewed by Anders Carlsson.
1358
1359         Caught by existing tests, rarely. I don't know how to catch such bugs more reliably.
1360
1361         * loader/ThreadableLoader.cpp: (WebCore::ThreadableLoaderOptions::isolatedCopy):
1362         * loader/ThreadableLoader.h:
1363
1364 2015-05-20  Tim Horton  <timothy_horton@apple.com>
1365
1366         Add a mechanism to opt-out of the automatic scaling applied to not-really-responsive sites
1367         https://bugs.webkit.org/show_bug.cgi?id=144760
1368
1369         Reviewed by Darin Adler.
1370
1371         Add a new viewport property, shrink-to-fit, which can be used to disable
1372         the automatic scaling introduced in r181400. This provides sites with a
1373         way to tell WebKit that they're really sure they want to be laid out at
1374         window-width/height, even if they fail to fit within that size.
1375
1376         * dom/ViewportArguments.cpp:
1377         (WebCore::ViewportArguments::resolve):
1378         (WebCore::findBooleanValue):
1379         (WebCore::setViewportFeature):
1380         * dom/ViewportArguments.h:
1381         (WebCore::ViewportArguments::ViewportArguments):
1382         (WebCore::ViewportArguments::operator==):
1383         * page/ViewportConfiguration.cpp:
1384         (WebCore::ViewportConfiguration::shouldIgnoreHorizontalScalingConstraints):
1385         (WebCore::ViewportConfiguration::shouldIgnoreVerticalScalingConstraints):
1386         (WebCore::ViewportConfiguration::webpageParameters):
1387         (WebCore::ViewportConfiguration::textDocumentParameters):
1388         (WebCore::ViewportConfiguration::imageDocumentParameters):
1389         (WebCore::ViewportConfiguration::testingParameters):
1390         (WebCore::booleanViewportArgumentIsSet):
1391         (WebCore::ViewportConfiguration::updateConfiguration):
1392         (WebCore::ViewportConfigurationTextStream::operator<<):
1393         (WebCore::viewportArgumentUserZoomIsSet): Deleted.
1394         * page/ViewportConfiguration.h:
1395         (WebCore::ViewportConfiguration::Parameters::Parameters):
1396         Plumb the shrink-to-fit viewport property through.
1397         If shrink-to-fit is set to yes, or not set, we behave as usual; if it is
1398         set to no, we will bail from shouldIgnore[Horizontal|Vertical]ScalingConstraints,
1399         effectively disabling the automatic scaling introduced in r181400.
1400
1401 2015-05-20  Antti Koivisto  <antti@apple.com>
1402
1403         Assertion failure in WebCore::BidiRun::BidiRun()
1404         https://bugs.webkit.org/show_bug.cgi?id=145203
1405         rdar://problem/20958973
1406
1407         Reviewed by Andreas Kling.
1408
1409         Test: fast/text/text-combine-crash.html
1410
1411         * rendering/line/BreakingContext.h:
1412         (WebCore::BreakingContext::handleText):
1413
1414             Renove !isCombined() check. RenderCombineText::combineText() doesn't
1415             do any work unless needed and text may become uncombined too.
1416
1417         * rendering/line/LineBreaker.cpp:
1418         (WebCore::LineBreaker::skipLeadingWhitespace):
1419
1420             Same here.
1421
1422 2015-05-20  Youenn Fablet  <youenn.fablet@crf.canon.fr>
1423
1424         AudioContext resume/close/suspend should reject promises with a DOM exception in lieu of throwing exceptions
1425         https://bugs.webkit.org/show_bug.cgi?id=145064
1426
1427         Reviewed by Darin Adler.
1428
1429         Rejecting resume/suspend/close promises with InvalidStateError values in case context is offline.
1430         Removed unneeded calls to postTask for resolving/rejecting promises.
1431         Adding promise rejection of DOM Exception values, 0 being equivalent of no error passed to reject callback.
1432
1433         Test: webaudio/audiocontext-promise-throwing.html
1434
1435         * Modules/webaudio/AudioContext.cpp:
1436         (WebCore::AudioContext::suspendContext): Rejecting promise in lieu of throwing exception.
1437         (WebCore::AudioContext::resumeContext): Ditto.
1438         (WebCore::AudioContext::closeContext): Ditto.
1439         * Modules/webaudio/AudioContext.h:
1440         * bindings/js/JSAudioContextCustom.cpp:
1441         (WebCore::JSAudioContext::suspend): Removing ExceptionCode handling.
1442         (WebCore::JSAudioContext::resume): Ditto.
1443         (WebCore::JSAudioContext::close): Ditto.
1444         * bindings/js/JSDOMBinding.cpp:
1445         (WebCore::createDOMException): Splitting DOM exception creation from throwing.
1446         (WebCore::setDOMException): Ditto.
1447         * bindings/js/JSDOMBinding.h: Adding createDOMException prototype.
1448         * bindings/js/JSDOMPromise.h:
1449         (WebCore::DeferredWrapper::reject<ExceptionCode>):
1450
1451 2015-05-20  Commit Queue  <commit-queue@webkit.org>
1452
1453         Unreviewed, rolling out r184645.
1454         https://bugs.webkit.org/show_bug.cgi?id=145220
1455
1456         Broken build (Requested by jacob_nielsen on #webkit).
1457
1458         Reverted changeset:
1459
1460         "AX: AutoFill button is not accessible with VoiceOver"
1461         https://bugs.webkit.org/show_bug.cgi?id=145200
1462         http://trac.webkit.org/changeset/184645
1463
1464 2015-05-20  Daniel Bates  <dabates@apple.com>
1465
1466         AX: AutoFill button is not accessible with VoiceOver
1467         https://bugs.webkit.org/show_bug.cgi?id=145200
1468         <rdar://problem/20507480>
1469
1470         Reviewed by Chris Fleizach.
1471
1472         Add ARIA label and role attributes to the AutoFill button markup so that VoiceOver
1473         can identify and interact with it.
1474
1475         Test: accessibility/input-auto-fill-button.html
1476
1477         * English.lproj/Localizable.strings: Add placeholder localized string for AutoFill button.
1478         * html/TextFieldInputType.cpp:
1479         (WebCore::TextFieldInputType::createAutoFillButton): Add ARIA label and role attributes.
1480         * platform/LocalizedStrings.cpp:
1481         (WebCore::AXAutoFillButtonText): Added; returns the localized string for the AutoFill button.
1482         * platform/LocalizedStrings.h:
1483         * platform/efl/LocalizedStringsEfl.cpp:
1484         (WebCore::AXAutoFillButtonText): Ditto.
1485         * platform/gtk/LocalizedStringsGtk.cpp:
1486         (WebCore::AXAutoFillButtonText): Ditto.
1487
1488 2015-05-20  Alex Christensen  <achristensen@webkit.org>
1489
1490         [Content Extensions] Relax restrictions on triggers that match everything.
1491         https://bugs.webkit.org/show_bug.cgi?id=145069
1492
1493         Reviewed by Benjamin Poulain.
1494
1495         Added API tests that cover the new functionality and test for correctness in behavior.
1496
1497         * contentextensions/CompiledContentExtension.cpp:
1498         (WebCore::ContentExtensions::CompiledContentExtension::globalDisplayNoneSelectors):
1499         * contentextensions/ContentExtensionCompiler.cpp:
1500         (WebCore::ContentExtensions::addUniversalActionsToDFA):
1501         (WebCore::ContentExtensions::compileRuleList):
1502         Put universalActionsWithoutDomains into the DFA from filtersWithoutDomains and
1503         put universalActionsWithDomains into the DFA from filtersWithDomains.        
1504         * contentextensions/ContentExtensionError.cpp:
1505         (WebCore::ContentExtensions::contentExtensionErrorCategory):
1506         * contentextensions/ContentExtensionError.h:
1507         Remove error codes for errors that are not errors any more.
1508         * contentextensions/ContentExtensionsBackend.cpp:
1509         (WebCore::ContentExtensions::ContentExtensionsBackend::actionsForResourceLoad):
1510         * contentextensions/ContentExtensionsBackend.h:
1511         * contentextensions/DFABytecode.h:
1512         (WebCore::ContentExtensions::instructionSizeWithArguments):
1513         * contentextensions/DFABytecodeCompiler.cpp:
1514         (WebCore::ContentExtensions::set32Bits):
1515         (WebCore::ContentExtensions::DFABytecodeCompiler::emitAppendAction):
1516         (WebCore::ContentExtensions::DFABytecodeCompiler::emitJump):
1517         (WebCore::ContentExtensions::DFABytecodeCompiler::emitCheckValue):
1518         (WebCore::ContentExtensions::DFABytecodeCompiler::emitCheckValueRange):
1519         (WebCore::ContentExtensions::DFABytecodeCompiler::compileNode):
1520         (WebCore::ContentExtensions::DFABytecodeCompiler::compile):
1521         (WebCore::ContentExtensions::DFABytecodeCompiler::emitTestFlagsAndAppendAction): Deleted.
1522         * contentextensions/DFABytecodeCompiler.h:
1523         * contentextensions/DFABytecodeInterpreter.cpp:
1524         (WebCore::ContentExtensions::DFABytecodeInterpreter::interpretAppendAction):
1525         (WebCore::ContentExtensions::DFABytecodeInterpreter::interpretTestFlagsAndAppendAction):
1526         (WebCore::ContentExtensions::DFABytecodeInterpreter::actionsForDefaultStylesheetFromDFARoot):
1527         (WebCore::ContentExtensions::DFABytecodeInterpreter::interpret):
1528         (WebCore::ContentExtensions::DFABytecodeInterpreter::actionsFromDFARoot): Deleted.
1529         * contentextensions/DFABytecodeInterpreter.h:
1530         Add a new bytecode AppendActionDefaultStylesheet to mark actions that are css-display-none
1531         that need to be put in the default stylesheet to be ignored or not as a whole.
1532         css-display-none actions with flags or domain rules and css-display-none actions 
1533         after ignore-previous-rules actions are not to be in this precompiled stylesheet, but
1534         they will be applied as needed per page.  The precompiled stylesheet is already applied
1535         if no ignore-previous-rules action is triggered.
1536         * loader/ResourceLoadInfo.h:
1537
1538 2015-05-20  Youenn Fablet  <youenn.fablet@crf.canon.fr>
1539
1540         JS binding generator should create a member variable for each Promise attribute of an interface
1541         https://bugs.webkit.org/show_bug.cgi?id=145056
1542
1543         Reviewed by Darin Adler.
1544
1545         For each attribute XXX whose type is Promise, a member m_XXXPromiseDeferred is created, its type being a JSC::Strong of JSPromiseDeferred.
1546         The purpose is to enable custom getters to create the JSPromiseDeferred and store ino the class member to ensure the same promise is returned each time
1547         the custom getter is called.
1548         This patch will enable simplifying ReadableStreamReader custom binding.
1549
1550         Covered by added attribute in TestObj.idl.
1551
1552         * bindings/scripts/CodeGeneratorJS.pm:
1553         (GenerateHeader):
1554         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
1555         (webkit_dom_test_obj_get_property):
1556         (webkit_dom_test_obj_class_init):
1557         (webkit_dom_test_obj_get_test_promise_attr):
1558         (webkit_dom_test_obj_set_nullable_string_value): Deleted.
1559         * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
1560         * bindings/scripts/test/JS/JSTestObj.cpp:
1561         (WebCore::jsTestObjTestPromiseAttr):
1562         (WebCore::jsTestObjAttributeWithReservedEnumType): Deleted.
1563         * bindings/scripts/test/JS/JSTestObj.h:
1564         * bindings/scripts/test/ObjC/DOMTestObj.h:
1565         * bindings/scripts/test/ObjC/DOMTestObj.mm:
1566         (-[DOMTestObj testPromiseAttr]):
1567         (-[DOMTestObj attribute]): Deleted.
1568         * bindings/scripts/test/TestObj.idl:
1569
1570 2015-05-20  Youenn Fablet  <youenn.fablet@crf.canon.fr>
1571
1572         AudioContext suspend/resume/close should resolve promises immediately when state is already suspended/active/closed
1573         https://bugs.webkit.org/show_bug.cgi?id=145164
1574
1575         Reviewed by Jer Noble.
1576
1577         Test: webaudio/audiocontext-promise.html
1578
1579         * Modules/webaudio/AudioContext.cpp:
1580         (WebCore::AudioContext::suspendContext): Immediatly call callbacks whenever possible to resolve/reject promises.
1581         (WebCore::AudioContext::resumeContext): Ditto.
1582         (WebCore::AudioContext::closeContext): Ditto
1583
1584 2015-05-20  Carlos Garcia Campos  <cgarcia@igalia.com>
1585
1586         REGRESSION(r184420): [GTK] webkit_dom_html_element_get_children has been removed
1587         https://bugs.webkit.org/show_bug.cgi?id=145174
1588
1589         Reviewed by Philippe Normand.
1590
1591         children property has been moved to Element, Document and
1592         DocumentFragment to match the spec, so we need to expose the new
1593         get_children and bring back webkit_dom_html_element_get_children()
1594         as deprecated.
1595
1596         * bindings/gobject/WebKitDOMDeprecated.cpp:
1597         (webkit_dom_html_element_get_children):
1598         * bindings/gobject/WebKitDOMDeprecated.h:
1599         * bindings/gobject/WebKitDOMDeprecated.symbols:
1600         * bindings/gobject/webkitdom.symbols:
1601
1602 2015-05-20  Hunseop Jeong  <hs85.jeong@samsung.com>
1603
1604         nullptr cleanup in WebCore/xml.
1605         https://bugs.webkit.org/show_bug.cgi?id=145165
1606
1607         Reviewed by Csaba Osztrogonác.
1608
1609         No new tests, no behavior changes
1610
1611         * xml/XMLHttpRequest.cpp:
1612         (WebCore::XMLHttpRequest::responseXML):
1613         (WebCore::XMLHttpRequest::internalAbort):
1614         (WebCore::XMLHttpRequest::clearResponseBuffers):
1615         (WebCore::XMLHttpRequest::clearRequest):
1616         (WebCore::XMLHttpRequest::didFinishLoading):
1617         * xml/XMLHttpRequestProgressEventThrottle.cpp:
1618         (WebCore::XMLHttpRequestProgressEventThrottle::flushProgressEvent):
1619         * xml/XSLImportRule.cpp:
1620         (WebCore::XSLImportRule::XSLImportRule):
1621         (WebCore::XSLImportRule::~XSLImportRule):
1622         (WebCore::XSLImportRule::setXSLStyleSheet):
1623         (WebCore::XSLImportRule::loadSheet):
1624         * xml/XSLStyleSheet.h:
1625         * xml/XSLStyleSheetLibxslt.cpp:
1626         (WebCore::XSLStyleSheet::XSLStyleSheet):
1627         (WebCore::XSLStyleSheet::~XSLStyleSheet):
1628         (WebCore::XSLStyleSheet::clearDocuments):
1629         * xml/XSLTProcessorLibxslt.cpp:
1630         (WebCore::saveResultToString):
1631         (WebCore::xsltParamArrayFromParameterMap):
1632         (WebCore::xmlDocPtrFromNode):
1633         (WebCore::XSLTProcessor::transformToString):
1634         * xml/parser/XMLDocumentParser.cpp:
1635         (WebCore::XMLDocumentParser::clearCurrentNodeStack):
1636         (WebCore::XMLDocumentParser::exitText):
1637         (WebCore::XMLDocumentParser::notifyFinished):
1638         * xml/parser/XMLDocumentParser.h:
1639         * xml/parser/XMLDocumentParserLibxml2.cpp:
1640         (WebCore::openFunc):
1641         (WebCore::XMLDocumentParser::XMLDocumentParser):
1642         * xml/parser/XMLDocumentParserScope.cpp:
1643         * xml/parser/XMLDocumentParserScope.h:
1644
1645 2015-05-19  Carlos Garcia Campos  <cgarcia@igalia.com>
1646
1647         [SOUP] Network Cache: Implement ShareableResource for Soup and enable it for GTK platform
1648         https://bugs.webkit.org/show_bug.cgi?id=144380
1649
1650         Reviewed by Antti Koivisto.
1651
1652         Add a soup implementation of SharedBuffer::tryReplaceContentsWithPlatformBuffer().
1653
1654         Covered by http/tests/cache/disk-cache/ tests.
1655
1656         * loader/cache/CachedResource.cpp: Define
1657         CachedResource::tryReplaceEncodedData() also for Soup.
1658         * loader/cache/CachedResource.h: Ditto.
1659         * platform/soup/SharedBufferSoup.cpp:
1660         (WebCore::SharedBuffer::tryReplaceContentsWithPlatformBuffer):
1661
1662 2015-05-17  Sam Weinig  <sam@webkit.org>
1663
1664         Organize event handlers a bit
1665         https://bugs.webkit.org/show_bug.cgi?id=145106
1666
1667         Reviewed by Darin Adler.
1668
1669         - Add GlobalEventHandlers.idl (from https://html.spec.whatwg.org/multipage/webappapis.html#globaleventhandlers)
1670           and move all event handlers shared by Element, Document and DOMWindow there. Put all the standard defined
1671           event handlers at the top (commenting out the ones that aren't implemented yet) and the non-standard ones
1672           at the bottom.
1673
1674           There is one change in behavior here. Previously, the media related event handlers where only exposed on
1675           Element and DOMWindow. The spec says they should also be on Document, so this adds support for that (this
1676           is tested in fast/dom/event-handler-attributes.html).
1677
1678         - Add WindowEventHandlers.idl (from https://html.spec.whatwg.org/multipage/webappapis.html#windoweventhandlers)
1679           and move all event handlers shared by DOMWindow, HTMLBodyElement and HTMLFrameSetElement there. Put all the 
1680           standard defined event handlers at the top (commenting out the ones that aren't implemented yet) and the 
1681           non-standard ones at the bottom.
1682
1683         - Group remaining event handlers in Element, Document, DOMWindow, HTMLBodyElement and HTMLFrameSetElement by
1684           their grouping, and add some FIXMEs for future cleaning.
1685
1686         * CMakeLists.txt:
1687         * DerivedSources.make:
1688         * WebCore.xcodeproj/project.pbxproj:
1689         - Add GlobalEventHandlers.idl and WindowEventHandlers.idl.
1690
1691         * bindings/scripts/CodeGeneratorJS.pm:
1692         (GenerateImplementation):
1693         Add special cases for WindowEventHandler when used on DOMWindow and DocumentEventHandler when used on Document
1694         so that event handlers using those extended attributes can be set on shared interfaces. This is used to allow
1695         DOMWindow to implement WindowEventHandlers.
1696
1697         * dom/Document.idl:
1698         Move event handlers to GlobalEventHandlers and have Document implement it. Group remaining event handlers.
1699
1700         * dom/Element.idl:
1701         Move event handlers to GlobalEventHandlers and have Element implement it. Group remaining event handlers.
1702
1703         * dom/GlobalEventHandlers.idl:
1704         Added.
1705
1706         * html/HTMLBodyElement.idl:
1707         Move event handlers to WindowEventHandlers and have HTMLBodyElement implement it. Group remaining event handlers.
1708         
1709         * html/HTMLFrameSetElement.idl:
1710         Move event handlers to WindowEventHandlers and have HTMLFrameSetElement implement it. Group remaining event handlers.
1711
1712         * page/DOMWindow.idl:
1713         Move event handlers to GlobalEventHandlers and WindowEventHandlers and have DOMWindow implement both of them. Group 
1714         remaining event handlers.
1715
1716         * page/WindowEventHandlers.idl:
1717         Added.
1718
1719 2015-05-19  Antti Koivisto  <antti@apple.com>
1720
1721         Crash under WebCore::invalidateStyleRecursively
1722         https://bugs.webkit.org/show_bug.cgi?id=145186
1723         rdar://problem/19736838
1724
1725         Reviewed by Andreas Kling
1726
1727         We have seen crashes where we run out of stack under invalidateStyleRecursively in StyleInvalidationAnalysis
1728         on some devices.
1729
1730         Switch to iterative algorithm.
1731
1732         * css/StyleInvalidationAnalysis.cpp:
1733         (WebCore::StyleInvalidationAnalysis::StyleInvalidationAnalysis):
1734         (WebCore::invalidateIfNeeded):
1735         (WebCore::invalidateStyleForTree):
1736         (WebCore::StyleInvalidationAnalysis::invalidateStyle):
1737         (WebCore::invalidateStyleRecursively): Deleted.
1738
1739 2015-05-19  Yusuke Suzuki  <utatane.tea@gmail.com>
1740
1741         Move AtomicStringImpl table related operations from AtomicString to AtomicStringImpl
1742         https://bugs.webkit.org/show_bug.cgi?id=145109
1743
1744         Reviewed by Darin Adler.
1745
1746         * dom/TreeScope.cpp:
1747         (WebCore::TreeScope::getElementById):
1748
1749 2015-05-19  Jon Lee  <jonlee@apple.com>
1750
1751         [iOS] Optimized fullscreen placeholder is incorrectly sized
1752         https://bugs.webkit.org/show_bug.cgi?id=145196
1753         rdar://problem/21031188
1754
1755         Reviewed by Dean Jackson.
1756
1757         Add a new media part UI for the placeholder text when entering optimized fullscreen,
1758         and use it as part of the title text in the placeholder. Now the wireless playback status
1759         div serves as a multi-purpose placeholder.
1760
1761         * Modules/mediacontrols/MediaControlsHost.cpp:
1762         (WebCore::MediaControlsHost::mediaUIImageData): Return the placeholder text.
1763         * Modules/mediacontrols/MediaControlsHost.idl: Add a new UI part for placeholder text.
1764         * Modules/mediacontrols/mediaControlsApple.js: Add a new "optimized" ClassName when
1765         the presentation mode is set to optimized.
1766
1767         * Modules/mediacontrols/mediaControlsiOS.css:
1768         (audio::-webkit-media-controls-wireless-playback-status): The text should be at
1769         medium weight, not light weight.
1770         (audio::-webkit-media-controls-wireless-playback-text-top): The title text should be
1771         white for both wireless playback and optimized fullscreen. It matches the style
1772         when taking a video fullscreen.
1773
1774         Add new CSS rules when the placard is used for optimized fullscreen.
1775         (audio::-webkit-media-controls-wireless-playback-status.optimized): Accommodate the
1776         size of the graphic, and position appropriately.
1777         (audio::-webkit-media-controls-wireless-playback-text-top.optimized): One line is
1778         needed, so use this one, and place it where the bottom one is since more room is
1779         needed to accommodate the graphic.
1780         (audio::-webkit-media-controls-wireless-playback-text-bottom.optimized): One line is
1781         needed, so hide this one.
1782         * Modules/mediacontrols/mediaControlsiOS.js:
1783         (ControllerIOS.prototype.createControls): Several of the container divs are already
1784         created in Controller.prototype.createControls(). Fly-by fix to avoid creation of
1785         those divs. Only the panelContainer is new for the iOS controls. Fly-by fix of a
1786         missing semicolon.
1787         (ControllerIOS.prototype.handlePresentationModeChange): When the presentation mode
1788         changes do several things:
1789             1- Update the background image. Clear the inline background image when going back
1790                to inline or in wireless playback.
1791             2- Add the "optimized" ClassName to the placeholder container, and the two text
1792                divs when entering optimized fullscreen. Remove them in other cases.
1793             3- Set -webkit-media-controls-wireless-playback-text-top to the placeholder text.
1794                This is better than embedding it inside the graphic. Clear the -bottom text.
1795         * platform/ios/WebCoreSystemInterfaceIOS.h: Add a new enum to obtain the placeholder
1796         text.
1797
1798 2015-05-19  Ryuan Choi  <ryuan.choi@navercorp.com>
1799
1800         [EFL] Use GSimpleProxyResolver instead of custom SoupProxyResolver
1801         https://bugs.webkit.org/show_bug.cgi?id=145154
1802
1803         Reviewed by Gyuyoung Kim.
1804
1805         SoupProxyResolver was deprecated since libsoup 2.42.
1806         So, this patch refactors the custom SoupProxyResolver to GSimpleProxyResolver
1807         which provides same functionality in gio.
1808
1809         No new tests, because there is not behavior change.
1810
1811         * PlatformEfl.cmake:
1812         * WebCore.vcxproj/WebCore.vcxproj:
1813         * WebCore.vcxproj/WebCore.vcxproj.filters:
1814         * platform/network/soup/ProxyResolverSoup.cpp: Removed.
1815         * platform/network/soup/ProxyResolverSoup.h: Removed.
1816         * platform/network/soup/SoupNetworkSession.cpp:
1817         (WebCore::SoupNetworkSession::setHTTPProxy): Moved to private member.
1818         (WebCore::SoupNetworkSession::httpProxy): Deleted because nobody calls it.
1819         * platform/network/soup/SoupNetworkSession.h:
1820
1821 2015-05-19  Commit Queue  <commit-queue@webkit.org>
1822
1823         Unreviewed, rolling out r184595.
1824         https://bugs.webkit.org/show_bug.cgi?id=145197
1825
1826         Introduced a crash in 15 layout tests on Mavericks on #webkit
1827         (Requested by rniwa on #webkit).
1828
1829         Reverted changeset:
1830
1831         "Media Controls stop updating after hovering for a few
1832         seconds."
1833         https://bugs.webkit.org/show_bug.cgi?id=144770
1834         http://trac.webkit.org/changeset/184595
1835
1836 2015-05-19  Carlos Alberto Lopez Perez  <clopez@igalia.com>
1837
1838         REGRESSION(r181571): Build broken when USE(OPENGL_ES_2) is defined.
1839         https://bugs.webkit.org/show_bug.cgi?id=145156
1840
1841         Reviewed by Alex Christensen.
1842
1843         No new tests, no behavior changes.
1844
1845         Vertex Array Objects are not available in OpenGLESv2.
1846         Add guards to avoid using this when building with GLESv2.
1847
1848         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
1849         (WebCore::GraphicsContext3D::createVertexArray):
1850         (WebCore::GraphicsContext3D::deleteVertexArray):
1851         (WebCore::GraphicsContext3D::isVertexArray):
1852         (WebCore::GraphicsContext3D::bindVertexArray):
1853
1854 2015-05-19  Roger Fong  <roger_fong@apple.com>
1855
1856         Upper half of volume control should be filled, not hollow.
1857         https://bugs.webkit.org/show_bug.cgi?id=145187.
1858         <rdar://problem/21021970>
1859
1860         Reviewed by Dean Jackson.
1861
1862         * Modules/mediacontrols/mediaControlsApple.js:
1863         (Controller.prototype.drawVolumeBackground):
1864
1865 2015-05-19  Michael Saboff  <msaboff@apple.com>
1866
1867         REGRESSION(183787): JIT is enabled for all builds
1868         https://bugs.webkit.org/show_bug.cgi?id=145179
1869
1870         Reviewed by Geoffrey Garen.
1871
1872         Eliminated the setting of ENABLE_JIT, as wtf/Platform.h has appropriate logic to
1873         set it depending on OS and CPU type.
1874
1875         Only changed the way build options are initialized.
1876
1877         * Configurations/FeatureDefines.xcconfig:
1878
1879 2015-05-19  Chris Dumez  <cdumez@apple.com>
1880
1881         [Mac] Font lookups are flakey due to caching
1882         https://bugs.webkit.org/show_bug.cgi?id=145180
1883         <rdar://problem/21012406>
1884
1885         Reviewed by Darin Adler.
1886
1887         Font lookups were flakey on Mac due to the cache in fontWithFamily().
1888         The reason is that the "desired family" to "available family" mapping
1889         is sometimes dependent on the desired traits. However, our cache was
1890         only using the "desired family" as key.
1891
1892         This patch now uses a std::pair as key containing both the "desired
1893         family" and the "desired traits" for correctness. I also updated the
1894         cache to use WTF types instead of NS types.
1895
1896         Test: platform/mac/fast/text/font-weights.html
1897
1898         * platform/graphics/mac/FontCacheMac.mm:
1899         (WebCore::desiredFamilyToAvailableFamilyMap):
1900         (WebCore::hasDesiredFamilyToAvailableFamilyMapping):
1901         (WebCore::rememberDesiredFamilyToAvailableFamilyMapping):
1902         (WebCore::fontWithFamily):
1903         (WebCore::invalidateFontCache):
1904         (WebCore::desiredFamilyToAvailableFamilyDictionary): Deleted.
1905
1906 2015-05-19  Brady Eidson  <beidson@apple.com>
1907
1908         X-Frame-Options headers not respected when loading from application cache.
1909         <rdar://problem/14877623> and https://bugs.webkit.org/show_bug.cgi?id=131800
1910
1911         Reviewed by Alexey Proskuryakov.
1912
1913         Test: http/tests/appcache/x-frame-options-prevents-framing.php
1914
1915         This patch updates SubstituteData to hold on to a ResourceResponse instead of just a URL.
1916         
1917         It also updates all users of SubstituteData to reflect this.
1918         
1919         Finally it updates ApplicationCacheHost to put the full response (including x-frame-options header)
1920         in the SubstituteData so they can be checked at the appropriate times.
1921         
1922         * loader/DocumentLoader.cpp:
1923         (WebCore::DocumentLoader::handleSubstituteDataLoadNow):
1924         (WebCore::DocumentLoader::responseReceived): Update an ASSERT to reflect that it's okay to not have
1925           a main resource as long as you have a substitute identifier for it.
1926         (WebCore::DocumentLoader::documentURL):
1927         (WebCore::DocumentLoader::contentFilterDidDecide):
1928         
1929         * loader/FrameLoader.cpp:
1930         (WebCore::FrameLoader::loadArchive):
1931         (WebCore::FrameLoader::defaultSubstituteDataForURL):
1932
1933         * loader/SubstituteData.h:
1934         (WebCore::SubstituteData::SubstituteData):
1935         (WebCore::SubstituteData::shouldRevealToSessionHistory):
1936         (WebCore::SubstituteData::mimeType):
1937         (WebCore::SubstituteData::textEncoding):
1938         (WebCore::SubstituteData::response):
1939         (WebCore::SubstituteData::responseURL): Deleted.
1940
1941         * loader/appcache/ApplicationCacheHost.cpp:
1942         (WebCore::ApplicationCacheHost::maybeLoadMainResource): Put the full ResourceResponse here, which 
1943           includes x-frame-options headers sent back when the resources was initially loaded from the network.
1944
1945         * platform/network/ResourceResponseBase.h:
1946
1947 2015-05-19  Brent Fulgham  <bfulgham@apple.com>
1948
1949         REGRESSION(142590): Part 2: Scroll-snap points are improperly snapping to earlier index values (Scrolling Thread) 
1950         https://bugs.webkit.org/show_bug.cgi?id=145175
1951         <rdar://problem/21023785>
1952
1953         Reviewed by Beth Dakin.
1954
1955         Extend the main-thread scrolling changes done in Bug 145140 to also handle Scrolling Thread snapping.
1956         The post-layout fixup (needed to handle window resize and device orientation changes) should not fire
1957         while Scrolling Thread scroll-snap animations are running, since these animations will most likely
1958         move the scroll view into the proper position. If we attempt to 'fix up' the scroll position before
1959         these animations finish, we get an ugly 'jump' in the display.
1960
1961         * page/FrameView.cpp:
1962         (WebCore::FrameView::isScrollSnapInProgress): New method based on isRubberBandInProgress, which considers
1963         both the ScrollAnimator (main thread) scrolling, as well as the ScrollingCoordinator (Scrolling Thread)
1964         scrolling operations. Returns true if a scroll-snap animation is still active.
1965         * page/FrameView.h:
1966         * page/scrolling/AsyncScrollingCoordinator.cpp:
1967         (WebCore::AsyncScrollingCoordinator::isScrollSnapInProgress): Added. Returns scrolling tree's
1968         'isScrollSnapInProgress' state.
1969         * page/scrolling/AsyncScrollingCoordinator.h:
1970         * page/scrolling/ScrollingCoordinator.h:
1971         (WebCore::ScrollingCoordinator::isScrollSnapInProgress): Added default 'false' stub.
1972         * page/scrolling/ScrollingTree.cpp:
1973         (WebCore::ScrollingTree::ScrollingTree): Use modern C++11 initializers.
1974         (WebCore::ScrollingTree::isScrollSnapInProgress): Added.
1975         (WebCore::ScrollingTree::setMainFrameIsScrollSnapping): Added.
1976         * page/scrolling/ScrollingTree.h:
1977         * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.h:
1978         * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm:
1979         (WebCore::ScrollingTreeFrameScrollingNodeMac::handleWheelEvent): Update scrolling tree state to match the
1980         ScrollController's scroll-snap state.
1981         (WebCore::ScrollingTreeFrameScrollingNodeMac::startScrollSnapTimer): Added. When starting a scroll snap timer,
1982         always set the scrolling tree scroll-snapping state to true.
1983         (WebCore::ScrollingTreeFrameScrollingNodeMac::stopScrollSnapTimer): Added. When ending a scroll snap timer,
1984         only set the scrolling tree scroll-snapping state to false if the other axis animator is inactive.
1985         * platform/ScrollableArea.cpp:
1986         (WebCore::ScrollableArea::updateScrollSnapState): Revise implementation to use its 'isScrollSnapInProgress'
1987         method, rather than only looking at the ScrollAnimator (main thread) state.
1988         * platform/ScrollableArea.h:
1989         (WebCore::ScrollableArea::isScrollSnapInProgress): Added.
1990         * platform/cocoa/ScrollController.h:
1991         * platform/cocoa/ScrollController.mm:
1992         (WebCore::ScrollController::hasActiveScrollSnapTimerForAxis): Added. Reports if the scroll snap animation
1993         timer on the requested axis is running or not.
1994         * rendering/RenderLayer.cpp:
1995         (WebCore::RenderLayer::isScrollSnapInProgress): Added.
1996         * rendering/RenderLayer.h:
1997
1998 2015-05-19  Roger Fong  <roger_fong@apple.com>
1999
2000         Media Controls stop updating after hovering for a few seconds.
2001         https://bugs.webkit.org/show_bug.cgi?id=144770.
2002         <rdar://problem/19823121>
2003
2004         Reviewed by Jer Noble.
2005
2006         * Modules/mediacontrols/mediaControlsApple.js:
2007         (Controller.prototype.createBase):
2008         We should never hide controls immediately as a result of mousing out of the controls.
2009         It should only happen when the mouse leaves the video entirely.
2010         (Controller.prototype.updateTimelineMetricsIfNeeded):
2011         Don’t update if controls are hidden, timeline dimensions will be 0.
2012         (Controller.prototype.handlePanelTransitionEnd): 
2013         Instead of adjusting visibility via adding and removing classes,
2014         remove controls entirely from the tree.
2015         (Controller.prototype.showControls):
2016         Add controls back into the tree when showing controls.
2017         (Controller.prototype.updateForShowingControls):
2018         Helper method for showControls.
2019         (Controller.prototype.controlsAreHidden):
2020         Controls also hidden if removed from tree.
2021
2022         Remove forceUpdate logic, no longer necessary.
2023         (Controller.prototype.handleDurationChange): 
2024         (Controller.prototype.updateProgress):
2025         (Controller.prototype.updateTime):
2026
2027         Override methods to use add and remove panelContainer for iOS.
2028         * Modules/mediacontrols/mediaControlsiOS.js:
2029         (ControllerIOS.prototype.handlePanelTransitionEnd):
2030         (ControllerIOS.prototype.showControls):
2031         (ControllerIOS.prototype.controlsAreHidden):
2032
2033 2015-05-19  Brent Fulgham  <bfulgham@apple.com>
2034
2035         Scroll-snap animations should not start on axes with zero-delta
2036         https://bugs.webkit.org/show_bug.cgi?id=145148
2037
2038         Reviewed by Dean Jackson.
2039
2040         Don't begin a scroll snap animation on an axis that had no change in position (on that axis)
2041         during the gesture.
2042
2043         * platform/cocoa/ScrollController.mm:
2044         (WebCore::ScrollController::processWheelEventForScrollSnapOnAxis): Don't begin a scroll snap
2045         animation if no movement on this axis was ever made.
2046
2047 2015-05-19  Youenn Fablet  <youenn.fablet@crf.canon.fr>
2048
2049         AudioContext should resolve promises with jsUndefined() and not jsNull()
2050         https://bugs.webkit.org/show_bug.cgi?id=145063
2051
2052         Reviewed by Sam Weinig.
2053
2054         Covered by updated test.
2055
2056         * bindings/js/JSDOMPromise.h:
2057         (WebCore::DeferredWrapper::resolve): resolving std::nullptr_t as jsUndefined() and not jsNull()
2058
2059 2015-05-19  Xabier Rodriguez Calvar  <calvaris@igalia.com> and Youenn Fablet <youenn.fablet@crf.canon.fr>
2060
2061         [Streams API] Migrate closed promise handling from ReadableStreamReader to ReadableStream
2062         https://bugs.webkit.org/show_bug.cgi?id=145110
2063
2064         Reviewed by Darin Adler.
2065
2066         Reader is now just checking whether it is the reader locking the stream or not.
2067         If not and stream is readable, it resolves the closed promise.
2068         Otherwise, it delegates the promise handling to its stream.
2069
2070         No change in behavior.
2071
2072         * Modules/streams/ReadableStream.cpp:
2073         (WebCore::ReadableStream::cleanCallbacks): Cleaning of closed callbacks.
2074         (WebCore::ReadableStream::changeStateToClosed): Resolving closed promise if set.
2075         (WebCore::ReadableStream::changeStateToErrored): Rejecting closed promise if set.
2076         (WebCore::ReadableStream::getReader): Removed reader state notification.
2077         (WebCore::ReadableStream::closed): Moved from reader to stream.
2078         * Modules/streams/ReadableStream.h:
2079         (WebCore::ReadableStream::reader): Added to allow reader to check whether it is locking its stream or not.
2080         (WebCore::ReadableStream::isReadable): Added as an improvement over internalState which is removed.
2081         (WebCore::ReadableStream::internalState): Deleted.
2082         * Modules/streams/ReadableStreamReader.cpp:
2083         (WebCore::ReadableStreamReader::closed):
2084         * Modules/streams/ReadableStreamReader.h: Removed state and closed promise callbacks.
2085         * bindings/js/JSReadableStreamControllerCustom.cpp:
2086         (WebCore::JSReadableStreamController::close): Refactoring of internalState to isReadable.
2087         (WebCore::JSReadableStreamController::error): Ditto.
2088         * bindings/js/JSReadableStreamReaderCustom.cpp:
2089         (WebCore::JSReadableStreamReader::closed): Refactoring to have the promise value as callback parameter.
2090
2091 2015-05-19  Jeremy Jones  <jeremyj@apple.com>
2092
2093         Remove use of deprecated AVKit SPI cancelOptimizedFullscreen.
2094         https://bugs.webkit.org/show_bug.cgi?id=145159
2095
2096         Reviewed by Eric Carlson.
2097
2098         Remove cancelOptimizedFullscreen, and use stopOptimizedFullscreen instead.
2099
2100         * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
2101         (WebVideoFullscreenInterfaceAVKit::cleanupFullscreenInternal):
2102         * platform/spi/cocoa/AVKitSPI.h: remove declaration.
2103
2104 2015-05-19  Zalan Bujtas  <zalan@apple.com>
2105
2106         Merged anonymous blocks should invalidate simple line layout path.
2107         https://bugs.webkit.org/show_bug.cgi?id=145104
2108         rdar://problem/20980930
2109
2110         Reviewed by Antti Koivisto.
2111
2112         When anonymous blocks are merged together, it's not guaranteed that the final block can use simple line layout.
2113         This patch ensures that the flow block, where the other block's content gets moved to, is no longer on simple line layout path.
2114         Whether the final flow block ends up using inline boxes or simple line layout will be determined during the next layout.
2115
2116         Test: fast/block/crash-when-anonymous-blocks-are-merged-with-simple-line-layout.html
2117
2118         * rendering/RenderElement.cpp:
2119         (WebCore::RenderElement::insertChildInternal):
2120
2121 2015-05-19  Beth Dakin  <bdakin@apple.com>
2122
2123         Crash in WebCore::RenderLayer::updateScrollbarsAfterLayout
2124         https://bugs.webkit.org/show_bug.cgi?id=145142
2125
2126         Reviewed by Simon Fraser.
2127
2128         I have not been able to reproduce this crash, but according to symbolication 
2129         m_vBar is null. It seems like this crash was probably caused by 
2130         http://trac.webkit.org/changeset/173668 which made it so that overflow:scroll 
2131         behaves like overflow:auto when the scrollbars are overlay. I can see how you 
2132         could encounter this crash with that change if the layout caused 
2133         styleRequiresScrollbar() to return true when it used to return false. Then this 
2134         code, by failing to null-check the scrollbars, assumes that 
2135         styleRequiresScrollbar() could not have changed based on a layout. But it could 
2136         change if the css changed the scrollbars to be custom or if the user managed 
2137         switch to legacy style scrollbars at just the wrong time. Or I suppose it could 
2138         also happen if the user has legacy scrollbars and the style switched from auto to 
2139         scroll during the layout.
2140
2141         Anyway, we should null-check  the scrollbars. This is a speculative fix.
2142         * rendering/RenderLayer.cpp:
2143         (WebCore::RenderLayer::updateScrollbarsAfterLayout):
2144
2145 2015-05-19  Hunseop Jeong  <hs85.jeong@samsung.com>
2146
2147         Use modern for-loops in WebCore/xml.
2148         https://bugs.webkit.org/show_bug.cgi?id=145046
2149
2150         Reviewed by Chris Dumez.
2151
2152         No new tests, no new tests.
2153
2154         * xml/XMLHttpRequest.cpp:
2155         (WebCore::XMLHttpRequest::uppercaseKnownHTTPMethod):
2156         * xml/XPathExpressionNode.cpp:
2157         (WebCore::XPath::Expression::setSubexpressions):
2158         * xml/XPathFunctions.cpp:
2159         (WebCore::XPath::FunSum::evaluate):
2160         (WebCore::XPath::populateFunctionMap):
2161         * xml/XPathNodeSet.cpp:
2162         (WebCore::XPath::NodeSet::traversalSort):
2163         * xml/XPathParser.cpp:
2164         (WebCore::XPath::populateAxisNamesMap):
2165         * xml/XPathPath.cpp:
2166         (WebCore::XPath::Filter::evaluate):
2167         (WebCore::XPath::LocationPath::evaluate):
2168         * xml/XPathPredicate.cpp:
2169         (WebCore::XPath::EqTestOp::compare):
2170         (WebCore::XPath::Union::evaluate):
2171         * xml/XPathStep.cpp:
2172         (WebCore::XPath::Step::optimize):
2173         (WebCore::XPath::Step::predicatesAreContextListInsensitive):
2174         (WebCore::XPath::Step::evaluate):
2175         (WebCore::XPath::nodeMatches):
2176         * xml/XSLStyleSheetLibxslt.cpp:
2177         (WebCore::XSLStyleSheet::~XSLStyleSheet):
2178         (WebCore::XSLStyleSheet::isLoading):
2179         (WebCore::XSLStyleSheet::clearDocuments):
2180         (WebCore::XSLStyleSheet::locateStylesheetSubResource):
2181         * xml/XSLTProcessorLibxslt.cpp:
2182         (WebCore::xsltParamArrayFromParameterMap):
2183
2184 2015-05-19  Jon Lee  <jonlee@apple.com>
2185
2186         Improve text rendering of placeholder
2187         https://bugs.webkit.org/show_bug.cgi?id=145135
2188
2189         Reviewed by Eric Carlson.
2190
2191         * Modules/mediacontrols/mediaControlsApple.css: The <p> elements of the wireless playback
2192         text are being popped out into separate layers, causing the text to render antialiased, which
2193         looks bad on non-retina machines. Explicitly set the background color (which is ok since the
2194         container element for the placeholder is also black). Also extend the height out 1pt to prevent
2195         clipping of descenders.
2196         (audio::-webkit-media-controls-wireless-playback-text-top): Set background color to black and add
2197         1 to the height.
2198         (audio::-webkit-media-controls-wireless-playback-text-bottom): Ditto.
2199
2200 2015-05-19  Jon Lee  <jonlee@apple.com>
2201
2202         [iOS] Current time display should be right-aligned
2203         https://bugs.webkit.org/show_bug.cgi?id=145163
2204         rdar://problem/21014339
2205
2206         Reviewed by Eric Carlson.
2207
2208         * Modules/mediacontrols/mediaControlsiOS.css: Use flex-start and flex-end
2209         instead of right and left, similar to the Mac controls.
2210         (video::-webkit-media-controls-current-time-display):
2211         (video::-webkit-media-controls-time-remaining-display):
2212
2213 2015-05-14  Chris Fleizach  <cfleizach@apple.com>
2214
2215         AX: Select text mechanism returns results outside of text control regions
2216         https://bugs.webkit.org/show_bug.cgi?id=145041
2217
2218         Reviewed by Mario Sanchez Prada.
2219
2220         The behavior of the select text mechanism (inside accessibility) should make sure that results
2221         returned stay within text control elements if the search was initiated inside a text control element.
2222
2223         Test: platform/mac/accessibility/select-text-stays-inside-text-controls.html
2224
2225         * accessibility/AccessibilityObject.cpp:
2226         (WebCore::rangeClosestToRange):
2227         (WebCore::AccessibilityObject::selectText):
2228
2229 2015-05-19  Chris Dumez  <cdumez@apple.com>
2230
2231         Mark static variables as const when possible
2232         https://bugs.webkit.org/show_bug.cgi?id=145161
2233
2234         Reviewed by Andreas Kling.
2235
2236         * Modules/mediasession/WebMediaSessionManager.cpp:
2237         * Modules/mediasource/SourceBuffer.cpp:
2238         * Modules/webdatabase/SQLException.cpp:
2239         * dom/DOMCoreException.cpp:
2240         * inspector/NetworkResourcesData.cpp:
2241         * loader/icon/IconDatabase.cpp:
2242         (WebCore::urlForLogging):
2243         * page/AutoscrollController.cpp:
2244         * page/Page.cpp:
2245         * platform/RuntimeApplicationChecksIOS.mm:
2246         (WebCore::applicationIsAdSheet):
2247         (WebCore::applicationIsMobileMail):
2248         (WebCore::applicationIsMobileSafari):
2249         (WebCore::applicationIsDumpRenderTree):
2250         (WebCore::applicationIsWebApp):
2251         (WebCore::applicationIsOkCupid):
2252         (WebCore::applicationIsFacebook):
2253         (WebCore::applicationIsEpicurious):
2254         (WebCore::applicationIsDaijisenDictionary):
2255         (WebCore::applicationIsNASAHD):
2256         (WebCore::applicationIsMASH):
2257         (WebCore::applicationIsTheEconomistOnIPhone):
2258         (WebCore::applicationIsWebProcess):
2259         (WebCore::applicationIsIBooksOnIOS):
2260         * platform/audio/HRTFElevation.cpp:
2261         * platform/audio/mac/AudioHardwareListenerMac.cpp:
2262         (WebCore::processIsRunningPropertyDescriptor):
2263         (WebCore::outputDevicePropertyDescriptor):
2264         * platform/graphics/avfoundation/AudioSourceProviderAVFObjC.mm:
2265         * platform/graphics/ca/GraphicsLayerCA.cpp:
2266         * platform/graphics/mac/FontCacheMac.mm:
2267         (WebCore::toCoreTextFontWeight):
2268         (WebCore::toAppKitFontWeight):
2269         (WebCore::toNSFontWeight):
2270         * platform/mac/ScrollAnimatorMac.mm:
2271         (supportsUIStateTransitionProgress):
2272         (supportsExpansionTransitionProgress):
2273         (supportsContentAreaScrolledInDirection):
2274         * platform/mac/ScrollbarThemeMac.mm:
2275         * platform/mac/WebCoreNSURLExtras.mm:
2276         (WebCore::dataForURLComponentType):
2277         * platform/mock/ScrollbarThemeMock.cpp:
2278         * platform/text/icu/UTextProviderLatin1.cpp:
2279         * platform/text/ios/LocalizedDateCache.mm:
2280         (WebCore::LocalizedDateCache::calculateMaximumWidth):
2281         * rendering/RenderBlockLineLayout.cpp:
2282         (WebCore::RenderBlockFlow::matchedEndLine):
2283         * rendering/RenderBoxModelObject.cpp:
2284         (WebCore::RenderBoxModelObject::paintTranslucentBorderSides):
2285         * rendering/RenderFrameBase.cpp:
2286         (WebCore::shouldExpandFrame):
2287         * rendering/RenderTableSection.cpp:
2288         * rendering/RenderThemeIOS.mm:
2289         (WebCore::getInsetGradient):
2290         (WebCore::getShineGradient):
2291         (WebCore::getShadeGradient):
2292         (WebCore::getConvexGradient):
2293         (WebCore::getConcaveGradient):
2294         (WebCore::getSliderTrackGradient):
2295         (WebCore::getReadonlySliderTrackGradient):
2296         (WebCore::getSliderThumbOpaquePressedGradient):
2297         (WebCore::RenderThemeIOS::paintCheckboxDecorations):
2298         (WebCore::RenderThemeIOS::paintRadioDecorations):
2299         * rendering/RenderThemeMac.mm:
2300         (WebCore::toFontWeight):
2301         (WebCore::TopGradientInterpolate):
2302         (WebCore::BottomGradientInterpolate):
2303         (WebCore::MainGradientInterpolate):
2304         (WebCore::TrackGradientInterpolate):
2305
2306 2015-05-18  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
2307
2308         Use Ref instead of PassRefPtr in WebCore/bindings
2309         https://bugs.webkit.org/show_bug.cgi?id=144981
2310
2311         Reviewed by Darin Adler.
2312
2313         As a step to purge PassRefPtr, remove PassRefPtr in WebCore/bindings.
2314
2315         No new tests, no behavior changes.
2316
2317         * bindings/gobject/GObjectNodeFilterCondition.h:
2318         (WebCore::GObjectNodeFilterCondition::create):
2319         * bindings/gobject/GObjectXPathNSResolver.h:
2320         (WebCore::GObjectXPathNSResolver::create):
2321         * bindings/js/JSCustomXPathNSResolver.cpp:
2322         (WebCore::JSCustomXPathNSResolver::create):
2323         * bindings/js/JSCustomXPathNSResolver.h:
2324         * bindings/js/JSDOMGlobalObjectTask.cpp:
2325         * bindings/js/JSErrorHandler.h:
2326         (WebCore::JSErrorHandler::create):
2327         * bindings/js/JSLazyEventListener.cpp:
2328         (WebCore::JSLazyEventListener::createForNode):
2329         (WebCore::JSLazyEventListener::createForDOMWindow):
2330         * bindings/js/JSLazyEventListener.h:
2331         * bindings/js/JSMutationCallback.h:
2332         (WebCore::JSMutationCallback::create):
2333         * bindings/js/JSNodeFilterCondition.h:
2334         (WebCore::JSNodeFilterCondition::create):
2335         * bindings/js/SerializedScriptValue.cpp:
2336         (WebCore::SerializedScriptValue::create):
2337         (WebCore::SerializedScriptValue::numberValue):
2338         (WebCore::SerializedScriptValue::undefinedValue):
2339         (WebCore::SerializedScriptValue::nullValue):
2340         * bindings/js/SerializedScriptValue.h:
2341         * bindings/objc/ObjCEventListener.h:
2342         * bindings/objc/ObjCEventListener.mm:
2343         (WebCore::ObjCEventListener::wrap):
2344         * bindings/objc/ObjCNodeFilterCondition.h:
2345         (WebCore::ObjCNodeFilterCondition::create):
2346
2347 2015-05-18  Csaba Osztrogonác  <ossy@webkit.org>
2348
2349         Fix uninitialized warnings in RealtimeMediaSourceCenterOwr.cpp
2350         https://bugs.webkit.org/show_bug.cgi?id=145119
2351
2352         Reviewed by Gyuyoung Kim.
2353
2354         * platform/mediastream/openwebrtc/RealtimeMediaSourceCenterOwr.cpp:
2355         (WebCore::RealtimeMediaSourceCenterOwr::validateRequestConstraints):
2356         (WebCore::RealtimeMediaSourceCenterOwr::mediaSourcesAvailable):
2357
2358 2015-05-18  Michael Catanzaro  <mcatanzaro@igalia.com>
2359
2360         [CMake] Ignore warnings in system headers
2361         https://bugs.webkit.org/show_bug.cgi?id=144747
2362
2363         Reviewed by Darin Adler.
2364
2365         Separate include directories into WebKit project includes and system includes. Suppress all
2366         warnings from headers in system include directories using the SYSTEM argument to
2367         the include_directories command.
2368
2369         * CMakeLists.txt:
2370         * PlatformEfl.cmake:
2371         * PlatformGTK.cmake:
2372         * PlatformMac.cmake:
2373
2374 2015-05-18  Myles C. Maxfield  <mmaxfield@apple.com>
2375
2376         Addressing post-review comments on r184353
2377         https://bugs.webkit.org/show_bug.cgi?id=145146
2378
2379         Reviewed by Benjamin Poulain.
2380
2381         See per-file comments.
2382
2383         No new tests because there is no behavior change.
2384
2385         * platform/graphics/mac/FontCacheMac.mm:
2386         (WebCore::fontWithFamilySpecialCase): Use equalIgnoringASCIICase() AtomicString overload.
2387         * rendering/RenderThemeMac.mm:
2388         (WebCore::RenderThemeMac::updateCachedSystemFontDescription): Implement Ben's ideas for
2389         cheaply constructing AtomicStrings only when necessary.
2390
2391 2015-05-18  Skachkov Alexandr  <gskachkov@gmail.com>
2392
2393         [ES6] Arrow function syntax. Feature flag for arrow function
2394         https://bugs.webkit.org/show_bug.cgi?id=145108
2395
2396         Reviewed by Ryosuke Niwa.
2397
2398         Added feature flag ENABLE_ES6_ARROWFUNCTION_SYNTAX for arrow function
2399
2400         * Configurations/FeatureDefines.xcconfig:
2401
2402 2015-05-18  Brent Fulgham  <bfulgham@apple.com>
2403
2404         REGRESSION(142590): Scroll-snap points are improperly snapping to earlier index values
2405         https://bugs.webkit.org/show_bug.cgi?id=145140
2406         <rdar://problem/21006738>
2407
2408         Reviewed by Beth Dakin.
2409
2410         The new "nearestActiveSnapPoint" logic is firing while scroll snap animations are running. We need
2411         to add an "isScrollSnapInProgress" predicate, much like the existing "isRubberBandInProgress" to avoid
2412         certain "fix-up" logic that we don't want running while we are in the process of moving to a new position.
2413
2414         * platform/ScrollAnimator.h:
2415         (WebCore::ScrollAnimator::ScrollAnimator::isScrollSnapInProgress): Added.
2416         * platform/ScrollableArea.cpp:
2417         (WebCore::ScrollableArea::updateScrollSnapState): If we are in the midst of a scroll snap operation,
2418         do not attempt to reset position to the current active snap point.
2419         * platform/cocoa/ScrollController.h:
2420         * platform/cocoa/ScrollController.mm:
2421         (WebCore::ScrollController::isScrollSnapInProgress): Added.
2422         * platform/mac/ScrollAnimatorMac.h:
2423         * platform/mac/ScrollAnimatorMac.mm:
2424         (WebCore::ScrollAnimatorMac::isScrollSnapInProgress): Added.
2425
2426 2015-05-17  Manuel Rego Casasnovas  <rego@igalia.com>
2427
2428         [CSS Grid Layout] Add scrollbar width in intrinsic logical widths computation
2429         https://bugs.webkit.org/show_bug.cgi?id=145021
2430
2431         Like for flexboxes we've to take into account the scrollbar logical
2432         width while computing the intrinsic min and max logical widths.
2433
2434         Reviewed by Sergio Villar Senin.
2435
2436         Test: fast/css-grid-layout/compute-intrinsic-widths-scrollbar.html
2437
2438         * rendering/RenderGrid.cpp:
2439         (WebCore::RenderGrid::computeIntrinsicLogicalWidths): Add scrollbar
2440         logical width.
2441
2442 2015-05-17  Xabier Rodriguez Calvar  <calvaris@igalia.com> and Youenn Fablet <youenn.fablet@crf.canon.fr>
2443
2444         [Streams API] Delegate ReadableStreamReader reference counting to ReadableStream
2445         https://bugs.webkit.org/show_bug.cgi?id=144907
2446
2447         Reviewed by Darin Adler.
2448
2449         Changed the link between readadable stream and reader.
2450         Controller ref()/deref() now increments/decrements its stream ref counter, similarly to ReadableStreamController.
2451         This ensures that even if JS scripts do not keep track of the readable stream,
2452         the readable stream will not be disposed as long as the JS script has access to its reader.
2453
2454         All readers of a given stream are kept by the stream, either in an array (for released readers) 
2455         or and in ReadableStream::m_reader for the active reader.
2456         This removes the need for the code synchronizing stream and reader.
2457
2458         As a reader can now already count on its stream, the reader no longer needs to store the error in errored state.
2459         Removal of ReadableJSStream::Reader as closed promise rejection error is directly retrieved from the ReadableStream.
2460         Moved the creation of reader directly in ReadableStream.
2461
2462         Next step should be to remove ReadableStreamReader::m_state and to delegate the handling of ReadableStreamReader closed promise callbacks to ReadableStream.
2463
2464         No change in behavior.
2465
2466         * Modules/streams/ReadableStream.cpp:
2467         (WebCore::ReadableStream::changeStateToClosed):
2468         (WebCore::ReadableStream::changeStateToErrored):
2469         (WebCore::ReadableStream::getReader):
2470         * Modules/streams/ReadableStream.h:
2471         (WebCore::ReadableStream::reader):
2472         * Modules/streams/ReadableStreamReader.cpp:
2473         (WebCore::ReadableStreamReader::clean):
2474         (WebCore::ReadableStreamReader::ref):
2475         (WebCore::ReadableStreamReader::deref):
2476         (WebCore::ReadableStreamReader::closed):
2477         (WebCore::ReadableStreamReader::changeStateToClosed):
2478         (WebCore::ReadableStreamReader::changeStateToErrored):
2479         * Modules/streams/ReadableStreamReader.h:
2480         (WebCore::ReadableStreamReader::ReadableStreamReader):
2481         * Modules/streams/ReadableStreamReader.idl:
2482         * bindings/js/JSReadableStreamCustom.cpp:
2483         (WebCore::JSReadableStream::getReader):
2484         * bindings/js/JSReadableStreamReaderCustom.cpp:
2485         (WebCore::JSReadableStreamReader::closed):
2486         (WebCore::constructJSReadableStreamReader):
2487         * bindings/js/ReadableJSStream.cpp:
2488         (WebCore::ReadableJSStream::storeError):
2489         (WebCore::ReadableJSStream::ReadableJSStream): Deleted.
2490         * bindings/js/ReadableJSStream.h:
2491
2492 2015-05-17  Alexey Proskuryakov  <ap@apple.com>
2493
2494         Crash when uploading huge files to YouTube or Google Drive
2495         https://bugs.webkit.org/show_bug.cgi?id=145083
2496         rdar://problem/15468529
2497
2498         Reviewed by Darin Adler.
2499
2500         This fixes the crash, but uploading will fail.
2501
2502         * fileapi/FileReaderLoader.cpp:
2503         (WebCore::FileReaderLoader::start): Tell SubresourceLoader to not store a copy of
2504         all received data, FileReaderLoader has its own buffer.
2505         (WebCore::FileReaderLoader::didReceiveResponse): Fixed a bounds check - not every
2506         64-bit value that doesn't fit into 32 bits is negative. With this, FileReader fails
2507         on huge files right away, as intended.
2508         (WebCore::FileReaderLoader::didReceiveData): Fixed multiple bugs in code that's
2509         executed when size is not available upfront. This is the code that used to crash,
2510         but with the above fix, it's not executed by YouTube.
2511         Not only overflow was handled incorrectly, but even simply growing a buffer for
2512         append was buggy.
2513
2514 2015-05-16  Zalan Bujtas  <zalan@apple.com>
2515
2516         REGRESSION (Subpixel): Dashed underline is missing when box is positioned at subpixels.
2517         https://bugs.webkit.org/show_bug.cgi?id=145097
2518         rdar://problem/18588415
2519
2520         Reviewed by Simon Fraser.
2521
2522         Dashed and dotted border painting needs clipping in order to properly display corners.
2523         Similarly to solid border's quad calculation, we pixelsnap the border positions before computing the clipping quad values.
2524
2525         Test: fast/borders/dashed-border-on-subpixel-position.html
2526               fast/borders/dotted-border-on-subpixel-position.html
2527
2528         * rendering/RenderBoxModelObject.cpp:
2529         (WebCore::RenderBoxModelObject::clipBorderSidePolygon):
2530
2531 2015-05-16  Sungmann Cho  <sungmann.cho@navercorp.com>
2532
2533         Remove styleText() and applyStyleText() from InspectorStyle.
2534         https://bugs.webkit.org/show_bug.cgi?id=145093
2535
2536         Reviewed by Darin Adler.
2537
2538         styleText() and applyStyleText() in InspectorStyle are private aliases for the public
2539         accessors in the same class but are rarely used. I think it would be better off removing
2540         these aliases and updating all the current call sites to use the public accessors directly
2541         as noted in InspectorStyleSheet.h.
2542
2543         No new tests, no behavior change.
2544
2545         * inspector/InspectorStyleSheet.cpp:
2546         (WebCore::InspectorStyle::populateAllProperties):
2547         * inspector/InspectorStyleSheet.h:
2548
2549 2015-05-16  Sungmann Cho  <sungmann.cho@navercorp.com>
2550
2551         Remove MessageType variant of addMessageToConsole() from ChromeClient.
2552         https://bugs.webkit.org/show_bug.cgi?id=145095
2553
2554         Reviewed by Darin Adler.
2555
2556         All addMessageToConsole() in ChromeClient are exactly the same thing.
2557         So there is no reason to keep all this methods.
2558
2559         No new tests, no behavior change.
2560
2561         * page/ChromeClient.h:
2562         * page/PageConsoleClient.cpp:
2563         (WebCore::PageConsoleClient::messageWithTypeAndLevel):
2564
2565 2015-05-15  Sam Weinig  <sam@webkit.org>
2566
2567         Add getElementById to DocumentFragment
2568         https://bugs.webkit.org/show_bug.cgi?id=145094
2569
2570         Reviewed by Alexey Proskuryakov.
2571
2572         Match the latest DOM standard and other browsers by adding getElementById
2573         to DocumentFragment in addition to Document and SVGSVGElement. Add NonElementParentNode
2574         interface that the DOM standard defines.
2575
2576         Test: fast/dom/DocumentFragment/getElementById.html
2577
2578         * DerivedSources.make:
2579         * WebCore.xcodeproj/project.pbxproj:
2580         Add NonElementParentNode.idl
2581
2582         * dom/Document.idl:
2583         Mark Document as implementing NonElementParentNode and remove now redundant getElementById
2584         declaration.
2585
2586         * dom/DocumentFragment.cpp:
2587         (WebCore::DocumentFragment::getElementById):
2588         * dom/DocumentFragment.h:
2589         Add implementation of getElementById for DocumentFragments. Add a fast path for ShadowRoots
2590         which can take advantage of the fact that they are TreeScopes to use the elements by id cache
2591         in TreeScrope.
2592
2593         * dom/DocumentFragment.idl:
2594         Mark DocumentFragment as implementing NonElementParentNode.
2595
2596         * dom/NonElementParentNode.idl: Copied from Source/WebCore/dom/NonDocumentTypeChildNode.idl.
2597         Added.
2598
2599         * svg/SVGSVGElement.cpp:
2600         (WebCore::SVGSVGElement::getElementById):
2601         * svg/SVGSVGElement.h:
2602         * svg/SVGSVGElement.idl:
2603         Convert to taking an AtomicString to match other getElementByIds.
2604
2605 2015-05-15  Antti Koivisto  <antti@apple.com>
2606
2607         When redirecting to data URL use HTTP response for same origin policy checks
2608         https://bugs.webkit.org/show_bug.cgi?id=145054
2609         rdar://problem/20299050
2610
2611         Reviewed by Alexey Proskuryakov.
2612
2613         Test: http/tests/security/canvas-remote-read-data-url-image-redirect.html
2614
2615         * dom/ScriptElement.cpp:
2616         (WebCore::ScriptElement::notifyFinished):
2617         * dom/ScriptExecutionContext.cpp:
2618         (WebCore::ScriptExecutionContext::sanitizeScriptError):
2619         * html/canvas/CanvasRenderingContext.cpp:
2620         (WebCore::CanvasRenderingContext::wouldTaintOrigin):
2621         * loader/ImageLoader.cpp:
2622         (WebCore::ImageLoader::notifyFinished):
2623         * loader/MediaResourceLoader.cpp:
2624         (WebCore::MediaResourceLoader::responseReceived):
2625         * loader/TextTrackLoader.cpp:
2626         (WebCore::TextTrackLoader::notifyFinished):
2627         * loader/cache/CachedImage.cpp:
2628         (WebCore::CachedImage::isOriginClean):
2629         * loader/cache/CachedResource.cpp:
2630         (WebCore::CachedResource::passesAccessControlCheck):
2631         (WebCore::CachedResource::passesSameOriginPolicyCheck):
2632
2633             Factor repeatedly used same origin policy test into a function.
2634
2635         (WebCore::CachedResource::redirectReceived):
2636
2637             When redirecting to a data URL save the redirect response.
2638
2639         (WebCore::CachedResource::responseForSameOriginPolicyChecks):
2640
2641             In case we got redirected to data use that response instead of the final data response for policy checks.
2642
2643         * loader/cache/CachedResource.h:
2644
2645 2015-05-16  Jon Lee  <jonlee@apple.com>
2646
2647         [iOS] wireless playback picker button is drawn incorrectly
2648         https://bugs.webkit.org/show_bug.cgi?id=145057
2649         rdar://problem/20877518
2650
2651         Reviewed by Jer Noble.
2652
2653         * Modules/mediacontrols/mediaControlsiOS.js:
2654         (ControllerIOS.prototype.updateWirelessTargetPickerButton): This method is
2655         defined in Controller, but is only meant to run on Macs. Override it with
2656         an empty function for iOS.
2657
2658 2015-05-15  Simon Fraser  <simon.fraser@apple.com>
2659
2660         REGRESSION (r183300): Background missing on top links on apple.com
2661         https://bugs.webkit.org/show_bug.cgi?id=145079
2662         rdar://problem/20914252
2663
2664         Reviewed by Tim Horton.
2665         
2666         Re-land r184421 with a fix to check against rects.coverageRect
2667         rather than the stale m_coverageRect.
2668
2669         Test: compositing/visible-rect/backing-change-height-from-zero.html
2670
2671         * platform/graphics/ca/GraphicsLayerCA.cpp:
2672         (WebCore::GraphicsLayerCA::setVisibleAndCoverageRects):
2673         * rendering/RenderLayerBacking.cpp:
2674         (WebCore::RenderLayerBacking::shouldSkipLayerInDump):
2675
2676 2015-05-15  Matt Baker  <mattbaker@apple.com>
2677
2678         Web Inspector: REGRESSION (r181625): Timeline recording started from console.profile is always empty
2679         https://bugs.webkit.org/show_bug.cgi?id=144882
2680
2681         Reviewed by Joseph Pecoraro.
2682
2683         A timeline recording will always be stopped before the end of the current run loop is observed. Before
2684         dispatching the recording stopped event, any events that are currently in progress should be considered
2685         complete and sent to the frontend.
2686
2687         * inspector/InspectorTimelineAgent.cpp:
2688         (WebCore::InspectorTimelineAgent::internalStop):
2689
2690 2015-05-15  Commit Queue  <commit-queue@webkit.org>
2691
2692         Unreviewed, rolling out r184421.
2693         https://bugs.webkit.org/show_bug.cgi?id=145087
2694
2695         Introduced 42 layout test failures (Requested by rniwa on
2696         #webkit).
2697
2698         Reverted changeset:
2699
2700         "REGRESSION (r183300): Background missing on top links on
2701         apple.com"
2702         https://bugs.webkit.org/show_bug.cgi?id=145079
2703         http://trac.webkit.org/changeset/184421
2704
2705 2015-05-15  Simon Fraser  <simon.fraser@apple.com>
2706
2707         REGRESSION (r183300): Background missing on top links on apple.com
2708         https://bugs.webkit.org/show_bug.cgi?id=145079
2709         rdar://problem/20914252
2710
2711         Reviewed by Tim Horton.
2712
2713         GraphicsLayerCA::setVisibleAndCoverageRects() only set the m_intersectsCoverageRect
2714         flag if the coverage rect changed, but it doesn't if you simply change the size of
2715         the layer.
2716
2717         Instead, always re-evaluate the intersection, and set the CoverageRectChanged bit
2718         if it changes.
2719
2720         Test: compositing/visible-rect/backing-change-height-from-zero.html
2721
2722         * platform/graphics/ca/GraphicsLayerCA.cpp:
2723         (WebCore::GraphicsLayerCA::setVisibleAndCoverageRects):
2724         * rendering/RenderLayerBacking.cpp:
2725         (WebCore::RenderLayerBacking::shouldSkipLayerInDump): Don't skip any layers in a
2726         debug layer dump, to assist debugging.
2727
2728 2015-05-15  Sam Weinig  <sam@webkit.org>
2729
2730         Move HTMLElement's children property to ParentNode
2731         https://bugs.webkit.org/show_bug.cgi?id=145072
2732
2733         Reviewed by Chris Dumez.
2734
2735         Match the latest DOM standard and other browsers by moving the children property
2736         to ParentNode, thus exposing it on Element, Document and DocumentFragment.
2737
2738         Test: fast/dom/ParentNode-children.html
2739
2740         * dom/ContainerNode.cpp:
2741         (WebCore::ContainerNode::children):
2742         Moved implementation from HTMLElement to here.
2743
2744         (WebCore::ContainerNode::ensureCachedHTMLCollection):
2745         (WebCore::ContainerNode::cachedHTMLCollection):
2746         Moved implementation from Element to here so that ContainerNode::children
2747         can use it.
2748
2749         (WebCore::ContainerNode::firstElementChild):
2750         (WebCore::ContainerNode::lastElementChild):
2751         (WebCore::ContainerNode::childElementCount):
2752         Remove unnecessary assertions.
2753
2754         * dom/ContainerNode.h:
2755         Moved declarations from HTMLElement and Element to here.
2756
2757         * dom/Element.cpp:
2758         (WebCore::Element::ensureCachedHTMLCollection): Deleted.
2759         (WebCore::Element::cachedHTMLCollection): Deleted.
2760         * dom/Element.h:
2761         Moved to ContainerNode.
2762
2763         * dom/Node.cpp:
2764         (WebCore::Node::previousElementSibling):
2765         (WebCore::Node::nextElementSibling):
2766         Remove unnecessary assertions.
2767
2768         * dom/ParentNode.idl:
2769         Moved the children property here from HTMLElement.
2770
2771         * html/HTMLElement.cpp:
2772         (WebCore::HTMLElement::children): Deleted.
2773         * html/HTMLElement.h:
2774         Moved to ContainerNode.
2775
2776         * html/HTMLElement.idl:
2777         Get rid of the children property for all bindings except Objective-C which needs
2778         to keep it to avoid changing the public API.
2779
2780 2015-05-15  Zalan Bujtas  <zalan@apple.com>
2781
2782         WebCore ASan debug build fails. ERROR: WebCore has a weak external symbol in it.
2783         https://bugs.webkit.org/show_bug.cgi?id=145070
2784
2785         Reviewed by David Kilzer.
2786
2787         Build fix.
2788
2789         * Configurations/WebCore.unexp:
2790
2791 2015-05-15  Beth Dakin  <bdakin@apple.com>
2792
2793         Prefix force on MouseEvent and add constants for click and force click values
2794         https://bugs.webkit.org/show_bug.cgi?id=145065
2795         -and corresponding-
2796         rdar://problem/20770052
2797
2798         Reviewed by Tim Horton.
2799
2800         (WebCore::MouseEvent::webkitForce):
2801         * dom/MouseEvent.idl:
2802
2803 2015-05-15  Jer Noble  <jer.noble@apple.com>
2804
2805         [MediaControls] Refactor media controls & bring improvements made to iOS controls to Mac.
2806         https://bugs.webkit.org/show_bug.cgi?id=144973
2807
2808         Reviewed by Dean Jackson.
2809
2810         Pull improvements made to the iOS media controls back into the Mac controls by moving
2811         code from mediaControlsiOS.js into MediaControlsApple.js.
2812
2813         The largest refactored feature is the ability to drop individual controls from the media
2814         controls when the video is too small to contain them. To allow these controls to resize
2815         dynamically, a new "resize" event is fired inside the media element's shadow DOM.
2816
2817         * Modules/mediacontrols/mediaControlsApple.css:
2818         (audio::-webkit-media-controls-panel .dropped): Added; sets "display: none".
2819         * Modules/mediacontrols/mediaControlsApple.js:
2820         (Controller): Set defaults for new variables.
2821         (Controller.prototype.updateControls): Update the controls width; moved from iOS.js.
2822         (Controller.prototype.handleReadyStateChange): Update the controls; moved from iOS.js.
2823         (Controller.prototype.handleTimeUpdate): Update the progress; moved from iOS.js.
2824         (Controller.prototype.handleTimelineInput): Pause if scrubbing; moved from iOS.js.
2825         (Controller.prototype.handleTimelineChange): Update the progress; moved from iOS.js.
2826         (Controller.prototype.showControls): Update the controls width; moved from iOS.js.
2827         (Controller.prototype.hideControls): Removed _potentiallyScrubbing check; not needed due to changes
2828             to controlsAlwaysVisible().
2829         (Controller.prototype.scheduleUpdateLayoutForDisplayedWidth): Moved from iOS.js.
2830         (Controller.prototype.isControlVisible): Added; checks whether control is parented & not hidden.
2831         (Controller.prototype.updateLayoutForDisplayedWidth): Moved from iOS.js and refactored.
2832         (Controller.prototype.controlsAlwaysVisible): Return true if scrubbing.
2833         (Controller.prototype.updateHasAudio): Check currentPlaybackTargetIsWireless(); moved from iOS.js.
2834         (Controller.prototype.get scrubbing): Simple getter for _scrubbing.
2835         (Controller.prototype.set scrubbing): Check play state if scrubbing; start playback (if necessary)
2836             if not scrubbing.
2837         (Controller.prototype.get pageScaleFactor): Moved from iOS.js.
2838         (Controller.prototype.set pageScaleFactor): Ditto.
2839         (Controller.prototype.handleRootResize): Schedule an update of the contrtols width.
2840
2841         Remove a bunch of newly unnecessary code from the iOS media controls:
2842
2843         * Modules/mediacontrols/mediaControlsiOS.js:
2844         (ControllerIOS):
2845         (ControllerIOS.prototype.createControls): Remove ivars moved into Apple.js.
2846         (ControllerIOS.prototype.configureInlineControls): Remove spacer; made unnecessary.
2847         (ControllerIOS.prototype.showControls): Deleted.
2848         (ControllerIOS.prototype.updateTime): Deleted.
2849         (ControllerIOS.prototype.handleTimelineTouchStart): Just call "scrubbing = true", handled in Apple.js.
2850         (ControllerIOS.prototype.handleTimelineTouchEnd): Just call "scrubbing = false", handled in Apple.js.
2851         (ControllerIOS.prototype.handleReadyStateChange): Deleted.
2852         (ControllerIOS.prototype.setPlaying): Don't check _timelineIsHidden; not needed.
2853         (ControllerIOS.prototype.get pageScaleFactor): Deleted.
2854         (ControllerIOS.prototype.set pageScaleFactor): Deleted.
2855         (ControllerIOS.prototype.scheduleUpdateLayoutForDisplayedWidth): Deleted.
2856         (ControllerIOS.prototypeupdateLayoutForDisplayedWidth): Deleted.
2857
2858         Fire a "resize" event at the shadow DOM root when layout results in a size change.
2859
2860         * html/HTMLMediaElement.cpp:
2861         (WebCore::HTMLMediaElement::layoutSizeChanged): Fire the "resize" event at the shadow DOM.
2862         * html/HTMLMediaElement.h:
2863         * rendering/RenderMedia.cpp:
2864         (WebCore::RenderMedia::layout): Trigger layoutSizeChanged()
2865         * rendering/RenderMedia.h:
2866
2867         Drive-by fixes:
2868
2869         * Modules/mediacontrols/mediaControlsApple.js:
2870         (Controller.prototype.createControls): aria-label text is totally wrong; removed.
2871         (Controller.prototype.updateWirelessPlaybackStatus): Use class-names to hide controls, not inline styles.
2872
2873 2015-05-15  Alex Christensen  <achristensen@webkit.org>
2874
2875         [Content Extensions] Fail to load old content extension files
2876         https://bugs.webkit.org/show_bug.cgi?id=145027
2877
2878         Reviewed by Eric Carlson.
2879
2880         * contentextensions/DFABytecode.h:
2881
2882 2015-05-15  Eric Carlson  <eric.carlson@apple.com>
2883
2884         Unreviewed build fix.
2885
2886         * platform/ios/WebVideoFullscreenInterfaceAVKit.mm: Add clang pragmas to ignore
2887         deprecation warnings.
2888
2889 2015-05-15  Jeremy Jones  <jeremyj@apple.com>
2890
2891         Limit alternate fullscreen with linked on or after.
2892         https://bugs.webkit.org/show_bug.cgi?id=144894
2893
2894         Reviewed by Dean Jackson.
2895
2896         * platform/ios/WebCoreSystemInterfaceIOS.h: add new wkIOSSystemVersion
2897
2898 2015-05-15  Roger Fong  <roger_fong@apple.com>
2899
2900         Unreviewed. Revert part of r184361.
2901
2902         * Modules/mediacontrols/mediaControlsApple.js:
2903         (Controller.prototype.configureInlineControls):
2904         HI wants the buttons flipped.
2905
2906 2015-05-15  Sungmann Cho  <sungmann.cho@navercorp.com>
2907
2908         Fix trivial typo in TextEncodingDetectorICU.cpp.
2909         https://bugs.webkit.org/show_bug.cgi?id=145055
2910
2911         Reviewed by Alexey Proskuryakov.
2912
2913         No new tests, no behavior change..
2914
2915         * platform/text/TextEncodingDetectorICU.cpp:
2916         (WebCore::detectTextEncoding):
2917
2918 2015-05-15  Alexey Proskuryakov  <ap@apple.com>
2919
2920         Cyrillic top-level domains are displayed as punycode
2921         https://bugs.webkit.org/show_bug.cgi?id=145024
2922         rdar://problem/17747133
2923         rdar://problem/14116594
2924
2925         Reviewed by Tim Horton.
2926
2927         Handling each TLD in code is annoying, but we can probably survive like this
2928         for a few more years, and maybe we'll think of an entirely different way to deal
2929         with non-ASCII domain labels in the meanwhile.
2930
2931         * platform/mac/WebCoreNSURLExtras.mm:
2932         (WebCore::isSecondLevelDomainNameAllowedByTLDRules):
2933         (WebCore::allCharactersAllowedByTLDRules):
2934
2935 2015-05-15  Roger Fong  <roger_fong@apple.com>
2936
2937         Cursor is displayed after full screen video controls fade away.
2938         https://bugs.webkit.org/show_bug.cgi?id=145034.
2939         <rdar://problem/20458604>
2940
2941         Reviewed by Jer Noble.
2942
2943         * Modules/mediacontrols/mediaControlsApple.css:
2944         (video::-webkit-media-controls-panel):
2945         Unnecessary cursor style is on the control panel while hidden but
2946         the cursor will already be hidden anyways from being auto-hidden.
2947         Causes style to change when controls are hidden,
2948         which causes the cursor to reappear.
2949
2950 2015-05-15  Roger Fong  <roger_fong@apple.com>
2951
2952         Checkmark on OFF option of captions sometimes does not appear.
2953         https://bugs.webkit.org/show_bug.cgi?id=145060.
2954         <rdar://problem/19388333>
2955
2956         Reviewed by Eric Carlson.
2957
2958         * Modules/mediacontrols/mediaControlsApple.js:
2959         (Controller.prototype.buildCaptionMenu):
2960         Audio tracks don’t have an OFF option.
2961         Remove related code to allow OFF option for subtitles to work properly.
2962
2963 2015-05-15  Zalan Bujtas  <zalan@apple.com>
2964
2965         White edge on animating panel on http://rokkosunnyvale.com
2966         https://bugs.webkit.org/show_bug.cgi?id=144986
2967         rdar://problem/20907683
2968
2969         Reviewed by Simon Fraser.
2970
2971         Background image geometry calculation needs to be based on the final painting size of the container
2972         in order to accurately compute tile sizes, repeating positions etc.
2973         The container's size is pixelsnapped at painting using absolute coordinates. This patch
2974         ensures that we snap to the same size while computing background geometry.
2975
2976         Test: fast/images/background-image-size-changes-fractional-position.html
2977
2978         * rendering/InlineFlowBox.cpp:
2979         (WebCore::InlineFlowBox::paintBoxDecorations):
2980         * rendering/RenderBox.cpp:
2981         (WebCore::RenderBox::paintBoxDecorations):
2982         (WebCore::RenderBox::paintBackground):
2983         (WebCore::RenderBox::getBackgroundPaintedExtent):
2984         (WebCore::RenderBox::computeBackgroundIsKnownToBeObscured):
2985         (WebCore::RenderBox::maskClipRect):
2986         (WebCore::RenderBox::repaintLayerRectsForImage): unable to get absolute coords.
2987         * rendering/RenderBox.h:
2988         * rendering/RenderBoxModelObject.cpp:
2989         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
2990         (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
2991         (WebCore::RenderBoxModelObject::getGeometryForBackgroundImage):
2992         (WebCore::RenderBoxModelObject::boxShadowShouldBeAppliedToBackground):
2993         * rendering/RenderBoxModelObject.h:
2994         * rendering/RenderFieldset.cpp:
2995         (WebCore::RenderFieldset::paintBoxDecorations):
2996         * rendering/RenderImage.cpp:
2997         (WebCore::RenderImage::boxShadowShouldBeAppliedToBackground):
2998         (WebCore::RenderImage::computeBackgroundIsKnownToBeObscured):
2999         * rendering/RenderImage.h:
3000         * rendering/RenderLayer.cpp: unable to get absolute coords.
3001         (WebCore::RenderLayer::calculateClipRects):
3002         * rendering/RenderLayerBacking.cpp:
3003         (WebCore::RenderLayerBacking::updateDirectlyCompositedBackgroundImage): currently not used.
3004         * rendering/RenderObject.h:
3005         (WebCore::RenderObject::computeBackgroundIsKnownToBeObscured):
3006         (WebCore::RenderObject::backgroundIsKnownToBeObscured):
3007         * rendering/RenderTable.cpp:
3008         (WebCore::RenderTable::paintBoxDecorations):
3009         * rendering/RenderTableCell.cpp:
3010         (WebCore::RenderTableCell::boxShadowShouldBeAppliedToBackground):
3011         * rendering/RenderTableCell.h:
3012
3013 2015-05-15  Jer Noble  <jer.noble@apple.com>
3014
3015         Crash in RenderFlowThread::popFlowThreadLayoutState() due to mismatched push/pop count
3016         https://bugs.webkit.org/show_bug.cgi?id=145042
3017
3018         Reviewed by David Hyatt.
3019
3020         RenderFlowThread previously used a ListHashSet to store its stack of active objects. This
3021         is problematic because, if the same object is pushed twice, only a single entry of that
3022         object is added to the stack. After this occurs, a matching number of pushes will pop too
3023         many items off the stack, causing a crash when popping a stack with zero items. This
3024         specifically happens in FrameView::layout(), which will push its root renderer on the stack
3025         of active items, and then ask the root to layout(), which will attempt to push itself on the
3026         stack of active items.
3027
3028         Instead of a ListHashSet, use a Vector, which has similar memory characteristics and no 
3029         uniqueness requirements.
3030
3031         * rendering/RenderFlowThread.cpp:
3032         (WebCore::RenderFlowThread::pushFlowThreadLayoutState):
3033         (WebCore::RenderFlowThread::popFlowThreadLayoutState):
3034         * rendering/RenderFlowThread.h:
3035
3036 2015-05-15  Per Arne Vollan  <peavo@outlook.com>
3037
3038         [Curl] WebSocket platform part is not implemented.
3039         https://bugs.webkit.org/show_bug.cgi?id=144628
3040
3041         Reviewed by Darin Adler.
3042
3043         Add Curl platform code implementation for WebSockets.
3044
3045         * platform/network/curl/SocketStreamHandle.h:
3046         (WebCore::SocketStreamHandle::create):
3047         (WebCore::SocketStreamHandle::SocketData::SocketData):
3048         * platform/network/curl/SocketStreamHandleCurl.cpp:
3049         (WebCore::SocketStreamHandle::SocketStreamHandle):
3050         (WebCore::SocketStreamHandle::~SocketStreamHandle):
3051         (WebCore::SocketStreamHandle::platformSend):
3052         (WebCore::SocketStreamHandle::platformClose):
3053         (WebCore::SocketStreamHandle::readData):
3054         (WebCore::SocketStreamHandle::sendData):
3055         (WebCore::SocketStreamHandle::waitForAvailableData):
3056         (WebCore::SocketStreamHandle::startThread):
3057         (WebCore::SocketStreamHandle::stopThread):
3058         (WebCore::SocketStreamHandle::didReceiveData):
3059         (WebCore::SocketStreamHandle::didOpenSocket):
3060         (WebCore::SocketStreamHandle::createCopy):
3061
3062 2015-05-14  Carlos Garcia Campos  <cgarcia@igalia.com>
3063
3064         REGRESSION(r183861): [SOUP] Downloads are broken when using the Network Process
3065         https://bugs.webkit.org/show_bug.cgi?id=144738
3066
3067         Reviewed by Alexey Proskuryakov.
3068
3069         Add ResourceHandle::releaseForDownload() that releases the current
3070         handle to be used as a download.
3071
3072         * platform/network/ResourceHandle.h:
3073         * platform/network/soup/ResourceHandleSoup.cpp:
3074         (WebCore::ResourceHandle::releaseForDownload):
3075
3076 2015-05-15  Zan Dobersek  <zdobersek@igalia.com>
3077
3078         [GTK] Fix PlatformDisplayWayland construction error, implement the destructor
3079         https://bugs.webkit.org/show_bug.cgi?id=144997
3080
3081         Reviewed by Carlos Garcia Campos.
3082
3083         The PlatformDisplayWayland constructor is private, so we can't use
3084         std::make_unique<>() to construct an object of this class.
3085
3086         Implement the PlatformDisplayWayland destructor, cleaning out all
3087         the Wayland resources, if present.
3088
3089         * platform/graphics/wayland/PlatformDisplayWayland.cpp:
3090         (WebCore::PlatformDisplayWayland::create):
3091         (WebCore::PlatformDisplayWayland::PlatformDisplayWayland):
3092         (WebCore::PlatformDisplayWayland::~PlatformDisplayWayland):
3093
3094 2015-05-14  Zalan Bujtas  <zalan@apple.com>
3095
3096         Images on www.fitstylelife.com jiggle on hover.
3097         https://bugs.webkit.org/show_bug.cgi?id=145020
3098         rdar://problem/20885337
3099
3100         Reviewed by Simon Fraser.
3101
3102         This patch ensures that the clipping layer of a composited content is pixel snapped properly.
3103
3104         Tests: compositing/composited-parent-clipping-layer-on-subpixel-position.html
3105                compositing/parent-clipping-layer-on-subpixel-position.html
3106
3107         * rendering/RenderLayerBacking.cpp:
3108         (WebCore::RenderLayerBacking::updateGeometry):
3109
3110 2015-05-14  Chris Dumez  <cdumez@apple.com>
3111
3112         Have DOMWindow::createWindow() take references to frames
3113         https://bugs.webkit.org/show_bug.cgi?id=145037
3114
3115         Reviewed by Gyuyoung Kim.
3116
3117         Have DOMWindow::createWindow() take references to frames instead of
3118         pointers as they are expected to be non-null. Also return a RefPtr
3119         instead of a PassRefPtr.
3120
3121         * inspector/InspectorFrontendClientLocal.cpp:
3122         (WebCore::InspectorFrontendClientLocal::openInNewTab):
3123         * loader/FrameLoader.cpp:
3124         (WebCore::createWindow):
3125         * loader/FrameLoader.h:
3126         * page/DOMWindow.cpp:
3127         (WebCore::DOMWindow::createWindow):
3128         (WebCore::DOMWindow::open):
3129         (WebCore::DOMWindow::showModalDialog):
3130         * page/DOMWindow.h:
3131
3132 2015-05-14  Simon Fraser  <simon.fraser@apple.com>
3133
3134         REGRESSION (r183794): Garbage tiles when body background switches to fixed
3135         https://bugs.webkit.org/show_bug.cgi?id=145032
3136         rdar://problem/20963679
3137
3138         Reviewed by Dean Jackson.
3139         
3140         After r183794 (or possibly an earlier commit), we failed to dynamically update
3141         the configuration of layers that handled fixed background attachment on the root.
3142         
3143         This would result in unpainted tiles, and non-fixed-background behavior.
3144         
3145         Fix by calling RenderLayerCompositor::rootOrBodyStyleChanged() whenever the
3146         style changes on the root or body renderers, and triggering a compositing update
3147         if the fixedness of the background changes. It calls the existing rootBackgroundTransparencyChanged()
3148         if the color changes.
3149
3150         Test: platform/mac-wk2/tiled-drawing/toggle-to-fixed-background.html
3151
3152         * rendering/RenderBox.cpp:
3153         (WebCore::RenderBox::styleDidChange):
3154         * rendering/RenderLayerCompositor.cpp:
3155         (WebCore::RenderLayerCompositor::rootOrBodyStyleChanged):
3156         (WebCore::RenderLayerCompositor::rootBackgroundTransparencyChanged):
3157         * rendering/RenderLayerCompositor.h:
3158
3159 2015-05-14  Commit Queue  <commit-queue@webkit.org>
3160
3161         Unreviewed, rolling out r184359 and r184362.
3162         https://bugs.webkit.org/show_bug.cgi?id=145035
3163
3164         Introduced a crash in six media element tests (Requested by
3165         rniwa on #webkit).
3166
3167         Reverted changesets:
3168
3169         "[MediaControls] Refactor media controls & bring improvements
3170         made to iOS controls to Mac."
3171         https://bugs.webkit.org/show_bug.cgi?id=144973
3172         http://trac.webkit.org/changeset/184359
3173
3174         "Unreviewed build fix after r184359; typo."
3175         http://trac.webkit.org/changeset/184362
3176
3177 2015-05-14  Jer Noble  <jer.noble@apple.com>
3178
3179         Unreviewed build fix after r184359; typo.
3180
3181         * html/HTMLMediaElement.cpp:
3182         (WebCore::HTMLMediaElement::layoutSizeChanged):
3183
3184 2015-05-14  Roger Fong  <roger_fong@apple.com>
3185
3186         Adjust button CSS and positioning in preparation.
3187         https://bugs.webkit.org/show_bug.cgi?id=144973.
3188         <rdar://problem/20306227>
3189
3190         Reviewed by Dean Jackson.
3191
3192         The only visual change here is the swapping of the rewind and play button positions.
3193         Also, position buttons based off of both left and right margins instead of just one of the two.
3194         This allows the controls drop off to work without having to use a spacer element to take the place
3195         of the timeline if the controls are too small.
3196         * Modules/mediacontrols/mediaControlsApple.css:
3197         (audio::-webkit-media-controls-rewind-button):
3198         (audio::-webkit-media-controls-play-button):
3199         (audio::-webkit-media-controls-panel .mute-box):
3200         (audio::-webkit-media-controls-wireless-playback-picker-button):
3201         (audio::-webkit-media-controls-toggle-closed-captions-button):
3202         (audio::-webkit-media-controls-fullscreen-button):
3203         (audio::-webkit-media-controls-fullscreen-button.exit):
3204         (audio::-webkit-media-controls-time-remaining-display):
3205         (audio:-webkit-full-screen::-webkit-media-controls-toggle-closed-captions-button):
3206         (audio:-webkit-full-screen::-webkit-media-controls-wireless-playback-picker-button):
3207         * Modules/mediacontrols/mediaControlsApple.js:
3208         (Controller.prototype.configureInlineControls):
3209
3210 2015-05-14  Dean Jackson  <dino@apple.com>
3211
3212         MediaControls: controls are live even when invisible
3213         https://bugs.webkit.org/show_bug.cgi?id=145029
3214         <rdar://problem/20865442>
3215
3216         Reviewed by Jer Noble.
3217
3218         When the controls are invisible they should ignore touch/mouse
3219         events.
3220
3221         * Modules/mediacontrols/mediaControlsiOS.css: Add pointer-events: none where appropriate.
3222         (video::-webkit-media-controls-panel-container):
3223         (video::-webkit-media-controls-panel-background):
3224         (video::-webkit-media-controls-panel):
3225         (video::-webkit-media-controls-panel.paused):
3226
3227 2015-05-14  Jer Noble  <jer.noble@apple.com>
3228
3229         [MediaControls] Refactor media controls & bring improvements made to iOS controls to Mac.
3230         https://bugs.webkit.org/show_bug.cgi?id=144973
3231
3232         Reviewed by Dean Jackson.
3233
3234         Pull improvements made to the iOS media controls back into the Mac controls by moving
3235         code from mediaControlsiOS.js into MediaControlsApple.js.
3236
3237         The largest refactored feature is the ability to drop individual controls from the media
3238         controls when the video is too small to contain them. To allow these controls to resize
3239         dynamically, a new "resize" event is fired inside the media element's shadow DOM.
3240
3241         * Modules/mediacontrols/mediaControlsApple.css:
3242         (audio::-webkit-media-controls-panel .dropped): Added; sets "display: none".
3243         * Modules/mediacontrols/mediaControlsApple.js:
3244         (Controller): Set defaults for new variables.
3245         (Controller.prototype.updateControls): Update the controls width; moved from iOS.js.
3246         (Controller.prototype.handleReadyStateChange): Update the controls; moved from iOS.js.
3247         (Controller.prototype.handleTimeUpdate): Update the progress; moved from iOS.js.
3248         (Controller.prototype.handleTimelineInput): Pause if scrubbing; moved from iOS.js.
3249         (Controller.prototype.handleTimelineChange): Update the progress; moved from iOS.js.
3250         (Controller.prototype.showControls): Update the controls width; moved from iOS.js.
3251         (Controller.prototype.hideControls): Removed _potentiallyScrubbing check; not needed due to changes
3252             to controlsAlwaysVisible().
3253         (Controller.prototype.scheduleUpdateLayoutForDisplayedWidth): Moved from iOS.js.
3254         (Controller.prototype.isControlVisible): Added; checks whether control is parented & not hidden.
3255         (Controller.prototype.updateLayoutForDisplayedWidth): Moved from iOS.js and refactored.
3256         (Controller.prototype.controlsAlwaysVisible): Return true if scrubbing.
3257         (Controller.prototype.updateHasAudio): Check currentPlaybackTargetIsWireless(); moved from iOS.js.
3258         (Controller.prototype.get scrubbing): Simple getter for _scrubbing.
3259         (Controller.prototype.set scrubbing): Check play state if scrubbing; start playback (if necessary)
3260             if not scrubbing.
3261         (Controller.prototype.get pageScaleFactor): Moved from iOS.js.
3262         (Controller.prototype.set pageScaleFactor): Ditto.
3263         (Controller.prototype.handleRootResize): Schedule an update of the contrtols width.
3264
3265         Remove a bunch of newly unnecessary code from the iOS media controls:
3266
3267         * Modules/mediacontrols/mediaControlsiOS.js:
3268         (ControllerIOS):
3269         (ControllerIOS.prototype.createControls): Remove ivars moved into Apple.js.
3270         (ControllerIOS.prototype.configureInlineControls): Remove spacer; made unnecessary.
3271         (ControllerIOS.prototype.showControls): Deleted.
3272         (ControllerIOS.prototype.updateTime): Deleted.
3273         (ControllerIOS.prototype.handleTimelineTouchStart): Just call "scrubbing = true", handled in Apple.js.
3274         (ControllerIOS.prototype.handleTimelineTouchEnd): Just call "scrubbing = false", handled in Apple.js.
3275         (ControllerIOS.prototype.handleReadyStateChange): Deleted.
3276         (ControllerIOS.prototype.setPlaying): Don't check _timelineIsHidden; not needed.
3277         (ControllerIOS.prototype.get pageScaleFactor): Deleted.
3278         (ControllerIOS.prototype.set pageScaleFactor): Deleted.
3279         (ControllerIOS.prototype.scheduleUpdateLayoutForDisplayedWidth): Deleted.
3280         (ControllerIOS.prototypeupdateLayoutForDisplayedWidth): Deleted.
3281
3282         Fire a "resize" event at the shadow DOM root when layout results in a size change.
3283
3284         * html/HTMLMediaElement.cpp:
3285         (WebCore::HTMLMediaElement::layoutSizeChanged): Fire the "resize" event at the shadow DOM.
3286         * html/HTMLMediaElement.h:
3287         * rendering/RenderMedia.cpp:
3288         (WebCore::RenderMedia::layout): Trigger layoutSizeChanged()
3289         * rendering/RenderMedia.h:
3290
3291         Drive-by fixes:
3292
3293         * Modules/mediacontrols/mediaControlsApple.js:
3294         (Controller.prototype.createControls): aria-label text is totally wrong; removed.
3295         (Controller.prototype.updateWirelessPlaybackStatus): Use class-names to hide controls, not inline styles.
3296
3297 2015-05-13  Ryosuke Niwa  <rniwa@webkit.org>
3298
3299         Crash in ReplaceSelectionCommand::removeRedundantStylesAndKeepStyleSpanInline
3300         https://bugs.webkit.org/show_bug.cgi?id=119068
3301
3302         Reviewed by Enrica Casucci.
3303
3304         The bug was caused by makeInsertedContentRoundTrippableWithHTMLTreeBuilder not updating
3305         nodes kept tracked by insertedNodes and moveNodeOutOfAncestor stumbling upon it.
3306
3307         Fixed the bug by updating insertedNodes in makeInsertedContentRoundTrippableWithHTMLTreeBuilder.
3308
3309         Test: editing/inserting/insert-table-in-paragraph-crash.html
3310
3311         * editing/ReplaceSelectionCommand.cpp:
3312         (WebCore::ReplaceSelectionCommand::makeInsertedContentRoundTrippableWithHTMLTreeBuilder):
3313         (WebCore::ReplaceSelectionCommand::moveNodeOutOfAncestor):
3314         * editing/ReplaceSelectionCommand.h:
3315
3316 2015-05-14  Myles C. Maxfield  <mmaxfield@apple.com>
3317
3318         [Mac] Expose more font weights for -apple-system
3319         https://bugs.webkit.org/show_bug.cgi?id=144707
3320
3321         Reviewed by Simon Fraser.
3322
3323         Previously, when we parsed a CSS declaration of the form font: keyword; where keyword
3324         is one of caption, icon, menu, message-box, small-caption, -webkit-mini-control, -webkit-small-control,
3325         or -webkit-control (which html.css does for form controls), we would ask the system what the appropriate
3326         system font is, get that font's family name, and synthesize a font-family CSS property for the element.
3327         Then, later when we actually go to look up the font, we would look up the font by family name using this
3328         information. However, this round-tripping of a font through a family name is actually lossy, and is not
3329         guaranteed to preserve system-font-ness (which we use for various things including metrics calculations).
3330
3331         This patch modifies this logic to specify a token family name instead, which the font lookup code special
3332         cases (and reacts by making the appropriate system-font lookup call). This approach is currently how iOS
3333         handles these system fonts; this patch simply brings this approach to OS X.
3334
3335         There is also an added progression here. We used to simply call [NSFont fontWithName:size:] on the system
3336         font family name (which the parser found for us) which entirely disregards weight. This means that we
3337         used to be getting synthesized bold in form controls which ask for a heavy weight. Migrating to this
3338         system-font aware call means that we get the real bold font instead of synthesized bold.
3339
3340         Once this system-font-ness is guaranteed to be preserved between parsing time and font lookup time, we
3341         can safely migrate to using [NSFont systemFontOfSize:weight] instead of [NSFont systemFontOfSize:] on
3342         platforms which support it.
3343
3344         Tests: fast/text/systemFont.html
3345                fast/css/css2-system-fonts.html
3346                fast/forms/select/optgroup-rendering.html
3347                fast/forms/validation-message-appearance.html
3348
3349         * css/CSSParser.cpp:
3350         (WebCore::CSSParser::parseSystemFont): Add a comment regarding why we are bothering with expanding out
3351         the font property in the first place.
3352         * platform/graphics/cocoa/FontCascadeCocoa.mm:
3353         (WebCore::FontCascade::primaryFontIsSystemFont): Update to use new system font tokens.
3354         * platform/graphics/mac/FontCacheMac.mm:
3355         (WebCore::toNSFontWeight): New static method to map font weights to NSFontWeight constants available on
3356         Yosemite and later.
3357         (WebCore::fontWithFamilySpecialCase): Pull all these special-case font token name handling into a
3358         separate function, which returns an Optional.
3359         (WebCore::fontWithFamily):
3360         * platform/mac/ThemeMac.mm:
3361         (WebCore::ThemeMac::controlFont): Use the font token name instead of the generated system font family
3362         name.
3363         * platform/spi/mac/NSFontSPI.h: Add [NSFont systemFontWithSize:weight:] and the proper NSFontWeight
3364         constants.
3365         * rendering/RenderThemeMac.mm:
3366         (WebCore::RenderThemeMac::updateCachedSystemFontDescription): Use the font token names instead of the
3367         generated system font family name.
3368         (WebCore::RenderThemeMac::setFontFromControlSize): Ditto.
3369
3370 2015-05-14  Roger Fong  <roger_fong@apple.com>
3371
3372         Add internals setting to disable wireless playback availability for layout tests
3373         https://bugs.webkit.org/show_bug.cgi?id=145012.
3374         <rdar://problem/20946504>
3375
3376         Reviewed by Eric Carlson.
3377
3378         * testing/InternalSettings.cpp:
3379         (WebCore::InternalSettings::resetToConsistentState):
3380         (WebCore::InternalSettings::setWirelessPlaybackDisabled):
3381         * testing/InternalSettings.idl:
3382
3383 2015-05-14  Beth Dakin  <bdakin@apple.com>
3384
3385         Change range of possible forces for mouseforcechanged DOM event
3386         https://bugs.webkit.org/show_bug.cgi?id=144987
3387         -and corresponding-
3388         rdar://problem/20472802
3389
3390         Reviewed by Tim Horton.
3391
3392         Change to a 0-3 range.
3393         * platform/PlatformMouseEvent.h:
3394         * platform/mac/PlatformEventFactoryMac.mm:
3395         (WebCore::PlatformMouseEventBuilder::PlatformMouseEventBuilder):
3396
3397 2015-05-14  Manuel Rego Casasnovas  <rego@igalia.com>
3398
3399         Fix typo in RenderBox::instrinsicScrollbarLogicalWidth()
3400         https://bugs.webkit.org/show_bug.cgi?id=144999
3401
3402         Reviewed by Sergio Villar Senin.
3403
3404         Rename RenderBox::instrinsicScrollbarLogicalWidth() to
3405         RenderBox::intrinsicScrollbarLogicalWidth().
3406
3407         No new tests, no behavior changes.
3408
3409         * rendering/RenderBlock.cpp:
3410         (WebCore::RenderBlock::computeIntrinsicLogicalWidths):
3411         * rendering/RenderBlockFlow.cpp:
3412         (WebCore::RenderBlockFlow::computeIntrinsicLogicalWidths):
3413         * rendering/RenderBox.cpp:
3414         (WebCore::RenderBox::intrinsicScrollbarLogicalWidth):
3415         (WebCore::RenderBox::instrinsicScrollbarLogicalWidth): Deleted.
3416         * rendering/RenderBox.h:
3417         * rendering/RenderDeprecatedFlexibleBox.cpp:
3418         (WebCore::RenderDeprecatedFlexibleBox::computeIntrinsicLogicalWidths):
3419         * rendering/RenderFlexibleBox.cpp:
3420         (WebCore::RenderFlexibleBox::computeIntrinsicLogicalWidths):
3421
3422 2015-05-14  Youenn Fablet  <youenn.fablet@crf.canon.fr>
3423
3424         SharedBuffer::createWithContentsOfFile should use map file routines
3425         https://bugs.webkit.org/show_bug.cgi?id=144192
3426
3427         Reviewed by Darin Adler.
3428
3429         Made use of mmap routines within SharedBuffer::createWithContentsOfFile for EFL, GTK and Mac ports.
3430         If mapping is failing, it falls back to the previous version of SharedBuffer::createWithContentsOfFile renamed as