2011-06-25 Joseph Pecoraro <joepeck@webkit.org>
[WebKit.git] / Source / WebCore / ChangeLog
1 2011-06-25  Joseph Pecoraro  <joepeck@webkit.org>
2
3         Reviewed by Simon Fraser.
4
5         Inspector highlight rect is wrong for contents of transformed iframes
6         https://bugs.webkit.org/show_bug.cgi?id=53627
7
8         Part 2: Only adjust for the FrameView's scroll position when
9         the localToAbsolute mapping did not end with fixed content.
10         Content that is inside of a fixed position container is already
11         adjusted for the FrameView's scrollPosition when RenderView
12         maps local to container.
13
14         This patch uses a "wasFixed" out parameter to determine if
15         the localToAbsolute transformation ended inside a fixed block,
16         and if so does not apply the scroll position.
17
18         * page/FrameView.cpp:
19         (WebCore::FrameView::convertFromRenderer):
20         Respect wasFixed as described above.
21
22         * rendering/RenderBox.h:
23         * rendering/RenderBox.cpp:
24         (WebCore::RenderBox::mapLocalToContainer):
25         This is the only time that "fixed" ever changed. So when
26         fixed changes, update the optional wasFixed out parameter.
27
28         * rendering/RenderObject.cpp:
29         (WebCore::RenderObject::localToAbsolute):
30         (WebCore::RenderObject::mapLocalToContainer):
31         (WebCore::RenderObject::localToContainerQuad):
32         * rendering/RenderObject.h:
33         (WebCore::RenderObject::localToAbsoluteQuad):
34         Ignore wasFixed by default, but pipe it though where needed.
35
36         * rendering/RenderView.h:
37         * rendering/RenderView.cpp:
38         (WebCore::RenderView::mapLocalToContainer):
39         This is the final recursive call, so wasFixed goes no
40         further. We sanity check its value in debug builds.
41
42         * rendering/RenderBlock.cpp:
43         (WebCore::RenderBlock::selectionGapRectsForRepaint):
44         * rendering/RenderInline.cpp:
45         (WebCore::RenderInline::mapLocalToContainer):
46         * rendering/RenderInline.h:
47         * rendering/svg/RenderSVGForeignObject.cpp:
48         (WebCore::RenderSVGForeignObject::mapLocalToContainer):
49         * rendering/svg/RenderSVGForeignObject.h:
50         * rendering/svg/RenderSVGInline.cpp:
51         (WebCore::RenderSVGInline::mapLocalToContainer):
52         * rendering/svg/RenderSVGInline.h:
53         * rendering/svg/RenderSVGModelObject.cpp:
54         (WebCore::RenderSVGModelObject::mapLocalToContainer):
55         * rendering/svg/RenderSVGModelObject.h:
56         * rendering/svg/RenderSVGRoot.cpp:
57         (WebCore::RenderSVGRoot::mapLocalToContainer):
58         * rendering/svg/RenderSVGRoot.h:
59         * rendering/svg/RenderSVGText.cpp:
60         (WebCore::RenderSVGText::mapLocalToContainer):
61         * rendering/svg/RenderSVGText.h:
62         * rendering/svg/SVGRenderSupport.cpp:
63         (WebCore::SVGRenderSupport::mapLocalToContainer):
64         * rendering/svg/SVGRenderSupport.h:
65         Pipe wasFixed through where needed.
66
67 2011-06-25  Joseph Pecoraro  <joepeck@webkit.org>
68
69         Reviewed by Simon Fraser.
70
71         Inspector highlight rect is wrong for contents of transformed iframes
72         https://bugs.webkit.org/show_bug.cgi?id=53627
73
74         Part 1: Provide FloatQuad versions of convertFromRenderer,
75         convertToContainingView, and convertChildToSelf, so that we
76         can get the fully transformed quad of a renderer all the
77         way up to the root widget.
78
79         * page/FrameView.cpp:
80         (WebCore::FrameView::convertFromRenderer):
81         (WebCore::FrameView::convertToContainingView):
82         * page/FrameView.h:
83         * platform/ScrollView.h:
84         (WebCore::ScrollView::convertChildToSelf):
85         * platform/Widget.h:
86         * platform/Widget.cpp:
87         (WebCore::Widget::convertToContainingView):
88         Provide FloatQuad versions of these already existing functions.
89
90         (WebCore::Widget::convertToRootContainingView):
91         Provide a helper conversion function to recursively
92         convert a given FloatQuad up to the root widget.
93
94         * inspector/DOMNodeHighlighter.cpp:
95         (WebCore::DOMNodeHighlighter::DrawNodeHighlight):
96         Use the new methods to convert the FloatQuad for the highlighted
97         node to the root container, without losing transformation
98         information. Add a FIXME for SVG, which is still broken.
99
100         * WebCore.exp.in:
101         Export the new Widget functions so WebKit can link properly.
102
103 2011-06-25  Dirk Schulze  <krit@webkit.org>
104
105         Unreviewed build fix.
106
107         SVGAnimatedType should support SVGNumberList animation
108         https://bugs.webkit.org/show_bug.cgi?id=63387
109
110         * svg/SVGAnimatedNumberList.cpp:
111         (WebCore::SVGAnimatedNumberListAnimator::calculateAnimatedValue):
112
113 2011-06-25  Dirk Schulze  <krit@webkit.org>
114
115         Reviewed by Nikolas Zimmermann.
116
117         SVGAnimatedType should support SVGNumberList animation
118         https://bugs.webkit.org/show_bug.cgi?id=63387
119         
120         Follow up of "SVGAnimation should use direct unit animation for SVGLength": https://bugs.webkit.org/show_bug.cgi?id=61368
121         This patch continues the conversion to the new concept of SVGAnimatorFactory with SVGNumberList.
122         
123         Animations of attributes with type SVGNumberList can be interpolated now.
124
125         Tests: svg/animations/svgnumberlist-animation-1.html
126                svg/animations/svgnumberlist-animation-2.html
127
128         * CMakeLists.txt: Added new file to build system.
129         * GNUmakefile.list.am: Ditto.
130         * WebCore.gypi: Ditto.
131         * WebCore.pro: Ditto.
132         * WebCore.xcodeproj/project.pbxproj: Ditto.
133         * svg/SVGAllInOne.cpp: Ditto.
134         * svg/SVGAnimateElement.cpp: Make use of attribute type AnimatedNumberList.
135         (WebCore::SVGAnimateElement::determineAnimatedAttributeType):
136         (WebCore::SVGAnimateElement::calculateAnimatedValue):
137         (WebCore::SVGAnimateElement::calculateFromAndToValues):
138         (WebCore::SVGAnimateElement::calculateFromAndByValues):
139         (WebCore::SVGAnimateElement::resetToBaseValue):
140         (WebCore::SVGAnimateElement::applyResultsToTarget):
141         (WebCore::SVGAnimateElement::calculateDistance):
142         * svg/SVGAnimatedNumber.cpp:
143         (WebCore::SVGAnimatedNumberAnimator::calculateAnimatedNumber): Made method static for reuse in SVGAnimatedNumberList (and SVGAnimatedNumberOptionalNumber later).
144         (WebCore::SVGAnimatedNumberAnimator::calculateAnimatedValue): Use new static function.
145         * svg/SVGAnimatedNumber.h:
146         * svg/SVGAnimatedNumberList.cpp: Added. New animator for SVGNumberList.
147         (WebCore::SVGAnimatedNumberListAnimator::SVGAnimatedNumberListAnimator):
148         (WebCore::SVGAnimatedNumberListAnimator::constructFromString):
149         (WebCore::SVGAnimatedNumberListAnimator::calculateFromAndToValues):
150         (WebCore::SVGAnimatedNumberListAnimator::calculateFromAndByValues):
151         (WebCore::SVGAnimatedNumberListAnimator::calculateAnimatedValue):
152         (WebCore::SVGAnimatedNumberListAnimator::calculateDistance):
153         * svg/SVGAnimatedNumberList.h:
154         (WebCore::SVGAnimatedNumberListAnimator::~SVGAnimatedNumberListAnimator):
155         * svg/SVGAnimatedType.cpp: Use new Animator.
156         (WebCore::SVGAnimatedType::~SVGAnimatedType):
157         (WebCore::SVGAnimatedType::createNumberList):
158         (WebCore::SVGAnimatedType::numberList):
159         (WebCore::SVGAnimatedType::valueAsString):
160         (WebCore::SVGAnimatedType::setValueAsString):
161         * svg/SVGAnimatedType.h:
162         * svg/SVGAnimatorFactory.h:
163         (WebCore::SVGAnimatorFactory::create):
164
165 2011-06-25  Nikolas Zimmermann  <nzimmermann@rim.com>
166
167         Reviewed by Dirk Schulze.
168
169         Convert SVGPath to SVGAnimatorFactory concept
170         https://bugs.webkit.org/show_bug.cgi?id=63336
171
172         Convert <animate attributeName="d"> parsing to the new SVGAnimatorFactory concept, removing
173         the last special data types from SVGAnimateElement: SVGPathByteStream m_fromPath/m_toPath/m_animatedPath.
174         All existing non-string primitives have been converted to the new concept.
175
176         Doesn't change any functionality.
177
178         * CMakeLists.txt: Added SVGAnimatedPath.*.
179         * GNUmakefile.list.am: Ditto.
180         * WebCore.gypi: Ditto.
181         * WebCore.pro: Ditto.
182         * WebCore.vcproj/WebCore.vcproj: Ditto.
183         * WebCore.xcodeproj/project.pbxproj: Ditto.
184         * svg/SVGAllInOne.cpp: Ditto.
185         * svg/SVGAnimateElement.cpp:
186         (WebCore::SVGAnimateElement::SVGAnimateElement):
187         (WebCore::SVGAnimateElement::calculateAnimatedValue):
188         (WebCore::SVGAnimateElement::calculateFromAndToValues):
189         (WebCore::SVGAnimateElement::calculateFromAndByValues):
190         (WebCore::SVGAnimateElement::resetToBaseValue):
191         (WebCore::SVGAnimateElement::applyResultsToTarget):
192         * svg/SVGAnimateElement.h:
193         * svg/SVGAnimatedPath.cpp: Added.
194         (WebCore::SVGAnimatedPathAnimator::SVGAnimatedPathAnimator):
195         (WebCore::SVGAnimatedPathAnimator::constructFromString):
196         (WebCore::SVGAnimatedPathAnimator::calculateFromAndToValues):
197         (WebCore::SVGAnimatedPathAnimator::calculateFromAndByValues):
198         (WebCore::SVGAnimatedPathAnimator::calculateAnimatedValue):
199         (WebCore::SVGAnimatedPathAnimator::calculateDistance):
200         * svg/SVGAnimatedPath.h: Added.
201         (WebCore::SVGAnimatedPathAnimator::~SVGAnimatedPathAnimator):
202         * svg/SVGAnimatedType.cpp:
203         (WebCore::SVGAnimatedType::~SVGAnimatedType):
204         (WebCore::SVGAnimatedType::createPath):
205         (WebCore::SVGAnimatedType::path):
206         (WebCore::SVGAnimatedType::valueAsString):
207         (WebCore::SVGAnimatedType::setValueAsString):
208         * svg/SVGAnimatedType.h:
209         * svg/SVGAnimatorFactory.h:
210         (WebCore::SVGAnimatorFactory::create):
211         * svg/SVGPathByteStream.h:
212         (WebCore::SVGPathByteStream::initializeFrom):
213         * svg/SVGPathParserFactory.cpp:
214         (WebCore::SVGPathParserFactory::buildSVGPathByteStreamFromSVGPathSegList):
215         (WebCore::SVGPathParserFactory::buildSVGPathByteStreamFromString):
216         (WebCore::SVGPathParserFactory::buildAnimatedSVGPathByteStream):
217
218 2011-06-25  Jer Noble  <jer.noble@apple.com>
219
220         Reviewed by Maciej Stachowiak.
221
222         SOFT_LINK_POINTER_OPTIONAL isn't optional.
223         https://bugs.webkit.org/show_bug.cgi?id=63378
224
225         Continuation of r89718.  SOFT_LINK_POINTER_OPTIONAL should check the value returned by dlsym before dereferencing it.
226
227         * platform/mac/SoftLinking.h:
228
229 2011-06-25  Rob Buis  <rbuis@rim.com>
230
231         Reviewed by Nikolas Zimmermann.
232
233         SVG1.1SE test linking-uri-01-b.svg fails
234         https://bugs.webkit.org/show_bug.cgi?id=63322
235
236         Allow navigating to internal <view> targets. When choosing Back ensure
237         the <svg> current view is initialized correctly.
238
239         Tests: svg/W3C-SVG-1.1-SE/linking-uri-01-b.svg
240                svg/custom/linking-uri-01-b.svg
241
242         * page/FrameView.cpp: Delegate to setupInitialView.
243         (WebCore::FrameView::scrollToAnchor):
244         * svg/SVGAElement.cpp: Allow navigating to internal <view> targets.
245         (WebCore::SVGAElement::defaultEventHandler):
246         * svg/SVGSVGElement.cpp:
247         (WebCore::SVGSVGElement::setupInitialView): Initialize current view depending on fragment identifier.
248         (WebCore::SVGSVGElement::inheritViewAttributes):
249         * svg/SVGSVGElement.h:
250
251 2011-06-24  Dimitri Glazkov  <dglazkov@chromium.org>
252
253         Reviewed by Darin Adler.
254
255         REGRESSION (r77740): Shadow DOM pseudo elements aren't matching when combined with descendant selectors
256         https://bugs.webkit.org/show_bug.cgi?id=63373
257
258         * css/CSSStyleSelector.cpp:
259         (WebCore::CSSStyleSelector::pushParentStackFrame): Changed to use parentOrHostElement.
260         (WebCore::CSSStyleSelector::pushParent): Ditto.
261         * dom/Node.cpp:
262         (WebCore::Node::parentOrHostElement): Added.
263         * dom/Node.h:
264
265 2011-06-24  Dan Bernstein  <mitz@apple.com>
266
267         Reviewed by Anders Carlsson.
268
269         Add an option to enable legacy rounding hacks
270         https://bugs.webkit.org/show_bug.cgi?id=63363
271
272         Restored most of text rounding hacks which were removed in r78846, with a global flag to control
273         whether rounding hacks are allowed, which defaults to false.
274
275         Test: platform/mac/fast/text/rounding-hacks.html
276
277         * CMakeLists.txt: Added TextRun.cpp.
278         * GNUmakefile.list.am: Ditto.
279         * WebCore.exp.in: Export new TextRun function and global and updated StringTruncator functions.
280         * WebCore.gypi: Added TextRun.cpp.
281         * WebCore.pro: Ditto.
282         * WebCore.vcproj/WebCore.vcproj: Ditto.
283         * WebCore.xcodeproj/project.pbxproj: Ditto.
284         * html/canvas/CanvasRenderingContext2D.cpp:
285         (WebCore::CanvasRenderingContext2D::drawTextInternal): Disable rounding hacks in the one place
286         they used to be disabled.
287         * platform/graphics/Font.cpp: Re-added the rounding character table.
288         * platform/graphics/Font.h:
289         (WebCore::Font::isRoundingHackCharacter): Re-added.
290         * platform/graphics/FontFastPath.cpp:
291         (WebCore::Font::getGlyphsAndAdvancesForSimpleText): Account for final rounding width.
292         * platform/graphics/SimpleFontData.cpp:
293         (WebCore::SimpleFontData::platformGlyphInit): Initialize m_adjustedSpaceWidth.
294         * platform/graphics/SimpleFontData.h:
295         (WebCore::SimpleFontData::adjustedSpaceWidth): Re-added.
296         * platform/graphics/StringTruncator.cpp:
297         (WebCore::stringWidth): Re-added disableRoundingHacks parameter.
298         (WebCore::truncateString): Ditto.
299         (WebCore::StringTruncator::centerTruncate): Added EnableRoundingHacksOrNot parameter.
300         (WebCore::StringTruncator::rightTruncate): Ditto.
301         (WebCore::StringTruncator::width): Ditto.
302         * platform/graphics/StringTruncator.h:
303         * platform/graphics/TextRun.cpp: Added.
304         (WebCore::TextRun::setAllowsRoundingHacks): Added.
305         * platform/graphics/TextRun.h:
306         (WebCore::TextRun::TextRun): Added RoundingHacks parameter to the constructors, used to initialize
307         the m_applyRunRounding and m_applyWordRounding member variables, subject to rounding hacks being allowed.
308         (WebCore::TextRun::applyRunRounding): Re-added this accessor.
309         (WebCore::TextRun::applyWordRounding): Ditto.
310         (WebCore::TextRun::disableRoundingHacks): Re-added.
311         * platform/graphics/WidthIterator.cpp:
312         (WebCore::WidthIterator::WidthIterator): Re-added code to apply rounding hacks.
313         (WebCore::WidthIterator::advance): Ditto.
314         * platform/graphics/WidthIterator.h:
315         * platform/graphics/mac/ComplexTextController.cpp:
316         (WebCore::ceilCGFloat): Re-added.
317         (WebCore::ComplexTextController::ComplexTextController): Re-added code to apply rounding hacks.
318         (WebCore::ComplexTextController::advance): Ditto.
319         (WebCore::ComplexTextController::adjustGlyphsAndAdvances): Ditto.
320         * platform/graphics/mac/ComplexTextController.h:
321         (WebCore::ComplexTextController::finalRoundingWidth): Re-added this accessor.
322         * platform/graphics/mac/FontComplexTextMac.cpp:
323         (WebCore::Font::getGlyphsAndAdvancesForComplexText): Accound for final rounding width.
324         * platform/graphics/qt/SimpleFontDataQt.cpp:
325         (WebCore::SimpleFontData::platformGlyphInit): Initialize m_adjustedSpaceWidth.
326         * platform/gtk/RenderThemeGtk.cpp:
327         (WebCore::RenderThemeGtk::fileListNameForWidth): Enabled rounding hacks in the string truncator.
328         * platform/mac/DragImageMac.mm:
329         (WebCore::widthWithFont): Disable rounding hacks when measuring.
330         (WebCore::drawAtPoint): Disable rounding hacks when drawing.
331         * platform/win/DragImageWin.cpp:
332         (WebCore::createDragImageForLink): Enable rounding hacks in the string truncator.
333         * platform/win/WebCoreTextRenderer.cpp:
334         (WebCore::WebCoreTextFloatWidth): Ditto.
335         * rendering/RenderFileUploadControl.cpp:
336         (WebCore::RenderFileUploadControl::paintObject): Disable rounding hacks.
337         * rendering/RenderListBox.cpp:
338         (WebCore::RenderListBox::updateFromElement): Ditto.
339         (WebCore::RenderListBox::paintItemForeground): Ditto.
340         * rendering/RenderTextControl.cpp:
341         (WebCore::RenderTextControl::getAvgCharWidth): Ditto.
342         * rendering/RenderTheme.cpp:
343         (WebCore::RenderTheme::fileListNameForWidth): Enabled rounding hacks in the string truncator.
344         * rendering/RenderThemeMac.mm:
345         (WebCore::RenderThemeMac::fileListNameForWidth): Ditto.
346         * rendering/svg/SVGInlineTextBox.cpp:
347         (WebCore::SVGInlineTextBox::constructTextRun): Disabled rounding hacks.
348         * rendering/svg/SVGTextMetrics.cpp:
349         (WebCore::constructTextRun): Ditto.
350
351 2011-06-24  Nikolas Zimmermann  <nzimmermann@rim.com>
352
353         Reviewed by Rob Buis.
354
355         Integrate SVG Fonts within GlyphPage concept, removing the special SVG code paths from Font, making it possible to reuse the simple text code path for SVG Fonts
356         https://bugs.webkit.org/show_bug.cgi?id=59085
357
358         font substitution doesn't work for HTML text using SVG fonts
359         https://bugs.webkit.org/show_bug.cgi?id=17608
360
361         Selection rects are wrong for text with SVG fonts
362         https://bugs.webkit.org/show_bug.cgi?id=25460
363
364         With @font-face, SVG fonts only work as primary, non-segmented
365         https://bugs.webkit.org/show_bug.cgi?id=32227
366
367         When using SVG fonts with @font-face word-spacing and text-align: justify are not being honored
368         https://bugs.webkit.org/show_bug.cgi?id=34236
369
370         SVG @font-face breaks text-overflow: ellipsis
371         https://bugs.webkit.org/show_bug.cgi?id=36840
372
373         REGRESSION: SVG Font selection problems
374         https://bugs.webkit.org/show_bug.cgi?id=41934
375
376         Tests: svg/custom/svg-fonts-fallback.xhtml (for bug 17608, extended the original test from Mark Ambachtsheer)
377                svg/custom/svg-fonts-segmented.xhtml (for bug 32227)
378                svg/custom/svg-fonts-word-spacing.html (for bug 34236, from Michael Lewis)
379                svg/text/select-text-svgfont.html (for bug 25460/41934, from Emil Schutte)
380                svg/text/text-overflow-ellipsis-svgfont.html (for 36840, from Emil Schutte)
381
382         Rewrite the SVG Fonts support to fully integrate within the GlyphPage concept and the "simple" code path used to render platform fonts.
383         That means the special logic for measuring text using SVG Fonts, calculating offset for positions, computing selection rects etc. is all gone now.
384         There's no difference anymore between using a native font or a SVG Font, in terms of these operations.
385
386         This makes text selection using SVG Fonts possible again.
387
388         * features.pri: Temporarily turn of SVG Fonts for Qt, as long as QRawFont support is not available and the fast path is disabled.
389         * page/DOMWindow.idl: Touched file to force Qt regenerating the bindings.
390         * platform/graphics/Font.cpp: Remove SVG Font special cases, the simple code path now handles SVG Fonts as well.
391         (WebCore::Font::drawText):
392         (WebCore::Font::drawEmphasisMarks):
393         (WebCore::Font::width):
394         (WebCore::Font::selectionRectForText):
395         (WebCore::Font::offsetForPosition):
396         (WebCore::Font::codePath):
397         * platform/graphics/Font.h: Pass TextRun to drawGlyphBuffer/drawEmphasisMarks. Add new glyphDataAndPageForCharacter() method which returns a pair
398                                     std::pair<GlyphData, GlyphPage*>, so we know the associated GlyphPage for a certain GlyphData object, which is needed to properly
399                                     handle font fallback glyph matching for SVG Fonts..
400         (WebCore::Font::fontList): Add FontFallbackList accessor.
401         * platform/graphics/FontFallbackList.h: Add getters/setters for glyphPageZero -- SVG Fonts support needs access to these objects from SVGTextRunRenderingContext.
402         (WebCore::FontFallbackList::glyphPageZero):
403         (WebCore::FontFallbackList::glyphPages):
404         (WebCore::FontFallbackList::setGlyphPageZero):
405         (WebCore::FontFallbackList::setGlyphPages):
406         * platform/graphics/FontFastPath.cpp:
407         (WebCore::Font::glyphDataForCharacter): Move implementation to glyphDataAndPageForCharacter(), and use that method from here.
408         (WebCore::Font::glyphDataAndPageForCharacter): Does the same as before, just returns an additional GlyphPage* pointer.
409         (WebCore::Font::getEmphasisMarkGlyphData): Remove SVG Fonts special case.
410         (WebCore::Font::drawGlyphBuffer): Ditto.
411         * platform/graphics/FontMetrics.h:
412         (WebCore::scaleEmToUnits): Refactored scaleEmToUnits free function from SimpleFontDataMac/CGWin to share with SVGFontData/SVGTextRunRenderingContext.
413         * platform/graphics/GlyphPageTreeNode.cpp:
414         (WebCore::fill): Stop skipping SVG Fonts, they now also fill the GlyphPage using the glyphs defined in the SVG Font.
415         * platform/graphics/SVGGlyph.h: s/isValid/isPartOfLigature/. Its usage has been changed.
416         (WebCore::SVGGlyph::SVGGlyph):
417         (WebCore::SVGGlyph::operator==):
418         * platform/graphics/SimpleFontData.cpp: Change font size to be a float, not an int.
419         (WebCore::SimpleFontData::SimpleFontData):
420         * platform/graphics/SimpleFontData.h: Add new pure virtual methods to the AdditionalFontData interface, to be implemented in SVGFontData.
421         (WebCore::SimpleFontData::widthForGlyph): Call widthForSVGGlyph, if we encounter a SVG glyph.
422         * platform/graphics/TextRun.h: 
423         * platform/graphics/WidthIterator.cpp:
424         (WebCore::WidthIterator::glyphDataForCharacter):
425         (WebCore::WidthIterator::advance):
426         * platform/graphics/WidthIterator.h: Store several new members needed for SVG Fonts support (last processed glyph name used for kerning pair lookup)
427                                              and a map mapping each character of a text to its arabic-form (if needed, to perform SVG glyph selection for Arabic text).
428         (WebCore::WidthIterator::run):
429         (WebCore::WidthIterator::runWidthSoFar):
430         (WebCore::WidthIterator::lastGlyphName):
431         (WebCore::WidthIterator::setLastGlyphName):
432         (WebCore::WidthIterator::arabicForms):
433         * platform/graphics/chromium/SimpleFontDataChromiumWin.cpp: Use new scaleEmToUnits free function from FontMetrics.h.
434         * platform/graphics/mac/SimpleFontDataMac.mm: Ditto.
435         * platform/graphics/win/SimpleFontDataCGWin.cpp: Ditto.
436         * rendering/svg/SVGTextLayoutAttributesBuilder.cpp:
437         (WebCore::SVGTextLayoutAttributesBuilder::propagateLayoutAttributes): Handle UTF-16 surrogate pairs correctly, fixes the previous Acid3 regression.
438         * rendering/svg/SVGTextMetrics.cpp:
439         (WebCore::SVGTextMetrics::SVGTextMetrics):
440         (WebCore::constructTextRun):
441         (WebCore::SVGTextMetrics::measureCharacterRange):
442         * rendering/svg/SVGTextMetrics.h:
443         * rendering/svg/SVGTextRunRenderingContext.cpp: Remove drawTextUsingSVGFont/floatWidthUsingSVGFont/selectionRectForTextUsingSVGFont/offsetForPositionForTextUsingSVGFont.
444         (WebCore::firstParentRendererForNonTextNode): Don't assert node() exists, doesn't hold true for generated render objects.
445         (WebCore::renderObjectFromRun): Renamed from referencingRenderObjectFromRun.
446         (WebCore::SVGTextRunRenderingContext::floatWidthUsingSVGFont): Remove extra "extraCharsAvailable" parameter, now solves via TextRun::charactersLength().
447         (WebCore::calculateEmUnitToPixelScaleFactor): Add helper method.
448         (WebCore::SVGTextRunRenderingContext::drawSVGGlyphs): Main drawing method, this actually creates/renders Paths.
449         (WebCore::SVGTextRunRenderingContext::glyphDataForCharacter): Part 1/2 of SVG Glyph selection code.
450         * rendering/svg/SVGTextRunRenderingContext.h:
451         * svg/SVGAltGlyphElement.cpp:
452         (WebCore::SVGAltGlyphElement::hasValidGlyphElement):
453         * svg/SVGAltGlyphElement.h:
454         * svg/SVGFontData.cpp:
455         (WebCore::SVGFontData::initializeFontData): Changed font size from int to float.
456         (WebCore::SVGFontData::widthForSVGGlyph): Lookup a SVGGlyph from a Glyph using the glyph table in SVGFontElement and calculate its width.
457         (WebCore::SVGFontData::applySVGGlyphSelection): Part 2/2 of SVG Glyph selection code.
458         (WebCore::SVGFontData::fillSVGGlyphPage): Fill GlyphPage using glyphs defined in the SVG Font.
459         (WebCore::SVGFontData::fillBMPGlyphs): Moved from the previous fillSVGGlyphPage implementation.
460         (WebCore::SVGFontData::fillNonBMPGlyphs): Add non-bmp glyph handling, fixing the Acid3 regression (support using SVGGlyphs for UTF-16 surrogate pairs).
461         * svg/SVGFontData.h:
462         * svg/SVGFontElement.cpp:
463         (WebCore::SVGFontElement::registerLigaturesInGlyphCache): Enable ligature registration for the use within GlyphPage.
464         (WebCore::SVGFontElement::ensureGlyphCache):
465         * svg/SVGGlyphMap.h: Switch to use SurrogatePairTextIterator, and switch glyph table from UChar to UChar32, just like GlyphPage, to handle glyphs from non-BMP correctly.
466         (WebCore::SVGGlyphMap::addGlyph): Remove setting isValid, it's not needed anymore and gone.
467         (WebCore::SVGGlyphMap::collectGlyphsForString):
468         * svg/svgtags.in: Surround vkern in ENABLE_SVG_FONTS block.
469
470 2011-06-24  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
471
472         Reviewed by Antonio Gomes.
473
474         [CMAKE] Replace ";" with space in FEATURE_DEFINES macro
475         https://bugs.webkit.org/show_bug.cgi?id=62211
476
477         html.css file doesn't recognize ENABLE_XXX macro because FEATURE_DEFINES macro has ";"
478         as separator. So, let the html.css to use new feature macro with space separator.
479
480         * CMakeLists.txt:
481
482 2011-06-24  Gavin Peters  <gavinp@chromium.org>
483
484         Reviewed by Darin Adler.
485
486         fix possible race in LinkLoader
487         https://bugs.webkit.org/show_bug.cgi?id=63360
488
489         In chromium bug 80729
490         http://code.google.com/p/chromium/issues/detail?id=80729 I am
491         seeing some kind of double triggering of the timer; I am concerned
492         that it is possible that a Link element errors out or succeeds,
493         sets a timer, and shortly before the timer is triggered it is
494         editted, launches another request.  After that, the first timer
495         triggers, zeroing out m_cachedResource.  Then, the second load
496         finishes, and *crash*.  If this is the case, this fix should stop
497         it.
498
499         No new tests; I haven't reproduced this.  I hope chrome's crash
500         telemetry will give good feedback; this crash is occuring many times a
501         day so the difference should be obvious.
502
503         * loader/LinkLoader.cpp:
504         (WebCore::LinkLoader::LinkLoader):
505         (WebCore::LinkLoader::linkLoadTimerFired):
506         (WebCore::LinkLoader::linkLoadingErrorTimerFired):
507         (WebCore::LinkLoader::notifyFinished):
508         * loader/LinkLoader.h:
509
510 2011-06-24  Jer Noble  <jer.noble@apple.com>
511
512         Reviewed by Eric Carlson.
513
514         Safari will quit unexpectedly when launching Safari in the first time (crash in initQTSecurityPolicyNoLocalToRemoteSiteAttribute)
515         https://bugs.webkit.org/show_bug.cgi?id=63332
516         <rdar://problem/9661650>
517
518         No new tests; Only affects machines with QTKit < 7.6.3 installed.
519
520         Check to see if QTSecurityPolicyNoRemoteToLocalSiteAttribute is non-NULL before passing it into -[QTMovie initWithAttributes:],
521         as it is only defined in QTKit >= 7.6.3.  If it is NULL, pass QTSecurityPolicyNoCrossSiteAttribute=YES instead, which has
522         the same effect in earlier versions of QTKit as the NoLocalToRemote and NoRemoteToLocal keys.  To avoid ASSERTs when running
523         debug builds with earlier versions of QTKit, add a SOFT_LINK_POINTER_OPTIONAL macro to SoftLinking.h and make these keys optional.
524
525         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
526         (WebCore::MediaPlayerPrivateQTKit::commonMovieAttributes):
527         * platform/mac/SoftLinking.h: Add SOFT_LINK_POINTER_OPTIONAL macro.
528
529 2011-06-24  Darin Adler  <darin@apple.com>
530
531         Try to fix Windows build failure.
532
533         * platform/win/ClipboardUtilitiesWin.cpp:
534         (WebCore::setFileDescriptorData): Copy string into a local so we
535         can call charactersWithNullTermination on it.
536
537 2011-06-23  Darin Adler  <darin@apple.com>
538
539         Reviewed by Adam Barth.
540
541         Remove some unneeded functions from FrameLoader
542         https://bugs.webkit.org/show_bug.cgi?id=63295
543
544         Removing 7 of the functions in FrameLoader.h is probably a step
545         in the right direction.
546
547         * loader/DocumentLoader.cpp:
548         (WebCore::DocumentLoader::handledOnloadEvents):
549         Moved the call to stopDeferringEvents in here from FrameLoader.
550         * loader/DocumentLoader.h: Ditto.
551
552         * loader/DocumentWriter.h: Fixed a typo.
553
554         * loader/FrameLoader.cpp:
555         (WebCore::FrameLoader::setFirstPartyForCookies): Changed this to
556         use a non-recursive tree walk instead of recursion.
557         (WebCore::FrameLoader::stopAllLoaders): Moved the code from
558         stopLoadingSubframes inline, since it's only two lines of code.
559         (WebCore::FrameLoader::checkLoadCompleteForThisFrame): Moved
560         the code from markLoadComplete inline, since it's only one line.
561         (WebCore::FrameLoader::checkLoadComplete): Changed this to use a
562         non-recursive tree walk instead of recursion, eliminating the
563         recursiveCheckLoadComplete function completely.
564         (WebCore::FrameLoader::handledOnloadEvents): Moved the call to
565         stopDeferringEvents into DocumentLoader.
566
567         * loader/FrameLoader.h: Removed unneeded forward declarations,
568         and now-unneeded functions setupForReplaceByMIMEType,
569         isStopping, isLoadingFromCachedPage, stopLoadingSubframes,
570         markLoadComplete, mainReceivedError, and recursiveCheckLoadComplete.
571         Also made allChildrenAreComplete private.
572
573         * loader/MainResourceLoader.cpp:
574         (WebCore::MainResourceLoader::continueAfterContentPolicy):
575         Call DocumentLoader::isStopping so we can remove the function
576         from FrameLoader that just calls through. Other call sites were
577         using DocumentLoader::isStopping directly.
578         (WebCore::MainResourceLoader::didReceiveResponse): Call
579         DocumentLoader::setupForReplaceByMIMEType so we can remove the
580         function from FrameLoader that just calls through. This was
581         the only call site.
582
583         * loader/ResourceLoader.cpp:
584         (WebCore::ResourceLoader::init): Call the
585         ResourceLoader::cancelledError function instead of calling
586         directly to FrameLoader.
587
588         * loader/ResourceLoader.h: Made response an inline function.
589
590 2011-06-24  Alexey Proskuryakov  <ap@apple.com>
591
592         Rubber-stamped by Maciej Stachowiak.
593
594         REGRESSION (r88984): Infinite recursion in DocumentLoader::detachFromFrame/stopLoading
595
596         No new tests, as there is no known way to reproduce this (but we'll keep investigating, as
597         the rollout will re-introduce the older less frequent crash).
598
599         * loader/DocumentLoader.cpp: (WebCore::DocumentLoader::detachFromFrame): Rollout the fix
600         for bug 62764.
601
602 2011-06-24  Tony Chang  <tony@chromium.org>
603
604         Reviewed by Ojan Vafai.
605
606         add flexbox and inline-flexbox as possible CSS display values
607         https://bugs.webkit.org/show_bug.cgi?id=63361
608
609         Test: css3/flexbox/display-property.html
610
611         * css/CSSParser.cpp:
612         (WebCore::CSSParser::parseValue):
613         * css/CSSValueKeywords.in:
614
615 2011-06-24  Anna Cavender  <annacc@chromium.org>
616
617         Reviewed by Eric Carlson.
618
619         Loading out-of-band text track files from <track>.
620         https://bugs.webkit.org/show_bug.cgi?id=62881
621
622         Uses the src attribute of <track> urls to load out-of-band text track
623         files using ThreadableLoader.  Also removes TextTrackPrivateInterface
624         (as well as LoadableTextTrackImpl and MutableTextTrackImpl) classes.
625
626         No new tests because feature is hidden behind VIDEO_TRACK feature
627         define, which is turned off.
628
629         * CMakeLists.txt:
630         * GNUmakefile.am:
631         * GNUmakefile.list.am:
632         * WebCore.gypi:
633         * WebCore.pro:
634         * WebCore.xcodeproj/project.pbxproj:
635         * html/HTMLMediaElement.cpp:
636         * html/HTMLMediaElement.h:
637         * html/HTMLTrackElement.cpp:
638         * html/HTMLTrackElement.h:
639         * html/LoadableTextTrack.cpp:
640         * html/LoadableTextTrack.h:
641         * html/LoadableTextTrackImpl.cpp: Removed.
642         * html/LoadableTextTrackImpl.h: Removed.
643         * html/MutableTextTrack.cpp:
644         * html/MutableTextTrack.h:
645         * html/MutableTextTrackImpl.cpp: Removed.
646         * html/MutableTextTrackImpl.h: Removed.
647         * html/TextTrack.cpp:
648         * html/TextTrack.h:
649         * html/TextTrackPrivate.h: Removed.
650         * platform/track/CueParser.cpp:
651         * platform/track/CueParser.h:
652
653 2011-06-24  Rob Buis  <rbuis@rim.com>
654
655         Rubber-stamped by Nikolas Zimmermann.
656
657         All pointer-events fail if text has visibility="hidden"
658         https://bugs.webkit.org/show_bug.cgi?id=62209
659
660         Do not use writing mode aware code for SVG Text.
661
662         No new tests needed.
663
664         * rendering/svg/SVGInlineTextBox.cpp:
665         (WebCore::SVGInlineTextBox::nodeAtPoint):
666
667 2011-06-24  Lukasz Slachciak  <l.slachciak@samsung.com>
668
669         Reviewed by Darin Adler.
670
671         Change NDEBUG to !LOG_DISABLED macro in databases for logging.
672         https://bugs.webkit.org/show_bug.cgi?id=63346
673
674         Changed NDEBUG to !LOG_DISABLED in databases code which involves logging.
675         This change resolves also build break in Release build when logging enabled.
676
677         No new tests because there is no new behavior or feature exposed.
678
679         * loader/icon/IconDatabase.cpp: Macro fixes.
680         (WebCore::IconDatabase::iconDatabaseSyncThread):
681         (WebCore::IconDatabase::syncThreadMainLoop):
682         (WebCore::IconDatabase::readFromDatabase):
683         (WebCore::IconDatabase::writeToDatabase):
684         (WebCore::IconDatabase::cleanupSyncThread):
685         * storage/AbstractDatabase.h: Macro fixes.
686         * storage/DatabaseTask.cpp: Macro fixes.
687         * storage/DatabaseTask.h: Macro fixes.
688         * storage/SQLTransaction.cpp: Macro fixes.
689         * storage/SQLTransaction.h: Macro fixes.
690
691 2011-06-24  Tony Chang  <tony@chromium.org>
692
693         Reviewed by Adam Barth.
694
695         Pass Strings by const reference to functions
696         https://bugs.webkit.org/show_bug.cgi?id=63341
697
698         Note that since Strings hold a RefPtr to StringImpl, passing Strings
699         by value isn't horrible, but it does cause ref count churn and using
700         const references is more consistent with the rest of the code base.
701
702         * loader/FrameLoader.cpp:
703         (WebCore::FrameLoader::addHTTPOriginIfNeeded): Rework the code to not
704             change the value of the passed in String.
705         * loader/FrameLoader.h:
706         * platform/win/ClipboardUtilitiesWin.cpp:
707         (WebCore::setFileDescriptorData):
708         * platform/win/ClipboardUtilitiesWin.h:
709         * storage/DatabaseTracker.h:
710         * storage/IDBLevelDBBackingStore.cpp:
711         (WebCore::IDBLevelDBBackingStore::IDBLevelDBBackingStore):
712         * storage/IDBLevelDBBackingStore.h:
713         * storage/IDBSQLiteBackingStore.cpp:
714         (WebCore::IDBSQLiteBackingStore::IDBSQLiteBackingStore):
715         * storage/IDBSQLiteBackingStore.h:
716         * storage/chromium/DatabaseTrackerChromium.cpp:
717         (WebCore::DatabaseTracker::getOpenDatabases):
718         * svg/SVGPaint.cpp:
719         (WebCore::SVGPaint::SVGPaint):
720         * svg/SVGPaint.h:
721         * svg/animation/SMILTimeContainer.cpp:
722         (WebCore::SMILTimeContainer::updateAnimations):
723         * svg/animation/SMILTimeContainer.h:
724         * websockets/ThreadableWebSocketChannelClientWrapper.cpp:
725         (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessageCallback):
726         * websockets/ThreadableWebSocketChannelClientWrapper.h:
727
728 2011-06-24  Abhishek Arya  <inferno@chromium.org>
729
730         Reviewed by Darin Adler.
731
732         Add clamping for CSSPrimitiveValues and SVGInlineText font size.
733         https://bugs.webkit.org/show_bug.cgi?id=53449        
734
735         Test: svg/text/svg-zoom-large-value.xhtml
736
737         * css/CSSPrimitiveValue.cpp:
738         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): add asserts to detect if the
739         number created is valid.
740         * css/CSSPrimitiveValue.h: add clamping checks to prevent overflows.
741         (WebCore::CSSPrimitiveValue::getFloatValue):
742         (WebCore::CSSPrimitiveValue::getIntValue):
743         * css/CSSStyleSelector.cpp:
744         (WebCore::CSSStyleSelector::getComputedSizeFromSpecifiedSize): split into two
745         static functions, one specific to CSSStyleSelector and other generic to help
746         in clamping font size for other callers like svg text, etc.
747         * css/CSSStyleSelector.h:
748         * platform/graphics/FontDescription.h: add asserts to detect if the new font
749         size is valid.
750         (WebCore::FontDescription::setComputedSize):
751         (WebCore::FontDescription::setSpecifiedSize):
752         * rendering/svg/RenderSVGInlineText.cpp:
753         (WebCore::RenderSVGInlineText::computeNewScaledFontForStyle): use the new helper
754         from CSSStyleSelector to help in clamping new scaled font size. do not use
755         "smart minimum" since svg allows really small unreadable fonts (tested by existing
756         layout tests). Document's minimum font size clamp (0 in my case) and harmless epsilon
757         check in CSSStyleSelector function should still hold for svg.
758
759 2011-06-24  Julien Chaffraix  <jchaffraix@webkit.org>
760
761         Reviewed by Darin Adler.
762
763         Remove unsafe static_cast inside the InlineBox hierarchy
764         https://bugs.webkit.org/show_bug.cgi?id=63077
765
766         Refactoring only, no new test.
767
768         * rendering/InlineFlowBox.h:
769         (WebCore::toInlineFlowBox):
770         * rendering/InlineTextBox.h:
771         (WebCore::toInlineTextBox):
772         Added the proper cast methods to those 2 classes from an InlineBox.
773
774         * rendering/InlineBox.cpp:
775         (WebCore::InlineBox::nextLeafChild):
776         (WebCore::InlineBox::prevLeafChild):
777         * rendering/InlineFlowBox.cpp:
778         (WebCore::InlineFlowBox::getFlowSpacingLogicalWidth):
779         (WebCore::InlineFlowBox::addToLine):
780         (WebCore::InlineFlowBox::determineSpacingForFlowBoxes):
781         (WebCore::InlineFlowBox::placeBoxesInInlineDirection):
782         (WebCore::InlineFlowBox::requiresIdeographicBaseline):
783         (WebCore::InlineFlowBox::adjustMaxAscentAndDescent):
784         (WebCore::InlineFlowBox::computeLogicalBoxHeights):
785         (WebCore::InlineFlowBox::placeBoxesInBlockDirection):
786         (WebCore::InlineFlowBox::flipLinesInBlockDirection):
787         (WebCore::InlineFlowBox::computeOverflow):
788         (WebCore::InlineFlowBox::firstLeafChild):
789         (WebCore::InlineFlowBox::lastLeafChild):
790         (WebCore::InlineFlowBox::computeOverAnnotationAdjustment):
791         (WebCore::InlineFlowBox::computeUnderAnnotationAdjustment):
792         * rendering/RenderBlock.cpp:
793         (WebCore::RenderBlock::positionForBox):
794         * rendering/RenderBlockLineLayout.cpp:
795         (WebCore::RenderBlock::createLineBoxes):
796         (WebCore::RenderBlock::constructLine):
797         (WebCore::setLogicalWidthForTextRun):
798         (WebCore::computeExpansionForJustifiedText):
799         (WebCore::RenderBlock::computeInlineDirectionPositionsForLine):
800         * rendering/RenderText.cpp:
801         (WebCore::RenderText::localCaretRect):
802         (WebCore::RenderText::positionLineBox):
803         * rendering/RootInlineBox.cpp:
804         (WebCore::RootInlineBox::ascentAndDescentForBox):
805         (WebCore::RootInlineBox::includeFontForBox):
806         (WebCore::RootInlineBox::includeGlyphsForBox):
807         Replaced the static_cast in those previous call sites with the new cast methods.
808
809 2011-06-24  Alexis Menard  <alexis.menard@openbossa.org>
810
811         Unreviewed build fix.
812
813         Build fix on Linux when using the GStreamer backend.
814
815         No new tests, just a build fix.
816
817         * platform/graphics/gstreamer/PlatformVideoWindowQt.cpp:
818         (FullScreenVideoWindow::keyPressEvent):
819
820 2011-06-24  Nat Duca  <nduca@chromium.org>
821
822         Unreviewed, rolling out r89694.
823         http://trac.webkit.org/changeset/89694
824         https://bugs.webkit.org/show_bug.cgi?id=58408
825
826         Test shell still not ready for animate changes.
827
828         * WebCore.gypi:
829         * platform/graphics/chromium/LayerRendererChromium.cpp:
830         (WebCore::LayerRendererChromium::create):
831         (WebCore::LayerRendererChromium::LayerRendererChromium):
832         (WebCore::LayerRendererChromium::setViewport):
833         (WebCore::LayerRendererChromium::updateAndDrawLayers):
834         * platform/graphics/chromium/LayerRendererChromium.h:
835         * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
836         * platform/graphics/chromium/cc/CCHeadsUpDisplay.h:
837         (WebCore::CCHeadsUpDisplay::setShowFPSCounter):
838         (WebCore::CCHeadsUpDisplay::setShowPlatformLayerTree):
839         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp: Removed.
840         * platform/graphics/chromium/cc/CCLayerTreeHost.h: Removed.
841         * platform/graphics/chromium/cc/CCLayerTreeHostCommitter.cpp: Removed.
842         * platform/graphics/chromium/cc/CCLayerTreeHostCommitter.h: Removed.
843         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp: Removed.
844         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h: Removed.
845         * platform/graphics/chromium/cc/CCLayerTreeHostImplProxy.cpp: Removed.
846         * platform/graphics/chromium/cc/CCLayerTreeHostImplProxy.h: Removed.
847         * platform/graphics/chromium/cc/CCMainThreadTask.h:
848         * platform/graphics/chromium/cc/CCThread.cpp:
849         (WebCore::CCThread::runLoop):
850         * platform/graphics/chromium/cc/CCThreadTask.h:
851
852 2011-06-24  Chris Rogers  <crogers@google.com>
853
854         Unreviewed build fix.
855
856         Fix Chromium Linux Build
857         https://bugs.webkit.org/show_bug.cgi?id=63349
858
859         * WebCore.gyp/WebCore.gyp:
860
861 2011-06-24  Henry Song  <hsong@sisa.samsung.com>
862
863         Reviewed by Martin Robinson.
864
865         Correct _sharedTimer value in SharedTimerEfl.cpp
866         https://bugs.webkit.org/show_bug.cgi?id=62380
867
868         SharedTimerEfl.cpp set _sharedTimer = 0 is incorrect in 
869         timerEvent(), we have observed addNewTimer() can be triggered 
870         by either inside timerFunction() or others that are not within
871         timerFunction().  We have observed the following case:
872         1. add a new Timer within timerFunction()
873         2. timerFunction returns, set _sharedTimer = 0
874         3. addNewTimer() is triggered again within webkit, don't know
875            it triggers this.
876         4. because at this moment, _sharedTimer == 0, the previous
877            registered timer (in step 1) did not get removed.
878         5. Now in ecore_timer, there are two timers with same callbacks
879         6. From now on, timerFunction() will be called twice back-to-back
880            in each ecore_timer loop.
881         To correct this, we should set _sharedTimer = 0 before
882         timerFunction() so that when addNewTimer() triggered within,
883         we have a valid timer object.
884
885         * platform/efl/SharedTimerEfl.cpp:
886         (WebCore::timerEvent):
887
888 2011-05-17  Nat Duca  <nduca@chromium.org>
889
890         Reviewed by James Robinson.
891
892         [chromium] Implement CCLayerTreeHost and CCLayerTreeHostImpl portions of threaded compositor
893         https://bugs.webkit.org/show_bug.cgi?id=58408
894
895         Create CCLayerTreeHost and CCLayerTreeHostImpl, which are the main
896         thread and compositor thread halves of a composited view. Communication
897         between the two is based on the design used in FileStreamProxy.
898
899         * WebCore.gypi:
900         * platform/chromium/TraceEvent.h:
901         * platform/graphics/chromium/LayerRendererChromium.cpp:
902         (WebCore::LayerRendererChromium::create):
903         (WebCore::LayerRendererChromium::LayerRendererChromium):
904         (WebCore::LayerRendererChromium::setViewport):
905         (WebCore::LayerRendererChromium::updateLayers):
906         (WebCore::LayerRendererChromium::drawLayers):
907         (WebCore::LayerRendererChromiumImpl::create):
908         (WebCore::LayerRendererChromiumImpl::drawLayersAndPresent):
909         (WebCore::LayerRendererChromiumImpl::LayerRendererChromiumImpl):
910         (WebCore::LayerRendererChromiumImpl::drawLayersOnMainThread):
911         (WebCore::LayerRendererChromiumImplProxy::create):
912         (WebCore::LayerRendererChromiumImplProxy::createLayerTreeHostImpl):
913         (WebCore::LayerRendererChromiumImplProxy::LayerRendererChromiumImplProxy):
914         (WebCore::LayerRendererChromium::createLayerTreeHostImplProxy):
915         * platform/graphics/chromium/LayerRendererChromium.h:
916         * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
917         (WebCore::CCHeadsUpDisplay::setShowFPSCounter):
918         (WebCore::CCHeadsUpDisplay::setShowPlatformLayerTree):
919         * platform/graphics/chromium/cc/CCHeadsUpDisplay.h:
920         (WebCore::CCHeadsUpDisplay::currentFrameNumber):
921         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp: Copied from Source/WebCore/platform/graphics/chromium/cc/CCThread.cpp.
922         (WebCore::CCLayerTreeHost::CCLayerTreeHost):
923         (WebCore::CCLayerTreeHost::init):
924         (WebCore::CCLayerTreeHost::~CCLayerTreeHost):
925         (WebCore::CCLayerTreeHost::beginCommit):
926         (WebCore::CCLayerTreeHost::commitComplete):
927         (WebCore::CCLayerTreeHost::animateAndLayout):
928         (WebCore::CCLayerTreeHost::createLayerTreeHostCommitter):
929         (WebCore::CCLayerTreeHost::setNeedsCommitAndRedraw):
930         (WebCore::CCLayerTreeHost::setNeedsRedraw):
931         (WebCore::CCLayerTreeHost::updateLayers):
932         * platform/graphics/chromium/cc/CCLayerTreeHost.h: Copied from Source/WebCore/platform/graphics/chromium/cc/CCThread.cpp.
933         (WebCore::CCLayerTreeHost::frameNumber):
934         * platform/graphics/chromium/cc/CCLayerTreeHostCommitter.cpp: Copied from Source/WebCore/platform/graphics/chromium/cc/CCThread.cpp.
935         (WebCore::CCLayerTreeHostCommitter::create):
936         (WebCore::CCLayerTreeHostCommitter::commit):
937         * platform/graphics/chromium/cc/CCLayerTreeHostCommitter.h: Copied from Source/WebCore/platform/graphics/chromium/cc/CCThread.cpp.
938         (WebCore::CCLayerTreeHostCommitter::CCLayerTreeHostCommitter):
939         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp: Added.
940         (WebCore::CCLayerTreeHostImpl::CCLayerTreeHostImpl):
941         (WebCore::CCLayerTreeHostImpl::~CCLayerTreeHostImpl):
942         (WebCore::CCLayerTreeHostImpl::beginCommit):
943         (WebCore::CCLayerTreeHostImpl::commitComplete):
944         (WebCore::CCLayerTreeHostImpl::drawLayers):
945         (WebCore::CCLayerTreeHostImpl::setNeedsCommitAndRedraw):
946         (WebCore::CCLayerTreeHostImpl::setNeedsRedraw):
947         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h: Copied from Source/WebCore/platform/graphics/chromium/cc/CCThread.cpp.
948         (WebCore::CCLayerTreeHostImplClient::~CCLayerTreeHostImplClient):
949         (WebCore::CCLayerTreeHostImpl::frameNumber):
950         (WebCore::CCLayerTreeHostImpl::sourceFrameNumber):
951         (WebCore::CCLayerTreeHostImpl::setSourceFrameNumber):
952         * platform/graphics/chromium/cc/CCLayerTreeHostImplProxy.cpp: Added.
953         (WebCore::CCLayerTreeHostImplProxy::CCLayerTreeHostImplProxy):
954         (WebCore::CCLayerTreeHostImplProxy::start):
955         (WebCore::CCLayerTreeHostImplProxy::~CCLayerTreeHostImplProxy):
956         (WebCore::CCLayerTreeHostImplProxy::isStarted):
957         (WebCore::CCLayerTreeHostImplProxy::setNeedsCommitAndRedraw):
958         (WebCore::CCLayerTreeHostImplProxy::setNeedsRedraw):
959         (WebCore::CCLayerTreeHostImplProxy::stop):
960         (WebCore::CCLayerTreeHostImplProxy::postDrawLayersTaskOnCCThread):
961         (WebCore::CCLayerTreeHostImplProxy::requestFrameAndCommitOnCCThread):
962         (WebCore::CCLayerTreeHostImplProxy::isMainThread):
963         (WebCore::CCLayerTreeHostImplProxy::isCCThread):
964         (WebCore::CCLayerTreeHostImplProxy::requestFrameAndCommit):
965         (WebCore::CCLayerTreeHostImplProxy::commitOnCCThread):
966         (WebCore::CCLayerTreeHostImplProxy::drawLayersOnCCThread):
967         (WebCore::CCLayerTreeHostImplProxy::setNeedsCommitAndRedrawOnCCThread):
968         (WebCore::CCLayerTreeHostImplProxy::setNeedsRedrawOnCCThread):
969         (WebCore::CCLayerTreeHostImplProxy::initImplOnCCThread):
970         (WebCore::CCLayerTreeHostImplProxy::layerTreeHostClosedOnCCThread):
971         * platform/graphics/chromium/cc/CCLayerTreeHostImplProxy.h: Added.
972         (WebCore::CCLayerTreeHostImplProxy::host):
973         * platform/graphics/chromium/cc/CCMainThreadTask.h:
974         * platform/graphics/chromium/cc/CCThread.cpp:
975         (WebCore::CCThread::runLoop):
976         * platform/graphics/chromium/cc/CCThreadTask.h:
977
978 2011-06-24  Adrienne Walker  <enne@google.com>
979
980         Unreviewed, remove assertion about root layers in RenderLayerBacking.
981         https://bugs.webkit.org/show_bug.cgi?id=60741
982
983         This was added in r89687, but somehow is not true on Safari Leopard.
984         However, as the tests that were added with that revision are passing
985         correctly, the assertion is most likely not correct.
986
987         * rendering/RenderLayerBacking.cpp:
988         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
989
990 2011-06-24  Nikolas Zimmermann  <nzimmermann@rim.com>
991
992         Reviewed by Dirk Schulze.
993
994         Refactor text iterator code respecting surrogate pairs from WidthIterator
995         https://bugs.webkit.org/show_bug.cgi?id=63319
996
997         WidthIterator contains a surrogate pair aware text iterator that is needed in other parts of WebCore.
998         Refactor the code into its own SurrogatePairAwareTextIterator class. It can be used like this:
999
1000         UChar32 character = 0;
1001         unsigned clusterLength = 0;
1002
1003         SurrogatePairAwareTextIterator textIterator(myString.characters(), 0, myString.length(), myString.length());
1004         while (textIterator.consume(character, clusterLength)) {
1005             // Either clusterLength is 1 and UChar32 fits into a single UChar.
1006             // Or     clusterLength is 2 and the UChar32 has been computed by combining the high & low surrogate pairs
1007             ...
1008         
1009             textIterator.advance(clusterLength);
1010         }
1011
1012         SVGGlyphMap is the next candidate that wants to make use of SurrogatePairAwareTextIterator.
1013         Doesn't affect any tests, just refactoring.
1014
1015         * CMakeLists.txt: Add SurrogatePairAwareTextIterator.* to build.
1016         * GNUmakefile.list.am: Ditto.
1017         * WebCore.gypi: Ditto.
1018         * WebCore.pro: Ditto.
1019         * WebCore.vcproj/WebCore.vcproj: Ditto.
1020         * WebCore.xcodeproj/project.pbxproj: Ditto.
1021         * platform/graphics/SurrogatePairAwareTextIterator.cpp: Copied from platform/graphics/WidthIterator.cpp.
1022         * platform/graphics/SurrogatePairAwareTextIterator.h: Added.
1023         (WebCore::SurrogatePairAwareTextIterator::currentCharacter):
1024         * platform/graphics/WidthIterator.cpp:
1025         (WebCore::WidthIterator::advance):
1026         * platform/graphics/WidthIterator.h:
1027
1028 2011-06-24  Adrienne Walker  <enne@google.com>
1029
1030         Reviewed by Simon Fraser.
1031
1032         Incorrect RenderLayer transforms on overflow RTL pages
1033         https://bugs.webkit.org/show_bug.cgi?id=60741
1034
1035         Fix positioning of the root graphics layer for RTL pages.  The fact
1036         that the left side of the page is negative for pages with overflow is
1037         not taken into account when calculating the position.  This negative
1038         value ends up being double-counted for the root graphics layer (once
1039         in the position and once in the offset) and it shifts child layers
1040         into the wrong place.
1041
1042         Tests: compositing/rtl/rtl-absolute-overflow-scrolled.html
1043                compositing/rtl/rtl-absolute-overflow.html
1044                compositing/rtl/rtl-absolute.html
1045                compositing/rtl/rtl-fixed-overflow-scrolled.html
1046                compositing/rtl/rtl-fixed-overflow.html
1047                compositing/rtl/rtl-fixed.html
1048                compositing/rtl/rtl-iframe-absolute-overflow-scrolled.html
1049                compositing/rtl/rtl-iframe-absolute-overflow.html
1050                compositing/rtl/rtl-iframe-absolute.html
1051                compositing/rtl/rtl-iframe-fixed-overflow-scrolled.html
1052                compositing/rtl/rtl-iframe-fixed-overflow.html
1053                compositing/rtl/rtl-iframe-fixed.html
1054                compositing/rtl/rtl-iframe-relative.html
1055                compositing/rtl/rtl-relative.html
1056
1057         * rendering/RenderLayerBacking.cpp:
1058         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
1059
1060 2011-06-24  Ryosuke Niwa  <rniwa@webkit.org>
1061
1062         Reviewed by Enrica Casucci.
1063
1064         Add BeforeChildren and AfterChildren to the Position's anchor types
1065         https://bugs.webkit.org/show_bug.cgi?id=63100
1066
1067         Added PositionIsBeforeChildren and PositionIsAfterChildren to Position::AnchorType and deployed them in
1068         firstPositionInNode and lastPositionInNode.
1069
1070         These new types of positions will let us express the first and the last positions in a non-text node in O(1).
1071
1072         No new tests because there is no new behavior or feature exposed.
1073
1074         * dom/Position.cpp:
1075         (WebCore::Position::Position): Assert that the anchor type is not BeforeChildren and AfterChildren for text nodes.
1076         (WebCore::Position::containerNode): For BeforeChildren and AfterChildren, the anchor node is the container node.
1077         (WebCore::Position::computeOffsetInContainerNode): The offset in the container node is 0 for BeforeChildren and
1078         the offset in the anchor node for AfterChildren.
1079         (WebCore::Position::offsetForPositionAfterAnchor): Called by deprecatedNode; the anchor type could be AfterChildren.
1080         (WebCore::Position::parentAnchoredEquivalent): If the anchor node is before or after children, then do the trick
1081         for table and ignored contents like before or after anchor.
1082         (WebCore::Position::computeNodeBeforePosition): Returns null for BeforeChildren and returns the last child of
1083         the anchor node for AfterChildren.
1084         (WebCore::Position::computeNodeAfterPosition): Returns the first child of the anchor node for BeforeChildren
1085         (WebCore::Position::atFirstEditingPositionForNode): A position is at the last editing position if the anchor type
1086         is BeforeChildren, or the anchor type is AfterChildren or AfterAnchor and the anchor doesn't have any children.
1087         (WebCore::Position::atLastEditingPositionForNode): A position is at the last editing position if the anchor type
1088         is AfterChildren.
1089         (WebCore::Position::showAnchorTypeAndOffset): Supports BeforeChildren and AfterChildren.
1090         * dom/Position.h:
1091         (WebCore::Position::deprecatedEditingOffset): Returns m_offset if the anchor type is BeforeChildren.
1092         (WebCore::firstPositionInNode): Returns a position in offset for a text node. Otherwise returns BeforeChildren.
1093         (WebCore::lastPositionInNode): Returns a position in offset for a text node. Otherwise returns AfterChildren.
1094         * editing/CompositeEditCommand.cpp:
1095         (WebCore::CompositeEditCommand::positionOutsideTabSpan): Since the anchor node was a text node,
1096         the anchor type shouldn't be BeforeChildren or AfterChildren.
1097         * editing/DeleteSelectionCommand.cpp:
1098         (WebCore::updatePositionForNodeRemoval): Supports BeforeChildren and AfterChildren.
1099         (WebCore::DeleteSelectionCommand::handleGeneralDelete): Calls updatePositionForNodeRemoval on m_downstremEnd
1100         when its anchor node is removed instead of manually updating the offset; also avoid calling moveToOffset
1101         on BeforeChildren or AfterChildren position.
1102         * editing/FormatBlockCommand.cpp:
1103         (WebCore::FormatBlockCommand::formatRange): Since lastParagraphInBlockNode is used to insert a placeholder
1104         after paragraphs below the block is moved into, it needs to be the position after the current last child in
1105         the block instead of after children in the block; otherwise the position will move to the end of block.
1106         * editing/VisiblePosition.cpp:
1107         (WebCore::VisiblePosition::characterAfter): Since the container node is never a text for position before/after
1108         children or before/after anchor, just return null for these anchor types.
1109
1110 2011-06-24  Dominic Cooney  <dominicc@chromium.org>
1111
1112         Reviewed by Dimitri Glazkov.
1113
1114         Convert shadow DOM-related tests to use window.internals
1115         https://bugs.webkit.org/show_bug.cgi?id=61671
1116
1117         * WebCore.exp.in: Exports for symbols used by WebCoreTestSupport.
1118         * testing/Internals.cpp: The new home of shadowRoot and friends.
1119         (WebCore::Internals::ensureShadowRoot):
1120         (WebCore::Internals::shadowRoot):
1121         (WebCore::Internals::removeShadowRoot):
1122         (WebCore::Internals::shadowPseudoId):
1123         * testing/Internals.h:
1124         * testing/Internals.idl:
1125
1126 2011-06-24  Tony Chang  <tony@chromium.org>
1127
1128         Reviewed by Darin Adler.
1129
1130         Refactor creation of primitive values in CSSParser
1131         https://bugs.webkit.org/show_bug.cgi?id=63270
1132
1133         Covered by existing tests.
1134
1135         * css/CSSParser.cpp:
1136         (WebCore::CSSParser::createPrimitiveNumericValue): Helper method for creating numeric values
1137             to keep the cast in one place.
1138         (WebCore::CSSParser::createPrimitiveStringValue): Helper method for creating string values.
1139         (WebCore::CSSParser::parseValidPrimitive):
1140         (WebCore::CSSParser::parseValue):
1141         (WebCore::CSSParser::parseWCSSInputProperty):
1142         (WebCore::CSSParser::parsePage):
1143         (WebCore::CSSParser::parseSizeParameter):
1144         (WebCore::CSSParser::parseContent):
1145         (WebCore::CSSParser::parseFillPositionX):
1146         (WebCore::CSSParser::parseFillPositionY):
1147         (WebCore::CSSParser::parseFillPositionComponent):
1148         (WebCore::CSSParser::parseFillSize):
1149         (WebCore::CSSParser::parseAnimationDelay):
1150         (WebCore::CSSParser::parseAnimationDuration):
1151         (WebCore::CSSParser::parseAnimationIterationCount):
1152         (WebCore::CSSParser::parseAnimationName):
1153         (WebCore::CSSParser::parseTransformOriginShorthand):
1154         (WebCore::CSSParser::parseDashboardRegions):
1155         (WebCore::CSSParser::parseCounterContent):
1156         (WebCore::CSSParser::parseShape):
1157         (WebCore::CSSParser::parseFont):
1158         (WebCore::CSSParser::parseReflect):
1159         (WebCore::CSSParser::parseBorderRadius):
1160         (WebCore::CSSParser::parseCounter):
1161         (WebCore::CSSParser::parseDeprecatedGradient):
1162         (WebCore::CSSParser::parseLinearGradient):
1163         (WebCore::CSSParser::parseRadialGradient):
1164         (WebCore::CSSParser::parseGradientColorStops):
1165         (WebCore::CSSParser::parseTransform):
1166         (WebCore::CSSParser::parseTransformOrigin):
1167         (WebCore::CSSParser::parseTextEmphasisStyle):
1168         * css/CSSParser.h:
1169         * css/CSSPrimitiveValueCache.h:
1170         (WebCore::CSSPrimitiveValueCache::createValue): pass String by const reference
1171
1172 2011-06-24  Carlos Garcia Campos  <cgarcia@igalia.com>
1173
1174         Reviewed by Martin Robinson.
1175
1176         [GTK] Fix runtime critical warnings in WebKit2
1177         https://bugs.webkit.org/show_bug.cgi?id=63256
1178
1179         Check whether there's a view widget before trying to use it in
1180         PlatformScreenGtk. If there isn't a view widget, which is the case
1181         in WebKit2, try to use the default GdkScreen and monitor.
1182
1183         * platform/gtk/PlatformScreenGtk.cpp:
1184         (WebCore::getToplevel): Helper function to get the toplevel
1185         widget.
1186         (WebCore::getVisual): Use getToplevel().
1187         (WebCore::getScreen): Helper funtion to get the screen of a
1188         widget.
1189         (WebCore::screenRect): Use getToplevel() and getScreen().
1190
1191 2011-06-24  Yuta Kitamura  <yutak@chromium.org>
1192
1193         Reviewed by Adam Barth.
1194
1195         WebSocket: Add run-time flag for new HyBi protocol
1196         https://bugs.webkit.org/show_bug.cgi?id=60348
1197
1198         Add a flag in Setting so that WebSocket protocols can be switched
1199         dynamically. The protocol we have implemented so far is based on
1200         older Hixie-76 specification. A new protocol is being discussed in
1201         IETF HyBi working group, and I'm planning to implement the new protocol
1202         behind this Settings flag.
1203
1204         I will add a method to LayoutTestController which flips this flag in
1205         a later patch. In this way, we can put tests for both protocols in
1206         the same place and test implementation for both protocols at the same time.
1207
1208         This patch only adds a flag. The flag is not used yet, thus there is
1209         no change in functionality. Therefore, no tests were added.
1210
1211         * page/Settings.cpp:
1212         (WebCore::Settings::Settings):
1213         * page/Settings.h:
1214         (WebCore::Settings::setUseHixie76WebSocketProtocol):
1215         (WebCore::Settings::useHixie76WebSocketProtocol):
1216
1217 2011-06-23  Mikhail Naganov  <mnaganov@chromium.org>
1218
1219         Reviewed by Pavel Feldman.
1220
1221         Web Inspector: [Chromium] Shorten DOMWindow URLs in heap profiles.
1222         https://bugs.webkit.org/show_bug.cgi?id=63238
1223
1224         * inspector/front-end/DetailedHeapshotGridNodes.js:
1225         (WebInspector.HeapSnapshotGridNode.prototype.hasHoverMessage.false.hoverMessage):
1226         (WebInspector.HeapSnapshotGenericObjectNode):
1227         (WebInspector.HeapSnapshotGenericObjectNode.prototype.hoverMessage):
1228         (WebInspector.HeapSnapshotGenericObjectNode.prototype._updateHasChildren):
1229         (WebInspector.HeapSnapshotGenericObjectNode.prototype.isDOMWindow):
1230         (WebInspector.HeapSnapshotGenericObjectNode.prototype.shortenWindowURL):
1231         * inspector/front-end/DetailedHeapshotView.js:
1232         (WebInspector.HeapSnapshotRetainingPathsList.prototype.showNext.pathFound):
1233         (WebInspector.DetailedHeapshotView.prototype._getHoverAnchor):
1234         (WebInspector.DetailedHeapshotView.prototype._showStringContentPopup.displayString):
1235         (WebInspector.DetailedHeapshotView.prototype._showStringContentPopup):
1236         * inspector/front-end/utilities.js:
1237         ():
1238
1239 2011-06-24  Vsevolod Vlasov  <vsevik@chromium.org>
1240
1241         Reviewed by Pavel Feldman.
1242
1243         Web Inspector: HTML preview should delete old iframe on show().
1244         https://bugs.webkit.org/show_bug.cgi?id=63170
1245
1246         * inspector/front-end/ResourceHTMLView.js:
1247         (WebInspector.ResourceHTMLView.prototype._createIFrame):
1248         * inspector/front-end/ResourcePreviewView.js:
1249         (WebInspector.ResourcePreviewView.prototype.contentLoaded):
1250
1251 2011-06-24  Dirk Schulze  <krit@webkit.org>
1252
1253         Reviewed by Nikolas Zimmermann.
1254
1255         Convert AnimatedString to SVGAnimatorFactory concept
1256         https://bugs.webkit.org/show_bug.cgi?id=63296
1257
1258         Follow up of "SVGAnimation should use direct unit animation for SVGLength": https://bugs.webkit.org/show_bug.cgi?id=61368
1259         This patch continues the conversion to the new concept of SVGAnimatorFactory with SVGString.
1260
1261         No new tests added. No change of functionality.
1262
1263         * CMakeLists.txt: Added new file to build system.
1264         * GNUmakefile.list.am: Ditto.
1265         * WebCore.gypi: Ditto.
1266         * WebCore.pro: Ditto.
1267         * WebCore.xcodeproj/project.pbxproj: Ditto.
1268         * svg/SVGAllInOne.cpp: Ditto.
1269         * svg/SVGAnimateElement.cpp:
1270         (WebCore::SVGAnimateElement::calculateAnimatedValue):
1271         (WebCore::SVGAnimateElement::calculateFromAndToValues):
1272         (WebCore::SVGAnimateElement::calculateFromAndByValues):
1273         (WebCore::SVGAnimateElement::resetToBaseValue):
1274         (WebCore::SVGAnimateElement::applyResultsToTarget):
1275         (WebCore::SVGAnimateElement::calculateDistance):
1276         * svg/SVGAnimateElement.h:
1277         * svg/SVGAnimatedString.cpp: Added. Animator for SVGString.
1278         (WebCore::SVGAnimatedStringAnimator::SVGAnimatedStringAnimator):
1279         (WebCore::SVGAnimatedStringAnimator::constructFromString):
1280         (WebCore::SVGAnimatedStringAnimator::calculateFromAndToValues):
1281         (WebCore::SVGAnimatedStringAnimator::calculateFromAndByValues):
1282         (WebCore::SVGAnimatedStringAnimator::calculateAnimatedValue):
1283         (WebCore::SVGAnimatedStringAnimator::calculateDistance):
1284         * svg/SVGAnimatedString.h:
1285         (WebCore::SVGAnimatedStringAnimator::~SVGAnimatedStringAnimator):
1286         * svg/SVGAnimatedType.cpp:
1287         (WebCore::SVGAnimatedType::~SVGAnimatedType):
1288         (WebCore::SVGAnimatedType::createString):
1289         (WebCore::SVGAnimatedType::string):
1290         (WebCore::SVGAnimatedType::valueAsString):
1291         (WebCore::SVGAnimatedType::setValueAsString):
1292         * svg/SVGAnimatedType.h:
1293         * svg/SVGAnimatorFactory.h:
1294         (WebCore::SVGAnimatorFactory::create):
1295
1296 2011-06-24  Mario Sanchez Prada  <msanchez@igalia.com>
1297
1298         Reviewed by Chris Fleizach.
1299
1300         [GTK] Consider rows being ignored when adding children to tables
1301         https://bugs.webkit.org/show_bug.cgi?id=62718
1302
1303         Hide row objects in tables in GTK's accessibility wrapper.
1304
1305         This is a different approach in the way WebCore's accessible
1306         rows are exposed to assistive technologies in the GTK port,
1307         since from now on those objects are kept in WebCore (they do not
1308         declare to ignore accessibility) and just bypassed in the mapping
1309         to ATK, allowing to hide them in the ATK hierarchy while, at the
1310         same time, keeping them internally to be able to provide enough
1311         information to determine tables related information, such as rows
1312         counting or finding an cell for specific coordinates.
1313
1314         * accessibility/gtk/AccessibilityObjectAtk.cpp:
1315         (WebCore::AccessibilityObject::accessibilityPlatformIncludesObject):
1316         Do not ignore accessibility for table rows here.
1317
1318         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
1319         (webkit_accessible_get_parent): Bypass rows when needed.
1320         (getNChildrenForTable): New, find the number of children for a
1321         table, which will be the addition of all cells for its rows.
1322         (webkit_accessible_get_n_children): Call to getNChildrenForTable
1323         for accessibility tables if needed.
1324         (getChildForTable): New, bypass rows when needed, retrieving
1325         cells as if they were direct children for tables.
1326         (webkit_accessible_ref_child): Call to refChildForTable if needed.
1327         (getIndexInParentForCellInRow): New, get the index for a given
1328         cell in its parent table, considering other rows' cells.
1329         (webkit_accessible_get_index_in_parent): Call to
1330         getIndexInParentForCellInRow if needed.
1331
1332 2011-06-24  Andrey Kosyakov  <caseq@chromium.org>
1333
1334         Reviewed by Yury Semikhatsky.
1335
1336         Web Inspector: extension panel iframes do not span entire panel client area
1337         https://bugs.webkit.org/show_bug.cgi?id=63165
1338
1339         * inspector/front-end/ExtensionServer.js:
1340         (WebInspector.ExtensionServer.prototype._onCreatePanel):
1341         (WebInspector.ExtensionServer.prototype.createClientIframe):
1342         * inspector/front-end/inspector.css:
1343         (iframe.extension):
1344         (iframe.panel.extension):
1345
1346 2011-06-24  David Grogan  <dgrogan@chromium.org>
1347
1348         Reviewed by Pavel Feldman.
1349
1350         Web Inspector: [REGRESSION r86838] line numbers do not scroll when script paused
1351         https://bugs.webkit.org/show_bug.cgi?id=61653
1352
1353         roll out r86838
1354
1355         No new tests - refactoring.
1356
1357         * dom/Document.h:
1358         * dom/EventQueue.cpp:
1359         (WebCore::EventQueueTimer::EventQueueTimer):
1360         (WebCore::EventQueueTimer::fired):
1361         (WebCore::EventQueue::create):
1362         (WebCore::EventQueue::EventQueue):
1363         (WebCore::EventQueue::~EventQueue):
1364         (WebCore::EventQueue::enqueueEvent):
1365         (WebCore::EventQueue::cancelEvent):
1366         (WebCore::EventQueue::cancelQueuedEvents):
1367         (WebCore::EventQueue::pendingEventTimerFired):
1368         (WebCore::EventQueue::dispatchEvent):
1369         * dom/EventQueue.h:
1370
1371 2011-06-24  Sheriff Bot  <webkit.review.bot@gmail.com>
1372
1373         Unreviewed, rolling out r89594.
1374         http://trac.webkit.org/changeset/89594
1375         https://bugs.webkit.org/show_bug.cgi?id=63316
1376
1377         It broke 5 tests on the Qt bot (Requested by Ossy_DC on
1378         #webkit).
1379
1380         * WebCore.exp.in:
1381         * icu/unicode/uscript.h:
1382         * page/Settings.cpp:
1383         (WebCore::Settings::setStandardFontFamily):
1384         (WebCore::Settings::setFixedFontFamily):
1385         (WebCore::Settings::setSerifFontFamily):
1386         (WebCore::Settings::setSansSerifFontFamily):
1387         (WebCore::Settings::setCursiveFontFamily):
1388         (WebCore::Settings::setFantasyFontFamily):
1389         * page/Settings.h:
1390         (WebCore::Settings::standardFontFamily):
1391         (WebCore::Settings::fixedFontFamily):
1392         (WebCore::Settings::serifFontFamily):
1393         (WebCore::Settings::sansSerifFontFamily):
1394         (WebCore::Settings::cursiveFontFamily):
1395         (WebCore::Settings::fantasyFontFamily):
1396
1397 2011-06-23  Tony Chang  <tony@chromium.org>
1398
1399         Reviewed by Kent Tamura.
1400
1401         Pass Strings by const reference in bindings code
1402         https://bugs.webkit.org/show_bug.cgi?id=63302
1403
1404         Note that since Strings hold a RefPtr to StringImpl, passing Strings
1405         by value isn't horrible, but it does cause ref count churn and using
1406         const references is more consistent with the rest of the code base.
1407
1408         * bindings/generic/BindingSecurity.h:
1409         (WebCore::::allowSettingFrameSrcToJavascriptUrl):
1410         (WebCore::::allowSettingSrcToJavascriptURL):
1411         * bindings/js/SerializedScriptValue.cpp:
1412         (WebCore::CloneSerializer::serialize):
1413         (WebCore::SerializedScriptValue::create):
1414         * bindings/js/SerializedScriptValue.h:
1415         * bindings/v8/SerializedScriptValue.cpp:
1416         (WebCore::SerializedScriptValue::createFromWire):
1417         (WebCore::SerializedScriptValue::create):
1418         (WebCore::SerializedScriptValue::SerializedScriptValue):
1419         * bindings/v8/SerializedScriptValue.h:
1420         * bindings/v8/V8Binding.h:
1421         (WebCore::V8ParameterBase::setString):
1422
1423 2011-06-23  Yury Semikhatsky  <yurys@chromium.org>
1424
1425         Reviewed by Pavel Feldman.
1426
1427         [Chromium] Web Inspector: provide context menu item for enabling native worker inspection
1428         https://bugs.webkit.org/show_bug.cgi?id=63258
1429
1430         Added context menu checkbox item that allows to enable inspection of
1431         native workers. The value will be persisted as other inspector settings
1432         and will be restored after frontend/breowser reopening.
1433
1434         * inspector/Inspector.json:
1435         * inspector/InspectorController.cpp:
1436         (WebCore::InspectorController::restoreInspectorStateFromCookie):
1437         * inspector/InspectorInstrumentation.h:
1438         (WebCore::InspectorInstrumentation::didStartWorkerContext):
1439         * inspector/InspectorWorkerAgent.cpp:
1440         (WebCore::InspectorWorkerAgent::setFrontend):
1441         (WebCore::InspectorWorkerAgent::restore):
1442         (WebCore::InspectorWorkerAgent::setWorkerInspectionEnabled):
1443         * inspector/InspectorWorkerAgent.h:
1444         * inspector/front-end/ScriptsPanel.js:
1445         (WebInspector.ScriptsPanel):
1446         (WebInspector.ScriptsPanel.prototype.reset):
1447         (WebInspector.ScriptsPanel.prototype._toggleFormatSourceFiles):
1448         (WebInspector.ScriptsPanel.prototype._contextMenu.enableWorkerInspection):
1449         (WebInspector.ScriptsPanel.prototype._contextMenu):
1450         * inspector/front-end/Settings.js:
1451         (WebInspector.Settings):
1452         * inspector/front-end/inspector.js:
1453         (WebInspector.didCreateWorker):
1454         (WebInspector.didDestroyWorker):
1455         * workers/Worker.cpp:
1456         (WebCore::Worker::notifyFinished):
1457
1458 2011-06-23  Simon Fraser  <simon.fraser@apple.com>
1459
1460         Reviewed by Dan Bernstein.
1461
1462         Need to turn off default animations for anchorPointZ in PlatformCALayer
1463         https://bugs.webkit.org/show_bug.cgi?id=63159
1464         
1465         When the z-component of transform-origin changed, we ran an implicit
1466         animation of anchorPointZ on the CALayer. Turn this off.
1467
1468         Test: transforms/3d/general/transform-origin-z-change.html
1469
1470         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
1471         (nullActionsDictionary):
1472
1473 2011-06-23  Zhenyao Mo  <zmo@google.com>
1474
1475         Reviewed by Kenneth Russell.
1476
1477         Limit WebGL internal drawingBuffer size to 4k x 4k
1478         https://bugs.webkit.org/show_bug.cgi?id=63304
1479
1480         * html/canvas/WebGLRenderingContext.cpp:
1481         (WebCore::WebGLRenderingContext::reshape): Limit drawing buffer size to 4k x 4k.
1482
1483 2011-06-20  MORITA Hajime  <morrita@google.com>
1484
1485         Reviewed by Dimitri Glazkov.
1486
1487         [ShadowContentElement] should layout child whitespace between span.
1488         https://bugs.webkit.org/show_bug.cgi?id=62202
1489
1490         NodeRenderingContext::nextRenderer() and previousRenderer()
1491         ignored forwarded content tree hierarchies and used render-object
1492         hierarchies instead, that caused some wrong Text node rendering.
1493         
1494         This change uses ShadowContentElement::m_inclusions for the lookup.
1495         In this way, these methods can reflect hierarchies of forward light tree.
1496         
1497         * dom/NodeRenderingContext.cpp:
1498         (WebCore::NodeRenderingContext::NodeRenderingContext):
1499         (WebCore::nextRendererOf): Added. This traverses content element's children for searching neighboring renderer.
1500         (WebCore::previousRendererOf): Added. This traverses content element's children for searching neighboring renderer.
1501         (WebCore::NodeRenderingContext::nextRenderer):
1502         (WebCore::NodeRenderingContext::previousRenderer):
1503         * dom/NodeRenderingContext.h:
1504         * dom/ShadowContentElement.h:
1505         (ShadowContentElement::inclusionIndexOf): Added.
1506         * dom/ShadowContentSelector.cpp:
1507         (WebCore::ShadowContentSelector::activeElement):
1508         * dom/ShadowContentSelector.h:
1509         * dom/ShadowRoot.cpp:
1510         (WebCore::ShadowRoot::activeContentElement):
1511         * dom/ShadowRoot.h:
1512         * rendering/RenderTreeAsText.cpp: 
1513         (WebCore::externalRepresentation): Fixed an apparent bug introduced at r89230.
1514
1515 2011-05-25  James Robinson  <jamesr@chromium.org>
1516
1517         Reviewed by Kenneth Russell.
1518
1519         [chromium] Fix ownership of PlatformImage for ImageLayerChromiums
1520         https://bugs.webkit.org/show_bug.cgi?id=61099
1521
1522         For a composited image, both the ImageLayerChromium and its associated LayerTilerChromium need access to a
1523         PlatformImage - the ImageLayerChromium has to update the PlatformImage's contents and the LayerTilerChromium has
1524         to upload pixels from it.  This patch makes the ImageLayerTextureUpdater have exclusive ownership of the
1525         PlatformImage and moves ownership of the LayerTextureUpdater from the LayerTilerChromium to the owner of the
1526         tiler.  The updater is passed in as a parameter to the relevant tiler calls.
1527
1528         Patch also fixes a number of minor style issues (missing explicit keyword on constructor, etc).
1529
1530         Refactor only, no new tests.
1531
1532         * platform/graphics/chromium/ContentLayerChromium.cpp:
1533         (WebCore::ContentLayerPainter::create):
1534         (WebCore::ContentLayerPainter::ContentLayerPainter):
1535         (WebCore::ContentLayerChromium::paintContentsIfDirty):
1536         (WebCore::ContentLayerChromium::createTextureUpdaterIfNeeded):
1537         (WebCore::ContentLayerChromium::draw):
1538         (WebCore::ContentLayerChromium::createTilerIfNeeded):
1539         (WebCore::ContentLayerChromium::updateCompositorResources):
1540         * platform/graphics/chromium/ContentLayerChromium.h:
1541         * platform/graphics/chromium/ImageLayerChromium.cpp:
1542         (WebCore::ImageLayerTextureUpdater::create):
1543         (WebCore::ImageLayerTextureUpdater::updateFromImage):
1544         (WebCore::ImageLayerTextureUpdater::imageSize):
1545         (WebCore::ImageLayerTextureUpdater::ImageLayerTextureUpdater):
1546         (WebCore::ImageLayerChromium::~ImageLayerChromium):
1547         (WebCore::ImageLayerChromium::paintContentsIfDirty):
1548         (WebCore::ImageLayerChromium::updateCompositorResources):
1549         (WebCore::ImageLayerChromium::setLayerRenderer):
1550         (WebCore::ImageLayerChromium::createTextureUpdaterIfNeeded):
1551         (WebCore::ImageLayerChromium::layerBounds):
1552         * platform/graphics/chromium/ImageLayerChromium.h:
1553         * platform/graphics/chromium/LayerRendererChromium.cpp:
1554         (WebCore::LayerRendererChromium::LayerRendererChromium):
1555         (WebCore::LayerRendererChromium::updateRootLayerContents):
1556         (WebCore::LayerRendererChromium::drawRootLayer):
1557         (WebCore::LayerRendererChromium::updateLayers):
1558         * platform/graphics/chromium/LayerRendererChromium.h:
1559         * platform/graphics/chromium/LayerTextureUpdater.h:
1560         (WebCore::LayerTextureUpdater::LayerTextureUpdater):
1561         * platform/graphics/chromium/LayerTextureUpdaterCanvas.cpp:
1562         (WebCore::LayerTextureUpdaterBitmap::create):
1563         (WebCore::LayerTextureUpdaterSkPicture::create):
1564         * platform/graphics/chromium/LayerTextureUpdaterCanvas.h:
1565         * platform/graphics/chromium/LayerTilerChromium.cpp:
1566         (WebCore::LayerTilerChromium::create):
1567         (WebCore::LayerTilerChromium::LayerTilerChromium):
1568         (WebCore::LayerTilerChromium::prepareToUpdate):
1569         (WebCore::LayerTilerChromium::updateRect):
1570         (WebCore::LayerTilerChromium::draw):
1571         * platform/graphics/chromium/LayerTilerChromium.h:
1572
1573 2011-06-23  Adrienne Walker  <enne@google.com>
1574
1575         Unreviewed, rolling out r89632 and r89640.
1576         http://trac.webkit.org/changeset/89632
1577         http://trac.webkit.org/changeset/89640
1578         https://bugs.webkit.org/show_bug.cgi?id=60741
1579
1580         Breaks ancestor-overflow-change unexpectedly
1581
1582         * rendering/RenderLayerBacking.cpp:
1583         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
1584
1585 2011-06-23  John Bates  <jbates@google.com>
1586
1587         Reviewed by James Robinson.
1588
1589         Fix latch deadlock when GPU process crashes or context is lost.
1590         https://bugs.webkit.org/show_bug.cgi?id=63189
1591         The main bug fix is to only set/wait latches if the child context has no errors.
1592         Additionally, the LayerChromium classes needed to be modified to not continue drawing when
1593         their corresponding contexts have errors. Otherwise, they would draw with invalid texture ids.
1594
1595         Test: open particles WebGL demo in chrome, kill GPU process from Task Manager; observe no deadlock.
1596
1597         * platform/graphics/chromium/LayerRendererChromium.cpp:
1598         (WebCore::LayerRendererChromium::LayerRendererChromium):
1599         (WebCore::LayerRendererChromium::updateAndDrawLayers):
1600         (WebCore::LayerRendererChromium::updateLayers):
1601         (WebCore::LayerRendererChromium::isCompositorContextLost):
1602         * platform/graphics/chromium/LayerRendererChromium.h:
1603         * platform/graphics/chromium/WebGLLayerChromium.cpp:
1604         (WebCore::WebGLLayerChromium::drawsContent):
1605         (WebCore::WebGLLayerChromium::updateCompositorResources):
1606         (WebCore::WebGLLayerChromium::setContext):
1607         * platform/graphics/chromium/WebGLLayerChromium.h:
1608         * platform/graphics/chromium/Canvas2DLayerChromium.cpp:
1609         (WebCore::Canvas2DLayerChromium::drawsContent):
1610         * platform/graphics/chromium/Canvas2DLayerChromium.h:
1611
1612 2011-06-23  Alok Priyadarshi  <alokp@chromium.org>
1613
1614         Reviewed by James Robinson.
1615
1616         [chromium] Red and Blue channels are swapped in images with accelerated drawing
1617         https://bugs.webkit.org/show_bug.cgi?id=61442
1618
1619         We were uploading BGRA pixels into RGBA textures and swapping the components in the pixel shader.
1620         This strategy does not work with accelerated drawing because we are directly rendering to the texture, not uploading pixels.
1621         This patch uses BGRA textures if available. If not it falls back to the original scheme of swapping the components in the pixel shader. 
1622
1623         Tests: compositing/color-matching/image-color-matching.html (existing)
1624
1625         * WebCore.gypi:
1626         * platform/graphics/chromium/ImageLayerChromium.cpp:
1627         (WebCore::ImageLayerTextureUpdater::sampledTexelFormat):
1628         (WebCore::ImageLayerTextureUpdater::updateTextureRect):
1629         * platform/graphics/chromium/LayerRendererChromium.cpp:
1630         (WebCore::LayerRendererChromium::LayerRendererChromium):
1631         (WebCore::LayerRendererChromium::skiaContext):
1632         (WebCore::LayerRendererChromium::tilerProgram):
1633         (WebCore::LayerRendererChromium::tilerProgramSwizzle):
1634         (WebCore::LayerRendererChromium::cleanupSharedObjects):
1635         * platform/graphics/chromium/LayerRendererChromium.h:
1636         * platform/graphics/chromium/LayerTexture.h:
1637         (WebCore::LayerTexture::format):
1638         * platform/graphics/chromium/LayerTextureSubImage.cpp:
1639         (WebCore::LayerTextureSubImage::upload):
1640         (WebCore::LayerTextureSubImage::uploadWithTexSubImage):
1641         (WebCore::LayerTextureSubImage::uploadWithMapTexSubImage):
1642         * platform/graphics/chromium/LayerTextureSubImage.h:
1643         * platform/graphics/chromium/LayerTextureUpdater.h:
1644         * platform/graphics/chromium/LayerTextureUpdaterCanvas.cpp:
1645         (WebCore::LayerTextureUpdaterBitmap::sampledTexelFormat):
1646         (WebCore::LayerTextureUpdaterBitmap::updateTextureRect):
1647         (WebCore::LayerTextureUpdaterSkPicture::sampledTexelFormat):
1648         (WebCore::LayerTextureUpdaterSkPicture::createFrameBuffer):
1649         * platform/graphics/chromium/LayerTextureUpdaterCanvas.h:
1650         * platform/graphics/chromium/LayerTilerChromium.cpp:
1651         (WebCore::LayerTilerChromium::LayerTilerChromium):
1652         (WebCore::LayerTilerChromium::prepareToUpdate):
1653         (WebCore::LayerTilerChromium::updateRect):
1654         (WebCore::LayerTilerChromium::draw):
1655         (WebCore::LayerTilerChromium::growLayerToContain):
1656         (WebCore::LayerTilerChromium::drawTiles):
1657         (WebCore::LayerTilerChromium::drawTexturedQuad):
1658         * platform/graphics/chromium/LayerTilerChromium.h:
1659         * platform/graphics/chromium/PlatformColor.h: Added.
1660         (WebCore::PlatformColor::format):
1661         (WebCore::PlatformColor::bestTextureFormat):
1662         (WebCore::PlatformColor::sameComponentOrder):
1663         * platform/graphics/chromium/ShaderChromium.cpp:
1664         (WebCore::FragmentShaderRGBATexSwizzleAlpha::getShaderString):
1665         * platform/graphics/chromium/ShaderChromium.h:
1666         * platform/graphics/chromium/cc/CCHeadsUpDisplay.h:
1667
1668 2011-06-23  Adrienne Walker  <enne@google.com>
1669
1670         Reviewed by Simon Fraser.
1671
1672         Incorrect RenderLayer transforms on overflow RTL pages
1673         https://bugs.webkit.org/show_bug.cgi?id=60741
1674
1675         Fix positioning of the root graphics layer for RTL pages.  The fact
1676         that the left side of the page is negative for pages with overflow is
1677         not taken into account when calculating the position.  This negative
1678         value ends up being double-counted for the root graphics layer (once
1679         in the position and once in the offset) and it shifts child layers
1680         into the wrong place.
1681
1682         Tests: compositing/rtl/rtl-absolute-overflow-scrolled.html
1683                compositing/rtl/rtl-absolute-overflow.html
1684                compositing/rtl/rtl-absolute.html
1685                compositing/rtl/rtl-fixed-overflow-scrolled.html
1686                compositing/rtl/rtl-fixed-overflow.html
1687                compositing/rtl/rtl-fixed.html
1688                compositing/rtl/rtl-iframe-absolute-overflow-scrolled.html
1689                compositing/rtl/rtl-iframe-absolute-overflow.html
1690                compositing/rtl/rtl-iframe-absolute.html
1691                compositing/rtl/rtl-iframe-fixed-overflow-scrolled.html
1692                compositing/rtl/rtl-iframe-fixed-overflow.html
1693                compositing/rtl/rtl-iframe-fixed.html
1694                compositing/rtl/rtl-iframe-relative.html
1695                compositing/rtl/rtl-relative.html
1696
1697         * rendering/RenderLayerBacking.cpp:
1698         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
1699
1700 2011-06-23  Emil A Eklund  <eae@chromium.org>
1701
1702         Reviewed by Eric Seidel.
1703
1704         FloatRect should implement the same methods as IntRect
1705         https://bugs.webkit.org/show_bug.cgi?id=63273
1706         
1707         Add missing methods from IntRect to FloatRect in preparation for moving
1708         the rendering tree over to floats.
1709
1710         * platform/graphics/FloatPoint.h:
1711         (WebCore::FloatPoint::expandedTo):
1712         (WebCore::FloatPoint::transposedPoint):
1713         * platform/graphics/FloatRect.h:
1714         (WebCore::FloatRect::move):
1715         (WebCore::FloatRect::expand):
1716         (WebCore::FloatRect::contract):
1717         (WebCore::FloatRect::shiftXEdgeTo):
1718         (WebCore::FloatRect::shiftMaxXEdgeTo):
1719         (WebCore::FloatRect::shiftYEdgeTo):
1720         (WebCore::FloatRect::shiftMaxYEdgeTo):
1721         (WebCore::FloatRect::minXMinYCorner):
1722         (WebCore::FloatRect::maxXMinYCorner):
1723         (WebCore::FloatRect::minXMaxYCorner):
1724         (WebCore::FloatRect::maxXMaxYCorner):
1725         (WebCore::FloatRect::transposedRect):
1726         * platform/graphics/FloatSize.h:
1727         (WebCore::FloatSize::expand):
1728         (WebCore::FloatSize::transposedSize):
1729
1730 2011-06-23  Emil A Eklund  <eae@chromium.org>
1731
1732         Reviewed by Darin Adler.
1733
1734         input/textarea onchange doesn't fire if value is set in key listener
1735         https://bugs.webkit.org/show_bug.cgi?id=63092
1736
1737         Change setValue implementation of HTMLInputElement and HTMLTextAreaElement to
1738         not call setTextAsOfLastFormControlChangeEvent unless the value truly changed.
1739         Thus element.value = element.value will no longer reset the state 
1740         m_textAsOfLastFormControlChangeEvent field and suppress the change event.
1741
1742         Test: fast/events/onchange-setvalue.html
1743
1744         * html/HTMLInputElement.cpp:
1745         (WebCore::HTMLInputElement::setValue):
1746         * html/HTMLTextAreaElement.cpp:
1747         (WebCore::HTMLTextAreaElement::setValue):
1748         (WebCore::HTMLTextAreaElement::setNonDirtyValue):
1749         (WebCore::HTMLTextAreaElement::setValueCommon):
1750
1751 2011-06-23  Alexis Menard  <alexis.menard@openbossa.org>
1752
1753         Reviewed by Eric Carlson.
1754
1755         [Qt] Implement fullscreen support on Mac with the QuickTime backend.
1756         https://bugs.webkit.org/show_bug.cgi?id=61728
1757
1758         Implement fullscreen support for Qt when using the QuickTime backend.
1759         We mostly use what is already done for the Mac port.
1760
1761         * DerivedSources.pro: We use the mac files and they have <WebCore/x> type
1762         of includes. We need to generate those headers.
1763         * WebCore.pro:
1764         * platform/mac/WebVideoFullscreenController.h:
1765         * platform/mac/WebVideoFullscreenController.mm:
1766         * platform/mac/WebVideoFullscreenHUDWindowController.h:
1767         * platform/mac/WebVideoFullscreenHUDWindowController.mm:
1768         * platform/qt/WebCoreSystemInterface.h:
1769         * platform/qt/WebCoreSystemInterface.mm:
1770
1771 2011-06-23  Darin Adler  <darin@apple.com>
1772
1773         Reviewed by Ryosuke Niwa.
1774
1775         RefPtr misused as argument type in a few classes
1776         https://bugs.webkit.org/show_bug.cgi?id=62955
1777
1778         * dom/DataTransferItem.cpp:
1779         (WebCore::DataTransferItem::DataTransferItem):
1780         * dom/DataTransferItem.h:
1781         * dom/DataTransferItems.cpp:
1782         (WebCore::DataTransferItems::DataTransferItems):
1783         * dom/DataTransferItems.h:
1784         * editing/CompositeEditCommand.cpp:
1785         (WebCore::CompositeEditCommand::rebalanceWhitespaceOnTextSubstring):
1786         * editing/CompositeEditCommand.h:
1787         * page/WebKitAnimationList.cpp:
1788         (WebCore::WebKitAnimationList::append):
1789         (WebCore::WebKitAnimationList::insertAnimation):
1790         * page/WebKitAnimationList.h:
1791         * svg/graphics/filters/SVGFEImage.cpp:
1792         (WebCore::FEImage::FEImage):
1793         (WebCore::FEImage::create):
1794         * svg/graphics/filters/SVGFEImage.h:
1795         * svg/graphics/filters/SVGFilterBuilder.cpp:
1796         (WebCore::SVGFilterBuilder::SVGFilterBuilder):
1797         (WebCore::SVGFilterBuilder::add):
1798         (WebCore::SVGFilterBuilder::appendEffectToEffectReferences):
1799         * svg/graphics/filters/SVGFilterBuilder.h:
1800         * websockets/ThreadableWebSocketChannelClientWrapper.cpp:
1801         (WebCore::ThreadableWebSocketChannelClientWrapper::didConnectCallback):
1802         (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessageCallback):
1803         (WebCore::ThreadableWebSocketChannelClientWrapper::didStartClosingHandshakeCallback):
1804         (WebCore::ThreadableWebSocketChannelClientWrapper::didCloseCallback):
1805         * websockets/ThreadableWebSocketChannelClientWrapper.h:
1806         * websockets/WorkerThreadableWebSocketChannel.cpp:
1807         (WebCore::WorkerThreadableWebSocketChannel::Peer::Peer):
1808         (WebCore::WorkerThreadableWebSocketChannel::Bridge::setWebSocketChannel):
1809         (WebCore::WorkerThreadableWebSocketChannel::Bridge::mainThreadCreateWebSocketChannel):
1810         * websockets/WorkerThreadableWebSocketChannel.h:
1811         Use PassRefPtr or raw pointer as appropriate for RefPtr arguments.
1812
1813 2011-06-23  Sheriff Bot  <webkit.review.bot@gmail.com>
1814
1815         Unreviewed, rolling out r89591 and r89593.
1816         http://trac.webkit.org/changeset/89591
1817         http://trac.webkit.org/changeset/89593
1818         https://bugs.webkit.org/show_bug.cgi?id=63279
1819
1820         Caused test crashes in SL and Chromium (Requested by dimich_
1821         on #webkit).
1822
1823         * accessibility/AXObjectCache.cpp:
1824         (WebCore::AXObjectCache::AXObjectCache):
1825         (WebCore::AXObjectCache::remove):
1826         (WebCore::AXObjectCache::childrenChanged):
1827         * accessibility/AXObjectCache.h:
1828         * accessibility/AccessibilityMenuList.cpp:
1829         (WebCore::AccessibilityMenuList::childrenChanged):
1830         * accessibility/AccessibilityMenuList.h:
1831         * accessibility/AccessibilityMenuListPopup.cpp:
1832         (WebCore::AccessibilityMenuListPopup::childrenChanged):
1833         * accessibility/AccessibilityMenuListPopup.h:
1834         * accessibility/AccessibilityObject.h:
1835         (WebCore::AccessibilityObject::childrenChanged):
1836         * accessibility/AccessibilityRenderObject.cpp:
1837         (WebCore::startOfContinuations):
1838         (WebCore::AccessibilityRenderObject::updateAccessibilityRole):
1839         (WebCore::AccessibilityRenderObject::childrenChanged):
1840         * accessibility/AccessibilityRenderObject.h:
1841
1842 2011-06-23  Andreas Kling  <kling@webkit.org>
1843
1844         Reviewed by Benjamin Poulain.
1845
1846         [Qt] Unbreak simple font fast-path after QRawFont API changes.
1847         https://bugs.webkit.org/show_bug.cgi?id=63272
1848
1849         In the Qt 4.8 branch, the QGlyphs class has been renamed to
1850         QGlyphRun, and some other small things have been tweaked.
1851
1852         * WebCore.pro:
1853         * platform/graphics/qt/FontCacheQt.cpp:
1854         (WebCore::rawFontForCharacters):
1855         * platform/graphics/qt/FontQt.cpp:
1856         (WebCore::Font::drawGlyphs):
1857
1858 2011-06-23  Tony Chang  <tony@chromium.org>
1859
1860         Reviewed by Andreas Kling.
1861
1862         Pass Strings as const references in NetworkResourcesData.h
1863         https://bugs.webkit.org/show_bug.cgi?id=63271
1864
1865         * inspector/NetworkResourcesData.h:
1866         (WebCore::NetworkResourcesData::ResourceData::setFrameId):
1867         (WebCore::NetworkResourcesData::ResourceData::setUrl):
1868         (WebCore::NetworkResourcesData::ResourceData::setTextEncodingName):
1869
1870 2011-06-23  Jay Civelli  <jcivelli@chromium.org>
1871
1872         Reviewed by Adam Barth.
1873
1874         Fixing the SharedBufferChunkReader API so it works correctly with
1875         binary data (non printable characters).
1876         Also adding a method to peek at the data (this is needed for MHTML
1877         with binary parts).
1878         https://bugs.webkit.org/show_bug.cgi?id=63231
1879
1880         * loader/archive/mhtml/MHTMLParser.cpp:
1881         (WebCore::skipLinesUntilBoundaryFound):
1882         (WebCore::MHTMLParser::parseNextPart):
1883         * loader/archive/mhtml/MHTMLParser.h:
1884         * platform/SharedBufferChunkReader.cpp:
1885         (WebCore::SharedBufferChunkReader::SharedBufferChunkReader):
1886         (WebCore::SharedBufferChunkReader::setSeparator):
1887         (WebCore::SharedBufferChunkReader::nextChunk):
1888         (WebCore::SharedBufferChunkReader::nextChunkAsUTF8StringWithLatin1Fallback):
1889         (WebCore::SharedBufferChunkReader::peek):
1890         * platform/SharedBufferChunkReader.h:
1891         * platform/network/MIMEHeader.cpp:
1892         (WebCore::retrieveKeyValuePairs):
1893
1894 2011-06-23  Nate Chapin  <japhet@chromium.org>
1895
1896         Unreviewed.
1897
1898         Revert production code part of r89503, since it's causing
1899         crashes on WebKit2/mac and failures on qt.
1900
1901         * dom/Document.cpp:
1902         (WebCore::Document::Document):
1903         (WebCore::Document::dispatchWindowLoadEvent):
1904         * dom/Document.h:
1905         (WebCore::Document::processingLoadEvent):
1906         * loader/DocumentLoader.cpp:
1907         (WebCore::DocumentLoader::isLoadingInAPISense):
1908
1909 2011-06-23  Young Han Lee  <joybro@company100.net>
1910
1911         Reviewed by Simon Fraser.
1912
1913         runAnimationTest always fails if the pause API is enabled and the test target animation has "infinite" iteration count.
1914         https://bugs.webkit.org/show_bug.cgi?id=63152
1915
1916         The pausing conditions are modified. Now it accepts the infinite-iteration-count,
1917         but rejects the zero-iteration-count. There is no reason to consider the zero-count meaning no animation.
1918         
1919         Test: animations/keyframes-infinite-iterations.html
1920
1921         * page/animation/CompositeAnimation.cpp:
1922         (WebCore::CompositeAnimation::pauseAnimationAtTime):
1923
1924 2011-06-23  Abhishek Arya  <inferno@chromium.org>
1925
1926         Reviewed by Adam Barth.
1927
1928         RefPtr m_style in MediaQueryEvaluator in case of callers like
1929         MediaQueryMatcher::prepareEvaluator that do not retain its reference.
1930         https://bugs.webkit.org/show_bug.cgi?id=63264
1931
1932         Test: fast/css/media-query-evaluator-crash.html
1933
1934         * css/MediaQueryEvaluator.cpp:
1935         (WebCore::MediaQueryEvaluator::eval):
1936         * css/MediaQueryEvaluator.h:
1937
1938 2011-06-23  Jungshik Shin  <jshin@chromium.org>
1939
1940         Reviewed by Alexey Proskuryakov.
1941
1942         Allow generic font family settings per script code.
1943         https://bugs.webkit.org/show_bug.cgi?id=20797
1944
1945         Make generic font family getters/setters accept an additional
1946         argument (script code). It has a default value so that if an embedder
1947         does not have/want a per-script font family setting, call-sites
1948         don't have to be changed.
1949         This is to prepare for fixing bug 10874 (font selection is not
1950         language-dependent) and bug 18085.
1951
1952         uscript.h has been updated to that of ICU 3.6 (the version of ICU on
1953         Mac OS 10.5)
1954
1955         There should be no change in layout and no new layout test
1956         is added.
1957
1958         * WebCore.exp.in:
1959         * icu/unicode/uscript.h: updated to ICU 4.6
1960         * page/Settings.cpp:
1961         (WebCore::setGenericFontFamilyMap): helper to set generic family per script
1962         (WebCore::getGenericFontFamilyForScript): helper function used by getters for fooFontFamily.
1963         (WebCore::Settings::standardFontFamily):
1964         (WebCore::Settings::setStandardFontFamily):
1965         (WebCore::Settings::fixedFontFamily):
1966         (WebCore::Settings::setFixedFontFamily):
1967         (WebCore::Settings::serifFontFamily):
1968         (WebCore::Settings::setSerifFontFamily):
1969         (WebCore::Settings::sansSerifFontFamily):
1970         (WebCore::Settings::setSansSerifFontFamily):
1971         (WebCore::Settings::cursiveFontFamily):
1972         (WebCore::Settings::setCursiveFontFamily):
1973         (WebCore::Settings::fantasyFontFamily):
1974         (WebCore::Settings::setFantasyFontFamily):
1975         * page/Settings.h: setter and getter for FooFontFamily have a new optional argument, scriptCode.
1976
1977 2011-06-23  Dan Bernstein  <mitz@apple.com>
1978
1979         Reviewed by Alexey Proskuryakov.
1980
1981         Make line breaking obey the -webkit-locale property
1982         https://bugs.webkit.org/show_bug.cgi?id=63209
1983
1984         Test: platform/mac/fast/text/line-break-locale.html
1985
1986         * platform/text/TextBreakIterator.h:
1987         (WebCore::LazyLineBreakIterator::LazyLineBreakIterator): Take an optional locale identifier and
1988         initialize the m_locale member.
1989         (WebCore::LazyLineBreakIterator::get): Pass the locale to acquireLineBreakIterator().
1990         (WebCore::LazyLineBreakIterator::reset): Pass the locale to releaseLineBreakIterator() and update
1991         the m_locale member.
1992         * platform/text/TextBreakIteratorICU.cpp:
1993         (WebCore::LineBreakIteratorPool::sharedPool): Return a shared instance.
1994         (WebCore::LineBreakIteratorPool::take): Returns a text iterator for the given locale, either a newly-
1995         created one, or an existing one from the pool.
1996         (WebCore::LineBreakIteratorPool::put): Puts an iterator back into the pool, removing the least-recently used
1997         one if needed.
1998         (WebCore::LineBreakIteratorPool::LineBreakIteratorPool):
1999         (WebCore::acquireLineBreakIterator): Changed to take an optional local identifier, and to use the pool.
2000         (WebCore::releaseLineBreakIterator): Changed to use the pool.
2001         * platform/text/brew/TextBreakIteratorBrew.cpp:
2002         (WebCore::acquireLineBreakIterator): Updated for new parameter.
2003         * platform/text/gtk/TextBreakIteratorGtk.cpp:
2004         (WebCore::acquireLineBreakIterator): Ditto.
2005         * platform/text/qt/TextBreakIteratorQt.cpp:
2006         (WebCore::acquireLineBreakIterator): Ditto.
2007         * platform/text/wince/TextBreakIteratorWinCE.cpp:
2008         (WebCore::acquireLineBreakIterator): Ditto.
2009         * rendering/RenderBlockLineLayout.cpp:
2010         (WebCore::RenderBlock::LineBreaker::nextLineBreak): Use the locale from the style for the line break
2011         iterator.
2012         * rendering/RenderText.cpp:
2013         (WebCore::RenderText::computePreferredLogicalWidths): Ditto.
2014
2015 2011-06-23  Chris Fleizach  <cfleizach@apple.com>
2016
2017         Reviewed by Darin Adler.
2018
2019         ARIA live regions don't trigger notifications for elements that aren't in the AX tree
2020         https://bugs.webkit.org/show_bug.cgi?id=62289
2021
2022         If an ARIA Live region udpates an element that is not in the AX object cache, then the Live region
2023         notification is not sent. To fix this, I think the childrenChanged() method needs to actually create
2024         the appropriate objects, but since that method gets called during a render tree update, we've learned 
2025         that it's generally not safe to create objects.
2026  
2027         Instead a one shot timer can be fired that will update and create the necessary objects so that the
2028         correct notification can be sent.
2029
2030         Test: platform/mac/accessibility/aria-liveregion-without-element-access.html
2031
2032         * accessibility/AXObjectCache.cpp:
2033         (WebCore::AXObjectCache::AXObjectCache):
2034         (WebCore::AXObjectCache::remove):
2035         (WebCore::AXObjectCache::childrenUpdateTimerFired):
2036         (WebCore::AXObjectCache::childrenChanged):
2037         * accessibility/AXObjectCache.h:
2038         * accessibility/AccessibilityMenuList.cpp:
2039         (WebCore::AccessibilityMenuList::childrenChanged):
2040         * accessibility/AccessibilityMenuList.h:
2041         * accessibility/AccessibilityMenuListPopup.cpp:
2042         (WebCore::AccessibilityMenuListPopup::childrenChanged):
2043         * accessibility/AccessibilityMenuListPopup.h:
2044         * accessibility/AccessibilityObject.h:
2045         (WebCore::AccessibilityObject::childrenChanged):
2046         * accessibility/AccessibilityRenderObject.cpp:
2047         (WebCore::startOfContinuations):
2048            This changed exposed a case where an object was inlineElementContinuation, but not renderInlined,
2049            which led to an assert.
2050         (WebCore::AccessibilityRenderObject::updateAccessibilityRole):
2051         (WebCore::AccessibilityRenderObject::childrenChanged):
2052         * accessibility/AccessibilityRenderObject.h:
2053
2054 2011-06-23  Dirk Schulze  <krit@webkit.org>
2055
2056         Reviewed by Nikolas Zimmermann.
2057
2058         Convert SVGColor to SVGAnimatorFactory concept
2059         https://bugs.webkit.org/show_bug.cgi?id=63246
2060
2061         Follow up of "SVGAnimation should use direct unit animation for SVGLength": https://bugs.webkit.org/show_bug.cgi?id=61368
2062         This patch continues the conversion to the new concept of SVGAnimatorFactory with SVGColor.
2063
2064         Changed constructors of animators to take the animation element SVGAnimationsElement as new argument. Removed attribute name argument instead.
2065         This information is already exposed by the animation element. The animators store the pointer of the animation element, so that it is not
2066         necessary to pass it as argument to the functions calculateDistance, calculateAnimatedValue.
2067         
2068         Replace all SVGSMILElement references by SVGAnimationsElement - the common base class of all animation elements.
2069
2070         Added a new method in SVGAnimateElement to determine the property value type of CSS properties (regular value type, inherit or currentColor).
2071         The other two new methods fromPropertyValueType() and toPropertyValueType() avoid passing boolean arguments in calculateAnimatedValue().
2072
2073         No new tests added. Current tests cover the changes.
2074
2075         * CMakeLists.txt: Added new files to build system.
2076         * GNUmakefile.list.am: Ditto.
2077         * WebCore.gypi: Ditto.
2078         * WebCore.pro: Ditto.
2079         * WebCore.vcproj/WebCore.vcproj: Ditto.
2080         * WebCore.xcodeproj/project.pbxproj: Ditto.
2081         * svg/SVGAllInOne.cpp:  Ditto.
2082         * svg/SVGAnimateElement.cpp: Use Animator for SVGColor. 
2083         (WebCore::SVGAnimateElement::SVGAnimateElement):
2084         (WebCore::SVGAnimateElement::determineAnimatedAttributeType):
2085         (WebCore::SVGAnimateElement::calculateAnimatedValue):
2086         (WebCore::SVGAnimateElement::determinePropertyValueTypes):
2087         (WebCore::SVGAnimateElement::calculateFromAndToValues):
2088         (WebCore::SVGAnimateElement::calculateFromAndByValues):
2089         (WebCore::SVGAnimateElement::resetToBaseValue):
2090         (WebCore::SVGAnimateElement::applyResultsToTarget):
2091         (WebCore::SVGAnimateElement::calculateDistance):
2092         (WebCore::SVGAnimateElement::ensureAnimator): Pass the animation element as pointer to animator.
2093         * svg/SVGAnimateElement.h: Removed unnecessary includes. Some cleanup.
2094         (WebCore::SVGAnimateElement::fromPropertyValueType): Get property value type of 'from' property.
2095         (WebCore::SVGAnimateElement::toPropertyValueType): Get property value type of 'to' property.
2096         * svg/SVGAnimatedAngle.cpp:
2097         (WebCore::SVGAnimatedAngleAnimator::SVGAnimatedAngleAnimator): Added SVGSMILElement as new argument, removed attributeName.
2098         (WebCore::SVGAnimatedAngleAnimator::calculateFromAndToValues): Determine property value type.
2099         (WebCore::SVGAnimatedAngleAnimator::calculateFromAndByValues): Ditto.
2100         (WebCore::SVGAnimatedAngleAnimator::calculateAnimatedValue): Use new functions of SVGAnimateElement for handling of 'inherit'.
2101             And removed unnecessary arguments.
2102         (WebCore::SVGAnimatedAngleAnimator::calculateDistance): Removed animation element argument.
2103         * svg/SVGAnimatedAngle.h:
2104         * svg/SVGAnimatedColor.cpp: Added.
2105         (WebCore::SVGAnimatedColorAnimator::SVGAnimatedColorAnimator): Ditto.
2106         (WebCore::SVGAnimatedColorAnimator::constructFromString):
2107         (WebCore::SVGAnimatedColorAnimator::calculateFromAndToValues):
2108         (WebCore::SVGAnimatedColorAnimator::calculateFromAndByValues):
2109         (WebCore::SVGAnimatedColorAnimator::calculateAnimatedValue):
2110         (WebCore::SVGAnimatedColorAnimator::calculateDistance):
2111         * svg/SVGAnimatedColor.h: Added.
2112         (WebCore::SVGAnimatedColorAnimator::~SVGAnimatedColorAnimator):
2113         * svg/SVGAnimatedLength.cpp:
2114         (WebCore::SVGAnimatedLengthAnimator::SVGAnimatedLengthAnimator): Ditto.
2115         (WebCore::SVGAnimatedLengthAnimator::calculateFromAndToValues):
2116         (WebCore::SVGAnimatedLengthAnimator::calculateFromAndByValues):
2117         (WebCore::SVGAnimatedLengthAnimator::calculateAnimatedValue):
2118         (WebCore::SVGAnimatedLengthAnimator::calculateDistance):
2119         * svg/SVGAnimatedLength.h:
2120         * svg/SVGAnimatedNumber.cpp:
2121         (WebCore::SVGAnimatedNumberAnimator::SVGAnimatedNumberAnimator): Ditto.
2122         (WebCore::SVGAnimatedNumberAnimator::calculateFromAndToValues):
2123         (WebCore::SVGAnimatedNumberAnimator::calculateFromAndByValues):
2124         (WebCore::SVGAnimatedNumberAnimator::calculateAnimatedValue):
2125         (WebCore::SVGAnimatedNumberAnimator::calculateDistance):
2126         * svg/SVGAnimatedNumber.h:
2127         * svg/SVGAnimatedPointList.cpp:
2128         (WebCore::SVGAnimatedPointListAnimator::SVGAnimatedPointListAnimator): Ditto.
2129         (WebCore::SVGAnimatedPointListAnimator::calculateAnimatedValue):
2130         (WebCore::SVGAnimatedPointListAnimator::calculateDistance):
2131         * svg/SVGAnimatedPointList.h:
2132         * svg/SVGAnimatedRect.cpp:
2133         (WebCore::SVGAnimatedRectAnimator::SVGAnimatedRectAnimator): Ditto.
2134         (WebCore::SVGAnimatedRectAnimator::calculateAnimatedValue):
2135         (WebCore::SVGAnimatedRectAnimator::calculateDistance):
2136         * svg/SVGAnimatedRect.h:
2137         * svg/SVGAnimatedType.cpp: Added handling of Color values.
2138         (WebCore::SVGAnimatedType::~SVGAnimatedType):
2139         (WebCore::SVGAnimatedType::createColor):
2140         (WebCore::SVGAnimatedType::color):
2141         (WebCore::SVGAnimatedType::valueAsString):
2142         (WebCore::SVGAnimatedType::setValueAsString):
2143         * svg/SVGAnimatedType.h:
2144         * svg/SVGAnimatedTypeAnimator.h:
2145         (WebCore::SVGAnimatedTypeAnimator::SVGAnimatedTypeAnimator):
2146         * svg/SVGAnimatorFactory.h:
2147         (WebCore::SVGAnimatorFactory::create):
2148
2149 2011-06-23  Yael Aharon  <yael.aharon@nokia.com>
2150
2151         Reviewed by Andreas Kling.
2152
2153         [Qt] [WK2] Add drag and drop support
2154         https://bugs.webkit.org/show_bug.cgi?id=62838
2155
2156         Add convenience methods to allow encoding/decoding of DragData.
2157         Move the call to dragEnded() to DragClient, to make WebKit1 and WebKit2 
2158         consistent.
2159
2160         * page/qt/DragControllerQt.cpp:
2161         (WebCore::DragController::cleanupAfterSystemDrag):
2162         * platform/DragData.h:
2163         (WebCore::DragData::flags):
2164         (WebCore::DragData::DragData):
2165         (WebCore::DragData::operator =):
2166
2167 2011-06-23  Vsevolod Vlasov  <vsevik@chromium.org>
2168
2169         Reviewed by Yury Semikhatsky.
2170
2171         Web Inspector: Show "no content" message in network panel when resource does not have content available.
2172         https://bugs.webkit.org/show_bug.cgi?id=63007
2173
2174         * English.lproj/localizedStrings.js:
2175         * WebCore.gypi:
2176         * WebCore.vcproj/WebCore.vcproj:
2177         * inspector/front-end/ApplicationCacheItemsView.js:
2178         (WebInspector.ApplicationCacheItemsView):
2179         (WebInspector.ApplicationCacheItemsView.prototype._updateCallback):
2180         * inspector/front-end/CookieItemsView.js:
2181         (WebInspector.CookieItemsView):
2182         (WebInspector.CookieItemsView.prototype._updateWithCookies):
2183         * inspector/front-end/DatabaseTableView.js:
2184         (WebInspector.DatabaseTableView.prototype._queryFinished):
2185         * inspector/front-end/EmptyView.js: Added.
2186         (WebInspector.EmptyView):
2187         (WebInspector.EmptyView.prototype.show):
2188         (WebInspector.EmptyView.prototype.set text):
2189         * inspector/front-end/NetworkItemView.js:
2190         (WebInspector.NetworkItemView):
2191         (WebInspector.ResourceContentView):
2192         (WebInspector.ResourceContentView.prototype.hasContent):
2193         (WebInspector.ResourceContentView.prototype.get sourceView):
2194         (WebInspector.ResourceContentView.prototype.show):
2195         (WebInspector.ResourceContentView.prototype._ensureInnerViewShown.callback):
2196         (WebInspector.ResourceContentView.prototype._ensureInnerViewShown):
2197         (WebInspector.ResourceContentView.prototype.contentLoaded):
2198         * inspector/front-end/ResourceCookiesView.js:
2199         (WebInspector.ResourceCookiesView.prototype.show):
2200         * inspector/front-end/ResourcePreviewView.js:
2201         (WebInspector.ResourcePreviewView):
2202         (WebInspector.ResourcePreviewView.prototype.contentLoaded):
2203         (WebInspector.ResourcePreviewView.prototype._createInnerView):
2204         * inspector/front-end/ResourceResponseView.js: Added.
2205         (WebInspector.ResourceResponseView):
2206         (WebInspector.ResourceResponseView.prototype.get sourceView):
2207         (WebInspector.ResourceResponseView.prototype.contentLoaded):
2208         * inspector/front-end/ResourceTimingView.js:
2209         (WebInspector.ResourceTimingView.prototype.show):
2210         * inspector/front-end/ResourcesPanel.js:
2211         (WebInspector.StorageCategoryView):
2212         (WebInspector.StorageCategoryView.prototype.setText):
2213         * inspector/front-end/WebKit.qrc:
2214         * inspector/front-end/inspector.html:
2215
2216 2011-06-23  Balazs Kelemen  <kbalazs@webkit.org>
2217
2218         Reviewed by Adam Roben.
2219
2220         PluginView::dispatchNPEvent is deceptive
2221         https://bugs.webkit.org/show_bug.cgi?id=63243
2222
2223         Straighten the inverted logic of dispatchNPEvent
2224         and it's callers.
2225
2226         No change in behaviour so no new tests.
2227         Existing plugin tests cover this.
2228
2229         * plugins/gtk/PluginViewGtk.cpp:
2230         (WebCore::PluginView::dispatchNPEvent):
2231         (WebCore::PluginView::handleKeyboardEvent):
2232         (WebCore::PluginView::handleMouseEvent):
2233         * plugins/qt/PluginViewQt.cpp:
2234         (WebCore::PluginView::dispatchNPEvent):
2235         (WebCore::PluginView::handleKeyboardEvent):
2236         (WebCore::PluginView::handleMouseEvent):
2237         * plugins/symbian/PluginViewSymbian.cpp:
2238         (WebCore::PluginView::dispatchNPEvent):
2239         (WebCore::PluginView::handleKeyboardEvent):
2240         (WebCore::PluginView::handleMouseEvent):
2241         * plugins/win/PluginViewWin.cpp:
2242         (WebCore::PluginView::dispatchNPEvent):
2243         (WebCore::PluginView::handleKeyboardEvent):
2244         (WebCore::PluginView::handleMouseEvent):
2245
2246 2011-06-23  Tommy Widenflycht  <tommyw@google.com>
2247
2248         Reviewed by Tony Gentilcore.
2249
2250         MediaStream API: Rename Stream, GeneratedStream and StreamRecorder to the latest spec
2251         https://bugs.webkit.org/show_bug.cgi?id=63122
2252
2253         Fixing broken makefile.
2254
2255         * GNUmakefile.list.am:
2256
2257 2011-06-23  Tommy Widenflycht  <tommyw@google.com>
2258
2259         Reviewed by Tony Gentilcore.
2260
2261         MediaStream API: Rename Stream, GeneratedStream and StreamRecorder to the latest spec
2262         https://bugs.webkit.org/show_bug.cgi?id=63122
2263
2264         No new tests since no code has actually changed.
2265
2266         * CMakeLists.txt:
2267         * CodeGenerators.pri:
2268         * DerivedSources.cpp:
2269         * DerivedSources.make:
2270         * GNUmakefile.list.am:
2271         * WebCore.gypi:
2272         * WebCore.pro:
2273         * WebCore.vcproj/WebCore.vcproj:
2274         * WebCore.xcodeproj/project.pbxproj:
2275         * bindings/js/JSEventTarget.cpp:
2276         (WebCore::toJS):
2277         * bindings/v8/V8DOMWrapper.cpp:
2278         (WebCore::V8DOMWrapper::convertEventTargetToV8Object):
2279         * dom/DOMAllInOne.cpp:
2280         * dom/EventTarget.cpp:
2281         (WebCore::EventTarget::toMediaStream):
2282         (WebCore::EventTarget::toLocalMediaStream):
2283         * dom/EventTarget.h:
2284         * dom/LocalMediaStream.cpp: Renamed from Source/WebCore/dom/GeneratedStream.cpp.
2285         (WebCore::LocalMediaStream::DispatchUpdateTask::create):
2286         (WebCore::LocalMediaStream::DispatchUpdateTask::performTask):
2287         (WebCore::LocalMediaStream::DispatchUpdateTask::DispatchUpdateTask):
2288         (WebCore::LocalMediaStream::create):
2289         (WebCore::LocalMediaStream::LocalMediaStream):
2290         (WebCore::LocalMediaStream::~LocalMediaStream):
2291         (WebCore::LocalMediaStream::toLocalMediaStream):
2292         (WebCore::LocalMediaStream::detachEmbedder):
2293         (WebCore::LocalMediaStream::streamEnded):
2294         (WebCore::LocalMediaStream::audioTracks):
2295         (WebCore::LocalMediaStream::videoTracks):
2296         (WebCore::LocalMediaStream::stop):
2297         (WebCore::LocalMediaStream::onStop):
2298         * dom/LocalMediaStream.h: Renamed from Source/WebCore/dom/GeneratedStream.h.
2299         * dom/LocalMediaStream.idl: Renamed from Source/WebCore/dom/GeneratedStream.idl.
2300         * dom/MediaStream.cpp: Renamed from Source/WebCore/dom/Stream.cpp.
2301         (WebCore::MediaStream::create):
2302         (WebCore::MediaStream::MediaStream):
2303         (WebCore::MediaStream::~MediaStream):
2304         (WebCore::MediaStream::toMediaStream):
2305         (WebCore::MediaStream::streamEnded):
2306         (WebCore::MediaStream::scriptExecutionContext):
2307         (WebCore::MediaStream::eventTargetData):
2308         (WebCore::MediaStream::ensureEventTargetData):
2309         * dom/MediaStream.h: Renamed from Source/WebCore/dom/Stream.h.
2310         (WebCore::MediaStream::readyState):
2311         (WebCore::MediaStream::label):
2312         (WebCore::MediaStream::refEventTarget):
2313         (WebCore::MediaStream::derefEventTarget):
2314         * dom/MediaStream.idl: Renamed from Source/WebCore/dom/Stream.idl.
2315         * dom/MediaStreamContainer.h: Renamed from Source/WebCore/dom/StreamContainer.h.
2316         (WebCore::MediaStreamContainer::create):
2317         (WebCore::MediaStreamContainer::~MediaStreamContainer):
2318         (WebCore::MediaStreamContainer::length):
2319         (WebCore::MediaStreamContainer::item):
2320         (WebCore::MediaStreamContainer::add):
2321         (WebCore::MediaStreamContainer::remove):
2322         (WebCore::MediaStreamContainer::contains):
2323         (WebCore::MediaStreamContainer::get):
2324         (WebCore::MediaStreamContainer::MediaStreamContainer):
2325         * dom/MediaStreamList.cpp: Renamed from Source/WebCore/dom/StreamList.cpp.
2326         (WebCore::MediaStreamList::create):
2327         (WebCore::MediaStreamList::MediaStreamList):
2328         (WebCore::MediaStreamList::~MediaStreamList):
2329         (WebCore::MediaStreamList::length):
2330         (WebCore::MediaStreamList::item):
2331         * dom/MediaStreamList.h: Renamed from Source/WebCore/dom/StreamList.h.
2332         * dom/MediaStreamList.idl: Renamed from Source/WebCore/dom/StreamList.idl.
2333         * dom/StreamEvent.cpp:
2334         (WebCore::StreamEvent::create):
2335         (WebCore::StreamEvent::StreamEvent):
2336         (WebCore::StreamEvent::initStreamEvent):
2337         (WebCore::StreamEvent::stream):
2338         * dom/StreamEvent.h:
2339         (WebCore::StreamEvent::isMediaStreamEvent):
2340         * dom/StreamEvent.idl:
2341         * page/MediaStreamFrameController.cpp:
2342         (WebCore::MediaStreamFrameController::unregister):
2343         (WebCore::MediaStreamFrameController::getStreamFromLabel):
2344         (WebCore::MediaStreamFrameController::stopGeneratedStream):
2345         (WebCore::MediaStreamFrameController::streamGenerated):
2346         (WebCore::MediaStreamFrameController::audioTrackFailed):
2347         (WebCore::MediaStreamFrameController::videoTrackFailed):
2348         * page/MediaStreamFrameController.h:
2349         (WebCore::MediaStreamFrameController::ClientBase::isMediaStream):
2350         (WebCore::MediaStreamFrameController::ClientBase::isLocalMediaStream):
2351         (WebCore::MediaStreamFrameController::MediaStreamClient::MediaStreamClient):
2352         (WebCore::MediaStreamFrameController::MediaStreamClient::~MediaStreamClient):
2353         (WebCore::MediaStreamFrameController::MediaStreamClient::isMediaStream):
2354         (WebCore::MediaStreamFrameController::MediaStreamClient::isLocalMediaStream):
2355         * page/NavigatorUserMediaSuccessCallback.h:
2356         * page/NavigatorUserMediaSuccessCallback.idl:
2357
2358 2011-06-23  Mikhail Naganov  <mnaganov@chromium.org>
2359
2360         Reviewed by Yury Semikhatsky.
2361
2362         Web Inspector: [Chromium] Fix showing dominator leaf nodes after r89457
2363         https://bugs.webkit.org/show_bug.cgi?id=63250
2364
2365         * inspector/front-end/DetailedHeapshotView.js:
2366         * inspector/front-end/HeapSnapshot.js:
2367         (WebInspector.HeapSnapshotFilteredOrderedIterator.prototype.get isEmpty):
2368
2369 2011-06-23  Vsevolod Vlasov  <vsevik@chromium.org>
2370
2371         Reviewed by Yury Semikhatsky.
2372
2373         Web Inspector: HTML preview in network panel should take 100% of resource view height.
2374         https://bugs.webkit.org/show_bug.cgi?id=63167
2375
2376         * inspector/front-end/inspector.css:
2377         (.resource-view.html iframe):
2378
2379 2011-06-23  Zoltan Herczeg  <zherczeg@inf.u-szeged.hu>
2380
2381         Reviewed by Pavel Feldman.
2382
2383         Inspector may close at the start of the next inspector test in DRT
2384         https://bugs.webkit.org/show_bug.cgi?id=60881
2385
2386         Add a new function to the inspector, which tests whether the
2387         dispatch queue is empty.
2388
2389         * inspector/front-end/inspector.js:
2390         (WebInspector.dispatchQueueIsEmpty):
2391
2392 2011-06-23  Jeffrey Pfau  <jpfau@apple.com>
2393
2394         Reviewed by Nikolas Zimmermann.
2395
2396         Incorrectly placed SVG gradients can cause crashes when referenced
2397         https://bugs.webkit.org/show_bug.cgi?id=62914
2398
2399         Added a check for gradient rendering contexts. If the contexts can't be found, the gradient must be in an invalid location, so we use the fallback color instead.
2400
2401         Tests: svg/custom/invalid-gradient-with-xlink.svg
2402                svg/custom/xlink-to-invalid-gradient.svg
2403
2404         * rendering/svg/RenderSVGResourceGradient.cpp:
2405         (WebCore::RenderSVGResourceGradient::applyResource):
2406         * rendering/svg/RenderSVGResourceGradient.h:
2407         * rendering/svg/RenderSVGResourceLinearGradient.cpp:
2408         (WebCore::RenderSVGResourceLinearGradient::collectGradientAttributes):
2409         * rendering/svg/RenderSVGResourceLinearGradient.h:
2410         * rendering/svg/RenderSVGResourceRadialGradient.cpp:
2411         (WebCore::RenderSVGResourceRadialGradient::collectGradientAttributes):
2412         * rendering/svg/RenderSVGResourceRadialGradient.h:
2413         * svg/SVGLinearGradientElement.cpp:
2414         (WebCore::SVGLinearGradientElement::collectGradientAttributes):
2415         * svg/SVGLinearGradientElement.h:
2416         * svg/SVGRadialGradientElement.cpp:
2417         (WebCore::SVGRadialGradientElement::collectGradientAttributes):
2418         * svg/SVGRadialGradientElement.h:
2419
2420 2011-06-23  Dmitriy Vyukov  <dvyukov@google.com>
2421
2422         Reviewed by David Levin.
2423
2424         Fix incorrect usage of a condition variable.
2425         https://bugs.webkit.org/show_bug.cgi?id=63127
2426
2427         No new tests. This does not affect existing
2428         functionality.
2429
2430         * storage/DatabaseTask.cpp:
2431         (WebCore::DatabaseTaskSynchronizer::waitForTaskCompletion):
2432
2433 2011-06-23  David Grogan  <dgrogan@chromium.org>
2434
2435         Reviewed by Eric Seidel.
2436
2437         IndexedDB: add detail to an ASSERT error message
2438         https://bugs.webkit.org/show_bug.cgi?id=60407
2439
2440         No new tests, this is just a debug ASSERT.
2441
2442         * storage/IDBRequest.cpp:
2443         (WebCore::IDBRequest::dispatchEvent):
2444
2445 2011-06-22  Dirk Schulze  <krit@webkit.org>
2446
2447         Reviewed by Rob Buis.
2448
2449         Convert SVGPointList to SVGAnimatorFactory concept
2450         https://bugs.webkit.org/show_bug.cgi?id=63171
2451
2452         Follow up of "SVGAnimation should use direct unit animation for SVGLength": https://bugs.webkit.org/show_bug.cgi?id=61368
2453         This patch continues the conversion to the new concept of SVGAnimatorFactory with SVGPointList.
2454
2455         Added support for from-by animations of SVGPointLists.
2456
2457         Tests: svg/animations/svgpointlist-animation-1.html
2458                svg/animations/svgpointlist-animation-2.html
2459
2460         * CMakeLists.txt: Added new files to build system.
2461         * GNUmakefile.list.am: Ditto.
2462         * WebCore.gypi: Ditto.
2463         * WebCore.pro: Ditto.
2464         * WebCore.vcproj/WebCore.vcproj: Ditto.
2465         * WebCore.xcodeproj/project.pbxproj: Ditto.
2466         * svg/SVGAllInOne.cpp: Added SVGAnimatedPointList.cpp
2467         * svg/SVGAnimateElement.cpp:
2468         (WebCore::SVGAnimateElement::calculateAnimatedValue):
2469         (WebCore::SVGAnimateElement::calculateFromAndToValues):
2470         (WebCore::SVGAnimateElement::calculateFromAndByValues):
2471         (WebCore::SVGAnimateElement::resetToBaseValue):
2472         (WebCore::SVGAnimateElement::applyResultsToTarget):
2473         (WebCore::SVGAnimateElement::calculateDistance):
2474         * svg/SVGAnimateElement.h:
2475         * svg/SVGAnimatedPointList.cpp: Added.
2476         (WebCore::SVGAnimatedPointListAnimator::SVGAnimatedPointListAnimator):
2477         (WebCore::SVGAnimatedPointListAnimator::constructFromString):
2478         (WebCore::SVGAnimatedPointListAnimator::calculateFromAndToValues):
2479         (WebCore::SVGAnimatedPointListAnimator::calculateFromAndByValues):
2480         (WebCore::SVGAnimatedPointListAnimator::calculateAnimatedValue):
2481         (WebCore::SVGAnimatedPointListAnimator::calculateDistance):
2482         * svg/SVGAnimatedPointList.h: Added.
2483         (WebCore::SVGAnimatedPointListAnimator::~SVGAnimatedPointListAnimator):
2484         * svg/SVGAnimatedType.cpp:
2485         (WebCore::SVGAnimatedType::~SVGAnimatedType):
2486         (WebCore::SVGAnimatedType::createPointList):
2487         (WebCore::SVGAnimatedType::pointList):
2488         (WebCore::SVGAnimatedType::valueAsString):
2489         (WebCore::SVGAnimatedType::setValueAsString):
2490         * svg/SVGAnimatedType.h:
2491         * svg/SVGAnimatorFactory.h:
2492         (WebCore::SVGAnimatorFactory::create):
2493
2494 2011-06-22  Dimitri Glazkov  <dglazkov@chromium.org>
2495
2496         Reviewed by Kent Tamura.
2497
2498         Move file-choosing and icon-loading management to FileInputType
2499         https://bugs.webkit.org/show_bug.cgi?id=62069
2500
2501         1) Moved the duties of FileChooserClient and FileIconLoaderClient from
2502         RenderFileUploadControl to FileInputType, along with all of the
2503         supporting functions.
2504
2505         2) Moved Icon ownership to FileInputType and exposed accessor on
2506         HTMInputElement to allow RenderFileUploadControl to query current icon.
2507
2508         As a result, RenderFileUploadControl is now completely stateless, which is
2509         neat and clean.
2510
2511         Refactoring, covered by existing tests.
2512
2513         * html/FileInputType.cpp:
2514         (WebCore::FileInputType::handleDOMActivateEvent): Moved logic here from RenderFileUploadControl.
2515         (WebCore::FileInputType::requestIcon): Ditto.
2516         (WebCore::FileInputType::filesChosen): Ditto.
2517         (WebCore::FileInputType::receiveDropForDirectoryUpload): Ditto.
2518         (WebCore::FileInputType::updateRendering): Ditto.
2519         (WebCore::FileInputType::chrome): Ditto.
2520         (WebCore::FileInputType::receiveDroppedFiles): Ditto.
2521         (WebCore::FileInputType::icon): Added.
2522         * html/FileInputType.h:
2523         * html/HTMLInputElement.cpp:
2524         (WebCore::HTMLInputElement::setValueFromRenderer): Updated comment.
2525         (WebCore::HTMLInputElement::receiveDroppedFiles): Added to replace setFileListFromRenderer.
2526         (WebCore::HTMLInputElement::icon): Added.
2527         * html/HTMLInputElement.h:
2528         * html/InputType.cpp:
2529         (WebCore::InputType::receiveDroppedFiles): Added.
2530         (WebCore::InputType::icon): Added.
2531         * html/InputType.h:
2532         * page/DragController.cpp:
2533         (WebCore::DragController::concludeEditDrag): Changed to use HTMLInputElement. Ahh, nice and clean!
2534         * rendering/RenderFileUploadControl.cpp:
2535         (WebCore::RenderFileUploadControl::RenderFileUploadControl): Removed code that is no longer necessary.
2536         (WebCore::RenderFileUploadControl::updateFromElement): Ditto.
2537         (WebCore::RenderFileUploadControl::maxFilenameWidth): Changed to use HTMLInputElement icon accessor.
2538         (WebCore::RenderFileUploadControl::paintObject): Ditto.
2539         * rendering/RenderFileUploadControl.h:
2540
2541 2011-06-22  Pratik Solanki  <psolanki@apple.com>
2542
2543         Reviewed by Darin Adler.
2544
2545         Add NSError wrapper functions in ResourceError when USE(CFNETWORK) is enabled
2546         https://bugs.webkit.org/show_bug.cgi?id=63155
2547
2548         Add wrapper functions to ResourceError when building with USE(CFNETWORK). We need to create
2549         a new NSError in ResourceError::nsError() since Safari has category methods on NSError and
2550         passing a CFErrorRef back does not work even though CFErrorRef/NSErrror are toll-free
2551         bridged.
2552
2553         No tests because no change in functionality.
2554
2555         * WebCore.exp.in:
2556         * platform/network/cf/ResourceError.h:
2557         * platform/network/mac/ResourceErrorMac.mm:
2558         (WebCore::ResourceError::ResourceError):
2559         (WebCore::ResourceError::nsError):
2560         (WebCore::ResourceError::operator NSError *):
2561
2562 2011-06-22  Dominic Cooney  <dominicc@chromium.org>
2563
2564         Reviewed by Mark Rowe.
2565
2566         Add window.internals to WebKit2's WebKitTestRunner.
2567         https://bugs.webkit.org/show_bug.cgi?id=61073
2568
2569         * Configurations/WebCoreTestSupport.xcconfig:
2570         * WebCore.xcodeproj/project.pbxproj:
2571
2572 2011-06-22  Dimitri Glazkov  <dglazkov@chromium.org>
2573
2574         Reviewed by Kent Tamura.
2575
2576         Convert FileIconLoaderClient to "smart client" pattern, just like FileChooserClient.
2577         https://bugs.webkit.org/show_bug.cgi?id=63224
2578
2579         Refactoring, covered by existing tests.
2580
2581         * platform/FileIconLoader.cpp:
2582         (WebCore::FileIconLoaderClient::~FileIconLoaderClient): Changed to discard loader.
2583         (WebCore::FileIconLoaderClient::newFileIconLoader): Added.
2584         (WebCore::FileIconLoaderClient::discardLoader): Added.
2585         * platform/FileIconLoader.h: Updated defs.
2586         * rendering/RenderFileUploadControl.cpp:
2587         (WebCore::RenderFileUploadControl::RenderFileUploadControl): Removed initialization of icon loader.
2588         (WebCore::RenderFileUploadControl::~RenderFileUploadControl): Remove discarding of loader.
2589         (WebCore::RenderFileUploadControl::requestIcon): Changed to use newFileIconLoader.
2590         * rendering/RenderFileUploadControl.h: Updated defs.
2591
2592 2011-06-22  Yael Aharon  <yael.aharon@nokia.com>
2593
2594         Another unreviewed build fix after r89472.
2595
2596         No new tests, just a build fix.
2597
2598         * rendering/svg/SVGResources.cpp:
2599
2600 2011-06-22  Yael Aharon  <yael.aharon@nokia.com>
2601
2602         Unreviewed build fix after r89472.
2603
2604         No new tests, just a build fix.
2605
2606         * rendering/InlineBox.cpp:
2607         * rendering/RenderCounter.cpp:
2608
2609 2011-06-22  Dimitri Glazkov  <dglazkov@chromium.org>
2610
2611         Reviewed by Kent Tamura.
2612
2613         Add a helper function to FileList to retrieve a list of filenames.
2614         https://bugs.webkit.org/show_bug.cgi?id=63222
2615
2616         Refactoring, covered by existing tests.
2617
2618         * fileapi/FileList.cpp:
2619         (WebCore::FileList::filenames): Added.
2620         * fileapi/FileList.h:
2621         * rendering/RenderFileUploadControl.cpp:
2622         (WebCore::RenderFileUploadControl::RenderFileUploadControl): Changed to use newly added helper.
2623         (WebCore::RenderFileUploadControl::click): Ditto.
2624         (WebCore::RenderFileUploadControl::fileTextValue): Ditto.
2625
2626 2011-06-22  Sam Weinig  <sam@webkit.org>
2627
2628         Reviewed by Adam Barth.
2629
2630         Lower HTML parser DOM depth limit to 2048
2631         https://bugs.webkit.org/show_bug.cgi?id=63219
2632
2633         Lower the default depth limit from 4096 to 2048. There isn't a good
2634         reason to have such pathologically nested content, and by-and-large,
2635         the rendering code is not setup to support it that well. Adding this
2636         aggressive limit now will allow us to see if anything breaks in the
2637         nightlies.
2638
2639         * page/Settings.h:
2640
2641 2011-06-22  Julien Chaffraix  <jchaffraix@webkit.org>
2642
2643         Reviewed by Dimitri Glazkov.
2644
2645         Tighten type usage in the Shadow tree code
2646         https://bugs.webkit.org/show_bug.cgi?id=63210
2647
2648         Refactoring only, no new test required.
2649
2650         * dom/Document.cpp:
2651         (WebCore::Document::buildAccessKeyMap):
2652         * dom/Document.h:
2653         Changed the argument of buildAccessKeyMap to TreeScope.
2654
2655         * dom/Element.cpp:
2656         (WebCore::Element::attach):
2657         (WebCore::Element::removeShadowRoot):
2658         * html/ColorInputType.cpp:
2659         (WebCore::ColorInputType::shadowColorSwatch):
2660         * html/HTMLKeygenElement.cpp:
2661         (WebCore::HTMLKeygenElement::shadowSelect):
2662         * html/shadow/SliderThumbElement.cpp:
2663         (WebCore::sliderThumbElementOf):
2664         Use ShadowRoot for the previous call sites as this is what is
2665         returned by shadowRoot().
2666
2667         * dom/Node.cpp:
2668         (WebCore::traverseTreeAndMark): Renamed the parameter here as it is not
2669         expected to be a shadow object. Just the rootNode of our traversal.
2670
2671         * dom/ShadowRoot.h: Made attach() public as it is public in ContainerNode
2672         and we would do some casting to avoid the private attribute in ShadowRoot.
2673
2674 2011-06-22  Joseph Pecoraro  <joepeck@webkit.org>
2675
2676         Reviewed by Darin Adler.
2677
2678         Remove comment about pages with frames not being page-cachable
2679         https://bugs.webkit.org/show_bug.cgi?id=63207
2680
2681         This comment was out of date. Caching pages with Frames in
2682         the PageCache has worked since 2009:
2683         <http://webkit.org/b/13631> Page Cache should support pages with frames
2684
2685         * history/PageCache.cpp:
2686         (WebCore::PageCache::canCache):
2687
2688 2011-06-22  Yael Aharon  <yael.aharon@nokia.com>
2689
2690         Reviewed by Andreas Kling.
2691
2692         [Qt] Add a build flag for building with libxml2 and libxslt.
2693         https://bugs.webkit.org/show_bug.cgi?id=63113
2694
2695         No new tests. If this new flag was set by default, we could unskip
2696         existing xmlviewer tests.
2697
2698         * CodeGenerators.pri:
2699         * WebCore.pri:
2700         * WebCore.pro:
2701         * features.pri:
2702
2703 2011-06-22  Ryosuke Niwa  <rniwa@webkit.org>
2704
2705         Yet another build fix after r89472.
2706
2707         * html/parser/HTMLFormattingElementList.cpp:
2708
2709 2011-06-22  Ryosuke Niwa  <rniwa@webkit.org>
2710
2711         Another build fix after r89472.
2712
2713         * dom/DocumentMarkerController.cpp:
2714
2715 2011-06-22  Ryosuke Niwa  <rniwa@webkit.org>
2716
2717         Build fix after r89472.
2718
2719         * css/CSSStyleDeclaration.cpp:
2720
2721 2011-06-22  Mark Pilgrim  <pilgrim@chromium.org>
2722
2723         Reviewed by Adam Barth.
2724
2725         IndexedDB open (database) should NOT throw if name is null
2726         https://bugs.webkit.org/show_bug.cgi?id=63110
2727
2728         * storage/IDBFactory.idl: remove ConvertNullToNullString flag on
2729         name argument, let IDL code generator stringify null value to "null"
2730
2731 2011-06-22  Ryosuke Niwa  <rniwa@webkit.org>
2732
2733         Reviewed by Darin Adler.
2734
2735         Add a Position constructor that takes (Text*, unsigned offset)
2736         https://bugs.webkit.org/show_bug.cgi?id=63181
2737
2738         Added Position::Position(PassRefPtr<Text*>, unsigned offset) and deployed in a couple of places
2739         by replacing the calls to the old constructor.
2740
2741         * dom/Position.cpp:
2742         (WebCore::Position::Position): Added.
2743         * dom/Position.h:
2744         * editing/CompositeEditCommand.cpp:
2745         (WebCore::CompositeEditCommand::replaceSelectedTextInNode): Calls new constructor; extracted
2746         from InsertTextCommand::performTrivialReplace and ReplaceSelectionCommand::performTrivialReplace.
2747         (WebCore::CompositeEditCommand::rebalanceWhitespaceOnTextSubstring): Calls new constructor
2748         * editing/CompositeEditCommand.h:
2749         * editing/InsertTextCommand.cpp:
2750         (WebCore::InsertTextCommand::performTrivialReplace): Calls replaceSelectedTextInNode.
2751         (WebCore::InsertTextCommand::input): Calls new constructor.
2752         (WebCore::InsertTextCommand::insertTab): Use RefPtr instead of a raw pointer.
2753         * editing/ReplaceSelectionCommand.cpp:
2754         (WebCore::ReplaceSelectionCommand::performTrivialReplace): Calls replaceSelectedTextInNode.
2755         * editing/visible_units.cpp:
2756         (WebCore::startPositionForLine): Calls new constructor.
2757         * rendering/RenderTextControl.cpp:
2758         (WebCore::RenderTextControl::visiblePositionForIndex): Calls new constructor; calls endPosition
2759         on Range instead of avoid manually constructing a VisiblePosition out of endContainer and endOffset.
2760
2761 2011-06-22  Adam Barth  <abarth@webkit.org>
2762
2763         Reviewed by Darin Fisher.
2764
2765         [Chromium] Add WebDocument APIs for the functions moving from WebFrame
2766         https://bugs.webkit.org/show_bug.cgi?id=62831
2767
2768         * dom/Document.cpp:
2769         (WebCore::Document::openSearchDescriptionURL):
2770             - This function exists to service a Chromium WebKit API, but it's
2771               generally purpose and might be useful to other ports.  The
2772               algorithm has some strange early exits, which I've marked with
2773               FIXME comments.
2774         * dom/Document.h:
2775
2776 2011-06-22  Nate Chapin  <japhet@chromium.org>
2777
2778         Reviewed by Adam Barth.
2779
2780         Don't let all subresources keep isLoadingInAPISense() from
2781         returning false, only requests that affect
2782         CachedResourceRequest::requestCount().
2783
2784         Also, add a callback to Internals to determine whether
2785         a resource has been preloaded.
2786
2787         https://bugs.webkit.org/show_bug.cgi?id=62066
2788
2789         * WebCore.exp.in:
2790         * dom/Document.cpp: Add m_loadEventFinished.
2791         * dom/Document.h:
2792         * loader/DocumentLoader.cpp:
2793         (WebCore::DocumentLoader::isLoadingInAPISense):
2794         * loader/cache/CachedResourceLoader.cpp:
2795         (WebCore::CachedResourceLoader::isPreloaded):
2796         * loader/cache/CachedResourceLoader.h:
2797         * testing/Internals.cpp:
2798         (WebCore::Internals::isPreloaded):
2799         * testing/Internals.h:
2800         * testing/Internals.idl:
2801
2802 2011-06-22  Chris Rogers  <crogers@google.com>
2803
2804         Reviewed by David Levin.
2805
2806         Use create() method for AsyncAudioDecoder::DecodingTask
2807         https://bugs.webkit.org/show_bug.cgi?id=63198
2808
2809         No new tests.  This doesn't change any JS API.
2810
2811         * webaudio/AsyncAudioDecoder.cpp:
2812         (WebCore::AsyncAudioDecoder::decodeAsync):
2813         (WebCore::AsyncAudioDecoder::DecodingTask::create):
2814         * webaudio/AsyncAudioDecoder.h:
2815
2816 2011-06-22  Sheriff Bot  <webkit.review.bot@gmail.com>
2817
2818         Unreviewed, rolling out r89489.
2819         http://trac.webkit.org/changeset/89489
2820         https://bugs.webkit.org/show_bug.cgi?id=63203
2821
2822         Broke chromium mac build on build.webkit.org (Requested by
2823         abarth on #webkit).
2824
2825         * WebCore.gyp/WebCore.gyp:
2826         * loader/cache/CachedFont.cpp:
2827         * platform/chromium/DragImageRef.h:
2828         * platform/graphics/FloatPoint.h:
2829         * platform/graphics/FloatRect.h:
2830         * platform/graphics/FloatSize.h:
2831         * platform/graphics/FontPlatformData.h:
2832         (WebCore::FontPlatformData::hash):
2833         * platform/graphics/GlyphBuffer.h:
2834         (WebCore::GlyphBuffer::advanceAt):
2835         (WebCore::GlyphBuffer::add):
2836         (WebCore::GlyphBuffer::expandLastAdvance):
2837         * platform/graphics/IntPoint.h:
2838         * platform/graphics/IntRect.h:
2839         * platform/graphics/IntSize.h:
2840         * platform/graphics/SimpleFontData.h:
2841         * platform/graphics/cg/FloatPointCG.cpp:
2842         * platform/graphics/cg/FloatRectCG.cpp:
2843         * platform/graphics/cg/FloatSizeCG.cpp:
2844         * platform/graphics/cg/IntPointCG.cpp:
2845         * platform/graphics/cg/IntRectCG.cpp:
2846         * platform/graphics/cg/IntSizeCG.cpp:
2847         * platform/graphics/mac/FontCustomPlatformData.cpp:
2848         (WebCore::FontCustomPlatformData::~FontCustomPlatformData):
2849         (WebCore::createFontCustomPlatformData):
2850         * platform/graphics/mac/FontCustomPlatformData.h:
2851         (WebCore::FontCustomPlatformData::FontCustomPlatformData):
2852
2853 2011-06-22  Luke Macpherson   <macpherson@chromium.org>
2854
2855         Reviewed by James Robinson.
2856
2857         Remove comment that snuck in via copy & paste.
2858         https://bugs.webkit.org/show_bug.cgi?id=63177
2859
2860         No new tests / no code changes.
2861
2862         * css/CSSPrimitiveValueMappings.h:
2863         (WebCore::CSSPrimitiveValue::operator short):
2864         Removed incorrect comment.
2865
2866 2011-06-22  Annie Sullivan  <sullivan@chromium.org>
2867
2868         Reviewed by Ryosuke Niwa.
2869
2870         REGRESSION: Hitting enter in the middle of this span causes the cursor to go to the end of the span
2871         https://bugs.webkit.org/show_bug.cgi?id=61594
2872
2873         When the tree is split at the cursor in InsertParagraphSeparatorCommand, it is possible for the position
2874         split at to be at the end of a text node. The code assumes the position is at the start of the node, so
2875         pass the correct node into splitTreeToNode() in that case.
2876
2877         Tests: editing/inserting/return-key-before-br-in-span.html
2878                editing/inserting/return-key-middle-of-span.html
2879
2880         * editing/InsertParagraphSeparatorCommand.cpp:
2881         (WebCore::InsertParagraphSeparatorCommand::doApply):
2882
2883 2011-06-22  Rob Buis  <rbuis@rim.com>
2884
2885         Reviewed by Nikolas Zimmermann.
2886
2887         SVG1.1SE test with pointer-events and invalid gradient fill fails
2888         https://bugs.webkit.org/show_bug.cgi?id=63109
2889
2890         Properly detect fill/stroke properties of type SVG_PAINTTYPE_URI_NONE, store it in SVGPaint
2891         and don't apply the paint if the uri lookup fails.
2892
2893         Tests: svg/W3C-SVG-1.1-SE/interact-pointer-03-t.svg
2894                svg/custom/pointer-events-invalid-fill.svg
2895
2896         * css/SVGCSSParser.cpp:
2897         (WebCore::CSSParser::parseSVGValue):
2898         * rendering/svg/RenderSVGResource.cpp:
2899         (WebCore::requestPaintingResource):
2900         * svg/SVGPaint.h:
2901         (WebCore::SVGPaint::createURIAndNone):
2902
2903 2011-06-22  Cary Clark  <caryclark@google.com>
2904
2905         Reviewed by Darin Fisher.
2906
2907         Use Skia if Skia on Mac Chrome is enabled
2908         https://bugs.webkit.org/show_bug.cgi?id=62999
2909
2910         No new tests. This does not affect existing
2911         functionality.
2912
2913         * WebCore.gyp/WebCore.gyp:
2914         Include Skia and related files and exclude CG
2915         and related files when building Chromium for Skia
2916         on the Mac.
2917
2918         * loader/cache/CachedFont.cpp:
2919         Rename CHROME to CHROMIUM.
2920
2921         * platform/chromium/DragImageRef.h:
2922         * platform/graphics/FloatPoint.h:
2923         * platform/graphics/FloatRect.h:
2924         * platform/graphics/FloatSize.h:
2925         * platform/graphics/FontPlatformData.h:
2926         (WebCore::FontPlatformData::hash):
2927         * platform/graphics/GlyphBuffer.h:
2928         (WebCore::GlyphBuffer::advanceAt):
2929         (WebCore::GlyphBuffer::add):
2930         (WebCore::GlyphBuffer::expandLastAdvance):
2931         * platform/graphics/IntPoint.h:
2932         * platform/graphics/IntRect.h:
2933         * platform/graphics/IntSize.h:
2934         * platform/graphics/SimpleFontData.h:
2935         * platform/graphics/cg/FloatPointCG.cpp:
2936         * platform/graphics/cg/FloatRectCG.cpp:
2937         * platform/graphics/cg/FloatSizeCG.cpp:
2938         * platform/graphics/cg/IntPointCG.cpp:
2939         * platform/graphics/cg/IntRectCG.cpp:
2940         * platform/graphics/cg/IntSizeCG.cpp:
2941         * platform/graphics/mac/FontCustomPlatformData.cpp:
2942         (WebCore::FontCustomPlatformData::~FontCustomPlatformData):
2943         (WebCore::createFontCustomPlatformData):
2944         * platform/graphics/mac/FontCustomPlatformData.h:
2945         (WebCore::FontCustomPlatformData::FontCustomPlatformData):
2946         Ditto.
2947
2948 2011-06-22  Mark Pilgrim  <pilgrim@chromium.org>
2949
2950         Reviewed by Adam Barth.
2951
2952         IndexedDB createIndex should NOT throw if name arg is null
2953         https://bugs.webkit.org/show_bug.cgi?id=63114
2954
2955         * storage/IDBObjectStore.idl: remove ConvertNullToNullString flag
2956         so null values will be stringified as "null", as per WebIDL spec.
2957
2958 2011-06-22  Chris Rogers  <crogers@google.com>
2959
2960         Reviewed by Kenneth Russell.
2961
2962         AudioContext needs non-blocking call to create AudioBuffer from audio file data
2963         https://bugs.webkit.org/show_bug.cgi?id=61947
2964
2965         No new tests since audio API is not yet implemented.
2966
2967         * DerivedSources.make:
2968         * WebCore.gypi:
2969         * WebCore.xcodeproj/project.pbxproj:
2970         * webaudio/AsyncAudioDecoder.cpp: Added.
2971         (WebCore::AsyncAudioDecoder::AsyncAudioDecoder):
2972         (WebCore::AsyncAudioDecoder::~AsyncAudioDecoder):
2973         (WebCore::AsyncAudioDecoder::decodeAsync):
2974         (WebCore::AsyncAudioDecoder::threadEntry):
2975         (WebCore::AsyncAudioDecoder::runLoop):
2976         (WebCore::AsyncAudioDecoder::DecodingTask::DecodingTask):
2977         (WebCore::AsyncAudioDecoder::DecodingTask::decode):
2978         (WebCore::AsyncAudioDecoder::DecodingTask::notifyCompleteDispatch):
2979         (WebCore::AsyncAudioDecoder::DecodingTask::notifyComplete):
2980         * webaudio/AsyncAudioDecoder.h: Added.
2981         (WebCore::AsyncAudioDecoder::DecodingTask::audioData):
2982         (WebCore::AsyncAudioDecoder::DecodingTask::sampleRate):
2983         (WebCore::AsyncAudioDecoder::DecodingTask::successCallback):
2984         (WebCore::AsyncAudioDecoder::DecodingTask::errorCallback):
2985         (WebCore::AsyncAudioDecoder::DecodingTask::audioBuffer):
2986         * webaudio/AudioBufferCallback.h: Added.
2987         (WebCore::AudioBufferCallback::~AudioBufferCallback):
2988         * webaudio/AudioBufferCallback.idl: Added.
2989         * webaudio/AudioContext.cpp:
2990         (WebCore::AudioContext::decodeAudioData):
2991         * webaudio/AudioContext.h:
2992         * webaudio/AudioContext.idl:
2993
2994 2011-06-22  Beth Dakin  <bdakin@apple.com>
2995
2996         Reviewed by Simon Fraser.
2997
2998         https://bugs.webkit.org/show_bug.cgi?id=63174
2999         Don't draw the borders as one path unless there really are 4 borders
3000         -and corresponding-
3001         <rdar://problem/9457997>
3002
3003         If any of the border edges have no width, then allEdgesVisible should be set to 
3004         false since borders without width will not be visible.
3005         * rendering/RenderBoxModelObject.cpp:
3006         (WebCore::RenderBoxModelObject::paintBorder):
3007
3008 2011-06-22  Matthew Delaney  <mdelaney@apple.com>
3009
3010         Reviewed by Oliver Hunt.
3011
3012         Canvas in layer obscures overlapping span
3013         https://bugs.webkit.org/show_bug.cgi?id=63161
3014
3015         Test: compositing/layer-creation/spanOverlapsCanvas.html
3016
3017         * rendering/RenderLayer.cpp: Added checks for canvas to be layered properly.
3018         (WebCore::RenderLayer::shouldBeNormalFlowOnly):
3019         (WebCore::RenderLayer::isSelfPaintingLayer):
3020
3021 2011-06-22  Chris Rogers  <crogers@google.com>
3022
3023         Reviewed by Kenneth Russell.
3024
3025         AudioContext noteGrainOn() method should not apply explicit windowing
3026         https://bugs.webkit.org/show_bug.cgi?id=63005
3027
3028         No new tests since audio API is not yet implemented.
3029
3030         * webaudio/AudioBufferSourceNode.cpp:
3031         (WebCore::AudioBufferSourceNode::readFromBuffer):
3032         * webaudio/AudioBufferSourceNode.h:
3033
3034 2011-06-22  Kentaro Hara  <haraken@google.com>
3035
3036         Reviewed by Tony Chang.
3037
3038         Check |keypath| argument of createObjectStore(). Remove storage/indexeddb/keypath-as-array.html.
3039         https://bugs.webkit.org/show_bug.cgi?id=63054
3040
3041         At the head of createObjectStore(), we parse |keypath| argument and throw an exception
3042         if the |keypath| is invalid. With this parsing, we remove keypath-as-array.html because
3043         the current keypath parser does not support an array of keypath and (more importantly)
3044         the current implementation of ObjectStore does not support multiple keypaths.
3045         We added keypath-basics.html that demonstrates that we do not support an array of keypaths.
3046
3047         Tests: storage/indexeddb/keypath-basics.html
3048
3049         * storage/IDBDatabase.cpp:
3050         (WebCore::IDBDatabase::createObjectStore):
3051         * storage/IDBKeyPath.cpp:
3052         (WebCore::IDBIsValidKeyPath):
3053         * storage/IDBKeyPath.h:
3054
3055 2011-06-22  Young Han Lee  <joybro@company100.net>
3056
3057         Reviewed by Simon Fraser.
3058
3059         animation-timing-function property with a list uses first item for all animations
3060         https://bugs.webkit.org/show_bug.cgi?id=60303
3061
3062         When an element has multiple animations that have different timingFunctions,
3063         the progress of each animation should be calculated using its respective timingFunction.
3064         But at this point, the timingFunction of the first animation is only used for the
3065         calculation, regardless of how many animations the element has.
3066
3067         The code for getting a timingFunction is changed by this patch
3068         so that the timingFunction of the correct animation searched by its name will be used.
3069
3070         Test: animations/multiple-animations-timing-function.html
3071
3072         * page/animation/KeyframeAnimation.cpp:
3073         (WebCore::getAnimationFromStyleByName):
3074         (WebCore::KeyframeAnimation::fetchIntervalEndpointsForProperty):
3075
3076 2011-06-22  Sheriff Bot  <webkit.review.bot@gmail.com>
3077
3078         Unreviewed, rolling out r89407, r89409, r89410, and r89411.
3079         http://trac.webkit.org/changeset/89407
3080         http://trac.webkit.org/changeset/89409
3081         http://trac.webkit.org/changeset/89410
3082         http://trac.webkit.org/changeset/89411
3083         https://bugs.webkit.org/show_bug.cgi?id=63168
3084
3085         Broke Chromium tests for Forms and Autofill (Requested by
3086         dimich on #webkit).
3087
3088         * css/html.css:
3089         (input[type="search"]::-webkit-search-cancel-button):
3090         (input[type="search"]::-webkit-search-decoration):
3091         (input[type="search"]::-webkit-search-results-decoration):
3092         (input[type="search"]::-webkit-search-results-button):
3093         (input::-webkit-inner-spin-button):
3094         (input::-webkit-input-speech-button):
3095         * html/HTMLInputElement.cpp:
3096         * html/HTMLInputElement.h:
3097         * html/InputType.h:
3098         * html/SearchInputType.cpp:
3099         (WebCore::SearchInputType::SearchInputType):
3100         (WebCore::SearchInputType::createShadowSubtree):
3101         (WebCore::SearchInputType::destroyShadowSubtree):
3102         * html/SearchInputType.h:
3103         (WebCore::SearchInputType::innerBlockElement):
3104         * html/TextFieldInputType.cpp:
3105         (WebCore::TextFieldInputType::TextFieldInputType):
3106         (WebCore::TextFieldInputType::createShadowSubtree):
3107         (WebCore::TextFieldInputType::destroyShadowSubtree):
3108         * html/TextFieldInputType.h:
3109         (WebCore::TextFieldInputType::innerTextElement):
3110         (WebCore::TextFieldInputType::innerSpinButtonElement):
3111         (WebCore::TextFieldInputType::speechButtonElement):
3112         (WebCore::TextFieldInputType::setInnerTextElement):
3113         (WebCore::TextFieldInputType::setSpeechButtonElement):
3114         * rendering/RenderTextControlSingleLine.cpp:
3115         (WebCore::RenderTextControlSingleLine::innerTextElement):
3116         (WebCore::RenderTextControlSingleLine::layout):
3117         (WebCore::RenderTextControlSingleLine::nodeAtPoint):
3118         (WebCore::RenderTextControlSingleLine::forwardEvent):
3119         (WebCore::RenderTextControlSingleLine::styleDidChange):
3120         (WebCore::RenderTextControlSingleLine::hasControlClip):
3121         (WebCore::RenderTextControlSingleLine::controlClipRect):
3122         (WebCore::RenderTextControlSingleLine::textBlockWidth):
3123         (WebCore::RenderTextControlSingleLine::createInnerTextStyle):
3124         (WebCore::RenderTextControlSingleLine::createInnerBlockStyle):
3125         (WebCore::RenderTextControlSingleLine::textBlockInsetTop):
3126         * rendering/RenderTextControlSingleLine.h:
3127
3128 2011-06-20  Mikhail Naganov  <mnaganov@chromium.org>
3129
3130         Reviewed by Pavel Feldman.
3131
3132         Web Inspector: [Chromium] Improve speed of heap profiles dominators view.
3133         https://bugs.webkit.org/show_bug.cgi?id=62979
3134
3135         * inspector/front-end/DetailedHeapshotGridNodes.js:
3136         (WebInspector.HeapSnapshotDominatorObjectNode.prototype._createProvider):
3137         * inspector/front-end/HeapSnapshot.js:
3138         (WebInspector.HeapSnapshotArraySlice.prototype.item):
3139         (WebInspector.HeapSnapshotArraySlice.prototype.slice):
3140         (WebInspector.HeapSnapshot.prototype.dispose):
3141         (WebInspector.HeapSnapshot.prototype._dominatedNodesOfNode):
3142         (WebInspector.HeapSnapshot.prototype._buildReverseIndex.var):
3143         (WebInspector.HeapSnapshot.prototype._buildReverseIndex):
3144         (WebInspector.HeapSnapshot.prototype._buildRetainers):
3145         (WebInspector.HeapSnapshot.prototype._buildNodeIndex):
3146         (WebInspector.HeapSnapshot.prototype._buildDominatedNodes):
3147         (WebInspector.HeapSnapshot.prototype._getDominatedIndex):
3148         (WebInspector.HeapSnapshot.prototype.createNodesProviderForClass):
3149         (WebInspector.HeapSnapshot.prototype.createNodesProviderForDominator):
3150         (WebInspector.HeapSnapshotFilteredOrderedIterator):
3151         (WebInspector.HeapSnapshotFilteredOrderedIterator.prototype._createIterationOrder):
3152         (WebInspector.HeapSnapshotFilteredOrderedIterator.prototype.get length):
3153         (WebInspector.HeapSnapshotFilteredOrderedIterator.prototype.serializeNextItems):
3154         (WebInspector.HeapSnapshotNodesProvider):
3155         * inspector/front-end/HeapSnapshotProxy.js:
3156         (WebInspector.HeapSnapshotProxy.prototype.createNodesProviderForDominator):
3157
3158 2011-06-22  Sreeram Ramachandran  <sreeram@chromium.org>
3159
3160         Reviewed by Pavel Feldman.
3161
3162         Web Inspector: Restore console messages when restoring inspector state
3163         https://bugs.webkit.org/show_bug.cgi?id=63146
3164
3165         No new tests (no change in functionality, only in display).
3166
3167         * inspector/InspectorConsoleAgent.cpp:
3168         (WebCore::InspectorConsoleAgent::restore):
3169         * inspector/InspectorConsoleAgent.h:
3170         * inspector/InspectorController.cpp:
3171         (WebCore::InspectorController::restoreInspectorStateFromCookie):
3172
3173 2011-06-22  Adam Barth  <abarth@webkit.org>
3174
3175         Attempt to fix the GTK build after my incomplete rollout of 88332.
3176
3177         * GNUmakefile.list.am:
3178
3179 2011-06-22  Sam Weinig  <sam@webkit.org>
3180
3181         Reviewed by Adam Barth.
3182
3183         HTML parser should limit element depth of produced tree
3184         https://bugs.webkit.org/show_bug.cgi?id=63082
3185
3186         Test by:
3187             fast/parser/block-nesting-cap.html
3188             fast/parser/element-nesting-cap.html
3189
3190         * html/parser/HTMLConstructionSite.cpp:
3191         (WebCore::HTMLConstructionSite::attach):
3192         (WebCore::HTMLConstructionSite::HTMLConstructionSite):
3193         * html/parser/HTMLConstructionSite.h:
3194         Limit the DOM tree depth by turning attempts to add a child passed a certain
3195         threshold (configurable by Settings::maximumDOMTreeDepth) into a sibling.
3196
3197         * html/parser/HTMLDocumentParser.cpp:
3198         (WebCore::HTMLDocumentParser::HTMLDocumentParser):
3199         (WebCore::HTMLDocumentParser::maximumDOMTreeDepth):
3200         * html/parser/HTMLDocumentParser.h:
3201         Pass the maximumDOMTreeDepth to the TreeBuilder.
3202
3203         * html/parser/HTMLElementStack.cpp:
3204         (WebCore::HTMLElementStack::HTMLElementStack):
3205         (WebCore::HTMLElementStack::popAll):
3206         (WebCore::HTMLElementStack::insertAbove):
3207         (WebCore::HTMLElementStack::pushCommon):
3208         (WebCore::HTMLElementStack::popCommon):
3209         (WebCore::HTMLElementStack::removeNonTopCommon):
3210         * html/parser/HTMLElementStack.h:
3211         (WebCore::HTMLElementStack::size):
3212         Keep track of the size of the element stack.
3213
3214         * html/parser/HTMLTreeBuilder.cpp:
3215         (WebCore::HTMLTreeBuilder::HTMLTreeBuilder):
3216         * html/parser/HTMLTreeBuilder.h:
3217         (WebCore::HTMLTreeBuilder::create):
3218         Pass the maximumDOMTreeDepth to the construction site.
3219
3220         * page/Settings.cpp:
3221         (WebCore::Settings::Settings):
3222         * page/Settings.h:
3223         (WebCore::Settings::setMaximumHTMLParserDOMTreeDepth):
3224         (WebCore::Settings::maximumHTMLParserDOMTreeDepth):
3225         Add a setting to control the maximum DOM tree depth that the parser will produce.
3226
3227 2011-06-22  Adam Barth  <abarth@webkit.org>
3228
3229         Rollout 88332.  As discussed on webkit-dev, we'd like to iterate on
3230         both the API and it's implementation a bit.
3231
3232         * WebCore.gypi:
3233         * bindings/generic/RuntimeEnabledFeatures.cpp:
3234         * bindings/generic/RuntimeEnabledFeatures.h:
3235         * dom/DocumentMarker.h:
3236         (WebCore::DocumentMarker::activeMatch):
3237         * dom/DocumentMarkerController.cpp:
3238         * dom/DocumentMarkerController.h:
3239         * html/HTMLDivElement.cpp:
3240         * html/HTMLDivElement.h:
3241         * html/HTMLDivElement.idl:
3242         * html/HTMLInputElement.cpp:
3243         * html/HTMLInputElement.h:
3244         * html/HTMLInputElement.idl:
3245         * html/HTMLTextAreaElement.cpp:
3246         * html/HTMLTextAreaElement.h:
3247         * html/HTMLTextAreaElement.idl:
3248         * html/SpellcheckRange.cpp: Removed.
3249         * html/SpellcheckRange.h: Removed.
3250         * html/SpellcheckRange.idl: Removed.
3251         * html/SpellcheckRangeList.cpp: Removed.
3252         * html/SpellcheckRangeList.h: Removed.
3253         * html/SpellcheckRangeList.idl: Removed.
3254         * rendering/InlineTextBox.cpp:
3255         (WebCore::textCheckingLineStyleForMarkerType):
3256         (WebCore::InlineTextBox::paintDocumentMarkers):
3257
3258 2011-06-22  Mark Pilgrim  <pilgrim@chromium.org>
3259
3260         Reviewed by Adam Barth.
3261
3262         IndexedDB: fix multiple issues in IDBDatabase.idl
3263         https://bugs.webkit.org/show_bug.cgi?id=63140
3264
3265         Tests: storage/indexeddb/createObjectStore-name-argument-required.html
3266                storage/indexeddb/createObjectStore-null-name.html
3267                storage/indexeddb/deleteObjectStore-name-argument-required.html
3268                storage/indexeddb/deleteObjectStore-null-name.html
3269                storage/indexeddb/setVersion-null.html
3270                storage/indexeddb/transaction-storeNames-required.html
3271
3272         * storage/IDBDatabase.idl: remove LegacyDefaultOptionalArguments so
3273         all functions will throw TypeError when called with too few arguments,
3274         as per WebIDL spec. Also remove ConvertNullToNullString flags so null
3275         values are stringified as "null" (also as per WebIDL spec).
3276
3277 2011-06-22  Vsevolod Vlasov  <vsevik@chromium.org>
3278
3279         Reviewed by Pavel Feldman.
3280
3281         Web Inspector: Move logic for deciding whether resource content should be base64 encoded on backend.
3282         https://bugs.webkit.org/show_bug.cgi?id=63069
3283
3284         * inspector/Inspector.json:
3285         * inspector/InspectorPageAgent.cpp:
3286         (WebCore::InspectorPageAgent::cachedResourceContent):
3287         (WebCore::InspectorPageAgent::resourceContent):
3288         (WebCore::InspectorPageAgent::getResourceContent):
3289         (WebCore::InspectorPageAgent::searchInResources):
3290         * inspector/InspectorPageAgent.h:
3291         * inspector/InspectorResourceAgent.cpp:
3292         (WebCore::InspectorResourceAgent::getResourceContent):
3293         * inspector/InspectorResourceAgent.h:
3294         * inspector/InspectorStyleSheet.cpp:
3295         (WebCore::InspectorStyleSheet::resourceStyleSheetText):
3296         * inspector/front-end/NetworkManager.js:
3297         (WebInspector.NetworkManager.prototype.requestContent):
3298         * inspector/front-end/Resource.js:
3299         (WebInspector.Resource.prototype._innerRequestContent.onResourceContent):
3300         (WebInspector.Resource.prototype._innerRequestContent):
3301
3302 2011-06-22  Luke Macpherson   <macpherson@chromium.org>
3303
3304         Reviewed by Dimitri Glazkov.
3305
3306         Support cast from CSSPrimitiveValue to short and use for CSSPropertyWidows and CSSPropertyOrphans.
3307         https://bugs.webkit.org/show_bug.cgi?id=62964
3308
3309         No new tests / refactoring only.
3310
3311         * css/CSSPrimitiveValueMappings.h:
3312         Support cast to/from short.
3313         * css/CSSStyleSelector.cpp:
3314         (WebCore::CSSStyleSelector::applyProperty):
3315         Use cast to short to allow CSSPropertWidows and CSSPropertyOrphans to use existing macro.
3316
3317 2011-06-22  Eunmi Lee  <eunmi15.lee@samsung.com>
3318
3319         Reviewed by Martin Robinson.
3320
3321         Change GtkWidgetBackingStore.h to WidgetBackingStore.h in order to use in the EFL port.
3322         https://bugs.webkit.org/show_bug.cgi?id=62848
3323
3324         This patch will make GtkWidgetBackingStore shareable with EFL port.
3325         It is a preparation to integrate WebKit2's BackingStoreGtk.cpp and
3326         BackingStoreEfl.cpp as a BackingStoreCairo.cpp.
3327
3328         * GNUmakefile.am:
3329         * GNUmakefile.list.am:
3330         * platform/graphics/cairo/CairoUtilities.cpp:
3331         (WebCore::copyRectFromOneSurfaceToAnother):
3332         * platform/graphics/cairo/CairoUtilities.h:
3333         * platform/cairo/WidgetBackingStore.h: Added.
3334         * platform/gtk/GtkWidgetBackingStore.h: Removed.
3335         * platform/gtk/GtkWidgetBackingStoreCairo.cpp:
3336         (WebCore::createSurfaceForBackingStore):
3337         (WebCore::WidgetBackingStorePrivate::create):
3338         (WebCore::WidgetBackingStorePrivate::WidgetBackingStorePrivate):
3339         (WebCore::WidgetBackingStore::create):
3340         (WebCore::WidgetBackingStore::WidgetBackingStore):
3341         (WebCore::WidgetBackingStore::~WidgetBackingStore):
3342         (WebCore::WidgetBackingStore::cairoSurface):
3343         (WebCore::WidgetBackingStore::scroll):
3344         * platform/gtk/GtkWidgetBackingStoreX11.cpp:
3345         (WebCore::WidgetBackingStorePrivate::create):
3346         (WebCore::WidgetBackingStorePrivate::~WidgetBackingStorePrivate):
3347         (WebCore::WidgetBackingStorePrivate::WidgetBackingStorePrivate):
3348         (WebCore::WidgetBackingStore::create):
3349         (WebCore::WidgetBackingStore::WidgetBackingStore):
3350         (WebCore::WidgetBackingStore::~WidgetBackingStore):
3351         (WebCore::WidgetBackingStore::cairoSurface):
3352         (WebCore::WidgetBackingStore::scroll):
3353
3354 2011-06-22  Simon Fraser  <simon.fraser@apple.com>
3355
3356         Reviewed by Dan Bernstein.
3357
3358         Update position, bounds and anchor point in GraphicsLayerCA all at once
3359         https://bugs.webkit.org/show_bug.cgi?id=63148
3360
3361         Since position, bounds and anchor point are inter-dependent, avoid
3362         redundant work by simply updating them all at the same time.
3363         
3364         No behavior changes, so no new tests.
3365
3366         * platform/graphics/ca/GraphicsLayerCA.cpp:
3367         (WebCore::GraphicsLayerCA::setPosition):
3368         (WebCore::GraphicsLayerCA::setAnchorPoint):
3369         (WebCore::GraphicsLayerCA::setSize):
3370         (WebCore::GraphicsLayerCA::setBoundsOrigin):
3371         (WebCore::GraphicsLayerCA::setAllowTiledLayer):
3372         (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
3373         (WebCore::GraphicsLayerCA::updateGeometry):
3374         (WebCore::GraphicsLayerCA::ensureStructuralLayer):
3375         (WebCore::GraphicsLayerCA::swapFromOrToTiledLayer):
3376         * platform/graphics/ca/GraphicsLayerCA.h:
3377
3378 2011-06-22  Ryosuke Niwa  <rniwa@webkit.org>
3379
3380         Reviewed by Darin Adler.
3381
3382         Make instantiation of legacy editing position more explicit
3383         https://bugs.webkit.org/show_bug.cgi?id=63037
3384
3385         Replaced the constructor of Position class that used to instantiate a legacy editing position
3386         by a function called createLegacyEditingPosition.
3387
3388         * WebCore.exp.in: Removed the constructor from the list.
3389         * accessibility/AXObjectCache.cpp:
3390         (WebCore::AXObjectCache::visiblePositionForTextMarkerData): Calls createLegacyEditingPosition.
3391         * accessibility/gtk/AXObjectCacheAtk.cpp:
3392         (WebCore::AXObjectCache::nodeTextChangePlatformNotification): No longer uses Positions to instantiate a range.
3393         * dom/Position.cpp:
3394         (WebCore::Position::Position): New constructor takes LegacyEditingOffset, which can only be instantiated
3395         by createLegacyEditingPosition.
3396         (WebCore::Position::previous): Calls createLegacyEditingPosition.
3397         (WebCore::Position::next): Ditto.
3398         (WebCore::Position::upstream): Ditto.
3399         (WebCore::Position::downstream): Ditto.
3400         * dom/Position.h: Added new Position::LegacyEditingOffset class to hide the legacy constructor from the world.
3401         (WebCore::Position::LegacyEditingOffset::value): Added.
3402         (WebCore::Position::LegacyEditingOffset::LegacyEditingOffset): Added.
3403         (WebCore::createLegacyEditingPosition): Added.
3404         * dom/PositionIterator.cpp:
3405         (WebCore::PositionIterator::operator Position): Calls createLegacyEditingPosition.
3406         * dom/RangeBoundaryPoint.h:
3407         (WebCore::RangeBoundaryPoint::toPosition): Ditto.
3408         * editing/InsertTextCommand.cpp:
3409         (WebCore::InsertTextCommand::performTrivialReplace): Instantiates new Position instead of old one; this is always
3410         safe since the anchor node is always a text node.
3411         * editing/VisiblePosition.cpp:
3412         (WebCore::VisiblePosition::leftVisuallyDistinctCandidate): Calls createLegacyEditingPosition.
3413         (WebCore::VisiblePosition::rightVisuallyDistinctCandidate): Ditto.
3414         * editing/markup.cpp:
3415         (WebCore::StyledMarkupAccumulator::renderedText): Ditto.
3416         * editing/visible_units.cpp:
3417         (WebCore::previousBoundary): Ditto.
3418         (WebCore::previousLinePosition): Ditto.
3419         (WebCore::nextLinePosition): Ditto.
3420         * page/DOMSelection.cpp:
3421         (WebCore::DOMSelection::collapse): Ditto.
3422         (WebCore::DOMSelection::setBaseAndExtent): Ditto.
3423         (WebCore::DOMSelection::setPosition): Ditto.
3424         (WebCore::DOMSelection::extend): Ditto.
3425         * rendering/RenderBlock.cpp:
3426         (WebCore::RenderBlock::positionForBox): Ditto.
3427         * rendering/RenderBox.cpp:
3428         (WebCore::RenderBox::positionForPoint): Calls Position() instead of Position(0, 0).
3429         * rendering/RenderObject.cpp:
3430         (WebCore::RenderObject::createVisiblePosition): Calls createLegacyEditingPosition.s
3431
3432 2011-06-22  Pavel Feldman  <pfeldman@google.com>
3433
3434         Reviewed by Yury Semikhatsky.
3435
3436         Web Inspector: split setAttributes and setAttributeValue.
3437         https://bugs.webkit.org/show_bug.cgi?id=63138
3438
3439         * inspector/Inspector.json:
3440         * inspector/InspectorDOMAgent.cpp:
3441         (WebCore::InspectorDOMAgent::setAttributeValue):
3442         (WebCore::InspectorDOMAgent::setAttributesText):
3443         * inspector/InspectorDOMAgent.h:
3444         * inspector/front-end/DOMAgent.js:
3445         (WebInspector.DOMNode.prototype.setAttribute):
3446         (WebInspector.DOMNode.prototype.setAttributeValue):
3447
3448 2011-06-22  Dirk Schulze  <krit@webkit.org>
3449
3450         Reviewed by Nikolas Zimmermann.
3451
3452         Animate viewBox attribute in SVG
3453         https://bugs.webkit.org/show_bug.cgi?id=20057
3454
3455         Follow up of "SVGAnimation should use direct unit animation for SVGLength": https://bugs.webkit.org/show_bug.cgi?id=61368
3456         This patch continues the conversion to the new concept of SVGAnimatorFactory with SVGRect. With the new animator we support
3457         interpolation between SVGRects. A feature that can be used to get smooth zooming animations for SVGs.
3458         
3459         Added parseRect() to SVGParserUtilities for parsing Strings to FloatRects.
3460
3461         Tests: svg/animations/svgrect-animation-1.html
3462                svg/animations/svgrect-animation-2.html
3463
3464         * CMakeLists.txt: Added new file SVGAnimatedRect.cpp to build system.
3465         * GNUmakefile.list.am: Ditto.
3466         * WebCore.gypi: Ditto.
3467         * WebCore.pro: Ditto.
3468         * WebCore.xcodeproj/project.pbxproj: Ditto.
3469         * platform/graphics/FloatRect.h: Added new operators + and +=.
3470         (WebCore::operator+=):
3471         (WebCore::operator+):
3472         * svg/SVGAllInOne.cpp: Added SVGAnimatedRect.cpp for Win build.
3473         * svg/SVGAnimateElement.cpp: Handle AnimatedRect explicitly.
3474         (WebCore::SVGAnimateElement::determineAnimatedAttributeType): Ditto.
3475         (WebCore::SVGAnimateElement::calculateAnimatedValue): Ditto.
3476         (WebCore::SVGAnimateElement::calculateFromAndToValues): Ditto.
3477         (WebCore::SVGAnimateElement::calculateFromAndByValues): Ditto.
3478         (WebCore::SVGAnimateElement::resetToBaseValue): Ditto.
3479         (WebCore::SVGAnimateElement::applyResultsToTarget): Ditto.
3480         (WebCore::SVGAnimateElement::calculateDistance): Ditto.
3481         * svg/SVGAnimatedRect.cpp: Added. The new Animator for SVGRect.
3482         (WebCore::SVGAnimatedRectAnimator::SVGAnimatedRectAnimator):
3483         (WebCore::SVGAnimatedRectAnimator::constructFromString):
3484         (WebCore::SVGAnimatedRectAnimator::calculateFromAndToValues):