Fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=7223
[WebKit-https.git] / WebCore / ChangeLog
1 2006-03-21  Beth Dakin  <bdakin@apple.com>
2
3         Reviewed by Maciej
4
5         Fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=7223 
6         Reproducible crash when tabbing to a frame that has not been loaded
7
8         * bridge/mac/FrameMac.mm:
9         (WebCore::FrameMac::nextKeyViewInFrame): When a renderer doesn't 
10         have a widget, skip it in the focus loop.
11
12 2006-03-20  Eric Seidel  <eseidel@apple.com>
13
14         Reviewed by mjs.
15
16         Fix a unsafe static cast causing intermittent crashes.
17         <rdar://problem/4411663> crash at KXMLCore::RefPtr<WebCore::DOMStringImpl>::get() const + 20 (RefPtr.h:45)
18
19         Test: fast/dom/NodeList/item-by-id-with-no-document.html
20
21         * dom/NodeList.cpp:
22         (WebCore::NodeList::itemById): fix unsafe static cast.
23
24 2006-03-20  Maciej Stachowiak  <mjs@apple.com>
25
26         - touch this file in hopes of fixing build
27
28         * bindings/js/JSDOMCore.cpp:
29
30 2006-03-20  Maciej Stachowiak  <mjs@apple.com>
31
32         Reviewed by Anders.
33         
34         - fixed <rdar://problem/4446749> 10.4.4: safari crash in DOM::NamedAttrMapImpl::setNamedItem
35
36         * bindings/scripts/CodeGeneratorJS.pm: Add a framework for typechecking method
37         arguments. For now only use it for parameters of type Attr.
38         * dom/Element.idl: Arbitrary change to make it regenerate.
39         * dom/dom_elementimpl.cpp:
40         (WebCore::Element::setAttributeNode): ASSERT that attr is not null
41         * khtml/ecma/kjs_dom.cpp:
42         (KJS::toAttr): add bool ok parameter
43         * khtml/ecma/kjs_dom.h:
44
45 2006-03-20  Eric Seidel  <eseidel@apple.com>
46
47         * ksvg2/css/SVGCSSParser.h: Removed unused file.
48
49 2006-03-20  Eric Seidel  <eseidel@apple.com>
50
51         Reviewed by mjs.
52
53         Fix tokenizer crash when document.open() is called from an external script:
54         <rdar://problem/4483882> REGRESSION (417.8-TOT): crash at yourmovies.com.au in WebCore::HTMLTokenizer::reset() + 92 (7818)
55
56         * dom/Document.cpp:
57         (WebCore::Document::open): Check to make sure the current tokenizer isn't executing a script
58         * dom/xml_tokenizer.h:
59         (WebCore::Tokenizer::executingScript): Add a way for others to know if scripts are executing.
60         * html/HTMLTokenizer.cpp:
61         (WebCore::HTMLTokenizer::scriptExecution): Wire into existing m_executingScript member var.
62         * html/HTMLTokenizer.h:
63         (WebCore::HTMLTokenizer::executingScript):
64         * kcanvas/device/quartz/KCanvasFilterQuartz.mm:
65         (WebCore::KCanvasFilterQuartz::prepareFilter): Unrelated code cleanup.
66
67 2006-03-20  Justin Garcia  <justin.garcia@apple.com>
68
69         Reviewed by darin
70         
71         <rdar://problem/3997958> 
72         REGRESSION (Mail): Mail takes half of forever to paste >1500 lines - replaceSelectionWithNode
73
74         * dom/Position.cpp:
75         (WebCore::Position::upstream): Avoid calling previous() when we know that 
76         it will 1) end the search and 2) be expensive to compute.
77         (WebCore::Position::downstream): Removed some dead code.
78         (WebCore::Position::inRenderedText): Return false for offsets inside composed characters.
79         * dom/Position.h:
80         * editing/VisiblePosition.cpp:
81         (WebCore::VisiblePosition::init): If there are two visually equivalent candidates, we choose
82         the one that occurs first in document order.  Using upstream() to find the one that occurs first is
83         much faster than the old code.
84
85 2006-03-20  Eric Seidel  <eseidel@apple.com>
86
87         Reviewed by adele & ggaren.
88
89         Added new cachePluginDataIfNecessary function to update
90         plugins and mimes arrays.  Made sure to call this in
91         constructor as well as refresh.  The crash was caused by
92         a refresh rendering a "plugins" object invalid.
93         Changed existing test case to depend on this new correct behavior.
94         
95         <rdar://problem/4480571> Safari crashed at exit at KXMLCore::deleteAllValues + 24
96
97         * khtml/ecma/kjs_navigator.cpp:
98         (KJS::PluginBase::cachePluginDataIfNecessary):
99         (KJS::PluginBase::PluginBase):
100         (KJS::PluginBase::~PluginBase):
101         (KJS::PluginBase::refresh):
102
103 2006-03-20  Adele Peterson  <adele@apple.com>
104
105         Reviewed by Justin.
106
107         * rendering/RenderTextField.cpp: (WebCore::RenderTextField::visiblePositionForIndex):
108         When calculating the VisiblePosition for the first position in the text field, it
109         makes more sense for the position to have a downstream affinity.
110
111 2006-03-20  Maciej Stachowiak  <mjs@apple.com>
112
113         Reviewed by Adele.
114         
115         <rdar://problem/4362396> REGRESSION: (417-420) stopPropagation is not working for click event listener (onclick works fine)
116
117         * dom/EventTargetNode.cpp:
118         (WebCore::EventTargetNode::dispatchGenericEvent): make sure to fire capturing listeners
119         as well as bubbling ones on the target.
120
121 2006-03-20  Maciej Stachowiak  <mjs@apple.com>
122
123         Reviewed by Darin.
124         
125         <rdar://problem/4458568> WebCore should not disclose https referrers
126
127         * bridge/mac/WebCoreFrameBridge.mm:
128         (-[WebCoreFrameBridge canLoadURL:fromReferrer:hideReferrer:]):
129         Don't send https URLs as referrers to non-secure http sites.
130
131 2006-03-20  Darin Adler  <darin@apple.com>
132
133         Reviewed by Geoff.
134
135         - http://bugzilla.opendarwin.org/show_bug.cgi?id=7867
136           get rid of macro hacks for DOM, KDOM, KSVG, khtml, DOMString, QString
137
138         * config.h: Remove the defines for DOM, KDOM, KSVG, khtml, DOMString, QString,
139         and qstring().
140
141         * WebCore.xcodeproj/project.pbxproj: Pass in WebCore instead of KSVG as the
142         namespace for SVG names.
143         * ksvg2/scripts/make_names.pl: Made a couple changes to trick the SVG names into
144         recompiling, since they are in a different namespace now.
145
146         * ForwardingHeaders/kjs/identifier.h: Added.
147
148         * dom/PlatformWheelEvent.idl: Removed.
149         * dom/WheelEvent.idl: Added. This file was renamed by accident.
150
151         * bindings/js/JSDOMCore.cpp:
152         * bindings/js/JSDOMEvents.cpp:
153         * bindings/js/JSDOMHTML.cpp:
154         * dom/Attr.idl:
155         * dom/CharacterData.idl:
156         * dom/DOMImplementation.idl:
157         * dom/DocumentType.idl:
158         * dom/Element.idl:
159         * dom/Entity.idl:
160         * dom/MutationEvent.idl:
161         * dom/Notation.idl:
162         * dom/ProcessingInstruction.idl:
163         * dom/Text.idl:
164         * html/CanvasGradient.idl:
165         * html/CanvasPattern.idl:
166         * html/CanvasRenderingContext2D.idl:
167         Touched, to get CodeGeneratorJS.pm changes to take effect.
168  
169         * css/CSSGrammar.y:
170         * css/css_valueimpl.cpp: (WebCore::propertyID):
171         Changed calls to get CSS property values to use an explicit SVG:: namespace,
172         to match what the script writes out.
173
174         * khtml/ecma/kjs_binding.h: Added forward declaration of WebCore::String.
175
176         * ksvg2/scripts/cssmakeget rid of macro hacks for DOM, KDOM, KSVG, khtml, DOMString, QString
177           props: Made this compile with warnings and strict turned on.
178         Really just a trick to get properties to recompile, which turned out to be unneeded.
179         * ksvg2/scripts/cssmakevalues: Ditto.
180
181         * ksvg2/svg/SVGAElement.cpp:
182         (SVGAElement::parseMappedAttribute):
183         (SVGAElement::defaultEventHandler):
184         * ksvg2/svg/SVGAnimateTransformElement.cpp:
185         (SVGAnimateTransformElement::parseMappedAttribute):
186         * ksvg2/svg/SVGAnimationElement.cpp:
187         (SVGAnimationElement::parseMappedAttribute):
188         * ksvg2/svg/SVGClipPathElement.cpp:
189         (SVGClipPathElement::parseMappedAttribute):
190         * ksvg2/svg/SVGComponentTransferFunctionElement.cpp:
191         (SVGComponentTransferFunctionElement::parseMappedAttribute):
192         * ksvg2/svg/SVGExternalResourcesRequired.cpp:
193         (SVGExternalResourcesRequired::parseMappedAttribute):
194         * ksvg2/svg/SVGFEBlendElement.cpp:
195         (SVGFEBlendElement::parseMappedAttribute):
196         * ksvg2/svg/SVGFEColorMatrixElement.cpp:
197         (SVGFEColorMatrixElement::parseMappedAttribute):
198         * ksvg2/svg/SVGFEComponentTransferElement.cpp:
199         (SVGFEComponentTransferElement::parseMappedAttribute):
200         * ksvg2/svg/SVGFECompositeElement.cpp:
201         (SVGFECompositeElement::parseMappedAttribute):
202         * ksvg2/svg/SVGFEDiffuseLightingElement.cpp:
203         (WebCore::SVGFEDiffuseLightingElement::parseMappedAttribute):
204         * ksvg2/svg/SVGFEDisplacementMapElement.cpp:
205         (SVGFEDisplacementMapElement::SVGFEDisplacementMapElement):
206         (SVGFEDisplacementMapElement::stringToChannel):
207         (SVGFEDisplacementMapElement::parseMappedAttribute):
208         (SVGFEDisplacementMapElement::filterEffect):
209         * ksvg2/svg/SVGFEDisplacementMapElement.h:
210         * ksvg2/svg/SVGFEFloodElement.cpp:
211         (SVGFEFloodElement::parseMappedAttribute):
212         * ksvg2/svg/SVGFEGaussianBlurElement.cpp:
213         (SVGFEGaussianBlurElement::parseMappedAttribute):
214         * ksvg2/svg/SVGFEImageElement.cpp:
215         (SVGFEImageElement::parseMappedAttribute):
216         * ksvg2/svg/SVGFELightElement.cpp:
217         (SVGFELightElement::parseMappedAttribute):
218         * ksvg2/svg/SVGFEMergeNodeElement.cpp:
219         (SVGFEMergeNodeElement::parseMappedAttribute):
220         * ksvg2/svg/SVGFEOffsetElement.cpp:
221         (SVGFEOffsetElement::parseMappedAttribute):
222         * ksvg2/svg/SVGFESpecularLightingElement.cpp:
223         (SVGFESpecularLightingElement::parseMappedAttribute):
224         * ksvg2/svg/SVGFETileElement.cpp:
225         (SVGFETileElement::parseMappedAttribute):
226         * ksvg2/svg/SVGFETurbulenceElement.cpp:
227         (SVGFETurbulenceElement::parseMappedAttribute):
228         * ksvg2/svg/SVGFilterElement.cpp:
229         (SVGFilterElement::parseMappedAttribute):
230         * ksvg2/svg/SVGGradientElement.cpp:
231         (SVGGradientElement::parseMappedAttribute):
232         * ksvg2/svg/SVGMaskElement.cpp:
233         (WebCore::SVGMaskElement::parseMappedAttribute):
234         * ksvg2/svg/SVGPolyElement.cpp:
235         (SVGPolyElement::parseMappedAttribute):
236         * ksvg2/svg/SVGStopElement.cpp:
237         (SVGStopElement::parseMappedAttribute):
238         * ksvg2/svg/SVGStyledElement.cpp:
239         (WebCore::SVGStyledElement::parseMappedAttribute):
240         * ksvg2/svg/SVGTests.cpp:
241         (WebCore::SVGTests::parseMappedAttribute):
242         * ksvg2/svg/SVGTextContentElement.cpp:
243         (SVGTextContentElement::parseMappedAttribute):
244         * ksvg2/svg/SVGTextPositioningElement.cpp:
245         (SVGTextPositioningElement::parseMappedAttribute):
246         * ksvg2/svg/SVGViewElement.cpp:
247         (SVGViewElement::parseMappedAttribute):
248         * ksvg2/svg/SVGZoomAndPan.cpp:
249         (SVGZoomAndPan::parseMappedAttribute):
250         Changed code that converts an AtomicString to a String to do it in a
251         more-efficient fashion that works even with all the new conversions.
252
253         * page/Frame.cpp:
254         (WebCore::getString): Removed unneeded .deprecatedString().
255         (WebCore::Frame::begin): Removed the only use of QSTRING_NULL.
256
257         * platform/AtomicString.h: Added conversion to and from KJS::Identifier
258         and KJS::UString.
259         * platform/AtomicString.cpp:
260         (WebCore::AtomicString::add): Added overloads for Identifier and UString.
261         (WebCore::AtomicString::operator Identifier): Added.
262         (WebCore::AtomicString::operator UString): Added.
263
264         * platform/DeprecatedString.h: Added conversion to and from KJS::Identifier
265         and KJS::UString.
266         * platform/DeprecatedString.cpp:
267         (DeprecatedString::DeprecatedString): Added overloads for Identifier and UString.
268         (DeprecatedString::operator Identifier): Added.
269         (DeprecatedString::operator UString): Added.
270
271         * platform/PlatformString.h: Added conversion to and from KJS::Identifier
272         and KJS::UString.
273         * platform/String.cpp:
274         (WebCore::String::String): Added overloads for Identifier and UString.
275         (WebCore::String::operator Identifier): Added.
276         (WebCore::String::operator UString): Added.
277
278         * platform/StringImpl.h: Added constructors that take KJS::Identifier
279         and KJS::UString
280         * platform/StringImpl.cpp:
281         (WebCore::getWordBreakIterator): Changed a use of UChar to say ::UChar
282         instead because of ambiguity with KJS::UChar.
283         (WebCore::StringImpl::StringImpl): Added overloads for Identifier and String.
284
285         * bindings/js/JSCanvasRenderingContext2DBase.cpp:
286         (WebCore::JSCanvasRenderingContext2DBaseProtoFunc::callAsFunction):
287         (WebCore::toHTMLCanvasStyle):
288         * bindings/scripts/CodeGeneratorJS.pm:
289         * bridge/mac/WebCoreFrameBridge.mm:
290         (aeDescFromJSValue):
291         (-[WebCoreFrameBridge stringByEvaluatingJavaScriptFromString:forceUserGesture:]):
292         * dom/QualifiedName.cpp:
293         (WebCore::QualifiedName::toString):
294         * khtml/ecma/JSDOMParser.cpp:
295         (KJS::DOMParserProtoFunc::callAsFunction):
296         * khtml/ecma/JSXMLHttpRequest.cpp:
297         (KJS::JSXMLHttpRequestProtoFunc::callAsFunction):
298         * khtml/ecma/JSXSLTProcessor.cpp:
299         (KJS::XSLTProcessorProtoFunc::callAsFunction):
300         * khtml/ecma/kjs_binding.cpp:
301         (KJS::valueToStringWithNullCheck):
302         * khtml/ecma/kjs_css.cpp:
303         (KJS::cssPropertyName):
304         (KJS::DOMCSSStyleDeclaration::put):
305         (KJS::DOMCSSStyleDeclarationProtoFunc::callAsFunction):
306         (KJS::DOMStyleSheetList::nameGetter):
307         (KJS::DOMStyleSheetList::getOwnPropertySlot):
308         (KJS::DOMMediaList::put):
309         (KJS::KJS::DOMMediaListProtoFunc::callAsFunction):
310         (KJS::DOMCSSStyleSheetProtoFunc::callAsFunction):
311         (KJS::DOMCSSRule::putValueProperty):
312         (KJS::DOMCSSRuleFunc::callAsFunction):
313         (KJS::DOMCSSValue::put):
314         (KJS::DOMCSSPrimitiveValueProtoFunc::callAsFunction):
315         * khtml/ecma/kjs_dom.cpp:
316         (KJS::DOMNode::putValueProperty):
317         (KJS::DOMNode::toString):
318         (KJS::DOMNodeProtoFunc::callAsFunction):
319         (KJS::DOMEventTargetNodeProtoFunc::callAsFunction):
320         (KJS::DOMNodeList::nameGetter):
321         (KJS::DOMNodeList::getOwnPropertySlot):
322         (KJS::DOMDocument::putValueProperty):
323         (KJS::DOMDocumentProtoFunc::callAsFunction):
324         (KJS::DOMElement::attributeGetter):
325         (KJS::DOMElement::getOwnPropertySlot):
326         (KJS::DOMNamedNodeMap::nameGetter):
327         (KJS::DOMNamedNodeMap::getOwnPropertySlot):
328         (KJS::DOMNamedNodeMapProtoFunc::callAsFunction):
329         (KJS::DOMNamedNodesCollection::getOwnPropertySlot):
330         * khtml/ecma/kjs_events.cpp:
331         (KJS::JSAbstractEventListener::handleEvent):
332         (KJS::DOMEvent::getValueProperty):
333         (KJS::DOMEventProtoFunc::callAsFunction):
334         (KJS::DOMUIEventProtoFunc::callAsFunction):
335         (KJS::DOMMouseEventProtoFunc::callAsFunction):
336         (KJS::DOMKeyboardEventProtoFunc::callAsFunction):
337         (KJS::Clipboard::putValueProperty):
338         (KJS::ClipboardProtoFunc::callAsFunction):
339         * khtml/ecma/kjs_html.cpp:
340         (KJS::HTMLDocFunction::callAsFunction):
341         (KJS::JSHTMLDocument::namedItemGetter):
342         (KJS::JSHTMLDocument::getOwnPropertySlot):
343         (KJS::JSHTMLDocument::putValueProperty):
344         (KJS::JSHTMLElement::framesetNameGetter):
345         (KJS::JSHTMLElement::getOwnPropertySlot):
346         (KJS::HTMLElementFunction::callAsFunction):
347         (KJS::JSHTMLElement::putValueProperty):
348         (KJS::JSHTMLCollection::callAsFunction):
349         (KJS::JSHTMLCollection::getNamedItems):
350         (KJS::HTMLCollectionProtoFunc::callAsFunction):
351         (KJS::OptionConstructorImp::construct):
352         * khtml/ecma/kjs_navigator.cpp:
353         (KJS::Plugins::nameGetter):
354         (KJS::Plugins::getOwnPropertySlot):
355         (KJS::MimeTypes::nameGetter):
356         (KJS::MimeTypes::getOwnPropertySlot):
357         (KJS::Plugin::nameGetter):
358         (KJS::Plugin::getOwnPropertySlot):
359         * khtml/ecma/kjs_proxy.cpp:
360         (WebCore::KJSProxy::evaluate):
361         * khtml/ecma/kjs_range.cpp:
362         (KJS::DOMRangeProtoFunc::callAsFunction):
363         * khtml/ecma/kjs_views.cpp:
364         (KJS::DOMAbstractViewProtoFunc::callAsFunction):
365         * khtml/ecma/kjs_window.cpp:
366         (KJS::parseModalDialogFeatures):
367         (KJS::showModalDialog):
368         (KJS::Window::childFrameGetter):
369         (KJS::Window::namedFrameGetter):
370         (KJS::Window::namedItemGetter):
371         (KJS::Window::getOwnPropertySlot):
372         (KJS::Window::put):
373         (KJS::WindowFunc::callAsFunction):
374         (KJS::ScheduledAction::execute):
375         (KJS::Window::installTimeout):
376         (KJS::FrameArray::nameGetter):
377         (KJS::FrameArray::getOwnPropertySlot):
378         (KJS::Location::put):
379         (KJS::LocationFunc::callAsFunction):
380         (KJS::SelectionFunc::callAsFunction):
381         Removed explicit calls to domString(), sometimes replacing with explicit calls to the
382         String() constructor. Other similar changes for AtomicString and DeprecatedString use.
383
384 2006-03-20  Eric Seidel  <eseidel@apple.com>
385
386         Reviewed by darin.
387
388         Remove many, many uses of DeprecatedString.
389         Fix various style issues throughout the touched code.
390
391         * bindings/objc/DOM.mm:
392         (-[DOMRange _text]):
393         * bridge/mac/BrowserExtensionMac.mm:
394         (WebCore::BrowserExtensionMac::createNewWindow):
395         * bridge/mac/FrameMac.h:
396         (WebCore::FrameMac::bridge):
397         (WebCore::FrameMac::markedTextRange):
398         (WebCore::Mac):
399         * bridge/mac/FrameMac.mm:
400         (WebCore::FrameMac::openURLRequest):
401         (WebCore::FrameMac::searchForLabelsAboveCell):
402         (WebCore::FrameMac::searchForLabelsBeforeElement):
403         (WebCore::FrameMac::matchLabelsAgainstElement):
404         (WebCore::FrameMac::findString):
405         (WebCore::FrameMac::submitForm):
406         (WebCore::FrameMac::urlSelected):
407         (WebCore::FrameMac::objectContentType):
408         (WebCore::FrameMac::createPlugin):
409         (WebCore::FrameMac::createFrame):
410         (WebCore::FrameMac::setTitle):
411         (WebCore::FrameMac::setStatusBarText):
412         (WebCore::FrameMac::advanceToNextMisspelling):
413         (WebCore::FrameMac::userAgent):
414         (WebCore::FrameMac::mimeTypeForFileName):
415         (WebCore::FrameMac::openURLFromPageCache):
416         (WebCore::FrameMac::incomingReferrer):
417         (WebCore::FrameMac::attributedString):
418         (WebCore::FrameMac::overrideMediaType):
419         (WebCore::FrameMac::shouldClose):
420         * bridge/mac/WebCoreFrameBridge.mm:
421         (-[WebCoreFrameBridge _documentTypeString]):
422         (-[WebCoreFrameBridge selectedString]):
423         (-[WebCoreFrameBridge stringForRange:]):
424         (-[WebCoreFrameBridge advanceToNextMisspelling]):
425         (-[WebCoreFrameBridge advanceToNextMisspellingStartingJustBeforeSelection]):
426         (-[WebCoreFrameBridge domain]):
427         * bridge/mac/WebCoreSettings.mm:
428         (-[WebCoreSettings setStandardFontFamily:]):
429         (-[WebCoreSettings setFixedFontFamily:]):
430         (-[WebCoreSettings setSerifFontFamily:]):
431         (-[WebCoreSettings setSansSerifFontFamily:]):
432         (-[WebCoreSettings setCursiveFontFamily:]):
433         (-[WebCoreSettings setFantasyFontFamily:]):
434         (-[WebCoreSettings setUserStyleSheetLocation:]):
435         (-[WebCoreSettings setDefaultTextEncoding:]):
436         * css/css_valueimpl.cpp:
437         (WebCore::quoteStringIfNeeded):
438         * css/cssstyleselector.cpp:
439         (WebCore::CSSStyleSelector::CSSStyleSelector):
440         (WebCore::CSSStyleSelector::setEncodedURL):
441         (WebCore::cleanpath):
442         (WebCore::checkPseudoState):
443         (WebCore::CSSStyleSelector::styleForElement):
444         (WebCore::CSSStyleSelector::styleRulesForElement):
445         (WebCore::convertToLength):
446         (WebCore::colorForCSSValue):
447         (WebCore::CSSStyleSelector::applyProperty):
448         (WebCore::CSSStyleSelector::getColorFromPrimitiveValue):
449         * css/cssstyleselector.h:
450         * dom/CDATASection.cpp:
451         (WebCore::CDATASection::toString):
452         * dom/Document.cpp:
453         (WebCore::Document::recalcStyle):
454         * dom/Document.h:
455         (WebCore::Document::baseTarget):
456         (WebCore::Document::setBaseTarget):
457         * dom/dom_elementimpl.cpp:
458         (WebCore::Element::openTagStartToString):
459         * dom/xml_tokenizer.cpp:
460         (WebCore::handleElementAttributes):
461         (WebCore::XMLTokenizer::startElementNs):
462         * editing/SelectionController.cpp:
463         (WebCore::SelectionController::type):
464         * editing/TextIterator.cpp:
465         (WebCore::TextIterator::advance):
466         (WebCore::TextIterator::handleTextBox):
467         (WebCore::TextIterator::handleNonTextNode):
468         (WebCore::TextIterator::exitNode):
469         (WebCore::SimplifiedBackwardsTextIterator::advance):
470         (WebCore::SimplifiedBackwardsTextIterator::handleTextNode):
471         (WebCore::CharacterIterator::advance):
472         (WebCore::WordAwareIterator::advance):
473         (WebCore::WordAwareIterator::length):
474         (WebCore::WordAwareIterator::characters):
475         (WebCore::CircularSearchBuffer::CircularSearchBuffer):
476         (WebCore::CircularSearchBuffer::append):
477         (WebCore::TextIterator::rangeFromLocationAndLength):
478         (WebCore::findPlainText):
479         * editing/TextIterator.h:
480         * html/HTMLFormElement.cpp:
481         (WebCore::HTMLFormElement::formData):
482         * khtml/ecma/kjs_navigator.cpp:
483         (KJS::Navigator::getValueProperty):
484         * khtml/ecma/kjs_proxy.cpp:
485         (WebCore::KJSProxy::initScriptIfNeeded):
486         * khtml/ecma/kjs_window.cpp:
487         (KJS::Location::getValueProperty):
488         * ksvg2/misc/KCanvasRenderingStyle.cpp:
489         (WebCore::KSVGPainterFactory::fillPaintServer):
490         (WebCore::KSVGPainterFactory::strokePaintServer):
491         * ksvg2/svg/SVGAngle.cpp:
492         (SVGAngle::calculate):
493         (SVGAngle::setValueAsString):
494         (SVGAngle::valueAsString):
495         (SVGAngle::convertToSpecifiedUnits):
496         (SVGAngle::shortestArcBisector):
497         * ksvg2/svg/SVGAngle.h:
498         * ksvg2/svg/SVGAnimationElement.cpp:
499         (SVGAnimationElement::targetElement):
500         (SVGAnimationElement::parseMappedAttribute):
501         (SVGAnimationElement::parseClockValue):
502         (SVGAnimationElement::targetAttribute):
503         (SVGAnimationElement::setTargetAttribute):
504         (SVGAnimationElement::detectAnimationMode):
505         (SVGAnimationElement::calculateCurrentValueItem):
506         (SVGAnimationElement::calculateRelativeTimePercentage):
507         * ksvg2/svg/SVGColor.cpp:
508         (SVGColor::setRGBColor):
509         * ksvg2/svg/SVGDOMImplementation.cpp:
510         (svgFeatureSet):
511         (SVGDOMImplementation::self):
512         (SVGDOMImplementation::hasFeature):
513         (SVGDOMImplementation::createDocumentType):
514         (SVGDOMImplementation::createDocument):
515         * ksvg2/svg/SVGDOMImplementation.h:
516         * ksvg2/svg/SVGPaint.cpp:
517         (SVGPaint::cssText):
518         * ksvg2/svg/SVGPathSegClosePath.h:
519         (WebCore::SVGPathSegClosePath::toString):
520         * ksvg2/svg/SVGPreserveAspectRatio.cpp:
521         (SVGPreserveAspectRatio::parsePreserveAspectRatio):
522         (SVGPreserveAspectRatio::getCTM):
523         * ksvg2/svg/SVGStopElement.cpp:
524         (SVGStopElement::parseMappedAttribute):
525         * ksvg2/svg/SVGStyleElement.cpp:
526         (SVGStyleElement::childrenChanged):
527         * ksvg2/svg/SVGURIReference.cpp:
528         (SVGURIReference::getTarget):
529         * kwq/ClipboardMac.mm:
530         (WebCore::ClipboardMac::setData):
531         (WebCore::ClipboardMac::types):
532         (WebCore::ClipboardMac::setEffectAllowed):
533         (WebCore::cocoaOpFromIEOp):
534         (WebCore::IEOpFromCocoaOp):
535         (WebCore::ClipboardMac::sourceOperation):
536         (WebCore::ClipboardMac::destinationOperation):
537         * kwq/KWQCString.cpp:
538         (DeprecatedCString::append):
539         * kwq/KWQKHTMLSettings.h:
540         (KHTMLSettings::stdFontName):
541         (KHTMLSettings::fixedFontName):
542         (KHTMLSettings::serifFontName):
543         (KHTMLSettings::sansSerifFontName):
544         (KHTMLSettings::cursiveFontName):
545         (KHTMLSettings::fantasyFontName):
546         (KHTMLSettings::minFontSize):
547         (KHTMLSettings::minLogicalFontSize):
548         (KHTMLSettings::mediumFontSize):
549         (KHTMLSettings::mediumFixedFontSize):
550         (KHTMLSettings::autoLoadImages):
551         (KHTMLSettings::isJavaScriptEnabled):
552         (KHTMLSettings::JavaScriptCanOpenWindowsAutomatically):
553         (KHTMLSettings::isJavaEnabled):
554         (KHTMLSettings::isPluginsEnabled):
555         (KHTMLSettings::encoding):
556         (KHTMLSettings::userStyleSheet):
557         (KHTMLSettings::shouldPrintBackgrounds):
558         (KHTMLSettings::textAreasAreResizable):
559         (KHTMLSettings::setStdFontName):
560         (KHTMLSettings::setFixedFontName):
561         (KHTMLSettings::setSerifFontName):
562         (KHTMLSettings::setSansSerifFontName):
563         (KHTMLSettings::setCursiveFontName):
564         (KHTMLSettings::setFantasyFontName):
565         (KHTMLSettings::setMinFontSize):
566         (KHTMLSettings::setMinLogicalFontSize):
567         (KHTMLSettings::setMediumFontSize):
568         (KHTMLSettings::setMediumFixedFontSize):
569         (KHTMLSettings::setAutoLoadImages):
570         (KHTMLSettings::setIsJavaScriptEnabled):
571         (KHTMLSettings::setIsJavaEnabled):
572         (KHTMLSettings::setArePluginsEnabled):
573         (KHTMLSettings::setJavaScriptCanOpenWindowsAutomatically):
574         (KHTMLSettings::setEncoding):
575         (KHTMLSettings::setUserStyleSheet):
576         (KHTMLSettings::setShouldPrintBackgrounds):
577         (KHTMLSettings::setTextAreasAreResizable):
578         * kwq/KWQLoader.mm:
579         (KWQServeSynchronousRequest):
580         * kwq/KWQTextStream.cpp:
581         (QTextStream::QTextStream):
582         (QTextStream::operator<<):
583         (QTextStream::precision):
584         * kwq/KWQTextStream.h:
585         * kwq/RenderTreeAsText.cpp:
586         (operator<<):
587         (quoteAndEscapeNonPrintables):
588         (writeTextRun):
589         (write):
590         (writeSelection):
591         * loader/Cache.cpp:
592         (WebCore::Cache::init):
593         (WebCore::Cache::requestImage):
594         (WebCore::Cache::requestStyleSheet):
595         (WebCore::Cache::preloadStyleSheet):
596         (WebCore::Cache::requestScript):
597         (WebCore::Cache::preloadScript):
598         (WebCore::Cache::requestXSLStyleSheet):
599         (WebCore::Cache::requestXBLDocument):
600         (WebCore::Cache::remove):
601         * loader/Cache.h:
602         * loader/CachedCSSStyleSheet.cpp:
603         (WebCore::CachedCSSStyleSheet::error):
604         * loader/CachedCSSStyleSheet.h:
605         * loader/CachedImage.cpp:
606         (WebCore::CachedImage::error):
607         * loader/CachedImage.h:
608         * loader/CachedObject.h:
609         * loader/CachedScript.cpp:
610         (WebCore::CachedScript::checkNotify):
611         (WebCore::CachedScript::error):
612         * loader/CachedScript.h:
613         * loader/CachedXBLDocument.cpp:
614         (WebCore::CachedXBLDocument::error):
615         * loader/CachedXBLDocument.h:
616         * loader/CachedXSLStyleSheet.cpp:
617         (WebCore::CachedXSLStyleSheet::error):
618         * loader/CachedXSLStyleSheet.h:
619         * loader/DocLoader.cpp:
620         (WebCore::DocLoader::DocLoader):
621         (WebCore::DocLoader::~DocLoader):
622         (WebCore::DocLoader::needReload):
623         (WebCore::DocLoader::requestImage):
624         (WebCore::DocLoader::requestStyleSheet):
625         (WebCore::DocLoader::requestScript):
626         (WebCore::DocLoader::requestXSLStyleSheet):
627         (WebCore::DocLoader::requestXBLDocument):
628         (WebCore::DocLoader::setAutoloadImages):
629         (WebCore::DocLoader::setShowAnimations):
630         (WebCore::DocLoader::removeCachedObject):
631         * loader/loader.cpp:
632         (WebCore::Loader::receivedAllData):
633         (WebCore::Loader::receivedResponse):
634         * page/Frame.cpp:
635         (WebCore::UserStyleSheetLoader::setStyleSheet):
636         (WebCore::Frame::didOpenURL):
637         (WebCore::Frame::setMetaRefreshEnabled):
638         (WebCore::Frame::setAutoloadImages):
639         (WebCore::Frame::autoloadImages):
640         (WebCore::Frame::clear):
641         (WebCore::Frame::receivedFirstData):
642         (WebCore::Frame::begin):
643         (WebCore::Frame::write):
644         (WebCore::Frame::baseTarget):
645         (WebCore::Frame::completeURL):
646         (WebCore::Frame::scheduleRedirection):
647         (WebCore::Frame::scheduleLocationChange):
648         (WebCore::Frame::scheduleHistoryNavigation):
649         (WebCore::Frame::changeLocation):
650         (WebCore::Frame::redirectionTimerFired):
651         (WebCore::Frame::encoding):
652         (WebCore::Frame::gotoAnchor):
653         (WebCore::Frame::setStandardFont):
654         (WebCore::Frame::setFixedFont):
655         (WebCore::Frame::selectedText):
656         (WebCore::Frame::selection):
657         (WebCore::Frame::dragCaret):
658         (WebCore::Frame::setSelection):
659         (WebCore::Frame::setDragCaret):
660         (WebCore::Frame::paintCaret):
661         (WebCore::Frame::paintDragCaret):
662         (WebCore::Frame::urlSelected):
663         (WebCore::Frame::requestFrame):
664         (WebCore::Frame::requestObject):
665         (WebCore::Frame::shouldUsePlugin):
666         (WebCore::Frame::loadPlugin):
667         (WebCore::Frame::loadSubframe):
668         (WebCore::Frame::submitForm):
669         (WebCore::Frame::lastModified):
670         (WebCore::Frame::reparseConfiguration):
671         (WebCore::Frame::shouldChangeSelection):
672         (WebCore::Frame::appliedEditing):
673         (WebCore::Frame::unappliedEditing):
674         (WebCore::Frame::reappliedEditing):
675         (WebCore::Frame::executeScript):
676         (WebCore::updateState):
677         (WebCore::Frame::isCharacterSmartReplaceExempt):
678         (WebCore::Frame::openURL):
679         (WebCore::Frame::didNotOpenURL):
680         (WebCore::Frame::setEncoding):
681         (WebCore::Frame::saveInterpreterBuiltins):
682         (WebCore::Frame::restoreInterpreterBuiltins):
683         (WebCore::Frame::mutableInstances):
684         (WebCore::Frame::setPolicyBaseURL):
685         (WebCore::Frame::addMetaData):
686         (WebCore::Frame::scrollToAnchor):
687         (WebCore::Frame::setMediaType):
688         (WebCore::Frame::highlightAllMatchesForString):
689         (WebCore::Frame::tree):
690         * page/Frame.h:
691         (WebCore::Frame::instances):
692         * page/FramePrivate.h:
693         * page/FrameView.cpp:
694         (WebCore::FrameViewPrivate::FrameViewPrivate):
695         (WebCore::FrameView::FrameView):
696         (WebCore::FrameView::~FrameView):
697         (WebCore::FrameView::init):
698         (WebCore::FrameView::setMarginWidth):
699         (WebCore::FrameView::setMarginHeight):
700         (WebCore::FrameView::adjustViewSize):
701         (WebCore::FrameView::layout):
702         (WebCore::FrameView::dispatchDragEvent):
703         (WebCore::FrameView::scrollTo):
704         (WebCore::FrameView::setMediaType):
705         (WebCore::FrameView::mediaType):
706         (WebCore::FrameView::setResizingFrameSet):
707         (WebCore::FrameView::setIgnoreWheelEvents):
708         * page/FrameView.h:
709         (WebCore::FrameView::frameWidth):
710         (WebCore::FrameView::marginWidth):
711         (WebCore::FrameView::marginHeight):
712         (WebCore::FrameView::ref):
713         (WebCore::FrameView::deref):
714         * page/ResourceRequest.h:
715         (WebCore::ResourceRequest::contentType):
716         (WebCore::ResourceRequest::setContentType):
717         * platform/FontFamily.h:
718         * platform/Image.h:
719         * platform/KURL.cpp:
720         (KURL::KURL):
721         (KURL::parse):
722         (urlcmp):
723         (KURL::encode_string):
724         (encodeHostname):
725         * platform/KURL.h:
726         * platform/PlatformString.h:
727         (WebCore::String::left):
728         (WebCore::String::right):
729         * platform/String.cpp:
730         (WebCore::String::toInt):
731         * platform/StringImpl.cpp:
732         (WebCore::StringImpl::toInt):
733         * platform/TransferJob.cpp:
734         (WebCore::TransferJob::queryMetaData):
735         (WebCore::TransferJob::addMetaData):
736         * platform/TransferJob.h:
737         * platform/mac/ImageMac.mm:
738         (WebCore::Image::supportsType):
739         * platform/mac/TransferJobMac.mm:
740         (WebCore::TransferJob::start):
741         * rendering/RenderObject.cpp:
742         (WebCore::RenderObject::information):
743         * rendering/RenderTextField.cpp:
744         (WebCore::RenderTextField::updateFromElement):
745         * xml/xmlhttprequest.cpp:
746         (WebCore::getMIMEType):
747         (WebCore::getCharset):
748         (WebCore::XMLHttpRequest::getReadyState):
749         (WebCore::XMLHttpRequest::getResponseText):
750         (WebCore::XMLHttpRequest::getResponseXML):
751         (WebCore::XMLHttpRequest::XMLHttpRequest):
752         (WebCore::XMLHttpRequest::~XMLHttpRequest):
753         (WebCore::XMLHttpRequest::changeState):
754         (WebCore::XMLHttpRequest::callReadyStateChangeListener):
755         (WebCore::XMLHttpRequest::urlMatchesDocumentDomain):
756         (WebCore::XMLHttpRequest::open):
757         (WebCore::XMLHttpRequest::send):
758         (WebCore::XMLHttpRequest::abort):
759         (WebCore::XMLHttpRequest::overrideMIMEType):
760         (WebCore::XMLHttpRequest::setRequestHeader):
761         (WebCore::XMLHttpRequest::getRequestHeader):
762         (WebCore::XMLHttpRequest::getAllResponseHeaders):
763         (WebCore::XMLHttpRequest::getResponseHeader):
764         (WebCore::XMLHttpRequest::responseIsXML):
765         (WebCore::XMLHttpRequest::getStatus):
766         (WebCore::XMLHttpRequest::getStatusText):
767         (WebCore::XMLHttpRequest::processSyncLoadResults):
768         (WebCore::XMLHttpRequest::receivedAllData):
769         (WebCore::XMLHttpRequest::receivedRedirect):
770         (WebCore::XMLHttpRequest::receivedData):
771         (WebCore::XMLHttpRequest::cancelRequests):
772         (WebCore::XMLHttpRequest::detachRequests):
773         * xml/xmlhttprequest.h:
774
775 2006-03-20  Alexey Proskuryakov  <ap@nypop.com>
776
777         Reviewed by Darin.
778
779         - http://bugzilla.opendarwin.org/show_bug.cgi?id=3439
780          mouseover effects can get stuck sometimes due to missing events
781         - http://bugzilla.opendarwin.org/show_bug.cgi?id=7701
782          mouseout sent to the wrong element when layout changes simultaneously
783         
784         Implemented saving the previous node under the mouse, so that we don't need to 
785         recalculate it, which is slow and even not really possible. This has fixed a number 
786         of issues with mouse event dispatching when the content changes.
787         The code still needs refactoring and cleanup, see bug 3439 for comments.
788
789         Tests (both files perform multiple checks):
790         - fast/events/mouseover-mouseout.html
791         - fast/events/mouseover-mouseout2.html
792
793         * page/Frame.h: Added a Frame parameter to passSubframeEventToSubframe(),
794         used for mouseMoved events.
795         * bridge/mac/FrameMac.h: Ditto.
796         * bridge/mac/FrameMac.mm: 
797         (WebCore::FrameMac::passSubframeEventToSubframe): Use the passed subframe to target 
798         NSMouseMoved events.
799         * page/FrameView.h: Added a prepareMouseEvent() helper that does viewportToContents translation.
800         * page/FrameView.cpp: Added data members for storing the previous node and subframe 
801         under the mouse to FrameViewPrivate. Removed the now unused prevMouseX/prevMouseY.
802         (WebCore::FrameViewPrivate::reset): Reset the new data members.
803         (WebCore::subframeForEvent): A temporary place for the code that extracts a subframe
804         pointer from MouseEventWithHitTestResults, moved from FrameMac::passSubframeEventToSubframe().
805         (WebCore::FrameView::prepareMouseEvent): The new helper.
806         (WebCore::FrameView::handleMousePressEvent): Use the new helper.
807         (WebCore::FrameView::handleMouseDoubleClickEvent): Ditto.
808         (WebCore::FrameView::handleMouseReleaseEvent): Ditto.
809         (WebCore::FrameView::updateDragAndDrop): Ditto.
810         (WebCore::FrameView::hoverTimerFired): Ditto.
811         (WebCore::FrameView::dispatchMouseEvent): Store and use the oldUnder node, don't store 
812         or use prevMouseX/Y.
813         (WebCore::FrameView::handleMouseMoveEvent): Rewrote dispatching events to subframes using 
814         a stored oldSubframe reference. Protect "this" from being removed while in this function.
815
816 2006-03-20  Darin Adler  <darin@apple.com>
817
818         Reviewed by Anders.
819
820         - http://bugzilla.opendarwin.org/show_bug.cgi?id=7875
821           autogenerate bindings for Range
822
823         * dom/Range.idl: Added.
824         * khtml/ecma/kjs_range.cpp: Removed.
825         * khtml/ecma/kjs_range.h: Removed.
826
827         * WebCore.vcproj/WebCore/build-generated-files.sh: Removed code to generate
828         kjs_range.lut.h.
829
830         * WebCore.xcodeproj/project.pbxproj: Added Range.idl source file.
831         Removed kjs_range.h and kjs_range.cpp source files. Sorted the "dom" group.
832         Removed rule to generate kjs_range.lut.h.
833
834         * bindings/js/JSDOMCore.cpp: Added include of JSRange.cpp.
835
836         * bindings/scripts/CodeGeneratorJS.pm: Added DocumentFragment, Range, CompareHow,
837         and short to the types this script can handle. Added code to generate toRange
838         functions and the like. Added separate code to handle exceptions for getters
839         vs. setters for attributes. Changed return values for the "bad ID" case to 0
840         -- there's no need to generate the extra code to return jsUndefined() in such
841         cases, which should be unreachable. Changed exception handling to use setDOMException
842         directly instead of DOMExceptionTranslator; DOMExceptionTranslator was a trick
843         to make it easier to convert existing bindings and shouldn't be used going
844         forward. Fixed names of constructors to use the JavaScript class name (the
845         interface name), not the name of the C++ implementation class. Fixed generation
846         of code for functions that have no parameters but do raise exceptions.
847
848         * bindings/scripts/IDLParser.pm: Added parsing for separate getter and setter
849         exceptions in attributes. The syntax is not real IDL, but real IDL doesn't support
850         declaring exceptions on attributes at all. We'll probably want to revisit our
851         syntax for this some day.
852
853         * bindings/scripts/IDLStructure.pm: Removed unused exceptionName field from
854         domAttribute, and replaced raisesExceptions field with getterExceptions and
855         setterExceptions. Added regular expressions for parsing getter/setter syntax.
856         We'll probably have to redo this whole thing parse in a better way at some
857         point -- the regular expressions allow any invalid syntax in between them.
858
859         * dom/Attr.idl: Change exception declaration for setting the value attribute
860         to use setter-specific exception syntax.
861         * dom/CharacterData.idl: Change exception declaration for setting the data
862         attribute to use setter-specific exception syntax.
863         * dom/ProcessingInstruction.idl: Change exception declaration for setting the
864         data attribute to use setter-specific exception syntax.
865
866         * khtml/ecma/kjs_dom.cpp: Include JSRange.h instead of kjs_range.h.
867         * khtml/ecma/kjs_window.cpp: Include JSRange.h instead of kjs_range.h.
868         (KJS::Window::getValueProperty): Use JSRange::getConstructor instead of
869         getRangeConstructor.
870
871 2006-03-20  Eric Seidel  <eseidel@apple.com>
872
873         Reviewed by hyatt.
874
875         Fix win32 compile.
876
877         * Viewer/ImageView.cpp:
878         * platform/GraphicsContext.cpp:
879         (WebCore::WebCore::GraphicsContext::createGraphicsContextPrivate):
880         (WebCore::WebCore::GraphicsContext::destroyGraphicsContextPrivate):
881         * platform/cairo/GraphicsContextCairo.cpp:
882         (WebCore::fillRectSourceOver):
883         (WebCore::GraphicsContext::drawLine):
884         (WebCore::GraphicsContext::drawFocusRing):
885         * platform/win/FontWin.cpp:
886         (WebCore::Font::drawHighlightForText):
887         (WebCore::Font::drawLineForText):
888
889 2006-03-19  Darin Adler  <darin@apple.com>
890
891         Rubber stamped by Eric.
892
893         - moved khtml/html files all into html directory
894
895         * WebCore.vcproj/WebCore/WebCore.vcproj: Updated for new paths.
896         * WebCore.vcproj/WebCore/build-generated-files.sh: Ditto.
897         * WebCore.xcodeproj/project.pbxproj: Ditto.
898
899         * khtml/html: Removed.
900
901         * html/DocTypeStrings.gperf: Moved.
902         * html/FormDataList.cpp: Ditto.
903         * html/FormDataList.h: Ditto.
904         * html/HTMLBaseFontElement.cpp: Ditto.
905         * html/HTMLBaseFontElement.h: Ditto.
906         * html/HTMLButtonElement.cpp: Ditto.
907         * html/HTMLButtonElement.h: Ditto.
908         * html/HTMLCanvasElement.cpp: Ditto.
909         * html/HTMLCanvasElement.h: Ditto.
910         * html/HTMLCollection.cpp: Ditto.
911         * html/HTMLCollection.h: Ditto.
912         * html/HTMLDocument.cpp: Ditto.
913         * html/HTMLDocument.h: Ditto.
914         * html/HTMLElement.cpp: Ditto.
915         * html/HTMLElement.h: Ditto.
916         * html/HTMLElementFactory.cpp: Ditto.
917         * html/HTMLElementFactory.h: Ditto.
918         * html/HTMLEntityNames.gperf: Ditto.
919         * html/HTMLFieldSetElement.cpp: Ditto.
920         * html/HTMLFieldSetElement.h: Ditto.
921         * html/HTMLFormCollection.cpp: Ditto.
922         * html/HTMLFormCollection.h: Ditto.
923         * html/HTMLFormElement.cpp: Ditto.
924         * html/HTMLFormElement.h: Ditto.
925         * html/HTMLGenericFormElement.cpp: Ditto.
926         * html/HTMLGenericFormElement.h: Ditto.
927         * html/HTMLInputElement.cpp: Ditto.
928         * html/HTMLInputElement.h: Ditto.
929         * html/HTMLIsIndexElement.cpp: Ditto.
930         * html/HTMLIsIndexElement.h: Ditto.
931         * html/HTMLKeygenElement.cpp: Ditto.
932         * html/HTMLKeygenElement.h: Ditto.
933         * html/HTMLLabelElement.cpp: Ditto.
934         * html/HTMLLabelElement.h: Ditto.
935         * html/HTMLLegendElement.cpp: Ditto.
936         * html/HTMLLegendElement.h: Ditto.
937         * html/HTMLNameCollection.cpp: Ditto.
938         * html/HTMLNameCollection.h: Ditto.
939         * html/HTMLNames.cpp: Ditto.
940         * html/HTMLNames.h: Ditto.
941         * html/HTMLOptGroupElement.cpp: Ditto.
942         * html/HTMLOptGroupElement.h: Ditto.
943         * html/HTMLOptionElement.cpp: Ditto.
944         * html/HTMLOptionElement.h: Ditto.
945         * html/HTMLOptionsCollection.cpp: Ditto.
946         * html/HTMLOptionsCollection.h: Ditto.
947         * html/HTMLParser.cpp: Ditto.
948         * html/HTMLParser.h: Ditto.
949         * html/HTMLSelectElement.cpp: Ditto.
950         * html/HTMLSelectElement.h: Ditto.
951         * html/HTMLTextAreaElement.cpp: Ditto.
952         * html/HTMLTextAreaElement.h: Ditto.
953         * html/HTMLTextFieldInnerElement.cpp: Ditto.
954         * html/HTMLTextFieldInnerElement.h: Ditto.
955         * html/HTMLTokenizer.cpp: Ditto.
956         * html/HTMLTokenizer.h: Ditto.
957         * html/html_baseimpl.cpp: Ditto.
958         * html/html_baseimpl.h: Ditto.
959         * html/html_blockimpl.cpp: Ditto.
960         * html/html_blockimpl.h: Ditto.
961         * html/html_headimpl.cpp: Ditto.
962         * html/html_headimpl.h: Ditto.
963         * html/html_imageimpl.cpp: Ditto.
964         * html/html_imageimpl.h: Ditto.
965         * html/html_inlineimpl.cpp: Ditto.
966         * html/html_inlineimpl.h: Ditto.
967         * html/html_listimpl.cpp: Ditto.
968         * html/html_listimpl.h: Ditto.
969         * html/html_objectimpl.cpp: Ditto.
970         * html/html_objectimpl.h: Ditto.
971         * html/html_tableimpl.cpp: Ditto.
972         * html/html_tableimpl.h: Ditto.
973
974         * bindings/objc/DOM.mm:
975         * bridge/mac/WebCoreEncodings.mm:
976         * bridge/mac/WebCoreFrameBridge.mm:
977         * css/CSSGrammar.y:
978         * css/cssstyleselector.cpp:
979         * dom/Document.cpp:
980         * dom/EventTargetNode.cpp:
981         * dom/NameNodeList.cpp:
982         * dom/Node.cpp:
983         * dom/Position.cpp:
984         * dom/dom_elementimpl.cpp:
985         * dom/xml_tokenizer.cpp:
986         * editing/ApplyStyleCommand.cpp:
987         * editing/BreakBlockquoteCommand.cpp:
988         * editing/CompositeEditCommand.cpp:
989         * editing/DeleteSelectionCommand.cpp:
990         * editing/InsertLineBreakCommand.cpp:
991         * editing/InsertParagraphSeparatorCommand.cpp:
992         * editing/JSEditor.cpp:
993         * editing/ReplaceSelectionCommand.cpp:
994         * editing/TextIterator.cpp:
995         * editing/VisiblePosition.cpp:
996         * editing/htmlediting.cpp:
997         * editing/markup.cpp:
998         * editing/visible_units.cpp:
999         * html/CanvasRenderingContext2D.cpp:
1000         * kcanvas/KCanvasTreeDebug.cpp:
1001         * khtml/ecma/JSDOMParser.cpp:
1002         * khtml/ecma/kjs_css.cpp:
1003         * khtml/ecma/kjs_dom.cpp:
1004         * khtml/ecma/kjs_events.cpp:
1005         * khtml/misc/decoder.cpp:
1006         * khtml/xsl/XSLStyleSheet.cpp:
1007         * khtml/xsl/XSLTProcessor.cpp:
1008         * ksvg2/misc/SVGImageLoader.h:
1009         * ksvg2/svg/SVGElement.cpp:
1010         * ksvg2/svg/SVGSVGElement.cpp:
1011         * kwq/WebCoreAXObject.mm:
1012         * page/Frame.cpp:
1013         * page/FrameView.cpp:
1014         * rendering/RenderBlock.cpp:
1015         * rendering/RenderBox.cpp:
1016         * rendering/RenderFlow.cpp:
1017         * rendering/RenderHTMLCanvas.cpp:
1018         * rendering/RenderImage.cpp:
1019         * rendering/RenderLayer.cpp:
1020         * rendering/RenderObject.cpp:
1021         * rendering/RenderTable.cpp:
1022         * rendering/RenderTableCell.cpp:
1023         * rendering/RenderTableCol.cpp:
1024         * rendering/RenderTableRow.cpp:
1025         * rendering/RenderTableSection.cpp:
1026         * rendering/RenderTextField.cpp:
1027         * rendering/RenderTheme.cpp:
1028         * rendering/render_applet.cpp:
1029         * rendering/render_button.cpp:
1030         * rendering/render_frames.cpp:
1031         * rendering/render_list.cpp:
1032         Updated includes.
1033
1034 2006-03-17  Eric Seidel  <eseidel@apple.com>
1035
1036         Reviewed by darin.
1037
1038         Move Form code from MacFrame to Frame.
1039         Move GraphicsContext code from GraphicsContextMac to GraphicsContext.
1040         Use IntRect, FloatRect in more places throughout the code.
1041         http://bugzilla.opendarwin.org/show_bug.cgi?id=7824
1042
1043         * bridge/mac/MacFrame.h:
1044         * bridge/mac/MacFrame.mm:
1045         (WebCore::MacFrame::MacFrame):
1046         (WebCore::MacFrame::searchForLabelsAboveCell):
1047         (WebCore::MacFrame::searchForLabelsBeforeElement):
1048         (WebCore::dictionaryFromHashMap):
1049         (WebCore::MacFrame::submitForm):
1050         (WebCore::MacFrame::setView):
1051         (WebCore::MacFrame::currentEventIsMouseDownInWidget):
1052         (WebCore::MacFrame::currentEventIsKeyboardOptionTab):
1053         (WebCore::MacFrame::handleKeyboardOptionTabInView):
1054         (WebCore::MacFrame::tabsToAllControls):
1055         (WebCore::MacFrame::shouldDragAutoNode):
1056         (WebCore::MacFrame::selectionImage):
1057         (WebCore::MacFrame::snapshotDragImage):
1058         * bridge/mac/WebCoreFrameBridge.mm:
1059         (-[WebCoreFrameBridge nextKeyView]):
1060         (-[WebCoreFrameBridge previousKeyView]):
1061         (-[WebCoreFrameBridge nextKeyViewInsideWebFrameViews]):
1062         (-[WebCoreFrameBridge previousKeyViewInsideWebFrameViews]):
1063         * kcanvas/RenderSVGImage.cpp:
1064         (WebCore::RenderSVGImage::paint):
1065         * page/Frame.cpp:
1066         (WebCore::Frame::Frame):
1067         (WebCore::Frame::clearRecordedFormValues):
1068         (WebCore::Frame::recordFormValue):
1069         (WebCore::Frame::didNotOpenURL):
1070         (WebCore::scanForForm):
1071         (WebCore::Frame::paint):
1072         (WebCore::Frame::prepareForUserAction):
1073         * page/Frame.h:
1074         * platform/GraphicsContext.cpp:
1075         (WebCore::GraphicsContextState::GraphicsContextState):
1076         (WebCore::GraphicsContextPrivate::GraphicsContextPrivate):
1077         (WebCore::GraphicsContextPrivate::~GraphicsContextPrivate):
1078         (WebCore::GraphicsContext::save):
1079         (WebCore::GraphicsContext::restore):
1080         (WebCore::GraphicsContext::font):
1081         (WebCore::GraphicsContext::setFont):
1082         (WebCore::GraphicsContext::pen):
1083         (WebCore::GraphicsContext::setPen):
1084         (WebCore::GraphicsContext::setBrush):
1085         (WebCore::GraphicsContext::brush):
1086         (WebCore::GraphicsContext::setUsesInactiveTextBackgroundColor):
1087         (WebCore::GraphicsContext::usesInactiveTextBackgroundColor):
1088         (WebCore::GraphicsContext::updatingControlTints):
1089         (WebCore::GraphicsContext::setUpdatingControlTints):
1090         (WebCore::GraphicsContext::setPaintingDisabled):
1091         (WebCore::GraphicsContext::paintingDisabled):
1092         (WebCore::GraphicsContext::printing):
1093         (WebCore::GraphicsContext::drawImageAtPoint):
1094         (WebCore::GraphicsContext::drawImageInRect):
1095         (WebCore::GraphicsContext::drawImage):
1096         (WebCore::GraphicsContext::initFocusRing):
1097         (WebCore::GraphicsContext::clearFocusRing):
1098         (WebCore::GraphicsContext::addFocusRingRect):
1099         (WebCore::GraphicsContext::focusRingWidth):
1100         (WebCore::GraphicsContext::focusRingOffset):
1101         (WebCore::GraphicsContext::focusRingRects):
1102         * platform/GraphicsContext.h:
1103         * platform/mac/GraphicsContextMac.mm:
1104         (WebCore::fillRectSourceOver):
1105         (WebCore::GraphicsContextPlatformPrivate::GraphicsContextPlatformPrivate):
1106         (WebCore::GraphicsContextPlatformPrivate::~GraphicsContextPlatformPrivate):
1107         (WebCore::GraphicsContext::GraphicsContext):
1108         (WebCore::GraphicsContext::~GraphicsContext):
1109         (WebCore::GraphicsContext::savePlatformState):
1110         (WebCore::GraphicsContext::restorePlatformState):
1111         (WebCore::GraphicsContext::drawRect):
1112         (WebCore::GraphicsContext::setColorFromBrush):
1113         (WebCore::GraphicsContext::setColorFromPen):
1114         (WebCore::GraphicsContext::drawLine):
1115         (WebCore::GraphicsContext::drawEllipse):
1116         (WebCore::GraphicsContext::drawArc):
1117         (WebCore::GraphicsContext::drawConvexPolygon):
1118         (WebCore::GraphicsContext::drawFloatImage):
1119         (WebCore::GraphicsContext::drawTiledImage):
1120         (WebCore::GraphicsContext::drawScaledAndTiledImage):
1121         (WebCore::GraphicsContext::selectedTextBackgroundColor):
1122         (WebCore::GraphicsContext::fillRect):
1123         (WebCore::GraphicsContext::addClip):
1124         (WebCore::GraphicsContext::addRoundedRectClip):
1125         (WebCore::GraphicsContext::beginTransparencyLayer):
1126         (WebCore::GraphicsContext::endTransparencyLayer):
1127         (WebCore::GraphicsContext::setShadow):
1128         (WebCore::GraphicsContext::clearShadow):
1129         (WebCore::GraphicsContext::drawFocusRing):
1130         * rendering/render_box.cpp:
1131         (WebCore::RenderBox::paintBackgroundExtended):
1132         (WebCore::RenderBox::outlineBox):
1133         * rendering/render_frames.cpp:
1134         (WebCore::RenderFrameSet::userResize):
1135         * rendering/render_image.cpp:
1136         (WebCore::RenderImage::paint):
1137         * rendering/render_list.cpp:
1138         (WebCore::RenderListMarker::paint):
1139         * rendering/render_object.cpp:
1140         (WebCore::RenderObject::drawBorder):
1141         (WebCore::RenderObject::paintBorderImage):
1142
1143 2006-03-19  Darin Adler  <darin@apple.com>
1144
1145         Reviewed by Eric.
1146
1147         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=7854
1148           CanvasGradient leaks
1149
1150         * html/CanvasGradient.cpp: (WebCore::CanvasGradient::platformShading):
1151         Don't make the CG shading object keep a reference to the DOM gradient object.
1152         I got confused because in the case of a CanvasPattern, the pattern does need
1153         to keep a reference to the DOM pattern object, but the object lifetime is
1154         handled differently here. The CG shading object is used right away, not set
1155         in a graphics context.
1156
1157 2006-03-19  Darin Adler  <darin@apple.com>
1158
1159         Reviewed by Eric.
1160
1161         - attempt to fix the buildbot by handling DOMImplementation another way
1162
1163         * WebCore.xcodeproj/project.pbxproj: Added DOMImplementationFront.h/cpp.
1164
1165         * bindings/objc/DOMImplementationFront.cpp: Added.
1166         * bindings/objc/DOMImplementationFront.h: Added.
1167
1168         * bindings/objc/DOMInternal.h: Use DOMImplementationFront, not DOMImplementation.
1169         * bindings/objc/DOM.mm:
1170         (-[DOMImplementation dealloc]): Ditto.
1171         (-[DOMImplementation finalize]): Ditto.
1172         (-[DOMImplementation _initWithDOMImplementation:]): Ditto.
1173         (+[DOMImplementation _DOMImplementationWith:]): Ditto.
1174         (-[DOMImplementation _DOMImplementation]): Ditto.
1175         (-[DOMDocument implementation]): Call implementationFront from the
1176         DOMImplementationFront header instead of using the real implementation
1177         function on the Document.
1178
1179 2006-03-19  Darin Adler  <darin@apple.com>
1180
1181         - global rename, done by script
1182
1183         * <lots of files>: Renamed XXXImpl to XXX, and a number of other renames.
1184         See WebKitTools/Scripts/do-webcore-rename version 13392 for details.
1185
1186 2006-03-19  Darin Adler  <darin@apple.com>
1187
1188         - roll out fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=6314
1189           Unclosed <style> element in <head> makes page completely blank
1190
1191         This fix was breaking major sites -- details in the bug report.
1192
1193         * khtml/html/htmltokenizer.cpp: (WebCore::HTMLTokenizer::parseTag):
1194         Removed the bug fix, added a FIXME about the <title> code that has
1195         the same problem.
1196
1197 2006-03-18  David Carson  <dacarson@gmail.com>
1198
1199         Test: fast/canvas/patternfill-repeat.html
1200
1201         Reviewed by Darin.
1202
1203         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=7830
1204           <canvas> createPattern 'repeat' options fail
1205
1206         * CanvasPattern.cpp (CanvasPattern::createPattern)
1207         Change stepping so that repeat-x, repeat-y, and no-repeat repeat 
1208         outside the view area by using large values for repeat interval.
1209
1210 2006-03-18  Mitz Pettel  <opendarwin.org@mitzpettel.com>
1211
1212         Test: fast/dom/Element/class-attribute-whitespace.html
1213
1214         Reviewed by Darin.
1215
1216         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=7761
1217           Tabs in class attribute not treated as whitespace
1218
1219         * dom/dom_elementimpl.cpp:
1220         (WebCore::isClassWhitespace): Helper function to check if a character
1221         in the class attribute should be treated as whitespace. Added \r and \t.
1222         (WebCore::NamedMappedAttrMapImpl::parseClassAttribute): Instead of creating
1223         a QStringList and iterating it, do everything in one pass over the string.
1224
1225 2006-03-18  Mitz Pettel  <opendarwin.org@mitzpettel.com>
1226
1227         Test: fast/block/float/vertical-move-relayout.html
1228
1229         Reviewed by Hyatt.
1230
1231         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6795
1232           Slow image load causes render problem
1233
1234         * rendering/RenderBlock.cpp:
1235         (WebCore::RenderBlock::layoutBlockChildren): Call markAllDescendantsWithFloatsForLayout
1236         when the child's vertical position changes.
1237
1238 2006-03-18  David Kilzer  <ddkilzer@kilzer.net>
1239
1240         Reviewed by Darin.
1241
1242         - Fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=6314
1243         Unclosed <style> element in <head> makes page completely blank
1244
1245         Test: fast/js/exception-linenums-in-html-3.html
1246         Test: fast/js/missing-style-end-tag-js.html
1247         Test: fast/tokenizer/missing-style-end-tag-1.html
1248         Test: fast/tokenizer/missing-style-end-tag-2.html
1249
1250         * khtml/html/htmlparser.cpp:
1251         (WebCore::HTMLParser::handleError): Add check for missing </style> tag and handle
1252         this condition if identified.
1253         * khtml/html/htmltokenizer.cpp:
1254         (WebCore::HTMLTokenizer::parseTag): If parseSpecial() consumes the rest of the
1255         document looking for a </style> tag, reset the state of the tokenizer and
1256         retokenize with no special handling for <style>.  The parser will handle the
1257         missing </style> tag in HTMLParser::handleError().
1258
1259 2006-03-18  Rob Buis  <buis@kde.org>
1260
1261         Reviewed by Darin.
1262
1263         Fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=5351:
1264         SVG: Safari ignores <title> elements
1265
1266         Make SVGTitleElementImpl act the same as HTMLTitleElementImpl,
1267         in the process setting the title on the right triggers.
1268
1269         * ksvg2/svg/SVGTitleElementImpl.cpp:
1270         (SVGTitleElementImpl::SVGTitleElementImpl):
1271         (SVGTitleElementImpl::title):
1272         (SVGTitleElementImpl::closeRenderer):
1273         (SVGTitleElementImpl::insertedIntoDocument):
1274         (SVGTitleElementImpl::removedFromDocument):
1275         (SVGTitleElementImpl::childrenChanged):
1276         * ksvg2/svg/SVGTitleElementImpl.h:
1277
1278 2006-03-18  Darin Adler  <darin@apple.com>
1279
1280         - another try at fixing Windows build
1281
1282         * WebCore.vcproj/WebCore/WebCore.vcproj: Added EventTargetNodeImpl.h and .cpp.
1283
1284 2006-03-18  Darin Adler  <darin@apple.com>
1285
1286         - another try at fixing Windows build
1287
1288         * bridge/win/FrameWin.cpp: (WebCore::FrameWin::keyPress): Added EventTargetNodeCast.
1289
1290 2006-03-18  Darin Adler  <darin@apple.com>
1291
1292         - try to fix Windows build
1293
1294         * bridge/win/FrameWin.h: Remove KURL parameter.
1295         * bridge/win/FrameWin.cpp: (WebCore::FrameWin::urlSelected): Ditto.
1296         * platform/win/TemporaryLinkStubs.cpp: (BrowserExtensionWin::canRunModal): Ditto.
1297
1298 2006-03-18  Mitz Pettel  <opendarwin.org@mitzpettel.com>
1299
1300         Reviewed by Darin.
1301
1302         - fix leaks caused by the fix for Bugzilla bug 3560
1303
1304         * rendering/RenderContainer.cpp:
1305         (WebCore::RenderContainer::destroyLeftoverChildren): Text renderers with
1306         first-letter pseudo style are children of an existing first-letter inline
1307         that has been updated, and should be destroyed.
1308
1309 2006-03-18  David Hyatt  <hyatt@apple.com>
1310
1311         Fix for bug 7841, tables, table rows, and table row groups should
1312         all support overflow:hidden.
1313
1314         Reviewed by eric
1315
1316         * css/cssstyleselector.cpp:
1317         (WebCore::CSSStyleSelector::adjustRenderStyle):
1318         * rendering/RenderTable.cpp:
1319         (WebCore::RenderTable::layout):
1320         (WebCore::RenderTable::paint):
1321         (WebCore::RenderTable::getOverflowClipRect):
1322         * rendering/RenderTable.h:
1323         * rendering/RenderTableCol.h:
1324         (WebCore::RenderTableCol::requiresLayer):
1325         * rendering/RenderTableRow.h:
1326         (WebCore::RenderTableRow::requiresLayer):
1327         * rendering/render_box.cpp:
1328         (WebCore::RenderBox::setStyle):
1329         * rendering/render_layer.cpp:
1330         (WebCore::RenderLayer::paintLayer):
1331
1332 2006-03-17  Alice Liu  <alice.liu@apple.com>
1333
1334         Reviewed by Hyatt.
1335
1336         - fixed http://bugzilla.opendarwin.org/show_bug.cgi?id=6999
1337           "Dynamically added link-tag disables the use of change styles 
1338            dynamically"
1339
1340         * khtml/html/html_headimpl.cpp:
1341         (WebCore::HTMLLinkElementImpl::process):
1342         - dynamically added link-tags for stylesheets were messing up the
1343           counting of pending stylesheets.  If a head link element 
1344           specifies a new stylesheet but the previously specified 
1345           stylesheet is still loading, tell the document that stylesheets 
1346           are loaded so that there are no remaining requests for it to be 
1347           loaded.
1348
1349 2006-03-17  Geoffrey Garen  <ggaren@apple.com>
1350
1351         Reviewed by Darin.
1352
1353         - Fixed some crashes in event dispatch and settled the question of 
1354         when getDocument() can return NULL, removing superfluous NULL checks.
1355
1356         I promise to check in a test case soon, but I need to land this before
1357         the global rename happens, and I left the test file on my other machine.
1358
1359         Here's what I did:
1360
1361         (1) Removed NULL checks for getDocument() in cases where we know it
1362         should not return NULL (which turned out to be all but one). Replaced 
1363         with ASSERT inside getDocument(). Tested to ensure there was no 
1364         regression @ albertsons.com.
1365
1366         (2) Added the EventTargetNode class, which represents Nodes that
1367         implement the DOM EventTarget interface. Discussed this design with
1368         Maciej and Hyatt. The previous dsign -- assuming that all Nodes were 
1369         EventTargets -- made it possible to crash WebKit by, for example, 
1370         dispatching a mouse event to a documentType node that was not 
1371         associated with a document.
1372
1373         (3) Reflected (2) into the JS bindings and touched JSDOMCore.cpp to 
1374         force a re-build.
1375
1376         (4) Using classInfo checking, strengthened type constraints on 
1377         JavaScript method dispatch so that you can't finagle JavaScript into, 
1378         for example, invoking a document-dependent method belonging to a
1379         node type that's guaranteed to have a document on a node type that may
1380         not have one. 
1381
1382         (5) Pushed some IE-specific JS bindings that depend on a node having a 
1383         document down from DOMNode to DOMElement. (An element always has a 
1384         document.) Tested that Firefox's behavior matched. Confirmed with MSDN.
1385
1386         (6) Updated Objc bindigns to throw an exception if you try to use
1387         the event interface on a node that doesn't support it. Discussed this
1388         design with Maciej and TimH.
1389
1390         (7) Consolidated repeated documentElement-finding code in the Position 
1391         class into the Position::documentElement() method. Did the same for
1392         repeated top-level document finding and DocumentImpl::topDocument().
1393         
1394         * WebCore+SVG/KDOMHeaders.h:
1395         * WebCore.xcodeproj/project.pbxproj:
1396         * bindings/js/JSDOMCore.cpp:
1397         * bindings/objc/DOM.mm:
1398         (-[DOMNode addEventListener:::]):
1399         (-[DOMNode removeEventListener:::]):
1400         (-[DOMNode dispatchEvent:]):
1401         (-[DOMNode KJS::Bindings::]):
1402         * bridge/mac/MacFrame.mm:
1403         (WebCore::MacFrame::keyEvent):
1404         (WebCore::MacFrame::dispatchCPPEvent):
1405         * bridge/mac/WebCoreFrameBridge.mm:
1406         (-[WebCoreFrameBridge setSelectedDOMRange:affinity:closeTyping:]):
1407         (-[WebCoreFrameBridge smartDeleteRangeForProposedRange:]):
1408         * css/css_base.cpp:
1409         (WebCore::StyleBaseImpl::baseURL):
1410         * css/css_computedstyle.cpp:
1411         (WebCore::CSSComputedStyleDeclarationImpl::getPropertyCSSValue):
1412         * css/css_valueimpl.cpp:
1413         (WebCore::CSSMutableStyleDeclarationImpl::removeProperty):
1414         (WebCore::CSSMutableStyleDeclarationImpl::setProperty):
1415         * css/cssstyleselector.cpp:
1416         (WebCore::CSSStyleSelector::applyProperty):
1417         * dom/Attr.idl:
1418         * dom/CharacterData.idl:
1419         * dom/CharacterDataImpl.cpp:
1420         (WebCore::CharacterDataImpl::CharacterDataImpl):
1421         (WebCore::CharacterDataImpl::rendererIsNeeded):
1422         (WebCore::CharacterDataImpl::dump):
1423         * dom/CharacterDataImpl.h:
1424         * dom/ContainerNodeImpl.cpp:
1425         (WebCore::ContainerNodeImpl::ContainerNodeImpl):
1426         (WebCore::ContainerNodeImpl::removeChild):
1427         (WebCore::ContainerNodeImpl::attach):
1428         (WebCore::ContainerNodeImpl::detach):
1429         (WebCore::ContainerNodeImpl::insertedIntoDocument):
1430         (WebCore::ContainerNodeImpl::removedFromDocument):
1431         (WebCore::ContainerNodeImpl::insertedIntoTree):
1432         (WebCore::ContainerNodeImpl::removedFromTree):
1433         (WebCore::ContainerNodeImpl::setFocus):
1434         (WebCore::ContainerNodeImpl::setActive):
1435         (WebCore::ContainerNodeImpl::setHovered):
1436         (WebCore::dispatchChildInsertionEvents):
1437         (WebCore::dispatchChildRemovalEvents):
1438         * dom/ContainerNodeImpl.h:
1439         * dom/DOMImplementationImpl.cpp:
1440         (WebCore::DOMImplementationImpl::createDocument):
1441         * dom/DocumentImpl.cpp:
1442         (WebCore::DocumentImpl::removeAllEventListenersFromAllNodes):
1443         (WebCore::DocumentImpl::removeAllDisconnectedNodeEventListeners):
1444         (WebCore::DocumentImpl::getAccObjectCache):
1445         (WebCore::DocumentImpl::setFocusNode):
1446         (WebCore::DocumentImpl::topDocument):
1447         * dom/Element.idl:
1448         * dom/EventTargetNodeImpl.cpp: Added.
1449         (WebCore::EventTargetNodeImpl::EventTargetNodeImpl):
1450         (WebCore::EventTargetNodeImpl::~EventTargetNodeImpl):
1451         (WebCore::EventTargetNodeImpl::insertedIntoDocument):
1452         (WebCore::EventTargetNodeImpl::removedFromDocument):
1453         (WebCore::EventTargetNodeImpl::addEventListener):
1454         (WebCore::EventTargetNodeImpl::removeEventListener):
1455         (WebCore::EventTargetNodeImpl::removeAllEventListeners):
1456         (WebCore::EventTargetNodeImpl::handleLocalEvents):
1457         (WebCore::EventTargetNodeImpl::dispatchGenericEvent):
1458         (WebCore::EventTargetNodeImpl::dispatchEvent):
1459         (WebCore::EventTargetNodeImpl::dispatchSubtreeModifiedEvent):
1460         (WebCore::EventTargetNodeImpl::dispatchWindowEvent):
1461         (WebCore::EventTargetNodeImpl::dispatchUIEvent):
1462         (WebCore::EventTargetNodeImpl::dispatchKeyEvent):
1463         (WebCore::EventTargetNodeImpl::dispatchMouseEvent):
1464         (WebCore::EventTargetNodeImpl::dispatchSimulatedMouseEvent):
1465         (WebCore::EventTargetNodeImpl::dispatchWheelEvent):
1466         (WebCore::EventTargetNodeImpl::dispatchHTMLEvent):
1467         (WebCore::EventTargetNodeImpl::removeHTMLEventListener):
1468         (WebCore::EventTargetNodeImpl::setHTMLEventListener):
1469         (WebCore::EventTargetNodeImpl::getHTMLEventListener):
1470         (WebCore::EventTargetNodeImpl::disabled):
1471         (WebCore::EventTargetNodeImpl::defaultEventHandler):
1472         (WebCore::EventTargetNodeImpl::dump):
1473         * dom/EventTargetNodeImpl.h: Added.
1474         (WebCore::EventTargetNodeImpl::isEventTargetNode):
1475         (WebCore::EventTargetNodeImpl::preDispatchEventHandler):
1476         (WebCore::EventTargetNodeImpl::postDispatchEventHandler):
1477         (WebCore::EventTarget):
1478         (WebCore::forbidEventDispatch):
1479         (WebCore::allowEventDispatch):
1480         (WebCore::eventDispatchForbidden):
1481         * dom/NodeImpl.cpp:
1482         (WebCore::NodeImpl::NodeImpl):
1483         (WebCore::NodeImpl::~NodeImpl):
1484         (WebCore::NodeImpl::dump):
1485         (WebCore::NodeImpl::detach):
1486         (WebCore::NodeImpl::insertedIntoDocument):
1487         (WebCore::NodeImpl::removedFromDocument):
1488         * dom/NodeImpl.h:
1489         (WebCore::NodeImpl::isEventTargetNode):
1490         (WebCore::NodeImpl::isLink):
1491         (WebCore::NodeImpl::getDocument):
1492         (WebCore::NodeImpl::inDocument):
1493         * dom/dom2_eventsimpl.cpp:
1494         (WebCore::MouseRelatedEventImpl::receivedTarget):
1495         * dom/dom2_rangeimpl.cpp:
1496         (WebCore::RangeImpl::commonAncestorContainer):
1497         * dom/dom_elementimpl.cpp:
1498         (WebCore::inHTMLDocument):
1499         (WebCore::ElementImpl::focus):
1500         (WebCore::ElementImpl::blur):
1501         (WebCore::StyledElementImpl::parseMappedAttribute):
1502         * dom/dom_position.cpp:
1503         (WebCore::Position::documentElement):
1504         * dom/dom_position.h:
1505         * editing/ReplaceSelectionCommand.cpp:
1506         (WebCore::computeAndStoreNodeDesiredStyle):
1507         * editing/SelectionController.cpp:
1508         (WebCore::SelectionController::needsCaretRepaint):
1509         * editing/visible_units.cpp:
1510         (WebCore::previousBoundary):
1511         (WebCore::nextBoundary):
1512         (WebCore::previousLinePosition):
1513         (WebCore::nextLinePosition):
1514         (WebCore::startOfDocument):
1515         (WebCore::endOfDocument):
1516         * khtml/ecma/kjs_dom.cpp:
1517         (KJS::DOMNode::mark):
1518         (KJS::DOMNode::getValueProperty):
1519         (KJS::DOMNode::putValueProperty):
1520         (KJS::DOMNodeProtoFunc::callAsFunction):
1521         (KJS::DOMEventTargetNode::DOMEventTargetNode):
1522         (KJS::DOMEventTargetNode::getOwnPropertySlot):
1523         (KJS::DOMEventTargetNode::getValueProperty):
1524         (KJS::DOMEventTargetNode::put):
1525         (KJS::DOMEventTargetNode::putValueProperty):
1526         (KJS::DOMEventTargetNode::setListener):
1527         (KJS::DOMEventTargetNode::getListener):
1528         (KJS::DOMEventTargetNode::pushEventHandlerScope):
1529         (KJS::DOMEventTargetNodeProtoFunc::callAsFunction):
1530         (KJS::):
1531         (KJS::DOMDocument::DOMDocument):
1532         (KJS::DOMDocument::getOwnPropertySlot):
1533         (KJS::DOMDocument::put):
1534         (KJS::DOMDocument::putValueProperty):
1535         (KJS::DOMDocumentProtoFunc::callAsFunction):
1536         (KJS::DOMElement::DOMElement):
1537         (KJS::DOMElement::getValueProperty):
1538         (KJS::DOMElement::put):
1539         (KJS::DOMElement::putValueProperty):
1540         (KJS::DOMElement::getOwnPropertySlot):
1541         (KJS::DOMElementProtoFunc::callAsFunction):
1542         (KJS::checkNodeSecurity):
1543         * khtml/ecma/kjs_dom.h:
1544         (KJS::DOMNode::):
1545         (KJS::DOMEventTargetNode::):
1546         (KJS::DOMElement::):
1547         * khtml/ecma/kjs_events.cpp:
1548         (KJS::JSLazyEventListener::parseCode):
1549         (KJS::getNodeEventListener):
1550         * khtml/ecma/kjs_html.cpp:
1551         (KJS::HTMLElement::bodyGetter):
1552         (KJS::HTMLElement::anchorGetter):
1553         (KJS::HTMLElement::getValueProperty):
1554         (KJS::HTMLElement::bodySetter):
1555         * khtml/ecma/kjs_views.cpp:
1556         (KJS::DOMAbstractViewProtoFunc::callAsFunction):
1557         * khtml/html/HTMLFormElementImpl.cpp:
1558         (WebCore::HTMLFormElementImpl::registerFormElement):
1559         (WebCore::HTMLFormElementImpl::removeFormElement):
1560         * khtml/html/HTMLGenericFormElementImpl.cpp:
1561         (WebCore::HTMLGenericFormElementImpl::insertedIntoTree):
1562         * khtml/html/HTMLInputElementImpl.cpp:
1563         (WebCore::HTMLInputElementImpl::~HTMLInputElementImpl):
1564         (WebCore::HTMLInputElementImpl::focus):
1565         * khtml/html/HTMLOptionElementImpl.cpp:
1566         (WebCore::HTMLOptionElementImpl::text):
1567         * khtml/html/HTMLSelectElementImpl.cpp:
1568         (WebCore::HTMLSelectElementImpl::~HTMLSelectElementImpl):
1569         * khtml/html/HTMLTextAreaElementImpl.cpp:
1570         (WebCore::HTMLTextAreaElementImpl::~HTMLTextAreaElementImpl):
1571         * khtml/html/html_baseimpl.cpp:
1572         (WebCore::HTMLBodyElementImpl::insertedIntoDocument):
1573         (WebCore::HTMLFrameElementImpl::isURLAllowed):
1574         (WebCore::HTMLFrameElementImpl::openURL):
1575         (WebCore::HTMLFrameElementImpl::frameWidth):
1576         (WebCore::HTMLFrameElementImpl::frameHeight):
1577         * khtml/html/html_imageimpl.cpp:
1578         (WebCore::HTMLImageLoader::~HTMLImageLoader):
1579         (WebCore::HTMLImageLoader::updateFromElement):
1580         (WebCore::HTMLImageLoader::notifyFinished):
1581         (WebCore::HTMLImageElementImpl::width):
1582         (WebCore::HTMLImageElementImpl::height):
1583         (WebCore::HTMLMapElementImpl::~HTMLMapElementImpl):
1584         * khtml/html/html_inlineimpl.cpp:
1585         (WebCore::HTMLAnchorElementImpl::defaultEventHandler):
1586         * khtml/html/htmltokenizer.cpp:
1587         (WebCore::HTMLTokenizer::notifyFinished):
1588         * ksvg2/svg/SVGAnimateColorElementImpl.cpp:
1589         (SVGAnimateColorElementImpl::handleTimerEvent):
1590         * ksvg2/svg/SVGAnimateElementImpl.cpp:
1591         (SVGAnimateElementImpl::handleTimerEvent):
1592         * ksvg2/svg/SVGAnimateTransformElementImpl.cpp:
1593         (SVGAnimateTransformElementImpl::handleTimerEvent):
1594         * ksvg2/svg/SVGAnimationElementImpl.cpp:
1595         (SVGAnimationElementImpl::closeRenderer):
1596         * ksvg2/svg/SVGDOMImplementationImpl.cpp:
1597         * ksvg2/svg/SVGDocumentImpl.cpp:
1598         (WebCore::SVGDocumentImpl::dispatchRecursiveEvent):
1599         * ksvg2/svg/SVGDocumentImpl.h:
1600         * ksvg2/svg/SVGImageElementImpl.cpp:
1601         * ksvg2/svg/SVGSetElementImpl.cpp:
1602         (SVGSetElementImpl::handleTimerEvent):
1603         * kwq/KWQAccObject.mm:
1604         (-[KWQAccObject mouseButtonListener]):
1605         (-[KWQAccObject accessibilityPerformAction:]):
1606         * kwq/KWQTextArea.mm:
1607         (-[KWQTextAreaTextView dispatchHTMLEvent:]):
1608         * page/Frame.cpp:
1609         (WebCore::dispatchKHTMLEditableContentChanged):
1610         * page/FrameView.cpp:
1611         (WebCore::FrameView::dispatchDragEvent):
1612         (WebCore::FrameView::dispatchMouseEvent):
1613         (WebCore::FrameView::viewportWheelEvent):
1614         * rendering/render_layer.cpp:
1615         (WebCore::RenderLayer::scrollToOffset):
1616         * rendering/render_object.cpp:
1617         (WebCore::RenderObject::shouldSelect):
1618         (WebCore::RenderObject::backslashAsCurrencySymbol):
1619         * rendering/render_replaced.cpp:
1620         (WebCore::RenderWidget::sendConsumedMouseUp):
1621
1622 2006-03-17  David Hyatt  <hyatt@apple.com>
1623
1624         Fix for 7837, make opacity work with table rows.  Make transparent backgrounds
1625         stack properly in cells (so that the layers behind can show through like they
1626         should).
1627
1628         Reviewed by beth
1629
1630         * rendering/RenderTableCell.cpp:
1631         (WebCore::RenderTableCell::requiresLayer):
1632         (WebCore::RenderTableCell::paintBackgroundsBehindCell):
1633         (WebCore::RenderTableCell::paintBoxDecorations):
1634         * rendering/RenderTableCell.h:
1635         * rendering/RenderTableRow.cpp:
1636         (WebCore::RenderTableRow::paint):
1637         * rendering/RenderTableRow.h:
1638         (WebCore::RenderTableRow::requiresLayer):
1639         * rendering/RenderTableSection.cpp:
1640         (WebCore::RenderTableSection::paint):
1641         * rendering/render_layer.cpp:
1642         (WebCore::RenderLayer::updateLayerPosition):
1643         (WebCore::RenderLayer::isTransparent):
1644         (WebCore::RenderLayer::transparentAncestor):
1645         (WebCore::RenderLayer::beginTransparencyLayers):
1646         (WebCore::RenderLayer::paintLayer):
1647         (WebCore::RenderLayer::absoluteBoundingBox):
1648         * rendering/render_object.cpp:
1649         (WebCore::RenderObject::requiresLayer):
1650         * rendering/render_object.h:
1651         (WebCore::RenderObject::isTransparent):
1652         (WebCore::RenderObject::opacity):
1653
1654 2006-03-17  Maciej Stachowiak  <mjs@apple.com>
1655
1656         Reviewed by Adele.
1657
1658         - clean up ResourceRequest to be closer to a proper request interface
1659
1660         * page/ResourceRequest.h: folded URL into ResourceRequest, other cleanup
1661         (WebCore::ResourceRequest::ResourceRequest): Add new explicit constructor
1662         that takes a KURL.
1663         (WebCore::ResourceRequest::url): getter for KURL
1664         (WebCore::ResourceRequest::setURL): corresponding setter
1665         (WebCore::ResourceRequest::referrer): new getter for referrer, instead
1666         of storing it in m_metaData (it was the only remaining real use of it)
1667         (WebCore::ResourceRequest::setReferrer): corresponding setter
1668         * bridge/BrowserExtension.h: 
1669         - removed unused openURLRequest and openURLNotify methods
1670         - folded KURL parameter into ResourceRequest
1671         * bridge/mac/BrowserExtensionMac.h: remove KURL args from methods that
1672         also take a ResourceRequest
1673         * bridge/mac/BrowserExtensionMac.mm:
1674         (WebCore::BrowserExtensionMac::createNewWindow): adjust for ResourceRequest
1675         changes.
1676         * bridge/mac/MacFrame.h: remove KURL args from methods that also take a
1677         ResourceRequest
1678         * bridge/mac/MacFrame.mm:
1679         (WebCore::MacFrame::openURLRequest): adjust for ResourceRequest changes
1680         (WebCore::MacFrame::submitForm): ditto
1681         (WebCore::MacFrame::urlSelected): ditto
1682         * bridge/mac/WebCoreFrameBridge.mm:
1683         (-[WebCoreFrameBridge openURL:reload:contentType:refresh:lastModified:pageCache:]): 
1684         adjust for ResourceRequest changes
1685         * bridge/win/BrowserExtensionWin.h:
1686         * khtml/ecma/kjs_window.cpp:
1687         (KJS::createNewWindow): adjust for ResourceRequest changes
1688         (KJS::WindowFunc::callAsFunction): ditto
1689         * page/Frame.cpp:
1690         (WebCore::Frame::didOpenURL): adjust for ResourceRequest changes
1691         (WebCore::Frame::receivedFirstData): ditto
1692         (WebCore::Frame::begin): ditto
1693         (WebCore::Frame::completeURL): ditto
1694         (WebCore::Frame::changeLocation): ditto
1695         (WebCore::Frame::urlSelected): ditto
1696         (WebCore::Frame::requestFrame): ditto
1697         (WebCore::Frame::submitForm): ditto
1698         * page/Frame.h:
1699         * platform/win/TemporaryLinkStubs.cpp:
1700         (BrowserExtensionWin::createNewWindow): ditto
1701
1702 2006-03-17  Adele Peterson  <adele@apple.com>
1703
1704         Reviewed by Tim H.
1705
1706         Make default backgrounds for new text fields white
1707         instead of transparent.  This will move to html4.css
1708         when we flip the switch.
1709
1710         Test added:
1711         * fast/forms/input-appearance-default-bkcolor.html
1712
1713         * rendering/render_theme_mac.mm:
1714         (WebCore::RenderThemeMac::adjustTextFieldStyle):
1715
1716 2006-03-17  David Hyatt  <hyatt@apple.com>
1717
1718         Make table sections and table captions support opacity.
1719
1720         Reviewed by darin
1721
1722         Covered by some of the new Mozilla table tests.
1723
1724         * rendering/RenderTable.cpp:
1725         (WebCore::RenderTable::paint):
1726
1727 2006-03-17  Mitz Pettel  <opendarwin.org@mitzpettel.com>
1728
1729         Reviewed by Maciej, landed by Beth.
1730
1731         fix http://bugzilla.opendarwin.org/show_bug.cgi?id=3560
1732         page with use of first-letter crashes reproducibly in 
1733         RenderObject::renderArena()
1734
1735         * rendering/RenderBlock.cpp:
1736         (WebCore::RenderBlock::updateFirstLetter): Pass the first-leter 
1737         renderer to the remaining text fragment.
1738         * rendering/RenderContainer.cpp:
1739         (WebCore::RenderContainer::destroyLeftoverChildren): Do not destroy 
1740         first-letter renderers since they are destroyed by their remaining 
1741         text now.
1742         * rendering/RenderTextFragment.cpp:
1743         (khtml::RenderTextFragment::RenderTextFragment):
1744         (khtml::RenderTextFragment::destroy): Destroy the first-letter 
1745         renderer.
1746         * rendering/RenderTextFragment.h:
1747         (khtml::RenderTextFragment::firstLetter):
1748
1749 2006-03-17  Adele Peterson  <adele@apple.com>
1750
1751         Reviewed by Eric.
1752
1753         - Fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=7798 
1754         New text fields are much wider than they should be for a specified size
1755
1756         I changed the character we use to calculate the width from "w" back to "0", 
1757         which matches our old behavior.  The original change was intentional, to try
1758         to better match other browsers, but "w" is a little too wide.  For now, lets
1759         go back to the old behavior.
1760
1761         I also set the minWidth = maxWidth.  We were trying to match a WinIE quirk,
1762         but that caused some odd behavior with growth of the text field in table cells.
1763
1764         * rendering/RenderTextField.cpp: (WebCore::RenderTextField::calcMinMaxWidth):
1765
1766 2006-03-17  Eric Seidel  <eseidel@apple.com>
1767
1768         Reviewed by adele.
1769
1770         Fix win32 build.
1771         Add PageWin class.
1772         Add previously forgotten KeyEventWin class.
1773         Pass MouseEvent() instead of 0 in a couple places to make compiler happy.
1774
1775         * WebCore.vcproj/WebCore/WebCore.vcproj:
1776         * bridge/win/BrowserExtensionWin.h:
1777         * bridge/win/FrameWin.cpp:
1778         (WebCore::FrameWin::urlSelected):
1779         (WebCore::FrameWin::keyPress):
1780         * bridge/win/FrameWin.h:
1781         * bridge/win/PageWin.cpp: Added.
1782         (WebCore::rootWindowForFrame):
1783         (WebCore::Page::windowRect):
1784         (WebCore::Page::setWindowRect):
1785         * page/FrameView.cpp:
1786         (WebCore::FrameView::updateDragAndDrop):
1787         (WebCore::FrameView::hoverTimerFired):
1788         * page/Page.h:
1789         (WebCore::Page::mainFrame):
1790         * platform/win/KeyEventWin.cpp: Added.
1791         (WebCore::KeyEvent::KeyEvent):
1792         * platform/win/TemporaryLinkStubs.cpp:
1793         (WebCore::findNextWordFromIndex):
1794         (FrameWin::passMouseDownEventToWidget):
1795         (FrameWin::scheduleClose):
1796         (BrowserExtensionWin::createNewWindow):
1797         (WebCore::findWordBoundary):
1798         (FrameWin::registerCommandForUndo):
1799         (FrameWin::markMisspellingsInAdjacentWords):
1800         (FrameWin::respondToChangedContents):
1801
1802 2006-03-17  David Hyatt  <hyatt@apple.com>
1803
1804         Fix pixel test regression in fast/table/overflowHidden.html.  There was
1805         a borderTopExtra error made in the new boundingBox code for layers that
1806         caused the bottom half of cells with opacity set to be clipped out.
1807
1808         Reviewed by andersca
1809
1810         * rendering/render_layer.cpp:
1811         (WebCore::RenderLayer::absoluteBoundingBox):
1812
1813 2006-03-17  David Hyatt  <hyatt@apple.com>
1814
1815         Give table rows and sections accurate dimensions.  Fix absolutePosition
1816         to work for table cells properly.  Add an absolutePositionForContent method
1817         to make sure callers that want to deal with the content of a cell handle
1818         the cell's extra space correctly.
1819
1820         Reviewed by darin
1821
1822         Existing layout tests cover this change.
1823
1824         * bridge/mac/WebCoreFrameBridge.mm:
1825         (-[WebCoreFrameBridge copyRenderNode:copier:]):
1826         * dom/ContainerNodeImpl.cpp:
1827         (WebCore::ContainerNodeImpl::getUpperLeftCorner):
1828         (WebCore::ContainerNodeImpl::getLowerRightCorner):
1829         * dom/NodeImpl.cpp:
1830         (WebCore::NodeImpl::getRect):
1831         * editing/SelectionController.cpp:
1832         (WebCore::SelectionController::layout):
1833         (WebCore::SelectionController::caretRect):
1834         * editing/visible_units.cpp:
1835         (WebCore::previousLinePosition):
1836         (WebCore::nextLinePosition):
1837         * khtml/html/HTMLInputElementImpl.cpp:
1838         (WebCore::HTMLInputElementImpl::defaultEventHandler):
1839         * kwq/KWQRenderTreeDebug.cpp:
1840         (operator<<):
1841         * rendering/RenderBlock.cpp:
1842         (WebCore::RenderBlock::selectionGapRects):
1843         (WebCore::RenderBlock::positionForCoordinates):
1844         * rendering/RenderContainer.cpp:
1845         (WebCore::RenderContainer::positionForCoordinates):
1846         (WebCore::RenderContainer::lineBoxRects):
1847         * rendering/RenderTableCell.cpp:
1848         (WebCore::RenderTableCell::computeAbsoluteRepaintRect):
1849         (WebCore::RenderTableCell::absolutePosition):
1850         * rendering/RenderTableRow.cpp:
1851         (WebCore::RenderTableRow::addChild):
1852         (WebCore::RenderTableRow::getAbsoluteRepaintRect):
1853         (WebCore::RenderTableRow::nodeAtPoint):
1854         * rendering/RenderTableRow.h:
1855         * rendering/RenderTableSection.cpp:
1856         (WebCore::RenderTableSection::ensureRows):
1857         (WebCore::RenderTableSection::addCell):
1858         (WebCore::RenderTableSection::layoutRows):
1859         (WebCore::RenderTableSection::recalcCells):
1860         (WebCore::RenderTableSection::nodeAtPoint):
1861         * rendering/RenderTableSection.h:
1862         * rendering/RenderText.cpp:
1863         (WebCore::RenderText::lineBoxRects):
1864         (WebCore::RenderText::positionForCoordinates):
1865         (WebCore::RenderText::caretRect):
1866         (WebCore::RenderText::posOfChar):
1867         (WebCore::RenderText::selectionRect):
1868         * rendering/render_box.cpp:
1869         (WebCore::RenderBox::absolutePosition):
1870         (WebCore::RenderBox::caretRect):
1871         * rendering/render_br.cpp:
1872         (WebCore::RenderBR::caretRect):
1873         * rendering/render_canvas.h:
1874         * rendering/render_flow.cpp:
1875         (WebCore::RenderFlow::caretRect):
1876         * rendering/render_frames.cpp:
1877         (WebCore::RenderPart::updateWidgetPosition):
1878         * rendering/render_layer.cpp:
1879         (WebCore::RenderLayer::updateLayerPosition):
1880         * rendering/render_object.cpp:
1881         (WebCore::RenderObject::absoluteRects):
1882         (WebCore::RenderObject::absoluteBoundingBoxRect):
1883         (WebCore::RenderObject::absolutePosition):
1884         * rendering/render_object.h:
1885         (WebCore::RenderObject::absolutePositionForContent):
1886         (WebCore::RenderObject::offsetHeight):
1887         * rendering/render_replaced.cpp:
1888         (WebCore::RenderWidget::updateWidgetPosition):
1889
1890 2006-03-17  Adele Peterson  <adele@apple.com>
1891
1892         Reviewed by Hyatt.
1893
1894         WebCore part of fix for:
1895         http://bugzilla.opendarwin.org/show_bug.cgi?id=7797 
1896         Can't set background color on new text fields
1897
1898         Bezeled NSTextFieldCells always draw a background, so instead we'll use a new 
1899         WebKitSystemInterface function to just draw the border of the cell.
1900
1901         Since the theme is drawing the border and the engine is drawing the background 
1902         (which is different from the other form controls), we have to make sure we let the 
1903         theme paint the border after the engine paints the background.
1904
1905         * platform/mac/WebCoreGraphicsBridge.h:
1906         * platform/mac/WebCoreGraphicsBridge.m:
1907         (-[WebCoreGraphicsBridge drawBezeledTextFieldCell:enabled:]):
1908         * rendering/render_box.cpp: (WebCore::RenderBox::paintBoxDecorations):
1909         * rendering/render_theme.cpp:
1910         (WebCore::RenderTheme::paint):
1911         (WebCore::RenderTheme::paintBorder):
1912         (WebCore::RenderTheme::shouldPaintBorder):
1913         * rendering/render_theme.h:
1914         * rendering/render_theme_mac.mm:
1915         (WebCore::RenderThemeMac::paintTextField):
1916         (WebCore::RenderThemeMac::setTextFieldCellState):
1917
1918 2006-03-16  Darin Adler  <darin@apple.com>
1919
1920         Reviewed by Eric.
1921
1922         - removed KWQWindowWidget
1923         - changed most event handling to use references instead of pointers
1924         - chagned PageMac to no longer be a subclass of Page
1925
1926         Yes, I know there's no detail in this ChangeLog entry.
1927         No, I don't plan to make a habit of doing things this way.
1928         Yes, this will probably break the Windows build again.
1929
1930         * WebCore.xcodeproj/project.pbxproj:
1931         * bridge/mac/BrowserExtensionMac.mm:
1932         (WebCore::BrowserExtensionMac::createNewWindow):
1933         * bridge/mac/FrameViewMac.mm:
1934         * bridge/mac/MacFrame.h:
1935         * bridge/mac/MacFrame.mm:
1936         (WebCore::MacFrame::MacFrame):
1937         (WebCore::MacFrame::~MacFrame):
1938         (WebCore::MacFrame::wheelEvent):
1939         (WebCore::MacFrame::keyEvent):
1940         (WebCore::MacFrame::khtmlMousePressEvent):
1941         (WebCore::MacFrame::khtmlMouseMoveEvent):
1942         (WebCore::MacFrame::khtmlMouseReleaseEvent):
1943         (WebCore::MacFrame::mouseDown):
1944         (WebCore::MacFrame::mouseDragged):
1945         (WebCore::MacFrame::mouseUp):
1946         (WebCore::MacFrame::mouseMoved):
1947         (WebCore::MacFrame::sendContextMenuEvent):
1948         (WebCore::MacFrame::setBridge):
1949         (WebCore::MacFrame::dragSourceMovedTo):
1950         (WebCore::MacFrame::dragSourceEndedAt):
1951         (WebCore::MacFrame::dispatchDragSrcEvent):
1952         * bridge/mac/PageMac.h: Removed.
1953         * bridge/mac/PageMac.mm: Added.
1954         (WebCore::Page::Page):
1955         (WebCore::Page::windowRect):
1956         (WebCore::Page::setWindowRect):
1957         * bridge/mac/WebCoreFrameBridge.h:
1958         * bridge/mac/WebCoreFrameBridge.mm:
1959         (-[WebCoreFrameBridge page]):
1960         (-[WebCoreFrameBridge initializeSettings:]):
1961         (globalPoint):
1962         (createMouseEventFromDraggingInfo):
1963         (-[WebCoreFrameBridge dragOperationForDraggingInfo:]):
1964         (-[WebCoreFrameBridge dragExitedWithDraggingInfo:]):
1965         (-[WebCoreFrameBridge concludeDragForDraggingInfo:]):
1966         (-[WebCoreFrameBridge dragSourceMovedTo:]):
1967         (-[WebCoreFrameBridge dragSourceEndedAt:operation:]):
1968         * bridge/mac/WebCoreFrameNamespaces.mm:
1969         (WebCore::):
1970         * bridge/mac/WebCorePageBridge.h:
1971         * bridge/mac/WebCorePageBridge.mm:
1972         (-[WebCorePageBridge init]):
1973         * dom/DocumentImpl.cpp:
1974         (WebCore::DocumentImpl::prepareMouseEvent):
1975         (WebCore::DocumentImpl::defaultEventHandler):
1976         * dom/DocumentImpl.h:
1977         * dom/NodeImpl.cpp:
1978         (WebCore::NodeImpl::dispatchMouseEvent):
1979         (WebCore::NodeImpl::dispatchKeyEvent):
1980         (WebCore::NodeImpl::dispatchWheelEvent):
1981         * dom/NodeImpl.h:
1982         * dom/dom2_eventsimpl.cpp:
1983         (WebCore::KeyboardEventImpl::KeyboardEventImpl):
1984         * dom/dom2_eventsimpl.h:
1985         (WebCore::KeyboardEventImpl::keyEvent):
1986         * khtml/ecma/kjs_window.cpp:
1987         (KJS::Window::getValueProperty):
1988         (KJS::WindowFunc::callAsFunction):
1989         * khtml/html/html_inlineimpl.cpp:
1990         (WebCore::HTMLAnchorElementImpl::defaultEventHandler):
1991         * ksvg2/svg/SVGDocumentImpl.cpp:
1992         * ksvg2/svg/SVGDocumentImpl.h:
1993         * kwq/KWQWindowWidget.h:
1994         * kwq/KWQWindowWidget.mm: Removed.
1995         * page/Frame.cpp:
1996         (WebCore::Frame::selectClosestWordFromMouseEvent):
1997         (WebCore::Frame::handleMousePressEventDoubleClick):
1998         (WebCore::Frame::handleMousePressEventTripleClick):
1999         (WebCore::Frame::handleMousePressEventSingleClick):
2000         (WebCore::Frame::khtmlMousePressEvent):
2001         (WebCore::Frame::handleMouseMoveEventSelection):
2002         (WebCore::Frame::khtmlMouseMoveEvent):
2003         (WebCore::Frame::khtmlMouseReleaseEvent):
2004         (WebCore::Frame::khtmlMouseDoubleClickEvent):
2005         (WebCore::Frame::passWidgetMouseDownEventToWidget):
2006         * page/Frame.h:
2007         * page/FrameView.cpp:
2008         (WebCore::FrameView::viewportMousePressEvent):
2009         (WebCore::FrameView::viewportMouseDoubleClickEvent):
2010         (WebCore::FrameView::viewportMouseMoveEvent):
2011         (WebCore::FrameView::viewportMouseReleaseEvent):
2012         (WebCore::FrameView::dispatchDragEvent):
2013         (WebCore::FrameView::updateDragAndDrop):
2014         (WebCore::FrameView::cancelDragAndDrop):
2015         (WebCore::FrameView::performDragAndDrop):
2016         (WebCore::FrameView::dispatchMouseEvent):
2017         (WebCore::FrameView::viewportWheelEvent):
2018         * page/FrameView.h:
2019         * page/MouseEventWithHitTestResults.h:
2020         (WebCore::MouseEventWithHitTestResults::MouseEventWithHitTestResults):
2021         (WebCore::MouseEventWithHitTestResults::event):
2022         * page/Page.cpp:
2023         (WebCore::Page::init):
2024         * page/Page.h:
2025         (WebCore::Page::bridge):
2026         * platform/KeyEvent.h:
2027         (WebCore::KeyEvent::isAutoRepeat):
2028         * platform/MouseEvent.h:
2029         (WebCore::MouseEvent::MouseEvent):
2030         * platform/mac/KeyEventMac.mm:
2031         (WebCore::KeyEvent::KeyEvent):
2032         * platform/win/TemporaryLinkStubs.cpp:
2033         (FrameView::isFrameView):
2034         * rendering/render_form.cpp:
2035         (WebCore::RenderFormElement::clicked):
2036
2037 2006-03-16  Eric Seidel  <eseidel@apple.com>
2038
2039         Reviewed by darin.
2040
2041         Add additional hackish Font, focusring and caret code.
2042         http://bugzilla.opendarwin.org/show_bug.cgi?id=7803
2043
2044         * WebCore.vcproj/WebCore/WebCore.vcproj:
2045         * WebCore.vcproj/WebCore/build-generated-files.sh:
2046         * bindings/js/JSCanvasRenderingContext2DBase.cpp:
2047         * bridge/win/FrameWin.cpp:
2048         (WebCore::FrameWin::keyPress):
2049         * bridge/win/FrameWin.h:
2050         * html/CanvasRenderingContext2D.h:
2051         * platform/IntSize.h:
2052         * platform/KeyEvent.h:
2053         * platform/cairo/GraphicsContextCairo.cpp:
2054         (WebCore::GraphicsContext::drawArc):
2055         (WebCore::GraphicsContext::drawFocusRing):
2056         * platform/win/FontWin.cpp:
2057         (WebCore::hackishExtentForString):
2058         (WebCore::Font::floatWidth):
2059         (WebCore::convertRange):
2060         (WebCore::Font::drawText):
2061         (WebCore::Font::drawHighlightForText):
2062         (WebCore::Font::selectionRectForText):
2063         (WebCore::Font::checkSelectionPoint):
2064         (WebCore::Font::drawLineForText):
2065         (WebCore::Font::misspellingLineThickness):
2066         * platform/win/IntSizeWin.cpp: Added.
2067         (WebCore::IntSize::IntSize):
2068         (WebCore::IntSize::operator SIZE):
2069         * platform/win/ScrollViewWin.cpp:
2070         (WebCore::ScrollView::visibleContentRect):
2071         * platform/win/TemporaryLinkStubs.cpp:
2072         (Widget::disableFlushDrawing):
2073         (GraphicsContext::GraphicsContext):
2074         (QListBox::setSelected):
2075         (QListBox::sizeForNumberOfLines):
2076         (QListBox::isSelected):
2077         (QListBox::appendItem):
2078         (QListBox::doneAppendingItems):
2079         (FrameWin::locationbarVisible):
2080         (FrameWin::canUndo):
2081         (FrameWin::mimeTypeForFileName):
2082         (FrameWin::issueTransposeCommand):
2083         (RenderCanvasImage::setNeedsImageUpdate):
2084         (FrameWin::shouldChangeSelection):
2085         (FrameWin::respondToChangedSelection):
2086         (FrameWin::clearRecordedFormValues):
2087         (FrameWin::recordFormValue):
2088         (BrowserExtensionWin::getHistoryLength):
2089         (Widget::setIsSelected):
2090         (GraphicsContext::selectedTextBackgroundColor):
2091         (GraphicsContext::addRoundedRectClip):
2092         (QScrollBar::QScrollBar):
2093         (QScrollBar::~QScrollBar):
2094         (QScrollBar::setSteps):
2095         (QScrollBar::scroll):
2096         (QScrollBar::setValue):
2097         (QScrollBar::setKnobProportion):
2098         (QListBox::QListBox):
2099         (QListBox::~QListBox):
2100         (QListBox::setSelectionMode):
2101         (QListBox::setFont):
2102         * rendering/render_canvasimage.h:
2103
2104 2006-03-16  Maciej Stachowiak  <mjs@apple.com>
2105
2106         Reviewed by Eric.
2107
2108         - renamed URLArgs to ResourceRequest, split it into its own header
2109         - moved methods to get and set ResourceRequest to Frame
2110
2111         * WebCore.xcodeproj/project.pbxproj:
2112         * bridge/BrowserExtension.h:
2113         * bridge/mac/BrowserExtensionMac.h:
2114         * bridge/mac/BrowserExtensionMac.mm:
2115         (WebCore::BrowserExtensionMac::openURLRequest):
2116         (WebCore::BrowserExtensionMac::createNewWindow):
2117         * bridge/mac/MacFrame.h:
2118         * bridge/mac/MacFrame.mm:
2119         (WebCore::MacFrame::openURLRequest):
2120         (WebCore::MacFrame::submitForm):
2121         (WebCore::MacFrame::urlSelected):
2122         * bridge/mac/WebCoreFrameBridge.mm:
2123         (-[WebCoreFrameBridge openURL:reload:contentType:refresh:lastModified:pageCache:]):
2124         * khtml/ecma/kjs_window.cpp:
2125         (KJS::createNewWindow):
2126         (KJS::WindowFunc::callAsFunction):
2127         * page/Frame.cpp:
2128         (WebCore::Frame::didOpenURL):
2129         (WebCore::Frame::receivedFirstData):
2130         (WebCore::Frame::setResourceRequest):
2131         (WebCore::Frame::resourceRequest):
2132         (WebCore::Frame::begin):
2133         (WebCore::Frame::changeLocation):
2134         (WebCore::Frame::urlSelected):
2135         (WebCore::Frame::requestFrame):
2136         (WebCore::Frame::submitForm):
2137         * page/Frame.h:
2138         * page/FramePrivate.h:
2139         * page/ResourceRequest.h: Added.
2140         (WebCore::ResourceRequest::ResourceRequest):
2141         (WebCore::ResourceRequest::contentType):
2142         (WebCore::ResourceRequest::setContentType):
2143         (WebCore::ResourceRequest::doPost):
2144         (WebCore::ResourceRequest::setDoPost):
2145         (WebCore::ResourceRequest::lockHistory):
2146         (WebCore::ResourceRequest::setLockHistory):
2147         (WebCore::ResourceRequest::metaData):
2148
2149 2006-03-16  Darin Adler  <darin@apple.com>
2150
2151         - need to touch one more file to fix the build
2152           (Darn the lack of dependencies for autogenerated bindings!)
2153
2154         * dom/Element.idl: Touch. (Really this time.)
2155
2156 2006-03-16  Eric Seidel  <eseidel@apple.com>
2157
2158         Reviewed by darin.
2159
2160         Pushed focus ring handling down into GraphicsContext.cpp
2161
2162         * bridge/mac/MacFrame.mm:
2163         (WebCore::MacFrame::mouseDown):
2164         * platform/GraphicsContext.cpp:
2165         (WebCore::GraphicsContext::initFocusRing):
2166         (WebCore::GraphicsContext::clearFocusRing):
2167         (WebCore::GraphicsContext::addFocusRingRect):
2168         * platform/GraphicsContext.h:
2169         * platform/mac/GraphicsContextMac.mm:
2170         (WebCore::GraphicsContextPrivate::GraphicsContextPrivate):
2171         (WebCore::GraphicsContextPrivate::~GraphicsContextPrivate):
2172         (WebCore::GraphicsContext::GraphicsContext):
2173         (WebCore::GraphicsContext::drawFocusRing):
2174         * rendering/render_flow.cpp:
2175         (WebCore::RenderFlow::addFocusRingRects):
2176         * rendering/render_object.cpp:
2177         (WebCore::RenderObject::addFocusRingRects):
2178
2179 2006-03-15  Darin Adler  <darin@apple.com>
2180
2181         Reviewed by Hyatt.
2182
2183         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=7749
2184           canvas should be in DOM, not implemented in the JS bindings
2185
2186         * WebCore.xcodeproj/project.pbxproj: Added new files.
2187         Changed bindings-generation code to work on the new html directory
2188         as well as the dom one.
2189
2190         * bindings/js/JSCanvasRenderingContext2DBase.cpp: Added.
2191         * bindings/js/JSCanvasRenderingContext2DBase.h: Added.
2192         * bindings/js/JSDOMHTML.cpp: Added.
2193         * html: Added.
2194         * html/CanvasGradient.cpp: Added.
2195         * html/CanvasGradient.h: Added.
2196         * html/CanvasGradient.idl: Added.
2197         * html/CanvasPattern.cpp: Added.
2198         * html/CanvasPattern.h: Added.
2199         * html/CanvasPattern.idl: Added.
2200         * html/CanvasRenderingContext2D.cpp: Added.
2201         * html/CanvasRenderingContext2D.h: Added.
2202         * html/CanvasRenderingContext2D.idl: Added.
2203         * html/CanvasStyle.cpp: Added.
2204         * html/CanvasStyle.h: Added.
2205
2206         * bindings/js/JSDOMCore.cpp: Touched so that it will recompile.
2207         * bindings/js/JSDOMEvents.cpp: Ditto.
2208         * dom/Attr.idl: Ditto.
2209         * dom/DOMImplementation.idl: Ditto.
2210         * dom/DocumentType.idl: Ditto.
2211         * dom/MutationEvent.idl: Ditto.
2212         * dom/ProcessingInstruction.idl: Ditto.
2213         * dom/Text.idl: Ditto.
2214
2215         * khtml/ecma/kjs_binding.h: (KJS::toJS): Added. Template so that you can call
2216         toJS on a PassRefPtr as well as on a raw pointer.
2217
2218         * bindings/scripts/CodeGeneratorJS.pm: Fixed handling of a class that has only
2219         a legacy parent, no conventional parents. Added JSCanvasRenderingContext2DBase
2220         as a legacy parent, and html as a legacy module. Added CanvasRenderingContext2D,
2221         CanvasGradient, and CanvasPattern to the "waht to include". Added a special
2222         case for strings beginning with Canvas to not add an "Impl" suffix. Made the
2223         generated impl() function be a const member function. Made m_mimpl be private
2224         instead of protected. Generate a toJS function for each class. Added flaot as
2225         a type. Generate String, not DOMString. Made the HashTable const.
2226
2227         * bindings/scripts/IDLParser.pm: Fix a couple small things. I had started to
2228         try to make a missing semicolon trigger an error, but ended up giving up on
2229         that for now.
2230
2231         * khtml/html/html_canvasimpl.h:
2232         * khtml/html/html_canvasimpl.cpp:
2233         (WebCore::HTMLCanvasElementImpl::HTMLCanvasElementImpl): Set m_2DContext to 0.
2234         (WebCore::HTMLCanvasElementImpl::~HTMLCanvasElementImpl): Call detachCanvas
2235         on m_2DContext, if any.
2236         (WebCore::HTMLCanvasElementImpl::detach): Call reset on m_2DContext, if any.
2237         (WebCore::HTMLCanvasElementImpl::getContext): Added.
2238         (WebCore::HTMLCanvasElementImpl::size): Added.
2239         (WebCore::HTMLCanvasElementImpl::createPlatformImage): Added.
2240
2241         * platform/Image.h:
2242         * platform/Image.cpp: (WebCore::Image::compositeOperatorFromString):
2243         Changed to take a String instead of a const char*.
2244
2245         * khtml/html/html_imageimpl.h:
2246         * khtml/html/html_imageimpl.cpp: (WebCore::HTMLMapElementImpl::areas):
2247         Tweaked formatting. Changed to use PassRefPtr.
2248
2249         * bindings/objc/DOMInternal.mm: (-[WebScriptObject _initializeScriptDOMNodeImp]):
2250         * khtml/ecma/JSXMLHttpRequest.cpp: (KJS::JSXMLHttpRequest::getValueProperty):
2251         * khtml/ecma/XSLTProcessor.cpp: (KJS::XSLTProcessorProtoFunc::callAsFunction):
2252         * khtml/ecma/domparser.cpp: (KJS::DOMParserProtoFunc::callAsFunction):
2253         * khtml/ecma/kjs_css.cpp:
2254         (KJS::DOMCSSStyleDeclaration::getValueProperty):
2255         (KJS::DOMCSSStyleDeclarationProtoFunc::callAsFunction):
2256         (KJS::toJS):
2257         (KJS::DOMStyleSheet::getValueProperty):
2258         (KJS::DOMStyleSheetList::indexGetter):
2259         (KJS::DOMStyleSheetList::nameGetter):
2260         (KJS::DOMStyleSheetListFunc::callAsFunction):
2261         (KJS::DOMCSSStyleSheet::getValueProperty):
2262         (KJS::DOMCSSRuleList::indexGetter):
2263         (KJS::DOMCSSRuleListFunc::callAsFunction):
2264         (KJS::DOMCSSRule::getValueProperty):
2265         (KJS::DOMCSSPrimitiveValueProtoFunc::callAsFunction):
2266         (KJS::DOMCSSValueList::indexGetter):
2267         (KJS::DOMCSSValueListFunc::callAsFunction):
2268         (KJS::DOMRect::getValueProperty):
2269         * khtml/ecma/kjs_css.h:
2270         * khtml/ecma/kjs_dom.cpp:
2271         (KJS::DOMNode::getValueProperty):
2272         (KJS::DOMNodeProtoFunc::callAsFunction):
2273         (KJS::DOMNodeList::indexGetter):
2274         (KJS::DOMNodeList::nameGetter):
2275         (KJS::DOMNodeList::callAsFunction):
2276         (KJS::DOMNodeListFunc::callAsFunction):
2277         (KJS::DOMDocument::getValueProperty):
2278         (KJS::DOMDocumentProtoFunc::callAsFunction):
2279         (KJS::DOMNamedNodeMap::indexGetter):
2280         (KJS::DOMNamedNodeMap::nameGetter):
2281         (KJS::DOMNamedNodeMapProtoFunc::callAsFunction):
2282         (KJS::toJS):
2283         (KJS::DOMNamedNodesCollection::indexGetter):
2284         * khtml/ecma/kjs_dom.h:
2285         * khtml/ecma/kjs_events.cpp:
2286         (KJS::JSAbstractEventListener::handleEvent):
2287         (KJS::JSLazyEventListener::parseCode):
2288         (KJS::DOMEvent::getValueProperty):
2289         (KJS::toJS):
2290         (KJS::DOMUIEvent::getValueProperty):
2291         (KJS::DOMMouseEvent::getValueProperty):
2292         * khtml/ecma/kjs_events.h:
2293         * khtml/ecma/kjs_html.cpp:
2294         (KJS::HTMLDocFunction::callAsFunction):
2295         (KJS::HTMLDocument::namedItemGetter):
2296         (KJS::HTMLDocument::getValueProperty):
2297         (KJS::HTMLDocument::put):
2298         (KJS::HTMLDocument::putValueProperty):
2299         (KJS::HTMLElement::classInfo):
2300         (KJS::HTMLElement::formIndexGetter):
2301         (KJS::HTMLElement::selectIndexGetter):
2302         (KJS::HTMLElement::implementsCall):
2303         (KJS::HTMLElement::callAsFunction):
2304         (KJS::HTMLElement::linkGetter):
2305         (KJS::HTMLElement::isIndexGetter):
2306         (KJS::HTMLElement::styleGetter):
2307         (KJS::HTMLElement::selectGetter):
2308         (KJS::HTMLElement::optionGetter):
2309         (KJS::HTMLElement::inputGetter):
2310         (KJS::HTMLElement::textAreaGetter):
2311         (KJS::HTMLElement::buttonGetter):
2312         (KJS::HTMLElement::labelGetter):
2313         (KJS::HTMLElement::fieldSetGetter):
2314         (KJS::HTMLElement::legendGetter):
2315         (KJS::HTMLElement::objectGetter):
2316         (KJS::HTMLElement::tableGetter):
2317         (KJS::HTMLElement::frameGetter):
2318         (KJS::HTMLElement::iFrameGetter):
2319         (KJS::HTMLElement::getValueProperty):
2320         (KJS::HTMLElement::toString):
2321         (KJS::HTMLElement::pushEventHandlerScope):
2322         (KJS::toJS):
2323         (KJS::HTMLElementFunction::callAsFunction):
2324         (KJS::HTMLElement::put):
2325         (KJS::HTMLCollection::indexGetter):
2326         (KJS::HTMLCollection::callAsFunction):
2327         (KJS::HTMLCollection::getNamedItems):
2328         (KJS::HTMLCollectionProtoFunc::callAsFunction):
2329         (KJS::HTMLSelectCollection::put):
2330         (KJS::OptionConstructorImp::construct):
2331         (KJS::ImageConstructorImp::construct):
2332         * khtml/ecma/kjs_html.h:
2333         * khtml/ecma/kjs_proxy.cpp: (WebCore::KJSProxyImpl::evaluate):
2334         * khtml/ecma/kjs_range.cpp:
2335         (KJS::DOMRange::getValueProperty):
2336         (KJS::DOMRangeProtoFunc::callAsFunction):
2337         (KJS::toJS):
2338         * khtml/ecma/kjs_range.h:
2339         * khtml/ecma/kjs_traversal.cpp:
2340         (KJS::DOMNodeIterator::getValueProperty):
2341         (KJS::DOMNodeIteratorProtoFunc::callAsFunction):
2342         (KJS::toJS):
2343         (KJS::DOMTreeWalker::getValueProperty):
2344         (KJS::DOMTreeWalkerProtoFunc::callAsFunction):
2345         (KJS::JSNodeFilterCondition::acceptNode):
2346         * khtml/ecma/kjs_traversal.h:
2347         * khtml/ecma/kjs_views.cpp:
2348         (KJS::DOMAbstractView::getValueProperty):
2349         (KJS::DOMAbstractViewProtoFunc::callAsFunction):
2350         (KJS::toJS):
2351         * khtml/ecma/kjs_views.h:
2352         * khtml/ecma/kjs_window.cpp:
2353         (KJS::Window::getValueProperty):
2354         (KJS::Window::namedItemGetter):
2355         (KJS::Selection::getValueProperty):
2356         (KJS::SelectionFunc::callAsFunction):
2357         Rename uses and definitions of all the various converstions to JavaScript
2358         wrappers to the new common overloaded name: "toJS".
2359
2360 2006-03-15  Eric Seidel  <eseidel@apple.com>
2361
2362         Reviewed by darin.
2363
2364         Push more of MacFrame down into Frame.
2365         Add visibleContentRect method to ScrollView.
2366
2367         * bridge/mac/MacFrame.h:
2368         * bridge/mac/MacFrame.mm:
2369         (WebCore::MacFrame::imageFromRect):
2370         (WebCore::MacFrame::setDisplaysWithFocusAttributes):
2371         (WebCore::MacFrame::bodyBackgroundColor):
2372         * bridge/mac/WebCoreFrameBridge.mm:
2373         * page/Frame.cpp:
2374         (WebCore::Frame::visibleSelectionRect):
2375         (WebCore::Frame::setDisplaysWithFocusAttributes):
2376         * page/Frame.h:
2377         * platform/ScrollView.h:
2378         * platform/mac/ScrollViewMac.mm:
2379         (WebCore::ScrollView::visibleWidth):
2380         (WebCore::ScrollView::visibleHeight):
2381         (WebCore::ScrollView::visibleContentRect):
2382         (WebCore::ScrollView::contentsWidth):
2383         (WebCore::ScrollView::contentsHeight):
2384         (WebCore::ScrollView::contentsX):
2385         (WebCore::ScrollView::contentsY):
2386         (WebCore::ScrollView::scrollXOffset):
2387         (WebCore::ScrollView::scrollYOffset):
2388         (WebCore::ScrollView::inWindow):
2389
2390 2006-03-15  Eric Seidel  <eseidel@apple.com>
2391
2392         Reviewed by darin.
2393
2394         Remove unused code and clean-up style.
2395
2396         * bridge/mac/MacFrame.mm:
2397         (WebCore::MacFrame::advanceToNextMisspelling):
2398         (WebCore::MacFrame::wheelEvent):
2399         (WebCore::MacFrame::nextKeyViewInFrame):
2400         (WebCore::MacFrame::nextKeyViewInFrameHierarchy):
2401         (WebCore::MacFrame::nextKeyView):
2402         * page/Frame.cpp:
2403         * page/Frame.h:
2404         * page/FrameView.cpp:
2405         (WebCore::FrameView::dispatchMouseEvent):
2406
2407 2006-03-15  Eric Seidel  <eseidel@apple.com>
2408
2409         Reviewed by mjs.
2410
2411         http://bugzilla.opendarwin.org/show_bug.cgi?id=7790
2412         addEventListener does not work with "dblclick" event.
2413         Renamed khtmlDblclickEvent to dblclickEvent to fix.
2414
2415         Test: fast/events/dblclick-addEventListener.html
2416
2417         * WebCore.xcodeproj/project.pbxproj:
2418         * bridge/mac/MacFrame.mm:
2419         (WebCore::MacFrame::mouseUp):
2420         (WebCore::MacFrame::mouseMoved):
2421         (WebCore::MacFrame::shouldDragAutoNode):
2422         (WebCore::MacFrame::sendContextMenuEvent):
2423         * dom/EventNames.h:
2424         * dom/NodeImpl.cpp:
2425         (WebCore::NodeImpl::dispatchMouseEvent):
2426         * dom/NodeImpl.h:
2427         * khtml/ecma/kjs_binding.cpp:
2428         (KJS::ScriptInterpreter::wasRunByUserGesture):
2429         * khtml/ecma/kjs_dom.cpp:
2430         (KJS::DOMNode::getValueProperty):
2431         (KJS::DOMNode::putValueProperty):
2432         * khtml/ecma/kjs_window.cpp:
2433         (KJS::Window::getValueProperty):
2434         (KJS::Window::put):
2435         * khtml/html/HTMLElementImpl.cpp:
2436         (WebCore::HTMLElementImpl::parseMappedAttribute):
2437         * page/FrameView.cpp:
2438         (WebCore::FrameView::dispatchMouseEvent):
2439         * page/FrameView.h:
2440
2441 2006-03-16  Alexey Proskuryakov  <ap@nypop.com>
2442
2443         Reviewed by Maciej.
2444
2445         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=4395
2446          REGRESSION: document.open doesn't clear the document
2447
2448         Test: fast/dom/Document/document-reopen.html
2449         Test: fast/dom/Document/doc-open-while-parsing.html
2450
2451         * dom/DocumentImpl.cpp:
2452         (WebCore::DocumentImpl::open): Only ignore open() while the frame is still loading the main resource.
2453         * page/Frame.cpp:
2454         (WebCore::Frame::isComplete): Added const specifier.
2455         (WebCore::Frame::isLoadingMainResource): New function.
2456         * page/Frame.h:
2457
2458 2006-03-15  Adele Peterson  <adele@apple.com>
2459
2460         Reviewed by Eric.
2461
2462         - Fixes win32 build.
2463
2464         * page/Frame.cpp: (WebCore::Frame::autoscrollTimerFired): Calls isMouseButtonDown instead of CG function.
2465         * platform/MouseEvent.h: Added isMouseButtonDown
2466         * platform/mac/MouseEventMac.mm: (WebCore::MouseEvent::isMouseButtonDown): Calls CG function to get state of mouse button.
2467         * platform/win/TemporaryLinkStubs.cpp: (MouseEvent::isMouseButtonDown): Added stub.
2468
2469 2006-03-15  Eric Seidel  <eseidel@apple.com>
2470
2471         Reviewed by geoff.
2472
2473         * platform/KeyEvent.h: Fix #define from QEvent_H to KeyEvent_H
2474
2475 2006-03-15  David Hyatt  <hyatt@apple.com>
2476
2477         Fix the box-sizing layout test by stopping integer overflowing from
2478         occurring in the flexbox code.
2479
2480         Reviewed by beth
2481
2482         * rendering/render_flexbox.cpp:
2483         (khtml::RenderFlexibleBox::allowedChildFlex):
2484
2485 2006-03-15  Beth Dakin  <bdakin@apple.com>
2486
2487         Reviewed by Eric
2488
2489         Fix for some leaks and intermittent broken pipes in the layout 
2490         tests after check-in for http://bugzilla.opendarwin.org/
2491         show_bug.cgi?id=4171.  
2492
2493         * platform/StringImpl.cpp:
2494         (WebCore::StringImpl::capitalize): Call deleteQCharVector() for 
2495         stringWithPrevious and make sure we don't walk off the end of 
2496         stringWithPrevious when copying to capitalizedString.
2497
2498 2006-03-15  Adele Peterson  <adele@apple.com>
2499
2500        Reviewed by Maciej.
2501
2502        Followup fix for previous checkin.
2503        http://bugzilla.opendarwin.org/show_bug.cgi?id=7114
2504        <rdar://problem/3695120> dragging to scroll doesn't work with overflow:auto/scroll/overlay areas 
2505
2506        Many of the bugs related to the Radar bug have to do with autoscrolling in the RSS View.  
2507        This fix walks the layer tree to find the first scrollable layer, so that autoscrolling will 
2508        also work with nested layers, like those in the RSS View.
2509
2510        * bridge/mac/MacFrame.mm: (WebCore::MacFrame::khtmlMouseMoveEvent):
2511
2512 2006-03-15  Adele Peterson  <adele@apple.com>
2513
2514         Reviewed by Maciej.
2515
2516         - Fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=7114
2517         Dragging to scroll doesn't work for overflow areas
2518
2519         No test case.  There doesn't appear to be a way to trigger the autoscroll with the EventSender.
2520
2521         * bridge/mac/MacFrame.mm:
2522         (WebCore::MacFrame::khtmlMouseMoveEvent):  If we have a layer that can scroll, let the layer handle its autoscroll.  
2523          Otherwise, call over the bridge to let AppKit scroll the view.
2524         (WebCore::MacFrame::khtmlMouseReleaseEvent): Stops the autoscroll timer.
2525         * page/Frame.cpp:
2526         (WebCore::Frame::khtmlMouseReleaseEvent): Stops the autoscroll timer.
2527         (WebCore::Frame::handleAutoscroll): Added. Saves the layer, and starts the timer.
2528         (WebCore::Frame::autoscrollTimerFired): Added. Calls autoscroll() on the layer.
2529         (WebCore::Frame::startAutoscrollTimer): Added.
2530         (WebCore::Frame::stopAutoscrollTimer): Added.
2531         * page/Frame.h: Added new autoscroll methods.
2532         * page/FramePrivate.h: (WebCore::FramePrivate::FramePrivate): Initialize m_autoscrollTimer and m_autoscrollLayer.
2533         * rendering/render_layer.cpp:
2534         (WebCore::RenderLayer::autoscroll): Calculates how much the layer should scroll, and actually scrolls.
2535         (WebCore::RenderLayer::shouldAutoscroll): If the layer has overflow then it should be able to scroll.  
2536          Except for overflow:hidden areas that aren't editable.  
2537          In the future, we may want to have a css property that indicates an overflow:hidden style that should also scroll.
2538         * rendering/render_layer.h: Added new autoscroll methods.
2539
2540 2006-03-14  Justin Garcia  <justin.garcia@apple.com>
2541
2542         Reviewed by mjs
2543         
2544         <http://bugzilla.opendarwin.org/show_bug.cgi?id=7578>
2545         TinyMCE: Implement execCommand CreateLink
2546         
2547         Used ApplyStyleCommand so that creating a link from
2548         a selection doesn't change document structure.
2549
2550         * WebCore.xcodeproj/project.pbxproj:
2551         * editing/ApplyStyleCommand.cpp:
2552         (WebCore::ApplyStyleCommand::ApplyStyleCommand):
2553         (WebCore::ApplyStyleCommand::doApply):
2554         (WebCore::ApplyStyleCommand::removeInlineStyle):
2555         (WebCore::ApplyStyleCommand::addInlineStyleIfNeeded):
2556         * editing/ApplyStyleCommand.h:
2557         * editing/CompositeEditCommand.cpp:
2558         (WebCore::CompositeEditCommand::applyStyle):
2559         * editing/CreateLinkCommand.cpp: Added.
2560         (WebCore::CreateLinkCommand::CreateLinkCommand):
2561         (WebCore::CreateLinkCommand::doApply):
2562         * editing/CreateLinkCommand.h: Added.
2563         * editing/jsediting.cpp:
2564         * page/Frame.cpp:
2565         (WebCore::Frame::computeAndSetTypingStyle):
2566         (WebCore::Frame::applyStyle):
2567         (WebCore::Frame::applyParagraphStyle):
2568
2569 2006-03-14  Beth Dakin  <bdakin@apple.com>
2570
2571         Reviewed by Maciej
2572
2573         Fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=4171
2574         This patch changes the word-break algorithm used to apply text-
2575         transform:capitalize to use a UBreakIterator. This fixes some 
2576         existing edge cases we have in our text-transform:capitalize 
2577         support and generally makes our results more consistent.
2578
2579         * platform/StringImpl.cpp:
2580         (WebCore::getWordBreakIterator): Returns a UBreakIterator for a 
2581         given string of a given length.
2582         (WebCore::StringImpl::capitalize): Now uses the UBreakIterator to 
2583         step between words and requires the previous character as input.
2584         * platform/StringImpl.h: Change the declaration of capitalize() to 
2585         take the previous character as a parameter. 
2586         * rendering/RenderText.cpp:
2587         (WebCore::RenderText::setText): Find the previous character and 
2588         send it to StringImpl::capitalize()
2589
2590 2006-03-14  Justin Garcia  <justin.garcia@apple.com>
2591
2592         Reviewed by adele
2593         
2594         <http://bugzilla.opendarwin.org/show_bug.cgi?id=7770>
2595         Should only dispatch the khtmlTextInsertedEvent for high level editing operations
2596
2597         Dispatching this event for low level editing operations 
2598         isn't necessary and causes a big performance regression. 
2599         Also renamed the event because it's dispatched for changes
2600         other than just text insertion.
2601
2602         * dom/EventNames.h: 
2603         * editing/EditCommand.cpp:
2604         (WebCore::EditCommand::apply):
2605         (WebCore::EditCommand::unapply):
2606         (WebCore::EditCommand::reapply):
2607         * khtml/html/HTMLTextFieldInnerElementImpl.cpp:
2608         (WebCore::HTMLTextFieldInnerElementImpl::defaultEventHandler):
2609         * page/Frame.cpp:
2610         (WebCore::dispatchKHTMLEditableContentChanged):
2611         (WebCore::Frame::appliedEditing):
2612         (WebCore::Frame::unappliedEditing):
2613         (WebCore::Frame::reappliedEditing):
2614
2615 2006-03-14  Darin Adler  <darin@apple.com>
2616
2617         Reviewed by Eric.
2618
2619         - fix <rdar://problem/4478121> -[WebCoreFrameBridge finalize] crashes under GC
2620
2621         * bridge/mac/WebCoreFrameBridge.mm: (-[WebCoreFrameBridge finalize]):
2622         Don't call setBridge(nil).
2623
2624 2006-03-14  Darin Adler  <darin@apple.com>
2625
2626         - oops, didn't mean to check this in
2627
2628         * dom/dom_elementimpl.cpp: (WebCore::StyledElementImpl::parseMappedAttribute):
2629         Reverted nil-document check that I didn't mean to remove.
2630
2631 2006-03-14  Beth Dakin  <bdakin@apple.com>
2632
2633         Reviewed by Hyatt
2634
2635         Fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=6796
2636         This fix prevents infinite recursion when a block with overflow: 
2637         auto can't decide if it needs scrollbars or not. This fix puts a 
2638         guard in place in updateScrollInforAfterLayout that only allows you 
2639         to re-layout if you are not currently laying out.  
2640
2641         * rendering/render_layer.cpp:
2642         (WebCore::RenderLayer::RenderLayer): Initialize 
2643         m_inOverflowRelayout to false. Fixed spacing too.
2644         (WebCore::RenderLayer::updateScrollInfoAfterLayout): Place guard 
2645         around layout calls in overflow:auto case.
2646         * rendering/render_layer.h: Add m_inOverflowRelayout.
2647
2648 2006-03-14  Darin Adler  <darin@apple.com>
2649
2650         Reviewed by Geoff and Eric.
2651
2652         - fix <http://bugzilla.opendarwin.org/show_bug.cgi?id=7765>, <rdar://problem/4474884>
2653           hasAttribute always returns false for uppercase attribute names like "STYLE"
2654         - re-add missing JavaScript binding for getAttributeNS
2655         - fixed handling of null namespace parameters in getAttributeNS and friends
2656
2657         Test: fast/dom/Element/attribute-uppercase.html
2658
2659         To match Gecko's behavior, the magic "lowercasing" of all attribute names
2660         is only done when calling DOM Level 1 functions that lack an NS suffix.
2661         The functions with an NS suffix are case sensitive, even in HTML documents.
2662
2663         * dom/NamedNodeMapImpl.h: Changed getNamedItem and removeNamedItem to be pure virtual
2664         functions instead of calling through to getNamedItemNS and removeNamedItemNS.
2665
2666         * dom/dom_elementimpl.h: Eliminated inline versions of non-NS functions that called
2667         the NS functions. They can't work that way any more since the lowercasing behavior
2668         is different.
2669         * dom/dom_elementimpl.cpp:
2670         (WebCore::ElementImpl::getAttribute): Added. Lowercases the name if the document
2671         is an HTML document, and then calls through to the qualified name version. Removed
2672         the null check since getDocument is guaranteed to never return 0 now that nodes
2673         hold a reference to their document.
2674         (WebCore::ElementImpl::getAttributeNS): Removed the lowercasing code.
2675         (WebCore::ElementImpl::setAttribute): More of the same.
2676         (WebCore::ElementImpl::setAttributeNS): Ditto.
2677         (WebCore::ElementImpl::removeAttribute): Ditto.
2678         (WebCore::ElementImpl::removeAttributeNS): Ditto.
2679         (WebCore::ElementImpl::getAttributeNode): Ditto.
2680         (WebCore::ElementImpl::getAttributeNodeNS): Ditto.
2681         (WebCore::ElementImpl::hasAttribute): Ditto.
2682         (WebCore::ElementImpl::hasAttributeNS): Ditto.
2683         (WebCore::NamedAttrMapImpl::getNamedItem): Ditto.
2684         (WebCore::NamedAttrMapImpl::getNamedItemNS): Ditto.
2685         (WebCore::NamedAttrMapImpl::removeNamedItem): Ditto.
2686         (WebCore::NamedAttrMapImpl::removeNamedItemNS): Ditto.
2687         (WebCore::StyledElementImpl::parseMappedAttribute): Removed another unneeded null
2688         check like the one mentioned above.
2689
2690         * dom/Element.idl: Set ConvertNullToNullString for all the namespaceURI
2691         parameters, since we don't want null to turn into "null". Added a semicolon
2692         to the end of the hasAttributeNS line -- was causing the next declaration to
2693         be eaten up (so getAttributeNS was completely broken).
2694
2695         * khtml/ecma/kjs_dom.cpp: (KJS::DOMNamedNodeMapProtoFunc::callAsFunction):
2696         Call valueToStringWithNullCheck to do the equivalent of ConvertNullToNullString
2697         for both getNamedItemNS and removeNamedItemNS.
2698
2699         * bindings/js/JSDOMCore.cpp: Touched so that the changes above will take effect.
2700
2701 2006-03-14  David Hyatt  <hyatt@apple.com>
2702
2703         Fix for bug 7259, opacity performs badly.
2704
2705         Reviewed by mjs
2706
2707         Adding some tests in fast/opacity.
2708
2709         * rendering/RenderTableRow.h:
2710         (WebCore::RenderTableRow::requiresLayer):
2711         * rendering/render_layer.cpp:
2712         (WebCore::transparencyClipBox):
2713         (WebCore::RenderLayer::beginTransparencyLayers):
2714         (WebCore::RenderLayer::paintLayer):
2715         (WebCore::RenderLayer::intersectsDamageRect):
2716         (WebCore::RenderLayer::absoluteBoundingBox):
2717         * rendering/render_layer.h:
2718         (WebCore::RenderLayer::root):
2719
2720 2006-03-14  Eric Seidel  <eseidel@apple.com>
2721
2722         Reviewed by mjs.
2723
2724         Fix Gif crasher.
2725
2726         * platform/image-decoders/gif/GIFImageReader.cpp:
2727         (GIFImageReader::do_lzw): Initialize array after new.
2728
2729 2006-03-14  Eric Seidel  <eseidel@apple.com>
2730
2731         Reviewed by mjs.
2732
2733         Make MouseEvents aware of current scroll position.
2734
2735         * platform/win/ScrollViewWin.cpp:
2736         (WebCore::ScrollView::viewportToContents):
2737         (WebCore::ScrollView::contentsToViewport):
2738
2739 2006-03-13  Eric Seidel  <eseidel@apple.com>
2740
2741         Reviewed by mjs.
2742
2743         Fix mouse events to be window-relative.
2744
2745         * platform/win/MouseEventWin.cpp:
2746         (WebCore::positionForEvent):
2747         (WebCore::globalPositionForEvent):
2748         (WebCore::MouseEvent::MouseEvent):
2749
2750 2006-03-13  Eric Seidel  <eseidel@apple.com>
2751
2752         Reviewed by mjs.
2753
2754         Close DeviceContext leaks in Font code.
2755         Also add moveCursor stub to make maps.google.com not crash.
2756
2757         * platform/win/FontWin.cpp:
2758         (WebCore::getFontData):
2759         (WebCore::Font::floatWidth):
2760         (WebCore::Font::drawText):
2761         * platform/win/TemporaryLinkStubs.cpp:
2762         (Cursor::Cursor):
2763         (WebCore::moveCursor):
2764
2765 2006-03-13  Eric Seidel  <eseidel@apple.com>
2766
2767         Reviewed by ggaren & TimH.
2768
2769         <rdar://problem/4473288> XSL file containing <xsl:include href="../Styles/EscapeString.xsl" /> fails to load file
2770         XML_DTD_NODE objects in the tree were causing loadChildSheets to 
2771         fail to preload child stylesheets, this patch causes us to 
2772         correctly ignore all nodes besides the first XML_ELEMENT_NODE at 
2773         the root level when searching the tree for xsl:include statements 
2774         to pre-load.
2775
2776         Test: fast/xsl/xslt-second-level-import.xml
2777
2778         * khtml/xsl/xsl_stylesheetimpl.cpp:
2779         (WebCore::XSLStyleSheetImpl::loadChildSheets):
2780
2781 2006-03-10  Rob Buis  <buis@kde.org>
2782
2783         Reviewed by darin.  Landed by eseidel.
2784
2785         Fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=7666:
2786         dasharray on rounded rectangles is broken
2787
2788         Make sure the rounded rectangle is drawn clockwise, as outlined
2789         in the specification.
2790
2791         Test: svg/custom/dashArrayOrigin.svg
2792
2793         * kcanvas/KCanvasCreator.cpp:
2794         (WebCore::KCanvasCreator::createRoundedRectangle):
2795
2796 2006-03-12  Mitz Pettel  <opendarwin.org@mitzpettel.com>
2797
2798         Reviewed by Maciej, landed by ap.
2799
2800         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=5923
2801           REGRESSION: scrolling on Google maps continues after the mouse is 
2802           released outside the window
2803
2804         Test: fast/events/drag-outside-window.html
2805
2806         * rendering/render_layer.cpp:
2807         (WebCore::RenderLayer::containsPoint): Always return true for the root
2808         object to ensure that mouse events occurring outside the window target
2809         the document.
2810
2811 2006-03-12  Alexey Proskuryakov  <ap@nypop.com>
2812
2813         Reviewed by Maciej.
2814
2815         - Fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=7735
2816         REGRESSION: crash on importing bookmarks
2817
2818         No test - only reproducible when Safari imports the bookmarks.
2819
2820         * dom/EventNames.cpp:
2821         (WebCore::EventNames::init): Initialize AtomicString before using it.
2822         * dom/QualifiedName.cpp:
2823         (WebCore::QualifiedName::init): Ditto.
2824         * khtml/html/htmlnames.cpp:
2825         (WebCore::HTMLNames::init): Ditto.
2826         * ksvg2/scripts/make_names.pl: Ditto.
2827
2828 2006-03-12  David Kilzer  <ddkilzer@kilzer.net>
2829
2830         Reviewed by Darin, landed by ap.
2831
2832         - Fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=7724
2833         Minor refactoring to HTMLParser::handleError() to remove duplicate code
2834
2835         Test: fast/invalid/missing-address-end-tag.html
2836         Test: fast/invalid/missing-dl-end-tag.html
2837         Test: fast/invalid/missing-dt-end-tag.html
2838         Test: fast/invalid/missing-font-end-tag.html
2839
2840         * khtml/html/htmlparser.cpp:
2841         (WebCore::HTMLParser::handleError): Refactored code.
2842
2843 2006-03-10  Darin Adler  <darin@apple.com>
2844
2845         - fix Windows build
2846
2847         * bridge/win/FrameWin.h: Removed declaration of generateFrameName.
2848
2849 2006-03-10  Darin Adler  <darin@apple.com>
2850
2851         Reviewed by Adele.
2852
2853         - removed some unused stuff from Frame and MacFrame
2854
2855         * page/Frame.h: Removed autoloadImages (the setter), enableMetaRefresh,
2856         setCharset, backgroundURL, findTextBegin, findTextNext, preloadStyleSheet,
2857         preloadScript, restored, onURL, selectionChanged, htmlError, openFile,
2858         updateActions, openURLInFrame, overURL, checkLinkSecurity, and cacheId.
2859         * page/FramePrivate.h: Removed m_restored, m_frameNameId, m_strSelectedURL,
2860         m_strSelectedURLTarget, m_bDnd, m_bClearing, m_bSecurityInQuestion,
2861         m_focusNodeRestored, m_focusNodeNumber, and m_newJSInterpreterExists.
2862         * page/Frame.cpp:
2863         (WebCore::Frame::didOpenURL): Removed use of m_restored, code to set
2864         m_bClearing.
2865         (WebCore::Frame::clear): Removed code to set m_bClearing and m_frameNameId.
2866         (WebCore::Frame::khtmlMousePressEvent): Removed code to set m_strSelectedURL
2867         and m_strSelectedURLTarget.
2868
2869         * bridge/mac/MacFrame.h: Removed scheduleHistoryNavigation and
2870         requestedURLString.
2871         * bridge/mac/MacFrame.mm:
2872         (WebCore::MacFrame::openURLFromPageCache): Removed use of m_restored.
2873         Removed unused requestedURLString.
2874
2875         * bridge/mac/WebCoreFrameBridge.h: Removed requestedURLString.
2876
2877 2006-03-10  Darin Adler  <darin@apple.com>
2878
2879         - fix Windows build
2880
2881         * page/FrameTree.cpp: Add include of <stdarg.h>.
2882
2883 2006-03-10  Darin Adler  <darin@apple.com>
2884
2885         Reviewed by Geoff.
2886
2887         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=3308
2888           Pop-up blocking blocks window.open for already open windows
2889
2890         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=7422
2891           Setting a frame name to the same value resets it to a generated one
2892
2893         - refactor frame-name-related functions into the FrameTree object
2894
2895         * WebCore.xcodeproj/project.pbxproj: Update for rename.
2896         * bridge/mac/MacFrame.h: Remove generateFrameName.
2897         * bridge/mac/MacFrame.mm: Ditto.
2898         * bridge/mac/PageMac.h: Added a declaration for WebCorePageBridge.
2899
2900         * bridge/mac/WebCoreFrameBridge.h: Remove _frameNamespace, generateFrameName,
2901         setFrameNamespace, frameNamespace.
2902         * bridge/mac/WebCoreFrameBridge.mm:
2903         (-[WebCoreFrameBridge childFrameNamed:]): Change to call the new child
2904         function on the FrameTree.
2905         (-[WebCoreFrameBridge findFrameNamed:]): Change to call the new find
2906         function on the FrameTree.
2907         (-[WebCoreFrameBridge RenderObject::nodeInfoAtPoint:]): Change since the
2908         contentPart function has been renamed to contentFrame.
2909
2910         * bridge/mac/WebCoreFrameNamespaces.h: Removed everything except for the
2911         one method still used on the WebKit side, framesInNamespace:.
2912         * bridge/mac/WebCoreFrameNamespaces.m: Renamed.
2913         * bridge/mac/WebCoreFrameNamespaces.mm: Added. Reimplemented the
2914         framesInNamespace method to use the namespace in WebCore::Page.
2915
2916         * bridge/mac/WebCorePageBridge.h: Added setGroupName and groupName.
2917         * bridge/mac/WebCorePageBridge.mm:
2918         (-[WebCorePageBridge setGroupName:]): Added. Calls through to Page.
2919         (-[WebCorePageBridge groupName]): Ditto.
2920
2921         * khtml/ecma/kjs_html.cpp:
2922         (KJS::HTMLDocument::namedItemGetter): Changed to call contentFrame by its new name.
2923         (KJS::HTMLElement::frameGetter): Ditto.
2924         (KJS::HTMLElement::iFrameGetter): Ditto.
2925
2926         * khtml/ecma/kjs_window.cpp:
2927         (KJS::Window::getValueProperty): Changed to call FrameTree::childCount
2928         instead of Frame::frames.
2929         (KJS::Window::childFrameGetter): Changed to call FrameTree::child
2930         instead of Frame::childFrameNamed.
2931         (KJS::Window::namedFrameGetter): Changed to call FrameTree::find
2932         instead of Frame::findFrame.
2933         (KJS::Window::indexGetter): Changed to call FrameTree::child
2934         instead of Frame::frames.
2935         (KJS::Window::getOwnPropertySlot): Changed to call FrameTree::child,
2936         FrameTree::find, and FrameTree::childCount instead of Frame::childFrameNamed,
2937         and Frame::findFrame, and Frame::frames.
2938         (KJS::WindowFunc::callAsFunction): Call FrameTree::find to check if the window
2939         is already open when considering whether to block a pop-up.
2940         (KJS::FrameArray::getValueProperty): Changed to call FrameTree::childCount
2941         instead of Frame::frames.
2942         (KJS::FrameArray::indexGetter): Changed to call FrameTree::child
2943         instead of Frame::frames.
2944         (KJS::FrameArray::nameGetter): Changed to call FrameTree::child
2945         instead of Frame::findFrame.
2946         (KJS::FrameArray::getOwnPropertySlot): Changed to call FrameTree::child,
2947         and FrameTree::childCount instead of Frame::findFrame and Frame::frames.
2948
2949         * khtml/html/html_baseimpl.h:
2950         * khtml/html/html_baseimpl.cpp:
2951         (WebCore::HTMLFrameElementImpl::isURLAllowed): Changed to call Page::frameCount
2952         instead of Frame::topLevelFrameCount.
2953         (WebCore::HTMLFrameElementImpl::openURL): Changed to call FrameTree::child
2954         instead of Frame::findFrame.
2955         (WebCore::HTMLFrameElementImpl::attach): Changed to call Page::incrementFrameCount
2956         instead of Frame::incrementFrameCount. Changed to call FrameTree::uniqueChildName
2957         instead of Frame::requestFrameName.
2958         (WebCore::HTMLFrameElementImpl::close): Changed to call Page::decrementFrameCount
2959         instead of Frame::decrementFrameCount. Changed to call FrameTree::child
2960         instead of Frame::findFrame.
2961         (WebCore::HTMLFrameElementImpl::contentFrame): Renamed from contentPart. Also
2962         changed to call FrameTree::child instead of Frame::findFrame.
2963         (WebCore::HTMLFrameElementImpl::contentDocument): Updated for name change of
2964         contentFrame from contentPart.
2965         (WebCore::HTMLIFrameElementImpl::attach): Changed to call Page::incrementFrameCount
2966         instead of Frame::incrementFrameCount. Changed to call FrameTree::uniqueChildName
2967         instead of Frame::requestFrameName.
2968
2969         * rendering/render_frames.cpp: (WebCore::isURLAllowed): Changed to call Page::frameCount
2970         instead of Frame::topLevelFrameCount.
2971
2972         * page/Frame.h: Removed frameNames, frames, childFrameNamed, findFrame, currentFrame,
2973         frameExists, incrementFrameCount, decrementFrameCount, topLevelFrameCount,
2974         generateFrameName, and requestFrameName functions.
2975         * page/Frame.cpp: (WebCore::Frame::requestFrame): Changed to use FrameTree::child
2976         instead of Frame::childFrameNamed.
2977
2978         * page/FrameTree.h: Changed name to an atomic string. Changed childCount to unsigned.
2979         Added isDescendantOf, traverseNext, child, find, uniqueChildName.
2980         * page/FrameTree.cpp:
2981         (WebCore::FrameTree::setName): Changed to call uniqueChildName to handle name
2982         duplication logic.
2983         (WebCore::FrameTree::uniqueChildName): Added. Checks for duplication and generates
2984         an appropriate frame name if there is a duplicate.
2985         (WebCore::FrameTree::child): Added.
2986         (WebCore::FrameTree::find): Added.
2987         (WebCore::FrameTree::isDescendantOf): Added.
2988         (WebCore::FrameTree::traverseNext): Added.
2989
2990         * page/Page.h: Added setGroupName, groupName, frameNamespace, incrementFrameCount,
2991         decrementFrameCount, and frameCount.
2992         * page/Page.cpp:
2993         (WebCore::Page::Page): Initialize m_frameCount to 0.
2994         (WebCore::Page::~Page): Call setGroupName to remove the page from any group it's in.
2995         (WebCore::Page::setGroupName): Added.
2996         (WebCore::Page::frameNamespace): Added.
2997
2998         * platform/win/TemporaryLinkStubs.cpp: Removed FrameWin::generateFrameName.
2999
3000 2006-03-10  Justin Garcia  <justin.garcia@apple.com>
3001         
3002         Reviewed by darin, harrison
3003         
3004         ~3x speedup pasting plain text from the console
3005
3006         * dom/dom_position.cpp:
3007         (WebCore::Position::next): 
3008         (WebCore::Position::atEnd): 
3009
3010 2006-03-10  David Hyatt <hyatt@apple.com>
3011
3012         More refactoring.  Split the FontData into cross-platform and
3013         platform-specific components.
3014
3015         Reviewed by eric
3016
3017         * WebCore.vcproj/WebCore/WebCore.vcproj:
3018         * platform/FontData.h: Added.
3019         (WebCore::FontData:::m_platformData):
3020         (WebCore::FontData::platformData):
3021         (WebCore::FontData::setMetrics):
3022         (WebCore::FontData::ascent):
3023         (WebCore::FontData::descent):
3024         (WebCore::FontData::xHeight):
3025         (WebCore::FontData::lineSpacing):
3026         * platform/FontPlatformData.h: Added.
3027         (WebCore::FontPlatformData::hfont):
3028         (WebCore::FontPlatformData::scaledFont):
3029         * platform/win/FontPlatformDataWin.cpp: Added.
3030         (WebCore::FontPlatformData::FontPlatformData):
3031         (WebCore::FontPlatformData::~FontPlatformData):
3032         * platform/win/FontWin.cpp:
3033         (WebCore::Font::floatWidth):
3034         (WebCore::Font::drawText):
3035
3036 2006-03-10  Maciej Stachowiak  <mjs@apple.com>
3037
3038         Reviewed by Eric.
3039
3040         - fix win32 networking to properly use async load API
3041
3042         * platform/win/TransferJobWin.cpp:
3043         (WebCore::TransferJobWndProc):
3044         (WebCore::TransferJob::start):
3045
3046 2006-03-10  Eric Seidel  <eseidel@apple.com>
3047
3048         Fix build.
3049
3050         * platform/win/FontWin.cpp:
3051         (WebCore::getFontData):
3052         * platform/win/TemporaryLinkStubs.cpp:
3053
3054 2006-03-10  Adele Peterson  <adele@apple.com>
3055
3056         Reviewed by Tim Hatcher.
3057
3058         - fix for <rdar://problem/4469419> 
3059         REGRESSION: RadioButtons are not checked in Safari when name attribute comes after checked attribute
3060
3061         Test: fast/forms/radio-attr-order.html
3062
3063         * khtml/html/HTMLInputElementImpl.cpp: (WebCore::HTMLInputElementImpl::parseMappedAttribute):
3064         When the name attribute gets parsed for radio buttons, if its supposed to be checked by default, call setChecked.
3065         Also, when the name changes on a checked button, we don't need to check that 
3066         there's a form before removing it as the checked button for that group.  
3067         That was an old check from when we required a form to keep track of checked buttons.
3068
3069 2006-03-10  Eric Seidel  <eseidel@apple.com>
3070
3071         Reviewed by darin.
3072
3073         Add real ScrollViewWin implementation (fixes redraw bugs, adds ScrollBar support.)
3074
3075         * platform/ScrollView.h:
3076         * platform/Widget.h:
3077         * platform/win/FontWin.cpp:
3078         (WebCore::getCairoFont): Fix crasher.
3079         * platform/win/ScrollViewWin.cpp:
3080         (WebCore::ScrollView::ScrollViewPrivate::ScrollViewPrivate):
3081         (WebCore::ScrollView::ScrollView):
3082         (WebCore::ScrollView::~ScrollView):
3083         (WebCore::ScrollView::updateContents):
3084         (WebCore::ScrollView::visibleWidth):
3085         (WebCore::ScrollView::visibleHeight):
3086         (WebCore::ScrollView::setContentsPos):
3087         (WebCore::ScrollView::resizeContents):
3088         (WebCore::ScrollView::contentsX):
3089         (WebCore::ScrollView::contentsY):
3090         (WebCore::ScrollView::contentsWidth):
3091         (WebCore::ScrollView::contentsHeight):
3092         (WebCore::ScrollView::viewportToContents):
3093         (WebCore::ScrollView::contentsToViewport):
3094         (WebCore::ScrollView::scrollXOffset):
3095         (WebCore::ScrollView::scrollYOffset):
3096         (WebCore::ScrollView::scrollBy):
3097         (WebCore::ScrollView::hScrollBarMode):
3098         (WebCore::ScrollView::vScrollBarMode):
3099         (WebCore::ScrollView::suppressScrollBars):
3100         (WebCore::ScrollView::setHScrollBarMode):
3101         (WebCore::ScrollView::setVScrollBarMode):
3102         (WebCore::ScrollView::setScrollBarsMode):
3103         (WebCore::ScrollView::setStaticBackground):
3104         (WebCore::ScrollView::updateScrollInfo):
3105         (WebCore::ScrollView::updateScrollBars):
3106         * platform/win/TemporaryLinkStubs.cpp:
3107         (BrowserExtensionWin::goBackOrForward):
3108         (BrowserExtensionWin::setIconURL):
3109         (ScrollView::scrollPointRecursively):
3110         * platform/win/WidgetWin.cpp:
3111         (WebCore::Widget::windowHandle): mark as const
3112
3113 2006-03-10  David Hyatt  <hyatt@apple.com>
3114
3115         Rename the m_renderer variable to m_dataSet now that the class name
3116         has changed.
3117
3118         Reviewed by adele
3119
3120         * platform/Font.cpp:
3121         (WebCore::m_wordSpacing):
3122         (WebCore::Font::Font):
3123         (WebCore::Font::operator=):
3124         (WebCore::Font::update):
3125         * platform/Font.h:
3126         * platform/FontDataSet.h:
3127         * platform/mac/FontMac.mm:
3128         (WebCore::Font::getWebCoreFont):
3129         (WebCore::Font::ascent):
3130         (WebCore::Font::descent):
3131         (WebCore::Font::lineSpacing):
3132         (WebCore::Font::xHeight):
3133         (WebCore::Font::isFixedPitch):
3134         (WebCore::Font::selectionRectForText):
3135         (WebCore::Font::drawText):
3136         (WebCore::Font::drawHighlightForText):
3137         (WebCore::Font::drawLineForText):
3138         (WebCore::Font::drawLineForMisspelling):
3139         (WebCore::Font::misspellingLineThickness):
3140         (WebCore::Font::floatWidth):
3141         (WebCore::Font::checkSelectionPoint):
3142         * platform/win/FontWin.cpp:
3143         (WebCore::FontData::FontData):
3144         (WebCore::FontData::~FontData):
3145         (WebCore::getFontData):
3146         (WebCore::FontDataSet::primaryFont):
3147         (WebCore::Font::floatWidth):
3148         (WebCore::Font::ascent):
3149         (WebCore::Font::descent):
3150         (WebCore::Font::xHeight):
3151         (WebCore::Font::lineSpacing):
3152         (WebCore::Font::isFixedPitch):
3153         (WebCore::Font::drawText):
3154
3155 2006-03-10  David Hyatt  <hyatt@apple.com>
3156
3157         Rename FontRenderer to FontDataSet.
3158
3159         Reviewed by adele
3160
3161         * WebCore.xcodeproj/project.pbxproj:
3162         * platform/Font.cpp:
3163         (WebCore::Font::update):
3164         * platform/Font.h:
3165         * platform/FontDataSet.h: Added.
3166         * platform/FontRenderer.h: Removed.
3167         * platform/mac/FontMac.mm:
3168         (WebCore::FontDataSet::~FontDataSet):
3169         (WebCore::FontDataSet::getWebCoreFont):
3170         (WebCore::FontDataSet::getRenderer):
3171         (WebCore::FontDataSet::determinePitch):
3172         (WebCore::FontDataSet::invalidate):
3173         * platform/win/FontWin.cpp:
3174         (WebCore::getCairoFont):
3175         (WebCore::FontDataSet::~FontDataSet):
3176         (WebCore::FontDataSet::determinePitch):
3177         (WebCore::FontDataSet::invalidate):
3178         (WebCore::FontDataSet::primaryCairoFont):
3179
3180 2006-03-09  Justin Garcia  <justin.garcia@apple.com>
3181
3182         Reviewed by adele
3183         
3184         <http://bugzilla.opendarwin.org/show_bug.cgi?id=7692>
3185         Should use an iterator in CompositeEditCommand::doUnapply()
3186         
3187         ~30% speedup of a big undo
3188
3189         * editing/CompositeEditCommand.cpp:
3190         (WebCore::CompositeEditCommand::doUnapply):
3191         (WebCore::CompositeEditCommand::doReapply):
3192
3193 2006-03-09  Adele Peterson  <adele@apple.com>
3194
3195         Reviewed by Tim O.
3196
3197         Removed unnecessary alerts in TextIterator advance methods.  
3198         We want to be able to use advance() even if the iterator is already at the end.
3199
3200         * editing/visible_text.cpp:
3201         (khtml::TextIterator::advance): remove assert since TextIterator will just do nothing if its already at the end.
3202         (khtml::CharacterIterator::advance): ditto.
3203         * rendering/RenderTextField.cpp: (WebCore::RenderTextField::visiblePositionForIndex):
3204         Since the asserts in the iterator are removed, we don't have to check for it.atEnd() before calling advance.
3205
3206 2006-03-09  David Hyatt <hyatt@apple.com>
3207
3208         Make text paint with the correct foreground color on Windows.
3209         Make the face validation check case insensitive.
3210         Force ClearType to be on for font rendering.
3211
3212         Reviewed by Tim Hatcher
3213
3214         * platform/win/FontWin.cpp:
3215         (WebCore::getCairoFont):
3216         (WebCore::Font::drawText):
3217
3218 2006-03-09  Adele Peterson  <adele@apple.com>
3219
3220         Reviewed by Hyatt.
3221
3222         - Fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=7675
3223         When new text fields change from visibility:hidden to visibility:visible, value doesn't display
3224
3225         Test: fast/forms/input-appearance-visibility.html
3226
3227         * rendering/RenderTextField.cpp: (WebCore::RenderTextField::setStyle):
3228         Sets the style directly on the children of the inner div.
3229
3230 2006-03-09  David Hyatt <hyatt@apple.com>
3231
3232         Make basic text rendering work on Win32.
3233
3234         Reviewed by eric
3235
3236         * WebCore.vcproj/WebCore/WebCore.vcproj:
3237         Add FontDescription.h to the Visual Studio project.
3238
3239         * bridge/win/FrameWin.cpp:
3240         (WebCore::FrameWin::FrameWin):
3241         Add some good default font settings to KHTMLSettings.
3242
3243         * platform/Font.cpp:
3244         (WebCore::Font::update):
3245         Renamed the FontRenderer method to invalidate, so that's what
3246         update calls now.
3247
3248         * platform/FontRenderer.h:
3249         * platform/mac/FontMac.mm:
3250         (WebCore::FontRenderer::~FontRenderer):
3251         (WebCore::FontRenderer::invalidate):
3252         Rename the update method to invalidate.  Make sure the Mac
3253         font renderer releases its resources when it gets destroyed.
3254
3255         * platform/win/FontWin.cpp:
3256         (WebCore::CairoFont::CairoFont):
3257         (WebCore::CairoFont::~CairoFont):
3258         (WebCore::CairoFont::hfont):
3259         (WebCore::CairoFont::scaledFont):
3260         (WebCore::CairoFont::setMetrics):
3261         (WebCore::CairoFont::ascent):
3262         (WebCore::CairoFont::descent):
3263         (WebCore::CairoFont::xHeight):
3264         (WebCore::CairoFont::lineSpacing):
3265         Implement a new class called CairoFont that encapsulates
3266         the windows HFONT, the cairo font face, and the cairo scaled
3267         font.
3268
3269         (WebCore::getCairoFont):
3270         The method to look up a Cairo font.  This will eventually use
3271         a hash, but for now it just always makes the fonts over and
3272         over again.
3273
3274         (WebCore:::m_pitch):
3275         (WebCore::FontRenderer::~FontRenderer):
3276         (WebCore::FontRenderer::determinePitch):
3277         (WebCore::FontRenderer::invalidate):
3278         More of the FontRenderer plumbing.
3279
3280         (WebCore::FontRenderer::primaryCairoFont):
3281         Returns the primary Cairo font for a family list.  This is basically
3282         the first family that is present on the system.
3283
3284         (WebCore::Font::floatWidth):
3285         The width method uses GetTextExtentPoint32W for now.  This
3286         is totally wrong and will eventually be replaced by Cairo
3287         code.
3288
3289         (WebCore::Font::ascent):
3290         (WebCore::Font::descent):
3291         (WebCore::Font::xHeight):
3292         (WebCore::Font::lineSpacing):
3293         (WebCore::Font::isFixedPitch):
3294         Accessors for the metrics and pitch info.
3295
3296         (WebCore::Font::drawText):
3297         Drawing of text.  Uses TextOut and is also basically throwaway
3298         code.
3299
3300         * platform/win/TemporaryLinkStubs.cpp:
3301         (Font::checkSelectionPoint):
3302         Move the checkSelectionPoint method back to the link stubs.
3303
3304 2006-03-09  Justin Garcia  <justin.garcia@apple.com>
3305
3306         Reviewed by harrison
3307     
3308         Fixed formatting and changed functions to take in 
3309         a const Selection& instead of a Selection.
3310
3311         * editing/ModifySelectionListLevelCommand.cpp:
3312         (WebCore::ModifySelectionListLevelCommand::canIncreaseSelectionListLevel):
3313         (WebCore::ModifySelectionListLevelCommand::canDecreaseSelectionListLevel):
3314         (WebCore::ModifySelectionListLevelCommand::increaseSelectionListLevel):
3315         (WebCore::ModifySelectionListLevelCommand::decreaseSelectionListLevel):
3316         (WebCore::modifySelectionListLevel):
3317         (WebCore::getStartEndListChildren):
3318         (WebCore::canIncreaseListLevel):
3319         (WebCore::canDecreaseListLevel):
3320         (WebCore::ModifySelectionListLevelCommand::increaseListLevel):
3321         (WebCore::ModifySelectionListLevelCommand::decreaseListLevel):
3322         * editing/ModifySelectionListLevelCommand.h:
3323
3324 2006-03-09  Adele Peterson  <adele@apple.com>
3325
3326         Reviewed by Darin.
3327
3328         - Fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=6814
3329         Implement selection methods for RenderTextField
3330
3331         Test: fast/forms/input-appearance-selection.html
3332
3333         * rendering/RenderTextField.cpp:
3334         (WebCore::RenderTextField::createDivStyle): removed extra space.
3335         (WebCore::RenderTextField::select): Removed checks for document and m_div since there should always be a document and 
3336          m_div will be initialized as the renderer gets attached.
3337         (WebCore::RenderTextField::selectionStart): Calls indexForVisiblePosition.
3338         (WebCore::RenderTextField::selectionEnd): ditto.
3339         (WebCore::RenderTextField::setSelectionStart): calls setSelectionRange.
3340         (WebCore::RenderTextField::setSelectionEnd): ditto.
3341         (WebCore::RenderTextField::setSelectionRange): gets VisiblePositions for both indices, and sets the selection.
3342         (WebCore::RenderTextField::visiblePositionForIndex): Added helper method.
3343         (WebCore::RenderTextField::indexForVisiblePosition): Added helper method.
3344         * rendering/RenderTextField.h: Added new helper methods for selection.
3345
3346 2006-03-09  David Carson  <dacarson@gmail.com>
3347
3348         Test: fast/canvas/fillrect_gradient.html
3349
3350         Reviewed by Darin.
3351
3352         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6103
3353           Rectangles are not filled according to the Web Applications Working Draft
3354
3355         * khtml/ecma/kjs_html.cpp: (KJS::Context2DFunction::callAsFunction):
3356         Modified fillrect function to check and use a gradient if set.
3357         Builds a path to fill rects with a gradient.
3358
3359 2006-03-09  Mitz Pettel  <opendarwin.org@mitzpettel.com>
3360
3361         No test because this fixes an existing pixel test (and does not affect
3362         the render tree).
3363
3364         Reviewed by Maciej.
3365
3366         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=7664
3367           REGRESSION: tests that include numeric list markers fail in pixel mode
3368
3369         * platform/GraphicsContext.cpp:
3370         (WebCore::GraphicsContext::drawText): Restored AlignRight behavior.
3371
3372 2006-03-09  Mitz Pettel  <opendarwin.org@mitzpettel.com>
3373
3374         No test because we couldn't figure out how to write one.
3375
3376         Reviewed by Darin.
3377
3378         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=7680
3379           REGRESSION: Ellipsis painted over the chrome and in invalid contexts
3380
3381         * rendering/render_line.cpp:
3382         (WebCore::EllipsisBox::paint): Replaced call to Font::drawText with
3383         GraphicsContext::drawText, which checks the paintingDisabled flag.
3384
3385 2006-03-09  Maciej Stachowiak  <mjs@apple.com>
3386
3387         Reviewed by Eric.
3388
3389         - make link clicks work by propagating them up to a client
3390
3391         * Viewer/ImageView.cpp:
3392         * bridge/win/FrameWin.cpp:
3393         * bridge/win/FrameWin.h:
3394         * platform/win/TemporaryLinkStubs.cpp:
3395         (FrameWin::incomingReferrer):
3396
3397 2006-03-09  Eric Seidel  <eseidel@apple.com>
3398
3399         Reviewed by mjs.
3400
3401         Add support for Timers under 10ms.
3402         Fix random crashers due to multi-threaded loading.
3403
3404         * platform/TransferJob.h:
3405         * platform/TransferJobInternal.h:
3406         (WebCore::TransferJobInternal::TransferJobInternal):
3407         * platform/Widget.h:
3408         * platform/win/SharedTimerWin.cpp:
3409         (WebCore::TimerWindowWndProc):
3410         (WebCore::initializeOffScreenTimerWindow):
3411         (WebCore::setSharedTimerFireTime):
3412         * platform/win/TemporaryLinkStubs.cpp:
3413         (WebCore::TransferJob::assembleResponseHeaders):
3414         (WebCore::TransferJob::retrieveCharset):
3415         * platform/win/TransferJobWin.cpp:
3416         (WebCore::addToOutstandingJobs):
3417         (WebCore::removeFromOutstandingJobs):
3418         (WebCore::lookupTransferJob):
3419         (WebCore::TransferJobWndProc):
3420         (WebCore::initializeOffScreenTransferJobWindow):
3421         (WebCore::TransferJob::~TransferJob):
3422         (WebCore::transferJobStatusCallback):
3423         (WebCore::TransferJob::start):
3424         (WebCore::TransferJob::cancel):
3425         * platform/win/WidgetWin.cpp:
3426
3427 2006-03-08  Justin Garcia  <justin.garcia@apple.com>
3428
3429         Reviewed by darin
3430         
3431         <http://bugzilla.opendarwin.org/show_bug.cgi?id=7579>
3432         TinyMCE: Implement execCommand(insertImage, ...)
3433         
3434         Implemented InsertImage and also changed paste to use a single 
3435         rule for when to remove junk that remains after node removal. 
3436
3437         * editing/ReplaceSelectionCommand.cpp:
3438         (WebCore::ReplaceSelectionCommand::removeNodeAndPruneAncestors):
3439         (WebCore::ReplaceSelectionCommand::doApply):
3440         (WebCore::ReplaceSelectionCommand::removeLinePlaceholderIfNeeded):
3441         * editing/ReplaceSelectionCommand.h:
3442         * editing/htmlediting.cpp:
3443         * editing/jsediting.cpp:
3444
3445 2006-03-08  Eric Seidel  <eseidel@apple.com>
3446
3447         Reviewed by hyatt.
3448
3449         Fix build script to properly copy dll files.
3450
3451         * WebCore.vcproj/WebCore/build-generated-files.sh:
3452
3453 2006-03-08  Rob Buis  <buis@kde.org>
3454
3455         Reviewed by eseidel.
3456
3457         Fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=6899 SVG <rect> does not respect display: none
3458
3459         For svg elements that can render, call StyledElementImpl::rendererIsNeeded
3460         to decide whether the element should render. In particular this way
3461         any setting of display="none" is handled.
3462
3463         * ksvg2/svg/SVGAElementImpl.h:
3464         (WebCore::SVGAElementImpl::rendererIsNeeded):
3465         * ksvg2/svg/SVGCircleElementImpl.h:
3466         (WebCore::SVGCircleElementImpl::rendererIsNeeded):
3467         * ksvg2/svg/SVGEllipseElementImpl.h:
3468         (WebCore::SVGEllipseElementImpl::rendererIsNeeded):
3469         * ksvg2/svg/SVGForeignObjectElementImpl.h:
3470         (WebCore::SVGForeignObjectElementImpl::rendererIsNeeded):
3471         * ksvg2/svg/SVGGElementImpl.h:
3472         (WebCore::SVGGElementImpl::rendererIsNeeded):
3473         * ksvg2/svg/SVGImageElementImpl.h:
3474         (WebCore::SVGImageElementImpl::rendererIsNeeded):
3475         * ksvg2/svg/SVGLineElementImpl.h:
3476         (WebCore::SVGLineElementImpl::rendererIsNeeded):
3477         * ksvg2/svg/SVGMarkerElementImpl.h:
3478         (WebCore::SVGMarkerElementImpl::rendererIsNeeded):
3479         * ksvg2/svg/SVGMaskElementImpl.h:
3480         (WebCore::SVGMaskElementImpl::rendererIsNeeded):
3481         * ksvg2/svg/SVGPathElementImpl.h:
3482         (WebCore::SVGPathElementImpl::rendererIsNeeded):
3483         * ksvg2/svg/SVGPatternElementImpl.h:
3484         (WebCore::SVGPatternElementImpl::rendererIsNeeded):
3485         * ksvg2/svg/SVGPolyElementImpl.h:
3486         (WebCore::SVGPolyElementImpl::rendererIsNeeded):
3487         * ksvg2/svg/SVGRectElementImpl.h:
3488         (WebCore::SVGRectElementImpl::rendererIsNeeded):
3489         * ksvg2/svg/SVGSVGElementImpl.h:
3490         (WebCore::SVGSVGElementImpl::rendererIsNeeded):
3491         * ksvg2/svg/SVGSwitchElementImpl.h:
3492         (WebCore::SVGSwitchElementImpl::rendererIsNeeded):
3493         * ksvg2/svg/SVGTSpanElementImpl.h:
3494         (WebCore::SVGTSpanElementImpl::rendererIsNeeded):
3495         * ksvg2/svg/SVGTextElementImpl.h:
3496         (WebCore::SVGTextElementImpl::rendererIsNeeded):
3497         * ksvg2/svg/SVGUseElementImpl.h:
3498         (WebCore::SVGUseElementImpl::rendererIsNeeded):
3499
3500 2006-03-08  Eric Seidel  <eseidel@apple.com>
3501
3502         Reviewed by mjs.
3503
3504         Add stubs to allow JavaScript-enabled WebCore to not crash.
3505         Add ScreenWin implementation.
3506         Add alert() support.
3507
3508         * WebCore.vcproj/WebCore/WebCore.vcproj:
3509         * bridge/win/FrameWin.cpp:
3510         (WebCore::FrameWin::runJavaScriptAlert):
3511         (WebCore::FrameWin::runJavaScriptConfirm):
3512         * platform/win/ScreenWin.cpp: Added.
3513         (WebCore::monitorInfoForWidget):
3514         (WebCore::WebCore::screenRect):
3515         (WebCore::WebCore::screenDepth):
3516         (WebCore::WebCore::usableScreenRect):
3517         * platform/win/TemporaryLinkStubs.cpp:
3518         (FrameWin::canUndo):
3519         (FrameWin::runJavaScriptPrompt):
3520         (FrameWin::canPaste):
3521         (WebCore::setCookies):
3522         (WebCore::cookies):
3523         (WebCore::cookiesEnabled):
3524         (PlugInInfoStore::createPluginInfoForPluginAtIndex):
3525         (PlugInInfoStore::pluginCount):
3526         (WebCore::refreshPlugins):
3527         (FrameWin::clearUndoRedoOperations):
3528         (FrameWin::incomingReferrer):
3529
3530 2006-03-08  Darin Adler  <darin@apple.com>
3531
3532         Reviewed by Maciej.
3533
3534         - fix another instance of the bug I just fixed in the Macintosh-specific code path
3535
3536         * platform/image-decoders/gif/GIFImageReader.h: Remove not-so-useful 100ms constant.
3537         * platform/image-decoders/gif/GIFImageReader.cpp: (GIFImageReader::read):
3538         Use the correct rule for minimum frame durations.
3539
3540 2006-03-08  Maciej Stachowiak  <mjs@apple.com>
3541
3542         Reviewed by Eric.
3543
3544         - very rough implementation of networking in TransferJob for windows
3545
3546         * platform/TransferJob.h:
3547         * platform/TransferJobInternal.h:
3548         (WebCore::TransferJobInternal::TransferJobInternal):
3549         * platform/win/TransferJobWin.cpp:
3550         (WebCore::transferJobStatusCallback):
3551         (WebCore::TransferJob::start):
3552
3553 2006-03-08  Maciej Stachowiak  <mjs@apple.com>
3554
3555         Reviewed by Darin.
3556
3557         - fix win32 build
3558
3559         * platform/win/FontWin.cpp: