2008-12-08 Aaron Boodman <aa@chromium.org>
[WebKit-https.git] / WebCore / ChangeLog
1 2008-12-08  Aaron Boodman  <aa@chromium.org>
2
3         Reviewed by Stephanie Lewis.
4
5         https://bugs.webkit.org/show_bug.cgi?id=22301
6         Make dispatchDidFinishLoading() always fire before didFinishLoadForFrame().
7
8         * loader/FrameLoader.cpp:
9         (WebCore::FrameLoader::finishedParsing):
10
11 2008-12-08  Trenton Schulz <trenton.schulz@nokia.com>
12
13         Rubber-stamped by Tor Arne Vestbø.
14
15         Fix build warning on Mac
16
17         * platform/text/mac/StringImplMac.mm:
18
19 2008-12-08  Simon Hausmann  <simon.hausmann@nokia.com>
20
21         Fix the Qt build.
22
23         * bridge/qt/qt_runtime.cpp:
24         (JSC::Bindings::convertQVariantToValue): Pass JSGlobalData to RegExp
25           constructor.
26
27 2008-12-08  Oliver Hunt  <oliver@apple.com>
28
29         Reviewed by Alexey Proskuryakov.
30
31         Bug 22398: r39059: Crash when clearing webkitTransitionDuration in webkitTransitionEnd event handler
32         <rdar://problem/6426245> REGRESSION(r39059): Reproducible crash when clearing webkitTransitionDuration in webkitTransitionEnd event handler (22398)
33
34         This regression was caused by r39059 replacing the protector on the active
35         animation with a protector on just the composition.  It turns out that both
36         protectors are necessary.
37
38         Test: transitions/transition-duration-cleared-in-transitionend-crash.html
39
40         * page/animation/AnimationBase.cpp:
41         (WebCore::AnimationBase::animationTimerCallbackFired):
42
43 2008-12-08  Dmitry Titov  <dimich@chromium.org>
44
45         Reviewed by Alexey Proskuryakov.
46
47         https://bugs.webkit.org/show_bug.cgi?id=22732
48         Remove unused files PausedTimeouts.h,.cpp
49         The change that deprecated this code was https://bugs.webkit.org/show_bug.cgi?id=22620
50
51         * GNUmakefile.am:
52         * WebCore.pro:
53         * WebCore.scons:
54         * WebCore.vcproj/WebCore.vcproj:
55         * WebCore.xcodeproj/project.pbxproj:
56         * WebCoreSources.bkl:
57           These are build files which had PausedTimeouts referenced.
58
59         * bindings/js/PausedTimeouts.cpp: Removed.
60         * bindings/js/PausedTimeouts.h: Removed.
61         * bindings/js/ScriptController.cpp: Removed '#include'
62         * page/Chrome.cpp: Removed '#include' and unused variable.
63
64 2008-12-07  Simon Fraser  <simon.fraser@apple.com>
65
66         Reviewed by Dan Bernstein
67
68         https://bugs.webkit.org/show_bug.cgi?id=22594
69
70         Fix issues which break reading inline style for -webkit-transition
71         and -webkit-transform-origin.
72         
73         Test: fast/css/transform-inline-style.html
74
75         * css/CSSMutableStyleDeclaration.cpp:
76         (WebCore::CSSMutableStyleDeclaration::getPropertyValue): Add cases 
77         for CSSPropertyWebkitTransformOrigin and CSSPropertyWebkitTransition
78         so that these shorthand properties are returned correctly.
79         * css/CSSParser.cpp:
80         (WebCore::CSSParser::parseAnimationProperty): Create CSSPrimitiveValues
81         with the correct CSSValueAll and CSSValueNone identifiers, not the
82         RenderStyle-level cAnimateAll, cAnimateNone.
83         * css/CSSStyleSelector.cpp:
84         (WebCore::CSSStyleSelector::mapAnimationProperty): Special-case CSSValueAll
85         and CSSValueNone values to set cAnimateAll and cAnimateNone transition properties.
86
87 2008-12-07  Antti Koivisto  <antti@apple.com>
88
89         Reviewed by Darin Adler.
90
91         https://bugs.webkit.org/show_bug.cgi?id=22717
92         Make CSS values use less memory
93         
94         Share CSSPrimitiveValue objects for commonly used values including
95         - idents
96         - colors
97         - small integers
98         
99         This reduces the amount CSSPrimitiveValue instances by > 80%.
100
101         * css/CSSPrimitiveValue.cpp:
102         (WebCore::CSSPrimitiveValue::createIdentifier):
103         (WebCore::CSSPrimitiveValue::createColor):
104         (WebCore::CSSPrimitiveValue::create):
105         * css/CSSPrimitiveValue.h:
106         (WebCore::CSSPrimitiveValue::create):
107
108 2008-12-07  Antti Koivisto  <antti@apple.com>
109
110         Reviewed by Darin Adler.
111
112         https://bugs.webkit.org/show_bug.cgi?id=22717
113         Make CSS values use less memory
114
115         Get CSSValues off from the common StyleBase base class. They don't
116         need a parent pointer or anything else there and there is no real
117         reason to have them in same data structures with other CSSOM objects.
118         
119         Disabled (instead of refactoring around the lack of common base) the ability 
120         to have style declaration blocks as CSS variable values. They don't exist in 
121         the spec so I wasn't sure if they have future or not. It would not be hard to 
122         get them back. CSS variables are in any case an experimental feature and 
123         not enabled by default.
124
125         * css/CSSInitialValue.h:
126         (WebCore::CSSInitialValue::createExplicit):
127         (WebCore::CSSInitialValue::createImplicit):
128         * css/CSSParser.cpp:
129         (WebCore::CSSParser::addVariableDeclarationBlock):
130         * css/CSSParser.h:
131         * css/CSSValue.h:
132         (WebCore::CSSValue::~CSSValue):
133         (WebCore::CSSValue::parserValue):
134         * css/CSSVariablesDeclaration.cpp:
135         (WebCore::CSSVariablesDeclaration::CSSVariablesDeclaration):
136         (WebCore::CSSVariablesDeclaration::getVariableValue):
137         (WebCore::CSSVariablesDeclaration::removeVariable):
138         (WebCore::CSSVariablesDeclaration::addParsedVariable):
139         (WebCore::CSSVariablesDeclaration::getParsedVariable):
140         (WebCore::CSSVariablesDeclaration::getParsedVariableDeclarationBlock):
141         * css/CSSVariablesDeclaration.h:
142         (WebCore::CSSVariablesDeclaration::create):
143         * css/StyleBase.h:
144
145 2008-12-07  Dirk Schulze  <krit@webkit.org>
146
147         Reviewed by Oliver Hunt.
148
149         Add gradient and pattern support for strokeRect on canvas/Cg.
150
151         Canvas strokeRect() doesn't support gradients
152         https://bugs.webkit.org/show_bug.cgi?id=19790
153
154         Test: fast/canvas/canvas-strokeRect.html
155
156         * platform/graphics/cg/GraphicsContextCG.cpp:
157         (WebCore::GraphicsContext::strokeRect):
158
159 2008-12-06  Dirk Schulze  <krit@webkit.org>
160
161         Reviewed by Oliver Hunt.
162
163         Add support for setTransform() in canvas.
164
165         <canvas> lacks transform() and setTransform()
166         https://bugs.webkit.org/show_bug.cgi?id=16604
167
168         Test: fast/canvas/canvas-setTransform.html
169
170         * html/CanvasRenderingContext2D.cpp:
171         (WebCore::CanvasRenderingContext2D::State::State):
172         (WebCore::CanvasRenderingContext2D::setStrokeStyle):
173         (WebCore::CanvasRenderingContext2D::setFillStyle):
174         (WebCore::CanvasRenderingContext2D::scale):
175         (WebCore::CanvasRenderingContext2D::rotate):
176         (WebCore::CanvasRenderingContext2D::translate):
177         (WebCore::CanvasRenderingContext2D::transform):
178         (WebCore::CanvasRenderingContext2D::setTransform):
179         (WebCore::CanvasRenderingContext2D::beginPath):
180         (WebCore::CanvasRenderingContext2D::closePath):
181         (WebCore::CanvasRenderingContext2D::moveTo):
182         (WebCore::CanvasRenderingContext2D::lineTo):
183         (WebCore::CanvasRenderingContext2D::quadraticCurveTo):
184         (WebCore::CanvasRenderingContext2D::bezierCurveTo):
185         (WebCore::CanvasRenderingContext2D::arcTo):
186         (WebCore::CanvasRenderingContext2D::arc):
187         (WebCore::CanvasRenderingContext2D::rect):
188         (WebCore::CanvasRenderingContext2D::fill):
189         (WebCore::CanvasRenderingContext2D::stroke):
190         (WebCore::CanvasRenderingContext2D::clip):
191         (WebCore::CanvasRenderingContext2D::isPointInPath):
192         (WebCore::CanvasRenderingContext2D::clearRect):
193         (WebCore::CanvasRenderingContext2D::fillRect):
194         (WebCore::CanvasRenderingContext2D::strokeRect):
195         (WebCore::CanvasRenderingContext2D::drawImage):
196         (WebCore::CanvasRenderingContext2D::drawImageFromRect):
197         (WebCore::CanvasRenderingContext2D::willDraw):
198         (WebCore::CanvasRenderingContext2D::drawTextInternal):
199         * html/CanvasRenderingContext2D.h:
200         * html/CanvasRenderingContext2D.idl:
201         * html/HTMLCanvasElement.cpp:
202         (WebCore::HTMLCanvasElement::baseTransform):
203         * html/HTMLCanvasElement.h:
204         * platform/graphics/ImageBuffer.h:
205         (WebCore::ImageBuffer::baseTransform):
206
207 2008-12-06  Antti Koivisto  <antti@apple.com>
208
209         Reviewed by Darin Adler.
210
211         Also copy m_implicit field. Darin wanted this change commited separately.
212
213         * css/CSSProperty.h:
214         (WebCore::CSSProperty::operator=):
215
216 2008-12-06  Antti Koivisto  <antti@apple.com>
217
218         Reviewed by Darin Adler.
219
220         https://bugs.webkit.org/show_bug.cgi?id=22379
221         Make CSSOM use less memory
222         
223         Use vector instead of a double linked list for properties in CSSMutableStyleDeclaration.
224         
225         Taught setter functions to use existing slots to avoid memory moves, plus some
226         other optimizations.
227
228         * WebCore.xcodeproj/project.pbxproj:
229         * css/CSSMutableStyleDeclaration.cpp:
230         (WebCore::CSSMutableStyleDeclaration::CSSMutableStyleDeclaration):
231         (WebCore::CSSMutableStyleDeclaration::operator=):
232         (WebCore::CSSMutableStyleDeclaration::getPropertyCSSValue):
233         (WebCore::CSSMutableStyleDeclaration::removeShorthandProperty):
234         (WebCore::CSSMutableStyleDeclaration::removeProperty):
235         (WebCore::CSSMutableStyleDeclaration::getPropertyPriority):
236         (WebCore::CSSMutableStyleDeclaration::getPropertyShorthand):
237         (WebCore::CSSMutableStyleDeclaration::isPropertyImplicit):
238         (WebCore::CSSMutableStyleDeclaration::setProperty):
239         (WebCore::CSSMutableStyleDeclaration::setPropertyInternal):
240         (WebCore::CSSMutableStyleDeclaration::setStringProperty):
241         (WebCore::CSSMutableStyleDeclaration::setImageProperty):
242         (WebCore::CSSMutableStyleDeclaration::parseDeclaration):
243         (WebCore::CSSMutableStyleDeclaration::addParsedProperties):
244         (WebCore::CSSMutableStyleDeclaration::addParsedProperty):
245         (WebCore::CSSMutableStyleDeclaration::setLengthProperty):
246         (WebCore::CSSMutableStyleDeclaration::length):
247         (WebCore::CSSMutableStyleDeclaration::item):
248         (WebCore::CSSMutableStyleDeclaration::cssText):
249         (WebCore::CSSMutableStyleDeclaration::setCssText):
250         (WebCore::CSSMutableStyleDeclaration::merge):
251         (WebCore::CSSMutableStyleDeclaration::removePropertiesInSet):
252         (WebCore::CSSMutableStyleDeclaration::copy):
253         (WebCore::CSSMutableStyleDeclaration::findPropertyWithId):
254         * css/CSSMutableStyleDeclaration.h:
255         (WebCore::CSSMutableStyleDeclarationConstIterator::operator*):
256         (WebCore::CSSMutableStyleDeclarationConstIterator::operator->):
257         (WebCore::CSSMutableStyleDeclarationConstIterator::operator!=):
258         (WebCore::CSSMutableStyleDeclarationConstIterator::operator==):
259         (WebCore::CSSMutableStyleDeclaration::create):
260         (WebCore::CSSMutableStyleDeclaration::begin):
261         (WebCore::CSSMutableStyleDeclaration::end):
262         (WebCore::CSSMutableStyleDeclarationConstIterator::CSSMutableStyleDeclarationConstIterator):
263         (WebCore::CSSMutableStyleDeclarationConstIterator::~CSSMutableStyleDeclarationConstIterator):
264         (WebCore::CSSMutableStyleDeclarationConstIterator::operator=):
265         (WebCore::CSSMutableStyleDeclarationConstIterator::operator++):
266         (WebCore::CSSMutableStyleDeclarationConstIterator::operator--):
267         * css/CSSProperty.h:
268         (WTF::):
269         * css/CSSStyleDeclaration.cpp:
270         (WebCore::CSSStyleDeclaration::diff):
271         (WebCore::CSSStyleDeclaration::copyPropertiesInSet):
272         * css/CSSStyleSelector.cpp:
273         (WebCore::CSSStyleSelector::resolveVariablesForDeclaration):
274         (WebCore::CSSStyleSelector::keyframeStylesForAnimation):
275         (WebCore::CSSStyleSelector::applyDeclarations):
276         * dom/EventTarget.h:
277         * editing/ApplyStyleCommand.cpp:
278         (WebCore::StyleChange::init):
279         (WebCore::ApplyStyleCommand::isHTMLStyleNode):
280         (WebCore::ApplyStyleCommand::removeHTMLFontStyle):
281         (WebCore::ApplyStyleCommand::removeCSSStyle):
282         * editing/Editor.cpp:
283         (WebCore::Editor::selectionStartHasStyle):
284         (WebCore::updateState):
285         * editing/ReplaceSelectionCommand.cpp:
286         (WebCore::ReplaceSelectionCommand::handleStyleSpans):
287         * editing/markup.cpp:
288         (WebCore::appendStartMarkup):
289
290 2008-12-06  Simon Fraser  <simon.fraser@apple.com>
291
292         Reviewed by Antti Koivisto, Dan Bernstein
293
294         https://bugs.webkit.org/show_bug.cgi?id=22088
295
296         Fix logic related to repainting when transform changes:
297         If an object has a layer, and the transform changes, then we need
298         to do a repaintIncludingDescendants(), not just a repaint.
299         
300         Test: fast/repaint/transform-repaint-descendants.html
301
302         * rendering/RenderObject.cpp:
303         (WebCore::RenderObject::styleWillChange):
304
305 2008-12-06  Simon Fraser  <simon.fraser@apple.com>
306
307         Reviewed by Dan Bernstein
308
309         https://bugs.webkit.org/show_bug.cgi?id=15739
310
311         When painting the selection on a replaced element, paint
312         using local coordinates so that the selection is correctly
313         painted for transformed elements.
314
315         Test: fast/replaced/selection-rect-transform.html
316
317         * rendering/RenderReplaced.cpp:
318         (WebCore::RenderReplaced::paint):
319
320 2008-12-06  Simon Fraser  <simon.fraser@apple.com>
321
322         Reviewed by Dave Hyatt
323
324         https://bugs.webkit.org/show_bug.cgi?id=15671
325         
326         Fix caret rendering to behave correctly with transforms:
327         * Rename caretRect() methods to localCaretRect() and
328           absoluteCaretBounds() as appropriate
329         * Fix localCaretRect() methods to return a rect in the
330           appropriate coordinates.
331         * Pass tx, ty down through the paintCaret() methods, after fixing them
332           up to account for differences between contents coords, and renderer-local
333           coords (via RenderBlock::offsetForContents()).
334         * Remove m_caretPositionOnLayout from SelectionController, and instead
335           call invalidateSelection() from RenderLayer::scrollToOffset(), because
336           we can no longer assume simple x/y offsets from scrolling with transforms.
337         * Move the logic to compute which RenderObject actually paints the caret into
338           SelectionController::caretRenderer(), rather than having it in RenderBlock.
339         * SelectionController now computes and caches a local caret rect. For invalidation,
340           it computes the absolute bounds of that (possibly transformed) local rect.
341           The local rect is computed in the coordinate system of the RenderObject that
342           will paint the caret (this may require offsetting from the actual renderer
343           at the start of the selection).
344         * Fix LayoutState(RenderObject* root) to take transforms into account
345         * Make offsetFromContainer() a virtual method on RenderObject, and implement
346           the RenderObject version. It's used to map from selection start renderer
347           to caret renderer.
348
349         Test: fast/transforms/transformed-caret.html
350
351         * WebCore.base.exp:
352         * editing/DeleteSelectionCommand.cpp:
353         (WebCore::DeleteSelectionCommand::mergeParagraphs):
354         * editing/SelectionController.cpp:
355         (WebCore::SelectionController::SelectionController):
356         (WebCore::absoluteCaretY):
357         (WebCore::SelectionController::modify):
358         (WebCore::SelectionController::xPosForVerticalArrowNavigation):
359         (WebCore::SelectionController::layout):
360         (WebCore::SelectionController::caretRenderer):
361         (WebCore::SelectionController::localCaretRect):
362         (WebCore::SelectionController::absoluteCaretBounds):
363         (WebCore::SelectionController::caretRepaintRect):
364         (WebCore::SelectionController::recomputeCaretRect):
365         (WebCore::SelectionController::invalidateCaretRect):
366         (WebCore::SelectionController::paintCaret):
367         (WebCore::SelectionController::caretRendersInsideNode):
368         * editing/SelectionController.h:
369         * editing/VisiblePosition.cpp:
370         (WebCore::VisiblePosition::localCaretRect):
371         (WebCore::VisiblePosition::absoluteCaretBounds):
372         (WebCore::VisiblePosition::xOffsetForVerticalNavigation):
373         * editing/VisiblePosition.h:
374         * editing/mac/SelectionControllerMac.mm:
375         (WebCore::SelectionController::notifyAccessibilityForSelectionChange):
376         * html/HTMLElement.cpp:
377         (WebCore::HTMLElement::isContentEditable):
378         * page/AccessibilityRenderObject.cpp:
379         (WebCore::AccessibilityRenderObject::boundsForVisiblePositionRange):
380         * page/Frame.cpp:
381         (WebCore::Frame::firstRectForRange):
382         (WebCore::Frame::selectionLayoutChanged):
383         (WebCore::Frame::paintCaret):
384         (WebCore::Frame::paintDragCaret):
385         (WebCore::Frame::revealSelection):
386         (WebCore::Frame::revealCaret):
387         * page/Frame.h:
388         * rendering/LayoutState.cpp:
389         (WebCore::LayoutState::LayoutState):
390         * rendering/RenderBlock.cpp:
391         (WebCore::RenderBlock::paintCaret):
392         (WebCore::RenderBlock::paintObject):
393         (WebCore::RenderBlock::positionForCoordinates):
394         (WebCore::RenderBlock::offsetForContents):
395         * rendering/RenderBlock.h:
396         * rendering/RenderBox.cpp:
397         (WebCore::RenderBox::localCaretRect):
398         * rendering/RenderBox.h:
399         * rendering/RenderFlow.cpp:
400         (WebCore::RenderFlow::localCaretRect):
401         * rendering/RenderFlow.h:
402         * rendering/RenderLayer.cpp:
403         (WebCore::RenderLayer::scrollToOffset):
404         * rendering/RenderObject.cpp:
405         (WebCore::RenderObject::localCaretRect):
406         * rendering/RenderObject.h:
407         * rendering/RenderSVGInlineText.cpp:
408         (WebCore::RenderSVGInlineText::localCaretRect):
409         * rendering/RenderSVGInlineText.h:
410         * rendering/RenderText.cpp:
411         (WebCore::RenderText::RenderText):
412         (WebCore::RenderText::localCaretRect):
413         * rendering/RenderText.h:
414
415 2008-12-06  David Kilzer  <ddkilzer@apple.com>
416
417         Bug 22711: Current svn (build 39065) fails to compile
418
419         <https://bugs.webkit.org/show_bug.cgi?id=22711>
420
421         BUILD FIX for r39065: Forgot parentheses after "document".
422
423         Bug 22666: Clean up data structures used when collecting URLs of subresources for webarchives
424         <https://bugs.webkit.org/show_bug.cgi?id=22666>
425
426         * svg/SVGFEImageElement.cpp:
427         (WebCore::SVGFEImageElement::addSubresourceAttributeURLs): Changed
428         document to document().
429
430 2008-12-06  Dmitry Titov  <dimich@chromium.org>
431
432         Reviewed by Alexey Proskuryakov.
433
434         https://bugs.webkit.org/show_bug.cgi?id=22710
435         Memory leak due to circular reference Document->DOMTimer->ScheduledAction->[JS objects]->Document
436
437         * bindings/js/DOMTimer.cpp:
438         (WebCore::DOMTimer::stop): Delete ScheduledAction, which contains a protected object.
439
440 2008-12-06  David Kilzer  <ddkilzer@apple.com>
441
442         Bug 22666: Clean up data structures used when collecting URLs of subresources for webarchives
443
444         <https://bugs.webkit.org/show_bug.cgi?id=22666>
445
446         Reviewed by Darin Adler.
447
448         When creating a webarchive from WebCore::LegacyWebArchive::create(),
449         HashSet<String>, Vector<KURL> and Vector<String> were all used to
450         store a list of URLs for resources found in the document.  Instead
451         use a single ListHashSet<KURL> to store the list and resolve the
452         relative URLs as they're added.  We use a new inline method called
453         WebCore::addSubresourceURL() to add KURL objects to the ListHashSet
454         to prevent "null" KURL objects from crashing in the KURL hashing
455         function.
456
457         * WebCore.base.exp: Changed export of
458         WebCore::Node::getSubresourceURLs() to take a ListHashSet<KURL>
459         argument instead of a Vector<KURL>.
460
461         * WebCore.xcodeproj/project.pbxproj: Marked KURLHash.h as a private
462         header for use in WebKit.
463
464         * css/CSSStyleSheet.cpp:
465         (WebCore::CSSStyleSheet::addSubresourceStyleURLs): Renamed from
466         addSubresourceURLStrings().  Changed to use ListHashSet<KURL>
467         instead of HashSet<String>.  Cleaned up code.
468         * css/CSSStyleSheet.h:
469         (WebCore::CSSStyleSheet::addSubresourceStyleURLs): Ditto.
470         * css/StyleSheet.h:
471         (WebCore::StyleSheet::addSubresourceStyleURLs): Ditto.
472
473         * dom/Node.cpp:
474         (WebCore::Node::getSubresourceURLs): Changed to use
475         ListHashSet<KURL> instead of Vector<KURL>.  Cleaned up code.
476         * dom/Node.h:
477         (WebCore::Node::getSubresourceURLs): Ditto.
478         (WebCore::Node::addSubresourceAttributeURLs): Renamed from
479         getSubresourceAttributeStrings().  Changed to use ListHashSet<KURL>
480         instead of Vector<String>.
481         (WebCore::addSubresourceURL): Added.  Safely adds new KURL objects
482         to a ListHashSet<KURL> object.  A "null" KURL object will cause the
483         hash function to crash since it contains a null StringImpl.  Used in
484         Node::addSubresourceAttributeURLs() and addSubresourceStyleURLs() in
485         the style subsystem.
486
487         * dom/ProcessingInstruction.cpp:
488         (WebCore::ProcessingInstruction::addSubresourceAttributeURLs):
489         Renamed from getSubresourceAttributeStrings().  Changed to use
490         ListHashSet<KURL> instead of Vector<String>.  Use
491         WebCore::addSubresourceURL() to add new KURL objects.
492         * dom/ProcessingInstruction.h: Ditto.
493         * html/HTMLBodyElement.cpp:
494         (WebCore::HTMLBodyElement::addSubresourceAttributeURLs): Ditto.
495         * html/HTMLBodyElement.h: Ditto.
496         * html/HTMLEmbedElement.cpp:
497         (WebCore::HTMLEmbedElement::addSubresourceAttributeURLs): Ditto.
498         * html/HTMLEmbedElement.h: Ditto.
499         * html/HTMLImageElement.cpp:
500         (WebCore::HTMLImageElement::addSubresourceAttributeURLs): Ditto.
501         * html/HTMLImageElement.h: Ditto.
502         * html/HTMLInputElement.cpp:
503         (WebCore::HTMLInputElement::addSubresourceAttributeURLs): Ditto.
504         * html/HTMLInputElement.h: Ditto.
505         * html/HTMLLinkElement.cpp:
506         (WebCore::HTMLLinkElement::addSubresourceAttributeURLs): Ditto.
507         * html/HTMLLinkElement.h: Ditto.
508         * html/HTMLObjectElement.cpp:
509         (WebCore::HTMLObjectElement::addSubresourceAttributeURLs): Ditto.
510         * html/HTMLObjectElement.h: Ditto.
511         * html/HTMLParamElement.cpp:
512         (WebCore::HTMLParamElement::addSubresourceAttributeURLs): Ditto.
513         * html/HTMLParamElement.h: Ditto.
514         * html/HTMLScriptElement.cpp:
515         (WebCore::HTMLScriptElement::addSubresourceAttributeURLs): Ditto.
516         * html/HTMLScriptElement.h: Ditto.
517         * html/HTMLStyleElement.cpp:
518         (WebCore::HTMLStyleElement::addSubresourceAttributeURLs): Ditto.
519         * html/HTMLStyleElement.h: Ditto.
520         * html/HTMLTableCellElement.cpp:
521         (WebCore::HTMLTableCellElement::addSubresourceAttributeURLs): Ditto.
522         * html/HTMLTableCellElement.h: Ditto.
523         * html/HTMLTableElement.cpp:
524         (WebCore::HTMLTableElement::addSubresourceAttributeURLs): Ditto.
525         * html/HTMLTableElement.h: Ditto.
526
527         * loader/archive/cf/LegacyWebArchive.cpp:
528         (WebCore::LegacyWebArchive::create): Changed from using
529         HashSet<String> to ListHashSet<KURL> for tracking unique
530         subresources.  Changed from using Vector<KURL> to ListHashSet<KURL>
531         when calling WebCore::Node::getSubresourceURLs().  Cleaned up code.
532
533         * svg/SVGCursorElement.cpp:
534         (WebCore::SVGCursorElement::addSubresourceAttributeURLs): Renamed
535         from getSubresourceAttributeStrings().  Changed to use
536         ListHashSet<KURL> instead of Vector<String>.  Use
537         WebCore::addSubresourceURL() to add new KURL objects.
538         * svg/SVGCursorElement.h: Ditto.
539         * svg/SVGFEImageElement.cpp:
540         (WebCore::SVGFEImageElement::addSubresourceAttributeURLs): Ditto.
541         * svg/SVGFEImageElement.h: Ditto.
542         * svg/SVGImageElement.cpp:
543         (WebCore::SVGImageElement::addSubresourceAttributeURLs): Ditto.
544         * svg/SVGImageElement.h: Ditto.
545         * svg/SVGScriptElement.cpp:
546         (WebCore::SVGScriptElement::addSubresourceAttributeURLs): Ditto.
547         * svg/SVGScriptElement.h: Ditto.
548
549 2008-12-05  Brett Wilson  <brettw@chromium.org>
550
551         Reviewed by Darin Adler.
552
553         Make the page group use the proper link hashing functions rather than
554         calling the string hash functions directly. Add Chromium-specfic ifdefs
555         in the visited link computation functions to allow integration.
556
557         * page/PageGroup.cpp:
558         (WebCore::PageGroup::isLinkVisited):
559         (WebCore::PageGroup::addVisitedLink):
560         * platform/LinkHash.cpp:
561         (WebCore::visitedLinkHash):
562         * platform/LinkHash.h:
563
564 2008-12-05  Chris Marrin  <cmarrin@apple.com>
565
566         Reviewed by Dave Hyatt.
567
568         Fix for https://bugs.webkit.org/show_bug.cgi?id=22635
569         For iteration and end events, previous fixes to prevent the deletion of
570         Animation objects (ref counting and hanging onto a ref during event callbacks)
571         was sufficient to prevent dangling pointers. But start events are sent in
572         the styleAvailable() call, which iterates over CompositeAnimation objects,
573         which are not ref counted. So that object can get destroyed in the event
574         handler while still active. So I added refcounting for CompositeAnimations.
575
576         Additionally, when am iterating over the CompositingAnimation list, it can
577         be deleted, which mutates the list. So I now make one pass over the list
578         building a vector of CompositeAnimation objects that need to be called and
579         then iterate over that vector to make the actual calls.
580
581         Finally, to make sure the lifetime of the CompositeAnimation exceeds that of
582         the Animation objects it owns, I now keep a ref to the CompositeAnimation
583         in the timer callback for the iteration and end events. That means I no
584         longer need to keep a ref to the Animation objects themselves in that timer
585         callback, since the CompositeAnimation already has one.
586
587         Tests: animations/animation-iteration-event-destroy-renderer.html
588                animations/animation-start-event-destroy-renderer.html
589
590         * page/animation/AnimationBase.cpp:
591         (WebCore::AnimationBase::updateStateMachine):
592         (WebCore::AnimationBase::animationTimerCallbackFired):
593         * page/animation/AnimationController.cpp:
594         (WebCore::AnimationControllerPrivate::~AnimationControllerPrivate):
595         (WebCore::AnimationControllerPrivate::accessCompositeAnimation):
596         (WebCore::AnimationControllerPrivate::clear):
597         (WebCore::AnimationControllerPrivate::styleAvailable):
598         (WebCore::AnimationControllerPrivate::updateAnimationTimer):
599         (WebCore::AnimationControllerPrivate::animationTimerFired):
600         (WebCore::AnimationControllerPrivate::isAnimatingPropertyOnRenderer):
601         (WebCore::AnimationControllerPrivate::suspendAnimations):
602         (WebCore::AnimationControllerPrivate::resumeAnimations):
603         (WebCore::AnimationControllerPrivate::pauseAnimationAtTime):
604         (WebCore::AnimationControllerPrivate::pauseTransitionAtTime):
605         (WebCore::AnimationController::updateAnimations):
606         (WebCore::AnimationController::setAnimationStartTime):
607         (WebCore::AnimationController::setTransitionStartTime):
608         * page/animation/CompositeAnimation.cpp:
609         (WebCore::CompositeAnimationPrivate::animationController):
610         (WebCore::CompositeAnimationPrivate::isWaitingForStyleAvailable):
611         (WebCore::CompositeAnimationPrivate::~CompositeAnimationPrivate):
612         (WebCore::CompositeAnimationPrivate::clearRenderer):
613         (WebCore::CompositeAnimation::clearRenderer):
614         (WebCore::CompositeAnimation::animationController):
615         (WebCore::CompositeAnimation::isWaitingForStyleAvailable):
616         * page/animation/CompositeAnimation.h:
617         (WebCore::CompositeAnimation::create):
618
619 2008-12-05  David Kilzer  <ddkilzer@apple.com>
620
621         Bug 22609: Provide a build-time choice when generating hash tables for properties of built-in DOM objects
622
623         <https://bugs.webkit.org/show_bug.cgi?id=22609>
624         <rdar://problem/6331749>
625
626         Reviewed by Darin Adler.
627
628         Initial patch by Yosen Lin.  Adapted for ToT WebKit by David Kilzer.
629
630         Added back the code that generates a "compact" hash (instead of a
631         perfect hash) as a build-time option using the
632         ENABLE(PERFECT_HASH_SIZE) macro as defined in Lookup.h.
633
634         * bindings/scripts/CodeGeneratorJS.pm:
635         (GenerateImplementation): Compute the number of elements that will
636         be stored in each hash table and pass it to GenerateHashTable().
637         (GenerateHashTable): Added new second parameter representing the
638         number of elements to store in the compact hash table.  Added back
639         code to compute compact hash tables.  Generate both hash table sizes
640         and emit conditionalized code based on ENABLE(PERFECT_HASH_SIZE).
641
642 2008-12-05  Brett Wilson  <brettw@chromium.org>
643
644         Fix build bustage from previous patch.
645
646         * css/CSSSelector.h:
647
648 2008-12-05  Brett Wilson  <brettw@chromium.org>
649
650         Reviewed by Eric Seidel.
651
652         Add a missing include for OwnPtr to make CSSSelector compile without
653         precompiled headers.
654
655         * css/CSSSelector.h:
656
657 2008-12-05  Finnur Thorarinsson  <finnur.webkit@gmail.com>
658
659         Reviewed by Darin Adler.
660
661         Bug 22579: Providing a function to ScrollbarClient.h which allows us to get at the tickmarks
662         without relying on high-level WebCore types, as requested by Dave Hyatt.
663         
664         No functional changes, thus no test cases.
665
666         * page/FrameView.cpp:
667         (WebCore::FrameView::getTickmarks):
668         * page/FrameView.h:
669         * platform/ScrollbarClient.h:
670
671 2008-12-05  Dean Jackson  <dino@apple.com>
672
673         Reviewed by David Hyatt.
674
675         Make sure Window event listeners also tell the
676         Document about the event type, so noisy events
677         will be dispatched even if nothing in the document
678         is listening.
679         https://bugs.webkit.org/show_bug.cgi?id=20572
680
681         * dom/Document.cpp:
682         (WebCore::Document::addWindowEventListener):
683
684 2008-12-05  Adam Roben  <aroben@apple.com>
685
686         Windows build fix after r39026
687
688         * platform/network/cf/ResourceRequestCFNet.cpp:
689         (WebCore::ResourceRequest::doUpdatePlatformRequest):
690         (WebCore::ResourceRequest::doUpdateResourceRequest):
691         Add some missing .get()s.
692
693 2008-12-05  Alexey Proskuryakov  <ap@webkit.org>
694
695         Tiger build fix.
696
697         * platform/network/mac/ResourceRequestMac.mm: Define NSUInteger.
698
699 2008-12-05  Alexey Proskuryakov  <ap@webkit.org>
700
701         Reviewed by Darin Adler.
702
703         <rdar://problem/6405599> Tiger Mail crashes when using "Mail Contents of This Page"
704         in Safari before opening a mail message in Mail
705
706         * platform/mac/WebCoreObjCExtras.mm:
707         (WebCoreObjCFinalizeOnMainThread):
708         Don't call initializeThreading: we now expect the caller to do it, to simplify keeping
709         Tiger and post-Tiger behavior in line.
710
711         * bindings/objc/DOMRGBColor.mm:
712         (+[DOMRGBColor initialize]):
713         * bindings/objc/WebScriptObject.mm:
714         (+[WebScriptObject initialize]):
715         * page/mac/AccessibilityObjectWrapper.mm:
716         (+[AccessibilityObjectWrapper initialize]):
717         * platform/mac/SharedBufferMac.mm:
718         (+[WebCoreSharedBufferData initialize]):
719         Call JSC::initializeThreading();
720
721 2008-12-05  Alexey Proskuryakov  <ap@webkit.org>
722
723         Reviewed by Darin Adler.
724
725         <rdar://problem/4072827> Downloaded non-ASCII file name becomes garbled
726
727         * platform/network/ResourceRequestBase.cpp:
728         (WebCore::ResourceRequestBase::setResponseContentDispositionEncodingFallbackArray):
729         * platform/network/ResourceRequestBase.h:
730         * platform/network/cf/ResourceRequestCFNet.cpp:
731         (WebCore::findCFURLRequestSetContentDispositionEncodingFallbackArrayFunction):
732         (WebCore::findCFURLRequestCopyContentDispositionEncodingFallbackArrayFunction):
733         (WebCore::setContentDispositionEncodingFallbackArray):
734         (WebCore::copyContentDispositionEncodingFallbackArray):
735         (WebCore::ResourceRequest::doUpdatePlatformRequest):
736         (WebCore::ResourceRequest::doUpdateResourceRequest):
737         * platform/network/mac/ResourceRequestMac.mm:
738         (WebCore::ResourceRequest::doUpdateResourceRequest):
739         (WebCore::ResourceRequest::doUpdatePlatformRequest):
740         Added a way to specify encoding fallback list for Content-Disposition header.
741
742         * loader/FrameLoader.cpp: (WebCore::FrameLoader::addExtraFieldsToRequest): Generate and
743         pass a list of encodings to try when decoding Content-Disposition header, as described
744         in comments.
745
746 2008-12-05  Alexey Proskuryakov  <ap@webkit.org>
747
748         Reviewed by Darin Adler.
749
750         https://bugs.webkit.org/show_bug.cgi?id=22672
751         ASSERT(m_table) when xhr.onabort creates another xhr or calls setTimeout
752
753         Test: http/tests/xmlhttprequest/send-on-abort.html
754
755         * dom/ScriptExecutionContext.cpp:
756         (WebCore::ScriptExecutionContext::canSuspendActiveDOMObjects):
757         (WebCore::ScriptExecutionContext::suspendActiveDOMObjects):
758         (WebCore::ScriptExecutionContext::resumeActiveDOMObjects):
759         (WebCore::ScriptExecutionContext::stopActiveDOMObjects):
760         Add a comment explaining that ActiveDOMObject methods shouldn't execute arbitrary JS.
761
762         * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::stop): Don't dispatch events. This
763         reverts a recent change that made the behavior slightly closer to Firefox - but the
764         compatibility effect should be very minor if any, and Firefox itself behaves inconsistently.
765
766 2008-12-05  Tobias König <tobias.koenig@nokia.com>
767
768         Reviewed by Simon Hausmann.
769
770         Record required package dependencies for the Qt build for a correct
771         pkg-config file.
772
773         * WebCore.pro:
774
775 2008-12-05  Tor Arne Vestbø  <tavestbo@trolltech.com>
776
777         Rubber-stamped by Simon Hausmann.
778
779         [Qt/Mac] Blacklist QuickTime plugin until we support the QuickDraw drawing model
780
781         * plugins/mac/PluginPackageMac.cpp:
782         (WebCore::PluginPackage::fetchInfo):
783         (WebCore::PluginPackage::isPluginBlacklisted):
784
785 2008-12-05  Jungshik Shin  <jshin@chromium.org>
786
787         Reviewed by Alexey Proskuryakov.
788
789         https://bugs.webkit.org/show_bug.cgi?id=22472
790
791         Revises charset alias map for TextCodecICU.
792         - Uses windows-949 and windows-874 instead of windows-949-2000 and windows-874-2000
793         - Replaces 'windows874' in a couple of place with 'windows-874' (for the canonical name)
794         - Maps 'dos-874' to 'windows-874'. Currently, it's aliases to 'cp874', which is in turn
795           mapped to 'TIS-620'. 'TIS-620' is manually aliased to 'windows-874'. We'd better directly
796           alias 'dos-874' to 'windows-874'.
797         - Replaces 'EUC-CN' with 'GBK' when it's used as the canonical name.
798           Similar to the above case, we're getting rid of indirection that eventually leads to 'GBK' by
799           directly going to 'GBK'.
800         - Adds 'x-uhc' as an alias for 'windows-949'. It's used in some web pages.
801
802         Tests: fast/encoding/char-decoding-mac.html
803                fast/encoding/char-decoding.html
804
805         * platform/text/TextCodecICU.cpp:
806         (WebCore::TextCodecICU::registerExtendedEncodingNames):
807
808 2008-12-04  Kevin Watters  <kevinwatters@gmail.com>
809
810         Reviewed by Kevin Ollivier.
811
812         Add a MIME mapping for the .htm extension to wx and GTK ports.
813         
814         https://bugs.webkit.org/show_bug.cgi?id=22668
815         
816         * platform/gtk/MIMETypeRegistryGtk.cpp:
817         (WebCore::):
818         * platform/wx/MimeTypeRegistryWx.cpp:
819         (WebCore::):
820
821 2008-12-04  Kevin Watters  <kevinwatters@gmail.com>
822
823         Reviewed by Kevin Ollivier.
824
825         Implement basic text paste support in wx and add notImplemented stubs
826         to catch other methods.
827         
828         https://bugs.webkit.org/show_bug.cgi?id=22667
829
830         * platform/wx/PasteboardWx.cpp:
831         (WebCore::Pasteboard::canSmartReplace):
832         (WebCore::Pasteboard::plainText):
833         (WebCore::Pasteboard::documentFragment):
834         (WebCore::Pasteboard::writeImage):
835
836 2008-12-04  Kevin Ollivier  <kevino@theolliviers.com>
837
838         wx build fix for !USE(WXGC) build config.
839
840         * platform/graphics/wx/PathWx.cpp:
841         (WebCore::Path::contains):
842         (WebCore::Path::addLineTo):
843         (WebCore::Path::addQuadCurveTo):
844         (WebCore::Path::addBezierCurveTo):
845         (WebCore::Path::addArcTo):
846         (WebCore::Path::closeSubpath):
847         (WebCore::Path::addArc):
848         (WebCore::Path::addRect):
849         (WebCore::Path::addEllipse):
850         (WebCore::Path::transform):
851         (WebCore::Path::apply):
852         (WebCore::Path::isEmpty):
853
854 2008-12-04  Kevin Watters  <kevinwatters@gmail.com>
855
856         Reviewed by Kevin Ollivier.
857
858         Turn off styled controls until we can implement them properly.
859         
860         https://bugs.webkit.org/show_bug.cgi?id=22662
861
862         * platform/wx/RenderThemeWx.cpp:
863         (WebCore::RenderThemeWx::isControlStyled):
864
865 2008-12-04  Kevin Watters  <kevinwatters@gmail.com>
866
867         Reviewed by Kevin Ollivier.
868
869         wx implementations for Path API.
870
871         https://bugs.webkit.org/show_bug.cgi?id=22661
872
873         * platform/graphics/wx/PathWx.cpp:
874         (WebCore::Path::~Path):
875         (WebCore::Path::contains):
876         (WebCore::Path::addLineTo):
877         (WebCore::Path::addQuadCurveTo):
878         (WebCore::Path::addBezierCurveTo):
879         (WebCore::Path::addArcTo):
880         (WebCore::Path::closeSubpath):
881         (WebCore::Path::addArc):
882         (WebCore::Path::addRect):
883         (WebCore::Path::addEllipse):
884         (WebCore::Path::transform):
885         (WebCore::Path::isEmpty):
886
887 2008-12-04  Julien Chaffraix  <jchaffraix@webkit.org>
888
889         Reviewed by Eric Seidel.
890
891         Bug 22564: Make HTML elements' constructors take a QualifiedName
892         https://bugs.webkit.org/show_bug.cgi?id=22564
893
894         Updated the remaining constructors.
895
896         * bindings/js/JSImageConstructor.cpp:
897         (WebCore::constructImage):
898         * dom/Document.cpp:
899         (WebCore::Document::getCSSCanvasElement):
900         * editing/DeleteButton.cpp:
901         (WebCore::DeleteButton::DeleteButton):
902         * html/HTMLAppletElement.cpp:
903         (WebCore::HTMLAppletElement::HTMLAppletElement):
904         * html/HTMLAppletElement.h:
905         * html/HTMLAreaElement.cpp:
906         (WebCore::HTMLAreaElement::HTMLAreaElement):
907         * html/HTMLAreaElement.h:
908         * html/HTMLBaseFontElement.cpp:
909         (WebCore::HTMLBaseFontElement::HTMLBaseFontElement):
910         * html/HTMLBaseFontElement.h:
911         * html/HTMLCanvasElement.cpp:
912         (WebCore::HTMLCanvasElement::HTMLCanvasElement):
913         * html/HTMLCanvasElement.h:
914         * html/HTMLElementFactory.cpp:
915         (WebCore::hrConstructor):
916         (WebCore::paragraphConstructor):
917         (WebCore::basefontConstructor):
918         (WebCore::fontConstructor):
919         (WebCore::anchorConstructor):
920         (WebCore::imageConstructor):
921         (WebCore::mapConstructor):
922         (WebCore::areaConstructor):
923         (WebCore::canvasConstructor):
924         (WebCore::appletConstructor):
925         (WebCore::embedConstructor):
926         (WebCore::objectConstructor):
927         (WebCore::paramConstructor):
928         (WebCore::scriptConstructor):
929         (WebCore::tableConstructor):
930         (WebCore::tableCaptionConstructor):
931         (WebCore::tableRowConstructor):
932         * html/HTMLEmbedElement.cpp:
933         (WebCore::HTMLEmbedElement::HTMLEmbedElement):
934         * html/HTMLEmbedElement.h:
935         * html/HTMLFontElement.cpp:
936         (WebCore::HTMLFontElement::HTMLFontElement):
937         * html/HTMLFontElement.h:
938         * html/HTMLHRElement.cpp:
939         (WebCore::HTMLHRElement::HTMLHRElement):
940         * html/HTMLHRElement.h:
941         * html/HTMLImageElement.cpp:
942         (WebCore::HTMLImageElement::HTMLImageElement):
943         * html/HTMLImageElement.h:
944         * html/HTMLMapElement.cpp:
945         (WebCore::HTMLMapElement::HTMLMapElement):
946         * html/HTMLMapElement.h:
947         * html/HTMLObjectElement.cpp:
948         (WebCore::HTMLObjectElement::HTMLObjectElement):
949         * html/HTMLObjectElement.h:
950         * html/HTMLParagraphElement.cpp:
951         (WebCore::HTMLParagraphElement::HTMLParagraphElement):
952         * html/HTMLParagraphElement.h:
953         * html/HTMLParamElement.cpp:
954         (WebCore::HTMLParamElement::HTMLParamElement):
955         * html/HTMLParamElement.h:
956         * html/HTMLParser.cpp:
957         (WebCore::HTMLParser::handleError):
958         (WebCore::HTMLParser::mapCreateErrorCheck):
959         (WebCore::HTMLParser::handleIsindex):
960         * html/HTMLScriptElement.cpp:
961         (WebCore::HTMLScriptElement::HTMLScriptElement):
962         * html/HTMLScriptElement.h:
963         * html/HTMLTableCaptionElement.cpp:
964         (WebCore::HTMLTableCaptionElement::HTMLTableCaptionElement):
965         * html/HTMLTableCaptionElement.h:
966         * html/HTMLTableElement.cpp:
967         (WebCore::HTMLTableElement::HTMLTableElement):
968         (WebCore::HTMLTableElement::createCaption):
969         (WebCore::HTMLTableElement::insertRow):
970         * html/HTMLTableElement.h:
971         * html/HTMLTableRowElement.cpp:
972         (WebCore::HTMLTableRowElement::HTMLTableRowElement):
973         * html/HTMLTableRowElement.h:
974         * html/HTMLTableSectionElement.cpp:
975         (WebCore::HTMLTableSectionElement::insertRow):
976         * html/HTMLViewSourceDocument.cpp:
977         (WebCore::HTMLViewSourceDocument::createContainingTable):
978         (WebCore::HTMLViewSourceDocument::addLine):
979         * loader/ImageDocument.cpp:
980         (WebCore::ImageDocumentElement::ImageDocumentElement):
981
982 2008-12-04  Eric Seidel  <eric@webkit.org>
983
984         No review, build fix only.
985
986         Add file missing from last commit.
987
988         * bindings/js/ScriptState.h: Added.
989
990 2008-12-04  Dimitri Glazkov  <dglazkov@chromium.org>
991
992         Reviewed by Geoff Garen.
993
994         Implement ScriptState abstraction (initially, a simple typedef)
995         as means of carrying exception information across bindings boundaries
996         and in a script engine-independent way.
997
998         * WebCore.vcproj/WebCore.vcproj:
999         * WebCore.xcodeproj/project.pbxproj:
1000         * bindings/js/JSDOMBinding.cpp:
1001         (WebCore::scriptStateFromNode):
1002         * bindings/js/JSDOMBinding.h:
1003         * bindings/js/JSNodeFilterCondition.h:
1004         * bindings/js/ScriptState.h: Added.
1005         * dom/NodeFilter.cpp:
1006         (WebCore::NodeFilter::acceptNode):
1007         * dom/NodeFilter.h:
1008         (WebCore::NodeFilter::acceptNode):
1009         * dom/NodeFilterCondition.cpp:
1010         (WebCore::NodeFilterCondition::acceptNode):
1011         * dom/NodeFilterCondition.h:
1012         * dom/NodeIterator.cpp:
1013         (WebCore::NodeIterator::nextNode):
1014         (WebCore::NodeIterator::previousNode):
1015         * dom/NodeIterator.h:
1016         (WebCore::NodeIterator::nextNode):
1017         (WebCore::NodeIterator::previousNode):
1018         * dom/Traversal.cpp:
1019         (WebCore::Traversal::acceptNode):
1020         * dom/Traversal.h:
1021         * dom/TreeWalker.cpp:
1022         (WebCore::TreeWalker::parentNode):
1023         (WebCore::TreeWalker::firstChild):
1024         (WebCore::TreeWalker::lastChild):
1025         (WebCore::TreeWalker::previousSibling):
1026         (WebCore::TreeWalker::nextSibling):
1027         (WebCore::TreeWalker::previousNode):
1028         (WebCore::TreeWalker::nextNode):
1029         * dom/TreeWalker.h:
1030         (WebCore::TreeWalker::parentNode):
1031         (WebCore::TreeWalker::firstChild):
1032         (WebCore::TreeWalker::lastChild):
1033         (WebCore::TreeWalker::previousSibling):
1034         (WebCore::TreeWalker::nextSibling):
1035         (WebCore::TreeWalker::previousNode):
1036         (WebCore::TreeWalker::nextNode):
1037
1038 2008-12-04  Pierre-Olivier Latour  <pol@apple.com>
1039
1040         Reviewed by Dan Bernstein.
1041
1042         Fixed pauseTransitionAtTimeOnElementWithId() in DRT asserting when passed invalid property name
1043         and potential similar issue with pauseAnimationAtTimeOnElementWithId().
1044
1045         https://bugs.webkit.org/show_bug.cgi?id=22641
1046
1047         * page/animation/CompositeAnimation.cpp:
1048         (WebCore::CompositeAnimationPrivate::pauseAnimationAtTime):
1049         (WebCore::CompositeAnimationPrivate::pauseTransitionAtTime):
1050
1051 2008-12-04  Dimitri Glazkov  <dglazkov@chromium.org>
1052
1053         Reviewed by Darin Adler.
1054
1055         Remove unused Completion.h include.
1056
1057         * html/CanvasRenderingContext2D.cpp: Removed Completion.h include.
1058
1059 2008-11-13  David Hyatt  <hyatt@apple.com>
1060
1061         Fix a bug in ScrollView's refactoring.  An isVisible check should have been isSelfVisible.
1062
1063         Reviewed by Darin Adler
1064
1065         * platform/ScrollView.cpp:
1066         (WebCore::ScrollView::setParentVisible):
1067
1068 2008-12-04  Friedemann Kleint  <friedemann.kleint@nokia.com>
1069
1070         Reviewed by Tor Arne Vestbø.
1071
1072         Fix small translation glitch in the Qt file chooser.
1073
1074         * platform/qt/FileChooserQt.cpp:
1075         (WebCore::FileChooser::basenameForWidth):
1076
1077 2008-12-04  Tor Arne Vestbø  <tavestbo@trolltech.com>
1078
1079         Rubber-stamped by Simon Hausmann.
1080
1081         Blacklist Silverlight plugin on Qt/Mac until supported
1082
1083         Currently the plugin crashes with a corrupted stack trace, possibly
1084         related to https://bugs.webkit.org/show_bug.cgi?id=20635
1085
1086         * plugins/mac/PluginPackageMac.cpp:
1087         (WebCore::PluginPackage::fetchInfo):
1088         (WebCore::PluginPackage::isPluginBlacklisted):
1089
1090 2008-12-03  Dmitry Titov  <dimich@chromium.org>
1091
1092         Reviewed by Alexey Proskuryakov.
1093
1094         Fix non-Mac build.
1095
1096         * page/Chrome.cpp: (WebCore::PageGroupLoadDeferrer::~PageGroupLoadDeferrer):
1097
1098 2008-12-03  David Levin  <levin@chromium.org>
1099
1100         Reviewed by Alexey Proskuryakov.
1101
1102         Remove uses of document() in XMLHttpRequest where simple.
1103         https://bugs.webkit.org/show_bug.cgi?id=22619
1104
1105         * xml/XMLHttpRequest.cpp:
1106         (WebCore::XMLHttpRequest::responseXML):
1107         Return NULL in the worker case which is according to spec (and avoids using document()).
1108
1109         (WebCore::XMLHttpRequest::callReadyStateChangeListener):
1110         (WebCore::XMLHttpRequest::initSend):
1111         Use scriptExecutionContext() instead of document().
1112
1113 2008-12-03  David Levin  <levin@chromium.org>
1114
1115         Reviewed by Alexey Proskuryakov.
1116
1117         Make ScriptExecutionContextTaskWorkerTask::performTask a pure virtual function.
1118         https://bugs.webkit.org/show_bug.cgi?id=22642
1119
1120         * dom/Document.cpp:
1121         (WebCore::ScriptExecutionContextTaskTimer::ScriptExecutionContextTaskTimer):
1122         (WebCore::ScriptExecutionContextTaskTimer::fired):
1123         (WebCore::PerformTaskContext::PerformTaskContext):
1124         (WebCore::performTask):
1125         (WebCore::Document::postTask):
1126         * dom/Document.h:
1127         * dom/ScriptExecutionContext.cpp:
1128         * dom/ScriptExecutionContext.h:
1129         * dom/WorkerContext.cpp:
1130         (WebCore::ScriptExecutionContextTaskWorkerTask::create):
1131         (WebCore::ScriptExecutionContextTaskWorkerTask::ScriptExecutionContextTaskWorkerTask):
1132         (WebCore::ScriptExecutionContextTaskWorkerTask::performTask):
1133         (WebCore::WorkerContext::postTask):
1134         * dom/WorkerContext.h:
1135
1136 2008-12-03  Dmitry Titov  <dimich@chromium.org>
1137
1138         Reviewed by Alexey Proskuryakov.
1139
1140         Using ActiveDOMObject as base class for DOMTimer.
1141         https://bugs.webkit.org/show_bug.cgi?id=22620
1142
1143         Using ActiveDOMObject simplifies the code because ActiveDOMObject
1144         is wired for stop/pause/resume on loading/unloading/caching the page etc
1145         so the timer-specific code that does the same can be removed.
1146         In addition, timers can be now paused/resumed 'in place' which
1147         makes it unnecessary to 'serialize' them into special PausedTimeouts
1148         instance, so pause/resumeTimeouts implementation in JSDOMWindowBase can also be removed.
1149         Also, moving TimeoutMap from JSDOMWindowBase to Document matches lifetime
1150         of timeouts and makes it possible to not roundtrip them via PausedTimeouts 
1151         every time when JSDOMWindow wrapper is destroyed while the page is in the b/f cache.
1152
1153         Timeouts are now paused with other ActiveDOMObjects:
1154         - before creating CachedPage in FrameLoader::commitProvisionalLoad()
1155         - in JavaScriptDebugServer::setJavaScriptPaused
1156         - during modal UI operations in Chrome::*
1157         this is equivalent to previous usage of JSDOMWindowBase::pauseTimeouts()
1158
1159         Timeouts are stopped to prevent future firing from:
1160         - FrameLoader::clear()
1161         - FrameLoader::frameDetached()
1162         this is equivalent to previous usage of JSDOMWindowBase::clearAllTimeouts()
1163
1164         This is also one of the steps to having timers in Workers. See the plan of
1165         the next steps in the bug above.
1166
1167         * bindings/js/DOMTimer.cpp:
1168         (WebCore::DOMTimer::DOMTimer):
1169         (WebCore::DOMTimer::fired):
1170         (WebCore::DOMTimer::hasPendingActivity):
1171         (WebCore::DOMTimer::contextDestroyed):
1172         (WebCore::DOMTimer::stop):
1173         (WebCore::DOMTimer::suspend):
1174         (WebCore::DOMTimer::resume):
1175         (WebCore::DOMTimer::canSuspend): Implemented ActiveDOMObject methods.
1176
1177         * bindings/js/DOMTimer.h:
1178         * bindings/js/JSDOMBinding.cpp: ActiveDOMObject can have no JS wrapper
1179         (WebCore::markActiveObjectsForContext): 
1180
1181         * bindings/js/JSDOMWindowBase.cpp:
1182         (WebCore::JSDOMWindowBase::~JSDOMWindowBase):
1183         (WebCore::JSDOMWindowBase::clear):
1184         (WebCore::JSDOMWindowBase::installTimeout):
1185         (WebCore::JSDOMWindowBase::removeTimeout):
1186         (WebCore::JSDOMWindowBase::timerFired):
1187         (WebCore::JSDOMWindowBase::disconnectFrame):
1188         * bindings/js/JSDOMWindowBase.h:
1189         * bindings/js/ScriptController.cpp:
1190         * bindings/js/ScriptController.h:
1191
1192         * dom/Document.cpp: Document now holds a hash map id->timeout
1193         (WebCore::Document::addTimeout):
1194         (WebCore::Document::removeTimeout):
1195         (WebCore::Document::findTimeout):
1196         * dom/Document.h:
1197         * history/CachedPage.cpp:
1198         (WebCore::CachedPage::CachedPage):
1199         (WebCore::CachedPage::restore):
1200         (WebCore::CachedPage::clear):
1201         * history/CachedPage.h:
1202         * inspector/JavaScriptDebugServer.cpp:
1203         (WebCore::JavaScriptDebugServer::~JavaScriptDebugServer):
1204         (WebCore::JavaScriptDebugServer::setJavaScriptPaused):
1205         * inspector/JavaScriptDebugServer.h:
1206
1207         * loader/FrameLoader.cpp:
1208         (WebCore::FrameLoader::commitProvisionalLoad): 
1209         removed clearAllTimeouts since all ActiveDOMObjects will be stopped in FrameLoader::clear();
1210         I don't see how the old comment can be correct - the code in the same method proceeds to invoke 'onunload'
1211         and then calls into client which can be external code and can cause any active object created in onunload
1212         to fire. We can stop them all before firing onunload but it does not make a lot of sense.
1213         I have a test to go with the next patch which verifies that timers set in onunload do not fire.
1214
1215         (WebCore::FrameLoader::open):
1216         * page/Chrome.cpp:
1217         (WebCore::PageGroupLoadDeferrer::PageGroupLoadDeferrer):
1218         (WebCore::PageGroupLoadDeferrer::~PageGroupLoadDeferrer):
1219
1220 2008-12-03  Justin Garcia  <justin.garcia@apple.com>
1221
1222         Reviewed by Beth Dakin.
1223
1224         <rdar://problem/6018653> Extra blank line when pasting paragraph in plain text
1225         
1226         In SnowLeopard, Mail occasionally adds an empty, unstyled paragraph at the
1227         end of pasted content so that users don't get stuck with non-standard pargraph
1228         spacing.  This content threw off our handling of interchange newlines.  Any interchange
1229         newline, regardless of it's position in the incoming fragment was considered to be
1230         "at the start" of the fragment, and would result in us inserting in a newline before 
1231         inserted content.  This patch makes the checks for interchange newlines more strict, 
1232         and treats interchange newlines found elsewhere as normal <br>s.
1233
1234         * editing/ReplaceSelectionCommand.cpp:
1235         (WebCore::ReplacementFragment::ReplacementFragment):
1236         (WebCore::ReplacementFragment::removeInterchangeNodes):
1237         * editing/VisiblePosition.cpp:
1238         (WebCore::VisiblePosition::init):
1239         (WebCore::VisiblePosition::canonicalPosition):
1240         * editing/VisiblePosition.h:
1241
1242 2008-12-03  Eric Seidel  <eric@webkit.org>
1243
1244         Rubber-stamped by David Hyatt.
1245
1246         Bring the WebCore chromium build a couple steps closer to building.
1247
1248         * WebCore.scons:
1249
1250 2008-12-03  Kevin Ollivier  <kevino@theolliviers.com>
1251
1252         wx build fix.
1253
1254         * WebCoreSources.bkl:
1255
1256 2008-12-03  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
1257
1258         Reviewed by George Staikos.
1259
1260         Fixes: https://bugs.webkit.org/show_bug.cgi?id=22636
1261
1262         Implement WML variable substitution & validation.
1263         Created a framework for scriptable WML layout tests, that are able to test variable substiution & validation.
1264
1265         Tests: wml/variable-reference-invalid-character.html
1266                wml/variable-reference-valid.html
1267
1268         * wml/WMLVariables.cpp:
1269         (WebCore::isValidFirstVariableNameCharacter):
1270         (WebCore::isValidVariableNameCharacter):
1271         (WebCore::isValidVariableEscapingModeString):
1272         (WebCore::isValidVariableName):
1273         (WebCore::containsVariableReference):
1274         (WebCore::substituteVariableReferences):
1275         * wml/WMLVariables.h:
1276
1277 2008-12-03  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
1278
1279         Reviewed by Cameron Zwarich.
1280
1281         Further preparations for WML layout tests.
1282         - Enable variable substitution in Text.cpp - if the parent is a WMLElement derived class.
1283         - Dump WMLMessageSource messages to the console, just like it's done for JSMessageSource
1284         - Add helper method in Document.idl, to reset the WML page state to a well-known default state.
1285           (will be used in the upcoming LayoutTests/wml testcases)
1286
1287          * dom/Document.cpp:
1288         (WebCore::Document::resetWMLPageState):
1289         * dom/Document.h:
1290         * dom/Document.idl:
1291         * dom/Text.cpp:
1292         (WebCore::Text::insertedIntoDocument):
1293         * dom/Text.h:
1294         * page/Console.cpp:
1295         (WebCore::Console::addMessage):
1296         * wml/WMLPageState.h: Readd heper function
1297         (WebCore::WMLPageState::hasVariables):
1298
1299 2008-12-03  Antti Koivisto  <antti@apple.com>
1300
1301         Reviewed by Sam Weinig.
1302
1303         Don't leak selectors in case selector list parsing failed.
1304
1305         * css/CSSGrammar.y:
1306         * css/CSSParser.cpp:
1307         (WebCore::CSSParser::~CSSParser):
1308
1309 2008-12-03  Chris Marrin  <cmarrin@apple.com>
1310
1311         Reviewed by Dave Hyatt.
1312
1313         Fix https://bugs.webkit.org/show_bug.cgi?id=22520
1314
1315         This is a regression (causes a crash of LayoutTests/animations/transform-animation-event-destroy-element.html).
1316         This patch fixes the testcase.
1317
1318         This is another case of animations getting destroyed in the end animation callback and causing dangling
1319         pointers on return. This one involves iterating over the CompositeAnimation, which has been destroyed.
1320         So I now check for a null m_object pointer (which is nullified when the CompositeAnimation is destroyed)
1321         and skip that call.
1322
1323         * page/animation/AnimationBase.cpp:
1324         (WebCore::AnimationBase::updateStateMachine):
1325
1326 2008-12-03  Antti Koivisto  <antti@apple.com>
1327
1328         Reviewed by Darin Adler.
1329
1330         https://bugs.webkit.org/show_bug.cgi?id=22379
1331         Make CSSOM use less memory
1332
1333         Reduce size of the CSSSelector by one more pointer by using an array
1334         instead of a linked list to store them.
1335
1336         * WebCore.xcodeproj/project.pbxproj:
1337         * css/CSSGrammar.y:
1338         * css/CSSParser.cpp:
1339         (WebCore::CSSParser::CSSParser):
1340         (WebCore::CSSParser::parseSelector):
1341         (WebCore::CSSParser::createStyleRule):
1342         * css/CSSParser.h:
1343         (WebCore::CSSParser::reusableSelectorVector):
1344         * css/CSSSelector.h:
1345         (WebCore::CSSSelector::CSSSelector):
1346         (WebCore::CSSSelector::~CSSSelector):
1347         (WebCore::CSSSelector::isLastInSelectorList):
1348         (WebCore::CSSSelector::setLastInSelectorList):
1349         * css/CSSStyleRule.cpp:
1350         (WebCore::CSSStyleRule::CSSStyleRule):
1351         (WebCore::CSSStyleRule::~CSSStyleRule):
1352         (WebCore::CSSStyleRule::selectorText):
1353         * css/CSSStyleRule.h:
1354         (WebCore::CSSStyleRule::adoptSelectorVector):
1355         (WebCore::CSSStyleRule::selectorList):
1356         * css/CSSStyleSelector.cpp:
1357         (WebCore::CSSRuleSet::addRulesFromSheet):
1358         * dom/Node.cpp:
1359         (WebCore::forEachSelector):
1360         (WebCore::selectorNeedsNamespaceResolution):
1361         (WebCore::Node::querySelector):
1362         (WebCore::Node::querySelectorAll):
1363         * dom/SelectorNodeList.cpp:
1364         (WebCore::createSelectorNodeList):
1365         * dom/SelectorNodeList.h:
1366
1367 2008-12-03  Alexey Proskuryakov  <ap@webkit.org>
1368
1369         Reviewed by Darin Adler.
1370
1371         https://bugs.webkit.org/show_bug.cgi?id=22630
1372         Assertion failure in XMLHttpRequest::contextDestroyed
1373
1374         Test: http/tests/xmlhttprequest/close-window.html
1375
1376         * loader/FrameLoader.cpp:
1377         (WebCore::FrameLoader::clear):
1378         (WebCore::FrameLoader::commitProvisionalLoad):
1379         Move stopping active objects to clear(), so that closing a window is also covered.
1380
1381         * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::abort): Protect the object in abort(),
1382         because internalAbort() deref()'s.
1383
1384 2008-12-03  Dean Jackson  <dino@apple.com>
1385
1386         Reviewed by Dan Bernstein.
1387
1388         Implement CSS 3 <angle> turn unit and support it
1389         in rotations.
1390         https://bugs.webkit.org/show_bug.cgi?id=22497
1391
1392         * css/CSSGrammar.y:
1393         * css/CSSParser.cpp:
1394         (WebCore::CSSParser::validUnit):
1395         (WebCore::unitFromString):
1396         (WebCore::CSSParser::lex):
1397         * css/CSSPrimitiveValue.cpp:
1398         (WebCore::CSSPrimitiveValue::cssText):
1399         (WebCore::CSSPrimitiveValue::parserValue):
1400         * css/CSSPrimitiveValue.h:
1401         (WebCore::CSSPrimitiveValue::):
1402         * css/CSSStyleSelector.cpp:
1403         (WebCore::CSSStyleSelector::createTransformOperations):
1404         * css/tokenizer.flex:
1405
1406 2008-12-03  Dirk Schulze  <krit@webkit.org>
1407
1408         Reviewed by Nikolas Zimmermann.
1409
1410         Make use of the gradient code in GraphicsContext and get rid of most of the
1411         platform dependent code.
1412
1413         SVG should use the new Gradient support on GraphicsContext
1414         https://bugs.webkit.org/show_bug.cgi?id=20543
1415
1416         * GNUmakefile.am:
1417         * WebCore.pro:
1418         * WebCore.vcproj/WebCore.vcproj:
1419         * WebCore.xcodeproj/project.pbxproj:
1420         * platform/graphics/FloatSize.h:
1421         (WebCore::FloatSize::shrunkTo):
1422         * svg/SVGLinearGradientElement.cpp:
1423         (WebCore::SVGLinearGradientElement::buildGradient):
1424         * svg/SVGRadialGradientElement.cpp:
1425         (WebCore::SVGRadialGradientElement::buildGradient):
1426         * svg/graphics/SVGPaintServer.h:
1427         * svg/graphics/SVGPaintServerGradient.cpp:
1428         (WebCore::SVGPaintServerGradient::SVGPaintServerGradient):
1429         (WebCore::SVGPaintServerGradient::~SVGPaintServerGradient):
1430         (WebCore::SVGPaintServerGradient::gradient):
1431         (WebCore::SVGPaintServerGradient::setGradient):
1432         (WebCore::findTextRootObject):
1433         (WebCore::createMaskAndSwapContextForTextGradient):
1434         (WebCore::clipToTextMask):
1435         (WebCore::SVGPaintServerGradient::setup):
1436         (WebCore::SVGPaintServerGradient::renderPath):
1437         (WebCore::SVGPaintServerGradient::teardown):
1438         * svg/graphics/SVGPaintServerGradient.h:
1439         (WebCore::SVGPaintServerGradient::setGradientStops):
1440         (WebCore::SVGPaintServerGradient::gradientStops):
1441         * svg/graphics/SVGPaintServerLinearGradient.h:
1442         * svg/graphics/SVGPaintServerRadialGradient.h:
1443         * svg/graphics/cairo/SVGPaintServerGradientCairo.cpp: Removed.
1444         * svg/graphics/cg/SVGPaintServerCg.cpp:
1445         * svg/graphics/cg/SVGPaintServerGradientCg.cpp: Removed.
1446         * svg/graphics/qt/SVGPaintServerGradientQt.cpp: Removed.
1447         * svg/graphics/qt/SVGPaintServerLinearGradientQt.cpp: Removed.
1448         * svg/graphics/qt/SVGPaintServerRadialGradientQt.cpp: Removed.
1449
1450 2008-12-03  Sam Weinig  <sam@webkit.org>
1451
1452         Reviewed by Mark Rowe.
1453
1454         Fix formatting.
1455
1456         * css/CSSSelector.h:
1457         (WebCore::CSSSelector::createRareData):
1458
1459 2008-12-03  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
1460
1461         Reviewed by Adam Roben.
1462
1463         As Adam Roben noticed, synchronize MessageSource enum with Console.js, and add a comment.
1464
1465         * inspector/front-end/Console.js:
1466         * page/Console.h:
1467
1468 2008-12-03  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
1469
1470         Reviewed by Alexey Proskuryakov.
1471
1472         Next steps to make LayoutTests work:
1473         Never access the main frame from WMLRefreshElement/WMLCardElement, but
1474         the current documents frame (WML layout tests will run in an <iframe>)
1475
1476         Prepare WMLErrorHandling for the case that no tokenizer is available anymore
1477         -> report errors through Console::addMessage(), so they get logged in the
1478            expected layout test results.
1479
1480         * wml/WMLCardElement.cpp:
1481         (WebCore::WMLCardElement::setActiveCardInDocument):
1482         * wml/WMLErrorHandling.cpp:
1483         (WebCore::reportWMLError):
1484         (WebCore::errorMessageForErrorCode):
1485         * wml/WMLErrorHandling.h:
1486         * wml/WMLRefreshElement.cpp:
1487         (WebCore::WMLRefreshElement::executeTask):
1488         * page/Console.cpp: Handle WMLMessageSource.
1489         (WebCore::printMessageSourceAndLevelPrefix):
1490         * page/Console.h: Add WMLMessageSource.
1491         (WebCore::):
1492
1493 2008-12-03  Tor Arne Vestbø  <tavestbo@trolltech.com>
1494
1495         Reviewed by Simon Hausmann.
1496
1497         Allow passing jsNull and jsUndefined to Qt plugins
1498
1499         Currently limited to functions with QString and QVariant arguments,
1500         and properties of these types. Both jsNull and jsUndefined ends up
1501         as default-constructed QStrings and QVariants, which means you can
1502         check for isEmpty() and isValid() in the native plugin code.
1503
1504         Based on patches by Jade Han <jade.han@nokia.com>
1505
1506         * bridge/qt/qt_runtime.cpp:
1507         (JSC::Bindings::convertValueToQVariant):
1508         (JSC::Bindings::findMethodIndex):
1509
1510 2008-12-03  Trenton Schulz  <trenton.schulz@nokia.com>
1511
1512         Reviewed by Simon Hausmann.
1513
1514         Fix the build with Qt for Mac OS X.
1515
1516         * platform/PurgeableBuffer.h: Use the dummy wrappers for now.
1517
1518 2008-12-03  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
1519
1520         Reviewed by Alexey Proskuryakov.
1521
1522         Fix error handling in WMLSetvarElement. If an invalid variable reference is contained
1523         in the 'name' attribute of <setvar>, a 'WMLErrorInvalidVariableName' error should be
1524         reported, instead of 'WMLErrorInvalidVariableReference'.
1525
1526         * wml/WMLElement.cpp:
1527         (WebCore::WMLElement::parseValueSubstitutingVariableReferences):
1528         (WebCore::WMLElement::parseValueForbiddingVariableReferences):
1529         * wml/WMLElement.h:
1530         * wml/WMLSetvarElement.cpp:
1531         (WebCore::WMLSetvarElement::parseMappedAttribute):
1532         * wml/WMLSetvarElement.h:
1533         (WebCore::WMLSetvarElement::name):
1534         (WebCore::WMLSetvarElement::value):
1535
1536 2008-12-03  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
1537
1538         Reviewed by Alexey Proskuryakov.
1539
1540         Preparations to get WML layout tests going.
1541         Make WMLPageState an OwnPtr to Page, and let Page create it on demand.
1542
1543         * page/Page.cpp:
1544         (WebCore::Page::Page):
1545         (WebCore::Page::wmlPageState):
1546         * page/Page.h:
1547         * wml/WMLDocument.cpp:
1548         (WebCore::WMLDocument::WMLDocument):
1549         (WebCore::WMLDocument::finishedParsing):
1550         (WebCore::wmlPageStateForDocument):
1551         * wml/WMLPageState.h: Don't inherit from RefCounted anymore.
1552         (WebCore::WMLPageState::hasVariables): Remove helper function.
1553
1554 2008-12-03  Alexey Proskuryakov  <ap@webkit.org>
1555
1556         Reviewed by Mark Rowe.
1557
1558         https://bugs.webkit.org/show_bug.cgi?id=22627
1559         fast/workers/worker-terminate.html fails randomly
1560
1561         The problem is that worker termination uses script timeouts, so an InterruptedExecutionError
1562         is raised, and it sometimes reaches the main thread.
1563
1564         * dom/WorkerMessagingProxy.cpp:
1565         (WebCore::WorkerExceptionTask::create):
1566         (WebCore::WorkerExceptionTask::WorkerExceptionTask):
1567         (WebCore::WorkerExceptionTask::performTask):
1568         (WebCore::WorkerMessagingProxy::postWorkerException):
1569         * dom/WorkerMessagingProxy.h:
1570         Ignore exceptions that happen in terminated workers.
1571
1572 2008-12-03  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
1573
1574         Reviewed by Alexey Proskuryakov.
1575
1576         Remove some unncessary includes.
1577
1578         * wml/WMLAccessElement.cpp:
1579         * wml/WMLDocument.h:
1580         * wml/WMLRefreshElement.cpp:
1581
1582 2008-12-03  Alexey Proskuryakov  <ap@webkit.org>
1583
1584         Rubber-stamped by Cameron Zwarich and Adam Roben.
1585
1586         Fix a typo: m_executionForbidded.
1587
1588         * bindings/js/WorkerScriptController.cpp:
1589         (WebCore::WorkerScriptController::WorkerScriptController):
1590         (WebCore::WorkerScriptController::evaluate):
1591         (WebCore::WorkerScriptController::forbidExecution):
1592         * bindings/js/WorkerScriptController.h:
1593
1594 2008-12-03  Dean McNamee  <deanm@chromium.org>
1595
1596         Bug 22623: Uninitialized memory access in cache parsing code
1597         <https://bugs.webkit.org/show_bug.cgi?id=22623>
1598
1599         Reviewed by David Kilzer.
1600
1601         Initialize m_haveParsedCacheControlHeader and m_haveParsedPragmaHeader.
1602
1603         * platform/network/ResourceResponseBase.h:
1604         (WebCore::ResourceResponseBase::ResourceResponseBase):
1605
1606 2008-12-03  Antti Koivisto  <antti@apple.com>
1607
1608         Probable build fix.
1609
1610         * WebCoreSources.bkl:
1611
1612 2008-12-03  Antti Koivisto  <antti@apple.com>
1613
1614         Forgot to commit these.
1615
1616         * dom/Node.cpp:
1617         (WebCore::forEachTagSelector):
1618         (WebCore::SelectorNeedsNamespaceResolutionFunctor::operator()):
1619         (WebCore::Node::querySelector):
1620         * dom/SelectorNodeList.cpp:
1621         (WebCore::createSelectorNodeList):
1622
1623 2008-12-03  Antti Koivisto  <antti@apple.com>
1624
1625         Reviewed by Dan Bernstein and Mark Rowe.
1626
1627         https://bugs.webkit.org/show_bug.cgi?id=22379
1628         Make CSSOM use less memory
1629
1630         Reduce size of the CSSSelector by 3/8 by moving rarely used fields to a rare data
1631         struct. Browsing around with some instrumentation showed that ~0.1% of all selectors
1632         encountered had rare data.
1633         
1634         This also eliminates the CSSNthSelector subclass which will make possible to store
1635         CSSSelectors in an array instead of a linked list for futher memory savings.
1636
1637         * css/CSSGrammar.y:
1638         * css/CSSNthSelector.cpp: Removed.
1639         * css/CSSNthSelector.h: Removed.
1640         * css/CSSParser.cpp:
1641         (WebCore::CSSParser::createFloatingSelector):
1642         * css/CSSParser.h:
1643         * css/CSSSelector.cpp:
1644         (WebCore::CSSSelector::specificity):
1645         (WebCore::CSSSelector::operator==):
1646         (WebCore::CSSSelector::selectorText):
1647         (WebCore::CSSSelector::setTagHistory):
1648         (WebCore::CSSSelector::attribute):
1649         (WebCore::CSSSelector::setAttribute):
1650         (WebCore::CSSSelector::setArgument):
1651         (WebCore::CSSSelector::setSimpleSelector):
1652         (WebCore::CSSSelector::parseNth):
1653         (WebCore::CSSSelector::matchNth):
1654         (WebCore::CSSSelector::RareData::parseNth):
1655         (WebCore::CSSSelector::RareData::matchNth):
1656         * css/CSSSelector.h:
1657         (WebCore::CSSSelector::CSSSelector):
1658         (WebCore::CSSSelector::~CSSSelector):
1659         (WebCore::CSSSelector::tagHistory):
1660         (WebCore::CSSSelector::hasAttribute):
1661         (WebCore::CSSSelector::argument):
1662         (WebCore::CSSSelector::simpleSelector):
1663         (WebCore::CSSSelector::RareData::RareData):
1664         (WebCore::CSSSelector::createRareData):
1665         (WebCore::CSSSelector::):
1666         * css/CSSStyleSelector.cpp:
1667         (WebCore::CSSStyleSelector::SelectorChecker::checkSelector):
1668         (WebCore::CSSStyleSelector::SelectorChecker::checkOneSelector):
1669
1670 2008-12-03  Jian Li  <jianli@chromium.org>
1671
1672         Reviewed by Alexey Proskuryakov.
1673
1674         Remove unneeded included file in WorkerThread.cpp.
1675         https://bugs.webkit.org/show_bug.cgi?id=22613
1676
1677         * dom/WorkerThread.cpp: No need to include JSWorkerContext.h.
1678
1679 2008-12-02  Alexey Proskuryakov  <ap@webkit.org>
1680
1681         Reviewed by Maciej Stachowiak.
1682
1683         https://bugs.webkit.org/show_bug.cgi?id=22543
1684         Consolidate ActiveDOMObject page cache interaction
1685
1686         Test: http/tests/xmlhttprequest/abort-on-leaving-page.html
1687
1688         * dom/ActiveDOMObject.cpp:
1689         (WebCore::ActiveDOMObject::canSuspend):
1690         (WebCore::ActiveDOMObject::suspend):
1691         (WebCore::ActiveDOMObject::resume):
1692         * dom/ActiveDOMObject.h:
1693         * dom/ScriptExecutionContext.cpp:
1694         (WebCore::ScriptExecutionContext::canSuspendActiveDOMObjects):
1695         (WebCore::ScriptExecutionContext::suspendActiveDOMObjects):
1696         (WebCore::ScriptExecutionContext::resumeActiveDOMObjects):
1697         * dom/ScriptExecutionContext.h:
1698         Added methods for suspending and resuming active objects.
1699
1700         * dom/Worker.cpp:
1701         (WebCore::Worker::canSuspend):
1702         (WebCore::Worker::stop):
1703         * dom/Worker.h:
1704         Workers cannot be suspended yet. This is a change in behavior, as workers used to keep
1705         running until their owner was destroyed.
1706
1707         * loader/FrameLoader.cpp:
1708         (WebCore::FrameLoader::stopLoading): No longer call stopActiveDOMObjects() here, because
1709         their activity is not necessarily loading.
1710         (WebCore::FrameLoader::canCachePage): Can only cache if all active objects can be suspended.
1711         Previously, stopLoading() cancelled outstanding XMLHttpRequests, which made the page
1712         uncacheable due to no-null main document error.
1713         (WebCore::FrameLoader::commitProvisionalLoad): Suspend or stop active objects, depending on
1714         whether the document will be cached.
1715         (WebCore::FrameLoader::frameDetached): Stop active objects to let them clean up before their
1716         context is destroyed.
1717
1718         * xml/XMLHttpRequest.h: added canSuspend().
1719         * xml/XMLHttpRequest.cpp:
1720         (WebCore::XMLHttpRequest::canSuspend): Only XHRs that are not loading can be suspended.
1721         (WebCore::XMLHttpRequest::stop): Call abort() instead of internalAbort() to dispatch events
1722         for Firefox compatibility. This is a change in behavior that helps test that requests do
1723         get aborted.
1724         (WebCore::XMLHttpRequest::contextDestroyed): The request must have been stopped by now, so
1725         assert that.
1726
1727 2008-12-02  Chris Fleizach  <cfleizach@apple.com>
1728
1729         Reviewed by Beth Dakin.
1730
1731         Bug 22606: Can <th> serves as the AXTitleUIElement for <td>?
1732
1733         Test: accessibility/th-as-title-ui.html
1734
1735         * page/AccessibilityObject.h:
1736         (WebCore::AccessibilityObject::isGroup):
1737         * page/AccessibilityRenderObject.cpp:
1738         (WebCore::AccessibilityRenderObject::isGroup):
1739         * page/AccessibilityRenderObject.h:
1740         * page/AccessibilityTableCell.cpp:
1741         (WebCore::AccessibilityTableCell::rowIndexRange):
1742         (WebCore::AccessibilityTableCell::columnIndexRange):
1743         (WebCore::AccessibilityTableCell::titleUIElement):
1744         * page/AccessibilityTableCell.h:
1745         * page/mac/AccessibilityObjectWrapper.mm:
1746         (-[AccessibilityObjectWrapper accessibilityAttributeNames]):
1747
1748 2008-12-02  Simon Fraser  <simon.fraser@apple.com>
1749
1750         Reviewed by Dave Hyatt
1751
1752         https://bugs.webkit.org/show_bug.cgi?id=22472
1753         
1754         Override absoluteClippedOverflowRect() in RenderReplaced to return a rect
1755         that is large enough to encompass the selection, so that the repainting of
1756         selected replaced elements works correctly.
1757         
1758         Test: fast/repaint/selected-replaced.html
1759
1760         * rendering/RenderReplaced.cpp:
1761         (WebCore::RenderReplaced::selectionRect):
1762         (WebCore::RenderReplaced::localSelectionRect):
1763         (WebCore::RenderReplaced::absoluteClippedOverflowRect):
1764         * rendering/RenderReplaced.h:
1765
1766 2008-12-02  Gregory Hughes  <ghughes@apple.com>
1767
1768         Reviewed by Beth Dakin.
1769
1770         Bug 22513: ZOOM: text selection does not send correct zoom bounds
1771
1772         When zoomed, text selection must send the zoom bounds in flipped
1773         screen coordinates.
1774
1775         * editing/mac/SelectionControllerMac.mm:
1776         (WebCore::SelectionController::notifyAccessibilityForSelectionChange):
1777         * page/mac/WebCoreViewFactory.h:
1778
1779 2008-12-02  Dean Jackson  <dino@apple.com>
1780
1781         Reviewed by Sam Weinig.
1782
1783         Remove support for 'now' from CSS (was
1784         erroneously added to transition and animation delay)
1785         https://bugs.webkit.org/show_bug.cgi?id=22571
1786
1787         * css/CSSParser.cpp:
1788         (WebCore::CSSParser::parseAnimationDelay):
1789         * css/CSSStyleSelector.cpp:
1790         (WebCore::CSSStyleSelector::mapAnimationDelay):
1791         * css/CSSValueKeywords.in:
1792
1793 2008-12-02  Eric Seidel  <eric@webkit.org>
1794
1795         Build fix, no review.
1796
1797         Fix the Mac and gtk builds:
1798         Don't use a float to hold a double.
1799         Remove a now duplicate symbol.
1800
1801         * page/Frame.cpp:
1802         (WebCore::Frame::selectionLayoutChanged):
1803         * platform/gtk/TemporaryLinkStubs.cpp:
1804
1805 2008-12-02  Chris Fleizach  <cfleizach@apple.com>
1806
1807         Bug 22596: Some elements don't report AXBlockQuoteLevel
1808         https://bugs.webkit.org/show_bug.cgi?id=22596
1809  
1810         Reviewed by John Sullivan.
1811
1812         * page/mac/AccessibilityObjectWrapper.mm:
1813         (blockquoteLevel):
1814         (AXAttributeStringSetBlockquoteLevel):
1815         (-[AccessibilityObjectWrapper accessibilityAttributeNames]):
1816         (-[AccessibilityObjectWrapper accessibilityAttributeValue:]):
1817
1818 2008-12-02  Dean McNamee  <deanm@chromium.org>
1819
1820         Reviewed by Eric Seidel.
1821
1822         Correctly handle a theme returning a non-blinking interval.  We should
1823         not set any timers when the interval is 0 (non-blinking), otherwise we
1824         repeatedly set and destroy a blinking timer, causing a paint and timer
1825         storm.  This is applicable to GTK and Windows, where a user can set a
1826         non-blinking caret in their system preferences.
1827
1828         Renamed caretBlinkFrequency to the more accurate caretBlinkInterval.
1829
1830         * page/Frame.cpp:
1831         (WebCore::Frame::selectionLayoutChanged):
1832         * platform/Theme.h:
1833         (WebCore::Theme::caretBlinkInterval):
1834         * platform/gtk/RenderThemeGtk.cpp:
1835         (WebCore::RenderThemeGtk::caretBlinkInterval):
1836         * platform/gtk/RenderThemeGtk.h:
1837         * rendering/RenderTheme.h:
1838         (WebCore::RenderTheme::caretBlinkInterval):
1839
1840 2008-12-02  David Levin  <levin@chromium.org>
1841
1842         Reviewed by Eric Seidel.
1843
1844         https://bugs.webkit.org/show_bug.cgi?id=22538
1845         
1846         startsWith uses find which searches through the whole string if no match is found.
1847         Using reverseFind with an index of 0 has the benefit of only searching for the match
1848         at the beginning of the string.  This may only be a small benefit in the overall program,
1849         but it may help in some cases when the string is big.
1850
1851         No observable change in behavior, so no test.
1852  
1853         * platform/text/StringImpl.h:
1854         (WebCore::StringImpl::startsWith):
1855
1856 2008-10-29  Eric Seidel  <eric@webkit.org>
1857
1858         Reviewed by Darin Adler.
1859
1860         Wrap a JSC-only hack in a USE(JSC) block to fix the v8 build.
1861         https://bugs.webkit.org/show_bug.cgi?id=21951
1862
1863         * svg/SVGElementInstance.cpp:
1864         (WebCore::SVGElementInstance::forgetWrapper):
1865
1866 2008-12-02  Eric Seidel  <eric@webkit.org>
1867
1868         Reviewed by Darin Adler.
1869
1870         Add an ASSERT to try and catch the root cause of:
1871         https://bugs.webkit.org/show_bug.cgi?id=22168
1872         http://code.google.com/p/chromium/issues/detail?id=4122
1873
1874         * editing/TextIterator.cpp:
1875         (WebCore::TextIterator::emitText):
1876
1877 2008-12-02  Brent Fulgham  <bfulgham@gmail.com>
1878
1879         Reviewed by Adam Roben.
1880
1881         Remove some CG-specific code from the Windows Cairo build.
1882         https://bugs.webkit.org/show_bug.cgi?id=22586
1883
1884         No new test cases since this update should create no user-visible
1885         changes, and should be fully covered by the existing regression
1886         tests.
1887
1888         * WebCore.vcproj/WebCore.vcproj: Remove FontDatabase from
1889         * platform/graphics/cairo/GraphicsContextCairo.cpp:
1890         (WebCore::focusRingColor): Add stub method
1891         * platform/win/TemporaryLinkStubs.cpp:
1892         (WebCore::populateFontDatabase): Add stub method.
1893
1894 2008-12-01 Laszlo Gombos <laszlo.1.gombos@nokia.com>
1895
1896         Reviewed by Tor Arne Vestbø.
1897
1898         MinGW compilation fix for PluginPackageWin.cpp
1899
1900         https://bugs.webkit.org/show_bug.cgi?id=22585
1901
1902         * plugins/win/PluginPackageWin.cpp:
1903         (WebCore::PluginPackage::fetchInfo):
1904
1905 2008-12-02  Adam Roben  <aroben@apple.com>
1906
1907         Build fix for Windows projects with NOMINMAX defined globally
1908
1909         * platform/win/COMPtr.h: Don't redefine NOMINMAX if it's already
1910         defined.
1911
1912 2008-12-02  Simon Hausmann  <hausmann@webkit.org>
1913
1914         Reviewed by Tor Arne Vestbø.
1915
1916         Build JavaScriptCore into libQtWebKit.so through a direct build
1917         instead of a static library. When linking a static library into
1918         a shared library qmake generates an incorrect .prl file, which
1919         causes all sorts of different build problems when linking against
1920         QtWebKit. Fixing this in qmake requires bigger changes that are
1921         currently not possible, so we need to work around this limitation
1922         for now. The advantages of the separate build did not outweight the
1923         build problems it caused.
1924
1925         * WebCore.pro: include JavaScriptCore.pri, re-enable prl support
1926         and rename the lut generator to domlut to avoid a conflict with
1927         JavaScriptCore.pri's lut generator.
1928
1929 2008-12-02  David Levin  <levin@chromium.org>
1930
1931         Reviewed by Alexey Proskuryakov.
1932
1933         https://bugs.webkit.org/show_bug.cgi?id=22588
1934         Move securityOrigin() from Document and WorkerContext into ScriptExecutionContext.
1935
1936         No observable change in behavior, so no test.
1937         
1938         * dom/Document.cpp:
1939         (WebCore::Document::open):
1940         (WebCore::Document::domain):
1941         (WebCore::Document::setDomain):
1942         (WebCore::Document::initSecurityContext):
1943         (WebCore::Document::setSecurityOrigin):
1944         * dom/Document.h:
1945         * dom/ScriptExecutionContext.cpp:
1946         (WebCore::ScriptExecutionContext::setSecurityOrigin):
1947         * dom/ScriptExecutionContext.h:
1948         (WebCore::ScriptExecutionContext::securityOrigin):
1949         * dom/WorkerContext.cpp:
1950         (WebCore::WorkerContext::WorkerContext):
1951         * dom/WorkerContext.h:
1952         These changes are for the move of securityOrigin().
1953         
1954         * xml/XMLHttpRequest.cpp:
1955         (WebCore::XMLHttpRequest::createRequest):
1956         (WebCore::XMLHttpRequest::makeSimpleCrossSiteAccessRequest):
1957         (WebCore::XMLHttpRequest::makeCrossSiteAccessRequestWithPreflight):
1958         (WebCore::XMLHttpRequest::handleAsynchronousPreflightResult):
1959         (WebCore::XMLHttpRequest::setRequestHeader):
1960         (WebCore::XMLHttpRequest::getAllResponseHeaders):
1961         (WebCore::XMLHttpRequest::getResponseHeader):
1962         (WebCore::XMLHttpRequest::processSyncLoadResults):
1963         (WebCore::XMLHttpRequest::willSendRequest):
1964         (WebCore::XMLHttpRequest::accessControlCheck):
1965         (WebCore::XMLHttpRequest::didReceiveResponsePreflight):
1966         Change XMLHttpRequest to use ScriptExecutionContext instead of Document to access securityOrigin().
1967
1968 2008-12-02  André Pönitz  <apoenitz@trolltech.com>
1969
1970         Reviewed by Simon Hausmann.
1971
1972         Disable the creation of debug information for the Qt build when done
1973         inside Qt. With 670 mb it was slowing down gdb start significantly
1974         for third-party applications that usually don't need it.
1975
1976         * WebCore.pro:
1977
1978 2008-12-01  Beth Dakin  <bdakin@apple.com>
1979
1980         Reviewed by Dan Bernstein.
1981
1982         Fix for https://bugs.webkit.org/show_bug.cgi?id=13736 REGRESSION 
1983         (r19811): Using the down arrow in a textarea gets "stuck" at the 
1984         end of a wrapped line
1985         And corresponding: <rdar://problem/5347931>
1986
1987         The basic problem here is that Position::getInlineBoxAndOffset() 
1988         failed to look beyond a single renderer. This patch looks for a 
1989         better match beyond the first renderer when the affinity is 
1990         downstream and we failed to find a "perfect" match. 
1991         * dom/Position.cpp:
1992         (WebCore::isNonTextLeafChild):
1993         (WebCore::searchAheadForBetterMatch):
1994         (WebCore::Position::getInlineBoxAndOffset):
1995
1996         This is a fix I made based on code inspection. It looks like the 
1997         old code here and skipped over the parent as a possible match. 
1998         * rendering/RenderObject.cpp:
1999         (WebCore::RenderObject::nextInPreOrderAfterChildren):
2000
2001 2008-12-01  Brent Fulgham  <bfulgham@gmail.com>
2002
2003         Reviewed by Adam Roben.
2004
2005         Add WML related files to Visual Studio projects.
2006         https://bugs.webkit.org/show_bug.cgi?id=22561
2007
2008         * WebCore.vcproj/WebCore.vcproj:
2009           1. Add files from the wml directory to the set of windows files.
2010           2. Extend include paths with new wml directory. 
2011           3. Add new autogenerated WML files to DerivedSources.
2012           4. Alphabetize preprocesor includes (holdover from earlier debugging).
2013
2014 2008-12-01  Steve Falkenburg  <sfalken@apple.com>
2015
2016         Revise node/selection image fix.
2017         Moved updateLayout call so selection rect is fetched after the layout.
2018         
2019         Reviewed by Adam Roben.
2020
2021         * page/win/FrameCGWin.cpp:
2022         (WebCore::imageFromRect):
2023         (WebCore::imageFromSelection):
2024         (WebCore::Frame::nodeImage):
2025
2026 2008-12-01  Steve Falkenburg  <sfalken@apple.com>
2027
2028         Support needed to implement renderedImage for Windows.
2029         https://bugs.webkit.org/show_bug.cgi?25648
2030
2031         Reviewed by Adam Roben.
2032
2033         * page/Frame.h:
2034         * page/win/FrameCGWin.cpp:
2035         (WebCore::imageFromRect):
2036         (WebCore::imageFromSelection):
2037         (WebCore::Frame::nodeImage):
2038         * page/win/FrameCairoWin.cpp:
2039         (WebCore::imageFromNode):
2040
2041 2008-12-01  Simon Fraser  <simon.fraser@apple.com>
2042
2043         Reviewed by Dan Bernstein
2044
2045         https://bugs.webkit.org/show_bug.cgi?id=22581
2046         
2047         Fix the painting of the caps lock indicator for transformed text inputs,
2048         by replacing a call to absoluteContentBox() with code that computes the
2049         painting rect for the input contents.
2050
2051         * rendering/RenderTextControl.cpp:
2052         (WebCore::RenderTextControl::paint):
2053
2054 2008-12-01  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
2055
2056         Reviewed by George Staikos.
2057
2058         Add two new helper functions to WMLElement, parseValueSubstitutingVariableReferences/parseValueForbiddingVariableReferences.
2059
2060         Convert all elements to parse their attribute values using these new helper functions. This simplifies the
2061         actual attribute parsing code in all WMLElement derived classes, as most WML attribute values either report
2062         an error if there's a variable reference used in the attribute value, or if it's invalid.
2063
2064         Split the WMLErrorInvalidVariableReference error which covered both 'invalid syntax' / 'wrong location'
2065         in two seperated error codes: WMLErrorInvalidVariableReference / WMLErrorInvalidVariableReferenceLocation.
2066
2067         * wml/WMLAccessElement.cpp:
2068         (WebCore::WMLAccessElement::parseMappedAttribute):
2069         * wml/WMLDoElement.cpp:
2070         (WebCore::WMLDoElement::defaultEventHandler):
2071         (WebCore::WMLDoElement::parseMappedAttribute):
2072         * wml/WMLElement.cpp:
2073         (WebCore::WMLElement::parseValueSubstitutingVariableReferences):
2074         (WebCore::WMLElement::parseValueForbiddingVariableReferences):
2075         * wml/WMLElement.h:
2076         * wml/WMLErrorHandling.cpp:
2077         (WebCore::reportWMLError):
2078         * wml/WMLErrorHandling.h:
2079         (WebCore::):
2080         * wml/WMLOnEventElement.cpp:
2081         (WebCore::WMLOnEventElement::parseMappedAttribute):
2082         * wml/WMLPrevElement.cpp:
2083         (WebCore::WMLPrevElement::executeTask):
2084         * wml/WMLSetvarElement.cpp:
2085         (WebCore::WMLSetvarElement::parseMappedAttribute):
2086         * wml/WMLTimerElement.cpp:
2087         (WebCore::WMLTimerElement::parseMappedAttribute):
2088
2089 2008-12-01  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
2090
2091         Reviewed by George Staikos.
2092
2093         Fix switching active cards within a document. No way to test, until <go> support is implemented.
2094
2095         * wml/WMLCardElement.cpp:
2096         (WebCore::WMLCardElement::showCard):
2097         (WebCore::WMLCardElement::hideCard):
2098         (WebCore::WMLCardElement::setActiveCardInDocument):
2099         * wml/WMLCardElement.h:
2100
2101 2008-12-01  David Kilzer  <ddkilzer@apple.com>
2102
2103         Fix logic error in LegacyWebArchive::create() from r38884.
2104
2105         * loader/archive/cf/LegacyWebArchive.cpp:
2106         (WebCore::LegacyWebArchive::create): Only continue if the
2107         subresource is actually added.
2108
2109 2008-12-01  David Kilzer  <ddkilzer@apple.com>
2110
2111         Bug 22466: REGRESSION (35867): Many resources missing when saving webarchive of webkit.org
2112
2113         <https://bugs.webkit.org/show_bug.cgi?id=22466>
2114         <rdar://problem/6403593>
2115
2116         Reviewed by Brady Eidson.
2117
2118         Test: http/tests/webarchive/test-preload-resources.html
2119
2120         * loader/archive/cf/LegacyWebArchive.cpp:
2121         (WebCore::LegacyWebArchive::create): Check the WebCore cache for
2122         resources if DocumentLoader::subresource() doesn't return them.
2123         Note that the DocumentLoader::subresource() method returned
2124         preloaded resources before r35867, but this caused a regression in
2125         Mail.
2126
2127 2008-12-01  Julien Chaffraix  <jchaffraix@webkit.org>
2128
2129         Reviewed by Eric Seidel.
2130
2131         Bug 22564: Make HTML elements' constructors take a QualifiedName
2132         https://bugs.webkit.org/show_bug.cgi?id=22564
2133
2134         - Modified the remaining HTML elements' constructors to take a QualifiedName.
2135
2136         - Added an assertion that the QualifiedName given corresponds to the element constructed.
2137
2138         * bindings/js/JSAudioConstructor.cpp:
2139         (WebCore::constructAudio):
2140         * html/HTMLAudioElement.cpp:
2141         (WebCore::HTMLAudioElement::HTMLAudioElement):
2142         * html/HTMLAudioElement.h:
2143         * html/HTMLBRElement.cpp:
2144         (WebCore::HTMLBRElement::HTMLBRElement):
2145         * html/HTMLBRElement.h:
2146         * html/HTMLElement.cpp:
2147         (WebCore::HTMLElement::setInnerText):
2148         * html/HTMLElementFactory.cpp:
2149         (WebCore::brConstructor):
2150         (WebCore::quoteConstructor):
2151         (WebCore::marqueeConstructor):
2152         (WebCore::audioConstructor):
2153         (WebCore::videoConstructor):
2154         (WebCore::sourceConstructor):
2155         * html/HTMLMarqueeElement.cpp:
2156         (WebCore::HTMLMarqueeElement::HTMLMarqueeElement):
2157         * html/HTMLMarqueeElement.h:
2158         * html/HTMLQuoteElement.cpp:
2159         (WebCore::HTMLQuoteElement::HTMLQuoteElement):
2160         * html/HTMLQuoteElement.h:
2161         * html/HTMLSourceElement.cpp:
2162         (WebCore::HTMLSourceElement::HTMLSourceElement):
2163         * html/HTMLSourceElement.h:
2164         * html/HTMLVideoElement.cpp:
2165         (WebCore::HTMLVideoElement::HTMLVideoElement):
2166         * html/HTMLVideoElement.h:
2167         * rendering/RenderTextControl.cpp:
2168         (WebCore::RenderTextControl::updateFromElement):
2169
2170 2008-12-01  Julien Chaffraix  <jchaffraix@webkit.org>
2171
2172         Reviewed by Antti Koivisto.
2173
2174         Bug 22441: Bridge the gap between the generated ElementFactory and HTMLElementFactory
2175         https://bugs.webkit.org/show_bug.cgi?id=22441
2176
2177         Add an assertion to the modified HTML elements' constructor
2178         to check that the QualifiedName parameter is the one that
2179         matches the Element's.
2180
2181         * html/HTMLBaseElement.cpp:
2182         (WebCore::HTMLBaseElement::HTMLBaseElement):
2183         * html/HTMLBlockquoteElement.cpp:
2184         (WebCore::HTMLBlockquoteElement::HTMLBlockquoteElement):
2185         * html/HTMLBodyElement.cpp:
2186         (WebCore::HTMLBodyElement::HTMLBodyElement):
2187         * html/HTMLButtonElement.cpp:
2188         (WebCore::HTMLButtonElement::HTMLButtonElement):
2189         * html/HTMLDListElement.cpp:
2190         (WebCore::HTMLDListElement::HTMLDListElement):
2191         * html/HTMLDirectoryElement.cpp:
2192         (WebCore::HTMLDirectoryElement::HTMLDirectoryElement):
2193         * html/HTMLDivElement.cpp:
2194         (WebCore::HTMLDivElement::HTMLDivElement):
2195         * html/HTMLFieldSetElement.cpp:
2196         (WebCore::HTMLFieldSetElement::HTMLFieldSetElement):
2197         * html/HTMLFormElement.cpp:
2198         (WebCore::HTMLFormElement::HTMLFormElement):
2199         * html/HTMLFrameElement.cpp:
2200         (WebCore::HTMLFrameElement::HTMLFrameElement):
2201         * html/HTMLFrameSetElement.cpp:
2202         (WebCore::HTMLFrameSetElement::HTMLFrameSetElement):
2203         * html/HTMLHeadElement.cpp:
2204         (WebCore::HTMLHeadElement::HTMLHeadElement):
2205         * html/HTMLHtmlElement.cpp:
2206         (WebCore::HTMLHtmlElement::HTMLHtmlElement):
2207         * html/HTMLIFrameElement.cpp:
2208         (WebCore::HTMLIFrameElement::HTMLIFrameElement):
2209         * html/HTMLInputElement.cpp:
2210         (WebCore::HTMLInputElement::HTMLInputElement):
2211         * html/HTMLIsIndexElement.cpp:
2212         (WebCore::HTMLIsIndexElement::HTMLIsIndexElement):
2213         * html/HTMLKeygenElement.cpp:
2214         (WebCore::HTMLKeygenElement::HTMLKeygenElement):
2215         * html/HTMLLIElement.cpp:
2216         (WebCore::HTMLLIElement::HTMLLIElement):
2217         * html/HTMLLabelElement.cpp:
2218         (WebCore::HTMLLabelElement::HTMLLabelElement):
2219         * html/HTMLLegendElement.cpp:
2220         (WebCore::HTMLLegendElement::HTMLLegendElement):
2221         * html/HTMLLinkElement.cpp:
2222         (WebCore::HTMLLinkElement::HTMLLinkElement):
2223         * html/HTMLMenuElement.cpp:
2224         (WebCore::HTMLMenuElement::HTMLMenuElement):
2225         * html/HTMLMetaElement.cpp:
2226         (WebCore::HTMLMetaElement::HTMLMetaElement):
2227         * html/HTMLOListElement.cpp:
2228         (WebCore::HTMLOListElement::HTMLOListElement):
2229         * html/HTMLOptGroupElement.cpp:
2230         (WebCore::HTMLOptGroupElement::HTMLOptGroupElement):
2231         * html/HTMLOptionElement.cpp:
2232         (WebCore::HTMLOptionElement::HTMLOptionElement):
2233         * html/HTMLSelectElement.cpp:
2234         (WebCore::HTMLSelectElement::HTMLSelectElement):
2235         * html/HTMLStyleElement.cpp:
2236         (WebCore::HTMLStyleElement::HTMLStyleElement):
2237         * html/HTMLTextAreaElement.cpp:
2238         (WebCore::HTMLTextAreaElement::HTMLTextAreaElement):
2239         * html/HTMLTitleElement.cpp:
2240         (WebCore::HTMLTitleElement::HTMLTitleElement):
2241         * html/HTMLUListElement.cpp:
2242         (WebCore::HTMLUListElement::HTMLUListElement):
2243
2244 2008-12-01  Chris Marrin  <cmarrin@apple.com>
2245
2246         Reviewed by Darin Adler.
2247
2248         https://bugs.webkit.org/show_bug.cgi?id=22046
2249
2250         Fixed another case of crashing because the animation object is getting deleted when
2251         it's in the middle of a callback. I actually moved where I am retaining the pointer
2252         up out of the lower level AnimationBase code and into the timer callback that calls
2253         them. So now the pointer is valid throughout the entire sequence of callback code.
2254
2255         The testcase for https://bugs.webkit.org/show_bug.cgi?id=22052 also exhibits a
2256         crash which this patch fixes. 
2257
2258         * page/animation/AnimationBase.cpp:
2259         (WebCore::AnimationBase::updateStateMachine):
2260         (WebCore::AnimationBase::animationTimerCallbackFired):
2261         * page/animation/CompositeAnimation.cpp:
2262         (WebCore::CompositeAnimationPrivate::setAnimationStartTime):
2263         (WebCore::CompositeAnimationPrivate::setTransitionStartTime):
2264         (WebCore::CompositeAnimationPrivate::styleAvailable):
2265         * page/animation/ImplicitAnimation.cpp:
2266         (WebCore::ImplicitAnimation::sendTransitionEvent):
2267         * page/animation/KeyframeAnimation.cpp:
2268         (WebCore::KeyframeAnimation::sendAnimationEvent):
2269         (WebCore::KeyframeAnimation::resumeOverriddenAnimations):
2270
2271 2008-12-01  Tor Arne Vestbø  <tavestbo@trolltech.com>
2272
2273         Reviewed by Simon Hausmann.
2274
2275         [Qt/Mac] Initialize NPAPI plugins before getting their entry points
2276
2277         The old behavior (calling NP_GetEntryPoints before NP_Initialize) was
2278         copied from Windows, but caused Silverlight on Mac to crash when loaded.
2279
2280         Apparently the call order of NP_Initialize and NP_GetEntryPoints is
2281         reversed on Mac. See https://bugzilla.mozilla.org/show_bug.cgi?id=344425
2282
2283         Reported-by: Peter Johnson <peter@zattoo.com>
2284
2285         * plugins/mac/PluginPackageMac.cpp:
2286         (WebCore::PluginPackage::load):
2287
2288 2008-11-30  Chris Fleizach  <cfleizach@apple.com>
2289
2290         Reviewed by John Sullivan.
2291
2292         https://bugs.webkit.org/show_bug.cgi?id=22510
2293         Crash at WebCore::AccessibilityRenderObject::activeDescendant() on Google Reader with ARIA (22510)
2294
2295         A nil pointer needed to be checked
2296
2297         * page/AccessibilityRenderObject.cpp:
2298         (WebCore::AccessibilityRenderObject::activeDescendant):
2299
2300 2008-11-30  Alexey Proskuryakov  <ap@webkit.org>
2301
2302         Reviewed by Dan Bernstein.
2303
2304         https://bugs.webkit.org/show_bug.cgi?id=22530
2305         Assertion failures seen on buildbot due to uninitialized WorkerThread::m_threadID
2306
2307         * dom/WorkerThread.cpp:
2308         (WebCore::WorkerThread::start): Protect worker startup with a mutex to ensure that this
2309         function runs to completion before the thread begins execution.
2310         (WebCore::WorkerThread::workerThread): Updated comments.
2311         (WebCore::WorkerThread::stop): Ditto.
2312         * dom/WorkerThread.h: Renamed m_workerContextMutex to m_threadCreationMutex, because it now
2313         protects startup as a whole.
2314
2315         * storage/DatabaseThread.cpp:
2316         * storage/DatabaseThread.h:
2317         * storage/LocalStorageThread.cpp:
2318         * storage/LocalStorageThread.h:
2319         Fixed the same m_threadID problem.
2320
2321 2008-11-29  Brent Fulgham  <bfulgham@gmail.com>
2322
2323         Reviewed by Alexey Proskuryakov.
2324
2325         Remove Visual Studio project dependencies on non-redistributable
2326         components in the Debug_Cairo and Release_Cairo build targets.
2327         See https://bugs.webkit.org/show_bug.cgi?id=22527
2328
2329         * WebCore.vcproj/WebCore.vcproj:
2330
2331 2008-11-29  Sam Weinig  <sam@webkit.org>
2332
2333         Rubber-stamped by Alexey Proskuryakov.
2334
2335         Fix some sorting
2336
2337         * WebCore.xcodeproj/project.pbxproj:
2338
2339 2008-11-28  Sam Weinig  <sam@webkit.org>
2340
2341         Reviewed by Alexey Proskuryakov.
2342
2343         Fix for https://bugs.webkit.org/show_bug.cgi?id=21063
2344         NULL pointer crash in dispatchEvent(null);
2345
2346         Test: fast/events/dispatchEvent-crash.html
2347
2348         * dom/MessagePort.cpp:
2349         (WebCore::MessagePort::dispatchEvent):
2350         * dom/Worker.cpp:
2351         (WebCore::Worker::dispatchEvent):
2352         * dom/WorkerContext.cpp:
2353         (WebCore::WorkerContext::dispatchEvent):
2354         * loader/appcache/DOMApplicationCache.cpp:
2355         (WebCore::DOMApplicationCache::dispatchEvent):
2356         * xml/XMLHttpRequest.cpp:
2357         (WebCore::XMLHttpRequest::dispatchEvent):
2358         * xml/XMLHttpRequestUpload.cpp:
2359         (WebCore::XMLHttpRequestUpload::dispatchEvent):
2360
2361 2008-11-29  Dan Bernstein  <mitz@apple.com>
2362
2363         Reviewed by Alexey Proskuryakov.
2364
2365         - fix https://bugs.webkit.org/show_bug.cgi?id=22454
2366           <rdar://problem/6405550> REGRESSION (3.2-TOT): Crash below FontFallbackList::fontDataAt on jacobian.org
2367
2368         Test: http/tests/misc/font-face-in-multiple-segmented-faces.html
2369
2370         The crash happened because style recalculation was invoked by
2371         CSSFontSelector after one CSSSegmentedFontFace had pruned its tables but
2372         before another CSSSegmentedFontFace using the same CSSFontFace had done
2373         so. The fix is to let all CSSSegmentedFontFaces using the CSSFontFace
2374         prune their tables before telling the CSSFontSelector to recalc style.
2375
2376         * css/CSSFontFace.cpp:
2377         (WebCore::CSSFontFace::fontLoaded):
2378         * css/CSSFontSelector.cpp:
2379         (WebCore::CSSFontSelector::fontLoaded):
2380         * css/CSSFontSelector.h:
2381         * css/CSSSegmentedFontFace.cpp:
2382         (WebCore::CSSSegmentedFontFace::fontLoaded):
2383
2384 2008-11-29  Alexey Proskuryakov  <ap@webkit.org>
2385
2386         Reviewed by Eric Seidel.
2387
2388         https://bugs.webkit.org/show_bug.cgi?id=14968
2389         document.open() erroneously returns void instead of the new Document
2390
2391         Test: fast/dom/HTMLDocument/document-open-return-value.html
2392
2393         * bindings/js/JSHTMLDocumentCustom.cpp: (WebCore::JSHTMLDocument::open):
2394         Return the document on which this method was invoked, per HTML5.
2395
2396 2008-11-28  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
2397
2398         Reviewed by Cameron Zwarich.
2399
2400         Fixes: https://bugs.webkit.org/show_bug.cgi?id=22550
2401
2402         Add <timer> element support. It provides a way to execute a task with a delay.
2403         The user is notified by firing the task associated with the <card>'s ontimer attribute.
2404         Only one timer element is allowed per <card> (fix wrong error message in reportWMLError)
2405
2406         * WebCore.xcodeproj/project.pbxproj:
2407         * wml/WMLCardElement.cpp:
2408         (WebCore::WMLCardElement::WMLCardElement):
2409         (WebCore::WMLCardElement::setIntrinsicEventTimer):
2410         (WebCore::WMLCardElement::handleIntrinsicEventIfNeeded):
2411         * wml/WMLCardElement.h:
2412         * wml/WMLDoElement.cpp:
2413         (WebCore::WMLDoElement::defaultEventHandler):
2414         * wml/WMLErrorHandling.cpp:
2415         (WebCore::reportWMLError):
2416         * wml/WMLPageState.h:
2417         (WebCore::WMLPageState::getVariable):
2418         * wml/WMLPrevElement.cpp:
2419         (WebCore::WMLPrevElement::executeTask):
2420         * wml/WMLRefreshElement.cpp:
2421         (WebCore::WMLRefreshElement::executeTask):
2422         * wml/WMLTagNames.in:
2423         * wml/WMLTimerElement.cpp: Added.
2424         (WebCore::WMLTimerElement::WMLTimerElement):
2425         (WebCore::WMLTimerElement::parseMappedAttribute):
2426         (WebCore::WMLTimerElement::insertedIntoDocument):
2427         (WebCore::WMLTimerElement::timerFired):
2428         (WebCore::WMLTimerElement::start):
2429         (WebCore::WMLTimerElement::stop):
2430         (WebCore::WMLTimerElement::storeIntervalToPageState):
2431         * wml/WMLTimerElement.h: Added.
2432
2433 2008-11-28  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
2434
2435         Reviewed by Holger Freyther.
2436
2437         Fixes: https://bugs.webkit.org/show_bug.cgi?id=22549
2438
2439         Add <do> element support. It provides a way to bind a task element to a <template>/<card> element. 
2440         Changes numerous of layout tests which contain <do> elements, as they render as buttons now.
2441
2442         * WebCore.xcodeproj/project.pbxproj:
2443         * rendering/RenderButton.cpp:
2444         (WebCore::RenderButton::updateFromElement):
2445         * wml/WMLCardElement.cpp:
2446         (WebCore::WMLCardElement::registerDoElement):
2447         * wml/WMLCardElement.h:
2448         * wml/WMLDoElement.cpp: Added.
2449         (WebCore::WMLDoElement::WMLDoElement):
2450         (WebCore::WMLDoElement::defaultEventHandler):
2451         (WebCore::WMLDoElement::parseMappedAttribute):
2452         (WebCore::WMLDoElement::insertedIntoDocument):
2453         (WebCore::WMLDoElement::createRenderer):
2454         (WebCore::WMLDoElement::recalcStyle):
2455         * wml/WMLDoElement.h: Added.
2456         (WebCore::WMLDoElement::registerTask):
2457         (WebCore::WMLDoElement::isActive):
2458         (WebCore::WMLDoElement::label):
2459         (WebCore::WMLDoElement::name):
2460         (WebCore::WMLDoElement::setActive):
2461         (WebCore::WMLDoElement::setNoop):
2462         * wml/WMLNoopElement.cpp:
2463         (WebCore::WMLNoopElement::insertedIntoDocument):
2464         * wml/WMLTagNames.in:
2465         * wml/WMLTaskElement.cpp:
2466         (WebCore::WMLTaskElement::insertedIntoDocument):
2467
2468 2008-11-28  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
2469
2470         Reviewed by Sam Weinig.
2471
2472         Fixes: https://bugs.webkit.org/show_bug.cgi?id=22545
2473
2474         Add onenterforward/onenterbackward/ontimer support for <card> elements.
2475
2476         No testing possible at the moment because WMLGoElement is not yet implemented.
2477         After that we can add tests covering the <card> event handling.
2478
2479         * wml/WMLCardElement.cpp:
2480         (WebCore::WMLCardElement::WMLCardElement):
2481         (WebCore::WMLCardElement::handleIntrinsicEventIfNeeded):
2482         (WebCore::WMLCardElement::parseMappedAttribute):
2483         (WebCore::WMLCardElement::setActiveCardInDocument):
2484         * wml/WMLCardElement.h:
2485         (WebCore::WMLCardElement::isNewContext):
2486         (WebCore::WMLCardElement::isOrdered):
2487         * wml/WMLDocument.cpp:
2488         (WebCore::WMLDocument::finishedParsing):
2489         * wml/WMLIntrinsicEvent.cpp:
2490         (WebCore::WMLIntrinsicEvent::WMLIntrinsicEvent):
2491         * wml/WMLIntrinsicEvent.h:
2492         (WebCore::WMLIntrinsicEvent::create):
2493
2494 2008-11-27  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
2495
2496         Reviewed by Tor Arne Vestbø.
2497
2498         Regression seen on QtWebKit - causes a build failure on Win using MinGW
2499
2500         https://bugs.webkit.org/show_bug.cgi?id=22536
2501
2502         * WebCore.pro:
2503
2504 2008-11-28  Simon Hausmann  <hausmann@webkit.org>
2505
2506         Reviewed by Tor Arne Vestbø.
2507
2508         Fix compilation and linking on Windows CE.
2509
2510         Use WIN_OS instead of WIN and therefore exclude determineModuleVersionFromDescription()
2511         from the Windows'ish build.
2512
2513         Link against the newly required mmtimer.
2514
2515         * WebCore.pro:
2516         * plugins/PluginPackage.cpp:
2517
2518 2008-11-28  David Levin  <levin@chromium.org>
2519
2520         Reviewed by Alexey Proskuryakov.
2521
2522         http://bugs.webkit.org/show_bug.cgi?id=22524
2523
2524         Made static initializations in XMLHttpRequest.cpp thread-safe in preparation for usage
2525         of XMLHttpRequest by Workers (on threads).
2526
2527         No observable change in behavior, so no test.
2528
2529         * xml/XMLHttpRequest.cpp:
2530         (WebCore::XMLHttpRequestStaticData::XMLHttpRequestStaticData):
2531         (WebCore::PreflightResultCacheItem::allowsCrossSiteMethod):
2532         (WebCore::PreflightResultCacheItem::allowsCrossSiteHeaders):
2533         (WebCore::PreflightResultCacheItem::allowsRequest):
2534         (WebCore::createXMLHttpRequestStaticData):
2535         (WebCore::initializeXMLHttpRequestStaticData):
2536         (WebCore::XMLHttpRequest::XMLHttpRequest):
2537         (WebCore::XMLHttpRequest::isSafeRequestHeader):
2538         (WebCore::XMLHttpRequest::isOnAccessControlResponseHeaderWhitelist):
2539         * xml/XMLHttpRequest.h:
2540
2541 2008-11-27  Cameron Zwarich  <zwarich@apple.com>
2542
2543         Not reviewed.
2544
2545         r38825, was committed without checking whether anything in WebCore
2546         uses JSFunction::m_body. Use the appropriate getters and setters
2547         instead.
2548
2549         * inspector/JavaScriptDebugServer.cpp:
2550         (WebCore::JavaScriptDebugServer::recompileAllJSFunctions):
2551
2552 2008-11-27  Alexey Proskuryakov  <ap@webkit.org>
2553
2554         Reviewed by Dan Bernstein.
2555
2556         https://bugs.webkit.org/show_bug.cgi?id=22529
2557         Crashes seen on buildbots due to trying to stop a worker thread twice
2558
2559         * dom/WorkerMessagingProxy.cpp: (WebCore::WorkerMessagingProxy::workerObjectDestroyed):
2560         Don't try to stop the thread if it's already stopping.
2561
2562 2008-11-27  Kent Hansen  <khansen@trolltech.com>
2563
2564         Reviewed by Simon Hausmann.
2565
2566         Make JavaScript bindings for Qt plugin widgets work again
2567         this was a regression; need to handle non-NPAPI plugins as in 4.4.
2568
2569         * bindings/js/ScriptControllerQt.cpp:
2570         (WebCore::ScriptController::createScriptInstanceForWidget):
2571
2572 2008-11-26  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
2573
2574         Reviewed by George Staikos.
2575
2576         Fixes: https://bugs.webkit.org/show_bug.cgi?id=22522
2577
2578         Catch WML errors (invalid variable name/reference, multiple access elements, etc)
2579         while parsing the document, and stop parsing immediately and wrap the document
2580         fragment in a XHTML error document, just like it's done from XML parsing errors.
2581
2582         Until now all card elements were hidden by default (no renderer created), and
2583         WMLDocument::finishedParsing() took care of showing the right card (either the first,
2584         or any named card in the document, specified by document URL reference). Change this
2585         behaviour to support displaying partially parsed WML document fragments: Mark the first
2586         WMLCardElement inserted into the document as visible. If the document parsing finishes
2587         without problems, WMLDocument::finishedParsing() will be called, which takes care of
2588         showing the desired card (common case: first card in the document, which is already
2589         visible, so nothing actually has to be done). If an error occours, the document is
2590         correctly rendered until the error happened - wrapped in a XHTML document.
2591
2592         Fixes: fast/wml/err-event-binding-conflict.wml
2593                fast/wml/err-invalid-variable-name.wml
2594                fast/wml/err-multi-access.wml
2595                fast/wml/err-unallowed-task-in-anchor.wml
2596
2597         * WebCore.xcodeproj/project.pbxproj:
2598         * wml/WMLAccessElement.cpp:
2599         (WebCore::WMLAccessElement::parseMappedAttribute):
2600         (WebCore::WMLAccessElement::insertedIntoDocument):
2601         * wml/WMLAccessElement.h:
2602         * wml/WMLCardElement.cpp:
2603         (WebCore::WMLCardElement::insertedIntoDocument):
2604         (WebCore::WMLCardElement::setActiveCardInDocument):
2605         * wml/WMLCardElement.h:
2606         * wml/WMLDocument.cpp:
2607         (WebCore::WMLDocument::finishedParsing):
2608         * wml/WMLErrorHandling.cpp: Added.
2609         (WebCore::reportWMLError):
2610         * wml/WMLErrorHandling.h: Added.
2611         (WebCore::):
2612         * wml/WMLIntrinsicEventHandler.cpp:
2613         (WebCore::WMLIntrinsicEventHandler::registerIntrinsicEvent):
2614         * wml/WMLIntrinsicEventHandler.h:
2615         * wml/WMLNoopElement.cpp:
2616         (WebCore::WMLNoopElement::insertedIntoDocument):
2617         * wml/WMLOnEventElement.cpp:
2618         (WebCore::WMLOnEventElement::parseMappedAttribute):
2619         (WebCore::WMLOnEventElement::registerTask):
2620         * wml/WMLPageState.cpp:
2621         (WebCore::WMLPageState::setNeedCheckDeckAccess):
2622         * wml/WMLPageState.h:
2623         * wml/WMLSetvarElement.cpp:
2624         (WebCore::WMLSetvarElement::parseMappedAttribute):
2625
2626 2008-11-26  Glenn Wilson  <gwilson@chromium.org>
2627
2628         Reviewed by Dan Bernstein.
2629
2630         Fixed bug http://bugs.webkit.org/show_bug.cgi?id=21953
2631
2632         This fixes the crash when the small-caps font variant is used
2633         on a lower-case glyph that does not have a corresponding
2634         upper-case glyph defined in the set of available fonts.
2635
2636         This changes Font.cpp to check if the font being used exists before trying to apply the small-caps variant.
2637         
2638         Test: fast/css/small-caps-crash.html
2639
2640         * platform/graphics/Font.cpp:
2641         (WebCore::Font::glyphDataForCharacter):
2642
2643 2008-11-26  Tony Chang  <tony@chromium.org>
2644
2645         Reviewed by Oliver Hunt.
2646
2647         Add a new platform specific method cleanupAfterSystemDrag
2648         that platforms can ue to clean up drag state after a
2649         system drag.  Use this method on PLAFORM(MAC).
2650         https://bugs.webkit.org/show_bug.cgi?id=21956
2651
2652         * ChangeLog:
2653         * page/DragController.cpp:
2654         (WebCore::DragController::doSystemDrag):
2655         * page/DragController.h:
2656         * page/gtk/DragControllerGtk.cpp:
2657         (WebCore::DragController::cleanupAfterSystemDrag):
2658         * page/mac/DragControllerMac.mm:
2659         (WebCore::DragController::cleanupAfterSystemDrag):
2660         * page/qt/DragControllerQt.cpp:
2661         (WebCore::DragController::cleanupAfterSystemDrag):
2662         * page/win/DragControllerWin.cpp:
2663         (WebCore::DragController::cleanupAfterSystemDrag):
2664         * page/wx/DragControllerWx.cpp:
2665       (WebCore::DragController::cleanupAfterSystemDrag):
2666
2667 2008-11-26  Nikolas Zimmermann  <zimmermann@kde.org>
2668
2669         Reviewed by Oliver Hunt.
2670
2671         Fix path to string logic, correctly taking closed (sub-)paths into account.
2672         Code was just broken on cg, observed by Dirk Schulze.
2673
2674         QPainterPath doesn't seem to expose any functionality to detect closed sub paths,
2675         using the elementAt() function. There might be a workaround - Dirk will investigate.
2676
2677         * platform/graphics/cg/PathCG.cpp:
2678         (WebCore::CGPathToCFStringApplierFunction):
2679         * platform/graphics/cairo/PathCairo.cpp:
2680         (WebCore::Path::debugString):
2681
2682 2008-11-26  Darin Fisher  <darin@chromium.org>
2683
2684         Reviewed by Eric Seidel.
2685
2686         https://bugs.webkit.org/show_bug.cgi?id=22519
2687         Remove unnecessary include.
2688
2689         * dom/XMLTokenizer.cpp:
2690
2691 2008-11-26  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
2692
2693         Reviewed by Oliver Hunt.
2694
2695         Add <noop> element support, completing the task element support.
2696
2697         * WebCore.xcodeproj/project.pbxproj:
2698         * wml/WMLNoopElement.cpp: Added.
2699         (WebCore::WMLNoopElement::WMLNoopElement):
2700         (WebCore::WMLNoopElement::insertedIntoDocument):
2701         * wml/WMLNoopElement.h: Added.
2702         * wml/WMLTagNames.in: Reorganize file a bit.
2703
2704 2008-11-26  Julien Chaffraix  <jchaffraix@webkit.org>
2705
2706         Reviewed by Eric Seidel.
2707
2708         Bug 22441: Bridge the gap between the generated ElementFactory and HTMLElementFactory
2709         https://bugs.webkit.org/show_bug.cgi?id=22441
2710
2711         Make more HTML elements' constructors take a QualifiedName.
2712
2713         * editing/DeleteButtonController.cpp:
2714         (WebCore::DeleteButtonController::createDeletionUI):
2715         * html/HTMLBlockquoteElement.cpp:
2716         (WebCore::HTMLBlockquoteElement::HTMLBlockquoteElement):
2717         * html/HTMLBlockquoteElement.h:
2718         * html/HTMLButtonElement.cpp:
2719         (WebCore::HTMLButtonElement::HTMLButtonElement):
2720         * html/HTMLButtonElement.h:
2721         * html/HTMLDListElement.cpp:
2722         (WebCore::HTMLDListElement::HTMLDListElement):
2723         * html/HTMLDListElement.h:
2724         * html/HTMLDirectoryElement.cpp:
2725         (WebCore::HTMLDirectoryElement::HTMLDirectoryElement):
2726         * html/HTMLDirectoryElement.h:
2727         * html/HTMLDivElement.cpp:
2728         (WebCore::HTMLDivElement::HTMLDivElement):
2729         * html/HTMLDivElement.h:
2730         * html/HTMLElementFactory.cpp:
2731         (WebCore::styleConstructor):
2732         (WebCore::titleConstructor):
2733         (WebCore::frameConstructor):
2734         (WebCore::framesetConstructor):
2735         (WebCore::iframeConstructor):
2736         (WebCore::formConstructor):
2737         (WebCore::buttonConstructor):
2738         (WebCore::inputConstructor):
2739         (WebCore::isindexConstructor):
2740         (WebCore::fieldsetConstructor):
2741         (WebCore::keygenConstructor):
2742         (WebCore::labelConstructor):
2743         (WebCore::legendConstructor):
2744         (WebCore::optgroupConstructor):
2745         (WebCore::optionConstructor):
2746         (WebCore::selectConstructor):
2747         (WebCore::textareaConstructor):
2748         (WebCore::dlConstructor):
2749         (WebCore::ulConstructor):
2750         (WebCore::olConstructor):
2751         (WebCore::dirConstructor):
2752         (WebCore::menuConstructor):
2753         (WebCore::liConstructor):
2754         (WebCore::blockquoteConstructor):
2755         (WebCore::divConstructor):
2756         (WebCore::headingConstructor):
2757         * html/HTMLFieldSetElement.cpp:
2758         (WebCore::HTMLFieldSetElement::HTMLFieldSetElement):
2759         * html/HTMLFieldSetElement.h:
2760         * html/HTMLFormElement.cpp:
2761         (WebCore::HTMLFormElement::HTMLFormElement):
2762         * html/HTMLFormElement.h:
2763         * html/HTMLFrameElement.cpp:
2764         (WebCore::HTMLFrameElement::HTMLFrameElement):
2765         * html/HTMLFrameElement.h:
2766         * html/HTMLFrameSetElement.cpp:
2767         (WebCore::HTMLFrameSetElement::HTMLFrameSetElement):
2768         * html/HTMLFrameSetElement.h:
2769         * html/HTMLIFrameElement.cpp:
2770         (WebCore::HTMLIFrameElement::HTMLIFrameElement):
2771         * html/HTMLIFrameElement.h:
2772         * html/HTMLInputElement.cpp:
2773         * html/HTMLInputElement.h:
2774         * html/HTMLIsIndexElement.cpp:
2775         (WebCore::HTMLIsIndexElement::HTMLIsIndexElement):
2776         * html/HTMLIsIndexElement.h:
2777         * html/HTMLKeygenElement.cpp:
2778         (WebCore::HTMLKeygenElement::HTMLKeygenElement):
2779         * html/HTMLKeygenElement.h:
2780         * html/HTMLLIElement.cpp:
2781         (WebCore::HTMLLIElement::HTMLLIElement):
2782         * html/HTMLLIElement.h:
2783         * html/HTMLLabelElement.cpp:
2784         (WebCore::HTMLLabelElement::HTMLLabelElement):
2785         * html/HTMLLabelElement.h:
2786         * html/HTMLLegendElement.cpp:
2787         (WebCore::HTMLLegendElement::HTMLLegendElement):
2788         * html/HTMLLegendElement.h:
2789         * html/HTMLMenuElement.cpp:
2790         (WebCore::HTMLMenuElement::HTMLMenuElement):
2791         * html/HTMLMenuElement.h:
2792         * html/HTMLOListElement.cpp:
2793         (WebCore::HTMLOListElement::HTMLOListElement):
2794         * html/HTMLOListElement.h:
2795         * html/HTMLOptGroupElement.cpp:
2796         (WebCore::HTMLOptGroupElement::HTMLOptGroupElement):
2797         * html/HTMLOptGroupElement.h:
2798         * html/HTMLOptionElement.cpp:
2799         (WebCore::HTMLOptionElement::HTMLOptionElement):
2800         * html/HTMLOptionElement.h:
2801         * html/HTMLParser.cpp:
2802         (WebCore::HTMLParser::formCreateErrorCheck):
2803         (WebCore::HTMLParser::handleIsindex):
2804         * html/HTMLSelectElement.cpp:
2805         * html/HTMLSelectElement.h:
2806         * html/HTMLStyleElement.cpp:
2807         (WebCore::HTMLStyleElement::HTMLStyleElement):
2808         * html/HTMLStyleElement.h:
2809         * html/HTMLTextAreaElement.cpp:
2810         (WebCore::HTMLTextAreaElement::HTMLTextAreaElement):
2811         * html/HTMLTextAreaElement.h:
2812         * html/HTMLTitleElement.cpp:
2813         (WebCore::HTMLTitleElement::HTMLTitleElement):
2814         * html/HTMLTitleElement.h:
2815         * html/HTMLUListElement.cpp:
2816         (WebCore::HTMLUListElement::HTMLUListElement):
2817         * html/HTMLUListElement.h:
2818         * html/HTMLViewSourceDocument.cpp:
2819         (WebCore::HTMLViewSourceDocument::createContainingTable):
2820         * rendering/MediaControlElements.cpp:
2821         (WebCore::MediaControlShadowRootElement::MediaControlShadowRootElement):
2822         (WebCore::MediaControlInputElement::MediaControlInputElement):
2823         * rendering/RenderFileUploadControl.cpp:
2824         (WebCore::HTMLFileUploadInnerButtonElement::HTMLFileUploadInnerButtonElement):
2825         * rendering/RenderMedia.cpp:
2826         (WebCore::RenderMedia::createPanel):
2827         (WebCore::RenderMedia::createTimeDisplay):
2828         * rendering/RenderSlider.cpp:
2829         (WebCore::HTMLSliderThumbElement::HTMLSliderThumbElement):
2830         * rendering/TextControlInnerElements.cpp:
2831         (WebCore::TextControlInnerElement::TextControlInnerElement):
2832
2833 2008-11-26  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
2834
2835         Reviewed by Sam Weinig.
2836
2837         Fix obvious problem in WMLPageState constructor, m_page was not set to the passed Page pointer.
2838
2839         * wml/WMLPageState.cpp:
2840         (WebCore::WMLPageState::WMLPageState):
2841
2842 2008-11-26  Matt Perry  <mpcomplete@gmail.com>
2843
2844         Fix Qt bustage.
2845
2846         See https://bugs.webkit.org/show_bug.cgi?id=22051
2847
2848         * platform/qt/RenderThemeQt.cpp:
2849         (WebCore::RenderThemeQt::extraDefaultStyleSheet):
2850
2851 2008-11-26  Matt Perry  <mpcomplete@gmail.com>
2852
2853         Reviewed by Maciej Stachowiak.
2854
2855         Fix https://bugs.webkit.org/show_bug.cgi?id=22051
2856         Renderthemes should be able to supply additional CSS rules to the core
2857         ones.
2858
2859         * DerivedSources.make:
2860         * css/CSSStyleSelector.cpp:
2861         (WebCore::parseUASheet):
2862         (WebCore::loadFullDefaultStyle):
2863         (WebCore::loadSimpleDefaultStyle):
2864         * css/themeWin.css: Added.
2865         * css/themeWinQuirks.css: Added.
2866         * platform/qt/RenderThemeQt.cpp:
2867         (WebCore::RenderThemeQt::extraDefaultStyleSheet):
2868         * platform/qt/RenderThemeQt.h:
2869         * rendering/RenderTheme.cpp:
2870         * rendering/RenderTheme.h:
2871         (WebCore::RenderTheme::extraDefaultStyleSheet):
2872         (WebCore::RenderTheme::extraQuirksStyleSheet):
2873         * rendering/RenderThemeWin.cpp:
2874         (WebCore::RenderThemeWin::extraDefaultStyleSheet):
2875         (WebCore::RenderThemeWin::extraQuirksStyleSheet):
2876         * rendering/RenderThemeWin.h:
2877
2878 2008-11-26  David Kilzer  <ddkilzer@apple.com>
2879
2880         Make CSSStyleSheet::addSubresourceURLStrings() iterative
2881
2882         Part of the fix for Bug 11850: Webarchive fails to save images referenced in CSS
2883         <https://bugs.webkit.org/show_bug.cgi?id=11850>
2884
2885         Reviewed by Brady Eidson.
2886
2887         * css/CSSStyleSheet.cpp:
2888         (WebCore::CSSStyleSheet::addSubresourceURLStrings): Switch algorithm
2889         from recursive to iterative for gathering the list of all CSS
2890         stylesheets referenced in @import statements.
2891
2892 2008-11-26  Dirk Schulze  <krit@webkit.org>
2893
2894         Reviewed by Simon Hausmann.
2895
2896         Transformations to the context shouldn't transform the currentPath.
2897         Fixed this on Qt.
2898
2899         [QT] GraphicsContext's currenPath can be transformed
2900         https://bugs.webkit.org/show_bug.cgi?id=22163
2901
2902         * platform/graphics/GraphicsContextPrivate.h:
2903         * platform/graphics/qt/GraphicsContextQt.cpp:
2904         (WebCore::GraphicsContext::restorePlatformState):
2905         (WebCore::GraphicsContext::fillPath):
2906         (WebCore::GraphicsContext::strokePath):
2907         (WebCore::GraphicsContext::fillRect):
2908         (WebCore::GraphicsContext::translate):
2909         (WebCore::GraphicsContext::rotate):
2910         (WebCore::GraphicsContext::scale):
2911         (WebCore::GraphicsContext::concatCTM):
2912
2913 2008-11-26  Jan Michael Alonzo  <jmalonzo@webkit.org>
2914
2915         Gtk build script minor fixes. Not reviewed.
2916
2917         * GNUmakefile.am:
2918           - Add ScriptInstance.h (introduced in r38774) to
2919         the build.
2920           - Move WML and GEOLOCATION conditionals before the SVG
2921         conditional to be consistent with the style of the script.
2922           - Move GeolocationGtk sources to webcoregtk_sources.
2923
2924 2008-11-26  Dmitry Titov  <dimich@chromium.org>
2925
2926         Reviewed by Darin Adler and Eric Seidel.
2927
2928         https://bugs.webkit.org/show_bug.cgi?id=22469
2929
2930         Move the class DOMWindowTimer from JSDOMWindowBase into its own file in
2931         preparation to making it work for Workers. For now, just move the code and couple
2932         of global variables.
2933
2934         * GNUmakefile.am:
2935         * WebCore.pro:
2936         * WebCore.vcproj/WebCore.vcproj:
2937         * WebCore.xcodeproj/project.pbxproj:
2938         * WebCoreSources.bkl:
2939         * bindings/js/JSDOMWindowBase.cpp:
2940         (WebCore::JSDOMWindowBase::installTimeout):
2941         (WebCore::JSDOMWindowBase::pauseTimeouts):
2942         (WebCore::JSDOMWindowBase::resumeTimeouts):
2943         (WebCore::JSDOMWindowBase::timerFired):
2944         * bindings/js/JSDOMWindowBase.h:
2945         * bindings/js/DOMTimer.cpp: Added.
2946         (WebCore::DOMTimer::DOMTimer):
2947         (WebCore::DOMTimer::~DOMTimer):
2948         (WebCore::DOMTimer::fired):
2949         * bindings/js/DOMTimer.h: Added.
2950         (WebCore::DOMTimer::timeoutId):
2951         (WebCore::DOMTimer::nestingLevel):
2952         (WebCore::DOMTimer::setNestingLevel):
2953         (WebCore::DOMTimer::action):
2954         (WebCore::DOMTimer::takeAction):
2955
2956 2008-11-25  Darin Fisher  <darin@chromium.org>
2957
2958         Fix bustage.
2959
2960         https://bugs.webkit.org/show_bug.cgi?id=22493
2961         Need to expose bridge/*.h to the WebKit build.
2962
2963         * WebCore.vcproj/WebCore.vcproj:
2964
2965 2008-11-25  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
2966
2967         Not reviewed. Fix build, by removing some wrong last-minute changes.
2968
2969         * wml/WMLIntrinsicEvent.cpp:
2970         (WebCore::createTaskElement):
2971         * wml/WMLOnEventElement.cpp:
2972         (WebCore::WMLOnEventElement::registerTask):
2973
2974 2008-11-25  Darin Fisher  <darin@chromium.org>
2975
2976         Reviewed by Geoffrey Garen.
2977
2978         https://bugs.webkit.org/show_bug.cgi?id=22493
2979         Abstract away JSC:: usage in WebCore/html
2980
2981         * WebCore.xcodeproj/project.pbxproj:
2982         * bindings/js/JSPluginElementFunctions.cpp:
2983         (WebCore::pluginInstance):
2984         * bindings/js/ScriptController.h:
2985         * bindings/js/ScriptControllerMac.mm:
2986         (WebCore::ScriptController::createScriptInstanceForWidget):
2987         * bindings/js/ScriptInstance.h: Added.
2988         * html/HTMLPlugInElement.cpp:
2989         (WebCore::HTMLPlugInElement::~HTMLPlugInElement):
2990         (WebCore::HTMLPlugInElement::getInstance):
2991         * html/HTMLPlugInElement.h:
2992
2993 2008-11-24  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
2994
2995         Reviewed by Sam Weinig.
2996
2997         Fixes: https://bugs.webkit.org/show_bug.cgi?id=22477
2998
2999         A WMLTaskElement checks wheter it's parent is an <anchor>/<do>/<onevent> element, and calls registerTask(this) on the parent.
3000         Add a isWMLTaskElement() function to WMLElement, making it possible to cast to WMLTaskElement directly.
3001
3002         Add WMLEventHandlingElement class, inheriting from WMLElement, to serve as common base WMLTemplate/Option/CardElement,
3003         centralizing the eventHandler() / createEventHandlerIfNeeded() implementation. Add a isWMLEventHandlingElement()
3004         function to WMLElement, so WMLOnEventElement can create event handlers, without knowing wheter it's a
3005         <template>/<option> or <card> element.
3006
3007         Add complete <onevent> support.
3008
3009         * WebCore.xcodeproj/project.pbxproj:
3010         * wml/WMLCardElement.cpp:
3011         (WebCore::WMLCardElement::WMLCardElement):
3012         (WebCore::WMLCardElement::setActiveCardInDocument):
3013         * wml/WMLCardElement.h:
3014         (WebCore::WMLCardElement::isVisible):
3015         (WebCore::WMLCardElement::setVisible):
3016         * wml/WMLElement.h:
3017         (WebCore::WMLElement::isWMLTaskElement):
3018         * wml/WMLEventHandlingElement.cpp: Added.
3019         (WebCore::WMLEventHandlingElement::WMLEventHandlingElement):
3020         (WebCore::WMLEventHandlingElement::createEventHandlerIfNeeded):
3021         * wml/WMLEventHandlingElement.h: Added.
3022         (WebCore::WMLEventHandlingElement::isWMLEventHandlingElement):
3023         (WebCore::WMLEventHandlingElement::eventHandler):
3024         * wml/WMLOnEventElement.cpp: Added.
3025         (WebCore::WMLOnEventElement::WMLOnEventElement):
3026         (WebCore::WMLOnEventElement::parseMappedAttribute):
3027         (WebCore::WMLOnEventElement::registerTask):
3028         * wml/WMLOnEventElement.h: Added.
3029         * wml/WMLSetvarElement.cpp:
3030         (WebCore::WMLSetvarElement::parseMappedAttribute):
3031         (WebCore::WMLSetvarElement::insertedIntoDocument):
3032         * wml/WMLTagNames.in:
3033         * wml/WMLTaskElement.cpp:
3034         (WebCore::WMLTaskElement::insertedIntoDocument):
3035         * wml/WMLTaskElement.h:
3036         (WebCore::WMLTaskElement::isWMLTaskElement):
3037
3038 2008-11-25  Pierre-Olivier Latour  <pol@apple.com>
3039
3040         Reviewed by Mark Rowe.
3041
3042         createFontCustomPlatformData() crashes if CGFontCreateWithPlatformFont() returns NULL
3043
3044         https://bugs.webkit.org/show_bug.cgi?id=22503
3045
3046         * platform/graphics/mac/FontCustomPlatformData.cpp:
3047         (WebCore::createFontCustomPlatformData):
3048
3049 2008-11-25  Julien Chaffraix  <jchaffraix@webkit.org>
3050
3051         Reviewed by Eric Seidel.
3052
3053         Bug 22441: Bridge the gap between the generated ElementFactory and HTMLElementFactory
3054         https://bugs.webkit.org/show_bug.cgi?id=22441
3055
3056         Element's other than HTML ones take a QualifiedName in their constructors.
3057         To make HTMLElementFactory closer to the other ElementFactory, we need
3058         to make them take the same arguments.
3059         This patch only makes the 5 first one in HTMLElementFactory abide by that. The others
3060         will go into the next patch.
3061
3062         * dom/Document.cpp:
3063         (WebCore::Document::implicitClose):
3064         * html/HTMLBaseElement.cpp:
3065         (WebCore::HTMLBaseElement::HTMLBaseElement):
3066         * html/HTMLBaseElement.h:
3067         * html/HTMLBodyElement.cpp:
3068         (WebCore::HTMLBodyElement::HTMLBodyElement):
3069         * html/HTMLBodyElement.h:
3070         * html/HTMLElementFactory.cpp:
3071         (WebCore::htmlConstructor):
3072         (WebCore::headConstructor):
3073         (WebCore::bodyConstructor):
3074         (WebCore::baseConstructor):
3075         (WebCore::linkConstructor):
3076         (WebCore::metaConstructor):
3077         * html/HTMLHeadElement.cpp:
3078         (WebCore::HTMLHeadElement::HTMLHeadElement):
3079         * html/HTMLHeadElement.h:
3080         * html/HTMLHtmlElement.cpp:
3081         (WebCore::HTMLHtmlElement::HTMLHtmlElement):
3082         * html/HTMLHtmlElement.h:
3083         * html/HTMLLinkElement.cpp:
3084         (WebCore::HTMLLinkElement::HTMLLinkElement):
3085         * html/HTMLLinkElement.h:
3086         * html/HTMLMetaElement.cpp:
3087         (WebCore::HTMLMetaElement::HTMLMetaElement):
3088         * html/HTMLMetaElement.h:
3089         * html/HTMLParser.cpp:
3090         (WebCore::HTMLParser::handleError):
3091         (WebCore::HTMLParser::headCreateErrorCheck):
3092         (WebCore::HTMLParser::createHead):
3093         (WebCore::HTMLParser::finished):
3094         * html/HTMLViewSourceDocument.cpp:
3095         (WebCore::HTMLViewSourceDocument::createContainingTable):
3096
3097 2008-11-25  Chris Marrin  <cmarrin@apple.com>
3098
3099         Reviewed by Dan Bernstein.
3100
3101         Fix for https://bugs.webkit.org/show_bug.cgi?id=22487
3102         I was not checking for the case of 0 length keyframe lists and dereffing a null pointer.
3103
3104         Tests: animations/empty-keyframes.html
3105                animations/fill-unset-properties.html
3106
3107         * css/CSSStyleSelector.cpp:
3108         (WebCore::CSSStyleSelector::keyframeStylesForAnimation):
3109
3110 2008-11-25  Chris Marrin  <cmarrin@apple.com>
3111
3112         Reviewed by Darin Adler
3113
3114         https://bugs.webkit.org/show_bug.cgi?id=22046
3115
3116         Fix a crash when an animation or transition end event handler
3117         removes the element upon which the transition/animation is running,
3118         by keeping a reference to the AnimationBase object on the stack.
3119
3120         Tests: animations/transform-animation-event-destroy-element.html
3121                transitions/transform-transition-event-destroy-element.html
3122
3123         * page/animation/AnimationBase.cpp:
3124         (WebCore::AnimationBase::setChanged):
3125         (WebCore::AnimationBase::updateStateMachine):
3126         * page/animation/AnimationBase.h:
3127         (WebCore::AnimationBase::clearRenderer):
3128         * page/animation/AnimationController.cpp:
3129         (WebCore::AnimationControllerPrivate::clear):
3130         * page/animation/CompositeAnimation.cpp:
3131         (WebCore::CompositeAnimationPrivate::~CompositeAnimationPrivate):
3132         * page/animation/CompositeAnimation.h:
3133
3134 2008-11-25  Kevin Ollivier  <kevino@theolliviers.com>
3135
3136         Better wx build fix - support PurgeableBuffer on Mac.
3137
3138         * platform/PurgeableBuffer.h:
3139         * webcore-wx.bkl:
3140
3141 2008-11-25  Holger Hans Peter Freyther  <zecke@selfish.org>
3142
3143         Reviewed by David Kilzer.
3144
3145         https://bugs.webkit.org/show_bug.cgi?id=22022
3146
3147         Add GeoleocationServiceGtk stubs and integrate it into the buildsystem
3148
3149         Add stubs for a Gtk Implementation.
3150
3151         * GNUmakefile.am:
3152         * platform/gtk/GeolocationServiceGtk.cpp: Added.
3153         (WebCore::GeolocationService::create):
3154         (WebCore::GeolocationServiceGtk::GeolocationServiceGtk):
3155         (WebCore::GeolocationServiceGtk::startUpdating):
3156         (WebCore::GeolocationServiceGtk::stopUpdating):
3157         (WebCore::GeolocationServiceGtk::suspend):
3158         (WebCore::GeolocationServiceGtk::resume):
3159         (WebCore::GeolocationServiceGtk::lastPosition):
3160         (WebCore::GeolocationServiceGtk::lastError):
3161         * platform/gtk/GeolocationServiceGtk.h: Added.
3162
3163 2008-11-25  Kevin Ollivier  <kevino@theolliviers.com>
3164
3165         wx build fix - we don't support PurgeableBuffer on Leopard for now.
3166         
3167         * platform/PurgeableBuffer.h:
3168
3169 2008-11-25  Antti Koivisto  <antti@apple.com>
3170
3171         Reviewed by Mark Rowe.
3172
3173         Fix https://bugs.webkit.org/show_bug.cgi?id=22483
3174         Assertion failure in CachedResource::makePurgeable during layout tests
3175         
3176         Deleting SVG image can re-enter destroyDecodedData.
3177
3178         * loader/CachedImage.cpp:
3179         (WebCore::CachedImage::destroyDecodedData):
3180
3181 2008-11-25  David Levin  <levin@chromium.org>
3182
3183         Reviewed by Alexey Proskuryakov.
3184
3185         https://bugs.webkit.org/show_bug.cgi?id=22443
3186         Made the PreflightResultCache thread-safe in preparation for usage of XMLHttpRequest by
3187         Workers on threads.
3188
3189         No observable change in behavior, so no test.
3190
3191         * platform/text/PlatformString.h:
3192         * platform/text/String.cpp:
3193         (WebCore::String::substringCopy):
3194         * platform/text/StringImpl.cpp:
3195         (WebCore::StringImpl::substringCopy):
3196         * platform/text/StringImpl.h:
3197         Added the ability to copy a substring.
3198
3199         * xml/XMLHttpRequest.cpp:
3200         (WebCore::PreflightResultCacheItem::PreflightResultCacheItem):
3201         (WebCore::PreflightResultCache::PreflightResultCache):
3202         (WebCore::PreflightResultCacheItem::addToAccessControlAllowList):
3203         (WebCore::PreflightResultCacheItem::parseAccessControlAllowList):
3204         (WebCore::PreflightResultCacheItem::parseAccessControlMaxAge):
3205         (WebCore::PreflightResultCacheItem::parse):
3206         (WebCore::PreflightResultCacheItem::allowsRequest):
3207         (WebCore::PreflightResultCache::shared):
3208         (WebCore::PreflightResultCache::appendEntry):
3209         (WebCore::PreflightResultCache::canSkipPreflight):
3210         (WebCore::XMLHttpRequest::makeCrossSiteAccessRequestWithPreflight):
3211         (WebCore::XMLHttpRequest::didReceiveResponsePreflight):
3212         Made the PreflightResultCache threadsafe.
3213
3214         (WebCore::PreflightResultCacheItem::allowsCrossSiteMethod):
3215         (WebCore::PreflightResultCacheItem::allowsCrossSiteHeaders):
3216         Consolidation of duplicate logic.
3217
3218 2008-11-24  Jungshik Shin  <jshin@chromium.org>
3219
3220         Reviewed by Darin Adler.
3221
3222         For Unicode encodings other than UTF-8, use UTF-8 for
3223         form submission and URL query part encoding.
3224
3225         See https://bugs.webkit.org/show_bug.cgi?id=21635
3226
3227         Tests: http/tests/misc/submit-get-in-utf16be.html
3228                http/tests/misc/submit-get-in-utf16le.html
3229                http/tests/misc/submit-get-in-utf32be.html
3230                http/tests/misc/submit-get-in-utf32le.html
3231                http/tests/misc/submit-get-in-utf7.html
3232                http/tests/misc/submit-post-in-utf16be.html
3233                http/tests/misc/submit-post-in-utf16le.html
3234                http/tests/misc/submit-post-in-utf32be.html
3235                http/tests/misc/submit-post-in-utf32le.html
3236                http/tests/misc/submit-post-in-utf7.html
3237                http/tests/misc/url-in-utf16be.html
3238                http/tests/misc/url-in-utf16le.html
3239                http/tests/misc/url-in-utf32be.html
3240                http/tests/misc/url-in-utf32le.html
3241                http/tests/misc/url-in-utf7.html
3242  
3243         * html/HTMLFormElement.cpp:
3244         (WebCore::HTMLFormElement::formData):
3245         * loader/TextResourceDecoder.cpp:
3246         (WebCore::TextResourceDecoder::setEncoding):
3247         * platform/KURL.cpp:
3248         (WebCore::KURL::KURL):
3249         * platform/text/TextEncoding.cpp:
3250         (WebCore::UTF7Encoding):
3251         (WebCore::TextEncoding::isNonByteBasedEncoding):
3252         (WebCore::TextEncoding::closestByteBasedEquivalent):
3253         (WebCore::TextEncoding::encodingForFormSubmission):
3254         * platform/text/TextEncoding.h:
3255
3256 2008-11-24  Julien Chaffraix  <jchaffraix@webkit.org>
3257
3258         Reviewed by Darin Adler.
3259
3260         Bug 22441: Bridge the gap between the generated ElementFactory and HTMLElementFactory
3261         https://bugs.webkit.org/show_bug.cgi?id=22441
3262
3263         - Make the generated ElementFactory constructors return PassRefPtr instead of raw pointers.
3264
3265         - Tweaked the generated files to better match our coding style.
3266
3267         * dom/make_names.pl:
3268
3269 2008-11-24  Antti Koivisto  <antti@apple.com>
3270
3271         Reviewed by Darin Adler.
3272         
3273         Fix for https://bugs.webkit.org/show_bug.cgi?id=22073
3274         REGRESSION(r33544): Palace in the Sky crashes WebKit
3275         
3276         HTMLTokenizer::m_hasScriptsWaitingForStylesheets would still be set while
3277         there were no scripts left to execute. 
3278         
3279         If m_hasScriptsWaitingForStylesheets becomes true during script execution
3280         bail out from executing more scripts synchronously.
3281
3282         Test: fast/tokenizer/nested-cached-scripts-and-stylesheet.html
3283
3284         * html/HTMLTokenizer.cpp:
3285         (WebCore::HTMLTokenizer::reset):
3286         (WebCore::HTMLTokenizer::notifyFinished):
3287
3288 2008-11-24  Darin Fisher  <darin@chromium.org>
3289
3290         Reviewed by Geoffrey Garen.
3291
3292         https://bugs.webkit.org/show_bug.cgi?id=22465
3293         Define KURL::copy() and use it in WorkerThread.cpp
3294
3295         * dom/WorkerThread.cpp:
3296         (WebCore::WorkerThread::WorkerThread):
3297         * platform/KURL.cpp:
3298         (WebCore::KURL::copy):
3299         * platform/KURL.h:
3300
3301 2008-11-24  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
3302
3303         Reviewed by Sam Weinig.
3304
3305         Name enum values in a style guide compatible way.
3306         Allow WMLIntrinsicEvent inclusion, without needing other includes.
3307
3308         * wml/WMLIntrinsicEvent.cpp:
3309         (WebCore::createTaskElement):
3310         * wml/WMLIntrinsicEvent.h:
3311         * wml/WMLIntrinsicEventHandler.cpp:
3312         * wml/WMLIntrinsicEventHandler.h:
3313         (WebCore::):
3314
3315 2008-11-24  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
3316
3317         Reviewed by Sam Weinig.
3318
3319         Add wmlPageStateForDocument() helper function and use it in some places.
3320
3321         * wml/WMLAccessElement.cpp:
3322         (WebCore::WMLAccessElement::parseMappedAttribute):
3323         * wml/WMLDocument.cpp:
3324         (WebCore::WMLDocument::WMLDocument):
3325         (WebCore::WMLDocument::finishedParsing):
3326         (WebCore::wmlPageStateForDocument):
3327         * wml/WMLDocument.h:
3328         * wml/WMLGoElement.cpp:
3329         (WebCore::WMLGoElement::executeTask):
3330         * wml/WMLPrevElement.cpp:
3331         (WebCore::WMLPrevElement::executeTask):
3332         * wml/WMLRefreshElement.cpp:
3333         (WebCore::WMLRefreshElement::executeTask):
3334         * wml/WMLTaskElement.cpp:
3335         (WebCore::WMLTaskElement::storeVariableState):
3336         * wml/WMLTaskElement.h:
3337
3338 2008-11-24  Antti Koivisto  <antti@apple.com>
3339
3340         Reviewed by Geoff Garen and Sam Weinig.
3341
3342         https://bugs.webkit.org/show_bug.cgi?id=22214
3343         Keep dead resources in memory cache in purgeable memory.
3344         <rdar://problem/6333088>
3345         
3346         OS X 10.5 has purgeable memory kernel facility that allows marking reserved memory
3347         areas as less important. Under memory pressure system can steal pages that have
3348         been marked purgeable for (hopefully) better uses. This is ideal for caches.
3349         
3350         Only resources larger than 16KB will be moved to the purgeable memory.
3351
3352         * WebCore.base.exp:
3353         * WebCore.vcproj/WebCore.vcproj:
3354         * WebCore.xcodeproj/project.pbxproj:
3355         * loader/Cache.cpp:
3356         (WebCore::Cache::requestResource):
3357         (WebCore::Cache::requestUserCSSStyleSheet):
3358         (WebCore::Cache::resourceForURL):
3359         (WebCore::Cache::pruneDeadResources):
3360         (WebCore::Cache::TypeStatistic::addResource):
3361         (WebCore::Cache::getStatistics):
3362         (WebCore::Cache::dumpStats):
3363         * loader/Cache.h:
3364         (WebCore::Cache::TypeStatistic::TypeStatistic):
3365         * loader/CachedCSSStyleSheet.cpp:
3366         (WebCore::CachedCSSStyleSheet::allClientsRemoved):
3367         (WebCore::CachedCSSStyleSheet::sheetText):
3368         * loader/CachedCSSStyleSheet.h:
3369         * loader/CachedImage.cpp:
3370         (WebCore::CachedImage::addClient):
3371         (WebCore::CachedImage::image):
3372         (WebCore::CachedImage::imageSize):
3373         (WebCore::CachedImage::imageRect):
3374         (WebCore::CachedImage::destroyDecodedData):
3375         * loader/CachedResource.cpp:
3376         (WebCore::CachedResource::addClient):
3377         (WebCore::CachedResource::makePurgeable):
3378         (WebCore::CachedResource::isPurgeable):
3379         (WebCore::CachedResource::wasPurged):
3380         * loader/CachedResource.h:
3381         (WebCore::CachedResource::data):
3382         * loader/CachedScript.cpp:
3383         (WebCore::CachedScript::allClientsRemoved):
3384         (WebCore::CachedScript::script):
3385         (WebCore::CachedScript::destroyDecodedData):
3386         * platform/PurgeableBuffer.h: Added.
3387         (WebCore::PurgeableBuffer::create):
3388         (WebCore::PurgeableBuffer::size):
3389         (WebCore::PurgeableBuffer::):
3390         (WebCore::PurgeableBuffer::purgePriority):
3391         (WebCore::PurgeableBuffer::isPurgeable):
3392         (WebCore::PurgeableBuffer::~PurgeableBuffer):
3393         (WebCore::PurgeableBuffer::data):
3394         (WebCore::PurgeableBuffer::setPurgePriority):
3395         (WebCore::PurgeableBuffer::wasPurged):
3396         (WebCore::PurgeableBuffer::makePurgeable):
3397         * platform/SharedBuffer.cpp:
3398         (WebCore::SharedBuffer::~SharedBuffer):
3399         (WebCore::SharedBuffer::adoptPurgeableBuffer):
3400         (WebCore::SharedBuffer::size):
3401         (WebCore::SharedBuffer::data):
3402         (WebCore::SharedBuffer::append):
3403         (WebCore::SharedBuffer::clear):
3404         (WebCore::SharedBuffer::releasePurgeableBuffer):
3405         * platform/SharedBuffer.h:
3406         (WebCore::SharedBuffer::hasPurgeableBuffer):
3407         * platform/cf/SharedBufferCF.cpp:
3408         * platform/mac/PurgeableBufferMac.cpp: Added.
3409         (WebCore::PurgeableBuffer::PurgeableBuffer):
3410         (WebCore::PurgeableBuffer::~PurgeableBuffer):
3411         (WebCore::PurgeableBuffer::create):
3412         (WebCore::PurgeableBuffer::makePurgeable):
3413         (WebCore::PurgeableBuffer::wasPurged):
3414         (WebCore::PurgeableBuffer::setPurgePriority):
3415         (WebCore::PurgeableBuffer::data):
3416
3417 2008-11-24  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
3418
3419         Reviewed by George Staikos & Eric Seidel.
3420
3421         Fixes: https://bugs.webkit.org/show_bug.cgi?id=22430
3422
3423         Regenerate WML layout test results after implementing WML specific <card> handling:
3424         Only the first <card> element should be visible after loading the document, others
3425         can be shown by using the <go> task element.
3426
3427         * dom/Document.h: Make 'finishedParsing()' a virtual function.
3428         * wml/WMLCardElement.cpp:
3429         (WebCore::WMLCardElement::WMLCardElement):
3430         (WebCore::WMLCardElement::~WMLCardElement):
3431         (WebCore::WMLCardElement::createRenderer):
3432         (WebCore::WMLCardElement::setActiveCardInDocument):
3433         (WebCore::WMLCardElement::setVisibility):
3434         * wml/WMLCardElement.h:
3435         * wml/WMLDocument.cpp:
3436         (WebCore::WMLDocument::finishedParsing): Execute WML specific logic after tokenzing.
3437         * wml/WMLDocument.h:
3438
3439 2008-11-24  Glenn Wilson  <gwilson@chromium.org>
3440
3441         Reviewed by Alexey Proskuryakov.
3442
3443         http://bugs.webkit.org/show_bug.cgi?id=15643
3444
3445         Added support for clients that wish to disable smart insert/delete
3446         and enable the "trailing whitespace selection" work-around.
3447
3448         Tests: editing/selection/doubleclick-whitespace.html
3449
3450         * editing/Editor.cpp:
3451         (WebCore::Editor::selectTrailingWhitespaceEnabled):
3452         * editing/Editor.h:
3453         * editing/Selection.cpp:
3454         (WebCore::Selection::includeTrailingWhitespace):
3455         * editing/Selection.h:
3456         * loader/EmptyClients.h:
3457         (WebCore::EmptyEditorClient::selectTrailingWhitespaceEnabled):
3458         * page/EditorClient.h:
3459         * page/EventHandler.cpp:
3460         (WebCore::EventHandler::selectClosestWordFromMouseEvent):
3461
3462 2008-11-24  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
3463
3464         Not reviewed. Forgot to include WMLPageState.h in last commit.
3465
3466         * wml/WMLPageState.h:
3467         (WebCore::WMLPageState::restrictDeckAccessToDomain):
3468         (WebCore::WMLPageState::restrictDeckAccessToPath):
3469
3470 2008-11-24  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
3471
3472         Reviewed by Oliver Hunt & Eric Seidel.
3473
3474         Fixes: https://bugs.webkit.org/show_bug.cgi?id=22431
3475
3476         Implement WMLAccessElement. It just propogates two attributes values to WMLPageState.
3477
3478         * WebCore.xcodeproj/project.pbxproj:
3479         * wml/WMLAccessElement.cpp: Added.
3480         (WebCore::WMLAccessElement::WMLAccessElement):
3481         (WebCore::WMLAccessElement::parseMappedAttribute):
3482         * wml/WMLAccessElement.h: Added.
3483         * wml/WMLTagNames.in:
3484         * wml/WMLPageState.h: Rename functions.
3485         (WebCore::WMLPageState::restrictDeckAccessToDomain):
3486         (WebCore::WMLPageState::restrictDeckAccessToPath):
3487         * wml/WMLVariables.cpp: Add new helper function.
3488         (WebCore::valueContainsVariableReference):
3489         * wml/WMLVariables.h:
3490         (WebCore::):
3491
3492 2008-11-24  Darin Adler  <darin@apple.com>
3493
3494         Reviewed by Dan Bernstein.
3495
3496         - https://bugs.webkit.org/show_bug.cgi?id=22470
3497           remove unneeded URL argument from FrameLoaderClient::updateGlobalHistory
3498
3499         * loader/EmptyClients.h:
3500         (WebCore::EmptyFrameLoaderClient::updateGlobalHistory): Remove argument.
3501         * loader/FrameLoader.cpp:
3502         (WebCore::FrameLoader::updateHistoryForStandardLoad): Don't pass the URL.
3503         (WebCore::FrameLoader::updateHistoryForRedirectWithLockedHistory): Ditto.
3504         * loader/FrameLoaderClient.h: Remove argument.
3505
3506 2008-11-24  Finnur Thorarinsson  <finnur.webkit@gmail.com>
3507
3508         Reviewed by Darin Adler.
3509
3510         Fixes: https://bugs.webkit.org/show_bug.cgi?id=22432
3511
3512         Add plumbing for tickmark support for the scrollbars. The painting code
3513         for the scrollbar just needed to call paintTickmarks at the right time
3514         and a default no-op implementation is provided, which the ports will
3515         need to override.
3516
3517         * platform/ScrollbarThemeComposite.cpp:
3518         (WebCore::ScrollbarThemeComposite::paint):
3519         * platform/ScrollbarThemeComposite.h:
3520         (WebCore::ScrollbarThemeComposite::paintTickmarks):
3521
3522 2008-11-24  Darin Fisher  <darin@chromium.org>
3523
3524         Reviewed by Sam Weinig.
3525
3526         https://bugs.webkit.org/show_bug.cgi?id=22448
3527         Create an abstraction for JSC::SourceCode
3528
3529         * WebCore.vcproj/WebCore.vcproj:
3530         * bindings/js/CachedScriptSourceProvider.h:
3531         * bindings/js/ScriptController.cpp:
3532         (WebCore::ScriptController::evaluate):
3533         * bindings/js/ScriptController.h:
3534         * bindings/js/ScriptSourceCode.h: Added.
3535         (WebCore::ScriptSourceCode::ScriptSourceCode):
3536         (WebCore::ScriptSourceCode::length):
3537         (WebCore::ScriptSourceCode::jsSourceCode):
3538         * bindings/js/WorkerScriptController.cpp:
3539         (WebCore::Workevn ScriptController::evaluate):
3540         * bindings/js/WorkerScriptController.h:
3541         * dom/ScriptElement.cpp:
3542         (WebCore::ScriptElement::insertedIntoDocument):
3543         (WebCore::ScriptElement::childrenChanged):
3544         (WebCore::ScriptElementData::evaluateScript):
3545         (WebCore::ScriptElementData::notifyFinished):
3546         * dom/ScriptElement.h:
3547         * dom/WorkerThread.cpp:
3548         (WebCore::WorkerThread::workerThread):
3549         * dom/WorkerThread.h:
3550         * dom/XMLTokenizer.cpp:
3551         (WebCore::XMLTokenizer::notifyFinished):
3552         * dom/XMLTokenizerLibxml2.cpp:
3553         (WebCore::XMLTokenizer::endElementNs):
3554         * dom/XMLTokenizerQt.cpp:
3555         (WebCore::XMLTokenizer::parseEndElement):
3556         * html/HTMLTokenizer.cpp:
3557         (WebCore::HTMLTokenizer::scriptHandler):
3558         (WebCore::HTMLTokenizer::scriptExecution):
3559         (WebCore::HTMLTokenizer::notifyFinished):
3560         * html/HTMLTokenizer.h:
3561         * loader/FrameLoader.cpp:
3562         (WebCore::FrameLoader::executeScript):
3563         * loader/FrameLoader.h:
3564
3565 2008-11-24  Darin Adler  <darin@apple.com>
3566
3567         Reviewed by Dan Bernstein.
3568
3569         - finish https://bugs.webkit.org/show_bug.cgi?id=22295
3570           track which history items are from page load failures
3571
3572         * WebCore.base.exp: Exported new function.
3573
3574         * loader/DocumentLoader.cpp:
3575         (WebCore::DocumentLoader::urlForHistoryReflectsFailure): Added.
3576         * loader/DocumentLoader.h: Ditto.
3577
3578 2008-11-24  Chris Fleizach  <cfleizach@apple.com>
3579
3580         Reviewed by Beth Dakin.
3581
3582         Bug 22461: AccessibilityListBox::doAccessibilityHitTest() signature does not match the base class
3583         https://bugs.webkit.org/show_bug.cgi?id=22461
3584  
3585         Changing AccessibilityListBox to use its parent's signature for hit testing
3586
3587         * page/AccessibilityListBox.cpp:
3588         (WebCore::AccessibilityListBox::doAccessibilityHitTest):
3589         * page/AccessibilityListBox.h:
3590
3591 2008-11-24  Simon Fraser  <simon.fraser@apple.com>
3592
3593         Fix Windows build: selectionRect() -> selectionBounds().
3594
3595         * page/win/FrameCGWin.cpp:
3596         (WebCore::imageFromSelection):
3597
3598 2008-11-24  Glenn Wilson  <gwilson@chromium.org>
3599
3600         Reviewed by Darin Adler.
3601
3602         http://bugs.webkit.org/show_bug.cgi?id=18703
3603         "Changing the 'size' property on a text input does not affect its length"
3604
3605         Text fields would not repaint themselves after having their "size" 
3606         attributes modified.  This fix tells the object to recalculate its 
3607         width and repaint itself when its "size" attribute is parsed.
3608
3609         Test: fast/js/text-field-resize.html
3610
3611         * html/HTMLInputElement.cpp:
3612         (WebCore::HTMLInputElement::parseMappedAttribute):
3613
3614 2008-11-24  Simon Fraser  <simon.fraser@apple.com>
3615
3616         Reviewed by Darin Adler
3617