RenderMathMLScripts isPrescript() helper should take a reference.
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2014-11-21  Andreas Kling  <akling@apple.com>
2
3         RenderMathMLScripts isPrescript() helper should take a reference.
4         <https://webkit.org/b/138975>
5
6         Reviewed by Antti Koivisto.
7
8         Tidy this up a bit, since it's never called with a null pointer.
9
10         * rendering/mathml/RenderMathMLScripts.cpp:
11         (WebCore::isPrescript):
12         (WebCore::RenderMathMLScripts::fixAnonymousStyles):
13         (WebCore::RenderMathMLScripts::addChildInternal):
14         (WebCore::RenderMathMLScripts::removeChildInternal):
15         (WebCore::RenderMathMLScripts::layout):
16         (WebCore::RenderMathMLScriptsWrapper::addChildInternal):
17         (WebCore::RenderMathMLScriptsWrapper::removeChildInternal):
18
19 2014-11-21  Anders Carlsson  <andersca@apple.com>
20
21         Windows build fixes.
22
23         * plugins/PluginPackage.cpp:
24         (WebCore::PluginPackage::freeLibraryTimerFired):
25         (WebCore::PluginPackage::PluginPackage):
26         * plugins/PluginPackage.h:
27         * plugins/PluginStream.cpp:
28         (WebCore::PluginStream::PluginStream):
29         (WebCore::PluginStream::delayDeliveryTimerFired):
30         (WebCore::PluginStream::deliverData): Deleted.
31         * plugins/PluginStream.h:
32         * plugins/PluginView.cpp:
33         (WebCore::PluginView::popPopupsStateTimerFired):
34         (WebCore::PluginView::requestTimerFired):
35         (WebCore::PluginView::invalidateTimerFired):
36         (WebCore::PluginView::PluginView):
37         (WebCore::PluginView::lifeSupportTimerFired):
38         (WebCore::PluginView::performRequest): Deleted.
39         (WebCore::PluginView::setValue): Deleted.
40         (WebCore::PluginView::setParameters): Deleted.
41         (WebCore::PluginView::userAgent): Deleted.
42         * plugins/PluginView.h:
43         * plugins/win/PluginMessageThrottlerWin.cpp:
44         (WebCore::PluginMessageThrottlerWin::PluginMessageThrottlerWin):
45         (WebCore::PluginMessageThrottlerWin::messageThrottleTimerFired):
46         * plugins/win/PluginMessageThrottlerWin.h:
47
48 2014-11-21  Tim Horton  <timothy_horton@apple.com>
49
50         REGRESSION (r176351): Parts of apple.com/contact aren't Lookup-able
51         https://bugs.webkit.org/show_bug.cgi?id=138960
52         <rdar://problem/19056715>
53
54         Reviewed by Beth Dakin.
55
56         * platform/spi/mac/DataDetectorsSPI.h:
57         Softlink some SPI.
58
59 2014-11-21  Tim Horton  <timothy_horton@apple.com>
60
61         Move TextIndicator{Window} to WebCore
62         https://bugs.webkit.org/show_bug.cgi?id=138954
63         <rdar://problem/18992185>
64
65         Some adjustments by Csaba Osztrogon√°c.
66         Reviewed by Anders Carlsson.
67
68         Move TextIndicator and TextIndicatorWindow to WebCore so that both
69         WebKits can share the implementation.
70
71         * CMakeLists.txt:
72         Build TextIndicator.
73
74         * WebCore.exp.in:
75         Export TextIndicator{Window} symbols for the WebKits.
76
77         * WebCore.xcodeproj/project.pbxproj:
78         * page/TextIndicator.cpp: Renamed from Source/WebKit2/Shared/TextIndicator.cpp.
79         * page/TextIndicator.h: Renamed from Source/WebKit2/Shared/TextIndicator.h.
80         Straighforward move of TextIndicator from WebKit2, except:
81
82         Move TextIndicator::Data and TextIndicator::PresentationTransition out directly
83         into the WebCore namespace to allow for implementation of WebKit2 argument coders.
84
85         Use Image instead of ShareableBitmap internally.
86
87         Move the TextIndicatorData encode/decode to WebCoreArgumentCoders.
88         
89         * page/mac/TextIndicatorWindow.h: Renamed from Source/WebKit2/UIProcess/mac/TextIndicatorWindow.h.
90         * page/mac/TextIndicatorWindow.mm: Renamed from Source/WebKit2/UIProcess/mac/TextIndicatorWindow.mm.
91         Straighforward move of TextIndicatorWindow from WebKit2.
92
93 2014-11-21  Anders Carlsson  <andersca@apple.com>
94
95         Remove the Timer parameters from timer callbacks
96         https://bugs.webkit.org/show_bug.cgi?id=138974
97
98         Reviewed by Antti Koivisto.
99
100         * Modules/encryptedmedia/MediaKeySession.cpp:
101         (WebCore::MediaKeySession::MediaKeySession):
102         (WebCore::MediaKeySession::keyRequestTimerFired):
103         (WebCore::MediaKeySession::addKeyTimerFired):
104         * Modules/encryptedmedia/MediaKeySession.h:
105         * Modules/geolocation/Geolocation.cpp:
106         (WebCore::Geolocation::GeoNotifier::GeoNotifier):
107         (WebCore::Geolocation::GeoNotifier::timerFired):
108         (WebCore::Geolocation::Geolocation):
109         (WebCore::Geolocation::resumeTimerFired):
110         * Modules/geolocation/Geolocation.h:
111         * Modules/indexeddb/IDBTransactionBackend.cpp:
112         (WebCore::IDBTransactionBackend::IDBTransactionBackend):
113         (WebCore::IDBTransactionBackend::taskTimerFired):
114         * Modules/indexeddb/IDBTransactionBackend.h:
115         * Modules/mediasource/SourceBuffer.cpp:
116         (WebCore::SourceBuffer::SourceBuffer):
117         (WebCore::SourceBuffer::appendBufferTimerFired):
118         (WebCore::SourceBuffer::removeTimerFired):
119         * Modules/mediasource/SourceBuffer.h:
120         * Modules/mediastream/MediaStream.cpp:
121         (WebCore::MediaStream::MediaStream):
122         (WebCore::MediaStream::scheduledEventTimerFired):
123         * Modules/mediastream/MediaStream.h:
124         * Modules/mediastream/RTCDTMFSender.cpp:
125         (WebCore::RTCDTMFSender::RTCDTMFSender):
126         (WebCore::RTCDTMFSender::scheduledEventTimerFired):
127         * Modules/mediastream/RTCDTMFSender.h:
128         * Modules/mediastream/RTCDataChannel.cpp:
129         (WebCore::RTCDataChannel::RTCDataChannel):
130         (WebCore::RTCDataChannel::scheduledEventTimerFired):
131         * Modules/mediastream/RTCDataChannel.h:
132         * Modules/mediastream/RTCPeerConnection.cpp:
133         (WebCore::RTCPeerConnection::RTCPeerConnection):
134         (WebCore::RTCPeerConnection::scheduledEventTimerFired):
135         * Modules/mediastream/RTCPeerConnection.h:
136         * Modules/notifications/Notification.cpp:
137         (WebCore::Notification::Notification):
138         (WebCore::Notification::taskTimerFired):
139         * Modules/notifications/Notification.h:
140         * Modules/notifications/NotificationCenter.cpp:
141         (WebCore::NotificationCenter::NotificationRequestCallback::NotificationRequestCallback):
142         (WebCore::NotificationCenter::NotificationRequestCallback::timerFired):
143         * Modules/notifications/NotificationCenter.h:
144         * Modules/websockets/WebSocketChannel.cpp:
145         (WebCore::WebSocketChannel::WebSocketChannel):
146         (WebCore::WebSocketChannel::resumeTimerFired):
147         (WebCore::WebSocketChannel::closingTimerFired):
148         * Modules/websockets/WebSocketChannel.h:
149         * accessibility/AXObjectCache.cpp:
150         (WebCore::AXObjectCache::AXObjectCache):
151         (WebCore::AXObjectCache::notificationPostTimerFired):
152         * accessibility/AXObjectCache.h:
153         * bindings/js/GCController.cpp:
154         (WebCore::GCController::GCController):
155         (WebCore::GCController::gcTimerFired):
156         * bindings/js/GCController.h:
157         * css/CSSFontFaceSource.h:
158         * css/CSSFontSelector.cpp:
159         (WebCore::CSSFontSelector::CSSFontSelector):
160         (WebCore::CSSFontSelector::beginLoadTimerFired):
161         * css/CSSFontSelector.h:
162         * css/CSSImageGeneratorValue.cpp:
163         (WebCore::CSSImageGeneratorValue::CachedGeneratedImage::CachedGeneratedImage):
164         * css/StyleResolver.cpp:
165         (WebCore::StyleResolver::StyleResolver):
166         (WebCore::StyleResolver::sweepMatchedPropertiesCache):
167         * css/StyleResolver.h:
168         * dom/Document.cpp:
169         (WebCore::Document::Document):
170         (WebCore::Document::visualUpdatesSuppressionTimerFired):
171         (WebCore::Document::styleRecalcTimerFired):
172         (WebCore::Document::optimizedStyleSheetUpdateTimerFired):
173         (WebCore::Document::sharedObjectPoolClearTimerFired):
174         (WebCore::Document::updateFocusAppearanceTimerFired):
175         (WebCore::Document::pendingTasksTimerFired):
176         (WebCore::Document::webkitWillEnterFullScreenForElement):
177         (WebCore::Document::webkitDidExitFullScreenForElement):
178         (WebCore::Document::fullScreenChangeDelayTimerFired):
179         (WebCore::Document::loadEventDelayTimerFired):
180         (WebCore::Document::didAssociateFormControlsTimerFired):
181         (WebCore::Document::domCookieCacheExpiryTimerFired):
182         * dom/Document.h:
183         * dom/EventSender.h:
184         (WebCore::EventSender::timerFired):
185         (WebCore::EventSender<T>::EventSender):
186         * dom/ScriptRunner.cpp:
187         (WebCore::ScriptRunner::ScriptRunner):
188         (WebCore::ScriptRunner::timerFired):
189         * dom/ScriptRunner.h:
190         * dom/ScriptedAnimationController.cpp:
191         (WebCore::ScriptedAnimationController::ScriptedAnimationController):
192         (WebCore::ScriptedAnimationController::animationTimerFired):
193         * dom/ScriptedAnimationController.h:
194         * dom/StyledElement.cpp:
195         (WebCore::PresentationAttributeCacheCleaner::PresentationAttributeCacheCleaner):
196         (WebCore::PresentationAttributeCacheCleaner::cleanCache):
197         * editing/AlternativeTextController.cpp:
198         (WebCore::AlternativeTextController::AlternativeTextController):
199         (WebCore::AlternativeTextController::timerFired):
200         * editing/AlternativeTextController.h:
201         * editing/Editor.cpp:
202         (WebCore::Editor::Editor):
203         (WebCore::Editor::updateEditorUINowIfScheduled):
204         (WebCore::Editor::editorUIUpdateTimerFired):
205         (WebCore::Editor::scanSelectionForTelephoneNumbers): Deleted.
206         * editing/Editor.h:
207         * editing/FrameSelection.cpp:
208         (WebCore::FrameSelection::FrameSelection):
209         (WebCore::FrameSelection::caretBlinkTimerFired):
210         * editing/FrameSelection.h:
211         * editing/SpellChecker.cpp:
212         (WebCore::SpellChecker::SpellChecker):
213         (WebCore::SpellChecker::timerFiredToProcessQueuedRequest):
214         * editing/SpellChecker.h:
215         * html/HTMLFormElement.cpp:
216         (WebCore::HTMLFormElement::HTMLFormElement):
217         (WebCore::HTMLFormElement::requestAutocompleteTimerFired):
218         * html/HTMLFormElement.h:
219         * html/HTMLMediaElement.cpp:
220         (WebCore::HTMLMediaElement::HTMLMediaElement):
221         (WebCore::HTMLMediaElement::parseAttribute):
222         * html/HTMLMediaElement.h:
223         * html/HTMLPlugInElement.cpp:
224         (WebCore::HTMLPlugInElement::HTMLPlugInElement):
225         (WebCore::HTMLPlugInElement::swapRendererTimerFired):
226         * html/HTMLPlugInElement.h:
227         * html/HTMLPlugInImageElement.cpp:
228         (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement):
229         (WebCore::HTMLPlugInImageElement::removeSnapshotTimerFired):
230         * html/HTMLPlugInImageElement.h:
231         * html/HTMLSourceElement.cpp:
232         (WebCore::HTMLSourceElement::HTMLSourceElement):
233         (WebCore::HTMLSourceElement::errorEventTimerFired):
234         * html/HTMLSourceElement.h:
235         * html/HTMLTrackElement.cpp:
236         (WebCore::HTMLTrackElement::HTMLTrackElement):
237         (WebCore::HTMLTrackElement::loadTimerFired):
238         * html/HTMLTrackElement.h:
239         * html/MediaController.cpp:
240         (MediaController::MediaController):
241         (MediaController::asyncEventTimerFired):
242         (MediaController::clearPositionTimerFired):
243         (MediaController::timeupdateTimerFired):
244         * html/MediaController.h:
245         * html/MediaDocument.cpp:
246         (WebCore::MediaDocument::MediaDocument):
247         (WebCore::MediaDocument::replaceMediaElementTimerFired):
248         * html/MediaDocument.h:
249         * html/SearchInputType.cpp:
250         (WebCore::SearchInputType::SearchInputType):
251         (WebCore::SearchInputType::searchEventTimerFired):
252         * html/SearchInputType.h:
253         * html/ValidationMessage.cpp:
254         (WebCore::ValidationMessage::setMessage):
255         (WebCore::ValidationMessage::setMessageDOMAndStartTimer):
256         (WebCore::ValidationMessage::buildBubbleTree):
257         (WebCore::ValidationMessage::requestToHideMessage):
258         (WebCore::ValidationMessage::deleteBubbleTree):
259         * html/ValidationMessage.h:
260         * html/canvas/WebGLRenderingContext.cpp:
261         (WebCore::WebGLRenderingContext::WebGLRenderingContext):
262         (WebCore::WebGLRenderingContext::dispatchContextLostEvent):
263         (WebCore::WebGLRenderingContext::maybeRestoreContext):
264         * html/canvas/WebGLRenderingContext.h:
265         * html/parser/HTMLParserScheduler.cpp:
266         (WebCore::HTMLParserScheduler::HTMLParserScheduler):
267         (WebCore::HTMLParserScheduler::continueNextChunkTimerFired):
268         * html/parser/HTMLParserScheduler.h:
269         * html/shadow/MediaControlElements.cpp:
270         (WebCore::MediaControlPanelElement::MediaControlPanelElement):
271         (WebCore::MediaControlPanelElement::transitionTimerFired):
272         (WebCore::MediaControlTextTrackContainerElement::MediaControlTextTrackContainerElement):
273         (WebCore::MediaControlTextTrackContainerElement::updateTimerFired):
274         * html/shadow/MediaControlElements.h:
275         * html/shadow/MediaControls.cpp:
276         (WebCore::MediaControls::MediaControls):
277         (WebCore::MediaControls::hideFullscreenControlsTimerFired):
278         * html/shadow/MediaControls.h:
279         * html/shadow/SpinButtonElement.cpp:
280         (WebCore::SpinButtonElement::SpinButtonElement):
281         (WebCore::SpinButtonElement::repeatingTimerFired):
282         * html/shadow/SpinButtonElement.h:
283         * html/track/LoadableTextTrack.cpp:
284         (WebCore::LoadableTextTrack::LoadableTextTrack):
285         (WebCore::LoadableTextTrack::loadTimerFired):
286         * html/track/LoadableTextTrack.h:
287         * html/track/VTTRegion.cpp:
288         (WebCore::VTTRegion::VTTRegion):
289         (WebCore::VTTRegion::scrollTimerFired):
290         * html/track/VTTRegion.h:
291         * inspector/InspectorCSSAgent.cpp:
292         (WebCore::ChangeRegionOversetTask::ChangeRegionOversetTask):
293         (WebCore::ChangeRegionOversetTask::timerFired):
294         * inspector/InspectorDOMAgent.cpp:
295         (WebCore::RevalidateStyleAttributeTask::RevalidateStyleAttributeTask):
296         (WebCore::RevalidateStyleAttributeTask::timerFired):
297         * inspector/InspectorFrontendClientLocal.cpp:
298         (WebCore::InspectorBackendDispatchTask::InspectorBackendDispatchTask):
299         (WebCore::InspectorBackendDispatchTask::timerFired):
300         * inspector/InspectorOverlay.cpp:
301         (WebCore::InspectorOverlay::InspectorOverlay):
302         (WebCore::InspectorOverlay::updatePaintRectsTimerFired):
303         * inspector/InspectorOverlay.h:
304         * loader/DocumentLoader.cpp:
305         (WebCore::DocumentLoader::DocumentLoader):
306         (WebCore::DocumentLoader::handleSubstituteDataLoadNow):
307         (WebCore::DocumentLoader::handleSubstituteDataLoadSoon):
308         (WebCore::DocumentLoader::substituteResourceDeliveryTimerFired):
309         * loader/DocumentLoader.h:
310         * loader/FrameLoader.cpp:
311         (WebCore::FrameLoader::FrameLoader):
312         (WebCore::FrameLoader::checkTimerFired):
313         * loader/FrameLoader.h:
314         * loader/ImageLoader.cpp:
315         (WebCore::ImageLoader::ImageLoader):
316         (WebCore::ImageLoader::timerFired):
317         * loader/ImageLoader.h:
318         * loader/LinkLoader.cpp:
319         (WebCore::LinkLoader::LinkLoader):
320         (WebCore::LinkLoader::linkLoadTimerFired):
321         (WebCore::LinkLoader::linkLoadingErrorTimerFired):
322         * loader/LinkLoader.h:
323         * loader/NavigationScheduler.cpp:
324         (WebCore::NavigationScheduler::NavigationScheduler):
325         (WebCore::NavigationScheduler::timerFired):
326         * loader/NavigationScheduler.h:
327         * loader/PingLoader.cpp:
328         (WebCore::PingLoader::PingLoader):
329         * loader/PingLoader.h:
330         (WebCore::PingLoader::timeoutTimerFired):
331         * loader/ProgressTracker.cpp:
332         (WebCore::ProgressTracker::ProgressTracker):
333         (WebCore::ProgressTracker::progressHeartbeatTimerFired):
334         * loader/ProgressTracker.h:
335         * loader/ResourceLoadScheduler.cpp:
336         (WebCore::ResourceLoadScheduler::ResourceLoadScheduler):
337         (WebCore::ResourceLoadScheduler::requestTimerFired):
338         * loader/ResourceLoadScheduler.h:
339         * loader/TextTrackLoader.cpp:
340         (WebCore::TextTrackLoader::TextTrackLoader):
341         (WebCore::TextTrackLoader::cueLoadTimerFired):
342         * loader/TextTrackLoader.h:
343         * loader/cache/CachedResource.cpp:
344         (WebCore::CachedResource::CachedResource):
345         (WebCore::CachedResource::Callback::Callback):
346         (WebCore::CachedResource::Callback::timerFired):
347         * loader/cache/CachedResource.h:
348         * loader/cache/CachedResourceLoader.cpp:
349         (WebCore::CachedResourceLoader::CachedResourceLoader):
350         (WebCore::CachedResourceLoader::garbageCollectDocumentResourcesTimerFired):
351         * loader/cache/CachedResourceLoader.h:
352         * loader/icon/IconDatabase.cpp:
353         (WebCore::IconDatabase::IconDatabase):
354         (WebCore::IconDatabase::syncTimerFired):
355         * loader/icon/IconDatabase.h:
356         * page/AutoscrollController.cpp:
357         (WebCore::AutoscrollController::AutoscrollController):
358         (WebCore::AutoscrollController::autoscrollTimerFired):
359         * page/AutoscrollController.h:
360         * page/CaptionUserPreferences.cpp:
361         (WebCore::CaptionUserPreferences::CaptionUserPreferences):
362         (WebCore::CaptionUserPreferences::timerFired):
363         * page/CaptionUserPreferences.h:
364         * page/CaptionUserPreferencesMediaAF.cpp:
365         (WebCore::CaptionUserPreferencesMediaAF::CaptionUserPreferencesMediaAF):
366         (WebCore::CaptionUserPreferencesMediaAF::updateTimerFired):
367         * page/CaptionUserPreferencesMediaAF.h:
368         * page/DeviceController.cpp:
369         (WebCore::DeviceController::DeviceController):
370         (WebCore::DeviceController::fireDeviceEvent):
371         * page/DeviceController.h:
372         * page/EventHandler.cpp:
373         (WebCore::EventHandler::EventHandler):
374         (WebCore::EventHandler::cursorUpdateTimerFired):
375         (WebCore::EventHandler::autoHideCursorTimerFired):
376         (WebCore::EventHandler::recognizeLongMousePress):
377         (WebCore::EventHandler::fakeMouseMoveEventTimerFired):
378         (WebCore::EventHandler::hoverTimerFired):
379         * page/EventHandler.h:
380         * page/EventSource.cpp:
381         (WebCore::EventSource::EventSource):
382         (WebCore::EventSource::connectTimerFired):
383         * page/EventSource.h:
384         * page/FocusController.cpp:
385         (WebCore::FocusController::FocusController):
386         (WebCore::FocusController::focusRepaintTimerFired):
387         * page/FocusController.h:
388         * page/Frame.cpp:
389         (WebCore::Frame::Frame):
390         (WebCore::Frame::overflowAutoScrollTimerFired):
391         * page/Frame.h:
392         * page/FrameView.cpp:
393         (WebCore::FrameView::FrameView):
394         (WebCore::FrameView::delayedScrollEventTimerFired):
395         (WebCore::FrameView::speculativeTilingEnableTimerFired):
396         (WebCore::FrameView::layoutTimerFired):
397         (WebCore::FrameView::updateEmbeddedObjectsTimerFired):
398         (WebCore::FrameView::flushAnyPendingPostLayoutTasks):
399         (WebCore::FrameView::postLayoutTimerFired):
400         * page/FrameView.h:
401         * page/PageOverlay.cpp:
402         (WebCore::PageOverlay::PageOverlay):
403         (WebCore::PageOverlay::fadeAnimationTimerFired):
404         * page/PageOverlay.h:
405         * page/Settings.cpp:
406         (WebCore::Settings::Settings):
407         (WebCore::Settings::imageLoadingSettingsTimerFired):
408         * page/Settings.h:
409         * page/animation/AnimationController.cpp:
410         (WebCore::AnimationControllerPrivate::AnimationControllerPrivate):
411         (WebCore::AnimationControllerPrivate::updateStyleIfNeededDispatcherFired):
412         (WebCore::AnimationControllerPrivate::animationTimerFired):
413         * page/animation/AnimationControllerPrivate.h:
414         * page/mac/ServicesOverlayController.h:
415         * page/mac/ServicesOverlayController.mm:
416         (WebCore::ServicesOverlayController::ServicesOverlayController):
417         (WebCore::ServicesOverlayController::determineActiveHighlightTimerFired):
418         * page/scrolling/AsyncScrollingCoordinator.cpp:
419         (WebCore::AsyncScrollingCoordinator::AsyncScrollingCoordinator):
420         (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScrollTimerFired):
421         * page/scrolling/AsyncScrollingCoordinator.h:
422         * page/scrolling/ios/ScrollingCoordinatorIOS.h:
423         * page/scrolling/ios/ScrollingCoordinatorIOS.mm:
424         (WebCore::ScrollingCoordinatorIOS::ScrollingCoordinatorIOS):
425         (WebCore::ScrollingCoordinatorIOS::scrollingStateTreeCommitterTimerFired):
426         * page/scrolling/mac/ScrollingCoordinatorMac.h:
427         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
428         (WebCore::ScrollingCoordinatorMac::ScrollingCoordinatorMac):
429         (WebCore::ScrollingCoordinatorMac::scrollingStateTreeCommitterTimerFired):
430         * platform/HysteresisActivity.h:
431         (WebCore::HysteresisActivity::HysteresisActivity):
432         (WebCore::HysteresisActivity::hysteresisTimerFired):
433         * platform/ScrollAnimator.cpp:
434         (WebCore::ScrollAnimator::updateScrollAnimatorsAndTimers):
435         (WebCore::ScrollAnimator::horizontalScrollSnapTimerFired):
436         (WebCore::ScrollAnimator::verticalScrollSnapTimerFired):
437         * platform/ScrollAnimator.h:
438         * platform/Scrollbar.cpp:
439         (WebCore::Scrollbar::Scrollbar):
440         (WebCore::Scrollbar::autoscrollTimerFired):
441         * platform/Scrollbar.h:
442         * platform/Timer.h:
443         (WebCore::DeferrableOneShotTimer::DeferrableOneShotTimer):
444         (WebCore::Timer::Timer): Deleted.
445         * platform/audio/MediaSession.cpp:
446         (WebCore::MediaSession::MediaSession):
447         (WebCore::MediaSession::clientDataBufferingTimerFired):
448         * platform/audio/MediaSession.h:
449         * platform/graphics/BitmapImage.cpp:
450         (WebCore::BitmapImage::startAnimation):
451         (WebCore::BitmapImage::advanceAnimation):
452         * platform/graphics/BitmapImage.h:
453         * platform/graphics/MediaPlayer.cpp:
454         (WebCore::MediaPlayer::MediaPlayer):
455         (WebCore::MediaPlayer::reloadTimerFired):
456         * platform/graphics/MediaPlayer.h:
457         * platform/graphics/ShadowBlur.cpp:
458         (WebCore::ScratchBuffer::ScratchBuffer):
459         (WebCore::ScratchBuffer::timerFired):
460         * platform/graphics/avfoundation/MediaSelectionGroupAVFObjC.h:
461         * platform/graphics/avfoundation/MediaSelectionGroupAVFObjC.mm:
462         (WebCore::MediaSelectionGroupAVFObjC::MediaSelectionGroupAVFObjC):
463         (WebCore::MediaSelectionGroupAVFObjC::selectionTimerFired):
464         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
465         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
466         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::MediaPlayerPrivateMediaSourceAVFObjC):
467         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekTimerFired):
468         * platform/graphics/ca/LayerPool.cpp:
469         (WebCore::LayerPool::LayerPool):
470         (WebCore::LayerPool::pruneTimerFired):
471         * platform/graphics/ca/LayerPool.h:
472         * platform/graphics/ca/TileController.cpp:
473         (WebCore::TileController::TileController):
474         (WebCore::TileController::tileRevalidationTimerFired):
475         * platform/graphics/ca/TileController.h:
476         * platform/graphics/ca/TileGrid.cpp:
477         (WebCore::TileGrid::TileGrid):
478         (WebCore::TileGrid::cohortRemovalTimerFired):
479         * platform/graphics/ca/TileGrid.h:
480         * platform/graphics/cg/IOSurfacePool.cpp:
481         (WebCore::IOSurfacePool::IOSurfacePool):
482         (WebCore::IOSurfacePool::collectionTimerFired):
483         * platform/graphics/cg/IOSurfacePool.h:
484         * platform/graphics/cg/SubimageCacheWithTimer.cpp:
485         (WebCore::SubimageCacheWithTimer::SubimageCacheWithTimer):
486         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
487         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
488         (WebCore::MediaPlayerPrivateQTKit::MediaPlayerPrivateQTKit):
489         (WebCore::MediaPlayerPrivateQTKit::seekTimerFired):
490         * platform/ios/LegacyTileCache.h:
491         * platform/ios/LegacyTileCache.mm:
492         (WebCore::LegacyTileCache::LegacyTileCache):
493         (WebCore::LegacyTileCache::tileCreationTimerFired):
494         * platform/mac/HIDGamepadProvider.cpp:
495         (WebCore::HIDGamepadProvider::HIDGamepadProvider):
496         (WebCore::HIDGamepadProvider::connectionDelayTimerFired):
497         (WebCore::HIDGamepadProvider::inputNotificationTimerFired):
498         * platform/mac/HIDGamepadProvider.h:
499         * platform/mac/ScrollAnimatorMac.h:
500         * platform/mac/ScrollAnimatorMac.mm:
501         (WebCore::ScrollAnimatorMac::ScrollAnimatorMac):
502         (WebCore::ScrollAnimatorMac::snapRubberBandTimerFired):
503         (WebCore::ScrollAnimatorMac::initialScrollbarPaintTimerFired):
504         (WebCore::ScrollAnimatorMac::sendContentAreaScrolledTimerFired):
505         * platform/mock/DeviceOrientationClientMock.cpp:
506         (WebCore::DeviceOrientationClientMock::DeviceOrientationClientMock):
507         (WebCore::DeviceOrientationClientMock::timerFired):
508         * platform/mock/DeviceOrientationClientMock.h:
509         * platform/mock/PlatformSpeechSynthesizerMock.cpp:
510         (WebCore::PlatformSpeechSynthesizerMock::PlatformSpeechSynthesizerMock):
511         (WebCore::PlatformSpeechSynthesizerMock::speakingFinished):
512         * platform/mock/PlatformSpeechSynthesizerMock.h:
513         * platform/network/DNSResolveQueue.cpp:
514         (WebCore::DNSResolveQueue::DNSResolveQueue):
515         (WebCore::DNSResolveQueue::timerFired):
516         * platform/network/DNSResolveQueue.h:
517         * platform/network/NetworkStateNotifier.h:
518         * platform/network/ResourceHandle.cpp:
519         (WebCore::ResourceHandle::failureTimerFired):
520         * platform/network/ResourceHandle.h:
521         * platform/network/ResourceHandleInternal.h:
522         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
523         * platform/network/mac/NetworkStateNotifierMac.cpp:
524         (WebCore::NetworkStateNotifier::networkStateChangeTimerFired):
525         (WebCore::NetworkStateNotifier::NetworkStateNotifier):
526         * rendering/ImageQualityController.cpp:
527         (WebCore::ImageQualityController::ImageQualityController):
528         (WebCore::ImageQualityController::highQualityRepaintTimerFired):
529         * rendering/ImageQualityController.h:
530         * rendering/RenderButton.cpp:
531         (WebCore::RenderButton::styleDidChange):
532         (WebCore::RenderButton::timerFired):
533         * rendering/RenderButton.h:
534         * rendering/RenderLayerCompositor.cpp:
535         (WebCore::RenderLayerCompositor::RenderLayerCompositor):
536         (WebCore::RenderLayerCompositor::updateCompositingLayersTimerFired):
537         (WebCore::RenderLayerCompositor::layerFlushTimerFired):
538         (WebCore::RenderLayerCompositor::paintRelatedMilestonesTimerFired):
539         * rendering/RenderLayerCompositor.h:
540         * rendering/RenderMarquee.cpp:
541         (WebCore::RenderMarquee::RenderMarquee):
542         (WebCore::RenderMarquee::timerFired):
543         * rendering/RenderMarquee.h:
544         * rendering/RenderNamedFlowThread.cpp:
545         (WebCore::RenderNamedFlowThread::RenderNamedFlowThread):
546         (WebCore::RenderNamedFlowThread::regionOversetChangeEventTimerFired):
547         * rendering/RenderNamedFlowThread.h:
548         * rendering/RenderProgress.cpp:
549         (WebCore::RenderProgress::RenderProgress):
550         (WebCore::RenderProgress::animationTimerFired):
551         * rendering/RenderProgress.h:
552         * rendering/RenderView.cpp:
553         (WebCore::RenderView::RenderView):
554         (WebCore::RenderView::lazyRepaintTimerFired):
555         * rendering/RenderView.h:
556         * replay/EventLoopInputDispatcher.cpp:
557         (WebCore::EventLoopInputDispatcher::EventLoopInputDispatcher):
558         (WebCore::EventLoopInputDispatcher::timerFired):
559         * replay/EventLoopInputDispatcher.h:
560         * storage/StorageAreaImpl.cpp:
561         (WebCore::StorageAreaImpl::StorageAreaImpl):
562         (WebCore::StorageAreaImpl::closeDatabaseTimerFired):
563         (WebCore::StorageAreaImpl::closeDatabaseIfIdle):
564         * storage/StorageAreaImpl.h:
565         * storage/StorageAreaSync.cpp:
566         (WebCore::StorageAreaSync::StorageAreaSync):
567         (WebCore::StorageAreaSync::scheduleFinalSync):
568         (WebCore::StorageAreaSync::syncTimerFired):
569         (WebCore::StorageAreaSync::scheduleSync):
570         * storage/StorageAreaSync.h:
571         * svg/SVGElement.cpp:
572         (WebCore::SVGElement::svgLoadEventTimerFired):
573         * svg/SVGElement.h:
574         * svg/SVGScriptElement.cpp:
575         (WebCore::SVGScriptElement::SVGScriptElement):
576         * svg/SVGStyleElement.cpp:
577         (WebCore::SVGStyleElement::SVGStyleElement):
578         * svg/SVGUseElement.cpp:
579         (WebCore::SVGUseElement::SVGUseElement):
580         * svg/animation/SMILTimeContainer.cpp:
581         (WebCore::SMILTimeContainer::SMILTimeContainer):
582         (WebCore::SMILTimeContainer::timerFired):
583         * svg/animation/SMILTimeContainer.h:
584         * xml/XMLHttpRequestProgressEventThrottle.cpp:
585         (WebCore::XMLHttpRequestProgressEventThrottle::XMLHttpRequestProgressEventThrottle):
586         (WebCore::XMLHttpRequestProgressEventThrottle::dispatchDeferredEvents):
587         * xml/XMLHttpRequestProgressEventThrottle.h:
588
589 2014-11-21  Chris Dumez  <cdumez@apple.com>
590
591         Crash when setting 'transition-delay' CSS property to a calculated value
592         https://bugs.webkit.org/show_bug.cgi?id=138784
593
594         Reviewed by Sam Weinig.
595
596         Update CSSPrimitiveValue::computeTime() to use primitiveType() instead
597         of m_primitiveUnitType so that it properly handles calculated values.
598         Without this, we would hit the ASSERT_NOT_REACHED() assertion in
599         computeTime() for calculated values.
600
601         Test: fast/css/transition-delay-calculated-value.html
602
603         * css/CSSPrimitiveValue.h:
604         (WebCore::CSSPrimitiveValue::computeTime):
605
606 2014-11-21  Chris Dumez  <cdumez@apple.com>
607
608         Regression(r175381): -webkit-mask-box-image is broken
609         https://bugs.webkit.org/show_bug.cgi?id=138969
610         <rdar://problem/19054471>
611
612         Reviewed by Simon Fraser.
613
614         After r175381, the StyleBuilder would call NinePieceImage::setMaskDefaults()
615         *after* calling CSSToStyleMap::mapNinePieceImage(), instead of *before*, for
616         -webkit-mask-box-image CSS property. This was causing the mask defaults to
617         overwrite what was set by mapNinePieceImage().
618
619         Test: fast/css/webkit-mask-box-image.html
620
621         * css/StyleBuilderConverter.h:
622         (WebCore::StyleBuilderConverter::convertBorderMask):
623
624 2014-11-21  Chris Dumez  <cdumez@apple.com>
625
626         Crash when setting 'font' CSS property to 'calc(2 * 3)'
627         https://bugs.webkit.org/show_bug.cgi?id=138933
628
629         Reviewed by Darin Adler.
630
631         The CSS Parser was not handling calculated values when parsing the font
632         weight. This would lead us to hit an assertion when parsing a font
633         property whose weight is set to a calculated value.
634
635         This patch updates parseFontWeight() to properly handle calculated
636         values.
637
638         Test: fast/css/font-calculated-value.html
639
640         * css/CSSParser.cpp:
641         (WebCore::CSSParser::parseFontWeight):
642
643 2014-11-21  Bear Travis  <betravis@gmail.com>
644
645         [CSS Font Loading] Switch to dispatching events asynchronously
646         https://bugs.webkit.org/show_bug.cgi?id=138755
647
648         Reviewed by Simon Fraser.
649
650         Moving FontLoader to dispatch events and notify callbacks similarly
651         to EventSender or the GenericEventQueue. Several bugs have popped
652         up in the past because FontLoader has been sending events during
653         layout, and there is no need for that to be the case.
654
655         Covered by existing font loader event tests. Added an additional
656         test for the svg case, fontloader-svg-select.
657
658         * css/FontLoader.cpp:
659         (WebCore::FontLoader::didLayout):
660         (WebCore::FontLoader::timerFired): Adding asynchronous callback.
661         (WebCore::FontLoader::scheduleEvent): Add an event to the dispatch
662         queue.
663         (WebCore::FontLoader::firePendingEvents): Modified to handle the
664         loading done event and callbacks.
665         (WebCore::FontLoader::loadingDone): Modified to spin up the timer
666         rather than immediately dispatching events.
667         * css/FontLoader.h:
668
669 2014-11-21  Daniel Bates  <dabates@apple.com>
670
671         Attempt to fix the internal Apple Mavericks build after <https://trac.webkit.org/changeset/176448>
672         (https://bugs.webkit.org/show_bug.cgi?id=138930)
673
674         Declare NSCachedURLResponse SPI when building without the Apple Internal SDK and with the Apple
675         Internal SDK when building for OS X Mavericks or earlier.
676
677         * platform/spi/cf/CFNetworkSPI.h:
678
679 2014-11-21  Anders Carlsson  <andersca@apple.com>
680
681         Make memoryCache() return a reference
682         https://bugs.webkit.org/show_bug.cgi?id=138939
683
684         Reviewed by Antti Koivisto.
685
686         * inspector/InspectorPageAgent.cpp:
687         (WebCore::InspectorPageAgent::cachedResource):
688         * inspector/InspectorResourceAgent.cpp:
689         (WebCore::InspectorResourceAgent::replayXHR):
690         (WebCore::InspectorResourceAgent::setCacheDisabled):
691         (WebCore::InspectorResourceAgent::mainFrameNavigated):
692         * loader/DocumentLoader.cpp:
693         (WebCore::areAllLoadersPageCacheAcceptable):
694         (WebCore::DocumentLoader::finishedLoading):
695         (WebCore::DocumentLoader::responseReceived):
696         * loader/FrameLoader.cpp:
697         (WebCore::FrameLoader::tellClientAboutPastMemoryCacheLoads):
698         * loader/SubresourceLoader.cpp:
699         (WebCore::SubresourceLoader::willSendRequest):
700         (WebCore::SubresourceLoader::didReceiveResponse):
701         (WebCore::SubresourceLoader::didFail):
702         (WebCore::SubresourceLoader::willCancel):
703         * loader/archive/cf/LegacyWebArchive.cpp:
704         (WebCore::LegacyWebArchive::create):
705         * loader/cache/CachedImage.cpp:
706         (WebCore::CachedImage::addIncrementalDataBuffer):
707         (WebCore::CachedImage::finishLoading):
708         * loader/cache/CachedResource.cpp:
709         (WebCore::deadDecodedDataDeletionIntervalForResourceType):
710         (WebCore::CachedResource::~CachedResource):
711         (WebCore::CachedResource::failBeforeStarting):
712         (WebCore::CachedResource::addClientToSet):
713         (WebCore::CachedResource::removeClient):
714         (WebCore::CachedResource::destroyDecodedDataIfNeeded):
715         (WebCore::CachedResource::setDecodedSize):
716         (WebCore::CachedResource::setEncodedSize):
717         (WebCore::CachedResource::didAccessDecodedData):
718         * loader/cache/CachedResourceLoader.cpp:
719         (WebCore::CachedResourceLoader::requestUserCSSStyleSheet):
720         (WebCore::CachedResourceLoader::requestResource):
721         (WebCore::CachedResourceLoader::revalidateResource):
722         (WebCore::CachedResourceLoader::loadResource):
723         (WebCore::CachedResourceLoader::clearPreloads):
724         (WebCore::CachedResourceLoader::printPreloadStats):
725         * loader/cache/MemoryCache.cpp:
726         (WebCore::memoryCache):
727         (WebCore::MemoryCache::removeRequestFromCache):
728         (WebCore::MemoryCache::removeRequestFromSessionCaches):
729         * loader/cache/MemoryCache.h:
730         * loader/cocoa/DiskCacheMonitorCocoa.mm:
731         (WebCore::DiskCacheMonitor::resourceBecameFileBacked):
732         * page/FrameView.cpp:
733         (WebCore::FrameView::willPaintContents):
734         (WebCore::FrameView::didPaintContents):
735         * platform/MemoryPressureHandler.cpp:
736         (WebCore::MemoryPressureHandler::releaseCriticalMemory):
737         * testing/Internals.cpp:
738         (WebCore::Internals::isLoadingFromMemoryCache):
739
740 2014-11-21  Daniel Bates  <dabates@apple.com>
741
742         [iOS] WebKit2 fails to build with public SDK due to missing SPI from CFNetwork, QuartzCore, MediaPlayer, XPC
743         https://bugs.webkit.org/show_bug.cgi?id=138930
744
745         Reviewed by Anders Carlsson.
746
747         * WebCore.xcodeproj/project.pbxproj: Rename header MPAVRoutingControllerSPI.h to MediaPlayerSPI.h.
748         * loader/cocoa/SubresourceLoaderCocoa.mm: Move NSCachedURLResponse forward declarations to file
749         CFNetworkSPI.h and include header CFNetworkSPI.h.
750         * loader/mac/ResourceLoaderMac.mm: Ditto.
751         * platform/audio/ios/MediaSessionManagerIOS.mm: Substitute MediaPlayerSPI.h for MPAVRoutingControllerSPI.h.
752         * platform/spi/cf/CFNetworkSPI.h: Add more SPI.
753         * platform/spi/cg/CoreGraphicsSPI.h: Ditto.
754         * platform/spi/cocoa/QuartzCoreSPI.h: Ditto.
755         * platform/spi/ios/MediaPlayerSPI.h: Renamed from Source/WebCore/platform/spi/ios/MPAVRoutingControllerSPI.h.
756
757 2014-11-21  Chris Fleizach  <cfleizach@apple.com>
758
759         AX: MathML expressions are misread by VoiceOver
760         https://bugs.webkit.org/show_bug.cgi?id=138948
761
762         Reviewed by Mario Sanchez Prada.
763
764         The logic for deciding what's the radicand and an index was too tied to children placement.
765         We should instead pull directly from the source.
766
767         Test: platform/mac/accessibility/mathml-root.html
768
769         * accessibility/AccessibilityRenderObject.cpp:
770         (WebCore::AccessibilityRenderObject::mathRadicandObject):
771         (WebCore::AccessibilityRenderObject::mathRootIndexObject):
772         * rendering/mathml/RenderMathMLRoot.h:
773
774 2014-11-20  Benjamin Poulain  <bpoulain@apple.com>
775
776         Remove the remaining vestiges of minimal-ui
777         https://bugs.webkit.org/show_bug.cgi?id=138890
778
779         Reviewed by Sam Weinig.
780
781         In ViewportArguments' setViewportFeature(), I skip the warning for now.
782
783         * WebCore.exp.in:
784         * dom/ViewportArguments.cpp:
785         (WebCore::setViewportFeature):
786         * dom/ViewportArguments.h:
787         (WebCore::ViewportArguments::ViewportArguments):
788         (WebCore::ViewportArguments::operator==):
789         * page/ViewportConfiguration.cpp:
790         (WebCore::ViewportConfiguration::ViewportConfiguration):
791         (WebCore::ViewportConfiguration::initialScale):
792         (WebCore::ViewportConfiguration::minimumScale):
793         (WebCore::ViewportConfiguration::updateConfiguration):
794         (WebCore::ViewportConfiguration::viewportArgumentsLength):
795         (WebCore::ViewportConfiguration::layoutWidth):
796         (WebCore::ViewportConfiguration::layoutHeight):
797         (WebCore::ViewportConfigurationTextStream::operator<<):
798         (WebCore::ViewportConfiguration::description):
799         (WebCore::ViewportConfiguration::setMinimumLayoutSizeForMinimalUI): Deleted.
800         (WebCore::ViewportConfiguration::activeMinimumLayoutSizeInScrollViewCoordinates): Deleted.
801         (WebCore::ViewportConfiguration::resetMinimalUI): Deleted.
802         (WebCore::ViewportConfiguration::didFinishDocumentLoad): Deleted.
803         * page/ViewportConfiguration.h:
804         (WebCore::ViewportConfiguration::minimumLayoutSizeForMinimalUI): Deleted.
805         (WebCore::ViewportConfiguration::usesMinimalUI): Deleted.
806
807 2014-11-20  Benjamin Poulain  <benjamin@webkit.org>
808
809         Web Inspector: do not show invalid specificity for dynamic cases of :matches()
810         https://bugs.webkit.org/show_bug.cgi?id=138911
811
812         Reviewed by Joseph Pecoraro.
813
814         * css/CSSSelector.cpp:
815         (WebCore::simpleSelectorFunctionalPseudoClassStaticSpecificity):
816         (WebCore::functionalPseudoClassStaticSpecificity):
817         (WebCore::staticSpecificityInternal):
818         (WebCore::CSSSelector::staticSpecificity):
819         (WebCore::CSSSelector::specificity): Deleted.
820         * css/CSSSelector.h:
821         Add an additional computation path for the inspector.
822
823         The regular path ignores everything inside function pseudo classes.
824         This new path takes the static specificity of the regular path, then evaluate
825         recursively all the selector lists inside any level of :matches().
826
827         If two complex selector of selector list do not have the same specificity,
828         we bail out and refuse to compute a static specificity representing the selector.
829
830         * inspector/InspectorStyleSheet.cpp:
831         (WebCore::buildObjectForSelectorHelper):
832         (WebCore::selectorsFromSource):
833         (WebCore::InspectorStyleSheet::buildObjectForSelector):
834         Do not add the complexity to the inspector's CSSSelector structure whenever
835         it is dynamic.
836
837 2014-11-20  Benjamin Poulain  <bpoulain@apple.com>
838
839         Remove InspectorCSSAgent::buildArrayForRuleList()
840         https://bugs.webkit.org/show_bug.cgi?id=138907
841
842         Reviewed by Andreas Kling.
843
844         * inspector/InspectorCSSAgent.cpp:
845         (WebCore::InspectorCSSAgent::buildArrayForRuleList): Deleted.
846         * inspector/InspectorCSSAgent.h:
847
848 2014-11-20  Zalan Bujtas  <zalan@apple.com>
849
850         REGRESSION (174986): CSS clip property is ignored when border-radius is present.
851         https://bugs.webkit.org/show_bug.cgi?id=138935
852         rdar://problem/18965984
853
854         Reviewed by Simon Fraser.
855
856         Revert back to r163382 and fix bug 127729 properly. Save the graphics context when paint and clip rects are
857         the same, but the clip rect has radius.
858         Each iteration on ::clipRect() from r163382 onwards just introduced yet another regression.
859
860         Test: fast/clip/css-clip-does-not-work-when-border-radius-is-present.html
861
862         * rendering/RenderLayer.cpp:
863         (WebCore::RenderLayer::clipToRect):
864
865 2014-11-20  Geoffrey Garen  <ggaren@apple.com>
866
867         Removed the custom allocator for PODRedBlackTree
868         https://bugs.webkit.org/show_bug.cgi?id=138942
869
870         Reviewed by Sam Weinig.
871
872         bmalloc is fast enough.
873
874         * WebCore.xcodeproj/project.pbxproj:
875         * platform/PODArena.h: Removed.
876         * platform/PODFreeListArena.h: Removed. This is the point of the patch.
877
878         * platform/PODIntervalTree.h:
879         (WebCore::PODIntervalTree::PODIntervalTree): Deleted. As a side effect
880         of removing our custom allocator, we can no longer have a special
881         "I'm not initialized yet" state. Instead, the tree either exists or not,
882         like an idiomatic C++ object.
883
884         * platform/PODRedBlackTree.h:
885         (WebCore::PODRedBlackTree::PODRedBlackTree): Ditto.
886
887         (WebCore::PODRedBlackTree::~PODRedBlackTree): We need to clear in our
888         destructor because we can no longer rely on the arena destructor
889         implicitly freeing our tree nodes.
890
891         Side note: This change basically removes the whole reason for having
892         a purpose-built tree for POD data. We should probably remove this whole
893         data structure in a follow-up patch, and just use a standard tree.
894
895         (WebCore::PODRedBlackTree::clear):
896         (WebCore::PODRedBlackTree::add):
897         (WebCore::PODRedBlackTree::remove):
898         (WebCore::PODRedBlackTree::contains):
899         (WebCore::PODRedBlackTree::visitInorder):
900         (WebCore::PODRedBlackTree::size):
901         (WebCore::PODRedBlackTree::checkInvariants):
902         (WebCore::PODRedBlackTree::dump):
903         (WebCore::PODRedBlackTree::deleteNode):
904         (WebCore::PODRedBlackTree::markFree): Use normal new/delete, and mark
905         ourselves as fast allocated so we get the bmalloc goodness.
906
907         (WebCore::PODRedBlackTree::isInitialized): Deleted.
908         (WebCore::PODRedBlackTree::initIfNeeded): Deleted.
909
910         * rendering/FloatingObjects.cpp:
911         (WebCore::FloatingObjects::findNextFloatLogicalBottomBelow):
912         (WebCore::FloatingObjects::findNextFloatLogicalBottomBelowForBlock):
913         (WebCore::FloatingObjects::FloatingObjects):
914         (WebCore::FloatingObjects::clear):
915         (WebCore::FloatingObjects::addPlacedObject):
916         (WebCore::FloatingObjects::removePlacedObject):
917         (WebCore::FloatingObjects::computePlacedFloatsTree):
918         (WebCore::FloatingObjects::placedFloatsTree):
919         (WebCore::FloatingObjects::logicalLeftOffsetForPositioningFloat):
920         (WebCore::FloatingObjects::logicalRightOffsetForPositioningFloat):
921         (WebCore::FloatingObjects::logicalLeftOffset):
922         (WebCore::FloatingObjects::logicalRightOffset): POD tree had a slightly
923         weird behavior in which it was valid to use some of its APIs without
924         first initializing it, but not others. It's not really possible to model
925         that behavior with normal C++ objects that use new/delete, so instead
926         I added some explicit NULL checks.
927
928         * rendering/FloatingObjects.h:
929         * rendering/RenderFlowThread.cpp:
930         (WebCore::RenderFlowThread::updateRegionsFlowThreadPortionRect):
931         * rendering/RenderView.cpp:
932         (WebCore::RenderView::intervalArena): Deleted.
933         * rendering/RenderView.h: Removed custom-allocator-related cruft.
934
935 2014-11-20  Dean Jackson  <dino@apple.com>
936
937         Support unprefixed animation event types
938         https://bugs.webkit.org/show_bug.cgi?id=138931
939         <rdar://problem/18943167>
940
941         Reviewed by Simon Fraser.
942
943         Tests: animations/unprefixed-events-mixed-with-prefixed.html
944                animations/unprefixed-events.html
945
946         Support the unprefixed animation event names:
947         - animationstart (was webkitAnimationStart)
948         - animationiteration (was webkitAnimationIteration)
949         - animationend (was webkitAnimationEnd)
950
951         (Yes, event types are case sensitive and yes, this will
952         likely cause some head-scratching as people change content)
953
954         The approach here is to follow what transitions does:
955         - listener only for old event name -> fire old event name
956         - listener for both old and new event name -> fire new event name
957         - listener only for new event name -> fire new event name
958
959         That way pages that were trying to anticipate the new event name
960         won't get duplicate events.
961
962         * CMakeLists.txt: Add new AnimationEvent* stuff.
963         * DerivedSources.make: Ditto.
964         * WebCore.vcxproj/WebCore.vcxproj: Ditto.
965         * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
966         * WebCore.xcodeproj/project.pbxproj: Ditto.
967
968         * bindings/js/JSBindingsAllInOne.cpp: New files for all in one builds.
969         * dom/DOMAllInOne.cpp:
970
971         * dom/AnimationEvent.cpp: Added. Copied from WebKitAnimationEvent.cpp.
972         (WebCore::AnimationEventInit::AnimationEventInit):
973         (WebCore::AnimationEvent::AnimationEvent):
974         (WebCore::AnimationEvent::~AnimationEvent):
975         (WebCore::AnimationEvent::animationName):
976         (WebCore::AnimationEvent::elapsedTime):
977         (WebCore::AnimationEvent::eventInterface):
978         * dom/AnimationEvent.h: Added. Copied from WebKitAnimationEvent.h.
979         * dom/AnimationEvent.idl: Added. Copied from WebKitAnimationEvent.idl.
980
981         * dom/Document.cpp:
982         (WebCore::Document::addListenerTypeIfNeeded): Handle new event types.
983
984         * dom/EventNames.h: New names.
985         * dom/EventNames.in:
986
987         * dom/EventTarget.cpp:
988         (WebCore::legacyType): Provide a mapping from the new names to the older
989         prefixed forms.
990
991         * html/HTMLAttributeNames.in: Support the on* attributes, even though I
992         hate them and wish this approach would die.
993         * html/HTMLElement.cpp:
994         (WebCore::HTMLElement::populateEventNameForAttributeLocalNameMap):
995
996         * page/DOMWindow.h: New names, and constructors.
997         * page/DOMWindow.idl:
998
999         * page/animation/AnimationController.cpp:
1000         (WebCore::AnimationControllerPrivate::fireEventsAndUpdateStyle): Fire new type.
1001
1002         * page/animation/KeyframeAnimation.cpp: Fire the new types of events.
1003         (WebCore::KeyframeAnimation::onAnimationStart):
1004         (WebCore::KeyframeAnimation::onAnimationIteration):
1005         (WebCore::KeyframeAnimation::onAnimationEnd):
1006         (WebCore::KeyframeAnimation::sendAnimationEvent):
1007
1008 2014-11-20  Tim Horton  <timothy_horton@apple.com>
1009
1010         Remove a piece of DataDetectors SPI that we aren't using anymore
1011         https://bugs.webkit.org/show_bug.cgi?id=138917
1012
1013         Reviewed by Beth Dakin.
1014
1015         * platform/spi/mac/DataDetectorsSPI.h:
1016
1017 2014-11-20  Beth Dakin  <bdakin@apple.com>
1018
1019         Invalid message WebPageProxy.DidPerformDictionaryLookup on Google stocks result
1020         https://bugs.webkit.org/show_bug.cgi?id=138568
1021         -and corresponding-
1022         rdar://problem/18904600
1023
1024         Reviewed by Tim Horton.
1025
1026         Add an optional parameter indicating whether or not to include images.
1027         * WebCore.exp.in:
1028         * editing/cocoa/HTMLConverter.h:
1029         * editing/cocoa/HTMLConverter.mm:
1030         (WebCore::editingAttributedStringFromRange):
1031
1032 2014-11-20  Myles C. Maxfield  <mmaxfield@apple.com>
1033
1034         Fix the !ENABLE(SVG_FONTS) build after r176276
1035         https://bugs.webkit.org/show_bug.cgi?id=138924
1036
1037         Reviewed by Csaba Osztrogon√°c.
1038
1039         No new tests because there is no behavior change.
1040
1041         * css/CSSFontFaceSource.cpp:
1042         (WebCore::CSSFontFaceSource::getFontData):
1043         * loader/cache/CachedResourceLoader.cpp:
1044         (WebCore::CachedResourceLoader::requestFont):
1045
1046 2014-11-19  Ada Chan  <adachan@apple.com>
1047
1048         Add a way to mute an AudioContext.
1049         https://bugs.webkit.org/show_bug.cgi?id=138104
1050
1051         Reviewed by Eric Carlson.
1052
1053         Keep a muted state in AudioDestinationNode. If m_muted is true,
1054         zero out the audio buffers.
1055
1056         No new tests, since it's difficult to test whether the audio is indeed muted.
1057
1058         * Modules/webaudio/AudioContext.cpp:
1059         (WebCore::AudioContext::AudioContext):
1060         Call pageMutedStateDidChange() so it'll initialize the destination audio node's muted state accordingly.
1061         (WebCore::AudioContext::pageMutedStateDidChange):
1062         Set the destination audio node's muted state to match the page's muted state.
1063
1064         * Modules/webaudio/AudioDestinationNode.cpp:
1065         (WebCore::AudioDestinationNode::AudioDestinationNode):
1066         Initialize m_muted.
1067         (WebCore::AudioDestinationNode::render):
1068         If m_muted is true, call AudioBus::zero() to zero out the buffers.
1069         * Modules/webaudio/AudioDestinationNode.h:
1070         (WebCore::AudioDestinationNode::setMuted):
1071         Set m_muted.
1072
1073 2014-11-20  Chris Dumez  <cdumez@apple.com>
1074
1075         Crash when destroying a Document that has a throttled timer still running
1076         https://bugs.webkit.org/show_bug.cgi?id=138914
1077
1078         Reviewed by Benjamin Poulain.
1079
1080         Upon destruction, a throttled DOMTimer whose interval depends on
1081         viewport changes will try to unregister itself from the view. It gets
1082         the view pointer from its Document. However, scriptExecutionContext()
1083         can return null if the Document is being destroyed (i.e. ~DOMTimer()
1084         is called from ~ScriptExecutionContext(), as the ScriptExecutionContext
1085         owns the DOMTimer).
1086
1087         This patch adds a null check for scriptExecutionContext() in the
1088         DOMTimer destructor to avoid this issue.
1089
1090         Test: fast/dom/throttled-timer-running-on-document-destruction.html
1091
1092         * page/DOMTimer.cpp:
1093         (WebCore::DOMTimer::~DOMTimer):
1094
1095         (WebCore::DOMTimer::unregisterForViewportChanges):
1096         Add assertion to make sure scriptExecutionContext() does not return
1097         null.
1098
1099         (WebCore::DOMTimerFireState::setChangedStyleOfElementOutsideViewport): Deleted.
1100         Killed this function as this was dead code.
1101
1102 2014-11-20  Zalan Bujtas  <zalan@apple.com>
1103
1104         Simple line layout: Introduce text fragment continuation.
1105         https://bugs.webkit.org/show_bug.cgi?id=138274
1106
1107         This patch extends simple line layout coverage to multiple text renderers.
1108         When a particular render flow has multiple text renderers (but not any other type)
1109         then we use simple line layout to process and paint the content. -other, existing requirements still apply
1110         so that for example if the content requires decoration, we bail out of simple line layout.
1111
1112         FlowContent now supports multiple renderes. It continuously reads content from sibling renderers
1113         so that the simple line layout parser sees it as one monolithic block of content. Run positions
1114         are all relative to the block and they get resolved to renderer's positions on demand.
1115         (painting, computing bounding rects etc)
1116
1117         Reviewed by Antti Koivisto.
1118
1119         Performance test already been added for the multiple rendere use case,
1120         correctness is covered by existing test cases.
1121         Test: fast/text/simple-lines-mutliple-renderers.html
1122
1123         * rendering/SimpleLineLayout.cpp:
1124         (WebCore::SimpleLineLayout::canUseFor): Check if children are all 8bit RenderTexts.
1125         (WebCore::SimpleLineLayout::removeTrailingWhitespace): Move the endofline check right before where we might overflow using end position.
1126         (WebCore::SimpleLineLayout::initializeNewLine):
1127         (WebCore::SimpleLineLayout::closeLineEndingAndAdjustRuns):
1128         (WebCore::SimpleLineLayout::splitRunsAtRendererBoundary): Split runs at renderers' boundary to be in sync with inline text renderering.
1129         (WebCore::SimpleLineLayout::createTextRuns):
1130         (WebCore::SimpleLineLayout::create):
1131         * rendering/SimpleLineLayoutFlowContents.cpp:
1132         (WebCore::SimpleLineLayout::FlowContents::FlowContents):
1133         (WebCore::SimpleLineLayout::FlowContents::findNextBreakablePosition):
1134         (WebCore::SimpleLineLayout::FlowContents::findNextNonWhitespacePosition):
1135         (WebCore::SimpleLineLayout::FlowContents::textWidth): Do not measure text across renderers. It could produce different width value due to
1136         ligature which later can produce unexpected line breaks and out sync rendering in general.
1137         (WebCore::SimpleLineLayout::FlowContents::renderer): 
1138         (WebCore::SimpleLineLayout::FlowContents::resolveRendererPositions):
1139         (WebCore::SimpleLineLayout::FlowContents::appendNextRendererContentIfNeeded): Read the next renderer content if needed.
1140         (WebCore::SimpleLineLayout::FlowContents::nextNonWhitespacePosition):
1141         (WebCore::SimpleLineLayout::FlowContents::runWidth):
1142         * rendering/SimpleLineLayoutFlowContents.h:
1143         (WebCore::SimpleLineLayout::FlowContents::isNewlineCharacter):
1144         (WebCore::SimpleLineLayout::FlowContents::isEndOfContent):
1145         * rendering/SimpleLineLayoutResolver.cpp:
1146         (WebCore::SimpleLineLayout::RunResolver::Run::text):
1147
1148 2014-11-20  Commit Queue  <commit-queue@webkit.org>
1149
1150         Unreviewed, rolling out r176396.
1151         https://bugs.webkit.org/show_bug.cgi?id=138926
1152
1153         revealed some WebCore::BidiResolver issue. rollout this for
1154         now. (Requested by zalan on #webkit).
1155
1156         Reverted changeset:
1157
1158         "Simple line layout: Introduce text fragment continuation."
1159         https://bugs.webkit.org/show_bug.cgi?id=138274
1160         http://trac.webkit.org/changeset/176396
1161
1162 2014-11-20  Zalan Bujtas  <zalan@apple.com>
1163
1164         Simple line layout: Introduce text fragment continuation.
1165         https://bugs.webkit.org/show_bug.cgi?id=138274
1166
1167         This patch extends simple line layout coverage to multiple text renderers.
1168         When a particular render flow has multiple text renderers (but not any other type)
1169         then we use simple line layout to process and paint the content. -other, existing requirements still apply
1170         so that for example if the content requires decoration, we bail out of simple line layout.
1171
1172         FlowContent now supports multiple renderes. It continuously reads content from sibling renderers
1173         so that the simple line layout parser sees it as one monolithic block of content. Run positions
1174         are all relative to the block and they get resolved to renderer's positions on demand.
1175         (painting, computing bounding rects etc)
1176
1177         Reviewed by Antti Koivisto.
1178
1179         Performance test already been added for the multiple rendere use case,
1180         correctness is covered by existing test cases.
1181         Test: fast/text/simple-lines-mutliple-renderers.html
1182
1183         * rendering/SimpleLineLayout.cpp:
1184         (WebCore::SimpleLineLayout::canUseFor): Check if children are all 8bit RenderTexts.
1185         (WebCore::SimpleLineLayout::removeTrailingWhitespace): Move the endofline check right before where we might overflow using end position.
1186         (WebCore::SimpleLineLayout::initializeNewLine):
1187         (WebCore::SimpleLineLayout::closeLineEndingAndAdjustRuns):
1188         (WebCore::SimpleLineLayout::splitRunsAtRendererBoundary): Split runs at renderers' boundary to be in sync with inline text renderering.
1189         (WebCore::SimpleLineLayout::createTextRuns):
1190         (WebCore::SimpleLineLayout::create):
1191         * rendering/SimpleLineLayoutFlowContents.cpp:
1192         (WebCore::SimpleLineLayout::FlowContents::FlowContents):
1193         (WebCore::SimpleLineLayout::FlowContents::findNextBreakablePosition):
1194         (WebCore::SimpleLineLayout::FlowContents::findNextNonWhitespacePosition):
1195         (WebCore::SimpleLineLayout::FlowContents::textWidth): Do not measure text across renderers. It could produce different width value due to
1196         ligature which later can produce unexpected line breaks and out sync renderering in general.
1197         (WebCore::SimpleLineLayout::FlowContents::renderer): 
1198         (WebCore::SimpleLineLayout::FlowContents::resolveRendererPositions):
1199         (WebCore::SimpleLineLayout::FlowContents::appendNextRendererContentIfNeeded): Read the next renderer content if needed.
1200         (WebCore::SimpleLineLayout::FlowContents::nextNonWhitespacePosition):
1201         (WebCore::SimpleLineLayout::FlowContents::runWidth):
1202         * rendering/SimpleLineLayoutFlowContents.h:
1203         (WebCore::SimpleLineLayout::FlowContents::isNewlineCharacter):
1204         (WebCore::SimpleLineLayout::FlowContents::isEndOfContent):
1205         * rendering/SimpleLineLayoutResolver.cpp:
1206         (WebCore::SimpleLineLayout::RunResolver::Run::text):
1207
1208 2014-11-20  peavo@outlook.com  <peavo@outlook.com>
1209
1210         [WinCairo] Compile error when GStreamer is enabled.
1211         https://bugs.webkit.org/show_bug.cgi?id=138925
1212
1213         Reviewed by Philippe Normand.
1214
1215         A guard is missing for an overridden method.
1216
1217         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
1218
1219 2014-11-20  Adrian Perez de Castro  <aperez@igalia.com>
1220
1221         [GTK] Provide convenience API in DOM bindings to post messages to user message handlers
1222         https://bugs.webkit.org/show_bug.cgi?id=138871
1223
1224         Reviewed by Carlos Garcia Campos.
1225
1226         Adds a convenience function in the WebKitGTK+ DOM bindings to post
1227         messages to user message handlers in a way convenient way more
1228         convenient than using the autogenerated bindings.
1229
1230         * bindings/gobject/WebKitDOMCustom.cpp:
1231         (webkit_dom_dom_window_webkit_message_handlers_post_message):
1232         Added new convenience API function to post messages to user message
1233         handlers.
1234         * bindings/gobject/WebKitDOMCustom.h: Ditto.
1235         * bindings/gobject/WebKitDOMCustom.symbols: Ditto.
1236
1237 2014-11-12  Sergio Villar Senin  <svillar@igalia.com>
1238
1239         [CSS Grid Layout] Replace the usage of size_t by unsigned
1240         https://bugs.webkit.org/show_bug.cgi?id=136218
1241
1242         Reviewed by Benjamin Poulain.
1243
1244         In general, size_t should be used for sizes of objects in
1245         memory. We're using it to represent indexes and spans in the
1246         grid. Now that the maximum number of tracks is 1 million, it
1247         should be safe to replace them by unsigned integers.
1248
1249         No new tests as there is no change in functionality.
1250
1251         * css/CSSParser.cpp:
1252         (WebCore::CSSParser::parseGridTrackRepeatFunction):
1253         * css/StyleResolver.cpp:
1254         (WebCore::createImplicitNamedGridLinesFromGridArea):
1255         (WebCore::createGridTrackList):
1256         * rendering/RenderGrid.cpp:
1257         (WebCore::RenderGrid::GridIterator::GridIterator):
1258         (WebCore::RenderGrid::GridIterator::nextGridItem):
1259         (WebCore::RenderGrid::GridIterator::isEmptyAreaEnough):
1260         (WebCore::RenderGrid::GridIterator::nextEmptyGridArea):
1261         (WebCore::RenderGrid::GridSizingData::GridSizingData):
1262         (WebCore::RenderGrid::computeUsedBreadthOfGridTracks):
1263         (WebCore::RenderGrid::gridTrackSize):
1264         (WebCore::RenderGrid::distributeSpaceToTracks):
1265         (WebCore::RenderGrid::tracksAreWiderThanMinTrackBreadth):
1266         (WebCore::RenderGrid::ensureGridSize):
1267         (WebCore::RenderGrid::populateExplicitGridAndOrderIterator):
1268         (WebCore::RenderGrid::createEmptyGridAreaAtSpecifiedPositionsOutsideGrid):
1269         (WebCore::RenderGrid::placeAutoMajorAxisItemOnGrid):
1270         (WebCore::RenderGrid::populateGridPositions):
1271         * rendering/RenderGrid.h:
1272         * rendering/style/GridCoordinate.h:
1273         (WebCore::GridSpan::integerSpan):
1274         * rendering/style/GridResolvedPosition.cpp:
1275         (WebCore::GridResolvedPosition::explicitGridColumnCount):
1276         (WebCore::GridResolvedPosition::explicitGridRowCount):
1277         (WebCore::explicitGridSizeForSide):
1278         (WebCore::GridResolvedPosition::resolveNamedGridLinePositionFromStyle):
1279         (WebCore::GridResolvedPosition::resolveGridPositionFromStyle):
1280         (WebCore::GridResolvedPosition::resolveGridPositionAgainstOppositePosition):
1281         (WebCore::firstNamedGridLineBeforePosition):
1282         (WebCore::GridResolvedPosition::resolveRowStartColumnStartNamedGridLinePositionAgainstOppositePosition):
1283         (WebCore::GridResolvedPosition::resolveRowEndColumnEndNamedGridLinePositionAgainstOppositePosition):
1284         * rendering/style/GridResolvedPosition.h:
1285         (WebCore::GridResolvedPosition::adjustGridPositionForRowEndColumnEndSide):
1286         (WebCore::GridResolvedPosition::adjustGridPositionForSide):
1287         (WebCore::GridResolvedPosition::GridResolvedPosition):
1288         (WebCore::GridResolvedPosition::toInt):
1289         * rendering/style/StyleGridData.h:
1290
1291 2014-11-20  Andreas Kling  <akling@apple.com>
1292
1293         Remove "document has no sibling rules" optimization.
1294         <https://webkit.org/b/138902>
1295
1296         Reviewed by Antti Koivisto.
1297
1298         We were keeping a document-level flag to track whether there are any
1299         sibling rules in any active style sheets.
1300
1301         This information was used to do.. nothing.
1302
1303         * css/StyleResolver.h:
1304         (WebCore::StyleResolver::usesSiblingRules): Deleted.
1305         * dom/DocumentStyleSheetCollection.cpp:
1306         (WebCore::DocumentStyleSheetCollection::DocumentStyleSheetCollection):
1307         (WebCore::DocumentStyleSheetCollection::combineCSSFeatureFlags):
1308         (WebCore::DocumentStyleSheetCollection::resetCSSFeatureFlags):
1309         * dom/DocumentStyleSheetCollection.h:
1310         (WebCore::DocumentStyleSheetCollection::usesSiblingRules): Deleted.
1311         (WebCore::DocumentStyleSheetCollection::setUsesSiblingRulesOverride): Deleted.
1312         * mathml/MathMLMathElement.cpp:
1313         (WebCore::MathMLMathElement::insertedInto): Deleted.
1314         * mathml/MathMLMathElement.h:
1315
1316 2014-11-20  Andreas Kling  <akling@apple.com>
1317
1318         Caret renderer is always a RenderBlock.
1319         <https://webkit.org/b/138912>
1320
1321         Reviewed by Chris Dumez.
1322
1323         Tighten typing in the code that finds and deals with the renderer
1324         used to paint the caret (it's always a RenderBlock.)
1325
1326         * editing/FrameSelection.cpp:
1327         (WebCore::CaretBase::updateCaretRect):
1328         (WebCore::FrameSelection::caretRendererWithoutUpdatingLayout):
1329         (WebCore::DragCaretController::caretRenderer):
1330         (WebCore::repaintCaretForLocalRect):
1331         (WebCore::CaretBase::paintCaret):
1332         * editing/FrameSelection.h:
1333         * editing/VisiblePosition.cpp:
1334         (WebCore::VisiblePosition::absoluteCaretBounds):
1335         * editing/htmlediting.cpp:
1336         (WebCore::rendererForCaretPainting):
1337         (WebCore::localCaretRectInRendererForCaretPainting):
1338         (WebCore::absoluteBoundsForLocalCaretRect):
1339         * editing/htmlediting.h:
1340         * rendering/RenderBlock.cpp:
1341         (WebCore::RenderBlock::paintCaret):
1342
1343 2014-11-20  Antti Koivisto  <antti@apple.com>
1344
1345         REGRESSION (r172854): Web Viewer in FileMaker does not render a Base64 encoded animated-GIF
1346         https://bugs.webkit.org/show_bug.cgi?id=138807
1347         <rdar://problem/18829540>
1348
1349         Reviewed by Simon Fraser.
1350
1351         Animation gets paused because WebKit thinks the GIF is outside of the view.
1352
1353         * page/FrameView.cpp:
1354         (WebCore::FrameView::windowClipRect):
1355
1356         We need to convert to window coordinates in paintsEntireContents mode too so these functions are consistent.
1357         This matters with some WK1 API clients.
1358
1359 2014-11-19  Chris Dumez  <cdumez@apple.com>
1360
1361         Move 'clip' CSS property to the new StyleBuilder
1362         https://bugs.webkit.org/show_bug.cgi?id=138909
1363
1364         Reviewed by Andreas Kling.
1365
1366         Move 'clip' CSS property from DeprecatedStyleBuilder to the new
1367         StyleBuilder by using custom code.
1368
1369         No new tests, no behavior change.
1370
1371         * css/CSSPropertyNames.in:
1372         * css/DeprecatedStyleBuilder.cpp:
1373         (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
1374         (WebCore::ApplyPropertyClip::convertToLength): Deleted.
1375         (WebCore::ApplyPropertyClip::applyInheritValue): Deleted.
1376         (WebCore::ApplyPropertyClip::applyInitialValue): Deleted.
1377         (WebCore::ApplyPropertyClip::applyValue): Deleted.
1378         (WebCore::ApplyPropertyClip::createHandler): Deleted.
1379         * css/StyleBuilderCustom.h:
1380         (WebCore::StyleBuilderFunctions::applyInitialClip):
1381         (WebCore::StyleBuilderFunctions::applyInheritClip):
1382         (WebCore::StyleBuilderFunctions::applyValueClip):
1383
1384 2014-11-19  Ryuan Choi  <ryuan.choi@navercorp.com>
1385
1386         Remove dead code from TiledBackingStore
1387         https://bugs.webkit.org/show_bug.cgi?id=138864
1388
1389         Reviewed by Andreas Kling.
1390
1391         Since r168151, paint() method, m_commitTileUpdatesOnIdleEventLoop and related code are not used.
1392
1393         No new tests, no behavior change.
1394
1395         * platform/graphics/TiledBackingStore.cpp:
1396         (WebCore::TiledBackingStore::TiledBackingStore):
1397         (WebCore::TiledBackingStore::setTileSize):
1398         (WebCore::TiledBackingStore::invalidate):
1399         (WebCore::TiledBackingStore::createTiles):
1400         (WebCore::TiledBackingStore::paint): Deleted.
1401         (WebCore::TiledBackingStore::startTileBufferUpdateTimer): Deleted.
1402         (WebCore::TiledBackingStore::tileBufferUpdateTimerFired): Deleted.
1403         (WebCore::TiledBackingStore::startBackingStoreUpdateTimer): Deleted.
1404         (WebCore::TiledBackingStore::backingStoreUpdateTimerFired): Deleted.
1405         * platform/graphics/TiledBackingStore.h:
1406         (WebCore::TiledBackingStore::setCommitTileUpdatesOnIdleEventLoop): Deleted.
1407
1408 2014-11-19  Andreas Kling  <akling@apple.com>
1409
1410         Remove "document has no ::before and/or ::after rules" optimization.
1411         <https://webkit.org/b/138897>
1412
1413         Reviewed by Antti Koivisto.
1414
1415         This optimization has been dead for a long time, since the default UA
1416         style contains both ::before and ::after rules.
1417
1418         * css/RuleFeature.cpp:
1419         (WebCore::recursivelyCollectFeaturesFromSelector):
1420         (WebCore::RuleFeatureSet::add):
1421         (WebCore::RuleFeatureSet::clear):
1422         * css/RuleFeature.h:
1423         (WebCore::RuleFeatureSet::RuleFeatureSet):
1424         * css/StyleResolver.h:
1425         (WebCore::StyleResolver::usesBeforeAfterRules): Deleted.
1426         * dom/DocumentStyleSheetCollection.cpp:
1427         (WebCore::DocumentStyleSheetCollection::DocumentStyleSheetCollection):
1428         (WebCore::DocumentStyleSheetCollection::combineCSSFeatureFlags):
1429         (WebCore::DocumentStyleSheetCollection::resetCSSFeatureFlags):
1430         * dom/DocumentStyleSheetCollection.h:
1431         (WebCore::DocumentStyleSheetCollection::usesBeforeAfterRules): Deleted.
1432         (WebCore::DocumentStyleSheetCollection::setUsesBeforeAfterRulesOverride): Deleted.
1433         * html/HTMLQuoteElement.cpp:
1434         (WebCore::HTMLQuoteElement::insertedInto): Deleted.
1435         * html/HTMLQuoteElement.h:
1436         * style/StyleResolveTree.cpp:
1437         (WebCore::Style::needsPseudoElement):
1438
1439 2014-11-19  Myles C. Maxfield  <mmaxfield@apple.com>
1440
1441         [OS X] Upright vertical text is completely broken for multi-code-unit codepoints
1442         https://bugs.webkit.org/show_bug.cgi?id=138891
1443
1444         Reviewed by Dan Bernstein.
1445
1446         We were assuming that we can use the string index (in UTF-16) as the glyph
1447         index. This falls down when a single codepoint (and glyph) contians
1448         multiple code units.
1449
1450         Test: platform/mac/fast/text/multiple-codeunit-vertical-upright.html
1451
1452         * platform/graphics/GlyphPage.h:
1453         * platform/graphics/mac/GlyphPageTreeNodeMac.cpp:
1454         (WebCore::GlyphPage::fill):
1455
1456 2014-11-19  Daniel Bates  <dabates@apple.com>
1457
1458         Attempt to fix the Apple Internal Mavericks build after <https://trac.webkit.org/changeset/176347>
1459         (https://bugs.webkit.org/show_bug.cgi?id=136863)
1460
1461         Define enumerator NSHTTPCookieAcceptPolicyExclusivelyFromMainDocumentDomain when building without
1462         the Apple Internal SDK or with the Apple Internal SDK on OS X Mavericks or earlier.
1463
1464         * platform/spi/cf/CFNetworkSPI.h:
1465
1466 2014-11-16  Sam Weinig  <sam@webkit.org>
1467
1468         Move the 'quotes' CSS property to the new StyleBuilder
1469         https://bugs.webkit.org/show_bug.cgi?id=138788
1470
1471         Reviewed by Chris Dumez.
1472
1473         Test: fast/css/content/content-quotes-07.html
1474
1475         * css/CSSParser.cpp:
1476         (WebCore::CSSParser::parseValue):
1477         Fix the parser to only accept none as a valid primitive identifier. Tested in 
1478         the newly added content-quotes-07.html.
1479
1480         * css/CSSPropertyNames.in:
1481         * css/StyleBuilderConverter.h:
1482         (WebCore::StyleBuilderConverter::convertQuotes):
1483         * css/StyleResolver.cpp:
1484         (WebCore::StyleResolver::applyProperty):
1485         Move "quotes" to the new style builder.
1486
1487         * rendering/style/RenderStyle.h:
1488         Add an initialQuotes() function for use in the auto-generated style builder.
1489
1490 2014-11-19  Dean Jackson  <dino@apple.com>
1491
1492         Handle unprefixed @keyframes rule
1493         https://bugs.webkit.org/show_bug.cgi?id=138899
1494         <rdar://problem/18943117>
1495
1496         Reviewed by Simon Fraser.
1497
1498         Support the parsing of unprefixed @keyframes. In
1499         CSSParser, assign the same token identifier to
1500         the prefixed and unprefixed forms. This will
1501         keep compatibility with older content. If a page
1502         has both forms, then whatever comes last will
1503         win (as it does if you had duplicate names of the same
1504         form).
1505
1506         Tests: animations/unprefixed-keyframes-rule.html
1507                animations/unprefixed-keyframes.html
1508
1509         * css/CSSGrammar.y.in: Rename the WEBKIT_KEYFRAME_RULE_SYM symbol to
1510         be KEYFRAME_RULE_SYM. Same with KEYFRAMES_SYM.
1511         * css/CSSParser.cpp:
1512         (WebCore::CSSParser::detectAtToken): Look for the @keyframes style
1513         strings and assign the new token values.
1514
1515 2014-11-19  Andreas Kling  <akling@apple.com>
1516
1517         Move pseudo-style code from RenderObject to RenderElement.
1518         <https://webkit.org/b/138880>
1519
1520         Reviewed by Antti Koivisto.
1521
1522         Migrate get*PseudoStyle() to RenderElement, and the selection color
1523         functions along with them. This gets rid of a DOM ancestor walk in
1524         pseudo style lookup.
1525
1526         Narrow down some argument types to keep things building.
1527
1528         * rendering/RenderBlock.cpp:
1529         (WebCore::RenderBlock::logicalLeftSelectionGap):
1530         (WebCore::RenderBlock::logicalRightSelectionGap):
1531         (WebCore::styleForFirstLetter):
1532         (WebCore::RenderBlock::updateFirstLetterStyle):
1533         (WebCore::RenderBlock::createFirstLetterRenderer):
1534         * rendering/RenderBlock.h:
1535         * rendering/RenderElement.cpp:
1536         (WebCore::RenderElement::getCachedPseudoStyle):
1537         (WebCore::RenderElement::getUncachedPseudoStyle):
1538         (WebCore::RenderElement::selectionColor):
1539         (WebCore::RenderElement::selectionPseudoStyle):
1540         (WebCore::RenderElement::selectionForegroundColor):
1541         (WebCore::RenderElement::selectionEmphasisMarkColor):
1542         (WebCore::RenderElement::selectionBackgroundColor):
1543         * rendering/RenderElement.h:
1544         * rendering/RenderObject.cpp:
1545         (WebCore::RenderObject::selectionBackgroundColor): Deleted.
1546         (WebCore::RenderObject::selectionColor): Deleted.
1547         (WebCore::RenderObject::selectionPseudoStyle): Deleted.
1548         (WebCore::RenderObject::selectionForegroundColor): Deleted.
1549         (WebCore::RenderObject::selectionEmphasisMarkColor): Deleted.
1550         (WebCore::RenderObject::getCachedPseudoStyle): Deleted.
1551         (WebCore::RenderObject::getUncachedPseudoStyle): Deleted.
1552         * rendering/RenderObject.h:
1553         * rendering/RenderText.h:
1554         (WebCore::RenderText::getCachedPseudoStyle):
1555         (WebCore::RenderText::selectionBackgroundColor):
1556         (WebCore::RenderText::selectionForegroundColor):
1557         (WebCore::RenderText::selectionEmphasisMarkColor):
1558         * rendering/svg/SVGInlineTextBox.cpp:
1559         (WebCore::SVGInlineTextBox::paintSelectionBackground):
1560         (WebCore::SVGInlineTextBox::paint):
1561
1562 2014-11-19  Tim Horton  <timothy_horton@apple.com>
1563
1564         Add an optional entry transition (from selection highlight) to TextIndicator
1565         https://bugs.webkit.org/show_bug.cgi?id=138856
1566         <rdar://problem/18840128>
1567
1568         Reviewed by Anders Carlsson.
1569
1570         * WebCore.exp.in:
1571         Add an export.
1572
1573         * platform/spi/cocoa/QuartzCoreSPI.h:
1574         Add some SPI.
1575
1576 2014-11-19  Chris Dumez  <cdumez@apple.com>
1577
1578         Move 'outline-style' CSS property to the new StyleBuilder
1579         https://bugs.webkit.org/show_bug.cgi?id=138882
1580
1581         Reviewed by Sam Weinig.
1582
1583         Move 'outline-style' CSS property from DeprecatedStyleBuilder to the
1584         new StyleBuilder by using custom code.
1585
1586         No new tests, no behavior change.
1587
1588         * css/CSSPropertyNames.in:
1589         * css/DeprecatedStyleBuilder.cpp:
1590         (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
1591         (WebCore::ApplyPropertyDefault::setValue): Deleted.
1592         (WebCore::ApplyPropertyDefault::applyValue): Deleted.
1593         (WebCore::ApplyPropertyDefault::createHandler): Deleted.
1594         (WebCore::ApplyPropertyOutlineStyle::applyInheritValue): Deleted.
1595         (WebCore::ApplyPropertyOutlineStyle::applyInitialValue): Deleted.
1596         (WebCore::ApplyPropertyOutlineStyle::applyValue): Deleted.
1597         (WebCore::ApplyPropertyOutlineStyle::createHandler): Deleted.
1598         * css/StyleBuilderCustom.h:
1599         (WebCore::StyleBuilderFunctions::applyInheritOutlineStyle):
1600         (WebCore::StyleBuilderFunctions::applyInitialOutlineStyle):
1601         (WebCore::StyleBuilderFunctions::applyValueOutlineStyle):
1602
1603 2014-11-19  Joseph Pecoraro  <pecoraro@apple.com>
1604
1605         Web Inspector: JSContext inspection Resource search does not work
1606         https://bugs.webkit.org/show_bug.cgi?id=131252
1607
1608         Reviewed by Timothy Hatcher.
1609
1610         Test: inspector/debugger/search-scripts.html
1611
1612         * inspector/InspectorPageAgent.cpp:
1613         (WebCore::InspectorPageAgent::searchInResources):
1614         A little cleanup.
1615
1616 2014-11-19  Joseph Pecoraro  <pecoraro@apple.com>
1617
1618         Web Inspector: Provide $exception in the console for the thrown exception value
1619         https://bugs.webkit.org/show_bug.cgi?id=138726
1620
1621         Reviewed by Timothy Hatcher.
1622
1623         Tests: inspector/debugger/command-line-api-exception-nested-catch.html
1624                inspector/debugger/command-line-api-exception.html
1625
1626         * inspector/CommandLineAPIModuleSource.js:
1627         Expose $exception in the more complete command line API.
1628
1629 2014-11-19  David Hyatt  <hyatt@apple.com>
1630
1631         Images/replaced elements that are as tall as a page should be on their own page
1632         https://bugs.webkit.org/show_bug.cgi?id=138886 - <rdar://problem/18296371>
1633
1634         Reviewed by Dean Jackson.
1635
1636         Added fast/multicol/tall-image-behavior.html (and RL/LR variants)
1637
1638         * rendering/InlineFlowBox.cpp:
1639         (WebCore::InlineFlowBox::computeReplacedAndTextLineTopAndBottom):
1640         * rendering/InlineFlowBox.h:
1641         Add a new method that computes the line top and line bottom ignoring all margins,
1642         overflow and line-height. This allows us to see if a line that is taller than a page
1643         can be made to fit if we ignored margins and unused descent.
1644
1645         * rendering/RenderBlockFlow.cpp:
1646         (WebCore::RenderBlockFlow::adjustLinePositionForPagination):
1647         Call the new helper function, computeReplacedAndTextLineTopAndBottom and push
1648         to a new page if we see that we can fit on a page by ourselves without blank space
1649         included.
1650
1651 2014-11-18  Ada Chan  <adachan@apple.com>
1652
1653         Take Web Audio into account for the Page::isPlayingAudio() API.
1654         https://bugs.webkit.org/show_bug.cgi?id=137464
1655
1656         Reviewed by Jer Noble.
1657
1658         Make AudioContext a subclass of AudioProducer. It figures out whether there's
1659         audio playing by checking whether its AudioDestinationNode is playing (and not
1660         silent). It calls Document::updateIsPlayingAudio() whenever its audio playing
1661         state has changed.
1662
1663         Test: webaudio/web-audio-is-playing.html
1664
1665         * Modules/webaudio/AudioContext.cpp:
1666         (WebCore::AudioContext::lazyInitialize):
1667         Add itself to the Document's list of AudioProducers if it's not an offline
1668         audio context.
1669         (WebCore::AudioContext::uninitialize):
1670         Remove itself from the Document's list of AudioProducers if it's not an offline
1671         audio context.
1672         (WebCore::AudioContext::stop):
1673         Tell the document to update its audio playing state.
1674         (WebCore::AudioContext::isPlayingAudio):
1675         Return true if the audio context hasn't been stopped and its destination node is
1676         playing audio.
1677         (WebCore::AudioContext::pageMutedStateDidChange):
1678         Add a FIXME for now.
1679         (WebCore::AudioContext::isPlayingAudioDidChange):
1680         Call Document::updateIsPlayingAudio().
1681         * Modules/webaudio/AudioContext.h:
1682
1683         * Modules/webaudio/AudioDestinationNode.cpp:
1684         (WebCore::AudioDestinationNode::AudioDestinationNode):
1685         Initialize m_isSilent and m_isEffectivelyPlayingAudio.
1686         (WebCore::AudioDestinationNode::render):
1687         Call setIsSilent() with the appropriate value after rendering.
1688         (WebCore::AudioDestinationNode::isPlayingDidChange):
1689         Call updateIsEffectivelyPlayingAudio().
1690         (WebCore::AudioDestinationNode::setIsSilent):
1691         If m_isSilent has changed, call updateIsEffectivelyPlayingAudio().
1692         (WebCore::AudioDestinationNode::updateIsEffectivelyPlayingAudio):
1693         If m_isEffectivelyPlayingAudio has changed, call AudioContext::isPlayingAudioDidChange().
1694         * Modules/webaudio/AudioDestinationNode.h:
1695         (WebCore::AudioDestinationNode::isPlaying):
1696         (WebCore::AudioDestinationNode::isPlayingAudio):
1697
1698         * Modules/webaudio/DefaultAudioDestinationNode.cpp:
1699         (WebCore::DefaultAudioDestinationNode::isPlaying):
1700         Return whether the AudioDestination is playing.
1701         * Modules/webaudio/DefaultAudioDestinationNode.h:
1702
1703         * platform/audio/AudioIOCallback.h:
1704         * platform/audio/ios/AudioDestinationIOS.cpp:
1705         (WebCore::AudioDestinationIOS::start):
1706         Call setIsPlaying() instead.
1707         (WebCore::AudioDestinationIOS::stop):
1708         Ditto.
1709         (WebCore::AudioDestinationIOS::setIsPlaying):
1710         If m_isPlaying has changed, call AudioIOCallback::isPlayingDidChange().
1711         * platform/audio/ios/AudioDestinationIOS.h:
1712
1713         * platform/audio/mac/AudioDestinationMac.cpp:
1714         (WebCore::AudioDestinationMac::start):
1715         Call setIsPlaying() instead.
1716         (WebCore::AudioDestinationMac::stop):
1717         Ditto.
1718         (WebCore::AudioDestinationMac::setIsPlaying):
1719         If m_isPlaying has changed, call AudioIOCallback::isPlayingDidChange().
1720         * platform/audio/mac/AudioDestinationMac.h:
1721
1722         * testing/Internals.cpp:
1723         (WebCore::Internals::isPagePlayingAudio):
1724         * testing/Internals.h:
1725         * testing/Internals.idl:
1726         Add internals.isPagePlayingAudio() for testing.
1727
1728 2014-11-19  Daniel Bates  <dabates@apple.com>
1729
1730         Attempt to fix the Apple Internal Mountain Lion build after <https://trac.webkit.org/changeset/176347>
1731         (https://bugs.webkit.org/show_bug.cgi?id=136863)
1732
1733         Only import header CFNSURLConnection.h when building for iOS or OS X Yosemite.
1734
1735         * platform/spi/cf/CFNetworkSPI.h:
1736
1737 2014-11-19  Antti Koivisto  <antti@apple.com>
1738
1739         Fix TilesAdded bitmask
1740         https://bugs.webkit.org/show_bug.cgi?id=138883
1741
1742         Reviewed by Simon Fraser.
1743
1744         Simon spotted this.
1745
1746         * platform/graphics/ca/GraphicsLayerCA.h:
1747
1748             Use 1LLU << 29 instead of 1LLU < 29
1749             This worked before by pure luck as bit 0 is unused.
1750
1751 2014-11-19  Daniel Bates  <dabates@apple.com>
1752
1753         [iOS] Make WebKit build with public iOS SDK
1754         https://bugs.webkit.org/show_bug.cgi?id=136863
1755
1756         Reviewed by David Kilzer.
1757
1758         * WebCore.xcodeproj/project.pbxproj: Add private headers CFNetworkSPI.h and
1759         NS{CalendarDate, String, URLDownload}SPI.h.
1760         * loader/cocoa/DiskCacheMonitorCocoa.mm: Move forward declaration of
1761         CFNetwork data types and functions from here to file CFNetworkSPI.h and
1762         include header CFNetworkSPI.h.
1763         * platform/network/mac/ResourceHandleMac.mm: Substitute CFNetworkSPI.h for
1764         CFURLRequestSPI.h as the content of the latter was incorporated into the former.
1765         * platform/spi/cf/CFNetworkSPI.h: Added.
1766         * platform/spi/cf/CFURLRequestSPI.h: Removed; incorporated its functionality
1767         into CFNetworkSPI.h
1768         * platform/spi/cocoa/NSCalendarDateSPI.h: Added.
1769         * platform/spi/cocoa/NSStringSPI.h: Added.
1770         * platform/spi/cocoa/NSURLDownloadSPI.h: Added.
1771
1772 2014-11-19  Benjamin Poulain  <bpoulain@apple.com>
1773
1774         Get rid of AccessibilityObject::setRoleValue()
1775         https://bugs.webkit.org/show_bug.cgi?id=138861
1776
1777         Reviewed by Chris Fleizach.
1778
1779         * accessibility/AccessibilityObject.h:
1780         (WebCore::AccessibilityObject::setRoleValue): Deleted.
1781
1782 2014-11-19  Philippe Normand  <pnormand@igalia.com>
1783
1784         Missing NULL-check in VideoTrack::setLanguage
1785         https://bugs.webkit.org/show_bug.cgi?id=138867
1786
1787         Reviewed by Jer Noble.
1788
1789         * html/track/VideoTrack.cpp:
1790         (WebCore::VideoTrack::setLanguage): Prevent change event creation
1791         on an empty video track list.
1792
1793 2014-11-19  Chris Fleizach  <cfleizach@apple.com>
1794
1795         AX: Safari fails to load a web page with VoiceOver
1796         https://bugs.webkit.org/show_bug.cgi?id=138849
1797
1798         Reviewed by Mario Sanchez Prada.
1799
1800         Sometimes an inlineElementContinuation will continue to an inline RenderBlock, so we case this incorrectly and bad things happen.
1801
1802         Test: accessibility/inline-block-assertion.html
1803
1804         * accessibility/AccessibilityRenderObject.cpp:
1805         (WebCore::startOfContinuations):
1806
1807 2014-11-19  Zalan Bujtas  <zalan@apple.com>
1808
1809         Simple line layout: RenderTreeAsText should use rangeForRenderer() when dumping simple line text.
1810         https://bugs.webkit.org/show_bug.cgi?id=138847
1811
1812         Reviewed by Antti Koivisto.
1813
1814         This is in preparation to support multiple renderers for simple line layout.
1815         Use rangeForRenderer() to get runs for a particular renderer as opposed to for the entire flow.
1816
1817         Not testable.
1818
1819         * rendering/RenderTreeAsText.cpp:
1820         (WebCore::write):
1821
1822 2014-11-19  peavo@outlook.com  <peavo@outlook.com>
1823
1824         [WinCairo] Compile error when CSS_SELECTORS_LEVEL4 is not enabled.
1825         https://bugs.webkit.org/show_bug.cgi?id=138870
1826
1827         Reviewed by Alex Christensen.
1828
1829         * css/CSSSelector.cpp:
1830         (WebCore::simpleSelectorSpecificityInternal):
1831
1832 2014-11-19  Chris Fleizach  <cfleizach@apple.com>
1833
1834         AX: Screen braille input doesn't work on forms.
1835         https://bugs.webkit.org/show_bug.cgi?id=138804
1836
1837         Reviewed by Mario Sanchez Prada.
1838
1839         Allow iOS to set values of text fields through the API.
1840
1841         Test: platform/ios-sim/accessibility/set-value.html
1842
1843         * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
1844         (-[WebAccessibilityObjectWrapper _accessibilitySetValue:]):
1845
1846 2014-11-19  Zalan Bujtas  <zalan@apple.com>
1847
1848         Simple line layout: Add renderer based rect collecting to RunResolver.
1849         https://bugs.webkit.org/show_bug.cgi?id=138818
1850
1851         Reviewed by Antti Koivisto.
1852
1853         This is in preparation to multiple renderers support.
1854         RunResolver should be able to collect rects for a particular renderer
1855         that might overlap multiple runs. (or might just be a subset of a Run)
1856
1857         Covered by existing tests.
1858
1859         * rendering/SimpleLineLayoutFlowContents.cpp:
1860         (WebCore::SimpleLineLayout::FlowContents::renderer): It operates on a single renderer currently.
1861         (WebCore::SimpleLineLayout::FlowContents::resolveRendererPositions): It operates on a single renderer currently.
1862         * rendering/SimpleLineLayoutFlowContents.h:
1863         * rendering/SimpleLineLayoutFunctions.cpp:
1864         (WebCore::SimpleLineLayout::computeTextBoundingBox):
1865         (WebCore::SimpleLineLayout::computeTextFirstRunLocation):
1866         (WebCore::SimpleLineLayout::collectTextAbsoluteRects):
1867         (WebCore::SimpleLineLayout::collectTextAbsoluteQuads):
1868         (WebCore::SimpleLineLayout::showLineLayoutForFlow):
1869         * rendering/SimpleLineLayoutResolver.cpp:
1870         (WebCore::SimpleLineLayout::baselinePosition):
1871         (WebCore::SimpleLineLayout::linePosition):
1872         (WebCore::SimpleLineLayout::lineSize):
1873         (WebCore::SimpleLineLayout::RunResolver::Run::rect):
1874         (WebCore::SimpleLineLayout::RunResolver::Run::rectForTextRenderer):
1875         (WebCore::SimpleLineLayout::RunResolver::Run::baseline):
1876         (WebCore::SimpleLineLayout::RunResolver::Run::text):
1877         (WebCore::SimpleLineLayout::RunResolver::Run::computeRect):
1878         (WebCore::SimpleLineLayout::RunResolver::RunResolver):
1879         * rendering/SimpleLineLayoutResolver.h:
1880
1881 2014-11-19  Dhi Aurrahman  <diorahman@rockybars.com>
1882
1883         Add selector checker for :lang pseudo class in Selectors level 4
1884         https://bugs.webkit.org/show_bug.cgi?id=138281
1885
1886         Reviewed by Benjamin Poulain.
1887
1888         Add selector checker for :lang pseudo class in Selectors level 4.
1889
1890         The language tags matching is specified in [1,2].
1891
1892         [1] http://www.ietf.org/rfc/rfc4647.txt
1893         [2] http://dev.w3.org/csswg/selectors4/#the-lang-pseudo
1894
1895         Tests: fast/selectors/lang-extended-filtering.html
1896                fast/selectors/lang-multiple.html
1897
1898         * css/SelectorChecker.cpp:
1899         (WebCore::SelectorChecker::checkOne):
1900         * css/SelectorCheckerTestFunctions.h:
1901         (WebCore::containslanguageSubtagMatchingRange):
1902         (WebCore::matchesLangPseudoClass):
1903         (WebCore::matchesLangPseudoClassDeprecated):
1904         * cssjit/SelectorCompiler.cpp:
1905         (WebCore::SelectorCompiler::addPseudoClassType):
1906
1907 2014-11-18  Philippe Normand  <pnormand@igalia.com>
1908
1909         start/stop method for AudioBufferSourceNodes and OscillatorNodes can take no args
1910         https://bugs.webkit.org/show_bug.cgi?id=138739
1911
1912         Reviewed by Darin Adler.
1913
1914         The patch is inspired by the following Blink revision by
1915         <rtoy@google.com>:
1916         <https://src.chromium.org/viewvc/blink?view=rev&revision=160845>
1917
1918         Test: webaudio/dom-exceptions.html
1919
1920         * Modules/webaudio/AudioBufferSourceNode.cpp:
1921         (WebCore::AudioBufferSourceNode::start):
1922         (WebCore::AudioBufferSourceNode::startPlaying):
1923         (WebCore::AudioBufferSourceNode::noteGrainOn):
1924         (WebCore::AudioBufferSourceNode::startGrain): Deleted.
1925         * Modules/webaudio/AudioBufferSourceNode.h:
1926         * Modules/webaudio/AudioBufferSourceNode.idl:
1927         * Modules/webaudio/AudioScheduledSourceNode.cpp:
1928         (WebCore::AudioScheduledSourceNode::start):
1929         (WebCore::AudioScheduledSourceNode::stop):
1930         * Modules/webaudio/AudioScheduledSourceNode.h:
1931         * Modules/webaudio/OscillatorNode.idl:
1932
1933 2014-11-18  Benjamin Poulain  <benjamin@webkit.org>
1934
1935         Add the initial implementation of dynamic specificity for :matches()
1936         https://bugs.webkit.org/show_bug.cgi?id=138822
1937
1938         Reviewed by Andreas Kling.
1939
1940         Previously we completely ignored the selector list of :matches() when computing
1941         the specificity of the selector.
1942
1943         The spec (http://dev.w3.org/csswg/selectors4/#specificity) says:
1944         "The specificity of a :matches() pseudo-class, however, is the specificity
1945          of the most specific complex selector that matched the given element."
1946
1947         This patch does just that.
1948
1949         In the CSS JIT, we only consider specificities that can be computed statically
1950         for now, this should be extended later.
1951         When the specificity is dynamic, we fall back to SelectorChecker. In that case,
1952         we execute every selector of the selector list and we keep the maximum value
1953         as the specificity for the whole :matches().
1954
1955         Tests: fast/css/matches-specificity-1.html
1956                fast/css/matches-specificity-2.html
1957                fast/css/matches-specificity-3.html
1958                fast/css/matches-specificity-4.html
1959                fast/css/matches-specificity-5.html
1960                fast/css/matches-specificity-6.html
1961                fast/css/matches-specificity-7.html
1962                fast/css/matches-specificity-8.html
1963                fast/css/matches-specificity-9.html
1964                fast/css/matches-specificity-10.html
1965
1966         * css/CSSSelector.cpp:
1967         (WebCore::selectorSpecificity):
1968         (WebCore::maxSpecificity):
1969         (WebCore::CSSSelector::specificity):
1970         (WebCore::simpleSelectorSpecificityInternal):
1971         (WebCore::CSSSelector::simpleSelectorSpecificity):
1972         :matches() itself should not have any specificity. The specificity of its components
1973         is computed in SelectorChecker.
1974
1975         Since :matches() is no longer accounted as a class B specificity, I had to finish
1976         the specificity of :not() or some test breaks.
1977
1978         * css/CSSSelector.h:
1979         * css/PageRuleCollector.cpp:
1980         (WebCore::comparePageRules):
1981         * css/SelectorChecker.cpp:
1982         (WebCore::SelectorChecker::checkOne):
1983         We can no longer shortcut the execution when context.pseudoElementEffective is false.
1984         There is no guarantee that a following selector wouldn't match with a higher specificity.
1985
1986         * cssjit/SelectorCompiler.cpp:
1987         (WebCore::SelectorCompiler::addPseudoClassType):
1988         (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
1989         (WebCore::SelectorCompiler::constructFragments):
1990         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
1991
1992 2014-11-18  David Kilzer  <ddkilzer@apple.com>
1993
1994         FeatureDefines.xcconfig: Switch from using PLATFORM_NAME to SDK selectors
1995         <http://webkit.org/b/138813>
1996
1997         Reviewed by Mark Rowe.
1998
1999         * Configurations/FeatureDefines.xcconfig: Switch to using SDK
2000         selectors.
2001
2002 2014-11-18  Chris Dumez  <cdumez@apple.com>
2003
2004         Crash when setting 'z-index' / 'flex-shrink' CSS properties to a calculated value
2005         https://bugs.webkit.org/show_bug.cgi?id=138783
2006
2007         Reviewed by Andreas Kling.
2008
2009         Update operators converting CSSPrimitiveValue to integer / floating
2010         point types to properly handle calculated values (e.g. 'calc(2 * 3)').
2011         Previously, this was not working in release builds and we would hit an
2012         ASSERT_NOT_REACHED() in debug builds.
2013
2014         Tests: fast/css/flex-shrink-calculated-value.html
2015                fast/css/z-index-calculated-value.html
2016
2017         * css/CSSPrimitiveValueMappings.h:
2018         (WebCore::CSSPrimitiveValue::operator unsigned short):
2019         (WebCore::CSSPrimitiveValue::operator int):
2020         (WebCore::CSSPrimitiveValue::operator unsigned):
2021         (WebCore::CSSPrimitiveValue::operator float):
2022
2023 2014-11-18  Commit Queue  <commit-queue@webkit.org>
2024
2025         Unreviewed, rolling out r176263 and r176273.
2026         https://bugs.webkit.org/show_bug.cgi?id=138854
2027
2028         Underlines are hideous. (Requested by litherum on #webkit).
2029
2030         Reverted changesets:
2031
2032         "Use underlining metrics from the font file"
2033         https://bugs.webkit.org/show_bug.cgi?id=138762
2034         http://trac.webkit.org/changeset/176263
2035
2036         "iOS build fix."
2037         http://trac.webkit.org/changeset/176273
2038
2039 2014-11-18  Chris Dumez  <cdumez@apple.com>
2040
2041         Add a setting to toggle DOMTimer throttling support
2042         https://bugs.webkit.org/show_bug.cgi?id=138844
2043         <rdar://problem/19020874>
2044
2045         Reviewed by Andreas Kling.
2046
2047         Add a setting to disable DOM timers throttling, in order to help
2048         developers determine if a specific issue is caused by timer
2049         throttling.
2050
2051         * page/DOMTimer.cpp:
2052         (WebCore::DOMTimerFireState::contextDocument):
2053         (WebCore::DOMTimerFireState::scriptMadeUserObservableChanges):
2054         (WebCore::DOMTimer::isDOMTimersThrottlingEnabled):
2055         (WebCore::DOMTimer::updateThrottlingStateIfNecessary):
2056         * page/DOMTimer.h:
2057         * page/Settings.in:
2058
2059 2014-11-18  Beth Dakin  <bdakin@apple.com>
2060
2061         REGRESSION: Invoking dictionary lookup on text in some search fields searches for 
2062         incorrect item
2063         https://bugs.webkit.org/show_bug.cgi?id=138853
2064         -and corresponding-
2065         rdar://problem/18912505
2066
2067         Reviewed by Tim Horton.
2068
2069         Get the visible position based on the frame, not just the renderer.
2070         * editing/mac/DictionaryLookup.mm:
2071         (WebCore::rangeForDictionaryLookupAtHitTestResult):
2072
2073 2014-11-18  David Hyatt  <hyatt@apple.com>
2074
2075         REGRESSION (r167210): Invalid cast in WebCore::RenderBlock::blockSelectionGaps
2076         https://bugs.webkit.org/show_bug.cgi?id=137590
2077
2078         Reviewed by Dean Jackson.
2079
2080         Added fast/block/selection-block-gaps-crash.html
2081
2082         * rendering/RenderBlock.cpp:
2083         (WebCore::RenderBlock::blockSelectionGaps):
2084         Check that we really are a RenderBlock before recurring.
2085
2086 2014-11-18  Andreas Kling  <akling@apple.com>
2087
2088         Avoid synchronous style recalc in Document.activeElement
2089         <https://webkit.org/b/138850>
2090
2091         Reviewed by Ryosuke Niwa.
2092
2093         This subtly changes the behavior of <input autofocus>, which was caught by
2094         a layout test. Auto-focus doesn't happen until the render tree is attached,
2095         although it was possible to force it by accessing document.activeElement.
2096
2097         Now auto-focus is always lazy. This is consistent with other browser engines.
2098
2099         ~1% progression on Speedometer locally.
2100
2101         * dom/Document.cpp:
2102         (WebCore::Document::activeElement):
2103
2104 2014-11-18  Chris Dumez  <cdumez@apple.com>
2105
2106         Have Vector::capacity() return an unsigned instead of a size_t
2107         https://bugs.webkit.org/show_bug.cgi?id=138842
2108
2109         Reviewed by Andreas Kling.
2110
2111         Update the code base now that Vector::capacity() returns an unsigned
2112         type instead of a size_t.
2113
2114         No new tests, no behavior change.
2115
2116         * editing/TextIterator.cpp:
2117         (WebCore::SearchBuffer::append):
2118         (WebCore::SearchBuffer::prependContext):
2119         (WebCore::SearchBuffer::search):
2120         (WebCore::SearchBuffer::length):
2121         * platform/SharedBuffer.cpp:
2122         (WebCore::SharedBuffer::duplicateDataBufferIfNecessary):
2123
2124 2014-11-18  Geoffrey Garen  <ggaren@apple.com>
2125
2126         Removed the custom allocator for ListHashSet nodes
2127         https://bugs.webkit.org/show_bug.cgi?id=138841
2128
2129         Reviewed by Andreas Kling.
2130
2131         Uses of ListHashSet no longer need to declare an inline capacity,
2132         since that was only used to specify the capacity of the custom allocator.
2133
2134         * dom/DOMNamedFlowCollection.h:
2135         * dom/DocumentEventQueue.h:
2136         * dom/DocumentStyleSheetCollection.h:
2137         * dom/NamedFlowCollection.h:
2138         * html/FormController.h:
2139         * rendering/FloatingObjects.h:
2140         * rendering/RenderBlock.h:
2141
2142 2014-11-18  David Hyatt  <hyatt@apple.com>
2143
2144         REGRESSION(r152313): Inline-block element doesn't wrap properly
2145         https://bugs.webkit.org/show_bug.cgi?id=138846 - <rdar://problem/18838703>
2146
2147         Reviewed by Simon Fraser.
2148
2149         Added fast/inline-block/inline-block-empty-spans.html
2150
2151         * rendering/line/BreakingContextInlineHeaders.h:
2152         (WebCore::BreakingContext::canBreakAtThisPosition):
2153
2154 2014-11-18  Myles C. Maxfield  <mmaxfield@apple.com>
2155
2156         Multicolumn layout with negative line spacing and orphans causes pieces of letters to be shown at the bottom of columns
2157         https://bugs.webkit.org/show_bug.cgi?id=138204
2158
2159         Reviewed by Dave Hyatt.
2160
2161         This code is responsible for pushing block elements to the next column if
2162         the "orphans" CSS property is triggered. The mechanism by which this is
2163         achieved is to push the block down such that the origin of the block is
2164         at the origin of the next column. However, if there is negative line
2165         spacing, the top portion of the text might actually be on top of the
2166         origin of the block. Therefore, the block wasn't being pushed down enough
2167         to entirely contain its text, so the top pieces were being drawn on the
2168         previous column.
2169
2170         Test: fast/multicol/orphans-negative-line-spacing.html
2171
2172         * rendering/RenderBlockFlow.cpp:
2173         (WebCore::RenderBlockFlow::adjustLinePositionForPagination):
2174
2175 2014-11-18  Chris Dumez  <cdumez@apple.com>
2176
2177         DOMTimers sometimes don't get unthrottled on scrolling
2178         https://bugs.webkit.org/show_bug.cgi?id=138838
2179
2180         Reviewed by Antti Koivisto.
2181
2182         DOMTimers sometimes didn't get unthrottled on scrolling. This is
2183         because we stopped listening for viewport changes every time the
2184         timer fires, but we didn't listen for those changes again if we
2185         decided the timer should stay throttled after the timer's action
2186         was executed.
2187
2188         We should listen for viewport changes again after executing the
2189         timer's action, if there are elements outside the viewport causing
2190         the DOMTimer to be throttled, even if the throttleState hasn't
2191         changed (i.e the timer stays throttled).
2192
2193         Test: fast/dom/timer-unthrottle-on-scroll.html
2194
2195         * page/DOMTimer.cpp:
2196         (WebCore::DOMTimer::updateThrottlingStateIfNecessary):
2197         (WebCore::DOMTimer::updateTimerIntervalIfNecessary):
2198         (WebCore::DOMTimer::updateThrottlingStateAfterViewportChange):
2199
2200 2014-11-18  Daniel Bates  <dbates@webkit.org>
2201
2202         [iOS] Make WebCore build and link with public SDK
2203         https://bugs.webkit.org/show_bug.cgi?id=136487
2204
2205         Reviewed by David Kilzer.
2206
2207         * bindings/objc/DOMInternal.mm: Include header NSMapTableSPI.h.
2208         * bindings/objc/WebScriptObject.mm: Ditto; Also fix style nit, substitute
2209         #import for #include when importing header WTFString.h.
2210         * bridge/objc/objc_instance.mm: Include header NSMapTableSPI.h and remove
2211         #import NSMapTable.h as the former will import the latter.
2212         * platform/ios/PlatformEventFactoryIOS.mm: Include header wtf/CurrentTime.h
2213         for the declaration of WTF::currentTime().
2214         * platform/ios/wak/WebCoreThread.mm: Remove unnecessary include of header CoreFoundation/CFPriv.h.
2215         * platform/spi/ios/AVKitSPI.h: Add more SPI.
2216         * platform/spi/ios/MPAVRoutingControllerSPI.h: Ditto.
2217
2218 2014-11-18  Myles C. Maxfield  <mmaxfield@apple.com>
2219
2220         Subclass CachedFont for SVG fonts
2221         https://bugs.webkit.org/show_bug.cgi?id=138686
2222
2223         Reviewed by Simon Fraser.
2224
2225         Re-landing due to flakey bots.
2226
2227         CachedFont had many #if ENABLE(SVG_FONTS) scattered throughout it.
2228         Splitting out this SVG-specific code into a subclass of CachedFont
2229         cleans up the design.
2230
2231         No new tests because there is no behavior change.
2232
2233         * CMakeLists.txt:
2234         * WebCore.vcxproj/WebCore.vcxproj:
2235         * WebCore.vcxproj/WebCore.vcxproj.filters:
2236         * WebCore.xcodeproj/project.pbxproj:
2237         * css/CSSFontFaceSource.cpp:
2238         (WebCore::CSSFontFaceSource::getFontData): There are two sections
2239         in this function; one for SVG fonts and one for regular fonts.
2240         I've moved these two sections into CachedFont and SVGCachedFont,
2241         thereby simplifying this function.
2242         (WebCore::CSSFontFaceSource::ensureFontData): Ditto.
2243         (WebCore::CSSFontFaceSource::svgFontFaceElement): Moved to header.
2244         (WebCore::CSSFontFaceSource::setSVGFontFaceElement): Ditto.
2245         (WebCore::CSSFontFaceSource::isSVGFontFaceSource): Ditto.
2246         * css/CSSFontFaceSource.h: Put functions that are simple enough to
2247         be inlined here.
2248         * css/CSSFontFaceSrcValue.cpp:
2249         (WebCore::CSSFontFaceSrcValue::isSVGFontTarget): Convenience
2250         function.
2251         (WebCore::CSSFontFaceSrcValue::cachedFont): Pass through a boolean
2252         from CSSFontSelector to CachedResourceHandle regarding if we should
2253         be using SVGCachedFont instead of CachedFont.
2254         * css/CSSFontFaceSrcValue.h: New convenience function.
2255         * css/CSSFontSelector.cpp:
2256         (WebCore::CSSFontSelector::addFontFaceRule): Pass through a boolean
2257         * inspector/InspectorPageAgent.cpp:
2258         (WebCore::InspectorPageAgent::cachedResourceType): Update for new
2259         CachedResource type
2260         (WebCore::cachedResourcesForFrame): Ditto.
2261         * loader/cache/CachedFont.cpp:
2262         (WebCore::CachedFont::CachedFont):
2263         (WebCore::CachedFont::ensureCustomFontData): Taken from
2264         CSSFontFaceSource::getFontData()
2265         (WebCore::CachedFont::getFontData): Ditto.
2266         (WebCore::CachedFont::platformDataFromCustomData): Ditto.
2267         (WebCore::CachedFont::ensureSVGFontData): Moved to SVGCachedFont.
2268         (WebCore::CachedFont::getSVGFontById): Ditto.
2269         * loader/cache/CachedFont.h:
2270         * loader/cache/CachedResource.cpp:
2271         (WebCore::defaultPriorityForResourceType): Update for new enum
2272         type.
2273         * loader/cache/CachedResource.h:
2274         * loader/cache/CachedResourceLoader.cpp:
2275         (WebCore::createResource): Takes new boolean.
2276         (WebCore::CachedResourceLoader::requestFont): Ditto.
2277         (WebCore::CachedResourceLoader::checkInsecureContent): Update for
2278         new enum type
2279         (WebCore::CachedResourceLoader::canRequest): Ditto.
2280         * loader/cache/CachedResourceLoader.h:
2281         * loader/cache/CachedSVGFont.cpp: Added.
2282         (WebCore::CachedSVGFont::CachedSVGFont): Moved from
2283         CSSFontFaceSource::getFontData() and CachedFont
2284         (WebCore::CachedSVGFont::getFontData): Ditto.
2285         (WebCore::CachedSVGFont::platformDataFromCustomData): Ditto.
2286         (WebCore::CachedSVGFont::ensureCustomFontData): Ditto.
2287         (WebCore::CachedSVGFont::getSVGFontById): Ditto.
2288         (WebCore::CachedSVGFont::firstFontFace): Ditto.
2289         * loader/cache/CachedSVGFont.h: Subclass CachedFont.
2290         * loader/cache/MemoryCache.cpp:
2291         (WebCore::MemoryCache::getStatistics): Update for new enum.
2292         * svg/SVGFontFaceUriElement.cpp:
2293         (WebCore::isSVGFontTarget): Convenience function.
2294         (WebCore::SVGFontFaceUriElement::loadFont): Update for new
2295         boolean.
2296
2297 2014-11-18  Chris Dumez  <cdumez@apple.com>
2298
2299         Update the Vector API to deal with unsigned types instead of size_t
2300         https://bugs.webkit.org/show_bug.cgi?id=138824
2301
2302         Reviewed by Andreas Kling.
2303
2304         Update code base to fix build errors related to the typing changes
2305         in the Vector API (size_t -> unsigned).
2306
2307         No new tests, no behavior change.
2308
2309         * WebCore.exp.in:
2310         * bindings/js/JSDOMBinding.h:
2311         (WebCore::jsArray):
2312         * bindings/js/JSWebGLRenderingContextCustom.cpp:
2313         * cssjit/SelectorCompiler.cpp:
2314         * html/HTMLFormElement.cpp:
2315         (WebCore::removeFromVector):
2316         * html/parser/HTMLParserIdioms.h:
2317         * html/parser/XSSAuditor.cpp:
2318
2319 2014-11-18  Myles C. Maxfield  <mmaxfield@apple.com>
2320
2321         Unreviewed iOS build fix
2322
2323         * platform/graphics/ios/SimpleFontDataIOS.mm:
2324         (WebCore::SimpleFontData::platformInit):
2325
2326 2014-11-18  Dan Bernstein  <mitz@apple.com>
2327
2328         iOS build fix.
2329
2330         * platform/graphics/ios/SimpleFontDataIOS.mm:
2331         (WebCore::SimpleFontData::platformInit):
2332
2333 2014-11-18  Commit Queue  <commit-queue@webkit.org>
2334
2335         Unreviewed, rolling out r176264.
2336         https://bugs.webkit.org/show_bug.cgi?id=138837
2337
2338         caused many test failures (Requested by litherum on #webkit).
2339
2340         Reverted changeset:
2341
2342         "Subclass CachedFont for SVG fonts"
2343         https://bugs.webkit.org/show_bug.cgi?id=138686
2344         http://trac.webkit.org/changeset/176264
2345
2346 2014-11-18  Daniel Bates  <dabates@apple.com>
2347
2348         [iOS] Libdispatch, Dyld, IOKit, Mach, NSPointerFunctions, MobileGestalt
2349         SPI are not available in public SDK
2350         https://bugs.webkit.org/show_bug.cgi?id=138802
2351
2352         Reviewed by David Kilzer.
2353
2354         Add SPI wrapper headers {Dispatch, DynamicLinker, IOPMLib, MachVM, NSPointerFunctions, MobileGestalt}SPI.h
2355         that forward declare applicable libdispatch, dyld, IOKit, mach, Foundation, MobileGestalt SPI
2356         and use these headers instead of the including private headers corresponding to these libraries/frameworks.
2357
2358         * WebCore.xcodeproj/project.pbxproj: Add private headers MobileGestaltSPI.h and
2359         MachVMSPI.h, and project headers DynamicLinkerSPI.h, NSPointerFunctionsSPI.h,
2360         DispatchSPI.h and IOPMLibSPI.h. Also, sort files in Xcode project.
2361         * bindings/objc/DOMInternal.mm: Include header NSPointerFunctionsSPI.h.
2362         * bridge/objc/objc_instance.mm: Ditto; Also, sort #import directives.
2363         * platform/cocoa/DisplaySleepDisablerCocoa.cpp: Substitute header IOPMLibSPI.h
2364         for private header IOKit/pwr_mgt/IOPMLib.h.
2365         * platform/cocoa/MemoryPressureHandlerCocoa.mm: Substitute header DispatchSPI.h
2366         for private header dispatch/private.h.
2367         * platform/graphics/ios/FontServicesIOS.mm: Substitute header DynamicLinkerSPI.h
2368         for private header mach-o/dyld_priv.h.
2369         * platform/ios/PlatformScreenIOS.mm: Substitute header MobileGestaltSPI.h for
2370         private header MobileGestalt.h.
2371         * platform/spi/cocoa/DispatchSPI.h: Added.
2372         * platform/spi/cocoa/DynamicLinkerSPI.h: Added.
2373         * platform/spi/cocoa/IOPMLibSPI.h: Added.
2374         * platform/spi/cocoa/MachVMSPI.h: Added.
2375         * platform/spi/cocoa/NSPointerFunctionsSPI.h: Added.
2376         * platform/spi/ios/MobileGestaltSPI.h: Added.
2377
2378 2014-11-18  Myles C. Maxfield  <mmaxfield@apple.com>
2379
2380         Subclass CachedFont for SVG fonts
2381         https://bugs.webkit.org/show_bug.cgi?id=138686
2382
2383         Reviewed by Simon Fraser.
2384
2385         CachedFont had many #if ENABLE(SVG_FONTS) scattered throughout it.
2386         Splitting out this SVG-specific code into a subclass of CachedFont
2387         cleans up the design.
2388
2389         No new tests because there is no behavior change.
2390
2391         * CMakeLists.txt:
2392         * WebCore.vcxproj/WebCore.vcxproj:
2393         * WebCore.vcxproj/WebCore.vcxproj.filters:
2394         * WebCore.xcodeproj/project.pbxproj:
2395         * css/CSSFontFaceSource.cpp:
2396         (WebCore::CSSFontFaceSource::getFontData): There are two sections
2397         in this function; one for SVG fonts and one for regular fonts.
2398         I've moved these two sections into CachedFont and SVGCachedFont,
2399         thereby simplifying this function.
2400         (WebCore::CSSFontFaceSource::ensureFontData): Ditto.
2401         (WebCore::CSSFontFaceSource::svgFontFaceElement): Moved to header.
2402         (WebCore::CSSFontFaceSource::setSVGFontFaceElement): Ditto.
2403         (WebCore::CSSFontFaceSource::isSVGFontFaceSource): Ditto.
2404         * css/CSSFontFaceSource.h: Put functions that are simple enough to
2405         be inlined here.
2406         * css/CSSFontFaceSrcValue.cpp:
2407         (WebCore::CSSFontFaceSrcValue::isSVGFontTarget): Convenience
2408         function.
2409         (WebCore::CSSFontFaceSrcValue::cachedFont): Pass through a boolean
2410         from CSSFontSelector to CachedResourceHandle regarding if we should
2411         be using SVGCachedFont instead of CachedFont.
2412         * css/CSSFontFaceSrcValue.h: New convenience function.
2413         * css/CSSFontSelector.cpp:
2414         (WebCore::CSSFontSelector::addFontFaceRule): Pass through a boolean
2415         * inspector/InspectorPageAgent.cpp:
2416         (WebCore::InspectorPageAgent::cachedResourceType): Update for new
2417         CachedResource type
2418         (WebCore::cachedResourcesForFrame): Ditto.
2419         * loader/cache/CachedFont.cpp:
2420         (WebCore::CachedFont::CachedFont):
2421         (WebCore::CachedFont::ensureCustomFontData): Taken from
2422         CSSFontFaceSource::getFontData()
2423         (WebCore::CachedFont::getFontData): Ditto.
2424         (WebCore::CachedFont::platformDataFromCustomData): Ditto.
2425         (WebCore::CachedFont::ensureSVGFontData): Moved to SVGCachedFont.
2426         (WebCore::CachedFont::getSVGFontById): Ditto.
2427         * loader/cache/CachedFont.h:
2428         * loader/cache/CachedResource.cpp:
2429         (WebCore::defaultPriorityForResourceType): Update for new enum
2430         type.
2431         * loader/cache/CachedResource.h:
2432         * loader/cache/CachedResourceLoader.cpp:
2433         (WebCore::createResource): Takes new boolean.
2434         (WebCore::CachedResourceLoader::requestFont): Ditto.
2435         (WebCore::CachedResourceLoader::checkInsecureContent): Update for
2436         new enum type
2437         (WebCore::CachedResourceLoader::canRequest): Ditto.
2438         * loader/cache/CachedResourceLoader.h:
2439         * loader/cache/CachedSVGFont.cpp: Added.
2440         (WebCore::CachedSVGFont::CachedSVGFont): Moved from
2441         CSSFontFaceSource::getFontData() and CachedFont
2442         (WebCore::CachedSVGFont::getFontData): Ditto.
2443         (WebCore::CachedSVGFont::platformDataFromCustomData): Ditto.
2444         (WebCore::CachedSVGFont::ensureCustomFontData): Ditto.
2445         (WebCore::CachedSVGFont::getSVGFontById): Ditto.
2446         (WebCore::CachedSVGFont::firstFontFace): Ditto.
2447         * loader/cache/CachedSVGFont.h: Subclass CachedFont.
2448         * loader/cache/MemoryCache.cpp:
2449         (WebCore::MemoryCache::getStatistics): Update for new enum.
2450         * svg/SVGFontFaceUriElement.cpp:
2451         (WebCore::isSVGFontTarget): Convenience function.
2452         (WebCore::SVGFontFaceUriElement::loadFont): Update for new
2453         boolean.
2454
2455 2014-11-18  Myles C. Maxfield  <litherum@gmail.com>
2456
2457         Use underlining metrics from the font file
2458         https://bugs.webkit.org/show_bug.cgi?id=138762
2459
2460         Reviewed by Dave Hyatt.
2461
2462         Test: platform/mac/fast/css3-text/css3-text-decoration/text-decoration-thickness.html
2463
2464         * platform/graphics/FontMetrics.h: Adding variables for text decoration thickness and
2465         underline position.
2466         (WebCore::FontMetrics::FontMetrics):
2467         (WebCore::FontMetrics::decorationThickness):
2468         (WebCore::FontMetrics::setDecorationThickness):
2469         (WebCore::FontMetrics::underlinePosition):
2470         (WebCore::FontMetrics::setUnderlinePosition):
2471         * platform/graphics/freetype/SimpleFontDataFreeType.cpp:
2472         (WebCore::SimpleFontData::platformInit): Initialize new FontMetrics members.
2473         * platform/graphics/ios/SimpleFontDataIOS.mm:
2474         (WebCore::SimpleFontData::platformInit): Ditto.
2475         * platform/graphics/mac/SimpleFontDataMac.mm:
2476         (WebCore::SimpleFontData::platformInit): Ditto.
2477         * platform/graphics/win/SimpleFontDataCGWin.cpp:
2478         (WebCore::SimpleFontData::platformInit): Ditto.
2479         * platform/graphics/win/SimpleFontDataCairoWin.cpp:
2480         (WebCore::SimpleFontData::platformInit): Ditto.
2481         * platform/graphics/win/SimpleFontDataWin.cpp:
2482         (WebCore::SimpleFontData::initGDIFont): Ditto.
2483         * rendering/InlineTextBox.cpp:
2484         (WebCore::InlineTextBox::paintDecoration): Use FontMetrics data.
2485         * style/InlineTextBoxStyle.cpp:
2486         (WebCore::computeUnderlineOffset): Ditto.
2487         (WebCore::visualOverflowForDecorations): Ditto.
2488         * style/InlineTextBoxStyle.h:
2489         (WebCore::textDecorationStrokeThickness): Deleted.
2490         * svg/SVGFontData.cpp:
2491         (WebCore::SVGFontData::initializeFontData): Initialize new FontMetrics members.
2492
2493 2014-11-17  David Hyatt  <hyatt@apple.com>
2494
2495         Improve Ruby selection (getting rid of overlap and improving gap filling)
2496         https://bugs.webkit.org/show_bug.cgi?id=138250
2497
2498         Reviewed by Dean Jackson.
2499
2500         * rendering/RenderBlock.cpp:
2501         (WebCore::RenderBlock::selectionGaps):
2502         (WebCore::RenderBlock::blockSelectionGaps):
2503         Add Ruby text in along with the Ruby base.
2504
2505         * rendering/RenderBlockFlow.cpp:
2506         (WebCore::RenderBlockFlow::inlineSelectionGaps):
2507         Don't let block gaps get filled in here.
2508
2509         * rendering/RenderRubyBase.h:
2510         Expose accessor to the ruby run.
2511
2512         * rendering/RenderRubyText.cpp:
2513         (WebCore::RenderRubyText::rubyRun):
2514         * rendering/RenderRubyText.h:
2515         Add accessor to the ruby run.
2516
2517         * rendering/RootInlineBox.cpp:
2518         (WebCore::RootInlineBox::selectionTop):
2519         (WebCore::RootInlineBox::selectionBottom):
2520         Improve selectionTop and selectionBottom of ruby bases to avoid the
2521         ruby text. Improve the selectionTop and selectionBottom of ruby texts
2522         to fill the gap up to the previous/next line as appropriate.
2523
2524 2014-11-18  Shivakumar JM  <shiva.jm@samsung.com>
2525
2526         crypto: Use sequence<> instead of KeyUsage[] in IDL.
2527         https://bugs.webkit.org/show_bug.cgi?id=138823
2528
2529         Reviewed by Darin Adler.
2530
2531         Use sequence<KeyUsage> instead of KeyUsage[] in crypto IDL as per spec: https://dvcs.w3.org/hg/webcrypto-api/raw-file/tip/spec/
2532         Overview.html#SubtleCrypto-method-generateKey
2533
2534         No new tests, no behavior change.
2535
2536         * crypto/SubtleCrypto.idl:
2537
2538 2014-11-18  Philippe Normand  <pnormand@igalia.com>
2539
2540         HRTFDatabaseLoader is not an absolute condition to run audioContext
2541         https://bugs.webkit.org/show_bug.cgi?id=138829
2542
2543         Reviewed by Jer Noble.
2544
2545         This patch is a port of the following Blink revision by
2546         <keonho07.kim@samsung.com>:
2547         <https://src.chromium.org/viewvc/blink?revision=167887&view=revision>
2548
2549         * Modules/webaudio/AudioContext.cpp:
2550         (WebCore::AudioContext::AudioContext):
2551         (WebCore::AudioContext::isRunnable): Deleted.
2552         * Modules/webaudio/AudioContext.h:
2553         (WebCore::AudioContext::hrtfDatabaseLoader): Deleted.
2554         * Modules/webaudio/AudioDestinationNode.cpp:
2555         (WebCore::AudioDestinationNode::render):
2556         * Modules/webaudio/OfflineAudioDestinationNode.cpp:
2557         (WebCore::OfflineAudioDestinationNode::offlineRender):
2558         * Modules/webaudio/PannerNode.cpp:
2559         (WebCore::PannerNode::PannerNode):
2560         (WebCore::PannerNode::process):
2561         (WebCore::PannerNode::initialize):
2562         (WebCore::PannerNode::setPanningModel):
2563         * Modules/webaudio/PannerNode.h:
2564         * Modules/webaudio/RealtimeAnalyser.cpp:
2565         * Modules/webaudio/RealtimeAnalyser.h:
2566         * platform/audio/HRTFDatabaseLoader.cpp:
2567         (WebCore::HRTFDatabaseLoader::createAndLoadAsynchronouslyIfNecessary):
2568
2569 2014-11-18  Commit Queue  <commit-queue@webkit.org>
2570
2571         Unreviewed, rolling out r176218.
2572         https://bugs.webkit.org/show_bug.cgi?id=138827
2573
2574         seems to have caused regressions on the perf bots (Requested
2575         by lajava on #webkit).
2576
2577         Reverted changeset:
2578
2579         "[CSS Grid Layout] Upgrade align-self and align-items parsing
2580         to CSS 3"
2581         https://bugs.webkit.org/show_bug.cgi?id=133359
2582         http://trac.webkit.org/changeset/176218
2583
2584 2014-11-18  Joanmarie Diggs  <jdiggs@igalia.com>
2585
2586         AX: [ATK] Crash getting the orientation of a MenuListOption after the MenuList was removed from the document
2587         https://bugs.webkit.org/show_bug.cgi?id=138727
2588
2589         Reviewed by Chris Fleizach.
2590
2591         AccessibilityMenuListOption::elementRect() returns the value of the
2592         grandparent MenuList, asserting that the grandparent exists with that
2593         role. But it is possible to have an existing MenuListOption and remove
2594         the element which had been backing that MenuList from the document.
2595         Adding null checks prior to the assertions prevents our crashing if the
2596         parent or grandparent was removed.
2597
2598         Test: platform/gtk/accessibility/combobox-descendants-orientation-crash.html
2599
2600         * accessibility/AccessibilityMenuListOption.cpp:
2601         (WebCore::AccessibilityMenuListOption::elementRect):
2602
2603 2014-11-17  Benjamin Poulain  <bpoulain@apple.com>
2604
2605         Fix a small indentation mistake in SelectorCodeGenerator::generateNthFilterTest
2606
2607         * cssjit/SelectorCompiler.cpp:
2608         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateNthFilterTest):
2609
2610 2014-11-17  Benjamin Poulain  <benjamin@webkit.org>
2611
2612         Fix two bad function names of HTMLFormControlElement
2613         https://bugs.webkit.org/show_bug.cgi?id=138790
2614
2615         Reviewed by Andreas Kling.
2616
2617         Darin suggested some name improvements in https://bugs.webkit.org/show_bug.cgi?id=138769
2618
2619         * dom/CheckedRadioButtons.cpp:
2620         (WebCore::RadioButtonGroup::add):
2621         (WebCore::RadioButtonGroup::updateCheckedState):
2622         (WebCore::RadioButtonGroup::requiredAttributeChanged):
2623         (WebCore::RadioButtonGroup::remove):
2624         (WebCore::RadioButtonGroup::updateValidityForAllButtons):
2625         (WebCore::RadioButtonGroup::setNeedsValidityCheckForAllButtons): Deleted.
2626         * html/FileInputType.cpp:
2627         (WebCore::FileInputType::setFiles):
2628         * html/HTMLButtonElement.cpp:
2629         (WebCore::HTMLButtonElement::computeWillValidate):
2630         (WebCore::HTMLButtonElement::recalcWillValidate): Deleted.
2631         * html/HTMLButtonElement.h:
2632         * html/HTMLFieldSetElement.h:
2633         * html/HTMLFormControlElement.cpp:
2634         (WebCore::HTMLFormControlElement::requiredAttributeChanged):
2635         (WebCore::HTMLFormControlElement::computeWillValidate):
2636         (WebCore::HTMLFormControlElement::willValidate):
2637         (WebCore::HTMLFormControlElement::setNeedsWillValidateCheck):
2638         (WebCore::HTMLFormControlElement::isValidFormControlElement):
2639         (WebCore::HTMLFormControlElement::updateValidity):
2640         (WebCore::HTMLFormControlElement::setCustomValidity):
2641         (WebCore::HTMLFormControlElement::recalcWillValidate): Deleted.
2642         (WebCore::HTMLFormControlElement::setNeedsValidityCheck): Deleted.
2643         * html/HTMLFormControlElement.h:
2644         * html/HTMLInputElement.cpp:
2645         (WebCore::HTMLInputElement::runPostTypeUpdateTasks):
2646         (WebCore::HTMLInputElement::parseAttribute):
2647         (WebCore::HTMLInputElement::setChecked):
2648         (WebCore::HTMLInputElement::setValueInternal):
2649         (WebCore::HTMLInputElement::setValueFromRenderer):
2650         (WebCore::HTMLInputElement::computeWillValidate):
2651         (WebCore::HTMLInputElement::parseMaxLengthAttribute):
2652         (WebCore::HTMLInputElement::recalcWillValidate): Deleted.
2653         * html/HTMLInputElement.h:
2654         * html/HTMLKeygenElement.h:
2655         * html/HTMLOutputElement.h:
2656         * html/HTMLSelectElement.cpp:
2657         (WebCore::HTMLSelectElement::deselectItems):
2658         (WebCore::HTMLSelectElement::optionSelectedByUser):
2659         (WebCore::HTMLSelectElement::listBoxSelectItem):
2660         (WebCore::HTMLSelectElement::add):
2661         (WebCore::HTMLSelectElement::parseAttribute):
2662         (WebCore::HTMLSelectElement::childrenChanged):
2663         (WebCore::HTMLSelectElement::optionElementChildrenChanged):
2664         (WebCore::HTMLSelectElement::setLength):
2665         (WebCore::HTMLSelectElement::selectAll):
2666         (WebCore::HTMLSelectElement::updateListBoxSelection):
2667         (WebCore::HTMLSelectElement::selectOption):
2668         (WebCore::HTMLSelectElement::restoreFormControlState):
2669         (WebCore::HTMLSelectElement::parseMultipleAttribute):
2670         (WebCore::HTMLSelectElement::reset):
2671         * html/HTMLTextAreaElement.cpp:
2672         (WebCore::HTMLTextAreaElement::parseAttribute):
2673         (WebCore::HTMLTextAreaElement::subtreeHasChanged):
2674         (WebCore::HTMLTextAreaElement::setValue):
2675         (WebCore::HTMLTextAreaElement::setNonDirtyValue):
2676
2677 2014-11-17  Sukolsak Sakshuwong  <sukolsak@gmail.com>
2678
2679         Add parsing for :role()
2680         https://bugs.webkit.org/show_bug.cgi?id=138310
2681
2682         Reviewed by Benjamin Poulain.
2683
2684         Add support for parsing :role() pseudo class. The implementation of selector
2685         matching will be in a follow-up patch.
2686
2687         * css/CSSGrammar.y.in:
2688         * css/CSSParser.cpp:
2689         (WebCore::CSSParser::detectFunctionTypeToken):
2690         * css/CSSSelector.cpp:
2691         (WebCore::appendPseudoClassFunctionTail):
2692         (WebCore::CSSSelector::selectorText):
2693         * css/CSSSelector.h:
2694         * css/SelectorChecker.cpp:
2695         (WebCore::SelectorChecker::checkOne):
2696         * css/SelectorPseudoClassAndCompatibilityElementMap.in:
2697         * cssjit/SelectorCompiler.cpp:
2698         (WebCore::SelectorCompiler::addPseudoClassType):
2699
2700 2014-11-17  Simon Fraser  <simon.fraser@apple.com>
2701
2702         [iOS WK1] Sometimes, missing tiles in -webkit-overflow-scrolling: touch in UIWebViews
2703         https://bugs.webkit.org/show_bug.cgi?id=138815
2704         rdar://problem/18746203
2705
2706         Reviewed by Tim Horton.
2707
2708         The scroll-velocity-related data members on FrameView, added in r168233, were uninitialized in UIWebViews,
2709         so FrameView::computeCoverageRect() could return garbage results, leading to too much or too little tile coverage.
2710         
2711         We still add additional coverage from the new inclusion of a margin area, but, for simplicity, leave that the same
2712         between WK1 and WK2 for now.
2713         
2714         * page/FrameView.cpp:
2715         (WebCore::FrameView::FrameView):
2716
2717 2014-11-17  Chris Dumez  <cdumez@apple.com>
2718
2719         Add initial layout testing coverage for timer throttling
2720         https://bugs.webkit.org/show_bug.cgi?id=138809
2721
2722         Reviewed by Simon Fraser.
2723
2724         Add isTimerThrottled() API to Internals so that we can add layout test
2725         coverage for timer throttling.
2726
2727         Tests: fast/dom/nested-timer-invisible-element-throttling.html
2728                fast/dom/nested-timer-visible-element-throttling.html
2729                fast/dom/repeating-timer-invisible-element-throttling.html
2730                fast/dom/repeating-timer-visible-element-throttling.html
2731
2732         * page/DOMTimer.h:
2733         * testing/Internals.cpp:
2734         (WebCore::Internals::isTimerThrottled):
2735         * testing/Internals.h:
2736         * testing/Internals.idl:
2737
2738 2014-11-17  Zalan Bujtas  <zalan@apple.com>
2739
2740         Simple line layout: Rename FlowContentIterator and move implementation to SimpleLineLayoutFlowContents.cpp
2741         https://bugs.webkit.org/show_bug.cgi?id=138799
2742
2743         Reviewed by Antti Koivisto.
2744
2745         This is in preparation to support multiple renderers.
2746         The FlowContents class will be used not just when we create runs, but also when we resolve them at painting time.
2747
2748         No change in functionality.
2749
2750         * CMakeLists.txt:
2751         * WebCore.vcxproj/WebCore.vcxproj:
2752         * WebCore.vcxproj/WebCore.vcxproj.filters:
2753         * WebCore.xcodeproj/project.pbxproj:
2754         * rendering/SimpleLineLayout.cpp:
2755         (WebCore::SimpleLineLayout::removeTrailingWhitespace):
2756         (WebCore::SimpleLineLayout::initializeNewLine):
2757         (WebCore::SimpleLineLayout::splitFragmentToFitLine):
2758         (WebCore::SimpleLineLayout::nextFragment):
2759         (WebCore::SimpleLineLayout::createLineRuns):
2760         (WebCore::SimpleLineLayout::closeLineEndingAndAdjustRuns):
2761         (WebCore::SimpleLineLayout::createTextRuns):
2762         (WebCore::SimpleLineLayout::FlowContentIterator::FlowContentIterator): Deleted.
2763         (WebCore::SimpleLineLayout::FlowContentIterator::findNextBreakablePosition): Deleted.
2764         (WebCore::SimpleLineLayout::FlowContentIterator::findNextNonWhitespacePosition): Deleted.
2765         (WebCore::SimpleLineLayout::FlowContentIterator::textWidth): Deleted.
2766         (WebCore::SimpleLineLayout::FlowContentIterator::isNewlineCharacter): Deleted.
2767         (WebCore::SimpleLineLayout::FlowContentIterator::isEndOfContent): Deleted.
2768         (WebCore::SimpleLineLayout::FlowContentIterator::style): Deleted.
2769         (WebCore::SimpleLineLayout::computeLineLeft): Deleted.
2770         * rendering/SimpleLineLayoutFlowContents.cpp: Added.
2771         (WebCore::SimpleLineLayout::FlowContents::FlowContents):
2772         (WebCore::SimpleLineLayout::FlowContents::findNextBreakablePosition):
2773         (WebCore::SimpleLineLayout::FlowContents::findNextNonWhitespacePosition):
2774         (WebCore::SimpleLineLayout::FlowContents::textWidth):
2775         * rendering/SimpleLineLayoutFlowContents.h: Added.
2776         (WebCore::SimpleLineLayout::FlowContents::Style::Style):
2777         (WebCore::SimpleLineLayout::FlowContents::style):
2778         (WebCore::SimpleLineLayout::FlowContents::isNewlineCharacter):
2779         (WebCore::SimpleLineLayout::FlowContents::isEndOfContent):
2780
2781 2014-11-17  Daniel Bates  <dabates@apple.com>
2782
2783         Unreviewed, rolling out r176232.
2784
2785         Broke the Mac build. Will investigate offline.
2786
2787         Reverted changeset:
2788
2789         "[iOS] Libdispatch, Dyld, IOKit, Mach, NSPointerFunctions,
2790         MobileGestalt"
2791         https://bugs.webkit.org/show_bug.cgi?id=138802
2792         http://trac.webkit.org/changeset/176232
2793
2794 2014-11-17  Daniel Bates  <dabates@apple.com>
2795
2796         [iOS] Libdispatch, Dyld, IOKit, Mach, NSPointerFunctions, MobileGestalt
2797         SPI are not available in public SDK
2798         https://bugs.webkit.org/show_bug.cgi?id=138802
2799
2800         Reviewed by David Kilzer.
2801
2802         Add SPI wrapper headers {Dispatch, DynamicLinker, IOPMLib, MachVM, NSPointerFunctions, MobileGestalt}SPI.h
2803         that forward declare applicable libdispatch, dyld, IOKit, mach, Foundation, MobileGestalt SPI
2804         and use these headers instead of the including private headers corresponding to these libraries/frameworks.
2805
2806         * WebCore.xcodeproj/project.pbxproj: Add private headers MobileGestaltSPI.h and
2807         MachVMSPI.h, and project headers DynamicLinkerSPI.h, NSPointerFunctionsSPI.h,
2808         DispatchSPI.h and IOPMLibSPI.h. Also, sort files in Xcode project.
2809         * bindings/objc/DOMInternal.mm: Include header NSPointerFunctionsSPI.h.
2810         * bridge/objc/objc_instance.mm: Ditto; Also, sort #import directives.
2811         * platform/cocoa/DisplaySleepDisablerCocoa.cpp: Substitute header IOPMLibSPI.h
2812         for private header IOKit/pwr_mgt/IOPMLib.h.
2813         * platform/cocoa/MemoryPressureHandlerCocoa.mm: Substitute header DispatchSPI.h
2814         for private header dispatch/private.h.
2815         * platform/graphics/ios/FontServicesIOS.mm: Substitute header DynamicLinkerSPI.h
2816         for private header mach-o/dyld_priv.h.
2817         * platform/ios/PlatformScreenIOS.mm: Substitute header MobileGestaltSPI.h for
2818         private header MobileGestalt.h.
2819         * platform/spi/cocoa/DispatchSPI.h: Added.
2820         * platform/spi/cocoa/DynamicLinkerSPI.h: Added.
2821         * platform/spi/cocoa/IOPMLibSPI.h: Added.
2822         * platform/spi/cocoa/MachVMSPI.h: Added.
2823         * platform/spi/cocoa/NSPointerFunctionsSPI.h: Added.
2824         * platform/spi/ios/MobileGestaltSPI.h: Added.
2825
2826 2014-11-17  Daniel Bates  <dabates@apple.com>
2827
2828         [iOS] CoreText and CoreUI SPI are not available in public SDK
2829         https://bugs.webkit.org/show_bug.cgi?id=138760
2830
2831         Reviewed by David Kilzer.
2832
2833         Add a SPI wrapper header CoreUISPI.h that forward declares CoreUI SPI
2834         and use this header instead of including private headers of CoreUI directly.
2835
2836         Additionally, add more forward declarations for CoreText SPI.
2837
2838         * WebCore.xcodeproj/project.pbxproj: Add project header CoreUISPI.h.
2839         * platform/graphics/ios/FontCacheIOS.mm: Include header CoreTextSPI.h instead
2840         of including CoreText headers directly.
2841         * platform/graphics/mac/FontMac.mm: Include header CoreUISPI.h instead
2842         of including CoreUI headers directly.
2843         * platform/graphics/mac/GlyphPageTreeNodeMac.cpp: Remove unnecessary
2844         include of CoreText headers. These headers will be included by header
2845         CoreTextSPI.h (at the top of the file).
2846         * platform/graphics/mac/SimpleFontDataMac.mm: Remove forward declaration
2847         of CTFontDescriptorIsSystemUIFont() and include of header CTFontDescriptorPriv.h
2848         as this duplicates the logic in CoreTextSPI.h, which is included in this file.
2849         * platform/spi/cocoa/CoreTextSPI.h: Added more forward declarations. Simplified
2850         #include directives.
2851         * platform/spi/ios/CoreUISPI.h: Added.
2852         * rendering/RenderThemeIOS.mm: Move CoreUI externs from this file to file
2853         CoreUISPI.h and include header CoreUISPI.h.
2854
2855 2014-11-17  Zalan Bujtas  <zalan@apple.com>
2856
2857         Simple line layout: Drop 16bit support temporarily.
2858         https://bugs.webkit.org/show_bug.cgi?id=138796
2859
2860         Reviewed by Antti Koivisto.
2861
2862         This is in preparation to multiple renderers support.
2863         It requires code refactoring on top of the coming multiple renderers codebase.
2864         (Not expecting any significant coverage shrinking.)
2865
2866         * rendering/SimpleLineLayout.cpp:
2867         (WebCore::SimpleLineLayout::canUseFor):
2868         (WebCore::SimpleLineLayout::FlowContentIterator::findNextBreakablePosition):
2869         (WebCore::SimpleLineLayout::FlowContentIterator::findNextNonWhitespacePosition):
2870         (WebCore::SimpleLineLayout::FlowContentIterator::textWidth):
2871         (WebCore::SimpleLineLayout::removeTrailingWhitespace):
2872         (WebCore::SimpleLineLayout::initializeNewLine):
2873         (WebCore::SimpleLineLayout::splitFragmentToFitLine):
2874         (WebCore::SimpleLineLayout::nextFragment):
2875         (WebCore::SimpleLineLayout::createLineRuns):
2876         (WebCore::SimpleLineLayout::closeLineEndingAndAdjustRuns):
2877         (WebCore::SimpleLineLayout::createTextRuns):
2878         (WebCore::SimpleLineLayout::create):
2879
2880 2014-11-17  Tim Horton  <timothy_horton@apple.com>
2881
2882         DataDetectors PageOverlay callbacks can come in to the wrong overlay
2883         https://bugs.webkit.org/show_bug.cgi?id=138801
2884         <rdar://problem/18991369>
2885
2886         Reviewed by Anders Carlsson.
2887
2888         * page/PageOverlay.cpp:
2889         (WebCore::generatePageOverlayID):
2890         (WebCore::PageOverlay::PageOverlay):
2891         * page/PageOverlay.h:
2892         Give each PageOverlay a unique ID.
2893
2894 2014-11-17  Javier Fernandez  <jfernandez@igalia.com>
2895
2896         [CSS Grid Layout] Upgrade align-self and align-items parsing to CSS 3
2897         https://bugs.webkit.org/show_bug.cgi?id=133359
2898
2899         Reviewed by David Hyatt.
2900
2901         Broaden justify-self's parsing name as a preparation of migrating
2902         align-self, align-items and justify-items to the CSS 3 Alignment syntax.
2903
2904         The current naming was too tied to justify-self and needs to
2905         be broadened. This will reduce the follow-up implementations'
2906         patches.
2907
2908         Upgrade align-self and align-items parsing to CSS 3
2909
2910         This change migrates the 2 properties to the CSS 3 Alignment
2911         parsing. The new parsing is identical to how we parse
2912         'justify-self'. The 2 properties need to be migrated together
2913         as they are used in tandem in CSSComputedStyleDeclaration.
2914
2915         This change also removes EAlignItems as it is now unused.
2916
2917         Tests: css3/parse-align-items.html
2918                css3/parse-align-self.html
2919
2920         * css/CSSComputedStyleDeclaration.cpp:
2921         (WebCore::valueForItemPositionWithOverflowAlignment): Added. Builds the CSSValue for the for the alignment properties.
2922         (WebCore::ComputedStyleExtractor::propertyValue):
2923         * css/CSSParser.cpp:
2924         (WebCore::isKeywordPropertyID): Removed align-items and align-self from the list.
2925         (WebCore::isValidKeywordPropertyAndValue): Removed align-items and align-self from the list.
2926         (WebCore::CSSParser::parseValue): Added align-items and align-self to the list and call to the generic parsing fuction for the alignment properties.
2927         (WebCore::isBaselinePositionKeyword): Utility function added to identify Baseline keyword values.
2928         (WebCore::CSSParser::parseItemPositionOverflowPosition): Generic parsing fuction for the alignment properties.
2929         (WebCore::CSSParser::parseJustifySelf): Deleted.
2930         * css/CSSParser.h:
2931         * css/CSSPrimitiveValueMappings.h:
2932         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Refactoring some mapping functions.
2933        (WebCore::CSSPrimitiveValue::operator ItemPosition): Added. Replace the old EAlignItems enumeration.
2934         (WebCore::CSSPrimitiveValue::operator OverflowAlignment): Added.
2935         (WebCore::CSSPrimitiveValue::operator EAlignItems): Deleted.
2936         (WebCore::CSSPrimitiveValue::operator EJustifySelf): Deleted.
2937         (WebCore::CSSPrimitiveValue::operator EJustifySelfOverflowAlignment): Deleted.
2938         * css/CSSPropertyNames.in:
2939         * css/CSSValueKeywords.in:
2940         * css/StyleResolver.cpp:
2941         (WebCore::StyleResolver::adjustRenderStyle): Added a new adjustment to resolve the "auto" vale on the alignment properties.
2942         (WebCore::StyleResolver::adjustStyleForAlignment): Added. Function to resolve the "auto" vale on the alignment properties. 
2943         (WebCore::StyleResolver::applyProperty):
2944         (WebCore::isDisplayFlexibleBox): Deleted. Moved to the RenderStyle.
2945         (WebCore::isDisplayGridBox): Deleted. Moved to the RenderStyle.
2946         (WebCore::isDisplayFlexibleOrGridBox): Deleted. Moved to the RenderStyle.
2947         * css/StyleResolver.h:
2948         * rendering/RenderBox.cpp:
2949         (WebCore::flexItemHasStretchAlignment): Adapted to the new ItemPosition enum.
2950         * rendering/RenderFlexibleBox.cpp:
2951         (WebCore::RenderFlexibleBox::firstLineBaseline): Adapted to the new ItemPosition enum.
2952         (WebCore::resolveAlignment): Consider also that align-items could be "auto", since it's the default now.
2953         (WebCore::RenderFlexibleBox::styleDidChange): Adapted to the new ItemPosition enum.
2954         (WebCore::RenderFlexibleBox::alignmentForChild): Adapted to the new ItemPosition enum.
2955         (WebCore::RenderFlexibleBox::needToStretchChild): Adapted to the new ItemPosition enum.
2956         (WebCore::RenderFlexibleBox::layoutAndPlaceChildren): Adapted to the new ItemPosition enum.
2957         (WebCore::RenderFlexibleBox::alignChildren): Adapted to the new ItemPosition enum.
2958         * rendering/RenderFlexibleBox.h:
2959         * rendering/RenderFullScreen.cpp:
2960         (WebCore::createFullScreenStyle): Adapted to the new ItemPosition enum.
2961         * rendering/RenderMenuList.cpp:
2962         (WebCore::RenderMenuList::adjustInnerStyle): Adapted to the new ItemPosition enum.
2963         * rendering/mathml/RenderMathMLRoot.cpp:
2964         (WebCore::RenderMathMLRoot::updateStyle): Adapted to the new ItemPosition enum.
2965         * rendering/mathml/RenderMathMLScripts.cpp:
2966         (WebCore::RenderMathMLScripts::fixAnonymousStyleForSubSupPair): Adapted to the new ItemPosition enum.
2967         (WebCore::RenderMathMLScripts::fixAnonymousStyles): Adapted to the new ItemPosition enum.
2968         * rendering/style/RenderStyle.h: Adapted to the new ItemPosition enum.
2969         * rendering/style/RenderStyleConstants.h: Adapted to the new ItemPosition enum.
2970         * rendering/style/StyleRareNonInheritedData.cpp: Adapted to the new ItemPosition enum.
2971         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData): Adapted to the new ItemPosition enum.
2972         (WebCore::StyleRareNonInheritedData::operator==): Adapted to the new ItemPosition enum.
2973         * rendering/style/StyleRareNonInheritedData.h: Adapted to the new ItemPosition enum.
2974         * style/StyleResolveTree.cpp:
2975         (WebCore::Style::determineChange): Changes in the alignItems property will cause a Detach.
2976
2977 2014-11-17  Shivakumar JM  <shiva.jm@samsung.com>
2978
2979         Attribute text in HTMLAnchorElement should behave as per specification.
2980         https://bugs.webkit.org/show_bug.cgi?id=138557
2981
2982         Reviewed by Darin Adler.
2983
2984         attribute text in HTMLAnchorElement should not be readonly as per specification
2985         http://www.w3.org/TR/html/text-level-semantics.html#dom-a-text. It should behave as textContent attribute. 
2986         Also This matches the behavior of Chrome 38 and FireFox.
2987
2988         Test: fast/dom/HTMLAnchorElement/anchor-text-attribute.html
2989
2990         * html/HTMLAnchorElement.cpp:
2991         (WebCore::HTMLAnchorElement::text):
2992         (WebCore::HTMLAnchorElement::setText):
2993         * html/HTMLAnchorElement.h:
2994         * html/HTMLAnchorElement.idl:
2995
2996 2014-11-17  Chris Dumez  <cdumez@apple.com>
2997
2998         Throttle timers that change the style of elements outside the viewport
2999         https://bugs.webkit.org/show_bug.cgi?id=138292
3000
3001         Reviewed by Antti Koivisto.
3002
3003         Throttle timers that change the style of elements outside the viewport
3004         to 1 second, similarly to what was already done for timers interacting
3005         with non user observable plugins. To be conservative, we don't throttle
3006         timers that also cause DOM Tree modifications (e.g. adding/removing
3007         nodes, modify element attributes).
3008
3009         On huffingtonpost.com, the CPU usage is at ~17% when the top scrolling
3010         banner is inside the viewport on my machine. Without this patch, CPU
3011         usage would stay ~17% when the banner is outside the viewport. Thanks
3012         to timer throttling, CPU usage now goes down to ~1.5%, without user
3013         observable side effects. The timers get unthrottled when they are
3014         inside the viewport again (i.e. due to scrolling or layout).
3015
3016         On espn.com, the CPU usage goes down from ~7% at the top of the page
3017         to ~1% when scrolling to the bottom of the page. On ebay.com, CPU
3018         usage goes down from ~25% at the top of the page to less than 1% when
3019         scrolling to the bottom of the page.
3020
3021 2014-11-17  peavo@outlook.com  <peavo@outlook.com>
3022
3023         [WinCairo] Compile error, CoreGraphics header file included.
3024         https://bugs.webkit.org/show_bug.cgi?id=138795
3025
3026         Reviewed by Brent Fulgham.
3027
3028         CoreGraphics is not available on WinCairo.
3029
3030         * platform/graphics/win/FontCacheWin.cpp:
3031
3032 2014-11-17  Commit Queue  <commit-queue@webkit.org>
3033
3034         Unreviewed, rolling out r176169.
3035         https://bugs.webkit.org/show_bug.cgi?id=138797
3036
3037         Appears to have broken svg/custom/anchor-on-use.svg (Requested
3038         by ap on #webkit).
3039
3040         Reverted changeset:
3041
3042         "Attribute text in HTMLAnchorElement should behave as per
3043         specification."
3044         https://bugs.webkit.org/show_bug.cgi?id=138557
3045         http://trac.webkit.org/changeset/176169
3046
3047 2014-11-17  Daniel Bates  <dabates@apple.com>
3048
3049         [iOS] AVKit and MediaPlayer SPI are not available in public SDK
3050         https://bugs.webkit.org/show_bug.cgi?id=138756
3051
3052         Reviewed by Eric Carlson.
3053
3054         Add a SPI wrapper headers {AVKit, MPAVRoutingController}SPI.h that forward declares
3055         AVKit and MPAVRoutingController SPI, respectively, and use these header instead of
3056         including private headers of AVKit and MediaPlayer directly.
3057
3058         * WebCore.xcodeproj/project.pbxproj: Add project and private header AVKitSPI.h
3059         and MPAVRoutingControllerSPI.h, respectively.
3060         * platform/audio/ios/MediaSessionManagerIOS.mm: Include header MPAVRoutingControllerSPI.h
3061         instead of including the private header MPAVRoutingController.h.
3062         * platform/ios/WebVideoFullscreenInterfaceAVKit.mm: Include header AVKitSPI.h
3063         instead of including AVKit headers directly.
3064
3065 2014-11-17  Daniel Bates  <dabates@apple.com>
3066
3067         Attempt to fix the Mac build after <https://trac.webkit.org/changeset/176204>
3068         (https://bugs.webkit.org/show_bug.cgi?id=138751)
3069
3070         Move declaration of CAContext to be before the declaration of CALayer since
3071         the latter depends on the former.
3072
3073         * platform/spi/cocoa/QuartzCoreSPI.h:
3074
3075 2014-11-17  Daniel Bates  <dabates@apple.com>
3076
3077         [iOS] QuartzCore SPI not available in public SDK
3078         https://bugs.webkit.org/show_bug.cgi?id=138751
3079
3080         Reviewed by David Kilzer.
3081
3082         Add a SPI wrapper header called QuartzCoreSPI.h that forward declares
3083         QuartzCore SPI and use this header instead of including private headers
3084         of QuartzCore directly.
3085
3086         * WebCore.xcodeproj/project.pbxproj: Added private header QuartzCoreSPI.h.
3087         * platform/graphics/ca/mac/PlatformCAFiltersMac.h: Removed; incorporated its
3088         functionality into QuartzCoreSPI.h.
3089         * platform/graphics/ca/mac/PlatformCAFiltersMac.mm: Substitute header
3090         QuartzCoreSPI.h for PlatformCAFiltersMac.h as the content of the latter
3091         was incorporated into the former.
3092         * platform/graphics/ca/mac/PlatformCALayerMac.mm: Move CALayer and CATiledLayer
3093         forward declarations from this file to file QuartzCoreSPI.h and include
3094         header QuartzCoreSPI.h instead of including CATiledLayerPrivate.h directly. Also
3095         remove header PlatformCAFiltersMac.h as its content is incorporated into QuartzCoreSPI.h
3096         * platform/ios/LegacyTileCache.mm: Include headers CoreGraphicsSPI.h and QuartzCoreSPI.h
3097         instead of including QuartzCore headers directly.
3098         * platform/ios/LegacyTileGrid.mm: Include header QuartzCoreSPI.h instead
3099         of including QuartzCore headers directly. Also sort the list of #include directives.
3100         * platform/ios/LegacyTileGridTile.mm: Include header QuartzCoreSPI.h
3101         instead of including QuartzCore headers directly.
3102         * platform/spi/cocoa/QuartzCoreSPI.h: Added.
3103
3104 2014-11-17  Chris Dumez  <cdumez@apple.com>
3105
3106         Move more CSS properties to the new StyleBuilder
3107         https://bugs.webkit.org/show_bug.cgi?id=138766
3108
3109         Reviewed by Darin Adler.
3110
3111         Move more CSS properties from DeprecatedStyleBuilder to the new
3112         StyleBuilder:
3113         line-height
3114         word-spacing
3115         -webkit-marquee-repetition
3116         -webkit-text-underline-position
3117
3118         No new tests, no behavior change.
3119
3120         * css/CSSPropertyNames.in:
3121         * css/DeprecatedStyleBuilder.cpp:
3122         (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
3123         (WebCore::csstoLengthConversionDataWithTextZoomFactor): Deleted.
3124         (WebCore::ApplyPropertyMarqueeRepetition::applyValue): Deleted.
3125         (WebCore::ApplyPropertyMarqueeRepetition::createHandler): Deleted.
3126         (WebCore::ApplyPropertyTextUnderlinePosition::applyValue): Deleted.
3127         (WebCore::ApplyPropertyTextUnderlinePosition::createHandler): Deleted.
3128         (WebCore::ApplyPropertyLineHeight::applyValue): Deleted.
3129         (WebCore::ApplyPropertyLineHeight::createHandler): Deleted.
3130         (WebCore::ApplyPropertyLineHeightForIOSTextAutosizing::applyValue): Deleted.
3131         (WebCore::ApplyPropertyLineHeightForIOSTextAutosizing::applyInitialValue): Deleted.
3132         (WebCore::ApplyPropertyLineHeightForIOSTextAutosizing::applyInheritValue): Deleted.
3133         (WebCore::ApplyPropertyLineHeightForIOSTextAutosizing::createHandler): Deleted.
3134         (WebCore::ApplyPropertyWordSpacing::applyValue): Deleted.
3135         (WebCore::ApplyPropertyWordSpacing::createHandler): Deleted.
3136         * css/StyleBuilderConverter.h:
3137         (WebCore::StyleBuilderConverter::convertMarqueeRepetition):
3138         (WebCore::StyleBuilderConverter::convertTextUnderlinePosition):
3139         * css/StyleBuilderCustom.h:
3140         (WebCore::StyleBuilderFunctions::csstoLengthConversionDataWithTextZoomFactor):
3141         (WebCore::StyleBuilderFunctions::convertLineHeight):
3142         (WebCore::StyleBuilderFunctions::applyValueWordSpacing):
3143         (WebCore::StyleBuilderFunctions::applyInheritLineHeight):
3144         (WebCore::StyleBuilderFunctions::applyInitialLineHeight):
3145         (WebCore::StyleBuilderFunctions::applyValueLineHeight):
3146
3147 2014-11-16  Andreas Kling  <akling@apple.com>
3148
3149         Avoid synchronous style recalc when mutating a Node inside FrameSelection.
3150         <https://webkit.org/b/138791>
3151
3152         Reviewed by Antti Koivisto.
3153
3154         We can safely clear the RenderView's selection without doing a synchronous
3155         style recalc first.
3156
3157         This is a small progression on Speedometer locally.
3158
3159         * editing/FrameSelection.cpp:
3160         (WebCore::DragCaretController::nodeWillBeRemoved):
3161         (WebCore::FrameSelection::respondToNodeModification):
3162         (WebCore::clearRenderViewSelection): Deleted.
3163
3164             Merged clearRenderViewSelection() into the call sites and removed
3165             the now-unnecessary protection of the Document.
3166
3167 2014-11-17  Eric Carlson  <eric.carlson@apple.com>
3168
3169         [iOS] allow host application to opt-out of alternate fullscreen
3170         https://bugs.webkit.org/show_bug.cgi?id=138787
3171
3172         Reviewed by Darin Adler.
3173
3174         * Modules/mediacontrols/MediaControlsHost.cpp:
3175         (WebCore::MediaControlsHost::optimizedFullscreenSupported): Check mediaSession().allowsAlternateFullscreen.
3176
3177         * html/HTMLMediaElement.cpp:
3178         (WebCore::HTMLMediaElement::enterFullscreenOptimized): Do nothing if
3179             mediaSession().allowsAlternateFullscreen says it isn't allowed.
3180
3181         * html/HTMLMediaSession.cpp:
3182         (WebCore::HTMLMediaSession::allowsAlternateFullscreen): New, check settings.
3183         * html/HTMLMediaSession.h:
3184
3185         * page/Settings.cpp: Add allowsAlternateFullscreen.
3186         * page/Settings.in: Ditto.
3187
3188 2014-11-16  Zan Dobersek  <zdobersek@igalia.com>
3189
3190         Replace RenderSVGResource::cast<T>() with downcast<T>()
3191         https://bugs.webkit.org/show_bug.cgi?id=138290
3192
3193         Reviewed by Chris Dumez.
3194
3195         Add type traits for the RenderSVGResource hierarchy. This enables
3196         using the typecasting framework in getRenderSVGResourceById() that
3197         in return renders the RenderSVGResource::cast<>() template and all
3198         the static s_resourceType member variables in the hierarchy removable.
3199
3200         * WebCore.order:
3201         * rendering/svg/RenderSVGResource.h:
3202         (WebCore::RenderSVGResource::cast): Deleted.
3203         * rendering/svg/RenderSVGResourceClipper.h:
3204         * rendering/svg/RenderSVGResourceContainer.h:
3205         (WebCore::getRenderSVGResourceById):
3206         * rendering/svg/RenderSVGResourceFilter.h:
3207         (isType):
3208         * rendering/svg/RenderSVGResourceLinearGradient.h:
3209         * rendering/svg/RenderSVGResourceMarker.h:
3210         * rendering/svg/RenderSVGResourceMasker.h:
3211         * rendering/svg/RenderSVGResourcePattern.h:
3212         * rendering/svg/RenderSVGResourceRadialGradient.h:
3213         * rendering/svg/RenderSVGResourceSolidColor.h:
3214
3215 2014-11-16  Benjamin Poulain  <benjamin@webkit.org>
3216
3217         Implement :valid and :invalid matching for the fieldset element
3218         https://bugs.webkit.org/show_bug.cgi?id=138769
3219
3220         Reviewed by Darin Adler.
3221
3222         In the latest HTML spec, the pseudo classes :valid and :invalid match
3223         a fieldset element based on its descendants:
3224             https://html.spec.whatwg.org/#selector-valid
3225             https://html.spec.whatwg.org/#selector-invalid
3226
3227         This patch adds that behavior.
3228
3229         There are two key problems to solve with these pseudo classes on fieldset:
3230         -Efficient matching.
3231         -Style invalidation when any of the descendant changes.
3232
3233         To implement the style invalidation, I have modified HTMLFormControlElement
3234         to notify its ancestor when its state changes.
3235
3236         The first change is making the state fully internal to HTMLFormControlElement,
3237         we do not want subclass to be able to change the behavior and forget to update
3238         the ancestors.
3239
3240         To achieve that encapsulation, the interface was changed a bit:
3241         -Neither willValidate() nor isValidFormControlElement() inherit from Element.
3242          Instead, willValidate() is the implementation of FormAssociatedElement's interface
3243          and it is final. The method isValidFormControlElement() becomes completely internal
3244          to HTMLFormControlElement.
3245         -Since willValidate() should no longer be re-implemented by subclass, the elements
3246          that were depending on it have been migrated to recalcWillValidate() to set
3247          the initial state as needed.
3248
3249         With the validity state fully encapsulated in HTMLFormControlElement, all I need
3250         is a way to communicate that information to HTMLFieldSetElement ancestors.
3251         This is done in two cases:
3252         -The validity state changes.
3253         -The tree changes in a way that would make the input element not a descendant
3254          of a HTMLFieldSetElement.
3255
3256         The invalidation is simply done by walking up the ancestors and adding the current
3257         element to a "validity dependency list" on each HTMLFieldSetElement.
3258
3259         Tests: fast/css/pseudo-invalid-fieldset-invalidation-optimization.html
3260                fast/css/pseudo-invalid-fieldset-style-sharing.html
3261                fast/css/pseudo-invalid-fieldset.html
3262                fast/css/pseudo-valid-fieldset-invalidation-optimization.html
3263                fast/css/pseudo-valid-fieldset-style-sharing.html
3264                fast/css/pseudo-valid-fieldset.html
3265                fast/selectors/invalid-fieldset-style-update-1.html
3266                fast/selectors/invalid-fieldset-style-update-2.html
3267                fast/selectors/invalid-fieldset-style-update-3.html
3268                fast/selectors/invalid-fieldset-style-update-4.html
3269                fast/selectors/invalid-fieldset-style-update-5.html
3270                fast/selectors/valid-fieldset-style-update-1.html
3271                fast/selectors/valid-fieldset-style-update-2.html
3272                fast/selectors/valid-fieldset-style-update-3.html
3273                fast/selectors/valid-fieldset-style-update-4.html
3274                fast/selectors/valid-fieldset-style-update-5.html
3275
3276         * css/SelectorCheckerTestFunctions.h:
3277         (WebCore::isInRange):
3278         (WebCore::isOutOfRange):
3279         (WebCore::isInvalid):
3280         (WebCore::isValid):
3281         The hack "ContainsValidityStyleRules" is in the way of correct styling
3282         of FieldSet and Form.
3283         It is not the right way to get stylesheet properties anyway.
3284
3285         * css/StyleResolver.cpp:
3286         (WebCore::StyleResolver::canShareStyleWithControl):
3287         Make sure style sharing does not incorrectly share style for fieldset elements.
3288
3289         * dom/Document.cpp:
3290         (WebCore::Document::Document):
3291         * dom/Document.h:
3292         (WebCore::Document::containsValidityStyleRules): Deleted.
3293         (WebCore::Document::setContainsValidityStyleRules): Deleted.
3294         * dom/Element.h:
3295         (WebCore::Element::matchesValidPseudoClass):
3296         (WebCore::Element::matchesInvalidPseudoClass):
3297         (WebCore::Element::willValidate): Deleted.
3298         (WebCore::Element::isValidFormControlElement): Deleted.
3299         * html/FormAssociatedElement.cpp:
3300         (WebCore::FormAssociatedElement::customError):
3301         * html/FormAssociatedElement.h:
3302
3303         * html/HTMLFieldSetElement.cpp:
3304         (WebCore::HTMLFieldSetElement::matchesValidPseudoClass):
3305         (WebCore::HTMLFieldSetElement::matchesInvalidPseudoClass):
3306         (WebCore::HTMLFieldSetElement::addInvalidDescendant):
3307         (WebCore::HTMLFieldSetElement::removeInvalidDescendant):
3308         Each HTMLFormControlElement that has constraint validation adds or removes
3309         itself from its HTMLFieldSetElement ancestors.
3310
3311         It should be possible to just keep track of a count instead of a HashSet.
3312         I decided to got with the HashSet to make the code more robust and easier
3313         to debug. A few assertions ensure that the HashSet is actually used as a counter.
3314
3315         * html/HTMLFieldSetElement.h:
3316         * html/HTMLFormControlElement.cpp:
3317         (WebCore::addInvalidElementToAncestorFromInsertionPoint):
3318         (WebCore::removeInvalidElementToAncestorFromInsertionPoint):
3319
3320         (WebCore::HTMLFormControlElement::insertedInto):
3321         (WebCore::HTMLFormControlElement::removedFrom):
3322         One tricky part of those two functions is that we cannot use
3323         matchesValidPseudoClass() or matchesInvalidPseudoClass().
3324
3325         The reason is that HTMLFieldSetElement is a subclass of HTMLFormControlElement
3326         and it has its own definition of what Valid and Invalid mean when matching selectors.
3327
3328         In HTMLFormControlElement, we must use the internal state,
3329         willValidate() and isValidFormControlElement() must be used directly.
3330
3331         (WebCore::HTMLFormControlElement::matchesValidPseudoClass):
3332         (WebCore::HTMLFormControlElement::matchesInvalidPseudoClass):
3333         (WebCore::HTMLFormControlElement::willValidate):
3334         (WebCore::addInvalidElementToAncestors):
3335         (WebCore::removeInvalidElementFromAncestors):
3336         (WebCore::HTMLFormControlElement::setNeedsWillValidateCheck):
3337         (WebCore::HTMLFormControlElement::setNeedsValidityCheck):
3338         (WebCore::HTMLFormControlElement::isValidFormControlElement): Deleted.
3339         * html/HTMLFormControlElement.h:
3340         (WebCore::HTMLFormControlElement::isValidFormControlElement):
3341         * html/HTMLKeygenElement.h:
3342         * html/HTMLObjectElement.h:
3343         * html/HTMLOutputElement.h:
3344
3345 2014-11-16  Zan Dobersek  <zdobersek@igalia.com>
3346
3347         [TexMap] Add typecasting support for GraphicsLayerTextureMapper
3348         https://bugs.webkit.org/show_bug.cgi?id=138741
3349
3350         Reviewed by Martin Robinson.
3351
3352         Add type traits for the GraphicsLayerTextureMapper class.
3353         This enables using typecasting functions instead of
3354         toGraphicsLayerTextureMapper().
3355
3356         Remove toTextureMapperLayer() casting function which actually
3357         returned the TextureMapperLayer object that belonged to the
3358         passed-in GraphicsLayerTextureMapper. Instead, the GraphicsLayer
3359         object is now downcasted and the TextureMapperLayer is accessed
3360         by calling the GraphicsLayerTextureMapper::layer() method.
3361
3362         * platform/graphics/GraphicsLayer.h:
3363         (WebCore::GraphicsLayer::isGraphicsLayerTextureMapper):
3364         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
3365         (WebCore::toTextureMapperLayerVector):
3366         (WebCore::GraphicsLayerTextureMapper::commitLayerChanges):
3367         (WebCore::toTextureMapperLayer): Deleted.
3368         * platform/graphics/texmap/GraphicsLayerTextureMapper.h:
3369         (WebCore::toGraphicsLayerTextureMapper): Deleted.
3370
3371 2014-11-16  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
3372
3373         Move WebCore/loader to std::unique_ptr
3374         https://bugs.webkit.org/show_bug.cgi?id=138646
3375
3376         Reviewed by Chris Dumez.
3377
3378         Replace OwnPtr with std::unique_ptr<> and std::make_unique<>.
3379         However this patch leaves ResourceRequest::adopt() because this need
3380         to be handled by different patch.
3381
3382         No new tests, no behavior changes.
3383
3384         * loader/DocumentThreadableLoader.cpp:
3385         (WebCore::DocumentThreadableLoader::makeCrossOriginAccessRequest):
3386         (WebCore::DocumentThreadableLoader::preflightSuccess):
3387         * loader/DocumentThreadableLoader.h:
3388         * loader/SubresourceLoader.cpp:
3389         (WebCore::SubresourceLoader::SubresourceLoader):
3390         (WebCore::SubresourceLoader::didReceiveResponse):
3391         (WebCore::SubresourceLoader::notifyDone):
3392         * loader/SubresourceLoader.h:
3393         * loader/TextTrackLoader.h:
3394         * loader/appcache/ApplicationCacheHost.h:
3395         * loader/appcache/ApplicationCacheStorage.cpp:
3396         (WebCore::ApplicationCacheStorage::storeCopyOfCache):
3397         * loader/archive/cf/LegacyWebArchive.cpp:
3398         (WebCore::LegacyWebArchive::create):
3399         * loader/cache/CachedResourceLoader.cpp:
3400         (WebCore::CachedResourceLoader::requestPreload):
3401         (WebCore::CachedResourceLoader::clearPreloads):
3402         (WebCore::CachedResourceLoader::printPreloadStats):
3403         * loader/cache/CachedResourceLoader.h:
3404         * loader/icon/IconDatabase.cpp:
3405         (WebCore::IconDatabase::deleteAllPreparedStatements):
3406         (WebCore::readySQLiteStatement):
3407         * loader/icon/IconDatabase.h:
3408         * loader/icon/IconRecord.h:
3409
3410 2014-11-16  Chris Dumez  <cdumez@apple.com>
3411
3412         Crash when setting 'order' CSS property to a calculated value
3413         https://bugs.webkit.org/show_bug.cgi?id=138780
3414
3415         Reviewed by Darin Adler.
3416
3417         CSS Calculated values were not handled by the CSS parser for 'order'
3418         CSS property. As a result, using calculated values wouldn't work in
3419         release builds and would hit an assertion in debug builds.
3420
3421         This patch updates the CSS parser to directly convert the
3422         CSS Calculated value into a simple integer CSSPrimitiveValue for
3423         'order' property. We could have marked CSS Calculated values as
3424         valid in the CSS Parser instead but this would have brought issues:
3425         - The calculated value needs to be adjusted to INT_MIN + 2 if it is less
3426           than that. This would force us to calculate the expression anyway.
3427         - The StyleBuilder would need updating to properly handle CSS Calculated
3428           values for 'order'.
3429
3430         Test: fast/css/order-calculated-value.html
3431
3432         * css/CSSParser.cpp:
3433         (WebCore::CSSParser::parseValue):
3434
3435 2014-11-16  Chris Dumez  <cdumez@apple.com>
3436
3437         Assertion hit when setting a very large value to 'border-width' / 'font-size' CSS properties
3438         https://bugs.webkit.org/show_bug.cgi?id=138770
3439
3440         Reviewed by Darin Adler.