2011-05-24 Leo Yang <leo.yang@torchmobile.com.cn>
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2011-05-24  Leo Yang  <leo.yang@torchmobile.com.cn>
2
3         Reviewed by Ryosuke Niwa.
4
5         [SVG] Assertion failure by dragging text between input fields inside <foreignObject>s
6         https://bugs.webkit.org/show_bug.cgi?id=60692
7
8         Add NULL check of 'holder' in WebCore::ReplacementFragment::ReplacementFragment()
9         before call VisibleSelection::selectionFromContentsOfNode() to prevent crashing.
10
11         Test: editing/pasteboard/drag-drop-input-in-svg.svg
12
13         * editing/ReplaceSelectionCommand.cpp:
14         (WebCore::ReplacementFragment::ReplacementFragment):
15
16 2011-05-24  Andy Estes  <aestes@apple.com>
17
18         Reviewed by Geoffrey Garen.
19
20         REGRESSION (r70748): WebKit cannot play QuickTime movies on Mac OS X Wiki Server pages
21         https://bugs.webkit.org/show_bug.cgi?id=61229
22
23         This site-specific hack maintains compatibility with Mac OS X Wiki Server,
24         which embeds QuickTime movies using an object tag containing QuickTime's
25         ActiveX classid. Treat this classid as valid only if OS X Server's unique
26         'generator' meta tag is present. Only apply this quirk if there is no
27         fallback content, which ensures the quirk will disable itself if Wiki
28         Server is updated to generate an alternate embed tag as fallback content.
29
30         * html/HTMLObjectElement.cpp:
31         (WebCore::HTMLObjectElement::shouldAllowQuickTimeClassIdQuirk): Return
32         true if site-specific quirks are enabled, the object element has no
33         fallback content, the classid attribute matches QuickTime's classid and
34         the document has a 'generator' meta tag matching Mac OS X Web Services
35         Server's unique generator string.
36         (WebCore::HTMLObjectElement::hasValidClassId): Call
37         shouldAllowQuickTimeClassIdQuirk()
38         * html/HTMLObjectElement.h:
39
40 2011-05-24  Nate Chapin  <japhet@chromium.org>
41
42         Reviewed by Adam Barth.
43
44         Change CachedResources to take a ResourceRequest instead of
45         a url in their constructors and provide a very minimal set of
46         cases for avoiding reusing a CachedResource. The ResourceRequest
47         part of this change requires pushing responsibility
48         for calling Document::completeURL() to the caller, instead of
49         CachedResourceLoader, since ResourceRequest ASSERTs if it
50         is constructed with an invalid url.
51
52         https://bugs.webkit.org/show_bug.cgi?id=61318
53
54         Refactor, no new tests.
55
56         * css/CSSFontSelector.cpp:
57         (WebCore::CSSFontSelector::addFontFaceRule):
58         * css/CSSImageValue.cpp:
59         (WebCore::CSSImageValue::cachedImage):
60         * css/CSSImportRule.cpp:
61         (WebCore::CSSImportRule::insertedIntoParent):
62         * dom/ProcessingInstruction.cpp:
63         (WebCore::ProcessingInstruction::checkStyleSheet):
64         * dom/ScriptElement.cpp:
65         (WebCore::ScriptElement::requestScript):
66         * html/HTMLLinkElement.cpp:
67         (WebCore::HTMLLinkElement::process):
68         * loader/ImageLoader.cpp:
69         (WebCore::ImageLoader::updateFromElement):
70         * loader/cache/CachedCSSStyleSheet.cpp:
71         (WebCore::CachedCSSStyleSheet::CachedCSSStyleSheet):
72         (WebCore::CachedCSSStyleSheet::didAddClient):
73         (WebCore::CachedCSSStyleSheet::checkNotify):
74         * loader/cache/CachedCSSStyleSheet.h:
75         * loader/cache/CachedFont.cpp:
76         (WebCore::CachedFont::CachedFont):
77         * loader/cache/CachedFont.h:
78         * loader/cache/CachedImage.cpp:
79         (WebCore::CachedImage::CachedImage):
80         (WebCore::CachedImage::checkShouldPaintBrokenImage):
81         * loader/cache/CachedImage.h:
82         * loader/cache/CachedResource.cpp:
83         (WebCore::CachedResource::CachedResource):
84         (WebCore::reuseRequest):
85         (WebCore::CachedResource::allowReuseOfRequest):
86         (WebCore::CachedResource::removeClient):
87         (WebCore::CachedResource::canUseCacheValidator):
88         * loader/cache/CachedResource.h:
89         (WebCore::CachedResource::resourceRequest):
90         (WebCore::CachedResource::url):
91         * loader/cache/CachedResourceLoader.cpp:
92         * loader/cache/CachedResourceLoader.h:
93         * loader/cache/CachedResourceRequest.cpp:
94         (WebCore::CachedResourceRequest::load):
95         * loader/cache/CachedScript.cpp:
96         (WebCore::CachedScript::CachedScript):
97         * loader/cache/CachedScript.h:
98         * loader/cache/CachedXSLStyleSheet.cpp:
99         (WebCore::CachedXSLStyleSheet::CachedXSLStyleSheet):
100         (WebCore::CachedXSLStyleSheet::didAddClient):
101         (WebCore::CachedXSLStyleSheet::checkNotify):
102         * loader/cache/CachedXSLStyleSheet.h:
103         * svg/SVGFEImageElement.cpp:
104         (WebCore::SVGFEImageElement::requestImageResource):
105         * svg/SVGFontFaceUriElement.cpp:
106         (WebCore::SVGFontFaceUriElement::loadFont):
107         * xml/XSLImportRule.cpp:
108         (WebCore::XSLImportRule::loadSheet):
109
110 2011-05-24  Kent Tamura  <tkent@chromium.org>
111
112         Reviewed by Dimitri Glazkov.
113
114         Use Element::shadowPseudoId() for text field decoration elements
115         https://bugs.webkit.org/show_bug.cgi?id=61351
116
117         No new tests. Covered by existing tests.
118
119         * css/CSSSelector.cpp: Remove support for the following static pseudo selectors:
120           - -webkit-inner-spin-button
121           - -webkit-input-speech-button
122           - -webkit-outer-spin-button
123           - -webkit-search-cancel-button
124           - -webkit-search-decoration
125           - -webkit-search-results-button
126           - -webkit-search-results-decoration
127         (WebCore::CSSSelector::pseudoId):
128         (WebCore::nameToPseudoTypeMap):
129         (WebCore::CSSSelector::extractPseudoType):
130         * css/CSSSelector.h: ditto.
131         * css/CSSStyleSelector.cpp:
132         (WebCore::CSSStyleSelector::matchRules):
133           Store shadowPseudoId() result in a local variable because
134           SearchFieldResultsButtonElement::shadowPseudoId() is a little expensive.
135         * html/shadow/TextControlInnerElements.cpp:
136          Override Element::shadowPseudoId() instead of Element::styleForRenderer().
137         (WebCore::SearchFieldResultsButtonElement::shadowPseudoId):
138         (WebCore::SearchFieldCancelButtonElement::shadowPseudoId):
139         (WebCore::SpinButtonElement::shadowPseudoId):
140         (WebCore::InputFieldSpeechButtonElement::shadowPseudoId):
141         * html/shadow/TextControlInnerElements.h: Update declarations.
142         * rendering/RenderTextControlSingleLine.cpp: Remove createFooStyle() functions.
143         * rendering/RenderTextControlSingleLine.h: ditto.
144         * rendering/style/RenderStyleConstants.h: Remove unused pseudo IDs.
145
146 2011-05-24  Dimitri Glazkov  <dglazkov@chromium.org>
147
148         Sorted WebCore.xcodeproj again.
149
150         * WebCore.xcodeproj/project.pbxproj: Ran sort-XCode-project-file.
151
152 2011-05-24  Stephanie Lewis  <slewis@apple.com>
153
154         Reviewed by Geoff Garen.
155
156         https://bugs.webkit.org/show_bug.cgi?id=61345
157         part of <rdar://problem/8675177>
158         Don't initialize ResourceResponse.m_suggestedFilename until we want to use it.  Initializing it requires reading in and parsing a plist.  
159         Add new initialization state CommonAndUncommonFields to ResourceResponse.  This will be for all the header fields.
160         Move suggestedFilename initialization to AllFields so it is never initialized unless we ask for it. 
161         Add "Content-Type" to common headers since it is looked for by every CSS sheet load.
162
163         No new tests because functionality has not changed.
164
165         * platform/network/ResourceResponseBase.cpp:
166         (WebCore::ResourceResponseBase::adopt):
167         (WebCore::ResourceResponseBase::suggestedFilename):
168         (WebCore::ResourceResponseBase::setSuggestedFilename):
169         (WebCore::ResourceResponseBase::httpStatusText):
170         (WebCore::ResourceResponseBase::setHTTPStatusText):
171         (WebCore::ResourceResponseBase::httpHeaderField):
172         (WebCore::ResourceResponseBase::setHTTPHeaderField):
173         (WebCore::ResourceResponseBase::httpHeaderFields):
174         (WebCore::ResourceResponseBase::isAttachment):
175         (WebCore::ResourceResponseBase::setLastModifiedDate):
176         (WebCore::ResourceResponseBase::lastModifiedDate):
177         (WebCore::ResourceResponseBase::wasCached):
178         (WebCore::ResourceResponseBase::connectionReused):
179         (WebCore::ResourceResponseBase::setConnectionReused):
180         (WebCore::ResourceResponseBase::connectionID):
181         (WebCore::ResourceResponseBase::setConnectionID):
182         (WebCore::ResourceResponseBase::resourceLoadTiming):
183         (WebCore::ResourceResponseBase::setResourceLoadTiming):
184         (WebCore::ResourceResponseBase::resourceLoadInfo):
185         (WebCore::ResourceResponseBase::setResourceLoadInfo):
186         * platform/network/ResourceResponseBase.h:
187         * platform/network/cf/ResourceResponse.h:
188         (WebCore::ResourceResponse::ResourceResponse):
189         * platform/network/cf/ResourceResponseCFNet.cpp:
190         (WebCore::ResourceResponse::platformLazyInit):
191         * platform/network/mac/ResourceResponseMac.mm:
192         (WebCore::ResourceResponse::platformLazyInit):
193
194 2011-05-24  Michael Saboff  <msaboff@apple.com>
195
196         Reviewed by Geoffrey Garen.
197
198         Improve handling in WebCore of low memory situations
199         https://bugs.webkit.org/show_bug.cgi?id=61222
200
201         Added new class, MemoryPressureHandler, to platform to respond to low
202         system memory events. Added Mac specific implementation that reduces the
203         page cache, NSURL cache, WebCore cache by half their current usage
204         and then garbage collects.  This can allow Safari to continue operating
205         in a low memory situation with minimal paging.
206         Split up prune operations in MemoryCache to allow for pruning to a
207         specific actual size to support this change.
208
209         No tests added as the functionality of WebKit wasn't changed.
210
211         * GNUmakefile.list.am:
212         * WebCore.exp.in:
213         * WebCore.gypi:
214         * WebCore.pro:
215         * WebCore.vcproj/WebCore.vcproj:
216         * WebCore.xcodeproj/project.pbxproj:
217         * loader/cache/MemoryCache.cpp:
218         (WebCore::MemoryCache::pruneLiveResources):
219         (WebCore::MemoryCache::forcePruneLiveResources):
220         (WebCore::MemoryCache::pruneLiveResourcesToTarget):
221         (WebCore::MemoryCache::pruneDeadResources):
222         (WebCore::MemoryCache::forcePruneDeadResources):
223         (WebCore::MemoryCache::pruneDeadResourcesToTarget):
224         * loader/cache/MemoryCache.h:
225         (WebCore::MemoryCache::forcePrune):
226         * platform/MemoryPressureHandler.cpp: Added.
227         (WebCore::memoryPressureHandler):
228         (WebCore::MemoryPressureHandler::MemoryPressureHandler):
229         (WebCore::MemoryPressureHandler::install):
230         (WebCore::MemoryPressureHandler::respondToMemoryPressure):
231         * platform/MemoryPressureHandler.h: Added.
232         * platform/mac/MemoryPressureHandler.mm: Added.
233         (WebCore::MemoryPressureHandler::install):
234         (WebCore::MemoryPressureHandler::respondToMemoryPressure):
235
236 2011-05-24  Kent Tamura  <tkent@chromium.org>
237
238         Reviewed by Dimitri Glazkov.
239
240         Node::shadowAncestorNode() and shadowTreeRootNode() should be const.
241         https://bugs.webkit.org/show_bug.cgi?id=61398
242
243         shadowAncestorNode() and shadowTreeRootNode() should be const
244         though they can return 'this' pointer.
245
246         No new tests. This doesn't change any visible behavior.
247
248         * dom/Node.cpp:
249         (WebCore::Node::shadowAncestorNode): Make this const.
250         (WebCore::Node::shadowTreeRootNode): ditto.
251         * dom/Node.h: Update declarations.
252         * html/shadow/TextControlInnerElements.h:
253         (WebCore::SpinButtonElement::isEnabledFormControl): Need no const_cast<>.
254         (WebCore::SpinButtonElement::isReadOnlyFormControl): ditto.
255
256 2011-05-24  James Simonsen  <simonjam@chromium.org>
257
258         Reviewed by Eric Seidel.
259
260         ASSERT_NOT_REACHED reached with broken ideograph and system fallback
261         https://bugs.webkit.org/show_bug.cgi?id=53528
262
263         Test: fast/text/justify-ideograph-vertical.html (on chromium linux)
264
265         * platform/graphics/FontFastPath.cpp:
266         (WebCore::Font::glyphDataForCharacter): Identify and handle broken ideographs as any other variant.
267         * platform/graphics/SimpleFontData.h:
268         (WebCore::SimpleFontData::variantFontData): Added BrokenIdeographVariant.
269
270 2011-05-24  Syed Idris Shah  <syed.idris-shah@nokia.com>
271
272         Reviewed by Andreas Kling.
273
274         [Qt] fast/canvas/webgl/gl-uniform-arrays.html failing for Qt on Linux
275         https://bugs.webkit.org/show_bug.cgi?id=60377 
276
277         LayoutTests/fast/canvas/webgl/gl-uniform-arrays.html
278
279         We do not need assert for the useProgram as program can be null.
280
281         * platform/graphics/qt/GraphicsContext3DQt.cpp:
282         (WebCore::GraphicsContext3D::useProgram): Program can be null. Removing assert.
283
284 2011-05-24  Ryosuke Niwa  <rniwa@webkit.org>
285
286         Reviewed by Darin Adler.
287
288         Undo gets broken in contenteditable area when a text field's value is set by script
289         https://bugs.webkit.org/show_bug.cgi?id=61340
290
291         The bug was caused by RenderTextControl::setInnerTextValue's clearing undo stack by
292         calling clearUndoRedoOperations whenever script sets new value to input or textarea.
293
294         Fixed the bug by removing the offending call to clearUndoRedoOperations. While this call
295         was added by r15565 to fix a crash, SimpleEditCommands have since become much more robust
296         and the test added by r15565 (fast/forms/text-field-setvalue-crash.html) still passes.
297
298         Test: editing/undo/undo-after-setting-value.html
299
300         * rendering/RenderTextControl.cpp:
301         (WebCore::RenderTextControl::setInnerTextValue):
302
303 2011-05-24  Dan Bernstein  <mitz@apple.com>
304
305         Reviewed by Dave Hyatt.
306
307         Move code to discover if a CTFont has vertical glyphs out of SimpleFontData::platformInit()
308         https://bugs.webkit.org/show_bug.cgi?id=61392
309
310         * platform/graphics/mac/SimpleFontDataMac.mm:
311         (WebCore::fontHasVerticalGlyphs): Moved code here...
312         (WebCore::SimpleFontData::platformInit): ...from here.
313
314 2011-05-24  Kenneth Russell  <kbr@google.com>
315
316         Reviewed by James Robinson.
317
318         Implement Float64Array
319         https://bugs.webkit.org/show_bug.cgi?id=39144
320
321         Implemented Float64Array based on the existing Float32Array sources.
322         Built and tested in Chromium on Linux and Mac OS X and Safari on Mac OS X.
323
324         * CMakeLists.txt:
325         * CodeGenerators.pri:
326         * DerivedSources.cpp:
327         * DerivedSources.make:
328         * GNUmakefile.list.am:
329         * UseJSC.cmake:
330         * WebCore.gypi:
331         * WebCore.pro:
332         * WebCore.vcproj/WebCore.vcproj:
333         * WebCore.xcodeproj/project.pbxproj:
334         * bindings/js/JSBindingsAllInOne.cpp:
335         * bindings/js/JSDOMWindowCustom.cpp:
336         (WebCore::JSDOMWindow::float64Array):
337         * bindings/js/JSFloat64ArrayCustom.cpp: Added.
338         (WebCore::JSFloat64Array::indexSetter):
339         (WebCore::toJS):
340         (WebCore::JSFloat64Array::set):
341         (WebCore::JSFloat64ArrayConstructor::constructJSFloat64Array):
342         * bindings/v8/custom/V8Float64ArrayCustom.cpp: Added.
343         (WebCore::V8Float64Array::constructorCallback):
344         (WebCore::V8Float64Array::setCallback):
345         (WebCore::toV8):
346         * html/canvas/ArrayBufferView.h:
347         (WebCore::ArrayBufferView::isDoubleArray):
348         * html/canvas/Float64Array.cpp: Added.
349         (WebCore::Float64Array::create):
350         (WebCore::Float64Array::Float64Array):
351         (WebCore::Float64Array::subarray):
352         * html/canvas/Float64Array.h: Added.
353         (WebCore::Float64Array::set):
354         (WebCore::Float64Array::item):
355         (WebCore::Float64Array::isDoubleArray):
356         * html/canvas/Float64Array.idl: Added.
357         * page/DOMWindow.idl:
358         * workers/WorkerContext.idl:
359
360 2011-05-24  Simon Fraser  <simon.fraser@apple.com>
361
362         Reviewed by Chris Marrin.
363
364         Add ability to set compositing layer bounds origin
365         https://bugs.webkit.org/show_bug.cgi?id=61381
366
367         On Core Animation layers, the origin of the bounds
368         rectangle affects where layer content is rendered, as well
369         as the offset of sublayers. Currently we always set the
370         bounds offset to a zero point, but may need to make use
371         of the bounds offset in future, so expose it via GraphicsLayer.
372
373         * platform/graphics/GraphicsLayer.h:
374         (WebCore::GraphicsLayer::boundsOrigin):
375         (WebCore::GraphicsLayer::setBoundsOrigin):
376         * platform/graphics/ca/GraphicsLayerCA.cpp:
377         (WebCore::GraphicsLayerCA::setSize):
378         (WebCore::GraphicsLayerCA::setBoundsOrigin):
379         (WebCore::GraphicsLayerCA::setAllowTiledLayer):
380         (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
381         (WebCore::GraphicsLayerCA::updateBounds):
382         (WebCore::GraphicsLayerCA::ensureStructuralLayer):
383         (WebCore::GraphicsLayerCA::swapFromOrToTiledLayer):
384         * platform/graphics/ca/GraphicsLayerCA.h:
385
386 2011-05-24  Leandro Pereira  <leandro@profusion.mobi>
387
388         [EFL] Build fix.
389
390         * CMakeLists.txt: Also build platform/network/ContentTypeParser.cpp,
391         added by r86289.
392
393 2011-05-24  Leandro Pereira  <leandro@profusion.mobi>
394
395         [EFL] Build fix.
396
397         * bridge/runtime_root.cpp: Include <heap/Weak.h> instead of
398         <JavaScriptCore/Weak.h>.
399
400 2011-05-24  Jay Civelli  <jcivelli@chromium.org>
401
402         Reviewed by Adam Barth.
403
404         Adding MHTML reading support. That required some basic MIME header parsing.
405         Modified DocumentLoader to keep a reference to the currently Archive loaded,
406         so we can have different policies for loading subresources depending on the
407         archive type.
408         https://bugs.webkit.org/show_bug.cgi?id=7168
409
410         * CMakeLists.txt:
411         * Configurations/FeatureDefines.xcconfig:
412         * GNUmakefile.am:
413         * GNUmakefile.list.am:
414         * WebCore.gyp/WebCore.gyp:
415         * WebCore.gypi:
416         * WebCore.pro:
417         * WebCore.vcproj/WebCore.vcproj:
418         * WebCore.xcodeproj/project.pbxproj:
419         * features.pri:
420         * loader/DocumentLoader.cpp:
421         (WebCore::DocumentLoader::commitLoad):
422         (WebCore::DocumentLoader::setupForReplaceByMIMEType):
423         (WebCore::DocumentLoader::popArchiveForSubframe):
424         (WebCore::DocumentLoader::scheduleArchiveLoad):
425         * loader/DocumentLoader.h:
426         * loader/FrameLoader.cpp:
427         (WebCore::FrameLoader::loadURLIntoChildFrame):
428         (WebCore::FrameLoader::loadArchive):
429         (WebCore::FrameLoader::stopAllLoaders):
430         (WebCore::FrameLoader::finishedLoadingDocument):
431         * loader/FrameLoader.h:
432         (WebCore::FrameLoader::archive):
433         * loader/MainResourceLoader.cpp:
434         (WebCore::MainResourceLoader::continueAfterContentPolicy):
435         * loader/ResourceLoader.cpp:
436         (WebCore::ResourceLoader::start):
437         * loader/archive/Archive.cpp: Added.
438         * loader/archive/Archive.h:
439         (WebCore::Archive::mainResource):
440         * loader/archive/ArchiveFactory.cpp:
441         (WebCore::archiveFactoryCreate):
442         (WebCore::archiveMIMETypes):
443         (WebCore::ArchiveFactory::create):
444         (WebCore::ArchiveFactory::registerKnownArchiveMIMETypes):
445         * loader/archive/ArchiveFactory.h:
446         * loader/archive/ArchiveResourceCollection.cpp:
447         (WebCore::ArchiveResourceCollection::addAllResources):
448         (WebCore::ArchiveResourceCollection::popSubframeArchive):
449         * loader/archive/ArchiveResourceCollection.h:
450         * loader/archive/cf/LegacyWebArchive.cpp:
451         (WebCore::LegacyWebArchive::create):
452         (WebCore::LegacyWebArchive::type):
453         * loader/archive/cf/LegacyWebArchive.h:
454         * loader/archive/mhtml/MHTMLArchive.cpp: Added.
455         * loader/archive/mhtml/MHTMLArchive.h: Added.
456         * loader/archive/mhtml/MHTMLParser.cpp: Added.
457         * loader/archive/mhtml/MHTMLParser.h: Added.
458         * platform/MIMETypeRegistry.cpp:
459         (WebCore::initializeSupportedNonImageMimeTypes):
460         * platform/mac/PasteboardMac.mm:
461         (WebCore::Pasteboard::documentFragment):
462         * platform/network/MIMEHeader.cpp: Added.
463         * platform/network/MIMEHeader.h: Added.
464
465 2011-05-24  Geoffrey Garen  <ggaren@apple.com>
466
467         Try to fix some builds: #include Weak.h for Weak<T>.
468
469         * bridge/runtime_root.h:
470
471 2011-05-24  Sam Weinig  <sam@webkit.org>
472
473         Reviewed by Beth Dakin.
474
475         Can't scroll scaled page that has overflow:hidden on its root
476         <rdar://problem/9029189>
477         https://bugs.webkit.org/show_bug.cgi?id=61339
478
479         Test: fast/events/scroll-in-scaled-page-with-overflow-hidden.html
480
481         * page/FrameView.cpp:
482         (WebCore::FrameView::applyOverflowToViewport):
483         Scrollbars should be enabled for the viewport when scaled, even if overflow:hidden
484         is specified.
485
486 2011-05-24  Adam Roben  <aroben@apple.com>
487
488         Leopard build fix
489
490         * bridge/runtime_root.cpp: Added a missing #include.
491
492 2011-05-24  Jian Li  <jianli@chromium.org>
493
494         Reviewed by Kenneth Russell.
495
496         Make start parameter of Blob.slice optional.
497         https://bugs.webkit.org/show_bug.cgi?id=59628
498
499         The start parameter should be optional per the latest FILE API
500         spec: http://dev.w3.org/2006/webapi/FileAPI/#dfn-Blob.
501
502         * fileapi/Blob.h:
503         * fileapi/Blob.idl: Make start parameter optional.
504
505 2011-05-24  Adam Roben  <aroben@apple.com>
506
507         Invalidate RuntimeObjects when they are finalized
508
509         This will cause the underlying NPObject to be released at finalization time, rather than at
510         destruction time (which is unpredictable and could occur after the plugin has been
511         unloaded).
512
513         Test: plugins/npobject-js-wrapper-destroyed-after-plugin-unload.html
514
515         Fixes <http://webkit.org/b/61317> <rdar://problem/9489829> Crash in _NPN_DeallocateObject
516         when reloading yahoo.com webarchive in WebKit1
517
518         Reviewed by Oliver Hunt.
519
520         * bridge/runtime_object.cpp:
521         (JSC::Bindings::RuntimeObject::~RuntimeObject): Assert that we've already been invalidated.
522
523         * bridge/runtime_root.cpp:
524         (JSC::Bindings::RootObject::invalidate):
525         (JSC::Bindings::RootObject::addRuntimeObject):
526         Updated for m_runtimeObjects type change.
527
528         (JSC::Bindings::RootObject::finalize): Added. Invalidates the RuntimeObject and removes it
529         from the map.
530
531         * bridge/runtime_root.h: Now inherits from WeakHandleOwner.
532         Changed m_runtimeObjects from a WeakGCMap to a HashMap of JSC::Weak objects so that we will
533         be notified when the RuntimeObjects are finalized.
534
535 2011-05-24  Mike Reed  <reed@google.com>
536
537         Reviewed by Kenneth Russell.
538
539         skia: fix stroking of zero-height rectangles
540         https://bugs.webkit.org/show_bug.cgi?id=61284
541
542         Tests: canvas/philip/tests/2d.line.miter.lineedge.html
543                canvas/philip/tests/2d.strokeRect.zero.4.html
544
545         * platform/graphics/skia/GraphicsContextSkia.cpp:
546         (WebCore::GraphicsContext::strokeRect):
547
548 2011-05-24  Zan Dobersek  <zandobersek@gmail.com> and Philippe Normand  <pnormand@igalia.com>
549
550         Reviewed by Kenneth Russell.
551
552         Enable FloatArray usage outside WebGL guards
553         https://bugs.webkit.org/show_bug.cgi?id=61356
554
555         * webaudio/AudioBuffer.cpp:
556         * webaudio/AudioBuffer.idl:
557         * webaudio/RealtimeAnalyser.cpp:
558         * webaudio/RealtimeAnalyser.h:
559         * webaudio/RealtimeAnalyserNode.h:
560         * webaudio/RealtimeAnalyserNode.idl:
561
562 2011-05-24  Adam Klein  <adamk@chromium.org>
563
564         Unreviewed, rolling out r87145.
565         http://trac.webkit.org/changeset/87145
566         https://bugs.webkit.org/show_bug.cgi?id=61194
567
568         Regression in LayoutTests/inspector/debugger/scripts-panel.html on Chromium Win & Linux.
569
570         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
571         (WebCore::V8InjectedScriptHost::evaluateCallback):
572
573 2011-05-24  Matthew Delaney  <mdelaney@apple.com>
574
575         Reviewed by Simon Fraser.
576
577         Clamp coordinates to integers for canvas create/getImageData routines
578         https://bugs.webkit.org/show_bug.cgi?id=61135
579
580         Test: fast/canvas/canvas-getImageData-largeNonintegralDimensions.html
581
582         * html/HTMLCanvasElement.cpp:
583         (WebCore::HTMLCanvasElement::convertLogicalToDevice): clamp to ints
584         * html/canvas/CanvasRenderingContext2D.cpp:
585         (WebCore::CanvasRenderingContext2D::createImageData):
586         (WebCore::CanvasRenderingContext2D::getImageData):
587         * platform/graphics/cg/ImageBufferDataCG.cpp:
588         (WebCore::ImageBufferData::getData):
589
590 2011-05-24  Robin Dunn  <robin@alldunn.com>
591
592         Reviewed by Kevin Ollivier.
593
594         [wx] Make sure x and y adjustments are applied to all operations, and fix the calculations
595         for the height and width checks to take into account x and y offsets.
596         
597         https://bugs.webkit.org/show_bug.cgi?id=61367
598
599         * platform/graphics/wx/ImageWx.cpp:
600         (WebCore::Image::drawPattern):
601
602 2011-05-24  Tony Chang  <tony@chromium.org>
603
604         Reviewed by James Robinson.
605
606         fix render overflow computation for input type=range
607         https://bugs.webkit.org/show_bug.cgi?id=61132
608
609         Test: fast/forms/slider-hit-testing.html
610
611         We need to clear m_overflow otherwise we use the first
612         size of the slider for hit testing (i.e., changes to the size
613         cause problems).  This only shows up if the thumb isn't contained
614         in the bounds of the slider.  Making the range have a smaller height
615         than the thumb shows the bug.
616
617         * rendering/RenderSlider.cpp:
618         (WebCore::RenderSlider::layout): Clear the overflow during layout
619             so we re-compute the overflow based on the current size of the
620             slider.
621
622 2011-05-24  Alok Priyadarshi  <alokp@chromium.org>
623
624         Reviewed by James Robinson.
625
626         Enable skia gpu rendering for content layers
627         https://bugs.webkit.org/show_bug.cgi?id=56749
628
629         This patch adds gpu accelerated rendering for content and root layers.
630         Layer textures are updated in two stages:
631         1. Paint: The non-accelerated path paints the layer contents into a bitmap.
632                   The accelerated path paints into an SkPicture, which is essentially a display list.
633         2. Upload: The non-accelerated path uploads the pixels obtained in the first stage to a texture.
634                    The accelerated path renders the picture directly into the texture.
635
636         The accelerated path can be enabled by --enable-accelerated-drawing command-line flag in chromium.
637         Note that this patch does not accelerate the CG path on mac. We have two options here - use skia or accelrate CG path.
638         Any bugs should be caught by layout tests.
639
640         * platform/graphics/chromium/ContentLayerChromium.cpp:
641         (WebCore::ContentLayerChromium::createTextureUpdater):
642         * platform/graphics/chromium/LayerRendererChromium.cpp:
643         (WebCore::LayerRendererChromium::create):
644         (WebCore::LayerRendererChromium::LayerRendererChromium):
645         (WebCore::LayerRendererChromium::skiaContext):
646         (WebCore::LayerRendererChromium::updateAndDrawLayers):
647         (WebCore::LayerRendererChromium::createRootLayerTextureUpdater):
648         * platform/graphics/chromium/LayerRendererChromium.h:
649         (WebCore::LayerRendererChromium::acceleratedDrawing):
650         * platform/graphics/chromium/LayerTextureUpdaterCanvas.cpp:
651         (WebCore::LayerTextureUpdaterSkPicture::LayerTextureUpdaterSkPicture):
652         (WebCore::LayerTextureUpdaterSkPicture::~LayerTextureUpdaterSkPicture):
653         (WebCore::LayerTextureUpdaterSkPicture::prepareToUpdate):
654         (WebCore::LayerTextureUpdaterSkPicture::updateTextureRect):
655         (WebCore::LayerTextureUpdaterSkPicture::deleteFrameBuffer):
656         (WebCore::LayerTextureUpdaterSkPicture::createFrameBuffer):
657         (WebCore::LayerTextureUpdaterSkPicture::clearFrameBuffer):
658         * platform/graphics/chromium/LayerTextureUpdaterCanvas.h:
659         (WebCore::LayerTextureUpdaterSkPicture::orientation):
660         * platform/graphics/chromium/LayerTilerChromium.cpp:
661         (WebCore::LayerTilerChromium::updateRect):
662         (WebCore::LayerTilerChromium::draw):
663
664 2011-05-24  Pavel Podivilov  <podivilov@chromium.org>
665
666         Reviewed by Yury Semikhatsky.
667
668         Web Inspector: display keyboard shortcuts in scripts panel sidebar buttons tooltip text.
669         https://bugs.webkit.org/show_bug.cgi?id=61358
670
671         * English.lproj/localizedStrings.js:
672         * inspector/front-end/CallStackSidebarPane.js:
673         (WebInspector.CallStackSidebarPane.prototype._selectedPlacardByIndex):
674         (WebInspector.CallStackSidebarPane.prototype.registerShortcuts):
675         * inspector/front-end/Panel.js:
676         (WebInspector.Panel.prototype.registerShortcut):
677         * inspector/front-end/ScriptsPanel.js:
678         (WebInspector.ScriptsPanel):
679         (WebInspector.ScriptsPanel.prototype._createSidebarButtons):
680         (WebInspector.ScriptsPanel.prototype._createSidebarButtonAndRegisterShortcuts):
681
682 2011-05-24  Philippe Normand  <pnormand@igalia.com>
683
684         Reviewed by Andres Kling.
685
686         JSAudioContextCustom doesn't encode errors
687         https://bugs.webkit.org/show_bug.cgi?id=61357
688
689         Fix AudioContext return values
690
691         * bindings/js/JSAudioContextCustom.cpp:
692         (WebCore::JSAudioContextConstructor::constructJSAudioContext):
693
694 2011-05-24  Rob Buis  <rbuis@rim.com>
695
696         Rubber-stamped by Dirk Schulze.
697
698         Remove requiresLayer inlines, already provided by RenderSVGModelObject.
699
700         * rendering/svg/RenderSVGHiddenContainer.h:
701         (WebCore::RenderSVGHiddenContainer::isSVGHiddenContainer):
702         * rendering/svg/RenderSVGImage.h:
703
704 2011-05-24  Nikolas Zimmermann  <nzimmermann@rim.com>
705
706         Not reviewed, build fix.
707
708         Remove platform layering violation: TextRun stores RenderObjects for SVG Fonts support
709         https://bugs.webkit.org/show_bug.cgi?id=60254
710
711         Forgot to rename the destructor.
712
713         * platform/graphics/SimpleFontData.h:
714         (WebCore::SimpleFontData::AdditionalFontData::~AdditionalFontData):
715
716 2011-05-24  Nikolas Zimmermann  <nzimmermann@rim.com>
717
718         Not reviewed, build fix.
719
720         Remove platform layering violation: TextRun stores RenderObjects for SVG Fonts support
721         https://bugs.webkit.org/show_bug.cgi?id=60254
722
723         Rename SimpleFontData::FontData subclass to AdditionalFontData, to avoid clashes with the WebCore::FontData class, which breaks the win build.
724
725         * platform/graphics/SimpleFontData.cpp:
726         (WebCore::SimpleFontData::SimpleFontData):
727         * platform/graphics/SimpleFontData.h:
728         (WebCore::SimpleFontData::fontData):
729         * svg/SVGFontData.h:
730
731 2011-05-24  Nikolas Zimmermann  <nzimmermann@rim.com>
732
733         Reviewed by Antti Koivisto.
734
735         Remove platform layering violation: TextRun stores RenderObjects for SVG Fonts support
736         https://bugs.webkit.org/show_bug.cgi?id=60254
737
738         First part:
739         Remove a long-standing layering violation in TextRun: it stores RenderObject/RenderSVGResource pointers for SVG Fonts support.
740         Replace the two Render* pointers with a single RefPtr<AbstractRenderingContext>. AbstractRenderingContext is a helper class,
741         that can be derived from in order to associate additional data with a TextRun. This effectively reduces the memory consumption of TextRun.
742
743         Introduce rendering/TextRunRenderingContext.h, which inherits from TextRun::AbstractRenderingContext and holds additional data.
744         If the primary font in use is a SVG Font then allocate a TextRunRenderingContext object and store it in the RefPtr<AbstractRenderingContext>
745         in TextRun. If the primary font is not a SVG Font, don't even allocate the TextRunRenderingContext structure, as we won't need the context data.
746         SVG Fonts glyph matching only works within a context, so we need access to the RenderObject that's drawing the text.
747
748         This is the main preparation patch for the SVG Fonts rewrite, that will allow us to share the simple text code path for SVG Fonts as well,
749         making all CSS text properties work for HTML text using SVG Fonts, and allows proper integration within the GlyphPage concept. Soon
750         we can intermix WOFF/SVG & native fonts, within segment font declarations.
751
752         Second part:
753         Remove a long-standing layering violation in SimpleFontData: it stores SVGFontData objects, that are living in svg/.
754         Use the same concept as above, introduce SimpleFontData::AbstractFontData, and let SVGFontData inherit from AbstractFontData and extent it.
755         If SVG Fonts are used, CSSFontFaceSource will create a SVGFontData object and pass it as PassOwnPtr<AbstractFontData> to SimpleFontData.
756
757         All layering violations are gone now, SVG Fonts are cleanly integrated now.
758         Doesn't affect any tests yet, refactoring only.
759
760         * CMakeLists.txt:
761         * GNUmakefile.list.am:
762         * WebCore.gypi:
763         * WebCore.pro:
764         * WebCore.vcproj/WebCore.vcproj:
765         * WebCore.xcodeproj/project.pbxproj:
766         * css/CSSFontFaceSource.cpp:
767         (WebCore::CSSFontFaceSource::getFontData):
768         * platform/graphics/Font.cpp:
769         (WebCore::Font::drawText):
770         (WebCore::Font::width):
771         (WebCore::Font::selectionRectForText):
772         (WebCore::Font::offsetForPosition):
773         * platform/graphics/Font.h:
774         * platform/graphics/SimpleFontData.cpp:
775         (WebCore::SimpleFontData::SimpleFontData):
776         (WebCore::SimpleFontData::~SimpleFontData):
777         * platform/graphics/SimpleFontData.h:
778         (WebCore::SimpleFontData::FontData::~FontData):
779         (WebCore::SimpleFontData::fontMetrics):
780         (WebCore::SimpleFontData::setMaxCharWidth):
781         (WebCore::SimpleFontData::setAvgCharWidth):
782         (WebCore::SimpleFontData::setSpaceWidth):
783         (WebCore::SimpleFontData::setSpaceGlyph):
784         (WebCore::SimpleFontData::setZeroWidthSpaceGlyph):
785         (WebCore::SimpleFontData::fontData):
786         (WebCore::SimpleFontData::isSVGFont):
787         (WebCore::SimpleFontData::setMissingGlyphData):
788         * platform/graphics/TextRun.h:
789         (WebCore::TextRun::TextRun):
790         (WebCore::TextRun::setAllowTabs):
791         (WebCore::TextRun::setXPos):
792         (WebCore::TextRun::RenderingContext::~RenderingContext):
793         (WebCore::TextRun::renderingContext):
794         (WebCore::TextRun::setRenderingContext):
795         * rendering/EllipsisBox.cpp:
796         (WebCore::EllipsisBox::paint):
797         (WebCore::EllipsisBox::selectionRect):
798         (WebCore::EllipsisBox::paintSelection):
799         * rendering/InlineTextBox.cpp:
800         (WebCore::InlineTextBox::selectionRect):
801         (WebCore::InlineTextBox::paint):
802         (WebCore::InlineTextBox::paintSelection):
803         (WebCore::InlineTextBox::paintCompositionBackground):
804         (WebCore::InlineTextBox::paintSpellingOrGrammarMarker):
805         (WebCore::InlineTextBox::paintTextMatchMarker):
806         (WebCore::InlineTextBox::computeRectForReplacementMarker):
807         (WebCore::InlineTextBox::offsetForPosition):
808         (WebCore::InlineTextBox::positionForOffset):
809         (WebCore::InlineTextBox::constructTextRun):
810         * rendering/InlineTextBox.h:
811         * rendering/RenderBlock.cpp:
812         (WebCore::stripTrailingSpace):
813         (WebCore::RenderBlock::constructTextRun):
814         * rendering/RenderBlock.h:
815         * rendering/RenderBlockLineLayout.cpp:
816         (WebCore::setLogicalWidthForTextRun):
817         (WebCore::textWidth):
818         (WebCore::tryHyphenating):
819         (WebCore::RenderBlock::LineBreaker::nextLineBreak):
820         (WebCore::RenderBlock::checkLinesForTextOverflow):
821         * rendering/RenderCombineText.cpp:
822         (WebCore::RenderCombineText::combineText):
823         * rendering/RenderFileUploadControl.cpp:
824         (WebCore::RenderFileUploadControl::paintObject):
825         (WebCore::RenderFileUploadControl::computePreferredLogicalWidths):
826         * rendering/RenderFlexibleBox.cpp:
827         (WebCore::RenderFlexibleBox::applyLineClamp):
828         * rendering/RenderImage.cpp:
829         (WebCore::RenderImage::setImageSizeForAltText):
830         (WebCore::RenderImage::paintReplaced):
831         * rendering/RenderListBox.cpp:
832         (WebCore::RenderListBox::updateFromElement):
833         * rendering/RenderListMarker.cpp:
834         (WebCore::RenderListMarker::paint):
835         (WebCore::RenderListMarker::computePreferredLogicalWidths):
836         (WebCore::RenderListMarker::getRelativeMarkerRect):
837         * rendering/RenderText.cpp:
838         (WebCore::RenderText::widthFromCache):
839         (WebCore::RenderText::trimmedPrefWidths):
840         (WebCore::RenderText::computePreferredLogicalWidths):
841         (WebCore::RenderText::width):
842         * rendering/RenderTextControl.cpp:
843         (WebCore::RenderTextControl::getAvgCharWidth):
844         * rendering/svg/RenderSVGAllInOne.cpp:
845         * rendering/svg/SVGInlineTextBox.cpp:
846         (WebCore::SVGInlineTextBox::offsetForPositionInFragment):
847         (WebCore::SVGInlineTextBox::prepareGraphicsContextForTextPainting):
848         (WebCore::SVGInlineTextBox::restoreGraphicsContextAfterTextPainting):
849         (WebCore::SVGInlineTextBox::constructTextRun):
850         (WebCore::SVGInlineTextBox::paintText):
851         * rendering/svg/SVGTextLayoutEngineSpacing.cpp:
852         (WebCore::SVGTextLayoutEngineSpacing::calculateSVGKerning):
853         * rendering/svg/SVGTextMetrics.cpp:
854         (WebCore::constructTextRun):
855         (WebCore::SVGTextMetrics::measureCharacterRange):
856         * rendering/svg/SVGTextRunRenderingContext.cpp: Copied from svg/SVGFont.cpp.
857         (WebCore::svgFontAndFontFaceElementForFontData):
858         (WebCore::firstParentRendererForNonTextNode):
859         (WebCore::referencingRenderObjectFromRun):
860         (WebCore::activePaintingResourceFromRun):
861         (WebCore::SVGTextRunWalker::walk):
862         (WebCore::floatWidthMissingGlyphCallback):
863         (WebCore::floatWidthOfSubStringUsingSVGFont):
864         (WebCore::SVGTextRunRenderingContext::floatWidthUsingSVGFont):
865         (WebCore::SVGTextRunRenderingContext::drawTextUsingSVGFont):
866         (WebCore::SVGTextRunRenderingContext::selectionRectForTextUsingSVGFont):
867         (WebCore::SVGTextRunRenderingContext::offsetForPositionForTextUsingSVGFont):
868         * rendering/svg/SVGTextRunRenderingContext.h: Added.
869         (WebCore::SVGTextRunRenderingContext::create):
870         (WebCore::SVGTextRunRenderingContext::context):
871         (WebCore::SVGTextRunRenderingContext::activePaintingResource):
872         (WebCore::SVGTextRunRenderingContext::setActivePaintingResource):
873         (WebCore::SVGTextRunRenderingContext::SVGTextRunRenderingContext):
874         (WebCore::textRunNeedsRenderingContext):
875         * svg/SVGAllInOne.cpp:
876         * svg/SVGFont.cpp: Removed.
877         * svg/SVGFontData.cpp:
878         (WebCore::SVGFontData::initializeFontData):
879         * svg/SVGFontData.h:
880         (WebCore::SVGFontData::create):
881         (WebCore::SVGFontData::isSVGFontData):
882         * svg/SVGGlyphElement.cpp:
883         (WebCore::SVGGlyphElement::SVGGlyphElement):
884         (WebCore::SVGGlyphElement::buildGenericGlyphIdentifier):
885         (WebCore::SVGGlyphElement::buildGlyphIdentifier):
886         * svg/SVGHKernElement.cpp:
887         (WebCore::SVGHKernElement::SVGHKernElement):
888         (WebCore::SVGHKernElement::buildHorizontalKerningPair):
889         * svg/SVGVKernElement.cpp:
890         (WebCore::SVGVKernElement::SVGVKernElement):
891         (WebCore::SVGVKernElement::buildVerticalKerningPair):
892         * svg/SVGVKernElement.h:
893
894 2011-05-24  Ryuan Choi  <ryuan.choi@samsung.com>
895
896         Reviewed by Andreas Kling.
897
898         [GTK] Implement GraphicsContextCairo::imageInterpolationQuality().
899         https://bugs.webkit.org/show_bug.cgi?id=60827
900
901         Implement getter/setter of imageInterpolationQuality and logic to change
902         interpolation algorithm when drawing image.
903         Mac and Qt already implemented it.
904
905         * platform/graphics/cairo/GraphicsContextCairo.cpp:
906         (WebCore::GraphicsContext::setImageInterpolationQuality):
907         (WebCore::GraphicsContext::imageInterpolationQuality):
908         * platform/graphics/cairo/GraphicsContextPlatformPrivateCairo.h:
909         * platform/graphics/cairo/PlatformContextCairo.cpp:
910         (WebCore::PlatformContextCairo::drawSurfaceToContext):
911         * platform/graphics/cairo/PlatformContextCairo.h:
912         (WebCore::PlatformContextCairo::setImageInterpolationQuality): Added.
913         (WebCore::PlatformContextCairo::imageInterpolationQuality): Added.
914
915 2011-05-24  Leandro Gracia Gil  <leandrogracia@chromium.org>
916
917         Reviewed by Tony Gentilcore.
918
919         Media Stream API: adding Stream and GeneratedStream classes.
920         https://bugs.webkit.org/show_bug.cgi?id=56666
921
922         Add the code for the Stream and GeneratedStream classes and integrate it
923         with the existing stream generation requests.
924
925         Tests for the Media Stream API will be provided by the bug 56587.
926
927         * CMakeLists.txt:
928         * CodeGenerators.pri:
929         * DerivedSources.cpp:
930         * DerivedSources.make:
931         * GNUmakefile.list.am:
932         * WebCore.gypi:
933         * WebCore.pro:
934         * WebCore.vcproj/WebCore.vcproj:
935         * WebCore.xcodeproj/project.pbxproj:
936         * bindings/js/JSEventTarget.cpp:
937         (WebCore::toJS):
938         * bindings/v8/V8DOMWrapper.cpp:
939         (WebCore::V8DOMWrapper::convertEventTargetToV8Object):
940         * dom/DOMAllInOne.cpp:
941         * dom/EventTarget.cpp:
942         (WebCore::EventTarget::toStream):
943         (WebCore::EventTarget::toGeneratedStream):
944         * dom/EventTarget.h:
945         * dom/GeneratedStream.cpp: Added.
946         (WebCore::GeneratedStream::DispatchUpdateTask::create):
947         (WebCore::GeneratedStream::DispatchUpdateTask::performTask):
948         (WebCore::GeneratedStream::DispatchUpdateTask::DispatchUpdateTask):
949         (WebCore::GeneratedStream::create):
950         (WebCore::GeneratedStream::GeneratedStream):
951         (WebCore::GeneratedStream::~GeneratedStream):
952         (WebCore::GeneratedStream::toGeneratedStream):
953         (WebCore::GeneratedStream::detachEmbedder):
954         (WebCore::GeneratedStream::stop):
955         (WebCore::GeneratedStream::onStop):
956         * dom/GeneratedStream.h: Added.
957         * dom/GeneratedStream.idl: Added.
958         * dom/Stream.cpp: Added.
959         (WebCore::Stream::create):
960         (WebCore::Stream::Stream):
961         (WebCore::Stream::~Stream):
962         (WebCore::Stream::toStream):
963         (WebCore::Stream::streamEnded):
964         (WebCore::Stream::scriptExecutionContext):
965         (WebCore::Stream::eventTargetData):
966         (WebCore::Stream::ensureEventTargetData):
967         * dom/Stream.h: Added.
968         (WebCore::Stream::readyState):
969         (WebCore::Stream::label):
970         (WebCore::Stream::refEventTarget):
971         (WebCore::Stream::derefEventTarget):
972         * dom/Stream.idl: Added.
973         * page/CallbackTask.h:
974         (WebCore::CallbackTask1::Scheduler::~Scheduler):
975         * page/MediaStreamClient.h:
976         * page/MediaStreamController.cpp:
977         (WebCore::MediaStreamController::stopGeneratedStream):
978         (WebCore::MediaStreamController::streamFailed):
979         * page/MediaStreamController.h:
980         * page/MediaStreamFrameController.cpp:
981         (WebCore::MediaStreamFrameController::Request::Request):
982         (WebCore::MediaStreamFrameController::GenerateStreamRequest::create):
983         (WebCore::MediaStreamFrameController::GenerateStreamRequest::abort):
984         (WebCore::MediaStreamFrameController::GenerateStreamRequest::GenerateStreamRequest):
985         (WebCore::MediaStreamFrameController::unregister):
986         (WebCore::MediaStreamFrameController::getStreamFromLabel):
987         (WebCore::MediaStreamFrameController::generateStream):
988         (WebCore::MediaStreamFrameController::stopGeneratedStream):
989         (WebCore::MediaStreamFrameController::streamGenerated):
990         (WebCore::MediaStreamFrameController::streamGenerationFailed):
991         (WebCore::MediaStreamFrameController::streamFailed):
992         * page/MediaStreamFrameController.h:
993         (WebCore::MediaStreamFrameController::StreamClient::StreamClient):
994         (WebCore::MediaStreamFrameController::StreamClient::isGeneratedStream):
995         * page/NavigatorUserMediaError.h:
996         (WebCore::NavigatorUserMediaError::create):
997         (WebCore::NavigatorUserMediaError::NavigatorUserMediaError):
998         * page/NavigatorUserMediaSuccessCallback.h:
999         * page/NavigatorUserMediaSuccessCallback.idl:
1000
1001 2011-05-23  Antti Koivisto  <antti@apple.com>
1002
1003         Reviewed by Oliver Hunt.
1004     
1005         REGRESSION (r45620): Node list caches never deleted
1006         https://bugs.webkit.org/show_bug.cgi?id=61268
1007         <rdar://problem/9467379>
1008         
1009         NodeListsNodeData::isEmpty() tests if RefCounted objects have refcount of zero which is impossible.
1010         As a results NodeList caches are never deleted, causing bad performance in DOM mutating operations as
1011         they repeatedly invalidate caches.
1012
1013         * dom/Node.cpp:
1014         (WebCore::Node::childNodes):
1015             Construct m_childNodeListCaches lazily.
1016
1017         (WebCore::Node::unregisterDynamicNodeList):
1018         (WebCore::Node::notifyLocalNodeListsAttributeChanged):
1019         (WebCore::Node::notifyLocalNodeListsChildrenChanged):
1020         (WebCore::Node::removeNodeListCacheIfPossible): 
1021             Add a helper.
1022
1023         (WebCore::NodeListsNodeData::invalidateCaches):
1024             Invalidate m_childNodeListCaches by clearing it if there are no additional clients
1025
1026         (WebCore::NodeListsNodeData::isEmpty):
1027             Test emptiness of various NodeListCaches simply by testing hash emptiness instead of testing for non-zero ref count of items.
1028             m_childNodeListCaches is empty if it is null.
1029
1030         * dom/Node.h: 
1031         * dom/NodeRareData.h:
1032         (WebCore::NodeListsNodeData::NodeListsNodeData):
1033             Construct m_childNodeListCaches lazily.
1034
1035 2011-05-24  Mikhail Naganov  <mnaganov@chromium.org>
1036
1037         Reviewed by Yury Semikhatsky.
1038
1039         Web Inspector: Reorganize InspectorBackendDispatch code to eliminate duplication
1040         https://bugs.webkit.org/show_bug.cgi?id=61300
1041
1042         * inspector/CodeGeneratorInspector.pm:
1043
1044 2011-05-23  Yury Semikhatsky  <yurys@chromium.org>
1045
1046         Reviewed by Adam Barth.
1047
1048         Chromium DevTools: Tab crashes with "Aw, snap!" on entering "(new Image())." in console
1049         https://bugs.webkit.org/show_bug.cgi?id=61194
1050
1051         Test: inspector/console/console-eval-syntax-error.html
1052
1053         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
1054         (WebCore::V8InjectedScriptHost::evaluateCallback): return immediately in case of syntax error
1055
1056 2011-04-13  Steve Block  <steveblock@google.com>
1057
1058         Reviewed by Eric Seidel.
1059
1060         Geolocation callbacks should make use of new callback generation mechanism
1061         https://bugs.webkit.org/show_bug.cgi?id=40065
1062
1063         No new tests, refactoring only.
1064
1065         * Android.derived.jscbindings.mk:
1066         * Android.derived.v8bindings.mk:
1067         * Android.jscbindings.mk:
1068         * Android.v8bindings.mk:
1069         * CMakeLists.txt:
1070         * CodeGenerators.pri:
1071         * DerivedSources.cpp:
1072         * DerivedSources.make:
1073         * GNUmakefile.list.am:
1074         * UseJSC.cmake:
1075         * WebCore.gypi:
1076         * WebCore.order:
1077         * WebCore.pro:
1078         * WebCore.vcproj/WebCore.vcproj:
1079         * WebCore.xcodeproj/project.pbxproj:
1080         * bindings/js/JSBindingsAllInOne.cpp:
1081         * bindings/js/JSCustomPositionCallback.cpp: Removed.
1082         * bindings/js/JSCustomPositionCallback.h: Removed.
1083         * bindings/js/JSCustomPositionErrorCallback.cpp: Removed.
1084         * bindings/js/JSCustomPositionErrorCallback.h: Removed.
1085         * bindings/js/JSGeolocationCustom.cpp:
1086         (WebCore::JSGeolocation::getCurrentPosition):
1087         (WebCore::JSGeolocation::watchPosition):
1088         * bindings/v8/custom/V8CustomPositionCallback.cpp: Removed.
1089         * bindings/v8/custom/V8CustomPositionCallback.h: Removed.
1090         * bindings/v8/custom/V8CustomPositionErrorCallback.cpp: Removed.
1091         * bindings/v8/custom/V8CustomPositionErrorCallback.h: Removed.
1092         * bindings/v8/custom/V8GeolocationCustom.cpp:
1093         (WebCore::V8Geolocation::getCurrentPositionCallback):
1094         (WebCore::V8Geolocation::watchPositionCallback):
1095         * page/PositionCallback.h:
1096         * page/PositionCallback.idl: Added.
1097         * page/PositionErrorCallback.h:
1098         * page/PositionErrorCallback.idl: Added.
1099
1100 2011-05-23  Pavel Podivilov  <podivilov@chromium.org>
1101
1102         Reviewed by Yury Semikhatsky.
1103
1104         Web Inspector: watched expressions buttons do not match inspector styles.
1105         https://bugs.webkit.org/show_bug.cgi?id=30554
1106
1107         * WebCore.gypi:
1108         * inspector/front-end/BreakpointsSidebarPane.js:
1109         (WebInspector.XHRBreakpointsSidebarPane):
1110         * inspector/front-end/Images/deleteIcon.png: Added.
1111         * inspector/front-end/Images/paneRefreshButtons.png: Added.
1112         * inspector/front-end/WatchExpressionsSidebarPane.js:
1113         (WebInspector.WatchExpressionsSidebarPane.prototype.reset):
1114         (WebInspector.WatchExpressionsSidebarPane.prototype._addButtonClicked):
1115         (WebInspector.WatchExpressionsSidebarPane.prototype._refreshButtonClicked):
1116         (WebInspector.WatchExpressionsSidebarPane.prototype.refreshExpressions):
1117         (WebInspector.WatchExpressionsSection):
1118         (WebInspector.WatchExpressionsSection.prototype.update.appendResult):
1119         (WebInspector.WatchExpressionsSection.prototype.update):
1120         (WebInspector.WatchExpressionsSection.prototype.saveExpressions):
1121         (WebInspector.WatchExpressionsSection.prototype._mouseMove):
1122         (WebInspector.WatchExpressionsSection.prototype._mouseOut):
1123         (WebInspector.WatchExpressionsSection.prototype._updateHoveredElement):
1124         (WebInspector.WatchExpressionsSection.CompareProperties):
1125         (WebInspector.WatchExpressionTreeElement.prototype.update):
1126         (WebInspector.WatchExpressionTreeElement.prototype.editingCancelled):
1127         * inspector/front-end/WebKit.qrc:
1128         * inspector/front-end/inspector.css:
1129         (.properties-tree.watch-expressions):
1130         (.properties-tree.watch-expressions li):
1131         (.section .properties .delete-button):
1132         (.section .properties li.hovered .delete-button):
1133         (.pane > .title > .pane-title-button):
1134         (.pane > .title > .pane-title-button:hover):
1135         (.pane > .title > .pane-title-button:active):
1136         (.pane > .title > .pane-title-button.add):
1137         (.pane > .title > .pane-title-button.refresh):
1138
1139 2011-05-24  Yuta Kitamura  <yutak@chromium.org>
1140
1141         Reviewed by Kent Tamura.
1142
1143         WebSocket: Add fail() to WebSocketChannel and its family
1144         https://bugs.webkit.org/show_bug.cgi?id=61277
1145
1146         This is the first part of refactoring effort described in bug 61115.
1147         Existing error reports will be modified to use fail() in a later patch.
1148
1149         No change in behavior, thus no new tests.
1150
1151         * websockets/ThreadableWebSocketChannel.h:
1152         * websockets/WebSocketChannel.cpp:
1153         (WebCore::WebSocketChannel::fail):
1154         * websockets/WebSocketChannel.h:
1155         * websockets/WorkerThreadableWebSocketChannel.cpp:
1156         (WebCore::WorkerThreadableWebSocketChannel::fail):
1157         (WebCore::WorkerThreadableWebSocketChannel::Peer::fail):
1158         (WebCore::WorkerThreadableWebSocketChannel::mainThreadFail):
1159         (WebCore::WorkerThreadableWebSocketChannel::Bridge::fail):
1160         * websockets/WorkerThreadableWebSocketChannel.h:
1161
1162 2011-05-24  Andras Becsi  <abecsi@webkit.org>
1163
1164         Reviewed by Csaba Osztrogon√°c.
1165
1166         [Qt][V8] REGRESSION (r87063): Fix the build.
1167         https://bugs.webkit.org/show_bug.cgi?id=61290
1168
1169         No new tests needed.
1170
1171         * bindings/scripts/CodeGeneratorV8.pm: disable the unsupported call
1172         tracked in: https://bugs.webkit.org/show_bug.cgi?id=61291
1173
1174 2011-05-24  Naoki Takano  <takano.naoki@gmail.com>
1175
1176         Reviewed by Kent Tamura.
1177
1178         [Chromium]Add clipping for listBox in popup window to fix wrong location display when the autofill item is really long.
1179         https://bugs.webkit.org/show_bug.cgi?id=61252
1180         http://code.google.com/p/chromium/issues/detail?id=83539
1181
1182         Manual test: manual-tests/autofill-popup-location.html.
1183
1184         * manual-tests/autofill-popup-location.html: With long long text, test the shown location is correct.
1185         * platform/chromium/PopupMenuChromium.cpp:
1186         (WebCore::PopupListBox::setBaseWidth): Clip width with m_maxWindowWidth.
1187         (WebCore::PopupListBox::PopupListBox): Add m_maxWindowWidth initialization.
1188         (WebCore::PopupContainer::layoutAndCalculateWidgetRect): Call setMaxWidthAndLayout() when the width is clipped with screen size.
1189         (WebCore::PopupListBox::setMaxWidthAndLayout): Set m_maxWindowWidth and call layout().
1190         (WebCore::PopupListBox::layout): Compare renewed windowWidth and m_maxWindowWidth, and clip the it.
1191
1192 2011-05-24  James Robinson  <jamesr@chromium.org>
1193
1194         Reviewed by Kenneth Russell.
1195
1196         [chromium] Properly handle huge initial dimensions for 2d canvas when accelerated 2d canvas is enabled
1197         https://bugs.webkit.org/show_bug.cgi?id=60077
1198
1199         Return NULL from DrawingBuffer::create() if the initial dimensions are larger than we can support in hardware so
1200         that we properly use the software canvas path and not enable the compositor for the canvas.
1201
1202         compositing/tiling/huge-layer-img.html triggers this case by trying to create a 20000 pixel high canvas.  The
1203         failure was previously masked by other bugs fixed by r85661.
1204
1205         * platform/graphics/chromium/DrawingBufferChromium.cpp:
1206         (WebCore::DrawingBuffer::DrawingBuffer):
1207             Return NULL from DrawingBuffer::create() if resize() fails.
1208
1209 2011-05-24  Fumitoshi Ukai  <ukai@chromium.org>
1210
1211         Reviewed by Adam Barth.
1212
1213         close before open WebSocket doesn't fire close event.
1214         https://bugs.webkit.org/show_bug.cgi?id=57301
1215
1216         In platformClose(), m_readStream may be 0 until proxy is resolved.
1217         It should callback didClose() in such case.
1218         
1219         Test: http/tests/websocket/tests/close-before-open.html
1220
1221         * platform/network/cf/SocketStreamHandleCFNet.cpp:
1222         (WebCore::SocketStreamHandle::platformClose):
1223
1224 2011-05-23  Sheriff Bot  <webkit.review.bot@gmail.com>
1225
1226         Unreviewed, rolling out r87118.
1227         http://trac.webkit.org/changeset/87118
1228         https://bugs.webkit.org/show_bug.cgi?id=61347
1229
1230         patch breaks layout tests
1231         (https://bugs.webkit.org/show_bug.cgi?id=61342), and chromium
1232         tests (browser_test MacTestCmdUp and ui_test Scrollbar)
1233         (Requested by ukai_ on #webkit).
1234
1235         * WebCore.gyp/WebCore.gyp:
1236         * WebCore.gypi:
1237         * platform/ScrollAnimator.cpp:
1238         * platform/chromium/ScrollAnimatorChromiumMac.h: Removed.
1239         * platform/chromium/ScrollAnimatorChromiumMac.mm: Removed.
1240         * platform/graphics/IntPoint.h:
1241
1242 2011-05-23  Julien Chaffraix  <jchaffraix@codeaurora.org>
1243
1244         Reviewed by Adam Barth.
1245
1246         Remove Node::deprecatedParserAddChild
1247         https://bugs.webkit.org/show_bug.cgi?id=60818
1248
1249         No new tests as this is just a removal.
1250
1251         * dom/ContainerNode.cpp:
1252         * dom/ContainerNode.h:
1253         * dom/Node.cpp:
1254         * dom/Node.h:
1255         Removed the method now that the last instance got removed as part of the <input>
1256         shadow DOM refactoring.
1257
1258 2011-05-23  Dirk Schulze  <krit@webkit.org>
1259
1260         Reviewed by Darin Adler.
1261
1262         SVGTextPositioning attributes are marked as NumberList instead of LengthList
1263         https://bugs.webkit.org/show_bug.cgi?id=61301
1264
1265         SVGTextPositioningElement attributes x, y, dx and dy were marked as AnimatedNumberList
1266         instead of AnimatedLengthList.
1267         See specification http://www.w3.org/TR/SVG/text.html#InterfaceSVGTextPositioningElement
1268
1269         This does not affect the behavior, since we do not respect SVG units in SMIL animation yet.
1270         No new tests added.
1271
1272         * svg/SVGTextPositioningElement.cpp:
1273         (WebCore::SVGTextPositioningElement::fillPassedAttributeToPropertyTypeMap):
1274
1275 2011-05-19  MORITA Hajime  <morrita@google.com>
1276
1277         Reviewed by Dimitri Glazkov.
1278
1279         [Refactoring] Pass NodeRenderingContext to Node::rendererIsNeeded()
1280         https://bugs.webkit.org/show_bug.cgi?id=61114
1281
1282         - Extracted NodeRenderingContext from NodeRendererFactory, giving separate files to it.
1283         - Changed signature rendererIsNeeded(RenderStyle*) 
1284           to rendererIsNeeded(const NodeRenderingContext&).
1285           The style object is retrieved from NodeRendererFactory::style()
1286           This will allow rendererIsNeeded() to access contextual
1287           information like attaching phase and rendering-parent.
1288         
1289         No new tests. No behaviour change.
1290         
1291         * CMakeLists.txt:
1292         * GNUmakefile.list.am:
1293         * WebCore.gypi:
1294         * WebCore.pro:
1295         * WebCore.vcproj/WebCore.vcproj:
1296         * WebCore.xcodeproj/project.pbxproj:
1297         * dom/CharacterData.cpp:
1298         (WebCore::CharacterData::updateRenderer): Pass unresolved NodeRenderingContext& to rendererIsNeeded()
1299         (WebCore::CharacterData::rendererIsNeeded):
1300         * dom/CharacterData.h:
1301         * dom/DOMAllInOne.cpp:
1302         * dom/EditingText.cpp:
1303         (WebCore::EditingText::rendererIsNeeded):
1304         * dom/EditingText.h:
1305         * dom/Node.cpp:
1306         (WebCore::Node::parentNodeForRenderingAndStyle):
1307         (WebCore::Node::rendererIsNeeded):
1308         * dom/Node.h:
1309         * dom/NodeRenderingContext.cpp: Added.
1310         (WebCore::NodeRenderingContext::NodeRenderingContext):
1311         (WebCore::NodeRenderingContext::~NodeRenderingContext):
1312         (WebCore::NodeRenderingContext::setStyle):
1313         (WebCore::NodeRenderingContext::releaseStyle):
1314         (WebCore::NodeRenderingContext::nextRenderer):
1315         (WebCore::NodeRenderingContext::parentRenderer):
1316         (WebCore::NodeRenderingContext::hostChildrenChanged):
1317         (WebCore::NodeRenderingContext::shouldCreateRenderer):
1318         (WebCore::NodeRendererFactory::NodeRendererFactory):
1319         (WebCore::NodeRendererFactory::createRendererAndStyle):
1320         (WebCore::wrapWithRenderFullScreen):
1321         (WebCore::NodeRendererFactory::createRendererIfNeeded):
1322         * dom/NodeRenderingContext.h: Added.
1323         (WebCore::NodeRenderingContext::node):
1324         (WebCore::NodeRenderingContext::parentNodeForRenderingAndStyle):
1325         (WebCore::NodeRenderingContext::style):
1326         (WebCore::NodeRendererFactory::context):
1327         * dom/ShadowContentElement.h:
1328         * dom/Text.cpp:
1329         * dom/Text.h:
1330         * html/HTMLAppletElement.cpp:
1331         * html/HTMLAppletElement.h:
1332         * html/HTMLElement.cpp:
1333         * html/HTMLElement.h:
1334         * html/HTMLEmbedElement.cpp:
1335         * html/HTMLEmbedElement.h:
1336         * html/HTMLFormElement.cpp:
1337         * html/HTMLFormElement.h:
1338         * html/HTMLFrameElement.cpp:
1339         * html/HTMLFrameElement.h:
1340         * html/HTMLFrameSetElement.cpp:
1341         * html/HTMLFrameSetElement.h:
1342         * html/HTMLIFrameElement.cpp:
1343         * html/HTMLIFrameElement.h:
1344         * html/HTMLInputElement.cpp:
1345         * html/HTMLInputElement.h:
1346         * html/HTMLMediaElement.cpp:
1347         * html/HTMLMediaElement.h:
1348         * html/HTMLNoScriptElement.h:
1349         * html/HTMLObjectElement.cpp:
1350         * html/HTMLObjectElement.h:
1351         * html/HTMLOptGroupElement.h:
1352         * html/HTMLOptionElement.h:
1353         * html/HTMLVideoElement.cpp:
1354         * html/HTMLVideoElement.h:
1355         * html/shadow/DetailsMarkerControl.cpp:
1356         * html/shadow/DetailsMarkerControl.h:
1357         * html/shadow/MeterShadowElement.cpp:
1358         * html/shadow/MeterShadowElement.h:
1359         * html/shadow/ProgressShadowElement.cpp:
1360         * html/shadow/ProgressShadowElement.h:
1361         * svg/SVGDescElement.h:
1362         * svg/SVGElement.h:
1363         * svg/SVGFilterPrimitiveStandardAttributes.cpp:
1364         * svg/SVGFilterPrimitiveStandardAttributes.h:
1365         * svg/SVGFontElement.h:
1366         * svg/SVGGElement.cpp:
1367         * svg/SVGGElement.h:
1368         * svg/SVGGlyphElement.h:
1369         * svg/SVGHKernElement.h:
1370         * svg/SVGMarkerElement.h:
1371         * svg/SVGMissingGlyphElement.h:
1372         * svg/SVGSVGElement.h:
1373         * svg/SVGStyledElement.cpp:
1374         * svg/SVGStyledElement.h:
1375         * svg/SVGSymbolElement.h:
1376         * svg/SVGTRefElement.cpp:
1377         * svg/SVGTRefElement.h:
1378         * svg/SVGTSpanElement.cpp:
1379         * svg/SVGTSpanElement.h:
1380         * svg/SVGTextPathElement.cpp:
1381         * svg/SVGTextPathElement.h:
1382         * svg/SVGTitleElement.h:
1383         * svg/SVGVKernElement.h:
1384         * svg/SVGViewElement.h:
1385
1386 2011-05-20  MORITA Hajime  <morrita@google.com>
1387
1388         Reviewed by Dimitri Glazkov.
1389         
1390         [Refactoring] attach() following detach() should be replaced with Node::reattach()
1391         https://bugs.webkit.org/show_bug.cgi?id=61011
1392
1393         - Renamed forceReattach() to reattach()
1394         - Introduced reattachIfAttached() as a variant.
1395         
1396         No new tests. No behavior change.
1397
1398         * dom/CharacterData.cpp:
1399         (WebCore::CharacterData::updateRenderer):
1400         * dom/Element.cpp:
1401         (WebCore::Element::recalcStyle):
1402         * dom/Node.h:
1403         (WebCore::Node::reattach):
1404         (WebCore::Node::reattachIfAttached):
1405         * dom/Text.cpp:
1406         (WebCore::Text::recalcStyle):
1407         * html/HTMLDetailsElement.cpp:
1408         (WebCore::HTMLDetailsElement::refreshMainSummary):
1409         (WebCore::HTMLDetailsElement::parseMappedAttribute):
1410         * html/HTMLInputElement.cpp:
1411         (WebCore::HTMLInputElement::parseMappedAttribute):
1412         * html/HTMLObjectElement.cpp:
1413         (WebCore::HTMLObjectElement::renderFallbackContent):
1414         * html/HTMLPlugInImageElement.cpp:
1415         (WebCore::HTMLPlugInImageElement::recalcStyle):
1416         * html/HTMLSelectElement.cpp:
1417         (WebCore::HTMLSelectElement::parseMappedAttribute):
1418
1419 2011-05-23  Mark Rowe  <mrowe@apple.com>
1420
1421         Build fix after r87117.
1422
1423         When moving #defines out in to separate files I find that code is more likely to compile
1424         when the new header file is actually #included.
1425
1426         * editing/SpellingCorrectionController.h:
1427
1428 2011-05-23  Mike Lawther  <mikelawther@chromium.org>
1429
1430         Reviewed by James Robinson.
1431
1432         implement image-rendering: optimize-contrast (with a vendor prefix) as defined in CSS3 image values
1433         https://bugs.webkit.org/show_bug.cgi?id=56627
1434
1435         Tests: css3/images/optimize-contrast-canvas.html
1436                css3/images/optimize-contrast-image.html
1437
1438         * WebCore.xcodeproj/project.pbxproj:
1439         * css/CSSComputedStyleDeclaration.cpp:
1440         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1441         * css/CSSParser.cpp:
1442         (WebCore::CSSParser::parseValue):
1443         * css/CSSPrimitiveValueMappings.h:
1444         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
1445         (WebCore::CSSPrimitiveValue::operator EImageRendering):
1446         * css/CSSPropertyNames.in:
1447         * css/CSSStyleSelector.cpp:
1448         (WebCore::CSSStyleSelector::applyProperty):
1449         * css/CSSValueKeywords.in:
1450         * css/SVGCSSComputedStyleDeclaration.cpp:
1451         (WebCore::CSSComputedStyleDeclaration::getSVGPropertyCSSValue):
1452         * css/SVGCSSPropertyNames.in:
1453         * css/SVGCSSStyleSelector.cpp:
1454         (WebCore::CSSStyleSelector::applySVGProperty):
1455         * css/SVGCSSValueKeywords.in:
1456         * html/HTMLCanvasElement.cpp:
1457         (WebCore::HTMLCanvasElement::paint):
1458         * html/HTMLCanvasElement.h:
1459         * platform/graphics/ImageRenderingMode.h: Added.
1460         * rendering/RenderBoxModelObject.cpp:
1461         (WebCore::ImageQualityController::shouldPaintAtLowQuality):
1462         * rendering/RenderHTMLCanvas.cpp:
1463         (WebCore::RenderHTMLCanvas::paintReplaced):
1464         * rendering/style/RenderStyle.cpp:
1465         (WebCore::RenderStyle::diff):
1466         * rendering/style/RenderStyle.h:
1467         (WebCore::InheritedFlags::imageRendering):
1468         (WebCore::InheritedFlags::setImageRendering):
1469         (WebCore::InheritedFlags::initialImageRendering):
1470         * rendering/style/RenderStyleConstants.h:
1471         * rendering/style/SVGRenderStyle.cpp:
1472         (WebCore::SVGRenderStyle::diff):
1473         * rendering/style/SVGRenderStyle.h:
1474         (WebCore::SVGRenderStyle::InheritedFlags::operator==):
1475         (WebCore::SVGRenderStyle::setBitDefaults):
1476         * rendering/style/SVGRenderStyleDefs.h:
1477         * rendering/svg/SVGRenderTreeAsText.cpp:
1478         (WebCore::writeStyle):
1479
1480 2011-05-23  Sailesh Agrawal  <sail@chromium.org>
1481
1482         Reviewed by James Robinson.
1483
1484         Chromium Mac: Use ScrollAnimatorMac.mm for overlay scrollbar support
1485         https://bugs.webkit.org/show_bug.cgi?id=59753
1486
1487         No new tests. Just forking ScrollAnimatorMac to ScrollAnimatorChromiumMac.
1488
1489         * WebCore.gyp/WebCore.gyp:
1490         * WebCore.gypi:
1491         * platform/ScrollAnimator.cpp:
1492         * platform/chromium/ScrollAnimatorChromiumMac.h: Added.
1493         (WebCore::ScrollAnimatorChromiumMac::setIsDrawingIntoLayer):
1494         (WebCore::ScrollAnimatorChromiumMac::isDrawingIntoLayer):
1495         (WebCore::ScrollAnimatorChromiumMac::haveScrolledSincePageLoad):
1496         * 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.
1497         (abs):
1498         (-[ScrollAnimationHelperDelegate initWithScrollAnimator:WebCore::]):
1499         (-[ScrollAnimationHelperDelegate scrollAnimatorDestroyed]):
1500         (-[ScrollAnimationHelperDelegate bounds]):
1501         (-[ScrollAnimationHelperDelegate _immediateScrollToPoint:]):
1502         (-[ScrollAnimationHelperDelegate _pixelAlignProposedScrollPosition:]):
1503         (-[ScrollAnimationHelperDelegate convertSizeToBase:]):
1504         (-[ScrollAnimationHelperDelegate convertSizeFromBase:]):
1505         (-[ScrollAnimationHelperDelegate convertSizeToBacking:]):
1506         (-[ScrollAnimationHelperDelegate convertSizeFromBacking:]):
1507         (-[ScrollAnimationHelperDelegate superview]):
1508         (-[ScrollAnimationHelperDelegate documentView]):
1509         (-[ScrollAnimationHelperDelegate window]):
1510         (-[ScrollAnimationHelperDelegate _recursiveRecomputeToolTips]):
1511         (-[ScrollbarPainterControllerDelegate initWithScrollAnimator:WebCore::]):
1512         (-[ScrollbarPainterControllerDelegate scrollAnimatorDestroyed]):
1513         (-[ScrollbarPainterControllerDelegate contentAreaRectForScrollerImpPair:]):
1514         (-[ScrollbarPainterControllerDelegate inLiveResizeForScrollerImpPair:]):
1515         (-[ScrollbarPainterControllerDelegate mouseLocationInContentAreaForScrollerImpPair:]):
1516         (-[ScrollbarPainterControllerDelegate scrollerImpPair:convertContentPoint:toScrollerImp:]):
1517         (-[ScrollbarPainterControllerDelegate scrollerImpPair:setContentAreaNeedsDisplayInRect:]):
1518         (-[ScrollbarPainterControllerDelegate scrollerImpPair:updateScrollerStyleForNewRecommendedScrollerStyle:]):
1519         (-[ScrollbarPartAnimation initWithScrollbarPainter:part:WebCore::scrollAnimator:WebCore::animateAlphaTo:duration:]):
1520         (-[ScrollbarPartAnimation setCurrentProgress:]):
1521         (-[ScrollbarPartAnimation scrollAnimatorDestroyed]):
1522         (-[ScrollbarPainterDelegate initWithScrollAnimator:WebCore::]):
1523         (-[ScrollbarPainterDelegate cancelAnimations]):
1524         (-[ScrollbarPainterDelegate convertRectToBacking:]):
1525         (-[ScrollbarPainterDelegate convertRectFromBacking:]):
1526         (-[ScrollbarPainterDelegate layer]):
1527         (-[ScrollbarPainterDelegate setUpAnimation:scrollerPainter:part:WebCore::animateAlphaTo:duration:]):
1528         (-[ScrollbarPainterDelegate scrollerImp:animateKnobAlphaTo:duration:]):
1529         (-[ScrollbarPainterDelegate scrollerImp:animateTrackAlphaTo:duration:]):
1530         (-[ScrollbarPainterDelegate scrollerImp:overlayScrollerStateChangedTo:]):
1531         (-[ScrollbarPainterDelegate scrollAnimatorDestroyed]):
1532         (WebCore::ScrollAnimator::create):
1533         (WebCore::ScrollAnimatorChromiumMac::ScrollAnimatorChromiumMac):
1534         (WebCore::ScrollAnimatorChromiumMac::~ScrollAnimatorChromiumMac):
1535         (WebCore::ScrollAnimatorChromiumMac::scroll):
1536         (WebCore::ScrollAnimatorChromiumMac::scrollToOffsetWithoutAnimation):
1537         (WebCore::ScrollAnimatorChromiumMac::adjustScrollXPositionIfNecessary):
1538         (WebCore::ScrollAnimatorChromiumMac::adjustScrollYPositionIfNecessary):
1539         (WebCore::ScrollAnimatorChromiumMac::adjustScrollPositionIfNecessary):
1540         (WebCore::ScrollAnimatorChromiumMac::immediateScrollToPoint):
1541         (WebCore::ScrollAnimatorChromiumMac::immediateScrollByDeltaX):
1542         (WebCore::ScrollAnimatorChromiumMac::immediateScrollByDeltaY):
1543         (WebCore::ScrollAnimatorChromiumMac::notityPositionChanged):
1544         (WebCore::ScrollAnimatorChromiumMac::contentAreaWillPaint):
1545         (WebCore::ScrollAnimatorChromiumMac::mouseEnteredContentArea):
1546         (WebCore::ScrollAnimatorChromiumMac::mouseExitedContentArea):
1547         (WebCore::ScrollAnimatorChromiumMac::mouseMovedInContentArea):
1548         (WebCore::ScrollAnimatorChromiumMac::willStartLiveResize):
1549         (WebCore::ScrollAnimatorChromiumMac::contentsResized):
1550         (WebCore::ScrollAnimatorChromiumMac::willEndLiveResize):
1551         (WebCore::ScrollAnimatorChromiumMac::contentAreaDidShow):
1552         (WebCore::ScrollAnimatorChromiumMac::contentAreaDidHide):
1553         (WebCore::ScrollAnimatorChromiumMac::didBeginScrollGesture):
1554         (WebCore::ScrollAnimatorChromiumMac::didEndScrollGesture):
1555         (WebCore::ScrollAnimatorChromiumMac::didAddVerticalScrollbar):
1556         (WebCore::ScrollAnimatorChromiumMac::willRemoveVerticalScrollbar):
1557         (WebCore::ScrollAnimatorChromiumMac::didAddHorizontalScrollbar):
1558         (WebCore::ScrollAnimatorChromiumMac::willRemoveHorizontalScrollbar):
1559         (WebCore::ScrollAnimatorChromiumMac::cancelAnimations):
1560         (WebCore::elasticDeltaForTimeDelta):
1561         (WebCore::reboundDeltaForElasticDelta):
1562         (WebCore::elasticDeltaForReboundDelta):
1563         (WebCore::scrollWheelMultiplier):
1564         (WebCore::ScrollAnimatorChromiumMac::handleWheelEvent):
1565         (WebCore::ScrollAnimatorChromiumMac::handleGestureEvent):
1566         (WebCore::ScrollAnimatorChromiumMac::pinnedInDirection):
1567         (WebCore::ScrollAnimatorChromiumMac::allowsVerticalStretching):
1568         (WebCore::ScrollAnimatorChromiumMac::allowsHorizontalStretching):
1569         (WebCore::ScrollAnimatorChromiumMac::smoothScrollWithEvent):
1570         (WebCore::ScrollAnimatorChromiumMac::beginScrollGesture):
1571         (WebCore::ScrollAnimatorChromiumMac::endScrollGesture):
1572         (WebCore::ScrollAnimatorChromiumMac::snapRubberBand):
1573         (WebCore::roundTowardZero):
1574         (WebCore::roundToDevicePixelTowardZero):
1575         (WebCore::ScrollAnimatorChromiumMac::snapRubberBandTimerFired):
1576         (WebCore::ScrollAnimatorChromiumMac::startScrollbarPaintTimer):
1577         (WebCore::ScrollAnimatorChromiumMac::scrollbarPaintTimerIsActive):
1578         (WebCore::ScrollAnimatorChromiumMac::stopScrollbarPaintTimer):
1579         (WebCore::ScrollAnimatorChromiumMac::initialScrollbarPaintTimerFired):
1580         (WebCore::ScrollAnimatorChromiumMac::setVisibleScrollerThumbRect):
1581         * platform/graphics/IntPoint.h:
1582
1583 2011-05-22  MORITA Hajime  <morrita@google.com>
1584
1585         Reviewed by Ryosuke Niwa.
1586
1587         SUPPORT_AUTOCORRECTION_PANEL should be USE(AUTOCORRECTION_PANEL)
1588         https://bugs.webkit.org/show_bug.cgi?id=61181
1589
1590         - Removed SUPPORT_AUTOCORRECTION_PANEL and REMOVE_MARKERS_UPON_EDITING from SpellingCorrectionController.h
1591         - Define WTF_USE_UNIFIED_TEXT_CHECKING and WTF_USE_AUTOMATIC_TEXT_REPLACEMENT at TextChecking.h
1592
1593         No new tests. Just renaming a compilation conditional.
1594
1595         * editing/Editor.cpp:
1596         (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges):
1597         * editing/SpellingCorrectionCommand.cpp:
1598         (WebCore::SpellingCorrectionCommand::doApply):
1599         * editing/SpellingCorrectionController.cpp:
1600         * editing/SpellingCorrectionController.h:
1601         (WebCore::SpellingCorrectionController::shouldRemoveMarkersUponEditing):
1602         * loader/EmptyClients.h:
1603         * page/EditorClient.h:
1604         * platform/text/TextChecking.h:
1605
1606 2011-05-23  Sheriff Bot  <webkit.review.bot@gmail.com>
1607
1608         Unreviewed, rolling out r87007.
1609         http://trac.webkit.org/changeset/87007
1610         https://bugs.webkit.org/show_bug.cgi?id=61329
1611
1612         patch unnecessarily breaks HTML5 compatibility (Requested by
1613         estes on #webkit).
1614
1615         * html/HTMLObjectElement.cpp:
1616         (WebCore::HTMLObjectElement::hasValidClassId):
1617
1618 2011-05-23  Julien Chaffraix  <jchaffraix@codeaurora.org>
1619
1620         Reviewed by Darin Adler.
1621
1622         Crash from null pointer dereference below WebCore::StorageAreaImpl::setItem()
1623         https://bugs.webkit.org/show_bug.cgi?id=57140
1624
1625         Test: fast/storage/storage-detached-iframe.html
1626
1627         Access of localStorage on a detached iframe was causing a crash because a detached 
1628         iframe has a null m_page, and WebCore::privateBrowsingEnabled() wasn't testing for such.
1629
1630         * storage/StorageAreaImpl.cpp:
1631         (WebCore::privateBrowsingEnabled): check that child->page() is non-null before
1632         accessing it.
1633
1634 2011-05-23  Chris Fleizach  <cfleizach@apple.com>
1635
1636         Reviewed by David Kilzer.
1637
1638         VO doesn't work with HTML5 range (slider) input @step attribute
1639         https://bugs.webkit.org/show_bug.cgi?id=61298
1640
1641         Test: platform/mac/accessibility/range-alter-by-step.html
1642
1643         * accessibility/AccessibilityObject.h:
1644         (WebCore::AccessibilityObject::stepValueForRange):
1645         * accessibility/AccessibilityRenderObject.cpp:
1646         (WebCore::AccessibilityRenderObject::alterSliderValue):
1647         (WebCore::AccessibilityRenderObject::increment):
1648         (WebCore::AccessibilityRenderObject::decrement):
1649         (WebCore::AccessibilityRenderObject::stepValueForRange):
1650         (WebCore::AccessibilityRenderObject::changeValueByStep):
1651         * accessibility/AccessibilityRenderObject.h:
1652
1653 2011-05-23  Gavin Peters  <gavinp@chromium.org>
1654
1655         Reviewed by Adam Barth.
1656
1657         fix rel=prerender target types
1658         https://bugs.webkit.org/show_bug.cgi?id=61297
1659
1660         The original fix in https://bugs.webkit.org/show_bug.cgi?id=61079
1661         didn't properly map the target type, and didn't carry the target
1662         types through to chromium properly.  Fixed.
1663
1664         No new tests; it's very hard to catch these with a layout test, however
1665         all of the chromium Prerender browser tests will test this functionality
1666         when I land an upcoming chromium CL.
1667
1668         * loader/cache/CachedResourceRequest.cpp:
1669         (WebCore::cachedResourceTypeToTargetType):
1670
1671 2011-05-23  Matthew Delaney  <mdelaney@apple.com>
1672
1673         Reviewed by Simon Fraser.
1674
1675         Remove safeFloatToInt() in FloatRect.cpp and replace with working version of clampToInteger()
1676         https://bugs.webkit.org/show_bug.cgi?id=58216
1677
1678         No new tests. The SVG tests mask-excessive-malloc.svg and pattern-excessive-malloc.svg exercise this code path.
1679
1680         * platform/graphics/FloatRect.cpp:
1681         (WebCore::enclosingIntRect):
1682
1683 2011-05-20  Jeremy Noble  <jer.noble@apple.com>
1684
1685         Reviewed by Darin Adler.
1686
1687         Video looks squished when animating to full screen.
1688         https://bugs.webkit.org/show_bug.cgi?id=61220
1689
1690         No new tests, because DumpRenderTree does not currently "animate" the full-screen transition.
1691
1692         There are three issues animating video content to full screen which this patch is meant to
1693         address:
1694         1) The animation scales between the client sizes of the element before and after full-screen.
1695         Because these sizes have different aspect ratios, the video appears "squished" for part of
1696         the animation. Instead, we will animate between the content box sizes before and after full
1697         screen which, in the case of video now and object-fit content in the future, will have the
1698         same aspect ratio before and after full screen.
1699         2) Now that we are animating the full-screen video element's content box, the black letterbox
1700         bars appear above and below the video (depending on the video's aspect ratio) as soon as the
1701         animation begins. This is extremely jarring, so set the background color to clear. The
1702         full-screen renderer's background color will serve the same purpose (providing the letterbox
1703         background) once the animation completes.
1704         3) Now that the letterbox color is gone, the full screen controls can appear to float in thin
1705         air beneath the video (again, depending on aspect ratio) during the animation, so to avoid
1706         that effect and to make the animation consistent with the old webkitenterfullscreen()
1707         animation, we will hide the controls during the animation by adding a new CSS pseudo class
1708         -webkit-animating-full-screen-transition.
1709
1710         Added a new css pseudo-class: -webkit-animating-full-screen.  During the transition animation, this
1711         pseudo-class will be applied to the current full-screen element.  Styles have been added to 
1712         fullscreenQuickTime.css to hide the video element's built-in controller during the full-screen
1713         animation.
1714
1715         To accomplish this, the ivar tracking whether the full-screen animation is taking place has been moved
1716         from the RenderFullScreen renderer, to the current full-screen Document.  Because changing 
1717         isAnimatingFullScreen causes style changes, make sure to call recalcStyle on the full-screen element
1718         after changing.
1719
1720         This extra transition caused assertions in HTMLFormControlElement::updateFromElementCallback. A
1721         full-screen media control's renderer is disabled during the style recalculation when exiting full
1722         screen. This assertion was exposed by the extra recalcStyle() issued during the exit transition, and
1723         has been removed.
1724
1725         * WebCore.exp.in:
1726         * css/CSSSelector.cpp:
1727         (WebCore::CSSSelector::pseudoId): Add support for new pseudo class -webkit-animate-full-screen-transition.
1728         (WebCore::nameToPseudoTypeMap): Ditto.
1729         (WebCore::CSSSelector::extractPseudoType): Ditto.
1730         * css/CSSSelector.h:
1731         * css/CSSStyleSelector.cpp:
1732         (WebCore::CSSStyleSelector::SelectorChecker::checkOneSelector): Ditto.
1733         * css/fullscreen.css: 
1734         (video:-webkit-full-screen): Set full screen video background color to clear.
1735         * css/fullscreenQuickTime.css: 
1736         (video:-webkit-full-screen::-webkit-media-controls-panel): Set a default opacity transition.
1737         (video:-webkit-animating-full-screen::-webkit-media-controls-panel): Set the opacity to 0 and 
1738             disable the transition.
1739         * dom/Document.cpp:
1740         (WebCore::Document::Document):
1741         (WebCore::Document::webkitWillEnterFullScreenForElement): Call our new setAnimatingFullScreen function.
1742         (WebCore::Document::webkitDidEnterFullScreenForElement): Ditto.
1743         (WebCore::Document::webkitWillExitFullScreenForElement): Ditto.
1744         (WebCore::Document::webkitDidExitFullScreenForElement): Ditto.
1745         (WebCore::Document::isAnimatingFullScreen): Moved here from RenderFullScreen.
1746         (WebCore::Document::setAnimatingFullScreen): Ditto.
1747         * dom/Document.h:
1748         * html/HTMLFormControlElement.cpp: 
1749         (WebCore::updateFromElementCallback): Use the Document's isAnimatingFullScreen function.
1750         * page/FrameView.cpp:
1751         (WebCore::isDocumentRunningFullScreenAnimation): Ditto.
1752         * rendering/RenderFullScreen.cpp:
1753         * rendering/RenderFullScreen.h:
1754         * rendering/RenderLayerCompositor.cpp:
1755         (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree): Ditto.
1756         (WebCore::RenderLayerCompositor::requiresCompositingForFullScreen): Ditto.
1757         * rendering/style/RenderStyleConstants.h:
1758
1759 2011-05-23  Emil A Eklund  <eae@chromium.org>
1760
1761         Reviewed by Eric Seidel.
1762
1763         Change RenderBlock hit testing to use IntPoint instead x,y pair
1764         https://bugs.webkit.org/show_bug.cgi?id=61146
1765
1766         Covered by existing tests.
1767
1768         * platform/graphics/IntPoint.h:
1769         (WebCore::toSize):
1770         Add toSize function for converting from point to size.
1771
1772         * rendering/RenderBlock.cpp:
1773         (WebCore::RenderBlock::isPointInOverflowControl):
1774         (WebCore::RenderBlock::nodeAtPoint):
1775         (WebCore::RenderBlock::hitTestFloats):
1776         (WebCore::RenderBlock::hitTestColumns):
1777         (WebCore::RenderBlock::hitTestContents):
1778         * rendering/RenderBlock.h:
1779         Change hit testing code in RenderBlock to use IntPoint.
1780
1781         * rendering/RenderListBox.cpp:
1782         (WebCore::RenderListBox::isPointInOverflowControl):
1783         * rendering/RenderListBox.h:
1784         Change overridden method to use IntPoint.
1785
1786 2011-05-23  Mike Reed  <reed@google.com>
1787
1788         Reviewed by James Robinson.
1789
1790         Skia: Need to implement GraphicsContext::clipConvexPolygon()
1791         https://bugs.webkit.org/show_bug.cgi?id=41311
1792
1793         No new tests. 
1794
1795         * platform/graphics/skia/GraphicsContextSkia.cpp:
1796         (WebCore::setPathFromConvexPoints):
1797         (WebCore::GraphicsContext::drawConvexPolygon):
1798         (WebCore::GraphicsContext::clipConvexPolygon):
1799
1800 2011-05-23  James Simonsen  <simonjam@chromium.org>
1801
1802         Reviewed by Adam Barth.
1803
1804         Convert raw pointer to RefPtr.
1805         https://bugs.webkit.org/show_bug.cgi?id=61196
1806
1807         * dom/XMLDocumentParserLibxml2.cpp:
1808         (WebCore::XMLDocumentParser::endElementNs):
1809         * dom/XMLDocumentParserQt.cpp:
1810         (WebCore::XMLDocumentParser::parseEndElement):
1811
1812 2011-05-23  Ryosuke Niwa  <rniwa@webkit.org>
1813
1814         Reviewed by Alexey Proskuryakov.
1815
1816         selectstart is fired for every mouse move
1817         https://bugs.webkit.org/show_bug.cgi?id=19489
1818
1819         Fixed the bug by dispatching selectstart event immediately before modifying selection in
1820         handleMousePressEventSingleClick and updateSelectionForMouseDrag.
1821
1822         Also replaced a boolean EventHandler::m_beganSelectingText by an enum-valued m_selectionInitiationState
1823         to retain 3 states:
1824         1. HaveNotStartedSelection - Selection has not been set by a mouse drag or a mouse click
1825         2. PlacedCaret - A caret was placed by a mouse click, double click, or triple click, and is about
1826         to replace selection if a mouse drag never occurs.
1827         3. ExtendedSelection - A range selection was set by a mouse click, a double click, a triple click,
1828         or a mouse drag; otherwise a caret selection was set by a mouse drag.
1829
1830         State 1 corresponds to m_beganSelectingText being false and state 3 corresponds to m_beganSelectingText
1831         being true. State 2 is used in updateSelectionForMouseDrag to avoid dispatching selectstart twice.
1832
1833         States 1 and 2 are set by updateSelectionForMouseDownDispatchingSelectStart and state 3 is set by
1834         updateSelectionForMouseDrag.
1835
1836         Test: fast/events/selectstart-by-double-triple-clicks.html
1837               fast/events/selectstart-by-drag.html
1838               fast/events/selectstart-by-single-click-with-shift.html
1839
1840         * page/EventHandler.cpp: Removed canMouseDragExtendSelect.
1841         (WebCore::EventHandler::EventHandler): Initializes m_selectionInitiationState.
1842         (WebCore::dispatchSelectStart): Returns true only if selectstart was successfully fired
1843         and default action was not prevented.
1844         (WebCore::EventHandler::updateSelectionForMouseDownDispatchingSelectStart): Updates m_selectionInitiationState
1845         and modifies the selection if dispatchSelectStart returns true.
1846         (WebCore::EventHandler::selectClosestWordFromMouseEvent): Calls updateSelectionForMouseDownDispatchingSelectStart.
1847         (WebCore::EventHandler::selectClosestWordOrLinkFromMouseEvent): Ditto.
1848         (WebCore::EventHandler::handleMousePressEventDoubleClick):
1849         (WebCore::EventHandler::handleMousePressEventTripleClick): Ditto.
1850         (WebCore::EventHandler::handleMousePressEventSingleClick): Ditto.
1851         (WebCore::canMouseDownStartSelect): No longer dispatches startselect; also renamed from
1852         EventHandler::canMouseDownStartSelect.
1853         (WebCore::EventHandler::handleMousePressEvent): No longer calls canMouseDragExtendSelect.
1854         (WebCore::EventHandler::handleMouseDraggedEvent):
1855         (WebCore::EventHandler::updateSelectionForMouseDrag): Exit early if m_selectionInitiationState is
1856         HaveNotStartedSelection and dispatchSelectStart returns false. Since setSelectionIfPossible dispatches
1857         selectstart event before assigning PlacedCaret or ExtendedSelection to m_selectionInitiationState,
1858         there is no need to dispatch event for those two cases.
1859         (WebCore::EventHandler::handleMouseReleaseEvent):
1860         * page/EventHandler.h: Removed canMouseDownStartSelect and canMouseDragExtendSelect from EventHandler
1861         and added setSelectionIfPossible.
1862
1863 2011-05-23  Adam Klein  <adamk@chromium.org>
1864
1865         Reviewed by Jian Li.
1866
1867         [fileapi] Add a File::createWithName method to avoid obfuscated filename leakage from FileEntry.file() method
1868         https://bugs.webkit.org/show_bug.cgi?id=61155
1869
1870         Covered by existing tests: fast/filesystem/file-from-file-entry.html
1871                                    fast/filesystem/workers/file-from-file-entry.html
1872                                    fast/filesystem/workers/file-from-file-entry-sync.html
1873
1874         * fileapi/DOMFileSystem.cpp:
1875         (WebCore::DOMFileSystem::createFile): Updated to call createWithName().
1876         * fileapi/DOMFileSystemSync.cpp:
1877         (WebCore::DOMFileSystemSync::createFile): Updated to call createWithName().
1878         * fileapi/File.cpp:
1879         (WebCore::createBlobDataForFile): Added an optional name argument to fix MIME type lookup.
1880         (WebCore::File::createWithRelativePath): Renamed from create() for consistency with new method.
1881         (WebCore::File::File):
1882         * fileapi/File.h:
1883         (WebCore::File::createWithName):
1884         * html/FileInputType.cpp:
1885         (WebCore::FileInputType::setFileList): Updated the single caller of File::createWithRelativePath().
1886
1887 2011-05-23  Adrienne Walker  <enne@google.com>
1888
1889         Reviewed by James Robinson.
1890
1891         [chromium] Fix division by zero in TilingData for boundary case texture sizes
1892         https://bugs.webkit.org/show_bug.cgi?id=61164
1893
1894         * platform/graphics/gpu/TilingData.cpp:
1895         (WebCore::TilingData::tileXIndexFromSrcCoord):
1896         (WebCore::TilingData::tileYIndexFromSrcCoord):
1897
1898 2011-05-23  Adam Barth  <abarth@webkit.org>
1899
1900         Reviewed by Eric Seidel.
1901
1902         Update ImageDecoder::create to match sniffing spec
1903         https://bugs.webkit.org/show_bug.cgi?id=47683
1904
1905         This change is difficult to test.  We're making this change to comply
1906         with standards even if the change is difficult to observe.  (This patch
1907         also causes us to match Firefox.)
1908
1909         Test: fast/images/busted-oval-does-not-render.html
1910
1911         * platform/image-decoders/ImageDecoder.cpp:
1912
1913 2011-05-23  Ruben  <chromium@hybridsource.org>
1914
1915         Reviewed by Tony Chang.
1916
1917         Chromium gyp patch to use new POSIX defines toolkit_uses_gtk and os_posix
1918         https://bugs.webkit.org/show_bug.cgi?id=61219
1919
1920         No new tests, just changing gyp defines.
1921
1922         * WebCore.gyp/WebCore.gyp:
1923
1924 2011-05-23  Abhishek Arya  <inferno@chromium.org>
1925
1926         Reviewed by Simon Fraser.
1927
1928         Terminate css color parsing on integers which are not followed
1929         by a terminator.
1930         https://bugs.webkit.org/show_bug.cgi?id=61293
1931
1932         Test: fast/css/parse-color-int-or-percent-crash.html
1933
1934         * css/CSSParser.cpp:
1935         (WebCore::parseColorIntOrPercentage):
1936
1937 2011-05-20  Ryosuke Niwa  <rniwa@webkit.org>
1938
1939         Reviewed by Enrica Casucci.
1940
1941         REGRESSION(r84311): WebKit copies too much styles when copying
1942         https://bugs.webkit.org/show_bug.cgi?id=60914
1943
1944         The bug was caused by WebKit's cloning node hierarchy up until the node that has background color.
1945         Fixed the bug by not cloning background color and adding the effective background color to the wrapping
1946         style span.
1947
1948         Tests: editing/pasteboard/do-no-clone-unnecessary-styles-2.html
1949                editing/pasteboard/do-no-clone-unnecessary-styles.html
1950
1951         * editing/EditingStyle.cpp:
1952         (WebCore::cssValueToRGBA): Extracted from getRGBAFontColor.
1953         (WebCore::getRGBAFontColor): Moved.
1954         (WebCore::rgbaBackgroundColorInEffect): Added.
1955         (WebCore::EditingStyle::init): Added support for InheritablePropertiesAndBackgroundColorInEffect.
1956         (WebCore::EditingStyle::prepareToApplyAt): Include the effective background color at the given position.
1957         Also remove the background color property when the effective background color is equal to the background
1958         color property (in terms of RGBA value) of the editing style.
1959         (WebCore::hasTransparentBackgroundColor): Moved from Editor class.
1960         (WebCore::backgroundColorInEffect): Extracted from Editor::selectionStartCSSPropertyValue.
1961         * editing/EditingStyle.h: Added prototypes for hasTransparentBackgroundColor and backgroundColorInEffect.
1962         * editing/Editor.cpp:
1963         (WebCore::Editor::selectionStartCSSPropertyValue): Calls backgroundColorInEffect.
1964         * editing/Editor.h: Removed hasTransparentBackgroundColor.
1965         * editing/markup.cpp:
1966         (WebCore::isElementPresentational): Reverted r85090 and r84311.
1967         (WebCore::createMarkup): Include the background color in effect when computing the editing style.
1968
1969 2011-05-23  Roland Steiner  <rolandsteiner@chromium.org>
1970
1971         Reviewed by Dimitri Glazkov.
1972
1973         Update node list cache count on the containing TreeScope rather than the Document
1974         https://bugs.webkit.org/show_bug.cgi?id=59983
1975
1976         Change code to call add/removeNodeListCache() and hasNodeListCaches() on the proper tree scope.
1977         Move updating of the node list cache count from setDocument() to setTreeScopeRecursively().
1978         Make setDocument() and setDocumentRecursively() private.
1979
1980         No new tests. (refactoring)
1981
1982         * dom/ContainerNode.cpp:
1983         (WebCore::ContainerNode::childrenChanged):
1984         * dom/Node.cpp:
1985         (WebCore::Node::~Node):
1986         (WebCore::Node::setDocument):
1987         (WebCore::Node::setTreeScopeRecursively):
1988         (WebCore::Node::childNodes):
1989         (WebCore::Node::registerDynamicNodeList):
1990         (WebCore::Node::unregisterDynamicNodeList):
1991         (WebCore::Node::notifyLocalNodeListsAttributeChanged):
1992         (WebCore::Node::notifyLocalNodeListsChildrenChanged):
1993         (WebCore::Node::getElementsByTagName):
1994         (WebCore::Node::getElementsByTagNameNS):
1995         (WebCore::Node::getElementsByName):
1996         (WebCore::Node::getElementsByClassName):
1997         * dom/Node.h:
1998         * html/HTMLFormControlElement.cpp:
1999         (WebCore::HTMLFormControlElement::labels):
2000
2001 2011-05-23  Yury Semikhatsky  <yurys@chromium.org>
2002
2003         Reviewed by Pavel Feldman.
2004
2005         [Chromium] Web Inspector: provide initial implementation of worker inspector transport
2006         https://bugs.webkit.org/show_bug.cgi?id=60267
2007
2008         All methods of WorkerContextInspectorProxy are inlined in WorkerContextProxy and
2009         the class itself is removed. Messages from worker inspector to page inspector
2010         are sent by means of WorkerReportingProxy.
2011
2012         * GNUmakefile.list.am:
2013         * WebCore.gypi:
2014         * WebCore.vcproj/WebCore.vcproj:
2015         * WebCore.xcodeproj/project.pbxproj:
2016         * inspector/InspectorWorkerAgent.cpp:
2017         (WebCore::InspectorWorkerAgent::WorkerFrontendChannel::WorkerFrontendChannel):
2018         (WebCore::InspectorWorkerAgent::WorkerFrontendChannel::proxy):
2019         (WebCore::InspectorWorkerAgent::WorkerFrontendChannel::dispatchMessageFromWorker):
2020         (WebCore::InspectorWorkerAgent::sendMessageToWorker):
2021         (WebCore::InspectorWorkerAgent::didStartWorkerContext):
2022         * inspector/InspectorWorkerAgent.h:
2023         * inspector/WorkerInspectorController.cpp:
2024         (WebCore::WorkerInspectorController::connectFrontend):
2025         (WebCore::WorkerInspectorController::disconnectFrontend):
2026         * inspector/WorkerInspectorController.h:
2027         * workers/DefaultSharedWorkerRepository.cpp:
2028         (WebCore::SharedWorkerProxy::postMessageToPageInspector):
2029         * workers/WorkerContextInspectorProxy.h: Removed.
2030         * workers/WorkerContextProxy.h:
2031         (WebCore::WorkerContextProxy::PageInspector::~PageInspector):
2032         (WebCore::WorkerContextProxy::connectToInspector):
2033         (WebCore::WorkerContextProxy::disconnectFromInspector):
2034         (WebCore::WorkerContextProxy::sendMessageToInspector):
2035         * workers/WorkerMessagingProxy.cpp:
2036         (WebCore::WorkerMessagingProxy::postMessageToPageInspector):
2037         * workers/WorkerMessagingProxy.h:
2038         * workers/WorkerReportingProxy.h:
2039
2040 2011-05-23  Sheriff Bot  <webkit.review.bot@gmail.com>
2041
2042         Unreviewed, rolling out r87070.
2043         http://trac.webkit.org/changeset/87070
2044         https://bugs.webkit.org/show_bug.cgi?id=61285
2045
2046         broke resource-parameters.html on win, weird failures on wk2
2047         (Requested by caseq on #webkit).
2048
2049         * inspector/front-end/HAREntry.js:
2050         (WebInspector.HAREntry.prototype.build):
2051         (WebInspector.HAREntry.prototype._buildRequest):
2052         (WebInspector.HAREntry.prototype._buildResponse):
2053         (WebInspector.HAREntry.prototype._buildContent):
2054         (WebInspector.HAREntry.prototype._buildCookie):
2055         (WebInspector.HAREntry.prototype._interval):
2056         (WebInspector.HARLog.prototype.build):
2057         * inspector/front-end/Resource.js:
2058         (WebInspector.Resource.prototype.set requestHeaders):
2059         (WebInspector.Resource.prototype.get requestHeadersText):
2060         (WebInspector.Resource.prototype.set requestHeadersText):
2061         (WebInspector.Resource.prototype.get requestHeadersSize):
2062         (WebInspector.Resource.prototype.set responseHeaders):
2063         (WebInspector.Resource.prototype.get responseHeadersText):
2064         (WebInspector.Resource.prototype.set responseHeadersText):
2065         (WebInspector.Resource.prototype.get responseHeadersSize):
2066         (WebInspector.Resource.prototype._headersSize):
2067
2068 2011-05-18  Pavel Podivilov  <podivilov@chromium.org>
2069
2070         Reviewed by Yury Semikhatsky.
2071
2072         Web Inspector: source mapping for pretty-printed scripts is sometimes inaccurate after indented comments.
2073         https://bugs.webkit.org/show_bug.cgi?id=61037
2074
2075         * inspector/front-end/JavaScriptFormatter.js:
2076         (FormattedContentBuilder.prototype.addToken):
2077         (FormattedContentBuilder.prototype._addComment):
2078         (FormattedContentBuilder.prototype._addText):
2079         (FormattedContentBuilder.prototype._addMappingIfNeeded):
2080
2081 2011-05-23  Mike West  <mkwst@chromium.org>
2082
2083         Reviewed by Yury Semikhatsky.
2084
2085         Web Inspector: Missing fields in HAR
2086         https://bugs.webkit.org/show_bug.cgi?id=58127
2087         
2088         Specifically, this patch adds:
2089         - entry.request.httpVersion
2090         - entry.request.headersSize
2091         - entry.request.bodySize
2092         - entry.response.httpVersion
2093         - entry.response.headersSize
2094         - entry.response.bodySize
2095         - entry.response.content.compression
2096         
2097         Tests: http/tests/inspector/resource-har-conversion.html
2098                http/tests/inspector/resource-har-headers.html
2099                http/tests/inspector/resource-parameters.html
2100                http/tests/inspector/network/network-size.html
2101
2102         * inspector/front-end/HAREntry.js:
2103         (WebInspector.HAREntry.prototype.build):
2104         (WebInspector.HAREntry.prototype._buildRequest):
2105         (WebInspector.HAREntry.prototype._buildResponse):
2106         (WebInspector.HAREntry.prototype._buildContent):
2107         (WebInspector.HAREntry.prototype._buildCookie):
2108         (WebInspector.HAREntry.prototype._interval):
2109         (WebInspector.HAREntry.prototype.get requestBodySize):
2110         (WebInspector.HAREntry.prototype.get responseBodySize):
2111         (WebInspector.HAREntry.prototype.get responseCompression):
2112         (WebInspector.HARLog.prototype.build):
2113         * inspector/front-end/Resource.js:
2114         (WebInspector.Resource.prototype.set requestHeaders):
2115         (WebInspector.Resource.prototype.get requestHeadersText):
2116         (WebInspector.Resource.prototype.set requestHeadersText):
2117         (WebInspector.Resource.prototype.get requestHeadersSize):
2118         (WebInspector.Resource.prototype.get requestHttpVersion):
2119         (WebInspector.Resource.prototype.set responseHeaders):
2120         (WebInspector.Resource.prototype.get responseHeadersText):
2121         (WebInspector.Resource.prototype.set responseHeadersText):
2122         (WebInspector.Resource.prototype.get responseHeadersSize):
2123         (WebInspector.Resource.prototype.get responseHttpVersion):
2124
2125 2011-05-23  Andrey Kosyakov  <caseq@chromium.org>
2126
2127         Reviewed by Yury Semikhatsky.
2128
2129         Web Inspector: keyboard shortcut panel is 1px too short
2130         https://bugs.webkit.org/show_bug.cgi?id=61242
2131
2132         Fixed bottom margin of attached helpscreen so it's glued to status bar.
2133
2134         * inspector/front-end/helpScreen.css:
2135         (body.attached .help-window-outer):
2136
2137 2011-05-23  Kent Tamura  <tkent@chromium.org>
2138
2139         Reviewed by Dimitri Glazkov.
2140
2141         Change text-based <input> types to the new shadow DOM model
2142         https://bugs.webkit.org/show_bug.cgi?id=54179
2143
2144         By this change, text field inputs and textareas have one extra
2145         shadow node at the root of shadow trees.
2146         e.g. Before the change:
2147           <textarea> --(shadow-connection)-- <div> -- ...
2148         After the change:
2149           <textarea> --(shadow-connection)-- {#shadow-root} -- <div> -- ...
2150
2151         The goals of this change are
2152         - Change to the new shadow DOM model, and
2153         - Minimize the patch size.
2154
2155         We should use shadowPseudoId() in the new shadow DOM model, but the
2156         shadow elements in this patch don't use it in order to reduce the patch
2157         size.
2158
2159         Note: This is a re-landing for r87014 with a small fix of
2160         Element::removeShadowRoot().
2161         
2162         * css/html.css:
2163         (input::-webkit-inner-spin-button):
2164          Add vertical-align in order to avoid the button affect the baseline.
2165         (input::-webkit-outer-spin-button): ditto.
2166         (input::-webkit-input-speech-button): ditto.
2167         * dom/Element.cpp:
2168         (WebCore::Element::recalcStyle): Calls styleForRenderer() so that a
2169          subclass of Element can override it.
2170         (WebCore::Element::remvoeShadowRoot):
2171          Fix a wrong parameter for willRemoveDOMNode().
2172         (WebCore::Element::isSpellCheckingEnabled):
2173          Handle ShadowRoot, which is not an Element.
2174         * dom/Node.cpp:
2175           Add utility functions for editing code.
2176         (WebCore::Node::nonBoundaryShadowTreeRootNode):
2177         (WebCore::Node::nonShadowBoundaryParentNode):
2178         * dom/Node.h: Declare them.
2179         * dom/Position.cpp:
2180          - Add some assertions about ShadowRoot
2181          - Replace parentNode() with nonShadowBoundaryParentNode()
2182         Because input/textarea shadow structures are changed.
2183         (WebCore::Position::Position):
2184         (WebCore::Position::containerNode):
2185         (WebCore::Position::parentAnchoredEquivalent):
2186         (WebCore::Position::previous):
2187         (WebCore::Position::next):
2188         (WebCore::Position::parentEditingBoundary):
2189         (WebCore::Position::atStartOfTree):
2190         (WebCore::Position::atEndOfTree):
2191         * dom/Position.h: ditto.
2192         (WebCore::positionInParentBeforeNode):
2193         (WebCore::positionInParentAfterNode):
2194         * editing/CompositeEditCommand.cpp: ditto.
2195         (WebCore::CompositeEditCommand::insertNodeAfter):
2196         (WebCore::CompositeEditCommand::removeNode):
2197         * editing/Editor.cpp:
2198         (WebCore::Editor::findString): ditto.
2199         * editing/FrameSelection.cpp:
2200         (WebCore::FrameSelection::selectAll): Inline shadowTreeRootNode() calls.
2201         * editing/FrameSelection.h:
2202           Remove shadowTreeRootNode(). It is used only by FrameSelection::selectAll().
2203         * editing/InsertParagraphSeparatorCommand.cpp:
2204         (WebCore::InsertParagraphSeparatorCommand::doApply): Use nonShadowBoundaryParentNode()
2205         * editing/ReplaceSelectionCommand.cpp:
2206         (WebCore::ReplacementFragment::removeNode): ditto.
2207         (WebCore::ReplacementFragment::insertNodeBefore): ditto.
2208         * editing/VisibleSelection.cpp:
2209           Rename shadowTreeRootNode() to nonBoundaryShadowTreeRootNode(), and it reutrns
2210           a child node of ShadowRoot.
2211         (WebCore::VisibleSelection::isAll):
2212         (WebCore::VisibleSelection::adjustSelectionToAvoidCrossingShadowBoundaries):
2213         (WebCore::VisibleSelection::nonBoundaryShadowTreeRootNode):
2214         * editing/VisibleSelection.h: ditto.
2215         * editing/htmlediting.cpp: Add assertions.
2216         (WebCore::visiblePositionBeforeNode):
2217         (WebCore::visiblePositionAfterNode):
2218         * html/HTMLInputElement.cpp:
2219         (WebCore::HTMLInputElement::create): Calls createShadowSubtree().
2220         (WebCore::HTMLInputElement::createShadowSubtree):
2221           Calls InputType::createShadowSubTree().
2222         (WebCore::HTMLInputElement::innerTextElement):
2223           Accessor of a shadow node. This is used by RenderTextControlSingleLine.
2224         (WebCore::HTMLInputElement::innerBlockElement): ditto.
2225         (WebCore::HTMLInputElement::innerSpinButtonElement): ditto.
2226         (WebCore::HTMLInputElement::outerSpinButtonElement): ditto.
2227         (WebCore::HTMLInputElement::resultsButtonElement): ditto.
2228         (WebCore::HTMLInputElement::cancelButtonElement): ditto.
2229         (WebCore::HTMLInputElement::speechButtonElement): ditto.
2230         (WebCore::HTMLInputElement::parseMappedAttribute):
2231           Rebuild shadow trees because x-webkit-speech attribute affects it.
2232         * html/HTMLInputElement.h: Add declarations.
2233         * html/HTMLIsIndexElement.cpp:
2234         (WebCore::HTMLIsIndexElement::create): Calls createShadowSubtree().
2235         * html/HTMLTextAreaElement.cpp:
2236         (WebCore::HTMLTextAreaElement::create): Calls createShadowSubtree().
2237         (WebCore::HTMLTextAreaElement::createShadowSubtree): Added.
2238         * html/HTMLTextAreaElement.h: Declare createShadowSubtree().
2239         * html/InputType.h: Add default implementations of accessors.
2240         (WebCore::InputType::innerBlockElement):
2241         (WebCore::InputType::innerTextElement):
2242         (WebCore::InputType::innerSpinButtonElement):
2243         (WebCore::InputType::outerSpinButtonElement):
2244         (WebCore::InputType::resultsButtonElement):
2245         (WebCore::InputType::cancelButtonElement):
2246         (WebCore::InputType::speechButtonElement):
2247         * html/SearchInputType.cpp:
2248         (WebCore::SearchInputType::SearchInputType): Initializes new data members.
2249         (WebCore::SearchInputType::createShadowSubtree):
2250           Moved from RenderTextControlSingleLine.
2251         (WebCore::SearchInputType::destroyShadowSubtree): Clear element references.
2252         * html/SearchInputType.h: Add declarations.
2253         (WebCore::SearchInputType::innerBlockElement):
2254         (WebCore::SearchInputType::resultsButtonElement):
2255         (WebCore::SearchInputType::cancelButtonElement):
2256         * html/TextFieldInputType.cpp:
2257         (WebCore::TextFieldInputType::TextFieldInputType):
2258           Initializes new data members.
2259         (WebCore::TextFieldInputType::createShadowSubtree):
2260           Moved from RenderTextControlSingleLine.
2261         (WebCore::TextFieldInputType::destroyShadowSubtree): Clear element references.
2262         * html/TextFieldInputType.h: Add declarations.
2263         (WebCore::TextFieldInputType::innerTextElement):
2264         (WebCore::TextFieldInputType::innerSpinButtonElement):
2265         (WebCore::TextFieldInputType::outerSpinButtonElement):
2266         (WebCore::TextFieldInputType::speechButtonElement):
2267         (WebCore::TextFieldInputType::setInnerTextElement):
2268         (WebCore::TextFieldInputType::setSpeechButtonElement):
2269         * html/shadow/TextControlInnerElements.cpp:
2270         (WebCore::TextControlInnerElement::TextControlInnerElement):
2271           Remove shadowParent parameter. It is unnecessary because we switch to
2272           new shadow model.
2273         (WebCore::TextControlInnerElement::create):
2274           Change the parameter type to Document.
2275         (WebCore::TextControlInnerElement::styleForRenderer):
2276           Override this in order to set style by
2277           RenderTextControlSingleLine::createInnerBlockStyle().
2278         (WebCore::TextControlInnerTextElement::TextControlInnerTextElement):
2279           Remove shadowParent parameter.
2280           Inherit HTMLDivElement, not TextControlInnerElement.
2281         (WebCore::TextControlInnerTextElement::create): Remove shadowParent parameter.
2282         (WebCore::TextControlInnerTextElement::styleForRenderer):
2283           Override this in order to set style by
2284           RenderTextControlSingleLine::createInnerTextStyle().
2285         (WebCore::SearchFieldResultsButtonElement::SearchFieldResultsButtonElement):
2286           Inherit HTMLDivElement, not TextControlInnerElement.
2287         (WebCore::SearchFieldResultsButtonElement::styleForRenderer):
2288           Override this in order to set style by
2289           RenderTextControlSingleLine::createResultButtonStyle().
2290         (WebCore::SearchFieldCancelButtonElement::SearchFieldCancelButtonElement):
2291           Inherit HTMLDivElement, not TextControlInnerElement.
2292         (WebCore::SearchFieldCancelButtonElement::styleForRenderer):
2293           Override this in order to set style by
2294           RenderTextControlSingleLine::createCancelButtonStyle().
2295         (WebCore::SearchFieldCancelButtonElement::detach):
2296           Update for the parent class change.
2297         (WebCore::SpinButtonElement::SpinButtonElement):
2298           - Change the parameter type: shadowParent -> Document
2299           - Add the inner flag
2300           - Inherit HTMLDivElement, not TextControlInnerElement.
2301         (WebCore::SpinButtonElement::createInner): Introduce a new factory
2302           method to hide a bool parameter of the constructor.
2303         (WebCore::SpinButtonElement::createOuter): ditto.
2304         (WebCore::SpinButtonElement::styleForRenderer):
2305           Override this in order to set style by
2306           RenderTextControlSingleLine::createInnerSpinButtonStyle() or
2307           createOuterSpinButtonStyle().
2308         (WebCore::SpinButtonElement::detach): Update for the parent class change.
2309         (WebCore::SpinButtonElement::setHovered): ditto.
2310         (WebCore::InputFieldSpeechButtonElement::InputFieldSpeechButtonElement):
2311           - Change the parameter type: shadowParent -> Document
2312           - Inherit HTMLDivElement, not TextControlInnerElement.
2313           - Do not register this as a speech input listener here.
2314         (WebCore::InputFieldSpeechButtonElement::create):
2315           Update for the parameter change.
2316         (WebCore::InputFieldSpeechButtonElement::defaultEventHandler):
2317           Do not handle click event if listener registration is not done.
2318         (WebCore::InputFieldSpeechButtonElement::attach):
2319           Register this as a speech input listener.
2320         (WebCore::InputFieldSpeechButtonElement::detach):
2321           Update for the parent class change.
2322         (WebCore::InputFieldSpeechButtonElement::styleForRenderer):
2323           Override this in order to set style by
2324           RenderTextControlSingleLine::createSpeechButtonStyle().
2325         * html/shadow/TextControlInnerElements.h:
2326         (WebCore::TextControlInnerTextElement::isMouseFocusable):
2327           Add this because the class is not a subclass of TextControllInnerElement.
2328         (WebCore::SearchFieldResultsButtonElement::isMouseFocusable): ditto.
2329         (WebCore::SearchFieldCancelButtonElement::isMouseFocusable): ditto.
2330         (WebCore::SpinButtonElement::isMouseFocusable): ditto.
2331         (WebCore::InputFieldSpeechButtonElement::isMouseFocusable): ditto.
2332         * rendering/RenderTextControl.cpp:
2333         (WebCore::RenderTextControl::~RenderTextControl): Remove unnecessary code.
2334         (WebCore::RenderTextControl::styleDidChange):
2335           innerTextElement can have no renderer.
2336           Explicitly call setNeedsStyleRecals() for innerTextElement. It is
2337           needed for LayoutTests/editing/selection/select-across-readonly-input-*.html.
2338         (WebCore::RenderTextControl::textBlockWidth): Member data -> function
2339         (WebCore::RenderTextControl::updateFromElement): ditto.
2340         (WebCore::RenderTextControl::setInnerTextValue): ditto.
2341         (WebCore::RenderTextControl::hasVisibleTextArea): ditto.
2342         (WebCore::RenderTextControl::isSelectableElement): ditto.
2343         (WebCore::RenderTextControl::selection): ditto.
2344         (WebCore::RenderTextControl::visiblePositionForIndex): ditto.
2345         (WebCore::RenderTextControl::indexForVisiblePosition): ditto.
2346         (WebCore::RenderTextControl::text): ditto.
2347         (WebCore::RenderTextControl::textWithHardLineBreaks): ditto.
2348         (WebCore::RenderTextControl::computeLogicalHeight): ditto.
2349         (WebCore::RenderTextControl::hitInnerTextElement): ditto.
2350         (WebCore::RenderTextControl::forwardEvent): ditto.
2351         (WebCore::RenderTextControl::computePreferredLogicalWidths): ditto.
2352         * rendering/RenderTextControl.h:
2353           - Make m_innerText virtual function.
2354           - Make createInnerTextStyle() public in order that
2355             TextControlInnerElements can call it.
2356         * rendering/RenderTextControlMultiLine.cpp:
2357         (WebCore::RenderTextControlMultiLine::innerTextElement): Added.
2358         (WebCore::RenderTextControlMultiLine::updateFromElement):
2359           Remove unnecessary createSubtreeIfNeeded() call.
2360         * rendering/RenderTextControlMultiLine.h: Add a declaration.
2361         * rendering/RenderTextControlSingleLine.cpp:
2362         (WebCore::RenderTextControlSingleLine::~RenderTextControlSingleLine):
2363           Remove unnecessary code.
2364         (WebCore::RenderTextControlSingleLine::innerTextElement): Added.
2365         (WebCore::RenderTextControlSingleLine::innerBlockElement): Added.
2366         (WebCore::RenderTextControlSingleLine::innerSpinButtonElement): Added.
2367         (WebCore::RenderTextControlSingleLine::outerSpinButtonElement): Added.
2368         (WebCore::RenderTextControlSingleLine::resultsButtonElement): Added.
2369         (WebCore::RenderTextControlSingleLine::cancelButtonElement): Added.
2370         (WebCore::RenderTextControlSingleLine::speechButtonElement): Added.
2371         (WebCore::RenderTextControlSingleLine::textBaseStyle): Data member -> function
2372         (WebCore::RenderTextControlSingleLine::subtreeHasChanged): ditto.
2373         (WebCore::RenderTextControlSingleLine::layout): ditto.
2374         (WebCore::RenderTextControlSingleLine::nodeAtPoint): ditto.
2375         (WebCore::RenderTextControlSingleLine::forwardEvent): ditto.
2376         (WebCore::RenderTextControlSingleLine::styleDidChange): ditto.
2377         (WebCore::RenderTextControlSingleLine::hasControlClip): ditto.
2378         (WebCore::RenderTextControlSingleLine::controlClipRect): ditto.
2379         (WebCore::RenderTextControlSingleLine::textBlockWidth): ditto.
2380         (WebCore::RenderTextControlSingleLine::decorationWidthRight): ditto.
2381         (WebCore::RenderTextControlSingleLine::preferredContentWidth): ditto.
2382         (WebCore::RenderTextControlSingleLine::preferredDecorationWidthRight): ditto.
2383         (WebCore::RenderTextControlSingleLine::adjustControlHeightBasedOnLineHeight): ditto.
2384         (WebCore::RenderTextControlSingleLine::updateFromElement):
2385           ditto, and remove unnecessary createSubtreeIfNeeded() call.
2386         (WebCore::RenderTextControlSingleLine::createInnerTextStyle):
2387           Data member -> function
2388         (WebCore::RenderTextControlSingleLine::updateCancelButtonVisibility): ditto.
2389         (WebCore::RenderTextControlSingleLine::clientPaddingLeft): ditto.
2390         (WebCore::RenderTextControlSingleLine::clientPaddingRight): ditto.
2391         (WebCore::RenderTextControlSingleLine::textBlockInsetTop): ditto.
2392         * rendering/RenderTextControlSingleLine.h:
2393           Add declarations, and remove unnecessary data members.
2394
2395 2011-05-19  Vitaly Repeshko  <vitalyr@chromium.org>
2396
2397         Reviewed by Adam Barth.
2398
2399         [V8] Explicitly mark objects with complex GC rules.
2400         https://bugs.webkit.org/show_bug.cgi?id=61131
2401
2402         From the GC point view there are two kinds of objects: the ones
2403         that may participate in object grouping (i.e. their lifetime
2404         depends on other objects) and the ones that never participate in
2405         grouping (independent). V8 added support for marking persistent
2406         handles as independent so that the GC can process the objects they
2407         hold faster. The motivating use case here is typed arrays.
2408
2409         This patch adds V8-specific inherited IDL attribute
2410         V8DependentLifetime to types used in V8GCController, which is
2411         exactly the set of types with object lifetimes depending on other
2412         objects. The handles for the types that are not marked with the
2413         new attribute can be marked as independent and GC-ed faster.
2414
2415         * bindings/scripts/CodeGeneratorV8.pm: Added proccessing of the new attribute.
2416
2417         Updated test output:
2418         * bindings/scripts/test/V8/V8TestInterface.cpp:
2419         (WebCore::V8TestInterface::wrapSlow):
2420         * bindings/scripts/test/V8/V8TestInterface.h:
2421         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
2422         (WebCore::V8TestMediaQueryListListener::wrapSlow):
2423         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
2424         * bindings/scripts/test/V8/V8TestObj.cpp:
2425         (WebCore::V8TestObj::wrapSlow):
2426         * bindings/scripts/test/V8/V8TestObj.h:
2427         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
2428         (WebCore::V8TestSerializedScriptValueInterface::wrapSlow):
2429         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
2430
2431         Added the new attribute:
2432         * css/CSSRule.idl:
2433         * css/CSSRuleList.idl:
2434         * css/CSSStyleDeclaration.idl:
2435         * css/CSSValue.idl:
2436         * css/StyleSheet.idl:
2437         * css/StyleSheetList.idl:
2438         * dom/DOMImplementation.idl:
2439         * dom/Node.idl:
2440
2441 2011-05-23  Sheriff Bot  <webkit.review.bot@gmail.com>
2442
2443         Unreviewed, rolling out r87014, r87016, and r87017.
2444         http://trac.webkit.org/changeset/87014
2445         http://trac.webkit.org/changeset/87016
2446         http://trac.webkit.org/changeset/87017
2447         https://bugs.webkit.org/show_bug.cgi?id=61266
2448
2449         It made more tests assert (Requested by Ossy on #webkit).
2450
2451         * css/html.css:
2452         (input::-webkit-inner-spin-button):
2453         (input::-webkit-outer-spin-button):
2454         (input::-webkit-input-speech-button):
2455         * dom/Element.cpp:
2456         (WebCore::Element::recalcStyle):
2457         (WebCore::Element::isSpellCheckingEnabled):
2458         * dom/Node.cpp:
2459         * dom/Node.h:
2460         * dom/Position.cpp:
2461         (WebCore::Position::Position):
2462         (WebCore::Position::containerNode):
2463         (WebCore::Position::parentAnchoredEquivalent):
2464         (WebCore::Position::previous):
2465         (WebCore::Position::next):
2466         (WebCore::Position::parentEditingBoundary):
2467         (WebCore::Position::atStartOfTree):
2468         (WebCore::Position::atEndOfTree):
2469         * dom/Position.h:
2470         (WebCore::positionInParentBeforeNode):
2471         (WebCore::positionInParentAfterNode):
2472         * editing/CompositeEditCommand.cpp:
2473         (WebCore::CompositeEditCommand::insertNodeAfter):
2474         (WebCore::CompositeEditCommand::removeNode):
2475         * editing/Editor.cpp:
2476         (WebCore::Editor::findString):
2477         * editing/FrameSelection.cpp:
2478         (WebCore::FrameSelection::selectAll):
2479         * editing/FrameSelection.h:
2480         (WebCore::FrameSelection::shadowTreeRootNode):
2481         * editing/InsertParagraphSeparatorCommand.cpp:
2482         (WebCore::InsertParagraphSeparatorCommand::doApply):
2483         * editing/ReplaceSelectionCommand.cpp:
2484         (WebCore::ReplacementFragment::removeNode):
2485         (WebCore::ReplacementFragment::insertNodeBefore):
2486         * editing/VisibleSelection.cpp:
2487         (WebCore::VisibleSelection::isAll):
2488         (WebCore::VisibleSelection::adjustSelectionToAvoidCrossingShadowBoundaries):
2489         (WebCore::VisibleSelection::shadowTreeRootNode):
2490         * editing/VisibleSelection.h:
2491         * editing/htmlediting.cpp:
2492         (WebCore::visiblePositionBeforeNode):
2493         (WebCore::visiblePositionAfterNode):
2494         * html/HTMLInputElement.cpp:
2495         (WebCore::HTMLInputElement::create):
2496         (WebCore::HTMLInputElement::parseMappedAttribute):
2497         * html/HTMLInputElement.h:
2498         * html/HTMLIsIndexElement.cpp:
2499         (WebCore::HTMLIsIndexElement::create):
2500         * html/HTMLTextAreaElement.cpp:
2501         (WebCore::HTMLTextAreaElement::create):
2502         * html/HTMLTextAreaElement.h:
2503         * html/InputType.h:
2504         * html/SearchInputType.cpp:
2505         * html/SearchInputType.h:
2506         (WebCore::SearchInputType::SearchInputType):
2507         * html/TextFieldInputType.cpp:
2508         * html/TextFieldInputType.h:
2509         (WebCore::TextFieldInputType::TextFieldInputType):
2510         * html/shadow/TextControlInnerElements.cpp:
2511         (WebCore::TextControlInnerElement::TextControlInnerElement):
2512         (WebCore::TextControlInnerElement::create):
2513         (WebCore::TextControlInnerElement::attachInnerElement):
2514         (WebCore::TextControlInnerElement::detach):
2515         (WebCore::TextControlInnerTextElement::TextControlInnerTextElement):
2516         (WebCore::TextControlInnerTextElement::create):
2517         (WebCore::SearchFieldResultsButtonElement::SearchFieldResultsButtonElement):
2518         (WebCore::SearchFieldCancelButtonElement::SearchFieldCancelButtonElement):
2519         (WebCore::SearchFieldCancelButtonElement::detach):
2520         (WebCore::SpinButtonElement::SpinButtonElement):
2521         (WebCore::SpinButtonElement::create):
2522         (WebCore::SpinButtonElement::detach):
2523         (WebCore::SpinButtonElement::setHovered):
2524         (WebCore::InputFieldSpeechButtonElement::InputFieldSpeechButtonElement):
2525         (WebCore::InputFieldSpeechButtonElement::create):
2526         (WebCore::InputFieldSpeechButtonElement::defaultEventHandler):
2527         (WebCore::InputFieldSpeechButtonElement::detach):
2528         * html/shadow/TextControlInnerElements.h:
2529         * rendering/RenderTextControl.cpp:
2530         (WebCore::RenderTextControl::~RenderTextControl):
2531         (WebCore::RenderTextControl::styleDidChange):
2532         (WebCore::RenderTextControl::setInnerTextStyle):
2533         (WebCore::RenderTextControl::createSubtreeIfNeeded):
2534         (WebCore::RenderTextControl::textBlockWidth):
2535         (WebCore::RenderTextControl::updateFromElement):
2536         (WebCore::RenderTextControl::setInnerTextValue):
2537         (WebCore::RenderTextControl::hasVisibleTextArea):
2538         (WebCore::RenderTextControl::isSelectableElement):
2539         (WebCore::RenderTextControl::selection):
2540         (WebCore::RenderTextControl::visiblePositionForIndex):
2541         (WebCore::RenderTextControl::indexForVisiblePosition):
2542         (WebCore::RenderTextControl::text):
2543         (WebCore::RenderTextControl::textWithHardLineBreaks):
2544         (WebCore::RenderTextControl::computeLogicalHeight):
2545         (WebCore::RenderTextControl::hitInnerTextElement):
2546         (WebCore::RenderTextControl::forwardEvent):
2547         (WebCore::RenderTextControl::computePreferredLogicalWidths):
2548         (WebCore::RenderTextControl::innerTextElement):
2549         * rendering/RenderTextControl.h:
2550         * rendering/RenderTextControlMultiLine.cpp:
2551         (WebCore::RenderTextControlMultiLine::updateFromElement):
2552         * rendering/RenderTextControlMultiLine.h:
2553         * rendering/RenderTextControlSingleLine.cpp:
2554         (WebCore::RenderTextControlSingleLine::~RenderTextControlSingleLine):
2555         (WebCore::RenderTextControlSingleLine::textBaseStyle):
2556         (WebCore::RenderTextControlSingleLine::subtreeHasChanged):
2557         (WebCore::RenderTextControlSingleLine::layout):
2558         (WebCore::RenderTextControlSingleLine::nodeAtPoint):
2559         (WebCore::RenderTextControlSingleLine::forwardEvent):
2560         (WebCore::RenderTextControlSingleLine::styleDidChange):
2561         (WebCore::RenderTextControlSingleLine::hasControlClip):
2562         (WebCore::RenderTextControlSingleLine::controlClipRect):
2563         (WebCore::RenderTextControlSingleLine::textBlockWidth):
2564         (WebCore::RenderTextControlSingleLine::decorationWidthRight):
2565         (WebCore::RenderTextControlSingleLine::preferredContentWidth):
2566         (WebCore::RenderTextControlSingleLine::preferredDecorationWidthRight):
2567         (WebCore::RenderTextControlSingleLine::adjustControlHeightBasedOnLineHeight):
2568         (WebCore::RenderTextControlSingleLine::createSubtreeIfNeeded):
2569         (WebCore::RenderTextControlSingleLine::updateFromElement):
2570         (WebCore::RenderTextControlSingleLine::createInnerTextStyle):
2571         (WebCore::RenderTextControlSingleLine::updateCancelButtonVisibility):
2572         (WebCore::RenderTextControlSingleLine::clientPaddingLeft):
2573         (WebCore::RenderTextControlSingleLine::clientPaddingRight):
2574         (WebCore::RenderTextControlSingleLine::textBlockInsetTop):
2575         * rendering/RenderTextControlSingleLine.h:
2576
2577 2011-05-23  Syed Idris Shah  <syed.idris-shah@nokia.com>
2578
2579         Reviewed by Andreas Kling.
2580
2581         GraphicsContext3DInternal object should be called for getAttachedShaders.
2582         [Qt] fast/canvas/webgl/gl-object-get-calls.html crash for Qt based webkit
2583         https://bugs.webkit.org/show_bug.cgi?id=61202 
2584
2585         LayoutTests/fast/canvas/webgl/gl-object-get-calls.html
2586
2587         getAttachedShaders should be called on GraphicsContext3DInternal instance.
2588         It was left out by mistake.
2589
2590         * platform/graphics/qt/GraphicsContext3DQt.cpp: 
2591         (WebCore::GraphicsContext3D::getAttachedShaders): GraphicsContext3DInternal instance should be called.
2592
2593 2011-05-23  Carlos Garcia Campos  <cgarcia@igalia.com>
2594
2595         Unreviewed. Strict PassOwnPtr build fix.
2596
2597         * platform/text/gtk/TextCodecGtk.cpp:
2598         (WebCore::newTextCodecGtk):
2599
2600 2011-05-23  Mikhail Naganov  <mnaganov@chromium.org>
2601
2602         Reviewed by Yury Semikhatsky.
2603
2604         Web Inspector: [Chromium] Show "Please wait" message during initial
2605         heap snapshot processing.
2606         https://bugs.webkit.org/show_bug.cgi?id=61040
2607
2608         * inspector/front-end/DetailedHeapshotView.js:
2609         (WebInspector.HeapSnapshotSortableDataGrid.prototype.sortingChanged.sort):
2610         (WebInspector.HeapSnapshotSortableDataGrid.prototype.sortingChanged):
2611         (WebInspector.DetailedHeapshotView.profileCallback):
2612         (WebInspector.DetailedHeapshotView.setDataSource):
2613         (WebInspector.DetailedHeapshotView):
2614         (WebInspector.DetailedHeapshotView.prototype._changeBase.baseProfileLoaded):
2615         (WebInspector.DetailedHeapshotView.prototype._changeBase.setDataSource):
2616         (WebInspector.DetailedHeapshotView.prototype._changeBase):
2617         (WebInspector.DetailedHeapshotView.prototype._changeView.setDataSource):
2618         (WebInspector.DetailedHeapshotView.prototype._changeView):
2619         * inspector/front-end/PleaseWaitMessage.js:
2620         (WebInspector.PleaseWaitMessage.prototype.showAndWaitFor):
2621
2622 2011-05-23  Adam Barth  <abarth@webkit.org>
2623
2624         Strict PassOwnPtr build fixes.
2625
2626         * platform/gtk/GeolocationServiceGtk.cpp:
2627         (WebCore::GeolocationServiceGtk::create):
2628         * platform/gtk/RenderThemeGtk.cpp:
2629         (WebCore::RenderThemeGtk::adjustSliderTrackStyle):
2630         (WebCore::RenderThemeGtk::adjustSliderThumbStyle):
2631         (WebCore::RenderThemeGtk::adjustProgressBarStyle):
2632
2633 2011-05-22  Adam Barth  <abarth@webkit.org>
2634
2635         Strict PassOwnPtr build fix.
2636
2637         * platform/efl/RenderThemeEfl.cpp:
2638         (WebCore::RenderThemeEfl::adjustProgressBarStyle):
2639
2640 2011-05-22  Andrew Wason  <rectalogic@rectalogic.com>
2641
2642         Reviewed by Benjamin Poulain.
2643
2644         [Qt] Implement toImageData() in QtWebKit Bridge
2645         https://bugs.webkit.org/show_bug.cgi?id=60897
2646
2647         Tests are in WebKit/qt/tests/hybridPixmap
2648
2649         * bridge/qt/qt_pixmapruntime.cpp:
2650         (JSC::Bindings::QtPixmapToImageDataMethod::name):
2651         (JSC::Bindings::QtPixmapToImageDataMethod::invoke):
2652         (JSC::Bindings::QtPixmapToImageDataMethod::copyPixels):
2653         (JSC::Bindings::QtPixmapClass::methodsNamed):
2654         (JSC::Bindings::QtPixmapInstance::getPropertyNames):
2655          Add toImageData() to Qt Bridge, alternative to
2656          assignToHTMLImageElement().
2657
2658 2011-05-22  Dominic Cooney  <dominicc@chromium.org>
2659
2660         Reviewed by Dimitri Glazkov.
2661
2662         When removing a shadow root, also remove it from the render tree.
2663         https://bugs.webkit.org/show_bug.cgi?id=61245
2664
2665         Test: existing fast/dom/shadow/layout-tests-can-access-shadow.html
2666
2667         * dom/Element.cpp:
2668         (WebCore::Element::removeShadowRoot): Call detach if attached.
2669
2670 2011-05-22  Dirk Schulze  <krit@webkit.org>
2671
2672         Reviewed by Nikolas Zimmermann.
2673
2674         Don't do manually style resolution for SVGElements with renderer
2675         https://bugs.webkit.org/show_bug.cgi?id=59176
2676
2677         General clean-up.
2678
2679         Don't resolve style manually, instead ask the RenderObject for its style.
2680
2681         Cleanup svgattrs.in, some SVG element names were accidently listed there as attributes.
2682
2683         No new tests needed. No change of behavior.
2684
2685         * svg/SVGFEDiffuseLightingElement.cpp:
2686         (WebCore::SVGFEDiffuseLightingElement::build):
2687         * svg/SVGFEDropShadowElement.cpp:
2688         (WebCore::SVGFEDropShadowElement::build):
2689         * svg/SVGFEFloodElement.cpp:
2690         (WebCore::SVGFEFloodElement::build):
2691         * svg/SVGFESpecularLightingElement.cpp:
2692         (WebCore::SVGFESpecularLightingElement::build):
2693         * svg/svgattrs.in:
2694
2695 2011-05-21  Dirk Schulze  <krit@webkit.org>
2696
2697         Reviewed by Darin Adler.
2698
2699         REGRESSION(r66731): pointer-events are broken in some cases
2700         https://bugs.webkit.org/show_bug.cgi?id=45467
2701
2702         The SVGSVGElement shouldn't be the target of a mouse event, if its pointer-events attribute is set
2703         to 'none'. This matches the behavior on Firefox where an embedded SVG element is the target of an event,
2704         if none of its childs caught the event. This is the case for all pointer-events other than 'none'.
2705
2706         Tests: svg/custom/pointer-events-on-svg-with-pointer.xhtml
2707                svg/custom/pointer-events-on-svg-without-pointer.xhtml
2708
2709         * rendering/svg/RenderSVGRoot.cpp:
2710         (WebCore::RenderSVGRoot::nodeAtPoint):
2711
2712 2011-05-21  Dan Bernstein  <mitz@apple.com>
2713
2714         Reviewed by Darin Adler.
2715
2716         <rdar://problem/9479926> REGRESSION (r82144): Icon overlaps text in Twitter message dialog
2717         https://bugs.webkit.org/show_bug.cgi?id=61241
2718
2719         Test: fast/block/positioning/start-ignoring-before.html
2720
2721         * rendering/RenderBlockLineLayout.cpp:
2722         (WebCore::TrailingObjects::updateMidpointsForTrailingBoxes): Added a boolean parameter saying
2723         whether to merge the first trailing space with the line break.
2724         (WebCore::RenderBlock::LineBreaker::nextLineBreak): When adding a midpoint behind the current
2725         character, account for trailing positioned objects that occurred after the midpoint by calling
2726         updateMidpointsForTrailingBoxes(), which adds midpoints for them.
2727
2728 2011-05-21  Jeremy Noble  <jer.noble@apple.com>
2729
2730         Reviewed by Eric Carlson.
2731
2732         WebKit2: fix failing fullscreen/full-screen-remove* tests.
2733         https://bugs.webkit.org/show_bug.cgi?id=61027
2734
2735         * dom/Document.cpp:
2736         (WebCore::Document::fullScreenChangeDelayTimerFired): dispatchEvent can be
2737             synchronous, so make sure to check whether the current element is
2738             in the DOM before dispatching.
2739
2740 2011-05-21  Gavin Peters  <gavinp@chromium.org>
2741
2742         Reviewed by Adam Barth.
2743
2744         Add rel type prerender to distinguish prerender from prefetch
2745         https://bugs.webkit.org/show_bug.cgi?id=61079
2746
2747         Chrome right now uses <link rel=prefetch ...> for one of two things,
2748         to warm the cache in the same way as firefox, or to launch a speculative
2749         rendering of a web page, for faster "loading" when the user navigates to it.
2750
2751         This new rel type will let us distinguish the two cases; the rel type prerender
2752         isn't used on the web today, but the Google Web Search example prerendering application
2753         is ready to experiment with it.
2754
2755         Test: fast/dom/HTMLLinkElement/prerender.html
2756
2757         * html/HTMLLinkElement.cpp:
2758         (WebCore::HTMLLinkElement::tokenizeRelAttribute):
2759         (WebCore::HTMLLinkElement::process):
2760         * html/HTMLLinkElement.h:
2761         (WebCore::HTMLLinkElement::RelAttribute::RelAttribute):
2762         * loader/cache/CachedResource.cpp:
2763         (WebCore::defaultPriorityForResourceType):
2764         * loader/cache/CachedResource.h:
2765         (WebCore::CachedResource::isLinkResource):
2766         * loader/cache/CachedResourceLoader.cpp:
2767         (WebCore::createResource):
2768         (WebCore::CachedResourceLoader::requestLinkResource):
2769         (WebCore::CachedResourceLoader::canRequest):
2770         * loader/cache/CachedResourceLoader.h:
2771         * loader/cache/CachedResourceRequest.cpp:
2772         (WebCore::cachedResourceTypeToTargetType):
2773         (WebCore::CachedResourceRequest::load):
2774         * platform/network/ResourceRequestBase.h:
2775
2776 2011-05-21  Emil A Eklund  <eae@chromium.org>
2777
2778         Reviewed by Eric Seidel.
2779
2780         Change RenderLineBoxList::hitTest to use IntPoint
2781         https://bugs.webkit.org/show_bug.cgi?id=61156
2782
2783         Change the RenderLineBoxList hit testing to use IntPoint and clean up the rect calculation.
2784
2785         Covered by existing tests.
2786
2787         * rendering/RenderBlock.cpp:
2788         (WebCore::RenderBlock::hitTestContents):
2789         * rendering/RenderInline.cpp:
2790         (WebCore::RenderInline::nodeAtPoint):
2791         * rendering/RenderLineBoxList.cpp:
2792         (WebCore::RenderLineBoxList::hitTest):
2793         * rendering/RenderLineBoxList.h:
2794
2795 2011-05-21  Emil A Eklund  <eae@chromium.org>
2796
2797         Reviewed by Eric Seidel.
2798
2799         Change HitTestResult to use IntPoint
2800         https://bugs.webkit.org/show_bug.cgi?id=61230
2801
2802         Covered by existing tests.
2803
2804         * rendering/EllipsisBox.cpp:
2805         (WebCore::EllipsisBox::nodeAtPoint):
2806         * rendering/HitTestResult.cpp:
2807         (WebCore::HitTestResult::addNodeToRectBasedTestResult):
2808         * rendering/HitTestResult.h:
2809         (WebCore::HitTestResult::isRectBasedTest):
2810         * rendering/InlineFlowBox.cpp:
2811         (WebCore::InlineFlowBox::nodeAtPoint):
2812         * rendering/InlineTextBox.cpp:
2813         (WebCore::InlineTextBox::nodeAtPoint):
2814         * rendering/RenderBlock.cpp:
2815         (WebCore::RenderBlock::nodeAtPoint):
2816         (WebCore::RenderBlock::hitTestColumns):
2817         * rendering/RenderBox.cpp:
2818         (WebCore::RenderBox::nodeAtPoint):
2819         * rendering/RenderTable.cpp:
2820         (WebCore::RenderTable::nodeAtPoint):
2821         * rendering/svg/RenderSVGRoot.cpp:
2822         (WebCore::RenderSVGRoot::nodeAtPoint):
2823
2824 2011-05-21  Jochen Eisinger  <jochen@chromium.org>
2825
2826         Reviewed by Darin Fisher.
2827
2828         [chromium] add extraData field to resource requests
2829         https://bugs.webkit.org/show_bug.cgi?id=61033
2830
2831         * platform/network/chromium/ResourceRequest.h:
2832         (WebCore::ResourceRequest::ExtraData::~ExtraData):
2833         (WebCore::ResourceRequest::extraData):
2834         (WebCore::ResourceRequest::setExtraData):
2835
2836 2011-05-21  Kent Tamura  <tkent@chromium.org>
2837
2838         Reviewed by Dimitri Glazkov.
2839
2840         Change text-based <input> types to the new shadow DOM model
2841         https://bugs.webkit.org/show_bug.cgi?id=54179
2842
2843         By this change, text field inputs and textareas have one extra
2844         shadow node at the root of shadow trees.
2845         e.g. Before the change:
2846           <textarea> --(shadow-connection)-- <div> -- ...
2847         After the change:
2848           <textarea> --(shadow-connection)-- {#shadow-root} -- <div> -- ...
2849
2850         The goals of this change are
2851         - Change to the new shadow DOM model, and
2852         - Minimize the patch size.
2853
2854         We should use shadowPseudoId() in the new shadow DOM model, but the
2855         shadow elements in this patch don't use it in order to reduce the patch
2856         size.
2857
2858         * css/html.css:
2859         (input::-webkit-inner-spin-button):
2860          Add vertical-align in order to avoid the button affect the baseline.
2861         (input::-webkit-outer-spin-button): ditto.
2862         (input::-webkit-input-speech-button): ditto.
2863         * dom/Element.cpp:
2864         (WebCore::Element::recalcStyle): Calls styleForRenderer() so that a
2865          subclass of Element can override it.
2866         (WebCore::Element::isSpellCheckingEnabled):
2867         Handle ShadowRoot, which is not an Element.
2868         * dom/Node.cpp:
2869           Add utility functions for editing code.
2870         (WebCore::Node::nonBoundaryShadowTreeRootNode):
2871         (WebCore::Node::nonShadowBoundaryParentNode):
2872         * dom/Node.h: Declare them.
2873         * dom/Position.cpp:
2874          - Add some assertions about ShadowRoot
2875          - Replace parentNode() with nonShadowBoundaryParentNode()
2876         Because input/textarea shadow structures are changed.
2877         (WebCore::Position::Position):
2878         (WebCore::Position::containerNode):
2879         (WebCore::Position::parentAnchoredEquivalent):
2880         (WebCore::Position::previous):
2881         (WebCore::Position::next):
2882         (WebCore::Position::parentEditingBoundary):
2883         (WebCore::Position::atStartOfTree):
2884         (WebCore::Position::atEndOfTree):
2885         * dom/Position.h: ditto.
2886         (WebCore::positionInParentBeforeNode):
2887         (WebCore::positionInParentAfterNode):
2888         * editing/CompositeEditCommand.cpp: ditto.
2889         (WebCore::CompositeEditCommand::insertNodeAfter):
2890         (WebCore::CompositeEditCommand::removeNode):
2891         * editing/Editor.cpp:
2892         (WebCore::Editor::findString): ditto.
2893         * editing/FrameSelection.cpp:
2894         (WebCore::FrameSelection::selectAll): Inline shadowTreeRootNode() calls.
2895         * editing/FrameSelection.h:
2896           Remove shadowTreeRootNode(). It is used only by FrameSelection::selectAll().
2897         * editing/InsertParagraphSeparatorCommand.cpp:
2898         (WebCore::InsertParagraphSeparatorCommand::doApply): Use nonShadowBoundaryParentNode()
2899         * editing/ReplaceSelectionCommand.cpp:
2900         (WebCore::ReplacementFragment::removeNode): ditto.
2901         (WebCore::ReplacementFragment::insertNodeBefore): ditto.
2902         * editing/VisibleSelection.cpp:
2903           Rename shadowTreeRootNode() to nonBoundaryShadowTreeRootNode(), and it reutrns
2904           a child node of ShadowRoot.
2905         (WebCore::VisibleSelection::isAll):
2906         (WebCore::VisibleSelection::adjustSelectionToAvoidCrossingShadowBoundaries):
2907         (WebCore::VisibleSelection::nonBoundaryShadowTreeRootNode):
2908         * editing/VisibleSelection.h: ditto.
2909         * editing/htmlediting.cpp: Add assertions.
2910         (WebCore::visiblePositionBeforeNode):
2911         (WebCore::visiblePositionAfterNode):
2912         * html/HTMLInputElement.cpp:
2913         (WebCore::HTMLInputElement::create): Calls createShadowSubtree().
2914         (WebCore::HTMLInputElement::createShadowSubtree):
2915           Calls InputType::createShadowSubTree().
2916         (WebCore::HTMLInputElement::innerTextElement):
2917           Accessor of a shadow node. This is used by RenderTextControlSingleLine.
2918         (WebCore::HTMLInputElement::innerBlockElement): ditto.
2919         (WebCore::HTMLInputElement::innerSpinButtonElement): ditto.
2920         (WebCore::HTMLInputElement::outerSpinButtonElement): ditto.
2921         (WebCore::HTMLInputElement::resultsButtonElement): ditto.
2922         (WebCore::HTMLInputElement::cancelButtonElement): ditto.
2923         (WebCore::HTMLInputElement::speechButtonElement): ditto.
2924         (WebCore::HTMLInputElement::parseMappedAttribute):
2925           Rebuild shadow trees because x-webkit-speech attribute affects it.
2926         * html/HTMLInputElement.h: Add declarations.
2927         * html/HTMLIsIndexElement.cpp:
2928         (WebCore::HTMLIsIndexElement::create): Calls createShadowSubtree().
2929         * html/HTMLTextAreaElement.cpp:
2930         (WebCore::HTMLTextAreaElement::create): Calls createShadowSubtree().
2931         (WebCore::HTMLTextAreaElement::createShadowSubtree): Added.
2932         * html/HTMLTextAreaElement.h: Declare createShadowSubtree().
2933         * html/InputType.h: Add default implementations of accessors.
2934         (WebCore::InputType::innerBlockElement):
2935         (WebCore::InputType::innerTextElement):
2936         (WebCore::InputType::innerSpinButtonElement):
2937         (WebCore::InputType::outerSpinButtonElement):
2938         (WebCore::InputType::resultsButtonElement):
2939         (WebCore::InputType::cancelButtonElement):
2940         (WebCore::InputType::speechButtonElement):
2941         * html/SearchInputType.cpp:
2942         (WebCore::SearchInputType::SearchInputType): Initializes new data members.
2943         (WebCore::SearchInputType::createShadowSubtree):
2944           Moved from RenderTextControlSingleLine.
2945         (WebCore::SearchInputType::destroyShadowSubtree): Clear element references.
2946         * html/SearchInputType.h: Add declarations.
2947         (WebCore::SearchInputType::innerBlockElement):
2948         (WebCore::SearchInputType::resultsButtonElement):
2949         (WebCore::SearchInputType::cancelButtonElement):
2950         * html/TextFieldInputType.cpp:
2951         (WebCore::TextFieldInputType::TextFieldInputType):
2952           Initializes new data members.
2953         (WebCore::TextFieldInputType::createShadowSubtree):
2954           Moved from RenderTextControlSingleLine.
2955         (WebCore::TextFieldInputType::destroyShadowSubtree): Clear element references.
2956         * html/TextFieldInputType.h: Add declarations.
2957         (WebCore::TextFieldInputType::innerTextElement):
2958         (WebCore::TextFieldInputType::innerSpinButtonElement):
2959         (WebCore::TextFieldInputType::outerSpinButtonElement):
2960         (WebCore::TextFieldInputType::speechButtonElement):
2961         (WebCore::TextFieldInputType::setInnerTextElement):
2962         (WebCore::TextFieldInputType::setSpeechButtonElement):
2963         * html/shadow/TextControlInnerElements.cpp:
2964         (WebCore::TextControlInnerElement::TextControlInnerElement):
2965           Remove shadowParent parameter. It is unnecessary because we switch to
2966           new shadow model.
2967         (WebCore::TextControlInnerElement::create):
2968           Change the parameter type to Document.
2969         (WebCore::TextControlInnerElement::styleForRenderer):
2970           Override this in order to set style by
2971           RenderTextControlSingleLine::createInnerBlockStyle().
2972         (WebCore::TextControlInnerTextElement::TextControlInnerTextElement):
2973           Remove shadowParent parameter.
2974           Inherit HTMLDivElement, not TextControlInnerElement.
2975         (WebCore::TextControlInnerTextElement::create): Remove shadowParent parameter.
2976         (WebCore::TextControlInnerTextElement::styleForRenderer):
2977           Override this in order to set style by
2978           RenderTextControlSingleLine::createInnerTextStyle().
2979         (WebCore::SearchFieldResultsButtonElement::SearchFieldResultsButtonElement):
2980           Inherit HTMLDivElement, not TextControlInnerElement.
2981         (WebCore::SearchFieldResultsButtonElement::styleForRenderer):
2982           Override this in order to set style by
2983           RenderTextControlSingleLine::createResultButtonStyle().
2984         (WebCore::SearchFieldCancelButtonElement::SearchFieldCancelButtonElement):
2985           Inherit HTMLDivElement, not TextControlInnerElement.
2986         (WebCore::SearchFieldCancelButtonElement::styleForRenderer):
2987           Override this in order to set style by
2988           RenderTextControlSingleLine::createCancelButtonStyle().
2989         (WebCore::SearchFieldCancelButtonElement::detach):
2990           Update for the parent class change.
2991         (WebCore::SpinButtonElement::SpinButtonElement):
2992           - Change the parameter type: shadowParent -> Document
2993           - Add the inner flag
2994           - Inherit HTMLDivElement, not TextControlInnerElement.
2995         (WebCore::SpinButtonElement::createInner): Introduce a new factory
2996           method to hide a bool parameter of the constructor.
2997         (WebCore::SpinButtonElement::createOuter): ditto.
2998         (WebCore::SpinButtonElement::styleForRenderer):
2999           Override this in order to set style by
3000           RenderTextControlSingleLine::createInnerSpinButtonStyle() or
3001           createOuterSpinButtonStyle().
3002         (WebCore::SpinButtonElement::detach): Update for the parent class change.
3003         (WebCore::SpinButtonElement::setHovered): ditto.
3004         (WebCore::InputFieldSpeechButtonElement::InputFieldSpeechButtonElement):
3005           - Change the parameter type: shadowParent -> Document
3006           - Inherit HTMLDivElement, not TextControlInnerElement.
3007           - Do not register this as a speech input listener here.
3008         (WebCore::InputFieldSpeechButtonElement::create):
3009           Update for the parameter change.
3010         (WebCore::InputFieldSpeechButtonElement::defaultEventHandler):
3011           Do not handle click event if listener registration is not done.
3012         (WebCore::InputFieldSpeechButtonElement::attach):
3013           Register this as a speech input listener.
3014         (WebCore::InputFieldSpeechButtonElement::detach):
3015           Update for the parent class change.
3016         (WebCore::InputFieldSpeechButtonElement::styleForRenderer):
3017           Override this in order to set style by
3018           RenderTextControlSingleLine::createSpeechButtonStyle().
3019         * html/shadow/TextControlInnerElements.h:
3020         (WebCore::TextControlInnerTextElement::isMouseFocusable):
3021           Add this because the class is not a subclass of TextControllInnerElement.
3022         (WebCore::SearchFieldResultsButtonElement::isMouseFocusable): ditto.
3023         (WebCore::SearchFieldCancelButtonElement::isMouseFocusable): ditto.
3024         (WebCore::SpinButtonElement::isMouseFocusable): ditto.
3025         (WebCore::InputFieldSpeechButtonElement::isMouseFocusable): ditto.
3026         * rendering/RenderTextControl.cpp:
3027         (WebCore::RenderTextControl::~RenderTextControl): Remove unnecessary code.
3028         (WebCore::RenderTextControl::styleDidChange):
3029           innerTextElement can have no renderer.
3030           Explicitly call setNeedsStyleRecals() for innerTextElement. It is
3031           needed for LayoutTests/editing/selection/select-across-readonly-input-*.html.
3032         (WebCore::RenderTextControl::textBlockWidth): Member data -> function
3033         (WebCore::RenderTextControl::updateFromElement): ditto.
3034         (WebCore::RenderTextControl::setInnerTextValue): ditto.
3035         (WebCore::RenderTextControl::hasVisibleTextArea): ditto.
3036         (WebCore::RenderTextControl::isSelectableElement): ditto.
3037         (WebCore::RenderTextControl::selection): ditto.
3038         (WebCore::RenderTextControl::visiblePositionForIndex): ditto.
3039         (WebCore::RenderTextControl::indexForVisiblePosition): ditto.
3040         (WebCore::RenderTextControl::text): ditto.
3041         (WebCore::RenderTextControl::textWithHardLineBreaks): ditto.
3042         (WebCore::RenderTextControl::computeLogicalHeight): ditto.
3043         (WebCore::RenderTextControl::hitInnerTextElement): ditto.
3044         (WebCore::RenderTextControl::forwardEvent): ditto.
3045         (WebCore::RenderTextControl::computePreferredLogicalWidths): ditto.
3046         * rendering/RenderTextControl.h:
3047           - Make m_innerText virtual function.
3048           - Make createInnerTextStyle() public in order that
3049             TextControlInnerElements can call it.
3050         * rendering/RenderTextControlMultiLine.cpp:
3051         (WebCore::RenderTextControlMultiLine::innerTextElement): Added.
3052         (WebCore::RenderTextControlMultiLine::updateFromElement):
3053           Remove unnecessary createSubtreeIfNeeded() call.
3054         * rendering/RenderTextControlMultiLine.h: Add a declaration.
3055         * rendering/RenderTextControlSingleLine.cpp:
3056         (WebCore::RenderTextControlSingleLine::~RenderTextControlSingleLine):
3057           Remove unnecessary code.
3058         (WebCore::RenderTextControlSingleLine::innerTextElement): Added.
3059         (WebCore::RenderTextControlSingleLine::innerBlockElement): Added.
3060         (WebCore::RenderTextControlSingleLine::innerSpinButtonElement): Added.
3061         (WebCore::RenderTextControlSingleLine::outerSpinButtonElement): Added.
3062         (WebCore::RenderTextControlSingleLine::resultsButtonElement): Added.
3063         (WebCore::RenderTextControlSingleLine::cancelButtonElement): Added.
3064         (WebCore::RenderTextControlSingleLine::speechButtonElement): Added.
3065         (WebCore::RenderTextControlSingleLine::textBaseStyle): Data member -> function
3066         (WebCore::RenderTextControlSingleLine::subtreeHasChanged): ditto.
3067         (WebCore::RenderTextControlSingleLine::layout): ditto.
3068         (WebCore::RenderTextControlSingleLine::nodeAtPoint): ditto.
3069         (WebCore::RenderTextControlSingleLine::forwardEvent): ditto.
3070         (WebCore::RenderTextControlSingleLine::styleDidChange): ditto.
3071         (WebCore::RenderTextControlSingleLine::hasControlClip): ditto.
3072         (WebCore::RenderTextControlSingleLine::controlClipRect): ditto.
3073         (WebCore::RenderTextControlSingleLine::textBlockWidth): ditto.
3074         (WebCore::RenderTextControlSingleLine::decorationWidthRight): ditto.
3075         (WebCore::RenderTextControlSingleLine::preferredContentWidth): ditto.
3076         (WebCore::RenderTextControlSingleLine::preferredDecorationWidthRight): ditto.
3077         (WebCore::RenderTextControlSingleLine::adjustControlHeightBasedOnLineHeight): ditto.
3078         (WebCore::RenderTextControlSingleLine::updateFromElement):
3079           ditto, and remove unnecessary createSubtreeIfNeeded() call.
3080         (WebCore::RenderTextControlSingleLine::createInnerTextStyle):
3081           Data member -> function
3082         (WebCore::RenderTextControlSingleLine::updateCancelButtonVisibility): ditto.
3083         (WebCore::RenderTextControlSingleLine::clientPaddingLeft): ditto.
3084         (WebCore::RenderTextControlSingleLine::clientPaddingRight): ditto.
3085         (WebCore::RenderTextControlSingleLine::textBlockInsetTop): ditto.
3086         * rendering/RenderTextControlSingleLine.h:
3087           Add declarations, and remove unnecessary data members.
3088
3089 2011-05-21  Chris Rogers  <crogers@google.com>
3090
3091         Reviewed by Kenneth Russell.
3092
3093         AudioBufferSourceNode noteOff() method must respect scheduling time
3094         https://bugs.webkit.org/show_bug.cgi?id=61226
3095
3096         No new tests since audio API is not yet implemented.
3097
3098         * webaudio/AudioBufferSourceNode.cpp:
3099         (WebCore::AudioBufferSourceNode::AudioBufferSourceNode):
3100         (WebCore::AudioBufferSourceNode::process):
3101         (WebCore::AudioBufferSourceNode::provideInput):
3102         (WebCore::AudioBufferSourceNode::finish):
3103         (WebCore::AudioBufferSourceNode::noteGrainOn):
3104         (WebCore::AudioBufferSourceNode::noteOff):
3105         * webaudio/AudioBufferSourceNode.h:
3106
3107 2011-05-20  Dirk Schulze  <krit@webkit.org>
3108
3109         Reviewed by Nikolas Zimmermann.
3110
3111         Share more code in PathTraversalState
3112         https://bugs.webkit.org/show_bug.cgi?id=61238
3113
3114         Share more code between SVGPathTraversalStateBuilder and Path in PathTraversalState.
3115
3116         No change in functionality, so no new tests.
3117
3118         * platform/graphics/Path.cpp:
3119         (WebCore::pathLengthApplierFunction):
3120         * platform/graphics/PathTraversalState.cpp:
3121         (WebCore::PathTraversalState::processSegment):
3122         * platform/graphics/PathTraversalState.h:
3123         * svg/SVGPathTraversalStateBuilder.cpp:
3124         (WebCore::SVGPathTraversalStateBuilder::continueConsuming):
3125
3126 2011-05-21  Nikolas Zimmermann  <nzimmermann@rim.com>
3127
3128         Reviewed by Rob Buis.
3129
3130         SVG svgAttributeChanged/synchronizeProperty/parseMappedAttribute should be optimized
3131         https://bugs.webkit.org/show_bug.cgi?id=61183
3132
3133         Example: rect.x.baseVal.value = 100;
3134         What happens: SVGRectElement::svgAttributeChanged(const QualifiedName& attrName) is invoked with "SVGNames::rectAttr" as parameter.
3135
3136         void SVGRectElement::svgAttributeChanged(const QualifiedName& attrName)
3137         {
3138             SVGStyledTransformableElement::svgAttributeChanged(attrName);
3139             // Handle my own attribute changes...
3140         }
3141
3142         Currently we always traverse the base class hierarchy, when invoking svgAttributeChanged. Every svgAttributeChanged call from a class
3143         like SVGRectElement has to reach the base class SVGStyledElement::svgAttributeChanged, as it handles invalidation of the instances of
3144         an element. Say that a <rect> is referenced by a <use> and we change the 'x' attribute of the <rect>, then SVGStyledElement::svgAttributeChanged,
3145         calls SVGElementInstance::invalidateAllInstancesOfElement(this), so that the <use> can rebuild its shadow tree...
3146         That's the only reason all svgAttributeChanged implementations call the base class immediately, so SVGStyledElement is always reached.
3147
3148         Switch to a more efficient pattern, by providing a "bool isSupportedAttribute(const QualifiedName&);" function for all SVG*Elements.
3149         It contains all attributes the particular SVG*Element class handles (but not its parent classes attributes). For example SVGRectElement
3150         contains x/y/width/height/rx/ry attributes, and the ones from SVGTests/SVGLangSpace/SVGExternalResourcesRequired (xml:space/lang, etc.),
3151         but not eg. transform as that's handled by the parent class SVGStyledTransformableElement.
3152
3153         void SVGRectElement::svgAttributeChanged(const QualifiedName& attrName)
3154         {
3155             if (!isSupportedAttribute.contains(attrName)) {
3156                 SVGStyledTransformableElement::svgAttributeChanged(attrName);
3157                 return;
3158             }
3159
3160             // When we get here, we know for sure it's one of our attributes that has changed.
3161             // Note for eg. SVGNames::transformAttr, the call from SVGRectElement::svgAttributeChanged, would be immediately forwarded to the base class, which handles transformAttr changes)
3162
3163             if (attrName == SVGNames::xAttr) { do_work(); return; }
3164             if (attrName == SVGNames::yAttr) { do_work(); return; }
3165             ...
3166             // Assure that we handled all properties we claim support for in "isSupportedAttribute()".
3167             ASSERT_NOT_REACHED();
3168         }
3169
3170         Exactly the same pattern can be applied to synchronizeProperty and parseMappedAttribute to speed them up as well.
3171
3172         Add "SVGElementInstance::InvalidationGuard guard(this)" statements in all svgAttributeChanged implementations, that calls invalidateAllInstancesOfElement(this)
3173         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
3174         need to rely on the base class svgAttributeChanged() call to do it.
3175        
3176         It's a slight overal performance progression.
3177
3178         * svg/SVGAElement.cpp:
3179         (WebCore::SVGAElement::isSupportedAttribute):
3180         (WebCore::SVGAElement::parseMappedAttribute):
3181         (WebCore::SVGAElement::svgAttributeChanged):
3182         (WebCore::SVGAElement::synchronizeProperty):
3183         * svg/SVGAElement.h:
3184         * svg/SVGAnimateMotionElement.cpp:
3185         (WebCore::SVGAnimateMotionElement::isSupportedAttribute):
3186         (WebCore::SVGAnimateMotionElement::parseMappedAttribute):
3187         * svg/SVGAnimateMotionElement.h:
3188         * svg/SVGAnimateTransformElement.cpp:
3189         (WebCore::SVGAnimateTransformElement::isSupportedAttribute):
3190         (WebCore::SVGAnimateTransformElement::parseMappedAttribute):
3191         * svg/SVGAnimateTransformElement.h:
3192         * svg/SVGAnimationElement.cpp:
3193         (WebCore::SVGAnimationElement::isSupportedAttribute):
3194         (WebCore::SVGAnimationElement::parseMappedAttribute):
3195         * svg/SVGAnimationElement.h:
3196         * svg/SVGCircleElement.cpp:
3197         (WebCore::SVGCircleElement::isSupportedAttribute):
3198         (WebCore::SVGCircleElement::parseMappedAttribute):
3199         (WebCore::SVGCircleElement::svgAttributeChanged):
3200         (WebCore::SVGCircleElement::synchronizeProperty):
3201         * svg/SVGCircleElement.h:
3202         * svg/SVGClipPathElement.cpp:
3203         (WebCore::SVGClipPathElement::isSupportedAttribute):
3204         (WebCore::SVGClipPathElement::parseMappedAttribute):
3205         (WebCore::SVGClipPathElement::svgAttributeChanged):
3206         (WebCore::SVGClipPathElement::synchronizeProperty):
3207         * svg/SVGClipPathElement.h:
3208         * svg/SVGComponentTransferFunctionElement.cpp:
3209         (WebCore::SVGComponentTransferFunctionElement::isSupportedAttribute):
3210         (WebCore::SVGComponentTransferFunctionElement::parseMappedAttribute):
3211         (WebCore::SVGComponentTransferFunctionElement::synchronizeProperty):
3212         * svg/SVGComponentTransferFunctionElement.h:
3213         * svg/SVGCursorElement.cpp:
3214         (WebCore::SVGCursorElement::isSupportedAttribute):
3215         (WebCore::SVGCursorElement::parseMappedAttribute):
3216         (WebCore::SVGCursorElement::svgAttributeChanged):
3217         (WebCore::SVGCursorElement::synchronizeProperty):
3218         * svg/SVGCursorElement.h:
3219         * svg/SVGElementInstance.h:
3220         (WebCore::SVGElementInstance::InvalidationGuard::InvalidationGuard):
3221         (WebCore::SVGElementInstance::InvalidationGuard::~InvalidationGuard):
3222         * svg/SVGEllipseElement.cpp:
3223         (WebCore::SVGEllipseElement::isSupportedAttribute):
3224         (WebCore::SVGEllipseElement::parseMappedAttribute):
3225         (WebCore::SVGEllipseElement::svgAttributeChanged):
3226         (WebCore::SVGEllipseElement::synchronizeProperty):
3227         * svg/SVGEllipseElement.h:
3228         * svg/SVGExternalResourcesRequired.cpp:
3229         (WebCore::SVGExternalResourcesRequired::addSupportedAttributes):
3230         * svg/SVGExternalResourcesRequired.h:
3231         * svg/SVGFEBlendElement.cpp:
3232         (WebCore::SVGFEBlendElement::isSupportedAttribute):
3233         (WebCore::SVGFEBlendElement::parseMappedAttribute):
3234         (WebCore::SVGFEBlendElement::svgAttributeChanged):
3235         (WebCore::SVGFEBlendElement::synchronizeProperty):
3236         * svg/SVGFEBlendElement.h:
3237         * svg/SVGFEColorMatrixElement.cpp:
3238         (WebCore::SVGFEColorMatrixElement::isSupportedAttribute):
3239         (WebCore::SVGFEColorMatrixElement::parseMappedAttribute):
3240         (WebCore::SVGFEColorMatrixElement::svgAttributeChanged):
3241         (WebCore::SVGFEColorMatrixElement::synchronizeProperty):
3242         * svg/SVGFEColorMatrixElement.h:
3243         * svg/SVGFEComponentTransferElement.cpp:
3244         (WebCore::SVGFEComponentTransferElement::isSupportedAttribute):
3245         (WebCore::SVGFEComponentTransferElement::parseMappedAttribute):
3246         (WebCore::SVGFEComponentTransferElement::synchronizeProperty):
3247         * svg/SVGFEComponentTransferElement.h:
3248         * svg/SVGFECompositeElement.cpp:
3249         (WebCore::SVGFECompositeElement::isSupportedAttribute):
3250         (WebCore::SVGFECompositeElement::parseMappedAttribute):
3251         (WebCore::SVGFECompositeElement::svgAttributeChanged):
3252         (WebCore::SVGFECompositeElement::synchronizeProperty):
3253         * svg/SVGFECompositeElement.h:
3254         * svg/SVGFEConvolveMatrixElement.cpp:
3255         (WebCore::SVGFEConvolveMatrixElement::isSupportedAttribute):
3256         (WebCore::SVGFEConvolveMatrixElement::parseMappedAttribute):
3257         (WebCore::SVGFEConvolveMatrixElement::svgAttributeChanged):
3258         (WebCore::SVGFEConvolveMatrixElement::synchronizeProperty):
3259         * svg/SVGFEConvolveMatrixElement.h:
3260         * svg/SVGFEDiffuseLightingElement.cpp:
3261         (WebCore::SVGFEDiffuseLightingElement::isSupportedAttribute):
3262         (WebCore::SVGFEDiffuseLightingElement::parseMappedAttribute):
3263         (WebCore::SVGFEDiffuseLightingElement::svgAttributeChanged):
3264         (WebCore::SVGFEDiffuseLightingElement::synchronizeProperty):
3265         * svg/SVGFEDiffuseLightingElement.h:
3266         * svg/SVGFEDisplacementMapElement.cpp:
3267         (WebCore::SVGFEDisplacementMapElement::isSupportedAttribute):
3268         (WebCore::SVGFEDisplacementMapElement::parseMappedAttribute):
3269         (WebCore::SVGFEDisplacementMapElement::svgAttributeChanged):
3270         (WebCore::SVGFEDisplacementMapElement::synchronizeProperty):
3271         * svg/SVGFEDisplacementMapElement.h:
3272         * svg/SVGFEDropShadowElement.cpp:
3273         (WebCore::SVGFEDropShadowElement::isSupportedAttribute):
3274         (WebCore::SVGFEDropShadowElement::parseMappedAttribute):
3275         (WebCore::SVGFEDropShadowElement::svgAttributeChanged):
3276         (WebCore::SVGFEDropShadowElement::synchronizeProperty):
3277         * svg/SVGFEDropShadowElement.h:
3278         * svg/SVGFEGaussianBlurElement.cpp:
3279         (WebCore::SVGFEGaussianBlurElement::isSupportedAttribute):
3280         (WebCore::SVGFEGaussianBlurElement::parseMappedAttribute):
3281         (WebCore::SVGFEGaussianBlurElement::svgAttributeChanged):
3282         (WebCore::SVGFEGaussianBlurElement::synchronizeProperty):
3283         * svg/SVGFEGaussianBlurElement.h:
3284         * svg/SVGFEImageElement.cpp:
3285         (WebCore::SVGFEImageElement::isSupportedAttribute):
3286         (WebCore::SVGFEImageElement::parseMappedAttribute):
3287         (WebCore::SVGFEImageElement::svgAttributeChanged):
3288         (WebCore::SVGFEImageElement::synchronizeProperty):
3289         * svg/SVGFEImageElement.h:
3290         * svg/SVGFELightElement.cpp:
3291         (WebCore::SVGFELightElement::isSupportedAttribute):
3292         (WebCore::SVGFELightElement::parseMappedAttribute):
3293         (WebCore::SVGFELightElement::svgAttributeChanged):
3294         (WebCore::SVGFELightElement::synchronizeProperty):
3295         * svg/SVGFELightElement.h:
3296         * svg/SVGFEMergeNodeElement.cpp:
3297         (WebCore::SVGFEMergeNodeElement::isSupportedAttribute):
3298         (WebCore::SVGFEMergeNodeElement::parseMappedAttribute):
3299         (WebCore::SVGFEMergeNodeElement::svgAttributeChanged):
3300         (WebCore::SVGFEMergeNodeElement::synchronizeProperty):
3301         * svg/SVGFEMergeNodeElement.h:
3302         * svg/SVGFEMorphologyElement.cpp:
3303         (WebCore::SVGFEMorphologyElement::isSupportedAttribute):
3304         (WebCore::SVGFEMorphologyElement::parseMappedAttribute):
3305         (WebCore::SVGFEMorphologyElement::svgAttributeChanged):
3306         (WebCore::SVGFEMorphologyElement::synchronizeProperty):
3307         * svg/SVGFEMorphologyElement.h:
3308         * svg/SVGFEOffsetElement.cpp:
3309         (WebCore::SVGFEOffsetElement::isSupportedAttribute):
3310         (WebCore::SVGFEOffsetElement::parseMappedAttribute):
3311         (WebCore::SVGFEOffsetElement::svgAttributeChanged):
3312         (WebCore::SVGFEOffsetElement::synchronizeProperty):
3313         * svg/SVGFEOffsetElement.h:
3314         * svg/SVGFESpecularLightingElement.cpp:
3315         (WebCore::SVGFESpecularLightingElement::isSupportedAttribute):
3316         (WebCore::SVGFESpecularLightingElement::parseMappedAttribute):
3317         (WebCore::SVGFESpecularLightingElement::svgAttributeChanged):
3318         (WebCore::SVGFESpecularLightingElement::synchronizeProperty):
3319         * svg/SVGFESpecularLightingElement.h:
3320         * svg/SVGFETileElement.cpp:
3321         (WebCore::SVGFETileElement::isSupportedAttribute):
3322         (WebCore::SVGFETileElement::parseMappedAttribute):
3323         (WebCore::SVGFETileElement::svgAttributeChanged):
3324         (WebCore::SVGFETileElement::synchronizeProperty):
3325         * svg/SVGFETileElement.h:
3326         * svg/SVGFETurbulenceElement.cpp:
3327         (WebCore::SVGFETurbulenceElement::isSupportedAttribute):
3328         (WebCore::SVGFETurbulenceElement::parseMappedAttribute):
3329         (WebCore::SVGFETurbulenceElement::svgAttributeChanged):
3330         (WebCore::SVGFETurbulenceElement::synchronizeProperty):
3331         * svg/SVGFETurbulenceElement.h:
3332         * svg/SVGFilterElement.cpp:
3333         (WebCore::SVGFilterElement::isSupportedAttribute):
3334         (WebCore::SVGFilterElement::parseMappedAttribute):
3335         (WebCore::SVGFilterElement::svgAttributeChanged):
3336         (WebCore::SVGFilterElement::synchronizeProperty):
3337         * svg/SVGFilterElement.h:
3338         * svg/SVGFilterPrimitiveStandardAttributes.cpp:
3339         (WebCore::SVGFilterPrimitiveStandardAttributes::isSupportedAttribute):
3340         (WebCore::SVGFilterPrimitiveStandardAttributes::parseMappedAttribute):
3341         (WebCore::SVGFilterPrimitiveStandardAttributes::svgAttributeChanged):
3342         (WebCore::SVGFilterPrimitiveStandardAttributes::synchronizeProperty):
3343         * svg/SVGFilterPrimitiveStandardAttributes.h:
3344         * svg/SVGFitToViewBox.cpp:
3345         (WebCore::SVGFitToViewBox::parseMappedAttribute):
3346         (WebCore::SVGFitToViewBox::synchronizeProperties):
3347         (WebCore::SVGFitToViewBox::addSupportedAttributes):
3348         * svg/SVGFitToViewBox.h:
3349         * svg/SVGForeignObjectElement.cpp:
3350         (WebCore::SVGForeignObjectElement::isSupportedAttribute):
3351         (WebCore::SVGForeignObjectElement::parseMappedAttribute):
3352         (WebCore::SVGForeignObjectElement::svgAttributeChanged):
3353         (WebCore::SVGForeignObjectElement::synchronizeProperty):
3354         * svg/SVGForeignObjectElement.h:
3355         * svg/SVGGElement.cpp:
3356         (WebCore::SVGGElement::isSupportedAttribute):
3357         (WebCore::SVGGElement::parseMappedAttribute):
3358         (WebCore::SVGGElement::svgAttributeChanged):
3359         (WebCore::SVGGElement::synchronizeProperty):
3360         * svg/SVGGElement.h:
3361         * svg/SVGGradientElement.cpp:
3362         (WebCore::SVGGradientElement::isSupportedAttribute):
3363         (WebCore::SVGGradientElement::parseMappedAttribute):
3364         (WebCore::SVGGradientElement::svgAttributeChanged):
3365         (WebCore::SVGGradientElement::synchronizeProperty):
3366         * svg/SVGGradientElement.h:
3367         * svg/SVGImageElement.cpp:
3368         (WebCore::SVGImageElement::isSupportedAttribute):
3369         (WebCore::SVGImageElement::parseMappedAttribute):
3370         (WebCore::SVGImageElement::svgAttributeChanged):
3371         (WebCore::SVGImageElement::synchronizeProperty):
3372         * svg/SVGImageElement.h:
3373         * svg/SVGLangSpace.cpp:
3374         (WebCore::SVGLangSpace::addSupportedAttributes):
3375         * svg/SVGLangSpace.h:
3376         * svg/SVGLineElement.cpp:
3377         (WebCore::SVGLineElement::isSupportedAttribute):
3378         (WebCore::SVGLineElement::parseMappedAttribute):
3379         (WebCore::SVGLineElement::svgAttributeChanged):
3380         (WebCore::SVGLineElement::synchronizeProperty):
3381         * svg/SVGLineElement.h:
3382         * svg/SVGLinearGradientElement.cpp:
3383         (WebCore::SVGLinearGradientElement::isSupportedAttribute):
3384         (WebCore::SVGLinearGradientElement::parseMappedAttribute):
3385         (WebCore::SVGLinearGradientElement::svgAttributeChanged):
3386         (WebCore::SVGLinearGradientElement::synchronizeProperty):
3387         * svg/SVGLinearGradientElement.h:
3388         * svg/SVGMPathElement.cpp:
3389         (WebCore::SVGMPathElement::isSupportedAttribute):
3390         (WebCore::SVGMPathElement::parseMappedAttribute):
3391         (WebCore::SVGMPathElement::synchronizeProperty):
3392         * svg/SVGMPathElement.h:
3393         * svg/SVGMarkerElement.cpp:
3394         (WebCore::SVGMarkerElement::isSupportedAttribute):
3395         (WebCore::SVGMarkerElement::parseMappedAttribute):
3396         (WebCore::SVGMarkerElement::svgAttributeChanged):
3397         (WebCore::SVGMarkerElement::synchronizeProperty):
3398         * svg/SVGMarkerElement.h:
3399         * svg/SVGMaskElement.cpp:
3400         (WebCore::SVGMaskElement::isSupportedAttribute):
3401         (WebCore::SVGMaskElement::parseMappedAttribute):
3402         (WebCore::SVGMaskElement::svgAttributeChanged):
3403         (WebCore::SVGMaskElement::synchronizeProperty):