Reviewed by me, patch by Mitz Pettel.
[WebKit-https.git] / WebCore / ChangeLog-2005-08-23
1 2005-05-26  Darin Adler  <darin@apple.com>
2
3         Reviewed by me, patch by Mitz Pettel.
4
5         - fixed <rdar://problem/4106907> bidi algorithm bug fixed for KHTML should be fixed in WebCore too
6
7         * khtml/rendering/bidi.cpp: (khtml::RenderBlock::bidiReorderLine): Integrated the patch that Mitz did
8         for the KDE bug, details at <http://www.mitzpettel.com/software/WebCorePatch2.html>.
9
10         Test cases added:
11         * layout-tests/fast/text/international/bidi-neutral-directionality-paragraph-start-expected.txt: Added.
12         * layout-tests/fast/text/international/bidi-neutral-directionality-paragraph-start.html: Added.
13
14 2005-05-26  Darin Adler  <darin@apple.com>
15
16         Reviewed by Richard and Dave Harrison.
17         No new test cases needed for this change.
18
19         - eliminate WebCoreUnicode and use ICU directly instead
20         - fixed compiling with gcc 4.0 (was broken for Development only)
21
22         * WebCore.exp: Removed the WebCoreXXXFunction exports.
23         * WebCore-tests.exp: Removed some QChar functions that are now inlines.
24         Removed some typeinfo exports that are no longer appropriate since we use -fno-rtti.
25
26         * kwq/KWQString.h:
27         (QChar::isDigit): Changed to call u_isdigit when non-ASCII. We should probably phase
28         this out since it's only used in places where we don't want to handle non-ASCII decimal digits.
29         (QChar::isLetter): Changed to call u_isalpha when non-ASCII.
30         (QChar::isNumber): Changed to call u_isdigit when non-ASCII. This probably should be removed, since
31         we always want to call isDigit instead.
32         (QChar::isLetterOrNumber): Changed to call u_isalnum when non-ASCII.
33         (QChar::isPunct): Changed to call u_ispunct when non-ASCII.
34         (QChar::digitValue): Changed to call u_charDigitValue when not '0'-'9'. We should probably phase
35         this out since it's only used in places where we don't want to handle non-ASCII decimal digits.
36         (QChar::lower): Changed to call u_tolower when non-ASCII.
37         (QChar::upper): Changed to call u_toupper when non-ASCII.
38         (QChar::direction): Made inline. Calls u_charDirection.
39         (QChar::mirrored): Made inline. Calls u_isMirrored.
40         (QChar::mirroredChar): Made inline. Calls u_charMirror.
41
42         * kwq/KWQChar.mm: Removed.
43         * kwq/WebCoreUnicode.cpp: Removed.
44         * kwq/WebCoreUnicode.h: Removed.
45
46         * WebCore.pbproj/project.pbxproj: Removed files.
47
48 2005-05-26  David Harrison  <harrison@apple.com>
49
50         Reviewed by John.
51
52         <rdar://problem/4120518> Mail: control-T in an empty message crashes mail
53         
54         * kwq/WebCoreBridge.mm:
55         (-[WebCoreBridge rangeOfCharactersAroundCaret]):
56         Nil-check result of VisiblePosition previous() and next().
57
58         * khtml/editing/visible_position.cpp:
59         (khtml::VisiblePosition::previous):
60         (khtml::VisiblePosition::previousVisiblePosition):
61         Make sure previous() does not return the original position.  Also, simplified.
62         Commented odd, but required, behavior in previousVisiblePosition().
63
64         * khtml/editing/visible_units.cpp:
65         (khtml::startOfEditableContent):
66         (khtml::endOfEditableContent):
67         Removed redundant check for isEditableContent().
68         
69         * khtml/editing/jsediting.cpp:
70         * khtml/khtml_part.cpp:
71         (KHTMLPart::transpose):
72         * khtml/khtml_part.h:
73         * kwq/KWQKHTMLPart.h:
74         * kwq/KWQKHTMLPart.mm:
75         (KWQKHTMLPart::issueTransposeCommand):
76         * layout-tests/editing/editing.js:
77         * kwq/WebCoreBridge.h:
78         Add support for transpose command in JavaScript and therefore layout tests.
79         
80         * layout-tests/editing/deleting/transpose-empty-expected.txt: Added.
81         * layout-tests/editing/deleting/transpose-empty.html: Added.
82         New test for this bug.
83         
84 2005-05-24  Richard Williamson   <rjw@apple.com>
85
86         Fixed <rdar://problem/4127061> <canvas> backing store should be zero filled
87
88         Use calloc instead of malloc to ensure zero filled backing store.
89
90         Reviewed by Darin.
91
92         * khtml/rendering/render_canvasimage.cpp:
93         (RenderCanvasImage::createDrawingContext):
94
95 2005-05-24  John Sullivan  <sullivan@apple.com>
96
97         Reviewed by Dave Hyatt.
98         
99         - fixed these bugs:
100         <rdar://problem/4118510> Textareas with a vertical scroll bar should have their resize corner under the scroll bar
101         <rdar://problem/4118523> Resize image in textareas is drawn repeatedly when scrolling vertically with scrollbar
102
103         Test cases added: none; doesn't affect page layout
104
105         * kwq/KWQTextArea.h:
106         added inInitWithFrame ivar
107         * kwq/KWQTextArea.mm:
108         (+[KWQTextArea _resizeCornerImage]):
109         moved here from KWQTextAreaTextView; now it's a class method so we only look up the image once.
110         (-[KWQTextArea initWithFrame:]):
111         set and clear inInitWithFrame ivar, used by -tile
112         (-[KWQTextArea _isResizableByUser]):
113         renamed with an underscore for consistency
114         (-[KWQTextArea _textViewShouldHandleResizing]):
115         new method, returns YES if the textarea is user-resizable and the enclosed textview is responsible for drawing
116         and tracking the resize corner.
117         (-[KWQTextArea tile]):
118         shrink the vertical scroller if appropriate to account for the resize corner
119         (-[KWQTextArea _resizeCornerRect]):
120         new method, returns the bottom-right corner rect, where the resize image goes
121         (-[KWQTextArea _trackResizeFromMouseDown:]):
122         moved here from KWQTextAreaTextView. The only changes were to move the [NSCursor set] call inside here (was in
123         the caller), and to use self where it was using [self _enclosingTextArea], and to move a comment in here that
124         was in the caller
125         (-[KWQTextArea mouseDown:]):
126         track resizing if appropriate
127         (-[KWQTextArea drawRect:]):
128         draw the resize corner if appropriate
129         (-[KWQTextAreaTextView _resizeCornerRect]):
130         get the resize image from KWQTextArea
131         (-[KWQTextAreaTextView resetCursorRects]):
132         check _textViewShouldHandleResizing
133         (-[KWQTextAreaTextView drawRect:]):
134         ditto
135         (-[KWQTextAreaTextView mouseDown:]):
136         ditto; also, make the textarea handle the resize tracking now
137
138 2005-05-24  Darin Adler  <darin@apple.com>
139
140         - another gcc 4.0 fix
141
142         No new test cases needed.
143
144         * khtml/dom/dom2_events.cpp: Moved constants out of the KHTML_NO_CPLUSPLUS_DOM #if.
145
146 2005-05-24  Darin Adler  <darin@apple.com>
147
148         Reviewed by Vicki.
149
150         - fixed <rdar://problem/4128727> many DOM classes not exported (can't add categories or do other things that require class name linking)
151
152         No new test cases needed.
153
154         * WebCore.exp: Added exports for many classes in the public DOM headers that were omitted before.
155         Also removed one symbol that was listed twice.
156
157 2005-05-24  Maciej Stachowiak  <mjs@apple.com>
158
159         Reviewed by John.
160
161         - fixed <rdar://problem/3598589> onunload handler doesn't fire when a window is closed
162
163         Test cases added: 
164         * layout-tests/fast/events/onunload-expected.txt: Added.
165         * layout-tests/fast/events/onunload.html: Added.
166
167         * khtml/xml/dom_docimpl.cpp:
168         (DocumentImpl::detach): Don't remove all event handlers from the document here...
169         * khtml/khtml_part.cpp:
170         (KHTMLPart::closeURL): ...instead do it here, after firing the unload event, but only
171         if the document is not in the back/forward cache...
172         * kwq/KWQPageState.mm:
173         (-[KWQPageState finalize]): ...and take care of the back/forward cache case here.
174
175 2005-05-24  John Sullivan  <sullivan@apple.com>
176
177         Reviewed by Kevin.
178         
179         - WebCore part of <rdar://problem/4125783> WebKit needs a way to control whether textareas are resizable
180
181         * kwq/KWQKHTMLSettings.h:
182         (KHTMLSettings::textAreasAreResizable):
183         new getter
184         (KHTMLSettings::setTextAreasAreResizable):
185         new setter
186         
187         * kwq/KWQTextArea.h:
188         * kwq/KWQTextArea.mm:
189         eliminated ALLOW_RESIZING_TEXT_AREAS #define in favor of using runtime setting
190         (-[KWQTextArea isResizableByUser]):
191         get value from settings, and cache it in KWQTextArea instance
192         (-[KWQTextAreaTextView _enclosingTextArea]):
193         new convenience method, extracted from _trackResizeFromMouseDown:
194         (-[KWQTextAreaTextView _trackResizeFromMouseDown:]):
195         now uses extracted method
196         
197         (-[KWQTextAreaTextView drawRect:]):
198         now checks isResizableByUser
199         (-[KWQTextAreaTextView mouseDown:]):
200         ditto
201         
202         * kwq/WebCoreSettings.h:
203         * kwq/WebCoreSettings.mm:
204         (-[WebCoreSettings setTextAreasAreResizable:]):
205         new setter
206         (-[WebCoreSettings textAreasAreResizable]):
207         new getter
208
209 2005-05-23  Maciej Stachowiak  <mjs@apple.com>
210
211         Reviewed by John.
212
213         - split remaining editing command classes out of htmlediting.cpp
214         - rename InsertParagraphSeparatorInQuotedContentCommand to BreakBlockquoteCommand
215
216         No layout tests needed - this is a pure refactoring change.
217         
218         * WebCore.pbproj/project.pbxproj:
219         * khtml/editing/apply_style_command.cpp:
220         * khtml/editing/break_blockquote_command.cpp: Added.
221         * khtml/editing/break_blockquote_command.h: Added.
222         * khtml/editing/composite_edit_command.cpp:
223         * khtml/editing/delete_selection_command.cpp:
224         * khtml/editing/edit_command.cpp:
225         * khtml/editing/htmlediting.cpp:
226         * khtml/editing/htmlediting.h:
227         * khtml/editing/insert_line_break_command.cpp: Added.
228         * khtml/editing/insert_line_break_command.h: Added.
229         * khtml/editing/insert_paragraph_separator_command.cpp: Added.
230         * khtml/editing/insert_paragraph_separator_command.h: Added.
231         * khtml/editing/insert_text_command.cpp: Added.
232         * khtml/editing/insert_text_command.h: Added.
233         * khtml/editing/join_text_nodes_command.cpp: Added.
234         * khtml/editing/join_text_nodes_command.h: Added.
235         * khtml/editing/merge_identical_elements_command.cpp: Added.
236         * khtml/editing/merge_identical_elements_command.h: Added.
237         * khtml/editing/move_selection_command.cpp: Added.
238         * khtml/editing/move_selection_command.h: Added.
239         * khtml/editing/rebalance_whitespace_command.cpp: Added.
240         * khtml/editing/rebalance_whitespace_command.h: Added.
241         * khtml/editing/remove_css_property_command.cpp: Added.
242         * khtml/editing/remove_css_property_command.h: Added.
243         * khtml/editing/remove_node_attribute_command.cpp: Added.
244         * khtml/editing/remove_node_attribute_command.h: Added.
245         * khtml/editing/remove_node_command.cpp: Added.
246         * khtml/editing/remove_node_command.h: Added.
247         * khtml/editing/remove_node_preserving_children_command.cpp: Added.
248         * khtml/editing/remove_node_preserving_children_command.h: Added.
249         * khtml/editing/replace_selection_command.cpp: Added.
250         * khtml/editing/replace_selection_command.h: Added.
251         * khtml/editing/set_node_attribute_command.cpp: Added.
252         * khtml/editing/set_node_attribute_command.h: Added.
253         * khtml/editing/split_element_command.cpp: Added.
254         * khtml/editing/split_element_command.h: Added.
255         * khtml/editing/split_text_node_command.cpp: Added.
256         * khtml/editing/split_text_node_command.h: Added.
257         * khtml/editing/split_text_node_containing_element_command.h: Added.
258         * khtml/editing/typing_command.cpp: Added.
259         * khtml/editing/typing_command.h: Added.
260         * khtml/editing/wrap_contents_in_dummy_span_command.cpp: Added.
261         * khtml/editing/wrap_contents_in_dummy_span_command.h: Added.
262
263 2005-05-23  Darin Adler  <darin@apple.com>
264
265         * WebCore.exp: Sorted file for more readable diffs.
266
267 2005-05-23  Adele Peterson  <adele@apple.com>
268
269         Reviewed by Darin.
270
271         fix for <rdar://problem/4122661> Regression: 10.3.8-10.3.9: Next lesson doesn't work on Dale Carnegie Action Systems page
272
273         * khtml/ecma/kjs_window.cpp: (KJS::WindowFunc::tryCall): added checks for NaN, in case it is passed into window.open for screenx, screeny, left, top, height, or width.
274
275 2005-05-23  David Harrison  <harrison@apple.com>
276
277         Reviewed by Darin.
278
279         Prevent crash when going from no selection to selection with mispelling checks enabled.
280                 
281         * kwq/KWQKHTMLPart.mm:
282         (KWQKHTMLPart::markMisspellings):
283         Repair check for null searchRange.  Was inadvertently broken in recent checkin.
284
285 2005-05-23  John Sullivan  <sullivan@apple.com>
286
287         Reviewed by Dave Hyatt.
288         
289         - fixed <rdar://problem/4123592> Can't resize textareas that have a width specified by a style
290
291         * kwq/KWQTextArea.mm:
292         (-[KWQTextArea getNumColumns:andNumRows:forSize:]):
293         removed this method, which I had added earlier to set cols and rows correctly
294         (-[KWQTextAreaTextView _trackResizeFromMouseDown:]):
295         set width and height instead of cols and rows; handle the intrinsic margin that sometimes appears
296         on form elements
297
298 2005-05-22  Adele Peterson  <adele@apple.com>
299
300         Reviewed by Maciej.
301
302         fix for <rdar://problem/4127101> REGRESSION(412-TOT) crash when creating Option element
303
304         * khtml/ecma/kjs_html.cpp: (KJS::OptionConstructorImp::construct):
305         Changed ElementImpl pointer to a SharedPtr because it was getting destroyed before we were done with it.  
306
307 2005-05-20  John Sullivan  <sullivan@apple.com>
308
309         Reviewed by Chris.
310         
311         - fixed <rdar://problem/4126160> Crash sending mouse-exited event after reloading 
312         page with resizable textarea
313
314         * kwq/KWQTextArea.mm:
315         (-[KWQTextAreaTextView resetCursorRects]):
316         This was some side effect of tracking rect code used for resizable textareas. I discovered
317         that I didn't need the tracking rect code at all (at least to achieve the level of only-somewhat-working
318         cursor behavior that I already had). Removing it caused the bug to vanish.
319
320 2005-05-19  Darin Adler  <darin@apple.com>
321
322         Reviewed by Maciej.
323         
324         - turned off exceptions and RTTI; seems to cut WebCore code size by about 35%
325
326         * WebCore.pbproj/project.pbxproj: Turn off exceptions and RTTI for the framework.
327
328 2005-05-19  Darin Adler  <darin@apple.com>
329
330         Reviewed by Chris Petersen.
331
332         - fixed a mistake I introduced in my previous check-in that caused a Deployment build failure
333
334         * kwq/DOM.mm: (-[DOMDocument createTreeWalker::::]): Initialize cppFilter to 0, which fixes both
335         the build failure and a potential bug!
336
337 2005-05-17  Darin Adler  <darin@apple.com>
338
339         Reviewed by Maciej.
340         No new layout tests required.
341
342         - remove all dependencies on exceptions and RTTI (but don't turn them off yet, that will be in a later patch)
343
344         * WebCore.pbproj/project.pbxproj: Set a new KHTML_NO_CPLUSPLUS_DOM define.
345         Removed all C++ DOM wrapper files that we don't need to compile any more.
346
347         * khtml/dom/css_stylesheet.h: Added more KHTML_NO_CPLUSPLUS_DOM checks so we don't include any
348         headers when including this file.
349
350         * khtml/dom/dom2_events.h: Fixed up KHTML_NO_CPLUSPLUS_DOM checks so that everything but EventListener
351         is turned off when that's on. Also moved the public so that the constants from KeyboardEvent are public.
352         * khtml/dom/dom2_events.cpp: Put everything except for EventListener inside KHTML_NO_CPLUSPLUS_DOM.
353
354         * khtml/dom/dom2_range.h: Added KHTML_NO_CPLUSPLUS_DOM checks so that only the constants are defined,
355         no classes.
356
357         * khtml/dom/dom2_traversal.cpp: Put everything except for NodeFilterCondition inside KHTML_NO_CPLUSPLUS_DOM.
358
359         * khtml/dom/dom_node.h: Added more KHTML_NO_CPLUSPLUS_DOM checks so we don't include any
360         headers when including this file.
361
362         * khtml/ecma/kjs_binding.cpp:
363         (KJS::DOMObject::get): Removed exception-handling code. Now we can eliminate tryGet altogether.
364         (KJS::DOMObject::put): Ditto.
365         (KJS::DOMFunction::get): Ditto.
366         (KJS::DOMFunction::call): Ditto.
367
368         * khtml/editing/visible_text.h: Added an include of <qstring.h>.
369
370         * khtml/misc/loader.h: Added isKHTMLLoader.
371         * khtml/misc/loader.cpp: (Loader::isKHTMLLoader): Added. Poor-man's replacement for dynamic_cast.
372
373         * khtml/rendering/render_form.h:
374         * khtml/rendering/render_form.cpp: (RenderFormElement::slotTextChanged): Added. Hack to make KWQSlot work
375         for this function.
376
377         * khtml/xml/dom2_rangeimpl.h: Added a forward declaration of class DOMString, needed now that the C++
378         DOM wrappers aren't defining it.
379
380         * khtml/xml/dom_docimpl.cpp:
381         (DocumentImpl::defaultEventHandler): Changed to call handleEventImpl so we don't have to make the
382         C++ DOM wrapper for the event.
383         * khtml/xml/dom_nodeimpl.cpp:
384         (NodeImpl::handleLocalEvents): Ditto.
385         (ContainerNodeImpl::insertBefore): Used SharedPtr<NodeImpl> rather than Node to protect the child node.
386         (ContainerNodeImpl::replaceChild): Ditto.
387         (ContainerNodeImpl::appendChild): Ditto.
388         (ContainerNodeImpl::addChild): Ditto.
389
390         * kwq/DOM.mm:
391         (ObjCNodeFilterCondition::acceptNode): Update to add a KHTML_NO_CPLUSPLUS_DOM check since FilterCondition
392         has a different API depending on the state.
393         (-[DOMDocument createNodeIterator::::]): Rewrote to use NodeFilterImpl instead of NodeFilter.
394         (-[DOMDocument createTreeWalker::::]): Ditto.
395
396         * kwq/KWQAccObject.mm:
397         (-[KWQAccObject role]): Use identifier instead of casting to Node and using elementId.
398         (-[KWQAccObject title]): Ditto.
399         (-[KWQAccObject accessibilityIsIgnored]): Ditto.
400         (-[KWQAccObject rendererForView:]): Ditto.
401
402         * kwq/KWQFrame.mm: (QFrame::setFrameStyle): Use isKHTMLView instead of dynamic_cast.
403
404         * kwq/KWQKHTMLPart.mm:
405         (KWQKHTMLPart::currentForm): Use focusNode instead of activeNode.
406         (KWQKHTMLPart::nextKeyViewInFrame): Use isWidget instead of dynamic_cast.
407         (KWQKHTMLPart::currentEventIsMouseDownInWidget): Use KHTMLView's nodeUnderMouse instead of our public one
408         that uses a DOM C++ wrapper.
409         (KWQKHTMLPart::partForWidget): Use isKHTMLView instead of dynamic_cast.
410         (KWQKHTMLPart::passSubframeEventToSubframe): Use isWidget instead of dynamic_cast.
411
412         * kwq/KWQObject.h: Made isXXX functions all public since we use them in a few more places now.
413         Also added isKHTMLLoader.
414         * kwq/KWQObject.mm: (QObject::isKHTMLLoader): Added. Returns false by default.
415
416         * kwq/KWQSlot.mm: Removed all uses of dynamic_cast.
417
418         * kwq/WebCoreBridge.mm:
419         (-[WebCoreBridge stringForRange:]): Used plainText instead of text.
420         (-[WebCoreBridge copyRenderNode:copier:]): Used isWidget instead of dynamic_cast.
421
422 2005-05-16  Darin Adler  <darin@apple.com>
423
424         - attempt to get things building under "Saffron" development tools
425
426         * WebCore.pbproj/project.pbxproj: Use BUILT_PRODUCTS_DIR instead of SYMROOT.
427
428 2005-05-16  Adele Peterson  <adele@apple.com>
429
430         Changes by Darin. Reviewed by myself.
431
432         Changed the Render Tree debug code to write out an indication that the affinity is upstream
433         when writing out caret position. Updated the one layout test with output affected by the change.
434         Also updated one test to use the new dumpAsText method in dumpRenderTree.
435
436         * kwq/KWQRenderTreeDebug.cpp: (writeSelection): writes out affinity if it's upstream in the caret case
437         * layout-tests/editing/style/create-block-for-style-004-expected.txt: new results that contain the affinity
438         * layout-tests/fast/js/char-at.html: now calls layoutController.dumpAsText()
439         * layout-tests/fast/js/char-at-expected.txt: plain text result (replaces old render tree result)
440
441 2005-05-16  Darin Adler  <darin@apple.com>
442
443         Reviewed by Adele.
444
445         - fixed issues preventing us from compiling with newer versions of gcc 4.0
446
447         * khtml/dom/dom2_events.cpp: Add definitions of some static data member constants, as required
448         by the C++ standard and the gcc 4.0 compiler.
449
450         * khtml/editing/selection.h: Specified KHTMLPart friend class as ::KHTMLPart, since if it's
451         not explicitly qualified, it means DOM::KHTMLPart.
452
453         * khtml/dom/dom_string.cpp:
454         (DOM::strcasecmp): Removed redundant and illegal DOM:: prefix.
455         (DOM::operator==): Ditto.
456         * khtml/ecma/kjs_binding.cpp:
457         (KJS::getStringOrNull): Removed redundant and illegal KJS:: prefix.
458         (KJS::ValueToVariant): Ditto.
459         * khtml/ecma/kjs_css.cpp:
460         (KJS::getCSSRuleConstructor): Ditto.
461         (KJS::getCSSValueConstructor): Ditto.
462         (KJS::getCSSPrimitiveValueConstructor): Ditto.
463         * khtml/ecma/kjs_events.cpp:
464         (KJS::getEventConstructor): Ditto.
465         (KJS::getEventExceptionConstructor): Ditto.
466         (KJS::getMutationEventConstructor): Ditto.
467         * khtml/ecma/kjs_traversal.cpp:
468         (KJS::getNodeFilterConstructor): Ditto.
469
470         * khtml/misc/loader_client.h: Added an empty virtual destructor to CachedObjectClient
471         to quiet the compiler. This doesn't really do any good, but also does no harm.
472         * khtml/misc/loader.cpp: (CachedObjectClient::~CachedObjectClient): Added.
473
474         * khtml/rendering/render_block.cpp: (khtml::RenderBlock::fillBlockSelectionGaps):
475         Initialize a couple of variables that should have been initialized to 0.
476         Not just about making the compiler happy -- warning found a real bug!
477
478         * kwq/KWQTextArea.mm: (RangeOfParagraph): Change else structure to work around compiler
479         warning bug.
480
481 2005-05-13  John Sullivan  <sullivan@apple.com>
482
483         * kwq/KWQTextArea.mm:
484         (-[KWQTextAreaTextView _trackResizeFromMouseDown:]):
485         added Radar numbers to FIXMEs about resizable textareas
486         (-[KWQTextAreaTextView resetCursorRects]):
487         ditto
488         (-[KWQTextAreaTextView mouseDown:]):
489         ditto
490
491 2005-05-12  Darin Adler  <darin@apple.com>
492
493         Reviewed by Chris Blumenberg.
494
495         - more "getting off the C++ DOM wrappers" changes
496           This pass involves replacing uses of DOM::Range with use of DOM::RangeImpl
497           plus some more use of DOM::DocumentImpl instead of DOM::Document.
498
499         * khtml/dom/dom2_range.cpp:
500         * khtml/dom/dom2_range.h:
501         * khtml/ecma/kjs_window.cpp:
502         (KJS::Window::get):
503         (KJS::WindowFunc::tryCall):
504         (KJS::Window::updateLayout):
505         (KJS::ScheduledAction::execute):
506         (KJS::Selection::toString):
507         * khtml/ecma/xmlhttprequest.cpp:
508         (KJS::XMLHttpRequestProtoFunc::tryCall):
509         * khtml/editing/htmlediting.cpp:
510         (khtml::InsertLineBreakCommand::doApply):
511         * khtml/editing/selection.cpp:
512         (khtml::Selection::Selection):
513         (khtml::Selection::moveTo):
514         (khtml::Selection::toRange):
515         * khtml/editing/selection.h:
516         * khtml/editing/visible_position.cpp:
517         (khtml::makeRange):
518         (khtml::startVisiblePosition):
519         (khtml::endVisiblePosition):
520         (khtml::setStart):
521         (khtml::setEnd):
522         * khtml/editing/visible_position.h:
523         * khtml/editing/visible_range.h:
524         * khtml/editing/visible_text.cpp:
525         (khtml::TextIterator::TextIterator):
526         (khtml::TextIterator::range):
527         (khtml::SimplifiedBackwardsTextIterator::SimplifiedBackwardsTextIterator):
528         (khtml::SimplifiedBackwardsTextIterator::range):
529         (khtml::CharacterIterator::CharacterIterator):
530         (khtml::CharacterIterator::range):
531         (khtml::WordAwareIterator::WordAwareIterator):
532         (khtml::WordAwareIterator::advance):
533         (khtml::TextIterator::rangeLength):
534         (khtml::TextIterator::rangeFromLocationAndLength):
535         (khtml::plainText):
536         (khtml::findPlainText):
537         * khtml/editing/visible_text.h:
538         (khtml::WordAwareIterator::range):
539         * khtml/editing/visible_units.cpp:
540         (khtml::previousBoundary):
541         (khtml::nextBoundary):
542         * khtml/html/html_elementimpl.cpp:
543         (HTMLElementImpl::innerText):
544         * khtml/html/htmltokenizer.cpp:
545         (khtml::HTMLTokenizer::scriptExecution):
546         * khtml/khtml_part.cpp:
547         (KHTMLPart::text):
548         (KHTMLPart::selectedText):
549         (KHTMLPart::shouldBeginEditing):
550         (KHTMLPart::shouldEndEditing):
551         (KHTMLPart::selectionComputedStyle):
552         * khtml/khtml_part.h:
553         * khtml/khtmlview.h:
554         * khtml/rendering/render_text.cpp:
555         (InlineTextBox::paint):
556         * khtml/xml/dom2_rangeimpl.cpp:
557         (DOM::operator==):
558         (DOM::rangeOfContents):
559         * khtml/xml/dom2_rangeimpl.h:
560         (DOM::operator!=):
561         * khtml/xml/dom_docimpl.cpp:
562         (DocumentImpl::relinquishesEditingFocus):
563         (DocumentImpl::acceptsEditingFocus):
564         (DocumentImpl::addMarker):
565         (DocumentImpl::removeMarker):
566         * khtml/xml/dom_docimpl.h:
567         * khtml/xml/dom_position.cpp:
568         (DOM::startPosition):
569         * khtml/xml/dom_position.h:
570         * kwq/DOMHTML.mm:
571         (-[DOMHTMLLinkElement href]):
572         (-[DOMHTMLBaseElement href]):
573         (-[DOMHTMLInputElement src]):
574         (-[DOMHTMLAnchorElement href]):
575         (-[DOMHTMLImageElement src]):
576         (-[DOMHTMLAreaElement href]):
577         * kwq/KWQAccObject.mm:
578         (-[KWQAccObject textUnderElement]):
579         (-[KWQAccObject value]):
580         (-[KWQAccObject doAXStringForTextMarkerRange:]):
581         (-[KWQAccObject doAXAttributedStringForTextMarkerRange:]):
582         * kwq/KWQKHTMLPart.h:
583         (KWQKHTMLPart::markedTextRange):
584         * kwq/KWQKHTMLPart.mm:
585         (KWQKHTMLPart::findString):
586         (KWQKHTMLPart::advanceToNextMisspelling):
587         (KWQKHTMLPart::fontForSelection):
588         (KWQKHTMLPart::markMisspellings):
589         (KWQKHTMLPart::respondToChangedSelection):
590         (KWQKHTMLPart::shouldBeginEditing):
591         (KWQKHTMLPart::shouldEndEditing):
592         (convertAttributesToUnderlines):
593         (KWQKHTMLPart::setMarkedTextRange):
594         * kwq/WebCoreBridge.mm:
595         (-[WebCoreBridge elementAtPoint:]):
596         (-[WebCoreBridge rangeByExpandingSelectionWithGranularity:]):
597         (-[WebCoreBridge rangeByAlteringCurrentSelection:direction:granularity:]):
598         (-[WebCoreBridge rangeByAlteringCurrentSelection:verticalDistance:]):
599         (-[WebCoreBridge selectedDOMRange]):
600         (-[WebCoreBridge convertToNSRange:DOM::]):
601         (-[WebCoreBridge convertToDOMRange:]):
602         (-[WebCoreBridge convertToObjCDOMRange:]):
603         (-[WebCoreBridge selectNSRange:]):
604         (-[WebCoreBridge selectedNSRange]):
605         (-[WebCoreBridge markDOMRange]):
606         (-[WebCoreBridge markedTextDOMRange]):
607         (-[WebCoreBridge markedTextNSRange]):
608         (-[WebCoreBridge replaceMarkedTextWithText:]):
609         (-[WebCoreBridge smartDeleteRangeForProposedRange:]):
610         (-[WebCoreBridge dragCaretDOMRange]):
611         (-[WebCoreBridge editableDOMRangeForPoint:]):
612         (-[WebCoreBridge rangeOfCharactersAroundCaret]):
613
614 2005-05-13  Maciej Stachowiak  <mjs@apple.com>
615
616         Reviewed by Dave.
617
618         - more splitting up of htmlediting.cpp
619
620         * WebCore.pbproj/project.pbxproj:
621         * khtml/editing/composite_edit_command.cpp:
622         * khtml/editing/delete_from_text_node_command.cpp: Added.
623         * khtml/editing/delete_from_text_node_command.h: Added.
624         * khtml/editing/delete_selection_command.cpp: Added.
625         * khtml/editing/delete_selection_command.h: Added.
626         * khtml/editing/htmlediting.cpp:
627         * khtml/editing/htmlediting.h:
628         * khtml/editing/insert_into_text_node_command.cpp: Added.
629         * khtml/editing/insert_into_text_node_command.h: Added.
630         * khtml/editing/insert_node_before_command.cpp: Added.
631         * khtml/editing/insert_node_before_command.h: Added.
632
633 2005-05-12  Adele Peterson  <adele@apple.com>
634
635         Reviewed by Maciej.
636
637         fix for  <rdar://problem/4117656> deleting an input element in its onBlur handler crashes Safari
638
639         * khtml/rendering/render_form.cpp: (RenderLineEdit::handleFocusOut): added nil check for element
640
641 2005-05-12  John Sullivan  <sullivan@apple.com>
642
643         Reviewed by Kevin.
644         
645         - rolled in changes from experimental-ui-branch to support resizable textareas
646         and find-as-you-type. The files/functions modified are listed just below. After
647         that are the ChangeLog comments from the branch.
648
649         * Resources/textAreaResizeCorner.tiff: Added.
650         * WebCore.pbproj/project.pbxproj:
651         * kwq/KWQKHTMLPart.h:
652         * kwq/KWQKHTMLPart.mm:
653         (KWQKHTMLPart::findString):
654         * kwq/KWQTextArea.mm:
655         (-[KWQTextArea textDidChange:]):
656         (-[KWQTextAreaTextView _resizeCornerImage]):
657         (-[KWQTextAreaTextView _resizeCornerRect]):
658         (-[KWQTextAreaTextView resetCursorRects]):
659         (-[KWQTextAreaTextView drawRect:]):
660         (-[KWQTextAreaTextView mouseDown:]):
661         * kwq/WebCoreBridge.h:
662         * kwq/WebCoreBridge.mm:
663         (-[WebCoreBridge searchFor:direction:caseSensitive:wrap:findInSelection:]):
664
665         2005-05-05  John Sullivan  <sullivan@apple.com>
666
667                 Reviewed by Chris.
668
669                 * kwq/KWQTextArea.mm:
670                 (-[KWQTextAreaTextView _resizeCornerRect]):
671                 Get corner rect from enclosing clipView, rather than using visibleRect.
672                 VisibleRect would return the wrong result when the textarea was clipped
673                 by the bottom of the window, leading to redraw schmutz among other things.
674
675         2005-05-02  John Sullivan  <sullivan@apple.com>
676
677                 Reviewed by Chris.
678                 
679                 Improvements to resizable textarea experiment:
680                 - resize image is now drawn in the resize corner
681                 - cursor sometimes tracks to arrow when over resize corner (but usually not)
682                 - cursor changes to arrow on mouse down in any case
683
684                 * Resources/textAreaResizeCorner.tiff: Added.
685                 * WebCore.pbproj/project.pbxproj:
686                 updated for added image file
687                 
688                 * kwq/KWQTextArea.mm:
689                 (-[KWQTextAreaTextView _resizeCornerImage]):
690                 new method, reads resize image once and caches it
691                 (-[KWQTextAreaTextView _resizeCornerRect]):
692                 new method, computes rect from image
693                 (-[KWQTextAreaTextView resetCursorRects]):
694                 overridden to attempt to make the cursor change to an arrow when over this
695                 corner. Only works sometimes, as explained in comments.
696                 (-[KWQTextAreaTextView drawRect:]):
697                 overridden to draw resize image
698                 (-[KWQTextAreaTextView mouseDown:]):
699                 now uses _resizeCornerRect, and sets cursor to arrow when pressed in resize corner
700
701         2005-04-18  John Sullivan  <sullivan@apple.com>
702
703                 WebCore support for notifying a form delegate when a
704                 textarea's contents have changed (as opposed to a 
705                 textfield, which was already handled).
706
707                 Reviewed by Maciej.
708
709                 * kwq/WebCoreBridge.h:
710                 add textDidChange: method
711
712                 * kwq/KWQTextArea.mm:
713                 (-[KWQTextArea textDidChange:]):
714                 call through to bridge
715
716         2005-04-07  John Sullivan  <sullivan@apple.com>
717
718                 WebCore support for find-as-you-type; needed an additional parameter
719                 to findString and searchFor:...
720
721                 Reviewed by Dave Hyatt.
722
723                 * kwq/KWQKHTMLPart.h:
724                 * kwq/KWQKHTMLPart.mm:
725                 (KWQKHTMLPart::findString):
726                 new findInSelection parameter; if true, start from the beginning of the selection
727                 when searching forward, or the end of the selection when searching backward
728                 
729                 * kwq/WebCoreBridge.h:
730                 * kwq/WebCoreBridge.mm:
731                 (-[WebCoreBridge searchFor:direction:caseSensitive:wrap:findInSelection:]):
732                 new findInSelection parameter; passed through to findString
733
734 2005-05-12  Darin Adler  <darin@apple.com>
735
736         Reviewed by Maciej (except for some parts outside the ECMA directory).
737
738         - switch KJS wrappers over to using the DOM impl. classes rather than using
739           the DOM wrappers; will allow us to not even compile the DOM wrappers and
740           make the code smaller
741
742         * khtml/css/css_valueimpl.h: Added CSSStyleDeclarationImpl::isPropertyName,
743         removed CSSStyleDeclarationImpl::propertyID.
744         * khtml/css/css_valueimpl.cpp:
745         (DOM::propertyID): Added. Gets property ID given a DOM string. Replaces the
746         previous version that had hacks that we want to leave in the JS wrapper for now.
747         (DOM::CSSStyleDeclarationImpl::isPropertyName): Added.
748
749         * khtml/css/cssproperties.in: Fixed up comments.
750
751         * khtml/css/makeprop: Added new maxCSSPropertyNameLength constant, used for
752         buffer size in the propertyID function.
753
754         * khtml/dom/dom2_events.h: Added handleEventImpl, making it easier to call
755         handleEvent in a way that works either with or without the C++ DOM wrappers.
756         * khtml/dom/dom2_events.cpp: (EventListener::handleEventImpl): Added.
757
758         * khtml/dom/dom2_views.cpp: Added now-needed include.
759         * khtml/dom/dom_doc.cpp: Added now-needed include.
760         * khtml/dom/dom_element.cpp: Tweaked includes.
761
762         * khtml/editing/htmlediting.cpp: Removed now-unneeded include.
763         * khtml/html/html_baseimpl.cpp: Ditto.
764         * khtml/html/html_formimpl.h: Ditto.
765         * khtml/rendering/render_form.h: Ditto.
766         * khtml/rendering/render_style.h: Ditto.
767         * khtml/xml/dom2_eventsimpl.cpp: Ditto.
768         * khtml/xml/dom2_viewsimpl.h: Ditto.
769         * khtml/xml/dom_elementimpl.h: Ditto.
770         * khtml/xml/dom_stringimpl.h: Ditto.
771         * kwq/DOM.mm: Ditto.
772         * kwq/DOMHTML.mm: Ditto.
773
774         * khtml/khtml_part.cpp: Tweaked incluudes.
775         * khtml/khtmlpart_p.h: Ditto.
776
777         * kwq/KWQKHTMLPart.mm: (KWQKHTMLPart::canCachePage): Change to use DOM impl. rather
778         than C++ DOM.
779
780         * khtml/xml/dom_docimpl.cpp:
781         (DOMImplementationImpl::createDocumentType): Disabled the calls to the not-implemented
782         name checks in the C++ DOM wrappers. If we add name changes, we'll want them inside the
783         impl, not in the wrappers.
784         (DOMImplementationImpl::createDocument): Ditto.
785         * khtml/xml/dom_nodeimpl.cpp: (NodeImpl::checkSetPrefix): Ditto.
786
787         * khtml/ecma/kjs_binding.cpp:
788         (KJS::ScriptInterpreter::wasRunByUserGesture):
789         (KJS::KJS::ValueToVariant):
790         (KJS::setDOMException):
791         * khtml/ecma/kjs_binding.h:
792         (KJS::ScriptInterpreter::setCurrentEvent):
793         (KJS::ScriptInterpreter::getCurrentEvent):
794         (KJS::cacheDOMObject):
795         (KJS::DOMExceptionTranslator::DOMExceptionTranslator):
796         (KJS::DOMExceptionTranslator::~DOMExceptionTranslator):
797         (KJS::DOMExceptionTranslator::operator int &):
798         (KJS::cacheGlobalObject):
799         * khtml/ecma/kjs_css.cpp:
800         (KJS::cssPropertyName):
801         (KJS::isCSSPropertyName):
802         (KJS::DOMCSSStyleDeclaration::DOMCSSStyleDeclaration):
803         (KJS::DOMCSSStyleDeclaration::~DOMCSSStyleDeclaration):
804         (KJS::DOMCSSStyleDeclaration::hasProperty):
805         (KJS::DOMCSSStyleDeclaration::tryGet):
806         (KJS::DOMCSSStyleDeclaration::tryPut):
807         (KJS::DOMCSSStyleDeclarationProtoFunc::tryCall):
808         (KJS::getDOMCSSStyleDeclaration):
809         (KJS::DOMStyleSheet::~DOMStyleSheet):
810         (KJS::DOMStyleSheet::getValueProperty):
811         (KJS::DOMStyleSheet::tryPut):
812         (KJS::getDOMStyleSheet):
813         (KJS::DOMStyleSheetList::~DOMStyleSheetList):
814         (KJS::DOMStyleSheetList::tryGet):
815         (KJS::getDOMStyleSheetList):
816         (KJS::DOMStyleSheetListFunc::tryCall):
817         (KJS::DOMMediaList::DOMMediaList):
818         (KJS::DOMMediaList::~DOMMediaList):
819         (KJS::DOMMediaList::tryGet):
820         (KJS::DOMMediaList::tryPut):
821         (KJS::getDOMMediaList):
822         (KJS::KJS::DOMMediaListProtoFunc::tryCall):
823         (KJS::DOMCSSStyleSheet::DOMCSSStyleSheet):
824         (KJS::DOMCSSStyleSheet::tryGet):
825         (KJS::DOMCSSStyleSheetProtoFunc::tryCall):
826         (KJS::DOMCSSRuleList::~DOMCSSRuleList):
827         (KJS::DOMCSSRuleList::tryGet):
828         (KJS::DOMCSSRuleListFunc::tryCall):
829         (KJS::getDOMCSSRuleList):
830         (KJS::DOMCSSRule::~DOMCSSRule):
831         (KJS::DOMCSSRule::classInfo):
832         (KJS::DOMCSSRule::tryGet):
833         (KJS::DOMCSSRule::getValueProperty):
834         (KJS::DOMCSSRule::putValue):
835         (KJS::DOMCSSRuleFunc::tryCall):
836         (KJS::getDOMCSSRule):
837         (KJS::DOMCSSValue::~DOMCSSValue):
838         (KJS::DOMCSSValue::tryGet):
839         (KJS::DOMCSSValue::tryPut):
840         (KJS::getDOMCSSValue):
841         (KJS::DOMCSSPrimitiveValue::DOMCSSPrimitiveValue):
842         (KJS::DOMCSSPrimitiveValue::tryGet):
843         (KJS::DOMCSSPrimitiveValueProtoFunc::tryCall):
844         (KJS::DOMCSSValueList::DOMCSSValueList):
845         (KJS::DOMCSSValueList::tryGet):
846         (KJS::DOMCSSValueListFunc::tryCall):
847         (KJS::DOMRGBColor::getValueProperty):
848         (KJS::getDOMRGBColor):
849         (KJS::DOMRect::~DOMRect):
850         (KJS::DOMRect::getValueProperty):
851         (KJS::getDOMRect):
852         (KJS::DOMCounter::~DOMCounter):
853         (KJS::DOMCounter::getValueProperty):
854         (KJS::getDOMCounter):
855         * khtml/ecma/kjs_css.h:
856         (KJS::DOMCSSStyleDeclaration::impl):
857         (KJS::DOMStyleSheet::DOMStyleSheet):
858         (KJS::DOMStyleSheet::impl):
859         (KJS::DOMStyleSheetList::DOMStyleSheetList):
860         (KJS::DOMStyleSheetList::impl):
861         (KJS::DOMMediaList::impl):
862         (KJS::DOMCSSStyleSheet::):
863         (KJS::DOMCSSRuleList::DOMCSSRuleList):
864         (KJS::DOMCSSRuleList::impl):
865         (KJS::DOMCSSRule::DOMCSSRule):
866         (KJS::DOMCSSRule::impl):
867         (KJS::DOMCSSValue::DOMCSSValue):
868         (KJS::DOMCSSValue::impl):
869         (KJS::DOMCSSValueList::):
870         (KJS::DOMRGBColor::DOMRGBColor):
871         (KJS::DOMRect::DOMRect):
872         (KJS::DOMCounter::DOMCounter):
873         * khtml/ecma/kjs_dom.cpp:
874         (KJS::DOMNodeListFunc::):
875         (KJS::DOMNode::DOMNode):
876         (KJS::DOMNode::toBoolean):
877         (KJS::DOMNode::getValueProperty):
878         (KJS::DOMNode::putValue):
879         (KJS::DOMNode::toPrimitive):
880         (KJS::DOMNode::toString):
881         (KJS::DOMNode::setListener):
882         (KJS::DOMNode::getListener):
883         (KJS::DOMNodeProtoFunc::tryCall):
884         (KJS::toNode):
885         (KJS::DOMNodeList::~DOMNodeList):
886         (KJS::DOMNodeList::toPrimitive):
887         (KJS::DOMNodeList::tryGet):
888         (KJS::DOMNodeList::tryCall):
889         (KJS::DOMNodeListFunc::tryCall):
890         (KJS::DOMAttr::DOMAttr):
891         (KJS::DOMAttr::getValueProperty):
892         (KJS::DOMAttr::putValue):
893         (KJS::toAttr):
894         (KJS::DOMDocument::DOMDocument):
895         (KJS::DOMDocument::~DOMDocument):
896         (KJS::DOMDocument::getValueProperty):
897         (KJS::DOMDocument::putValue):
898         (KJS::DOMDocumentProtoFunc::tryCall):
899         (KJS::DOMElement::DOMElement):
900         (KJS::DOMElement::tryGet):
901         (KJS::DOMElementProtoFunc::tryCall):
902         (KJS::toElement):
903         (KJS::DOMDOMImplementation::DOMDOMImplementation):
904         (KJS::DOMDOMImplementation::~DOMDOMImplementation):
905         (KJS::DOMDOMImplementationProtoFunc::tryCall):
906         (KJS::DOMDocumentType::DOMDocumentType):
907         (KJS::DOMDocumentType::getValueProperty):
908         (KJS::toDocumentType):
909         (KJS::DOMNamedNodeMap::DOMNamedNodeMap):
910         (KJS::DOMNamedNodeMap::~DOMNamedNodeMap):
911         (KJS::DOMNamedNodeMap::tryGet):
912         (KJS::DOMNamedNodeMapProtoFunc::tryCall):
913         (KJS::DOMProcessingInstruction::DOMProcessingInstruction):
914         (KJS::DOMProcessingInstruction::getValueProperty):
915         (KJS::DOMProcessingInstruction::tryPut):
916         (KJS::DOMNotation::DOMNotation):
917         (KJS::DOMNotation::getValueProperty):
918         (KJS::DOMEntity::DOMEntity):
919         (KJS::DOMEntity::getValueProperty):
920         (KJS::getDOMDocumentNode):
921         (KJS::checkNodeSecurity):
922         (KJS::getDOMNode):
923         (KJS::getDOMNamedNodeMap):
924         (KJS::getRuntimeObject):
925         (KJS::getDOMNodeList):
926         (KJS::getDOMDOMImplementation):
927         (KJS::getNodeConstructor):
928         (KJS::getDOMExceptionConstructor):
929         (KJS::DOMNamedNodesCollection::DOMNamedNodesCollection):
930         (KJS::DOMNamedNodesCollection::tryGet):
931         (KJS::DOMCharacterData::DOMCharacterData):
932         (KJS::DOMCharacterData::getValueProperty):
933         (KJS::DOMCharacterData::tryPut):
934         (KJS::DOMCharacterDataProtoFunc::tryCall):
935         (KJS::DOMText::DOMText):
936         (KJS::DOMTextProtoFunc::tryCall):
937         * khtml/ecma/kjs_dom.h:
938         (KJS::DOMNode::impl):
939         (KJS::DOMNodeList::DOMNodeList):
940         (KJS::DOMNodeList::impl):
941         (KJS::DOMDOMImplementation::impl):
942         (KJS::DOMNamedNodeMap::impl):
943         * khtml/ecma/kjs_events.cpp:
944         (KJS::JSAbstractEventListener::handleEvent):
945         (KJS::JSLazyEventListener::handleEvent):
946         (KJS::getNodeEventListener):
947         (KJS::DOMEvent::DOMEvent):
948         (KJS::DOMEvent::~DOMEvent):
949         (KJS::DOMEvent::getValueProperty):
950         (KJS::DOMEvent::putValue):
951         (KJS::DOMEventProtoFunc::tryCall):
952         (KJS::getDOMEvent):
953         (KJS::toEvent):
954         (KJS::DOMUIEvent::DOMUIEvent):
955         (KJS::DOMUIEvent::getValueProperty):
956         (KJS::DOMUIEventProtoFunc::tryCall):
957         (KJS::DOMMouseEvent::DOMMouseEvent):
958         (KJS::DOMMouseEvent::getValueProperty):
959         (KJS::DOMMouseEventProtoFunc::tryCall):
960         (KJS::DOMKeyboardEvent::DOMKeyboardEvent):
961         (KJS::DOMKeyboardEvent::getValueProperty):
962         (KJS::DOMKeyboardEventProtoFunc::tryCall):
963         (KJS::DOMMutationEvent::DOMMutationEvent):
964         (KJS::DOMMutationEvent::getValueProperty):
965         (KJS::DOMMutationEventProtoFunc::tryCall):
966         (KJS::DOMWheelEvent::DOMWheelEvent):
967         (KJS::DOMWheelEvent::getValueProperty):
968         (KJS::ClipboardProtoFunc::tryCall):
969         * khtml/ecma/kjs_events.h:
970         (KJS::DOMEvent::impl):
971         (KJS::DOMUIEvent::):
972         (KJS::DOMMouseEvent::):
973         (KJS::DOMKeyboardEvent::):
974         (KJS::DOMMutationEvent::):
975         * khtml/ecma/kjs_html.cpp:
976         (KJS::KJS::HTMLDocFunction::tryCall):
977         (KJS::HTMLDocument::HTMLDocument):
978         (KJS::HTMLDocument::hasProperty):
979         (KJS::HTMLDocument::tryGet):
980         (KJS::KJS::HTMLDocument::putValue):
981         (KJS::KJS::HTMLElement::classInfo):
982         (KJS::HTMLElement::HTMLElement):
983         (KJS::KJS::HTMLElement::tryGet):
984         (KJS::KJS::HTMLElement::implementsCall):
985         (KJS::KJS::HTMLElement::call):
986         (KJS::KJS::HTMLElement::getValueProperty):
987         (KJS::KJS::HTMLElement::hasProperty):
988         (KJS::KJS::HTMLElement::toString):
989         (KJS::getForm):
990         (KJS::KJS::HTMLElement::pushEventHandlerScope):
991         (KJS::KJS::HTMLElementFunction::tryCall):
992         (KJS::KJS::HTMLElement::tryPut):
993         (KJS::HTMLElement::putValue):
994         (KJS::toHTMLElement):
995         (KJS::toHTMLTableCaptionElement):
996         (KJS::toHTMLTableSectionElement):
997         (KJS::HTMLCollection::HTMLCollection):
998         (KJS::HTMLCollection::~HTMLCollection):
999         (KJS::KJS::HTMLCollection::tryGet):
1000         (KJS::KJS::HTMLCollection::tryCall):
1001         (KJS::KJS::HTMLCollection::getNamedItems):
1002         (KJS::KJS::HTMLCollectionProtoFunc::tryCall):
1003         (KJS::HTMLSelectCollection::HTMLSelectCollection):
1004         (KJS::KJS::HTMLSelectCollection::tryGet):
1005         (KJS::KJS::HTMLSelectCollection::tryPut):
1006         (KJS::OptionConstructorImp::OptionConstructorImp):
1007         (KJS::OptionConstructorImp::construct):
1008         (KJS::ImageConstructorImp::ImageConstructorImp):
1009         (KJS::ImageConstructorImp::construct):
1010         (KJS::Image::notifyFinished):
1011         (KJS::Image::Image):
1012         (KJS::KJS::Context2DFunction::tryCall):
1013         (KJS::):
1014         (KJS::colorRefFromValue):
1015         (KJS::colorFromValue):
1016         (KJS::Context2D::putValue):
1017         (KJS::Context2D::Context2D):
1018         (KJS::Context2D::mark):
1019         (KJS::GradientFunction::tryCall):
1020         (KJS::ImagePattern::tryGet):
1021         (KJS::getHTMLCollection):
1022         (KJS::getSelectHTMLCollection):
1023         * khtml/ecma/kjs_html.h:
1024         (KJS::HTMLDocument::):
1025         (KJS::HTMLElement::):
1026         (KJS::HTMLCollection::impl):
1027         * khtml/ecma/kjs_navigator.cpp:
1028         * khtml/ecma/kjs_proxy.cpp:
1029         (KJSProxyImpl::evaluate):
1030         (KJSProxyImpl::finishedWithEvent):
1031         * khtml/ecma/kjs_proxy.h:
1032         * khtml/ecma/kjs_range.cpp:
1033         (KJS::DOMRange::DOMRange):
1034         (KJS::DOMRange::~DOMRange):
1035         (KJS::DOMRange::tryGet):
1036         (KJS::DOMRange::getValueProperty):
1037         (KJS::DOMRangeProtoFunc::tryCall):
1038         (KJS::getDOMRange):
1039         (KJS::RangeConstructor::tryGet):
1040         (KJS::getRangeConstructor):
1041         (KJS::toRange):
1042         * khtml/ecma/kjs_range.h:
1043         (KJS::DOMRange::impl):
1044         * khtml/ecma/kjs_traversal.cpp:
1045         (KJS::DOMNodeIterator::DOMNodeIterator):
1046         (KJS::DOMNodeIterator::~DOMNodeIterator):
1047         (KJS::DOMNodeIterator::getValueProperty):
1048         (KJS::DOMNodeIteratorProtoFunc::tryCall):
1049         (KJS::getDOMNodeIterator):
1050         (KJS::DOMNodeFilter::DOMNodeFilter):
1051         (KJS::DOMNodeFilter::~DOMNodeFilter):
1052         (KJS::DOMNodeFilterProtoFunc::tryCall):
1053         (KJS::getDOMNodeFilter):
1054         (KJS::toNodeFilter):
1055         (KJS::DOMTreeWalker::DOMTreeWalker):
1056         (KJS::DOMTreeWalker::~DOMTreeWalker):
1057         (KJS::DOMTreeWalker::getValueProperty):
1058         (KJS::DOMTreeWalker::tryPut):
1059         (KJS::DOMTreeWalkerProtoFunc::tryCall):
1060         (KJS::getDOMTreeWalker):
1061         (KJS::JSNodeFilterCondition::acceptNode):
1062         * khtml/ecma/kjs_traversal.h:
1063         (KJS::DOMNodeIterator::impl):
1064         (KJS::DOMNodeFilter::impl):
1065         (KJS::DOMTreeWalker::impl):
1066         * khtml/ecma/kjs_views.cpp:
1067         (KJS::DOMAbstractView::~DOMAbstractView):
1068         (KJS::DOMAbstractView::tryGet):
1069         (KJS::DOMAbstractViewFunc::tryCall):
1070         (KJS::getDOMAbstractView):
1071         (KJS::toAbstractView):
1072         * khtml/ecma/kjs_views.h:
1073         (KJS::DOMAbstractView::DOMAbstractView):
1074         (KJS::DOMAbstractView::impl):
1075         * khtml/ecma/kjs_window.cpp:
1076         (KJS::Window::get):
1077         (KJS::Window::hasProperty):
1078         (KJS::Window::put):
1079         (KJS::Window::setListener):
1080         (KJS::Window::getListener):
1081         (KJS::Window::setCurrentEvent):
1082         (KJS::WindowFunc::tryCall):
1083         (KJS::Location::put):
1084         (KJS::LocationFunc::tryCall):
1085         (KJS::Selection::get):
1086         (KJS::SelectionFunc::tryCall):
1087         * khtml/ecma/kjs_window.h:
1088         * khtml/ecma/xmlhttprequest.cpp:
1089         (KJS::XMLHttpRequestConstructorImp::XMLHttpRequestConstructorImp):
1090         (KJS::XMLHttpRequestConstructorImp::~XMLHttpRequestConstructorImp):
1091         (KJS::XMLHttpRequestConstructorImp::construct):
1092         (KJS::XMLHttpRequest::getValueProperty):
1093         (KJS::XMLHttpRequest::XMLHttpRequest):
1094         (KJS::XMLHttpRequest::changeState):
1095         (KJS::XMLHttpRequest::open):
1096         (KJS::XMLHttpRequestProtoFunc::tryCall):
1097         * khtml/ecma/xmlhttprequest.h:
1098         * khtml/ecma/xmlserializer.cpp:
1099         (KJS::XMLSerializerProtoFunc::tryCall):
1100         * khtml/ecma/xmlserializer.h:
1101         * kwq/DOMInternal.mm:
1102         (-[WebScriptObject _initializeScriptDOMNodeImp]):
1103         * kwq/DOMUtility.mm:
1104         (KJS::ScriptInterpreter::createObjcInstanceForValue):
1105
1106 2005-05-11  David Hyatt  <hyatt@apple.com>
1107
1108         Improve the display of apple.com.  innerWidth and innerHeight refer to the size of the visible view and
1109         so they do not need to do a layout in order to yield correct values from JS.  Removing this stops an
1110         early layout and paint before the apple.com images are typically loaded.
1111
1112         This is an improvement of the fix for wired.com's FOUC.  For that bug I eliminated the need to ignore pending
1113         stylesheets, but now I'm going further and just eliminating the layout all together.  This means that the old
1114         updateLayout function can be reverted to how it was before the wired.com fix.
1115         
1116         Reviewed by john
1117
1118         * khtml/ecma/kjs_window.cpp:
1119         (Window::get):
1120         (Window::updateLayout):
1121         * khtml/ecma/kjs_window.h:
1122
1123 2005-05-11  Maciej Stachowiak  <mjs@apple.com>
1124
1125         Reviewed by Kevin.
1126
1127         - split some more individual classes out of htmlediting.cpp
1128         (CompositeEditcommand, AppendnodeCommand, ApplyStyleCommand)
1129
1130         Also moves StyleChange directly into ApplyStyleCommand
1131         implementation file, it doesn't need to be in a header at all.
1132         
1133         * WebCore.pbproj/project.pbxproj:
1134         * khtml/editing/append_node_command.cpp: Added.
1135         * khtml/editing/append_node_command.h: Added.
1136         * khtml/editing/apply_style_command.cpp: Added.
1137         * khtml/editing/apply_style_command.h: Added.
1138         * khtml/editing/composite_edit_command.cpp: Added.
1139         * khtml/editing/composite_edit_command.h: Added.
1140         * khtml/editing/edit_command.cpp: Minor clean-ups.
1141         * khtml/editing/edit_command.h:
1142         * khtml/editing/htmlediting.cpp:
1143         * khtml/editing/htmlediting.h:
1144
1145 2005-05-11  Adele Peterson  <adele@apple.com>
1146
1147         Reviewed by Darin.
1148
1149         fix for <rdar://problem/4061979> crash in DOM::ElementImpl::setAttribute at www.nitto-kohki.co.jp
1150
1151         * khtml/html/html_imageimpl.cpp: (HTMLImageLoader::updateFromElement): added a nil check for the document
1152         * khtml/xml/dom_nodeimpl.h: (DOM::NodeImpl::inDocument): added check for document in case the document has been destroyed before the node has been removed.  A lot of code already assumes that if inDocument returns true, a document exists.
1153  
1154         * layout-tests/fast/events/onload-re-entry.html: removed alert.
1155         * layout-tests/fast/events/onload-re-entry-expected.txt: updated.
1156         * layout-tests/fast/dom/attr_dead_doc-expected.txt: Added.
1157         * layout-tests/fast/dom/attr_dead_doc.html: Added.
1158         * layout-tests/fast/dom/resources/apple.gif: Added.
1159         * layout-tests/fast/dom/resources/mozilla.gif: Added.
1160         * layout-tests/fast/dom/resources/top.html: Added.
1161
1162 2005-05-10  Maciej Stachowiak  <mjs@apple.com>
1163
1164         Reviewed by Kevin.
1165
1166         - start on splitting htmlediting.cpp into smaller files - pull
1167         EditCommand and EditCommandPtr out.
1168
1169         * WebCore.pbproj/project.pbxproj:
1170         * khtml/editing/edit_command.cpp: Added.
1171         * khtml/editing/edit_command.h: Added.
1172         * khtml/editing/htmlediting.cpp: Took EditCommand and EditCommandPtr out.
1173         * khtml/editing/htmlediting.h: Ditto.
1174
1175 2005-05-10  David Hyatt  <hyatt@apple.com>
1176
1177         Refactor the DOM so that the concept of class/style/id is no longer unique to HTML elements.  This paves the way
1178         for SVG and MathML elements to also support these capabilities.  In addition the concept of presentational
1179         attributes has also been factored out.
1180         
1181         Reviewed by mjs
1182
1183         * khtml/css/css_ruleimpl.cpp:
1184         (CSSStyleRuleImpl::setDeclaration):
1185         * khtml/css/cssstyleselector.cpp:
1186         (khtml::parseUASheet):
1187         (khtml::CSSStyleSelector::loadDefaultStyle):
1188         (khtml::CSSStyleSelector::initElementAndPseudoState):
1189         (khtml::CSSStyleSelector::canShareStyleWithElement):
1190         (khtml::CSSStyleSelector::locateSharedStyle):
1191         (khtml::CSSStyleSelector::styleForElement):
1192         (khtml::CSSStyleSelector::checkOneSelector):
1193         * khtml/css/cssstyleselector.h:
1194         * khtml/html/html_baseimpl.cpp:
1195         (HTMLBodyElementImpl::parseMappedAttribute):
1196         (HTMLFrameElementImpl::parseMappedAttribute):
1197         (HTMLFrameSetElementImpl::parseMappedAttribute):
1198         (HTMLIFrameElementImpl::parseMappedAttribute):
1199         * khtml/html/html_baseimpl.h:
1200         * khtml/html/html_blockimpl.cpp:
1201         (HTMLDivElementImpl::parseMappedAttribute):
1202         (HTMLHRElementImpl::parseMappedAttribute):
1203         (HTMLParagraphElementImpl::parseMappedAttribute):
1204         (HTMLMarqueeElementImpl::parseMappedAttribute):
1205         * khtml/html/html_blockimpl.h:
1206         * khtml/html/html_canvasimpl.cpp:
1207         (HTMLCanvasElementImpl::parseMappedAttribute):
1208         * khtml/html/html_canvasimpl.h:
1209         * khtml/html/html_elementimpl.cpp:
1210         (HTMLElementImpl::HTMLElementImpl):
1211         (HTMLElementImpl::~HTMLElementImpl):
1212         (HTMLElementImpl::mapToEntry):
1213         (HTMLElementImpl::parseMappedAttribute):
1214         (HTMLElementImpl::addHTMLAlignment):
1215         (HTMLElementImpl::setContentEditable):
1216         (HTMLElementImpl::toString):
1217         * khtml/html/html_elementimpl.h:
1218         * khtml/html/html_formimpl.cpp:
1219         (DOM::HTMLFormElementImpl::parseMappedAttribute):
1220         (DOM::HTMLGenericFormElementImpl::parseMappedAttribute):
1221         (DOM::HTMLButtonElementImpl::parseMappedAttribute):
1222         (DOM::HTMLInputElementImpl::setType):
1223         (DOM::HTMLInputElementImpl::parseMappedAttribute):
1224         (DOM::HTMLLabelElementImpl::parseMappedAttribute):
1225         (DOM::HTMLSelectElementImpl::parseMappedAttribute):
1226         (DOM::HTMLKeygenElementImpl::parseMappedAttribute):
1227         (DOM::HTMLOptGroupElementImpl::parseMappedAttribute):
1228         (DOM::HTMLOptionElementImpl::parseMappedAttribute):
1229         (DOM::HTMLTextAreaElementImpl::parseMappedAttribute):
1230         (DOM::HTMLIsIndexElementImpl::parseMappedAttribute):
1231         * khtml/html/html_formimpl.h:
1232         * khtml/html/html_headimpl.cpp:
1233         (HTMLBaseElementImpl::parseMappedAttribute):
1234         (HTMLLinkElementImpl::parseMappedAttribute):
1235         (HTMLMetaElementImpl::parseMappedAttribute):
1236         (HTMLStyleElementImpl::parseMappedAttribute):
1237         * khtml/html/html_headimpl.h:
1238         * khtml/html/html_imageimpl.cpp:
1239         (HTMLImageElementImpl::parseMappedAttribute):
1240         (HTMLMapElementImpl::parseMappedAttribute):
1241         (HTMLAreaElementImpl::parseMappedAttribute):
1242         * khtml/html/html_imageimpl.h:
1243         * khtml/html/html_inlineimpl.cpp:
1244         (DOM::HTMLAnchorElementImpl::parseMappedAttribute):
1245         (DOM::HTMLBRElementImpl::parseMappedAttribute):
1246         (DOM::HTMLFontElementImpl::parseMappedAttribute):
1247         * khtml/html/html_inlineimpl.h:
1248         * khtml/html/html_listimpl.cpp:
1249         (DOM::HTMLUListElementImpl::parseMappedAttribute):
1250         (DOM::HTMLOListElementImpl::parseMappedAttribute):
1251         (DOM::HTMLLIElementImpl::parseMappedAttribute):
1252         * khtml/html/html_listimpl.h:
1253         * khtml/html/html_objectimpl.cpp:
1254         (DOM::HTMLAppletElementImpl::parseMappedAttribute):
1255         (DOM::HTMLEmbedElementImpl::parseMappedAttribute):
1256         (DOM::HTMLObjectElementImpl::parseMappedAttribute):
1257         (DOM::HTMLParamElementImpl::parseMappedAttribute):
1258         * khtml/html/html_objectimpl.h:
1259         * khtml/html/html_tableimpl.cpp:
1260         (DOM::HTMLTableElementImpl::parseMappedAttribute):
1261         (DOM::HTMLTableElementImpl::additionalAttributeStyleDecl):
1262         (DOM::HTMLTableElementImpl::getSharedCellDecl):
1263         (DOM::HTMLTablePartElementImpl::parseMappedAttribute):
1264         (DOM::HTMLTableCellElementImpl::parseMappedAttribute):
1265         (DOM::HTMLTableColElementImpl::parseMappedAttribute):
1266         (DOM::HTMLTableCaptionElementImpl::parseMappedAttribute):
1267         * khtml/html/html_tableimpl.h:
1268         * khtml/html/htmltokenizer.h:
1269         (khtml::Token::addAttribute):
1270         * khtml/misc/htmlattrs.in:
1271         * khtml/misc/htmltags.in:
1272         * khtml/xml/dom_docimpl.cpp:
1273         (DocumentImpl::createAttribute):
1274         (DocumentImpl::createElementNS):
1275         (DocumentImpl::createHTMLElement):
1276         * khtml/xml/dom_elementimpl.cpp:
1277         (XMLElementImpl::cloneNode):
1278         (NamedAttrMapImpl::isMappedAttributeMap):
1279         (CSSMappedAttributeDeclarationImpl::~CSSMappedAttributeDeclarationImpl):
1280         (StyledElementImpl::getMappedAttributeDecl):
1281         (StyledElementImpl::setMappedAttributeDecl):
1282         (StyledElementImpl::removeMappedAttributeDecl):
1283         (StyledElementImpl::invalidateStyleAttribute):
1284         (StyledElementImpl::updateStyleAttributeIfNeeded):
1285         (MappedAttributeImpl::~MappedAttributeImpl):
1286         (MappedAttributeImpl::clone):
1287         (m_mappedAttributeCount):
1288         (NamedMappedAttrMapImpl::clearAttributes):
1289         (NamedMappedAttrMapImpl::isMappedAttributeMap):
1290         (NamedMappedAttrMapImpl::declCount):
1291         (NamedMappedAttrMapImpl::mapsEquivalent):
1292         (NamedMappedAttrMapImpl::parseClassAttribute):
1293         (StyledElementImpl::StyledElementImpl):
1294         (StyledElementImpl::~StyledElementImpl):
1295         (StyledElementImpl::createAttribute):
1296         (StyledElementImpl::createInlineStyleDecl):
1297         (StyledElementImpl::destroyInlineStyleDecl):
1298         (StyledElementImpl::attributeChanged):
1299         (StyledElementImpl::mapToEntry):
1300         (StyledElementImpl::parseMappedAttribute):
1301         (StyledElementImpl::createAttributeMap):
1302         (StyledElementImpl::getInlineStyleDecl):
1303         (StyledElementImpl::style):
1304         (StyledElementImpl::additionalAttributeStyleDecl):
1305         (StyledElementImpl::getClassList):
1306         (isHexDigit):
1307         (toHex):
1308         (StyledElementImpl::addCSSProperty):
1309         (StyledElementImpl::addCSSStringProperty):
1310         (StyledElementImpl::addCSSImageProperty):
1311         (StyledElementImpl::addCSSLength):
1312         (StyledElementImpl::addCSSColor):
1313         (StyledElementImpl::createMappedDecl):
1314         * khtml/xml/dom_elementimpl.h:
1315         (DOM::):
1316         (DOM::CSSMappedAttributeDeclarationImpl::CSSMappedAttributeDeclarationImpl):
1317         (DOM::CSSMappedAttributeDeclarationImpl::setMappedState):
1318         (DOM::MappedAttributeImpl::MappedAttributeImpl):
1319         (DOM::MappedAttributeImpl::decl):
1320         (DOM::MappedAttributeImpl::setDecl):
1321         (DOM::NamedMappedAttrMapImpl::getClassList):
1322         (DOM::NamedMappedAttrMapImpl::hasMappedAttributes):
1323         (DOM::NamedMappedAttrMapImpl::declRemoved):
1324         (DOM::NamedMappedAttrMapImpl::declAdded):
1325         (DOM::NamedMappedAttrMapImpl::attributeItem):
1326         (DOM::StyledElementImpl::isStyledElement):
1327         (DOM::StyledElementImpl::hasMappedAttributes):
1328         (DOM::StyledElementImpl::mappedAttributes):
1329         (DOM::StyledElementImpl::isMappedAttribute):
1330         (DOM::StyledElementImpl::inlineStyleDecl):
1331         * khtml/xml/dom_nodeimpl.h:
1332         (DOM::NodeImpl::isStyledElement):
1333
1334 2005-05-10  Darin Adler  <darin@apple.com>
1335
1336         Reviewed by Dave Hyatt.
1337         No new layout tests needed.
1338
1339         - remove all remaining uses of QMIN/QMAX and KMIN/KMAX.
1340
1341         * kwq/KWQDef.h: Remove the macros.
1342
1343         Remove all use of the macros (and fix a few compile errors by changing the types of
1344         some integer and floating point constants).
1345
1346         * khtml/css/cssparser.cpp:
1347         (CSSParser::parseColorFromValue):
1348         * khtml/css/cssstyleselector.cpp:
1349         (khtml::CSSStyleSelector::getComputedSizeFromSpecifiedSize):
1350         * khtml/html/html_elementimpl.cpp:
1351         (HTMLElementImpl::addHTMLColor):
1352         * khtml/html/html_formimpl.cpp:
1353         (DOM::HTMLSelectElementImpl::parseHTMLAttribute):
1354         * khtml/html/htmltokenizer.cpp:
1355         (khtml::HTMLTokenizer::parseComment):
1356         * khtml/rendering/render_block.cpp:
1357         (khtml::RenderBlock::nearestFloatBottom):
1358         (khtml::RenderBlock::calcMinMaxWidth):
1359         * khtml/rendering/render_flow.cpp:
1360         (RenderFlow::paintOutlineForLine):
1361         * khtml/rendering/render_form.cpp:
1362         (RenderLineEdit::calcMinMaxWidth):
1363         (RenderFieldset::layoutLegend):
1364         (RenderFileButton::calcMinMaxWidth):
1365         (RenderSelect::layout):
1366         (RenderTextArea::calcMinMaxWidth):
1367         * khtml/rendering/render_object.cpp:
1368         (RenderObject::drawBorder):
1369         * khtml/rendering/render_replaced.cpp:
1370         (RenderWidget::resizeWidget):
1371         * khtml/rendering/render_table.cpp:
1372         (RenderTableSection::layoutRows):
1373         * khtml/rendering/table_layout.cpp:
1374         (AutoTableLayout::recalcColumn):
1375         (AutoTableLayout::calcEffectiveWidth):
1376
1377 2005-05-10  Darin Adler  <darin@apple.com>
1378
1379         Reviewed by Chris Blumenberg.
1380
1381         - next pass of moving code from C++ DOM wrappers into the DOM impl. classes
1382           (this step adds still more member functions missing from the DOM impl. and
1383            changes some of the C++ and Objective-C DOM to call the new ones; also
1384            changes various places that use the C++ DOM to use the DOM impl. instead)
1385
1386         * khtml/css/css_computedstyle.cpp:
1387         (DOM::CSSComputedStyleDeclarationImpl::getPropertyCSSValue):
1388         * khtml/css/css_computedstyle.h:
1389         * khtml/css/css_stylesheetimpl.cpp:
1390         (CSSStyleSheetImpl::cssRules):
1391         * khtml/css/css_stylesheetimpl.h:
1392         * khtml/css/css_valueimpl.cpp:
1393         (DOM::CSSStyleDeclarationImpl::getPropertyCSSValue):
1394         (DOM::CSSStyleDeclarationImpl::getPropertyValue):
1395         (DOM::CSSStyleDeclarationImpl::getPropertyPriority):
1396         (DOM::CSSStyleDeclarationImpl::setProperty):
1397         (DOM::CSSStyleDeclarationImpl::removeProperty):
1398         (DOM::CSSMutableStyleDeclarationImpl::getPropertyValue):
1399         (DOM::CSSPrimitiveValueImpl::CSSPrimitiveValueImpl):
1400         (DOM::operator==):
1401         (DOM::CSSStyleDeclarationImpl::propertyID):
1402         * khtml/css/css_valueimpl.h:
1403         (DOM::CSSValueImpl::setCssText):
1404         (DOM::CSSPrimitiveValueImpl::getDashboardRegionValue):
1405         * khtml/dom/css_rule.cpp:
1406         * khtml/dom/css_rule.h:
1407         * khtml/dom/css_stylesheet.h:
1408         (DOM::CSSException::):
1409         * khtml/dom/css_value.cpp:
1410         (DOM::CSSStyleDeclaration::getPropertyValue):
1411         (DOM::CSSStyleDeclaration::getPropertyCSSValue):
1412         (DOM::CSSStyleDeclaration::removeProperty):
1413         (DOM::CSSStyleDeclaration::getPropertyPriority):
1414         (DOM::CSSStyleDeclaration::setProperty):
1415         * khtml/dom/css_value.h:
1416         * khtml/dom/dom2_events.cpp:
1417         (EventListener::handleEvent):
1418         * khtml/dom/dom2_events.h:
1419         * khtml/dom/dom2_traversal.h:
1420         * khtml/dom/dom_doc.cpp:
1421         (DOM::DOMImplementation::createHTMLDocument):
1422         (DOM::DOMImplementation::createCSSStyleSheet):
1423         (DOM::Document::doctype):
1424         (DOM::Document::createAttribute):
1425         (DOM::Document::createAttributeNS):
1426         (DOM::Document::queryCommandValue):
1427         (DOM::Document::handle):
1428         * khtml/dom/dom_doc.h:
1429         * khtml/dom/dom_element.cpp:
1430         (Attr::name):
1431         (Attr::value):
1432         (Element::getAttribute):
1433         (Element::setAttribute):
1434         (Element::removeAttribute):
1435         (Element::getAttributeNode):
1436         (Element::setAttributeNode):
1437         (Element::removeAttributeNode):
1438         (Element::getElementsByTagName):
1439         (Element::getElementsByTagNameNS):
1440         (Element::getAttributeNS):
1441         (Element::setAttributeNS):
1442         (Element::removeAttributeNS):
1443         (Element::getAttributeNodeNS):
1444         (Element::setAttributeNodeNS):
1445         (Element::hasAttribute):
1446         (Element::hasAttributeNS):
1447         (Element::style):
1448         * khtml/dom/dom_exception.h:
1449         * khtml/dom/dom_misc.cpp:
1450         (DOM::DomShared::deleteMe):
1451         * khtml/dom/dom_misc.h:
1452         (DOM::DomShared::deleteMe):
1453         * khtml/dom/dom_node.cpp:
1454         (NamedNodeMap::getNamedItemNS):
1455         (NamedNodeMap::setNamedItemNS):
1456         (NamedNodeMap::removeNamedItemNS):
1457         (Node::ownerDocument):
1458         (Node::hasAttributes):
1459         (Node::isSupported):
1460         (Node::addEventListener):
1461         (Node::removeEventListener):
1462         * khtml/dom/dom_node.h:
1463         * khtml/dom/html_document.cpp:
1464         (HTMLDocument::setTitle):
1465         (HTMLDocument::completeURL):
1466         (HTMLDocument::getElementsByName):
1467         * khtml/dom/html_element.cpp:
1468         (HTMLElement::setInnerHTML):
1469         (HTMLElement::setInnerText):
1470         (HTMLElement::setOuterHTML):
1471         (HTMLElement::setOuterText):
1472         * khtml/dom/html_form.cpp:
1473         (HTMLLabelElement::form):
1474         (HTMLSelectElement::setValue):
1475         (HTMLSelectElement::options):
1476         (HTMLOptionElement::setValue):
1477         * khtml/dom/html_inline.cpp:
1478         (HTMLAnchorElement::accessKey):
1479         (HTMLAnchorElement::setAccessKey):
1480         (HTMLAnchorElement::charset):
1481         (HTMLAnchorElement::setCharset):
1482         (HTMLAnchorElement::coords):
1483         (HTMLAnchorElement::setCoords):
1484         (HTMLAnchorElement::href):
1485         (HTMLAnchorElement::setHref):
1486         (HTMLAnchorElement::hreflang):
1487         (HTMLAnchorElement::setHreflang):
1488         (HTMLAnchorElement::name):
1489         (HTMLAnchorElement::setName):
1490         (HTMLAnchorElement::rel):
1491         (HTMLAnchorElement::setRel):
1492         (HTMLAnchorElement::rev):
1493         (HTMLAnchorElement::setRev):
1494         (HTMLAnchorElement::shape):
1495         (HTMLAnchorElement::setShape):
1496         (HTMLAnchorElement::tabIndex):
1497         (HTMLAnchorElement::setTabIndex):
1498         (HTMLAnchorElement::target):
1499         (HTMLAnchorElement::setTarget):
1500         (HTMLAnchorElement::type):
1501         (HTMLAnchorElement::setType):
1502         (HTMLAnchorElement::blur):
1503         (HTMLAnchorElement::focus):
1504         (HTMLBRElement::clear):
1505         (HTMLBRElement::setClear):
1506         (HTMLFontElement::color):
1507         (HTMLFontElement::setColor):
1508         (HTMLFontElement::face):
1509         (HTMLFontElement::setFace):
1510         (HTMLFontElement::size):
1511         (HTMLFontElement::setSize):
1512         (HTMLModElement::cite):
1513         (HTMLModElement::setCite):
1514         (HTMLModElement::dateTime):
1515         (HTMLModElement::setDateTime):
1516         (HTMLQuoteElement::cite):
1517         (HTMLQuoteElement::setCite):
1518         * khtml/dom/html_misc.cpp:
1519         (HTMLCollection::HTMLCollection):
1520         (HTMLCollection::base):
1521         (HTMLCollection::namedItems):
1522         * khtml/dom/html_misc.h:
1523         * khtml/editing/htmlediting.cpp:
1524         * khtml/editing/selection.cpp:
1525         * khtml/html/html_documentimpl.cpp:
1526         (DOM::HTMLDocumentImpl::determineParseMode):
1527         (DOM::HTMLDocumentImpl::doctype):
1528         * khtml/html/html_documentimpl.h:
1529         * khtml/html/html_elementimpl.cpp:
1530         (HTMLElementImpl::setInnerHTML):
1531         (HTMLElementImpl::setOuterHTML):
1532         (HTMLElementImpl::setInnerText):
1533         (HTMLElementImpl::setOuterText):
1534         (HTMLElementImpl::style):
1535         (HTMLElementImpl::idDOM):
1536         (HTMLElementImpl::setId):
1537         (HTMLElementImpl::title):
1538         (HTMLElementImpl::setTitle):
1539         (HTMLElementImpl::lang):
1540         (HTMLElementImpl::setLang):
1541         (HTMLElementImpl::dir):
1542         (HTMLElementImpl::setDir):
1543         (HTMLElementImpl::className):
1544         (HTMLElementImpl::setClassName):
1545         (HTMLElementImpl::children):
1546         (HTMLGenericElementImpl::HTMLGenericElementImpl):
1547         (HTMLGenericElementImpl::id):
1548         * khtml/html/html_elementimpl.h:
1549         (DOM::HTMLElementImpl::isGenericFormElement):
1550         * khtml/html/html_formimpl.cpp:
1551         (DOM::HTMLFormElementImpl::parseEnctype):
1552         (DOM::HTMLFormElementImpl::parseHTMLAttribute):
1553         (DOM::HTMLFormElementImpl::elements):
1554         (DOM::HTMLFormElementImpl::name):
1555         (DOM::HTMLFormElementImpl::setName):
1556         (DOM::HTMLFormElementImpl::acceptCharset):
1557         (DOM::HTMLFormElementImpl::setAcceptCharset):
1558         (DOM::HTMLFormElementImpl::action):
1559         (DOM::HTMLFormElementImpl::setAction):
1560         (DOM::HTMLFormElementImpl::setEnctype):
1561         (DOM::HTMLFormElementImpl::method):
1562         (DOM::HTMLFormElementImpl::setMethod):
1563         (DOM::HTMLFormElementImpl::target):
1564         (DOM::HTMLFormElementImpl::setTarget):
1565         (DOM::HTMLGenericFormElementImpl::HTMLGenericFormElementImpl):
1566         (DOM::HTMLGenericFormElementImpl::~HTMLGenericFormElementImpl):
1567         (DOM::HTMLGenericFormElementImpl::parseHTMLAttribute):
1568         (DOM::HTMLGenericFormElementImpl::name):
1569         (DOM::HTMLGenericFormElementImpl::setName):
1570         (DOM::HTMLGenericFormElementImpl::setOverrideName):
1571         (DOM::HTMLGenericFormElementImpl::setDisabled):
1572         (DOM::HTMLGenericFormElementImpl::setReadOnly):
1573         (DOM::HTMLGenericFormElementImpl::tabIndex):
1574         (DOM::HTMLGenericFormElementImpl::setTabIndex):
1575         (DOM::HTMLButtonElementImpl::accessKey):
1576         (DOM::HTMLButtonElementImpl::setAccessKey):
1577         (DOM::HTMLButtonElementImpl::value):
1578         (DOM::HTMLButtonElementImpl::setValue):
1579         (DOM::HTMLInputElementImpl::HTMLInputElementImpl):
1580         (DOM::HTMLInputElementImpl::parseHTMLAttribute):
1581         (DOM::HTMLInputElementImpl::defaultValue):
1582         (DOM::HTMLInputElementImpl::setDefaultValue):
1583         (DOM::HTMLInputElementImpl::defaultChecked):
1584         (DOM::HTMLInputElementImpl::setDefaultChecked):
1585         (DOM::HTMLInputElementImpl::accept):
1586         (DOM::HTMLInputElementImpl::setAccept):
1587         (DOM::HTMLInputElementImpl::accessKey):
1588         (DOM::HTMLInputElementImpl::setAccessKey):
1589         (DOM::HTMLInputElementImpl::align):
1590         (DOM::HTMLInputElementImpl::setAlign):
1591         (DOM::HTMLInputElementImpl::alt):
1592         (DOM::HTMLInputElementImpl::setAlt):
1593         (DOM::HTMLInputElementImpl::setMaxLength):
1594         (DOM::HTMLInputElementImpl::sizeDOM):
1595         (DOM::HTMLInputElementImpl::setSize):
1596         (DOM::HTMLInputElementImpl::src):
1597         (DOM::HTMLInputElementImpl::setSrc):
1598         (DOM::HTMLInputElementImpl::useMap):
1599         (DOM::HTMLInputElementImpl::setUseMap):
1600         (DOM::HTMLLabelElementImpl::form):
1601         (DOM::HTMLLabelElementImpl::accessKey):
1602         (DOM::HTMLLabelElementImpl::setAccessKey):
1603         (DOM::HTMLLabelElementImpl::htmlFor):
1604         (DOM::HTMLLabelElementImpl::setHtmlFor):
1605         (DOM::HTMLLegendElementImpl::accessKey):
1606         (DOM::HTMLLegendElementImpl::setAccessKey):
1607         (DOM::HTMLLegendElementImpl::align):
1608         (DOM::HTMLLegendElementImpl::setAlign):
1609         (DOM::HTMLSelectElementImpl::setValue):
1610         (DOM::HTMLSelectElementImpl::optionsHTMLCollection):
1611         (DOM::HTMLSelectElementImpl::setMultiple):
1612         (DOM::HTMLSelectElementImpl::setSize):
1613         (DOM::HTMLOptGroupElementImpl::label):
1614         (DOM::HTMLOptGroupElementImpl::setLabel):
1615         (DOM::HTMLOptionElementImpl::setText):
1616         (DOM::HTMLOptionElementImpl::setIndex):
1617         (DOM::HTMLOptionElementImpl::setValue):
1618         (DOM::HTMLOptionElementImpl::defaultSelected):
1619         (DOM::HTMLOptionElementImpl::setDefaultSelected):
1620         (DOM::HTMLOptionElementImpl::label):
1621         (DOM::HTMLOptionElementImpl::setLabel):
1622         (DOM::HTMLTextAreaElementImpl::accessKey):
1623         (DOM::HTMLTextAreaElementImpl::setAccessKey):
1624         (DOM::HTMLTextAreaElementImpl::setCols):
1625         (DOM::HTMLTextAreaElementImpl::setRows):
1626         (DOM::HTMLIsIndexElementImpl::HTMLIsIndexElementImpl):
1627         (DOM::HTMLIsIndexElementImpl::parseHTMLAttribute):
1628         (DOM::HTMLIsIndexElementImpl::prompt):
1629         (DOM::HTMLIsIndexElementImpl::setPrompt):
1630         * khtml/html/html_formimpl.h:
1631         * khtml/html/html_headimpl.cpp:
1632         (HTMLBaseElementImpl::setHref):
1633         (HTMLBaseElementImpl::setTarget):
1634         (HTMLLinkElementImpl::disabled):
1635         (HTMLLinkElementImpl::setDisabled):
1636         (HTMLLinkElementImpl::charset):
1637         (HTMLLinkElementImpl::setCharset):
1638         (HTMLLinkElementImpl::href):
1639         (HTMLLinkElementImpl::setHref):
1640         (HTMLLinkElementImpl::hreflang):
1641         (HTMLLinkElementImpl::setHreflang):
1642         (HTMLLinkElementImpl::media):
1643         (HTMLLinkElementImpl::setMedia):
1644         (HTMLLinkElementImpl::rel):
1645         (HTMLLinkElementImpl::setRel):
1646         (HTMLLinkElementImpl::rev):
1647         (HTMLLinkElementImpl::setRev):
1648         (HTMLLinkElementImpl::target):
1649         (HTMLLinkElementImpl::setTarget):
1650         (HTMLLinkElementImpl::type):
1651         (HTMLLinkElementImpl::setType):
1652         (HTMLMetaElementImpl::content):
1653         (HTMLMetaElementImpl::setContent):
1654         (HTMLMetaElementImpl::httpEquiv):
1655         (HTMLMetaElementImpl::setHttpEquiv):
1656         (HTMLMetaElementImpl::name):
1657         (HTMLMetaElementImpl::setName):
1658         (HTMLMetaElementImpl::scheme):
1659         (HTMLMetaElementImpl::setScheme):
1660         (HTMLScriptElementImpl::id):
1661         (HTMLScriptElementImpl::isURLAttribute):
1662         (HTMLScriptElementImpl::insertedIntoDocument):
1663         (HTMLScriptElementImpl::notifyFinished):
1664         (HTMLScriptElementImpl::text):
1665         (HTMLScriptElementImpl::setText):
1666         (HTMLScriptElementImpl::htmlFor):
1667         (HTMLScriptElementImpl::setHtmlFor):
1668         (HTMLScriptElementImpl::event):
1669         (HTMLScriptElementImpl::setEvent):
1670         (HTMLScriptElementImpl::charset):
1671         (HTMLScriptElementImpl::setCharset):
1672         (HTMLScriptElementImpl::defer):
1673         (HTMLScriptElementImpl::setDefer):
1674         (HTMLScriptElementImpl::src):
1675         (HTMLScriptElementImpl::setSrc):
1676         (HTMLScriptElementImpl::type):
1677         (HTMLScriptElementImpl::setType):
1678         (HTMLStyleElementImpl::disabled):
1679         (HTMLStyleElementImpl::setDisabled):
1680         (HTMLStyleElementImpl::media):
1681         (HTMLStyleElementImpl::setMedia):
1682         (HTMLStyleElementImpl::type):
1683         (HTMLStyleElementImpl::setType):
1684         (HTMLTitleElementImpl::insertedIntoDocument):
1685         (HTMLTitleElementImpl::childrenChanged):
1686         (HTMLTitleElementImpl::text):
1687         (HTMLTitleElementImpl::setText):
1688         * khtml/html/html_headimpl.h:
1689         * khtml/html/html_miscimpl.cpp:
1690         (DOM::HTMLBaseFontElementImpl::id):
1691         (DOM::HTMLBaseFontElementImpl::color):
1692         (DOM::HTMLBaseFontElementImpl::setColor):
1693         (DOM::HTMLBaseFontElementImpl::face):
1694         (DOM::HTMLBaseFontElementImpl::setFace):
1695         (DOM::HTMLBaseFontElementImpl::size):
1696         (DOM::HTMLBaseFontElementImpl::setSize):
1697         (DOM::HTMLCollectionImpl::HTMLCollectionImpl):
1698         (DOM::HTMLCollectionImpl::~HTMLCollectionImpl):
1699         (DOM::HTMLCollectionImpl::resetCollectionInfo):
1700         (DOM::HTMLCollectionImpl::traverseNextItem):
1701         (DOM::HTMLCollectionImpl::calcLength):
1702         (DOM::HTMLCollectionImpl::item):
1703         (DOM::HTMLCollectionImpl::namedItem):
1704         (DOM::HTMLCollectionImpl::updateNameCache):
1705         (DOM::HTMLCollectionImpl::namedItems):
1706         (DOM::HTMLCollectionImpl::nextNamedItem):
1707         (DOM::HTMLFormCollectionImpl::HTMLFormCollectionImpl):
1708         (DOM::HTMLFormCollectionImpl::calcLength):
1709         (DOM::HTMLFormCollectionImpl::item):
1710         (DOM::HTMLFormCollectionImpl::getNamedFormItem):
1711         (DOM::HTMLFormCollectionImpl::nextNamedItemInternal):
1712         (DOM::HTMLFormCollectionImpl::namedItem):
1713         (DOM::HTMLFormCollectionImpl::updateNameCache):
1714         * khtml/html/html_miscimpl.h:
1715         (DOM::HTMLCollectionImpl::base):
1716         * khtml/html/htmlparser.cpp:
1717         (KHTMLParser::parseToken):
1718         (KHTMLParser::insertNode):
1719         * khtml/html/htmltokenizer.cpp:
1720         (khtml::HTMLTokenizer::scriptExecution):
1721         * khtml/khtml_events.cpp:
1722         (khtml::MouseEvent::MouseEvent):
1723         (khtml::MouseEvent::offset):
1724         * khtml/khtml_events.h:
1725         (khtml::MouseEvent::innerNode):
1726         (khtml::MousePressEvent::MousePressEvent):
1727         (khtml::MouseDoubleClickEvent::MouseDoubleClickEvent):
1728         (khtml::MouseMoveEvent::MouseMoveEvent):
1729         (khtml::MouseReleaseEvent::MouseReleaseEvent):
1730         * khtml/khtml_part.cpp:
1731         (KHTMLPart::closeURL):
1732         (KHTMLPart::executeScript):
1733         (KHTMLPart::scheduleScript):
1734         (KHTMLPart::executeScheduledScript):
1735         (KHTMLPart::clear):
1736         (KHTMLPart::selectClosestWordFromMouseEvent):
1737         (KHTMLPart::handleMousePressEventDoubleClick):
1738         (KHTMLPart::handleMousePressEventTripleClick):
1739         (KHTMLPart::handleMousePressEventSingleClick):
1740         (KHTMLPart::khtmlMousePressEvent):
1741         (KHTMLPart::handleMouseMoveEventDrag):
1742         (KHTMLPart::handleMouseMoveEventOver):
1743         (KHTMLPart::handleMouseMoveEventSelection):
1744         (KHTMLPart::khtmlMouseReleaseEvent):
1745         (KHTMLPart::selectionHasStyle):
1746         (KHTMLPart::selectionStartHasStyle):
1747         * khtml/khtml_part.h:
1748         * khtml/khtmlpart_p.h:
1749         * khtml/khtmlview.cpp:
1750         (KHTMLViewPrivate::reset):
1751         (KHTMLView::viewportMousePressEvent):
1752         (KHTMLView::viewportMouseDoubleClickEvent):
1753         (KHTMLView::contentsContextMenuEvent):
1754         (KHTMLView::updateDragAndDrop):
1755         (KHTMLView::cancelDragAndDrop):
1756         (KHTMLView::performDragAndDrop):
1757         (KHTMLView::focusNextPrevNode):
1758         * kwq/DOM-CSS.mm:
1759         (-[DOMCSSStyleSheet cssRules]):
1760         (-[DOMCSSStyleDeclaration getPropertyValue:]):
1761         (-[DOMCSSStyleDeclaration getPropertyCSSValue:]):
1762         (-[DOMCSSStyleDeclaration removeProperty:]):
1763         (-[DOMCSSStyleDeclaration getPropertyPriority:]):
1764         (-[DOMCSSStyleDeclaration setProperty:::]):
1765         (-[DOMCSSValue setCssText:]):
1766         * kwq/DOMCSS.h:
1767         * kwq/DOMHTML.mm:
1768         (-[DOMHTMLElement setInnerHTML:]):
1769         (-[DOMHTMLElement setOuterHTML:]):
1770         (-[DOMHTMLElement setInnerText:]):
1771         (-[DOMHTMLElement setOuterText:]):
1772         (-[DOMHTMLSelectElement setLength:]):
1773         (-[DOMHTMLTableSectionElement insertRow:]):
1774         * kwq/DOMInternal.h:
1775         * kwq/DOMInternal.mm:
1776         (raiseDOMException):
1777         (-[WebScriptObject _initializeScriptDOMNodeImp]):
1778         * kwq/DOMUtility.mm:
1779         (KJS::ScriptInterpreter::createObjcInstanceForValue):
1780         * kwq/KWQAccObject.mm:
1781         (-[KWQAccObject accessibilityAttributeValue:]):
1782         * kwq/KWQKHTMLPart.h:
1783         * kwq/KWQKHTMLPart.mm:
1784         (KWQKHTMLPart::KWQKHTMLPart):
1785         (KWQKHTMLPart::advanceToNextMisspelling):
1786         (KWQKHTMLPart::scrollOverflow):
1787         (KWQKHTMLPart::paint):
1788         (KWQKHTMLPart::openURLFromPageCache):
1789         (KWQKHTMLPart::khtmlMousePressEvent):
1790         (KWQKHTMLPart::passWidgetMouseDownEventToWidget):
1791         (KWQKHTMLPart::dispatchDragSrcEvent):
1792         (KWQKHTMLPart::eventMayStartDrag):
1793         (KWQKHTMLPart::khtmlMouseMoveEvent):
1794         (KWQKHTMLPart::dragSourceEndedAt):
1795         (KWQKHTMLPart::mouseDown):
1796         (KWQKHTMLPart::sendContextMenuEvent):
1797         (listParent):
1798         (isTextFirstInListItem):
1799         (KWQKHTMLPart::attributedString):
1800         (KWQKHTMLPart::snapshotDragImage):
1801         (KWQKHTMLPart::mousePressNode):
1802         * kwq/WebCoreBridge.mm:
1803         (updateRenderingForBindings):
1804         (-[WebCoreBridge _documentTypeString]):
1805
1806 2005-05-10  Maciej Stachowiak  <mjs@apple.com>
1807
1808         Reviewed by John.
1809
1810         - rename hasAnchor method to isLink
1811
1812         * khtml/css/cssstyleselector.cpp:
1813         (khtml::checkPseudoState):
1814         (khtml::CSSStyleSelector::canShareStyleWithElement):
1815         (khtml::CSSStyleSelector::styleForElement):
1816         (khtml::CSSStyleSelector::checkOneSelector):
1817         * khtml/editing/htmlediting.cpp:
1818         (khtml::isSpecialElement):
1819         * khtml/html/html_imageimpl.cpp:
1820         (HTMLImageElementImpl::parseHTMLAttribute):
1821         * khtml/html/html_inlineimpl.cpp:
1822         (DOM::HTMLAnchorElementImpl::isFocusable):
1823         (DOM::HTMLAnchorElementImpl::defaultEventHandler):
1824         (DOM::HTMLAnchorElementImpl::parseHTMLAttribute):
1825         * khtml/rendering/render_flexbox.cpp:
1826         (khtml::RenderFlexibleBox::layoutVerticalBox):
1827         * khtml/rendering/render_layer.cpp:
1828         (RenderLayer::hitTest):
1829         * khtml/rendering/render_object.cpp:
1830         (RenderObject::information):
1831         * khtml/xml/dom_nodeimpl.cpp:
1832         (NodeImpl::NodeImpl):
1833         * khtml/xml/dom_nodeimpl.h:
1834         (DOM::NodeImpl::isLink):
1835         * kwq/KWQAccObject.mm:
1836         (-[KWQAccObject anchorElement]):
1837         (-[KWQAccObject addChildrenToArray:]):
1838         (-[KWQAccObject role]):
1839         (-[KWQAccObject title]):
1840         (-[KWQAccObject accessibilityIsIgnored]):
1841         (-[KWQAccObject accessibilityAttributeNames]):
1842         (-[KWQAccObject accessibilityAttributeValue:]):
1843         * kwq/KWQKHTMLPart.mm:
1844         (KWQKHTMLPart::khtmlMouseMoveEvent):
1845
1846 2005-05-09  Maciej Stachowiak  <mjs@apple.com>
1847
1848         Reviewed by John.
1849
1850         - remove init hint argument from VisiblePosition 
1851
1852         * khtml/editing/visible_position.cpp:
1853         (khtml::VisiblePosition::VisiblePosition):
1854         (khtml::VisiblePosition::init):
1855         * khtml/editing/visible_position.h:
1856         * khtml/editing/visible_units.cpp:
1857         (khtml::previousBoundary):
1858         (khtml::nextBoundary):
1859         * khtml/xml/dom_docimpl.cpp:
1860         (DocumentImpl::updateSelection):
1861         * kwq/KWQKHTMLPart.mm:
1862         (KWQKHTMLPart::styleForSelectionStart):
1863         * kwq/WebCoreBridge.mm:
1864         (-[WebCoreBridge setSelectedDOMRange:affinity:closeTyping:]):
1865
1866 2005-05-10  Darin Adler  <darin@apple.com>
1867
1868         Reviewed by David Harrison.
1869
1870         - next pass of moving code from C++ DOM wrappers into the DOM impl. classes
1871           (this step adds more member functions missing from the DOM impl. and
1872            changes some of the Objective-C DOM to call the new ones; also changes some
1873            parameter types in the DOM impl.)
1874
1875         * khtml/dom/dom2_events.cpp:
1876         (UIEvent::initUIEvent):
1877         (MouseEvent::initMouseEvent):
1878         (MutationEvent::initMutationEvent):
1879         (KeyboardEvent::initKeyboardEvent):
1880         * khtml/dom/dom_doc.cpp:
1881         (DOM::DOMImplementation::createDocument):
1882         (DOM::Document::getElementsByTagName):
1883         (DOM::Document::getElementsByTagNameNS):
1884         * khtml/dom/dom_element.cpp:
1885         (Element::removeAttributeNode):
1886         (Element::getElementsByTagName):
1887         (Element::getElementsByTagNameNS):
1888         (Element::setAttributeNodeNS):
1889         * khtml/dom/dom_node.cpp:
1890         (NamedNodeMap::setNamedItemNS):
1891         (NamedNodeMap::removeNamedItemNS):
1892         * khtml/ecma/kjs_binding.cpp:
1893         * khtml/ecma/kjs_events.cpp:
1894         (ClipboardProtoFunc::tryCall):
1895         * khtml/editing/jsediting.cpp:
1896         * khtml/khtml_part.cpp:
1897         (KHTMLPart::applyEditingStyleToBodyElement):
1898         (KHTMLPart::removeEditingStyleFromBodyElement):
1899         * khtml/khtmlview.cpp:
1900         (KHTMLView::viewportMousePressEvent):
1901         (KHTMLView::viewportMouseDoubleClickEvent):
1902         (KHTMLView::viewportMouseMoveEvent):
1903         (KHTMLView::viewportMouseReleaseEvent):
1904         (KHTMLView::updateDragAndDrop):
1905         (KHTMLView::dispatchMouseEvent):
1906         * khtml/misc/shared.h:
1907         (khtml::SharedPtr::reset):
1908         (khtml::::operator):
1909         (khtml::static_pointer_cast):
1910         (khtml::const_pointer_cast):
1911         * khtml/xml/dom2_eventsimpl.cpp:
1912         (UIEventImpl::initUIEvent):
1913         (UIEventImpl::keyCode):
1914         (UIEventImpl::charCode):
1915         (UIEventImpl::layerX):
1916         (UIEventImpl::layerY):
1917         (UIEventImpl::pageX):
1918         (UIEventImpl::pageY):
1919         (UIEventImpl::which):
1920         (MouseRelatedEventImpl::pageX):
1921         (MouseRelatedEventImpl::pageY):
1922         (MouseEventImpl::initMouseEvent):
1923         (MouseEventImpl::which):
1924         (KeyboardEventImpl::initKeyboardEvent):
1925         (KeyboardEventImpl::which):
1926         (MutationEventImpl::MutationEventImpl):
1927         (MutationEventImpl::initMutationEvent):
1928         * khtml/xml/dom2_eventsimpl.h:
1929         (DOM::MutationEventImpl::relatedNode):
1930         * khtml/xml/dom2_rangeimpl.h:
1931         * khtml/xml/dom2_traversalimpl.cpp:
1932         (DOM::NodeFilterImpl::acceptNode):
1933         * khtml/xml/dom2_traversalimpl.h:
1934         * khtml/xml/dom_docimpl.cpp:
1935         (DOMImplementationImpl::createDocument):
1936         (DOMImplementationImpl::createCSSStyleSheet):
1937         (DOMImplementationImpl::createHTMLDocument):
1938         (DocumentImpl::createAttribute):
1939         (DocumentImpl::createHTMLElement):
1940         (DocumentImpl::getOverrideStyle):
1941         (DocumentImpl::defaultEventHandler):
1942         (DocumentImpl::completeURL):
1943         (DocumentImpl::topDocument):
1944         (DocumentImpl::createAttributeNS):
1945         (DocumentImpl::images):
1946         (DocumentImpl::applets):
1947         (DocumentImpl::embeds):
1948         (DocumentImpl::objects):
1949         (DocumentImpl::links):
1950         (DocumentImpl::forms):
1951         (DocumentImpl::anchors):
1952         (DocumentImpl::all):
1953         (DocumentImpl::nameableItems):
1954         (DocumentImpl::getElementsByName):
1955         * khtml/xml/dom_docimpl.h:
1956         (DOM::DocumentImpl::realDocType):
1957         (DOM::DocumentImpl::createAttribute):
1958         * khtml/xml/dom_elementimpl.cpp:
1959         (AttrImpl::nodeName):
1960         (AttrImpl::nodeValue):
1961         (AttrImpl::name):
1962         (AttrImpl::value):
1963         (ElementImpl::attributes):
1964         (ElementImpl::isURLAttribute):
1965         (ElementImpl::setAttributeNode):
1966         (ElementImpl::removeAttributeNode):
1967         (ElementImpl::setAttributeNS):
1968         (ElementImpl::removeAttributeNS):
1969         (ElementImpl::getAttributeNodeNS):
1970         (ElementImpl::hasAttributeNS):
1971         (ElementImpl::style):
1972         (XMLElementImpl::cloneNode):
1973         (NamedAttrMapImpl::setNamedItem):
1974         (NamedAttrMapImpl::removeNamedItem):
1975         * khtml/xml/dom_elementimpl.h:
1976         (DOM::ElementImpl::hasAttribute):
1977         (DOM::ElementImpl::getAttribute):
1978         (DOM::ElementImpl::setAttribute):
1979         (DOM::ElementImpl::removeAttribute):
1980         (DOM::ElementImpl::getAttributeNode):
1981         (DOM::ElementImpl::setAttributeNodeNS):
1982         * khtml/xml/dom_nodeimpl.cpp:
1983         (NodeImpl::handleLocalEvents):
1984         (NodeImpl::isAncestor):
1985         (NodeImpl::addEventListener):
1986         (NodeImpl::removeEventListener):
1987         (NodeImpl::getElementsByTagNameNS):
1988         (NodeImpl::isSupported):
1989         (NodeImpl::ownerDocument):
1990         (NodeImpl::hasAttributes):
1991         (NodeImpl::attributes):
1992         (ContainerNodeImpl::removeChildren):
1993         (NamedNodeMapImpl::~NamedNodeMapImpl):
1994         (NamedNodeMapImpl::getNamedItemNS):
1995         (NamedNodeMapImpl::removeNamedItemNS):
1996         * khtml/xml/dom_nodeimpl.h:
1997         (DOM::NodeImpl::getElementsByTagName):
1998         (DOM::NamedNodeMapImpl::NamedNodeMapImpl):
1999         (DOM::NamedNodeMapImpl::getNamedItem):
2000         (DOM::NamedNodeMapImpl::removeNamedItem):
2001         (DOM::NamedNodeMapImpl::setNamedItemNS):
2002         (DOM::NamedNodeMapImpl::isReadOnly):
2003         * khtml/xml/dom_textimpl.h:
2004         * khtml/xml/dom_xmlimpl.h:
2005         * kwq/DOM.mm:
2006         (-[DOMNode isSupported::]):
2007         (-[DOMNode namespaceURI]):
2008         (-[DOMNode hasAttributes]):
2009         (-[DOMNamedNodeMap getNamedItem:]):
2010         (-[DOMNamedNodeMap setNamedItem:]):
2011         (-[DOMNamedNodeMap removeNamedItem:]):
2012         (-[DOMNamedNodeMap getNamedItemNS::]):
2013         (-[DOMNamedNodeMap setNamedItemNS:]):
2014         (-[DOMNamedNodeMap removeNamedItemNS::]):
2015         (-[DOMImplementation createDocument:::]):
2016         (-[DOMImplementation createCSSStyleSheet::]):
2017         (-[DOMDocument createAttribute:]):
2018         (-[DOMDocument getElementsByTagName:]):
2019         (-[DOMDocument createAttributeNS::]):
2020         (-[DOMDocument getElementsByTagNameNS::]):
2021         (-[DOMElement setAttribute::]):
2022         (-[DOMElement removeAttribute:]):
2023         (-[DOMElement getAttributeNode:]):
2024         (-[DOMElement setAttributeNode:]):
2025         (-[DOMElement removeAttributeNode:]):
2026         (-[DOMElement getElementsByTagName:]):
2027         (-[DOMElement getAttributeNS::]):
2028         (-[DOMElement setAttributeNS:::]):
2029         (-[DOMElement removeAttributeNS::]):
2030         (-[DOMElement getAttributeNodeNS::]):
2031         (-[DOMElement setAttributeNodeNS:]):
2032         (-[DOMElement getElementsByTagNameNS::]):
2033         (-[DOMElement hasAttribute:]):
2034         (-[DOMElement hasAttributeNS::]):
2035         (-[DOMElement style]):
2036         (-[DOMDocumentType _documentTypeImpl]):
2037         (ObjCNodeFilterCondition::acceptNode):
2038         * kwq/DOMEvents.mm:
2039         (-[DOMMutationEvent relatedNode]):
2040         * kwq/KWQClipboard.h:
2041         * kwq/KWQClipboard.mm:
2042         (KWQClipboard::KWQClipboard):
2043         (KWQClipboard::setDragImage):
2044         (KWQClipboard::dragImageElement):
2045         (KWQClipboard::setDragImageElement):
2046         (KWQClipboard::dragNSImage):
2047         * kwq/KWQKHTMLPart.mm:
2048         (KWQKHTMLPart::khtmlMouseMoveEvent):
2049         (KWQKHTMLPart::passSubframeEventToSubframe):
2050         (KWQKHTMLPart::sendContextMenuEvent):
2051
2052 2005-05-10  Darin Adler  <darin@apple.com>
2053
2054         Reviewed by David Harrison.
2055
2056         - first pass of moving code from C++ DOM wrappers into the DOM impl. classes
2057           (this step mostly adds member functions missing from the DOM impl.; later steps
2058            will change the C++, JavaScript, and ObjC wrappers to call these functions)
2059
2060         * khtml/css/parser.y:
2061         * khtml/css/css_ruleimpl.cpp:
2062         (CSSRuleListImpl::CSSRuleListImpl):
2063         * khtml/css/css_ruleimpl.h:
2064         (DOM::CSSRuleListImpl::CSSRuleListImpl):
2065         * khtml/html/html_baseimpl.cpp:
2066         (HTMLBodyElementImpl::aLink):
2067         (HTMLBodyElementImpl::setALink):
2068         (HTMLBodyElementImpl::background):
2069         (HTMLBodyElementImpl::setBackground):
2070         (HTMLBodyElementImpl::bgColor):
2071         (HTMLBodyElementImpl::setBgColor):
2072         (HTMLBodyElementImpl::link):
2073         (HTMLBodyElementImpl::setLink):
2074         (HTMLBodyElementImpl::text):
2075         (HTMLBodyElementImpl::setText):
2076         (HTMLBodyElementImpl::vLink):
2077         (HTMLBodyElementImpl::setVLink):
2078         (HTMLFrameElementImpl::HTMLFrameElementImpl):
2079         (HTMLFrameElementImpl::updateForNewURL):
2080         (HTMLFrameElementImpl::openURL):
2081         (HTMLFrameElementImpl::parseHTMLAttribute):
2082         (HTMLFrameElementImpl::rendererIsNeeded):
2083         (HTMLFrameElementImpl::attach):
2084         (HTMLFrameElementImpl::detach):
2085         (HTMLFrameElementImpl::setLocation):
2086         (HTMLFrameElementImpl::contentPart):
2087         (HTMLFrameElementImpl::frameBorder):
2088         (HTMLFrameElementImpl::setFrameBorder):
2089         (HTMLFrameElementImpl::longDesc):
2090         (HTMLFrameElementImpl::setLongDesc):
2091         (HTMLFrameElementImpl::marginHeight):
2092         (HTMLFrameElementImpl::setMarginHeight):
2093         (HTMLFrameElementImpl::marginWidth):
2094         (HTMLFrameElementImpl::setMarginWidth):
2095         (HTMLFrameElementImpl::name):
2096         (HTMLFrameElementImpl::setName):
2097         (HTMLFrameElementImpl::setNoResize):
2098         (HTMLFrameElementImpl::scrolling):
2099         (HTMLFrameElementImpl::setScrolling):
2100         (HTMLFrameElementImpl::src):
2101         (HTMLFrameElementImpl::setSrc):
2102         (HTMLFrameSetElementImpl::parseHTMLAttribute):
2103         (HTMLFrameSetElementImpl::cols):
2104         (HTMLFrameSetElementImpl::setCols):
2105         (HTMLFrameSetElementImpl::rows):
2106         (HTMLFrameSetElementImpl::setRows):
2107         (HTMLHeadElementImpl::profile):
2108         (HTMLHeadElementImpl::setProfile):
2109         (HTMLHtmlElementImpl::version):
2110         (HTMLHtmlElementImpl::setVersion):
2111         (HTMLIFrameElementImpl::HTMLIFrameElementImpl):
2112         (HTMLIFrameElementImpl::rendererIsNeeded):
2113         (HTMLIFrameElementImpl::attach):
2114         (HTMLIFrameElementImpl::isURLAttribute):
2115         (HTMLIFrameElementImpl::align):
2116         (HTMLIFrameElementImpl::setAlign):
2117         (HTMLIFrameElementImpl::height):
2118         (HTMLIFrameElementImpl::setHeight):
2119         (HTMLIFrameElementImpl::src):
2120         (HTMLIFrameElementImpl::width):
2121         (HTMLIFrameElementImpl::setWidth):
2122         * khtml/html/html_baseimpl.h:
2123         (DOM::HTMLFrameElementImpl::noResize):
2124         (DOM::HTMLFrameElementImpl::scrollingMode):
2125         (DOM::HTMLFrameElementImpl::getMarginWidth):
2126         (DOM::HTMLFrameElementImpl::getMarginHeight):
2127         * khtml/html/html_blockimpl.cpp:
2128         (HTMLBlockquoteElementImpl::cite):
2129         (HTMLBlockquoteElementImpl::setCite):
2130         (HTMLDivElementImpl::align):
2131         (HTMLDivElementImpl::setAlign):
2132         (HTMLHRElementImpl::align):
2133         (HTMLHRElementImpl::setAlign):
2134         (HTMLHRElementImpl::noShade):
2135         (HTMLHRElementImpl::setNoShade):
2136         (HTMLHRElementImpl::size):
2137         (HTMLHRElementImpl::setSize):
2138         (HTMLHRElementImpl::width):
2139         (HTMLHRElementImpl::setWidth):
2140         (HTMLHeadingElementImpl::align):
2141         (HTMLHeadingElementImpl::setAlign):
2142         (HTMLParagraphElementImpl::align):
2143         (HTMLParagraphElementImpl::setAlign):
2144         (HTMLPreElementImpl::width):
2145         (HTMLPreElementImpl::setWidth):
2146         * khtml/html/html_blockimpl.h:
2147         * khtml/html/html_imageimpl.cpp:
2148         (HTMLImageElementImpl::name):
2149         (HTMLImageElementImpl::setName):
2150         (HTMLImageElementImpl::align):
2151         (HTMLImageElementImpl::setAlign):
2152         (HTMLImageElementImpl::alt):
2153         (HTMLImageElementImpl::setAlt):
2154         (HTMLImageElementImpl::border):
2155         (HTMLImageElementImpl::setBorder):
2156         (HTMLImageElementImpl::setHeight):
2157         (HTMLImageElementImpl::hspace):
2158         (HTMLImageElementImpl::setHspace):
2159         (HTMLImageElementImpl::isMap):
2160         (HTMLImageElementImpl::setIsMap):
2161         (HTMLImageElementImpl::longDesc):
2162         (HTMLImageElementImpl::setLongDesc):
2163         (HTMLImageElementImpl::src):
2164         (HTMLImageElementImpl::setSrc):
2165         (HTMLImageElementImpl::useMap):
2166         (HTMLImageElementImpl::setUseMap):
2167         (HTMLImageElementImpl::vspace):
2168         (HTMLImageElementImpl::setVspace):
2169         (HTMLImageElementImpl::setWidth):
2170         (HTMLImageElementImpl::x):
2171         (HTMLImageElementImpl::y):
2172         (HTMLMapElementImpl::parseHTMLAttribute):
2173         (HTMLMapElementImpl::areas):
2174         (HTMLMapElementImpl::name):
2175         (HTMLMapElementImpl::setName):
2176         (HTMLAreaElementImpl::HTMLAreaElementImpl):
2177         (HTMLAreaElementImpl::parseHTMLAttribute):
2178         (HTMLAreaElementImpl::getRegion):
2179         (HTMLAreaElementImpl::accessKey):
2180         (HTMLAreaElementImpl::setAccessKey):
2181         (HTMLAreaElementImpl::alt):
2182         (HTMLAreaElementImpl::setAlt):
2183         (HTMLAreaElementImpl::coords):
2184         (HTMLAreaElementImpl::setCoords):
2185         (HTMLAreaElementImpl::href):
2186         (HTMLAreaElementImpl::setHref):
2187         (HTMLAreaElementImpl::noHref):
2188         (HTMLAreaElementImpl::setNoHref):
2189         (HTMLAreaElementImpl::shape):
2190         (HTMLAreaElementImpl::setShape):
2191         (HTMLAreaElementImpl::tabIndex):
2192         (HTMLAreaElementImpl::setTabIndex):
2193         (HTMLAreaElementImpl::target):
2194         (HTMLAreaElementImpl::setTarget):
2195         * khtml/html/html_imageimpl.h:
2196         (DOM::HTMLImageElementImpl::pixmap):
2197         (DOM::HTMLAreaElementImpl::isDefault):
2198         (DOM::HTMLMapElementImpl::getName):
2199         * khtml/html/html_inlineimpl.cpp:
2200         (DOM::HTMLAnchorElementImpl::accessKey):
2201         (DOM::HTMLAnchorElementImpl::setAccessKey):
2202         (DOM::HTMLAnchorElementImpl::charset):
2203         (DOM::HTMLAnchorElementImpl::setCharset):
2204         (DOM::HTMLAnchorElementImpl::coords):
2205         (DOM::HTMLAnchorElementImpl::setCoords):
2206         (DOM::HTMLAnchorElementImpl::href):
2207         (DOM::HTMLAnchorElementImpl::setHref):
2208         (DOM::HTMLAnchorElementImpl::hreflang):
2209         (DOM::HTMLAnchorElementImpl::setHreflang):
2210         (DOM::HTMLAnchorElementImpl::name):
2211         (DOM::HTMLAnchorElementImpl::setName):
2212         (DOM::HTMLAnchorElementImpl::rel):
2213         (DOM::HTMLAnchorElementImpl::setRel):
2214         (DOM::HTMLAnchorElementImpl::rev):
2215         (DOM::HTMLAnchorElementImpl::setRev):
2216         (DOM::HTMLAnchorElementImpl::shape):
2217         (DOM::HTMLAnchorElementImpl::setShape):
2218         (DOM::HTMLAnchorElementImpl::tabIndex):
2219         (DOM::HTMLAnchorElementImpl::setTabIndex):
2220         (DOM::HTMLAnchorElementImpl::target):
2221         (DOM::HTMLAnchorElementImpl::setTarget):
2222         (DOM::HTMLAnchorElementImpl::type):
2223         (DOM::HTMLAnchorElementImpl::setType):
2224         (DOM::HTMLAnchorElementImpl::blur):
2225         (DOM::HTMLAnchorElementImpl::focus):
2226         (DOM::HTMLBRElementImpl::clear):
2227         (DOM::HTMLBRElementImpl::setClear):
2228         (DOM::HTMLFontElementImpl::parseHTMLAttribute):
2229         (DOM::HTMLFontElementImpl::color):
2230         (DOM::HTMLFontElementImpl::setColor):
2231         (DOM::HTMLFontElementImpl::face):
2232         (DOM::HTMLFontElementImpl::setFace):
2233         (DOM::HTMLFontElementImpl::size):
2234         (DOM::HTMLFontElementImpl::setSize):
2235         (DOM::HTMLModElementImpl::HTMLModElementImpl):
2236         (DOM::HTMLModElementImpl::cite):
2237         (DOM::HTMLModElementImpl::setCite):
2238         (DOM::HTMLModElementImpl::dateTime):
2239         (DOM::HTMLModElementImpl::setDateTime):
2240         (DOM::HTMLQuoteElementImpl::HTMLQuoteElementImpl):
2241         (DOM::HTMLQuoteElementImpl::id):
2242         (DOM::HTMLQuoteElementImpl::cite):
2243         (DOM::HTMLQuoteElementImpl::setCite):
2244         * khtml/html/html_inlineimpl.h:
2245         * khtml/html/html_listimpl.cpp:
2246         (DOM::HTMLUListElementImpl::compact):
2247         (DOM::HTMLUListElementImpl::setCompact):
2248         (DOM::HTMLUListElementImpl::type):
2249         (DOM::HTMLUListElementImpl::setType):
2250         (DOM::HTMLDirectoryElementImpl::compact):
2251         (DOM::HTMLDirectoryElementImpl::setCompact):
2252         (DOM::HTMLMenuElementImpl::compact):
2253         (DOM::HTMLMenuElementImpl::setCompact):
2254         (DOM::HTMLOListElementImpl::compact):
2255         (DOM::HTMLOListElementImpl::setCompact):
2256         (DOM::HTMLOListElementImpl::setStart):
2257         (DOM::HTMLOListElementImpl::type):
2258         (DOM::HTMLOListElementImpl::setType):
2259         (DOM::HTMLLIElementImpl::type):
2260         (DOM::HTMLLIElementImpl::setType):
2261         (DOM::HTMLLIElementImpl::value):
2262         (DOM::HTMLLIElementImpl::setValue):
2263         (DOM::HTMLDListElementImpl::compact):
2264         (DOM::HTMLDListElementImpl::setCompact):
2265         * khtml/html/html_listimpl.h:
2266         (DOM::HTMLUListElementImpl::start):
2267         (DOM::HTMLDirectoryElementImpl::HTMLDirectoryElementImpl):
2268         (DOM::HTMLMenuElementImpl::HTMLMenuElementImpl):
2269         (DOM::HTMLOListElementImpl::HTMLOListElementImpl):
2270         (DOM::HTMLOListElementImpl::start):
2271         * khtml/html/html_objectimpl.cpp:
2272         (DOM::HTMLAppletElementImpl::align):
2273         (DOM::HTMLAppletElementImpl::setAlign):
2274         (DOM::HTMLAppletElementImpl::alt):
2275         (DOM::HTMLAppletElementImpl::setAlt):
2276         (DOM::HTMLAppletElementImpl::archive):
2277         (DOM::HTMLAppletElementImpl::setArchive):
2278         (DOM::HTMLAppletElementImpl::code):
2279         (DOM::HTMLAppletElementImpl::setCode):
2280         (DOM::HTMLAppletElementImpl::codeBase):
2281         (DOM::HTMLAppletElementImpl::setCodeBase):
2282         (DOM::HTMLAppletElementImpl::height):
2283         (DOM::HTMLAppletElementImpl::setHeight):
2284         (DOM::HTMLAppletElementImpl::hspace):
2285         (DOM::HTMLAppletElementImpl::setHspace):
2286         (DOM::HTMLAppletElementImpl::name):
2287         (DOM::HTMLAppletElementImpl::setName):
2288         (DOM::HTMLAppletElementImpl::object):
2289         (DOM::HTMLAppletElementImpl::setObject):
2290         (DOM::HTMLAppletElementImpl::vspace):
2291         (DOM::HTMLAppletElementImpl::setVspace):
2292         (DOM::HTMLAppletElementImpl::width):
2293         (DOM::HTMLAppletElementImpl::setWidth):
2294         (DOM::HTMLObjectElementImpl::code):
2295         (DOM::HTMLObjectElementImpl::setCode):
2296         (DOM::HTMLObjectElementImpl::align):
2297         (DOM::HTMLObjectElementImpl::setAlign):
2298         (DOM::HTMLObjectElementImpl::archive):
2299         (DOM::HTMLObjectElementImpl::setArchive):
2300         (DOM::HTMLObjectElementImpl::border):
2301         (DOM::HTMLObjectElementImpl::setBorder):
2302         (DOM::HTMLObjectElementImpl::codeBase):
2303         (DOM::HTMLObjectElementImpl::setCodeBase):
2304         (DOM::HTMLObjectElementImpl::codeType):
2305         (DOM::HTMLObjectElementImpl::setCodeType):
2306         (DOM::HTMLObjectElementImpl::data):
2307         (DOM::HTMLObjectElementImpl::setData):
2308         (DOM::HTMLObjectElementImpl::declare):
2309         (DOM::HTMLObjectElementImpl::setDeclare):
2310         (DOM::HTMLObjectElementImpl::height):
2311         (DOM::HTMLObjectElementImpl::setHeight):
2312         (DOM::HTMLObjectElementImpl::hspace):
2313         (DOM::HTMLObjectElementImpl::setHspace):
2314         (DOM::HTMLObjectElementImpl::name):
2315         (DOM::HTMLObjectElementImpl::setName):
2316         (DOM::HTMLObjectElementImpl::standby):
2317         (DOM::HTMLObjectElementImpl::setStandby):
2318         (DOM::HTMLObjectElementImpl::tabIndex):
2319         (DOM::HTMLObjectElementImpl::setTabIndex):
2320         (DOM::HTMLObjectElementImpl::type):
2321         (DOM::HTMLObjectElementImpl::setType):
2322         (DOM::HTMLObjectElementImpl::useMap):
2323         (DOM::HTMLObjectElementImpl::setUseMap):
2324         (DOM::HTMLObjectElementImpl::vspace):
2325         (DOM::HTMLObjectElementImpl::setVspace):
2326         (DOM::HTMLObjectElementImpl::width):
2327         (DOM::HTMLObjectElementImpl::setWidth):
2328         (DOM::HTMLParamElementImpl::isURLAttribute):
2329         (DOM::HTMLParamElementImpl::setName):
2330         (DOM::HTMLParamElementImpl::type):
2331         (DOM::HTMLParamElementImpl::setType):
2332         (DOM::HTMLParamElementImpl::setValue):
2333         (DOM::HTMLParamElementImpl::valueType):
2334         (DOM::HTMLParamElementImpl::setValueType):
2335         * khtml/html/html_objectimpl.h:
2336         (DOM::HTMLParamElementImpl::name):
2337         (DOM::HTMLParamElementImpl::value):
2338         * khtml/html/html_tableimpl.cpp:
2339         (DOM::HTMLTableElementImpl::rows):
2340         (DOM::HTMLTableElementImpl::tBodies):
2341         (DOM::HTMLTableElementImpl::align):
2342         (DOM::HTMLTableElementImpl::setAlign):
2343         (DOM::HTMLTableElementImpl::bgColor):
2344         (DOM::HTMLTableElementImpl::setBgColor):
2345         (DOM::HTMLTableElementImpl::border):
2346         (DOM::HTMLTableElementImpl::setBorder):
2347         (DOM::HTMLTableElementImpl::cellPadding):
2348         (DOM::HTMLTableElementImpl::setCellPadding):
2349         (DOM::HTMLTableElementImpl::cellSpacing):
2350         (DOM::HTMLTableElementImpl::setCellSpacing):
2351         (DOM::HTMLTableElementImpl::frame):
2352         (DOM::HTMLTableElementImpl::setFrame):
2353         (DOM::HTMLTableElementImpl::rules):
2354         (DOM::HTMLTableElementImpl::setRules):
2355         (DOM::HTMLTableElementImpl::summary):
2356         (DOM::HTMLTableElementImpl::setSummary):
2357         (DOM::HTMLTableElementImpl::width):
2358         (DOM::HTMLTableElementImpl::setWidth):
2359         (DOM::HTMLTableSectionElementImpl::align):
2360         (DOM::HTMLTableSectionElementImpl::setAlign):
2361         (DOM::HTMLTableSectionElementImpl::ch):
2362         (DOM::HTMLTableSectionElementImpl::setCh):
2363         (DOM::HTMLTableSectionElementImpl::chOff):
2364         (DOM::HTMLTableSectionElementImpl::setChOff):
2365         (DOM::HTMLTableSectionElementImpl::vAlign):
2366         (DOM::HTMLTableSectionElementImpl::setVAlign):
2367         (DOM::HTMLTableSectionElementImpl::rows):
2368         (DOM::HTMLTableRowElementImpl::cells):
2369         (DOM::HTMLTableRowElementImpl::setCells):
2370         (DOM::HTMLTableRowElementImpl::align):
2371         (DOM::HTMLTableRowElementImpl::setAlign):
2372         (DOM::HTMLTableRowElementImpl::bgColor):
2373         (DOM::HTMLTableRowElementImpl::setBgColor):
2374         (DOM::HTMLTableRowElementImpl::ch):
2375         (DOM::HTMLTableRowElementImpl::setCh):
2376         (DOM::HTMLTableRowElementImpl::chOff):
2377         (DOM::HTMLTableRowElementImpl::setChOff):
2378         (DOM::HTMLTableRowElementImpl::vAlign):
2379         (DOM::HTMLTableRowElementImpl::setVAlign):
2380         (DOM::HTMLTableCellElementImpl::abbr):
2381         (DOM::HTMLTableCellElementImpl::setAbbr):
2382         (DOM::HTMLTableCellElementImpl::align):
2383         (DOM::HTMLTableCellElementImpl::setAlign):
2384         (DOM::HTMLTableCellElementImpl::axis):
2385         (DOM::HTMLTableCellElementImpl::setAxis):
2386         (DOM::HTMLTableCellElementImpl::bgColor):
2387         (DOM::HTMLTableCellElementImpl::setBgColor):
2388         (DOM::HTMLTableCellElementImpl::ch):
2389         (DOM::HTMLTableCellElementImpl::setCh):
2390         (DOM::HTMLTableCellElementImpl::chOff):
2391         (DOM::HTMLTableCellElementImpl::setChOff):
2392         (DOM::HTMLTableCellElementImpl::setColSpan):
2393         (DOM::HTMLTableCellElementImpl::headers):
2394         (DOM::HTMLTableCellElementImpl::setHeaders):
2395         (DOM::HTMLTableCellElementImpl::height):
2396         (DOM::HTMLTableCellElementImpl::setHeight):
2397         (DOM::HTMLTableCellElementImpl::noWrap):
2398         (DOM::HTMLTableCellElementImpl::setNoWrap):
2399         (DOM::HTMLTableCellElementImpl::setRowSpan):
2400         (DOM::HTMLTableCellElementImpl::scope):
2401         (DOM::HTMLTableCellElementImpl::setScope):
2402         (DOM::HTMLTableCellElementImpl::vAlign):
2403         (DOM::HTMLTableCellElementImpl::setVAlign):
2404         (DOM::HTMLTableCellElementImpl::width):
2405         (DOM::HTMLTableCellElementImpl::setWidth):
2406         (DOM::HTMLTableColElementImpl::align):
2407         (DOM::HTMLTableColElementImpl::setAlign):
2408         (DOM::HTMLTableColElementImpl::ch):
2409         (DOM::HTMLTableColElementImpl::setCh):
2410         (DOM::HTMLTableColElementImpl::chOff):
2411         (DOM::HTMLTableColElementImpl::setChOff):
2412         (DOM::HTMLTableColElementImpl::setSpan):
2413         (DOM::HTMLTableColElementImpl::vAlign):
2414         (DOM::HTMLTableColElementImpl::setVAlign):
2415         (DOM::HTMLTableColElementImpl::width):
2416         (DOM::HTMLTableColElementImpl::setWidth):
2417         (DOM::HTMLTableCaptionElementImpl::parseHTMLAttribute):
2418         (DOM::HTMLTableCaptionElementImpl::align):
2419         (DOM::HTMLTableCaptionElementImpl::setAlign):
2420         * khtml/html/html_tableimpl.h:
2421         (DOM::HTMLTableColElementImpl::span):
2422         * khtml/rendering/render_applet.cpp:
2423         (RenderApplet::createWidgetIfNecessary):
2424         * khtml/rendering/render_frames.cpp:
2425         (RenderFrame::slotViewCleared):
2426         (RenderPartObject::updateWidget):
2427         (RenderPartObject::slotViewCleared):
2428         * khtml/xml/dom_docimpl.cpp:
2429         (DocumentImpl::completeURL):
2430         * khtml/xml/dom_docimpl.h:
2431
2432 2005-05-09  Maciej Stachowiak  <mjs@apple.com>
2433
2434         Reviewed by Kevin.
2435
2436         - remove more isFirst/isLast functions and use isStart/isEnd verions instead
2437
2438         * khtml/editing/htmlediting.cpp:
2439         (khtml::DeleteSelectionCommand::initializePositionData):
2440         (khtml::InsertParagraphSeparatorCommand::calculateStyleBeforeInsertion):
2441         (khtml::InsertTextCommand::input):
2442         (khtml::ReplaceSelectionCommand::doApply):
2443         (khtml::ReplaceSelectionCommand::removeLinePlaceholderIfNeeded):
2444         * khtml/editing/visible_position.cpp:
2445         (khtml::VisiblePosition::previous):
2446         (khtml::setAffinityUsingLinePosition):
2447         (khtml::isFirstVisiblePositionInNode):
2448         * khtml/editing/visible_position.h:
2449         * khtml/editing/visible_units.cpp:
2450         (khtml::endOfLine):
2451         (khtml::previousLinePosition):
2452         * khtml/xml/dom_position.cpp:
2453         (DOM::Position::previousCharacterPosition):
2454         (DOM::Position::nextCharacterPosition):
2455         * kwq/WebCoreBridge.mm:
2456         (-[WebCoreBridge smartInsertForString:replacingRange:beforeString:afterString:]):
2457
2458 2005-05-09  Maciej Stachowiak  <mjs@apple.com>
2459
2460         Reviewed by Kevin.
2461
2462         - remove isFirstVisiblePositionInBlock and isLastVisiblePositionInBlock, in favor of isStartOfBlock and isEndOfBlock
2463
2464         It turned out that both isEndOfBlock and isLastVisiblePositionInBlock had (different) bugs,
2465         and there was code relying on the bugs of each. So in addition I fixed isEndOfBlock and fixed 
2466         the parts of the code relying on buggy behavior.
2467
2468         I also removed the includeEndOfLine parameter to endOfBlock since no one used it and it's not
2469         clear if it would ever be useful.
2470         
2471         * khtml/editing/htmlediting.cpp:
2472         (khtml::InsertLineBreakCommand::doApply): Use new calls.
2473         (khtml::InsertParagraphSeparatorCommand::calculateStyleBeforeInsertion): Don't gratuitously make
2474         an UPSTREAM VisiblePosition, as this will cause trouble comparing it to end of block.
2475         (khtml::InsertParagraphSeparatorCommand::doApply): Use new calls.
2476         (khtml::ReplaceSelectionCommand::doApply): Use new calls. Also, don't make a position <BR,0> and test
2477         if it is the end of a block, that can never be true, although the buggy code in 
2478         isLastVisiblePositionInBlock would say it is. Make <BR,1> instead.
2479         * khtml/editing/markup.cpp:
2480         (khtml::createMarkup): Instead of checking isEndOfBlock on the start position, check if the start's
2481         next is in a different block, to avoid relying on the buggy old isEndOfBlock behavior.
2482         * khtml/editing/visible_position.cpp:
2483         (khtml::isFirstVisiblePositionInParagraph): Use isStartOfBlock.
2484         (khtml::isLastVisiblePositionInParagraph): Use isEndOfBlock.
2485         * khtml/editing/visible_position.h:
2486         * khtml/editing/visible_units.cpp:
2487         (khtml::endOfBlock): Greatly simplify, and no longer consider the start of a descendant
2488         block to be the end of the block. That's inconsistent with how startOfBlock works. Also
2489         remove include end of line parameter.
2490         (khtml::isEndOfBlock): Don't pass unneeded parameter.
2491         * khtml/editing/visible_units.h:
2492
2493 2005-05-09  Adele Peterson  <adele@apple.com>
2494
2495         fix for <rdar://problem/4110775> Crash will occur when double-clicking outerHTML link on W3 DOM test
2496
2497         Reviewed by Darin.
2498
2499         * khtml/html/html_elementimpl.cpp: (HTMLElementImpl::setOuterHTML): added nil check.  
2500         This was causing a crash when you tried to set the outerHTML on an element that was no longer in the DOM tree.
2501
2502         * layout-tests/fast/dom/outerText-no-element.html: Added. Tests case where you try to set outerText on an element no longer in the DOM tree.
2503         * layout-tests/fast/dom/outerText-no-element-expected.txt: Added.
2504         * layout-tests/fast/dynamic/outerHTML-doc.html: Added.  Tests case where someone tries to set outerHTML on the document.
2505         * layout-tests/fast/dynamic/outerHTML-doc-expected.txt: Added..
2506         * layout-tests/fast/dynamic/outerHTML-no-element.html: Added. Tests case where you try to set outerHTML on an element no longer in the DOM tree.
2507         * layout-tests/fast/dynamic/outerHTML-no-element-expected.txt: Added.
2508         * layout-tests/fast/dynamic/outerHTML-img.html: moved images to resources directory
2509         * layout-tests/fast/dynamic/resources/apple.gif: Added.
2510         * layout-tests/fast/dynamic/resources/mozilla.gif: Added.
2511
2512 2005-05-09  Maciej Stachowiak  <mjs@apple.com>
2513
2514         Reviewed by Kevin.
2515
2516         - remove code for DoNotStayInBlock variant of upstream/downstream and make
2517         the methods take no parameters
2518
2519         * khtml/editing/htmlediting.cpp:
2520         (khtml::CompositeEditCommand::deleteInsignificantTextDownstream):
2521         (khtml::CompositeEditCommand::moveParagraphContentsToNewBlockIfNecessary):
2522         (khtml::ApplyStyleCommand::applyRelativeFontStyleChange):
2523         (khtml::ApplyStyleCommand::applyInlineStyle):
2524         (khtml::ApplyStyleCommand::removeInlineStyle):
2525         (khtml::ApplyStyleCommand::nodeFullySelected):
2526         (khtml::ApplyStyleCommand::nodeFullyUnselected):
2527         (khtml::DeleteSelectionCommand::initializePositionData):
2528         (khtml::DeleteSelectionCommand::fixupWhitespace):
2529         (khtml::InsertLineBreakCommand::insertNodeAfterPosition):
2530         (khtml::InsertLineBreakCommand::insertNodeBeforePosition):
2531         (khtml::InsertLineBreakCommand::doApply):
2532         (khtml::InsertParagraphSeparatorCommand::doApply):
2533         (khtml::InsertParagraphSeparatorInQuotedContentCommand::doApply):
2534         (khtml::InsertTextCommand::prepareForTextInsertion):
2535         (khtml::InsertTextCommand::input):
2536         (khtml::InsertTextCommand::insertSpace):
2537         (khtml::ReplaceSelectionCommand::doApply):
2538         * khtml/editing/selection.cpp:
2539         (khtml::Selection::toRange):
2540         (khtml::Selection::validate):
2541         * khtml/editing/visible_position.cpp:
2542         (khtml::VisiblePosition::previousVisiblePosition):
2543         (khtml::VisiblePosition::nextVisiblePosition):
2544         (khtml::VisiblePosition::downstreamDeepEquivalent):
2545         (khtml::isFirstVisiblePositionInParagraph):
2546         (khtml::isFirstVisiblePositionInBlock):
2547         (khtml::isLastVisiblePositionInParagraph):
2548         * khtml/xml/dom2_rangeimpl.cpp:
2549         (DOM::RangeImpl::editingStartPosition):
2550         * khtml/xml/dom_position.cpp:
2551         (DOM::isStreamer):
2552         (DOM::Position::upstream):
2553         (DOM::Position::downstream):
2554         (DOM::Position::leadingWhitespacePosition):
2555         (DOM::Position::trailingWhitespacePosition):
2556         * khtml/xml/dom_position.h:
2557         * kwq/WebCoreBridge.mm:
2558         (-[WebCoreBridge smartDeleteRangeForProposedRange:]):
2559
2560 2005-05-08  Maciej Stachowiak  <mjs@apple.com>
2561
2562         Reviewed by Dave Harrison.
2563
2564         - remove remaining uses of upstream/downstream DoNotStayInBlock
2565         
2566         * khtml/editing/htmlediting.cpp:
2567         (khtml::CompositeEditCommand::moveParagraphContentsToNewBlockIfNecessary):
2568         (khtml::ApplyStyleCommand::nodeFullySelected):
2569         (khtml::ApplyStyleCommand::nodeFullyUnselected):
2570         (khtml::DeleteSelectionCommand::insertPlaceholderForAncestorBlockContent):
2571         (khtml::InsertParagraphSeparatorCommand::doApply):
2572         (khtml::InsertParagraphSeparatorInQuotedContentCommand::doApply):
2573         (khtml::InsertTextCommand::insertSpace):
2574         (khtml::ReplaceSelectionCommand::doApply):
2575         
2576         * khtml/editing/visible_position.cpp:
2577         (khtml::enclosingBlockFlowElement): New helper function.
2578         * khtml/editing/visible_position.h:
2579
2580         * khtml/editing/visible_units.cpp:
2581         (khtml::inSameBlock): Check enclosing block flows instead of comparing
2582         visible block starts. Two nested blocks may have the same visible start but
2583         different visible ends, so the old check would give false positives.
2584
2585 2005-05-09  David Harrison  <harrison@apple.com>
2586
2587         Add layout test for <rdar://problem/4110366>.
2588
2589         * layout-tests/editing/deleting/delete-at-paragraph-boundaries-011-expected.txt: Added.
2590         * layout-tests/editing/deleting/delete-at-paragraph-boundaries-011.html: Added.
2591
2592 2005-05-09  Darin Adler  <darin@apple.com>
2593
2594         - checked in a result for the Flash replacement test that Dave added
2595
2596         * layout-tests/fast/dynamic/flash-replacement-test-expected.txt: Added.
2597         Hope it's right! If not, Dave can update it.
2598
2599 2005-05-09  Darin Adler  <darin@apple.com>
2600
2601         * Makefile.am: Don't set up PBXIntermediatesDirectory explicitly;
2602         Not needed to make builds work, spews undesirable error messages too.
2603
2604         * WebCore.pbproj/project.pbxproj: Remove unneeded $(DSTROOT) in framework paths.
2605
2606 2005-05-07  Maciej Stachowiak  <mjs@apple.com>
2607
2608         Reviewed by Kevin.
2609
2610         - remove some of the uses of upstream/downstream DoNotStayInBlock
2611         
2612         * khtml/editing/markup.cpp:
2613         (khtml::createMarkup): Instead of using upstream to decide if a line break should be 
2614         added at the end, use inSameParagraph.
2615         * khtml/editing/selection.cpp:
2616         (khtml::Selection::debugPosition): Remove the code to print upstream and downstream,
2617         the selection endpoints themselves are adequate for debugging and are what we use for
2618         layout tests.
2619         * khtml/xml/dom2_rangeimpl.cpp:
2620         (DOM::RangeImpl::editingStartPosition): Skip a possible paragraph break at the start
2621         of the selection in a more explicit way to avoid DoNotStayInBlock.
2622
2623 2005-05-07  David Harrison  <harrison@apple.com>
2624
2625         Reviewed by John.
2626
2627         <rdar://problem/4110366> Deleting text at the end of email moves insertion point to the top of the document
2628         
2629         * khtml/editing/htmlediting.cpp:
2630         (khtml::DeleteSelectionCommand::handleGeneralDelete):
2631         Update m_upstreamStart when deleting m_downstreamEnd.node() if the former is no longer in the document.
2632         Better to update here than trying to recover later in calculateEndingPosition().
2633
2634 2005-05-07  David Harrison  <harrison@apple.com>
2635         
2636         Remove workaround for <rdar://problem/4103339>.
2637         
2638         * khtml/editing/htmlediting.cpp:
2639         (khtml::DeleteSelectionCommand::initializePositionData):
2640
2641 2005-05-06  Maciej Stachowiak  <mjs@apple.com>
2642
2643         Reviewed by Dave Harrison.
2644
2645         - make StayInBlock vs DoNotStayInBlock explicit in all calls to
2646         upstream/downstream, in preparation for phasing out the
2647         DoNotStayInBlock variant.
2648
2649         * khtml/editing/htmlediting.cpp:
2650         (khtml::ApplyStyleCommand::nodeFullySelected):
2651         (khtml::ApplyStyleCommand::nodeFullyUnselected):
2652         (khtml::DeleteSelectionCommand::insertPlaceholderForAncestorBlockContent):
2653         (khtml::InsertParagraphSeparatorInQuotedContentCommand::doApply):
2654         (khtml::InsertTextCommand::insertSpace):
2655         (khtml::ReplaceSelectionCommand::doApply):
2656         * khtml/editing/markup.cpp:
2657         (khtml::createMarkup):
2658         * khtml/editing/selection.cpp:
2659         (khtml::Selection::debugPosition):
2660         * khtml/xml/dom_position.h:
2661
2662 2005-05-06  David Harrison  <harrison@apple.com>
2663
2664         Reviewed by Maciej, Darin.
2665
2666         <rdar://problem/4103339> VisiblePosition and PositionIterator iterators do not return positions in order
2667
2668         * WebCore.pbproj/project.pbxproj:
2669         Removed dom_positioniterator.h and dom_positioniterator.cpp.
2670         
2671         * khtml/editing/htmlediting.cpp:
2672         Removed unused include of dom_positioniterator.h and "using" of PositionIterator.
2673         
2674         * khtml/editing/selection.cpp:
2675         Removed unused include of dom_positioniterator.h.
2676
2677         * khtml/editing/visible_position.h:
2678         * khtml/editing/visible_position.cpp:
2679         (khtml::VisiblePosition::previousVisiblePosition):
2680         (khtml::VisiblePosition::nextVisiblePosition):
2681         (khtml::VisiblePosition::downstreamDeepEquivalent):
2682         Use Position::next(), Position::previous(), Position::atStart(), Position::atEnd() instead of duplicated code.
2683         
2684         * khtml/xml/dom_nodeimpl.h:
2685         * khtml/xml/dom_nodeimpl.cpp:
2686         (NodeImpl::maxDeepOffset):
2687         Added to support Position::next(), Position::previous(), Position::atStart(), Position::atEnd()
2688         
2689         * khtml/xml/dom_position.h:
2690         * khtml/xml/dom_position.cpp:
2691         (DOM::Position::previous):
2692         (DOM::Position::next):
2693         (DOM::Position::atStart):
2694         (DOM::Position::atEnd):
2695         Moved here, replacing VisiblePosition's duplicate and PositionIterator.  Fixed to
2696         return positions in order and not skip positions.
2697         
2698         (DOM::Position::previousCharacterPosition):
2699         (DOM::Position::nextCharacterPosition):
2700         Use Position::next(), Position::previous(), Position::atStart(), Position::atEnd() instead of PositionIterator.
2701
2702         (DOM::isStreamer):
2703         (DOM::Position::upstream):
2704         (DOM::Position::downstream):
2705         Use Position::next(), Position::previous(), Position::atStart(), Position::atEnd() instead of PositionIterator.
2706
2707         * khtml/xml/dom_positioniterator.cpp: Removed.
2708         * khtml/xml/dom_positioniterator.h: Removed.
2709         Removed in favor of Position::next(), Position::previous(), Position::atStart(), Position::atEnd()
2710
2711 2005-05-05  Maciej Stachowiak  <mjs@apple.com>
2712
2713         Reviewed by Darin.
2714
2715         <rdar://problem/4058167> Unit Converter and Weather widgets crashed in KJS::Collector::markCurrentThreadConservatively
2716         
2717         Avoid possibly allocating new prototype objects as parameters to
2718         superclass constructors - there may be an allocated but
2719         uninitilized object so this is a bad time to allocate. Instead,
2720         set the prototype in the constructor body, since the object is
2721         happily allocated by then.
2722
2723         * khtml/ecma/kjs_binding.h:
2724         * khtml/ecma/kjs_css.cpp:
2725         (DOMCSSStyleDeclaration::DOMCSSStyleDeclaration):
2726         (DOMMediaList::DOMMediaList):
2727         (DOMCSSStyleSheet::DOMCSSStyleSheet):
2728         (DOMCSSPrimitiveValue::DOMCSSPrimitiveValue):
2729         (DOMCSSValueList::DOMCSSValueList):
2730         * khtml/ecma/kjs_css.h:
2731         (KJS::DOMStyleSheet::DOMStyleSheet):
2732         (KJS::DOMCSSValue::DOMCSSValue):
2733         * khtml/ecma/kjs_dom.cpp:
2734         (DOMNode::DOMNode):
2735         (DOMDocument::DOMDocument):
2736         (DOMElement::DOMElement):
2737         (DOMDOMImplementation::DOMDOMImplementation):
2738         (DOMNamedNodeMap::DOMNamedNodeMap):
2739         (DOMNamedNodesCollection::DOMNamedNodesCollection):
2740         (DOMCharacterData::DOMCharacterData):
2741         (DOMText::DOMText):
2742         * khtml/ecma/kjs_dom.h:
2743         (KJS::NodeConstructor::NodeConstructor):
2744         (KJS::DOMExceptionConstructor::DOMExceptionConstructor):
2745         * khtml/ecma/kjs_events.cpp:
2746         (DOMEvent::DOMEvent):
2747         (Clipboard::Clipboard):
2748         * khtml/ecma/kjs_html.cpp:
2749         (HTMLCollection::HTMLCollection):
2750         * khtml/ecma/kjs_range.cpp:
2751         (DOMRange::DOMRange):
2752         * khtml/ecma/kjs_traversal.cpp:
2753         (DOMNodeIterator::DOMNodeIterator):
2754         (DOMNodeFilter::DOMNodeFilter):
2755         (DOMTreeWalker::DOMTreeWalker):
2756         * khtml/ecma/xmlhttprequest.cpp:
2757         (KJS::XMLHttpRequest::XMLHttpRequest):
2758         * khtml/ecma/xmlserializer.cpp:
2759         (KJS::XMLSerializer::XMLSerializer):
2760
2761 2005-05-06  Darin Adler  <darin@apple.com>
2762
2763         Reviewed by Maciej.
2764
2765         - make building multiple trees with make work better
2766
2767         * Makefile.am: Set up Xcode build directory before invoking xcodebuild.
2768
2769 2005-05-05  David Hyatt  <hyatt@apple.com>
2770
2771         Eliminate the FOUCS on wired.com.  innerWidth and innerHeight on window should not do a layout that ignores
2772         pending stylesheets, since even if stylesheets are loading the correct window dimensions can be determined with
2773         a normal layout.
2774
2775         The radar # is 4109888.
2776         
2777         Reviewed by rjw
2778
2779         * khtml/ecma/kjs_window.cpp:
2780         (Window::get):
2781         (Window::updateLayout):
2782         * khtml/ecma/kjs_window.h:
2783
2784 2005-05-05  David Hyatt  <hyatt@apple.com>
2785
2786         Fix for 4109667, sIFR flash replacement technique often malfunctions.  This bug occurs when the plugin
2787         widget update causes the onload for the document to fire.  Because you can be in the middle of a style
2788         recalc when doing an attach (in response to a stylesheet load), the onload fires in the middle of the attach
2789         process when the tree is in a bogus state.
2790
2791         The fix is to add a bit to the document that tells style recalc that the implicitClose() method was invoked
2792         during the style recalc process and the code has been patched so that when this situation occurs, the close is
2793         deferred until after the style recalc has finished.
2794         
2795         Reviewed by John Sullivan
2796
2797         * khtml/xml/dom_docimpl.cpp:
2798         (DocumentImpl::DocumentImpl):
2799         (DocumentImpl::recalcStyle):
2800         (DocumentImpl::implicitClose):
2801         * khtml/xml/dom_docimpl.h:
2802         * layout-tests/fast/dynamic/flash-replacement-test.html: Added.
2803
2804 2005-05-05  Darin Adler  <darin@apple.com>
2805
2806         Reviewed by Dave Hyatt.
2807
2808         - fixed <rdar://problem/4109564> REGRESSION (Atlanta): maps.google.com doesn't always center California correctly
2809
2810         * khtml/ecma/kjs_events.cpp: (offsetFromTarget): Fix two places that said X where they should say Y.
2811
2812 2005-05-05  David Harrison  <harrison@apple.com>
2813
2814         Restore fixed setEndingSelection.  Fixed method was ifdef'd out
2815         because change was at end of Tiger development, but method is
2816         unused.  You just can never be _too_ safe.
2817         
2818         * khtml/editing/htmlediting.cpp:
2819         (khtml::EditCommandPtr::setEndingSelection):
2820
2821 2005-05-02  Maciej Stachowiak  <mjs@apple.com>
2822
2823         Reviewed by Vicki.
2824
2825         - renamed NodeBaseImpl to ContainerNodeImpl
2826
2827         * khtml/ecma/kjs_dom.cpp:
2828         (DOMNodeProtoFunc::tryCall): Avoid use of NodeBaseImpl and avoid
2829         use of obsolete checkNoOwner call, use isAncestor instead.
2830         * khtml/html/html_elementimpl.cpp:
2831         (HTMLElementImpl::setOuterText): Avoid gratuitous use of
2832         NodeBaseImpl.
2833         * khtml/xml/dom_nodeimpl.cpp:
2834         (NodeBaseImpl::checkNoOwner): Removed.
2835         
2836         Ther rest is all just simple renaming.
2837         
2838         * khtml/xml/dom_docimpl.cpp:
2839         (DocumentImpl::DocumentImpl):
2840         (DocumentImpl::attach):
2841         (DocumentImpl::detach):
2842         (DocumentFragmentImpl::DocumentFragmentImpl):
2843         * khtml/xml/dom_docimpl.h:
2844         * khtml/xml/dom_elementimpl.cpp:
2845         (AttrImpl::AttrImpl):
2846         (ElementImpl::ElementImpl):
2847         (ElementImpl::insertedIntoDocument):
2848         (ElementImpl::removedFromDocument):
2849         (ElementImpl::attach):
2850         (ElementImpl::dump):
2851         * khtml/xml/dom_elementimpl.h:
2852         * khtml/xml/dom_nodeimpl.cpp:
2853         (ContainerNodeImpl::ContainerNodeImpl):
2854         (ContainerNodeImpl::~ContainerNodeImpl):
2855         (ContainerNodeImpl::firstChild):
2856         (ContainerNodeImpl::lastChild):
2857         (ContainerNodeImpl::insertBefore):
2858         (ContainerNodeImpl::replaceChild):
2859         (ContainerNodeImpl::removeChild):
2860         (ContainerNodeImpl::removeChildren):
2861         (ContainerNodeImpl::appendChild):
2862         (ContainerNodeImpl::hasChildNodes):
2863         (ContainerNodeImpl::setFirstChild):
2864         (ContainerNodeImpl::setLastChild):
2865         (ContainerNodeImpl::checkSameDocument):
2866         (ContainerNodeImpl::checkIsChild):
2867         (ContainerNodeImpl::addChild):
2868         (ContainerNodeImpl::attach):
2869         (ContainerNodeImpl::detach):
2870         (ContainerNodeImpl::insertedIntoDocument):
2871         (ContainerNodeImpl::removedFromDocument):
2872         (ContainerNodeImpl::cloneChildNodes):
2873         (ContainerNodeImpl::getElementsByTagNameNS):
2874         (ContainerNodeImpl::getUpperLeftCorner):
2875         (ContainerNodeImpl::getLowerRightCorner):
2876         (ContainerNodeImpl::getRect):
2877         (ContainerNodeImpl::setFocus):
2878         (ContainerNodeImpl::setActive):
2879         (ContainerNodeImpl::childNodeCount):
2880         (ContainerNodeImpl::childNode):
2881         (ContainerNodeImpl::dispatchChildInsertedEvents):
2882         (ContainerNodeImpl::dispatchChildRemovalEvents):
2883         * khtml/xml/dom_nodeimpl.h:
2884         * khtml/xml/dom_xmlimpl.cpp:
2885         (DOM::EntityImpl::EntityImpl):
2886         (DOM::EntityReferenceImpl::EntityReferenceImpl):
2887         (DOM::NotationImpl::NotationImpl):
2888         (DOM::ProcessingInstructionImpl::ProcessingInstructionImpl):
2889         * khtml/xml/dom_xmlimpl.h:
2890
2891 2005-05-04  Vicki Murley  <vicki@apple.com>
2892
2893         Reviewed by Darin.
2894
2895         - fix mismatched parentheses in one of the ifdefs
2896  
2897         * khtml/html/html_headimpl.cpp:
2898         (HTMLTitleElementImpl::childrenChanged):
2899
2900 2005-05-04  Darin Adler  <darin@apple.com>
2901
2902         Reviewed by Dave Hyatt.
2903
2904         - fixed build rules to match other projects
2905
2906         * WebCore.pbproj/project.pbxproj: Set deployment target to 10.3 in the build styles.
2907         When built without a build style (by Apple B&I) we want to get the target from the
2908         environment. But when built with a build style (by Safari engineers and others), we want
2909         to use 10.3.
2910
2911         * Makefile.am: Took out extra parameters that make command-line building different from
2912         Xcode building. Now that this is fixed, you should not get a full rebuild if you switch
2913         from command line to Xcode or back.
2914
2915 2005-05-04  Vicki Murley  <vicki@apple.com>
2916
2917         Reviewed by darin.
2918
2919         - fixed <rdar://problem/3986228> Not able to load additional script blocks dynamically
2920
2921         Run scripts when they're inserted into the document. Use createdByParser bit to make sure
2922         that scripts aren't run twice, once while parsing and again when inserting.
2923
2924         * khtml/html/html_headimpl.cpp:
2925         (HTMLScriptElementImpl::HTMLScriptElementImpl):
2926         (HTMLScriptElementImpl::~HTMLScriptElementImpl):
2927         (HTMLScriptElementImpl::insertedIntoDocument): 
2928         (HTMLScriptElementImpl::removedFromDocument): 
2929         (HTMLScriptElementImpl::notifyFinished): 
2930         * khtml/html/html_headimpl.h:
2931         (DOM::HTMLScriptElementImpl::setCreatedByParser):
2932         * khtml/html/htmlparser.cpp:
2933         (KHTMLParser::getElement): 
2934         * khtml/xml/xml_tokenizer.cpp:
2935         (khtml::XMLTokenizer::startElement): 
2936
2937 2005-05-03  David Hyatt  <hyatt@apple.com>
2938
2939         Normalize all our custom properties in our implementation to be -khtml (remove all the -apple).
2940
2941         Make sure that -apple, -khtml, and -moz are all able to be used.  -apple and -moz just map to -khtml.
2942
2943         Add support for automatically converting -khtml-opacity to opacity (for legacy Safari 1.1 compat).
2944         
2945         Reviewed by darin
2946
2947         * khtml/css/css_computedstyle.cpp:
2948         (DOM::):
2949         (DOM::CSSComputedStyleDeclarationImpl::getPropertyCSSValue):
2950         * khtml/css/cssparser.cpp:
2951         (CSSParser::parseValue):
2952         * khtml/css/cssproperties.in:
2953         * khtml/css/cssstyleselector.cpp:
2954         (khtml::CSSStyleSelector::applyDeclarations):
2955         (khtml::CSSStyleSelector::applyProperty):
2956         * khtml/css/parser.y:
2957         * khtml/ecma/kjs_css.cpp:
2958         (cssPropertyName):
2959
2960 2005-05-03  Darin Adler  <darin@apple.com>
2961
2962         - fix the build
2963
2964         * WebCore.pbproj/project.pbxproj: Fix some SYMROOTS that should have been SYMROOT.
2965
2966 2005-05-03  David Hyatt  <hyatt@apple.com>
2967
2968         Fix for 4098281, news.com missing a bunch of content.  Make sure not to apply strict SGML parsing
2969         when stripping comments out of scripts.
2970
2971         New test is comments-in-script.html
2972         
2973         * khtml/html/htmltokenizer.cpp:
2974         (khtml::HTMLTokenizer::parseComment):
2975
2976 2005-05-03  David Hyatt  <hyatt@apple.com>
2977
2978         Remove unused notification to avoid ERROR messages spewing on the acid2 test.
2979         
2980         Reviewed by darin
2981
2982         * khtml/khtml_part.cpp:
2983         (KHTMLPart::processObjectRequest):
2984         * khtml/rendering/render_frames.cpp:
2985         (RenderPartObject::updateWidget):
2986         * khtml/rendering/render_frames.h:
2987
2988 2005-05-03  Darin Adler  <darin@apple.com>
2989
2990         Reviewed by Dave Hyatt.
2991         No new layout tests needed.
2992
2993         - eliminated the bogus kMin/kMax macros that we had in addition to inline functions
2994           of the same name
2995
2996         * kwq/KWQKGlobal.h: Remove the kMin/kMax macros.
2997
2998         * khtml/css/cssstyleselector.cpp:
2999         (khtml::CSSStyleSelector::applyProperty): Change type of constant so both sides
3000         of kMin calls match.
3001         (khtml::CSSStyleSelector::fontSizeForKeyword): Ditto.
3002         * khtml/html/htmltokenizer.cpp: (khtml::HTMLTokenizer::parseEntity): Ditto.
3003
3004         - remove unused parameter to dirtyLinesFromChangedChild for clarity
3005
3006         * khtml/rendering/render_object.h: Don't take the parameter.
3007         * khtml/rendering/render_object.cpp: (RenderObject::dirtyLinesFromChangedChild): Ditto.
3008
3009         * khtml/rendering/render_flow.h: Don't take the parameter.
3010         * khtml/rendering/render_flow.cpp:
3011         (RenderFlow::detach): Don't pass the parameter.
3012         (RenderFlow::dirtyLinesFromChangedChild): Don't take the parameter.
3013
3014         * khtml/rendering/render_text.cpp: (RenderText::detach): Don't pass the parameter.
3015
3016         - convert DOM::NodeImpl into an abstract base class by making a couple of functions
3017           pure virtual for clarity
3018
3019         * khtml/xml/dom_nodeimpl.h: Made nodeName and nodeType pure virtual.
3020         * khtml/xml/dom_nodeimpl.cpp: Remove bodies of nodeName and nodeType.
3021
3022 2005-05-03  David Hyatt  <hyatt@apple.com>
3023
3024         Fix for object element to support fallback content.  WIth this change Safari passes the Acid2 test.
3025         
3026         Reviewed by Maciej
3027
3028         * khtml/css/html4.css:
3029         * khtml/html/html_objectimpl.cpp:
3030         (HTMLObjectElementImpl::HTMLObjectElementImpl):
3031         (HTMLObjectElementImpl::parseHTMLAttribute):
3032         (HTMLObjectElementImpl::rendererIsNeeded):
3033         (HTMLObjectElementImpl::createRenderer):
3034         (HTMLObjectElementImpl::attach):
3035         (HTMLObjectElementImpl::detach):
3036         (HTMLObjectElementImpl::recalcStyle):
3037         (HTMLObjectElementImpl::childrenChanged):
3038         (HTMLObjectElementImpl::isURLAttribute):
3039         (HTMLObjectElementImpl::isImageType):
3040         (HTMLObjectElementImpl::renderFallbackContent):
3041         * khtml/html/html_objectimpl.h:
3042         * khtml/khtml_part.cpp:
3043         (KHTMLPart::requestObject):
3044         (KHTMLPart::selectFrameElementInParentIfFullySelected):
3045         (KHTMLPart::handleFallbackContent):
3046         * khtml/khtml_part.h:
3047         * khtml/khtmlpart_p.h:
3048         (khtml::ChildFrame::ChildFrame):
3049         * khtml/rendering/render_frames.cpp:
3050         (RenderPartObject::RenderPartObject):
3051         (RenderPartObject::updateWidget):
3052         * khtml/rendering/render_frames.h:
3053         (khtml::RenderPart::hasFallbackContent):
3054         * khtml/rendering/render_replaced.cpp:
3055         (RenderReplaced::RenderReplaced):
3056         * kwq/KWQKHTMLPart.mm:
3057         (KWQKHTMLPart::createPart):
3058         * kwq/WebCoreBridge.h:
3059         * kwq/WebCoreBridge.mm:
3060         (-[WebCoreBridge mainResourceError]):
3061
3062 2005-05-01  Darin Adler  <darin@apple.com>
3063
3064         - move to Xcode native targets and stop checking in generated files
3065
3066         * WebCore.pbproj/project.pbxproj: Updated to use native targets and generate all the generated
3067         files, so we don't have to check them in any more.
3068         * Info.plist: Added. Native targets use a separate file for this.
3069
3070         * Makefile.am: Removed rule to generate WebCore-combined.exp since this is now handled by the
3071         Xcode project. Removed the code to remove the embedded copy of the framework since we don't
3072         do that any more. Removed timestamp cleaning rules since we don't use those any more.
3073
3074         * WebCore-tests.exp: Removed symbols that aren't really needed. The native target gives an
3075         error when you mention a nonexistent symbol, so we can't have them any more.
3076
3077         * khtml/css/parser_wrapper.cpp: Added. Shell used to compile parser.cpp since we can't add
3078         a generated file easily to the list of files to be compiled.
3079
3080         * .cvsignore: Removed various timestamp files.
3081
3082         * WebCore-combined.exp: Removed.
3083         * force-clean-timestamp: Removed.
3084         * force-js-clean-timestamp: Removed.
3085         * khtml/.cvsignore: Removed.
3086         * khtml/Makefile.am: Removed.
3087         * khtml/css/.cvsignore: Removed.
3088         * khtml/css/Makefile.am: Removed.
3089         * khtml/css/cssproperties.c: Removed.
3090         * khtml/css/cssproperties.h: Removed.
3091         * khtml/css/cssvalues.c: Removed.
3092         * khtml/css/cssvalues.h: Removed.
3093         * khtml/css/parser.cpp: Removed.
3094         * khtml/css/parser.h: Removed.
3095         * khtml/css/tokenizer.cpp: Removed.
3096         * khtml/ecma/.cvsignore: Removed.
3097         * khtml/ecma/Makefile.am: Removed.
3098         * khtml/ecma/kjs_css.lut.h: Removed.
3099         * khtml/ecma/kjs_dom.lut.h: Removed.
3100         * khtml/ecma/kjs_events.lut.h: Removed.
3101         * khtml/ecma/kjs_html.lut.h: Removed.
3102         * khtml/ecma/kjs_navigator.lut.h: Removed.
3103         * khtml/ecma/kjs_range.lut.h: Removed.
3104         * khtml/ecma/kjs_traversal.lut.h: Removed.
3105         * khtml/ecma/kjs_views.lut.h: Removed.
3106         * khtml/ecma/kjs_window.lut.h: Removed.
3107         * khtml/ecma/xmlhttprequest.lut.h: Removed.
3108         * khtml/ecma/xmlserializer.lut.h: Removed.
3109         * khtml/html/.cvsignore: Removed.
3110         * khtml/html/Makefile.am: Removed.
3111         * khtml/html/doctypes.cpp: Removed.
3112         * khtml/html/kentities.c: Removed.
3113         * khtml/misc/.cvsignore: Removed.
3114         * khtml/misc/Makefile.am: Removed.
3115         * khtml/misc/htmlattrs.c: Removed.
3116         * khtml/misc/htmlattrs.h: Removed.
3117         * khtml/misc/htmltags.c: Removed.
3118         * khtml/misc/htmltags.h: Removed.
3119         * kwq/.cvsignore: Removed.
3120         * kwq/KWQCharsetData.c: Removed.
3121         * kwq/KWQColorData.c: Removed.
3122         * kwq/Makefile.am: Removed.
3123
3124 2005-05-02  Darin Adler  <darin@apple.com>
3125
3126         Reviewed by Vicki.
3127         Added two layout tests for regression testing.
3128
3129         - redid frameElement (fix for 4091082 below)
3130
3131         The first version lacked a security check, and was also broken.
3132
3133         * khtml/ecma/kjs_window.cpp:
3134         (frameElement): Refactored into separate function; added isSafeScript check.
3135         (Window::get): Call the new frameElement function.
3136
3137         * layout-tests/fast/frames/frameElement-frame.html: Added.
3138         * layout-tests/fast/frames/frameElement-frame-expected.txt: Added.
3139         * layout-tests/fast/frames/frameElement-iframe.html: Added.
3140         * layout-tests/fast/frames/frameElement-iframe-expected.txt: Added.
3141         * layout-tests/fast/frames/resources/frameElement-contents.html: Added.
3142
3143 2005-05-02  David Harrison  <harrison@apple.com>
3144
3145         Reviewed by Vicki.
3146
3147         Fix isStartOfEditableContent and isEndOfEditableContent to return actual, rather than inverted, answers.
3148         No Radar.  Found this when trying to use isEndOfEditableContent() in some new code.
3149         
3150         * khtml/editing/visible_units.cpp:
3151         (khtml::isStartOfEditableContent):
3152         (khtml::isEndOfEditableContent):
3153         Flip expressions.
3154
3155 2005-04-29  Darin Adler  <darin@apple.com>
3156
3157         Reviewed by David Harrison.
3158
3159         * khtml/xml/dom_nodeimpl.cpp: (NodeImpl::displayNode): Turn newlines into \n for better dumping.
3160
3161 2005-04-29  David Harrison  <harrison@apple.com>
3162
3163         Reviewed by Darin.
3164
3165         <rdar://problem/4083333> When deleting link at end of sentence, entire sentence gets deleted
3166         
3167         * khtml/editing/htmlediting.cpp:
3168         (khtml::DeleteSelectionCommand::initializePositionData):
3169         Work around bug #4103339 (whose real fix is somewhat risky), so this fix can get into a software update.
3170         
3171         (khtml::DeleteSelectionCommand::handleGeneralDelete):
3172         Add isAncestor check when comparing m_downstreamEnd.node() and m_startNode.
3173
3174         * layout-tests/editing/deleting/delete-4083333-fix-expected.txt: Added.
3175         * layout-tests/editing/deleting/delete-4083333-fix.html: Added.
3176
3177 2005-04-29  Darin Adler  <darin@apple.com>
3178
3179         Reviewed by Dave Harrison.
3180
3181         - changed layout tests to dump more minimal information about caret and selection
3182
3183         * kwq/KWQRenderTreeDebug.cpp:
3184         (nodePosition): Changed name; now does position relative to document.
3185         (writeSelection): Removed upstream/downstream code and changed format slightly.
3186
3187         * layout-tests/editing/*-expected.txt: Regenerated in new format.
3188
3189 2005-04-29  Darin Adler  <darin@apple.com>
3190
3191         Reviewed by Chris Blumenberg.
3192         Added two layout tests for regression testing.
3193
3194         - fixed <rdar://problem/4097849> REGRESSION (162-163): importNode creates non-HTML elements, thus style attributes (and some others) don't work
3195
3196         * khtml/xml/dom_docimpl.cpp:
3197         (DocumentImpl::importNode): Reorganized and partly rewrote this. The change that fixes the bug at
3198         hand is to explicitly use XHTML_NAMESPACE for HTML elements, since the old way of getting the namespace
3199         will return the null string for HTML elements, and createElementNS will not create an HTML element
3200         if passed a null string for the namespace.
3201         (DocumentImpl::processHttpEquiv): Removed some bogus getDocument() calls -- no need to call getDocument()
3202         in a document object.
3203         (DocumentImpl::attrName): Ditto.
3204         (DocumentImpl::tagName): Ditto.
3205         (DocumentImpl::setFocusNode): Ditto.
3206
3207         * khtml/html/html_elementimpl.cpp: (HTMLElementImpl::cloneNode): Moved the actual cloning here
3208         from ElementImpl::cloneNode, because XMLElementImpl already had its own version, and in here
3209         we can use createHTMLElement, which will work properly even in an XML document, and is also slightly
3210         more efficient.
3211
3212         * khtml/xml/dom_nodeimpl.h: Added a namespaceURI method function to go along with localName.
3213         * khtml/xml/dom_nodeimpl.cpp: (NodeImpl::namespaceURI): Added. Returns null string to be consistent
3214         with localName (only works on certain types of elements as documented).
3215         * khtml/xml/dom_elementimpl.h: Removed ElementImpl::cloneNode (see above). Added an override of
3216         namespaceURI for XMLElementImpl.
3217         * khtml/xml/dom_elementimpl.cpp: (XMLElementImpl::namespaceURI): Added. Returns the namespace
3218         (consistent with localName).
3219
3220         * layout-tests/fast/dom/importNodeHTML.html: Added. Tests both importNode and cloneNode (for comparison).
3221         * layout-tests/fast/dom/importNodeHTML-expected.txt: Added.
3222         * layout-tests/fast/dom/importNodeXML.xhtml: Added. XML version of the same test as above. Tests a different
3223         code path, so useful to have.
3224         * layout-tests/fast/dom/importNodeXML-expected.txt: Added.
3225
3226 2005-04-28  Darin Adler  <darin@apple.com>
3227
3228         Reviewed by Dave Harrison.
3229
3230         - fixed problems preventing us from compiling with gcc 4.0
3231
3232         * WebCore.pbproj/project.pbxproj: Removed -fobjc-exceptions because I can't figure out an easy
3233         way to pass it only when compiling Objective-C/C++. Removed -Wmissing-prototypes from
3234         WARNING_CPLUSPLUSFLAGS since it's now a C-only warning.
3235
3236         * khtml/css/parser.y: Changed some rules that were using a float to pass around an enum to use an
3237         int instead to avoid a warning.
3238         * khtml/css/parser.cpp: Regenerated.
3239         * khtml/css/parser.h: Regenerated.
3240
3241         * khtml/ecma/kjs_dom.cpp: (DOMTextProtoFunc::tryCall): Rearranged a return statement to avoid an incorrect
3242         warning.
3243         * khtml/ecma/kjs_html.cpp: (KJS::Context2DFunction::tryCall): Initialized a couple of variables to avoid
3244         an incorrect warning.
3245         * khtml/ecma/kjs_proxy.cpp: (KJSProxyImpl::evaluate): Rearranged how we exit from the function to avoid
3246         an incorret warning.
3247         * khtml/editing/selection.cpp: (khtml::Selection::debugPosition): Changed some %d to %ld where the
3248         parameters where long ints.
3249         * khtml/editing/visible_position.cpp: (khtml::VisiblePosition::debugPosition): Ditto.
3250         * khtml/xml/dom_position.cpp: (DOM::Position::debugPosition): Ditto.
3251         * kwq/DOMEvents.mm: (-[DOMMouseEvent initMouseEvent:::::::::::::::]): Rearranged code to avoid a cast
3252         that was causing an incorrect warning.
3253         * kwq/DOMUtility.mm:
3254         (createObjCDOMNode): Broke out as a separate function.
3255         (KJS::ScriptInterpreter::createObjcInstanceForValue): Rearranged code to avoid a namespace collision with
3256         KJS::DOMNode and the Objective-C DOMNode class.
3257         * kwq/KWQFileButton.mm: Made fields of KWQFileButtonAdapter public to avoid an error, new to gcc 4.0,
3258         about accessing protected Objective-C fields.
3259         * kwq/KWQKHTMLPart.mm:
3260         (KWQKHTMLPart::matchLabelsAgainstElement): Rearranged a return statement to avoid an incorrect warning.
3261         (KWQKHTMLPart::imageFromRect): Rearranged how this function does its exception handling to avoid a
3262         "may be clobbered" warning.
3263         * kwq/KWQKJavaAppletWidget.mm: Fixed incorrect import that said "KHTMLView.h" instead of "khtmlview.h".
3264         * kwq/KWQObject.mm: Made fields of KWQObjectTimerTarget public to avoid an error, new to gcc 4.0,
3265         about accessing protected Objective-C fields.
3266         * kwq/WebCoreBridge.mm: (partHasSelection): Used [bridge part] instead of getting directly at instance
3267         variable to avoid an error, new to gcc 4.0, about accessing protected Objective-C fields.
3268
3269         * WebCore-combined.exp: Regenerated.
3270         * WebCore-tests.exp: Added some additional symbols needed by the tests under gcc 4.0.
3271
3272 2005-04-28  Darin Adler  <darin@apple.com>
3273
3274         * WebCore.pbproj/project.pbxproj: Add back the main_thread_malloc files, rolled out by accident.
3275
3276 2005-04-27 Adele Peterson  <adele@apple.com>
3277
3278         Rolling out fix for <rdar://problem/4097849> because the following layout tests were failing:
3279
3280         fast/css/namespaces/001
3281         fast/css/namespaces/002
3282         fast/css/namespaces/004
3283         fast/css/namespaces/005
3284         fast/css/namespaces/006
3285         fast/overflow/003
3286         
3287
3288         * khtml/html/html_documentimpl.cpp:
3289         * khtml/html/html_documentimpl.h:
3290         * khtml/html/html_elementimpl.cpp:
3291         (HTMLElementImpl::namespaceURI):
3292         * khtml/xml/dom_docimpl.cpp:
3293         (DocumentImpl::importNode):
3294         (DocumentImpl::createElementNS):
3295         (DocumentImpl::createHTMLElement):
3296         (DocumentImpl::attrId):
3297         (DocumentImpl::tagId):
3298         * khtml/xml/dom_docimpl.h:
3299
3300 2005-04-27  John Sullivan  <sullivan@apple.com>
3301
3302         Reviewed by Darin.
3303         
3304         Experimental prototype of user-resizable textareas. All the new code is guarded by
3305         #if ALLOW_RESIZING_TEXTAREAS, which is false unless you remove a comment and rebuild.
3306         
3307         This code allows you to press near the bottom-right corner of any textarea and drag
3308         to resize the textarea on the page. It works correctly with textareas in left-aligned
3309         or centered blocks, but is weird in right-aligned blocks. It also does something
3310         sensible if the width is specified as a % (in that case, you can resize vertically only).
3311         The user-created-size survives resizing the window and survives the back/forward cache.
3312         It does not survive reloading the page.
3313         
3314         This complete-lack-of-affordance UI is obviously not shippable, but this proof of concept
3315         code could lead to a real user feature.
3316
3317         * kwq/KWQTextArea.mm:
3318         (-[KWQTextArea getNumColumns:andNumRows:forSize:]):
3319         new method that determines cols and rows for a given textarea frame size
3320         (-[KWQTextAreaTextView _trackResizeFromMouseDown:]):
3321         new method that tracks a drag and does a live resize-and-relayout
3322         (-[KWQTextAreaTextView mouseDown:]):
3323         if the mouse down is in the bottom-right corner, call _trackResizeFromMouseDown:
3324
3325 2005-04-27  John Sullivan  <sullivan@apple.com>
3326
3327         Reviewed by Adele.
3328
3329         - fixed problem with mouse wheel patch where alt and shift keys were switched
3330
3331         * khtml/xml/dom2_eventsimpl.h:
3332         use the order cntl, alt, shift, meta in KeyboardEventImpl constructors to match
3333         superclass. This isn't necessary to fix the bug, but is better for clarity.
3334         
3335         * khtml/xml/dom2_eventsimpl.cpp:
3336         (KeyboardEventImpl::KeyboardEventImpl):
3337         switch parameter order to match superclass. Then pass the parameters to superclass's
3338         constructor in the right order.
3339         (KeyboardEventImpl::initKeyboardEvent):
3340         Pass parameters to superclass's constructor in the right order.
3341
3342 2005-04-26  Adele Peterson  <adele@apple.com>
3343
3344         Fixed by Darin, reviewed by me.
3345
3346         Fix for <rdar://problem/4084029> designMode doesn't allow editing when iframe src = "" or = about:blank
3347         
3348         This change will add an HTML element for empty documents.  Now that there will be an HTMLDocument in this case, 
3349         a body will also be created (see rdar://problem/3758785). This was preventing frames with empty documents from 
3350         being editable.
3351
3352         * khtml/html/htmlparser.cpp: (KHTMLParser::finished):
3353
3354         Updated these tests to expect the HTML and BODY elements
3355         * layout-tests/fast/flexbox/016-expected.txt:
3356         * layout-tests/fast/frames/001-expected.txt:
3357         * layout-tests/fast/frames/002-expected.txt:
3358         * layout-tests/fast/frames/contentWindow_Frame-expected.txt:
3359         * layout-tests/fast/frames/contentWindow_iFrame-expected.txt:
3360         * layout-tests/fast/frames/empty-frame-src-expected.txt:
3361
3362 2005-04-26  Maciej Stachowiak  <mjs@apple.com>
3363
3364         New test case for <rdar://problem/4092136> reproducible crash in KJS::kjs_fast_realloc loading maps.google.com
3365
3366         * layout-tests/fast/js/string-from-char-code-expected.txt: Added.
3367         * layout-tests/fast/js/string-from-char-code.html: Added.
3368
3369 2005-04-26  Darin Adler  <darin@apple.com>
3370
3371         Reviewed by John.
3372
3373         - fixed <rdar://problem/3655817> please add support for mouse wheel events and the onmousewheel handler
3374
3375         Loose ends:
3376
3377             - need to test behavior of Windows IE with horizontal scroll wheeling; we currently send a distinct event
3378               for that relatively obscure case, which means the event handlers won't fire at all; might be incorrect
3379             - overflow scrolling is done after all DOM event handling, but ideally should be done in the overflowing
3380               element's default event handler; not important in practice
3381             - frame scrolling is done after all DOM event handling, but probably should be done in a default event handler;
3382               not sure about this, but it's probably not important in practice and definitely not required
3383
3384         - JavaScript
3385
3386         * khtml/ecma/kjs_events.h: Added DOMWheelEvent.
3387         * khtml/ecma/kjs_events.cpp:
3388         (KJS::getDOMEvent): Added a case for wheel event. To be forward looking, I use the event's impl pointer
3389         instead of a C++ DOM wrapper. Eventually it will all work this way.
3390         (offsetFromTarget): Added. Factored out code to compute offsetX/Y for an event.
3391         (DOMMouseEvent::getValueProperty): Changed to call offsetFromTarget for offsetX/Y.
3392         (DOMWheelEvent::DOMWheelEvent): Added.