Another attempted build fix.
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2014-01-24  Anders Carlsson  <andersca@apple.com>
2
3         Another attempted build fix.
4
5         Use wildcards in the the std::duration symbol.
6
7         * WebCore.exp.in:
8
9 2014-01-24  Simon Fraser  <simon.fraser@apple.com>
10
11         Start using the RemoteScrollingCoordinatorProxy on iOS
12         https://bugs.webkit.org/show_bug.cgi?id=127598
13
14         Reviewed by Tim Horton.
15
16         Add a scrollPositionChangedViaDelegatedScrolling() function to
17         ScrollingTree, allowing the ScrollingTree to be informed about
18         external sources of scrolling.
19         
20         Also add a convenience getter for nodes, nodeForID().
21
22         * WebCore.exp.in:
23         * page/scrolling/ScrollingTree.cpp:
24         (WebCore::ScrollingTree::scrollPositionChangedViaDelegatedScrolling):
25         (WebCore::ScrollingTree::nodeForID):
26         * page/scrolling/ScrollingTree.h:
27         * rendering/RenderLayerCompositor.cpp:
28         (WebCore::RenderLayerCompositor::registerAllViewportConstrainedLayers):
29         To avoid assertions on iOS, bail from iOS WK1 fixed position code if
30         we have a ScrollingCoordinator.
31         (WebCore::RenderLayerCompositor::unregisterAllViewportConstrainedLayers):
32         Ditto.
33
34 2014-01-24  Simon Fraser  <simon.fraser@apple.com>
35
36         Add typesafe casts for ScrollingTreeNode classes
37         https://bugs.webkit.org/show_bug.cgi?id=127597
38
39         Reviewed by Tim Horton.
40
41         Add a ScrollingNodeType member to ScrollingTreeNodes and
42         use it for type-safe casting.
43
44         * page/scrolling/ScrollingTreeNode.cpp:
45         (WebCore::ScrollingTreeNode::ScrollingTreeNode):
46         * page/scrolling/ScrollingTreeNode.h:
47         (WebCore::ScrollingTreeNode::nodeType):
48         (WebCore::ScrollingTreeNode::scrollingNodeID):
49         * page/scrolling/ScrollingTreeScrollingNode.cpp:
50         (WebCore::ScrollingTreeScrollingNode::ScrollingTreeScrollingNode):
51         * page/scrolling/ScrollingTreeScrollingNode.h:
52         * page/scrolling/mac/ScrollingTreeFixedNode.h:
53         * page/scrolling/mac/ScrollingTreeFixedNode.mm:
54         (WebCore::ScrollingTreeFixedNode::ScrollingTreeFixedNode):
55         * page/scrolling/mac/ScrollingTreeStickyNode.h:
56         * page/scrolling/mac/ScrollingTreeStickyNode.mm:
57         (WebCore::ScrollingTreeStickyNode::ScrollingTreeStickyNode):
58
59 2014-01-24  Anders Carlsson  <andersca@apple.com>
60
61         Remove back/forward list related functions from Page
62         https://bugs.webkit.org/show_bug.cgi?id=127596
63
64         Reviewed by Andreas Kling.
65
66         * WebCore.exp.in:
67         * history/BackForwardController.cpp:
68         (WebCore::BackForwardController::canGoBackOrForward):
69         (WebCore::BackForwardController::goBackOrForward):
70         (WebCore::BackForwardController::goBack):
71         (WebCore::BackForwardController::goForward):
72         (WebCore::BackForwardController::count):
73         * page/EventHandler.cpp:
74         (WebCore::EventHandler::defaultBackspaceEventHandler):
75         * page/Page.cpp:
76         * page/Page.h:
77
78 2014-01-24  Antti Koivisto  <antti@apple.com>
79
80         Update style asynchronously after style sheet load
81         https://bugs.webkit.org/show_bug.cgi?id=127563
82
83         Reviewed by Andreas Kling.
84         
85         Since we don't attach synchronously we don't need to recalc style synchronously either.
86
87         * dom/Document.cpp:
88         (WebCore::Document::didRemoveAllPendingStylesheet):
89
90 2014-01-24  Zalan Bujtas  <zalan@apple.com>
91
92         Subpixel layout: Default style of input type=checkbox/radio (0.5ex) adds 1px extra margin on both left and right.
93         https://bugs.webkit.org/show_bug.cgi?id=125728
94
95         Reviewed by Simon Fraser.
96
97         Using the 0.5ex value to set checkbox/radio left and right margins is a long-standing
98         (khtml) behavior. While it indicates dynamic behavior, in order to get the margins changed,
99         the widget's font size needs to be set, which is rather rare for such input types.
100         It also results in odd layout, where the checkbox's indentation may seem to change randomly.
101
102         '<input style="font-size: 30px;" type="checkbox">foo' changes neither the checkbox
103         nor the text size, but it indents the line by about 15px.
104
105         Other browsers (FF, Opera with Presto) disagree and they set static margins values.
106         2px is the current default computed value.
107
108         * css/html.css:
109         (input[type="radio"], input[type="checkbox"]):
110
111 2014-01-24  Oliver Hunt  <oliver@apple.com>
112
113         Put functions need to take a base object and a this value, and perform type checks on |this|
114         https://bugs.webkit.org/show_bug.cgi?id=127594
115
116         Reviewed by Geoffrey Garen.
117
118         Update bindings generator to emit setters with correct type, and perform
119         type checks on |this|, instead of the baseObject.
120
121         Test: js/dom/dom-as-prototype-assignment-exception.html
122
123         * bindings/scripts/CodeGeneratorJS.pm:
124         (GenerateHeader):
125         (GenerateImplementation):
126         (GenerateHashTable):
127         * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
128         * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
129         * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
130         * bindings/scripts/test/JS/JSTestEventTarget.cpp:
131         * bindings/scripts/test/JS/JSTestException.cpp:
132         * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
133         * bindings/scripts/test/JS/JSTestInterface.cpp:
134         (WebCore::setJSTestInterfaceConstructorImplementsStaticAttr):
135         (WebCore::setJSTestInterfaceImplementsStr2):
136         (WebCore::setJSTestInterfaceImplementsStr3):
137         (WebCore::setJSTestInterfaceImplementsNode):
138         (WebCore::setJSTestInterfaceConstructorSupplementalStaticAttr):
139         (WebCore::setJSTestInterfaceSupplementalStr2):
140         (WebCore::setJSTestInterfaceSupplementalStr3):
141         (WebCore::setJSTestInterfaceSupplementalNode):
142         * bindings/scripts/test/JS/JSTestInterface.h:
143         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
144         * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
145         * bindings/scripts/test/JS/JSTestNode.cpp:
146         * bindings/scripts/test/JS/JSTestObj.cpp:
147         (WebCore::setJSTestObjConstructorStaticStringAttr):
148         (WebCore::setJSTestObjTestSubObjEnabledBySettingConstructor):
149         (WebCore::setJSTestObjEnumAttr):
150         (WebCore::setJSTestObjByteAttr):
151         (WebCore::setJSTestObjOctetAttr):
152         (WebCore::setJSTestObjShortAttr):
153         (WebCore::setJSTestObjUnsignedShortAttr):
154         (WebCore::setJSTestObjLongAttr):
155         (WebCore::setJSTestObjLongLongAttr):
156         (WebCore::setJSTestObjUnsignedLongLongAttr):
157         (WebCore::setJSTestObjStringAttr):
158         (WebCore::setJSTestObjTestObjAttr):
159         (WebCore::setJSTestObjXMLObjAttr):
160         (WebCore::setJSTestObjCreate):
161         (WebCore::setJSTestObjReflectedStringAttr):
162         (WebCore::setJSTestObjReflectedIntegralAttr):
163         (WebCore::setJSTestObjReflectedUnsignedIntegralAttr):
164         (WebCore::setJSTestObjReflectedBooleanAttr):
165         (WebCore::setJSTestObjReflectedURLAttr):
166         (WebCore::setJSTestObjReflectedCustomIntegralAttr):
167         (WebCore::setJSTestObjReflectedCustomBooleanAttr):
168         (WebCore::setJSTestObjReflectedCustomURLAttr):
169         (WebCore::setJSTestObjTypedArrayAttr):
170         (WebCore::setJSTestObjAttrWithGetterException):
171         (WebCore::setJSTestObjAttrWithSetterException):
172         (WebCore::setJSTestObjStringAttrWithGetterException):
173         (WebCore::setJSTestObjStringAttrWithSetterException):
174         (WebCore::setJSTestObjCustomAttr):
175         (WebCore::setJSTestObjWithScriptStateAttribute):
176         (WebCore::setJSTestObjWithScriptExecutionContextAttribute):
177         (WebCore::setJSTestObjWithScriptStateAttributeRaises):
178         (WebCore::setJSTestObjWithScriptExecutionContextAttributeRaises):
179         (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateAttribute):
180         (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
181         (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateWithSpacesAttribute):
182         (WebCore::setJSTestObjWithScriptArgumentsAndCallStackAttribute):
183         (WebCore::setJSTestObjConditionalAttr1):
184         (WebCore::setJSTestObjConditionalAttr2):
185         (WebCore::setJSTestObjConditionalAttr3):
186         (WebCore::setJSTestObjConditionalAttr4Constructor):
187         (WebCore::setJSTestObjConditionalAttr5Constructor):
188         (WebCore::setJSTestObjConditionalAttr6Constructor):
189         (WebCore::setJSTestObjAnyAttribute):
190         (WebCore::setJSTestObjMutablePoint):
191         (WebCore::setJSTestObjImmutablePoint):
192         (WebCore::setJSTestObjStrawberry):
193         (WebCore::setJSTestObjStrictFloat):
194         (WebCore::setJSTestObjId):
195         (WebCore::setJSTestObjReplaceableAttribute):
196         (WebCore::setJSTestObjNullableLongSettableAttribute):
197         (WebCore::setJSTestObjNullableStringValue):
198         (WebCore::setJSTestObjAttributeWithReservedEnumType):
199         * bindings/scripts/test/JS/JSTestObj.h:
200         * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
201         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
202         (WebCore::setJSTestSerializedScriptValueInterfaceValue):
203         (WebCore::setJSTestSerializedScriptValueInterfaceCachedValue):
204         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
205         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
206         (WebCore::setJSTestTypedefsUnsignedLongLongAttr):
207         (WebCore::setJSTestTypedefsImmutableSerializedScriptValue):
208         (WebCore::setJSTestTypedefsAttrWithGetterException):
209         (WebCore::setJSTestTypedefsAttrWithSetterException):
210         (WebCore::setJSTestTypedefsStringAttrWithGetterException):
211         (WebCore::setJSTestTypedefsStringAttrWithSetterException):
212         * bindings/scripts/test/JS/JSTestTypedefs.h:
213         * bindings/scripts/test/JS/JSattribute.cpp:
214         * bindings/scripts/test/JS/JSreadonly.cpp:
215
216 2014-01-24  Oliver Hunt  <oliver@apple.com>
217
218         Generic JSObject::put should handle static properties in the classinfo hierarchy
219         https://bugs.webkit.org/show_bug.cgi?id=127523
220
221         Reviewed by Geoffrey Garen.
222
223         Update the bindings generator to emit the flag indicating the presence
224         of setters, and remove the many (now unnecessary) put overrides.
225         Tested with run-jsc-benchmarks and shows neutral performance. A few of the
226         micro benchmarks actually get a significant performance increase which
227         is nice.
228
229         * bindings/js/JSDOMWindowCustom.cpp:
230         (WebCore::JSDOMWindow::put):
231             We still need a custom call to lookupPut here in order
232             to get the magic security semantics of the window object.
233         * bindings/scripts/CodeGeneratorJS.pm:
234         (hashTableAccessor):
235         (prototypeHashTableAccessor):
236         (constructorHashTableAccessor):
237         (GenerateImplementation):
238         (GenerateHashTable):
239         (GenerateConstructorHelperMethods):
240
241         * bindings/js/JSDOMWindowCustom.cpp:
242         (WebCore::JSDOMWindow::put):
243         * bindings/scripts/CodeGeneratorJS.pm:
244         (hashTableAccessor):
245         (prototypeHashTableAccessor):
246         (constructorHashTableAccessor):
247         (InstanceOverridesPutImplementation):
248         (InstanceOverridesPutDeclaration):
249         (GenerateHeader):
250         (GenerateImplementation):
251         (GenerateHashTable):
252         (GenerateConstructorHelperMethods):
253         * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
254         * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
255         * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
256         * bindings/scripts/test/JS/JSTestEventTarget.cpp:
257         * bindings/scripts/test/JS/JSTestException.cpp:
258         * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
259         * bindings/scripts/test/JS/JSTestInterface.cpp:
260         (WebCore::JSTestInterface::put):
261         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
262         * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
263         * bindings/scripts/test/JS/JSTestNode.cpp:
264         * bindings/scripts/test/JS/JSTestObj.cpp:
265         * bindings/scripts/test/JS/JSTestObj.h:
266         * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
267         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
268         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
269         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
270         * bindings/scripts/test/JS/JSTestTypedefs.h:
271         * bindings/scripts/test/JS/JSattribute.cpp:
272         * bindings/scripts/test/JS/JSreadonly.cpp:
273         * html/canvas/WebGLRenderingContext.idl:
274           Remove bogus attribute, as it has never been in the spec and should not
275           have been added.
276
277 2014-01-24  Commit Queue  <commit-queue@webkit.org>
278
279         Unreviewed, rolling out r162713.
280         http://trac.webkit.org/changeset/162713
281         https://bugs.webkit.org/show_bug.cgi?id=127593
282
283         broke media/network-no-source-const-shadow (Requested by
284         thorton on #webkit).
285
286         * bindings/js/JSDOMWindowCustom.cpp:
287         (WebCore::JSDOMWindow::put):
288         * bindings/scripts/CodeGeneratorJS.pm:
289         (hashTableAccessor):
290         (prototypeHashTableAccessor):
291         (constructorHashTableAccessor):
292         (GenerateHeader):
293         (GenerateImplementation):
294         (GenerateHashTable):
295         (GenerateConstructorHelperMethods):
296         * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
297         * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
298         * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
299         * bindings/scripts/test/JS/JSTestEventTarget.cpp:
300         * bindings/scripts/test/JS/JSTestException.cpp:
301         * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
302         * bindings/scripts/test/JS/JSTestInterface.cpp:
303         (WebCore::JSTestInterface::put):
304         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
305         * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
306         * bindings/scripts/test/JS/JSTestNode.cpp:
307         * bindings/scripts/test/JS/JSTestObj.cpp:
308         (WebCore::JSTestObj::put):
309         * bindings/scripts/test/JS/JSTestObj.h:
310         * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
311         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
312         (WebCore::JSTestSerializedScriptValueInterface::put):
313         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
314         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
315         (WebCore::JSTestTypedefs::put):
316         * bindings/scripts/test/JS/JSTestTypedefs.h:
317         * bindings/scripts/test/JS/JSattribute.cpp:
318         * bindings/scripts/test/JS/JSreadonly.cpp:
319         * html/canvas/WebGLRenderingContext.idl:
320
321 2014-01-24  Zalan Bujtas  <zalan@apple.com>
322
323         Replace LayoutUnit() calls to a more descriptive LayoutUnit::fromPixel(int).
324         https://bugs.webkit.org/show_bug.cgi?id=127580
325
326         Reviewed by Simon Fraser.
327
328         LayoutUnit(1) statement is ambiguous. While it is intended to set one (CSS) pixel, it
329         could be interpreted as 1 layout unit (1/64th of a CSS pixel atm).
330
331         No change in behavior.
332
333         * inspector/InspectorOverlay.cpp:
334         (WebCore::buildObjectForRegionHighlight):
335         * rendering/FloatingObjects.cpp:
336         (WebCore::ComputeFloatOffsetForFloatLayoutAdapter<FloatTypeValue>::heightRemaining):
337         * rendering/RenderBlock.cpp:
338         (WebCore::RenderBlock::layoutShapeInsideInfo):
339         * rendering/RenderBlockFlow.cpp:
340         (WebCore::RenderBlockFlow::collapseMargins):
341         * rendering/RenderFlexibleBox.cpp:
342         (WebCore::RenderFlexibleBox::mainAxisContentExtent):
343         (WebCore::RenderFlexibleBox::preferredMainAxisContentExtentForChild):
344         (WebCore::RenderFlexibleBox::alignChildren):
345         * rendering/RenderMultiColumnFlowThread.cpp:
346         (WebCore::RenderMultiColumnFlowThread::addForcedRegionBreak):
347         * rendering/RenderMultiColumnSet.cpp:
348         (WebCore::RenderMultiColumnSet::heightAdjustedForSetOffset):
349         (WebCore::RenderMultiColumnSet::calculateBalancedHeight):
350
351 2014-01-24  Simon Fraser  <simon.fraser@apple.com>
352
353         Prepare scrolling tree to handle > 1 scrolling node
354         https://bugs.webkit.org/show_bug.cgi?id=127590
355
356         Reviewed by Tim Horton.
357
358         Clean up the code path called after the ScrollingTree has scrolled a node,
359         to prepare for multiple scrolling nodes.
360         
361         Change "updateMainFrameScrollPosition" terminology to "updateScrollPositionAfterAsyncScroll",
362         and pass along the ScrollingNodeID that scrolled.
363         
364         Move updateMainFrameScrollPosition-related code from ScrollingCoordinator to
365         AsyncScrollingCoordinator, since this sync-up is only necessary when doing
366         async scrolling.
367
368         * WebCore.exp.in:
369         * page/scrolling/AsyncScrollingCoordinator.cpp:
370         (WebCore::AsyncScrollingCoordinator::AsyncScrollingCoordinator):
371         (WebCore::AsyncScrollingCoordinator::requestScrollPositionUpdate):
372         (WebCore::AsyncScrollingCoordinator::scheduleUpdateScrollPositionAfterAsyncScroll):
373         (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScrollTimerFired):
374         (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll):
375         * page/scrolling/AsyncScrollingCoordinator.h:
376         (WebCore::AsyncScrollingCoordinator::ScheduledScrollUpdate::ScheduledScrollUpdate):
377         (WebCore::AsyncScrollingCoordinator::ScheduledScrollUpdate::matchesUpdateType):
378         Package up the data related to a scheduled scroll into a ScheduledScrollUpdate struct,
379         for easier comparison and cleaner code.
380         * page/scrolling/ScrollingCoordinator.cpp:
381         (WebCore::ScrollingCoordinator::ScrollingCoordinator):
382         * page/scrolling/ScrollingCoordinator.h:
383         * page/scrolling/ScrollingTree.h:
384         * page/scrolling/ThreadedScrollingTree.cpp:
385         (WebCore::ThreadedScrollingTree::scrollingTreeNodeDidScroll):
386         * page/scrolling/ThreadedScrollingTree.h:
387         * page/scrolling/ios/ScrollingTreeIOS.cpp:
388         (WebCore::ScrollingTreeIOS::scrollingTreeNodeDidScroll):
389         * page/scrolling/ios/ScrollingTreeIOS.h:
390         * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.mm:
391         (WebCore::ScrollingTreeScrollingNodeIOS::setScrollPositionWithoutContentEdgeConstraints):
392         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
393         (WebCore::ScrollingTreeScrollingNodeMac::setScrollPositionWithoutContentEdgeConstraints):
394
395 2014-01-24  Mark Lam  <mark.lam@apple.com>
396
397         ASSERT(!m_markedSpace.m_currentDelayedReleaseScope) reloading page in inspector.
398         <https://webkit.org/b/127582>
399
400         Reviewed by Mark Hahnenberg.
401
402         No new tests.
403
404         * bindings/js/ScriptController.cpp:
405         (WebCore::ScriptController::attachDebugger):
406         * bindings/js/WorkerScriptController.cpp:
407         (WebCore::WorkerScriptController::detachDebugger):
408         - Adding reasons for detaching a globalObject from the debugger.
409
410 2014-01-24  Zalan Bujtas  <zalan@apple.com>
411
412         Subpixel rendering: Make PaintInfo layout unit aware.
413         https://bugs.webkit.org/show_bug.cgi?id=127562
414
415         Reviewed by Simon Fraser.
416
417         Replace PaintInfo's IntRect with LayoutRect to be able to render to
418         subpixel positions.
419
420         No functional changes.
421
422         * platform/graphics/LayoutRect.h:
423         * rendering/PaintInfo.h:
424         (WebCore::PaintInfo::PaintInfo):
425         (WebCore::PaintInfo::applyTransform):
426         * rendering/RenderBlock.cpp:
427         (WebCore::RenderBlock::paint):
428         * rendering/RenderBoxModelObject.cpp:
429         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
430         * rendering/RenderLayer.cpp:
431         (WebCore::cornerRect):
432         (WebCore::RenderLayer::scrollCornerRect):
433         (WebCore::resizerCornerRect):
434         (WebCore::RenderLayer::scrollCornerAndResizerRect):
435         (WebCore::RenderLayer::horizontalScrollbarStart):
436         (WebCore::RenderLayer::drawPlatformResizerImage):
437         (WebCore::RenderLayer::paintResizer):
438         (WebCore::RenderLayer::hitTestOverflowControls):
439         * rendering/RenderLayer.h:
440         * rendering/RenderLayerBacking.cpp:
441         (WebCore::RenderLayerBacking::paintContents):
442         * rendering/RenderListBox.cpp:
443         (WebCore::RenderListBox::paintScrollbar):
444         * rendering/RenderWidget.cpp:
445         (WebCore::RenderWidget::paintContents):
446         * rendering/mathml/RenderMathMLOperator.cpp:
447         (WebCore::RenderMathMLOperator::fillWithExtensionGlyph):
448         * rendering/svg/SVGRenderingContext.h:
449
450 2014-01-24  Simon Fraser  <simon.fraser@apple.com>
451
452         #ifdef out handleWheelEventPhase for iOS
453         https://bugs.webkit.org/show_bug.cgi?id=127583
454
455         Reviewed by Tim Horton.
456
457         handleWheelEventPhase() doesn't make any sense for iOS, which
458         has no wheel events.
459
460         * page/scrolling/ScrollingTree.h:
461         * page/scrolling/ThreadedScrollingTree.cpp:
462         * page/scrolling/ThreadedScrollingTree.h:
463         * page/scrolling/ios/ScrollingTreeIOS.h:
464
465 2014-01-24  David Hyatt  <hyatt@apple.com>
466
467         [New Multicolumn] Don't destroy all the renderers when a multi-column block stops being multi-column (and vice versa)
468         https://bugs.webkit.org/show_bug.cgi?id=127584
469
470         Make the logic for when you need columns and when you don't shared between the
471         old multi-column code and the new multi-column code. Make sure that the flow thread
472         and sets get created lazily and destroyed on-demand when whether or not we should
473         have multiple columns changes.
474
475         Reviewed by Beth Dakin.
476
477         * rendering/RenderBlock.cpp:
478         (WebCore::RenderBlock::updateLogicalWidthAndColumnWidth):
479         No longer virtual. The new column code now uses this function too.
480
481         (WebCore::RenderBlock::availableLogicalWidth):
482         Renamed desiredColumnWidth() to computedColumnWidth().
483
484         (WebCore::RenderBlock::computeColumnCountAndWidth):
485         Renamed calcColumnWidth to computeColumnCountAndWidth.
486
487         (WebCore::RenderBlock::setComputedColumnCountAndWidth):
488         Rename setDesiredColumnCountAndWidth to computed.
489
490         (WebCore::RenderBlock::computedColumnWidth):
491         (WebCore::RenderBlock::computedColumnCount):
492         Renamed desiredColumnWidth/Count to computedColumnWidth/Count and made them virtual.
493
494         (WebCore::RenderBlock::updateFirstLetterStyle):
495         desired -> computed rename.
496
497         * rendering/RenderBlock.h:
498         Renames and made a few functions virtual so that RenderBlockFlow can override.
499
500         * rendering/RenderBlockFlow.cpp:
501         (WebCore::RenderBlockFlow::RenderBlockFlow):
502         Don't create the flow thread at construction time any longer.
503
504         (WebCore::RenderBlockFlow::createMultiColumnFlowThread):
505         (WebCore::RenderBlockFlow::destroyMultiColumnFlowThread):
506         The methods to create and destroy flow threads. These work at any time now and will
507         fix up the render tree accordingly.
508
509         (WebCore::RenderBlockFlow::setComputedColumnCountAndWidth):
510         Virtual override that creates/destroys the new multi-column information as needed.
511
512         (WebCore::RenderBlockFlow::computedColumnWidth):
513         (WebCore::RenderBlockFlow::computedColumnCount):
514         Overrides to return the cached column width and count from the flow thread.
515
516         * rendering/RenderBlockFlow.h:
517         Has overrides of the virtual functions needed to turn multi-column state on/off and
518         to hand back computed count/width information.
519
520         * rendering/RenderMultiColumnFlowThread.cpp:
521         * rendering/RenderMultiColumnFlowThread.h:
522         Removed the algorithm to compute column count and width, since this has been combined
523         with the old multi-column layout code.
524
525         * rendering/RenderView.cpp:
526         (WebCore::RenderView::computeColumnCountAndWidth):
527         Renamed desired -> computed.
528
529         * rendering/RenderView.h:
530         Renamed desired -> computed.
531
532         * style/StyleResolveTree.cpp:
533         (WebCore::Style::determineChange):
534         (WebCore::Style::resolveLocal):
535         (WebCore::Style::resolveTree):
536         * style/StyleResolveTree.h:
537         The Settings argument is no longer needed now that we don't destroy and re-create
538         the renderer for a block flow if it stops being (or becomes) multi-column.
539
540 2014-01-24  Anders Carlsson  <andersca@apple.com>
541
542         Fix 32-bit build.
543
544         * WebCore.exp.in:
545
546 2014-01-24  Brent Fulgham  <bfulgham@apple.com>
547
548         [Win] Convert some NMake files to MSBuild project files
549         https://bugs.webkit.org/show_bug.cgi?id=127579
550
551         Reviewed by Tim Horton.
552
553         * WebCore.vcxproj/WebCore.make: Removed.
554         * WebCore.vcxproj/WebCore.proj: Added.
555
556 2014-01-24  Joseph Pecoraro  <pecoraro@apple.com>
557
558         fast/profiler tests ASSERTing after moving recompileAllJSFunctions off a timer
559         https://bugs.webkit.org/show_bug.cgi?id=127566
560
561         Reviewed by Oliver Hunt.
562
563         Covered by existing tests.
564
565         * testing/Internals.cpp:
566         (WebCore::Internals::closeDummyInspectorFrontend):
567         Now that we don't have to fake that this is a page being destroyed to
568         avoid recompilation. Use the InspectorDestroyed reason.
569
570 2014-01-24  Anders Carlsson  <andersca@apple.com>
571
572         Get rid of monotonicallyIncreasingTimeMS and start using std::chrono instead
573         https://bugs.webkit.org/show_bug.cgi?id=127571
574
575         Reviewed by Antti Koivisto.
576
577         WebCore.exp.in:
578         Update symbols.
579
580         * dom/Document.cpp:
581         (WebCore::Document::Document):
582         (WebCore::Document::implicitClose):
583         (WebCore::Document::setParsing):
584         (WebCore::Document::isLayoutTimerActive):
585         (WebCore::Document::minimumLayoutDelay):
586         (WebCore::Document::elapsedTime):
587         (WebCore::Document::write):
588         (WebCore::Document::styleResolverChanged):
589         * dom/Document.h:
590         Use std::chrono instead of doubles for the times and durations.
591
592         * fileapi/FileReader.cpp:
593         (WebCore::FileReader::FileReader):
594         (WebCore::FileReader::didReceiveData):
595         * fileapi/FileReader.h:
596         Switch over to std::chrono.
597
598         * page/FrameView.cpp:
599         (WebCore::FrameView::layout):
600         (WebCore::FrameView::layoutTimerFired):
601         (WebCore::FrameView::scheduleRelayout):
602         (WebCore::FrameView::scheduleRelayoutOfSubtree):
603         Update for Document::elapsedTime() changes.
604
605         * page/Settings.cpp:
606         (WebCore::Settings::setLayoutInterval):
607         * page/Settings.h:
608         (WebCore::Settings::layoutInterval):
609         Change layoutInterval to be std::chrono::milliseconds instead of int.
610
611         * platform/Timer.h:
612         (WebCore::TimerBase::startOneShot):
613         Add an overload that takes std::chrono::milliseconds.
614
615 2014-01-24  Oliver Hunt  <oliver@apple.com>
616
617         Generic JSObject::put should handle static properties in the classinfo hierarchy
618         https://bugs.webkit.org/show_bug.cgi?id=127523
619
620         Reviewed by Geoffrey Garen.
621
622         Update the bindings generator to emit the flag indicating the presence
623         of setters, and remove the many (now unnecessary) put overrides.
624         Tested with run-jsc-benchmarks and shows neutral performance. A few of the
625         micro benchmarks actually get a significant performance increase which
626         is nice.
627
628         * bindings/js/JSDOMWindowCustom.cpp:
629         (WebCore::JSDOMWindow::put):
630             We still need a custom call to lookupPut here in order
631             to get the magic security semantics of the window object.
632         * bindings/scripts/CodeGeneratorJS.pm:
633         (hashTableAccessor):
634         (prototypeHashTableAccessor):
635         (constructorHashTableAccessor):
636         (GenerateImplementation):
637         (GenerateHashTable):
638         (GenerateConstructorHelperMethods):
639
640         * bindings/js/JSDOMWindowCustom.cpp:
641         (WebCore::JSDOMWindow::put):
642         * bindings/scripts/CodeGeneratorJS.pm:
643         (hashTableAccessor):
644         (prototypeHashTableAccessor):
645         (constructorHashTableAccessor):
646         (InstanceOverridesPutImplementation):
647         (InstanceOverridesPutDeclaration):
648         (GenerateHeader):
649         (GenerateImplementation):
650         (GenerateHashTable):
651         (GenerateConstructorHelperMethods):
652         * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
653         * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
654         * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
655         * bindings/scripts/test/JS/JSTestEventTarget.cpp:
656         * bindings/scripts/test/JS/JSTestException.cpp:
657         * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
658         * bindings/scripts/test/JS/JSTestInterface.cpp:
659         (WebCore::JSTestInterface::put):
660         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
661         * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
662         * bindings/scripts/test/JS/JSTestNode.cpp:
663         * bindings/scripts/test/JS/JSTestObj.cpp:
664         * bindings/scripts/test/JS/JSTestObj.h:
665         * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
666         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
667         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
668         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
669         * bindings/scripts/test/JS/JSTestTypedefs.h:
670         * bindings/scripts/test/JS/JSattribute.cpp:
671         * bindings/scripts/test/JS/JSreadonly.cpp:
672         * html/canvas/WebGLRenderingContext.idl:
673           Remove bogus attribute, as it has never been in the spec and should not
674           have been added.
675
676 2014-01-24  David Hyatt  <hyatt@apple.com>
677
678         [New Multicolumn] Eliminate RenderMultiColumnBlock
679         https://bugs.webkit.org/show_bug.cgi?id=127565
680
681         Reviewed by Antti Koivisto.
682
683         This patch eliminates RenderMultiColumnBlock and folds all of its remaining code
684         back into RenderBlockFlow. This allows all block flows to support multi-column
685         layout, including table cells, list items, and the RenderView itself.
686
687         * CMakeLists.txt:
688         * WebCore.order:
689         * WebCore.vcxproj/WebCore.vcxproj:
690         * WebCore.vcxproj/WebCore.vcxproj.filters:
691         * WebCore.xcodeproj/project.pbxproj:
692         Remove RenderMultiColumnBlock from the makefiles.
693
694         * rendering/RenderBlock.cpp:
695         (WebCore::RenderBlock::adjustIntrinsicLogicalWidthsForColumns):
696         Tweak the comment, since it was no longer accurate.
697
698         * rendering/RenderBlock.h:
699         Move some functions down into RenderBlockFlow.
700
701         * rendering/RenderBlockFlow.cpp:
702         (WebCore::RenderBlockFlow::RenderBlockFlow):
703         (WebCore::RenderBlockFlow::createMultiColumnFlowThreadIfNeeded):
704         (WebCore::RenderBlockFlow::styleDidChange):
705         (WebCore::RenderBlockFlow::relayoutForPagination):
706         (WebCore::RenderBlockFlow::layoutSpecialExcludedChild):
707         (WebCore::RenderBlockFlow::updateLogicalWidthAndColumnWidth):
708         (WebCore::RenderBlockFlow::addChild):
709         (WebCore::RenderBlockFlow::checkForPaginationLogicalHeightChange):
710          * rendering/RenderBlockFlow.h:
711          Move a bunch of functions from RenderMultiColumnBlock up into RenderBlockFlow.
712
713         * rendering/RenderBox.cpp:
714         (WebCore::RenderBox::isUnsplittableForPagination):
715         Calls isMultiColumnBlockFlow() now instead of testing for a specific renderer type.
716
717         * rendering/RenderElement.cpp:
718         (WebCore::RenderElement::createFor):
719         Remove the multicolumn block creation code, since we always make a block flow now.
720
721         * rendering/RenderMultiColumnBlock.cpp: Removed.
722         * rendering/RenderMultiColumnBlock.h: Removed.
723         Nuke the files.
724
725         * rendering/RenderMultiColumnFlowThread.cpp:
726         (WebCore::RenderMultiColumnFlowThread::initialLogicalWidth):
727         (WebCore::RenderMultiColumnFlowThread::autoGenerateRegionsToBlockOffset):
728         * rendering/RenderMultiColumnSet.cpp:
729         (WebCore::RenderMultiColumnSet::heightAdjustedForSetOffset):
730         (WebCore::RenderMultiColumnSet::addForcedBreak):
731         (WebCore::RenderMultiColumnSet::recalculateBalancedHeight):
732         (WebCore::RenderMultiColumnSet::updateLogicalWidth):
733         (WebCore::RenderMultiColumnSet::prepareForLayout):
734         (WebCore::RenderMultiColumnSet::columnGap):
735         (WebCore::RenderMultiColumnSet::paintColumnRules):
736         Change all of the functions in the multicolumnset and multicolumnflowthread classes
737         to cast the parent to a RenderBlockFlow now instead of a RenderMultiColumnBlock.
738         Change the code to call through to multiColumnFlowThread() for column-specific information
739         for that parent block.
740
741         * rendering/RenderObject.h:
742         (WebCore::RenderObject::isMultiColumnBlockFlow):
743         Remove isRenderMultiColumnBlock() and replace with isMultiColumnBlockFlow().
744
745         * rendering/RenderingAllInOne.cpp:
746         Remove RenderMultiColumnBlock include.
747         
748 2014-01-24  Brady Eidson  <beidson@apple.com>
749
750         IDB: support createIndex/deleteIndex messaging
751         https://bugs.webkit.org/show_bug.cgi?id=127546
752
753         Reviewed by Tim Horton.
754
755         * WebCore.exp.in: Export a needed CrossThreadCopier
756
757 2014-01-24  Daniel Bates  <dabates@apple.com>
758
759         Fix the Windows build after <http://trac.webkit.org/changeset/162704>
760         (https://bugs.webkit.org/show_bug.cgi?id=127293)
761
762         Only include TargetConditionals.h when building on a Darwin-based OS.
763         Also, check that TARGET_OS_IPHONE is defined before referencing its value
764         since it will be undefined when building on Windows.
765
766         * bindings/objc/PublicDOMInterfaces.h:
767
768 2014-01-24  Daniel Bates  <dabates@apple.com>
769
770         Bindings generation tests hit an error trying to include wtf/Platform.h after r161638
771         https://bugs.webkit.org/show_bug.cgi?id=127293
772
773         Reviewed by Alexey Proskuryakov.
774
775         Include TargetConditionals.h instead of wtf/Platform.h as the latter isn't available
776         in the public SDK.
777
778         As a side effect of this change, replace usage of PLATFORM(IOS) with TARGET_OS_IPHONE.
779
780         * bindings/objc/PublicDOMInterfaces.h:
781
782 2014-01-21  David Hyatt  <hyatt@apple.com>
783
784         [New Multicolumn] Table cells and list items need to work as multicolumn blocks.
785         https://bugs.webkit.org/show_bug.cgi?id=127365
786         
787         This patch is a first step towards eliminating RenderMultiColumnBlock and moving
788         all its functionality into RenderBlockFlow. Doing so will allow table cells, list
789         items and the RenderView to use the new multi-column layout.
790         
791         Reviewed by Simon Fraser.
792
793         * rendering/RenderBlockFlow.cpp:
794         (WebCore::RenderBlockFlow::setMultiColumnFlowThread):
795         * rendering/RenderBlockFlow.h:
796         (WebCore::RenderBlockFlow::RenderBlockFlowRareData::RenderBlockFlowRareData):
797         (WebCore::RenderBlockFlow::multiColumnFlowThread):
798         Add the flow thread pointer to the multi-column flow thread to RenderBlockFlow's
799         rare data. This lets us use only one pointer in the rare data to point to an object
800         that can hold all of the rest of the multi-column info.
801
802         * rendering/RenderMultiColumnBlock.cpp:
803         (WebCore::RenderMultiColumnBlock::RenderMultiColumnBlock):
804         Move the construction of the flow thread to the constructor. This ensures we
805         never have a null flow thread and lets us avoid having to null check it for
806         empty multi-column blocks.
807
808         (WebCore::RenderMultiColumnBlock::columnHeightAvailable):
809         (WebCore::RenderMultiColumnBlock::columnWidth):
810         (WebCore::RenderMultiColumnBlock::columnCount):
811         (WebCore::RenderMultiColumnBlock::updateLogicalWidthAndColumnWidth):
812         The above functions now call through to the multi-column flow thread for results.
813
814         (WebCore::RenderMultiColumnBlock::checkForPaginationLogicalHeightChange):
815          Set the column height available on the flow thread.
816
817         (WebCore::RenderMultiColumnBlock::relayoutForPagination):
818         The balancing pass and guard is in the multi-column flow thread now.
819
820         (WebCore::RenderMultiColumnBlock::addChild):
821         Don't have to create the flow thread here any longer, since we do it up front
822         in the constructor of RenderMultiColumnBlock.
823
824         (WebCore::RenderMultiColumnBlock::layoutSpecialExcludedChild):
825         Don't need the null check of the flow thread any more.
826
827         * rendering/RenderMultiColumnBlock.h:
828         Change the inlined functions to not be inlined, since they need to call
829         RenderMultiColumnFlowThread functions now.
830
831         * rendering/RenderMultiColumnFlowThread.cpp:
832         (WebCore::RenderMultiColumnFlowThread::RenderMultiColumnFlowThread):
833         Init the new member variables we moved here from RenderMultiColumnBlock.
834
835         (WebCore::RenderMultiColumnFlowThread::computeColumnCountAndWidth):
836         Moved from RenderMultiColumnBlock.
837
838         * rendering/RenderMultiColumnFlowThread.h:
839         Add public getters/setters to the member variables so that RenderMultiColumnBlock can
840         still see them. Move the member variables here from RenderMultiColumnBlock.
841
842         * rendering/RenderMultiColumnSet.cpp:
843         (WebCore::RenderMultiColumnSet::calculateBalancedHeight):
844         (WebCore::RenderMultiColumnSet::prepareForLayout):
845         (WebCore::RenderMultiColumnSet::columnCount):
846         Call through to the flow thread instead.
847
848 2014-01-24  Zan Dobersek  <zdobersek@igalia.com>
849
850         Unreviewed GTK build fix after r162663.
851
852         * platform/gtk/ScrollViewGtk.cpp:
853         (WebCore::ScrollView::visibleContentRectInternal): Renamed from visibleContentRect.
854
855 2014-01-24  Zan Dobersek  <zdobersek@igalia.com>
856
857         Move HistoryItem to std::unique_ptr
858         https://bugs.webkit.org/show_bug.cgi?id=127275
859
860         Reviewed by Darin Adler.
861
862         Replace the uses of OwnPtr and PassOwnPtr in the HistoryItem class with std::unique_ptr.
863
864         * history/HistoryItem.cpp:
865         (WebCore::HistoryItem::HistoryItem):
866         (WebCore::HistoryItem::reset):
867         (WebCore::HistoryItem::addRedirectURL):
868         (WebCore::HistoryItem::setRedirectURLs):
869         * history/HistoryItem.h:
870         * history/mac/HistoryItemMac.mm:
871         (WebCore::HistoryItem::setTransientProperty):
872         WebCore.exp.in: Update the symbol.
873
874 2014-01-23  Morten Stenshorne  <mstensho@opera.com>
875
876         Region based multicol: unresolvable percent height results in 1px tall multicol
877         https://bugs.webkit.org/show_bug.cgi?id=122826
878
879         Reviewed by David Hyatt.
880
881         If a box has a percentage height, but the computed height of its
882         containing block is auto, the computed height of the box also becomes
883         auto. computeContentLogicalHeight() returns -1 if the height isn't
884         resolvable, and we need to make sure that such a value doesn't
885         constrain the height of the multicol container.
886
887         Tests: fast/multicol/newmulticol/unresolvable-percent-height-2.html
888                fast/multicol/newmulticol/unresolvable-percent-height.html
889                fast/multicol/newmulticol/unresolvable-percent-max-height-2.html
890                fast/multicol/newmulticol/unresolvable-percent-max-height.html
891
892         * rendering/RenderMultiColumnSet.cpp:
893         (WebCore::RenderMultiColumnSet::RenderMultiColumnSet):
894         (WebCore::RenderMultiColumnSet::calculateBalancedHeight):
895         (WebCore::RenderMultiColumnSet::recalculateBalancedHeight):
896         (WebCore::RenderMultiColumnSet::prepareForLayout):
897
898 2014-01-23  Joseph Pecoraro  <pecoraro@apple.com>
899
900         Move ContentSearchUtils, ScriptBreakpoint, and ScriptDebugListener into JavaScriptCore for inspector
901         https://bugs.webkit.org/show_bug.cgi?id=127537
902
903         Reviewed by Timothy Hatcher.
904
905           - Rename ContentSearchUtils => ContentSearchUtilities and move to JavaScriptCore.
906           - Move ScriptBreakpoint and ScriptDebugListener to JavaScriptCore.
907           - Move them all to namespace Inspector.
908           - Update build files and users to the new names.
909
910         No change in functionality, just moving code.
911
912         * CMakeLists.txt:
913         * ForwardingHeaders/inspector/ContentSearchUtilities.h: Added.
914         * ForwardingHeaders/inspector/ScriptBreakpoint.h: Added.
915         * ForwardingHeaders/inspector/ScriptDebugListener.h: Added.
916         * GNUmakefile.list.am:
917         * WebCore.vcxproj/WebCore.vcxproj:
918         * WebCore.vcxproj/WebCore.vcxproj.filters:
919         * WebCore.xcodeproj/project.pbxproj:
920         * bindings/js/PageScriptDebugServer.cpp:
921         * bindings/js/PageScriptDebugServer.h:
922         * bindings/js/ScriptDebugServer.cpp:
923         * bindings/js/ScriptDebugServer.h:
924         * bindings/js/WorkerScriptDebugServer.cpp:
925         * bindings/js/WorkerScriptDebugServer.h:
926         * inspector/InspectorAllInOne.cpp:
927         * inspector/InspectorDebuggerAgent.cpp:
928         (WebCore::InspectorDebuggerAgent::searchInContent):
929         (WebCore::InspectorDebuggerAgent::sourceMapURLForScript):
930         (WebCore::InspectorDebuggerAgent::didParseSource):
931         * inspector/InspectorDebuggerAgent.h:
932         * inspector/InspectorPageAgent.cpp:
933         (WebCore::InspectorPageAgent::sourceMapURLForResource):
934         (WebCore::InspectorPageAgent::searchInResource):
935         (WebCore::InspectorPageAgent::searchInResources):
936         * inspector/InspectorStyleSheet.cpp:
937         (WebCore::buildSourceRangeObject):
938         (WebCore::InspectorStyleSheet::lineEndings):
939         (WebCore::InspectorStyleSheetForInlineStyle::lineEndings):
940
941 2014-01-23  Joseph Pecoraro  <pecoraro@apple.com>
942
943         Move RegularExpression into JavaScriptCore for inspector
944         https://bugs.webkit.org/show_bug.cgi?id=127526
945
946         Reviewed by Geoffrey Garen.
947
948         Update as appropriate for the moved file and namespace
949         change for class RegularExpression.
950
951         * CMakeLists.txt:
952         * ForwardingHeaders/yarr/RegularExpression.h: Added.
953         * GNUmakefile.list.am:
954         * WebCore.exp.in:
955         * WebCore.vcxproj/WebCore.vcxproj:
956         * WebCore.vcxproj/WebCore.vcxproj.filters:
957         * WebCore.xcodeproj/project.pbxproj:
958         * dom/DOMImplementation.h:
959         * html/BaseCheckableInputType.cpp:
960         * html/BaseTextInputType.cpp:
961         (WebCore::BaseTextInputType::patternMismatch):
962         * html/EmailInputType.cpp:
963         (WebCore::isValidEmailAddress):
964         * html/InputType.cpp:
965         * inspector/ContentSearchUtils.cpp:
966         (WebCore::ContentSearchUtils::getRegularExpressionMatchesByLines):
967         (WebCore::ContentSearchUtils::createSearchRegex):
968         (WebCore::ContentSearchUtils::countRegularExpressionMatches):
969         (WebCore::ContentSearchUtils::searchInTextByLines):
970         * inspector/ContentSearchUtils.h:
971         * inspector/InspectorDebuggerAgent.cpp:
972         (WebCore::matches):
973         (WebCore::InspectorDebuggerAgent::breakpointActionLog):
974         (WebCore::InspectorDebuggerAgent::breakpointActionSound):
975         * inspector/InspectorDebuggerAgent.h:
976         * inspector/InspectorPageAgent.cpp:
977         (WebCore::InspectorPageAgent::searchInResources):
978         * inspector/InspectorPageAgent.h:
979         * inspector/InspectorRuntimeAgent.cpp:
980         * inspector/InspectorRuntimeAgent.h:
981         * inspector/InspectorStyleSheet.cpp:
982         (WebCore::selectorsFromSource):
983         * inspector/WorkerDebuggerAgent.cpp:
984         * page/Frame.cpp:
985         (WebCore::createRegExpForLabels):
986         (WebCore::Frame::searchForLabelsAboveCell):
987         (WebCore::Frame::searchForLabelsBeforeElement):
988         (WebCore::matchLabelsAgainstString):
989         * page/Frame.h:
990         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
991         (WebCore::GraphicsContext3D::getUnmangledInfoLog):
992
993 2014-01-23  Brady Eidson  <beidson@apple.com>
994
995         IDB: Support IDBObjectStore.clear()
996         https://bugs.webkit.org/show_bug.cgi?id=127541
997         
998         Reviewed by Anders Carlsson.
999
1000         The backing store should never be performing callbacks directly:
1001         * Modules/indexeddb/leveldb/IDBServerConnectionLevelDB.cpp:
1002         (WebCore::IDBServerConnectionLevelDB::clearObjectStore):
1003
1004         Instead, the transaction operations should do that themselves:
1005         * Modules/indexeddb/IDBTransactionBackendOperations.cpp:
1006         (WebCore::ClearObjectStoreOperation::perform):
1007         * Modules/indexeddb/IDBTransactionBackendOperations.h:
1008         (WebCore::ClearObjectStoreOperation::transaction):
1009
1010 2014-01-23  Dan Bernstein  <mitz@apple.com>
1011
1012         <rdar://problem/15875326> REGRESSION (r162257): Assertion failure (should not be reached) in CSSPreloadScanner::tokenize()
1013         https://bugs.webkit.org/show_bug.cgi?id=127540
1014
1015         Reviewed by Anders Carlsson.
1016
1017         No new tests, because I could not reproduce the bug reliably and I don’t know how to trigger
1018         it.
1019
1020         * html/parser/CSSPreloadScanner.cpp:
1021         (WebCore::CSSPreloadScanner::scan): Check for the DoneParsingImportRules before tokenizing
1022         a character, not after. This restores the logic from before r162257.
1023
1024 2014-01-23  Jer Noble  <jer.noble@apple.com>
1025
1026         [iOS] Protect against possbile deadlock by delaying video layer creation
1027         https://bugs.webkit.org/show_bug.cgi?id=127505
1028
1029         Reviewed by Eric Carlson.
1030
1031         Work around a possible deadlock on iOS when creating a media element
1032         backed by AVFoundation by delaying creation of the AVPlayerLayer.
1033         The deadlock can occur when the web thread is doing CALayer layout
1034         while taking the web thread lock, while CoreMedia is doing property
1035         access on an async thread while taking the CM lock, and each is waiting
1036         for the other's lock to be released.
1037
1038         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
1039         (WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoLayer):
1040
1041 2014-01-23  Jer Noble  <jer.noble@apple.com>
1042
1043         [MSE][Mac] Crash when reloading a page during playback
1044         https://bugs.webkit.org/show_bug.cgi?id=126903
1045
1046         Reviewed by Eric Carlson.
1047
1048         Periodic time observers added to AVSampleBufferRenderSynchronizer will execute their
1049         callback block even after being removed with -removeTimeObserver:, which is tracked by
1050         <rdar://problem/15798050>. Work around this problem by passing a WeakPtr into the block
1051         and bail early if the owning media player has been destroyed.
1052
1053         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
1054         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::createWeakPtr):
1055         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
1056         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::MediaPlayerPrivateMediaSourceAVFObjC):
1057
1058 2014-01-23  ChangSeok Oh  <changseok.oh@collabora.com>
1059
1060         Dragging from inner side of video to outside causes a crash
1061         https://bugs.webkit.org/show_bug.cgi?id=126338
1062
1063         Reviewed by Jer Noble.
1064
1065         The crash happens while dragging mouse cursor through timeline control to outside
1066         of video region. This is beacause media controls are selected with the drag.
1067         The media controls disappear when mouse cursor goes outside of video though
1068         the dragging/selection proceeds. If once media controls are hidden, related element
1069         lose their renderers. However the drag is still under going. it requires shadowPseudoId
1070         of the selected controls. Untorntunately, SliderThumbElement/SliderContainerElement
1071         don't return a static value for the shadowPseudoId unlike other media controls,
1072         but they need a renderer to determine it. This is the reason of crash.
1073
1074         Test: media/media-controller-drag-crash.html
1075
1076         * html/shadow/SliderThumbElement.cpp:
1077         (WebCore::SliderThumbElement::shadowPseudoId):
1078         (WebCore::SliderContainerElement::shadowPseudoId):
1079
1080 2014-01-23  Brady Eidson  <beidson@apple.com>
1081
1082         IDB: Implement SQLite backing store 'get' support
1083         https://bugs.webkit.org/show_bug.cgi?id=127502
1084
1085         Reviewed by Tim Horton.
1086
1087         Get a KeyRange from a KeyRangeData:
1088         * Modules/indexeddb/IDBKeyRangeData.cpp:
1089         (WebCore::IDBKeyRangeData::maybeCreateIDBKeyRange):
1090         * Modules/indexeddb/IDBKeyRangeData.h:
1091
1092         Add collation function support to SQLiteDatabase:
1093         * platform/sql/SQLiteDatabase.cpp:
1094         (WebCore::destroyCollationFunction):
1095         (WebCore::callCollationFunction):
1096         (WebCore::SQLiteDatabase::setCollationFunction):
1097         (WebCore::SQLiteDatabase::removeCollationFunction):
1098         * platform/sql/SQLiteDatabase.h:
1099
1100         * WebCore.exp.in:
1101
1102 2014-01-23  Jon Honeycutt  <jhoneycutt@apple.com>
1103
1104         Assertion failure in WebCore::PseudoElement::didRecalcStyle()
1105         <https://bugs.webkit.org/show_bug.cgi?id=126761>
1106         <rdar://problem/15793540>
1107
1108         Reviewed by Andy Estes.
1109
1110         Test: fast/images/animate-list-item-image-assertion.html
1111
1112         * dom/PseudoElement.cpp:
1113         (WebCore::PseudoElement::didRecalcStyle):
1114         Check isRenderImage() rather than isImage() before casting to
1115         RenderImage.
1116
1117         * editing/ios/EditorIOS.mm:
1118         (WebCore::getImage):
1119         Ditto.
1120
1121         * editing/mac/EditorMac.mm:
1122         (WebCore::getImage):
1123         Ditto.
1124
1125         * html/HTMLImageElement.cpp:
1126         (WebCore::HTMLImageElement::parseAttribute):
1127         (WebCore::HTMLImageElement::didAttachRenderers):
1128         Ditto.
1129
1130         * loader/ImageLoader.cpp:
1131         (WebCore::ImageLoader::renderImageResource):
1132         Ditto.
1133
1134         * page/DragController.cpp:
1135         (WebCore::getCachedImage):
1136         Ditto.
1137
1138         * rendering/RenderLayerBacking.cpp:
1139         (WebCore::RenderLayerBacking::isDirectlyCompositedImage):
1140         (WebCore::RenderLayerBacking::updateImageContents):
1141         Ditto.
1142
1143 2014-01-23  Joseph Pecoraro  <pecoraro@apple.com>
1144
1145         Web Inspector: Remove recompileAllJSFunctions timer in ScriptDebugServer
1146         https://bugs.webkit.org/show_bug.cgi?id=127409
1147
1148         Reviewed by Geoffrey Garen.
1149
1150         Covered by existing tests.
1151
1152         * bindings/js/ScriptDebugServer.h:
1153         * bindings/js/ScriptDebugServer.cpp:
1154         (WebCore::ScriptDebugServer::ScriptDebugServer):
1155         Remove m_recompileTimer and the recompile soon function.
1156         We can just recompile immediately in all existing cases.
1157
1158         * bindings/js/PageScriptDebugServer.h:
1159         * bindings/js/PageScriptDebugServer.cpp:
1160         (WebCore::PageScriptDebugServer::addListener):
1161         (WebCore::PageScriptDebugServer::removeListener):
1162         (WebCore::PageScriptDebugServer::recompileAllJSFunctions):
1163         (WebCore::PageScriptDebugServer::didAddFirstListener):
1164         (WebCore::PageScriptDebugServer::didRemoveLastListener):
1165         Add a "didAddFirstListener" to match "didRemoveLastListener".
1166         Only recompile functions when we attach the debugger and when
1167         we detach the last listener.
1168
1169         * bindings/js/WorkerScriptDebugServer.cpp:
1170         (WebCore::WorkerScriptDebugServer::addListener):
1171         (WebCore::WorkerScriptDebugServer::removeListener):
1172         (WebCore::WorkerScriptDebugServer::recompileAllJSFunctions):
1173         Same thing. Also rearrange the functions to read better.
1174
1175         * inspector/InspectorProfilerAgent.cpp:
1176         Use the direct recompile function instead of the removed "soon" version.
1177
1178         * WebCore.exp.in:
1179         Update disconnectFrontend symbol.
1180
1181         * page/PageDebuggable.cpp:
1182         (WebCore::PageDebuggable::disconnect):
1183         * testing/Internals.cpp:
1184         (WebCore::Internals::closeDummyInspectorFrontend):
1185         * workers/WorkerMessagingProxy.cpp:
1186         (WebCore::disconnectFromWorkerGlobalScopeInspectorTask):
1187         Include an InspectorDisconnectReason when calling disconnectFrontend.
1188
1189         * inspector/InspectorDatabaseAgent.h:
1190         * inspector/InspectorDebuggerAgent.cpp:
1191         (WebCore::InspectorDebuggerAgent::disable):
1192         (WebCore::InspectorDebuggerAgent::willDestroyFrontendAndBackend):
1193         If the disconnect reason is the page will be destroyed, don't recompile when disconnecting.
1194
1195         * inspector/InspectorProfilerAgent.h:
1196         * inspector/InspectorProfilerAgent.cpp:
1197         (WebCore::InspectorProfilerAgent::enable):
1198         (WebCore::InspectorProfilerAgent::disable):
1199         (WebCore::InspectorProfilerAgent::willDestroyFrontendAndBackend):
1200         If the disconnect reason is the page will be destroyed, don't recompile when disconnecting.
1201
1202         * inspector/InspectorController.h:
1203         * inspector/InspectorController.cpp:
1204         (WebCore::InspectorController::inspectedPageDestroyed):
1205         (WebCore::InspectorController::disconnectFrontend):
1206         (WebCore::InspectorController::close):
1207         Pass different reasons for the different disconnect reasons.
1208
1209         * inspector/WorkerInspectorController.h:
1210         * inspector/WorkerInspectorController.cpp:
1211         (WebCore::WorkerInspectorController::~WorkerInspectorController):
1212         (WebCore::WorkerInspectorController::disconnectFrontend):
1213         Pass different reasons for the different disconnect reasons.
1214
1215         * inspector/InspectorApplicationCacheAgent.cpp:
1216         (WebCore::InspectorApplicationCacheAgent::willDestroyFrontendAndBackend):
1217         * inspector/InspectorApplicationCacheAgent.h:
1218         * inspector/InspectorCSSAgent.cpp:
1219         (WebCore::InspectorCSSAgent::willDestroyFrontendAndBackend):
1220         * inspector/InspectorCSSAgent.h:
1221         * inspector/InspectorCanvasAgent.cpp:
1222         (WebCore::InspectorCanvasAgent::willDestroyFrontendAndBackend):
1223         * inspector/InspectorCanvasAgent.h:
1224         * inspector/InspectorConsoleAgent.cpp:
1225         (WebCore::InspectorConsoleAgent::willDestroyFrontendAndBackend):
1226         * inspector/InspectorConsoleAgent.h:
1227         * inspector/InspectorDOMAgent.cpp:
1228         (WebCore::InspectorDOMAgent::willDestroyFrontendAndBackend):
1229         * inspector/InspectorDOMAgent.h:
1230         * inspector/InspectorDOMDebuggerAgent.cpp:
1231         (WebCore::InspectorDOMDebuggerAgent::willDestroyFrontendAndBackend):
1232         * inspector/InspectorDOMDebuggerAgent.h:
1233         * inspector/InspectorDOMStorageAgent.cpp:
1234         (WebCore::InspectorDOMStorageAgent::willDestroyFrontendAndBackend):
1235         * inspector/InspectorDOMStorageAgent.h:
1236         * inspector/InspectorDatabaseAgent.cpp:
1237         (WebCore::InspectorDatabaseAgent::willDestroyFrontendAndBackend):
1238         * inspector/InspectorDebuggerAgent.h:
1239         * inspector/InspectorHeapProfilerAgent.cpp:
1240         (WebCore::InspectorHeapProfilerAgent::willDestroyFrontendAndBackend):
1241         * inspector/InspectorHeapProfilerAgent.h:
1242         * inspector/InspectorIndexedDBAgent.cpp:
1243         (WebCore::InspectorIndexedDBAgent::willDestroyFrontendAndBackend):
1244         * inspector/InspectorIndexedDBAgent.h:
1245         * inspector/InspectorInputAgent.cpp:
1246         (WebCore::InspectorInputAgent::willDestroyFrontendAndBackend):
1247         * inspector/InspectorInputAgent.h:
1248         * inspector/InspectorLayerTreeAgent.cpp:
1249         (WebCore::InspectorLayerTreeAgent::willDestroyFrontendAndBackend):
1250         * inspector/InspectorLayerTreeAgent.h:
1251         * inspector/InspectorMemoryAgent.cpp:
1252         (WebCore::InspectorMemoryAgent::willDestroyFrontendAndBackend):
1253         * inspector/InspectorMemoryAgent.h:
1254         * inspector/InspectorPageAgent.cpp:
1255         (WebCore::InspectorPageAgent::willDestroyFrontendAndBackend):
1256         * inspector/InspectorPageAgent.h:
1257         * inspector/InspectorResourceAgent.cpp:
1258         (WebCore::InspectorResourceAgent::willDestroyFrontendAndBackend):
1259         * inspector/InspectorResourceAgent.h:
1260         * inspector/InspectorTimelineAgent.cpp:
1261         (WebCore::InspectorTimelineAgent::willDestroyFrontendAndBackend):
1262         * inspector/InspectorTimelineAgent.h:
1263         * inspector/InspectorWorkerAgent.cpp:
1264         (WebCore::InspectorWorkerAgent::willDestroyFrontendAndBackend):
1265         * inspector/InspectorWorkerAgent.h:
1266         * inspector/PageDebuggerAgent.cpp:
1267         (WebCore::PageDebuggerAgent::disable):
1268         (WebCore::PageDebuggerAgent::stopListeningScriptDebugServer):
1269         * inspector/PageDebuggerAgent.h:
1270         * inspector/PageRuntimeAgent.cpp:
1271         (WebCore::PageRuntimeAgent::willDestroyFrontendAndBackend):
1272         * inspector/PageRuntimeAgent.h:
1273         * inspector/WorkerDebuggerAgent.cpp:
1274         (WebCore::WorkerDebuggerAgent::stopListeningScriptDebugServer):
1275         * inspector/WorkerDebuggerAgent.h:
1276         * inspector/WorkerRuntimeAgent.cpp:
1277         (WebCore::WorkerRuntimeAgent::willDestroyFrontendAndBackend):
1278         * inspector/WorkerRuntimeAgent.h:
1279         Include InspectorDisconnectReason param.
1280
1281 2014-01-23  Simon Fraser  <simon.fraser@apple.com>
1282
1283         Another Windows fix: include <algorithm> for std::min and std::max.
1284         
1285         * platform/graphics/IntSize.h:
1286
1287 2014-01-23  Simon Fraser  <simon.fraser@apple.com>
1288
1289         Try to fix Windows build.
1290
1291         * platform/win/PopupMenuWin.cpp:
1292         (WebCore::PopupMenuWin::visibleSize):
1293         * platform/win/PopupMenuWin.h:
1294
1295 2014-01-23  Simon Fraser  <simon.fraser@apple.com>
1296
1297         Make visibleContentRect() return actualVisibleContentRect() on iOS most of the time
1298         https://bugs.webkit.org/show_bug.cgi?id=127456
1299         
1300         Reviewed by Antti Koivisto.
1301         
1302         On iOS, visibleContentRect() returns the entire document rect for historical
1303         reasons, and actualVisibleContentRect() returns what visibleContentRect()
1304         returns on other platforms.
1305         
1306         In addition, actualVisibleContentRect() was returning an empty rect in WK2.
1307         
1308         Reduce the confusion of #ifdefs by making visibleContentRect() behave like
1309         actualVisibleContentRect() by default on iOS. Where it needs the old behavior,
1310         an optional parameter, LegacyIOSDocumentVisibleRect, provides this.
1311         
1312         Achieve this by having the virtual ScrollableArea::visibleContentRectInternal(),
1313         which is called by non-virtual visibleContentRect() and visibleContentRectIncludingScrollbars().
1314         
1315         Similarly clean up visibleHeight/visibleWidth functions by having visibleSize() be virtual,
1316         with non-virtual visibleHeight() and visibleWidth().
1317         
1318         ScrollableArea subclasses override visibleContentRectInternal() and visibleSize() where necessary.
1319         
1320         Mechanically change all the call sites of actualVisibleContentRect() to
1321         use visibleContentRect(), and the call sites of visibleContentRect()
1322         to visibleContentRect(..., LegacyIOSDocumentVisibleRect), adding comments
1323         where this may not be appropriate.
1324         
1325         Change callers of visibleContentRect(IncludeScrollbars...) to visibleContentRectIncludingScrollbars().
1326         
1327         Also add actualScrollPosition(), and clean up some actualScroll* call sites.
1328         
1329         No behavior change.
1330
1331         * WebCore.exp.in:
1332         * accessibility/AccessibilityObject.cpp:
1333         (WebCore::AccessibilityObject::isOnscreen):
1334         (WebCore::AccessibilityObject::scrollToMakeVisibleWithSubFocus):
1335         * accessibility/AccessibilityRenderObject.cpp:
1336         (WebCore::AccessibilityRenderObject::isOffScreen):
1337         * dom/Document.cpp:
1338         (WebCore::Document::adjustFloatQuadsForScrollAndAbsoluteZoomAndFrameScale):
1339         (WebCore::Document::adjustFloatRectForScrollAndAbsoluteZoomAndFrameScale):
1340         * dom/MouseRelatedEvent.cpp:
1341         (WebCore::MouseRelatedEvent::MouseRelatedEvent):
1342         * editing/Editor.cpp:
1343         (WebCore::Editor::countMatchesForText):
1344         * editing/FrameSelection.cpp:
1345         (WebCore::FrameSelection::bounds):
1346         (WebCore::FrameSelection::getClippedVisibleTextRectangles):
1347         * html/HTMLBodyElement.cpp:
1348         (WebCore::HTMLBodyElement::scrollLeft):
1349         (WebCore::HTMLBodyElement::scrollTop):
1350         * html/ImageDocument.cpp:
1351         (WebCore::ImageDocument::imageFitsInWindow):
1352         (WebCore::ImageDocument::windowSizeChanged):
1353         * inspector/InspectorOverlay.cpp:
1354         (WebCore::InspectorOverlay::update):
1355         * page/DOMWindow.cpp:
1356         (WebCore::DOMWindow::innerHeight):
1357         (WebCore::DOMWindow::innerWidth):
1358         (WebCore::DOMWindow::scrollX):
1359         (WebCore::DOMWindow::scrollY):
1360         (WebCore::DOMWindow::scrollBy):
1361         * page/FrameView.cpp:
1362         (WebCore::FrameView::calculateScrollbarModesForLayout):
1363         (WebCore::FrameView::layout):
1364         (WebCore::FrameView::scrollContentsSlowPath):
1365         (WebCore::FrameView::repaintContentRectangle):
1366         (WebCore::FrameView::sendResizeEventIfNeeded):
1367         (WebCore::FrameView::windowClipRect):
1368         (WebCore::FrameView::isScrollable):
1369         (WebCore::FrameView::paintControlTints):
1370         * page/SpatialNavigation.cpp:
1371         (WebCore::canScrollInDirection):
1372         * platform/ScrollView.cpp:
1373         (WebCore::ScrollView::unscaledVisibleContentSize):
1374         (WebCore::ScrollView::visibleContentRectInternal):
1375         (WebCore::ScrollView::updateScrollbars):
1376         (WebCore::ScrollView::paint):
1377         * platform/ScrollView.h:
1378         (WebCore::ScrollView::scrollOffset):
1379         (WebCore::ScrollView::actualScrollX):
1380         (WebCore::ScrollView::actualScrollY):
1381         (WebCore::ScrollView::actualScrollPosition):
1382         * platform/ScrollableArea.cpp:
1383         (WebCore::ScrollableArea::visibleContentRect):
1384         (WebCore::ScrollableArea::visibleContentRectIncludingScrollbars):
1385         (WebCore::ScrollableArea::visibleContentRectInternal):
1386         * platform/ScrollableArea.h:
1387         (WebCore::ScrollableArea::visibleWidth):
1388         (WebCore::ScrollableArea::visibleHeight):
1389         * platform/graphics/IntSize.h:
1390         (WebCore::IntSize::expandedTo): Drive-by cleanup.
1391         (WebCore::IntSize::shrunkTo):
1392         * platform/gtk/ScrollViewGtk.cpp:
1393         (WebCore::ScrollView::visibleContentRect):
1394         * rendering/RenderLayer.cpp:
1395         (WebCore::RenderLayer::scrollRectToVisible):
1396         (WebCore::RenderLayer::maximumScrollPosition):
1397         (WebCore::RenderLayer::visibleContentRectInternal):
1398         (WebCore::RenderLayer::hitTest):
1399         * rendering/RenderLayer.h:
1400         * rendering/RenderLayerBacking.cpp:
1401         (WebCore::RenderLayerBacking::updateCompositedBounds):
1402         * rendering/RenderListBox.cpp:
1403         * rendering/RenderListBox.h:
1404         * rendering/RenderView.cpp:
1405         (WebCore::RenderView::viewRect):
1406         (WebCore::RenderView::viewportSize):
1407
1408 2014-01-20  Myles C. Maxfield  <mmaxfield@apple.com>
1409
1410        Turn text-decoration-skip: ink on for all underlines
1411        https://bugs.webkit.org/show_bug.cgi?id=127331
1412
1413        Reviewed by Antti Koivisto.
1414
1415        No new tests are necessary because tests already exist
1416
1417        * rendering/style/RenderStyle.h:
1418
1419 2014-01-23  Hans Muller  <hmuller@adobe.com>
1420
1421         [CSS Shapes] Image valued shape size and position should conform to the spec
1422         https://bugs.webkit.org/show_bug.cgi?id=123295
1423
1424         Reviewed by Andreas Kling.
1425
1426         Implement image valued shape-outside scaling and translation per the spec,
1427         http://dev.w3.org/csswg/css-shapes/#shapes-from-image:
1428
1429         "The image is sized and positioned as if it were a replaced element whose
1430         specified width and height are the same as the element’s used content box size."
1431
1432         This change doesn't completely fulfill the spec, it's limited to image elements
1433         and shape-outside.
1434
1435         Tests: fast/shapes/shape-outside-floats/shape-outside-image-fit-001.html
1436                fast/shapes/shape-outside-floats/shape-outside-image-fit-002.html
1437                fast/shapes/shape-outside-floats/shape-outside-image-fit-003.html
1438                fast/shapes/shape-outside-floats/shape-outside-image-fit-004.html
1439
1440         * rendering/shapes/Shape.h:
1441         * rendering/shapes/Shape.cpp:
1442         (WebCore::Shape::createRasterShape):
1443         Added an imageRect parameter which specifies where the shape image is to
1444         appear relative to the content box. The imageRect implies both scaling and
1445         translation of the shape image.
1446
1447         * rendering/shapes/ShapeInfo.cpp:
1448         (WebCore::ShapeInfo<RenderType>::computedShape):
1449         (WebCore::getShapeImageRect):
1450         For replaced elements, compute the shape's imageRect with
1451         RenderReplaced::replacedContentRect().
1452
1453
1454 2014-01-23  Max Vujovic  <mvujovic@adobe.com>
1455
1456         Remove CSS Custom Filters code and tests
1457         https://bugs.webkit.org/show_bug.cgi?id=127382
1458
1459         Reviewed by Simon Fraser.
1460
1461         No new tests. Removing functionality.
1462
1463         * CMakeLists.txt:
1464         * Configurations/FeatureDefines.xcconfig:
1465         * DerivedSources.cpp:
1466         * DerivedSources.make:
1467         * GNUmakefile.list.am:
1468         * WebCore.order:
1469         * WebCore.vcxproj/WebCore.vcxproj:
1470         * WebCore.vcxproj/WebCore.vcxproj.filters:
1471         * WebCore.xcodeproj/project.pbxproj:
1472         * bindings/js/JSCSSRuleCustom.cpp:
1473         (WebCore::toJS):
1474         * bindings/js/JSCSSValueCustom.cpp:
1475         (WebCore::toJS):
1476         * bindings/objc/DOMCSS.mm:
1477         (kitClass):
1478         * css/CSSComputedStyleDeclaration.cpp:
1479         (WebCore::ComputedStyleExtractor::valueForFilter):
1480         (WebCore::ComputedStyleExtractor::propertyValue):
1481         * css/CSSComputedStyleDeclaration.h:
1482         * css/CSSGrammar.y.in:
1483         * css/CSSParser.cpp:
1484         (WebCore::CSSParserContext::CSSParserContext):
1485         (WebCore::operator==):
1486         (WebCore::CSSParser::CSSParser):
1487         (WebCore::CSSParser::parseValue):
1488         (WebCore::filterInfoForName):
1489         (WebCore::CSSParser::parseFilter):
1490         (WebCore::CSSParser::detectAtToken):
1491         * css/CSSParser.h:
1492         * css/CSSParserMode.h:
1493         * css/CSSPropertyNames.in:
1494         * css/CSSPropertySourceData.h:
1495         * css/CSSRule.h:
1496         * css/CSSRule.idl:
1497         * css/CSSValue.cpp:
1498         (WebCore::CSSValue::equals):
1499         (WebCore::CSSValue::cssText):
1500         (WebCore::CSSValue::destroy):
1501         (WebCore::CSSValue::cloneForCSSOM):
1502         * css/CSSValue.h:
1503         * css/CSSValueKeywords.in:
1504         * css/StyleResolver.cpp:
1505         (WebCore::StyleResolver::State::clear):
1506         (WebCore::StyleResolver::applyProperty):
1507         (WebCore::filterOperationForType):
1508         (WebCore::StyleResolver::createFilterOperations):
1509         (WebCore::StyleResolver::loadPendingResources):
1510         * css/StyleResolver.h:
1511         (WebCore::StyleResolver::State::State):
1512         * css/StyleRule.cpp:
1513         (WebCore::StyleRuleBase::destroy):
1514         (WebCore::StyleRuleBase::copy):
1515         (WebCore::StyleRuleBase::createCSSOMWrapper):
1516         * css/StyleRule.h:
1517         * css/StyleSheetContents.cpp:
1518         (WebCore::childRulesHaveFailedOrCanceledSubresources):
1519         * css/WebKitCSSArrayFunctionValue.cpp: Removed.
1520         * css/WebKitCSSArrayFunctionValue.h: Removed.
1521         * css/WebKitCSSFilterRule.cpp: Removed.
1522         * css/WebKitCSSFilterRule.h: Removed.
1523         * css/WebKitCSSFilterRule.idl: Removed.
1524         * css/WebKitCSSFilterValue.cpp:
1525         (WebCore::WebKitCSSFilterValue::WebKitCSSFilterValue):
1526         (WebCore::WebKitCSSFilterValue::customCSSText):
1527         * css/WebKitCSSFilterValue.h:
1528         * css/WebKitCSSFilterValue.idl:
1529         * css/WebKitCSSMatFunctionValue.cpp: Removed.
1530         * css/WebKitCSSMatFunctionValue.h: Removed.
1531         * css/WebKitCSSMixFunctionValue.cpp: Removed.
1532         * css/WebKitCSSMixFunctionValue.h: Removed.
1533         * css/WebKitCSSMixFunctionValue.idl: Removed.
1534         * css/WebKitCSSShaderValue.cpp: Removed.
1535         * css/WebKitCSSShaderValue.h: Removed.
1536         * loader/cache/CachedResource.cpp:
1537         (WebCore::defaultPriorityForResourceType):
1538         * loader/cache/CachedResource.h:
1539         * loader/cache/CachedResourceLoader.cpp:
1540         (WebCore::createResource):
1541         (WebCore::CachedResourceLoader::checkInsecureContent):
1542         (WebCore::CachedResourceLoader::canRequest):
1543         * loader/cache/CachedResourceLoader.h:
1544         * loader/cache/CachedShader.cpp: Removed.
1545         * loader/cache/CachedShader.h: Removed.
1546         * page/Settings.cpp:
1547         (WebCore::Settings::Settings):
1548         * page/Settings.h:
1549         * page/animation/CSSPropertyAnimation.cpp:
1550         (WebCore::blendFilter):
1551         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
1552         (PlatformCALayerMac::filtersCanBeComposited):
1553         * platform/graphics/filters/CustomFilterArrayParameter.h: Removed.
1554         * platform/graphics/filters/CustomFilterColorParameter.h: Removed.
1555         * platform/graphics/filters/CustomFilterCompiledProgram.cpp: Removed.
1556         * platform/graphics/filters/CustomFilterCompiledProgram.h: Removed.
1557         * platform/graphics/filters/CustomFilterConstants.h: Removed.
1558         * platform/graphics/filters/CustomFilterGlobalContext.cpp: Removed.
1559         * platform/graphics/filters/CustomFilterGlobalContext.h: Removed.
1560         * platform/graphics/filters/CustomFilterMesh.cpp: Removed.
1561         * platform/graphics/filters/CustomFilterMesh.h: Removed.
1562         * platform/graphics/filters/CustomFilterMeshGenerator.cpp: Removed.
1563         * platform/graphics/filters/CustomFilterMeshGenerator.h: Removed.
1564         * platform/graphics/filters/CustomFilterNumberParameter.h: Removed.
1565         * platform/graphics/filters/CustomFilterOperation.cpp: Removed.
1566         * platform/graphics/filters/CustomFilterOperation.h: Removed.
1567         * platform/graphics/filters/CustomFilterParameter.h: Removed.
1568         * platform/graphics/filters/CustomFilterParameterList.cpp: Removed.
1569         * platform/graphics/filters/CustomFilterParameterList.h: Removed.
1570         * platform/graphics/filters/CustomFilterProgram.cpp: Removed.
1571         * platform/graphics/filters/CustomFilterProgram.h: Removed.
1572         * platform/graphics/filters/CustomFilterProgramClient.h: Removed.
1573         * platform/graphics/filters/CustomFilterProgramInfo.cpp: Removed.
1574         * platform/graphics/filters/CustomFilterProgramInfo.h: Removed.
1575         * platform/graphics/filters/CustomFilterRenderer.cpp: Removed.
1576         * platform/graphics/filters/CustomFilterRenderer.h: Removed.
1577         * platform/graphics/filters/CustomFilterTransformParameter.h: Removed.
1578         * platform/graphics/filters/CustomFilterValidatedProgram.cpp: Removed.
1579         * platform/graphics/filters/CustomFilterValidatedProgram.h: Removed.
1580         * platform/graphics/filters/FECustomFilter.cpp: Removed.
1581         * platform/graphics/filters/FECustomFilter.h: Removed.
1582         * platform/graphics/filters/FilterOperation.h:
1583         * platform/graphics/filters/FilterOperations.cpp:
1584         (WebCore::FilterOperations::outsets):
1585         * platform/graphics/filters/FilterOperations.h:
1586         * platform/graphics/filters/ValidatedCustomFilterOperation.cpp: Removed.
1587         * platform/graphics/filters/ValidatedCustomFilterOperation.h: Removed.
1588         * platform/graphics/filters/texmap/CustomFilterValidatedProgramTextureMapper.cpp: Removed.
1589         * platform/graphics/filters/texmap/TextureMapperPlatformCompiledProgram.h: Removed.
1590         * platform/graphics/gpu/Texture.cpp:
1591         * platform/graphics/texmap/TextureMapper.h:
1592         * platform/graphics/texmap/TextureMapperGL.cpp:
1593         (WebCore::getPassesRequiredForFilter):
1594         (WebCore::BitmapTextureGL::applyFilters):
1595         * platform/graphics/texmap/TextureMapperGL.h:
1596         * platform/graphics/texmap/coordinated/CompositingCoordinator.cpp:
1597         (WebCore::CompositingCoordinator::clearPendingStateChanges):
1598         (WebCore::CompositingCoordinator::syncLayerState):
1599         * platform/graphics/texmap/coordinated/CompositingCoordinator.h:
1600         * platform/graphics/texmap/coordinated/CoordinatedCustomFilterOperation.h: Removed.
1601         * platform/graphics/texmap/coordinated/CoordinatedCustomFilterProgram.h: Removed.
1602         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
1603         (WebCore::CoordinatedGraphicsScene::setLayerFiltersIfNeeded):
1604         (WebCore::CoordinatedGraphicsScene::commitSceneState):
1605         (WebCore::CoordinatedGraphicsScene::setLayerAnimationsIfNeeded):
1606         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.h:
1607         * platform/graphics/texmap/coordinated/CoordinatedGraphicsState.h:
1608         * rendering/FilterEffectRenderer.cpp:
1609         (WebCore::FilterEffectRenderer::FilterEffectRenderer):
1610         (WebCore::FilterEffectRenderer::build):
1611         (WebCore::FilterEffectRenderer::computeSourceImageRectForDirtyRect):
1612         * rendering/FilterEffectRenderer.h:
1613         * rendering/RenderLayer.cpp:
1614         (WebCore::RenderLayer::setFilterBackendNeedsRepaintingInRect):
1615         (WebCore::RenderLayer::calculateClipRects):
1616         * rendering/RenderLayer.h:
1617         * rendering/RenderLayerBacking.cpp:
1618         (WebCore::RenderLayerBacking::updateFilters):
1619         * rendering/RenderLayerFilterInfo.cpp:
1620         (WebCore::RenderLayer::FilterInfo::~FilterInfo):
1621         * rendering/RenderLayerFilterInfo.h:
1622         * rendering/RenderView.cpp:
1623         * rendering/RenderView.h:
1624         * rendering/style/StyleCachedShader.cpp: Removed.
1625         * rendering/style/StyleCachedShader.h: Removed.
1626         * rendering/style/StyleCustomFilterProgram.cpp: Removed.
1627         * rendering/style/StyleCustomFilterProgram.h: Removed.
1628         * rendering/style/StyleCustomFilterProgramCache.cpp: Removed.
1629         * rendering/style/StyleCustomFilterProgramCache.h: Removed.
1630         * rendering/style/StylePendingShader.h: Removed.
1631         * rendering/style/StyleShader.h: Removed.
1632
1633 2014-01-22  Jon Honeycutt  <jhoneycutt@apple.com>
1634
1635         REGRESSION(r161967): Crash in WebCore::CachedSVGDocumentReference::load
1636         <https://webkit.org/b/127151>
1637         <rdar://problem/15840760>
1638
1639         There were two issues introduced here; the first is a use-after-free of
1640         CachedSVGDocumentReference objects.
1641
1642         The previous code kept a map from FilterOperation ->
1643         RefPtr<WebKitCSSSVGDocumentValue>, which retained the
1644         CachedSVGDocument. In r161967, this was changed to use a weak HashSet,
1645         which allows stale CachedSVGDocumentReferences in the pending document
1646         set if the owning FilterOperation is deleted. To fix this, we'll keep a
1647         vector of RefPtr<FilterOperation> with pending SVG documents.
1648
1649         The second issue is a null deref in CachedSVGDocumentReference::load();
1650         CachedResourceLoader::requestSVGDocument() can return 0 if (for
1651         example) an invalid URL is passed. r161967 removed a null check as part
1652         of the refactoring.
1653
1654         Reviewed by Dirk Schulze.
1655
1656         Tests: css3/filters/crash-filter-animation-invalid-url.html
1657                css3/filters/crash-invalid-url.html
1658
1659         * css/StyleResolver.cpp:
1660         (WebCore::StyleResolver::State::clear):
1661         Use new member var name.
1662         (WebCore::StyleResolver::loadPendingSVGDocuments):
1663         For each FilterOperation with a pending SVG document, get or create a
1664         CachedSVGDocumentReference, and tell it to load. Changed to use new
1665         function names.
1666         (WebCore::StyleResolver::createFilterOperations):
1667         Append the FilterOperation to the list of FilterOperations with
1668         unloaded SVG documents.
1669
1670         * css/StyleResolver.h:
1671         Changed from using PendingSVGDocumentSet, a weak set, to
1672         a Vector<RefPtr<ReferenceFilterOperation>>.
1673         (WebCore::StyleResolver::State::filtersWithPendingSVGDocuments):
1674         Return the vector.
1675
1676         * loader/cache/CachedSVGDocumentReference.cpp:
1677         (WebCore::CachedSVGDocumentReference::~CachedSVGDocumentReference):
1678         Null check m_document rather than checking m_loadRequested.
1679         m_loadRequested may be true when m_document is 0.
1680         (WebCore::CachedSVGDocumentReference::load):
1681         Null check the result of CachedResourceLoader::requestSVGDocument().
1682
1683         * platform/graphics/filters/FilterOperation.cpp:
1684         (WebCore::ReferenceFilterOperation::getOrCreateCachedSVGDocumentReference):
1685         Create, if necessary, and return the CachedSVGDocumentReference.
1686
1687         * platform/graphics/filters/FilterOperation.h:
1688         Replaced createCachedSVGDocumentReference() with
1689         getOrCreateCachedSVGDocumentReference(), which makes for slightly
1690         cleaner code.
1691
1692 2014-01-23  Antti Koivisto  <antti@apple.com>
1693
1694         Don't enable speculative tiles immediately after main load stops progressing
1695         https://bugs.webkit.org/show_bug.cgi?id=127507
1696
1697         Reviewed by Andreas Kling.
1698
1699         It is common for timers and events to trigger more loading after the initial main frame loading
1700         has completed. We should delay a bit before enabling speculative tiles and keep them disabled 
1701         if loading still continues.
1702
1703         * page/FrameView.cpp:
1704         (WebCore::FrameView::FrameView):
1705         (WebCore::FrameView::adjustTiledBackingCoverage):
1706         (WebCore::shouldEnableSpeculativeTilingDuringLoading):
1707         (WebCore::FrameView::enableSpeculativeTilingIfNeeded):
1708         
1709             When load progression stops wait 0.5s before enabling speculative tiles.
1710
1711         (WebCore::FrameView::speculativeTilingEnableTimerFired):
1712         
1713             Don't enable speculative tiles if the progression has started again. Instead restart the timer.
1714
1715         * page/FrameView.h:
1716         * rendering/RenderLayerBacking.cpp:
1717         (WebCore::RenderLayerBacking::RenderLayerBacking):
1718         (WebCore::computeTileCoverage):
1719         
1720             Move the FrameView level code to FrameView (so we don't need to add a timer to every RenderLayerBacking).
1721
1722         * rendering/RenderLayerBacking.h:
1723
1724 2014-01-23  Antti Koivisto  <antti@apple.com>
1725
1726         Loads started soon after main frame completion should be considered part of the main load
1727         https://bugs.webkit.org/show_bug.cgi?id=127504
1728
1729         Reviewed by Andreas Kling.
1730
1731         ProgressTracker currently decides that main load is complete when the main frame stops loading. 
1732         However it is common that timers and onload events trigger more loads immediately (for example 
1733         by inserting iframes) and loading continues visually. These should be considered as part of the
1734         main load for paint throttling and speculative tiling coverage purposes.
1735
1736         * loader/ProgressTracker.cpp:
1737         (WebCore::ProgressTracker::ProgressTracker):
1738         (WebCore::ProgressTracker::progressStarted):
1739         
1740             Track whether this is considered part of the main load or not with a boolean. 
1741             It is set for subframe loads too if they start loading soon (within 1s) after the main frame load completes.
1742
1743         (WebCore::ProgressTracker::finalProgressComplete):
1744         
1745             Get a timestamp.
1746
1747         (WebCore::ProgressTracker::isMainLoadProgressing):
1748
1749             New definition of "main load".
1750
1751         * loader/ProgressTracker.h:
1752
1753 2014-01-23  peavo@outlook.com  <peavo@outlook.com>
1754
1755         [WinCairo] Compile error.
1756         https://bugs.webkit.org/show_bug.cgi?id=127499
1757
1758         Reviewed by Brent Fulgham.
1759
1760         * platform/network/curl/ResourceError.h: Include <winsock2.h> before <curl/curl.h>.
1761
1762 2014-01-23  Brady Eidson  <beidson@apple.com>
1763
1764         IDB: Implement cross-thread and IPC plumbing for 'get' support
1765         https://bugs.webkit.org/show_bug.cgi?id=127501
1766
1767         Reviewed by Anders Carlsson.
1768
1769         Add isolatedCopy to the IDBGetResult object:
1770         * Modules/indexeddb/IDBGetResult.h:
1771         (WebCore::IDBGetResult::isolatedCopy):
1772
1773         Add a cross-thread and cross-IPC appropriate object for IDBKeyRanges:
1774         * Modules/indexeddb/IDBKeyRangeData.cpp: Copied from Source/WebCore/Modules/indexeddb/IDBGetResult.h.
1775         (WebCore::IDBKeyRangeData::isolatedCopy):
1776         * Modules/indexeddb/IDBKeyRangeData.h: Copied from Source/WebCore/Modules/indexeddb/IDBGetResult.h.
1777         (WebCore::IDBKeyRangeData::IDBKeyRangeData):
1778
1779         Add a few more cross-thread copiers:
1780         * platform/CrossThreadCopier.cpp:
1781         (WebCore::IDBGetResult>::copy):
1782         (WebCore::IDBKeyRangeData>::copy):
1783         * platform/CrossThreadCopier.h:
1784
1785         Project file gunk:
1786         * CMakeLists.txt:
1787         * GNUmakefile.list.am:
1788         * WebCore.exp.in:
1789         * WebCore.xcodeproj/project.pbxproj:
1790
1791 2014-01-23  Jer Noble  <jer.noble@apple.com>
1792
1793         [MSE][Mac] Adopt new AVStreamDataParser delegate API
1794         https://bugs.webkit.org/show_bug.cgi?id=127498
1795
1796         Reviewed by Eric Carlson.
1797
1798         Adopt a new delegate API which passes in whether or not the new AVAsset
1799         is discontinuous, implying the AVAsset is entirely new rather than
1800         just updated with new information.
1801
1802         * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
1803         (-[WebAVStreamDataParserListener streamDataParser:didParseStreamDataAsAsset:withDiscontinuity:]):
1804
1805 2014-01-23  Tim Horton  <timothy_horton@apple.com>
1806
1807         PDFPlugin: Use PDFPlugin even if there's an external plugin installed, if it's blocked
1808         https://bugs.webkit.org/show_bug.cgi?id=127415
1809         <rdar://problem/12482452>
1810
1811         Reviewed by Sam Weinig.
1812
1813         * English.lproj/Localizable.strings:
1814         * WebCore.exp.in:
1815         * platform/LocalizedStrings.cpp:
1816         (WebCore::useBlockedPlugInContextMenuTitle):
1817         * platform/LocalizedStrings.h:
1818         Add a localizable string for the generic case, where the client
1819         didn't provide a more specific string for the context menu item.
1820
1821 2014-01-23  peavo@outlook.com  <peavo@outlook.com>
1822
1823         [Curl] There is no way to specify cache folder.
1824         https://bugs.webkit.org/show_bug.cgi?id=125028
1825
1826         Reviewed by Brent Fulgham.
1827
1828         Fixed logical test, disc cache should be disabled if creating cache folder fails.
1829
1830         * platform/network/curl/CurlCacheManager.cpp:
1831         (WebCore::CurlCacheManager::setCacheDirectory):
1832
1833 2014-01-23  Brady Eidson  <beidson@apple.com>
1834
1835         Unreviewed build fix.
1836
1837         * WebCore.xcodeproj/project.pbxproj: Export the new header so WebKit can see it
1838
1839 2014-01-22  Brent Fulgham  <bfulgham@apple.com>
1840
1841         [Win] Update project and solution files for 64-bit builds
1842         https://bugs.webkit.org/show_bug.cgi?id=127457
1843
1844         Reviewed by Eric Carlson.
1845
1846         * WebCore.vcxproj/QTMovieWin/QTMovieWin.vcxproj: Update for VS2013
1847         * WebCore.vcxproj/WebCore.submit.sln: Add x64 targets
1848         * WebCore.vcxproj/WebCore.vcxproj: Update for VS2013. Also exclude 32-bit specific
1849         assembly when building 64-bit target.
1850         * WebCore.vcxproj/WebCore.vcxproj.filters: Update for VS2013
1851         * config.h: Handle 64-bit type definitions.
1852         * platform/graphics/ca/win/PlatformCAAnimationWin.cpp:
1853         (PlatformCAAnimation::setFromValue): Use CGFloat to support 64-bit builds
1854         (PlatformCAAnimation::setToValue): Ditto
1855         (PlatformCAAnimation::setValues): Ditto
1856         * platform/graphics/win/FontCustomPlatformData.cpp:
1857         (WebCore::FontCustomPlatformData::fontPlatformData): Add cast to
1858         support 32- and 64-bit targets.
1859         * platform/graphics/win/GraphicsContextCGWin.cpp:
1860         (WebCore::GraphicsContext::drawLineForDocumentMarker): Use CGFloat to
1861         support 64-bit builds.
1862         * platform/win/PasteboardWin.cpp:
1863         (WebCore::Pasteboard::writeURLToDataObject): Specialize std::min to
1864         work on 32- and 64-bit code.
1865         (WebCore::createGlobalImageFileDescriptor): Ditto
1866         * platform/win/StructuredExceptionHandlerSuppressor.cpp:
1867         (WebCore::StructuredExceptionHandlerSuppressor::StructuredExceptionHandlerSuppressor):
1868         Comment out 32-bit inline assembly.
1869         (WebCore::StructuredExceptionHandlerSuppressor::~StructuredExceptionHandlerSuppressor):
1870         Ditto
1871
1872 2014-01-23  Brady Eidson  <beidson@apple.com>
1873
1874         Make IDBGetResult work with IDBKeyData instead of IDBKey.
1875         https://bugs.webkit.org/show_bug.cgi?id=127493
1876
1877         Reviewed by Eric Carlson.
1878
1879         Also break it into its own header to work better with IPC messages.
1880
1881         * Modules/indexeddb/IDBGetResult.h: Added.
1882         (WebCore::IDBGetResult::IDBGetResult):
1883
1884         * Modules/indexeddb/IDBServerConnection.h:
1885
1886         * Modules/indexeddb/IDBTransactionBackendOperations.cpp:
1887         (WebCore::GetOperation::perform):
1888
1889         * WebCore.xcodeproj/project.pbxproj:
1890
1891 2014-01-23  Mátyás Mustoha  <mmatyas@inf.u-szeged.hu>
1892
1893         [curl] Add storage limit to cache manager
1894         https://bugs.webkit.org/show_bug.cgi?id=125779
1895
1896         Reviewed by Brent Fulgham.
1897
1898         Sets a local disc storage size limit for the cache manager
1899         used by the curl network backend.
1900
1901         * platform/network/curl/CurlCacheEntry.cpp:
1902         (WebCore::CurlCacheEntry::CurlCacheEntry):
1903         (WebCore::CurlCacheEntry::isCached):
1904         (WebCore::CurlCacheEntry::saveCachedData):
1905         (WebCore::CurlCacheEntry::readCachedData):
1906         (WebCore::CurlCacheEntry::didFail):
1907         (WebCore::CurlCacheEntry::didFinishLoading):
1908         (WebCore::CurlCacheEntry::loadFileToBuffer):
1909         (WebCore::CurlCacheEntry::parseResponseHeaders):
1910         (WebCore::CurlCacheEntry::entrySize):
1911         * platform/network/curl/CurlCacheEntry.h:
1912         (WebCore::CurlCacheEntry::requestHeaders):
1913         * platform/network/curl/CurlCacheManager.cpp:
1914         (WebCore::CurlCacheManager::CurlCacheManager):
1915         (WebCore::CurlCacheManager::setStorageSizeLimit):
1916         (WebCore::CurlCacheManager::loadIndex):
1917         (WebCore::CurlCacheManager::saveIndex):
1918         (WebCore::CurlCacheManager::makeRoomForNewEntry):
1919         (WebCore::CurlCacheManager::didReceiveResponse):
1920         (WebCore::CurlCacheManager::didReceiveData):
1921         (WebCore::CurlCacheManager::invalidateCacheEntry):
1922         (WebCore::CurlCacheManager::readCachedData):
1923         * platform/network/curl/CurlCacheManager.h:
1924         (WebCore::CurlCacheManager::cacheDirectory):
1925
1926 2014-01-23  Carlos Garcia Campos  <cgarcia@igalia.com>
1927
1928         Unreviewed. Fix automake warning.
1929
1930         * GNUmakefile.list.am: Remove trailing whitespaces.
1931
1932 2014-01-23  Mihai Maerean  <mmaerean@adobe.com>
1933
1934         [CSS Regions] Fix positioning composited layers when the region has overflow:hidden
1935         https://bugs.webkit.org/show_bug.cgi?id=124042
1936
1937         Reviewed by Mihnea Ovidenie.
1938
1939         If there's a clipping GraphicsLayer on the hierarchy, substract its offset, since it's its
1940         parent that positions us.
1941
1942         Tests: compositing/regions/position-layer-inside-region-overflow-hidden.html
1943                compositing/regions/position-layer-inside-overflow-hidden.html
1944                compositing/regions/position-layers-inside-region-overflow-hidden.html
1945                compositing/regions/position-layers-inside-regions-overflow-hidden.html
1946
1947         * rendering/RenderLayerBacking.cpp:
1948         (WebCore::RenderLayerBacking::adjustAncestorCompositingBoundsForFlowThread): The position
1949         must also be correct when the region has box-shadow that inflates the region's layer. The
1950         composited layers from the flow thread should be rendered in the same position whether the
1951         associated region has clipping or not.
1952         Using the position of the clipping layer instead of the location of the clipbox makes it
1953         also work with box-shadow that inflates the region's graphics layer.
1954
1955 2014-01-23  Andrei Bucur  <abucur@adobe.com>
1956
1957         [CSS Regions] Convert regions iterator loops to range-based loops
1958         https://bugs.webkit.org/show_bug.cgi?id=127464
1959
1960         Reviewed by Antti Koivisto.
1961
1962         Replace most of the iterator loops in the region implementation with
1963         range based for loops. The for loops that iterate only over subsets
1964         of collections have not been changed.
1965
1966         Tests: no new tests, this is a refactoring patch.
1967
1968         * dom/WebKitNamedFlow.cpp:
1969         (WebCore::WebKitNamedFlow::firstEmptyRegionIndex):
1970         (WebCore::WebKitNamedFlow::getRegionsByContent):
1971         (WebCore::WebKitNamedFlow::getRegions):
1972         (WebCore::WebKitNamedFlow::getContent):
1973         * inspector/InspectorOverlay.cpp:
1974         (WebCore::buildObjectForCSSRegionsHighlight):
1975         * rendering/RenderFlowThread.cpp:
1976         (WebCore::RenderFlowThread::validateRegions):
1977         (WebCore::RenderFlowThread::updateLogicalWidth):
1978         (WebCore::RenderFlowThread::computeLogicalHeight):
1979         (WebCore::RenderFlowThread::repaintRectangleInRegions):
1980         (WebCore::RenderFlowThread::removeRenderBoxRegionInfo):
1981         (WebCore::RenderFlowThread::logicalWidthChangedInRegionsForBlock):
1982         (WebCore::RenderFlowThread::clearRenderBoxRegionInfoAndCustomStyle):
1983         (WebCore::RenderFlowThread::isAutoLogicalHeightRegionsCountConsistent):
1984         (WebCore::RenderFlowThread::markAutoLogicalHeightRegionsForLayout):
1985         (WebCore::RenderFlowThread::markRegionsForOverflowLayoutIfNeeded):
1986         (WebCore::RenderFlowThread::updateRegionsFlowThreadPortionRect):
1987         (WebCore::RenderFlowThread::collectLayerFragments):
1988         (WebCore::RenderFlowThread::fragmentsBoundingBox):
1989         * rendering/RenderNamedFlowFragment.cpp:
1990         (WebCore::RenderNamedFlowFragment::setRegionObjectsRegionStyle):
1991         (WebCore::RenderNamedFlowFragment::restoreRegionObjectsOriginalStyle):
1992         * rendering/RenderNamedFlowThread.cpp:
1993         (WebCore::RenderNamedFlowThread::clearContentElements):
1994         (WebCore::RenderNamedFlowThread::nextRendererForNode):
1995         (WebCore::RenderNamedFlowThread::dependsOn):
1996         (WebCore::RenderNamedFlowThread::computeOversetStateForRegions):
1997         (WebCore::RenderNamedFlowThread::checkInvalidRegions):
1998         (WebCore::RenderNamedFlowThread::pushDependencies):
1999         (WebCore::RenderNamedFlowThread::registerNamedFlowContentElement):
2000         (WebCore::isContainedInElements):
2001         (WebCore::RenderNamedFlowThread::getRanges):
2002         (WebCore::RenderNamedFlowThread::checkRegionsWithStyling):
2003         (WebCore::RenderNamedFlowThread::clearRenderObjectCustomStyle):
2004         * rendering/RenderTreeAsText.cpp:
2005         (WebCore::writeRenderRegionList):
2006
2007 2014-01-23  László Langó  <llango.u-szeged@partner.samsung.com>
2008
2009         Range should be constructable.
2010         https://bugs.webkit.org/show_bug.cgi?id=115639
2011
2012         Reviewed by Ryosuke Niwa.
2013
2014         http://www.w3.org/TR/2013/WD-dom-20131107/#interface-range
2015         Now we can do `new Range()` instead of `document.createRange()`.
2016
2017         Backported from Blink: https://chromium.googlesource.com/chromium/blink/+/47ca40efdf58a4787aa33aa75a35778899b1c002%5E%21
2018
2019         Test: fast/dom/Range/range-constructor.html
2020
2021         * dom/Range.cpp:
2022         (WebCore::Range::create):
2023         * dom/Range.h:
2024         * dom/Range.idl:
2025
2026 2014-01-23  ChangSeok Oh  <changseok.oh@collabora.com>
2027
2028         Unreviewed build fix for gles after r162565. Add missing definitions.
2029
2030         * platform/graphics/opengl/GraphicsContext3DOpenGLES.cpp:
2031         (WebCore::GraphicsContext3D::drawArraysInstanced):
2032         (WebCore::GraphicsContext3D::drawElementsInstanced):
2033         (WebCore::GraphicsContext3D::vertexAttribDivisor):
2034
2035 2014-01-22  Carlos Garcia Campos  <cgarcia@igalia.com>
2036
2037         [GLIB] Use GUniquePtr instead of GOwnPtr
2038         https://bugs.webkit.org/show_bug.cgi?id=127431
2039
2040         Reviewed by Martin Robinson.
2041
2042         GUniquePtr is a template alias of std::unique_ptr with a custom
2043         deleter that replaces GOwnPtr. GOwnPtr is still used for the cases
2044         where the output pointer is needed, but it will also be replaced soon.
2045
2046         * GNUmakefile.list.am:
2047         * PlatformGTK.cmake:
2048         * accessibility/atk/AXObjectCacheAtk.cpp:
2049         * accessibility/atk/WebKitAccessibleInterfaceText.cpp:
2050         (getAttributeSetForAccessibilityObject):
2051         (accessibilityObjectLength):
2052         (textExtents):
2053         (webkitAccessibleTextGetChar):
2054         (numberOfReplacedElementsBeforeOffset):
2055         * page/ContextMenuController.cpp:
2056         * platform/SharedBuffer.h:
2057         * platform/audio/gstreamer/WebKitWebAudioSourceGStreamer.cpp:
2058         (webKitWebAudioSrcConstructed):
2059         (webKitWebAudioSrcLoop):
2060         * platform/audio/gtk/AudioBusGtk.cpp:
2061         (WebCore::AudioBus::loadPlatformResource):
2062         * platform/geoclue/GeolocationProviderGeoclue.cpp:
2063         * platform/graphics/gstreamer/ImageGStreamerCairo.cpp:
2064         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
2065         (WebCore::MediaPlayerPrivateGStreamer::setAudioStreamProperties):
2066         (WebCore::MediaPlayerPrivateGStreamer::handleMessage):
2067         * platform/graphics/gstreamer/WebKitMediaSourceGStreamer.cpp:
2068         (webKitMediaSrcAddSrc):
2069         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
2070         (webKitWebSrcStart):
2071         (ResourceHandleStreamingClient::wasBlocked):
2072         (ResourceHandleStreamingClient::cannotShowURL):
2073         * platform/graphics/gtk/ImageBufferGtk.cpp:
2074         (WebCore::encodeImage):
2075         (WebCore::ImageBuffer::toDataURL):
2076         * platform/graphics/gtk/ImageGtk.cpp:
2077         (WebCore::getThemeIconFileName):
2078         (WebCore::Image::loadPlatformResource):
2079         * platform/gtk/ContextMenuGtk.cpp:
2080         (WebCore::ContextMenu::itemCount):
2081         (WebCore::contextMenuItemVector):
2082         * platform/gtk/ContextMenuItemGtk.cpp:
2083         (WebCore::createPlatformMenuItemDescription):
2084         * platform/gtk/DataObjectGtk.cpp:
2085         (WebCore::DataObjectGtk::setURIList):
2086         (WebCore::DataObjectGtk::setURL):
2087         * platform/gtk/FileSystemGtk.cpp:
2088         (WebCore::filenameToString):
2089         (WebCore::fileSystemRepresentation):
2090         (WebCore::filenameForDisplay):
2091         (WebCore::pathGetFileName):
2092         (WebCore::applicationDirectoryPath):
2093         (WebCore::sharedResourcesPath):
2094         (WebCore::directoryName):
2095         (WebCore::listDirectory):
2096         (WebCore::openTemporaryFile):
2097         * platform/gtk/GOwnPtrGtk.cpp: Removed.
2098         * platform/gtk/GOwnPtrGtk.h: Removed.
2099         * platform/gtk/GUniquePtrGtk.h: Added.
2100         * platform/gtk/GamepadsGtk.cpp:
2101         (WebCore::GamepadsGtk::GamepadsGtk):
2102         * platform/gtk/GtkClickCounter.cpp:
2103         (WebCore::GtkClickCounter::shouldProcessButtonEvent):
2104         * platform/gtk/GtkInputMethodFilter.cpp:
2105         (WebCore::GtkInputMethodFilter::sendCompositionAndPreeditWithFakeKeyEvents):
2106         * platform/gtk/GtkPopupMenu.cpp:
2107         (WebCore::GtkPopupMenu::popUp):
2108         (WebCore::GtkPopupMenu::typeAheadFind):
2109         * platform/gtk/LanguageGtk.cpp:
2110         (WebCore::platformLanguage):
2111         * platform/gtk/LocalizedStringsGtk.cpp:
2112         (WebCore::imageTitle):
2113         (WebCore::localizedMediaTimeDescription):
2114         * platform/gtk/PasteboardHelper.cpp:
2115         (WebCore::selectionDataToUTF8String):
2116         (WebCore::PasteboardHelper::getClipboardContents):
2117         (WebCore::PasteboardHelper::fillSelectionData):
2118         * platform/gtk/PopupMenuGtk.cpp:
2119         (WebCore::PopupMenuGtk::createGtkActionForMenuItem):
2120         (WebCore::PopupMenuGtk::show):
2121         * platform/gtk/WebKitAuthenticationWidget.cpp:
2122         (webkitAuthenticationWidgetInitialize):
2123         * platform/network/ResourceHandleInternal.h:
2124         * platform/network/gtk/CredentialBackingStore.cpp:
2125         (WebCore::credentialForChallengeAsyncReadyCallback):
2126         * platform/network/soup/CookieJarSoup.cpp:
2127         (WebCore::setCookiesFromDOM):
2128         (WebCore::cookiesForSession):
2129         (WebCore::getRawCookies):
2130         (WebCore::deleteCookie):
2131         (WebCore::getHostnamesWithCookies):
2132         (WebCore::deleteCookiesForHostname):
2133         (WebCore::deleteAllCookies):
2134         * platform/network/soup/DNSSoup.cpp:
2135         * platform/network/soup/GUniquePtrSoup.h: Added.
2136         * platform/network/soup/ResourceErrorSoup.cpp:
2137         (WebCore::failingURI):
2138         * platform/network/soup/ResourceHandleSoup.cpp:
2139         (WebCore::ResourceHandle::ensureReadBuffer):
2140         (WebCore::cleanupSoupRequestOperation):
2141         (WebCore::createSoupRequestAndMessageForHandle):
2142         * platform/network/soup/ResourceRequestSoup.cpp:
2143         (WebCore::ResourceRequest::updateSoupMessageMembers):
2144         (WebCore::ResourceRequest::updateSoupMessage):
2145         * platform/network/soup/ResourceResponseSoup.cpp:
2146         * platform/network/soup/SoupURIUtils.cpp:
2147         (WebCore::soupURIToKURL):
2148         * platform/soup/SharedBufferSoup.cpp:
2149         (WebCore::SharedBuffer::SharedBuffer):
2150         (WebCore::SharedBuffer::clearPlatformData):
2151         (WebCore::SharedBuffer::maybeTransferPlatformData):
2152         (WebCore::SharedBuffer::hasPlatformData):
2153         * plugins/gtk/PluginPackageGtk.cpp:
2154         (WebCore::PluginPackage::fetchInfo):
2155         (WebCore::PluginPackage::load):
2156
2157 2014-01-22  Simon Fraser  <simon.fraser@apple.com>
2158
2159         Surround fixedVisibleContentRect code with USE(TILED_BACKING_STORE)
2160         https://bugs.webkit.org/show_bug.cgi?id=127461
2161
2162         Reviewed by Andreas Kling.
2163
2164         The "fixedVisibleContentRect" code path is only used by platforms
2165         which enabled TILED_BACKING_STORE, so to reduce confusion, surround
2166         this code with #if USE(TILED_BACKING_STORE).
2167
2168         * page/Frame.cpp:
2169         (WebCore::Frame::createView):
2170         * page/FrameView.cpp:
2171         * page/FrameView.h:
2172         * platform/ScrollView.cpp:
2173         (WebCore::ScrollView::unscaledVisibleContentSize):
2174         (WebCore::ScrollView::visibleContentRect):
2175         * platform/ScrollView.h:
2176         (WebCore::ScrollView::visibleSize):
2177
2178 2014-01-22  Myles C. Maxfield  <mmaxfield@apple.com>
2179
2180         ASSERTION FAILED: v.isFixed() in WebCore::RenderStyle::setWordSpacing
2181         https://bugs.webkit.org/show_bug.cgi?id=126987
2182
2183         Reviewed by Simon Fraser.
2184
2185         When "inherit" is specified and there is no parent, Length values have an "Auto" type
2186
2187         Test: fast/css3-text/css3-word-spacing-percentage/word-spacing-crash.html
2188
2189         * rendering/style/RenderStyle.cpp:
2190         (WebCore::RenderStyle::setWordSpacing):
2191
2192 2014-01-22  Samuel White  <samuel_white@apple.com>
2193
2194         AX: Can't always increment web sliders.
2195         https://bugs.webkit.org/show_bug.cgi?id=127451
2196
2197         Reviewed by Chris Fleizach.
2198
2199         Clamping the decrement/increment amount to one when necessary (if a percent change would result in a change of less than one).
2200
2201         Test: accessibility/range-alter-by-percent.html
2202
2203         * accessibility/AccessibilityNodeObject.cpp:
2204         (WebCore::AccessibilityNodeObject::changeValueByPercent):
2205
2206 2014-01-22  Myles C. Maxfield  <mmaxfield@apple.com>
2207
2208         Remove CSS3_TEXT_DECORATION define
2209         https://bugs.webkit.org/show_bug.cgi?id=127333
2210
2211         Reviewed by Simon Fraser.
2212
2213         This is required for unprefixing the text-decoration-* CSS properties.
2214
2215         No new tests are necessary becase the flag was already on by default.
2216
2217         * Configurations/FeatureDefines.xcconfig:
2218         * css/CSSComputedStyleDeclaration.cpp:
2219         (WebCore::renderTextDecorationSkipFlagsToCSSValue):
2220         (WebCore::ComputedStyleExtractor::propertyValue):
2221         * css/CSSParser.cpp:
2222         (WebCore::isColorPropertyID):
2223         (WebCore::CSSParser::parseValue):
2224         (WebCore::CSSParser::addTextDecorationProperty):
2225         (WebCore::CSSParser::parseTextUnderlinePosition):
2226         * css/CSSParser.h:
2227         * css/CSSPrimitiveValueMappings.h:
2228         (WebCore::CSSPrimitiveValue::operator TextUnderlinePosition):
2229         * css/CSSPropertyNames.in:
2230         * css/CSSValueKeywords.in:
2231         * css/DeprecatedStyleBuilder.cpp:
2232         (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
2233         * css/StylePropertyShorthand.cpp:
2234         (WebCore::webkitTextDecorationShorthand):
2235         (WebCore::shorthandForProperty):
2236         (WebCore::matchingShorthandsForLonghand):
2237         * css/StylePropertyShorthand.h:
2238         * css/StyleResolver.cpp:
2239         (WebCore::shouldApplyPropertyInParseOrder):
2240         (WebCore::isValidVisitedLinkProperty):
2241         (WebCore::StyleResolver::applyProperty):
2242         * platform/graphics/GraphicsContext.h:
2243         * platform/graphics/cairo/GraphicsContextCairo.cpp:
2244         (WebCore::GraphicsContext::setPlatformStrokeStyle):
2245         * platform/graphics/cg/GraphicsContextCG.cpp:
2246         (WebCore::GraphicsContext::platformInit):
2247         * platform/graphics/wince/GraphicsContextWinCE.cpp:
2248         (WebCore::createPen):
2249         * rendering/InlineFlowBox.cpp:
2250         (WebCore::InlineFlowBox::computeMaxLogicalTop):
2251         * rendering/InlineFlowBox.h:
2252         * rendering/InlineTextBox.cpp:
2253         (WebCore::textDecorationStyleToStrokeStyle):
2254         (WebCore::boundingBoxForAllActiveDecorations):
2255         (WebCore::InlineTextBox::paintDecoration):
2256         * rendering/RenderObject.cpp:
2257         (WebCore::decorationColor):
2258         * rendering/RootInlineBox.cpp:
2259         (WebCore::RootInlineBox::maxLogicalTop):
2260         * rendering/RootInlineBox.h:
2261         * rendering/style/RenderStyle.cpp:
2262         (WebCore::RenderStyle::changeRequiresRepaintIfTextOrBorderOrOutline):
2263         (WebCore::RenderStyle::colorIncludingFallback):
2264         (WebCore::RenderStyle::visitedDependentColor):
2265         * rendering/style/RenderStyle.h:
2266         * rendering/style/RenderStyleConstants.h:
2267         * rendering/style/StyleRareInheritedData.cpp:
2268         (WebCore::StyleRareInheritedData::StyleRareInheritedData):
2269         (WebCore::StyleRareInheritedData::operator==):
2270         * rendering/style/StyleRareInheritedData.h:
2271         * rendering/style/StyleRareNonInheritedData.cpp:
2272         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
2273         (WebCore::StyleRareNonInheritedData::operator==):
2274         * rendering/style/StyleRareNonInheritedData.h:
2275
2276 2014-01-22  Chris Fleizach  <cfleizach@apple.com>
2277
2278         AX: Do not return an accessible name for an object just because it has tabindex=0
2279         https://bugs.webkit.org/show_bug.cgi?id=126914
2280
2281         Reviewed by Mario Sanchez Prada.
2282
2283         WebKit has code to return an accessible name for any object that is "generically" focusable (ie. tabindex=0).
2284         This behavior, which is not supported in ARIA, has caused many problems for VoiceOver. Often VoiceOver will
2285         speak all the text underneath any type of group.
2286
2287         I think we need to revert this behavior and follow the ARIA spec more closely.
2288
2289         Test: accessibility/aria-describedby-ensures-visibility.html
2290
2291         * accessibility/AccessibilityNodeObject.cpp:
2292         (WebCore::AccessibilityNodeObject::visibleText):
2293         (WebCore::AccessibilityNodeObject::title):
2294
2295 2014-01-22  Brady Eidson  <beidson@apple.com>
2296
2297         The IDB backing store get() method shouldn't call IDB callbacks directly
2298         https://bugs.webkit.org/show_bug.cgi?id=127453
2299
2300         Reviewed by Beth Dakin.
2301
2302         * Modules/indexeddb/IDBServerConnection.h:
2303         (WebCore::IDBGetResult::IDBGetResult): Add a new structure to hold all of the
2304           possible results of a get() call.
2305
2306         * Modules/indexeddb/leveldb/IDBServerConnectionLevelDB.cpp:
2307         (WebCore::IDBServerConnectionLevelDB::get): Don't call IDBCallbacks directly.
2308           Instead, return the GetResult to the GetOperation which will make IDBCallbacks.
2309         * Modules/indexeddb/leveldb/IDBServerConnectionLevelDB.h:
2310
2311         * Modules/indexeddb/IDBTransactionBackendOperations.cpp:
2312         (WebCore::GetOperation::perform): Get all of the IDBGetResults in the completion callback
2313           make the appropriate IDBCallback.
2314         * Modules/indexeddb/IDBTransactionBackendOperations.h:
2315
2316 2014-01-22  Dean Jackson  <dino@apple.com>
2317
2318         Unreviewed attempt to fix 32-bit builds.
2319
2320         Use long long rather than GC3Dintptr.
2321
2322         * html/canvas/ANGLEInstancedArrays.cpp:
2323         (WebCore::ANGLEInstancedArrays::drawElementsInstancedANGLE):
2324         * html/canvas/ANGLEInstancedArrays.h:
2325         * html/canvas/WebGLRenderingContext.cpp:
2326         (WebCore::WebGLRenderingContext::drawElementsInstanced):
2327         * html/canvas/WebGLRenderingContext.h:
2328
2329 2014-01-21  Brady Eidson  <beidson@apple.com>
2330
2331         IDB: "Put" support
2332         <rdar://problem/15779643> and https://bugs.webkit.org/show_bug.cgi?id=127401
2333
2334         Reviewed by Alexey Proskuryakov.
2335
2336         Add persistent encode/decode for storage to the database:
2337         * Modules/indexeddb/IDBKey.cpp:
2338         (WebCore::IDBKey::encode):
2339         (WebCore::IDBKey::decode):
2340         * Modules/indexeddb/IDBKey.h:
2341
2342         Add a data class to represent IDBKey suitable for crossing IPC:
2343         * Modules/indexeddb/IDBKeyData.cpp: Added.
2344         (WebCore::IDBKeyData::IDBKeyData):
2345         (WebCore::IDBKeyData::maybeCreateIDBKey):
2346         (WebCore::IDBKeyData::isolatedCopy):
2347         * Modules/indexeddb/IDBKeyData.h: Added.
2348         (WebCore::IDBKeyData::IDBKeyData):
2349
2350         * platform/CrossThreadCopier.cpp:
2351         (WebCore::IDBKeyData>::copy):
2352         * platform/CrossThreadCopier.h:
2353
2354         * WebCore.exp.in:
2355         * WebCore.xcodeproj/project.pbxproj:
2356
2357 2014-01-22  Dean Jackson  <dino@apple.com>
2358
2359         [WebGL] Implement ANGLE_instanced_arrays
2360         https://bugs.webkit.org/show_bug.cgi?id=127257
2361
2362         Reviewed by Brent Fulgham.
2363
2364         Implement the instanced drawing WebGL extension,
2365         ANGLE_instanced_arrays. This is currently Mac-only,
2366         but should be portable to other platforms if their
2367         OpenGL exposes the functions. It's also done in a way
2368         that will make exposing it to WebGL2 simple.
2369
2370         Test: fast/canvas/webgl/angle-instanced-arrays.html
2371
2372         * CMakeLists.txt:
2373         * DerivedSources.cpp:
2374         * DerivedSources.make:
2375         * GNUmakefile.list.am:
2376         * WebCore.vcxproj/WebCore.vcxproj:
2377         * WebCore.vcxproj/WebCore.vcxproj.filters:
2378         * WebCore.xcodeproj/project.pbxproj:
2379         Add the new files to all the build systems.
2380
2381         * bindings/js/JSWebGLRenderingContextCustom.cpp:
2382         (WebCore::toJS): Link JS side to C++ side.
2383
2384         * html/canvas/ANGLEInstancedArrays.cpp: Added.
2385         (WebCore::ANGLEInstancedArrays::ANGLEInstancedArrays):
2386         * html/canvas/ANGLEInstancedArrays.h: Added.
2387         * html/canvas/ANGLEInstancedArrays.idl: Added.
2388         New boilerplate files that expose the extension methods.
2389
2390         * html/canvas/WebGLExtension.h: New extension enum.
2391
2392         * html/canvas/WebGLRenderingContext.cpp:
2393         (WebCore::WebGLRenderingContext::validateVertexAttributes): Add an optional
2394         parameter representing the number of instance primitives we are asked
2395         to draw. Use that for the draw count if looking at an instanced attribute.
2396         Also make sure we see at least one non-instanced attribute.
2397         (WebCore::WebGLRenderingContext::validateDrawArrays): Update this so it could
2398         be used from either drawArrays or drawArraysInstanced.
2399         (WebCore::WebGLRenderingContext::drawArrays):
2400         (WebCore::WebGLRenderingContext::validateDrawElements): Same here, now can be
2401         used by the instanced and non-instanced versions.
2402         (WebCore::WebGLRenderingContext::drawElements):
2403         (WebCore::WebGLRenderingContext::getExtension): Create and return the new extension.
2404         (WebCore::WebGLRenderingContext::getSupportedExtensions): Add new extension to the list.
2405         (WebCore::WebGLRenderingContext::getVertexAttrib): Intercept a query to the divisor
2406         attribute and return the value we kept in the state.
2407         (WebCore::WebGLRenderingContext::drawArraysInstanced): Call the GC3D method.
2408         (WebCore::WebGLRenderingContext::drawElementsInstanced): Ditto.
2409         (WebCore::WebGLRenderingContext::vertexAttribDivisor): Ditto.
2410
2411         * html/canvas/WebGLRenderingContext.h: Define the new methods and parameters.
2412
2413         * html/canvas/WebGLVertexArrayObjectOES.cpp:
2414         (WebCore::WebGLVertexArrayObjectOES::setVertexAttribDivisor): Keep a record of the
2415         divisor if we set it.
2416         * html/canvas/WebGLVertexArrayObjectOES.h:
2417         (WebCore::WebGLVertexArrayObjectOES::VertexAttribState::VertexAttribState):
2418
2419         * platform/graphics/GraphicsContext3D.h: New enum.
2420         * platform/graphics/mac/GraphicsContext3DMac.mm:
2421         (WebCore::GraphicsContext3D::drawArraysInstanced): The actual calls into OpenGL.
2422         (WebCore::GraphicsContext3D::drawElementsInstanced): Ditto.
2423         (WebCore::GraphicsContext3D::vertexAttribDivisor): Ditto.
2424
2425         * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp: Empty implementations
2426         for non-mac platforms.
2427
2428         * platform/graphics/ios/GraphicsContext3DIOS.h: Define the iOS names for the
2429         functions.
2430
2431 2014-01-22  Zalan Bujtas  <zalan@apple.com>
2432
2433         [CSS Shapes] shape-inside rectangle layout can fail
2434         https://bugs.webkit.org/show_bug.cgi?id=124784
2435
2436         Reviewed by Darin Adler.
2437
2438         Early subpixel rounding/flooring/ceiling can have unwanted
2439         side effect on the final pixel value. Delay pixel
2440         conversions as much as possible.
2441
2442         Existing test is changed to reflect subpixel functionality.
2443
2444         * rendering/shapes/RectangleShape.cpp:
2445         (WebCore::RectangleShape::firstIncludedIntervalLogicalTop):
2446
2447 2014-01-22  Jochen Eisinger  <jochen@chromium.org>
2448
2449         Add protocolIsInHTTPFamily for strings and use it where appropriate
2450         https://bugs.webkit.org/show_bug.cgi?id=127336
2451
2452         Reviewed by Alexey Proskuryakov.
2453
2454         * html/HTMLAnchorElement.cpp:
2455         (WebCore::HTMLAnchorElement::parseAttribute):
2456         * page/ContentSecurityPolicy.cpp:
2457         (WebCore::CSPSource::schemeMatches):
2458         * page/SecurityPolicy.cpp:
2459         (WebCore::SecurityPolicy::generateReferrerHeader):
2460         * platform/URL.cpp:
2461         (WebCore::protocolIsInHTTPFamily):
2462         * platform/URL.h:
2463
2464 2014-01-22  Zalan Bujtas  <zalan@apple.com>
2465
2466         Subpixel Layout: SimpleLineLayout needs more position rounding to match InlineFlowBox layout.
2467         https://bugs.webkit.org/show_bug.cgi?id=127404
2468
2469         Reviewed by Antti Koivisto.
2470
2471         In order to produce a CSS pixel perfect layout, SimpleLineLayout needs to
2472         round line positions to CSS (integral) position similarly to InlineFlowBox.
2473
2474         Existing tests cover it.
2475
2476         * rendering/SimpleLineLayoutResolver.h:
2477         (WebCore::SimpleLineLayout::RunResolver::Run::rect):
2478         (WebCore::SimpleLineLayout::RunResolver::Run::baseline):
2479
2480 2014-01-22  Joseph Pecoraro  <pecoraro@apple.com>
2481
2482         Unreviewed rollout of r162534, this caused inspector test failures.
2483
2484         * bindings/js/PageScriptDebugServer.cpp:
2485         (WebCore::PageScriptDebugServer::addListener):
2486         (WebCore::PageScriptDebugServer::removeListener):
2487         (WebCore::PageScriptDebugServer::recompileAllJSFunctions):
2488         (WebCore::PageScriptDebugServer::didRemoveLastListener):
2489         * bindings/js/PageScriptDebugServer.h:
2490         * bindings/js/ScriptDebugServer.cpp:
2491         (WebCore::ScriptDebugServer::ScriptDebugServer):
2492         (WebCore::ScriptDebugServer::recompileAllJSFunctionsSoon):
2493         (WebCore::ScriptDebugServer::recompileAllJSFunctionsTimerFired):
2494         * bindings/js/ScriptDebugServer.h:
2495         * bindings/js/WorkerScriptDebugServer.cpp:
2496         (WebCore::WorkerScriptDebugServer::addListener):
2497         (WebCore::WorkerScriptDebugServer::recompileAllJSFunctions):
2498         (WebCore::WorkerScriptDebugServer::removeListener):
2499         * inspector/InspectorProfilerAgent.cpp:
2500
2501 2014-01-22  peavo@outlook.com  <peavo@outlook.com>
2502
2503         Crashes in setTextForIterator
2504         https://bugs.webkit.org/show_bug.cgi?id=127424
2505
2506         Reviewed by Brent Fulgham.
2507
2508         * platform/text/icu/UTextProviderLatin1.cpp:
2509         (WebCore::uTextLatin1Clone): Provide correct buffer size in utext_setup function call.
2510         (WebCore::uTextLatin1Access): Give correct buffer size to memset call.
2511         (WebCore::openLatin1UTextProvider): Ditto.
2512
2513 2014-01-22  Jer Noble  <jer.noble@apple.com>
2514
2515         [Mac] MediaPlayerPrivateMediaSourceAVFObjC::load ASSERTs on lots of tests
2516         https://bugs.webkit.org/show_bug.cgi?id=127430
2517
2518         Reviewed by Eric Carlson.
2519
2520         When other registered media engines cannot load a URL, the engine selection
2521         will eventually pick MediaPlayerPrivateMediaSourceAVFObjC and ask it to load
2522         the URL. Instead of ASSERTing here, simply reject the URL by setting the
2523         network state to FormatError.
2524
2525         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
2526         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::load):
2527
2528 2014-01-22  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
2529
2530         [EFL][GTK] Get EFL and GTK compiling with ACCESSIBILITY disabled
2531         https://bugs.webkit.org/show_bug.cgi?id=127119
2532
2533         Reviewed by Mario Sanchez Prada.
2534
2535         At build time, the compiler was not able to determine which Timer's constructor to call in AXObjectCache when
2536         ACCESSIBILITY is not enabled, fixing that.
2537         Also guarding some members in AccessibilityObject that are only being used by EFL and GTK with ACCESSIBILITY.
2538
2539         * accessibility/AXObjectCache.h:
2540         (WebCore::AXObjectCache::AXObjectCache):
2541         * accessibility/AccessibilityObject.h:
2542
2543 2014-01-22  Peter Molnar  <pmolnar.u-szeged@partner.samsung.com>
2544
2545         Refactor calculation of hasRx and hasRy values in SVGPathData
2546         https://bugs.webkit.org/show_bug.cgi?id=127423
2547
2548         Reviewed by Darin Adler.
2549
2550         This is a follow-up on https://bugs.webkit.org/show_bug.cgi?id=127337
2551
2552         * rendering/svg/SVGPathData.cpp:
2553         (WebCore::updatePathFromRectElement):
2554
2555 2014-01-21  Joseph Pecoraro  <pecoraro@apple.com>
2556
2557         Web Inspector: Remove recompileAllJSFunctions timer in ScriptDebugServer
2558         https://bugs.webkit.org/show_bug.cgi?id=127409
2559
2560         Reviewed by Timothy Hatcher.
2561
2562         * bindings/js/ScriptDebugServer.h:
2563         * bindings/js/ScriptDebugServer.cpp:
2564         (WebCore::ScriptDebugServer::ScriptDebugServer):
2565         Remove m_recompileTimer and the recompile soon function.
2566         We can just recompile immediately in all existing cases.
2567
2568         * bindings/js/PageScriptDebugServer.h:
2569         * bindings/js/PageScriptDebugServer.cpp:
2570         (WebCore::PageScriptDebugServer::addListener):
2571         (WebCore::PageScriptDebugServer::removeListener):
2572         (WebCore::PageScriptDebugServer::recompileAllJSFunctions):
2573         (WebCore::PageScriptDebugServer::didAddFirstListener):
2574         (WebCore::PageScriptDebugServer::didRemoveLastListener):
2575         Add a "didAddFirstListener" to match "didRemoveLastListener".
2576         Only recompile functions when we attach the debugger and when
2577         we detach the last listener.
2578
2579         * bindings/js/WorkerScriptDebugServer.cpp:
2580         (WebCore::WorkerScriptDebugServer::addListener):
2581         (WebCore::WorkerScriptDebugServer::removeListener):
2582         (WebCore::WorkerScriptDebugServer::recompileAllJSFunctions):
2583         Same thing. Also rearrange the functions to read better.
2584
2585         * inspector/InspectorProfilerAgent.cpp:
2586         Use the direct recompile function instead of the removed "soon" version.
2587
2588 2014-01-22  Robert Sipka  <sipka@inf.u-szeged.hu>
2589
2590         [curl] Improve detecting and handling of SSL client certificate
2591         https://bugs.webkit.org/show_bug.cgi?id=125006
2592
2593         Reviewed by Brent Fulgham.
2594
2595         Add client certificate handling.
2596
2597         * platform/network/ResourceHandle.h:
2598         * platform/network/curl/ResourceError.h:
2599         (WebCore::ResourceError::hasSSLConnectError):
2600         * platform/network/curl/ResourceHandleCurl.cpp:
2601         (WebCore::ResourceHandle::setClientCertificateInfo):
2602         * platform/network/curl/ResourceHandleManager.cpp:
2603         (WebCore::ResourceHandleManager::initializeHandle):
2604         * platform/network/curl/SSLHandle.cpp:
2605         (WebCore::addAllowedClientCertificate):
2606         (WebCore::setSSLClientCertificate):
2607         * platform/network/curl/SSLHandle.h:
2608
2609 2014-01-22  Mihai Maerean  <mmaerean@adobe.com>
2610
2611         [CSS Regions] layerOwner in RenderNamedFlowFragment cannot return null
2612         https://bugs.webkit.org/show_bug.cgi?id=127343
2613
2614         Reviewed by Sam Weinig.
2615
2616         RenderNamedFlowFragment::layerOwner cannot return null because regions create stacking
2617         contexts which create layers.
2618
2619         No new tests, no functional change.
2620
2621         * rendering/RenderFlowThread.cpp:
2622         (WebCore::RenderFlowThread::hasCompositingRegionDescendant):
2623         * rendering/RenderLayer.cpp:
2624         (WebCore::RenderLayer::calculateClipRects):
2625         * rendering/RenderLayerBacking.cpp:
2626         (WebCore::RenderLayerBacking::adjustAncestorCompositingBoundsForFlowThread):
2627         * rendering/RenderLayerCompositor.cpp:
2628         (WebCore::RenderLayerCompositor::computeRegionCompositingRequirements):
2629         * rendering/RenderNamedFlowFragment.h:
2630
2631 2014-01-22  Antti Koivisto  <antti@apple.com>
2632
2633         Avoid unthrottled layer flushes triggered by RenderLayerCompositor::ensureRootLayer
2634         https://bugs.webkit.org/show_bug.cgi?id=127426
2635
2636         Reviewed by Anders Carlsson.
2637         
2638         * rendering/RenderLayerCompositor.cpp:
2639         (WebCore::RenderLayerCompositor::updateScrollLayerPosition):
2640         (WebCore::RenderLayerCompositor::frameViewDidScroll):
2641
2642             Factor scroll layer position update to a function.
2643
2644         (WebCore::RenderLayerCompositor::ensureRootLayer):
2645         
2646             Stop calling frameViewDidChangeSize/frameViewDidScroll. Instead call the relevent functions
2647             directly. This avoid unthrottled layer flush that is done when the view actually scrolls.
2648
2649         * rendering/RenderLayerCompositor.h:
2650
2651 2014-01-22  Mihai Tica  <mitica@adobe.com>
2652
2653         [CSS Background Blending] -webkit-background-blend-mode fails for certain SVG files
2654         https://bugs.webkit.org/show_bug.cgi?id=127350
2655
2656         Reviewed by Dirk Schulze.
2657
2658         The graphics context of the SVG inherits the blend mode set
2659         on the background layer. Fix consists in drawing the SVG
2660         in a transparency layer.
2661
2662         Test: css3/compositing/background-blend-mode-svg.html
2663
2664         * svg/graphics/SVGImage.cpp:
2665         (WebCore::SVGImage::draw): Begin a transparency layer if a blend mode is set.
2666
2667 2014-01-22  Antti Koivisto  <antti@apple.com>
2668
2669         Update overlay scrollbars in single pass
2670         https://bugs.webkit.org/show_bug.cgi?id=127289
2671
2672         Reviewed by Anders Carlsson.
2673
2674         * platform/ScrollView.cpp:
2675         (WebCore::ScrollView::updateScrollbars):
2676         
2677             Multi-pass scrollbar resolution is only needed for traditional scrollbars. Overlay scrollbars don't affect layout.
2678
2679 2014-01-22  Mihnea Ovidenie  <mihnea@adobe.com>
2680
2681         [CSSRegions] Incorrect layout of a region pseudo children
2682         https://bugs.webkit.org/show_bug.cgi?id=126146
2683
2684         Reviewed by David Hyatt.
2685
2686         Test: fast/regions/collapse-anonymous-region.html
2687
2688         A region behaviour, styled using -webkit-flow-from, is modeled using an anonymous
2689         block created to fragment the named flow content inside the region. We have to prevent
2690         the behaviour of anonymous children collapsing for this block to make sure that the
2691         region element children are still laid out properly when the region element becomes an ordinary
2692         element.
2693
2694         * rendering/RenderBlockFlow.h:
2695
2696 2014-01-21  Ryuan Choi  <ryuan.choi@samsung.com>
2697
2698         Remove unused "acceleratedCompositingForScrollableFramesEnabled" setting
2699         https://bugs.webkit.org/show_bug.cgi?id=127402
2700
2701         Reviewed by Anders Carlsson.
2702
2703         compositing/iframes/iframe-composited-scrolling.html is updated because
2704         there are no usages in WebCore.
2705
2706         * page/Settings.in:
2707
2708 2014-01-21  Alex Christensen  <achristensen@webkit.org>
2709
2710         Compile fix for using libsoup on Windows.
2711         https://bugs.webkit.org/show_bug.cgi?id=127377
2712
2713         Reviewed by Daniel Bates.
2714
2715         * platform/network/soup/ProxyResolverSoup.cpp:
2716         (soupProxyResolverWkSetProperty):
2717         (soupProxyResolverWkGetProperty):
2718         (soupProxyResolverWkGetProxyURISync):
2719         Replaced uint with unsigned.
2720
2721 2014-01-21  Daniel Bates  <dabates@apple.com>
2722
2723         Break up single assertion into two assertions in HTMLMediaElement::returnPlatformLayer()
2724
2725         Following up after <http://trac.webkit.org/changeset/162473>, we should break up
2726         the assertion into two assertions as suggested by Darin Adler. Separating the single
2727         assertion into two assertions makes it straightforward to determine the conjunct that
2728         failed among other benefits.
2729
2730         * html/HTMLMediaElement.cpp:
2731         (WebCore::HTMLMediaElement::parseAttribute):
2732
2733 2014-01-21  Brady Eidson  <beidson@apple.com>
2734
2735         The IDB backing store put() method shouldn't call IDB callbacks directly
2736         https://bugs.webkit.org/show_bug.cgi?id=127399
2737
2738         Reviewed by Beth Dakin.
2739
2740         Refactor the put() callback to take a resulting key or an error.
2741         * Modules/indexeddb/IDBServerConnection.h:
2742
2743         * Modules/indexeddb/IDBTransactionBackendOperations.cpp:
2744         (WebCore::PutOperation::perform): Call to the backing store, then perform the
2745           appropriate IDB callback whether a key or an error was returned.
2746         * Modules/indexeddb/IDBTransactionBackendOperations.h:
2747
2748         * Modules/indexeddb/leveldb/IDBServerConnectionLevelDB.cpp:
2749         (WebCore::IDBServerConnectionLevelDB::put): Don’t call IDB callbacks directly.
2750           Instead, pass the resulting key/error back to the PutOperation.
2751         * Modules/indexeddb/leveldb/IDBServerConnectionLevelDB.h:
2752
2753 2014-01-21  Jae Hyun Park  <jae.park@company100.net>
2754
2755         Use nullptr in HTMLCanvasElement
2756         https://bugs.webkit.org/show_bug.cgi?id=127388
2757
2758         Reviewed by Gyuyoung Kim.
2759
2760         * html/HTMLCanvasElement.cpp:
2761         (WebCore::HTMLCanvasElement::getContext):
2762         (WebCore::HTMLCanvasElement::drawingContext):
2763         (WebCore::HTMLCanvasElement::existingDrawingContext):
2764
2765 2014-01-21  László Langó  <llango.u-szeged@partner.samsung.com>
2766
2767         Assertion failure in Range::nodeWillBeRemoved
2768         https://bugs.webkit.org/show_bug.cgi?id=121694
2769
2770         Reviewed by Ryosuke Niwa.
2771
2772         Based on Blink a change: https://chromium.googlesource.com/chromium/blink/+/407c1d7b2c45974aa614b3f847ffe9e8fce205fa
2773
2774         This patch fix an assertion failure. Range::nodeWillBeRemoved() might
2775         be called with removed node in ContainerNode, when DOMNodeRemovedFromDocument
2776         event handler calls removeChild(), for node being removed.
2777
2778         Test: fast/dom/Range/remove-twice-crash.html
2779
2780         * dom/ContainerNode.cpp:
2781         (WebCore::ContainerNode::willRemoveChild):
2782         * dom/ContainerNode.h:
2783
2784 2014-01-21  Tim Horton  <timothy_horton@apple.com>
2785
2786         REGRESSION (r161580): Some PDFs render outside their <img>
2787         https://bugs.webkit.org/show_bug.cgi?id=127381
2788         <rdar://problem/15872168>
2789
2790         Reviewed by Simon Fraser.
2791
2792         * platform/graphics/cg/PDFDocumentImage.cpp:
2793         (WebCore::transformContextForPainting):
2794         Only try to make the scale uniform if it isn't already, and use the minimum
2795         of the two original scales when doing so, so that it is absolutely certain
2796         to fit inside space allocated for the image during layout.
2797
2798 2014-01-21  Simon Fraser  <simon.fraser@apple.com>
2799
2800         Remove #if PLATFORM(IOS) in various places around customFixedPositionLayoutRect() code
2801         https://bugs.webkit.org/show_bug.cgi?id=127373
2802
2803         Reviewed by Beth Dakin.
2804
2805         Instead of PLATFORM(IOS) #idefs at every call site for viewportConstrainedVisibleContentRect(),
2806         move the #ifdef inside viewportConstrainedVisibleContentRect().
2807         
2808         The one call site that needs special handling is RenderLayerBacking::updateCompositedBounds(),
2809         which needs to avoid clipping fixed layers to the custom fixed position rect, but instead to
2810         visibleContentRect() (which is really the document bounds on iOS). This ensures that the
2811         fixed layers aren't clipped when zooming out.
2812
2813         * page/FrameView.cpp:
2814         (WebCore::FrameView::viewportConstrainedVisibleContentRect):
2815         * rendering/RenderBoxModelObject.cpp:
2816         (WebCore::RenderBoxModelObject::stickyPositionOffset):
2817         * rendering/RenderLayerBacking.cpp:
2818         (WebCore::RenderLayerBacking::updateCompositedBounds):
2819         * rendering/RenderLayerCompositor.cpp:
2820         (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
2821         (WebCore::RenderLayerCompositor::computeFixedViewportConstraints):
2822         (WebCore::RenderLayerCompositor::computeStickyViewportConstraints):
2823
2824 2014-01-21  Andy Estes  <aestes@apple.com>
2825
2826         [iOS] Allow all clients to link against WebCore
2827         https://bugs.webkit.org/show_bug.cgi?id=127372
2828         
2829         Reviewed by Dan Bernstein.
2830
2831         * Configurations/WebCore.xcconfig:
2832
2833 2014-01-21  Bear Travis  <betravis@adobe.com>
2834
2835         [CSS Shapes] Preserve box-shape order when serializing shape values
2836         https://bugs.webkit.org/show_bug.cgi?id=127200
2837
2838         Reviewed by Dirk Schulze.
2839
2840         Convert the parsed shape-box pair to a CSSValueList rather than directly
2841         adding the box value to BasicShape. The CSSValueList preserves the
2842         shape-box ordering, and cleans up a little bit of the code shared between
2843         clip and shape values.
2844
2845         Modifying existing parsing tests.
2846
2847         * css/CSSComputedStyleDeclaration.cpp:
2848         (WebCore::shapePropertyValue): Factor out code common to generating shape
2849         values.
2850         (WebCore::ComputedStyleExtractor::propertyValue): Generate a CSSValueList when
2851         you have both a shape and a box.
2852         * css/CSSParser.cpp:
2853         (WebCore::CSSParser::parseBasicShapeAndOrBox): Factor out code common to clip
2854         paths and shape properties that parses the [basic-shape || box] syntax from
2855         the CSS Shapes spec.
2856         (WebCore::CSSParser::parseShapeProperty): Parse shape-box pairs as a CSSValueList.
2857         * css/DeprecatedStyleBuilder.cpp:
2858         (WebCore::ApplyPropertyShape::applyValue): Use the CSSValueList for shape-box pairs.
2859         * css/CSSValueList.h:
2860         (WebCore::CSSValueList::itemWithoutBoundsCheck): Add a const version.
2861         * page/animation/CSSPropertyAnimation.cpp:
2862         (WebCore::blendFunc): Specify a box when blending.
2863         * rendering/style/ShapeValue.h:
2864         (WebCore::ShapeValue::createShapeValue): Add a box parameter.
2865         (WebCore::ShapeValue::ShapeValue): Ditto.
2866
2867 2014-01-21  Daniel Bates  <dabates@apple.com>
2868
2869         Fix the iOS Simulator release build
2870
2871         Substitute ASSERT_UNUSED() for ASSERT() to resolve a compiler warning
2872         that the argument platformLayer is unused. The argument platformLayer
2873         is only used in the asserted condition, which isn't compiled in a
2874         release build; => the argument is unused in a release build.
2875
2876         * html/HTMLMediaElement.cpp:
2877         (WebCore::HTMLMediaElement::parseAttribute):
2878
2879 2014-01-21  Zoltan Horvath  <zoltan@webkit.org>
2880
2881         Since MidpointState is a class, it should behave like a class
2882         https://bugs.webkit.org/show_bug.cgi?id=127154
2883
2884         Reviewed by David Hyatt.
2885
2886         I modified MidpointState to behave like a class, updated the call sites also.
2887
2888         No new tests, no behavior change.
2889
2890         * platform/text/BidiResolver.h:
2891         (WebCore::MidpointState::reset):
2892         (WebCore::MidpointState::startIgnoringSpaces):
2893         (WebCore::MidpointState::stopIgnoringSpaces):
2894         (WebCore::MidpointState::midpoints):
2895         (WebCore::MidpointState::numMidpoints):
2896         (WebCore::MidpointState::currentMidpoint):
2897         (WebCore::MidpointState::incrementCurrentMidpoint):
2898         (WebCore::MidpointState::decreaseNumMidpoints):
2899         (WebCore::MidpointState::betweenMidpoints):
2900         (WebCore::MidpointState::setBetweenMidpoints):
2901         (WebCore::MidpointState::addMidpoint): Renamed from deprecatedAddMidpoint, since now
2902         its private, we no longer need to discourage callers from using it.
2903         * rendering/InlineIterator.h:
2904         (WebCore::IsolateTracker::addFakeRunIfNecessary):
2905         * rendering/RenderBlockLineLayout.cpp:
2906         (WebCore::RenderBlockFlow::appendRunsForObject):
2907         (WebCore::constructBidiRunsForLine):
2908         * rendering/line/BreakingContextInlineHeaders.h:
2909         (WebCore::checkMidpoints):
2910         * rendering/line/TrailingObjects.cpp:
2911         (WebCore::TrailingObjects::updateMidpointsForTrailingBoxes):
2912
2913 2014-01-21  Commit Queue  <commit-queue@webkit.org>
2914
2915         Unreviewed, rolling out r162452.
2916         http://trac.webkit.org/changeset/162452
2917         https://bugs.webkit.org/show_bug.cgi?id=127366
2918
2919         broke a few tests on all Mac WebKit1 bots (Requested by
2920         thorton on #webkit).
2921
2922         * WebCore.exp.in:
2923         * page/FocusController.cpp:
2924         (WebCore::FocusController::FocusController):
2925         (WebCore::FocusController::setFocused):
2926         (WebCore::FocusController::setActive):
2927         (WebCore::FocusController::setContentIsVisible):
2928         * page/FocusController.h:
2929         (WebCore::FocusController::isActive):
2930         (WebCore::FocusController::isFocused):
2931         * page/Page.cpp:
2932         (WebCore::Page::Page):
2933         (WebCore::Page::setIsInWindow):
2934         (WebCore::Page::setIsVisuallyIdle):
2935         (WebCore::Page::setIsVisible):
2936         (WebCore::Page::visibilityState):
2937         (WebCore::Page::hiddenPageCSSAnimationSuspensionStateChanged):
2938         * page/Page.h:
2939         (WebCore::Page::isVisible):
2940         (WebCore::Page::isInWindow):
2941
2942 2014-01-21  Chris Fleizach  <cfleizach@apple.com>
2943
2944         AX: Mac: Expose the visible text of a password field to AX
2945         https://bugs.webkit.org/show_bug.cgi?id=127353
2946
2947         Reviewed by Brent Fulgham.
2948
2949         The Mac platform should now expose the rendered value of password fields through AX.
2950
2951         Test: accessibility/password-field-value.html
2952
2953         * accessibility/AccessibilityRenderObject.cpp:
2954         (WebCore::AccessibilityRenderObject::textLength):
2955         (WebCore::AccessibilityRenderObject::passwordFieldValue):
2956
2957 2014-01-21  Robert Sipka  <sipka@inf.u-szeged.hu>
2958
2959         Support SSL error handling in case of synchronous job.
2960         https://bugs.webkit.org/show_bug.cgi?id=125301
2961
2962         Reviewed by Brent Fulgham.
2963
2964         Set ssl error informations for the users.
2965
2966         * platform/network/curl/ResourceHandleManager.cpp:
2967         (WebCore::ResourceHandleManager::dispatchSynchronousJob):
2968
2969 2014-01-21  Simon Fraser  <simon.fraser@apple.com>
2970
2971         Export systemTotalMemory() and systemMemoryLevel() for MobileSafari
2972         https://bugs.webkit.org/show_bug.cgi?id=127360
2973
2974         Reviewed by Andy Estes.
2975         
2976         MobileSafari inappropriately calls these WebCore functions directly,
2977         so export them.
2978
2979         * WebCore.exp.in:
2980
2981 2014-01-21  Simon Fraser  <simon.fraser@apple.com>
2982
2983         Clean up PLATFORM(IOS) code related to the custom fixed position layout rect
2984         https://bugs.webkit.org/show_bug.cgi?id=127362
2985
2986         Reviewed by Dave Hyatt.
2987
2988         Various platforms customize the rect used to layout position:fixed elements,
2989         and each modified RenderBox::availableLogicalHeight/WidthUsing() in different
2990         ways.
2991         
2992         Clean this up by adding RenderView::clientLogicalWidth/HeightForFixedPosition(),
2993         and moving the platform hacks into it.
2994
2995         * rendering/RenderBox.cpp:
2996         (WebCore::RenderBox::availableLogicalHeightUsing):
2997         (WebCore::RenderBox::containingBlockLogicalWidthForPositioned):
2998         (WebCore::RenderBox::containingBlockLogicalHeightForPositioned):
2999         * rendering/RenderView.cpp:
3000         (WebCore::RenderView::clientLogicalWidthForFixedPosition):
3001         (WebCore::RenderView::clientLogicalHeightForFixedPosition):
3002         * rendering/RenderView.h:
3003
3004 2014-01-21  Tamas Gergely  <tgergely.u-szeged@partner.samsung.com>
3005
3006         ASSERT(time.isFinite()) in SVGSMILElement::createInstanceTimesFromSyncbase
3007         <https://webkit.org/b/108184>
3008
3009         Reviewed by Philip Rogers.
3010
3011         In the case a SMILElement timing had a syncbase dependency on an indefinite value
3012         the assert were raised. The assert has been removed and a check has been added
3013         instead that prevents the addition of indefinite times to the time list.
3014
3015         Test: svg/animations/smil-syncbase-self-dependency.svg
3016
3017         * svg/animation/SVGSMILElement.cpp:
3018         (WebCore::SVGSMILElement::createInstanceTimesFromSyncbase):
3019           ASSERT removed.
3020
3021 2014-01-21  Tim Horton  <timothy_horton@apple.com>
3022
3023         Address late review naming comments after r162453.
3024
3025         * WebCore.xcodeproj/project.pbxproj:
3026         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
3027         * platform/graphics/mac/CALayerWebAdditions.h: Removed.
3028         * platform/graphics/mac/CALayerWebAdditions.mm: Removed.
3029         * platform/graphics/mac/WebCoreCALayerExtras.h: Added.
3030         * platform/graphics/mac/WebCoreCALayerExtras.mm: Added.
3031         (-[CALayer web_disableAllActions]):
3032
3033 2014-01-21  Tim Horton  <timothy_horton@apple.com>
3034
3035         Keep CALayer implicit animation disabling code in a single place
3036         https://bugs.webkit.org/show_bug.cgi?id=127355
3037
3038         Reviewed by Simon Fraser.
3039
3040         * WebCore.xcodeproj/project.pbxproj:
3041         Add CALayerWebAdditions.{h,mm}.
3042
3043         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
3044         (PlatformCALayerMac::commonInit):
3045         Remove nullActionsDictionary() and use [CALayer(WebAdditions) web_disableAllActions] instead.
3046
3047         * platform/graphics/mac/CALayerWebAdditions.h: Added.
3048         * platform/graphics/mac/CALayerWebAdditions.mm: Added.
3049         (-[CALayer web_disableAllActions]):
3050         Added. Disable all implicit actions on the layer.
3051
3052 2014-01-21  Gavin Barraclough  <barraclough@apple.com>
3053
3054         Change Page, FocusController to use ViewState
3055         https://bugs.webkit.org/show_bug.cgi?id=126533
3056
3057         Reviewed by Tim Horton.
3058
3059         These classes currently maintain a set of separate fields to represent the view state;
3060         combine these into a single field, and allow WebPage to send the combined update rather
3061         than individual changes.
3062
3063         Maintain existing interface for WebKit1 clients.
3064
3065         * WebCore.exp.in:
3066             - Added WebCore::setViewState, removed WebCore::setIsVisuallyIdle.
3067         * page/FocusController.cpp:
3068         (WebCore::FocusController::FocusController):
3069             - Initialize combined m_viewState.
3070         (WebCore::FocusController::setFocused):
3071             - Calls setViewState.
3072         (WebCore::FocusController::setFocusedInternal):
3073             - setFocused -> setFocusedInternal.
3074         (WebCore::FocusController::setViewState):
3075             - Added, update all ViewState flags.
3076         (WebCore::FocusController::setActive):
3077             - Calls setViewState.
3078         (WebCore::FocusController::setActiveInternal):
3079             - setActive -> setActiveInternal.
3080         (WebCore::FocusController::setContentIsVisible):
3081             - Calls setViewState.
3082         (WebCore::FocusController::setContentIsVisibleInternal):
3083             - setContentIsVisible -> setContentIsVisibleInternal.
3084         * page/FocusController.h:
3085         (WebCore::FocusController::isActive):
3086         (WebCore::FocusController::isFocused):
3087         (WebCore::FocusController::contentIsVisible):
3088             - Implemented in terms of ViewState.
3089         * page/Page.cpp:
3090         (WebCore::Page::Page):
3091             - Initialize using PageInitialViewState.
3092         (WebCore::Page::setIsInWindow):
3093             - Calls setViewState.
3094         (WebCore::Page::setIsInWindowInternal):
3095             - setIsInWindow -> setIsInWindowInternal.
3096         (WebCore::Page::setIsVisuallyIdleInternal):
3097             - setIsVisuallyIdle -> setIsVisuallyIdleInternal.
3098         (WebCore::Page::setViewState):
3099             - Added, update all ViewState flags, including FocusController.
3100         (WebCore::Page::setIsVisible):
3101             - Calls setViewState.
3102         (WebCore::Page::setIsVisibleInternal):
3103             - setIsVisible -> setIsVisibleInternal.
3104         (WebCore::Page::visibilityState):
3105             - m_isVisible -> isVisible()
3106         (WebCore::Page::hiddenPageCSSAnimationSuspensionStateChanged):
3107             - m_isVisible -> isVisible()
3108         * page/Page.h:
3109         (WebCore::Page::isVisible):
3110         (WebCore::Page::isInWindow):
3111             - Implemented in terms of ViewState.
3112         (WebCore::Page::scriptedAnimationsSuspended):
3113             - Combined member fields into ViewState::Flags.
3114
3115 2014-01-21  Lauro Neto  <lauro.neto@openbossa.org>
3116
3117         Remove PLATFORM(NIX) from WebCore
3118         https://bugs.webkit.org/show_bug.cgi?id=127299
3119
3120         Reviewed by Anders Carlsson.
3121
3122         * editing/Editor.cpp:
3123         (WebCore::Editor::cut):
3124         (WebCore::Editor::copy):
3125         (WebCore::Editor::copyImage):
3126         * editing/Editor.h:
3127         * html/HTMLCanvasElement.h:
3128         * loader/EmptyClients.h:
3129         * loader/FrameLoader.cpp:
3130         (WebCore::FrameLoader::defaultObjectContentType):
3131         * page/ChromeClient.h:
3132         * page/DragController.cpp:
3133         (WebCore::DragController::startDrag):
3134         * platform/Cursor.h:
3135         * platform/DragData.h:
3136         * platform/DragImage.h:
3137         * platform/FileSystem.h:
3138         * platform/LocalizedStrings.h:
3139         * platform/Widget.h:
3140         * platform/audio/FFTFrame.h:
3141         * platform/audio/HRTFElevation.cpp:
3142         * platform/cairo/WidgetBackingStore.h:
3143         * platform/graphics/ANGLEWebKitBridge.h:
3144         * platform/graphics/FontPlatformData.h:
3145         * platform/graphics/GLContext.cpp:
3146         (WebCore::GLContext::createContextForWindow):
3147         * platform/graphics/GLContext.h:
3148         * platform/graphics/GraphicsContext3D.h:
3149         * platform/graphics/GraphicsContext3DPrivate.cpp:
3150         (WebCore::GraphicsContext3DPrivate::GraphicsContext3DPrivate):
3151         * platform/graphics/OpenGLESShims.h:
3152         * platform/graphics/OpenGLShims.cpp:
3153         (WebCore::getProcAddress):
3154         * platform/graphics/OpenGLShims.h:
3155         * platform/graphics/PlatformLayer.h:
3156         * platform/graphics/freetype/FontPlatformDataFreeType.cpp:
3157         * platform/graphics/opengl/Extensions3DOpenGL.cpp:
3158         (WebCore::Extensions3DOpenGL::createVertexArrayOES):
3159         (WebCore::Extensions3DOpenGL::deleteVertexArrayOES):
3160         (WebCore::Extensions3DOpenGL::isVertexArrayOES):
3161         (WebCore::Extensions3DOpenGL::bindVertexArrayOES):
3162         (WebCore::Extensions3DOpenGL::supportsExtension):
3163         * platform/graphics/opengl/Extensions3DOpenGL.h:
3164         * platform/graphics/opengl/Extensions3DOpenGLCommon.cpp:
3165         * platform/graphics/opengl/Extensions3DOpenGLES.h:
3166         * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
3167         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
3168         (WebCore::GraphicsContext3D::reshape):
3169         * platform/graphics/opengl/TemporaryOpenGLSetting.cpp:
3170         * platform/graphics/texmap/TextureMapper.h:
3171         * platform/network/ResourceHandle.h:
3172         * plugins/PluginPackage.cpp:
3173         * plugins/PluginView.cpp:
3174         (WebCore::PluginView::PluginView):
3175         * plugins/PluginView.h:
3176         * plugins/PluginViewNone.cpp:
3177         * rendering/SimpleLineLayout.cpp:
3178         (WebCore::SimpleLineLayout::canUseFor):
3179
3180 2014-01-21  Eric Carlson  <eric.carlson@apple.com>
3181
3182         Add &lrm; &rlm; and &nbsp; to WebVTT parser
3183         https://bugs.webkit.org/show_bug.cgi?id=85112
3184
3185         Reviewed by Jer Noble.
3186
3187         No new tests, track-webvtt-tc022-entities.html was updated to test this.
3188
3189         * html/track/WebVTTTokenizer.cpp:
3190         (WebCore::WebVTTTokenizer::nextToken): Support RLM, LRM, and NBSP entities.
3191
3192 2014-01-21  Commit Queue  <commit-queue@webkit.org>
3193
3194         Unreviewed, rolling out r162354.
3195         http://trac.webkit.org/changeset/162354
3196         https://bugs.webkit.org/show_bug.cgi?id=127354
3197
3198         Appears to have broken accessibility in a non-trivial way
3199         (Requested by ap on #webkit).
3200
3201         * platform/ScrollView.cpp:
3202         (WebCore::ScrollView::updateScrollbars):
3203
3204 2014-01-21  Commit Queue  <commit-queue@webkit.org>
3205
3206         Unreviewed, rolling out r162445.
3207         http://trac.webkit.org/changeset/162445
3208         https://bugs.webkit.org/show_bug.cgi?id=127351
3209
3210         It broke the 32 bit GTK build (Requested by Ossy on #webkit).
3211
3212         * rendering/style/StyleRareInheritedData.cpp:
3213
3214 2014-01-21  László Langó  <llango.u-szeged@partner.samsung.com>
3215
3216         Wrong struct size when CSS_IMAGE_ORIENTATION and CSS3_TEXT_DECORATION are enabled.
3217         https://bugs.webkit.org/show_bug.cgi?id=127346
3218
3219         Efl build fix.
3220
3221         Reviewed by Csaba Osztrogonác.
3222
3223         * rendering/style/StyleRareInheritedData.cpp:
3224
3225 2014-01-21  Antti Koivisto  <antti@apple.com>
3226
3227         Delay initial layer flush during loading on all platforms
3228         https://bugs.webkit.org/show_bug.cgi?id=127347
3229
3230         Reviewed by Andreas Kling.
3231
3232         To reduce unnecessary repaints enable the same behaviour as iOS already has.
3233
3234         * rendering/RenderLayerCompositor.cpp:
3235         (WebCore::RenderLayerCompositor::RenderLayerCompositor):
3236         
3237             Set the initial state of m_layerFlushThrottlingEnabled correctly.
3238
3239         (WebCore::RenderLayerCompositor::scheduleLayerFlush):
3240         (WebCore::RenderLayerCompositor::startInitialLayerFlushTimerIfNeeded):
3241         * rendering/RenderLayerCompositor.h:
3242         
3243             Enable initial layer flush delay on all platforms.
3244
3245 2014-01-21  Mihai Tica  <mitica@adobe.com>
3246
3247         If you set a tiled cross-faded-image or a tiled gradient as
3248         a background layer, -webkit-background-blend-mode doesn't work.
3249         The problem consists in the blendMode parameter not being set
3250         for these specific drawing paths.
3251
3252         https://bugs.webkit.org/show_bug.cgi?id=126888
3253         Reviewed by Dirk Schulze.
3254
3255         Test: css3/compositing/background-blend-mode-tiled-layers.html
3256
3257         * platform/graphics/CrossfadeGeneratedImage.cpp:
3258         (WebCore::CrossfadeGeneratedImage::drawPattern): Add the blendMode parameter and pass it to ImageBuffer::drawPattern.
3259         * platform/graphics/GradientImage.cpp:
3260         (WebCore::GradientImage::drawPattern): Add the blendMode parameter and pass it to ImageBuffer::drawPattern.
3261         * platform/graphics/ImageBuffer.h: Add a BlendMode parameter to the drawPattern method.
3262         * platform/graphics/cairo/ImageBufferCairo.cpp:
3263         (WebCore::ImageBuffer::drawPattern): Add the default BlendMode parameter to the method declaration.
3264         * platform/graphics/cg/ImageBufferCG.cpp:
3265         (WebCore::ImageBuffer::drawPattern): Add and use the blendMode parameter for all the code paths.
3266         * platform/graphics/wince/ImageBufferWinCE.cpp:
3267         (WebCore::BufferedImage::drawPattern): Add the default BlendMode parameter to the method declaration.
3268
3269 2014-01-21  Gurpreet Kaur  <k.gurpreet@samsung.com>
3270
3271         The WebCore.vcxproj.filters doesnot apply
3272         https://bugs.webkit.org/show_bug.cgi?id=127338
3273
3274         Reviewed by Csaba Osztrogonác.
3275
3276         * WebCore.vcxproj/WebCore.vcxproj.filters:
3277         Modified the WebCore.vcxproj.filters so that it is applied when loading
3278         WebCore.vcxproj file.
3279
3280 2014-01-21  Peter Molnar  <pmolnar.u-szeged@partner.samsung.com>
3281
3282         Fix SVG animations which set rx or ry attributes
3283         https://bugs.webkit.org/show_bug.cgi?id=127337
3284
3285         Reviewed by Dirk Schulze.
3286
3287         Test: svg/stroke/animated-non-scaling-rxry.html
3288
3289         Merged from Blink: https://src.chromium.org/viewvc/blink?revision=152376&view=revision
3290
3291         * rendering/svg/RenderSVGRect.cpp:
3292         (WebCore::RenderSVGRect::updateShapeFromElement):
3293         * rendering/svg/SVGPathData.cpp:
3294         (WebCore::updatePathFromRectElement):
3295
3296 2014-01-21  Krzysztof Czech  <k.czech@samsung.com>
3297
3298         [ATK] Expose aria-flowto through ATK_RELATION_FLOWS_TO
3299         https://bugs.webkit.org/show_bug.cgi?id=127291
3300
3301         Reviewed by Mario Sanchez Prada.
3302
3303         Test: accessibility/aria-flowto.html
3304
3305         Expose aria-flowto through ATK_RELATION_FLOWS_TO according to
3306         http://www.w3.org/TR/wai-aria-implementation/#mapping_state-property
3307
3308         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
3309         (setAtkRelationSetFromCoreObject):
3310
3311 2014-01-20  Ryuan Choi  <ryuan.choi@samsung.com>
3312
3313         [CMAKE] Remove Nix from CMake scripts
3314         https://bugs.webkit.org/show_bug.cgi?id=127264
3315
3316         Reviewed by Anders Carlsson.
3317
3318         * CMakeLists.txt:
3319
3320 2014-01-20  Anders Carlsson  <andersca@apple.com>
3321
3322         Remove an unused PageGroup function
3323         https://bugs.webkit.org/show_bug.cgi?id=127327
3324
3325         Reviewed by Andreas Kling.
3326
3327         * WebCore.exp.in:
3328         * page/PageGroup.cpp:
3329         * page/PageGroup.h:
3330
3331 2014-01-20  Anders Carlsson  <andersca@apple.com>
3332
3333         Move user style sheet handling to UserContentController
3334         https://bugs.webkit.org/show_bug.cgi?id=127322
3335         <rdar://problem/15861296>
3336
3337         Reviewed by Andreas Kling.
3338
3339         * dom/DocumentStyleSheetCollection.cpp:
3340         (WebCore::DocumentStyleSheetCollection::updateInjectedStyleSheetCache):
3341         * page/PageGroup.cpp:
3342         (WebCore::PageGroup::addUserStyleSheetToWorld):
3343         (WebCore::PageGroup::removeUserStyleSheetFromWorld):
3344         (WebCore::PageGroup::removeUserStyleSheetsFromWorld):
3345         (WebCore::PageGroup::removeAllUserContent):
3346         * page/PageGroup.h:
3347         * page/UserContentController.cpp:
3348         (WebCore::UserContentController::addUserStyleSheet):
3349         (WebCore::UserContentController::removeUserStyleSheet):
3350         (WebCore::UserContentController::removeUserStyleSheets):
3351         (WebCore::UserContentController::removeAllUserContent):
3352         (WebCore::UserContentController::invalidateInjectedStyleSheetCacheInAllFrames):
3353         * page/UserContentController.h:
3354         (WebCore::UserContentController::userStyleSheets):
3355
3356 2014-01-20  Benjamin Poulain  <benjamin@webkit.org>
3357
3358         Add a nicer way to iterate over all the attributes of an element
3359         https://bugs.webkit.org/show_bug.cgi?id=127266
3360
3361         Reviewed by Geoffrey Garen.
3362
3363         When using Element::attributeAt() in a loop, the compiler had to generate two kinds of
3364         accessor:
3365         -If the element data is unique, the length and data comes from the attribute Vector.
3366         -If the element data is shared, the data comes from the tail of elementData itself.
3367
3368         The choice was done for every access, which caused the assembly to be a little
3369         hard to follow.
3370         This patch unify the data access by doing everything as a array pointer with offset (getting
3371         that data from Vector when necessary).
3372
3373         To make it easier to do the right thing, a new iterator was added so that range-based loops
3374         can replace all the faulty cases.
3375
3376         * css/SelectorChecker.cpp:
3377         (WebCore::anyAttributeMatches):
3378         * css/SelectorChecker.h:
3379         (WebCore::SelectorChecker::checkExactAttribute):
3380         * dom/DatasetDOMStringMap.cpp:
3381         (WebCore::DatasetDOMStringMap::getNames):
3382         (WebCore::DatasetDOMStringMap::item):
3383         (WebCore::DatasetDOMStringMap::contains):
3384         * dom/Element.cpp:
3385         (WebCore::Element::normalizeAttributes):
3386         (WebCore::Element::detachAllAttrNodesFromElement):
3387         (WebCore::Element::cloneAttributesFromElement):
3388         * dom/Element.h:
3389         (WebCore::Element::attributesIterator):
3390         * dom/ElementData.cpp:
3391         (WebCore::ElementData::isEquivalent):
3392         (WebCore::ElementData::findAttributeIndexByNameSlowCase):
3393         * dom/ElementData.h:
3394         (WebCore::AttributeConstIterator::AttributeConstIterator):
3395         (WebCore::AttributeConstIterator::operator*):
3396         (WebCore::AttributeConstIterator::operator->):
3397         (WebCore::AttributeConstIterator::operator++):
3398         (WebCore::AttributeConstIterator::operator==):
3399         (WebCore::AttributeConstIterator::operator!=):
3400         (WebCore::AttributeIteratorAccessor::AttributeIteratorAccessor):
3401         (WebCore::AttributeIteratorAccessor::begin):
3402         (WebCore::AttributeIteratorAccessor::end):
3403         (WebCore::ElementData::attributesIterator):
3404         * dom/Node.cpp:
3405         (WebCore::Node::isDefaultNamespace):
3406         (WebCore::Node::lookupNamespaceURI):
3407         (WebCore::Node::lookupNamespacePrefix):
3408         (WebCore::Node::compareDocumentPosition):
3409         * dom/StyledElement.cpp:
3410         (WebCore::StyledElement::makePresentationAttributeCacheKey):
3411         (WebCore::StyledElement::rebuildPresentationAttributeStyle):
3412         * editing/MarkupAccumulator.cpp:
3413         (WebCore::MarkupAccumulator::appendElement):
3414         * editing/markup.cpp:
3415         (WebCore::completeURLs):
3416         (WebCore::StyledMarkupAccumulator::appendElement):
3417         * html/HTMLEmbedElement.cpp:
3418         (WebCore::HTMLEmbedElement::parametersForPlugin):
3419         * html/HTMLObjectElement.cpp:
3420         (WebCore::HTMLObjectElement::parametersForPlugin):
3421         * inspector/DOMPatchSupport.cpp:
3422         (WebCore::DOMPatchSupport::innerPatchNode):
3423         (WebCore::DOMPatchSupport::createDigest):
3424         * inspector/InspectorDOMAgent.cpp:
3425         (WebCore::InspectorDOMAgent::setAttributesAsText):
3426         (WebCore::InspectorDOMAgent::buildArrayForElementAttributes):
3427         * inspector/InspectorNodeFinder.cpp:
3428         (WebCore::InspectorNodeFinder::matchesElement):
3429         * page/PageSerializer.cpp:
3430         (WebCore::isCharsetSpecifyingNode):
3431         * xml/XPathNodeSet.cpp:
3432         (WebCore::XPath::NodeSet::traversalSort):
3433         * xml/XPathStep.cpp:
3434         (WebCore::XPath::Step::nodesInAxis):
3435         * xml/parser/XMLDocumentParserLibxml2.cpp:
3436         (WebCore::XMLDocumentParser::XMLDocumentParser):
3437
3438 2014-01-20  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
3439
3440         Do refactor in collectGradientAttributes() and renderStyleForLengthResolve()
3441         https://bugs.webkit.org/show_bug.cgi?id=126869
3442
3443         Reviewed by Dirk Schulze.
3444
3445         Some SVG functions have done a first iteration by using a boolean flag. This is
3446         one of poor implementations. This patch fix it by extracting a logic into a new method.
3447         Additionally it would be good to use do-while() loop instead of using while() in
3448         renderStyleForLengthResolving() because a first condition is always true.
3449
3450         Merge r165358 from blink.
3451
3452         * svg/SVGLengthContext.cpp:
3453         (WebCore::renderStyleForLengthResolving):
3454         * svg/SVGLinearGradientElement.cpp:
3455         (WebCore::setGradientAttributes):
3456         (WebCore::SVGLinearGradientElement::collectGradientAttributes):
3457         * svg/SVGRadialGradientElement.cpp:
3458         (WebCore::setGradientAttributes):
3459         (WebCore::SVGRadialGradientElement::collectGradientAttributes):
3460
3461 2014-01-20  Anders Carlsson  <andersca@apple.com>
3462
3463         UserContentController should keep track of user scripts
3464         https://bugs.webkit.org/show_bug.cgi?id=127317
3465         <rdar://problem/15861296>
3466
3467         Reviewed by Andreas Kling.
3468
3469         Move handling of user scripts from PageGroup to UserContentController.
3470
3471         * page/Frame.cpp:
3472         (WebCore::Frame::injectUserScripts):
3473         * page/PageGroup.cpp:
3474         (WebCore::PageGroup::addUserScriptToWorld):
3475         (WebCore::PageGroup::removeUserScriptFromWorld):
3476         (WebCore::PageGroup::removeUserScriptsFromWorld):
3477         (WebCore::PageGroup::removeAllUserContent):
3478         * page/PageGroup.h:
3479         * page/UserContentController.cpp:
3480         (WebCore::UserContentController::addUserScript):
3481         (WebCore::UserContentController::removeUserScript):
3482         (WebCore::UserContentController::removeUserScripts):
3483         (WebCore::UserContentController::removeAllUserContent):
3484         * page/UserContentController.h:
3485         (WebCore::UserContentController::userScripts):
3486
3487 2014-01-20  Anders Carlsson  <andersca@apple.com>
3488
3489         Give each page a UserContentController
3490         https://bugs.webkit.org/show_bug.cgi?id=127315
3491         <rdar://problem/15861296>
3492
3493         Reviewed by Andreas Kling.
3494
3495         Add a UserContentController object to PageGroup and have the page group set it on any
3496         pages that are added to the page group.
3497
3498         This is another step towards moving handling of user content away from PageGroup and make it
3499         possible for each page to have different user content.
3500
3501         * page/Page.cpp:
3502         (WebCore::Page::~Page):
3503         (WebCore::Page::setUserContentController):
3504         * page/Page.h:
3505         (WebCore::Page::userContentController):
3506         * page/PageGroup.cpp:
3507         (WebCore::PageGroup::PageGroup):
3508         (WebCore::PageGroup::addPage):
3509         (WebCore::PageGroup::removePage):
3510         * page/PageGroup.h:
3511         * page/UserContentController.cpp:
3512         (WebCore::UserContentController::addPage):
3513         (WebCore::UserContentController::removePage):
3514         * page/UserContentController.h:
3515
3516 2014-01-20  Jeremy Jones  <jeremyj@apple.com>
3517
3518         Add AVKit fullscreen video interface.
3519         https://bugs.webkit.org/show_bug.cgi?id=126818
3520
3521         Reviewed by Eric Carlson.
3522
3523         No new tests, no observable change in functionality.
3524
3525         * WebCore.exp.in:
3526         * WebCore.xcodeproj/project.pbxproj:
3527         * html/HTMLMediaElement.cpp:
3528         (WebCore::HTMLMediaElement::parseAttribute):
3529         * html/HTMLMediaElement.h:
3530         Add ability for fullscreen to borrow the AVPlayerLayer.
3531         * page/Settings.cpp:
3532         * page/Settings.h:
3533         (WebCore::Settings::setMediaPlaybackFullscreenAVKit):
3534         (WebCore::Settings::mediaPlaybackFullscreenAVKit):
3535         Add a disabled setting.
3536         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
3537         (WebCore::MediaPlayerPrivateAVFoundation::supportsFullscreen):
3538         Enabled fullscreen for iOS.
3539         * platform/ios/WebVideoFullscreenControllerAVKit.h: Added.
3540         * platform/ios/WebVideoFullscreenControllerAVKit.mm: Added.
3541         (-[WebAVPlayerController init]):
3542         (-[WebAVPlayerController dealloc]):
3543         (-[WebAVPlayerController forwardingTargetForSelector:]):
3544         (-[WebAVPlayerController shouldDismissForDone]):
3545         (-[WebAVPlayerController play:]):
3546         (-[WebAVPlayerController pause:]):
3547         (-[WebAVPlayerController togglePlayback:]):
3548         (-[WebAVPlayerController isPlaying]):
3549         (-[WebAVPlayerController setPlaying:]):
3550         (+[WebAVPlayerController keyPathsForValuesAffectingPlaying]):
3551         (-[WebAVPlayerController seekToTime:]):
3552         (-[WebAVPlayerController updateTimingWithCurrentTime:]):
3553         (-[WebAVPlayerController effectiveRate]):
3554         (-[WebAVPlayerController setMediaElement:]):
3555         (-[WebAVPlayerController handleEvent:]):
3556         (-[WebVideoFullscreenController init]):
3557         (-[WebVideoFullscreenController dealloc]):
3558         (-[WebVideoFullscreenController setMediaElement:]):
3559         (-[WebVideoFullscreenController mediaElement]):
3560         (-[WebVideoFullscreenController enterFullscreen:]):
3561         (-[WebVideoFullscreenController exitFullscreen]):
3562         Add WebAVPlayerController for HTMLMediaElememt to interface with AVPlayerViewController.
3563
3564 2014-01-20  Zan Dobersek  <zdobersek@igalia.com>
3565
3566         Replace uses of std::forward<T>(), std::unique_ptr<T>::clear() that landed in r162368
3567         https://bugs.webkit.org/show_bug.cgi?id=127306
3568
3569         Reviewed by Darin Adler.
3570
3571         Address the post-landing reviews of the r162368 commit that moved WebAudio source code to using std::unique_ptr.
3572         std::move() should be used instead of std::forward<T>() in HRTFKernel::create().
3573         Instead of calling std::unique_ptr<T>::reset(), nullptr should be assigned to that smart pointer to reset it.
3574
3575         * Modules/webaudio/ConvolverNode.cpp:
3576         (WebCore::ConvolverNode::uninitialize):
3577         * Modules/webaudio/DynamicsCompressorNode.cpp:
3578         (WebCore::DynamicsCompressorNode::uninitialize):
3579         * Modules/webaudio/MediaElementAudioSourceNode.cpp:
3580         (WebCore::MediaElementAudioSourceNode::setFormat):
3581         * Modules/webaudio/PannerNode.cpp:
3582         (WebCore::PannerNode::uninitialize):
3583         * platform/audio/AudioChannel.h:
3584         (WebCore::AudioChannel::set):
3585         * platform/audio/HRTFDatabaseLoader.cpp:
3586         (WebCore::HRTFDatabaseLoader::~HRTFDatabaseLoader):
3587         * platform/audio/HRTFKernel.h:
3588         (WebCore::HRTFKernel::create):
3589
3590 2014-01-20  Joseph Pecoraro  <pecoraro@apple.com>
3591
3592         Modernize WebCore/inspector with nullptr
3593         https://bugs.webkit.org/show_bug.cgi?id=127303
3594
3595         Reviewed by Anders Carlsson.
3596
3597         Ran clang-modernize -use-nullptr over WebCore/inspector.
3598
3599         * inspector/ConsoleMessage.cpp:
3600         (WebCore::ConsoleMessage::ConsoleMessage):
3601         * inspector/ConsoleMessage.h:
3602         * inspector/ContentSearchUtils.cpp:
3603         (WebCore::ContentSearchUtils::findMagicComment):
3604         * inspector/DOMEditor.cpp:
3605         (WebCore::DOMEditor::SetOuterHTMLAction::SetOuterHTMLAction):
3606         * inspector/DOMPatchSupport.cpp:
3607         (WebCore::DOMPatchSupport::patchDocument):
3608         (WebCore::DOMPatchSupport::patchNode):
3609         (WebCore::DOMPatchSupport::diff):
3610         (WebCore::DOMPatchSupport::innerPatchChildren):
3611         * inspector/InspectorApplicationCacheAgent.cpp:
3612         (WebCore::InspectorApplicationCacheAgent::willDestroyFrontendAndBackend):
3613         (WebCore::InspectorApplicationCacheAgent::assertFrameWithDocumentLoader):
3614         * inspector/InspectorCanvasAgent.cpp:
3615         (WebCore::InspectorCanvasAgent::disable):
3616         (WebCore::InspectorCanvasAgent::notifyRenderingContextWasWrapped):
3617         (WebCore::InspectorCanvasAgent::frameNavigated):
3618         * inspector/InspectorConsoleAgent.cpp:
3619         (WebCore::InspectorConsoleAgent::InspectorConsoleAgent):
3620         (WebCore::InspectorConsoleAgent::~InspectorConsoleAgent):
3621         (WebCore::InspectorConsoleAgent::clearMessages):
3622         (WebCore::InspectorConsoleAgent::didFinishXHRLoading):
3623         (WebCore::InspectorConsoleAgent::didReceiveResponse):
3624         (WebCore::InspectorConsoleAgent::didFailLoading):
3625         * inspector/InspectorConsoleAgent.h:
3626         * inspector/InspectorController.cpp:
3627         (WebCore::InspectorController::inspectedPageDestroyed):
3628         * inspector/InspectorDOMDebuggerAgent.cpp:
3629         (WebCore::InspectorDOMDebuggerAgent::disable):
3630         (WebCore::InspectorDOMDebuggerAgent::discardAgent):
3631         * inspector/InspectorDOMStorageAgent.cpp:
3632         (WebCore::InspectorDOMStorageAgent::~InspectorDOMStorageAgent):
3633         (WebCore::InspectorDOMStorageAgent::setDOMStorageItem):
3634         (WebCore::InspectorDOMStorageAgent::removeDOMStorageItem):
3635         (WebCore::InspectorDOMStorageAgent::findStorageArea):
3636         * inspector/InspectorDatabaseAgent.cpp:
3637         (WebCore::InspectorDatabaseAgent::~InspectorDatabaseAgent):
3638         (WebCore::InspectorDatabaseAgent::findByFileName):
3639         (WebCore::InspectorDatabaseAgent::databaseForId):
3640         * inspector/InspectorDebuggerAgent.cpp:
3641         (WebCore::InspectorDebuggerAgent::addMessageToConsole):
3642         (WebCore::InspectorDebuggerAgent::resolveBreakpoint):
3643         (WebCore::InspectorDebuggerAgent::didParseSource):
3644         (WebCore::InspectorDebuggerAgent::didContinue):
3645         (WebCore::InspectorDebuggerAgent::clearBreakDetails):
3646         * inspector/InspectorFrontendHost.cpp:
3647         (WebCore::FrontendMenuProvider::disconnect):
3648         (WebCore::InspectorFrontendHost::InspectorFrontendHost):
3649         (WebCore::InspectorFrontendHost::disconnectClient):
3650         * inspector/InspectorHeapProfilerAgent.cpp:
3651         (WebCore::InspectorHeapProfilerAgent::~InspectorHeapProfilerAgent):
3652         * inspector/InspectorIndexedDBAgent.cpp:
3653         (WebCore::assertDocument):
3654         (WebCore::assertIDBFactory):
3655         (WebCore::InspectorIndexedDBAgent::requestData):
3656         * inspector/InspectorInstrumentation.cpp:
3657         (WebCore::frameForScriptExecutionContext):
3658         (WebCore::InspectorInstrumentation::willDispatchEventOnWindowImpl):
3659         (WebCore::InspectorInstrumentation::didReceiveResourceResponseButCanceledImpl):
3660         (WebCore::InspectorInstrumentation::consoleAgentEnabled):
3661         (WebCore::InspectorInstrumentation::unregisterInstrumentingAgents):
3662         (WebCore::InspectorInstrumentation::retrieveTimelineAgent):
3663         (WebCore::InspectorInstrumentation::instrumentingAgentsForPage):
3664         (WebCore::InspectorInstrumentation::instrumentingAgentsForWorkerGlobalScope):
3665         (WebCore::InspectorInstrumentation::instrumentingAgentsForNonDocumentContext):
3666         * inspector/InspectorInstrumentation.h:
3667         (WebCore::InspectorInstrumentation::instrumentingAgentsForContext):
3668         (WebCore::InspectorInstrumentation::instrumentingAgentsForFrame):
3669         (WebCore::InspectorInstrumentation::instrumentingAgentsForDocument):
3670         * inspector/InspectorLayerTreeAgent.cpp:
3671         (WebCore::InspectorLayerTreeAgent::disable):
3672         * inspector/InspectorNodeFinder.cpp:
3673         (WebCore::InspectorNodeFinder::searchUsingXPath):
3674         * inspector/InspectorOverlay.cpp:
3675         (WebCore::buildObjectForElementInfo):
3676         * inspector/InspectorPageAgent.cpp:
3677         (WebCore::InspectorPageAgent::cachedResourceContent):
3678         (WebCore::InspectorPageAgent::sharedBufferContent):
3679         (WebCore::InspectorPageAgent::disable):
3680         (WebCore::InspectorPageAgent::frameForId):
3681         (WebCore::InspectorPageAgent::findFrameWithSecurityOrigin):
3682         * inspector/InspectorProfilerAgent.cpp:
3683         (WebCore::InspectorProfilerAgent::~InspectorProfilerAgent):
3684         * inspector/InspectorProfilerAgent.h:
3685         * inspector/InspectorResourceAgent.cpp:
3686         (WebCore::buildObjectForResourceResponse):
3687         (WebCore::InspectorResourceAgent::willSendRequest):
3688         (WebCore::InspectorResourceAgent::didReceiveResponse):
3689         (WebCore::InspectorResourceAgent::didFinishLoading):
3690         (WebCore::InspectorResourceAgent::didFailLoading):
3691         (WebCore::InspectorResourceAgent::didLoadResourceFromMemoryCache):
3692         (WebCore::InspectorResourceAgent::disable):
3693         * inspector/InspectorRuntimeAgent.cpp:
3694         (WebCore::InspectorRuntimeAgent::InspectorRuntimeAgent):
3695         * inspector/InspectorStyleSheet.cpp:
3696         (ParsedStyleSheet::ruleSourceDataAt):
3697         (WebCore::buildSourceRangeObject):
3698         (WebCore::asCSSRuleList):
3699         (WebCore::fillMediaListChain):
3700         (WebCore::InspectorStyle::setPropertyText):
3701         (WebCore::InspectorStyle::populateAllProperties):
3702         (WebCore::InspectorStyle::extractSourceData):
3703         (WebCore::InspectorStyle::newLineAndWhitespaceDelimiters):
3704         (WebCore::InspectorStyleSheet::addRule):
3705         (WebCore::InspectorStyleSheet::ruleForId):
3706         (WebCore::InspectorStyleSheet::buildObjectForStyleSheet):
3707         (WebCore::InspectorStyleSheet::buildObjectForStyleSheetInfo):
3708         (WebCore::InspectorStyleSheet::buildObjectForRule):
3709         (WebCore::InspectorStyleSheet::styleForId):
3710         (WebCore::InspectorStyleSheet::inspectorStyleForId):
3711         (WebCore::InspectorStyleSheetForInlineStyle::InspectorStyleSheetForInlineStyle):
3712         * inspector/InspectorStyleSheet.h:
3713         (WebCore::InspectorCSSId::asProtocolValue):
3714         * inspector/InspectorTimelineAgent.cpp:
3715         (WebCore::InspectorTimelineAgent::stop):
3716         (WebCore::InspectorTimelineAgent::willComposite):
3717         (WebCore::InspectorTimelineAgent::page):
3718         * inspector/InspectorWorkerAgent.cpp:
3719         (WebCore::InspectorWorkerAgent::~InspectorWorkerAgent):
3720         * inspector/InstrumentingAgents.cpp:
3721         (WebCore::InstrumentingAgents::InstrumentingAgents):
3722         (WebCore::InstrumentingAgents::reset):
3723         * inspector/NetworkResourcesData.cpp:
3724         (WebCore::NetworkResourcesData::ResourceData::ResourceData):
3725         (WebCore::NetworkResourcesData::xhrReplayData):
3726         (WebCore::NetworkResourcesData::removeCachedResource):
3727         (WebCore::NetworkResourcesData::resourceDataForRequestId):
3728         * inspector/PageConsoleAgent.cpp:
3729         (WebCore::PageConsoleAgent::~PageConsoleAgent):
3730         * inspector/PageDebuggerAgent.cpp:
3731         (WebCore::PageDebuggerAgent::disable):
3732         * inspector/PageRuntimeAgent.cpp:
3733         (WebCore::PageRuntimeAgent::~PageRuntimeAgent):
3734         (WebCore::PageRuntimeAgent::didCreateMainWorldContext):
3735         (WebCore::PageRuntimeAgent::reportExecutionContextCreation):
3736         * inspector/ScriptArguments.cpp:
3737         (WebCore::ScriptArguments::globalState):
3738         * inspector/WorkerRuntimeAgent.cpp:
3739         (WebCore::WorkerRuntimeAgent::~WorkerRuntimeAgent):
3740
3741 2014-01-20  Anders Carlsson  <andersca@apple.com>
3742
3743         Add empty UserContentController class
3744         https://bugs.webkit.org/show_bug.cgi?id=127300
3745         <rdar://problem/15861296>
3746
3747         Reviewed by Dan Bernstein.
3748
3749         This is the first step towards moving handling of user scripts and style sheets from
3750         the page group to a separate objects and ultimately make them be settable per page instead of per page group.
3751
3752         * CMakeLists.txt:
3753         * GNUmakefile.list.am:
3754         * WebCore.vcxproj/WebCore.vcxproj:
3755         * WebCore.vcxproj/WebCore.vcxproj.filters:
3756         * WebCore.xcodeproj/project.pbxproj:
3757         * page/UserContentController.cpp: Added.
3758         (WebCore::UserContentController::create):
3759         (WebCore::UserContentController::UserContentController):
3760         (WebCore::UserContentController::~UserContentController):
3761         * page/UserContentController.h: Added.
3762
3763 2014-01-20  Joseph Pecoraro  <pecoraro@apple.com>
3764
3765         Run clang-modernize and let it add a bunch of missing overrides in WebCore/inspector
3766         https://bugs.webkit.org/show_bug.cgi?id=127206
3767
3768         Reviewed by Anders Carlsson.
3769
3770         Let clang-modernize add overrides.
3771
3772         * inspector/DOMEditor.cpp:
3773         * inspector/InspectorApplicationCacheAgent.h:
3774         * inspector/InspectorCSSAgent.h:
3775         * inspector/InspectorCanvasAgent.h:
3776         * inspector/InspectorConsoleAgent.h:
3777         * inspector/InspectorDOMAgent.h:
3778         * inspector/InspectorDOMDebuggerAgent.h:
3779         * inspector/InspectorDOMStorageAgent.h:
3780         * inspector/InspectorDatabaseAgent.cpp:
3781         * inspector/InspectorDatabaseAgent.h:
3782         * inspector/InspectorDebuggerAgent.h:
3783         * inspector/InspectorFrontendHost.cpp:
3784         * inspector/InspectorHeapProfilerAgent.cpp:
3785         (WebCore::InspectorHeapProfilerAgent::getHeapSnapshot):
3786         (WebCore::InspectorHeapProfilerAgent::takeHeapSnapshot):
3787         * inspector/InspectorHeapProfilerAgent.h:
3788         * inspector/InspectorHistory.cpp:
3789         * inspector/InspectorIndexedDBAgent.cpp:
3790         * inspector/InspectorIndexedDBAgent.h:
3791         * inspector/InspectorInputAgent.h:
3792         * inspector/InspectorLayerTreeAgent.h:
3793         * inspector/InspectorMemoryAgent.h:
3794         * inspector/InspectorPageAgent.h:
3795         * inspector/InspectorProfilerAgent.cpp:
3796         * inspector/InspectorProfilerAgent.h:
3797         * inspector/InspectorResourceAgent.h:
3798         * inspector/InspectorRuntimeAgent.h:
3799         * inspector/InspectorStyleSheet.h:
3800         * inspector/InspectorTimelineAgent.h:
3801         * inspector/InspectorWorkerAgent.cpp:
3802         * inspector/InspectorWorkerAgent.h:
3803         * inspector/PageConsoleAgent.h:
3804         * inspector/PageDebuggerAgent.h:
3805         * inspector/PageRuntimeAgent.h:
3806         * inspector/WorkerConsoleAgent.h:
3807         * inspector/WorkerDebuggerAgent.cpp:
3808         * inspector/WorkerInspectorController.cpp:
3809         * inspector/WorkerRuntimeAgent.h:
3810
3811 2014-01-20  Zan Dobersek  <zdobersek@igalia.com>
3812
3813         Move WebAudio source code to std::unique_ptr
3814         https://bugs.webkit.org/show_bug.cgi?id=127274
3815
3816         Reviewed by Eric Carlson.
3817
3818         Move from using OwnPtr and PassOwnPtr to using std::unique_ptr and move semantics
3819         in the WebAudio module and the WebAudio code in the platform layer.
3820
3821         * Modules/webaudio/AsyncAudioDecoder.cpp:
3822         * Modules/webaudio/AsyncAudioDecoder.h:
3823         * Modules/webaudio/AudioBasicInspectorNode.cpp:
3824         (WebCore::AudioBasicInspectorNode::AudioBasicInspectorNode):
3825         * Modules/webaudio/AudioBasicProcessorNode.cpp:
3826         (WebCore::AudioBasicProcessorNode::AudioBasicProcessorNode):
3827         * Modules/webaudio/AudioBasicProcessorNode.h:
3828         * Modules/webaudio/AudioBufferSourceNode.cpp:
3829         (WebCore::AudioBufferSourceNode::AudioBufferSourceNode):
3830         * Modules/webaudio/AudioContext.cpp:
3831         * Modules/webaudio/AudioContext.h:
3832         * Modules/webaudio/AudioDestinationNode.cpp:
3833         (WebCore::AudioDestinationNode::AudioDestinationNode):
3834         * Modules/webaudio/AudioNode.cpp:
3835         (WebCore::AudioNode::addInput):
3836         (WebCore::AudioNode::addOutput):
3837         (WebCore::AudioNode::checkNumberOfChannelsForInput):
3838         * Modules/webaudio/AudioNode.h:
3839         * Modules/webaudio/BiquadFilterNode.cpp:
3840         (WebCore::BiquadFilterNode::BiquadFilterNode):
3841         * Modules/webaudio/BiquadProcessor.cpp:
3842         (WebCore::BiquadProcessor::createKernel):
3843         (WebCore::BiquadProcessor::getFrequencyResponse):
3844         * Modules/webaudio/BiquadProcessor.h:
3845         * Modules/webaudio/ChannelMergerNode.cpp:
3846         (WebCore::ChannelMergerNode::ChannelMergerNode):
3847         * Modules/webaudio/ChannelSplitterNode.cpp:
3848         (WebCore::ChannelSplitterNode::ChannelSplitterNode):
3849         * Modules/webaudio/ConvolverNode.cpp:
3850         (WebCore::ConvolverNode::ConvolverNode):
3851         (WebCore::ConvolverNode::uninitialize):
3852         (WebCore::ConvolverNode::setBuffer):
3853         * Modules/webaudio/ConvolverNode.h:
3854         * Modules/webaudio/DefaultAudioDestinationNode.h:
3855         * Modules/webaudio/DelayNode.cpp:
3856         (WebCore::DelayNode::DelayNode):
3857         * Modules/webaudio/DelayProcessor.cpp:
3858         (WebCore::DelayProcessor::createKernel):
3859         * Modules/webaudio/DelayProcessor.h:
3860         * Modules/webaudio/DynamicsCompressorNode.cpp:
3861         (WebCore::DynamicsCompressorNode::DynamicsCompressorNode):
3862         (WebCore::DynamicsCompressorNode::initialize):
3863         (WebCore::DynamicsCompressorNode::uninitialize):
3864         * Modules/webaudio/DynamicsCompressorNode.h:
3865         * Modules/webaudio/GainNode.cpp:
3866         (WebCore::GainNode::GainNode):
3867         * Modules/webaudio/MediaElementAudioSourceNode.cpp:
3868         (WebCore::MediaElementAudioSourceNode::MediaElementAudioSourceNode):
3869         (WebCore::MediaElementAudioSourceNode::setFormat):
3870         * Modules/webaudio/MediaElementAudioSourceNode.h:
3871         * Modules/webaudio/MediaStreamAudioDestinationNode.h:
3872         * Modules/webaudio/MediaStreamAudioSource.cpp:
3873         * Modules/webaudio/MediaStreamAudioSourceNode.cpp:
3874         (WebCore::MediaStreamAudioSourceNode::MediaStreamAudioSourceNode):
3875         * Modules/webaudio/MediaStreamAudioSourceNode.h:
3876         * Modules/webaudio/OscillatorNode.cpp:
3877         (WebCore::OscillatorNode::OscillatorNode):
3878         * Modules/webaudio/PannerNode.cpp:
3879         (WebCore::PannerNode::PannerNode):
3880         (WebCore::PannerNode::uninitialize):
3881         (WebCore::PannerNode::setPanningModel):
3882         * Modules/webaudio/PannerNode.h:
3883         * Modules/webaudio/PeriodicWave.cpp:
3884         (WebCore::PeriodicWave::createBandLimitedTables):
3885         * Modules/webaudio/PeriodicWave.h:
3886         * Modules/webaudio/RealtimeAnalyser.cpp:
3887         (WebCore::RealtimeAnalyser::RealtimeAnalyser):
3888         (WebCore::RealtimeAnalyser::setFftSize):
3889         * Modules/webaudio/RealtimeAnalyser.h:
3890         * Modules/webaudio/ScriptProcessorNode.cpp:
3891         (WebCore::ScriptProcessorNode::ScriptProcessorNode):
3892         * Modules/webaudio/WaveShaperDSPKernel.cpp:
3893         (WebCore::WaveShaperDSPKernel::lazyInitializeOversampling):
3894         * Modules/webaudio/WaveShaperDSPKernel.h:
3895         * Modules/webaudio/WaveShaperNode.cpp:
3896         (WebCore::WaveShaperNode::WaveShaperNode):
3897         * Modules/webaudio/WaveShaperProcessor.cpp:
3898         (WebCore::WaveShaperProcessor::createKernel):
3899         * Modules/webaudio/WaveShaperProcessor.h:
3900         * platform/audio/AudioBus.cpp:
3901         (WebCore::AudioBus::AudioBus):
3902         (WebCore::AudioBus::copyWithGainFrom):
3903         * platform/audio/AudioBus.h:
3904         * platform/audio/AudioChannel.cpp:
3905         * platform/audio/AudioChannel.h:
3906         (WebCore::AudioChannel::AudioChannel):
3907         (WebCore::AudioChannel::set):
3908         * platform/audio/AudioDSPKernelProcessor.h:
3909         * platform/audio/AudioDestination.h:
3910         * platform/audio/AudioResampler.cpp:
3911         (WebCore::AudioResampler::AudioResampler):
3912         (WebCore::AudioResampler::configureChannels):
3913         * platform/audio/AudioResampler.h:
3914         * platform/audio/AudioSession.h:
3915         * platform/audio/DynamicsCompressor.cpp:
3916         (WebCore::DynamicsCompressor::setNumberOfChannels):
3917         * platform/audio/DynamicsCompressor.h:
3918         * platform/audio/DynamicsCompressorKernel.cpp:
3919         (WebCore::DynamicsCompressorKernel::setNumberOfChannels):
3920         * platform/audio/DynamicsCompressorKernel.h:
3921         * platform/audio/FFTFrame.cpp:
3922         (WebCore::FFTFrame::createInterpolatedFrame):
3923         * platform/audio/FFTFrame.h:
3924         * platform/audio/HRTFDatabase.cpp:
3925         (WebCore::HRTFDatabase::HRTFDatabase):
3926         * platform/audio/HRTFDatabase.h:
3927         * platform/audio/HRTFDatabaseLoader.cpp:
3928         (WebCore::HRTFDatabaseLoader::~HRTFDatabaseLoader):
3929         (WebCore::HRTFDatabaseLoader::load):
3930         * platform/audio/HRTFDatabaseLoader.h:
3931         * platform/audio/HRTFElevation.cpp:
3932         (WebCore::HRTFElevation::createForSubject):
3933         (WebCore::HRTFElevation::createByInterpolatingSlices):
3934         * platform/audio/HRTFElevation.h:
3935         (WebCore::HRTFElevation::HRTFElevation):
3936         * platform/audio/HRTFKernel.cpp:
3937         (WebCore::HRTFKernel::HRTFKernel):
3938         (WebCore::HRTFKernel::createImpulseResponse):
3939         (WebCore::HRTFKernel::createInterpolatedKernel):
3940         * platform/audio/HRTFKernel.h:
3941         (WebCore::HRTFKernel::create):
3942         (WebCore::HRTFKernel::HRTFKernel):
3943         * platform/audio/MultiChannelResampler.cpp:
3944         (WebCore::MultiChannelResampler::MultiChannelResampler):
3945         * platform/audio/MultiChannelResampler.h:
3946         * platform/audio/Panner.cpp:
3947         (WebCore::Panner::create):
3948         * platform/audio/Panner.h:
3949         * platform/audio/Reverb.cpp:
3950         (WebCore::Reverb::initialize):
3951         * platform/audio/Reverb.h:
3952         * platform/audio/ReverbConvolver.h:
3953         * platform/audio/ReverbConvolverStage.cpp:
3954         (WebCore::ReverbConvolverStage::ReverbConvolverStage):
3955         * platform/audio/ReverbConvolverStage.h:
3956         * platform/audio/gstreamer/AudioDestinationGStreamer.cpp:
3957         (WebCore::AudioDestination::create):
3958         * platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
3959         * platform/audio/ios/AudioDestinationIOS.cpp:
3960         (WebCore::AudioDestination::create):
3961         * platform/audio/ios/AudioSessionIOS.mm:
3962         (WebCore::AudioSession::AudioSession):
3963         * platform/audio/mac/AudioDestinationMac.cpp:
3964         (WebCore::AudioDestination::create):
3965         * platform/audio/mac/AudioDestinationMac.h:
3966         * platform/audio/mac/AudioSessionMac.cpp:
3967         (WebCore::AudioSession::AudioSession):
3968
3969 2014-01-20  Morten Stenshorne  <mstensho@opera.com>
3970
3971         Region based multicol: support explicit column breaks
3972         https://bugs.webkit.org/show_bug.cgi?id=123993
3973
3974         Reviewed by David Hyatt.
3975
3976         Merely supporting insertion of explicit (forced) column breaks in
3977         the region based multicol implementation is really simple: just
3978         hook up with what the CSS regions code is already doing.
3979
3980         However, there is one complication: column balancing. In order to
3981         balance columns as nicely as possible when there are explicit
3982         breaks, we need to figure out between which explicit breaks the
3983         implicit breaks will occur (if there's room for any at all).
3984
3985         Tests: fast/multicol/newmulticol/break-after.html
3986                fast/multicol/newmulticol/break-before.html
3987                fast/multicol/newmulticol/breaks-2-columns-3-no-balancing.html
3988                fast/multicol/newmulticol/breaks-2-columns-3.html
3989                fast/multicol/newmulticol/breaks-3-columns-3.html
3990                fast/multicol/newmulticol/fixed-height-fill-balance-2.html
3991
3992         * rendering/RenderBlockFlow.cpp:
3993         (WebCore::RenderBlockFlow::applyBeforeBreak):
3994         (WebCore::RenderBlockFlow::applyAfterBreak): Use the already
3995         existing region breaking code when inserting breaks in region
3996         based multicol.
3997         * rendering/RenderFlowThread.h:
3998         * rendering/RenderMultiColumnBlock.cpp:
3999         (WebCore::RenderMultiColumnBlock::RenderMultiColumnBlock):
4000         (WebCore::RenderMultiColumnBlock::relayoutForPagination): Avoid
4001         re-balancing if the multicol's contents were not laid out. Apart
4002         from being good for performance, this is now necessary because of
4003         how explicit breaks are implemented.
4004         (WebCore::RenderMultiColumnBlock::layoutSpecialExcludedChild):
4005         Detect if the contents are going to be laid out, or skipped, so
4006         that we can tell if we need to (re-)balance the columns
4007         afterwards.
4008         * rendering/RenderMultiColumnBlock.h:
4009         * rendering/RenderMultiColumnFlowThread.cpp:
4010         (WebCore::RenderMultiColumnFlowThread::addForcedRegionBreak):
4011         Locate the appropriate multi-column set and call its
4012         addForcedBreak().
4013         * rendering/RenderMultiColumnFlowThread.h:
4014         * rendering/RenderMultiColumnSet.cpp:
4015         (WebCore::RenderMultiColumnSet::RenderMultiColumnSet):
4016         (WebCore::RenderMultiColumnSet::findRunWithTallestColumns):
4017         (WebCore::RenderMultiColumnSet::distributeImplicitBreaks): Figure
4018         out how many implicit breaks each single "content run" should
4019         contain. The taller the content run, the more implicit breaks.
4020         (WebCore::RenderMultiColumnSet::calculateBalancedHeight): This is
4021         now a const method that only does half of what the old
4022         calculateBalancedHeight() did. The rest (such as actually storing
4023         the new column height) is done by recalculateBalancedHeight().
4024         (WebCore::RenderMultiColumnSet::clearForcedBreaks): Needs to be
4025         called between each layout pass, to clear the list of "content
4026         runs".
4027         (WebCore::RenderMultiColumnSet::addForcedBreak): Only useful when
4028         columns are to be balanced. It receives explicit (forced) breaks
4029         and stores them as "content runs". When layout is done, we'll go
4030         through the list of content runs, and see where implicit breaks
4031         should be inserted (if there's room for any). The goal is to
4032         insert implicit breaks in such a way that the final columns become
4033         as short as possible.
4034         (WebCore::RenderMultiColumnSet::recalculateBalancedHeight):
4035         Calculates and sets a new balanced column height. This used to be
4036         done directly in calculateBalancedHeight(), but that method is now
4037         const and it now only calculates the new height and returns it.
4038         (WebCore::RenderMultiColumnSet::prepareForLayout):
4039         * rendering/RenderMultiColumnSet.h: Remove old data members
4040         intended for forced breaks (they were unused), and introduce a
4041         "content run" vector instead. A new content run is triggered by an
4042    &nb