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