Build fix for Qt Windows.
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2012-10-09  Jon Lee  <jonlee@apple.com>
2
3         Build fix for Qt Windows.
4
5         * html/HTMLPlugInElement.h: Include Image.h.
6
7 2012-10-09  Enrica Casucci  <enrica@apple.com>
8
9         Only measure text once instead of twice when performing line layout.
10         https://bugs.webkit.org/show_bug.cgi?id=98317
11         <rdar://problem/12080821>
12
13         Reviewed by Dan Bernstein.
14
15         Since we are measuring each word to find out where the line break should occur,
16         we should cache that information to avoid measuring the run again when
17         creating the line box. The bulk of the change is in nextLineBreak, where
18         the measurements are collected and placed in a vector so that they can
19         be consumed in setLogicalWidthForTextRun where we used to measure the
20         text one more time.
21         Each entry in the vector is a WordMeasurement object that contains information
22         about the start and end offset in the run, the renderer, the measured width
23         and, possibly, a list of fallback fonts.
24         When we need to compute the width of the run to create the line box, we add
25         all the measurements for the given renderer in the run to get the total width.
26
27         * platform/graphics/Font.cpp:
28         (WebCore::Font::width): Added fallback fonts parameter.
29         * platform/graphics/Font.h:
30         (Font): Added fallback fonts parameter to the width static member function.
31         This method is called when we compute the width using TextLayout.
32         * platform/graphics/mac/ComplexTextController.cpp:
33         (WebCore::TextLayout::width): Added fallback fonts parameter.
34         (WebCore::Font::width):
35         (WebCore::ComplexTextController::advance):
36         * platform/graphics/mac/ComplexTextController.h:
37         (ComplexTextController): Added fallback fonts parameter to advance method.
38         * rendering/RenderBlock.h: Added WordMeasures parameter to few methods.
39         * rendering/RenderBlockLineLayout.cpp:
40         (WordMeasurement): Added new class to hold measurement information.
41         (WebCore::setLogicalWidthForTextRun): This is where we compute the run width using the
42         cached information.
43         (WebCore::RenderBlock::computeInlineDirectionPositionsForLine): Added wordMeasures parameter.
44         (WebCore::RenderBlock::createLineBoxesFromBidiRuns): Added wordMeasures parameter.
45         (WebCore::RenderBlock::layoutRunsAndFloatsInRange): Added declaration of the WordMeasures
46         vector and its use.
47         (WebCore::textWidth): Added fallbackFonts parameter, since now we only measure once.
48         (WebCore::RenderBlock::LineBreaker::nextLineBreak): This method has been modified to collect
49         the measurements of the individual words and add them to the vector.
50
51 2012-10-09  Levi Weintraub  <leviw@chromium.org>
52
53         [Sub pixel layout] Fast-path iframe scrolling can picks up an extra pixel
54         https://bugs.webkit.org/show_bug.cgi?id=98571
55
56         Reviewed by Emil A Eklund.
57
58         Refactoring all coordinate-switching functionality to use a single "mode" flag
59         as opposed to having a bunch of boolean values. This enables the same set of
60         options across the board, and a consistent interface. This was previously
61         done for mapLocalToContainer.
62
63         The imptetus for this for this stems from the one logical change in this patch
64         which only effects sub-pixel layout. FrameView::convertToRenderer and
65         convertFromRenderer return IntPoint coordinates, and need to also snap transform
66         offsets to determine proper rects for scrolling.
67
68         Unlabeled functions below are simply being updated to these new interfaces.
69
70         Test: fast/sub-pixel/sub-pixel-iframe-copy-on-scroll.html
71
72         * WebCore.exp.in:
73         * dom/ContainerNode.cpp:
74         (WebCore::ContainerNode::getUpperLeftCorner):
75         (WebCore::ContainerNode::getLowerRightCorner):
76         * dom/Element.cpp:
77         (WebCore::Element::boundsInRootViewSpace):
78         * dom/MouseRelatedEvent.cpp:
79         (WebCore::MouseRelatedEvent::computeRelativePosition):
80         * dom/Node.cpp:
81         (WebCore::Node::convertToPage):
82         (WebCore::Node::convertFromPage):
83         * html/HTMLSelectElement.cpp:
84         (WebCore::HTMLSelectElement::listBoxDefaultEventHandler):
85         * html/shadow/SliderThumbElement.cpp:
86         (WebCore::SliderThumbElement::setPositionFromPoint):
87         * html/shadow/SpinButtonElement.cpp:
88         (WebCore::SpinButtonElement::defaultEventHandler):
89         * page/FrameView.cpp:
90         (WebCore::FrameView::convertToRenderer): Now pixel-snaps offsets before passing
91         them to TransformState, which transforms the coordinates.
92         (WebCore::FrameView::convertFromRenderer): Ditto.
93         * rendering/LayoutState.cpp:
94         (WebCore::LayoutState::LayoutState):
95         * rendering/RenderBlock.cpp:
96         (WebCore::RenderBlock::absoluteQuads):
97         * rendering/RenderBox.cpp:
98         (WebCore::RenderBox::absoluteQuads):
99         (WebCore::RenderBox::mapLocalToContainer):
100         (WebCore::RenderBox::mapAbsoluteToLocalPoint):
101         * rendering/RenderBox.h:
102         (RenderBox):
103         * rendering/RenderBoxModelObject.cpp:
104         (WebCore::RenderBoxModelObject::mapAbsoluteToLocalPoint):
105         * rendering/RenderBoxModelObject.h:
106         (RenderBoxModelObject):
107         * rendering/RenderEmbeddedObject.cpp:
108         (WebCore::RenderEmbeddedObject::isInUnavailablePluginIndicator):
109         * rendering/RenderFrameSet.cpp:
110         (WebCore::RenderFrameSet::userResize):
111         * rendering/RenderGeometryMap.cpp:
112         (WebCore::RenderGeometryMap::absolutePoint):
113         * rendering/RenderInline.cpp:
114         (WebCore::RenderInline::mapLocalToContainer):
115         * rendering/RenderInline.h:
116         (RenderInline):
117         * rendering/RenderLayer.cpp:
118         (WebCore::RenderLayer::absoluteToContents):
119         (WebCore::RenderLayer::calculateClipRects):
120         * rendering/RenderMediaControls.cpp:
121         (WebCore::RenderMediaControls::volumeSliderOffsetFromMuteButton):
122         * rendering/RenderMenuList.cpp:
123         (WebCore::RenderMenuList::showPopup):
124         * rendering/RenderObject.cpp:
125         (WebCore::RenderObject::localToAbsolute):
126         (WebCore::RenderObject::absoluteToLocal):
127         (WebCore::RenderObject::mapLocalToContainer):
128         (WebCore::RenderObject::mapAbsoluteToLocalPoint):
129         (WebCore::RenderObject::localToContainerQuad):
130         (WebCore::RenderObject::localToContainerPoint):
131         * rendering/RenderObject.h:
132         (RenderObject): MapLocalToContainerFlags is now MapCoordinatesFlags since it's
133         now used for other conversion methods.
134         (WebCore::RenderObject::localToAbsoluteQuad):
135         * rendering/RenderTheme.cpp:
136         (WebCore::RenderTheme::volumeSliderOffsetFromMuteButton):
137         * rendering/RenderView.cpp:
138         (WebCore::RenderView::mapLocalToContainer):
139         (WebCore::RenderView::mapAbsoluteToLocalPoint):
140         * rendering/RenderView.h:
141         (RenderView):
142         * rendering/svg/RenderSVGForeignObject.cpp:
143         (WebCore::RenderSVGForeignObject::mapLocalToContainer):
144         * rendering/svg/RenderSVGForeignObject.h:
145         (RenderSVGForeignObject):
146         * rendering/svg/RenderSVGInline.cpp:
147         (WebCore::RenderSVGInline::mapLocalToContainer):
148         * rendering/svg/RenderSVGInline.h:
149         (RenderSVGInline):
150         * rendering/svg/RenderSVGModelObject.cpp:
151         (WebCore::RenderSVGModelObject::mapLocalToContainer):
152         * rendering/svg/RenderSVGModelObject.h:
153         (RenderSVGModelObject):
154         * rendering/svg/RenderSVGRoot.cpp:
155         (WebCore::RenderSVGRoot::mapLocalToContainer):
156         * rendering/svg/RenderSVGRoot.h:
157         (RenderSVGRoot):
158         * rendering/svg/RenderSVGText.cpp:
159         (WebCore::RenderSVGText::mapLocalToContainer):
160         * rendering/svg/RenderSVGText.h:
161         (RenderSVGText):
162         * rendering/svg/SVGRenderSupport.cpp:
163         (WebCore::SVGRenderSupport::mapLocalToContainer):
164         * svg/SVGSVGElement.cpp:
165         (WebCore::SVGSVGElement::localCoordinateSpaceTransform):
166
167 2012-10-09  Jon Lee  <jonlee@apple.com>
168
169         [WK2] Have plugins render offscreen to capture snapshot
170         https://bugs.webkit.org/show_bug.cgi?id=98326
171         <rdar://problem/12426658>
172
173         Reviewed by Simon Fraser.
174
175         Change updateSnapshot() to use a PassRefPtr<Image> instead of Image*. WebKit2 ultimately
176         hands the image off to RenderSnapshottedPlugin. A CachedImage instance then manages the
177         lifetime of the Image.
178
179         * html/HTMLPlugInElement.h:
180         (WebCore::HTMLPlugInElement::updateSnapshot):
181         * html/HTMLPlugInImageElement.cpp:
182         (WebCore::HTMLPlugInImageElement::updateSnapshot):
183         * html/HTMLPlugInImageElement.h:
184         (HTMLPlugInImageElement):
185         * rendering/RenderSnapshottedPlugIn.cpp:
186         (WebCore::RenderSnapshottedPlugIn::updateSnapshot): Updated to use the PassRefPtr<Image>
187         pointer.
188         * rendering/RenderSnapshottedPlugIn.h:
189         (RenderSnapshottedPlugIn):
190
191 2012-10-09  Adam Barth  <abarth@webkit.org>
192
193         Unreviewed. Move this file to where the build systems think it should
194         be. See https://bugs.webkit.org/show_bug.cgi?id=94755
195
196         * platform/graphics/CustomFilterConstants.h: Removed.
197         * platform/graphics/filters/CustomFilterConstants.h: Copied from Source/WebCore/platform/graphics/CustomFilterConstants.h.
198
199 2012-10-09  Tony Chang  <tony@chromium.org>
200
201         Use computeLogical* methods instead of updateLogical* methods in RenderImage
202         https://bugs.webkit.org/show_bug.cgi?id=98802
203
204         Reviewed by Eric Seidel.
205
206         We were storing the old values of width/height, calling updateLogical{Width,Height}, then restoring
207         the old values.  Instead, use the computeLogical{Width,Height} methods so we don't have to overwrite
208         the current values.
209
210         No new tests, this is just a refactoring.
211
212         * rendering/RenderImage.cpp:
213         (WebCore::RenderImage::imageDimensionsChanged):
214
215 2012-10-09  Enrica Casucci  <enrica@apple.com>
216
217         [chromium] fast/text/international/text-spliced-font.html and fast/writing-mode/Kusa-Makura-
218         background-canvas.html failing on the Mac after r130443
219         https://bugs.webkit.org/show_bug.cgi?id=98545
220
221         Reviewed by Tony Chang.
222
223         Adding back the ! removed by mistake before submitting r130779. 
224
225         * platform/graphics/FontFastPath.cpp:
226         (WebCore::Font::glyphDataAndPageForCharacter):
227
228 2012-10-09  Artem Simonov  <asimonov@rim.com>
229
230         [BlackBerry] EGL Context deleted prematurely in GraphicsContext3D destructor
231         https://bugs.webkit.org/show_bug.cgi?id=98796
232
233         Reviewed by George Staikos.
234
235         Reordered destruction of GraphicsContext3D so that the compositing layer is
236         destroyed first.
237
238         * platform/graphics/blackberry/GraphicsContext3DBlackBerry.cpp:
239         (WebCore::GraphicsContext3D::~GraphicsContext3D):
240
241 2012-10-09  Ben Wagner  <bungeman@chromium.org>
242
243         Disable hinting when webkit-font-smoothing:antialiased is used on Mac.
244         https://bugs.webkit.org/show_bug.cgi?id=98061
245
246         Reviewed by Stephen White.
247
248         Normal anti-aliased text matches subpixel anti-aliased text.
249         However, text marked with webkit-font-smoothing:antialiased should be drawn without hinting to match Safari.
250         See crbug.com/152304 . 
251
252         Test is fast/css/font-smoothing.html, but DRT runs with font smoothing disabled, so no change visible. 
253
254         * platform/graphics/skia/FontSkia.cpp:
255         (WebCore::setupPaint):
256         Set kNo_Hinting when webkit-font-smoothing is antialiased.
257
258 2012-10-09  Max Vujovic  <mvujovic@adobe.com>
259
260         [CSS Shaders] Create constants for vertex attribute sizes and offsets
261         https://bugs.webkit.org/show_bug.cgi?id=94755
262
263         Reviewed by Dean Jackson.
264
265         Factor out the vertex attribute size and offset constants into a new file,
266         CustomFilterConstants.h. Replace literals in CustomFilterMeshGenerator with the constants.
267
268         I could have added the constants to CustomFilterMeshGenerator.h, but this would make
269         FECustomFilter depend on CustomFilterMeshGenerator.
270
271         I also could have added the constants to CustomFilterMesh.h, but this would make
272         CustomFilterMeshGenerator depend on CustomFilterMesh.
273
274         No new tests. No change in behavior.
275
276         * GNUmakefile.list.am:
277         * Target.pri:
278         * WebCore.gypi:
279         * WebCore.vcproj/WebCore.vcproj:
280         * WebCore.xcodeproj/project.pbxproj:
281         * platform/graphics/CustomFilterConstants.h: Added.
282         (WebCore):
283         * platform/graphics/filters/CustomFilterMeshGenerator.h:
284         (WebCore::CustomFilterMeshGenerator::floatsPerVertex):
285             Use the new constants instead of literal values.
286         * platform/graphics/filters/FECustomFilter.cpp:
287         (WebCore::FECustomFilter::bindProgramAndBuffers):
288             Pull the constant definitions out of here.
289
290 2012-10-09  Michael Saboff  <msaboff@apple.com>
291
292         MarkupAccumulator should optimally handle 8 bit Strings
293         https://bugs.webkit.org/show_bug.cgi?id=98224
294
295         Reviewed by Ryosuke Niwa.
296
297         Updated appendCharactersReplacingEntities to take a string, offset and length and process 8 or 16 bit
298         data as appropriate.  Also made it a member function of MarkupAccumulator.
299
300         No new tests, behavior covered by existing tests.
301
302         * editing/MarkupAccumulator.cpp:
303         (WebCore::MarkupAccumulator::appendCharactersReplacingEntities):
304         (WebCore::MarkupAccumulator::appendAttributeValue):
305         (WebCore::MarkupAccumulator::appendNodeValue):
306         * editing/MarkupAccumulator.h:
307         (MarkupAccumulator):
308         * editing/markup.cpp:
309         (WebCore::StyledMarkupAccumulator::appendText):
310         (WebCore::urlToMarkup):
311
312 2012-10-09  Joshua Bell  <jsbell@chromium.org>
313
314         IndexedDB: Overflowing key generator should throw ConstraintError
315         https://bugs.webkit.org/show_bug.cgi?id=98807
316
317         Reviewed by Tony Chang.
318
319         After the WebKit implementation landed throwing DataError, public-webapps
320         consensus was that the exception thrown should be ConstraintError. Trivial
321         change, and we pass one more W3C test submission.
322
323         Test: storage/indexeddb/key-generator.html
324
325         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
326         (WebCore::IDBObjectStoreBackendImpl::putInternal):
327
328 2012-10-08  Martin Robinson  <mrobinson@igalia.com>
329
330         Fix the order of the statements in my previous build fix.
331
332         Reviewed by Gustavo Noronha Silva.
333
334         My previous build build fix for ResourceHandleSoup ordered the assignment
335         of the local ResourceHandleInternal incorrectly. Instead of being before
336         both assertions, it should be interspersed among them.
337
338         * platform/network/soup/ResourceHandleSoup.cpp:
339         (WebCore::createSoupMessageForHandleAndRequest):
340
341 2012-10-09  Beth Dakin  <bdakin@apple.com>
342
343         https://bugs.webkit.org/show_bug.cgi?id=98457
344         ScrollingStateNodes should be referenced via IDs on 
345         RenderLayerBacking
346
347         Reviewed by Simon Fraser.
348
349         This patch associates all ScrollingStateNodes with a 
350         RenderLayerBacking via a HashMap from RenderLayerBackings to 
351         ScrollingStateNodes on ScrollingCoordinator. Prior to this patch, the 
352         root ScrollingStateNode was created immediately upon creation of the 
353         ScrollingCoordinator, and it was constantly re-used for every main 
354         FrameView. This doesn't work in the new model since that doesn't 
355         allow that ScrollingStateNode to have a definite association with a 
356         RenderLayerBacking. So this patch does also introduce some lifetime 
357         differences with the ScrollingStateNodes.
358
359         If a page is going into the page cache, we should clear the state 
360         tree. When the page is in the cache, we won't have access to the 
361         RenderLayerBacking, and we don't want to be doing anything with the 
362         ScrollingStateNodes anyway.
363         * dom/Document.cpp:
364         (WebCore::Document::setInPageCache):
365
366         When a page is restored from the page cache, call 
367         frameViewRootLayerDidChange() to re-create the state tree.
368         * loader/HistoryController.cpp:
369         (WebCore::HistoryController::restoreScrollPositionAndViewState):
370
371         This new FrameView function will return the scrollLayerID for a given FrameView.
372         * page/FrameView.cpp:
373         (WebCore::FrameView::scrollLayerID):
374         (WebCore):
375         * page/FrameView.h:
376         (FrameView):
377
378         There is a lot of unfortunate fiddling with the terrible 
379         if-defs in ScrollingCoordinator. I added a FIXME to the header
380         noting how we can avoid this in the future.
381         * page/scrolling/ScrollingCoordinator.cpp:
382
383         All of this code used to refer to the rootStateNode directly. 
384         Instead, now it looks up the proper ScrollingStateNode for the given 
385         FrameView in the HashMap.
386         (WebCore::ScrollingCoordinator::frameViewLayoutUpdated):
387         (WebCore::ScrollingCoordinator::frameViewWheelEventHandlerCountChanged):
388         (WebCore::ScrollingCoordinator::frameViewRootLayerDidChange):
389         (WebCore::ScrollingCoordinator::requestScrollPositionUpdate):
390         (WebCore::ScrollingCoordinator::updateMainFrameScrollLayerPosition):
391         (WebCore::ScrollingCoordinator::recomputeWheelEventHandlerCountForFrameView):
392         (WebCore::ScrollingCoordinator::setScrollLayerForNode):
393         (WebCore::ScrollingCoordinator::setNonFastScrollableRegionForNode):
394         (WebCore::ScrollingCoordinator::setScrollParametersForNode):
395         (WebCore::ScrollingCoordinator::setWheelEventHandlerCountForNode):
396
397         Returns the existing ScrollingStateNode for a given FrameView by 
398         looking it up in the HashMap.
399         (WebCore::ScrollingCoordinator::stateNodeForFrameView):
400
401         This is called when a RenderLayerBacking is destroyed. At that time, 
402         its associated ScrollingStateNode is destroyed.
403         (WebCore::ScrollingCoordinator::detachFromStateTree):
404
405         clearStateTree() clears the HashMap and destroys all of the nodes in 
406         the current state tree.
407         (WebCore::ScrollingCoordinator::clearStateTree):
408
409         Creates a new root state node for the given FrameView.
410         (WebCore::ScrollingCoordinator::ensureRootStateNodeForFrameView):
411
412         Some new functions for the new node stuff.
413         * page/scrolling/ScrollingCoordinator.h:
414         * page/scrolling/ScrollingCoordinatorNone.cpp:
415         (WebCore::ScrollingCoordinator::setShouldUpdateScrollLayerPositionOnMainThread):
416         (WebCore::ScrollingCoordinator::supportsFixedPositionLayers):
417         (WebCore::ScrollingCoordinator::setLayerIsContainerForFixedPositionLayers):
418         (WebCore::ScrollingCoordinator::setLayerIsFixedToContainerLayer):
419         (WebCore::ScrollingCoordinator::scrollableAreaScrollLayerDidChange):
420         (WebCore::ScrollingCoordinator::detachFromStateTree):
421         (WebCore::ScrollingCoordinator::clearStateTree):
422         (WebCore::ScrollingCoordinator::ensureRootStateNodeForFrameView):
423         (WebCore::setScrollParameters):
424         (WebCore::setWheelEventHandlerCount):
425
426         New remove functions are used when the sate tree is cleared and when 
427         a RenderLayerBacking is destroyed.
428         * page/scrolling/ScrollingStateNode.cpp:
429         (WebCore::ScrollingStateNode::removeChild):
430         (WebCore):
431         * page/scrolling/ScrollingStateNode.h:
432         (WebCore::ScrollingStateNode::isScrollingStateScrollingNode):
433         (ScrollingStateNode):
434         (WebCore::ScrollingStateNode::parent):
435
436         New convenience function for casting to ScrollingStateScrollingNodes.
437         * page/scrolling/ScrollingStateScrollingNode.h:
438         (WebCore::toScrollingStateScrollingNode):
439         (WebCore):
440
441         No longer automatically create a root node upon creation of the 
442         ScrollingStateTree. We now want to wait to create the root node until 
443         we have a RenderLayerBacking to associate it with.
444         * page/scrolling/ScrollingStateTree.cpp:
445         (WebCore::ScrollingStateTree::ScrollingStateTree):
446         (WebCore::ScrollingStateTree::removeNode):
447         (WebCore):
448         * page/scrolling/ScrollingStateTree.h:
449         (WebCore::ScrollingStateTree::setRootStateNode):
450         (ScrollingStateTree):
451
452         RenderLayerBacking has a new data member called m_scrollLayerID. If 
453         this RenderLayerBacking is represented in the scrolling tree, then 
454         the ID with be unique and non-zero. 
455         * rendering/RenderLayerBacking.cpp:
456         (WebCore::RenderLayerBacking::RenderLayerBacking):
457         (WebCore::RenderLayerBacking::~RenderLayerBacking):
458         (WebCore::generateScrollLayerID):
459         (WebCore):
460         (WebCore::RenderLayerBacking::attachToScrollingCoordinator):
461         (WebCore::RenderLayerBacking::detachFromScrollingCoordinator):
462         * rendering/RenderLayerBacking.h:
463         (RenderLayerBacking):
464         (WebCore::RenderLayerBacking::scrollLayerID):
465
466         Move the call to ScrollingCooridinator::frameViewRootLayerDidChange() 
467         from RenderLayerCompositor::attachRootLayer() to 
468         RenderLayerCompositor:: updateBacking(). The problem with the old call 
469         site is that there is no backing at that time, so we are trying to set 
470         state on the root scrolling state node before we have enough 
471         information to create that node and add it to the HashMap.
472         * rendering/RenderLayerCompositor.cpp:
473         (WebCore::RenderLayerCompositor::updateBacking):
474         (WebCore::RenderLayerCompositor::attachRootLayer):
475
476 2012-10-09  Florin Malita  <fmalita@chromium.org>
477
478         SVGResources should use HashSet<AtomicString> instead of HashSet<AtomicStringImpl*>
479         https://bugs.webkit.org/show_bug.cgi?id=98683
480
481         Reviewed by Darin Adler.
482
483         Eric's notes:
484
485         SVGResources should use HashSet<AtomicString> instead of HashSet<AtomicStringImpl*>
486         They do basically the same thing, and the former is much more common (and less code). It's
487         also safe, on the off-chance that we're using AtomicStrings which might otherwise go away.
488
489         No new tests, refactoring. 
490
491         * rendering/svg/SVGResources.cpp:
492         (WebCore::clipperFilterMaskerTags):
493         (WebCore::markerTags):
494         (WebCore::fillAndStrokeTags):
495         (WebCore::chainableResourceTags):
496         (WebCore::SVGResources::buildCachedResources):
497
498 2012-10-09  Enrica Casucci  <enrica@apple.com>
499
500         [chromium] fast/text/international/text-spliced-font.html and fast/writing-mode/Kusa-Makura-background-canvas.html
501         failing on the Mac after r130443
502         https://bugs.webkit.org/show_bug.cgi?id=98545
503
504         Reviewed by Tony Chang.
505
506         Fixes a regression introduced with r130443.
507         No new tests added since we already have tests covering this.
508         Updated TestExpectations for chromium and mac.
509
510         * platform/graphics/FontFastPath.cpp:
511         (WebCore::Font::glyphDataAndPageForCharacter): Text orientation should not be
512         taken into account if the character is an ideograph or a symbol.
513
514 2012-10-09  Philip Rogers  <pdr@google.com>
515
516         Prevent animation when CSS attributeType is invalid.
517         https://bugs.webkit.org/show_bug.cgi?id=94569
518
519         Reviewed by Dirk Schulze.
520
521         This patch changes hasValidAttributeType() to return false when
522         we have attributeType=CSS with a non-CSS attribute name.
523
524         Previously we would animate non-CSS attributes when attributeType was
525         CSS which resulted in crashes. To track this case, this patch catches
526         changes to targetElement, attributeName, and attributeType and checks
527         if an invalid combination is present. If invalid, hasInvalidCSSAttributeType()
528         will return true causing hasValidAttributeType() to return false and prevent
529         the animation from running.
530
531         Tests: svg/animations/animate-css-xml-attributeType.html
532                svg/animations/invalid-css-attribute-crash-expected.svg
533                svg/animations/invalid-css-attribute-crash.svg
534
535         * svg/SVGAnimateElement.cpp:
536         (WebCore::SVGAnimateElement::hasValidAttributeType):
537         (WebCore::SVGAnimateElement::targetElementWillChange):
538         * svg/SVGAnimationElement.cpp:
539         (WebCore::SVGAnimationElement::SVGAnimationElement):
540         (WebCore::SVGAnimationElement::isSupportedAttribute):
541
542             This now supports the attributeType attribute which is stored in m_attributeType.
543
544         (WebCore::SVGAnimationElement::parseAttribute):
545         (WebCore::SVGAnimationElement::setAttributeType):
546
547             Changes to attributeType, attributeName, and targetElement need to be tracked
548             to determine when an invalid combination happens.
549
550         (WebCore::SVGAnimationElement::targetElementWillChange):
551         (WebCore):
552         (WebCore::SVGAnimationElement::setAttributeName):
553         (WebCore::SVGAnimationElement::checkInvalidCSSAttributeType):
554         * svg/SVGAnimationElement.h:
555         (WebCore::SVGAnimationElement::attributeType):
556         (SVGAnimationElement):
557         (WebCore::SVGAnimationElement::hasInvalidCSSAttributeType):
558         * svg/animation/SVGSMILElement.cpp:
559         (WebCore::SVGSMILElement::targetElement):
560         * svg/animation/SVGSMILElement.h:
561         (SVGSMILElement):
562
563 2012-10-09  Pravin D  <pravind.2k4@gmail.com>
564
565         max-width property is does not overriding the width properties for css tables(display:table)
566         https://bugs.webkit.org/show_bug.cgi?id=98455
567
568         Reviewed by Tony Chang.
569
570         The max-width property determines the maximum computed width an element can have. In case of css tables(display:table),
571         the computed was not being limited by the max-width property. The current patch fixes this issue.
572
573         Test: fast/table/css-table-max-width.html
574
575         * rendering/RenderTable.cpp:
576         (WebCore::RenderTable::updateLogicalWidth):
577          Logic to compute the logical width of an element such that it does not exceed the max-width value.
578          Also when both min-width and max-width are present, the following contraint is used to compute the logical width:
579            1) min-width < Computed LogicalWidth < max-width, when min-width < max-width.
580            2) Computed LogicalWidth = min-width, when min-width > max-width.
581
582 2012-10-09  Harald Alvestrand  <hta@google.com>
583
584         Change PeerConnection getStats function to single value local / remote
585         elements in RTCStatsReport.
586
587         https://bugs.webkit.org/show_bug.cgi?id=98753
588
589         Reviewed by Adam Barth.
590
591         IDL of RTCStatsReport has been changed to make local/remote
592         single valued RTCStatsElement attributes.
593         The RTCStatsReport argument to index the list of RTCStatsElement
594         in the local and remote functions has been removed.
595
596         Tested by modifications to RTCPeerConnection-stats.html
597
598         * Modules/mediastream/RTCStatsReport.cpp:
599         (WebCore::RTCStatsReport::addElement):
600         (WebCore::RTCStatsReport::addStatistic):
601         * Modules/mediastream/RTCStatsReport.h:
602         (WebCore::RTCStatsReport::local):
603         (WebCore::RTCStatsReport::remote):
604         (RTCStatsReport):
605         * Modules/mediastream/RTCStatsReport.idl:
606         * Modules/mediastream/RTCStatsResponse.cpp:
607         (WebCore::RTCStatsResponse::addElement):
608         (WebCore::RTCStatsResponse::addStatistic):
609         * Modules/mediastream/RTCStatsResponse.h:
610         (RTCStatsResponse):
611         * platform/chromium/support/WebRTCStatsResponse.cpp:
612         (WebKit::WebRTCStatsResponse::addElement):
613         (WebKit::WebRTCStatsResponse::addStatistic):
614         * platform/mediastream/RTCStatsResponseBase.h:
615         (RTCStatsResponseBase):
616
617 2012-10-09  Antonio Gomes  <agomes@rim.com>
618
619         Get rid of FIXED_POSITION_CREATES_STACKING_CONTEXT in favor of Settings::fixedPositionCreatesStackingContext()
620         https://bugs.webkit.org/show_bug.cgi?id=98756
621
622         Reviewed by Rob Buis.
623
624         No behavior change so no new tests.
625
626         * css/StyleResolver.cpp:
627         (WebCore::StyleResolver::collectMatchingRulesForList):
628
629 2012-10-09  Simon Hausmann  <simon.hausmann@digia.com>
630
631         [Qt] Fix build with QtMultimedia
632
633         Reviewed by Tor Arne Vestbø.
634
635         This is an initial rudimentary port to of the QtMultimedia back-end,
636         adapted to slight API changes and (more importantly) to the
637         implementation of QAbstractVideoSurface instead of using
638         QGraphicsVideoItem (which is in QtMultimediaWidgets).
639
640         * WebCore.pri:
641         * platform/graphics/qt/MediaPlayerPrivateQt.cpp:
642         (WebCore::MediaPlayerPrivateQt::supportsType):
643         (WebCore::MediaPlayerPrivateQt::MediaPlayerPrivateQt):
644         (WebCore::MediaPlayerPrivateQt::~MediaPlayerPrivateQt):
645         (WebCore::MediaPlayerPrivateQt::didLoadingProgress):
646         (WebCore::MediaPlayerPrivateQt::totalBytes):
647         (WebCore::MediaPlayerPrivateQt::setVisible):
648         (WebCore::MediaPlayerPrivateQt::surfaceFormatChanged):
649         (WebCore::MediaPlayerPrivateQt::setSize):
650         (WebCore::MediaPlayerPrivateQt::removeVideoItem):
651         (WebCore::MediaPlayerPrivateQt::restoreVideoItem):
652         (WebCore):
653         (WebCore::MediaPlayerPrivateQt::start):
654         (WebCore::MediaPlayerPrivateQt::supportedPixelFormats):
655         (WebCore::MediaPlayerPrivateQt::present):
656         (WebCore::MediaPlayerPrivateQt::paint):
657         (WebCore::MediaPlayerPrivateQt::paintCurrentFrameInContext):
658         (WebCore::MediaPlayerPrivateQt::paintToTextureMapper):
659         * platform/graphics/qt/MediaPlayerPrivateQt.h:
660         (MediaPlayerPrivateQt):
661
662 2012-10-09  Garrett Casto  <gcasto@chromium.org>
663
664         Allow users to specify a different hover image for TextFieldDecorationElement
665         https://bugs.webkit.org/show_bug.cgi?id=93662
666
667         Reviewed by Kent Tamura.
668
669         * html/shadow/TextFieldDecorationElement.cpp:
670         (WebCore::TextFieldDecorationElement::TextFieldDecorationElement):
671         (WebCore::TextFieldDecorationElement::updateImage):
672         (WebCore::TextFieldDecorationElement::defaultEventHandler): Handles mouseover and mouseout events.
673         (WebCore::TextFieldDecorationElement::willRespondToMouseMoveEvents): Now returns true if the element is not disabled.
674         (WebCore):
675         * html/shadow/TextFieldDecorationElement.h:
676         (TextFieldDecorator):
677         (TextFieldDecorationElement):
678
679 2012-10-09  Allan Sandfeld Jensen  <allan.jensen@digia.com>
680
681         [Qt] Uploading images to Google+ using QtWebKit does not work.
682         https://bugs.webkit.org/show_bug.cgi?id=72329
683
684         Reviewed by Jocelyn Turcotte.
685
686         Implement handling of Blob FormData, including its extensions to the File FormData.
687
688         * platform/network/qt/QNetworkReplyHandler.cpp:
689         (WebCore::FormDataIODevice::FormDataIODevice):
690         (WebCore::appendBlobResolved):
691         (WebCore::FormDataIODevice::prepareFormElements):
692         (WebCore::FormDataIODevice::computeSize):
693         (WebCore::FormDataIODevice::moveToNextElement):
694         (WebCore::FormDataIODevice::prepareCurrentElement):
695         (WebCore::FormDataIODevice::openFileForCurrentElement):
696         (WebCore::FormDataIODevice::readData):
697         (WebCore::QNetworkReplyHandler::sendNetworkRequest):
698         * platform/network/qt/QNetworkReplyHandler.h:
699         (FormDataIODevice):
700
701 2012-10-09  Arpita Bahuguna  <arpitabahuguna@gmail.com>
702
703         Text decorations specified on the containing block are not properly applied when ::first-line is present.
704         https://bugs.webkit.org/show_bug.cgi?id=93829
705
706         Reviewed by Abhishek Arya.
707
708         If a container's style and its pseudo :first-line style have unique
709         text-decorations specified for them, only the :first-line text-decoarations
710         were being applied.
711
712         The uploaded patch intends to first compute the text decoration colors
713         for the containing box, followed by that of the first-line (if specified).
714
715         This thus avoids the condition wherein our containing box's text-decorations
716         were not getting applied at all since initially we were only computing
717         for the first-line style.
718
719         Test: fast/css/text-decorations-on-first-line-and-containing-block.html
720
721         * rendering/InlineTextBox.cpp:
722         (WebCore::InlineTextBox::paintDecoration):
723         getTextDecorationColors() is first called for computing the containing box's
724         text-decoration values and then for first-line style's text-decorations,
725         if specified.
726
727 2012-10-09  Sheriff Bot  <webkit.review.bot@gmail.com>
728
729         Unreviewed, rolling out r130746.
730         http://trac.webkit.org/changeset/130746
731         https://bugs.webkit.org/show_bug.cgi?id=98749
732
733         It made 45 tests crash on Qt (Requested by Ossy on #webkit).
734
735         * platform/network/qt/QNetworkReplyHandler.cpp:
736         (WebCore::FormDataIODevice::FormDataIODevice):
737         (WebCore::FormDataIODevice::computeSize):
738         (WebCore::FormDataIODevice::moveToNextElement):
739         (WebCore::FormDataIODevice::openFileForCurrentElement):
740         (WebCore::FormDataIODevice::readData):
741         (WebCore::QNetworkReplyHandler::getIODevice):
742         (WebCore::QNetworkReplyHandler::sendNetworkRequest):
743         * platform/network/qt/QNetworkReplyHandler.h:
744         (QNetworkReplyHandler):
745         (FormDataIODevice):
746
747 2012-10-09  Allan Sandfeld Jensen  <allan.jensen@digia.com>
748
749         [Qt] Uploading images to Google+ using QtWebKit does not work.
750         https://bugs.webkit.org/show_bug.cgi?id=72329
751
752         Reviewed by Jocelyn Turcotte.
753
754         Implement handling of Blob FormData, including its extensions to the File FormData.
755
756         * platform/network/qt/QNetworkReplyHandler.cpp:
757         (WebCore::FormDataIODevice::FormDataIODevice):
758         (WebCore::FormDataIODevice::computeSize):
759         (WebCore::FormDataIODevice::moveToNextElement):
760         (WebCore::FormDataIODevice::prepareCurrentElement):
761         (WebCore::FormDataIODevice::openFileForCurrentElement):
762         (WebCore::FormDataIODevice::readData):
763         (WebCore::QNetworkReplyHandler::getIODevice):
764         (WebCore::QNetworkReplyHandler::handleBlobDataIfAny):
765         (WebCore::QNetworkReplyHandler::sendNetworkRequest):
766         * platform/network/qt/QNetworkReplyHandler.h:
767         (QNetworkReplyHandler):
768         (FormDataIODevice):
769
770 2012-10-09  Keishi Hattori  <keishi@webkit.org>
771
772         Page popup should be smarter about its layout
773         https://bugs.webkit.org/show_bug.cgi?id=98499
774
775         Reviewed by Kent Tamura.
776
777         This change fixes these two issues:
778         1. Page popup should reposition itself so it won't get clipped by screen(Win/Linux) or rootview(Mac) bounds.
779         2. Page popup should resize itself when it doesn't fit.
780
781         Test: platform/chromium/fast/forms/page-popup/page-popup-adjust-rect.html
782
783         * Resources/pagepopups/calendarPicker.js:
784         (initialize): We need to set global.params at the beginning because we need it for resizeWindow().
785         * Resources/pagepopups/colorSuggestionPicker.js: Added global.params.
786         (handleMessage):
787         (initialize):
788         (handleArgumentsTimeout):
789         * Resources/pagepopups/pickerCommon.js:
790         (Rect): Represents an axis aligned rectangle.
791         (Rect.prototype.get maxX): Gets position of right edge.
792         (Rect.prototype.get maxY): Gets position of bottom edge.
793         (Rect.prototype.toString):
794         (Rect.intersection): Returns the intersection of two rectangles.
795         (resizeWindow): Resize window to a certain size. Don't allow shrinking.
796         (adjustWindowRect): Calculates the best position and size for the popup.
797         (_adjustWindowRectVertically):
798         (_adjustWindowRectHorizontally):
799         (setWindowRect): Sets the position and size of the popup to the given rect.
800         * Resources/pagepopups/suggestionPicker.css:
801         (.suggestion-list): Don't show horizontal scroll bar.
802         * Resources/pagepopups/suggestionPicker.js:
803         (SuggestionPicker.prototype._fixWindowSize): 
804         * page/PagePopupClient.cpp:
805         (WebCore::PagePopupClient::addProperty): For adding an int to JSON.
806         (WebCore::PagePopupClient::addProperty): For adding an IntRect to JSON.
807         (WebCore):
808         * page/PagePopupClient.h:
809         (PagePopupClient):
810
811 2012-10-09  Hajime Morrita  <morrita@google.com>
812
813         [Refactoring] Scoped Style related code should have its own class.
814         https://bugs.webkit.org/show_bug.cgi?id=98244
815
816         Reviewed by Dimitri Glazkov.
817
818         This change extracts StyleScopeResolver from StyleResolver to clarify
819         the responsibility of the style scope handling. Now we can easily see
820         where the style scoping needs to be involed.
821
822         Coming Shadow DOM related change like @host rules will fit within this class.
823
824         No new tests, refactoring.
825
826         * CMakeLists.txt:
827         * GNUmakefile.list.am:
828         * Target.pri:
829         * WebCore.gypi:
830         * WebCore.xcodeproj/project.pbxproj:
831         * css/CSSAllInOne.cpp:
832         * css/StyleResolver.cpp:
833         (WebCore::StyleResolver::StyleResolver):
834         (WebCore::StyleResolver::collectFeatures):
835         (WebCore::StyleResolver::appendAuthorStylesheets):
836         (WebCore::StyleResolver::pushParentElement):
837         (WebCore::StyleResolver::popParentElement):
838         (WebCore::StyleResolver::pushParentShadowRoot):
839         (WebCore::StyleResolver::popParentShadowRoot):
840         (WebCore::StyleResolver::matchScopedAuthorRules):
841         (WebCore::StyleResolver::collectMatchingRulesForList):
842         (WebCore::StyleResolver::reportMemoryUsage):
843         * css/StyleResolver.h:
844         (StyleResolver):
845         * css/StyleScopeResolver.cpp: Added.
846         (WebCore):
847         (WebCore::StyleScopeResolver::StyleScopeResolver):
848         (WebCore::StyleScopeResolver::~StyleScopeResolver):
849         (WebCore::StyleScopeResolver::scopeFor):
850         (WebCore::StyleScopeResolver::ruleSetFor):
851         (WebCore::StyleScopeResolver::ensureRuleSetFor):
852         (WebCore::StyleScopeResolver::setupStack):
853         (WebCore::StyleScopeResolver::push):
854         (WebCore::StyleScopeResolver::pop):
855         (WebCore::StyleScopeResolver::collectFeaturesTo):
856         (WebCore::StyleScopeResolver::reportMemoryUsage):
857         * css/StyleScopeResolver.h: Added.
858         (WebCore):
859         (StyleScopeResolver):
860         (WebCore::StyleScopeResolver::StackFrame::StackFrame):
861         (StackFrame):
862         (WebCore::StyleScopeResolver::hasScopedStyles):
863         (WebCore::StyleScopeResolver::stackSize):
864         (WebCore::StyleScopeResolver::stackFrameAt):
865         (WebCore::StyleScopeResolver::matchesStyleBounds):
866         (WebCore::StyleScopeResolver::stackIsConsistent):
867         (WebCore::StyleScopeResolver::ensureStackConsistency):
868         (WebCore::StyleScopeResolver::scopeFor):
869         (WebCore::StyleScopeResolver::ensureRuleSetFor):
870
871 2012-10-08  Simon Hausmann  <simon.hausmann@digia.com>
872
873         [Qt] Make RenderThemeQStyle/ScrollbarThemeQStyle compile without QStyle/QtWidgets
874         https://bugs.webkit.org/show_bug.cgi?id=98268
875
876         Reviewed by Tor Arne Vestbø.
877
878         Extracted QStyle/QWidget related code into a QWebStyle class that implements the QStyleFacade interface.
879
880         QStyleFacade is a pure interface that lives in WebCore/platform/qt
881         (next to RenderThemeQStyle and ScrollbarThemeQStyle) and provides a
882         minimal interface of what we need to draw with QStyle as well as basic
883         hit testing and metric retrieval. It also provides a
884         QStyleFacadeOption class that aggregates common meta-data for
885         rendering primitives, such as direction, rectangle, state (sunken,
886         enabled, etc.) or palette. It also provides some more slider/scrollbar
887         specific fields in a slider sub-structure.
888
889         RenderThemeQStyle/ScrollbarThemeQStyle used to instantiate specific QStyleOption sub-classes and populate
890         them with state information from render objects, before calling straight to QStyle. Most of the common code
891         was encapsulated in StylePainterQStyle.
892
893         The new RenderThemeQStyle/ScrolllbarThemeQStyle uses common code in
894         StylePainterQStyle to populate state into QStyleFacadeOption before
895         calling into QStyleFacade.
896
897         The style facade is then implemented by QStyleFacadeImp, which extracts
898         meta-data from QStyleFacadeOption arguments, populates style
899         primitive specific QStyleOption objects and then calls on QStyle.
900
901         RenderThemeQStyle/ScrollbarThemeQStyle can only use interface methods
902         from QStyleFacade. QStyleFacadeImp on the other hand will live in the
903         separate QtWebKitWidgets library in the future and therefore cannot use
904         any WebCore types.
905
906         * Target.pri:
907         * platform/qt/QStyleFacade.cpp: Added.
908         (WebCore):
909         (WebCore::QStyleFacade::styleForPage):
910         * platform/qt/QStyleFacade.h: Added.
911         (WebCore):
912         (QStyleFacade):
913         (WebCore::QStyleFacade::~QStyleFacade):
914         (WebCore::QStyleFacadeOption::QStyleFacadeOption):
915         (QStyleFacadeOption):
916         * platform/qt/RenderThemeQStyle.cpp: Renamed from Source/WebKit/qt/WebCoreSupport/RenderThemeQStyle.cpp.
917         (WebCore):
918         (WebCore::RenderThemeQStyle::getStylePainter):
919         (WebCore::StylePainterQStyle::StylePainterQStyle):
920         (WebCore::StylePainterQStyle::init):
921         (WebCore::RenderThemeQStyle::create):
922         (WebCore::RenderThemeQStyle::setStyleFactoryFunction):
923         (WebCore::RenderThemeQStyle::styleFactory):
924         (WebCore::RenderThemeQStyle::RenderThemeQStyle):
925         (WebCore::RenderThemeQStyle::~RenderThemeQStyle):
926         (WebCore::RenderThemeQStyle::setPaletteFromPageClientIfExists):
927         (WebCore::RenderThemeQStyle::inflateButtonRect):
928         (WebCore::RenderThemeQStyle::computeSizeBasedOnStyle):
929         (WebCore::RenderThemeQStyle::adjustButtonStyle):
930         (WebCore::RenderThemeQStyle::setButtonPadding):
931         (WebCore::RenderThemeQStyle::paintButton):
932         (WebCore::RenderThemeQStyle::paintTextField):
933         (WebCore::RenderThemeQStyle::adjustTextAreaStyle):
934         (WebCore::RenderThemeQStyle::paintTextArea):
935         (WebCore::RenderThemeQStyle::setPopupPadding):
936         (WebCore::RenderThemeQStyle::colorPalette):
937         (WebCore::RenderThemeQStyle::paintMenuList):
938         (WebCore::RenderThemeQStyle::adjustMenuListButtonStyle):
939         (WebCore::RenderThemeQStyle::paintMenuListButton):
940         (WebCore::RenderThemeQStyle::animationDurationForProgressBar):
941         (WebCore::RenderThemeQStyle::paintProgressBar):
942         (WebCore::RenderThemeQStyle::paintSliderTrack):
943         (WebCore::RenderThemeQStyle::adjustSliderTrackStyle):
944         (WebCore::RenderThemeQStyle::paintSliderThumb):
945         (WebCore::RenderThemeQStyle::adjustSliderThumbStyle):
946         (WebCore::RenderThemeQStyle::paintSearchField):
947         (WebCore::RenderThemeQStyle::adjustSearchFieldDecorationStyle):
948         (WebCore::RenderThemeQStyle::paintSearchFieldDecoration):
949         (WebCore::RenderThemeQStyle::adjustSearchFieldResultsDecorationStyle):
950         (WebCore::RenderThemeQStyle::paintSearchFieldResultsDecoration):
951         (WebCore::RenderThemeQStyle::paintInnerSpinButton):
952         (WebCore::RenderThemeQStyle::initializeCommonQStyleOptions):
953         (WebCore::RenderThemeQStyle::adjustSliderThumbSize):
954         * platform/qt/RenderThemeQStyle.h: Renamed from Source/WebKit/qt/WebCoreSupport/RenderThemeQStyle.h.
955         (WebCore):
956         (RenderThemeQStyle):
957         (WebCore::RenderThemeQStyle::qStyle):
958         (StylePainterQStyle):
959         (WebCore::StylePainterQStyle::isValid):
960         (WebCore::StylePainterQStyle::paintButton):
961         (WebCore::StylePainterQStyle::paintTextField):
962         (WebCore::StylePainterQStyle::paintComboBox):
963         (WebCore::StylePainterQStyle::paintComboBoxArrow):
964         (WebCore::StylePainterQStyle::paintSliderTrack):
965         (WebCore::StylePainterQStyle::paintSliderThumb):
966         (WebCore::StylePainterQStyle::paintInnerSpinButton):
967         (WebCore::StylePainterQStyle::paintProgressBar):
968         (WebCore::StylePainterQStyle::paintScrollCorner):
969         (WebCore::StylePainterQStyle::paintScrollBar):
970         * platform/qt/ScrollbarThemeQStyle.cpp: Renamed from Source/WebKit/qt/WebCoreSupport/ScrollbarThemeQStyle.cpp.
971         (WebCore):
972         (WebCore::ScrollbarThemeQStyle::ScrollbarThemeQStyle):
973         (WebCore::ScrollbarThemeQStyle::~ScrollbarThemeQStyle):
974         (WebCore::scPart):
975         (WebCore::scrollbarPart):
976         (WebCore::initSliderStyleOption):
977         (WebCore::ScrollbarThemeQStyle::paint):
978         (WebCore::ScrollbarThemeQStyle::hitTest):
979         (WebCore::ScrollbarThemeQStyle::shouldCenterOnThumb):
980         (WebCore::ScrollbarThemeQStyle::invalidatePart):
981         (WebCore::ScrollbarThemeQStyle::scrollbarThickness):
982         (WebCore::ScrollbarThemeQStyle::thumbPosition):
983         (WebCore::ScrollbarThemeQStyle::thumbLength):
984         (WebCore::ScrollbarThemeQStyle::trackPosition):
985         (WebCore::ScrollbarThemeQStyle::trackLength):
986         (WebCore::ScrollbarThemeQStyle::paintScrollCorner):
987         * platform/qt/ScrollbarThemeQStyle.h: Renamed from Source/WebKit/qt/WebCoreSupport/ScrollbarThemeQStyle.h.
988         (WebCore):
989         (ScrollbarThemeQStyle):
990         (WebCore::ScrollbarThemeQStyle::qStyle):
991
992 2012-10-08  Kiran Muppala  <cmuppala@apple.com>
993
994         Throttle DOM timers on hidden pages.
995         https://bugs.webkit.org/show_bug.cgi?id=98474
996
997         Reviewed by Maciej Stachowiak.
998
999         When the visibility of a page changes to "hidden", all it's DOM timers are
1000         updated to align their fire times on one second intervals.  This limits the
1001         number of CPU wakes due to a hidden pages to one per second.
1002
1003         Test: fast/dom/timer-throttling-hidden-page.html
1004
1005         * Configurations/FeatureDefines.xcconfig:
1006         * WebCore.exp.in:
1007         * dom/Document.cpp:
1008         (WebCore):
1009         (WebCore::Document::timerAlignmentInterval):
1010         Read Page::timerAlignmentInterval and pass it along to DOMTimer.
1011
1012         * dom/Document.h:
1013         (Document):
1014         * dom/ScriptExecutionContext.cpp:
1015         (WebCore):
1016         (WebCore::ScriptExecutionContext::didChangeTimerAlignmentInterval):
1017         Scan through self DOM Timers and tell them to recompute their fire
1018         time based on the updated alignment interval.
1019         (WebCore::ScriptExecutionContext::timerAlignmentInterval):
1020
1021         * dom/ScriptExecutionContext.h:
1022         (ScriptExecutionContext):
1023         * page/DOMTimer.cpp:
1024         (WebCore):
1025         (WebCore::DOMTimer::alignedFireTime):
1026         If the document's alignment interval is non zero, round up the fire
1027         time to the next multiple of alignment interval.
1028
1029         * page/DOMTimer.h:
1030         (DOMTimer):
1031         (WebCore::DOMTimer::defaultTimerAlignmentInterval):
1032         (WebCore::DOMTimer::setDefaultTimerAlignmentInterval):
1033         * page/Page.cpp:
1034         (WebCore::Page::Page):
1035         (WebCore):
1036         (WebCore::Page::setTimerAlignmentInterval):
1037         (WebCore::Page::timerAlignmentInterval):
1038         (WebCore::Page::setVisibilityState):
1039         Getter and Setter for alignment interval.  Expose setVisibilityState
1040         if either PAGE_VISIBILITY_API is enabled or if HIDDEN_PAGE_DOM_TIMER_REDUCTION
1041         is enabled.
1042
1043         * page/Page.h:
1044         (Page):
1045         * page/Settings.cpp:
1046         (WebCore):
1047         (WebCore::Settings::setDefaultDOMTimerAlignmentInterval):
1048         (WebCore::Settings::defaultDOMTimerAlignmentInterval):
1049         (WebCore::Settings::setDOMTimerAlignmentInterval):
1050         (WebCore::Settings::domTimerAlignmentInterval):
1051         * page/Settings.h:
1052         (Settings):
1053         * page/SuspendableTimer.cpp:
1054         (WebCore::SuspendableTimer::suspend):
1055         Save the time remaining to the original unaligned fire time, so that
1056         on resuming, the fire time will be correctly aligned using the latest
1057         alignment interval.
1058
1059         * platform/ThreadTimers.cpp:
1060         (WebCore::ThreadTimers::sharedTimerFiredInternal):
1061         Clear m_unalignedNextFireTime along with m_nextFireTime to keep
1062         them always in sync.
1063
1064         * platform/Timer.cpp:
1065         (WebCore::TimerBase::TimerBase):
1066         (WebCore::TimerBase::setNextFireTime):
1067         Save the requested fire time in m_unalignedNextFireTime and
1068         set m_nextFireTime to the aligned value.  The unalinged value
1069         is used to recompute fire time if alignment interval changes.
1070         (WebCore):
1071         (WebCore::TimerBase::didChangeAlignmentInterval):
1072         Recompute next fire time from m_unalignedNextFireTime.
1073         (WebCore::TimerBase::nextUnalignedFireInterval):
1074         Interval from current time to the original unaligned fire time.
1075
1076         * platform/Timer.h:
1077         (TimerBase):
1078         (WebCore::TimerBase::alignedFireTime):
1079
1080 2012-10-08  Andreas Kling  <kling@webkit.org>
1081
1082         1.18MB below RenderTableSection::setCachedCollapsedBorderValue() on Membuster3.
1083         <http://webkit.org/b/98670>
1084         <rdar://problem/12454276>
1085
1086         Reviewed by Anders Carlsson.
1087
1088         Refactor CollapsedBorderValue to only store the bits and pieces from the BorderValue
1089         that it actually needs. Packed the whole thing into 64 bits.
1090
1091         Reduces memory consumption by 547kB on Membuster3.
1092
1093         * rendering/RenderTableCell.cpp:
1094
1095             Add compile-time size assertion for CollapsedBorderValue.
1096
1097         * rendering/style/CollapsedBorderValue.h:
1098         (WebCore::CollapsedBorderValue::CollapsedBorderValue):
1099         (WebCore::CollapsedBorderValue::width):
1100         (WebCore::CollapsedBorderValue::style):
1101         (WebCore::CollapsedBorderValue::color):
1102         (WebCore::CollapsedBorderValue::isTransparent):
1103         (WebCore::CollapsedBorderValue::precedence):
1104         (WebCore::CollapsedBorderValue::isSameIgnoringColor):
1105         (CollapsedBorderValue):
1106
1107             Apply shrinkwrap to CollapsedBorderValue. Removed specialized copy constructor since
1108             the class only has primitive members now.
1109
1110 2012-10-08  Yoshifumi Inoue  <yosin@chromium.org>
1111
1112         HTMLSelectElement::typeAheadFind depends on implementation dependent behavior
1113         https://bugs.webkit.org/show_bug.cgi?id=98710
1114
1115         Reviewed by Kent Tamura.
1116
1117         This patch gets rid of C/C++ implementation dependent behavior from
1118         HTMLSelectElement::typeAheadFind() which does modulo operation with
1119         a negative operand.
1120
1121         HTMLSelectElement::typeAheadFind() contains expression with modulo
1122         operator and dividend can be -1 when the "select" element without
1123         "option" element but "optgroup" element.
1124
1125         Test: fast/forms/select/select-typeahead-crash.html
1126
1127         * html/HTMLSelectElement.cpp:
1128         (WebCore::HTMLSelectElement::typeAheadFind): Changed to do modulo
1129         operation with both operands are non-negative.
1130
1131 2012-10-08  Kent Tamura  <tkent@chromium.org>
1132
1133         Take account of overflowing values for width calculation of a year sub-field
1134         https://bugs.webkit.org/show_bug.cgi?id=98506
1135
1136         Reviewed by Eric Seidel.
1137
1138         When we decide the width of a year field of an input[type=date]
1139         with the multiple fields UI, we need to take account of the
1140         current value width because we allow to set overflowing values to
1141         the input[type=date].
1142
1143         This change affects only platforms with INPUT_TYPE_DATE &&
1144         INPUT_MULTIPLE_FIELDS_UI.
1145
1146         Test: fast/forms/date-multiple-fields/date-multiple-fields-change-layout-by-value.html
1147
1148         * html/shadow/DateTimeNumericFieldElement.cpp:
1149         (WebCore::DateTimeNumericFieldElement::customStyleForRenderer):
1150         Take account of the current value width.
1151
1152 2012-10-08  Tony Chang  <tony@chromium.org>
1153
1154         image not displayed in flexbox
1155         https://bugs.webkit.org/show_bug.cgi?id=98611
1156
1157         Reviewed by Ojan Vafai.
1158
1159         Flexbox will override the width of a child and when stretching, will override the height of the child.
1160         When this happens, when an image loads, it checks to see if it's width/height has
1161         changed, and if so, does a relayout.  The overridden width/height was preventing this
1162         relayout from happening.
1163
1164         To fix, we clear all the override sizes when we're done laying out the flex children.
1165
1166         Test: css3/flexbox/relayout-image-load.html
1167
1168         * rendering/RenderFlexibleBox.cpp:
1169         (WebCore::RenderFlexibleBox::layoutBlock): Clear child override sizes.
1170         (WebCore::RenderFlexibleBox::clearChildOverrideSizes):
1171         (WebCore::RenderFlexibleBox::computeMainAxisPreferredSizes): No longer need to clear the override size
1172         here since it should have already been cleared.
1173         * rendering/RenderFlexibleBox.h:
1174
1175 2012-10-08  Andreas Kling  <kling@webkit.org>
1176
1177         REGRESSION(r130643): editing/pasteboard/data-transfer-item is failing on chromium.
1178         <http://webkit.org/b/98686>
1179
1180         Reviewed by Tony Chang.
1181
1182         Change ChromiumDataObject::createFromPasteboard() to use a ListHashSet instead of a HashSet so that
1183         item order is preserved.
1184
1185         * platform/chromium/ChromiumDataObject.cpp:
1186         (WebCore::ChromiumDataObject::createFromPasteboard):
1187
1188 2012-10-08  Eric Seidel  <eric@webkit.org>
1189
1190         Inline logicalHeightForRowSizing to shave another 2-3% off robohornet's resizecol.html
1191         https://bugs.webkit.org/show_bug.cgi?id=98703
1192
1193         Reviewed by Emil A Eklund.
1194
1195         This is very small potatoes.  There are much bigger wins for table layout yet, but
1196         this was an easy win.
1197
1198         This function should probably be converted to use int's only, as table cells are pixel-sized
1199         according to our subpixel-experts.
1200
1201         Also, I suspect there should be ways to early return with less-math in the common cases, but
1202         I've saved such for a later patch.
1203
1204         Note that I changed from using paddingBefore/paddingAfter (which include the instrinsic padding)
1205         to calling computedCSSPaddingBefore/computedCSSPaddingAfter directly as well.
1206
1207         This single function is about 11% of total time for robohornet's resizecol.
1208
1209         * rendering/RenderTableCell.cpp:
1210         * rendering/RenderTableCell.h:
1211         (WebCore::RenderTableCell::logicalHeightForRowSizing):
1212
1213 2012-10-08  Alec Flett  <alecflett@chromium.org>
1214
1215         IndexedDB: remove autogenerated objectStore/index id code
1216         https://bugs.webkit.org/show_bug.cgi?id=98085
1217
1218         Reviewed by Tony Chang.
1219
1220         Remove support for backend-generated objectstore and index
1221         ids. The frontend objects now manage that state during
1222         versionchange transactions. The IDBDatabaseBackendInterface and
1223         IDBObjectStoreBackendInterface methods will go away when
1224         https://bugs.webkit.org/show_bug.cgi?id=98682 lands.
1225
1226         No new tests as this is part of a refactoring, existing indexeddb
1227         tests cover correctness.
1228
1229         * Modules/indexeddb/IDBBackingStore.h:
1230         (IDBBackingStore):
1231         * Modules/indexeddb/IDBDatabase.cpp:
1232         (WebCore::IDBDatabase::createObjectStore):
1233         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
1234         (WebCore::IDBDatabaseBackendImpl::createObjectStore):
1235         (WebCore::IDBDatabaseBackendImpl::createObjectStoreInternal):
1236         (WebCore::IDBDatabaseBackendImpl::loadObjectStores):
1237         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
1238         (IDBDatabaseBackendInterface):
1239         * Modules/indexeddb/IDBLevelDBBackingStore.cpp:
1240         (WebCore::IDBLevelDBBackingStore::createObjectStore):
1241         (WebCore::setMaxIndexId):
1242         (WebCore::IDBLevelDBBackingStore::createIndex):
1243         * Modules/indexeddb/IDBLevelDBBackingStore.h:
1244         (IDBLevelDBBackingStore):
1245         * Modules/indexeddb/IDBObjectStore.cpp:
1246         (WebCore::IDBObjectStore::createIndex):
1247         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
1248         (WebCore::IDBObjectStoreBackendImpl::IDBObjectStoreBackendImpl):
1249         (WebCore::IDBObjectStoreBackendImpl::createIndex):
1250         (WebCore::IDBObjectStoreBackendImpl::createIndexInternal):
1251         * Modules/indexeddb/IDBObjectStoreBackendInterface.h:
1252
1253 2012-10-08  Jaehun Lim  <ljaehun.lim@samsung.com>
1254
1255         [CAIRO] Adjust the source rect size when IMAGE_DECODER_DOWN_SAMPLING is enabled
1256         https://bugs.webkit.org/show_bug.cgi?id=98630
1257
1258         Reviewed by Martin Robinson.
1259
1260         IMAGE_DECODER_DOWN_SAMPLING scales down the size of the big image.
1261         CAIRO needs to adjust the source size to the scaled value.
1262
1263         No new tests.
1264
1265         * platform/graphics/cairo/BitmapImageCairo.cpp:
1266         (WebCore::BitmapImage::draw):
1267
1268 2012-10-08  Adam Barth  <abarth@webkit.org>
1269
1270         Remove unused features of BlobBuilder
1271         https://bugs.webkit.org/show_bug.cgi?id=98331
1272
1273         Reviewed by Eric Seidel.
1274
1275         Now that we don't expose BlobBuilder as a web platform API, we can
1276         strip down the class to handle only those cases that are needed by the
1277         Blob constructor.
1278
1279         I've also renamed the class from WebKitBlobBuilder to BlobBuilder and
1280         made it stack allocated rather than RefCounted. A future patch will
1281         actually move the files around. (I didn't want to mix moving code
1282         around with modifying the code.)
1283
1284         * bindings/js/JSBlobCustom.cpp:
1285         (WebCore::JSBlobConstructor::constructJSBlob):
1286         * bindings/v8/custom/V8BlobCustom.cpp:
1287         (WebCore::V8Blob::constructorCallback):
1288         * fileapi/WebKitBlobBuilder.cpp:
1289         (WebCore):
1290         (WebCore::BlobBuilder::BlobBuilder):
1291         (WebCore::BlobBuilder::getBuffer):
1292         (WebCore::BlobBuilder::append):
1293         (WebCore::BlobBuilder::appendBytesData):
1294         (WebCore::BlobBuilder::getBlob):
1295         * fileapi/WebKitBlobBuilder.h:
1296         (WebCore):
1297         (BlobBuilder):
1298         * page/FeatureObserver.h:
1299
1300 2012-10-08  Martin Robinson  <mrobinson@igalia.com>
1301
1302         Try to fix the debug build after r130699
1303
1304         Move the assignment of the ResourceHandleInternal local to before
1305         the include statement where it is used.
1306
1307         * platform/network/soup/ResourceHandleSoup.cpp:
1308         (WebCore::createSoupMessageForHandleAndRequest):
1309
1310 2012-10-08  Nate Chapin  <japhet@chromium.org>
1311
1312         Post-r130226 Cleanup: Comment a complicated if statement and make it a helper.
1313         https://bugs.webkit.org/show_bug.cgi?id=98463
1314
1315         Reviewed by Eric Seidel.
1316
1317         No new tests, refactor only.
1318
1319         * rendering/RenderLayer.cpp:
1320         (WebCore::frameElementAndViewPermitScroll):
1321         (WebCore::RenderLayer::scrollRectToVisible):
1322
1323 2012-10-06  Martin Robinson  <mrobinson@igalia.com>
1324
1325         [Soup] Simplify the way that requests are started
1326         https://bugs.webkit.org/show_bug.cgi?id=98532
1327
1328         Reviewed by Gustavo Noronha Silva.
1329
1330         Simplify the creation of the libsoup request and message when kicking off
1331         requests, by elminating a bit of duplicate code.
1332
1333         No new tests. This should not change any behavior.
1334
1335         * platform/network/ResourceHandle.h:
1336         (ResourceHandle):
1337         * platform/network/soup/ResourceHandleSoup.cpp:
1338         (WebCore):
1339         (WebCore::ResourceHandleInternal::soupSession): Ensure the session
1340         is initialized when passing it to the caller.
1341         (WebCore::createSoupMessageForHandleAndRequest): Added this helper which
1342         takes care of creating the SoupMessage for HTTP/HTTPS requests.
1343         (WebCore::createSoupRequestAndMessageForHandle): Collapsed the HTTP and
1344         non-HTTP request creation into this helper.
1345         (WebCore::ResourceHandle::start): Call the new helper now and then sendPendingRequest.
1346         (WebCore::ResourceHandle::sendPendingRequest): Instead of having special
1347         helpers to create and send the request, duplicating the logic for sending it
1348         across the file, add this method which can be used in both cases.
1349         (WebCore::waitingToSendRequest): Reworked the hasBeenSent method to answer
1350         the question of whether or not the request is ready to be sent, but is unsent.
1351         (WebCore::ResourceHandle::platformSetDefersLoading): Use the new helper.
1352         * platform/network/soup/ResourceRequest.h:
1353         (ResourceRequest): Added a new method for getting the URL string for soup.
1354         * platform/network/soup/ResourceRequestSoup.cpp:
1355         (WebCore::ResourceRequest::urlStringForSoup): Added.
1356
1357 2012-10-08  Eric Seidel  <eric@webkit.org>
1358
1359         Make no-column table-layout cases a little faster with inlining
1360         https://bugs.webkit.org/show_bug.cgi?id=98566
1361
1362         Reviewed by Julien Chaffraix.
1363
1364         This change is almost not worth it at only a couple percent boost on
1365         http://www.robohornet.org/tests/resizecol.html
1366         However, I think the logicalWidthFromTableColumn split it kinda nice
1367         so I've decided to post it anyway.
1368
1369         * rendering/RenderTable.cpp:
1370         (WebCore::RenderTable::slowColElement):
1371         * rendering/RenderTable.h:
1372         (WebCore::RenderTable::colElement):
1373         (RenderTable):
1374         * rendering/RenderTableCell.cpp:
1375         (WebCore::RenderTableCell::logicalWidthFromTableColumn):
1376         * rendering/RenderTableCell.h:
1377         (WebCore::RenderTableCell::styleOrColLogicalWidth):
1378         (RenderTableCell):
1379
1380 2012-10-08  Arpita Bahuguna  <arpitabahuguna@gmail.com>
1381
1382         Rename RenderObject::firstLineStyleSlowCase() to a more appropriate cachedFirstLineStyle()
1383         https://bugs.webkit.org/show_bug.cgi?id=98631
1384
1385         Reviewed by Eric Seidel.
1386
1387         Renaming firstLineStyleSlowCase() to cachedFirstLineStyle().
1388
1389         The current name is confusing since the function actually gets the
1390         the cached first-line styles.
1391         It also makes the name more descriptive of its functionality
1392         and in accordance with RenderObject::uncachedFirstLineStyle().
1393
1394         No new tests required for this change since no change in behavior is expected.
1395
1396         * rendering/RenderObject.cpp:
1397         (WebCore::RenderObject::cachedFirstLineStyle):
1398         * rendering/RenderObject.h:
1399         (WebCore::RenderObject::firstLineStyle):
1400         (RenderObject):
1401         Renamed RenderObject::firstLineStyleSlowCase() to cachedFirstLineStyle()
1402         and made the associated changes.
1403
1404 2012-10-08  Sami Kyostila  <skyostil@chromium.org>
1405
1406         Some non-scrollable elements are added to non-fast-scrollable region
1407         https://bugs.webkit.org/show_bug.cgi?id=97927
1408
1409         Reviewed by James Robinson.
1410
1411         Only RenderLayers that can actually be scrolled should be added to the
1412         ScrollingCoordinator's non-fast scrollable region. Otherwise we may
1413         needlessly fall back to main thread scrolling.
1414
1415         Test: ScrollingCoordinatorChromiumTest.clippedBodyTest
1416
1417         * rendering/RenderLayer.cpp:
1418         (WebCore::RenderLayer::updateScrollbarsAfterLayout):
1419         (WebCore::RenderLayer::updateScrollbarsAfterStyleChange):
1420
1421 2012-10-08  Simon Fraser  <simon.fraser@apple.com>
1422
1423         Move layerTreeAsText to window.internals
1424         https://bugs.webkit.org/show_bug.cgi?id=98690
1425
1426         Reviewed by James Robinson.
1427
1428         Add window.internals.layerTreeAsText(document), and change the tests to use it.
1429         I'll remove testRunner.layerTreeAsText() in a later patch.
1430
1431         * testing/Internals.cpp:
1432         (WebCore::Internals::layerTreeAsText):
1433         * testing/Internals.h:
1434         (Internals):
1435         * testing/Internals.idl:
1436
1437 2012-10-08  Jon Lee  <jonlee@apple.com>
1438
1439         Add render object that paints plugin snapshots
1440         https://bugs.webkit.org/show_bug.cgi?id=98322
1441         <rdar://problem/12426546>
1442
1443         Reviewed by Simon Fraser.
1444
1445         First, teach plugins to maintain a set of states when plugin snapshotting is enabled.
1446
1447         Second, a new RenderSnapshottedPlugIn class is a RenderEmbeddedObject that knows how to paint
1448         snapshots when the plugin is not visibly playing. It maintains a RenderImageResource to
1449         the generated poster image.
1450
1451         * html/HTMLPlugInElement.cpp:
1452         (WebCore::HTMLPlugInElement::HTMLPlugInElement): By default all plugins play on load.
1453         * html/HTMLPlugInElement.h: Move the inheritance of ImageLoaderClientBase down to
1454         HTMLPlugInImageElement, since that is the class that actually deals with image-based plugins.
1455         (WebCore::HTMLPlugInElement::displayState): Add bit for display state.
1456         (WebCore::HTMLPlugInElement::setDisplayState):
1457         (WebCore::HTMLPlugInElement::updateSnapshot):
1458
1459         * html/HTMLPlugInImageElement.cpp:
1460         (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement): If plugin snapshotting is
1461         enabled, plugin state is set to wait for a poster image.
1462         (WebCore::HTMLPlugInImageElement::createRenderer): Create RenderSnapshottedPlugIn if
1463         plugin snapshotting is enabled.
1464         (WebCore::HTMLPlugInImageElement::updateSnapshot): Once a snapshot is available, update the
1465         renderer and set its state to wait for user input to start the plugin.
1466         * html/HTMLPlugInImageElement.h:
1467         (HTMLPlugInImageElement):
1468
1469         * rendering/RenderObject.h:
1470         (WebCore::RenderObject::isSnapshottedPlugIn): Add new function to identify
1471         RenderSnapshottedPlugIn instances. Since RenderSnapshottedPlugIn inherits from
1472         RenderEmbeddedObject, isEmbeddedObject() still returns true.
1473         * rendering/RenderEmbeddedObject.h:
1474         (RenderEmbeddedObject): Elevate a few virtual methods to protected for
1475         RenderSnapshottedPlugIn to override.
1476
1477         * rendering/RenderSnapshottedPlugIn.cpp: Added.
1478         (WebCore::RenderSnapshottedPlugIn::RenderSnapshottedPlugIn): Initialize snapshot
1479         resource.
1480         (WebCore::RenderSnapshottedPlugIn::~RenderSnapshottedPlugIn): Shut down snapshot
1481         image resource to remove the renderer as a client, and remove image from memory cache.
1482         (WebCore::RenderSnapshottedPlugIn::plugInImageElement): Convenience function to get the
1483         HTML element.
1484         (WebCore::RenderSnapshottedPlugIn::updateSnapshot): Cache the snapshot, and repaint.
1485         (WebCore::RenderSnapshottedPlugIn::paint): If the plugin is not playing, paint like a
1486         RenderImage does.
1487         (WebCore::RenderSnapshottedPlugIn::paintReplaced): Paint the snapshot and overlay if the
1488         plugin is not playing.
1489         (WebCore::RenderSnapshottedPlugIn::paintReplacedSnapshot): Inspired by
1490         RenderImage::paintReplaced() and RenderImage::paintIntoRect().
1491         * rendering/RenderSnapshottedPlugIn.h: Added.
1492         (WebCore::RenderSnapshottedPlugIn::isSnapshottedPlugin): Returns true.
1493
1494         * rendering/RenderTheme.h: Add a function that paints the overlay on top of the snapshot.
1495         * rendering/RenderThemeMac.h:
1496         * rendering/RenderThemeMac.mm:
1497         (WebCore::RenderThemeMac::paintPlugInSnapshotOverlay):
1498
1499         * WebCore.xcodeproj/project.pbxproj: Add new RenderSnapshottedPlugIn class.
1500         * CMakeLists.txt: Ditto.
1501         * GNUmakefile.list.am: Ditto.
1502         * Target.pri: Ditto.
1503         * WebCore.gypi: Ditto.
1504         * WebCore.vcproj/WebCore.vcproj: Ditto.
1505         * rendering/RenderingAllInOne.cpp: Ditto.
1506
1507 2012-10-08  Hans Muller  <hmuller@adobe.com>
1508
1509         [CSS Exclusions] Add support for polygonal shapes
1510         https://bugs.webkit.org/show_bug.cgi?id=96811
1511
1512         Reviewed by Dirk Schulze.
1513
1514         Initial version of the layout support for polygonal exclusion shapes: the ExclusionPolygon class.
1515         Supports the public ExclusionShape operations using the algorithm described here:
1516         http://hansmuller-webkit.blogspot.com/2012/06/horizontal-box-polygon-intersection-for.html.
1517         Although both the "included" and "excluded" operations are supported, only the former is
1518         used, since only shape-inside is supported at the moment.
1519
1520         The ExclusionPolygon class stores the polygon's edges in an interval tree.
1521
1522         Polygon edges are represented by the ExclusionPolygonEdge struct, which records the indices of
1523         the pair of vertices joined by the edge.  Edge vertex index1 is usually less than index2, except
1524         the last edge where index2 is 0.  We plan to improve the algorithm that creates the edges
1525         by spanning vertices contained in sequences of more than two colinear vertices. For example,
1526         a triangular polygon might be specified with 5 vertices like this: 3,0 5,0, 5,5, 4,4 2,2, 0,0.
1527         By spanning the extra colinear points: 0,0 5,0, 5,5, which implies index1-index2 edges: 5-1 1-2 2-5.
1528
1529         Although the implementation supports complex polygons, the layout code is limited to
1530         essentially rectangular shapes until a patch for https://bugs.webkit.org/show_bug.cgi?id=96813
1531         lands.
1532
1533         Tests: fast/exclusions/shape-inside/shape-inside-polygon-rectangle.html
1534                fast/exclusions/shape-inside/shape-inside-simple-polygon-001.html
1535                fast/exclusions/shape-inside/shape-inside-simple-polygon-002.html
1536                fast/exclusions/shape-inside/shape-inside-simple-polygon-003.html
1537                fast/exclusions/shape-inside/shape-inside-simple-polygon-004.html
1538
1539         * CMakeLists.txt:
1540         * GNUmakefile.list.am:
1541         * Target.pri:
1542         * WebCore.gypi:
1543         * WebCore.vcproj/WebCore.vcproj:
1544         * WebCore.xcodeproj/project.pbxproj:
1545         * rendering/ExclusionPolygon.cpp: Added.
1546         (WebCore):
1547         (EdgeIntersection): Internal description of the intersection of a polygon edge and a horizontal line.
1548         (WebCore::ExclusionPolygon::ExclusionPolygon): See the introductory text above for a description of this type.
1549         (WebCore::computeXIntersection): Find and classify the X intercept of a polygon edge with horizontal line, if any.
1550         (WebCore::ExclusionPolygon::rightVertexY): This method is used to decide if a horizontal line "crosses" a vertex.
1551         (WebCore::appendIntervalX): Append an x coordinate to a vector of ExclusionIntervals.
1552         (WebCore::ExclusionPolygon::computeXIntersections): Return a vector of the intersections of a horizontal line with the polygon's edges.
1553         (WebCore::ExclusionPolygon::computeEdgeIntersections): Return a vector of the X projections of the edges that overlap a horizonal rectangle.
1554         (WebCore::ExclusionPolygon::getExcludedIntervals): Return a SegmentList of the X intervals within a horizontal rectangle that overlap the polygon.
1555         (WebCore::ExclusionPolygon::getIncludedIntervals): Return the X intervals within a horizontal rectangle that fit inside the polygon.
1556         * rendering/ExclusionPolygon.h: Added.
1557         (WebCore):
1558         (ExclusionPolygon):
1559         (WebCore::ExclusionPolygon::getXAt): X coordinate of a polygon vertex
1560         (WebCore::ExclusionPolygon::getYAt): Y coordinate of a polygon vertex
1561         (WebCore::ExclusionPolygon::numberOfVertices):
1562         (WebCore::ExclusionPolygon::fillRule): A WindRule value that defines "inside" for self-intersecting polygons.
1563         (ExclusionPolygonEdge):
1564         (WebCore::ExclusionPolygonEdge::ExclusionPolygonEdge):
1565         (WebCore::ExclusionPolygonEdge::vertex1):
1566         (WebCore::ExclusionPolygonEdge::vertex2):
1567         (WebCore::ExclusionPolygonEdge::minX):
1568         (WebCore::ExclusionPolygonEdge::minY):
1569         (WebCore::ExclusionPolygonEdge::maxX):
1570         (WebCore::ExclusionPolygonEdge::maxY):
1571         * rendering/ExclusionShape.cpp:
1572         (WebCore::createExclusionPolygon): Return a new ExclusionPolygon.
1573         (WebCore):
1574         (WebCore::ExclusionShape::createExclusionShape): Added support for BasicShape::BASIC_SHAPE_POLYGON.
1575         * rendering/ExclusionShapeInsideInfo.cpp:
1576         (WebCore::ExclusionShapeInsideInfo::isExclusionShapeInsideInfoEnabledForRenderBlock): Enable BASIC_SHAPE_POLYGON shapes for RenderBlocks.
1577
1578 2012-10-08  Tony Chang  <tony@chromium.org>
1579
1580         Replace 2 uses of updateLogicalHeight with computeLogicalHeight
1581         https://bugs.webkit.org/show_bug.cgi?id=98677
1582
1583         Reviewed by Ojan Vafai.
1584
1585         This is part of bug 96804.  Convert RenderTextControl and RenderSVGForeignObject to
1586         override the const computeLogicalHeight method rather than the updateLogicalHeight
1587         setter method.
1588
1589         No new tests, there should be no behavior change as this is just a refactor.
1590
1591         * rendering/RenderTextControl.cpp:
1592         (WebCore::RenderTextControl::computeLogicalHeight): Pass logicalHeight through rather than setting height.
1593         This is a slight correctness fix, although we don't support vertical inputs yet.
1594         * rendering/RenderTextControl.h:
1595         (RenderTextControl):
1596         * rendering/svg/RenderSVGForeignObject.cpp:
1597         (WebCore::RenderSVGForeignObject::computeLogicalHeight):
1598         * rendering/svg/RenderSVGForeignObject.h:
1599         (RenderSVGForeignObject):
1600
1601 2012-10-08  Min Qin  <qinmin@chromium.org>
1602
1603         Upstream some tweaks for overlay play button on Android
1604         https://bugs.webkit.org/show_bug.cgi?id=98671
1605
1606         Reviewed by Adam Barth.
1607
1608         This change stops displaying the overlay play button if video height is too small
1609         No test for this. Will rebase layout test expectations for android later.
1610
1611         * css/mediaControlsChromiumAndroid.css:
1612         (video::-webkit-media-controls-overlay-enclosure):
1613
1614 2012-10-08  Simon Fraser  <simon.fraser@apple.com>
1615
1616         Some GraphicsLayer cleanup to separate the concepts of using a tile cache, and being the main tile cache layer
1617         https://bugs.webkit.org/show_bug.cgi?id=98574
1618
1619         Reviewed by Dean Jackson.
1620
1621         GraphicsLayerCA assumed that using a TileCache equated to being the main page tile
1622         cache layer, which has some special considerations. Make these two concepts separate
1623         to get closer to being able to use TileCaches in place of CATiledLayer.
1624
1625         * platform/graphics/GraphicsLayer.h:
1626         (GraphicsLayer): Remove m_usingTileCache member, which was not appropriate
1627         for this class to have.
1628         * platform/graphics/GraphicsLayer.cpp:
1629         (WebCore::GraphicsLayer::GraphicsLayer): Remove init of m_usingTileCache.
1630         (WebCore::GraphicsLayer::debugBorderInfo): Can no longer use m_usingTileCache to
1631         get the blue color, so moved code into a virtual debugBorderInfo() method.
1632         (WebCore::GraphicsLayer::updateDebugIndicators): Call the virtual debugBorderInfo().
1633         * platform/graphics/GraphicsLayerClient.h: Remove the usingTileCache() callback;
1634         we now just cache this information in the GraphicsLayerCA on creation.
1635         * platform/graphics/ca/GraphicsLayerCA.cpp:
1636         (WebCore::GraphicsLayerCA::GraphicsLayerCA): Init m_isPageTileCacheLayer to false,
1637         then set to m_isPageTileCacheLayer if the client says we should create a tile cache.
1638         (WebCore::GraphicsLayerCA::platformCALayerShowRepaintCounter): Overidden to avoid duplicate repaint
1639         counters in the top-left tile.
1640         (WebCore::GraphicsLayerCA::updateLayerBackgroundColor): If this layer is the page tile cache layer,
1641         we allow setting of its background color.
1642         (WebCore::GraphicsLayerCA::debugBorderInfo): Overidden to use a blue color for tiles.
1643         (WebCore::GraphicsLayerCA::requiresTiledLayer): Don't make CATiledLayers for the page tile cache.
1644         * platform/graphics/ca/GraphicsLayerCA.h:
1645         (GraphicsLayerCA):
1646         * platform/graphics/ca/PlatformCALayerClient.h:
1647         (PlatformCALayerClient): Need to pass the platform layer into platformCALayerShowRepaintCounter()
1648         so we can distinguish between calls for tiles, and calls for the tile cache layer itself.
1649         * platform/graphics/ca/mac/TileCache.mm:
1650         (WebCore::TileCache::shouldShowRepaintCounters): Pass 0 to platformCALayerShowRepaintCounter() to
1651         indicate that we're asking about a tile.
1652         * platform/graphics/mac/WebLayer.mm:
1653         (drawLayerContents): Now we can just rely on platformCALayerShowRepaintCounter() to tell us whether
1654         to draw the repaint counter.
1655         (-[WebLayer setNeedsDisplayInRect:]):
1656         * platform/graphics/mac/WebTiledLayer.mm:
1657         (-[WebTiledLayer setNeedsDisplayInRect:]):
1658         * rendering/RenderLayerBacking.h:
1659         (WebCore::RenderLayerBacking::usingTileCache):
1660         (RenderLayerBacking):
1661         * rendering/RenderLayerCompositor.cpp:
1662         (WebCore::RenderLayerCompositor::documentBackgroundColorDidChange): We can ask the RenderLayerBacking
1663         whether it's for the tile cache, rather than going to the GraphicsLayer.
1664         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
1665         (WebCore::MediaPlayerPrivateQuickTimeVisualContext::LayerClient::platformCALayerShowRepaintCounter):
1666
1667 2012-10-08  Huang Dongsung  <luxtella@company100.net>
1668
1669         [Qt] Make ImageBufferQt use premultiplied converting functions in Color.h instead of its own mechanism.
1670         https://bugs.webkit.org/show_bug.cgi?id=98582
1671
1672         Reviewed by Eric Seidel.
1673
1674         Only Qt port failed canvas/philip/tests/2d.imageData.put.unchanged.html because
1675         ImageBufferQt converts from or to a premultiplied color using its own code. When
1676         we convert twice from an unmultiplied color to a premultiplied color and then to
1677         an unmultiplied color using this code, the calculated result are pretty
1678         different against the input color. It is why Gtk passes this test although Qt
1679         fails. Gtk port uses them in Color.h.
1680
1681         In addition, Qt should use the functions in Color.h to reduce duplicated codes.
1682
1683         Tests: canvas/philip/tests/2d.imageData.put.unchanged.html: Fixed a test case
1684
1685         * platform/graphics/qt/ImageBufferQt.cpp:
1686         (WebCore::getImageData):
1687         (WebCore::convertBGRAToRGBA):
1688         (WebCore::ImageBuffer::putByteArray):
1689
1690 2012-10-08  Tab Atkins  <jackalmage@gmail.com>
1691
1692         Remove "orphaned units" quirk
1693         https://bugs.webkit.org/show_bug.cgi?id=98553
1694
1695         Reviewed by Eric Seidel.
1696
1697         This patch removes our "orphaned units" quirk.
1698         We have an "orphaned units" quirk to match IE, which allows things like "width: 20 px;".
1699         But FF and Opera don't have it and aren't aware of bugs for it,
1700         and it's not in Simon Pieters' Quirks Mode spec <http://dvcs.w3.org/hg/quirks-mode/raw-file/tip/Overview.html>
1701
1702         No new tests, because I'm killing a quirk.
1703
1704         * css/CSSParser.cpp:
1705         (WebCore::CSSParser::parseValue):
1706         * css/CSSParser.h:
1707         (CSSParser):
1708
1709 2012-10-08  Robert Hogan  <robert@webkit.org>
1710
1711         Border, margin and padding of an inline's inline ancestors counted twice
1712         https://bugs.webkit.org/show_bug.cgi?id=63074
1713
1714         Reviewed by David Hyatt.
1715
1716         In a line such as '<span><span><img>Text' the border, padding and margin belonging
1717         to the two spans was counted twice by RenderBlockLineLayout::nextLineBreak(): once
1718         when adding the width of the <img> object to the line, and a second time when adding
1719         the 'Text'. The result was that nextLineBreak() now had a length for the line that 
1720         exceeded the line's maximum length and inserted a bogus line break.
1721
1722         This all happened because the helper function that is used to add in the border etc.
1723         from inline ancestors was crawling up the tree each time. It doesn't need to do that, it
1724         should stop crawling up the tree when the current object is not the first or last sibling below a parent.
1725
1726         Test: fast/inline/bpm-inline-ancestors.html
1727
1728         * rendering/RenderBlockLineLayout.cpp:
1729         (WebCore::shouldAddBorderPaddingMargin): Broke this check out into a helper function so that it 
1730         can help inlineLogicalWidth() return early and also treat empty RenderTexts the same as no previous/next
1731         sibling on the line. This ensures that collapsed leading space does not interfere with the decision to
1732         crawl up the ancestors accumulating border, padding, and margin.
1733         (WebCore):
1734         (WebCore::inlineLogicalWidth): Return early once the current child is no longer on the edge of its line - 
1735         this ensures the border, padding and margin of ancestors is not counted twice. 
1736
1737 2012-10-08  Mike West  <mkwst@chromium.org>
1738
1739         Null-check for DOMWindow before feeding it to FeatureObserver.
1740         https://bugs.webkit.org/show_bug.cgi?id=98624
1741
1742         Reviewed by Adam Barth.
1743
1744         We shouldn't call out to FeatureObserver in
1745         ContentSecurityPolicy::didReceiveHeader if the policy's document doesn't
1746         have a DOMWindow.
1747
1748         Test: http/tests/security/contentSecurityPolicy/xmlhttprequest-protected-resource-does-not-crash.html
1749
1750         * page/ContentSecurityPolicy.cpp:
1751         (WebCore::ContentSecurityPolicy::didReceiveHeader):
1752             Null check 'document->domWindow' before passing it on.
1753         * page/FeatureObserver.cpp:
1754         (WebCore::FeatureObserver::observe):
1755             ASSERT 'domWindow'.
1756
1757 2012-10-08  Nate Chapin  <japhet@chromium.org>
1758
1759         Loader cleanup : Simplify FrameLoader/DocumentLoader setupForReplace()
1760         https://bugs.webkit.org/show_bug.cgi?id=49072
1761
1762         Reviewed by Eric Seidel.
1763
1764         This patch contains one small known behavior change: multipart/x-mixed-replace main resources with text/html parts
1765         will no longer load the text/html progressively. In practice, loading the html progressively causes the document
1766         to get cleared as soon as the next part's data starts arriving, which leads to a blank page most of the time. This case
1767         seems to be pathological, as IE, FF, Opera and WebKit all do something different currently. This patch will cause
1768         us to behave like Firefox, which is the most sane of the current behaviors.
1769
1770         Test: http/tests/multipart/multipart-html.php
1771
1772         * loader/DocumentLoader.cpp:
1773         (WebCore::DocumentLoader::commitData): Use isMultipartReplacingLoad() helper.
1774         (WebCore::DocumentLoader::receivedData):
1775         (WebCore::DocumentLoader::setupForReplace): Renamed from setupForReplaceByMIMEType(). Call maybeFinishLoadingMultipartContent()
1776             instead of doing identical work inline. After we call frameLoader()->setReplacing(), we will never load progressively, so remove
1777             the if (doesProgressiveLoad(newMIMEType)) {} block.
1778         (WebCore::DocumentLoader::isMultipartReplacingLoad):
1779         (WebCore::DocumentLoader::maybeFinishLoadingMultipartContent): Inline the old DocumentLoader::setupForeReplace(), check
1780             frameLoader()->isReplacing() instead of the delete doesProgressiveLoad().
1781         * loader/DocumentLoader.h:
1782         * loader/FrameLoader.cpp:
1783         (WebCore::FrameLoader::setupForReplace): Move all calls to revertToProvisionalState here.
1784         * loader/MainResourceLoader.cpp:
1785         (WebCore::MainResourceLoader::didReceiveResponse): Call setupForReplace(), renamed from setupForReplaceByMIMEType().
1786
1787 2012-10-08  Zoltan Horvath  <zoltan@webkit.org>
1788
1789         [Qt] r122720 causes performance regression with DirectFB on ARMv7
1790         https://bugs.webkit.org/show_bug.cgi?id=97548
1791
1792         Reviewed by Jocelyn Turcotte.
1793
1794         Revert the rest of r122720. This change modifies the NativeImagePtr from QImage* to QPixmap*.
1795
1796         Covered by existing tests.
1797
1798         * bridge/qt/qt_pixmapruntime.cpp:
1799         (JSC::Bindings::assignToHTMLImageElement):
1800         (JSC::Bindings::QtPixmapRuntime::toQt):
1801         * platform/DragImage.h:
1802         (WebCore):
1803         * platform/graphics/GraphicsContext.h:
1804         (GraphicsContext):
1805         * platform/graphics/Image.h:
1806         (Image):
1807         * platform/graphics/NativeImagePtr.h:
1808         (WebCore):
1809         * platform/graphics/gstreamer/ImageGStreamer.h:
1810         * platform/graphics/gstreamer/ImageGStreamerQt.cpp:
1811         (ImageGStreamer::ImageGStreamer):
1812         * platform/graphics/qt/GraphicsContext3DQt.cpp:
1813         (WebCore::GraphicsContext3D::getImageData):
1814         * platform/graphics/qt/GraphicsContextQt.cpp:
1815         (WebCore::GraphicsContext::pushTransparencyLayerInternal):
1816         (WebCore::GraphicsContext::beginPlatformTransparencyLayer):
1817         (WebCore::GraphicsContext::endPlatformTransparencyLayer):
1818         * platform/graphics/qt/ImageBufferDataQt.h:
1819         (ImageBufferData):
1820         * platform/graphics/qt/ImageBufferQt.cpp:
1821         (WebCore::ImageBufferData::ImageBufferData):
1822         (WebCore):
1823         (WebCore::ImageBufferData::toQImage):
1824         (WebCore::ImageBuffer::copyImage):
1825         (WebCore::ImageBuffer::clip):
1826         (WebCore::ImageBuffer::platformTransformColorSpace):
1827         (WebCore::getImageData):
1828         (WebCore::ImageBuffer::putByteArray):
1829         (WebCore::encodeImage):
1830         (WebCore::ImageBuffer::toDataURL):
1831         * platform/graphics/qt/ImageDecoderQt.cpp:
1832         (WebCore::ImageFrame::asNewNativeImage):
1833         * platform/graphics/qt/ImageQt.cpp:
1834         (graphics):
1835         (loadResourcePixmap):
1836         (WebCore::Image::loadPlatformResource):
1837         (WebCore::Image::setPlatformResource):
1838         (WebCore::Image::drawPattern):
1839         (WebCore::BitmapImage::BitmapImage):
1840         (WebCore::BitmapImage::draw):
1841         (WebCore::BitmapImage::checkForSolidColor):
1842         (WebCore::BitmapImage::create):
1843         * platform/graphics/qt/PatternQt.cpp:
1844         (WebCore::Pattern::createPlatformPattern):
1845         * platform/graphics/qt/StillImageQt.cpp:
1846         (WebCore::StillImage::StillImage):
1847         (WebCore::StillImage::~StillImage):
1848         (WebCore::StillImage::currentFrameHasAlpha):
1849         (WebCore::StillImage::size):
1850         (WebCore::StillImage::nativeImageForCurrentFrame):
1851         (WebCore::StillImage::draw):
1852         * platform/graphics/qt/StillImageQt.h:
1853         (WebCore::StillImage::create):
1854         (WebCore::StillImage::createForRendering):
1855         (StillImage):
1856         * platform/graphics/qt/TransparencyLayer.h:
1857         (WebCore::TransparencyLayer::TransparencyLayer):
1858         (TransparencyLayer):
1859         * platform/graphics/surfaces/qt/GraphicsSurfaceQt.cpp:
1860         (WebCore::GraphicsSurface::createReadOnlyImage):
1861         * platform/graphics/texmap/TextureMapperGL.cpp:
1862         (WebCore::BitmapTextureGL::updateContents):
1863         * platform/qt/ClipboardQt.cpp:
1864         (WebCore::ClipboardQt::createDragImage):
1865         (WebCore::ClipboardQt::declareAndWriteDragImage):
1866         * platform/qt/CursorQt.cpp:
1867         (WebCore::createCustomCursor):
1868         * platform/qt/DragImageQt.cpp:
1869         (WebCore::createDragImageFromImage):
1870         * platform/qt/PasteboardQt.cpp:
1871         (WebCore::Pasteboard::writeImage):
1872
1873 2012-10-08  Carlos Garcia Campos  <cgarcia@igalia.com>
1874
1875         Unreviewed. Fix make distcheck.
1876
1877         * GNUmakefile.list.am: Add missing header file to compilation.
1878
1879 2012-10-08  Sheriff Bot  <webkit.review.bot@gmail.com>
1880
1881         Unreviewed, rolling out r130619.
1882         http://trac.webkit.org/changeset/130619
1883         https://bugs.webkit.org/show_bug.cgi?id=98634
1884
1885         Causes many crashes on the EFL bots. (Requested by rakuco on
1886         #webkit).
1887
1888         * platform/RunLoop.h:
1889         (RunLoop):
1890         * platform/efl/RunLoopEfl.cpp:
1891         (WebCore::RunLoop::RunLoop):
1892         (WebCore::RunLoop::wakeUpEvent):
1893         (WebCore::RunLoop::wakeUp):
1894
1895 2012-10-08  Byungwoo Lee  <bw80.lee@samsung.com>
1896
1897         [EFL] Use ecore_main_loop_thread_safe_call_async() to wakeup main loop.
1898         https://bugs.webkit.org/show_bug.cgi?id=98505
1899
1900         Reviewed by Kenneth Rohde Christiansen.
1901
1902         Instead of ecore_pipe_write(),
1903         use ecore_main_loop_thread_safe_call_async() to wakeup ecore main loop.
1904
1905         According to the EFL API document, this function is designed to dispatch
1906         a function on ecore main loop by avoiding dead lock or race condition. 
1907         With this function, webkit doesn't need to maintain ecore pipe also.
1908
1909         No new tests. The function to wakeup main loop is changed.
1910
1911         * platform/RunLoop.h:
1912         (RunLoop):
1913         * platform/efl/RunLoopEfl.cpp:
1914         (WebCore::RunLoop::RunLoop):
1915         (WebCore::RunLoop::wakeUpEvent):
1916         (WebCore::RunLoop::wakeUp):
1917
1918 2012-10-07  Arpita Bahuguna  <arpitabahuguna@gmail.com>
1919
1920         :first-line pseudo selector ignoring words created from :before
1921         https://bugs.webkit.org/show_bug.cgi?id=80794
1922
1923         Reviewed by Daniel Bates.
1924
1925         The :first-line pseudo-element style is not applied for content
1926         which is generated from the :before/:after pseudo-elements.
1927
1928         Test: fast/css/first-line-style-for-before-after-content.html
1929
1930         * rendering/RenderObject.cpp:
1931         (WebCore::firstLineStyleForCachedUncachedType):
1932         Added a new static helper function incorporating the common
1933         functionality of both uncachedFirstLineStyle() and firstLineStyleSlowCase()
1934         functions. It also modifies the functionality to handle the
1935         scenario when :first-line style needs to be applied on content
1936         generated from :before/:after.
1937
1938         While getting the :first-line style we should also consider the case
1939         when the content is generated from a :before/:after pseudo-element in
1940         which case the RenderInline's parent should be considered for
1941         obtaining the first-line style.
1942
1943         (WebCore):
1944         (WebCore::RenderObject::uncachedFirstLineStyle):
1945         (WebCore::RenderObject::firstLineStyleSlowCase):
1946         Moved the duplicate code between the two functions to the common
1947         helper function firstLineStyleForCachedUncachedType().
1948
1949 2012-10-07  Peter Wang  <peter.wang@torchmobile.com.cn>
1950
1951         Web Inspector: The front-end should provide the position in original source file when set a breakpoint
1952         https://bugs.webkit.org/show_bug.cgi?id=93473
1953
1954         Reviewed by Yury Semikhatsky.
1955
1956         Since frontend truncates the indent, the first statement in a line must match the breakpoint (line, 0).
1957         With this patch JSC debugger can support both normal and "Pretty Print" mode.
1958
1959         No new test case. This patch can be verified with cases in "LayoutTests/inspector/debugger/".
1960
1961         * bindings/js/ScriptDebugServer.cpp:
1962         (WebCore::ScriptDebugServer::ScriptDebugServer):
1963         (WebCore::ScriptDebugServer::hasBreakpoint):
1964         (WebCore::ScriptDebugServer::createCallFrameAndPauseIfNeeded):
1965         (WebCore::ScriptDebugServer::pauseIfNeeded):
1966         * bindings/js/ScriptDebugServer.h:
1967         (ScriptDebugServer):
1968
1969 2012-10-07  Martin Robinson  <mrobinson@igalia.com>
1970
1971         [Soup] Clean up ResourceError creation
1972         https://bugs.webkit.org/show_bug.cgi?id=98521
1973
1974         Reviewed by Carlos Garcia Campos.
1975
1976         Simplify the creation of ResourcErrors in ResourceHandleSoup. This is
1977         part of a process to make the libsoup networking backend more hackable.
1978
1979         No new tests. This shouldn't change functionality.
1980
1981         * GNUmakefile.list.am: Added new file.
1982         * PlatformEfl.cmake: Added new file.
1983         * platform/network/soup/ResourceError.h:
1984         (ResourceError): Added new factories.
1985         * platform/network/soup/ResourceErrorSoup.cpp: Added.
1986         (WebCore::failingURI): Added this helper.
1987         (WebCore::ResourceError::httpError): New factory.
1988         (WebCore::ResourceError::genericIOError): Ditto.
1989         (WebCore::ResourceError::tlsError): Ditto.
1990         (WebCore::ResourceError::timeoutError): Ditto.
1991         * platform/network/soup/ResourceHandleSoup.cpp:
1992         (WebCore::handleUnignoredTLSErrors): Created this helper which merges
1993         some of the logic from sendRequestCallback.
1994         (WebCore::sendRequestCallback): Use the new helper.
1995         (WebCore::requestTimeoutCallback): Use the new factory.
1996
1997 2012-10-07  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
1998
1999         Rename first/second to key/value in HashMap iterators
2000         https://bugs.webkit.org/show_bug.cgi?id=82784
2001
2002         Reviewed by Eric Seidel.
2003
2004         * Modules/geolocation/Geolocation.cpp:
2005         (WebCore::Geolocation::Watchers::find):
2006         (WebCore::Geolocation::Watchers::remove):
2007         * Modules/indexeddb/IDBDatabase.cpp:
2008         (WebCore::IDBDatabase::objectStoreNames):
2009         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
2010         (WebCore::IDBDatabaseBackendImpl::metadata):
2011         * Modules/indexeddb/IDBFactoryBackendImpl.cpp:
2012         (WebCore::IDBFactoryBackendImpl::deleteDatabase):
2013         (WebCore::IDBFactoryBackendImpl::openBackingStore):
2014         (WebCore::IDBFactoryBackendImpl::open):
2015         * Modules/indexeddb/IDBObjectStore.cpp:
2016         (WebCore::IDBObjectStore::indexNames):
2017         (WebCore::IDBObjectStore::put):
2018         (WebCore::IDBObjectStore::index):
2019         (WebCore::IDBObjectStore::deleteIndex):
2020         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
2021         (WebCore::IDBObjectStoreBackendImpl::metadata):
2022         (WebCore::makeIndexWriters):
2023         (WebCore::IDBObjectStoreBackendImpl::deleteInternal):
2024         * Modules/indexeddb/IDBTransaction.cpp:
2025         (WebCore::IDBTransaction::objectStore):
2026         (WebCore::IDBTransaction::objectStoreDeleted):
2027         (WebCore::IDBTransaction::onAbort):
2028         (WebCore::IDBTransaction::dispatchEvent):
2029         * Modules/mediastream/MediaConstraintsImpl.cpp:
2030         (WebCore::MediaConstraintsImpl::getMandatoryConstraints):
2031         (WebCore::MediaConstraintsImpl::getMandatoryConstraintValue):
2032         * Modules/webdatabase/AbstractDatabase.cpp:
2033         (WebCore::AbstractDatabase::performOpenAndVerify):
2034         * Modules/webdatabase/DatabaseTracker.cpp:
2035         (WebCore::DatabaseTracker::interruptAllDatabasesForContext):
2036         * Modules/webdatabase/OriginUsageRecord.cpp:
2037         (WebCore::OriginUsageRecord::diskUsage):
2038         * Modules/webdatabase/SQLTransactionCoordinator.cpp:
2039         (WebCore::SQLTransactionCoordinator::acquireLock):
2040         (WebCore::SQLTransactionCoordinator::releaseLock):
2041         (WebCore::SQLTransactionCoordinator::shutdown):
2042         * Modules/webdatabase/chromium/DatabaseTrackerChromium.cpp:
2043         (WebCore::DatabaseTracker::interruptAllDatabasesForContext):
2044         * Modules/webdatabase/chromium/QuotaTracker.cpp:
2045         (WebCore::QuotaTracker::getDatabaseSizeAndSpaceAvailableToOrigin):
2046         (WebCore::QuotaTracker::updateDatabaseSize):
2047         * Modules/websockets/WebSocketDeflateFramer.cpp:
2048         (WebCore::WebSocketExtensionDeflateFrame::processResponse):
2049         * Modules/websockets/WebSocketExtensionDispatcher.cpp:
2050         (WebCore::WebSocketExtensionDispatcher::appendAcceptedExtension):
2051         * accessibility/AXObjectCache.cpp:
2052         (WebCore::AXObjectCache::~AXObjectCache):
2053         * bindings/gobject/DOMObjectCache.cpp:
2054         (WebKit::DOMObjectCache::clearByFrame):
2055         * bindings/js/DOMObjectHashTableMap.h:
2056         (WebCore::DOMObjectHashTableMap::~DOMObjectHashTableMap):
2057         (WebCore::DOMObjectHashTableMap::get):
2058         * bindings/js/JSDOMBinding.cpp:
2059         (WebCore::cacheDOMStructure):
2060         * bindings/js/JSDOMGlobalObject.cpp:
2061         (WebCore::JSDOMGlobalObject::visitChildren):
2062         * bindings/js/JSDOMGlobalObject.h:
2063         (WebCore::getDOMConstructor):
2064         * bindings/js/PageScriptDebugServer.cpp:
2065         (WebCore::PageScriptDebugServer::addListener):
2066         (WebCore::PageScriptDebugServer::removeListener):
2067         * bindings/js/ScriptCachedFrameData.cpp:
2068         (WebCore::ScriptCachedFrameData::ScriptCachedFrameData):
2069         (WebCore::ScriptCachedFrameData::restore):
2070         * bindings/js/ScriptController.cpp:
2071         (WebCore::ScriptController::~ScriptController):
2072         (WebCore::ScriptController::clearWindowShell):
2073         (WebCore::ScriptController::attachDebugger):
2074         (WebCore::ScriptController::updateDocument):
2075         (WebCore::ScriptController::createRootObject):
2076         (WebCore::ScriptController::collectIsolatedContexts):
2077         (WebCore::ScriptController::cleanupScriptObjectsForPlugin):
2078         (WebCore::ScriptController::clearScriptObjects):
2079         * bindings/js/ScriptController.h:
2080         (WebCore::ScriptController::windowShell):
2081         (WebCore::ScriptController::existingWindowShell):
2082         * bindings/js/ScriptDebugServer.cpp:
2083         (WebCore::ScriptDebugServer::setBreakpoint):
2084         (WebCore::ScriptDebugServer::removeBreakpoint):
2085         (WebCore::ScriptDebugServer::hasBreakpoint):
2086         * bindings/js/SerializedScriptValue.cpp:
2087         (WebCore::CloneSerializer::checkForDuplicate):
2088         (WebCore::CloneSerializer::dumpIfTerminal):
2089         (WebCore::CloneSerializer::write):
2090         * bindings/scripts/CodeGeneratorV8.pm:
2091         (GenerateImplementation):
2092         * bindings/scripts/test/V8/V8Float64Array.cpp:
2093         (WebCore::V8Float64Array::GetRawTemplate):
2094         (WebCore::V8Float64Array::GetTemplate):
2095         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
2096         (WebCore::V8TestActiveDOMObject::GetRawTemplate):
2097         (WebCore::V8TestActiveDOMObject::GetTemplate):
2098         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
2099         (WebCore::V8TestCustomNamedGetter::GetRawTemplate):
2100         (WebCore::V8TestCustomNamedGetter::GetTemplate):
2101         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
2102         (WebCore::V8TestEventConstructor::GetRawTemplate):
2103         (WebCore::V8TestEventConstructor::GetTemplate):
2104         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
2105         (WebCore::V8TestEventTarget::GetRawTemplate):
2106         (WebCore::V8TestEventTarget::GetTemplate):
2107         * bindings/scripts/test/V8/V8TestException.cpp:
2108         (WebCore::V8TestException::GetRawTemplate):
2109         (WebCore::V8TestException::GetTemplate):
2110         * bindings/scripts/test/V8/V8TestInterface.cpp:
2111         (WebCore::V8TestInterface::GetRawTemplate):
2112         (WebCore::V8TestInterface::GetTemplate):
2113         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
2114         (WebCore::V8TestMediaQueryListListener::GetRawTemplate):
2115         (WebCore::V8TestMediaQueryListListener::GetTemplate):
2116         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
2117         (WebCore::V8TestNamedConstructor::GetRawTemplate):
2118         (WebCore::V8TestNamedConstructor::GetTemplate):
2119         * bindings/scripts/test/V8/V8TestNode.cpp:
2120         (WebCore::V8TestNode::GetRawTemplate):
2121         (WebCore::V8TestNode::GetTemplate):
2122         * bindings/scripts/test/V8/V8TestObj.cpp:
2123         (WebCore::V8TestObj::GetRawTemplate):
2124         (WebCore::V8TestObj::GetTemplate):
2125         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
2126         (WebCore::V8TestSerializedScriptValueInterface::GetRawTemplate):
2127         (WebCore::V8TestSerializedScriptValueInterface::GetTemplate):
2128         * bindings/v8/DOMWrapperWorld.cpp:
2129         (WebCore::DOMWrapperWorld::deallocate):
2130         (WebCore::DOMWrapperWorld::ensureIsolatedWorld):
2131         * bindings/v8/NPV8Object.cpp:
2132         (WebCore::freeV8NPObject):
2133         (WebCore::npCreateV8ScriptObject):
2134         * bindings/v8/ScriptController.cpp:
2135         (WebCore::ScriptController::clearScriptObjects):
2136         (WebCore::ScriptController::resetIsolatedWorlds):
2137         (WebCore::ScriptController::ensureIsolatedWorldContext):
2138         (WebCore::ScriptController::existingWindowShellInternal):
2139         (WebCore::ScriptController::evaluateInIsolatedWorld):
2140         (WebCore::ScriptController::setIsolatedWorldSecurityOrigin):
2141         (WebCore::ScriptController::cleanupScriptObjectsForPlugin):
2142         (WebCore::ScriptController::collectIsolatedContexts):
2143         * bindings/v8/SerializedScriptValue.cpp:
2144         * bindings/v8/V8DOMMap.h:
2145         (WebCore::WeakReferenceMap::removeIfPresent):
2146         (WebCore::WeakReferenceMap::visit):
2147         * bindings/v8/V8PerContextData.cpp:
2148         (WebCore::V8PerContextData::dispose):
2149         * bindings/v8/npruntime.cpp:
2150         * bridge/IdentifierRep.cpp:
2151         (WebCore::IdentifierRep::get):
2152         * bridge/NP_jsobject.cpp:
2153         (ObjectMap::add):
2154         (ObjectMap::remove):
2155         * bridge/runtime_root.cpp:
2156         (JSC::Bindings::RootObject::invalidate):
2157         * css/CSSCanvasValue.cpp:
2158         (WebCore::CSSCanvasValue::canvasChanged):
2159         (WebCore::CSSCanvasValue::canvasResized):
2160         * css/CSSComputedStyleDeclaration.cpp:
2161         (WebCore::counterToCSSValue):
2162         * css/CSSCrossfadeValue.cpp:
2163         (WebCore::CSSCrossfadeValue::crossfadeChanged):
2164         * css/CSSFontFaceSource.cpp:
2165         (WebCore::CSSFontFaceSource::getFontData):
2166         * css/CSSFontSelector.cpp:
2167         (WebCore::CSSFontSelector::addFontFaceRule):
2168         (WebCore::CSSFontSelector::getFontData):
2169         * css/CSSImageGeneratorValue.cpp:
2170         (WebCore::CSSImageGeneratorValue::addClient):
2171         (WebCore::CSSImageGeneratorValue::removeClient):
2172         (WebCore::CSSImageGeneratorValue::getImage):
2173         * css/CSSSegmentedFontFace.cpp:
2174         (WebCore::CSSSegmentedFontFace::getFontData):
2175         * css/CSSSelector.cpp:
2176         (WebCore::CSSSelector::parsePseudoType):
2177         * css/CSSValuePool.cpp:
2178         (WebCore::CSSValuePool::createColorValue):
2179         (WebCore::CSSValuePool::createFontFamilyValue):
2180         (WebCore::CSSValuePool::createFontFaceValue):
2181         * css/PropertySetCSSStyleDeclaration.cpp:
2182         (WebCore::PropertySetCSSStyleDeclaration::cloneAndCacheForCSSOM):
2183         * css/RuleSet.cpp:
2184         (WebCore::reportAtomRuleMap):
2185         (WebCore::RuleSet::addToRuleSet):
2186         (WebCore::shrinkMapVectorsToFit):
2187         * css/StyleBuilder.cpp:
2188         (WebCore::ApplyPropertyCounter::applyInheritValue):
2189         (WebCore::ApplyPropertyCounter::applyValue):
2190         * css/StyleResolver.cpp:
2191         (WebCore::StyleResolver::collectFeatures):
2192         (WebCore::StyleResolver::ruleSetForScope):
2193         (WebCore::StyleResolver::appendAuthorStylesheets):
2194         (WebCore::StyleResolver::sweepMatchedPropertiesCache):
2195         (WebCore::StyleResolver::collectMatchingRulesForList):
2196         * css/StyleSheetContents.cpp:
2197         (WebCore::StyleSheetContents::parserAddNamespace):
2198         (WebCore::StyleSheetContents::determineNamespace):
2199         * dom/CheckedRadioButtons.cpp:
2200         (WebCore::CheckedRadioButtons::addButton):
2201         (WebCore::CheckedRadioButtons::removeButton):
2202         * dom/ChildListMutationScope.cpp:
2203         (WebCore::ChildListMutationAccumulator::getOrCreate):
2204         * dom/Document.cpp:
2205         (WebCore::Document::windowNamedItems):
2206         (WebCore::Document::documentNamedItems):
2207         (WebCore::Document::getCSSCanvasElement):
2208         (WebCore::Document::cachedImmutableAttributeData):
2209         (WebCore::Document::getCachedLocalizer):
2210         * dom/DocumentMarkerController.cpp:
2211         (WebCore::DocumentMarkerController::markerContainingPoint):
2212         (WebCore::DocumentMarkerController::renderedRectsForMarkers):
2213         (WebCore::DocumentMarkerController::removeMarkers):
2214         (WebCore::DocumentMarkerController::repaintMarkers):
2215         (WebCore::DocumentMarkerController::invalidateRenderedRectsForMarkersInRect):
2216         (WebCore::DocumentMarkerController::showMarkers):
2217         * dom/DocumentOrderedMap.cpp:
2218         (WebCore::DocumentOrderedMap::remove):
2219         * dom/DocumentStyleSheetCollection.cpp:
2220         (WebCore::DocumentStyleSheetCollection::pageGroupUserSheets):
2221         * dom/ElementAttributeData.cpp:
2222         (WebCore::ensureAttrListForElement):
2223         * dom/EventDispatcher.cpp:
2224         (WebCore::EventRelatedTargetAdjuster::findRelatedTarget):
2225         * dom/IdTargetObserverRegistry.cpp:
2226         (WebCore::IdTargetObserverRegistry::addObserver):
2227         (WebCore::IdTargetObserverRegistry::removeObserver):
2228         * dom/MutationObserverInterestGroup.cpp:
2229         (WebCore::MutationObserverInterestGroup::isOldValueRequested):
2230         (WebCore::MutationObserverInterestGroup::enqueueMutationRecord):
2231         * dom/Node.cpp:
2232         (WebCore::Node::dumpStatistics):
2233         (WebCore::Node::clearRareData):
2234         (WebCore::NodeListsNodeData::invalidateCaches):
2235         (WebCore::collectMatchingObserversForMutation):
2236         * dom/NodeRareData.h:
2237         (WebCore::NodeListsNodeData::addCacheWithAtomicName):
2238         (WebCore::NodeListsNodeData::addCacheWithName):
2239         (WebCore::NodeListsNodeData::addCacheWithQualifiedName):
2240         (WebCore::NodeListsNodeData::adoptTreeScope):
2241         * dom/ProcessingInstruction.cpp:
2242         (WebCore::ProcessingInstruction::checkStyleSheet):
2243         * dom/ScriptExecutionContext.cpp:
2244         (WebCore::ScriptExecutionContext::canSuspendActiveDOMObjects):
2245         (WebCore::ScriptExecutionContext::suspendActiveDOMObjects):
2246         (WebCore::ScriptExecutionContext::resumeActiveDOMObjects):
2247         (WebCore::ScriptExecutionContext::stopActiveDOMObjects):
2248         (WebCore::ScriptExecutionContext::adjustMinimumTimerInterval):
2249         * dom/SelectorQuery.cpp:
2250         (WebCore::SelectorQueryCache::add):
2251         * dom/SpaceSplitString.cpp:
2252         (WebCore::SpaceSplitStringData::create):
2253         * dom/StyledElement.cpp:
2254         (WebCore::StyledElement::updateAttributeStyle):
2255         * editing/mac/AlternativeTextUIController.mm:
2256         (WebCore::AlternativeTextUIController::AlernativeTextContextController::alternativesForContext):
2257         * html/FormController.cpp:
2258         (WebCore::SavedFormState::serializeTo):
2259         (WebCore::SavedFormState::appendControlState):
2260         (WebCore::SavedFormState::takeControlState):
2261         (WebCore::SavedFormState::getReferencedFilePaths):
2262         (WebCore::FormKeyGenerator::formKey):
2263         (WebCore::FormController::createSavedFormStateMap):
2264         (WebCore::FormController::formElementsState):
2265         (WebCore::FormController::takeStateForFormElement):
2266         (WebCore::FormController::getReferencedFilePaths):
2267         * html/HTMLCollection.cpp:
2268         (WebCore::HTMLCollectionCacheBase::append):
2269         * html/canvas/WebGLFramebuffer.cpp:
2270         (WebCore::WebGLFramebuffer::getAttachment):
2271         (WebCore::WebGLFramebuffer::removeAttachmentFromBoundFramebuffer):
2272         (WebCore::WebGLFramebuffer::checkStatus):
2273         (WebCore::WebGLFramebuffer::deleteObjectImpl):
2274         (WebCore::WebGLFramebuffer::initializeAttachments):
2275         * inspector/CodeGeneratorInspector.py:
2276         * inspector/DOMPatchSupport.cpp:
2277         (WebCore::DOMPatchSupport::diff):
2278         (WebCore::DOMPatchSupport::innerPatchChildren):
2279         (WebCore::DOMPatchSupport::removeChildAndMoveToNew):
2280         * inspector/InjectedScriptManager.cpp:
2281         (WebCore::InjectedScriptManager::injectedScriptForId):
2282         (WebCore::InjectedScriptManager::injectedScriptIdFor):
2283         (WebCore::InjectedScriptManager::discardInjectedScriptsFor):
2284         (WebCore::InjectedScriptManager::releaseObjectGroup):
2285         (WebCore::InjectedScriptManager::injectedScriptFor):
2286         * inspector/InspectorCSSAgent.cpp:
2287         (WebCore::SelectorProfile::commitSelector):
2288         (WebCore::SelectorProfile::commitSelectorTime):
2289         (WebCore::SelectorProfile::toInspectorObject):
2290         (WebCore::UpdateRegionLayoutTask::onTimer):
2291         (WebCore::InspectorCSSAgent::forcePseudoState):
2292         (WebCore::InspectorCSSAgent::asInspectorStyleSheet):
2293         (WebCore::InspectorCSSAgent::assertStyleSheetForId):
2294         (WebCore::InspectorCSSAgent::didRemoveDOMNode):
2295         (WebCore::InspectorCSSAgent::didModifyDOMAttr):
2296         (WebCore::InspectorCSSAgent::resetPseudoStates):
2297         * inspector/InspectorConsoleAgent.cpp:
2298         (WebCore::InspectorConsoleAgent::stopTiming):
2299         (WebCore::InspectorConsoleAgent::count):
2300         * inspector/InspectorDOMAgent.cpp:
2301         (WebCore::InspectorDOMAgent::nodeForId):
2302         (WebCore::InspectorDOMAgent::performSearch):
2303         (WebCore::InspectorDOMAgent::getSearchResults):
2304         * inspector/InspectorDOMDebuggerAgent.cpp:
2305         (WebCore::InspectorDOMDebuggerAgent::willSendXMLHttpRequest):
2306         * inspector/InspectorDOMStorageAgent.cpp:
2307         (WebCore::InspectorDOMStorageAgent::clearFrontend):
2308         (WebCore::InspectorDOMStorageAgent::enable):
2309         (WebCore::InspectorDOMStorageAgent::storageId):
2310         (WebCore::InspectorDOMStorageAgent::getDOMStorageResourceForId):
2311         (WebCore::InspectorDOMStorageAgent::didUseDOMStorage):
2312         (WebCore::InspectorDOMStorageAgent::memoryBytesUsedByStorageCache):
2313         * inspector/InspectorDatabaseAgent.cpp:
2314         (WebCore::InspectorDatabaseAgent::enable):
2315         (WebCore::InspectorDatabaseAgent::databaseId):
2316         (WebCore::InspectorDatabaseAgent::findByFileName):
2317         (WebCore::InspectorDatabaseAgent::databaseForId):
2318         * inspector/InspectorDebuggerAgent.cpp:
2319         (WebCore::InspectorDebuggerAgent::setBreakpointByUrl):
2320         (WebCore::InspectorDebuggerAgent::removeBreakpoint):
2321         (WebCore::InspectorDebuggerAgent::resolveBreakpoint):
2322         (WebCore::InspectorDebuggerAgent::searchInContent):
2323         (WebCore::InspectorDebuggerAgent::getScriptSource):
2324         (WebCore::InspectorDebuggerAgent::didParseSource):
2325         * inspector/InspectorIndexedDBAgent.cpp:
2326         (WebCore):
2327         * inspector/InspectorMemoryAgent.cpp:
2328         (WebCore):
2329         * inspector/InspectorPageAgent.cpp:
2330         (WebCore::cachedResourcesForFrame):
2331         (WebCore::InspectorPageAgent::didClearWindowObjectInWorld):
2332         (WebCore::InspectorPageAgent::frameDetached):
2333         * inspector/InspectorProfilerAgent.cpp:
2334         (WebCore::InspectorProfilerAgent::getProfileHeaders):
2335         (WebCore):
2336         (WebCore::InspectorProfilerAgent::getProfile):
2337         * inspector/InspectorResourceAgent.cpp:
2338         (WebCore::buildObjectForHeaders):
2339         (WebCore::InspectorResourceAgent::willSendRequest):
2340         (WebCore::InspectorResourceAgent::documentThreadableLoaderStartedLoadingForClient):
2341         (WebCore::InspectorResourceAgent::willLoadXHR):
2342         (WebCore::InspectorResourceAgent::replayXHR):
2343         * inspector/InspectorState.cpp:
2344         (WebCore::InspectorState::getBoolean):
2345         (WebCore::InspectorState::getString):
2346         (WebCore::InspectorState::getLong):
2347         (WebCore::InspectorState::getDouble):
2348         (WebCore::InspectorState::getObject):
2349         * inspector/InspectorStyleSheet.cpp:
2350         (WebCore::InspectorStyle::styleWithProperties):
2351         (WebCore::InspectorStyleSheet::inspectorStyleForId):
2352         * inspector/InspectorValues.cpp:
2353         (WebCore::InspectorObjectBase::get):
2354         (WebCore::InspectorObjectBase::writeJSON):
2355         * inspector/InspectorWorkerAgent.cpp:
2356         (WebCore::InspectorWorkerAgent::workerContextTerminated):
2357         (WebCore::InspectorWorkerAgent::createWorkerFrontendChannelsForExistingWorkers):
2358         (WebCore::InspectorWorkerAgent::destroyWorkerFrontendChannels):
2359         * inspector/MemoryInstrumentationImpl.cpp:
2360         (WebCore::MemoryInstrumentationClientImpl::countObjectSize):
2361         * inspector/MemoryInstrumentationImpl.h:
2362         (WebCore::MemoryInstrumentationClientImpl::totalSize):
2363         (WebCore::MemoryInstrumentationClientImpl::reportedSizeForAllTypes):
2364         * inspector/NetworkResourcesData.cpp:
2365         (WebCore::NetworkResourcesData::setXHRReplayData):
2366         (WebCore::NetworkResourcesData::removeCachedResource):
2367         (WebCore::NetworkResourcesData::clear):
2368         * loader/CrossOriginAccessControl.cpp:
2369         (WebCore::isSimpleCrossOriginAccessRequest):
2370         (WebCore::createAccessControlPreflightRequest):
2371         * loader/CrossOriginPreflightResultCache.cpp:
2372         (WebCore::CrossOriginPreflightResultCacheItem::allowsCrossOriginHeaders):
2373         (WebCore::CrossOriginPreflightResultCache::canSkipPreflight):
2374         * loader/DocumentLoader.cpp:
2375         (WebCore::DocumentLoader::getSubresources):
2376         (WebCore::DocumentLoader::substituteResourceDeliveryTimerFired):
2377         * loader/MainResourceLoader.cpp:
2378         (WebCore::MainResourceLoader::didReceiveResponse):
2379         * loader/ResourceLoadScheduler.cpp:
2380         (WebCore::ResourceLoadScheduler::servePendingRequests):
2381         * loader/appcache/ApplicationCache.cpp:
2382         (WebCore::ApplicationCache::removeResource):
2383         (WebCore::ApplicationCache::clearStorageID):
2384         (WebCore::ApplicationCache::dump):
2385         * loader/appcache/ApplicationCacheGroup.cpp:
2386         (WebCore::ApplicationCacheGroup::didFinishLoadingManifest):
2387         (WebCore::ApplicationCacheGroup::startLoadingEntry):
2388         (WebCore::ApplicationCacheGroup::addEntry):
2389         * loader/appcache/ApplicationCacheHost.cpp:
2390         (WebCore::ApplicationCacheHost::fillResourceList):
2391         * loader/appcache/ApplicationCacheResource.cpp:
2392         (WebCore::ApplicationCacheResource::estimatedSizeInStorage):
2393         * loader/appcache/ApplicationCacheStorage.cpp:
2394         (WebCore::ApplicationCacheStorage::findOrCreateCacheGroup):
2395         (WebCore::ApplicationCacheStorage::cacheGroupForURL):
2396         (WebCore::ApplicationCacheStorage::fallbackCacheGroupForURL):
2397         (WebCore::ApplicationCacheStorage::store):
2398         (WebCore::ApplicationCacheStorage::empty):
2399         (WebCore::ApplicationCacheStorage::storeCopyOfCache):
2400         * loader/archive/ArchiveFactory.cpp:
2401         (WebCore::ArchiveFactory::registerKnownArchiveMIMETypes):
2402         * loader/cache/CachedRawResource.cpp:
2403         (WebCore::CachedRawResource::canReuse):
2404         * loader/cache/CachedResource.cpp:
2405         (WebCore::CachedResource::switchClientsToRevalidatedResource):
2406         (WebCore::CachedResource::updateResponseAfterRevalidation):
2407         * loader/cache/CachedResourceClientWalker.h:
2408         (WebCore::CachedResourceClientWalker::CachedResourceClientWalker):
2409         * loader/cache/CachedResourceLoader.cpp:
2410         (WebCore::CachedResourceLoader::~CachedResourceLoader):
2411         (WebCore::CachedResourceLoader::requestResource):
2412         (WebCore::CachedResourceLoader::reloadImagesIfNotDeferred):
2413         (WebCore::CachedResourceLoader::removeCachedResource):
2414         (WebCore::CachedResourceLoader::garbageCollectDocumentResources):
2415         * loader/cache/MemoryCache.cpp:
2416         (WebCore::MemoryCache::removeResourcesWithOrigin):
2417         (WebCore::MemoryCache::getOriginsWithCache):
2418         (WebCore::MemoryCache::getStatistics):
2419         (WebCore::MemoryCache::setDisabled):
2420         * loader/icon/IconDatabase.cpp:
2421         (WebCore::IconDatabase::removeAllIcons):
2422         (WebCore::IconDatabase::iconRecordCountWithData):
2423         (WebCore::IconDatabase::performPendingRetainAndReleaseOperations):
2424         * page/DOMWindow.cpp:
2425         (WebCore::DOMWindow::dispatchAllPendingBeforeUnloadEvents):
2426         (WebCore::DOMWindow::dispatchAllPendingUnloadEvents):
2427         * page/EventHandler.cpp:
2428         (WebCore::EventHandler::handleTouchEvent):
2429         * page/Frame.cpp:
2430         (WebCore::Frame::injectUserScripts):
2431         * page/PageGroup.cpp:
2432         (WebCore::PageGroup::pageGroup):
2433         (WebCore::PageGroup::closeLocalStorage):
2434         (WebCore::PageGroup::clearLocalStorageForAllOrigins):
2435         (WebCore::PageGroup::clearLocalStorageForOrigin):
2436         (WebCore::PageGroup::syncLocalStorage):
2437         (WebCore::PageGroup::addUserScriptToWorld):
2438         (WebCore::PageGroup::addUserStyleSheetToWorld):
2439         (WebCore::PageGroup::removeUserScriptFromWorld):
2440         (WebCore::PageGroup::removeUserStyleSheetFromWorld):
2441         * page/PageSerializer.cpp:
2442         (WebCore::PageSerializer::urlForBlankFrame):
2443         * page/SecurityPolicy.cpp:
2444         (WebCore::SecurityPolicy::addOriginAccessWhitelistEntry):
2445         (WebCore::SecurityPolicy::removeOriginAccessWhitelistEntry):
2446         * page/Settings.cpp:
2447         (WebCore::setGenericFontFamilyMap):
2448         (WebCore::getGenericFontFamilyForScript):
2449         * page/SpeechInput.cpp:
2450         (WebCore::SpeechInput::registerListener):
2451         * page/TouchDisambiguation.cpp:
2452         (WebCore::findGoodTouchTargets):
2453         * page/WindowFeatures.cpp:
2454         (WebCore::WindowFeatures::boolFeature):
2455         (WebCore::WindowFeatures::floatFeature):
2456         * page/animation/AnimationController.cpp:
2457         (WebCore::AnimationControllerPrivate::updateAnimations):
2458         (WebCore::AnimationControllerPrivate::suspendAnimationsForDocument):
2459         (WebCore::AnimationControllerPrivate::resumeAnimationsForDocument):
2460         (WebCore::AnimationControllerPrivate::numberOfActiveAnimations):
2461         * page/animation/CompositeAnimation.cpp:
2462         (WebCore::CompositeAnimation::clearRenderer):
2463         (WebCore::CompositeAnimation::updateTransitions):
2464         (WebCore::CompositeAnimation::updateKeyframeAnimations):
2465         (WebCore::CompositeAnimation::animate):
2466         (WebCore::CompositeAnimation::getAnimatedStyle):
2467         (WebCore::CompositeAnimation::setAnimating):
2468         (WebCore::CompositeAnimation::timeToNextService):
2469         (WebCore::CompositeAnimation::getAnimationForProperty):
2470         (WebCore::CompositeAnimation::suspendAnimations):
2471         (WebCore::CompositeAnimation::resumeAnimations):
2472         (WebCore::CompositeAnimation::overrideImplicitAnimations):
2473         (WebCore::CompositeAnimation::resumeOverriddenImplicitAnimations):
2474         (WebCore::CompositeAnimation::isAnimatingProperty):
2475         (WebCore::CompositeAnimation::numberOfActiveAnimations):
2476         * platform/Language.cpp:
2477         (WebCore::languageDidChange):
2478         * platform/MIMETypeRegistry.cpp:
2479         (WebCore::MIMETypeRegistry::getNormalizedMIMEType):
2480         * platform/audio/HRTFElevation.cpp:
2481         (WebCore::getConcatenatedImpulseResponsesForSubject):
2482         * platform/blackberry/CookieManager.cpp:
2483         (WebCore::CookieManager::generateHtmlFragmentForCookies):
2484         (WebCore::CookieManager::removeAllCookies):
2485         * platform/blackberry/CookieMap.cpp:
2486         (WebCore::CookieMap::removeOldestCookie):
2487         (WebCore::CookieMap::getAllChildCookies):
2488         * platform/cf/BinaryPropertyList.cpp:
2489         (WebCore::BinaryPropertyListPlan::writeIntegerArray):
2490         * platform/chromium/support/WebHTTPLoadInfo.cpp:
2491         (WebKit::addHeader):
2492         * platform/chromium/support/WebURLRequest.cpp:
2493         (WebKit::WebURLRequest::visitHTTPHeaderFields):
2494         * platform/chromium/support/WebURLResponse.cpp:
2495         (WebKit::WebURLResponse::addHTTPHeaderField):
2496         (WebKit::WebURLResponse::visitHTTPHeaderFields):
2497         * platform/graphics/DisplayRefreshMonitor.cpp:
2498         (WebCore::DisplayRefreshMonitorManager::ensureMonitorForClient):
2499         (WebCore::DisplayRefreshMonitorManager::unregisterClient):
2500         * platform/graphics/FontCache.cpp:
2501         (WebCore::FontCache::getCachedFontPlatformData):
2502         (WebCore::FontCache::getVerticalData):
2503         (WebCore::FontCache::getCachedFontData):
2504         (WebCore::FontCache::releaseFontData):
2505         (WebCore::FontCache::purgeInactiveFontData):
2506         * platform/graphics/GlyphPageTreeNode.cpp:
2507         (WebCore::GlyphPageTreeNode::treeGlyphPageCount):
2508         (WebCore::GlyphPageTreeNode::pageCount):
2509         (WebCore::GlyphPageTreeNode::pruneTreeCustomFontData):
2510         (WebCore::GlyphPageTreeNode::pruneTreeFontData):
2511         (WebCore::GlyphPageTreeNode::pruneCustomFontData):
2512         (WebCore::GlyphPageTreeNode::pruneFontData):
2513         (WebCore::GlyphPageTreeNode::showSubtree):
2514         (showGlyphPageTrees):
2515         * platform/graphics/TiledBackingStore.cpp:
2516         (WebCore::TiledBackingStore::updateTileBuffers):
2517         (WebCore::TiledBackingStore::resizeEdgeTiles):
2518         (WebCore::TiledBackingStore::setKeepRect):
2519         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
2520         (WebCore::AVFWrapper::avfWrapperForCallbackContext):
2521         * platform/graphics/blackberry/LayerTiler.cpp:
2522         (WebCore::LayerTiler::layerVisibilityChanged):
2523         (WebCore::LayerTiler::uploadTexturesIfNeeded):
2524         (WebCore::LayerTiler::addTileJob):
2525         (WebCore::LayerTiler::deleteTextures):
2526         (WebCore::LayerTiler::pruneTextures):
2527         (WebCore::LayerTiler::bindContentsTexture):
2528         * platform/graphics/blackberry/TextureCacheCompositingThread.cpp:
2529         (WebCore::TextureCacheCompositingThread::textureForTiledContents):
2530         (WebCore::TextureCacheCompositingThread::textureForColor):
2531         * platform/graphics/ca/GraphicsLayerCA.cpp:
2532         (WebCore::GraphicsLayerCA::moveOrCopyAnimations):
2533         (WebCore::GraphicsLayerCA::pauseAnimation):
2534         (WebCore::GraphicsLayerCA::layerDidDisplay):
2535         (WebCore::GraphicsLayerCA::updateGeometry):
2536         (WebCore::GraphicsLayerCA::updateTransform):
2537         (WebCore::GraphicsLayerCA::updateChildrenTransform):
2538         (WebCore::GraphicsLayerCA::updateMasksToBounds):
2539         (WebCore::GraphicsLayerCA::updateContentsVisibility):
2540         (WebCore::GraphicsLayerCA::updateContentsOpaque):
2541         (WebCore::GraphicsLayerCA::updateBackfaceVisibility):
2542         (WebCore::GraphicsLayerCA::updateFilters):
2543         (WebCore::GraphicsLayerCA::ensureStructuralLayer):
2544         (WebCore::GraphicsLayerCA::updateLayerDrawsContent):
2545         (WebCore::GraphicsLayerCA::updateContentsImage):
2546         (WebCore::GraphicsLayerCA::updateContentsRect):
2547         (WebCore::GraphicsLayerCA::updateMaskLayer):
2548         (WebCore::GraphicsLayerCA::updateLayerAnimations):
2549         (WebCore::GraphicsLayerCA::setAnimationOnLayer):
2550         (WebCore::GraphicsLayerCA::removeCAAnimationFromLayer):
2551         (WebCore::GraphicsLayerCA::pauseCAAnimationOnLayer):
2552         (WebCore::GraphicsLayerCA::suspendAnimations):
2553         (WebCore::GraphicsLayerCA::resumeAnimations):
2554         (WebCore::GraphicsLayerCA::findOrMakeClone):
2555         (WebCore::GraphicsLayerCA::setOpacityInternal):
2556         (WebCore::GraphicsLayerCA::updateOpacityOnLayer):
2557         * platform/graphics/ca/mac/TileCache.mm:
2558         (WebCore::TileCache::~TileCache):
2559         (WebCore::TileCache::setNeedsDisplay):
2560         (WebCore::TileCache::setScale):
2561         (WebCore::TileCache::setAcceleratesDrawing):
2562         (WebCore::TileCache::setTileDebugBorderWidth):
2563         (WebCore::TileCache::setTileDebugBorderColor):
2564         (WebCore::TileCache::revalidateTiles):
2565         * platform/graphics/ca/win/PlatformCALayerWin.cpp:
2566         (PlatformCALayer::animationStarted):
2567         (resubmitAllAnimations):
2568         (PlatformCALayer::animationForKey):
2569         * platform/graphics/chromium/FontCacheChromiumWin.cpp:
2570         (WebCore::LookupAltName):
2571         (WebCore::fontContainsCharacter):
2572         * platform/graphics/chromium/FontUtilsChromiumWin.cpp:
2573         (WebCore::getDerivedFontData):
2574         * platform/graphics/filters/CustomFilterGlobalContext.cpp:
2575         (WebCore::CustomFilterGlobalContext::~CustomFilterGlobalContext):
2576         (WebCore::CustomFilterGlobalContext::getValidatedProgram):
2577         (WebCore::CustomFilterGlobalContext::removeValidatedProgram):
2578         * platform/graphics/filters/CustomFilterProgram.cpp:
2579         (WebCore::CustomFilterProgram::notifyClients):
2580         * platform/graphics/harfbuzz/HarfBuzzSkia.cpp:
2581         (WebCore::getCachedHarfbuzzFace):
2582         (WebCore::releaseCachedHarfbuzzFace):
2583         * platform/graphics/harfbuzz/ng/HarfBuzzNGFace.cpp:
2584         (WebCore::HarfBuzzNGFace::HarfBuzzNGFace):
2585         (WebCore::HarfBuzzNGFace::~HarfBuzzNGFace):
2586         * platform/graphics/mac/SimpleFontDataCoreText.cpp:
2587         (WebCore::SimpleFontData::getCFStringAttributes):
2588         * platform/graphics/mac/SimpleFontDataMac.mm:
2589         (WebCore::SimpleFontData::canRenderCombiningCharacterSequence):
2590         * platform/graphics/opengl/Extensions3DOpenGLCommon.cpp:
2591         (WebCore::Extensions3DOpenGLCommon::getTranslatedShaderSourceANGLE):
2592         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
2593         (WebCore::GraphicsContext3D::compileShader):
2594         (WebCore::GraphicsContext3D::mappedSymbolName):
2595         (WebCore::GraphicsContext3D::getShaderiv):
2596         (WebCore::GraphicsContext3D::getShaderInfoLog):
2597         (WebCore::GraphicsContext3D::getShaderSource):
2598         * platform/graphics/openvg/EGLDisplayOpenVG.cpp:
2599         (WebCore::EGLDisplayOpenVG::~EGLDisplayOpenVG):
2600         (WebCore::EGLDisplayOpenVG::destroySurface):
2601         (WebCore::EGLDisplayOpenVG::contextForSurface):
2602         * platform/graphics/texmap/TextureMapperGL.cpp:
2603         (WebCore::TextureMapperGLData::SharedGLData::currentSharedGLData):
2604         (WebCore::TextureMapperGLData::SharedGLData::~SharedGLData):
2605         * platform/graphics/texmap/TextureMapperShaderManager.cpp:
2606         (WebCore::TextureMapperShaderManager::getShaderProgram):
2607         (WebCore::TextureMapperShaderManager::getShaderForFilter):
2608         * platform/graphics/wince/FontPlatformData.cpp:
2609         (WebCore::FixedSizeFontData::create):
2610         * platform/gtk/DataObjectGtk.cpp:
2611         (WebCore::DataObjectGtk::forClipboard):
2612         * platform/gtk/GtkDragAndDropHelper.cpp:
2613         (WebCore::GtkDragAndDropHelper::handleGetDragData):
2614         (WebCore::GtkDragAndDropHelper::handleDragLeave):
2615         (WebCore::GtkDragAndDropHelper::handleDragMotion):
2616         (WebCore::GtkDragAndDropHelper::handleDragDataReceived):
2617         (WebCore::GtkDragAndDropHelper::handleDragDrop):
2618         * platform/gtk/RedirectedXCompositeWindow.cpp:
2619         (WebCore::filterXDamageEvent):
2620         * platform/gtk/RenderThemeGtk3.cpp:
2621         (WebCore::gtkStyleChangedCallback):
2622         (WebCore::getStyleContext):
2623         * platform/mac/ScrollbarThemeMac.mm:
2624         (+[WebScrollbarPrefsObserver appearancePrefsChanged:]):
2625         * platform/network/CredentialStorage.cpp:
2626         (WebCore::CredentialStorage::set):
2627         (WebCore::CredentialStorage::get):
2628         * platform/network/HTTPHeaderMap.cpp:
2629         (WebCore::HTTPHeaderMap::copyData):
2630         (WebCore::HTTPHeaderMap::get):
2631         * platform/network/MIMEHeader.cpp:
2632         (WebCore::MIMEHeader::parseHeader):
2633         * platform/network/ResourceHandle.cpp:
2634         (WebCore::ResourceHandle::create):
2635         * platform/network/ResourceRequestBase.cpp:
2636         (WebCore::ResourceRequestBase::addHTTPHeaderField):
2637         (WebCore::ResourceRequestBase::addHTTPHeaderFields):
2638         * platform/network/blackberry/ResourceRequestBlackBerry.cpp:
2639         (WebCore::ResourceRequest::targetTypeFromMimeType):
2640         (WebCore::ResourceRequest::initializePlatformRequest):
2641         * platform/network/cf/ResourceHandleCFNet.cpp:
2642         (WebCore::makeFinalRequest):
2643         * platform/network/cf/ResourceRequestCFNet.cpp:
2644         (WebCore::setHeaderFields):
2645         * platform/network/curl/ResourceHandleManager.cpp:
2646         (WebCore::ResourceHandleManager::initializeHandle):
2647         * platform/network/mac/ResourceRequestMac.mm:
2648         (WebCore::ResourceRequest::doUpdatePlatformRequest):
2649         * platform/network/qt/ResourceRequestQt.cpp:
2650         (WebCore::ResourceRequest::toNetworkRequest):
2651         * platform/network/soup/ResourceHandleSoup.cpp:
2652         (WebCore::sendRequestCallback):
2653         (WebCore::ResourceHandle::setClientCertificate):
2654         * platform/network/soup/ResourceRequestSoup.cpp:
2655         (WebCore::ResourceRequest::updateSoupMessage):
2656         (WebCore::ResourceRequest::toSoupMessage):
2657         * platform/network/soup/ResourceResponseSoup.cpp:
2658         (WebCore::ResourceResponse::toSoupMessage):
2659         * platform/network/win/ResourceHandleWin.cpp:
2660         (WebCore::ResourceHandle::start):
2661         * platform/qt/RunLoopQt.cpp:
2662         (WebCore::RunLoop::TimerBase::timerFired):
2663         * platform/text/LocaleToScriptMappingDefault.cpp:
2664         (WebCore::scriptNameToCode):
2665         (WebCore::localeToScriptCodeForFontSelection):
2666         * platform/text/TextEncodingRegistry.cpp:
2667         (WebCore::pruneBlacklistedCodecs):
2668         (WebCore::dumpTextEncodingNameMap):
2669         * platform/text/transcoder/FontTranscoder.cpp:
2670         (WebCore::FontTranscoder::converterType):
2671         * platform/text/win/TextCodecWin.cpp:
2672         (WebCore::LanguageManager::LanguageManager):
2673         (WebCore::getCodePage):
2674         (WebCore::TextCodecWin::registerExtendedEncodingNames):
2675         (WebCore::TextCodecWin::registerExtendedCodecs):
2676         (WebCore::TextCodecWin::enumerateSupportedEncodings):
2677         * platform/win/ClipboardUtilitiesWin.cpp:
2678         (WebCore::getDataMapItem):
2679         (WebCore::getClipboardData):
2680         (WebCore::setClipboardData):
2681         * platform/win/ClipboardWin.cpp:
2682         (WebCore::ClipboardWin::types):
2683         * platform/win/FileSystemWin.cpp:
2684         (WebCore::cachedStorageDirectory):
2685         * platform/win/RunLoopWin.cpp:
2686         (WebCore::RunLoop::TimerBase::timerFired):
2687         * platform/win/WCDataObject.cpp:
2688         (WebCore::WCDataObject::createInstance):
2689         * platform/wince/MIMETypeRegistryWinCE.cpp:
2690         (WebCore::MIMETypeRegistry::getPreferredExtensionForMIMEType):
2691         * platform/wx/ContextMenuWx.cpp:
2692         (WebCore::ContextMenu::appendItem):
2693         * plugins/PluginDatabase.cpp:
2694         (WebCore::PluginDatabase::refresh):
2695         (WebCore::PluginDatabase::MIMETypeForExtension):
2696         (WebCore::PluginDatabase::remove):
2697         * plugins/PluginMainThreadScheduler.cpp:
2698         (WebCore::PluginMainThreadScheduler::scheduleCall):
2699         (WebCore::PluginMainThreadScheduler::dispatchCalls):
2700         * plugins/PluginStream.cpp:
2701         (WebCore::PluginStream::startStream):
2702         * plugins/blackberry/PluginDataBlackBerry.cpp:
2703         (WebCore::PluginData::initPlugins):
2704         * plugins/wx/PluginDataWx.cpp:
2705         (WebCore::PluginData::initPlugins):
2706         * rendering/ExclusionShapeInsideInfo.cpp:
2707         (WebCore::ExclusionShapeInsideInfo::ensureExclusionShapeInsideInfoForRenderBlock):
2708         * rendering/FlowThreadController.cpp:
2709         (WebCore::FlowThreadController::unregisterNamedFlowContentNode):
2710         * rendering/InlineFlowBox.cpp:
2711         (WebCore::InlineFlowBox::requiresIdeographicBaseline):
2712         (WebCore::InlineFlowBox::addTextBoxVisualOverflow):
2713         * rendering/RenderBlock.cpp:
2714         (WebCore::RenderBlock::clearFloats):
2715         * rendering/RenderBlockLineLayout.cpp:
2716         (WebCore::setLogicalWidthForTextRun):
2717         * rendering/RenderBoxModelObject.cpp:
2718         (WebCore::ImageQualityController::highQualityRepaintTimerFired):
2719         (WebCore::ImageQualityController::shouldPaintAtLowQuality):
2720         * rendering/RenderCounter.cpp:
2721         (WebCore::RenderCounter::destroyCounterNodes):
2722         (WebCore::RenderCounter::destroyCounterNode):
2723         (WebCore::updateCounters):
2724         (WebCore::RenderCounter::rendererStyleChanged):
2725         * rendering/RenderFlowThread.cpp:
2726         (WebCore::RenderFlowThread::setRegionRangeForBox):
2727         (WebCore::RenderFlowThread::getRegionRangeForBox):
2728         * rendering/RenderLayer.cpp:
2729         (WebCore::RenderLayer::paint):
2730         (WebCore::performOverlapTests):
2731         * rendering/RenderLayerFilterInfo.cpp:
2732         (WebCore::RenderLayerFilterInfo::filterInfoForRenderLayer):
2733         (WebCore::RenderLayerFilterInfo::createFilterInfoForRenderLayerIfNeeded):
2734         * rendering/RenderNamedFlowThread.cpp:
2735         (WebCore::RenderNamedFlowThread::dependsOn):
2736         (WebCore::RenderNamedFlowThread::pushDependencies):
2737         * rendering/RenderRegion.cpp:
2738         (WebCore::RenderRegion::setRenderBoxRegionInfo):
2739         (WebCore::RenderRegion::setRegionObjectsRegionStyle):
2740         (WebCore::RenderRegion::restoreRegionObjectsOriginalStyle):
2741         (WebCore::RenderRegion::computeChildrenStyleInRegion):
2742         * rendering/RenderTableSection.cpp:
2743         (WebCore::RenderTableSection::cachedCollapsedBorder):
2744         * rendering/RenderThemeMac.mm:
2745         (WebCore::RenderThemeMac::systemColor):
2746         * rendering/RenderView.cpp:
2747         (WebCore::RenderView::selectionBounds):
2748         (WebCore::RenderView::setSelection):
2749         * rendering/RenderWidget.cpp:
2750         (WebCore::WidgetHierarchyUpdatesSuspensionScope::moveWidgets):
2751         * rendering/RootInlineBox.cpp:
2752         (WebCore::RootInlineBox::ascentAndDescentForBox):
2753         * rendering/VerticalPositionCache.h:
2754         (WebCore::VerticalPositionCache::get):
2755         * rendering/svg/RenderSVGInlineText.cpp:
2756         (WebCore::RenderSVGInlineText::characterStartsNewTextChunk):
2757         * rendering/svg/RenderSVGResourceFilter.cpp:
2758         (WebCore::RenderSVGResourceFilter::primitiveAttributeChanged):
2759         * rendering/svg/RenderSVGResourceGradient.cpp:
2760         (WebCore::RenderSVGResourceGradient::applyResource):
2761         * rendering/svg/RenderSVGResourcePattern.cpp:
2762         (WebCore::RenderSVGResourcePattern::applyResource):
2763         * rendering/svg/SVGResourcesCache.cpp:
2764         (WebCore::SVGResourcesCache::resourceDestroyed):
2765         * rendering/svg/SVGRootInlineBox.cpp:
2766         (WebCore::swapItemsInLayoutAttributes):
2767         * rendering/svg/SVGTextLayoutAttributes.cpp:
2768         (WebCore::SVGTextLayoutAttributes::dump):
2769         * rendering/svg/SVGTextLayoutAttributesBuilder.cpp:
2770         (WebCore::SVGTextLayoutAttributesBuilder::buildCharacterDataMap):
2771         (WebCore::SVGTextLayoutAttributesBuilder::fillCharacterDataMap):
2772         * rendering/svg/SVGTextLayoutEngine.cpp:
2773         (WebCore::SVGTextLayoutEngine::layoutTextOnLineOrPath):
2774         * rendering/svg/SVGTextMetricsBuilder.cpp:
2775         (WebCore::SVGTextMetricsBuilder::measureTextRenderer):
2776         * storage/StorageAreaSync.cpp:
2777         (WebCore::StorageAreaSync::syncTimerFired):
2778         (WebCore::StorageAreaSync::performImport):
2779         (WebCore::StorageAreaSync::sync):
2780         * storage/StorageMap.cpp:
2781         (WebCore::StorageMap::key):
2782         (WebCore::StorageMap::setItem):
2783         * storage/StorageNamespaceImpl.cpp:
2784         (WebCore::StorageNamespaceImpl::localStorageNamespace):
2785         (WebCore::StorageNamespaceImpl::copy):
2786         (WebCore::StorageNamespaceImpl::close):
2787         (WebCore::StorageNamespaceImpl::clearAllOriginsForDeletion):
2788         (WebCore::StorageNamespaceImpl::sync):
2789         * svg/SVGDocumentExtensions.cpp:
2790         (WebCore::SVGDocumentExtensions::removeAnimationElementFromTarget):
2791         (WebCore::SVGDocumentExtensions::removeAllAnimationElementsFromTarget):
2792         (WebCore::SVGDocumentExtensions::addPendingResource):
2793         (WebCore::SVGDocumentExtensions::isElementPendingResources):
2794         (WebCore::SVGDocumentExtensions::removeElementFromPendingResources):
2795         (WebCore::SVGDocumentExtensions::setOfElementsReferencingTarget):
2796         (WebCore::SVGDocumentExtensions::removeAllTargetReferencesForElement):
2797         (WebCore::SVGDocumentExtensions::removeAllElementReferencesForTarget):
2798         * svg/SVGElement.cpp:
2799         (WebCore::SVGElement::~SVGElement):
2800         * svg/animation/SMILTimeContainer.cpp:
2801         (WebCore::SMILTimeContainer::setElapsed):
2802         (WebCore::SMILTimeContainer::updateAnimations):
2803         * svg/graphics/SVGImageCache.cpp:
2804         (WebCore::SVGImageCache::~SVGImageCache):
2805         (WebCore::SVGImageCache::removeClientFromCache):
2806         (WebCore::SVGImageCache::requestedSizeAndScales):
2807         (WebCore::SVGImageCache::imageContentChanged):
2808         (WebCore::SVGImageCache::redraw):
2809         (WebCore::SVGImageCache::lookupOrCreateBitmapImageForRenderer):
2810         * svg/graphics/filters/SVGFilterBuilder.h:
2811         (WebCore::SVGFilterBuilder::effectReferences):
2812         (WebCore::SVGFilterBuilder::addBuiltinEffects):
2813         * svg/properties/SVGAnimatedProperty.h:
2814         (WebCore::SVGAnimatedProperty::~SVGAnimatedProperty):
2815         * svg/properties/SVGAttributeToPropertyMap.cpp:
2816         (WebCore::SVGAttributeToPropertyMap::addProperties):
2817         (WebCore::SVGAttributeToPropertyMap::synchronizeProperties):
2818         * workers/WorkerContext.cpp:
2819         (WebCore::WorkerContext::hasPendingActivity):
2820         * workers/WorkerEventQueue.cpp:
2821         (WebCore::WorkerEventQueue::close):
2822         * xml/XMLHttpRequest.cpp:
2823         (WebCore::XMLHttpRequest::setRequestHeaderInternal):
2824         (WebCore::XMLHttpRequest::getAllResponseHeaders):
2825         * xml/XPathFunctions.cpp:
2826         (WebCore::XPath::createFunction):
2827         * xml/XPathParser.cpp:
2828         (isAxisName):
2829         * xml/XSLTProcessorLibxslt.cpp:
2830         (WebCore::xsltParamArrayFromParameterMap):
2831         * xml/XSLTProcessorQt.cpp:
2832         (WebCore::XSLTProcessor::transformToString):
2833
2834 2012-10-07  Geoffrey Garen  <ggaren@apple.com>
2835
2836         REGRESSION (r130584): Crashes in JSC::MarkedAllocator::allocateSlowCase, failing fast/dom/gc-dom-tree-lifetime.html
2837         https://bugs.webkit.org/show_bug.cgi?id=98612
2838
2839         Reviewed by Darin Adler.
2840
2841         Since DOM modification can happen outside of JS, calls into JS due to
2842         DOM modification need to take the JS lock.
2843
2844         * bindings/js/JSNodeCustom.cpp:
2845         (WebCore::willCreatePossiblyOrphanedTreeByRemovalSlowCase): Take the JS
2846         lock before doing a JS allocation, since this may be a JS entrypoint.
2847
2848         * bindings/js/JSNodeCustom.h:
2849         (WebCore::willCreatePossiblyOrphanedTreeByRemoval): Split out a slow case
2850         to help the inliner.
2851
2852 2012-10-07  Nick Carter  <nick@chromium.org>
2853
2854         [chromium] Crash in WebCore::GraphicsLayerChromium::setContentsToImage
2855         https://bugs.webkit.org/show_bug.cgi?id=98456
2856
2857         Reviewed by James Robinson.
2858
2859         Handle null return of nativeImageForCurrentFrame.
2860
2861         Test: compositing/images/truncated-direct-png-image.html
2862
2863         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
2864         (WebCore::GraphicsLayerChromium::setContentsToImage):
2865
2866 2012-10-07  Benjamin Poulain  <benjamin@webkit.org>
2867
2868         WTFURL: implement URL port removal for HTMLAnchorElement
2869         https://bugs.webkit.org/show_bug.cgi?id=98604
2870
2871         Reviewed by Adam Barth.
2872
2873         * platform/KURLWTFURL.cpp:
2874         (WebCore::KURL::hasPort):
2875         (WebCore::KURL::removePort):
2876         (WebCore::KURL::isHierarchical):
2877         Implement those methods to pass the port removal test of HTMLAnchorElement.
2878
2879 2012-10-05  Dirk Schulze  <krit@webkit.org>
2880
2881         SVG radialGradient should support 'fr' for focal radius (just like Canvas)
2882         https://bugs.webkit.org/show_bug.cgi?id=97986
2883
2884         Reviewed by Daniel Bates.
2885
2886         Update SVGRadialGradient to the changed behavior in SVG2: http://www.w3.org/TR/SVG2/pservers.html#RadialGradients
2887         SVG2 adds the focal radius for radial gradients. Color stops will start from the edge of
2888         the focal radius.
2889         The new specification does not limit the focal point to be inside the radial gradients radius.
2890         This makes SVGRadialGradient consistent with the radial gradient on Canvas.
2891
2892         Test: svg/custom/radialGradient-focal-radius.svg
2893
2894         * rendering/svg/RenderSVGResourceRadialGradient.cpp:
2895             Remove checks for position of focal point. The focal point
2896             can be placed every where outside the radius of the gradient now.
2897         (WebCore::RenderSVGResourceRadialGradient::focalRadius):
2898             Add new method to get the focal radius from SVGRadialGradientElement.
2899         (WebCore::RenderSVGResourceRadialGradient::buildGradient):
2900         * rendering/svg/RenderSVGResourceRadialGradient.h:
2901         (RenderSVGResourceRadialGradient):
2902         * rendering/svg/SVGRenderTreeAsText.cpp:
2903         (WebCore::writeSVGResourceContainer):
2904             Modify DRT output to include the focal radius.
2905         * svg/RadialGradientAttributes.h:
2906         (WebCore::RadialGradientAttributes::RadialGradientAttributes):
2907         (WebCore::RadialGradientAttributes::fr):
2908         (WebCore::RadialGradientAttributes::setFr):
2909         (WebCore::RadialGradientAttributes::hasFr):
2910         (RadialGradientAttributes):
2911             New setters and getters for focal radius.
2912         * svg/SVGRadialGradientElement.cpp:
2913         (WebCore):
2914         (WebCore::SVGRadialGradientElement::SVGRadialGradientElement):
2915         (WebCore::SVGRadialGradientElement::isSupportedAttribute):
2916         (WebCore::SVGRadialGradientElement::parseAttribute):
2917         (WebCore::SVGRadialGradientElement::collectGradientAttributes):
2918         (WebCore::SVGRadialGradientElement::selfHasRelativeLengths):
2919             Ditto.
2920         * svg/SVGRadialGradientElement.h:
2921         (SVGRadialGradientElement):
2922         * svg/SVGRadialGradientElement.idl:
2923         * svg/svgattrs.in:
2924             Add 'fr' as new attribute to the SVG attribute list.
2925
2926 2012-10-07  Glenn Adams  <glenn@skynav.com>
2927
2928         Use start instead of -webkit-auto in default and quirks mode stylesheets.
2929         https://bugs.webkit.org/show_bug.cgi?id=98609
2930
2931         Reviewed by Antti Koivisto.
2932
2933         Change text-align use of legacy '-webkit-auto' to 'start' in the few places where it is used
2934         in default/quirks stylesheets.
2935         
2936         No new tests. No change of rendering/styling behavior. No performance impact.
2937
2938         * css/html.css:
2939         (input, textarea, keygen, select, button, isindex):
2940         (ruby > rt):
2941         * css/quirks.css:
2942         (table):
2943
2944 2012-10-06  Raul Hudea  <rhudea@adobe.com>
2945
2946         -webkit-clip-path should parse IRIs
2947         https://bugs.webkit.org/show_bug.cgi?id=96381
2948
2949         Reviewed by Andreas Kling.
2950
2951         Implemented the clipping via referencing a SVG clipPath. Currently it works only if the clipPath is defined
2952         before using it on an HTML element. The forward reference issue is tracked via https://bugs.webkit.org/show_bug.cgi?id=90405.
2953
2954         Tests: css3/masking/clip-path-reference-userSpaceOnUse.html
2955                css3/masking/clip-path-reference.html
2956                fast/masking/parsing-clip-path-iri.html
2957
2958         * css/CSSComputedStyleDeclaration.cpp:
2959         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): Add handling for SVG clipPath references.
2960         * css/CSSParser.cpp:
2961         (WebCore::CSSParser::parseValue): Add handling for SVG clipPath references.
2962         * css/StyleBuilder.cpp:
2963         (WebCore::ApplyPropertyClipPath::applyValue): Add handling for SVG references.
2964         * rendering/ClipPathOperation.h:
2965         (ReferenceClipPathOperation): Added a new class corresponding to SVG referenced clipPath.
2966         (WebCore::ReferenceClipPathOperation::create):
2967         (WebCore::ReferenceClipPathOperation::url):
2968         (WebCore::ReferenceClipPathOperation::fragment):
2969         (WebCore::ReferenceClipPathOperation::operator==):
2970         (WebCore::ReferenceClipPathOperation::ReferenceClipPathOperation):
2971         (WebCore):
2972         * rendering/RenderLayer.cpp:
2973         (WebCore::RenderLayer::paintLayerContents): Add handling for ReferenceClipPathOperation.
2974         * rendering/svg/RenderSVGResourceClipper.h:
2975         (RenderSVGResourceClipper): Made applyClippingToContext public as it needs to be called directly for HTML elements.
2976
2977 2012-10-06  Pratik Solanki  <psolanki@apple.com>
2978
2979         Reduce calls to CGImageSourceCopyPropertiesAtIndex from frameSizeAtIndex
2980         https://bugs.webkit.org/show_bug.cgi?id=98607
2981
2982         Reviewed by Dan Bernstein.
2983
2984         Refactor code so that we avoid a second call to CGImageSourceCopyPropertiesAtIndex under
2985         ImageSource::frameSizeAtIndex().
2986
2987         No new tests because no functional change.
2988
2989         * platform/graphics/cg/ImageSourceCG.cpp:
2990         (WebCore::orientationFromProperties):
2991         (WebCore):
2992         (WebCore::ImageSource::frameSizeAtIndex):
2993         (WebCore::ImageSource::orientationAtIndex):
2994
2995 2012-10-06  Mark Rowe  <mrowe@apple.com>
2996
2997         Build fix.
2998
2999         Stop calling -[NSSliderCell setTitle:]. It's never done anything on OS X.
3000
3001         * rendering/RenderThemeMac.mm:
3002         (WebCore::RenderThemeMac::sliderThumbHorizontal):
3003         (WebCore::RenderThemeMac::sliderThumbVertical):
3004
3005 2012-10-06  Andreas Kling  <kling@webkit.org>
3006
3007         Clipboard::types() should return an ordered collection.
3008         <http://webkit.org/b/98547>
3009
3010         Reviewed by Darin Adler.
3011
3012         Let Clipboard::types() return a ListHashSet<String> instead of a HashSet<String> to make sure
3013         it retains the order in which type strings are added.
3014
3015         No test, this fixes an issue that was uncovered when lowering the default table size of WTF
3016         hash tables, causing the HashSet<String> to rehash and reorder itself.
3017
3018         * bindings/js/JSClipboardCustom.cpp:
3019         (WebCore::JSClipboard::types):
3020         * bindings/v8/custom/V8ClipboardCustom.cpp:
3021         (WebCore::V8Clipboard::typesAccessorGetter):
3022         * dom/Clipboard.h:
3023         (Clipboard):
3024         * platform/blackberry/ClipboardBlackBerry.cpp:
3025         (WebCore::ClipboardBlackBerry::types):
3026         * platform/blackberry/ClipboardBlackBerry.h:
3027         (ClipboardBlackBerry):
3028         * platform/chromium/ChromiumDataObject.cpp:
3029         (WebCore::ChromiumDataObject::types):
3030         * platform/chromium/ChromiumDataObject.h:
3031         (ChromiumDataObject):
3032         * platform/chromium/ClipboardChromium.cpp:
3033         (WebCore::ClipboardChromium::types):
3034         * platform/chromium/ClipboardChromium.h:
3035         (ClipboardChromium):
3036         * platform/efl/ClipboardEfl.cpp:
3037         (WebCore::ClipboardEfl::types):
3038         * platform/efl/ClipboardEfl.h:
3039         (ClipboardEfl):
3040         * platform/gtk/ClipboardGtk.cpp:
3041         (WebCore::ClipboardGtk::types):
3042         * platform/gtk/ClipboardGtk.h:
3043         (ClipboardGtk):
3044         * platform/mac/ClipboardMac.h:
3045         (ClipboardMac):
3046         * platform/mac/ClipboardMac.mm:
3047         (WebCore::addHTMLClipboardTypesForCocoaType):
3048         (WebCore::ClipboardMac::types):
3049         * platform/qt/ClipboardQt.cpp:
3050         (WebCore::ClipboardQt::types):
3051         * platform/qt/ClipboardQt.h:
3052         (ClipboardQt):
3053         * platform/win/ClipboardWin.cpp:
3054         (WebCore::addMimeTypesForFormat):
3055         (WebCore::ClipboardWin::types):
3056         * platform/win/ClipboardWin.h:
3057         (ClipboardWin):
3058         * platform/wx/ClipboardWx.cpp:
3059         (WebCore::ClipboardWx::types):
3060         * platform/wx/ClipboardWx.h:
3061         (ClipboardWx):
3062
3063 2012-10-06  Geoffrey Garen  <ggaren@apple.com>
3064
3065         If Node X is reachable from JavaScript, all Nodes in the same tree should be kept alive
3066         https://bugs.webkit.org/show_bug.cgi?id=88834
3067
3068         Reviewed by Gavin Barraclough.
3069
3070         Follow-up patch to address some comments by Darin Adler.
3071
3072         * bindings/js/JSNodeCustom.h:
3073         (WebCore::willCreatePossiblyOrphanedTreeByRemoval): Save some space by
3074         collapsing comment lines. Use Node::hasChildNodes() for brevity.
3075
3076 2012-10-06  Benjamin Poulain  <benjamin@webkit.org>
3077
3078         Fix weird use of KURL's protocolIs
3079         https://bugs.webkit.org/show_bug.cgi?id=98584
3080
3081         Reviewed by Adam Barth.
3082
3083         Converting a KURL to string is a bad idea.
3084
3085         Invalid URLs can return a string that pass the tests, while an
3086         invalid URL will fail protocolIs().
3087
3088         * loader/cache/CachedResource.cpp:
3089         (WebCore::CachedResource::removeClient):
3090         * platform/graphics/MediaPlayer.cpp:
3091         (WebCore::MediaPlayer::load):
3092         * platform/network/DataURL.cpp:
3093         (WebCore::handleDataURL):
3094
3095 2012-10-06  Dan Bernstein  <mitz@apple.com>
3096
3097         WebCore part of <rdar://problem/12446507> [mac] WebKit clients cannot change the behavior of text-rendering: auto
3098         https://bugs.webkit.org/show_bug.cgi?id=98601
3099
3100         Reviewed by Darin Adler.
3101
3102         * WebCore.exp.in: Exported Font::setDefaultTypesettingFeatures().
3103         * platform/graphics/Font.cpp:
3104         (WebCore::Font::s_defaultTypesettingFeatures): Defined this static.
3105         (WebCore::Font::setDefaultTypesettingFeatures): Added this setter.
3106         (WebCore::Font::defaultTypesettingFeatures): Added this getter.
3107         * platform/graphics/Font.h:
3108         (WebCore::Font::typesettingFeatures): Changed to use the value of the new static member
3109         s_defaultTypesettingFeatures, rather than 0, if text-redering is set to auto.
3110
3111 2012-10-04  Geoffrey Garen  <ggaren@apple.com>
3112
3113         If Node X is reachable from JavaScript, all Nodes in the same tree should be kept alive
3114         https://bugs.webkit.org/show_bug.cgi?id=88834
3115
3116         Reviewed by Gavin Barraclough.
3117
3118         * bindings/js/JSNodeCustom.cpp:
3119         (WebCore::isObservable): Clarified this comment, since it seems to have
3120         misled some folks. 
3121
3122         * bindings/js/JSNodeCustom.h:
3123         (WebCore::willCreatePossiblyOrphanedTreeByRemoval): New helper function
3124         to ensure that a disconnected tree is visible to JavaScript.
3125
3126         * bindings/js/ScriptState.cpp:
3127         (WebCore::mainWorldScriptState): Need to check for null because a document's
3128         frame can be null.
3129
3130         * dom/ContainerNode.cpp:
3131         (WebCore::dispatchChildRemovalEvents): When we remove a subtree from the
3132         document, we sever the reference that JavaScript previously held by
3133         referencing its root. So, we give JavaScript an opportunity to establish
3134         a reference to the new root.
3135
3136 2012-10-06  Byungwoo Lee  <bw80.lee@samsung.com>
3137
3138         Fix build warning : -Wunused-parameter.
3139         https://bugs.webkit.org/show_bug.cgi?id=98583
3140
3141         Reviewed by Kentaro Hara.
3142
3143         Use ASSERT_UNUSED() macro to remove build warning.
3144
3145         * plugins/PluginStream.cpp:
3146         (WebCore::PluginStream::delayDeliveryTimerFired):
3147         (WebCore::PluginStream::didReceiveResponse):
3148         (WebCore::PluginStream::didReceiveData):
3149         (WebCore::PluginStream::didFail):
3150         (WebCore::PluginStream::didFinishLoading):
3151         * plugins/PluginView.cpp:
3152         (WebCore::PluginView::requestTimerFired):
3153         (WebCore::PluginView::invalidateTimerFired):
3154
3155 2012-10-05  Adam Barth  <abarth@webkit.org>
3156
3157         [V8] toV8(Node*, ...) does more work than needed (6% faster on dom-traverse)
3158         https://bugs.webkit.org/show_bug.cgi?id=98567
3159
3160         Reviewed by Kentaro Hara.
3161
3162         This patch introduces toV8Fast for Node*. This function works a
3163         differently from the existing toV8 function in two ways:
3164
3165         1) It uses the inline wrapper cache in Node to determine if we're
3166            executing in the main world. This is faster both in the case when
3167            isolated worlds exist because we don't need to retrieve any state
3168            for the current context.
3169
3170         2) It doesn't attempt to inline the hash table lookup used to find the
3171            wrapper in the isolated world. There isn't a big need to inline this
3172            code since performance in the isolated world case is dominated by
3173            the hash table lookup.
3174
3175         Because of these two changes, toV8Fast is small enough to inline into
3176         each attribute getter profitably. Over time, I would like to convert
3177         all the performance critical uses of toV8(Node*) to toV8Fast. At that
3178         point, we can delete toV8 and rename toV8Slow to toV8.
3179
3180         * bindings/scripts/CodeGeneratorV8.pm:
3181         (GenerateHeader):
3182         (GenerateNormalAttrGetter):
3183
3184 2012-10-05  Huang Dongsung  <luxtella@company100.net>
3185
3186         [mac] REGRESSION (r122215): Animated GIF outside the viewport doesn't play when scrolled into view.
3187         https://bugs.webkit.org/show_bug.cgi?id=94874
3188
3189         Reviewed by Simon Fraser.
3190
3191         Rollback previous patch because this patch caused two problems.
3192         1. GIF animation is occasionally paused when tiled scrolling is enabled.
3193         2. This change regressed Apple's Membuster benchmark by ~20% (80MB.)
3194
3195         * loader/cache/CachedImage.cpp:
3196         (WebCore::CachedImage::shouldPauseAnimation):
3197         * loader/cache/CachedImage.h:
3198         (CachedImage):
3199         * loader/cache/CachedResource.h:
3200         * loader/cache/MemoryCache.cpp:
3201         (WebCore::MemoryCache::pruneLiveResourcesToSize):
3202         * rendering/RenderObject.cpp:
3203         (WebCore::RenderObject::willRenderImage):
3204
3205 2012-10-05  Xianzhu Wang  <wangxianzhu@chromium.org>
3206
3207         OpenTypeVerticalData issue with DroidSansFallback.ttf on chromium-android and chromium-linux
3208         https://bugs.webkit.org/show_bug.cgi?id=97824
3209
3210         Reviewed by Tony Chang.
3211
3212         The issue occurred when a font that contains vert GSUB table but doesn't have
3213         a DFLT script and the first script doesn't have vert feature. Added logic to
3214         handle the case.
3215
3216         Test: fast/writing-mode/vertical-subst-font-vert-no-dflt.html
3217
3218         * platform/graphics/opentype/OpenTypeVerticalData.cpp:
3219         (FeatureList):
3220         (WebCore::OpenType::FeatureList::findFeature): Added to find the matching feature in FeatureList.
3221         (WebCore::OpenType::GSUBTable::feature): Added logic to handle the case of no DFLT script and no vert feature under the first script.
3222
3223 2012-10-05  Tony Chang  <tony@chromium.org>
3224
3225         Form controls should always be horizontal
3226         https://bugs.webkit.org/show_bug.cgi?id=98563
3227
3228         Reviewed by Ojan Vafai.
3229
3230         Fix a regression where we didn't force form controls to be horizontal.
3231
3232         Tests: fast/dom/HTMLMeterElement/meter-writing-mode.html
3233                fast/dom/HTMLProgressElement/progress-writing-mode.html
3234                fast/table/colspanMinWidth-vertical.html
3235
3236         * css/html.css:
3237         (input, textarea, keygen, select, button, isindex, meter, progress):
3238
3239 2012-10-05  Sheriff Bot  <webkit.review.bot@gmail.com>
3240
3241         Unreviewed, rolling out r130556 and r130564.
3242         http://trac.webkit.org/changeset/130556
3243         http://trac.webkit.org/changeset/130564
3244         https://bugs.webkit.org/show_bug.cgi?id=98572
3245
3246         The patch wasn't reviewed by a reviewer and it is breaking
3247         Chromium Windows (Requested by jchaffraix on #webkit).
3248
3249         * WebCore.exp.in:
3250         * WebCore.xcodeproj/project.pbxproj:
3251         * css/mediaControls.css:
3252         (video::-webkit-media-text-track-container):
3253         (video::-webkit-media-text-track-past-nodes):
3254         (video::-webkit-media-text-track-future-nodes):
3255         (video::-webkit-media-text-track-display):
3256         * html/HTMLMediaElement.cpp:
3257         (WebCore::HTMLMediaElement::HTMLMediaElement):
3258         (WebCore::HTMLMediaElement::attach):
3259         (WebCore::HTMLMediaElement::userIsInterestedInThisLanguage):
3260         (WebCore::HTMLMediaElement::userIsInterestedInThisTrackKind):
3261         (WebCore::HTMLMediaElement::setClosedCaptionsVisible):
3262         (WebCore::HTMLMediaElement::updateClosedCaptionsControls):
3263         * html/HTMLMediaElement.h:
3264         (HTMLMediaElement):
3265         * html/shadow/MediaControlElements.cpp:
3266         (WebCore):
3267         (WebCore::MediaControlTextTrackContainerElement::updateSizes):
3268         * html/shadow/MediaControlElements.h:
3269         (MediaControlTextTrackContainerElement):
3270         * html/shadow/MediaControlRootElement.cpp:
3271         (WebCore::MediaControlRootElement::updateTextTrackDisplay):
3272         * html/shadow/MediaControlRootElement.h:
3273         (MediaControlRootElement):
3274         * html/shadow/MediaControls.h:
3275         (MediaControls):
3276         * html/track/TextTrack.cpp:
3277         (WebCore::TextTrack::TextTrack):
3278         (WebCore::TextTrack::isValidKindKeyword):
3279         (WebCore::TextTrack::setKind):
3280         (WebCore::TextTrack::setMode):
3281         (WebCore::TextTrack::mode):
3282         * html/track/TextTrack.h:
3283         (WebCore::TextTrack::create):
3284         (WebCore::TextTrack::kind):
3285         (TextTrack):
3286         (WebCore::TextTrack::label):
3287         (WebCore::TextTrack::setLabel):
3288         (WebCore::TextTrack::language):
3289         (WebCore::TextTrack::setLanguage):
3290         * html/track/TextTrackCue.cpp:
3291         (WebCore::TextTrackCueBox::TextTrackCueBox):
3292         (WebCore::TextTrackCueBox::shadowPseudoId):
3293         (WebCore):
3294         (WebCore::TextTrackCue::updateDisplayTree):
3295         * html/track/TextTrackCue.h:
3296         (TextTrackCueBox):
3297         (TextTrackCue):
3298         * platform/mac/WebCoreSystemInterface.h:
3299         * platform/mac/WebCoreSystemInterface.mm:
3300         * rendering/CaptionPreferencesChangedListener.h: Removed.
3301         * rendering/RenderTheme.h:
3302         (WebCore):
3303         (RenderTheme):
3304         * rendering/RenderThemeMac.h:
3305         (RenderThemeMac):
3306         * rendering/RenderThemeMac.mm:
3307         (WebCore):
3308         (WebCore::RenderThemeMac::RenderThemeMac):
3309         (WebCore::RenderThemeMac::~RenderThemeMac):
3310
3311 2012-10-05  Tim Horton  <timothy_horton@apple.com>
3312
3313         [cg] GraphicsContextCG should ask CG whether the shadow offset workaround is required
3314         https://bugs.webkit.org/show_bug.cgi?id=98565
3315         <rdar://problem/12436468>
3316
3317         Reviewed by Simon Fraser.
3318
3319         On Mountain Lion and above, CG can tell us whether we need to work around incorrect
3320         shadow offsets. Prior to Mountain Lion, we should assume we need to apply the workaround.
3321
3322         No new tests, as this requires an obscure configuration to test.
3323
3324         * WebCore.exp.in:
3325         * platform/graphics/cg/GraphicsContextCG.cpp:
3326         (WebCore::applyShadowOffsetWorkaroundIfNeeded):
3327         (WebCore::GraphicsContext::setPlatformShadow):
3328         * platform/mac/WebCoreSystemInterface.h: Add wkCGContextDrawsWithCorrectShadowOffsets.
3329         * platform/mac/WebCoreSystemInterface.mm: Add wkCGContextDrawsWithCorrectShadowOffsets.
3330
3331 2012-10-05  Anders Carlsson  <andersca@apple.com>
3332
3333         Try to fix the build.
3334
3335         * rendering/RenderThemeMac.mm:
3336         (WebCore::RenderThemeMac::captionsWindowColor):
3337
3338 2012-10-05  Eric Seidel  <eric@webkit.org>
3339
3340         Remove needless virtual calls and inline RenderStyle::logical* to make table layout faster
3341         https://bugs.webkit.org/show_bug.cgi?id=98550
3342
3343         Reviewed by Andreas Kling.
3344
3345         This shaved another 5% (100ms) off of the runtime of resizecol.html microbenchmark:
3346         http://www.robohornet.org/tests/resizecol.html
3347
3348         * rendering/AutoTableLayout.cpp:
3349         (WebCore::AutoTableLayout::recalcColumn):
3350         * rendering/style/RenderStyle.cpp:
3351         * rendering/style/RenderStyle.h:
3352
3353 2012-10-04  Eric Carlson  <eric.carlson@apple.com>
3354
3355         Allow ports to override text track rendering style
3356         https://bugs.webkit.org/show_bug.cgi?id=97800
3357         <rdar://problem/12044964>
3358
3359         Reviewed by Silvia Pfeiffer.
3360
3361         * WebCore.exp.in: Export new WebkitSystemInterface functions.
3362         * WebCore.xcodeproj/project.pbxproj: Add CaptionPreferencesChangedListener.h.
3363
3364         * css/mediaControls.css: Rearrange the caption CSS so it is possible to style the cue window,
3365             background, and text independently.
3366
3367         * html/HTMLMediaElement.cpp:
3368         (WebCore::HTMLMediaElement::HTMLMediaElement): Initialize m_disableCaptions with theme->userPrefersCaptions().
3369         (WebCore::HTMLMediaElement::attach): Register for caption preferences change callbacks.
3370         (WebCore::HTMLMediaElement::detach): Unregister for caption preferences change callbacks.
3371         (WebCore::HTMLMediaElement::userPrefersCaptions): Return theme->userPrefersCaptions().
3372         (WebCore::HTMLMediaElement::userIsInterestedInThisTrackKind): Consider userPrefersCaptions().
3373         (WebCore::HTMLMediaElement::setClosedCaptionsVisible): Move the code that marks all tracks as
3374             un-configured to markCaptionAndSubtitleTracksAsUnconfigured so it can be reused.
3375         (WebCore::HTMLMediaElement::captionPreferencesChanged): New, force a reevaluation of all text tracks.
3376         (WebCore::HTMLMediaElement::markCaptionAndSubtitleTracksAsUnconfigured): New, code moved from 
3377             setClosedCaptionsVisible
3378         * html/HTMLMediaElement.h: Inherit from CaptionPreferencesChangedListener.
3379
3380         * html/shadow/MediaControlElements.cpp:
3381         (WebCore::MediaControlTextTrackContainerElement::userCaptionPreferencesChanged): New, if theme
3382             has a captions style sheet override, inject it into the current page group, otherwise
3383             remove injected sheet.
3384         (WebCore::MediaControlTextTrackContainerElement::updateSizes): Get rid of unnecessary member
3385             variable. Get caption font scale from theme instead of hard coding.
3386         * html/shadow/MediaControlElements.h:
3387
3388         * html/shadow/MediaControlRootElement.cpp:
3389         (WebCore::MediaControlRootElement::userCaptionPreferencesChanged): New.
3390         (WebCore::MediaControlRootElement::updateTextTrackDisplay):
3391         * html/shadow/MediaControlRootElement.h: Add userCaptionPreferencesChanged, minor cleanup.
3392
3393         * html/shadow/MediaControls.h:
3394         (WebCore::MediaControls::userCaptionPreferencesChanged): New.
3395
3396         * html/track/TextTrackCue.cpp:
3397         (WebCore::TextTrackCueBox::TextTrackCueBox): Set the shadow pseudo id.
3398         (WebCore::TextTrackCueBox::textTrackCueBoxShadowPseudoId): New, class method to return the 
3399             shadow pseudo id so it can be used elsewhere.
3400         (WebCore::TextTrackCueBox::shadowPseudoId): Call textTrackCueBoxShadowPseudoId.
3401         (WebCore::TextTrackCue::pastNodesShadowPseudoId): New, class method to return the 
3402             shadow pseudo id so it can be used elsewhere.
3403         (WebCore::TextTrackCue::futureNodesShadowPseudoId): Ditto.
3404         (WebCore::TextTrackCue::updateDisplayTree):
3405         * html/track/TextTrackCue.h:
3406
3407         * platform/mac/WebCoreSystemInterface.h: Updated.
3408         * platform/mac/WebCoreSystemInterface.mm: Ditto.
3409
3410         * rendering/CaptionPreferencesChangedListener.h: Added.