Reviewed by Zack
[WebKit-https.git] / WebCore / ChangeLog
1 2007-01-29  Lars Knoll <lars@trolltech.com>
2
3         Reviewed by Zack
4
5         Fix the way we handle native widgets (QWidget) inside
6         WebCore. Now WebCore::Widget owns the QWidget in all
7         cases. This is the only way to get well defined semantics
8         for all teh native widgets we have (currently ScrollView
9         and ScrollBar, but plugins will follow).
10
11         This has the side effect that one cannot rely on a defined 
12         lifetime of a QWebFrame when using the API. 
13
14         * platform/Widget.h:
15         * platform/qt/PlatformScrollBarQt.cpp:
16         (WebCore::PlatformScrollbar::PlatformScrollbar):
17         * platform/qt/ScrollViewQt.cpp:
18         (WebCore::ScrollView::addChild):
19         (WebCore::ScrollView::removeChild):
20         * platform/qt/WidgetQt.cpp:
21         (WebCore::WidgetPrivate::WidgetPrivate):
22         (WebCore::WidgetPrivate::~WidgetPrivate):
23         (WebCore::Widget::qwidget):
24
25 2007-01-28  George Staikos  <staikos@kde.org>
26
27         Reviewed by Maciej.
28
29         Don't send data during a redirect -> causes assert failure.
30
31         * platform/network/qt/ResourceHandleManagerQt.cpp:
32         (WebCore::ResourceHandleManager::receivedData):
33
34 2007-01-29  Mark Rowe  <mrowe@apple.com>
35
36         Reviewed by Brady.
37
38         http://bugs.webkit.org/show_bug.cgi?id=11085
39         Bug 11085: REGRESSION: favicon.ico always looked for on port 80
40
41         * loader/FrameLoader.cpp:
42         (WebCore::FrameLoader::iconURL): Copy the port over to the favicon URL.
43
44 2007-01-28  Adam Roben  <aroben@apple.com>
45
46         Reviewed by Adele.
47
48         Fix http://bugs.webkit.org/show_bug.cgi?id=12453
49         REGRESSION(r19197): Tabbing into web page requires two key presses
50
51         All layout tests pass.
52
53         * page/FocusController.cpp:
54         (WebCore::FocusController::advanceFocus): If there's no focused frame,
55         actually go ahead and find a focusable node instead of just focusing
56         the main frame and quitting. This behavior was a holdover from a
57         previous desired tabbing behavior with respect to frames.
58
59 2007-01-28  David Kilzer  <ddkilzer@webkit.org>
60
61         Reviewed by Darin and David Hyatt.
62
63         - fix http://bugs.webkit.org/show_bug.cgi?id=12423
64           Mixing white-space:pre text with non white-space:pre text does not wrap properly
65
66         Test: fast/block/basic/white-space-pre-wraps.html
67
68         * rendering/bidi.cpp:
69         (WebCore::RenderBlock::findNextLineBreak): Wrap a non-wrapping text run if it
70         appears on a line with previous text runs that do wrap.
71
72 2007-01-28  Mitz Pettel  <mitz@webkit.org>
73
74         Reviewed by Darin.
75
76         - fix http://bugs.webkit.org/show_bug.cgi?id=8360
77           Repro crash when onscroll handler deletes the scrolled object
78
79         Test: fast/layers/removed-by-scroll-handler.html
80
81         * page/FrameView.cpp:
82         (WebCore::FrameViewPrivate::FrameViewPrivate): Added a m_enqueueEvents count.
83         (WebCore::FrameView::layout): Raise the enqueue count before starting layout and
84         until after enqueued events are dispatched.
85         (WebCore::FrameView::scheduleEvent): Made this function dispatch the event
86         immediately unless the enqueue count is positive.
87         * rendering/RenderLayer.cpp:
88         (WebCore::RenderLayer::scrollToOffset): Schedule the scroll event through the
89         FrameView.
90         (WebCore::RenderLayer::scrollRectToVisible):
91         (WebCore::RenderLayer::updateScrollInfoAfterLayout):
92         (WebCore::Marquee::start):
93
94 2007-01-28  Charles Ying  <charles_ying@yahoo.com>
95
96         Reviewed by eseidel.  Landed by eseidel.
97
98         Fix http://bugs.webkit.org/show_bug.cgi?id=12429
99             animateTransform rotate, with cx/cy is broken
100             
101         SVGTransform now contains a float point to store the rotation center, needed
102             to track rotation center for interpolation by animateTransform.
103             
104         SVGTransform now has an additional constructor:
105             SVGTransform(type) to make empty base value transforms that match their
106             distanced values.
107             
108         Removed m_colorDistance and m_transformDistance from their respective classes
109             as they are now computed at update time.
110
111         Fix a case where animateTransform did not parse transform values correctly
112             according to BNF in W3C spec:
113
114         Test case in:
115         * manual-tests/animation/animateTransform-toanimation.svg: Added.
116
117         Fix a case where animateTransform only specified a to animation only.
118
119         Test case in:
120         * manual-tests/animation/animateTransform-parser.svg: Added.
121
122         * ksvg2/svg/SVGAnimateColorElement.cpp:
123         (WebCore::SVGAnimateColorElement::updateAnimationBaseValueFromElement):
124         (WebCore::SVGAnimateColorElement::updateAnimatedValue):
125         (WebCore::SVGAnimateColorElement::calculateFromAndToValues):
126         * ksvg2/svg/SVGAnimateColorElement.h:
127         * ksvg2/svg/SVGAnimateTransformElement.cpp:
128         (WebCore::SVGAnimateTransformElement::updateAnimatedValue):
129         (WebCore::SVGAnimateTransformElement::updateAnimationBaseValueFromElement):
130         (WebCore::SVGAnimateTransformElement::calculateFromAndToValues):
131         (WebCore::SVGAnimateTransformElement::parseTransformValue):
132         * ksvg2/svg/SVGAnimateTransformElement.h:
133         * ksvg2/svg/SVGTransform.cpp:
134         (SVGTransform::SVGTransform):
135         (SVGTransform::angle):
136         (SVGTransform::rotationCenter):
137         (SVGTransform::setTranslate):
138         (SVGTransform::setScale):
139         (SVGTransform::setRotate):
140         (SVGTransform::setSkewX):
141         (SVGTransform::setSkewY):
142         * ksvg2/svg/SVGTransform.h:
143         * ksvg2/svg/SVGTransformDistance.cpp:
144         (WebCore::SVGTransformDistance::SVGTransformDistance):
145         (WebCore::SVGTransformDistance::scaledDistance):
146         (WebCore::SVGTransformDistance::addSVGTransforms):
147         (WebCore::SVGTransformDistance::addSVGTransform):
148         (WebCore::SVGTransformDistance::addToSVGTransform):
149         (WebCore::SVGTransformDistance::distance):
150         * ksvg2/svg/SVGTransformDistance.h:
151         * manual-tests/animation/animateTransform-parser.svg: Added.
152         * manual-tests/animation/animateTransform-toanimation.svg: Added.
153
154 2007-01-27  Adam Roben  <aroben@apple.com>
155
156         Reviewed by Ada.
157
158         Fix <rdar://problem/4957184> REGRESSION: After creating a new mail
159         message, the caret is automatically in message body
160
161         -[WebHTMLView _updateActiveState] was calling
162         FocusController::focusedOrMainFrame, which had the surprising
163         side-effect of setting the focused frame if there was none. The fix
164         was to remove this side-effect.
165
166         No tests possible, as this bug involves focus outside the WebView,
167         which we have no support for in DRT.
168
169         Change inspired by Dave Harrison.
170
171         * page/FocusController.cpp:
172         (WebCore::FocusController::focusedOrMainFrame): Removed this method's
173         non-obvious side-effect of setting the focused frame.
174         * WebCore.xcodeproj/project.pbxproj: Version wars.
175
176 2007-01-27  Don Gibson  <dgibson77@gmail.com>
177
178         Reviewed by Maciej.
179
180         http://bugs.webkit.org/show_bug.cgi?id=11880: Improve some egregious
181         Windows form control drawing issues:
182         Provide Classic mode fallbacks for the button/textfield drawing
183         routines.
184         Provide some basic drawing of menulists (still relatively broken).
185         Some cleanup.
186
187         * platform/win/TemporaryLinkStubs.cpp:
188         (WebCore::RenderThemeWin::systemFont):
189         * rendering/RenderThemeWin.cpp:
190         (WebCore::m_menuListTheme):
191         (WebCore::RenderThemeWin::close):
192         (WebCore::RenderThemeWin::determineClassicState):
193         (WebCore::RenderThemeWin::getThemeData):
194         (WebCore::RenderThemeWin::paintButton):
195         (WebCore::RenderThemeWin::paintTextField):
196         (WebCore::RenderThemeWin::paintMenuList):
197         (WebCore::RenderThemeWin::paintMenuListButton):
198         * rendering/RenderThemeWin.h:
199         (WebCore::ThemeData::m_classicState):
200         (WebCore::RenderThemeWin::setRadioSize):
201         (WebCore::RenderThemeWin::paintTextArea):
202
203 2007-01-27  David Kilzer  <ddkilzer@webkit.org>
204
205         Reviewed by Adam.
206
207         - fix http://bugs.webkit.org/show_bug.cgi?id=12260
208           Windows platform build is not maintained
209
210         * loader/win/FrameLoaderWin.cpp:
211         * platform/network/win/ResourceHandleWin.cpp:
212         * platform/win/TemporaryLinkStubs.cpp:
213         (WebCore::contextMenuItemTagOpenLinkInNewWindow):
214         (WebCore::contextMenuItemTagDownloadLinkToDisk):
215         (WebCore::contextMenuItemTagCopyLinkToClipboard):
216         (WebCore::contextMenuItemTagOpenImageInNewWindow):
217         (WebCore::contextMenuItemTagDownloadImageToDisk):
218         (WebCore::contextMenuItemTagCopyImageToClipboard):
219         (WebCore::contextMenuItemTagOpenFrameInNewWindow):
220         (WebCore::contextMenuItemTagCopy):
221         (WebCore::contextMenuItemTagGoBack):
222         (WebCore::contextMenuItemTagGoForward):
223         (WebCore::contextMenuItemTagStop):
224         (WebCore::contextMenuItemTagReload):
225         (WebCore::contextMenuItemTagCut):
226         (WebCore::contextMenuItemTagPaste):
227         (WebCore::contextMenuItemTagNoGuessesFound):
228         (WebCore::contextMenuItemTagIgnoreSpelling):
229         (WebCore::contextMenuItemTagLearnSpelling):
230         (WebCore::contextMenuItemTagSearchWeb):
231         (WebCore::contextMenuItemTagLookUpInDictionary):
232         (WebCore::contextMenuItemTagOpenLink):
233         (WebCore::contextMenuItemTagIgnoreGrammar):
234         (WebCore::contextMenuItemTagSpellingMenu):
235         (WebCore::contextMenuItemTagShowSpellingPanel):
236         (WebCore::contextMenuItemTagCheckSpelling):
237         (WebCore::contextMenuItemTagCheckSpellingWhileTyping):
238         (WebCore::contextMenuItemTagCheckGrammarWithSpelling):
239         (WebCore::contextMenuItemTagFontMenu):
240         (WebCore::contextMenuItemTagBold):
241         (WebCore::contextMenuItemTagItalic):
242         (WebCore::contextMenuItemTagUnderline):
243         (WebCore::contextMenuItemTagOutline):
244         (WebCore::contextMenuItemTagWritingDirectionMenu):
245         (WebCore::contextMenuItemTagDefaultDirection):
246         (WebCore::contextMenuItemTagLeftToRight):
247         (WebCore::contextMenuItemTagRightToLeft):
248         (WebCore::DocumentLoader::unreachableURL):
249         (WebCore::FrameLoader::redirectDataToPlugin):
250         (WebCore::FrameLoader::partClearedInBegin):
251         (WebCore::FrameLoader::createPlugin):
252
253 2007-01-27  Sam Weinig  <sam@webkit.org>
254
255         Reviewed by Mitz.
256
257         - Patch for http://bugs.webkit.org/show_bug.cgi?id=11957
258           REGRESSION: Unordered List Bullets too big and changing from size
259
260         * rendering/RenderListMarker.cpp:
261         (WebCore::RenderListMarker::paint): Explicitly set the stroke size to 1.0f.
262
263 2007-01-27  Lars Knoll <lars@trolltech.com>
264
265         Fix the Qt build and disable the usage
266         of QScrollbars for PlatformScrollBar for 
267         now as it causes crashes in the layout tests.
268
269         * WebCore.pro:
270         * ksvg2/svg/SVGTransformDistance.cpp:
271         * page/qt/FrameQt.cpp:
272         (WebCore::FrameQt::FrameQt):
273         (WebCore::FrameQt::bindingRootObject):
274         (WebCore::FrameQt::createRootObject):
275         * page/qt/FrameQt.h:
276         * platform/qt/PlatformScrollBarQt.cpp:
277         (WebCore::PlatformScrollbar::PlatformScrollbar):
278         * platform/qt/ScrollViewQt.cpp:
279         (WebCore::ScrollView::addChild):
280
281 2007-01-27  David Kilzer  <ddkilzer@kilzer.net>
282
283         Reviewed by NOBODY (buildbot build fix).
284
285         * ksvg2/svg/ColorDistance.cpp:
286         (WebCore::ColorDistance::scaledDistance): Added static cast of arguments to int.
287
288 2007-01-27  Rob Buis  <buis@kde.org>
289
290         Reviewed by NOBODY (typo in method name fix).
291
292         * ksvg2/svg/SVGSVGElement.cpp:
293         (WebCore::SVGSVGElement::addSVGWindowEventListener):
294         (WebCore::SVGSVGElement::parseMappedAttribute):
295         * ksvg2/svg/SVGSVGElement.h:
296
297 2007-01-27  Eric Seidel  <eric@webkit.org>
298
299         Reviewed by olliej.
300
301         Fix support for SVG's <set> element.
302
303         Manual test added.
304
305         * ksvg2/svg/SVGSetElement.cpp:
306         (WebCore::SVGSetElement::updateAnimatedValue):
307         (WebCore::SVGSetElement::calculateFromAndToValues):
308         * ksvg2/svg/SVGSetElement.h:
309         * manual-tests/animation/set-to.svg: Added.
310
311 2007-01-27  Alexey Proskuryakov  <ap@webkit.org>
312
313         Release build fix.
314
315         * loader/TextResourceDecoder.cpp:
316         (WebCore::TextResourceDecoder::checkForHeadCharset):
317
318 2007-01-27  Alexey Proskuryakov  <ap@webkit.org>
319
320         Reviewed by Darin.
321
322         http://bugs.webkit.org/show_bug.cgi?id=12389
323         Chinese decoding error at hk.antispam.yahoo.com
324
325         Test: fast/encoding/noscript-in-head.html
326
327         * loader/TextResourceDecoder.cpp:
328         (WebCore::TextResourceDecoder::checkForHeadCharset): We were already allowing 
329         NOSCRIPT tags in head, let's actually skip over their content.
330
331 2007-01-26  Geoffrey Garen  <ggaren@apple.com>
332
333         Reviewed by Maciej Stachowiak.
334         
335         Fixed <rdar://problem/4608404> WebScriptObject's _executionContext lack 
336         of ownership policy causes crashes (e.g., in Dashcode)
337
338         Added RootObject ref-counting goodness.
339
340         * page/mac/FrameMac.h:
341         * page/mac/FrameMac.mm:
342         (WebCore::FrameMac::cleanupPluginObjects): Invalidate our RootObjects 
343         instead of detroying them. Track _bindingRootObject separately from the
344         rest of our RootObjects, since it has its own variable.
345
346         * page/mac/WebCoreFrameBridge.mm:
347         (createRootObject): Use the Frame's new, more encapsulated function to
348         create a RootObject.
349
350         * bindings/objc/WebScriptObject.mm: Nixed rootObject setters, since they
351         were unused and they complicated reference-counting.
352
353 2007-01-26  David Kilzer  <ddkilzer@webkit.org>
354
355         Reviewed by Eric.
356
357         Release build fix.
358
359         * ksvg2/svg/SVGAnimationElement.cpp:
360         (WebCore::SVGAnimationElement::calculateValueIndexAndPercentagePast): Added static cast
361         to unsigned when calculating flooredValueIndex.
362
363 2007-01-26  Darin Adler  <darin@apple.com>
364
365         - checked in slightly newer revision of the patch below
366
367         * css/CSSComputedStyleDeclaration.cpp:
368         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
369         Grouped all the unimplemented values at the bottom. Fixed the ifdef for
370         CSS_PROP__WEBKIT_DASHBOARD_REGION so that it compiles on all platforms.
371
372         * css/cssparser.cpp: (WebCore::CSSParser::parseValue): Removed default
373         case and added type so that the compiler warns about missing properties.
374         * css/cssstyleselector.cpp: (WebCore::CSSStyleSelector::applyProperty): Ditto.
375
376 2007-01-26  Darin Adler  <darin@apple.com>
377
378         Reviewed by Beth.
379
380         - fix http://bugs.webkit.org/show_bug.cgi?id=12412
381           "unimplemented propertyID: 46" seen at dojotoolkit.org
382
383         Covered by fast/css/computed-style.html
384
385         * css/CSSPropertyNames.in: Sorted the file into two separate sections, one
386         for properties without the -webkit- prefix and another for properties with.
387
388         * css/makeprop: Generate a CSSPropertyID enum instead of a set of #defines.
389         Removed unused CSS_PROP_MIN and CSS_PROP_MAX. Renamed CSS_PROP_TOTAL to
390         numCSSProperties and changed it to a const int instead of #define.
391         Added a declaration of getPropertyName in the header. Changed the return
392         type of getPropertyName to const char* and the parameter type to CSSPropertyID.
393
394         * css/CSSComputedStyleDeclaration.cpp: Sort the lists of properties in
395         an easier to maintain order -- properties without a WebKit prefix first.
396         (WebCore::valueForLength): Changed return value to PassRefPtr.
397         (WebCore::valueForMaxLength): Ditto.
398         (WebCore::valueForBorderStyle): Ditto.
399         (WebCore::valueForTextAlign): Ditto.
400         (WebCore::valueForAppearance): Added.
401         (WebCore::valueForMarginCollapse): Added.
402         (WebCore::valueForShadow): Changed return value to PassRefPtr.
403         (WebCore::getPositionOffsetValue): Ditto.
404         (WebCore::currentColorOrValidColor): Ditto.
405         (WebCore::CSSComputedStyleDeclaration::cssText): Added cast since
406         getPropertyName now takes an enum value.
407         (WebCore::primitiveValueFromLength): Changed return value to PassRefPtr.
408         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
409         Added cast to CSSPropertyID so that gcc will detect missing enums in the
410         switch statement. Simplified the background-size and border-spacing
411         implementations so they don't have local variables. Added lots of cases
412         to the switch statement for unimplemented properties. Implemented the
413         outline-width, box-sizing, -webkit-appearance, -webkit-rtl-ordering,
414         -webkit-user-drag, and -webkit-user-select properties.
415         (WebCore::CSSComputedStyleDeclaration::item): Added cast since
416         getPropertyName now takes an enum value.
417
418         * css/CSSMutableStyleDeclaration.cpp: Removed declaration of getPropertyName.
419         (WebCore::CSSMutableStyleDeclaration::item): Added cast since
420         getPropertyName now takes an enum value.
421
422         * css/CSSProperty.cpp: Removed declaration of getPropertyName.
423         (WebCore::CSSProperty::cssText): Added cast since
424         getPropertyName now takes an enum value and returns a const char*.
425
426         * css/CSSStyleDeclaration.cpp: Removed declaration of getPropertyName.
427         (WebCore::CSSStyleDeclaration::getPropertyShorthand): Added cast since
428         getPropertyName now takes an enum value and returns a const char*.
429
430 2007-01-26  Alice Liu  <alice.liu@apple.com>
431
432         Reviewed by Brady.
433
434         Fixed <rdar://problem/4838076> CrashTracer: 10 crashes in Mail at com.apple.WebCore: WTF::HashMap<WebCore::String
435
436         * loader/DocLoader.cpp:
437         (WebCore::DocLoader::requestResource):
438         Added nil check around resource from cache.
439
440 2007-01-26  Adam Roben  <aroben@apple.com>
441
442         Reviewed by Oliver.
443
444         Build fix.
445
446         * ksvg2/svg/SVGAnimationElement.cpp:
447         (WebCore::SVGAnimationElement::calculateValueIndexAndPercentagePast):
448         Keep index variables as unsigned until we need to convert to float.
449
450 2007-01-26  Alice Liu  <alice.liu@apple.com>
451
452         Reviewed by Ada.
453
454         Fixed <rdar://problem/4919097> REGRESSION: Ctrl-Y fails to yank (11076)
455
456         * editing/Editor.cpp:
457         (WebCore::Editor::deleteWithDirection):
458         If there's no selection, locally create a range that is to the end of the granularity unit and pass that to deleteRange(). 
459
460 2007-01-26  Sam Weinig  <sam@webkit.org>
461
462         Reviewed by Maciej.
463
464         Qt build fix.
465
466         * page/qt/EventHandlerQt.cpp:
467
468 2007-01-26  Dex Deacon  <occupant4@gmail.com>
469
470         Reviewed by Hyatt.
471
472         Fix so that we only relayout frameset children on calls to layout.
473
474         * page/FrameView.cpp:
475         (WebCore::FrameView::layout):
476
477 2007-01-26  Oliver Hunt  <oliver@apple.com>
478
479         Build Fix
480
481         * ksvg2/svg/ColorDistance.cpp:
482         * ksvg2/svg/SVGAnimationElement.cpp:
483         (WebCore::SVGAnimationElement::handleTimerEvent):
484
485 2007-01-26  Eric Seidel  <eric@webkit.org>
486
487         Reviewed by olliej.
488
489         Add support for calcMode, keyTimes and (nearly) keySplines.
490         http://bugs.webkit.org/show_bug.cgi?id=12350
491         Re-architect much of the animation system to remove huge sections of code.
492         Added new ColorDistance, SVGTransformDistance to simplify animateColor, animateTransform calculations.
493         I also added basic <animateMotion> support since it was so easy w/ the new architecture.
494         
495         Adding manual animation tests until bug 12074 is fixed.
496
497         * WebCore.xcodeproj/project.pbxproj:
498         * ksvg2/misc/SVGTimer.cpp:
499         (WebCore::SVGTimer::applyAnimations):
500         * ksvg2/svg/ColorDistance.cpp: Added.
501         (WebCore::ColorDistance::ColorDistance):
502         (WebCore::clampColorValue):
503         (WebCore::ColorDistance::scaledDistance):
504         (WebCore::ColorDistance::addColorsAndClamp):
505         (WebCore::ColorDistance::addToColorAndClamp):
506         (WebCore::ColorDistance::isZero):
507         (WebCore::ColorDistance::distance):
508         * ksvg2/svg/ColorDistance.h: Added.
509         * ksvg2/svg/SVGAnimateColorElement.cpp:
510         (WebCore::SVGAnimateColorElement::SVGAnimateColorElement):
511         (WebCore::SVGAnimateColorElement::updateAnimationBaseValueFromElement):
512         (WebCore::SVGAnimateColorElement::applyAnimatedValueToElement):
513         (WebCore::SVGAnimateColorElement::updateAnimatedValue):
514         (WebCore::SVGAnimateColorElement::calculateFromAndToValues):
515         * ksvg2/svg/SVGAnimateColorElement.h:
516         (WebCore::SVGAnimateColorElement::contextElement):
517         * ksvg2/svg/SVGAnimateElement.h:
518         (WebCore::SVGAnimateElement::updateAnimatedValue):
519         (WebCore::SVGAnimateElement::calculateFromAndToValues):
520         * ksvg2/svg/SVGAnimateMotionElement.cpp:
521         (WebCore::SVGAnimateMotionElement::hasValidTarget):
522         (WebCore::SVGAnimateMotionElement::updateAnimatedValue):
523         (WebCore::parsePoint):
524         (WebCore::SVGAnimateMotionElement::calculateFromAndToValues):
525         (WebCore::SVGAnimateMotionElement::updateAnimationBaseValueFromElement):
526         (WebCore::SVGAnimateMotionElement::applyAnimatedValueToElement):
527         * ksvg2/svg/SVGAnimateMotionElement.h:
528         * ksvg2/svg/SVGAnimateTransformElement.cpp:
529         (WebCore::SVGAnimateTransformElement::SVGAnimateTransformElement):
530         (WebCore::SVGAnimateTransformElement::updateAnimatedValue):
531         (WebCore::SVGAnimateTransformElement::updateAnimationBaseValueFromElement):
532         (WebCore::SVGAnimateTransformElement::applyAnimatedValueToElement):
533         (WebCore::SVGAnimateTransformElement::calculateFromAndToValues):
534         (WebCore::SVGAnimateTransformElement::parseTransformValue):
535         * ksvg2/svg/SVGAnimateTransformElement.h:
536         (WebCore::SVGAnimateTransformElement::contextElement):
537         * ksvg2/svg/SVGAnimationElement.cpp:
538         (WebCore::SVGAnimationElement::parseKeyNumbers):
539         (WebCore::parseValues):
540         (WebCore::parseKeySplines):
541         (WebCore::SVGAnimationElement::parseMappedAttribute):
542         (WebCore::SVGAnimationElement::targetAttributeAnimatedValue):
543         (WebCore::SVGAnimationElement::setTargetAttributeAnimatedValue):
544         (WebCore::SVGAnimationElement::detectAnimationMode):
545         (WebCore::adjustPercentagePastForKeySplines):
546         (WebCore::SVGAnimationElement::valueIndexAndPercentagePastForDistance):
547         (WebCore::SVGAnimationElement::calculateTotalDistance):
548         (WebCore::caculateValueIndexForKeyTimes):
549         (WebCore::SVGAnimationElement::isValidAnimation):
550         (WebCore::SVGAnimationElement::calculateValueIndexAndPercentagePast):
551         (WebCore::SVGAnimationElement::updateAnimationBaseValueFromElement):
552         (WebCore::SVGAnimationElement::applyAnimatedValueToElement):
553         (WebCore::SVGAnimationElement::handleTimerEvent):
554         (WebCore::SVGAnimationElement::updateAnimatedValueForElapsedSeconds):
555         * ksvg2/svg/SVGAnimationElement.h:
556         * ksvg2/svg/SVGParserUtilities.cpp:
557         (WebCore::SVGPolyParser::parsePoints):
558         * ksvg2/svg/SVGParserUtilities.h:
559         * ksvg2/svg/SVGSetElement.cpp:
560         * ksvg2/svg/SVGSetElement.h:
561         (WebCore::SVGSetElement::updateAnimatedValue):
562         (WebCore::SVGSetElement::calculateFromAndToValues):
563         * ksvg2/svg/SVGTransform.cpp:
564         (SVGTransform::type):
565         (SVGTransform::translate):
566         (SVGTransform::scale):
567         (SVGTransform::setSkewX):
568         (SVGTransform::setSkewY):
569         * ksvg2/svg/SVGTransform.h:
570         (WebCore::operator==):
571         (WebCore::operator!=):
572         * ksvg2/svg/SVGTransformDistance.cpp: Added.
573         (WebCore::SVGTransformDistance::SVGTransformDistance):
574         (WebCore::SVGTransformDistance::scaledDistance):
575         (WebCore::SVGTransformDistance::addSVGTransforms):
576         (WebCore::SVGTransformDistance::addSVGTransform):
577         (WebCore::SVGTransformDistance::addToSVGTransform):
578         (WebCore::SVGTransformDistance::isZero):
579         (WebCore::SVGTransformDistance::distance):
580         * ksvg2/svg/SVGTransformDistance.h: Added.
581         * ksvg2/svg/SVGTransformList.cpp:
582         (SVGTransformList::concatenateForType):
583         * ksvg2/svg/SVGTransformList.h:
584         * manual-tests/animation/animateColor-by.svg: Added.
585         * manual-tests/animation/animateColor-from-by.svg: Added.
586         * manual-tests/animation/animateColor-repeat-indefinite.svg: Added.
587         * manual-tests/animation/animateColor-to-from.svg: Added.
588         * manual-tests/animation/animateColor-to.svg: Added.
589         * manual-tests/animation/animateColor-values-simple.svg: Added.
590         * manual-tests/animation/animateMotion-to.svg: Added.
591         * manual-tests/animation/animateTransform-keyTimes.svg: Added.
592         * manual-tests/animation/animateTransform-repeat-once.svg: Added.
593
594 2007-01-26  Beth Dakin  <bdakin@apple.com>
595
596         Reviewed by Darin.
597
598         Fix for <rdar://problem/4956565> REGRESSION: After scrolling frame, 
599         hovering over link in this frame doesn't change cursor to pointing 
600         hand
601
602         The mouseMove event was not being propagated correctly after using 
603         the mouse to scroll the frame because m_mousePressed was never 
604         getting set to false.
605
606         * page/EventHandler.cpp:
607         (WebCore::EventHandler::handleMousePressEvent): This code does not 
608         belong here.
609         * page/EventHandler.h: lastEventIsMouseUp() is only ever relevant 
610         in EventHandlerMac, so it can just be a static function there.
611         * page/mac/EventHandlerMac.mm:
612         (WebCore::lastEventIsMouseUp): Make this static.
613         (WebCore::EventHandler::passMouseDownEventToWidget): Here is where 
614         we need to set m_mousePressed to false if lastEventIsMouseUp() is 
615         true.
616
617 2007-01-26  David Hyatt  <hyatt@apple.com>
618
619         Fix for style regression caused by strictness checking of the number of properties.  This caused code like:
620         "width: 20 px" to fail, because we interpreted it as two values and rejected it.  Our old code allowed 20 to be
621         used like a pixel value and then ignored the orphaned unit.
622
623         This patch actually scans the list of values looking for orphaned units and reattaches them to the numeric
624         values that they should correspond to.  This means rules like "width: 5 em" will now work in quirks mdoe and
625         the "em" unit type will be honored.
626
627         Reviewed by beth
628
629         * WebCore.xcodeproj/project.pbxproj:
630         * css/cssparser.cpp:
631         (WebCore::unitFromString):
632         (WebCore::CSSParser::checkForOrphanedUnits):
633         (WebCore::CSSParser::parseValue):
634         * css/cssparser.h:
635         (WebCore::ValueList::valueAt):
636         (WebCore::ValueList::deleteValueAt):
637
638 2007-01-26  George Staikos  <staikos@kde.org>
639
640         Reviewed by Zack.
641
642         Qt implementation.
643
644         * WebCore.pro:
645         * platform/qt/FontPlatformDataQt.cpp:
646         (WebCore::FontPlatformData::FontPlatformData):
647         * platform/qt/ScrollViewQt.cpp:
648         (WebCore::ScrollView::scrollbarUnderMouse):
649
650 2007-01-26  Brady Eidson  <beidson@apple.com>
651
652         Reviewed by Anders' rubberstamp
653         
654         Warning about unreferenced formal parameter caused compile to fail
655
656         * platform/cf/RetainPtr.h:
657         (WebCore::adoptCFReference):
658
659 2007-01-26  Darin Adler  <darin@apple.com>
660
661         Reviewed by Brady.
662
663         - fix <rdar://problem/4956688> move Mac-specific part of icon code into IconMac
664         - fix a GC-compatibility problem in the icon code I noticed by code inspection
665
666         * platform/FileChooser.cpp: (WebCore::FileChooser::chooseIcon): Removed Mac-specific
667         path check -- that's in newIconForFile now.
668
669         * platform/graphics/Icon.h: Changed the image to be a RetainPtr. The old code was
670         using -[NSObject retain] which is not good enough for a pointer in a C++ object.
671         * platform/graphics/mac/IconMac.mm:
672         (WebCore::Icon::Icon): Got rid of unneeded code to do what RetainPtr does for us.
673         (WebCore::Icon::~Icon): Ditto.
674         (WebCore::Icon::newIconForFile): Added check for non-absolute file names. Updated
675         for use of RetainPtr. Use constructor that takes NSImage.
676         (WebCore::Icon::paint): Add get() calls needed now that we are using a RetainPtr.
677
678         * WebCore.xcodeproj/project.pbxproj: Let Xcode do its thing.
679
680 2007-01-26  Alexey Proskuryakov  <ap@webkit.org>
681
682         Reviewed by Maciej.
683
684         http://bugs.webkit.org/show_bug.cgi?id=12385
685         Assertion failure when loading subresources from "data:" frames
686
687         Test: fast/loader/opaque-base-url.html
688
689         * platform/KURL.cpp:
690         (WebCore::KURL::init): Make the URL invalid if it's relative, but has an opaque or empty base.
691
692 2007-01-26  Dex Deacon  <occupant4@gmail.com>
693
694         Reviewed by Darin.
695
696         * page/EventHandler.cpp:
697         (WebCore::EventHandler::handleMouseMoveEvent):
698         Removed a call to invalidateClick(), since we don't want to cancel a
699         click if the mouse moves.
700
701 2007-01-26  Darin Adler  <darin@apple.com>
702
703         * css/MediaQueryEvaluator.cpp:
704         (WebCore::MediaQueryEvaluator::mediaTypeMatchSpecific):
705         Oops, forgot a !.
706
707 2007-01-26  Darin Adler  <darin@apple.com>
708
709         Patch by Nate Begeman.
710         Reviewed by Darin and Maciej.
711
712         - <rdar://problem/4946877> Avoid unnecessary allocations in CSS, patch attached (12401)
713           http://bugs.webkit.org/show_bug.cgi?id=12401
714
715         * css/MediaQueryEvaluator.h: Add mediaTypeMatchSpecific, a function that
716         takes a char* to avoid creating and destroying a String for simple media
717         type queries.
718         * css/MediaQueryEvaluator.cpp:
719         (WebCore::MediaQueryEvaluator::mediaTypeMatchSpecific): Added. Besides
720         avoiding the conversion to String, this also doesn't have the special
721         case code to handle "" and "all".
722
723         * css/cssstyleselector.cpp: (WebCore::CSSStyleSelector::matchUARules):
724         Call mediaTypeMatchSpecific here when deciding whether to use the
725         print version of the user agent style sheet.
726
727         * loader/Cache.cpp: (WebCore::Cache::requestResource): Don't convert to
728         a string and back to a KURL when calling createResource. Avoids reparsing
729         the URL string.
730
731 2007-01-26  Zack Rusin  <zrusin@trolltech.com>
732
733         Reviewed by Lars
734
735         Add history related classes to the project file.
736
737         * WebCore.pro:
738
739 2007-01-26  Zack Rusin  <zack@kde.org>
740
741         Reviewed by Lars
742
743         Introduce PlatformScrollBar and try to make 
744         the scrollbar behavior a little more sane.
745
746         * WebCore.pro:
747         * platform/qt/PlatformScrollBarQt.cpp: Added.
748         (WebCore::Scrollbar::Scrollbar):
749         (WebCore::Scrollbar::setSteps):
750         (WebCore::Scrollbar::scroll):
751         (WebCore::Scrollbar::setValue):
752         (WebCore::Scrollbar::setProportion):
753         (WebCore::PlatformScrollbar::PlatformScrollbar):
754         (WebCore::PlatformScrollbar::~PlatformScrollbar):
755         (WebCore::PlatformScrollbar::width):
756         (WebCore::PlatformScrollbar::height):
757         (WebCore::PlatformScrollbar::setEnabled):
758         (WebCore::PlatformScrollbar::paint):
759         (WebCore::PlatformScrollbar::updateThumbPosition):
760         (WebCore::PlatformScrollbar::updateThumbProportion):
761         (WebCore::PlatformScrollbar::setRect):
762         * platform/qt/ScrollViewQt.cpp:
763         (WebCore::ScrollView::addChild):
764         * platform/qt/TemporaryLinkStubs.cpp:
765         (WebCore::PlatformMouseEvent::PlatformMouseEvent):
766
767 2007-01-26  Mitz Pettel  <mitz@webkit.org>
768
769         Reviewed by Darin.
770
771         - fix http://bugs.webkit.org/show_bug.cgi?id=11109
772           REGRESSION (r15471): menus are offset on eink.com
773           <rdar://problem/4824760>
774
775         Changed offset{Left,Top} to match Firefox. If the body element is statically
776         positioned, it is still returned as the offsetParent of elements whose containing
777         block is the initial containing block (the root), but their offset{Left,Top} are
778         relative to the root. If the body element is positioned, then offsets are relative
779         to it. The body's own offset{Left,Top} are always 0. 
780
781         Test: fast/dom/Element/offsetLeft-offsetTop-body-quirk.html
782
783         * rendering/RenderObject.cpp:
784         (WebCore::RenderObject::offsetLeft):
785         (WebCore::RenderObject::offsetTop):
786
787 2007-01-26  Mitz Pettel  <mitz@webkit.org>
788
789         Reviewed by Darin and Maciej.
790
791         - fix http://bugs.webkit.org/show_bug.cgi?id=10983
792           REGRESSION (r12290): Drop shadow of flickr photo note is positioned incorrectly the second time it's shown
793
794         Test: fast/dynamic/staticY.html
795
796         * rendering/RenderBlock.cpp:
797         (WebCore::RenderBlock::layoutPositionedObjects): Avoid marking the object's
798         parents, since they have already been laid out.
799         * rendering/RenderBox.cpp:
800         (WebCore::RenderBox::setStaticY): Added a call to setChildNeedsLayout() to
801         ensure relayout by this box's container (third and fourth cases in the
802         layout test).
803         * rendering/RenderBox.h:
804         * rendering/RenderObject.cpp:
805         (WebCore::RenderObject::markContainingBlocksForLayout): For positioned objects
806         with static y, also mark the object's parent to ensure that it recomputes
807         the static y value (first case in the layout test).
808
809 2007-01-26  Lars Knoll <lars@trolltech.com>
810
811         Reviewed by Zack
812
813         Get rid of FrameQtClient. It's unused since we moved over
814         to the loader.
815
816         * WebCore.pro:
817         * page/qt/FrameQt.cpp:
818         (WebCore::FrameQt::FrameQt):
819         * page/qt/FrameQt.h:
820         * page/qt/FrameQtClient.cpp: Removed.
821         * page/qt/FrameQtClient.h: Removed.
822         * platform/network/ResourceHandleInternal.h:
823         * platform/network/qt/ResourceHandleManagerQt.cpp:
824         (WebCore::RequestQt::RequestQt):
825         (WebCore::ResourceHandleManager::add):
826         * platform/network/qt/ResourceHandleManagerQt.h:
827         * platform/network/qt/ResourceHandleQt.cpp:
828         (WebCore::ResourceHandle::start):
829
830 2007-01-26  Zack Rusin  <zack@kde.org>
831
832         Fix the compile
833
834         * WebCore.pro:
835
836 2007-01-26  Adam Roben  <aroben@apple.com>
837
838         Reviewed by Maciej.
839
840         Fixed <rdar://problem/4946499>, which made it impossible to tab
841         forward into the left frame of tivofaq.com after tabbing out of the
842         document.
843
844         * page/FocusController.cpp:
845         (WebCore::FocusController::advanceFocus): Clear the focused frame
846         before passing off focus to Chrome so that when we re-enter the
847         document we start at the main frame instead of the last focused frame.
848
849 2007-01-25  Rob Buis  <buis@kde.org>
850
851         Reviewed by olliej.
852
853         http://bugs.webkit.org/show_bug.cgi?id=11911
854         SVG exhibits double-text-selection behavior
855
856         Fix selection height of the inline text boxes for svg.
857
858         * WebCore.xcodeproj/project.pbxproj:
859         * rendering/InlineTextBox.cpp:
860         (WebCore::InlineTextBox::selectionTop):
861         (WebCore::InlineTextBox::selectionHeight):
862         (WebCore::InlineTextBox::selectionRect):
863         (WebCore::InlineTextBox::paintSelection):
864         (WebCore::InlineTextBox::paintMarkedTextBackground):
865         (WebCore::InlineTextBox::paintCustomHighlight):
866         (WebCore::InlineTextBox::paintSpellingOrGrammarMarker):
867         (WebCore::InlineTextBox::paintTextMatchMarker):
868         * rendering/InlineTextBox.h:
869         * rendering/RenderSVGInlineText.cpp:
870         (WebCore::RenderSVGInlineText::createInlineTextBox):
871         * rendering/RenderSVGInlineText.h:
872         * rendering/RenderText.cpp:
873         (WebCore::RenderText::createInlineTextBox):
874         (WebCore::RenderText::createInlineBox):
875         * rendering/RenderText.h:
876         * rendering/SVGInlineTextBox.cpp: Added.
877         (WebCore::SVGInlineTextBox::selectionTop):
878         (WebCore::SVGInlineTextBox::selectionHeight):
879         * rendering/SVGInlineTextBox.h: Added.
880         (WebCore::SVGInlineTextBox::SVGInlineTextBox):
881
882 2007-01-26  Zack Rusin  <zack@kde.org>
883
884         Reviewed by Lars
885
886         Fix drawing of tiled images.
887
888         * WebCore.pro:
889         * platform/graphics/qt/ImageQt.cpp:
890         (WebCore::BitmapImage::drawPattern):
891
892 2007-01-26  Zack Rusin  <zack@kde.org>
893
894         Reviewed by Lars
895
896         Fixing image loading - we decode QImages
897         but render QPixmaps now. Implement Icon
898         class
899
900         * platform/graphics/BitmapImage.h:
901         * platform/graphics/Icon.h:
902         * platform/graphics/Image.h:
903         (WebCore::Image::getPixmap):
904         * platform/graphics/qt/IconQt.cpp:
905         (WebCore::Icon::Icon):
906         (WebCore::Icon::~Icon):
907         (WebCore::Icon::newIconForFile):
908         (WebCore::Icon::paint):
909         * platform/graphics/qt/ImageDecoderQt.cpp:
910         (WebCore::ImageDecoderQt::ImageData::ImageData):
911         (WebCore::ImageDecoderQt::ReadContext::read):
912         (WebCore::ImageDecoderQt::ReadContext::readImageLines):
913         (WebCore::ImageDecoderQt::reset):
914         (WebCore::ImageDecoderQt::imageAtIndex):
915         * platform/graphics/qt/ImageDecoderQt.h:
916         * platform/graphics/qt/ImageQt.cpp:
917         (WebCore::BitmapImage::drawPattern):
918         (WebCore::BitmapImage::getPixmap):
919         * platform/graphics/qt/ImageSourceQt.cpp:
920         (WebCore::ImageSource::createFrameAtIndex):
921
922 2007-01-25  Justin Garcia  <justin.garcia@apple.com>
923
924         Reviewed by oliver
925         
926         <http://bugs.webkit.org/show_bug.cgi?id=12409>
927         REGRESSION (r19039): Drag caret isn't cleared after a drop
928
929         No new layout tests because the regression was
930         caught by current layout tests.
931
932         * page/DragController.cpp:
933         (WebCore::DragController::concludeDrag): Clear the drag caret.
934
935 2007-01-25  Darin Adler  <darin@apple.com>
936
937         Reviewed and landed by Geoffrey Garen.
938
939         - fix http://bugs.webkit.org/show_bug.cgi?id=12342
940           REGRESSION: destroying a frame from its own script causes various crashes
941
942         * bindings/js/kjs_window.cpp: (KJS::ScheduledAction::execute):
943         Use RefPtr for the frame and the interpreter object so they don't get deleted
944         out from underneath us.
945
946         * bindings/js/kjs_proxy.cpp: (WebCore::KJSProxy::evaluate):
947         Add a check for a page of 0. This was the only call site for the
948         addMessageToConsole function that did not have a check for a page of 0.
949
950 2007-01-25 Dirk Mueller  <mueller@kde.org>
951
952         Reviewed and merged by Beth.
953
954         Fix for <rdar://problem/4921692> not processing comments inside a 
955         title element leads to XSS (for at least BlogSpot)
956
957         This is equivalent to commit 626791 in the KDE tree. Basically, the 
958         patch allows comment parsing in titles to avoid capturing a 
959         <script> tag by accident.
960
961         * html/HTMLTokenizer.cpp:
962         (WebCore::HTMLTokenizer::parseSpecial):
963         (WebCore::HTMLTokenizer::parseComment):
964
965 2007-01-25  Darin Adler  <darin@apple.com>
966
967         * ksvg2/svg/SVGPreserveAspectRatio.cpp: Add a couple of comments.
968
969 2007-01-25  Darin Adler  <darin@apple.com>
970
971         Reviewed by Maciej.
972
973         - fix http://bugs.webkit.org/show_bug.cgi?id=12365
974           Reproducible crash in WebCore::SVGPreserveAspectRatio::parsePreserveAspectRatio
975           in svg/W3C-SVG-1.1/animate-elem-40-t.svg under guard malloc
976         - fix bug where the parser accepts "meet" or "slice" as an entire string
977         - fix bug where "slice" is ignored if the old alignment was "none"
978           even if the newly-parsed alignment is something other than "none", and
979           "slice" is not ignored if the old alignment was not "none", but the
980           newly-parsed alignment is "none"
981         - optimize to only call notifyAttributeChange if the attribute actually changed
982
983         Test: svg/dom/preserve-aspect-ratio-parser-test.html
984
985         * ksvg2/svg/SVGPreserveAspectRatio.cpp:
986         (WebCore::checkString): Added an overload for using char* constants which is
987         much simpler than the old one, and almost as fast.
988         (WebCore::SVGPreserveAspectRatio::parsePreserveAspectRatio): Fail if there's no
989         more text after "defer". Fail if there's neither "none" nor an x/y specified.
990         Check that there's more text before looking at the "m" and "s" for "meet" and
991         "slice". Merged the failure and success cases. Only call notifyAttributeChange
992         if something changed.
993
994         I think all the "optimized" code where we check the first character before
995         calling checkString isn't really helpful, but I decided to leave it as-is
996         for now.
997
998 2007-01-25  Lars Knoll <lars@trolltech.com>
999
1000         Reviewed by Zack
1001
1002         Trivial implementation of getMIMETypeForExtension.
1003         Use the above method in the ResourceHandleManager to set
1004         a mimetype on Resources that don't have one set (which
1005         includes everything loaded from local disk).
1006
1007         Should fix quite a few test cases :)
1008
1009         * platform/network/qt/ResourceHandleManagerQt.cpp:
1010         (WebCore::ResourceHandleManager::receivedResponse):
1011         * platform/qt/MimeTypeRegistryQt.cpp:
1012         (WebCore::):
1013         (WebCore::MimeTypeRegistry::getMIMETypeForExtension):
1014
1015 2007-01-25 Harald Fernengel <harald@trolltech.com>
1016
1017         Reviewed by zack
1018
1019         Compile on platforms where qreal is not a double.
1020
1021         * platform/graphics/qt/AffineTransformQt.cpp:
1022         (WebCore::AffineTransform::map):
1023
1024 2007-01-25  Zack Rusin  <zack@kde.org>
1025
1026         Reviewed by Lars.
1027
1028         Add wheel event handling and make explicit usage
1029         of the EventHandler.
1030
1031         * WebCore.pro:
1032         * page/qt/EventHandlerQt.cpp:
1033         (WebCore::EventHandler::focusDocumentView):
1034         (WebCore::EventHandler::passWidgetMouseDownEventToWidget):
1035         (WebCore::EventHandler::passMouseDownEventToWidget):
1036         (WebCore::EventHandler::lastEventIsMouseUp):
1037         (WebCore::EventHandler::handleMouseUp):
1038         * platform/PlatformWheelEvent.h:
1039         * platform/qt/ScrollViewCanvasQt.cpp:
1040         (WebCore::ScrollViewCanvasQt::ScrollViewCanvasQt):
1041         (WebCore::ScrollViewCanvasQt::mousePressEvent):
1042         (WebCore::ScrollViewCanvasQt::wheelEvent):
1043         (WebCore::ScrollViewCanvasQt::dragEnterEvent):
1044         (WebCore::ScrollViewCanvasQt::dragLeaveEvent):
1045         (WebCore::ScrollViewCanvasQt::dragMoveEvent):
1046         * platform/qt/ScrollViewCanvasQt.h:
1047         * platform/qt/ScrollViewQt.cpp:
1048         (WebCore::ScrollView::wheelEvent):
1049         * platform/qt/WheelEventQt.cpp: Added.
1050         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
1051
1052 2007-01-25  Rob Buis  <buis@kde.org>
1053
1054         Reviewed by Maciej.
1055
1056         http://bugs.webkit.org/show_bug.cgi?id=12391
1057         SVG containers with viewports should respect overflow when hit testing
1058
1059         Take into account the overflow property when hit testing <svg>.
1060
1061         * rendering/RenderSVGContainer.cpp:
1062         (WebCore::RenderSVGContainer::nodeAtPoint):
1063
1064 2007-01-23  Alice Liu  <alice.liu@apple.com>
1065
1066         Reviewed by Maciej.
1067
1068         fixed <rdar://problem/4808039> REGRESSION: eBay ID check never completes
1069         Also known as http://bugs.webkit.org/show_bug.cgi?id=11230
1070
1071         * bindings/js/kjs_window.cpp:
1072         It's not necessary to check safeScript when doing a location.replace, .reload, or .assign
1073         (KJS::Location::getOwnPropertySlot):
1074         (KJS::LocationFunc::callAsFunction):
1075
1076 2007-01-25  Alice Liu  <alice.liu@apple.com>
1077
1078         Reviewed by Geoff and Adele.
1079
1080         fixed <rdar://problem/4866655> REGRESSION: Copying out of Calculator & CIFIlterWidget is broken on 9A320
1081
1082         * editing/Editor.cpp:
1083         (WebCore::Editor::canDHTMLCut):
1084         (WebCore::Editor::canDHTMLCopy):
1085         (WebCore::Editor::tryDHTMLCopy):
1086         (WebCore::Editor::tryDHTMLCut):
1087         Reverting some mistakes made in r17504:
1088         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
1089         Anything else in r17503 that used to call mayCopy now calls (!)selectionController::isInPasswordField.
1090
1091         * editing/JSEditor.cpp:
1092         copy via JS should be enabled as long as selection is not in a password field.  a range selection shouldn't be required. 
1093
1094 2007-01-24  Adele Peterson  <adele@apple.com>
1095
1096         Reviewed by Brady and Oliver.
1097
1098         Fix for <rdar://problem/4953504> When the keydown event changes focus, the keypress event should go to the new focused node
1099
1100         Test: fast/events/keydown-keypress-focus-change.html
1101
1102         * page/EventHandler.cpp:
1103         (WebCore::eventTargetNodeForDocument): Added for convenience.
1104         (WebCore::EventHandler::keyEvent): Moved from EventHandlerMac.mm.  After dispatching the keyDown event,
1105          recheck the target node for the keyPress event in case its changed.
1106         * page/EventHandler.h:
1107         * page/mac/EventHandlerMac.mm: (WebCore::EventHandler::keyEvent):
1108           Moved the bulk of this code to EventHandler.cpp.
1109
1110 2007-01-24  Geoffrey Garen  <ggaren@apple.com>
1111
1112         New forwarding header. No review necessary.
1113
1114         * ForwardingHeaders/kjs/ustring.h: Added.
1115
1116 2007-01-24  Oliver Hunt  <oliver@apple.com>
1117
1118         Reviewed by Maciej.
1119
1120         Migrating more drag state information to WebCore
1121
1122         * page/DragController.cpp:
1123         * page/DragController.h:
1124         (WebCore::DragController::dragOperation):
1125         (WebCore::DragController::setDraggingImageURL):
1126         (WebCore::DragController::draggingImageURL):
1127         (WebCore::DragController::setDragOffset):
1128         (WebCore::DragController::dragOffset):
1129
1130 2007-01-24  Darin Adler  <darin@apple.com>
1131
1132         Reviewed by Adele.
1133
1134         - fix http://bugs.webkit.org/show_bug.cgi?id=12331
1135           REGRESSION(r18951): Selecting text in a textarea makes the page scroll
1136
1137         Test: fast/events/autoscroll.html
1138
1139         * rendering/RenderLayer.cpp: (WebCore::RenderLayer::autoscroll):
1140         Adjust position to be relative to the object's corner for the hit test, but not for the
1141         scrollRectToVisible call. The previous version accidentally re-used the version that was
1142         adjusted for the hit test.
1143
1144 2007-01-24  Beth Dakin  <bdakin@apple.com>
1145
1146         Reviewed by Geoff.
1147
1148         Fix for <rdar://problem/4948128> REGRESSION: A crash occurs at 
1149         WebCore::Frame::view() after completing a query at mapquest.com 
1150         then switching to Bookmarks view
1151
1152         This is just a null-check. If you are in strict mode and ask for 
1153         the clientWidth or clientHeight after the document was removed from 
1154         it's parent, we no longer have a frameView, so we have to null-
1155         check it. I added null checks for the FrameView in some other 
1156         places where it seems like we could potentially run into this 
1157         issue.
1158
1159         * bindings/objc/DOMHTML.mm:
1160         (-[DOMHTMLInputElement _rectOnScreen]):
1161         * bridge/mac/WebCoreAXObject.mm:
1162         (-[WebCoreAXObject accessibilityAttributeValue:]):
1163         * dom/ContainerNode.cpp:
1164         (WebCore::ContainerNode::getUpperLeftCorner):
1165         * dom/Element.cpp:
1166         (WebCore::Element::clientWidth): Actual bug fix here!
1167         (WebCore::Element::clientHeight): And here!
1168         * ksvg2/svg/SVGLength.cpp:
1169         (WebCore::SVGLength::PercentageOfViewport):
1170         * loader/FrameLoader.cpp:
1171         (WebCore::FrameLoader::createJavaAppletWidget):
1172         * page/mac/WebCoreFrameBridge.mm:
1173         (-[WebCoreFrameBridge computePageRectsWithPrintWidthScaleFactor:printHeight:]):
1174         * rendering/RenderLayer.cpp:
1175         (WebCore::RenderLayer::windowClipRect):
1176         (WebCore::RenderLayer::updateOverflowStatus):
1177         (WebCore::frameVisibleRect):
1178         * rendering/RenderListBox.cpp:
1179         (WebCore::RenderListBox::windowClipRect):
1180         * rendering/RenderTable.cpp:
1181         (WebCore::RenderTable::layout):
1182
1183 2007-01-24  Maciej Stachowiak  <mjs@apple.com>
1184
1185         Not reviewed, just removing accidentally committed file.
1186
1187         - removed file that shouldn't be there
1188
1189         * Image Viewer/Image Viewer.aps: Removed.
1190
1191 2007-01-24  Anders Carlsson  <acarlsson@apple.com>
1192
1193         Reviewed by Geoff and Adam.
1194
1195         <rdar://problem/4922655>
1196         http://galeri.milliyet.com.tr/ reproducibly crashes Safari
1197         
1198         * loader/FrameLoader.cpp:
1199         (WebCore::FrameLoader::requestFrame):
1200         If the frame already exists, defer the navigation so that we won't end up replacing the document
1201         while we're parsing it. This is similar to what setting window.location ends up doing.
1202
1203 2007-01-25  Mark Rowe  <mrowe@apple.com>
1204
1205         Reviewed by Darin.
1206
1207         * Info.plist: Update copyright string.
1208
1209 2007-01-24  Justin Garcia  <justin.garcia@apple.com>
1210
1211         Reviewed by harrison
1212
1213         <rdar://problem/4916235>
1214         eBay Editor: Crash occurs at WebCore::Range::startPosition() after applying ordered list styling to selected text
1215         <rdar://problem/4857269>
1216         REGRESSION: editing/execCommand/create-list-from-range-selection.html no longer works as intended
1217         <rdar://problem/4916583>
1218         eBay Editor: Removing a indent from a list item actually deletes the list item instead
1219         <rdar://problem/4928635>
1220         designMode outdent causes crash (11750)
1221
1222         * editing/CompositeEditCommand.cpp:
1223         (WebCore::CompositeEditCommand::moveParagraphs): Fixed br insertion
1224         after the pruning of empty containers left over after the paragraph
1225         to move is removed.
1226         * editing/DeleteSelectionCommand.cpp:
1227         (WebCore::DeleteSelectionCommand::DeleteSelectionCommand): There are
1228         bugs that leave the wrong number of line breaks after a deletion 
1229         that expands to include special elements (lists/tables).  Added 
1230         a workaround so that moveParagraphs can avoid these until they 
1231         are fixed.
1232         (WebCore::DeleteSelectionCommand::initializeStartEnd): Ditto.
1233         (WebCore::DeleteSelectionCommand::initializePositionData): Ditto.
1234         * editing/DeleteSelectionCommand.h:
1235         * editing/TextIterator.cpp:
1236         (WebCore::TextIterator::advance): We used to not call exitNode for
1237         ancestors of a node where the next node in a pre-order traversal is 
1238         the ranges's pastEndNode().  This is only correct for ancestors that
1239         contain the end of the range.
1240         (WebCore::shouldEmitNewlineAfterNode): Added, we should only emit newlines
1241         after blocks that have VisiblePositions after them.  VisiblePosition creation
1242         though is too expensive to do here, what I added here is an OK substitute.
1243         (WebCore::shouldEmitNewlineBeforeNode): Added.  No special logic yet.
1244         (WebCore::TextIterator::handleNonTextNode): Call shouldEmitNewlineBeforeNode.
1245         (WebCore::TextIterator::exitNode): Call shouldEmitNewlineAfterNode.
1246         (WebCore::SimplifiedBackwardsTextIterator::handleNonTextNode): Call
1247         shouldEmitNewlineAfterNode.
1248
1249 2007-01-24  Darin Adler  <darin@apple.com>
1250
1251         Reviewed by Mark Rowe.
1252
1253         * WebCore.xcodeproj/project.pbxproj: Changed to /usr/sbin/sysctl
1254         so we don't rely on people's paths.
1255
1256 2007-01-24  Darin Adler  <darin@apple.com>
1257
1258         Reviewed by Adele.
1259
1260         - a couple minor tweaks to recently-changed things
1261
1262         * dom/Document.h: Use HTMLHeadElement as type for the head function.
1263         * dom/Document.cpp: (WebCore::Document::head):
1264
1265         * ksvg2/svg/SVGElementInstance.cpp:
1266         (WebCore::SVGElementInstance::~SVGElementInstance): Change loop to
1267         a for loop and use a local variable for document.
1268
1269 2007-01-24  Oliver Hunt  <oliver@apple.com>
1270
1271         Reviewed by Adele.
1272
1273         Fixes DragController to allow a null target Document.
1274         This is encountered in new tabs/windows that have not 
1275         loaded any page
1276
1277         * page/DragController.cpp:
1278         (WebCore::documentAtPoint):
1279         (WebCore::DragController::tryDocumentDrag):
1280         (WebCore::DragController::operationForLoad):
1281         (WebCore::DragController::concludeDrag):
1282         * page/mac/DragControllerMac.mm:
1283         (WebCore::DragController::dragOperation):
1284
1285 2007-01-24  Sam Weinig  <sam@webkit.org>
1286
1287         Reviewed by Mitz.
1288
1289         Patch for http://bugs.webkit.org/show_bug.cgi?id=12394
1290         Cleanup RenderBox
1291
1292         No functionality changes, just a good old fashion cleanup,
1293         thus no tests.
1294
1295         * rendering/RenderBox.cpp:
1296         (WebCore::RenderBox::RenderBox):
1297         (WebCore::RenderBox::setStyle):
1298         (WebCore::RenderBox::destroy):
1299         (WebCore::RenderBox::setPos):
1300         (WebCore::RenderBox::calcBorderBoxWidth):
1301         (WebCore::RenderBox::calcBorderBoxHeight):
1302         (WebCore::RenderBox::calcContentBoxWidth):
1303         (WebCore::RenderBox::calcContentBoxHeight):
1304         (WebCore::RenderBox::nodeAtPoint):
1305         (WebCore::RenderBox::paintRootBoxDecorations):
1306         (WebCore::RenderBox::paintBoxDecorations):
1307         (WebCore::RenderBox::paintBackgrounds):
1308         (WebCore::RenderBox::paintBackground):
1309         (WebCore::cacluateBackgroundSize):
1310         (WebCore::RenderBox::paintBackgroundExtended):
1311         (WebCore::RenderBox::getOverflowClipRect):
1312         (WebCore::RenderBox::getClipRect):
1313         (WebCore::RenderBox::containingBlockWidth):
1314         (WebCore::RenderBox::absolutePosition):
1315         (WebCore::RenderBox::dirtyLineBoxes):
1316         (WebCore::RenderBox::position):
1317         (WebCore::RenderBox::getAbsoluteRepaintRect):
1318         (WebCore::RenderBox::computeAbsoluteRepaintRect):
1319         (WebCore::RenderBox::repaintDuringLayoutIfMoved):
1320         (WebCore::RenderBox::relativePositionOffsetX):
1321         (WebCore::RenderBox::relativePositionOffsetY):
1322         (WebCore::RenderBox::calcWidth):
1323         (WebCore::RenderBox::calcWidthUsing):
1324         (WebCore::RenderBox::sizesToIntrinsicWidth):
1325         (WebCore::RenderBox::calcHorizontalMargins):
1326         (WebCore::RenderBox::calcHeight):
1327         (WebCore::RenderBox::calcPercentageHeight):
1328         (WebCore::RenderBox::calcReplacedWidthUsing):
1329         (WebCore::RenderBox::calcReplacedHeightUsing):
1330         (WebCore::RenderBox::availableHeightUsing):
1331         (WebCore::RenderBox::calcVerticalMargins):
1332         (WebCore::RenderBox::containingBlockWidthForPositioned):
1333         (WebCore::RenderBox::calcAbsoluteHorizontal):
1334         (WebCore::RenderBox::calcAbsoluteHorizontalValues):
1335         (WebCore::RenderBox::calcAbsoluteVertical):
1336         (WebCore::RenderBox::calcAbsoluteVerticalValues):
1337         (WebCore::RenderBox::calcAbsoluteHorizontalReplaced):
1338         (WebCore::RenderBox::caretRect):
1339         * rendering/RenderBox.h:
1340         (WebCore::RenderBox::setOverrideSize):
1341         (WebCore::RenderBox::width):
1342         (WebCore::RenderBox::height):
1343         (WebCore::RenderBox::setWidth):
1344         (WebCore::RenderBox::setHeight):
1345         (WebCore::RenderBox::inlineBoxWrapper):
1346         (WebCore::RenderBox::setInlineBoxWrapper):
1347         (WebCore::RenderBox::stretchesToViewHeight):
1348         (WebCore::RenderBox::setStaticX):
1349         (WebCore::RenderBox::setStaticY):
1350
1351 2007-01-24  Eric Seidel  <eric@webkit.org>
1352
1353         Reviewed by ap.
1354
1355         Converted SVGTransform from being Shared<T> to a POD type.
1356
1357         No functional changes, thus no tests.
1358
1359         * bindings/scripts/CodeGenerator.pm:
1360         * bindings/scripts/CodeGeneratorJS.pm:
1361         * ksvg2/misc/SVGTimer.cpp:
1362         (WebCore::baseValueTransformList):
1363         * ksvg2/svg/SVGAnimateTransformElement.cpp:
1364         (WebCore::SVGAnimateTransformElement::storeInitialValue):
1365         (WebCore::SVGAnimateTransformElement::resetValues):
1366         (WebCore::SVGAnimateTransformElement::updateCurrentValue):
1367         (WebCore::SVGAnimateTransformElement::handleStartCondition):
1368         (WebCore::SVGAnimateTransformElement::applyAnimationToValue):
1369         (WebCore::SVGAnimateTransformElement::parseTransformValue):
1370         * ksvg2/svg/SVGAnimateTransformElement.h:
1371         * ksvg2/svg/SVGLinearGradientElement.cpp:
1372         (WebCore::SVGLinearGradientElement::collectGradientProperties):
1373         * ksvg2/svg/SVGPatternElement.cpp:
1374         (WebCore::SVGPatternElement::collectPatternProperties):
1375         * ksvg2/svg/SVGRadialGradientElement.cpp:
1376         (WebCore::SVGRadialGradientElement::collectGradientProperties):
1377         * ksvg2/svg/SVGSVGElement.cpp:
1378         (WebCore::SVGSVGElement::createSVGTransform):
1379         (WebCore::SVGSVGElement::createSVGTransformFromMatrix):
1380         * ksvg2/svg/SVGSVGElement.h:
1381         * ksvg2/svg/SVGStyledTransformableElement.cpp:
1382         (WebCore::SVGStyledTransformableElement::updateLocalTransform):
1383         * ksvg2/svg/SVGTextElement.cpp:
1384         (WebCore::SVGTextElement::updateLocalTransform):
1385         * ksvg2/svg/SVGTransform.cpp:
1386         (SVGTransform::SVGTransform):
1387         (SVGTransform::isValid):
1388         * ksvg2/svg/SVGTransform.h:
1389         * ksvg2/svg/SVGTransform.idl:
1390         * ksvg2/svg/SVGTransformList.cpp:
1391         (SVGTransformList::SVGTransformList):
1392         (SVGTransformList::createSVGTransformFromMatrix):
1393         (SVGTransformList::consolidate):
1394         (SVGTransformList::concatenate):
1395         * ksvg2/svg/SVGTransformList.h:
1396         * ksvg2/svg/SVGTransformable.cpp:
1397         (WebCore::SVGTransformable::parseTransformAttribute):
1398
1399 2007-01-24  Mark Rowe  <mrowe@apple.com>
1400
1401         Reviewed by Eric.
1402
1403         Plug another bunch of SVG memory leaks.
1404
1405         * ksvg2/misc/SVGDocumentExtensions.cpp:
1406         (WebCore::SVGDocumentExtensions::~SVGDocumentExtensions): Delete memory we have allocated.
1407         (WebCore::SVGDocumentExtensions::removePendingResource): Return an auto_ptr to show that we are transferring ownership.
1408         * ksvg2/misc/SVGDocumentExtensions.h:
1409         * ksvg2/svg/SVGElement.cpp:
1410         (WebCore::SVGElement::insertedIntoDocument): Update for use of auto_ptr.
1411
1412 2007-01-23  Mark Rowe  <mrowe@apple.com>
1413
1414         Reviewed by Brady.
1415
1416         Plug thousands of node leaks seen running layout tests.
1417
1418         * ksvg2/svg/SVGElementInstance.cpp:
1419         (WebCore::SVGElementInstance::~SVGElementInstance): Disassociate ourselves from our children so they will
1420         be destroyed if we were the only thing referencing them.
1421         * ksvg2/svg/SVGUseElement.cpp:
1422         (WebCore::SVGUseElement::removedFromDocument):
1423         * ksvg2/svg/SVGUseElement.h:
1424
1425 2007-01-23  Alice Liu  <alice.liu@apple.com>
1426
1427         Reviewed by Brady.
1428
1429         * editing/Editor.cpp:
1430         (WebCore::Editor::appliedEditing):
1431         minor change.  removing unnecessary call to frame to fetch editor
1432
1433 2007-01-23  Mark Rowe  <mrowe@apple.com>
1434
1435         Reviewed by Adele.
1436
1437         http://bugs.webkit.org/show_bug.cgi?id=12375
1438         Bug 12375: REGRESSION(r19038): fast/dom/title-text-property-2.html failing
1439
1440         Fix regression by making setTitle/updateTitle/removeTitle logic match document.title
1441         specification at http://whatwg.org/specs/web-apps/current-work/#the-title1.
1442
1443         * dom/Document.cpp:
1444         (WebCore::Document::setTitle): Materialize a title element into the head if one doesn't exist when setting
1445         document.title.  Also update the contents of the title element when the title is set via document.title.
1446         (WebCore::Document::removeTitle): Update the title based on first title element in the head, if one exists.
1447         (WebCore::Document::head): Convenience method to retrieve the head element in an HTML document.
1448         * dom/Document.h:
1449
1450 2007-01-23  Beth Dakin  <bdakin@apple.com>
1451
1452         Reviewed by Hyatt.
1453
1454         Follow-up to the fix below for 4843226.
1455
1456         * rendering/RenderLayer.cpp:
1457         (WebCore::transparencyClipBox): Has to be recursive or we will miss 
1458         out on grandchildren!
1459
1460 2007-01-23  Oliver Hunt  <oliver@apple.com>
1461
1462         Reviewed by Adam.
1463
1464         Fixes dropping of files into safari
1465
1466         * page/DragController.cpp:
1467         (WebCore::DragController::performDrag):
1468
1469 2007-01-23  Brady Eidson  <beidson@apple.com>
1470
1471         Reviewed by Darin
1472
1473         Added a couple of CF things previously missed
1474
1475         * platform/network/ResourceError.h:
1476         * platform/network/ResourceHandle.h:
1477
1478 2007-01-23  Nikolas Zimmermann  <zimmermann@kde.org>
1479
1480         Reviewed by Maciej.
1481
1482         Fix evil genericContext() assertion, which occours sometimes when running DRT.
1483         Fixes: http://bugs.webkit.org/show_bug.cgi?id=12379
1484
1485         * bindings/scripts/CodeGeneratorJS.pm:
1486         * ksvg2/misc/SVGDocumentExtensions.h:
1487         (WebCore::SVGDocumentExtensions::genericContextMap):
1488         (WebCore::SVGDocumentExtensions::forgetGenericContext):
1489
1490 2007-01-23  Beth Dakin  <bdakin@apple.com>
1491
1492         Reviewed by Hyatt.
1493
1494         Fix for <rdar://problem/4843226> REGRESSION: Pull down menu appears 
1495         clipped at http://istweb.apple.com/
1496
1497         * rendering/RenderLayer.cpp:
1498         (WebCore::transparencyClipBox): Always unite with sibling rects.
1499
1500 2007-01-22  Justin Garcia  <justin.garcia@apple.com>
1501
1502         Reviewed by john
1503
1504         <rdar://problem/4920742>
1505         REGRESSION: GMail Editor: Attempting to remove formatting from selection results in a crash at WebCore::Range::checkDeleteExtract()
1506
1507         * dom/Range.cpp:
1508         (WebCore::Range::checkDeleteExtract): Return if there is no
1509         commonAncestor container or if commonAncestorContainer() throws
1510         an exception.
1511         * editing/Editor.cpp:
1512         (WebCore::Editor::removeFormattingAndStyle): Fixed a bug that reversed
1513         the order of the selected paragraphs.
1514
1515 2007-01-23  Nikolas Zimmermann  <zimmermann@kde.org>
1516
1517         Reviewed by Sam.
1518
1519         Fix dynamic creation/updates of markers, masks, clipPaths, and several tiny pattern issues.
1520         Added 16 (!) new layout tests covering quite some weird scenerios - Batik & Opera do have problems, we don't.
1521
1522         Fixes: http://bugs.webkit.org/show_bug.cgi?id=12380
1523         Fixes: svg/custom/image-with-transform-clip-filter.svg (filter shows up again)
1524
1525         Added: svg/custom/clip-path-child-changes.svg
1526         Added: svg/custom/clip-path-href-changes.svg
1527         Added: svg/custom/clip-path-units-changes.svg
1528         Added: svg/custom/deep-dynamic-updates.svg
1529         Added: svg/custom/js-late-clipPath-and-object-creation.svg
1530         Added: svg/custom/js-late-clipPath-creation.svg
1531         Added: svg/custom/js-late-marker-and-object-creation.svg
1532         Added: svg/custom/js-late-marker-creation.svg
1533         Added: svg/custom/js-late-mask-and-object-creation.svg
1534         Added: svg/custom/js-late-mask-creation.svg
1535         Added: svg/custom/js-update-pattern-child.svg
1536         Added: svg/custom/marker-changes.svg
1537         Added: svg/custom/marker-child-changes.svg
1538         Added: svg/custom/marker-viewBox-changes.svg
1539         Added: svg/custom/mask-changes.svg
1540         Added: svg/custom/mask-child-changes.svg
1541
1542         * ksvg2/misc/KCanvasRenderingStyle.cpp:
1543         (WebCore::KSVGPainterFactory::fillPaintServer):
1544         (WebCore::KSVGPainterFactory::strokePaintServer):
1545         * ksvg2/svg/SVGClipPathElement.cpp:
1546         (WebCore::SVGClipPathElement::notifyAttributeChange):
1547         * ksvg2/svg/SVGClipPathElement.h:
1548         * ksvg2/svg/SVGGradientElement.cpp:
1549         * ksvg2/svg/SVGGradientElement.h:
1550         * ksvg2/svg/SVGMarkerElement.cpp:
1551         (WebCore::SVGMarkerElement::canvasResource):
1552         (WebCore::SVGMarkerElement::notifyAttributeChange):
1553         * ksvg2/svg/SVGMarkerElement.h:
1554         * ksvg2/svg/SVGMaskElement.cpp:
1555         (WebCore::SVGMaskElement::notifyAttributeChange):
1556         * ksvg2/svg/SVGMaskElement.h:
1557         * ksvg2/svg/SVGStopElement.cpp:
1558         (WebCore::SVGStopElement::notifyAttributeChange):
1559         * ksvg2/svg/SVGStyledElement.cpp:
1560         (WebCore::SVGStyledElement::notifyAttributeChange):
1561         (WebCore::SVGStyledElement::notifyResourceParentIfExistant):
1562         (WebCore::SVGStyledElement::rebuildRenderer):
1563         * ksvg2/svg/SVGStyledElement.h:
1564         * ksvg2/svg/SVGUseElement.cpp:
1565         (WebCore::SVGUseElement::notifyAttributeChange):
1566         * platform/graphics/svg/SVGResource.cpp:
1567         (WebCore::SVGResource::invalidate):
1568         (WebCore::SVGResource::addClient):
1569         (WebCore::SVGResource::repaintClients):
1570         * platform/graphics/svg/SVGResource.h:
1571         * platform/graphics/svg/SVGResourceMarker.cpp:
1572         (WebCore::SVGResourceMarker::draw):
1573         (WebCore::SVGResourceMarker::cachedBounds):
1574         * platform/graphics/svg/SVGResourceMarker.h:
1575         * rendering/RenderPath.cpp:
1576         (WebCore::RenderPath::layout):
1577         (WebCore::RenderPath::getAbsoluteRepaintRect):
1578         (WebCore::RenderPath::paint):
1579         (WebCore::drawMarkerWithData):
1580         (WebCore::RenderPath::drawMarkersIfNeeded):
1581         * rendering/RenderPath.h:
1582         * rendering/RenderSVGContainer.cpp:
1583         (WebCore::RenderSVGContainer::paint):
1584         (WebCore::RenderSVGContainer::getAbsoluteRepaintRect):
1585         * rendering/RenderSVGImage.cpp:
1586         (WebCore::RenderSVGImage::paint):
1587         (WebCore::RenderSVGImage::getAbsoluteRepaintRect):
1588         * rendering/SVGInlineFlowBox.cpp:
1589         (WebCore::paintSVGInlineFlow):
1590
1591 2007-01-23  Adele Peterson  <adele@apple.com>
1592
1593         Reviewed by Darin.
1594         
1595         WebCore part of fix for <rdar://problem/4946753>REGRESSION: Inserting tabs is broken in Mail
1596
1597         In addition to this fix, I also reorganized some event handling code for keyPress events to
1598         prepare for another fix.  There's also just a little bit of unrelated cleanup.
1599         
1600         * dom/EventTargetNode.cpp: (WebCore::EventTargetNode::defaultEventHandler):
1601           Move tab focus behavior into new defaultKeyboardEventHandler method.
1602         
1603         * bridge/EditorClient.h: Added handleKeyPress.
1604         * editing/Editor.cpp:
1605         (WebCore::Editor::handleKeyPress): Added. Calls over to the client method.
1606         (WebCore::Editor::deleteRange): Removed unnecessary propogateDOMException.
1607         * editing/Editor.h: Added handleKeyPress.
1608         (WebCore::Editor::addToKillRing): Formatting cleanup.
1609         * editing/mac/EditorMac.mm: Removed unnecessary propogateDOMException.
1610         
1611         * page/EventHandler.cpp: (WebCore::EventHandler::defaultKeyboardEventHandler): Added. Checks
1612           the tabKeyCyclesThroughElements setting before advancing focus for tab key events.  Calls handleKeyPress.
1613         * page/EventHandler.h: Added defaultKeyboardEventHandler.
1614         
1615         * page/Page.cpp: (WebCore::Page::Page): Initialize m_tabKeyCyclesThroughElements to true.
1616         * page/Page.h: Added m_tabKeyCyclesThroughElements.
1617         (WebCore::Page::setTabKeyCyclesThroughElements): Added.
1618         (WebCore::Page::tabKeyCyclesThroughElements): Added.
1619         
1620         * platform/PlatformKeyboardEvent.h: Added ability to get NSEvent from PlatformKeyboardEvent.
1621         * platform/mac/KeyEventMac.mm: (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):
1622           Initialize m_macEvent to the NSEvent.
1623         
1624         * platform/graphics/svg/SVGImageEmptyClients.h: (WebCore::SVGEmptyEditorClient::handleKeyPress): Added.
1625
1626 2007-01-23  George Staikos  <staikos@kde.org>
1627
1628         Compile with a released Qt.
1629
1630         * platform/graphics/qt/ImageQt.cpp:
1631
1632 2007-01-23  Lars Knoll <lars@trolltech.com>
1633
1634         Reviewed by Zack
1635
1636         Widget and ScrollView do not own the Qt widgets
1637         anymore. Make sure they can handle the case of
1638         a null QWidget and never delete them.
1639
1640         * platform/qt/ScrollViewQt.cpp:
1641         (WebCore::ScrollView::setScrollArea):
1642         (WebCore::ScrollView::updateContents):
1643         (WebCore::ScrollView::visibleWidth):
1644         (WebCore::ScrollView::visibleHeight):
1645         (WebCore::ScrollView::visibleContentRect):
1646         (WebCore::ScrollView::setContentsPos):
1647         (WebCore::ScrollView::resizeContents):
1648         (WebCore::ScrollView::contentsX):
1649         (WebCore::ScrollView::contentsY):
1650         (WebCore::ScrollView::contentsWidth):
1651         (WebCore::ScrollView::contentsHeight):
1652         (WebCore::ScrollView::scrollOffset):
1653         (WebCore::ScrollView::scrollBy):
1654         (WebCore::ScrollView::hScrollbarMode):
1655         (WebCore::ScrollView::vScrollbarMode):
1656         (WebCore::ScrollView::setHScrollbarMode):
1657         (WebCore::ScrollView::setVScrollbarMode):
1658         * platform/qt/WidgetQt.cpp:
1659         (WebCore::WidgetPrivate::~WidgetPrivate):
1660         (WebCore::Widget::setQWidget):
1661
1662 2007-01-23  Zack Rusin  <zack@kde.org>
1663
1664         Forgot to add one new file to the build.
1665
1666         * WebCore.pro: Add dom/clipboard.cpp
1667
1668 2007-01-23  Zack Rusin  <zack@kde.org>
1669
1670         Fix the Qt build
1671
1672         * page/DragActions.h:
1673         * page/DragController.cpp:
1674         * platform/qt/DragDataQt.cpp:
1675         (WebCore::DragData::canSmartReplace):
1676         (WebCore::DragData::containsColor):
1677         (WebCore::DragData::containsPlainText):
1678         (WebCore::DragData::asPlainText):
1679         (WebCore::DragData::asColor):
1680         (WebCore::DragData::createClipboard):
1681         (WebCore::DragData::containsCompatibleContent):
1682         (WebCore::DragData::containsURL):
1683         (WebCore::DragData::asURL):
1684         (WebCore::DragData::asFragment):
1685         * platform/qt/FileChooserQt.cpp:
1686
1687 2007-01-23  Lars Knoll <lars@trolltech.com>
1688
1689         Reviewed by Maciej
1690
1691         Make the last remaining pieces of the FrameLoader platform 
1692         independent. Move most of the code over to WebFrameLoaderClient.
1693         Some smaller cleanups in the WebFrameBridge, and moved some
1694         platform independent functionality over to the shared code
1695         in WebCore.
1696         
1697         * WebCore.exp:
1698         * WebCore.pro:
1699         * WebCore.xcodeproj/project.pbxproj:
1700         * loader/FrameLoader.cpp:
1701         (WebCore::FrameLoader::loadSubframe):
1702         (WebCore::FrameLoader::shouldUsePlugin):
1703         (WebCore::FrameLoader::loadPlugin):
1704         (WebCore::FrameLoader::detachFromParent):
1705         (WebCore::FrameLoader::partClearedInBegin):
1706         (WebCore::FrameLoader::createJavaAppletWidget):
1707         (WebCore::FrameLoader::didChangeTitle):
1708         * loader/FrameLoader.h:
1709         * loader/FrameLoaderClient.h:
1710         * loader/FrameLoaderTypes.h:
1711         (WebCore::):
1712         * loader/PluginDocument.cpp:
1713         (WebCore::PluginTokenizer::writeRawData):
1714         * loader/mac/FrameLoaderMac.mm: Removed.
1715         * loader/qt/FrameLoaderQt.cpp: Removed.
1716         * page/Frame.cpp:
1717         (WebCore::Frame::Frame):
1718         * page/FrameView.cpp:
1719         (WebCore::FrameView::mediaType):
1720         * page/qt/FrameQt.cpp:
1721         (WebCore::FrameQt::FrameQt):
1722         * platform/graphics/svg/SVGImageEmptyClients.h:
1723         (WebCore::SVGEmptyFrameLoaderClient::makeRepresentation):
1724         (WebCore::SVGEmptyFrameLoaderClient::dispatchDidLoadResourceFromMemoryCache):
1725         (WebCore::SVGEmptyFrameLoaderClient::dispatchDidCommitLoad):
1726         (WebCore::SVGEmptyFrameLoaderClient::dispatchDidFailLoad):
1727         (WebCore::SVGEmptyFrameLoaderClient::dispatchCreatePage):
1728         (WebCore::SVGEmptyFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
1729         (WebCore::SVGEmptyFrameLoaderClient::dispatchUnableToImplementPolicy):
1730         (WebCore::SVGEmptyFrameLoaderClient::revertToProvisionalState):
1731         (WebCore::SVGEmptyFrameLoaderClient::setMainDocumentError):
1732         (WebCore::SVGEmptyFrameLoaderClient::startDownload):
1733         (WebCore::SVGEmptyFrameLoaderClient::committedLoad):
1734         (WebCore::SVGEmptyFrameLoaderClient::shouldFallBack):
1735         (WebCore::SVGEmptyFrameLoaderClient::willUseArchive):
1736         (WebCore::SVGEmptyFrameLoaderClient::createDocumentLoader):
1737         (WebCore::SVGEmptyFrameLoaderClient::createFrame):
1738         (WebCore::SVGEmptyFrameLoaderClient::createPlugin):
1739         (WebCore::SVGEmptyFrameLoaderClient::createJavaAppletWidget):
1740         (WebCore::SVGEmptyFrameLoaderClient::objectContentType):
1741         (WebCore::SVGEmptyFrameLoaderClient::overrideMediaType):
1742         (WebCore::SVGEmptyFrameLoaderClient::redirectDataToPlugin):
1743         (WebCore::SVGEmptyFrameLoaderClient::windowObjectCleared):
1744
1745 2007-01-23  Oliver Hunt  <oliver@apple.com>
1746
1747         Reviewed by Adam.
1748
1749         Added DragController to handled drag and drop state and control logic.
1750         Currently this only handles logic for Dragging and Dropping, and is 
1751         unable to initialise a drag itself.
1752
1753         platform/DragData encapsulate the paltform Drag data (NSDraggingInfo on Mac, 
1754         QMimeType in Qt).  This provides methods to pull data out the drag data as a String, 
1755         a URL, a DocumentFragment (for rich content), or a Colour.
1756
1757         * WebCore.exp:
1758         * WebCore.pro:
1759         * WebCore.xcodeproj/project.pbxproj:
1760         * dom/Clipboard.cpp: Added.
1761         (WebCore::Clipboard::setAccessPolicy):
1762         (WebCore::dragOpFromIEOp):
1763         (WebCore::IEOpFromDragOp):
1764         (WebCore::Clipboard::sourceOperation):
1765         (WebCore::Clipboard::destinationOperation):
1766         (WebCore::Clipboard::setSourceOperation):
1767         (WebCore::Clipboard::setDestinationOperation):
1768         (WebCore::Clipboard::setDropEffect):
1769         (WebCore::Clipboard::setEffectAllowed):
1770           move platform independent functions from ClipboardMac to Clipboard
1771
1772         * dom/Clipboard.h:
1773         (WebCore::Clipboard::Clipboard):
1774         (WebCore::Clipboard::dropEffect):
1775         (WebCore::Clipboard::effectAllowed):
1776         (WebCore::Clipboard::policy):
1777           as above -- also removed virtual modifier from now 
1778           platform independent methods
1779
1780         * editing/Editor.cpp:
1781         (WebCore::Editor::smartInsertDeleteEnabled): 
1782         (WebCore::Editor::shouldApplyStyle):
1783         * editing/Editor.h:
1784           adding calls through to EditorClient
1785          
1786         * page/DragActions.h: Added.
1787         (WebCore::):
1788           Replicates a number of NS* enums in the WebCore namespace
1789
1790         * page/DragClient.h: Added.
1791         (WebCore::DragClient::~DragClient):
1792           Standard client interface for dragging UIDelegate
1793
1794         * page/DragController.cpp: Added.
1795         (WebCore::createMouseEvent):
1796         (WebCore::DragController::DragController):
1797         (WebCore::DragController::~DragController):
1798         (WebCore::documentFragmentFromDragData):
1799         (WebCore::DragController::isMoveDrag):
1800         (WebCore::visiblePositionForPoint):
1801         (WebCore::DragController::cancelDrag):
1802         (WebCore::documentAtPoint):
1803         (WebCore::DragController::dragEntered):
1804         (WebCore::DragController::dragExited):
1805         (WebCore::DragController::dragUpdated):
1806         (WebCore::DragController::performDrag):
1807         (WebCore::DragController::dragEnteredOrUpdated):
1808         (WebCore::DragController::tryDocumentDrag):
1809         (WebCore::DragController::operationForLoad):
1810         (WebCore::DragController::concludeDrag):
1811         (WebCore::DragController::canProcessDrag):
1812         (WebCore::DragController::tryDHTMLDrag):
1813           Class to handle state and logic for dragging and dropping
1814
1815         * page/DragController.h: Added.
1816         (WebCore::DragController::client):
1817         (WebCore::DragController::didInitiateDrag):
1818         (WebCore::DragController::isHandlingDrag):
1819         (WebCore::DragController::dragOperation):
1820         (WebCore::DragController::document):
1821         (WebCore::DragController::dragInitiator):
1822         (WebCore::DragController::dragDestinationAction):
1823         (WebCore::DragController::dragSourceAction):
1824         (WebCore::DragController::dragEnded):
1825         (WebCore::DragController::setIsHandlingDrag):
1826         (WebCore::DragController::setDidInitiateDrag):
1827         (WebCore::DragController::setDragOperation):
1828         (WebCore::DragController::setDragSourceAction):
1829         (WebCore::DragController::setDragInitiator):
1830           See above
1831
1832         * page/Page.cpp:
1833         (WebCore::Page::Page):
1834           Update Page to have DragController
1835
1836         * page/Page.h:
1837         (WebCore::Page::dragController):
1838           ditto
1839
1840         * page/mac/DragControllerMac.mm: Added.
1841         (WebCore::DragController::isCopyKeyDown):
1842         (WebCore::DragController::dragOperation):
1843           Platform specific portions of the DragController
1844
1845         * page/mac/EventHandlerMac.mm:
1846         (WebCore::EventHandler::handleDrag):
1847         (WebCore::EventHandler::dragSourceEndedAt):
1848           Convert from NSDragOperation to WebCore::DragOperation
1849
1850         * page/mac/WebCoreFrameBridge.h:
1851         * page/mac/WebCoreFrameBridge.mm:
1852           Remove obsolete Drag functions
1853
1854         * page/qt/DragControllerQt.cpp: Added.
1855         (WebCore::DragController::isCopyKeyDown):
1856         (WebCore::DragController::dragOperation):
1857           Basic stubs to maintain Qt  build
1858
1859         * platform/DragData.cpp: Added.
1860         (WebCore::DragData::DragData):
1861         * platform/DragData.h: Added.
1862         (WebCore::DragData::clientPosition):
1863         (WebCore::DragData::globalPosition):
1864         (WebCore::DragData::platformData):
1865         (WebCore::DragData::draggingSourceOperationMask):
1866           DragData class to encapsulate platform drag data/event
1867
1868         * platform/graphics/svg/SVGImage.cpp:
1869         (WebCore::SVGImage::setData):
1870           Addition of dummy DragClient
1871
1872         * platform/graphics/svg/SVGImageEmptyClients.h:
1873         (WebCore::SVGEmptyDragClient::~SVGEmptyDragClient):
1874         (WebCore::SVGEmptyDragClient::willPerformDragDestinationAction):
1875         (WebCore::SVGEmptyDragClient::actionMaskForDrag):
1876         (WebCore::SVGEmptyDragClient::dragControllerDestroyed):
1877           ditto
1878
1879         * platform/mac/ClipboardMac.h:
1880         * platform/mac/ClipboardMac.mm:
1881         (WebCore::ClipboardMac::ClipboardMac):
1882         (WebCore::ClipboardMac::clearData):
1883         (WebCore::ClipboardMac::clearAllData):
1884         (WebCore::ClipboardMac::getData):
1885         (WebCore::ClipboardMac::setData):
1886         (WebCore::ClipboardMac::types):
1887         (WebCore::ClipboardMac::setDragImage):
1888          Moving platform independent logic to Clipboard, and updating
1889          platform specific methods to use appropriate accessors rather than 
1890          directly manipulating data they no longer own
1891
1892         * platform/mac/DragDataMac.mm: Added.
1893         (WebCore::DragData::DragData):
1894         (WebCore::DragData::canSmartReplace):
1895         (WebCore::DragData::containsColor):
1896         (WebCore::DragData::containsPlainText):
1897         (WebCore::DragData::asPlainText):
1898         (WebCore::DragData::asColor):
1899         (WebCore::DragData::createClipboard):
1900         (WebCore::imageExistsAtPaths):
1901         (WebCore::DragData::containsCompatibleContent):
1902         (WebCore::DragData::containsURL):
1903         (WebCore::DragData::asURL):
1904         (WebCore::DragData::asFragment):
1905           Mac implementations of DragData methods.  A number of these use
1906           a Helper class that accesses WebKit functionality.  That functionality 
1907           should be migrated to WebCore in the future.
1908
1909         * platform/mac/PasteboardHelper.h: Added.
1910         (WebCore::PasteboardHelper::~PasteboardHelper):
1911           Temporary, and Mac only, helper class to access WebKit functionality 
1912           from WebCore
1913
1914         * platform/qt/DragDataQt.cpp: Added.
1915         (WebCore::DragData::canSmartReplace):
1916         (WebCore::DragData::containsColor):
1917         (WebCore::DragData::containsPlainText):
1918         (WebCore::DragData::asPlainText):
1919         (WebCore::DragData::asColor):
1920         (WebCore::DragData::createClipboard):
1921         (WebCore::DragData::containsCompatibleContent):
1922         (WebCore::DragData::containsURL):
1923         (WebCore::DragData::asURL):
1924         (WebCore::DragData::asFragment):
1925          Basic stubs to maintain Qt build
1926
1927         * rendering/HitTestResult.cpp:
1928         (WebCore::HitTestResult::HitTestResult):
1929          Correct HitTestResult copy contructor to copy localPoint
1930
1931 2007-01-22  Mark Rowe  <mrowe@apple.com>
1932
1933         Reviewed by Maciej.
1934
1935         http://bugs.webkit.org/show_bug.cgi?id=11692
1936         Bug 11692: REGRESSION(r17352): Disappearing page title
1937
1938         * dom/Document.cpp:
1939         (WebCore::Document::setTitle): If the title has already been set explicitly via JavaScript,
1940         ignore any changes to it due to encountering <title> tags.
1941
1942 2007-01-22  Mitz Pettel  <mitz@webkit.org>
1943
1944         Reviewed by Darin.
1945
1946         - fix http://bugs.webkit.org/show_bug.cgi?id=12344
1947           NativeListBox: item hit testing does not account for top padding and border
1948
1949         Test: fast/forms/listbox-selection-2.html
1950
1951         * rendering/RenderListBox.cpp:
1952         (WebCore::RenderListBox::numVisibleItems): Changed height() to contentHeight()
1953         since items are visible only in the content box.
1954         (WebCore::RenderListBox::listIndexAtOffset): Adjusted for vertical padding and
1955         borders. Changed to return -1 instead of the last item's index if the given offset
1956         is below the last item.
1957         (WebCore::RenderListBox::autoscroll): Adjusted for vertical padding and borders.
1958         (WebCore::RenderListBox::controlClipRect): Changed to return the content box since
1959         items should not spill into the padding box. This change is the reason the test
1960         generates pixel results.
1961
1962 2007-01-22  Justin Garcia  <justin.garcia@apple.com>
1963
1964         Reviewed by darin
1965         
1966         <rdar://problem/4944770>
1967         editing/pasteboard/4641033 layout test is broken (12328)
1968         
1969         This layout test failure demonstrates three bugs:
1970         Smart replace shouldn't be turned on, but is because a word
1971         selection granularity from the previous test isn't cleared.
1972         Smart replace shouldn't add any spaces because the paste is performed
1973         in an empty paragraph.
1974         Smart replace spaces are added to the text of options inside
1975         the select element instead of before/after the select element.
1976         
1977         This patch fixes the second two problems.  During a 
1978         ReplaceSelectionCommand, the VisiblePosition for the end of 
1979         the inserted content is the last position in the last leaf 
1980         inserted.  This is a problem when the last leaf is inside a 
1981         select element, since VP creation is inconsistent there.  
1982         Second, smart spaces were inserted inside the last leaf, not
1983         at the endOfInsertedContent.
1984
1985         * editing/ReplaceSelectionCommand.cpp:
1986         (WebCore::ReplaceSelectionCommand::shouldMergeStart): Renamed 
1987         m_lastNodeInserted to m_lastLeafInserted.  Use the 
1988         start/endOfInsertedContent getters.
1989         (WebCore::ReplaceSelectionCommand::shouldMergeEnd): Ditto.
1990         (WebCore::ReplaceSelectionCommand::removeNodePreservingChildren): Ditto.
1991         (WebCore::ReplaceSelectionCommand::removeRedundantStyles): Ditto.
1992         (WebCore::ReplaceSelectionCommand::positionAtEndOfInsertedContent): Added.
1993         Special case for when the last leaf inserted is inside a select 
1994         element: return the VisiblePosition after the select element.
1995         (WebCore::ReplaceSelectionCommand::positionAtStartOfInsertedContent): Added.
1996         (WebCore::ReplaceSelectionCommand::doApply): Did renaming.  Used
1997         the start/endOfInsertedContent getters.  Insert smart replace spaces
1998         into the right nodes.
1999         (WebCore::ReplaceSelectionCommand::shouldRemoveEndBR): Renaming.
2000         (WebCore::ReplaceSelectionCommand::completeHTMLReplacement): Ditto.
2001         (WebCore::ReplaceSelectionCommand::updateNodesInserted): Ditto.
2002         * editing/ReplaceSelectionCommand.h:
2003
2004 2007-01-22  Darin Adler  <darin@apple.com>
2005
2006         Reviewed by Adam.
2007
2008         - fix http://bugs.webkit.org/show_bug.cgi?id=12273
2009           REGRESSION: File input value invisible after removing and re-appending
2010
2011         - made more of the file chooser code cross-platform
2012
2013         - fixed an Objective-C garbage collection problem in FileChooser
2014
2015         - tried to remove layering violations where FileChooser in the platform
2016           directory knows about the rendering and DOM trees (but wasn't able to
2017           do it entirely)
2018
2019         * platform/FileChooser.cpp: Added.
2020         (WebCore::FileChooser::create): Changed parameters.
2021         (WebCore::FileChooser::chooseFile): Changed to call chooseIcon function.
2022         (WebCore::FileChooser::chooseIcon): Added.
2023
2024         * platform/FileChooser.h: Added FileChooserClient so this file doesn't have
2025         to know about RenderFileUploadControl. Used RetainPtr instead of retain/release
2026         so this works properly with Objective-C GC. Replaced disconnectUploadControl
2027         with disconnectClient, which has a simple inline implementation. Moved the
2028         Document parameter from the constructor to openFileChooser, along with a comment
2029         about why it should not be there. Added a filename parameter to the constructor
2030         for the initial filename. Added a font parameter to basenameForWidth so we don't
2031         depend on having a pointer to the renderer. Removed the uploadControl() and
2032         document() functions since no one calls either of them.
2033
2034         * platform/mac/FileChooserMac.mm: Removed code that is now cross-platform.
2035         (-[OpenPanelController beginSheetWithFrame:]): Added frame parameter, instead
2036         of storing a document pointer in the FileChooser.
2037         (WebCore::FileChooser::FileChooser): Updated for changed parameters. Also added
2038         code to choose the icon based on the initial filename. Pass the adopt parameter
2039         to the constructor of the RetainPtr.
2040         (WebCore::FileChooser::~FileChooser): Removed the release call, since the
2041         RetainPtr will take care of it. Added a call to disconnectFileChooser here.
2042         There's no need to disconnect at disconnectClient time, and that lets us have
2043         one more cross-platform function.
2044         (WebCore::FileChooser::openFileChooser): Added document parameter. Added code
2045         to get the frame from the document. And added a nil check since there's no
2046         ironclad guarantee the document won't have outlived its frame.
2047         (WebCore::FileChooser::basenameForWidth): Added font parameter. Use that instead
2048         of going at the upload control's style. The caller can handle that now.
2049
2050         * rendering/RenderFileUploadControl.h: Removed unnecessary includes.
2051         Made class inherit privately from FileChooserClient. Changed constructor
2052         parameter to HTMLInputElement rather than Node. Made protected members be
2053         private instead, and made a couple function members const.
2054         * rendering/RenderFileUploadControl.cpp: Moved constants to the top of the file,
2055         but after the "using namespace"
2056         (WebCore::RenderFileUploadControl::RenderFileUploadControl): Updated for changes
2057         to the FileChooser::create function and the parameter types.
2058         (WebCore::RenderFileUploadControl::~RenderFileUploadControl): Removed unneeded
2059         null check -- there's no case where the FileChooser fails to be created.
2060         (WebCore::RenderFileUploadControl::click): Pass document to openFileChooser.
2061         (WebCore::RenderFileUploadControl::updateFromElement): Tweaked code a bit by
2062         using updateFromElement and setValue instead of casting the renderer to a
2063         RenderButton and calling setText directly. Put setInputType call here.
2064         (WebCore::RenderFileUploadControl::maxFilenameWidth): Made const. Broke long line.
2065         (WebCore::RenderFileUploadControl::createButtonStyle): Made const.
2066         (WebCore::RenderFileUploadControl::paintObject): Moved buttonShadowHeight constant
2067         to the top of the file. Call isEmpty instead of checking width and height of
2068         IntRect for 0. Computed font to pass to FileChooser::basenameForWidth. Broke
2069         long lines.
2070         (WebCore::HTMLFileUploadInnerButtonElement::HTMLFileUploadInnerButtonElement):
2071         Moved the setInputType call to the caller; concept here is that this class is
2072         as simple as possible, rather than doing as much of the button job as possible.
2073
2074         * WebCore.xcodeproj/project.pbxproj: Added FileChooser.cpp.
2075         * WebCore.pro: Ditto.
2076         * CMakeLists.txt: Ditto.
2077         * WebCoreSources.bkl: Ditto.
2078
2079         * platform/gdk/TemporaryLinkStubs.cpp: Updated stubs.
2080         * platform/qt/FileChooserQt.cpp: Updated stubs.
2081
2082 2007-01-22  Mitz Pettel  <mitz@webkit.org>
2083
2084         Reviewed by Darin.
2085
2086         - fix http://bugs.webkit.org/show_bug.cgi?id=12364
2087           REGRESSSION (NativeListBox): Selected option's background is not clipped to the list box
2088
2089         Test: fast/forms/select-item-background-clip.html
2090
2091         * rendering/RenderListBox.cpp:
2092         (WebCore::RenderListBox::paintItemBackground): Intersect the item's rect with
2093         the list box's clip rect.
2094
2095 2007-01-22  Darin Adler  <darin@apple.com>
2096
2097         Reviewed by Beth.
2098
2099         - fix http://bugs.webkit.org/show_bug.cgi?id=12369
2100           REGRESSION (r19027): amazon.com home page crashes WebKit r19028 debug build
2101
2102         I caused this a few hours ago. Oops!
2103
2104         * rendering/RenderText.cpp: (WebCore::RenderText::setStyle):
2105         Compute whether the font changed before calling RenderObject::setStyle.
2106
2107 2007-01-22  Beth Dakin  <bdakin@apple.com>
2108
2109         Reviewed by Maciej.
2110
2111         Fix for <rdar://problem/4912129> REGRESSION: Crash occurs at 
2112         WebCore::Frame::eventHandler() after clicking to dismiss a 
2113         contextual menu on the page
2114
2115         * page/EventHandler.cpp:
2116         (WebCore::EventHandler::stopAutoscrollTimer): Added nil-check.
2117
2118 2007-01-22  Darin Adler  <darin@apple.com>
2119
2120         Reviewed by Mitz.
2121
2122         Inspired by a much simpler patch by Andrew Wellington <proton@wiretapped.net>.
2123
2124         - fix http://bugs.webkit.org/show_bug.cgi?id=11197
2125           REGRESSION: Specifying a counter for a CODE tag's content style property
2126           on before or after causes a crash.
2127
2128         Test: fast/css/beforeSelectorOnCodeElement.html
2129
2130         - fix regression I recently introduced where the monospace cache could be
2131           used for text that was not ASCII, if text was changed after the style was set
2132
2133         Test: fast/text/monospace-width-cache.html
2134
2135         - streamline RenderText.h -- remove unneeded functions, make some needlessly
2136           virtual functions non-virtual, remove unneeded header includes, replace use
2137           of Font* with Font& for consistency with RenderStyle, use "text" consistently
2138           instead of "string"
2139
2140         * rendering/RenderText.h: Removed unneeded include of "Text.h", declarations of
2141         SOFT_HYPHEN, DocumentMarker, InlineBox, Position, String. Got rid of friend
2142         declaration for InlineTextBox. Changed constructor to take a PassRefPtr since
2143         we do take owership of the passed-in text. Made deleteTextBoxes() private.
2144         Removed unneeded data(). Made override of length() private so people will use
2145         the faster textLength() instead. Renamed string() to text() so it matches up
2146         better with setText(). Same for stringLength(), originalString(), and
2147         setInternalString(), which are now textLength(), originalText(), and
2148         setTextInternal(). Renamed the old text() function to characters(), since it
2149         returns a pointer as StringImpl::characters does. Changed Font* to Font& everywhere.
2150         Renamed the internal calcMinMaxWidth() function to calcMinMaxWidthInternal() and
2151         made it non-virtual since it's not overriden anywhere. Also made the
2152         trimmedMinMaxWidth() function non-virtual. Made containsOnlyWhitespace() private.
2153         Removed both font() functions (one was needlessly virtual) and element().
2154         Renamed cacheWidths() to updateMonospaceCharacterWidth() and removed the
2155         shouldUseMonospaceCache() function. Renamed allAscii() to isAllASCII() and made
2156         it an inline function. Removed the m_allAsciiChecked flag and renamed the
2157         m_allAscii flag to m_isAllASCII.
2158         * rendering/RenderText.cpp:
2159         (WebCore::RenderText::RenderText): Removed initialization of m_allAsciiChecked.
2160         Initialize m_isAllASCII. Changed all occurrences of m_str->length() and
2161         m_str->characters () to use the stringLength() and characters() inline functions
2162         instead.
2163         (WebCore::RenderText::setStyle): Replaced the unconditional call to cacheWidths
2164         with a conditional call to updateMonospaceCharacterWidth. This speeds up the common
2165         case where style is changed without changing the font.
2166         (WebCore::RenderText::originalText): Changed code to not depend on overridden
2167         element() function with casts to a Text node -- this was one of only two call sites.
2168         Also renamed.
2169         (WebCore::RenderText::positionForCoordinates): Name change.
2170         (WebCore::RenderText::caretRect): Ditto.
2171         (WebCore::RenderText::updateMonospaceCharacterWidth): Renamed from cacheWidths and
2172         incorporate the check that was formerly in a separate shouldUseMonospaceCache
2173         function.
2174         (WebCore::RenderText::widthFromCache): Changed to take a Font& instead of Font*.
2175         Changed to take advantage of the fact that the string is known to be all ASCII in
2176         the m_monospaceCharacterWidth code path.
2177         (WebCore::RenderText::trimmedMinMaxWidth): Ditto. Also use style()->font() instead
2178         of font(false).
2179         (WebCore::RenderText::calcMinMaxWidth): Ditto. Also changed to use softHyphen instead
2180         of SOFT_HYPHEN.
2181         (WebCore::RenderText::containsOnlyWhitespace): More of the same.
2182         (WebCore::RenderText::setSelectionState): Ditto.
2183         (WebCore::RenderText::setTextWithOffset): Ditto.
2184         (WebCore::isInlineFlowOrEmptyText): Ditto.
2185         (WebCore::RenderText::setTextInternal): Updated for name changes. Also changed to
2186         set the m_isAllASCII flag every time, in the more-efficient way we use elsewhere
2187         (or'ing all the characters together), and to call updateMonospaceCharacterWidth
2188         if the "all ASCII"-ness of the text changes.
2189         (WebCore::RenderText::setText): Updated for name changes.
2190         (WebCore::RenderText::width): More like above.
2191         (WebCore::RenderText::selectionRect): Ditto.
2192         (WebCore::RenderText::caretMaxOffset): Ditto.
2193         (WebCore::RenderText::previousOffset): Ditto.
2194         (WebCore::RenderText::nextOffset): Ditto.
2195
2196         * dom/Position.cpp:
2197         * dom/Range.cpp:
2198         * editing/CompositeEditCommand.cpp:
2199         * editing/DeleteSelectionCommand.cpp:
2200         * editing/VisiblePosition.cpp:
2201         * html/HTMLElement.cpp:
2202         Added now-needed include of "Text.h" which is no longer included by "RenderText.h".
2203
2204         * editing/SelectionController.cpp:
2205         (WebCore::SelectionController::debugRenderer):
2206         * editing/TextIterator.cpp:
2207         (WebCore::TextIterator::handleTextNode):
2208         (WebCore::TextIterator::handleTextBox):
2209         (WebCore::SimplifiedBackwardsTextIterator::handleTextNode):
2210         Update for name changes of stringLength(), string(), and originalString() to
2211         textLength(), text(), and originalText(), and to always use textLength() instead
2212         of length() when we have a RenderText* rather than a RenderObject*.
2213         * editing/visible_units.cpp:
2214         (WebCore::startOfParagraph): Ditto.
2215         (WebCore::endOfParagraph): Ditto.
2216         * rendering/InlineFlowBox.cpp:
2217         (WebCore::InlineFlowBox::placeBoxesHorizontally): Ditto. Also removed use of the
2218         RenderObject::font() function and replaced it with explicit access to the style.
2219         (WebCore::InlineFlowBox::placeBoxesVertically): Ditto.
2220         * rendering/InlineTextBox.cpp:
2221         (WebCore::InlineTextBox::selectionRect): Ditto.
2222         (WebCore::InlineTextBox::isLineBreak): Ditto.
2223         (WebCore::InlineTextBox::paint): Ditto.
2224         (WebCore::InlineTextBox::selectionStartEnd): Ditto.
2225         (WebCore::InlineTextBox::paintSelection): Ditto.
2226         (WebCore::InlineTextBox::paintMarkedTextBackground): Ditto.
2227         (WebCore::InlineTextBox::paintSpellingOrGrammarMarker): Ditto.
2228         (WebCore::InlineTextBox::paintTextMatchMarker): Ditto.
2229         (WebCore::InlineTextBox::offsetForPosition): Ditto.
2230         (WebCore::InlineTextBox::positionForOffset): Ditto.
2231         * rendering/RenderContainer.cpp:
2232         (WebCore::RenderContainer::addChild): Ditto.
2233         * rendering/RenderCounter.cpp:
2234         (WebCore::RenderCounter::originalText): Ditto.
2235         (WebCore::RenderCounter::calcMinMaxWidth): Ditto.
2236         * rendering/RenderCounter.h: Ditto.
2237         * rendering/RenderTextFragment.cpp:
2238         (WebCore::RenderTextFragment::originalText): Ditto.
2239         * rendering/RenderTextFragment.h: Ditto.
2240         * rendering/SVGInlineFlowBox.cpp:
2241         (WebCore::placePositionedBoxesHorizontally): Ditto.
2242         (WebCore::placeBoxesVerticallyWithAbsBaseline): Ditto.
2243         * rendering/bidi.cpp:
2244         (WebCore::BidiIterator::increment): Ditto.
2245         (WebCore::BidiIterator::current): Ditto.
2246         (WebCore::BidiIterator::direction): Ditto.
2247         (WebCore::addRun): Ditto.
2248         (WebCore::checkMidpoints): Ditto.
2249         (WebCore::RenderBlock::computeHorizontalPositionsForLine): Ditto.
2250         (WebCore::RenderBlock::skipWhitespace): Ditto.
2251         (WebCore::RenderBlock::findNextLineBreak): Ditto.
2252
2253         * rendering/RenderBR.h: Updated signature of width function which now takes a
2254         Font& instead of a Font*.
2255
2256         * rendering/RenderBlock.cpp: (WebCore::stripTrailingSpace): Updated to no longer
2257         use the RenderObject::font() function, and added a comment about first-line, which
2258         is not handled properly here.
2259
2260         * rendering/RenderMenuList.cpp: (WebCore::RenderMenuList::text):
2261         * rendering/RenderTreeAsText.cpp: (WebCore::writeTextRun):
2262         Eliminated use of RenderText::data().
2263
2264         * rendering/RenderObject.h: Removed RenderObject::font(). This had the bad effect of
2265         having everyone pass in a boolean rather than using the cleaner style() and
2266         firstLineStyle() functions in cases where there's no a firstLineStyle boolean.
2267         * rendering/RenderObject.cpp:
2268         (WebCore::RenderObject::getVerticalPosition): Replaced use of RenderObject::font()
2269         with direct use of the style instead, which is arguably easier to understand anyway.
2270         (WebCore::RenderObject::baselinePosition): Ditto.
2271
2272 2007-01-22  Sam Weinig  <sam@webkit.org>
2273
2274         Reviewed by The Mitz.
2275
2276         Move JSHTMLSelectElementCustom.cpp from bindings to bindings/js
2277         where it belongs.
2278
2279         * WebCore.pro:
2280         * WebCore.xcodeproj/project.pbxproj:
2281         * bindings/JSHTMLSelectElementCustom.cpp: Removed.
2282         * bindings/js/JSHTMLSelectElementCustom.cpp: Added.
2283
2284 2007-01-22  Zack Rusin  <zack@kde.org>
2285
2286         Fix the Qt build.
2287
2288         * WebCore.pro: adjust after last changes
2289
2290 2007-01-21  Alexey Proskuryakov  <ap@webkit.org>
2291
2292         Reviewed by Darin.
2293
2294         http://bugs.webkit.org/show_bug.cgi?id=10934
2295         REGRESSION: prototype.js logs error (HTMLFormElement) on webkit builds
2296
2297         Added constructors for most HTML elements; started auto-generating HTMLSelectElement JS binding.
2298
2299         Test: fast/dom/Window/element-constructors-on-window.html
2300
2301         * DerivedSources.make: Generate JSHTMLSelectElement.
2302         * WebCore.xcodeproj/project.pbxproj: Added JSHTMLSelectElement{Custom}.
2303         * bindings/js/JSHTMLElementWrapperFactory.cpp: Create a proper binding for SELECT.
2304
2305         * bindings/js/kjs_html.cpp:
2306         (KJS::):
2307         (KJS::JSHTMLElement::classInfo):
2308         (KJS::JSHTMLElement::accessors):
2309         (KJS::JSHTMLElement::getOwnPropertySlot):
2310         (KJS::HTMLElementFunction::callAsFunction):
2311         (KJS::JSHTMLElement::put):
2312         * bindings/js/kjs_html.h:
2313         (KJS::JSHTMLElement::):
2314         Removed everything related to SELECT. Renamed getHTMLOptionsCollection to toJS for autogenerated code 
2315         to be happy, and rewrote it using cacheDOMObject.
2316
2317         * bindings/scripts/CodeGeneratorJS.pm: Added HTMLElement to the list of types that cannot fail conversion.
2318
2319         * html/HTMLAnchorElement.idl:
2320         * html/HTMLAppletElement.idl:
2321         * html/HTMLAreaElement.idl:
2322         * html/HTMLBRElement.idl:
2323         * html/HTMLBaseElement.idl:
2324         * html/HTMLBaseFontElement.idl:
2325         * html/HTMLBodyElement.idl:
2326         * html/HTMLButtonElement.idl:
2327         * html/HTMLCanvasElement.idl:
2328         * html/HTMLDListElement.idl:
2329         * html/HTMLDirectoryElement.idl:
2330         * html/HTMLDivElement.idl:
2331         * html/HTMLFieldSetElement.idl:
2332         * html/HTMLFontElement.idl:
2333         * html/HTMLFormElement.idl:
2334         * html/HTMLHRElement.idl:
2335         * html/HTMLHeadElement.idl:
2336         * html/HTMLHeadingElement.idl:
2337         * html/HTMLHtmlElement.idl:
2338         * html/HTMLImageElement.idl:
2339         * html/HTMLInputElement.idl:
2340         * html/HTMLIsIndexElement.idl:
2341         * html/HTMLLIElement.idl:
2342         * html/HTMLLabelElement.idl:
2343         * html/HTMLLegendElement.idl:
2344         * html/HTMLLinkElement.idl:
2345         * html/HTMLMapElement.idl:
2346         * html/HTMLMenuElement.idl:
2347         * html/HTMLMetaElement.idl:
2348         * html/HTMLModElement.idl:
2349         * html/HTMLOListElement.idl:
2350         * html/HTMLOptGroupElement.idl:
2351         * html/HTMLParagraphElement.idl:
2352         * html/HTMLParamElement.idl:
2353         * html/HTMLPreElement.idl:
2354         * html/HTMLQuoteElement.idl:
2355         * html/HTMLScriptElement.idl:
2356         * html/HTMLStyleElement.idl:
2357         * html/HTMLTextAreaElement.idl:
2358         * html/HTMLTitleElement.idl:
2359         * html/HTMLUListElement.idl:
2360         Generate constructors.
2361
2362         * html/HTMLSelectElement.cpp:
2363         (WebCore::HTMLSelectElement::length):
2364         * html/HTMLSelectElement.h:
2365         Make length() return unsigned for auto-generated code to be happy.
2366
2367         * html/HTMLSelectElement.idl: Adjusted to be usable for JS.
2368
2369         * bindings/JSHTMLSelectElementCustom.cpp: Added. Implements remove().
2370
2371         * page/DOMWindow.idl:
2372         Added properties for most elements' constructors.
2373
2374 2007-01-21  Mark Rowe  <mrowe@apple.com>
2375
2376         Reviewed by Maciej.
2377
2378         http://bugs.webkit.org/show_bug.cgi?id=12357
2379         Bug 12357: Reproducible crash in WebCore::Settings::isJavaScriptEnabled in svg/custom/js-update-bounce.svg under guard-malloc
2380
2381         * page/Frame.cpp:
2382         (WebCore::Frame::~Frame): Access the global object directly rather than via Window::retrieveWindow to prevent our reference to
2383         a deleted settings object being used.
2384
2385 2007-01-21  Darin Adler  <darin@apple.com>
2386
2387         Reviewed by Maciej.
2388
2389         - fix <rdar://problem/4930503> REGRESSION: Page changes title when
2390           command-clicking on named anchor link (12299)
2391
2392         * loader/FrameLoader.cpp:
2393         (WebCore::FrameLoader::continueFragmentScrollAfterNavigationPolicy):
2394         Return if shouldContinue is false. This matches the other similar
2395         functions and prevents us from doing extra work in the "ignore" case.
2396
2397 2007-01-21  Mark Rowe  <mrowe@apple.com>
2398
2399         Reviewed by Darin.
2400
2401         http://bugs.webkit.org/show_bug.cgi?id=12355
2402         Bug 12355: Reproducible crash in WebCore::parseNumber in svg/custom/js-update-bounce.svg under guard-malloc
2403
2404         * ksvg2/svg/SVGParserUtilities.cpp:
2405         (WebCore::parseNumber): Parenthesize to prevent reading past end of buffer.
2406
2407 2007-01-21  Mitz Pettel  <mitz@webkit.org>
2408
2409         Reviewed by Darin.
2410
2411         - fix http://bugs.webkit.org/show_bug.cgi?id=12345
2412           REGRESSION: Disabled pop-up text is not grayed out
2413
2414         Test: fast/forms/select-disabled-appearance.html
2415
2416         * rendering/RenderThemeMac.mm:
2417         (WebCore::RenderThemeMac::adjustMenuListStyle):
2418
2419 2007-01-21  Darin Adler  <darin@apple.com>
2420
2421         - fix non-Mac builds
2422
2423         * CMakeLists.txt: Added JSDocumentCustom.cpp.
2424         * WebCore.pro: Ditto.
2425         * WebCoreSources.bkl: Ditto.
2426
2427 2007-01-21  Mitz Pettel  <mitz@webkit.org>
2428
2429         Reviewed by Darin.
2430
2431         - fix http://bugs.webkit.org/show_bug.cgi?id=12353 <rdar://problem/4944599>
2432           REGRESSION: Crash on load (mutation event dispatch under the image element constructor deletes the element)
2433     
2434         Test: fast/dom/HTMLImageElement/constructor-mutation-event-dispatch.html
2435
2436         * bindings/js/kjs_html.cpp:
2437         (KJS::ImageConstructorImp::construct): Protect the image element before setting
2438         its attributes.
2439
2440 2007-01-21  Sam Weinig  <sam@webkit.org>
2441
2442         Rolling out patch for http://bugs.webkit.org/show_bug.cgi?id=8360.
2443
2444         * rendering/RenderLayer.cpp:
2445         (WebCore::RenderLayer::RenderLayer):
2446         (WebCore::RenderLayer::scrollToOffset):
2447         (WebCore::RenderLayer::scrollRectToVisible):
2448         (WebCore::RenderLayer::updateScrollInfoAfterLayout):
2449         (WebCore::Marquee::start):
2450         * rendering/RenderLayer.h:
2451
2452 2007-01-21  David Kilzer  <ddkilzer@webkit.org>
2453
2454         Reviewed by Darin.
2455
2456         - fix http://bugs.webkit.org/show_bug.cgi?id=12280
2457           select element not available by name through document.all
2458           (dropdown list not available on smarthome.com checkout)
2459
2460         Test: fast/dom/document-all-select.html
2461
2462         * html/HTMLCollection.cpp:
2463         (WebCore::HTMLCollection::checkForNameMatch):
2464         (WebCore::HTMLCollection::updateNameCache):
2465
2466 2007-01-21  Mitz Pettel  <mitz@webkit.org>
2467
2468         Reviewed by Darin.
2469
2470         - http://bugs.webkit.org/show_bug.cgi?id=10805
2471           REGRESSION (r15720): manual-tests/onblur-remove.html failing
2472
2473         * manual-tests/onblur-remove.html: Changed the test to not require pressing
2474         Enter, since the correct behavior for Enter is to send a blur event.
2475
2476 2007-01-21  Sanjay Madhav  <sanjay12@gmail.com>
2477
2478         Reviewed by Darin.
2479
2480         Fix for: <rdar://problem/4928583> Memory usage grows when reloading google.com/ig
2481
2482         JSDocuments are now responsible for marking the DOM wrappers associated with them, when they get marked.
2483         This fixes a JS object leak when a DOM wrapper has a reference to a JSDocument that is otherwise not reachable.
2484
2485         Test: fast/dom/gc-10.html
2486
2487         * WebCore.vcproj/WebCore/WebCore.vcproj:
2488         * WebCore.xcodeproj/project.pbxproj:
2489         * bindings/js/JSDocumentCustom.cpp: Added.
2490         (WebCore::JSDocument::mark):
2491         * bindings/js/kjs_binding.cpp:
2492         (KJS::ScriptInterpreter::markDOMNodesForDocument):
2493         (KJS::ScriptInterpreter::mark):
2494         * bindings/js/kjs_binding.h:
2495         * dom/Document.idl:
2496
2497 2007-01-21  Mitz Pettel  <mitz@webkit.org>
2498
2499         Reviewed by Darin.
2500
2501         - fix http://bugs.webkit.org/show_bug.cgi?id=10692
2502           REGRESSION (r14847): Unnecessary scrollbars with position:relative; and overflow:auto;
2503
2504         Test: fast/overflow/position-relative.html
2505
2506         * rendering/RenderBox.cpp:
2507         (WebCore::RenderBox::lowestPosition): Add the relative position offset only
2508         if 'includeSelf' is true.
2509         (WebCore::RenderBox::rightmostPosition): Ditto.
2510         (WebCore::RenderBox::leftmostPosition): Ditto.
2511         * rendering/RenderFlow.cpp:
2512         (WebCore::RenderFlow::lowestPosition): Ditto.
2513         (WebCore::RenderFlow::rightmostPosition): Ditto.
2514         (WebCore::RenderFlow::leftmostPosition): Ditto.
2515
2516 2007-01-21  Mitz Pettel  <mitz@webkit.org>
2517
2518         Reviewed by Darin.
2519
2520         - fix http://bugs.webkit.org/show_bug.cgi?id=10472
2521           REGRESSION: "add" method of <select> object does not put the <option> object in the correct position
2522
2523         Test: fast/dom/HTMLSelectElement/options-collection-detached.html
2524
2525         * html/HTMLSelectElement.cpp:
2526         (WebCore::HTMLSelectElement::setRecalcListItems): Reset the options collection
2527         info if the <select> is not in the document. For in-document <select>s this
2528         happens anyway as a result of the DOM tree version increasing.
2529
2530 2007-01-21  Mitz Pettel  <mitz@webkit.org>
2531
2532         Reviewed by Darin.
2533
2534         - fix http://bugs.webkit.org/show_bug.cgi?id=12349
2535           NativeFileUpload: Button text is not grayed out when the control is disabled
2536
2537         Covered by fast/forms/file-input-disabled.html 
2538
2539         * css/html4.css: Changed selectors that had pseudo-classes after the -webkit-file-upload-button
2540         pseudo-element to have the pseudo-element at the end. Pseudo-elements must be at the end.
2541         * rendering/RenderFileUploadControl.cpp:
2542         (WebCore::RenderFileUploadControl::createButtonStyle): Changed to not overwrite the button's
2543         style with its parent's style. getPseudoStyle() handles inheritance properly.
2544
2545 2007-01-21  Mitz Pettel  <mitz@webkit.org>
2546
2547         Reviewed by Darin.
2548
2549         - fix http://bugs.webkit.org/show_bug.cgi?id=12343
2550           crash in css2.1/t1202-counter-09-b.html
2551
2552         * platform/Font.cpp:
2553         (WebCore::Font::glyphDataForCharacter):
2554
2555 2007-01-21  Darin Adler  <darin@apple.com>
2556
2557         Reviewed by Adam and Mitz.
2558
2559         - fix http://bugs.webkit.org/show_bug.cgi?id=12347
2560           REGRESSION: list box scrolling broken (fast/forms/listbox-selection.html)
2561
2562         Covered by existing test: fast/forms/listbox-selection.html
2563
2564         * rendering/RenderListBox.h: Added override of layout(), made selectionChanged()
2565         no longer an inline. Added private scrollToRevealSelection(),
2566         m_scrollToRevealSelectionAfterLayout, and m_inAutoscroll.
2567         * rendering/RenderListBox.cpp:
2568         (WebCore::RenderListBox::RenderListBox): Initialize new data members.
2569         (WebCore::RenderListBox::updateFromElement): Remove scrolling code.
2570         (WebCore::RenderListBox::selectionChanged): Moved from header. Calls repaint
2571         and then scrollToRevealSelection, but if we need layout, instead schedules
2572         scrollToRevealSelection to be done after layout.
2573         (WebCore::RenderListBox::layout): Added. After calling base class, calls
2574         scrollToRevealSelection if the m_scrollToRevealSelectionAfterLayout is set.
2575         (WebCore::RenderListBox::scrollToRevealSelection): Added. Code was originally
2576         in updateFromElement.
2577         (WebCore::RenderListBox::autoscroll): Set m_inAutoscroll so that the
2578         selectionChanged function knows not to scroll. Also removed the repaint()
2579         here because updateListBoxSelection() takes care of repainting by calling
2580         selectionChanged().
2581
2582 2007-01-21  David Kilzer  <ddkilzer@webkit.org>
2583
2584         * page/EventHandler.cpp:
2585         (WebCore::EventHandler::handleMouseMoveEvent): Changed #if SVG_SUPPORT to #ifdef SVG_SUPPORT.
2586
2587 2007-01-20  Mitz Pettel  <mitz@webkit.org>
2588
2589         Reviewed by Maciej.
2590
2591         - fix http://bugs.webkit.org/show_bug.cgi?id=11115
2592           REGRESSION: Crash on Flickr after hitting cancel from adding a note
2593
2594         Test: fast/forms/text-set-value-crash.html
2595
2596         * html/HTMLInputElement.cpp:
2597         (WebCore::HTMLInputElement::setValue): Added a call to Document::updateRendering().
2598         * html/HTMLTextAreaElement.cpp:
2599         (WebCore::HTMLTextAreaElement::setValue): Ditto.
2600
2601 2007-01-20  Mitz Pettel  <mitz@webkit.org>
2602
2603         Reviewed by Darin.
2604
2605         - fix http://bugs.webkit.org/show_bug.cgi?id=8360
2606           Repro crash when onscroll handler deletes the scrolled object
2607
2608         Test: fast/layers/removed-by-scroll-handler.html
2609
2610         * rendering/RenderLayer.cpp:
2611         (WebCore::RenderLayer::RenderLayer):
2612         (WebCore::RenderLayer::dispatchScrollEvent): Added. Called when the timer
2613         fires and dispatches the scroll event to the layer's element.
2614         (WebCore::RenderLayer::scrollToOffset): Instead of dispatching the scroll
2615         event from this function, which is called during layout, schedule a 0-duration
2616         timer to dispatch the event after layout.
2617         (WebCore::RenderLayer::scrollRectToVisible):
2618         (WebCore::RenderLayer::updateScrollInfoAfterLayout):
2619         (WebCore::Marquee::start):
2620         * rendering/RenderLayer.h:
2621
2622 2007-01-20  Nikolas Zimmermann  <zimmermann@kde.org>
2623
2624         Reviewed by Sam.
2625
2626         Fix JS bindings for SVGAnimated{Boolean, Enumeration, Integer, Number, String}.
2627
2628         Dynamic SVG DOM updates (ie. "someUse.href.baseVal = '#rect'") with these types
2629         didn't work. Existing gradient updating examples relied on calling setAttribute
2630         after a SVG DOM update - that was the only reason it worked, added a new test
2631         only using SVG DOM updates (js-update-stop.svg).
2632
2633         Added test: js-update-stop.svg
2634         Added test: use-property-changes-through-dom.svg (change xlink:href, x/y attributes using setAttribute)
2635         Added test: use-property-changes-through-svg-dom.svg (change xlink:href, x/y attributes using SVG DOM)
2636
2637         * bindings/js/JSSVGPODTypeWrapper.h:
2638         (WebCore::JSSVGPODTypeWrapper::commitChange):
2639         (WebCore::JSSVGPODTypeWrapperCreator::commitChange):
2640         (WebCore::JSSVGPODTypeWrapperCreatorForList::commitChange):
2641         * bindings/js/JSSVGPathSegListCustom.cpp:
2642         (WebCore::updatePathSegContextMap):
2643         (WebCore::removeFromPathSegContextMap):
2644         * bindings/scripts/CodeGeneratorJS.pm:
2645         * ksvg2/misc/SVGDocumentExtensions.h:
2646         (WebCore::SVGDocumentExtensions::baseValueMap):
2647         (WebCore::SVGDocumentExtensions::genericContextMap):
2648         (WebCore::SVGDocumentExtensions::baseValue):
2649         (WebCore::SVGDocumentExtensions::setBaseValue):
2650         (WebCore::SVGDocumentExtensions::removeBaseValue):
2651         (WebCore::SVGDocumentExtensions::hasBaseValue):
2652         (WebCore::SVGDocumentExtensions::genericContext):
2653         (WebCore::SVGDocumentExtensions::setGenericContext):
2654         (WebCore::SVGDocumentExtensions::removeGenericContext):
2655         (WebCore::SVGDocumentExtensions::hasGenericContext):
2656         (WebCore::String):
2657         (WebCore::FloatRect):
2658         (WebCore::bool):
2659         (WebCore::double):
2660         * ksvg2/svg/SVGClipPathElement.h:
2661         * ksvg2/svg/SVGElement.h:
2662         (WebCore::SVGElement::notifyAttributeChange):
2663         * ksvg2/svg/SVGPathSegList.cpp:
2664         (WebCore::SVGPathSegList::SVGPathSegList):
2665         (WebCore::SVGPathSegList::context):
2666         * ksvg2/svg/SVGPathSegList.h:
2667         * ksvg2/svg/SVGPatternElement.h:
2668         * ksvg2/svg/SVGPointList.cpp:
2669         (SVGPointList::SVGPointList):
2670         (SVGPointList::context):
2671         * ksvg2/svg/SVGPointList.h:
2672         * ksvg2/svg/SVGStopElement.cpp:
2673         (WebCore::SVGStopElement::parseMappedAttribute):
2674         (WebCore::SVGStopElement::notifyAttributeChange):
2675         * ksvg2/svg/SVGStopElement.h:
2676         * ksvg2/svg/SVGUseElement.cpp:
2677         (WebCore::SVGUseElement::notifyAttributeChange):
2678
2679 2007-01-20  Rob Buis  <buis@kde.org>
2680
2681         Reviewed by Sam.
2682
2683         http://bugs.webkit.org/show_bug.cgi?id=12334
2684         Respect <text> boundaries for svg text selecting
2685
2686         Make sure the text selection for svg stays inside
2687         containing blocks.
2688         Added one manual test since html selection does not
2689         seem to work for SVG and selectSubString for SVG
2690         is not implemented yet.
2691
2692         * manual-tests/svg-text-selection.svg: Added.
2693         * page/EventHandler.cpp:
2694         (WebCore::EventHandler::handleMouseMoveEvent):
2695         * rendering/RenderObject.h:
2696         (WebCore::RenderObject::isSVGText):
2697         * rendering/RenderSVGInlineText.h:
2698         (WebCore::RenderSVGInlineText::isSVGText):
2699         * rendering/RenderSVGText.h:
2700         (WebCore::RenderSVGText::isSVGText):
2701
2702 2007-01-19  Adele Peterson  <adele@apple.com>
2703
2704         Reviewed by Hyatt.
2705
2706         Fix for: <rdar://problem/4697438> REGRESSION: select menu lists match the wrong css rule on www.chainreaction.com
2707
2708         Update the size attribute value for select elements to match the numeric value.  This is a special case since this
2709         attribute is used to determine which control to use.  We want to make sure that the size attribute is valid when we match
2710         CSS rules.
2711
2712         Test: fast/forms/select-size.html
2713
2714         * html/HTMLSelectElement.cpp: (WebCore::HTMLSelectElement::parseMappedAttribute): If the attribute string value is not the
2715           same as its integer value, then update the attribute value to match the integer.
2716         * dom/Attribute.h: Made setValue and setPrefix public.
2717
2718 2007-01-19  John Sullivan  <sullivan@apple.com>
2719
2720         Reviewed by Darin
2721
2722         - WebCore part of fix for: <rdar://problem/4451715> REGRESSION: On some sites, have to 
2723           type a character before username/password autofill kicks in
2724
2725         * loader/FrameLoaderClient.h:
2726         new dispatchDidFinishDocumentLoad call
2727
2728         * loader/FrameLoader.cpp:
2729         (WebCore::FrameLoader::finishedParsing):
2730         call dispatchDidFinishDocumentLoad
2731         
2732         * platform/graphics/svg/SVGImageEmptyClients.h:
2733         (WebCore::SVGEmptyFrameLoaderClient::dispatchDidFinishDocumentLoad):
2734         empty implementation for dispatchDidFinishDocumentLoad
2735
2736 2007-01-19  Adele Peterson  <adele@apple.com>
2737
2738         Reviewed by Hyatt.
2739
2740         Fix for <rdar://problem/4760280> REGRESSION: Bottom portion of text hangs off edge of SELECT element at http://macreviewzone.com/index.php
2741         
2742         Test: fast/forms/control-restrict-line-height.html
2743
2744         * rendering/RenderThemeMac.mm: (WebCore::RenderThemeMac::setFontFromControlSize): Don't honor line-height for controls that
2745           have restricted font size.
2746
2747 2007-01-19  Darin Adler  <darin@apple.com>
2748
2749         Reviewed by Adele.
2750
2751         - fix http://bugs.webkit.org/show_bug.cgi?id=11999
2752           <rdar://problem/4940442> REGRESSION: Incomplete listing in TVListings window (11999)
2753           Fix was to use the actual size of the renderer in the RenderListBox
2754           case, instead of always using the size specified by the select element.
2755
2756         Test: fast/forms/select-list-box-with-height.html
2757
2758         - fix http://bugs.webkit.org/show_bug.cgi?id=11995
2759           <rdar://problem/4901834> REGRESSION(NativeListBox): Focus is not placed on
2760           SELECT after mousing down on OPTION
2761
2762         Test: fast/forms/select-list-box-mouse-focus.html
2763
2764         - fix bug where auto-scrolling was not working in list box select elements
2765
2766         No test yet.
2767
2768         - fix a missing semicolon in the radio/checkbox section of html4.css
2769
2770         Test: fast/forms/radio-no-theme-padding.html
2771
2772         - fix bug where the scroll bars for select elements were pixel-type scroll
2773           bars even though the scrolling is line at a time scrolling
2774
2775         No test.
2776
2777         * html/HTMLSelectElement.cpp:
2778         (WebCore::HTMLSelectElement::selectAll): Removed an explicit call
2779         to repaint, since the RenderListBox now does that in selectionChanged.
2780         (WebCore::HTMLSelectElement::notifyOptionSelected): Call the new
2781         selectionChanged instead of the old setSelectionChanged.
2782         (WebCore::HTMLSelectElement::listBoxDefaultEventHandler): Added a call
2783         to focus. Removed an explicit call to repaint and added a call to the
2784         new setMouseDownMayStartAutoscroll function in EventHandler. Removed an
2785         explicit call to repaint as above.
2786         (WebCore::HTMLSelectElement::updateListBoxSelection): Call the new
2787         selectionChanged instead of the old setSelectionChanged.
2788
2789         * page/EventHandler.h: Added setMouseDownMayStartAutoscroll, needed
2790         because the existing code to set that flag won't get triggered when
2791         the select element's default event handler handles the event.
2792
2793         * rendering/RenderListBox.h: Made ScrollbarClient a private base class.
2794         Removed setSelectionChanged and m_selectionChanged. Added selectionChanged,
2795         which is really just a synonym for repaint for now. Moved valueChanged,
2796         the ScrollbarClient function implementations, and itemHeight into the
2797         private part of the class. Added numVisibleItems() and listHeight() to
2798         the private section. Changed m_vBar to be a RefPtr.
2799
2800         * rendering/RenderListBox.cpp: Removed unneeded includes. Moved all
2801         the constants to the top of the file.
2802         (WebCore::RenderListBox::RenderListBox): Removed initialization of
2803         m_selectionChanged because it was removed and of m_vBar because it's
2804         now a RefPtr which is automaticall initialized.
2805         (WebCore::RenderListBox::~RenderListBox): Removed the explicit deref of
2806         m_vBar because it's a RefPtr. Added null checking for FrameView.
2807         (WebCore::RenderListBox::updateFromElement): Use numItems().
2808         (WebCore::RenderListBox::calcMinMaxWidth): Added null checking for
2809         FrameView and used RefPtr for the newly-created scroll bar.
2810         (WebCore::RenderListBox::size): Tweaked formatting. Also renamed the
2811         misleading minDefaultSize to maxDefaultSize, since it's a maximum.
2812         (WebCore::RenderListBox::numVisibleItems): Added. Used in many places
2813         where size() was used before. This computes the number of rows we have
2814         room for. We don't need a row space after the last row, and this takes
2815         that into account.
2816         (WebCore::RenderListBox::numItems): Tweaked to remove the local variable.
2817         (WebCore::RenderListBox::listHeight): Added. Total height of all the rows
2818         and spaces between them.
2819         (WebCore::RenderListBox::calcHeight): Changed to call itemHeight for the
2820         row height, and to subtract the last row spacing off since we don't need
2821         a space after the last row. Changed the scroll bar setup to make it
2822         correspond to row numbers, not pixel numbers.
2823         (WebCore::RenderListBox::baselinePosition): Moved the comment to the
2824         constant declaration at the top of the file.
2825         (WebCore::RenderListBox::itemBoundingBoxRect): Simplified by using
2826         the itemHeight() function.
2827         (WebCore::RenderListBox::paintObject): Changed to use numItems and
2828         to use numVisibleItems instead of size.
2829         (WebCore::RenderListBox::isPointInScrollbar): Added get() call since
2830         m_vBar is now a RefPtr.
2831         (WebCore::RenderListBox::listIndexAtOffset): Changed to use numItems(),
2832         itemHeight(), and rearranged a min/max combo so it starts with the low,
2833         then the value, then the high value for pinning.
2834         (WebCore::RenderListBox::autoscroll): Use numVisibleItems() instead of
2835         size().
2836         (WebCore::RenderListBox::stopAutoscroll): Removed an unneeded nil check
2837         of the element.
2838         (WebCore::RenderListBox::scrollToRevealElementAtListIndex): Changed
2839         to use numItems() and to use numVisibleItems() instead of size().
2840         Also changed scroll bar code to work more simply now that the scroll
2841         bar is row-based.
2842         (WebCore::RenderListBox::listIndexIsVisible): Changed to use
2843         numVisibleItems() instead of size().
2844         (WebCore::RenderListBox::valueChanged): Simplified since the scrollbar
2845         is now row-based. Also removed an unnecessary null check.
2846         (WebCore::RenderListBox::itemHeight): Updated for name change from
2847         optionsSpacingMiddle to rowSpacing.
2848         (WebCore::RenderListBox::scrollHeight): Changed to use listHeight().
2849         (WebCore::RenderListBox::setScrollTop): Simplified, and removed the code
2850         that does nothing if the computed list index is visible (which did not
2851         make sense for this function and seemed a cut and paste error from the
2852         scrollToReveal function). The scrollbar part is simpler now that it's
2853         row-based.
2854         (WebCore::RenderListBox::windowClipRect): Changed to use document()->view()
2855         so we don't have to include RenderView.h.
2856
2857         * css/html4.css: Added a semicolon I noticed was missing.
2858
2859 2007-01-19  Beth Dakin  <bdakin@apple.com>
2860
2861         Reviewed by Maciej and Darin.
2862
2863         Fix for <rdar://problem/4702420> REGRESSION: Null characters need 
2864         to be stripped from text nodes (townhall.com)
2865
2866         This was a regression from the fix for <rdar://problem/3727939>
2867         Safari strips \0 characters from HTML tags making them valid, which
2868         was fixed with r12652. We still need to strip null characters in
2869         text nodes.
2870
2871         * html/HTMLTokenizer.cpp:
2872         (WebCore::HTMLTokenizer::write): No behavior change here, this is
2873         just to make Darin happy.
2874         (WebCore::HTMLTokenizer::processToken): Call into StringImpl's new 
2875         createStrippingNull function instead of the normal StringImpl 
2876         constructor.
2877         * platform/StringImpl.cpp:
2878         (WebCore::StringImpl::createStrippingNull): Strip null.
2879         * platform/StringImpl.h:
2880
2881 2007-01-19  David Kilzer  <ddkilzer@webkit.org>
2882
2883         Reviewed by NOBODY (no-svg build fix).
2884
2885         * ksvg2/svg/SVGMPathElement.cpp: Added #ifdef SVG_SUPPORT/#endif guards.
2886
2887 2007-01-19  Anders Carlsson  <acarlsson@apple.com>
2888         
2889         Build fix.
2890         
2891         * platform/graphics/svg/SVGImageEmptyClients.h:
2892         (WebCore::SVGEmptyChromeClient::setStatusbarText):
2893
2894 2007-01-18  Anders Carlsson  <acarlsson@apple.com>
2895
2896         Reviewed by Adam.
2897
2898         Move JavaScript alert and status bar functions to the chrome.
2899         
2900         * bindings/js/kjs_window.cpp:
2901         (KJS::WindowFunc::callAsFunction):
2902         * page/Chrome.cpp:
2903         (WebCore::Chrome::runJavaScriptAlert):
2904         (WebCore::Chrome::runJavaScriptConfirm):
2905         (WebCore::Chrome::runJavaScriptPrompt):
2906         (WebCore::Chrome::setStatusBarText):
2907         * page/Chrome.h:
2908         * page/ChromeClient.h:
2909         * page/Frame.cpp:
2910         (WebCore::Frame::setJSStatusBarText):
2911         (WebCore::Frame::setJSDefaultStatusBarText):
2912         * page/Frame.h:
2913         * page/mac/FrameMac.h:
2914         * page/mac/FrameMac.mm:
2915         * page/mac/WebCoreFrameBridge.h:
2916         * platform/graphics/svg/SVGImageEmptyClients.h:
2917         (WebCore::SVGEmptyChromeClient::runJavaScriptAlert):
2918         (WebCore::SVGEmptyChromeClient::runJavaScriptConfirm):
2919         (WebCore::SVGEmptyChromeClient::runJavaScriptPrompt):
2920         (WebCore::SVGEmptyChromeClient::setStatusBarText):
2921
2922 2007-01-19  Zack Rusin  <zack@kde.org>
2923
2924         Fix the build.
2925
2926         * WebCore.pro: Add missing files
2927
2928 2007-01-19  Eric Seidel  <eric@webkit.org>
2929
2930         Reviewed by rwlbuis.
2931
2932         More cleanup to SVGAnimated* classes.
2933
2934         No tests possible (only code cleanup)
2935
2936         * ksvg2/svg/SVGAnimateMotionElement.cpp:
2937         (WebCore::SVGAnimateMotionElement::applyAnimationToValue):
2938         * ksvg2/svg/SVGAnimateMotionElement.h:
2939         * ksvg2/svg/SVGAnimationElement.cpp:
2940         (WebCore::SVGAnimationElement::parseBeginOrEndValue):
2941         (WebCore::SVGAnimationElement::parseMappedAttribute):
2942         (WebCore::SVGAnimationElement::parseClockValue):
2943         (WebCore::SVGAnimationElement::isIndefinite):
2944         * ksvg2/svg/SVGAnimationElement.h:
2945
2946 2007-01-19  Nikolas Zimmermann  <zimmermann@kde.org>
2947
2948         Not reviewed.
2949
2950         Remove accidently commited debug output. Shame on me :-)
2951
2952         * ksvg2/svg/SVGUseElement.cpp:
2953         (WebCore::SVGUseElement::notifyAttributeChange):
2954
2955 2007-01-19  Nikolas Zimmermann  <zimmermann@kde.org>
2956
2957         Reviewed by Eric.
2958
2959         Fixes: http://bugs.webkit.org/show_bug.cgi?id=10410 (SVG Slider example renders completely wrong (inserting <use> dynamically doesn't work))
2960         Fixes: http://bugs.webkit.org/show_bug.cgi?id=11660 (SVG: creation of <use/> elements through scripting/DOM doesn't work)
2961
2962         Added test: svg/custom/use-instanceRoot-modifications.svg
2963         Added test: svg/custom/use-on-g.svg
2964         Added test: svg/custom/use-on-rect.svg
2965         Added test: svg/custom/use-on-symbol-inside-pattern.svg
2966         Added test: svg/custom/use-on-symbol.svg
2967         Added test: svg/custom/use-on-text.svg
2968         Added test: svg/custom/use-transform.svg
2969
2970         Fixes: svg/W3C-SVG-1.1/text-text-04-t.svg (missing use elements)
2971         Fixes: svg/carto.net/button.svg (image buttons didn't appear)
2972         Fixes: svg/carto.net/colourpicker.svg (slider handles finally show up)
2973         Fixes: svg/carto.net/slider.svg (slider handles finally show up)
2974         Fixes: svg/carto.net/window.svg (window decorations show up) 
2975         Fixes: svg/custom/use-forward-refs.svg (missing use elements)
2976
2977         Rewrite <use> support with a real-shadow tree (as the spec demands), and implement SVGElementInstance.
2978         AFAIK we're the first implementing this SVG feature - after ASV3 (!).
2979
2980         * DerivedSources.make:
2981         * WebCore.xcodeproj/project.pbxproj:
2982         * bindings/objc/DOMInternal.h:
2983         * bindings/objc/DOMSVG.h:
2984         * ksvg2/misc/SVGDocumentExtensions.cpp:
2985         (WebCore::SVGDocumentExtensions::reportWarning):
2986         (WebCore::SVGDocumentExtensions::reportError):
2987         (WebCore::SVGDocumentExtensions::addPendingResource):
2988         (WebCore::SVGDocumentExtensions::isPendingResource):
2989         (WebCore::SVGDocumentExtensions::removePendingResource):
2990         (WebCore::SVGDocumentExtensions::mapInstanceToElement):
2991         (WebCore::SVGDocumentExtensions::removeInstanceMapping):
2992         (WebCore::SVGDocumentExtensions::instancesForElement):
2993         * ksvg2/misc/SVGDocumentExtensions.h:
2994         * ksvg2/svg/SVGCircleElement.cpp:
2995         (WebCore::SVGCircleElement::notifyAttributeChange):
2996         * ksvg2/svg/SVGElement.cpp:
2997         (WebCore::SVGElement::insertedIntoDocument):
2998         * ksvg2/svg/SVGElement.h:
2999         (WebCore::SVGElement::buildPendingResource):
3000         * ksvg2/svg/SVGElementInstance.cpp:
3001         (WebCore::SVGElementInstance::SVGElementInstance):
3002         (WebCore::SVGElementInstance::~SVGElementInstance):
3003         (WebCore::SVGElementInstance::clonedElement):
3004         (WebCore::SVGElementInstance::correspondingElement):
3005         (WebCore::SVGElementInstance::correspondingUseElement):
3006         (WebCore::SVGElementInstance::parentNode):
3007         (WebCore::SVGElementInstance::childNodes):
3008         (WebCore::SVGElementInstance::previousSibling):
3009         (WebCore::SVGElementInstance::nextSibling):
3010         (WebCore::SVGElementInstance::firstChild):
3011         (WebCore::SVGElementInstance::lastChild):
3012         (WebCore::SVGElementInstance::appendChild):
3013         (WebCore::SVGElementInstance::updateInstance):
3014         * ksvg2/svg/SVGElementInstance.h:
3015         * ksvg2/svg/SVGElementInstance.idl: Added.
3016         * ksvg2/svg/SVGElementInstanceList.cpp:
3017         (WebCore::SVGElementInstanceList::SVGElementInstanceList):
3018         (WebCore::SVGElementInstanceList::length):
3019         (WebCore::SVGElementInstanceList::item):
3020         * ksvg2/svg/SVGElementInstanceList.h:
3021         * ksvg2/svg/SVGElementInstanceList.idl: Added.
3022         * ksvg2/svg/SVGEllipseElement.cpp:
3023         (WebCore::SVGEllipseElement::notifyAttributeChange):
3024         * ksvg2/svg/SVGGElement.cpp:
3025         * ksvg2/svg/SVGGElement.h:
3026         (WebCore::SVGGElement::contextElement):
3027         * ksvg2/svg/SVGGradientElement.cpp:
3028         * ksvg2/svg/SVGGradientElement.h:
3029         * ksvg2/svg/SVGHiddenElement.h: Added.
3030         (WebCore::SVGHiddenElement::Type):
3031         (WebCore::SVGHiddenElement::~SVGHiddenElement):
3032         (WebCore::SVGHiddenElement::localName):
3033         * ksvg2/svg/SVGImageElement.cpp:
3034         (WebCore::SVGImageElement::notifyAttributeChange):
3035         * ksvg2/svg/SVGLineElement.cpp:
3036         (WebCore::SVGLineElement::notifyAttributeChange):
3037         * ksvg2/svg/SVGPathElement.cpp:
3038         (WebCore::SVGPathElement::notifyAttributeChange):
3039         * ksvg2/svg/SVGPatternElement.cpp:
3040         * ksvg2/svg/SVGPatternElement.h:
3041         * ksvg2/svg/SVGPolyElement.cpp:
3042         (WebCore::SVGPolyElement::notifyAttributeChange):
3043         * ksvg2/svg/SVGRectElement.cpp:
3044         (WebCore::SVGRectElement::notifyAttributeChange):
3045         * ksvg2/svg/SVGStyledElement.cpp:
3046         (WebCore::SVGStyledElement::notifyAttributeChange):
3047         (WebCore::SVGStyledElement::updateElementInstance):
3048         * ksvg2/svg/SVGStyledElement.h:
3049         * ksvg2/svg/SVGUseElement.cpp:
3050         (WebCore::SVGUseElement::instanceRoot):
3051         (WebCore::SVGUseElement::animatedInstanceRoot):
3052         (WebCore::SVGUseElement::hasChildNodes):
3053         (WebCore::SVGUseElement::insertedIntoDocument):
3054         (WebCore::SVGUseElement::buildPendingResource):
3055         (WebCore::SVGUseElement::createRenderer):
3056         (WebCore::SVGUseElement::buildShadowTree):
3057         (WebCore::SVGUseElement::recursiveShadowTreeBuilder):
3058         (WebCore::dumpShadowTree):
3059         (WebCore::SVGUseElement::addShadowTree):
3060         * ksvg2/svg/SVGUseElement.h:
3061         * ksvg2/svg/SVGUseElement.idl:
3062
3063 2007-01-19  Eric Seidel  <eric@webkit.org>
3064
3065         Reviewed by rwlbuis.
3066
3067         Add support for SVGMPathElement parsing.
3068
3069         No test cases possible (SVGAnimateMotion doesn't work yet)
3070
3071         * WebCore.xcodeproj/project.pbxproj:
3072         * ksvg2/svg/SVGAnimateMotionElement.cpp:
3073         (WebCore::SVGAnimateMotionElement::animationPath):
3074         * ksvg2/svg/SVGMPathElement.cpp: Added.
3075         (WebCore::SVGMPathElement::SVGMPathElement):
3076         (WebCore::SVGMPathElement::~SVGMPathElement):
3077         (WebCore::SVGMPathElement::parseMappedAttribute):
3078         (WebCore::SVGMPathElement::pathElement):
3079         * ksvg2/svg/SVGMPathElement.h: Added.
3080         * ksvg2/svg/SVGNumberList.cpp:
3081         (WebCore::SVGNumberList::parse): fix typo in comment
3082         * ksvg2/svg/svgtags.in: add back mpath
3083
3084 2007-01-19  Eric Seidel  <eric@webkit.org>
3085
3086         Reviewed by rwlbuis.
3087
3088         Implement better parsing for keyTimes, keySplines and keyPoints.
3089
3090         Unfortunately none of this code is used much yet, thus isn't very testable.
3091
3092         * ksvg2/svg/SVGAnimateMotionElement.cpp:
3093         (WebCore::SVGAnimateMotionElement::parseMappedAttribute):
3094         * ksvg2/svg/SVGAnimationElement.cpp:
3095         (WebCore::SVGAnimationElement::parseKeyNumbers):
3096         (WebCore::parseKeySplines):
3097         (WebCore::SVGAnimationElement::parseMappedAttribute):
3098         * ksvg2/svg/SVGAnimationElement.h:
3099         * ksvg2/svg/SVGNumberList.cpp:
3100         (WebCore::SVGNumberList::parse):
3101
3102 2007-01-18  Adam Roben  <aroben@apple.com>
3103
3104         Reviewed by Beth.
3105
3106         Fix: <rdar://problem/4939672> REGRESSION: With text selected that is
3107         not a link, the "Remove Link" contextual menu item remains active
3108
3109         * platform/ContextMenuItem.h: Added enabled method.
3110         * platform/qt/ContextMenuItemQt.cpp:
3111         (WebCore::ContextMenuItem::enabled): Implemented.
3112         * platform/mac/ContextMenuItemMac.mm:
3113         (WebCore::ContextMenuItem::enabled): Ditto.
3114         * platform/mac/ContextMenuMac.mm:
3115         (-[WebCoreMenuTarget validateMenuItem:]): Implemented to fulfill the
3116         NSMenuValidation protocol.
3117         
3118 2007-01-18  Beth Dakin  <bdakin@apple.com>
3119
3120         Reviewed by Adele.
3121
3122         Fix for <rdar://problem/4939558> REGRESSION: "Search in Google", 
3123         "Search in Spotlight" and "Look up in Dictionary" are missing 
3124         initially from the contextual menu
3125
3126         The bug here is that we select the we were selecting the word after 
3127         the context menu event was dispatched and after the context menu 
3128         was built up.
3129
3130         * page/EventHandler.cpp:
3131         (WebCore::EventHandler::sendContextMenuEvent): Select the word 
3132         before dispatching the event. It is safe to remove the check for 
3133         swallowEvent since WebCore context menus ensure that we always 
3134         swallow the event anyway.
3135
3136 2007-01-18  Mark Rowe  <mrowe@apple.com>
3137
3138         Reviewed by Tim H.
3139
3140         Fix for http://bugs.webkit.org/show_bug.cgi?id=7926
3141         Bug 7926: Crash using -callWebScriptMethod to access offsetTop property
3142
3143         * bindings/objc/WebScriptObject.mm:
3144         (-[WebScriptObject callWebScriptMethod:withArguments:]): Bail out early if function value is an immediate,
3145         or if the function object is not callable.
3146
3147 2007-01-18  Sam Weinig  <sam@webkit.org>
3148
3149         Reviewed by Maciej.
3150
3151         Patch for http://bugs.webkit.org/show_bug.cgi?id=11853
3152         REGRESSION (r17352): Whitespace in <title> is rendered
3153
3154         * loader/DocumentLoader.cpp:
3155         (WebCore::canonicalizedTitle): Changed to also collapse internal
3156         whitespace.  This required removing an optimization that is no
3157         longer possible.
3158         * manual-tests/title-internal-whitespace.html: Added.
3159
3160 2007-01-18  Mitz Pettel  <mitz@webkit.org>
3161
3162         Reviewed by Maciej.
3163
3164         - fix http://bugs.webkit.org/show_bug.cgi?id=12039
3165           Assertion failure in WebCore::Font::primaryFont
3166
3167         Test: fast/text/font-initial.html
3168
3169         * css/cssstyleselector.cpp:
3170         (WebCore::CSSStyleSelector::applyProperty): Give 'font: initial' the
3171         Standard generic family. This makes the FontDescription different from
3172         that of the initial font of a GraphicsContext, ensuring that the latter
3173         will not be used.
3174
3175 2007-01-18  Mitz Pettel  <mitz@webkit.org>
3176
3177         Reviewed by Darin.
3178
3179         - fix http://bugs.webkit.org/show_bug.cgi?id=11451
3180           REGRESSION: Dell.com does not render correctly in ToT (stylesheet not loaded)
3181
3182         Test: http/tests/misc/css-accept-any-type.html
3183
3184         * loader/CachedCSSStyleSheet.cpp:
3185         (WebCore::CachedCSSStyleSheet::CachedCSSStyleSheet): Changed the accept header
3186         for stylesheets to "text/css,*/*;q=0.1" to match Firefox, accepting CSS served
3187         as any type.
3188
3189 2007-01-18  Mitz Pettel  <mitz@webkit.org>
3190
3191         Reviewed by Darin.
3192
3193         - fix http://bugs.webkit.org/show_bug.cgi?id=11271
3194         REGRESSION (r12358): Text in display: table unselectable
3195
3196         Test: editing/selection/display-table-text.html
3197
3198         * editing/htmlediting.cpp:
3199         (WebCore::isTableElement): Changed to return false for text nodes.
3200
3201 2007-01-18  Mitz Pettel  <mitz@webkit.org>
3202
3203         Reviewed by Darin.
3204
3205         - fix http://bugs.webkit.org/show_bug.cgi?id=6218
3206           CSS1: WebTextRenderer caches and re-uses fallback renderers that are based on family lists
3207
3208         This patch takes character-to-glyph mapping out of FontData and instead makes
3209         each Font keep its own mapping, using a shared set of glyph page fallback trees.
3210
3211         For each page number there is (at most) one tree. A path from the root to a
3212         node in the tree corresponds to a fallback list of FontDatas. The node points to
3213         a page (which may be shared with other nodes) that maps each character in its range
3214         to a glyph in the first FontData in the fallback list that has it, or to 0 if none of
3215         the FontDatas has a glyph for that character. A special kind of node, that can
3216         only occur as a leaf, corresponds to using system fallback fonts after the list
3217         has been exhausted. This prevents system fallback from polluting non-leaf
3218         nodes.
3219
3220         Nodes and pages are initialized lazily and employ "copy on write".
3221
3222         * CMakeLists.txt:
3223         * WebCore.pro:
3224         * WebCore.vcproj/WebCore/WebCore.vcproj:
3225         * WebCore.xcodeproj/project.pbxproj:
3226         * WebCoreSources.bkl:
3227         * platform/Font.cpp:
3228         (WebCore::WidthIterator::WidthIterator): Removed substituteFontData.
3229         (WebCore::WidthIterator::advance): Moved all character-to-glyph mapping logic out
3230         of here and replaced it with a call to Font::glyphDataForCharacter().
3231         (WebCore::Font::Font):
3232         (WebCore::Font::operator=):
3233         (WebCore::Font::glyphDataForCharacter): Added. This method performs the lookup in the
3234         page fallback trees, triggering lazy initialization as needed, and caching pointers to
3235         the retrieved page tree nodes in the font.
3236         (WebCore::Font::update):
3237         (WebCore::Font::drawSimpleText):
3238         (WebCore::Font::floatWidth):
3239         (WebCore::Font::floatWidthForSimpleText): Removed substituteFont argument.
3240         (WebCore::Font::offsetForPositionForSimpleText):
3241         * platform/Font.h:
3242         * platform/FontData.cpp:
3243         (WebCore::FontData::FontData):
3244         * platform/FontData.h:
3245         (WebCore::FontData::missingGlyphData): Added. Returns the "missing glyph" GlyphData for
3246         this FontData.
3247         * platform/GlyphMap.cpp: Removed.
3248         * platform/GlyphMap.h: Removed.
3249         * platform/GlyphPageTreeNode.cpp: Renamed GlyphMap.cpp to this.
3250         (WebCore::GlyphPageTreeNode::getRoot): Added. Returns the root of the page fallback tree for
3251         the given page number.
3252         (WebCore::GlyphPageTreeNode::initializePage): Added. Helper method that initializes the page
3253         pointer of a node, possibly to a pointer to another node's page or to 0.
3254         (WebCore::GlyphPageTreeNode::getChild): Added.
3255         * platform/GlyphPageTreeNode.h: Renamed GlyphMap.h to this.
3256         (WebCore::GlyphPage::glyphDataForCharacter):
3257         (WebCore::GlyphPage::setGlyphDataForCharacter):
3258         (WebCore::GlyphPage::setGlyphDataForIndex):
3259         (WebCore::GlyphPageTreeNode::GlyphPageTreeNode):
3260         (WebCore::GlyphPageTreeNode::getRootChild):
3261         (WebCore::GlyphPageTreeNode::parent):
3262         (WebCore::GlyphPageTreeNode::page):
3263         (WebCore::GlyphPageTreeNode::level):
3264         (WebCore::GlyphPageTreeNode::isSystemFallback): Added. Returns whether the node corresponds
3265         to the system providing fallback fonts, which is done on a character-by-character basis.
3266         * platform/gdk/GlyphMapGdk.cpp: Removed.
3267         * platform/gdk/GlyphPageTreeNodeGdk.cpp: Renamed GlyphMapGdk.cpp to this.
3268         (WebCore::GlyphPage::fill):
3269         * platform/mac/FontDataMac.mm:
3270         (WebCore::FontData::platformInit):
3271         * platform/mac/FontMac.mm:
3272         (WebCore::Font::Font):
3273         * platform/mac/GlyphMapMac.cpp: Removed.
3274         * platform/mac/GlyphPageTreeNodeMac.cpp: Renamed GlypMapMac.cpp to this.
3275         (WebCore::GlyphPage::fill): Changed to return false if the font has no glyphs in the page.
3276         * platform/qt/GlyphMapQt.cpp: Removed.
3277         * platform/qt/GlyphPageTreeNodeQt.cpp: Renamed GlyphMapQt.cpp to this.
3278         (WebCore::GlyphPage::fill):
3279         * platform/win/GlyphMapWin.cpp: Removed.
3280         * platform/win/GlyphPageTreeNodeWin.cpp: Renamed GlyphMapWin to this.
3281         (WebCore::GlyphPage::fill):
3282
3283 2007-01-18  Mitz Pettel  <mitz@webkit.org>
3284
3285         Reviewed by Darin.
3286
3287         - fix http://bugs.webkit.org/show_bug.cgi?id=9952
3288           REGRESSION: Repro crash when dragging an image from the window to the address bar
3289
3290         * page/FrameView.cpp:
3291         (WebCore::FrameView::~FrameView): Removed the call to Document::detach(). If this
3292         view is the current view, then the Frame should have already detached the document.
3293         Added an assertion that this is the case. If this view is not the current view,
3294         then it cannot access its document, but the page cache should have detached it already.
3295         Similarly, changed to call RenderPart::setWidget() only if this is the current view
3296         in the frame.
3297         (WebCore::FrameView::adjustViewSize): Added an assertion that this view is the current
3298         view in the frame.
3299         (WebCore::FrameView::layout): Ditto.
3300         (WebCore::FrameView::scheduleRelayout): Ditto.
3301         (WebCore::FrameView::scheduleRelayoutOfSubtree): Ditto.
3302         (WebCore::FrameView::windowClipRect): Ditto.
3303
3304 2007-01-18  Eric Seidel  <eric@webkit.org>
3305
3306         Reviewed by bdash.
3307
3308         No test needed, removed bogus debug-only ASSERT.
3309
3310         * rendering/RenderSVGContainer.cpp:
3311         (WebCore::RenderSVGContainer::paint):
3312
3313 2007-01-18  Alice Liu  <alice.liu@apple.com>
3314
3315         Build Fix
3316
3317         * platform/mac/PasteboardMac.mm:
3318         (WebCore::Pasteboard::writeSelection):
3319
3320 2007-01-18  Alice Liu  <alice.liu@apple.com>
3321
3322         Reviewed by Mark Rowe.
3323
3324         Fixes the leaks from my last patch, except for the first change below which is a missing delegate call for Mail purposes
3325
3326         * editing/Editor.cpp:
3327         (WebCore::Editor::cut):
3328         * platform/Pasteboard.h:
3329         * platform/mac/PasteboardMac.mm:
3330         (WebCore::Pasteboard::Pasteboard):
3331         (WebCore::Pasteboard::clear):
3332         (WebCore::Pasteboard::writeSelection):
3333         (WebCore::Pasteboard::writeURL):
3334         (WebCore::Pasteboard::plainText):
3335         (WebCore::Pasteboard::documentFragment):
3336
3337 2007-01-18  David Hyatt  <hyatt@apple.com>
3338
3339         Make sure layer autoscrolling puts the event coordinates into the layer's coordinate space before
3340         calling hitTest on it.  Fixes "flashy" selection in textareas.
3341
3342         Reviewed by darin
3343
3344         * rendering/RenderLayer.cpp:
3345         (WebCore::RenderLayer::autoscroll):
3346         * rendering/RenderTextControl.cpp:
3347         (WebCore::RenderTextControl::nodeAtPoint):
3348
3349 2007-01-18  Anders Carlsson  <acarlsson@apple.com>
3350
3351         Reviewed by Adam.
3352
3353         Get rid of ResourceLoaderMac.mm and make willCacheResponse platform-independent.
3354         
3355         * loader/ResourceLoader.cpp:
3356         (WebCore::ResourceLoader::willCacheResponse):
3357         * loader/ResourceLoader.h:
3358         * loader/mac/ResourceLoaderMac.mm: Removed.
3359         * platform/network/ResourceHandleClient.h:
3360         (WebCore::):
3361         (WebCore::ResourceHandleClient::willCacheResponse):
3362         (WebCore::ResourceHandleClient::willStopBufferingData):
3363         * platform/network/mac/ResourceHandleMac.mm:
3364         (-[WebCoreResourceHandleAsDelegate connection:willCacheResponse:]):
3365
3366 2007-01-18  Maciej Stachowiak  <mjs@apple.com>
3367
3368         Reviewed by John.
3369
3370         - fixed <rdar://problem/4887416> REGRESSION (SearchField): Assertion failure in HTMLInputElement::setValueFromRenderer when editing via drag and drop (11846)
3371         http://bugs.webkit.org/show_bug.cgi?id=11846
3372         
3373         * editing/ReplaceSelectionCommand.cpp:
3374         (WebCore::ReplaceSelectionCommand::doApply): Don't insert extra paragraph separators to avoid
3375         nesting blocks in plaintext mode, since that's not an issue under normal circumstances.
3376         * html/HTMLInputElement.h:
3377         * manual-tests/drag-move-in-search-field.html: Added.
3378         * rendering/RenderTextControl.cpp:
3379         (WebCore::RenderTextControl::subtreeHasChanged): constrain the value; we'd
3380         rather truncate it than end up with an illegal value here.
3381
3382 2007-01-18  Simon Hausmann  <hausmann@kde.org>
3383
3384         Reviewed by Zack.
3385
3386         * WebCore.pro: Ha^H^HFix to support massive parallel builds.
3387
3388 2007-01-18  David Kilzer  <ddkilzer@kilzer.net>
3389
3390         Reviewed by Darin and Mitz.
3391
3392         - fix http://bugs.webkit.org/show_bug.cgi?id=12305
3393           REGRESSION: Images do not load in video sections on CNN.com homepage
3394
3395         <rdar://problem/4931480> REGRESSION: Images do not load in video sections on CNN.com homepage (12305)
3396
3397         Test: fast/dom/HTMLImageElement/image-lowsrc-getset.html
3398
3399         * html/HTMLAttributeNames.in: Added lowsrc.
3400         * html/HTMLImageElement.cpp:
3401         (WebCore::HTMLImageElement::isURLAttribute): Added lowsrc.
3402         (WebCore::HTMLImageElement::lowsrc): Added.
3403         (WebCore::HTMLImageElement::setLowsrc): Added.
3404         * html/HTMLImageElement.h: Added lowsrc and setLowsrc.
3405         * html/HTMLImageElement.idl: Added lowsrc.
3406
3407 2007-01-18  Simon Hausmann  <hausmann@kde.org>
3408
3409         Reviewed by Zack.
3410
3411         * WebCore.pro: Remove generated files on make clean.
3412
3413 2007-01-17  Alice Liu  <alice.liu@apple.com>
3414
3415         Reviewed by Harrison.
3416
3417         Fix for <rdar://problem/4894155> REGRESSION: Extra line break is pasted with content into message body after choosing File - Paste
3418
3419         Migration of some editing code from WebHTMView to WebCore::Editor
3420         resulted in not calling pasteboardTypesForSelection, which Mail was
3421         overriding for the special purpose of adding a type to the
3422         pasteboard after WebKit did.  This patch adds 2 separate code paths
3423         for Tiger and Leopard.  On Tiger we give in and call the WebView's
3424         pasteboardTypesForSelection.  On Leopard we call a delegate after
3425         the pasteboard types are set. 
3426
3427         * bridge/EditorClient.h:
3428         * editing/Editor.h:
3429         * platform/Pasteboard.h:
3430         * platform/graphics/svg/SVGImageEmptyClients.h:
3431         (WebCore::SVGEmptyEditorClient::didSetSelectionTypesForPasteboard):
3432         (WebCore::SVGEmptyEditorClient::pasteboardTypesForSelection):
3433         * platform/mac/PasteboardMac.mm:
3434         (WebCore::Pasteboard::Pasteboard):
3435         (WebCore::Pasteboard::clear):
3436         (WebCore::Pasteboard::writeSelection):
3437         (WebCore::Pasteboard::writeURL):
3438         (WebCore::Pasteboard::plainText):
3439         (WebCore::Pasteboard::documentFragment):
3440
3441 2007-01-17  John Sullivan  <sullivan@apple.com>
3442
3443         Reviewed by Darin
3444
3445         - WebCore part of fix for <rdar://problem/4462420> REGRESSION: Mail hangs during 
3446           Replace All if the replacement string contains the search string
3447         
3448         * page/Frame.h:
3449         * page/Frame.cpp:
3450         (WebCore::Frame::findString):
3451         new startInSelection parameter -- if true, search starts looking in selection; if false,
3452         search starts looking after the selection
3453         
3454         * page/mac/WebCoreFrameBridge.h:
3455         * page/mac/WebCoreFrameBridge.mm:
3456         (-[WebCoreFrameBridge searchFor:direction:caseSensitive:wrap:startInSelection:]):
3457         new startInSelection parameter, passed through to Frame::findString()
3458
3459         * editing/JSEditor.cpp:
3460         pass false for new findString parameter, to match old behavior
3461
3462 2007-01-17  Beth Dakin  <bdakin@apple.com>
3463
3464         Rubber stamped by Darin.
3465
3466         * rendering/HitTestResult.cpp: Just added a comment.
3467
3468 2007-01-17  Justin Garcia  <justin.garcia@apple.com>
3469
3470         Reviewed by darin
3471         
3472         <rdar://problem/4920488>
3473         REGRESSION: A crash occurs at WebCore::Range::processContents () when removing formatting from selected text (that contains a link)
3474
3475         * dom/Range.cpp:
3476         (WebCore::Range::commonAncestorContainer): Return null if the nodes
3477         don't have a common ancestor.  As a side effect, the public 
3478         commonAncestorContainer now sets an exception if the Range starts
3479         in one document and ends in another, or starts or ends in a tree
3480         that's been removed from the document.  The spec doesn't cover
3481         this and there is no precedent in other browsers for this case because
3482         they don't allow invalid Ranges (you can create one with WebCore
3483         by removing a node that contains the start/end of a Range).
3484         (WebCore::Range::compareBoundaryPoints): If the the two positions
3485         are in nodes that have no common ancestor, return null.  This doesn't
3486         change the behavior of the public compareBoundaryPoints: it already
3487         throws an exception if the two positions are in nodes that don't have
3488         a common ancestor.  This follows the spec.
3489
3490 2007-01-17  John Sullivan  <sullivan@apple.com>
3491
3492         The one word was typed by me, but only after debugging for a long time with Darin.
3493
3494         - fixed <rdar://problem/4912002> REGRESSION: Series of words marked as a single misspelled word
3495
3496         * editing/TextIterator.cpp:
3497         (WebCore::WordAwareIterator::WordAwareIterator):
3498         We were creating a TextIterator with the default kind, but WordAwareIterator is designed to work
3499         in concert with CharacterIterator, so they need to use the same kind. CharacterIterator uses
3500         kind RUNFINDER, so WordAwareIterator needs to do so also.
3501
3502 2007-01-17  Adele Peterson  <adele@apple.com>
3503
3504         Reviewed by Brady.
3505
3506         Fix for <rdar://problem/4900895> REGRESSION: onChange doesn't always fire for popups that have had value changed by JS
3507
3508         No test case since you need to open up the menu to fire onChange.
3509
3510         * html/HTMLSelectElement.cpp: (WebCore::HTMLSelectElement::setSelectedIndex):
3511           Keep track of m_lastOnChangeIndex even when we're not firing onChange.  Since
3512           the selected index has changed, we still want the m_lastOnChangeIndex to be up to date when we compare
3513           it later.  This matches our behavior in Safari 2.0.
3514
3515 2007-01-17  Adele Peterson  <adele@apple.com>
3516
3517         Reviewed by Darin and John.
3518
3519         - Fix for <rdar://problem/4816550> REGRESSION: autoscrolling doesn't work after double-click
3520
3521         * page/EventHandler.cpp: (WebCore::EventHandler::handleMousePressEvent): Set swallowEvent bool instead
3522           of returning early for double and triple clicks.
3523
3524 2007-01-17  Darin Adler  <darin@apple.com>
3525
3526         Reviewed by Hyatt.
3527
3528         * rendering/RenderObject.h: Removed unused nextEditable and previousEditable.
3529         * rendering/RenderObject.cpp: Ditto.
3530
3531 2007-01-17  Darin Adler  <darin@apple.com>
3532
3533         Reviewed by Maciej.
3534
3535         - fix http://bugs.webkit.org/show_bug.cgi?id=12278
3536           <rdar://problem/4928705> REGRESSION(r13070): Dragged image size includes padding (12278)
3537
3538         * WebCore.exp: Added HitTestResult::imageRect,
3539         removed HitTestResult::boundingBox.
3540
3541         * rendering/HitTestResult.h: