2007-01-23 Mark Rowe <mrowe@apple.com>
[WebKit-https.git] / WebCore / ChangeLog
1 2007-01-23  Mark Rowe  <mrowe@apple.com>
2
3         Reviewed by Brady.
4
5         Plug thousands of node leaks seen running layout tests.
6
7         * ksvg2/svg/SVGElementInstance.cpp:
8         (WebCore::SVGElementInstance::~SVGElementInstance): Disassociate ourselves from our children so they will
9         be destroyed if we were the only thing referencing them.
10         * ksvg2/svg/SVGUseElement.cpp:
11         (WebCore::SVGUseElement::removedFromDocument):
12         * ksvg2/svg/SVGUseElement.h:
13
14 2007-01-23  Alice Liu  <alice.liu@apple.com>
15
16         Reviewed by Brady.
17
18         * editing/Editor.cpp:
19         (WebCore::Editor::appliedEditing):
20         minor change.  removing unnecessary call to frame to fetch editor
21
22 2007-01-23  Mark Rowe  <mrowe@apple.com>
23
24         Reviewed by Adele.
25
26         http://bugs.webkit.org/show_bug.cgi?id=12375
27         Bug 12375: REGRESSION(r19038): fast/dom/title-text-property-2.html failing
28
29         Fix regression by making setTitle/updateTitle/removeTitle logic match document.title
30         specification at http://whatwg.org/specs/web-apps/current-work/#the-title1.
31
32         * dom/Document.cpp:
33         (WebCore::Document::setTitle): Materialize a title element into the head if one doesn't exist when setting
34         document.title.  Also update the contents of the title element when the title is set via document.title.
35         (WebCore::Document::removeTitle): Update the title based on first title element in the head, if one exists.
36         (WebCore::Document::head): Convenience method to retrieve the head element in an HTML document.
37         * dom/Document.h:
38
39 2007-01-23  Beth Dakin  <bdakin@apple.com>
40
41         Reviewed by Hyatt.
42
43         Follow-up to the fix below for 4843226.
44
45         * rendering/RenderLayer.cpp:
46         (WebCore::transparencyClipBox): Has to be recursive or we will miss 
47         out on grandchildren!
48
49 2007-01-23  Oliver Hunt  <oliver@apple.com>
50
51         Reviewed by Adam.
52
53         Fixes dropping of files into safari
54
55         * page/DragController.cpp:
56         (WebCore::DragController::performDrag):
57
58 2007-01-23  Brady Eidson  <beidson@apple.com>
59
60         Reviewed by Darin
61
62         Added a couple of CF things previously missed
63
64         * platform/network/ResourceError.h:
65         * platform/network/ResourceHandle.h:
66
67 2007-01-23  Nikolas Zimmermann  <zimmermann@kde.org>
68
69         Reviewed by Maciej.
70
71         Fix evil genericContext() assertion, which occours sometimes when running DRT.
72         Fixes: http://bugs.webkit.org/show_bug.cgi?id=12379
73
74         * bindings/scripts/CodeGeneratorJS.pm:
75         * ksvg2/misc/SVGDocumentExtensions.h:
76         (WebCore::SVGDocumentExtensions::genericContextMap):
77         (WebCore::SVGDocumentExtensions::forgetGenericContext):
78
79 2007-01-23  Beth Dakin  <bdakin@apple.com>
80
81         Reviewed by Hyatt.
82
83         Fix for <rdar://problem/4843226> REGRESSION: Pull down menu appears 
84         clipped at http://istweb.apple.com/
85
86         * rendering/RenderLayer.cpp:
87         (WebCore::transparencyClipBox): Always unite with sibling rects.
88
89 2007-01-22  Justin Garcia  <justin.garcia@apple.com>
90
91         Reviewed by john
92
93         <rdar://problem/4920742>
94         REGRESSION: GMail Editor: Attempting to remove formatting from selection results in a crash at WebCore::Range::checkDeleteExtract()
95
96         * dom/Range.cpp:
97         (WebCore::Range::checkDeleteExtract): Return if there is no
98         commonAncestor container or if commonAncestorContainer() throws
99         an exception.
100         * editing/Editor.cpp:
101         (WebCore::Editor::removeFormattingAndStyle): Fixed a bug that reversed
102         the order of the selected paragraphs.
103
104 2007-01-23  Nikolas Zimmermann  <zimmermann@kde.org>
105
106         Reviewed by Sam.
107
108         Fix dynamic creation/updates of markers, masks, clipPaths, and several tiny pattern issues.
109         Added 16 (!) new layout tests covering quite some weird scenerios - Batik & Opera do have problems, we don't.
110
111         Fixes: http://bugs.webkit.org/show_bug.cgi?id=12380
112         Fixes: svg/custom/image-with-transform-clip-filter.svg (filter shows up again)
113
114         Added: svg/custom/clip-path-child-changes.svg
115         Added: svg/custom/clip-path-href-changes.svg
116         Added: svg/custom/clip-path-units-changes.svg
117         Added: svg/custom/deep-dynamic-updates.svg
118         Added: svg/custom/js-late-clipPath-and-object-creation.svg
119         Added: svg/custom/js-late-clipPath-creation.svg
120         Added: svg/custom/js-late-marker-and-object-creation.svg
121         Added: svg/custom/js-late-marker-creation.svg
122         Added: svg/custom/js-late-mask-and-object-creation.svg
123         Added: svg/custom/js-late-mask-creation.svg
124         Added: svg/custom/js-update-pattern-child.svg
125         Added: svg/custom/marker-changes.svg
126         Added: svg/custom/marker-child-changes.svg
127         Added: svg/custom/marker-viewBox-changes.svg
128         Added: svg/custom/mask-changes.svg
129         Added: svg/custom/mask-child-changes.svg
130
131         * ksvg2/misc/KCanvasRenderingStyle.cpp:
132         (WebCore::KSVGPainterFactory::fillPaintServer):
133         (WebCore::KSVGPainterFactory::strokePaintServer):
134         * ksvg2/svg/SVGClipPathElement.cpp:
135         (WebCore::SVGClipPathElement::notifyAttributeChange):
136         * ksvg2/svg/SVGClipPathElement.h:
137         * ksvg2/svg/SVGGradientElement.cpp:
138         * ksvg2/svg/SVGGradientElement.h:
139         * ksvg2/svg/SVGMarkerElement.cpp:
140         (WebCore::SVGMarkerElement::canvasResource):
141         (WebCore::SVGMarkerElement::notifyAttributeChange):
142         * ksvg2/svg/SVGMarkerElement.h:
143         * ksvg2/svg/SVGMaskElement.cpp:
144         (WebCore::SVGMaskElement::notifyAttributeChange):
145         * ksvg2/svg/SVGMaskElement.h:
146         * ksvg2/svg/SVGStopElement.cpp:
147         (WebCore::SVGStopElement::notifyAttributeChange):
148         * ksvg2/svg/SVGStyledElement.cpp:
149         (WebCore::SVGStyledElement::notifyAttributeChange):
150         (WebCore::SVGStyledElement::notifyResourceParentIfExistant):
151         (WebCore::SVGStyledElement::rebuildRenderer):
152         * ksvg2/svg/SVGStyledElement.h:
153         * ksvg2/svg/SVGUseElement.cpp:
154         (WebCore::SVGUseElement::notifyAttributeChange):
155         * platform/graphics/svg/SVGResource.cpp:
156         (WebCore::SVGResource::invalidate):
157         (WebCore::SVGResource::addClient):
158         (WebCore::SVGResource::repaintClients):
159         * platform/graphics/svg/SVGResource.h:
160         * platform/graphics/svg/SVGResourceMarker.cpp:
161         (WebCore::SVGResourceMarker::draw):
162         (WebCore::SVGResourceMarker::cachedBounds):
163         * platform/graphics/svg/SVGResourceMarker.h:
164         * rendering/RenderPath.cpp:
165         (WebCore::RenderPath::layout):
166         (WebCore::RenderPath::getAbsoluteRepaintRect):
167         (WebCore::RenderPath::paint):
168         (WebCore::drawMarkerWithData):
169         (WebCore::RenderPath::drawMarkersIfNeeded):
170         * rendering/RenderPath.h:
171         * rendering/RenderSVGContainer.cpp:
172         (WebCore::RenderSVGContainer::paint):
173         (WebCore::RenderSVGContainer::getAbsoluteRepaintRect):
174         * rendering/RenderSVGImage.cpp:
175         (WebCore::RenderSVGImage::paint):
176         (WebCore::RenderSVGImage::getAbsoluteRepaintRect):
177         * rendering/SVGInlineFlowBox.cpp:
178         (WebCore::paintSVGInlineFlow):
179
180 2007-01-23  Adele Peterson  <adele@apple.com>
181
182         Reviewed by Darin.
183         
184         WebCore part of fix for <rdar://problem/4946753>REGRESSION: Inserting tabs is broken in Mail
185
186         In addition to this fix, I also reorganized some event handling code for keyPress events to
187         prepare for another fix.  There's also just a little bit of unrelated cleanup.
188         
189         * dom/EventTargetNode.cpp: (WebCore::EventTargetNode::defaultEventHandler):
190           Move tab focus behavior into new defaultKeyboardEventHandler method.
191         
192         * bridge/EditorClient.h: Added handleKeyPress.
193         * editing/Editor.cpp:
194         (WebCore::Editor::handleKeyPress): Added. Calls over to the client method.
195         (WebCore::Editor::deleteRange): Removed unnecessary propogateDOMException.
196         * editing/Editor.h: Added handleKeyPress.
197         (WebCore::Editor::addToKillRing): Formatting cleanup.
198         * editing/mac/EditorMac.mm: Removed unnecessary propogateDOMException.
199         
200         * page/EventHandler.cpp: (WebCore::EventHandler::defaultKeyboardEventHandler): Added. Checks
201           the tabKeyCyclesThroughElements setting before advancing focus for tab key events.  Calls handleKeyPress.
202         * page/EventHandler.h: Added defaultKeyboardEventHandler.
203         
204         * page/Page.cpp: (WebCore::Page::Page): Initialize m_tabKeyCyclesThroughElements to true.
205         * page/Page.h: Added m_tabKeyCyclesThroughElements.
206         (WebCore::Page::setTabKeyCyclesThroughElements): Added.
207         (WebCore::Page::tabKeyCyclesThroughElements): Added.
208         
209         * platform/PlatformKeyboardEvent.h: Added ability to get NSEvent from PlatformKeyboardEvent.
210         * platform/mac/KeyEventMac.mm: (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):
211           Initialize m_macEvent to the NSEvent.
212         
213         * platform/graphics/svg/SVGImageEmptyClients.h: (WebCore::SVGEmptyEditorClient::handleKeyPress): Added.
214
215 2007-01-23  George Staikos  <staikos@kde.org>
216
217         Compile with a released Qt.
218
219         * platform/graphics/qt/ImageQt.cpp:
220
221 2007-01-23  Lars Knoll <lars@trolltech.com>
222
223         Reviewed by Zack
224
225         Widget and ScrollView do not own the Qt widgets
226         anymore. Make sure they can handle the case of
227         a null QWidget and never delete them.
228
229         * platform/qt/ScrollViewQt.cpp:
230         (WebCore::ScrollView::setScrollArea):
231         (WebCore::ScrollView::updateContents):
232         (WebCore::ScrollView::visibleWidth):
233         (WebCore::ScrollView::visibleHeight):
234         (WebCore::ScrollView::visibleContentRect):
235         (WebCore::ScrollView::setContentsPos):
236         (WebCore::ScrollView::resizeContents):
237         (WebCore::ScrollView::contentsX):
238         (WebCore::ScrollView::contentsY):
239         (WebCore::ScrollView::contentsWidth):
240         (WebCore::ScrollView::contentsHeight):
241         (WebCore::ScrollView::scrollOffset):
242         (WebCore::ScrollView::scrollBy):
243         (WebCore::ScrollView::hScrollbarMode):
244         (WebCore::ScrollView::vScrollbarMode):
245         (WebCore::ScrollView::setHScrollbarMode):
246         (WebCore::ScrollView::setVScrollbarMode):
247         * platform/qt/WidgetQt.cpp:
248         (WebCore::WidgetPrivate::~WidgetPrivate):
249         (WebCore::Widget::setQWidget):
250
251 2007-01-23  Zack Rusin  <zack@kde.org>
252
253         Forgot to add one new file to the build.
254
255         * WebCore.pro: Add dom/clipboard.cpp
256
257 2007-01-23  Zack Rusin  <zack@kde.org>
258
259         Fix the Qt build
260
261         * page/DragActions.h:
262         * page/DragController.cpp:
263         * platform/qt/DragDataQt.cpp:
264         (WebCore::DragData::canSmartReplace):
265         (WebCore::DragData::containsColor):
266         (WebCore::DragData::containsPlainText):
267         (WebCore::DragData::asPlainText):
268         (WebCore::DragData::asColor):
269         (WebCore::DragData::createClipboard):
270         (WebCore::DragData::containsCompatibleContent):
271         (WebCore::DragData::containsURL):
272         (WebCore::DragData::asURL):
273         (WebCore::DragData::asFragment):
274         * platform/qt/FileChooserQt.cpp:
275
276 2007-01-23  Lars Knoll <lars@trolltech.com>
277
278         Reviewed by Maciej
279
280         Make the last remaining pieces of the FrameLoader platform 
281         independent. Move most of the code over to WebFrameLoaderClient.
282         Some smaller cleanups in the WebFrameBridge, and moved some
283         platform independent functionality over to the shared code
284         in WebCore.
285         
286         * WebCore.exp:
287         * WebCore.pro:
288         * WebCore.xcodeproj/project.pbxproj:
289         * loader/FrameLoader.cpp:
290         (WebCore::FrameLoader::loadSubframe):
291         (WebCore::FrameLoader::shouldUsePlugin):
292         (WebCore::FrameLoader::loadPlugin):
293         (WebCore::FrameLoader::detachFromParent):
294         (WebCore::FrameLoader::partClearedInBegin):
295         (WebCore::FrameLoader::createJavaAppletWidget):
296         (WebCore::FrameLoader::didChangeTitle):
297         * loader/FrameLoader.h:
298         * loader/FrameLoaderClient.h:
299         * loader/FrameLoaderTypes.h:
300         (WebCore::):
301         * loader/PluginDocument.cpp:
302         (WebCore::PluginTokenizer::writeRawData):
303         * loader/mac/FrameLoaderMac.mm: Removed.
304         * loader/qt/FrameLoaderQt.cpp: Removed.
305         * page/Frame.cpp:
306         (WebCore::Frame::Frame):
307         * page/FrameView.cpp:
308         (WebCore::FrameView::mediaType):
309         * page/qt/FrameQt.cpp:
310         (WebCore::FrameQt::FrameQt):
311         * platform/graphics/svg/SVGImageEmptyClients.h:
312         (WebCore::SVGEmptyFrameLoaderClient::makeRepresentation):
313         (WebCore::SVGEmptyFrameLoaderClient::dispatchDidLoadResourceFromMemoryCache):
314         (WebCore::SVGEmptyFrameLoaderClient::dispatchDidCommitLoad):
315         (WebCore::SVGEmptyFrameLoaderClient::dispatchDidFailLoad):
316         (WebCore::SVGEmptyFrameLoaderClient::dispatchCreatePage):
317         (WebCore::SVGEmptyFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
318         (WebCore::SVGEmptyFrameLoaderClient::dispatchUnableToImplementPolicy):
319         (WebCore::SVGEmptyFrameLoaderClient::revertToProvisionalState):
320         (WebCore::SVGEmptyFrameLoaderClient::setMainDocumentError):
321         (WebCore::SVGEmptyFrameLoaderClient::startDownload):
322         (WebCore::SVGEmptyFrameLoaderClient::committedLoad):
323         (WebCore::SVGEmptyFrameLoaderClient::shouldFallBack):
324         (WebCore::SVGEmptyFrameLoaderClient::willUseArchive):
325         (WebCore::SVGEmptyFrameLoaderClient::createDocumentLoader):
326         (WebCore::SVGEmptyFrameLoaderClient::createFrame):
327         (WebCore::SVGEmptyFrameLoaderClient::createPlugin):
328         (WebCore::SVGEmptyFrameLoaderClient::createJavaAppletWidget):
329         (WebCore::SVGEmptyFrameLoaderClient::objectContentType):
330         (WebCore::SVGEmptyFrameLoaderClient::overrideMediaType):
331         (WebCore::SVGEmptyFrameLoaderClient::redirectDataToPlugin):
332         (WebCore::SVGEmptyFrameLoaderClient::windowObjectCleared):
333
334 2007-01-23  Oliver Hunt  <oliver@apple.com>
335
336         Reviewed by Adam.
337
338         Added DragController to handled drag and drop state and control logic.
339         Currently this only handles logic for Dragging and Dropping, and is 
340         unable to initialise a drag itself.
341
342         platform/DragData encapsulate the paltform Drag data (NSDraggingInfo on Mac, 
343         QMimeType in Qt).  This provides methods to pull data out the drag data as a String, 
344         a URL, a DocumentFragment (for rich content), or a Colour.
345
346         * WebCore.exp:
347         * WebCore.pro:
348         * WebCore.xcodeproj/project.pbxproj:
349         * dom/Clipboard.cpp: Added.
350         (WebCore::Clipboard::setAccessPolicy):
351         (WebCore::dragOpFromIEOp):
352         (WebCore::IEOpFromDragOp):
353         (WebCore::Clipboard::sourceOperation):
354         (WebCore::Clipboard::destinationOperation):
355         (WebCore::Clipboard::setSourceOperation):
356         (WebCore::Clipboard::setDestinationOperation):
357         (WebCore::Clipboard::setDropEffect):
358         (WebCore::Clipboard::setEffectAllowed):
359           move platform independent functions from ClipboardMac to Clipboard
360
361         * dom/Clipboard.h:
362         (WebCore::Clipboard::Clipboard):
363         (WebCore::Clipboard::dropEffect):
364         (WebCore::Clipboard::effectAllowed):
365         (WebCore::Clipboard::policy):
366           as above -- also removed virtual modifier from now 
367           platform independent methods
368
369         * editing/Editor.cpp:
370         (WebCore::Editor::smartInsertDeleteEnabled): 
371         (WebCore::Editor::shouldApplyStyle):
372         * editing/Editor.h:
373           adding calls through to EditorClient
374          
375         * page/DragActions.h: Added.
376         (WebCore::):
377           Replicates a number of NS* enums in the WebCore namespace
378
379         * page/DragClient.h: Added.
380         (WebCore::DragClient::~DragClient):
381           Standard client interface for dragging UIDelegate
382
383         * page/DragController.cpp: Added.
384         (WebCore::createMouseEvent):
385         (WebCore::DragController::DragController):
386         (WebCore::DragController::~DragController):
387         (WebCore::documentFragmentFromDragData):
388         (WebCore::DragController::isMoveDrag):
389         (WebCore::visiblePositionForPoint):
390         (WebCore::DragController::cancelDrag):
391         (WebCore::documentAtPoint):
392         (WebCore::DragController::dragEntered):
393         (WebCore::DragController::dragExited):
394         (WebCore::DragController::dragUpdated):
395         (WebCore::DragController::performDrag):
396         (WebCore::DragController::dragEnteredOrUpdated):
397         (WebCore::DragController::tryDocumentDrag):
398         (WebCore::DragController::operationForLoad):
399         (WebCore::DragController::concludeDrag):
400         (WebCore::DragController::canProcessDrag):
401         (WebCore::DragController::tryDHTMLDrag):
402           Class to handle state and logic for dragging and dropping
403
404         * page/DragController.h: Added.
405         (WebCore::DragController::client):
406         (WebCore::DragController::didInitiateDrag):
407         (WebCore::DragController::isHandlingDrag):
408         (WebCore::DragController::dragOperation):
409         (WebCore::DragController::document):
410         (WebCore::DragController::dragInitiator):
411         (WebCore::DragController::dragDestinationAction):
412         (WebCore::DragController::dragSourceAction):
413         (WebCore::DragController::dragEnded):
414         (WebCore::DragController::setIsHandlingDrag):
415         (WebCore::DragController::setDidInitiateDrag):
416         (WebCore::DragController::setDragOperation):
417         (WebCore::DragController::setDragSourceAction):
418         (WebCore::DragController::setDragInitiator):
419           See above
420
421         * page/Page.cpp:
422         (WebCore::Page::Page):
423           Update Page to have DragController
424
425         * page/Page.h:
426         (WebCore::Page::dragController):
427           ditto
428
429         * page/mac/DragControllerMac.mm: Added.
430         (WebCore::DragController::isCopyKeyDown):
431         (WebCore::DragController::dragOperation):
432           Platform specific portions of the DragController
433
434         * page/mac/EventHandlerMac.mm:
435         (WebCore::EventHandler::handleDrag):
436         (WebCore::EventHandler::dragSourceEndedAt):
437           Convert from NSDragOperation to WebCore::DragOperation
438
439         * page/mac/WebCoreFrameBridge.h:
440         * page/mac/WebCoreFrameBridge.mm:
441           Remove obsolete Drag functions
442
443         * page/qt/DragControllerQt.cpp: Added.
444         (WebCore::DragController::isCopyKeyDown):
445         (WebCore::DragController::dragOperation):
446           Basic stubs to maintain Qt  build
447
448         * platform/DragData.cpp: Added.
449         (WebCore::DragData::DragData):
450         * platform/DragData.h: Added.
451         (WebCore::DragData::clientPosition):
452         (WebCore::DragData::globalPosition):
453         (WebCore::DragData::platformData):
454         (WebCore::DragData::draggingSourceOperationMask):
455           DragData class to encapsulate platform drag data/event
456
457         * platform/graphics/svg/SVGImage.cpp:
458         (WebCore::SVGImage::setData):
459           Addition of dummy DragClient
460
461         * platform/graphics/svg/SVGImageEmptyClients.h:
462         (WebCore::SVGEmptyDragClient::~SVGEmptyDragClient):
463         (WebCore::SVGEmptyDragClient::willPerformDragDestinationAction):
464         (WebCore::SVGEmptyDragClient::actionMaskForDrag):
465         (WebCore::SVGEmptyDragClient::dragControllerDestroyed):
466           ditto
467
468         * platform/mac/ClipboardMac.h:
469         * platform/mac/ClipboardMac.mm:
470         (WebCore::ClipboardMac::ClipboardMac):
471         (WebCore::ClipboardMac::clearData):
472         (WebCore::ClipboardMac::clearAllData):
473         (WebCore::ClipboardMac::getData):
474         (WebCore::ClipboardMac::setData):
475         (WebCore::ClipboardMac::types):
476         (WebCore::ClipboardMac::setDragImage):
477          Moving platform independent logic to Clipboard, and updating
478          platform specific methods to use appropriate accessors rather than 
479          directly manipulating data they no longer own
480
481         * platform/mac/DragDataMac.mm: Added.
482         (WebCore::DragData::DragData):
483         (WebCore::DragData::canSmartReplace):
484         (WebCore::DragData::containsColor):
485         (WebCore::DragData::containsPlainText):
486         (WebCore::DragData::asPlainText):
487         (WebCore::DragData::asColor):
488         (WebCore::DragData::createClipboard):
489         (WebCore::imageExistsAtPaths):
490         (WebCore::DragData::containsCompatibleContent):
491         (WebCore::DragData::containsURL):
492         (WebCore::DragData::asURL):
493         (WebCore::DragData::asFragment):
494           Mac implementations of DragData methods.  A number of these use
495           a Helper class that accesses WebKit functionality.  That functionality 
496           should be migrated to WebCore in the future.
497
498         * platform/mac/PasteboardHelper.h: Added.
499         (WebCore::PasteboardHelper::~PasteboardHelper):
500           Temporary, and Mac only, helper class to access WebKit functionality 
501           from WebCore
502
503         * platform/qt/DragDataQt.cpp: Added.
504         (WebCore::DragData::canSmartReplace):
505         (WebCore::DragData::containsColor):
506         (WebCore::DragData::containsPlainText):
507         (WebCore::DragData::asPlainText):
508         (WebCore::DragData::asColor):
509         (WebCore::DragData::createClipboard):
510         (WebCore::DragData::containsCompatibleContent):
511         (WebCore::DragData::containsURL):
512         (WebCore::DragData::asURL):
513         (WebCore::DragData::asFragment):
514          Basic stubs to maintain Qt build
515
516         * rendering/HitTestResult.cpp:
517         (WebCore::HitTestResult::HitTestResult):
518          Correct HitTestResult copy contructor to copy localPoint
519
520 2007-01-22  Mark Rowe  <mrowe@apple.com>
521
522         Reviewed by Maciej.
523
524         http://bugs.webkit.org/show_bug.cgi?id=11692
525         Bug 11692: REGRESSION(r17352): Disappearing page title
526
527         * dom/Document.cpp:
528         (WebCore::Document::setTitle): If the title has already been set explicitly via JavaScript,
529         ignore any changes to it due to encountering <title> tags.
530
531 2007-01-22  Mitz Pettel  <mitz@webkit.org>
532
533         Reviewed by Darin.
534
535         - fix http://bugs.webkit.org/show_bug.cgi?id=12344
536           NativeListBox: item hit testing does not account for top padding and border
537
538         Test: fast/forms/listbox-selection-2.html
539
540         * rendering/RenderListBox.cpp:
541         (WebCore::RenderListBox::numVisibleItems): Changed height() to contentHeight()
542         since items are visible only in the content box.
543         (WebCore::RenderListBox::listIndexAtOffset): Adjusted for vertical padding and
544         borders. Changed to return -1 instead of the last item's index if the given offset
545         is below the last item.
546         (WebCore::RenderListBox::autoscroll): Adjusted for vertical padding and borders.
547         (WebCore::RenderListBox::controlClipRect): Changed to return the content box since
548         items should not spill into the padding box. This change is the reason the test
549         generates pixel results.
550
551 2007-01-22  Justin Garcia  <justin.garcia@apple.com>
552
553         Reviewed by darin
554         
555         <rdar://problem/4944770>
556         editing/pasteboard/4641033 layout test is broken (12328)
557         
558         This layout test failure demonstrates three bugs:
559         Smart replace shouldn't be turned on, but is because a word
560         selection granularity from the previous test isn't cleared.
561         Smart replace shouldn't add any spaces because the paste is performed
562         in an empty paragraph.
563         Smart replace spaces are added to the text of options inside
564         the select element instead of before/after the select element.
565         
566         This patch fixes the second two problems.  During a 
567         ReplaceSelectionCommand, the VisiblePosition for the end of 
568         the inserted content is the last position in the last leaf 
569         inserted.  This is a problem when the last leaf is inside a 
570         select element, since VP creation is inconsistent there.  
571         Second, smart spaces were inserted inside the last leaf, not
572         at the endOfInsertedContent.
573
574         * editing/ReplaceSelectionCommand.cpp:
575         (WebCore::ReplaceSelectionCommand::shouldMergeStart): Renamed 
576         m_lastNodeInserted to m_lastLeafInserted.  Use the 
577         start/endOfInsertedContent getters.
578         (WebCore::ReplaceSelectionCommand::shouldMergeEnd): Ditto.
579         (WebCore::ReplaceSelectionCommand::removeNodePreservingChildren): Ditto.
580         (WebCore::ReplaceSelectionCommand::removeRedundantStyles): Ditto.
581         (WebCore::ReplaceSelectionCommand::positionAtEndOfInsertedContent): Added.
582         Special case for when the last leaf inserted is inside a select 
583         element: return the VisiblePosition after the select element.
584         (WebCore::ReplaceSelectionCommand::positionAtStartOfInsertedContent): Added.
585         (WebCore::ReplaceSelectionCommand::doApply): Did renaming.  Used
586         the start/endOfInsertedContent getters.  Insert smart replace spaces
587         into the right nodes.
588         (WebCore::ReplaceSelectionCommand::shouldRemoveEndBR): Renaming.
589         (WebCore::ReplaceSelectionCommand::completeHTMLReplacement): Ditto.
590         (WebCore::ReplaceSelectionCommand::updateNodesInserted): Ditto.
591         * editing/ReplaceSelectionCommand.h:
592
593 2007-01-22  Darin Adler  <darin@apple.com>
594
595         Reviewed by Adam.
596
597         - fix http://bugs.webkit.org/show_bug.cgi?id=12273
598           REGRESSION: File input value invisible after removing and re-appending
599
600         - made more of the file chooser code cross-platform
601
602         - fixed an Objective-C garbage collection problem in FileChooser
603
604         - tried to remove layering violations where FileChooser in the platform
605           directory knows about the rendering and DOM trees (but wasn't able to
606           do it entirely)
607
608         * platform/FileChooser.cpp: Added.
609         (WebCore::FileChooser::create): Changed parameters.
610         (WebCore::FileChooser::chooseFile): Changed to call chooseIcon function.
611         (WebCore::FileChooser::chooseIcon): Added.
612
613         * platform/FileChooser.h: Added FileChooserClient so this file doesn't have
614         to know about RenderFileUploadControl. Used RetainPtr instead of retain/release
615         so this works properly with Objective-C GC. Replaced disconnectUploadControl
616         with disconnectClient, which has a simple inline implementation. Moved the
617         Document parameter from the constructor to openFileChooser, along with a comment
618         about why it should not be there. Added a filename parameter to the constructor
619         for the initial filename. Added a font parameter to basenameForWidth so we don't
620         depend on having a pointer to the renderer. Removed the uploadControl() and
621         document() functions since no one calls either of them.
622
623         * platform/mac/FileChooserMac.mm: Removed code that is now cross-platform.
624         (-[OpenPanelController beginSheetWithFrame:]): Added frame parameter, instead
625         of storing a document pointer in the FileChooser.
626         (WebCore::FileChooser::FileChooser): Updated for changed parameters. Also added
627         code to choose the icon based on the initial filename. Pass the adopt parameter
628         to the constructor of the RetainPtr.
629         (WebCore::FileChooser::~FileChooser): Removed the release call, since the
630         RetainPtr will take care of it. Added a call to disconnectFileChooser here.
631         There's no need to disconnect at disconnectClient time, and that lets us have
632         one more cross-platform function.
633         (WebCore::FileChooser::openFileChooser): Added document parameter. Added code
634         to get the frame from the document. And added a nil check since there's no
635         ironclad guarantee the document won't have outlived its frame.
636         (WebCore::FileChooser::basenameForWidth): Added font parameter. Use that instead
637         of going at the upload control's style. The caller can handle that now.
638
639         * rendering/RenderFileUploadControl.h: Removed unnecessary includes.
640         Made class inherit privately from FileChooserClient. Changed constructor
641         parameter to HTMLInputElement rather than Node. Made protected members be
642         private instead, and made a couple function members const.
643         * rendering/RenderFileUploadControl.cpp: Moved constants to the top of the file,
644         but after the "using namespace"
645         (WebCore::RenderFileUploadControl::RenderFileUploadControl): Updated for changes
646         to the FileChooser::create function and the parameter types.
647         (WebCore::RenderFileUploadControl::~RenderFileUploadControl): Removed unneeded
648         null check -- there's no case where the FileChooser fails to be created.
649         (WebCore::RenderFileUploadControl::click): Pass document to openFileChooser.
650         (WebCore::RenderFileUploadControl::updateFromElement): Tweaked code a bit by
651         using updateFromElement and setValue instead of casting the renderer to a
652         RenderButton and calling setText directly. Put setInputType call here.
653         (WebCore::RenderFileUploadControl::maxFilenameWidth): Made const. Broke long line.
654         (WebCore::RenderFileUploadControl::createButtonStyle): Made const.
655         (WebCore::RenderFileUploadControl::paintObject): Moved buttonShadowHeight constant
656         to the top of the file. Call isEmpty instead of checking width and height of
657         IntRect for 0. Computed font to pass to FileChooser::basenameForWidth. Broke
658         long lines.
659         (WebCore::HTMLFileUploadInnerButtonElement::HTMLFileUploadInnerButtonElement):
660         Moved the setInputType call to the caller; concept here is that this class is
661         as simple as possible, rather than doing as much of the button job as possible.
662
663         * WebCore.xcodeproj/project.pbxproj: Added FileChooser.cpp.
664         * WebCore.pro: Ditto.
665         * CMakeLists.txt: Ditto.
666         * WebCoreSources.bkl: Ditto.
667
668         * platform/gdk/TemporaryLinkStubs.cpp: Updated stubs.
669         * platform/qt/FileChooserQt.cpp: Updated stubs.
670
671 2007-01-22  Mitz Pettel  <mitz@webkit.org>
672
673         Reviewed by Darin.
674
675         - fix http://bugs.webkit.org/show_bug.cgi?id=12364
676           REGRESSSION (NativeListBox): Selected option's background is not clipped to the list box
677
678         Test: fast/forms/select-item-background-clip.html
679
680         * rendering/RenderListBox.cpp:
681         (WebCore::RenderListBox::paintItemBackground): Intersect the item's rect with
682         the list box's clip rect.
683
684 2007-01-22  Darin Adler  <darin@apple.com>
685
686         Reviewed by Beth.
687
688         - fix http://bugs.webkit.org/show_bug.cgi?id=12369
689           REGRESSION (r19027): amazon.com home page crashes WebKit r19028 debug build
690
691         I caused this a few hours ago. Oops!
692
693         * rendering/RenderText.cpp: (WebCore::RenderText::setStyle):
694         Compute whether the font changed before calling RenderObject::setStyle.
695
696 2007-01-22  Beth Dakin  <bdakin@apple.com>
697
698         Reviewed by Maciej.
699
700         Fix for <rdar://problem/4912129> REGRESSION: Crash occurs at 
701         WebCore::Frame::eventHandler() after clicking to dismiss a 
702         contextual menu on the page
703
704         * page/EventHandler.cpp:
705         (WebCore::EventHandler::stopAutoscrollTimer): Added nil-check.
706
707 2007-01-22  Darin Adler  <darin@apple.com>
708
709         Reviewed by Mitz.
710
711         Inspired by a much simpler patch by Andrew Wellington <proton@wiretapped.net>.
712
713         - fix http://bugs.webkit.org/show_bug.cgi?id=11197
714           REGRESSION: Specifying a counter for a CODE tag's content style property
715           on before or after causes a crash.
716
717         Test: fast/css/beforeSelectorOnCodeElement.html
718
719         - fix regression I recently introduced where the monospace cache could be
720           used for text that was not ASCII, if text was changed after the style was set
721
722         Test: fast/text/monospace-width-cache.html
723
724         - streamline RenderText.h -- remove unneeded functions, make some needlessly
725           virtual functions non-virtual, remove unneeded header includes, replace use
726           of Font* with Font& for consistency with RenderStyle, use "text" consistently
727           instead of "string"
728
729         * rendering/RenderText.h: Removed unneeded include of "Text.h", declarations of
730         SOFT_HYPHEN, DocumentMarker, InlineBox, Position, String. Got rid of friend
731         declaration for InlineTextBox. Changed constructor to take a PassRefPtr since
732         we do take owership of the passed-in text. Made deleteTextBoxes() private.
733         Removed unneeded data(). Made override of length() private so people will use
734         the faster textLength() instead. Renamed string() to text() so it matches up
735         better with setText(). Same for stringLength(), originalString(), and
736         setInternalString(), which are now textLength(), originalText(), and
737         setTextInternal(). Renamed the old text() function to characters(), since it
738         returns a pointer as StringImpl::characters does. Changed Font* to Font& everywhere.
739         Renamed the internal calcMinMaxWidth() function to calcMinMaxWidthInternal() and
740         made it non-virtual since it's not overriden anywhere. Also made the
741         trimmedMinMaxWidth() function non-virtual. Made containsOnlyWhitespace() private.
742         Removed both font() functions (one was needlessly virtual) and element().
743         Renamed cacheWidths() to updateMonospaceCharacterWidth() and removed the
744         shouldUseMonospaceCache() function. Renamed allAscii() to isAllASCII() and made
745         it an inline function. Removed the m_allAsciiChecked flag and renamed the
746         m_allAscii flag to m_isAllASCII.
747         * rendering/RenderText.cpp:
748         (WebCore::RenderText::RenderText): Removed initialization of m_allAsciiChecked.
749         Initialize m_isAllASCII. Changed all occurrences of m_str->length() and
750         m_str->characters () to use the stringLength() and characters() inline functions
751         instead.
752         (WebCore::RenderText::setStyle): Replaced the unconditional call to cacheWidths
753         with a conditional call to updateMonospaceCharacterWidth. This speeds up the common
754         case where style is changed without changing the font.
755         (WebCore::RenderText::originalText): Changed code to not depend on overridden
756         element() function with casts to a Text node -- this was one of only two call sites.
757         Also renamed.
758         (WebCore::RenderText::positionForCoordinates): Name change.
759         (WebCore::RenderText::caretRect): Ditto.
760         (WebCore::RenderText::updateMonospaceCharacterWidth): Renamed from cacheWidths and
761         incorporate the check that was formerly in a separate shouldUseMonospaceCache
762         function.
763         (WebCore::RenderText::widthFromCache): Changed to take a Font& instead of Font*.
764         Changed to take advantage of the fact that the string is known to be all ASCII in
765         the m_monospaceCharacterWidth code path.
766         (WebCore::RenderText::trimmedMinMaxWidth): Ditto. Also use style()->font() instead
767         of font(false).
768         (WebCore::RenderText::calcMinMaxWidth): Ditto. Also changed to use softHyphen instead
769         of SOFT_HYPHEN.
770         (WebCore::RenderText::containsOnlyWhitespace): More of the same.
771         (WebCore::RenderText::setSelectionState): Ditto.
772         (WebCore::RenderText::setTextWithOffset): Ditto.
773         (WebCore::isInlineFlowOrEmptyText): Ditto.
774         (WebCore::RenderText::setTextInternal): Updated for name changes. Also changed to
775         set the m_isAllASCII flag every time, in the more-efficient way we use elsewhere
776         (or'ing all the characters together), and to call updateMonospaceCharacterWidth
777         if the "all ASCII"-ness of the text changes.
778         (WebCore::RenderText::setText): Updated for name changes.
779         (WebCore::RenderText::width): More like above.
780         (WebCore::RenderText::selectionRect): Ditto.
781         (WebCore::RenderText::caretMaxOffset): Ditto.
782         (WebCore::RenderText::previousOffset): Ditto.
783         (WebCore::RenderText::nextOffset): Ditto.
784
785         * dom/Position.cpp:
786         * dom/Range.cpp:
787         * editing/CompositeEditCommand.cpp:
788         * editing/DeleteSelectionCommand.cpp:
789         * editing/VisiblePosition.cpp:
790         * html/HTMLElement.cpp:
791         Added now-needed include of "Text.h" which is no longer included by "RenderText.h".
792
793         * editing/SelectionController.cpp:
794         (WebCore::SelectionController::debugRenderer):
795         * editing/TextIterator.cpp:
796         (WebCore::TextIterator::handleTextNode):
797         (WebCore::TextIterator::handleTextBox):
798         (WebCore::SimplifiedBackwardsTextIterator::handleTextNode):
799         Update for name changes of stringLength(), string(), and originalString() to
800         textLength(), text(), and originalText(), and to always use textLength() instead
801         of length() when we have a RenderText* rather than a RenderObject*.
802         * editing/visible_units.cpp:
803         (WebCore::startOfParagraph): Ditto.
804         (WebCore::endOfParagraph): Ditto.
805         * rendering/InlineFlowBox.cpp:
806         (WebCore::InlineFlowBox::placeBoxesHorizontally): Ditto. Also removed use of the
807         RenderObject::font() function and replaced it with explicit access to the style.
808         (WebCore::InlineFlowBox::placeBoxesVertically): Ditto.
809         * rendering/InlineTextBox.cpp:
810         (WebCore::InlineTextBox::selectionRect): Ditto.
811         (WebCore::InlineTextBox::isLineBreak): Ditto.
812         (WebCore::InlineTextBox::paint): Ditto.
813         (WebCore::InlineTextBox::selectionStartEnd): Ditto.
814         (WebCore::InlineTextBox::paintSelection): Ditto.
815         (WebCore::InlineTextBox::paintMarkedTextBackground): Ditto.
816         (WebCore::InlineTextBox::paintSpellingOrGrammarMarker): Ditto.
817         (WebCore::InlineTextBox::paintTextMatchMarker): Ditto.
818         (WebCore::InlineTextBox::offsetForPosition): Ditto.
819         (WebCore::InlineTextBox::positionForOffset): Ditto.
820         * rendering/RenderContainer.cpp:
821         (WebCore::RenderContainer::addChild): Ditto.
822         * rendering/RenderCounter.cpp:
823         (WebCore::RenderCounter::originalText): Ditto.
824         (WebCore::RenderCounter::calcMinMaxWidth): Ditto.
825         * rendering/RenderCounter.h: Ditto.
826         * rendering/RenderTextFragment.cpp:
827         (WebCore::RenderTextFragment::originalText): Ditto.
828         * rendering/RenderTextFragment.h: Ditto.
829         * rendering/SVGInlineFlowBox.cpp:
830         (WebCore::placePositionedBoxesHorizontally): Ditto.
831         (WebCore::placeBoxesVerticallyWithAbsBaseline): Ditto.
832         * rendering/bidi.cpp:
833         (WebCore::BidiIterator::increment): Ditto.
834         (WebCore::BidiIterator::current): Ditto.
835         (WebCore::BidiIterator::direction): Ditto.
836         (WebCore::addRun): Ditto.
837         (WebCore::checkMidpoints): Ditto.
838         (WebCore::RenderBlock::computeHorizontalPositionsForLine): Ditto.
839         (WebCore::RenderBlock::skipWhitespace): Ditto.
840         (WebCore::RenderBlock::findNextLineBreak): Ditto.
841
842         * rendering/RenderBR.h: Updated signature of width function which now takes a
843         Font& instead of a Font*.
844
845         * rendering/RenderBlock.cpp: (WebCore::stripTrailingSpace): Updated to no longer
846         use the RenderObject::font() function, and added a comment about first-line, which
847         is not handled properly here.
848
849         * rendering/RenderMenuList.cpp: (WebCore::RenderMenuList::text):
850         * rendering/RenderTreeAsText.cpp: (WebCore::writeTextRun):
851         Eliminated use of RenderText::data().
852
853         * rendering/RenderObject.h: Removed RenderObject::font(). This had the bad effect of
854         having everyone pass in a boolean rather than using the cleaner style() and
855         firstLineStyle() functions in cases where there's no a firstLineStyle boolean.
856         * rendering/RenderObject.cpp:
857         (WebCore::RenderObject::getVerticalPosition): Replaced use of RenderObject::font()
858         with direct use of the style instead, which is arguably easier to understand anyway.
859         (WebCore::RenderObject::baselinePosition): Ditto.
860
861 2007-01-22  Sam Weinig  <sam@webkit.org>
862
863         Reviewed by The Mitz.
864
865         Move JSHTMLSelectElementCustom.cpp from bindings to bindings/js
866         where it belongs.
867
868         * WebCore.pro:
869         * WebCore.xcodeproj/project.pbxproj:
870         * bindings/JSHTMLSelectElementCustom.cpp: Removed.
871         * bindings/js/JSHTMLSelectElementCustom.cpp: Added.
872
873 2007-01-22  Zack Rusin  <zack@kde.org>
874
875         Fix the Qt build.
876
877         * WebCore.pro: adjust after last changes
878
879 2007-01-21  Alexey Proskuryakov  <ap@webkit.org>
880
881         Reviewed by Darin.
882
883         http://bugs.webkit.org/show_bug.cgi?id=10934
884         REGRESSION: prototype.js logs error (HTMLFormElement) on webkit builds
885
886         Added constructors for most HTML elements; started auto-generating HTMLSelectElement JS binding.
887
888         Test: fast/dom/Window/element-constructors-on-window.html
889
890         * DerivedSources.make: Generate JSHTMLSelectElement.
891         * WebCore.xcodeproj/project.pbxproj: Added JSHTMLSelectElement{Custom}.
892         * bindings/js/JSHTMLElementWrapperFactory.cpp: Create a proper binding for SELECT.
893
894         * bindings/js/kjs_html.cpp:
895         (KJS::):
896         (KJS::JSHTMLElement::classInfo):
897         (KJS::JSHTMLElement::accessors):
898         (KJS::JSHTMLElement::getOwnPropertySlot):
899         (KJS::HTMLElementFunction::callAsFunction):
900         (KJS::JSHTMLElement::put):
901         * bindings/js/kjs_html.h:
902         (KJS::JSHTMLElement::):
903         Removed everything related to SELECT. Renamed getHTMLOptionsCollection to toJS for autogenerated code 
904         to be happy, and rewrote it using cacheDOMObject.
905
906         * bindings/scripts/CodeGeneratorJS.pm: Added HTMLElement to the list of types that cannot fail conversion.
907
908         * html/HTMLAnchorElement.idl:
909         * html/HTMLAppletElement.idl:
910         * html/HTMLAreaElement.idl:
911         * html/HTMLBRElement.idl:
912         * html/HTMLBaseElement.idl:
913         * html/HTMLBaseFontElement.idl:
914         * html/HTMLBodyElement.idl:
915         * html/HTMLButtonElement.idl:
916         * html/HTMLCanvasElement.idl:
917         * html/HTMLDListElement.idl:
918         * html/HTMLDirectoryElement.idl:
919         * html/HTMLDivElement.idl:
920         * html/HTMLFieldSetElement.idl:
921         * html/HTMLFontElement.idl:
922         * html/HTMLFormElement.idl:
923         * html/HTMLHRElement.idl:
924         * html/HTMLHeadElement.idl:
925         * html/HTMLHeadingElement.idl:
926         * html/HTMLHtmlElement.idl:
927         * html/HTMLImageElement.idl:
928         * html/HTMLInputElement.idl:
929         * html/HTMLIsIndexElement.idl:
930         * html/HTMLLIElement.idl:
931         * html/HTMLLabelElement.idl:
932         * html/HTMLLegendElement.idl:
933         * html/HTMLLinkElement.idl:
934         * html/HTMLMapElement.idl:
935         * html/HTMLMenuElement.idl:
936         * html/HTMLMetaElement.idl:
937         * html/HTMLModElement.idl:
938         * html/HTMLOListElement.idl:
939         * html/HTMLOptGroupElement.idl:
940         * html/HTMLParagraphElement.idl:
941         * html/HTMLParamElement.idl:
942         * html/HTMLPreElement.idl:
943         * html/HTMLQuoteElement.idl:
944         * html/HTMLScriptElement.idl:
945         * html/HTMLStyleElement.idl:
946         * html/HTMLTextAreaElement.idl:
947         * html/HTMLTitleElement.idl:
948         * html/HTMLUListElement.idl:
949         Generate constructors.
950
951         * html/HTMLSelectElement.cpp:
952         (WebCore::HTMLSelectElement::length):
953         * html/HTMLSelectElement.h:
954         Make length() return unsigned for auto-generated code to be happy.
955
956         * html/HTMLSelectElement.idl: Adjusted to be usable for JS.
957
958         * bindings/JSHTMLSelectElementCustom.cpp: Added. Implements remove().
959
960         * page/DOMWindow.idl:
961         Added properties for most elements' constructors.
962
963 2007-01-21  Mark Rowe  <mrowe@apple.com>
964
965         Reviewed by Maciej.
966
967         http://bugs.webkit.org/show_bug.cgi?id=12357
968         Bug 12357: Reproducible crash in WebCore::Settings::isJavaScriptEnabled in svg/custom/js-update-bounce.svg under guard-malloc
969
970         * page/Frame.cpp:
971         (WebCore::Frame::~Frame): Access the global object directly rather than via Window::retrieveWindow to prevent our reference to
972         a deleted settings object being used.
973
974 2007-01-21  Darin Adler  <darin@apple.com>
975
976         Reviewed by Maciej.
977
978         - fix <rdar://problem/4930503> REGRESSION: Page changes title when
979           command-clicking on named anchor link (12299)
980
981         * loader/FrameLoader.cpp:
982         (WebCore::FrameLoader::continueFragmentScrollAfterNavigationPolicy):
983         Return if shouldContinue is false. This matches the other similar
984         functions and prevents us from doing extra work in the "ignore" case.
985
986 2007-01-21  Mark Rowe  <mrowe@apple.com>
987
988         Reviewed by Darin.
989
990         http://bugs.webkit.org/show_bug.cgi?id=12355
991         Bug 12355: Reproducible crash in WebCore::parseNumber in svg/custom/js-update-bounce.svg under guard-malloc
992
993         * ksvg2/svg/SVGParserUtilities.cpp:
994         (WebCore::parseNumber): Parenthesize to prevent reading past end of buffer.
995
996 2007-01-21  Mitz Pettel  <mitz@webkit.org>
997
998         Reviewed by Darin.
999
1000         - fix http://bugs.webkit.org/show_bug.cgi?id=12345
1001           REGRESSION: Disabled pop-up text is not grayed out
1002
1003         Test: fast/forms/select-disabled-appearance.html
1004
1005         * rendering/RenderThemeMac.mm:
1006         (WebCore::RenderThemeMac::adjustMenuListStyle):
1007
1008 2007-01-21  Darin Adler  <darin@apple.com>
1009
1010         - fix non-Mac builds
1011
1012         * CMakeLists.txt: Added JSDocumentCustom.cpp.
1013         * WebCore.pro: Ditto.
1014         * WebCoreSources.bkl: Ditto.
1015
1016 2007-01-21  Mitz Pettel  <mitz@webkit.org>
1017
1018         Reviewed by Darin.
1019
1020         - fix http://bugs.webkit.org/show_bug.cgi?id=12353 <rdar://problem/4944599>
1021           REGRESSION: Crash on load (mutation event dispatch under the image element constructor deletes the element)
1022     
1023         Test: fast/dom/HTMLImageElement/constructor-mutation-event-dispatch.html
1024
1025         * bindings/js/kjs_html.cpp:
1026         (KJS::ImageConstructorImp::construct): Protect the image element before setting
1027         its attributes.
1028
1029 2007-01-21  Sam Weinig  <sam@webkit.org>
1030
1031         Rolling out patch for http://bugs.webkit.org/show_bug.cgi?id=8360.
1032
1033         * rendering/RenderLayer.cpp:
1034         (WebCore::RenderLayer::RenderLayer):
1035         (WebCore::RenderLayer::scrollToOffset):
1036         (WebCore::RenderLayer::scrollRectToVisible):
1037         (WebCore::RenderLayer::updateScrollInfoAfterLayout):
1038         (WebCore::Marquee::start):
1039         * rendering/RenderLayer.h:
1040
1041 2007-01-21  David Kilzer  <ddkilzer@webkit.org>
1042
1043         Reviewed by Darin.
1044
1045         - fix http://bugs.webkit.org/show_bug.cgi?id=12280
1046           select element not available by name through document.all
1047           (dropdown list not available on smarthome.com checkout)
1048
1049         Test: fast/dom/document-all-select.html
1050
1051         * html/HTMLCollection.cpp:
1052         (WebCore::HTMLCollection::checkForNameMatch):
1053         (WebCore::HTMLCollection::updateNameCache):
1054
1055 2007-01-21  Mitz Pettel  <mitz@webkit.org>
1056
1057         Reviewed by Darin.
1058
1059         - http://bugs.webkit.org/show_bug.cgi?id=10805
1060           REGRESSION (r15720): manual-tests/onblur-remove.html failing
1061
1062         * manual-tests/onblur-remove.html: Changed the test to not require pressing
1063         Enter, since the correct behavior for Enter is to send a blur event.
1064
1065 2007-01-21  Sanjay Madhav  <sanjay12@gmail.com>
1066
1067         Reviewed by Darin.
1068
1069         Fix for: <rdar://problem/4928583> Memory usage grows when reloading google.com/ig
1070
1071         JSDocuments are now responsible for marking the DOM wrappers associated with them, when they get marked.
1072         This fixes a JS object leak when a DOM wrapper has a reference to a JSDocument that is otherwise not reachable.
1073
1074         Test: fast/dom/gc-10.html
1075
1076         * WebCore.vcproj/WebCore/WebCore.vcproj:
1077         * WebCore.xcodeproj/project.pbxproj:
1078         * bindings/js/JSDocumentCustom.cpp: Added.
1079         (WebCore::JSDocument::mark):
1080         * bindings/js/kjs_binding.cpp:
1081         (KJS::ScriptInterpreter::markDOMNodesForDocument):
1082         (KJS::ScriptInterpreter::mark):
1083         * bindings/js/kjs_binding.h:
1084         * dom/Document.idl:
1085
1086 2007-01-21  Mitz Pettel  <mitz@webkit.org>
1087
1088         Reviewed by Darin.
1089
1090         - fix http://bugs.webkit.org/show_bug.cgi?id=10692
1091           REGRESSION (r14847): Unnecessary scrollbars with position:relative; and overflow:auto;
1092
1093         Test: fast/overflow/position-relative.html
1094
1095         * rendering/RenderBox.cpp:
1096         (WebCore::RenderBox::lowestPosition): Add the relative position offset only
1097         if 'includeSelf' is true.
1098         (WebCore::RenderBox::rightmostPosition): Ditto.
1099         (WebCore::RenderBox::leftmostPosition): Ditto.
1100         * rendering/RenderFlow.cpp:
1101         (WebCore::RenderFlow::lowestPosition): Ditto.
1102         (WebCore::RenderFlow::rightmostPosition): Ditto.
1103         (WebCore::RenderFlow::leftmostPosition): Ditto.
1104
1105 2007-01-21  Mitz Pettel  <mitz@webkit.org>
1106
1107         Reviewed by Darin.
1108
1109         - fix http://bugs.webkit.org/show_bug.cgi?id=10472
1110           REGRESSION: "add" method of <select> object does not put the <option> object in the correct position
1111
1112         Test: fast/dom/HTMLSelectElement/options-collection-detached.html
1113
1114         * html/HTMLSelectElement.cpp:
1115         (WebCore::HTMLSelectElement::setRecalcListItems): Reset the options collection
1116         info if the <select> is not in the document. For in-document <select>s this
1117         happens anyway as a result of the DOM tree version increasing.
1118
1119 2007-01-21  Mitz Pettel  <mitz@webkit.org>
1120
1121         Reviewed by Darin.
1122
1123         - fix http://bugs.webkit.org/show_bug.cgi?id=12349
1124           NativeFileUpload: Button text is not grayed out when the control is disabled
1125
1126         Covered by fast/forms/file-input-disabled.html 
1127
1128         * css/html4.css: Changed selectors that had pseudo-classes after the -webkit-file-upload-button
1129         pseudo-element to have the pseudo-element at the end. Pseudo-elements must be at the end.
1130         * rendering/RenderFileUploadControl.cpp:
1131         (WebCore::RenderFileUploadControl::createButtonStyle): Changed to not overwrite the button's
1132         style with its parent's style. getPseudoStyle() handles inheritance properly.
1133
1134 2007-01-21  Mitz Pettel  <mitz@webkit.org>
1135
1136         Reviewed by Darin.
1137
1138         - fix http://bugs.webkit.org/show_bug.cgi?id=12343
1139           crash in css2.1/t1202-counter-09-b.html
1140
1141         * platform/Font.cpp:
1142         (WebCore::Font::glyphDataForCharacter):
1143
1144 2007-01-21  Darin Adler  <darin@apple.com>
1145
1146         Reviewed by Adam and Mitz.
1147
1148         - fix http://bugs.webkit.org/show_bug.cgi?id=12347
1149           REGRESSION: list box scrolling broken (fast/forms/listbox-selection.html)
1150
1151         Covered by existing test: fast/forms/listbox-selection.html
1152
1153         * rendering/RenderListBox.h: Added override of layout(), made selectionChanged()
1154         no longer an inline. Added private scrollToRevealSelection(),
1155         m_scrollToRevealSelectionAfterLayout, and m_inAutoscroll.
1156         * rendering/RenderListBox.cpp:
1157         (WebCore::RenderListBox::RenderListBox): Initialize new data members.
1158         (WebCore::RenderListBox::updateFromElement): Remove scrolling code.
1159         (WebCore::RenderListBox::selectionChanged): Moved from header. Calls repaint
1160         and then scrollToRevealSelection, but if we need layout, instead schedules
1161         scrollToRevealSelection to be done after layout.
1162         (WebCore::RenderListBox::layout): Added. After calling base class, calls
1163         scrollToRevealSelection if the m_scrollToRevealSelectionAfterLayout is set.
1164         (WebCore::RenderListBox::scrollToRevealSelection): Added. Code was originally
1165         in updateFromElement.
1166         (WebCore::RenderListBox::autoscroll): Set m_inAutoscroll so that the
1167         selectionChanged function knows not to scroll. Also removed the repaint()
1168         here because updateListBoxSelection() takes care of repainting by calling
1169         selectionChanged().
1170
1171 2007-01-21  David Kilzer  <ddkilzer@webkit.org>
1172
1173         * page/EventHandler.cpp:
1174         (WebCore::EventHandler::handleMouseMoveEvent): Changed #if SVG_SUPPORT to #ifdef SVG_SUPPORT.
1175
1176 2007-01-20  Mitz Pettel  <mitz@webkit.org>
1177
1178         Reviewed by Maciej.
1179
1180         - fix http://bugs.webkit.org/show_bug.cgi?id=11115
1181           REGRESSION: Crash on Flickr after hitting cancel from adding a note
1182
1183         Test: fast/forms/text-set-value-crash.html
1184
1185         * html/HTMLInputElement.cpp:
1186         (WebCore::HTMLInputElement::setValue): Added a call to Document::updateRendering().
1187         * html/HTMLTextAreaElement.cpp:
1188         (WebCore::HTMLTextAreaElement::setValue): Ditto.
1189
1190 2007-01-20  Mitz Pettel  <mitz@webkit.org>
1191
1192         Reviewed by Darin.
1193
1194         - fix http://bugs.webkit.org/show_bug.cgi?id=8360
1195           Repro crash when onscroll handler deletes the scrolled object
1196
1197         Test: fast/layers/removed-by-scroll-handler.html
1198
1199         * rendering/RenderLayer.cpp:
1200         (WebCore::RenderLayer::RenderLayer):
1201         (WebCore::RenderLayer::dispatchScrollEvent): Added. Called when the timer
1202         fires and dispatches the scroll event to the layer's element.
1203         (WebCore::RenderLayer::scrollToOffset): Instead of dispatching the scroll
1204         event from this function, which is called during layout, schedule a 0-duration
1205         timer to dispatch the event after layout.
1206         (WebCore::RenderLayer::scrollRectToVisible):
1207         (WebCore::RenderLayer::updateScrollInfoAfterLayout):
1208         (WebCore::Marquee::start):
1209         * rendering/RenderLayer.h:
1210
1211 2007-01-20  Nikolas Zimmermann  <zimmermann@kde.org>
1212
1213         Reviewed by Sam.
1214
1215         Fix JS bindings for SVGAnimated{Boolean, Enumeration, Integer, Number, String}.
1216
1217         Dynamic SVG DOM updates (ie. "someUse.href.baseVal = '#rect'") with these types
1218         didn't work. Existing gradient updating examples relied on calling setAttribute
1219         after a SVG DOM update - that was the only reason it worked, added a new test
1220         only using SVG DOM updates (js-update-stop.svg).
1221
1222         Added test: js-update-stop.svg
1223         Added test: use-property-changes-through-dom.svg (change xlink:href, x/y attributes using setAttribute)
1224         Added test: use-property-changes-through-svg-dom.svg (change xlink:href, x/y attributes using SVG DOM)
1225
1226         * bindings/js/JSSVGPODTypeWrapper.h:
1227         (WebCore::JSSVGPODTypeWrapper::commitChange):
1228         (WebCore::JSSVGPODTypeWrapperCreator::commitChange):
1229         (WebCore::JSSVGPODTypeWrapperCreatorForList::commitChange):
1230         * bindings/js/JSSVGPathSegListCustom.cpp:
1231         (WebCore::updatePathSegContextMap):
1232         (WebCore::removeFromPathSegContextMap):
1233         * bindings/scripts/CodeGeneratorJS.pm:
1234         * ksvg2/misc/SVGDocumentExtensions.h:
1235         (WebCore::SVGDocumentExtensions::baseValueMap):
1236         (WebCore::SVGDocumentExtensions::genericContextMap):
1237         (WebCore::SVGDocumentExtensions::baseValue):
1238         (WebCore::SVGDocumentExtensions::setBaseValue):
1239         (WebCore::SVGDocumentExtensions::removeBaseValue):
1240         (WebCore::SVGDocumentExtensions::hasBaseValue):
1241         (WebCore::SVGDocumentExtensions::genericContext):
1242         (WebCore::SVGDocumentExtensions::setGenericContext):
1243         (WebCore::SVGDocumentExtensions::removeGenericContext):
1244         (WebCore::SVGDocumentExtensions::hasGenericContext):
1245         (WebCore::String):
1246         (WebCore::FloatRect):
1247         (WebCore::bool):
1248         (WebCore::double):
1249         * ksvg2/svg/SVGClipPathElement.h:
1250         * ksvg2/svg/SVGElement.h:
1251         (WebCore::SVGElement::notifyAttributeChange):
1252         * ksvg2/svg/SVGPathSegList.cpp:
1253         (WebCore::SVGPathSegList::SVGPathSegList):
1254         (WebCore::SVGPathSegList::context):
1255         * ksvg2/svg/SVGPathSegList.h:
1256         * ksvg2/svg/SVGPatternElement.h:
1257         * ksvg2/svg/SVGPointList.cpp:
1258         (SVGPointList::SVGPointList):
1259         (SVGPointList::context):
1260         * ksvg2/svg/SVGPointList.h:
1261         * ksvg2/svg/SVGStopElement.cpp:
1262         (WebCore::SVGStopElement::parseMappedAttribute):
1263         (WebCore::SVGStopElement::notifyAttributeChange):
1264         * ksvg2/svg/SVGStopElement.h:
1265         * ksvg2/svg/SVGUseElement.cpp:
1266         (WebCore::SVGUseElement::notifyAttributeChange):
1267
1268 2007-01-20  Rob Buis  <buis@kde.org>
1269
1270         Reviewed by Sam.
1271
1272         http://bugs.webkit.org/show_bug.cgi?id=12334
1273         Respect <text> boundaries for svg text selecting
1274
1275         Make sure the text selection for svg stays inside
1276         containing blocks.
1277         Added one manual test since html selection does not
1278         seem to work for SVG and selectSubString for SVG
1279         is not implemented yet.
1280
1281         * manual-tests/svg-text-selection.svg: Added.
1282         * page/EventHandler.cpp:
1283         (WebCore::EventHandler::handleMouseMoveEvent):
1284         * rendering/RenderObject.h:
1285         (WebCore::RenderObject::isSVGText):
1286         * rendering/RenderSVGInlineText.h:
1287         (WebCore::RenderSVGInlineText::isSVGText):
1288         * rendering/RenderSVGText.h:
1289         (WebCore::RenderSVGText::isSVGText):
1290
1291 2007-01-19  Adele Peterson  <adele@apple.com>
1292
1293         Reviewed by Hyatt.
1294
1295         Fix for: <rdar://problem/4697438> REGRESSION: select menu lists match the wrong css rule on www.chainreaction.com
1296
1297         Update the size attribute value for select elements to match the numeric value.  This is a special case since this
1298         attribute is used to determine which control to use.  We want to make sure that the size attribute is valid when we match
1299         CSS rules.
1300
1301         Test: fast/forms/select-size.html
1302
1303         * html/HTMLSelectElement.cpp: (WebCore::HTMLSelectElement::parseMappedAttribute): If the attribute string value is not the
1304           same as its integer value, then update the attribute value to match the integer.
1305         * dom/Attribute.h: Made setValue and setPrefix public.
1306
1307 2007-01-19  John Sullivan  <sullivan@apple.com>
1308
1309         Reviewed by Darin
1310
1311         - WebCore part of fix for: <rdar://problem/4451715> REGRESSION: On some sites, have to 
1312           type a character before username/password autofill kicks in
1313
1314         * loader/FrameLoaderClient.h:
1315         new dispatchDidFinishDocumentLoad call
1316
1317         * loader/FrameLoader.cpp:
1318         (WebCore::FrameLoader::finishedParsing):
1319         call dispatchDidFinishDocumentLoad
1320         
1321         * platform/graphics/svg/SVGImageEmptyClients.h:
1322         (WebCore::SVGEmptyFrameLoaderClient::dispatchDidFinishDocumentLoad):
1323         empty implementation for dispatchDidFinishDocumentLoad
1324
1325 2007-01-19  Adele Peterson  <adele@apple.com>
1326
1327         Reviewed by Hyatt.
1328
1329         Fix for <rdar://problem/4760280> REGRESSION: Bottom portion of text hangs off edge of SELECT element at http://macreviewzone.com/index.php
1330         
1331         Test: fast/forms/control-restrict-line-height.html
1332
1333         * rendering/RenderThemeMac.mm: (WebCore::RenderThemeMac::setFontFromControlSize): Don't honor line-height for controls that
1334           have restricted font size.
1335
1336 2007-01-19  Darin Adler  <darin@apple.com>
1337
1338         Reviewed by Adele.
1339
1340         - fix http://bugs.webkit.org/show_bug.cgi?id=11999
1341           <rdar://problem/4940442> REGRESSION: Incomplete listing in TVListings window (11999)
1342           Fix was to use the actual size of the renderer in the RenderListBox
1343           case, instead of always using the size specified by the select element.
1344
1345         Test: fast/forms/select-list-box-with-height.html
1346
1347         - fix http://bugs.webkit.org/show_bug.cgi?id=11995
1348           <rdar://problem/4901834> REGRESSION(NativeListBox): Focus is not placed on
1349           SELECT after mousing down on OPTION
1350
1351         Test: fast/forms/select-list-box-mouse-focus.html
1352
1353         - fix bug where auto-scrolling was not working in list box select elements
1354
1355         No test yet.
1356
1357         - fix a missing semicolon in the radio/checkbox section of html4.css
1358
1359         Test: fast/forms/radio-no-theme-padding.html
1360
1361         - fix bug where the scroll bars for select elements were pixel-type scroll
1362           bars even though the scrolling is line at a time scrolling
1363
1364         No test.
1365
1366         * html/HTMLSelectElement.cpp:
1367         (WebCore::HTMLSelectElement::selectAll): Removed an explicit call
1368         to repaint, since the RenderListBox now does that in selectionChanged.
1369         (WebCore::HTMLSelectElement::notifyOptionSelected): Call the new
1370         selectionChanged instead of the old setSelectionChanged.
1371         (WebCore::HTMLSelectElement::listBoxDefaultEventHandler): Added a call
1372         to focus. Removed an explicit call to repaint and added a call to the
1373         new setMouseDownMayStartAutoscroll function in EventHandler. Removed an
1374         explicit call to repaint as above.
1375         (WebCore::HTMLSelectElement::updateListBoxSelection): Call the new
1376         selectionChanged instead of the old setSelectionChanged.
1377
1378         * page/EventHandler.h: Added setMouseDownMayStartAutoscroll, needed
1379         because the existing code to set that flag won't get triggered when
1380         the select element's default event handler handles the event.
1381
1382         * rendering/RenderListBox.h: Made ScrollbarClient a private base class.
1383         Removed setSelectionChanged and m_selectionChanged. Added selectionChanged,
1384         which is really just a synonym for repaint for now. Moved valueChanged,
1385         the ScrollbarClient function implementations, and itemHeight into the
1386         private part of the class. Added numVisibleItems() and listHeight() to
1387         the private section. Changed m_vBar to be a RefPtr.
1388
1389         * rendering/RenderListBox.cpp: Removed unneeded includes. Moved all
1390         the constants to the top of the file.
1391         (WebCore::RenderListBox::RenderListBox): Removed initialization of
1392         m_selectionChanged because it was removed and of m_vBar because it's
1393         now a RefPtr which is automaticall initialized.
1394         (WebCore::RenderListBox::~RenderListBox): Removed the explicit deref of
1395         m_vBar because it's a RefPtr. Added null checking for FrameView.
1396         (WebCore::RenderListBox::updateFromElement): Use numItems().
1397         (WebCore::RenderListBox::calcMinMaxWidth): Added null checking for
1398         FrameView and used RefPtr for the newly-created scroll bar.
1399         (WebCore::RenderListBox::size): Tweaked formatting. Also renamed the
1400         misleading minDefaultSize to maxDefaultSize, since it's a maximum.
1401         (WebCore::RenderListBox::numVisibleItems): Added. Used in many places
1402         where size() was used before. This computes the number of rows we have
1403         room for. We don't need a row space after the last row, and this takes
1404         that into account.
1405         (WebCore::RenderListBox::numItems): Tweaked to remove the local variable.
1406         (WebCore::RenderListBox::listHeight): Added. Total height of all the rows
1407         and spaces between them.
1408         (WebCore::RenderListBox::calcHeight): Changed to call itemHeight for the
1409         row height, and to subtract the last row spacing off since we don't need
1410         a space after the last row. Changed the scroll bar setup to make it
1411         correspond to row numbers, not pixel numbers.
1412         (WebCore::RenderListBox::baselinePosition): Moved the comment to the
1413         constant declaration at the top of the file.
1414         (WebCore::RenderListBox::itemBoundingBoxRect): Simplified by using
1415         the itemHeight() function.
1416         (WebCore::RenderListBox::paintObject): Changed to use numItems and
1417         to use numVisibleItems instead of size.
1418         (WebCore::RenderListBox::isPointInScrollbar): Added get() call since
1419         m_vBar is now a RefPtr.
1420         (WebCore::RenderListBox::listIndexAtOffset): Changed to use numItems(),
1421         itemHeight(), and rearranged a min/max combo so it starts with the low,
1422         then the value, then the high value for pinning.
1423         (WebCore::RenderListBox::autoscroll): Use numVisibleItems() instead of
1424         size().
1425         (WebCore::RenderListBox::stopAutoscroll): Removed an unneeded nil check
1426         of the element.
1427         (WebCore::RenderListBox::scrollToRevealElementAtListIndex): Changed
1428         to use numItems() and to use numVisibleItems() instead of size().
1429         Also changed scroll bar code to work more simply now that the scroll
1430         bar is row-based.
1431         (WebCore::RenderListBox::listIndexIsVisible): Changed to use
1432         numVisibleItems() instead of size().
1433         (WebCore::RenderListBox::valueChanged): Simplified since the scrollbar
1434         is now row-based. Also removed an unnecessary null check.
1435         (WebCore::RenderListBox::itemHeight): Updated for name change from
1436         optionsSpacingMiddle to rowSpacing.
1437         (WebCore::RenderListBox::scrollHeight): Changed to use listHeight().
1438         (WebCore::RenderListBox::setScrollTop): Simplified, and removed the code
1439         that does nothing if the computed list index is visible (which did not
1440         make sense for this function and seemed a cut and paste error from the
1441         scrollToReveal function). The scrollbar part is simpler now that it's
1442         row-based.
1443         (WebCore::RenderListBox::windowClipRect): Changed to use document()->view()
1444         so we don't have to include RenderView.h.
1445
1446         * css/html4.css: Added a semicolon I noticed was missing.
1447
1448 2007-01-19  Beth Dakin  <bdakin@apple.com>
1449
1450         Reviewed by Maciej and Darin.
1451
1452         Fix for <rdar://problem/4702420> REGRESSION: Null characters need 
1453         to be stripped from text nodes (townhall.com)
1454
1455         This was a regression from the fix for <rdar://problem/3727939>
1456         Safari strips \0 characters from HTML tags making them valid, which
1457         was fixed with r12652. We still need to strip null characters in
1458         text nodes.
1459
1460         * html/HTMLTokenizer.cpp:
1461         (WebCore::HTMLTokenizer::write): No behavior change here, this is
1462         just to make Darin happy.
1463         (WebCore::HTMLTokenizer::processToken): Call into StringImpl's new 
1464         createStrippingNull function instead of the normal StringImpl 
1465         constructor.
1466         * platform/StringImpl.cpp:
1467         (WebCore::StringImpl::createStrippingNull): Strip null.
1468         * platform/StringImpl.h:
1469
1470 2007-01-19  David Kilzer  <ddkilzer@webkit.org>
1471
1472         Reviewed by NOBODY (no-svg build fix).
1473
1474         * ksvg2/svg/SVGMPathElement.cpp: Added #ifdef SVG_SUPPORT/#endif guards.
1475
1476 2007-01-19  Anders Carlsson  <acarlsson@apple.com>
1477         
1478         Build fix.
1479         
1480         * platform/graphics/svg/SVGImageEmptyClients.h:
1481         (WebCore::SVGEmptyChromeClient::setStatusbarText):
1482
1483 2007-01-18  Anders Carlsson  <acarlsson@apple.com>
1484
1485         Reviewed by Adam.
1486
1487         Move JavaScript alert and status bar functions to the chrome.
1488         
1489         * bindings/js/kjs_window.cpp:
1490         (KJS::WindowFunc::callAsFunction):
1491         * page/Chrome.cpp:
1492         (WebCore::Chrome::runJavaScriptAlert):
1493         (WebCore::Chrome::runJavaScriptConfirm):
1494         (WebCore::Chrome::runJavaScriptPrompt):
1495         (WebCore::Chrome::setStatusBarText):
1496         * page/Chrome.h:
1497         * page/ChromeClient.h:
1498         * page/Frame.cpp:
1499         (WebCore::Frame::setJSStatusBarText):
1500         (WebCore::Frame::setJSDefaultStatusBarText):
1501         * page/Frame.h:
1502         * page/mac/FrameMac.h:
1503         * page/mac/FrameMac.mm:
1504         * page/mac/WebCoreFrameBridge.h:
1505         * platform/graphics/svg/SVGImageEmptyClients.h:
1506         (WebCore::SVGEmptyChromeClient::runJavaScriptAlert):
1507         (WebCore::SVGEmptyChromeClient::runJavaScriptConfirm):
1508         (WebCore::SVGEmptyChromeClient::runJavaScriptPrompt):
1509         (WebCore::SVGEmptyChromeClient::setStatusBarText):
1510
1511 2007-01-19  Zack Rusin  <zack@kde.org>
1512
1513         Fix the build.
1514
1515         * WebCore.pro: Add missing files
1516
1517 2007-01-19  Eric Seidel  <eric@webkit.org>
1518
1519         Reviewed by rwlbuis.
1520
1521         More cleanup to SVGAnimated* classes.
1522
1523         No tests possible (only code cleanup)
1524
1525         * ksvg2/svg/SVGAnimateMotionElement.cpp:
1526         (WebCore::SVGAnimateMotionElement::applyAnimationToValue):
1527         * ksvg2/svg/SVGAnimateMotionElement.h:
1528         * ksvg2/svg/SVGAnimationElement.cpp:
1529         (WebCore::SVGAnimationElement::parseBeginOrEndValue):
1530         (WebCore::SVGAnimationElement::parseMappedAttribute):
1531         (WebCore::SVGAnimationElement::parseClockValue):
1532         (WebCore::SVGAnimationElement::isIndefinite):
1533         * ksvg2/svg/SVGAnimationElement.h:
1534
1535 2007-01-19  Nikolas Zimmermann  <zimmermann@kde.org>
1536
1537         Not reviewed.
1538
1539         Remove accidently commited debug output. Shame on me :-)
1540
1541         * ksvg2/svg/SVGUseElement.cpp:
1542         (WebCore::SVGUseElement::notifyAttributeChange):
1543
1544 2007-01-19  Nikolas Zimmermann  <zimmermann@kde.org>
1545
1546         Reviewed by Eric.
1547
1548         Fixes: http://bugs.webkit.org/show_bug.cgi?id=10410 (SVG Slider example renders completely wrong (inserting <use> dynamically doesn't work))
1549         Fixes: http://bugs.webkit.org/show_bug.cgi?id=11660 (SVG: creation of <use/> elements through scripting/DOM doesn't work)
1550
1551         Added test: svg/custom/use-instanceRoot-modifications.svg
1552         Added test: svg/custom/use-on-g.svg
1553         Added test: svg/custom/use-on-rect.svg
1554         Added test: svg/custom/use-on-symbol-inside-pattern.svg
1555         Added test: svg/custom/use-on-symbol.svg
1556         Added test: svg/custom/use-on-text.svg
1557         Added test: svg/custom/use-transform.svg
1558
1559         Fixes: svg/W3C-SVG-1.1/text-text-04-t.svg (missing use elements)
1560         Fixes: svg/carto.net/button.svg (image buttons didn't appear)
1561         Fixes: svg/carto.net/colourpicker.svg (slider handles finally show up)
1562         Fixes: svg/carto.net/slider.svg (slider handles finally show up)
1563         Fixes: svg/carto.net/window.svg (window decorations show up) 
1564         Fixes: svg/custom/use-forward-refs.svg (missing use elements)
1565
1566         Rewrite <use> support with a real-shadow tree (as the spec demands), and implement SVGElementInstance.
1567         AFAIK we're the first implementing this SVG feature - after ASV3 (!).
1568
1569         * DerivedSources.make:
1570         * WebCore.xcodeproj/project.pbxproj:
1571         * bindings/objc/DOMInternal.h:
1572         * bindings/objc/DOMSVG.h:
1573         * ksvg2/misc/SVGDocumentExtensions.cpp:
1574         (WebCore::SVGDocumentExtensions::reportWarning):
1575         (WebCore::SVGDocumentExtensions::reportError):
1576         (WebCore::SVGDocumentExtensions::addPendingResource):
1577         (WebCore::SVGDocumentExtensions::isPendingResource):
1578         (WebCore::SVGDocumentExtensions::removePendingResource):
1579         (WebCore::SVGDocumentExtensions::mapInstanceToElement):
1580         (WebCore::SVGDocumentExtensions::removeInstanceMapping):
1581         (WebCore::SVGDocumentExtensions::instancesForElement):
1582         * ksvg2/misc/SVGDocumentExtensions.h:
1583         * ksvg2/svg/SVGCircleElement.cpp:
1584         (WebCore::SVGCircleElement::notifyAttributeChange):
1585         * ksvg2/svg/SVGElement.cpp:
1586         (WebCore::SVGElement::insertedIntoDocument):
1587         * ksvg2/svg/SVGElement.h:
1588         (WebCore::SVGElement::buildPendingResource):
1589         * ksvg2/svg/SVGElementInstance.cpp:
1590         (WebCore::SVGElementInstance::SVGElementInstance):
1591         (WebCore::SVGElementInstance::~SVGElementInstance):
1592         (WebCore::SVGElementInstance::clonedElement):
1593         (WebCore::SVGElementInstance::correspondingElement):
1594         (WebCore::SVGElementInstance::correspondingUseElement):
1595         (WebCore::SVGElementInstance::parentNode):
1596         (WebCore::SVGElementInstance::childNodes):
1597         (WebCore::SVGElementInstance::previousSibling):
1598         (WebCore::SVGElementInstance::nextSibling):
1599         (WebCore::SVGElementInstance::firstChild):
1600         (WebCore::SVGElementInstance::lastChild):
1601         (WebCore::SVGElementInstance::appendChild):
1602         (WebCore::SVGElementInstance::updateInstance):
1603         * ksvg2/svg/SVGElementInstance.h:
1604         * ksvg2/svg/SVGElementInstance.idl: Added.
1605         * ksvg2/svg/SVGElementInstanceList.cpp:
1606         (WebCore::SVGElementInstanceList::SVGElementInstanceList):
1607         (WebCore::SVGElementInstanceList::length):
1608         (WebCore::SVGElementInstanceList::item):
1609         * ksvg2/svg/SVGElementInstanceList.h:
1610         * ksvg2/svg/SVGElementInstanceList.idl: Added.
1611         * ksvg2/svg/SVGEllipseElement.cpp:
1612         (WebCore::SVGEllipseElement::notifyAttributeChange):
1613         * ksvg2/svg/SVGGElement.cpp:
1614         * ksvg2/svg/SVGGElement.h:
1615         (WebCore::SVGGElement::contextElement):
1616         * ksvg2/svg/SVGGradientElement.cpp:
1617         * ksvg2/svg/SVGGradientElement.h:
1618         * ksvg2/svg/SVGHiddenElement.h: Added.
1619         (WebCore::SVGHiddenElement::Type):
1620         (WebCore::SVGHiddenElement::~SVGHiddenElement):
1621         (WebCore::SVGHiddenElement::localName):
1622         * ksvg2/svg/SVGImageElement.cpp:
1623         (WebCore::SVGImageElement::notifyAttributeChange):
1624         * ksvg2/svg/SVGLineElement.cpp:
1625         (WebCore::SVGLineElement::notifyAttributeChange):
1626         * ksvg2/svg/SVGPathElement.cpp:
1627         (WebCore::SVGPathElement::notifyAttributeChange):
1628         * ksvg2/svg/SVGPatternElement.cpp:
1629         * ksvg2/svg/SVGPatternElement.h:
1630         * ksvg2/svg/SVGPolyElement.cpp:
1631         (WebCore::SVGPolyElement::notifyAttributeChange):
1632         * ksvg2/svg/SVGRectElement.cpp:
1633         (WebCore::SVGRectElement::notifyAttributeChange):
1634         * ksvg2/svg/SVGStyledElement.cpp:
1635         (WebCore::SVGStyledElement::notifyAttributeChange):
1636         (WebCore::SVGStyledElement::updateElementInstance):
1637         * ksvg2/svg/SVGStyledElement.h:
1638         * ksvg2/svg/SVGUseElement.cpp:
1639         (WebCore::SVGUseElement::instanceRoot):
1640         (WebCore::SVGUseElement::animatedInstanceRoot):
1641         (WebCore::SVGUseElement::hasChildNodes):
1642         (WebCore::SVGUseElement::insertedIntoDocument):
1643         (WebCore::SVGUseElement::buildPendingResource):
1644         (WebCore::SVGUseElement::createRenderer):
1645         (WebCore::SVGUseElement::buildShadowTree):
1646         (WebCore::SVGUseElement::recursiveShadowTreeBuilder):
1647         (WebCore::dumpShadowTree):
1648         (WebCore::SVGUseElement::addShadowTree):
1649         * ksvg2/svg/SVGUseElement.h:
1650         * ksvg2/svg/SVGUseElement.idl:
1651
1652 2007-01-19  Eric Seidel  <eric@webkit.org>
1653
1654         Reviewed by rwlbuis.
1655
1656         Add support for SVGMPathElement parsing.
1657
1658         No test cases possible (SVGAnimateMotion doesn't work yet)
1659
1660         * WebCore.xcodeproj/project.pbxproj:
1661         * ksvg2/svg/SVGAnimateMotionElement.cpp:
1662         (WebCore::SVGAnimateMotionElement::animationPath):
1663         * ksvg2/svg/SVGMPathElement.cpp: Added.
1664         (WebCore::SVGMPathElement::SVGMPathElement):
1665         (WebCore::SVGMPathElement::~SVGMPathElement):
1666         (WebCore::SVGMPathElement::parseMappedAttribute):
1667         (WebCore::SVGMPathElement::pathElement):
1668         * ksvg2/svg/SVGMPathElement.h: Added.
1669         * ksvg2/svg/SVGNumberList.cpp:
1670         (WebCore::SVGNumberList::parse): fix typo in comment
1671         * ksvg2/svg/svgtags.in: add back mpath
1672
1673 2007-01-19  Eric Seidel  <eric@webkit.org>
1674
1675         Reviewed by rwlbuis.
1676
1677         Implement better parsing for keyTimes, keySplines and keyPoints.
1678
1679         Unfortunately none of this code is used much yet, thus isn't very testable.
1680
1681         * ksvg2/svg/SVGAnimateMotionElement.cpp:
1682         (WebCore::SVGAnimateMotionElement::parseMappedAttribute):
1683         * ksvg2/svg/SVGAnimationElement.cpp:
1684         (WebCore::SVGAnimationElement::parseKeyNumbers):
1685         (WebCore::parseKeySplines):
1686         (WebCore::SVGAnimationElement::parseMappedAttribute):
1687         * ksvg2/svg/SVGAnimationElement.h:
1688         * ksvg2/svg/SVGNumberList.cpp:
1689         (WebCore::SVGNumberList::parse):
1690
1691 2007-01-18  Adam Roben  <aroben@apple.com>
1692
1693         Reviewed by Beth.
1694
1695         Fix: <rdar://problem/4939672> REGRESSION: With text selected that is
1696         not a link, the "Remove Link" contextual menu item remains active
1697
1698         * platform/ContextMenuItem.h: Added enabled method.
1699         * platform/qt/ContextMenuItemQt.cpp:
1700         (WebCore::ContextMenuItem::enabled): Implemented.
1701         * platform/mac/ContextMenuItemMac.mm:
1702         (WebCore::ContextMenuItem::enabled): Ditto.
1703         * platform/mac/ContextMenuMac.mm:
1704         (-[WebCoreMenuTarget validateMenuItem:]): Implemented to fulfill the
1705         NSMenuValidation protocol.
1706         
1707 2007-01-18  Beth Dakin  <bdakin@apple.com>
1708
1709         Reviewed by Adele.
1710
1711         Fix for <rdar://problem/4939558> REGRESSION: "Search in Google", 
1712         "Search in Spotlight" and "Look up in Dictionary" are missing 
1713         initially from the contextual menu
1714
1715         The bug here is that we select the we were selecting the word after 
1716         the context menu event was dispatched and after the context menu 
1717         was built up.
1718
1719         * page/EventHandler.cpp:
1720         (WebCore::EventHandler::sendContextMenuEvent): Select the word 
1721         before dispatching the event. It is safe to remove the check for 
1722         swallowEvent since WebCore context menus ensure that we always 
1723         swallow the event anyway.
1724
1725 2007-01-18  Mark Rowe  <mrowe@apple.com>
1726
1727         Reviewed by Tim H.
1728
1729         Fix for http://bugs.webkit.org/show_bug.cgi?id=7926
1730         Bug 7926: Crash using -callWebScriptMethod to access offsetTop property
1731
1732         * bindings/objc/WebScriptObject.mm:
1733         (-[WebScriptObject callWebScriptMethod:withArguments:]): Bail out early if function value is an immediate,
1734         or if the function object is not callable.
1735
1736 2007-01-18  Sam Weinig  <sam@webkit.org>
1737
1738         Reviewed by Maciej.
1739
1740         Patch for http://bugs.webkit.org/show_bug.cgi?id=11853
1741         REGRESSION (r17352): Whitespace in <title> is rendered
1742
1743         * loader/DocumentLoader.cpp:
1744         (WebCore::canonicalizedTitle): Changed to also collapse internal
1745         whitespace.  This required removing an optimization that is no
1746         longer possible.
1747         * manual-tests/title-internal-whitespace.html: Added.
1748
1749 2007-01-18  Mitz Pettel  <mitz@webkit.org>
1750
1751         Reviewed by Maciej.
1752
1753         - fix http://bugs.webkit.org/show_bug.cgi?id=12039
1754           Assertion failure in WebCore::Font::primaryFont
1755
1756         Test: fast/text/font-initial.html
1757
1758         * css/cssstyleselector.cpp:
1759         (WebCore::CSSStyleSelector::applyProperty): Give 'font: initial' the
1760         Standard generic family. This makes the FontDescription different from
1761         that of the initial font of a GraphicsContext, ensuring that the latter
1762         will not be used.
1763
1764 2007-01-18  Mitz Pettel  <mitz@webkit.org>
1765
1766         Reviewed by Darin.
1767
1768         - fix http://bugs.webkit.org/show_bug.cgi?id=11451
1769           REGRESSION: Dell.com does not render correctly in ToT (stylesheet not loaded)
1770
1771         Test: http/tests/misc/css-accept-any-type.html
1772
1773         * loader/CachedCSSStyleSheet.cpp:
1774         (WebCore::CachedCSSStyleSheet::CachedCSSStyleSheet): Changed the accept header
1775         for stylesheets to "text/css,*/*;q=0.1" to match Firefox, accepting CSS served
1776         as any type.
1777
1778 2007-01-18  Mitz Pettel  <mitz@webkit.org>
1779
1780         Reviewed by Darin.
1781
1782         - fix http://bugs.webkit.org/show_bug.cgi?id=11271
1783         REGRESSION (r12358): Text in display: table unselectable
1784
1785         Test: editing/selection/display-table-text.html
1786
1787         * editing/htmlediting.cpp:
1788         (WebCore::isTableElement): Changed to return false for text nodes.
1789
1790 2007-01-18  Mitz Pettel  <mitz@webkit.org>
1791
1792         Reviewed by Darin.
1793
1794         - fix http://bugs.webkit.org/show_bug.cgi?id=6218
1795           CSS1: WebTextRenderer caches and re-uses fallback renderers that are based on family lists
1796
1797         This patch takes character-to-glyph mapping out of FontData and instead makes
1798         each Font keep its own mapping, using a shared set of glyph page fallback trees.
1799
1800         For each page number there is (at most) one tree. A path from the root to a
1801         node in the tree corresponds to a fallback list of FontDatas. The node points to
1802         a page (which may be shared with other nodes) that maps each character in its range
1803         to a glyph in the first FontData in the fallback list that has it, or to 0 if none of
1804         the FontDatas has a glyph for that character. A special kind of node, that can
1805         only occur as a leaf, corresponds to using system fallback fonts after the list
1806         has been exhausted. This prevents system fallback from polluting non-leaf
1807         nodes.
1808
1809         Nodes and pages are initialized lazily and employ "copy on write".
1810
1811         * CMakeLists.txt:
1812         * WebCore.pro:
1813         * WebCore.vcproj/WebCore/WebCore.vcproj:
1814         * WebCore.xcodeproj/project.pbxproj:
1815         * WebCoreSources.bkl:
1816         * platform/Font.cpp:
1817         (WebCore::WidthIterator::WidthIterator): Removed substituteFontData.
1818         (WebCore::WidthIterator::advance): Moved all character-to-glyph mapping logic out
1819         of here and replaced it with a call to Font::glyphDataForCharacter().
1820         (WebCore::Font::Font):
1821         (WebCore::Font::operator=):
1822         (WebCore::Font::glyphDataForCharacter): Added. This method performs the lookup in the
1823         page fallback trees, triggering lazy initialization as needed, and caching pointers to
1824         the retrieved page tree nodes in the font.
1825         (WebCore::Font::update):
1826         (WebCore::Font::drawSimpleText):
1827         (WebCore::Font::floatWidth):
1828         (WebCore::Font::floatWidthForSimpleText): Removed substituteFont argument.
1829         (WebCore::Font::offsetForPositionForSimpleText):
1830         * platform/Font.h:
1831         * platform/FontData.cpp:
1832         (WebCore::FontData::FontData):
1833         * platform/FontData.h:
1834         (WebCore::FontData::missingGlyphData): Added. Returns the "missing glyph" GlyphData for
1835         this FontData.
1836         * platform/GlyphMap.cpp: Removed.
1837         * platform/GlyphMap.h: Removed.
1838         * platform/GlyphPageTreeNode.cpp: Renamed GlyphMap.cpp to this.
1839         (WebCore::GlyphPageTreeNode::getRoot): Added. Returns the root of the page fallback tree for
1840         the given page number.
1841         (WebCore::GlyphPageTreeNode::initializePage): Added. Helper method that initializes the page
1842         pointer of a node, possibly to a pointer to another node's page or to 0.
1843         (WebCore::GlyphPageTreeNode::getChild): Added.
1844         * platform/GlyphPageTreeNode.h: Renamed GlyphMap.h to this.
1845         (WebCore::GlyphPage::glyphDataForCharacter):
1846         (WebCore::GlyphPage::setGlyphDataForCharacter):
1847         (WebCore::GlyphPage::setGlyphDataForIndex):
1848         (WebCore::GlyphPageTreeNode::GlyphPageTreeNode):
1849         (WebCore::GlyphPageTreeNode::getRootChild):
1850         (WebCore::GlyphPageTreeNode::parent):
1851         (WebCore::GlyphPageTreeNode::page):
1852         (WebCore::GlyphPageTreeNode::level):
1853         (WebCore::GlyphPageTreeNode::isSystemFallback): Added. Returns whether the node corresponds
1854         to the system providing fallback fonts, which is done on a character-by-character basis.
1855         * platform/gdk/GlyphMapGdk.cpp: Removed.
1856         * platform/gdk/GlyphPageTreeNodeGdk.cpp: Renamed GlyphMapGdk.cpp to this.
1857         (WebCore::GlyphPage::fill):
1858         * platform/mac/FontDataMac.mm:
1859         (WebCore::FontData::platformInit):
1860         * platform/mac/FontMac.mm:
1861         (WebCore::Font::Font):
1862         * platform/mac/GlyphMapMac.cpp: Removed.
1863         * platform/mac/GlyphPageTreeNodeMac.cpp: Renamed GlypMapMac.cpp to this.
1864         (WebCore::GlyphPage::fill): Changed to return false if the font has no glyphs in the page.
1865         * platform/qt/GlyphMapQt.cpp: Removed.
1866         * platform/qt/GlyphPageTreeNodeQt.cpp: Renamed GlyphMapQt.cpp to this.
1867         (WebCore::GlyphPage::fill):
1868         * platform/win/GlyphMapWin.cpp: Removed.
1869         * platform/win/GlyphPageTreeNodeWin.cpp: Renamed GlyphMapWin to this.
1870         (WebCore::GlyphPage::fill):
1871
1872 2007-01-18  Mitz Pettel  <mitz@webkit.org>
1873
1874         Reviewed by Darin.
1875
1876         - fix http://bugs.webkit.org/show_bug.cgi?id=9952
1877           REGRESSION: Repro crash when dragging an image from the window to the address bar
1878
1879         * page/FrameView.cpp:
1880         (WebCore::FrameView::~FrameView): Removed the call to Document::detach(). If this
1881         view is the current view, then the Frame should have already detached the document.
1882         Added an assertion that this is the case. If this view is not the current view,
1883         then it cannot access its document, but the page cache should have detached it already.
1884         Similarly, changed to call RenderPart::setWidget() only if this is the current view
1885         in the frame.
1886         (WebCore::FrameView::adjustViewSize): Added an assertion that this view is the current
1887         view in the frame.
1888         (WebCore::FrameView::layout): Ditto.
1889         (WebCore::FrameView::scheduleRelayout): Ditto.
1890         (WebCore::FrameView::scheduleRelayoutOfSubtree): Ditto.
1891         (WebCore::FrameView::windowClipRect): Ditto.
1892
1893 2007-01-18  Eric Seidel  <eric@webkit.org>
1894
1895         Reviewed by bdash.
1896
1897         No test needed, removed bogus debug-only ASSERT.
1898
1899         * rendering/RenderSVGContainer.cpp:
1900         (WebCore::RenderSVGContainer::paint):
1901
1902 2007-01-18  Alice Liu  <alice.liu@apple.com>
1903
1904         Build Fix
1905
1906         * platform/mac/PasteboardMac.mm:
1907         (WebCore::Pasteboard::writeSelection):
1908
1909 2007-01-18  Alice Liu  <alice.liu@apple.com>
1910
1911         Reviewed by Mark Rowe.
1912
1913         Fixes the leaks from my last patch, except for the first change below which is a missing delegate call for Mail purposes
1914
1915         * editing/Editor.cpp:
1916         (WebCore::Editor::cut):
1917         * platform/Pasteboard.h:
1918         * platform/mac/PasteboardMac.mm:
1919         (WebCore::Pasteboard::Pasteboard):
1920         (WebCore::Pasteboard::clear):
1921         (WebCore::Pasteboard::writeSelection):
1922         (WebCore::Pasteboard::writeURL):
1923         (WebCore::Pasteboard::plainText):
1924         (WebCore::Pasteboard::documentFragment):
1925
1926 2007-01-18  David Hyatt  <hyatt@apple.com>
1927
1928         Make sure layer autoscrolling puts the event coordinates into the layer's coordinate space before
1929         calling hitTest on it.  Fixes "flashy" selection in textareas.
1930
1931         Reviewed by darin
1932
1933         * rendering/RenderLayer.cpp:
1934         (WebCore::RenderLayer::autoscroll):
1935         * rendering/RenderTextControl.cpp:
1936         (WebCore::RenderTextControl::nodeAtPoint):
1937
1938 2007-01-18  Anders Carlsson  <acarlsson@apple.com>
1939
1940         Reviewed by Adam.
1941
1942         Get rid of ResourceLoaderMac.mm and make willCacheResponse platform-independent.
1943         
1944         * loader/ResourceLoader.cpp:
1945         (WebCore::ResourceLoader::willCacheResponse):
1946         * loader/ResourceLoader.h:
1947         * loader/mac/ResourceLoaderMac.mm: Removed.
1948         * platform/network/ResourceHandleClient.h:
1949         (WebCore::):
1950         (WebCore::ResourceHandleClient::willCacheResponse):
1951         (WebCore::ResourceHandleClient::willStopBufferingData):
1952         * platform/network/mac/ResourceHandleMac.mm:
1953         (-[WebCoreResourceHandleAsDelegate connection:willCacheResponse:]):
1954
1955 2007-01-18  Maciej Stachowiak  <mjs@apple.com>
1956
1957         Reviewed by John.
1958
1959         - fixed <rdar://problem/4887416> REGRESSION (SearchField): Assertion failure in HTMLInputElement::setValueFromRenderer when editing via drag and drop (11846)
1960         http://bugs.webkit.org/show_bug.cgi?id=11846
1961         
1962         * editing/ReplaceSelectionCommand.cpp:
1963         (WebCore::ReplaceSelectionCommand::doApply): Don't insert extra paragraph separators to avoid
1964         nesting blocks in plaintext mode, since that's not an issue under normal circumstances.
1965         * html/HTMLInputElement.h:
1966         * manual-tests/drag-move-in-search-field.html: Added.
1967         * rendering/RenderTextControl.cpp:
1968         (WebCore::RenderTextControl::subtreeHasChanged): constrain the value; we'd
1969         rather truncate it than end up with an illegal value here.
1970
1971 2007-01-18  Simon Hausmann  <hausmann@kde.org>
1972
1973         Reviewed by Zack.
1974
1975         * WebCore.pro: Ha^H^HFix to support massive parallel builds.
1976
1977 2007-01-18  David Kilzer  <ddkilzer@kilzer.net>
1978
1979         Reviewed by Darin and Mitz.
1980
1981         - fix http://bugs.webkit.org/show_bug.cgi?id=12305
1982           REGRESSION: Images do not load in video sections on CNN.com homepage
1983
1984         <rdar://problem/4931480> REGRESSION: Images do not load in video sections on CNN.com homepage (12305)
1985
1986         Test: fast/dom/HTMLImageElement/image-lowsrc-getset.html
1987
1988         * html/HTMLAttributeNames.in: Added lowsrc.
1989         * html/HTMLImageElement.cpp:
1990         (WebCore::HTMLImageElement::isURLAttribute): Added lowsrc.
1991         (WebCore::HTMLImageElement::lowsrc): Added.
1992         (WebCore::HTMLImageElement::setLowsrc): Added.
1993         * html/HTMLImageElement.h: Added lowsrc and setLowsrc.
1994         * html/HTMLImageElement.idl: Added lowsrc.
1995
1996 2007-01-18  Simon Hausmann  <hausmann@kde.org>
1997
1998         Reviewed by Zack.
1999
2000         * WebCore.pro: Remove generated files on make clean.
2001
2002 2007-01-17  Alice Liu  <alice.liu@apple.com>
2003
2004         Reviewed by Harrison.
2005
2006         Fix for <rdar://problem/4894155> REGRESSION: Extra line break is pasted with content into message body after choosing File - Paste
2007
2008         Migration of some editing code from WebHTMView to WebCore::Editor
2009         resulted in not calling pasteboardTypesForSelection, which Mail was
2010         overriding for the special purpose of adding a type to the
2011         pasteboard after WebKit did.  This patch adds 2 separate code paths
2012         for Tiger and Leopard.  On Tiger we give in and call the WebView's
2013         pasteboardTypesForSelection.  On Leopard we call a delegate after
2014         the pasteboard types are set. 
2015
2016         * bridge/EditorClient.h:
2017         * editing/Editor.h:
2018         * platform/Pasteboard.h:
2019         * platform/graphics/svg/SVGImageEmptyClients.h:
2020         (WebCore::SVGEmptyEditorClient::didSetSelectionTypesForPasteboard):
2021         (WebCore::SVGEmptyEditorClient::pasteboardTypesForSelection):
2022         * platform/mac/PasteboardMac.mm:
2023         (WebCore::Pasteboard::Pasteboard):
2024         (WebCore::Pasteboard::clear):
2025         (WebCore::Pasteboard::writeSelection):
2026         (WebCore::Pasteboard::writeURL):
2027         (WebCore::Pasteboard::plainText):
2028         (WebCore::Pasteboard::documentFragment):
2029
2030 2007-01-17  John Sullivan  <sullivan@apple.com>
2031
2032         Reviewed by Darin
2033
2034         - WebCore part of fix for <rdar://problem/4462420> REGRESSION: Mail hangs during 
2035           Replace All if the replacement string contains the search string
2036         
2037         * page/Frame.h:
2038         * page/Frame.cpp:
2039         (WebCore::Frame::findString):
2040         new startInSelection parameter -- if true, search starts looking in selection; if false,
2041         search starts looking after the selection
2042         
2043         * page/mac/WebCoreFrameBridge.h:
2044         * page/mac/WebCoreFrameBridge.mm:
2045         (-[WebCoreFrameBridge searchFor:direction:caseSensitive:wrap:startInSelection:]):
2046         new startInSelection parameter, passed through to Frame::findString()
2047
2048         * editing/JSEditor.cpp:
2049         pass false for new findString parameter, to match old behavior
2050
2051 2007-01-17  Beth Dakin  <bdakin@apple.com>
2052
2053         Rubber stamped by Darin.
2054
2055         * rendering/HitTestResult.cpp: Just added a comment.
2056
2057 2007-01-17  Justin Garcia  <justin.garcia@apple.com>
2058
2059         Reviewed by darin
2060         
2061         <rdar://problem/4920488>
2062         REGRESSION: A crash occurs at WebCore::Range::processContents () when removing formatting from selected text (that contains a link)
2063
2064         * dom/Range.cpp:
2065         (WebCore::Range::commonAncestorContainer): Return null if the nodes
2066         don't have a common ancestor.  As a side effect, the public 
2067         commonAncestorContainer now sets an exception if the Range starts
2068         in one document and ends in another, or starts or ends in a tree
2069         that's been removed from the document.  The spec doesn't cover
2070         this and there is no precedent in other browsers for this case because
2071         they don't allow invalid Ranges (you can create one with WebCore
2072         by removing a node that contains the start/end of a Range).
2073         (WebCore::Range::compareBoundaryPoints): If the the two positions
2074         are in nodes that have no common ancestor, return null.  This doesn't
2075         change the behavior of the public compareBoundaryPoints: it already
2076         throws an exception if the two positions are in nodes that don't have
2077         a common ancestor.  This follows the spec.
2078
2079 2007-01-17  John Sullivan  <sullivan@apple.com>
2080
2081         The one word was typed by me, but only after debugging for a long time with Darin.
2082
2083         - fixed <rdar://problem/4912002> REGRESSION: Series of words marked as a single misspelled word
2084
2085         * editing/TextIterator.cpp:
2086         (WebCore::WordAwareIterator::WordAwareIterator):
2087         We were creating a TextIterator with the default kind, but WordAwareIterator is designed to work
2088         in concert with CharacterIterator, so they need to use the same kind. CharacterIterator uses
2089         kind RUNFINDER, so WordAwareIterator needs to do so also.
2090
2091 2007-01-17  Adele Peterson  <adele@apple.com>
2092
2093         Reviewed by Brady.
2094
2095         Fix for <rdar://problem/4900895> REGRESSION: onChange doesn't always fire for popups that have had value changed by JS
2096
2097         No test case since you need to open up the menu to fire onChange.
2098
2099         * html/HTMLSelectElement.cpp: (WebCore::HTMLSelectElement::setSelectedIndex):
2100           Keep track of m_lastOnChangeIndex even when we're not firing onChange.  Since
2101           the selected index has changed, we still want the m_lastOnChangeIndex to be up to date when we compare
2102           it later.  This matches our behavior in Safari 2.0.
2103
2104 2007-01-17  Adele Peterson  <adele@apple.com>
2105
2106         Reviewed by Darin and John.
2107
2108         - Fix for <rdar://problem/4816550> REGRESSION: autoscrolling doesn't work after double-click
2109
2110         * page/EventHandler.cpp: (WebCore::EventHandler::handleMousePressEvent): Set swallowEvent bool instead
2111           of returning early for double and triple clicks.
2112
2113 2007-01-17  Darin Adler  <darin@apple.com>
2114
2115         Reviewed by Hyatt.
2116
2117         * rendering/RenderObject.h: Removed unused nextEditable and previousEditable.
2118         * rendering/RenderObject.cpp: Ditto.
2119
2120 2007-01-17  Darin Adler  <darin@apple.com>
2121
2122         Reviewed by Maciej.
2123
2124         - fix http://bugs.webkit.org/show_bug.cgi?id=12278
2125           <rdar://problem/4928705> REGRESSION(r13070): Dragged image size includes padding (12278)
2126
2127         * WebCore.exp: Added HitTestResult::imageRect,
2128         removed HitTestResult::boundingBox.
2129
2130         * rendering/HitTestResult.h:
2131         * rendering/HitTestResult.cpp: (WebCore::HitTestResult::imageRect):
2132         Added. Returns the content rectangle of the image.
2133
2134         * rendering/RenderObject.h:
2135         * rendering/RenderObject.cpp:
2136         (WebCore::RenderObject::absolutePosition): Made const.
2137         (WebCore::RenderObject::contentBox): Added.
2138         (WebCore::RenderObject::absoluteContentBox): Added.
2139
2140         * rendering/RenderBox.h:
2141         * rendering/RenderBox.cpp:
2142         (WebCore::RenderBox::absolutePosition): Made const.
2143
2144         * rendering/RenderTableCell.h:
2145         * rendering/RenderTableCell.cpp:
2146         (WebCore::RenderTableCell::absolutePosition): Made const.
2147
2148         * rendering/RenderView.h:
2149         * rendering/RenderView.cpp:
2150         (WebCore::RenderView::absolutePosition): Made const.
2151
2152 2007-01-17  Adele Peterson  <adele@apple.com>
2153
2154         Reviewed by Beth.
2155
2156         Fix for  http://bugs.webkit.org/show_bug.cgi?id=10139
2157         <rdar://problem/4823028> REGRESSION: Reproducible crash when selecting a popup/button with ::selection pseudostyle
2158
2159         Test: fast/css/pseudostyle-anonymous-text.html
2160
2161         * rendering/RenderObject.cpp: (WebCore::RenderObject::getPseudoStyle): Nil check the node.
2162
2163 2007-01-17  Adele Peterson  <adele@apple.com>
2164
2165         Reviewed by Anders and John.
2166
2167         Fix for http://bugs.webkit.org/show_bug.cgi?id=11278
2168         <rdar://problem/4826875> REGRESSION: Popup width doesn't change to accommodate dynamic changes to options
2169
2170         Test: fast/forms/menulist-width-change.html
2171
2172         * rendering/RenderMenuList.cpp: (WebCore::RenderMenuList::updateFromElement):
2173           When the options change, call setNeedsLayoutAndMinMaxRecalc.
2174
2175 2007-01-16  Alexey Proskuryakov  <ap@webkit.org>
2176
2177         Reviewed by Maciej.
2178
2179         http://bugs.webkit.org/show_bug.cgi?id=12268
2180         Give object prototypes their own names
2181
2182         * bindings/js/kjs_html.cpp: Changed the names of KJS:HTMLElement and KJS::HTMLElement to 
2183         not match the names of their WebCore counterparts. The "DOM" prefix I gave them doesn't 
2184         seem to carry much sense, but matches some other kjs_html object names.
2185
2186         * bindings/scripts/CodeGeneratorJS.pm: Append "Proto" to interface name for the prototype's ClassInfo.
2187
2188         * bindings/js/JSHTMLInputElementBase.cpp:
2189         (WebCore::JSHTMLInputElementBasePrototypeFunction::callAsFunction):
2190         (WebCore::JSHTMLInputElementBase::JSHTMLInputElementBase):
2191         * bindings/js/JSHTMLInputElementBase.h:
2192         * bindings/js/JSXMLHttpRequest.cpp:
2193         (KJS::JSXMLHttpRequestConstructorImp::JSXMLHttpRequestConstructorImp):
2194         (KJS::JSXMLHttpRequest::JSXMLHttpRequest):
2195         (KJS::JSXMLHttpRequestPrototypeFunction::callAsFunction):
2196         * bindings/js/JSXMLHttpRequest.h:
2197         * bindings/js/JSXSLTProcessor.cpp:
2198         (KJS::JSXSLTProcessor::JSXSLTProcessor):
2199         (KJS::XSLTProcessorPrototypeFunction::callAsFunction):
2200         (KJS::XSLTProcessorConstructorImp::XSLTProcessorConstructorImp):
2201         * bindings/js/kjs_css.cpp:
2202         (KJS::DOMCSSStyleDeclaration::DOMCSSStyleDeclaration):
2203         (KJS::DOMCSSStyleDeclarationPrototypeFunction::callAsFunction):
2204         (KJS::DOMMediaList::DOMMediaList):
2205         (KJS::KJS::DOMMediaListPrototypeFunction::callAsFunction):
2206         (KJS::DOMCSSStyleSheet::DOMCSSStyleSheet):
2207         (KJS::DOMCSSStyleSheetPrototypeFunction::callAsFunction):
2208         (KJS::DOMCSSValue::DOMCSSValue):
2209         (KJS::DOMCSSValuePrototypeFunction::callAsFunction):
2210         * bindings/js/kjs_css.h:
2211         * bindings/js/kjs_dom.cpp:
2212         (KJS::DOMNode::DOMNode):
2213         (KJS::DOMNodePrototypeFunction::callAsFunction):
2214         (KJS::DOMEventTargetNode::DOMEventTargetNode):
2215         (KJS::DOMEventTargetNodePrototypeFunction::callAsFunction):
2216         (KJS::DOMNamedNodeMap::DOMNamedNodeMap):
2217         (KJS::DOMNamedNodeMapPrototypeFunction::callAsFunction):
2218         * bindings/js/kjs_dom.h:
2219         * bindings/js/kjs_domnode.h:
2220         * bindings/js/kjs_events.cpp:
2221         (KJS::DOMEvent::DOMEvent):
2222         (KJS::DOMEventPrototypeFunction::callAsFunction):
2223         (KJS::Clipboard::Clipboard):
2224         (KJS::ClipboardPrototypeFunction::callAsFunction):
2225         * bindings/js/kjs_events.h:
2226         * bindings/js/kjs_html.cpp:
2227         (KJS::JSHTMLDocumentPrototypeFunction::callAsFunction):
2228         (KJS::):
2229         (KJS::JSHTMLDocument::JSHTMLDocument):
2230         (KJS::JSHTMLElementPrototypeFunction::callAsFunction):
2231         (KJS::JSHTMLElement::JSHTMLElement):
2232         (KJS::JSHTMLCollection::JSHTMLCollection):
2233         (KJS::JSHTMLCollectionPrototypeFunction::callAsFunction):
2234         * bindings/js/kjs_html.h:
2235         * bindings/js/kjs_navigator.cpp:
2236         * bindings/js/kjs_traversal.cpp:
2237         (KJS::DOMNodeFilter::DOMNodeFilter):
2238         (KJS::DOMNodeFilterPrototypeFunction::callAsFunction):
2239         * bindings/js/kjs_window.cpp:
2240         (KJS::Window::clear):
2241         Changed Proto to Prototype, and ProtoFunc to PrototypeFunction.
2242
2243 2007-01-17  Lars Knoll <lars@trolltech.com>
2244
2245         Reviewed by Zack and Darin
2246
2247         Fix the Qt build again after the latest Image changes.
2248         Also make some of the methods implemented in ImageCG 
2249         crossplatform.
2250
2251         * platform/graphics/BitmapImage.h:
2252         * platform/graphics/Image.cpp:
2253         (WebCore::Image::fillWithSolidColor):
2254         (WebCore::calculatePatternScale):
2255         (WebCore::Image::drawTiled):
2256         * platform/graphics/Image.h:
2257         * platform/graphics/cg/ImageCG.cpp:
2258         (WebCore::BitmapImage::draw):
2259         * platform/graphics/qt/ImageQt.cpp:
2260         (WebCore::Image::loadPlatformResource):
2261         (WebCore::Image::drawPattern):
2262         (WebCore::BitmapImage::initPlatformData):
2263         (WebCore::BitmapImage::invalidatePlatformData):
2264         (WebCore::BitmapImage::draw):
2265         (WebCore::BitmapImage::drawPattern):
2266         * platform/qt/TemporaryLinkStubs.cpp:
2267
2268 2007-01-17  Darin Adler  <darin@apple.com>
2269
2270         - quick attempt to fix the Qt build
2271
2272         * platform/graphics/qt/ImageQt.cpp: (WebCore::BitmapImage::drawTiled):
2273         Remove obsolete parameters from this stub.
2274
2275 2007-01-17  Eric Seidel  <eric@webkit.org>
2276
2277         Reviewed by rwlbuis.
2278
2279         Test: svg/custom/inner-svg-hit-test.svg
2280
2281         * rendering/RenderSVGContainer.cpp:
2282         (WebCore::RenderSVGContainer::nodeAtPoint): never allow containers to be hit.
2283
2284 2007-01-17  Lars Knoll <lars@trolltech.com>
2285
2286         Reviewed by Zack
2287
2288         Don't call receivedResponse twice for file: URLs.
2289         Never call back into the ResourceHandleClient once
2290         cancel() has been called on the ResourceHandle.
2291
2292         * WebCore.pro:
2293         * platform/network/qt/ResourceHandleManagerQt.cpp:
2294         (WebCore::ResourceHandleManager::cancel):
2295         (WebCore::ResourceHandleManager::receivedResponse):
2296         (WebCore::ResourceHandleManager::receivedData):
2297         (WebCore::ResourceHandleManager::receivedFinished):
2298         (WebCore::FileLoader::request):
2299         (WebCore::FileLoader::parseDataUrl):
2300         (WebCore::WebCoreHttp::scheduleNextRequest):
2301         * platform/network/qt/ResourceHandleManagerQt.h:
2302
2303 2007-01-17  Eric Seidel  <eric@webkit.org>
2304
2305         No review, build fix only.
2306
2307         * platform/graphics/cg/ImageCG.cpp: correct drawPatternCombined to drawPattern
2308         (WebCore::Image::drawPattern):
2309         (WebCore::Image::drawTiled):
2310
2311 2007-01-17  Eric Seidel  <eric@webkit.org>
2312
2313         Reviewed by mitz and rwlbuis.
2314         
2315         SVGs do not work as background images:
2316         http://bugs.webkit.org/show_bug.cgi?id=12096
2317
2318         Tests updated:
2319         - fast/images/svg-as-background.svg: now passes
2320         - fast/images/svg-as-tiled-background.svg: now passes
2321
2322         * platform/graphics/BitmapImage.h:
2323         (WebCore::BitmapImage::nativeImageForCurrentFrame):
2324         (WebCore::BitmapImage::mayFillWithSolidColor):
2325         (WebCore::BitmapImage::solidColor):
2326         * platform/graphics/Image.h:
2327         (WebCore::Image::mayFillWithSolidColor):
2328         (WebCore::Image::solidColor):
2329         (WebCore::Image::nativeImageForCurrentFrame):
2330         (WebCore::Image::startAnimation):
2331         * platform/graphics/cg/ImageCG.cpp:
2332         (WebCore::Image::drawPatternCallback):
2333         (WebCore::Image::drawPatternCombined):
2334         (WebCore::caculatePatternScale):
2335         (WebCore::Image::drawTiled):
2336         * platform/graphics/cg/PDFDocumentImage.cpp:
2337         * platform/graphics/cg/PDFDocumentImage.h:
2338         * platform/graphics/svg/SVGImage.cpp:
2339         (WebCore::SVGImage::nativeImageForCurrentFrame):
2340         * platform/graphics/svg/SVGImage.h:
2341
2342 2007-01-17  Rob Buis  <buis@kde.org>
2343
2344         Reviewed by Eric
2345
2346         Add proper condition for rx attribute negative check.
2347
2348         * ksvg2/svg/SVGRectElement.cpp:
2349         (WebCore::SVGRectElement::parseMappedAttribute):
2350
2351 2007-01-17  Lars Knoll <lars@trolltech.com>
2352
2353         Reviewed by Zack
2354
2355         change all notImplemented() macros to use qDebug
2356         instead of fprintf(stder, ...)
2357
2358         * loader/qt/DocumentLoaderQt.cpp:
2359         * loader/qt/FrameLoaderQt.cpp:
2360         * page/qt/EventHandlerQt.cpp:
2361         * page/qt/FrameQt.cpp:
2362         * platform/graphics/qt/GraphicsContextQt.cpp:
2363         * platform/graphics/qt/IconQt.cpp:
2364         * platform/network/qt/ResourceHandleManagerQt.cpp:
2365         * platform/network/qt/ResourceHandleQt.cpp:
2366         * platform/qt/CursorQt.cpp:
2367         * platform/qt/FileChooserQt.cpp:
2368         * platform/qt/MimeTypeRegistryQt.cpp:
2369         * platform/qt/PageQt.cpp: Removed.
2370         * platform/qt/PopupMenuQt.cpp:
2371         * platform/qt/ScrollViewQt.cpp:
2372         * platform/qt/TemporaryLinkStubs.cpp:
2373         * platform/qt/TextBoundaries.cpp:
2374         * platform/qt/WidgetQt.cpp:
2375
2376 2007-01-16  Brady Eidson  <beidson@apple.com>
2377
2378         Reviewed by Oliver
2379
2380         A few enhancements to the HTTP Auth architecture
2381
2382         * platform/network/ProtectionSpace.cpp:
2383         (WebCore::ProtectionSpace::isProxy):
2384         (WebCore::ProtectionSpace::receivesCredentialSecurely):
2385         * platform/network/ProtectionSpace.h:
2386
2387 2007-01-16  Alice Liu  <alice.liu@apple.com>
2388
2389         Reviewed by harrison.
2390
2391         Fixed <rdar://problem/4921134> WebKit needs extensible cut/copy to allow additional types to be written to pasteboard
2392
2393         * WebCore.xcodeproj/project.pbxproj:
2394         * bridge/EditorClient.h:
2395         * editing/Editor.cpp:
2396         (WebCore::Editor::copy):
2397         (WebCore::Editor::didWriteSelectionToPasteboard):
2398         * editing/Editor.h:
2399         * platform/graphics/svg/SVGImageEmptyClients.h:
2400         (WebCore::SVGEmptyEditorClient::didWriteSelectionToPasteboard):
2401
2402 2007-01-16  Justin Garcia  <justin.garcia@apple.com>
2403
2404         Reviewed by harrison
2405         
2406         <rdar://problem/4747450>
2407         Gmail Editor: Caret doesn't always position itself after list marker
2408         <rdar://problem/4917055>
2409         GMail Editor: A hang can occur when attempting to apply list styling to selected indented text
2410
2411         * editing/TextIterator.cpp:
2412         (WebCore::TextIterator::rangeFromLocationAndLength): Use VisiblePositions
2413         to compute the end of a run for emitted '\n's, because it's often wrong
2414         in that case.
2415
2416 2007-01-16  Darin Adler  <darin@apple.com>
2417
2418         - quick lame attempt to get Qt compiling again
2419
2420         * platform/qt/ContextMenuQt.cpp: Removed show() function.
2421
2422 2007-01-17  Nicholas Shanks  <contact@nickshanks.com>
2423
2424         Reviewed by Darin.
2425
2426         * platform/network/ResourceRequest.h:
2427         (WebCore::ResourceRequest::setHTTPAccept): Correct argument name.
2428
2429 2007-01-16  Beth Dakin  <bdakin@apple.com>
2430
2431         Reviewed by Adam.
2432
2433         Get rid of show() and hide() since they don't do anything.
2434
2435         * page/ContextMenuController.cpp:
2436         (WebCore::ContextMenuController::handleContextMenuEvent):
2437         * platform/ContextMenu.h:
2438         * platform/mac/ContextMenuMac.mm:
2439
2440 2007-01-16  Lars Knoll <lars@trolltech.com>
2441
2442         Reviewed by Zack
2443
2444         Cleaned up the way we create native widgets. They are
2445         now not created in WebCore anymore, but in the new
2446         Qt API to WebKit.
2447
2448         Fix a compile issue in the ResourceHandleManager.
2449
2450         * WebCore.pro:
2451         * platform/ScrollView.h:
2452         * platform/Widget.h:
2453         (WebCore::ResourceHandleManager::cancel):
2454         * platform/qt/ScrollViewCanvasQt.cpp:
2455         (WebCore::ScrollViewCanvasQt::ScrollViewCanvasQt):
2456         (WebCore::ScrollViewCanvasQt::paintEvent):
2457         (WebCore::ScrollViewCanvasQt::mouseMoveEvent):
2458         (WebCore::ScrollViewCanvasQt::mousePressEvent):
2459         (WebCore::ScrollViewCanvasQt::mouseReleaseEvent):
2460         (WebCore::ScrollViewCanvasQt::handleKeyEvent):
2461         * platform/qt/ScrollViewCanvasQt.h:
2462         * platform/qt/ScrollViewQt.cpp:
2463         (WebCore::ScrollView::ScrollView):
2464         (WebCore::ScrollView::setScrollArea):
2465         (WebCore::ScrollView::addChild):
2466         * platform/qt/WidgetQt.cpp:
2467         * platform/network/qt/ResourceHandleManagerQt.cpp:
2468
2469 2007-01-16  Lars Knoll <lars@trolltech.com>
2470
2471         Reviewed by Zack
2472
2473         Looks like ResourceHandle _has_ to do everything
2474         asynchronously if we don't want to run into
2475         lots of trouble in the loader.
2476
2477         Implement support data: URLs.
2478
2479         Remove some unused Qt only code in ResourceHandleClient.h
2480
2481         * platform/network/ResourceHandleClient.h:
2482         * platform/network/qt/ResourceHandleManagerQt.cpp:
2483         (WebCore::RequestQt::setURL):
2484         (WebCore::ResourceHandleManager::add):
2485         (WebCore::ResourceHandleManager::cancel):
2486         (WebCore::ResourceHandleManager::receivedFinished):
2487         (WebCore::LoaderThread::run):
2488         (WebCore::FileLoader::request):
2489         (WebCore::FileLoader::sendData):
2490         (WebCore::FileLoader::parseDataUrl):
2491         * platform/network/qt/ResourceHandleManagerQt.h:
2492
2493 2007-01-16  Eric Seidel  <eric@webkit.org>
2494
2495         Reviewed by mitz.
2496
2497         Refactor drawTiled implementations in preparation for combining them.
2498         Removed unused RoundTile code path.
2499
2500         * platform/graphics/cg/ImageCG.cpp:
2501         (WebCore::drawPattern):
2502         (WebCore::BitmapImage::drawTiled):
2503         (WebCore::caculatePatternScale):
2504
2505 2007-01-16  Darin Adler  <darin@apple.com>
2506
2507         Reviewed by Mark Rowe.
2508
2509         - removed unused field from loader
2510
2511         * loader/loader.cpp:
2512         (WebCore::Loader::numRequests):
2513         (WebCore::Loader::cancelRequests):
2514         * loader/loader.h:
2515
2516 2007-01-15  Rob Buis  <buis@kde.org>
2517
2518         Reviewed by Eric.
2519
2520         http://bugs.webkit.org/show_bug.cgi?id=12272
2521         SVG picture is clipped (edges not visible)
2522
2523         Expose css dpi constant and use it for svg, making
2524         1in amount to 96 pixels like for html.
2525
2526         * css/CSSPrimitiveValue.cpp:
2527         (WebCore::CSSPrimitiveValue::computeLengthFloat):
2528         (WebCore::scaleFactorForConversion):
2529         * css/csshelper.h:
2530         * ksvg2/svg/SVGLength.cpp:
2531         (WebCore::SVGLength::value):
2532         (WebCore::SVGLength::setValue):
2533         * ksvg2/svg/SVGLength.h:
2534
2535 2007-01-15  Brady Eidson  <beidson@apple.com>
2536
2537         Reviewed by Adam
2538         
2539         CFNet additions
2540
2541         * platform/network/AuthenticationChallenge.cpp:
2542         (WebCore::operator==):
2543         * platform/network/AuthenticationChallenge.h:
2544         (WebCore::AuthenticationChallenge::sourceHandle):
2545         (WebCore::AuthenticationChallenge::cfURLAuthChallengeRef):
2546         * platform/network/ResourceError.h:
2547         * platform/network/ResourceHandle.h:
2548         * platform/network/ResourceHandleInternal.h:
2549         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
2550
2551 2007-01-15  Eric Seidel  <eric@webkit.org>
2552
2553         Reviewed by hyatt.
2554
2555         Don't map attributes in namespaces other than null to CSS properties.
2556         
2557         Test: svg/custom/attribute-namespace-check.svg
2558
2559         * ksvg2/svg/SVGStyledElement.cpp:
2560         (WebCore::SVGStyledElement::cssPropertyIdForSVGAttributeName):
2561
2562 2007-01-15  Lars Naesbye Christensen  <larsnaesbye@stud.ku.dk>
2563
2564         Reviewed by Darin.
2565
2566         - http://bugs.webkit.org/show_bug.cgi?id=11112
2567           add a drop shadow to the hand cursor used for links
2568
2569         * Resources/linkCursor.png: Added a drop shadow.
2570
2571 2007-01-15  Darin Adler  <darin@apple.com>
2572
2573         Reviewed by Adam.
2574
2575         - fix http://bugs.webkit.org/show_bug.cgi?id=12190
2576           REGRESSION: Placeholder text does not reflect dynamic updates
2577
2578         Test: fast/forms/placeholder-set-attribute.html
2579
2580         * html/HTMLTextFieldInnerElement.cpp:
2581         (WebCore::HTMLSearchFieldCancelButtonElement::defaultEventHandler):
2582         Call onSearch on the element since I removed it from the renderer.
2583
2584         * rendering/RenderTextControl.h: Added explicit virtual keywords for overrides
2585         of virtual functions. Removed the unneeded onSearch function. Made the inheritance
2586         from PopupMenuClient be private, and made the overrides all private. Replaced the
2587         showPlaceholderIfNeeded and hidePlaceholderIfNeeded functions with updatePlaceholder.
2588         * rendering/RenderTextControl.cpp:
2589         (WebCore::RenderTextControl::createResultsButtonStyle): Added an assertion.
2590         (WebCore::RenderTextControl::updatePlaceholder): Added. Replaces the two
2591         functions, showPlaceholderIfNeeded and hidePlaceholderIfNeeded.
2592         (WebCore::RenderTextControl::updateFromElement): Added call to
2593         updatePlaceholder before updating the value. Also improved the structure
2594         of the function and corrected incorrect use of copy and replace.
2595         (WebCore::RenderTextControl::updateCancelButtonVisibility): Added an
2596         assertion and removed an unneeded local variable.
2597         (WebCore::RenderTextControl::subtreeHasChanged): Removed an unneeded
2598         null check and virtual function calls.
2599         (WebCore::RenderTextControl::forwardEvent): Replaced calls to the old
2600         functions with calls to updatePlaceholder.
2601         (WebCore::RenderTextControl::selectionChanged): Changed code to dispatch
2602         the select event directly -- I plan to remove the onSelect function, which
2603         was only called here.
2604         (WebCore::RenderTextControl::autosaveName): Removed too-specific cast and
2605         local variable.
2606         (WebCore::RenderTextControl::addSearchResult): Added assertion and changed
2607         variable name for clarity.
2608         (WebCore::RenderTextControl::valueChanged): Changed code to check for empty
2609         autosave name instead of null for consistency with other call sites that
2610         manage the autosave name. Also changed the code that dispatches an event
2611         to call onSearch on the input element so we don't need our own function.
2612
2613 2007-01-15  Eric Seidel  <eric@webkit.org>
2614
2615         Reviewed by hyatt.
2616
2617         Fix SVGStyledElement::parseMappedAttribute to only map SVG-allowed CSS properties
2618         (i.e. width is no longer mapped to CSS for SVG)
2619         Add SVGStyledElement::mapToEntry to allow RenderStyle-sharing
2620         http://bugs.webkit.org/show_bug.cgi?id=12060
2621
2622         * dom/MappedAttributeEntry.h:
2623         (WebCore::):
2624         * ksvg2/svg/SVGStyledElement.cpp:
2625         (WebCore::cssPropertyIdForName): new helper
2626         (WebCore::mapAttributeToCSSProperty): new helper
2627         (WebCore::SVGStyledElement::cssPropertyIdForSVGAttributeName): new helper
2628         (WebCore::SVGStyledElement::mapToEntry): added.
2629         (WebCore::SVGStyledElement::parseMappedAttribute): use cssPropertyIdForSVGAttributeName
2630         * ksvg2/svg/SVGStyledElement.h:
2631
2632 2007-01-15  Eric Seidel  <eric@webkit.org>
2633
2634         Reviewed by bdash.
2635
2636         Update header guards to follow new style guidelines using new clean-header-guards script.
2637
2638         * bindings/js/JSHTMLElementWrapperFactory.h:
2639         * bindings/js/JSHTMLInputElementBase.h:
2640         * bindings/js/JSHTMLOptionElementConstructor.h:
2641         * bindings/js/JSSVGElementWrapperFactory.h:
2642         * bindings/js/JSSVGPODTypeWrapper.h:
2643         * bindings/js/JSXMLHttpRequest.h:
2644         * bindings/js/JSXSLTProcessor.h:
2645         * bindings/js/kjs_binding.h:
2646         * bindings/js/kjs_css.h:
2647         * bindings/js/kjs_dom.h:
2648         * bindings/js/kjs_domnode.h:
2649         * bindings/js/kjs_events.h:
2650         * bindings/js/kjs_html.h:
2651         * bindings/js/kjs_navigator.h:
2652         * bindings/js/kjs_proxy.h:
2653         * bindings/js/kjs_traversal.h:
2654         * bindings/js/kjs_window.h:
2655         * bridge/EditorClient.h:
2656         * bridge/History.h:
2657         * css/CSSStyleSheet.h:
2658         * css/CSSValue.h:
2659         * css/CSSValueList.h:
2660         * css/DashboardRegion.h:
2661         * css/FontFamilyValue.h:
2662         * css/FontValue.h:
2663         * css/MediaFeatureNames.h:
2664         * css/MediaList.h:
2665         * css/Pair.h:
2666         * css/RectImpl.h:
2667         * css/ShadowValue.h:
2668         * css/StyleBase.h:
2669         * css/StyleList.h:
2670         * css/StyleSheet.h:
2671         * css/StyleSheetList.h:
2672         * css/cssstyleselector.h:
2673         * dom/BeforeTextInsertedEvent.h:
2674         * dom/CDATASection.h:
2675         * dom/CharacterData.h:
2676         * dom/ChildNodeList.h:
2677         * dom/Comment.h:
2678         * dom/DOMImplementation.h:
2679         * dom/DocPtr.h:
2680         * dom/Document.h:
2681         * dom/DocumentFragment.h:
2682         * dom/DocumentMarker.h:
2683         * dom/DocumentType.h:
2684         * dom/EditingText.h:
2685         * dom/Entity.h:
2686         * dom/EntityReference.h:
2687         * dom/EventNames.h:
2688         * dom/EventTargetNode.h:
2689         * dom/NameNodeList.h:
2690         * dom/NamedNodeMap.h:
2691         * dom/Node.h:
2692         * dom/NodeList.h:
2693         * dom/Notation.h:
2694         * dom/Position.h:
2695         * dom/ProcessingInstruction.h:
2696         * dom/Range.h:
2697         * dom/StyleElement.h:
2698         * dom/Text.h:
2699         * editing/AppendNodeCommand.h:
2700         * editing/ApplyStyleCommand.h:
2701         * editing/BreakBlockquoteCommand.h:
2702         * editing/CommandByName.h:
2703         * editing/CompositeEditCommand.h:
2704         * editing/DeleteButton.h:
2705         * editing/DeleteButtonController.h:
2706         * editing/DeleteFromTextNodeCommand.h:
2707         * editing/DeleteSelectionCommand.h:
2708         * editing/InsertIntoTextNodeCommand.h:
2709         * editing/InsertLineBreakCommand.h:
2710         * editing/InsertNodeBeforeCommand.h:
2711         * editing/InsertParagraphSeparatorCommand.h:
2712         * editing/InsertTextCommand.h:
2713         * editing/JoinTextNodesCommand.h:
2714         * editing/MergeIdenticalElementsCommand.h:
2715         * editing/ModifySelectionListLevel.h:
2716         * editing/MoveSelectionCommand.h:
2717         * editing/RemoveCSSPropertyCommand.h:
2718         * editing/RemoveNodeAttributeCommand.h:
2719         * editing/RemoveNodeCommand.h:
2720         * editing/RemoveNodePreservingChildrenCommand.h:
2721         * editing/ReplaceSelectionCommand.h:
2722         * editing/SetNodeAttributeCommand.h:
2723         * editing/SplitElementCommand.h:
2724         * editing/SplitTextNodeCommand.h:
2725         * editing/SplitTextNodeContainingElementCommand.h:
2726         * editing/TextGranularity.h:
2727         * editing/TypingCommand.h:
2728         * editing/WrapContentsInDummySpanCommand.h:
2729         * history/BackForwardList.h:
2730         * history/HistoryItem.h:
2731         * history/HistoryItemTimer.h:
2732         * history/PageCache.h:
2733         * html/CanvasGradient.h:
2734         * html/CanvasPattern.h:
2735         * html/CanvasRenderingContext2D.h:
2736         * html/CanvasStyle.h:
2737         * html/FormDataList.h:
2738         * html/HTMLAnchorElement.h:
2739         * html/HTMLAppletElement.h:
2740         * html/HTMLAreaElement.h:
2741         * html/HTMLBRElement.h:
2742         * html/HTMLBaseElement.h:
2743         * html/HTMLBaseFontElement.h:
2744         * html/HTMLBlockquoteElement.h:
2745         * html/HTMLBodyElement.h:
2746         * html/HTMLButtonElement.h:
2747         * html/HTMLCanvasElement.h:
2748         * html/HTMLCollection.h:
2749         * html/HTMLDListElement.h:
2750         * html/HTMLDirectoryElement.h:
2751         * html/HTMLDivElement.h:
2752         * html/HTMLElement.h:
2753         * html/HTMLElementFactory.h:
2754         * html/HTMLEmbedElement.h:
2755         * html/HTMLFieldSetElement.h:
2756         * html/HTMLFontElement.h:
2757         * html/HTMLFormCollection.h:
2758         * html/HTMLFormElement.h:
2759         * html/HTMLFrameSetElement.h:
2760         * html/HTMLGenericFormElement.h:
2761         * html/HTMLHRElement.h:
2762         * html/HTMLHeadElement.h:
2763         * html/HTMLHeadingElement.h:
2764         * html/HTMLHtmlElement.h:
2765         * html/HTMLImageElement.h:
2766         * html/HTMLImageLoader.h:
2767         * html/HTMLInputElement.h:
2768         * html/HTMLIsIndexElement.h:
2769         * html/HTMLKeygenElement.h:
2770         * html/HTMLLIElement.h:
2771         * html/HTMLLabelElement.h:
2772         * html/HTMLLegendElement.h:
2773         * html/HTMLLinkElement.h:
2774         * html/HTMLMapElement.h:
2775         * html/HTMLMarqueeElement.h:
2776         * html/HTMLMenuElement.h:
2777         * html/HTMLMetaElement.h:
2778         * html/HTMLModElement.h:
2779         * html/HTMLNameCollection.h:
2780         * html/HTMLOListElement.h:
2781         * html/HTMLObjectElement.h:
2782         * html/HTMLOptGroupElement.h:
2783         * html/HTMLOptionElement.h:
2784         * html/HTMLOptionsCollection.h:
2785         * html/HTMLParagraphElement.h:
2786         * html/HTMLParamElement.h:
2787         * html/HTMLParser.h:
2788         * html/HTMLPlugInElement.h:
2789         * html/HTMLPreElement.h:
2790         * html/HTMLQuoteElement.h:
2791         * html/HTMLScriptElement.h:
2792         * html/HTMLSelectElement.h:
2793         * html/HTMLStyleElement.h:
2794         * html/HTMLTableCaptionElement.h:
2795         * html/HTMLTableCellElement.h:
2796         * html/HTMLTableColElement.h:
2797         * html/HTMLTableElement.h:
2798         * html/HTMLTablePartElement.h:
2799         * html/HTMLTableRowElement.h:
2800         * html/HTMLTableSectionElement.h:
2801         * html/HTMLTextAreaElement.h:
2802         * html/HTMLTextFieldInnerElement.h:
2803         * html/HTMLTitleElement.h:
2804         * html/HTMLUListElement.h:
2805         * ksvg2/css/SVGRenderStyle.h:
2806         * ksvg2/css/SVGRenderStyleDefs.h:
2807         * ksvg2/events/JSSVGLazyEventListener.h:
2808         * ksvg2/events/SVGZoomEvent.h:
2809         * ksvg2/misc/KCanvasRenderingStyle.h:
2810         * ksvg2/misc/PointerEventsHitRules.h:
2811         * ksvg2/misc/SVGDocumentExtensions.h:
2812         * ksvg2/misc/SVGImageLoader.h:
2813         * ksvg2/misc/TimeScheduler.h:
2814         * ksvg2/svg/GradientAttributes.h:
2815         * ksvg2/svg/LinearGradientAttributes.h:
2816         * ksvg2/svg/PatternAttributes.h:
2817         * ksvg2/svg/RadialGradientAttributes.h:
2818         * ksvg2/svg/SVGAElement.h:
2819         * ksvg2/svg/SVGAngle.h:
2820         * ksvg2/svg/SVGAnimateColorElement.h:
2821         * ksvg2/svg/SVGAnimateElement.h:
2822         * ksvg2/svg/SVGAnimateMotionElement.h:
2823         * ksvg2/svg/SVGAnimateTransformElement.h:
2824         * ksvg2/svg/SVGAnimatedPathData.h:
2825         * ksvg2/svg/SVGAnimatedPoints.h:
2826         * ksvg2/svg/SVGAnimatedTemplate.h:
2827         * ksvg2/svg/SVGAnimationElement.h:
2828         * ksvg2/svg/SVGCircleElement.h:
2829         * ksvg2/svg/SVGClipPathElement.h:
2830         * ksvg2/svg/SVGColor.h:
2831         * ksvg2/svg/SVGComponentTransferFunctionElement.h:
2832         * ksvg2/svg/SVGCursorElement.h:
2833         * ksvg2/svg/SVGDOMImplementation.h:
2834         * ksvg2/svg/SVGDefsElement.h:
2835         * ksvg2/svg/SVGDescElement.h:
2836         * ksvg2/svg/SVGDocument.h:
2837         * ksvg2/svg/SVGElement.h:
2838         * ksvg2/svg/SVGElementInstance.h:
2839         * ksvg2/svg/SVGElementInstanceList.h:
2840         * ksvg2/svg/SVGEllipseElement.h:
2841         * ksvg2/svg/SVGExternalResourcesRequired.h:
2842         * ksvg2/svg/SVGFEBlendElement.h:
2843         * ksvg2/svg/SVGFEColorMatrixElement.h:
2844         * ksvg2/svg/SVGFEComponentTransferElement.h:
2845         * ksvg2/svg/SVGFECompositeElement.h:
2846         * ksvg2/svg/SVGFEDiffuseLightingElement.h:
2847         * ksvg2/svg/SVGFEDisplacementMapElement.h:
2848         * ksvg2/svg/SVGFEDistantLightElement.h:
2849         * ksvg2/svg/SVGFEFloodElement.h:
2850         * ksvg2/svg/SVGFEFuncAElement.h:
2851         * ksvg2/svg/SVGFEFuncBElement.h:
2852         * ksvg2/svg/SVGFEFuncGElement.h:
2853         * ksvg2/svg/SVGFEFuncRElement.h:
2854         * ksvg2/svg/SVGFEGaussianBlurElement.h:
2855         * ksvg2/svg/SVGFEImageElement.h:
2856         * ksvg2/svg/SVGFELightElement.h:
2857         * ksvg2/svg/SVGFEMergeElement.h:
2858         * ksvg2/svg/SVGFEMergeNodeElement.h:
2859         * ksvg2/svg/SVGFEOffsetElement.h:
2860         * ksvg2/svg/SVGFEPointLightElement.h:
2861         * ksvg2/svg/SVGFESpecularLightingElement.h:
2862         * ksvg2/svg/SVGFESpotLightElement.h:
2863         * ksvg2/svg/SVGFETileElement.h:
2864         * ksvg2/svg/SVGFETurbulenceElement.h:
2865         * ksvg2/svg/SVGFilterElement.h:
2866         * ksvg2/svg/SVGFilterPrimitiveStandardAttributes.h:
2867         * ksvg2/svg/SVGFitToViewBox.h:
2868         * ksvg2/svg/SVGForeignObjectElement.h:
2869         * ksvg2/svg/SVGGElement.h:
2870         * ksvg2/svg/SVGGradientElement.h:
2871         * ksvg2/svg/SVGImageElement.h:
2872         * ksvg2/svg/SVGLangSpace.h:
2873         * ksvg2/svg/SVGLength.h:
2874         * ksvg2/svg/SVGLengthList.h:
2875         * ksvg2/svg/SVGLineElement.h:
2876         * ksvg2/svg/SVGLinearGradientElement.h:
2877         * ksvg2/svg/SVGList.h:
2878         * ksvg2/svg/SVGListTraits.h:
2879         * ksvg2/svg/SVGLocatable.h:
2880         * ksvg2/svg/SVGMarkerElement.h:
2881         * ksvg2/svg/SVGMaskElement.h:
2882         * ksvg2/svg/SVGMetadataElement.h:
2883         * ksvg2/svg/SVGNumberList.h:
2884         * ksvg2/svg/SVGPaint.h:
2885         * ksvg2/svg/SVGParserUtilities.h:
2886         * ksvg2/svg/SVGPathElement.h:
2887         * ksvg2/svg/SVGPathSeg.h:
2888         * ksvg2/svg/SVGPathSegArc.h:
2889         * ksvg2/svg/SVGPathSegClosePath.h:
2890         * ksvg2/svg/SVGPathSegCurvetoCubic.h:
2891         * ksvg2/svg/SVGPathSegCurvetoCubicSmooth.h:
2892         * ksvg2/svg/SVGPathSegCurvetoQuadratic.h:
2893         * ksvg2/svg/SVGPathSegCurvetoQuadraticSmooth.h:
2894         * ksvg2/svg/SVGPathSegLineto.h:
2895         * ksvg2/svg/SVGPathSegLinetoHorizontal.h:
2896         * ksvg2/svg/SVGPathSegLinetoVertical.h:
2897         * ksvg2/svg/SVGPathSegList.h:
2898         * ksvg2/svg/SVGPathSegMoveto.h:
2899         * ksvg2/svg/SVGPatternElement.h:
2900         * ksvg2/svg/SVGPointList.h:
2901         * ksvg2/svg/SVGPolyElement.h:
2902         * ksvg2/svg/SVGPolygonElement.h:
2903         * ksvg2/svg/SVGPolylineElement.h:
2904         * ksvg2/svg/SVGPreserveAspectRatio.h:
2905         * ksvg2/svg/SVGRadialGradientElement.h:
2906         * ksvg2/svg/SVGRectElement.h:
2907         * ksvg2/svg/SVGRenderingIntent.h:
2908         * ksvg2/svg/SVGSVGElement.h:
2909         * ksvg2/svg/SVGScriptElement.h:
2910         * ksvg2/svg/SVGSetElement.h:
2911         * ksvg2/svg/SVGStopElement.h:
2912         * ksvg2/svg/SVGStringList.h:
2913         * ksvg2/svg/SVGStylable.h:
2914         * ksvg2/svg/SVGStyleElement.h:
2915         * ksvg2/svg/SVGStyledElement.h:
2916         * ksvg2/svg/SVGStyledLocatableElement.h:
2917         * ksvg2/svg/SVGStyledTransformableElement.h:
2918         * ksvg2/svg/SVGSwitchElement.h:
2919         * ksvg2/svg/SVGSymbolElement.h:
2920         * ksvg2/svg/SVGTRefElement.h:
2921         * ksvg2/svg/SVGTSpanElement.h:
2922         * ksvg2/svg/SVGTests.h:
2923         * ksvg2/svg/SVGTextContentElement.h:
2924         * ksvg2/svg/SVGTextElement.h:
2925         * ksvg2/svg/SVGTextPositioningElement.h:
2926         * ksvg2/svg/SVGTitleElement.h:
2927         * ksvg2/svg/SVGTransform.h:
2928         * ksvg2/svg/SVGTransformList.h:
2929         * ksvg2/svg/SVGTransformable.h:
2930         * ksvg2/svg/SVGURIReference.h:
2931         * ksvg2/svg/SVGUnitTypes.h:
2932         * ksvg2/svg/SVGUseElement.h:
2933         * ksvg2/svg/SVGViewElement.h:
2934         * ksvg2/svg/SVGZoomAndPan.h:
2935         * loader/CachedCSSStyleSheet.h:
2936         * loader/CachedImage.h:
2937         * loader/CachedXSLStyleSheet.h:
2938         * loader/DocumentLoader.h:
2939         * loader/Request.h:
2940         * loader/SubresourceLoader.h:
2941         * loader/icon/IconDataCache.h:
2942         * loader/icon/IconDatabase.h:
2943         * loader/icon/IconLoader.h:
2944         * loader/icon/SQLDatabase.h:
2945         * loader/icon/SQLStatement.h:
2946         * loader/icon/SQLTransaction.h:
2947         * page/Frame.h:
2948         * page/FrameLoadRequest.h:
2949         * page/FrameTree.h:
2950         * page/FrameView.h:
2951         * page/PageState.h:
2952         * page/Plugin.h:
2953         * page/qt/FrameQt.h:
2954         * page/qt/FrameQtClient.h:
2955         * platform/Arena.h:
2956         * platform/ArrayImpl.h:
2957         * platform/Cursor.h:
2958         * platform/DeprecatedArray.h:
2959         * platform/DeprecatedCString.h:
2960         * platform/FileChooser.h:
2961         * platform/Font.h:
2962         * platform/FontCache.h:
2963         * platform/FontData.h:
2964         * platform/FontDescription.h:
2965         * platform/FontFamily.h:
2966         * platform/GlyphBuffer.h:
2967         * platform/GlyphMap.h:
2968         * platform/GlyphWidthMap.h:
2969         * platform/Logging.h:
2970         * platform/Pasteboard.h:
2971         * platform/PlatformString.h:
2972         * platform/PlugInInfoStore.h:
2973         * platform/PopupMenu.h:
2974         * platform/PopupMenuClient.h:
2975         * platform/ScrollBar.h:
2976         * platform/ScrollView.h:
2977         * platform/SearchPopupMenu.h:
2978         * platform/Shared.h:
2979         * platform/Sound.h:
2980         * platform/SystemTime.h:
2981         * platform/Timer.h:
2982         * platform/Widget.h:
2983         * platform/cf/RetainPtr.h:
2984         * platform/gdk/ChromeClientGdk.h:
2985         * platform/gdk/FontPlatformData.h:
2986         * platform/gdk/FrameGdk.h:
2987         * platform/gdk/KeyboardCodes.h:
2988         * platform/gdk/RenderPopupMenuGdk.h:
2989         * platform/gdk/RenderThemeGdk.h:
2990         * platform/graphics/BitmapImage.h:
2991         * platform/graphics/Color.h:
2992         * platform/graphics/FloatPoint.h:
2993         * platform/graphics/FloatPoint3D.h:
2994         * platform/graphics/FloatRect.h:
2995         * platform/graphics/Icon.h:
2996         * platform/graphics/Image.h:
2997         * platform/graphics/ImageAnimationObserver.h:
2998         * platform/graphics/ImageBuffer.h:
2999         * platform/graphics/ImageSource.h:
3000         * platform/graphics/IntPoint.h:
3001         * platform/graphics/IntRect.h:
3002         * platform/graphics/IntSize.h:
3003         * platform/graphics/IntSizeHash.h:
3004         * platform/graphics/PathTraversalState.h:
3005         * platform/graphics/Pen.h:
3006         * platform/graphics/qt/ImageDecoderQt.h:
3007         * platform/graphics/svg/SVGImage.h:
3008         * platform/graphics/svg/SVGImageEmptyClients.h:
3009         * platform/graphics/svg/SVGPaintServer.h:
3010         * platform/graphics/svg/SVGPaintServerGradient.h:
3011         * platform/graphics/svg/SVGPaintServerLinearGradient.h:
3012         * platform/graphics/svg/SVGPaintServerPattern.h:
3013         * platform/graphics/svg/SVGPaintServerRadialGradient.h:
3014         * platform/graphics/svg/SVGPaintServerSolid.h:
3015         * platform/graphics/svg/SVGResource.h:
3016         * platform/graphics/svg/SVGResourceClipper.h:
3017         * platform/graphics/svg/SVGResourceFilter.h:
3018         * platform/graphics/svg/SVGResourceMarker.h:
3019         * platform/graphics/svg/SVGResourceMasker.h:
3020         * platform/graphics/svg/cg/CgSupport.h:
3021         * platform/graphics/svg/filters/SVGDistantLightSource.h:
3022         * platform/graphics/svg/filters/SVGFEBlend.h:
3023         * platform/graphics/svg/filters/SVGFEColorMatrix.h:
3024         * platform/graphics/svg/filters/SVGFEComponentTransfer.h:
3025         * platform/graphics/svg/filters/SVGFEComposite.h:
3026         * platform/graphics/svg/filters/SVGFEConvolveMatrix.h:
3027         * platform/graphics/svg/filters/SVGFEDiffuseLighting.h:
3028         * platform/graphics/svg/filters/SVGFEDisplacementMap.h:
3029         * platform/graphics/svg/filters/SVGFEFlood.h:
3030         * platform/graphics/svg/filters/SVGFEGaussianBlur.h:
3031         * platform/graphics/svg/filters/SVGFEImage.h:
3032         * platform/graphics/svg/filters/SVGFEMerge.h:
3033         * platform/graphics/svg/filters/SVGFEMorphology.h:
3034         * platform/graphics/svg/filters/SVGFEOffset.h:
3035         * platform/graphics/svg/filters/SVGFESpecularLighting.h:
3036         * platform/graphics/svg/filters/SVGFETile.h:
3037         * platform/graphics/svg/filters/SVGFETurbulence.h:
3038         * platform/graphics/svg/filters/SVGFilterEffect.h:
3039         * platform/graphics/svg/filters/SVGLightSource.h:
3040         * platform/graphics/svg/filters/SVGPointLightSource.h:
3041         * platform/graphics/svg/filters/SVGSpotLightSource.h:
3042         * platform/mac/FontPlatformData.h:
3043         * platform/mac/PlatformScrollBar.h:
3044         * platform/network/AuthenticationChallenge.h:
3045         * platform/network/Credential.h:
3046         * platform/network/HTTPHeaderMap.h:
3047         * platform/network/ProtectionSpace.h:
3048         * platform/network/ResourceError.h:
3049         * platform/network/ResourceRequest.h:
3050         * platform/network/ResourceResponse.h:
3051         * platform/network/cf/FormDataStreamCFNet.h:
3052         * platform/network/cf/ResourceRequestCFNet.h:
3053         * platform/network/cf/ResourceResponseCFNet.h:
3054         * platform/network/gdk/ResourceHandleManager.h:
3055         * platform/network/mac/AuthenticationMac.h:
3056         * platform/network/mac/FormDataStreamMac.h:
3057         * platform/network/qt/ResourceHandleManagerKDE.h:
3058         * platform/network/qt/ResourceHandleManagerQt.h:
3059         * platform/network/win/ResourceHandleWin.h:
3060         * platform/qt/FontPlatformData.h:
3061         * platform/qt/KeyboardCodes.h:
3062         * platform/qt/PlatformScrollBar.h:
3063         * platform/qt/ScrollViewCanvasQt.h:
3064         * platform/qt/SharedTimerQt.h:
3065         * platform/win/FontPlatformData.h:
3066         * platform/win/PlatformScrollBar.h:
3067         * rendering/AutoTableLayout.h:
3068         * rendering/HitTestRequest.h:
3069         * rendering/HitTestResult.h:
3070         * rendering/InlineBox.h:
3071         * rendering/InlineFlowBox.h:
3072         * rendering/Length.h:
3073         * rendering/ListMarkerBox.h:
3074         * rendering/RenderBox.h:
3075         * rendering/RenderMenuList.h:
3076         * rendering/RenderPart.h:
3077         * rendering/RenderPartObject.h:
3078         * rendering/RenderPath.h:
3079         * rendering/RenderReplaced.h:
3080         * rendering/RenderSVGContainer.h:
3081         * rendering/RenderSVGImage.h:
3082         * rendering/RenderSVGInline.h:
3083         * rendering/RenderSVGInlineText.h:
3084         * rendering/RenderSVGTSpan.h:
3085         * rendering/RenderSVGText.h:
3086         * rendering/RenderStyle.h:
3087         * rendering/RenderTableCol.h:
3088         * rendering/RenderThemeWin.h:
3089         * rendering/bidi.h:
3090         * xml/DOMParser.h:
3091         * xml/XPathEvaluator.h:
3092         * xml/XPathExpression.h:
3093         * xml/XPathExpressionNode.h:
3094         * xml/XPathFunctions.h:
3095         * xml/XPathNSResolver.h:
3096         * xml/XPathNamespace.h:
3097         * xml/XPathParser.h:
3098         * xml/XPathPath.h:
3099         * xml/XPathPredicate.h:
3100         * xml/XPathResult.h:
3101         * xml/XPathStep.h:
3102         * xml/XPathUtil.h:
3103         * xml/XPathValue.h:
3104         * xml/XPathVariableReference.h:
3105         * xml/XSLImportRule.h:
3106         * xml/XSLStyleSheet.h:
3107         * xml/XSLTProcessor.h:
3108         * xml/xmlhttprequest.h:
3109
3110 2007-01-15  Anders Carlsson  <acarlsson@apple.com>
3111
3112         Build fix.
3113         
3114         * loader/ProgressTracker.cpp:
3115
3116 2007-01-15  Lars Knoll <lars@trolltech.com>
3117
3118         Fix the Qt build
3119
3120         * WebCore.pro:
3121
3122 2007-01-15  Anders Carlsson  <acarlsson@apple.com>
3123
3124         Reviewed by Darin.
3125
3126         * loader/ProgressTracker.cpp:
3127         Set finalProgressValue to its value explicitly instead of calculating it 
3128         (which causes a global initializer to be generated).
3129
3130 2007-01-15  Anders Carlsson  <acarlsson@apple.com>
3131
3132         Reviewed by Darin and Adam.
3133
3134         Move progress tracking down to WebCore.
3135         
3136         * WebCore.exp:
3137         Add ProgressTracker::estimatedProgress() to be used by WebKit.
3138         
3139         * WebCore.xcodeproj/project.pbxproj:
3140         Add ProgressTracker.[cpp|h]
3141         
3142         * loader/FrameLoader.cpp:
3143         (WebCore::FrameLoader::prepareForLoadStart):
3144         (WebCore::FrameLoader::clearProvisionalLoad):
3145         (WebCore::FrameLoader::checkLoadCompleteForThisFrame):
3146         (WebCore::FrameLoader::startLoading):
3147         (WebCore::FrameLoader::didReceiveResponse):
3148         (WebCore::FrameLoader::didReceiveData):
3149         (WebCore::FrameLoader::didFailToLoad):
3150         (WebCore::FrameLoader::requestFromDelegate):
3151         (WebCore::FrameLoader::didFinishLoad):
3152         Call directly to the progress tracker instead of through the frame loader client.
3153         
3154         * loader/FrameLoaderClient.h:
3155         Get rid of the old methods and add new methods for tracking progress.
3156         
3157         * loader/ProgressTracker.cpp: Added.
3158         (WebCore::ProgressItem::ProgressItem):
3159         (WebCore::ProgressTracker::ProgressTracker):
3160         (WebCore::ProgressTracker::~ProgressTracker):
3161         (WebCore::ProgressTracker::estimatedProgress):
3162         (WebCore::ProgressTracker::reset):
3163         (WebCore::ProgressTracker::progressStarted):
3164         (WebCore::ProgressTracker::progressCompleted):
3165         (WebCore::ProgressTracker::finalProgressComplete):
3166         (WebCore::ProgressTracker::incrementProgress):
3167         (WebCore::ProgressTracker::completeProgress):
3168         (WebCore::ProgressTracker::createUniqueIdentifier):
3169         * loader/ProgressTracker.h: Added.
3170         New per page class which tracks progress.
3171         
3172         * loader/ResourceLoader.cpp:
3173         (WebCore::ResourceLoader::willSendRequest):
3174         * page/Page.cpp:
3175         (WebCore::Page::Page):
3176         * page/Page.h:
3177         (WebCore::Page::progress):
3178         Move createUniqueIdentifier to ProgressTracker, add ProgressTracker object to Page.
3179         
3180         * platform/graphics/svg/SVGImageEmptyClients.h:
3181         (WebCore::SVGEmptyFrameLoaderClient::willChangeEstimatedProgress):
3182         (WebCore::SVGEmptyFrameLoaderClient::didChangeEstimatedProgress):
3183         (WebCore::SVGEmptyFrameLoaderClient::postProgressStartedNotification):
3184         (WebCore::SVGEmptyFrameLoaderClient::postProgressEstimateChangedNotification):
3185         (WebCore::SVGEmptyFrameLoaderClient::postProgressFinishedNotification):
3186         Add new methods, get rid of the old ones.
3187
3188 2007-01-15  Adam Roben  <aroben@apple.com>
3189
3190         Reviewed by Anders.
3191
3192         Fix comment.
3193
3194         * html/HTMLScriptElement.cpp:
3195         (WebCore::HTMLScriptElement::shouldExecuteAsJavaScript):
3196
3197 2007-01-15  John Sullivan  <sullivan@apple.com>
3198
3199         * platform/ContextMenu.cpp:
3200         (WebCore::ContextMenu::checkOrEnableIfNeeded):
3201         Leopard build fix; don't declare one of the case values twice
3202
3203 2007-01-15  Mitz Pettel  <mitz@webkit.org>
3204
3205         Reviewed by Darin.
3206
3207         - fix http://bugs.webkit.org/show_bug.cgi?id=8604
3208           rowspan does not work when set through javascript
3209
3210         Covered by existing tests.
3211
3212         * rendering/RenderTableCell.cpp:
3213         (WebCore::RenderTableCell::updateFromElement): Mark the section for grid recalc
3214         if row span or column span change.
3215
3216 2007-01-15  Adam Roben  <aroben@apple.com>
3217
3218         Reviewed by Darin.
3219
3220         Small context menu fixes.
3221
3222         * platform/ContextMenu.cpp:
3223         (WebCore::ContextMenu::populate): Fix typo.
3224         (WebCore::ContextMenu::checkOrEnableIfNeeded): Disabled "No Guesses
3225         Found", and added all enum values explicitly.
3226
3227 2007-01-15  Alexey Proskuryakov  <ap@webkit.org>
3228
3229         Reviewed by Darin.
3230
3231         http://bugs.webkit.org/show_bug.cgi?id=6272
3232         XMLHttpRequest freezes on getting a missing document with overridden Content-Length
3233
3234         http://bugs.webkit.org/show_bug.cgi?id=6212
3235         Investigate disallowing some XMLHttpRequest headers from being set via setRequestHeader.
3236
3237         Tests:
3238         - http/tests/xmlhttprequest/connection-error-sync.html
3239         - http/tests/xmlhttprequest/set-dangerous-headers.html
3240
3241         * bindings/js/kjs_binding.cpp:
3242         (KJS::):
3243         (KJS::setDOMException): Added support for NETWORK_ERR. Changed the temporary 
3244         PERMISSION_DENIED error into a special case.
3245
3246         * loader/FrameLoader.cpp:
3247         (WebCore::FrameLoader::loadResourceSynchronously):
3248         * loader/FrameLoader.h:
3249         Return the error object to the caller. Removed an extra local variable for error, 
3250         which shadowed the one from enclosing block.
3251
3252         * dom/XMLTokenizer.cpp:
3253         (WebCore::openFunc): 
3254         * xml/XSLTProcessor.cpp:
3255         (WebCore::docLoaderFunc): 
3256         Updated to pass an error object (currently ignored).
3257
3258         * xml/xmlhttprequest.cpp:
3259         (WebCore::canSetRequestHeader): Added. The headers to block include the ones from 
3260         the current XMLHttpRequest draft plus "Via", which is blocked by Firefox.
3261         (WebCore::XMLHttpRequest::send): Raise an exception if a sync request results in 
3262         an error.
3263         (WebCore::XMLHttpRequest::setRequestHeader): Call canSetRequestHeader().
3264         * xml/xmlhttprequest.h:
3265         (WebCore::): Added NETWORK_ERR and a comment about PERMISSION_DENIED.
3266
3267 2007-01-15  Zack Rusin  <zack@kde.org>
3268
3269         Optimizing rendering on the Qt platform. Mainly
3270         switching from client side QImage to QPixmap's.
3271         Also cleaning the the ScrollViewCanvasQt code
3272         quite a bit.
3273
3274         * platform/graphics/ImageSource.h: use QPixmap
3275         * platform/graphics/qt/GraphicsContextQt.cpp:
3276         (WebCore::TransparencyLayer::TransparencyLayer):
3277         (WebCore::GraphicsContext::clip): clip rects when you can
3278         * platform/graphics/qt/ImageDecoderQt.cpp:
3279         (WebCore::ImageDecoderQt::ImageData::ImageData):
3280         (WebCore::ImageDecoderQt::ReadContext::read):
3281         (WebCore::ImageDecoderQt::ReadContext::readImageLines):
3282         (WebCore::ImageDecoderQt::imageAtIndex):
3283         * platform/graphics/qt/ImageDecoderQt.h: use QPixmap
3284         * platform/graphics/qt/ImageQt.cpp: QPixmap instead of QImage
3285         (WebCore::BitmapImage::draw):
3286         (WebCore::BitmapImage::drawTiled):
3287         * platform/graphics/qt/ImageSourceQt.cpp:
3288         (WebCore::):
3289         (WebCore::ImageSource::createFrameAtIndex):
3290         (WebCore::ImageSource::frameHasAlphaAtIndex):
3291         * platform/qt/ScrollViewCanvasQt.cpp: clean up
3292         (WebCore::ScrollViewCanvasQt::ScrollViewCanvasQt):
3293         (WebCore::ScrollViewCanvasQt::updateFrameView):
3294         (WebCore::ScrollViewCanvasQt::paintEvent):
3295         (WebCore::ScrollViewCanvasQt::mouseMoveEvent):
3296         (WebCore::ScrollViewCanvasQt::mousePressEvent):
3297         (WebCore::ScrollViewCanvasQt::mouseReleaseEvent):
3298         (WebCore::ScrollViewCanvasQt::handleKeyEvent):
3299         * platform/qt/ScrollViewCanvasQt.h:
3300         * platform/qt/ScrollViewQt.cpp: remove hacks
3301         (WebCore::ScrollView::ScrollView):
3302         (WebCore::ScrollView::setParentWidget):
3303         (WebCore::ScrollView::updateContents):
3304
3305 2007-01-15  Lars Knoll <lars@trolltech.com>
3306
3307         Reviewed by Zack
3308
3309         Fix weird crashes when running the layout tests. The
3310         reason was that I used KURL (and thus DeprecatedString)
3311         in a thread. Unfortunately that class is not threadsafe
3312         at all.
3313
3314         * platform/network/qt/ResourceHandleManagerQt.cpp:
3315         (WebCore::RequestQt::RequestQt):
3316         (WebCore::RequestQt::setURL):
3317         (WebCore::ResourceHandleManager::add):
3318         (WebCore::ResourceHandleManager::cancel):
3319         (WebCore::ResourceHandleManager::receivedResponse):
3320         (WebCore::FileLoader::request):
3321         (WebCore::HostInfo::HostInfo):
3322         (WebCore::NetworkLoader::request):
3323         (WebCore::NetworkLoader::cancel):
3324         * platform/network/qt/ResourceHandleManagerQt.h:
3325         (WebCore::HostInfo::HostInfo):
3326         (WebCore::HostInfo::isLocalFile):
3327
3328 2007-01-15  Eric Seidel  <eric@webkit.org>
3329
3330         Reviewed by rwlbuis.
3331
3332         Make isValid check not malloc 3 SVGStringLists for every element.
3333         
3334         No test possible, performance fix only.
3335
3336         * ksvg2/svg/SVGTests.cpp:
3337         (WebCore::SVGTests::isValid):
3338
3339 2007-01-15  Rob Buis  <buis@kde.org>
3340
3341         Reviewed by Eric.
3342
3343         Remove unused member var.
3344
3345         * ksvg2/svg/SVGStyledElement.h:
3346
3347 2007-01-15  Rob Buis  <buis@kde.org>
3348
3349         Reviewed by Eric.
3350
3351         http://bugs.webkit.org/show_bug.cgi?id=12069
3352         Hit detection fails under some viewbox constraints
3353
3354         Do not take viewBox into account when hit testing svg container.
3355
3356         * rendering/RenderSVGContainer.cpp:
3357         (WebCore::RenderSVGContainer::nodeAtPoint):
3358
3359 2007-01-15  David Hyatt  <hyatt@apple.com>
3360
3361         Fix  for 12275, negative margins confuse page breaks.
3362
3363         Reviewed by Eric
3364
3365         * rendering/RenderBlock.cpp:
3366         (WebCore::RenderBlock::paintChildren):
3367
3368 2007-01-15  Eric Seidel  <eric@webkit.org>
3369
3370         Reviewed by mjs.
3371         
3372         SVG gradients do not notice stop additions
3373         http://bugs.webkit.org/show_bug.cgi?id=12192
3374
3375         Test: svg/custom/gradient-add-stops.svg
3376
3377         * ksvg2/svg/SVGGradientElement.cpp:
3378         (WebCore::SVGGradientElement::childrenChanged):
3379         * ksvg2/svg/SVGGradientElement.h:
3380
3381 2007-01-14  David Hyatt  <hyatt@apple.com>
3382
3383         Fix for bug 10356, positioning doesn't work with <svg> elements in XHTML.  Change the requiresLayer
3384         check to use the DOM, since the old check would fail if the parent block had no element.
3385
3386         Reviewed by Eric
3387
3388         Added svg/custom/relative-positioning.html (absolute/fixed too)
3389
3390         * rendering/RenderSVGContainer.cpp:
3391         (WebCore::RenderSVGContainer::requiresLayer):
3392
3393 2007-01-14  Eric Seidel  <eric@webkit.org>
3394
3395         Reviewed by hyatt.
3396         
3397         SVG does not correctly handle float: left
3398         http://bugs.webkit.org/show_bug.cgi?id=12210
3399
3400         Test: svg/custom/svg-float-border-padding.xml
3401
3402         * rendering/RenderSVGContainer.cpp:
3403         (WebCore::RenderSVGContainer::paint):
3404
3405 2007-01-14  David Hyatt  <hyatt@apple.com>
3406
3407         More work to fix 10145, regression where form elements don't break properly.  Make sure to really use
3408         the parent of the replaced element's whitespace value everywhere.
3409
3410         Reviewed by olliej
3411
3412         fast/replaced/three-selects-break.html
3413
3414         * rendering/bidi.cpp:
3415         (WebCore::RenderBlock::findNextLineBreak):
3416
3417 2007-01-14  Sam Weinig  <sam@webkit.org>
3418
3419         Reviewed by Darin and then by Mitz.
3420
3421         Patch for http://bugs.webkit.org/show_bug.cgi?id=12228
3422         Cleanup assorted CSS classes
3423
3424         * css/CSSBorderImageValue.cpp:
3425         (WebCore::CSSBorderImageValue::CSSBorderImageValue):
3426         (WebCore::CSSBorderImageValue::cssText):
3427         * css/CSSBorderImageValue.h:
3428         * css/CSSComputedStyleDeclaration.cpp:
3429         (WebCore::valueForLength):
3430         (WebCore::valueForBorderStyle):
3431         (WebCore::valueForTextAlign):
3432         (WebCore::valueForShadow):
3433         (WebCore::getPositionOffsetValue):
3434         (WebCore::CSSComputedStyleDeclaration::cssText):
3435         (WebCore::primitiveValueFromLength):
3436         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3437         (WebCore::CSSComputedStyleDeclaration::getPropertyPriority):
3438         (WebCore::CSSComputedStyleDeclaration::removeProperty):
3439         (WebCore::CSSComputedStyleDeclaration::setProperty):
3440         (WebCore::CSSComputedStyleDeclaration::length):
3441         (WebCore::CSSComputedStyleDeclaration::item):
3442         * css/CSSComputedStyleDeclaration.h:
3443         * css/CSSCursorImageValue.cpp:
3444         (WebCore::CSSCursorImageValue::CSSCursorImageValue):
3445         * css/CSSCursorImageValue.h:
3446         * css/CSSGrammar.y:
3447         * css/CSSImageValue.cpp:
3448         * css/CSSImageValue.h:
3449         * css/CSSInheritedValue.cpp:
3450         * css/CSSInheritedValue.h:
3451         * css/CSSInitialValue.cpp:
3452         * css/CSSInitialValue.h:
3453         * css/CSSMutableStyleDeclaration.cpp:
3454         (WebCore::CSSMutableStyleDeclaration::CSSMutableStyleDeclaration):
3455         (WebCore::CSSMutableStyleDeclaration::operator=):
3456         (WebCore::CSSMutableStyleDeclaration::getPropertyValue):
3457         (WebCore::CSSMutableStyleDeclaration::get4Values):
3458         (WebCore::CSSMutableStyleDeclaration::getShorthandValue):
3459         (WebCore::CSSMutableStyleDeclaration::getPropertyCSSValue):
3460         (WebCore::CSSMutableStyleDeclaration::removeProperty):
3461         (WebCore::CSSMutableStyleDeclaration::setChanged):
3462         (WebCore::CSSMutableStyleDeclaration::getPropertyPriority):
3463         (WebCore::CSSMutableStyleDeclaration::getPropertyShorthand):
3464         (WebCore::CSSMutableStyleDeclaration::isPropertyImplicit):
3465         (WebCore::CSSMutableStyleDeclaration::setProperty):
3466         (WebCore::CSSMutableStyleDeclaration::setImageProperty):
3467         (WebCore::CSSMutableStyleDeclaration::parseDeclaration):
3468         (WebCore::CSSMutableStyleDeclaration::addParsedProperties):
3469         (WebCore::CSSMutableStyleDeclaration::setLengthProperty):
3470         (WebCore::CSSMutableStyleDeclaration::cssText):
3471         (WebCore::CSSMutableStyleDeclaration::merge):
3472         (WebCore::CSSMutableStyleDeclaration::removePropertiesInSet):
3473         * css/CSSMutableStyleDeclaration.h:
3474         (WebCore::CSSMutableStyleDeclaration::setProperty):
3475         (WebCore::CSSMutableStyleDeclaration::removeProperty):
3476         * css/CSSNamespace.h:
3477         (WebCore::CSSNamespace::CSSNamespace):
3478         * css/CSSPrimitiveValue.cpp:
3479         (WebCore::isCSSTokenizerIdentifier):
3480         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
3481         (WebCore::CSSPrimitiveValue::cleanup):
3482         (WebCore::CSSPrimitiveValue::computeLengthInt):
3483         (WebCore::CSSPrimitiveValue::computeLengthIntForLength):
3484         (WebCore::CSSPrimitiveValue::computeLengthShort):
3485         (WebCore::CSSPrimitiveValue::computeLengthFloat):
3486         (WebCore::CSSPrimitiveValue::setFloatValue):
3487         (WebCore::scaleFactorForConversion):
3488         (WebCore::CSSPrimitiveValue::getFloatValue):
3489         (WebCore::CSSPrimitiveValue::setStringValue):
3490         (WebCore::CSSPrimitiveValue::getStringValue):
3491         (WebCore::CSSPrimitiveValue::parseString):
3492         (WebCore::CSSPrimitiveValue::getIdent):
3493         (WebCore::CSSPrimitiveValue::cssText):
3494         * css/CSSPrimitiveValue.h:
3495         (WebCore::CSSPrimitiveValue::getCounterValue):
3496         (WebCore::CSSPrimitiveValue::getRectValue):
3497         (WebCore::CSSPrimitiveValue::getRGBColorValue):
3498         (WebCore::CSSPrimitiveValue::getPairValue):
3499         (WebCore::CSSPrimitiveValue::getDashboardRegionValue):
3500         * css/CSSProperty.cpp:
3501         (WebCore::operator==):
3502         * css/CSSProperty.h:
3503         (WebCore::CSSProperty::operator=):
3504         * css/CSSQuirkPrimitiveValue.h:
3505         (WebCore::CSSQuirkPrimitiveValue::CSSQuirkPrimitiveValue):
3506         * css/CSSRuleList.cpp:
3507         (WebCore::CSSRuleList::CSSRuleList):
3508         (WebCore::CSSRuleList::deleteRule):
3509         (WebCore::CSSRuleList::insertRule):
3510         * css/CSSRuleList.h:
3511         (WebCore::CSSRuleList::item):
3512         * css/CSSSelector.cpp:
3513         (WebCore::CSSSelector::print):
3514         (WebCore::CSSSelector::specificity):
3515         (WebCore::CSSSelector::extractPseudoType):
3516         (WebCore::CSSSelector::operator==):
3517         (WebCore::CSSSelector::selectorText):
3518         * css/CSSSelector.h:
3519         (WebCore::CSSSelector::CSSSelector):
3520         (WebCore::CSSSelector::~CSSSelector):
3521         (WebCore::CSSSelector::append):
3522         (WebCore::CSSSelector::next):
3523         (WebCore::CSSSelector::pseudoType):
3524         (WebCore::CSSSelector::hasTag):
3525         (WebCore::CSSSelector::hasAttribute):
3526         * css/CSSStyleDeclaration.cpp:
3527         (WebCore::propertyID):
3528         (WebCore::CSSStyleDeclaration::getPropertyPriority):
3529         (WebCore::CSSStyleDeclaration::getPropertyShorthand):
3530         (WebCore::CSSStyleDeclaration::isPropertyImplicit):
3531         (WebCore::CSSStyleDeclaration::setProperty):
3532         (WebCore::CSSStyleDeclaration::isPropertyName):
3533         (WebCore::CSSStyleDeclaration::parentRule):
3534         (WebCore::CSSStyleDeclaration::diff):
3535         (WebCore::CSSStyleDeclaration::copyPropertiesInSet):
3536         * css/CSSStyleDeclaration.h:
3537         * css/Counter.h:
3538         (WebCore::Counter::Counter):
3539         (WebCore::Counter::listStyleNumber):
3540         * css/csshelper.cpp:
3541         (WebCore::parseURL):
3542         * css/csshelper.h:
3543         * css/cssparser.h:
3544         (WebCore::domString):
3545         (WebCore::atomicString):
3546         (WebCore::CSSParser::operator|):
3547         * css/cssstyleselector.cpp:
3548         (WebCore::CSSStyleSelector::matchRulesForList):
3549         (WebCore::CSSStyleSelector::checkSelector):
3550         (WebCore::CSSStyleSelector::checkOneSelector):
3551         (WebCore::CSSRuleSet::addRule):
3552
3553 2007-01-14  Mitz Pettel  <mitz@webkit.org>
3554
3555         Reviewed by Adam.
3556
3557         - fix http://bugs.webkit.org/show_bug.cgi?id=12264
3558           REGRESSION (r18843): Webkit crashes on 43Folders.com home page
3559
3560         Test: fast/tokenizer/ignore-tags-in-iframe.html
3561
3562         * html/HTMLParser.cpp:
3563         (WebCore::HTMLParser::reset): Removed unused inSelect member variable.
3564         (WebCore::HTMLParser::selectCreateErrorCheck): Ditto.
3565         (WebCore::HTMLParser::processCloseTag): Ditto.
3566         * html/HTMLParser.h: Ditto.
3567         * html/HTMLTokenizer.cpp:
3568         (WebCore::HTMLTokenizer::parseTag): Changed not to process <pre>, <listing>,
3569         <script>, <style>, <title>, <textarea> and <xmp> if the parser is in skip mode
3570         (waiting for a close tag of an element whose contents are not parsed,
3571         such as iframe).
3572         * html/HTMLTokenizer.h:
3573         (WebCore::HTMLTokenizer::State::setInStyle): Removed unused bit.
3574         (WebCore::HTMLTokenizer::State::): Ditto.
3575
3576 2007-01-14  Alexey Proskuryakov  <ap@webkit.org>
3577
3578         Reviewed by Darin.
3579
3580         http://bugs.webkit.org/show_bug.cgi?id=12258
3581         fast/tokenizer/002 test broken
3582
3583         * loader/FrameLoader.h: Added a flush parameter to write().
3584         * loader/FrameLoader.cpp:
3585         (WebCore::FrameLoader::write): Ditto.
3586         (WebCore::FrameLoader::endIfNotLoading): Instead of poorly duplicating the logic in write(),
3587         call it directly.
3588
3589 2007-01-14  Adam Roben  <aroben@apple.com>
3590
3591         Reviewed by Maciej.
3592
3593         Make sure our whitelisting of the type and language attributes of the
3594         <script> element is enforced in all HTMLTokenizer/HTMLScriptElement
3595         code paths.
3596
3597         All layout tests pass.
3598
3599         * html/HTMLScriptElement.cpp:
3600         (WebCore::HTMLScriptElement::shouldExecuteAsJavaScript): New method to
3601         determine whether the script should be executed, given its type and
3602         language attributes.
3603         (WebCore::HTMLScriptElement::evaluateScript): Check type/language
3604         before executing.
3605         * html/HTMLScriptElement.h: Added new declarations.
3606         * html/HTMLTokenizer.cpp:
3607         (WebCore::HTMLTokenizer::begin): Made scriptSrc a String. 
3608         (WebCore::HTMLTokenizer::scriptHandler): Check
3609         shouldExecuteAsJavaScript before executing.
3610         (WebCore::HTMLTokenizer::notifyFinished): Ditto.
3611         (WebCore::HTMLTokenizer::parseTag): Moved type/language checking from
3612         here to HTMLScriptElement::shouldExecuteAsJavaScript.
3613         * html/HTMLTokenizer.h: Made scriptSrc a String, and removed the
3614         javascript member.
3615
3616 2007-01-14  David Hyatt  <hyatt@apple.com>
3617
3618         Make sure floats are avoided if you have non-auto column property values.  Fixes the crazy layout
3619         on http://weblogs.mozillazine.org/roc.
3620
3621         Reviewed by mitz
3622
3623         Added fast/multicol/float-avoidance.html
3624
3625         * rendering/RenderBlock.cpp:
3626         (WebCore::RenderBlock::avoidsFloats):
3627
3628 2007-01-14  David Hyatt  <hyatt@apple.com>
3629
3630         Fix for 10145, regression where line breaks are not being honored between adjacent replaced elements.
3631         When checking for break opportunities where replaced elements are involved, we ignore their white-space
3632         values and use their parents' instead.  The assumption/idea behind this change is that because the element
3633         is replaced, its white-space value is irrelevant except as a means of applying style to its interior.
3634
3635         The CSS spec does not cover this situation, so we're implementing this based off what other browsers seem to
3636         do.
3637
3638         Reviewed by aroben
3639
3640         * css/CSSComputedStyleDeclaration.cpp:
3641         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3642         * css/CSSValueKeywords.in:
3643         * css/cssparser.cpp:
3644         (WebCore::CSSParser::parseValue):
3645         * css/cssstyleselector.cpp:
3646         (WebCore::CSSStyleSelector::applyProperty):
3647         * page/EventHandler.cpp:
3648         (WebCore::EventHandler::EventHandler):
3649         (WebCore::EventHandler::clear):
3650         (WebCore::EventHandler::handleWheelEvent):
3651         * page/EventHandler.h:
3652         * rendering/RenderBox.cpp:
3653         (WebCore::RenderBox::calcHeight):
3654         * rendering/RenderLayer.cpp:
3655         (WebCore::Marquee::Marquee):
3656         (WebCore::Marquee::start):
3657         (WebCore::Marquee::updateMarqueePosition):
3658         (WebCore::Marquee::updateMarqueeStyle):
3659         (WebCore::Marquee::timerFired):
3660         * rendering/RenderLayer.h:
3661         * rendering/RenderPartObject.cpp:
3662         (WebCore::RenderPartObject::viewCleared):
3663         * rendering/RenderStyle.h:
3664         (WebCore::):
3665         * rendering/bidi.cpp:
3666         (WebCore::RenderBlock::findNextLineBreak):
3667
3668 2007-01-13  David Hyatt  <hyatt@apple.com>
3669
3670         While optimizing form controls and fixing their clipping, I caused this text zoom regression.  The layout
3671         of text is necessary because it needs to recalc minmaxwidth.  This is still a really unfortunate
3672         bit of code... since a lot of properties don't apply to text (e.g., borders), we're marking text renderers
3673         as dirty when we don't have to.
3674
3675         Reviewed by mitz
3676
3677         * rendering/RenderObject.cpp:
3678         (WebCore::RenderObject::setStyle):
3679
3680 2007-01-13  Lars Knoll <lars@trolltech.com>
3681
3682         Reviewed by Alexey
3683
3684         String::format() was relying on undefined behaviour, which
3685         happened to work on lots of systems (Mac and 32bit Linux at least)
3686         but broke badly on 64bit Linux.
3687         
3688         * platform/String.cpp:
3689         (WebCore::String::format):
3690
3691 2007-01-13  Martin Reddy  <reddy@pixar.com>
3692
3693         Fix for bug 11924: WebCore would crash on any HTML content
3694         with a non-empty <table> tag in it on a 64-bit machine. The
3695         size_t (64bit) vs int (32bit) cast is now fixed in ensureRows,
3696         and the clients of this function have been updated to check
3697         for a false return code.
3698
3699         Reviewed by Darin, landed by Lars
3700
3701         * rendering/RenderTableSection.cpp:
3702         (WebCore::RenderTableSection::addChild):
3703         (WebCore::RenderTableSection::ensureRows):
3704         (WebCore::RenderTableSection::recalcCells):
3705
3706 2007-01-13  Alexey Proskuryakov  <ap@webkit.org>
3707
3708         Reviewed by Darin.
3709
3710         http://bugs.webkit.org/show_bug.cgi?id=12165
3711         REGRESSION: text encoding problem at jn.sapo.pt
3712
3713         Test: fast/encoding/script-in-head.html
3714
3715         * loader/TextResourceDecoder.cpp:
3716         (WebCore::TextResourceDecoder::checkForHeadCharset):
3717         Ignore tags within <script> elements in head, just like we do for <title>.
3718
3719 2007-01-13  Lars Knoll <lars@trolltech.com>
3720
3721         Reviewed by Maciej
3722
3723         Don't crash when constructing a GraphicsContext with a 0
3724         PlatformGraphicsContext and don't do anything if painting
3725         is disabled.
3726
3727         * platform/graphics/qt/GraphicsContextQt.cpp:
3728         (WebCore::GraphicsContextPlatformPrivate::GraphicsContextPlatformPrivate):
3729         (WebCore::GraphicsContext::origin):
3730         (WebCore::GraphicsContext::setPlatformFont):
3731         (WebCore::GraphicsContext::setPlatformStrokeColor):
3732         (WebCore::GraphicsContext::setPlatformStrokeStyle):
3733         (WebCore::GraphicsContext::setPlatformStrokeThickness):
3734         (WebCore::GraphicsContext::setPlatformFillColor):
3735
3736 2007-01-13  Eric Seidel  <eric@webkit.org>
3737
3738         Reviewed by hyatt.
3739
3740         RichDraw demo does not live-update in Safari
3741         (SVG elements should ignore CSS position)
3742         http://bugs.webkit.org/show_bug.cgi?id=10364
3743
3744         * css/cssstyleselector.cpp:
3745         (WebCore::CSSStyleSelector::adjustRenderStyle): ignore position for everything but <svg>
3746         * ksvg2/svg/SVGStyledElement.cpp:
3747         (WebCore::SVGStyledElement::rebuildRenderer): move path generation into layout()
3748         * rendering/RenderContainer.cpp:
3749         (WebCore::RenderContainer::layout): ASSERT kids marked as having completed layout
3750         * rendering/RenderPath.cpp:
3751         (WebCore::RenderPath::layout): move path generation into layout()
3752         * rendering/RenderSVGContainer.cpp:
3753         (WebCore::RenderSVGContainer::layout): ASSERT kids marked as having completed layout
3754
3755 2007-01-12  David Hyatt  <hyatt@apple.com>
3756
3757         Add support for column rules.
3758
3759         Reviewed by bdash
3760
3761         fast/multicol/column-rules.html
3762
3763         * rendering/RenderBlock.cpp:
3764         (WebCore::RenderBlock::paintColumns):
3765         * rendering/RenderStyle.h:
3766         (WebCore::RenderStyle::columnRuleIsTransparent):
3767
3768 2007-01-12  David Hyatt  <hyatt@apple.com>
3769
3770         Make multicolumn layout work with floats.
3771
3772         Reviewed by andersca
3773
3774         Added fast/multicol/float-multicol.html
3775
3776         * rendering/RenderBlock.cpp:
3777         (WebCore::RenderBlock::layoutBlock):
3778         (WebCore::RenderBlock::paintColumns):
3779         (WebCore::RenderBlock::paintObject):
3780         * rendering/RenderBlock.h:
3781
3782 2007-01-12  David Kilzer  <ddkilzer@kilzer.net>
3783
3784         Reviewed by Maciej.
3785
3786         - fix http://bugs.webkit.org/show_bug.cgi?id=12239
3787           REGRESSION (r18816-r18818): Assertion failure in 
3788           WebCore::Length::Length[in-charge](int, WebCore::LengthType, bool)
3789
3790         Test: fast/css/line-height.html
3791
3792         * rendering/RenderTextControl.cpp:
3793         (WebCore::RenderTextControl::createInnerTextStyle): Use a float to create a percent Length.
3794
3795 2007-01-12  Anders Carlsson  <acarlsson@apple.com>
3796
3797         Reviewed by Darin.
3798
3799         Use unsigned long for identifiers instead of Objective-C objects.
3800         
3801         * loader/FrameLoader.cpp:
3802         (WebCore::FrameLoader::loadResourceSynchronously):
3803         (WebCore::FrameLoader::startLoadingMainResource):
3804         (WebCore::FrameLoader::startLoading):
3805         (WebCore::FrameLoader::assignIdentifierToInitialRequest):
3806         (WebCore::FrameLoader::opened):
3807         (WebCore::FrameLoader::sendRemainingDelegateMessages):
3808         (WebCore::FrameLoader::requestFromDelegate):
3809         (WebCore::FrameLoader::loadedResourceFromMemoryCache):
3810         * loader/FrameLoader.h:
3811         * loader/FrameLoaderClient.h:
3812         * loader/ResourceLoader.cpp:
3813         (WebCore::ResourceLoader::ResourceLoader):
3814         (WebCore::ResourceLoader::willSendRequest):
3815         * loader/ResourceLoader.h:
3816         (WebCore::ResourceLoader::setIdentifier):
3817         (WebCore::ResourceLoader::identifier):
3818         * page/Page.cpp:
3819         (WebCore::Page::Page):
3820         (WebCore::Page::createUniqueIdentifier):
3821         * page/Page.h:
3822         * platform/graphics/svg/SVGImageEmptyClients.h:
3823         (WebCore::SVGEmptyFrameLoaderClient::assignIdentifierToInitialRequest):
3824         (WebCore::SVGEmptyFrameLoaderClient::dispatchWillSendRequest):
3825         (WebCore::SVGEmptyFrameLoaderClient::dispatchDidReceiveAuthenticationChallenge):
3826         (WebCore::SVGEmptyFrameLoaderClient::dispatchDidCancelAuthenticationChallenge):
3827         (WebCore::SVGEmptyFrameLoaderClient::dispatchDidReceiveResponse):
3828         (WebCore::SVGEmptyFrameLoaderClient::dispatchDidReceiveContentLength):
3829         (WebCore::SVGEmptyFrameLoaderClient::dispatchDidFinishLoading):
3830         (WebCore::SVGEmptyFrameLoaderClient::dispatchDidFailLoading):
3831         (WebCore::SVGEmptyFrameLoaderClient::incrementProgress):
3832         (WebCore::SVGEmptyFrameLoaderClient::completeProgress):
3833
3834 2007-01-12  Mitz Pettel  <mitz@webkit.org>
3835
3836         Reviewed by Darin.
3837
3838         - fix http://bugs.webkit.org/show_bug.cgi?id=12235
3839           REGRESSION (r18815): Marquees do not scroll
3840
3841         * css/cssstyleselector.cpp:
3842         (WebCore::CSSStyleSelector::applyProperty): Apply the '-webkit-marquee' value
3843         of 'overflow-x' and 'overflow-y'.
3844
3845 2007-01-12  Justin Garcia  <justin.garcia@apple.com>
3846
3847         Reviewed by hyatt
3848         
3849         <rdar://problem/4875425>
3850         EBay, GMail, and GoogleDocs RTEs font size popups don't work
3851
3852         Changed execCommand("FontSize", ...) to match the spec 
3853         and the behavior of other browsers.  It expects a number, 
3854         n, which, the spec says can be 1 through 7.  Other browsers 
3855         perform the font size change by creating a font element 
3856         wrapper with size="n".  We convert n into one of the absolute 
3857         size CSS keywords (x-small, medium, etc.).
3858
3859         * editing/JSEditor.cpp: Call cssValueFromFontSizeNumber.  If
3860         successful, perform the style change.
3861         * html/HTMLFontElement.cpp:
3862         (WebCore::HTMLFontElement::cssValueFromFontSizeNumber):  Added.
3863         Moved this code from parsedMappedAttribute so that it could be
3864         called from the Editor.
3865         (WebCore::HTMLFontElement::parseMappedAttribute): Moved code into
3866         cssValueFromFontSizeNumber.
3867         * html/HTMLFontElement.h:
3868
3869 2007-01-12  David Hyatt  <hyatt@apple.com>
3870
3871         Fix for bug 11598, implement lightweight control clipping mechanism for
3872         buttons, list boxes, and dropdown lists.  Make sure list box respects
3873         scrollLeft/Top/Width/Height as well as clientWidth/Height.
3874
3875         Fix bugs in RenderStyle::diff.  CursorData was not being compared properly.
3876         vertical-align had a non-inline display check that was wrong (preventing
3877         dynamic changes to keyword-based vertical-align from working).
3878
3879         Reviewed by mitz
3880
3881         * page/EventHandler.cpp:
3882         (WebCore::EventHandler::selectClosestWordFromMouseEvent):
3883         * rendering/RenderBlock.cpp:
3884         (WebCore::RenderBlock::layout):
3885         (WebCore::RenderBlock::layoutBlock):
3886         (WebCore::RenderBlock::determineHorizontalPosition):
3887         (WebCore::RenderBlock::layoutBlockChildren):
3888         (WebCore::RenderBlock::paint):
3889         (WebCore::RenderBlock::fillHorizontalSelectionGap):
3890         (WebCore::RenderBlock::nodeAtPoint):
3891         (WebCore::RenderBlock::layoutColumns):
3892         * rendering/RenderBox.cpp:
3893         (WebCore::RenderBox::computeAbsoluteRepaintRect):
3894         * rendering/RenderBox.h:
3895         * rendering/RenderButton.cpp:
3896         (WebCore::RenderButton::setStyle):
3897         (WebCore::RenderButton::controlClipRect):
3898         * rendering/RenderButton.h:
3899         (WebCore::RenderButton::hasControlClip):
3900         * rendering/RenderFlexibleBox.cpp:
3901         (WebCore::RenderFlexibleBox::layoutBlock):
3902         (WebCore::RenderFlexibleBox::layoutHorizontalBox):
3903         (WebCore::RenderFlexibleBox::layoutVerticalBox):
3904         * rendering/RenderFlow.cpp:
3905         (WebCore::RenderFlow::addFocusRingRects):
3906         * rendering/RenderListBox.cpp:
3907         (WebCore::RenderListBox::itemBoundingBoxRect):
3908         (WebCore::RenderListBox::paintObject):
3909         (WebCore::RenderListBox::itemHeight):
3910         (WebCore::RenderListBox::verticalScrollbarWidth):
3911         (WebCore::RenderListBox::scrollWidth):
3912         (WebCore::RenderListBox::scrollHeight):
3913         (WebCore::RenderListBox::scrollLeft):
3914         (WebCore::RenderListBox::setScrollLeft):
3915         (WebCore::RenderListBox::scrollTop):
3916         (WebCore::RenderListBox::setScrollTop):
3917         (WebCore::RenderListBox::controlClipRect):
3918         * rendering/RenderListBox.h:
3919         (WebCore::RenderListBox::hasControlClip):
3920         * rendering/RenderMenuList.cpp:
3921         (WebCore::RenderMenuList::setStyle):
3922         (WebCore::RenderMenuList::controlClipRect):
3923         * rendering/RenderMenuList.h:
3924         (WebCore::RenderMenuList::hasControlClip):
3925         * rendering/RenderObject.cpp:
3926         (WebCore::RenderObject::verticalScrollbarWidth):
3927         (WebCore::RenderObject::horizontalScrollbarHeight):
3928         (WebCore::RenderObject::clientWidth):
3929         (WebCore::RenderObject::clientHeight):
3930         (WebCore::RenderObject::setStyle):
3931         * rendering/RenderObject.h:
3932         (WebCore::RenderObject::hasControlClip):
3933         (WebCore::RenderObject::controlClipRect):
3934         (WebCore::RenderObject::contentWidth):
3935         (WebCore::RenderObject::contentHeight):
3936         * rendering/RenderStyle.cpp:
3937         (WebCore::StyleVisualData::StyleVisualData):
3938         (WebCore::cursorDataEqvuialent):
3939         (WebCore::StyleInheritedData::operator==):
3940         (WebCore::CursorList::operator==):
3941         (WebCore::RenderStyle::diff):
3942         * rendering/RenderStyle.h:
3943         (WebCore::LengthBox::operator!=):
3944         (WebCore::StyleVisualData::operator==):
3945         (WebCore::CursorData::operator==):
3946         (WebCore::CursorData::operator!=):
3947         (WebCore::CursorList::operator!=):
3948         (WebCore::RenderStyle::setTableLayout):
3949         * rendering/bidi.cpp:
3950         (WebCore::RenderBlock::layoutInlineChildren):
3951
3952 2007-01-12  David Hyatt  <hyatt@apple.com>
3953
3954         Fix for bug 9934, smaller line heights should not be allowed on
3955         text fields.
3956
3957         Reviewed by darin
3958
3959         * rendering/RenderTextControl.cpp:
3960         (WebCore::RenderTextControl::createInnerTextStyle):
3961
3962 2007-01-12  Mitz Pettel  <mitz@webkit.org>
3963
3964         Reviewed by Hyatt.
3965
3966         - http://bugs.webkit.org/show_bug.cgi?id=12215
3967           Treat 'overflow' and '-webkit-border-radius' as shorthands when parsing and
3968           when removing.
3969
3970         Test: fast/css/remove-shorthand.html (updated)
3971
3972         * css/CSSMutableStyleDeclaration.cpp:
3973         (WebCore::initShorthandMap):
3974         * css/cssparser.cpp:
3975         (WebCore::CSSParser::parseValue):
3976
3977 2007-01-12  Rob Buis  <buis@kde.org>
3978
3979         Reviewed by Mitz.
3980
3981         Do not mix up JSSVGPolygonElement and JSSVGPolylineElement.
3982
3983         * bindings/js/JSSVGElementWrapperFactory.cpp:
3984
3985 2007-01-12  Kevin Decker <kdecker@apple.com>
3986
3987         Reviewed by andersca.
3988
3989         Fixed: <rdar://problem/4701326>21.2 ms launch time regression spent in +[WebPluginDatabase installedPlugins]
3990
3991         * dom/DOMImplementation.cpp:
3992         (WebCore::DOMImplementation::createDocument): Added a guard clause for text/html which used to be in WebKit before a lot of the 
3993         loader plumbing was moved to WebCore.  Pinging the plug-in database to ask it if it supports a given mime type has the side 
3994         effect of reading from disk on first call, therefore such a check should be a last resort.  
3995
3996 2007-01-12  Mitz Pettel  <mitz@webkit.org>
3997
3998         Reviewed by Darin.
3999
4000         - fix http://bugs.webkit.org/show_bug.cgi?id=12223
4001           REGRESSION: Leaks under CSSStyleSelector::applyProperty
4002
4003         No test possible (no change to functionality).
4004
4005         * rendering/RenderObject.h: Removed unused forward declaration.
4006         * rendering/RenderStyle.cpp:
4007         (WebCore::StyleRareNonInheritedData::~StyleRareNonInheritedData):
4008         Delete shadow data.
4009
4010 2007-01-12  Anders Carlsson  <acarlsson@apple.com>
4011
4012         Build fix.
4013         
4014         * WebCore.xcodeproj/project.pbxproj:
4015         Remove SubresourceLoaderMac.mm.
4016         
4017 2007-01-12  Lars Knoll <lars@trolltech.com>
4018
4019         Reviewed by Darin and Anders.
4020
4021         Make some more of the loader code platform independent.
4022
4023         * loader/FrameLoader.cpp:
4024         (WebCore::FrameLoader::clear):
4025         (WebCore::FrameLoader::checkLoadCompleteForThisFrame):
4026         (WebCore::FrameLoader::urlSelected):
4027         (WebCore::FrameLoader::createEmptyDocument):
4028         (WebCore::FrameLoader::setTitle):
4029         (WebCore::FrameLoader::originalRequestURL):
4030         (WebCore::FrameLoader::referrer):
4031         * loader/SubresourceLoader.cpp:
4032         (WebCore::SubresourceLoader::SubresourceLoader):
4033         (WebCore::SubresourceLoader::load):
4034         (WebCore::SubresourceLoader::create):
4035         (WebCore::SubresourceLoader::willSendRequest):
4036         (WebCore::SubresourceLoader::didReceiveResponse):
4037         (WebCore::SubresourceLoader::didReceiveData):
4038         (WebCore::SubresourceLoader::didFinishLoading):
4039         (WebCore::SubresourceLoader::didFail):
4040         (WebCore::SubresourceLoader::didCancel):
4041         (WebCore::SubresourceLoader::stopLoading):
4042         * loader/SubresourceLoader.h:
4043         * loader/mac/FrameLoaderMac.mm:
4044         * loader/mac/SubresourceLoaderMac.mm: Removed.
4045         * loader/qt/FrameLoaderQt.cpp:
4046
4047 2007-01-12  Lars Knoll <lars@trolltech.com>
4048
4049         Reviewed by Zack
4050
4051         Valgrind reported uninitialized variable.
4052
4053         * platform/network/qt/ResourceHandleManagerQt.cpp:
4054         (WebCore::FileLoader::request):
4055
4056 2007-01-12  Mitz Pettel  <mitz@webkit.org>
4057
4058         Reviewed by rwlbuis.
4059
4060         - add missing null check in new fixed table layout code
4061
4062         * rendering/FixedTableLayout.cpp:
4063         (WebCore::FixedTableLayout::calcWidthArray):
4064
4065 2007-01-12  Lars Knoll <lars@trolltech.com>
4066
4067         Fix the Qt build after the Authenitcation changes.
4068
4069         * WebCore.pro:
4070         * platform/network/ResourceHandleInternal.h:
4071
4072 2007-01-12  David Hyatt  <hyatt@apple.com>
4073
4074         Fix for bug 9569.  Make sure the selection offset for selection roots excludes border and padding.
4075
4076         Reviewed by Eric
4077
4078         * rendering/RenderBlock.cpp:
4079         (WebCore::RenderBlock::leftSelectionOffset):
4080         (WebCore::RenderBlock::rightSelectionOffset):
4081
4082 2007-01-11  David Hyatt  <hyatt@apple.com>
4083
4084         Fix for bug 8705, readonly text fields should not get focus rings.  Add a rule to that effect to
4085         html4.css and then also add readonly as a special case for style sharing so that we can retain the
4086         performance boost from sharing styles on inputs.
4087
4088         Reviewed by bdash
4089
4090         * css/cssstyleselector.cpp:
4091         (WebCore::CSSStyleSelector::canShareStyleWithElement):
4092         (WebCore::CSSStyleSelector::checkOneSelector):
4093         * css/html4.css:
4094
4095 2007-01-11  David Hyatt  <hyatt@apple.com>
4096
4097         Fix for bug 11595.  Autoscrolling of layers didn't really work at all unless the layer was coincidentally
4098         in the root layer's coordinate space.  The event point was an absolute position within the document, but
4099         the layer's rect was only local coords.  This patch makes sure to use absolute bounds for the layer
4100         when comparing it with the point.
4101
4102         This is covered by the scrollRevealButton test case already in the tree... the results change to be more
4103         correct.
4104
4105         Reviewed by ggaren
4106
4107         * rendering/RenderLayer.cpp:
4108         (WebCore::RenderLayer::scrollRectToVisible):
4109
4110 2007-01-11  Brady Eidson  <beidson@apple.com>
4111
4112         Reviewed by Oliver
4113
4114         -Move more HTTP Auth handling towards ResourceHandle, away from ResourceHandleClient
4115         -Make more of ResourceLoader cross-platform
4116
4117         * loader/ResourceLoader.cpp:
4118         (WebCore::ResourceLoader::ResourceLoader):
4119         (WebCore::ResourceLoader::releaseResources):
4120         (WebCore::ResourceLoader::didCancel):
4121         (WebCore::ResourceLoader::didReceiveAuthenticationChallenge):
4122         (WebCore::ResourceLoader::didCancelAuthenticationChallenge):
4123         (WebCore::ResourceLoader::receivedCancellation):
4124         * loader/ResourceLoader.h:
4125         (WebCore::ResourceLoader::willStopBufferingData):
4126         (WebCore::ResourceLoader::didCancelAuthenticationChallenge):
4127         (WebCore::ResourceLoader::willCacheResponse):
4128         * loader/mac/ResourceLoaderMac.mm:
4129         * platform/network/ResourceHandle.h:
4130         * platform/network/ResourceHandleClient.h:
4131         (WebCore::ResourceHandleClient::willStopBufferingData):
4132         * platform/network/ResourceHandleInternal.h:
4133         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
4134         * platform/network/mac/ResourceHandleMac.mm:
4135         (WebCore::ResourceHandle::didReceiveAuthenticationChallenge):
4136         (WebCore::ResourceHandle::didCancelAuthenticationChallenge):
4137         (WebCore::ResourceHandle::receivedCredential):
4138         (WebCore::ResourceHandle::receivedRequestToContinueWithoutCredential):
4139         (WebCore::ResourceHandle::receivedCancellation):
4140         (WebCore::ResourceHandle::clearAuthentication):
4141         (-[WebCoreResourceHandleAsDelegate connection:didReceiveAuthenticationChallenge:]):
4142         (-[WebCoreResourceHandleAsDelegate connection:didCancelAuthenticationChallenge:]):
4143         (-[WebCoreResourceHandleAsDelegate useCredential:forAuthenticationChallenge:]):
4144         (-[WebCoreResourceHandleAsDelegate continueWithoutCredentialForAuthenticationChallenge:]):
4145         (-[WebCoreResourceHandleAsDelegate cancelAuthenticationChallenge:]):
4146
4147 2007-01-11  David Hyatt  <hyatt@apple.com>
4148
4149         A hit test is returning a null renderer.  Make sure to null-check it in the autoscroll code.
4150         This really shouldn't happen, but I'm just going to bullet proof for now given that it's happening
4151         on the front page of yahoo.com!
4152
4153         Reviewed by mark
4154
4155         * rendering/RenderLayer.cpp:
4156         (WebCore::RenderLayer::autoscroll):
4157
4158 2007-01-11  David Hyatt  <hyatt@apple.com>
4159
4160         Force column-width to parse in strict mode so that there is no confusion when it is used in the columns
4161         shorthand (it can be mistaken for column-count otherwise).
4162
4163         Reviewed by Mark
4164
4165         fast/multicol/columns-shorthand-parsing.html
4166
4167         * css/cssparser.cpp:
4168         (WebCore::CSSParser::parseValue):
4169
4170 2007-01-11  Mitz Pettel  <mitz@webkit.org>
4171
4172         Reviewed by Hyatt.
4173
4174         - fix http://bugs.webkit.org/show_bug.cgi?id=12124
4175           RenderTable::section{Above,Below}() can return the wrong answer for the {footer,header}
4176
4177         * rendering/RenderTable.cpp:
4178         (WebCore::resetSectionPointerIfNotBefore): Added this function to help with