2008-01-07 Steve Falkenburg <sfalken@apple.com>
[WebKit-https.git] / WebCore / ChangeLog
1 2008-01-07  Steve Falkenburg  <sfalken@apple.com>
2
3         Add version resource to QTMovieWin.dll
4         
5         Reviewed by Adam.
6
7         * WebCore.vcproj/PRODUCTVERSION: Copied from ../WebKit/win/WebKit.vcproj/PRODUCTVERSION.
8         * WebCore.vcproj/QTMovieWin.rc: Added.
9         * WebCore.vcproj/QTMovieWin.vcproj:
10         * WebCore.vcproj/VERSION: Copied from ../WebKit/win/WebKit.vcproj/VERSION.
11         * WebCore.vcproj/auto-version.sh: Copied from ../WebKit/win/WebKit.vcproj/auto-version.sh.
12
13 2008-01-07  Dan Bernstein  <mitz@apple.com>
14
15         Build fix.
16
17         * platform/graphics/qt/FontCustomPlatformData.cpp:
18         (WebCore::FontCustomPlatformData::~FontCustomPlatformData): Added.
19         Calls QFontDatabase::removeApplicationFont().
20         * platform/graphics/qt/FontCustomPlatformData.h:
21         * platform/graphics/qt/GlyphPageTreeNodeQt.cpp:
22         (WebCore::GlyphPageTreeNode::pruneTreeCustomFontData): Removed the
23         implementation because Qt does not use the WebCore glyph cache.
24
25 2008-01-07  Dan Bernstein  <mitz@apple.com>
26
27         Reviewed by Oliver Hunt.
28
29         - fix an assertion failure in svg/W3C-SVG-1.1/fonts-elem-03-b.svg on
30           Tiger and multiple SVG layout test failures on Leopard.
31
32         * css/CSSSegmentedFontFace.cpp:
33         (WebCore::CSSSegmentedFontFace::getFontData): Avoid returning an
34         empty SegmentedFontData.
35         * platform/graphics/mac/FontCustomPlatformData.cpp:
36         (WebCore::createFontCustomPlatformData): Avoid creating a font that
37         contains no glyphs. On Leopard, ATS might create such a font given
38         data in an unsupported format (such as SVG).
39
40 2008-01-07  Steve Falkenburg  <sfalken@apple.com>
41
42         Build fix.
43
44         * WebCore.vcproj/WebCore.sln:
45         * WebCore.vcproj/WebCore.submit.sln:
46
47 2008-01-07  Oliver Hunt  <oliver@apple.com>
48
49         Reviewed by Niko.
50
51         Fix painting of SVG <image> when the image must be scaled to retain aspect ratio
52
53         Test: svg/custom/image-with-aspect-ratio-stretch.svg
54
55         * rendering/RenderSVGImage.cpp:
56         (WebCore::RenderSVGImage::adjustRectsForAspectRatio):
57
58 2008-01-07  Dan Bernstein  <mitz@apple.com>
59
60         Build fix.
61
62         * platform/graphics/qt/GlyphPageTreeNodeQt.cpp:
63         (WebCore::GlyphPageTreeNode::pruneTreeCustomFontData):
64
65 2008-01-07  Adele Peterson  <adele@apple.com>
66
67         Add missing newline.
68
69         * rendering/MediaControlElements.cpp:
70
71 2008-01-07  Jon Honeycutt  <jhoneycutt@apple.com>
72
73         Reviewed by Hyatt.
74
75         <rdar://problem/5673489> Safari does not render windowless plugins in an
76         iframe when opacity < 1.0
77
78         Plugins in transparency layers handle their own world transforms, so
79         only apply the horizontal/vertical transform if we are not in a
80         transparency layer.
81
82         * platform/graphics/GraphicsContext.h: Add a Windows-platform-only
83         inTransparencyLayer() function
84         * platform/win/GraphicsContextWin.cpp:
85         (WebCore::GraphicsContext::getWindowsContext): Use inTransparencyLayer()
86         (WebCore::GraphicsContext::inTransparencyLayer):
87         (WebCore::GraphicsContext::releaseWindowsContext): Use
88         inTransparencyLayer()
89         * plugins/win/PluginViewWin.cpp:
90         (WebCore::PluginViewWin::paint): When retrieving the HDC, use the rect
91         relative to the window. Pass m_isTransparent to
92         get/releaseWindowsContext(). Only set the world transform if we are not
93         in a transparency layer.
94
95 2008-01-07  Adele Peterson  <adele@apple.com>
96
97         Build fix.  Need to wrap these classes in #if ENABLE(VIDEO)
98
99         * rendering/MediaControlElements.cpp:
100         * rendering/MediaControlElements.h:
101
102 2008-01-07  Nikolas Zimmermann  <zimmermann@kde.org>
103
104         Reviewed by Mark.
105
106         Enable SVG_FONTS by default.
107
108         * Configurations/WebCore.xcconfig:
109         * WebCore.vcproj/build-generated-files.sh:
110
111 2008-01-07  Dan Bernstein  <mitz@apple.com>
112
113         Build fix.
114
115         * platform/graphics/qt/SimpleFontDataQt.cpp:
116         (WebCore::SimpleFontData::SimpleFontData):
117         (WebCore::SimpleFontData::~SimpleFontData):
118
119 2008-01-07  Adam Barth  <hk9565@gmail.com>
120
121         Reviewed by Sam Weinig
122
123         Fixes: http://bugs.webkit.org/show_bug.cgi?id=16523
124         <rdar://problem/5657447>
125
126         When a frame is created with the URL "about:blank" or "", it should
127         inherit its SecurityOrigin from its opener.  However, once it has
128         decided on that SecurityOrigin, it should not change its mind.
129         Prior to this patch, several events could induce the frame to change
130         its SecurityOrigin, permitting an attacker to inject script into an
131         arbitrary SecurityOrigin.
132
133         This patch makes several changes:
134
135         1) Documents refuse to change from one SecurityOrigin to another
136            unless explicitly instructed to do so.
137
138         2) Navigating to a JavaScript URL that produces a value
139            preserves the current SecurityOrigin explicitly instead of
140            relying on the URL to preserve the origin (which fails for
141            about:blank URLs and SecurityOrigins with document.domain set).
142
143            Ideally, we should not preserve the URL at all.  Instead, the
144            frame's URL should be the JavaScript URL, as in Firefox, but this
145            would require changes that are too risky for this patch.  I'll
146            file this as a separate issue.
147
148         3) Various methods of navigating to JavaScript URLs were not
149            properly handling JavaScript that returned a value (and should
150            therefore replace the current document).  This patch unifies
151            those code paths with the path that works.
152
153            There are still a handful of bugs relating to the handling of
154            JavaScript URLs, but I'll file those as separate issues.
155
156         Tests: http/tests/security/aboutBlank/xss-DENIED-navigate-opener-document-write.html
157                http/tests/security/aboutBlank/xss-DENIED-navigate-opener-javascript-url.html
158                http/tests/security/aboutBlank/xss-DENIED-set-opener.html
159
160         * dom/Document.cpp:
161         (WebCore::Document::initSecurityOrigin):
162         * dom/Document.h:
163         (WebCore::Document::setSecurityOrigin):
164         * loader/FrameLoader.cpp:
165         (WebCore::FrameLoader::changeLocation):
166         (WebCore::FrameLoader::urlSelected):
167         (WebCore::FrameLoader::requestFrame):
168         (WebCore::FrameLoader::submitForm):
169         (WebCore::FrameLoader::executeIfJavaScriptURL):
170         (WebCore::FrameLoader::begin):
171         * loader/FrameLoader.h:
172         * platform/SecurityOrigin.cpp:
173         (WebCore::SecurityOrigin::setForURL):
174         (WebCore::SecurityOrigin::createForFrame):
175         * platform/SecurityOrigin.h:
176
177 2008-01-07  Adele Peterson  <adele@apple.com>
178
179         Forgot to check in these changes in my last checkin.
180
181         * rendering/RenderThemeSafari.cpp:
182
183 2008-01-07  Dan Bernstein  <mitz@apple.com>
184
185         Build fixes.
186
187         * WebCore.pro:
188         * platform/graphics/qt/FontCacheQt.cpp:
189         (WebCore::FontCache::getCachedFontData):
190
191 2008-01-07  Timothy Hatcher  <timothy@apple.com>
192
193         Reviewed by John Sullivan.
194
195         <rdar://problem/5674119> Make the Web Inspector toolbar the normal size when not docked
196
197         * page/inspector/inspector.css: Changed CSS rules to have the toolbar and buttons be
198           normal height when not docked, and small when docked. Also added some cursor properties
199           prevent showing the text cursor over areas that are not selectable.
200         * page/inspector/Images: A few images added and old ones removed or renamed.
201
202 2008-01-07  Alp Toker  <alp@atoker.com>
203
204         Prospective GTK+ autotools/qmake VIDEO build fix for breakage
205         introduced in r29257.
206
207         * GNUmakefile.am:
208         * WebCore.pro:
209
210 2008-01-07  Nikolas Zimmermann  <zimmermann@kde.org>
211
212         Reviewed by Oliver.
213
214         Build fix affecting all builds - again related to the unicode-range addition.
215
216         * css/CSSFontSelector.cpp:
217         (WebCore::CSSFontSelector::addFontFaceRule):
218         * css/SVGCSSFontFace.cpp:
219         (WebCore::SVGCSSFontFace::SVGCSSFontFace):
220         * css/SVGCSSFontFace.h:
221         * rendering/RenderSVGText.cpp:
222         * svg/SVGFont.cpp:
223         (WebCore::svgFontAndFontFaceElementForFontData):
224         (WebCore::floatWidthMissingGlyphCallback):
225         (WebCore::drawTextMissingGlyphCallback):
226         * svg/SVGFontFaceElement.cpp:
227
228 2008-01-07  Adele Peterson  <adele@apple.com>
229
230         Reviewed by Antti, Adam, and Mitz.
231
232         WebCore part of fix for 
233         <rdar://problem/5619073> Updated look for <video> controls
234         <rdar://problem/5619057> Add volume control to video controls
235
236         * WebCore.base.exp: Added symbols for WebKitSystemInterface drawing methods.
237         * WebCore.xcodeproj/project.pbxproj: Added MediaControlElements.h/cpp
238         * WebCore.vcproj/WebCore.vcproj: ditto.
239
240         * css/CSSPrimitiveValueMappings.h: (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Added cases for new appearances.
241         * css/CSSSelector.cpp: (WebCore::CSSSelector::extractPseudoType): Added cases for new types.
242         * css/CSSSelector.h: (WebCore::CSSSelector::): Added new pseudo elements.
243         * css/CSSStyleSelector.cpp: (WebCore::CSSStyleSelector::checkOneSelector): ditto.
244         * css/CSSValueKeywords.in: Added keywords for new control appearance styles.
245         * css/html4.css: Added new styles for new controls.
246
247         * html/HTMLMediaElement.cpp: (WebCore::HTMLMediaElement::canPlay): Added. Takes loading state into account.
248         * html/HTMLMediaElement.h:
249
250         * page/EventHandler.cpp: (WebCore::EventHandler::updateMouseEventTargetNode): Make sure the events always go to the capturing node, if there is one.
251
252         * platform/mac/WebCoreSystemInterface.h: Added drawing methods for controls.
253         * platform/mac/WebCoreSystemInterface.mm: ditto.
254
255         * rendering/MediaControlElements.cpp: Added.
256         (WebCore::MediaControlShadowRootElement::MediaControlShadowRootElement): Moved from RenderMedia.  Made this relatively positioned, instead of absolute.
257         (WebCore::MediaControlInputElement::MediaControlInputElement): Moved from RenderMedia.  Removed call to updateFromElement, 
258          since its too early to do this here, and causes crashes for the slider.
259         (WebCore::MediaControlInputElement::attachToParent): Moved from RenderMedia.
260         (WebCore::MediaControlInputElement::update): ditto.
261         (WebCore::MediaControlMuteButtonElement::MediaControlMuteButtonElement): Added.
262         (WebCore::MediaControlMuteButtonElement::defaultEventHandler): ditto.
263         (WebCore::MediaControlPlayButtonElement::MediaControlPlayButtonElement): Moved from RenderMedia.
264         (WebCore::MediaControlPlayButtonElement::defaultEventHandler): ditto.
265         (WebCore::MediaControlSeekButtonElement::MediaControlSeekButtonElement): Added.
266         (WebCore::MediaControlSeekButtonElement::defaultEventHandler): ditto.
267         (WebCore::MediaControlSeekButtonElement::seekTimerFired): ditto.
268         (WebCore::MediaControlTimelineElement::MediaControlTimelineElement): Moved from RenderMedia.
269         (WebCore::MediaControlTimelineElement::defaultEventHandler): ditto.
270         (WebCore::MediaControlTimelineElement::update): ditto. 
271         (WebCore::MediaControlFullscreenButtonElement::MediaControlFullscreenButtonElement): Added.
272         (WebCore::MediaControlFullscreenButtonElement::defaultEventHandler): ditto.
273         * rendering/MediaControlElements.h: Added. Moved from RenderMedia.
274         (WebCore::MediaControlShadowRootElement::isShadowNode):
275         (WebCore::MediaControlShadowRootElement::shadowParentNode):
276         (WebCore::RenderMediaControlShadowRoot::RenderMediaControlShadowRoot):
277         (WebCore::RenderMediaControlShadowRoot::setParent):
278
279         * rendering/RenderMedia.cpp: Moved control element classes to MediaControlElements files.
280         (WebCore::RenderMedia::RenderMedia): No need to initialize RefPtrs.
281         (WebCore::RenderMedia::layout): Set the position for the controlsRenderer.
282         (WebCore::RenderMedia::createPanel): Added nil check for the renderer.
283         (WebCore::RenderMedia::createMuteButton): Added.
284         (WebCore::RenderMedia::createSeekBackButton): ditto.
285         (WebCore::RenderMedia::createSeekForwardButton): ditto.
286         (WebCore::RenderMedia::createTimeDisplay): Added nil check for the renderer.
287         (WebCore::RenderMedia::createFullscreenButton): Added.
288         (WebCore::RenderMedia::updateControls): Create, delete, and update new controls when appropriate.
289         (WebCore::RenderMedia::updateControlVisibility): Don't fade controls for audio controls. 
290         (WebCore::RenderMedia::forwardEvent): Forward events for new controls.
291         * rendering/RenderMedia.h: Added new methods for creating new controls.
292
293         * rendering/RenderObject.cpp: (WebCore::RenderObject::containingBlock): Updated special case for media elements, which are replaced elements, 
294           but also can contain children (the controls' container) that may need to look for the containing block.
295
296         * rendering/RenderSlider.cpp: (WebCore::RenderSlider::createThumbStyle): Added case for MediaSliderAppearance.
297
298         * rendering/RenderStyle.h: Added appearance constants and pseudo ids for new controls.
299         (WebCore::):
300         (WebCore::RenderStyle::):
301
302         * rendering/RenderTheme.cpp:
303         (WebCore::RenderTheme::adjustStyle): Added cases for new appearances.
304         (WebCore::RenderTheme::paint): ditto.
305         * rendering/RenderTheme.h: Added new methods for painting new appearances.
306         (WebCore::RenderTheme::paintMediaBackground):
307         (WebCore::RenderTheme::paintMediaFullscreenButton):
308         (WebCore::RenderTheme::paintMediaPlayButton):
309         (WebCore::RenderTheme::paintMediaMuteButton):
310         (WebCore::RenderTheme::paintMediaSeekBackButton):
311         (WebCore::RenderTheme::paintMediaSeekForwardButton):
312         (WebCore::RenderTheme::paintMediaSliderThumb):
313         * rendering/RenderThemeMac.h:
314         * rendering/RenderThemeMac.mm:
315         (WebCore::RenderThemeMac::RenderThemeMac): Initialize m_mediaControlBackgroundImage.
316         (WebCore::RenderThemeMac::~RenderThemeMac): Delete m_mediaControlBackgroundImage.
317         (WebCore::RenderThemeMac::paintCapsLockIndicator): Use LocalCurrentGraphicsContext here too, since we use it in all other painting methods.
318         (WebCore::RenderThemeMac::paintSliderTrack): Added case for MediaSliderAppearance.
319         (WebCore::RenderThemeMac::adjustSliderThumbSize): Added case for MediaSliderThumbAppearance.
320         (WebCore::RenderThemeMac::paintMediaBackground): Draws the new artwork for the controls.
321         (WebCore::RenderThemeMac::paintMediaFullscreenButton): ditto.
322         (WebCore::RenderThemeMac::paintMediaMuteButton): ditto.
323         (WebCore::RenderThemeMac::paintMediaPlayButton): ditto.
324         (WebCore::RenderThemeMac::paintMediaSeekBackButton): ditto.
325         (WebCore::RenderThemeMac::paintMediaSeekForwardButton): ditto.
326         (WebCore::RenderThemeMac::paintMediaSliderThumb): ditto.
327         * rendering/RenderThemeSafari.cpp: Draws the new artwork on Windows.
328         (WebCore::RenderThemeSafari::paintSliderTrack):
329         (WebCore::RenderThemeSafari::adjustSliderThumbSize):
330         (WebCore::RenderThemeSafari::paintMediaBackground):
331         (WebCore::RenderThemeSafari::paintMediaFullscreenButton):
332         (WebCore::RenderThemeSafari::paintMediaMuteButton):
333         (WebCore::RenderThemeSafari::paintMediaPlayButton):
334         (WebCore::RenderThemeSafari::paintMediaSeekBackButton):
335         (WebCore::RenderThemeSafari::paintMediaSeekForwardButton):
336         (WebCore::RenderThemeSafari::paintMediaSliderThumb):
337         * rendering/RenderThemeSafari.h:
338
339 2008-01-07  Timothy Hatcher  <timothy@apple.com>
340
341         Reviewed by Darin Adler.
342
343         Fix ASSERTION FAILED: dstOffset + srcSegmentLength == static_cast<int>(data.size())
344         when the replacment string is a different length.
345
346         * platform/text/StringImpl.cpp:
347         (WebCore::StringImpl::replace): Move the parenthesis to be around only the subtraction in
348         the Vector size calculation, correcting the order of math operations.
349
350 2008-01-07  Nikolas Zimmermann  <zimmermann@kde.org>
351
352         Reviewed by Eric. Hopefully fix build with mac tiger after the unicode-range addition. NSInteger not available there.
353
354         * platform/graphics/mac/FontCacheMac.mm:
355
356 2008-01-07  Nikolas Zimmermann  <zimmermann@kde.org>
357
358         Reviewed by Oliver. Fix build error introduced by Dan's unicode-range support patch & enabling SVG_FONTS by default.
359
360         * css/CSSFontSelector.cpp:
361         (WebCore::CSSFontSelector::getFontData):
362
363 2008-01-07  Nikolas Zimmermann  <zimmermann@kde.org>
364
365         Not reviewed. Next try to fix wx/mac leopard build.
366
367         * css/CSSFontSelector.cpp: Need to wrap a SVG* include in ENABLE(SVG) blocks, as this port doesn't build this generated file.
368         * svg/SVGFontFaceElement.cpp:
369         (WebCore::SVGFontFaceElement::createFontData): Fix double<->float conversion issue.
370         * webcore-base.bkl: Undo svg/ include.
371
372 2008-01-07  Dan Bernstein  <mitz@apple.com>
373
374         Reviewed by Dave Hyatt.
375
376         - <rdar://problem/5665216> Support the unicode-range property in @font-face rules
377
378         * GNUmakefile.am:
379         * WebCore.pro:
380         * WebCore.vcproj/WebCore.vcproj:
381         * WebCore.xcodeproj/project.pbxproj:
382         * WebCoreSources.bkl:
383         * bindings/objc/DOM.mm:
384         * bridge/mac/WebCoreAXObject.mm:
385         * css/CSSComputedStyleDeclaration.cpp:
386         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
387         * css/CSSFontFace.cpp:
388         (WebCore::CSSFontFace::fontLoaded): Changed to call the owning segmented
389         font face.
390         (WebCore::CSSFontFace::getFontData):
391         * css/CSSFontFace.h:
392         (WebCore::CSSFontFace::CSSFontFace):
393         (WebCore::CSSFontFace::setSegmentedFontFace):
394         * css/CSSFontFaceSource.cpp:
395         (WebCore::CSSFontFaceSource::pruneTable): Removed the calls to
396         GlyphPageTreeNode::pruneTreeCustomFontData because the fonts in the
397         font table are not exposed in the glyph page tree. Only the segmented
398         font is, and that is taken care of by the segmented font face.
399         (WebCore::CSSFontFaceSource::getFontData):
400         * css/CSSFontFaceSource.h:
401         * css/CSSFontSelector.cpp:
402         (WebCore::CSSFontSelector::addFontFaceRule): Changed to collect
403         @font-face rules with the same family and traits into a single
404         segmented font face, instead of just retaining the most recent one.
405         (WebCore::CSSFontSelector::fontLoaded):
406         (WebCore::CSSFontSelector::getFontData):
407         * css/CSSFontSelector.h:
408         * css/CSSGrammar.y:
409         * css/CSSParser.cpp:
410         (WebCore::CSSParser::parseValue):
411         (WebCore::CSSParser::parseFontFaceUnicodeRange): Added. Parses a unicode
412         range value.
413         * css/CSSParser.h:
414         * css/CSSPrimitiveValue.h:
415         (WebCore::CSSPrimitiveValue::):
416         * css/CSSPropertyNames.in:
417         * css/CSSSegmentedFontFace.cpp: Added.
418         (WebCore::CSSSegmentedFontFace::CSSSegmentedFontFace):
419         (WebCore::CSSSegmentedFontFace::~CSSSegmentedFontFace):
420         (WebCore::CSSSegmentedFontFace::pruneTable):
421         (WebCore::CSSSegmentedFontFace::isLoaded):
422         (WebCore::CSSSegmentedFontFace::isValid):
423         (WebCore::CSSSegmentedFontFace::fontLoaded):
424         (WebCore::CSSSegmentedFontFace::overlayRange):
425         (WebCore::CSSSegmentedFontFace::getFontData):
426         * css/CSSSegmentedFontFace.h: Added.
427         (WebCore::FontFaceRange::FontFaceRange):
428         (WebCore::FontFaceRange::from):
429         (WebCore::FontFaceRange::to):
430         (WebCore::FontFaceRange::fontFace):
431         (WebCore::CSSSegmentedFontFace::fontSelector):
432         * css/CSSStyleSelector.cpp:
433         (WebCore::CSSStyleSelector::applyProperty):
434         * css/CSSUnicodeRangeValue.cpp: Added.
435         (WebCore::CSSUnicodeRangeValue::~CSSUnicodeRangeValue):
436         (WebCore::CSSUnicodeRangeValue::cssText):
437         * css/CSSUnicodeRangeValue.h: Added.
438         (WebCore::CSSUnicodeRangeValue::CSSUnicodeRangeValue):
439         (WebCore::CSSUnicodeRangeValue::from):
440         (WebCore::CSSUnicodeRangeValue::to):
441         * css/SVGCSSFontFace.cpp:
442         (WebCore::SVGCSSFontFace::getFontData):
443         * css/SVGCSSFontFace.h:
444         * editing/Editor.cpp:
445         (WebCore::Editor::fontForSelection):
446         * editing/Editor.h:
447         * page/mac/FrameMac.mm:
448         * page/mac/WebCoreFrameBridge.mm:
449         (-[WebCoreFrameBridge fontForSelection:]):
450         * platform/graphics/Font.cpp:
451         (WebCore::WidthIterator::advance):
452         (WebCore::Font::glyphDataForCharacter):
453         (WebCore::Font::primaryFont): Changed to return the simple font data
454         used for the space character.
455         (WebCore::Font::fontDataAt):
456         (WebCore::Font::fontDataForCharacters):
457         (WebCore::Font::drawGlyphBuffer):
458         * platform/graphics/Font.h:
459         * platform/graphics/FontCache.cpp:
460         (WebCore::FontCache::getCachedFontData):
461         (WebCore::FontCache::getFontData):
462         * platform/graphics/FontCache.h:
463         * platform/graphics/FontData.cpp: Renamed to SimpleFontData.cpp
464         * platform/graphics/FontData.h: Renamed to SimpleFontData.cpp.
465         * platform/graphics/FontDataBaseClass.cpp: Added. This will be renamed
466         FontData.cpp.
467         (WebCore::FontData::~FontData):
468         * platform/graphics/FontDataBaseClass.h: Added. This will be renamed
469         FontData.h.
470         * platform/graphics/FontFallbackList.cpp:
471         (WebCore::FontFallbackList::determinePitch):
472         (WebCore::FontFallbackList::fontDataAt):
473         (WebCore::FontFallbackList::fontDataForCharacters):
474         * platform/graphics/FontFallbackList.h:
475         (WebCore::FontFallbackList::primaryFont):
476         * platform/graphics/FontSelector.h:
477         * platform/graphics/GlyphBuffer.h:
478         (WebCore::GlyphBuffer::fontDataAt):
479         (WebCore::GlyphBuffer::swap):
480         (WebCore::GlyphBuffer::add):
481         * platform/graphics/GlyphPageTreeNode.cpp:
482         (WebCore::GlyphPageTreeNode::pruneTreeCustomFontData):
483         (WebCore::GlyphPageTreeNode::initializePage): Added code to initialize
484         pages for segmented font data.
485         (WebCore::GlyphPageTreeNode::getChild):
486         (WebCore::GlyphPageTreeNode::pruneCustomFontData):
487         * platform/graphics/GlyphPageTreeNode.h:
488         (WebCore::GlyphPage::setGlyphDataForCharacter):
489         (WebCore::GlyphPage::setGlyphDataForIndex):
490         (WebCore::GlyphPageTreeNode::getRootChild):
491         * platform/graphics/SegmentedFontData.cpp: Added.
492         (WebCore::SegmentedFontData::~SegmentedFontData):
493         (WebCore::SegmentedFontData::fontDataForCharacter):
494         (WebCore::SegmentedFontData::containsCharacters):
495         (WebCore::SegmentedFontData::isCustomFont):
496         (WebCore::SegmentedFontData::isLoading):
497         (WebCore::SegmentedFontData::isSegmented):
498         * platform/graphics/SegmentedFontData.h: Added.
499         (WebCore::FontDataRange::FontDataRange):
500         (WebCore::FontDataRange::from):
501         (WebCore::FontDataRange::to):
502         (WebCore::FontDataRange::fontData):
503         (WebCore::SegmentedFontData::appendRange):
504         (WebCore::SegmentedFontData::numRanges):
505         (WebCore::SegmentedFontData::rangeAt):
506         * platform/graphics/SimpleFontData.cpp: Copied from WebCore/platform/graphics/FontData.cpp.
507         (WebCore::SimpleFontData::SimpleFontData):
508         (WebCore::SimpleFontData::~SimpleFontData):
509         (WebCore::SimpleFontData::ascent):
510         (WebCore::SimpleFontData::descent):
511         (WebCore::SimpleFontData::widthForGlyph):
512         (WebCore::SimpleFontData::fontDataForCharacter):
513         (WebCore::SimpleFontData::isSegmented):
514         * platform/graphics/SimpleFontData.h: Copied from WebCore/platform/graphics/FontData.h.
515         (WebCore::SimpleFontData::isCustomFont):
516         (WebCore::SimpleFontData::isLoading):
517         * platform/graphics/cairo/GraphicsContextCairo.cpp:
518         (WebCore::GraphicsContext::setPlatformFont):
519         * platform/graphics/gtk/FontCacheGtk.cpp:
520         (WebCore::FontCache::getFontDataForCharacters):
521         * platform/graphics/gtk/FontDataGtk.cpp: Renamed to
522         SimpleFontDataGtk.cpp.
523         * platform/graphics/gtk/FontGtk.cpp:
524         (WebCore::Font::drawGlyphs):
525         * platform/graphics/gtk/GlyphPageTreeNodeGtk.cpp:
526         (WebCore::GlyphPage::fill):
527         * platform/graphics/gtk/SimpleFontDataGtk.cpp: Copied from WebCore/platform/graphics/gtk/FontDataGtk.cpp.
528         (WebCore::SimpleFontData::platformInit):
529         (WebCore::SimpleFontData::platformDestroy):
530         (WebCore::SimpleFontData::smallCapsFontData):
531         (WebCore::SimpleFontData::containsCharacters):
532         (WebCore::SimpleFontData::determinePitch):
533         (WebCore::SimpleFontData::platformWidthForGlyph):
534         (WebCore::SimpleFontData::setFont):
535         * platform/graphics/mac/FontCacheMac.mm:
536         (WebCore::FontCache::getFontDataForCharacters):
537         * platform/graphics/mac/FontDataMac.mm: Renamed to SimpleFontDataMac.mm.
538         * platform/graphics/mac/FontMac.mm:
539         (WebCore::initializeATSUStyle):
540         (WebCore::overrideLayoutOperation):
541         (WebCore::ATSULayoutParameters::initialize):
542         (WebCore::Font::drawGlyphs):
543         * platform/graphics/mac/GlyphPageTreeNodeMac.cpp:
544         (WebCore::GlyphPage::fill):
545         * platform/graphics/mac/SimpleFontDataMac.mm: Copied from WebCore/platform/graphics/mac/FontDataMac.mm.
546         (WebCore::initFontData):
547         (WebCore::SimpleFontData::platformInit):
548         (WebCore::SimpleFontData::platformDestroy):
549         (WebCore::SimpleFontData::smallCapsFontData):
550         (WebCore::SimpleFontData::containsCharacters):
551         (WebCore::SimpleFontData::determinePitch):
552         (WebCore::SimpleFontData::platformWidthForGlyph):
553         (WebCore::SimpleFontData::checkShapesArabic):
554         * platform/graphics/qt/FontDataQt.cpp: Renamed to SimpleFontDataQt.cpp.
555         * platform/graphics/qt/GlyphPageTreeNodeQt.cpp:
556         (WebCore::GlyphPageTreeNode::pruneTreeCustomFontData):
557         * platform/graphics/qt/SimpleFontDataQt.cpp: Copied from WebCore/platform/graphics/qt/FontDataQt.cpp.
558         * platform/graphics/win/FontCacheWin.cpp:
559         (WebCore::FontCache::getFontDataForCharacters):
560         * platform/graphics/win/FontDataWin.cpp: Renamed to
561         SimpleFontDataWin.cpp.
562         * platform/graphics/win/FontWin.cpp:
563         (WebCore::Font::drawGlyphs):
564         * platform/graphics/win/GlyphPageTreeNodeWin.cpp:
565         (WebCore::GlyphPage::fill):
566         * platform/graphics/win/SimpleFontDataWin.cpp: Copied from WebCore/platform/graphics/win/FontDataWin.cpp.
567         (WebCore::SimpleFontData::setShouldApplyMacAscentHack):
568         (WebCore::SimpleFontData::platformInit):
569         (WebCore::SimpleFontData::platformDestroy):
570         (WebCore::SimpleFontData::smallCapsFontData):
571         (WebCore::SimpleFontData::containsCharacters):
572         (WebCore::SimpleFontData::determinePitch):
573         (WebCore::SimpleFontData::platformWidthForGlyph):
574         (WebCore::SimpleFontData::scriptFontProperties):
575         * platform/graphics/wx/FontCacheWx.cpp:
576         (WebCore::FontCache::getFontDataForCharacters):
577         * platform/graphics/wx/FontDataWx.cpp: Renamed to SimpleFontDataWx.cpp.
578         * platform/graphics/wx/FontWx.cpp:
579         (WebCore::Font::drawGlyphs):
580         * platform/graphics/wx/GlyphMapWx.cpp:
581         (WebCore::GlyphPage::fill):
582         * platform/graphics/wx/SimpleFontDataWx.cpp: Copied from WebCore/platform/graphics/wx/FontDataWx.cpp.
583         (WebCore::SimpleFontData::platformInit):
584         (WebCore::SimpleFontData::platformDestroy):
585         (WebCore::SimpleFontData::smallCapsFontData):
586         (WebCore::SimpleFontData::containsCharacters):
587         (WebCore::SimpleFontData::determinePitch):
588         (WebCore::SimpleFontData::platformWidthForGlyph):
589         * platform/mac/FileChooserMac.mm:
590         * platform/mac/PopupMenuMac.mm:
591         * platform/mac/WebCoreTextRenderer.mm:
592         * platform/win/PopupMenuWin.cpp:
593         * platform/win/UniscribeController.cpp:
594         (WebCore::UniscribeController::advance):
595         (WebCore::UniscribeController::itemizeShapeAndPlace):
596         (WebCore::UniscribeController::shapeAndPlaceItem):
597         (WebCore::UniscribeController::shape):
598         * platform/win/UniscribeController.h:
599         * svg/SVGFont.cpp:
600         (WebCore::Font::drawGlyphsWithSVGFont):
601         * svg/SVGFontElement.cpp:
602         (WebCore::SVGFontElement::collectGlyphs):
603         * svg/SVGFontFaceElement.cpp:
604         (WebCore::SVGFontFaceElement::createFontData):
605         * svg/SVGFontFaceElement.h:
606         * svg/SVGGlyphElement.cpp:
607
608 2008-01-07  Nikolas Zimmermann  <zimmermann@kde.org>
609
610         Not reviewed. Try to fix mac build by forcing SVGNames regeneration.
611
612         * svg/svgtags.in:
613
614 2008-01-07  Nikolas Zimmermann  <zimmermann@kde.org>
615
616         Not reviewed. Proposed build fix for wx.
617
618         * webcore-base.bkl:
619
620 2008-01-07  Dan Bernstein  <mitz@apple.com>
621
622         64-bit build fix
623
624         * platform/graphics/mac/FontCustomPlatformData.cpp:
625         (WebCore::FontCustomPlatformData::fontPlatformData): Have to use a
626         cast here since FMGetFontFromATSFontRef() is not available on 64-bit.
627
628 2008-01-06  Nikolas Zimmermann  <zimmermann@kde.org>
629
630         Reviewed by Oliver. Parts reviewed by Eric, David Hyatt & Dan & Alexey.
631         Fixes: http://bugs.webkit.org/show_bug.cgi?id=15741 (REGRESSION: svg/W3C-SVG-1.1/fonts-elem-03-b.svg shows worse behavior on TOT)
632
633         Display SVG Fonts, fill svg/SVGFont.cpp with life by adding all needed code to
634         measure & render glyphs contained in SVG Fonts, including ligature lookup support.
635
636         Implement floatWidth/selectionRectForText for SVG Fonts, fixing text selection.
637
638         Support horiz-origin-x/y, horiz-adv-x, vert-adv-y, vert-origin-x/y & arabic-form.
639         Implement simple algorithm to determine the arabic forms for a string (initial, isolated, medial, terminal).
640
641         Removed drawGlyphsWithSVGFont - create a new function drawTextWithSVGFont instead.
642         This doesn't involve creating/using a 'GlyphBuffer' object anymore, which is not
643         required for SVG Fonts anyway (we already know all our offsets/advances/etc..)
644
645         Don't call it from drawSimpleText anymore, but directly in drawText - as Dan suggested.
646
647         <glyph> elements now register themselves in the SVGFontElement's glyph cache.
648         (insertedIntoDocument / removedFromDocument take care of this)
649
650         The cache is built once now, and is kept updated - it's not rebuild anymore
651         on painting (!) - which was a crude hack for testing.
652
653         W3C testcase which include SVG Fonts:
654         svg/W3C-SVG-1.1/animate-elem-03-t.svg (Fixed, of course not the anim itself, but it's SVG Fonts usage)
655         svg/W3C-SVG-1.1/animate-elem-24-t.svg (Ditto)
656         svg/W3C-SVG-1.1/animate-elem-36-t.svg (Ditto)
657         svg/W3C-SVG-1.1/animate-elem-40-t.svg (Ditto)
658         svg/W3C-SVG-1.1/fonts-kern-01-t.svg (missing <vkern>/<hkern> support)
659         svg/W3C-SVG-1.1/fonts-desc-02-t.svg (Fixed, tests CSS font matching based on font-variant attribute)
660         svg/W3C-SVG-1.1/fonts-elem-01-t.svg (Fixed, basic SVG font test)
661         svg/W3C-SVG-1.1/fonts-elem-02-t.svg (Fixed, accuracy test for embedded SVG font)
662         svg/W3C-SVG-1.1/fonts-elem-05-t.svg (Fixed, checks horiz-origin-x support, note: W3C reference image is wrong)
663         svg/W3C-SVG-1.1/fonts-elem-06-t.svg (Fixed, checks horiz-adv-x support)
664         svg/W3C-SVG-1.1/fonts-glyph-02-t.svg (Fixed, checks arabic-form support)
665         svg/W3C-SVG-1.1/fonts-glyph-03-t.svg (Fixed, checks glyph matching based on xml:lang)
666         svg/W3C-SVG-1.1/masking-mask-01-b.svg (Fixed, SVG Fonts & masking)
667         svg/W3C-SVG-1.1/pservers-grad-08-b.svg (Fixed, SVG Fonts & gradient on fill/stroke)
668         svg/W3C-SVG-1.1/render-elems-06-t.svg (Fixed, simple 'fill' property test)
669         svg/W3C-SVG-1.1/render-elems-07-t.svg (Fixed, simple 'stroke' property test - shows SVG Font interprets stroke-width in glyph coordinate system, as demanded by spec)
670         svg/W3C-SVG-1.1/render-elems-08-t.svg (Fixed, simple 'fill' & 'stroke' property test)
671         svg/W3C-SVG-1.1/render-groups-01-b.svg (missing <vkern>/<hkern> support)
672         svg/W3C-SVG-1.1/render-groups-03-t.svg (Ditto)
673         svg/W3C-SVG-1.1/text-altglyph-01-b.svg (no <altGlyph> support yet)
674         svg/W3C-SVG-1.1/text-text-04-t.svg (Fixed, absolute placing of characters pixel perfect now)
675         svg/W3C-SVG-1.1/text-text-05-t.svg (FIXME: problem with text-anchor)
676         svg/W3C-SVG-1.1/text-text-06-t.svg (highlights problem with ligatures & absolute positioned characters)
677
678         Questionable testcases:
679         svg/W3C-SVG-1.1/fonts-glyph-04-t.svg (tests that glyph selection is done in the order in the definition of the font element.)
680         I am not sure why this behaviour is desired, no comment given in spec - doesn't make much sense to me, ignoring it for now.
681
682         Several other batik testcases fixed, which use SVG Fonts in combination with gradients & filters.
683
684         * css/CSSFontSelector.cpp:
685         (WebCore::CSSFontSelector::addFontFaceRule):
686         (WebCore::CSSFontSelector::getFontData):
687         * platform/graphics/Font.cpp:
688         (WebCore::Font::lineSpacing):
689         (WebCore::Font::xHeight):
690         (WebCore::Font::canUseGlyphCache):
691         (WebCore::Font::drawGlyphBuffer):
692         (WebCore::Font::drawText):
693         (WebCore::Font::floatWidth):
694         (WebCore::Font::selectionRectForText):
695         * platform/graphics/Font.h:
696         (WebCore::TextRun::TextRun):
697         (WebCore::TextRun::activePaintServer):
698         (WebCore::TextRun::setActivePaintServer):
699         * platform/graphics/FontData.cpp:
700         (WebCore::FontData::lineSpacing):
701         (WebCore::FontData::lineGap):
702         (WebCore::FontData::xHeight):
703         * platform/graphics/FontData.h:
704         * platform/graphics/win/FontWin.cpp:
705         (WebCore::Font::drawGlyphs):
706         * rendering/RenderSVGText.cpp:
707         (WebCore::RenderSVGText::relativeBBox):
708         * rendering/SVGInlineTextBox.cpp:
709         (WebCore::SVGInlineTextBox::paintCharacters):
710         * rendering/SVGInlineTextBox.h:
711         * rendering/SVGRootInlineBox.cpp:
712         (WebCore::SVGRootInlineBoxPaintWalker::chunkPortionCallback):
713         * svg/SVGFont.cpp:
714         (WebCore::):
715         (WebCore::processArabicFormDetection):
716         (WebCore::charactersWithArabicForm):
717         (WebCore::isCompatibleArabicForm):
718         (WebCore::isCompatibleGlyph):
719         (WebCore::svgFontAndFontFaceElementForFontData):
720         (WebCore::SVGTextRunWalker::SVGTextRunWalker):
721         (WebCore::SVGTextRunWalker::walk):
722         (WebCore::floatWidthUsingSVGFontCallback):
723         (WebCore::floatWidthMissingGlyphCallback):
724         (WebCore::floatWidthOfSubStringUsingSVGFont):
725         (WebCore::Font::floatWidthUsingSVGFont):
726         (WebCore::drawTextUsingSVGFontCallback):
727         (WebCore::drawTextMissingGlyphCallback):
728         (WebCore::Font::drawTextUsingSVGFont):
729         (WebCore::Font::selectionRectForTextUsingSVGFont):
730         * svg/SVGFontElement.cpp:
731         (WebCore::SVGFontElement::SVGFontElement):
732         (WebCore::SVGFontElement::addGlyphToCache):
733         (WebCore::SVGFontElement::removeGlyphFromCache):
734         (WebCore::SVGFontElement::firstMissingGlyphElement):
735         (WebCore::SVGFontElement::glyphIdentifiersForString):
736         * svg/SVGFontElement.h:
737         (WebCore::SVGFontElement::maximumHashKeyLength):
738         * svg/SVGFontFaceElement.cpp:
739         (WebCore::SVGFontFaceElement::createFontData):
740         (WebCore::SVGFontFaceElement::rebuildFontFace):
741         (WebCore::SVGFontFaceElement::associatedFontElement):
742         * svg/SVGFontFaceElement.h:
743         * svg/SVGGlyphElement.cpp:
744         (WebCore::SVGGlyphElement::insertedIntoDocument):
745         (WebCore::SVGGlyphElement::removedFromDocument):
746         (WebCore::parseArabicForm):
747         (WebCore::SVGGlyphElement::inheritUnspecifiedAttributes):
748         (WebCore::SVGGlyphElement::buildGlyphIdentifier):
749         * svg/SVGGlyphElement.h:
750         (WebCore::SVGGlyphIdentifier::):
751         (WebCore::SVGGlyphIdentifier::SVGGlyphIdentifier):
752         (WebCore::SVGGlyphIdentifier::inheritedValue):
753         (WebCore::SVGGlyphIdentifier::operator==):
754         (WebCore::SVGGlyphElement::~SVGGlyphElement):
755
756 2008-01-07  David Hyatt  <hyatt@apple.com>
757
758         Fix for bug 13095, CSS3 multiple backgrounds don't work on table cells.
759
760         Reviewed by Dan
761
762         * rendering/RenderBox.h:
763         * rendering/RenderTableCell.cpp:
764         (WebCore::RenderTableCell::paintBackgroundsBehindCell):
765
766 2008-01-07  Holger Freyther  <zecke@selfish.org>
767
768         Reviewed by Alp Toker.
769
770         * Fix indention
771
772         * platform/gtk/ContextMenuGtk.cpp:
773         (WebCore::ContextMenu::~ContextMenu):
774
775 2008-01-07  Holger Freyther  <zecke@selfish.org>
776
777         Reviewed by Alp Toker.
778
779         * The ContextMenuController is going to live longer than the ContextMenu. It is
780         going to live as long as the WebCore::Page is around where the ContextMenu, specially
781         in the case of a SubMenu, is gone before we popup the menu.
782
783         * platform/gtk/ContextMenuGtk.cpp:
784         (WebCore::menuItemActivated):
785         (WebCore::ContextMenu::appendItem):
786
787 2008-01-07  Holger Freyther  <zecke@selfish.org>
788
789         Reviewed by Alp Toker.
790
791         * Fix SubMenu handling
792         * Do not connect to the activated signal if we are a separator or submenu
793         * Change our type from ActionType to SubMenuType when we have a submenu
794         * Initialize the SubMenu
795
796         * platform/gtk/ContextMenuGtk.cpp:
797         (WebCore::ContextMenu::appendItem):
798         * platform/gtk/ContextMenuItemGtk.cpp:
799         (WebCore::ContextMenuItem::ContextMenuItem):
800         (WebCore::ContextMenuItem::createNativeMenuItem):
801         (WebCore::ContextMenuItem::setSubMenu):
802
803 2008-01-07  Holger Freyther  <zecke@selfish.org>
804
805         Reviewed by Alp Toker.
806
807         * Qt and Gtk must know if a ContextMenuItem is checkable. Add a new ContextMenuItemType for checkable
808         actions.
809         * Use this information in the Gtk platform to create a GtkCheckMenuItem when needed.
810         * Update the ContextMenuController to accept CheckableActionTypes as well.
811         * Change ContextMenu.cpp to use the CheckableActionType. The information if a item is checkable
812         was extracted from ContextMenu::checkOrEnableIfNeeded.
813         * Update the Qt and Windows port.
814
815
816         * page/ContextMenuController.cpp:
817         * platform/ContextMenu.cpp:
818         (WebCore::createAndAppendFontSubMenu):
819         (WebCore::createAndAppendSpellingAndGrammarSubMenu):
820         (WebCore::createAndAppendSpellingSubMenu):
821         (WebCore::createAndAppendWritingDirectionSubMenu):
822         * platform/ContextMenuItem.h:
823         * platform/gtk/ContextMenuItemGtk.cpp:
824         (WebCore::ContextMenuItem::ContextMenuItem):
825         (WebCore::ContextMenuItem::createNativeMenuItem):
826
827 2008-01-07  Luca Bruno  <lethalman88@gmail.com>
828
829         Reviewed by Alp Toker.
830
831         http://bugs.webkit.org/show_bug.cgi?id=16745
832         [GTK] Context menu doesn't feel or look native - no icons
833
834         Use GTK+ stock icons for menu items where possible.
835
836         * platform/gtk/ContextMenuItemGtk.cpp:
837         (WebCore::gtkStockIDFromContextMenuAction):
838         (WebCore::ContextMenuItem::createNativeMenuItem):
839         (WebCore::ContextMenuItem::setAction):
840
841 2008-01-07  Dan Bernstein  <mitz@apple.com>
842
843         Reviewed by John Sullivan.
844
845         - make the ATSUI code path work with custom fonts rather than crash
846
847         * platform/graphics/mac/FontCustomPlatformData.cpp:
848         (WebCore::FontCustomPlatformData::fontPlatformData):
849         * platform/graphics/mac/FontMac.mm:
850         (WebCore::initializeATSUStyle):
851
852 2008-01-07  Thiago Macieira  <thiago.macieira@trolltech.com>
853
854         Reviewed by Simon.
855
856         abort() now emits the signals, so disconnect them before you abort()
857
858         * platform/network/qt/QNetworkReplyHandler.cpp:
859         (WebCore::QNetworkReplyHandler::abort):
860
861 2008-01-07  Simon Hausmann  <hausmann@webkit.org>
862
863         Reviewed by Lars.
864
865         Use a faster and safer way of flattening the form data.
866
867         * platform/network/qt/QNetworkReplyHandler.cpp:
868         (WebCore::QNetworkReplyHandler::start):
869
870 2008-01-07  Simon Hausmann  <hausmann@webkit.org>
871
872         Reviewed by Lars.
873
874         Ported of the network backend of the Qt platform to Qt 4.4's new networking API.
875
876         * WebCore.pro:
877         * platform/network/ResourceHandleInternal.h:
878         * platform/network/qt/QNetworkReplyHandler.cpp: Added.
879         (WebCore::QNetworkReplyHandler::QNetworkReplyHandler):
880         (WebCore::QNetworkReplyHandler::abort):
881         (WebCore::QNetworkReplyHandler::finish):
882         (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
883         (WebCore::QNetworkReplyHandler::forwardData):
884         (WebCore::QNetworkReplyHandler::start):
885         * platform/network/qt/QNetworkReplyHandler.h: Added.
886         (WebCore::QNetworkReplyHandler::reply):
887         * platform/network/qt/ResourceHandleQt.cpp:
888         (WebCore::ResourceHandle::start):
889         (WebCore::ResourceHandle::cancel):
890         (WebCore::ResourceHandle::loadResourceSynchronously):
891         * platform/network/qt/ResourceRequest.h:
892         (WebCore::ResourceRequest::ResourceRequest):
893         * platform/network/qt/ResourceRequestQt.cpp: Added.
894         (WebCore::ResourceRequest::toNetworkRequest):
895         * platform/qt/MIMETypeRegistryQt.cpp:
896         (WebCore::MIMETypeRegistry::getMIMETypeForExtension):
897         * platform/qt/PlugInInfoStoreQt.cpp:
898         (WebCore::PlugInInfoStore::createPluginInfoForPluginAtIndex):
899         (WebCore::PlugInInfoStore::pluginCount):
900         (WebCore::PlugInInfoStore::pluginNameForMIMEType):
901
902 2008-01-07  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
903
904         Reviewed by Lars.
905
906         * Remove m_dirtyRegion as it is not used as we pass every dirty region
907         directly to the ChromeClient
908
909         * platform/qt/ScrollViewQt.cpp:
910         (WebCore::ScrollView::paint):
911
912 2008-01-06  Nikolas Zimmermann  <zimmermann@kde.org>
913
914         Reviewed by Oliver.
915
916         Small CG paint server cleanups - use more GraphicsContext method where possible.
917
918         * svg/graphics/cg/CgSupport.cpp:
919         (WebCore::applyStrokeStyleToContext):
920         (WebCore::strokeBoundingBox):
921         * svg/graphics/cg/CgSupport.h:
922         * svg/graphics/cg/RenderPathCg.cpp:
923         (WebCore::RenderPath::strokeContains):
924         * svg/graphics/cg/SVGPaintServerGradientCg.cpp:
925         (WebCore::SVGPaintServerGradient::setup):
926         * svg/graphics/cg/SVGPaintServerPatternCg.cpp:
927         (WebCore::SVGPaintServerPattern::setup):
928         * svg/graphics/cg/SVGPaintServerSolidCg.cpp:
929         (WebCore::SVGPaintServerSolid::setup):
930
931 2008-01-06  Nikolas Zimmermann  <zimmermann@kde.org>
932
933         Reviewed by Dan.
934
935         Use new helper function isArabicChar() - which also calls ublock_getCode() == UBLOCK_ARABIC on mac.
936
937         * platform/graphics/mac/FontMac.mm:
938         (WebCore::ATSULayoutParameters::initialize):
939
940 2008-01-06  Andrew Wellington  <proton@wiretapped.net>
941
942         Reviewed by Darin.
943         
944         DOMRange doesn't correctly re-size when inserting items (Acid3)
945         http://bugs.webkit.org/show_bug.cgi?id=16764
946         
947         Update the offset for the range when inserting items into the range.
948
949         Test: fast/dom/Range/range-modifycontents.html
950
951         * dom/Range.cpp:
952         (WebCore::Range::insertNode):
953
954 2008-01-06  Alexey Proskuryakov  <ap@webkit.org>
955
956         Reviewed by Darin.
957
958         http://bugs.webkit.org/show_bug.cgi?id=16731
959         Incorrect node type for whitespace when setting innerHTML in an XHTML document
960
961         Test: fast/dom/xhtml-fragment-whitespace.xhtml
962
963         * dom/XMLTokenizer.cpp: (WebCore::parseXMLDocumentFragment):
964         Use balancedCharactersHandler for ignorable whitespace.
965
966 2008-01-06  Alexey Proskuryakov  <ap@webkit.org>
967
968         Reviewed by Darin.
969
970         http://bugs.webkit.org/show_bug.cgi?id=16701
971         <rdar://problem/5666580> REGRESSION: URL-encoded space (%20) in livejournal url
972         causes page load error
973
974         Test: http/tests/misc/location-with-space.php
975
976         * platform/network/cf/ResourceRequestCFNet.cpp:
977         (WebCore::ResourceRequest::doUpdatePlatformRequest): Do update its URL, too.
978
979 2008-01-06  Andrew Wellington  <proton@wiretapped.net>
980
981         Reviewed by Darin.
982         
983         DOMRange.cloneContents does not work (Acid3 bug)
984         http://bugs.webkit.org/show_bug.cgi?id=16748
985         
986         When cloning an empty range, return an empty DocmentFragment instead of
987         null or undefined.
988
989         Test: fast/dom/Range/range-clone-empty.html
990
991         * dom/Range.cpp:
992         (WebCore::Range::processContents):
993
994 2008-01-06  Luca Bruno  <lethalman88@gmail.com>
995
996         Reviewed by Alp Toker.
997
998         Remove curl handles immediately if the timer is not running.
999
1000         * platform/network/curl/ResourceHandleManager.cpp:
1001         (WebCore::ResourceHandleManager::cancel):
1002
1003 2008-01-06  Alp Toker  <alp@atoker.com>
1004
1005         Reviewed by Eric.
1006
1007         Cairo canvas refcounting fix. Reference the surface in the constructor
1008         to match its destruction in the destructor.
1009
1010         Fixes a crash triggered by leaving this page:
1011           http://philip.html5.org/tests/canvas/misc/globalalpha-pattern.html
1012
1013         * html/CanvasPattern.cpp:
1014         (WebCore::CanvasPattern::CanvasPattern):
1015
1016 2008-01-06  Eric Seidel  <eric@webkit.org>
1017
1018         Reviewed by darin.
1019
1020         Make attr selectors case-insensitive for certain HTML attributes
1021         http://bugs.webkit.org/show_bug.cgi?id=15470
1022
1023         Test: fast/css/html-attr-case-sensitivity.html
1024
1025         * css/CSSStyleSelector.cpp:
1026         (WebCore::addLocalNameToSet):
1027         (WebCore::createHtmlCaseInsensitiveAttributesSet):
1028         (WebCore::htmlAttributeHasCaseInsensitiveValue):
1029         (WebCore::CSSStyleSelector::checkOneSelector):
1030
1031 2008-01-06  Eric Seidel  <eric@webkit.org>
1032
1033         Reviewed by Sam.
1034
1035         Fix :checked matching type='text' and add test case
1036         http://bugs.webkit.org/show_bug.cgi?id=16750
1037
1038         Test: fast/dom/HTMLInputElement/checked-pseudo-selector.html
1039
1040         * html/HTMLInputElement.h: isChecked() can only be true for RADIO or CHECKBOX
1041
1042 2008-01-05  Sam Weinig  <sam@webkit.org>
1043
1044         Reviewed by Eric Seidel.
1045
1046         Patch for http://bugs.webkit.org/show_bug.cgi?id=16758
1047         ASSERT when using TreeWalker methods for a current node outside of the root (Acid3)
1048
1049         - Ensure that returned nodes are within the root node, or return 0, in adherence with the spec.
1050
1051         Test: fast/dom/TreeWalker/TreeWalker-currentNode.html
1052
1053         * dom/TreeWalker.cpp:
1054         (WebCore::TreeWalker::parentNode):
1055         (WebCore::TreeWalker::firstChild):
1056         (WebCore::TreeWalker::lastChild):
1057         (WebCore::TreeWalker::previousSibling):
1058         (WebCore::TreeWalker::nextSibling):
1059         (WebCore::TreeWalker::previousNode):
1060         (WebCore::TreeWalker::nextNode):
1061
1062 2008-01-04  Oliver Hunt  <oliver@apple.com>
1063
1064         Reviewed by Beth Dakin.
1065
1066         Fix bounds computation bugs responsible for http://bugs.webkit.org/show_bug.cgi?id=16015
1067         and other image repaint bugs.
1068
1069         We now cache the full local bounds for the <image> element, as otherwise certain
1070         combinations of attribute changes could result in incorrect dirty rects.
1071         Additionally we no longer use any of the integer bounds fields on RenderObject for
1072         determining repaint bounds (this was the principle cause of bug #16015).
1073
1074         I also removed the outline painting code as it was both wrong, and not correctly
1075         repainted.  I feel safe doing this as no other browser or viewer supports outline
1076         properties on svg elements.
1077
1078         I was unable to make a testcase for this unfortunately, despite seemingly deterministic 
1079         behaviour :(
1080
1081         * rendering/RenderSVGImage.cpp:
1082         (WebCore::RenderSVGImage::layout):
1083         (WebCore::RenderSVGImage::paint):
1084         (WebCore::RenderSVGImage::nodeAtPoint):
1085         (WebCore::RenderSVGImage::calculateAbsoluteBounds):
1086         * rendering/RenderSVGImage.h:
1087
1088 2008-01-04  Beth Dakin  <bdakin@apple.com>
1089
1090         Reviewed by Oliver.
1091
1092         Fix for http://bugs.webkit.org/show_bug.cgi?id=16704 input with 
1093         type="hidden" matches :enabled/:disabled (Acid3 bug)
1094
1095         Prevent :enabled and :disabled from applying to input type="hidden" 
1096
1097         * css/CSSStyleSelector.cpp:
1098         (WebCore::CSSStyleSelector::checkOneSelector): Rather than 
1099         allowing :enabled and :disabled to apply to all controls, only 
1100         allow it to apply to non-"hidden" controls
1101         * dom/Element.h:
1102         (WebCore::Element::isInputTypeHidden): 
1103         * html/HTMLInputElement.h:
1104         (WebCore::HTMLInputElement::isInputTypeHidden):
1105
1106 2008-01-04  Sam Weinig  <sam@webkit.org>
1107
1108         Reviewed by Oliver Hunt.
1109
1110         - Match the spec when calling getFloatValue, getStringValue, getCounterValue,
1111           getRectValue and getRGBColorValue of CSSPrimitiveValue by throwing exceptions
1112           if the type of the CSSPrimitiveValue is not the same as the type requested.
1113         - Fix the intermittent assertion failure seen in svg/css/glyph-orientation-rounding-test.xhtml
1114
1115         Test: fast/css/CSSPrimitiveValue-exceptions.html
1116
1117         * css/CSSPrimitiveValue.cpp:
1118         (WebCore::CSSPrimitiveValue::getDoubleValue):
1119         (WebCore::CSSPrimitiveValue::getStringValue):
1120         (WebCore::CSSPrimitiveValue::getCounterValue):
1121         (WebCore::CSSPrimitiveValue::getRectValue):
1122         (WebCore::CSSPrimitiveValue::getRGBColorValue):
1123         (WebCore::CSSPrimitiveValue::getPairValue):
1124         * css/CSSPrimitiveValue.h:
1125         (WebCore::CSSPrimitiveValue::getFloatValue):
1126         (WebCore::CSSPrimitiveValue::getIntValue):
1127         (WebCore::CSSPrimitiveValue::getCounterValue):
1128         (WebCore::CSSPrimitiveValue::getRectValue):
1129         (WebCore::CSSPrimitiveValue::getDashboardRegionValue):
1130         * css/CSSPrimitiveValue.idl:
1131
1132 2008-01-04  Antti Koivisto  <antti@apple.com>
1133
1134         Reviewed by Darin.
1135         
1136         Windows part of <rdar://problem/5647034>
1137         Media tests crash if an old version of QuickTime is installed
1138
1139         Check QuickTime version on Windows too.
1140
1141         * platform/graphics/MediaPlayer.cpp:
1142         (WebCore::MediaPlayer::isAvailable):
1143         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.h:
1144         (WebCore::MediaPlayerPrivate::isAvailable):
1145         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.cpp:
1146         (WebCore::MediaPlayerPrivate::isAvailable):
1147         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.h:
1148         * platform/graphics/win/QTMovieWin.cpp:
1149         (QTMovieWin::initializeQuickTime):
1150
1151 2008-01-04  Darin Adler  <darin@apple.com>
1152
1153         Reviewed by Maciej and Alice.
1154
1155         - fix <rdar://problem/4404302> Borders where there should be none (canadasmountains.com)
1156
1157         Test: fast/images/border.html
1158
1159         * html/HTMLImageElement.cpp:
1160         (WebCore::HTMLImageElement::parseMappedAttribute): Change the code that handles cases
1161         where the border value is not a number to use the value "0" for the border width instead
1162         of not setting the border width and style at all. This matches other browsers, and makes
1163         more sense.
1164
1165 2008-01-04  Antti Koivisto  <antti@apple.com>
1166
1167         Try to fix 64-bit build
1168
1169         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
1170         (WebCore::MediaPlayerPrivate::isAvailable):
1171
1172 2008-01-04  Stephanie  <slewis@apple.com>
1173
1174         Reviewed by Oliver.
1175
1176         WARNING: NO TEST CASES ADDED OR CHANGED
1177
1178         Fix another stringImpl leak.
1179
1180         * platform/text/StringImpl.cpp: remove an extra allocation
1181         (WebCore::StringImpl::StringImpl):
1182
1183 2008-01-04  Alice Liu  <alice.liu@apple.com>
1184
1185         Reviewed by Mitz.
1186
1187         * platform/graphics/win/FontCacheWin.cpp:
1188         fix loop condition that was causing crash
1189
1190 2008-01-04  Timothy Hatcher  <timothy@apple.com>
1191
1192         Reviewed by Adam Roben.
1193
1194         <rdar://problem/5671059> Always show the Timeline and Console buttons in the Inspector
1195
1196         * page/inspector/inspector.css: Remove styles related to the toggle button
1197           and make the area always visible. 
1198         * page/inspector/inspector.html: Remove the toggle button.
1199         * page/inspector/inspector.js: Remove code to toggle the status area.
1200
1201 2008-01-04  Alexey Proskuryakov  <ap@webkit.org>
1202
1203         Reviewed by Adam Roben.
1204
1205         Temporarily restore BackwardDelete for Windows nightlies to work correctly.
1206
1207         * editing/EditorCommand.cpp: (WebCore::CommandEntry::):
1208
1209 2008-01-04  Alexey Proskuryakov  <ap@webkit.org>
1210
1211         Reviewed by Darin.
1212
1213         <rdar://problem/5611712> xsl:sort does not use a case folding sort, and the 'case-order' attribute is ignored (16077)
1214
1215         Enable the fix on Windows.
1216
1217         * xml/XSLTProcessor.cpp: (WebCore::XSLTProcessor::transformToString):
1218         Always set a custom sort function, even if it doesn't implement proper collation on the platform.
1219
1220         * xml/XSLTUnicodeSort.cpp:
1221         (WebCore::xsltUnicodeSortFunction):
1222         * xml/XSLTUnicodeSort.h:
1223         If the platform does not use ICU, or ICU has collation support disabled, fall back to binary comparison.
1224
1225 2008-01-04  Antti Koivisto  <antti@apple.com>
1226
1227         Fix build.
1228
1229         * bindings/js/JSHTMLElementWrapperFactory.cpp:
1230
1231 2008-01-04  Antti Koivisto  <antti@apple.com>
1232
1233         Reviewed by Darin.
1234         
1235         Partial fix for <rdar://problem/5647034>
1236         Media tests crash if an old version of QuickTime is installed
1237
1238         Disable media support if QuickTime is not current enough (>=7.3).
1239         
1240         Windows patch coming soon.
1241
1242         * bindings/js/JSHTMLElementWrapperFactory.cpp:
1243         (WebCore::createJSHTMLWrapper):
1244         * bindings/js/kjs_window.cpp:
1245         (KJS::Window::getValueProperty):
1246         * html/HTMLElementFactory.cpp:
1247         (WebCore::audioConstructor):
1248         (WebCore::videoConstructor):
1249         (WebCore::sourceConstructor):
1250         * platform/graphics/MediaPlayer.cpp:
1251         (WebCore::MediaPlayer::isAvailable):
1252         * platform/graphics/MediaPlayer.h:
1253         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
1254         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
1255         (WebCore::MediaPlayerPrivate::isAvailable):
1256
1257 2008-01-04  Timothy Hatcher  <timothy@apple.com>
1258
1259         Reviewed by Darin Adler.
1260
1261         <rdar://problem/5604409> JavaScript privilege escalation when Web Inspector accesses page unsafely (16011)
1262
1263         Check if the property is a getter before asking for the value.
1264         If the property is a getter, we no longer show the value.
1265
1266         * page/inspector/PropertiesSidebarPane.js:
1267         * page/inspector/inspector.css:
1268
1269 2008-01-04  Dan Bernstein  <mitz@apple.com>
1270
1271         Reviewed by Darin Adler.
1272
1273         - fix synthetic bold and italic on Windows
1274
1275         Covered by an existing test.
1276
1277         * platform/graphics/win/FontPlatformDataWin.cpp:
1278         (WebCore::FontPlatformData::FontPlatformData):
1279
1280 2008-01-04  Alp Toker  <alp@atoker.com>
1281
1282         GTK+ autotools build fix. Terminate empty rules.
1283
1284         * GNUmakefile.am:
1285
1286 2008-01-04  Lars Knoll  <lars@trolltech.com>
1287
1288         Reviewed by Simon.
1289
1290         Remove most dependencies of Widget/ScrollView onto native QWidgets.
1291
1292         This also brings the code closer in line with the Windows code. Seems
1293         to work nicely on first try :)
1294
1295         * page/qt/FrameQt.cpp:
1296         (WebCore::Frame::createScriptInstanceForWidget):
1297         * platform/Widget.h:
1298         * platform/qt/PlatformScreenQt.cpp:
1299         (WebCore::screenDepth):
1300         (WebCore::screenDepthPerComponent):
1301         (WebCore::screenIsMonochrome):
1302         (WebCore::screenRect):
1303         * platform/qt/PlatformScrollBarQt.cpp:
1304         (WebCore::PlatformScrollbar::thumbPosition):
1305         (WebCore::PlatformScrollbar::handleMouseMoveEvent):
1306         * platform/qt/ScrollViewQt.cpp:
1307         (WebCore::ScrollView::ScrollViewPrivate::ScrollViewPrivate):
1308         (WebCore::ScrollView::ScrollViewPrivate::scrollBackingStore):
1309         (WebCore::ScrollView::updateContents):
1310         (WebCore::ScrollView::update):
1311         (WebCore::ScrollView::scrollRectIntoViewRecursively):
1312         (WebCore::ScrollView::updateScrollbars):
1313         (WebCore::ScrollView::addChild):
1314         (WebCore::ScrollView::removeChild):
1315         (WebCore::ScrollView::paint):
1316         * platform/qt/WidgetQt.cpp:
1317         (WebCore::WidgetPrivate::WidgetPrivate):
1318         (WebCore::WidgetPrivate::~WidgetPrivate):
1319         (WebCore::Widget::frameGeometry):
1320         (WebCore::Widget::setFrameGeometry):
1321         (WebCore::Widget::setCursor):
1322         (WebCore::Widget::show):
1323         (WebCore::Widget::hide):
1324         (WebCore::Widget::nativeWidget):
1325         (WebCore::Widget::setNativeWidget):
1326         (WebCore::Widget::suppressInvalidation):
1327         (WebCore::Widget::setSuppressInvalidation):
1328         (WebCore::Widget::invalidateRect):
1329         (WebCore::Widget::topLevel):
1330         (WebCore::Widget::containingWindow):
1331
1332 2008-01-04  Lars Knoll  <lars@trolltech.com>
1333
1334         Reviewed by Simon.
1335
1336         make QWebPage a QObject and get things to compile.
1337
1338         Nothing works currently though.
1339
1340         * platform/qt/ScrollViewQt.cpp:
1341         (WebCore::ScrollView::updateContents):
1342         (WebCore::ScrollView::update):
1343         * platform/qt/WidgetQt.cpp:
1344         (WebCore::Widget::qwidget):
1345         (WebCore::Widget::invalidateRect):
1346
1347 2008-01-04  Alp Toker  <alp@atoker.com>
1348
1349         Reviewed by Mark Rowe.
1350
1351         http://bugs.webkit.org/show_bug.cgi?id=16667
1352         make -j is failing with the autotools based system
1353
1354         Support parallel code generation. Nearly every use of explicit
1355         multiple targets was a potential concurrency bug, though in practice
1356         the bison rules were the first to be noticed because they took longer
1357         to complete and broke the build immediately.
1358
1359         * GNUmakefile.am:
1360
1361 2008-01-04  Alp Toker  <alp@atoker.com>
1362
1363         Reviewed by Mark Rowe.
1364
1365         Re-use a single static dummy surface rather than creating and
1366         destroying a surface for each CairoPath.
1367
1368         * platform/graphics/cairo/CairoPath.h:
1369         (WebCore::CairoPath::CairoPath):
1370
1371 2008-01-04  Mark Rowe  <mrowe@apple.com>
1372
1373         Tiger build fix.
1374
1375         * platform/Threading.h: The OSAtomic functions take non-volatile pointers on Tiger.
1376
1377 2008-01-03  Mark Rowe  <mrowe@apple.com>
1378
1379         Reviewed by Maciej Stachowiak.
1380
1381         Use platform-provided atomic operations in place of inline assembly to
1382         increase portability.
1383
1384         * platform/Threading.h:
1385         (WebCore::atomicIncrement):
1386         (WebCore::atomicDecrement):
1387
1388 2008-01-03  Oliver Hunt  <oliver@apple.com>
1389
1390         Reviewed by Maciej.
1391
1392         Fix <rdar://problem/5668517> REGRESSION: Major under painting issues in SVG (carto.net dock example)
1393
1394         We need to cache the absolute bounds of the <image>,
1395         as there's no reliable way to recompute the old bounding
1396         box one we have started layout.
1397
1398         * rendering/RenderSVGImage.cpp:
1399         (WebCore::RenderSVGImage::layout):
1400         (WebCore::RenderSVGImage::calculateAbsoluteBounds):
1401         * rendering/RenderSVGImage.h:
1402
1403 2008-01-03  Alp Toker  <alp@atoker.com>
1404
1405         Reviewed by Mark Rowe.
1406
1407         Support building in Scratchbox, which has a version of make that fails
1408         on wildcard syntax. Use a vpath to match IDL files instead.
1409
1410         * GNUmakefile.am:
1411
1412 2008-01-03  Jon Honeycutt  <jhoneycutt@apple.com>
1413
1414         Reviewed by Darin.
1415
1416         <rdar://problem/5504775> PDF page will not load first time after Adobe
1417         Reader install, unless browser is relaunched
1418
1419         Refresh and re-search the plugin database if the MIME type is not
1420         registered.
1421
1422         * plugins/win/PluginDatabaseWin.cpp:
1423         (WebCore::PluginDatabaseWin::isMIMETypeRegistered):
1424         * plugins/win/PluginDatabaseWin.h:
1425
1426 2008-01-03  Dan Bernstein  <mitz@apple.com>
1427
1428         Reviewed by Darin Adler.
1429
1430         - fix http://bugs.webkit.org/show_bug.cgi?id=16548
1431           <rdar://problem/5659452> REGRESSION(r28810): Font style and sizes are weird for Japanese text
1432
1433         * platform/graphics/win/FontCacheWin.cpp:
1434         (WebCore::linkedFontEnumProc): Added. This callback is used to fetch
1435         a valid LOGFONT for a given family.
1436         (WebCore::getLinkedFonts): Added. Returns a vector of font families
1437         linked to the given font family by the Windows registry key
1438         HKLM\Software\...\FontLink\SystemLink. The registry values typically
1439         differ based on the installed language version of Windows.
1440         (WebCore::FontCache::getFontDataForCharacters): Changed to not use MLang
1441         font mapping, which is Windows code page based, except for characters in
1442         the range U+2000..U+200F. Instead, this function gets the font Uniscribe
1443         would use for the character. However, that font might not actually
1444         contain the character, in which case GDI font linking would substitute a
1445         different font. Therefore, this function walks the linked font list
1446         until it finds a font that actually contains the character.
1447
1448 2008-01-03  Darin Adler  <darin@apple.com>
1449
1450         Reviewed by Mitz.
1451
1452         - fix http://bugs.webkit.org/show_bug.cgi?id=16723
1453           tables/mozilla/bugs/bug30418.html test failing due to problems updating dynamic border rules
1454
1455         Test: fast/table/border-changes.html
1456
1457         * html/HTMLTableElement.h:
1458         * html/HTMLTableElement.cpp:
1459         (WebCore::HTMLTableElement::parseMappedAttribute): Check the border type before and after
1460         parsing attributes, rather than doing this only for the rules attribute.
1461         (WebCore::HTMLTableElement::cellBorders): Added.
1462         (WebCore::HTMLTableElement::getSharedCellDecl): Changed to use cellBorders to factor out the
1463         rule about what type of borders to use.
1464
1465 2008-01-02  Sam Weinig  <sam@webkit.org>
1466
1467         Reviewed by Darin.
1468
1469         Pass the prototype of WebCore JS objects up the constructor chain
1470         rather than explicitly setting using setPrototype.  This removes many
1471         redundant settings of the prototype on construction.  To avoid a CG 
1472         hazard, the prototype must be constructed before calling the
1473         constructor of the JS object.
1474
1475         - JS objects that inherit from DOMObject, which all bindings objects
1476           (except Window) do, now can't implicitly have a jsNull prototype, but
1477           must explicitly pass it up the construction chain.
1478
1479         * bindings/js/JSCSSRuleCustom.cpp:
1480         (WebCore::toJS):
1481         * bindings/js/JSCSSValueCustom.cpp:
1482         (WebCore::toJS):
1483         * bindings/js/JSDocumentCustom.cpp:
1484         (WebCore::toJS):
1485         * bindings/js/JSEventCustom.cpp:
1486         (WebCore::toJS):
1487         * bindings/js/JSEventTargetNode.cpp:
1488         (WebCore::JSEventTargetNode::JSEventTargetNode):
1489         * bindings/js/JSEventTargetNode.h:
1490         * bindings/js/JSHTMLAllCollection.h:
1491         (WebCore::JSHTMLAllCollection::JSHTMLAllCollection):
1492         * bindings/js/JSHTMLAudioElementConstructor.cpp:
1493         (WebCore::JSHTMLAudioElementConstructor::JSHTMLAudioElementConstructor):
1494         * bindings/js/JSHTMLCollectionCustom.cpp:
1495         (WebCore::getNamedItems):
1496         (WebCore::toJS):
1497         * bindings/js/JSHTMLElementWrapperFactory.cpp:
1498         (WebCore::createJSHTMLWrapper):
1499         * bindings/js/JSHTMLFormElementCustom.cpp:
1500         (WebCore::JSHTMLFormElement::nameGetter):
1501         * bindings/js/JSHTMLInputElementBase.cpp:
1502         (WebCore::JSHTMLInputElementBase::JSHTMLInputElementBase):
1503         * bindings/js/JSHTMLInputElementBase.h:
1504         * bindings/js/JSHTMLOptionElementConstructor.cpp:
1505         (WebCore::JSHTMLOptionElementConstructor::JSHTMLOptionElementConstructor):
1506         * bindings/js/JSLocation.cpp:
1507         (WebCore::JSLocation::JSLocation):
1508         * bindings/js/JSLocation.h:
1509         * bindings/js/JSNamedNodesCollection.cpp:
1510         (WebCore::JSNamedNodesCollection::JSNamedNodesCollection):
1511         * bindings/js/JSNamedNodesCollection.h:
1512         * bindings/js/JSNodeCustom.cpp:
1513         (WebCore::toJS):
1514         * bindings/js/JSSVGElementWrapperFactory.cpp:
1515         (WebCore::createJSSVGWrapper):
1516         * bindings/js/JSSVGPathSegCustom.cpp:
1517         (WebCore::toJS):
1518         * bindings/js/JSStyleSheetCustom.cpp:
1519         (WebCore::toJS):
1520         * bindings/js/JSXMLHttpRequest.cpp:
1521         (KJS::JSXMLHttpRequestConstructorImp::JSXMLHttpRequestConstructorImp):
1522         (KJS::JSXMLHttpRequestConstructorImp::construct):
1523         (KJS::JSXMLHttpRequest::JSXMLHttpRequest):
1524         * bindings/js/JSXMLHttpRequest.h:
1525         * bindings/js/JSXSLTProcessor.cpp:
1526         (KJS::JSXSLTProcessor::JSXSLTProcessor):
1527         (KJS::XSLTProcessorConstructorImp::XSLTProcessorConstructorImp):
1528         (KJS::XSLTProcessorConstructorImp::implementsConstruct):
1529         (KJS::XSLTProcessorConstructorImp::construct):
1530         * bindings/js/JSXSLTProcessor.h:
1531         * bindings/js/kjs_binding.h:
1532         (KJS::DOMObject::DOMObject):
1533         (KJS::cacheDOMObject):
1534         (KJS::cacheSVGDOMObject):
1535         * bindings/js/kjs_css.cpp:
1536         (WebCore::JSRGBColor::JSRGBColor):
1537         (WebCore::getJSRGBColor):
1538         * bindings/js/kjs_css.h:
1539         * bindings/js/kjs_events.cpp:
1540         (WebCore::JSClipboard::JSClipboard):
1541         (WebCore::toJS):
1542         * bindings/js/kjs_events.h:
1543         * bindings/js/kjs_html.cpp:
1544         (WebCore::ImageConstructorImp::ImageConstructorImp):
1545         * bindings/js/kjs_navigator.cpp:
1546         (KJS::Navigator::Navigator):
1547         (KJS::PluginBase::PluginBase):
1548         * bindings/js/kjs_navigator.h:
1549         * bindings/js/kjs_window.cpp:
1550         (KJS::Window::Window):
1551         (KJS::Window::location):
1552         (KJS::Window::getValueProperty):
1553         * bindings/js/kjs_window.h:
1554         * bindings/scripts/CodeGeneratorJS.pm:
1555
1556 2008-01-03  Holger Hans Peter Freyther  <zecke@selfish.org>
1557
1558         Reviewed by Alp.
1559
1560         -This is from http://bugs.webkit.org/show_bug.cgi?id=16115
1561
1562         Change the Gtk ContextMenuItem code to generate the GtkMenuItem
1563         or GtkCheckMenuItem on the fly. Currently we will create a
1564         GtkCheckMenuItem if the ContextMenuItem has been checked. What needs
1565         to be done is to change WebCore to tell the platform code if an item
1566         is checkable or not.
1567
1568         * platform/ContextMenuItem.h:
1569         (WebCore::PlatformMenuItemDescription::PlatformMenuItemDescription):
1570         * platform/gtk/ContextMenuGtk.cpp:
1571         (WebCore::ContextMenu::appendItem):
1572         * platform/gtk/ContextMenuItemGtk.cpp:
1573         (WebCore::ContextMenuItem::ContextMenuItem):
1574         (WebCore::ContextMenuItem::~ContextMenuItem):
1575         (WebCore::ContextMenuItem::createNativeMenuItem):
1576         (WebCore::ContextMenuItem::releasePlatformDescription):
1577         (WebCore::ContextMenuItem::type):
1578         (WebCore::ContextMenuItem::setType):
1579         (WebCore::ContextMenuItem::action):
1580         (WebCore::ContextMenuItem::setAction):
1581         (WebCore::ContextMenuItem::platformSubMenu):
1582         (WebCore::ContextMenuItem::setSubMenu):
1583         (WebCore::ContextMenuItem::setChecked):
1584
1585 2008-01-03  Dan Bernstein  <mitz@apple.com>
1586
1587         Rubber-stamped by Adam Roben.
1588
1589         - update the project hierarchy to match the on-disk organization of
1590           the platform directory.
1591
1592         * WebCore.vcproj/WebCore.vcproj:
1593
1594 2008-01-03  Adam Roben  <aroben@apple.com>
1595
1596         Fix a buffer overrun and a leak introduced in r29098
1597
1598         Reviewed by Mark.
1599
1600         * platform/text/StringImpl.cpp:
1601         (WebCore::StringImpl::StringImpl): Only allocate one buffer, and make
1602         it be big enough to hold the string contents plus the null terminator.
1603
1604 2008-01-03  Simon Hausmann  <hausmann@webkit.org>
1605
1606         Reviewed by Lars.
1607
1608         Added the first revision of QWebView and started moving functionality from QWebPave over to QWebView and QWebFrame.
1609
1610         * WebCore.pro:
1611
1612 2008-01-03  Alp Toker  <alp@atoker.com>
1613
1614         Suggested by Mark Rowe.
1615
1616         Fix indentation and remove trailing whitespace.
1617
1618         * platform/network/curl/ResourceHandleManager.cpp:
1619
1620 2008-01-03  Luca Bruno  <lethalman88@gmail.com>
1621
1622         Reviewed by Alp Toker.
1623
1624         Fix HTTP POST-based logins to sites like Facebook, GMail by ensuring
1625         that the two POST methods don't conflict.
1626
1627         * platform/network/curl/ResourceHandleManager.cpp:
1628         (WebCore::ResourceHandleManager::setupPOST):
1629
1630 2008-01-02  Darin Adler  <darin@apple.com>
1631
1632         - touched some files to try to get the Windows buildbot building again
1633
1634 2008-01-02  Dan Bernstein  <mitz@apple.com>
1635
1636         Reviewed by Sam Weinig.
1637
1638         - fix small caps rendering
1639
1640         Covered by an existing test.
1641
1642         * platform/graphics/win/FontDataWin.cpp:
1643         (WebCore::FontData::smallCapsFontData):
1644
1645 2008-01-02  Antti Koivisto  <antti@apple.com>
1646
1647         Reviewed by Oliver.
1648
1649         Calculate video position and size within the renderer box in WebCore. This
1650         way the aspect ratio calculation is not needed in each MediaPlayer implementation.
1651         
1652         This fixes video aspect ratio on Windows.
1653         
1654         Covered by an existing pixel test.
1655
1656         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
1657         (WebCore::MediaPlayerPrivate::createQTMovieView):
1658         * rendering/RenderVideo.cpp:
1659         (WebCore::RenderVideo::videoBox):
1660         (WebCore::RenderVideo::paintReplaced):
1661         (WebCore::RenderVideo::updatePlayer):
1662         * rendering/RenderVideo.h:
1663
1664 2008-01-02  Ada Chan  <adachan@apple.com>
1665
1666         Fix windows build.
1667
1668         * WebCore.vcproj/WebCore.vcproj:
1669
1670 2008-01-02  John Sullivan  <sullivan@apple.com>
1671
1672         Reviewed by Dan Bernstein
1673         
1674         - fixed <rdar://problem/5579010> REGRESSION: Safari inserts newlines in tab names when U+2028 is present
1675
1676         * loader/DocumentLoader.cpp:
1677         (WebCore::canonicalizedTitle):
1678         in the code that replaces control characters with white space, also replace the unicode line separator
1679         and paragraph separator characters
1680
1681 2008-01-02  Darin Adler  <darin@apple.com>
1682
1683         - fix buffer overruns seen on buildbot
1684
1685         * platform/text/StringImpl.cpp:
1686         (WebCore::countCharacter): Added this.
1687         (WebCore::StringImpl::toCoordsArray): Use countCharacter instead of incorrect find expression.
1688         (WebCore::StringImpl::toLengthArray): Ditto.
1689         (WebCore::StringImpl::replace): Added assertions.
1690
1691 2008-01-02  Darin Adler  <darin@apple.com>
1692
1693         Reviewed by Maciej.
1694
1695         - fix http://bugs.webkit.org/show_bug.cgi?id=16657
1696           Acid3 failure since table.caption and table.thead do not work for nodes added by appendChild
1697         - fix http://bugs.webkit.org/show_bug.cgi?id=16659
1698           Acid3 expects HTMLTableElement.rows to include a <tr> element that is an immediate child of the <table>
1699
1700         Tests: dom/html/level2/html/HTMLCollection07.html
1701                dom/html/level2/html/HTMLCollection08.html
1702                dom/html/level2/xhtml/HTMLCollection07.xhtml
1703                dom/html/level2/xhtml/HTMLCollection08.xhtml
1704                fast/dom/HTMLTableElement/early-acid3-65-excerpt.html
1705                fast/dom/HTMLTableElement/early-acid3-66-excerpt.html
1706
1707         * GNUmakefile.am: Added HTMLTableRowsCollection.
1708         * WebCore.pro: Ditto.
1709         * WebCore.vcproj/WebCore.vcproj: Ditto.
1710         * WebCore.xcodeproj/project.pbxproj: Ditto.
1711         * WebCoreSources.bkl: Ditto.
1712
1713         * dom/XMLTokenizer.cpp: Took out stray include.
1714
1715         * html/HTMLCollection.cpp:
1716         (WebCore::HTMLCollection::itemAfter): Removed all the table rows code, since we now use
1717         a separate class for that collection. Also got rid of the distinct types for custom collections
1718         that don't need them (use Other for both).
1719         * html/HTMLCollection.h: Also made firstItem non-virtual because it doesn't need to be virtual.
1720
1721         * html/HTMLFormCollection.cpp:
1722         (WebCore::HTMLFormCollection::HTMLFormCollection): Use Other instead of FormElements
1723         for the HTMLCollection type.
1724
1725         * html/HTMLTableElement.cpp:
1726         (WebCore::HTMLTableElement::HTMLTableElement): Eliminated m_head, m_foot, m_firstBody, and m_caption.
1727         (WebCore::HTMLTableElement::caption): Added non-inline version. Finds the caption rather than
1728         keeping a pointer to it.
1729         (WebCore::HTMLTableElement::setCaption): Rewrote.
1730         (WebCore::HTMLTableElement::tHead): Ditto.
1731         (WebCore::HTMLTableElement::setTHead): Ditto.
1732         (WebCore::HTMLTableElement::tFoot): Ditto.
1733         (WebCore::HTMLTableElement::setTFoot): Ditto.
1734         (WebCore::HTMLTableElement::createTHead): Ditto.
1735         (WebCore::HTMLTableElement::deleteTHead): Ditto.
1736         (WebCore::HTMLTableElement::createTFoot): Ditto.
1737         (WebCore::HTMLTableElement::deleteTFoot): Ditto.
1738         (WebCore::HTMLTableElement::createCaption): Ditto.
1739         (WebCore::HTMLTableElement::deleteCaption): Ditto.
1740         (WebCore::HTMLTableElement::lastBody): Added.
1741         (WebCore::HTMLTableElement::insertRow): Rewrote to use a loop based on code in HTMLTableRowsCollection.
1742         This is different from the old code mainly in how it handles rows outside any section.
1743         (WebCore::HTMLTableElement::deleteRow): Ditto.
1744         (WebCore::HTMLTableElement::addChild): Removed code to set the various members. Keeping pointers to
1745         these was a possible source of serious bugs too, including crashes with stale pointers, although I
1746         didn't write any test cases to prove those bugs existed.
1747         (WebCore::HTMLTableElement::parseMappedAttribute): Changed the rules code to visit all cells, not
1748         just the cells of the first body. I believe this fixed rendering on some table tests. I think the code
1749         visits too many cells and also the use of recursion is overkill, but I didn't try to fix that.
1750         (WebCore::HTMLTableElement::rows): Changed to use the new HTMLTableRowsCollection.
1751         * html/HTMLTableElement.h: Changed functions to return PassRefPtr, which can be important if strange
1752         things like DOM mutation events take things ot of the tree before they are safely referenced by
1753         JavaScript wrappers. Also changed functions to take PassRefPtr and added exceptions. Removed unneeded
1754         firstTBody and setTBody functions and childrenChanged function override, as well as unused Rules and
1755         Frame enums. Removed m_head, m_foot, m_firstBody, and m_caption, and added lastBody function. Removed
1756         unneeded friend declaration for HTMLTableCellElement.
1757         * html/HTMLTableElement.idl: Allow the setteres for caption, tHead, and tFoot to raise exceptions.
1758
1759         * html/HTMLTableRowsCollection.cpp: Added. Implements the HTML 5 rule for which rows are in the
1760         collection in which order.
1761         * html/HTMLTableRowsCollection.h: Added.
1762
1763         * loader/FTPDirectoryDocument.cpp:
1764         (WebCore::FTPDirectoryTokenizer::appendEntry): Use the standard insertRow function instead of
1765         coming up with our own way of inserting a row. Simplifies things -- we can remove the code to
1766         create a tbody element.
1767
1768 2008-01-02  Darin Adler  <darin@apple.com>
1769
1770         Reviewed by Alice and Tim.
1771
1772         - try to fix GTK and Qt builds
1773
1774         * platform/win/ScrollViewWin.cpp:
1775         (WebCore::ScrollView::scroll): Improve logic slightly for the case of
1776         vertical scrolling when there's no vertical scroll bar.
1777
1778         * platform/gtk/ScrollViewGtk.cpp:
1779         (WebCore::ScrollView::scroll): Copy the code from Windows. Maybe this
1780         should be factored differently.
1781         * platform/qt/ScrollViewQt.cpp:
1782         (WebCore::ScrollView::scroll): Ditto.
1783
1784 2008-01-02  Darin Adler  <darin@apple.com>
1785
1786         Reviewed by Anders.
1787
1788         - http://bugs.webkit.org/show_bug.cgi?id=16712
1789           change StringImpl to take and return PassRefPtr instead of raw pointers
1790
1791         Also eliminated use of const StringImpl. Since StringImpl is immutable there
1792         is no distinction between a const and non-const one at the moment.
1793
1794         * WebCore.base.exp: Updated.
1795
1796         * css/CSSHelper.cpp:
1797         (WebCore::parseURL): Make String directly, not by making a StringImpl.
1798         * dom/Attr.cpp:
1799         (WebCore::Attr::createTextChild): Convert AtomicString to String with domString,
1800         not via StringImpl.
1801         (WebCore::Attr::setValue): Remove unneed call to impl() when passing a String
1802         to a function that takes a String.
1803
1804         * dom/CDATASection.cpp: Removed unused constructor.
1805         (WebCore::CDATASection::cloneNode): Added a now-needed .get().
1806         (WebCore::CDATASection::createNew): Changed function to take a PassRefPtr.
1807         * dom/CDATASection.h:
1808
1809         * dom/CharacterData.cpp:
1810         (WebCore::CharacterData::CharacterData): Removed unneeded initialization and
1811         ref() now that the string is a RefPtr. Also updated to not call "new StringImpl".
1812         (WebCore::CharacterData::~CharacterData): Removed unneeded deref() since it's
1813         a RefPtr.
1814         (WebCore::CharacterData::setData): More of that.
1815         (WebCore::CharacterData::substringData): Ditto.
1816         (WebCore::CharacterData::appendData): Ditto.
1817         (WebCore::CharacterData::insertData): Ditto.
1818         (WebCore::CharacterData::deleteData): Ditto.
1819         (WebCore::CharacterData::replaceData): Ditto.
1820         (WebCore::CharacterData::nodeValue): Ditto.
1821         (WebCore::CharacterData::dispatchModifiedEvent): Ditto.
1822         (WebCore::CharacterData::dump): Ditto.
1823         * dom/CharacterData.h: Changed to use a RefPtr. I could have used a String
1824         instead, but since String adds extra branches to handle 0, I figured it was
1825         more conservative to just use RefPtr. Later it would be good to figure out
1826         which is preferred style and be more consistent. Maybe we'll phase out
1827         StringImpl, or maybe we'll go the other way and use it more since it can be
1828         more efficient.
1829
1830         * dom/DOMImplementation.cpp:
1831         (WebCore::addString): Changed set to use String rather than StringImpl.
1832         (WebCore::isSVG10Feature): Ditto.
1833         (WebCore::isSVG11Feature): Ditto.
1834         (WebCore::DOMImplementation::createDocument): Replaced custom code to
1835         find a colon with a call to String::find.
1836
1837         * dom/Range.cpp:
1838         (WebCore::Range::insertNode): Updated since the result of splitText is now
1839         a PassRefPtr.
1840
1841         * dom/Text.cpp:
1842         (WebCore::Text::splitText): Updated since str is now a RefPtr. Also made the
1843         result of this function be a PassRefPtr.
1844         (WebCore::Text::createRenderer): Ditto.
1845         (WebCore::Text::createNew): Made the parameter and result both be PassRefPtr.
1846         * dom/Text.h:
1847
1848         * html/HTMLElement.cpp:
1849         (WebCore::HTMLElement::nodeName): Use String::upper.
1850
1851         * html/HTMLInputElement.cpp:
1852         (WebCore::numGraphemeClusters): Remove now-unneeded const.
1853         (WebCore::numCharactersInGraphemeClusters): Ditto.
1854
1855         * html/HTMLTokenizer.cpp:
1856         (WebCore::HTMLTokenizer::processToken): Updated for function name change.
1857
1858         * platform/text/AtomicString.cpp:
1859         (WebCore::CStringTranslator::translate): Updated since there is no longer
1860         a constructor that takes a string.
1861
1862         * platform/text/PlatformString.h: Added new constructors that take
1863         PassRefPtr and RefPtr. Removed misleading comment.
1864
1865         * platform/text/String.cpp:
1866         (WebCore::String::String): Changed to use StringImpl::create, which handles
1867         the empty string automatically.
1868         (WebCore::String::append): Ditto.
1869         (WebCore::String::charactersWithNullTermination): Similar.
1870         (WebCore::String::format): Ditto.
1871
1872         * platform/text/StringHash.h: Took out unneeded const.
1873
1874         * platform/text/StringImpl.cpp:
1875         (WebCore::deleteUCharVector): Changed to take a const pointer since the
1876         buffers are now const UChar buffers.
1877         (WebCore::StringImpl::StringImpl): Removed some constructors. Got rid of the
1878         separate init functions. The constructors are now private and used only in
1879         the create functions and one or two other places.
1880         (WebCore::StringImpl::containsOnlyWhitespace): Removed now-meaningless const.
1881         (WebCore::StringImpl::substring): Ditto. Also changed return value to be a
1882         PassRefPtr.
1883         (WebCore::StringImpl::characterStartingAt): Ditto.
1884         (WebCore::StringImpl::toLength): Ditto.
1885         (WebCore::StringImpl::toCoordsArray): Ditto.
1886         (WebCore::StringImpl::toLengthArray): Ditto.
1887         (WebCore::StringImpl::isLower): Ditto.
1888         (WebCore::StringImpl::lower): Ditto. Changed to use Vector and adopt so we
1889         don't have to use new directly here. Makes empty string handling more consistent.
1890         (WebCore::StringImpl::upper): Ditto.
1891         (WebCore::StringImpl::secure): Ditto.
1892         (WebCore::StringImpl::foldCase): Ditto.
1893         (WebCore::StringImpl::stripWhiteSpace): Ditto.
1894         (WebCore::StringImpl::simplifyWhiteSpace): Ditto.
1895         (WebCore::StringImpl::capitalize): Ditto.
1896         (WebCore::StringImpl::toInt): Removed now-meaningless const.
1897         (WebCore::StringImpl::toInt64): Ditto.
1898         (WebCore::StringImpl::toUInt64): Ditto.
1899         (WebCore::StringImpl::toDouble): Ditto.
1900         (WebCore::StringImpl::toFloat): Ditto.
1901         (WebCore::StringImpl::find): Ditto.
1902         (WebCore::StringImpl::reverseFind): Ditto.
1903         (WebCore::StringImpl::endsWith): Ditto.
1904         (WebCore::StringImpl::replace): Ditto.
1905         (WebCore::equal): Ditto.
1906         (WebCore::equalIgnoringCase): Ditto.
1907         (WebCore::StringImpl::ascii): Ditto.
1908         (WebCore::StringImpl::defaultWritingDirection): Ditto.
1909         (WebCore::StringImpl::createStrippingNullCharacters): Ditto.
1910         (WebCore::StringImpl::adopt): Added special case so this uses the shared
1911         empty string like other functions. Also optimized the common case where the
1912         vector happens to already have the right size so we don't do a fastRealloc
1913         at all in those cases.
1914         (WebCore::StringImpl::create): Added. These are now the public functions for
1915         creating new StringImpl objects. They all implement the shared empty string.
1916         (WebCore::StringImpl::createWithTerminatingNullCharacter):
1917         * platform/text/StringImpl.h:
1918
1919         * platform/text/cf/StringCF.cpp:
1920         (WebCore::String::String): Use StringImpl::create instead of new StringImpl.
1921         * platform/text/cf/StringImplCF.cpp:
1922         (WebCore::StringImpl::createCFString): Removed now-obsolete const.
1923         * platform/text/mac/StringImplMac.mm:
1924         (WebCore::StringImpl::operator NSString *): Ditto.
1925         * platform/text/mac/StringMac.mm:
1926         (WebCore::String::String): Use StringImpl::create instead of new StringImpl.
1927         * platform/text/qt/StringQt.cpp:
1928         (WebCore::String::String): Ditto.
1929         * platform/text/wx/StringWx.cpp:
1930         (WebCore::String::String): Ditto.
1931         * rendering/RenderBR.cpp:
1932         (WebCore::RenderBR::RenderBR): Ditto.
1933
1934         * rendering/RenderSVGInlineText.cpp:
1935         (WebCore::RenderSVGInlineText::RenderSVGInlineText): Use PassRefPtr.
1936         * rendering/RenderSVGInlineText.h:
1937
1938         * rendering/RenderText.cpp:
1939         (WebCore::charactersAreAllASCII): Removed now-unneeded const.
1940         * rendering/RenderTextFragment.cpp:
1941         (WebCore::RenderTextFragment::originalText): Use RefPtr.
1942
1943 2008-01-02  Timothy Hatcher  <timothy@apple.com>
1944
1945         Reviewed by Oliver Hunt.
1946
1947         <rdar://problem/5618086> WebInspector does not expand the DOM tree after being closed
1948
1949         Closing the Web Inspector causes the DOM tree outline to be torn down, clearing the
1950         internal element lookup tables. The represented DOM node object still holds the identifier
1951         it was assigned, and a later call to findTreeElement will use that original identifier
1952         against a cleared lookup table. In that case we need to fallback on DOM ancestor lookup.
1953
1954         * page/inspector/treeoutline.js:
1955         (TreeOutline.prototype.findTreeElement): If the DOM node already had a __treeElementIdentifier,
1956         but the TreeOutline no longer has the element in the _knownTreeElements list do an ancestor lookup
1957         instead of an early return.
1958
1959 2008-01-02  Alice Liu  <alice.liu@apple.com>
1960
1961         Reviewed by Maciej.
1962
1963         Fixed <rdar://5283861> (problems scrolling in gmail message content area)
1964
1965         * platform/ScrollView.h:
1966         * platform/win/ScrollViewWin.cpp:
1967         (WebCore::ScrollView::scroll):
1968          Changed return value to bool to reflect success of scroll attempt
1969
1970 2008-01-02  Alexey Proskuryakov  <ap@webkit.org>
1971
1972         Fixed a typo (pointed out in review, but I somehow missed it at first).
1973
1974         * editing/EditorCommand.cpp: (WebCore::executeDelete):
1975
1976 2008-01-02  Alexey Proskuryakov  <ap@webkit.org>
1977
1978         Reviewed by Darin.
1979
1980         Resolved several FIXMEs in EditorCommand.
1981         Made recently added commands hidden from JS again.
1982         Removed BackwardDelete implementation, which used to be dead code, but got exposed now.
1983
1984         Tests: editing/execCommand/delete-no-scroll.html
1985                editing/execCommand/forward-delete-no-scroll.html
1986                editing/execCommand/insert-line-break-no-scroll.html
1987
1988         * editing/EditorCommand.cpp:
1989         (WebCore::executeDelete):
1990         (WebCore::executeForwardDelete):
1991         (WebCore::executeInsertLineBreak):
1992         (WebCore::supportedFromMenuOrKeyBinding):
1993         (WebCore::CommandEntry::):
1994
1995 2008-01-02  Alexey Proskuryakov  <ap@webkit.org>
1996
1997         Reviewed by Darin.
1998
1999         http://bugs.webkit.org/show_bug.cgi?id=14555
2000         action=mailto + method=get - The generated mailto URI is incorrect and the hvalues are encoded twice
2001
2002         http://bugs.webkit.org/show_bug.cgi?id=14774
2003         Submitted data only includes first input item
2004
2005         Reworked encoding of mailto URLs to match other browsers.
2006         Moved most of related logic from FrameLoader::submitForm() to HTMLFormElement::submit().
2007
2008         Tests: fast/forms/mailto/advanced-get.html
2009                fast/forms/mailto/advanced-put.html
2010                fast/forms/mailto/get-multiple-items-text-plain.html
2011                fast/forms/mailto/get-multiple-items-x-www-form-urlencoded.html
2012                fast/forms/mailto/get-multiple-items.html
2013                fast/forms/mailto/get-non-ascii.html
2014                fast/forms/mailto/get-non-ascii-text-plain.html
2015                fast/forms/mailto/get-overwrite-query.html
2016                fast/forms/mailto/post-append-query.html
2017                fast/forms/mailto/post-multiple-items-multipart-form-data.html
2018                fast/forms/mailto/post-multiple-items-text-plain.html
2019                fast/forms/mailto/post-multiple-items-x-www-form-urlencoded.html
2020                fast/forms/mailto/post-multiple-items.html
2021
2022         * html/HTMLFormElement.cpp:
2023         (WebCore::HTMLFormElement::submit):
2024         * loader/FrameLoader.cpp:
2025         (WebCore::FrameLoader::submitForm):
2026
2027 2008-01-02  Mark Rowe  <mrowe@apple.com>
2028
2029         Autotools build fix.
2030
2031         * GNUmakefile.am: Remove files before generating them, not after.
2032
2033 2008-01-02  Mark Rowe  <mrowe@apple.com>
2034
2035         Rubber-stamped by Alp Toker.
2036
2037         Add missing dependencies to some GNUmakefile.am rules.
2038
2039         * GNUmakefile.am:
2040
2041 2008-01-02  Mark Rowe  <mrowe@apple.com>
2042
2043         Reviewed by Alp Toker.
2044
2045         Autotools build fix.  Make can expand $@ to any of the targets for the rule,
2046         while we always want to use the name of the .cpp file as the output file.
2047
2048         * GNUmakefile.am:
2049
2050 2008-01-02  Luca Bruno  <lethalman88@gmail.com>
2051
2052         Reviewed by Alp Toker.
2053
2054         http://bugs.webkit.org/show_bug.cgi?id=16115
2055         [GTK] ContextMenu and ContextMenuItem lacks an implementation
2056
2057         Add context menu support.
2058
2059         Based on a patch by Holger Freyther.
2060
2061         * platform/gtk/ContextMenuGtk.cpp:
2062         (WebCore::menuItemActivated):
2063         (WebCore::ContextMenu::ContextMenu):
2064         (WebCore::ContextMenu::~ContextMenu):
2065         (WebCore::ContextMenu::appendItem):
2066         (WebCore::ContextMenu::setPlatformDescription):
2067         (WebCore::ContextMenu::releasePlatformDescription):
2068         * platform/gtk/ContextMenuItemGtk.cpp:
2069         (WebCore::ContextMenuItem::ContextMenuItem):
2070         (WebCore::ContextMenuItem::~ContextMenuItem):
2071         (WebCore::ContextMenuItem::releasePlatformDescription):
2072         (WebCore::ContextMenuItem::type):
2073         (WebCore::ContextMenuItem::action):
2074         (WebCore::ContextMenuItem::setAction):
2075         (WebCore::ContextMenuItem::platformSubMenu):
2076         (WebCore::ContextMenuItem::setSubMenu):
2077         (WebCore::ContextMenuItem::setChecked):
2078         (WebCore::ContextMenuItem::setEnabled):
2079
2080 2008-01-02  Alp Toker  <alp@atoker.com>
2081
2082         GTK+ autotools build fix. Track changes in r29073.
2083
2084         * GNUmakefile.am:
2085
2086 2008-01-01  Darin Adler  <darin@apple.com>
2087
2088         - fix release build
2089
2090         * bindings/js/kjs_binding.cpp:
2091         (KJS::setDOMException): Initialize to avoid uninitialized variable warning.
2092         Removed default so we get a warning if there's a missing case.
2093
2094 2008-01-01  David D. Kilzer  <ddkilzer@webkit.org>
2095
2096         Scripting MIME Types application/ecmascript, application/javascript not viewable
2097         <http://bugs.webkit.org/show_bug.cgi?id=11063>
2098
2099         Reviewed by Darin.
2100
2101         This patch consolidates the list of acceptable MIME types for JavaScript
2102         source into the MIMETypeRegistry class, and replaces checks for these
2103         types with a call to MIMETypeRegistry::isSupportedJavaScriptMIMEType().
2104
2105         No tests added since viewing JavaScript source is not testable.
2106
2107         * dom/DOMImplementation.cpp:
2108         (WebCore::DOMImplementation::isTextMIMEType): Use
2109         MIMETypeRegistry::isSupportedJavaScriptMIMEType() instead of a single
2110         hard-coded MIME type, "application/x-javascript".
2111
2112         * html/HTMLScriptElement.cpp:
2113         (WebCore::HTMLScriptElement::shouldExecuteAsJavaScript): Moved list of
2114         JavaScript MIME types from here to
2115         MIMETypeRegistry::initialiseSupportedJavaScriptMIMETypes().
2116
2117         * platform/MIMETypeRegistry.cpp:
2118         (WebCore::initialiseSupportedJavaScriptMIMETypes): Added. List of
2119         MIME types came from HTMLScriptElement::shouldExecuteAsJavaScript().
2120         (WebCore::initialiseSupportedNonImageMimeTypes): Remove single
2121         hard-coded MIME type, "application/x-javascript", from the list.
2122         (WebCore::initialiseMIMETypeRegistry): Initialise
2123         supportedJavaScriptMIMETypes, then pre-populate supportedNonImageMIMETypes
2124         with values in supportedJavaScriptMIMETypes.
2125         (WebCore::MIMETypeRegistry::isSupportedJavaScriptMIMEType): Added.
2126
2127         * platform/MIMETypeRegistry.h: Added isSupportedJavaScriptMIMEType().
2128
2129 2008-01-01  Sam Weinig  <sam@webkit.org>
2130
2131         Reviewed by Darin.
2132
2133         Patch for http://bugs.webkit.org/show_bug.cgi?id=16691
2134         Use real JS objects for the rest of the DOMExceptions (EventException, RangeException, etc)
2135
2136         - Create JS objects for all the different types of exceptions, each with there own prototype and constructor.
2137         - Abstract all the logic and storage for exception classes in to an ExceptionBase class.
2138         - Move specialized ExceptionCodes into the exception classes. (ie. the EventExceptionCode enum is now in EventException).
2139
2140         Tests: fast/dom/DOMException/EventException.html
2141                fast/dom/DOMException/RangeException.html
2142                fast/dom/DOMException/XPathException.html
2143                http/tests/xmlhttprequest/XMLHttpRequestException.html
2144                svg/custom/SVGException.html
2145
2146         * DerivedSources.make:
2147         * WebCore.pro:
2148         * WebCore.vcproj/WebCore.vcproj:
2149         * WebCore.xcodeproj/project.pbxproj:
2150         * WebCoreSources.bkl:
2151         * bindings/js/JSSVGMatrixCustom.cpp:
2152         (WebCore::JSSVGMatrix::inverse):
2153         (WebCore::JSSVGMatrix::rotateFromVector):
2154         * bindings/js/kjs_binding.cpp:
2155         (KJS::setDOMException):
2156         * bindings/scripts/CodeGeneratorJS.pm: Use the constant values defined
2157         in the IDL as the ObjC bindings do.
2158         * bindings/scripts/CodeGeneratorObjC.pm:
2159         * dom/DOMCoreException.cpp: Removed.
2160         * dom/DOMCoreException.h:
2161         (WebCore::DOMCoreException::DOMCoreException):
2162         * dom/DOMCoreException.idl:
2163         * dom/Event.h:
2164         * dom/EventException.h: Copied from WebCore/dom/DOMCoreException.h.
2165         (WebCore::EventException::EventException):
2166         (WebCore::EventException::):
2167         * dom/EventException.idl: Copied from WebCore/dom/DOMCoreException.idl.
2168         * dom/EventTargetNode.cpp:
2169         (WebCore::EventTargetNode::dispatchEvent):
2170         * dom/ExceptionBase.cpp: Copied from WebCore/dom/DOMCoreException.cpp.
2171         (WebCore::ExceptionBase::ExceptionBase):
2172         (WebCore::ExceptionBase::toString):
2173         * dom/ExceptionBase.h: Copied from WebCore/dom/DOMCoreException.h.
2174         (WebCore::ExceptionBase::code):
2175         * dom/ExceptionCode.cpp:
2176         (WebCore::getExceptionCodeDescription):
2177         * dom/ExceptionCode.h:
2178         (WebCore::):
2179         * dom/Range.cpp:
2180         (WebCore::Range::insertNode):
2181         (WebCore::Range::checkNodeWOffset):
2182         (WebCore::Range::checkNodeBA):
2183         (WebCore::Range::selectNode):
2184         (WebCore::Range::selectNodeContents):
2185         (WebCore::Range::surroundContents):
2186         * dom/RangeException.h:
2187         (WebCore::RangeException::RangeException):
2188         (WebCore::RangeException::):
2189         * dom/RangeException.idl:
2190         * page/DOMWindow.idl:
2191         * svg/SVGColor.cpp:
2192         (WebCore::SVGColor::setRGBColor):
2193         * svg/SVGException.h:
2194         (WebCore::SVGException::SVGException):
2195         (WebCore::SVGException::):
2196         * svg/SVGException.idl:
2197         * svg/SVGLocatable.cpp:
2198         (WebCore::SVGLocatable::getTransformToElement):
2199         * xml/XMLHttpRequest.cpp:
2200         (WebCore::XMLHttpRequest::dispatchEvent):
2201         (WebCore::XMLHttpRequest::open):
2202         (WebCore::XMLHttpRequest::send):
2203         * xml/XMLHttpRequest.h:
2204         * xml/XMLHttpRequestException.h: Copied from WebCore/dom/DOMCoreException.h.
2205         (WebCore::XMLHttpRequestException::XMLHttpRequestException):
2206         (WebCore::XMLHttpRequestException::):
2207         * xml/XMLHttpRequestException.idl: Copied from WebCore/dom/DOMCoreException.idl.
2208         * xml/XPathEvaluator.h:
2209         * xml/XPathException.h: Copied from WebCore/dom/DOMCoreException.h.
2210         (WebCore::XPathException::XPathException):
2211         (WebCore::XPathException::):
2212         * xml/XPathException.idl: Copied from WebCore/dom/DOMCoreException.idl.
2213         * xml/XPathParser.cpp:
2214         (WebCore::XPath::Parser::parseStatement):
2215         * xml/XPathResult.cpp:
2216         (WebCore::XPathResult::convertTo):
2217         (WebCore::XPathResult::numberValue):
2218         (WebCore::XPathResult::stringValue):
2219         (WebCore::XPathResult::booleanValue):
2220         (WebCore::XPathResult::singleNodeValue):
2221         (WebCore::XPathResult::snapshotLength):
2222         (WebCore::XPathResult::iterateNext):
2223         (WebCore::XPathResult::snapshotItem):
2224
2225 2008-01-01  Sam Weinig  <sam@webkit.org>
2226
2227         Remove JSDomExceptionConstructor.lut.h from clean step
2228         as it no longer exists.
2229
2230         * GNUmakefile.am:
2231
2232 2008-01-01  Dan Bernstein  <mitz@apple.com>
2233
2234         - Windows build fix
2235
2236         * WebCore.vcproj/WebCore.vcproj:
2237
2238 2008-01-01  Sam Weinig  <sam@webkit.org>
2239
2240         Try again to fix the builds
2241
2242         * DerivedSources.make:
2243
2244 2008-01-01  Sam Weinig  <sam@webkit.org>
2245
2246         Fix non-mac builds.
2247
2248         * WebCore.pro:
2249         * WebCore.vcproj/WebCore.vcproj:
2250         * WebCoreSources.bkl:
2251
2252 2008-01-01  Eric Seidel  <eric@webkit.org>
2253
2254         Reviewed by Alexey.
2255
2256         Don't replace \ with / in data: urls
2257         http://bugs.webkit.org/show_bug.cgi?id=16692
2258
2259         Test: fast/loader/url-data-replace-backslash.html
2260
2261         * platform/KURL.cpp:
2262         (WebCore::KURL::init):
2263
2264 2008-01-01  Alp Toker  <alp@atoker.com>
2265
2266         GTK+ autotools build fix. Track changes in r29051, r29058 and pass the
2267         correct parameter to AM_INIT_AUTOMAKE.
2268
2269         * GNUmakefile.am:
2270
2271 2007-12-31  Sam Weinig  <sam@webkit.org>
2272
2273         Reviewed by Darin.
2274
2275         Patch for http://bugs.webkit.org/show_bug.cgi?id=16637
2276         Acid3 expects ExeceptionCode constants to be defined on DOMException objects
2277
2278         - Make DOMException a real JS object.
2279
2280         Test: fast/dom/DOMException/prototype-object.html
2281
2282         * DerivedSources.make:
2283         * WebCore.xcodeproj/project.pbxproj:
2284
2285         This is no longer needed as the autogenerated classes now includes the
2286         constructor.
2287         * bindings/js/JSDOMExceptionConstructor.cpp: Removed.
2288         * bindings/js/JSDOMExceptionConstructor.h: Removed.
2289
2290         Create on demand and use the new class for DOMExceptions.
2291         * bindings/js/kjs_binding.cpp:
2292         (KJS::setDOMException):
2293
2294         Remove no longer needed custom constructor getter.
2295         * bindings/js/kjs_window.cpp:
2296         (KJS::Window::getValueProperty):
2297
2298         Don't expose DOMCoreException as the name of class by special casing
2299         the user visible class name to be DOMException.
2300         * bindings/scripts/CodeGeneratorJS.pm:
2301
2302         The DOMException class/file needs to be named DOMCoreException because there is
2303         name conflict with one of the Objective-C bindings classes.  It should be renamed
2304         to DOMException when the Objective-C bindings are moved into WebKit.
2305         * dom/DOMCoreException.cpp: Added.
2306         (WebCore::DOMCoreException::DOMCoreException):
2307         (WebCore::DOMCoreException::toString):
2308         * dom/DOMCoreException.h: Added.
2309         (WebCore::DOMCoreException::):
2310         (WebCore::DOMCoreException::code):
2311         (WebCore::DOMCoreException::name):
2312         (WebCore::DOMCoreException::message):
2313         * dom/DOMCoreException.idl: Added.
2314         * page/DOMWindow.idl:
2315
2316 2007-12-31  Sam Weinig  <sam@webkit.org>
2317
2318         Re-enable querySelector and querySelectorAll and touch the necessary files to not
2319         kill the windows build.
2320
2321         * WebCore.vcproj/build-generated-files.sh:
2322         * bindings/scripts/CodeGeneratorCOM.pm:
2323         * dom/Document.idl:
2324         * dom/Element.idl:
2325
2326 2007-12-31  Darin Adler  <darin@apple.com>
2327
2328         - fix Windows build
2329
2330         * dom/Document.idl: Temporarily disable querySelector and querySelectorAll, since they are showing
2331         up as pure virtual functions. Sam can fix this later.
2332         * dom/Element.idl: Ditto.
2333
2334 2007-12-31  Dan Bernstein  <mitz@apple.com>
2335
2336         Reviewed by Darin Adler.
2337
2338         - fix http://bugs.webkit.org/show_bug.cgi?id=14134
2339           <rdar://problem/5655160> REGRESSION (r25353): Whitespace nodes ignored between inline list items
2340
2341         Test: fast/dynamic/create-renderer-for-whitespace-only-text.html
2342
2343         * dom/Node.cpp:
2344         (WebCore::Node::attach): Added code to check if this node's renderer
2345         has become the "previous renderer" of any sibling text node, and if so,
2346         ensure that that node gets a renderer if it now needs one.
2347         (WebCore::Node::createRendererIfNeeded): Removed the assertion that the
2348         node is not attached.
2349
2350 2007-12-31  Darin Adler  <darin@apple.com>
2351
2352         Reviewed by Mitz.
2353
2354         - fix http://bugs.webkit.org/show_bug.cgi?id=16641
2355           Acid3 reveals HTMLFormElement.elements fails to update when element name changes
2356
2357         Test: fast/dom/HTMLFormElement/elements-not-in-document.html
2358
2359         This was a bug specific to forms that are not in the document tree.
2360         The fix was to change the code to increment the document version number to match
2361         up with other document change tracking. Maybe at some point we can clean these up
2362         so we don't have so many competing change notification systems.
2363
2364         * dom/ContainerNode.cpp:
2365         (WebCore::ContainerNode::replaceChild): Removed bogus comment.
2366         (WebCore::ContainerNode::addChild): Added an explicit incDOMTreeVersion
2367         call here, since this code path bypasses the subtree-modified event code.
2368
2369         * dom/Element.cpp:
2370         (WebCore::Element::setAttribute): Remove the inDocument() check -- not all HTML
2371         collections are for things in the document.
2372         (WebCore::Element::setAttributeMap): Ditto.
2373
2374         * dom/EventTargetNode.cpp:
2375         (WebCore::EventTargetNode::dispatchSubtreeModifiedEvent): Added a call to
2376         incDOMTreeVersion here; covers most cases of tree structure changes.
2377
2378         * dom/Node.cpp:
2379         (WebCore::Node::attach): Remove call to incDOMTreeVersion -- creating a renderer
2380         has nothing to do with changes to the DOM tree!
2381         (WebCore::Node::detach): Ditto.
2382
2383         * html/HTMLFormElement.cpp:
2384         (WebCore::HTMLFormElement::registerFormElement): Remove call to incDOMTreeVersion.
2385         This is handled at a lower level and doesn't need to be here.
2386         (WebCore::HTMLFormElement::removeFormElement): Ditto.
2387
2388 2007-12-31  Henry Mason  <hmason@mac.com>
2389
2390         Reviewed by Darin.
2391
2392         Patch for http://bugs.webkit.org/show_bug.cgi?id=14994
2393         Support for MessageEvent and cross-domain messaging
2394
2395         Test: http/tests/messaging/cross-domain-message-send.html
2396
2397         * DerivedSources.make:
2398         * WebCore.pro:
2399         * WebCore.vcproj/WebCore.vcproj:
2400         * WebCore.xcodeproj/project.pbxproj:
2401         * WebCoreSources.bkl:
2402         * bindings/js/JSDOMWindowCustom.cpp:
2403         (WebCore::JSDOMWindow::customGetOwnPropertySlot): Allow cross-domain access to the
2404         postMessage function.
2405         (WebCore::JSDOMWindow::postMessage):
2406         * bindings/js/JSEventCustom.cpp:
2407         (WebCore::toJS):
2408         * dom/Event.cpp:
2409         (WebCore::Event::isMessageEvent):
2410         * dom/Event.h:
2411         * dom/EventNames.h: New event name
2412         * dom/MessageEvent.cpp: Added.
2413         * dom/MessageEvent.h: Added.
2414         * dom/MessageEvent.idl: Added.
2415         * page/DOMWindow.cpp:
2416         (WebCore::DOMWindow::postMessage): Added.
2417         * page/DOMWindow.h:
2418         * page/DOMWindow.idl:
2419
2420 2007-12-31  Darin Adler  <darin@apple.com>
2421
2422         Suggested by Antti.
2423
2424         - turn ENABLE_VIDEO back off for Windows until we can install QuickTime on the build bots
2425
2426         * WebCore.vcproj/WebCore.vcproj: Removed ENABLE_VIDEO.
2427         * WebCore.vcproj/build-generated-files.sh: Ditto.
2428
2429 2007-12-30  Alp Toker  <alp@atoker.com>
2430
2431         Reviewed by Dan Bernstein.
2432
2433         Silence warning.
2434
2435         * dom/NodeList.h:
2436
2437 2007-12-30  Sam Weinig  <sam@webkit.org>
2438
2439         Reviewed by Oliver Hunt.
2440
2441         Fix for http://bugs.webkit.org/show_bug.cgi?id=16387
2442         Variable names can be enumerated across domains
2443         <rdar://problem/5640454>
2444
2445         Test: http/tests/security/cross-frame-access-enumeration.html
2446
2447         * bindings/js/kjs_window.cpp:
2448         (KJS::Window::getPropertyNames): Override method to test same-origin policy.
2449         * bindings/js/kjs_window.h:
2450
2451 2007-12-30  Sam Weinig  <sam@webkit.org>
2452
2453         Reviewed by Oliver Hunt.
2454
2455         Patch for http://bugs.webkit.org/show_bug.cgi?id=10686
2456         event instanceof MouseEvent throws exception
2457
2458         Add JS constructors for all the Event types.
2459
2460         Test: fast/events/event-instanceof.html
2461
2462         * WebCore.xcodeproj/project.pbxproj:
2463         * dom/KeyboardEvent.idl:
2464         * dom/MouseEvent.idl:
2465         * dom/MutationEvent.idl:
2466         * dom/OverflowEvent.idl:
2467         * dom/ProgressEvent.idl:
2468         * dom/TextEvent.idl:
2469         * dom/UIEvent.idl:
2470         * dom/WheelEvent.idl:
2471         * page/DOMWindow.idl:
2472
2473 2007-12-30  David Kilzer  <ddkilzer@webkit.org>
2474
2475         Reviewed by Darin.
2476
2477         - fix http://bugs.webkit.org/show_bug.cgi?id=15359
2478           JPEG image not shown when height is specified as percentage inside a table
2479
2480         The problem occurs when a replaced element (image, canvas, etc.) with
2481         a percent-height attribute is contained by a table cell with an auto-
2482         or percent-height attribute.  If there are no other conditions to cause
2483         the table cell's height to expand, an available height of zero will
2484         always be returned.  In these cases, the intrinsic height of the
2485         replaced element should be used if it is greater than the available
2486         height of the table cell.
2487
2488         Tests: fast/replaced/table-percent-height.html
2489                tables/mozilla/bugs/bug137388-1.html
2490                tables/mozilla/bugs/bug137388-2.html
2491
2492         * rendering/RenderBox.cpp:
2493         (WebCore::RenderBox::calcReplacedHeightUsing):
2494
2495 2007-12-30  Luca Bruno  <lethalman88@gmail.com>
2496
2497         Reviewed by Alp Toker.
2498
2499         http://bugs.webkit.org/show_bug.cgi?id=16099
2500         Crash in CURL for empty POST
2501
2502         We have to set POST even when the data is empty, otherwise cURL will
2503         hang while waiting for a response.
2504
2505         * platform/network/curl/ResourceHandleManager.cpp
2506         (ResourceHandleManager::setupPOST): allow empty POST
2507
2508 2007-12-29  Jan Michael Alonzo  <jmalonzo@unpluggable.com>
2509
2510         Reviewed by Alp Toker.
2511
2512         Move all SVG related stuff inside SVG block. Don't include
2513         SVGNames, SVGElementFactory, and XLinkNames when SVG is not
2514         enabled
2515
2516         * GNUmakefile.am:
2517
2518 2007-12-29  Alexey Proskuryakov  <ap@webkit.org>
2519
2520         Reviewed by Darin.
2521
2522         http://bugs.webkit.org/show_bug.cgi?id=14428
2523         FCKEditor: Images disappear on drag/drop and copy/paste
2524
2525         Test: editing/pasteboard/drag-image-in-about-blank-frame.html
2526
2527         * editing/markup.cpp: (WebCore::createFragmentFromMarkup): Don't use "about:blank" as a
2528         base URL, just like we don't use an empty one.
2529
2530 2007-12-29  Jan Michael Alonzo  <jmalonzo@unpluggable.com>
2531
2532         Reviewed by Alp Toker.
2533
2534         http://bugs.webkit.org/show_bug.cgi?id=16669
2535         autotools update and fixes
2536
2537         Autotools update and database/icon database inclusion guard fixes
2538
2539         * GNUmakefile.am:
2540           - Update autotools config as per -r29012 changes
2541           - Fix CSSGrammar.h/cpp generation (Seo Sanghyeon, sanxiyn)
2542         * dom/Document.cpp:
2543         * loader/icon/IconDatabase.h:
2544         * page/DOMWindow.cpp:
2545         * page/InspectorController.cpp:
2546         * page/Settings.cpp:
2547         * storage/Database.h:
2548           - Remove ENABLE(DATABASE) inclusion guard. Let the includer add the guard instead.
2549
2550 2007-12-29  Nikolas Zimmermann  <zimmermann@kde.org>
2551
2552         Reviewed by Alexey.
2553
2554         Respect horiz-origin-x / horiz-origin-y / vert-origin-x / vert-origin-y properties when drawing SVG Fonts.
2555         (Fixes fonts-elem-05-t.svg in a --svg-fonts build)
2556
2557         * svg/SVGFont.cpp:
2558         (WebCore::Font::drawGlyphsWithSVGFont):
2559
2560 2007-12-29  Nikolas Zimmermann  <zimmermann@kde.org>
2561
2562         Reviewed by Oliver.
2563
2564         Further SVG Font work. Parse all <glyph> attributes, using SVGGlyphElement::buildGlyphIdentifier.
2565         SVGFontElement::collectGlyphs() now uses this method. Per character advance values work well now.
2566
2567         * platform/graphics/FontData.cpp:
2568         (WebCore::SVGFontData::convertEmUnitToPixel): Add helper function.
2569         (WebCore::FontData::ascent):
2570         (WebCore::FontData::descent):
2571         * platform/graphics/FontData.h:
2572         * svg/SVGFont.cpp:
2573         (WebCore::isVerticalWritingMode): Add helper function.
2574         (WebCore::Font::drawGlyphsWithSVGFont):
2575         * svg/SVGFontElement.cpp:
2576         (WebCore::SVGFontElement::collectGlyphs): Simplified implementation - SVGGlyphIdentifier now build by SVGGlyphElement.
2577         * svg/SVGGlyphElement.cpp:
2578         (WebCore::parseArabicForm): Helper function.
2579         (WebCore::parseOrientation): Ditto.
2580         (WebCore::parsePathData): Ditto.
2581         (WebCore::SVGGlyphElement::buildGlyphIdentifier):
2582         * svg/SVGGlyphElement.h:
2583         (WebCore::SVGGlyphElement::rendererIsNeeded):
2584
2585 2007-12-29  Nikolas Zimmermann  <zimmermann@kde.org>
2586
2587         Reviewed by Oliver.
2588
2589         Refactor SVGAnimationElement::parseValues into a generic function parseDelimitedString.
2590         SVGAnimationElement needs to parse semicolon-seperated strings, SVGGlyphElement comma-seperated.
2591
2592         * svg/SVGAnimationElement.cpp:
2593         (WebCore::SVGAnimationElement::parseMappedAttribute):
2594         * svg/SVGParserUtilities.cpp:
2595         (WebCore::parseDelimitedString):
2596         * svg/SVGParserUtilities.h:
2597
2598 2007-12-29  Nikolas Zimmermann  <zimmermann@kde.org>
2599
2600         Reviewed by Maciej.
2601
2602         Add new helper structure SVGFontData - FontData holds this object as OwnPtr.
2603         Store several attribute values there (horiz-adv-x, horiz-origin-x etc..)
2604
2605         To optimize for the common case ('FontData' used for HTML rendering) it feels
2606         better to hold one OwnPtr in FontData, than several floats.
2607
2608         Parse all <font> attributes in SVGFontFaceElement::createFontData.
2609
2610         * platform/graphics/FontData.cpp:
2611         (WebCore::SVGFontData::SVGFontData):
2612         (WebCore::FontData::FontData):
2613         (WebCore::FontData::ascent):
2614         (WebCore::FontData::descent):
2615         * platform/graphics/FontData.h:
2616         (WebCore::FontData::isSVGFont):
2617         (WebCore::FontData::svgFontData):
2618         * svg/SVGFont.cpp:
2619         (WebCore::Font::drawGlyphsWithSVGFont):
2620         * svg/SVGFontElement.cpp:
2621         * svg/SVGFontElement.h:
2622         (WebCore::SVGFontElement::rendererIsNeeded):
2623         * svg/SVGFontFaceElement.cpp:
2624         (WebCore::SVGFontFaceElement::unitsPerEm):
2625         (WebCore::SVGFontFaceElement::createFontData):
2626
2627 2007-12-28  Darin Adler  <darin@apple.com>
2628
2629         - try to fix Windows and WX builds (broken by SVG Fonts check-in)
2630
2631         * platform/graphics/win/FontWin.cpp:
2632         (WebCore::Font::drawGlyphs): Pass font size to FontData::ascent, now that it requires it.
2633         I can't see how it can be right to require the font size for ascent and descent,
2634         but not for other metrics functions in FontData.
2635
2636         * platform/graphics/wx/FontWx.cpp:
2637         (WebCore::Font::drawGlyphs): Pass font size to FontData::ascent and FontData::descent.
2638
2639 2007-12-28  Dan Bernstein  <mitz@apple.com>
2640
2641         Reviewed by Mark Rowe.
2642
2643         - fix http://bugs.webkit.org/show_bug.cgi?id=16650
2644           <rdar://problem/5664872> REGRESSION (r28278-r28314): ATSUI uses LTR writing direction for all text runs
2645
2646         Covered by existing pixel tests.
2647
2648         * platform/graphics/mac/FontMac.mm:
2649         (WebCore::Font::drawComplexText): Corrected to maintain the style
2650         information in the adjusted text run when passing it to
2651         ATSUILayoutParameters. Prior to r28298 the style was passed separately.
2652
2653 2007-12-29  Nikolas Zimmermann  <zimmermann@kde.org>
2654
2655         Build fix, not reviewed.
2656
2657         Add wtf/OwnPtr.h include, to fix --svg-fonts build.
2658
2659         * css/SVGCSSFontFace.h:
2660
2661 2007-12-29  Nikolas Zimmermann  <zimmermann@kde.org>
2662
2663         Reviewed by Eric.
2664
2665         Fixes: http://bugs.webkit.org/show_bug.cgi?id=10649 (WebKit SVG needs SVG Fonts support)
2666
2667         Begin implementation of SVG Fonts module. Basic documents using SVG Fonts already work.
2668         Only local, in-document fonts who declare their glyphs using the <glyph d="..."> path syntax
2669         are supported. (<glyph> containing arbitary SVG content as child elements, not supported yet).
2670
2671         Limited to single char <-> glyph mapping, no ligatures supported yet.
2672         (ie. <glyph unicode='A'/> <glyph unicode='AB'/> - it ignores the 'AB' glyph definition for now)
2673
2674         Mark all SVG Font related classes & usages in ENABLE(SVG_FONTS) blocks.
2675
2676         No layout test changes for a --no-svg-fonts build, heavy changes if enabled. Because a lot of SVG Font
2677         attributes are not processed yet, the rendering looks wrong - hence disabled by default.)
2678
2679         * DerivedSources.make: Add SVGFontElement/SVGGlyphElement/SVGMissingGlyphElement
2680         * WebCore.pro: Updated build system.
2681         * WebCore.vcproj/WebCore.vcproj: Ditto.
2682         * WebCore.xcodeproj/project.pbxproj: Ditto.
2683         * bindings/js/JSSVGElementWrapperFactory.cpp: Add JSSVGFontElement/JSSVGGlyphElement/JSSVGMissingGlyphElement
2684         * bindings/objc/DOM.mm: Ditto (for DOMSVG*).
2685         (WebCore::createElementClassMap):
2686         * bindings/objc/DOMInternal.h: Ditto.
2687         * bindings/objc/DOMSVG.h: Ditto.
2688         * css/CSSFontFace.h: Mark three functions 'virtual', to be overriden by SVGCSSFontFace
2689         * css/CSSFontFaceSrcValue.h: Add functionality to identify as SVG CSS font face source.
2690         (WebCore::CSSFontFaceSrcValue::m_fontFaceElement): Hold a pointer to the font face which created it.
2691         (WebCore::CSSFontFaceSrcValue::svgFontFaceElement):
2692         (WebCore::CSSFontFaceSrcValue::setSVGFontFaceElement):
2693         * css/CSSFontSelector.cpp: Build 'SVGCSSFontFace' objects for local, in-document SVG fonts.
2694         (WebCore::CSSFontSelector::addFontFaceRule):
2695         * css/SVGCSSFontFace.cpp: Added. (Simplified implementation for SVG Fonts)
2696         (WebCore::SVGCSSFontFace::SVGCSSFontFace):
2697         (WebCore::SVGCSSFontFace::~SVGCSSFontFace):
2698         (WebCore::SVGCSSFontFace::isValid):
2699         (WebCore::SVGCSSFontFace::addSource):
2700         (WebCore::SVGCSSFontFace::getFontData):
2701         * css/SVGCSSFontFace.h: Added.
2702         * platform/graphics/cg/PathCG.cpp:
2703         (WebCore::Path::closeSubpath): Silence a CG warning when calling closeSubpath() on empty path.
2704         * platform/graphics/Font.cpp: Add some logic to call into SVG Font code when operating on SVG Fonts.
2705         (WebCore::Font::ascent): Pass font size to FontData::ascent() call
2706         (WebCore::Font::descent): Pass font size to FontData::descent() call
2707         (WebCore::Font::canUseGlyphCache): Always return true for SVG fonts here.
2708         (WebCore::Font::drawGlyphBuffer): Call drawGlyphsWithSVGFont (instead of drawGlyphs) if the primary font is a SVG font.
2709         * platform/graphics/Font.h: Add (SVG-only!) ability to store a RenderObject pointer, to the element which invoked the drawText() call.
2710         (WebCore::TextRun::TextRun):
2711         (WebCore::TextRun::referencingRenderObject):
2712         (WebCore::TextRun::setReferencingRenderObject):
2713         * platform/graphics/FontData.cpp:
2714         (WebCore::FontData::FontData):
2715         (WebCore::FontData::ascent):
2716         (WebCore::FontData::descent):
2717         * platform/graphics/FontData.h: Store a pointer to the SVGFontFaceElement, which created this FontData object - needed for drawGlyphsWithSVGFont().
2718         (WebCore::FontData::isSVGFont): Offer a way to determine wheter this is a FontData object, created by a SVGFontFaceElement.
2719         (WebCore::FontData::svgFontFace):
2720         * rendering/SVGInlineTextBox.cpp:
2721         (WebCore::SVGInlineTextBox::calculateGlyphWidth): Add assertion.
2722         * rendering/SVGRootInlineBox.cpp:
2723         (WebCore::svgTextRunForInlineTextBox): Always call 'setReferencingRenderObject(myRenderSVGText)' on the new TextRun
2724         * svg/SVGFont.cpp: Added.
2725         (WebCore::Font::drawGlyphsWithSVGFont): Outsourced implementation of SVG Fonts into it's own file.
2726         * svg/SVGFontElement.cpp: Added. (Note: this holds the GlyphHashMap which associates certain <glyph> objects with unicode values)
2727         (WebCore::SVGFontElement::SVGFontElement):
2728         (WebCore::SVGFontElement::~SVGFontElement):
2729         (WebCore::SVGFontElement::parseMappedAttribute):
2730         (WebCore::SVGFontElement::collectGlyphs):
2731         (WebCore::SVGFontElement::glyphIdentifierForGlyphCode):
2732         * svg/SVGFontElement.h: Added.
2733         (WebCore::GlyphHash::hash):
2734         (WebCore::GlyphHash::equal):
2735         (WebCore::GlyphHashTraits::deletedValue):
2736         (WebCore::SVGFontElement::rendererIsNeeded):
2737         (WebCore::SVGFontElement::contextElement):
2738         * svg/SVGFontElement.idl: Added.
2739         * svg/SVGFontFaceElement.cpp: Build SVG specific 'FontData' object
2740         (WebCore::SVGFontFaceElement::unitsPerEm):
2741         (WebCore::SVGFontFaceElement::fontFamily):
2742         (WebCore::SVGFontFaceElement::createFontData): Builds SVG specified 'FontData' object with the markup specified ascent/descent values etc..
2743         (WebCore::SVGFontFaceElement::rebuildFontFace): Construct CSSFontFaceSrc object (marked as 'isSVGFontFaceSrc') to satisfy CSSFontSelector::addFontFaceRule.
2744         (WebCore::SVGFontFaceElement::insertedIntoDocument): Rebuild font face.
2745         (WebCore::SVGFontFaceElement::glyphIdentifierForGlyphCode): Allows drawGlyphsWithSVGFont to access the glyph hash map living in the SVGFontElement.
2746         * svg/SVGFontFaceElement.h: Fixed code formatting issues & wrap in ENABLE(SVG_FONTS) blocks.
2747         * svg/SVGFontFaceElement.idl: Ditto.
2748         * svg/SVGFontFaceFormatElement.cpp: Ditto.
2749         * svg/SVGFontFaceFormatElement.h: Ditto.
2750         * svg/SVGFontFaceFormatElement.idl: Ditto.
2751         * svg/SVGFontFaceNameElement.cpp: Ditto.
2752         * svg/SVGFontFaceNameElement.h: Ditto.
2753         * svg/SVGFontFaceNameElement.idl: Ditto.
2754         * svg/SVGFontFaceSrcElement.cpp: Ditto.
2755         * svg/SVGFontFaceSrcElement.h: Ditto.
2756         * svg/SVGFontFaceSrcElement.idl: Ditto.
2757         * svg/SVGFontFaceUriElement.cpp: Ditto.
2758         * svg/SVGFontFaceUriElement.h: Ditto.
2759         * svg/SVGFontFaceUriElement.idl: Ditto.
2760         * svg/SVGDefinitionSrcElement.cpp: Ditto.
2761         * svg/SVGDefinitionSrcElement.h: Ditto.
2762         * svg/SVGDefinitionSrcElement.idl: Ditto.
2763         * svg/SVGGlyphElement.cpp: Added.
2764         (WebCore::SVGGlyphElement::SVGGlyphElement):
2765         (WebCore::SVGGlyphElement::parseMappedAttribute):
2766         (WebCore::SVGGlyphElement::childrenChanged):
2767         * svg/SVGGlyphElement.h: Added.
2768         (WebCore::SVGGlyphElement::rendererIsNeeded):
2769         (WebCore::SVGGlyphIdentifier::): Structure holding all data to represent a SVG glyph (origin, advance, orientation etc..)
2770         (WebCore::SVGGlyphIdentifier::SVGGlyphIdentifier):
2771         * svg/SVGGlyphElement.idl: Added.
2772         * svg/SVGMissingGlyphElement.cpp: Added. (stub implementation)
2773         (WebCore::SVGMissingGlyphElement::SVGMissingGlyphElement):
2774         (WebCore::SVGMissingGlyphElement::parseMappedAttribute):
2775         (WebCore::SVGMissingGlyphElement::childrenChanged):
2776         * svg/SVGMissingGlyphElement.h: Added.
2777         (WebCore::SVGMissingGlyphElement::rendererIsNeeded):
2778         * svg/SVGMissingGlyphElement.idl: Added.
2779         * svg/svgtags.in: Wrap all SVGFont* elements in ENABLE(SVG_FONTS) block - to assure --no-svg-fonts compilation works (which is the default for now!).
2780
2781 2007-12-27  Dan Bernstein  <mitz@apple.com>
2782
2783         Reviewed by Alexey Proskuryakov.
2784
2785         - fix http://bugs.webkit.org/show_bug.cgi?id=16628
2786           ASSERTION FAILED: m_resizeLayer (running layout tests)
2787
2788         * rendering/RenderLayer.cpp:
2789         (WebCore::RenderLayer::~RenderLayer): Avoid calling
2790         EventHandler::resizeLayerDestroyed() if the document is being destroyed.
2791
2792 2007-12-27  Dan Bernstein  <mitz@apple.com>
2793
2794         Reviewed by Oliver Hunt.
2795
2796         - fix http://bugs.webkit.org/show_bug.cgi?id=16603
2797           <rdar://problem/5664199> Crash when resizing text field
2798
2799         Test: fast/layers/resize-layer-deletion-crash.html
2800
2801         The event handler has only a weak reference to the layer that is
2802         currently in resize mode, so it is the layer's responsibility to let
2803         the event handler know if it has been destroyed while in that mode.
2804
2805         * page/EventHandler.cpp:
2806         (WebCore::EventHandler::resizeLayerDestroyed): Added. Resets
2807         m_resizeLayer to 0.
2808         * page/EventHandler.h:
2809         * rendering/RenderLayer.cpp:
2810         (WebCore::RenderLayer::~RenderLayer): Added a call to
2811         EventHandler::resizeLayerDestroyed() if the layer is in resize mode.
2812
2813 2007-12-27  Collin Jackson  <webkit@collinjackson.com>
2814
2815         Reviewed by Sam Weinig.
2816
2817         http://bugs.webkit.org/show_bug.cgi?id=16539
2818         <rdar://problem/5659269>
2819
2820         The same-origin check was missing in the implementation of 
2821         setTimeout, setInterval, addEventListener, and removeEventListener.
2822
2823         Suppose <http://www.badguy.com/> contains an iframe to 
2824         <http://www.goodguy.com/>. Now www.badguy.com can steal
2825         www.goodguy.com cookies by running this code:
2826
2827         setTimeout.call(frames[0], "alert(document.cookie)", 1000);
2828
2829         This patch changes the behavior so that setTimeout to does 
2830         nothing and returns an undefined value if the caller is not
2831         permitted to script the window whose setTimeout method is being
2832         called. The same applies to setInterval, addEventListener, and 
2833         removeEventListener.
2834
2835         Tests: http/tests/security/cross-frame-access-call.html
2836
2837         * bindings/js/kjs_window.cpp:
2838         (KJS::WindowProtoFuncSetTimeout::callAsFunction)
2839         (KJS::WindowProtoFuncSetInterval::callAsFunction)
2840         (KJS::WindowProtoFuncAddEventListener::callAsFunction)
2841         (KJS::WindowProtoFuncRemoveEventListener::callAsFunction)
2842
2843 2007-12-27  Dan Bernstein  <mitz@apple.com>
2844
2845         Reviewed by Dave Hyatt and Sam Weinig.
2846
2847         - fix <rdar://problem/5605937> Inspector: Disclosure triangle not drawn in node's properties panel until click
2848
2849         Test: fast/layers/add-layer-with-nested-stacking.html
2850         Test: fast/layers/remove-layer-with-nested-stacking.html
2851
2852         * rendering/RenderLayer.cpp:
2853         (WebCore::RenderLayer::addChild): If the new child is overflow-only
2854         but has children of its own, dirty the stacking context's z-order lists
2855         since the grandchildren might need to be in them.
2856         (WebCore::RenderLayer::removeChild): Similarly for the old child.
2857
2858 2007-12-27  Jan Michael Alonzo  <jmalonzo@unpluggable.com>
2859
2860         Reviewed by Alp Toker.
2861
2862         http://bugs.webkit.org/show_bug.cgi?id=16353
2863         [GTK] Check for deprecated API use (G_DISABLE_DEPRECATED etc.)
2864
2865         Added the flags mentioned in the bug only when doing 'debug'
2866         builds. -DGST_DISABLE_DEPRECATED only added when video is enabled.
2867
2868         * GNUmakefile.am:
2869         * WebCore.pro:
2870
2871 2007-12-27  Dan Bernstein  <mitz@apple.com>
2872
2873         Reviewed by Eric Seidel.
2874
2875         - fix http://bugs.webkit.org/show_bug.cgi?id=16490
2876           ASSERT in ~FrameView while viewing/reloading WICD test case
2877
2878         Test: fast/dynamic/paused-event-dispatch.html
2879
2880         * page/FrameView.cpp:
2881         (WebCore::FrameView::~FrameView):
2882         (WebCore::FrameView::layout): Changed to always pause event dispatch and
2883         always resume event dispatch, regardless of whether the post-layout
2884         task timer is active. However, if it is active, assert that event
2885         dispatch is still paused.
2886
2887 2007-12-27  Alexey Proskuryakov  <ap@webkit.org>
2888
2889         Reviewed by Maciej.
2890
2891         http://bugs.webkit.org/show_bug.cgi?id=14500
2892         need to be more generous about charset declaration with meta tag
2893         
2894         http://bugs.webkit.org/show_bug.cgi?id=12526
2895         <rdar://problem/4867183> Safari ignores encoding description "charset=Shift_JIS" in invalid html
2896
2897         <rdar://problem/4892428> Unlike other browsers, WebKit ignores <meta> charset definitions outside the head
2898
2899         <rdar://problem/5643774> REGRESSION: Text is garbled when clicking a link inside an Arabic website
2900
2901         Tests: fast/encoding/ahram-org-eg.html
2902                fast/encoding/bandai-co-jp-releases.html
2903                fast/encoding/floraexpress-ru.html
2904                fast/encoding/hanarei-blog32-fc2-com.html
2905                fast/encoding/yahoo-mail.html
2906
2907         * loader/TextResourceDecoder.cpp:
2908         (WebCore::TextResourceDecoder::checkForHeadCharset): Don't stop looking for <meta> until we've
2909         seen at least 512 bytes of input.
2910
2911 2007-12-26  Jan Michael Alonzo  <jmalonzo@unpluggable.com>
2912
2913         Reviewed by Alp Toker.
2914
2915         http://bugs.webkit.org/show_bug.cgi?id=16390
2916         Use autotools or GNU make as the build system for the GTK port
2917
2918         * GNUmakefile.am: Added.
2919
2920 2007-12-26  Alexey Proskuryakov  <ap@webkit.org>
2921
2922         Reviewed by Sam Weinig.
2923
2924         http://bugs.webkit.org/show_bug.cgi?id=16609
2925         Make manual-tests/xmlhttprequest-contenttype-empty.html test automatic
2926
2927         * manual-tests/xmlhttprequest-contenttype-empty.html: Removed (moved to LayoutTests/http).
2928
2929 2007-12-26  Mark Rowe  <mrowe@apple.com>
2930
2931         Windows build fix.
2932
2933         * platform/Threading.h:
2934
2935 2007-12-25  Rob Buis  <buis@kde.org>
2936
2937         Reviewed by Eric.
2938
2939         http://bugs.webkit.org/show_bug.cgi?id=15514
2940         <clipPath> with <use> not respected
2941         http://bugs.webkit.org/show_bug.cgi?id=16557
2942         SVG circle elements have been clipped away completely, instead of partially.
2943
2944         Add toClipPath to get clip path data for the clipping paths. Implement it for <use>, thereby allowing clip paths using use.
2945
2946         * svg/SVGClipPathElement.cpp:
2947         (WebCore::SVGClipPathElement::canvasResource):
2948         * svg/SVGStyledTransformableElement.h:
2949         (WebCore::SVGStyledTransformableElement::toClipPath):
2950         * svg/SVGUseElement.cpp:
2951         (WebCore::isDirectReference):
2952         (WebCore::SVGUseElement::toClipPath):
2953         * svg/SVGUseElement.h:
2954
2955 2007-12-25  Sam Weinig  <sam@webkit.org>
2956
2957         Reviewed by Eric Seidel.
2958
2959         Clean up the files relating to NodeLists.
2960
2961         * dom/ChildNodeList.cpp:
2962         (WebCore::ChildNodeList::ChildNodeList):
2963         (WebCore::ChildNodeList::length):
2964         (WebCore::ChildNodeList::item):
2965         (WebCore::ChildNodeList::nodeMatches):
2966         * dom/ChildNodeList.h:
2967         * dom/DynamicNodeList.cpp:
2968         (WebCore::DynamicNodeList::itemForwardsFromCurrent):
2969         (WebCore::DynamicNodeList::itemBackwardsFromCurrent):
2970         (WebCore::DynamicNodeList::itemWithName):
2971         * dom/DynamicNodeList.h:
2972         (WebCore::DynamicNodeList::needsNotifications):
2973         * dom/NameNodeList.cpp:
2974         (WebCore::NameNodeList::NameNodeList):
2975         (WebCore::NameNodeList::rootNodeAttributeChanged):
2976         (WebCore::NameNodeList::nodeMatches):
2977         * dom/NameNodeList.h:
2978         * dom/NodeList.h:
2979         * dom/SelectorNodeList.h:
2980
2981 2007-12-25  Sam Weinig  <sam@webkit.org>
2982
2983         Fix non-mac builds.
2984
2985         * WebCore.pro:
2986         * WebCore.vcproj/WebCore.vcproj:
2987         * WebCoreSources.bkl:
2988
2989 2007-12-25  Sam Weinig  <sam@webkit.org>
2990
2991         Rubber stamped by Eric Seidel.
2992
2993         Move TagNodeList into its own file.
2994
2995         * WebCore.xcodeproj/project.pbxproj:
2996         * dom/Node.cpp:
2997         * dom/TagNodeList.cpp: Copied from dom/Node.cpp.
2998         (WebCore::TagNodeList::TagNodeList):
2999         * dom/TagNodeList.h: Copied from dom/Node.cpp.
3000
3001 2007-12-25  Sam Weinig  <sam@webkit.org>
3002
3003         Reviewed by Eric Seidel.
3004
3005         Simplify the NodeList architecture.
3006         - Rename recursiveItem() to item(), since it is not recursive.
3007         - Make recursiveLength() iterative and rename to length().
3008         - Remove now unneeded overrides of item() and length() that used 
3009           to call the recursive variants.
3010
3011         * dom/ClassNodeList.cpp:
3012         * dom/ClassNodeList.h:
3013         * dom/DynamicNodeList.cpp:
3014         (WebCore::DynamicNodeList::length):
3015         (WebCore::DynamicNodeList::item):
3016         (WebCore::DynamicNodeList::rootNodeAttributeChanged): Move implementation 
3017         into the .cpp file since virtual methods can't be inlined.
3018         * dom/DynamicNodeList.h:
3019         * dom/NameNodeList.cpp:
3020         * dom/NameNodeList.h:
3021         * dom/Node.cpp:
3022
3023 2007-12-25  Alp Toker  <alp@atoker.com>
3024
3025         More complete GTK+/Qt/Wx/Win build fixes for breakage introduced in
3026         r28981.
3027
3028         * WebCore.pro:
3029         * WebCore.vcproj/WebCore.vcproj:
3030         * WebCoreSources.bkl:
3031
3032 2007-12-25  Alp Toker  <alp@atoker.com>
3033
3034         Win build fix for breakage introduced in r28981.
3035
3036         * WebCore.vcproj/WebCore.vcproj:
3037
3038 2007-12-25  Alp Toker  <alp@atoker.com>
3039
3040         Wx build fix for breakage introduced in r28981.
3041
3042         * WebCoreSources.bkl:
3043
3044 2007-12-25  Alp Toker  <alp@atoker.com>
3045
3046         GTK+/Qt build fix for breakage introduced in r28981.
3047
3048         * WebCore.pro:
3049
3050 2007-12-25  David Smith  <catfish.man@gmail.com> and Sam Weinig  <sam@webkit.org>
3051
3052         Reviewed by Oliver.
3053         
3054         - http://bugs.webkit.org/show_bug.cgi?id=16587
3055         Implement the most useful part of the W3C Selectors API.
3056
3057         * WebCore.xcodeproj/project.pbxproj:
3058         * css/CSSStyleSelector.h: Make Node a friend of CSSStyleSelector so it can use checkSelector()
3059         * dom/ChildNodeList.cpp:
3060         (WebCore::ChildNodeList::ChildNodeList): Change to being a DynamicNodeList
3061         * dom/ChildNodeList.h:
3062         * dom/ClassNodeList.cpp:
3063         (WebCore::ClassNodeList::ClassNodeList): Change to being a DynamicNodeList
3064         * dom/ClassNodeList.h:
3065         * dom/Document.idl: Add the new functions
3066         * dom/DynamicNodeList.cpp: Copied from WebCore/dom/NodeList.cpp.
3067         (WebCore::DynamicNodeList::DynamicNodeList): Rename NodeList to DynamicNodeList, to differentiate it from the new StaticNodeList
3068         (WebCore::DynamicNodeList::~DynamicNodeList):
3069         (WebCore::DynamicNodeList::recursiveLength):
3070         (WebCore::DynamicNodeList::itemForwardsFromCurrent):
3071         (WebCore::DynamicNodeList::itemBackwardsFromCurrent):
3072         (WebCore::DynamicNodeList::recursiveItem):
3073         (WebCore::DynamicNodeList::itemWithName):
3074         (WebCore::DynamicNodeList::rootNodeChildrenChanged):
3075         (WebCore::DynamicNodeList::Caches::Caches):
3076         (WebCore::DynamicNodeList::Caches::reset):
3077         * dom/DynamicNodeList.h: Copied from WebCore/dom/NodeList.h.
3078         (WebCore::DynamicNodeList::rootNodeAttributeChanged):
3079         * dom/Element.idl: Add the new functions
3080         * dom/NameNodeList.cpp: Change to being a DynamicNodeList
3081         (WebCore::NameNodeList::NameNodeList):
3082         * dom/NameNodeList.h:
3083         (WebCore::NameNodeList::rootNodeAttributeChanged):
3084         * dom/Node.cpp:
3085         (WebCore::TagNodeList::TagNodeList): Change to being a DynamicNodeList
3086         (WebCore::Node::registerDynamicNodeList):
3087         (WebCore::Node::unregisterDynamicNodeList):
3088         (WebCore::Node::getElementsByName):
3089         (WebCore::Node::getElementsByClassName):
3090         (WebCore::Node::querySelector): new
3091         (WebCore::Node::querySelectorAll): new
3092         * dom/Node.h:
3093         * dom/NodeList.cpp: Removed.
3094         * dom/NodeList.h: This is now an abstract superclass of DynamicNodeList and StaticNodeList
3095         (WebCore::NodeList::NodeList):
3096         (WebCore::NodeList::~NodeList):
3097         * dom/SelectorNodeList.cpp: Added.
3098         (WebCore::SelectorNodeList::SelectorNodeList): New StaticNodeList subclass that filters elements by CSS selector
3099         * dom/SelectorNodeList.h: Added.
3100         * dom/StaticNodeList.cpp: Added.
3101         (WebCore::StaticNodeList::length):
3102         (WebCore::StaticNodeList::item):
3103         (WebCore::StaticNodeList::itemWithName):
3104         * dom/StaticNodeList.h: Added.
3105         (WebCore::StaticNodeList::StaticNodeList):
3106         (WebCore::StaticNodeList::~StaticNodeList):
3107
3108 2007-12-25  Mark Rowe  <mrowe@apple.com>
3109
3110         Reviewed by Sam Weinig.
3111
3112         Implement a lock-free ThreadSafeShared for i386, x86_64, ppc and ppc64.
3113         http://bugs.webkit.org/show_bug.cgi?id=16596
3114
3115         This is a 1.7x as fast as the lock-based implementation on x86 for a single-threaded use
3116         of ThreadSafeShared but is closer to 280x as fast when there is heavy concurrent multi-threaded
3117         access to a single ThreadSafeShared object.
3118
3119         The atomic operations are based on those used by the Boost C++ library's shared_ptr implementation.
3120
3121         * platform/Threading.h:
3122         (WebCore::atomicIncrement):
3123         (WebCore::atomicDecrement):
3124         (WebCore::ThreadSafeShared::ThreadSafeShared):
3125         (WebCore::ThreadSafeShared::ref): Use lock-free operations if available.
3126         (WebCore::ThreadSafeShared::deref): Ditto.
3127         (WebCore::ThreadSafeShared::hasOneRef):
3128         (WebCore::ThreadSafeShared::refCount):
3129         (WebCore::ThreadSafeShared::isThreadSafe):
3130
3131 2007-12-24  Darin Adler  <darin@apple.com>
3132
3133         * platform/text/PlatformString.h: Removed now-incorrect comment.
3134         Added a comment about copy().
3135         * platform/text/StringImpl.h: Added a comment about copy().
3136
3137 2007-12-24  Darin Adler  <darin@apple.com>
3138
3139         Reviewed by Maciej.
3140
3141         - http://bugs.webkit.org/show_bug.cgi?id=16550
3142           make StringImpl immutable
3143
3144         I tried to keep the changes to a minimum. In some cases there is
3145         room for optimization -- I didn't try to add in the "single ref count"
3146         optimizations and there might be a tiny bit more string copying than
3147         we had before.
3148
3149         * WebCore.base.exp: Updated.
3150
3151         * dom/CharacterData.cpp:
3152         (WebCore::CharacterData::appendData): Changed to use String since
3153         StringImpl doesn't have mutating functions any more.
3154         (WebCore::CharacterData::insertData): Ditto.
3155         (WebCore::CharacterData::deleteData): Ditto.
3156         (WebCore::CharacterData::replaceData): Ditto.
3157         * dom/Text.cpp:
3158         (WebCore::Text::splitText): Changed to use substring instead of
3159         remove since StringImpl does't have mutating functions any more.
3160         * editing/CompositeEditCommand.cpp:
3161         (WebCore::CompositeEditCommand::deleteInsignificantText): Changed
3162         to use String instead of StringImpl so we can use remove.
3163
3164         * platform/text/PlatformString.h: Removed newUninitialized.
3165         Added append that takes a character pointer and length.
3166
3167         * platform/text/String.cpp:
3168         (WebCore::String::insert): Added an implementation that does not
3169         rely on an underlying StringImpl function.
3170         (WebCore::String::append): Ditto.
3171         (WebCore::String::truncate): Ditto.
3172         (WebCore::String::remove): Ditto.
3173         (WebCore::String::charactersWithNullTermination): Added an
3174         implementation that uses the new StringImpl null termination feature,
3175         which does not require modifying a string.
3176
3177         * platform/text/StringImpl.cpp:
3178         (WebCore::isSpace): Fix comment.
3179         (WebCore::StringImpl::StringImpl): Added a new constructor that makes
3180         a string with a trailing null character.
3181         (WebCore::StringImpl::substring): Marked const.
3182         (WebCore::StringImpl::replace): Marked const; had to add quite a few
3183         const_cast. Also rewrote one of these to work without modifying the
3184         existing string.
3185
3186         * platform/text/StringImpl.h: Fixed a mistake where the empty string had
3187         m_hasTerminatingNullCharacter uninitialized. Added a type and constructor
3188         for creating strings that have a trailing null character. Added a
3189         hasTerminatingNullCharacter function. Removed newUninitialized,
3190         charactersWithNullTermination, append, insert, truncate, and remove.
3191         Marked lots of other functions const.
3192
3193         * platform/text/TextCodecLatin1.cpp:
3194         (WebCore::TextCodecLatin1::decode): Rewrote to use a Vector instead of
3195         newUninitialized.
3196         * platform/text/TextCodecUTF16.cpp:
3197         (WebCore::TextCodecUTF16::decode): Ditto.
3198         * platform/text/TextCodecUserDefined.cpp:
3199         (WebCore::TextCodecUserDefined::decode): Ditto.
3200
3201         * rendering/RenderStyle.cpp:
3202         (WebCore::RenderStyle::setContent): Changed to use String since
3203         StringImpl doesn't have mutating functions any more.
3204
3205 2007-12-24  Alexey Proskuryakov  <ap@webkit.org>
3206
3207         Reviewed by Oliver.
3208
3209         Fix fast/events/arrow-keys-on-body.html, failing on Windows.
3210
3211         * platform/win/KeyEventWin.cpp:
3212         (WebCore::isKeypadEvent):
3213         (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):
3214         Use HIWORD() macro instead of shifting the value explicitly (no change in behavior).
3215
3216 2007-12-23  Alexey Proskuryakov  <ap@webkit.org>
3217
3218         Fix Debug and Release QTMovieWin bulds.
3219
3220         * WebCore.vcproj/QTMovieWin.vcproj:
3221         * WebCore.vcproj/debug.vsprops:
3222         * WebCore.vcproj/debug_internal.vsprops:
3223         * WebCore.vcproj/release.vsprops:
3224         Use LibraryConfigSuffix instead of WebKitConfigSuffix for pthreadVC2.
3225         Build release import lib into \lib, not \bin.
3226
3227 2007-12-23  Alp Toker  <alp@atoker.com>
3228
3229         Reviewed by Holger Freyther.
3230
3231         http://bugs.webkit.org/show_bug.cgi?id=15382
3232         [CAIRO] Canvas pattern support
3233
3234         http://bugs.webkit.org/show_bug.cgi?id=16577
3235         Merge Cairo enhancements from Apollo project
3236
3237         Add support for canvas patterns.
3238
3239         Make Image::nativeImageForCurrentFrame() public.
3240
3241         Fix some typos along the way.
3242
3243         The globalAlpha canvas fixes are not included in this patch as
3244         they're slightly more intrusive and may conflict conceptually with
3245         GraphicsContext::setAlpha().
3246
3247         * html/CanvasPattern.cpp:
3248         (WebCore::CanvasPattern::CanvasPattern):
3249         (WebCore::CanvasPattern::~CanvasPattern):
3250         (WebCore::CanvasPattern::createPattern):
3251         * html/CanvasPattern.h:
3252         (WebCore::CanvasPattern::platformImage):
3253         * html/CanvasRenderingContext2D.cpp:
3254         (WebCore::CanvasRenderingContext2D::setShadow):
3255         (WebCore::CanvasRenderingContext2D::applyShadow):
3256         (WebCore::CanvasRenderingContext2D::drawImage):
3257         (WebCore::CanvasRenderingContext2D::createPattern):
3258         (WebCore::CanvasRenderingContext2D::applyStrokePattern):
3259         (WebCore::CanvasRenderingContext2D::applyFillPattern):
3260         * platform/graphics/Image.h:
3261         (WebCore::Image::nativeImageForCurrentFrame):
3262
3263 2007-12-23  Kevin Ollivier  <kevino@theolliviers.com>
3264
3265         Reviewed by Eric Seidel.
3266
3267         Remove getWxBitmap as we have nativeImageForCurrentFrame now,
3268         and don't draw a border in fillRect.
3269
3270         * platform/graphics/BitmapImage.h:
3271         * platform/graphics/wx/GraphicsContextWx.cpp:
3272         (WebCore::GraphicsContext::fillRect):
3273         * platform/graphics/wx/ImageWx.cpp:
3274
3275 2007-12-23  Alp Toker  <alp@atoker.com>
3276
3277         Reviewed by Holger Freyther.
3278
3279         http://bugs.webkit.org/show_bug.cgi?id=16577
3280         Merge Cairo enhancements from Apollo project
3281
3282         This patch is based on initial merging work by Brent Fulgham. Adobe's
3283         code has been modified in a few places to better suit the existing
3284         coding style.
3285
3286         Implement more clipping and drawing functions.
3287
3288         Save and restore the fill rule manually when clipping.
3289
3290         Avoid image surface creation when the image buffer has height zero.
3291
3292         * platform/graphics/cairo/GraphicsContextCairo.cpp:
3293         (WebCore::GraphicsContext::clip):
3294         (WebCore::GraphicsContext::addInnerRoundedRectClip):
3295         (WebCore::GraphicsContext::addPath):
3296         (WebCore::GraphicsContext::clipOut):
3297         (WebCore::GraphicsContext::clipOutEllipseInRect):
3298         (WebCore::GraphicsContext::fillRoundedRect):
3299         * platform/graphics/cairo/ImageSourceCairo.cpp:
3300         (WebCore::ImageSource::createFrameAtIndex):
3301
3302 2007-12-23  Nikolas Zimmermann  <zimmermann@kde.org>
3303
3304         Reviewed by Mark.
3305
3306         Fix wrong placed ifdef - wrapping SVGDefsElement, instead of SVGDefinitionSrcElement in SVG_FONTS block.
3307
3308         * bindings/objc/DOM.mm:
3309         (WebCore::createElementClassMap):
3310
3311 2007-12-22  Alp Toker  <alp@atoker.com>
3312
3313         GTK+ build fix
3314
3315         GTK_TARGET_OTHER_APP is not available in older GTK+ versions. Pass
3316         empty target flags for now.
3317
3318         Check GTK+, not GLib versions, since they are different.
3319
3320         * platform/gtk/PasteboardGtk.cpp:
3321         (WebCore::Pasteboard::documentFragment):
3322
3323 2007-12-22  Luca Bruno  <lethalman88@gmail.com>
3324
3325         Reviewed by Alp Toker.
3326
3327         http://bugs.webkit.org/show_bug.cgi?id=16311
3328         [Gtk] Copy rich text to clipboard as text/plain and text/html.
3329
3330         Hook into the WebView to get the correct clipboard object on the
3331         appropriate display. This is necessary because GTK+ does not have
3332         global clipboards.
3333
3334         * WebCore.pro:
3335         * platform/Pasteboard.h:
3336         (WebCore::Pasteboard::setHelper): added for GTK
3337         (WebCore::Pasteboard::m_helper): private added for GTK
3338         * platform/gtk/PasteboardGtk.cpp:
3339         (WebCore::PasteboardSelectionData): added to support GTK selection data callback
3340         (WebCore::clipboard_get_contents_cb): added
3341         (WebCore::clipboard_clear_contents_cb): added
3342         (WebCore::Pasteboard::~Pasteboard):
3343         (WebCore::Pasteboard::setHelper):
3344         (WebCore::Pasteboard::writeSelection): copy rich text
3345         (WebCore::Pasteboard::documentFragment): 
3346         (WebCore::Pasteboard::plainText): 
3347         * platform/gtk/PasteboardHelper.h: Added.
3348
3349 2007-12-22  Nikolas Zimmermann  <zimmermann@kde.org>
3350
3351         Reviewed by Oliver.
3352
3353         Fixes: http://bugs.webkit.org/show_bug.cgi?id=15966 (Crash in SVGRootInlineBox::walkTextChunks() on mouse hover)
3354
3355         Add new isSVGRootInlineBox() function to InlineBox to be able to differentiate between RootInlineBox/SVGRootInlineBox.
3356         SVG assumed it's root inline box (for <text> elements) is always of type SVGRootInlineBox, which is not the case
3357         for HTML text in <foreignObject>. Text selection doesn't work so far as line box offsets are wrong - which is visible
3358         in Web Inspector.
3359
3360         * rendering/InlineBox.h:
3361         (WebCore::InlineBox::isSVGRootInlineBox):
3362         * rendering/SVGInlineTextBox.cpp:
3363         (WebCore::SVGInlineTextBox::svgRootInlineBox):
3364         (WebCore::SVGInlineTextBox::closestCharacterToPosition):
3365         (WebCore::SVGInlineTextBox::selectionRect):
3366         * rendering/SVGRenderTreeAsText.cpp:
3367         (WebCore::writeSVGInlineTextBox):
3368         * rendering/SVGRootInlineBox.h:
3369         (WebCore::SVGRootInlineBox::isSVGRootInlineBox):
3370
3371 2007-12-22  Alp Toker  <alp@atoker.com>
3372
3373         LOW_BANDWIDTH_DISPLAY build fix
3374
3375         Track recent KURL DeprecatedString changes.
3376
3377         * loader/FrameLoader.cpp:
3378         (WebCore::FrameLoader::switchOutLowBandwidthDisplayIfReady):
3379
3380 2007-12-22  Dan Bernstein  <mitz@apple.com>
3381
3382         - Windows build fix
3383
3384         * WebCore.vcproj/WebCore.vcproj:
3385
3386 2007-12-22  Xan Lopez  <xan@gnome.org>
3387
3388         Reviewed by Alp Toker.
3389
3390         Add missing return 0 to fix a compile warning.
3391
3392         * page/gtk/FrameGtk.cpp:
3393         (WebCore::Frame::createScriptInstanceForWidget):
3394
3395 2007-12-21  Antti Koivisto  <antti@apple.com>
3396
3397         Reviewed by Darin, Adam and Steve.
3398
3399         Add media playback support for Windows.
3400         
3401         The implementation uses low level QuickTime API. DLL is
3402         needed to work around CF use in both WebKit and QuickTime.
3403         
3404         This makes Windows build depend on the QuickTime SDK 
3405         
3406         http://developer.apple.com/quicktime/download/
3407         
3408         but not QuickTime itself.
3409         
3410         QTMovieWinTimer contains some copy code from SharedTimerWin. It
3411         is used in the QuickTime access DLL which can't use WebCore
3412         SharedTimer due to dependency problems.
3413
3414         * WebCore.vcproj/QTMovieWin.vcproj: Added.
3415         * WebCore.vcproj/WebCore.vcproj:
3416         * WebCore.vcproj/build-generated-files.sh:
3417         * html/HTMLMediaElement.cpp:
3418         (WebCore::HTMLMediaElement::setSrc):
3419         * platform/graphics/MediaPlayer.cpp:
3420         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.cpp: Added.
3421         (WebCore::MediaPlayerPrivate::MediaPlayerPrivate):
3422         (WebCore::MediaPlayerPrivate::~MediaPlayerPrivate):
3423         (WebCore::MediaPlayerPrivate::load):
3424         (WebCore::MediaPlayerPrivate::play):
3425         (WebCore::MediaPlayerPrivate::pause):
3426         (WebCore::MediaPlayerPrivate::duration):
3427         (WebCore::MediaPlayerPrivate::currentTime):
3428         (WebCore::MediaPlayerPrivate::seek):
3429         (WebCore::MediaPlayerPrivate::doSeek):
3430         (WebCore::MediaPlayerPrivate::cancelSeek):
3431         (WebCore::MediaPlayerPrivate::seekTimerFired):
3432         (WebCore::MediaPlayerPrivate::setEndTime):
3433         (WebCore::MediaPlayerPrivate::startEndPointTimerIfNeeded):
3434         (WebCore::MediaPlayerPrivate::endPointTimerFired):
3435         (WebCore::MediaPlayerPrivate::paused):
3436         (WebCore::MediaPlayerPrivate::seeking):
3437         (WebCore::MediaPlayerPrivate::naturalSize):
3438         (WebCore::MediaPlayerPrivate::hasVideo):
3439         (WebCore::MediaPlayerPrivate::setVolume):
3440         (WebCore::MediaPlayerPrivate::setMuted):
3441         (WebCore::MediaPlayerPrivate::setRate):
3442         (WebCore::MediaPlayerPrivate::dataRate):
3443         (WebCore::MediaPlayerPrivate::maxTimeBuffered):
3444         (WebCore::MediaPlayerPrivate::maxTimeSeekable):
3445         (WebCore::MediaPlayerPrivate::maxTimeLoaded):
3446         (WebCore::MediaPlayerPrivate::bytesLoaded):
3447         (WebCore::MediaPlayerPrivate::totalBytesKnown):
3448         (WebCore::MediaPlayerPrivate::totalBytes):
3449         (WebCore::MediaPlayerPrivate::cancelLoad):
3450         (WebCore::MediaPlayerPrivate::updateStates):
3451         (WebCore::MediaPlayerPrivate::didEnd):
3452         (WebCore::MediaPlayerPrivate::setRect):
3453         (WebCore::MediaPlayerPrivate::setVisible):
3454         (WebCore::MediaPlayerPrivate::paint):
3455         (WebCore::MediaPlayerPrivate::getSupportedTypes):
3456         (WebCore::MediaPlayerPrivate::movieEnded):
3457         (WebCore::MediaPlayerPrivate::movieLoadStateChanged):
3458         (WebCore::MediaPlayerPrivate::movieTimeChanged):
3459         (WebCore::MediaPlayerPrivate::movieNewImageAvailable):
3460         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.h: Added.
3461         (WebCore::MediaPlayerPrivate::networkState):
3462         (WebCore::MediaPlayerPrivate::readyState):
3463         * platform/graphics/win/QTMovieWin.cpp: Added.
3464         (updateTaskTimer):
3465         (QTMovieWinPrivate::QTMovieWinPrivate):
3466         (QTMovieWinPrivate::~QTMovieWinPrivate):
3467         (taskTimerFired):
3468         (QTMovieWinPrivate::startTask):
3469         (QTMovieWinPrivate::endTask):
3470         (QTMovieWinPrivate::task):
3471         (QTMovieWinPrivate::registerDrawingCallback):
3472         (QTMovieWinPrivate::drawingComplete):
3473         (QTMovieWinPrivate::createGWorld):
3474         (QTMovieWinPrivate::setSize):
3475         (QTMovieWinPrivate::deleteGWorld):
3476         (QTMovieWin::QTMovieWin):
3477         (QTMovieWin::~QTMovieWin):
3478         (QTMovieWin::play):
3479         (QTMovieWin::pause):
3480         (QTMovieWin::rate):
3481         (QTMovieWin::setRate):
3482         (QTMovieWin::duration):
3483         (QTMovieWin::currentTime):
3484         (QTMovieWin::setCurrentTime):
3485         (QTMovieWin::setVolume):
3486         (QTMovieWin::setMuted):
3487         (QTMovieWin::dataSize):
3488         (QTMovieWin::maxTimeLoaded):
3489         (QTMovieWin::loadState):
3490         (QTMovieWin::getNaturalSize):
3491         (QTMovieWin::setSize):
3492         (QTMovieWin::setVisible):
3493         (QTMovieWin::paint):
3494         (QTMovieWin::load):
3495         (movieDrawingCompleteProc):
3496         (initializeSupportedTypes):
3497         (QTMovieWin::countSupportedTypes):
3498         (QTMovieWin::getSupportedType):
3499         (QTMovieWin::initializeQuickTime):
3500         (DllMain):
3501         * platform/graphics/win/QTMovieWin.h: Added.
3502         * platform/graphics/win/QTMovieWinTimer.cpp: Added.
3503         (TimerWindowWndProc):
3504         (initializeOffScreenTimerWindow):
3505         (setSharedTimerFiredFunction):
3506         (timerFired):
3507         (setSharedTimerFireDelay):
3508         (stopSharedTimer):
3509         (setSharedTimerInstanceHandle):
3510         (systemTime):
3511         * platform/graphics/win/QTMovieWinTimer.h: Added.
3512         * rendering/RenderMedia.cpp:
3513         (WebCore::MediaControlPlayButtonElement::update):
3514
3515 2007-12-21  Brent Fulgham  <bfulgham@gmail.com>
3516
3517         Reviewed by Alp Toker.
3518
3519         http://bugs.webkit.org/show_bug.cgi?id=16558
3520         Cairo WebCore Rendering Fails on arc drawing
3521
3522         Fix for bug reported (and patched) by Apollo team in which
3523         arcs were draw in reverse (resulting in inverted images).
3524         Review of the source found that the 'clockwise' term was
3525         actually meant to mean 'anticlockwise' so the IDL and
3526         supporting classes have been changed to match this. 
3527
3528         * html/CanvasRenderingContext2D.cpp:
3529         (WebCore::CanvasRenderingContext2D::arc):
3530         * html/CanvasRenderingContext2D.idl:
3531         * platform/graphics/cairo/PathCairo.cpp:
3532         (WebCore::Path::addArc):
3533         (WebCore::Path::addEllipse):
3534         * platform/graphics/Path.h:
3535
3536 2007-12-21  Alexey Proskuryakov  <ap@webkit.org>
3537
3538         Reviewed by Oliver.
3539
3540         <rdar://problem/5629995> Incorrect display of Danish characters on web site.
3541
3542         Test: http/tests/xmlhttprequest/response-encoding.html
3543
3544         * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::didReceiveData):
3545         Default to UTF-8 for HTML, too. It's unfortunate that we have to use different
3546         rules for main content and XHR responses, but this matches both IE and Firefox.
3547
3548 2007-12-20  Jon Honeycutt  <jhoneycutt@apple.com>
3549
3550         Reviewed by Kevin Decker.
3551
3552         <rdar://problem/5655797> REGRESSION(304-306A10) Safari does not find
3553         shockwave plugin on freshly installed OS
3554
3555         Look for Director plugin in its native directory.
3556
3557         * plugins/win/PluginDatabaseWin.cpp:
3558         (WebCore::PluginDatabaseWin::getPluginsInPaths): The Director plugin
3559         doesn't start with "np," so special case its filename.
3560         (WebCore::addMacromediaPluginPaths): Add Flash and "Shockwave 10"
3561         directories to the plugin paths.
3562         (WebCore::PluginDatabaseWin::defaultPluginPaths):
3563
3564 2007-12-20  Peter Kasting  <zerodpx@gmail.com>
3565
3566         Reviewed by Alp Toker.
3567
3568         http://bugs.webkit.org/show_bug.cgi?id=16508
3569         Fix regression in GIFImageDecoder.cpp: "Haeberli hack" led to wrongly
3570         decoded transparent areas.
3571
3572         * pl