d840e5d94cfb893886d0e46c35011b7e2f6a0d6e
[WebKit-https.git] / WebCore / ChangeLog
1 2006-01-09  Eric Seidel  <eseidel@apple.com>
2
3         Reviewed by mjs.
4
5         Remove more unused code from kwq.
6
7         * ForwardingHeaders/dcopclient.h: Removed.
8         * ForwardingHeaders/kaction.h: Removed.
9         * ForwardingHeaders/kcharsets.h: Removed.
10         * ForwardingHeaders/kcombobox.h: Removed.
11         * ForwardingHeaders/klineedit.h: Removed.
12         * ForwardingHeaders/klistbox.h: Removed.
13         * ForwardingHeaders/kwin.h: Removed.
14         * ForwardingHeaders/qcombobox.h: Added.
15         * ForwardingHeaders/qlineedit.h: Added.
16         * WebCore.xcodeproj/project.pbxproj: remove files.
17         * khtml/css/csshelper.cpp:
18         * khtml/css/cssstyleselector.cpp:
19         * khtml/ecma/kjs_window.cpp:
20         (KJS::Window::getValueProperty):
21         * khtml/html/html_documentimpl.cpp:
22         * khtml/html/html_formimpl.cpp:
23         (DOM::HTMLOptionElementImpl::index):
24         (DOM::HTMLOptionElementImpl::setIndex):
25         * khtml/html/htmltokenizer.cpp:
26         * khtml/html/htmltokenizer.h:
27         * khtml/khtml_part.cpp:
28         * khtml/khtmlpart_p.h:
29         * khtml/rendering/render_form.cpp:
30         (RenderLineEdit::RenderLineEdit):
31         (RenderLineEdit::setStyle):
32         (RenderLineEdit::updateFromElement):
33         (RenderLineEdit::selectionStart):
34         (RenderLineEdit::selectionEnd):
35         (RenderLineEdit::setSelectionStart):
36         (RenderLineEdit::setSelectionEnd):
37         (RenderLineEdit::select):
38         (RenderLineEdit::setSelectionRange):
39         (ComboBoxWidget::ComboBoxWidget):
40         (ComboBoxWidget::event):
41         (ComboBoxWidget::eventFilter):
42         (RenderSelect::setWidgetWritingDirection):
43         (RenderSelect::updateFromElement):
44         (RenderSelect::layout):
45         (RenderSelect::slotSelectionChanged):
46         (RenderSelect::createListBox):
47         (RenderSelect::updateSelection):
48         (RenderTextArea::RenderTextArea):
49         * khtml/rendering/render_form.h:
50         (khtml::RenderLineEdit::widget):
51         * kwq/KWQDCOPClient.h: Removed.
52         * kwq/KWQKCharsets.cpp: Removed.
53         * kwq/KWQKCharsets.h: Removed.
54         * kwq/KWQKComboBox.h: Removed.
55         * kwq/KWQKKAction.h: Removed.
56         * kwq/KWQKLineEdit.h: Removed.
57         * kwq/KWQKListBox.h: Removed.
58         * kwq/KWQKWin.cpp: Removed.
59         * kwq/KWQKWin.h: Removed.
60         * kwq/KWQWidget.h:
61         * kwq/KWQWidget.mm:
62
63 2006-01-09  Eric Seidel  <eseidel@apple.com>
64
65         Reviewed by mjs.
66
67         Removing more unused parts of KWQ.
68
69         * ForwardingHeaders/java/kjavaappletcontext.h: Removed.
70         * ForwardingHeaders/khtml_find.h: Removed.
71         * ForwardingHeaders/qimage.h: Removed.
72         * ForwardingHeaders/rendering/break_lines.h: Removed.
73         * ForwardingHeaders/rendering/render_text.h: Removed.
74         * ForwardingHeaders/xbl/xbl_docimpl.h: Removed.
75         * WebCore.xcodeproj/project.pbxproj:
76         * khtml/html/html_canvasimpl.cpp:
77         * khtml/html/html_imageimpl.cpp:
78         * khtml/html/html_objectimpl.cpp:
79         * khtml/html/html_objectimpl.h:
80         * khtml/khtml_part.cpp:
81         (KHTMLPart::init):
82         (KHTMLPart::~KHTMLPart):
83         (KHTMLPart::clear):
84         * khtml/khtml_part.h:
85         * khtml/khtmlpart_p.h:
86         (KHTMLPartPrivate::KHTMLPartPrivate):
87         (KHTMLPartPrivate::~KHTMLPartPrivate):
88         * khtml/rendering/render_applet.cpp:
89         (RenderApplet::RenderApplet):
90         (RenderApplet::createWidgetIfNecessary):
91         * khtml/rendering/render_applet.h:
92         * ksvg2/svg/SVGFEImageElementImpl.cpp:
93         * ksvg2/svg/SVGImageElementImpl.cpp:
94         * kwq/DOMHTML.mm:
95         * kwq/KWQDummyView.h: Removed.
96         * kwq/KWQDummyView.m: Removed.
97         * kwq/KWQImage.h: Removed.
98         * kwq/KWQKHTMLFind.h: Removed.
99         * kwq/KWQKHTMLPart.mm:
100         * kwq/KWQKHTMLPartBrowserExtension.h:
101         * kwq/KWQKJavaAppletContext.h: Removed.
102         * kwq/KWQKJavaAppletWidget.h:
103         * kwq/KWQKJavaAppletWidget.mm:
104         (KJavaAppletWidget::KJavaAppletWidget):
105         * kwq/KWQKPartsBrowserExtension.h:
106         * kwq/KWQObject.h:
107         * kwq/KWQRegion.h:
108
109 2006-01-09  Eric Seidel  <eseidel@apple.com>
110
111         Rubber stamped by mjs.
112
113         Broke out loader.{h,cpp} into multiple files, one per class.
114         This patch also updates all files which previously included
115         loader.h to only include the necessary renamed headers.
116         http://bugzilla.opendarwin.org/show_bug.cgi?id=6444
117
118         * ForwardingHeaders/kdom/cache/KDOMCachedDocument.h: Removed.
119         * ForwardingHeaders/kdom/cache/KDOMCachedImage.h: updated include
120         * ForwardingHeaders/kdom/cache/KDOMCachedObject.h: updated include
121         * ForwardingHeaders/kdom/cache/KDOMCachedScript.h: updated include
122         * WebCore.xcodeproj/project.pbxproj: added files
123         * khtml/css/css_computedstyle.cpp: updated includes
124         * khtml/css/css_ruleimpl.cpp: updated includes
125         * khtml/css/css_stylesheetimpl.h: updated includes
126         * khtml/css/css_valueimpl.cpp: updated includes
127         * khtml/css/cssstyleselector.cpp: updated includes
128         * khtml/ecma/kjs_events.cpp: updated includes
129         * khtml/ecma/kjs_html.cpp: updated includes
130         * khtml/ecma/xmlhttprequest.cpp: updated includes
131         * khtml/html/html_headimpl.cpp: updated includes
132         * khtml/html/html_imageimpl.cpp: updated includes
133         * khtml/html/html_imageimpl.h: updated includes
134         * khtml/html/htmltokenizer.cpp: updated includes
135         * khtml/khtml_part.cpp: updated includes
136         * khtml/khtmlview.cpp: updated includes
137         * khtml/misc/Cache.cpp: Added.
138         * khtml/misc/Cache.h: Added.
139         * khtml/misc/CachedCSSStyleSheet.cpp: Added.
140         * khtml/misc/CachedCSSStyleSheet.h: Added.
141         * khtml/misc/CachedImage.cpp: Added.
142         * khtml/misc/CachedImage.h: Added.
143         * khtml/misc/CachedImageCallback.cpp: Added.
144         * khtml/misc/CachedImageCallback.h: Added.
145         * khtml/misc/CachedObject.cpp: Added.
146         * khtml/misc/CachedObject.h: Added, fixed tabs -> spaces.
147         * khtml/misc/CachedObjectClientWalker.cpp: Added.
148         * khtml/misc/CachedObjectClientWalker.h: Added.
149         * khtml/misc/CachedScript.cpp: Added.
150         * khtml/misc/CachedScript.h: Added.
151         * khtml/misc/CachedXBLDocument.cpp: Added.
152         * khtml/misc/CachedXBLDocument.h: Added.
153         * khtml/misc/CachedXSLStyleSheet.cpp: Added.
154         * khtml/misc/CachedXSLStyleSheet.h: Added.
155         * khtml/misc/DocLoader.cpp: Added.
156         * khtml/misc/DocLoader.h: Added.
157         * khtml/misc/Request.cpp: Added.
158         * khtml/misc/Request.h: Added.
159         * khtml/misc/loader.cpp: updated includes
160         * khtml/misc/loader.h: updated includes
161         * khtml/misc/loader_client.h: updated includes
162         * khtml/rendering/render_box.cpp: updated includes
163         * khtml/rendering/render_line.cpp: updated includes
164         * khtml/rendering/render_list.cpp: updated includes
165         * khtml/rendering/render_object.cpp: updated includes
166         * khtml/xml/dom_docimpl.cpp: updated includes
167         * khtml/xml/dom_xmlimpl.cpp: updated includes
168         * khtml/xml/xml_tokenizer.cpp: updated includes
169         * khtml/xsl/xsl_stylesheetimpl.cpp: updated includes
170         * khtml/xsl/xsl_stylesheetimpl.h: updated includes
171         * khtml/xsl/xslt_processorimpl.cpp: updated includes
172         * ksvg2/svg/SVGCursorElementImpl.cpp: updated includes
173         * ksvg2/svg/SVGDocumentImpl.cpp: updated includes
174         * ksvg2/svg/SVGFEImageElementImpl.cpp: updated includes
175         * ksvg2/svg/SVGImageElementImpl.cpp: updated includes
176         * ksvg2/svg/SVGImageElementImpl.h: updated includes
177         * kwq/KWQKHTMLPart.mm: updated includes
178         * kwq/KWQLoader.mm: updated includes
179         * kwq/KWQPixmap.mm: updated includes
180         * kwq/KWQTextArea.mm: updated includes
181         * kwq/WebCoreBridge.mm: updated includes
182         * kwq/WebCoreCache.mm: updated includes
183
184 2006-01-09  Alexey Proskuryakov  <ap@nypop.com>
185
186         Reviewed by Maciej.
187
188         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6402
189           Implement frameElement.width and frameElement.height
190
191         Test case: fast/frames/frameElement-widthheight.html
192
193         * khtml/ecma/kjs_html.cpp:
194         (KJS::HTMLElement::frameGetter):
195         * khtml/ecma/kjs_html.h:
196         Add FrameWidth, FrameHeight
197
198         * khtml/html/html_baseimpl.cpp:
199         (HTMLFrameElementImpl::frameWidth):
200         (HTMLFrameElementImpl::frameHeight):
201         * khtml/html/html_baseimpl.h:
202         Add frameWidth, frameHeight
203
204 2006-01-09  Mitz Pettel  <opendarwin.org@mitzpettel.com>
205
206         Reviewed by Maciej, landed by ap.
207         
208         Test: fast/replaced/inline-box-wrapper-handover.html
209         
210         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6276
211           Image thumbnails are misplaced on forum.2ostrov.ru
212           
213         * khtml/rendering/render_line.cpp:
214         (khtml::InlineBox::deleteLine): Don't reset the inline box wrapper when
215         deleting an extracted box.
216
217 2006-01-08  Eric Seidel  <eseidel@apple.com>
218
219         Reviewed by ggaren.
220
221         Remove all mention of NSView from khtml.
222
223         * khtml/html/html_objectimpl.cpp:
224         (DOM::HTMLAppletElementImpl::getAppletInstance): call w/ widget
225         (DOM::HTMLEmbedElementImpl::getEmbedInstance): call w/ widget
226         (DOM::HTMLObjectElementImpl::getObjectInstance): call w/ widget
227         * kwq/KWQKHTMLPart.h:
228         * kwq/KWQKHTMLPart.mm:
229         (KWQKHTMLPart::getAppletInstanceForWidget): renamed.
230         (KWQKHTMLPart::getEmbedInstanceForWidget): renamed.
231         (KWQKHTMLPart::getObjectInstanceForWidget): renamed.
232
233 2006-01-08  Eric Seidel  <eseidel@apple.com>
234
235         Rubber stamped by ggaren.
236
237         * ForwardingHeaders/qsortedlist.h: Added. (a khtml file was referencing KWQ directly.)
238         * WebCore.xcodeproj/project.pbxproj: added new files.
239         * khtml/editing/SelectionController.cpp: updated includes
240         * khtml/editing/composite_edit_command.cpp: updated includes
241         * khtml/editing/htmlediting.cpp: updated includes
242         * khtml/editing/markup.cpp: updated includes
243         * khtml/editing/visible_position.cpp: updated includes
244         * khtml/editing/visible_text.cpp: updated includes
245         * khtml/editing/visible_text.h: updated includes
246         * khtml/editing/visible_units.cpp: updated includes
247         * khtml/khtml_part.cpp: updated includes
248         * khtml/khtmlview.cpp: updated includes
249         * khtml/rendering/InlineTextBox.cpp: Split out from render_text
250         * khtml/rendering/InlineTextBox.h: Split out from render_text
251         * khtml/rendering/RenderText.cpp: Split out from render_text
252         (khtml::RenderText::position): removed DEBUG_LAYOUT
253         * khtml/rendering/RenderText.h: Split out from render_text
254         * khtml/rendering/RenderTextFragment.cpp: Split out from render_text
255         * khtml/rendering/RenderTextFragment.h: Split out from render_text
256         * khtml/rendering/bidi.cpp: updated includes
257         * khtml/rendering/render_block.cpp: updated includes
258         * khtml/rendering/render_br.cpp: updated includes
259         * khtml/rendering/render_br.h: updated includes
260         * khtml/rendering/render_button.cpp: updated includes
261         * khtml/rendering/render_container.cpp: updated includes
262         * khtml/rendering/render_flow.cpp: updated includes
263         * khtml/rendering/render_line.cpp: updated includes
264         * khtml/rendering/render_object.cpp: updated includes
265         * khtml/rendering/render_text.cpp: Removed.
266         * khtml/rendering/render_text.h: Removed.
267         * khtml/xml/dom_docimpl.cpp: updated includes
268         * khtml/xml/dom_nodeimpl.cpp: updated includes
269         * khtml/xml/dom_position.cpp: updated includes
270         * khtml/xml/dom_textimpl.cpp: updated includes
271         * kwq/KWQAccObject.mm: updated includes
272         * kwq/KWQKHTMLPart.mm: updated includes
273         * kwq/KWQRenderTreeDebug.cpp: updated includes
274
275 2006-01-08  Eric Seidel  <eseidel@apple.com>
276
277         Reviewed by mjs & xenon.
278
279         Renamed a few in kwq/ from .mm to .cpp
280
281         * WebCore.xcodeproj/project.pbxproj: updated paths
282         * kwq/KWQDictImpl.cpp: Added.
283         * kwq/KWQDictImpl.mm: Removed.
284         * kwq/KWQKPartsEvent.cpp: Added.
285         * kwq/KWQKPartsEvent.mm: Removed.
286         * kwq/KWQListImpl.cpp: Added.
287         * kwq/KWQListImpl.mm: Removed.
288
289 2006-01-08  Eric Seidel  <eseidel@apple.com>
290
291         Reviewed by mjs.
292
293         Renamed several files in kwq/ from .mm to .cpp
294         Removed a few pieces of unused KWQ code.
295
296         * WebCore.xcodeproj/project.pbxproj:
297         * khtml/html/htmltokenizer.cpp:
298         (khtml::HTMLTokenizer::continueProcessing): removed KWQUIEventTime
299         (khtml::HTMLTokenizer::write): removed KWQUIEventTime
300         * khtml/html/htmltokenizer.h:
301         * khtml/khtml_part.cpp:
302         (KHTMLPart::slotFinished): removed KWQUIEventTime
303         * khtml/misc/loader.cpp:
304         (CachedObject::finish): removed KWQUIEventTime
305         * khtml/xml/dom_docimpl.cpp:
306         (DocumentImpl::processHttpEquiv): removed KWQUIEventTime
307         * kwq/KWQArrayImpl.cpp: Added.
308         * kwq/KWQArrayImpl.mm: Removed.
309         * kwq/KWQBuffer.cpp: Added.
310         * kwq/KWQBuffer.mm: Removed.
311         * kwq/KWQCString.cpp: Added.
312         * kwq/KWQCString.mm: Removed.
313         * kwq/KWQCharsets.cpp: Added.
314         * kwq/KWQCharsets.mm: Removed.
315         * kwq/KWQCollection.h:
316         (QPtrCollection::~QPtrCollection): made inline
317         * kwq/KWQCollection.mm: Removed.
318         * kwq/KWQDateTime.cpp: Added, removed KWQUIEventTime
319         * kwq/KWQDateTime.h:
320         * kwq/KWQDateTime.mm: Removed.
321         * kwq/KWQGlobal.cpp: Added.
322         * kwq/KWQGlobal.mm: Removed.
323         * kwq/KWQGuardedPtr.cpp: Added.
324         * kwq/KWQGuardedPtr.mm: Removed.
325         * kwq/KWQKCharsets.cpp: Added.
326         * kwq/KWQKCharsets.mm: Removed.
327         * kwq/KWQKGlobalSettings.h:
328         (KGlobalSettings::generalFont): made inline
329         (KGlobalSettings::windowTitleFont): made inline
330         (KGlobalSettings::menuFont): made inline
331         (KGlobalSettings::contrast): made inline
332         * kwq/KWQKGlobalSettings.mm: Removed.
333         * kwq/KWQKHTMLFactory.cpp: Added.
334         * kwq/KWQKHTMLFactory.mm: Removed.
335         * kwq/KWQKHTMLView.cpp: Added.
336         * kwq/KWQKHTMLView.mm: Removed.
337         * kwq/KWQKJob.h:
338         * kwq/KWQKJob.mm: Removed.
339         * kwq/KWQKWin.cpp: Added.
340         * kwq/KWQKWin.mm: Removed.
341         * kwq/KWQMapImpl.cpp: Added.
342         * kwq/KWQMapImpl.mm: Removed.
343         * kwq/KWQObject.cpp: Added.
344         * kwq/KWQObject.mm: Removed.
345         * kwq/KWQPen.cpp: Added.
346         * kwq/KWQPen.mm: Removed.
347         * kwq/KWQPointArray.cpp: Added.
348         * kwq/KWQPointArray.mm: Removed.
349         * kwq/KWQPtrDictImpl.cpp: Added.
350         * kwq/KWQPtrDictImpl.mm: Removed.
351         * kwq/KWQRegExp.cpp: Added.
352         * kwq/KWQRegExp.mm: Removed.
353         * kwq/KWQRegion.cpp: Added.
354         * kwq/KWQRegion.mm: Removed.
355         * kwq/KWQStyle.cpp: Added.
356         * kwq/KWQStyle.mm: Removed.
357         * kwq/KWQTextCodec.cpp: Added.
358         * kwq/KWQTextCodec.mm: Removed.
359         * kwq/KWQTextStream.cpp: Added.
360         * kwq/KWQTextStream.mm: Removed.
361         * kwq/KWQTimer.cpp: Added.
362         * kwq/KWQTimer.mm: Removed.
363         * kwq/KWQValueListImpl.cpp: Added.
364         * kwq/KWQValueListImpl.mm: Removed.
365         * kwq/KWQVariant.cpp: Added.
366         * kwq/KWQVariant.mm: Removed.
367         * kwq/KWQVectorImpl.cpp: Added.
368         * kwq/KWQVectorImpl.mm: Removed.
369         * kwq/KWQWMatrix.cpp: Added.
370         * kwq/KWQWMatrix.mm: Removed.
371
372 2006-01-07  Maciej Stachowiak  <mjs@apple.com>
373
374         Reviewed by Eric.
375
376         - added basic SVG text support using CSS-based rendering
377         http://bugzilla.opendarwin.org/show_bug.cgi?id=4883
378  
379         Affects many test results in LayoutTests/svg.
380
381         * kcanvas/RenderSVGText.cpp: Added. Simple subclass of RenderBlock for SVG text.
382         (RenderSVGText::RenderSVGText): just call superclass constructor.
383         (RenderSVGText::translateTopToBaseline): helper to account for the fact that
384         y coordinates for <text> give the baseline position, but the render tree expects
385         current y to be the top.
386         (RenderSVGText::translateForAttributes): translate to account for x and y
387         attributes.
388         (RenderSVGText::paint): Apply appropriate CTM transform and then just let
389         RenderBlock paint.
390         * kcanvas/RenderSVGText.h: Added.
391         (RenderSVGText::renderName):
392         * kcanvas/device/quartz/KRenderingDeviceQuartz.mm:
393         (KRenderingDeviceContextQuartz::nsGraphicsContext): We want the context flipped.
394         * ksvg2/css/svg.css: Give <svg:text> display: block
395         * ksvg2/svg/SVGTextElementImpl.cpp:
396         (SVGTextElementImpl::createRenderer): Create a RenderSVGText renderer.
397         (SVGTextElementImpl::childShouldCreateRenderer): Let child text nodes make
398         renderers, but nothing else (for now).
399         * ksvg2/svg/SVGTextElementImpl.h:
400         (KSVG::SVGTextElementImpl::rendererIsNeeded): It sure is! :-)
401         * WebCore.xcodeproj/project.pbxproj: Add new files.
402
403 2006-01-07  Eric Seidel  <eseidel@apple.com>
404
405         Reviewed by mjs
406
407         Removed old, unneeded code.
408
409         * WebCore+SVG/DrawCanvasItem.h: Removed.
410         * WebCore+SVG/DrawCanvasItem.mm: Removed.
411         * WebCore+SVG/DrawCanvasItemPrivate.h: Removed.
412         * WebCore+SVG/DrawDocument.h: Removed.
413         * WebCore+SVG/DrawDocument.mm: Removed.
414         * WebCore+SVG/DrawDocumentPrivate.h: Removed.
415         * WebCore+SVG/DrawView.h: Removed.
416         * WebCore+SVG/DrawView.mm: Removed.
417         * WebCore+SVG/DrawViewPrivate.h: Removed.
418         * WebCore+SVG/NSSVGImageRep.h: Removed.
419         * WebCore+SVG/NSSVGImageRep.m: Removed.
420         * WebCore.xcodeproj/project.pbxproj: remove files
421
422 2006-01-07  Maciej Stachowiak  <mjs@apple.com>
423
424         Reviewed by Eric.
425
426         - fixed WebCore build
427         http://bugzilla.opendarwin.org/show_bug.cgi?id=6404
428
429         * khtml/rendering/render_canvasimage.h: Remove unneeded extern declarations.
430
431 2006-01-07  Anders Carlsson  <andersca@mac.com>
432
433         Reviewed by Maciej.
434
435         - Fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6373
436         REGRESSION: JavaScript hang when comparing large array to null
437         
438         * khtml/ecma/kjs_html.cpp:
439         Remove toPrimitive.
440         
441         * khtml/ecma/kjs_html.h:
442         (KJS::HTMLAllCollection::isEqualToNull):
443         Implement isEqualToNull and have it return true.
444
445 2006-01-06  Eric Seidel  <eseidel@apple.com>
446
447         Reviewed by darin.
448
449         <rdar://problem/4386652> Crash: SVG filter crash at w3schools.com
450
451         * kcanvas/device/quartz/KCanvasFilterQuartz.mm:
452         (KCanvasFEDiffuseLightingQuartz::getCIFilter): nil check
453         (KCanvasFESpecularLightingQuartz::getCIFilter): nil check
454
455 2006-01-06  Geoffrey Garen  <ggaren@apple.com>
456
457         Patch by Mitz, reviwed by Darin, layout tested and landed by me.
458
459         - Fixed http://bugzilla.opendarwin.org/show_bug.cgi?id=6382
460         REGRESSION: Repro crash when clicking link with target="_blank"
461
462         * kwq/KWQKHTMLPart.mm:
463         (KWQKHTMLPart::setName):
464         * manual-tests/empty-link-target.html: Added.
465
466 2006-01-06  Alexey Proskuryakov  <ap@nypop.com>
467
468         Reviewed by Darin.
469
470         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=5291
471           FORM multipart/form-data with GET method issue
472
473         Test cases: 
474         * fast/forms/form-get-multipart.html
475         * fast/forms/form-get-multipart2.html
476         * fast/forms/form-get-multipart3.html
477         * fast/forms/form-post-urlencoded.html
478
479         * khtml/html/html_formimpl.cpp:
480         (DOM::HTMLFormElementImpl::submit):
481         Reset m_multipart to false if not posting.
482         (DOM::HTMLFormElementImpl::parseEnctype):
483         multipart/form-data doesn't imply POST method.
484
485 2006-01-06  Alexey Proskuryakov  <ap@nypop.com>
486
487         Reviewed by Eric.
488
489         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=5792
490           Crasher on rendering-shapes from SVG 1.0 testsuite
491
492         Test case: fast/parser/entity-ignorable-whitespace.xhtml
493
494         * khtml/xml/xml_tokenizer.cpp:
495         (khtml::XMLTokenizer::finish): install an ignorableWhitespace callback to
496         work around a libxml2 bug
497         (khtml::ignorableWhitespaceHandler): no-op
498
499 2006-01-06  Anders Carlsson  <andersca@mac.com>
500
501         Reviewed by Eric.
502
503         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=5142
504         parseXMLDocumentFragment can't parse fragments correctly
505         
506         * khtml/xml/xml_tokenizer.cpp:
507         (khtml::balancedStartElementNsHandler):
508         (khtml::balancedEndElementNsHandler):
509         (khtml::balancedCharactersHandler):
510         (khtml::balancedProcessingInstructionHandler):
511         (khtml::balancedCdataBlockHandler):
512         (khtml::balancedCommentHandler):
513         (khtml::balancedWarningHandler):
514         Add handlers.
515         
516         (khtml::parseXMLDocumentFragment):
517         Change back into using xmlParseBalancedChunkMemory. 
518
519 2006-01-06  Alexander Kellett  <lypanov@kde.org>
520
521         Reviewed by eseidel.
522
523         Basic support for <mask> tag.
524         http://bugzilla.opendarwin.org/show_bug.cgi?id=5969
525         Still missing attribute support for: maskUnits, maskContentUnits.
526         
527         Mask pixel tests do not work in DumpRenderTree due to:
528         http://bugzilla.opendarwin.org/show_bug.cgi?id=6327
529         Added test cases anyway.
530
531         This also tickles a (known) gradient update issue:
532         http://bugzilla.opendarwin.org/show_bug.cgi?id=6052
533
534         * WebCore.xcodeproj/project.pbxproj: added Mask files
535         * kcanvas/KCanvasResources.cpp:
536         (KCanvasMasker::KCanvasMasker): added.
537         (KCanvasMasker::~KCanvasMasker): added.
538         (KCanvasMasker::setMask): added.
539         (KCanvasMasker::externalRepresentation): added.
540         (getMaskerById): added.
541         * kcanvas/KCanvasResources.h:
542         (KCanvasResource::isMasker): added.
543         (KCanvasMasker::isMasker): added.
544         (KCanvasMasker::mask): added.
545         * kcanvas/device/quartz/KCanvasItemQuartz.mm:
546         (KCanvasItemQuartz::paint): added mask support
547         * kcanvas/device/quartz/KCanvasMaskerQuartz.h: Added.
548         (KCanvasMaskerQuartz::KCanvasMaskerQuartz): added.
549         * kcanvas/device/quartz/KCanvasMaskerQuartz.mm: Added.
550         (applyLuminanceToAlphaFilter): added.
551         (applyExpandAlphatoGrayscaleFilter): added.
552         (transformImageIntoGrayscaleMask): added.
553         (KCanvasMaskerQuartz::applyMask): added.
554         * kcanvas/device/quartz/KCanvasResourcesQuartz.mm:
555         (KCanvasContainerQuartz::paint): added mask support.
556         * kcanvas/device/quartz/KRenderingDeviceQuartz.mm:
557         (KRenderingDeviceQuartz::createResource): added mask support.
558         * kcanvas/device/quartz/KRenderingPaintServerGradientQuartz.mm:
559         (KRenderingPaintServerRadialGradientQuartz::draw):
560         * kcanvas/device/quartz/QuartzSupport.h:
561         * kcanvas/device/quartz/QuartzSupport.mm:
562         (debugDumpCGImageToFile): added, debug only.
563         (debugDumpCGLayerToFile): added, debug only.
564         (debugDumpCIImageToFile): added, debug only.
565         * ksvg2/css/SVGCSSStyleSelector.cpp:
566         (KDOM::CSSStyleSelector::applySVGProperty): added mask support.
567         * ksvg2/css/SVGRenderStyle.cpp:
568         (SVGRenderStyle::SVGRenderStyle): added mask support.
569         (SVGRenderStyle::operator==): added mask support.
570         * ksvg2/css/SVGRenderStyle.h:
571         * ksvg2/css/SVGRenderStyleDefs.cpp:
572         (StyleMaskData::StyleMaskData): added mask support.
573         (StyleMaskData::operator==): added mask support.
574         * ksvg2/css/SVGRenderStyleDefs.h:
575         (KSVG::StyleMaskData::operator!=): added mask support.
576         * ksvg2/ecma/Ecma.cpp:
577         (Ecma::inheritedGetDOMNode): added mask support.
578         * ksvg2/svg/SVGMaskElementImpl.cpp: Added.
579         (KSVG::SVGMaskElementImpl::SVGMaskElementImpl): added.
580         (KSVG::SVGMaskElementImpl::~SVGMaskElementImpl): added.
581         (KSVG::SVGMaskElementImpl::x): added.
582         (KSVG::SVGMaskElementImpl::y): added.
583         (KSVG::SVGMaskElementImpl::width): added.
584         (KSVG::SVGMaskElementImpl::height): added.
585         (KSVG::SVGMaskElementImpl::attributeChanged): added.
586         (KSVG::SVGMaskElementImpl::childrenChanged): added.
587         (KSVG::SVGMaskElementImpl::parseMappedAttribute): added.
588         (KSVG::SVGMaskElementImpl::drawMaskerContent): added.
589         (KSVG::SVGMaskElementImpl::createRenderer): added.
590         (KSVG::SVGMaskElementImpl::canvasResource): added.
591         * ksvg2/svg/SVGMaskElementImpl.h: Added.
592         (KSVG::SVGMaskElementImpl::isValid): added.
593         (KSVG::SVGMaskElementImpl::rendererIsNeeded): added.
594         * ksvg2/svg/svgtags.in: added <mask> support.
595
596 2006-01-04  Maciej Stachowiak  <mjs@apple.com>
597
598         Reviewed by Darin.
599
600         - move frame management and finding code from WebKit to WebCore
601         http://bugzilla.opendarwin.org/show_bug.cgi?id=6368
602
603         * WebCore.exp: export WebCoreFrameNamespace
604         * WebCore.xcodeproj/project.pbxproj: add new files
605         * kwq/KWQKHTMLPart.mm:
606         (KWQKHTMLPart::setName): Don't call to bridge any more, not needed
607         * kwq/WebCoreBridge.h:
608         * kwq/WebCoreBridge.mm:
609         (isCaseSensitiveEqual): helper function
610         (-[WebCoreBridge appendChild:]): remove excess braces
611         (-[WebCoreBridge childFrameNamed:]): moved here from WebFrame
612         (-[WebCoreBridge _deepLastChildFrame]): ditto
613         (-[WebCoreBridge nextFrameWithWrap:]): ditto
614         (-[WebCoreBridge previousFrameWithWrap:]): ditto
615         (-[WebCoreBridge setFrameNamespace:]): ditto
616         (-[WebCoreBridge frameNamespace]): ditto
617         (-[WebCoreBridge _shouldAllowAccessFrom:]): ditto
618         (-[WebCoreBridge _descendantFrameNamed:sourceFrame:]): ditto
619         (-[WebCoreBridge _frameInAnyWindowNamed:sourceFrame:]): ditto
620         (-[WebCoreBridge findFrameNamed:]): ditto
621         (-[WebCoreBridge setName:]): don't call KHTMLPart setName directly,
622         the kwq version is fine
623         (-[WebCoreBridge _addFramePathToString:]): moved from WebFrame
624         (-[WebCoreBridge generateFrameName]): ditto
625
626 2006-01-04  Anders Carlsson  <andersca@mac.com>
627
628         Reviewed by Eric.
629
630         Based on a patch by Eric.
631         
632         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6180
633         "text" output in fragment produced by XSLTProccessor is wrong (has xhtml garbage)
634         
635         * khtml/xsl/xslt_processorimpl.cpp:
636         (DOM::xsltParamArrayFromParameterMap):
637         (DOM::freeXsltParamArray):
638         Use fastMalloc/fastFree.
639         
640         (DOM::createFragmentFromSource):
641         If the output is "text", just create a text node and add
642         it to the fragment.
643
644 2006-01-04  Geoffrey Garen  <ggaren@apple.com>
645
646         Reviewed by darin.
647
648         - Fixed http://bugzilla.opendarwin.org/show_bug.cgi?id=6311
649         document.plugins doesn't exist
650
651         * khtml/ecma/kjs_html.cpp: Added 'plugins' as synonym for 'embeds'
652
653 2006-01-04  Geoffrey Garen  <ggaren@apple.com>
654  
655          Reviewed by darin.
656  
657          - Fixed <rdar://problem/4214080> document.embeds: embeds[0].Play() 
658          undefined at languageguide.org prevents audio playing on mouseover
659  
660          - Layout test: fast/dom/object-embed-plugin-scripting.html
661  
662          A common idiom the kids like to use these days for plugins is to nest 
663          an <embed> inside an <object>, and assume that IE will honor the first,
664          Mozilla the second. We happen to honor both, but the rules dictate that
665          only the outer <object> gets a plugin/renderer. (A plugin is a 
666         renderer.) This is a problem because sites ID us as Mozilla and 
667         therefore attempt to script their plugins through the <embed>, which 
668         has no plugin/renderer. The fix here is to have an <embed> return its 
669         parent node's plugin/renderer when queried, if and only if it has no 
670         renderer of its own and its parent node is an <object>. We may decide
671         to restrict this further in the future.
672
673         One happy consequence of this patch is that all the apple.com Quicktime
674         websites we had previously broken with TOT are now fixed. 
675
676         * khtml/html/html_objectimpl.cpp:
677         (DOM::HTMLEmbedElementImpl::getEmbedInstance): The "if (!r)" clause 
678         implements the logic I just described. The code below it I changed 
679         just for style, to match the style in getObjectInstance().
680
681         (DOM::HTMLEmbedElementImpl::rendererIsNeeded): Assert that an <object>
682         parent has a renderer because we're going to use it later.
683
684         (DOM::HTMLObjectElementImpl::rendererIsNeeded): Changed to match style 
685         of HTMLEmbedElementImpl counterpart.
686
687 2006-01-04  Mitz Pettel  <opendarwin.org@mitzpettel.com>
688
689         Reviewed by Darin, landed by ap.
690         
691         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6301
692           REGRESSION: Border repaint glitch
693
694         * khtml/rendering/render_object.cpp:
695         (RenderObject::repaintAfterLayoutIfNeeded): Repaint parts of the
696         border that moved.
697         * manual-tests/border-repaint-glitch.html: Added.
698
699 2005-12-30  Kimmo Kinnunen  <kimmo.kinnunen@nokia.com>
700
701         Reviewed by eseidel.
702
703         Changed use of QRect to QRectF in the points where SVG can have
704         fractional numbers
705         http://bugzilla.opendarwin.org/show_bug.cgi?id=4462
706
707         Added test cases:
708         * svg/custom/fractional-rects.svg: copy of rounded-rects.svg with
709         fractional coordinates.
710
711         * WebCore.xcodeproj/project.pbxproj:
712         * kwq/KWQWMatrix.h:
713         * kwq/KWQWMatrix.mm:
714         (QWMatrix::mapRect): mapRect for QRectF
715         * kwq/KWQRectF.h:
716         * kwq/KWQRectF.mm:  Added. QRectF impl
717         * kwq/KWQSizeF.h:
718         * kwq/KWQSizeF.mm:  Added.QSizeF impl
719         * kwq/KWQPointF.h:
720         * kwq/KWQPointF.mm: Added. QPointF impl
721         * kcanvas/KCanvasContainer.cpp:
722         (KCanvasContainer::fillContains):
723         (KCanvasContainer::strokeContains):
724         (KCanvasContainer::relativeBBox):
725         (KCanvasContainer::getAspectRatio): QRect -> QRectF
726         * kcanvas/KCanvasContainer.h:
727         * kcanvas/KCanvasFilters.cpp:
728         (KCanvasFilterEffect::subRegion):
729         (KCanvasFilterEffect::setSubRegion): QRect -> QRectF
730         * kcanvas/KCanvasFilters.h:
731         (KCanvasFilter::filterRect):
732         (KCanvasFilter::setFilterRect): QRect -> QRectF
733         (KCanvasFEConvolveMatrix::kernelSize):
734         (KCanvasFEConvolveMatrix::setKernelSize):
735         (KCanvasFEConvolveMatrix::targetOffset):
736         (KCanvasFEConvolveMatrix::setTargetOffset): QSize -> QSizeF
737         * kcanvas/KCanvasItem.cpp:
738         (RenderPath::fillContains):
739         (RenderPath::strokeContains):
740         (RenderPath::relativeBBox): QRect -> QRectF
741         * kcanvas/KCanvasItem.h:
742         * kcanvas/KCanvasResources.cpp:
743         (KCanvasMarker::draw): QRect -> QRectF
744         * kcanvas/KCanvasResources.h:
745         * kcanvas/KCanvasTreeDebug.cpp:
746         (hasFractions): helper function
747         (operator<<): QSizeF operator, QRectF operator
748         * kcanvas/KCanvasTreeDebug.h:
749         * kcanvas/device/KRenderingPaintServerGradient.cpp:
750         (KRenderingPaintServerLinearGradient::gradientStart):
751         (KRenderingPaintServerLinearGradient::setGradientStart):
752         (KRenderingPaintServerLinearGradient::gradientEnd):
753         (KRenderingPaintServerLinearGradient::setGradientEnd):
754         (KRenderingPaintServerRadialGradient::gradientCenter):
755         (KRenderingPaintServerRadialGradient::setGradientCenter):
756         (KRenderingPaintServerRadialGradient::gradientFocal):
757         (KRenderingPaintServerRadialGradient::setGradientFocal): QPoint -> QPointF
758         * kcanvas/device/KRenderingPaintServerGradient.h:
759         * kcanvas/device/KRenderingPaintServerPattern.cpp:
760         (KRenderingPaintServerPattern::Private::Private): x, y, width, height -> QRectF
761         (KRenderingPaintServerPattern::setBbox): replaced get/set methods
762         (KRenderingPaintServerPattern::bbox): replaced get/set methods
763         (KRenderingPaintServerPattern::externalRepresentation):
764         * kcanvas/device/KRenderingPaintServerPattern.h:
765         * kcanvas/device/quartz/KCanvasFilterQuartz.h:
766         * kcanvas/device/quartz/KCanvasFilterQuartz.mm:
767         (KCanvasFilterQuartz::prepareFilter):
768         (KCanvasFilterQuartz::applyFilter): QRect -> QRectF
769         * kcanvas/device/quartz/KCanvasItemQuartz.h:
770         (KCanvasItemQuartz::getAbsoluteRepaintRect): QRect -> QRectF
771         * kcanvas/device/quartz/KCanvasItemQuartz.mm:
772         (drawMarkerWithData):
773         (KCanvasItemQuartz::drawMarkersIfNeeded):
774         (KCanvasItemQuartz::paint): QRect -> QRectF
775         (KCanvasItemQuartz::nodeAtPoint): QPoint -> QPointF
776         (KCanvasItemQuartz::bboxForPath) :QRect -> QRectF
777         (KCanvasItemQuartz::hitsPath):
778         * kcanvas/device/quartz/KCanvasResourcesQuartz.h:
779         (KCanvasContainerQuartz::getAbsoluteRepaintRect): QRect -> QRectF
780         * kcanvas/device/quartz/KRenderingPaintServerQuartz.mm:
781         (KRenderingPaintServerPatternQuartz::draw): QRect -> QRectF
782         * khtml/rendering/render_object.h:
783         (khtml::RenderObject::relativeBBox):QRect -> QRectF
784         * ksvg2/svg/SVGFilterElementImpl.cpp:
785         (SVGFilterElementImpl::canvasResource): QRect -> QRectF
786         * ksvg2/svg/SVGFilterPrimitiveStandardAttributesImpl.cpp:
787         (SVGFilterPrimitiveStandardAttributesImpl::setStandardAttributes):
788         * ksvg2/svg/SVGLengthImpl.cpp:
789         (SVGLengthImpl::value): QRect -> QRectF
790         * ksvg2/svg/SVGLinearGradientElementImpl.cpp:
791         (SVGLinearGradientElementImpl::buildGradient): QPoint -> QPointF, removed integer conversions
792         * ksvg2/svg/SVGLocatableImpl.cpp:
793         (SVGLocatableImpl::getBBox): Rect -> QRectF
794         * ksvg2/svg/SVGPatternElementImpl.cpp:
795         (SVGPatternElementImpl::drawPatternContentIntoTile): QRect -> QRectF
796         * ksvg2/svg/SVGRadialGradientElementImpl.cpp:
797         (SVGRadialGradientElementImpl::buildGradient): QPoint -> QPointF, removed integer conversions
798         * ksvg2/svg/SVGSVGElementImpl.cpp:
799         (SVGSVGElementImpl::checkIntersection): QRect -> QRectF, removed integer conversions
800         (SVGSVGElementImpl::checkEnclosure): QRect -> QRectF, removed integer conversions
801
802 2006-01-03  Maciej Stachowiak  <mjs@apple.com>
803
804         Reviewed by Vicki.
805
806         - moved frame traversal code across from bridge, also dropped the children
807         array
808
809         * kwq/WebCoreBridge.h:
810         * kwq/WebCoreBridge.mm:
811         (-[WebCoreBridge firstChild]): Moved from WebBridge. Use new _firstChild
812         pointer.
813         (-[WebCoreBridge lastChild]): Moved from WebBridge. Use new _lastChild pointer.
814         (-[WebCoreBridge childCount]): Moved from WebBridge. Use _childCount variable.
815         (-[WebCoreBridge previousSibling]): Moved from WebBridge.
816         (-[WebCoreBridge nextSibling]): ditt
817         (-[WebCoreBridge isDescendantOfFrame:]): ditto
818         (-[WebCoreBridge traverseNextFrameStayWithin:]): ditto
819         (-[WebCoreBridge appendChild:]): Moved from WebBridge, maintain count and first/last
820         pointers.
821         (-[WebCoreBridge removeChild:]): Moved from WebBridge, maintain count and first/last
822         pointers.
823
824 2006-01-03  Justin Garcia  <justin.garcia@apple.com>
825
826         Reviewed by harrison
827
828         <http://bugzilla.opendarwin.org/show_bug.cgi?id=4609>
829         window.getSelection().toString() is undefined (range object 
830         returned from window.getSelection() is useless)
831
832         toString was defined as a method on the JS Selection object, 
833         but it didn't return anything.
834
835         Added layout test:
836         * editing/selection/toString.html
837
838         * khtml/ecma/kjs_window.cpp:
839         (KJS::SelectionFunc::callAsFunction):
840
841 2006-01-03  Geoffrey Garen  <ggaren@apple.com>
842
843         Reviewed by timo.
844
845         - Fixed: http://bugzilla.opendarwin.org/show_bug.cgi?id=6318
846         REGRESSION: Repro crash in JS called from Flash on bdash.net.nz
847
848         Since we clear all the plugin data structures in setView, we need to
849         clear the windowScriptObject as well. I had already done this in my
850         previous patch, but I didn't realize there are two windowScriptObjects 
851         -- one for Netscape PlugIns, and one for WebKit PlugIns.
852
853         * kwq/KWQKHTMLPart.mm:
854         (KWQKHTMLPart::setView): Clear the Netscape PlugIn windowScriptObject
855         as well.
856
857 2006-01-03  Anders Carlsson  <andersca@mac.com>
858
859         Reviewed by Eric.
860
861         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6358
862         JS objects missing "prototype" properties
863         
864         * khtml/ecma/XSLTProcessor.cpp:
865         (KJS::XSLTProcessorConstructorImp::XSLTProcessorConstructorImp):
866         * khtml/ecma/XSLTProcessor.h:
867         * khtml/ecma/domparser.cpp:
868         (KJS::DOMParserConstructorImp::DOMParserConstructorImp):
869         * khtml/ecma/xmlhttprequest.cpp:
870         (KJS::XMLHttpRequestConstructorImp::XMLHttpRequestConstructorImp):
871         * khtml/ecma/xmlserializer.cpp:
872         (KJS::XMLSerializerConstructorImp::XMLSerializerConstructorImp):
873         Add "prototype" property in constructors.
874
875 2006-01-03  Eric Seidel  <eseidel@apple.com>
876
877         Reviewed by darin.
878
879         REGRESSION: repro crash w/ invalid charset attribute on <script>
880         http://bugzilla.opendarwin.org/show_bug.cgi?id=6345
881         I also made some small spacing cleanup here.
882         I did *not* fix the usage in formData, as the move from KCharSet to
883         QTextCodec actually fixed a bug whereby if the first listed charset
884         in accept-charsets was invalid, we would assume latin1 instead of
885         checking for the next valid one before assuming system encoding.
886
887         * khtml/html/html_formimpl.cpp:
888         (DOM::HTMLFormElementImpl::formData): cleanup
889         * khtml/misc/loader.cpp:
890         (CachedCSSStyleSheet::CachedCSSStyleSheet): null check
891         (CachedScript::CachedScript): cleanup
892         (CachedXSLStyleSheet::CachedXSLStyleSheet): null check
893         (CachedXBLDocument::CachedXBLDocument): cleanup
894
895 2006-01-03  Justin Garcia  <justin.garcia@apple.com>
896
897         <http://bugzilla.opendarwin.org/show_bug.cgi?id=4904>
898         Bug with baseOffset and extentOffset in selections (for writely.com)
899         <rdar://problem/4259818>
900         selection object incorrect after double-clicking a word
901         
902         Reviewed by harrison
903
904         Changed the Selection object's anchor/focus properties to match 
905         Mozilla's Selection object API, added getRangeAt and outlined the 
906         rest of the API.
907         Cleaned up the JS Selection object (to do less work in the DOM binding).
908         Added an updateLayout call to VisiblePosition::init and removed some 
909         updateLayout calls from other parts of the editing code.
910         
911         Added layout tests:
912         * editing/selection/getRangeAt.html
913         * editing/selection/anchor-focus1.html
914         * editing/selection/anchor-focus2.html
915         * editing/selection/anchor-focus3.html
916         Updated expected results:
917         * editing/selection/unrendered-001-expected.txt
918
919         * khtml/ecma/kjs_window.cpp:
920         (KJS::Selection::getValueProperty):
921         (KJS::Selection::toString):
922         (KJS::SelectionFunc::callAsFunction):
923         * khtml/ecma/kjs_window.h:
924         (KJS::Selection::):
925         * khtml/editing/SelectionController.cpp:
926         (khtml::SelectionController::modify):
927         (khtml::SelectionController::type):
928         (khtml::SelectionController::toString):
929         (khtml::SelectionController::getRangeAt):
930         (khtml::SelectionController::setBaseAndExtent):
931         (khtml::SelectionController::setPosition):
932         (khtml::SelectionController::collapse):
933         (khtml::SelectionController::collapseToEnd):
934         (khtml::SelectionController::collapseToStart):
935         (khtml::SelectionController::empty):
936         (khtml::SelectionController::extend):
937         (khtml::SelectionController::validate):
938         * khtml/editing/SelectionController.h:
939         (khtml::SelectionController::part):
940         (khtml::SelectionController::baseNode):
941         (khtml::SelectionController::extentNode):
942         (khtml::SelectionController::baseOffset):
943         (khtml::SelectionController::extentOffset):
944         (khtml::SelectionController::anchorNode):
945         (khtml::SelectionController::anchorOffset):
946         (khtml::SelectionController::focusNode):
947         (khtml::SelectionController::focusOffset):
948         (khtml::SelectionController::isCollapsed):
949         * khtml/editing/visible_position.cpp:
950         (khtml::VisiblePosition::init):
951         (khtml::VisiblePosition::isCandidate):
952         * khtml/khtml_part.cpp:
953         (KHTMLPart::handleMousePressEventSingleClick):
954
955 2006-01-03  Anders Carlsson  <andersca@mac.com>
956
957         Reviewed by Maciej.
958
959         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=5378
960         createDocument fails with DOM Exception 5 when passed empty qname
961         
962         * khtml/ecma/kjs_dom.cpp:
963         (KJS::DOMDOMImplementationProtoFunc::callAsFunction):
964         When passing null to createDocument, pass a null DOMString, and not
965         a DOMString containing the text "null".
966         
967         * khtml/xml/dom_docimpl.cpp:
968         (DOMImplementationImpl::createDocument):
969         Only validate the qualifiedName if it's not null or empty. Also, do not
970         create the document element if the qualifiedName is null or empty.
971
972 2006-01-03  Eric Seidel  <eseidel@apple.com>
973
974         Reviewed by darin.
975
976         No functionality changes, no tests possible.
977
978         khtml/editing should use RefPtr instead of manual ref/deref
979         http://bugzilla.opendarwin.org/show_bug.cgi?id=6109
980
981         Results in a slight performance gain < 1% on the PLT.
982
983         * khtml/editing/SelectionController.cpp:
984         (khtml::SelectionController::toRange):
985         * khtml/editing/SelectionController.h:
986         * khtml/editing/append_node_command.cpp:
987         (khtml::AppendNodeCommand::AppendNodeCommand):
988         (khtml::AppendNodeCommand::doApply):
989         (khtml::AppendNodeCommand::doUnapply):
990         * khtml/editing/append_node_command.h:
991         (khtml::AppendNodeCommand::~AppendNodeCommand):
992         (khtml::AppendNodeCommand::appendChild):
993         (khtml::AppendNodeCommand::parentNode):
994         * khtml/editing/apply_style_command.cpp:
995         (khtml::StyleChange::init):
996         (khtml::ApplyStyleCommand::removeInlineStyle):
997         * khtml/editing/apply_style_command.h:
998         * khtml/editing/composite_edit_command.cpp:
999         (khtml::CompositeEditCommand::deleteInsignificantText):
1000         * khtml/editing/delete_from_text_node_command.cpp:
1001         (khtml::DeleteFromTextNodeCommand::DeleteFromTextNodeCommand):
1002         * khtml/editing/delete_from_text_node_command.h:
1003         (khtml::DeleteFromTextNodeCommand::~DeleteFromTextNodeCommand):
1004         (khtml::DeleteFromTextNodeCommand::node):
1005         * khtml/editing/delete_selection_command.cpp:
1006         (khtml::DeleteSelectionCommand::initializePositionData):
1007         (khtml::DeleteSelectionCommand::saveTypingStyleState):
1008         (khtml::DeleteSelectionCommand::handleGeneralDelete):
1009         (khtml::DeleteSelectionCommand::calculateEndingPosition):
1010         (khtml::DeleteSelectionCommand::calculateTypingStyleAfterDelete):
1011         (khtml::DeleteSelectionCommand::clearTransientState):
1012         * khtml/editing/delete_selection_command.h:
1013         * khtml/editing/edit_command.cpp:
1014         (khtml::EditCommand::EditCommand):
1015         (khtml::EditCommand::~EditCommand):
1016         (khtml::EditCommand::setTypingStyle):
1017         (khtml::EditCommand::styleAtPosition):
1018         * khtml/editing/edit_command.h:
1019         (khtml::EditCommand::document):
1020         (khtml::EditCommand::typingStyle):
1021         * khtml/editing/insert_into_text_node_command.cpp:
1022         (khtml::InsertIntoTextNodeCommand::InsertIntoTextNodeCommand):
1023         * khtml/editing/insert_into_text_node_command.h:
1024         (khtml::InsertIntoTextNodeCommand::~InsertIntoTextNodeCommand):
1025         (khtml::InsertIntoTextNodeCommand::node):
1026         * khtml/editing/insert_node_before_command.cpp:
1027         (khtml::InsertNodeBeforeCommand::InsertNodeBeforeCommand):
1028         (khtml::InsertNodeBeforeCommand::doApply):
1029         (khtml::InsertNodeBeforeCommand::doUnapply):
1030         * khtml/editing/insert_node_before_command.h:
1031         (khtml::InsertNodeBeforeCommand::~InsertNodeBeforeCommand):
1032         (khtml::InsertNodeBeforeCommand::insertChild):
1033         (khtml::InsertNodeBeforeCommand::refChild):
1034         * khtml/editing/insert_paragraph_separator_command.cpp:
1035         (khtml::InsertParagraphSeparatorCommand::InsertParagraphSeparatorCommand):
1036         (khtml::InsertParagraphSeparatorCommand::~InsertParagraphSeparatorCommand):
1037         (khtml::InsertParagraphSeparatorCommand::calculateStyleBeforeInsertion):
1038         (khtml::InsertParagraphSeparatorCommand::applyStyleAfterInsertion):
1039         * khtml/editing/insert_paragraph_separator_command.h:
1040         * khtml/editing/join_text_nodes_command.cpp:
1041         (khtml::JoinTextNodesCommand::JoinTextNodesCommand):
1042         (khtml::JoinTextNodesCommand::doApply):
1043         (khtml::JoinTextNodesCommand::doUnapply):
1044         * khtml/editing/join_text_nodes_command.h:
1045         (khtml::JoinTextNodesCommand::~JoinTextNodesCommand):
1046         (khtml::JoinTextNodesCommand::firstNode):
1047         (khtml::JoinTextNodesCommand::secondNode):
1048         * khtml/editing/jsediting.cpp:
1049         * khtml/editing/markup.cpp:
1050         (khtml::createMarkup):
1051         (khtml::createFragmentFromMarkup):
1052         (khtml::createFragmentFromText):
1053         (khtml::createFragmentFromNodeList):
1054         * khtml/editing/markup.h:
1055         * khtml/editing/merge_identical_elements_command.cpp:
1056         (khtml::MergeIdenticalElementsCommand::MergeIdenticalElementsCommand):
1057         (khtml::MergeIdenticalElementsCommand::doApply):
1058         (khtml::MergeIdenticalElementsCommand::doUnapply):
1059         * khtml/editing/merge_identical_elements_command.h:
1060         (khtml::MergeIdenticalElementsCommand::~MergeIdenticalElementsCommand):
1061         * khtml/editing/move_selection_command.cpp:
1062         (khtml::MoveSelectionCommand::MoveSelectionCommand):
1063         (khtml::MoveSelectionCommand::~MoveSelectionCommand):
1064         (khtml::MoveSelectionCommand::doApply):
1065         * khtml/editing/move_selection_command.h:
1066         * khtml/editing/rebalance_whitespace_command.cpp:
1067         * khtml/editing/rebalance_whitespace_command.h:
1068         (khtml::RebalanceWhitespaceCommand::~RebalanceWhitespaceCommand):
1069         * khtml/editing/remove_css_property_command.cpp:
1070         (khtml::RemoveCSSPropertyCommand::RemoveCSSPropertyCommand):
1071         * khtml/editing/remove_css_property_command.h:
1072         (khtml::RemoveCSSPropertyCommand::~RemoveCSSPropertyCommand):
1073         (khtml::RemoveCSSPropertyCommand::styleDeclaration):
1074         * khtml/editing/remove_node_attribute_command.cpp:
1075         (khtml::RemoveNodeAttributeCommand::RemoveNodeAttributeCommand):
1076         * khtml/editing/remove_node_attribute_command.h:
1077         (khtml::RemoveNodeAttributeCommand::~RemoveNodeAttributeCommand):
1078         (khtml::RemoveNodeAttributeCommand::element):
1079         * khtml/editing/remove_node_command.cpp:
1080         (khtml::RemoveNodeCommand::RemoveNodeCommand):
1081         (khtml::RemoveNodeCommand::doApply):
1082         (khtml::RemoveNodeCommand::doUnapply):
1083         * khtml/editing/remove_node_command.h:
1084         (khtml::RemoveNodeCommand::~RemoveNodeCommand):
1085         (khtml::RemoveNodeCommand::node):
1086         * khtml/editing/remove_node_preserving_children_command.cpp:
1087         (khtml::RemoveNodePreservingChildrenCommand::RemoveNodePreservingChildrenCommand):
1088         * khtml/editing/remove_node_preserving_children_command.h:
1089         (khtml::RemoveNodePreservingChildrenCommand::~RemoveNodePreservingChildrenCommand):
1090         (khtml::RemoveNodePreservingChildrenCommand::node):
1091         * khtml/editing/replace_selection_command.cpp:
1092         (khtml::ReplacementFragment::ReplacementFragment):
1093         (khtml::ReplacementFragment::~ReplacementFragment):
1094         (khtml::ReplacementFragment::enclosingBlock):
1095         (khtml::ReplacementFragment::removeNodePreservingChildren):
1096         (khtml::ReplacementFragment::removeNode):
1097         (khtml::ReplacementFragment::insertFragmentForTestRendering):
1098         (khtml::ReplacementFragment::restoreTestRenderingNodesToFragment):
1099         (khtml::ReplaceSelectionCommand::fixupNodeStyles):
1100         (khtml::computeAndStoreNodeDesiredStyle):
1101         (khtml::NodeDesiredStyle::NodeDesiredStyle):
1102         (khtml::ReplaceSelectionCommand::ReplaceSelectionCommand):
1103         (khtml::ReplaceSelectionCommand::~ReplaceSelectionCommand):
1104         (khtml::ReplaceSelectionCommand::doApply):
1105         (khtml::ReplaceSelectionCommand::completeHTMLReplacement):
1106         (khtml::ReplaceSelectionCommand::updateNodesInserted):
1107         * khtml/editing/replace_selection_command.h:
1108         (khtml::NodeDesiredStyle::node):
1109         (khtml::NodeDesiredStyle::style):
1110         (khtml::ReplacementFragment::root):
1111         * khtml/editing/set_node_attribute_command.cpp:
1112         (khtml::SetNodeAttributeCommand::SetNodeAttributeCommand):
1113         * khtml/editing/set_node_attribute_command.h:
1114         (khtml::SetNodeAttributeCommand::~SetNodeAttributeCommand):
1115         (khtml::SetNodeAttributeCommand::element):
1116         * khtml/editing/split_element_command.cpp:
1117         (khtml::SplitElementCommand::SplitElementCommand):
1118         (khtml::SplitElementCommand::doApply):
1119         (khtml::SplitElementCommand::doUnapply):
1120         * khtml/editing/split_element_command.h:
1121         (khtml::SplitElementCommand::~SplitElementCommand):
1122         * khtml/editing/split_text_node_command.cpp:
1123         (khtml::SplitTextNodeCommand::SplitTextNodeCommand):
1124         (khtml::SplitTextNodeCommand::doApply):
1125         (khtml::SplitTextNodeCommand::doUnapply):
1126         * khtml/editing/split_text_node_command.h:
1127         (khtml::SplitTextNodeCommand::~SplitTextNodeCommand):
1128         (khtml::SplitTextNodeCommand::node):
1129         * khtml/editing/split_text_node_containing_element.cpp:
1130         (khtml::SplitTextNodeContainingElementCommand::SplitTextNodeContainingElementCommand):
1131         (khtml::SplitTextNodeContainingElementCommand::doApply):
1132         * khtml/editing/split_text_node_containing_element_command.h:
1133         (khtml::SplitTextNodeContainingElementCommand::~SplitTextNodeContainingElementCommand):
1134         * khtml/editing/visible_position.cpp:
1135         (khtml::makeRange):
1136         * khtml/editing/visible_position.h:
1137         * khtml/editing/visible_text.cpp:
1138         (khtml::TextIterator::range):
1139         (khtml::SimplifiedBackwardsTextIterator::range):
1140         (khtml::CharacterIterator::range):
1141         (khtml::findPlainText):
1142         * khtml/editing/visible_text.h:
1143         (khtml::WordAwareIterator::range):
1144         * khtml/editing/wrap_contents_in_dummy_span_command.cpp:
1145         (khtml::WrapContentsInDummySpanCommand::WrapContentsInDummySpanCommand):
1146         (khtml::WrapContentsInDummySpanCommand::doApply):
1147         (khtml::WrapContentsInDummySpanCommand::doUnapply):
1148         * khtml/editing/wrap_contents_in_dummy_span_command.h:
1149         (khtml::WrapContentsInDummySpanCommand::~WrapContentsInDummySpanCommand):
1150         * kwq/DOMHTML.mm:
1151         (-[DOMHTMLDocument _createDocumentFragmentWithMarkupString:baseURLString:]):
1152         (-[DOMHTMLDocument _createDocumentFragmentWithText:]):
1153         * kwq/WebCoreBridge.mm:
1154         (-[WebCoreBridge documentFragmentWithMarkupString:baseURLString:]):
1155         (-[WebCoreBridge documentFragmentWithText:]):
1156         (-[WebCoreBridge documentFragmentWithNodesAsParagraphs:]):
1157
1158 2006-01-03  Anders Carlsson  <andersca@mac.com>
1159
1160         Reviewed by Darin.
1161
1162         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=5177
1163         Javascript cloneNode(deep) does not clone form elements correctly
1164
1165         * khtml/html/html_elementimpl.cpp:
1166         (HTMLElementImpl::cloneNode):
1167         Call copyNonAttributeProperties on the new node.
1168         
1169         * khtml/html/html_formimpl.cpp:
1170         (DOM::HTMLInputElementImpl::copyNonAttributeProperties):
1171         * khtml/html/html_formimpl.h:
1172         Copy m_value, m_checked and m_indeterminate here.
1173         
1174         * khtml/xml/dom_docimpl.cpp:
1175         (DocumentImpl::importNode):
1176         Call copyNonAttributeProperties on the new node.
1177         
1178         * khtml/xml/dom_elementimpl.cpp:
1179         (ElementImpl::cloneNode):
1180         Call copyNonAttributeProperties on the new node.
1181         
1182         * khtml/xml/dom_elementimpl.h:
1183         (DOM::ElementImpl::copyNonAttributeProperties):
1184         Add function declaration.
1185
1186 2006-01-02  Maciej Stachowiak  <mjs@apple.com>
1187
1188         Rubber stamped by Eric.
1189
1190         - remove the no longer used QIntDict
1191
1192         * kwq/KWQIntDict.h: Removed.
1193
1194 2006-01-03  Alexey Proskuryakov  <ap@nypop.com>
1195
1196         Reviewed by Eric.
1197
1198         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=5609
1199           XSLT document() doesn't handle relative paths
1200
1201         Test case: fast/xsl/xslt-relative-path.xml
1202
1203         * khtml/xsl/xslt_processorimpl.cpp:
1204         (DOM::docLoaderFunc): Renamed from stylesheetLoadFunc. Use base URL when constructing URLs.
1205         (DOM::XSLTProcessorImpl::transformToString):
1206
1207 2006-01-02  Vicki Murley  <vicki@apple.com>
1208
1209         Reviewed by Maciej.
1210  
1211         - fix for <rdar://problem/4389622> *Pan EU2* iframe swallows events for overlapping elements (part 2)
1212
1213         We originally added a call to passSubframeEventToSubframe here to fix the hand cursor updating problem
1214         reported in <rdar://problem/4316201> REGRESSION: cursor and text in status bar is not updated when 
1215         mousing over links in a frame (5509). However, when we return early after passSubframeEventToSubframe,
1216         we fail to fire onmouseout events.  Since the call to passSubframeEventToSubframe was originally added
1217         to fix the hand cursor updating problem, remove the early return and make cursor updating conditional
1218         on passSubframeEventToSubframe.
1219
1220         * khtml/khtmlview.cpp:
1221         (KHTMLView::viewportMouseMoveEvent):
1222
1223 2005-12-30  Darin Adler  <darin@apple.com>
1224
1225         Reviewed by Maciej.
1226
1227         - http://bugzilla.opendarwin.org/show_bug.cgi?id=4557
1228           rename unusual strcmp and strcasecmp for DOMString family
1229
1230         Added new functions named equal and equalIgnoringCase.
1231
1232         * khtml/xml/dom_stringimpl.h: Changed the type of the length parameter to computeHash to unsigned
1233         to match the rest of the interface. Added equal and equalIgnoringCase functions. Added a
1234         version of the hash function that works on char* to CaseInsensitiveHash as preparation for an
1235         atomic string change.
1236         * khtml/xml/dom_stringimpl.cpp: Moved the QT_ALLOC_QCHAR_VEC and QT_DELETE_QCHAR_VEC macros
1237         here, and changed them into inline functions.
1238         (DOM::equal): Implemented.
1239         (DOM::equalIgnoringCase): Implemented.
1240         (DOM::DOMStringImpl::computeHash): Changed parameter type to unsigned to match other similar
1241         functions.
1242
1243         * khtml/dom/dom_string.h: Removed unnecessary friend declarations. Changed operator
1244         overloads for == and != to call through inline to DOMStringImpl. Replaced strcasecmp
1245         with equalIgnoringCase, overloaded for one more combination of parameters. Removed strcmp.
1246         * khtml/dom/dom_string.cpp: Removed functions that are now implemented in DOMStringImpl*.
1247
1248         * khtml/xml/dom_atomicstring.h: Removed a redundant const. Removed unnecessary
1249         friend declarations. Removed AtomicString::equal. Filled out a larger set of == and
1250         != operator implementations, mostly with inlines calling through to DOMStringImpl.
1251         Renamed equalsIgnoreCase to equalIgnoringCase and filled out a larger set as above.
1252         * khtml/xml/dom_atomicstring.cpp: Renamed AtomicString::equal to just ==.
1253         Removed some implementation of == and equalsIgnoreCase that are replaced by inlines.
1254
1255         * khtml/html/html_listimpl.cpp:
1256         (DOM::HTMLOListElementImpl::parseMappedAttribute):
1257         (DOM::HTMLLIElementImpl::parseMappedAttribute):
1258         Use the "==" operator instead of strcmp.
1259
1260         * khtml/css/cssstyleselector.cpp: (khtml::CSSStyleSelector::checkOneSelector):
1261         Use equalIgnoringCase instead of equalsIgnoreCase.
1262
1263         * khtml/rendering/render_form.cpp:
1264         (RenderSlider::updateFromElement): Fixed bug where a temporary DOMString was put into
1265         a const DOMString&. Changed some DOMString to AtomicString as appropriate, and also
1266         used equalIgnoringCase instead of strcasecmp.
1267         (RenderSlider::slotSliderValueChanged): More of the same.
1268
1269         * khtml/xml/dom_docimpl.cpp: (DocumentImpl::processHttpEquiv): Replaced use of strcasecmp
1270         with equalIgnoringCase. Added parentheses to fix incorrect operator precedence in one case
1271         (&& binds tighter than ||) which fixes a crash when using a http-equiv pragma when there
1272         is no part (not sure how to reproduce that).
1273
1274         * khtml/khtml_part.cpp:
1275         (updateState):
1276         (KHTMLPart::selectionStartHasStyle):
1277         * khtml/ecma/kjs_html.cpp: (KJS::KJS::HTMLDocument::putValueProperty):
1278         * khtml/editing/apply_style_command.cpp:
1279         (khtml::StyleChange::checkForLegacyHTMLStyleChange):
1280         (khtml::StyleChange::currentlyHasStyle):
1281         (khtml::hasTextDecorationProperty):
1282         (khtml::ApplyStyleCommand::extractTextDecorationStyle):
1283         (khtml::ApplyStyleCommand::extractAndNegateTextDecorationStyle):
1284         * khtml/html/html_baseimpl.cpp:
1285         (HTMLBodyElementImpl::parseMappedAttribute):
1286         (HTMLFrameElementImpl::parseMappedAttribute):
1287         * khtml/html/html_blockimpl.cpp:
1288         (HTMLDivElementImpl::parseMappedAttribute):
1289         (HTMLHRElementImpl::parseMappedAttribute):
1290         (HTMLParagraphElementImpl::parseMappedAttribute):
1291         (HTMLMarqueeElementImpl::parseMappedAttribute):
1292         * khtml/html/html_elementimpl.cpp:
1293         (HTMLElementImpl::parseMappedAttribute):
1294         (HTMLElementImpl::addHTMLAlignment):
1295         (HTMLElementImpl::setContentEditable):
1296         * khtml/html/html_formimpl.cpp:
1297         (DOM::HTMLFormElementImpl::parseMappedAttribute):
1298         (DOM::HTMLButtonElementImpl::parseMappedAttribute):
1299         (DOM::HTMLInputElementImpl::setInputType):
1300         (DOM::HTMLInputElementImpl::parseMappedAttribute):
1301         (DOM::HTMLKeygenElementImpl::appendFormData):
1302         (DOM::HTMLTextAreaElementImpl::parseMappedAttribute):
1303         * khtml/html/html_imageimpl.cpp: (DOM::HTMLAreaElementImpl::parseMappedAttribute):
1304         * khtml/html/html_inlineimpl.cpp: (DOM::HTMLBRElementImpl::parseMappedAttribute):
1305         * khtml/html/html_tableimpl.cpp: (DOM::HTMLTablePartElementImpl::parseMappedAttribute):
1306         * khtml/html/htmlparser.cpp: (HTMLParser::handleError):
1307         Use equalIgnoringCase instead of strcasecmp.
1308
1309 2005-12-30  Mitz Pettel  <opendarwin.org@mitzpettel.com>
1310
1311         Reviewed by Darin, landed by ap.
1312         
1313         Test: fast/text/justified-text-rect.html
1314         
1315         - WebCore part of fix for
1316           http://bugzilla.opendarwin.org/show_bug.cgi?id=5461
1317           Text width measured incorrectly when text-align: justify
1318
1319         * khtml/rendering/font.h:
1320         * khtml/rendering/font.cpp:
1321         (khtml::Font::selectionRectForText): Added.
1322         * khtml/rendering/render_text.cpp:
1323         (kthml::InlineTextBox::selectionRect): Use selectionRectForText. This
1324         works for justified text as well, and avoids intermediate rounding which
1325         resulted in selection rects narrower than AppKit's.
1326         (khtml::InlineTextBox::positionForOffset): Use selectionRectForText,
1327         which works for justified text as well.
1328         * kwq/KWQFontMetrics.h:
1329         * kwq/KWQFontMetrics.mm:
1330         (QFontMetrics::selectionRectForText): Added.
1331         * kwq/WebCoreTextRenderer.h:
1332
1333 2005-12-30  Alexey Proskuryakov  <ap@nypop.com>
1334
1335         - Fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6289
1336         REGRESSION: firstCharacterForRange(0, 0) returns a 0x0 rect
1337
1338         * khtml/editing/visible_text.cpp:
1339         (khtml::TextIterator::rangeFromLocationAndLength):
1340         Only special-case (0, 0) ranges for empty documents.
1341
1342 2005-12-30  Geoffrey Garen  <ggaren@apple.com>
1343
1344         Added test case for <rdar://problem/4268278> Submitting a form in onUnload event
1345         handler causes crash in -[WebDataSource(WebPrivate) _commitIfReady:]
1346
1347         * manual-tests/onunload-form-submit-crash.html: Added.
1348
1349 2005-12-30  Anders Carlsson  <andersca@mac.com>
1350
1351         Reviewed by Eric.
1352
1353         - Fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6297
1354         XMLSerializer should use createMarkup.
1355
1356         * khtml/ecma/xmlserializer.cpp:
1357         (KJS::XMLSerializerProtoFunc::callAsFunction):
1358         Use createMarkup instead of NodeImpl::toString.
1359
1360         * khtml/editing/markup.cpp:
1361         (khtml::startMarkup):
1362         escape attribute values and ignore document fragment nodes.
1363
1364 2005-12-30  Eric Seidel  <eseidel@apple.com>
1365
1366         Reviewed by mjs.
1367
1368         No functional changes, thus no layout test.
1369
1370         Just removes debug NSLog() calls from ksvg2/kcanvas.
1371         http://bugzilla.opendarwin.org/show_bug.cgi?id=6299
1372
1373         * kcanvas/device/quartz/KCanvasFilterQuartz.mm:
1374         (KCanvasFilterQuartz::prepareFilter):
1375         (KCanvasFilterQuartz::applyFilter):
1376         (KCanvasFilterQuartz::getCIFilterStack):
1377         (KCanvasFilterQuartz::imageForName):
1378         (KCanvasFEBlendQuartz::getCIFilter):
1379         (KCanvasFEColorMatrixQuartz::getCIFilter):
1380         (KCanvasFEGaussianBlurQuartz::getCIFilter):
1381         * kcanvas/device/quartz/KCanvasResourcesQuartz.mm:
1382         (KCanvasClipperQuartz::applyClip):
1383         * kcanvas/device/quartz/KRenderingDeviceQuartz.mm:
1384         (KRenderingDeviceContextQuartz::mapFromVisual):
1385         (KRenderingDeviceContextQuartz::mapToVisual):
1386         (KRenderingDeviceQuartz::createResource):
1387         (KRenderingDeviceQuartz::createFilterEffect):
1388         * kcanvas/device/quartz/KRenderingPaintServerGradientQuartz.mm:
1389         (drawShadingWithStyle):
1390         (KRenderingPaintServerGradientQuartz::updateQuartzGradientCache):
1391         * kcanvas/device/quartz/KRenderingPaintServerQuartz.mm:
1392         (KRenderingPaintServerPatternQuartz::draw):
1393         * ksvg2/svg/svgpathparser.cpp:
1394         (SVGPathParser::parseSVG):
1395
1396 2005-12-29  Graham Dennis  <Graham.Dennis@gmail.com>
1397
1398         Reviewed by Hyatt.
1399
1400         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=3579
1401           In-place style-switching is leaving junk behind, messing up styles
1402
1403         * khtml/rendering/render_block.h: (khtml::RenderBlock::initMaxMarginValues):
1404         Set all margin values in all cases.
1405
1406 2005-12-29  Eric Seidel  <eseidel@apple.com>
1407
1408         Reviewed by mjs.
1409
1410         XML documents with "html" in dtd name use XHTML entities when they shouldn't
1411         http://bugzilla.opendarwin.org/show_bug.cgi?id=6290
1412
1413         * khtml/xml/xml_tokenizer.cpp:
1414         (khtml::externalSubsetHandler): check for exact xhtml types
1415
1416 2005-12-29  Eric Seidel  <eseidel@apple.com>
1417
1418         Reviewed by mjs.
1419
1420         Close leak in CollectionInfo due to HashMap migration
1421         http://bugzilla.opendarwin.org/show_bug.cgi?id=6295
1422
1423         * khtml/html/html_miscimpl.cpp:
1424         (DOM::HTMLCollectionImpl::CollectionInfo::~CollectionInfo):
1425         * khtml/html/html_miscimpl.h:
1426
1427 2005-12-29  Maciej Stachowiak  <mjs@apple.com>
1428
1429         Reviewed by Eric.
1430
1431         - finished frame traversal cleanup
1432         http://bugzilla.opendarwin.org/show_bug.cgi?id=6293
1433         
1434         * kwq/WebCoreBridge.h: Removed childFrames method from WebCoreBridge protocol
1435         since it is not actually used.
1436
1437 2005-12-29  Eric Seidel  <eseidel@apple.com>
1438
1439         Reviewed by mjs.
1440
1441         Leaks in XSLTProcessorImpl due to early exit in failure case
1442         http://bugzilla.opendarwin.org/show_bug.cgi?id=6101
1443
1444         * khtml/xsl/xslt_processorimpl.cpp:
1445         (DOM::xmlDocPtrFromNode): add "shouldDelete" argument
1446         (DOM::XSLTProcessorImpl::transformToString): delete new'd xmlDoc
1447
1448 2005-12-29  Eric Seidel  <eseidel@apple.com>
1449
1450         File accidentally omitted from previous commit.
1451
1452         Remove QDict from khtml/html
1453         http://bugzilla.opendarwin.org/show_bug.cgi?id=6230
1454
1455         * khtml/ecma/kjs_html.cpp:
1456         (KJS::KJS::HTMLCollection::getNamedItems):
1457
1458 2005-12-29  Eric Seidel  <eseidel@apple.com>
1459
1460         Reviewed by mjs.
1461
1462         Remove QDict from khtml/html
1463         http://bugzilla.opendarwin.org/show_bug.cgi?id=6230
1464         Uses HashMap instead.
1465
1466         * khtml/html/html_miscimpl.cpp:
1467         (DOM::HTMLCollectionImpl::CollectionInfo::CollectionInfo):
1468         (DOM::HTMLCollectionImpl::CollectionInfo::reset):
1469         (DOM::HTMLCollectionImpl::namedItem):
1470         (DOM::HTMLCollectionImpl::updateNameCache):
1471         (DOM::HTMLCollectionImpl::namedItems):
1472         (DOM::HTMLCollectionImpl::nextNamedItem):
1473         (DOM::HTMLFormCollectionImpl::nextNamedItemInternal):
1474         (DOM::HTMLFormCollectionImpl::updateNameCache):
1475         * khtml/html/html_miscimpl.h:
1476
1477 2005-12-29  Eric Seidel  <eseidel@apple.com>
1478
1479         Reviewed by mjs.
1480
1481         DOMString/DOMStringImpl/AtomicString need enhancements before replacing QString
1482         http://bugzilla.opendarwin.org/show_bug.cgi?id=6228
1483         Added find(), contains(), startsWith() and endsWith() to DOMString
1484         Uses the above functions throughout the code.
1485         Small performance boost.
1486
1487         * khtml/css/css_base.cpp:
1488         (CSSSelector::print):
1489         * khtml/css/css_ruleimpl.cpp:
1490         (DOM::CSSImportRuleImpl::init):
1491         * khtml/css/css_valueimpl.cpp:
1492         (DOM::CSSStyleDeclarationImpl::setProperty):
1493         * khtml/css/cssparser.cpp:
1494         (CSSParser::parseValue):
1495         (CSSParser::parseDeclaration):
1496         (CSSParser::parseContent):
1497         * khtml/css/cssstyleselector.cpp:
1498         (khtml::CSSStyleSelector::CSSStyleSelector):
1499         (khtml::CSSStyleSelector::setEncodedURL):
1500         (khtml::parseUASheet):
1501         (khtml::cleanpath):
1502         (khtml::CSSStyleSelector::checkSelector):
1503         (khtml::CSSStyleSelector::checkOneSelector):
1504         (khtml::CSSRuleSet::addRulesFromSheet):
1505         (khtml::CSSStyleSelector::applyProperty):
1506         * khtml/dom/dom_string.cpp:
1507         * khtml/dom/dom_string.h:
1508         (DOM::DOMString::contains):
1509         (DOM::DOMString::find):
1510         (DOM::DOMString::startsWith):
1511         (DOM::DOMString::endsWith):
1512         * khtml/html/html_formimpl.cpp:
1513         (DOM::HTMLFormElementImpl::parseEnctype):
1514         * khtml/khtml_part.cpp:
1515         (KHTMLPart::requestFrame):
1516         (KHTMLPart::submitForm):
1517         * khtml/misc/decoder.cpp:
1518         (Decoder::decode):
1519         * khtml/xml/dom_atomicstring.h:
1520         (DOM::AtomicString::length):
1521         (DOM::AtomicString::operator []):
1522         (DOM::AtomicString::contains):
1523         (DOM::AtomicString::find):
1524         (DOM::AtomicString::startsWith):
1525         (DOM::AtomicString::endsWith):
1526         * khtml/xml/dom_docimpl.cpp:
1527         (DocumentImpl::processHttpEquiv):
1528         * khtml/xml/dom_stringimpl.cpp:
1529         (DOM::equal):
1530         (DOM::equalCaseInsensitive):
1531         (DOM::DOMStringImpl::find):
1532         (DOM::DOMStringImpl::endsWith):
1533         * khtml/xml/dom_stringimpl.h:
1534         (DOM::DOMStringImpl::startsWith):
1535
1536 2005-12-29  Rob Buis  <rwlbuis@xs4all.nl>
1537
1538         Reviewed by eseidel.
1539
1540         WebCore+SVG has some problems with rounded rectangles
1541         http://bugzilla.opendarwin.org/show_bug.cgi?id=6157
1542
1543         * ksvg2/svg/SVGRectElementImpl.cpp:
1544         (SVGRectElementImpl::toPathData): fixed round rect calculations
1545
1546 2005-12-29  Mark Rowe  <opendarwin.org@bdash.net.nz>
1547
1548         Reviewed by eseidel, ggaren, darin.
1549         
1550         - http://bugzilla.opendarwin.org/show_bug.cgi?id=4301
1551         Support HTML entities on pages parsed as XHTML
1552
1553         Added layout tests:
1554         * fast/parser/entities-in-xhtml.xhtml
1555
1556         * khtml/xml/xml_tokenizer.cpp:
1557         (khtml::XMLTokenizer::setIsXHTMLDocument): Track whether the XML document is XHTML.
1558         (khtml::XMLTokenizer::isXHTMLDocument): Ditto.
1559         (khtml::externalSubsetHandler): Ditto.
1560         (khtml::XMLTokenizer::finish): Ditto.
1561         (khtml::getXHTMLEntity): Look up the HTML entity.
1562         (khtml::getEntityHandler): Look up the HTML entity if this is an XHTML document.
1563         * khtml/html/kentities.h: Added.
1564         * khtml/html/kentities.gperf: changed entity to Entity
1565
1566 2005-12-29  Mitz Pettel  <opendarwin.org@mitzpettel.com>
1567
1568         Reviewed by darin
1569
1570         - WebCore part of fix for
1571           http://bugzilla.opendarwin.org/show_bug.cgi?id=3922
1572           Variable word/letter spacing and full justification not supported for
1573           ATSUI-rendered text
1574
1575         * khtml/rendering/font.h:
1576         (khtml::Font::checkSelectionPoint): Make sure the complete run, used for
1577         counting spaces and determining padding per space does not go beyond the
1578         text box.
1579
1580 2005-12-28  Geoffrey Garen  <ggaren@apple.com>
1581
1582         Reviewed by mjs.
1583
1584         - Fixed <rdar://problem/4325722> crash in KJS::Bindings::dispatchJNICall
1585         due to liveconnect call from Java after Java PlugInView has been 
1586         deallocated @ www.binarybet.com
1587         AKA
1588         http://bugzilla.opendarwin.org/show_bug.cgi?id=5518
1589
1590         We had code that checked for whether a call came from a live PlugIn,
1591         but the live PlugIn dictionary would only get cleared when the 
1592         KWQKHTMLPart was destroyed. Since a single part can service multiple
1593         loads, the dictionary needs to clear after each one.
1594
1595         No layout test because this bug is difficult to reproduce.
1596
1597         * kwq/KWQKHTMLPart.mm:
1598         (KWQKHTMLPart::~KWQKHTMLPart):
1599         (1) Unrelated cleanup: Removed manual clearing of form values,
1600         replaced with call to clearRecordedFormValues().
1601         (2) Replaced PlugIn dictionary cleanup code and view deref call
1602         with call to setView(0), since much of this code was duplicated in
1603         setView, and the stuff that wasn't duplicated needed to be.
1604
1605         (KWQKHTMLPart::setView):
1606         (1) Removed some unnecessary braces.
1607         (2) Added PlugIn dictionary cleanup code.
1608         (3) New behavior: clear _bindingRoot and _windowScriptObject after
1609         each view change. This is needed because after a call to
1610         clenaupPluginRootObjects(), both objects have stale references.
1611         (4) Changed a NULL to a 0.
1612
1613         (KWQKHTMLPart::cleanupPluginRootObjects): Removed extra space.
1614
1615 2005-12-28  Anders Carlsson  <andersca@mac.com>
1616
1617         Reviewed by Maciej.
1618
1619         - Fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6268
1620         Add undetectable document.all
1621         
1622         * khtml/ecma/kjs_html.cpp:
1623         (KJS::HTMLDocument::getValueProperty):
1624         If "all" has been set to a new value, return the new value.
1625         
1626         (KJS::KJS::HTMLDocument::putValueProperty):
1627         Allow "all" to be set to a new value.
1628         
1629         (KJS::HTMLAllCollection::toPrimitive):
1630         Return jsNull() if the preferred type is NullType.
1631         
1632         (KJS::getAllHTMLCollection):
1633         * khtml/ecma/kjs_html.h:
1634         (KJS::HTMLAllCollection::HTMLAllCollection):
1635         Add HTMLAllCollection, a subclass of HTMLCollection which should
1636         be undetectable.
1637         
1638         (KJS::HTMLAllCollection::toBoolean):
1639         Return false.
1640
1641 2005-12-28  Mitz Pettel  <opendarwin.org@mitzpettel.com>
1642
1643         Reviewed by Eric, landed by ap.
1644         
1645         Test: fast/block/basic/text-indent-rtl.html
1646
1647         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6214
1648           text-indent in RTL block does the opposite
1649
1650         * khtml/rendering/render_block.cpp:
1651         (khtml::RenderBlock::rightRelOffset): Subtract the indent instead of adding it.
1652
1653 2005-12-28  Mitz Pettel  <opendarwin.org@mitzpettel.com>
1654
1655         Reviewed by Darin, landed by ap.
1656
1657         Test: fast/dom/HTMLScriptElement/script-load-events.html
1658
1659         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=5812
1660           Generate load events for <script> elements
1661
1662         * khtml/html/html_headimpl.cpp:
1663         (HTMLScriptElementImpl::parseMappedAttribute): Parse the onload and onerror attributes.
1664         (HTMLScriptElementImpl::closeRenderer): Call base class's implementation.
1665         (HTMLScriptElementImpl::notifyFinished): Dispatch load and error events.
1666         * khtml/html/htmlparser.h:
1667         * khtml/html/htmlparser.cpp:
1668         (HTMLParser::parseToken): Return the node that was inserted.
1669         * khtml/html/htmltokenizer.h: Added scriptNode, a RefPtr to the node corresponding
1670         to the current load request.
1671         * khtml/html/htmltokenizer.cpp:
1672         (HTMLTokenizer::scriptHandler): Reset scriptNode if a load request was not made.
1673         (HTMLTokenizer::parseTag): Set scriptNode to the node created from the script tag.
1674         (HTMLTokenizer::processToken): Return the node that was inserted.
1675         (HTMLTokenizer::notifyFinished): Reset scriptNode and dispatch load and error events.
1676         * khtml/misc/loader.h:
1677         (CachedScript::errorOccurred): Added.
1678         * khtml/misc/loader.cpp:
1679         (CachedScript::CachedScript):
1680         (CachedScript::error):
1681
1682 2005-12-28  Alexey Proskuryakov  <ap@nypop.com>
1683
1684         Reviewed by Maciej.
1685
1686         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6246
1687           TextIterator::rangeFromLocationAndLength() returns nil range for an 
1688           empty document
1689
1690         Test: editing/input/range-for-empty-document.html
1691
1692         * khtml/editing/visible_text.cpp:
1693         (khtml::TextIterator::rangeFromLocationAndLength):
1694         Handle the case of an empty document and (0, 0) requested range.
1695
1696 2005-12-28  Anders Carlsson  <andersca@mac.com>
1697
1698         Reviewed and landed by Geoff.
1699
1700         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6269
1701         ToT memory corruption
1702         
1703         * khtml/rendering/render_text.cpp:
1704         (khtml::RenderText::setText):
1705         Remove deref().
1706         
1707 2005-12-27  Mitz Pettel  <opendarwin.org@mitzpettel.com>
1708
1709         Reviewed by Hyatt, landed by Darin.
1710         
1711         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=5699
1712           REGRESSION: incomplete repaint
1713
1714         * khtml/rendering/render_object.cpp:
1715         (RenderObject::repaintAfterLayoutIfNeeded): Return false if only the
1716         size changed and not everything was repainted.
1717         * manual-tests/bugzilla-5699.html: Added.
1718
1719 2005-12-27  Sam Weinig  <sam.weinig@gmail.com>
1720
1721         Reviewed by Maciej, landed by Darin.
1722
1723         - fixed <http://bugzilla.opendarwin.org/show_bug.cgi?id=4101>
1724         CSS Fibonacci spiral using 4 images doesn't render correctly
1725
1726         Added layout tests:
1727         * fast/replaced/absolute-image-sizing.html
1728
1729         * khtml/rendering/render_box.cpp:
1730         (RenderBox::calcAbsoluteHorizontalValues): Use calcReplacedWidth() instead of intrinsicWidth()
1731         for replaced elements.
1732         (RenderBox::calcAbsoluteVerticalValues): Same thing for height.
1733
1734 2005-12-27  Darin Adler  <darin@apple.com>
1735
1736         Reviewed by Geoff and Eric.
1737
1738         - http://bugzilla.opendarwin.org/show_bug.cgi?id=6198
1739           use RefPtr a few places in RenderText and related classes
1740
1741         * khtml/html/htmltokenizer.h: Use RefPtr for some data members in Token.
1742         Also removed use of bitfields in Token, since there's no need to optimize storage here.
1743         * khtml/html/htmlparser.cpp:
1744         (HTMLParser::parseToken): Update for use of RefPtr in Token.
1745         (HTMLParser::textCreateErrorCheck): Ditto.
1746         (HTMLParser::commentCreateErrorCheck): Ditto.
1747         (HTMLParser::handleIsindex): Ditto.
1748         * khtml/html/htmltokenizer.cpp:
1749         (khtml::Token::addAttribute): Ditto.
1750         (khtml::HTMLTokenizer::processToken): Ditto.
1751
1752         * khtml/rendering/render_text.h: Reduce the number of includes, change
1753         SOFT_HYPHEN from a macro into a constant. Change originalString function
1754         to return a PassRefPtr instead of a RefPtr. Make str and m_generatedContentStr
1755         member be a RefPtr.
1756         * khtml/rendering/render_text.cpp:
1757         (khtml::RenderText::previousOffset): Update for use of RefPtr for str.
1758         (khtml::RenderText::nextOffset): Ditto.
1759         (khtml::RenderText::RenderText): Ditto.
1760         (khtml::RenderText::originalString): Change to return PassRefPtr, even though
1761         it's not necessary at this level (since it's a virtual function).
1762         (khtml::RenderText::posOfChar): Update for use of RefPtr for str.
1763         (khtml::RenderText::setText): Ditto.
1764         (khtml::RenderTextFragment::RenderTextFragment): Ditto.
1765         (khtml::RenderTextFragment::originalString): Change to return PassRefPtr.
1766
1767         * khtml/html/html_inlineimpl.cpp: Re-sorted list of includes, added newly-needed ones.
1768         * kwq/KWQRenderTreeDebug.cpp: Added new include needed since QPtrVector is no longer
1769         included by render_text.h.
1770
1771 2005-12-27  Darin Adler  <darin@apple.com>
1772
1773         Fix suggested by Mitz.
1774
1775         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6240
1776           REGRESSION: scrollbars in overflows don't work
1777
1778         * khtml/xml/dom2_eventsimpl.cpp: (DOM::MouseRelatedEventImpl::computePositions):
1779         Remove the code to compute pageX/Y from clientX/Y, because clientX/Y are not passed
1780         in correctly (in fact, what's passed in is pageX/Y)! I accidentally included part
1781         of my fix for clientX/Y in the original patch.
1782
1783 2005-12-27  Maks Orlovich <maksim@kde.org>
1784
1785         Reviewed and landed by Maciej.
1786
1787         - fixed 4405: <button> not listed in form collections.
1788         http://bugzilla.opendarwin.org/show_bug.cgi?id=4405
1789
1790         Test: fast/forms/button-in-forms-collection.html
1791
1792         * khtml/html/html_formimpl.h:
1793         (DOM::HTMLButtonElementImpl::isEnumeratable): override to return true
1794
1795 2005-12-25  Maciej Stachowiak  <mjs@apple.com>
1796
1797         Reviewed by Geoff.
1798
1799         - Remove WebFrame's parent frame pointer, instead rely on WebCore's parent concept
1800         http://bugzilla.opendarwin.org/show_bug.cgi?id=6241
1801
1802         * kwq/WebCoreBridge.h:
1803         * kwq/WebCoreBridge.mm:
1804         (-[WebCoreBridge parent]): New method, relies on the KHTMLPart's
1805         parent pointer.
1806
1807 2005-12-24  Mitz Pettel  <opendarwin.org@mitzpettel.com>
1808
1809         Reviewed by eseidel.
1810         
1811         Test: fast/forms/domstring-replace-crash.html
1812
1813         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6236
1814           REGRESSION: Crash in DOMString::replace() in ToT (12/24/05)
1815
1816         * khtml/dom/dom_string.h:
1817         (DOMString::replace): Added check for null m_impl.
1818
1819 2005-12-24  Maciej Stachowiak  <mjs@apple.com>
1820
1821         Reviewed by Eric.
1822
1823         - replaced QPtrDict for Accessors structs with HashMap (also renamed some
1824         stray getSetInfo methods)
1825         http://bugzilla.opendarwin.org/show_bug.cgi?id=6223
1826
1827         * khtml/ecma/kjs_html.cpp:
1828         (KJS::HTMLElement::accessors):
1829         (KJS::HTMLElement::getValueProperty):
1830         (KJS::HTMLElement::putValueProperty):
1831         * khtml/ecma/kjs_html.h:
1832
1833 2005-12-24  Geoffrey Garen  <ggaren@apple.com>
1834
1835         Reviewed by eric.
1836
1837         http://bugzilla.opendarwin.org/show_bug.cgi?id=6231
1838
1839         - Fixed assertion failure in QString::mid caused by my last checkin. 
1840         parseWindowFeatures() sometimes called QString::mid() with a start 
1841         index past the end of the string but a length of 0. There were two 
1842         problems there. (1) parseWindowFeatures() shouldn't have gotten past 
1843         the end of the string. (2) QString had range truncating code that was 
1844         borked. So I fixed both.
1845
1846         * khtml/ecma/kjs_window.cpp:
1847         (KJS::parseWindowFeatures): One of the "past the end" tests was > 
1848         instead of >=.
1849         * kwq/KWQString.mm:
1850         (QString::mid): Truncate length *before* deciding whether to return 
1851         early. Also, compare start and data._length before computing 
1852         data._length - start, because the error case we're trying to catch 
1853         will almost certainly cause unsigned overflow.
1854         * manual-tests/window-open-features-parsing.html: Added trailing ',' 
1855         to uber-test to catch this failure, too.
1856
1857 2005-12-24  Mitz Pettel  <opendarwin.org@mitzpettel.com>
1858
1859         Reviewed by Maciej.
1860
1861         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6221
1862           REGRESSION: Password field is blank error for secure websites using
1863           password field (ToT, 12/24/05)
1864
1865         * khtml/kwq/KWQSlot.mm:
1866         (KWQSlot::KWQSlot): Changed the parameter type of slotTextChanged to const DOMString &
1867         * khtml/rendering/render_form.h:
1868         * khtml/rendering/render_form.cpp:
1869         (RenderLineEdit::RenderLineEdit): ditto.
1870         (RenderLineEdit::slotTextChanged): ditto.
1871         (RenderFileButton::RenderFileButton): ditto.
1872         (RenderFileButton::slotTextChanged): ditto.
1873
1874 2005-12-22  Geoffrey Garen  <ggaren@apple.com>
1875     
1876         Reviewed by vicki (yay!), eric.
1877
1878         - Fixed: <rdar://problem/4377597> parsing of window.open features strings needs to be more forgiving
1879
1880         Manual test case: WebCore/manual-tests/window-open-features-parsing.html
1881         Also fixed: WebCore/manual-tests/window-open-features.html, which had an incorrect URL in it.
1882
1883         This patch is long. Luckily, it's also complicated.
1884
1885         The main thing I've done is to change our parsing of the window.open 'features' argument to match Win IE.
1886         This is important because we now implement the correct defaults for window.open, and resizing and
1887         scrolling are turned off by default. So, if we parse the 'features' string incorrectly, we'll end
1888         up with an annoying, incorrectly sized window that can't resize or scroll.
1889
1890         To honor a long-standing request by Eric, I factored out the parsing into two new functions:
1891         parseWindowFeatures and constrainToScreen. I also added support for "innerWidth" and "innerHeight,"
1892         since they're just synonyms for "width" and "height."
1893
1894         * khtml/ecma/kjs_window.cpp: removed "emit" statements, since emit is #defined as ""
1895         (KJS::parseDialogFeatures): renamed from parseFeatures, since we now have a 'parseWindowFeatures'.
1896         (KJS::showModalDialog): ditto on parseFeatures. Also added some missing initializations for WindowArgs data members.
1897         (KJS::parseWindowFeatures): new function, all new functionality.
1898         (KJS::constrainToScreen): new function, no new functionality -- just cut and pasted code that used to run as
1899         part of our parsing routine.
1900         (KJS::WindowFunc::callAsFunction):
1901         (1) Factored out previous parsing code.
1902         (2) Factored 17 lines of custom popup-blocking code into 3 lines that use pre-existing 'allowPopUp' function.
1903             Gratuitous, but it cried out to me.
1904         (3) Changed URL parsing to substitute "" for undefined *and* null values (we already did this for undefined),
1905             to avoid trying to navigate to 'http://null'.
1906         (4) Factore a multiline if () { if () {}} into an if ( && )
1907         (4) Removed the main body of code from a giant 'else' block by inserting early returns for the exceptional cases.
1908             This caused some things to show up in the diff even though they're just whitespace changes.
1909             I didn't actually change any code past the line "if (!str.isEmpty() && activePart)"
1910         * kwq/KWQKHTMLPartBrowserExtension.mm:
1911         (KHTMLPartBrowserExtension::createNewWindow): Added code to set toolbars to visible if toolBarVisible is true *or*
1912         locationBarVisible is true. The parser used to do this for us, but it's really the browser that's responsible for
1913         saying that the toolbar and the locationbar are the same thing. Hopefully, we can add a setLocationBarVisible delegate
1914         in the future so that other webkit clients can make their own UI decisions.
1915         * kwq/KWQKPartsBrowserExtension.h: Added locationBarVisible data member to WindowArgs structure and renamed
1916         toolBarsVisible to toolBarVisible (see above). Removed initialization code from WindowArgs structure because
1917         this file is for platform-specific code, and what defaults to use for window arguments is purely engine stuff.
1918
1919 2005-12-23  Eric Seidel  <eseidel@apple.com>
1920
1921         Reviewed by mjs.
1922
1923         Remove many use of .qstring()
1924         Convert several instances of QStrings to DOMStrings
1925         Add DOMString::replace(QChar, QChar)
1926         Remove (unused) KWQLabel, KWQKGlobal
1927         Slight performance improvement.
1928         Also fixed ChangeLog line endings from previous commit.
1929         http://bugzilla.opendarwin.org/show_bug.cgi?id=6138
1930
1931         No tests needed, no functionality changes.
1932
1933         * ChangeLog: Fixed line endings
1934         * ForwardingHeaders/kglobal.h: Removed.
1935         * ForwardingHeaders/qlabel.h: Removed.
1936         * WebCore.xcodeproj/project.pbxproj: removed KWQLabel
1937         * khtml/css/css_base.cpp:
1938         (CSSSelector::selectorText):
1939         * khtml/css/css_stylesheetimpl.cpp:
1940         (MediaListImpl::setMediaText):
1941         * khtml/css/cssstyleselector.cpp:
1942         (khtml::checkPseudoState):
1943         * khtml/dom/dom_string.h:
1944         (DOM::DOMString::replace):
1945         * khtml/ecma/kjs_css.cpp:
1946         (KJS::DOMCSSStyleDeclaration::put):
1947         * khtml/ecma/kjs_dom.cpp:
1948         (KJS::DOMNode::put):
1949         (KJS::DOMAttr::put):
1950         (KJS::DOMDocument::put):
1951         * khtml/ecma/kjs_events.cpp:
1952         (KJS::JSAbstractEventListener::handleEvent):
1953         * khtml/ecma/kjs_html.cpp:
1954         (KJS::KJS::HTMLDocument::put):
1955         (KJS::KJS::HTMLElementFunction::callAsFunction):
1956         (KJS::KJS::HTMLElement::put):
1957         (KJS::KJS::Context2DFunction::callAsFunction):
1958         (KJS::Context2D::putValueProperty):
1959         * khtml/ecma/kjs_proxy.cpp:
1960         (KJSProxyImpl::evaluate):
1961         * khtml/ecma/kjs_window.cpp:
1962         (KJS::Window::isSafeScript):
1963         (KJS::WindowFunc::callAsFunction):
1964         (KJS::ScheduledAction::execute):
1965         * khtml/ecma/xmlhttprequest.cpp:
1966         (KJS::XMLHttpRequest::send):
1967         (KJS::XMLHttpRequestProtoFunc::callAsFunction):
1968         * khtml/ecma/xmlhttprequest.h:
1969         * khtml/editing/jsediting.cpp:
1970         (DOM::JSEditor::queryCommandSupported):
1971         * khtml/editing/markup.cpp:
1972         (khtml::stringValueForRange):
1973         (khtml::startMarkup):
1974         * khtml/html/html_baseimpl.cpp:
1975         (HTMLBodyElementImpl::parseMappedAttribute):
1976         * khtml/html/html_elementimpl.cpp:
1977         (HTMLElementImpl::addHTMLAlignment):
1978         * khtml/html/html_formimpl.cpp:
1979         (DOM::HTMLFormElementImpl::formData):
1980         (DOM::HTMLInputElementImpl::appendFormData):
1981         (DOM::HTMLTextAreaElementImpl::updateValue):
1982         * khtml/html/html_headimpl.cpp:
1983         (HTMLLinkElementImpl::parseMappedAttribute):
1984         * khtml/html/html_imageimpl.cpp:
1985         (DOM::HTMLImageElementImpl::parseMappedAttribute):
1986         * khtml/html/html_objectimpl.cpp:
1987         (DOM::HTMLObjectElementImpl::parseMappedAttribute):
1988         (DOM::HTMLParamElementImpl::isURLAttribute):
1989         * khtml/html/html_objectimpl.h:
1990         * khtml/html/html_tableimpl.cpp:
1991         (DOM::HTMLTableElementImpl::addChild):
1992         (DOM::HTMLTableElementImpl::parseMappedAttribute):
1993         (DOM::HTMLTablePartElementImpl::parseMappedAttribute):
1994         (DOM::HTMLTableSectionElementImpl::addChild):
1995         (DOM::HTMLTableRowElementImpl::addChild):
1996         * khtml/html/htmltokenizer.cpp:
1997         (khtml::HTMLTokenizer::parseTag):
1998         * khtml/khtml_part.cpp:
1999         (KHTMLPart::executeScript):
2000         (KHTMLPart::checkEmitLoadEvent):
2001         * khtml/misc/loader.cpp:
2002         (CachedObject::finish):
2003         (CachedCSSStyleSheet::checkNotify):
2004         (CachedXSLStyleSheet::checkNotify):
2005         (CachedXBLDocument::checkNotify):
2006         (DocLoader::requestImage):
2007         (DocLoader::requestStyleSheet):
2008         (DocLoader::requestScript):
2009         (Loader::servePendingRequests):
2010         (Loader::cancelRequests):
2011         * khtml/rendering/render_applet.cpp:
2012         * khtml/rendering/render_block.cpp:
2013         (khtml::RenderBlock::updateFirstLetter):
2014         * khtml/rendering/render_box.cpp:
2015         (RenderBox::~RenderBox):
2016         * khtml/rendering/render_form.cpp:
2017         (RenderFormElement::slotTextChanged):
2018         (RenderLineEdit::updateFromElement):
2019         (RenderTextArea::updateFromElement):
2020         (RenderTextArea::text):
2021         * khtml/rendering/render_form.h:
2022         * khtml/rendering/render_frames.cpp:
2023         (RenderPartObject::updateWidget):
2024         * khtml/rendering/render_line.cpp:
2025         (khtml::EllipsisBox::paint):
2026         * khtml/rendering/render_list.cpp:
2027         (RenderListItem::paint):
2028         (RenderListMarker::paint):
2029         * khtml/rendering/render_text.cpp:
2030         (khtml::RenderText::RenderText):
2031         (khtml::RenderText::position):
2032         * khtml/xml/dom_docimpl.cpp:
2033         (DOMImplementationImpl::hasFeature):
2034         (DocumentImpl::getElementByAccessKey):
2035         (DocumentImpl::recalcStyleSelector):
2036         (DocumentImpl::defaultEventHandler):
2037         * khtml/xml/dom_elementimpl.cpp:
2038         (ElementImpl::recalcStyle):
2039         * khtml/xml/dom_nodeimpl.cpp:
2040         (DOM::NodeImpl::dump):
2041         (DOM::appendAttributeDesc):
2042         (DOM::NodeImpl::showNode):
2043         * khtml/xml/dom_stringimpl.cpp:
2044         (DOM::DOMStringImpl::lower):
2045         * khtml/xml/xml_tokenizer.cpp:
2046         (khtml::XMLTokenizer::executeScripts):
2047         * khtml/xsl/xsl_stylesheetimpl.cpp:
2048         (DOM::XSLStyleSheetImpl::loadChildSheets):
2049         * kwq/KWQKHTMLPart.h:
2050         * kwq/KWQKHTMLPart.mm:
2051         (KWQKHTMLPart::documentViewForNode):
2052         (KWQKHTMLPart::runJavaScriptAlert):
2053         (KWQKHTMLPart::runJavaScriptConfirm):
2054         (KWQKHTMLPart::runJavaScriptPrompt):
2055         (KWQKHTMLPart::addMessageToConsole):
2056         (KWQKHTMLPart::passWheelEventToChildWidget):
2057         (KWQKHTMLPart::shouldDragAutoNode):
2058         (KWQKHTMLPart::snapshotDragImage):
2059         (convertAttributesToUnderlines):
2060         (KWQKHTMLPart::setMarkedTextRange):
2061         (KWQKHTMLPart::mousePressNode):
2062         * kwq/KWQKGlobal.h: Removed.
2063         * kwq/KWQKGlobal.mm: Removed.
2064         * kwq/KWQLabel.h: Removed.
2065         * kwq/KWQLabel.mm: Removed.
2066         * kwq/KWQLineEdit.h:
2067         * kwq/KWQLineEdit.mm:
2068         (QLineEdit::setText):
2069         (QLineEdit::text):
2070         (QLineEdit::setAutoSaveName):
2071         (QLineEdit::setPlaceholderString):
2072         * kwq/KWQPainter.mm:
2073         (QPainter::compositeOperatorFromString):
2074         * kwq/KWQSignal.h:
2075         * kwq/KWQSignal.mm:
2076         (KWQSignal::call):
2077         * kwq/KWQSlot.h:
2078         * kwq/KWQSlot.mm:
2079         (KWQSlot::call):
2080         * kwq/KWQString.h:
2081         * kwq/KWQString.mm:
2082         * kwq/KWQTextEdit.h:
2083         * kwq/KWQTextEdit.mm:
2084         (QTextEdit::setText):
2085         (QTextEdit::text):
2086         (QTextEdit::textWithHardLineBreaks):
2087         * ksvg2/scripts/cssmakeprops: removed kglobal.h
2088         * ksvg2/scripts/cssmakevalues: removed kglobal.h
2089
2090 2005-12-23  Alexey Proskuryakov  <ap@nypop.com>
2091
2092         Reviewed by Eric Seidel.
2093
2094         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=5924
2095           Zero-length responses to XMLHTTPRequest mishandled
2096
2097         * khtml/ecma/xmlhttprequest.cpp (KJS::XMLHttpRequest::slotFinished):
2098           Make sure to fetch response headers and set the state to Loaded, if
2099           this hasn't been done already.
2100
2101 2005-12-23  Alexey Proskuryakov  <ap@nypop.com>
2102
2103         Reviewed by Eric Seidel.
2104
2105         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=3565
2106           Posting data via XML HTTP Request doesnt work
2107
2108         * khtml/ecma/xmlhttprequest.cpp:
2109         (KJS::XMLHttpRequest::send): Set application/xml as a default Content-Type;
2110           use a proper codec for request body if a charset is specified.
2111         (KJS::XMLHttpRequest::getRequestHeader): Use getSpecificHeader.
2112         (KJS::XMLHttpRequest::getResponseHeader): Ditto.
2113         (KJS::XMLHttpRequest::getSpecificHeader): Factored out code from getResponseHeader.
2114         (KJS::XMLHttpRequestProtoFunc::callAsFunction): Removed a FIXME (this is done in send() now).
2115         * khtml/ecma/xmlhttprequest.h:
2116
2117 2005-12-22  Alexey Proskuryakov  <ap@nypop.com>
2118
2119         Reviewed by Darin Adler.
2120
2121         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6118
2122         Investigate not using the frameset charset as a default for frames
2123
2124         * khtml/khtml_part.cpp (KHTMLPart::write):
2125         Do not use the parent frame encoding as a default for sub-frames (revert
2126         rdar://3100151). 
2127
2128 2005-12-22  Maciej Stachowiak  <mjs@apple.com>
2129
2130         Reviewed by Eric.
2131
2132         - made RefPtr<DOMStringImpl> usable as a hashtable key/value
2133         - changed XSLTProcessorImpl to make use of this instead of a QDict.
2134         - partially fixed broken param handling for xslt
2135
2136         See LayoutTests for updated test case.
2137
2138         * khtml/xml/dom_stringimpl.cpp:
2139         * khtml/xml/dom_stringimpl.h:
2140         (KXMLCore::): Set things up so you can use RefPtr<DOMStringImpl> as
2141         a hashtable key (should already be usable as a value).
2142         * khtml/xsl/xslt_processorimpl.cpp:
2143         (DOM::xsltParamArrayFromParameterMap): Updated to use a HashMap of RefPtrs instead
2144         of QDict. Also, fixed bugs that would have kept this from ever working at all.
2145         (DOM::XSLTProcessorImpl::transformToString): ditto
2146         (DOM::XSLTProcessorImpl::setParameter): ditto
2147         (DOM::XSLTProcessorImpl::getParameter): ditto
2148         (DOM::XSLTProcessorImpl::removeParameter): ditto
2149         * khtml/xsl/xslt_processorimpl.h:
2150
2151 2005-12-21  Maciej Stachowiak  <mjs@apple.com>
2152
2153         Reviewed by Darin.
2154
2155         - update for new HashTranslator stuff
2156
2157         * khtml/xml/dom_atomicstring.cpp:
2158         (DOM::CStringTranslator::hash):
2159         (DOM::CStringTranslator::equal):
2160         (DOM::CStringTranslator::translate):
2161         (DOM::AtomicString::equal):
2162         (DOM::AtomicString::add):
2163         (DOM::QCharBufferTranslator::hash):
2164         (DOM::QCharBufferTranslator::equal):
2165         (DOM::QCharBufferTranslator::translate):
2166         * khtml/xml/dom_qname.cpp:
2167         (DOM::QNameComponentsTranslator::hash):
2168         (DOM::QNameComponentsTranslator::equal):
2169         (DOM::QNameComponentsTranslator::translate):
2170         (DOM::QualifiedName::QualifiedName):
2171
2172 2005-12-22  Adele Peterson  <adele@apple.com>
2173
2174         Reviewed by Darin.
2175
2176         Cleaned up a previous checkin by defining global const defaultForm.
2177
2178         * khtml/xml/dom_docimpl.cpp:
2179         (DocumentImpl::radioButtonChecked):
2180         (DocumentImpl::checkedRadioButtonForGroup):
2181         (DocumentImpl::removeRadioButtonGroup):
2182
2183 2005-12-22  Adele Peterson  <adele@apple.com>
2184
2185         Reviewed by Tim Hatcher.
2186
2187         Fixed <rdar://problem/4387433> Seed: Radio buttons behave incorrectly in Gmail settings
2188
2189         * khtml/html/html_formimpl.cpp:
2190         (DOM::HTMLFormElementImpl::registerFormElement): update radio button hash map when moving form elements around.
2191         (DOM::HTMLGenericFormElementImpl::insertedIntoTree): ditto.
2192         * khtml/html/html_formimpl.h:
2193         (DOM::HTMLGenericFormElementImpl::isRadioButton): Added.
2194         (DOM::HTMLInputElementImpl::isRadioButton): Added.
2195         * khtml/xml/dom_docimpl.cpp:
2196         (DocumentImpl::radioButtonChecked): 
2197         Added comment explaining that we use 1 for the default form.  We can't use a null pointer as a key for the hash map.
2198         (DocumentImpl::checkedRadioButtonForGroup): Added conversion of null form pointer to 1.
2199         (DocumentImpl::removeRadioButtonGroup): ditto.
2200
2201 2005-12-22  Anders Carlsson  <andersca@mac.com>
2202
2203         Reviewed by Eric.
2204
2205         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6196
2206         Would like to be able to define prototypes in headers
2207
2208         * khtml/ecma/XSLTProcessor.cpp:
2209         * khtml/ecma/domparser.cpp:
2210         * khtml/ecma/kjs_css.cpp:
2211         * khtml/ecma/kjs_dom.cpp:
2212         * khtml/ecma/kjs_events.cpp:
2213         * khtml/ecma/kjs_html.cpp:
2214         * khtml/ecma/kjs_range.cpp:
2215         * khtml/ecma/kjs_traversal.cpp:
2216         * khtml/ecma/kjs_views.cpp:
2217         * khtml/ecma/xmlhttprequest.cpp:
2218         * khtml/ecma/xmlserializer.cpp:
2219         Update for changes to JSC.
2220
2221 2005-12-22  Darin Adler  <darin@apple.com>
2222
2223         Reviewed by NOBODY (OOPS!).
2224
2225         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6198
2226           use RefPtr a few places in RenderText and related classes
2227
2228         * khtml/html/htmlparser.cpp:
2229         (HTMLParser::parseToken): Use get since text pointer is RefPtr now.
2230         (HTMLParser::textCreateErrorCheck): Ditto.
2231         (HTMLParser::commentCreateErrorCheck): Ditto.
2232         (HTMLParser::handleIsindex): Get rid of explicit deref, no longer needed.
2233
2234         * khtml/html/htmltokenizer.h: Make attrs and text fields of Token use
2235         RefPtr. Also stop using bit fields for the flags in Token -- there's no
2236         evidence this makes things faster.
2237         * khtml/html/htmltokenizer.cpp:
2238         (khtml::Token::addAttribute): Get rid of explicit ref, no longer needed.
2239         (khtml::HTMLTokenizer::processToken): Ditto.
2240
2241         * khtml/rendering/render_block.cpp: (khtml::RenderBlock::updateFirstLetter):
2242         Use a PassRefPtr.
2243
2244         * khtml/rendering/render_text.cpp:
2245         (khtml::RenderText::previousOffset): Use get since str pointer is RefPtr now.
2246         (khtml::RenderText::nextOffset): Ditto.
2247         (khtml::RenderText::RenderText): Get rid of explicit ref, no longer needed.
2248         Change to use initializer syntax instead of assignment.
2249         (khtml::RenderText::setStyle): Use PassRefPtr.
2250         (khtml::RenderText::originalString): Ditto.
2251         (khtml::RenderText::setText): Get rid of explicit ref, no longer needed.
2252         (khtml::RenderTextFragment::RenderTextFragment): Get rid of explicit ref,
2253         no longer needed.
2254         (khtml::RenderTextFragment::originalString): Use PassRefPtr.
2255
2256         * khtml/rendering/render_text.h: Change SOFT_HYPEN to be a constant rather than
2257         a preprocessor macro. Used PassRefPtr in a couple places. Made RenderText's str
2258         and RenderTextFragment's m_generatedContentStr be RefPtr.
2259
2260         * khtml/html/html_inlineimpl.cpp: Add a newly-needed include, sort them.
2261         * kwq/KWQRenderTreeDebug.cpp: Add a newly-needed include.
2262
2263 2005-12-22  Darin Adler  <darin@apple.com>
2264
2265         Reviewed by Eric.
2266
2267         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6193
2268           remove some unused KWQ code
2269
2270         * kcanvas/KCanvasCreator.cpp: (KCanvasCreator::self): Don't use static deleter for
2271         two reasons: (1) We don't want any globals with constructors in any of our frameworks
2272         because they slow down framework load time. (2) There's no need to destroy this object at
2273         process termination time -- it's extra work with no benefit. Because of both these
2274         reasons, our KStaticDeleter implementation was basically a no-op.
2275         * ksvg2/svg/SVGDOMImplementationImpl.cpp: (SVGDOMImplementationImpl::self): Ditto.
2276         * khtml/xml/dom_docimpl.cpp: (DocumentImpl::setDocumentChanged): Ditto.
2277
2278         * khtml/html/html_canvasimpl.cpp: Removed include of kstringhandler.h.
2279         * khtml/html/html_imageimpl.cpp: Ditto.
2280
2281         * khtml/khtmlpart_p.h: Removed something that was in an "APPLE_CANGES" ifdef.
2282
2283         * ForwardingHeaders/kstaticdeleter.h: Removed.
2284         * ForwardingHeaders/kstringhandler.h: Removed.
2285         * kwq/KWQKStaticDeleter.h: Removed.
2286         * kwq/KWQKStringHandler.h: Removed.
2287         * kwq/KWQKStringHandler.mm: Removed.
2288
2289         * WebCore.xcodeproj/project.pbxproj: Removed files.
2290
2291 2005-12-22  Darin Adler  <darin@apple.com>
2292
2293         Reviewed by Eric.
2294
2295         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6192
2296           add support for non-standard &nsup; entity (implemented in other browsers)
2297
2298         * khtml/html/kentities.gperf: Add "nsup" to table.
2299         * khtml/html/htmltokenizer.cpp: Removed old workaround for inlining issue that no
2300         longer seems to be necessary; also touches the file which is important because
2301         Xcode doesn't seem to understand the dependency on kentities.gperf and the need
2302         to recompile.
2303
2304 2005-12-22  Darin Adler  <darin@apple.com>
2305
2306         Reviewed by Eric.
2307
2308         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6167
2309           RenderStyle default constructor should initialize its members for speed
2310
2311         * khtml/rendering/DataRef.h: (khtml::DataRef::operator=): Eliminate an extra
2312         branch by doing ref before deref instead of == check.
2313
2314         * khtml/rendering/render_style.cpp:
2315         (khtml::initDefaultStyle): Added. Function to initialize the default style
2316         for use in constructor.
2317         (khtml::RenderStyle::RenderStyle): Changed constructor to initalize all the
2318         members with constructor syntax instead of using assignment on all of them.
2319         * khtml/rendering/render_style.h: Removed static data member _default --
2320         it's now a file scope global instead.
2321
2322 2005-12-21  Darin Adler  <darin@apple.com>
2323
2324         Reviewed by Justin.
2325
2326         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6142
2327           intermittent failures in some paste tests
2328
2329         * khtml/editing/apply_style_command.cpp:
2330         (khtml::ApplyStyleCommand::applyBlockStyle): Call new updateLayout member function.
2331         (khtml::ApplyStyleCommand::applyInlineStyle): Ditto.
2332         (khtml::ApplyStyleCommand::pushDownTextDecorationStyleAtBoundaries): Ditto.
2333         * khtml/editing/composite_edit_command.cpp:
2334         (khtml::CompositeEditCommand::addBlockPlaceholderIfNeeded): Ditto.
2335         (khtml::CompositeEditCommand::findBlockPlaceholder): Ditto.
2336         (khtml::CompositeEditCommand::moveParagraphContentsToNewBlockIfNecessary): Ditto.
2337         * khtml/editing/delete_selection_command.cpp:
2338         (khtml::DeleteSelectionCommand::fixupWhitespace): Ditto.
2339         (khtml::DeleteSelectionCommand::moveNodesAfterNode): Ditto.
2340         * khtml/editing/edit_command.cpp:
2341         (khtml::EditCommand::apply): Ditto.
2342         (khtml::EditCommand::unapply): Ditto.
2343         (khtml::EditCommand::reapply): Ditto.
2344         (khtml::EditCommand::updateLayout): Added. Calls updateLayoutIgnorePendingStylesheets
2345         on the document.
2346         * khtml/editing/edit_command.h: Added updateLayout member function.
2347         * khtml/editing/insert_line_break_command.cpp:
2348         (khtml::InsertLineBreakCommand::doApply): Call new updateLayout member function.
2349         * khtml/editing/insert_paragraph_separator_command.cpp:
2350         (khtml::InsertParagraphSeparatorCommand::doApply): Ditto.
2351         * khtml/editing/jsediting.cpp:
2352         (DOM::JSEditor::execCommand): Call updateLayoutIgnorePendingStylesheets instead of updateLayout.
2353         (DOM::JSEditor::queryCommandEnabled): Ditto.
2354         (DOM::JSEditor::queryCommandIndeterm): Ditto.
2355         (DOM::JSEditor::queryCommandState): Ditto.
2356         (DOM::JSEditor::queryCommandValue): Ditto.
2357         * khtml/editing/markup.cpp: (khtml::createMarkup): Ditto.
2358         * khtml/editing/replace_selection_command.cpp:
2359         (khtml::ReplacementFragment::insertFragmentForTestRendering): Ditto.
2360         (khtml::ReplaceSelectionCommand::fixupNodeStyles): Call new updateLayout member function.
2361         (khtml::ReplacementFragment::computeStylesUsingTestRendering): Call
2362         updateLayoutIgnorePendingStylesheets instead of updateLayout.
2363         (khtml::ReplaceSelectionCommand::doApply): Call new updateLayout member function.
2364         (khtml::ReplaceSelectionCommand::removeLinePlaceholderIfNeeded): Ditto.
2365         (khtml::ReplaceSelectionCommand::completeHTMLReplacement): Ditto.
2366         * khtml/editing/visible_units.cpp:
2367         (khtml::previousLinePosition): Call updateLayoutIgnorePendingStylesheets instead of updateLayout.
2368         (khtml::nextLinePosition): Ditto.
2369         * khtml/html/html_elementimpl.cpp:
2370         (HTMLElementImpl::innerText): Ditto.
2371         * kwq/WebCoreBridge.mm:
2372         (-[WebCoreBridge setSelectedDOMRange:affinity:closeTyping:]): Ditto.
2373         (-[WebCoreBridge smartDeleteRangeForProposedRange:]): Ditto.
2374
2375 2005-12-21  Darin Adler  <darin@apple.com>
2376
2377         Reviewed by Geoff.
2378
2379         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6177
2380           move event code from JavaScript binding into DOM implementation
2381
2382         * khtml/ecma/kjs_events.cpp:
2383         (KJS::DOMMouseEvent::getValueProperty): Change everything to just call through instead of doing
2384         the work here.
2385         (KJS::DOMWheelEvent::getValueProperty): Ditto.
2386
2387         * khtml/xml/dom2_eventsimpl.h:
2388         (DOM::MouseRelatedEventImpl::offsetX):
2389         (DOM::MouseRelatedEventImpl::offsetY):
2390         * khtml/xml/dom2_eventsimpl.cpp:
2391         (DOM::MouseRelatedEventImpl::MouseRelatedEventImpl): Initialize new m_pageX, m_pageY, m_layerX,
2392         m_layerY, m_offsetX, and m_offsetY.
2393         (DOM::MouseRelatedEventImpl::computePositions): Renamed from computeLayerPos since it handles
2394         page position andoffset position too now.
2395         (DOM::MouseRelatedEventImpl::pageX): Added. Not in header since it's virtual.
2396         (DOM::MouseRelatedEventImpl::pageY): Ditto.
2397         (DOM::MouseRelatedEventImpl::x): Added, with FIXME since it should change eventually.
2398         (DOM::MouseRelatedEventImpl::y): Ditto.
2399         (DOM::MouseEventImpl::initMouseEvent): Call computePositions instead of computeLayerPos.
2400         (DOM::MouseEventImpl::toElement): Added.
2401         (DOM::MouseEventImpl::fromElement): Added.
2402
2403 2005-12-21  Timothy Hatcher  <timothy@apple.com>
2404
2405         * WebCore.xcodeproj/project.pbxproj:
2406           Set tab width to 8, indent width to 4 and uses tabs to false per file.
2407
2408 2005-12-21  John Sullivan  <sullivan@apple.com>
2409
2410         Reviewed by Tim Omernick and Darin Adler.
2411         
2412         - fixed HiDPI problem with forms auto-fill menu width
2413
2414         No test cases added; this code is used for "chrome" only.
2415
2416         * kwq/DOMHTML.mm:
2417         (-[DOMHTMLInputElement _rectOnScreen]):
2418         convert entire rect to window coordinates, not just origin
2419
2420 2005-12-21  David Harrison  <harrison@apple.com>
2421
2422         Reviewed by Justin.
2423
2424         <rdar://problem/4039777> Pasting particular snippet of HTML containing list items and a link creates too many list items
2425         - Fixed paste crash by making calling RenderBox::deleteLineBoxWrapper() from RenderObject::remove(),
2426         so that the connection is broken before the InlineBox's parent gets deleted.
2427         - Fixed overzealous style changes when setting the style on a specific range of elements.  These specific
2428         ranges are derived programmatically, e.g. as a part of pasting, so they must be respected exactly rather
2429         than modified by converting the endpoints to VisiblePositions.
2430         
2431         Test cases coming soon.
2432
2433         * khtml/editing/apply_style_command.cpp:
2434         (khtml::ApplyStyleCommand::ApplyStyleCommand):
2435         (khtml::ApplyStyleCommand::updateStartEnd):
2436         (khtml::ApplyStyleCommand::startPosition):
2437         (khtml::ApplyStyleCommand::endPosition):
2438         (khtml::ApplyStyleCommand::applyBlockStyle):
2439         (khtml::ApplyStyleCommand::applyRelativeFontStyleChange):
2440         (khtml::ApplyStyleCommand::applyInlineStyle):
2441         (khtml::ApplyStyleCommand::removeInlineStyle):
2442         (khtml::ApplyStyleCommand::splitTextAtStartIfNeeded):
2443         (khtml::ApplyStyleCommand::splitTextAtEndIfNeeded):
2444         (khtml::ApplyStyleCommand::splitTextElementAtStartIfNeeded):
2445         (khtml::ApplyStyleCommand::splitTextElementAtEndIfNeeded):
2446         (khtml::ApplyStyleCommand::mergeStartWithPreviousIfIdentical):
2447         (khtml::ApplyStyleCommand::mergeEndWithNextIfIdentical):
2448         (khtml::ApplyStyleCommand::joinChildTextNodes):
2449         * khtml/editing/apply_style_command.h:
2450         * khtml/editing/composite_edit_command.cpp:
2451         (khtml::CompositeEditCommand::applyStyle):
2452         * khtml/editing/composite_edit_command.h:
2453         * khtml/editing/insert_line_break_command.cpp:
2454         (khtml::InsertLineBreakCommand::doApply):
2455         * khtml/editing/replace_selection_command.cpp:
2456         (khtml::ReplaceSelectionCommand::fixupNodeStyles):
2457         (khtml::ReplaceSelectionCommand::completeHTMLReplacement):
2458         * khtml/rendering/render_box.cpp:
2459         (RenderBox::destroy):
2460         (RenderBox::deleteLineBoxWrapper):
2461         * khtml/rendering/render_box.h:
2462         * khtml/rendering/render_list.cpp:
2463         (RenderListMarker::~RenderListMarker):
2464         (RenderListMarker::setStyle):
2465         * khtml/rendering/render_object.cpp:
2466         (RenderObject::remove):
2467         * khtml/rendering/render_object.h:
2468         * khtml/rendering/render_replaced.cpp:
2469         (RenderWidget::destroy):
2470
2471 2005-12-20  Adele Peterson  <adele@apple.com>
2472
2473         Reviewed by Darin.
2474
2475         Fixed http://bugzilla.opendarwin.org/show_bug.cgi?id=5911
2476         REGRESSION: Page scroll position jumps when clicking on word in editable div
2477
2478         I moved the scrolling code out of setFocusNode, and consolidated some of the focus code to scroll when necessary.
2479
2480         * khtml/html/html_formimpl.cpp: Removed HTMLButtonElementImpl::blur, HTMLButtonElementImpl::focus, HTMLInputElementImpl::blur, HTMLInputElementImpl::focus.  
2481         New code in ElementImpl::focus will now handle these cases.  This allows tabbing through the elements to go through the same code path as calling focus() on an element.  
2482         Before, focus() would scroll to reveal for any form elements that had a RenderWidget, but wouldn't scroll for anchor elements, or any of the new form elements.  
2483         Now the behavior will be more consistent.
2484         (DOM::HTMLLabelElementImpl::focus): calls ElementImpl::focus.
2485         (DOM::HTMLLegendElementImpl::focus): ditto.
2486         * khtml/html/html_formimpl.h:
2487         * khtml/khtml_part.cpp:
2488         (KHTMLPart::selectAll): calls new function selectContentsOfNode
2489         (KHTMLPart::selectContentsOfNode): factored out code to selectAll for a particular node- which is useful for contenteditable elements.
2490         * khtml/khtml_part.h: added selectContentsOfNode
2491         * khtml/xml/dom_docimpl.cpp:
2492         (DocumentImpl::setFocusNode): removed scrolling code.
2493         * khtml/xml/dom_elementimpl.cpp:
2494         (ElementImpl::focus): Calls updateLayout in case focus() is called before there's a renderer.
2495         Makes a selection for editable elements (right now we select all, but this will change).
2496         Doesn't scroll if the renderer is a RenderWidget, since that is handled when the view becomes first responder.  This will go away when we convert the rest of our form elements.
2497         * kwq/KWQKHTMLPart.mm:
2498         (KWQKHTMLPart::revealSelection): Made this more like centerSelectionInVisibleArea  where we get the right rectangle if the selection is a caret.
2499         (KWQKHTMLPart::nextKeyViewInFrame): call ElementImpl::focus() for the node.  This will set the selection too, which used to be done here.
2500
2501 2005-12-20  Alexey Proskuryakov  <ap@nypop.com>
2502
2503         Reviewed by justin
2504         
2505         <http://bugzilla.opendarwin.org/show_bug.cgi?id=4682>
2506         -[WebHTMLView firstRectForCharacterRange:] is using _selectedRange instead of the given range if no marked text
2507
2508         Added layout tests:
2509         * editing/input/firstrectforcharacterrange-styled
2510         * editing/input/firstrectforcharacterrange-plain
2511
2512         * khtml/editing/visible_text.cpp:
2513         (khtml::TextIterator::rangeFromLocationAndLength): 
2514         Return null if the range isn't found, instead of a startless/endless 
2515         range.  Set the end if the requested location+length is out of bounds.
2516         * kwq/WebCoreBridge.mm:
2517         (-[WebCoreBridge convertToDOMRange:]): Handle larged unsigned values 
2518         before calling rangeWithLocationAndLength, which expects signed ints.
2519
2520 2005-12-20  Adele Peterson  <adele@apple.com>
2521
2522         Reviewed by Darin.
2523
2524         Fix for <rdar://problem/4387630> REGRESSION: <select> element's onClick event doesn't fire @ bugweb.apple.com
2525
2526         * kwq/KWQKHTMLPart.mm:
2527         (KWQKHTMLPart::passSubframeEventToSubframe): only pass mouse down for khtmlviews.
2528
2529 2005-12-20  Justin Garcia  <justin.garcia@apple.com>
2530
2531         Reviewed by eric, thatcher
2532         
2533         <rdar://problem/4172984> KWQExceptions needs to use @try/@catch instead of relying on NSException.h internals
2534         
2535         Needed to undef try/catch because of 4333439.  Moved the 
2536         declarations of variables that are returned from within a @try 
2537         block outside the @try block (because of "might be clobbered by 
2538         a longjmp or vfork" warnings).  Moved some return statements
2539         inside the @try block to fix volatilization errors with gcc4.
2540
2541         * WebCore.xcodeproj/project.pbxproj:
2542         * WebCorePrefix.h:
2543         * kcanvas/device/quartz/KCanvasFilterQuartz.mm:
2544         (KCanvasFEBlendQuartz::getCIFilter):
2545         (KCanvasFEColorMatrixQuartz::getCIFilter):
2546         (KCanvasFECompositeQuartz::getCIFilter):
2547         (getPointLightVectors):
2548         (getLightVectors):
2549         (getNormalMap):
2550         (KCanvasFEDiffuseLightingQuartz::getCIFilter):
2551         (KCanvasFEFloodQuartz::getCIFilter):
2552         (KCanvasFEImageQuartz::getCIFilter):
2553         (KCanvasFEMergeQuartz::getCIFilter):
2554         (KCanvasFESpecularLightingQuartz::getCIFilter):
2555         * kwq/KWQExceptions.h:
2556         * kwq/KWQExceptions.mm:
2557         (KWQReportBlockedException):
2558         * kwq/KWQFileButton.mm:
2559         (KWQFileButton::sizeForCharacterWidth):
2560         (KWQFileButton::frameGeometry):
2561         * kwq/KWQKCursor.mm:
2562         (+[NSCursor _WebCore_cursorWithName:hotSpot:_WebCore_cursorWithName:hotSpot:]):
2563         * kwq/KWQKHTMLPart.mm:
2564         (KWQKHTMLPart::createPart):
2565         (KWQKHTMLPart::nextKeyView):
2566         (KWQKHTMLPart::runJavaScriptPrompt):
2567         (KWQKHTMLPart::keyEvent):
2568         (KWQKHTMLPart::sendContextMenuEvent):
2569         (KWQKHTMLPart::fileWrapperForElement):
2570         (KWQKHTMLPart::attributedString):
2571         (KWQKHTMLPart::imageFromRect):
2572         * kwq/KWQKHTMLPartBrowserExtension.mm:
2573         * kwq/KWQLineEdit.mm:
2574         (QLineEdit::sizeForCharacterWidth):
2575         * kwq/KWQListBox.mm:
2576         (QListBox::sizeForNumberOfLines):
2577         * kwq/KWQLoader.mm:
2578         (KWQCheckCacheObjectStatus):
2579         * kwq/KWQWidget.mm:
2580         (QWidget::frameGeometry):
2581         (QWidget::mapFromGlobal):
2582
2583 2005-12-20  David Harrison  <harrison@apple.com>
2584
2585         <rdar://problem/4294417> Cannot un-italicize some text after triple clicking it
2586
2587         Reviewed by Justin.
2588
2589         * khtml/editing/apply_style_command.cpp:
2590         (khtml::ApplyStyleCommand::addInlineStyleIfNeeded):
2591         Removed check for tab span because ApplyStyleCommand::removeCSSStyle() already makes the same check.
2592
2593 2005-12-20  Justin Garcia  <justin.garcia@apple.com>
2594
2595         <rdar://problem/4387270> editing/deleting/delete-3800834-fix failing
2596         <http://bugzilla.opendarwin.org/show_bug.cgi?id=6160> REGRESSION: Crash when running editing/deleting/delete-3800834-fix.html
2597         <http://bugzilla.opendarwin.org/show_bug.cgi?id=6161> REGRESSION: crash when pressing tab in editable WebHTMLView
2598
2599         Reviewed by darin
2600     
2601         Some callers call setAttribute on a floating element.  So, using 
2602         a RefPtr for the element inside addAttribute can destroy
2603         it.
2604
2605         * khtml/xml/dom_elementimpl.cpp:
2606         (NamedAttrMapImpl::addAttribute):
2607
2608 2005-12-20  Maciej Stachowiak  <mjs@apple.com>
2609
2610         Reviewed by Darin.
2611
2612         - fixed leak in createAttributeMap
2613         http://bugzilla.opendarwin.org/show_bug.cgi?id=6162
2614
2615         * khtml/xml/dom_elementimpl.cpp:
2616         (StyledElementImpl::createAttributeMap): the new attribute map
2617         is going in a RefPtr, don't also ref it manually.
2618
2619 2005-12-20  Maciej Stachowiak  <mjs@apple.com>
2620
2621         Reviewed by Darin.
2622
2623         - change an assignment to a contructor declaration to build with PassRefPtr
2624         leak fix changes
2625
2626         * ksvg2/svg/SVGTransformableImpl.cpp:
2627         (SVGTransformableImpl::parseTransformAttribute):
2628
2629 2005-12-20  Geoffrey Garen  <ggaren@apple.com>
2630
2631         Reviewed by John.
2632
2633         Fixed <rdar://problem/4310363> JavaScript window.open: Height is 1 
2634         pixel short, and related bugs.
2635
2636         There were a few bugs here.
2637         (1) Our code took size arguments and applied them to the window's
2638             content rect. That's incorrect. The Rhino book says the arguments 
2639             should apply to the WebView. Other things that occupy the content 
2640             rect include the tab bar, the status bar, and the 1 pixel border 
2641             between brushed metal and document. All of these used to impinge 
2642             on the web page's display area.
2643
2644             The fix is to calculate sizing based on the WebView instead of
2645             the content rect. This means that the webViewContentRect and 
2646             setContentRect delegate methods are obsolete and no longer called
2647             by any of our code. (setContentRect was never called in the 
2648             first place.)
2649
2650         (2) None of our sizing accounted for scaled resolutions.
2651
2652             The fix is to ask the WebView to scale all coordintes for us.
2653
2654         (3) Our code assumed that all window accoutrements were on by default.
2655             Safari works that way, but other WebKit clients might not.
2656
2657             The fix is always to explicitly set an on/off state.
2658         
2659         (a) To facilitate scaling, I added a new bridge method, webView, to 
2660         access the webView.
2661
2662         (b) For internal consistency, I changed ___Bars to ___bars in bridge 
2663         methods, and ___bars to ___Bars in WinArgs data members. (Interestingly,
2664         the different classes in our code are evenly divided on which format to 
2665         use.)
2666         
2667         Added manual test:
2668         * manual-tests/window-open-features.html: Added.
2669         * manual-tests/resources/200x200.png: Added.
2670         * manual-tests/resources/popup200x200.html: Added.
2671
2672         * khtml/ecma/kjs_window.cpp:
2673         (KJS::showModalDialog): see (b)
2674         (KJS::WindowFunc::callAsFunction): see (b)
2675         * kwq/KWQKHTMLPart.mm:
2676         (KWQKHTMLPart::statusbarVisible): see (b)
2677         * kwq/KWQKHTMLPartBrowserExtension.mm:
2678         (KHTMLPartBrowserExtension::createNewWindow):
2679         At the top of this method, I just did some formatting cleanup and
2680         moved the 'referrer' variable closer to where it's used.
2681         The changes in the middle of the method are (3), the bottom, (2).
2682         * kwq/KWQKPartsBrowserExtension.h:
2683         (KParts::WindowArgs::WindowArgs): see (b)
2684         * kwq/WebCoreBridge.h: see (a)
2685
2686 2005-12-20  Eric Seidel  <eseidel@apple.com>
2687
2688         Reviewed by mjs.
2689
2690         Leaks when running SVG tests
2691         http://bugzilla.opendarwin.org/show_bug.cgi?id=6156
2692         No additional tests necessary, leaks already caught by other tests.
2693
2694         * kcanvas/KCanvasFilters.cpp:
2695         (KCanvasFEDiffuseLighting::setLightSource): takes ownership
2696         (KCanvasFESpecularLighting::setLightSource): takes ownership
2697         * kcanvas/KCanvasFilters.h:
2698         (KCanvasFEDiffuseLighting::KCanvasFEDiffuseLighting): added
2699         (KCanvasFEDiffuseLighting::~KCanvasFEDiffuseLighting): added
2700         (KCanvasFEDiffuseLighting::lightSource): fixed spacing
2701         (KCanvasFESpecularLighting::KCanvasFESpecularLighting): added
2702         (KCanvasFESpecularLighting::~KCanvasFESpecularLighting): added
2703         (KCanvasFESpecularLighting::lightSource): fixed spacing
2704         * kcanvas/device/quartz/KRenderingDeviceQuartz.mm:
2705         (KRenderingDeviceQuartz::stringForPath): added missing CFRelease
2706
2707 2005-12-20  Eric Seidel  <eseidel@apple.com>
2708
2709         Reviewed by darin.
2710
2711         Remove additional bit-rotted DEBUG* ifdefs from WebCore.
2712         This removes PARSER_DEBUG, FORMS_DEBUG and CSS_STYLESHEET_DEBUG.
2713         http://bugzilla.opendarwin.org/show_bug.cgi?id=5931
2714         No tests possible, only removing dead code.
2715
2716         * khtml/css/css_stylesheetimpl.cpp:
2717         (CSSStyleSheetImpl::parseString):
2718         (CSSStyleSheetImpl::isLoading):
2719         * khtml/html/html_formimpl.cpp:
2720         (DOM::HTMLFormElementImpl::formData):
2721         (DOM::HTMLFormElementImpl::submit):
2722         (DOM::HTMLFormElementImpl::reset):
2723         (DOM::HTMLGenericFormElementImpl::getForm):
2724         * khtml/html/htmlparser.cpp:
2725         (HTMLParser::processCloseTag):
2726         (HTMLParser::createHead):
2727
2728 2005-12-20  Eric Seidel  <eseidel@apple.com>
2729
2730         Reviewed by darin.
2731
2732         Move Decoder onto Shared<T> and clients onto RefPtr.
2733         http://bugzilla.opendarwin.org/show_bug.cgi?id=6107
2734         No test cases possible, no functional changes.
2735
2736         * khtml/ecma/XSLTProcessor.cpp:
2737         (KJS::XSLTProcessorProtoFunc::callAsFunction):
2738         * khtml/ecma/xmlhttprequest.cpp:
2739         (KJS::XMLHttpRequest::XMLHttpRequest):
2740         (KJS::XMLHttpRequest::~XMLHttpRequest):
2741         (KJS::XMLHttpRequest::changeState):
2742         (KJS::XMLHttpRequest::abort):
2743         (KJS::XMLHttpRequest::slotFinished):
2744         (KJS::XMLHttpRequest::slotData):
2745         * khtml/ecma/xmlhttprequest.h:
2746         * khtml/khtml_part.cpp:
2747         (KHTMLPart::clear):
2748         (KHTMLPart::begin):
2749         (KHTMLPart::write):
2750         * khtml/khtmlpart_p.h:
2751         (KHTMLPartPrivate::KHTMLPartPrivate):
2752         * khtml/misc/decoder.cpp:
2753         (Decoder::Decoder):
2754         (Decoder::~Decoder):
2755         * khtml/misc/decoder.h:
2756         * khtml/misc/loader.h:
2757         * khtml/xml/dom_docimpl.cpp:
2758         (DocumentImpl::DocumentImpl):
2759         (DocumentImpl::~DocumentImpl):
2760         (DocumentImpl::prepareMouseEvent):
2761         (DocumentImpl::setDecoder):
2762         * khtml/xml/dom_docimpl.h:
2763         (DOM::DocumentImpl::decoder):
2764         * khtml/xsl/xslt_processorimpl.cpp:
2765         (DOM::XSLTProcessorImpl::createDocumentFromSource):
2766
2767 2005-12-19  Darin Adler  <darin@apple.com>
2768
2769         Reviewed by Maciej.
2770
2771         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6143
2772           DOM::ElementImpl should use a RefPtr for the attribute map
2773
2774         * khtml/xml/dom_elementimpl.cpp:
2775         (ElementImpl::ElementImpl): Remove code to initialize the pointer; not needed since
2776         RefPtr gets initialized to 0.
2777         (ElementImpl::~ElementImpl): Remove code to deref the pointer; RefPtr handles that.
2778         (ElementImpl::attributes): Add get() call to get raw pointer.
2779         (ElementImpl::setAttributeMap): Remove code to deref the old map and set the new map.
2780         But added code to clear the element pointer from the old map (missing in the old
2781         version). Also added a FIXME.
2782         (ElementImpl::createAttributeMap): Remove ref(); RefPtr handles that.
2783         (NamedAttrMapImpl::addAttribute): Use a RefPtr to guarantee the element does not go
2784         away in the middle of dispatching DOM events.
2785         (StyledElementImpl::attributeChanged): Clean up code by using the inline function
2786         mappedAttributes() instead of doing type casts.
2787         (StyledElementImpl::parseMappedAttribute): Ditto.
2788         (StyledElementImpl::getClassList): Ditto.
2789
2790         * khtml/xml/dom_elementimpl.h: Make ElementImpl::namedAttrMap be a RefPtr instead
2791         of raw pointer. Added an overload of StyledElementImpl::mappedAttributes for both
2792         const and non-const.
2793
2794         * khtml/xml/dom_nodeimpl.cpp: (DOM::NodeImpl::addChild): Use a RefPtr to ref/deref
2795         the child so that it doesn't leak.
2796
2797         * khtml/html/htmlparser.h: Changed isindex to use a RefPtr.
2798         * khtml/html/htmlparser.cpp:
2799         (HTMLParser::~HTMLParser): Removed now-unneeded ref.
2800         (HTMLParser::isindexCreateErrorCheck): Remove now-unneeded deref/ref.
2801         (HTMLParser::handleIsindex): Put isindex element into a RefPtr. This prevents a
2802         crash that was otherwise happening during layout tests (caused indirectly by
2803         the changes above).
2804         (HTMLParser::startBody): Added call to get().
2805
2806 2005-12-19  Darin Adler  <darin@apple.com>
2807
2808         Reviewed by Geoff Garen and Eric Seidel.
2809
2810         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=4923
2811           stop using <ostream> in WebCore, eliminating the <cmath> troubles it causes
2812
2813         * ForwardingHeaders/kxmlcore/AlwaysInline.h: Added.
2814         * WebCorePrefix.h: Removed the use of <ostream>.
2815
2816         * kwq/KWQDef.h: Removed now-unused Q_INT64, Q_INT16, Q_UINT16, qRound, and _KWQ_IOSTREAM_.
2817
2818         * kwq/KWQKHTMLPart.h: Removed some unneeded headers and added forward-declarations of classes
2819         instead. Corrected some incorrect member function declarations.
2820         * kwq/KWQKHTMLPart.mm: Added a now-needed header.
2821
2822         * khtml/ecma/kjs_window.cpp: Removed the <cmath> workaround.
2823         * khtml/rendering/bidi.cpp: Added include of AlwaysInline.h and removed a
2824         lot of unnecessary includes.
2825         * khtml/rendering/render_canvasimage.cpp: Removed the <cmath> workaround.
2826         * khtml/rendering/render_image.cpp: Removed the <cmath> workaround.
2827         * khtml/rendering/render_text.cpp: Added include of AlwaysInline.h and removed a
2828         lot of unnecessary includes.
2829
2830         * ksvg2/css/SVGCSSStyleSelector.cpp: (KDOM::CSSStyleSelector::applySVGProperty):
2831         * ksvg2/svg/SVGAnimateColorElementImpl.cpp: (SVGAnimateColorElementImpl::calculateColor):
2832         * ksvg2/svg/SVGAnimateTransformElementImpl.cpp: (SVGAnimateTransformElementImpl::handleTimerEvent):
2833         * ksvg2/svg/SVGAnimationElementImpl.cpp: (SVGAnimationElementImpl::closeRenderer):
2834         * ksvg2/svg/SVGLinearGradientElementImpl.cpp: (SVGLinearGradientElementImpl::buildGradient):
2835         * ksvg2/svg/SVGPatternElementImpl.cpp: (SVGPatternElementImpl::notifyAttributeChange):
2836         * ksvg2/svg/SVGRadialGradientElementImpl.cpp: (SVGRadialGradientElementImpl::buildGradient):
2837         Replaced use of qRound with use of lroundf or lround as appropriate.
2838
2839         * kwq/KWQCString.h:
2840         * kwq/KWQCString.mm:
2841         * kwq/KWQDateTime.h:
2842         * kwq/KWQDateTime.mm:
2843         * kwq/KWQMap.h:
2844         * kwq/KWQMemArray.h:
2845         * kwq/KWQPoint.mm:
2846         * kwq/KWQPointArray.h:
2847         * kwq/KWQPtrList.h:
2848         * kwq/KWQPtrStack.h:
2849         * kwq/KWQPtrVector.h:
2850         * kwq/KWQRect.h:
2851         * kwq/KWQRect.mm:
2852         * kwq/KWQSize.h:
2853         * kwq/KWQSize.mm:
2854         * kwq/KWQValueList.h:
2855         Removed _KWQ_IOSTREAM_ code that was used at one time for unit tests, but is now unneeded,
2856         and requires <ostream>.
2857
2858 2005-12-19  Darin Adler  <darin@apple.com>
2859
2860         Reviewed by Geoff Garen and John Sullivan.
2861
2862         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=4312
2863           XMLHttpRequest headers that have two CRLF sequences lead to Obj-C exception
2864
2865         I found this by code inspection after examining a security report about
2866         vulnerabilities in other browsers' XMLHttpRequest implementations.
2867
2868         * kwq/KWQLoader.mm:
2869         (+[NSDictionary _webcore_dictionaryWithHeaderString:_webcore_dictionaryWithHeaderString:]):
2870         Check length of string before calling characterAtIndex:0 since it will fail for an empty string.
2871
2872 2005-12-19  Mitz Pettel  <opendarwin.org@mitzpettel.com>
2873
2874         Reviewed by Beth
2875
2876         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6149
2877           REGRESSION (WebCore-417.5): horizontal scrollbar in overflow with top
2878           border doesn't receive mouse events
2879
2880         * khtml/rendering/render_block.cpp:
2881         (khtml::RenderBlock::isPointInScrollbar):
2882         Removed borderTop() from horizontal scrollbar rect computation.
2883         * manual-tests/scrollbar-hittest2.html: Added.
2884
2885 2005-12-19  Alexey Proskuryakov  <ap@nypop.com>
2886
2887         Reviewed by Darin, committed by Adele.
2888
2889         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=5744
2890           XMLHttpRequest does not apply page encoding after assigning via innerHtml
2891
2892         * khtml/ecma/xmlhttprequest.cpp:
2893         (getMIMEType): A helper function to get MIME type from a Content-Type string.
2894         (getCharset): A helper function to get charset from a Content-Type string.
2895         (KJS::XMLHttpRequest::getValueProperty): Factored out responseIsXML().
2896         (KJS::XMLHttpRequest::getResponseHeader): Return QString instead of JSValue
2897           (to get rid of unnecessary JSLocks).
2898         (KJS::XMLHttpRequest::responseIsXML): A new method that analyses Content-Type.
2899         (KJS::XMLHttpRequest::slotData): Use a correct charset for responses, see bug for details.
2900         (KJS::XMLHttpRequestProtoFunc::callAsFunction): Update for getResponseHeader() changes
2901         * khtml/ecma/xmlhttprequest.h:
2902
2903 == Rolled over to ChangeLog-2005-12-19 ==