2010-06-28 Xan Lopez <xlopez@igalia.com>
[WebKit-https.git] / WebCore / ChangeLog
1 2010-06-28  Xan Lopez  <xlopez@igalia.com>
2
3         Reviewed by Gustavo Noronha.
4
5         [GTK] Add support for GTK+3
6         https://bugs.webkit.org/show_bug.cgi?id=41253
7
8         Adapt build system for 3.x support.
9
10         * GNUmakefile.am:
11
12 2010-06-28  Yury Semikhatsky  <yurys@chromium.org>
13
14         Reviewed by Pavel Feldman.
15
16         [v8] Web Inspector: properties of scope variables are flattened while on a breakpoint.
17         https://bugs.webkit.org/show_bug.cgi?id=41214
18
19         Test: inspector/debugger-proto-property.html
20
21         * inspector/front-end/InjectedScript.js:
22         (injectedScriptConstructor): object proxy with non-empty path cannot be scope proxy.
23
24 2010-06-28  MORITA Hajime  <morrita@google.com>
25
26         Unreviewed attempt to fix windows build.
27
28         * page/DOMWindow.idl:
29
30 2010-06-22  MORITA Hajime  <morrita@google.com>
31
32         Reviewed by Kent Tamura.
33
34         <progress> should be styled with -webkit-progress-bar-value
35         https://bugs.webkit.org/show_bug.cgi?id=40823
36
37         Fixed to peek styles of the shadow node pseudo class to fallback
38         to non-styled painting.
39         
40         * css/html.css: 
41         (progress): Added defaul background-color.
42         (progress::-webkit-progress-bar-value): Added defaul background-color.
43         * rendering/RenderProgress.cpp:
44         (WebCore::RenderProgress::shouldHaveParts):
45         (WebCore::RenderProgress::updatePartsState):
46
47         Test: fast/dom/HTMLProgressElement/progress-bar-value-pseudo-element.html
48         
49 2010-06-28  Csaba Osztrogon√°c  <ossy@webkit.org>
50
51         Reviewed by Kent Tamura.
52
53         GCC suggest parentheses around && within ||
54         https://bugs.webkit.org/show_bug.cgi?id=41245
55
56         * rendering/RenderBlock.cpp:
57         (WebCore::RenderBlock::paintChildren):
58
59 2010-06-28  Adam Barth  <abarth@webkit.org>
60
61         Reviewed by Eric Seidel.
62
63         Don't dump contents of <script> elements in LayoutTests
64         https://bugs.webkit.org/show_bug.cgi?id=41277
65
66         Apparently we need to tell each element when we start and stop parsing
67         its children.  If we don't do this, we see the contents of every script
68         and style element in dumpAsText LayoutTests.  (This patch is *well*
69         covered by LayoutTests.)
70
71         * html/HTMLTreeBuilder.h:
72         (WebCore::HTMLTreeBuilder::ElementStack::pop):
73         (WebCore::HTMLTreeBuilder::ElementStack::push):
74
75 2010-06-28  Eric Seidel  <eric@webkit.org>
76
77         Reviewed by Adam Barth.
78
79         Make it possible to test the new HTML5 TreeBuilder
80         https://bugs.webkit.org/show_bug.cgi?id=41276
81
82         Adam was concerned that someone might make their port
83         depend on this setting (I guess we had some trouble with that
84         with the HTML5Parser setting), so I littered the code with warnings.
85
86         test-html5-parser now tests this code path.
87
88         * html/HTMLTreeBuilder.cpp:
89         (WebCore::HTMLTreeBuilder::HTMLTreeBuilder):
90         (WebCore::HTMLTreeBuilder::constructTreeFromToken):
91         (WebCore::HTMLTreeBuilder::finished):
92         * page/Settings.cpp:
93         (WebCore::Settings::Settings):
94         * page/Settings.h:
95         (WebCore::Settings::setHTML5TreeBuilderEnabled_DO_NOT_USE):
96         (WebCore::Settings::html5TreeBuilderEnabled):
97
98 2010-06-28  Adam Barth  <abarth@webkit.org>
99
100         Reviewed by Eric Seidel.
101
102         Make the html5lib runner.html not assert
103         https://bugs.webkit.org/show_bug.cgi?id=41273
104
105         This patch gets us closer to being able to run the parser tests.  We
106         still don't get parsing correct, but at least we don't assert.  :)
107
108         * html/HTMLTreeBuilder.cpp:
109         (WebCore::HTMLTreeBuilder::processStartTag):
110         (WebCore::HTMLTreeBuilder::processComment):
111         (WebCore::HTMLTreeBuilder::insertCommentOnDocument):
112         * html/HTMLTreeBuilder.h:
113
114 2010-06-28  Eric Seidel  <eric@webkit.org>
115
116         Unreviewed.  Attempt to fix Chromium and Qt builders.
117
118         Add a new baseclass for XML, HTML and Text DocumentParsers to clean up DocumentParser call sites
119         https://bugs.webkit.org/show_bug.cgi?id=41141
120
121         No functional changes, thus no tests.
122
123         * bindings/v8/ScriptController.cpp:
124         (WebCore::ScriptController::eventHandlerLineNumber):
125         (WebCore::ScriptController::eventHandlerColumnNumber):
126         * dom/XMLDocumentParserQt.cpp:
127         (WebCore::XMLDocumentParser::XMLDocumentParser):
128         (WebCore::XMLDocumentParser::stopParsing):
129
130 2010-06-28  Adam Barth  <abarth@webkit.org>
131
132         Reviewed by Eric Seidel.
133
134         Add support for parsing attributes
135         https://bugs.webkit.org/show_bug.cgi?id=41272
136
137         This patch lets use parse the following document:
138
139         <script src="data:text/javascript,alert('PASS')"></script>
140
141         * html/HTMLTreeBuilder.cpp:
142         (WebCore::HTMLTreeBuilder::constructTreeFromToken):
143         (WebCore::HTMLTreeBuilder::insertHTMLStartTagBeforeHTML):
144         (WebCore::HTMLTreeBuilder::insertScriptElement):
145         (WebCore::HTMLTreeBuilder::createElement):
146
147 2010-06-28  Eric Seidel  <eric@webkit.org>
148
149         Reviewed by Darin Adler.
150
151         Add a new baseclass for XML, HTML and Text DocumentParsers to clean up DocumentParser call sites
152         https://bugs.webkit.org/show_bug.cgi?id=41141
153
154         By splitting ScriptableDocumentParser and DecodedDataDocumentParser
155         out from DocumentParser we've made the DocumentParser and
156         RawDataDocumentParser classes simpler.
157
158         No functional change, thus no tests.
159
160         * Android.mk:
161         * CMakeLists.txt:
162         * GNUmakefile.am:
163         * WebCore.gypi:
164         * WebCore.pro:
165         * WebCore.vcproj/WebCore.vcproj:
166         * WebCore.xcodeproj/project.pbxproj:
167         * bindings/js/ScriptController.cpp:
168         (WebCore::ScriptController::eventHandlerLineNumber):
169         * css/CSSStyleSheet.cpp:
170         (WebCore::CSSStyleSheet::checkLoaded):
171         * dom/Document.cpp:
172         (WebCore::Document::scriptableDocumentParser):
173         (WebCore::Document::open):
174         (WebCore::Document::implicitOpen):
175         (WebCore::Document::implicitClose):
176         (WebCore::Document::removePendingSheet):
177         * dom/Document.h:
178         (WebCore::Document::parser):
179         * dom/DocumentParser.cpp:
180         (WebCore::DocumentParser::DocumentParser):
181         * dom/DocumentParser.h:
182         (WebCore::DocumentParser::asScriptableDocumentParser):
183         * dom/RawDataDocumentParser.h:
184         (WebCore::RawDataDocumentParser::finishWasCalled):
185         * dom/ScriptableDocumentParser.cpp: Copied from WebCore/html/HTMLEntityParser.h.
186         (WebCore::ScriptableDocumentParser::ScriptableDocumentParser):
187         * dom/ScriptableDocumentParser.h: Added.
188         (WebCore::ScriptableDocumentParser::isExecutingScript):
189         (WebCore::ScriptableDocumentParser::executeScriptsWaitingForStylesheets):
190         (WebCore::ScriptableDocumentParser::xssAuditor):
191         (WebCore::ScriptableDocumentParser::setXSSAuditor):
192         (WebCore::ScriptableDocumentParser::processingContentWrittenByScript):
193         (WebCore::ScriptableDocumentParser::asScriptableDocumentParser):
194         * dom/ViewportArguments.cpp:
195         (WebCore::parserLineNumber):
196         (WebCore::reportViewportWarning):
197         * dom/XMLDocumentParser.h:
198         * dom/XMLDocumentParserLibxml2.cpp:
199         (WebCore::XMLDocumentParser::XMLDocumentParser):
200         * html/HTMLDocumentParser.cpp:
201         (WebCore::HTMLDocumentParser::HTMLDocumentParser):
202         (WebCore::HTMLDocumentParser::shouldLoadExternalScriptFromSrc):
203         * html/HTMLDocumentParser.h:
204         * html/LegacyHTMLDocumentParser.cpp:
205         (WebCore::LegacyHTMLDocumentParser::LegacyHTMLDocumentParser):
206         (WebCore::LegacyHTMLDocumentParser::parseTag):
207         * html/LegacyHTMLDocumentParser.h:
208         (WebCore::LegacyHTMLDocumentParser::processingContentWrittenByScript):
209         * html/LegacyHTMLTreeBuilder.cpp:
210         (WebCore::LegacyHTMLTreeBuilder::reportErrorToConsole):
211         * loader/DocumentLoader.cpp:
212         * loader/DocumentWriter.cpp:
213         * loader/TextDocument.cpp:
214         (WebCore::TextDocumentParser::TextDocumentParser):
215         (WebCore::TextDocumentParser::finish):
216         * svg/SVGDocumentExtensions.cpp:
217         (WebCore::parserLineNumber):
218         (WebCore::reportMessage):
219         (WebCore::SVGDocumentExtensions::reportWarning):
220         (WebCore::SVGDocumentExtensions::reportError):
221
222 2010-06-27  Steve Falkenburg  <sfalken@apple.com>
223
224         Reviewed by Mark Rowe.
225
226         WebKit2 build exceeds address space on 32-bit Windows builders
227         https://bugs.webkit.org/show_bug.cgi?id=41270
228
229         Add all-in-one file for render-related SVG files.
230         Clean up other all-in-one files by adding missing files, excluding matching files from the vcproj.
231         Reduces release WebCore.lib size by 10% (160MB).
232
233         * DerivedSources.cpp:
234         * WebCore.vcproj/WebCore.vcproj:
235         * bindings/js/JSBindingsAllInOne.cpp:
236         * html/HTMLElementsAllInOne.cpp:
237         * rendering/RenderSVGAllInOne.cpp: Added.
238
239 2010-06-27  Adam Barth  <abarth@webkit.org>
240
241         Reviewed by Eric Seidel.
242
243         Sketch out the InBodyMode for the tree builder
244         https://bugs.webkit.org/show_bug.cgi?id=41271
245
246         This gives us some basic behavior for the InBodyMode.  I've implemented
247         some of the easier logic.  The more complicated logic will be in
248         subsequent patches.
249
250         * html/HTMLTreeBuilder.cpp:
251         (WebCore::HTMLTreeBuilder::processStartTag):
252         (WebCore::HTMLTreeBuilder::processEndTag):
253         (WebCore::HTMLTreeBuilder::insertFormatingElement):
254         (WebCore::HTMLTreeBuilder::reconstructTheActiveFormattingElements):
255         * html/HTMLTreeBuilder.h:
256
257 2010-06-25  Yuzo Fujishima  <yuzo@google.com>
258
259         Reviewed by Shinichiro Hamaji.
260
261         Improve default value handling for page format properties.
262
263         Default page size and orientation have been hard-coded.
264         Instead, pass default page size and margins to
265         WebCore::Document::pageSizeAndMarginsInPixels to handle auto page size
266         and margins specified as percentages.
267         Return margins instead of page rect.
268
269         https://bugs.webkit.org/show_bug.cgi?id=41150
270
271         * WebCore.base.exp:
272         * css/CSSStyleSelector.cpp:
273         (WebCore::CSSStyleSelector::applyPageSizeProperty):
274         (WebCore::CSSStyleSelector::pageSizeFromName):
275         * css/html.css:
276         (@page):
277         * dom/Document.cpp:
278         (WebCore::Document::pageSizeAndMarginsInPixels):
279         * dom/Document.h:
280         * page/PrintContext.cpp:
281         (WebCore::PrintContext::pageProperty):
282         (WebCore::PrintContext::pageSizeAndMarginsInPixels):
283         * page/PrintContext.h:
284         * rendering/style/RenderStyle.h:
285         (WebCore::InheritedFlags::pageSizeType):
286         (WebCore::InheritedFlags::setPageSizeType):
287         (WebCore::InheritedFlags::resetPageSizeType):
288         * rendering/style/StyleRareNonInheritedData.cpp:
289         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
290         (WebCore::StyleRareNonInheritedData::operator==):
291         * rendering/style/StyleRareNonInheritedData.h:
292         (WebCore::):
293
294 2010-06-27  Adam Barth  <abarth@webkit.org>
295
296         Reviewed by Eric Seidel.
297
298         Clean up some loose ends in HTML5 tree builder
299         https://bugs.webkit.org/show_bug.cgi?id=41265
300
301         This patch cleans up a few loose ends in HTML5 tree builder.
302         Technically, we could do each of these as individual patches, but that
303         didn't seem worth while.
304
305         * html/HTMLTreeBuilder.cpp:
306         (WebCore::HTMLTreeBuilder::processStartTag):
307             - Add missing break before default case statement.  I don't think
308               this change is observable.
309         (WebCore::HTMLTreeBuilder::processComment):
310             - Originally I thought that comments had special processing in the
311               InHeadNoscriptMode, but it turns out that when you unwind the
312               definitions, it amounts to exactly the same thing.
313         (WebCore::HTMLTreeBuilder::processEndOfFile):
314             - Add missing break before default case statement.  I don't think
315               this change is observable.
316         (WebCore::HTMLTreeBuilder::insertComment):
317             - Eliminate one unnecessary ref/deref pair.
318         (WebCore::HTMLTreeBuilder::insertSelfClosingElement):
319             - When we insert self-closing elements, there's no reason to push
320               them onto the stack of open elements just to pop them off again.
321               This change saves a malloc/free pair as well as a ref/deref pair.
322               Go team.
323         * html/HTMLTreeBuilder.h:
324             - Remove unused function.
325
326 2010-06-27  Adam Barth  <abarth@webkit.org>
327
328         Reviewed by Eric Seidel.
329
330         Implement remaining StartTag processing for InHeadNoscriptMode
331         https://bugs.webkit.org/show_bug.cgi?id=41264
332
333         The InHeadNoscriptMode processes some start tags "as if" the tree
334         builder were in the InHeadMode.  This is an idiom we'll see more of
335         later.  My approach is this patch is to factor all the logic for
336         processing start tags in the InHeadMode into a separate function that
337         can be called from both locations.  This seems cleaner than just
338         splitting out the parts that are actually used by both modes.
339
340         * html/HTMLTreeBuilder.cpp:
341         (WebCore::HTMLTreeBuilder::processStartTag):
342         (WebCore::HTMLTreeBuilder::processStartTagForInHead):
343         (WebCore::HTMLTreeBuilder::insertSelfClosingElement):
344         * html/HTMLTreeBuilder.h:
345
346 2010-06-27  Adam Barth  <abarth@webkit.org>
347
348         Reviewed by Eric Seidel.
349
350         Add support for <title> and <style> elements
351         https://bugs.webkit.org/show_bug.cgi?id=41263
352
353         These elements use the generic RCDATA and RawText algorithms,
354         respectively.
355
356         * html/HTMLTreeBuilder.cpp:
357         (WebCore::HTMLTreeBuilder::processEndTag):
358         (WebCore::HTMLTreeBuilder::insertGenericRCDATAElement):
359         (WebCore::HTMLTreeBuilder::insertGenericRawTextElement):
360
361 2010-06-27  Adam Barth  <abarth@webkit.org>
362
363         Reviewed by Eric Seidel.
364
365         Actually insert Doctype elements
366         https://bugs.webkit.org/show_bug.cgi?id=41262
367
368         This code is pretty much the same as in the old tree builder.
369
370         * html/HTMLToken.h:
371         (WebCore::AtomicHTMLToken::publicIdentifier):
372         (WebCore::AtomicHTMLToken::systemIdentifier):
373         * html/HTMLTreeBuilder.cpp:
374         (WebCore::HTMLTreeBuilder::insertDoctype):
375
376 2010-06-27  Andreas Kling  <andreas.kling@nokia.com>
377
378         Reviewed by Darin Adler.
379
380         Canvas: Ignore calls to drawImage() with non-finite parameters
381         https://bugs.webkit.org/show_bug.cgi?id=38929
382
383         This also fixes a Qt assert when using the raster graphics system.
384
385         Spec link:
386         http://www.whatwg.org/specs/web-apps/current-work/#2dcontext
387
388         * html/canvas/CanvasRenderingContext2D.cpp:
389         (WebCore::CanvasRenderingContext2D::drawImage):
390
391 2010-06-27  Andreas Kling  <andreas.kling@nokia.com>
392
393         Reviewed by Kenneth Rohde Christiansen.
394
395         editing/execCommand/copy-without-selection.html fails on Qt after r61637
396         https://bugs.webkit.org/show_bug.cgi?id=41025
397
398         The problem was that when getting data back via Clipboard::getData(),
399         the String::String(const char*, int) constructor was called
400         with UTF-16 data.
401
402         The solution is to use QMimeData's text() and setText() for "text/plain".
403
404         setText() which makes sure Qt passes the string in proper format to the
405         system clipboard. (The previous implementation would convert it to UTF-8)
406
407         text() makes sure that the correct encoding is used (UTF-16) and that
408         we get back whatever we originally put in there.
409
410         * platform/qt/ClipboardQt.cpp:
411         (WebCore::isTextMimeType):
412         (WebCore::ClipboardQt::getData):
413         (WebCore::ClipboardQt::setData):
414
415 2010-06-27  Adam Barth  <abarth@webkit.org>
416
417         Reviewed by Eric Seidel.
418
419         HTML5 tree builder should be able to execute inline scripts
420         https://bugs.webkit.org/show_bug.cgi?id=41257
421
422         This patch implements enough machinery so that we can execute inline
423         scripts in extremely simple documents such as the following:
424
425         <html>
426         <script>
427         alert(1);
428         </script>
429
430         To get this to work, I had to flesh out a surprising amount of the data
431         structures for processing the <head>.  No tests because this is
432         already covered by most LayoutTests.
433
434         * html/HTMLTreeBuilder.cpp:
435         (WebCore::HTMLTreeBuilder::HTMLTreeBuilder):
436         (WebCore::HTMLTreeBuilder::constructTreeFromToken):
437         (WebCore::HTMLTreeBuilder::processStartTag):
438         (WebCore::HTMLTreeBuilder::processEndTag):
439         (WebCore::HTMLTreeBuilder::processCharacter):
440         (WebCore::HTMLTreeBuilder::insertComment):
441         (WebCore::HTMLTreeBuilder::insertElement):
442         (WebCore::HTMLTreeBuilder::insertScriptElement):
443         * html/HTMLTreeBuilder.h:
444         (WebCore::HTMLTreeBuilder::ElementRecord::ElementRecord):
445         (WebCore::HTMLTreeBuilder::ElementRecord::element):
446         (WebCore::HTMLTreeBuilder::ElementRecord::next):
447         (WebCore::HTMLTreeBuilder::ElementRecord::releaseNext):
448         (WebCore::HTMLTreeBuilder::ElementRecord::setNext):
449         (WebCore::HTMLTreeBuilder::ElementStack::pop):
450         (WebCore::HTMLTreeBuilder::ElementStack::push):
451         (WebCore::HTMLTreeBuilder::ElementStack::top):
452         (WebCore::HTMLTreeBuilder::ElementStack::remove):
453         (WebCore::HTMLTreeBuilder::currentElement):
454
455 2010-06-26  Brady Eidson  <beidson@apple.com>
456
457         Reviewed by Darin Adler.
458
459         beforeProcess event needs to fire before inline scripts/stylesheets take effect
460         <rdar://problem/8084335> and https://bugs.webkit.org/show_bug.cgi?id=40484
461
462         This patch adds the Event, the onBeforeProcess attribute, and hooks the attribute up in a few places.
463         Besides that, no change in behavior.
464
465         Layout tests will come with the actual implementations as a followup to this patch.
466
467         Project file nonsense:
468         * DerivedSources.make:
469         * GNUmakefile.am:
470         * WebCore.gypi:
471         * WebCore.pri:
472         * WebCore.pro:
473         * WebCore.vcproj/WebCore.vcproj:
474         * WebCore.xcodeproj/project.pbxproj:
475
476         Scaffolding for the event itself:
477         * dom/BeforeProcessEvent.cpp: Added.
478         (WebCore::BeforeProcessEvent::text):
479         (WebCore::BeforeProcessEvent::setText):
480         * dom/BeforeProcessEvent.h: Added.
481         (WebCore::BeforeProcessEvent::create):
482         (WebCore::BeforeProcessEvent::initBeforeProcessEvent):
483         (WebCore::BeforeProcessEvent::BeforeProcessEvent):
484         * dom/BeforeProcessEvent.idl: Added.
485
486         * dom/EventNames.h:
487
488         Respect the onBeforeProcess attribute:
489         * dom/Document.cpp:
490         (WebCore::Document::addListenerTypeIfNeeded):
491         * dom/Document.h:
492         (WebCore::Document::):
493
494         * html/HTMLAttributeNames.in:
495         * html/HTMLScriptElement.cpp:
496         (WebCore::HTMLScriptElement::parseMappedAttribute):
497         * html/HTMLStyleElement.cpp:
498         (WebCore::HTMLStyleElement::parseMappedAttribute):
499
500 2010-06-26  Darin Adler  <darin@apple.com>
501
502         Try to fix Chromium build by adding back function used only by Chromium WebKit.
503
504         * html/HTMLInputElement.cpp:
505         (WebCore::HTMLInputElement::defaultChecked): Added back.
506         * html/HTMLInputElement.h: Added defaultChecked function.
507
508         * html/HTMLMetaElement.cpp:
509         (WebCore::HTMLMetaElement::httpEquiv): Added back.
510         * html/HTMLMetaElement.h: Added httpEquiv function.
511
512         * html/HTMLOptionElement.cpp:
513         (WebCore::HTMLOptionElement::defaultSelected): Added back.
514         * html/HTMLOptionElement.h: Added defaultSelected function.
515
516         * rendering/style/StyleRareNonInheritedData.h: Fixed incorrect struct vs. class
517         here as seen in warnings on Chromium Windows bot.
518
519 2010-06-26  Darin Adler  <darin@apple.com>
520
521         Try to fix Windows build by adding back function used only by Windows WebKit.
522
523         * html/HTMLOptionElement.cpp:
524         (WebCore::HTMLOptionElement::label): Added back.
525         * html/HTMLOptionElement.h: Added label function.
526
527 2010-06-26  Darin Adler  <darin@apple.com>
528
529         Try to fix Qt build by adding back function used only by Qt WebKit.
530
531         * html/HTMLMetaElement.cpp:
532         (WebCore::HTMLMetaElement::content): Added back.
533         * html/HTMLMetaElement.h: Added content function.
534
535 2010-06-26  Darin Adler  <darin@apple.com>
536
537         * html/HTMLFormElement.h: Removed stray character that got in here before landing.
538
539 2010-06-26  Darin Adler  <darin@apple.com>
540
541         Reviewed by Sam Weinig.
542
543         Add more use of reflection, remove unused functions
544         https://bugs.webkit.org/show_bug.cgi?id=41255
545
546         Also noticed that HTMLDirectoryElement was missing its create function
547         and added that so the element will get the correct class.
548
549         * html/HTMLBaseFontElement.idl: Use reflection for the size attribute
550         in the Objective-C code path too.
551
552         * html/HTMLSelectElement.idl: Use reflection for disabled and autofocus
553         attributes. Also removed spaces and indenting to match other IDL files.
554
555         * html/HTMLStyleElement.idl: Use reflection for disabled attribute.
556
557         * html/HTMLTableCellElement.idl: Use reflection for noWrap attribute.
558
559         * html/HTMLTextAreaElement.idl: Use reflection for disabled, autofocus,
560         readOnly, and required attributes.
561
562         * html/HTMLUListElement.idl: Use reflection for compact attribute.
563
564         * html/HTMLDirectoryElement.cpp:
565         (WebCore::HTMLDirectoryElement::HTMLDirectoryElement): Made inline.
566         (WebCore::HTMLDirectoryElement::create): Added.
567         * html/HTMLDirectoryElement.h:
568         Added create, made constructor private, removed unused functions.
569
570         * html/HTMLStyleElement.cpp:
571         (WebCore::HTMLStyleElement::parseMappedAttribute): Removed code to
572         set unused m_media data member.
573         * html/HTMLStyleElement.h:
574         Removed unused functions and m_media data member. Also made some
575         functions private.
576
577         * html/HTMLAppletElement.cpp:
578         * html/HTMLAppletElement.h:
579         * html/HTMLAreaElement.cpp:
580         * html/HTMLAreaElement.h:
581         * html/HTMLBaseFontElement.cpp:
582         * html/HTMLBaseFontElement.h:
583         * html/HTMLButtonElement.cpp:
584         * html/HTMLButtonElement.h:
585         * html/HTMLDListElement.cpp:
586         * html/HTMLDListElement.h:
587         * html/HTMLDivElement.cpp:
588         * html/HTMLDivElement.h:
589         * html/HTMLFontElement.cpp:
590         * html/HTMLFontElement.h:
591         * html/HTMLFormControlElement.cpp:
592         * html/HTMLFormControlElement.h:
593         * html/HTMLFormElement.cpp:
594         * html/HTMLFormElement.h:
595         * html/HTMLFrameElement.cpp: Also removed an incorrect FIXME comment
596         here after I did a little research to disprove it.
597         * html/HTMLFrameElement.h:
598         * html/HTMLFrameSetElement.cpp:
599         * html/HTMLFrameSetElement.h:
600         * html/HTMLHRElement.cpp:
601         * html/HTMLHRElement.h:
602         * html/HTMLHeadElement.cpp:
603         * html/HTMLHeadElement.h:
604         * html/HTMLHeadingElement.cpp:
605         * html/HTMLHeadingElement.h:
606         * html/HTMLHtmlElement.cpp:
607         * html/HTMLHtmlElement.h:
608         * html/HTMLImageElement.cpp:
609         * html/HTMLImageElement.h:
610         * html/HTMLInputElement.cpp:
611         * html/HTMLInputElement.h:
612         * html/HTMLIsIndexElement.cpp:
613         * html/HTMLIsIndexElement.h:
614         * html/HTMLLIElement.cpp:
615         * html/HTMLLIElement.h:
616         * html/HTMLLabelElement.cpp:
617         * html/HTMLLabelElement.h:
618         * html/HTMLLegendElement.cpp:
619         * html/HTMLLegendElement.h:
620         * html/HTMLLinkElement.cpp:
621         * html/HTMLLinkElement.h:
622         * html/HTMLMapElement.cpp:
623         * html/HTMLMapElement.h:
624         * html/HTMLMenuElement.cpp:
625         * html/HTMLMenuElement.h:
626         * html/HTMLMetaElement.cpp:
627         * html/HTMLMetaElement.h:
628         * html/HTMLModElement.cpp:
629         * html/HTMLModElement.h:
630         * html/HTMLOListElement.cpp:
631         * html/HTMLOListElement.h:
632         * html/HTMLObjectElement.cpp:
633         * html/HTMLObjectElement.h:
634         * html/HTMLOptGroupElement.cpp:
635         * html/HTMLOptGroupElement.h:
636         * html/HTMLOptionElement.cpp:
637         * html/HTMLOptionElement.h:
638         * html/HTMLParagraphElement.cpp:
639         * html/HTMLParagraphElement.h:
640         * html/HTMLParamElement.cpp:
641         * html/HTMLParamElement.h:
642         * html/HTMLPlugInElement.cpp:
643         * html/HTMLPlugInElement.h:
644         * html/HTMLPreElement.cpp:
645         * html/HTMLPreElement.h:
646         * html/HTMLQuoteElement.cpp:
647         * html/HTMLQuoteElement.h:
648         * html/HTMLScriptElement.cpp:
649         * html/HTMLScriptElement.h:
650         * html/HTMLTableCaptionElement.cpp:
651         * html/HTMLTableCaptionElement.h:
652         * html/HTMLTableCellElement.cpp:
653         * html/HTMLTableCellElement.h:
654         * html/HTMLTableColElement.cpp:
655         * html/HTMLTableColElement.h:
656         * html/HTMLTableElement.cpp:
657         * html/HTMLTableElement.h:
658         * html/HTMLTableRowElement.cpp:
659         * html/HTMLTableRowElement.h:
660         * html/HTMLTextAreaElement.cpp:
661         * html/HTMLTextAreaElement.h:
662         * html/HTMLUListElement.cpp:
663         * html/HTMLUListElement.h:
664         * html/HTMLVideoElement.cpp:
665         * html/HTMLVideoElement.h:
666         Removed unused functions.
667
668 2010-06-26  Tony Gentilcore  <tonyg@chromium.org>
669
670         Reviewed by Adam Barth.
671
672         Exclude line numbers for sources which are not from the network.
673         https://bugs.webkit.org/show_bug.cgi?id=41060
674
675         * html/HTMLDocumentParser.cpp:
676         (WebCore::HTMLDocumentParser::write):
677
678 2010-06-25  Antonio Gomes  <tonikitoo@webkit.org>
679
680         Unreviewed complementary fix for r61818. It added StaticHashSetListNode.cpp|h to the system,
681         but did not added it to chromium build system.
682
683         * WebCore.gypi:
684
685 2010-06-26  Pavel Feldman  <pfeldman@chromium.org>
686
687         Reviewed by Yury Semikhatsky.
688
689         Web Inspector: ScripsPanel.prototype.editScriptSource uses old addBreakpoint signature.
690
691         https://bugs.webkit.org/show_bug.cgi?id=41247
692
693         * inspector/front-end/BreakpointManager.js:
694         (WebInspector.BreakpointManager.prototype.removeBreakpoint):
695         (WebInspector.Breakpoint.prototype.set enabled):
696         (WebInspector.Breakpoint.prototype.set condition):
697         * inspector/front-end/Object.js:
698         (WebInspector.Object.prototype.addEventListener):
699         (WebInspector.Object.prototype.removeEventListener):
700         (WebInspector.Object.prototype.removeAllListeners):
701         * inspector/front-end/ScriptsPanel.js:
702         (WebInspector.ScriptsPanel.prototype.editScriptSource.mycallback):
703         (WebInspector.ScriptsPanel.prototype.editScriptSource):
704
705 2010-06-26  Tony Gentilcore  <tonyg@chromium.org>
706
707         Reviewed by Dimitri Glazkov.
708
709         Add a guarded window.performance.timing binding which is disabled by default.
710         https://bugs.webkit.org/show_bug.cgi?id=38924
711
712         This is where Web Timing support will be implemented. Web Timing is a
713         draft spec for exposing load times to web pages. It will be enabled
714         once the spec and implementaiton are solidified. See:
715         http://dev.w3.org/2006/webapi/WebTiming/
716
717         No new tests because guarded behind a #DEFINE. Will add tests as
718         functionality is landed.
719
720         * Android.mk:
721         * CMakeLists.txt:
722         * Configurations/FeatureDefines.xcconfig:
723         * DerivedSources.cpp:
724         * DerivedSources.make:
725         * GNUmakefile.am:
726         * WebCore.gypi:
727         * WebCore.pri:
728         * WebCore.pro:
729         * WebCore.vcproj/WebCore.vcproj:
730         * WebCore.xcodeproj/project.pbxproj:
731         * page/DOMWindow.cpp:
732         (WebCore::DOMWindow::clear):
733         (WebCore::DOMWindow::performance):
734         * page/DOMWindow.h:
735         (WebCore::DOMWindow::optionalPerformance):
736         * page/DOMWindow.idl:
737         * page/NavigationTiming.cpp: Added.
738         (WebCore::NavigationTiming::NavigationTiming):
739         (WebCore::NavigationTiming::frame):
740         (WebCore::NavigationTiming::disconnectFrame):
741         (WebCore::NavigationTiming::navigationStart):
742         * page/NavigationTiming.h: Added.
743         (WebCore::NavigationTiming::create):
744         * page/NavigationTiming.idl: Added.
745         * page/Performance.cpp: Added.
746         (WebCore::Performance::Performance):
747         (WebCore::Performance::frame):
748         (WebCore::Performance::disconnectFrame):
749         (WebCore::Performance::timing):
750         * page/Performance.h: Added.
751         (WebCore::Performance::create):
752         * page/Performance.idl: Added.
753
754 2010-06-25  Zhenyao Mo  <zmo@google.com>
755
756         Reviewed by Dimitri Glazkov.
757
758         activeTexture wrongly generates error with legal input.
759         https://bugs.webkit.org/show_bug.cgi?id=41227
760
761         Test: fast/canvas/webgl/texture-active-bind.html
762
763         * html/canvas/WebGLRenderingContext.cpp:
764         (WebCore::WebGLRenderingContext::activeTexture): Fix the upper limit test for test units.
765
766 2010-06-25  Johnny Ding  <jnd@chromium.org>
767
768         Reviewed by Adam Barth.
769
770         https://bugs.webkit.org/show_bug.cgi?id=41061
771         Make sure Chromium's ScriptController::processingUserGesture follows the JSC's behavior.
772         Set right value in UserGestureIndicator when handling events in PopupMenuList in chromium.
773
774         Test: fast/events/popup-when-select-change.html
775
776         * bindings/v8/ScriptController.cpp:
777         (WebCore::ScriptController::processingUserGesture):
778         * platform/chromium/PopupMenuChromium.cpp:
779         (WebCore::PopupContainer::handleMouseDownEvent):
780         (WebCore::PopupContainer::handleMouseMoveEvent):
781         (WebCore::PopupContainer::handleMouseReleaseEvent):
782         (WebCore::PopupContainer::handleWheelEvent):
783         (WebCore::PopupContainer::handleKeyEvent):
784
785 2010-06-25  Tony Gentilcore  <tonyg@chromium.org>
786
787         Reviewed by Eric Seidel.
788
789         Make PendingScript hold a CachedResourceClient open for its lifetime
790         https://bugs.webkit.org/show_bug.cgi?id=40968
791
792         This replaces the mechanism introduced in r61374 with a simpler
793         appraoch for preventing unexpected purges: always keep a client open.
794         This approach will allow deferred scripts to add a client after
795         the resource may have already been loaded without having to worry about
796         the buffer being purged in the meantime.
797
798         No new tests because making a CachedResource purse itself is not
799         testable from a LayoutTest.
800
801         * html/HTMLDocumentParser.cpp:
802         (WebCore::HTMLDocumentParser::watchForLoad):
803         (WebCore::HTMLDocumentParser::notifyFinished):
804         * html/HTMLScriptRunner.cpp:
805         (WebCore::HTMLScriptRunner::~HTMLScriptRunner):
806         (WebCore::HTMLScriptRunner::sourceFromPendingScript):
807         (WebCore::HTMLScriptRunner::isPendingScriptReady):
808         (WebCore::HTMLScriptRunner::executePendingScript):
809         (WebCore::HTMLScriptRunner::watchForLoad):
810         (WebCore::HTMLScriptRunner::stopWatchingForLoad):
811         (WebCore::HTMLScriptRunner::executeScriptsWaitingForLoad):
812         (WebCore::HTMLScriptRunner::requestScript):
813         (WebCore::HTMLScriptRunner::PendingScript::~PendingScript):
814         (WebCore::HTMLScriptRunner::PendingScript::releaseElementAndClear):
815         (WebCore::HTMLScriptRunner::PendingScript::setCachedScript):
816         (WebCore::HTMLScriptRunner::PendingScript::cachedScript):
817         * html/HTMLScriptRunner.h:
818         (WebCore::HTMLScriptRunner::PendingScript::PendingScript):
819         (WebCore::HTMLScriptRunner::PendingScript::watchingForLoad):
820         (WebCore::HTMLScriptRunner::PendingScript::setWatchingForLoad):
821         (WebCore::HTMLScriptRunner::PendingScript::notifyFinished):
822         * html/HTMLScriptRunnerHost.h:
823
824 2010-06-25  Zhenyao Mo  <zmo@google.com>
825
826         Reviewed by Dimitri Glazkov.
827
828         getUniform will not work for fetching uniform array elements
829         https://bugs.webkit.org/show_bug.cgi?id=34508
830
831         Test: fast/canvas/webgl/gl-uniform-arrays.html
832
833         * html/canvas/WebGLRenderingContext.cpp:
834         (WebCore::WebGLRenderingContext::attachShader): Generate correct errors.
835         (WebCore::WebGLRenderingContext::getUniform): Dealing with array elements.
836         (WebCore::WebGLRenderingContext::useProgram): Deal with program==null.
837         (WebCore::WebGLRenderingContext::validateProgram): Generate correct errors.
838         * platform/graphics/mac/GraphicsContext3DMac.mm:
839         (WebCore::GraphicsContext3D::useProgram): Deal with program==null.
840
841 2010-06-25  Zhenyao Mo  <zmo@google.com>
842
843         Reviewed by Dimitri Glazkov.
844
845         Bring set/get state functions to GLES2 conformance
846         https://bugs.webkit.org/show_bug.cgi?id=41095
847
848         Tests: fast/canvas/webgl/gl-enable-enum-test.html
849                fast/canvas/webgl/gl-enum-tests.html
850
851         * html/canvas/WebGLRenderingContext.cpp: Check input parameters according to GLES2 spec.
852         (WebCore::WebGLRenderingContext::blendEquation):
853         (WebCore::WebGLRenderingContext::blendEquationSeparate):
854         (WebCore::WebGLRenderingContext::disable):
855         (WebCore::WebGLRenderingContext::enable):
856         (WebCore::WebGLRenderingContext::hint):
857         (WebCore::WebGLRenderingContext::isEnabled):
858         (WebCore::WebGLRenderingContext::pixelStorei):
859         (WebCore::WebGLRenderingContext::validateBlendEquation):
860         (WebCore::WebGLRenderingContext::validateCapability):
861         * html/canvas/WebGLRenderingContext.h: Add helper function declaration.
862
863 2010-06-25  Sterling Swigart  <sswigart@google.com>
864
865         Reviewed by David Levin.
866
867         Callback code generation fixed so that now string parameters are converted to JSString
868         using the jsString method instead of the toJS method which would not compile.
869         https://bugs.webkit.org/show_bug.cgi?id=41119
870         
871         * bindings/scripts/CodeGeneratorJS.pm: Now generates jsString for String parameters in callbacks.
872         * bindings/scripts/test/JS/JSTestCallback.cpp: Fixed test for above.
873         (WebCore::JSTestCallback::callbackWithClass2Param): Ditto.
874
875 2010-06-25  Zhenyao Mo  <zmo@google.com>
876
877         Reviewed by Dimitri Glazkov.
878
879         A buffer should be bound to one target in its lifetime
880         https://bugs.webkit.org/show_bug.cgi?id=41108
881
882         Test: fast/canvas/webgl/buffer-bind-test.html
883
884         * html/canvas/WebGLBuffer.cpp:
885         (WebCore::WebGLBuffer::WebGLBuffer): Init target to 0. 
886         (WebCore::WebGLBuffer::associateBufferData): Remove target parameter, use one byteLength member.
887         (WebCore::WebGLBuffer::associateBufferSubData): Ditto.
888         (WebCore::WebGLBuffer::byteLength): Ditto.
889         (WebCore::WebGLBuffer::setTarget): Set target.
890         * html/canvas/WebGLBuffer.h: Cache target in the WebGLBuffer object, use one byteLength member.
891         (WebCore::WebGLBuffer::getTarget):
892         * html/canvas/WebGLRenderingContext.cpp:
893         (WebCore::WebGLRenderingContext::bindBuffer): Check if a buffer is bound to another target; set buffer object internal target.
894         (WebCore::WebGLRenderingContext::bufferData): Remove target parameter and use the WebGLBuffer cached target instead.
895         (WebCore::WebGLRenderingContext::bufferSubData): Ditto.
896         (WebCore::WebGLRenderingContext::validateElementArraySize): Ditto.
897         (WebCore::WebGLRenderingContext::validateIndexArrayConservative): Ditto.
898         (WebCore::WebGLRenderingContext::vertexAttribPointer): Ditto.
899
900 2010-06-25  Dean Jackson  <dino@apple.com>
901
902         Reviewed by Simon Fraser.
903
904         https://bugs.webkit.org/show_bug.cgi?id=41188
905         Animations should not require 0% and 100% keyframes
906
907         When we are generating the animation lists in CSSStyleSelector,
908         rather than bail if we notice that "from" or "to" are missing, we
909         now generate synthetic keyframes for those cases.
910
911         Tests: animations/missing-from-to-transforms.html
912                animations/missing-from-to.html
913                WebCore/manual-tests/animation-with-transition.html
914
915         * css/CSSStyleSelector.cpp:
916         (WebCore::CSSStyleSelector::styleForKeyframe):
917                 Moved individual keyframe generation into a new function.
918         (WebCore::CSSStyleSelector::keyframeStylesForAnimation):
919                 Call the new function above for regular keyframes, and
920                 also check for missing keyframes and generate them if
921                 necessary.
922         * css/CSSStyleSelector.h:
923
924 2010-06-25  Adam Barth  <abarth@webkit.org>
925
926         Reviewed by Eric Seidel.
927
928         We should parse <html>
929         https://bugs.webkit.org/show_bug.cgi?id=41239
930
931         This patch is hard to test, but I think this patch lets us parse a
932         document consisting of only an <html> start tag.
933
934         * html/HTMLTreeBuilder.cpp:
935         (WebCore::HTMLTreeBuilder::constructTreeFromToken):
936         (WebCore::HTMLTreeBuilder::insertHTMLStartTagBeforeHTML):
937         (WebCore::HTMLTreeBuilder::insertHTMLStartTagInBody):
938         (WebCore::HTMLTreeBuilder::processStartTag):
939         (WebCore::HTMLTreeBuilder::processDefaultForBeforeHTMLMode):
940         * html/HTMLTreeBuilder.h:
941         (WebCore::HTMLTreeBuilder::ElementStack::push):
942
943 2010-06-25  Dan Bernstein  <mitz@apple.com>
944
945         Reviewed by Sam Weinig.
946
947         <rdar://problem/8000667> Certain text is repeated before and after a line break
948
949         Test: fast/text/bidi-explicit-embedding-past-end.html
950
951         * platform/text/BidiResolver.h:
952         (WebCore::::createBidiRunsForLine): Committing explicit embedding past the end of the range
953         creates BidiRuns up to the end of the range, so at that point, we can stop iterating.
954
955 2010-06-25  Eric Seidel  <eric@webkit.org>
956
957         Reviewed by Adam Barth.
958
959         Move decoding into DocumentParser to further simplify RawDataDocumentParser and DocumentWriter
960         https://bugs.webkit.org/show_bug.cgi?id=41202
961
962         Hit the Windoze with the compile bat.
963
964         * WebCore.vcproj/WebCore.vcproj:
965
966 2010-06-25  Adam Barth  <abarth@webkit.org>
967
968         Reviewed by Eric Seidel.
969
970         HTMLTreeBuilder should branch first on token type and then on insertion mode
971         https://bugs.webkit.org/show_bug.cgi?id=41232
972
973         This is different than how the spec is written, but it lets us remove a
974         lot of redudancy in the algorithm.  We might even want to pull some of
975         the branches on token name outside the insertion mode branch, but I'll
976         leave that for a future patch.
977
978         Although this looks like a big patch, it's mostly just a mechanical
979         switch permutation.
980
981         * html/HTMLTreeBuilder.cpp:
982         (WebCore::HTMLTreeBuilder::constructTreeFromToken):
983         (WebCore::HTMLTreeBuilder::processToken):
984         (WebCore::HTMLTreeBuilder::processDoctypeToken):
985         (WebCore::HTMLTreeBuilder::processStartTag):
986         (WebCore::HTMLTreeBuilder::processEndTag):
987         (WebCore::HTMLTreeBuilder::processComment):
988         (WebCore::HTMLTreeBuilder::processCharacter):
989         (WebCore::HTMLTreeBuilder::processEndOfFile):
990         (WebCore::HTMLTreeBuilder::processDefaultForInitialMode):
991         (WebCore::HTMLTreeBuilder::processDefaultForBeforeHTMLMode):
992         (WebCore::HTMLTreeBuilder::processDefaultForBeforeHeadMode):
993         (WebCore::HTMLTreeBuilder::processDefaultForInHeadMode):
994         (WebCore::HTMLTreeBuilder::processDefaultForInHeadNoscriptMode):
995         (WebCore::HTMLTreeBuilder::processDefaultForAfterHeadMode):
996         * html/HTMLTreeBuilder.h:
997
998 2010-06-25  Adam Barth  <abarth@webkit.org>
999
1000         Reviewed by Darin Adler.
1001
1002         Tree builder doesn't need to return a Node
1003         https://bugs.webkit.org/show_bug.cgi?id=41225
1004
1005         The old tree builder returned the newly inserted Node, but the new tree
1006         builder doesn't need to do that as far as I can tell.  Removing the
1007         return value cuts down on a bunch of accounting.
1008
1009         * html/HTMLTreeBuilder.cpp:
1010         (WebCore::HTMLTreeBuilder::passTokenToLegacyParser):
1011         (WebCore::HTMLTreeBuilder::constructTreeFromToken):
1012         (WebCore::HTMLTreeBuilder::processToken):
1013         (WebCore::HTMLTreeBuilder::insertDoctype):
1014         (WebCore::HTMLTreeBuilder::insertComment):
1015         (WebCore::HTMLTreeBuilder::insertGenericRCDATAElement):
1016         (WebCore::HTMLTreeBuilder::insertGenericRawTextElement):
1017         (WebCore::HTMLTreeBuilder::insertScriptElement):
1018         * html/HTMLTreeBuilder.h:
1019
1020 2010-06-25  Zhenyao Mo  <zmo@google.com>
1021
1022         Reviewed by Dimitri Glazkov.
1023
1024         getParameter(COLOR_WRITEMASK) needs to return Array
1025         https://bugs.webkit.org/show_bug.cgi?id=40437
1026
1027         * bindings/js/JSWebGLRenderingContextCustom.cpp: Handling bool array.
1028         (WebCore::toJS):
1029         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp: Handling bool array.
1030         (WebCore::toV8Object):
1031         * html/canvas/WebGLGetInfo.cpp: Handling bool array.
1032         (WebCore::WebGLGetInfo::WebGLGetInfo):
1033         (WebCore::WebGLGetInfo::getBoolArray):
1034         * html/canvas/WebGLGetInfo.h: Handling bool array.
1035         (WebCore::WebGLGetInfo::):
1036         * html/canvas/WebGLRenderingContext.cpp: Handling bool array.
1037         (WebCore::WebGLRenderingContext::getParameter):
1038         (WebCore::WebGLRenderingContext::getBooleanArrayParameter):
1039         * html/canvas/WebGLRenderingContext.h: Handling bool array.
1040
1041 2010-06-25  Evan Stade  <estade@chromium.org>
1042
1043         Reviewed by Darin Fisher.
1044
1045         [chromium linux] Improve look of scrollbars
1046         https://bugs.webkit.org/show_bug.cgi?id=35775
1047
1048         This will affect layout pixel tests, which will need to be rebaselined.
1049
1050         * platform/Scrollbar.cpp: need the buttons to be invalidated when the
1051         thumb moves as they paint differently if the thumb is at the top or
1052         bottom
1053         (WebCore::Scrollbar::updateThumbPosition):
1054         (WebCore::Scrollbar::updateThumbProportion):
1055         * platform/chromium/ScrollbarThemeChromium.cpp:
1056         (WebCore::ScrollbarThemeChromium::trackRect): share code between
1057         linux/windows
1058         * platform/chromium/ScrollbarThemeChromiumLinux.cpp:
1059         (WebCore::ScrollbarThemeChromiumLinux::scrollbarThickness):
1060         (WebCore::outlineColor): up the contrast
1061         (WebCore::ScrollbarThemeChromiumLinux::paintButton): add custom button
1062         drawing implementation
1063         (WebCore::ScrollbarThemeChromiumLinux::buttonSize): add buttons
1064         * platform/chromium/ScrollbarThemeChromiumWin.cpp: share code between
1065         linux/windows
1066         * rendering/RenderThemeChromiumLinux.cpp: improve stock colors to get
1067         better contrast and integration with stock chrome theme
1068
1069 2010-06-25  Eric Seidel  <eric@webkit.org>
1070
1071         Reviewed by Adam Barth.
1072
1073         Move decoding into DocumentParser to further simplify RawDataDocumentParser and DocumentWriter
1074         https://bugs.webkit.org/show_bug.cgi?id=41202
1075
1076         The silly thing about this patch is that none of the
1077         RawDataDocumentParser subclasses actually use any of the
1078         data passed to them via appendBytes.
1079
1080         This makes the relationship between DocumentWriter and
1081         DocumentParser slightly more confusing, however I think this
1082         DocumentParser API is slightly nicer.
1083
1084         Next step is to split DecodedDataDocumentParser out from
1085         DocumentParser, and then the base DocumentParser won't know
1086         anything about decoding or SegmentedString.
1087
1088         No functional change, thus no tests.
1089
1090         * WebCore.xcodeproj/project.pbxproj:
1091         * dom/DocumentParser.h:
1092         * dom/RawDataDocumentParser.h:
1093         * loader/DocumentWriter.cpp:
1094         (WebCore::DocumentWriter::replaceDocument):
1095         (WebCore::DocumentWriter::createDecoderIfNeeded):
1096         (WebCore::DocumentWriter::reportDataRecieved):
1097         (WebCore::DocumentWriter::addData):
1098         * loader/DocumentWriter.h:
1099         * loader/ImageDocument.cpp:
1100         (WebCore::ImageDocumentParser::appendBytes):
1101         * loader/MediaDocument.cpp:
1102         (WebCore::MediaDocumentParser::appendBytes):
1103         * loader/PluginDocument.cpp:
1104         (WebCore::PluginDocumentParser::appendBytes):
1105         * loader/SinkDocument.cpp:
1106         (WebCore::SinkDocumentParser::SinkDocumentParser):
1107         (WebCore::SinkDocumentParser::appendBytes):
1108         (WebCore::SinkDocument::createParser):
1109
1110 2010-06-25  Eric Seidel  <eric@webkit.org>
1111
1112         Reviewed by Adam Barth.
1113
1114         Split DocumentParser::write into separate append and insert calls
1115         https://bugs.webkit.org/show_bug.cgi?id=41197
1116
1117         Unfortunately this is still somewhat confusing as
1118         "insert" means "insert this data at the current
1119         insertion point and run the parser synchronously
1120         unless we're in a nested write call" and "append"
1121         means "append this data to the end and run the
1122         parser if not in a nested call or until possibly yielding".
1123
1124         This at least makes clearer which document parsers implement
1125         which behavior, and paves the way for moving the decoding
1126         logic into DocumentParser from DocumentWriter.
1127
1128         No functional changes, thus no tests.
1129
1130         * dom/Document.cpp:
1131         (WebCore::Document::write):
1132         * dom/DocumentParser.h:
1133         * dom/RawDataDocumentParser.h:
1134         (WebCore::RawDataDocumentParser::insert):
1135         (WebCore::RawDataDocumentParser::append):
1136         * dom/XMLDocumentParser.cpp:
1137         (WebCore::XMLDocumentParser::insert):
1138         (WebCore::XMLDocumentParser::append):
1139         * dom/XMLDocumentParser.h:
1140         * dom/XMLDocumentParserLibxml2.cpp:
1141         (WebCore::XMLDocumentParser::resumeParsing):
1142         * html/HTMLDocumentParser.cpp:
1143         (WebCore::HTMLDocumentParser::insert):
1144         (WebCore::HTMLDocumentParser::append):
1145         (WebCore::HTMLDocumentParser::parseDocumentFragment):
1146         * html/HTMLDocumentParser.h:
1147         * html/LegacyHTMLDocumentParser.cpp:
1148         (WebCore::LegacyHTMLDocumentParser::insert):
1149         (WebCore::LegacyHTMLDocumentParser::append):
1150         * html/LegacyHTMLDocumentParser.h:
1151         * loader/DocumentWriter.cpp:
1152         (WebCore::DocumentWriter::replaceDocument):
1153         (WebCore::DocumentWriter::addData):
1154         * loader/FTPDirectoryDocument.cpp:
1155         (WebCore::FTPDirectoryDocumentParser::FTPDirectoryDocumentParser):
1156         (WebCore::FTPDirectoryDocumentParser::loadDocumentTemplate):
1157         (WebCore::FTPDirectoryDocumentParser::append):
1158         * loader/TextDocument.cpp:
1159         (WebCore::TextDocumentParser::insert):
1160         (WebCore::TextDocumentParser::append):
1161         (WebCore::TextDocumentParser::finish):
1162
1163 2010-06-25  Daniel Cheng  <dcheng@chromium.org>
1164
1165         Reviewed by Darin Fisher.
1166
1167         [chromium] Add new stubs for querying platform drag-and-drop and copy-and-paste data.
1168
1169         This change adds new stubs for querying for data in a clipboard or drag operation. This is
1170         so adding support for more data types in clipboard/drag operations doesn't become
1171         increasingly expensive, since we currently copy all the drag data we need every time a new
1172         web drop target is entered. It also adds a new mechanism to write back to the system
1173         clipboard that isn't tied to one data type.
1174
1175         https://bugs.webkit.org/show_bug.cgi?id=40540
1176
1177         No new tests since we're just adding new ChromiumBridge APIs. When we switch to it, it will
1178         be covered by the existing tests.
1179
1180         * platform/chromium/ChromiumBridge.h:
1181         * platform/chromium/PasteboardPrivate.h:
1182         (WebCore::PasteboardPrivate::):
1183
1184 2010-06-25  Mario Sanchez Prada  <msanchez@igalia.com>
1185
1186         Reviewed by Xan Lopez.
1187
1188         [Gtk] Implement atk_table_get_column_header
1189         https://bugs.webkit.org/show_bug.cgi?id=30896
1190
1191         Implemented get_column_header and modified get_row_header
1192         accordingly to keep them both coherent among themselves.
1193         Based on a previous patch by Joanmarie Diggs.
1194
1195         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
1196         (webkit_accessible_table_get_column_header):
1197         (webkit_accessible_table_get_row_header):
1198
1199 2010-06-25  Martin Robinson  <mrobinson@igalia.com>
1200
1201         Reviewed by Xan Lopez.
1202
1203         [GTK] Pasteboard code does not take into account the nil character when getting and setting markup/netscape-url data
1204         https://bugs.webkit.org/show_bug.cgi?id=41221
1205
1206         Take into account null-terminator when getting and setting markup and
1207         Netscape URL pasteboard types. This means that if the selection data
1208         contains the null terminator, it won't be included in the final String.
1209         When setting the pasteboard data the null terminator is now included to
1210         match the behavior of other applications.
1211
1212         * platform/gtk/PasteboardHelper.cpp:
1213         (WebCore::PasteboardHelper::getClipboardContents):
1214         Create the markup string after using g_strndup to protect against non-null-terminated
1215         strings. Use String::fromUTF8 here to ensure that the string is not longer than the
1216         first null-terminator. Also fix a small indentation issue.
1217         (WebCore::PasteboardHelper::fillSelectionData):
1218         Always include the null-terminator when setting pasteboard data manually. This matches
1219         the behavior of other browser applications.
1220
1221 2010-06-25  Sam Magnuson  <smagnuson@netflix.com>
1222
1223         Reviewed by Kenneth Rohde Christiansen.
1224
1225         [Qt] When any geometry change happens to a node it will resize the
1226         backing cache
1227         https://bugs.webkit.org/show_bug.cgi?id=40378
1228
1229         Continue to grow the cache, but never toss it. When the pixmap
1230         cache gets too big it will be lost and created at the right size
1231         next time.
1232
1233         No new tests: this is an optimization.
1234
1235         * platform/graphics/qt/GraphicsLayerQt.cpp:
1236         (WebCore::GraphicsLayerQtImpl::recache):
1237         (WebCore::GraphicsLayerQtImpl::paint):
1238         (WebCore::GraphicsLayerQtImpl::flushChanges):
1239
1240 2010-06-25  Andreas Kling  <andreas.kling@nokia.com>
1241
1242         Reviewed by Darin Adler.
1243
1244         https://bugs.webkit.org/show_bug.cgi?id=41019
1245         Canvas: Remember verified clean origins for drawImage()
1246
1247         Made CanvasRenderingContext2D cache the KURLs of clean origins
1248         for fast repeated lookup.
1249
1250         * html/canvas/CanvasRenderingContext2D.cpp:
1251         (WebCore::CanvasRenderingContext2D::checkOrigin):
1252         * html/canvas/CanvasRenderingContext2D.h:
1253
1254 2010-06-25  Robert Hogan  <robert@webkit.org>
1255
1256         Reviewed by Kenneth Rohde Christiansen.
1257
1258         [Qt] HTTP 307 after a 303 after a POST re-sends POST data from the original request
1259
1260         https://bugs.webkit.org/show_bug.cgi?id=35301
1261
1262         Qt needs to use ResourceRequest::request()->httpMethod()) in order to determine
1263         the appropriate method for a 307 redirect request.
1264
1265         When deciding if it needs to override a POST method with a GET method during a
1266         redirect chain, QNetworkReplyHandler needs to check the HTTP method stored
1267         in ResourceRequest::request()->httpMethod(). This will always contain the
1268         original request method in a redirect chain and, more importantly, is the
1269         method that will be used for the request created from the redirect
1270         if it is not overridden.
1271
1272         * platform/network/qt/QNetworkReplyHandler.cpp:
1273         (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
1274
1275 2010-06-25  Dan Bernstein  <mitz@apple.com>
1276
1277         Reviewed by Anders Carlsson.
1278
1279         Removed a one-line method that only had one internal caller.
1280
1281         * rendering/RenderBlock.h: Removed bidiReorderLine()
1282         * rendering/RenderBlockLineLayout.cpp:
1283         (WebCore::RenderBlock::layoutInlineChildren): Moved the implementation of
1284         bidiReorderLine() inline here.
1285
1286 2010-06-25  Nate Chapin  <japhet@chromium.org>
1287
1288         Reviewed by Adam Barth.
1289
1290         Take a KURL parameter in Document's constructor.
1291         This will remove the one case where Document::url() 
1292         and FrameLoader::url() are not equal, allowing us to
1293         remove FrameLoader::url().
1294
1295         https://bugs.webkit.org/show_bug.cgi?id=41166
1296
1297         Refactor only, no new tests.
1298
1299         * dom/DOMImplementation.cpp:
1300         (WebCore::DOMImplementation::createDocument): Take a KURL and pass it through to Document.
1301         (WebCore::DOMImplementation::createHTMLDocument):
1302         * dom/DOMImplementation.h:
1303         * dom/Document.cpp:
1304         (WebCore::Document::Document): Call setURL() if a frame or a non-empty KURL is specified.
1305         (WebCore::Document::initSecurityContext): m_url is now initialized, so use it instead
1306             of m_frame->loader()->url() for initializing the SecurityOrigin.
1307         * dom/Document.h:
1308         (WebCore::Document::create):
1309         (WebCore::Document::createXHTML):
1310         * html/HTMLDocument.cpp:
1311         * html/HTMLDocument.h: Add KURL parameter to create() and constructor.
1312         * html/HTMLViewSourceDocument.cpp:
1313         * html/HTMLViewSourceDocument.h: Add KURL parameter to create() and constructor.
1314         * loader/CachedFont.cpp:
1315         (WebCore::CachedFont::ensureSVGFontData):
1316         * loader/DocumentWriter.cpp:
1317         (WebCore::DocumentWriter::createDocument): Take a KURL and pass it through to Document.
1318         (WebCore::DocumentWriter::begin): Pass existing url parameter to constructors, and remove
1319             redundant Document::setURL() call.
1320         * loader/DocumentWriter.h:
1321         * loader/FTPDirectoryDocument.cpp:
1322         * loader/FTPDirectoryDocument.h: Add KURL parameter to create() and constructor.
1323         * loader/ImageDocument.cpp:
1324         * loader/ImageDocument.h: Add KURL parameter to create() and constructor.
1325         * loader/MediaDocument.cpp:
1326         * loader/MediaDocument.h: Add KURL parameter to create() and constructor.
1327         * loader/PlaceholderDocument.h: Add KURL parameter to create() and constructor.
1328         * loader/PluginDocument.cpp:
1329         * loader/PluginDocument.h: Add KURL parameter to create() and constructor.
1330         * loader/SinkDocument.cpp:
1331         * loader/SinkDocument.h: Add KURL parameter to create() and constructor.
1332         * loader/TextDocument.cpp:
1333         * loader/TextDocument.h: Add KURL parameter to create() and constructor.
1334         * svg/SVGDocument.cpp:
1335         * svg/SVGDocument.h: Add KURL parameter to create() and constructor.
1336         * xml/DOMParser.cpp:
1337         (WebCore::DOMParser::parseFromString):
1338         * xml/XMLHttpRequest.cpp:
1339         (WebCore::XMLHttpRequest::responseXML):
1340         * xml/XSLTProcessor.cpp:
1341         (WebCore::XSLTProcessor::createDocumentFromSource):
1342
1343 2010-06-25  Sheriff Bot  <webkit.review.bot@gmail.com>
1344
1345         Unreviewed, rolling out r61812.
1346         http://trac.webkit.org/changeset/61812
1347         https://bugs.webkit.org/show_bug.cgi?id=41216
1348
1349         breaks Chromium workers tests (Requested by mnaganov on
1350         #webkit).
1351
1352         * storage/AbstractDatabase.cpp:
1353         * storage/AbstractDatabase.h:
1354         * storage/Database.cpp:
1355         (WebCore::Database::databaseInfoTableName):
1356         (WebCore::guidMutex):
1357         (WebCore::guidToVersionMap):
1358         (WebCore::updateGuidVersionMap):
1359         (WebCore::guidToDatabaseMap):
1360         (WebCore::databaseVersionKey):
1361         (WebCore::DatabaseCreationCallbackTask::create):
1362         (WebCore::DatabaseCreationCallbackTask::performTask):
1363         (WebCore::DatabaseCreationCallbackTask::DatabaseCreationCallbackTask):
1364         (WebCore::Database::openDatabase):
1365         (WebCore::Database::Database):
1366         (WebCore::Database::openAndVerifyVersion):
1367         (WebCore::retrieveTextResultFromDatabase):
1368         (WebCore::Database::getVersionFromDatabase):
1369         (WebCore::setTextValueInDatabase):
1370         (WebCore::Database::setVersionInDatabase):
1371         (WebCore::Database::versionMatchesExpected):
1372         (WebCore::Database::close):
1373         (WebCore::Database::disableAuthorizer):
1374         (WebCore::Database::enableAuthorizer):
1375         (WebCore::Database::setAuthorizerReadOnly):
1376         (WebCore::Database::lastActionChangedDatabase):
1377         (WebCore::Database::lastActionWasInsert):
1378         (WebCore::Database::resetDeletes):
1379         (WebCore::Database::hadDeletes):
1380         (WebCore::guidForOriginAndName):
1381         (WebCore::Database::resetAuthorizer):
1382         (WebCore::Database::performOpenAndVerify):
1383         (WebCore::Database::performCreationCallback):
1384         (WebCore::Database::version):
1385         (WebCore::Database::setExpectedVersion):
1386         (WebCore::Database::stringIdentifier):
1387         (WebCore::Database::displayName):
1388         (WebCore::Database::estimatedSize):
1389         (WebCore::Database::fileName):
1390         * storage/Database.h:
1391         (WebCore::Database::scriptExecutionContext):
1392         (WebCore::Database::opened):
1393         (WebCore::Database::isNew):
1394         (WebCore::Database::databaseDebugName):
1395         * storage/DatabaseAuthorizer.cpp:
1396         (WebCore::DatabaseAuthorizer::DatabaseAuthorizer):
1397         (WebCore::DatabaseAuthorizer::denyBasedOnTableName):
1398         * storage/DatabaseAuthorizer.h:
1399         (WebCore::DatabaseAuthorizer::create):
1400         * storage/DatabaseSync.cpp:
1401         (WebCore::DatabaseSync::databaseInfoTableName):
1402         (WebCore::DatabaseSync::openDatabaseSync):
1403         (WebCore::DatabaseSync::DatabaseSync):
1404         (WebCore::DatabaseSync::~DatabaseSync):
1405         (WebCore::DatabaseSync::version):
1406         (WebCore::DatabaseSync::changeVersion):
1407         (WebCore::DatabaseSync::transaction):
1408         (WebCore::DatabaseSync::scriptExecutionContext):
1409         * storage/DatabaseSync.h:
1410         (WebCore::DatabaseSync::databaseDebugName):
1411         * storage/DatabaseTask.cpp:
1412         (WebCore::DatabaseOpenTask::DatabaseOpenTask):
1413         (WebCore::DatabaseOpenTask::doPerformTask):
1414         * storage/DatabaseTask.h:
1415         (WebCore::DatabaseOpenTask::create):
1416
1417 2010-06-25  Lei Zheng  <lzheng@chromium.org>
1418
1419         Reviewed by Dimitri Glazkov.
1420
1421         Add a flag to the ResourceResponse for tracking if a request was fetched when
1422         Alternate-protocol is available.
1423         https://bugs.webkit.org/show_bug.cgi?id=41001
1424
1425         No new tests. (This is just a setter and getter.)
1426
1427         * platform/network/chromium/ResourceResponse.h:
1428         (WebCore::ResourceResponse::ResourceResponse):
1429         (WebCore::ResourceResponse::wasAlternateProtocolAvailable):
1430         (WebCore::ResourceResponse::setWasAlternateProtocolAvailable):
1431
1432 2010-06-25  Lyon Chen  <liachen@rim.com>
1433
1434         Reviewed by Darin Adler.
1435
1436         InspectorCSSStore.cpp is not surrounded with ENABLE(INSPECTOR)
1437         https://bugs.webkit.org/show_bug.cgi?id=41004
1438
1439         Surround InspectorCSSStore.cpp code with ENABLE(INSPECTOR) so it will not
1440         break the build when INSPECTOR is disabled.
1441
1442         * inspector/InspectorCSSStore.cpp:
1443
1444 2010-06-25  No'am Rosenthal  <noam.rosenthal@nokia.com>
1445
1446         Reviewed by Simon Hausmann.
1447
1448         [Qt] WebGL: missing file
1449         https://bugs.webkit.org/show_bug.cgi?id=40998
1450
1451         Added a missing file to WebCore.pro
1452
1453         No new tests; build fix
1454
1455         * WebCore.pro:
1456
1457 2010-06-25  Adam Roben  <aroben@apple.com>
1458
1459         Windows build fix
1460
1461         * WebCore.vcproj/WebCore.vcproj: Added a missing </File> tag.
1462
1463 2010-06-25  Alex Milowski  <alex@milowski.com>
1464
1465         Reviewed by Kenneth Rohde Christiansen.
1466
1467         This patch changes the vertical alignment to rely upon baseline
1468         alignment for all MathML rendering.  This fixes a number of layout
1469         issues and the implementation is much more clean.
1470
1471         Also, this patch adds a horizontal green line in the debug layout
1472         so you can see the top padding of any RenderMathMLBlock instance.
1473
1474         Test: mathml/presentation/row-alignment.xhtml
1475
1476         * css/mathml.css:
1477         * mathml/RenderMathMLBlock.cpp:
1478         * mathml/RenderMathMLFraction.cpp:
1479         * mathml/RenderMathMLFraction.h:
1480         * mathml/RenderMathMLOperator.cpp:
1481         * mathml/RenderMathMLOperator.h:
1482         * mathml/RenderMathMLRoot.cpp:
1483         * mathml/RenderMathMLRow.cpp:
1484         * mathml/RenderMathMLRow.h:
1485         * mathml/RenderMathMLSquareRoot.cpp:
1486         * mathml/RenderMathMLSubSup.cpp:
1487         * mathml/RenderMathMLUnderOver.cpp:
1488
1489 2010-06-25  Yury Semikhatsky  <yurys@chromium.org>
1490
1491         Reviewed by Pavel Feldman.
1492
1493         Can't see source when hitting debugger statement in evaled source
1494         https://bugs.webkit.org/show_bug.cgi?id=41058
1495
1496         Test: inspector/debugger-pause-in-eval-script.html
1497
1498         * bindings/js/ScriptDebugServer.cpp:
1499         (WebCore::ScriptDebugServer::sourceParsed): use lexical global object to figure out
1500         where the script is compiled. Otherwise scripts typed in Web Inspector console will
1501         be treated as ones evaluated in the context of Web Inspector and won't appear in the
1502         scripts list.
1503         * inspector/InspectorController.cpp:
1504         (WebCore::InspectorController::didParseSource): cache script sources for eval's too.
1505
1506 2010-06-25  Lucas De Marchi  <lucas.demarchi@profusion.mobi>
1507
1508         Reviewed by Kenneth Rohde Christiansen.
1509
1510         [EFL] Use a descriptive string in FileChooser when multiple files can
1511         be selected.
1512         https://bugs.webkit.org/show_bug.cgi?id=40943
1513
1514         EFL port has no tests yet, so no new tests.
1515
1516         * platform/efl/FileChooserEfl.cpp:
1517         (WebCore::FileChooser::basenameForWidth):
1518
1519 2010-06-25  Nikolas Zimmermann  <nzimmermann@rim.com>
1520
1521         Reviewed by Dirk Schulze.
1522
1523         SVG Text Highlighting not yet supported (in Safari)
1524         https://bugs.webkit.org/show_bug.cgi?id=41200
1525
1526         Add text match marker highlighting support for SVG text - searching for SVG text in Safari now paints the nice yellow highlighting rect, and the
1527         white rectangles for all text matches. Behaves exactly like HTML text, but respecting SVGs per-character/per-chunk transformations,
1528         allowing to highlight textPaths, tspans with absolute per-character positions etc..
1529
1530         Only manually testable, thus no new tests.
1531
1532         * rendering/InlineBox.h: Expose calculateBoundaries() in non-SVG builds as well, now used by InlineTextBox too.
1533         * rendering/InlineTextBox.h: Add calculateBoundaries(), which will be used to refactor some code in RenderText, see below.
1534         (WebCore::InlineTextBox::calculateBoundaries): Just return a IntRect(x(), y(), width(), height()) here.
1535         (WebCore::RenderObject::isSVGInlineText):
1536         * rendering/RenderSVGInlineText.h:
1537         (WebCore::RenderSVGInlineText::isSVGInlineText): Return true for isSVGInlineText(), return false for isSVGText() (default in RenderObject.h)
1538         * rendering/RenderSVGRoot.cpp:
1539         (WebCore::RenderSVGRoot::paint): Only paint box decorations in PaintPhase(Child)BlockBackground, exit afterwards just like RenderBlock does.
1540                                          Otherwise the white text match marker rectangle gets drawn over the yellow highlight that Safari draws. 
1541         * rendering/RenderSVGText.cpp:
1542         (WebCore::RenderSVGText::paint): Accept a new painting phase: PaintPhaseSelection, used by Safari when drawing the yellow highlight rect.
1543         * rendering/RenderText.cpp:
1544         (WebCore::RenderText::absoluteQuads): Use calculateBoundaries() instead of IntRect(x(), y(), width(), height()). SVG provides different boundaries here.
1545         (WebCore::RenderText::absoluteQuadsForRange): Ditto. This is the main change, leading to correct text highlight placement.
1546         * rendering/SVGInlineFlowBox.cpp: Add assertion that painting is not disabled, for consistency. Change paint phase assertion to include PaintPhaseSelection.
1547         (WebCore::SVGInlineFlowBox::paint):
1548         * rendering/SVGInlineTextBox.cpp:
1549         (WebCore::SVGInlineTextBox::selectionRectForTextChunkPart): Refactored from selectionRect(), to share code between selectionRect/computeTextMatchMarkerRect.
1550         (WebCore::SVGInlineTextBox::selectionRect): Use new helper function selectionRectForTextChunkPart().
1551         (WebCore::SVGInlineTextBox::paint): Ditto. Call new computeTextMatchMarkerRect() function.
1552         (WebCore::SVGInlineTextBox::computeTextMatchMarkerRect): Implemented similar to HTML, but respecting SVGs concept of text chunk parts.
1553         (WebCore::SVGInlineTextBox::paintText): In PaintPhaseSelection, only paint selected text, not anything before/after the selection start/end.
1554         (WebCore::SVGInlineTextBox::calculateBoundaries): Early exit, if m_chunkTransformation is identity.
1555         * rendering/SVGInlineTextBox.h: Added "bool paintSelectedTextOnly" to paintText() and add new computeTextMatchMarkerRect(RenderStyle*) function.
1556         * rendering/SVGRootInlineBox.cpp:
1557         (WebCore::SVGRootInlineBox::paint): Change paint phase assertion to include PaintPhaseSelection.
1558
1559 2010-06-25  John Gregg  <johnnyg@google.com>
1560
1561         Reviewed by Darin Fisher.
1562
1563         Notification should expose ltr/rtl as TextDirection, not String
1564         https://bugs.webkit.org/show_bug.cgi?id=40871
1565
1566         No new tests; existing test covers this, just renaming a method.
1567
1568         * notifications/Notification.h:
1569         (WebCore::Notification::direction):
1570
1571 2010-06-25  Sheriff Bot  <webkit.review.bot@gmail.com>
1572
1573         Unreviewed, rolling out r61842.
1574         http://trac.webkit.org/changeset/61842
1575         https://bugs.webkit.org/show_bug.cgi?id=41208
1576
1577         It broke Windows build (Requested by Ossy_ on #webkit).
1578
1579         * ForwardingHeaders/wtf/win/OwnPtrWin.h: Removed.
1580
1581 2010-06-25  Patrick Gansterer  <paroga@paroga.com>
1582
1583         Reviewed by Darin Adler.
1584
1585         Remove unneeded whitespace from svgtags.in.
1586         https://bugs.webkit.org/show_bug.cgi?id=40912
1587
1588         make_names.pl throws an error at non-empty lines
1589         when using cl.exe as preprocessor.
1590
1591         * svg/svgtags.in:
1592
1593 2010-06-25  Nikolas Zimmermann  <nzimmermann@rim.com>
1594
1595         Reviewed by Rob Buis.
1596
1597         Split up isSVGText() in isSVGText() / isSVGInlineText()
1598         https://bugs.webkit.org/show_bug.cgi?id=41204
1599
1600         Introduce isSVGInlineText(), to provide a safe mechanism to differentiate between RenderSVGText / RenderSVGInlineText.
1601         No change in functionality, thus no new tests.
1602
1603         * rendering/RenderBlockLineLayout.cpp:
1604         (WebCore::shouldPreserveNewline): s/isSVGText/isSVGInlineText/
1605         (WebCore::RenderBlock::findNextLineBreak): Ditto.
1606         * rendering/RenderObject.h:
1607         (WebCore::RenderObject::isSVGInlineText): Return false, by default.
1608         * rendering/RenderSVGInlineText.h:
1609         (WebCore::RenderSVGInlineText::isSVGInlineText): Return true here, don't return true anymore for isSVGText().
1610         * rendering/RenderText.cpp:
1611         (WebCore::RenderText::setTextInternal): s/isSVGText/isSVGInlineText/
1612         * rendering/RenderTreeAsText.cpp: Remove hack, now that we can properly differentiate between RenderSVGText / RenderSVGInlineText.
1613         (WebCore::write):
1614
1615 2010-06-25  Kwang Yul Seo  <skyul@company100.net>
1616
1617         Reviewed by Adam Barth.
1618
1619         Change OwnPtrCommon to include platform-specific headers
1620         https://bugs.webkit.org/show_bug.cgi?id=40279
1621
1622         Adding new type to OwnPtrCommon needlessly causes all ports to do full rebuilds.
1623         Change OwnPtrCommon to include platform-specific headers to avoid all ports rebuilds.
1624
1625         * ForwardingHeaders/wtf/win: Added.
1626         * ForwardingHeaders/wtf/win/OwnPtrWin.h: Added.
1627
1628 2010-06-25  Patrick Gansterer  <paroga@paroga.com>
1629
1630         Reviewed by Adam Barth.
1631
1632         Implement TextCodecs for WinCE port.
1633         https://bugs.webkit.org/show_bug.cgi?id=32169
1634         Originally written by Yong Li <yong.li@torchmobile.com>
1635
1636         * platform/graphics/FontCache.h:
1637         * platform/graphics/wince/FontCacheWince.cpp:
1638         (WebCore::FontCache::getMultiLanguageInterface):
1639         * platform/text/wince/TextCodecWinCE.cpp: Added.
1640         (WebCore::codePageCharsets):
1641         (WebCore::knownCharsets):
1642         (WebCore::supportedCharsets):
1643         (WebCore::languageManager):
1644         (WebCore::addCharset):
1645         (WebCore::LanguageManager::LanguageManager):
1646         (WebCore::getCodePage):
1647         (WebCore::newTextCodecWinCE):
1648         (WebCore::TextCodecWinCE::TextCodecWinCE):
1649         (WebCore::TextCodecWinCE::~TextCodecWinCE):
1650         (WebCore::TextCodecWinCE::registerBaseEncodingNames):
1651         (WebCore::TextCodecWinCE::registerBaseCodecs):
1652         (WebCore::TextCodecWinCE::registerExtendedEncodingNames):
1653         (WebCore::TextCodecWinCE::registerExtendedCodecs):
1654         (WebCore::getCodePageFlags):
1655         (WebCore::findFirstNonAsciiCharacter):
1656         (WebCore::decode):
1657         (WebCore::TextCodecWinCE::decode):
1658         (WebCore::TextCodecWinCE::encode):
1659         (WebCore::TextCodecWinCE::enumerateSupportedEncodings):
1660         * platform/text/wince/TextCodecWinCE.h: Added.
1661
1662 2010-06-24  Rob Buis  <rwlbuis@gmail.com>
1663
1664         Reviewed by Dirk Schulze.
1665
1666         Bug 40880 - SVG properties fill and stroke do not accept system colors
1667         https://bugs.webkit.org/show_bug.cgi?id=40880
1668
1669         Handle css system colors in fill and stroke properties.
1670
1671         Test: svg/css/rect-system-color.xhtml
1672
1673         * css/CSSParser.cpp: Remove comment and unneeded if condition
1674         (WebCore::CSSParser::parseValue):
1675         * css/SVGCSSParser.cpp: Allow css system colors
1676         (WebCore::CSSParser::parseSVGValue):
1677
1678 2010-06-24  Eric Seidel  <eric@webkit.org>
1679
1680         Reviewed by Adam Barth.
1681
1682         Make DocumentParser API private on subclasses to catch misuse bugs
1683         https://bugs.webkit.org/show_bug.cgi?id=41186
1684
1685         This already found one bug:
1686         https://bugs.webkit.org/show_bug.cgi?id=41187
1687
1688         Added a new HTMLDocumentParaser::parseDocumentFragment so that
1689         DocumentFragment.cpp does not need to use private methods.
1690
1691         * dom/DocumentFragment.cpp:
1692         (WebCore::DocumentFragment::parseHTML):
1693         * dom/XMLDocumentParser.h:
1694         (WebCore::XMLDocumentParser::setIsXHTMLDocument):
1695         (WebCore::XMLDocumentParser::isXHTMLDocument):
1696         (WebCore::XMLDocumentParser::setIsXHTMLMPDocument):
1697         (WebCore::XMLDocumentParser::isXHTMLMPDocument):
1698         * html/HTMLDocumentParser.cpp:
1699         (WebCore::HTMLDocumentParser::parseDocumentFragment):
1700         * html/HTMLDocumentParser.h:
1701         * html/LegacyHTMLDocumentParser.cpp:
1702         (WebCore::LegacyHTMLDocumentParser::parseDocumentFragment):
1703         * html/LegacyHTMLDocumentParser.h:
1704         (WebCore::LegacyHTMLDocumentParser::forceSynchronous):
1705         (WebCore::LegacyHTMLDocumentParser::processingContentWrittenByScript):
1706         * html/LegacyHTMLTreeBuilder.cpp:
1707         (WebCore::LegacyHTMLTreeBuilder::reportErrorToConsole):
1708         * loader/DocumentWriter.cpp:
1709         (WebCore::DocumentWriter::replaceDocument):
1710         * loader/TextDocument.cpp:
1711
1712 2010-05-28  Philippe Normand  <pnormand@igalia.com>
1713
1714         Reviewed by Gustavo Noronha.
1715
1716         [GStreamer] multiple video sink support
1717         https://bugs.webkit.org/show_bug.cgi?id=39472
1718
1719         Playbin2 video-sink is now a bin containing a tee element capable
1720         of dispatching the buffers to multiple video sinks. By default
1721         only our webkit video sink is used. This will allow
1722         GStreamerGWorld to add support for autovideosink in the future.
1723
1724         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
1725         (WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer):
1726         (WebCore::MediaPlayerPrivateGStreamer::~MediaPlayerPrivateGStreamer):
1727         (WebCore::MediaPlayerPrivateGStreamer::naturalSize):
1728         (WebCore::MediaPlayerPrivateGStreamer::createGSTPlayBin):
1729         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
1730
1731 2010-06-24  Adam Barth  <abarth@webkit.org>
1732
1733         Reviewed by Eric Seidel.
1734
1735         Sketch out AfterHeadMode for tree builder
1736         https://bugs.webkit.org/show_bug.cgi?id=41191
1737
1738         This mode is fairly similar to the others.  I needed to change some of
1739         the types around w.r.t. Nodes/Elements.
1740
1741         * html/HTMLTreeBuilder.cpp:
1742         (WebCore::HTMLTreeBuilder::HTMLTreeBuilder):
1743         (WebCore::HTMLTreeBuilder::processToken):
1744         (WebCore::HTMLTreeBuilder::insertElement):
1745         * html/HTMLTreeBuilder.h:
1746         (WebCore::HTMLTreeBuilder::ElementStack::push):
1747         (WebCore::HTMLTreeBuilder::ElementStack::remove):
1748
1749 2010-06-24  Adam Barth  <abarth@webkit.org>
1750
1751         Reviewed by Eric Seidel.
1752
1753         Sketch out InHeadNoscriptMode for tree builder
1754         https://bugs.webkit.org/show_bug.cgi?id=41189
1755
1756         Lots of notImplemented() calls in this state.  I need to figure how to
1757         delegate handling of a token from one state to another.
1758
1759         * html/HTMLTreeBuilder.cpp:
1760         (WebCore::HTMLTreeBuilder::processToken):
1761
1762 2010-06-24  Adam Barth  <abarth@webkit.org>
1763
1764         Reviewed by Eric Seidel.
1765
1766         Sketch out InHeadMode for tree builder
1767         https://bugs.webkit.org/show_bug.cgi?id=41184
1768
1769         This state is relatively straightforward.  We introduce the stack of
1770         open elements to track that notion in the spec.  The old tree builder
1771         has a nice data structure for that, which we'll probably steal, but I'd
1772         like to see what the full API is first.
1773
1774         * html/HTMLTreeBuilder.cpp:
1775         (WebCore::HTMLTreeBuilder::processToken):
1776         (WebCore::HTMLTreeBuilder::insertCharacter):
1777         (WebCore::HTMLTreeBuilder::insertGenericRCDATAElement):
1778         (WebCore::HTMLTreeBuilder::insertGenericRawTextElement):
1779         (WebCore::HTMLTreeBuilder::insertScriptElement):
1780         * html/HTMLTreeBuilder.h:
1781         (WebCore::HTMLTreeBuilder::ElementStack::pop):
1782         (WebCore::HTMLTreeBuilder::ElementStack::top):
1783
1784 2010-06-24  Adam Barth  <abarth@webkit.org>
1785
1786         Reviewed by Eric Seidel.
1787
1788         Sketch out BeforeHeadMode tree builder state
1789         https://bugs.webkit.org/show_bug.cgi?id=41183
1790
1791         This makes procesToken recursive, which might not be the best idea.
1792         Also, we can now make fake AtomicHTMLTokens for use by the algorithm.
1793
1794         * html/HTMLToken.h:
1795         (WebCore::AtomicHTMLToken::AtomicHTMLToken):
1796         * html/HTMLTreeBuilder.cpp:
1797         (WebCore::HTMLTreeBuilder::processToken):
1798         (WebCore::HTMLTreeBuilder::insertElement):
1799         * html/HTMLTreeBuilder.h:
1800
1801 2010-06-22 Antonio Gomes <tonikitoo@webkit.org>
1802
1803         Reviewed by David Hyatt.
1804
1805         Add a NodeList-derivated wrapper class for a ListHashSet.
1806         https://bugs.webkit.org/show_bug.cgi?id=41081
1807
1808         StaticHashSetList will work as a wrapper to ListHashSet objects that are
1809         aimed to be exposed to the DOM.
1810
1811         As a use case, the rect based HitTest (bug 40197) will store the retrieved nodes
1812         in a ListHashSet. It is going to be exposed to the DOM through are nodesFromRect
1813         of Document returning a NodeList (i.e. StatisHashSetList) wrapping a ListHashSet.
1814
1815         No new tests.
1816
1817 2010-06-24  Cris Neckar  <cdn@chromium.org>
1818
1819         Reviewed by Darin Fisher.
1820
1821         [Chromium] Out of bounds write in WebCore::PNGImageDecoder::rowAvailable
1822         https://bugs.webkit.org/show_bug.cgi?id=40798
1823
1824         Catches error in row callback for libPNG when extra rows are returned.
1825
1826         Test: fast/images/png-extra-row-crash.html
1827
1828         * platform/image-decoders/png/PNGImageDecoder.cpp:
1829         (WebCore::PNGImageDecoder::rowAvailable):
1830
1831 2010-06-24  Eric Seidel  <eric@webkit.org>
1832
1833         Reviewed by Adam Barth.
1834
1835         Clean up and document DocumentWriter::replaceDocument code path
1836         https://bugs.webkit.org/show_bug.cgi?id=41182
1837
1838         No functional changes, thus no tests.
1839
1840         * loader/DocumentWriter.cpp:
1841         (WebCore::DocumentWriter::replaceDocument):
1842          - Remove comment which could be misleading.
1843
1844 2010-06-23  Dumitru Daniliuc  <dumi@chromium.org>
1845
1846         Reviewed by Adam Barth.
1847
1848         Implementing DatabaseSync::openDatabaseSync().
1849         https://bugs.webkit.org/show_bug.cgi?id=40607
1850
1851         Moved some common code from Database to AbstractDatabase. Made
1852         performOpenAndVerify() virtual, since DatabaseSync doesn't need to
1853         interact with DatabaseThread. Removed the m_creationCallback
1854         field, since it's only needed in the openDatabase{Sync} methods.
1855
1856         * storage/AbstractDatabase.cpp:
1857         (WebCore::retrieveTextResultFromDatabase):
1858         (WebCore::setTextValueInDatabase):
1859         (WebCore::guidMutex):
1860         (WebCore::guidToVersionMap):
1861         (WebCore::updateGuidVersionMap):
1862         (WebCore::guidToDatabaseMap):
1863         (WebCore::guidForOriginAndName):
1864         (WebCore::AbstractDatabase::databaseInfoTableName):
1865         (WebCore::AbstractDatabase::AbstractDatabase):
1866         (WebCore::AbstractDatabase::closeDatabase):
1867         (WebCore::AbstractDatabase::version):
1868         (WebCore::AbstractDatabase::performOpenAndVerify):
1869         (WebCore::AbstractDatabase::scriptExecutionContext):
1870         (WebCore::AbstractDatabase::securityOrigin):
1871         (WebCore::AbstractDatabase::stringIdentifier):
1872         (WebCore::AbstractDatabase::displayName):
1873         (WebCore::AbstractDatabase::estimatedSize):
1874         (WebCore::AbstractDatabase::fileName):
1875         (WebCore::AbstractDatabase::databaseVersionKey):
1876         (WebCore::AbstractDatabase::getVersionFromDatabase):
1877         (WebCore::AbstractDatabase::setVersionInDatabase):
1878         (WebCore::AbstractDatabase::versionMatchesExpected):
1879         (WebCore::AbstractDatabase::setExpectedVersion):
1880         (WebCore::AbstractDatabase::disableAuthorizer):
1881         (WebCore::AbstractDatabase::enableAuthorizer):
1882         (WebCore::AbstractDatabase::setAuthorizerReadOnly):
1883         (WebCore::AbstractDatabase::lastActionChangedDatabase):
1884         (WebCore::AbstractDatabase::lastActionWasInsert):
1885         (WebCore::AbstractDatabase::resetDeletes):
1886         (WebCore::AbstractDatabase::hadDeletes):
1887         (WebCore::AbstractDatabase::resetAuthorizer):
1888         * storage/AbstractDatabase.h:
1889         (WebCore::AbstractDatabase::opened):
1890         (WebCore::AbstractDatabase::isNew):
1891         (WebCore::AbstractDatabase::databaseDebugName):
1892         * storage/Database.cpp:
1893         (WebCore::DatabaseCreationCallbackTask::create):
1894         (WebCore::DatabaseCreationCallbackTask::performTask):
1895         (WebCore::DatabaseCreationCallbackTask::DatabaseCreationCallbackTask):
1896         (WebCore::Database::openDatabase):
1897         (WebCore::Database::Database):
1898         (WebCore::Database::version):
1899         (WebCore::Database::openAndVerifyVersion):
1900         (WebCore::Database::close):
1901         (WebCore::Database::stop):
1902         (WebCore::Database::performOpenAndVerify):
1903         * storage/Database.h:
1904         (WebCore::Database::sqliteDatabase):
1905         * storage/DatabaseAuthorizer.cpp:
1906         (WebCore::DatabaseAuthorizer::create):
1907         (WebCore::DatabaseAuthorizer::DatabaseAuthorizer):
1908         (WebCore::DatabaseAuthorizer::denyBasedOnTableName):
1909         * storage/DatabaseAuthorizer.h:
1910         * storage/DatabaseSync.cpp:
1911         (WebCore::DatabaseSync::openDatabaseSync):
1912         (WebCore::DatabaseSync::DatabaseSync):
1913         (WebCore::DatabaseSync::changeVersion):
1914         (WebCore::DatabaseSync::transaction):
1915         (WebCore::DatabaseSync::markAsDeletedAndClose):
1916         (WebCore::CloseSyncDatabaseOnContextThreadTask::create):
1917         (WebCore::CloseSyncDatabaseOnContextThreadTask::performTask):
1918         (WebCore::CloseSyncDatabaseOnContextThreadTask::CloseSyncDatabaseOnContextThreadTask):
1919         (WebCore::DatabaseSync::closeImmediately):
1920         * storage/DatabaseSync.h:
1921         * storage/DatabaseTask.cpp:
1922         (WebCore::DatabaseOpenTask::DatabaseOpenTask):
1923         (WebCore::DatabaseOpenTask::doPerformTask):
1924         * storage/DatabaseTask.h:
1925         (WebCore::DatabaseOpenTask::create):
1926
1927 2010-06-24  Steve Falkenburg  <sfalken@apple.com>
1928
1929         Windows build fix.
1930
1931         * platform/network/cf/AuthenticationCF.h:
1932
1933 2010-06-24  Martin Robinson  <mrobinson@igalia.com>
1934
1935         Unreviewed. Build fix.
1936
1937         Fix the build after r61798.
1938
1939         * platform/gtk/PasteboardHelper.cpp:
1940         (WebCore::PasteboardHelper::getClipboardContents):
1941
1942 2010-06-24  Alexey Proskuryakov  <ap@apple.com>
1943
1944         Reviewed by Brady Eidson.
1945
1946         https://bugs.webkit.org/show_bug.cgi?id=41178
1947         Timed refresh in subframes isn't stopped when going into b/f cache
1948
1949         Test: fast/history/timed-refresh-in-cached-frame.html
1950
1951         * history/CachedFrame.cpp: (WebCore::CachedFrame::CachedFrame): Top frame's stopLoading()
1952         won't help cached subframes; stop loading from here.
1953
1954         * loader/FrameLoader.cpp:
1955         (WebCore::FrameLoader::stopLoading): Don't stop loading in child frames. This didn't work
1956         for cached frames due to frame tree having been already desonstructed, and it's not necessary
1957         in non-cached case because stopLoading() will be called for subframes via
1958         FrameLoader::detachFromParent() and closeURL().
1959         (WebCore::FrameLoader::pageHidden): This was a second code path that dispatched pagehide
1960         event - it's no longer needed, because everything goes through FrameLoader::stopLoading().
1961         (WebCore::FrameLoader::commitProvisionalLoad): Don't call pageHidden(), the code for adding
1962         frame to b/f cache will do everything.
1963
1964         * loader/FrameLoader.h: Removed pageHidden().
1965
1966 2010-06-24  Eric Seidel  <eric@webkit.org>
1967
1968         Unreviewed. Fix the build.  I am a bad man.
1969
1970         * loader/DocumentWriter.cpp:
1971         (WebCore::DocumentWriter::replaceDocument):
1972
1973 2010-06-24  Martin Robinson  <mrobinson@igalia.com>
1974
1975         Reviewed by Xan Lopez.
1976
1977         Build fix for building against GTK+ 3.x.
1978
1979         No new tests as functionality has not changed.
1980
1981         * platform/gtk/GtkVersioning.h:
1982         * platform/gtk/PasteboardHelper.cpp:
1983         (WebCore::PasteboardHelper::getClipboardContents):
1984         (WebCore::PasteboardHelper::fillSelectionData):
1985
1986 2010-06-24  Eric Seidel  <eric@webkit.org>
1987
1988         Reviewed by Adam Barth.
1989
1990         Clean up and document DocumentWriter::replaceDocument code path
1991         https://bugs.webkit.org/show_bug.cgi?id=41182
1992
1993         No functional change, thus no test.
1994
1995         * loader/DocumentWriter.cpp:
1996         (WebCore::DocumentWriter::replaceDocument):
1997         * loader/DocumentWriter.h:
1998
1999 2010-06-24  Jer Noble  <jer.noble@apple.com>
2000
2001         Reviewed by Eric Carlson.
2002
2003         Full-screened content doesn't keep the display on: Safari not grabbing a power assertion?
2004         https://bugs.webkit.org/show_bug.cgi?id=40939
2005         rdar://problem/7996172
2006         
2007         Export -[MediaElement playbackRate];
2008         
2009         * WebCore.Video.exp:
2010
2011 2010-06-21  Evan Martin  <evan@chromium.org>
2012
2013         Reviewed by Adam Barth.
2014
2015         [chromium] overlapping characters in complex text
2016         https://bugs.webkit.org/show_bug.cgi?id=40966
2017
2018         We need to clear all the buffers we hand to Harfbuzz before we use them.
2019         While I'm here, refactor the code slightly to make its behavior more
2020         clear and correct (previously, we would repeatedly double our buffer
2021         size when we could have just sized it correctly on the second try).
2022
2023         * platform/graphics/chromium/FontLinux.cpp:
2024         (WebCore::TextRunWalker::TextRunWalker):
2025         (WebCore::TextRunWalker::nextScriptRun):
2026         (WebCore::TextRunWalker::createGlyphArrays):
2027         (WebCore::TextRunWalker::shapeGlyphs):
2028
2029 2010-06-24  Adele Peterson  <adele@apple.com>
2030
2031         Reviewed by Sam Weinig.
2032
2033         Updated fix for <rdar://problem/8093680> "Paste and Match Style" should fire paste events
2034         https://bugs.webkit.org/show_bug.cgi?id=41085
2035
2036         Covered by existing tests.
2037
2038         * editing/EditorCommand.cpp:
2039         (WebCore::executePasteAsPlainText): Added.
2040         (WebCore::createCommandMap): Added pasteAsPlainText command.
2041
2042 2010-06-24  Adam Barth  <abarth@webkit.org>
2043
2044         Reviewed by Eric Seidel.
2045
2046         Sketch out BeforeHTMLMode state
2047         https://bugs.webkit.org/show_bug.cgi?id=41133
2048
2049         In this patch, we switch the TreeBuidler over to using AtomicHTMLTokens
2050         and sketch out another state.  These states don't actually do anything
2051         yet, I'm still just getting the structure of the spec into the code so
2052         we can implement the details incrementally.
2053
2054         * html/HTMLTreeBuilder.cpp:
2055         (WebCore::HTMLTreeBuilder::constructTreeFromToken):
2056         (WebCore::HTMLTreeBuilder::processToken):
2057         (WebCore::HTMLTreeBuilder::insertDoctype):
2058         (WebCore::HTMLTreeBuilder::insertComment):
2059         * html/HTMLTreeBuilder.h:
2060         (WebCore::HTMLTreeBuilder::parseError):
2061
2062 2010-06-24  Adam Barth  <abarth@webkit.org>
2063
2064         Reviewed by Eric Seidel.
2065
2066         Add AtomicHTMLToken
2067         https://bugs.webkit.org/show_bug.cgi?id=41131
2068
2069         We need an atomized version of the token for use in the tree builder.
2070         Eventually, we should make the existing HTMLToken an internal detail of
2071         the HTMLTokenizer.  This new AtomicHTMLToken should be also be more
2072         easily cached between the preload scanner and the tree builder.
2073
2074         * html/HTMLToken.h:
2075         (WebCore::AtomicHTMLToken::AtomicHTMLToken):
2076         (WebCore::AtomicHTMLToken::type):
2077         (WebCore::AtomicHTMLToken::name):
2078         (WebCore::AtomicHTMLToken::selfClosing):
2079         (WebCore::AtomicHTMLToken::attributes):
2080         (WebCore::AtomicHTMLToken::characters):
2081         (WebCore::AtomicHTMLToken::comment):
2082         (WebCore::AtomicHTMLToken::publicIdentifier):
2083         (WebCore::AtomicHTMLToken::systemIdentifier):
2084         (WebCore::AtomicHTMLToken::forceQuirks):
2085         * html/HTMLTreeBuilder.cpp:
2086         (WebCore::convertToOldStyle):
2087         (WebCore::HTMLTreeBuilder::passTokenToLegacyParser):
2088
2089 2010-06-24  Eric Seidel  <eric@webkit.org>
2090
2091         Reviewed by Adam Barth.
2092
2093         Add RawDataDocumentParser to get rid of a bunch of copy/paste code in DocumentParser subclasses
2094         https://bugs.webkit.org/show_bug.cgi?id=41136
2095
2096         I think this is likely far from the final design,
2097         however this is almost entirely minus lines which is a
2098         good thing.
2099
2100         The original authors of these DocumentParser subclasses
2101         seem to have just copied the files whole, as they all
2102         had the same includes, many of which were unnecessary for
2103         some of the files.
2104
2105         I think eventually the FrameLoader will call a virtual
2106         DocumentParser::appendData which will in turn decode
2107         and call another write/appendData call.  In the case
2108         of these RawDataDocumentParsers, they will just override
2109         the low-level appendData call instead of needing
2110         DocumentWriter to have a special if based on
2111         DocumentParser::wantsRawData.
2112
2113         No functional change, thus no tests.
2114
2115         * GNUmakefile.am:
2116         * WebCore.gypi:
2117         * WebCore.pro:
2118         * WebCore.xcodeproj/project.pbxproj:
2119         * dom/DocumentParser.h:
2120         (WebCore::DocumentParser::writeRawData):
2121         * loader/ImageDocument.cpp:
2122         (WebCore::ImageDocumentParser::ImageDocumentParser):
2123         (WebCore::ImageDocumentParser::finish):
2124         * loader/MediaDocument.cpp:
2125         (WebCore::MediaDocumentParser::MediaDocumentParser):
2126         (WebCore::MediaDocumentParser::writeRawData):
2127         * loader/PluginDocument.cpp:
2128         (WebCore::PluginDocumentParser::PluginDocumentParser):
2129         * loader/SinkDocument.cpp:
2130         (WebCore::SinkDocument::createParser):
2131
2132 2010-06-23  Peter Kasting  <pkasting@google.com>
2133
2134         Reviewed by Adam Barth.
2135
2136         REGRESSION (r61619): Memory corruption in open-source ICO decoder
2137         https://bugs.webkit.org/show_bug.cgi?id=41107
2138
2139         * platform/image-decoders/bmp/BMPImageReader.cpp:
2140         (WebCore::BMPImageReader::processInfoHeader): Fix memory corruption.
2141         * platform/image-decoders/ico/ICOImageDecoder.cpp:
2142         (WebCore::ICOImageDecoder::processDirectoryEntries): Handle sizing failure correctly (though failure should be impossible).
2143
2144 2010-06-24  Sheriff Bot  <webkit.review.bot@gmail.com>
2145
2146         Unreviewed, rolling out r61783.
2147         http://trac.webkit.org/changeset/61783
2148         https://bugs.webkit.org/show_bug.cgi?id=41179
2149
2150         Caused a couple of test failures (Requested by japhet on
2151         #webkit).
2152
2153         * dom/DOMImplementation.cpp:
2154         (WebCore::DOMImplementation::createDocument):
2155         (WebCore::DOMImplementation::createHTMLDocument):
2156         * dom/DOMImplementation.h:
2157         * dom/Document.cpp:
2158         (WebCore::Document::Document):
2159         (WebCore::Document::initSecurityContext):
2160         * dom/Document.h:
2161         (WebCore::Document::create):
2162         (WebCore::Document::createXHTML):
2163         * html/HTMLDocument.cpp:
2164         (WebCore::HTMLDocument::HTMLDocument):
2165         * html/HTMLDocument.h:
2166         (WebCore::HTMLDocument::create):
2167         * html/HTMLViewSourceDocument.cpp:
2168         (WebCore::HTMLViewSourceDocument::HTMLViewSourceDocument):
2169         * html/HTMLViewSourceDocument.h:
2170         (WebCore::HTMLViewSourceDocument::create):
2171         * loader/CachedFont.cpp:
2172         (WebCore::CachedFont::ensureSVGFontData):
2173         * loader/DocumentWriter.cpp:
2174         (WebCore::DocumentWriter::createDocument):
2175         (WebCore::DocumentWriter::begin):
2176         * loader/DocumentWriter.h:
2177         * loader/FTPDirectoryDocument.cpp:
2178         (WebCore::FTPDirectoryDocument::FTPDirectoryDocument):
2179         * loader/FTPDirectoryDocument.h:
2180         (WebCore::FTPDirectoryDocument::create):
2181         * loader/ImageDocument.cpp:
2182         (WebCore::ImageDocument::ImageDocument):
2183         * loader/ImageDocument.h:
2184         (WebCore::ImageDocument::create):
2185         * loader/MediaDocument.cpp:
2186         (WebCore::MediaDocument::MediaDocument):
2187         * loader/MediaDocument.h:
2188         (WebCore::MediaDocument::create):
2189         * loader/PlaceholderDocument.h:
2190         (WebCore::PlaceholderDocument::create):
2191         (WebCore::PlaceholderDocument::PlaceholderDocument):
2192         * loader/PluginDocument.cpp:
2193         (WebCore::PluginDocument::PluginDocument):
2194         * loader/PluginDocument.h:
2195         (WebCore::PluginDocument::create):
2196         * loader/SinkDocument.cpp:
2197         (WebCore::SinkDocument::SinkDocument):
2198         * loader/SinkDocument.h:
2199         (WebCore::SinkDocument::create):
2200         * loader/TextDocument.cpp:
2201         (WebCore::TextDocument::TextDocument):
2202         * loader/TextDocument.h:
2203         (WebCore::TextDocument::create):
2204         * svg/SVGDocument.cpp:
2205         (WebCore::SVGDocument::SVGDocument):
2206         * svg/SVGDocument.h:
2207         (WebCore::SVGDocument::create):
2208         * xml/DOMParser.cpp:
2209         (WebCore::DOMParser::parseFromString):
2210         * xml/XMLHttpRequest.cpp:
2211         (WebCore::XMLHttpRequest::responseXML):
2212         * xml/XSLTProcessor.cpp:
2213         (WebCore::XSLTProcessor::createDocumentFromSource):
2214
2215 2010-06-24  Martin Robinson  <mrobinson@igalia.com>
2216
2217         Reviewed by Xan Lopez.
2218
2219         [GTK] Small code cleanup in RenderThemeGtk
2220         https://bugs.webkit.org/show_bug.cgi?id=40989
2221
2222         Reduce the amount of duplicated code slightly and prepare this section for
2223         future improvements, such as sharing the clipping rectangle calculation with
2224         the slow path.
2225
2226         No new tests as functionality has not changed.
2227
2228         * platform/gtk/RenderThemeGtk.cpp:
2229         (WebCore::paintMozillaGtkWidget): Small code cleanup.
2230
2231 2010-06-24  Nate Chapin  <japhet@chromium.org>
2232
2233         Reviewed by Adam Barth.
2234
2235         Take a KURL parameter in Document's constructor.
2236         This will remove the one case where Document::url() 
2237         and FrameLoader::url() are not equal, allowing us to
2238         remove FrameLoader::url().
2239
2240         https://bugs.webkit.org/show_bug.cgi?id=41166
2241
2242         Refactor only, no new tests.
2243
2244         * dom/DOMImplementation.cpp:
2245         (WebCore::DOMImplementation::createDocument): Take a KURL and pass it through to Document.
2246         (WebCore::DOMImplementation::createHTMLDocument):
2247         * dom/DOMImplementation.h:
2248         * dom/Document.cpp:
2249         (WebCore::Document::Document): Call setURL() for non-empty KURL input parameters.
2250         (WebCore::Document::initSecurityContext): m_url is now initialized, so use it instead
2251             of m_frame->loader()->url() for initializing the SecurityOrigin.
2252         * dom/Document.h:
2253         (WebCore::Document::create):
2254         (WebCore::Document::createXHTML):
2255         * html/HTMLDocument.cpp:
2256         * html/HTMLDocument.h: Add KURL parameter to create() and constructor.
2257         * html/HTMLViewSourceDocument.cpp:
2258         * html/HTMLViewSourceDocument.h: Add KURL parameter to create() and constructor.
2259         * loader/CachedFont.cpp:
2260         (WebCore::CachedFont::ensureSVGFontData):
2261         * loader/DocumentWriter.cpp:
2262         (WebCore::DocumentWriter::createDocument): Take a KURL and pass it through to Document.
2263         (WebCore::DocumentWriter::begin): Pass existing url parameter to constructors, and remove
2264             redundant Document::setURL() call.
2265         * loader/DocumentWriter.h:
2266         * loader/FTPDirectoryDocument.cpp:
2267         * loader/FTPDirectoryDocument.h: Add KURL parameter to create() and constructor.
2268         * loader/ImageDocument.cpp:
2269         * loader/ImageDocument.h: Add KURL parameter to create() and constructor.
2270         * loader/MediaDocument.cpp:
2271         * loader/MediaDocument.h: Add KURL parameter to create() and constructor.
2272         * loader/PlaceholderDocument.h: Add KURL parameter to create() and constructor.
2273         * loader/PluginDocument.cpp:
2274         * loader/PluginDocument.h: Add KURL parameter to create() and constructor.
2275         * loader/SinkDocument.cpp:
2276         * loader/SinkDocument.h: Add KURL parameter to create() and constructor.
2277         * loader/TextDocument.cpp:
2278         * loader/TextDocument.h: Add KURL parameter to create() and constructor.
2279         * svg/SVGDocument.cpp:
2280         * svg/SVGDocument.h: Add KURL parameter to create() and constructor.
2281         * xml/DOMParser.cpp:
2282         (WebCore::DOMParser::parseFromString):
2283         * xml/XMLHttpRequest.cpp:
2284         (WebCore::XMLHttpRequest::responseXML):
2285         * xml/XSLTProcessor.cpp:
2286         (WebCore::XSLTProcessor::createDocumentFromSource):
2287
2288 2010-06-24  Brady Eidson  <beidson@apple.com>
2289
2290         Reviewed by Sam Weinig.
2291
2292         <rdar://problem/8044645> and https://bugs.webkit.org/show_bug.cgi?id=41082
2293
2294         Webarchives will null main resource cause a repro crash.
2295
2296         Test: webarchive/loading/mainresource-null-mimetype-crash.html
2297
2298         * loader/archive/cf/LegacyWebArchive.cpp:
2299         (WebCore::LegacyWebArchive::createResource): Fail to create the archive resource if the main resource's
2300           mime type is null.
2301
2302 2010-06-24  Damian Kaleta  <dkaleta@apple.com>
2303
2304         Reviewed by Sam Weinig.
2305
2306         Provide a way to obtain the rendered rectangle for box elements.
2307
2308         * WebCore.base.exp: Export the symbol so we can see it in WebKit.
2309         * dom/Node.cpp:
2310         (WebCore::Node::renderRect): Added new ethod that will return a rendered rectangle for box elements.
2311         * dom/Node.h: Ditto.
2312
2313 2010-06-24  Vangelis Kokkevis  <vangelis@chromium.org>
2314
2315         Reviewed by Darin Fisher.
2316
2317         [Chromium] Create specialized classes for Transform,
2318         Image and WebGL layers to replace the rather monolithic LayerChromium class.
2319         Layers can now own the GL texture they use for backing store and a different
2320         shading program can be used by the compositor for each layer type. WebGL layers
2321         are not yet hooked up to GraphicsContext3D.
2322         https://bugs.webkit.org/show_bug.cgi?id=41106
2323
2324         * WebCore.gypi:
2325         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
2326         (WebCore::GraphicsLayerChromium::GraphicsLayerChromium):
2327         (WebCore::GraphicsLayerChromium::setContentsToImage):
2328         (WebCore::GraphicsLayerChromium::updateLayerPreserves3D):
2329         * platform/graphics/chromium/GraphicsLayerChromium.h:
2330         (WebCore::GraphicsLayerChromium::):
2331         * platform/graphics/chromium/ImageLayerChromium.cpp: Added.
2332         (WebCore::ImageLayerChromium::create):
2333         (WebCore::ImageLayerChromium::ImageLayerChromium):
2334         (WebCore::ImageLayerChromium::setContents):
2335         (WebCore::ImageLayerChromium::updateTextureContents):
2336         * platform/graphics/chromium/ImageLayerChromium.h: Added.
2337         (WebCore::ImageLayerChromium::drawsContent):
2338         * platform/graphics/chromium/LayerChromium.cpp:
2339         (WebCore::LayerChromium::create):
2340         (WebCore::LayerChromium::LayerChromium):
2341         (WebCore::LayerChromium::updateTextureContents):
2342         (WebCore::LayerChromium::updateTextureRect):
2343         * platform/graphics/chromium/LayerChromium.h:
2344         (WebCore::LayerChromium::drawsContent):
2345         (WebCore::LayerChromium::ownsTexture):
2346         (WebCore::LayerChromium::textureId):
2347         (WebCore::LayerChromium::setShaderProgramId):
2348         (WebCore::LayerChromium::shaderProgramId):
2349         * platform/graphics/chromium/LayerRendererChromium.cpp:
2350         (WebCore::LayerRendererChromium::createLayerShader):
2351         (WebCore::ShaderProgram::ShaderProgram):
2352         (WebCore::LayerRendererChromium::LayerRendererChromium):
2353         (WebCore::LayerRendererChromium::~LayerRendererChromium):
2354         (WebCore::LayerRendererChromium::useShaderProgram):
2355         (WebCore::LayerRendererChromium::drawTexturedQuad):
2356         (WebCore::LayerRendererChromium::drawLayers):
2357         (WebCore::LayerRendererChromium::drawDebugBorder):
2358         (WebCore::LayerRendererChromium::updateLayersRecursive):
2359         (WebCore::LayerRendererChromium::drawLayer):
2360         (WebCore::LayerRendererChromium::bindCommonAttribLocations):
2361         (WebCore::LayerRendererChromium::initializeSharedGLObjects):
2362         * platform/graphics/chromium/LayerRendererChromium.h:
2363         (WebCore::LayerRendererChromium::):
2364         * platform/graphics/chromium/TransformLayerChromium.cpp: Added.
2365         (WebCore::TransformLayerChromium::create):
2366         (WebCore::TransformLayerChromium::TransformLayerChromium):
2367         * platform/graphics/chromium/TransformLayerChromium.h: Added.
2368         (WebCore::TransformLayerChromium::drawsContent):
2369         * platform/graphics/chromium/WebGLLayerChromium.cpp: Added.
2370         (WebCore::WebGLLayerChromium::WebGLLayerChromium):
2371         (WebCore::WebGLLayerChromium::textureId):
2372         (WebCore::WebGLLayerChromium::updateTextureContents):
2373         (WebCore::WebGLLayerChromium::setContext):
2374         * platform/graphics/chromium/WebGLLayerChromium.h: Added.
2375         (WebCore::WebGLLayerChromium::drawsContent):
2376         (WebCore::WebGLLayerChromium::ownsTexture):
2377         (WebCore::WebGLLayerChromium::shaderProgramId):
2378         (WebCore::WebGLLayerChromium::setShaderProgramId):
2379
2380 2010-06-24  Pavel Feldman  <pfeldman@chromium.org>
2381
2382         Reviewed by Yury Semikhatsky.
2383  
2384         Web Inspector: Inspector cleanup + better DevTools alignment with Inspector.
2385
2386         https://bugs.webkit.org/show_bug.cgi?id=41094
2387
2388         - Removed a bunch of unused methods from all over the place
2389         - Added client callbacks for states surviving navigation
2390         - Implemented more user-friendly stub for InspectorFrontendHost.platform
2391
2392         * inspector/InspectorClient.h:
2393         (WebCore::InspectorClient::resourceTrackingWasEnabled):
2394         (WebCore::InspectorClient::resourceTrackingWasDisabled):
2395         (WebCore::InspectorClient::timelineProfilerWasStarted):
2396         (WebCore::InspectorClient::timelineProfilerWasStopped):
2397         * inspector/InspectorController.cpp:
2398         (WebCore::InspectorController::enableResourceTracking):
2399         (WebCore::InspectorController::disableResourceTracking):
2400         (WebCore::InspectorController::ensureSettingsLoaded):
2401         (WebCore::InspectorController::startTimelineProfiler):
2402         (WebCore::InspectorController::stopTimelineProfiler):
2403         * inspector/InspectorFrontend.cpp:
2404         * inspector/InspectorFrontend.h:
2405         * inspector/front-end/InspectorBackendStub.js:
2406         * inspector/front-end/InspectorFrontendHostStub.js:
2407         (.WebInspector.InspectorFrontendHostStub.prototype.platform):
2408
2409 2010-06-23  Alexey Proskuryakov  <ap@apple.com>
2410
2411         Reviewed by Darin Adler.
2412
2413         https://bugs.webkit.org/show_bug.cgi?id=41099
2414         Assertion failure: !m_suspended when XMLHttpRequest fails
2415
2416         This was a general problem with load failure timer not being deferred.
2417
2418         Test: manual-tests/xhr-failure-behind-alert.html
2419
2420         * manual-tests/xhr-failure-behind-alert.html: Added.
2421
2422         * platform/network/ResourceHandle.cpp:
2423         (WebCore::ResourceHandle::fireFailure): Added an empty case for NoFailure. Reset
2424         m_scheduledFailureType to NoFailure when firing.
2425         (WebCore::ResourceHandle::setDefersLoading): Stop failure timer when deferring, restart when
2426         un-deferring loads.
2427
2428         * platform/network/ResourceHandle.h: Renamed m_failureType to m_scheduledFailureType to
2429         make it clear that it is only set when a timer is scheduled.
2430
2431         * platform/network/ResourceHandleInternal.h:
2432         (WebCore::ResourceHandleInternal::ResourceHandleInternal): Initialize m_scheduledFailureType
2433         to NoFailure, so that we can look at it when un-deferring loads.
2434
2435         * platform/network/android/ResourceHandleAndroid.cpp:
2436         (WebCore::ResourceHandle::platformSetDefersLoading):
2437         * platform/network/cf/ResourceHandleCFNet.cpp:
2438         (WebCore::ResourceHandle::platformSetDefersLoading):
2439         * platform/network/curl/ResourceHandleCurl.cpp:
2440         (WebCore::ResourceHandle::platformSetDefersLoading):
2441         * platform/network/mac/ResourceHandleMac.mm:
2442         (WebCore::ResourceHandle::platformSetDefersLoading):
2443         * platform/network/qt/ResourceHandleQt.cpp:
2444         (WebCore::ResourceHandle::platformSetDefersLoading):
2445         * platform/network/soup/ResourceHandleSoup.cpp:
2446         Platform specific parts of setDefersLoading() are now in a separate function.
2447
2448 2010-06-24  Pavel Feldman  <pfeldman@chromium.org>
2449
2450         Not reviewed: revert 61766.
2451
2452         * inspector/InspectorClient.h:
2453         * inspector/InspectorController.cpp:
2454         (WebCore::InspectorController::enableResourceTracking):
2455         (WebCore::InspectorController::disableResourceTracking):
2456         (WebCore::InspectorController::ensureSettingsLoaded):
2457         (WebCore::InspectorController::startTimelineProfiler):
2458         (WebCore::InspectorController::stopTimelineProfiler):
2459         * inspector/InspectorFrontend.cpp:
2460         (WebCore::InspectorFrontend::setAttachedWindow):
2461         * inspector/InspectorFrontend.h:
2462         * inspector/front-end/InspectorBackendStub.js:
2463         (.WebInspector.InspectorBackendStub.prototype.setAttachedWindowHeight):
2464         * inspector/front-end/InspectorFrontendHostStub.js:
2465         (.WebInspector.InspectorFrontendHostStub.prototype.platform):
2466
2467 2010-06-23  Pavel Feldman  <pfeldman@chromium.org>
2468
2469         Reviewed by Yury Semikhatsky.
2470
2471         Web Inspector: Inspector cleanup + better DevTools alignment with Inspector.
2472         
2473         https://bugs.webkit.org/show_bug.cgi?id=41094
2474
2475         - Removed a bunch of unused methods from all over the place
2476         - Added client callbacks for states surviving navigation
2477         - Implemented more user-friendly stub for InspectorFrontendHost.platform
2478
2479         * inspector/InspectorClient.h:
2480         (WebCore::InspectorClient::resourceTrackingWasEnabled):
2481         (WebCore::InspectorClient::resourceTrackingWasDisabled):
2482         (WebCore::InspectorClient::timelineProfilerWasStarted):
2483         (WebCore::InspectorClient::timelineProfilerWasStopped):
2484         * inspector/InspectorController.cpp:
2485         (WebCore::InspectorController::enableResourceTracking):
2486         (WebCore::InspectorController::disableResourceTracking):
2487         (WebCore::InspectorController::ensureSettingsLoaded):
2488         (WebCore::InspectorController::startTimelineProfiler):
2489         (WebCore::InspectorController::stopTimelineProfiler):
2490         * inspector/InspectorFrontend.cpp:
2491         * inspector/InspectorFrontend.h:
2492         * inspector/front-end/InspectorBackendStub.js:
2493         * inspector/front-end/InspectorFrontendHostStub.js:
2494         (.WebInspector.InspectorFrontendHostStub.prototype.platform):
2495
2496 2010-06-24  Nikolas Zimmermann  <nzimmermann@rim.com>
2497
2498         Reviewed by Dirk Schulze.
2499
2500         Inspector & SVG Text have problems, kids of RenderSVGText are not properly placed.
2501         https://bugs.webkit.org/show_bug.cgi?id=41143
2502
2503         Simplify code path taken for SVG text in InspectorController, take the code path currently only used for RenderInline,
2504         that just calls absoluteQuads(), and displays the result. Refactored code that all SVG renderers (except RenderSVGRoot)
2505         take this code path -> highlighting now works as expected.
2506
2507         Don't use absoluteClippedOverlowRect() in the various RenderSVG*::absoluteQuads() methods, as we're loosing floating-point precision.
2508         Instead use localToAbsoluteQuad(strokeBoundingBox()) in order to highlight the unclipped, unfiltered, etc.. region that this renderer would paint.
2509
2510         No new tests, as this is only manual testable - at least I didn't find any Inspector-Highlighting tests, if someone knows please mail me.
2511
2512         * inspector/InspectorController.cpp:
2513         (WebCore::drawHighlightForLineBoxesOrSVGRenderer):
2514         (WebCore::InspectorController::drawNodeHighlight):
2515         * rendering/RenderSVGBlock.cpp:
2516         (WebCore::RenderSVGBlock::absoluteRects): ASSERT_NOT_REACHED() here. SVG should only be inspected through absoluteQuads().
2517         * rendering/RenderSVGBlock.h: Add absoluteRects() in this base class for RenderForeignObject/RenderSVGText.
2518         * rendering/RenderSVGHiddenContainer.cpp: Remove absoluteRects() - RenderSVGModelObject already has it.
2519         * rendering/RenderSVGHiddenContainer.h: Ditto.
2520         * rendering/RenderSVGImage.cpp: 
2521         (WebCore::RenderSVGImage::absoluteRects): ASSERT_NOT_REACHED() here.
2522         (WebCore::RenderSVGImage::absoluteQuads): Don't use absoluteClippedOverlowRect() but localToAbsoluteQuad(repaintRectInLocalCoordinates()).
2523         * rendering/RenderSVGImage.h:
2524         (WebCore::RenderSVGImage::objectBoundingBox): Inlined
2525         * rendering/RenderSVGInline.cpp: 
2526         (WebCore::RenderSVGInline::absoluteQuads): Take RenderSVGText translation into account, allows inspecting <tspan>/<tref> etc.
2527         * rendering/RenderSVGInline.h:
2528         * rendering/RenderSVGModelObject.cpp: 
2529         (WebCore::RenderSVGModelObject::absoluteRects): ASSERT_NOT_REACHED() here.
2530         (WebCore::RenderSVGModelObject::absoluteQuads): Don't use absoluteClippedOverlowRect() but localToAbsoluteQuad(repaintRectInLocalCoordinates()).
2531         * rendering/RenderSVGModelObject.h:
2532         * rendering/RenderSVGRoot.cpp: Fix typo in license s/aint/along. Need to touch this file in order to let Mac build.
2533         * rendering/RenderSVGText.cpp:
2534         (WebCore::RenderSVGText::mapLocalToContainer): Remove hack, which moved the transformState by x()/y(). Not needed anymore.
2535         (WebCore::RenderSVGText::absoluteQuads): Proper implementation, respecting x/y translation.
2536         * rendering/RenderSVGText.h: Reorder some functions. 
2537         * rendering/SVGRenderSupport.h: Removed last virtual function strokeBoundingBox().
2538
2539 2010-06-24  Kent Tamura  <tkent@chromium.org>
2540
2541         Unreviewed. Build fix for Tiger.
2542
2543         * platform/mac/ThemeMac.mm:
2544         (WebCore::setControlSize):
2545
2546 2010-06-24  Kent Tamura  <tkent@chromium.org>
2547
2548         Unreviewed. Build fix for Tiger.
2549
2550         * platform/mac/ThemeMac.mm:
2551         (WebCore::setControlSize):
2552         (WebCore::ThemeMac::inflateControlPaintRect):
2553
2554 2010-06-24  Kent Tamura  <tkent@chromium.org>
2555
2556         Unreviewed.  Build fix for Chromium Mac.
2557
2558         * html/HTMLInputElement.cpp:
2559         (WebCore::HTMLInputElement::isSpeechEnabled):
2560
2561 2010-06-24  Simon Hausmann  <simon.hausmann@nokia.com>
2562
2563         Unreviewed Symbian build fix.
2564
2565         The QML WebKit integration needs to be part of QtWebKit.sis
2566
2567         * WebCore.pro: Deploy qmlwebkitplugin.dll.
2568
2569 2010-06-24  Satish Sampath  <satish@chromium.org>
2570
2571         Reviewed by Kent Tamura.
2572
2573         Add a speech button to input elements, no rendering or actions yet.
2574
2575         Speech Input: Add a speech button to text input element (no rendering or actions yet)
2576         https://bugs.webkit.org/show_bug.cgi?id=40925
2577
2578         No new tests. Will create a layout test in a subsequent patch.
2579
2580         * css/CSSPrimitiveValueMappings.h:
2581         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
2582         * css/CSSSelector.cpp:
2583         (WebCore::CSSSelector::pseudoId):
2584         (WebCore::nameToPseudoTypeMap):
2585         (WebCore::CSSSelector::extractPseudoType):
2586         * css/CSSSelector.h:
2587         (WebCore::CSSSelector::):
2588         * css/CSSValueKeywords.in:
2589         * css/html.css:
2590         (input::-webkit-input-speech-button):
2591         * dom/InputElement.h:
2592         * html/HTMLAttributeNames.in:
2593         * html/HTMLInputElement.cpp:
2594         (WebCore::HTMLInputElement::isSpeechEnabled):
2595         * html/HTMLInputElement.h:
2596         * platform/ThemeTypes.h:
2597         (WebCore::):
2598         * rendering/RenderTextControlSingleLine.cpp:
2599         (WebCore::RenderTextControlSingleLine::nodeAtPoint):
2600         (WebCore::RenderTextControlSingleLine::forwardEvent):
2601         (WebCore::RenderTextControlSingleLine::styleDidChange):
2602         (WebCore::RenderTextControlSingleLine::hasControlClip):
2603         (WebCore::RenderTextControlSingleLine::controlClipRect):
2604         (WebCore::RenderTextControlSingleLine::textBlockWidth):
2605         (WebCore::RenderTextControlSingleLine::preferredContentWidth):
2606         (WebCore::RenderTextControlSingleLine::adjustControlHeightBasedOnLineHeight):
2607         (WebCore::RenderTextControlSingleLine::createSubtreeIfNeeded):
2608         (WebCore::RenderTextControlSingleLine::createSpeechButtonStyle):
2609         (WebCore::RenderTextControlSingleLine::clientPaddingRight):
2610         * rendering/RenderTextControlSingleLine.h:
2611         * rendering/RenderTheme.cpp:
2612         (WebCore::RenderTheme::adjustStyle):
2613         (WebCore::RenderTheme::paint):
2614         (WebCore::RenderTheme::paintBorderOnly):
2615         (WebCore::RenderTheme::paintDecorations):
2616         * rendering/TextControlInnerElements.cpp:
2617         (WebCore::InputFieldSpeechButtonElement::InputFieldSpeechButtonElement):
2618         (WebCore::InputFieldSpeechButtonElement::create):
2619         (WebCore::InputFieldSpeechButtonElement::defaultEventHandler):
2620         * rendering/TextControlInnerElements.h:
2621         * rendering/style/RenderStyleConstants.h:
2622         (WebCore::):
2623
2624 2010-06-24  Kent Tamura  <tkent@chromium.org>
2625
2626         Reviewed by Adam Barth.
2627
2628         [Mac] The upper button of <input type=number> has no visual effect on click
2629         https://bugs.webkit.org/show_bug.cgi?id=38380
2630
2631         Because we have no ways to draw an NSStepperCell with its up button
2632         highlighted, use HIThemeDrawButton() instead.
2633
2634         Test: platform/mac/fast/forms/input-appearance-spinbutton-up.html
2635
2636         * platform/mac/ThemeMac.mm:
2637         (WebCore::controlSizeFromPixelSize):
2638           New function. Made from a part of setControlSize().
2639         (WebCore::setControlSize):
2640         (WebCore::convertControlStatesToThemeDrawState):
2641         (WebCore::paintStepper): Use HITheme API instead of NSStepperCell.
2642         (WebCore::ThemeMac::inflateControlPaintRect):
2643           Use controlSizeFromPixelSize().
2644
2645 2010-06-24  Yury Semikhatsky  <yurys@chromium.org>
2646
2647         Reviewed by Pavel Feldman.
2648
2649         Web Inspector: implement layout tests for debugger
2650         https://bugs.webkit.org/show_bug.cgi?id=40774
2651
2652         Test: inspector/debugger-pause-on-debugger-statement.html
2653
2654         * bindings/js/ScriptDebugServer.cpp: remove unused obsolete code that deals with global listeners.
2655         (WebCore::ScriptDebugServer::ScriptDebugServer):
2656         (WebCore::ScriptDebugServer::removeListener):
2657         (WebCore::ScriptDebugServer::dispatchFunctionToListeners):
2658         (WebCore::ScriptDebugServer::pauseIfNeeded):
2659         (WebCore::ScriptDebugServer::didAddListener):
2660         (WebCore::ScriptDebugServer::didRemoveListener):
2661         * bindings/js/ScriptDebugServer.h:
2662         * platform/mac/EventLoopMac.mm:
2663         (WebCore::EventLoop::cycle): wait at most 10ms for new event, otherwise layout tests would
2664         hang because in their case there may be no events ever.
2665
2666 2010-06-24  Andrey Kosyakov  <caseq@chromium.org>
2667
2668         Reviewed by Yury Semikhatsky.
2669
2670         Fixed evaluation & logging of null values in console.
2671         Changed handling of null and undefined in ScriptValue::toString()
2672         to match JSC bindings (i.e. "null" and "undefined" instead of "").
2673         https://bugs.webkit.org/show_bug.cgi?id=40980
2674
2675         * bindings/v8/ScriptValue.cpp:
2676         (WebCore::ScriptValue::toString):
2677         * inspector/front-end/InjectedScript.js:
2678         (injectedScriptConstructor):
2679
2680 2010-06-24  Yury Semikhatsky  <yurys@chromium.org>
2681
2682         Reviewed by Pavel Feldman.
2683
2684         Web Inspector: live edit doesn't work when resource tracking is off
2685         https://bugs.webkit.org/show_bug.cgi?id=41076
2686
2687         * inspector/front-end/ScriptView.js:
2688         (WebInspector.ScriptView.prototype._sourceIDForLine): implement this method for ScriptView,
2689         it's needed for editLine to work.
2690
2691 2010-06-23  Adam Barth  <abarth@webkit.org>
2692
2693         Reviewed by Eric Seidel.
2694
2695         Sketch out InitialMode of HTML5 tree builder
2696         https://bugs.webkit.org/show_bug.cgi?id=41126
2697
2698         Transliterated from the spec.  Currently doesn't do anything.  Mostly
2699         an experiment to see where this goes.
2700
2701         * html/HTMLTreeBuilder.cpp:
2702         (WebCore::HTMLTreeBuilder::processToken):
2703         (WebCore::HTMLTreeBuilder::insertDoctype):
2704         (WebCore::HTMLTreeBuilder::insertComment):
2705         * html/HTMLTreeBuilder.h:
2706
2707 2010-06-23  Adam Barth  <abarth@webkit.org>
2708
2709         Reviewed by Eric Seidel.
2710
2711         Add all the HTML5 tree builder insertion modes
2712         https://bugs.webkit.org/show_bug.cgi?id=41124
2713
2714         These are just copied verbatim from the spec.  No tests because these
2715         don't do anything yet.
2716
2717         * html/HTMLTreeBuilder.cpp:
2718         (WebCore::HTMLTreeBuilder::HTMLTreeBuilder):
2719         (WebCore::HTMLTreeBuilder::passTokenToLegacyParser):
2720         * html/HTMLTreeBuilder.h:
2721         (WebCore::HTMLTreeBuilder::):
2722
2723 2010-06-23  Eric Seidel  <eric@webkit.org>
2724
2725         Unreviewed.  Fix namespace indent.  Just whitespace changes.
2726
2727         * dom/DocumentParser.h:
2728         (WebCore::DocumentParser::~DocumentParser):
2729         (WebCore::DocumentParser::isExecutingScript):
2730         (WebCore::DocumentParser::stopParsing):
2731         (WebCore::DocumentParser::processingData):
2732         (WebCore::DocumentParser::wantsRawData):
2733         (WebCore::DocumentParser::writeRawData):
2734         (WebCore::DocumentParser::wellFormed):
2735         (WebCore::DocumentParser::lineNumber):
2736         (WebCore::DocumentParser::columnNumber):
2737         (WebCore::DocumentParser::executeScriptsWaitingForStylesheets):
2738         (WebCore::DocumentParser::htmlTreeBuilder):
2739         (WebCore::DocumentParser::asHTMLDocumentParser):
2740         (WebCore::DocumentParser::inViewSourceMode):
2741         (WebCore::DocumentParser::setInViewSourceMode):
2742         (WebCore::DocumentParser::document):
2743         (WebCore::DocumentParser::xssAuditor):
2744         (WebCore::DocumentParser::setXSSAuditor):
2745         (WebCore::DocumentParser::DocumentParser):
2746
2747 2010-06-23  Eric Seidel  <eric@webkit.org>
2748
2749         Unreviewed.  Speculative build fix for Qt.
2750
2751         Move Document* down onto DocumentParser, since every DocumentParser needs one.
2752         https://bugs.webkit.org/show_bug.cgi?id=41117
2753
2754         XMLDocumentParserQt is a huge pile of donkey barf.
2755         I can't believe I ever r+'d the creation of this pile of
2756         copy/paste code.
2757
2758         I clearly missed removing m_doc from this code as well and thus
2759         broke Qt.
2760
2761         We really need to fix both XMLDocumentParserLibxml2 and
2762         XMLDocumentParserQt not to be so poorly abstracted so
2763         that if we're going to have two of them they can at least
2764         share some code.
2765
2766         * dom/XMLDocumentParserQt.cpp:
2767         (WebCore::XMLDocumentParser::XMLDocumentParser):
2768         (WebCore::XMLDocumentParser::~XMLDocumentParser):
2769         (WebCore::XMLDocumentParser::doWrite):
2770         (WebCore::XMLDocumentParser::doEnd):
2771         (WebCore::XMLDocumentParser::parse):
2772         (WebCore::XMLDocumentParser::startDocument):
2773         (WebCore::XMLDocumentParser::parseStartElement):
2774         (WebCore::XMLDocumentParser::parseEndElement):
2775         (WebCore::XMLDocumentParser::parseProcessingInstruction):
2776         (WebCore::XMLDocumentParser::parseCdata):
2777         (WebCore::XMLDocumentParser::parseComment):
2778         (WebCore::XMLDocumentParser::parseDtd):
2779
2780 2010-06-23  Eric Seidel  <eric@webkit.org>
2781
2782         Reviewed by Adam Barth.
2783
2784         Move Document* down onto DocumentParser, since every DocumentParser needs one.
2785         https://bugs.webkit.org/show_bug.cgi?id=41117
2786
2787         This eliminated the need for document() on HTMLDocumentParser.
2788         This paves the way for more code sharing between various
2789         DocumentParser subclasses.
2790
2791         * dom/DocumentParser.h:
2792         (WebCore::DocumentParser::inViewSourceMode):
2793         (WebCore::DocumentParser::setInViewSourceMode):
2794         (WebCore::DocumentParser::document):
2795         (WebCore::DocumentParser::DocumentParser):
2796         * dom/XMLDocumentParser.cpp:
2797         (WebCore::XMLDocumentParser::isWMLDocument):
2798         (WebCore::XMLDocumentParser::pushCurrentNode):
2799         (WebCore::XMLDocumentParser::popCurrentNode):
2800         (WebCore::XMLDocumentParser::clearCurrentNodeStack):
2801         (WebCore::XMLDocumentParser::enterText):
2802         (WebCore::XMLDocumentParser::end):
2803         (WebCore::XMLDocumentParser::insertErrorMessageBlock):
2804         * dom/XMLDocumentParser.h:
2805         * dom/XMLDocumentParserLibxml2.cpp:
2806         (WebCore::XMLDocumentParser::XMLDocumentParser):
2807         (WebCore::XMLDocumentParser::~XMLDocumentParser):
2808         (WebCore::XMLDocumentParser::doWrite):
2809         (WebCore::XMLDocumentParser::startElementNs):
2810         (WebCore::XMLDocumentParser::endElementNs):
2811         (WebCore::XMLDocumentParser::processingInstruction):
2812         (WebCore::XMLDocumentParser::cdataBlock):
2813         (WebCore::XMLDocumentParser::comment):
2814         (WebCore::XMLDocumentParser::startDocument):
2815         (WebCore::XMLDocumentParser::internalSubset):
2816         (WebCore::XMLDocumentParser::initializeParserContext):
2817         (WebCore::XMLDocumentParser::doEnd):
2818         * html/HTMLDocumentParser.cpp:
2819         (WebCore::HTMLDocumentParser::HTMLDocumentParser):
2820         * html/HTMLDocumentParser.h:
2821         * html/LegacyHTMLDocumentParser.cpp:
2822         (WebCore::LegacyHTMLDocumentParser::LegacyHTMLDocumentParser):
2823         (WebCore::LegacyHTMLDocumentParser::begin):
2824         (WebCore::LegacyHTMLDocumentParser::scriptHandler):
2825         (WebCore::LegacyHTMLDocumentParser::scriptExecution):
2826         (WebCore::LegacyHTMLDocumentParser::parseTag):
2827         (WebCore::LegacyHTMLDocumentParser::continueProcessing):
2828         (WebCore::LegacyHTMLDocumentParser::willWriteHTML):
2829         (WebCore::LegacyHTMLDocumentParser::didWriteHTML):
2830         (WebCore::LegacyHTMLDocumentParser::write):
2831         (WebCore::LegacyHTMLDocumentParser::stopParsing):
2832         (WebCore::LegacyHTMLDocumentParser::timerFired):
2833         (WebCore::LegacyHTMLDocumentParser::end):
2834         (WebCore::LegacyHTMLDocumentParser::processToken):
2835         (WebCore::LegacyHTMLDocumentParser::processDoctypeToken):
2836         (WebCore::LegacyHTMLDocumentParser::executeScriptsWaitingForStylesheets):
2837         (WebCore::LegacyHTMLDocumentParser::executeExternalScriptsIfReady):
2838         (WebCore::LegacyHTMLDocumentParser::executeExternalScriptsTimerFired):
2839         * html/LegacyHTMLDocumentParser.h:
2840         * loader/ImageDocument.cpp:
2841         (WebCore::ImageDocumentParser::ImageDocumentParser):
2842         (WebCore::ImageDocumentParser::imageDocument):
2843         (WebCore::ImageDocumentParser::write):
2844         (WebCore::ImageDocumentParser::writeRawData):
2845         (WebCore::ImageDocumentParser::finish):
2846         (WebCore::ImageDocumentParser::finishWasCalled):
2847         (WebCore::ImageDocumentParser::isWaitingForScripts):
2848         (WebCore::ImageDocument::createParser):
2849         * loader/MediaDocument.cpp:
2850         (WebCore::MediaDocumentParser::MediaDocumentParser):
2851         (WebCore::MediaDocumentParser::createDocumentStructure):
2852         (WebCore::MediaDocumentParser::finish):
2853         (WebCore::MediaDocumentParser::finishWasCalled):
2854         * loader/PluginDocument.cpp:
2855         (WebCore::PluginDocumentParser::PluginDocumentParser):
2856         (WebCore::PluginDocumentParser::createDocumentStructure):
2857         (WebCore::PluginDocumentParser::writeRawData):
2858         (WebCore::PluginDocumentParser::finish):
2859         (WebCore::PluginDocumentParser::finishWasCalled):
2860         * loader/SinkDocument.cpp:
2861         (WebCore::SinkDocumentParser::SinkDocumentParser):
2862         * loader/TextDocument.cpp:
2863         (WebCore::TextDocumentParser::TextDocumentParser):
2864         (WebCore::TextDocumentParser::write):
2865         (WebCore::TextDocumentParser::finish):
2866         (WebCore::TextDocumentParser::finishWasCalled):
2867
2868 2010-06-23  Eric Seidel  <eric@webkit.org>
2869
2870         Reviewed by Adam Barth.
2871
2872         Start to clean up DocumentParser interface
2873         https://bugs.webkit.org/show_bug.cgi?id=41114
2874
2875         The first of many cleanups needed to the DocumentParser
2876         interface.  Rename executingScript() to isExecutingScript()
2877         and make it return a bool instead of an int.  Also added a
2878         FIXME to XMLDocumentParser about implementing it and did
2879         some minor other cleanup to the XMLDocumentParser header.
2880
2881         No functional change, thus no tests.
2882
2883         * dom/Document.cpp:
2884         (WebCore::Document::open):
2885         * dom/DocumentParser.h:
2886         (WebCore::DocumentParser::isExecutingScript):
2887         * dom/XMLDocumentParser.h:
2888         (WebCore::XMLDocumentParser::wellFormed):
2889         * html/HTMLDocumentParser.cpp:
2890         (WebCore::HTMLDocumentParser::attemptToEnd):
2891         (WebCore::HTMLDocumentParser::endIfDelayed):
2892         (WebCore::HTMLDocumentParser::isExecutingScript):
2893         * html/HTMLDocumentParser.h:
2894         * html/LegacyHTMLDocumentParser.h:
2895         (WebCore::LegacyHTMLDocumentParser::isExecutingScript):
2896
2897 2010-06-22  Maciej Stachowiak  <mjs@apple.com>
2898
2899         Reviewed by Simon Fraser.
2900
2901         Implement IDL attribute for HTML5 hidden
2902         https://bugs.webkit.org/show_bug.cgi?id=41039
2903
2904         Test: fast/html/hidden-attr-dom.html
2905
2906         * html/HTMLElement.idl: Just add to the IDL file. [Reflect] takes
2907         care of the rest.
2908
2909 2010-06-23  Joanmarie Diggs  <joanmarie.diggs@gmail.com>
2910
2911         Reviewed by Chris Fleizach.
2912
2913         [Gtk] nameFromChildren is obsolete
2914         https://bugs.webkit.org/show_bug.cgi?id=36128
2915
2916         Look to the AtkText interface implemented by the objects in
2917         question.
2918
2919         Test: platform/gtk/accessibility/name-from-label.html
2920
2921         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
2922         (webkit_accessible_get_name):
2923         (webkit_accessible_table_get_column_description):
2924         (webkit_accessible_table_get_row_description):
2925
2926 2010-06-23  Kwang Yul Seo  <skyul@company100.net>
2927
2928         Reviewed by Kent Tamura.
2929
2930         [BREWMP] Port FileSystem
2931         https://bugs.webkit.org/show_bug.cgi?id=34323
2932
2933         Port FileSystem with IFileMgr interface.
2934
2935         * platform/FileSystem.h:
2936         * platform/brew/FileSystemBrew.cpp: Added.
2937         (WebCore::getFileSize):
2938         (WebCore::getFileModificationTime):
2939         (WebCore::fileExists):
2940         (WebCore::deleteFile):
2941         (WebCore::deleteEmptyDirectory):
2942         (WebCore::pathByAppendingComponent):
2943         (WebCore::fileSystemRepresentation):
2944         (WebCore::canonicalPath):
2945         (WebCore::makeAllDirectories):
2946         (WebCore::homeDirectoryPath):
2947         (WebCore::pathGetFileName):
2948         (WebCore::directoryName):
2949         (WebCore::openTemporaryFile):
2950         (WebCore::closeFile):
2951         (WebCore::writeToFile):
2952         (WebCore::unloadModule):
2953         (WebCore::listDirectory):
2954
2955 2010-06-23  Alexendar Pavlov  <apavlov@chromium.org>
2956
2957         Reviewed by David Hyatt.
2958
2959         Swap checks in Position::isCandidate so that the less expensive
2960         nodeIsUserSelectNode  (node && node->renderer() &&
2961         node->renderer()->style()->userSelect() == SELECT_NONE) came first.
2962
2963         (Was Web Inspector: Hangup when expanding elements with enormous
2964         text node content in Elements panel).
2965
2966         https://bugs.webkit.org/show_bug.cgi?id=35926
2967
2968         * dom/Position.cpp:
2969         (WebCore::Position::isCandidate):
2970         * dom/PositionIterator.cpp:
2971         (WebCore::PositionIterator::isCandidate):
2972
2973 2010-06-23  Kwang Yul Seo  <skyul@company100.net>
2974
2975         Reviewed by Kent Tamura.
2976
2977         [BREWMP] Add PopupMenu implementation
2978         https://bugs.webkit.org/show_bug.cgi?id=40226
2979
2980         Delegate PopupMenu handling to ChromeClientBrew.
2981
2982         * page/brew/ChromeClientBrew.h: Added.
2983         * platform/PopupMenu.h:
2984         * platform/brew/PopupMenuBrew.cpp: Added.
2985         (WebCore::PopupMenu::PopupMenu):
2986         (WebCore::PopupMenu::~PopupMenu):
2987         (WebCore::PopupMenu::show):
2988         (WebCore::PopupMenu::hide):
2989         (WebCore::PopupMenu::updateFromElement):
2990         (WebCore::PopupMenu::itemWritingDirectionIsNatural):
2991
2992 2010-06-23  Kenneth Russell  <kbr@google.com>
2993
2994         Reviewed by Dimitri Glazkov.
2995
2996         Implement format conversions in texImage2D and texSubImage2D taking HTML data
2997         https://bugs.webkit.org/show_bug.cgi?id=40319
2998
2999         Generalized code supporting premultiplication of alpha and
3000         vertical flip to pack texture data into requested format and type.
3001         Handled incoming image data of various formats, RGBA and BGRA in
3002         particular, both to reduce the number of temporary copies during
3003         texture upload and to support premultiplying alpha for the
3004         texImage2D and texSubImage2D entry points taking ArrayBufferView
3005         in a subsequent bug. Added test case exercising all combinations
3006         of format/type combinations, premultiplication of alpha, and
3007         Image/ImageData upload. (Incorporated pnglib.js under
3008         fast/canvas/webgl/resources/ to be able to generate Image elements
3009         programmatically.) Tested in Safari on Mac OS X and in Chromium on
3010         Mac OS X, Windows and Linux.
3011
3012         Test: fast/canvas/webgl/tex-image-with-format-and-type.html
3013
3014         * html/canvas/WebGLRenderingContext.cpp:
3015         (WebCore::WebGLRenderingContext::readPixels):
3016         (WebCore::WebGLRenderingContext::texImage2DImpl):
3017         (WebCore::WebGLRenderingContext::texImage2D):
3018         (WebCore::WebGLRenderingContext::texSubImage2DImpl):
3019         (WebCore::WebGLRenderingContext::texSubImage2D):
3020         (WebCore::WebGLRenderingContext::validateTexFuncFormatAndType):
3021         (WebCore::WebGLRenderingContext::validateTexFuncParameters):
3022         * platform/graphics/GraphicsContext3D.cpp:
3023         (WebCore::GraphicsContext3D::computeFormatAndTypeParameters):
3024         (WebCore::GraphicsContext3D::extractImageData):
3025         (WebCore::GraphicsContext3D::flipVertically):
3026         (WebCore::doUnpackingAndPacking):
3027         (WebCore::doPacking):
3028         (WebCore::GraphicsContext3D::packPixels):
3029         * platform/graphics/GraphicsContext3D.h:
3030         (WebCore::GraphicsContext3D::):
3031         * platform/graphics/cg/GraphicsContext3DCG.cpp:
3032         (WebCore::GraphicsContext3D::getImageData):
3033         * platform/graphics/mac/GraphicsContext3DMac.mm:
3034         (WebCore::narrowInternalFormat):
3035         (WebCore::GraphicsContext3D::texImage2D):
3036         * platform/graphics/qt/GraphicsContext3DQt.cpp:
3037         (WebCore::GraphicsContext3D::getImageData):
3038         * platform/graphics/skia/GraphicsContext3DSkia.cpp:
3039         (WebCore::GraphicsContext3D::getImageData):
3040
3041 2010-06-23  Stephen White  <senorblanco@chromium.org>
3042
3043         Unreviewed; correcting bad patch.
3044
3045         In my haste to land r61710, I mistakenly landed the wrong version, in
3046         which a chunk of code was moved.  This patch moves that chunk of code
3047         to where it was in the patch that was reviewed.  Mea culpa.
3048
3049         * rendering/RenderBoxModelObject.cpp:
3050         (WebCore::ImageQualityController::shouldPaintAtLowQuality):
3051
3052 2010-06-23  Stephen White  <senorblanco@chromium.org>
3053
3054         Reviewed by David Hyatt.
3055
3056         This is a tweak to the resize algorithm introduced in r61341, and
3057         is a fix for the regression described in
3058         https://bugs.webkit.org/show_bug.cgi?id=41036
3059
3060         The goal is to bring back the some of old behaviour, without regressing
3061         too much of the performance gains in r61341.
3062
3063         The old algorithm was:
3064         - on first resize, draw in high quality and record the paint time
3065         - if we've already drawn at this size, use the same quality as last time
3066         - on subsequent resizes, if the resize occurs within X ms of the
3067           previous one, draw at low quality and set a timer (one timer per
3068           image).
3069         - when each timer expires, draw that image at high quality
3070
3071         The r61341 algorithm was:  
3072         - on first resize, draw the image in low quality, add it to a list of
3073           resized images, and set a timer (one timer for all images)
3074         - when the timer expires, redraw all resized images in high quality
3075
3076         The new algorithm is:
3077         - on first resize, if no other animated resizes are outstanding, draw in
3078           high quality and set the timer (one timer for all images)
3079         - if any images have been resized to two different sizes in the last
3080           X ms, draw all resized images in low quality and kick the timer
3081           forward
3082         - when the timer expires, if any animated resizes occured, redraw all
3083           resized images in high quality, and reset the flag
3084
3085         This should cause GUIMark and the IE9 demos to have good performance 
3086         after the first frame, while other pages with only static resizes
3087         should be unaffected.
3088
3089         * rendering/RenderBoxModelObject.cpp:
3090         Change the LastPaintTimeMap to a LastPaintSizeMap:  we now record the
3091         last size an image was resized to, rather than the time it was painted
3092         (the time actually became redundant in r61341 when I added the
3093         check for m_timer.isActive():  we only care if anything is resizing
3094         while the timer is active).
3095         (WebCore::ImageQualityController::ImageQualityController):
3096         Add an initializer for the m_animatedResizeIsActive flag.
3097         (WebCore::ImageQualityController::objectDestroyed):
3098         Reset the m_animatedResizeIsActive flag if this was the last object
3099         in the list.
3100         (WebCore::ImageQualityController::highQualityRepaintTimerFired):
3101         Only repaint all the images if there was an animated resize (otherwise,
3102         everything is already high quality).
3103         (WebCore::ImageQualityController::shouldPaintAtLowQuality):
3104         Implement the above algorithm.
3105
3106 2010-06-23  Abhishek Arya  <inferno@chromium.org>
3107
3108         Reviewed by Kenneth Rohde Christiansen.
3109
3110         Bad cast after DOM mutation in RenderMenuList
3111         https://bugs.webkit.org/show_bug.cgi?id=40828
3112  
3113         Firing the onchange event on select which changes its size > 1 causes the select
3114         object to change from a menulist to a listbox. However, when propogating the events,
3115         we do a bad cast assuming the object will remain a menulist. Added proper checks to
3116         make sure we check the renderer after the onchange is fired and propogate the event
3117         based on correct object type.
3118
3119         Test: fast/events/select-onchange-crash.html
3120
3121         * dom/SelectElement.cpp:
3122         (WebCore::SelectElement::setSelectedIndex):
3123
3124 2010-06-23  Andy Estes  <aestes@apple.com>
3125
3126         Reviewed by Alexey Proskuryakov.
3127         
3128         <rdar://problem/8107855> Prevent a crash in WebCore when removing an
3129         object element with an invalid data URL in in a listener to its
3130         beforeload event.
3131         https://bugs.webkit.org/show_bug.cgi?id=41054
3132
3133         Tests: fast/dom/beforeload/remove-bad-object-in-beforeload-listener.html
3134
3135         * html/HTMLObjectElement.cpp:
3136         (WebCore::HTMLObjectElement::renderFallbackContent): Exit early if the
3137         object element is not in the document.
3138         * rendering/RenderEmbeddedObject.cpp:
3139         (WebCore::RenderEmbeddedObject::updateWidget): If RenderWidget::destroy()
3140         was called during processing of onbeforeload, do not proceed with loading
3141         the object.
3142
3143 2010-06-23  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
3144
3145         Reviewed by Xan Lopez.
3146
3147         [gtk] web fonts not loaded properly in scribd html5 reader
3148         https://bugs.webkit.org/show_bug.cgi?id=38758
3149
3150         Drop filling the pattern with default values, because this
3151         restricts the matching more than we want.
3152
3153         * platform/graphics/cairo/FontCacheCairo.cpp:
3154         (WebCore::FontCache::createFontPlatformData):
3155
3156 2010-06-23  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
3157
3158         Reviewed by Xan Lopez.
3159
3160         [gtk] web fonts not loaded properly in scribd html5 reader
3161         https://bugs.webkit.org/show_bug.cgi?id=38758
3162
3163         Also special-case `sans' amd `mono', which are aliases commonly
3164         used in GTK+ applications.
3165
3166         * platform/graphics/cairo/FontCacheCairo.cpp:
3167         (WebCore::isWellKnownFontName):
3168
3169 2010-06-23  Justin Schuh  <jschuh@chromium.org>
3170
3171         Unreviewed, rolling out r61695.
3172         http://trac.webkit.org/changeset/61695
3173         https://bugs.webkit.org/show_bug.cgi?id=40798
3174
3175         61695 broke all the Linux builds.
3176
3177         * platform/image-decoders/png/PNGImageDecoder.cpp:
3178         (WebCore::PNGImageDecoder::rowAvailable):
3179
3180 2010-06-23  Kevin Ollivier  <kevino@theolliviers.com>
3181
3182         Reviewed by Darin Adler.
3183
3184         Fix PluginViewNone.cpp compilation for ports that also compile PluginView.cpp
3185         https://bugs.webkit.org/show_bug.cgi?id=37939
3186
3187         * plugins/PluginViewNone.cpp:
3188         (WebCore::PluginView::handleFocusInEvent):
3189         (WebCore::PluginView::handleFocusOutEvent):
3190         (WebCore::PluginView::keepAlive):
3191         (WebCore::PluginView::privateBrowsingStateChanged):
3192         (WebCore::PluginView::setJavaScriptPaused):
3193
3194 2010-06-23  Cris Neckar  <cdn@chromium.org>
3195
3196         Reviewed by Darin Fisher.
3197
3198         [Chromium] Out of bounds write in WebCore::PNGImageDecoder::rowAvailable
3199         https://bugs.webkit.org/show_bug.cgi?id=40798
3200
3201         Catches error in row callback for libPNG when extra rows are returned.
3202
3203         Test: fast/images/png-extra-row-crash.html
3204
3205         * platform/image-decoders/png/PNGImageDecoder.cpp:
3206         (WebCore::PNGImageDecoder::rowAvailable):
3207
3208 2010-06-23  James Robinson  <jamesr@chromium.org>
3209
3210         Reviewed by Dan Bernstein.
3211
3212         Do not set needsLayout when the style attribute changes on an SVG element
3213         https://bugs.webkit.org/show_bug.cgi?id=40366
3214
3215         SVGSVGElement::svgAttributeChanged was incorrectly calling renderer()->setNeedsLayout(true)
3216         whenever the styleAttr changed on its element.  This could happen during layout in some
3217         circumstances due to lazy style attribute synchronization.  When it did, it could cause the
3218         layout flags to become inconsistent.  See the test case for details.
3219
3220         Changes to an element's style attribute always mark an element as needing layout anyway so
3221         this call was redundant.
3222
3223         Test: fast/repaint/svg-layout-root-style-attr-update.html
3224
3225         * svg/SVGStyledElement.cpp:
3226         (WebCore::SVGStyledElement::isKnownAttribute):
3227
3228 2010-06-23  Simon Fraser  <simon.fraser@apple.com>
3229
3230         Reviewed by Dan Bernstein.
3231
3232         r61215 broke Acid3
3233         https://bugs.webkit.org/show_bug.cgi?id=41034
3234         
3235         The code added in r61215, which tests whether the root renderer will fill
3236         the entire viewport, should not run for subframes. So bail from
3237         RenderView::paintBoxDecorations() if document()->ownerElement() is not null.
3238         The old code was trying to do this by checking 'elt', but that ends up as 
3239         null after the for loop above.
3240         
3241         We can also bail early if the is no FrameView().
3242
3243         Test: fast/frames/paint-iframe-background.html
3244
3245         * rendering/RenderView.cpp:
3246         (WebCore::RenderView::paintBoxDecorations):
3247
3248 2010-06-23  Pavel Feldman  <pfeldman@chromium.org>
3249
3250         Reviewed by Yury Semikhatsky.
3251
3252         Web Inspector: do not reset profiles panel on navigation.
3253
3254         https://bugs.webkit.org/show_bug.cgi?id=41068
3255
3256         * inspector/InspectorController.cpp:
3257         (WebCore::InspectorController::didCommitLoad):
3258         * inspector/InspectorFrontend.cpp:
3259         (WebCore::InspectorFrontend::resetProfilesPanel):
3260         * inspector/InspectorFrontend.h:
3261         * inspector/front-end/ProfilesPanel.js:
3262         (WebInspector.ProfilesPanel):
3263         (WebInspector.ProfilesPanel.prototype.populateInterface):
3264         (WebInspector.ProfilesPanel.prototype.profilerWasDisabled):
3265         (WebInspector.ProfilesPanel.prototype._reset):
3266         (WebInspector.ProfilesPanel.prototype._clearProfiles):
3267         * inspector/front-end/inspector.js:
3268         (WebInspector.resetProfilesPanel):
3269
3270 2010-06-23  Yury Semikhatsky  <yurys@chromium.org>
3271
3272         Reviewed by Pavel Feldman.
3273
3274         Web Inspector: InspectorController should be added only once as ScriptDebugListener to
3275         ScriptDebugServer.
3276         https://bugs.webkit.org/show_bug.cgi?id=41070
3277
3278         * inspector/InspectorController.cpp:
3279         (WebCore::InspectorController::connectFrontend):
3280         (WebCore::InspectorController::disconnectFrontend):
3281         (WebCore::InspectorController::enableDebuggerFromFrontend):
3282         * inspector/front-end/ScriptsPanel.js:
3283         (WebInspector.ScriptsPanel): don't call InspectorBackend.enableDebugger if debugger is always enabled,
3284         InspectorController will do this on its side when the front end is connected.
3285
3286 2010-06-23  Pavel Podivilov  <podivilov@chromium.org>
3287
3288         Reviewed by Yury Semikhatsky.
3289
3290         Clear breakpoints before restoring them, not after.
3291         https://bugs.webkit.org/show_bug.cgi?id=41071
3292
3293         * inspector/InspectorController.cpp:
3294         (WebCore::InspectorController::enableDebuggerFromFrontend):
3295
3296 2010-06-23  Benjamin Poulain  <benjamin.poulain@nokia.com>
3297
3298         Reviewed by Kenneth Rohde Christiansen.
3299
3300         Do not render the full frame when there is some elements with fixed positioning
3301         https://bugs.webkit.org/show_bug.cgi?id=33150
3302
3303         Do not render the full frame when there is some elements with fixed positioning
3304         https://bugs.webkit.org/show_bug.cgi?id=33150
3305
3306         The frame view take into acount the list of fixed object when scrolling
3307         the view. If the number of object is lower than a certain threshold, the pixel
3308         are blitted, and the invalidated area updated.
3309
3310         * page/FrameView.cpp:
3311         (WebCore::FrameView::addFixedObject):
3312         (WebCore::FrameView::removeFixedObject):
3313         (WebCore::FrameView::scrollContentsFastPath):
3314         * page/FrameView.h:
3315         * platform/ScrollView.cpp:
3316         (WebCore::ScrollView::scrollContents):
3317         (WebCore::ScrollView::scrollContentsFastPath):
3318         * platform/ScrollView.h:
3319         * rendering/RenderLayer.cpp:
3320         (WebCore::RenderLayer::repaintRectIncludingDescendants):
3321         * rendering/RenderLayer.h:
3322         * rendering/RenderObject.cpp:
3323         (WebCore::RenderObject::styleWillChange):
3324
3325 2010-06-23  Mikhail Naganov  <mnaganov@chromium.org>
3326
3327         Reviewed by Pavel Feldman.
3328
3329         Web Inspector: Fix displaying of several CPU profiles with the same name.
3330
3331         https://bugs.webkit.org/show_bug.cgi?id=40992
3332
3333         * inspector/front-end/ProfilesPanel.js:
3334         (WebInspector.ProfileGroupSidebarTreeElement.prototype.onselect):
3335
3336 2010-06-23  Adam Barth  <abarth@webkit.org>
3337
3338         Unreviewed.  clean-header-guards that were made dirty by recent
3339         renames.
3340
3341         * html/HTMLDocumentParser.h:
3342         * html/HTMLPreloadScanner.h:
3343         * html/HTMLTokenizer.h:
3344         * html/HTMLTreeBuilder.h:
3345         * html/LegacyHTMLDocumentParser.h:
3346         * html/LegacyHTMLTreeBuilder.h:
3347         * html/LegacyPreloadScanner.h:
3348
3349 2010-06-23  Adam Barth  <abarth@webkit.org>
3350
3351         Reviewed by Eric Seidel.
3352
3353         Rename LegacyHTMLTreeConstructor to LegacyHTMLTreeBuilder
3354         https://bugs.webkit.org/show_bug.cgi?id=41053
3355
3356         There was some debate about whether to call this class (and the
3357         non-legacy version) "tree builder" or "tree constructor".  Maciej
3358         pointed out that other implementations (including Mozilla and HTML5Lib)
3359         call it a tree builder.  The path of least resistance seems to be call
3360         it that for now.
3361
3362         * Android.mk:
3363         * CMakeLists.txt:
3364         * GNUmakefile.am:
3365         * WebCore.gypi:
3366         * WebCore.pro:
3367         * WebCore.vcproj/WebCore.vcproj:
3368         * WebCore.xcodeproj/project.pbxproj:
3369         * dom/Document.cpp:
3370         * dom/DocumentParser.h:
3371         (WebCore::DocumentParser::htmlTreeConstructor):
3372         * html/HTMLDocumentParser.cpp:
3373         (WebCore::HTMLDocumentParser::htmlTreeConstructor):
3374         * html/HTMLDocumentParser.h:
3375         * html/HTMLFormControlElement.cpp:
3376         (WebCore::HTMLFormControlElement::removedFromTree):
3377         * html/HTMLInputElement.cpp:
3378         * html/HTMLMeterElement.cpp:
3379         * html/HTMLProgressElement.cpp:
3380         * html/HTMLTreeBuilder.cpp:
3381         (WebCore::HTMLTreeBuilder::HTMLTreeBuilder):
3382         * html/HTMLTreeBuilder.h:
3383         (WebCore::HTMLTreeBuilder::legacyTreeConstructor):
3384         * html/LegacyHTMLDocumentParser.cpp:
3385         (WebCore::LegacyHTMLDocumentParser::LegacyHTMLDocumentParser):
3386         * html/LegacyHTMLDocumentParser.h:
3387         (WebCore::LegacyHTMLDocumentParser::htmlTreeConstructor):
3388         * html/LegacyHTMLTreeBuilder.cpp: Copied from WebCore/html/LegacyHTMLTreeConstructor.cpp.
3389         (WebCore::LegacyHTMLTreeBuilder::LegacyHTMLTreeBuilder):
3390         (WebCore::LegacyHTMLTreeBuilder::~LegacyHTMLTreeBuilder):
3391         (WebCore::LegacyHTMLTreeBuilder::reset):
3392         (WebCore::LegacyHTMLTreeBuilder::setCurrent):
3393         (WebCore::LegacyHTMLTreeBuilder::limitDepth):
3394         (WebCore::LegacyHTMLTreeBuilder::insertNodeAfterLimitDepth):
3395         (WebCore::LegacyHTMLTreeBuilder::parseToken):
3396         (WebCore::LegacyHTMLTreeBuilder::parseDoctypeToken):
3397         (WebCore::LegacyHTMLTreeBuilder::insertNode):
3398         (WebCore::LegacyHTMLTreeBuilder::handleError):
3399         (WebCore::LegacyHTMLTreeBuilder::textCreateErrorCheck):
3400         (WebCore::LegacyHTMLTreeBuilder::commentCreateErrorCheck):
3401         (WebCore::LegacyHTMLTreeBuilder::headCreateErrorCheck):
3402         (WebCore::LegacyHTMLTreeBuilder::bodyCreateErrorCheck):
3403         (WebCore::LegacyHTMLTreeBuilder::framesetCreateErrorCheck):
3404         (WebCore::LegacyHTMLTreeBuilder::formCreateErrorCheck):
3405         (WebCore::LegacyHTMLTreeBuilder::isindexCreateErrorCheck):
3406         (WebCore::LegacyHTMLTreeBuilder::selectCreateErrorCheck):
3407         (WebCore::LegacyHTMLTreeBuilder::ddCreateErrorCheck):
3408         (WebCore::LegacyHTMLTreeBuilder::dtCreateErrorCheck):
3409         (WebCore::LegacyHTMLTreeBuilder::rpCreateErrorCheck):
3410         (WebCore::LegacyHTMLTreeBuilder::rtCreateErrorCheck):
3411         (WebCore::LegacyHTMLTreeBuilder::nestedCreateErrorCheck):
3412         (WebCore::LegacyHTMLTreeBuilder::nestedPCloserCreateErrorCheck):
3413         (WebCore::LegacyHTMLTreeBuilder::nestedStyleCreateErrorCheck):
3414         (WebCore::LegacyHTMLTreeBuilder::tableCellCreateErrorCheck):
3415         (WebCore::LegacyHTMLTreeBuilder::tableSectionCreateErrorCheck):
3416         (WebCore::LegacyHTMLTreeBuilder::noembedCreateErrorCheck):
3417         (WebCore::LegacyHTMLTreeBuilder::noframesCreateErrorCheck):
3418         (WebCore::LegacyHTMLTreeBuilder::noscriptCreateErrorCheck):
3419         (WebCore::LegacyHTMLTreeBuilder::pCloserCreateErrorCheck):
3420         (WebCore::LegacyHTMLTreeBuilder::pCloserStrictCreateErrorCheck):
3421         (WebCore::LegacyHTMLTreeBuilder::mapCreateErrorCheck):
3422         (WebCore::LegacyHTMLTreeBuilder::getNode):
3423         (WebCore::LegacyHTMLTreeBuilder::allowNestedRedundantTag):
3424         (WebCore::LegacyHTMLTreeBuilder::processCloseTag):
3425         (WebCore::LegacyHTMLTreeBuilder::isHeadingTag):
3426         (WebCore::LegacyHTMLTreeBuilder::isInline):
3427         (WebCore::LegacyHTMLTreeBuilder::isResidualStyleTag):
3428         (WebCore::LegacyHTMLTreeBuilder::isAffectedByResidualStyle):
3429         (WebCore::LegacyHTMLTreeBuilder::handleResidualStyleCloseTagAcrossBlocks):
3430         (WebCore::LegacyHTMLTreeBuilder::reopenResidualStyleTags):
3431         (WebCore::LegacyHTMLTreeBuilder::pushBlock):
3432         (WebCore::LegacyHTMLTreeBuilder::popBlock):
3433         (WebCore::LegacyHTMLTreeBuilder::popOneBlockCommon):
3434         (WebCore::LegacyHTMLTreeBuilder::popOneBlock):
3435         (WebCore::LegacyHTMLTreeBuilder::moveOneBlockToStack):
3436         (WebCore::LegacyHTMLTreeBuilder::checkIfHasPElementInScope):
3437         (WebCore::LegacyHTMLTreeBuilder::popInlineBlocks):
3438         (WebCore::LegacyHTMLTreeBuilder::freeBlock):
3439         (WebCore::LegacyHTMLTreeBuilder::createHead):
3440         (WebCore::LegacyHTMLTreeBuilder::handleIsindex):
3441         (WebCore::LegacyHTMLTreeBuilder::startBody):
3442         (WebCore::LegacyHTMLTreeBuilder::finished):
3443         (WebCore::LegacyHTMLTreeBuilder::reportErrorToConsole):
3444         * html/LegacyHTMLTreeBuilder.h: Copied from WebCore/html/LegacyHTMLTreeConstructor.h.
3445         * html/LegacyHTMLTreeConstructor.cpp: Removed.
3446         * html/LegacyHTMLTreeConstructor.h: Removed.
3447         * html/StepRange.cpp:
3448         * html/ValidityState.cpp:
3449         * rendering/RenderSlider.cpp:
3450
3451 2010-06-23  Adam Barth  <abarth@webkit.org>
3452
3453         Reviewed by Eric Seidel.
3454
3455         Rename the preload scanners
3456         https://bugs.webkit.org/show_bug.cgi?id=41052
3457
3458         Renames PreloadScanner to LegacyPreloadScanner because this code is now
3459         off by default.  Also, rename HTML5PreloadScanner to
3460         HTMLPreloadScanner.  We're not calling it PreloadScanner because we've
3461         factored out the CSSPreloadScanner and the HTMLPreloadScanner from the
3462         original PreloadScanner.
3463
3464         * Android.mk:
3465         * CMakeLists.txt:
3466         * GNUmakefile.am:
3467         * WebCore.gypi:
3468         * WebCore.pro:
3469         * WebCore.vcproj/WebCore.vcproj:
3470         * WebCore.xcodeproj/project.pbxproj:
3471         * html/HTML5PreloadScanner.cpp: Removed.
3472         * html/HTML5PreloadScanner.h: Removed.
3473         * html/HTMLDocumentParser.cpp:
3474         (WebCore::HTMLDocumentParser::pumpTokenizer):
3475         * html/HTMLDocumentParser.h:
3476         * html/HTMLPreloadScanner.cpp: Copied from WebCore/html/HTML5PreloadScanner.cpp.
3477         (WebCore::HTMLPreloadScanner::HTMLPreloadScanner):
3478         (WebCore::HTMLPreloadScanner::appendToEnd):
3479         (WebCore::HTMLPreloadScanner::scan):
3480         (WebCore::HTMLPreloadScanner::processToken):
3481         (WebCore::HTMLPreloadScanner::scanningBody):
3482         * html/HTMLPreloadScanner.h: Copied from WebCore/html/HTML5PreloadScanner.h.
3483         * html/LegacyHTMLDocumentParser.cpp:
3484         (WebCore::LegacyHTMLDocumentParser::scriptHandler):
3485         (WebCore::LegacyHTMLDocumentParser::scriptExecution):
3486         * html/LegacyHTMLDocumentParser.h:
3487         * html/LegacyPreloadScanner.cpp: Copied from WebCore/html/PreloadScanner.cpp.
3488         (WebCore::LegacyPreloadScanner::LegacyPreloadScanner):
3489         (WebCore::LegacyPreloadScanner::~LegacyPreloadScanner):
3490         (WebCore::LegacyPreloadScanner::begin):
3491         (WebCore::LegacyPreloadScanner::end):
3492         (WebCore::LegacyPreloadScanner::reset):
3493         (WebCore::LegacyPreloadScanner::scanningBody):
3494         (WebCore::LegacyPreloadScanner::write):
3495         (WebCore::LegacyPreloadScanner::clearLastCharacters):
3496         (WebCore::LegacyPreloadScanner::rememberCharacter):
3497         (WebCore::LegacyPreloadScanner::lastCharactersMatch):
3498         (WebCore::LegacyPreloadScanner::consumeEntity):
3499         (WebCore::LegacyPreloadScanner::tokenize):
3500         (WebCore::LegacyPreloadScanner::processAttribute):
3501         (WebCore::LegacyPreloadScanner::emitCharacter):
3502         (WebCore::LegacyPreloadScanner::tokenizeCSS):
3503         (WebCore::LegacyPreloadScanner::emitTag):
3504         (WebCore::LegacyPreloadScanner::emitCSSRule):
3505         * html/LegacyPreloadScanner.h: Copied from WebCore/html/PreloadScanner.h.
3506         * html/PreloadScanner.cpp: Removed.
3507         * html/PreloadScanner.h: Removed.
3508         * page/XSSAuditor.cpp:
3509         (WebCore::XSSAuditor::decodeHTMLEntities):
3510
3511 2010-06-23  Adam Barth  <abarth@webkit.org>
3512
3513         Reviewed by Eric Seidel.
3514
3515         Yet more HTML5 => HTML renames
3516         https://bugs.webkit.org/show_bug.cgi?id=41051
3517
3518         This patch renames HTML5DocumentParser to HTMLDocumentParser and
3519         HTML5TreeBuilder to HTMLTreeBuilder.  There was some discussion about
3520         whether to use the name HTMLTreeBuilder or HTMLTreeConstructor, but
3521         tree builder seems to be the dominate name in other implementations.
3522
3523         * Android.mk:
3524         * CMakeLists.txt:
3525         * GNUmakefile.am:
3526         * WebCore.gypi:
3527         * WebCore.pro:
3528         * WebCore.vcproj/WebCore.vcproj:
3529         * WebCore.xcodeproj/project.pbxproj:
3530         * dom/DocumentFragment.cpp:
3531         (WebCore::DocumentFragment::parseHTML):
3532         * html/HTML5DocumentParser.cpp: Removed.
3533         * html/HTML5DocumentParser.h: Removed.
3534         * html/HTML5PreloadScanner.cpp:
3535         (WebCore::HTML5PreloadScanner::scan):
3536         (WebCore::HTML5PreloadScanner::processToken):
3537         * html/HTML5TreeBuilder.cpp: Removed.
3538         * html/HTML5TreeBuilder.h: Removed.
3539         * html/HTMLDocument.cpp:
3540         (WebCore::HTMLDocument::createParser):
3541         * html/HTMLDocumentParser.cpp: Copied from WebCore/html/HTML5DocumentParser.cpp.
3542         (WebCore::HTMLDocumentParser::HTMLDocumentParser):
3543         (WebCore::HTMLDocumentParser::~HTMLDocumentParser):
3544         (WebCore::HTMLDocumentParser::begin):
3545         (WebCore::HTMLDocumentParser::stopParsing):
3546         (WebCore::HTMLDocumentParser::processingData):
3547         (WebCore::HTMLDocumentParser::pumpTokenizerIfPossible):
3548         (WebCore::HTMLDocumentParser::isScheduledForResume):
3549         (WebCore::HTMLDocumentParser::resumeParsingAfterYield):
3550         (WebCore::HTMLDocumentParser::runScriptsForPausedTreeConstructor):
3551         (WebCore::HTMLDocumentParser::pumpTokenizer):
3552         (WebCore::HTMLDocumentParser::willPumpLexer):
3553         (WebCore::HTMLDocumentParser::didPumpLexer):
3554         (WebCore::HTMLDocumentParser::write):
3555         (WebCore::HTMLDocumentParser::end):
3556         (WebCore::HTMLDocumentParser::attemptToEnd):
3557         (WebCore::HTMLDocumentParser::endIfDelayed):
3558         (WebCore::HTMLDocumentParser::finish):
3559         (WebCore::HTMLDocumentParser::finishWasCalled):
3560         (WebCore::HTMLDocumentParser::executingScript):
3561         (WebCore::HTMLDocumentParser::inScriptExecution):
3562         (WebCore::HTMLDocumentParser::lineNumber):
3563         (WebCore::HTMLDocumentParser::columnNumber):
3564         (WebCore::HTMLDocumentParser::htmlTreeConstructor):
3565         (WebCore::HTMLDocumentParser::isWaitingForScripts):
3566         (WebCore::HTMLDocumentParser::resumeParsingAfterScriptExecution):
3567         (WebCore::HTMLDocumentParser::watchForLoad):
3568         (WebCore::HTMLDocumentParser::stopWatchingForLoad):
3569         (WebCore::HTMLDocumentParser::shouldLoadExternalScriptFromSrc):
3570         (WebCore::HTMLDocumentParser::notifyFinished):
3571         (WebCore::HTMLDocumentParser::executeScriptsWaitingForStylesheets):
3572         (WebCore::HTMLDocumentParser::script):
3573         * html/HTMLDocumentParser.h: Copied from WebCore/html/HTML5DocumentParser.h.<