Remove comment from Filter.h
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2014-03-27  Adenilson Cavalcanti  <cavalcantii@gmail.com>
2
3         Remove comment from Filter.h
4         https://bugs.webkit.org/show_bug.cgi?id=130848
5
6         Reviewed by Simon Fraser.
7
8         Exploring the use of consts on applyScale() methods didn't yield
9         good results.
10
11         No new tests, no change on behavior.
12
13         * platform/graphics/filters/Filter.h:
14
15 2014-03-27  Frédéric Wang  <fred.wang@free.fr>
16
17         Operator stretching: expose a math data API
18         https://bugs.webkit.org/show_bug.cgi?id=130572
19
20         Reviewed by Chris Fleizach.
21
22         We expose a new SimpleFontData API to give access to the data from the
23         OpenType MATH table using a font cache. The class OpenTypeMathData will
24         be implemented in bug 130324. On Darwin platform, we also implement the
25         missing FontPlatformData::openTypeTable function which will be necessary
26         to load the OpenType MATH table. The changes are intended to be used
27         for MathML operator stretching (bug 130322) so tests are not added yet.
28
29         * CMakeLists.txt: add new OpenTypeMathData files.
30         * WebCore.vcxproj/WebCore.vcxproj: ditto.
31         * WebCore.vcxproj/WebCore.vcxproj.filters: ditto.
32         * WebCore.xcodeproj/project.pbxproj: ditto.
33         * platform/graphics/FontCache.cpp: We add a FontCache::getMathData function to implement a cache for the math data.
34         We make the math and vertical data share the same key for the cache.
35         (WebCore::fontMathDataCacheInstance):
36         (WebCore::FontCache::getMathData):
37         (WebCore::fontVerticalDataCacheInstance):
38         * platform/graphics/FontCache.h: We declare FontCache::getMathData and FontFileKey on all platforms.
39         * platform/graphics/FontPlatformData.cpp:
40         (WebCore::FontPlatformData::openTypeTable): We implement openTypeTable() on Darwin platform.
41         * platform/graphics/FontPlatformData.h: We expose openTypeTable() on Darwin platform.
42         * platform/graphics/SimpleFontData.cpp: We initialize m_mathData from the font cache.
43         (WebCore::SimpleFontData::SimpleFontData):
44         * platform/graphics/SimpleFontData.h: We expose a mathData() function to access the MATH data.
45         * platform/graphics/opentype/OpenTypeMathData.cpp: Added. This is a new class that will be used to parse the data from the OpenType MATH table.
46         (WebCore::OpenTypeMathData::OpenTypeMathData):
47         * platform/graphics/opentype/OpenTypeMathData.h: Added.
48         (WebCore::OpenTypeMathData::create):
49         (WebCore::OpenTypeMathData::hasMathData):
50
51 2014-03-27  Brent Fulgham  <bfulgham@apple.com>
52
53         Fix a crash caused by track insertion after load()
54         https://bugs.webkit.org/show_bug.cgi?id=130777
55
56         Reviewed by Eric Carlson.
57
58         Test: media/track/track-insert-after-load-crash.html
59
60         Based on the Blink change (patch by acolwell@chromium.org):
61         https://codereview.chromium.org/211373009/
62
63         * html/HTMLMediaElement.cpp:
64         (WebCore::HTMLMediaElement::parseAttribute): Remove stale LoadMediaResource flag after explicit load.
65
66 2014-03-27  Alexey Proskuryakov  <ap@apple.com>
67
68         Connection::dispatchOneMessage() can be re-entered while handling Cmd-key menu
69         equivalents, ASSERT(!_data->_keyDownEventBeingResent)
70         https://bugs.webkit.org/show_bug.cgi?id=130767
71         <rdar://problem/16307487>
72
73         Added a wrapper for RunLoop::initializeMainThread that also adds modal run loop
74         mode to it on Mac.
75
76         * CMakeLists.txt:
77         * WebCore.exp.in:
78         * WebCore.vcxproj/WebCore.vcxproj:
79         * WebCore.vcxproj/WebCore.vcxproj.filters:
80         * WebCore.xcodeproj/project.pbxproj:
81         * platform/MainRunLoop.cpp: Added.
82         (WebCore::initializeMainRunLoop):
83         * platform/MainRunLoop.h: Added.
84         * platform/mac/MainRunLoop.mm: Added.
85         (WebCore::initializeMainRunLoop):
86
87 2014-03-27  Krzysztof Czech  <k.czech@samsung.com>
88
89         AX: Returns const reference to static string.
90         https://bugs.webkit.org/show_bug.cgi?id=130835
91
92         Reviewed by Mario Sanchez Prada.
93
94         Avoiding some unnecessary copies by returning const reference to static string.
95
96         No new tests. No behaviour change.
97
98         * accessibility/AccessibilityMediaControls.cpp:
99         (WebCore::AccessibilityMediaControl::controlTypeName):
100         (WebCore::AccessibilityMediaControlsContainer::elementTypeName):
101         * accessibility/AccessibilityMediaControls.h:
102
103 2014-03-27  Mihnea Ovidenie  <mihnea@adobe.com>
104
105         [CSSRegions] Rename inNamedFlow flag to isNamedFlowContentNode flag
106         https://bugs.webkit.org/show_bug.cgi?id=130731
107
108         Reviewed by Andrei Bucur.
109
110         Currently, the inNamedFlow flag in Node class tells if a node is a content node, one that has a style with flow-into.
111         Since it is used only for those nodes and not propagated through hierarchy, i want to renamed it to a more meaningful name.
112         No new functionality, no new tests.
113
114         * dom/ContainerNode.cpp:
115         (WebCore::destroyRenderTreeIfNeeded):
116         * dom/Element.cpp:
117         (WebCore::Element::~Element):
118         (WebCore::Element::unregisterNamedFlowContentElement):
119         * dom/Node.h:
120         (WebCore::Node::isNamedFlowContentNode):
121         (WebCore::Node::setIsNamedFlowContentNode):
122         (WebCore::Node::clearIsNamedFlowContentNode):
123         * rendering/RenderNamedFlowThread.cpp:
124         (WebCore::RenderNamedFlowThread::clearContentElements):
125         (WebCore::RenderNamedFlowThread::registerNamedFlowContentElement):
126         (WebCore::RenderNamedFlowThread::unregisterNamedFlowContentElement):
127         (WebCore::nextNodeInsideContentElement):
128         * style/StyleResolveTree.cpp:
129         (WebCore::Style::attachChildren):
130         (WebCore::Style::resolveLocal):
131
132 2014-03-27  Mihnea Ovidenie  <mihnea@adobe.com>
133
134         [CSSRegions] Crash when cloning a region child with a content node child
135         https://bugs.webkit.org/show_bug.cgi?id=129811
136
137         Reviewed by David Hyatt.
138
139         Collecting the children of a region in another named flow will be supported
140         again in the future and it will be revisited when we will implement the content
141         keyword: http://dev.w3.org/csswg/css-regions-1/#the-flow-into-property.
142         Remove the support for now as it introduces unnecessary complexity in the code
143         and potential wrong behavior.
144
145         Test: fast/regions/region-content-node-child-clone-crash.html
146
147         * dom/Element.cpp:
148         (WebCore::Element::shouldMoveToFlowThread):
149         (WebCore::Element::clearStyleDerivedDataBeforeDetachingRenderer):
150         * dom/Element.h:
151         * dom/ElementRareData.h:
152         (WebCore::ElementRareData::ElementRareData):
153         * rendering/FlowThreadController.cpp:
154         * rendering/FlowThreadController.h:
155         * style/StyleResolveTree.cpp:
156         (WebCore::Style::moveToFlowThreadIfNeeded):
157         (WebCore::Style::createRendererIfNeeded):
158
159 2014-03-27  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
160
161         Remove unneeded mutable keyword in some member variables 
162         https://bugs.webkit.org/show_bug.cgi?id=130813
163
164         Reviewed by Andreas Kling.
165
166         Some member variables have mutable keyword though they don't used by const function.
167         This patch removes them. 
168
169         No new tests, no behavior changes. Just clean up.
170
171         * storage/StorageAreaSync.h:
172         * svg/animation/SVGSMILElement.h:
173
174 2014-03-27  Commit Queue  <commit-queue@webkit.org>
175
176         Unreviewed, rolling out r166296 and r166331.
177         https://bugs.webkit.org/show_bug.cgi?id=130822
178
179         caused some crashes and frequent assertion failures, and the
180         fix is going to take a little while (Requested by thorton on
181         #webkit).
182
183         Reverted changesets:
184
185         "[iOS WebKit2] Flush all surfaces after painting into all of
186         them, instead of after painting into each one"
187         https://bugs.webkit.org/show_bug.cgi?id=130768
188         http://trac.webkit.org/changeset/166296
189
190         "Assertion failure in RemoteLayerBackingStore::flush"
191         https://bugs.webkit.org/show_bug.cgi?id=130810
192         http://trac.webkit.org/changeset/166331
193
194 2014-03-26  Simon Fraser  <simon.fraser@apple.com>
195
196         Fix failing scrolling tests by reverting to previous behavior where
197         the scrolling geometry for the main frame scrolling node was only
198         updated from frameViewLayoutUpdated() and no-where else.
199
200         * WebCore.exp.in:
201         * page/scrolling/AsyncScrollingCoordinator.cpp:
202         (WebCore::AsyncScrollingCoordinator::updateScrollingNode):
203         * page/scrolling/AsyncScrollingCoordinator.h:
204         * page/scrolling/ScrollingCoordinator.h:
205         (WebCore::ScrollingCoordinator::updateScrollingNode):
206         * rendering/RenderLayerCompositor.cpp:
207         (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
208         (WebCore::RenderLayerCompositor::detachScrollCoordinatedLayer): Deleted.
209
210 2014-03-26  Ryosuke Niwa  <rniwa@webkit.org>
211
212         HTMLConverter::_processText is slow because it walks up ancestor elements
213         https://bugs.webkit.org/show_bug.cgi?id=130820
214
215         Reviewed by Sam Weinig.
216
217         Avoid walking up the tree from each text node by caching the aggregated attributed strings for each element.
218         Also compute the attributed strings top-down to avoid calling mutableCopy in every iteration. 
219
220         This reduces the runtime of Interactive/CopyAll.html from 15s to 13s (15%).
221
222         * editing/cocoa/HTMLConverter.mm:
223         (HTMLConverter::_attributesForElement):
224         (HTMLConverter::attributesForElement):
225         (HTMLConverter::aggregatedAttributesForAncestors):
226         (HTMLConverter::_processText):
227
228 2014-03-26  Sam Weinig  <sam@webkit.org>
229
230         Fix iOS build.
231
232         * editing/cocoa/HTMLConverter.mm:
233         (_font):
234
235 2014-03-26  Ryosuke Niwa  <rniwa@webkit.org>
236
237         Make _processText and _traverseNode in HTMLConverter more efficient
238         https://bugs.webkit.org/show_bug.cgi?id=130769
239
240         Reviewed by Sam Weinig.
241
242         Rewrote a bunch of code in C++ and avoided creating wrappers.
243         This reduces the runtime of Interactive/CopyAll.html from ~16.5s to 15s.
244
245         * editing/cocoa/HTMLConverter.mm:
246         (HTMLConverterCaches::isAncestorsOfStartToBeConverted):
247         (HTMLConverter::HTMLConverter):
248         (HTMLConverter::~HTMLConverter):
249         (HTMLConverter::_processElement):
250         (HTMLConverter::_processText):
251         (HTMLConverter::_traverseNode):
252         (HTMLConverter::_traverseFooterNode):
253         (HTMLConverterCaches::cacheAncestorsOfStartToBeConverted):
254         (HTMLConverter::_loadFromDOMRange):
255
256 2014-03-26  Adenilson Cavalcanti  <cavalcantii@gmail.com>
257
258         FEGaussianBlur: unify and const-ify calculateKernelSize
259         https://bugs.webkit.org/show_bug.cgi?id=130779
260
261         Some methods can benefit of using const refs as also make sense to
262         unify the interface (i.e. parameters) in calculateKernelSize/Unscaled.
263
264         FilterEffect::filter() will now return a reference, which helps since
265         its descendants were accessing methods into the pointer without testing
266         for it.
267
268         Reviewed by Simon Fraser.
269
270         No new tests, no changes on behavior.
271
272         * platform/graphics/filters/FEDisplacementMap.cpp:
273         (WebCore::FEDisplacementMap::platformApplySoftware):
274         * platform/graphics/filters/FEDropShadow.cpp:
275         (WebCore::FEDropShadow::determineAbsolutePaintRect):
276         (WebCore::FEDropShadow::platformApplySoftware):
277         * platform/graphics/filters/FEGaussianBlur.cpp:
278         (WebCore::FEGaussianBlur::calculateUnscaledKernelSize):
279         (WebCore::FEGaussianBlur::calculateKernelSize):
280         (WebCore::FEGaussianBlur::determineAbsolutePaintRect):
281         (WebCore::FEGaussianBlur::platformApplySoftware):
282         * platform/graphics/filters/FEGaussianBlur.h:
283         * platform/graphics/filters/FEMorphology.cpp:
284         (WebCore::FEMorphology::determineAbsolutePaintRect):
285         (WebCore::FEMorphology::platformApplySoftware):
286         * platform/graphics/filters/FEOffset.cpp:
287         (WebCore::FEOffset::determineAbsolutePaintRect):
288         (WebCore::FEOffset::platformApplySoftware):
289         * platform/graphics/filters/FETile.cpp:
290         (WebCore::FETile::platformApplySoftware):
291         * platform/graphics/filters/FETurbulence.cpp:
292         (WebCore::FETurbulence::fillRegion):
293         * platform/graphics/filters/Filter.h:
294         (WebCore::Filter::applyHorizontalScale):
295         (WebCore::Filter::applyVerticalScale):
296         * platform/graphics/filters/FilterEffect.h:
297         (WebCore::FilterEffect::filter):
298         * platform/graphics/filters/SourceAlpha.cpp:
299         (WebCore::SourceAlpha::determineAbsolutePaintRect):
300         (WebCore::SourceAlpha::platformApplySoftware):
301         * platform/graphics/filters/SourceGraphic.cpp:
302         (WebCore::SourceGraphic::determineAbsolutePaintRect):
303         (WebCore::SourceGraphic::platformApplySoftware):
304         * rendering/svg/RenderSVGResourceFilterPrimitive.cpp:
305         (WebCore::RenderSVGResourceFilterPrimitive::determineFilterPrimitiveSubregion):
306         * svg/graphics/filters/SVGFEImage.cpp:
307         (WebCore::FEImage::determineAbsolutePaintRect):
308         (WebCore::FEImage::platformApplySoftware):
309
310 2014-03-26  Simon Fraser  <simon.fraser@apple.com>
311
312         Make sure childContainmentLayer is parented
313         https://bugs.webkit.org/show_bug.cgi?id=130808
314
315         Reviewed by Tim Horton.
316
317         m_childContainmentLayer was never parented if the page
318         created no other compositing layers, which left a dangling
319         GraphicsLayer which in turn confused UI-side compositing a little.
320         Fix by always parenting this layer.
321
322         * rendering/RenderLayerBacking.cpp:
323         (WebCore::RenderLayerBacking::createPrimaryGraphicsLayer):
324
325 2014-03-26  Brian Burg  <bburg@apple.com>
326
327         Web Replay: disable page cache during capture/replay
328         https://bugs.webkit.org/show_bug.cgi?id=130672
329
330         Reviewed by Timothy Hatcher.
331
332         Save, set, and restore page cache settings at the correct times.
333
334         No new tests. If this code fails, then the tests for network replay will fail.
335
336         * replay/ReplayController.cpp:
337         (WebCore::ReplayController::setForceDeterministicSettings): Added.
338         (WebCore::ReplayController::startCapturing):
339         (WebCore::ReplayController::stopCapturing):
340         (WebCore::ReplayController::cancelPlayback):
341         (WebCore::ReplayController::replayToPosition):
342         * replay/ReplayController.h:
343
344 2014-03-26  Sam Weinig  <sam@webkit.org>
345
346         Convert more of HTMLConverter to C++
347         https://bugs.webkit.org/show_bug.cgi?id=130811
348
349         Reviewed by Anders Carlsson.
350
351         * editing/cocoa/HTMLConverter.mm:
352         (HTMLConverter::HTMLConverter):
353         (HTMLConverter::~HTMLConverter):
354         (HTMLConverter::_blockLevelElementForNode):
355         (HTMLConverter::_colorForElement):
356         (HTMLConverter::_computedAttributesForElement):
357         (HTMLConverter::_attributesForElement):
358         (HTMLConverter::_fillInBlock):
359         (HTMLConverter::_enterElement):
360         (HTMLConverter::_addTableForElement):
361         (HTMLConverter::_addTableCellForElement):
362         (HTMLConverter::_processElement):
363         (HTMLConverter::_exitElement):
364         (HTMLConverter::_getFloat): Deleted.
365         (HTMLConverter::_elementIsBlockLevel): Deleted.
366         (HTMLConverter::_elementHasOwnBackgroundColor): Deleted.
367         (HTMLConverter::_colorForNode): Deleted.
368
369 2014-03-26  Simon Fraser  <simon.fraser@apple.com>
370
371         Hook up -webkit-overflow-scrolling:touch for iOS WK2
372         https://bugs.webkit.org/show_bug.cgi?id=130809
373
374         Reviewed by Tim Horton.
375
376         Get -webkit-overflow-scrolling: touch working for iOS WK2.
377         
378         * WebCore.exp.in:
379         * page/scrolling/AsyncScrollingCoordinator.cpp:
380         (WebCore::AsyncScrollingCoordinator::updateScrollingNode):
381         Send in ScrollingGeometry when we update scrolling nodes.
382         * page/scrolling/AsyncScrollingCoordinator.h:
383         * page/scrolling/ScrollingCoordinator.h:
384         (WebCore::ScrollingCoordinator::updateScrollingNode):
385         * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.h:
386         Need to get to the scrolling layer in a subclass.
387         (WebCore::ScrollingTreeScrollingNodeIOS::scrollLayer):
388         * rendering/RenderLayer.cpp:
389         (WebCore::RenderLayer::hasAcceleratedTouchScrolling): Remove code
390         that temporarily disabled touch-scrolling.
391         * rendering/RenderLayerCompositor.cpp:
392         (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer): When we
393         update scrolling nodes, send in the right scrolling geometry.
394
395 2014-03-26  Timothy Hatcher  <timothy@apple.com>
396
397         Modernize the loops in InspectorPageAgent.cpp.
398
399         Also moves the check for hiddenFromInspector to a lower level.
400         This hides hidden resources from more places.
401
402         https://bugs.webkit.org/show_bug.cgi?id=130803
403
404         Reviewed by Joseph Pecoraro.
405
406         * inspector/InspectorPageAgent.cpp:
407         (WebCore::buildArrayForCookies):
408         (WebCore::cachedResourcesForFrame):
409         (WebCore::allResourcesURLsForFrame):
410         (WebCore::InspectorPageAgent::getCookies):
411         (WebCore::InspectorPageAgent::searchInResources):
412         (WebCore::InspectorPageAgent::didClearWindowObjectInWorld):
413         (WebCore::InspectorPageAgent::loaderDetachedFromFrame):
414         (WebCore::InspectorPageAgent::buildObjectForFrameTree):
415
416 2014-03-26  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
417
418         Add platform implementation for RTCOfferAnswerOptions and RTCOfferOptions
419         https://bugs.webkit.org/show_bug.cgi?id=130689
420
421         Reviewed by Eric Carlson.
422
423         RTCOfferAnswerOptions and RTCOfferOptions objects were being passed to platform class, causing a layer
424         violation.
425
426         * Modules/mediastream/RTCOfferAnswerOptions.cpp:
427         (WebCore::RTCOfferAnswerOptions::initialize):
428         (WebCore::RTCOfferOptions::initialize):
429         * Modules/mediastream/RTCOfferAnswerOptions.h:
430         (WebCore::RTCOfferAnswerOptions::requestIdentity):
431         (WebCore::RTCOfferAnswerOptions::privateOfferAnswerOptions):
432         (WebCore::RTCOfferAnswerOptions::RTCOfferAnswerOptions):
433         (WebCore::RTCOfferOptions::offerToReceiveVideo):
434         (WebCore::RTCOfferOptions::offerToReceiveAudio):
435         (WebCore::RTCOfferOptions::voiceActivityDetection):
436         (WebCore::RTCOfferOptions::iceRestart):
437         (WebCore::RTCOfferOptions::privateOfferOptions):
438         (WebCore::RTCOfferOptions::RTCOfferOptions):
439         * Modules/mediastream/RTCPeerConnection.cpp:
440         (WebCore::RTCPeerConnection::createOffer):
441         (WebCore::RTCPeerConnection::createAnswer):
442         * platform/mediastream/RTCOfferAnswerOptionsPrivate.h: Added.
443         * platform/mediastream/RTCPeerConnectionHandler.h:
444         * platform/mock/RTCPeerConnectionHandlerMock.cpp:
445         (WebCore::RTCPeerConnectionHandlerMock::createOffer):
446         (WebCore::RTCPeerConnectionHandlerMock::createAnswer):
447         * platform/mock/RTCPeerConnectionHandlerMock.h:
448
449 2014-03-26  Zalan Bujtas  <zalan@apple.com>
450
451         Device scale factor should always be greater than 0.
452         https://bugs.webkit.org/show_bug.cgi?id=130798
453
454         Reviewed by David Kilzer.
455
456         Rendering context requires a device scale factor > 0 so that we can map CSS pixels
457         to device pixels properly. Neither 0 nor a negative device pixel ratio are considered to be valid.
458
459         * page/Page.cpp:
460         (WebCore::Page::setDeviceScaleFactor):
461
462 2014-03-26  Myles C. Maxfield  <mmaxfield@apple.com>
463
464         Skipping underlines disregard points completely inside the underline rect
465         https://bugs.webkit.org/show_bug.cgi?id=130800
466
467         Reviewed by Dean Jackson.
468
469         When determining bounds for underline skipping, endpoints of glyph contours
470         that lie entirely within the rect of the underline are ignored. This patch
471         makes these points affect the skipping regions the same way that intersections
472         do.
473
474         Test: fast/css3-text/css3-text-decoration/text-decoration-skip/glyph-inside-underline.html
475
476         * platform/graphics/mac/FontMac.mm:
477         (WebCore::updateX): Refactored common code into a function
478         (WebCore::findPathIntersections): Test for endpoints which lie entirely within
479         the underline bounds
480
481 2014-03-26  Pratik Solanki  <psolanki@apple.com>
482
483         Unreviewed. iOS build fix after r166312. Soft link CMTimeRangeGetEnd.
484
485         * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
486
487 2014-03-26  Timothy Hatcher  <timothy@apple.com>
488
489         Propagate the hiddenFromInspector flag on ResourceRequest in
490         places when a new request a made or passed between processes.
491
492         https://bugs.webkit.org/show_bug.cgi?id=130741
493
494         Reviewed by Joseph Pecoraro.
495
496         * WebCore.exp.in: Updated symbols for updateFromDelegatePreservingOldProperties.
497         * platform/network/cf/ResourceRequest.h:
498         * platform/network/cf/ResourceRequestCFNet.cpp:
499         (WebCore::ResourceRequest::updateFromDelegatePreservingOldProperties): Added.
500         (WebCore::ResourceRequest::updateFromDelegatePreservingOldHTTPBody): Deleted.
501         * platform/network/curl/ResourceRequest.h:
502         (WebCore::ResourceRequest::updateFromDelegatePreservingOldProperties): Added.
503         (WebCore::ResourceRequest::updateFromDelegatePreservingOldHTTPBody): Deleted.
504         * platform/network/mac/ResourceRequestMac.mm:
505         (WebCore::ResourceRequest::updateFromDelegatePreservingOldProperties): Added.
506         (WebCore::ResourceRequest::updateFromDelegatePreservingOldHTTPBody): Deleted.
507         * platform/network/soup/ResourceRequest.h:
508         (WebCore::ResourceRequest::updateFromDelegatePreservingOldProperties): Added.
509         (WebCore::ResourceRequest::updateFromDelegatePreservingOldHTTPBody): Deleted.
510
511 2014-03-26  Zoltan Horvath  <zoltan@webkit.org>
512
513         [CSS Shapes] Remove no-longer-used shape-inside geometry code
514         https://bugs.webkit.org/show_bug.cgi?id=130740
515
516         Reviewed by David Hyatt.
517
518         This patch removes shape-padding support, since it can be used only with shape-inside.
519         Shape-inside support has been removed in r166301.
520
521         No new tests needed, existing tests have been removed by r166301.
522
523         * rendering/shapes/BoxShape.cpp:
524         (WebCore::BoxShape::shapePaddingLogicalBoundingBox): Deleted.
525         (WebCore::BoxShape::shapePaddingBounds): Deleted.
526         (WebCore::BoxShape::getIncludedIntervals): Deleted.
527         (WebCore::BoxShape::firstIncludedIntervalLogicalTop): Deleted.
528         * rendering/shapes/BoxShape.h:
529         * rendering/shapes/PolygonShape.cpp:
530         (WebCore::leftSide): Deleted.
531         (WebCore::isReflexVertex): Deleted.
532         (WebCore::computeShapePaddingBounds): Deleted.
533         (WebCore::PolygonShape::shapePaddingBounds): Deleted.
534         (WebCore::PolygonShape::getIncludedIntervals): Deleted.
535         (WebCore::firstFitRectInPolygon): Deleted.
536         (WebCore::aboveOrToTheLeft): Deleted.
537         (WebCore::PolygonShape::firstIncludedIntervalLogicalTop): Deleted.
538         * rendering/shapes/PolygonShape.h:
539         (WebCore::PolygonShape::PolygonShape):
540         * rendering/shapes/RasterShape.cpp:
541         (WebCore::RasterShapeIntervals::firstIncludedIntervalY): Deleted.
542         (WebCore::RasterShapeIntervals::getIncludedIntervals): Deleted.
543         (WebCore::RasterShape::paddingIntervals): Deleted.
544         (WebCore::RasterShape::getIncludedIntervals): Deleted.
545         (WebCore::RasterShape::firstIncludedIntervalLogicalTop): Deleted.
546         * rendering/shapes/RasterShape.h:
547         * rendering/shapes/RectangleShape.cpp:
548         (WebCore::ellipseYIntercept): Deleted.
549         (WebCore::RectangleShape::shapePaddingBounds): Deleted.
550         (WebCore::RectangleShape::getIncludedIntervals): Deleted.
551         (WebCore::cornerInterceptForWidth): Deleted.
552         (WebCore::RectangleShape::firstIncludedIntervalLogicalTop): Deleted.
553         * rendering/shapes/RectangleShape.h:
554         * rendering/shapes/Shape.cpp:
555         (WebCore::Shape::createShape):
556         (WebCore::Shape::createRasterShape):
557         (WebCore::Shape::createBoxShape):
558         * rendering/shapes/Shape.h:
559         (WebCore::Shape::lineOverlapsShapePaddingBounds): Deleted.
560         (WebCore::Shape::shapePadding): Deleted.
561         * rendering/shapes/ShapeInfo.cpp:
562         (WebCore::ShapeInfo<RenderType>::computedShape):
563         * rendering/style/RenderStyle.cpp:
564         (WebCore::RenderStyle::changeRequiresLayout):
565         * rendering/style/RenderStyle.h:
566         * rendering/style/StyleRareNonInheritedData.cpp:
567         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
568         (WebCore::StyleRareNonInheritedData::operator==):
569         * rendering/style/StyleRareNonInheritedData.h:
570
571 2014-03-26  Jeremy Jones  <jeremyj@apple.com>
572
573         Implement hasLiveStreamingContent property in WebAVPlayerController
574         https://bugs.webkit.org/show_bug.cgi?id=128684
575
576         Reviewed by Simon Fraser.
577
578         * WebCore.exp.in:
579         Add export for WebVideoFullscreenInterfaceAVKit::setSeekableRanges().
580
581         * platform/ios/WebVideoFullscreenInterface.h:
582         Add setSeekableRanges()
583
584         * platform/ios/WebVideoFullscreenInterfaceAVKit.h:
585         Add setSeekableRanges()
586
587         * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
588         Remove vestigial playerLayer property. Add seekableTimeRanges property.
589
590         (-[WebAVPlayerController dealloc]):
591         Release _seekableTimeRanges.
592         Remove references to _playerLayer.
593
594         (-[WebAVPlayerController hasLiveStreamingContent]):
595         Implement based on duration. Live stream has an infinite duration.
596
597         (+[WebAVPlayerController keyPathsForValuesAffectingHasLiveStreamingContent]):
598         Describe dependent keys for computed property hasLiveStreamingContent.
599
600         (-[WebAVPlayerController skipBackwardThirtySeconds:]):
601         Seek back 30 seconds if that time is in the seekable ranges.
602
603         (-[WebAVPlayerController gotoEndOfSeekableRanges:]):
604         Jump to live by going to the of the seekable ranges.
605
606         (WebVideoFullscreenInterfaceAVKit::setSeekableRanges):
607         Convert TimeRange to CMTimeRange.
608
609         * platform/ios/WebVideoFullscreenModelMediaElement.mm:
610         (WebVideoFullscreenModelMediaElement::setMediaElement):
611         Set initial seekable ranges.
612
613         (WebVideoFullscreenModelMediaElement::handleEvent):
614         Update seekable ranges when time changes.
615
616 2014-03-26  Brent Fulgham  <bfulgham@apple.com>
617
618         Fix OS X build.
619
620         * WebCore.exp.in: Add missing export symbol.
621
622 2014-03-26  Simon Fraser  <simon.fraser@apple.com>
623
624         Fix the Windows build. Add a no-op impl for Mac non-UI-side.
625
626         * platform/graphics/ca/mac/PlatformCALayerMac.h:
627         * platform/graphics/ca/win/PlatformCALayerWin.cpp:
628         (PlatformCALayerWin::PlatformCALayerWin):
629         * platform/graphics/ca/win/PlatformCALayerWin.h:
630
631 2014-03-26  Simon Fraser  <simon.fraser@apple.com>
632
633         REGRESSION (r155977): matrix animations no longer animate
634         https://bugs.webkit.org/show_bug.cgi?id=130789
635         <rdar://problem/15650946>
636
637         Reviewed by Dean Jackson.
638         
639         r155977 erroneously removed two lines that set the end points for
640         matrix animations (used when transform lists don't match), so
641         put them back.
642         
643         Also don't repaint when updateContentsScale()
644         is called and doesn't change the contents scale.
645
646         Test: compositing/animation/matrix-animation.html
647
648         * platform/graphics/ca/GraphicsLayerCA.cpp:
649         (WebCore::GraphicsLayerCA::updateRootRelativeScale):
650         (WebCore::GraphicsLayerCA::setTransformAnimationEndpoints):
651         (WebCore::GraphicsLayerCA::updateContentsScale):
652
653 2014-03-26  Simon Fraser  <simon.fraser@apple.com>
654
655         Add a custom behavior flag to GraphicsLayer, piped down to PlatformCALayer, for scrolling layers
656         https://bugs.webkit.org/show_bug.cgi?id=130778
657
658         Reviewed by Tim Horton.
659
660         Make it possible to put a "custom behavior" flag on a layer so that,
661         with UI-side compositing, we know to create a specific type of
662         layer or view for that GraphicsLayer.
663
664         * WebCore.exp.in:
665         * platform/graphics/GraphicsLayer.cpp:
666         (WebCore::GraphicsLayer::GraphicsLayer):
667         * platform/graphics/GraphicsLayer.h:
668         (WebCore::GraphicsLayer::setCustomBehavior):
669         (WebCore::GraphicsLayer::customBehavior):
670         * platform/graphics/ca/GraphicsLayerCA.cpp:
671         (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
672         (WebCore::GraphicsLayerCA::updateCustomBehavior):
673         (WebCore::GraphicsLayerCA::setCustomBehavior):
674         * platform/graphics/ca/GraphicsLayerCA.h:
675         * platform/graphics/ca/PlatformCALayer.h:
676         * platform/graphics/ca/mac/PlatformCALayerMac.h:
677         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
678         (PlatformCALayerMac::PlatformCALayerMac):
679         * rendering/RenderLayerBacking.cpp:
680         (WebCore::RenderLayerBacking::updateScrollingLayers):
681
682 2014-03-26  Brent Fulgham  <bfulgham@apple.com>
683
684         Unreviewed test correction.
685
686         Because of the way DRT on Windows links to WebCore, having the implementaion of the update
687         method in the header caused a runtime failure due to duplicate symbols being bound to the
688         compilation unit.
689
690         * accessibility/AXObjectCache.cpp:
691         (WebCore::AXObjectCache::setEnhancedUserInterfaceAccessibility): Moved from header.
692         * accessibility/AXObjectCache.h:
693         (WebCore::AXObjectCache::setEnhancedUserInterfaceAccessibility): Deleted.
694
695 2014-03-26  Jer Noble  <jer.noble@apple.com>
696
697         REGRESSION(r162679): Poster image visible under the video
698         https://bugs.webkit.org/show_bug.cgi?id=130783
699
700         Reviewed by Simon Fraser.
701
702         In the listed revision, we started checking for isRenderImage()
703         instead of isImage(). RenderMedias return 'true' for the first
704         but 'false' for the second. Change the if() statement to check
705         for isRenderMedia() in addition to !isRenderImage().
706
707         * rendering/RenderLayerBacking.cpp:
708         (WebCore::RenderLayerBacking::isDirectlyCompositedImage):
709
710 2014-03-26  Antti Koivisto  <antti@apple.com>
711
712         Render tree construction is O(N^2) in number of siblings
713         https://bugs.webkit.org/show_bug.cgi?id=129065
714
715         Reviewed by Darin Adler.
716         
717         When adding a new renderer to the tree we would search for the correct render tree
718         position by traversing DOM children forward to find something that already has a renderer.
719         In common case there is no such renderer. This would be repeated for each inserted renderer
720         leading to O(n^2) in respect to child node count.
721         
722         This patch caches the computed render tree insertion position and passes it to siblings.
723         Until the cached position is reached it can be used for all new renderers.
724
725         Test: perf/sibling-renderer-On2.html
726
727         * style/StyleResolveTree.cpp:
728         (WebCore::Style::RenderTreePosition::parent):
729         (WebCore::Style::RenderTreePosition::RenderTreePosition):
730         (WebCore::Style::RenderTreePosition::canInsert):
731         (WebCore::Style::RenderTreePosition::insert):
732         (WebCore::Style::RenderTreePosition::computeNextSibling):
733         (WebCore::Style::RenderTreePosition::invalidateNextSibling):
734         (WebCore::Style::styleForElement):
735         (WebCore::Style::elementInsideRegionNeedsRenderer):
736         (WebCore::Style::createRendererIfNeeded):
737         (WebCore::Style::createTextRendererIfNeeded):
738         (WebCore::Style::attachTextRenderer):
739         (WebCore::Style::updateTextRendererAfterContentChange):
740         (WebCore::Style::attachChildren):
741         (WebCore::Style::attachDistributedChildren):
742         (WebCore::Style::attachShadowRoot):
743         (WebCore::Style::attachBeforeOrAfterPseudoElementIfNeeded):
744         (WebCore::Style::attachRenderTree):
745         (WebCore::Style::resolveLocal):
746         (WebCore::Style::resolveTextNode):
747         (WebCore::Style::resolveShadowTree):
748         (WebCore::Style::updateBeforeOrAfterPseudoElement):
749         (WebCore::Style::resolveTree):
750
751 2014-03-26  Commit Queue  <commit-queue@webkit.org>
752
753         Unreviewed, rolling out r166264.
754         https://bugs.webkit.org/show_bug.cgi?id=130785
755
756         Broke some window.opener tests for WK2 Mavericks (Requested by
757         brrian__ on #webkit).
758
759         Reverted changeset:
760
761         "Web Replay: resource unique identifiers should be unique-per-
762         frame, not globally"
763         https://bugs.webkit.org/show_bug.cgi?id=130632
764         http://trac.webkit.org/changeset/166264
765
766 2014-03-26  Zoltan Horvath  <zoltan@webkit.org>
767
768         [CSS Shapes] Remove shape-inside support
769         https://bugs.webkit.org/show_bug.cgi?id=130698
770
771         Reviewed by David Hyatt.
772
773         CSS Shapes Level 1 (CR) only contains shape-outside. We are focusing our efforts on finalizing
774         the implementation of shape-outside, it's worth to remove shape-inside code at this point for now.
775
776         A list of reasons for the removal:
777           - Shape-inside is only part of Shapes Level 2, which needs to be improved on some topics.
778           - Shape-inside is lack of new shapes support (e.g. inset).
779           - Deprecated shapes (r165472) are removed from the code (e.g. rectangle), which affects shape-inside. 
780           - The current shape-inside code spreads across the layout code.
781           - The current shape-inside implementation is experimental in some areas,
782             and the partially implemented code can have security implications.
783           - Removal of shape-inside opens possibilities for code complexity and performance
784             optimizations for shape-outside. (e.g. simpler geometry code)
785
786         No new tests are needed.
787
788         * CMakeLists.txt:
789         * Configurations/FeatureDefines.xcconfig:
790         * GNUmakefile.list.am:
791         * WebCore.xcodeproj/project.pbxproj:
792         * css/CSSComputedStyleDeclaration.cpp:
793         (WebCore::ComputedStyleExtractor::propertyValue):
794         * css/CSSParser.cpp:
795         (WebCore::isSimpleLengthPropertyID):
796         (WebCore::CSSParser::parseValue):
797         (WebCore::CSSParser::parseShapeProperty):
798         * css/CSSPropertyNames.in:
799         * css/DeprecatedStyleBuilder.cpp:
800         (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
801         * css/StyleResolver.cpp:
802         (WebCore::StyleResolver::applyProperty):
803         (WebCore::StyleResolver::loadPendingImages):
804         * page/animation/CSSPropertyAnimation.cpp:
805         (WebCore::CSSPropertyAnimationWrapperMap::CSSPropertyAnimationWrapperMap):
806         * rendering/LayoutState.cpp:
807         (WebCore::LayoutState::LayoutState):
808         * rendering/LayoutState.h:
809         (WebCore::LayoutState::LayoutState):
810         (WebCore::LayoutState::shapeInsideInfo): Deleted.
811         * rendering/RenderBlock.cpp:
812         (WebCore::RenderBlock::styleDidChange):
813         (WebCore::RenderBlock::imageChanged):
814         (WebCore::RenderBlock::preparePaginationBeforeBlockLayout):
815         (WebCore::RenderBlock::relayoutShapeDescendantIfMoved): Deleted.
816         (WebCore::RenderBlock::logicalOffsetFromShapeAncestorContainer): Deleted.
817         (WebCore::RenderBlock::updateShapeInsideInfoAfterStyleChange): Deleted.
818         (WebCore::RenderBlock::ensureShapeInsideInfo): Deleted.
819         (WebCore::RenderBlock::shapeInsideInfo): Deleted.
820         (WebCore::RenderBlock::setShapeInsideInfo): Deleted.
821         (WebCore::RenderBlock::markShapeInsideDescendantsForLayout): Deleted.
822         (WebCore::RenderBlock::layoutShapeInsideInfo): Deleted.
823         (WebCore::shapeInfoRequiresRelayout): Deleted.
824         (WebCore::RenderBlock::computeShapeSize): Deleted.
825         (WebCore::RenderBlock::updateShapesBeforeBlockLayout): Deleted.
826         (WebCore::RenderBlock::updateShapesAfterBlockLayout): Deleted.
827         (WebCore::RenderBlock::prepareShapesAndPaginationBeforeBlockLayout): Deleted.
828         * rendering/RenderBlock.h:
829         (WebCore::RenderBlock::allowsShapeInsideInfoSharing): Deleted.
830         * rendering/RenderBlockFlow.cpp:
831         (WebCore::RenderBlockFlow::layoutBlock):
832         (WebCore::RenderBlockFlow::layoutBlockChild):
833         (WebCore::RenderBlockFlow::computeLogicalLocationForFloat):
834         * rendering/RenderBlockFlow.h:
835         * rendering/RenderBlockLineLayout.cpp:
836         (WebCore::RenderBlockFlow::computeInlineDirectionPositionsForLine):
837         (WebCore::RenderBlockFlow::layoutRunsAndFloatsInRange):
838         (WebCore::constructBidiRunsForLine): Deleted.
839         (WebCore::pushShapeContentOverflowBelowTheContentBox): Deleted.
840         (WebCore::RenderBlockFlow::updateShapeAndSegmentsForCurrentLine): Deleted.
841         (WebCore::RenderBlockFlow::updateShapeAndSegmentsForCurrentLineInFlowThread): Deleted.
842         (WebCore::adjustLogicalLineTop): Deleted.
843         (WebCore::RenderBlockFlow::adjustLogicalLineTopAndLogicalHeightIfNeeded): Deleted.
844         * rendering/RenderDeprecatedFlexibleBox.cpp:
845         (WebCore::RenderDeprecatedFlexibleBox::layoutBlock):
846         * rendering/RenderElement.cpp:
847         (WebCore::RenderElement::~RenderElement):
848         (WebCore::RenderElement::initializeStyle):
849         (WebCore::RenderElement::setStyle):
850         * rendering/RenderFlexibleBox.cpp:
851         (WebCore::RenderFlexibleBox::layoutBlock):
852         * rendering/RenderGrid.cpp:
853         (WebCore::RenderGrid::layoutBlock):
854         * rendering/RenderNamedFlowFragment.cpp:
855         (WebCore::RenderNamedFlowFragment::createStyle):
856         * rendering/RenderView.h:
857         * rendering/SimpleLineLayout.cpp:
858         (WebCore::SimpleLineLayout::canUseFor):
859         * rendering/line/BreakingContextInlineHeaders.h:
860         (WebCore::BreakingContext::handleText):
861         (WebCore::BreakingContext::handleEndOfLine):
862         (WebCore::updateSegmentsForShapes): Deleted.
863         * rendering/line/LineBreaker.cpp:
864         (WebCore::LineBreaker::nextLineBreak):
865         * rendering/line/LineWidth.cpp:
866         (WebCore::LineWidth::LineWidth):
867         (WebCore::LineWidth::updateAvailableWidth):
868         (WebCore::LineWidth::wrapNextToShapeOutside):
869         (WebCore::LineWidth::fitBelowFloats):
870         (WebCore::LineWidth::updateLineSegment): Deleted.
871         (WebCore::LineWidth::updateCurrentShapeSegment): Deleted.
872         * rendering/line/LineWidth.h:
873         * rendering/shapes/ShapeInsideInfo.cpp: Removed.
874         * rendering/shapes/ShapeInsideInfo.h: Removed.
875         * rendering/style/RenderStyle.cpp:
876         (WebCore::RenderStyle::changeRequiresLayout):
877         * rendering/style/RenderStyle.h:
878         * rendering/style/StyleRareNonInheritedData.cpp:
879         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
880         (WebCore::StyleRareNonInheritedData::operator==):
881         * rendering/style/StyleRareNonInheritedData.h:
882
883 2014-03-25  Brent Fulgham  <bfulgham@apple.com>
884
885         Avoid duplicate size checks when creating empty image
886         https://bugs.webkit.org/show_bug.cgi?id=130730
887
888         Reviewed by Dean Jackson.
889
890         Merged from Blink (patch by ch.dumez@samsung.com):
891         https://chromium.googlesource.com/chromium/blink/+/4861a71bc1f284fc97417f405ab7d08dc6947b88
892         http://crbug.com/190633011
893
894         * html/canvas/CanvasRenderingContext2D.cpp:
895         (WebCore::createEmptyImageData): Don't perform overflow calculation twice.
896
897 2014-03-26  Sergio Villar Senin  <svillar@igalia.com>
898
899         [CSS Grid Layout] getComputedStyle() must return the specified value for positioning properties
900         https://bugs.webkit.org/show_bug.cgi?id=130010
901
902         Reviewed by Darin Adler.
903
904         According to the specs
905         http://dev.w3.org/csswg/css-grid/#property-index and also to
906         http://lists.w3.org/Archives/Public/www-style/2014Mar/0162.html
907         the function getComputedStyle() must return the specified values
908         for positioning properties, i.e, grid-{columns|rows}-{start|end}.
909
910         We were in some cases, adjusting the style in the StyleResolver
911         (for example with two opposing spans) something that is now done
912         in the RenderGrid because we cannot alter the original style.
913
914         The code moved to the renderer became more self explanatory and it
915         now supports named grid areas with names ending in "-start" and
916         "-end".
917
918         Test: fast/css-grid-layout/named-grid-lines-with-named-grid-areas-get-set.html
919
920         * css/StyleResolver.cpp:
921         (WebCore::StyleResolver::adjustRenderStyle):
922         (WebCore::gridLineDefinedBeforeGridArea): Deleted.
923         (WebCore::StyleResolver::adjustNamedGridItemPosition): Deleted.
924         (WebCore::StyleResolver::adjustGridItemPosition): Deleted.
925         * css/StyleResolver.h:
926         * rendering/RenderGrid.cpp:
927         (WebCore::isColumnSide):
928         (WebCore::RenderGrid::explicitGridSizeForSide):
929         (WebCore::gridLineDefinedBeforeGridArea):
930         (WebCore::setNamedLinePositionIfDefinedBeforeArea):
931         (WebCore::RenderGrid::adjustNamedGridItemPosition):
932         (WebCore::RenderGrid::adjustGridPositionsFromStyle):
933         (WebCore::RenderGrid::resolveGridPositionsFromStyle):
934         (WebCore::RenderGrid::resolveNamedGridLinePositionFromStyle):
935         (WebCore::RenderGrid::resolveNamedGridLinePositionAgainstOppositePosition):
936         * rendering/RenderGrid.h:
937         * rendering/style/GridPosition.h:
938         (WebCore::GridPosition::setAutoPosition): New helper function.
939
940 2014-03-26  Simon Fraser  <simon.fraser@apple.com>
941
942         Fix the iOS build.
943
944         * WebCore.exp.in:
945
946 2014-03-26  Tim Horton  <timothy_horton@apple.com>
947
948         [iOS WebKit2] Flush all surfaces after painting into all of them, instead of after painting into each one
949         https://bugs.webkit.org/show_bug.cgi?id=130768
950         <rdar://problem/16421471>
951
952         Reviewed by Simon Fraser.
953
954         * platform/graphics/cocoa/IOSurface.h:
955         Add a non-ensuring platformContext() getter.
956
957 2014-03-26  James Craig  <jcraig@apple.com>
958
959         Web Inspector: AXI: crash when inspecting "bar" text node in getAccessibilityPropertiesForNode layout test
960         https://bugs.webkit.org/show_bug.cgi?id=130290
961
962         Reviewed by Timothy Hatcher.
963
964         Test: inspector-protocol/dom/getAccessibilityPropertiesForNode.html
965
966         Fixing regression from r165590. http://webkit.org/b/129779
967         Verify isElementNode to avoid calling toElement on document or text nodes.
968
969         * inspector/InspectorDOMAgent.cpp:
970         (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
971
972 2014-03-25  Sergio Villar Senin  <svillar@igalia.com>
973
974         Replace DEPRECATED_DEFINE_STATIC_LOCAL by static NeverDestroyed<T> in editing/
975         https://bugs.webkit.org/show_bug.cgi?id=130722
976
977         Reviewed by Antti Koivisto.
978
979         * editing/AlternativeTextController.cpp:
980         (WebCore::markerTypesForAutocorrection):
981         (WebCore::markerTypesForReplacement):
982         (WebCore::markerTypesForAppliedDictationAlternative):
983         * editing/EditingStyle.cpp:
984         (WebCore::htmlElementEquivalents):
985         (WebCore::htmlAttributeEquivalents):
986         * editing/FormatBlockCommand.cpp:
987         (WebCore::isElementForFormatBlock):
988         * editing/RemoveFormatCommand.cpp:
989         (WebCore::isElementForRemoveFormatCommand):
990         * editing/ReplaceSelectionCommand.cpp:
991         (WebCore::isProhibitedParagraphChild):
992         * editing/atk/FrameSelectionAtk.cpp:
993         (WebCore::maybeEmitTextFocusChange):
994
995 2014-03-25  Simon Fraser  <simon.fraser@apple.com>
996
997         Add a new type of scrolling tree node for overflow scrolling
998         https://bugs.webkit.org/show_bug.cgi?id=130763
999
1000         Reviewed by Tim Horton.
1001
1002         Prepare for overflow scrolling via the scrolling tree by adding
1003         a new scrolling node type for overflow:scroll nodes. Mostly
1004         this is a new ScrollingNodeType that gets mapped to the same
1005         scrolling state nodes and scrolling nodes, but iOS creates
1006         state and scrolling nodes specific to overflow:scroll.
1007         
1008         Change the type checking on nodes to use virtual functions instead
1009         of just checking the node type, to allow the macros to work with
1010         the new scrolling node type.
1011
1012         * WebCore.exp.in:
1013         * page/scrolling/AsyncScrollingCoordinator.cpp:
1014         (WebCore::AsyncScrollingCoordinator::ensureRootStateNodeForFrameView):
1015         * page/scrolling/ScrollingCoordinator.h:
1016         * page/scrolling/ScrollingStateFixedNode.h:
1017         * page/scrolling/ScrollingStateNode.h:
1018         (WebCore::ScrollingStateNode::isFixedNode):
1019         (WebCore::ScrollingStateNode::isStickyNode):
1020         (WebCore::ScrollingStateNode::isScrollingNode):
1021         * page/scrolling/ScrollingStateScrollingNode.cpp:
1022         (WebCore::ScrollingStateScrollingNode::create):
1023         (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
1024         * page/scrolling/ScrollingStateScrollingNode.h:
1025         * page/scrolling/ScrollingStateStickyNode.h:
1026         * page/scrolling/ScrollingStateTree.cpp:
1027         (WebCore::ScrollingStateTree::attachNode):
1028         * page/scrolling/ScrollingTree.cpp:
1029         (WebCore::ScrollingTree::viewportChangedViaDelegatedScrolling):
1030         (WebCore::ScrollingTree::updateTreeFromStateNode):
1031         * page/scrolling/ScrollingTreeNode.h:
1032         (WebCore::ScrollingTreeNode::isFixedNode):
1033         (WebCore::ScrollingTreeNode::isStickyNode):
1034         (WebCore::ScrollingTreeNode::isScrollingNode):
1035         * page/scrolling/ScrollingTreeScrollingNode.cpp:
1036         (WebCore::ScrollingTreeScrollingNode::ScrollingTreeScrollingNode):
1037         * page/scrolling/ScrollingTreeScrollingNode.h:
1038         * page/scrolling/ios/ScrollingCoordinatorIOS.mm:
1039         (WebCore::ScrollingCoordinatorIOS::createScrollingTreeNode):
1040         * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.h:
1041         * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.mm:
1042         (WebCore::ScrollingTreeScrollingNodeIOS::create):
1043         (WebCore::ScrollingTreeScrollingNodeIOS::ScrollingTreeScrollingNodeIOS):
1044         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
1045         (WebCore::ScrollingCoordinatorMac::createScrollingTreeNode):
1046         * page/scrolling/mac/ScrollingTreeFixedNode.h:
1047         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.h:
1048         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
1049         (WebCore::ScrollingTreeScrollingNodeMac::create):
1050         (WebCore::ScrollingTreeScrollingNodeMac::ScrollingTreeScrollingNodeMac):
1051         * page/scrolling/mac/ScrollingTreeStickyNode.h:
1052         * rendering/RenderLayerCompositor.cpp:
1053         (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
1054
1055 2014-03-26  Krzysztof Czech  <k.czech@samsung.com>
1056
1057         [ATK] Utilize new AtkValue interface coming in ATK 2.11.92
1058         https://bugs.webkit.org/show_bug.cgi?id=130575
1059
1060         Reviewed by Mario Sanchez Prada.
1061
1062         ATK 2.11.92 introduces some new API and deprecates an old one.
1063         Adjust current implementation to meet requirements of the new API.
1064
1065         No new tests. Covered by existing ones.
1066
1067         * accessibility/atk/AXObjectCacheAtk.cpp:
1068         (WebCore::AXObjectCache::postPlatformNotification):
1069         * accessibility/atk/WebKitAccessibleInterfaceValue.cpp:
1070         (webkitAccessibleSetNewValue):
1071         (webkitAccessibleGetIncrementValue):
1072         (webkitAccessibleGetValueAndText):
1073         (webkitAccessibleGetIncrement):
1074         (webkitAccessibleSetValue):
1075         (webkitAccessibleGetRange):
1076         (webkitAccessibleValueSetCurrentValue):
1077         (webkitAccessibleValueGetMinimumIncrement):
1078         (webkitAccessibleValueInterfaceInit):
1079
1080 2014-03-26  Zan Dobersek  <zdobersek@igalia.com>
1081
1082         Unreviewed. Removing the remaining Automake cruft.
1083
1084         * GNUmakefile.list.am: Removed.
1085
1086 2014-03-25  Pratik Solanki  <psolanki@apple.com>
1087
1088         iOS build fix. Add missing semicolon.
1089
1090         * editing/cocoa/HTMLConverter.mm:
1091         (HTMLConverter::_addAttachmentForElement):
1092
1093 2014-03-25  Sam Weinig  <sam@webkit.org>
1094
1095         Speculative iOS build fix.
1096
1097         * editing/cocoa/HTMLConverter.mm:
1098         (HTMLConverter::_addAttachmentForElement):
1099
1100 2014-03-25  Jer Noble  <jer.noble@apple.com>
1101
1102         [MSE] Duplicate 'seeked' events.
1103         https://bugs.webkit.org/show_bug.cgi?id=130754
1104
1105         Reviewed by Eric Carlson.
1106
1107         Test: media/media-source/media-source-duplicate-seeked.html
1108
1109         During certain seek operations, HTMLMediaElement::finishSeek() can be called re-entrantly due to
1110         the ready state changing as a result of MediaSource::monitorSourceBuffers(). Move this call to the
1111         end of finishSeek() after m_seeking has been cleared.
1112
1113         * html/HTMLMediaElement.cpp:
1114         (WebCore::HTMLMediaElement::parseAttribute):
1115
1116 2014-03-25  James Craig  <jcraig@apple.com>
1117
1118         Web Inspector: AXI: add support for aria-activedescendant and reconcile UI/testing with parentNode
1119         https://bugs.webkit.org/show_bug.cgi?id=130712
1120
1121         Reviewed by Timothy Hatcher.
1122
1123         Test: inspector-protocol/dom/getAccessibilityPropertiesForNode.html
1124
1125         Support for @aria-activedescendant; code reuse changes w/ parentNode and activeDescendantNode.
1126
1127         * inspector/InspectorDOMAgent.cpp:
1128         (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
1129         * inspector/protocol/DOM.json:
1130
1131 2014-03-25  Sanghyup Lee  <sh53.lee@samsung.com>
1132
1133         When the mouse is upped after dragged out of shadowDOM, it should lose :active.
1134         https://bugs.webkit.org/show_bug.cgi?id=130660
1135
1136         Reviewed by Darin Adler.
1137
1138         This caused a regression after r165037.
1139         When we have to clear :active style of shadow DOM, we should clear host's style.
1140         This patch replaces parentElement() by parentOrShadowHostElement().
1141
1142         * dom/Document.cpp:
1143         (WebCore::Document::updateHoverActiveState):
1144
1145 2014-03-25  Eric Carlson  <eric.carlson@apple.com>
1146
1147         [Mac] Always retry a failed MediaDocument as a PluginDocument
1148         https://bugs.webkit.org/show_bug.cgi?id=130742
1149
1150         Reviewed by Jer Noble.
1151
1152         * html/HTMLMediaElement.cpp:
1153         (WebCore::HTMLMediaElement::mediaLoadingFailedFatally): If the element is in a media document,
1154             tell it that loading failed so it can retry as a plug-in.
1155
1156 2014-03-25  Ryosuke Niwa  <rniwa@webkit.org>
1157
1158         Replace HTMLConverter::_stringForNode by propertyValueForNode
1159         https://bugs.webkit.org/show_bug.cgi?id=130711
1160
1161         Reviewed by Sam Weinig.
1162
1163         Replaced all calls to HTMLConverter::_stringForNode by that to propertyValueForNode.
1164
1165         * editing/cocoa/HTMLConverter.mm:
1166         (HTMLConverter::_computedAttributesForElement):
1167         (HTMLConverter::_addAttachmentForElement):
1168         (HTMLConverter::_enterElement):
1169         (HTMLConverter::_addTableForElement):
1170         (HTMLConverter::_addTableCellForElement):
1171         (HTMLConverter::_processElement):
1172         (HTMLConverter::_exitElement):
1173         (HTMLConverter::_processText):
1174         (HTMLConverter::_traverseNode):
1175         (HTMLConverter::_traverseFooterNode):
1176         (HTMLConverter::_stringForNode): Deleted.
1177
1178 2014-03-25  Pratik Solanki  <psolanki@apple.com>
1179
1180         Attempt to fix iOS build after r166261.
1181
1182         * WebCore.xcodeproj/project.pbxproj: Make SystemSleepListener.h a private header.
1183
1184 2014-03-21  Jer Noble  <jer.noble@apple.com>
1185
1186         [iOS] Enable caption support in full screen.
1187         https://bugs.webkit.org/show_bug.cgi?id=130603
1188
1189         Reviewed by Eric Carlson.
1190
1191         Add TextTrackRepresentation support to MediaPlayerPrivateAVFoundationObjC.
1192
1193         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
1194         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
1195         (WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoLayer): Add the m_textTrackRepresenationLayer if present.
1196         (WebCore::MediaPlayerPrivateAVFoundationObjC::setVideoFullscreenLayer): Ditto.
1197         (WebCore::MediaPlayerPrivateAVFoundationObjC::requiresTextTrackRepresentation): True, if a m_videoFullscreenLayer is present.
1198         (WebCore::MediaPlayerPrivateAVFoundationObjC::setTextTrackRepresentation): Remove the old, and add the new m_textTrackRepresenationLayer.
1199
1200         Make the text track container a stacking context for painting purposes.
1201         * Modules/mediacontrols/mediaControlsiOS.css:
1202         (video::-webkit-media-text-track-container):
1203
1204 2014-03-25  Brian Burg  <bburg@apple.com>
1205
1206         Web Replay: resource unique identifiers should be unique-per-frame, not globally
1207         https://bugs.webkit.org/show_bug.cgi?id=130632
1208
1209         Reviewed by Timothy Hatcher.
1210
1211         For replay purposes, we want to deterministically assign resource load identifiers
1212         to resource loaders, provided that the resource loaders are created in the same
1213         order.
1214
1215         To do this, we convert unique identifiers from being globally-unique to being
1216         frame-unique. When a new frame is being loaded, unique identifiers for
1217         subresources of that frame begin counting from 1.
1218
1219         No new tests. Identifier invariants are exercised by existing assertions and tests.
1220
1221         * loader/ProgressTracker.cpp:
1222         (WebCore::ProgressTracker::ProgressTracker):
1223         (WebCore::ProgressTracker::reset):
1224         (WebCore::ProgressTracker::createUniqueIdentifier):
1225         * loader/ProgressTracker.h:
1226
1227 2014-03-25  Jer Noble  <jer.noble@apple.com>
1228
1229         [Mac] Pause the media element during system sleep.
1230         https://bugs.webkit.org/show_bug.cgi?id=130718
1231
1232         Reviewed by Eric Carlson.
1233
1234         Test: media/video-system-sleep.html
1235
1236         Relying on the platform media system to pause and restart playback during
1237         system sleep can cause problems on some platforms, especially where hardware
1238         decoders are concerned. Rather than implicitly pausing the media during
1239         system sleep, explicitly pause the media before sleeping and resume (if
1240         appropriate) upon waking.
1241
1242         Add a new class to be used for system sleep notifications:
1243         * platform/SystemSleepListener.cpp: Added.
1244         (WebCore::SystemSleepListener::create):
1245         (WebCore::SystemSleepListener::SystemSleepListener):
1246         * platform/SystemSleepListener.h: Added.
1247         (WebCore::SystemSleepListener::Client::~Client):
1248         (WebCore::SystemSleepListener::~SystemSleepListener):
1249         (WebCore::SystemSleepListener::client):
1250
1251         Add a Mac-specific implementation:
1252         * platform/mac/SystemSleepListenerMac.h: Added.
1253         * platform/mac/SystemSleepListenerMac.mm: Added.
1254         (WebCore::SystemSleepListener::create):
1255         (WebCore::SystemSleepListenerMac::SystemSleepListenerMac):
1256         (WebCore::SystemSleepListenerMac::~SystemSleepListenerMac):
1257
1258         Listen for system sleep notifications in MediaSessionManager:
1259         * platform/audio/MediaSessionManager.cpp:
1260         (WebCore::MediaSessionManager::MediaSessionManager):
1261         (WebCore::MediaSessionManager::systemWillSleep):
1262         (WebCore::MediaSessionManager::systemDidWake):
1263         * platform/audio/MediaSessionManager.h:
1264
1265         Drive-by fix; notify the MediaSession that playback will begin
1266         due to autoplay, but do not begin autoplaying if the session
1267         is already interrupted:
1268         * html/HTMLMediaElement.cpp:
1269         (WebCore::HTMLMediaElement::parseAttribute):
1270
1271         Add new files to project:
1272         * WebCore.vcxproj/WebCore.vcxproj:
1273         * WebCore.xcodeproj/project.pbxproj:
1274         * CMakeLists.txt:
1275         * GNUmakefile.list.am:
1276
1277 2014-03-25  Radu Stavila  <stavila@adobe.com>
1278
1279         [CSS Regions] The background of children of scrollable elements flowed into regions is not properly scrolled
1280         https://bugs.webkit.org/show_bug.cgi?id=130574
1281
1282         Reviewed by David Hyatt.
1283
1284         When computing the clip rect for painting the box decorations, the scrolled content offset
1285         must be computed by going up the containing block tree, up to the region.
1286
1287         Tests: fast/regions/scrollable-region-scrollable-absolute-content-background.html
1288                fast/regions/scrollable-region-scrollable-content-background.html
1289
1290         * rendering/RenderNamedFlowThread.cpp:
1291         (WebCore::RenderNamedFlowThread::decorationsClipRectForBoxInNamedFlowFragment):
1292
1293 2014-03-25  Joseph Pecoraro  <pecoraro@apple.com>
1294
1295         [iOS] Inspector View Indication Support
1296         https://bugs.webkit.org/show_bug.cgi?id=130709
1297
1298         Reviewed by Simon Fraser.
1299
1300         * inspector/InspectorClient.h:
1301         (WebCore::InspectorClient::showInspectorIndication):
1302         (WebCore::InspectorClient::hideInspectorIndication):
1303         * inspector/InspectorController.cpp:
1304         (WebCore::InspectorController::setIndicating):
1305         Rename indicate/hideIndication to show/hide names.
1306
1307 2014-03-25  Brent Fulgham  <bfulgham@apple.com>
1308
1309         Unreviewed build fix. Typo on checkin.
1310
1311         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
1312         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerItem): Left an unmatched open bracket.
1313
1314 2014-03-25  Jer Noble  <jer.noble@apple.com>
1315
1316         Even further unreviewed build fix after r166247. Unprotect the implementation of HTMLMediaElement::shouldDisableSleep().
1317
1318         * html/HTMLMediaElement.cpp:
1319         (WebCore::HTMLMediaElement::parseAttribute):
1320
1321 2014-03-25  Jer Noble  <jer.noble@apple.com>
1322
1323         Further unreviewed build fix after r166247. Add DisplaySleepDisabler to the windows project file and
1324         move the definition of DisplaySleepDisabler's constructor and destructor into the cpp file.
1325
1326         * WebCore.vcxproj/WebCore.vcxproj:
1327         * platform/DisplaySleepDisabler.cpp:
1328         (WebCore::DisplaySleepDisabler::DisplaySleepDisabler):
1329         (WebCore::DisplaySleepDisabler::~DisplaySleepDisabler):
1330         * platform/DisplaySleepDisabler.h:
1331
1332 2014-03-25  Jer Noble  <jer.noble@apple.com>
1333
1334         Unreviewed build fix after r166247. Un-platform-protect the declaration of HTMLMediaElement::shouldDisableSleep()
1335         and make WebVideoFullscreenController's _displaySleepDisabler a std::unique_ptr.
1336
1337         * html/HTMLMediaElement.h:
1338         * platform/mac/WebVideoFullscreenController.h:
1339
1340 2014-03-25  Brent Fulgham  <bfulgham@apple.com>
1341
1342         [iOS] Pass additional options to AVFoundation during playback.
1343         https://bugs.webkit.org/show_bug.cgi?id=130624
1344
1345         Reviewed by Eric Carlson.
1346
1347         * html/HTMLMediaElement.cpp:
1348         (WebCore::HTMLMediaElement::doesHaveAttribute): Return attribute value if the user
1349         passes a pointer to fill in.
1350         * html/HTMLMediaElement.h:
1351         * platform/graphics/MediaPlayer.cpp:
1352         (WebCore::MediaPlayer::doesHaveAttribute):
1353         * platform/graphics/MediaPlayer.h:
1354         (WebCore::MediaPlayerClient::doesHaveAttribute):
1355         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
1356         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerItem): Pass additional
1357         option if supplied by user.
1358
1359 2014-03-25  Michael Saboff  <msaboff@apple.com>
1360
1361         Unreviewed, rolling out r166070.
1362
1363         Rollout r166070 due to 2% performance loss in page load times
1364
1365         Reverted changeset:
1366
1367         "Change CodeGeneratorJS.pm special cases for "DOMWindow" to be
1368         general purpose"
1369         https://bugs.webkit.org/show_bug.cgi?id=130553
1370         http://trac.webkit.org/changeset/166070
1371
1372 2014-03-25  Michael Saboff  <msaboff@apple.com>
1373
1374         Unreviewed, rolling out r166126.
1375
1376         Rollout r166126 in prepartion to roll out prerequisite r166070
1377
1378         Reverted changeset:
1379
1380         "toThis() on a JSWorkerGlobalScope should return a JSProxy and
1381         not undefined"
1382         https://bugs.webkit.org/show_bug.cgi?id=130554
1383         http://trac.webkit.org/changeset/166126
1384
1385 2014-03-25  Jer Noble  <jer.noble@apple.com>
1386
1387         [iOS] Playing video does not disable display sleep.
1388         https://bugs.webkit.org/show_bug.cgi?id=130729
1389
1390         Reviewed by Eric Carlson.
1391
1392         DisplaySleepDisabler was broken by r161589, which replaced the iOS implementation with
1393         an empty one. Make a platform independent version with a Cocoa-platform subclass. Update
1394         the APIs to non-deprecated ones.
1395
1396         * platform/DisplaySleepDisabler.cpp: Added.
1397         (WebCore::DisplaySleepDisabler::create):
1398         * platform/DisplaySleepDisabler.h: Added.
1399         (WebCore::DisplaySleepDisabler::~DisplaySleepDisabler):
1400         (WebCore::DisplaySleepDisabler::DisplaySleepDisabler):
1401         * platform/cocoa/DisplaySleepDisablerCocoa.cpp: Renamed from Source/WebCore/platform/mac/DisplaySleepDisabler.cpp.
1402         (WebCore::DisplaySleepDisabler::create):
1403         (WebCore::DisplaySleepDisablerCocoa::DisplaySleepDisablerCocoa):
1404         (WebCore::DisplaySleepDisablerCocoa::~DisplaySleepDisablerCocoa):
1405         * platform/cocoa/DisplaySleepDisablerCocoa.h: Renamed from Source/WebCore/platform/mac/DisplaySleepDisabler.h.
1406
1407         Update m_sleepDisabler to be a std::unique_ptr, and unprotect the definition of methods which use it.
1408         * html/HTMLMediaElement.cpp:
1409         (WebCore::HTMLMediaElement::updateSleepDisabling):
1410         (WebCore::HTMLMediaElement::shouldDisableSleep):
1411         * html/HTMLMediaElement.h:
1412
1413         Add the new and renamed files to the project:
1414         * CMakeLists.txt:
1415         * GNUmakefile.list.am:
1416         * WebCore.xcodeproj/project.pbxproj:
1417
1418 2014-03-25  Dirk Schulze  <krit@webkit.org>
1419
1420         Implement ImageData constructors and WebWorkers exposure
1421         https://bugs.webkit.org/show_bug.cgi?id=130668
1422
1423         Reviewed by Dean Jackson.
1424
1425         Add new constructors for ImageData.
1426
1427         http://www.whatwg.org/specs/web-apps/current-work/multipage/the-canvas-element.html#pixel-manipulation
1428
1429         Test: fast/canvas/canvas-imageData.html
1430
1431         * html/ImageData.cpp: 
1432         (WebCore::ImageData::create):
1433         * html/ImageData.h:
1434         * html/ImageData.idl:
1435
1436 2014-03-25  Myles C. Maxfield  <mmaxfield@apple.com>
1437
1438         InlineIterator position (unsigned int) variable can wrap around
1439         https://bugs.webkit.org/show_bug.cgi?id=130540
1440
1441         Reviewed by Simon Fraser.
1442
1443         We trigger an ASSERT that occurs when we are ignoring spaces (to collapse them
1444         into a single whitespace mark) but then encounter a line break. Because we don't ignore
1445         the first space (but do ignore subsequent spaces), when we hit a newline in an RTL context
1446         we want to ignore that first space as well (so as not to push the text away from the right
1447         edge). We do this by decrementing the InlineIterator pointing to this first space, so all
1448         the spaces get ignored. However, if that space is the first character in a Text node, the
1449         decrement will try to go past the beginning of the node, and trigger an ASSERT.
1450
1451         This design is not great. At some point we should rework it to more elegantly handle
1452         collapsing whitespace in both RTL and LTR writing modes.
1453
1454         This patch adds an ASSERT earlier in this codepath to catch potential problems earlier.
1455         It also pulls our sentinel value out into a separate boolean to make it more clear what is
1456         going on.
1457
1458         Test: fast/text/whitespace-only-text-in-rtl.html
1459
1460         * rendering/InlineIterator.h:
1461         (WebCore::InlineIterator::moveTo): Use the set***() calls
1462         (WebCore::InlineIterator::setOffset): ASSERT early that our math hasn't wrapped
1463         * rendering/RenderBlockLineLayout.cpp:
1464         (WebCore::RenderBlockFlow::appendRunsForObject): Use new boolean value
1465         * rendering/line/BreakingContextInlineHeaders.h:
1466         (WebCore::BreakingContext::handleText): Guard against wraps
1467         (WebCore::checkMidpoints): Use new boolean value
1468         * rendering/line/TrailingObjects.cpp:
1469         (WebCore::TrailingObjects::updateMidpointsForTrailingBoxes): Use new boolean value
1470
1471 2014-03-25  Martin Robinson  <mrobinson@igalia.com>
1472
1473         [GTK] Remove the autotools build
1474         https://bugs.webkit.org/show_bug.cgi?id=130717
1475
1476         Reviewed by Anders Carlsson.
1477
1478         * GNUmakefile.am: Removed.
1479         * bindings/gobject/GNUmakefile.am: Removed.
1480         * config.h: Removed references to autotools configure file.
1481
1482 2014-03-24  Brent Fulgham  <bfulgham@apple.com>
1483
1484         Prevent 'removetrack' events from firing when all inband text tracks are removed.
1485         https://bugs.webkit.org/show_bug.cgi?id=130704
1486
1487         Reviewed by Eric Carlson.
1488
1489         Test: media/track/track-remove-track.html
1490
1491         Based on the Blink change (patch by acolwell@chromium.org):
1492         https://codereview.chromium.org/177243018/
1493
1494         * html/HTMLMediaElement.cpp:
1495         (WebCore::HTMLMediaElement::prepareForLoad): Reorder steps to match W3C specification.
1496         (WebCore::HTMLMediaElement::noneSupported): Forget tracks as required by specification.
1497         (WebCore::HTMLMediaElement::mediaLoadingFailed): Forget tracks as required by specification.
1498         (WebCore::HTMLMediaElement::removeTextTrack): Only request the 'removetracks' event if
1499         requested by caller.
1500         (WebCore::HTMLMediaElement::removeAllInbandTracks): Renamed to 'forgetResourceSpecificTracks'
1501         (WebCore::HTMLMediaElement::noneSupported): Specify that we want the 'removetracks' event
1502         fired for this use case.
1503         (WebCore::HTMLMediaElement::prepareForLoad): Switch to new 'forgetResourceSpecificTracks' name.
1504         * html/HTMLMediaElement.h:
1505         * html/track/TextTrackList.cpp:
1506         (TextTrackList::remove): Only fire the 'removetrack' event if the caller requests it.
1507         * html/track/TextTrackList.h: Add default argument to fire the 'removetrack' event
1508         when removing a track.
1509         * html/track/TrackListBase.cpp:
1510         (TrackListBase::remove): Only fire the 'removetrack' event if the caller requests it.
1511         * html/track/TrackListBase.h: Add default argument to fire the 'removetrack' event.
1512
1513 2014-03-25  David Kilzer  <ddkilzer@apple.com>
1514
1515         Hold a reference to firstSuccessfulSubmitButton in HTMLFormElement::submit
1516         <http://webkit.org/b/130713>
1517         <rdar://problem/15661876>
1518
1519         Reviewed by Darin Adler.
1520
1521         Merged from Blink (patch by Ian Beer):
1522         http://crbug.com/303657
1523         https://src.chromium.org/viewvc/blink?view=rev&revision=158938
1524
1525         Test: fast/forms/form-submission-crash-successful-submit-button.html
1526
1527         * html/HTMLFormElement.cpp:
1528         (WebCore::HTMLFormElement::submit):
1529
1530 2014-03-25  Gabor Rapcsanyi  <rgabor@webkit.org>
1531
1532         [ARM64] GNU assembler fails in TransformationMatrix::multiply
1533         https://bugs.webkit.org/show_bug.cgi?id=130454
1534
1535         Reviewed by Zoltan Herczeg.
1536
1537         Change the NEON intstructions to the proper style.
1538
1539         * platform/graphics/transforms/TransformationMatrix.cpp:
1540         (WebCore::TransformationMatrix::multiply):
1541
1542 2014-03-20  Sergio Villar Senin  <svillar@igalia.com>
1543
1544         [CSS Grid Layout] Vertical rectangles not considered as valid grid areas
1545         https://bugs.webkit.org/show_bug.cgi?id=130513
1546
1547         Reviewed by Andreas Kling.
1548
1549         Grid areas sized as vertical rectangles were incorrectly
1550         considered as invalid by the parser. That's because the condition
1551         checking that each new row was adjacent to the previous one was
1552         using the first row of the currently parsed grid area instead of
1553         the last one.
1554
1555         Test: fast/css-grid-layout/grid-template-areas-get-set.html
1556
1557         * css/CSSParser.cpp:
1558         (WebCore::CSSParser::parseGridTemplateAreas):
1559
1560 2014-03-25  Xabier Rodriguez Calvar  <calvaris@igalia.com>
1561
1562         [GTK] Volume slider shows below the panel with videos in certain cases
1563         https://bugs.webkit.org/show_bug.cgi?id=130608
1564
1565         Reviewed by Jer Noble.
1566
1567         We need to delay the moment we check if the volume slider shows up
1568         or down. If the video was not visible, the offsets were 0 and it
1569         was forced to be shown below the panel.
1570
1571         Test: media/video-initially-hidden-volume-slider-up.html
1572
1573         * Modules/mediacontrols/mediaControlsApple.js:
1574         (Controller.prototype.createControls): Moved volumebox pseudo from
1575         the subclass. The test checks for it and it would fail in Mac.
1576         * Modules/mediacontrols/mediaControlsGtk.js:
1577         (ControllerGtk.prototype.createControls): Moved volumebox pseudo
1578         to the superclass.
1579         (ControllerGtk.prototype.handleMuteButtonMouseOver): Check if
1580         volume slider should show up or down.
1581         (ControllerGtk.prototype.updateReadyState): Removed check for
1582         volume slider direction.
1583
1584 2014-03-24  Brent Fulgham  <bfulgham@apple.com>
1585
1586         [Win] Enable WebVTT Regions on Windows.
1587         https://bugs.webkit.org/show_bug.cgi?id=130680
1588
1589         Reviewed by Eric Carlson.
1590
1591         * DerivedSources.cpp: Add new build components.
1592         * WebCore.vcxproj/WebCore.vcxproj: Ditto.
1593         * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
1594
1595 2014-03-24  Simon Fraser  <simon.fraser@apple.com>
1596
1597         Remove some unnecessary includes from PlatformCALayerClient.h
1598         https://bugs.webkit.org/show_bug.cgi?id=130703
1599
1600         Reviewed by Andreas Kling.
1601         
1602         No need for all these #includes.
1603
1604         * platform/graphics/ca/PlatformCALayerClient.h:
1605
1606 2014-03-24  Adenilson Cavalcanti  <cavalcantii@gmail.com>
1607
1608         [core] FEGaussianBlur: use IntSize to simplify member function interface
1609         https://bugs.webkit.org/show_bug.cgi?id=130695
1610
1611         Reviewed by Dean Jackson.
1612
1613         By returning an IntSize to store the calculated kernel size values
1614         it is possible to have less function parameters. This patch also
1615         streamlines a bit the code in calculateUnscaledKernelSize.
1616
1617         No new tests, no change in behavior.
1618
1619         * platform/graphics/filters/FEDropShadow.cpp:
1620         (WebCore::FEDropShadow::determineAbsolutePaintRect):
1621         * platform/graphics/filters/FEGaussianBlur.cpp:
1622         (WebCore::FEGaussianBlur::calculateUnscaledKernelSize):
1623         (WebCore::FEGaussianBlur::calculateKernelSize):
1624         (WebCore::FEGaussianBlur::determineAbsolutePaintRect):
1625         (WebCore::FEGaussianBlur::platformApplySoftware):
1626         * platform/graphics/filters/FEGaussianBlur.h:
1627         (if): Deleted.
1628         * platform/graphics/filters/FilterOperations.cpp:
1629         (WebCore::outsetSizeForBlur):
1630
1631 2014-03-24  Brian Burg  <bburg@apple.com>
1632
1633         Web Replay: capture and replay keyboard events
1634         https://bugs.webkit.org/show_bug.cgi?id=130314
1635
1636         Reviewed by Joseph Pecoraro.
1637
1638         Upstream support for capturing and replaying non-IME keyboard input.
1639         This works similarly to mouse events. It introduces optional fields and
1640         macros to encode/decode them.
1641
1642         Test: ManualTests/inspector/replay-keyboard-events.html
1643
1644         * replay/ReplayInputDispatchMethods.cpp:
1645         (WebCore::HandleKeyPress::dispatch):
1646         * replay/SerializationMethods.cpp:
1647         (JSC::EncodingTraits<NondeterministicInputBase>::encodeValue):
1648         (JSC::EncodingTraits<NondeterministicInputBase>::decodeValue): Switch existing
1649         encode/decode calls to use the shortening macros.
1650         (JSC::EncodingTraits<KeypressCommand>::encodeValue): Added.
1651         (JSC::EncodingTraits<KeypressCommand>::decodeValue): Added.
1652         (JSC::PlatformKeyboardEventAppKit::PlatformKeyboardEventAppKit): Subclass
1653         PlatformKeyboardEvent so that we can set AppKit-specific members not
1654         initialized through the main constructors.
1655         (JSC::EncodingTraits<PlatformKeyboardEvent>::encodeValue): Added.
1656         (JSC::EncodingTraits<PlatformKeyboardEvent>::decodeValue): Added.
1657         * replay/SerializationMethods.h:
1658         * replay/UserInputBridge.cpp:
1659         (WebCore::UserInputBridge::UserInputBridge): initialize m_state inside a guard.
1660         (WebCore::UserInputBridge::handleKeyEvent): fill in the implementation.
1661         * replay/WebInputs.json:
1662
1663 2014-03-24  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
1664
1665         Optimizing string construction for type error in JSNavigatorCustom.cpp
1666         https://bugs.webkit.org/show_bug.cgi?id=130683
1667
1668         Reviewed by Eric Carlson.
1669
1670         * bindings/js/JSNavigatorCustom.cpp:
1671         (WebCore::JSNavigator::webkitGetUserMedia):
1672
1673 2014-03-24  Beth Dakin  <bdakin@apple.com>
1674
1675         Legacy-style scrollbars constantly redraw after scrolling
1676         https://bugs.webkit.org/show_bug.cgi?id=130699
1677
1678         Reviewed by Simon Fraser.
1679
1680         The constant re-draw was happening because we were never calling [ScrollbarPainter 
1681         setUsePresentationValue:NO]. This is a silly bug where were should have been 
1682         looking at PlatformWheelEvent::momentumPhase() instead of 
1683         PlatformWheelEvent::phase()
1684
1685         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
1686         (WebCore::ScrollingTreeScrollingNodeMac::handleWheelEvent):
1687
1688 2014-03-24  Daniel Bates  <dabates@apple.com>
1689
1690         XSS Auditor doesn't block <script> injected before an existing <script>
1691         https://bugs.webkit.org/show_bug.cgi?id=130475
1692
1693         Merged from Blink (patch by Tom Sepez):
1694         https://src.chromium.org/viewvc/blink?view=rev&revision=169697
1695
1696         Tests: http/tests/security/xssAuditor/script-tag-expression-follows.html
1697                http/tests/security/xssAuditor/script-tag-near-start.html
1698
1699         * html/parser/XSSAuditor.cpp:
1700         (WebCore::startsHTMLCommentAt):
1701         (WebCore::startsSingleLineCommentAt):
1702         (WebCore::startsMultiLineCommentAt):
1703         (WebCore::startsOpeningScriptTagAt):
1704         (WebCore::XSSAuditor::decodedSnippetForJavaScript):
1705
1706 2014-03-24  Brent Fulgham  <bfulgham@apple.com>
1707
1708         Activate WebVTT Tests Once Merging is Complete
1709         https://bugs.webkit.org/show_bug.cgi?id=130420
1710
1711         Reviewed by Eric Carlson.
1712
1713         * Configurations/FeatureDefines.xcconfig: Turn on ENABLE(WEBVTT_REGIONS)
1714
1715 2014-03-24  Anders Carlsson  <andersca@apple.com>
1716
1717         Re-fix the build.
1718
1719         * WebCore.exp.in:
1720
1721 2014-03-24  Anders Carlsson  <andersca@apple.com>
1722
1723         Fix build.
1724
1725         * WebCore.exp.in:
1726         Move a CFNetwork only symbol inside the USE(CFNETWORK) section.
1727
1728 2014-03-24  Chris Fleizach  <cfleizach@apple.com>
1729
1730         Regression: AX: Don't expose role or notifications for invalid menus
1731         https://bugs.webkit.org/show_bug.cgi?id=129814
1732
1733         Reviewed by Mario Sanchez Prada.
1734
1735         If a role=menu has no menuitem children, it should not be a menu.
1736         This was a bit tricky to implement since we need to update the role after the children are created,
1737         but it means we have to be a bit more aggressive about when to updateChildren, so that the role
1738         is known to be valid.
1739
1740         Test: platform/mac/accessibility/invalid-menu-role-does-not-send-notification.html
1741
1742         * accessibility/AXObjectCache.cpp:
1743         (WebCore::AXObjectCache::notificationPostTimerFired):
1744         * accessibility/AccessibilityRenderObject.cpp:
1745         (WebCore::AccessibilityRenderObject::updateRoleAfterChildrenCreation):
1746         (WebCore::AccessibilityRenderObject::addChildren):
1747         * accessibility/AccessibilityRenderObject.h:
1748         * accessibility/mac/WebAccessibilityObjectWrapperBase.mm:
1749         (-[WebAccessibilityObjectWrapperBase updateObjectBackingStore]):
1750
1751 2014-03-24  Andy Estes  <aestes@apple.com>
1752
1753         [iOS] Download support by CFURLDownloadRef under USE(CFNETWORK).
1754         https://bugs.webkit.org/show_bug.cgi?id=129322
1755
1756         Reviewed by Anders Carlsson.
1757
1758         * platform/network/ResourceHandle.h:
1759         * platform/network/cf/ResourceHandleCFNet.cpp:
1760         (WebCore::ResourceHandle::releaseConnectionForDownload): Changed to
1761         return a RetainPtr that adopts the connection's retain count.
1762
1763 2014-03-24  Enrica Casucci  <enrica@apple.com>
1764
1765         Update Hindi fallback font.
1766         https://bugs.webkit.org/show_bug.cgi?id=130690
1767         <rdar://problem/16391601>
1768
1769         Reviewed by Sam Weinig.
1770
1771         Using the new available font for Hindi in the fallback list.
1772
1773         * platform/graphics/ios/FontCacheIOS.mm:
1774         (WebCore::FontCache::systemFallbackForCharacters):
1775
1776 2014-03-24  Brent Fulgham  <bfulgham@apple.com>
1777
1778         Merge Minor WebVTT Cleanups from Blink
1779         https://bugs.webkit.org/show_bug.cgi?id=130681
1780
1781         Reviewed by Eric Carlson.
1782
1783         Merged from Blink (patch by philipj@opera.com):
1784         https://chromium.googlesource.com/chromium/blink/+/693eb5e2933dca0eab5bbd604e9f3406fe9fd1ab
1785         http://crbug.com/52593009
1786         https://chromium.googlesource.com/chromium/blink/+/40b3602feab34e9be829fd742b6ad6ded322a09f
1787         http://crbug.com/104243003
1788
1789         * html/track/TextTrack.cpp:
1790         (WebCore::TextTrack::setMode):
1791         * html/track/TextTrack.idl:
1792         * html/track/TextTrackCue.h:
1793         * html/track/VTTCue.cpp:
1794         (WebCore::VTTCue::VTTCue):
1795         * html/track/VTTCue.h:
1796
1797 2014-03-24  Commit Queue  <commit-queue@webkit.org>
1798
1799         Unreviewed, rolling out r166169.
1800         https://bugs.webkit.org/show_bug.cgi?id=130682
1801
1802         This patch broke tests on Apple Mavericks (Requested by fredw
1803         on #webkit).
1804
1805         Reverted changeset:
1806
1807         "Operator stretching: expose a math data API"
1808         https://bugs.webkit.org/show_bug.cgi?id=130572
1809         http://trac.webkit.org/changeset/166169
1810
1811 2014-03-24  Martin Hodovan  <mhodovan@inf.u-szeged.hu>
1812
1813         ENABLE(CSS_GRID_LAYOUT) guard for CSSGridLineNamesValue
1814         https://bugs.webkit.org/show_bug.cgi?id=130669
1815
1816         Reviewed by Sergio Villar Senin.
1817
1818         No new tests. No new functionality.
1819
1820         * css/CSSGridLineNamesValue.cpp:
1821         * css/CSSGridLineNamesValue.h:
1822
1823 2014-03-24  Chris Fleizach  <cfleizach@apple.com>
1824
1825         <hr> should expose AXRole/AXSubrole, etc
1826         https://bugs.webkit.org/show_bug.cgi?id=109015
1827
1828         Reviewed by Mario Sanchez Prada.
1829
1830         Expose the <hr> element to Mac and iOS through the accessibility interface.
1831
1832         Test: platform/mac/accessibility/hr-element.html
1833
1834         * English.lproj/Localizable.strings:
1835         * accessibility/AccessibilityNodeObject.cpp:
1836         (WebCore::AccessibilityNodeObject::isEnabled):
1837         * accessibility/AccessibilityObject.cpp:
1838         (WebCore::AccessibilityObject::computedRoleString):
1839         * accessibility/AccessibilityRenderObject.cpp:
1840         (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
1841         * accessibility/atk/AccessibilityObjectAtk.cpp:
1842         (WebCore::AccessibilityObject::accessibilityPlatformIncludesObject):
1843         * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
1844         (-[WebAccessibilityObjectWrapper determineIsAccessibilityElement]):
1845         (-[WebAccessibilityObjectWrapper accessibilityLabel]):
1846         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
1847         (createAccessibilityRoleMap):
1848         (-[WebAccessibilityObjectWrapper subrole]):
1849         (-[WebAccessibilityObjectWrapper roleDescription]):
1850         * platform/LocalizedStrings.cpp:
1851         (WebCore::AXHorizontalRuleDescriptionText):
1852         * platform/LocalizedStrings.h:
1853
1854 2014-03-24  Antti Koivisto  <antti@apple.com>
1855
1856         Invalidate sibling text node style when needed instead of attaching synchronously
1857         https://bugs.webkit.org/show_bug.cgi?id=130590
1858
1859         Reviewed by Andreas Kling.
1860         
1861         Make things simpler.
1862
1863         * style/StyleResolveTree.cpp:
1864         (WebCore::Style::invalidateWhitespaceOnlyTextSiblingsAfterAttachIfNeeded):
1865         
1866             Just invalidate instead of calling attach directly.
1867             Rename to match.
1868
1869         (WebCore::Style::textRendererIsNeeded):
1870         (WebCore::Style::createTextRendererIfNeeded):
1871         
1872             Move all testing to textRendererIsNeeded.
1873
1874         (WebCore::Style::updateTextRendererAfterContentChange):
1875         
1876             Call resolveTextNode instead of re-implementing the same thing.
1877
1878         (WebCore::Style::resolveLocal):
1879         (WebCore::Style::resolveTextNode):
1880         
1881             Avoid unnecessary reattaching.
1882             Rename for consistency.
1883
1884         (WebCore::Style::resolveShadowTree):
1885         (WebCore::Style::resolveTree):
1886         
1887 2014-03-24  Zsolt Borbely  <zsborbely.u-szeged@partner.samsung.com>
1888
1889         Fix !ENABLE(VIDEO) build
1890         https://bugs.webkit.org/show_bug.cgi?id=130671
1891
1892         Reviewed by Eric Carlson.
1893
1894         Add missing ENABLE(VIDEO) guards because many functions use
1895         the newly guarded functions.
1896
1897         * testing/Internals.cpp:
1898         * testing/Internals.h:
1899         * testing/Internals.idl:
1900
1901 2014-03-24  Antti Koivisto  <antti@apple.com>
1902
1903         Text autosizing does not determine line count correctly for simple line layout
1904         https://bugs.webkit.org/show_bug.cgi?id=130673
1905
1906         Reviewed by Daniel Bates.
1907         
1908         We don't count lines correctly in simple line layout case.
1909
1910         * page/Frame.cpp:
1911         (WebCore::Frame::textAutosizingWidth):
1912         (WebCore::Frame::setTextAutosizingWidth):
1913         * page/ios/FrameIOS.mm:
1914         (WebCore::Frame::textAutosizingWidth): Deleted.
1915         (WebCore::Frame::setTextAutosizingWidth): Deleted.
1916         
1917             Move to Frame.cpp to make enabling on non-iOS build easier.
1918
1919         * rendering/RenderBlockFlow.cpp:
1920         (WebCore::RenderBlockFlow::lineCount):
1921         
1922             Handle simple line layout case.
1923
1924         (WebCore::RenderBlockFlow::lineCountForTextAutosizing):
1925             
1926             Call lineCount() if children are inline.
1927             Rename for clarity.
1928
1929         (WebCore::RenderBlockFlow::adjustComputedFontSizes):
1930         (WebCore::RenderBlockFlow::immediateLineCount): Deleted.
1931         * rendering/RenderBlockFlow.h:
1932
1933 2014-03-24  Frédéric Wang  <fred.wang@free.fr>
1934
1935         [regression] background colors do not apply to <mo> elements.
1936         https://bugs.webkit.org/show_bug.cgi?id=130470.
1937
1938         Test: mathml/presentation/tokenElements-background-color.html
1939
1940         * rendering/mathml/RenderMathMLOperator.cpp:
1941         (WebCore::RenderMathMLOperator::paint): always call the parent painting to draw the background.
1942         (WebCore::RenderMathMLOperator::paintChildren): move the special case for invisible operator here.
1943
1944 2014-03-24  Frédéric Wang  <fred.wang@free.fr>
1945
1946         Operator stretching: expose a math data API
1947         https://bugs.webkit.org/show_bug.cgi?id=130572
1948
1949         Reviewed by Chris Fleizach.
1950
1951         We expose a new SimpleFontData API to give access to the data from the
1952         OpenType MATH table using a font cache. The class OpenTypeMathData will
1953         be implemented in bug 130324. On Darwin platform, we also implement the
1954         missing FontPlatformData::openTypeTable function which will be necessary
1955         to load the OpenType MATH table. The changes are intended to be used
1956         for MathML operator stretching (bug 130322) so tests are not added yet.
1957
1958         * CMakeLists.txt: add new OpenTypeMathData files.
1959         * GNUmakefile.list.am: ditto.
1960         * WebCore.vcxproj/WebCore.vcxproj: ditto.
1961         * WebCore.vcxproj/WebCore.vcxproj.filters: ditto.
1962         * WebCore.xcodeproj/project.pbxproj: ditto.
1963         * platform/graphics/FontCache.cpp: We add a FontCache::getMathData function to implement a cache for the math data.
1964         We make the math and vertical data share the same key for the cache.
1965         (WebCore::fontMathDataCacheInstance):
1966         (WebCore::FontCache::getMathData):
1967         (WebCore::fontVerticalDataCacheInstance):
1968         * platform/graphics/FontCache.h: We declare FontCache::getMathData and FontFileKey on all platforms.
1969         * platform/graphics/FontPlatformData.cpp:
1970         (WebCore::FontPlatformData::openTypeTable): We implement openTypeTable() on Darwin platform.
1971         * platform/graphics/FontPlatformData.h: We expose openTypeTable() on Darwin platform.
1972         * platform/graphics/SimpleFontData.cpp: We initialize m_mathData from the font cache.
1973         (WebCore::SimpleFontData::SimpleFontData):
1974         * platform/graphics/SimpleFontData.h: We expose a mathData() function to access the MATH data.
1975         * platform/graphics/opentype/OpenTypeMathData.cpp: Added. This is a new class that will be used to parse the data from the OpenType MATH table.
1976         (WebCore::OpenTypeMathData::OpenTypeMathData):
1977         * platform/graphics/opentype/OpenTypeMathData.h: Added.
1978         (WebCore::OpenTypeMathData::create):
1979         (WebCore::OpenTypeMathData::hasMathData):
1980
1981 2014-03-24  Jon Lee  <jonlee@apple.com>
1982
1983         Build fixes.
1984
1985         Unreviewed.
1986
1987         * editing/ios/EditorIOS.mm:
1988         (WebCore::Editor::writeSelectionToPasteboard): Convert to reference.
1989
1990 2014-03-24  Martin Hodovan  <mhodovan@inf.u-szeged.hu>
1991
1992         ENABLE(VIDEO_TRACK) guard for CSSParserSelector::parsePseudoCueFunctionSelector
1993         https://bugs.webkit.org/show_bug.cgi?id=130666
1994
1995         Reviewed by Andreas Kling.
1996
1997         No new tests. No new functionality.
1998
1999         * css/CSSParserValues.cpp:
2000         (WebCore::CSSParserSelector::parsePseudoCueFunctionSelector): Deleted.
2001
2002 2014-03-24  Javier Fernandez  <jfernandez@igalia.com>
2003
2004         [CSS Grid Layout] Update named <grid-line> syntax to the last version of the specs
2005         https://bugs.webkit.org/show_bug.cgi?id=129041
2006
2007         Reviewed by Sergio Villar Senin.
2008
2009         From Blink r162555 by <svillar@igalia.com>
2010
2011         Names for grid lines are now specified as a list of whitespace separated
2012         idents enclosed in parentheses instead of as a list of strings.
2013
2014         Updated tests to match the new <grid-line> syntax.
2015
2016         * CMakeLists.txt:
2017         * GNUmakefile.list.am:
2018         * WebCore.xcodeproj/project.pbxproj: Added info of the new file for the CSSGridLineNamesValue class.
2019         * css/CSSComputedStyleDeclaration.cpp:
2020         (WebCore::addValuesForNamedGridLinesAtIndex): The named <grid-line> value is now a list.
2021         * css/CSSGrammar.y.in: New syntax for named <grid-line>.
2022         * css/CSSGridLineNamesValue.cpp: Added.
2023         (WebCore::CSSGridLineNamesValue::customCSSText): String representation of the named <grid-line> as a list of Strings.
2024         (WebCore::CSSGridLineNamesValue::CSSGridLineNamesValue): Constructor.
2025         (WebCore::CSSGridLineNamesValue::cloneForCSSOM): Ref counted cloning function.
2026         * css/CSSGridLineNamesValue.h: Added.
2027         (WebCore::CSSGridLineNamesValue::create): Ref counted constructor.
2028         * css/CSSParser.cpp:
2029         (WebCore::CSSParser::parseGridLineNames): It replaces the old parseGrdTrackNames.
2030         (WebCore::CSSParser::parseGridTrackList): Using the new named <grid-line> syntax.
2031         (WebCore::CSSParser::parseGridTrackRepeatFunction): Using the new named <grid-line> syntax.
2032         * css/CSSParser.h:
2033         * css/CSSParserValues.cpp:
2034         (WebCore::destroy): Handling the case of CSSValue being CSSValueList intances.
2035         (WebCore::CSSParserValue::createCSSValue): Handling the case of CSSValue being CSSValueList intances.
2036         * css/CSSParserValues.h:
2037         (WebCore::CSSParserValue::setFromValueList): Adds the named <grid-line> list to the CSSParserValueList instance.
2038         * css/CSSValue.cpp:
2039         (WebCore::CSSValue::equals): Handling the case of the new CSSGridLineNamesValue class.
2040         (WebCore::CSSValue::cssText): Handling the case of the new CSSGridLineNamesValue class.
2041         (WebCore::CSSValue::destroy): Handling the case of the new CSSGridLineNamesValue class.
2042         * css/CSSValue.h:
2043         (WebCore::CSSValue::isGridLineNamesValue): Type cast check for the new CSSGridLineNamesValue class.
2044         * css/StyleResolver.cpp:
2045         (WebCore::createGridTrackList): Using the new named <grid-line> syntax.
2046
2047 2014-03-23  Sam Weinig  <sam@webkit.org>
2048
2049         Convert WebHTMLConverter to C++
2050         https://bugs.webkit.org/show_bug.cgi?id=130655
2051
2052         Reviewed by Andreas Kling.
2053
2054         - Mechanically converts the Objective-C class WebHTMLConverter, to the C++ HTMLConverter (lots of cleanup to follow).
2055         - Removes unused members
2056             - _standardFontFamily (never assigned to)
2057             - _textSizeMultiplier (always exactly 1)
2058             - _webViewTextSizeMultiplier (always exactly 0)
2059             - _defaultFontSize (always exactly 12, changed to be constant)
2060             - _minimumFontSize (always exactly 1, changed to be constant)
2061             - _colorsForNodes (never assigned to)
2062             - _indexingLimit (always exactly 0)
2063             - _thumbnailLimit (always exactly 0)
2064             - _flags.isIndexing (always false)
2065             - _flags.isTesting (always false)
2066
2067         * editing/cocoa/HTMLConverter.mm:
2068         (HTMLConverter::convert):
2069         (HTMLConverter::HTMLConverter):
2070         (HTMLConverter::~HTMLConverter):
2071         (defaultParagraphStyle):
2072         (_childrenForNode):
2073         (HTMLConverter::_stringForNode):
2074         (HTMLConverter::_getFloat):
2075         (_webKitBundle):
2076         (HTMLConverter::_elementIsBlockLevel):
2077         (HTMLConverter::_elementHasOwnBackgroundColor):
2078         (HTMLConverter::_blockLevelElementForNode):
2079         (HTMLConverter::_colorForNode):
2080         (HTMLConverter::_computedAttributesForElement):
2081         (HTMLConverter::_attributesForElement):
2082         (HTMLConverter::_newParagraphForElement):
2083         (HTMLConverter::_newLineForElement):
2084         (HTMLConverter::_newTabForElement):
2085         (_WebMessageDocumentClass):
2086         (HTMLConverter::_addAttachmentForElement):
2087         (HTMLConverter::_addQuoteForElement):
2088         (HTMLConverter::_addValue):
2089         (HTMLConverter::_fillInBlock):
2090         (HTMLConverter::_processMetaElementWithName):
2091         (HTMLConverter::_processHeadElement):
2092         (HTMLConverter::_enterElement):
2093         (HTMLConverter::_addTableForElement):
2094         (HTMLConverter::_addTableCellForElement):
2095         (HTMLConverter::_processElement):
2096         (HTMLConverter::_addMarkersToList):
2097         (HTMLConverter::_exitElement):
2098         (HTMLConverter::_processText):
2099         (HTMLConverter::_traverseNode):
2100         (HTMLConverter::_traverseFooterNode):
2101         (HTMLConverter::_adjustTrailingNewline):
2102         (HTMLConverter::_loadFromDOMRange):
2103         (fileWrapperForURL):
2104         (fileWrapperForElement):
2105         (WebCore::attributedStringFromRange):
2106         (WebCore::editingAttributedStringFromRange):
2107
2108 2014-03-23  Jinwoo Song  <jinwoo7.song@samsung.com>
2109
2110         Remove Dead Stores from editing directory
2111         https://bugs.webkit.org/show_bug.cgi?id=130634
2112
2113         Reviewed by Darin Adler.
2114
2115         Remove Dead Stores from editing directory which assigning a value to a variable
2116         and never reading that value.
2117
2118         * editing/ApplyStyleCommand.cpp:
2119         (WebCore::ApplyStyleCommand::mergeStartWithPreviousIfIdentical):
2120         * editing/markup.cpp:
2121         (WebCore::createMarkupInternal):
2122
2123 2014-03-23  Hyowon Kim  <hw1008.kim@samsung.com>
2124
2125         Move all EFL typedefs into EflTypedefs.h.
2126         https://bugs.webkit.org/show_bug.cgi?id=130511
2127
2128         Reviewed by Gyuyoung Kim.
2129
2130         * platform/FileSystem.h: Remove EFL typedefs.
2131         * platform/Widget.h: Ditto.
2132         * platform/efl/EflScreenUtilities.h: Ditto.
2133         * platform/graphics/Icon.h: Ditto.
2134         * platform/graphics/Image.h: Ditto.
2135         * platform/graphics/IntPoint.h: Ditto.
2136         * platform/graphics/IntRect.h: Ditto.
2137         * platform/network/NetworkStateNotifier.h: Ditto.
2138
2139 2014-03-23  Sam Weinig  <sam@webkit.org>
2140
2141         Move HTMLConverter from platform/mac to editing/cocoa.
2142
2143         Rubber-stamped by Darin Adler.
2144
2145         * WebCore.xcodeproj/project.pbxproj:
2146         * editing/cocoa: Added.
2147         * editing/cocoa/HTMLConverter.h: Copied from platform/mac/HTMLConverter.h.
2148         * editing/cocoa/HTMLConverter.mm: Copied from platform/mac/HTMLConverter.mm.
2149         * platform/mac/HTMLConverter.h: Removed.
2150         * platform/mac/HTMLConverter.mm: Removed.
2151
2152 2014-03-23  Sam Weinig  <sam@webkit.org>
2153
2154         Simplify the HTMLConverter interface (Part 2)
2155         https://bugs.webkit.org/show_bug.cgi?id=130654
2156
2157         Reviewed by Darin Adler.
2158
2159         Switch HTMLConverter from using an Objective-C interface to C functions.
2160
2161         * WebCore.exp.in:
2162         * editing/ios/EditorIOS.mm:
2163         (WebCore::Editor::writeSelectionToPasteboard):
2164         * editing/mac/EditorMac.mm:
2165         (WebCore::Editor::dataSelectionForPasteboard):
2166         (WebCore::Editor::writeSelectionToPasteboard):
2167         * platform/ios/PasteboardIOS.mm:
2168         * platform/mac/HTMLConverter.h:
2169         * platform/mac/HTMLConverter.mm:
2170         (WebCore::attributedStringFromRange):
2171         (WebCore::editingAttributedStringFromRange):
2172         * platform/mac/PasteboardMac.mm:
2173
2174 2014-03-23  Darin Adler  <darin@apple.com>
2175
2176         Remove code in HTMLObjectElement attribute parsing that forces style resolution and layout
2177         https://bugs.webkit.org/show_bug.cgi?id=130653
2178
2179         Reviewed by Antti Koivisto.
2180
2181         * dom/ContainerNode.cpp: Moved the post-attach callback code from here to
2182         StyleResolveTree.h/cpp.
2183         * dom/ContainerNode.h: Ditto.
2184
2185         * dom/Document.cpp:
2186         (WebCore::Document::recalcStyle): Use Style::PostResolutionCallbackDisabler instead of
2187         PostAttachCallbackDisabler.
2188
2189         * dom/Element.h: Moved the post-attach callback code from here to StyleResolveTree.h/cpp.
2190
2191         * html/HTMLEmbedElement.cpp:
2192         (WebCore::HTMLEmbedElement::parseAttribute): Simplified the code for typeAttr, turning
2193         it into a 1-liner. Added a FIXME in codeAttr about the fact that it does not have the
2194         code to trigger image loads. Changed srcAttr to call updateImageLoaderWithNewURLSoon to
2195         do the image loading logic.
2196
2197         * html/HTMLFormControlElement.cpp:
2198         (WebCore::HTMLFormControlElement::didAttachRenderers): Updated to use
2199         Style::queuePostResolutionCallback and use a lambda instead of a function.
2200         (WebCore::HTMLFormControlElement::didRecalcStyle): Ditto. Also added RefPtr instead
2201         of just using wishful thinking to keep the object alive.
2202         * html/HTMLFrameOwnerElement.cpp:
2203         (WebCore::HTMLFrameOwnerElement::scheduleSetNeedsStyleRecalc): Ditto.
2204
2205         * html/HTMLObjectElement.cpp:
2206         (WebCore::HTMLObjectElement::parseAttribute):: Simplified the code for typeAttr, turning
2207         it into a 1-liner. Changed dataAttr to use updateImageLoaderWithNewURLSoon(). Also made
2208         it call setNeedsWidgetUpdate(true) unconditionally after checking carefully to see that's
2209         harmless if there is no renderer. Changed classidAttr to call setNeedsWidgetUpdate(true)
2210         unconditionally and not set m_classId.
2211         (WebCore::HTMLObjectElement::shouldAllowQuickTimeClassIdQuirk): Use fastGetAttribute
2212         instead of classId and descendantsOfType instead of getElementsByTagName.
2213         (WebCore::HTMLObjectElement::hasValidClassId): Use fastGetAttribute instead of classId.
2214         (WebCore::HTMLObjectElement::renderFallbackContent): Use imageLoader instead of m_imageLoader.
2215
2216         * html/HTMLObjectElement.h: Removed classId, since there is no reason to cache that
2217         attribute in a data member. Rearranged header, making more private, and fixing some typos,
2218         and doing a "using" instead of a function to disambiguate the inherited form functions.
2219
2220         * html/HTMLPlugInImageElement.cpp:
2221         (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement): Initialize m_needsImageReload.
2222         (WebCore::HTMLPlugInImageElement::createElementRenderer): Fixed some code that assumed the
2223         first child of the shadow root is guaranteed to be an element.
2224         (WebCore::HTMLPlugInImageElement::didRecalcStyle): Added. Calls the new
2225         scheduleUpdateForAfterStyleResolution function.
2226         (WebCore::HTMLPlugInImageElement::didAttachRenderers): Moved all the logic from this
2227         function into scheduleUpdateForAfterStyleResolution. Also added a call through to the base
2228         class; cleaner even though it's just an assertion.
2229         (WebCore::HTMLPlugInImageElement::scheduleUpdateForAfterStyleResolution): Added.
2230         Schedules a call to updateAfterStyleResolution when needed.
2231         (WebCore::HTMLPlugInImageElement::updateAfterStyleResolution): Added.
2232         Combines updateWidgetIfNecessary and startLoadingImage, and also deals with the new
2233         m_needsImageReload boolean in cases where no actual loading is done.
2234         (WebCore::HTMLPlugInImageElement::removedFrom): Added. Do not delay the load event of
2235         document once this element is removed, clears m_needsImageReload.
2236         (WebCore::HTMLPlugInImageElement::didMoveToNewDocument): Removed null check on oldDocument,
2237         since m_needsDocumentActivationCallbacks can't be true if the old document was null.
2238         (WebCore::is100Percent): Added helper to make function below more readable.
2239         (WebCore::HTMLPlugInImageElement::subframeLoaderWillCreatePlugIn): Restructured the code a
2240         bit. The part that attracted my attention was the local variable of type RenderBox, which
2241         was named renderEmbeddedObject. Turns out the caller guarantees to only call this if there
2242         is a renderer of type RenderEmbeddedObject, so depend on that.
2243         (WebCore::HTMLPlugInImageElement::setNeedsImageReload): Added. When called with true, sets
2244         the flag and triggers a style recalculation, and lets updateAfterStyleResolution do the rest.
2245         When called with false, reverses the effects and stops delaying the load event.
2246
2247         * html/HTMLPlugInImageElement.h: Trimmed includes a bit. Made more members private.
2248         Marked more function members final. Made a protected imageLoader function so that
2249         m_imageLoader can be private. Added new protected function updateImageLoaderWithNewURLSoon,
2250         as well as other new private functions. Made m_imageLoader be std::unique_ptr instead of
2251         OwnPtr, and added m_needsImageReload.
2252
2253         * style/StyleResolveTree.cpp:
2254         (WebCore::Style::needsPseudoElement): Fixed spelling error in the name of this function.
2255         (WebCore::Style::attachBeforeOrAfterPseudoElementIfNeeded): Updated for name change.
2256         (WebCore::Style::attachRenderTree): Update for new name of PostResolutionCallbackDisabler.
2257         (WebCore::Style::updateBeforeOrAfterPseudoElement): Updated for name change.
2258         (WebCore::Style::postResolutionCallbackQueue): Added.
2259         (WebCore::Style::queuePostResolutionCallback): Added.
2260         (WebCore::Style::suspendMemoryCacheClientCalls): Added. This is a side effect of the original
2261         PostAttachCallbackDisabler that is now done in a cleaner way, using the callback queue, instead
2262         of as a special case. It should not work for multiple documents across multiple pages instead of
2263         only the outermost one.
2264         (WebCore::Style::PostResolutionCallbackDisabler::PostResolutionCallbackDisabler): Added.
2265         Calls suspendMemoryCacheClientCalls, but a FIXME tries to point out why that isn't so great.
2266         (WebCore::Style::PostResolutionCallbackDisabler::~PostResolutionCallbackDisabler): Added.
2267         (WebCore::Style::postResolutionCallbacksAreSuspended): Added.
2268
2269         * style/StyleResolveTree.h: Added queuePostResolutionCallback and
2270         postResolutionCallbacksAreSuspended. Also added PostResolutionCallbackDisabler, which should
2271         eventually become a private implementation detail.
2272
2273 2014-03-23  Sam Weinig  <sam@webkit.org>
2274
2275         Simplify the HTMLConverter interface (Part 1)
2276         https://bugs.webkit.org/show_bug.cgi?id=130654
2277
2278         Reviewed by Dan Bernstein.
2279
2280         Convert WebHTMLConverter's interface to only use class methods as the first
2281         step of simplifying the interface. 
2282
2283         * editing/ios/EditorIOS.mm:
2284         (WebCore::attributedStringForRange):
2285         * editing/mac/EditorMac.mm:
2286         (WebCore::attributedStringForRange):
2287         * platform/mac/HTMLConverter.h:
2288         * platform/mac/HTMLConverter.mm:
2289         (+[WebHTMLConverter attributedStringFromRange:]):
2290
2291 2014-03-23  James Craig  <jcraig@apple.com>
2292
2293         Web Inspector: AXI: add other ARIA one-to-many relationships: owns, flowto, controls.
2294         https://bugs.webkit.org/show_bug.cgi?id=130635
2295
2296         Reviewed by Timothy Hatcher.
2297
2298         Support for @aria-owns, @aria-controls, and @aria-flowto.
2299
2300         Test: inspector-protocol/dom/getAccessibilityPropertiesForNode.html
2301
2302         * inspector/InspectorDOMAgent.cpp:
2303         (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
2304         * inspector/protocol/DOM.json:
2305
2306 2014-03-23  Simon Fraser  <simon.fraser@apple.com>
2307
2308         Clean up #includes by geometry classes
2309         https://bugs.webkit.org/show_bug.cgi?id=130645
2310
2311         Reviewed by Andreas Kling.
2312
2313         Pulling in <wtf/Vector.h> and <wtf/PrintStream.h> in the simple geometry
2314         classes brings in a lot of additional headers. Fix by adding a new
2315         GeometryUtilities file so that the basic files don't need Vector,
2316         and including GeometryUtilities.h where necessary.
2317         
2318         Also forward declare PrintStream.h and only bring in the header
2319         in implementation files.
2320
2321         * CMakeLists.txt:
2322         * GNUmakefile.list.am:
2323         * WebCore.vcxproj/WebCore.vcxproj:
2324         * WebCore.vcxproj/WebCore.vcxproj.filters:
2325         * WebCore.xcodeproj/project.pbxproj:
2326         * css/CSSToStyleMap.h:
2327         * html/HTMLCanvasElement.cpp:
2328         * platform/cairo/WidgetBackingStoreCairo.h:
2329         * platform/graphics/FloatPoint.cpp:
2330         * platform/graphics/FloatPoint.h:
2331         * platform/graphics/FloatRect.cpp:
2332         * platform/graphics/FloatRect.h:
2333         * platform/graphics/FloatSize.cpp:
2334         * platform/graphics/FloatSize.h:
2335         * platform/graphics/GeometryUtilities.cpp: Added.
2336         (WebCore::findSlope):
2337         (WebCore::findIntersection):
2338         (WebCore::unionRect):
2339         (WebCore::mapRect):
2340         * platform/graphics/GeometryUtilities.h: Copied from Source/WebCore/platform/graphics/TextTrackRepresentation.h.
2341         * platform/graphics/IntPoint.h:
2342         * platform/graphics/IntRect.cpp:
2343         * platform/graphics/IntRect.h:
2344         * platform/graphics/IntSize.h:
2345         * platform/graphics/TextTrackRepresentation.h:
2346         * platform/graphics/Tile.h:
2347         * platform/graphics/texmap/coordinated/UpdateAtlas.h:
2348         * platform/gtk/WidgetBackingStoreGtkX11.h:
2349         * rendering/RenderBoxModelObject.cpp:
2350         * rendering/RenderImage.cpp:
2351         * rendering/RenderObject.cpp:
2352
2353 2014-03-23  Simon Fraser  <simon.fraser@apple.com>
2354
2355         Clean up #includes by geometry classes
2356         https://bugs.webkit.org/show_bug.cgi?id=130645
2357
2358         Reviewed by Andreas Kling.
2359
2360         Pulling in <wtf/Vector.h> and <wtf/PrintStream.h> in the simple geometry
2361         classes brings in a lot of additional headers. Fix by adding a new
2362         GeometryUtilities file so that the basic files don't need Vector,
2363         and including GeometryUtilities.h where necessary.
2364         
2365         Also forward declare PrintStream.h and only bring in the header
2366         in implementation files.
2367
2368         * CMakeLists.txt:
2369         * GNUmakefile.list.am:
2370         * WebCore.vcxproj/WebCore.vcxproj:
2371         * WebCore.vcxproj/WebCore.vcxproj.filters:
2372         * WebCore.xcodeproj/project.pbxproj:
2373         * css/CSSToStyleMap.h:
2374         * html/HTMLCanvasElement.cpp:
2375         * platform/cairo/WidgetBackingStoreCairo.h:
2376         * platform/graphics/FloatPoint.cpp:
2377         * platform/graphics/FloatPoint.h:
2378         * platform/graphics/FloatRect.cpp:
2379         * platform/graphics/FloatRect.h:
2380         * platform/graphics/FloatSize.cpp:
2381         * platform/graphics/FloatSize.h:
2382         * platform/graphics/GeometryUtilities.cpp: Added.
2383         (WebCore::findSlope):
2384         (WebCore::findIntersection):
2385         (WebCore::unionRect):
2386         (WebCore::mapRect):
2387         * platform/graphics/GeometryUtilities.h: Copied from Source/WebCore/platform/graphics/TextTrackRepresentation.h.
2388         * platform/graphics/IntPoint.h:
2389         * platform/graphics/IntRect.cpp:
2390         * platform/graphics/IntRect.h:
2391         * platform/graphics/IntSize.h:
2392         * platform/graphics/TextTrackRepresentation.h:
2393         * platform/graphics/Tile.h:
2394         * platform/gtk/WidgetBackingStoreGtkX11.h:
2395         * rendering/RenderBoxModelObject.cpp:
2396         * rendering/RenderImage.cpp:
2397         * rendering/RenderObject.cpp:
2398
2399 2014-03-22  Chang Shu  <cshu@webkit.org>
2400
2401         Replace deprecatedIsCollapsibleWhitespace with RenderStyle::isCollapsibleWhiteSpace in TextIterator.
2402         https://bugs.webkit.org/show_bug.cgi?id=130612.
2403
2404         Reviewed by Darin Adler.
2405
2406         Some layout tests are affected by this change but the new behavior should be correct.
2407
2408         * editing/TextIterator.cpp:
2409         (WebCore::TextIterator::handleTextNode):
2410         (WebCore::TextIterator::handleTextBox):
2411
2412 2014-03-22  Sam Weinig  <sam@webkit.org>
2413
2414         Switch HTMLConverter to use CSSPropertyIDs to refer to CSS properties
2415         https://bugs.webkit.org/show_bug.cgi?id=130639
2416
2417         Reviewed by Darin Adler.
2418
2419         This is a ~15% speedup on PerformanceTests/Interactive/CopyAll.html.
2420
2421         - Removes gratuitous lookup of CSS properties that are known at compile time.
2422         - Removes attempted use of non-supported CSS properties (font-effect and horizontal-align) 
2423           that will alway yield the same results.
2424         - Fix some obvious typos where the author thought they were testing for fontKerning or fontLigatures
2425           but instead used the non-existent font-effect.
2426
2427         * platform/mac/HTMLConverter.mm:
2428         (HTMLConverterCaches::computedStylePropertyForElement):
2429         (HTMLConverterCaches::inlineStylePropertyForElement):
2430         (HTMLConverterCaches::propertyValueForNode):
2431         (-[WebHTMLConverter _stringForNode:property:]):
2432         (HTMLConverterCaches::floatPropertyValueForNode):
2433         (-[WebHTMLConverter _getFloat:forNode:property:]):
2434         (HTMLConverterCaches::isBlockElement):
2435         (HTMLConverterCaches::elementHasOwnBackgroundColor):
2436         (HTMLConverterCaches::colorPropertyValueForNode):
2437         (-[WebHTMLConverter _colorForNode:property:]):
2438         (-[WebHTMLConverter _computedAttributesForElement:]):
2439         (-[WebHTMLConverter _addAttachmentForElement:URL:needsParagraph:usePlaceholder:]):
2440         (-[WebHTMLConverter _fillInBlock:forElement:backgroundColor:extraMargin:extraPadding:isTable:]):
2441         (-[WebHTMLConverter _addTableForElement:]):
2442         (-[WebHTMLConverter _addTableCellForElement:]):
2443         (-[WebHTMLConverter _processElement:tag:display:depth:]):
2444         (-[WebHTMLConverter _exitElement:tag:display:depth:startIndex:]):
2445         (-[WebHTMLConverter _processText:]):
2446         (-[WebHTMLConverter _traverseNode:depth:embedded:]):
2447
2448 2014-03-22  Andreas Kling  <akling@apple.com>
2449
2450         Fix debug build.
2451
2452         * bindings/js/JSDOMBinding.h:
2453         (WebCore::createWrapper):
2454
2455 2014-03-22  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2456
2457         Add *final* keyword to NavigatorContentUtils class
2458         https://bugs.webkit.org/show_bug.cgi?id=130636
2459
2460         Reviewed by Darin Adler.
2461
2462         NavigatorContentUtils won't be used as a base class. So, added final keyword.
2463
2464         No new tests, no behavior changes.
2465
2466         * Modules/navigatorcontentutils/NavigatorContentUtils.h:
2467
2468 2014-03-22  Andreas Kling  <akling@apple.com>
2469
2470         CREATE_DOM_WRAPPER doesn't need the ExecState.
2471         <https://webkit.org/b/130648>
2472
2473         Remove the ExecState parameter from CREATE_DOM_WRAPPER and get all
2474         that we need from the global object instead.
2475
2476         toJS() and toJSNewlyCreated() still take an ExecState, that needs
2477         to be dealt with separately since some of them have scary looking
2478         currentWorld() checks.
2479
2480         Reviewed by Darin Adler.
2481
2482         * bindings/js/JSAudioContextCustom.cpp:
2483         (WebCore::JSAudioContextConstructor::constructJSAudioContext):
2484         * bindings/js/JSBlobCustom.cpp:
2485         (WebCore::toJS):
2486         (WebCore::JSBlobConstructor::constructJSBlob):
2487         * bindings/js/JSCDATASectionCustom.cpp:
2488         (WebCore::toJSNewlyCreated):
2489         * bindings/js/JSCSSRuleCustom.cpp:
2490         (WebCore::toJS):
2491         * bindings/js/JSCSSValueCustom.cpp:
2492         (WebCore::toJS):
2493         * bindings/js/JSCanvasRenderingContextCustom.cpp:
2494         (WebCore::toJS):
2495         * bindings/js/JSDOMBinding.h:
2496         (WebCore::createWrapper):
2497         (WebCore::wrap):
2498         (WebCore::createNewWrapper):
2499         * bindings/js/JSDocumentCustom.cpp:
2500         (WebCore::toJS):
2501         * bindings/js/JSElementCustom.cpp:
2502         (WebCore::toJSNewlyCreated):
2503         * bindings/js/JSEventCustom.cpp:
2504         (WebCore::toJS):
2505         * bindings/js/JSHTMLCollectionCustom.cpp:
2506         (WebCore::toJS):
2507         * bindings/js/JSHTMLTemplateElementCustom.cpp:
2508         (WebCore::JSHTMLTemplateElement::content):
2509         * bindings/js/JSIDBAnyCustom.cpp:
2510         (WebCore::toJS):
2511         * bindings/js/JSImageDataCustom.cpp:
2512         (WebCore::toJS):
2513         * bindings/js/JSMediaStreamCapabilitiesCustom.cpp:
2514         (WebCore::toJS):
2515         * bindings/js/JSNodeCustom.cpp:
2516         (WebCore::createWrapperInline):
2517         * bindings/js/JSPerformanceEntryCustom.cpp:
2518         (WebCore::toJS):
2519         * bindings/js/JSRTCIceCandidateCustom.cpp:
2520         (WebCore::JSRTCIceCandidateConstructor::constructJSRTCIceCandidate):
2521         * bindings/js/JSRTCPeerConnectionCustom.cpp:
2522         (WebCore::JSRTCPeerConnectionConstructor::constructJSRTCPeerConnection):
2523         * bindings/js/JSRTCSessionDescriptionCustom.cpp:
2524         (WebCore::JSRTCSessionDescriptionConstructor::constructJSRTCSessionDescription):
2525         * bindings/js/JSSVGPathSegCustom.cpp:
2526         (WebCore::toJS):
2527         * bindings/js/JSStyleSheetCustom.cpp:
2528         (WebCore::toJS):
2529         * bindings/js/JSTextCustom.cpp:
2530         (WebCore::toJSNewlyCreated):
2531         * bindings/js/JSTextTrackCueCustom.cpp:
2532         (WebCore::toJS):
2533         * bindings/js/JSTouchCustom.cpp:
2534         (WebCore::toJSNewlyCreated):
2535         * bindings/js/JSTouchListCustom.cpp:
2536         (WebCore::toJSNewlyCreated):
2537         * bindings/js/JSTrackCustom.cpp:
2538         (WebCore::toJS):
2539         * bindings/scripts/CodeGeneratorJS.pm:
2540         (GenerateImplementation):
2541         * dom/make_names.pl:
2542         (printWrapperFunctions):
2543         (printWrapperFactoryCppFile):
2544         (printWrapperFactoryHeaderFile):
2545
2546 2014-03-22  Michael Saboff  <msaboff@apple.com>
2547
2548         toThis() on a JSWorkerGlobalScope should return a JSProxy and not undefined
2549         https://bugs.webkit.org/show_bug.cgi?id=130554
2550
2551         Reviewed by Geoffrey Garen.
2552
2553         Fixed toThis() on WorkerGlobalScope to return a JSProxy instead of the JSGlobalObject.
2554         Added cast from JSProxy->target() if the jsCast<>() to the native object fails
2555         in toJSDedicatedWorkerGlobalScope() and toJSSharedWorkerGlobalScope().
2556         The original cast is needed for access to the local side of the worker, while the JSProxy
2557         cast is used on the remote side of a worker.
2558
2559         Test: fast/workers/worker-strict.html
2560
2561         * bindings/js/JSWorkerGlobalScopeBase.cpp:
2562         (WebCore::toJSDedicatedWorkerGlobalScope):
2563         (WebCore::toJSSharedWorkerGlobalScope):
2564
2565         * bindings/js/WorkerScriptController.cpp:
2566         (WebCore::WorkerScriptController::evaluate): Changed to pass in the JSProxy and not
2567         the WorkerGlobalScope object as the this object to script evaluation.
2568
2569         * workers/DedicatedWorkerGlobalScope.idl:
2570         * workers/SharedWorkerGlobalScope.idl:
2571         * workers/WorkerGlobalScope.idl:
2572         Added the new CustomProxyToJSObject attribute so we'll call to<{nativeClass}>() for
2573         getting the object to use for global evaluation.
2574
2575 2014-03-22  Simon Fraser  <simon.fraser@apple.com>
2576
2577         Some #include hygiene in Node/Element etc
2578         https://bugs.webkit.org/show_bug.cgi?id=130642
2579
2580         Reviewed by Geoffrey Garen.
2581
2582         Clean up various #includes.
2583
2584         * accessibility/AccessibilityObject.h:
2585         * bindings/js/WebCoreTypedArrayController.h:
2586         * dom/Element.h:
2587         * dom/EventListenerMap.h:
2588         * dom/EventTarget.h:
2589         * dom/Node.h:
2590         * rendering/RenderObject.h:
2591         * rendering/svg/RenderSVGRoot.h:
2592
2593 2014-03-22  Simon Fraser  <simon.fraser@apple.com>
2594
2595         FloatRect.h on iOS should not suck in a system header
2596         https://bugs.webkit.org/show_bug.cgi?id=130641
2597
2598         Reviewed by Geoff Garen.
2599
2600         Don't pull in <CoreGraphics/CGGeometry.h> from FloatRect.h.
2601
2602         * platform/graphics/FloatRect.h:
2603
2604 2014-03-22  Dan Bernstein  <mitz@apple.com>
2605
2606         Fixed the iOS build.
2607
2608         Reviewed by Darin Adler.
2609
2610         * page/ios/FrameIOS.mm:
2611         (WebCore::Frame::interpretationsForCurrentRoot):
2612
2613 2014-03-22  Darin Adler  <darin@apple.com>
2614
2615         Remove String::deprecatedCharacters
2616         https://bugs.webkit.org/show_bug.cgi?id=126854
2617
2618         Reviewed by Sam Weinig.
2619
2620         * bindings/scripts/StaticString.pm:
2621         (GenerateStrings): Remove the code to generate the null m_copyData16 pointer.
2622
2623         * editing/TextIterator.cpp:
2624         (WebCore::SearchBuffer::prependContext): Changed to use the new append function in
2625         StringView.h and removed the one defined locally here.
2626
2627         * editing/VisibleUnits.cpp:
2628         (WebCore::wordBreakIteratorForMinOffsetBoundary): Use the new append function
2629         in StringView.h instead of using deprecatedCharacters.
2630         (WebCore::wordBreakIteratorForMaxOffsetBoundary): Ditto.
2631         Removed an append function defined locally here and use the one in StringView.h.
2632
2633         * editing/htmlediting.cpp:
2634         (WebCore::stringWithRebalancedWhitespace): Use StringView::getCharactersWithUpconvert.
2635
2636         * html/parser/HTMLToken.h:
2637         (WebCore::HTMLToken::appendToAttributeValue): Changed to take a StringView instead
2638         of a const String&.
2639
2640         * loader/appcache/ManifestParser.cpp:
2641         (WebCore::parseManifest): Use StringView and StringView::upconvertedCharacters.
2642
2643         * page/EventSource.cpp:
2644         (WebCore::EventSource::didReceiveData): Use the new append overload from StringView.h.
2645         Also added a comment about incorrect use of the decode function.
2646
2647         * page/ios/FrameIOS.mm:
2648         (WebCore::Frame::interpretationsForCurrentRoot): Use the new StringView append function.
2649         Also use simpler new-style for loops.
2650
2651         * platform/LinkHash.cpp:
2652         (WebCore::visitedURLInline): Use the new append function and StringView::substring.
2653         (WebCore::visitedLinkHash): Use upconvertedCharacters for the non-8-bit case.
2654
2655         * platform/URL.cpp:
2656         (WebCore::findFirstOf): Chagned to take a StringView.
2657         (WebCore::containsOnlyASCII): Added. Works on StringView. Could move to a WTF header in
2658         the future if it's needed elsewhere.
2659         (WebCore::protocolIs): Added. Works on StringView. Could put in URL.h if needed elsewhere,
2660         or consider replacing the one that takes const String& with just this one.
2661         (WebCore::appendEncodedHostname): Changed to take a StringView and use
2662         StringView::upconvertedCharacters.
2663         (WebCore::findHostnamesInMailToURL): Changed to take a StringView.
2664         (WebCore::findHostnameInHierarchicalURL): Ditto.
2665         (WebCore::encodeHostnames): Ditto.
2666         (WebCore::encodeRelativeString): Ditto.
2667
2668         * platform/graphics/StringTruncator.cpp:
2669         (WebCore::StringTruncator::width): Use StringView::upconvertedCharacters.
2670
2671         * platform/graphics/harfbuzz/HarfBuzzShaper.cpp:
2672         (WebCore::HarfBuzzShaper::setFontFeatures): Use indexing directly on the string instead
2673         of on a UChar*.
2674         (WebCore::HarfBuzzShaper::shapeHarfBuzzRuns): Use StringView::upconvertedCharacters.
2675
2676         * platform/text/TextCodecICU.cpp:
2677         (WebCore::TextCodecICU::encode): Use a Vector<UChar> rather than a String to copy and
2678         replace the backslashes with yen signs. Also optimize case where there are no backslashes.
2679
2680         * rendering/RenderListMarker.cpp:
2681         (WebCore::RenderListMarker::paint): Use TextRun::setText(StringView).
2682
2683         * rendering/RenderText.cpp:
2684         (WebCore::maxWordFragmentWidth): Pass a String to RenderBlock::constructTextRun instead of
2685         calling StringBuilder::deprecatedCharacters.
2686
2687         * rendering/RenderText.h: Removed deprecatedCharacters function.
2688
2689         * rendering/line/BreakingContextInlineHeaders.h: Added now-needed header include.
2690
2691         * rendering/svg/SVGInlineTextBox.cpp:
2692         (WebCore::SVGInlineTextBox::constructTextRun): Use StringView version of TextRun constructor.
2693
2694         * rendering/svg/SVGTextMetrics.cpp:
2695         (WebCore::SVGTextMetrics::SVGTextMetrics): Take references instead of pointers.
2696         (WebCore::SVGTextMetrics::constructTextRun): Take references instead of pointers, and don't
2697         take a character pointer any more. Instead, extract the text and use the StringView version of
2698         the TextRun constructor.
2699         (WebCore::SVGTextMetrics::measureCharacterRange): Take references instead of pointers and
2700         update for above changes.
2701         * rendering/svg/SVGTextMetrics.h: Updated for changes above. Also tweaked style a bit.
2702
2703         * rendering/svg/SVGTextMetricsBuilder.cpp:
2704         (WebCore::SVGTextMetricsBuilder::advanceSimpleText): Updated for SVGTextMetrics changes.
2705         (WebCore::SVGTextMetricsBuilder::advanceComplexText): Ditto.
2706         (WebCore::SVGTextMetricsBuilder::initializeMeasurementWithTextRenderer): Ditto.
2707         (WebCore::SVGTextMetricsBuilder::measureTextRenderer): Change code to store a character
2708         for lastCharacter rather than storing a pointer to a character. Stop using TextRun::data16.
2709
2710         * rendering/svg/SVGTextQuery.cpp:
2711         (WebCore::SVGTextQuery::subStringLengthCallback): Updated for SVGTextMetrics changes.
2712         (WebCore::SVGTextQuery::startPositionOfCharacterCallback): Ditto.
2713         (WebCore::SVGTextQuery::endPositionOfCharacterCallback): Ditto.
2714         (WebCore::calculateGlyphBoundaries): Ditto.
2715
2716         * xml/XPathFunctions.cpp:
2717         (WebCore::XPath::atomicSubstring): Added.
2718         (WebCore::XPath::FunId::evaluate): Tweaked a bit to use a new style for loop.
2719         Use the atomicSubstring function to avoid making a temporary String just to make an AtomicString.
2720         That function also uses characters8/16 rather than depreccatedCharacters.
2721
2722         * xml/XPathNodeSet.h: Added begin and end so this collection can be iterated with new style for loop.
2723
2724         * xml/parser/XMLDocumentParserLibxml2.cpp:
2725         (WebCore::XMLDocumentParser::doWrite): Use StringView::upconvertedCharacters.
2726         (WebCore::parseAttributes): Ditto.
2727
2728 2014-03-22  Commit Queue  <commit-queue@webkit.org>
2729
2730         Unreviewed, rolling out r166118.
2731         https://bugs.webkit.org/show_bug.cgi?id=130640
2732
2733         Crashing things (Requested by weinig on #webkit).
2734
2735         Reverted changeset:
2736
2737         "Switch HTMLConverter to use CSSPropertyIDs to refer to CSS
2738         properties"
2739         https://bugs.webkit.org/show_bug.cgi?id=130639
2740         http://trac.webkit.org/changeset/166118
2741
2742 2014-03-22  Sam Weinig  <sam@webkit.org>
2743
2744         Switch HTMLConverter to use CSSPropertyIDs to refer to CSS properties
2745         https://bugs.webkit.org/show_bug.cgi?id=130639
2746
2747         Reviewed by Simon Fraser.
2748
2749         This is a ~15% speedup on PerformanceTests/Interactive/CopyAll.html.
2750
2751         - Removes gratuitous lookup of CSS properties that are known at compile time.
2752         - Removes attempted use of non-supported CSS properties (font-effect and horizontal-align) 
2753           that will alway yield the same results.
2754         - Fix some obvious typos where the author thought they were testing for fontKerning or fontLigatures
2755           but instead used the non-existent font-effect.
2756
2757         * platform/mac/HTMLConverter.mm:
2758         (HTMLConverterCaches::computedStylePropertyForElement):
2759         (HTMLConverterCaches::inlineStylePropertyForElement):
2760         (HTMLConverterCaches::propertyValueForNode):
2761         (-[WebHTMLConverter _stringForNode:property:]):
2762         (HTMLConverterCaches::floatPropertyValueForNode):
2763         (-[WebHTMLConverter _getFloat:forNode:property:]):
2764         (HTMLConverterCaches::isBlockElement):
2765         (HTMLConverterCaches::elementHasOwnBackgroundColor):
2766         (HTMLConverterCaches::colorPropertyValueForNode):
2767         (-[WebHTMLConverter _colorForNode:property:]):
2768         (-[WebHTMLConverter _computedAttributesForElement:]):
2769         (-[WebHTMLConverter _addAttachmentForElement:URL:needsParagraph:usePlaceholder:]):
2770         (-[WebHTMLConverter _fillInBlock:forElement:backgroundColor:extraMargin:extraPadding:isTable:]):
2771         (-[WebHTMLConverter _addTableForElement:]):
2772         (-[WebHTMLConverter _addTableCellForElement:]):
2773         (-[WebHTMLConverter _processElement:tag:display:depth:]):
2774         (-[WebHTMLConverter _exitElement:tag:display:depth:startIndex:]):
2775         (-[WebHTMLConverter _processText:]):
2776         (-[WebHTMLConverter _traverseNode:depth:embedded:]):
2777
2778 2014-03-21  Simon Fraser  <simon.fraser@apple.com>
2779
2780         Don't flush compositing layers within FrameView::willPaintContents()
2781         https://bugs.webkit.org/show_bug.cgi?id=130627
2782         <rdar://problem/16368869>
2783
2784         Reviewed by Sam Weinig.
2785
2786         Remove the call to flushCompositingStateForThisFrame() here. We should
2787         have always flushed before painting via other mechanisms in WebKit2 and WebKit2.
2788         Flushing during painting is actually harmful, since we could be inside
2789         a CA commit already, and creating or destroying layers via flushing is bad.
2790
2791         * page/FrameView.cpp:
2792         (WebCore::FrameView::willPaintContents):
2793
2794 2014-03-22  Martin Hodovan  <mhodovan@inf.u-szeged.hu>
2795
2796         ASSERTION FAILED: std::isfinite(num) in WebCore::CSSPrimitiveValue::CSSPrimitiveValue
2797         https://bugs.webkit.org/show_bug.cgi?id=127361
2798
2799         Huge numbers represented by the 'INF' value can not be used
2800         in CSS rules, so they make the assert fail. We have to make
2801         sure that the parsed property value is finite, otherwise
2802         the property will be dropped.
2803
2804         Test: fast/css/infinite-floating-value.html
2805
2806         * css/CSSValuePool.cpp:
2807         (WebCore::CSSValuePool::createValue):
2808
2809 2014-03-21  Zalan Bujtas  <zalan@apple.com>
2810
2811         Remove redundant friending from class Image.
2812         https://bugs.webkit.org/show_bug.cgi?id=130628
2813
2814         Reviewed by Simon Fraser.
2815
2816         Those friend classes are subclasses. No need to make them friend of their parent class.
2817
2818         No change in functionality.
2819
2820         * platform/graphics/Image.h:
2821
2822 2014-03-21  Benjamin Poulain  <bpoulain@apple.com>
2823
2824         [iOS][WK2] Reduce the tiling coverage to the current rect and 1 tile size ahead
2825         https://bugs.webkit.org/show_bug.cgi?id=130555
2826
2827         Reviewed by Simon Fraser.
2828
2829         * WebCore.exp.in:
2830         * platform/ScrollView.h:
2831         * platform/graphics/ca/mac/TileController.mm:
2832         (WebCore::TileController::computeTileCoverageRect):
2833         * platform/ios/ScrollViewIOS.mm:
2834         (WebCore::ScrollView::setScrollVelocityInformation):
2835         (WebCore::ScrollView::computeCoverageRect):
2836         * rendering/RenderLayerCompositor.cpp:
2837         (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
2838
2839 2014-03-21  Eric Carlson  <eric.carlson@apple.com>
2840
2841         [iOS] clean up fullscreen player controller when exiting fullscreen
2842         https://bugs.webkit.org/show_bug.cgi?id=130621
2843
2844         Reviewed by Jer Noble.
2845
2846         * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
2847         (-[WebAVVideoLayer setBounds:]): Do nothing if _avPlayerController is nil.
2848         (-[WebAVVideoLayer setVideoLayerGravity:]): Ditto.
2849         (WebVideoFullscreenInterfaceAVKit::exitFullscreen): Set m_playerViewController delegate
2850             and player controller to nil.
2851
2852 2014-03-21  Eric Carlson  <eric.carlson@apple.com>
2853
2854         [iOS] remote command callbacks must happen on the WebThread
2855         https://bugs.webkit.org/show_bug.cgi?id=130618
2856
2857         Reviewed by Jer Noble.
2858
2859         * platform/ios/RemoteCommandListenerIOS.h:
2860         (WebCore::RemoteCommandListenerIOS::createWeakPtr):
2861         * platform/ios/RemoteCommandListenerIOS.mm:
2862         (WebCore::RemoteCommandListenerIOS::RemoteCommandListenerIOS): Dispatch commands to the
2863             main thread before making listener callbacks.
2864
2865 2014-03-21  Zalan Bujtas  <zalan@apple.com>
2866
2867         Subpixel rendering: Make <img> positioning subpixel aware.
2868         https://bugs.webkit.org/show_bug.cgi?id=130596
2869
2870         Reviewed by Simon Fraser.
2871
2872         Change <img> positioning from integral to device pixel. It enables us
2873         to paint hairline borders around <img> properly.
2874         This patch changes the behavior of broken image representation from constant 1 CSS px border
2875         to a dynamic 1 device px.
2876
2877         Test: fast/images/hidpi-image-position-on-device-pixels.html
2878
2879         * WebCore.exp.in:
2880         * platform/graphics/GraphicsContext.cpp:
2881         (WebCore::GraphicsContext::drawImage):
2882         * platform/graphics/GraphicsContext.h:
2883         * platform/graphics/cairo/GraphicsContextCairo.cpp:
2884         (WebCore::GraphicsContext::drawRect):
2885         * platform/graphics/cg/GraphicsContextCG.cpp:
2886         (WebCore::GraphicsContext::drawRect):
2887         * platform/graphics/wince/GraphicsContextWinCE.cpp:
2888         (WebCore::GraphicsContext::drawRect):
2889         * rendering/RenderImage.cpp:
2890         (WebCore::RenderImage::paintReplaced):
2891         (WebCore::RenderImage::paintIntoRect):
2892         * rendering/RenderImage.h:
2893         * rendering/RenderLayer.cpp:
2894         (WebCore::RenderLayer::drawPlatformResizerImage):
2895
2896 2014-03-21  Brent Fulgham  <bfulgham@apple.com>
2897
2898         Merge VTTScanner Code from Blink
2899         https://bugs.webkit.org/show_bug.cgi?id=130616
2900
2901         Reviewed by Eric Carlson.
2902
2903         Merged from Blink (patch by fs@opera.com):
2904         https://chromium.googlesource.com/chromium/blink/+/f1ceb058d574a1174b524c57f67350510a942071
2905         http://crbug.com/75273002
2906         https://chromium.googlesource.com/chromium/blink/+/3e2c67969486e86347b328c72c67cacabfe6f4a1
2907         http://crbug.com/134173002
2908         https://chromium.googlesource.com/chromium/blink/+/5962b7bbb001838f3fc7f24817637528b86bfd9b
2909         http://crbug.com/134153002
2910         https://chromium.googlesource.com/chromium/blink/+/6c81f51438013edca920a19fc6a31026fc562af2
2911         http://crbug.com/137033002
2912         https://chromium.googlesource.com/chromium/blink/+/fa286dca17a291da3ae8be80111e2264de6d5cfd
2913         http://crbug.com/140503004
2914         https://chromium.googlesource.com/chromium/blink/+/8f33b63aabcce7dd21dd15288d45c4eb37c02001
2915         http://crbug.com/139343006
2916         https://chromium.googlesource.com/chromium/blink/+/1872b54b908fac525f1ad9d6f15174b11e27c8af
2917         http://crbug.com/143983002
2918         https://chromium.googlesource.com/chromium/blink/+/e6494b3359e2077bd8772d86ab1fb709acf4c398
2919         http://crbug.com/144893002
2920  
2921         * CMakeLists.txt:
2922         * GNUmakefile.list.am:
2923         * WebCore.vcxproj/WebCore.vcxproj:
2924         * WebCore.vcxproj/WebCore.vcxproj.filters:
2925         * WebCore.xcodeproj/project.pbxproj:
2926         * html/track/ParsingUtilities.h: Added.
2927         (skipExactly):
2928         (skipUntil):
2929         (skipWhile):
2930         * html/track/VTTCue.cpp:
2931         (WebCore::VTTCue::markFutureAndPastNodes):
2932         (WebCore::VTTCue::settingName):
2933         (WebCore::scanPercentage):
2934         (WebCore::VTTCue::setCueSettings):
2935         * html/track/VTTCue.h:
2936         * html/track/VTTRegion.cpp:
2937         (WebCore::VTTRegion::setRegionSettings):
2938         (WebCore::VTTRegion::scanSettingName):
2939         (WebCore::parsedEntireRun):
2940         (WebCore::VTTRegion::parseSettingValue):
2941         * html/track/VTTRegion.h:
2942         * html/track/VTTScanner.cpp: Added.
2943         (WebCore::VTTScanner::VTTScanner):
2944         (WebCore::VTTScanner::scan):
2945         (WebCore::VTTScanner::scanRun):
2946         (WebCore::VTTScanner::skipRun):
2947         (WebCore::VTTScanner::extractString):
2948         (WebCore::VTTScanner::restOfInputAsString):
2949         (WebCore::VTTScanner::scanDigits):
2950         (WebCore::VTTScanner::scanFloat):
2951         * html/track/VTTScanner.h: Added.
2952         (WebCore::VTTScanner::Run::Run):
2953         (WebCore::VTTScanner::Run::start):
2954         (WebCore::VTTScanner::Run::end):
2955         (WebCore::VTTScanner::Run::isEmpty):
2956         (WebCore::VTTScanner::isAt):
2957         (WebCore::VTTScanner::isAtEnd):
2958         (WebCore::VTTScanner::match):
2959         (WebCore::VTTScanner::position):
2960         (WebCore::VTTScanner::end):
2961         (WebCore::VTTScanner::LCharPredicateAdapter):
2962         (WebCore::VTTScanner::Run::length):
2963         (WebCore::VTTScanner::scan):
2964         (WebCore::VTTScanner::skipWhile):
2965         (WebCore::VTTScanner::skipUntil):
2966         (WebCore::VTTScanner::collectWhile):
2967         (WebCore::VTTScanner::collectUntil):
2968         (WebCore::VTTScanner::seekTo):
2969         (WebCore::VTTScanner::currentChar):
2970         (WebCore::VTTScanner::advance):
2971         * html/track/WebVTTParser.cpp:
2972         (WebCore::WebVTTParser::parseFloatPercentageValue):
2973         (WebCore::WebVTTParser::parseFloatPercentageValuePair):
2974         (WebCore::WebVTTParser::collectTimingsAndSettings):
2975         (WebCore::WebVTTParser::collectTimeStamp):
2976         (WebCore::WebVTTTreeBuilder::constructTreeFromToken):
2977         * html/track/WebVTTParser.h:
2978
2979 2014-03-21  Benjamin Poulain  <bpoulain@apple.com>
2980
2981         Pseudo type cleanup part 2: split pseudo elements parsing
2982         https://bugs.webkit.org/show_bug.cgi?id=130370
2983
2984         Reviewed by Andreas Kling.
2985
2986         With this patch, pseudo elements are handled separately. The only thing left in
2987         the old path is compatibility pseudo elements and pseudo classes.
2988
2989         The list of special pseudo elements is now separated and is stored in SelectorPseudoElementTypeMap.in.
2990         The script makeSelectorPseudoElementsMap.py takes that list to make the pseudo elements hash table.
2991
2992         The other pseudo elements are the prefixed ones, they are filtered in CSSSelector::parsePseudoElementType().
2993
2994         All the non-compatibility selectors are removed from SelectorPseudoTypeMap.in. CSSParserSelector::setPseudoTypeValue()
2995         is updated accordingly. The next step will be to clean that part.
2996
2997         * CMakeLists.txt:
2998         * DerivedSources.make:
2999         * GNUmakefile.list.am:
3000         * WebCore.vcxproj/WebCore.vcxproj:
3001         * WebCore.vcxproj/WebCore.vcxproj.filters:
3002         * WebCore.xcodeproj/project.pbxproj:
3003         * css/CSSComputedStyleDeclaration.cpp:
3004         (WebCore::CSSComputedStyleDeclaration::CSSComputedStyleDeclaration):
3005         * css/CSSGrammar.y.in:
3006         * css/CSSParserValues.cpp:
3007         (WebCore::CSSParserSelector::parsePseudoElementSelector):
3008         (WebCore::CSSParserSelector::parsePseudoCueFunctionSelector):
3009         (WebCore::CSSParserSelector::setPseudoTypeValue):
3010         * css/CSSParserValues.h:
3011         * css/CSSSelector.cpp:
3012         (WebCore::CSSSelector::parsePseudoElementType):
3013         * css/CSSSelector.h:
3014         * css/SelectorPseudoElementTypeMap.in: Added.
3015         * css/SelectorPseudoTypeMap.h:
3016         * css/SelectorPseudoTypeMap.in:
3017         * css/html.css:
3018         (q::before):
3019         (q::after):
3020         * css/makeSelectorPseudoElementsMap.py: Added.
3021         (enumerablePseudoType):
3022         (expand_ifdef_condition):
3023         * page/DOMWindow.cpp:
3024         (WebCore::DOMWindow::getMatchedCSSRules):
3025
3026 2014-03-20  Andreas Kling  <akling@apple.com>
3027
3028         Less inclusion of JSCInlines.h.
3029         <https://webkit.org/b/130545>
3030
3031         Stop including JSCInlines.h from JSDOMGlobalObject.h!
3032
3033         Reviewed by Simon Fraser.
3034
3035         * ForwardingHeaders/runtime/IdentifierInlines.h: Added.
3036         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
3037         * bindings/js/JSCommandLineAPIHostCustom.cpp:
3038         * bindings/js/JSDOMGlobalObject.h:
3039         * bindings/js/JSDOMStringMapCustom.cpp:
3040         * bindings/js/JSHTMLAllCollectionCustom.cpp:
3041         * bindings/js/JSHTMLFormControlsCollectionCustom.cpp:
3042         * bindings/js/JSLazyEventListener.cpp:
3043         * bindings/js/JSSQLResultSetRowListCustom.cpp:
3044         * bindings/js/JSStorageCustom.cpp:
3045         * bindings/js/ScriptGlobalObject.cpp:
3046         * dom/NodeIterator.cpp:
3047         * dom/TreeWalker.cpp:
3048         * testing/Internals.cpp:
3049         * testing/js/WebCoreTestSupport.cpp:
3050
3051 2014-03-21  Oliver Hunt  <oliver@apple.com>
3052
3053         Fix a crash when assigning an object to document.location
3054         https://bugs.webkit.org/show_bug.cgi?id=130213
3055
3056         Reviewed by Geoffrey Garen.
3057
3058         Convert location to string before we make use the document.
3059         This prevents us from attempting to navigate a frame that
3060         has already been removed.
3061
3062         Test: fast/dom/navigation-with-sideeffects-crash.html
3063
3064         * bindings/js/JSDocumentCustom.cpp:
3065         (WebCore::JSDocument::location):
3066         (WebCore::JSDocument::setLocation):
3067
3068 2014-03-21  Brian Burg  <bburg@apple.com>
3069
3070         Web Replay: replay controller is improperly setting user input bridge state
3071         https://bugs.webkit.org/show_bug.cgi?id=130606
3072
3073         Reviewed by Timothy Hatcher.
3074
3075         The user input bridge was being set based on the old session state,
3076         rather than the new session state.
3077
3078         * replay/ReplayController.cpp:
3079         (WebCore::ReplayController::setSessionState):
3080
3081 2014-03-21  James Craig  <jcraig@apple.com>
3082
3083         Web Inspector: AXI: Expose Accessibility Tree children of the selected node
3084         https://bugs.webkit.org/show_bug.cgi?id=130264
3085
3086         Reviewed by Timothy Hatcher.
3087
3088         Test: inspector-protocol/dom/getAccessibilityPropertiesForNode.html
3089
3090         Expose the accessibility tree children (different from DOM children) of the
3091         current node in the accessibility node inspector.
3092
3093         * inspector/InspectorDOMAgent.cpp: 
3094         (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
3095         * inspector/InspectorDOMAgent.h:
3096         * inspector/protocol/DOM.json:
3097
3098 2014-03-21  Alex Christensen  <achristensen@webkit.org>
3099
3100         [Win] Compile fixes with video not enabled.
3101         https://bugs.webkit.org/show_bug.cgi?id=130597
3102
3103         Reviewed by Darin Adler.
3104
3105         * DerivedSources.make:
3106         Only generate UserAgentScripts.h if needed.
3107         * platform/audio/MediaSession.cpp:
3108         * platform/audio/MediaSessionManager.cpp:
3109         Only compile if video is enabled.
3110
3111 2014-03-21  Adenilson Cavalcanti  <cavalcantii@gmail.com>
3112
3113         Optimize FEGaussian blur
3114         https://bugs.webkit.org/show_bug.cgi?id=50881
3115
3116         Reviewed by Dirk Schulze.
3117
3118         Currently boxBlur() will calculate the filter for each channel in
3119         a loop and also uses Uint8ClampedArray::set() to write the
3120         resulting pixels into destination array.
3121
3122         Using Uint8ClampedArray::set() requires lots of unnecessary type
3123         conversions, not to mention other function calls. This patch
3124         updates the original written by Simon Fraser to apply cleanly to current
3125         trunk.
3126
3127         It also implements code to handle EdgeModes and finally avoids use
3128         of ::set() in the newly added boxBlurAlphaOnly()
3129         function. Assignment of calculated pixel values rely on pointers.
3130
3131         No new tests, no change on behavior.
3132
3133         * platform/graphics/filters/FEGaussianBlur.cpp:
3134         (WebCore::boxBlurAlphaOnly): Specialized version for alpha only cases.
3135         (WebCore::boxBlur):
3136
3137 2014-03-21  Simon Fraser  <simon.fraser@apple.com>
3138
3139         unobscuredContentRect() should have the same signature on iOS and other platforms,
3140         and should not recurse on iOS.
3141         https://bugs.webkit.org/show_bug.cgi?id=130604
3142         <rdar://problem/16392587>
3143
3144         Reviewed by Tim Horton and Beth Dakin.
3145
3146         Having different signatures on different platforms is a recipe for
3147         build breakage. Give the iOS unobscuredContentRect() an unused 
3148         VisibleContentRectIncludesScrollbars parameter.
3149         
3150         Also avoid recursion via unobscuredContentRect() calling visibleContentRectInternal().
3151
3152         * WebCore.exp.in:
3153         * platform/ScrollView.cpp:
3154         (WebCore::ScrollView::unobscuredContentRect):
3155         (WebCore::ScrollView::unobscuredContentRectInternal):
3156         (WebCore::ScrollView::visibleContentRectInternal):
3157         * platform/ScrollView.h:
3158         (WebCore::ScrollView::unobscuredContentRectIncludingScrollbars):
3159         * platform/ios/ScrollViewIOS.mm:
3160         (WebCore::ScrollView::unobscuredContentRect):
3161
3162 2014-03-21  Brent Fulgham  <bfulgham@apple.com>
3163
3164         Handle recovery on "timestamp-looking" lines in the WebVTT parser
3165         https://bugs.webkit.org/show_bug.cgi?id=130610
3166
3167         Reviewed by Eric Carlson.
3168
3169         Merged from Blink (patch by fs@opera.com):
3170         https://chromium.googlesource.com/chromium/blink/+/b669a380efbffe25f3b154b026b57b9822ce08e2
3171         http://crbug.com/75273002
3172
3173         Tests: media/track/track-webvtt-tc031-cue-recovery.html
3174                media/track/track-webvtt-tc032-degenerate-cues.html
3175
3176         * html/track/WebVTTParser.cpp:
3177         (WebCore::WebVTTParser::parse):
3178         (WebCore::WebVTTParser::collectCueText):
3179         (WebCore::WebVTTParser::recoverCue):
3180         (WebCore::WebVTTParser::ignoreBadCue):
3181         * html/track/WebVTTParser.h:
3182
3183 2014-03-21  Andreas Kling  <akling@apple.com>
3184
3185         Remove unused RenderView::repaintRectangleInViewAndCompositedLayers().
3186         <https://webkit.org/b/130605>
3187
3188         Reviewed by Antti Koivisto.
3189
3190         * rendering/RenderView.cpp:
3191         * rendering/RenderView.h:
3192
3193 2014-03-21  David Hyatt  <hyatt@apple.com>
3194
3195         Crash in RenderBlock::addChildIgnoringAnonymousColumnBlocks.
3196         https://bugs.webkit.org/show_bug.cgi?id=129948
3197         <rdar://problem/16074072>
3198         
3199         Reviewed by Simon Fraser.
3200
3201         When the marker was placed for multi-column list items, it was being inserted
3202         into the list item itself. Even though the add code in RenderBlock did the right
3203         thing and put the marker inside the multi-column flow thread, the list item code
3204         passed in a beforeChild that was computed using the incorrect parent. This resulted
3205         in the flow thread being used both as the parent of the marker and the sibling of
3206         the marker.
3207         
3208         The fix is to add some code to RenderListItem to make sure it uses the multi-column
3209         flow thread if it exists both as the parent of the marker and as the basis for the
3210         computation of the sibling that the marker should be placed in front of.
3211
3212         Added fast/multicol/multicol-li-crash.html
3213
3214         * rendering/RenderListItem.cpp:
3215         (WebCore::RenderListItem::insertOrMoveMarkerRendererIfNeeded):
3216
3217 2014-03-20  Andreas Kling  <akling@apple.com>
3218
3219         Stop pulling in JSCInlines.h all over the place.
3220         <https://webkit.org/b/130105>
3221
3222         JSDOMBinding.h is included by everyone and their uncle, so try to
3223         cut down on the amount of JSC *Inlines.h it includes.
3224
3225         Reviewed by Geoff Garen.
3226
3227         * ForwardingHeaders/heap/SlotVisitorInlines.h: Added.
3228         * ForwardingHeaders/runtime/JSCJSValueInlines.h: Added.
3229         * ForwardingHeaders/runtime/JSCellInlines.h: Added.
3230         * ForwardingHeaders/runtime/StructureInlines.h: Added.
3231         * bindings/js/JSDOMBinding.h:
3232
3233 2014-03-21  David Kilzer  <ddkilzer@apple.com>
3234
3235         WindowFeatures.{x|y|width|height} are not initialized
3236         <http://webkit.org/b/130547>
3237         <rdar://problem/16383151>
3238
3239         Reviewed by Darin Adler.
3240
3241         Based on a Blink patch in CRBug 342591 by zhaoqin.
3242
3243         * page/WindowFeatures.cpp:
3244         (WebCore::WindowFeatures::WindowFeatures):
3245         - Initialize x, y, width, height in String constructor.
3246         - Move 'resizeable' variable to short-hand initialization since
3247           it is true in both cases.
3248         - Use String::isEmpty() instead of checking its length.
3249         * page/WindowFeatures.h:
3250         (WebCore::WindowFeatures::WindowFeatures): Initialize x, y,
3251         width, height in no-argument constructor.
3252
3253 2014-03-21  Sergio Villar Senin  <svillar@igalia.com>
3254
3255         Replace DEPRECATED_DEFINE_STATIC_LOCAL by static NeverDestroyed<T> in bridge/
3256         https://bugs.webkit.org/show_bug.cgi?id=130601
3257
3258         Reviewed by Darin Adler.
3259
3260         * bridge/IdentifierRep.cpp:
3261         (WebCore::identifierSet):
3262         (WebCore::intIdentifierMap):
3263         (WebCore::stringIdentifierMap):
3264         * bridge/NP_jsobject.cpp:
3265         (objectMap):
3266         * bridge/runtime_root.cpp:
3267         (JSC::Bindings::rootObjectSet): Return a reference instead of
3268         a pointer.
3269         (JSC::Bindings::findProtectingRootObject):
3270         (JSC::Bindings::findRootObject):
3271         (JSC::Bindings::RootObject::RootObject):
3272         (JSC::Bindings::RootObject::invalidate):
3273
3274 2014-03-21  Michael Saboff  <msaboff@apple.com>
3275
3276         Change CodeGeneratorJS.pm special cases for "DOMWindow" to be general purpose
3277         https://bugs.webkit.org/show_bug.cgi?id=130553
3278
3279         Reviewed by Geoffrey Garen.
3280
3281         Eliminated 'if ($interfaceName eq "DOMWindow") {' sections in CodeGeneratorJS where
3282         it was used to do DOMWindow specific casting to a JSObject, either a JSDOMWindow* or
3283         a JSDOMWindowShell*.  Instead the code generator will use the existing 
3284         JSDOMWindow* toJSDOMWindow(JSValue value) function based on a newly added attribute
3285         "CustomProxyToJSObject".  That attribute will emit a call to the function
3286         ${className}* to${className}(JSValue).
3287
3288         This is being done to clean up the code generator and for a subsequent patch that
3289         will use a similar custom to{className} function for workers,
3290         JSDedicatedWorkerGlobalScope* toJSDedicatedWorkerGlobalScope(JSValue).
3291
3292         Changes covered by existing tests.
3293
3294         * bindings/scripts/CodeGeneratorJS.pm:
3295         (GenerateImplementation):
3296         * bindings/scripts/IDLAttributes.txt:
3297         * page/DOMWindow.idl:
3298
3299 2014-03-21  Krzysztof Czech  <k.czech@samsung.com>
3300
3301         AX: Replace DEPRECATED_DEFINE_STATIC_LOCAL by static NeverDestroyed
3302         https://bugs.webkit.org/show_bug.cgi?id=130594
3303
3304         Reviewed by Chris Fleizach.
3305
3306         Use static NeverDestroyed<T> in new code.
3307
3308         * accessibility/AccessibilityMediaControls.cpp:
3309         (WebCore::AccessibilityMediaControl::controlTypeName):
3310         (WebCore::AccessibilityMediaControl::title):
3311         (WebCore::AccessibilityMediaControlsContainer::elementTypeName):
3312         (WebCore::AccessibilityMediaTimeline::helpText):
3313         (WebCore::AccessibilityMediaTimeDisplay::accessibilityDescription):
3314         * accessibility/AccessibilityObject.cpp:
3315         (WebCore::AccessibilityObject::actionVerb):
3316         * accessibility/AccessibilityRenderObject.cpp:
3317         (WebCore::AccessibilityRenderObject::inheritsPresentationalRole):
3318         (WebCore::AccessibilityRenderObject::ariaLiveRegionStatus):
3319         (WebCore::AccessibilityRenderObject::ariaLiveRegionRelevant):
3320         (WebCore::AccessibilityRenderObject::actionVerb):
3321         * accessibility/atk/AXObjectCacheAtk.cpp:
3322         (WebCore::notifyChildrenSelectionChange):
3323
3324 2014-03-20  Brent Fulgham  <bfulgham@apple.com>
3325
3326         Merge WebVTT Tokenizer Updates
3327         https://bugs.webkit.org/show_bug.cgi?id=130565
3328
3329         Reviewed by Eric Carlson.
3330
3331         Merged from Blink (patch by fs@opera.com):
3332         https://chromium.googlesource.com/chromium/blink/+/923db263aa65d6efd71c5b55708ad7eea6b23f53
3333         http://crbug.com/73813002
3334         https://chromium.googlesource.com/chromium/blink/+/48375b1d56b2d8850ae93a6c6fb01c69fae82c75
3335         http://crbug.com/77553004
3336         https://chromium.googlesource.com/chromium/blink/+/98d4fc4f5cb716a31d11907120b10538d4ba0f09
3337         http://crbug.com/78833002
3338         https://chromium.googlesource.com/chromium/blink/+/0e53d4f9f140e979b7f32de495551684bc7f4cd2
3339         http://crbug.com/81113003
3340         https://chromium.googlesource.com/chromium/blink/+/730ef1e7f9a1919964f7e74e7ccb2f343e10a148
3341         http://crbug.com/97103002
3342         https://chromium.googlesource.com/chromium/blink/+/c373ee914ffabeaf833939129538251d8f2f4eca
3343         http://crbug.com/98763004
3344         https://chromium.googlesource.com/chromium/blink/+/4ddb4d57948228fa05e49e06bd58a1179c09f212
3345         http://crbug.com/118263002
3346  
3347         * html/track/VTTCue.cpp:
3348         (WebCore::scanPercentage):
3349         (WebCore::VTTCue::setCueSettings):
3350         * html/track/WebVTTParser.cpp:
3351         (WebCore::WebVTTTreeBuilder::buildFromString):
3352         (WebCore::WebVTTTreeBuilder::constructTreeFromToken):
3353         * html/track/WebVTTToken.h:
3354         (WebCore::WebVTTToken::WebVTTToken):
3355         (WebCore::WebVTTToken::StringToken):
3356         (WebCore::WebVTTToken::StartTag):
3357         (WebCore::WebVTTToken::EndTag):
3358         (WebCore::WebVTTToken::TimestampTag):
3359         (WebCore::WebVTTToken::type):
3360         (WebCore::WebVTTToken::name):
3361         (WebCore::WebVTTToken::characters):
3362         (WebCore::WebVTTToken::classes):
3363         (WebCore::WebVTTToken::annotation):
3364         * html/track/WebVTTTokenizer.cpp:
3365         (WebCore::addNewClass):
3366         (WebCore::emitToken):
3367         (WebCore::advanceAndEmitToken):
3368         (WebCore::WebVTTTokenizer::WebVTTTokenizer):
3369         (WebCore::WebVTTTokenizer::nextToken):
3370         * html/track/WebVTTTokenizer.h:
3371         (WebCore::WebVTTTokenizer::shouldSkipNullCharacters):
3372
3373 2014-03-21  Frédéric Wang  <fred.wang@free.fr>
3374
3375         Bug 130345 - Refine childShouldCreateRenderer for MathML elements
3376         https://bugs.webkit.org/show_bug.cgi?id=130345
3377
3378         Reviewed by Chris Fleizach.
3379
3380         This is a follow-up of bug 124128. We add more restrictions on foreign
3381         content of MathML elements.
3382
3383         Tests: mathml/presentation/annotation-children.html
3384                mathml/presentation/foreign-element-in-token.html
3385
3386         * mathml/MathMLElement.cpp:
3387         (WebCore::MathMLElement::isPresentationMathML): fix line wrapping
3388         (WebCore::MathMLElement::isPhrasingContent):
3389         - move the function from MathMLSelectElement.cpp
3390         - add the constraint "is descendant of a map element" for area.
3391         (WebCore::MathMLElement::isFlowContent): new function to test flow content.
3392         (WebCore::MathMLElement::childShouldCreateRenderer):
3393         - remove annotation since it is now tested in MathMLTextElement
3394         - refine testing of annotation-xml
3395         - do not create renderer for text content in MathML. Such content is only allowed inside token elements.
3396         * mathml/MathMLElement.h: Declare isPhrasingContent and isFlowContent.
3397         * mathml/MathMLSelectElement.cpp: Add new function to test MathML/SVG/HTML encodings.
3398         (WebCore::MathMLSelectElement::isMathMLEncoding):
3399         (WebCore::MathMLSelectElement::isSVGEncoding):
3400         (WebCore::MathMLSelectElement::isHTMLEncoding):
3401         (WebCore::MathMLSelectElement::getSelectedSemanticsChild): use the new functions.
3402         * mathml/MathMLSelectElement.h: Declare the new public functions.
3403         * mathml/MathMLTextElement.cpp: remove the isPhrasingContent function.
3404         (WebCore::MathMLTextElement::childShouldCreateRenderer): Just in case, use the generic StyledElement::childShouldCreateRenderer.
3405
3406 2014-03-21  Darin Adler  <darin@apple.com>
3407
3408         Stop using deprecatedCharacters in WebCore/platform/win
3409         https://bugs.webkit.org/show_bug.cgi?id=130515
3410
3411         Reviewed by Brent Fulgham.
3412
3413         * platform/graphics/TextRun.h:
3414         (WebCore::TextRun::TextRun): Add a constructor that takes a StringView.
3415         Later, we might want to exclusively use the StringView version and remove
3416         some of the others.
3417         (WebCore::TextRun::setText): Add a version of this function that takes a StringView.
3418
3419         * platform/graphics/win/FontCacheWin.cpp:
3420         (WebCore::FontCache::systemFallbackForCharacters): Use StringView::getCharactersWithUpconvert.
3421         (WebCore::createGDIFont): Ditto.
3422         (WebCore::FontCache::getTraitsInFamily): Ditto.
3423         * platform/win/BString.cpp:
3424         (WebCore::BString::BString): Use StringView::upconvertedCharacters.
3425         * platform/win/ClipboardUtilitiesWin.cpp:
3426         (WebCore::createGlobalData): Use StringView::getCharactersWithUpconvert.
3427         * platform/win/FileSystemWin.cpp:
3428         (WebCore::pathByAppendingComponent): Use StringBuilder and StringView::getCharactersWithUpconvert.
3429         (WebCore::fileSystemRepresentation): Use StringView::upconvertedCharacters.
3430         * platform/win/PasteboardWin.cpp:
3431         (WebCore::filesystemPathFromUrlOrTitle): Use StringView::getCharactersWithUpconvert.
3432         (WebCore::Pasteboard::writeURLToDataObject): Ditto.
3433         (WebCore::createGlobalImageFileDescriptor): Ditto.
3434
3435         * platform/win/PopupMenuWin.cpp:
3436         (WebCore::PopupMenuWin::calculatePositionAndSize): Use the new TextRun constructor.
3437         * platform/win/WebCoreTextRenderer.cpp:
3438         (WebCore::doDrawTextAtPoint): Ditto.
3439
3440 2014-03-21  Zalan Bujtas  <zalan@apple.com>
3441
3442         Subpixel rendering: RenderBox is positioned off by one when non-compositing transform is present.
3443         https://bugs.webkit.org/show_bug.cgi?id=130430
3444
3445         Reviewed by Simon Fraser.
3446
3447         div {
3448             position: absolute;
3449              top: 10.25px;
3450              left: 10.25px;
3451          }
3452
3453          The <div> with (10.25px, 10.25px) is painted to (10.5px, 10.5px) after device pixel snapping on 2x display.
3454          Moving <div> to its own RenderLayer should not change the painting position.
3455
3456          div {
3457              position: absolute;
3458              top: 10.25px;
3459              left: 10.25px;
3460              -webkit-transform: rotate(0deg);
3461          }
3462
3463         When we paint the RenderLayer's content, the graphics context is translated by the rounded value of
3464         renderer's offset from parent.
3465
3466             (10.25px,10.25px) -> rounded to (10.5px,10.5px).
3467
3468         When the translate moves the graphics context's origin over the renderer's top-left position,
3469         the renderer's relative top-left coordinates end up being negative.
3470
3471             Graphics context translated by (10.5px,10.5px) -> pushes renderer's relative top-left coords to (-0.25px,-0.25px)
3472
3473         When we round (pixel snap) these negative coordinates, half-way values get translated to the wrong direction.
3474
3475         (relative coords (-0.25px,-0.25px) -> pixel snapped to (-0.5px,-0.5px) -> final absolute(painting) coords (10px,10px))
3476
3477         This patch changes the rounding to flooring to ensure that the relative top-left position never gets negative as the result
3478         of subpixel shifting.
3479
3480         Tests: compositing/hidpi-box-positioned-off-by-one