ee7079c9bf399a382f5375d357074f47671bae88
[WebKit-https.git] / WebCore / ChangeLog
1 2007-06-08  Justin Garcia  <justin.garcia@apple.com>
2
3         Reviewed by John.
4         
5         <rdar://problem/5232159> REGRESSION: Cannot select text in RSS view
6
7         The selection is updated both on mouse movement and
8         when the autoscroll timer fires.  The autoscroll
9         code wasn't converting mouse coordinates to layer
10         coordinates correctly, and was then using those
11         coordinates to create a bad selection.
12
13         * rendering/RenderLayer.cpp:
14         (WebCore::RenderLayer::autoscroll): Use convertToLayerCoordinates.
15
16 2007-06-08  Anders Carlsson  <andersca@apple.com>
17
18         Reviewed by Geoff.
19
20         Store the root object in a hash set, keyed by the plugin view. This is in preparation for 
21         letting plugins invalidate the root object upon destruction
22
23         * page/Frame.cpp:
24         (WebCore::Frame::createRootObject):
25         (WebCore::Frame::cleanupScriptObjects):
26         * page/FramePrivate.h:
27
28 2007-06-08  Lars Knoll <lars@trolltech.com>
29
30         Reviewed by Zack.
31
32         Add qwebobjectpluginconnector to the build.
33
34         * WebCore.pro:
35
36 2007-06-07  Justin Garcia  <justin.garcia@apple.com>
37
38         Reviewed by Tristan.
39         
40         <rdar://problem/5250997> A crash occurs when selecting Undo Typing for a page that has been closed in tab
41
42         * WebCore.exp: Added clearUndoRedoOperations.
43         * page/Page.cpp:
44         (WebCore::Page::clearUndoRedoOperations): Added.
45         * page/Page.h:
46         
47 2007-06-07  David Hyatt  <hyatt@apple.com>
48
49         Fix crash.  Null check layer.  Bug 13984.
50
51         Reviewed by andersca
52
53         * WebCore.xcodeproj/project.pbxproj:
54         * page/FrameView.cpp:
55         (WebCore::FrameView::windowClipRectForLayer):
56
57 2007-06-07  Oliver Hunt  <oliver@apple.com>
58
59         Reviewed by Justin.
60
61         Remove incorrect assertions.
62         
63         These assertions were made on the assumption that 
64         TSM would always call with a range that was contained 
65         by an editable region.
66         
67         TSM may call -[WebHTMLView characterIndexForPoint:] on a mouse
68         event that is otherwise unrelated to editing, which may
69         be outside the current editing region, triggering these 
70         assertions.
71
72         * page/mac/WebCoreFrameBridge.mm:
73         (-[WebCoreFrameBridge convertToNSRange:]):
74
75 2007-06-07  Justin Garcia  <justin.garcia@apple.com>
76
77         Reviewed by John.
78         
79         <rdar://problem/5237074> REGRESSION: editing/unsupported-content/table-delete-003 is failing (13931)
80         
81         * editing/DeleteSelectionCommand.cpp:
82         (WebCore::DeleteSelectionCommand::initializeStartEnd):
83         We wouldn't expand the selection to include a special element 
84         at the start of the selection unless the end of the selection 
85         was at the end of a special element. Avoid a special 
86         element at the start as long as it's fully selected. Ditto for 
87         the end.
88         * editing/htmlediting.cpp:
89         (WebCore::positionBeforeContainingSpecialElement):
90         (WebCore::positionAfterContainingSpecialElement):
91
92 2007-06-07  Sam Weinig  <sam@webkit.org>
93
94         Reviewed by Anders.
95
96         Patch for  http://bugs.webkit.org/show_bug.cgi?id=14028
97         Finish autogenerating the JS bindings for Node
98
99         * DerivedSources.make:
100         * WebCore.pro:
101         * WebCore.xcodeproj/project.pbxproj:
102         * bindings/js/JSHTMLElementWrapperFactory.cpp:
103         (WebCore::createJSHTMLWrapper):
104         * bindings/js/JSHTMLElementWrapperFactory.h:
105         * bindings/js/JSHTMLOptionElementConstructor.cpp:
106         * bindings/js/JSNamedNodeMapCustom.cpp:
107         * bindings/js/JSNodeCustom.cpp:
108         (WebCore::JSNode::insertBefore):
109         (WebCore::JSNode::replaceChild):
110         (WebCore::JSNode::removeChild):
111         (WebCore::JSNode::appendChild):
112         (WebCore::JSNode::mark):
113         (WebCore::toJS):
114         * bindings/js/JSSVGElementWrapperFactory.cpp:
115         (WebCore::createJSSVGWrapper):
116         * bindings/js/JSSVGElementWrapperFactory.h:
117         * bindings/js/JSXSLTProcessor.cpp:
118         (KJS::XSLTProcessorPrototypeFunction::callAsFunction):
119         * bindings/js/kjs_binding.cpp:
120         (KJS::ScriptInterpreter::getDOMNodeForDocument):
121         (KJS::ScriptInterpreter::putDOMNodeForDocument):
122         (KJS::ScriptInterpreter::markDOMNodesForDocument):
123         (KJS::ScriptInterpreter::updateDOMNodeDocument):
124         * bindings/js/kjs_binding.h:
125         * bindings/js/kjs_dom.cpp:
126         (WebCore::toAttr):
127         * bindings/js/kjs_dom.h:
128         * bindings/js/kjs_domnode.h: Removed.
129         * bindings/objc/DOMUtility.mm:
130         (KJS::createDOMWrapper):
131         * bindings/scripts/CodeGeneratorJS.pm:
132         * dom/Node.h:
133         (WebCore::Node::parentElement):
134         * dom/Node.idl:
135
136 2007-06-07  Sam Weinig  <sam@webkit.org>
137
138         Another Gdk and Qt build fix.
139
140         * WebCore.pro:
141
142 2007-06-07  Sam Weinig  <sam@webkit.org>
143
144         Gdk and Qt build fix.
145
146         * WebCore.pro:
147
148 2007-06-06  Sam Weinig  <sam@webkit.org>
149
150         Reviewed by Hyatt.
151
152         Patch for http://bugs.webkit.org/show_bug.cgi?id=13973
153         Autogenerate most of the rest of kjs_dom.h/cpp
154
155         - Autogenerate JSNodeList and JSNamedNodeMap.
156         - Move JSEventTargetNode, JSNamedNodesCollection, and JSDOMExceptionConstructor 
157           into their own files.
158         - Rename KJS::DOMEventTargeNode to WebCore::JSEventTargetNode to adhere
159           to convention and allow easier code generation.
160         - Add JS constructors for JSNodeList and JSNamedNodeMap.
161         - Moved more toJS methods into the correct (corresponding) header files.
162         - Cleaned up code in order for changes to work.
163
164         * DerivedSources.make:
165         * WebCore.xcodeproj/project.pbxproj:
166         * bindings/js/JSDOMExceptionConstructor.cpp: Added.
167         (WebCore::):
168         (WebCore::JSDOMExceptionConstructor::JSDOMExceptionConstructor):
169         (WebCore::JSDOMExceptionConstructor::getOwnPropertySlot):
170         (WebCore::JSDOMExceptionConstructor::getValueProperty):
171         (WebCore::getDOMExceptionConstructor):
172         * bindings/js/JSDOMExceptionConstructor.h: Added.
173         (WebCore::JSDOMExceptionConstructor::classInfo):
174         * bindings/js/JSDOMWindowCustom.cpp: Added.
175         (WebCore::JSDOMWindow::customGetOwnPropertySlot):
176         * bindings/js/JSDocumentCustom.cpp:
177         (WebCore::JSDocument::mark):
178         (WebCore::toJS):
179         * bindings/js/JSEventTargetNode.cpp: Added.
180         (WebCore::JSEventTargetNode::JSEventTargetNode):
181         (WebCore::JSEventTargetNode::getOwnPropertySlot):
182         (WebCore::JSEventTargetNode::getValueProperty):
183         (WebCore::JSEventTargetNode::put):
184         (WebCore::JSEventTargetNode::putValueProperty):
185         (WebCore::JSEventTargetNode::setListener):
186         (WebCore::JSEventTargetNode::getListener):
187         (WebCore::JSEventTargetNode::pushEventHandlerScope):
188         (WebCore::JSEventTargetNodePrototypeFunction::callAsFunction):
189         (WebCore::toEventTargetNode):
190         * bindings/js/JSEventTargetNode.h: Added.
191         (WebCore::JSEventTargetNode::):
192         * bindings/js/JSHTMLElementCustom.cpp:
193         * bindings/js/JSHTMLFormElementCustom.cpp:
194         (WebCore::JSHTMLFormElement::nameGetter):
195         * bindings/js/JSHTMLOptionElementConstructor.cpp:
196         * bindings/js/JSNamedNodeMapCustom.cpp: Added.
197         (WebCore::JSNamedNodeMap::canGetItemsForName):
198         (WebCore::JSNamedNodeMap::nameGetter):
199         * bindings/js/JSNamedNodesCollection.cpp: Added.
200         (WebCore::):
201         (WebCore::JSNamedNodesCollection::JSNamedNodesCollection):
202         (WebCore::JSNamedNodesCollection::lengthGetter):
203         (WebCore::JSNamedNodesCollection::indexGetter):
204         (WebCore::JSNamedNodesCollection::getOwnPropertySlot):
205         * bindings/js/JSNamedNodesCollection.h: Added.
206         (WebCore::JSNamedNodesCollection::classInfo):
207         * bindings/js/JSNodeCustom.cpp: Added.
208         (WebCore::toJS):
209         * bindings/js/JSNodeListCustom.cpp: Added.
210         (WebCore::JSNodeList::callAsFunction):
211         (WebCore::JSNodeList::implementsCall):
212         (WebCore::JSNodeList::canGetItemsForName):
213         (WebCore::JSNodeList::nameGetter):
214         * bindings/js/kjs_dom.cpp:
215         * bindings/js/kjs_dom.h:
216         * bindings/js/kjs_domnode.h:
217         * bindings/js/kjs_events.cpp:
218         (KJS::JSLazyEventListener::parseCode):
219         * bindings/js/kjs_html.cpp:
220         (KJS::JSHTMLCollection::getNamedItems):
221         * bindings/js/kjs_html.h:
222         * bindings/js/kjs_window.cpp:
223         (WebCore::toJS):
224         * bindings/js/kjs_window.h:
225         * bindings/objc/DOMInternal.mm:
226         (-[WebScriptObject _initializeScriptDOMNodeImp]):
227         * bindings/objc/DOMUtility.mm:
228         (KJS::createDOMWrapper):
229         * bindings/scripts/CodeGeneratorJS.pm:
230         * bridge/mac/WebCoreAXObject.mm:
231         * dom/Attr.idl:
232         * dom/CharacterData.idl:
233         * dom/Document.idl:
234         * dom/DocumentFragment.idl:
235         * dom/DocumentType.idl:
236         * dom/Element.idl:
237         * dom/NamedNodeMap.idl:
238         * dom/Node.idl:
239         * dom/NodeList.idl:
240         * page/DOMWindow.idl:
241
242 2007-06-06  Justin Garcia  <justin.garcia@apple.com>
243
244         Reviewed by Oliver.
245         
246         <rdar://problem/5245519> CrashTracer: [USER] 457 crashes in Mail at WebCore::CSSComputedStyleDeclaration::copyInheritableProperties()
247         
248         If the user pastes something into a region that ends up being
249         invisible, or if the pasted content contains style spans 
250         that are render-less, we'll crash when we try to remove
251         redundant styles from style spans.
252
253         * css/CSSComputedStyleDeclaration.cpp:
254         (WebCore::CSSComputedStyleDeclaration::copyInheritableProperties):
255         Add null checks.
256
257 2007-06-06  Justin Garcia  <justin.garcia@apple.com>
258
259         Reviewed by Harrison.
260
261         <rdar://problem/4889598> Problems with moveDown: and moveUp: in Notes with ToDos
262         
263         The caret would disappear when moving from content above or below
264         a ToDo if that ToDo doesn't have any content in it with the same
265         x position as the caret. That's because closestLeafChildForXPos
266         would return non-editable leaves, and which turn into non-editable
267         VisiblePositions, which are invisible.
268
269         * editing/visible_units.cpp:
270         (WebCore::previousLinePosition): Ask closestLeafForXPos to only
271         return editable leaves.
272         (WebCore::nextLinePosition): Ditto.
273         * rendering/RootInlineBox.cpp:
274         (WebCore::isEditableLeaf): Added.
275         (WebCore::RootInlineBox::closestLeafChildForXPos): If requested,
276         return the closest editable leaf. Removed an early return if the
277         position is before the first leaf, it's not really much of an
278         optimization.
279         * rendering/RootInlineBox.h:
280
281 2007-06-06  Sam Weinig  <sam@webkit.org>
282
283         Reviewed by Anders.
284
285         Fix release build.
286
287         * bindings/objc/DOM.mm:
288         (-[DOMDocument createNodeIterator:whatToShow:filter:expandEntityReferences:]): Add missing null initialization.
289         (-[DOMDocument createTreeWalker:whatToShow:filter:expandEntityReferences:]): Add missing null initialization.
290
291 2007-06-06  Sam Weinig  <sam@webkit.org>
292
293         Reviewed by Hyatt.
294
295         Patch for http://bugs.webkit.org/show_bug.cgi?id=13947
296         Finish autogenerating the JS DOM traversal code
297
298         - Completely generate JSNodeFilter.
299         - Move JSNodeFilterCondition into its own file
300
301         * DerivedSources.make:
302         * WebCore.pro:
303         * WebCore.xcodeproj/project.pbxproj:
304         * bindings/js/JSNodeFilterCondition.cpp: Copied from WebCore/bindings/js/kjs_traversal.cpp.
305         (WebCore::JSNodeFilterCondition::JSNodeFilterCondition):
306         (WebCore::JSNodeFilterCondition::mark):
307         (WebCore::JSNodeFilterCondition::acceptNode):
308         * bindings/js/JSNodeFilterCondition.h: Copied from WebCore/bindings/js/kjs_traversal.h.
309         * bindings/js/JSNodeFilterCustom.cpp: Added.
310         (WebCore::JSNodeFilter::mark):
311         (WebCore::toNodeFilter):
312         * bindings/js/kjs_dom.cpp:
313         * bindings/js/kjs_traversal.cpp: Removed.
314         * bindings/js/kjs_traversal.h: Removed.
315         * bindings/js/kjs_window.cpp:
316         * bindings/objc/DOM.mm:
317         (-[DOMDocument createNodeIterator:whatToShow:filter:expandEntityReferences:]):
318         (-[DOMDocument createTreeWalker:whatToShow:filter:expandEntityReferences:]):
319         * bindings/scripts/CodeGeneratorJS.pm:
320         * dom/Document.cpp:
321         (WebCore::Document::createNodeIterator):
322         (WebCore::Document::createTreeWalker):
323         * dom/Document.h:
324         * dom/NodeFilter.idl:
325
326 2007-06-06  Alp Toker  <alp.toker@collabora.co.uk>
327
328         Reviewed by Eric Seidel.
329
330         http://bugs.webkit.org/show_bug.cgi?id=14017
331         Cairo: Unwanted gradient effect for small stretched images
332
333         * platform/graphics/cairo/ImageCairo.cpp: Use CAIRO_FILTER_NEAREST to
334         work around the issue.
335         (WebCore::BitmapImage::draw):
336         (WebCore::Image::drawPattern):
337
338 2007-06-06  Lars Knoll <lars@trolltech.com>
339
340         Reviewed by Zack
341
342         Add an API to create and load plugins.
343         Don't include moc files by hand anymore, rather let
344         qmake handle them.
345
346         * WebCore.pro:
347         * platform/qt/MimeTypeRegistryQt.cpp:
348         (WebCore::):
349         (WebCore::MimeTypeRegistry::getMIMETypeForExtension):
350         * platform/qt/QWebPopup.cpp:
351         * platform/qt/SharedTimerQt.cpp:
352
353 2007-06-06  Mark Rowe  <mrowe@apple.com>
354
355         Qt build fix.
356
357         * rendering/RenderTextControl.cpp: Fix case of #include filename.
358
359 2007-06-06  Lars Knoll  <lars@trolltech.com>
360
361         Reviewed by Maciej.
362
363         Define WTF_USE_NPOBJECT for Qt. Fix includes
364         in HTMLPluginElement and add proper forwarding headers
365         from JavaScriptCore.
366
367         * ForwardingHeaders/bindings/npruntime.h: Added.
368         * ForwardingHeaders/bindings/runtime.h: Added.
369         * config.h:
370         * html/HTMLPlugInElement.cpp:
371         * html/HTMLPlugInElement.h:
372
373 2007-06-06  David Hyatt  <hyatt@apple.com>
374
375         Bulletproof windowClipRect, since it can be called at crazy times.
376         Part of fix for 13972.
377
378         Reviewed by olliej
379
380         * bindings/objc/DOM.mm:
381         (-[DOMElement _windowClipRect]):
382
383 2007-06-05  MorganL  <morganl.webkit@yahoo.com>
384
385         Reviewed by Dave Hyatt.
386
387         Fixes http://bugs.webkit.org/show_bug.cgi?id=14008
388
389         * rendering/RenderTextControl.cpp:
390         (WebCore::RenderTextControl::calcHeight):
391         (WebCore::RenderTextControl::calcPrefWidths):
392
393 2007-06-05  Kevin McCullough  <kmccullough@apple.com>
394
395         - Respelling Oliver's name right.
396
397 2007-06-05  Kevin McCullough  <kmccullough@apple.com>
398
399         Reviewed by Mark and Oliver.
400
401         - http://bugs.webkit.org/show_bug.cgi?id=13352  REGRESSION: Gmail hangs on send message.
402         - Now we don't hang, but we do so by avoiding certain legitimate characters, the evangelism bug for this is: <rdar://problem/5252577> gmail does not accept legal characters in the form boundary
403
404         * html/HTMLFormElement.cpp:
405         (WebCore::getUniqueBoundaryString):
406
407 2007-06-05  Anders Carlsson  <andersca@apple.com>
408
409         Build fix.
410         
411         * xml/xmlhttprequest.cpp:
412         (WebCore::isValidToken):
413
414 2007-06-05  Anders Carlsson  <andersca@apple.com>
415
416         Reviewed by Geoff.
417
418         <rdar://problem/5245555> REGRESSION: HTTP header injection in XMLHttpRequest.setRequestHeader
419         <rdar://problem/5246208> HTTP injection in XMLHttpRequest.open method parameter
420         <rdar://problem/5246242> HTTP header injection in HXMLHttpRequest.setRequestHeader header parameter
421         
422         Check method names, header names and header values and throw exceptions if any of them are
423         invalid. This is what the new XMLHttpRequest spec states that we should do.
424         
425         * xml/xmlhttprequest.cpp:
426         (WebCore::isValidToken):
427         (WebCore::isValidHeaderValue):
428         (WebCore::XMLHttpRequest::open):
429         (WebCore::XMLHttpRequest::setRequestHeader):
430
431 2007-06-05  Sam Weinig  <sam@webkit.org>
432
433         Reviewed by Geoff.
434
435         Optimize JSCSSStyleDeclaration after performance regression in r21854.
436
437         - Check static table before name getter in JSCSSStyleDeclaration::getOwnPropertySlot()
438         - Get rid of a string allocation by keeping string as KJS::Identifier for canGetItemsForName()
439           functions.
440
441         * WebCore.xcodeproj/project.pbxproj:
442         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
443         (WebCore::JSCSSStyleDeclaration::canGetItemsForName):
444         * bindings/js/JSHTMLAppletElementCustom.cpp:
445         (WebCore::JSHTMLAppletElement::canGetItemsForName):
446         * bindings/js/JSHTMLDocumentCustom.cpp:
447         (WebCore::JSHTMLDocument::canGetItemsForName):
448         * bindings/js/JSHTMLEmbedElementCustom.cpp:
449         (WebCore::JSHTMLEmbedElement::canGetItemsForName):
450         * bindings/js/JSHTMLFormElementCustom.cpp:
451         (WebCore::JSHTMLFormElement::canGetItemsForName):
452         * bindings/js/JSHTMLFrameSetElementCustom.cpp:
453         (WebCore::JSHTMLFrameSetElement::canGetItemsForName):
454         * bindings/js/JSHTMLObjectElementCustom.cpp:
455         (WebCore::JSHTMLObjectElement::canGetItemsForName):
456         * bindings/scripts/CodeGeneratorJS.pm:
457         * css/CSSStyleDeclaration.idl:
458
459 2007-06-04  Sam Weinig  <sam@webkit.org>
460
461         Reviewed, tweaked and landed by Anders.
462
463         <rdar://problem/5247178> REGRESSION: With CSS Edit 2.5, a crash occurs at WebCore::DeprecatedString::DeprecatedString when page fails to be extracted
464         
465         Null check the provisional document loader. If an application stops the load 
466         inside of the didFailProvisionalLoad delegate method, the provisional document loader will be nulled out.
467
468         * loader/FrameLoader.cpp:
469         (WebCore::FrameLoader::checkLoadCompleteForThisFrame):
470
471 2007-06-04  Alp Toker  <alp.toker@collabora.co.uk>
472
473         Reviewed by Anders.
474
475         http://bugs.webkit.org/show_bug.cgi?id=13986
476         Cairo graphics fixes and cleanups
477
478         * platform/graphics/ImageBuffer.h:
479         * platform/graphics/cairo/ImageBufferCairo.cpp:
480         (WebCore::ImageBuffer::surface): Provide surface() accessor.
481         * platform/graphics/cairo/AffineTransformCairo.cpp:
482         (WebCore::AffineTransform::rotate): Convert from degrees to radians to
483         fix rotation.
484         * platform/graphics/cairo/GraphicsContextCairo.cpp:
485         (WebCore::GraphicsContext::drawRect): Add save/restore.
486         (WebCore::GraphicsContext::rotate): Rename parameter to "radians" to
487         avoid further confusion.
488         * platform/graphics/cairo/PathCairo.cpp:
489         (WebCore::Path::boundingRect): The cairo_fill_extents() parameters do
490         not describe a point/size but rather the two control points of the
491         rectangular region.
492         (WebCore::Path::contains): Remove needless casts.
493
494 2007-06-04  Sam Weinig  <sam@webkit.org>
495
496         Reviewed by Adam Roben.
497
498         Fix the buildbot.
499
500         * rendering/RenderSVGContainer.cpp:
501         (WebCore::RenderSVGContainer::layout):
502
503 2007-06-04  Justin Garcia  <justin.garcia@apple.com>
504
505         Reviewed by Kimon Tsinteris.
506
507         <rdar://problem/5241148> REGRESSION: ActivEdit can't perform operations on certain selections
508         
509         Return valid equivalents from these methods (no [img, 1] for 
510         example). ActivEdit was using positions returned from these
511         methods to create new DOM Ranges.
512         
513         * editing/SelectionController.cpp:
514         (WebCore::SelectionController::baseNode):
515         (WebCore::SelectionController::baseOffset):
516         (WebCore::SelectionController::extentNode):
517         (WebCore::SelectionController::extentOffset):
518         (WebCore::SelectionController::anchorNode):
519         (WebCore::SelectionController::anchorOffset):
520         (WebCore::SelectionController::focusNode):
521         (WebCore::SelectionController::focusOffset):
522         * editing/SelectionController.h:
523
524 2007-06-04  Rob Buis  <buis@kde.org>
525
526         Fix the svg experimental build.
527
528         * ksvg2/svg/SVGFEFloodElement.cpp:
529
530 2007-06-04  Rob Buis  <buis@kde.org>
531
532         Reviewed by Hyatt.
533
534         http://bugs.webkit.org/show_bug.cgi?id=6170
535         CSS1: Properties for :first-letter aren't recalculated on color change
536
537         Mark styles with first-letter as unique.
538
539         * css/cssstyleselector.cpp:
540         (WebCore::CSSStyleSelector::styleForElement):
541
542 2007-06-01  Anders Carlsson  <acarlsson@apple.com>
543
544         Reviewed by David Harrison.
545
546         <rdar://problem/5236843> 
547         CrashTracer: [USER] 3 crashes in Mail at WebCore::Loader::didReceiveResponse(WebCore::SubresourceLoader*, WebCore::ResourceResponse const&)
548
549         This is by no means the best solution for handling user style sheets. I've filed <rdar://problem/5244734> 
550         for tracking that.
551         
552         * loader/loader.cpp:
553         (WebCore::Loader::didReceiveResponse):
554         If a load starts while the frame is still in the provisional state 
555         (this can be the case when loading the user style sheet), committing the load then causes all
556         requests to be removed from the m_requestsLoading map. This means that req might be null here.
557         In that case we just return early. 
558         
559 2007-06-01  Mitz Pettel  <mitz@webkit.org>
560
561         Reviewed by Adele.
562
563         - fix http://bugs.webkit.org/show_bug.cgi?id=13958
564           REGRESSION: Form select menu in iframe destroys form select menu on page
565
566         * page/mac/EventHandlerMac.mm:
567         (WebCore::EventHandler::sendFakeEventsAfterWidgetTracking): Instead of calling
568         the event handler methods directly, post the fake event on the application event
569         queue. This ensures that the fake event is handled only after handling of the
570         initiating event has ended, and is seen by ancestor frames' event handlers.
571
572 2007-06-01  George Staikos  <staikos@kde.org>
573
574         Reviewed by bdash.
575
576         Redo the build fix again after it was backed out
577
578         * WebCore.pro: add an include guard around CSSGrammar.h
579
580 2007-05-31  Geoffrey Garen  <ggaren@apple.com>
581
582         Reviewed by Beth Dakin.
583
584         Fixed <rdar://problem/5238177> Continuing after hitting breakpoint doesn't 
585         execute the next step.
586         
587         No test because the only code affected is the debugger, and none of the
588         relevant API is exported.
589         
590         Reverted an accidental change in 21324 that caused originRootObject for
591         the window object always to be 0. We could probably just remove the debugger's
592         dependency on originRootObject, but I wanted to be safe.
593
594         * page/mac/FrameMac.mm:
595         (WebCore::Frame::windowScriptObject):
596
597 2007-05-31  David Hyatt  <hyatt@apple.com>
598
599         Fix for 11768, Flash plugin does not respect clips set via CSS.
600
601         Reviewed by olliej
602
603         * bindings/objc/DOM.mm:
604         (-[DOMElement _windowClipRect]):
605         * bindings/objc/DOMPrivate.h:
606         * page/FrameView.cpp:
607         (WebCore::FrameView::windowClipRect):
608         (WebCore::FrameView::windowClipRectForLayer):
609         * platform/ScrollView.h:
610         (WebCore::ScrollView::contentsToWindow):
611         (WebCore::ScrollView::windowToContents):
612         * platform/mac/ScrollViewMac.mm:
613         (WebCore::ScrollView::contentsToWindow):
614         (WebCore::ScrollView::windowToContents):
615
616 2007-05-31  Sam Weinig  <sam@webkit.org>
617
618         Reviewed by Adam.
619
620         Fix build bot.
621
622         * ksvg2/svg/SVGSVGElement.cpp:
623         (WebCore::SVGSVGElement::setCurrentScale):
624
625 2007-05-31  Sam Weinig  <sam@webkit.org>
626
627         Fix Qt and Gdk builds.
628
629         * WebCore.pro: remove bindings/js/JSHTMLAnchorElementCustom.cpp
630
631 2007-05-31  Sam Weinig  <sam@webkit.org>
632
633         Reviewed by Geoff.
634
635         Patch for http://bugs.webkit.org/show_bug.cgi?id=10782
636         Classes should not override JSObject::toString(ExecState *)
637
638         Remove all overrides of JSObject::toString and JSObject::toPrimitive
639         which is a bad practice.  Instead, if an object, like the 
640         HTMLAnchorElement, needs to override to toString, it should add
641         a function to the JS object which will be called when needed.  This
642         also allows developers to override toString and valueOf from within JS.
643
644         Test: fast/js/toString-and-valueOf-override.html
645
646         * WebCore.xcodeproj/project.pbxproj:
647         * bindings/js/JSHTMLAnchorElementCustom.cpp: Removed.
648         * bindings/js/kjs_binding.cpp:
649         * bindings/js/kjs_binding.h:
650         * bindings/js/kjs_dom.cpp:
651         * bindings/js/kjs_dom.h:
652         * bindings/js/kjs_domnode.h:
653         * bindings/js/kjs_window.cpp:
654         (KJS::History::):
655         (KJS::LocationFunc::callAsFunction):
656         (KJS::SelectionFunc::callAsFunction):
657         * bindings/js/kjs_window.h:
658         * bindings/scripts/CodeGeneratorJS.pm:
659         * html/HTMLAnchorElement.cpp:
660         (WebCore::HTMLAnchorElement::toString):
661         * html/HTMLAnchorElement.h:
662         * html/HTMLAnchorElement.idl:
663
664 2007-05-31  Rob Buis  <buis@kde.org>
665
666         Reviewed by Darin.
667
668         http://bugs.webkit.org/show_bug.cgi?id=11272
669         Implement currentScale(), setCurrentScale() and currentTranslate() in SVGSVGElement
670
671         Allow zooming and panning, thereby implementing the above methods.
672
673         * ksvg2/svg/SVGDocument.cpp:
674         (WebCore::SVGDocument::zoomEnabled):
675         (WebCore::SVGDocument::startPan):
676         (WebCore::SVGDocument::updatePan):
677         * ksvg2/svg/SVGDocument.h:
678         * ksvg2/svg/SVGSVGElement.cpp:
679         (WebCore::SVGSVGElement::currentScale):
680         (WebCore::SVGSVGElement::setCurrentScale):
681         (WebCore::SVGSVGElement::currentTranslate):
682         (WebCore::SVGSVGElement::setCurrentTranslate):
683         * ksvg2/svg/SVGSVGElement.h:
684         * page/EventHandler.cpp:
685         (WebCore::EventHandler::EventHandler):
686         (WebCore::EventHandler::handleMousePressEvent):
687         (WebCore::EventHandler::handleMouseMoveEvent):
688         (WebCore::EventHandler::handleMouseReleaseEvent):
689         * page/EventHandler.h:
690         * page/Frame.cpp:
691         (WebCore::Frame::setZoomFactor):
692         * rendering/RenderSVGContainer.cpp:
693         (WebCore::RenderSVGContainer::layout):
694         (WebCore::RenderSVGContainer::paint):
695         (WebCore::RenderSVGContainer::absoluteTransform):
696         * rendering/RenderSVGContainer.h:
697
698 2007-05-31  Eric Seidel  <eric@webkit.org>
699
700         Reviewed by Niko.
701
702         Links are activated based on mouse down events instead of click events
703         http://bugs.webkit.org/show_bug.cgi?id=12570
704         
705         Test: svg/custom/prevent-default.svg
706
707         * html/HTMLAnchorElement.cpp: use MiddleButton and RightButton instead of 1 and 2
708         (WebCore::HTMLAnchorElement::defaultEventHandler):
709         * ksvg2/svg/SVGAElement.cpp:
710         (WebCore::SVGAElement::defaultEventHandler): make it function more like the HTML side
711
712 2007-05-30  Maciej Stachowiak  <mjs@apple.com>
713
714         Reviewed by Hyatt.
715
716         - fix layout test editing/style/table-selection.html
717         
718         This was broken by the change to keep whitespace text nodes in tables. They safely didn't render,
719         but the font delta style change command would wrap them in spans, creating extra anonymous table
720         cells.
721
722         * editing/ApplyStyleCommand.cpp:
723         (WebCore::ApplyStyleCommand::applyRelativeFontStyleChange): Don't wrap in a span if the text node
724         is not rendered.
725
726 2007-05-31  Alp Toker  <alp.toker@collabora.co.uk>
727
728         Reviewed by Eric Seidel.
729
730         http://bugs.webkit.org/show_bug.cgi?id=13941
731         Rename WebCore/platform/network/gdk to WebCore/platform/network/curl
732
733         * WebCore.pro:
734
735 2007-05-31  Alp Toker  <alp.toker@collabora.co.uk>
736
737         Reviewed by Niko.
738
739         Patch for http://bugs.webkit.org/show_bug.cgi?id=13945
740         GraphicsContextCairo enhancements necessary for SVG support
741
742         * platform/graphics/cairo/GraphicsContextCairo.cpp:
743         (WebCore::GraphicsContext::concatCTM):
744         (WebCore::GraphicsContext::beginPath):
745         (WebCore::GraphicsContext::addPath):
746
747 2007-05-31  Patti Hoa <patti@apple.com>
748
749         Reviewed by Darin.
750         
751         <rdar://problem/5221920> AXLink is returning a CFString instead of a CFURL for AXURL
752
753         * bridge/mac/WebCoreAXObject.mm:
754         (-[WebCoreAXObject accessibilityAttributeValue:]):
755         Convert the url string to an NSURL before returning as the AXURLAttribute
756
757 2007-05-30  Sam Weinig  <sam@webkit.org>
758
759         Reviewed by Oliver.
760
761         Patch for http://bugs.webkit.org/show_bug.cgi?id=13943
762         Autogenerate the JS bindings for the CSSStyleSheet
763
764         * DerivedSources.make:
765         * WebCore.pro:
766         * WebCore.xcodeproj/project.pbxproj:
767         * bindings/js/JSStyleSheetCustom.cpp:
768         (WebCore::toJS):
769         * bindings/js/kjs_css.cpp:
770         * bindings/js/kjs_css.h:
771         * bindings/scripts/CodeGeneratorJS.pm:
772         * css/CSSStyleSheet.cpp:
773         (WebCore::CSSStyleSheet::addRule):
774         (WebCore::CSSStyleSheet::cssRules):
775         * css/CSSStyleSheet.h:
776         (WebCore::CSSStyleSheet::rules):
777         (WebCore::CSSStyleSheet::removeRule):
778         * css/CSSStyleSheet.idl:
779         * page/DOMWindow.idl:
780
781 2007-05-30  Sam Weinig  <sam@webkit.org>
782
783         Reviewed by Oliver.
784
785         Patch for http://bugs.webkit.org/show_bug.cgi?id=13937
786         Autogenerate the JS bindings for the CSSValue
787
788         * WebCore.pro:
789         * WebCore.xcodeproj/project.pbxproj:
790         * bindings/js/JSCSSValueCustom.cpp: Added.
791         (WebCore::toJS):
792         * bindings/js/kjs_css.cpp:
793         * bindings/js/kjs_css.h:
794         * bindings/objc/DOMUtility.mm:
795         (KJS::createDOMWrapper):
796         * bindings/scripts/CodeGeneratorJS.pm:
797         * css/CSSValue.h:
798         (WebCore::CSSValue::setCssText):
799         * css/CSSValue.idl:
800
801 2007-05-30  Sam Weinig  <sam@webkit.org>
802
803         Reviewed by Oliver the Hun.
804
805         Patch for http://bugs.webkit.org/show_bug.cgi?id=13944
806         Generate and add missing JS constructors
807
808         * css/CSSRuleList.idl:
809         * css/CSSValueList.idl:
810         * css/Counter.idl:
811         * page/DOMWindow.idl:
812
813 2007-05-30  Justin Garcia  <justin.garcia@apple.com>
814  
815         Reviewed by Darin.
816  
817         http://bugs.webkit.org/show_bug.cgi?id=13915
818         REGRESSION(r21687): editing/inserting/paragraph-separator-* failing pixel test (misspelling markers)
819
820         After r21687, SimplifiedBackwardsTextIterator was no longer 
821         emitting a '\n' as it left the first block of a range ending 
822         at [block, 0]. So, foo<div>^<br></div> looked like foo^ to
823         spell checking (foo wasn't marked as misspelled).
824
825         After r21687, SBTI stopped emitting '\n's in the above case 
826         because 1) we stopped incorrectly emitting '\n's for nodes as 
827         we entered them and 2) we were and still are incorrectly calling 
828         code that should only be called when entering nodes as we leave 
829         them and 3) we don't call exitNode(), which is responsible 
830         for emitting the '\n' in the above testcase, when we should.
831
832         Before and after r21687, we'd call exitNode() for a node as 
833         we traversed in reverse pre-order from its first descendant 
834         out to its sibling or one of its ancestors' siblings.  We 
835         weren't calling it a) after we'd enter a node that could 
836         have children but had none and b) when leaving a container 
837         that contained the end of the range used to create the iterator.
838
839         * editing/TextIterator.cpp:
840         (WebCore::SimplifiedBackwardsTextIterator::SimplifiedBackwardsTextIterator):
841         (WebCore::SimplifiedBackwardsTextIterator::advance): Call exitNode() as we
842         leave a childless container node and a node where the range ended.
843         * editing/TextIterator.h: Track the end of the range used to create
844         the SimplifiedBackwardsTextIterator.
845
846 2007-05-30  Alp Toker  <alp.toker@collabora.co.uk>
847
848         Reviewed by Brady.
849
850         Enable logging in the Gdk port.
851         http://bugs.webkit.org/show_bug.cgi?id=13936
852
853         * WebCore.pro:
854         * platform/NotImplemented.h: Changed to use WTFLogVerbose.
855         * platform/gdk/LoggingGdk.cpp: Added.
856         (WebCore::InitializeLoggingChannelsIfNecessary):
857
858 2007-05-30  Beth Dakin  <bdakin@apple.com>
859
860         Reviewed by Hyatt.
861
862         Fix for <rdar://problem/5198882> CrashTracer: [USER] 7 crashes in 
863         Safari at com.apple.WebCore: WebCore::RenderBlock::layoutBlock + 
864         2360
865
866         The problem is that we are re-entering layout when we should not. 
867         http://trac.webkit.org/projects/webkit/changeset/21778 actually 
868         fixed this crash, but we have been inspired to add the same guard 
869         in two other possibly-dangerous places.
870
871         * page/FrameView.cpp:
872         (WebCore::FrameView::layout): Add the guard in two more places.
873
874 2007-05-30  Justin Garcia  <justin.garcia@apple.com>
875
876         Reviewed by Oliver.
877
878         <rdar://problem/5096134> VO gets stuck on Howto.apple.com
879         http://bugs.webkit.org/show_bug.cgi?id=8622
880         VisiblePositions aren't canonicalized in some cases
881         
882         No new test cases added: can't write automated tests 
883         for VO.
884
885         * editing/IndentOutdentCommand.cpp:
886         (WebCore::IndentOutdentCommand::outdentParagraph):
887         VisiblePositions must be recomputed after nodes that
888         may have effected their canonicalization are removed.
889         * editing/VisiblePosition.cpp:
890         (WebCore::canonicalizeCandidate): Added.
891         (WebCore::VisiblePosition::canonicalPosition): Canonicalize
892         the candidates returned by next/previousCandidate before
893         returning them.
894         * editing/VisiblePosition.h:
895         (WebCore::operator==): Remove the workaround for 8622.
896         * editing/visible_units.cpp:
897         (WebCore::startOfParagraph): Ditto.
898
899 2007-05-30  Sam Weinig  <sam@webkit.org>
900
901         Reviewed by Dr. Harrison.
902
903         Patch for http://bugs.webkit.org/show_bug.cgi?id=13868
904         REGRESSION: crash on accessing a new iframe's contentWindow property
905
906         Adds a null check in for the contentWindow property for HTMLIFrameElement
907         and HTMLFrameElement.
908
909         * bindings/scripts/CodeGeneratorJS.pm:
910         * html/HTMLFrameElement.idl:
911         * html/HTMLIFrameElement.idl:
912
913 2007-05-30  Mitz Pettel  <mitz@webkit.org>
914
915         Reviewed by Darin.
916
917         - fix http://bugs.webkit.org/show_bug.cgi?id=13775
918           REGRESSION: Popup button text should use "natural" directionality to match the items in the popup menu
919
920         Test: fast/forms/select-writing-direction-natural.html
921
922         * platform/PopupMenu.h: Added the static method itemWritingDirectionIsNatural
923         which says whether items in the popup ignore the CSS text-align and direction
924         properties and instead are left-aligned and use natural writing direction.
925         * platform/gdk/PopupMenuGdk.cpp:
926         (WebCore::PopupMenu::itemWritingDirectionIsNatural):
927         * platform/mac/PopupMenuMac.mm:
928         (WebCore::PopupMenu::itemWritingDirectionIsNatural):
929         * platform/qt/PopupMenuQt.cpp:
930         (WebCore::PopupMenu::itemWritingDirectionIsNatural):
931         * platform/win/TemporaryLinkStubs.cpp:
932         (WebCore::PopupMenu::itemWritingDirectionIsNatural):
933         * platform/wx/TemporaryLinkStubs.cpp:
934         (PopupMenu::itemWritingDirectionIsNatural):
935         * rendering/RenderMenuList.cpp:
936         (WebCore::textDirectionForParagraph): Added this helper function that uses
937         the Unicode Bidi Algorithm rules P2 and P3 to determine the writing direction
938         of text.
939         (WebCore::RenderMenuList::adjustInnerStyle): Made the alignment and direction
940         adjustment conditional on the popup implementation.
941         (WebCore::RenderMenuList::setText): Added call to adjustInnerStyle() since
942         the style depends on the text when natural writing direction is used.
943
944 2007-05-30  Timothy Hatcher  <timothy@apple.com>
945
946         Reviewed by Darin.
947
948         <rdar://problem/5200795> REGRESSION (r21057): lineBoxRects doesn't match actual text when wrapping occurs
949
950         Use box->end() instead of box->len().
951
952         * rendering/RenderText.cpp:
953         (WebCore::RenderText::addLineBoxRects):
954
955 2007-05-30  Sam Weinig  <sam@webkit.org>
956
957         Reviewed by Darin.
958
959         Patch for http://bugs.webkit.org/show_bug.cgi?id=13919
960         Autogenerate the JS bindings for the CSSRule and its subclasses
961
962         - subclasses generated are CSSCharsetRule, CSSFontFaceRule, CSSImportRule
963           CSSMediaRule, CSSPageRule and CSSStyleRule.
964
965         * DerivedSources.make:
966         * WebCore.pro:
967         * WebCore.xcodeproj/project.pbxproj:
968         * bindings/js/JSCSSRuleCustom.cpp: Added.
969         (WebCore::toJS):
970         * bindings/js/kjs_css.cpp:
971         * bindings/js/kjs_css.h:
972         * bindings/objc/DOMUtility.mm:
973         (KJS::createDOMWrapper):
974         * bindings/scripts/CodeGeneratorJS.pm:
975         * css/CSSCharsetRule.h:
976         (WebCore::CSSCharsetRule::setEncoding):
977         * css/CSSCharsetRule.idl:
978         * css/CSSFontFaceRule.idl:
979         * css/CSSImportRule.idl:
980         * css/CSSMediaRule.idl:
981         * css/CSSPageRule.cpp:
982         (WebCore::CSSPageRule::setSelectorText):
983         * css/CSSPageRule.h:
984         * css/CSSPageRule.idl:
985         * css/CSSRule.cpp:
986         (WebCore::CSSRule::setCssText):
987         * css/CSSRule.h:
988         * css/CSSRule.idl:
989         * css/CSSStyleRule.cpp:
990         (WebCore::CSSStyleRule::setSelectorText):
991         * css/CSSStyleRule.h:
992         * css/CSSStyleRule.idl:
993         * page/DOMWindow.idl: add new constructors.
994
995 2007-05-30  Mark Rowe  <mrowe@apple.com>
996
997         Build fixes after r21889.  Add missing #includes.
998
999         * ForwardingHeaders/kjs/function.h: Added.
1000         * bindings/js/kjs_binding.h:
1001         * bindings/js/kjs_dom.h:
1002         * bindings/js/kjs_window.h:
1003
1004 2007-05-30  Mark Rowe  <mrowe@apple.com>
1005
1006         Gdk build fix.  Update WidgetGdk to use NotImplemented.h.
1007
1008         * platform/gdk/WidgetGdk.cpp:
1009         (WebCore::Widget::setEnabled):
1010         (WebCore::Widget::isEnabled):
1011         (WebCore::Widget::removeFromParent):
1012         (WebCore::Widget::paint):
1013         (WebCore::Widget::setIsSelected):
1014
1015 2007-05-29  Holger Freyther  <zecke@selfish.org>
1016
1017         Reviewed by Anders.
1018
1019         Make ScrollView use a GtkLayout. This class matches QScrollView the most and promises
1020         to ease the implementation of ScrollView::addChild. GtkLayout should be resource friendly
1021         even with huge width and heights of frames.
1022         Make Widget aware of GtkLayout to use the right GdkWindow as drawable. For GtkLayout one must
1023         draw on the bin_window.
1024         Remove the layer violation from FrameGdk.cpp and ScrollView. FrameGdk is no longer responsible to
1025         implement scrolling on keyboard events. ScrollView is no longer required to know that it could be
1026         a FrameView and handles scrolling of Frames magically.
1027
1028         * platform/ScrollView.h:
1029         * platform/gdk/FrameGdk.cpp:
1030         (WebCore::FrameGdk::keyPress):
1031         (WebCore::FrameGdk::handleGdkEvent):
1032         * platform/gdk/ScrollViewGdk.cpp:
1033         (WebCore::ScrollView::ScrollViewPrivate::ScrollViewPrivate):
1034         (WebCore::ScrollView::updateContents):
1035         (WebCore::ScrollView::visibleWidth):
1036         (WebCore::ScrollView::visibleHeight):
1037         (WebCore::ScrollView::visibleContentRect):
1038         (WebCore::ScrollView::resizeContents):
1039         (WebCore::ScrollView::contentsX):
1040         (WebCore::ScrollView::contentsY):
1041         (WebCore::ScrollView::scrollOffset):
1042         (WebCore::ScrollView::scrollBy):
1043         (WebCore::ScrollView::setFrameGeometry):
1044         (WebCore::ScrollView::updateGeometry):
1045         (WebCore::ScrollView::setGtkWidget):
1046         (WebCore::ScrollView::updateScrollbars):
1047         (WebCore::ScrollView::windowToContents):
1048         (WebCore::ScrollView::contentsToWindow):
1049         (WebCore::ScrollView::scrollbarUnderMouse):
1050         * platform/gdk/TemporaryLinkStubs.cpp: Move Widget methods to WidgetGdk.cpp
1051         * platform/gdk/WidgetGdk.cpp:
1052         (WebCore::Widget::setGtkWidget):
1053         (WebCore::Widget::setFrameGeometry):
1054         (WebCore::Widget::setEnabled):
1055         (WebCore::Widget::isEnabled):
1056         (WebCore::Widget::removeFromParent):
1057         (WebCore::Widget::paint):
1058         (WebCore::Widget::setIsSelected):
1059         (WebCore::Widget::invalidate):
1060         (WebCore::Widget::invalidateRect):
1061
1062 2007-05-29  Krzysztof Kowalczyk  <kkowalczyk@gmail.com>
1063
1064         Reviewed by Maciej.
1065
1066         Curl (linux/gdk) networking improvements: 
1067         a) POST support
1068         b) don't use CURL in a re-entrant way.
1069         c) turn on curl's internal debugging support in a debug build if the DEBUG_CURL environment variable is set.
1070
1071         * platform/network/ResourceHandleInternal.h:
1072         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
1073         * platform/network/gdk/ResourceHandleCurl.cpp:
1074         (WebCore::ResourceHandleInternal::~ResourceHandleInternal):
1075         * platform/network/gdk/ResourceHandleManager.cpp:
1076         (WebCore::ResourceHandleManager::ResourceHandleManager):
1077         (WebCore::writeCallback):
1078         (WebCore::ResourceHandleManager::downloadTimerCallback):
1079         (WebCore::ResourceHandleManager::setupPOST):
1080         (WebCore::ResourceHandleManager::add):
1081         (WebCore::ResourceHandleManager::removeScheduledJob):
1082         (WebCore::ResourceHandleManager::startScheduledJobs):
1083         (WebCore::ResourceHandleManager::startJob):
1084         (WebCore::ResourceHandleManager::cancel):
1085         * platform/network/gdk/ResourceHandleManager.h:
1086         (WebCore::ResourceHandleList::ResourceHandleList):
1087         (WebCore::ResourceHandleList::next):
1088         (WebCore::ResourceHandleList::job):
1089         (WebCore::ResourceHandleList::setRemoved):
1090         (WebCore::ResourceHandleList::removed):
1091
1092 2007-05-29  Sam Weinig  <sam@webkit.org>
1093
1094         Fix the Qt and Gdk builds.
1095
1096         * WebCore.pro:
1097
1098 2007-05-29  Adele Peterson  <adele@apple.com>
1099
1100         Reviewed by Adam.
1101
1102         Fix for <rdar://problem/5109711> REGRESSION: Focus ring artifacts appear around a widget's search field at times (Address Book, Dictionary)
1103
1104         * rendering/RenderThemeMac.mm: (WebCore::RenderThemeMac::paintSearchField):
1105           We only need this hack for drawing the search field focus ring on Tiger.  On Leopard, drawWithFrame correctly draws the cell's focus ring.
1106
1107 2007-05-29  Alp Toker  <alp.toker@collabora.co.uk>
1108
1109         Reviewed by Mitz.
1110
1111         Patch for http://bugs.webkit.org/show_bug.cgi?id=13899
1112
1113         * platform/graphics/cairo/GraphicsContextCairo.cpp:
1114         (WebCore::GraphicsContext::strokeArc): Use cairo_arc_negative() to fix
1115         CSS rounded borders.
1116         (WebCore::GraphicsContext::beginTransparencyLayer):
1117         (WebCore::GraphicsContext::endTransparencyLayer): save/restore is
1118         redundant. push/pop group does this implicitly.
1119
1120 2007-05-29  Sam Weinig  <sam@webkit.org>
1121
1122         Reviewed by Oliver.
1123
1124         Patch for http://bugs.webkit.org/show_bug.cgi?id=13912
1125         Autogenerate the JS bindings for the MediaList
1126
1127         * DerivedSources.make:
1128         * WebCore.xcodeproj/project.pbxproj:
1129         * bindings/js/kjs_css.cpp:
1130         * bindings/js/kjs_css.h:
1131         * bindings/objc/DOMUtility.mm:
1132         (KJS::createDOMWrapper):
1133         * bindings/scripts/CodeGeneratorJS.pm:
1134         * css/MediaList.idl:
1135         * page/DOMWindow.idl: Add constructor.
1136
1137 2007-05-29  Matt Perry  <mpComplete@gmail.com>
1138
1139         Reviewed by Maciej.
1140
1141         Fixed some rendering issues for <select>s on Windows.
1142
1143         * rendering/RenderThemeWin.cpp:
1144         (WebCore::RenderThemeWin::adjustMenuListStyle):
1145         (WebCore::RenderThemeWin::paintMenuList):
1146         * rendering/RenderThemeWin.h:
1147
1148 2007-05-29  David Hyatt  <hyatt@apple.com>
1149
1150         Fold the invalidateVerticalPositions crawl into the bidi iteration.
1151         This makes it more correct (since we won't drill into elements that
1152         did not need to be reset) and cuts out an extra walk of all our children.
1153         We're still O(n^2) as new content streams in, but this at least cuts
1154         out one separate O(n^2) crawl.
1155
1156         Reviewed by olliej
1157
1158         * rendering/RenderObject.cpp:
1159         * rendering/RenderObject.h:
1160         (WebCore::RenderObject::invalidateVerticalPosition):
1161         * rendering/bidi.cpp:
1162         (WebCore::RenderBlock::layoutInlineChildren):
1163
1164 2007-05-29  Sam Weinig  <sam@webkit.org>
1165
1166         Reviewed by Oliver.
1167
1168         Patch for http://bugs.webkit.org/show_bug.cgi?id=13908
1169         Autogenerate the JS bindings for the StyleSheet
1170
1171         * DerivedSources.make:
1172         * WebCore.xcodeproj/project.pbxproj:
1173         * bindings/js/JSStyleSheetCustom.cpp: Added.
1174         (WebCore::toJS):
1175         (WebCore::JSStyleSheet::toBoolean):
1176         * bindings/js/kjs_css.cpp:
1177         (KJS::):
1178         (KJS::DOMCSSStyleSheet::DOMCSSStyleSheet):
1179         (KJS::DOMCSSStyleSheet::getOwnPropertySlot):
1180         * bindings/js/kjs_css.h:
1181         * bindings/objc/DOMUtility.mm:
1182         (KJS::createDOMWrapper):
1183         * bindings/scripts/CodeGeneratorJS.pm:
1184         * css/StyleSheet.idl:
1185         * page/DOMWindow.idl: Add new constructor.
1186
1187 2007-05-29  David Hyatt  <hyatt@apple.com>
1188
1189         Make sure <embed> does not allow an end tag.
1190
1191         Reviewed by olliej
1192
1193         * html/HTMLEmbedElement.h:
1194         (WebCore::HTMLEmbedElement::endTagRequirement):
1195
1196 2007-05-29  Adele Peterson  <adele@apple.com>
1197
1198         Reviewed by Brady.
1199
1200         Fix for <rdar://problem/5213039> REGRESSION: Wells Fargo registration page returns blank
1201
1202         Roll out updated fix for 11866 that tried to make reset work for hidden inputs.  Since
1203         all browsers update the value attribute when setting the value, it doesn't really make sense to reset.
1204         Its true that IE does support resetting these controls, but in this case, it doesn't really make sense to have
1205         another place to store an alternate version of the value.
1206
1207         * html/HTMLInputElement.cpp: (WebCore::HTMLInputElement::reset):
1208         * html/HTMLInputElement.h:
1209
1210 2007-05-29  Darin Adler  <darin@apple.com>
1211
1212         Reviewed by Anders.
1213
1214         - removed the general case optimization for innerHTML because some sites
1215           rely on setting innerHTML to trigger loading plug-ins for example; we
1216           could consider bringing it back some day, perhaps with a list of element
1217           types to exclude
1218
1219         * dom/CharacterData.cpp: (WebCore::CharacterData::setData):
1220         Do nothing if the old data is identical to the new data.
1221
1222         * html/HTMLElement.cpp:
1223         (WebCore::replaceChildrenWithFragment): Remove childrenAreEqual optimization.
1224         (WebCore::replaceChildrenWithText): Remove optimization for cases where the
1225         text data is identical to the new data, since CharacterData handles that now.
1226         (WebCore::HTMLElement::setOuterHTML): Remove childrenAreEqual optimization.
1227
1228 2007-05-29  Mitz Pettel  <mitz@webkit.org>
1229
1230         Reviewed by Maciej.
1231
1232         - fix http://bugs.webkit.org/show_bug.cgi?id=13904
1233           REGRESSION: Search fields with a results popup do not always draw the popup arrow
1234
1235         Covered by fast/forms/box-shadow-override.html
1236
1237         The search button draws a popup arrow depending on whether the
1238         search menu template is set, rather than on the maximum number of recent
1239         search strings.
1240
1241         * rendering/RenderThemeMac.h:
1242         * rendering/RenderThemeMac.mm:
1243         (WebCore::RenderThemeMac::paintSearchFieldResultsDecoration): Removed the
1244         call to -setMaxmiumRecents:.
1245         (WebCore::RenderThemeMac::paintSearchFieldResultsButton): Replaced calling
1246         -setMaximumRecents: with setting the search menu template.
1247         (WebCore::RenderThemeMac::search): Removed initialization of the menu.
1248         (WebCore::RenderThemeMac::searchMenuTemplate): Added. Returns an empty
1249         NSMenu to be used as the search menu template.
1250
1251 2007-05-29  David Hyatt  <hyatt@apple.com>
1252
1253         Fix for bug 13907, <noscript> should be allowed inside <head> when
1254         scripting is enabled.
1255
1256         Reviewed by aroben
1257
1258         * html/HTMLHeadElement.cpp:
1259         (WebCore::HTMLHeadElement::checkDTD):
1260         * html/HTMLParser.cpp:
1261         (WebCore::HTMLParser::handleError):
1262         * html/HTMLParserErrorCodes.cpp:
1263         (WebCore::htmlParserErrorMessageTemplate):
1264         * html/HTMLParserErrorCodes.h:
1265
1266 2007-05-29  Mitz Pettel  <mitz@webkit.org>
1267
1268         Reviewed by Maciej.
1269
1270         - fix crash in http://bugs.webkit.org/show_bug.cgi?id=13792
1271           REGRESSION: WebKit doesn't show this javascript screenshot page (and crashes after click on its "hidden link")
1272
1273         Test: fast/frames/removal-before-attach-crash.html
1274
1275         Delayed the queueing of the post-attach callback until attach().
1276
1277         * html/HTMLFrameElementBase.cpp:
1278         (WebCore::HTMLFrameElementBase::HTMLFrameElementBase):
1279         (WebCore::HTMLFrameElementBase::parseMappedAttribute): Replaced call to the
1280         HTMLElement implementation with a call to the HTMLFrameOwnerElement
1281         implementation, as the latter is the parent class.
1282         (WebCore::HTMLFrameElementBase::insertedIntoDocument): Instead of queueing
1283         the post-attach callback here, just set a flag telling us to do so
1284         at the beginning of attach().
1285         (WebCore::HTMLFrameElementBase::removedFromDocument): Reset the above flag.
1286         (WebCore::HTMLFrameElementBase::attach): If this is the first attach() after
1287         being inserted into the document, queue a post-attach callback to load the
1288         frame.
1289         (WebCore::HTMLFrameElementBase::willRemove): Changed to call up to the correct
1290         parent class.
1291         (WebCore::HTMLFrameElementBase::setFocus): Ditto.
1292         * html/HTMLFrameElementBase.h:
1293         * html/HTMLPlugInElement.cpp:
1294         (WebCore::HTMLPlugInElement::mapToEntry): Replaced call to the HTMLElement
1295         implementation with a call to the HTMLFrameOwnerElement implementation,
1296         as the latter is the parent class.
1297         (WebCore::HTMLPlugInElement::parseMappedAttribute): Ditto.
1298         (WebCore::HTMLPlugInElement::checkDTD): Ditto.
1299         (WebCore::HTMLPlugInElement::detach): Ditto.
1300
1301 2007-05-29  Darin Adler  <darin@apple.com>
1302
1303         Reviewed by Maciej.
1304
1305         - fix http://bugs.webkit.org/show_bug.cgi?id=13602
1306           Amazon product pages keep repainting over and over again
1307
1308         - fix first-letter when the text of the affected text node is changed
1309
1310         Optimize setInnerHTML, setOuterHTML, and setInnerText so they don't change the DOM at all
1311         if they don't need to.
1312
1313         Test: fast/dom/HTMLElement/set-inner-outer-optimization.html
1314         Test: fast/css/first-letter-detach.html
1315
1316         * html/HTMLElement.cpp:
1317         (WebCore::equal): Added. Helper function that compares two Text nodes or two NamedAttrMap
1318         attribute maps.
1319         (WebCore::shallowEqual): Added. Helper function that compares two Element nodes or two
1320         arbitrary nodes.
1321         (WebCore::childrenAreEqual): Added. Helper functions that compare children of nodes.
1322         (WebCore::hasOneChild): Added. Helper function.
1323         (WebCore::hasOneTextChild): Added. Helper function.
1324         (WebCore::replaceChildrenWithFragment): Added. Helper function used by setInnerHTML and
1325         setInnerText. Optimizes the cases where all the nodes are the same, where both the current
1326         and the new content are single text nodes, and where the current content is a single node
1327         that can be replaced with replaceChild.
1328         (WebCore::replaceChildrenWithText): Added. Helper function used by setInnerText. Optimizes
1329         the case where the current content is a single text node or a single node that can be
1330         replaced with replaceChild.
1331         (WebCore::HTMLElement::setInnerHTML): Changed to call replaceChildrenWithFragment.
1332         (WebCore::HTMLElement::setOuterHTML): Added special case to optimize when the new content
1333         exactly matches the current node.
1334         (WebCore::HTMLElement::setInnerText): Changed to call replaceChildrenWithText in a few
1335         cases instead of doing removeChildren/appendChild. Changed code that was using
1336         DeprecatedString to instead use String. Changed general case to use a document fragment
1337         and replaceChildrenWithFragment.
1338
1339         * dom/CharacterData.cpp: (WebCore::CharacterData::dispatchModifiedEvent):
1340         Fixed bug where we would not dispatch the DOMSubtreeModified event unless someone
1341         was registered for the DOMCharacterDataModified event. Caused trouble in the test.
1342
1343         * rendering/RenderBlock.cpp: (WebCore::RenderBlock::updateFirstLetter): Set first-letter
1344         after the setStyle call so calls to setTextInternal inside setStyle don't clear it.
1345
1346         * rendering/RenderText.h: Made setTextInternal virtual so that RenderTextFragment can do
1347         appropriate work when the text changes.
1348
1349         * rendering/RenderTextFragment.h: Added an override of setTextInternal. Removed the
1350         firstLetter parameter to the constructor and made it a separate setter. Also changed
1351         m_generatedContentStr to m_contentString to match the getter function.
1352         * rendering/RenderTextFragment.cpp:
1353         (WebCore::RenderTextFragment::RenderTextFragment): Removed firstLetter parameter.
1354         (WebCore::RenderTextFragment::setTextInternal): When the text changes, destroy the
1355         first-letter node and reset the fragment values so that RenderBlock::updateFirstLetter,
1356         which will run during layout, will create a new first-letter child. Otherwise we end up
1357         with the first letter of the old text.
1358
1359 2007-05-29  Sam Weinig  <sam@webkit.org>
1360
1361         Fix Qt build.
1362
1363         * platform/NotImplemented.h:
1364
1365 2007-05-29  Sam Weinig  <sam@webkit.org>
1366
1367         Reviewed by Adam Roben.
1368
1369         Consolidate platform dependent notImplemented() macros
1370         into one platform independent macro that uses WTFLog.
1371
1372         * platform/NotImplemented.h:
1373
1374 2007-05-29  Darin Adler  <darin@apple.com>
1375
1376         Reviewed by Sam.
1377
1378         - a clean-up pass on form-related aspects of the recent JSHTMLElement patch
1379
1380         * bindings/js/JSHTMLElementCustom.cpp: (WebCore::JSHTMLElement::pushEventHandlerScope):
1381         Replace the call to formForEventHandlerScope() with a call to the new form() function.
1382         And removed the now-uneeded code to search for a form ancestor.
1383
1384         * html/HTMLElement.h: Added a general-purpose form() function. The intent is to return
1385         the form ancestor if any, but return the associated form for a form control, which isn't
1386         always an ancestor of the control. To keep form() efficient for form controls, it's an
1387         inline that calls a virtual, allowing a derived class to override it with an inline.
1388         This replaces formForEventHandlerScope(). Also added findFormAncestor() to use here and
1389         to replace the multiple loops found elsewhere to search for the nearest form ancestor.
1390         * html/HTMLElement.cpp:
1391         (WebCore::HTMLElement::findFormAncestor): Added.
1392         (WebCore::HTMLElement::virtualForm): Added. Calls findFormAncestor().
1393
1394         * html/HTMLGenericFormElement.h: Suggested name change to HTMLFormControlElement.
1395         Removed the confusing getForm() function, which is superceded by findFormAncestor.
1396         Removed the unused onSelect() function. Removed the override of formForEventHandlerScope(),
1397         replacing it with an override of virtualForm().
1398         * html/HTMLGenericFormElement.cpp:
1399         (WebCore::HTMLGenericFormElement::HTMLGenericFormElement): Use findFormAncestor
1400         instead of getForm.
1401         (WebCore::HTMLGenericFormElement::insertedIntoTree): Ditto.
1402         (WebCore::HTMLGenericFormElement::virtualForm): Added.
1403
1404         * html/HTMLLabelElement.h: Removed now-unneeded form() and formForEventHandlerScope()
1405         functions, since base class behavior is now good enough. Renamed formElement() to
1406         correspondingControl(), since that's the terminology used elsewhere in the code,
1407         and the old name was unnecessarily confusing.
1408         * html/HTMLLabelElement.cpp:
1409         (WebCore::HTMLLabelElement::correspondingControl): Renamed. Removed unnecessary
1410         special case for empty ID, since getElementById already returns 0 for that case.
1411         (WebCore::HTMLLabelElement::setActive): Updated for name change.
1412         (WebCore::HTMLLabelElement::setHovered): Ditto.
1413         (WebCore::HTMLLabelElement::defaultEventHandler): Ditto.
1414         (WebCore::HTMLLabelElement::focus): Ditto.
1415         (WebCore::HTMLLabelElement::accessKeyAction): Ditto.
1416
1417         * html/HTMLObjectElement.h: Removed now-unneeded form() and formForEventHandlerScope()
1418         functions, since base class behavior is now good enough. Also removed forward
1419         declaration of KJS::Bindings::Instance -- since the type is the return value of a
1420         function from the base class, it's guaranteed to be declared in the base class header.
1421         * html/HTMLObjectElement.cpp: Ditto.
1422
1423         * bridge/mac/WebCoreAXObject.mm: (labelForElement): Updated for name change.
1424
1425 2007-05-29  Zack Rusin  <zrusin@trolltech.com>
1426
1427         Reviewed by George and Niko
1428
1429         Making the convenience method notImplemented convenient
1430         for the Qt port.
1431
1432         * platform/NotImplemented.h:
1433
1434 2007-05-28  Sam Weinig  <sam@webkit.org>
1435
1436         Reviewed by Geoff.
1437
1438         - Patch for http://bugs.webkit.org/show_bug.cgi?id=13902
1439           Autogenerate the JS bindings for the CSSStyleDeclaration
1440
1441         * WebCore.pro:
1442         * WebCore.xcodeproj/project.pbxproj:
1443         * bindings/js/JSCSSStyleDeclarationCustom.cpp: Added.
1444         (WebCore::cssPropertyName):
1445         (WebCore::isCSSPropertyName):
1446         (WebCore::JSCSSStyleDeclaration::canGetItemsForName):
1447         (WebCore::JSCSSStyleDeclaration::nameGetter):
1448         (WebCore::JSCSSStyleDeclaration::customPut):
1449         * bindings/js/kjs_binding.h:
1450         * bindings/js/kjs_css.cpp:
1451         * bindings/js/kjs_css.h:
1452         * bindings/objc/DOMUtility.mm:
1453         (KJS::createDOMWrapper):
1454         * bindings/scripts/CodeGeneratorJS.pm:
1455         * css/CSSStyleDeclaration.idl:
1456
1457 2007-05-28  Mitz Pettel  <mitz@webkit.org>
1458
1459         Reviewed by Darin.
1460
1461         - fix http://bugs.webkit.org/show_bug.cgi?id=13896
1462           REGRESSION (NativePopup): Reproductible crasher on Google Coop control panel
1463
1464         Test: fast/forms/select-display-none-style-resolve.html
1465
1466         * html/HTMLOptGroupElement.cpp:
1467         (WebCore::HTMLOptGroupElement::attach): Do not compute style if the parent
1468         does not have style.
1469         * html/HTMLOptionElement.cpp:
1470         (WebCore::HTMLOptionElement::attach): Ditto.
1471
1472 2007-05-28  Sam Weinig  <sam@webkit.org>
1473
1474         Fix Gdk and Qt builds.
1475
1476         * WebCore.pro:
1477
1478 2007-05-28  Sam Weinig  <sam@webkit.org>
1479
1480         Reviewed by Darin.
1481
1482         Patch for http://bugs.webkit.org/show_bug.cgi?id=13894
1483         Remove the legacy class KJS::JSHTMLElement
1484
1485         - Now that all of the subclasses of JSHTMLElement are
1486           autogenerated and no longer rely on the legacy parent,
1487           we can remove it and update all the HTML idl files to
1488           reflect so.
1489
1490         - Also adds JSHTMLBlockquoteElement's JS constructor which
1491           was mistakingly missing.
1492
1493         * WebCore.xcodeproj/project.pbxproj:
1494         * bindings/js/JSHTMLAnchorElementCustom.cpp:
1495         (WebCore::JSHTMLAnchorElement::toString):
1496         * bindings/js/JSHTMLElementCustom.cpp: Added.
1497         (WebCore::JSHTMLElement::pushEventHandlerScope):
1498         * bindings/js/JSHTMLElementWrapperFactory.cpp:
1499         (WebCore::createJSHTMLWrapper):
1500         * bindings/js/JSHTMLInputElementBase.cpp:
1501         (WebCore::):
1502         (WebCore::JSHTMLInputElementBase::JSHTMLInputElementBase):
1503         (WebCore::JSHTMLInputElementBase::getOwnPropertySlot):
1504         (WebCore::JSHTMLInputElementBase::put):
1505         * bindings/js/JSHTMLInputElementBase.h:
1506         * bindings/js/JSHTMLSelectElementCustom.cpp:
1507         * bindings/js/kjs_html.cpp:
1508         (KJS::runtimeObjectCustomGetOwnPropertySlot):
1509         * bindings/js/kjs_html.h:
1510         * bindings/scripts/CodeGeneratorJS.pm:
1511         * html/HTMLAnchorElement.idl:
1512         * html/HTMLAppletElement.idl:
1513         * html/HTMLAreaElement.idl:
1514         * html/HTMLBRElement.idl:
1515         * html/HTMLBaseElement.idl:
1516         * html/HTMLBaseFontElement.idl:
1517         * html/HTMLBlockquoteElement.idl:
1518         * html/HTMLBodyElement.idl:
1519         * html/HTMLButtonElement.idl:
1520         * html/HTMLCanvasElement.idl:
1521         * html/HTMLDListElement.idl:
1522         * html/HTMLDirectoryElement.idl:
1523         * html/HTMLDivElement.idl:
1524         * html/HTMLElement.cpp:
1525         (WebCore::HTMLElement::formForEventHandlerScope):
1526         * html/HTMLElement.h:
1527         * html/HTMLElement.idl:
1528         * html/HTMLEmbedElement.idl:
1529         * html/HTMLFieldSetElement.idl:
1530         * html/HTMLFontElement.idl:
1531         * html/HTMLFormElement.idl:
1532         * html/HTMLFrameElement.idl:
1533         * html/HTMLFrameSetElement.idl:
1534         * html/HTMLGenericFormElement.cpp:
1535         (WebCore::HTMLGenericFormElement::formForEventHandlerScope):
1536         * html/HTMLGenericFormElement.h:
1537         * html/HTMLHRElement.idl:
1538         * html/HTMLHeadElement.idl:
1539         * html/HTMLHeadingElement.idl:
1540         * html/HTMLHtmlElement.idl:
1541         * html/HTMLIFrameElement.idl:
1542         * html/HTMLImageElement.idl:
1543         * html/HTMLIsIndexElement.idl:
1544         * html/HTMLLIElement.idl:
1545         * html/HTMLLabelElement.cpp:
1546         (WebCore::HTMLLabelElement::form):
1547         (WebCore::HTMLLabelElement::formForEventHandlerScope):
1548         * html/HTMLLabelElement.h:
1549         * html/HTMLLabelElement.idl:
1550         * html/HTMLLegendElement.idl:
1551         * html/HTMLLinkElement.idl:
1552         * html/HTMLMapElement.idl:
1553         * html/HTMLMarqueeElement.idl:
1554         * html/HTMLMenuElement.idl:
1555         * html/HTMLMetaElement.idl:
1556         * html/HTMLModElement.idl:
1557         * html/HTMLOListElement.idl:
1558         * html/HTMLObjectElement.cpp:
1559         (WebCore::HTMLObjectElement::formForEventHandlerScope):
1560         * html/HTMLObjectElement.h:
1561         * html/HTMLObjectElement.idl:
1562         * html/HTMLOptGroupElement.idl:
1563         * html/HTMLOptionElement.idl:
1564         * html/HTMLParagraphElement.idl:
1565         * html/HTMLParamElement.idl:
1566         * html/HTMLPreElement.idl:
1567         * html/HTMLQuoteElement.idl:
1568         * html/HTMLScriptElement.idl:
1569         * html/HTMLSelectElement.idl:
1570         * html/HTMLStyleElement.idl:
1571         * html/HTMLTableCaptionElement.idl:
1572         * html/HTMLTableCellElement.idl:
1573         * html/HTMLTableColElement.idl:
1574         * html/HTMLTableElement.idl:
1575         * html/HTMLTableRowElement.idl:
1576         * html/HTMLTableSectionElement.idl:
1577         * html/HTMLTextAreaElement.idl:
1578         * html/HTMLTitleElement.idl:
1579         * html/HTMLUListElement.idl:
1580         * page/DOMWindow.idl:
1581
1582 2007-05-28  Zack Rusin  <zrusin@trolltech.com>
1583
1584         Reviewed by andersca
1585
1586         Adding Qt related constructor/casting operators
1587         to the AtomicString and updating the project
1588         file for new Qt settings api using those.
1589
1590         * WebCore.pro:
1591         * platform/AtomicString.h:
1592
1593 2007-05-27  Sam Weinig  <sam@webkit.org>
1594
1595         Qt and Gdk build fix.
1596
1597         * WebCore.pro:
1598
1599 2007-05-27  Sam Weinig  <sam@webkit.org>
1600
1601         Reviewed by Hyatt.
1602
1603         Patch for http://bugs.webkit.org/show_bug.cgi?id=13893
1604         Autogenerate the JS bindings for the HTMLObjectElement, 
1605         HTMLEmbedElement and HTMLAppletElement
1606
1607         * DerivedSources.make:
1608         * WebCore.xcodeproj/project.pbxproj:
1609         * bindings/js/JSHTMLAppletElementCustom.cpp: Added.
1610         (WebCore::JSHTMLAppletElement::customGetOwnPropertySlot):
1611         (WebCore::JSHTMLAppletElement::customPut):
1612         (WebCore::JSHTMLAppletElement::implementsCall):
1613         (WebCore::JSHTMLAppletElement::callAsFunction):
1614         (WebCore::JSHTMLAppletElement::canGetItemsForName):
1615         (WebCore::JSHTMLAppletElement::nameGetter):
1616         * bindings/js/JSHTMLElementWrapperFactory.cpp:
1617         * bindings/js/JSHTMLEmbedElementCustom.cpp: Added.
1618         (WebCore::JSHTMLEmbedElement::customGetOwnPropertySlot):
1619         (WebCore::JSHTMLEmbedElement::customPut):
1620         (WebCore::JSHTMLEmbedElement::implementsCall):
1621         (WebCore::JSHTMLEmbedElement::callAsFunction):
1622         (WebCore::JSHTMLEmbedElement::canGetItemsForName):
1623         (WebCore::JSHTMLEmbedElement::nameGetter):
1624         * bindings/js/JSHTMLObjectElementCustom.cpp: Added.
1625         (WebCore::JSHTMLObjectElement::customGetOwnPropertySlot):
1626         (WebCore::JSHTMLObjectElement::customPut):
1627         (WebCore::JSHTMLObjectElement::implementsCall):
1628         (WebCore::JSHTMLObjectElement::callAsFunction):
1629         (WebCore::JSHTMLObjectElement::canGetItemsForName):
1630         (WebCore::JSHTMLObjectElement::nameGetter):
1631         * bindings/js/kjs_html.cpp:
1632         (KJS::):
1633         (KJS::JSHTMLElement::toString):
1634         (KJS::JSHTMLElement::pushEventHandlerScope):
1635         (KJS::runtimeObjectGetter):
1636         (KJS::runtimeObjectPropertyGetter):
1637         (KJS::runtimeObjectCustomGetOwnPropertySlot):
1638         (KJS::runtimeObjectCustomPut):
1639         (KJS::runtimeObjectImplementsCall):
1640         (KJS::runtimeObjectCallAsFunction):
1641         * bindings/js/kjs_html.h:
1642         (KJS::JSHTMLElement::classInfo):
1643         * bindings/scripts/CodeGeneratorJS.pm: Add support for 
1644         CustomGetOwnPropertySlot, CustomPutFunction, CustomCall,
1645         and SVGCheckSecurityDocument properties.
1646         * html/HTMLAppletElement.idl:
1647         * html/HTMLEmbedElement.idl:
1648         * html/HTMLObjectElement.idl:
1649         * page/DOMWindow.idl: Uncomment constructors.
1650
1651 2007-05-27  Sam Weinig  <sam@webkit.org>
1652
1653         Reviewed by Oliver.
1654
1655         Gdk build fix.
1656
1657         * platform/graphics/Path.h:
1658
1659 2007-05-27  Sam Weinig  <sam@webkit.org>
1660
1661         Gdk build fix.  Forgot to update a few instances of notImplementedGdk() to notImplemented().
1662
1663         * page/gdk/EventHandlerGdk.cpp:
1664         (WebCore::EventHandler::passMousePressEventToScrollbar):
1665         * platform/gdk/EditorClientGdk.cpp:
1666         (WebCore::EditorClientGdk::ignoreWordInSpellDocument):
1667         (WebCore::EditorClientGdk::learnWord):
1668         (WebCore::EditorClientGdk::checkSpellingOfString):
1669         (WebCore::EditorClientGdk::checkGrammarOfString):
1670         (WebCore::EditorClientGdk::updateSpellingUIWithGrammarString):
1671         (WebCore::EditorClientGdk::updateSpellingUIWithMisspelledWord):
1672         (WebCore::EditorClientGdk::showSpellingUI):
1673         (WebCore::EditorClientGdk::spellingUIIsShowing):
1674         (WebCore::EditorClientGdk::getGuessesForWord):
1675         * platform/gdk/FrameGdk.cpp:
1676         (WebCore::Frame::dashboardRegionsChanged):
1677         * platform/gdk/PlatformScrollBarGdk.cpp:
1678         (PlatformScrollbar::paint):
1679         (PlatformScrollbar::updateThumbPosition):
1680         (PlatformScrollbar::updateThumbProportion):
1681         * platform/gdk/TemporaryLinkStubs.cpp:
1682         (Widget::setEnabled):
1683         (Widget::isEnabled):
1684         (Widget::removeFromParent):
1685         (Widget::paint):
1686         (Widget::setIsSelected):
1687         (Widget::invalidate):
1688         (Widget::invalidateRect):
1689
1690 2007-05-27  Alp Toker  <alp.toker@collabora.co.uk>
1691
1692         Reviewed by Sam and Oliver.
1693
1694         Implement PathCairo. This patch is based on changes in Mike Emmel's
1695         WebKit fork with some additional clean-ups and updates.
1696
1697         * platform/graphics/Path.h:
1698         * platform/graphics/cairo/CairoPath.h: Added.
1699         (CairoPath::CairoPath):
1700         (CairoPath::~CairoPath):
1701         * platform/graphics/cairo/GraphicsContextCairo.cpp:
1702         (WebCore::GraphicsContext::clip):
1703         * platform/graphics/cairo/PathCairo.cpp:
1704         (WebCore::Path::Path):
1705         (WebCore::Path::~Path):
1706         (WebCore::Path::operator=):
1707         (WebCore::Path::clear):
1708         (WebCore::Path::isEmpty):
1709         (WebCore::Path::translate):
1710         (WebCore::Path::moveTo):
1711         (WebCore::Path::addLineTo):
1712         (WebCore::Path::addRect):
1713         (WebCore::Path::addQuadCurveTo):
1714         (WebCore::Path::addBezierCurveTo):
1715         (WebCore::Path::addArc):
1716         (WebCore::Path::addArcTo):
1717         (WebCore::Path::addEllipse):
1718         (WebCore::Path::closeSubpath):
1719         (WebCore::Path::boundingRect):
1720         (WebCore::Path::contains):
1721         (WebCore::Path::apply):
1722         (WebCore::Path::transform):
1723         (WebCore::Path::debugString):
1724
1725 2007-05-27  Kevin Ollivier  <kevino@theolliviers.com>
1726
1727         Reviewed by Sam Weinig.
1728
1729         Consolidate all notImplemented() macro definitions into
1730         one header file for all platforms.
1731
1732         * loader/gdk/DocumentLoaderGdk.cpp:
1733         (WebCore::DocumentLoader::getResponseModifiedHeader):
1734         * loader/gdk/FrameLoaderClientGdk.cpp:
1735         (WebCore::FrameLoaderClientGdk::dispatchDidReceiveAuthenticationChallenge):
1736         (WebCore::FrameLoaderClientGdk::dispatchDidCancelAuthenticationChallenge):
1737         (WebCore::FrameLoaderClientGdk::dispatchWillSendRequest):
1738         (WebCore::FrameLoaderClientGdk::assignIdentifierToInitialRequest):
1739         (WebCore::FrameLoaderClientGdk::createPlugin):
1740         (WebCore::FrameLoaderClientGdk::createFrame):
1741         (WebCore::FrameLoaderClientGdk::redirectDataToPlugin):
1742         (WebCore::FrameLoaderClientGdk::createJavaAppletWidget):
1743         (WebCore::FrameLoaderClientGdk::objectContentType):
1744         (WebCore::FrameLoaderClientGdk::overrideMediaType):
1745         (WebCore::FrameLoaderClientGdk::windowObjectCleared):
1746         (WebCore::FrameLoaderClientGdk::hasWebView):
1747         (WebCore::FrameLoaderClientGdk::hasFrameView):
1748         (WebCore::FrameLoaderClientGdk::frameLoadCompleted):
1749         (WebCore::FrameLoaderClientGdk::saveViewStateToItem):
1750         (WebCore::FrameLoaderClientGdk::restoreViewState):
1751         (WebCore::FrameLoaderClientGdk::privateBrowsingEnabled):
1752         (WebCore::FrameLoaderClientGdk::makeDocumentView):
1753         (WebCore::FrameLoaderClientGdk::makeRepresentation):
1754         (WebCore::FrameLoaderClientGdk::forceLayout):
1755         (WebCore::FrameLoaderClientGdk::forceLayoutForNonHTML):
1756         (WebCore::FrameLoaderClientGdk::setCopiesOnScroll):
1757         (WebCore::FrameLoaderClientGdk::detachedFromParent1):
1758         (WebCore::FrameLoaderClientGdk::detachedFromParent2):
1759         (WebCore::FrameLoaderClientGdk::detachedFromParent3):
1760         (WebCore::FrameLoaderClientGdk::detachedFromParent4):
1761         (WebCore::FrameLoaderClientGdk::loadedFromCachedPage):
1762         (WebCore::FrameLoaderClientGdk::dispatchDidHandleOnloadEvents):
1763         (WebCore::FrameLoaderClientGdk::dispatchDidReceiveServerRedirectForProvisionalLoad):
1764         (WebCore::FrameLoaderClientGdk::dispatchDidCancelClientRedirect):
1765         (WebCore::FrameLoaderClientGdk::dispatchWillPerformClientRedirect):
1766         (WebCore::FrameLoaderClientGdk::dispatchDidChangeLocationWithinPage):
1767         (WebCore::FrameLoaderClientGdk::dispatchWillClose):
1768         (WebCore::FrameLoaderClientGdk::dispatchDidReceiveIcon):
1769         (WebCore::FrameLoaderClientGdk::dispatchDidStartProvisionalLoad):
1770         (WebCore::FrameLoaderClientGdk::dispatchDidReceiveTitle):
1771         (WebCore::FrameLoaderClientGdk::dispatchDidCommitLoad):
1772         (WebCore::FrameLoaderClientGdk::dispatchDidFinishDocumentLoad):
1773         (WebCore::FrameLoaderClientGdk::dispatchDidFirstLayout):
1774         (WebCore::FrameLoaderClientGdk::dispatchShow):
1775         (WebCore::FrameLoaderClientGdk::cancelPolicyCheck):
1776         (WebCore::FrameLoaderClientGdk::dispatchDidLoadMainResource):
1777         (WebCore::FrameLoaderClientGdk::revertToProvisionalState):
1778         (WebCore::FrameLoaderClientGdk::clearUnarchivingState):
1779         (WebCore::FrameLoaderClientGdk::willChangeTitle):
1780         (WebCore::FrameLoaderClientGdk::finishedLoading):
1781         (WebCore::FrameLoaderClientGdk::finalSetupForReplace):
1782         (WebCore::FrameLoaderClientGdk::setDefersLoading):
1783         (WebCore::FrameLoaderClientGdk::isArchiveLoadPending):
1784         (WebCore::FrameLoaderClientGdk::cancelPendingArchiveLoad):
1785         (WebCore::FrameLoaderClientGdk::clearArchivedResources):
1786         (WebCore::FrameLoaderClientGdk::canHandleRequest):
1787         (WebCore::FrameLoaderClientGdk::canShowMIMEType):
1788         (WebCore::FrameLoaderClientGdk::representationExistsForURLScheme):
1789         (WebCore::FrameLoaderClientGdk::generatedMIMETypeForURLScheme):
1790         (WebCore::FrameLoaderClientGdk::provisionalLoadStarted):
1791         (WebCore::FrameLoaderClientGdk::didFinishLoad):
1792         (WebCore::FrameLoaderClientGdk::prepareForDataSourceReplacement):
1793         (WebCore::FrameLoaderClientGdk::setTitle):
1794         (WebCore::FrameLoaderClientGdk::setDocumentViewFromCachedPage):
1795         (WebCore::FrameLoaderClientGdk::dispatchDidReceiveContentLength):
1796         (WebCore::FrameLoaderClientGdk::dispatchDidFinishLoading):
1797         (WebCore::FrameLoaderClientGdk::dispatchDidFailLoading):
1798         (WebCore::FrameLoaderClientGdk::dispatchDidLoadResourceFromMemoryCache):
1799         (WebCore::FrameLoaderClientGdk::dispatchDidFailProvisionalLoad):
1800         (WebCore::FrameLoaderClientGdk::dispatchDidFailLoad):
1801         (WebCore::FrameLoaderClientGdk::download):
1802         (WebCore::FrameLoaderClientGdk::cancelledError):
1803         (WebCore::FrameLoaderClientGdk::blockedError):
1804         (WebCore::FrameLoaderClientGdk::cannotShowURLError):
1805         (WebCore::FrameLoaderClientGdk::interruptForPolicyChangeError):
1806         (WebCore::FrameLoaderClientGdk::cannotShowMIMETypeError):
1807         (WebCore::FrameLoaderClientGdk::fileDoesNotExistError):
1808         (WebCore::FrameLoaderClientGdk::shouldFallBack):
1809         (WebCore::FrameLoaderClientGdk::willUseArchive):
1810         (WebCore::FrameLoaderClientGdk::saveDocumentViewToCachedPage):
1811         (WebCore::FrameLoaderClientGdk::canCachePage):
1812         (WebCore::FrameLoaderClientGdk::dispatchCreatePage):
1813         (WebCore::FrameLoaderClientGdk::dispatchUnableToImplementPolicy):
1814         (WebCore::FrameLoaderClientGdk::setMainDocumentError):
1815         (WebCore::FrameLoaderClientGdk::startDownload):
1816         (WebCore::FrameLoaderClientGdk::updateGlobalHistoryForStandardLoad):
1817         (WebCore::FrameLoaderClientGdk::updateGlobalHistoryForReload):
1818         * loader/qt/DocumentLoaderQt.cpp:
1819         * page/gdk/ContextMenuClientGdk.cpp:
1820         (WebCore::ContextMenuClientGdk::contextMenuDestroyed):
1821         (WebCore::ContextMenuClientGdk::getCustomMenuFromDefaultItems):
1822         (WebCore::ContextMenuClientGdk::contextMenuItemSelected):
1823         (WebCore::ContextMenuClientGdk::downloadURL):
1824         (WebCore::ContextMenuClientGdk::copyImageToClipboard):
1825         (WebCore::ContextMenuClientGdk::searchWithGoogle):
1826         (WebCore::ContextMenuClientGdk::lookUpInDictionary):
1827         (WebCore::ContextMenuClientGdk::speak):
1828         (WebCore::ContextMenuClientGdk::stopSpeaking):
1829         * page/gdk/EventHandlerGdk.cpp:
1830         (WebCore::EventHandler::passMouseDownEventToWidget):
1831         (WebCore::EventHandler::eventActivatedView):
1832         (WebCore::EventHandler::passSubframeEventToSubframe):
1833         (WebCore::EventHandler::passWheelEventToWidget):
1834         (WebCore::EventHandler::createDraggingClipboard):
1835         * page/qt/EventHandlerQt.cpp:
1836         * page/qt/FrameQt.cpp:
1837         * platform/NotImplemented.h: Added.
1838         * platform/gdk/CursorGdk.cpp:
1839         (WebCore::Cursor::Cursor):
1840         * platform/gdk/EditorClientGdk.cpp:
1841         (WebCore::EditorClientGdk::shouldDeleteRange):
1842         (WebCore::EditorClientGdk::isContinuousSpellCheckingEnabled):
1843         (WebCore::EditorClientGdk::isGrammarCheckingEnabled):
1844         (WebCore::EditorClientGdk::spellCheckerDocumentTag):
1845         (WebCore::EditorClientGdk::shouldBeginEditing):
1846         (WebCore::EditorClientGdk::shouldEndEditing):
1847         (WebCore::EditorClientGdk::shouldInsertText):
1848         (WebCore::EditorClientGdk::shouldChangeSelectedRange):
1849         (WebCore::EditorClientGdk::shouldApplyStyle):
1850         (WebCore::EditorClientGdk::didBeginEditing):
1851         (WebCore::EditorClientGdk::respondToChangedContents):
1852         (WebCore::EditorClientGdk::respondToChangedSelection):
1853         (WebCore::EditorClientGdk::didEndEditing):
1854         (WebCore::EditorClientGdk::didWriteSelectionToPasteboard):
1855         (WebCore::EditorClientGdk::didSetSelectionTypesForPasteboard):
1856         (WebCore::EditorClientGdk::selectWordBeforeMenuEvent):
1857         (WebCore::EditorClientGdk::isEditable):
1858         (WebCore::EditorClientGdk::registerCommandForUndo):
1859         (WebCore::EditorClientGdk::registerCommandForRedo):
1860         (WebCore::EditorClientGdk::clearUndoRedoOperations):
1861         (WebCore::EditorClientGdk::canUndo):
1862         (WebCore::EditorClientGdk::canRedo):
1863         (WebCore::EditorClientGdk::undo):
1864         (WebCore::EditorClientGdk::redo):
1865         (WebCore::EditorClientGdk::shouldInsertNode):
1866         (WebCore::EditorClientGdk::pageDestroyed):
1867         (WebCore::EditorClientGdk::smartInsertDeleteEnabled):
1868         (WebCore::EditorClientGdk::toggleContinuousSpellChecking):
1869         (WebCore::EditorClientGdk::handleInputMethodKeypress):
1870         (WebCore::EditorClientGdk::textFieldDidBeginEditing):
1871         (WebCore::EditorClientGdk::textFieldDidEndEditing):
1872         (WebCore::EditorClientGdk::textDidChangeInTextField):
1873         (WebCore::EditorClientGdk::doTextFieldCommandFromEvent):
1874         (WebCore::EditorClientGdk::textWillBeDeletedInTextField):
1875         (WebCore::EditorClientGdk::textDidChangeInTextArea):
1876         * platform/gdk/FrameGdk.cpp:
1877         (WebCore::Frame::print):
1878         (WebCore::Frame::issueTransposeCommand):
1879         (WebCore::Frame::cleanupPlatformScriptObjects):
1880         (WebCore::Frame::dragImageForSelection):
1881         * platform/gdk/NotImplementedGdk.h: Removed.
1882         * platform/gdk/PopupMenuGdk.cpp:
1883         (WebCore::PopupMenu::PopupMenu):
1884         (WebCore::PopupMenu::~PopupMenu):
1885         (WebCore::PopupMenu::show):
1886         (WebCore::PopupMenu::hide):
1887         (WebCore::PopupMenu::updateFromElement):
1888         * platform/gdk/RenderThemeGdk.cpp:
1889         (WebCore::RenderThemeGdk::setCheckboxSize):
1890         (WebCore::RenderThemeGdk::setRadioSize):
1891         (WebCore::RenderThemeGdk::adjustTextFieldStyle):
1892         * platform/gdk/ScreenGdk.cpp:
1893         (WebCore::screenDepthPerComponent):
1894         (WebCore::screenIsMonochrome):
1895         (WebCore::screenRect):
1896         (WebCore::screenAvailableRect):
1897         * platform/gdk/ScrollViewGdk.cpp:
1898         (WebCore::ScrollView::update):
1899         (WebCore::ScrollView::addChild):
1900         (WebCore::ScrollView::removeChild):
1901         (WebCore::ScrollView::scrollRectIntoViewRecursively):
1902         (WebCore::ScrollView::inWindow):
1903         (WebCore::ScrollView::wheelEvent):
1904         (WebCore::ScrollView::updateScrollbars):
1905         (WebCore::ScrollView::updateScrollInfo):
1906         (WebCore::ScrollView::windowToContents):
1907         (WebCore::ScrollView::contentsToWindow):
1908         (WebCore::ScrollView::scrollbarUnderMouse):
1909         * platform/gdk/TemporaryLinkStubs.cpp:
1910         (FrameView::updateBorder):
1911         (WebCore::findNextWordFromIndex):
1912         (WebCore::currentTextBreakLocaleID):
1913         (ChromeClientGdk::chromeDestroyed):
1914         (ChromeClientGdk::windowRect):
1915         (ChromeClientGdk::setWindowRect):
1916         (ChromeClientGdk::pageRect):
1917         (ChromeClientGdk::scaleFactor):
1918         (ChromeClientGdk::focus):
1919         (ChromeClientGdk::unfocus):
1920         (ChromeClientGdk::createWindow):
1921         (ChromeClientGdk::createModalDialog):
1922         (ChromeClientGdk::show):
1923         (ChromeClientGdk::canRunModal):
1924         (ChromeClientGdk::runModal):
1925         (ChromeClientGdk::setToolbarsVisible):
1926         (ChromeClientGdk::toolbarsVisible):
1927         (ChromeClientGdk::setStatusbarVisible):
1928         (ChromeClientGdk::statusbarVisible):
1929         (ChromeClientGdk::setScrollbarsVisible):
1930         (ChromeClientGdk::scrollbarsVisible):
1931         (ChromeClientGdk::setMenubarVisible):
1932         (ChromeClientGdk::menubarVisible):
1933         (ChromeClientGdk::setResizable):
1934         (ChromeClientGdk::closeWindowSoon):
1935         (ChromeClientGdk::canTakeFocus):
1936         (ChromeClientGdk::takeFocus):
1937         (ChromeClientGdk::canRunBeforeUnloadConfirmPanel):
1938         (ChromeClientGdk::addMessageToConsole):
1939         (ChromeClientGdk::runBeforeUnloadConfirmPanel):
1940         (ChromeClientGdk::runJavaScriptAlert):
1941         (ChromeClientGdk::runJavaScriptConfirm):
1942         (ChromeClientGdk::runJavaScriptPrompt):
1943         (ChromeClientGdk::setStatusbarText):
1944         (ChromeClientGdk::shouldInterruptJavaScript):
1945         (ChromeClientGdk::tabsToLinks):
1946         (ChromeClientGdk::windowResizerRect):
1947         (ChromeClientGdk::addToDirtyRegion):
1948         (ChromeClientGdk::scrollBackingStore):
1949         (ChromeClientGdk::updateBackingStore):
1950         (PlugInInfoStore::createPluginInfoForPluginAtIndex):
1951         (PlugInInfoStore::pluginCount):
1952         (WebCore::PlugInInfoStore::supportsMIMEType):
1953         (WebCore::refreshPlugins):
1954         (SearchPopupMenu::saveRecentSearches):
1955         (SearchPopupMenu::loadRecentSearches):
1956         (SearchPopupMenu::SearchPopupMenu):
1957         (SearchPopupMenu::enabled):
1958         (FileChooser::FileChooser):
1959         (FileChooser::~FileChooser):
1960         (FileChooser::openFileChooser):
1961         (FileChooser::basenameForWidth):
1962         (ResourceHandle::willLoadFromCache):
1963         (ResourceHandle::loadsBlocked):
1964         (ResourceHandle::loadResourceSynchronously):
1965         (Icon::Icon):
1966         (Icon::~Icon):
1967         (Icon::newIconForFile):
1968         (Icon::paint):
1969         (Font::selectionRectForComplexText):
1970         (Font::drawComplexText):
1971         (Font::floatWidthForComplexText):
1972         (Font::offsetForPositionForComplexText):
1973         (CachedPage::close):
1974         (Editor::newGeneralClipboard):
1975         (Pasteboard::generalPasteboard):
1976         (Pasteboard::writeSelection):
1977         (Pasteboard::writeURL):
1978         (Pasteboard::writeImage):
1979         (Pasteboard::clear):
1980         (Pasteboard::canSmartReplace):
1981         (Pasteboard::documentFragment):
1982         (Pasteboard::plainText):
1983         (Pasteboard::Pasteboard):
1984         (Pasteboard::~Pasteboard):
1985         (ContextMenu::ContextMenu):
1986         (ContextMenu::~ContextMenu):
1987         (ContextMenu::appendItem):
1988         (ContextMenuItem::ContextMenuItem):
1989         (ContextMenuItem::~ContextMenuItem):
1990         (ContextMenuItem::releasePlatformDescription):
1991         (ContextMenuItem::type):
1992         (ContextMenuItem::setType):
1993         (ContextMenuItem::action):
1994         (ContextMenuItem::setAction):
1995         (ContextMenuItem::title):
1996         (ContextMenuItem::setTitle):
1997         (ContextMenuItem::platformSubMenu):
1998         (ContextMenuItem::setSubMenu):
1999         (ContextMenuItem::setChecked):
2000         (ContextMenuItem::setEnabled):
2001         (WebCore::supportedKeySizes):
2002         (WebCore::systemBeep):
2003         (WebCore::userIdleTime):
2004         * platform/graphics/cairo/GraphicsContextCairo.cpp:
2005         * platform/graphics/cairo/ImageBufferCairo.cpp:
2006         * platform/graphics/cairo/PathCairo.cpp:
2007         * platform/graphics/gdk/ImageGdk.cpp:
2008         * platform/graphics/qt/GraphicsContextQt.cpp:
2009         * platform/graphics/qt/IconQt.cpp:
2010         * platform/graphics/qt/ImageQt.cpp:
2011         * platform/network/gdk/ResourceHandleCurl.cpp:
2012         (WebCore::ResourceHandle::setDefersLoading):
2013         * platform/network/gdk/ResourceHandleManager.cpp:
2014         (WebCore::ResourceHandleManager::setupPUT):
2015         (WebCore::ResourceHandleManager::setupPOST):
2016         * platform/network/qt/ResourceHandleQt.cpp:
2017         * platform/qt/ClipboardQt.cpp:
2018         * platform/qt/CursorQt.cpp:
2019         * platform/qt/DragDataQt.cpp:
2020         * platform/qt/FileChooserQt.cpp:
2021         * platform/qt/MimeTypeRegistryQt.cpp:
2022         * platform/qt/PasteboardQt.cpp:
2023         * platform/qt/PlatformScrollBarQt.cpp:
2024         * platform/qt/PopupMenuQt.cpp:
2025         * platform/qt/ScrollViewQt.cpp:
2026         * platform/qt/TemporaryLinkStubs.cpp:
2027         * platform/qt/TextBoundaries.cpp:
2028         * platform/qt/WidgetQt.cpp:
2029         * platform/win/FontWin.cpp:
2030         * platform/win/TemporaryLinkStubs.cpp:
2031         * platform/wx/ClipboardWx.cpp:
2032         * platform/wx/FontWx.cpp:
2033         * platform/wx/ScrollViewWx.cpp:
2034         * platform/wx/SharedTimerWx.cpp:
2035         * platform/wx/TemporaryLinkStubs.cpp:
2036
2037 2007-05-27  Rob Buis  <buis@kde.org>
2038
2039         Reviewed by Oliver.
2040
2041         http://bugs.webkit.org/show_bug.cgi?id=13828
2042         x/y values on rootmost <svg> elements should be ignored
2043
2044         Make sure that root-most <svg> elements do not take into account x/y.
2045
2046         * ksvg2/svg/SVGSVGElement.cpp:
2047         (WebCore::SVGSVGElement::viewport):
2048         (WebCore::SVGSVGElement::getCTM):
2049         (WebCore::SVGSVGElement::getScreenCTM):
2050         * rendering/RenderSVGContainer.cpp:
2051         (WebCore::RenderSVGContainer::calcViewport):
2052
2053 2007-05-26  David Hyatt  <hyatt@apple.com>
2054
2055         Fix for radar bug 5219562, PNG isn't displayed on SVG test suite.
2056         Improve <object> error handling so that it recovers properly when
2057         <td> is used inside it.
2058
2059         Reviewed by olliej
2060
2061         Added fast/invalid/td-inside-object.html
2062
2063         * html/HTMLObjectElement.h:
2064         (WebCore::HTMLObjectElement::tagPriority):
2065         * html/HTMLParser.cpp:
2066         (WebCore::HTMLParser::handleError):
2067         * html/HTMLParserErrorCodes.cpp:
2068         (WebCore::htmlParserErrorMessageTemplate):
2069         * html/HTMLParserErrorCodes.h:
2070
2071 2007-05-26  David Hyatt  <hyatt@apple.com>
2072
2073         Don't compare the "isset" variables in background layers, since they
2074         lead us to turn off the Aqua look incorrectly, even when the background
2075         matches the default.
2076
2077         Reviewed by olliej
2078
2079         * rendering/RenderStyle.cpp:
2080         (WebCore::BackgroundLayer::operator==):
2081
2082 2007-05-26  David Hyatt  <hyatt@apple.com>
2083
2084         Improve the </p> -> <p></p> error message to not spew two errors.
2085         Fix a bug where errors reported inside document.write didn't get
2086         reported as such because of a mistake in the notation of SegmentedString.
2087
2088         Reviewed by aroben
2089
2090         * html/HTMLParser.cpp:
2091         (WebCore::HTMLParser::processCloseTag):
2092         * platform/SegmentedString.h:
2093         (WebCore::SegmentedSubstring::clear):
2094
2095 2007-05-26  David Hyatt  <hyatt@apple.com>
2096
2097         Fix for bug 13887, percentage height block not sized correctly inside
2098         positioned percentage height containing block.
2099
2100         Reviewed by mitz
2101
2102         fast/block/positioning/complex-percentage-height.html
2103
2104         * rendering/RenderBox.cpp:
2105         (WebCore::RenderBox::calcPercentageHeight):
2106
2107 2007-05-26  Mitz Pettel  <mitz@webkit.org>
2108
2109         Reviewed by Oliver Hunt.
2110
2111         - finish fixing http://bugs.webkit.org/show_bug.cgi?id=13871
2112           Box shadow should not apply to Aqua-themed controls
2113
2114         Covered by fast/forms/box-shadow-override.html
2115
2116         I forgot to include adjustSliderThumbStyle in the previous patch and the
2117         test didn't detect it because of a bug introduced in r21739.
2118
2119         * rendering/RenderThemeMac.h:
2120         * rendering/RenderThemeMac.mm:
2121         (WebCore::RenderThemeMac::adjustSliderThumbStyle):
2122
2123 2007-05-26  Mitz Pettel  <mitz@webkit.org>
2124
2125         Reviewed by Hyatt.
2126
2127         - fix http://bugs.webkit.org/show_bug.cgi?id=13876
2128           Box-Shadow disappears if shadow doesn't fit in the window size
2129
2130         Tests: fast/repaint/box-shadow-h.html
2131                fast/repaint/box-shadow-v.html
2132
2133         * rendering/RenderTable.cpp:
2134         (WebCore::RenderTable::layout):
2135
2136 2007-05-26  Alexey Proskuryakov  <ap@webkit.org>
2137
2138         Reviewed by Darin.
2139
2140         http://bugs.webkit.org/show_bug.cgi?id=13605
2141         REGRESSION: Browser crashes when switching Kotoeri input modes
2142
2143         The problem could no longer be reproduced with Kotoeri thanks to
2144         a fix in <http://trac.webkit.org/projects/webkit/changeset/21728>,
2145         but we still need to protect from invalid ranges passed from
2146         input methods.
2147
2148         Test: editing/input/replace-invalid-range.html
2149
2150         * page/mac/WebCoreFrameBridge.mm:
2151         (-[WebCoreFrameBridge selectNSRange:]): Added a null check.
2152
2153 2007-05-26  Darin Adler  <darin@apple.com>
2154
2155         * platform/network/mac/ResourceResponseMac.mm:
2156         (WebCore::ResourceResponse::doUpdateResourceResponse):
2157         Alexey pointed out that I was wrong about object lifetime, so
2158         rolling this change out.
2159
2160 2007-05-26  Darin Adler  <darin@apple.com>
2161
2162         Reviewed by Anders.
2163
2164         * platform/network/mac/ResourceResponseMac.mm:
2165         (WebCore::ResourceResponse::doUpdateResourceResponse):
2166         Fixed code where a temporary String is used after destroyed.
2167
2168 2007-05-26  Mitz Pettel  <mitz@webkit.org>
2169
2170         Reviewed by Darin.
2171
2172         - http://bugs.webkit.org/show_bug.cgi?id=13842
2173           Simplify Color::light() and Color::dark()
2174
2175         Not testable.
2176
2177         * platform/graphics/Color.cpp:
2178         (WebCore::Color::light):
2179         (WebCore::Color::dark):
2180
2181 2007-05-26  Mitz Pettel  <mitz@webkit.org>
2182
2183         Reviewed by Darin.
2184
2185         - fix http://bugs.webkit.org/show_bug.cgi?id=13870
2186           RenderFrameSet should only allow frame and frameset children
2187
2188         Covered by fast/frames/inline-object-inside-frameset.html
2189
2190         * rendering/RenderFrame.h:
2191         (WebCore::RenderFrame::isFrame): Added.
2192         * rendering/RenderFrameSet.cpp:
2193         (WebCore::RenderFrameSet::paint): Removed check for inline objects that is
2194         no longer needed.
2195         (WebCore::RenderFrameSet::isChildAllowed): Added. Allows the child only
2196         if it is a frame or another frameset.
2197         * rendering/RenderFrameSet.h:
2198         * rendering/RenderObject.h:
2199         (WebCore::RenderObject::isFrame): Added.
2200
2201 2007-05-26  Mitz Pettel  <mitz@webkit.org>
2202
2203         Reviewed by Darin.
2204
2205         - http://bugs.webkit.org/show_bug.cgi?id=13871
2206           Box shadow should not apply to Aqua-themed controls
2207
2208         Test: fast/forms/box-shadow-override.html
2209
2210         * rendering/RenderTheme.cpp:
2211         (WebCore::RenderTheme::adjustCheckboxStyle):
2212         (WebCore::RenderTheme::adjustRadioStyle):
2213         * rendering/RenderThemeMac.h:
2214         * rendering/RenderThemeMac.mm:
2215         (WebCore::RenderThemeMac::adjustButtonStyle):
2216         (WebCore::RenderThemeMac::adjustMenuListStyle):
2217         (WebCore::RenderThemeMac::adjustSliderTrackStyle):
2218         (WebCore::RenderThemeMac::adjustSearchFieldStyle):
2219         (WebCore::RenderThemeMac::adjustSearchFieldCancelButtonStyle):
2220         (WebCore::RenderThemeMac::adjustSearchFieldDecorationStyle):
2221         (WebCore::RenderThemeMac::adjustSearchFieldResultsDecorationStyle):
2222         (WebCore::RenderThemeMac::adjustSearchFieldResultsButtonStyle):
2223
2224 2007-05-26  Holger Freyther  <zecke@selfish.org>
2225
2226         Reviewed by Anders.
2227
2228         * platform/gdk/FrameGdk.cpp: Catch up to make it compile
2229         (WebCore::FrameGdk::FrameGdk): The Settings is now owned by the Page
2230
2231 2007-05-25  Sam Weinig  <sam@webkit.org>
2232
2233         Reviewed by Oliver of the Hunt.
2234
2235         Fixed <rdar://problem/5230247> at least 43 xhtml tests fail in 
2236         Leopard because they are being interpreted as html
2237
2238         Adds a work around for <rdar://problem/5230154> which explicitly
2239         sets local .xhtml files to have the MIME type application/xhtml+xml.
2240
2241         * platform/network/mac/ResourceResponseMac.mm:
2242         (WebCore::ResourceResponse::doUpdateResourceResponse):
2243
2244 2007-05-25  Geoffrey Garen  <ggaren@apple.com>
2245
2246         Reviewed by Darin Adler.
2247
2248         Fixed <rdar://problem/5055182> The page cache has no global cap.
2249         
2250         Beefed up the PageCache class to track which HistoryItems are 
2251         cached, and decide how to evict old HistoryItems as new ones are
2252         added.
2253
2254         * history/BackForwardList.cpp: Removed support for managing the page cache
2255         through the BackForwardList since this is deprecated in Mac's 
2256         WebBackForwardList, and doesn't exist on other platforms.
2257         
2258         Added a Page* back pointer so that Mac WebBackForwardList can still support 
2259         its deprecated API, using the new hotness. This isn't a big burden, since 
2260         Page is responsible for calling BackForwardList::close upon destruction, 
2261         anyway.
2262
2263         * history/HistoryItem.cpp: Replaced CachedPage* with boolean that tells
2264         you whether you're in the page cache. This prevents us from having more
2265         than one persistent repository for cached pages.
2266
2267         * history/PageCache.cpp: If you're playing along at home, this code is 
2268         the reason for the patch.
2269
2270         * loader/FrameLoader.cpp: If you're playing along at home, the minuses in
2271         this file are the reason for the patch.
2272         
2273         Replaced call to FrameLoaderClient::loadedFromCachedPage with its one-line
2274         implementation because WebCore calling itself through WebKit is uncivilized.
2275
2276         * page/Settings.cpp: Added support for removing a Page's HistoryItems from
2277         the page cache.
2278
2279 2007-05-25  Mitz Pettel  <mitz@webkit.org>
2280
2281         Reviewed by Darin.
2282
2283         - fix http://bugs.webkit.org/show_bug.cgi?id=13869
2284           Many leaks seen on buildbot after r21735
2285
2286         - fix another regression from r21739: ::-webkit-slider-thumb style not
2287           applied.
2288
2289         Test: fast/forms/slider-thumb-stylability.html
2290
2291         * rendering/RenderSlider.cpp:
2292         (WebCore::RenderSlider::setStyle):
2293         (WebCore::RenderSlider::createThumbStyle):
2294
2295 2007-05-25  Justin Garcia  <justin.garcia@apple.com>
2296
2297         Reviewed by Harrison.
2298
2299         <rdar://problem/5228141> 
2300         REGRESSION: Can't apply style to selection that ends after an image
2301
2302         * editing/ApplyStyleCommand.cpp:
2303         (WebCore::ApplyStyleCommand::applyInlineStyle):
2304         Use range compliant equivalents when creating the Range
2305         used to compute pastEndNode(), otherwise Range's constructor
2306         ASSERTs and pastEndNode() returns null. Added a testcase.
2307         If the incoming Range is collapsed at [br, 0], callers want
2308         the style to be applied to the br, so expand the Range to include
2309         it.  We got away without expanding before because pastEndNode
2310         of a Range from [br, 0] to [br, 0] is the node after the br.
2311         Using range compliant equivalents changed that. There's already
2312         test coverage for this change.
2313         Changed while loop termination for finding the end of a run 
2314         so that we don't process pastEnd.  end.node() may now be 
2315         non-atomic and we'd blow past it. There's already test
2316         coverage for this change.
2317
2318 2007-05-25  Beth Dakin  <bdakin@apple.com>
2319
2320         Rubber stamped by Hyatt
2321
2322         Adding an ASSERT for good measure.
2323
2324         * page/FrameView.cpp:
2325         (WebCore::FrameView::layout):
2326
2327 2007-05-25  Kevin McCullough  <kmccullough@apple.com>
2328  
2329         Reviewed by Geoff.
2330
2331         - <rdar://problem/5183523> REGRESSION: Excel: Worksheet tabs in spreadsheet saved as web page don't work 
2332         - Change load to check the URL as well as the referrer since it is possilbe to have a referrer which limits a load even thought the URL would allow it.  There is a bug about how we need to re-evaluate the whole load architecture: <rdar://problem/5227992> Rethink canLoad() to have a consistent and comprehensive architecture.
2333
2334         * loader/FrameLoader.cpp:
2335         (WebCore::FrameLoader::loadSubframe):
2336         (WebCore::FrameLoader::load):
2337         (WebCore::FrameLoader::canLoad):
2338         * loader/FrameLoader.h:
2339
2340 2007-05-25  Anders Carlsson  <andersca@apple.com>
2341
2342         Reviewed by Brady.
2343
2344         <rdar://problem/5209536>
2345         http://bugs.webkit.org/show_bug.cgi?id=13757
2346         REGRESSION: Leaks seen on buildbot after r21497.
2347         
2348         Fix multipart data loading so it works like Tiger Safari. When one part of a multipart connection has been loaded,
2349         move the subresource loader from the subresource loaders set and into a special multipart subresource loader set. This set 
2350         is not considered when asking a document loader if it's currently loading. 
2351                 
2352         * loader/DocumentLoader.cpp:
2353         (WebCore::DocumentLoader::stopLoading):
2354         Always stop the multipart subresource loaders here.
2355         
2356         (WebCore::DocumentLoader::subresourceLoaderFinishedLoadingOnePart):
2357         New function that moves the loader from m_subresourceLoaders to m_multipartSubresourceLoaders and updates the document loader's state.
2358         
2359         * loader/ProgressTracker.cpp:
2360         (WebCore::ProgressTracker::incrementProgress):
2361         If a progress item already exists, reuse it. This can happen in some rare circumstances when dealing with multipart data.
2362         
2363         * loader/SubresourceLoader.cpp:
2364         (WebCore::SubresourceLoader::didReceiveResponse):
2365         Call subresourceLoaderFinishedLoadingOnePart if the response is multipart.
2366
2367 2007-05-25  Patti Hoa  <patti@apple.com>
2368
2369         Reviewed by Tim Hatcher.
2370
2371         <rdar://problem/4918397> Exception raise inspecting note contents in the background
2372         
2373         * bridge/mac/WebCoreAXObject.mm:
2374         (-[WebCoreAXObject accessibilityDescription]):
2375         Only allow asking the attachmentView for description if attachmentView supports this description attribute
2376
2377 2007-05-25  Beth Dakin  <bdakin@apple.com>
2378
2379         Reviewed by Oliver and Hyatt.
2380
2381         Fix for <rdar://problem/5228363> REGRESSION: In Mail, attempting to 
2382         create a To Do results in a crash
2383
2384         This regressed with r21635. Now that -boundingBox updates layout if 
2385         it is needed, we infinitely recurse when Mail draws a custom 
2386         highlight. The fix is to put a guard around laying out the render 
2387         tree.
2388
2389         * page/FrameView.cpp:
2390         (WebCore::FrameViewPrivate::reset):
2391         (WebCore::FrameView::layout):
2392
2393 2007-05-25  Patti Hoa <patti@apple.com>
2394
2395         Reviewed by John Sullivan.
2396         
2397         <rdar://problem/5221986> selection in web areas doesn't seem to be working for text navigation
2398         
2399         * bridge/mac/WebCoreAXObject.mm:
2400         (-[WebCoreAXObject accessibilityIsAttributeSettable:]):
2401         Fixed up incorrect string comparison for AXSelectedTextMarkerRange ax attribute so 
2402         this attribute can actually announce its settability. 
2403
2404 2007-05-25  Darin Adler  <darin@apple.com>
2405
2406         Reviewed by Alice.
2407
2408         - fix <rdar://problem/5228048> REGRESSION: In a new Mail message, the caret isn't
2409           immediately inserted when tabbing into or clicking in the message body
2410
2411         This latent problem was uncovered by <http://trac.webkit.org/projects/webkit/changeset/21476>,
2412         which removed some code that did extra work whenever setCaretVisible made the caret visible.
2413
2414         * page/Frame.cpp: (WebCore::Frame::selectionLayoutChanged): Call invalidateCaretRect
2415         when turning the caret on. All other call sites that touched m_caretPaint were doing
2416         this, but this was not.
2417
2418 2007-05-25  Darin Adler  <darin@apple.com>
2419
2420         Reviewed by Harrison.
2421
2422         * DerivedSources.make: Tweaked spelling.
2423
2424 2007-05-25  Mitz Pettel  <mitz@webkit.org>
2425
2426         Reviewed by Darin.
2427
2428         - fix http://bugs.webkit.org/show_bug.cgi?id=13872
2429           REGRESSION: An empty search field can have a cancel button
2430
2431         Test: fast/forms/search-cancel-button-style-sharing.html
2432
2433         * rendering/RenderTextControl.cpp:
2434         (WebCore::RenderTextControl::createCancelButtonStyle): Prevented sharing of
2435         the cancel button style between search fields that share style, because
2436         each search field mutates the style to show and hide the cancel button.
2437
2438 2007-05-25  David Harrison  <harrison@apple.com>
2439
2440         Reviewed by Kevin and Geoff.
2441
2442         * DerivedSources.make:
2443         Add an inclusion guard for CSSGrammar.h and XPathGrammar.h, because older versions of bison do not
2444         
2445         * css/maketokenizer:
2446         Unconditionally define the flex basic types that are not part of newer versions of flex. Was
2447         only needed on Linux. Now needed on Mac OS 10.5, and is OK to do on 10.4.9.
2448
2449 2007-05-25  Geoffrey Garen  <ggaren@apple.com>
2450
2451         Reviewed by Darin Adler.
2452         
2453         Moved JavaScriptCore-related pending public API to public API.
2454
2455         Moved -JSObject
2456
2457         * bindings/objc/WebScriptObjectPendingPublic.h: from here
2458         * bindings/objc/WebScriptObject.h: to here
2459         * bindings/objc/WebScriptObject.mm: and out of its temporary category
2460
2461 2007-05-25  Mitz Pettel  <mitz@webkit.org>
2462
2463         Reviewed by Darin.
2464
2465         - fix http://bugs.webkit.org/show_bug.cgi?id=13767
2466           REGRESSION: Multipart image documents are garbled
2467
2468         Test: http/tests/multipart/invalid-image-data-standalone.html
2469
2470         * loader/DocumentLoader.cpp:
2471         (WebCore::DocumentLoader::isLoadingMultipartContent): Added.
2472         * loader/DocumentLoader.h:
2473         * loader/ImageDocument.cpp:
2474         (WebCore::ImageTokenizer::finish): If the image is multipart, make a copy
2475         of the current part instead of using the resource data, which is going to be
2476         overwritten by the next part.
2477         * loader/MainResourceLoader.h:
2478         (WebCore::MainResourceLoader::isLoadingMultipartContent): Added.
2479
2480 2007-05-25  Anders Carlsson  <andersca@apple.com>
2481
2482         Fix no-svg build.
2483         
2484         * bindings/js/kjs_html.cpp:
2485         (KJS::HTMLElementFunction::callAsFunction):
2486
2487 2007-05-25  Anders Carlsson  <andersca@apple.com>
2488
2489         Reviewed by Mitz.
2490
2491         <rdar://problem/5226788> After resizing the window larger than the image, hovering over the image still shows magnify glass
2492         
2493         One part of the bug was already fixed by my previous commit. This fixes the case where the window is sized so the image fit
2494         after it has been zoomed in.
2495         
2496         * loader/ImageDocument.cpp:
2497         (WebCore::ImageDocument::windowSizeChanged):
2498
2499 2007-05-25  John Sullivan  <sullivan@apple.com>
2500
2501         Reviewed by Anders and Tim
2502
2503         - WebCore change for: 
2504           <rdar://problem/5226000> REGRESSION: In Gmail and Mail, a hang occurs when attempting to grammar/spellcheck a word in a reply 
2505
2506         * editing/Editor.cpp:
2507         (WebCore::findFirstBadGrammarInRange):
2508         Use the more obvious way to check whether a range is empty. In this case the more obvious way
2509         would also have caused no problem to occur. Also added an assertion. Though this change is
2510         enough to fix the symptom of the bug, the real fix is in WebKit.
2511
2512 2007-05-25  Anders Carlsson  <andersca@apple.com>
2513
2514         Reviewed by Darin (Sorta).
2515
2516         * loader/ImageDocument.cpp:
2517         (WebCore::ImageDocument::restoreImageSize):
2518         Use removeProperty here.
2519
2520 2007-05-25  Geoffrey Garen  <ggaren@apple.com>
2521
2522         Reviewed by Darin Adler.
2523
2524         Some cleanup to Cache while Fixing <rdar://problem/5055182> The page cache 
2525         has no global cap.
2526         
2527         * loader/Cache.cpp: Removed destructor to help identify this class as a
2528         singleton.
2529
2530         * loader/Cache.h: Made constructor and destructor private to match the
2531         singleton model of PageCache.
2532         
2533         Put structs related to Cache inside its declaration to fix some namespace
2534         conflicts I had while writing my patch. (They don't exist anymore, but
2535         I figured this might help future development.)
2536
2537 2007-05-24  Geoffrey Garen  <ggaren@apple.com>
2538
2539         Reviewed by Darin Adler.
2540
2541         Fixed a bug with Settings where a number of different objects held bare 
2542         Settings* data members, even though the Page owns the Settings object and 
2543         deletes it upon destruction.
2544
2545         Added NULL checks since the Page can be deleted before the frame/document.
2546
2547         * page/Settings.cpp: Removed reliance on setNeedsReapplyStylesForSettingsChange.
2548
2549         * css/cssstyleselector.cpp: CSSStyleSelector was the worst offender. It 
2550         held a number of back pointers that were not guaranteed. I removed the 
2551         Settings*, Frame*, and FrameView* back pointers, but others could probably 
2552         go, too. I replaced them with a single Document* pointer, which is guaranteed
2553         because the Document owns the CSSStyleSelector.
2554
2555         * page/Page.cpp: Removed setNeedsReapplyStylesForSettingsChange -- the 
2556         Settings object is now a proper subcontroller of Page, so it doesn't need
2557         to use a global table to find its page anymore. Also, this function
2558         confusingly implied that the Frames in a page can have heterogeneous settings,
2559         which is not true.
2560
2561 2007-05-25  David Hyatt  <hyatt@apple.com>
2562
2563         Make sure -webkit-border-fit accounts for padding as well as border.
2564
2565         Reviewed by aroben
2566
2567         * rendering/RenderBlock.cpp:
2568         (WebCore::RenderBlock::borderFitAdjust):
2569
2570 2007-05-25  David Hyatt  <hyatt@apple.com>
2571
2572         Rework line numbering (again).  This time I finally think I have
2573         it right for all the document.write insanity that can occur.
2574
2575         Reviewed by aroben
2576
2577         * html/HTMLParser.cpp:
2578         (WebCore::HTMLParser::reportErrorToConsole):
2579         * html/HTMLParserErrorCodes.cpp:
2580         (WebCore::htmlParserDocumentWriteMessage):
2581         * html/HTMLParserErrorCodes.h:
2582         * html/HTMLTokenizer.cpp:
2583         (WebCore::HTMLTokenizer::write):
2584         * html/HTMLTokenizer.h:
2585         (WebCore::HTMLTokenizer::lineNumberPtr):
2586         (WebCore::HTMLTokenizer::processingContentWrittenByScript):
2587         * platform/SegementedSring.cpp
2588         (WebCore::SegmentedString::setExcludeLineNumbers):
2589         * platform/SegmentedString.h:
2590         (WebCore::SegmentedSubstring::SegmentedSubstring):
2591         (WebCore::SegmentedSubstring::clear):
2592         (WebCore::SegmentedSubstring::excludeLineNumbers):
2593         (WebCore::SegmentedSubstring::setExcludeLineNumbers):
2594         (WebCore::SegmentedString::excludeLineNumbers):
2595         (WebCore::SegmentedString::advance):
2596
2597 2007-05-24  Geoffrey Garen  <ggaren@apple.com>
2598
2599         Reviewed by Adam Roben.
2600
2601         Added a debug-only CachedPage counter. This helped me track down an SVG 
2602         timer bug in my recent page cache work.
2603                 
2604         * history/CachedPage.cpp:
2605
2606 2007-05-24  David Hyatt  <hyatt@apple.com>
2607
2608         Improve <form> error reporting to catch <form>s inside table parts.
2609         Tweak the wording of some of the error messages to be a bit better.
2610
2611         Reviewed by olliej
2612
2613         * html/HTMLParser.cpp:
2614         (WebCore::HTMLParser::insertNode):
2615         (WebCore::HTMLParser::processCloseTag):
2616         (WebCore::HTMLParser::popBlock):
2617         * html/HTMLParserErrorCodes.cpp:
2618         (WebCore::htmlParserErrorMessageTemplate):
2619         * html/HTMLParserErrorCodes.h:
2620
2621 2007-05-24  Rob Buis  <buis@kde.org>
2622
2623         Reviewed by Hyatt.
2624
2625         http://bugs.webkit.org/show_bug.cgi?id=4104
2626         first-letter not updating style with hover
2627         http://bugs.webkit.org/show_bug.cgi?id=13169
2628         css-formatted first letter won't hide dynamically
2629
2630         Update first letter when RenderBlock::setStyle is called. 
2631
2632         * css/cssstyleselector.cpp:
2633         (WebCore::CSSStyleSelector::checkOneSelector):
2634         * dom/Document.cpp:
2635         (WebCore::Document::Document):
2636         (WebCore::Document::createElement):
2637         * dom/Document.h:
2638         (WebCore::Document::usesFirstLetterRules):
2639         (WebCore::Document::setUsesFirstLetterRules):
2640         * rendering/RenderBlock.cpp:
2641         (WebCore::RenderBlock::setStyle):
2642         (WebCore::RenderBlock::updateFirstLetter):
2643
2644 2007-05-24  Mitz Pettel  <mitz@webkit.org>
2645
2646         Reviewed by Darin.
2647
2648         - fix http://bugs.webkit.org/show_bug.cgi?id=13800
2649           REGRESSION: Moving a slider moves another unrelated slider
2650
2651         Test: fast/forms/slider-thumb-shared-style.html
2652
2653         RenderSlider mutates the thumb's style, therefore it must not be shared
2654         with another slider's thumb, a situation that could occur if the sliders
2655         themselves shared style.
2656
2657         * rendering/RenderSlider.cpp:
2658         (WebCore::RenderSlider::createThumbStyle): Always use a private copy for
2659         the thumb style.
2660
2661 2007-05-24  Adele Peterson  <adele@apple.com>
2662
2663         Reviewed by Darin.
2664
2665         Fix for <rdar://problem/5211921> Form values sometimes get transposed (iGoogle)
2666
2667         Test: fast/history/redirect-load-no-form-restoration.html
2668
2669         * history/HistoryItem.cpp:
2670         (WebCore::HistoryItem::setURL): Clear the document state when the url changes for a HistoryItem.
2671         (WebCore::HistoryItem::isCurrentDocument): Added. Compares the HistoryItem url to the document's url.  This might not be the best way to do this, but it works for now.
2672         * history/HistoryItem.h:
2673         * loader/FrameLoader.cpp: (WebCore::FrameLoader::saveDocumentState): Only set the document (and form) state if the document is current for the history item.
2674
2675 2007-05-24  Mitz Pettel  <mitz@webkit.org>
2676
2677         Reviewed by Adele.
2678
2679         - fix http://bugs.webkit.org/show_bug.cgi?id=13857
2680           REGRESSION: onChange function applied to select element executes twice when focus is set
2681
2682         Test: fast/forms/select-double-onchange.html
2683
2684         * html/HTMLSelectElement.cpp:
2685         (WebCore::HTMLSelectElement::menuListOnChange): Changed to update m_lastOnChangeIndex
2686         before dispatching the change event to avoid reentrancy.
2687
2688 2007-05-24  Darin Adler  <darin@apple.com>
2689
2690         Reviewed by Hyatt.
2691
2692         - fix <rdar://problem/5226451> REGRESSION (21618): Mail block quotes
2693           are missing the lines on the side
2694
2695         This patch fixes three problems:
2696
2697         1) makes the "skip canLoad check" boolean also skip the check
2698            that prevents any loads while the document is in provisional
2699            state; this is the proximate cause of the bug
2700
2701         * loader/SubresourceLoader.cpp: (WebCore::SubresourceLoader::create):
2702         Don't check the frame's state if skipCanLoadCheck is true.
2703
2704         2) moves the "skip canLoad check" boolean to the Request object;
2705            the old implementation would cause that flag to affect the
2706            new request we served, which might not be the resource with
2707            that flag set
2708
2709         3) fixes error-handling code path that would leak requests
2710
2711         * html/HTMLImageLoader.cpp: (WebCore::HTMLImageLoader::updateFromElement):
2712         Pass false to the CachedImage constructor to indicate we are not making
2713         this object for the cache.
2714
2715         * loader/Cache.cpp:
2716         (WebCore::createResource): Pass true to the CachedImage constructor to
2717         indicate we are making this object for the cache.
2718         (WebCore::Cache::requestResource): Add new code that assumes the object
2719         will already have the inCache bit set, and that will delete the object
2720         and return 0 if the cache is disabled and the load failed.
2721
2722         * loader/CachedImage.h:
2723         * loader/CachedImage.cpp: (WebCore::CachedImage::CachedImage):
2724         Added a forCache boolean parameter. Always false for the constructor
2725         that's only used outside the cache code, and passed in as a boolean
2726         for the constructor that's used both in cache and outside cache.
2727
2728         * loader/CachedResource.h:
2729         * loader/CachedResource.cpp:
2730         (WebCore::CachedResource::CachedResource): Added a forCache boolean
2731         parameter that determines the initial state of the m_inCache flag.
2732         This is needed to prevent a resource from being destroyed if an
2733         error occurs during the initial load.
2734
2735         * loader/DocLoader.cpp:
2736         (WebCore::DocLoader::requestCSSStyleSheet): Added FIXME.
2737         (WebCore::DocLoader::setLoadInProgress): Added null check.
2738
2739         * loader/Request.h:
2740         * loader/Request.cpp: (WebCore::Request::Request):
2741         Added a shouldSkipCanLoadCheck boolean here, since we need to track
2742         this for each request.
2743
2744         * loader/loader.h:
2745         * loader/loader.cpp:
2746         (WebCore::Loader::load): Pass the skipCanLoadCheck boolean to the
2747         Request constructor rather than to the servePendingRequests function.
2748         (WebCore::Loader::servePendingRequests): Add a loop so we can handle
2749         cases where the request fails immediately without leaking the request
2750         and thinking that we're loading forever.
2751
2752 2007-05-24  David Hyatt  <hyatt@apple.com>
2753
2754         Add error reporting for residual style.
2755
2756         Reviewed by aroben
2757
2758         * html/HTMLParser.cpp:
2759         (WebCore::HTMLParser::handleResidualStyleCloseTagAcrossBlocks):
2760         (WebCore::HTMLParser::reopenResidualStyleTags):
2761         * html/HTMLParserErrorCodes.cpp:
2762         (WebCore::htmlParserErrorMessageTemplate):
2763         * html/HTMLParserErrorCodes.h:
2764
2765 2007-05-24  David Hyatt  <hyatt@apple.com>
2766
2767         Report <script/> as a warning instead of an error for now, since we
2768         actually do close it.  (Sigh.)
2769
2770         Reviewed by beth
2771
2772         * html/HTMLParser.cpp:
2773         (WebCore::HTMLParser::parseToken):
2774         (WebCore::HTMLParser::reportErrorToConsole):
2775         * html/HTMLParserErrorCodes.cpp:
2776         (WebCore::htmlParserErrorMessageTemplate):
2777         (WebCore::isWarning):
2778         * html/HTMLParserErrorCodes.h:
2779
2780 2007-05-24  David Hyatt  <hyatt@apple.com>
2781
2782         Add error reporting for the </p> -> <p></p> quirk.
2783
2784         Add error reporting when a stray close tag is encountered with no
2785         corresponding open tag.
2786
2787         Reviewed by adele
2788
2789         * html/HTMLParser.cpp:
2790         (WebCore::HTMLParser::HTMLParser):
2791         (WebCore::HTMLParser::processCloseTag):
2792         (WebCore::HTMLParser::popBlock):
2793         * html/HTMLParser.h:
2794         (WebCore::HTMLParser::popBlock):
2795         * html/HTMLParserErrorCodes.cpp:
2796         (WebCore::htmlParserErrorMessageTemplate):
2797         * html/HTMLParserErrorCodes.h:
2798
2799 2007-05-24  Kevin McCullough  <kmccullough@apple.com>
2800
2801         Reviewed by.
2802
2803         - Rolling back change to fix the build until I have a good fix for data: urls.
2804
2805         * ChangeLog:
2806         * loader/FrameLoader.cpp:
2807         (WebCore::FrameLoader::load):
2808         (WebCore::FrameLoader::open):
2809         * platform/String.cpp:
2810
2811 2007-05-24  David Hyatt  <hyatt@apple.com>
2812
2813         Add two more error messages to the HTMLParser.
2814
2815         Report when the </br> -> <br> quirk is triggered.
2816
2817         Also report whenever the broken XML self-closing tag syntax is used on
2818         tags that can actually have an end tag (either optional or required).
2819
2820         Reviewed by aroben
2821
2822         * html/HTMLParser.cpp:
2823         (WebCore::HTMLParser::parseToken):
2824         * html/HTMLParserErrorCodes.cpp:
2825         (WebCore::htmlParserErrorMessageTemplate):
2826         * html/HTMLParserErrorCodes.h:
2827         (WebCore::):
2828         * html/HTMLTokenizer.cpp:
2829         (WebCore::HTMLTokenizer::parseTag):
2830         * html/HTMLTokenizer.h:
2831         (WebCore::Token::reset):
2832
2833 2007-05-24  Sam Weinig  <sam@webkit.org>
2834
2835         Reviewed by Anders.
2836
2837         Rename JSHTMLFrameSetCustom.cpp to JSHTMLFrameSetElementCustom.cpp
2838         for consistency.
2839
2840         * WebCore.xcodeproj/project.pbxproj:
2841         * bindings/js/JSHTMLFrameSetCustom.cpp: Removed.
2842         * bindings/js/JSHTMLFrameSetElementCustom.cpp: Added.
2843
2844 2007-05-24  David Hyatt  <hyatt@apple.com>
2845
2846         Fix for <rdar://problem/5208440> (13753)
2847
2848         REGRESSION: Raw text needs to be pulled outside of tables
2849
2850         Reviewed by aroben
2851
2852         * html/HTMLParser.cpp:
2853         (WebCore::HTMLParser::handleError):
2854         * html/HTMLTableColElement.cpp:
2855         (WebCore::HTMLTableColElement::checkDTD):
2856         * html/HTMLTableElement.cpp:
2857         (WebCore::HTMLTableElement::checkDTD):
2858         * html/HTMLTableRowElement.cpp:
2859         (WebCore::HTMLTableRowElement::checkDTD):
2860         * html/HTMLTableSectionElement.cpp:
2861         (WebCore::HTMLTableSectionElement::checkDTD):
2862
2863 2007-05-24  Mitz Pettel  <mitz@webkit.org>
2864
2865         Reviewed by Darin.
2866
2867         - fix http://bugs.webkit.org/show_bug.cgi?id=13837
2868           Separator in new <select> widget disappears when block element with border is in document.
2869
2870         Test: fast/forms/menulist-separator-painting.html
2871
2872         * platform/graphics/cg/GraphicsContextCG.cpp:
2873         (WebCore::GraphicsContext::drawConvexPolygon): Changed this function to
2874         actually do both filling and stroking when needed, even though all existing
2875         callers set the stroke to none.
2876         * rendering/RenderThemeMac.mm:
2877         (WebCore::RenderThemeMac::paintMenuListButton): Added calls to set the stroke
2878         style and thickness when painting the arrows and the separator.
2879
2880 2007-05-24  Timothy Hatcher  <timothy@apple.com>
2881
2882         Reviewed by Sam Weinig.
2883
2884         Remove the OBJC_NEW_PROPERTIES #ifdef and only export the new @property syntax.
2885
2886         * bindings/objc/DOMObject.h:
2887         * bindings/scripts/CodeGeneratorObjC.pm:
2888
2889 2007-05-24  Sam Weinig  <sam@webkit.org>
2890
2891         Reviewed by Anders.
2892
2893         Uncomment HTMLFramesSetElement constructor now that it exists.
2894
2895         * page/DOMWindow.idl:
2896
2897 2007-05-24  Anders Carlsson  <andersca@apple.com>
2898
2899         Try fixing the buildbot build.
2900         
2901         * loader/ImageDocument.cpp:
2902         (WebCore::ImageDocument::resizeImageToFit):
2903         (WebCore::ImageDocument::imageClicked):
2904
2905 2007-05-24  Sam Weinig  <sam@webkit.org>
2906
2907         Reviewed by Darin.
2908
2909         Patch for http://bugs.webkit.org/show_bug.cgi?id=13853
2910         Autogenerate the JS bindings for the HTMLFrameSetElement
2911
2912         * DerivedSources.make:
2913         * WebCore.pro:
2914         * WebCore.xcodeproj/project.pbxproj:
2915         * bindings/js/JSHTMLElementWrapperFactory.cpp:
2916         * bindings/js/JSHTMLFrameSetCustom.cpp: Added.
2917         (WebCore::JSHTMLFrameSetElement::canGetItemsForName):
2918         (WebCore::JSHTMLFrameSetElement::nameGetter):
2919         * bindings/js/kjs_html.cpp:
2920         (KJS::):
2921         (KJS::JSHTMLElement::classInfo):
2922         (KJS::JSHTMLElement::accessors):
2923         (KJS::JSHTMLElement::getOwnPropertySlot):
2924         * bindings/js/kjs_html.h:
2925         (KJS::JSHTMLElement::):
2926         * html/HTMLFrameSetElement.idl:
2927
2928 2007-05-24  Zack Rusin  <zrusin@trolltech.com>
2929
2930         Reviewed by andersca
2931
2932         Fixing check for incorrent font size - it should
2933         check fixed not normal.
2934
2935         * page/Settings.cpp:
2936         (WebCore::Settings::setDefaultFixedFontSize):
2937
2938 2007-05-24  Mitz Pettel  <mitz@webkit.org>
2939
2940         Speculative buildbot build fix.
2941
2942         * css/cssstyleselector.cpp:
2943         (WebCore::CSSStyleSelector::applyProperty):
2944
2945 2007-05-24  Adam Roben  <aroben@apple.com>
2946
2947         Made Chrome::addMessageToConsole more flexible
2948
2949         addMessageToConsole now takes two additional parameters to specify the
2950         message source (HTML, JS, CSS, XML) and level (error, warning, log). To
2951         maintain our old behavior, all current messages were given
2952         JSMessageSource and ErrorMessageLevel parameters. Messages matching
2953         these characteristics are passed up to the ChromeClient.
2954
2955         Reviewed by Hyatt.
2956
2957         * bindings/js/JSCustomXPathNSResolver.cpp:
2958         (WebCore::JSCustomXPathNSResolver::lookupNamespaceURI):
2959         * bindings/js/kjs_events.cpp:
2960         (KJS::JSAbstractEventListener::handleEvent):
2961         * bindings/js/kjs_proxy.cpp:
2962         (WebCore::KJSProxy::evaluate):
2963         * bindings/js/kjs_window.cpp:
2964         (KJS::Window::isSafeScript):
2965         (KJS::ScheduledAction::execute):
2966         * html/HTMLParser.cpp:
2967         (WebCore::HTMLParser::reportErrorToConsole):
2968         * ksvg2/misc/SVGDocumentExtensions.cpp:
2969         (WebCore::SVGDocumentExtensions::reportWarning):
2970         (WebCore::SVGDocumentExtensions::reportError):
2971         * loader/FrameLoader.cpp:
2972         (WebCore::FrameLoader::reportLocalLoadFailed):
2973         * page/Chrome.cpp:
2974         (WebCore::Chrome::addMessageToConsole):
2975         * page/Chrome.h:
2976         (WebCore::):
2977         * xml/xmlhttprequest.cpp:
2978         (WebCore::XMLHttpRequest::setRequestHeader):
2979
2980 2007-05-24  David Hyatt  <hyatt@apple.com>
2981
2982         Rework how HTML handles line numbering so that it is not fooled by
2983         \r without a following \n and so that document.write doesn't lead
2984         to line numbering confusion.
2985
2986         Reviewed by aroben
2987
2988         * html/HTMLParser.cpp:
2989         (WebCore::HTMLParser::reportErrorToConsole):
2990         * html/HTMLTokenizer.cpp:
2991         (WebCore::HTMLTokenizer::processListing):
2992         (WebCore::HTMLTokenizer::parseSpecial):
2993         (WebCore::HTMLTokenizer::parseComment):
2994         (WebCore::HTMLTokenizer::parseServer):
2995         (WebCore::HTMLTokenizer::parseProcessingInstruction):
2996         (WebCore::HTMLTokenizer::parseText):
2997         (WebCore::HTMLTokenizer::parseEntity):
2998         (WebCore::HTMLTokenizer::parseTag):
2999         (WebCore::HTMLTokenizer::write):
3000         (WebCore::HTMLTokenizer::processToken):
3001         (WebCore::HTMLTokenizer::setSrc):
3002         * html/HTMLTokenizer.h:
3003         (WebCore::HTMLTokenizer::lineNumberPtr):
3004         * html/HTMLViewSourceDocument.cpp:
3005         (WebCore::HTMLViewSourceDocument::addLine):
3006         * loader/TextDocument.cpp:
3007         (WebCore::TextTokenizer::write):
3008         * platform/SegmentedString.cpp:
3009         (WebCore::SegmentedString::SegmentedString):
3010         (WebCore::SegmentedString::operator=):
3011         (WebCore::SegmentedString::clear):
3012         * platform/SegmentedString.h:
3013         (WebCore::SegmentedString::SegmentedString):
3014         (WebCore::SegmentedString::advance):
3015         (WebCore::SegmentedString::escaped):
3016
3017 2007-05-23  David Hyatt  <hyatt@apple.com>
3018
3019         Make the delete/InsertRows/Cells methods as well as the rowIndex method
3020         able to work properly even when whitespace or comment nodes are present.
3021
3022         Reviewed by aroben
3023
3024         fast/table/rowindex-comment-nodes.html
3025
3026         * html/HTMLTableRowElement.cpp:
3027         (WebCore::HTMLTableRowElement::rowIndex):
3028         (WebCore::HTMLTableRowElement::insertCell):
3029         (WebCore::HTMLTableRowElement::deleteCell):
3030         * html/HTMLTableSectionElement.cpp:
3031         (WebCore::HTMLTableSectionElement::insertRow):
3032         (WebCore::HTMLTableSectionElement::deleteRow):
3033
3034 2007-05-23  David Hyatt  <hyatt@apple.com>
3035
3036         <optgroup> should allow <script> and text nodes inside it, just like
3037         <select> does.
3038
3039         Reviewed by aroben
3040
3041         fast/forms/stuff-on-my-optgroup.html
3042
3043         * html/HTMLOptGroupElement.cpp:
3044         (WebCore::HTMLOptGroupElement::checkDTD):
3045         * html/HTMLSelectElement.cpp:
3046         (WebCore::HTMLSelectElement::checkDTD):
3047
3048 2007-05-23  David Hyatt  <hyatt@apple.com>
3049
3050         Framesets should allow whitespace text nodes as children.
3051
3052         Reviewed by aroben
3053
3054         * html/HTMLFrameSetElement.cpp:
3055         (WebCore::HTMLFrameSetElement::checkDTD):
3056
3057 2007-05-24  Mark Rowe  <mrowe@apple.com>
3058
3059         Fix the Qt build after r21685.
3060
3061         * platform/qt/CursorQt.cpp:
3062         (WebCore::notAllowedCursor):
3063         (WebCore::zoomInCursor):
3064         (WebCore::zoomOutCursor):
3065
3066 2007-05-23  Alp Toker  <alp.toker@collabora.co.uk>
3067
3068         Reviewed by Adam.
3069
3070         Fix the gdk build following changes in r21685.
3071
3072         * platform/gdk/CursorGdk.cpp:
3073         (WebCore::zoomInCursor):
3074         (WebCore::zoomOutCursor):
3075
3076 2007-05-23  David Hyatt  <hyatt@apple.com>
3077
3078         Fix for <rdar://problem/5222611> REGRESSION: Paint ordering problems at
3079         http://buymeasoda.com/dev/issues/image_onload/image_onload.html
3080
3081         Clamp z-index so that values that exceed maxint (or that are below minint)
3082         are clamped to those values.
3083
3084         Reviewed by darin
3085
3086         * css/cssstyleselector.cpp:
3087         (WebCore::CSSStyleSelector::applyProperty):
3088
3089 2007-05-23  Mitz Pettel  <mitz@webkit.org>
3090
3091         Reviewed by David Hyatt.
3092
3093         - fix http://bugs.webkit.org/show_bug.cgi?id=13563
3094           REGRESSION: Crash loading message in Yahoo! Mail
3095
3096         Tests: fast/css/stale-style-selector-crash-1.html
3097                fast/css/stale-style-selector-crash-2.html
3098
3099         * dom/Document.cpp:
3100         (WebCore::Document::Document): Initialize the m_didCalculateStyleSelector
3101         flag to 'false'.
3102         (WebCore::Document::updateStyleSelector): Do not bail out if we have ever
3103         calculated a non-trivial style selector, even if at the moment we are
3104         pending style sheets. We could have calculated a non-trivial selector
3105         already either because at some point there were no pending style sheets
3106         (so the currently pending ones were added dynamically) or because we were
3107         forced to do a layout ignoring pending style sheets. Either way, once
3108         there is a style selector, we need to keep it up to date, otherwise we can
3109         crash under recalcStyle() during updateRendering() or simply not recalculate
3110         style correctly for dynamic changes.
3111         (WebCore::Document::recalcStyleSelector): Set m_didCalculateStyleSelector
3112         to 'true' when creating a new style selector.
3113         * dom/Document.h:
3114
3115 2007-05-23  Anders Carlsson  <andersca@apple.com>
3116
3117         Reviewed by Adam.
3118
3119         <rdar://problem/5224749> Show a zoom/unzoom cursor for resizable image documents
3120         
3121         * WebCore.xcodeproj/project.pbxproj:
3122         Install the zoom cursors.
3123         
3124         * loader/ImageDocument.cpp:
3125         (WebCore::ImageDocument::resizeImageToFit):
3126         Set the cursor to the zoom in cursor.
3127         
3128         (WebCore::ImageDocument::restoreImageSize):
3129         If the image fits, reset the cursor. Otherwise, set it to the zoom in cursor.
3130
3131 2007-05-23  Darin Adler  <darin@apple.com>
3132
3133         Reviewed by Hyatt.
3134
3135         - fix problems where unrendered nodes were affecting on plain text serialization
3136
3137         * editing/TextIterator.cpp:
3138         (WebCore::TextIterator::advance): Don't call handleXXX functions or exitNode for
3139         nodes without renderers.
3140         (WebCore::shouldEmitNewlineAfterNode): Only consider rendered nodes when deciding
3141         if this is the last node in the document.
3142
3143 2007-05-23  Anders Carlsson  <andersca@apple.com>
3144
3145         Reviewed by Geoff.
3146
3147         <rdar://problem/3663808> Resize large images to fit in the browser window
3148         
3149         * WebCore.exp:
3150         Add new settings method.
3151         
3152         * loader/ImageDocument.cpp:
3153         (WebCore::ImageEventListener::ImageEventListener):
3154         New class that handles resize events and click events and forwards them to the image document.
3155         
3156         (WebCore::ImageTokenizer::ImageTokenizer):
3157         (WebCore::ImageTokenizer::writeRawData):
3158         (WebCore::ImageTokenizer::finish):
3159         (WebCore::ImageDocument::ImageDocument):
3160         (WebCore::ImageDocument::createDocumentStructure):
3161         (WebCore::ImageDocument::cachedImage):
3162         Let the ImageDocument class keep track of its document structure.
3163         
3164         (WebCore::ImageDocument::scale):
3165         Returns the scale that should be used when resizing the image.
3166         
3167         (WebCore::ImageDocument::resizeImage):
3168         Update the image size.
3169         
3170         (WebCore::ImageDocument::imageClicked):
3171         Toggle between resized and not resized. When restoring the size, scroll the image so that the area under
3172         the mouse stays the same.
3173         
3174         (WebCore::ImageDocument::imageChanged):
3175         When the image size is known, resize the image if needed.
3176         
3177         (WebCore::ImageDocument::restoreImageSize):
3178         Restore the image size.
3179         
3180         (WebCore::ImageDocument::imageNeedsResizing):
3181         Return whether the image is too big for its window or not.
3182         
3183         (WebCore::ImageDocument::windowSizeChanged):
3184         Called when the window's size changes. Determine if the window fits or not and resize it if it doesn't fit.
3185         
3186         (WebCore::ImageEventListener::handleEvent):
3187         Forward events to the image document.
3188         
3189         * page/Settings.cpp:
3190         (WebCore::Settings::Settings):
3191         (WebCore::Settings::setEnableAutomaticImageResizing):
3192         * page/Settings.h:
3193         (WebCore::Settings::enableAutomaticImageResizing):
3194         Add new setting.
3195         
3196 2007-05-23  Anders Carlsson  <andersca@apple.com>
3197
3198         Reviewed by Darin.
3199
3200         Add -webkit-zoom-in and -webkit-zoom-out cursors.
3201         
3202         * Resources/zoomInCursor.png: Added.
3203         * Resources/zoomOutCursor.png: Added.
3204         * css/CSSComputedStyleDeclaration.cpp:
3205         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3206         * css/CSSValueKeywords.in:
3207         * page/EventHandler.cpp:
3208         (WebCore::selectCursor):
3209         * platform/Cursor.h:
3210         * platform/mac/CursorMac.mm:
3211         (WebCore::zoomInCursor):
3212         (WebCore::zoomOutCursor):
3213         * rendering/RenderStyle.h:
3214         (WebCore::):
3215
3216 2007-05-23  Sam Weinig  <sam@webkit.org>
3217
3218         Reviewed by Darin.
3219
3220         Part one of patch for http://bugs.webkit.org/show_bug.cgi?id=13830
3221         Auto-generate JS DOM bindings for HTMLDocument and most of the rest
3222         of HTMLElement
3223
3224         - Just the HTMLElement part.
3225
3226         * bindings/js/kjs_html.cpp:
3227         (KJS::JSHTMLElement::getValueProperty):
3228         (KJS::JSHTMLElement::putValueProperty):
3229         * bindings/js/kjs_html.h:
3230         (KJS::JSHTMLElement::):
3231         * html/HTMLElement.idl:
3232
3233 2007-05-22  Kevin McCullough  <kmccullough@apple.com>
3234
3235         Reviewed by Darin.
3236
3237         - rdar://problem/5183523
3238         - We now check the document's URL to see if it can load a resource in the case of a URL click, instead of checking the referrer, which is blank for local files.
3239
3240         * loader/FrameLoader.cpp:
3241         (WebCore::FrameLoader::load):
3242         (WebCore::FrameLoader::open):
3243         * platform/PlatformString.h:
3244         (WebCore::debugPrintString):
3245
3246 2007-05-23  Sam Weinig  <sam@webkit.org>
3247
3248         Reviewed by Darin.
3249
3250         Part two of patch for http://bugs.webkit.org/show_bug.cgi?id=13830
3251         Auto-generate JS DOM bindings for HTMLDocument and most of the rest
3252         of HTMLElement
3253
3254         - Just the HTMLDocument part.
3255
3256         * WebCore.pro:
3257         * WebCore.xcodeproj/project.pbxproj:
3258         * bindings/js/JSHTMLDocumentCustom.cpp: Added.
3259         (WebCore::JSHTMLDocument::canGetItemsForName):
3260         (WebCore::JSHTMLDocument::nameGetter):
3261         (WebCore::JSHTMLDocument::all):
3262         (WebCore::JSHTMLDocument::setAll):
3263         (WebCore::JSHTMLDocument::location):
3264         (WebCore::JSHTMLDocument::setLocation):
3265         (WebCore::JSHTMLDocument::open):
3266         (WebCore::writeHelper):
3267         (WebCore::JSHTMLDocument::write):
3268         (WebCore::JSHTMLDocument::writeln):
3269         (WebCore::JSHTMLDocument::clear):
3270         * bindings/js/kjs_dom.cpp:
3271         (KJS::toJS):
3272         * bindings/js/kjs_dom.h:
3273         * bindings/js/kjs_html.cpp:
3274         * bindings/js/kjs_html.h:
3275         * bindings/objc/DOMPrivate.h:
3276         * bindings/scripts/CodeGeneratorJS.pm: Add [Deletable] property
3277         for Document.all and fix HasOverridingNameGetter to allow correct
3278         prototype chain
3279         * dom/Document.cpp:
3280         (WebCore::Document::plugins): adds alias to embeds() for bindings
3281         * dom/Document.h:
3282         * html/HTMLDocument.cpp:
3283         (WebCore::HTMLDocument::width):
3284         (WebCore::HTMLDocument::height):
3285         (WebCore::HTMLDocument::dir):
3286         (WebCore::HTMLDocument::setDir):
3287         (WebCore::HTMLDocument::designMode):
3288         (WebCore::HTMLDocument::setDesignMode):
3289         (WebCore::HTMLDocument::bgColor):
3290         (WebCore::HTMLDocument::setBgColor):
3291         (WebCore::HTMLDocument::fgColor):
3292         (WebCore::HTMLDocument::setFgColor):
3293         (WebCore::HTMLDocument::alinkColor):
3294         (WebCore::HTMLDocument::setAlinkColor):
3295         (WebCore::HTMLDocument::linkColor):
3296         (WebCore::HTMLDocument::setLinkColor):
3297         (WebCore::HTMLDocument::vlinkColor):
3298         (WebCore::HTMLDocument::setVlinkColor):
3299         (WebCore::HTMLDocument::captureEvents):
3300         (WebCore::HTMLDocument::releaseEvents):
3301         * html/HTMLDocument.h:
3302         * html/HTMLDocument.idl:
3303
3304 2007-05-23  David Hyatt  <hyatt@apple.com>
3305
3306         Fix for <rdar://problem/5221838> REGRESSION (r21581): no content in idisk
3307         window at mac.com.
3308
3309         Back out the change to make self-closed <script/> into a Dashboard quirk
3310         only.
3311
3312         Reviewed by aroben
3313
3314         * html/HTMLTokenizer.cpp:
3315         (WebCore::HTMLTokenizer::parseTag):
3316
3317 2007-05-23  Patti  <patti@apple.com>
3318
3319         Reviewed by David Harrison.
3320
3321         <rdar://problem/5078453> AXNext/PrevLineEndTextMarkerForTextMarker returns kAXErrorNoValue for attachment range
3322         
3323         Floating objects, such as aligned images, are not included as part of any line.  So when the given 
3324         text marker is on the floating object, the returned line edge cannot be found and asserts are fired.
3325         In addition, this paints an inconsistent text layout (in the accessibility sense) of where the floating 
3326         object resides.  Character/word methods report floating object at the beginning of the text line(s).  Yet
3327         line methods never present floating objects anywhere.  
3328         To fix this, the ax line methods will now do more checking to ensure floating object nodes are included
3329         when determining the line range/position. That way, assistive apps won't get stuck using the line methods 
3330         to read line-by-line
3331
3332         * bridge/mac/WebCoreAXObject.mm:
3333         (updateAXLineStartForVisiblePosition):
3334         Added a helper method to adjust line start position to account for floating objects
3335         (-[WebCoreAXObject doAXLeftLineTextMarkerRangeForTextMarker:]):
3336         (-[WebCoreAXObject doAXRightLineTextMarkerRangeForTextMarker:]):
3337         (-[WebCoreAXObject doAXNextLineEndTextMarkerForTextMarker:]):
3338         (-[WebCoreAXObject doAXPreviousLineStartTextMarkerForTextMarker:]):
3339         Fixed up line routines to include floating object nodes in line position calculation.
3340         startOfLine/endOLine may return null for position next to a floating position.  So now there's extra checks to prevent
3341         returning null line position/ranges back to AX.
3342
3343
3344 2007-05-23  Simon Hausmann  <hausmann@kde.org>
3345
3346         Reviewed by Zack, discussed also with Lars.
3347
3348         Make it possible to have per-QWebPage network interface
3349         implementations.
3350
3351         * platform/network/qt/ResourceHandleQt.cpp:
3352         (WebCore::ResourceHandle::start): Pass the page's network interface to
3353         the network manager.
3354
3355 2007-05-23  Rob Buis  <buis@kde.org>
3356
3357         Reviewed by Dave Hyatt.
3358
3359         http://bugs.webkit.org/show_bug.cgi?id=13174
3360         line-height in font shorthand does not override a previously stated line-height property
3361
3362         Make sure line-height is calculated against definite font-size and
3363         uses the last set line-height, ie. directly or through font shorthand.
3364
3365         * css/cssstyleselector.cpp:
3366         (WebCore::CSSStyleSelector::styleForElement):
3367         (WebCore::CSSStyleSelector::pseudoStyleForElement):
3368         (WebCore::CSSStyleSelector::applyDeclarations):
3369         (WebCore::CSSStyleSelector::applyProperty):
3370         * css/cssstyleselector.h:
3371
3372 2007-05-23  Lars Knoll <lars@trolltech.com>
3373
3374         Reviewed by Zack and Valgrind
3375
3376         Initialize variable.
3377
3378         * platform/qt/PlatformMouseEventQt.cpp:
3379         (WebCore::PlatformMouseEvent::PlatformMouseEvent):
3380
3381 2007-05-23  Rob Buis  <buis@kde.org>
3382
3383         Reviewed by Darin.
3384
3385         http://bugs.webkit.org/show_bug.cgi?id=13784
3386         REGRESSION (r13744-13750): Crash with empty gradient when drawing to canvas
3387
3388         Fix crash by testing for zero stops, and returning transparent black
3389         in this case.
3390
3391         * html/CanvasGradient.cpp:
3392         (WebCore::CanvasGradient::getColor):
3393
3394 2007-05-23  Rob Buis  <buis@kde.org>
3395
3396         Reviewed by Darin.
3397
3398         http://bugs.webkit.org/show_bug.cgi?id=13801
3399         Crash when loading nonexisting symbol
3400
3401         Check for referenced element and when not found just return.
3402
3403         * ksvg2/svg/SVGUseElement.cpp:
3404         (WebCore::SVGUseElement::buildPendingResource):
3405
3406 2007-05-22  Sam Weinig  <sam@webkit.org>
3407
3408         Rubber stamped by Adam.
3409
3410         Fix license.
3411
3412         * bindings/js/JSHTMLAnchorElementCustom.cpp:
3413
3414 2007-05-22  Sam Weinig  <sam@webkit.org>
3415
3416         Reviewed by Adam.
3417
3418         Patch for http://bugs.webkit.org/show_bug.cgi?id=13833
3419         Add ObjC DOM binding for HTMLMarqeeElement
3420
3421         - Also adds missing DOMHTMLFramePrivate.
3422
3423         * DerivedSources.make:
3424         * WebCore.xcodeproj/project.pbxproj:
3425         * bindings/objc/DOM.mm:
3426         (WebCore::createElementClassMap):
3427         * bindings/objc/DOMHTML.h:
3428         * bindings/objc/DOMInternal.h:
3429         * bindings/objc/DOMPrivate.h:
3430         * bindings/objc/PublicDOMInterfaces.h:
3431
3432 2007-05-22  Justin Garcia  <justin.garcia@apple.com>
3433
3434         Reviewed by darin, who found the fix independently.
3435
3436         http://bugs.webkit.org/show_bug.cgi?id=13804
3437         REGRESSION(r21611): Several new layout test pixel failures (misspelling markers)
3438         
3439         r21611 exposed a bug in the way removeMarkers computes
3440         the end of the range to remove markers from.  It also
3441         introduced a bug: removeMarkers expects a startOffset
3442         and a length, not a startOffset and an endOffset (added 
3443         a layout test).
3444
3445         * dom/Document.cpp:
3446         (WebCore::Document::removeMarkers): The other removeMarkers
3447         expects a startOffset and a length, not a startOffset and
3448         an endOffset.
3449         (WebCore::Document::removeMarkers): Fixed the endOffset
3450         from length and startOffset calculation.
3451
3452 2007-05-22  David Hyatt  <hyatt@apple.com>
3453
3454         Fix for bug 13802, background colors can't be reset to default
3455         color.  Fix the value cssText method to do the right thing for background
3456         and background-position values.
3457
3458         Reviewed by beth
3459
3460         fast/dom/background-shorthand-csstext.html
3461
3462         * css/CSSInitialValue.h:
3463         (WebCore::CSSInitialValue:::m_implicit):
3464         (WebCore::CSSInitialValue::isImplicitInitialValue):
3465         * css/CSSMutableStyleDeclaration.cpp:
3466         (WebCore::CSSMutableStyleDeclaration::getPropertyValue):
3467         (WebCore::CSSMutableStyleDeclaration::getLayeredShorthandValue):
3468         * css/CSSMutableStyleDeclaration.h:
3469         * css/CSSValue.h:
3470         (WebCore::CSSValue::isImplicitInitialValue):
3471         * css/cssparser.cpp:
3472         (WebCore::CSSParser::parseValue):
3473         (WebCore::CSSParser::parseBackgroundShorthand):
3474         (WebCore::CSSParser::parseShorthand):
3475
3476 2007-05-22  Darin Adler  <darin@apple.com>
3477
3478         Reviewed by Geoff.
3479
3480         - fix <rdar://problem/5215830> REGRESSION: ebay.com layout is wrong
3481
3482         The code on ebay was looking for the "document" property on a iframe.
3483         We changed that to be the ownerDocument rather than the contentDocument,
3484         which was not what ebay was expecting. The best fix seems to be removing
3485         the document property altogether.
3486
3487         Test: fast/dom/iframe-document.html
3488
3489         * bindings/js/kjs_html.h: Remove ElementDocument.
3490         * bindings/js/kjs_html.cpp: (KJS::JSHTMLElement::getValueProperty): Ditto.
3491
3492 2007-05-22  Adele Peterson  <adele@apple.com>
3493
3494         Reviewed by Darin.
3495
3496         A little cleanup from my last checkin.
3497
3498         * page/Chrome.h: Formatting change.
3499         * page/mac/ChromeMac.mm: Fixed copyright.
3500
3501 2007-05-22  Adele Peterson  <adele@apple.com>
3502
3503         Reviewed by Darin.
3504
3505         Fix for http://bugs.webkit.org/show_bug.cgi?id=13796
3506         Crash in [NSInputContext currentInputContext] when you click on this map
3507
3508         This is another case of <rdar://problem/5171145> Safari crashed closing tab in NSInputContext updateInputContexts
3509
3510         Test: fast/frames/frame-display-none-focus.html
3511
3512         * WebCore.xcodeproj/project.pbxproj: Added ChromeMac.mm
3513         * page/Chrome.h:
3514         * page/mac/ChromeMac.mm: Added.
3515         (WebCore::Chrome::focusNSView): Moved code from Widget::setFocus so it can be used whenever we need to make a view the first responder.
3516         * page/mac/EventHandlerMac.mm: (WebCore::EventHandler::focusDocumentView): Calls focusNSView.
3517         * platform/mac/WidgetMac.mm: (WebCore::Widget::setFocus): Calls focusNSView.
3518
3519 2007-05-22  Justin Garcia  <justin.garcia@apple.com>
3520
3521         Reviewed by darin
3522         
3523         <rdar://problem/4875189> 
3524         List is deleted when replacing contents with Chinese/Japanese characters
3525
3526         * editing/htmlediting.cpp:
3527         (WebCore::isSpecialElement): Lists are no longer special.
3528         They can be removed by removing their content and then 
3529         then hitting delete inside of the empty list item that's 
3530         left over. Even when that list item is the first thing 
3531         in the editable region.
3532
3533 2007-05-22  Darin Adler  <darin@apple.com>
3534
3535         Reviewed by Tim Hatcher.
3536
3537         - fix <rdar://problem/5206089> REGRESSION: hovering over amazon.com "product categories"
3538           tab makes page content disappear
3539
3540         The contentWindow property was doing a cross-frame security check, but it shouldn't.
3541         Window objects are responsible for protecting themselves from cross-frame activity.
3542         Because contentWindow returned undefined, we then ended up setting visibility on the
3543         body of the main frame to "hidden".
3544
3545         No layout test yet. When we make cross-domain tests, we should include this one.
3546
3547         * html/HTMLFrameElement.idl: Removed CheckFrameSecurity attribute from contentWindow.
3548         * html/HTMLIFrameElement.idl: Ditto.
3549
3550 2007-05-22  Justin Garcia  <justin.garcia@apple.com>
3551
3552         Reviewed by oliver
3553
3554         <rdar://problem/5213963>
3555         REGRESSION(r21467): Active selection remains in text field after clicking on a button
3556
3557         * page/EventHandler.cpp:
3558         (WebCore::EventHandler::dispatchMouseEvent): Call
3559         FocusController::setFocusedNode, because Document::setFocusedNode
3560         no longer clears the selection.
3561         Begin passing the new focused frame to 
3562         FocusController::setFocusedNode, because when the 
3563         new focus node is null, the selection should only be 
3564         cleared if the focused frame isn't changing.
3565         (WebCore::Element::focus): Begin passing the new focused
3566         frame.
3567         (WebCore::Element::blur): Ditto.
3568         * html/HTMLInputElement.cpp:
3569         (WebCore::HTMLInputElement::focus): Ditto.
3570         * html/HTMLTextAreaElement.cpp:
3571         (WebCore::HTMLTextAreaElement::focus): Ditto.
3572         * page/Frame.cpp:
3573         (WebCore::Frame::setFocusedNodeIfNeeded): Ditto.
3574         * page/FocusController.cpp:
3575         (WebCore::clearSelectionIfNeeded): Take in the new
3576         focused frame.  If it's not changing, don't clear the
3577         selection.
3578         (WebCore::FocusController::setFocusedNode): Take
3579         in the new focused frame.
3580         * page/FocusController.h:
3581
3582 2007-05-22  Marius Bugge Monsen  <mbm@trolltech.com>
3583
3584         Reviewed by Zack.
3585
3586         Implement some more functions in ClipboardQt.
3587
3588         * platform/qt/ClipboardQt.cpp:
3589         (WebCore::ClipboardQt::ClipboardQt):
3590         (WebCore::ClipboardQt::getData):
3591         (WebCore::ClipboardQt::setData):
3592         (WebCore::ClipboardQt::types):
3593
3594 2007-05-21  Oliver Hunt  <oliver@apple.com>
3595
3596         Reviewed by Sam.
3597         
3598         Fix for http://bugs.webkit.org/show_bug.cgi?id=13789 
3599         -- SVGLocatable::getScreenCTM() faulty
3600         
3601         Needed to update SVGLength to handle the case where the SVGElement is
3602         not the root document element -- we do this by falling back on the 
3603         renderer for the context.
3604         
3605         For <svg> elements embedded as mixed content in xhtml we consider the
3606         absolutePosition of the parent to be the origin for the <svg> element.
3607
3608         * ksvg2/svg/SVGLength.cpp:
3609         (WebCore::SVGLength::PercentageOfViewport):
3610         * ksvg2/svg/SVGSVGElement.cpp:
3611         (WebCore::SVGSVGElement::getScreenCTM):
3612
3613 2007-05-21  Timothy Hatcher  <timothy@apple.com>
3614
3615         Reviewed by Adam.
3616
3617         <rdar://problem/5084400> -[DOMRange lineBoxRects] returns an empty array when the DOM nodes have just been created
3618
3619         Do a updateLayoutIgnorePendingStylesheets before asking the Node or Range for it's box rects.
3620
3621         * bindings/objc/DOM.mm:
3622         (-[DOMNode boundingBox]):
3623         (-[DOMNode lineBoxRects]):
3624         (-[DOMRange boundingBox]):
3625         (-[DOMRange lineBoxRects]):
3626
3627 2007-05-21  Sam Weinig  <sam@webkit.org>
3628
3629         Reviewed by George Staikos.
3630
3631         Fix Qt build.
3632
3633         * WebCore.pro: add missing IDL files.
3634
3635 2007-05-21  Sam Weinig  <sam@webkit.org>
3636
3637         Reviewed by Darin.
3638
3639         Patch for http://bugs.webkit.org/show_bug.cgi?id=13803
3640         Autogenerate the JS bindings for the HTMLMarqueeElement.
3641
3642         * DerivedSources.make:
3643         * WebCore.xcodeproj/project.pbxproj:
3644         * bindings/js/JSHTMLElementWrapperFactory.cpp:
3645         * bindings/js/kjs_css.cpp:
3646         (KJS::DOMCSSRule::getOwnPropertySlot): Fix possible null pointer issue.
3647         (KJS::DOMCSSRule::put): Fix possible null pointer issue.
3648         * bindings/js/kjs_html.cpp:
3649         (KJS::):
3650         (KJS::JSHTMLElement::classInfo):
3651         (KJS::JSHTMLElement::accessors):
3652         (KJS::JSHTMLElement::getOwnPropertySlot): Fix null pointer issue.
3653         (KJS::HTMLElementFunction::callAsFunction):
3654         (KJS::JSHTMLElement::put):
3655         * bindings/js/kjs_html.h:
3656         (KJS::JSHTMLElement::):
3657         * html/HTMLMarqueeElement.cpp:
3658         (WebCore::HTMLMarqueeElement::start):
3659         (WebCore::HTMLMarqueeElement::stop):
3660         * html/HTMLMarqueeElement.h: Add start() and stop() functions.
3661         * html/HTMLMarqueeElement.idl: Added.
3662         * page/DOMWindow.idl: Add marquee constructor.
3663
3664 2007-05-21  Adele Peterson  <adele@apple.com>
3665
3666         Fix by Darin, reviewed by me.
3667
3668         Fix for <rdar://problem/5171145> Safari crashed closing tab in NSInputContext updateInputContexts
3669
3670         * platform/mac/WidgetMac.mm:
3671         (WebCore::safeRemoveFromSuperview): Added. If the view is the window's first responder, then 
3672          set the window's first responder to nil so we don't leave the window pointing to a view that's no longer in it.
3673         (WebCore::Widget::setFocus): Don't attempt to focus the view if it has no window.
3674         (WebCore::Widget::removeFromSuperview): Call safeRemoveFromSuperview.
3675         (WebCore::Widget::afterMouseDown): ditto.
3676
3677 2007-05-21  David Hyatt  <hyatt@apple.com>
3678
3679         Make a line gutter backdrop so that tiny view source docs don't look
3680         bad.
3681
3682         Reviewed by aroben
3683
3684         * css/view-source.css:
3685         * html/HTMLViewSourceDocument.cpp:
3686         (WebCore::HTMLViewSourceDocument::createContainingTable):
3687
3688 2007-05-21  David Hyatt  <hyatt@apple.com>
3689
3690         Make sure to distinguish between links to internal resources and
3691         real links (anchors) in view source mode.
3692
3693         Reviewed by aroben
3694
3695         * css/view-source.css:
3696         * html/HTMLViewSourceDocument.cpp:
3697         (WebCore::HTMLViewSourceDocument::addViewSourceToken):
3698         (WebCore::HTMLViewSourceDocument::addLink):
3699         * html/HTMLViewSourceDocument.h:
3700
3701 2007-05-21  Sam Weinig  <sam@webkit.org>
3702
3703         Reviewed by Adam and Darin.
3704
3705         Patch for http://bugs.webkit.org/show_bug.cgi?id=13791
3706         Autogenerate the JS bindings for the HTMLIFrameElement and HTMLFrameElement.
3707
3708         * DerivedSources.make:
3709         * WebCore.xcodeproj/project.pbxproj:
3710         * bindings/js/JSHTMLAnchorElementCustom.cpp:
3711         * bindings/js/JSHTMLElementWrapperFactory.cpp:
3712         * bindings/js/kjs_html.cpp:
3713         (KJS::):
3714         (KJS::JSHTMLElement::classInfo):
3715         (KJS::JSHTMLElement::accessors):
3716         (KJS::HTMLElementFunction::callAsFunction):
3717         * bindings/js/kjs_html.h:
3718         (KJS::JSHTMLElement::):
3719         * bindings/scripts/CodeGeneratorJS.pm:
3720         * html/HTMLFrameElement.idl:
3721         * html/HTMLFrameElementBase.cpp:
3722         (WebCore::HTMLFrameElementBase::location):
3723         * html/HTMLFrameElementBase.h:
3724         * html/HTMLFrameOwnerElement.h:
3725         (WebCore::HTMLFrameOwnerElement::contentWindow):
3726         * html/HTMLIFrameElement.idl:
3727         * page/DOMWindow.idl:
3728
3729 2007-05-21  Lars Knoll <lars@trolltech.com>
3730
3731         Reviewed by Zack.
3732
3733         Remove the ResourceHandleManager class, it is now part of 
3734         QWebNetworkInterface. Adapt ResourceHandle to the new way 
3735         of things.
3736
3737         * WebCore.pro:
3738         * platform/network/ResourceHandleInternal.h:
3739         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
3740         * platform/network/qt/ResourceHandleManagerKDE.cpp: Removed.
3741         * platform/network/qt/ResourceHandleManagerKDE.h: Removed.
3742         * platform/network/qt/ResourceHandleManagerQt.cpp: Removed.
3743         * platform/network/qt/ResourceHandleManagerQt.h: Removed.
3744         * platform/network/qt/ResourceHandleQt.cpp:
3745         (WebCore::ResourceHandle::~ResourceHandle):
3746         (WebCore::ResourceHandle::start):
3747         (WebCore::ResourceHandle::cancel):
3748
3749 2007-05-21  David Hyatt  <hyatt@apple.com>
3750
3751         Second half of fix for 13793, make sure rules=groups works properly with
3752         spanning colgroups.
3753
3754         Also make sure colgroups get an actual span of 1 (instead of incorrectly
3755         giving them a span of 0).
3756
3757         Reviewed by mitz
3758
3759         fast/table/colgroup-spanning-groups-rules.html
3760
3761         * html/HTMLTableColElement.cpp:
3762         (WebCore::HTMLTableColElement::HTMLTableColElement):
3763         * rendering/RenderTable.cpp:
3764         (WebCore::RenderTable::colElement):
3765         * rendering/RenderTable.h:
3766         * rendering/RenderTableCell.cpp:
3767         (WebCore::RenderTableCell::collapsedLeftBorder):
3768         (WebCore::RenderTableCell::collapsedRightBorder):
3769
3770 2007-05-20  David Hyatt  <hyatt@apple.com>
3771
3772         Half of a fix for 13793, make sure rules=groups and border behave properly
3773         together.
3774
3775         Reviewed by mitz
3776
3777         No tests added, two Mozilla table tests now pass that failed before.
3778
3779         * html/HTMLTableElement.cpp:
3780         (WebCore::HTMLTableElement::getSharedCellDecl):
3781
3782 2007-05-20  Brady Eidson <beidson@apple.com>
3783
3784         Reviewed by Geoose Garen
3785
3786         <rdar://problem/4758919> - Incorrect favicon shown for URL after going back
3787
3788         When restoring a cached page, we'd try to kick off the icon load for it, which ended up causing 
3789         shenanigans with the icon url -> page url mapping.  
3790
3791         * loader/FrameLoader.cpp:
3792         (WebCore::FrameLoader::endIfNotLoading): Only try an icon load if we're not restoring from the page cache
3793         (WebCore::FrameLoader::startIconLoader): Added helpful logging that helped me track this down
3794         (WebCore::FrameLoader::commitIconURLToIconDatabase): Ditto (and fixed a comment typo)
3795
3796         * loader/icon/IconLoader.cpp:
3797         (WebCore::IconLoader::stopLoading): Don't null out the ResourceLoader here, as clearLoadingState() does that
3798         (WebCore::IconLoader::finishLoading): Added helpful logging that helped me track this down
3799
3800
3801 2007-05-20  Darin Adler  <darin@apple.com>
3802
3803         Reviewed by Oliver Hunt.
3804
3805         - fix <rdar://problem/5193416> REGRESSION: Selection on large pages extremely slow
3806
3807         * dom/Document.cpp: (WebCore::Document::removeMarkers): Added an early exit for the common
3808         case where there are no markers. Changed code to iterate over all the nodes in the range
3809         instead of using TextIterator, which is more efficient.
3810         
3811         * page/Frame.cpp: (WebCore::Frame::respondToChangedSelection): Added checks for editable,
3812         so we don't bother doing work related to spell checking and grammar checking when changing
3813         the selection in non-editable text. Also rearranged the code so we only compute the old
3814         word boundaries and sentence boundaries when actually needed, and don't do the sentence
3815         range checks unless grammar checking is enabled.
3816
3817         * platform/TextBreakIteratorICU.cpp:
3818         (WebCore::setUpIterator): Don't take a locale parameter. Always pass in currentTextBreakLocaleID.
3819         (WebCore::characterBreakIterator): Removed local parameter.
3820         (WebCore::wordBreakIterator): Ditto.
3821         (WebCore::lineBreakIterator): Ditto.
3822         (WebCore::sentenceBreakIterator): Ditto.
3823
3824         * platform/mac/TextBreakIteratorInternalICUMac.mm:
3825         (WebCore::getTextBreakLocale): Broke out the code to actually get the locale.
3826         (WebCore::currentTextBreakLocaleID): This function now handles only the caching and calls
3827         getTextBreakLocale to actually figure it out.
3828
3829         * editing/visible_units.cpp: Added lots of FIXME comments, but no code change.
3830
3831 2007-05-20  Adam Treat  <adam@staikos.net>
3832
3833         Add -f to cp to deal with some obscure build environments.
3834
3835         Reviewed by George Staikos.
3836
3837         * move-js-headers.sh:
3838
3839 2007-05-20  Adam Treat  <adam@staikos.net>
3840
3841         Add missing include for auto_ptr
3842
3843         Reviewed by George Staikos.
3844
3845         * platform/graphics/ImageBuffer.h:
3846
3847 2007-05-19  David Hyatt  <hyatt@apple.com>
3848
3849         Fix for bug 13785, O(n^2) counter creation.
3850
3851         Reviewed by darin
3852
3853         * rendering/RenderCounter.cpp:
3854         (WebCore::findPlaceForCounter):
3855         (WebCore::RenderCounter::originalText):
3856
3857 2007-05-19  Mitz Pettel  <mitz@webkit.org>
3858
3859         Reviewed by Dave Hyatt.
3860
3861         - fix http://bugs.webkit.org/show_bug.cgi?id=12729
3862           box-shadow disappears when scrolling a div that it falls on/under
3863
3864         Tests: fast/repaint/box-shadow-dynamic.html
3865                fast/repaint/box-shadow-h.html
3866                fast/repaint/box-shadow-v.html
3867
3868         * rendering/InlineFlowBox.cpp:
3869         (WebCore::InlineFlowBox::placeBoxesHorizontally): Factor in box shadow.
3870         (WebCore::InlineFlowBox::placeBoxesVertically): Ditto.
3871         (WebCore::InlineFlowBox::paint): Account for box shadow when checking if
3872         the damage rect intersects.
3873         * rendering/RenderBlock.cpp:
3874         (WebCore::RenderBlock::overflowHeight): For overflow areas, when asked
3875         for the "exterior" overflow, add box shadow overflow.
3876         (WebCore::RenderBlock::overflowWidth): Ditto.
3877         (WebCore::RenderBlock::overflowLeft): Ditto.
3878         (WebCore::RenderBlock::overflowTop): Ditto.
3879         (WebCore::RenderBlock::overflowRect): Ditto.
3880         (WebCore::RenderBlock::layoutBlock): Factor box shadow into visual overflow.
3881         * rendering/RenderFlexibleBox.cpp:
3882         (WebCore::RenderFlexibleBox::layoutBlock): Ditto.
3883         * rendering/RenderFlow.cpp:
3884         (WebCore::RenderFlow::lowestPosition): For overflow areas, when asked for
3885         the "exterior" extreme position, add box shadow.
3886         (WebCore::RenderFlow::rightmostPosition): Ditto.
3887         (WebCore::RenderFlow::leftmostPosition): Ditto.
3888         * rendering/RenderLayer.cpp:
3889         (WebCore::RenderLayer::calculateRects): Avoid clipping out box shadow.
3890         * rendering/RenderObject.cpp:
3891         (WebCore::RenderObject::repaintAfterLayoutIfNeeded): Make sure to paint
3892         the box shadow when an edge with a shadow moves.
3893         (WebCore::RenderObject::adjustRectForOutlineAndShadow): Helper function
3894         that expands a given rectangle to encompass outline and box shadow.
3895         (WebCore::RenderObject::absoluteOutlineBox): Changed to include box shadow.
3896         * rendering/RenderObject.h:
3897
3898 2007-05-19  Mitz Pettel  <mitz@webkit.org>
3899
3900         Reviewed by Dave Hyatt.
3901
3902         - fix http://bugs.webkit.org/show_bug.cgi?id=13783
3903           REGRESSION (r21120): Frame resizers not repainted properly when dragged
3904
3905         * rendering/RenderFrameSet.cpp:
3906         (WebCore::RenderFrameSet::layout):
3907
3908 2007-05-19  Mitz Pettel  <mitz@webkit.org>
3909
3910         Reviewed by Darin.
3911
3912         - fix http://bugs.webkit.org/show_bug.cgi?id=13774
3913           REGRESSION: Crash emailing blog entry using Google Reader
3914
3915         Test: fast/table/stale-grid-crash.html
3916
3917         * rendering/RenderTable.cpp:
3918         (WebCore::RenderTable::recalcSections): Made const and replaced
3919         setNeedsLayout(true) with an assertion that the table is already
3920         marked for layout.
3921         (WebCore::RenderTable::sectionAbove): Added call to recalcSectionsIfNeeded().
3922         (WebCore::RenderTable::sectionBelow): Ditto.
3923         (WebCore::RenderTable::cellAbove): Ditto.
3924         (WebCore::RenderTable::cellBelow): Ditto.
3925         (WebCore::RenderTable::cellBefore): Ditto.
3926         (WebCore::RenderTable::cellAfter): Ditto.
3927         * rendering/RenderTable.h:
3928         Made some private member variables which are used in section recalc mutable.
3929         (WebCore::RenderTable::setNeedsSectionRecalc): Moved the call to
3930         setNeedsLayout() from recalcSections() into here, because I made
3931         recalcSections() const.
3932         (WebCore::RenderTable::recalcSectionsIfNeeded): Made const.
3933
3934 2007-05-19  Mitz Pettel  <mitz@webkit.org>
3935
3936         Reviewed by Darin.
3937
3938         - http://bugs.webkit.org/show_bug.cgi?id=13320
3939           rounded corners with drop shadows are really slow
3940
3941         Test for a rendering bug fixed by this patch:
3942             fast/box-shadow/border-radius-big.html
3943
3944         No test for the performance ingredient.
3945
3946         * platform/graphics/GraphicsContext.cpp:
3947         (WebCore::GraphicsContext::addRoundedRectClip): Made cross-platform.
3948         Changed to use a single clipping path. If all the radii cannot be
3949         accommodated, clips to a rect.
3950         (WebCore::GraphicsContext::clipOutRoundedRect): Changed to use a single
3951         clipping path. If all the radii cannot be accommodated, clips out a rect.
3952         * platform/graphics/GraphicsContext.h: Added clipOut(const Path&).
3953         * platform/graphics/Path.cpp:
3954         (WebCore::Path::createRoundedRectangle): Added. Returns a rounded rectangle
3955         with the specified radii. If all the radii cannot be accommodated, returns
3956         a rectangular path.
3957         * platform/graphics/Path.h:
3958         * platform/graphics/cairo/GraphicsContextCairo.cpp:
3959         (WebCore::GraphicsContext::clipOut): Added.
3960         * platform/graphics/cg/GraphicsContextCG.cpp:
3961         (WebCore::GraphicsContext::fillRoundedRect): Changed to use a single path.
3962         (WebCore::GraphicsContext::clipOut): Added.
3963         * platform/graphics/qt/GraphicsContextQt.cpp:
3964         (WebCore::GraphicsContext::clipOut): Added.
3965
3966 2007-05-19  Anders Carlsson  <andersca@apple.com>
3967
3968         Reviewed by Mitz.
3969
3970         Test: fast/frames/inline-object-inside-frameset.html
3971         
3972         http://bugs.webkit.org/show_bug.cgi?id=13771
3973         Assertion failure ASSERT(m_layer) when running Hamachi fuzz tester
3974
3975         Don't paint inline objects.
3976         
3977         * rendering/RenderFrameSet.cpp:
3978         (WebCore::RenderFrameSet::paint):
3979
3980 2007-05-19  David Hyatt  <hyatt@apple.com>
3981
3982         Add support for plain text MIME types (CSS/JS/TXT) to view source mode.
3983         CSS/JS will eventually tokenize via their own special tokenizers so that
3984         they can also be syntax-highlighted, but for now just treat them as
3985         plain text.
3986
3987         Reviewed by aroben
3988
3989         * dom/DOMImplementation.cpp:
3990         (WebCore::DOMImplementation::createDocument):
3991         * html/HTMLViewSourceDocument.cpp:
3992         (WebCore::HTMLViewSourceDocument::HTMLViewSourceDocument):
3993         (WebCore::HTMLViewSourceDocument::createTokenizer):
3994         (WebCore::HTMLViewSourceDocument::createContainingTable):
3995         (WebCore::HTMLViewSourceDocument::addViewSourceText):
3996         (WebCore::HTMLViewSourceDocument::addViewSourceToken):
3997         * html/HTMLViewSourceDocument.h:
3998         * loader/TextDocument.cpp:
3999         (WebCore::TextTokenizer::TextTokenizer):
4000         (WebCore::TextTokenizer::write):
4001         * loader/TextDocument.h:
4002         (WebCore::TextTokenizer::checkBuffer):
4003
4004 2007-05-18  David Hyatt  <hyatt@apple.com>
4005
4006         Fix a glitch in view source mode attribute names.
4007
4008         * html/HTMLViewSourceDocument.cpp:
4009         (WebCore::HTMLViewSourceDocument::addViewSourceToken):
4010
4011 2007-05-18  David Hyatt  <hyatt@apple.com>
4012
4013         "Linkify" view source mode links.
4014
4015         Reviewed by andersca
4016
4017         * css/view-source.css:
4018         * html/HTMLViewSourceDocument.cpp:
4019         (WebCore::HTMLViewSourceDocument::addViewSourceToken):
4020         (WebCore::HTMLViewSourceDocument::addSpanWithClassName):
4021         (WebCore::HTMLViewSourceDocument::addLink):
4022         * html/HTMLViewSourceDocument.h:
4023
4024 2007-05-18  Oliver Hunt  <oliver@apple.com>
4025
4026         Reviewed by Sam
4027
4028         No longer need to pass HTMLImageElement and HTMLImageLoader on to WebKit
4029         Need to expose CachedResourceClient constructor
4030
4031         * WebCore.exp:
4032         * WebCore.xcodeproj/project.pbxproj:
4033
4034 2007-05-18  David Hyatt  <hyatt@apple.com>
4035
4036         Fix for <rdar://problem/5214338> REGRESSION: / mishandled in 
4037         HTML tokenization (13780).
4038
4039         Reviewed by ggaren
4040
4041         * html/HTMLTokenizer.cpp:
4042         (WebCore::Token::addAttribute):
4043         (WebCore::HTMLTokenizer::parseTag):
4044
4045 2007-05-18  Brady Eidson  <beidson@apple.com>
4046
4047         Reviewed by Maciej
4048
4049         http://bugs.webkit.org/show_bug.cgi?id=12681 and
4050         <rdar://problem/5166149> - window.open() causes server to be hit twice
4051
4052         This regressed in http://trac.webkit.org/projects/webkit/changeset/14637
4053         That patch was to fix broken behavior when opening an already existant window.
4054         The unfortunate side effect was to cause the server to be hit twice.  
4055         Once during the call to frame->loader()->createWindow(), and again via a 
4056         scheduled redirection.
4057
4058         I decided to restore the original de-facto behavior by making the new window
4059         open via a scheduled redirection - there is a FIXME that was already here that
4060         explains the reason why we have to do it this way for now.
4061
4062         Additionally, there were two distinct places that had their own logic to open
4063         a new window - the logic for window.open() and the logic for 
4064         window.showModalDialog().  The logic was almost identical so I condensed them
4065         into one utility function that takes a flag to handle the slight difference.
4066
4067         A layout test is not possible at this time since it would involve capturing 
4068         server logs (the 1st connection does not exist long enough to result in any
4069         delegate callbacks).  That task is documented in 
4070         http://bugs.webkit.org/show_bug.cgi?id=13769
4071
4072         * bindings/js/kjs_window.cpp:
4073         (KJS::createWindow): Merged the two slightly different versions of "creating a window" 
4074           logic here.  For the modal dialog case the load is an immediate call to changeLocation(),
4075           which is triggered by the "immediate" flag, and the other cases load via scheduleLocationChange()
4076         (KJS::showModalDialog): Call createWindow()
4077         (KJS::WindowFunc::callAsFunction): Handle frame targets of _top or _parent immediately and call 
4078           createWindow() for all others
4079
4080 2007-05-18  Sam Weinig  <sam@webkit.org>
4081
4082         Reviewed by Geoff.
4083
4084         Autogenerate the JS bindings for the HTMLTableElement, HTMLTableCaptionElement,
4085         HTMLTableCellElement, HTMLTableColElement, HTMLTableRowElement, HTMLTableSectionElement.
4086
4087         * DerivedSources.make:
4088         * WebCore.pro:
4089         * WebCore.xcodeproj/project.pbxproj:
4090         * bindings/js/JSHTMLElementWrapperFactory.cpp:
4091         (WebCore::createJSHTMLWrapper):
4092         * bindings/js/kjs_html.cpp:
4093         (KJS::):
4094         (KJS::JSHTMLElement::classInfo):
4095         (KJS::JSHTMLElement::accessors):
4096         (KJS::HTMLElementFunction::callAsFunction):
4097         * bindings/js/kjs_html.h:
4098         (KJS::JSHTMLElement::):
4099         * html/HTMLTableCaptionElement.idl:
4100         * html/HTMLTableCellElement.idl:
4101         * html/HTMLTableColElement.idl:
4102         * html/HTMLTableElement.idl:
4103         * html/HTMLTableRowElement.idl:
4104         * html/HTMLTableSectionElement.idl:
4105         * page/DOMWindow.idl:
4106
4107 2007-05-18  Oliver Hunt  <oliver@apple.com>
4108
4109         Reviewed by Sam.
4110
4111         Fix for <rdar://problem/5211122> DRT crash below
4112         SVGTimer::applyAnimations when page cache is enabled 
4113         (SVG animation timers do not properly cancel themselves)
4114
4115         There were still a few paths in the SVG Animation code
4116         that could cause timers to be created and used.  This 
4117         patch inserts addition SVG_EXPERIMENTAL blocks to prevent
4118         these timers from being used.
4119
4120         * ksvg2/misc/SVGDocumentExtensions.cpp:
4121         (WebCore::SVGDocumentExtensions::startAnimations):
4122         * ksvg2/misc/SVGTimer.cpp:
4123         (WebCore::SVGTimer::animationsByElement):
4124         (WebCore::SVGTimer::applyAnimations):
4125         (WebCore::SVGTimer::notifyAll):
4126         (WebCore::SVGTimer::addNotify):
4127         (WebCore::SVGTimer::removeNotify):
4128         * ksvg2/misc/TimeScheduler.cpp:
4129         (WebCore::TimeScheduler::addTimer):
4130         (WebCore::TimeScheduler::connectIntervalTimer):
4131         (WebCore::TimeScheduler::disconnectIntervalTimer):
4132         (WebCore::TimeScheduler::startAnimations):
4133         (WebCore::TimeScheduler::toggleAnimations):
4134         (WebCore::TimeScheduler::timerFired):
4135         * ksvg2/svg/SVGAnimationElement.h:
4136
4137 2007-05-18  Marius Bugge Monsen <mbm@trolltech.com>
4138
4139         Reviewed by Zack Rusin. 
4140
4141         Return a valid pointer to a Clipboard object
4142         from newGeneralClipboard. 
4143
4144         * editing/qt/EditorQt.cpp:
4145         (WebCore::Editor::newGeneralClipboard):
4146
4147 2007-05-18  Mark Rowe  <mrowe@apple.com>
4148
4149         Attempt to fix the Gdk build after r21562.
4150
4151         * platform/gdk/TemporaryLinkStubs.cpp:
4152         (Widget::isEnabled):
4153         * platform/gdk/WidgetGdk.cpp:
4154
4155 2007-05-18  Adam Treat <treat@kde.org>
4156
4157         Reviewed by Lars
4158
4159         Remove dead code.
4160
4161         * platform/Widget.h:
4162         * platform/mac/WidgetMac.mm:
4163         * platform/qt/WidgetQt.cpp:
4164
4165 2007-05-18  Holger Freyther  <zecke@selfish.org>
4166
4167         Reviewed by Maciej.
4168
4169         Return true to make loading of pages working again
4170
4171         * loader/gdk/FrameLoaderClientGdk.cpp:
4172         (WebCore::FrameLoaderClientGdk::canHandleRequest):
4173
4174 2007-05-18  Holger Freyther  <zecke@selfish.org>
4175
4176         Reviewed by Maciej.
4177
4178         Make WebCore::Widget use GtkWidget to fix focus handling.
4179
4180         * WebCore.pro: Add PlatformScrollBar
4181         * platform/ScrollView.h: Gtk stuff
4182         * platform/Widget.h: Take a GtkWidget
4183         * platform/gdk/PlatformScrollBarGdk.cpp: Added.
4184         (PlatformScrollbar::PlatformScrollbar):
4185         (PlatformScrollbar::~PlatformScrollbar):
4186         (PlatformScrollbar::width):
4187         (PlatformScrollbar::height):
4188         (PlatformScrollbar::setEnabled):
4189         (PlatformScrollbar::paint):
4190         (PlatformScrollbar::updateThumbPosition):
4191         (PlatformScrollbar::updateThumbProportion):
4192         (PlatformScrollbar::setRect):
4193         * platform/gdk/ScreenGdk.cpp: Implement depth handling
4194         (WebCore::screenDepth):
4195         * platform/gdk/ScrollViewGdk.cpp: use setGtkWidget, not setDrawable
4196         (WebCore::ScrollView::setGtkWidget):
4197         * platform/gdk/TemporaryLinkStubs.cpp:
4198         * platform/gdk/WidgetGdk.cpp:
4199         (WebCore::Widget::Widget):
4200         (WebCore::Widget::gtkWidget):
4201         (WebCore::Widget::setGtkWidget):
4202         (WebCore::Widget::hasFocus):
4203         (WebCore::Widget::setFocus):
4204
4205 2007-05-18  Lars Knoll  <lars@trolltech.com>
4206
4207         Reviewed by Zack
4208
4209         Correctly implement initialiseSupportedImageMIMETypes.
4210
4211         * platform/MimeTypeRegistry.cpp:
4212         (WebCore::initialiseSupportedImageMIMETypes):
4213         * platform/qt/MimeTypeRegistryQt.cpp:
4214         (WebCore::):
4215
4216 2007-05-18  Holger Hans Peter Freyther  <zecke@selfish.org>
4217
4218         Reviewed by Maciej.
4219
4220         Build fix for non-Qt and non-Mac ports.
4221
4222         * html/HTMLCanvasElement.h:
4223
4224 2007-05-18  Holger Hans Peter Freyther  <zecke@selfish.org>
4225
4226         Reviewed by Mark Rowe.
4227
4228         No test added as this is hard to time.
4229
4230         * platform/gdk/FrameGdk.cpp: Use needsLayout() to decide if layout()
4231         is needed.
4232
4233         (WebCore::FrameGdk::dumpRenderTree):
4234         (WebCore::FrameGdk::handleGdkEvent):
4235
4236 2007-05-18  Simon Hausmann  <hausmann@kde.org>
4237
4238         Reviewed by Lars.
4239
4240         * WebCore.pro: Create a pkg-config file to make it easier to locate
4241         and use WebKitQt.
4242
4243 2007-05-18  Lars Knoll <lars@trolltech.com>
4244
4245         Reviewed by Hyatt.
4246
4247         Remove unused handleMouseEvent methods in the Widget
4248         and derived classes.
4249
4250         * page/EventHandler.cpp:
4251         (WebCore::EventHandler::handleMouseMoveEvent):
4252         * page/FrameView.cpp:
4253         * page/FrameView.h:
4254         * page/mac/EventHandlerMac.mm:
4255         (WebCore::EventHandler::mouseDragged):
4256         (WebCore::EventHandler::mouseMoved):
4257         * platform/ScrollBar.h:
4258         * platform/Widget.h:
4259         * platform/win/PlatformScrollBar.h:
4260         * platform/win/TemporaryLinkStubs.cpp:
4261         (WebCore::PlatformScrollbar::setRect):