ce8f7991ad824605521bb7dbf0be19ebcd4dc018
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2011-05-24  Andras Becsi  <abecsi@webkit.org>
2
3         Reviewed by Csaba Osztrogonác.
4
5         [Qt][V8] REGRESSION (r87063): Fix the build.
6         https://bugs.webkit.org/show_bug.cgi?id=61290
7
8         No new tests needed.
9
10         * bindings/scripts/CodeGeneratorV8.pm: disable the unsupported call
11         tracked in: https://bugs.webkit.org/show_bug.cgi?id=61291
12
13 2011-05-24  Naoki Takano  <takano.naoki@gmail.com>
14
15         Reviewed by Kent Tamura.
16
17         [Chromium]Add clipping for listBox in popup window to fix wrong location display when the autofill item is really long.
18         https://bugs.webkit.org/show_bug.cgi?id=61252
19         http://code.google.com/p/chromium/issues/detail?id=83539
20
21         Manual test: manual-tests/autofill-popup-location.html.
22
23         * manual-tests/autofill-popup-location.html: With long long text, test the shown location is correct.
24         * platform/chromium/PopupMenuChromium.cpp:
25         (WebCore::PopupListBox::setBaseWidth): Clip width with m_maxWindowWidth.
26         (WebCore::PopupListBox::PopupListBox): Add m_maxWindowWidth initialization.
27         (WebCore::PopupContainer::layoutAndCalculateWidgetRect): Call setMaxWidthAndLayout() when the width is clipped with screen size.
28         (WebCore::PopupListBox::setMaxWidthAndLayout): Set m_maxWindowWidth and call layout().
29         (WebCore::PopupListBox::layout): Compare renewed windowWidth and m_maxWindowWidth, and clip the it.
30
31 2011-05-24  James Robinson  <jamesr@chromium.org>
32
33         Reviewed by Kenneth Russell.
34
35         [chromium] Properly handle huge initial dimensions for 2d canvas when accelerated 2d canvas is enabled
36         https://bugs.webkit.org/show_bug.cgi?id=60077
37
38         Return NULL from DrawingBuffer::create() if the initial dimensions are larger than we can support in hardware so
39         that we properly use the software canvas path and not enable the compositor for the canvas.
40
41         compositing/tiling/huge-layer-img.html triggers this case by trying to create a 20000 pixel high canvas.  The
42         failure was previously masked by other bugs fixed by r85661.
43
44         * platform/graphics/chromium/DrawingBufferChromium.cpp:
45         (WebCore::DrawingBuffer::DrawingBuffer):
46             Return NULL from DrawingBuffer::create() if resize() fails.
47
48 2011-05-24  Fumitoshi Ukai  <ukai@chromium.org>
49
50         Reviewed by Adam Barth.
51
52         close before open WebSocket doesn't fire close event.
53         https://bugs.webkit.org/show_bug.cgi?id=57301
54
55         In platformClose(), m_readStream may be 0 until proxy is resolved.
56         It should callback didClose() in such case.
57         
58         Test: http/tests/websocket/tests/close-before-open.html
59
60         * platform/network/cf/SocketStreamHandleCFNet.cpp:
61         (WebCore::SocketStreamHandle::platformClose):
62
63 2011-05-23  Sheriff Bot  <webkit.review.bot@gmail.com>
64
65         Unreviewed, rolling out r87118.
66         http://trac.webkit.org/changeset/87118
67         https://bugs.webkit.org/show_bug.cgi?id=61347
68
69         patch breaks layout tests
70         (https://bugs.webkit.org/show_bug.cgi?id=61342), and chromium
71         tests (browser_test MacTestCmdUp and ui_test Scrollbar)
72         (Requested by ukai_ on #webkit).
73
74         * WebCore.gyp/WebCore.gyp:
75         * WebCore.gypi:
76         * platform/ScrollAnimator.cpp:
77         * platform/chromium/ScrollAnimatorChromiumMac.h: Removed.
78         * platform/chromium/ScrollAnimatorChromiumMac.mm: Removed.
79         * platform/graphics/IntPoint.h:
80
81 2011-05-23  Julien Chaffraix  <jchaffraix@codeaurora.org>
82
83         Reviewed by Adam Barth.
84
85         Remove Node::deprecatedParserAddChild
86         https://bugs.webkit.org/show_bug.cgi?id=60818
87
88         No new tests as this is just a removal.
89
90         * dom/ContainerNode.cpp:
91         * dom/ContainerNode.h:
92         * dom/Node.cpp:
93         * dom/Node.h:
94         Removed the method now that the last instance got removed as part of the <input>
95         shadow DOM refactoring.
96
97 2011-05-23  Dirk Schulze  <krit@webkit.org>
98
99         Reviewed by Darin Adler.
100
101         SVGTextPositioning attributes are marked as NumberList instead of LengthList
102         https://bugs.webkit.org/show_bug.cgi?id=61301
103
104         SVGTextPositioningElement attributes x, y, dx and dy were marked as AnimatedNumberList
105         instead of AnimatedLengthList.
106         See specification http://www.w3.org/TR/SVG/text.html#InterfaceSVGTextPositioningElement
107
108         This does not affect the behavior, since we do not respect SVG units in SMIL animation yet.
109         No new tests added.
110
111         * svg/SVGTextPositioningElement.cpp:
112         (WebCore::SVGTextPositioningElement::fillPassedAttributeToPropertyTypeMap):
113
114 2011-05-19  MORITA Hajime  <morrita@google.com>
115
116         Reviewed by Dimitri Glazkov.
117
118         [Refactoring] Pass NodeRenderingContext to Node::rendererIsNeeded()
119         https://bugs.webkit.org/show_bug.cgi?id=61114
120
121         - Extracted NodeRenderingContext from NodeRendererFactory, giving separate files to it.
122         - Changed signature rendererIsNeeded(RenderStyle*) 
123           to rendererIsNeeded(const NodeRenderingContext&).
124           The style object is retrieved from NodeRendererFactory::style()
125           This will allow rendererIsNeeded() to access contextual
126           information like attaching phase and rendering-parent.
127         
128         No new tests. No behaviour change.
129         
130         * CMakeLists.txt:
131         * GNUmakefile.list.am:
132         * WebCore.gypi:
133         * WebCore.pro:
134         * WebCore.vcproj/WebCore.vcproj:
135         * WebCore.xcodeproj/project.pbxproj:
136         * dom/CharacterData.cpp:
137         (WebCore::CharacterData::updateRenderer): Pass unresolved NodeRenderingContext& to rendererIsNeeded()
138         (WebCore::CharacterData::rendererIsNeeded):
139         * dom/CharacterData.h:
140         * dom/DOMAllInOne.cpp:
141         * dom/EditingText.cpp:
142         (WebCore::EditingText::rendererIsNeeded):
143         * dom/EditingText.h:
144         * dom/Node.cpp:
145         (WebCore::Node::parentNodeForRenderingAndStyle):
146         (WebCore::Node::rendererIsNeeded):
147         * dom/Node.h:
148         * dom/NodeRenderingContext.cpp: Added.
149         (WebCore::NodeRenderingContext::NodeRenderingContext):
150         (WebCore::NodeRenderingContext::~NodeRenderingContext):
151         (WebCore::NodeRenderingContext::setStyle):
152         (WebCore::NodeRenderingContext::releaseStyle):
153         (WebCore::NodeRenderingContext::nextRenderer):
154         (WebCore::NodeRenderingContext::parentRenderer):
155         (WebCore::NodeRenderingContext::hostChildrenChanged):
156         (WebCore::NodeRenderingContext::shouldCreateRenderer):
157         (WebCore::NodeRendererFactory::NodeRendererFactory):
158         (WebCore::NodeRendererFactory::createRendererAndStyle):
159         (WebCore::wrapWithRenderFullScreen):
160         (WebCore::NodeRendererFactory::createRendererIfNeeded):
161         * dom/NodeRenderingContext.h: Added.
162         (WebCore::NodeRenderingContext::node):
163         (WebCore::NodeRenderingContext::parentNodeForRenderingAndStyle):
164         (WebCore::NodeRenderingContext::style):
165         (WebCore::NodeRendererFactory::context):
166         * dom/ShadowContentElement.h:
167         * dom/Text.cpp:
168         * dom/Text.h:
169         * html/HTMLAppletElement.cpp:
170         * html/HTMLAppletElement.h:
171         * html/HTMLElement.cpp:
172         * html/HTMLElement.h:
173         * html/HTMLEmbedElement.cpp:
174         * html/HTMLEmbedElement.h:
175         * html/HTMLFormElement.cpp:
176         * html/HTMLFormElement.h:
177         * html/HTMLFrameElement.cpp:
178         * html/HTMLFrameElement.h:
179         * html/HTMLFrameSetElement.cpp:
180         * html/HTMLFrameSetElement.h:
181         * html/HTMLIFrameElement.cpp:
182         * html/HTMLIFrameElement.h:
183         * html/HTMLInputElement.cpp:
184         * html/HTMLInputElement.h:
185         * html/HTMLMediaElement.cpp:
186         * html/HTMLMediaElement.h:
187         * html/HTMLNoScriptElement.h:
188         * html/HTMLObjectElement.cpp:
189         * html/HTMLObjectElement.h:
190         * html/HTMLOptGroupElement.h:
191         * html/HTMLOptionElement.h:
192         * html/HTMLVideoElement.cpp:
193         * html/HTMLVideoElement.h:
194         * html/shadow/DetailsMarkerControl.cpp:
195         * html/shadow/DetailsMarkerControl.h:
196         * html/shadow/MeterShadowElement.cpp:
197         * html/shadow/MeterShadowElement.h:
198         * html/shadow/ProgressShadowElement.cpp:
199         * html/shadow/ProgressShadowElement.h:
200         * svg/SVGDescElement.h:
201         * svg/SVGElement.h:
202         * svg/SVGFilterPrimitiveStandardAttributes.cpp:
203         * svg/SVGFilterPrimitiveStandardAttributes.h:
204         * svg/SVGFontElement.h:
205         * svg/SVGGElement.cpp:
206         * svg/SVGGElement.h:
207         * svg/SVGGlyphElement.h:
208         * svg/SVGHKernElement.h:
209         * svg/SVGMarkerElement.h:
210         * svg/SVGMissingGlyphElement.h:
211         * svg/SVGSVGElement.h:
212         * svg/SVGStyledElement.cpp:
213         * svg/SVGStyledElement.h:
214         * svg/SVGSymbolElement.h:
215         * svg/SVGTRefElement.cpp:
216         * svg/SVGTRefElement.h:
217         * svg/SVGTSpanElement.cpp:
218         * svg/SVGTSpanElement.h:
219         * svg/SVGTextPathElement.cpp:
220         * svg/SVGTextPathElement.h:
221         * svg/SVGTitleElement.h:
222         * svg/SVGVKernElement.h:
223         * svg/SVGViewElement.h:
224
225 2011-05-20  MORITA Hajime  <morrita@google.com>
226
227         Reviewed by Dimitri Glazkov.
228         
229         [Refactoring] attach() following detach() should be replaced with Node::reattach()
230         https://bugs.webkit.org/show_bug.cgi?id=61011
231
232         - Renamed forceReattach() to reattach()
233         - Introduced reattachIfAttached() as a variant.
234         
235         No new tests. No behavior change.
236
237         * dom/CharacterData.cpp:
238         (WebCore::CharacterData::updateRenderer):
239         * dom/Element.cpp:
240         (WebCore::Element::recalcStyle):
241         * dom/Node.h:
242         (WebCore::Node::reattach):
243         (WebCore::Node::reattachIfAttached):
244         * dom/Text.cpp:
245         (WebCore::Text::recalcStyle):
246         * html/HTMLDetailsElement.cpp:
247         (WebCore::HTMLDetailsElement::refreshMainSummary):
248         (WebCore::HTMLDetailsElement::parseMappedAttribute):
249         * html/HTMLInputElement.cpp:
250         (WebCore::HTMLInputElement::parseMappedAttribute):
251         * html/HTMLObjectElement.cpp:
252         (WebCore::HTMLObjectElement::renderFallbackContent):
253         * html/HTMLPlugInImageElement.cpp:
254         (WebCore::HTMLPlugInImageElement::recalcStyle):
255         * html/HTMLSelectElement.cpp:
256         (WebCore::HTMLSelectElement::parseMappedAttribute):
257
258 2011-05-23  Mark Rowe  <mrowe@apple.com>
259
260         Build fix after r87117.
261
262         When moving #defines out in to separate files I find that code is more likely to compile
263         when the new header file is actually #included.
264
265         * editing/SpellingCorrectionController.h:
266
267 2011-05-23  Mike Lawther  <mikelawther@chromium.org>
268
269         Reviewed by James Robinson.
270
271         implement image-rendering: optimize-contrast (with a vendor prefix) as defined in CSS3 image values
272         https://bugs.webkit.org/show_bug.cgi?id=56627
273
274         Tests: css3/images/optimize-contrast-canvas.html
275                css3/images/optimize-contrast-image.html
276
277         * WebCore.xcodeproj/project.pbxproj:
278         * css/CSSComputedStyleDeclaration.cpp:
279         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
280         * css/CSSParser.cpp:
281         (WebCore::CSSParser::parseValue):
282         * css/CSSPrimitiveValueMappings.h:
283         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
284         (WebCore::CSSPrimitiveValue::operator EImageRendering):
285         * css/CSSPropertyNames.in:
286         * css/CSSStyleSelector.cpp:
287         (WebCore::CSSStyleSelector::applyProperty):
288         * css/CSSValueKeywords.in:
289         * css/SVGCSSComputedStyleDeclaration.cpp:
290         (WebCore::CSSComputedStyleDeclaration::getSVGPropertyCSSValue):
291         * css/SVGCSSPropertyNames.in:
292         * css/SVGCSSStyleSelector.cpp:
293         (WebCore::CSSStyleSelector::applySVGProperty):
294         * css/SVGCSSValueKeywords.in:
295         * html/HTMLCanvasElement.cpp:
296         (WebCore::HTMLCanvasElement::paint):
297         * html/HTMLCanvasElement.h:
298         * platform/graphics/ImageRenderingMode.h: Added.
299         * rendering/RenderBoxModelObject.cpp:
300         (WebCore::ImageQualityController::shouldPaintAtLowQuality):
301         * rendering/RenderHTMLCanvas.cpp:
302         (WebCore::RenderHTMLCanvas::paintReplaced):
303         * rendering/style/RenderStyle.cpp:
304         (WebCore::RenderStyle::diff):
305         * rendering/style/RenderStyle.h:
306         (WebCore::InheritedFlags::imageRendering):
307         (WebCore::InheritedFlags::setImageRendering):
308         (WebCore::InheritedFlags::initialImageRendering):
309         * rendering/style/RenderStyleConstants.h:
310         * rendering/style/SVGRenderStyle.cpp:
311         (WebCore::SVGRenderStyle::diff):
312         * rendering/style/SVGRenderStyle.h:
313         (WebCore::SVGRenderStyle::InheritedFlags::operator==):
314         (WebCore::SVGRenderStyle::setBitDefaults):
315         * rendering/style/SVGRenderStyleDefs.h:
316         * rendering/svg/SVGRenderTreeAsText.cpp:
317         (WebCore::writeStyle):
318
319 2011-05-23  Sailesh Agrawal  <sail@chromium.org>
320
321         Reviewed by James Robinson.
322
323         Chromium Mac: Use ScrollAnimatorMac.mm for overlay scrollbar support
324         https://bugs.webkit.org/show_bug.cgi?id=59753
325
326         No new tests. Just forking ScrollAnimatorMac to ScrollAnimatorChromiumMac.
327
328         * WebCore.gyp/WebCore.gyp:
329         * WebCore.gypi:
330         * platform/ScrollAnimator.cpp:
331         * platform/chromium/ScrollAnimatorChromiumMac.h: Added.
332         (WebCore::ScrollAnimatorChromiumMac::setIsDrawingIntoLayer):
333         (WebCore::ScrollAnimatorChromiumMac::isDrawingIntoLayer):
334         (WebCore::ScrollAnimatorChromiumMac::haveScrolledSincePageLoad):
335         * platform/chromium/ScrollAnimatorChromiumMac.mm: Added. Forked from ScrollAnimatorMac and replaced all instances of ScrollAnimatorMac with ScrollAnimatorChromiumMac and ScrollbarThemeMac with ScrollbarThemeChromiumMac. Removed the ENABLE(SMOOTH_SCROLLING) around the file.
336         (abs):
337         (-[ScrollAnimationHelperDelegate initWithScrollAnimator:WebCore::]):
338         (-[ScrollAnimationHelperDelegate scrollAnimatorDestroyed]):
339         (-[ScrollAnimationHelperDelegate bounds]):
340         (-[ScrollAnimationHelperDelegate _immediateScrollToPoint:]):
341         (-[ScrollAnimationHelperDelegate _pixelAlignProposedScrollPosition:]):
342         (-[ScrollAnimationHelperDelegate convertSizeToBase:]):
343         (-[ScrollAnimationHelperDelegate convertSizeFromBase:]):
344         (-[ScrollAnimationHelperDelegate convertSizeToBacking:]):
345         (-[ScrollAnimationHelperDelegate convertSizeFromBacking:]):
346         (-[ScrollAnimationHelperDelegate superview]):
347         (-[ScrollAnimationHelperDelegate documentView]):
348         (-[ScrollAnimationHelperDelegate window]):
349         (-[ScrollAnimationHelperDelegate _recursiveRecomputeToolTips]):
350         (-[ScrollbarPainterControllerDelegate initWithScrollAnimator:WebCore::]):
351         (-[ScrollbarPainterControllerDelegate scrollAnimatorDestroyed]):
352         (-[ScrollbarPainterControllerDelegate contentAreaRectForScrollerImpPair:]):
353         (-[ScrollbarPainterControllerDelegate inLiveResizeForScrollerImpPair:]):
354         (-[ScrollbarPainterControllerDelegate mouseLocationInContentAreaForScrollerImpPair:]):
355         (-[ScrollbarPainterControllerDelegate scrollerImpPair:convertContentPoint:toScrollerImp:]):
356         (-[ScrollbarPainterControllerDelegate scrollerImpPair:setContentAreaNeedsDisplayInRect:]):
357         (-[ScrollbarPainterControllerDelegate scrollerImpPair:updateScrollerStyleForNewRecommendedScrollerStyle:]):
358         (-[ScrollbarPartAnimation initWithScrollbarPainter:part:WebCore::scrollAnimator:WebCore::animateAlphaTo:duration:]):
359         (-[ScrollbarPartAnimation setCurrentProgress:]):
360         (-[ScrollbarPartAnimation scrollAnimatorDestroyed]):
361         (-[ScrollbarPainterDelegate initWithScrollAnimator:WebCore::]):
362         (-[ScrollbarPainterDelegate cancelAnimations]):
363         (-[ScrollbarPainterDelegate convertRectToBacking:]):
364         (-[ScrollbarPainterDelegate convertRectFromBacking:]):
365         (-[ScrollbarPainterDelegate layer]):
366         (-[ScrollbarPainterDelegate setUpAnimation:scrollerPainter:part:WebCore::animateAlphaTo:duration:]):
367         (-[ScrollbarPainterDelegate scrollerImp:animateKnobAlphaTo:duration:]):
368         (-[ScrollbarPainterDelegate scrollerImp:animateTrackAlphaTo:duration:]):
369         (-[ScrollbarPainterDelegate scrollerImp:overlayScrollerStateChangedTo:]):
370         (-[ScrollbarPainterDelegate scrollAnimatorDestroyed]):
371         (WebCore::ScrollAnimator::create):
372         (WebCore::ScrollAnimatorChromiumMac::ScrollAnimatorChromiumMac):
373         (WebCore::ScrollAnimatorChromiumMac::~ScrollAnimatorChromiumMac):
374         (WebCore::ScrollAnimatorChromiumMac::scroll):
375         (WebCore::ScrollAnimatorChromiumMac::scrollToOffsetWithoutAnimation):
376         (WebCore::ScrollAnimatorChromiumMac::adjustScrollXPositionIfNecessary):
377         (WebCore::ScrollAnimatorChromiumMac::adjustScrollYPositionIfNecessary):
378         (WebCore::ScrollAnimatorChromiumMac::adjustScrollPositionIfNecessary):
379         (WebCore::ScrollAnimatorChromiumMac::immediateScrollToPoint):
380         (WebCore::ScrollAnimatorChromiumMac::immediateScrollByDeltaX):
381         (WebCore::ScrollAnimatorChromiumMac::immediateScrollByDeltaY):
382         (WebCore::ScrollAnimatorChromiumMac::notityPositionChanged):
383         (WebCore::ScrollAnimatorChromiumMac::contentAreaWillPaint):
384         (WebCore::ScrollAnimatorChromiumMac::mouseEnteredContentArea):
385         (WebCore::ScrollAnimatorChromiumMac::mouseExitedContentArea):
386         (WebCore::ScrollAnimatorChromiumMac::mouseMovedInContentArea):
387         (WebCore::ScrollAnimatorChromiumMac::willStartLiveResize):
388         (WebCore::ScrollAnimatorChromiumMac::contentsResized):
389         (WebCore::ScrollAnimatorChromiumMac::willEndLiveResize):
390         (WebCore::ScrollAnimatorChromiumMac::contentAreaDidShow):
391         (WebCore::ScrollAnimatorChromiumMac::contentAreaDidHide):
392         (WebCore::ScrollAnimatorChromiumMac::didBeginScrollGesture):
393         (WebCore::ScrollAnimatorChromiumMac::didEndScrollGesture):
394         (WebCore::ScrollAnimatorChromiumMac::didAddVerticalScrollbar):
395         (WebCore::ScrollAnimatorChromiumMac::willRemoveVerticalScrollbar):
396         (WebCore::ScrollAnimatorChromiumMac::didAddHorizontalScrollbar):
397         (WebCore::ScrollAnimatorChromiumMac::willRemoveHorizontalScrollbar):
398         (WebCore::ScrollAnimatorChromiumMac::cancelAnimations):
399         (WebCore::elasticDeltaForTimeDelta):
400         (WebCore::reboundDeltaForElasticDelta):
401         (WebCore::elasticDeltaForReboundDelta):
402         (WebCore::scrollWheelMultiplier):
403         (WebCore::ScrollAnimatorChromiumMac::handleWheelEvent):
404         (WebCore::ScrollAnimatorChromiumMac::handleGestureEvent):
405         (WebCore::ScrollAnimatorChromiumMac::pinnedInDirection):
406         (WebCore::ScrollAnimatorChromiumMac::allowsVerticalStretching):
407         (WebCore::ScrollAnimatorChromiumMac::allowsHorizontalStretching):
408         (WebCore::ScrollAnimatorChromiumMac::smoothScrollWithEvent):
409         (WebCore::ScrollAnimatorChromiumMac::beginScrollGesture):
410         (WebCore::ScrollAnimatorChromiumMac::endScrollGesture):
411         (WebCore::ScrollAnimatorChromiumMac::snapRubberBand):
412         (WebCore::roundTowardZero):
413         (WebCore::roundToDevicePixelTowardZero):
414         (WebCore::ScrollAnimatorChromiumMac::snapRubberBandTimerFired):
415         (WebCore::ScrollAnimatorChromiumMac::startScrollbarPaintTimer):
416         (WebCore::ScrollAnimatorChromiumMac::scrollbarPaintTimerIsActive):
417         (WebCore::ScrollAnimatorChromiumMac::stopScrollbarPaintTimer):
418         (WebCore::ScrollAnimatorChromiumMac::initialScrollbarPaintTimerFired):
419         (WebCore::ScrollAnimatorChromiumMac::setVisibleScrollerThumbRect):
420         * platform/graphics/IntPoint.h:
421
422 2011-05-22  MORITA Hajime  <morrita@google.com>
423
424         Reviewed by Ryosuke Niwa.
425
426         SUPPORT_AUTOCORRECTION_PANEL should be USE(AUTOCORRECTION_PANEL)
427         https://bugs.webkit.org/show_bug.cgi?id=61181
428
429         - Removed SUPPORT_AUTOCORRECTION_PANEL and REMOVE_MARKERS_UPON_EDITING from SpellingCorrectionController.h
430         - Define WTF_USE_UNIFIED_TEXT_CHECKING and WTF_USE_AUTOMATIC_TEXT_REPLACEMENT at TextChecking.h
431
432         No new tests. Just renaming a compilation conditional.
433
434         * editing/Editor.cpp:
435         (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges):
436         * editing/SpellingCorrectionCommand.cpp:
437         (WebCore::SpellingCorrectionCommand::doApply):
438         * editing/SpellingCorrectionController.cpp:
439         * editing/SpellingCorrectionController.h:
440         (WebCore::SpellingCorrectionController::shouldRemoveMarkersUponEditing):
441         * loader/EmptyClients.h:
442         * page/EditorClient.h:
443         * platform/text/TextChecking.h:
444
445 2011-05-23  Sheriff Bot  <webkit.review.bot@gmail.com>
446
447         Unreviewed, rolling out r87007.
448         http://trac.webkit.org/changeset/87007
449         https://bugs.webkit.org/show_bug.cgi?id=61329
450
451         patch unnecessarily breaks HTML5 compatibility (Requested by
452         estes on #webkit).
453
454         * html/HTMLObjectElement.cpp:
455         (WebCore::HTMLObjectElement::hasValidClassId):
456
457 2011-05-23  Julien Chaffraix  <jchaffraix@codeaurora.org>
458
459         Reviewed by Darin Adler.
460
461         Crash from null pointer dereference below WebCore::StorageAreaImpl::setItem()
462         https://bugs.webkit.org/show_bug.cgi?id=57140
463
464         Test: fast/storage/storage-detached-iframe.html
465
466         Access of localStorage on a detached iframe was causing a crash because a detached 
467         iframe has a null m_page, and WebCore::privateBrowsingEnabled() wasn't testing for such.
468
469         * storage/StorageAreaImpl.cpp:
470         (WebCore::privateBrowsingEnabled): check that child->page() is non-null before
471         accessing it.
472
473 2011-05-23  Chris Fleizach  <cfleizach@apple.com>
474
475         Reviewed by David Kilzer.
476
477         VO doesn't work with HTML5 range (slider) input @step attribute
478         https://bugs.webkit.org/show_bug.cgi?id=61298
479
480         Test: platform/mac/accessibility/range-alter-by-step.html
481
482         * accessibility/AccessibilityObject.h:
483         (WebCore::AccessibilityObject::stepValueForRange):
484         * accessibility/AccessibilityRenderObject.cpp:
485         (WebCore::AccessibilityRenderObject::alterSliderValue):
486         (WebCore::AccessibilityRenderObject::increment):
487         (WebCore::AccessibilityRenderObject::decrement):
488         (WebCore::AccessibilityRenderObject::stepValueForRange):
489         (WebCore::AccessibilityRenderObject::changeValueByStep):
490         * accessibility/AccessibilityRenderObject.h:
491
492 2011-05-23  Gavin Peters  <gavinp@chromium.org>
493
494         Reviewed by Adam Barth.
495
496         fix rel=prerender target types
497         https://bugs.webkit.org/show_bug.cgi?id=61297
498
499         The original fix in https://bugs.webkit.org/show_bug.cgi?id=61079
500         didn't properly map the target type, and didn't carry the target
501         types through to chromium properly.  Fixed.
502
503         No new tests; it's very hard to catch these with a layout test, however
504         all of the chromium Prerender browser tests will test this functionality
505         when I land an upcoming chromium CL.
506
507         * loader/cache/CachedResourceRequest.cpp:
508         (WebCore::cachedResourceTypeToTargetType):
509
510 2011-05-23  Matthew Delaney  <mdelaney@apple.com>
511
512         Reviewed by Simon Fraser.
513
514         Remove safeFloatToInt() in FloatRect.cpp and replace with working version of clampToInteger()
515         https://bugs.webkit.org/show_bug.cgi?id=58216
516
517         No new tests. The SVG tests mask-excessive-malloc.svg and pattern-excessive-malloc.svg exercise this code path.
518
519         * platform/graphics/FloatRect.cpp:
520         (WebCore::enclosingIntRect):
521
522 2011-05-20  Jeremy Noble  <jer.noble@apple.com>
523
524         Reviewed by Darin Adler.
525
526         Video looks squished when animating to full screen.
527         https://bugs.webkit.org/show_bug.cgi?id=61220
528
529         No new tests, because DumpRenderTree does not currently "animate" the full-screen transition.
530
531         There are three issues animating video content to full screen which this patch is meant to
532         address:
533         1) The animation scales between the client sizes of the element before and after full-screen.
534         Because these sizes have different aspect ratios, the video appears "squished" for part of
535         the animation. Instead, we will animate between the content box sizes before and after full
536         screen which, in the case of video now and object-fit content in the future, will have the
537         same aspect ratio before and after full screen.
538         2) Now that we are animating the full-screen video element's content box, the black letterbox
539         bars appear above and below the video (depending on the video's aspect ratio) as soon as the
540         animation begins. This is extremely jarring, so set the background color to clear. The
541         full-screen renderer's background color will serve the same purpose (providing the letterbox
542         background) once the animation completes.
543         3) Now that the letterbox color is gone, the full screen controls can appear to float in thin
544         air beneath the video (again, depending on aspect ratio) during the animation, so to avoid
545         that effect and to make the animation consistent with the old webkitenterfullscreen()
546         animation, we will hide the controls during the animation by adding a new CSS pseudo class
547         -webkit-animating-full-screen-transition.
548
549         Added a new css pseudo-class: -webkit-animating-full-screen.  During the transition animation, this
550         pseudo-class will be applied to the current full-screen element.  Styles have been added to 
551         fullscreenQuickTime.css to hide the video element's built-in controller during the full-screen
552         animation.
553
554         To accomplish this, the ivar tracking whether the full-screen animation is taking place has been moved
555         from the RenderFullScreen renderer, to the current full-screen Document.  Because changing 
556         isAnimatingFullScreen causes style changes, make sure to call recalcStyle on the full-screen element
557         after changing.
558
559         This extra transition caused assertions in HTMLFormControlElement::updateFromElementCallback. A
560         full-screen media control's renderer is disabled during the style recalculation when exiting full
561         screen. This assertion was exposed by the extra recalcStyle() issued during the exit transition, and
562         has been removed.
563
564         * WebCore.exp.in:
565         * css/CSSSelector.cpp:
566         (WebCore::CSSSelector::pseudoId): Add support for new pseudo class -webkit-animate-full-screen-transition.
567         (WebCore::nameToPseudoTypeMap): Ditto.
568         (WebCore::CSSSelector::extractPseudoType): Ditto.
569         * css/CSSSelector.h:
570         * css/CSSStyleSelector.cpp:
571         (WebCore::CSSStyleSelector::SelectorChecker::checkOneSelector): Ditto.
572         * css/fullscreen.css: 
573         (video:-webkit-full-screen): Set full screen video background color to clear.
574         * css/fullscreenQuickTime.css: 
575         (video:-webkit-full-screen::-webkit-media-controls-panel): Set a default opacity transition.
576         (video:-webkit-animating-full-screen::-webkit-media-controls-panel): Set the opacity to 0 and 
577             disable the transition.
578         * dom/Document.cpp:
579         (WebCore::Document::Document):
580         (WebCore::Document::webkitWillEnterFullScreenForElement): Call our new setAnimatingFullScreen function.
581         (WebCore::Document::webkitDidEnterFullScreenForElement): Ditto.
582         (WebCore::Document::webkitWillExitFullScreenForElement): Ditto.
583         (WebCore::Document::webkitDidExitFullScreenForElement): Ditto.
584         (WebCore::Document::isAnimatingFullScreen): Moved here from RenderFullScreen.
585         (WebCore::Document::setAnimatingFullScreen): Ditto.
586         * dom/Document.h:
587         * html/HTMLFormControlElement.cpp: 
588         (WebCore::updateFromElementCallback): Use the Document's isAnimatingFullScreen function.
589         * page/FrameView.cpp:
590         (WebCore::isDocumentRunningFullScreenAnimation): Ditto.
591         * rendering/RenderFullScreen.cpp:
592         * rendering/RenderFullScreen.h:
593         * rendering/RenderLayerCompositor.cpp:
594         (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree): Ditto.
595         (WebCore::RenderLayerCompositor::requiresCompositingForFullScreen): Ditto.
596         * rendering/style/RenderStyleConstants.h:
597
598 2011-05-23  Emil A Eklund  <eae@chromium.org>
599
600         Reviewed by Eric Seidel.
601
602         Change RenderBlock hit testing to use IntPoint instead x,y pair
603         https://bugs.webkit.org/show_bug.cgi?id=61146
604
605         Covered by existing tests.
606
607         * platform/graphics/IntPoint.h:
608         (WebCore::toSize):
609         Add toSize function for converting from point to size.
610
611         * rendering/RenderBlock.cpp:
612         (WebCore::RenderBlock::isPointInOverflowControl):
613         (WebCore::RenderBlock::nodeAtPoint):
614         (WebCore::RenderBlock::hitTestFloats):
615         (WebCore::RenderBlock::hitTestColumns):
616         (WebCore::RenderBlock::hitTestContents):
617         * rendering/RenderBlock.h:
618         Change hit testing code in RenderBlock to use IntPoint.
619
620         * rendering/RenderListBox.cpp:
621         (WebCore::RenderListBox::isPointInOverflowControl):
622         * rendering/RenderListBox.h:
623         Change overridden method to use IntPoint.
624
625 2011-05-23  Mike Reed  <reed@google.com>
626
627         Reviewed by James Robinson.
628
629         Skia: Need to implement GraphicsContext::clipConvexPolygon()
630         https://bugs.webkit.org/show_bug.cgi?id=41311
631
632         No new tests. 
633
634         * platform/graphics/skia/GraphicsContextSkia.cpp:
635         (WebCore::setPathFromConvexPoints):
636         (WebCore::GraphicsContext::drawConvexPolygon):
637         (WebCore::GraphicsContext::clipConvexPolygon):
638
639 2011-05-23  James Simonsen  <simonjam@chromium.org>
640
641         Reviewed by Adam Barth.
642
643         Convert raw pointer to RefPtr.
644         https://bugs.webkit.org/show_bug.cgi?id=61196
645
646         * dom/XMLDocumentParserLibxml2.cpp:
647         (WebCore::XMLDocumentParser::endElementNs):
648         * dom/XMLDocumentParserQt.cpp:
649         (WebCore::XMLDocumentParser::parseEndElement):
650
651 2011-05-23  Ryosuke Niwa  <rniwa@webkit.org>
652
653         Reviewed by Alexey Proskuryakov.
654
655         selectstart is fired for every mouse move
656         https://bugs.webkit.org/show_bug.cgi?id=19489
657
658         Fixed the bug by dispatching selectstart event immediately before modifying selection in
659         handleMousePressEventSingleClick and updateSelectionForMouseDrag.
660
661         Also replaced a boolean EventHandler::m_beganSelectingText by an enum-valued m_selectionInitiationState
662         to retain 3 states:
663         1. HaveNotStartedSelection - Selection has not been set by a mouse drag or a mouse click
664         2. PlacedCaret - A caret was placed by a mouse click, double click, or triple click, and is about
665         to replace selection if a mouse drag never occurs.
666         3. ExtendedSelection - A range selection was set by a mouse click, a double click, a triple click,
667         or a mouse drag; otherwise a caret selection was set by a mouse drag.
668
669         State 1 corresponds to m_beganSelectingText being false and state 3 corresponds to m_beganSelectingText
670         being true. State 2 is used in updateSelectionForMouseDrag to avoid dispatching selectstart twice.
671
672         States 1 and 2 are set by updateSelectionForMouseDownDispatchingSelectStart and state 3 is set by
673         updateSelectionForMouseDrag.
674
675         Test: fast/events/selectstart-by-double-triple-clicks.html
676               fast/events/selectstart-by-drag.html
677               fast/events/selectstart-by-single-click-with-shift.html
678
679         * page/EventHandler.cpp: Removed canMouseDragExtendSelect.
680         (WebCore::EventHandler::EventHandler): Initializes m_selectionInitiationState.
681         (WebCore::dispatchSelectStart): Returns true only if selectstart was successfully fired
682         and default action was not prevented.
683         (WebCore::EventHandler::updateSelectionForMouseDownDispatchingSelectStart): Updates m_selectionInitiationState
684         and modifies the selection if dispatchSelectStart returns true.
685         (WebCore::EventHandler::selectClosestWordFromMouseEvent): Calls updateSelectionForMouseDownDispatchingSelectStart.
686         (WebCore::EventHandler::selectClosestWordOrLinkFromMouseEvent): Ditto.
687         (WebCore::EventHandler::handleMousePressEventDoubleClick):
688         (WebCore::EventHandler::handleMousePressEventTripleClick): Ditto.
689         (WebCore::EventHandler::handleMousePressEventSingleClick): Ditto.
690         (WebCore::canMouseDownStartSelect): No longer dispatches startselect; also renamed from
691         EventHandler::canMouseDownStartSelect.
692         (WebCore::EventHandler::handleMousePressEvent): No longer calls canMouseDragExtendSelect.
693         (WebCore::EventHandler::handleMouseDraggedEvent):
694         (WebCore::EventHandler::updateSelectionForMouseDrag): Exit early if m_selectionInitiationState is
695         HaveNotStartedSelection and dispatchSelectStart returns false. Since setSelectionIfPossible dispatches
696         selectstart event before assigning PlacedCaret or ExtendedSelection to m_selectionInitiationState,
697         there is no need to dispatch event for those two cases.
698         (WebCore::EventHandler::handleMouseReleaseEvent):
699         * page/EventHandler.h: Removed canMouseDownStartSelect and canMouseDragExtendSelect from EventHandler
700         and added setSelectionIfPossible.
701
702 2011-05-23  Adam Klein  <adamk@chromium.org>
703
704         Reviewed by Jian Li.
705
706         [fileapi] Add a File::createWithName method to avoid obfuscated filename leakage from FileEntry.file() method
707         https://bugs.webkit.org/show_bug.cgi?id=61155
708
709         Covered by existing tests: fast/filesystem/file-from-file-entry.html
710                                    fast/filesystem/workers/file-from-file-entry.html
711                                    fast/filesystem/workers/file-from-file-entry-sync.html
712
713         * fileapi/DOMFileSystem.cpp:
714         (WebCore::DOMFileSystem::createFile): Updated to call createWithName().
715         * fileapi/DOMFileSystemSync.cpp:
716         (WebCore::DOMFileSystemSync::createFile): Updated to call createWithName().
717         * fileapi/File.cpp:
718         (WebCore::createBlobDataForFile): Added an optional name argument to fix MIME type lookup.
719         (WebCore::File::createWithRelativePath): Renamed from create() for consistency with new method.
720         (WebCore::File::File):
721         * fileapi/File.h:
722         (WebCore::File::createWithName):
723         * html/FileInputType.cpp:
724         (WebCore::FileInputType::setFileList): Updated the single caller of File::createWithRelativePath().
725
726 2011-05-23  Adrienne Walker  <enne@google.com>
727
728         Reviewed by James Robinson.
729
730         [chromium] Fix division by zero in TilingData for boundary case texture sizes
731         https://bugs.webkit.org/show_bug.cgi?id=61164
732
733         * platform/graphics/gpu/TilingData.cpp:
734         (WebCore::TilingData::tileXIndexFromSrcCoord):
735         (WebCore::TilingData::tileYIndexFromSrcCoord):
736
737 2011-05-23  Adam Barth  <abarth@webkit.org>
738
739         Reviewed by Eric Seidel.
740
741         Update ImageDecoder::create to match sniffing spec
742         https://bugs.webkit.org/show_bug.cgi?id=47683
743
744         This change is difficult to test.  We're making this change to comply
745         with standards even if the change is difficult to observe.  (This patch
746         also causes us to match Firefox.)
747
748         Test: fast/images/busted-oval-does-not-render.html
749
750         * platform/image-decoders/ImageDecoder.cpp:
751
752 2011-05-23  Ruben  <chromium@hybridsource.org>
753
754         Reviewed by Tony Chang.
755
756         Chromium gyp patch to use new POSIX defines toolkit_uses_gtk and os_posix
757         https://bugs.webkit.org/show_bug.cgi?id=61219
758
759         No new tests, just changing gyp defines.
760
761         * WebCore.gyp/WebCore.gyp:
762
763 2011-05-23  Abhishek Arya  <inferno@chromium.org>
764
765         Reviewed by Simon Fraser.
766
767         Terminate css color parsing on integers which are not followed
768         by a terminator.
769         https://bugs.webkit.org/show_bug.cgi?id=61293
770
771         Test: fast/css/parse-color-int-or-percent-crash.html
772
773         * css/CSSParser.cpp:
774         (WebCore::parseColorIntOrPercentage):
775
776 2011-05-20  Ryosuke Niwa  <rniwa@webkit.org>
777
778         Reviewed by Enrica Casucci.
779
780         REGRESSION(r84311): WebKit copies too much styles when copying
781         https://bugs.webkit.org/show_bug.cgi?id=60914
782
783         The bug was caused by WebKit's cloning node hierarchy up until the node that has background color.
784         Fixed the bug by not cloning background color and adding the effective background color to the wrapping
785         style span.
786
787         Tests: editing/pasteboard/do-no-clone-unnecessary-styles-2.html
788                editing/pasteboard/do-no-clone-unnecessary-styles.html
789
790         * editing/EditingStyle.cpp:
791         (WebCore::cssValueToRGBA): Extracted from getRGBAFontColor.
792         (WebCore::getRGBAFontColor): Moved.
793         (WebCore::rgbaBackgroundColorInEffect): Added.
794         (WebCore::EditingStyle::init): Added support for InheritablePropertiesAndBackgroundColorInEffect.
795         (WebCore::EditingStyle::prepareToApplyAt): Include the effective background color at the given position.
796         Also remove the background color property when the effective background color is equal to the background
797         color property (in terms of RGBA value) of the editing style.
798         (WebCore::hasTransparentBackgroundColor): Moved from Editor class.
799         (WebCore::backgroundColorInEffect): Extracted from Editor::selectionStartCSSPropertyValue.
800         * editing/EditingStyle.h: Added prototypes for hasTransparentBackgroundColor and backgroundColorInEffect.
801         * editing/Editor.cpp:
802         (WebCore::Editor::selectionStartCSSPropertyValue): Calls backgroundColorInEffect.
803         * editing/Editor.h: Removed hasTransparentBackgroundColor.
804         * editing/markup.cpp:
805         (WebCore::isElementPresentational): Reverted r85090 and r84311.
806         (WebCore::createMarkup): Include the background color in effect when computing the editing style.
807
808 2011-05-23  Roland Steiner  <rolandsteiner@chromium.org>
809
810         Reviewed by Dimitri Glazkov.
811
812         Update node list cache count on the containing TreeScope rather than the Document
813         https://bugs.webkit.org/show_bug.cgi?id=59983
814
815         Change code to call add/removeNodeListCache() and hasNodeListCaches() on the proper tree scope.
816         Move updating of the node list cache count from setDocument() to setTreeScopeRecursively().
817         Make setDocument() and setDocumentRecursively() private.
818
819         No new tests. (refactoring)
820
821         * dom/ContainerNode.cpp:
822         (WebCore::ContainerNode::childrenChanged):
823         * dom/Node.cpp:
824         (WebCore::Node::~Node):
825         (WebCore::Node::setDocument):
826         (WebCore::Node::setTreeScopeRecursively):
827         (WebCore::Node::childNodes):
828         (WebCore::Node::registerDynamicNodeList):
829         (WebCore::Node::unregisterDynamicNodeList):
830         (WebCore::Node::notifyLocalNodeListsAttributeChanged):
831         (WebCore::Node::notifyLocalNodeListsChildrenChanged):
832         (WebCore::Node::getElementsByTagName):
833         (WebCore::Node::getElementsByTagNameNS):
834         (WebCore::Node::getElementsByName):
835         (WebCore::Node::getElementsByClassName):
836         * dom/Node.h:
837         * html/HTMLFormControlElement.cpp:
838         (WebCore::HTMLFormControlElement::labels):
839
840 2011-05-23  Yury Semikhatsky  <yurys@chromium.org>
841
842         Reviewed by Pavel Feldman.
843
844         [Chromium] Web Inspector: provide initial implementation of worker inspector transport
845         https://bugs.webkit.org/show_bug.cgi?id=60267
846
847         All methods of WorkerContextInspectorProxy are inlined in WorkerContextProxy and
848         the class itself is removed. Messages from worker inspector to page inspector
849         are sent by means of WorkerReportingProxy.
850
851         * GNUmakefile.list.am:
852         * WebCore.gypi:
853         * WebCore.vcproj/WebCore.vcproj:
854         * WebCore.xcodeproj/project.pbxproj:
855         * inspector/InspectorWorkerAgent.cpp:
856         (WebCore::InspectorWorkerAgent::WorkerFrontendChannel::WorkerFrontendChannel):
857         (WebCore::InspectorWorkerAgent::WorkerFrontendChannel::proxy):
858         (WebCore::InspectorWorkerAgent::WorkerFrontendChannel::dispatchMessageFromWorker):
859         (WebCore::InspectorWorkerAgent::sendMessageToWorker):
860         (WebCore::InspectorWorkerAgent::didStartWorkerContext):
861         * inspector/InspectorWorkerAgent.h:
862         * inspector/WorkerInspectorController.cpp:
863         (WebCore::WorkerInspectorController::connectFrontend):
864         (WebCore::WorkerInspectorController::disconnectFrontend):
865         * inspector/WorkerInspectorController.h:
866         * workers/DefaultSharedWorkerRepository.cpp:
867         (WebCore::SharedWorkerProxy::postMessageToPageInspector):
868         * workers/WorkerContextInspectorProxy.h: Removed.
869         * workers/WorkerContextProxy.h:
870         (WebCore::WorkerContextProxy::PageInspector::~PageInspector):
871         (WebCore::WorkerContextProxy::connectToInspector):
872         (WebCore::WorkerContextProxy::disconnectFromInspector):
873         (WebCore::WorkerContextProxy::sendMessageToInspector):
874         * workers/WorkerMessagingProxy.cpp:
875         (WebCore::WorkerMessagingProxy::postMessageToPageInspector):
876         * workers/WorkerMessagingProxy.h:
877         * workers/WorkerReportingProxy.h:
878
879 2011-05-23  Sheriff Bot  <webkit.review.bot@gmail.com>
880
881         Unreviewed, rolling out r87070.
882         http://trac.webkit.org/changeset/87070
883         https://bugs.webkit.org/show_bug.cgi?id=61285
884
885         broke resource-parameters.html on win, weird failures on wk2
886         (Requested by caseq on #webkit).
887
888         * inspector/front-end/HAREntry.js:
889         (WebInspector.HAREntry.prototype.build):
890         (WebInspector.HAREntry.prototype._buildRequest):
891         (WebInspector.HAREntry.prototype._buildResponse):
892         (WebInspector.HAREntry.prototype._buildContent):
893         (WebInspector.HAREntry.prototype._buildCookie):
894         (WebInspector.HAREntry.prototype._interval):
895         (WebInspector.HARLog.prototype.build):
896         * inspector/front-end/Resource.js:
897         (WebInspector.Resource.prototype.set requestHeaders):
898         (WebInspector.Resource.prototype.get requestHeadersText):
899         (WebInspector.Resource.prototype.set requestHeadersText):
900         (WebInspector.Resource.prototype.get requestHeadersSize):
901         (WebInspector.Resource.prototype.set responseHeaders):
902         (WebInspector.Resource.prototype.get responseHeadersText):
903         (WebInspector.Resource.prototype.set responseHeadersText):
904         (WebInspector.Resource.prototype.get responseHeadersSize):
905         (WebInspector.Resource.prototype._headersSize):
906
907 2011-05-18  Pavel Podivilov  <podivilov@chromium.org>
908
909         Reviewed by Yury Semikhatsky.
910
911         Web Inspector: source mapping for pretty-printed scripts is sometimes inaccurate after indented comments.
912         https://bugs.webkit.org/show_bug.cgi?id=61037
913
914         * inspector/front-end/JavaScriptFormatter.js:
915         (FormattedContentBuilder.prototype.addToken):
916         (FormattedContentBuilder.prototype._addComment):
917         (FormattedContentBuilder.prototype._addText):
918         (FormattedContentBuilder.prototype._addMappingIfNeeded):
919
920 2011-05-23  Mike West  <mkwst@chromium.org>
921
922         Reviewed by Yury Semikhatsky.
923
924         Web Inspector: Missing fields in HAR
925         https://bugs.webkit.org/show_bug.cgi?id=58127
926         
927         Specifically, this patch adds:
928         - entry.request.httpVersion
929         - entry.request.headersSize
930         - entry.request.bodySize
931         - entry.response.httpVersion
932         - entry.response.headersSize
933         - entry.response.bodySize
934         - entry.response.content.compression
935         
936         Tests: http/tests/inspector/resource-har-conversion.html
937                http/tests/inspector/resource-har-headers.html
938                http/tests/inspector/resource-parameters.html
939                http/tests/inspector/network/network-size.html
940
941         * inspector/front-end/HAREntry.js:
942         (WebInspector.HAREntry.prototype.build):
943         (WebInspector.HAREntry.prototype._buildRequest):
944         (WebInspector.HAREntry.prototype._buildResponse):
945         (WebInspector.HAREntry.prototype._buildContent):
946         (WebInspector.HAREntry.prototype._buildCookie):
947         (WebInspector.HAREntry.prototype._interval):
948         (WebInspector.HAREntry.prototype.get requestBodySize):
949         (WebInspector.HAREntry.prototype.get responseBodySize):
950         (WebInspector.HAREntry.prototype.get responseCompression):
951         (WebInspector.HARLog.prototype.build):
952         * inspector/front-end/Resource.js:
953         (WebInspector.Resource.prototype.set requestHeaders):
954         (WebInspector.Resource.prototype.get requestHeadersText):
955         (WebInspector.Resource.prototype.set requestHeadersText):
956         (WebInspector.Resource.prototype.get requestHeadersSize):
957         (WebInspector.Resource.prototype.get requestHttpVersion):
958         (WebInspector.Resource.prototype.set responseHeaders):
959         (WebInspector.Resource.prototype.get responseHeadersText):
960         (WebInspector.Resource.prototype.set responseHeadersText):
961         (WebInspector.Resource.prototype.get responseHeadersSize):
962         (WebInspector.Resource.prototype.get responseHttpVersion):
963
964 2011-05-23  Andrey Kosyakov  <caseq@chromium.org>
965
966         Reviewed by Yury Semikhatsky.
967
968         Web Inspector: keyboard shortcut panel is 1px too short
969         https://bugs.webkit.org/show_bug.cgi?id=61242
970
971         Fixed bottom margin of attached helpscreen so it's glued to status bar.
972
973         * inspector/front-end/helpScreen.css:
974         (body.attached .help-window-outer):
975
976 2011-05-23  Kent Tamura  <tkent@chromium.org>
977
978         Reviewed by Dimitri Glazkov.
979
980         Change text-based <input> types to the new shadow DOM model
981         https://bugs.webkit.org/show_bug.cgi?id=54179
982
983         By this change, text field inputs and textareas have one extra
984         shadow node at the root of shadow trees.
985         e.g. Before the change:
986           <textarea> --(shadow-connection)-- <div> -- ...
987         After the change:
988           <textarea> --(shadow-connection)-- {#shadow-root} -- <div> -- ...
989
990         The goals of this change are
991         - Change to the new shadow DOM model, and
992         - Minimize the patch size.
993
994         We should use shadowPseudoId() in the new shadow DOM model, but the
995         shadow elements in this patch don't use it in order to reduce the patch
996         size.
997
998         Note: This is a re-landing for r87014 with a small fix of
999         Element::removeShadowRoot().
1000         
1001         * css/html.css:
1002         (input::-webkit-inner-spin-button):
1003          Add vertical-align in order to avoid the button affect the baseline.
1004         (input::-webkit-outer-spin-button): ditto.
1005         (input::-webkit-input-speech-button): ditto.
1006         * dom/Element.cpp:
1007         (WebCore::Element::recalcStyle): Calls styleForRenderer() so that a
1008          subclass of Element can override it.
1009         (WebCore::Element::remvoeShadowRoot):
1010          Fix a wrong parameter for willRemoveDOMNode().
1011         (WebCore::Element::isSpellCheckingEnabled):
1012          Handle ShadowRoot, which is not an Element.
1013         * dom/Node.cpp:
1014           Add utility functions for editing code.
1015         (WebCore::Node::nonBoundaryShadowTreeRootNode):
1016         (WebCore::Node::nonShadowBoundaryParentNode):
1017         * dom/Node.h: Declare them.
1018         * dom/Position.cpp:
1019          - Add some assertions about ShadowRoot
1020          - Replace parentNode() with nonShadowBoundaryParentNode()
1021         Because input/textarea shadow structures are changed.
1022         (WebCore::Position::Position):
1023         (WebCore::Position::containerNode):
1024         (WebCore::Position::parentAnchoredEquivalent):
1025         (WebCore::Position::previous):
1026         (WebCore::Position::next):
1027         (WebCore::Position::parentEditingBoundary):
1028         (WebCore::Position::atStartOfTree):
1029         (WebCore::Position::atEndOfTree):
1030         * dom/Position.h: ditto.
1031         (WebCore::positionInParentBeforeNode):
1032         (WebCore::positionInParentAfterNode):
1033         * editing/CompositeEditCommand.cpp: ditto.
1034         (WebCore::CompositeEditCommand::insertNodeAfter):
1035         (WebCore::CompositeEditCommand::removeNode):
1036         * editing/Editor.cpp:
1037         (WebCore::Editor::findString): ditto.
1038         * editing/FrameSelection.cpp:
1039         (WebCore::FrameSelection::selectAll): Inline shadowTreeRootNode() calls.
1040         * editing/FrameSelection.h:
1041           Remove shadowTreeRootNode(). It is used only by FrameSelection::selectAll().
1042         * editing/InsertParagraphSeparatorCommand.cpp:
1043         (WebCore::InsertParagraphSeparatorCommand::doApply): Use nonShadowBoundaryParentNode()
1044         * editing/ReplaceSelectionCommand.cpp:
1045         (WebCore::ReplacementFragment::removeNode): ditto.
1046         (WebCore::ReplacementFragment::insertNodeBefore): ditto.
1047         * editing/VisibleSelection.cpp:
1048           Rename shadowTreeRootNode() to nonBoundaryShadowTreeRootNode(), and it reutrns
1049           a child node of ShadowRoot.
1050         (WebCore::VisibleSelection::isAll):
1051         (WebCore::VisibleSelection::adjustSelectionToAvoidCrossingShadowBoundaries):
1052         (WebCore::VisibleSelection::nonBoundaryShadowTreeRootNode):
1053         * editing/VisibleSelection.h: ditto.
1054         * editing/htmlediting.cpp: Add assertions.
1055         (WebCore::visiblePositionBeforeNode):
1056         (WebCore::visiblePositionAfterNode):
1057         * html/HTMLInputElement.cpp:
1058         (WebCore::HTMLInputElement::create): Calls createShadowSubtree().
1059         (WebCore::HTMLInputElement::createShadowSubtree):
1060           Calls InputType::createShadowSubTree().
1061         (WebCore::HTMLInputElement::innerTextElement):
1062           Accessor of a shadow node. This is used by RenderTextControlSingleLine.
1063         (WebCore::HTMLInputElement::innerBlockElement): ditto.
1064         (WebCore::HTMLInputElement::innerSpinButtonElement): ditto.
1065         (WebCore::HTMLInputElement::outerSpinButtonElement): ditto.
1066         (WebCore::HTMLInputElement::resultsButtonElement): ditto.
1067         (WebCore::HTMLInputElement::cancelButtonElement): ditto.
1068         (WebCore::HTMLInputElement::speechButtonElement): ditto.
1069         (WebCore::HTMLInputElement::parseMappedAttribute):
1070           Rebuild shadow trees because x-webkit-speech attribute affects it.
1071         * html/HTMLInputElement.h: Add declarations.
1072         * html/HTMLIsIndexElement.cpp:
1073         (WebCore::HTMLIsIndexElement::create): Calls createShadowSubtree().
1074         * html/HTMLTextAreaElement.cpp:
1075         (WebCore::HTMLTextAreaElement::create): Calls createShadowSubtree().
1076         (WebCore::HTMLTextAreaElement::createShadowSubtree): Added.
1077         * html/HTMLTextAreaElement.h: Declare createShadowSubtree().
1078         * html/InputType.h: Add default implementations of accessors.
1079         (WebCore::InputType::innerBlockElement):
1080         (WebCore::InputType::innerTextElement):
1081         (WebCore::InputType::innerSpinButtonElement):
1082         (WebCore::InputType::outerSpinButtonElement):
1083         (WebCore::InputType::resultsButtonElement):
1084         (WebCore::InputType::cancelButtonElement):
1085         (WebCore::InputType::speechButtonElement):
1086         * html/SearchInputType.cpp:
1087         (WebCore::SearchInputType::SearchInputType): Initializes new data members.
1088         (WebCore::SearchInputType::createShadowSubtree):
1089           Moved from RenderTextControlSingleLine.
1090         (WebCore::SearchInputType::destroyShadowSubtree): Clear element references.
1091         * html/SearchInputType.h: Add declarations.
1092         (WebCore::SearchInputType::innerBlockElement):
1093         (WebCore::SearchInputType::resultsButtonElement):
1094         (WebCore::SearchInputType::cancelButtonElement):
1095         * html/TextFieldInputType.cpp:
1096         (WebCore::TextFieldInputType::TextFieldInputType):
1097           Initializes new data members.
1098         (WebCore::TextFieldInputType::createShadowSubtree):
1099           Moved from RenderTextControlSingleLine.
1100         (WebCore::TextFieldInputType::destroyShadowSubtree): Clear element references.
1101         * html/TextFieldInputType.h: Add declarations.
1102         (WebCore::TextFieldInputType::innerTextElement):
1103         (WebCore::TextFieldInputType::innerSpinButtonElement):
1104         (WebCore::TextFieldInputType::outerSpinButtonElement):
1105         (WebCore::TextFieldInputType::speechButtonElement):
1106         (WebCore::TextFieldInputType::setInnerTextElement):
1107         (WebCore::TextFieldInputType::setSpeechButtonElement):
1108         * html/shadow/TextControlInnerElements.cpp:
1109         (WebCore::TextControlInnerElement::TextControlInnerElement):
1110           Remove shadowParent parameter. It is unnecessary because we switch to
1111           new shadow model.
1112         (WebCore::TextControlInnerElement::create):
1113           Change the parameter type to Document.
1114         (WebCore::TextControlInnerElement::styleForRenderer):
1115           Override this in order to set style by
1116           RenderTextControlSingleLine::createInnerBlockStyle().
1117         (WebCore::TextControlInnerTextElement::TextControlInnerTextElement):
1118           Remove shadowParent parameter.
1119           Inherit HTMLDivElement, not TextControlInnerElement.
1120         (WebCore::TextControlInnerTextElement::create): Remove shadowParent parameter.
1121         (WebCore::TextControlInnerTextElement::styleForRenderer):
1122           Override this in order to set style by
1123           RenderTextControlSingleLine::createInnerTextStyle().
1124         (WebCore::SearchFieldResultsButtonElement::SearchFieldResultsButtonElement):
1125           Inherit HTMLDivElement, not TextControlInnerElement.
1126         (WebCore::SearchFieldResultsButtonElement::styleForRenderer):
1127           Override this in order to set style by
1128           RenderTextControlSingleLine::createResultButtonStyle().
1129         (WebCore::SearchFieldCancelButtonElement::SearchFieldCancelButtonElement):
1130           Inherit HTMLDivElement, not TextControlInnerElement.
1131         (WebCore::SearchFieldCancelButtonElement::styleForRenderer):
1132           Override this in order to set style by
1133           RenderTextControlSingleLine::createCancelButtonStyle().
1134         (WebCore::SearchFieldCancelButtonElement::detach):
1135           Update for the parent class change.
1136         (WebCore::SpinButtonElement::SpinButtonElement):
1137           - Change the parameter type: shadowParent -> Document
1138           - Add the inner flag
1139           - Inherit HTMLDivElement, not TextControlInnerElement.
1140         (WebCore::SpinButtonElement::createInner): Introduce a new factory
1141           method to hide a bool parameter of the constructor.
1142         (WebCore::SpinButtonElement::createOuter): ditto.
1143         (WebCore::SpinButtonElement::styleForRenderer):
1144           Override this in order to set style by
1145           RenderTextControlSingleLine::createInnerSpinButtonStyle() or
1146           createOuterSpinButtonStyle().
1147         (WebCore::SpinButtonElement::detach): Update for the parent class change.
1148         (WebCore::SpinButtonElement::setHovered): ditto.
1149         (WebCore::InputFieldSpeechButtonElement::InputFieldSpeechButtonElement):
1150           - Change the parameter type: shadowParent -> Document
1151           - Inherit HTMLDivElement, not TextControlInnerElement.
1152           - Do not register this as a speech input listener here.
1153         (WebCore::InputFieldSpeechButtonElement::create):
1154           Update for the parameter change.
1155         (WebCore::InputFieldSpeechButtonElement::defaultEventHandler):
1156           Do not handle click event if listener registration is not done.
1157         (WebCore::InputFieldSpeechButtonElement::attach):
1158           Register this as a speech input listener.
1159         (WebCore::InputFieldSpeechButtonElement::detach):
1160           Update for the parent class change.
1161         (WebCore::InputFieldSpeechButtonElement::styleForRenderer):
1162           Override this in order to set style by
1163           RenderTextControlSingleLine::createSpeechButtonStyle().
1164         * html/shadow/TextControlInnerElements.h:
1165         (WebCore::TextControlInnerTextElement::isMouseFocusable):
1166           Add this because the class is not a subclass of TextControllInnerElement.
1167         (WebCore::SearchFieldResultsButtonElement::isMouseFocusable): ditto.
1168         (WebCore::SearchFieldCancelButtonElement::isMouseFocusable): ditto.
1169         (WebCore::SpinButtonElement::isMouseFocusable): ditto.
1170         (WebCore::InputFieldSpeechButtonElement::isMouseFocusable): ditto.
1171         * rendering/RenderTextControl.cpp:
1172         (WebCore::RenderTextControl::~RenderTextControl): Remove unnecessary code.
1173         (WebCore::RenderTextControl::styleDidChange):
1174           innerTextElement can have no renderer.
1175           Explicitly call setNeedsStyleRecals() for innerTextElement. It is
1176           needed for LayoutTests/editing/selection/select-across-readonly-input-*.html.
1177         (WebCore::RenderTextControl::textBlockWidth): Member data -> function
1178         (WebCore::RenderTextControl::updateFromElement): ditto.
1179         (WebCore::RenderTextControl::setInnerTextValue): ditto.
1180         (WebCore::RenderTextControl::hasVisibleTextArea): ditto.
1181         (WebCore::RenderTextControl::isSelectableElement): ditto.
1182         (WebCore::RenderTextControl::selection): ditto.
1183         (WebCore::RenderTextControl::visiblePositionForIndex): ditto.
1184         (WebCore::RenderTextControl::indexForVisiblePosition): ditto.
1185         (WebCore::RenderTextControl::text): ditto.
1186         (WebCore::RenderTextControl::textWithHardLineBreaks): ditto.
1187         (WebCore::RenderTextControl::computeLogicalHeight): ditto.
1188         (WebCore::RenderTextControl::hitInnerTextElement): ditto.
1189         (WebCore::RenderTextControl::forwardEvent): ditto.
1190         (WebCore::RenderTextControl::computePreferredLogicalWidths): ditto.
1191         * rendering/RenderTextControl.h:
1192           - Make m_innerText virtual function.
1193           - Make createInnerTextStyle() public in order that
1194             TextControlInnerElements can call it.
1195         * rendering/RenderTextControlMultiLine.cpp:
1196         (WebCore::RenderTextControlMultiLine::innerTextElement): Added.
1197         (WebCore::RenderTextControlMultiLine::updateFromElement):
1198           Remove unnecessary createSubtreeIfNeeded() call.
1199         * rendering/RenderTextControlMultiLine.h: Add a declaration.
1200         * rendering/RenderTextControlSingleLine.cpp:
1201         (WebCore::RenderTextControlSingleLine::~RenderTextControlSingleLine):
1202           Remove unnecessary code.
1203         (WebCore::RenderTextControlSingleLine::innerTextElement): Added.
1204         (WebCore::RenderTextControlSingleLine::innerBlockElement): Added.
1205         (WebCore::RenderTextControlSingleLine::innerSpinButtonElement): Added.
1206         (WebCore::RenderTextControlSingleLine::outerSpinButtonElement): Added.
1207         (WebCore::RenderTextControlSingleLine::resultsButtonElement): Added.
1208         (WebCore::RenderTextControlSingleLine::cancelButtonElement): Added.
1209         (WebCore::RenderTextControlSingleLine::speechButtonElement): Added.
1210         (WebCore::RenderTextControlSingleLine::textBaseStyle): Data member -> function
1211         (WebCore::RenderTextControlSingleLine::subtreeHasChanged): ditto.
1212         (WebCore::RenderTextControlSingleLine::layout): ditto.
1213         (WebCore::RenderTextControlSingleLine::nodeAtPoint): ditto.
1214         (WebCore::RenderTextControlSingleLine::forwardEvent): ditto.
1215         (WebCore::RenderTextControlSingleLine::styleDidChange): ditto.
1216         (WebCore::RenderTextControlSingleLine::hasControlClip): ditto.
1217         (WebCore::RenderTextControlSingleLine::controlClipRect): ditto.
1218         (WebCore::RenderTextControlSingleLine::textBlockWidth): ditto.
1219         (WebCore::RenderTextControlSingleLine::decorationWidthRight): ditto.
1220         (WebCore::RenderTextControlSingleLine::preferredContentWidth): ditto.
1221         (WebCore::RenderTextControlSingleLine::preferredDecorationWidthRight): ditto.
1222         (WebCore::RenderTextControlSingleLine::adjustControlHeightBasedOnLineHeight): ditto.
1223         (WebCore::RenderTextControlSingleLine::updateFromElement):
1224           ditto, and remove unnecessary createSubtreeIfNeeded() call.
1225         (WebCore::RenderTextControlSingleLine::createInnerTextStyle):
1226           Data member -> function
1227         (WebCore::RenderTextControlSingleLine::updateCancelButtonVisibility): ditto.
1228         (WebCore::RenderTextControlSingleLine::clientPaddingLeft): ditto.
1229         (WebCore::RenderTextControlSingleLine::clientPaddingRight): ditto.
1230         (WebCore::RenderTextControlSingleLine::textBlockInsetTop): ditto.
1231         * rendering/RenderTextControlSingleLine.h:
1232           Add declarations, and remove unnecessary data members.
1233
1234 2011-05-19  Vitaly Repeshko  <vitalyr@chromium.org>
1235
1236         Reviewed by Adam Barth.
1237
1238         [V8] Explicitly mark objects with complex GC rules.
1239         https://bugs.webkit.org/show_bug.cgi?id=61131
1240
1241         From the GC point view there are two kinds of objects: the ones
1242         that may participate in object grouping (i.e. their lifetime
1243         depends on other objects) and the ones that never participate in
1244         grouping (independent). V8 added support for marking persistent
1245         handles as independent so that the GC can process the objects they
1246         hold faster. The motivating use case here is typed arrays.
1247
1248         This patch adds V8-specific inherited IDL attribute
1249         V8DependentLifetime to types used in V8GCController, which is
1250         exactly the set of types with object lifetimes depending on other
1251         objects. The handles for the types that are not marked with the
1252         new attribute can be marked as independent and GC-ed faster.
1253
1254         * bindings/scripts/CodeGeneratorV8.pm: Added proccessing of the new attribute.
1255
1256         Updated test output:
1257         * bindings/scripts/test/V8/V8TestInterface.cpp:
1258         (WebCore::V8TestInterface::wrapSlow):
1259         * bindings/scripts/test/V8/V8TestInterface.h:
1260         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
1261         (WebCore::V8TestMediaQueryListListener::wrapSlow):
1262         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
1263         * bindings/scripts/test/V8/V8TestObj.cpp:
1264         (WebCore::V8TestObj::wrapSlow):
1265         * bindings/scripts/test/V8/V8TestObj.h:
1266         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
1267         (WebCore::V8TestSerializedScriptValueInterface::wrapSlow):
1268         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
1269
1270         Added the new attribute:
1271         * css/CSSRule.idl:
1272         * css/CSSRuleList.idl:
1273         * css/CSSStyleDeclaration.idl:
1274         * css/CSSValue.idl:
1275         * css/StyleSheet.idl:
1276         * css/StyleSheetList.idl:
1277         * dom/DOMImplementation.idl:
1278         * dom/Node.idl:
1279
1280 2011-05-23  Sheriff Bot  <webkit.review.bot@gmail.com>
1281
1282         Unreviewed, rolling out r87014, r87016, and r87017.
1283         http://trac.webkit.org/changeset/87014
1284         http://trac.webkit.org/changeset/87016
1285         http://trac.webkit.org/changeset/87017
1286         https://bugs.webkit.org/show_bug.cgi?id=61266
1287
1288         It made more tests assert (Requested by Ossy on #webkit).
1289
1290         * css/html.css:
1291         (input::-webkit-inner-spin-button):
1292         (input::-webkit-outer-spin-button):
1293         (input::-webkit-input-speech-button):
1294         * dom/Element.cpp:
1295         (WebCore::Element::recalcStyle):
1296         (WebCore::Element::isSpellCheckingEnabled):
1297         * dom/Node.cpp:
1298         * dom/Node.h:
1299         * dom/Position.cpp:
1300         (WebCore::Position::Position):
1301         (WebCore::Position::containerNode):
1302         (WebCore::Position::parentAnchoredEquivalent):
1303         (WebCore::Position::previous):
1304         (WebCore::Position::next):
1305         (WebCore::Position::parentEditingBoundary):
1306         (WebCore::Position::atStartOfTree):
1307         (WebCore::Position::atEndOfTree):
1308         * dom/Position.h:
1309         (WebCore::positionInParentBeforeNode):
1310         (WebCore::positionInParentAfterNode):
1311         * editing/CompositeEditCommand.cpp:
1312         (WebCore::CompositeEditCommand::insertNodeAfter):
1313         (WebCore::CompositeEditCommand::removeNode):
1314         * editing/Editor.cpp:
1315         (WebCore::Editor::findString):
1316         * editing/FrameSelection.cpp:
1317         (WebCore::FrameSelection::selectAll):
1318         * editing/FrameSelection.h:
1319         (WebCore::FrameSelection::shadowTreeRootNode):
1320         * editing/InsertParagraphSeparatorCommand.cpp:
1321         (WebCore::InsertParagraphSeparatorCommand::doApply):
1322         * editing/ReplaceSelectionCommand.cpp:
1323         (WebCore::ReplacementFragment::removeNode):
1324         (WebCore::ReplacementFragment::insertNodeBefore):
1325         * editing/VisibleSelection.cpp:
1326         (WebCore::VisibleSelection::isAll):
1327         (WebCore::VisibleSelection::adjustSelectionToAvoidCrossingShadowBoundaries):
1328         (WebCore::VisibleSelection::shadowTreeRootNode):
1329         * editing/VisibleSelection.h:
1330         * editing/htmlediting.cpp:
1331         (WebCore::visiblePositionBeforeNode):
1332         (WebCore::visiblePositionAfterNode):
1333         * html/HTMLInputElement.cpp:
1334         (WebCore::HTMLInputElement::create):
1335         (WebCore::HTMLInputElement::parseMappedAttribute):
1336         * html/HTMLInputElement.h:
1337         * html/HTMLIsIndexElement.cpp:
1338         (WebCore::HTMLIsIndexElement::create):
1339         * html/HTMLTextAreaElement.cpp:
1340         (WebCore::HTMLTextAreaElement::create):
1341         * html/HTMLTextAreaElement.h:
1342         * html/InputType.h:
1343         * html/SearchInputType.cpp:
1344         * html/SearchInputType.h:
1345         (WebCore::SearchInputType::SearchInputType):
1346         * html/TextFieldInputType.cpp:
1347         * html/TextFieldInputType.h:
1348         (WebCore::TextFieldInputType::TextFieldInputType):
1349         * html/shadow/TextControlInnerElements.cpp:
1350         (WebCore::TextControlInnerElement::TextControlInnerElement):
1351         (WebCore::TextControlInnerElement::create):
1352         (WebCore::TextControlInnerElement::attachInnerElement):
1353         (WebCore::TextControlInnerElement::detach):
1354         (WebCore::TextControlInnerTextElement::TextControlInnerTextElement):
1355         (WebCore::TextControlInnerTextElement::create):
1356         (WebCore::SearchFieldResultsButtonElement::SearchFieldResultsButtonElement):
1357         (WebCore::SearchFieldCancelButtonElement::SearchFieldCancelButtonElement):
1358         (WebCore::SearchFieldCancelButtonElement::detach):
1359         (WebCore::SpinButtonElement::SpinButtonElement):
1360         (WebCore::SpinButtonElement::create):
1361         (WebCore::SpinButtonElement::detach):
1362         (WebCore::SpinButtonElement::setHovered):
1363         (WebCore::InputFieldSpeechButtonElement::InputFieldSpeechButtonElement):
1364         (WebCore::InputFieldSpeechButtonElement::create):
1365         (WebCore::InputFieldSpeechButtonElement::defaultEventHandler):
1366         (WebCore::InputFieldSpeechButtonElement::detach):
1367         * html/shadow/TextControlInnerElements.h:
1368         * rendering/RenderTextControl.cpp:
1369         (WebCore::RenderTextControl::~RenderTextControl):
1370         (WebCore::RenderTextControl::styleDidChange):
1371         (WebCore::RenderTextControl::setInnerTextStyle):
1372         (WebCore::RenderTextControl::createSubtreeIfNeeded):
1373         (WebCore::RenderTextControl::textBlockWidth):
1374         (WebCore::RenderTextControl::updateFromElement):
1375         (WebCore::RenderTextControl::setInnerTextValue):
1376         (WebCore::RenderTextControl::hasVisibleTextArea):
1377         (WebCore::RenderTextControl::isSelectableElement):
1378         (WebCore::RenderTextControl::selection):
1379         (WebCore::RenderTextControl::visiblePositionForIndex):
1380         (WebCore::RenderTextControl::indexForVisiblePosition):
1381         (WebCore::RenderTextControl::text):
1382         (WebCore::RenderTextControl::textWithHardLineBreaks):
1383         (WebCore::RenderTextControl::computeLogicalHeight):
1384         (WebCore::RenderTextControl::hitInnerTextElement):
1385         (WebCore::RenderTextControl::forwardEvent):
1386         (WebCore::RenderTextControl::computePreferredLogicalWidths):
1387         (WebCore::RenderTextControl::innerTextElement):
1388         * rendering/RenderTextControl.h:
1389         * rendering/RenderTextControlMultiLine.cpp:
1390         (WebCore::RenderTextControlMultiLine::updateFromElement):
1391         * rendering/RenderTextControlMultiLine.h:
1392         * rendering/RenderTextControlSingleLine.cpp:
1393         (WebCore::RenderTextControlSingleLine::~RenderTextControlSingleLine):
1394         (WebCore::RenderTextControlSingleLine::textBaseStyle):
1395         (WebCore::RenderTextControlSingleLine::subtreeHasChanged):
1396         (WebCore::RenderTextControlSingleLine::layout):
1397         (WebCore::RenderTextControlSingleLine::nodeAtPoint):
1398         (WebCore::RenderTextControlSingleLine::forwardEvent):
1399         (WebCore::RenderTextControlSingleLine::styleDidChange):
1400         (WebCore::RenderTextControlSingleLine::hasControlClip):
1401         (WebCore::RenderTextControlSingleLine::controlClipRect):
1402         (WebCore::RenderTextControlSingleLine::textBlockWidth):
1403         (WebCore::RenderTextControlSingleLine::decorationWidthRight):
1404         (WebCore::RenderTextControlSingleLine::preferredContentWidth):
1405         (WebCore::RenderTextControlSingleLine::preferredDecorationWidthRight):
1406         (WebCore::RenderTextControlSingleLine::adjustControlHeightBasedOnLineHeight):
1407         (WebCore::RenderTextControlSingleLine::createSubtreeIfNeeded):
1408         (WebCore::RenderTextControlSingleLine::updateFromElement):
1409         (WebCore::RenderTextControlSingleLine::createInnerTextStyle):
1410         (WebCore::RenderTextControlSingleLine::updateCancelButtonVisibility):
1411         (WebCore::RenderTextControlSingleLine::clientPaddingLeft):
1412         (WebCore::RenderTextControlSingleLine::clientPaddingRight):
1413         (WebCore::RenderTextControlSingleLine::textBlockInsetTop):
1414         * rendering/RenderTextControlSingleLine.h:
1415
1416 2011-05-23  Syed Idris Shah  <syed.idris-shah@nokia.com>
1417
1418         Reviewed by Andreas Kling.
1419
1420         GraphicsContext3DInternal object should be called for getAttachedShaders.
1421         [Qt] fast/canvas/webgl/gl-object-get-calls.html crash for Qt based webkit
1422         https://bugs.webkit.org/show_bug.cgi?id=61202 
1423
1424         LayoutTests/fast/canvas/webgl/gl-object-get-calls.html
1425
1426         getAttachedShaders should be called on GraphicsContext3DInternal instance.
1427         It was left out by mistake.
1428
1429         * platform/graphics/qt/GraphicsContext3DQt.cpp: 
1430         (WebCore::GraphicsContext3D::getAttachedShaders): GraphicsContext3DInternal instance should be called.
1431
1432 2011-05-23  Carlos Garcia Campos  <cgarcia@igalia.com>
1433
1434         Unreviewed. Strict PassOwnPtr build fix.
1435
1436         * platform/text/gtk/TextCodecGtk.cpp:
1437         (WebCore::newTextCodecGtk):
1438
1439 2011-05-23  Mikhail Naganov  <mnaganov@chromium.org>
1440
1441         Reviewed by Yury Semikhatsky.
1442
1443         Web Inspector: [Chromium] Show "Please wait" message during initial
1444         heap snapshot processing.
1445         https://bugs.webkit.org/show_bug.cgi?id=61040
1446
1447         * inspector/front-end/DetailedHeapshotView.js:
1448         (WebInspector.HeapSnapshotSortableDataGrid.prototype.sortingChanged.sort):
1449         (WebInspector.HeapSnapshotSortableDataGrid.prototype.sortingChanged):
1450         (WebInspector.DetailedHeapshotView.profileCallback):
1451         (WebInspector.DetailedHeapshotView.setDataSource):
1452         (WebInspector.DetailedHeapshotView):
1453         (WebInspector.DetailedHeapshotView.prototype._changeBase.baseProfileLoaded):
1454         (WebInspector.DetailedHeapshotView.prototype._changeBase.setDataSource):
1455         (WebInspector.DetailedHeapshotView.prototype._changeBase):
1456         (WebInspector.DetailedHeapshotView.prototype._changeView.setDataSource):
1457         (WebInspector.DetailedHeapshotView.prototype._changeView):
1458         * inspector/front-end/PleaseWaitMessage.js:
1459         (WebInspector.PleaseWaitMessage.prototype.showAndWaitFor):
1460
1461 2011-05-23  Adam Barth  <abarth@webkit.org>
1462
1463         Strict PassOwnPtr build fixes.
1464
1465         * platform/gtk/GeolocationServiceGtk.cpp:
1466         (WebCore::GeolocationServiceGtk::create):
1467         * platform/gtk/RenderThemeGtk.cpp:
1468         (WebCore::RenderThemeGtk::adjustSliderTrackStyle):
1469         (WebCore::RenderThemeGtk::adjustSliderThumbStyle):
1470         (WebCore::RenderThemeGtk::adjustProgressBarStyle):
1471
1472 2011-05-22  Adam Barth  <abarth@webkit.org>
1473
1474         Strict PassOwnPtr build fix.
1475
1476         * platform/efl/RenderThemeEfl.cpp:
1477         (WebCore::RenderThemeEfl::adjustProgressBarStyle):
1478
1479 2011-05-22  Andrew Wason  <rectalogic@rectalogic.com>
1480
1481         Reviewed by Benjamin Poulain.
1482
1483         [Qt] Implement toImageData() in QtWebKit Bridge
1484         https://bugs.webkit.org/show_bug.cgi?id=60897
1485
1486         Tests are in WebKit/qt/tests/hybridPixmap
1487
1488         * bridge/qt/qt_pixmapruntime.cpp:
1489         (JSC::Bindings::QtPixmapToImageDataMethod::name):
1490         (JSC::Bindings::QtPixmapToImageDataMethod::invoke):
1491         (JSC::Bindings::QtPixmapToImageDataMethod::copyPixels):
1492         (JSC::Bindings::QtPixmapClass::methodsNamed):
1493         (JSC::Bindings::QtPixmapInstance::getPropertyNames):
1494          Add toImageData() to Qt Bridge, alternative to
1495          assignToHTMLImageElement().
1496
1497 2011-05-22  Dominic Cooney  <dominicc@chromium.org>
1498
1499         Reviewed by Dimitri Glazkov.
1500
1501         When removing a shadow root, also remove it from the render tree.
1502         https://bugs.webkit.org/show_bug.cgi?id=61245
1503
1504         Test: existing fast/dom/shadow/layout-tests-can-access-shadow.html
1505
1506         * dom/Element.cpp:
1507         (WebCore::Element::removeShadowRoot): Call detach if attached.
1508
1509 2011-05-22  Dirk Schulze  <krit@webkit.org>
1510
1511         Reviewed by Nikolas Zimmermann.
1512
1513         Don't do manually style resolution for SVGElements with renderer
1514         https://bugs.webkit.org/show_bug.cgi?id=59176
1515
1516         General clean-up.
1517
1518         Don't resolve style manually, instead ask the RenderObject for its style.
1519
1520         Cleanup svgattrs.in, some SVG element names were accidently listed there as attributes.
1521
1522         No new tests needed. No change of behavior.
1523
1524         * svg/SVGFEDiffuseLightingElement.cpp:
1525         (WebCore::SVGFEDiffuseLightingElement::build):
1526         * svg/SVGFEDropShadowElement.cpp:
1527         (WebCore::SVGFEDropShadowElement::build):
1528         * svg/SVGFEFloodElement.cpp:
1529         (WebCore::SVGFEFloodElement::build):
1530         * svg/SVGFESpecularLightingElement.cpp:
1531         (WebCore::SVGFESpecularLightingElement::build):
1532         * svg/svgattrs.in:
1533
1534 2011-05-21  Dirk Schulze  <krit@webkit.org>
1535
1536         Reviewed by Darin Adler.
1537
1538         REGRESSION(r66731): pointer-events are broken in some cases
1539         https://bugs.webkit.org/show_bug.cgi?id=45467
1540
1541         The SVGSVGElement shouldn't be the target of a mouse event, if its pointer-events attribute is set
1542         to 'none'. This matches the behavior on Firefox where an embedded SVG element is the target of an event,
1543         if none of its childs caught the event. This is the case for all pointer-events other than 'none'.
1544
1545         Tests: svg/custom/pointer-events-on-svg-with-pointer.xhtml
1546                svg/custom/pointer-events-on-svg-without-pointer.xhtml
1547
1548         * rendering/svg/RenderSVGRoot.cpp:
1549         (WebCore::RenderSVGRoot::nodeAtPoint):
1550
1551 2011-05-21  Dan Bernstein  <mitz@apple.com>
1552
1553         Reviewed by Darin Adler.
1554
1555         <rdar://problem/9479926> REGRESSION (r82144): Icon overlaps text in Twitter message dialog
1556         https://bugs.webkit.org/show_bug.cgi?id=61241
1557
1558         Test: fast/block/positioning/start-ignoring-before.html
1559
1560         * rendering/RenderBlockLineLayout.cpp:
1561         (WebCore::TrailingObjects::updateMidpointsForTrailingBoxes): Added a boolean parameter saying
1562         whether to merge the first trailing space with the line break.
1563         (WebCore::RenderBlock::LineBreaker::nextLineBreak): When adding a midpoint behind the current
1564         character, account for trailing positioned objects that occurred after the midpoint by calling
1565         updateMidpointsForTrailingBoxes(), which adds midpoints for them.
1566
1567 2011-05-21  Jeremy Noble  <jer.noble@apple.com>
1568
1569         Reviewed by Eric Carlson.
1570
1571         WebKit2: fix failing fullscreen/full-screen-remove* tests.
1572         https://bugs.webkit.org/show_bug.cgi?id=61027
1573
1574         * dom/Document.cpp:
1575         (WebCore::Document::fullScreenChangeDelayTimerFired): dispatchEvent can be
1576             synchronous, so make sure to check whether the current element is
1577             in the DOM before dispatching.
1578
1579 2011-05-21  Gavin Peters  <gavinp@chromium.org>
1580
1581         Reviewed by Adam Barth.
1582
1583         Add rel type prerender to distinguish prerender from prefetch
1584         https://bugs.webkit.org/show_bug.cgi?id=61079
1585
1586         Chrome right now uses <link rel=prefetch ...> for one of two things,
1587         to warm the cache in the same way as firefox, or to launch a speculative
1588         rendering of a web page, for faster "loading" when the user navigates to it.
1589
1590         This new rel type will let us distinguish the two cases; the rel type prerender
1591         isn't used on the web today, but the Google Web Search example prerendering application
1592         is ready to experiment with it.
1593
1594         Test: fast/dom/HTMLLinkElement/prerender.html
1595
1596         * html/HTMLLinkElement.cpp:
1597         (WebCore::HTMLLinkElement::tokenizeRelAttribute):
1598         (WebCore::HTMLLinkElement::process):
1599         * html/HTMLLinkElement.h:
1600         (WebCore::HTMLLinkElement::RelAttribute::RelAttribute):
1601         * loader/cache/CachedResource.cpp:
1602         (WebCore::defaultPriorityForResourceType):
1603         * loader/cache/CachedResource.h:
1604         (WebCore::CachedResource::isLinkResource):
1605         * loader/cache/CachedResourceLoader.cpp:
1606         (WebCore::createResource):
1607         (WebCore::CachedResourceLoader::requestLinkResource):
1608         (WebCore::CachedResourceLoader::canRequest):
1609         * loader/cache/CachedResourceLoader.h:
1610         * loader/cache/CachedResourceRequest.cpp:
1611         (WebCore::cachedResourceTypeToTargetType):
1612         (WebCore::CachedResourceRequest::load):
1613         * platform/network/ResourceRequestBase.h:
1614
1615 2011-05-21  Emil A Eklund  <eae@chromium.org>
1616
1617         Reviewed by Eric Seidel.
1618
1619         Change RenderLineBoxList::hitTest to use IntPoint
1620         https://bugs.webkit.org/show_bug.cgi?id=61156
1621
1622         Change the RenderLineBoxList hit testing to use IntPoint and clean up the rect calculation.
1623
1624         Covered by existing tests.
1625
1626         * rendering/RenderBlock.cpp:
1627         (WebCore::RenderBlock::hitTestContents):
1628         * rendering/RenderInline.cpp:
1629         (WebCore::RenderInline::nodeAtPoint):
1630         * rendering/RenderLineBoxList.cpp:
1631         (WebCore::RenderLineBoxList::hitTest):
1632         * rendering/RenderLineBoxList.h:
1633
1634 2011-05-21  Emil A Eklund  <eae@chromium.org>
1635
1636         Reviewed by Eric Seidel.
1637
1638         Change HitTestResult to use IntPoint
1639         https://bugs.webkit.org/show_bug.cgi?id=61230
1640
1641         Covered by existing tests.
1642
1643         * rendering/EllipsisBox.cpp:
1644         (WebCore::EllipsisBox::nodeAtPoint):
1645         * rendering/HitTestResult.cpp:
1646         (WebCore::HitTestResult::addNodeToRectBasedTestResult):
1647         * rendering/HitTestResult.h:
1648         (WebCore::HitTestResult::isRectBasedTest):
1649         * rendering/InlineFlowBox.cpp:
1650         (WebCore::InlineFlowBox::nodeAtPoint):
1651         * rendering/InlineTextBox.cpp:
1652         (WebCore::InlineTextBox::nodeAtPoint):
1653         * rendering/RenderBlock.cpp:
1654         (WebCore::RenderBlock::nodeAtPoint):
1655         (WebCore::RenderBlock::hitTestColumns):
1656         * rendering/RenderBox.cpp:
1657         (WebCore::RenderBox::nodeAtPoint):
1658         * rendering/RenderTable.cpp:
1659         (WebCore::RenderTable::nodeAtPoint):
1660         * rendering/svg/RenderSVGRoot.cpp:
1661         (WebCore::RenderSVGRoot::nodeAtPoint):
1662
1663 2011-05-21  Jochen Eisinger  <jochen@chromium.org>
1664
1665         Reviewed by Darin Fisher.
1666
1667         [chromium] add extraData field to resource requests
1668         https://bugs.webkit.org/show_bug.cgi?id=61033
1669
1670         * platform/network/chromium/ResourceRequest.h:
1671         (WebCore::ResourceRequest::ExtraData::~ExtraData):
1672         (WebCore::ResourceRequest::extraData):
1673         (WebCore::ResourceRequest::setExtraData):
1674
1675 2011-05-21  Kent Tamura  <tkent@chromium.org>
1676
1677         Reviewed by Dimitri Glazkov.
1678
1679         Change text-based <input> types to the new shadow DOM model
1680         https://bugs.webkit.org/show_bug.cgi?id=54179
1681
1682         By this change, text field inputs and textareas have one extra
1683         shadow node at the root of shadow trees.
1684         e.g. Before the change:
1685           <textarea> --(shadow-connection)-- <div> -- ...
1686         After the change:
1687           <textarea> --(shadow-connection)-- {#shadow-root} -- <div> -- ...
1688
1689         The goals of this change are
1690         - Change to the new shadow DOM model, and
1691         - Minimize the patch size.
1692
1693         We should use shadowPseudoId() in the new shadow DOM model, but the
1694         shadow elements in this patch don't use it in order to reduce the patch
1695         size.
1696
1697         * css/html.css:
1698         (input::-webkit-inner-spin-button):
1699          Add vertical-align in order to avoid the button affect the baseline.
1700         (input::-webkit-outer-spin-button): ditto.
1701         (input::-webkit-input-speech-button): ditto.
1702         * dom/Element.cpp:
1703         (WebCore::Element::recalcStyle): Calls styleForRenderer() so that a
1704          subclass of Element can override it.
1705         (WebCore::Element::isSpellCheckingEnabled):
1706         Handle ShadowRoot, which is not an Element.
1707         * dom/Node.cpp:
1708           Add utility functions for editing code.
1709         (WebCore::Node::nonBoundaryShadowTreeRootNode):
1710         (WebCore::Node::nonShadowBoundaryParentNode):
1711         * dom/Node.h: Declare them.
1712         * dom/Position.cpp:
1713          - Add some assertions about ShadowRoot
1714          - Replace parentNode() with nonShadowBoundaryParentNode()
1715         Because input/textarea shadow structures are changed.
1716         (WebCore::Position::Position):
1717         (WebCore::Position::containerNode):
1718         (WebCore::Position::parentAnchoredEquivalent):
1719         (WebCore::Position::previous):
1720         (WebCore::Position::next):
1721         (WebCore::Position::parentEditingBoundary):
1722         (WebCore::Position::atStartOfTree):
1723         (WebCore::Position::atEndOfTree):
1724         * dom/Position.h: ditto.
1725         (WebCore::positionInParentBeforeNode):
1726         (WebCore::positionInParentAfterNode):
1727         * editing/CompositeEditCommand.cpp: ditto.
1728         (WebCore::CompositeEditCommand::insertNodeAfter):
1729         (WebCore::CompositeEditCommand::removeNode):
1730         * editing/Editor.cpp:
1731         (WebCore::Editor::findString): ditto.
1732         * editing/FrameSelection.cpp:
1733         (WebCore::FrameSelection::selectAll): Inline shadowTreeRootNode() calls.
1734         * editing/FrameSelection.h:
1735           Remove shadowTreeRootNode(). It is used only by FrameSelection::selectAll().
1736         * editing/InsertParagraphSeparatorCommand.cpp:
1737         (WebCore::InsertParagraphSeparatorCommand::doApply): Use nonShadowBoundaryParentNode()
1738         * editing/ReplaceSelectionCommand.cpp:
1739         (WebCore::ReplacementFragment::removeNode): ditto.
1740         (WebCore::ReplacementFragment::insertNodeBefore): ditto.
1741         * editing/VisibleSelection.cpp:
1742           Rename shadowTreeRootNode() to nonBoundaryShadowTreeRootNode(), and it reutrns
1743           a child node of ShadowRoot.
1744         (WebCore::VisibleSelection::isAll):
1745         (WebCore::VisibleSelection::adjustSelectionToAvoidCrossingShadowBoundaries):
1746         (WebCore::VisibleSelection::nonBoundaryShadowTreeRootNode):
1747         * editing/VisibleSelection.h: ditto.
1748         * editing/htmlediting.cpp: Add assertions.
1749         (WebCore::visiblePositionBeforeNode):
1750         (WebCore::visiblePositionAfterNode):
1751         * html/HTMLInputElement.cpp:
1752         (WebCore::HTMLInputElement::create): Calls createShadowSubtree().
1753         (WebCore::HTMLInputElement::createShadowSubtree):
1754           Calls InputType::createShadowSubTree().
1755         (WebCore::HTMLInputElement::innerTextElement):
1756           Accessor of a shadow node. This is used by RenderTextControlSingleLine.
1757         (WebCore::HTMLInputElement::innerBlockElement): ditto.
1758         (WebCore::HTMLInputElement::innerSpinButtonElement): ditto.
1759         (WebCore::HTMLInputElement::outerSpinButtonElement): ditto.
1760         (WebCore::HTMLInputElement::resultsButtonElement): ditto.
1761         (WebCore::HTMLInputElement::cancelButtonElement): ditto.
1762         (WebCore::HTMLInputElement::speechButtonElement): ditto.
1763         (WebCore::HTMLInputElement::parseMappedAttribute):
1764           Rebuild shadow trees because x-webkit-speech attribute affects it.
1765         * html/HTMLInputElement.h: Add declarations.
1766         * html/HTMLIsIndexElement.cpp:
1767         (WebCore::HTMLIsIndexElement::create): Calls createShadowSubtree().
1768         * html/HTMLTextAreaElement.cpp:
1769         (WebCore::HTMLTextAreaElement::create): Calls createShadowSubtree().
1770         (WebCore::HTMLTextAreaElement::createShadowSubtree): Added.
1771         * html/HTMLTextAreaElement.h: Declare createShadowSubtree().
1772         * html/InputType.h: Add default implementations of accessors.
1773         (WebCore::InputType::innerBlockElement):
1774         (WebCore::InputType::innerTextElement):
1775         (WebCore::InputType::innerSpinButtonElement):
1776         (WebCore::InputType::outerSpinButtonElement):
1777         (WebCore::InputType::resultsButtonElement):
1778         (WebCore::InputType::cancelButtonElement):
1779         (WebCore::InputType::speechButtonElement):
1780         * html/SearchInputType.cpp:
1781         (WebCore::SearchInputType::SearchInputType): Initializes new data members.
1782         (WebCore::SearchInputType::createShadowSubtree):
1783           Moved from RenderTextControlSingleLine.
1784         (WebCore::SearchInputType::destroyShadowSubtree): Clear element references.
1785         * html/SearchInputType.h: Add declarations.
1786         (WebCore::SearchInputType::innerBlockElement):
1787         (WebCore::SearchInputType::resultsButtonElement):
1788         (WebCore::SearchInputType::cancelButtonElement):
1789         * html/TextFieldInputType.cpp:
1790         (WebCore::TextFieldInputType::TextFieldInputType):
1791           Initializes new data members.
1792         (WebCore::TextFieldInputType::createShadowSubtree):
1793           Moved from RenderTextControlSingleLine.
1794         (WebCore::TextFieldInputType::destroyShadowSubtree): Clear element references.
1795         * html/TextFieldInputType.h: Add declarations.
1796         (WebCore::TextFieldInputType::innerTextElement):
1797         (WebCore::TextFieldInputType::innerSpinButtonElement):
1798         (WebCore::TextFieldInputType::outerSpinButtonElement):
1799         (WebCore::TextFieldInputType::speechButtonElement):
1800         (WebCore::TextFieldInputType::setInnerTextElement):
1801         (WebCore::TextFieldInputType::setSpeechButtonElement):
1802         * html/shadow/TextControlInnerElements.cpp:
1803         (WebCore::TextControlInnerElement::TextControlInnerElement):
1804           Remove shadowParent parameter. It is unnecessary because we switch to
1805           new shadow model.
1806         (WebCore::TextControlInnerElement::create):
1807           Change the parameter type to Document.
1808         (WebCore::TextControlInnerElement::styleForRenderer):
1809           Override this in order to set style by
1810           RenderTextControlSingleLine::createInnerBlockStyle().
1811         (WebCore::TextControlInnerTextElement::TextControlInnerTextElement):
1812           Remove shadowParent parameter.
1813           Inherit HTMLDivElement, not TextControlInnerElement.
1814         (WebCore::TextControlInnerTextElement::create): Remove shadowParent parameter.
1815         (WebCore::TextControlInnerTextElement::styleForRenderer):
1816           Override this in order to set style by
1817           RenderTextControlSingleLine::createInnerTextStyle().
1818         (WebCore::SearchFieldResultsButtonElement::SearchFieldResultsButtonElement):
1819           Inherit HTMLDivElement, not TextControlInnerElement.
1820         (WebCore::SearchFieldResultsButtonElement::styleForRenderer):
1821           Override this in order to set style by
1822           RenderTextControlSingleLine::createResultButtonStyle().
1823         (WebCore::SearchFieldCancelButtonElement::SearchFieldCancelButtonElement):
1824           Inherit HTMLDivElement, not TextControlInnerElement.
1825         (WebCore::SearchFieldCancelButtonElement::styleForRenderer):
1826           Override this in order to set style by
1827           RenderTextControlSingleLine::createCancelButtonStyle().
1828         (WebCore::SearchFieldCancelButtonElement::detach):
1829           Update for the parent class change.
1830         (WebCore::SpinButtonElement::SpinButtonElement):
1831           - Change the parameter type: shadowParent -> Document
1832           - Add the inner flag
1833           - Inherit HTMLDivElement, not TextControlInnerElement.
1834         (WebCore::SpinButtonElement::createInner): Introduce a new factory
1835           method to hide a bool parameter of the constructor.
1836         (WebCore::SpinButtonElement::createOuter): ditto.
1837         (WebCore::SpinButtonElement::styleForRenderer):
1838           Override this in order to set style by
1839           RenderTextControlSingleLine::createInnerSpinButtonStyle() or
1840           createOuterSpinButtonStyle().
1841         (WebCore::SpinButtonElement::detach): Update for the parent class change.
1842         (WebCore::SpinButtonElement::setHovered): ditto.
1843         (WebCore::InputFieldSpeechButtonElement::InputFieldSpeechButtonElement):
1844           - Change the parameter type: shadowParent -> Document
1845           - Inherit HTMLDivElement, not TextControlInnerElement.
1846           - Do not register this as a speech input listener here.
1847         (WebCore::InputFieldSpeechButtonElement::create):
1848           Update for the parameter change.
1849         (WebCore::InputFieldSpeechButtonElement::defaultEventHandler):
1850           Do not handle click event if listener registration is not done.
1851         (WebCore::InputFieldSpeechButtonElement::attach):
1852           Register this as a speech input listener.
1853         (WebCore::InputFieldSpeechButtonElement::detach):
1854           Update for the parent class change.
1855         (WebCore::InputFieldSpeechButtonElement::styleForRenderer):
1856           Override this in order to set style by
1857           RenderTextControlSingleLine::createSpeechButtonStyle().
1858         * html/shadow/TextControlInnerElements.h:
1859         (WebCore::TextControlInnerTextElement::isMouseFocusable):
1860           Add this because the class is not a subclass of TextControllInnerElement.
1861         (WebCore::SearchFieldResultsButtonElement::isMouseFocusable): ditto.
1862         (WebCore::SearchFieldCancelButtonElement::isMouseFocusable): ditto.
1863         (WebCore::SpinButtonElement::isMouseFocusable): ditto.
1864         (WebCore::InputFieldSpeechButtonElement::isMouseFocusable): ditto.
1865         * rendering/RenderTextControl.cpp:
1866         (WebCore::RenderTextControl::~RenderTextControl): Remove unnecessary code.
1867         (WebCore::RenderTextControl::styleDidChange):
1868           innerTextElement can have no renderer.
1869           Explicitly call setNeedsStyleRecals() for innerTextElement. It is
1870           needed for LayoutTests/editing/selection/select-across-readonly-input-*.html.
1871         (WebCore::RenderTextControl::textBlockWidth): Member data -> function
1872         (WebCore::RenderTextControl::updateFromElement): ditto.
1873         (WebCore::RenderTextControl::setInnerTextValue): ditto.
1874         (WebCore::RenderTextControl::hasVisibleTextArea): ditto.
1875         (WebCore::RenderTextControl::isSelectableElement): ditto.
1876         (WebCore::RenderTextControl::selection): ditto.
1877         (WebCore::RenderTextControl::visiblePositionForIndex): ditto.
1878         (WebCore::RenderTextControl::indexForVisiblePosition): ditto.
1879         (WebCore::RenderTextControl::text): ditto.
1880         (WebCore::RenderTextControl::textWithHardLineBreaks): ditto.
1881         (WebCore::RenderTextControl::computeLogicalHeight): ditto.
1882         (WebCore::RenderTextControl::hitInnerTextElement): ditto.
1883         (WebCore::RenderTextControl::forwardEvent): ditto.
1884         (WebCore::RenderTextControl::computePreferredLogicalWidths): ditto.
1885         * rendering/RenderTextControl.h:
1886           - Make m_innerText virtual function.
1887           - Make createInnerTextStyle() public in order that
1888             TextControlInnerElements can call it.
1889         * rendering/RenderTextControlMultiLine.cpp:
1890         (WebCore::RenderTextControlMultiLine::innerTextElement): Added.
1891         (WebCore::RenderTextControlMultiLine::updateFromElement):
1892           Remove unnecessary createSubtreeIfNeeded() call.
1893         * rendering/RenderTextControlMultiLine.h: Add a declaration.
1894         * rendering/RenderTextControlSingleLine.cpp:
1895         (WebCore::RenderTextControlSingleLine::~RenderTextControlSingleLine):
1896           Remove unnecessary code.
1897         (WebCore::RenderTextControlSingleLine::innerTextElement): Added.
1898         (WebCore::RenderTextControlSingleLine::innerBlockElement): Added.
1899         (WebCore::RenderTextControlSingleLine::innerSpinButtonElement): Added.
1900         (WebCore::RenderTextControlSingleLine::outerSpinButtonElement): Added.
1901         (WebCore::RenderTextControlSingleLine::resultsButtonElement): Added.
1902         (WebCore::RenderTextControlSingleLine::cancelButtonElement): Added.
1903         (WebCore::RenderTextControlSingleLine::speechButtonElement): Added.
1904         (WebCore::RenderTextControlSingleLine::textBaseStyle): Data member -> function
1905         (WebCore::RenderTextControlSingleLine::subtreeHasChanged): ditto.
1906         (WebCore::RenderTextControlSingleLine::layout): ditto.
1907         (WebCore::RenderTextControlSingleLine::nodeAtPoint): ditto.
1908         (WebCore::RenderTextControlSingleLine::forwardEvent): ditto.
1909         (WebCore::RenderTextControlSingleLine::styleDidChange): ditto.
1910         (WebCore::RenderTextControlSingleLine::hasControlClip): ditto.
1911         (WebCore::RenderTextControlSingleLine::controlClipRect): ditto.
1912         (WebCore::RenderTextControlSingleLine::textBlockWidth): ditto.
1913         (WebCore::RenderTextControlSingleLine::decorationWidthRight): ditto.
1914         (WebCore::RenderTextControlSingleLine::preferredContentWidth): ditto.
1915         (WebCore::RenderTextControlSingleLine::preferredDecorationWidthRight): ditto.
1916         (WebCore::RenderTextControlSingleLine::adjustControlHeightBasedOnLineHeight): ditto.
1917         (WebCore::RenderTextControlSingleLine::updateFromElement):
1918           ditto, and remove unnecessary createSubtreeIfNeeded() call.
1919         (WebCore::RenderTextControlSingleLine::createInnerTextStyle):
1920           Data member -> function
1921         (WebCore::RenderTextControlSingleLine::updateCancelButtonVisibility): ditto.
1922         (WebCore::RenderTextControlSingleLine::clientPaddingLeft): ditto.
1923         (WebCore::RenderTextControlSingleLine::clientPaddingRight): ditto.
1924         (WebCore::RenderTextControlSingleLine::textBlockInsetTop): ditto.
1925         * rendering/RenderTextControlSingleLine.h:
1926           Add declarations, and remove unnecessary data members.
1927
1928 2011-05-21  Chris Rogers  <crogers@google.com>
1929
1930         Reviewed by Kenneth Russell.
1931
1932         AudioBufferSourceNode noteOff() method must respect scheduling time
1933         https://bugs.webkit.org/show_bug.cgi?id=61226
1934
1935         No new tests since audio API is not yet implemented.
1936
1937         * webaudio/AudioBufferSourceNode.cpp:
1938         (WebCore::AudioBufferSourceNode::AudioBufferSourceNode):
1939         (WebCore::AudioBufferSourceNode::process):
1940         (WebCore::AudioBufferSourceNode::provideInput):
1941         (WebCore::AudioBufferSourceNode::finish):
1942         (WebCore::AudioBufferSourceNode::noteGrainOn):
1943         (WebCore::AudioBufferSourceNode::noteOff):
1944         * webaudio/AudioBufferSourceNode.h:
1945
1946 2011-05-20  Dirk Schulze  <krit@webkit.org>
1947
1948         Reviewed by Nikolas Zimmermann.
1949
1950         Share more code in PathTraversalState
1951         https://bugs.webkit.org/show_bug.cgi?id=61238
1952
1953         Share more code between SVGPathTraversalStateBuilder and Path in PathTraversalState.
1954
1955         No change in functionality, so no new tests.
1956
1957         * platform/graphics/Path.cpp:
1958         (WebCore::pathLengthApplierFunction):
1959         * platform/graphics/PathTraversalState.cpp:
1960         (WebCore::PathTraversalState::processSegment):
1961         * platform/graphics/PathTraversalState.h:
1962         * svg/SVGPathTraversalStateBuilder.cpp:
1963         (WebCore::SVGPathTraversalStateBuilder::continueConsuming):
1964
1965 2011-05-21  Nikolas Zimmermann  <nzimmermann@rim.com>
1966
1967         Reviewed by Rob Buis.
1968
1969         SVG svgAttributeChanged/synchronizeProperty/parseMappedAttribute should be optimized
1970         https://bugs.webkit.org/show_bug.cgi?id=61183
1971
1972         Example: rect.x.baseVal.value = 100;
1973         What happens: SVGRectElement::svgAttributeChanged(const QualifiedName& attrName) is invoked with "SVGNames::rectAttr" as parameter.
1974
1975         void SVGRectElement::svgAttributeChanged(const QualifiedName& attrName)
1976         {
1977             SVGStyledTransformableElement::svgAttributeChanged(attrName);
1978             // Handle my own attribute changes...
1979         }
1980
1981         Currently we always traverse the base class hierarchy, when invoking svgAttributeChanged. Every svgAttributeChanged call from a class
1982         like SVGRectElement has to reach the base class SVGStyledElement::svgAttributeChanged, as it handles invalidation of the instances of
1983         an element. Say that a <rect> is referenced by a <use> and we change the 'x' attribute of the <rect>, then SVGStyledElement::svgAttributeChanged,
1984         calls SVGElementInstance::invalidateAllInstancesOfElement(this), so that the <use> can rebuild its shadow tree...
1985         That's the only reason all svgAttributeChanged implementations call the base class immediately, so SVGStyledElement is always reached.
1986
1987         Switch to a more efficient pattern, by providing a "bool isSupportedAttribute(const QualifiedName&);" function for all SVG*Elements.
1988         It contains all attributes the particular SVG*Element class handles (but not its parent classes attributes). For example SVGRectElement
1989         contains x/y/width/height/rx/ry attributes, and the ones from SVGTests/SVGLangSpace/SVGExternalResourcesRequired (xml:space/lang, etc.),
1990         but not eg. transform as that's handled by the parent class SVGStyledTransformableElement.
1991
1992         void SVGRectElement::svgAttributeChanged(const QualifiedName& attrName)
1993         {
1994             if (!isSupportedAttribute.contains(attrName)) {
1995                 SVGStyledTransformableElement::svgAttributeChanged(attrName);
1996                 return;
1997             }
1998
1999             // When we get here, we know for sure it's one of our attributes that has changed.
2000             // Note for eg. SVGNames::transformAttr, the call from SVGRectElement::svgAttributeChanged, would be immediately forwarded to the base class, which handles transformAttr changes)
2001
2002             if (attrName == SVGNames::xAttr) { do_work(); return; }
2003             if (attrName == SVGNames::yAttr) { do_work(); return; }
2004             ...
2005             // Assure that we handled all properties we claim support for in "isSupportedAttribute()".
2006             ASSERT_NOT_REACHED();
2007         }
2008
2009         Exactly the same pattern can be applied to synchronizeProperty and parseMappedAttribute to speed them up as well.
2010
2011         Add "SVGElementInstance::InvalidationGuard guard(this)" statements in all svgAttributeChanged implementations, that calls invalidateAllInstancesOfElement(this)
2012         upon destruction, after we've reacted to the svg attribute change. This assures we never forget to call the invalidation method anywhere, and don't
2013         need to rely on the base class svgAttributeChanged() call to do it.
2014        
2015         It's a slight overal performance progression.
2016
2017         * svg/SVGAElement.cpp:
2018         (WebCore::SVGAElement::isSupportedAttribute):
2019         (WebCore::SVGAElement::parseMappedAttribute):
2020         (WebCore::SVGAElement::svgAttributeChanged):
2021         (WebCore::SVGAElement::synchronizeProperty):
2022         * svg/SVGAElement.h:
2023         * svg/SVGAnimateMotionElement.cpp:
2024         (WebCore::SVGAnimateMotionElement::isSupportedAttribute):
2025         (WebCore::SVGAnimateMotionElement::parseMappedAttribute):
2026         * svg/SVGAnimateMotionElement.h:
2027         * svg/SVGAnimateTransformElement.cpp:
2028         (WebCore::SVGAnimateTransformElement::isSupportedAttribute):
2029         (WebCore::SVGAnimateTransformElement::parseMappedAttribute):
2030         * svg/SVGAnimateTransformElement.h:
2031         * svg/SVGAnimationElement.cpp:
2032         (WebCore::SVGAnimationElement::isSupportedAttribute):
2033         (WebCore::SVGAnimationElement::parseMappedAttribute):
2034         * svg/SVGAnimationElement.h:
2035         * svg/SVGCircleElement.cpp:
2036         (WebCore::SVGCircleElement::isSupportedAttribute):
2037         (WebCore::SVGCircleElement::parseMappedAttribute):
2038         (WebCore::SVGCircleElement::svgAttributeChanged):
2039         (WebCore::SVGCircleElement::synchronizeProperty):
2040         * svg/SVGCircleElement.h:
2041         * svg/SVGClipPathElement.cpp:
2042         (WebCore::SVGClipPathElement::isSupportedAttribute):
2043         (WebCore::SVGClipPathElement::parseMappedAttribute):
2044         (WebCore::SVGClipPathElement::svgAttributeChanged):
2045         (WebCore::SVGClipPathElement::synchronizeProperty):
2046         * svg/SVGClipPathElement.h:
2047         * svg/SVGComponentTransferFunctionElement.cpp:
2048         (WebCore::SVGComponentTransferFunctionElement::isSupportedAttribute):
2049         (WebCore::SVGComponentTransferFunctionElement::parseMappedAttribute):
2050         (WebCore::SVGComponentTransferFunctionElement::synchronizeProperty):
2051         * svg/SVGComponentTransferFunctionElement.h:
2052         * svg/SVGCursorElement.cpp:
2053         (WebCore::SVGCursorElement::isSupportedAttribute):
2054         (WebCore::SVGCursorElement::parseMappedAttribute):
2055         (WebCore::SVGCursorElement::svgAttributeChanged):
2056         (WebCore::SVGCursorElement::synchronizeProperty):
2057         * svg/SVGCursorElement.h:
2058         * svg/SVGElementInstance.h:
2059         (WebCore::SVGElementInstance::InvalidationGuard::InvalidationGuard):
2060         (WebCore::SVGElementInstance::InvalidationGuard::~InvalidationGuard):
2061         * svg/SVGEllipseElement.cpp:
2062         (WebCore::SVGEllipseElement::isSupportedAttribute):
2063         (WebCore::SVGEllipseElement::parseMappedAttribute):
2064         (WebCore::SVGEllipseElement::svgAttributeChanged):
2065         (WebCore::SVGEllipseElement::synchronizeProperty):
2066         * svg/SVGEllipseElement.h:
2067         * svg/SVGExternalResourcesRequired.cpp:
2068         (WebCore::SVGExternalResourcesRequired::addSupportedAttributes):
2069         * svg/SVGExternalResourcesRequired.h:
2070         * svg/SVGFEBlendElement.cpp:
2071         (WebCore::SVGFEBlendElement::isSupportedAttribute):
2072         (WebCore::SVGFEBlendElement::parseMappedAttribute):
2073         (WebCore::SVGFEBlendElement::svgAttributeChanged):
2074         (WebCore::SVGFEBlendElement::synchronizeProperty):
2075         * svg/SVGFEBlendElement.h:
2076         * svg/SVGFEColorMatrixElement.cpp:
2077         (WebCore::SVGFEColorMatrixElement::isSupportedAttribute):
2078         (WebCore::SVGFEColorMatrixElement::parseMappedAttribute):
2079         (WebCore::SVGFEColorMatrixElement::svgAttributeChanged):
2080         (WebCore::SVGFEColorMatrixElement::synchronizeProperty):
2081         * svg/SVGFEColorMatrixElement.h:
2082         * svg/SVGFEComponentTransferElement.cpp:
2083         (WebCore::SVGFEComponentTransferElement::isSupportedAttribute):
2084         (WebCore::SVGFEComponentTransferElement::parseMappedAttribute):
2085         (WebCore::SVGFEComponentTransferElement::synchronizeProperty):
2086         * svg/SVGFEComponentTransferElement.h:
2087         * svg/SVGFECompositeElement.cpp:
2088         (WebCore::SVGFECompositeElement::isSupportedAttribute):
2089         (WebCore::SVGFECompositeElement::parseMappedAttribute):
2090         (WebCore::SVGFECompositeElement::svgAttributeChanged):
2091         (WebCore::SVGFECompositeElement::synchronizeProperty):
2092         * svg/SVGFECompositeElement.h:
2093         * svg/SVGFEConvolveMatrixElement.cpp:
2094         (WebCore::SVGFEConvolveMatrixElement::isSupportedAttribute):
2095         (WebCore::SVGFEConvolveMatrixElement::parseMappedAttribute):
2096         (WebCore::SVGFEConvolveMatrixElement::svgAttributeChanged):
2097         (WebCore::SVGFEConvolveMatrixElement::synchronizeProperty):
2098         * svg/SVGFEConvolveMatrixElement.h:
2099         * svg/SVGFEDiffuseLightingElement.cpp:
2100         (WebCore::SVGFEDiffuseLightingElement::isSupportedAttribute):
2101         (WebCore::SVGFEDiffuseLightingElement::parseMappedAttribute):
2102         (WebCore::SVGFEDiffuseLightingElement::svgAttributeChanged):
2103         (WebCore::SVGFEDiffuseLightingElement::synchronizeProperty):
2104         * svg/SVGFEDiffuseLightingElement.h:
2105         * svg/SVGFEDisplacementMapElement.cpp:
2106         (WebCore::SVGFEDisplacementMapElement::isSupportedAttribute):
2107         (WebCore::SVGFEDisplacementMapElement::parseMappedAttribute):
2108         (WebCore::SVGFEDisplacementMapElement::svgAttributeChanged):
2109         (WebCore::SVGFEDisplacementMapElement::synchronizeProperty):
2110         * svg/SVGFEDisplacementMapElement.h:
2111         * svg/SVGFEDropShadowElement.cpp:
2112         (WebCore::SVGFEDropShadowElement::isSupportedAttribute):
2113         (WebCore::SVGFEDropShadowElement::parseMappedAttribute):
2114         (WebCore::SVGFEDropShadowElement::svgAttributeChanged):
2115         (WebCore::SVGFEDropShadowElement::synchronizeProperty):
2116         * svg/SVGFEDropShadowElement.h:
2117         * svg/SVGFEGaussianBlurElement.cpp:
2118         (WebCore::SVGFEGaussianBlurElement::isSupportedAttribute):
2119         (WebCore::SVGFEGaussianBlurElement::parseMappedAttribute):
2120         (WebCore::SVGFEGaussianBlurElement::svgAttributeChanged):
2121         (WebCore::SVGFEGaussianBlurElement::synchronizeProperty):
2122         * svg/SVGFEGaussianBlurElement.h:
2123         * svg/SVGFEImageElement.cpp:
2124         (WebCore::SVGFEImageElement::isSupportedAttribute):
2125         (WebCore::SVGFEImageElement::parseMappedAttribute):
2126         (WebCore::SVGFEImageElement::svgAttributeChanged):
2127         (WebCore::SVGFEImageElement::synchronizeProperty):
2128         * svg/SVGFEImageElement.h:
2129         * svg/SVGFELightElement.cpp:
2130         (WebCore::SVGFELightElement::isSupportedAttribute):
2131         (WebCore::SVGFELightElement::parseMappedAttribute):
2132         (WebCore::SVGFELightElement::svgAttributeChanged):
2133         (WebCore::SVGFELightElement::synchronizeProperty):
2134         * svg/SVGFELightElement.h:
2135         * svg/SVGFEMergeNodeElement.cpp:
2136         (WebCore::SVGFEMergeNodeElement::isSupportedAttribute):
2137         (WebCore::SVGFEMergeNodeElement::parseMappedAttribute):
2138         (WebCore::SVGFEMergeNodeElement::svgAttributeChanged):
2139         (WebCore::SVGFEMergeNodeElement::synchronizeProperty):
2140         * svg/SVGFEMergeNodeElement.h:
2141         * svg/SVGFEMorphologyElement.cpp:
2142         (WebCore::SVGFEMorphologyElement::isSupportedAttribute):
2143         (WebCore::SVGFEMorphologyElement::parseMappedAttribute):
2144         (WebCore::SVGFEMorphologyElement::svgAttributeChanged):
2145         (WebCore::SVGFEMorphologyElement::synchronizeProperty):
2146         * svg/SVGFEMorphologyElement.h:
2147         * svg/SVGFEOffsetElement.cpp:
2148         (WebCore::SVGFEOffsetElement::isSupportedAttribute):
2149         (WebCore::SVGFEOffsetElement::parseMappedAttribute):
2150         (WebCore::SVGFEOffsetElement::svgAttributeChanged):
2151         (WebCore::SVGFEOffsetElement::synchronizeProperty):
2152         * svg/SVGFEOffsetElement.h:
2153         * svg/SVGFESpecularLightingElement.cpp:
2154         (WebCore::SVGFESpecularLightingElement::isSupportedAttribute):
2155         (WebCore::SVGFESpecularLightingElement::parseMappedAttribute):
2156         (WebCore::SVGFESpecularLightingElement::svgAttributeChanged):
2157         (WebCore::SVGFESpecularLightingElement::synchronizeProperty):
2158         * svg/SVGFESpecularLightingElement.h:
2159         * svg/SVGFETileElement.cpp:
2160         (WebCore::SVGFETileElement::isSupportedAttribute):
2161         (WebCore::SVGFETileElement::parseMappedAttribute):
2162         (WebCore::SVGFETileElement::svgAttributeChanged):
2163         (WebCore::SVGFETileElement::synchronizeProperty):
2164         * svg/SVGFETileElement.h:
2165         * svg/SVGFETurbulenceElement.cpp:
2166         (WebCore::SVGFETurbulenceElement::isSupportedAttribute):
2167         (WebCore::SVGFETurbulenceElement::parseMappedAttribute):
2168         (WebCore::SVGFETurbulenceElement::svgAttributeChanged):
2169         (WebCore::SVGFETurbulenceElement::synchronizeProperty):
2170         * svg/SVGFETurbulenceElement.h:
2171         * svg/SVGFilterElement.cpp:
2172         (WebCore::SVGFilterElement::isSupportedAttribute):
2173         (WebCore::SVGFilterElement::parseMappedAttribute):
2174         (WebCore::SVGFilterElement::svgAttributeChanged):
2175         (WebCore::SVGFilterElement::synchronizeProperty):
2176         * svg/SVGFilterElement.h:
2177         * svg/SVGFilterPrimitiveStandardAttributes.cpp:
2178         (WebCore::SVGFilterPrimitiveStandardAttributes::isSupportedAttribute):
2179         (WebCore::SVGFilterPrimitiveStandardAttributes::parseMappedAttribute):
2180         (WebCore::SVGFilterPrimitiveStandardAttributes::svgAttributeChanged):
2181         (WebCore::SVGFilterPrimitiveStandardAttributes::synchronizeProperty):
2182         * svg/SVGFilterPrimitiveStandardAttributes.h:
2183         * svg/SVGFitToViewBox.cpp:
2184         (WebCore::SVGFitToViewBox::parseMappedAttribute):
2185         (WebCore::SVGFitToViewBox::synchronizeProperties):
2186         (WebCore::SVGFitToViewBox::addSupportedAttributes):
2187         * svg/SVGFitToViewBox.h:
2188         * svg/SVGForeignObjectElement.cpp:
2189         (WebCore::SVGForeignObjectElement::isSupportedAttribute):
2190         (WebCore::SVGForeignObjectElement::parseMappedAttribute):
2191         (WebCore::SVGForeignObjectElement::svgAttributeChanged):
2192         (WebCore::SVGForeignObjectElement::synchronizeProperty):
2193         * svg/SVGForeignObjectElement.h:
2194         * svg/SVGGElement.cpp:
2195         (WebCore::SVGGElement::isSupportedAttribute):
2196         (WebCore::SVGGElement::parseMappedAttribute):
2197         (WebCore::SVGGElement::svgAttributeChanged):
2198         (WebCore::SVGGElement::synchronizeProperty):
2199         * svg/SVGGElement.h:
2200         * svg/SVGGradientElement.cpp:
2201         (WebCore::SVGGradientElement::isSupportedAttribute):
2202         (WebCore::SVGGradientElement::parseMappedAttribute):
2203         (WebCore::SVGGradientElement::svgAttributeChanged):
2204         (WebCore::SVGGradientElement::synchronizeProperty):
2205         * svg/SVGGradientElement.h:
2206         * svg/SVGImageElement.cpp:
2207         (WebCore::SVGImageElement::isSupportedAttribute):
2208         (WebCore::SVGImageElement::parseMappedAttribute):
2209         (WebCore::SVGImageElement::svgAttributeChanged):
2210         (WebCore::SVGImageElement::synchronizeProperty):
2211         * svg/SVGImageElement.h:
2212         * svg/SVGLangSpace.cpp:
2213         (WebCore::SVGLangSpace::addSupportedAttributes):
2214         * svg/SVGLangSpace.h:
2215         * svg/SVGLineElement.cpp:
2216         (WebCore::SVGLineElement::isSupportedAttribute):
2217         (WebCore::SVGLineElement::parseMappedAttribute):
2218         (WebCore::SVGLineElement::svgAttributeChanged):
2219         (WebCore::SVGLineElement::synchronizeProperty):
2220         * svg/SVGLineElement.h:
2221         * svg/SVGLinearGradientElement.cpp:
2222         (WebCore::SVGLinearGradientElement::isSupportedAttribute):
2223         (WebCore::SVGLinearGradientElement::parseMappedAttribute):
2224         (WebCore::SVGLinearGradientElement::svgAttributeChanged):
2225         (WebCore::SVGLinearGradientElement::synchronizeProperty):
2226         * svg/SVGLinearGradientElement.h:
2227         * svg/SVGMPathElement.cpp:
2228         (WebCore::SVGMPathElement::isSupportedAttribute):
2229         (WebCore::SVGMPathElement::parseMappedAttribute):
2230         (WebCore::SVGMPathElement::synchronizeProperty):
2231         * svg/SVGMPathElement.h:
2232         * svg/SVGMarkerElement.cpp:
2233         (WebCore::SVGMarkerElement::isSupportedAttribute):
2234         (WebCore::SVGMarkerElement::parseMappedAttribute):
2235         (WebCore::SVGMarkerElement::svgAttributeChanged):
2236         (WebCore::SVGMarkerElement::synchronizeProperty):
2237         * svg/SVGMarkerElement.h:
2238         * svg/SVGMaskElement.cpp:
2239         (WebCore::SVGMaskElement::isSupportedAttribute):
2240         (WebCore::SVGMaskElement::parseMappedAttribute):
2241         (WebCore::SVGMaskElement::svgAttributeChanged):
2242         (WebCore::SVGMaskElement::synchronizeProperty):
2243         * svg/SVGMaskElement.h:
2244         * svg/SVGPathElement.cpp:
2245         (WebCore::SVGPathElement::isSupportedAttribute):
2246         (WebCore::SVGPathElement::parseMappedAttribute):
2247         (WebCore::SVGPathElement::svgAttributeChanged):
2248         (WebCore::SVGPathElement::synchronizeProperty):
2249         * svg/SVGPathElement.h:
2250         * svg/SVGPatternElement.cpp:
2251         (WebCore::SVGPatternElement::isSupportedAttribute):
2252         (WebCore::SVGPatternElement::parseMappedAttribute):
2253         (WebCore::SVGPatternElement::svgAttributeChanged):
2254         (WebCore::SVGPatternElement::synchronizeProperty):
2255         * svg/SVGPatternElement.h:
2256         * svg/SVGPolyElement.cpp:
2257         (WebCore::SVGPolyElement::isSupportedAttribute):
2258         (WebCore::SVGPolyElement::parseMappedAttribute):
2259         (WebCore::SVGPolyElement::svgAttributeChanged):
2260         * svg/SVGPolyElement.h:
2261         * svg/SVGRadialGradientElement.cpp:
2262         (WebCore::SVGRadialGradientElement::isSupportedAttribute):
2263         (WebCore::SVGRadialGradientElement::parseMappedAttribute):
2264         (WebCore::SVGRadialGradientElement::svgAttributeChanged):
2265         (WebCore::SVGRadialGradientElement::synchronizeProperty):
2266         * svg/SVGRadialGradientElement.h:
2267         * svg/SVGRectElement.cpp:
2268         (WebCore::SVGRectElement::isSupportedAttribute):
2269         (WebCore::SVGRectElement::parseMappedAttribute):
2270         (WebCore::SVGRectElement::svgAttributeChanged):
2271         (WebCore::SVGRectElement::synchronizeProperty):
2272         * svg/SVGRectElement.h:
2273         * svg/SVGSVGElement.cpp:
2274         (WebCore::SVGSVGElement::svgAttributeChanged):
2275         (WebCore::SVGSVGElement::synchronizeProperty):
2276         * svg/SVGScriptElement.cpp:
2277         (WebCore::SVGScriptElement::isSupportedAttribute):
2278         (WebCore::SVGScriptElement::parseMappedAttribute):
2279         (WebCore::SVGScriptElement::svgAttributeChanged):
2280         (WebCore::SVGScriptElement::synchronizeProperty):
2281         * svg/SVGScriptElement.h:
2282         * svg/SVGStopElement.cpp:
2283         (WebCore::SVGStopElement::isSupportedAttribute):
2284         (WebCore::SVGStopElement::parseMappedAttribute):
2285         (WebCore::SVGStopElement::svgAttributeChanged):
2286         (WebCore::SVGStopElement::synchronizeProperty):
2287         * svg/SVGStopElement.h:
2288         * svg/SVGStyleElement.cpp:
2289         (WebCore::SVGStyleElement::isSupportedAttribute):
2290         (WebCore::SVGStyleElement::parseMappedAttribute):
2291         * svg/SVGStyleElement.h:
2292         * svg/SVGStyledElement.cpp:
2293         (WebCore::SVGStyledElement::parseMappedAttribute):
2294         (WebCore::SVGStyledElement::svgAttributeChanged):
2295         (WebCore::SVGStyledElement::synchronizeProperty):
2296         * svg/SVGStyledTransformableElement.cpp:
2297         (WebCore::SVGStyledTransformableElement::isSupportedAttribute):
2298         (WebCore::SVGStyledTransformableElement::parseMappedAttribute):
2299         (WebCore::SVGStyledTransformableElement::svgAttributeChanged):
2300         (WebCore::SVGStyledTransformableElement::synchronizeProperty):
2301         * svg/SVGStyledTransformableElement.h:
2302         * svg/SVGSymbolElement.cpp:
2303         (WebCore::SVGSymbolElement::isSupportedAttribute):
2304         (WebCore::SVGSymbolElement::parseMappedAttribute):
2305         (WebCore::SVGSymbolElement::svgAttributeChanged):
2306         (WebCore::SVGSymbolElement::synchronizeProperty):
2307         * svg/SVGSymbolElement.h:
2308         * svg/SVGTRefElement.cpp:
2309         (WebCore::SVGTRefElement::isSupportedAttribute):
2310         (WebCore::SVGTRefElement::parseMappedAttribute):
2311         (WebCore::SVGTRefElement::svgAttributeChanged):
2312         (WebCore::SVGTRefElement::synchronizeProperty):
2313         * svg/SVGTRefElement.h:
2314         * svg/SVGTests.cpp:
2315         (WebCore::SVGTests::addSupportedAttributes):
2316         * svg/SVGTests.h:
2317         * svg/SVGTextContentElement.cpp:
2318         (WebCore::SVGTextContentElement::isSupportedAttribute):
2319         (WebCore::SVGTextContentElement::parseMappedAttribute):
2320         (WebCore::SVGTextContentElement::synchronizeProperty):
2321         (WebCore::SVGTextContentElement::svgAttributeChanged):
2322         * svg/SVGTextContentElement.h:
2323         * svg/SVGTextElement.cpp:
2324         (WebCore::SVGTextElement::isSupportedAttribute):
2325         (WebCore::SVGTextElement::parseMappedAttribute):
2326         (WebCore::SVGTextElement::svgAttributeChanged):
2327         (WebCore::SVGTextElement::synchronizeProperty):
2328         * svg/SVGTextElement.h:
2329         * svg/SVGTextPathElement.cpp:
2330         (WebCore::SVGTextPathElement::isSupportedAttribute):
2331         (WebCore::SVGTextPathElement::parseMappedAttribute):
2332         (WebCore::SVGTextPathElement::svgAttributeChanged):
2333         (WebCore::SVGTextPathElement::synchronizeProperty):
2334         * svg/SVGTextPathElement.h:
2335         * svg/SVGTextPositioningElement.cpp:
2336         (WebCore::SVGTextPositioningElement::isSupportedAttribute):
2337         (WebCore::SVGTextPositioningElement::parseMappedAttribute):
2338         (WebCore::SVGTextPositioningElement::svgAttributeChanged):
2339         (WebCore::SVGTextPositioningElement::synchronizeProperty):
2340         * svg/SVGTextPositioningElement.h:
2341         * svg/SVGTransformable.cpp:
2342         * svg/SVGTransformable.h:
2343         * svg/SVGURIReference.cpp:
2344         (WebCore::SVGURIReference::addSupportedAttributes):
2345         * svg/SVGURIReference.h:
2346         * svg/SVGUseElement.cpp:
2347         (WebCore::SVGUseElement::isSupportedAttribute):
2348         (WebCore::SVGUseElement::parseMappedAttribute):
2349         (WebCore::SVGUseElement::svgAttributeChanged):
2350         (WebCore::SVGUseElement::synchronizeProperty):
2351         * svg/SVGUseElement.h:
2352         * svg/SVGViewElement.cpp:
2353         (WebCore::SVGViewElement::isSupportedAttribute):
2354         (WebCore::SVGViewElement::parseMappedAttribute):
2355         (WebCore::SVGViewElement::synchronizeProperty):
2356         * svg/SVGViewElement.h:
2357         * svg/SVGZoomAndPan.cpp:
2358         (WebCore::SVGZoomAndPan::addSupportedAttributes):
2359         * svg/SVGZoomAndPan.h:
2360
2361 2011-05-20  Simon Fraser  <simon.fraser@apple.com>
2362
2363         Reviewed by Dan Bernstein.
2364
2365         Allow ShadowBlur to do tiling when the context is scaled
2366         https://bugs.webkit.org/show_bug.cgi?id=61232
2367
2368         If the GraphicsContext is scaled or rotated by a multiple of 90deg, have ShadowBlur
2369         use the tiling code path, to avoid blurring large areas on pages like cracked.com
2370         when the context is scaled.
2371
2372         * platform/graphics/ShadowBlur.cpp:
2373         (WebCore::ShadowBlur::drawRectShadow): Call preservesAxisAlignment()
2374         to decide when to not use tiling.
2375         (WebCore::ShadowBlur::drawInsetShadow): Ditto.
2376         (WebCore::ShadowBlur::drawLayerPieces): Round to device pixels when drawing tiles
2377         to avoid pixel cracks in scaled contexts.
2378         * platform/graphics/transforms/AffineTransform.h:
2379         (WebCore::AffineTransform::preservesAxisAlignment): Return true if there is the matrix
2380         contains a transform that results in axis alignment (no rotation or skew, or rotations
2381         which are multiples of 90deg).
2382
2383 2011-05-20  Alexey Proskuryakov  <ap@apple.com>
2384
2385         Reviewed by Kent Tamura.
2386
2387         Special characters can be inserted in text field having reached maxlength
2388         https://bugs.webkit.org/show_bug.cgi?id=19479
2389         <rdar://problem/7828739>
2390
2391         Test: platform/mac/editing/input/maxlength.html
2392
2393         * editing/CompositeEditCommand.cpp:
2394         (WebCore::CompositeEditCommand::insertTextIntoNode):
2395         (WebCore::CompositeEditCommand::replaceTextInNode):
2396         Avoid hitting an assertion below, now that we can get here with empty text.
2397
2398         * editing/TypingCommand.cpp: (WebCore::TypingCommand::insertText): There is still work to do
2399         even if beforetextinput removed all text from the event. At the very least, we should delete
2400         the current selection.
2401
2402 2011-05-20  Andy Estes  <aestes@apple.com>
2403
2404         Reviewed by Darin Adler.
2405
2406         REGRESSION (r70748): WebKit cannot play videos created by Podcast Producer.
2407         https://bugs.webkit.org/show_bug.cgi?id=61229
2408         
2409         Podcast Producer uses an object tag with a classid attribute to embed
2410         QuickTime Player into a page. In r70748, we changed our behavior to
2411         render the object's fallback content when a non-empty classid is
2412         encountered, per HTML5. Since Podcast Producer videos have no fallback
2413         content, this change in behavior causes the video to fail to load.
2414         
2415         Since the object tag has a valid type attribute, we would be able to
2416         load it if weren't for the non-empty classid. This patch changes our
2417         policy to allow objects with non-empty classids if there is no fallback
2418         content. We still continue to prefer fallback content if it exists,
2419         however.
2420
2421         * html/HTMLObjectElement.cpp:
2422         (WebCore::HTMLObjectElement::hasValidClassId): Treat a non-empty
2423         classid as valid if the object has no fallback content.
2424
2425 2011-05-20  Kulanthaivel Palanichamy  <kulanthaivel@codeaurora.org>
2426
2427         Reviewed by Simon Fraser.
2428
2429         If both border-radius and box-shadow applied, shadow is not fully visible
2430         https://bugs.webkit.org/show_bug.cgi?id=59577
2431
2432         The current implementation of RoundedIntRect::inflateWithRadii() inflates
2433         its rect size and corner radii out of sync. This leads to validation failure in
2434         Path::addRoundedRect() and results in ignoring radii in the path.
2435         When this invalid path is used to clip out the rounded corner box before painting
2436         the box shadow, the entire rectangle is clipped out without the corner radii.
2437
2438         This patch implements RoundedIntRect::inflateWithRadii() properly to inflate
2439         rounded rect radii based on inflate ratios of rect size.
2440
2441         Test: fast/css/box-shadow-and-border-radius.html
2442
2443         * platform/graphics/RoundedIntRect.cpp:
2444         (WebCore::RoundedIntRect::inflateWithRadii):
2445         * platform/graphics/RoundedIntRect.h:
2446
2447 2011-05-20  Michael Nordman  <michaeln@google.com>
2448
2449         Reviewed by Darin Fisher.
2450
2451         [Chromium] Support the new webkit apis so the WebDatabase system participates
2452         in the unified quota management system.
2453         https://bugs.webkit.org/show_bug.cgi?id=60985
2454
2455         No change in functionality, no new tests.
2456
2457         * platform/chromium/PlatformBridge.h:
2458         * storage/chromium/QuotaTracker.cpp:
2459         (WebCore::QuotaTracker::getDatabaseSizeAndSpaceAvailableToOrigin):
2460         (WebCore::QuotaTracker::updateDatabaseSize):
2461         (WebCore::QuotaTracker::updateSpaceAvailableToOrigin):
2462         (WebCore::QuotaTracker::resetSpaceAvailableToOrigin):
2463         * storage/chromium/QuotaTracker.h:
2464
2465 2011-05-20  Andy Estes  <aestes@apple.com>
2466
2467         Reviewed by Darin Adler.
2468
2469         WebView loses firstResponder status when entering full-screen mode.
2470         https://bugs.webkit.org/show_bug.cgi?id=61153
2471
2472         No test possible via DRT. Add a manual test instead.
2473
2474         * manual-tests/full-screen-keypress.html: Added.
2475
2476 2011-05-20  Jeremy Noble  <jer.noble@apple.com>
2477
2478         Reviewed by Maciej Stachowiak.
2479
2480         WebKit2: Exit full screen mode if the WebProcess crashes.
2481         https://bugs.webkit.org/show_bug.cgi?id=61151
2482
2483         * platform/graphics/win/FullScreenController.h:
2484         * platform/graphics/win/FullScreenController.cpp:
2485         (FullScreenController::close): Added.  Close the full-screen window without animation
2486             if called.
2487
2488 2011-05-20  Enrica Casucci  <enrica@apple.com>
2489
2490         Reviewed by David Kilzer.
2491
2492         Add delegate methods about focus and blur to all elements.
2493         https://bugs.webkit.org/show_bug.cgi?id=61218
2494
2495         We want to have delegates for these events for all the elements, not only the form elements.
2496         The patch moves the call to the delegate in the Node class and changes the name
2497         of the methods not to be form element specific.
2498
2499         * dom/Node.cpp:
2500         (WebCore::Node::dispatchFocusEvent): Added call to delegate with the new name.
2501         (WebCore::Node::dispatchBlurEvent): Added call to delegate with the new name.
2502         * html/HTMLFormControlElement.cpp:
2503         (WebCore::HTMLFormControlElement::dispatchBlurEvent): Removed code that calls the delegate since
2504         it has been moved into Node.
2505         * html/HTMLFormControlElement.h: Removed dispatchFocusEvent, since we are using the default inplementation in Node.
2506         * loader/EmptyClients.h:
2507         (WebCore::EmptyChromeClient::elementDidFocus): Name changed.
2508         (WebCore::EmptyChromeClient::elementDidBlur): Name changed.
2509         * page/ChromeClient.h:
2510         (WebCore::ChromeClient::elementDidFocus): Name changed.
2511         (WebCore::ChromeClient::elementDidBlur): Name changed.
2512
2513 2011-05-20  Ryosuke Niwa  <rniwa@webkit.org>
2514
2515         Reviewed by Enrica Casucci.
2516
2517         Wrap copied contents by one style span instead of two
2518         https://bugs.webkit.org/show_bug.cgi?id=60988
2519
2520         Replaced sourceDocumentStyleSpan and copiedRangeStyleSpan by one wrapping style span. Instead
2521         of wrapping the copied contents by user-applied style and document default style in serialization,
2522         take the difference with the document default's style in paste code.
2523
2524         This will dramatically simplify our copy and paste code and pave a way to fix the bug 60914.
2525
2526         No new tests because copy & paste is tested by existing layout tests.
2527
2528         * editing/EditingStyle.cpp:
2529         (WebCore::EditingStyle::prepareToApplyAt): Remove the color property if RGBA values of color
2530         matches that of the computed style at the specified position.
2531         * editing/ReplaceSelectionCommand.cpp:
2532         (WebCore::ReplaceSelectionCommand::handleStyleSpans): Replaced sourceDocumentStyleSpan and
2533         copiedRangeStyleSpan by wrappingStyleSpan. When pasting as a quotation, compare style against
2534         the document's default style to avoid keeping the document default style (tested by
2535         editing/pasteboard/4930986-3.html).
2536         * editing/ReplaceSelectionCommand.h:
2537         * editing/markup.cpp:
2538         (WebCore::createMarkup): Only use one style span to wrap the serialized contents.
2539
2540 2011-05-20  Simon Fraser  <simon.fraser@apple.com>
2541
2542         Reviewed by Sam Weinig.
2543
2544         numberOfActiveAnimations() can include animations from documents in the page cache
2545         https://bugs.webkit.org/show_bug.cgi?id=53641
2546         
2547         Some transition tests using layoutTestController.numberOfActiveAnimations() failed
2548         in WebKit2 because numberOfActiveAnimations() could include those from other documents
2549         in the page cache.
2550         
2551         Fix by passing in the document for which we wish to count animations.
2552
2553         * WebCore.exp.in:
2554         * page/animation/AnimationController.cpp:
2555         (WebCore::AnimationControllerPrivate::numberOfActiveAnimations):
2556         (WebCore::AnimationController::numberOfActiveAnimations):
2557         * page/animation/AnimationController.h:
2558         * page/animation/AnimationControllerPrivate.h:
2559
2560 2011-05-20  Adam Barth  <abarth@webkit.org>
2561
2562         Reviewed by Alexey Proskuryakov.
2563
2564         Factor CORS request preparation out of DocumentThreadableLoader
2565         https://bugs.webkit.org/show_bug.cgi?id=61209
2566
2567         DocumentThreadableLoader has two jobs:
2568
2569         1) Proxy loads between threads.
2570         2) Run the CORS state machine.
2571
2572         This patch begins the work of separating those concerns, allowing CORS
2573         to be used elsewhere in the loading pipeline.  In particular, this
2574         patch moves knowledge of how to prepare CORS requests out of
2575         DocumentThreadableLoder.
2576
2577         * loader/CrossOriginAccessControl.cpp:
2578         (WebCore::isOnAccessControlSimpleRequestHeaderWhitelist):
2579         (WebCore::updateRequestForAccessControl):
2580         (WebCore::createAccessControlPreflightRequest):
2581         * loader/CrossOriginAccessControl.h:
2582         * loader/DocumentThreadableLoader.cpp:
2583         (WebCore::DocumentThreadableLoader::DocumentThreadableLoader):
2584         (WebCore::DocumentThreadableLoader::makeSimpleCrossOriginAccessRequest):
2585         (WebCore::DocumentThreadableLoader::makeCrossOriginAccessRequestWithPreflight):
2586
2587 2011-05-20  Rob Buis  <rbuis@rim.com>
2588
2589         Reviewed by Dirk Schulze.
2590
2591         Use test from ietestcenter fails
2592         https://bugs.webkit.org/show_bug.cgi?id=60844
2593
2594         When an id changes on an in-document element, we need to check whether the id
2595         is part of the pending elements. Since this is the same thing as happens in
2596         insertedIntoDocument, split out the common code into buildPendingResourcesIfNeeded.
2597
2598         Test: svg/W3C-SVG-1.1-SE/struct-use-14-f.svg
2599
2600         * svg/SVGStyledElement.cpp:
2601         (WebCore::SVGStyledElement::svgAttributeChanged):
2602         (WebCore::SVGStyledElement::insertedIntoDocument):
2603         (WebCore::SVGStyledElement::buildPendingResourcesIfNeeded):
2604         * svg/SVGStyledElement.h:
2605
2606 2011-05-20  Abhishek Arya  <inferno@chromium.org>
2607
2608         Reviewed by Kent Tamura.
2609
2610         Make auto-focus a post attach callback in
2611         HTMLFormControlElement::attach().
2612         https://bugs.webkit.org/show_bug.cgi?id=32882
2613
2614         Original patch by Darin Adler. This one uses a part of it.
2615         
2616         Test: fast/forms/input-element-attach-crash.html
2617
2618         * dom/Document.cpp:
2619         (WebCore::Document::recalcStyle): Make sure that m_inStyleRecalc is
2620         already false by the time post-attach callbacks are done so that
2621         layout triggered inside those callbacks can work properly.
2622         * html/HTMLFormControlElement.cpp:
2623         (WebCore::shouldAutofocus): Helper function that expresses
2624         the rule for which form control elements should auto-focus.
2625         (WebCore::focusPostAttach): Called post-attach to focus an
2626         element if we discover it should be focused during attach.
2627         (WebCore::HTMLFormControlElement::attach): Refactored code for
2628         which elements need auto-focus into a separate function. Instead
2629         of focusing right away, use the focusPostAttach function to focus
2630         after attach is done. Also added calls to suspendPostAttachCallbacks
2631         and resumePostAttachCallbacks so post-attach callbacks happen late
2632         enough. Before, they could run inside the base attach function.
2633         * html/HTMLInputElement.cpp:
2634         (WebCore::HTMLInputElement::attach): Added calls to
2635         suspendPostAttachCallbacks and resumePostAttachCallbacks so
2636         post-attach callbacks happen late enough
2637
2638 2011-05-20  Alok Priyadarshi  <alokp@chromium.org>
2639
2640         Reviewed by James Robinson.
2641
2642         [chromium] Remove LayerRendererChromium::useShader
2643         https://bugs.webkit.org/show_bug.cgi?id=61143
2644
2645         GPU compositor tests should be sufficient.
2646
2647         * platform/graphics/chromium/LayerRendererChromium.cpp:
2648         (WebCore::LayerRendererChromium::LayerRendererChromium):
2649         * platform/graphics/chromium/LayerRendererChromium.h:
2650         * platform/graphics/chromium/LayerTilerChromium.cpp:
2651         (WebCore::LayerTilerChromium::draw):
2652         * platform/graphics/chromium/RenderSurfaceChromium.cpp:
2653         (WebCore::RenderSurfaceChromium::drawSurface):
2654         * platform/graphics/chromium/cc/CCCanvasLayerImpl.cpp:
2655         (WebCore::CCCanvasLayerImpl::draw):
2656         * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
2657         (WebCore::CCHeadsUpDisplay::draw):
2658         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
2659         (WebCore::CCLayerImpl::drawDebugBorder):
2660         * platform/graphics/chromium/cc/CCPluginLayerImpl.cpp:
2661         (WebCore::CCPluginLayerImpl::draw):
2662         * platform/graphics/chromium/cc/CCVideoLayerImpl.cpp:
2663         (WebCore::CCVideoLayerImpl::drawYUV):
2664         (WebCore::CCVideoLayerImpl::drawRGBA):
2665
2666 2011-05-20  Dirk Schulze  <krit@webkit.org>
2667
2668         Reviewed by Darin Adler.
2669
2670         SVGPathSegList needs better getTotalLength, getSegmentAtLength path traversal code
2671         https://bugs.webkit.org/show_bug.cgi?id=12047
2672
2673         Right now SVGPathElement::getTotalLength and SVGPathElement::getPointAtLength use toPathData()
2674         to transform a SVGPathByteStream to a Path. This Path gets traversed to find the searched value.
2675         With this patch both functions use the SVGPathByteStream directly together with the existing
2676         traversing code in SVG. This avoids the intermediate transforming to a platform path and gives
2677         platform independent results.
2678         The traversal code in SVG needed to be extended to support all PathTraversalActions.
2679
2680         No new tests added. The existing tests cover the changes.
2681
2682         * svg/SVGPathElement.cpp:
2683         (WebCore::SVGPathElement::getTotalLength):
2684         (WebCore::SVGPathElement::getPointAtLength):
2685         * svg/SVGPathParserFactory.cpp:
2686         (WebCore::SVGPathParserFactory::getTotalLengthOfSVGPathByteStream):
2687         (WebCore::SVGPathParserFactory::getPointAtLengthOfSVGPathByteStream):
2688         * svg/SVGPathParserFactory.h:
2689         * svg/SVGPathTraversalStateBuilder.cpp:
2690         (WebCore::SVGPathTraversalStateBuilder::continueConsuming):
2691         (WebCore::SVGPathTraversalStateBuilder::totalLength):
2692         (WebCore::SVGPathTraversalStateBuilder::currentPoint):
2693         * svg/SVGPathTraversalStateBuilder.h:
2694
2695 2011-05-20  Mark Pilgrim  <pilgrim@chromium.org>
2696
2697         Reviewed by Tony Chang.
2698
2699         IndexedDB createObjectStore should throw if name is null
2700         https://bugs.webkit.org/show_bug.cgi?id=58465
2701
2702         Test: storage/indexeddb/mozilla/create-objectstore-null-name.html
2703
2704         * storage/IDBDatabase.idl:
2705         * storage/IDBDatabaseBackendImpl.cpp:
2706         (WebCore::IDBDatabaseBackendImpl::createObjectStore):
2707
2708 2011-05-20  Xiaomei Ji  <xji@chromium.org>
2709
2710         Reviewed by Ryosuke Niwa.
2711
2712         ctrl-arrow does not work on words separated by multiple spaces.
2713         https://bugs.webkit.org/show_bug.cgi?id=57543.
2714
2715         Add the leftmost boundary of a box in RTL block or the rightmost boundary of a box in LTR
2716         block as word break if its inlineBox is the current box and it is a word break.
2717
2718         * editing/visible_units.cpp:
2719         (WebCore::previousWordBreakInBoxInsideBlockWithSameDirectionality): Add the rightmost
2720         boundary of a box in LTR block or leftmost boundary of a box in RTL block as visually
2721         first word break.
2722         (WebCore::nextWordBreakInBoxInsideBlockWithDifferentDirectionality):
2723         (WebCore::collectWordBreaksInBoxInsideBlockWithDifferntDirectionality):
2724         (WebCore::leftWordBoundary): Fix bug change "box" to "adjacentBox".
2725         (WebCore::rightWordBoundary): Fix bug change "box" to "adjacentBox".
2726
2727 2011-05-19  Evan Martin  <evan@chromium.org>
2728
2729         Reviewed by Tony Chang.
2730
2731         [chromium] remove <(library) variable
2732         https://bugs.webkit.org/show_bug.cgi?id=61158
2733
2734         This was for a build experiment; we can just use the correct value now.
2735
2736         * WebCore.gyp/WebCore.gyp:
2737
2738 2011-05-20  Pavel Podivilov  <podivilov@chromium.org>
2739
2740         Reviewed by Pavel Feldman.
2741
2742         Web Inspector: breakpoints disappear from ui after navigation.
2743         https://bugs.webkit.org/show_bug.cgi?id=61133
2744
2745         * inspector/front-end/DebuggerPresentationModel.js:
2746         (WebInspector.DebuggerPresentationModel.prototype._debuggerWasEnabled):
2747         (WebInspector.DebuggerPresentationModel.prototype._saveBreakpoints):
2748
2749 2011-05-20  Sheriff Bot  <webkit.review.bot@gmail.com>
2750
2751         Unreviewed, rolling out r86958.
2752         http://trac.webkit.org/changeset/86958
2753         https://bugs.webkit.org/show_bug.cgi?id=61195
2754
2755         broke breakpoints persisting (Requested by podivilov on
2756         #webkit).
2757
2758         * inspector/front-end/DebuggerPresentationModel.js:
2759         (WebInspector.DebuggerPresentationModel.prototype._debuggerWasEnabled):
2760         (WebInspector.DebuggerPresentationModel.prototype._saveBreakpoints):
2761
2762 2011-05-19  Sergey Vorobyev  <sergeyvorobyev@google.com>
2763
2764         Reviewed by Yury Semikhatsky.
2765
2766         Web Inspector: Background network events collection - add GUI to Inspector.
2767         https://bugs.webkit.org/show_bug.cgi?id=58652
2768
2769         Now in WebInspector Network panel avalaible new checkbox item in context menu:
2770         "Background events collection". It allows to save all network events when inspector
2771         frontend closed. Events that occur before collection enabling are not preserved after
2772         frontend reopening. Property unique for each page. Disabled by default.
2773
2774
2775         Tests: http/tests/inspector/network/network-clear-after-disabled.html
2776                http/tests/inspector/network/network-close-load-open.html
2777                http/tests/inspector/network/network-open-load-reopen.html
2778
2779         * inspector/EventsCollector.cpp:
2780         (WebCore::EventsCollector::clear):
2781         * inspector/EventsCollector.h:
2782         * inspector/Inspector.json:
2783         * inspector/InspectorFrontendProxy.cpp:
2784         (WebCore::InspectorFrontendProxy::inspectorFrontendChannel):
2785         * inspector/InspectorFrontendProxy.h:
2786         * inspector/InspectorResourceAgent.cpp:
2787         (WebCore::InspectorResourceAgent::setFrontend):
2788         (WebCore::InspectorResourceAgent::clearFrontend):
2789         (WebCore::InspectorResourceAgent::isBackgroundEventsCollectionEnabled):
2790         (WebCore::InspectorResourceAgent::setBackgroundEventsCollectionEnabled):
2791         (WebCore::InspectorResourceAgent::initializeBackgroundCollection):
2792         (WebCore::InspectorResourceAgent::InspectorResourceAgent):
2793         * inspector/InspectorResourceAgent.h:
2794         * inspector/front-end/NetworkPanel.js:
2795         (WebInspector.NetworkPanel):
2796         (WebInspector.NetworkPanel.prototype._contextMenu):
2797         (WebInspector.NetworkPanel.prototype._toggleBackgroundEventsCollection):
2798
2799 2011-05-20  Pavel Podivilov  <podivilov@chromium.org>
2800
2801         Reviewed by Pavel Feldman.
2802
2803         Web Inspector: breakpoints disappear from ui after navigation.
2804         https://bugs.webkit.org/show_bug.cgi?id=61133
2805
2806         * inspector/front-end/DebuggerPresentationModel.js:
2807         (WebInspector.DebuggerPresentationModel.prototype._debuggerWasEnabled):
2808         (WebInspector.DebuggerPresentationModel.prototype._saveBreakpoints):
2809
2810 2011-05-20  Jer Noble  <jer.noble@apple.com>
2811
2812         Reviewed by Maciej Stachowiak.
2813
2814         Win: non-full-screen content is briefly seen when entering full-screen mode (and vice versa)
2815         https://bugs.webkit.org/show_bug.cgi?id=61108
2816
2817         Instead of repainting the full- and non-full-screen windows in WebCore, delegate that
2818         responsibility to the FullScreenControllerClient.  Because the repaint operation may 
2819         be asynchronous, add a new method for clients to use to indicate repainting has completed.
2820
2821         * platform/graphics/win/FullScreenController.cpp:
2822         (FullScreenController::Private::Private): Added new ivars.
2823         (FullScreenController::enterFullScreen): Split into two functions (pre-and post repaint)
2824         (FullScreenController::enterFullScreenRepaintCompleted): Ditto.
2825         (FullScreenController::exitFullScreen): Ditto.
2826         (FullScreenController::exitFullScreenRepaintCompleted): Ditto.
2827         (FullScreenController::repaintCompleted): Call the appropriated repaint completed function.
2828         * platform/graphics/win/FullScreenController.h:
2829         * platform/graphics/win/FullScreenControllerClient.h:
2830
2831 2011-05-20  Yury Semikhatsky  <yurys@chromium.org>
2832
2833         Reviewed by Pavel Feldman.
2834
2835         Web Inspector: use RefPtr instead of OwnPtr to store InspectorBackendDispatcher
2836         https://bugs.webkit.org/show_bug.cgi?id=61188
2837
2838         * inspector/WorkerInspectorController.cpp:
2839         (WebCore::WorkerInspectorController::connectFrontend):
2840         (WebCore::WorkerInspectorController::disconnectFrontend):
2841         * inspector/WorkerInspectorController.h:
2842
2843 2011-05-20  Tonis Tiigi  <tonistiigi@gmail.com>
2844
2845         Reviewed by Pavel Feldman.
2846
2847         Web Inspector: Network panel should only show pointer cursor over valid resources
2848         https://bugs.webkit.org/show_bug.cgi?id=55240
2849
2850         Cursor style removed from filler area.
2851
2852         * inspector/front-end/networkPanel.css:
2853         (.network-sidebar .data-grid tr:not(.filler) td.name-column):
2854
2855 2011-05-20  Peter Varga  <pvarga@webkit.org>
2856
2857         Reviewed by Simon Hausmann.
2858
2859         [Qt][V8] Use qtscript-staging's shipped version of V8 when building with --v8
2860         https://bugs.webkit.org/show_bug.cgi?id=56649
2861
2862         Use the provided V8 and functionality of
2863         http://qt.gitorious.org/+qt-developers/qt/qtscript-staging to build QtWebKit+V8.
2864         Based on the original patch of Andras Becsi <abecsi@webkit.org>.
2865
2866         No new tests needed.
2867
2868         * CodeGenerators.pri: Add generating of DebuggerScriptSource.h
2869         * WebCore.pri: Fix the options for V8 build.
2870         * WebCore.pro: Ditto.
2871         * bindings/v8/NPV8Object.cpp:
2872         (WebCore::npObjectTypeInfo): Add missing initializer.
2873         * bindings/v8/ScriptController.cpp:
2874         (WebCore::ScriptController::disableEval): Temporarily disable
2875         unsupported feature on Qt.
2876         * bindings/v8/ScriptControllerQt.cpp:
2877         (WebCore::ScriptController::qtScriptEngine): use the QtScriptEngine
2878         constructor of qtscript-staging.
2879         * bindings/v8/custom/V8HTMLAudioElementConstructor.cpp: Add missing
2880         initializer.
2881         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp: Ditto.
2882         * bindings/v8/custom/V8HTMLOptionElementConstructor.cpp: Ditto.
2883         * loader/appcache/ApplicationCacheGroup.cpp: Add missing header.
2884         * loader/cache/CachedResourceRequest.cpp: Ditto.
2885         * page/PageSerializer.cpp: Ditto.
2886         * page/qt/FrameQt.cpp: Ditto.
2887         * storage/StorageEventDispatcher.cpp: Ditto.
2888
2889 2011-05-20  Tonis Tiigi  <tonistiigi@gmail.com>
2890
2891         Reviewed by Pavel Feldman.
2892
2893         Web Inspector: console.log(XMLDocument) should be case preserving
2894         https://bugs.webkit.org/show_bug.cgi?id=60765
2895
2896         Changes the XML document checking from base documents MIME type
2897         to xmlVersion parameter.
2898
2899         * inspector/InspectorDOMAgent.cpp:
2900         (WebCore::InspectorDOMAgent::buildObjectForNode):
2901         * inspector/front-end/DOMAgent.js:
2902         (WebInspector.DOMNode):
2903         * inspector/front-end/ElementsTreeOutline.js:
2904         (WebInspector.ElementsTreeOutline.prototype.set rootDOMNode):
2905
2906 2011-05-20  Mikhail Naganov  <mnaganov@chromium.org>
2907
2908         Reviewed by Yury Semikhatsky.
2909
2910         Web Inspector: [Chromium] Use bottom-up CPU profile tree built in VM,
2911         instead of building it on Inspector's side.
2912         https://bugs.webkit.org/show_bug.cgi?id=61185
2913
2914         * bindings/js/ScriptProfile.cpp:
2915         (WebCore::ScriptProfile::bottomUpHead):
2916         (WebCore::ScriptProfile::buildInspectorObjectForBottomUpHead):
2917         * bindings/js/ScriptProfile.h:
2918         * bindings/v8/ScriptProfile.cpp:
2919         (WebCore::ScriptProfile::bottomUpHead):
2920         (WebCore::ScriptProfile::buildInspectorObjectForBottomUpHead):
2921         * bindings/v8/ScriptProfile.h:
2922         * inspector/InspectorProfilerAgent.cpp:
2923         (WebCore::InspectorProfilerAgent::getProfile):
2924         * inspector/front-end/ProfileView.js:
2925         (WebInspector.CPUProfileView.prototype.get bottomUpProfileDataGridTree):
2926
2927 2011-05-20  Adam Roben  <aroben@apple.com>
2928
2929         Mac build fix after r86936
2930
2931         * WebCore.xcodeproj/project.pbxproj: Added preprocessor.pm like the
2932         other .pm files.
2933
2934 2011-05-20  Kent Tamura  <tkent@chromium.org>
2935
2936         Try to fix Windows CE build.
2937         Touch html.css to kick UA style sheet generation.
2938
2939         * css/html.css:
2940
2941 2011-05-20  Kent Tamura  <tkent@chromium.org>
2942
2943         Try to fix Windows CE build. 
2944
2945         * CMakeLists.txt: Add --preprocessor flag.
2946
2947 2011-05-20  Kent Tamura  <tkent@chromium.org>
2948
2949         Reviewed by Hajime Morita.
2950
2951         Apply feature flags to user-agent style sheets
2952         https://bugs.webkit.org/show_bug.cgi?id=52612
2953
2954         A user-agent style sheet should not have style definitions for disabled
2955         features because such definitions makes feature detection harder and
2956         causes incorrect behavior (See Bug 52214).
2957
2958         We have handled such feature-dependent style definitions by providing
2959         separated CSS files and selecting them in build files. Adding such style
2960         definition was hard because we need to update each of build files. This
2961         change simplifies the process to add such style definitions by applying
2962         preprocessor to the CSS files.
2963
2964         Implementation:
2965         make-css-file-arrays.pl invokes a preprocessor if it has --defines
2966         option. Otherwise, it just remove lines beginning with #.
2967         In this change, we pass --defines on Mac, Windows, Chromium, GTK, and
2968         CMake platforms. Qt and Android have no behavior change.
2969
2970         * CMakeLists.txt:
2971           - IDL handling depends on preprocessor.pm.
2972           - Pass --defines option to make-css-file-arrays.pl
2973           - Add WebCore/bindings/scripts to @INC for make-css-file-arrays.pl
2974         * CodeGenerators.pri: IDL handling depends on preprocessor.pm.
2975         * DerivedSources.make: ditto.
2976         * GNUmakefile.am: ditto.
2977         * WebCore.gyp/WebCore.gyp: ditto.
2978         * WebCore.gyp/scripts/action_useragentstylesheets.py:
2979           Change parameter order to support perl modules and options.
2980           Many code is taken from rule_bindings.py.
2981         * WebCore.vcproj/MigrateScripts: Handles preprocessor.pm.
2982         * bindings/scripts/IDLParser.pm:
2983           Move the preprocessor code to preprocessor.pm.
2984         * bindings/scripts/preprocessor.pm:
2985           Added. The code was moved from IDLParser.pm
2986         * css/html.css: Enclose some style definitions with #if-#endif.
2987         * css/make-css-file-arrays.pl:
2988           - Add --defines and --preprocessor options.
2989           - Invoke a preprocessor if --defines is specified.
2990
2991 2011-05-20  Dirk Schulze  <krit@webkit.org>
2992
2993         Rubber-stamped by Nikolas Zimmermann.
2994
2995         Remove unnecessary class Path inlcude from PathTraversalState.
2996
2997         * platform/graphics/PathTraversalState.h:
2998
2999 2011-05-19  Pavel Podivilov  <podivilov@chromium.org>
3000
3001         Reviewed by Pavel Feldman.
3002
3003         Web Inspector: ctrl+s should not switch source frame to read only mode.
3004         https://bugs.webkit.org/show_bug.cgi?id=61125
3005
3006         * inspector/front-end/SourceFrame.js:
3007         (WebInspector.SourceFrame.prototype.commitEditing.didEditContent):
3008         (WebInspector.SourceFrame.prototype.commitEditing):
3009         * inspector/front-end/inspector.js:
3010         (WebInspector.documentKeyDown):
3011
3012 2011-05-20  Piroska András  <Piroska.Andras@stud.u-szeged.hu>
3013
3014         Reviewed by Nikolas Zimmermann.
3015
3016         Apply the ParallelJobs support to FEConvolveMatrix
3017         https://bugs.webkit.org/show_bug.cgi?id=61171
3018
3019         The FEConvolveMatrix filter of SVG can consume lots of resources if it is
3020         applied to a large area. The computation can be distributed to multiple
3021         cores if the architecture supports.
3022         The average performance progression is 20-30% on dual-core machines.
3023
3024         Developed in cooperation with Gabor Loki.
3025
3026         * platform/graphics/filters/FEConvolveMatrix.cpp:
3027         (WebCore::FEConvolveMatrix::fastSetInteriorPixels):
3028         (WebCore::FEConvolveMatrix::setInteriorPixels):
3029         (WebCore::FEConvolveMatrix::setInteriorPixelsWorker):
3030         (WebCore::FEConvolveMatrix::apply):
3031         * platform/graphics/filters/FEConvolveMatrix.h:
3032
3033 2011-05-20  Sheriff Bot  <webkit.review.bot@gmail.com>
3034
3035         Unreviewed, rolling out r86920.
3036         http://trac.webkit.org/changeset/86920
3037         https://bugs.webkit.org/show_bug.cgi?id=61173
3038
3039         It cause compile error on some buildbot in chromium. e.g.
3040         http://build.chromium.org/p/chromium.memory/builders/Chromium%20Mac%20Builder%20%28valgrind%29/builds/12336/steps/compile/logs/stdio#error1
3041         (Requested by ukai_ on #webkit).
3042
3043         * WebCore.xcodeproj/project.pbxproj:
3044         * css/CSSComputedStyleDeclaration.cpp:
3045         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3046         * css/CSSParser.cpp:
3047         (WebCore::CSSParser::parseValue):
3048         * css/CSSPrimitiveValueMappings.h:
3049         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
3050         (WebCore::CSSPrimitiveValue::operator EImageRendering):
3051         * css/CSSPropertyNames.in:
3052         * css/CSSStyleSelector.cpp:
3053         (WebCore::CSSStyleSelector::applyProperty):
3054         * css/CSSValueKeywords.in:
3055         * css/SVGCSSComputedStyleDeclaration.cpp:
3056         (WebCore::CSSComputedStyleDeclaration::getSVGPropertyCSSValue):
3057         * css/SVGCSSPropertyNames.in:
3058         * css/SVGCSSStyleSelector.cpp:
3059         (WebCore::CSSStyleSelector::applySVGProperty):
3060         * css/SVGCSSValueKeywords.in:
3061         * html/HTMLCanvasElement.cpp:
3062         (WebCore::HTMLCanvasElement::paint):
3063         * html/HTMLCanvasElement.h:
3064         * platform/graphics/ImageRenderingMode.h: Removed.
3065         * rendering/RenderBoxModelObject.cpp:
3066         (WebCore::ImageQualityController::shouldPaintAtLowQuality):
3067         * rendering/RenderHTMLCanvas.cpp:
3068         (WebCore::RenderHTMLCanvas::paintReplaced):
3069         * rendering/style/RenderStyle.cpp:
3070         (WebCore::RenderStyle::diff):
3071         * rendering/style/RenderStyle.h:
3072         * rendering/style/RenderStyleConstants.h:
3073         * rendering/style/SVGRenderStyle.cpp:
3074         (WebCore::SVGRenderStyle::diff):
3075         * rendering/style/SVGRenderStyle.h:
3076         (WebCore::SVGRenderStyle::initialImageRendering):
3077         (WebCore::SVGRenderStyle::setImageRendering):
3078         (WebCore::SVGRenderStyle::imageRendering):
3079         (WebCore::SVGRenderStyle::InheritedFlags::operator==):
3080         (WebCore::SVGRenderStyle::setBitDefaults):
3081         * rendering/style/SVGRenderStyleDefs.h:
3082         * rendering/style/StyleRareInheritedData.cpp:
3083         (WebCore::StyleRareInheritedData::StyleRareInheritedData):
3084         (WebCore::StyleRareInheritedData::operator==):
3085         * rendering/style/StyleRareInheritedData.h:
3086         * rendering/svg/SVGRenderTreeAsText.cpp:
3087         (WebCore::writeStyle):
3088
3089 2011-05-20  Dirk Schulze  <krit@webkit.org>
3090
3091         Reviewed by Eric Seidel.
3092
3093         SVG Large curve path segment OOM crash
3094         https://bugs.webkit.org/show_bug.cgi?id=42079
3095
3096         Limit the depth of repeatedly splitting a segment on length calculation to 20. The limitation
3097         is necessary for very big segments that would be splitter into millions of parts otherwise.
3098         The limitation just cause a less accurate approximation.
3099         At the moment the limit is fixed to 20. This is comparable with splitting the segment into 
3100         ~1 million parts as a worst case. We might want to be more flexible later.
3101
3102         Test: svg/custom/path-getTotalLength-on-big-segment-crash.svg
3103
3104         * platform/graphics/PathTraversalState.cpp:
3105         (WebCore::midPoint):
3106         (WebCore::curveLength):
3107         (WebCore::PathTraversalState::PathTraversalState):
3108         (WebCore::PathTraversalState::moveTo):
3109         (WebCore::PathTraversalState::quadraticBezierTo):
3110         (WebCore::PathTraversalState::cubicBezierTo):
3111         * platform/graphics/PathTraversalState.h:
3112
3113 2011-05-20  Leo Yang  <leo.yang@torchmobile.com.cn>
3114
3115         Reviewed by Nikolas Zimmermann.
3116
3117         SVGRootInlineBox triggers calculateBoundaries twice in layout
3118         https://bugs.webkit.org/show_bug.cgi?id=60979
3119
3120         SVGRootInlineBox was calculating boundaries for children twice
3121         in computePerCharacterLayoutInformation(). The first time of
3122         calculation was in layoutChildBoxes() which is called by
3123         computePerCharacterLayoutInformation(), and the second time of
3124         calculation was in layoutRootBox() following layoutChildBoxes().
3125
3126         This patch calculates rectangle of children in layoutChildBoxes()
3127         and then uses the rectange in layoutRootBox() to reduce a pass
3128         of calculating child boundaries.
3129
3130         No functionality change, no new tests.
3131
3132         * rendering/svg/SVGRootInlineBox.cpp:
3133         (WebCore::SVGRootInlineBox::computePerCharacterLayoutInformation):
3134         (WebCore::SVGRootInlineBox::layoutChildBoxes):
3135         (WebCore::SVGRootInlineBox::layoutRootBox):
3136         * rendering/svg/SVGRootInlineBox.h:
3137
3138 2011-05-19  Naoki Takano  <takano.naoki@gmail.com>
3139
3140         Reviewed by Kent Tamura.
3141
3142         Fix a problem that updating HTMLInputElement::value sets the cursor to a wrong position.
3143         https://bugs.webkit.org/show_bug.cgi?id=61163
3144
3145         Manual test input-number-localization.html.
3146         Because we can't assume any number formats in various WebKit ports.
3147
3148         * html/HTMLInputElement.cpp:
3149         (WebCore::HTMLInputElement::setValue): The cursor must be the last position of visibleValue(), not m_value.
3150         * manual-tests/input-number-localization.html: Added manual test to check the cursor correctly moved to the last poisition of the input.
3151
3152 2011-05-19  Jer Noble  <jer.noble@apple.com>
3153
3154         Reviewed by Maciej Stachowiak.
3155
3156         WebKit2: Flashing when entering and exiting full screen mode
3157         https://bugs.webkit.org/show_bug.cgi?id=56957
3158
3159         Guard against the parameter of setAnimating() matching the ivar value it's 
3160         setting, thus avoiding tearing down the renderer's layer backing.
3161
3162         * rendering/RenderFullScreen.cpp:
3163         (RenderFullScreen::setAnimating):
3164
3165 2011-05-19  Julien Chaffraix  <jchaffraix@codeaurora.org>
3166
3167         Reviewed by Adam Barth.
3168
3169         Remove Node::deprecatedParserAddChild
3170         https://bugs.webkit.org/show_bug.cgi?id=60818
3171
3172         Refactoring only so no new tests.
3173
3174         This patch fails short of one instance of deprecatedParserAddChild which will
3175         require a refactoring of <input> shadow DOM to be removed.
3176
3177         * dom/XMLDocumentParser.cpp:
3178         (WebCore::XMLDocumentParser::pushCurrentNode): Updated to use a ContainerNode.
3179         (WebCore::XMLDocumentParser::clearCurrentNodeStack): We now need to clear
3180         up m_leafTextNode too.
3181
3182         (WebCore::XMLDocumentParser::enterText):
3183         (WebCore::XMLDocumentParser::exitText):
3184         Those methods were updated to use m_leafTextNode instead of m_currentNode.
3185
3186         * dom/XMLDocumentParser.h:
3187         Changed the currentNode logic to use ContainerNode. Also fixed the style of the
3188         forward declarations.
3189
3190         * dom/XMLDocumentParserLibxml2.cpp:
3191         (WebCore::XMLDocumentParser::startElementNs):
3192         (WebCore::XMLDocumentParser::endElementNs):
3193         (WebCore::XMLDocumentParser::characters):
3194         (WebCore::XMLDocumentParser::processingInstruction):
3195         (WebCore::XMLDocumentParser::cdataBlock):
3196         (WebCore::XMLDocumentParser::comment):
3197         * dom/XMLDocumentParserQt.cpp:
3198         (WebCore::XMLDocumentParser::parse):
3199         (WebCore::XMLDocumentParser::parseStartElement):
3200         (WebCore::XMLDocumentParser::parseEndElement):
3201         (WebCore::XMLDocumentParser::parseCharacters):
3202         (WebCore::XMLDocumentParser::parseProcessingInstruction):
3203         (WebCore::XMLDocumentParser::parseCdata):
3204         (WebCore::XMLDocumentParser::parseComment):
3205         Removed the calls to deprecatedParserAddChild, changed the code to use
3206         m_leafTextNode when it made sense and used ContainerNode instead of
3207         Node for m_currentNode.
3208
3209 2011-05-19  Mike Lawther  <mikelawther@chromium.org>
3210
3211         Reviewed by Simon Fraser.
3212
3213         implement image-rendering: optimize-contrast (with a vendor prefix) as defined in CSS3 image values
3214         https://bugs.webkit.org/show_bug.cgi?id=56627
3215
3216         Tests: css3/images/optimize-contrast-canvas.html
3217                css3/images/optimize-contrast-image.html
3218
3219         * WebCore.xcodeproj/project.pbxproj:
3220         * css/CSSComputedStyleDeclaration.cpp:
3221         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3222         * css/CSSParser.cpp:
3223         (WebCore::CSSParser::parseValue):
3224         * css/CSSPrimitiveValueMappings.h:
3225         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
3226         (WebCore::CSSPrimitiveValue::operator EImageRendering):
3227         * css/CSSPropertyNames.in:
3228         * css/CSSStyleSelector.cpp:
3229         (WebCore::CSSStyleSelector::applyProperty):
3230         * css/CSSValueKeywords.in:
3231         * css/SVGCSSComputedStyleDeclaration.cpp:
3232         (WebCore::CSSComputedStyleDeclaration::getSVGPropertyCSSValue):
3233         * css/SVGCSSPropertyNames.in:
3234         * css/SVGCSSStyleSelector.cpp:
3235         (WebCore::CSSStyleSelector::applySVGProperty):
3236         * css/SVGCSSValueKeywords.in:
3237         * html/HTMLCanvasElement.cpp:
3238         (WebCore::HTMLCanvasElement::paint):
3239         * html/HTMLCanvasElement.h:
3240         * platform/graphics/ImageRenderingMode.h: Added.
3241         * rendering/RenderBoxModelObject.cpp:
3242         (WebCore::ImageQualityController::shouldPaintAtLowQuality):
3243         * rendering/RenderHTMLCanvas.cpp:
3244         (WebCore::RenderHTMLCanvas::paintReplaced):
3245         * rendering/style/RenderStyle.cpp:
3246         (WebCore::RenderStyle::diff):
3247         * rendering/style/RenderStyle.h:
3248         (WebCore::InheritedFlags::imageRendering):
3249         (WebCore::InheritedFlags::setImageRendering):
3250         (WebCore::InheritedFlags::initialImageRendering):
3251         * rendering/style/RenderStyleConstants.h:
3252         * rendering/style/SVGRenderStyle.cpp:
3253         (WebCore::SVGRenderStyle::diff):
3254         * rendering/style/SVGRenderStyle.h:
3255         (WebCore::SVGRenderStyle::InheritedFlags::operator==):
3256         (WebCore::SVGRenderStyle::setBitDefaults):
3257         * rendering/style/SVGRenderStyleDefs.h:
3258         * rendering/svg/SVGRenderTreeAsText.cpp:
3259         (WebCore::writeStyle):
3260
3261 2011-05-18  Kenneth Russell  <kbr@google.com>
3262
3263         Reviewed by James Robinson.
3264
3265         [chromium] Disable blending in compositor for WebGL layers with alpha=false
3266         https://bugs.webkit.org/show_bug.cgi?id=61091
3267
3268         Test: compositing/webgl/webgl-no-alpha.html
3269
3270         * platform/graphics/chromium/CanvasLayerChromium.cpp:
3271         (WebCore::CanvasLayerChromium::CanvasLayerChromium):
3272         (WebCore::CanvasLayerChromium::pushPropertiesTo):
3273         * platform/graphics/chromium/CanvasLayerChromium.h:
3274         * platform/graphics/chromium/WebGLLayerChromium.cpp:
3275         (WebCore::WebGLLayerChromium::setContext):
3276         * platform/graphics/chromium/cc/CCCanvasLayerImpl.cpp:
3277         (WebCore::CCCanvasLayerImpl::CCCanvasLayerImpl):
3278         (WebCore::CCCanvasLayerImpl::draw):
3279         * platform/graphics/chromium/cc/CCCanvasLayerImpl.h:
3280         (WebCore::CCCanvasLayerImpl::setHasAlpha):
3281
3282 2011-05-18  Jeremy Noble  <jer.noble@apple.com>
3283
3284         Reviewed by Darin Adler.
3285
3286         Poster is not shown in Safari for video element with no playable source elements.
3287         https://bugs.webkit.org/show_bug.cgi?id=61109
3288
3289         Test: media/video-src-invalid-poster.html
3290
3291         In the case where no video sources are playable, update the display state and 
3292         renderer, allowing the poster image to display.
3293
3294         * html/HTMLMediaElement.cpp:
3295         (WebCore::HTMLMediaElement::waitForSourceChange): 
3296
3297 2011-05-19  Andrew Wilson  <atwilson@chromium.org>
3298
3299         Reviewed by Darin Adler.
3300
3301         MessagePortArray cloning code needs to verify source before copying.
3302         https://bugs.webkit.org/show_bug.cgi?id=61130
3303
3304         * bindings/js/JSMessagePortCustom.cpp:
3305         (WebCore::fillMessagePortArray):
3306         Changed code to not pre-allocate the destination array.
3307         * bindings/v8/custom/V8MessagePortCustom.cpp:
3308         (WebCore::getMessagePortArray):
3309         Changed code to not pre-allocate the destination array.
3310
3311 2011-05-19  Sheriff Bot  <webkit.review.bot@gmail.com>
3312
3313         Unreviewed, rolling out r86869, r86873, r86875, and r86877.
3314         http://trac.webkit.org/changeset/86869
3315         http://trac.webkit.org/changeset/86873
3316         http://trac.webkit.org/changeset/86875
3317         http://trac.webkit.org/changeset/86877
3318         https://bugs.webkit.org/show_bug.cgi?id=61139
3319
3320         broke builds and debug DRT (Requested by rniwa on #webkit).
3321
3322         * DerivedSources.make:
3323         * WebCore.exp.in:
3324         * WebCore.gyp/WebCore.gyp:
3325         * WebCore.gypi:
3326         * WebCore.xcodeproj/project.pbxproj:
3327         * testing/Internals.cpp: Removed.
3328         * testing/Internals.h: Removed.
3329         * testing/Internals.idl: Removed.
3330         * testing/js/WebCoreTestSupport.cpp: Removed.
3331         * testing/js/WebCoreTestSupport.h: Removed.
3332         * testing/v8/WebCoreTestSupport.cpp: Removed.
3333         * testing/v8/WebCoreTestSupport.h: Removed.
3334
3335 2011-05-19  Dimitri Glazkov  <dglazkov@chromium.org>
3336
3337         One more fix after r86869.
3338
3339         * WebCore.exp.in: Made __ZN7WebCore12JSDOMWrapperD2Ev only export for debug builds.
3340
3341 2011-05-19  Anders Carlsson  <andersca@apple.com>
3342
3343         Add two more symbols needed by the window.internals library.
3344
3345         * WebCore.exp.in:
3346
3347 2011-05-19  Dimitri Glazkov  <dglazkov@chromium.org>
3348
3349         Fix Leopard build after r86869.
3350
3351         * WebCore.exp.in: Moved now-always-used exported symbols out of the conditional guard.
3352
3353 2011-05-19  Robert Hogan  <robert@webkit.org>
3354
3355         Reviewed by Andreas Kling.
3356
3357         [Qt] Fix plugins/windowless_plugin_paint_test.html
3358         https://bugs.webkit.org/show_bug.cgi?id=60992
3359
3360         Call gdk_init_check before gdk_display_get_default().
3361         If we don't do this, gdk_display_get_default() will hang
3362         the next time it's called.
3363
3364         * plugins/qt/PluginViewQt.cpp:
3365         (WebCore::getPluginDisplay):
3366
3367 2011-05-18  Dimitri Glazkov  <dglazkov@chromium.org>
3368
3369         Reviewed by Darin Adler.
3370
3371         Add build logistics and plumbing for window.internals object.
3372         https://bugs.webkit.org/show_bug.cgi?id=60313
3373
3374         Test: fast/harness/internals-object.html
3375
3376         * DerivedSources.make: Added support for generating from Internals.idl.
3377         * WebCore.gyp/WebCore.gyp: Added new webcore_test_support library.
3378         * WebCore.gypi: Ditto.
3379         * WebCore.xcodeproj/project.pbxproj: Added WebCoreTestSupport library.
3380         * testing/Internals.cpp: Added.
3381         * testing/Internals.h: Added.
3382         * testing/Internals.idl: Added.
3383         * testing/js/WebCoreTestSupport.cpp: Added.
3384         * testing/js/WebCoreTestSupport.h: Added.
3385         * testing/v8/WebCoreTestSupport.cpp: Added.
3386         * testing/v8/WebCoreTestSupport.h: Added.
3387
3388 2011-05-19  Dimitri Glazkov  <dglazkov@chromium.org>
3389
3390         Accept XCode's decisions to keep modifying WebCore.xcodeproj.
3391
3392         * WebCore.xcodeproj/project.pbxproj: Opened in XCode then closed.
3393
3394 2011-05-19  Andrew Wason  <rectalogic@rectalogic.com>
3395
3396         Reviewed by Darin Adler.
3397
3398         Fix GraphicsContext3DQt.cpp compile error
3399         https://bugs.webkit.org/show_bug.cgi?id=61128
3400
3401         * platform/graphics/qt/GraphicsContext3DQt.cpp:
3402         (WebCore::GraphicsContext3D::GraphicsContext3D):
3403          clear() m_internal OwnPtr.
3404
3405 2011-05-19  Tonis Tiigi  <tonistiigi@gmail.com>
3406
3407         Reviewed by Pavel Feldman.
3408
3409         Web Inspector: Resizing columns in the network panel is weird
3410         https://bugs.webkit.org/show_bug.cgi?id=55238
3411
3412         Makes network panel column resizing more usable by adding "first only" and "last only"
3413         resizing methods to WebInspector.DataGrid. Current behavior is named "nearest" and
3414         remains default. Network panels datagrid is set to use method "last".
3415
3416         * inspector/front-end/DataGrid.js:
3417         (WebInspector.DataGrid.prototype.get resizeMethod):
3418         (WebInspector.DataGrid.prototype.set resizeMethod):
3419         (WebInspector.DataGrid.prototype._resizerDragging):
3420         * inspector/front-end/NetworkPanel.js:
3421         (WebInspector.NetworkPanel.prototype._createTable):
3422
3423 2011-05-19  Ryosuke Niwa  <rniwa@webkit.org>
3424
3425         Reviewed by Darin Adler.
3426
3427         JoinTextNodesCommand is never used
3428         https://bugs.webkit.org/show_bug.cgi?id=61089
3429
3430         Deleted JoinTextNodesCommand because it's never used.
3431
3432         * CMakeLists.txt:
3433         * GNUmakefile.list.am:
3434         * WebCore.gypi:
3435         * WebCore.pro:
3436         * WebCore.vcproj/WebCore.vcproj:
3437         * WebCore.xcodeproj/project.pbxproj:
3438         * editing/CompositeEditCommand.cpp:
3439         * editing/CompositeEditCommand.h:
3440         * editing/EditingAllInOne.cpp:
3441         * editing/JoinTextNodesCommand.cpp: Removed.
3442         * editing/JoinTextNodesCommand.h: Removed.
3443
3444 2011-05-19  Ryosuke Niwa  <rniwa@webkit.org>
3445
3446         Reviewed by Darin Adler.
3447
3448         REGRESSION (r83322): Many crashes in Mail.app in WebCore::Node::nodeIndex
3449         https://bugs.webkit.org/show_bug.cgi?id=61012
3450
3451         The crash was caused by ReplaceSelectionCommand's inserting content into a middle of the paragraph
3452         being moved when the insertion position's container node is the node to split to. Fixed the crash
3453         by not changing the insertion position in such a case.
3454
3455         Unfortunately, this fix caused markup to bloat in some tests but we'll take this regression since
3456         it's much better than crashing.
3457
3458         Test: editing/pasteboard/paste-after-inline-style-element.html
3459
3460         * editing/ReplaceSelectionCommand.cpp:
3461         (WebCore::ReplaceSelectionCommand::doApply):
3462
3463 2011-05-19  Brady Eidson  <beidson@apple.com>
3464
3465         Try to fix SUPPORT_AUTOCORRECTION_PANEL build.
3466
3467         * editing/SpellingCorrectionController.cpp:
3468         (WebCore::SpellingCorrectionController::recordSpellcheckerResponseForModifiedCorrection):
3469         (WebCore::SpellingCorrectionController::processMarkersOnTextToBeReplacedByResult):
3470
3471 2011-05-19  Darin Adler  <darin@apple.com>
3472
3473         Try to fix SUPPORT_AUTOCORRECTION_PANEL build.
3474
3475         * editing/SpellingCorrectionController.cpp:
3476         (WebCore::markersHaveIdenticalDescription): Call description() function.
3477
3478 2011-05-19  Andrey Adaikin  <aandrey@google.com>
3479
3480         Reviewed by Pavel Feldman.
3481
3482         Web Inspector: switch to Scripts panel is too slow
3483         https://bugs.webkit.org/show_bug.cgi?id=61030
3484
3485         - It is very expensive to listen to the DOM mutation events, thus we remove the listeners whenever we do any internal
3486         DOM manipulations (such as expand/collapse line rows) and set the listeners back when we are finished.
3487         - Also, when we switch to the Scripts panel that have a non-zero scrollTop offset, we would do the rendering work twice.
3488
3489         * inspector/front-end/SourceFrame.js:
3490         (WebInspector.SourceFrame.prototype.show):
3491         * inspector/front-end/TextViewer.js:
3492         (WebInspector.TextEditorMainPanel):
3493         (WebInspector.TextEditorMainPanel.prototype.beginDomUpdates):
3494         (WebInspector.TextEditorMainPanel.prototype.endDomUpdates):
3495         (WebInspector.TextEditorMainPanel.prototype._enableDOMNodeRemovedListener):
3496         (WebInspector.TextEditorMainChunk):
3497         (WebInspector.TextEditorMainChunk.prototype.set expanded):
3498         (WebInspector.TextEditorMainChunk.prototype._createRow):
3499
3500 2011-05-19  Pavel Feldman  <pfeldman@google.com>
3501
3502         Not reviewed: inspector protocol tests fixed.
3503
3504         * inspector/InjectedScriptSource.js:
3505
3506 2011-05-19  David Grogan  <dgrogan@chromium.org>
3507
3508         Reviewed by David Levin.
3509
3510         Make EventQueue post a Task to the task queue for each asynchronous event
3511         https://bugs.webkit.org/show_bug.cgi?id=60790
3512
3513         Currently EventQueue queues up events to be fired asynchronously and
3514         fires each of them when a single DOMTimer goes off.  In the words of
3515         dimich, "Having 2 queues will sooner or later cause problems with
3516         ordering of tasks, termination, suspension and other things that all
3517         require some control on how queues operate."
3518
3519         No new tests; this is just a refactoring to avoid potential future
3520         problems.
3521
3522         * dom/EventQueue.cpp:
3523         (WebCore::EventQueue::EventQueue):
3524         (WebCore::EventQueue::EventDispatcherTask::create):
3525         (WebCore::EventQueue::EventDispatcherTask::dispatchEvent):
3526         (WebCore::EventQueue::EventDispatcherTask::performTask):
3527         (WebCore::EventQueue::EventDispatcherTask::cancel):
3528         (WebCore::EventQueue::EventDispatcherTask::EventDispatcherTask):
3529         (WebCore::EventQueue::removeEvent):
3530         (WebCore::EventQueue::enqueueEvent):
3531         (WebCore::EventQueue::enqueueOrDispatchScrollEvent):
3532         (WebCore::EventQueue::cancelEvent):
3533         (WebCore::EventQueue::cancelQueuedEvents):
3534         * dom/EventQueue.h:
3535
3536 2011-05-18  Yury Semikhatsky  <yurys@chromium.org>
3537
3538         Reviewed by Pavel Feldman.
3539
3540         InjectedScriptSource.js - "Don't be eval()."
3541         https://bugs.webkit.org/show_bug.cgi?id=60800
3542
3543         Thanks to Adam Barth for providing JSC implementation!
3544
3545         InjectedScriptHost.evaluate is used to perform script evaluations for
3546         inspector needs. This method is not affected by CSP and should fix inspector
3547         on pages with CSP restrictions.
3548
3549         Test: inspector/console/console-eval-blocked.html
3550
3551         * bindings/js/JSInjectedScriptHostCustom.cpp:
3552         (WebCore::JSInjectedScriptHost::evaluate):
3553         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
3554         (WebCore::V8InjectedScriptHost::evaluateCallback):
3555         (WebCore::V8InjectedScriptHost::inspectedNodeCallback):
3556         * inspector/InjectedScriptHost.idl:
3557         * inspector/InjectedScriptSource.js:
3558         (.):
3559
3560 2011-05-19  Pavel Feldman  <pfeldman@google.com>
3561
3562         Reviewed by Yury Semikhatsky.
3563
3564         Web Inspector: expose object class name as a part of RemoteObject mirror.
3565         https://bugs.webkit.org/show_bug.cgi?id=61067
3566
3567         * inspector/InjectedScriptSource.js:
3568         * inspector/Inspector.json:
3569
3570 2011-05-19  Pavel Feldman  <pfeldman@google.com>
3571
3572         Reviewed by Yury Semikhatsky.
3573
3574         Web Inspector: make "this" a part of callFrame, not scope in the protocol.
3575         https://bugs.webkit.org/show_bug.cgi?id=61057
3576
3577         * inspector/InjectedScriptSource.js:
3578         * inspector/Inspector.json:
3579         * inspector/front-end/ScopeChainSidebarPane.js:
3580         (WebInspector.ScopeChainSidebarPane.prototype.update):
3581
3582 2011-05-19  Kent Tamura  <tkent@chromium.org>
3583
3584         Reviewed by Hajime Morita.
3585
3586         tooLong validity should not be true for a value set by a script
3587         https://bugs.webkit.org/show_bug.cgi?id=60948
3588
3589         The specification has been updated so that tooLong should be true only
3590         for user-edit values.
3591         
3592         Introduce m_wasModifiedByUser flag to HTMLInputElement and
3593         HTMLTextAreaElemnt. It is set to true when a renderer updates the
3594         value, and is cleared when the value is updated by others.
3595
3596         * html/HTMLInputElement.cpp:
3597         (WebCore::HTMLInputElement::HTMLInputElement):
3598           Initialize m_wasModifiedByUser.
3599         (WebCore::HTMLInputElement::tooLong):
3600           Skip the check if m_wasModifiedByUser is false.
3601         (WebCore::HTMLInputElement::updateType): Clear m_wasModifiedByUser.
3602         (WebCore::HTMLInputElement::copyNonAttributeProperties):
3603         (WebCore::HTMLInputElement::setValue): If sendChange is true,
3604           m_wasModifiedByUser should be true because sendChange is set in a case
3605           of form auto-fill.  We assume a value set by form auto-fill is a kind
3606           of user-edit.
3607         (WebCore::HTMLInputElement::setValueFromRenderer):
3608           m_wasModifiedByUser should be true for the update by a renderer.
3609         * html/HTMLInputElement.h: Declare m_wasModifiedByUser.
3610         * html/HTMLTextAreaElement.cpp:
3611         (WebCore::HTMLTextAreaElement::HTMLTextAreaElement):
3612           Initialize m_wasModifiedByUser.
3613         (WebCore::HTMLTextAreaElement::updateValue):
3614           m_wasModifiedByUser should be true for the update by a renderer.
3615         (WebCore::HTMLTextAreaElement::setValueCommon): Clear m_wasModifiedByUser.
3616         (WebCore::HTMLTextAreaElement::tooLong):
3617           Skip the check if m_wasModifiedByUser is false.
3618         * html/HTMLTextAreaElement.h: Declare m_wasModifiedByUser.
3619
3620 2011-05-19  David Barr  <davidbarr@chromium.org>
3621
3622         Reviewed by Simon Fraser.
3623
3624         CSS3: We fail 'border radius sum of radii' test
3625         https://bugs.webkit.org/show_bug.cgi?id=38788
3626
3627         Ignore border-radius properties with negative values.
3628
3629         Test: fast/css/border-radius-non-negative.html
3630
3631         * WebCore.xcodeproj/project.pbxproj:
3632         * css/CSSParser.cpp:
3633         (WebCore::CSSParser::parseValue):
3634         (WebCore::CSSParser::parseBorderRadius):
3635
3636 2011-05-19  Yuta Kitamura  <yutak@chromium.org>
3637
3638         Reviewed by Kent Tamura.
3639
3640         WebSocket: Use ScriptContext::Task to hold pending events of ThreadableWebSocketChannelClientWrapper
3641         https://bugs.webkit.org/show_bug.cgi?id=61034
3642
3643         Refactoring only. No new tests.
3644
3645         * websockets/ThreadableWebSocketChannelClientWrapper.cpp:
3646         (WebCore::ThreadableWebSocketChannelClientWrapper::ThreadableWebSocketChannelClientWrapper):
3647         (WebCore::ThreadableWebSocketChannelClientWrapper::didConnect):
3648         (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessage):
3649         (WebCore::ThreadableWebSocketChannelClientWrapper::didClose):
3650         (WebCore::ThreadableWebSocketChannelClientWrapper::resume):
3651         (WebCore::ThreadableWebSocketChannelClientWrapper::processPendingTasks):
3652         (WebCore::ThreadableWebSocketChannelClientWrapper::didConnectCallback):
3653         (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessageCallback):
3654         (WebCore::ThreadableWebSocketChannelClientWrapper::didCloseCallback):
3655         * websockets/ThreadableWebSocketChannelClientWrapper.h:
3656         Remove m_pendingConnected, m_pendingMessages and m_pendingClosed, and use ScriptContext::Task
3657         to hold these pending events.
3658
3659 2011-05-19  Emil A Eklund  <eae@chromium.org>
3660
3661         Reviewed by Alexey Proskuryakov.
3662
3663         REGRESSION (r80808): Multiple <select> - Selection reset to first element from multiple selected ones
3664         https://bugs.webkit.org/show_bug.cgi?id=60986
3665
3666         * html/HTMLSelectElement.cpp:
3667         (WebCore::HTMLSelectElement::setMultiple):
3668         Don't restore selection if the multiple attribute hasn't changed.
3669
3670 2011-05-18  Fumitoshi Ukai  <ukai@chromium.org>
3671
3672         Reviewed by Alexey Proskuryakov.
3673
3674         http/tests/websocket/tests/workers/worker-handshake-challenge-randomness.html crashed once on Windows XP Debug (Tests)
3675         https://bugs.webkit.org/show_bug.cgi?id=57048
3676
3677         * platform/network/cf/SocketStreamHandleCFNet.cpp:
3678         (WebCore::SocketStreamHandle::platformClose): use loaderRunLoop to schedule streams on platform WIN
3679
3680 2011-05-18  MORITA Hajime  <morrita@google.com>
3681
3682         Unreviewed attempt to fix clang build.
3683
3684         * rendering/InlineTextBox.h:
3685
3686 2011-05-18  Nat Duca  <nduca@chromium.org>
3687
3688         Reviewed by James Robinson.
3689
3690         [chromium] Add histograms for paint times
3691         https://bugs.webkit.org/show_bug.cgi?id=61010
3692
3693         * platform/graphics/chromium/ContentLayerChromium.cpp:
3694         (WebCore::ContentLayerPainter::paint):
3695
3696 2011-05-18  Adrienne Walker  <enne@google.com>
3697
3698         Reviewed by James Robinson.
3699
3700         [chromium] Fix incorrect size when clipping image layer upload rects
3701         https://bugs.webkit.org/show_bug.cgi?id=61105
3702
3703         The clipped destination and source rects should have the same size.
3704
3705         * platform/graphics/chromium/ImageLayerChromium.cpp:
3706         (WebCore::ImageLayerTextureUpdater::updateTextureRect):
3707
3708 2011-05-17  MORITA Hajime  <morrita@google.com>
3709
3710         Reviewed by Tony Chang.
3711
3712         [Refactoring] Member variables of DocumentMarker should be encapsulated.
3713         https://bugs.webkit.org/show_bug.cgi?id=56814
3714
3715         - Moved DocumentMarker's member variables to private and added getters for them.
3716         - Added DocumentMarker setters and constructors, which contain assertions against m_type values
3717           because description and activeMatch are used with specific type of MarkerType.
3718         - Moved chromium's WebKit::WebFrameImpl::addMarker() to DocumentMarkerController::addTextMatchMarker()
3719           because it accesses DocumentMarker internals.
3720         - Moved a version of DMC::addMarker() to private and add alternatives that hide
3721           internals of DocumentMarker. (The internal will be renewed by upcoming change.)
3722         
3723         * dom/DocumentMarker.h:
3724         (WebCore::DocumentMarker::type):
3725         (WebCore::DocumentMarker::startOffset):
3726         (WebCore::DocumentMarker::endOffset):
3727         (WebCore::DocumentMarker::description):
3728         (WebCore::DocumentMarker::hasDescription):
3729         (WebCore::DocumentMarker::activeMatch):
3730         (WebCore::DocumentMarker::clearDescription):
3731         (WebCore::DocumentMarker::setStartOffset):
3732         (WebCore::DocumentMarker::setEndOffset):
3733         (WebCore::DocumentMarker::operator==):
3734         (WebCore::DocumentMarker::DocumentMarker):
3735         (WebCore::DocumentMarker::shiftOffsets):
3736         (WebCore::DocumentMarker::setActiveMatch):
3737         * dom/DocumentMarkerController.cpp:
3738         (WebCore::DocumentMarkerController::addMarker):
3739         (WebCore::DocumentMarkerController::addTextMatchMarker):
3740         (WebCore::DocumentMarkerController::copyMarkers):
3741         (WebCore::DocumentMarkerController::removeMarkers):
3742         (WebCore::DocumentMarkerController::markerContainingPoint):
3743         (WebCore::DocumentMarkerController::markersInRange):
3744         (WebCore::DocumentMarkerController::renderedRectsForMarkers):
3745         (WebCore::DocumentMarkerController::removeMarkersFromList):
3746         (WebCore::DocumentMarkerController::repaintMarkers):
3747         (WebCore::DocumentMarkerController::shiftMarkers):
3748         (WebCore::DocumentMarkerController::setMarkersActive):
3749         (WebCore::DocumentMarkerController::hasMarkers):
3750         (WebCore::DocumentMarkerController::clearDescriptionOnMarkersIntersectingRange):
3751         (WebCore::DocumentMarkerController::showMarkers):
3752         * dom/DocumentMarkerController.h:
3753         * editing/CompositeEditCommand.cpp:
3754         (WebCore::CompositeEditCommand::replaceTextInNodePreservingMarkers):
3755         * editing/DeleteSelectionCommand.cpp:
3756         (WebCore::DeleteSelectionCommand::originalStringForAutocorrectionAtBeginningOfSelection):
3757         * editing/Editor.cpp:
3758         (WebCore::Editor::selectionStartHasMarkerFor):
3759         * editing/SpellingCorrectionController.cpp:
3760         (WebCore::SpellingCorrectionController::respondToChangedSelection):
3761         * editing/SpellingCorrectionController.h:
3762         (WebCore::SpellingCorrectionController::shouldStartTimerFor):
3763         * rendering/HitTestResult.cpp:
3764         (WebCore::HitTestResult::spellingToolTip):
3765         (WebCore::HitTestResult::replacedString):
3766         * rendering/InlineTextBox.cpp:
3767         (WebCore::InlineTextBox::paintSpellingOrGrammarMarker):
3768         (WebCore::InlineTextBox::paintTextMatchMarker):
3769         (WebCore::InlineTextBox::computeRectForReplacementMarker):
3770         (WebCore::InlineTextBox::paintDocumentMarkers):
3771         * rendering/svg/SVGInlineFlowBox.cpp:
3772         (WebCore::SVGInlineFlowBox::computeTextMatchMarkerRectForRenderer):
3773
3774 2011-05-18  Oliver Hunt  <oliver@apple.com>
3775
3776         Reviewed by Geoffrey Garen.
3777
3778         +[WebScriptObject throwException:] doesn't work when invoked from obj-c field access
3779         https://bugs.webkit.org/show_bug.cgi?id=61100
3780
3781         The objc bindings were written to assume exceptions would
3782         come from obj-c style exceptions, rather than throwException:
3783         This code simply calls the global ObjcInstance mechanism for
3784         transferring the reported exception.
3785
3786         * bridge/objc/objc_instance.h:
3787         * bridge/objc/objc_runtime.mm:
3788         (JSC::Bindings::ObjcField::valueFromInstance):
3789         (JSC::Bindings::ObjcField::setValueToInstance):
3790
3791 2011-05-16  Adrienne Walker  <enne@google.com>
3792
3793         Reviewed by James Robinson.
3794
3795         [chromium] Robustly handle mapTexSubImage2D returning NULL
3796         https://bugs.webkit.org/show_bug.cgi?id=60934
3797
3798         Also, lazily create the temp buffer so that both the map and non-map
3799         cases can use it.
3800
3801         * platform/graphics/chromium/LayerTextureSubImage.cpp:
3802         (WebCore::LayerTextureSubImage::setSubImageSize):
3803         (WebCore::LayerTextureSubImage::uploadWithTexSubImage):
3804         (WebCore::LayerTextureSubImage::uploadWithMapTexSubImage):
3805
3806 2011-05-18  Emil A Eklund  <eae@chromium.org>
3807
3808         Reviewed by Darin Adler.
3809
3810         Change RenderTextControl::hitInnerTextElement to use IntPoint
3811         https://bugs.webkit.org/show_bug.cgi?id=61003
3812
3813         Covered by existing tests.
3814
3815         * rendering/RenderTextControl.cpp:
3816         (WebCore::RenderTextControl::hitInnerTextElement):
3817         * rendering/RenderTextControl.h:
3818         * rendering/RenderTextControlMultiLine.cpp:
3819         (WebCore::RenderTextControlMultiLine::nodeAtPoint):
3820         * rendering/RenderTextControlSingleLine.cpp:
3821         (WebCore::RenderTextControlSingleLine::nodeAtPoint):
3822
3823 2011-05-18  Chris Fleizach  <cfleizach@apple.com>
3824
3825         Reviewed by Maciej Stachowiak.
3826
3827         WK2: VoiceOver cannot move focus into a web area programmatically
3828         https://bugs.webkit.org/show_bug.cgi?id=60661
3829
3830         Accessibility code relies on the ability to bring focus to the containing widget view.
3831         In WK2, that message needs to be propagated to the UI process.
3832
3833         * page/ChromeClient.h:
3834         (WebCore::ChromeClient::makeFirstResponder):
3835         * page/mac/ChromeMac.mm:
3836         (WebCore::Chrome::focusNSView):
3837         * platform/mac/WidgetMac.mm:
3838         (WebCore::Widget::setFocus):
3839
3840 2011-05-18  Alok Priyadarshi  <alokp@chromium.org> and Adrienne Walker  <enne@google.com>
3841
3842         Reviewed by James Robinson.
3843
3844         [chromium] Split canvas from LayerTilerChromium
3845         https://bugs.webkit.org/show_bug.cgi?id=60719
3846
3847         LayerTilerChromium now just does tiling. It delegates the task of painting and updating textures to LayerTextureUpdater.
3848         Also abstracted LayerTextureSubImage to upload texture pixels.
3849
3850         * WebCore.gypi:
3851         * platform/chromium/TraceEvent.h:
3852         * platform/graphics/chromium/ContentLayerChromium.cpp:
3853         (WebCore::ContentLayerChromium::create):
3854         (WebCore::ContentLayerChromium::ContentLayerChromium):
3855         (WebCore::ContentLayerChromium::~ContentLayerChromium):
3856         (WebCore::ContentLayerChromium::paintContentsIfDirty):
3857         (WebCore::ContentLayerChromium::cleanupResources):
3858         (WebCore::ContentLayerChromium::setLayerRenderer):
3859         (WebCore::ContentLayerChromium::createTextureUpdater):
3860         (WebCore::ContentLayerChromium::drawsContent):
3861         (WebCore::ContentLayerChromium::createTilerIfNeeded):
3862         (WebCore::ContentLayerChromium::updateCompositorResources):
3863         * platform/graphics/chromium/ContentLayerChromium.h:
3864         * platform/graphics/chromium/ImageLayerChromium.cpp:
3865         (WebCore::ImageLayerTextureUpdater::ImageLayerTextureUpdater):
3866         (WebCore::ImageLayerTextureUpdater::~ImageLayerTextureUpdater):
3867         (WebCore::ImageLayerTextureUpdater::orientation):
3868         (WebCore::ImageLayerTextureUpdater::prepareToUpdate):
3869         (WebCore::ImageLayerTextureUpdater::updateTextureRect):
3870         (WebCore::ImageLayerTextureUpdater::imageRect):
3871         (WebCore::ImageLayerChromium::paintContentsIfDirty):
3872         (WebCore::ImageLayerChromium::updateCompositorResources):
3873         (WebCore::ImageLayerChromium::createTextureUpdater):
3874         * platform/graphics/chromium/ImageLayerChromium.h:
3875         * platform/graphics/chromium/LayerPainterChromium.h: Added.
3876         * platform/graphics/chromium/LayerRendererChromium.cpp:
3877         (WebCore::LayerRendererChromium::create):
3878         (WebCore::LayerRendererChromium::LayerRendererChromium):
3879         (WebCore::LayerRendererChromium::updateRootLayerContents):
3880         (WebCore::LayerRendererChromium::drawRootLayer):
3881         (WebCore::LayerRendererChromium::updateAndDrawLayers):
3882         (WebCore::LayerRendererChromium::updateLayers):
3883         * platform/graphics/chromium/LayerRendererChromium.h:
3884         * platform/graphics/chromium/LayerTextureSubImage.cpp: Added.
3885         (WebCore::LayerTextureSubImage::LayerTextureSubImage):
3886         (WebCore::LayerTextureSubImage::~LayerTextureSubImage):
3887         (WebCore::LayerTextureSubImage::setSubImageSize):
3888         (WebCore::LayerTextureSubImage::upload):
3889         (WebCore::LayerTextureSubImage::uploadWithTexSubImage):
3890         (WebCore::LayerTextureSubImage::uploadWithMapTexSubImage):
3891         * platform/graphics/chromium/LayerTextureSubImage.h: Copied from Source/WebCore/platform/chromium/TraceEvent.h.
3892         * platform/graphics/chromium/LayerTextureUpdater.h: Copied from Source/WebCore/platform/chromium/TraceEvent.h.
3893         (WebCore::LayerTextureUpdater::LayerTextureUpdater):
3894         (WebCore::LayerTextureUpdater::~LayerTextureUpdater):
3895         (WebCore::LayerTextureUpdater::context):
3896         * platform/graphics/chromium/LayerTextureUpdaterCanvas.cpp: Added.
3897         (WebCore::LayerTextureUpdaterCanvas::LayerTextureUpdaterCanvas):
3898         (WebCore::LayerTextureUpdaterCanvas::paintContents):
3899         (WebCore::LayerTextureUpdaterBitmap::LayerTextureUpdaterBitmap):
3900         (WebCore::LayerTextureUpdaterBitmap::prepareToUpdate):
3901         (WebCore::LayerTextureUpdaterBitmap::updateTextureRect):
3902         * platform/graphics/chromium/LayerTextureUpdaterCanvas.h: Added.
3903         (WebCore::LayerTextureUpdaterCanvas::~LayerTextureUpdaterCanvas):
3904         (WebCore::LayerTextureUpdaterCanvas::contentRect):
3905         (WebCore::LayerTextureUpdaterBitmap::~LayerTextureUpdaterBitmap):
3906         (WebCore::LayerTextureUpdaterBitmap::orientation):
3907         * platform/graphics/chromium/LayerTilerChromium.cpp:
3908         (WebCore::LayerTilerChromium::create):
3909         (WebCore::LayerTilerChromium::LayerTilerChromium):
3910         (WebCore::LayerTilerChromium::setTileSize):
3911         (WebCore::LayerTilerChromium::prepareToUpdate):
3912         (WebCore::LayerTilerChromium::updateRect):
3913         (WebCore::LayerTilerChromium::draw):
3914         * platform/graphics/chromium/LayerTilerChromium.h:
3915         (WebCore::LayerTilerChromium::Tile::Tile):
3916         * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
3917         (WebCore::CCHeadsUpDisplay::draw):
3918
3919 2011-05-18  Mark Pilgrim  <pilgrim@chromium.org>
3920
3921         Reviewed by Tony Chang.
3922
3923         IndexedDB put() should fail adding to object store that uses
3924         out-of-line keys and has no key generator and the key parameter
3925         was not provided
3926         https://bugs.webkit.org/show_bug.cgi?id=58609
3927
3928         Out-of-line keys means that objectStore->m_keyPath is null in ::put(),
3929         no key generator means that objectStore->autoIncrement() is false, and
3930         key parameter was not provided means that prpKey will be a null pointer.
3931         The combination of these 3 should throw a DATA_ERR.
3932
3933         Test: storage/indexeddb/mozilla/key-requirements-put-no-key.html
3934
3935         * storage/IDBObjectStoreBackendImpl.cpp:
3936         (WebCore::IDBObjectStoreBackendImpl::put):
3937
3938 2011-05-18  Chris Rogers  <crogers@google.com>
3939
3940         Reviewed by James Robinson.
3941
3942         EqualPowerPanner is not using the correct azimuth range for stereo panning
3943         https://bugs.webkit.org/show_bug.cgi?id=61085
3944
3945         No new tests since audio API is not yet implemented.
3946
3947         * platform/audio/EqualPowerPanner.cpp:
3948         (WebCore::EqualPowerPanner::pan):
3949
3950 2011-05-18  Yi Shen  <yi.4.shen@nokia.com>
3951
3952         Reviewed by Andreas Kling.
3953
3954         [Qt] Enterkey to go to Newline does not work in the text area(in HTML form)
3955         https://bugs.webkit.org/show_bug.cgi?id=33179
3956
3957         Fill the missing key text for the EnterKey event.
3958
3959         Tests: fast/events/onsearch-enter.html
3960
3961         * platform/qt/PlatformKeyboardEventQt.cpp:
3962         (WebCore::keyTextForKeyEvent):
3963
3964 2011-05-17  Timothy Hatcher  <timothy@apple.com>
3965
3966         Update the the context menu to reflect the system search provider on Mac.
3967
3968         <rdar://problem/9198419>
3969
3970         Reviewed by Sam Weinig.
3971
3972         * English.lproj/Localizable.strings: Updated.
3973         * Source/WebCore/WebCore.exp.in: Added _wkCopyDefaultSearchProviderDisplayName.
3974         * platform/DefaultLocalizationStrategy.cpp:
3975         (WebCore::DefaultLocalizationStrategy::contextMenuItemTagSearchWeb): Use wkCopyDefaultSearchProviderDisplayName to
3976         create the string.
3977         * platform/mac/WebCoreSystemInterface.h: Added wkCopyDefaultSearchProviderDisplayName.
3978         * platform/mac/WebCoreSystemInterface.mm: Ditto.
3979
3980 2011-05-18  Rob Buis  <rbuis@rim.com>
3981
3982         Reviewed by Nikolas Zimmermann.
3983
3984         Marker test from ietestcenter fails
3985         https://bugs.webkit.org/show_bug.cgi?id=60721
3986
3987         Change <marker> renderer creation behaviour to always create the renderer. This fixes
3988         the problem that no marker is rendered when display=none is set on the <marker>. The
3989         specification states that display=none should have no influence on <marker> usage:
3990         "The ‘display’ property does not apply to the ‘marker’ element; thus, ..., and ‘marker’
3991         elements are available for referencing even when the ‘display’ property on the ‘marker’
3992         element or any of its ancestors is set to none."
3993
3994         Tests: svg/W3C-SVG-1.1-SE/painting-marker-07-f.svg
3995                svg/custom/painting-marker-07-f-inherit.svg
3996