* Coding-Style fixes.
[WebKit-https.git] / WebCore / ChangeLog
1 2008-01-18  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2
3         Reviewed by Simon.
4
5         * Coding-Style fixes.
6
7         * platform/qt/PlatformScrollBarQt.cpp:
8         (WebCore::PlatformScrollbar::PlatformScrollbar):
9
10 2008-01-18  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
11
12         Reviewed by Simon.
13
14         * Coding-Style fix
15
16         * platform/graphics/qt/ImageDecoderQt.cpp:
17         (WebCore::ImageDecoderQt::ReadContext::ReadContext):
18
19 2008-01-17  Geoffrey Garen  <ggaren@apple.com>
20
21         Reviewed by Darin Adler.
22
23         Fixed: lots of WebCore leaks reported when quitting Safari
24         
25         If we're quitting with a GC still scheduled, do the GC before quitting.
26         That way, WebCore's leak counters won't count objects that were
27         scheduled for GC.
28
29         * bindings/js/GCController.cpp:
30         (WebCore::GCController::~GCController):
31         (WebCore::GCController::garbageCollectNow):
32         * bindings/js/GCController.h:
33
34 2008-01-17  Alp Toker  <alp@atoker.com>
35
36         Reviewed by Oliver Hunt.
37
38         gdk_screen_get_font_options() returns NULL if no default options are
39         set so we always have to NULL check to avoid crashes later on since
40         Cairo doesn't accept NULL font options.
41
42         * platform/graphics/gtk/FontPlatformDataGtk.cpp:
43         (WebCore::FontPlatformData::FontPlatformData):
44
45 2008-01-17  Antti Koivisto  <antti@apple.com>
46
47         Reviewed by Adele.
48
49         Windows fix for <rdar://problem/5605682>
50         Disallow streaming protocols for media elements
51         and <rdar://problem/5668711>
52         Limit the container and codec types that the <video> tag supports
53         
54         - Disable unsupported QuickTime tracks types. 
55         - Disallow streaming protocols (for now).
56
57         * WebCore.vcproj/WebCore.vcproj:
58         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.cpp:
59         (WebCore::MediaPlayerPrivate::updateStates):
60         * platform/graphics/win/QTMovieWin.cpp:
61         (QTMovieWin::load):
62         (QTMovieWin::disableUnsupportedTracks):
63         * platform/graphics/win/QTMovieWin.h:
64
65 2008-01-17  Oliver Hunt  <oliver@apple.com>
66
67         Support smart copy and paste during drag and drop
68         
69         Reviewed by Alice
70         
71         In order for the drag and drop tests in Windows DRT to pass
72         we need to support smart cut and paste operations during
73         drag and drop on windows.
74         
75         There is no layout test as drag and drop is still unsupported
76         on windows.  Once supported smart drag/drop is tested by existing
77         tests
78
79         * platform/win/ClipboardUtilitiesWin.cpp:
80         (WebCore::smartPasteFormat):
81         * platform/win/ClipboardUtilitiesWin.h:
82         * platform/win/ClipboardWin.cpp:
83         (WebCore::ClipboardWin::writeRange):
84         * platform/win/DragDataWin.cpp:
85
86 2008-01-17  Oliver Hunt  <oliver@apple.com>
87
88         Reviewed by Anders.
89
90         <rdar://problem/5692940> Crash when attempting to get text properties in
91         SVG with no renderer
92
93         We use the element renderer to calculate the text element bounds,
94         however there was no check against the possibility of the text dimension
95         properties being requested on a element with no renderer (eg. unattached, 
96         display: none).
97
98         Test: svg/text/text-property-with-display-none.html
99
100         * svg/SVGTextContentElement.cpp:
101         (WebCore::rootInlineBoxForTextContentElement):
102
103 2008-01-17  Anders Carlsson  <andersca@apple.com>
104
105         Reviewed by Oliver.
106
107         <rdar://problem/5636742>
108         CrashTracer: [USER] 1302 crashes in Safari at com.apple.WebCore: WTF::Vector<char, 0ul>::reserveCapacity + 78
109         
110         When loading full-frame plug-ins, disable buffering data for the main resource loader. Otherwise, this can cause us
111         to crash when loading large files such as movies in the browser. We already do this for embedded plug-ins.
112         
113         * WebCore.base.exp:
114         * loader/DocumentLoader.h:
115         (WebCore::DocumentLoader::mainResourceLoader):
116         New accessor method.
117         
118         * loader/PluginDocument.cpp:
119         (WebCore::PluginTokenizer::writeRawData):
120         Disable buffering for the main resource loader.
121         
122         * loader/ResourceLoader.cpp:
123         (WebCore::ResourceLoader::setShouldBufferData):
124         * loader/ResourceLoader.h:
125         Have this free the buffer when disabling buffering.
126
127 2008-01-17  Adam Roben  <aroben@apple.com>
128
129         More Qt/GTK+ build fixing.
130
131         * platform/gtk/ScrollViewGtk.cpp:
132         * platform/qt/ScrollViewQt.cpp:
133
134 2008-01-17  Alexey Proskuryakov  <ap@webkit.org>
135
136         Reviewed by Darin.
137
138         http://bugs.webkit.org/show_bug.cgi?id=16902
139         <rdar://problem/5692566> fast/encoding/mailto-always-utf-8.html fails when run after
140         fast/dom/Window/window-property-shadowing.html
141
142         Test: fast/dom/Window/window-property-shadowing_.html
143
144         * loader/FrameLoader.cpp: (WebCore::FrameLoader::clear): Clear the frame name, too.
145
146 2008-01-17  Adam Roben  <aroben@apple.com>
147
148         Qt/GTK+ build fix.
149
150         * platform/gtk/ScrollViewGtk.cpp:
151         (WebCore::ScrollView::ScrollViewPrivate::isActive):
152         * platform/qt/ScrollViewQt.cpp:
153         (WebCore::ScrollView::ScrollViewPrivate::isActive):
154
155 2008-01-16  Adam Roben  <aroben@apple.com>
156
157         Update scroll bars/form controls when FocusController::isActive changes
158
159         Part of <rdar://5006915> Inactive look for Aqua controls
160
161         Reviewed by Darin.
162
163         All tests pass.
164
165         * page/FocusController.cpp:
166         (WebCore::FocusController::setActive): Update control tints when the
167         active state changes.
168         * page/FrameView.cpp:
169         (WebCore::FrameView::updateControlTints): On Windows, we have to ask
170         ScrollView to paint so that the outermost scroll bars will paint. On
171         Mac, the outermost scroll bars are taken care of by NSScroller.
172         * platform/PopupMenu.h: Updated for ScrollBarClient changes.
173         * platform/ScrollBar.h: Added a new ScrollBarClient method.
174         * platform/win/PlatformScrollBarSafari.cpp:
175         (WebCore::PlatformScrollbar::paint): Invalidate when updating control
176         tints so that we can paint with the new tint later.
177         (WebCore::PlatformScrollbar::paintButton): Pass the active state down
178         to SafariTheme.
179         (WebCore::PlatformScrollbar::paintTrack): Ditto.
180         (WebCore::PlatformScrollbar::paintThumb): Ditto.
181         * platform/win/ScrollViewWin.cpp:
182         (WebCore::ScrollView::ScrollViewPrivate::isActive): Added.
183         (WebCore::ScrollView::paint): Pass paint calls on down if we're
184         updating control tints so the scroll bars can invalidate.
185         * rendering/RenderLayer.cpp:
186         (WebCore::RenderLayer::isActive): Added.
187         * rendering/RenderLayer.h:
188         * rendering/RenderListBox.cpp:
189         (WebCore::RenderListBox::isActive): Added.
190         * rendering/RenderListBox.h:
191         * rendering/RenderTheme.cpp:
192         (WebCore::RenderTheme::isActive): Added.
193         * rendering/RenderTheme.h:
194         * rendering/RenderThemeSafari.cpp:
195         (WebCore::RenderThemeSafari::determineState): Pass the active state
196         down to SafariTheme.
197
198 2008-01-16  Adam Roben  <aroben@apple.com>
199
200         Move focused/active state from Frame to SelectionController/FocusController
201
202         This is the first part of <rdar://5006915> Inactive look for Aqua
203         controls.
204
205         The following methods were moved/renamed:
206             - Frame::setIsActive -> FocusController::setActive
207             - Frame::isActive -> SelectionController::isActiveAndFocused
208             - Frame::setWindowHasFocus -> SelectionController::setFocused
209
210         Active state is now correctly a Page-level concept.
211
212         The Mac parts of this patch were written by Darin.
213
214         Reviewed by Darin.
215
216         All tests pass.
217
218         * WebCore.base.exp: Updated for method renames.
219         * css/CSSStyleSelector.cpp:
220         (WebCore::CSSStyleSelector::checkOneSelector): Ditto.
221         * editing/SelectionController.cpp:
222         (WebCore::SelectionController::SelectionController): Initialize new
223         member.
224         (WebCore::SelectionController::focusedOrActiveStateChanged): New
225         private method. Most of this code came from Frame::setIsActive.
226         (WebCore::SelectionController::pageActivationChanged): Added.
227         (WebCore::SelectionController::setFocused): Added. Replaces
228         Frame::setWindowHasFocus.
229         (WebCore::SelectionController::isFocusedAndActive): Added. Replaces
230         Frame::isActive.
231         * editing/SelectionController.h:
232         * page/FocusController.cpp:
233         (WebCore::FocusController::FocusController): Initialize new member.
234         (WebCore::FocusController::setFocusedFrame): Changed to just call
235         SelectionController::setFocused, since active state has doesn't change
236         when the focused frame changes.
237         (WebCore::FocusController::setActive): Added. Replaces
238         Frame::setIsActive.
239         * page/FocusController.h:
240         (WebCore::FocusController::isActive): Added.
241         * page/Frame.cpp:
242         (WebCore::Frame::setDocument): Updated for method renames.
243         (WebCore::Frame::setFocusedNodeIfNeeded): Ditto.
244         (WebCore::Frame::updateSecureKeyboardEntryIfActive): Ditto.
245         (WebCore::FramePrivate::FramePrivate): Removed initialization of
246         removed members.
247         * page/Frame.h:
248         * page/FramePrivate.h:
249         * page/mac/WebCoreFrameBridge.h: Removed -selectionColor.
250         * page/mac/WebCoreFrameBridge.mm: Ditto.
251         * rendering/RenderListBox.cpp:
252         (WebCore::RenderListBox::paintItemForeground): Updated for method
253         renames.
254         (WebCore::RenderListBox::paintItemBackground): Ditto.
255         * rendering/RenderObject.cpp:
256         (WebCore::RenderObject::selectionBackgroundColor): Ditto.
257         (WebCore::RenderObject::selectionForegroundColor): Ditto.
258         * rendering/RenderTextControl.cpp:
259         (WebCore::RenderTextControl::capsLockStateMayHaveChanged): Ditto.
260         * rendering/RenderTheme.cpp:
261         (WebCore::RenderTheme::isFocused): Ditto.
262
263 2008-01-17  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
264
265         Reviewed by Simon.
266
267         * Make the nice 'safari' feature work on our port. When viewing a single image, clicking
268         on the image will zoom it.
269         * It seems like our platform can only determine the size of the image once it is completely
270         loaded. Call m_doc->imageChanged on the last chunk of data as well.
271
272         * loader/ImageDocument.cpp:
273         (WebCore::ImageTokenizer::finish):
274
275 2008-01-17  Simon Hausmann  <hausmann@webkit.org>
276
277         Reviewed by Lars.
278
279         Set the library version of QtWebKit to the Qt version.
280
281         * WebCore.pro:
282
283 2008-01-17  Simon Hausmann  <hausmann@webkit.org>
284
285         Reviewed by Holger.
286
287         Re-enable gzip compression as accepted encoding, now that the bug is fixed in Qt 4.4's network module.
288
289         * platform/network/qt/QNetworkReplyHandler.cpp:
290         (WebCore::QNetworkReplyHandler::QNetworkReplyHandler):
291
292 2008-01-17  Simon Hausmann  <hausmann@webkit.org>
293
294         Another Windows build fix, setCookies accidentially had a const
295         Document pointer.
296
297         * platform/network/win/CookieJarWin.cpp:
298
299 2008-01-17  Simon Hausmann  <hausmann@webkit.org>
300
301         MSVC Windows build fix. Forward declaring Document in CookieJar.h
302         seems not enough for MSVC.
303
304         * platform/network/win/CookieJarWin.cpp:
305
306 2008-01-17  Simon Hausmann  <hausmann@webkit.org>
307
308         Reviewed by Maciej, Lars, Holger.
309
310         http://bugs.webkit.org/show_bug.cgi?id=16589
311
312         Add a document parameter to WebCore::cookies, setCookies and cookiesEnabled.
313
314         * WebCore.pro:
315         * bindings/js/kjs_navigator.cpp:
316         (KJS::Navigator::getValueProperty):
317         * dom/Document.cpp:
318         (WebCore::Document::cookie):
319         * platform/CookieJar.h:
320         * platform/gtk/CookieJarGtk.cpp:
321         (WebCore::setCookies):
322         (WebCore::cookies):
323         * platform/mac/CookieJar.mm:
324         * platform/network/win/CookieJarWin.cpp:
325         * platform/qt/CookieJarQt.cpp:
326         (WebCore::setCookies):
327         (WebCore::cookies):
328         (WebCore::cookiesEnabled):
329         * platform/wx/TemporaryLinkStubs.cpp:
330
331 2008-01-17  Simon Hausmann  <hausmann@webkit.org>
332
333         Reviewed by Holger.
334
335         Windows build fix. (use localtime_r again instead of _s)
336
337         * loader/FTPDirectoryDocument.cpp:
338         (WebCore::processFileDateString):
339
340 2008-01-17  Frans Englich  <fenglich@trolltech.com>
341
342         Reviewed by Simon Hausmann <hausmann@webkit.org>.
343
344         Fix linking on MinGW and at least one MSVC platform by having gmtimeQt in the correct namespace.
345
346         * loader/FTPDirectoryDocument.cpp:
347
348 2008-01-17  Simon Hausmann  <hausmann@webkit.org>
349
350         Reviewed by Holger.
351
352         Don't link QtWebKit against libQtXml when building against Qt 4.4.
353
354         This is not necessary anymore since QXmlStream has been moved into QtCore.
355
356         * WebCore.pro:
357
358 2008-01-17  HÃ¥vard Wall  <hwall@trolltech.com>
359
360         Reviewed by Simon Hausmann <hausmann@webkit.org>.
361
362         Fix compilation on arm
363
364         * platform/graphics/qt/GraphicsContextQt.cpp:
365         (WebCore::GraphicsContext::endTransparencyLayer):
366
367 2008-01-17  Simon Hausmann  <shausman@trolltech.com>
368
369         Reviewed by Holger.
370
371         Fix compilation against Qt 4.4 without files that are specific for the Qt 4.3 build.
372
373         * WebCore.pro:
374         * platform/network/qt/ResourceHandleQt.cpp:
375         * platform/qt/MIMETypeRegistryQt.cpp:
376         * platform/qt/PlugInInfoStoreQt.cpp:
377
378 2008-01-17  Frans Englich  <fenglich@trolltech.com>
379
380         Reviewed by Simon Hausmann <hausmann@webkit.org>.
381
382         Fixes compilation with MinGW.
383         Neither localtime_r nor localtime_s are available on MingW, so instead of
384         calling back to the thread-unsafe localtime use QDateTime instead.
385
386         * loader/FTPDirectoryDocument.cpp:
387         (WebCore::FTPDirectoryTokenizer::WebCore::processFilesizeString):
388         (WebCore::FTPDirectoryTokenizer::WebCore::wasLastDayOfMonth):
389         (WebCore::FTPDirectoryTokenizer::WebCore::WebCore::gmtimeQt):
390         * loader/FTPDirectoryParser.cpp:
391         (WebCore::parseOneFTPLine):
392
393 2008-01-17  Dan Bernstein  <mitz@apple.com>
394
395         Reviewed by Dave Hyatt.
396
397         - fix determinePitch for segmented fonts
398
399         Covered by fast/css/font-face-implicit-local-font.html
400
401         * platform/graphics/FontFallbackList.cpp:
402         (WebCore::FontFallbackList::determinePitch): If the primary font is
403         segmented, treat as fixed pitch only if it has only one segment
404         and that segment is fixed-pitch.
405
406 2008-01-16  David Hyatt  <hyatt@apple.com>
407
408         Fix for http://bugs.webkit.org/show_bug.cgi?id=16611
409
410         Make sure vertical-align length values are offset from their parents rather than being absolute to the
411         line.
412
413         Reviewed by olliej
414
415         Added fast/css/vertical-align-lengths.html
416
417         * rendering/RenderObject.cpp:
418         (WebCore::RenderObject::getVerticalPosition):
419
420 2008-01-16  Dan Bernstein  <mitz@apple.com>
421
422         Reviewed by Dave Hyatt.
423
424         - fix for @font-face rules with unicode-range: always use a local font where not
425           explicitly overlaid.
426
427         Test: fast/css/font-face-implicit-local-font.html
428
429         * css/CSSFontSelector.cpp:
430         (WebCore::CSSFontSelector::addFontFaceRule): Changed to insert an implicit
431         @font-face rule with the local font the matches the family and description before
432         any explicit @font-face rules that overlay specific ranges of the same font.
433         * css/CSSSegmentedFontFace.h:
434         (WebCore::CSSSegmentedFontFace::numRanges): Addded.
435
436 2008-01-16  Antti Koivisto  <antti@apple.com>
437
438         Fix Tiger build.
439
440         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
441         (WebCore::MediaPlayerPrivate::disableUnsupportedTracks):
442
443 2008-01-16  Antti Koivisto  <antti@apple.com>
444
445         Reviewed by Adele.
446         
447         OS X fix for <rdar://problem/5605682>
448         Disallow streaming protocols for media elements
449         and <rdar://problem/5668711>
450         Limit the container and codec types that the <video> tag supports
451         
452         - Disable unsupported QuickTime tracks types. 
453         - Disallow streaming protocols (for now).
454         - Set QTMovie QTMoviePreventExternalURLLinksAttribute and QTSecurityPolicyNoCrossSiteAttribute 
455           to limit QuickTime's access to external resources.
456         
457         Windows patch coming up.
458
459         Tests: media/broken-video.html
460                media/unsupported-rtsp.html
461                media/unsupported-tracks.html
462
463         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
464         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
465         (WebCore::MediaPlayerPrivate::createQTMovie):
466         (WebCore::MediaPlayerPrivate::updateStates):
467         (WebCore::MediaPlayerPrivate::disableUnsupportedTracks):
468
469 2008-01-16  Rodney Dawes  <dobey@wayofthemonkey.com>
470
471         Reviewed by Alp Toker.
472
473         http://bugs.webkit.org/show_bug.cgi?id=16897
474         Add shared plugins directory to INCLUDE path
475
476         Add the plugins directory to INCLUDEPATH
477
478         * GNUmakefile.am:
479         * WebCore.pro:
480
481 2008-01-16  Geoffrey Garen  <ggaren@apple.com>
482
483         Reviewed by Sam Weinig.
484         
485         Added a debug counter for SQL transactions. This helped me debug an SQL
486         leak.
487
488         * bindings/js/JSCustomSQLTransactionCallback.cpp:
489         (WebCore::):
490         (WebCore::JSCustomSQLTransactionCallbackCounter::~JSCustomSQLTransactionCallbackCounter):
491         (WebCore::JSCustomSQLTransactionCallback::JSCustomSQLTransactionCallback):
492         (WebCore::JSCustomSQLTransactionCallback::~JSCustomSQLTransactionCallback):
493         * bindings/js/JSCustomSQLTransactionCallback.h:
494
495         * bindings/js/kjs_window.cpp: Removed a silly comment.
496
497 2008-01-16  David Hyatt  <hyatt@apple.com>
498
499         Fix for http://bugs.webkit.org/show_bug.cgi?id=14846, cell padding can't be changed dynamically.
500
501         Reviewed by Eric Seidel
502
503         Added fast/table/dynamic-cellpadding.html
504
505         * html/HTMLTableElement.cpp:
506         (WebCore::HTMLTableElement::parseMappedAttribute):
507         * rendering/RenderTable.cpp:
508         (WebCore::RenderTable::setCellPadding):
509         * rendering/RenderTable.h:
510
511 2008-01-16  David Hyatt  <hyatt@apple.com>
512
513         Fix for <rdar://problem/5681647> Item pages on http://www.stendmarsofa.com/ hang Safari
514
515         This regression was caused by an attempt to implement a WinIE quirk in RenderBlock::calcInlinePrefWidths.
516         The original patch introduced pathological O(n^2) behavior into this function even when the quirk didn't need
517         to apply.  In addition the quirk was only partially implemented (the full quirk did not care what was adjacent
518         to images and also needed bidi.cpp patched, since the quirk applies both when computing pref widths and when
519         laying out).
520
521         This new patch rewrites the quirk to be complete.  The original test case attached to the bug that tested a variety
522         of image/text combinations now fully matches WinIE.
523
524         Reviewed by Beth
525
526         Added fast/table/unbreakable-images-quirk.html
527
528         * rendering/RenderBlock.cpp:
529         (WebCore::RenderBlock::calcInlinePrefWidths):
530         * rendering/bidi.cpp:
531         (WebCore::RenderBlock::findNextLineBreak):
532
533 2008-01-16  Rodney Dawes  <dobey@wayofthemonkey.com>
534
535         Reviewed by Jon Honeycutt
536
537         Move isPluginBlacklisted to PluginPackageWin.cpp, to avoid
538         a circular dependency on PluginDatabaseWin
539         Remove the getFileVersion method, and just check the versions directly
540         in isPluginBlacklisted, as it was the only caller
541
542         http://bugs.webkit.org/show_bug.cgi?id=16884
543
544         * plugins/win/PluginDatabaseWin.cpp:
545         * plugins/win/PluginDatabaseWin.h:
546         * plugins/win/PluginPackageWin.cpp:
547         * plugins/win/PluginPackageWin.h:
548
549 2008-01-16  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
550
551         Reviewed by Lars.
552
553         * Set the cursor on the containingWindow() instead of the
554         nativeWidget()
555         * This should be safe even with plugins as the cursor is set
556         on the mouse events.
557
558         * platform/qt/WidgetQt.cpp:
559         (WebCore::Widget::setCursor):
560
561 2008-01-16  Brad Hughes  <bhughes@trolltech.com>
562
563         Reviewed by Lars.
564
565         Improve the sqlite3 dependency when building WebKit inside Qt.
566
567         Build sqlite3 into QtWebKit if a system sqlite3 development package
568         can't be found.
569
570         * WebCore.pro:
571
572 2008-01-16  Lars Knoll  <lars@trolltech.com>
573
574         Reviewed by Simon Hausmann <simon.hausmann@trolltech.com>.
575
576         Implement GraphicsContext::clipOut and fix transparency layers.
577
578         Transparency layers where broken in two ways: It always used the
579         complete device rect as the size of the layer pixmap and the pixmaps
580         where not correctly initialized to transparent.
581
582         This fixes the worst drawing errors in the Inspector and makes drawing it
583         10 times faster.
584
585         * platform/graphics/qt/GraphicsContextQt.cpp:
586         (WebCore::toQtLineJoin):
587         (WebCore::TransparencyLayer::TransparencyLayer):
588         (WebCore::GraphicsContextPlatformPrivate::p):
589         (WebCore::GraphicsContext::platformContext):
590         (WebCore::GraphicsContext::savePlatformState):
591         (WebCore::GraphicsContext::restorePlatformState):
592         (WebCore::GraphicsContext::drawRect):
593         (WebCore::GraphicsContext::drawLine):
594         (WebCore::GraphicsContext::drawEllipse):
595         (WebCore::GraphicsContext::strokeArc):
596         (WebCore::GraphicsContext::drawConvexPolygon):
597         (WebCore::GraphicsContext::fillRect):
598         (WebCore::GraphicsContext::fillRoundedRect):
599         (WebCore::GraphicsContext::clip):
600         (WebCore::GraphicsContext::drawFocusRing):
601         (WebCore::GraphicsContext::beginTransparencyLayer):
602         (WebCore::GraphicsContext::endTransparencyLayer):
603         (WebCore::GraphicsContext::clearRect):
604         (WebCore::GraphicsContext::strokeRect):
605         (WebCore::GraphicsContext::setLineCap):
606         (WebCore::GraphicsContext::setLineJoin):
607         (WebCore::GraphicsContext::setMiterLimit):
608         (WebCore::GraphicsContext::setAlpha):
609         (WebCore::GraphicsContext::setCompositeOperation):
610         (WebCore::GraphicsContext::clipOut):
611         (WebCore::GraphicsContext::translate):
612         (WebCore::GraphicsContext::origin):
613         (WebCore::GraphicsContext::rotate):
614         (WebCore::GraphicsContext::scale):
615         (WebCore::GraphicsContext::clipOutEllipseInRect):
616         (WebCore::GraphicsContext::addInnerRoundedRectClip):
617         (WebCore::GraphicsContext::setPlatformStrokeStyle):
618         (WebCore::GraphicsContext::setPlatformStrokeThickness):
619         (WebCore::GraphicsContext::setPlatformFillColor):
620         (WebCore::GraphicsContext::setUseAntialiasing):
621
622 2008-01-16  Lars Knoll  <lars@trolltech.com>
623
624         Reviewed by Simon Hausmann <simon.hausmann@trolltech.com>.
625
626         Trivially implement the themed search field by mapping it to a text field
627
628         Also add a bunch of notImplemented warnings for other places where we don't
629         have an implementatin in RenderTheme.
630
631         * platform/qt/RenderThemeQt.cpp:
632         (WebCore::RenderThemeQt::paintTextField):
633         (WebCore::RenderThemeQt::paintMenuListButton):
634         (WebCore::RenderThemeQt::adjustMenuListButtonStyle):
635         (WebCore::RenderThemeQt::paintSliderTrack):
636         (WebCore::RenderThemeQt::paintSliderThumb):
637         (WebCore::RenderThemeQt::paintSearchField):
638         (WebCore::RenderThemeQt::adjustSearchFieldStyle):
639         (WebCore::RenderThemeQt::adjustSearchFieldCancelButtonStyle):
640         (WebCore::RenderThemeQt::paintSearchFieldCancelButton):
641         (WebCore::RenderThemeQt::adjustSearchFieldDecorationStyle):
642         (WebCore::RenderThemeQt::paintSearchFieldDecoration):
643         (WebCore::RenderThemeQt::adjustSearchFieldResultsDecorationStyle):
644         (WebCore::RenderThemeQt::paintSearchFieldResultsDecoration):
645
646 2008-01-16  Holger Freyther  <holger.freyther@trolltech.com>
647
648         Reviewed by Simon.
649
650         * Follow the EventHandlerWin.cpp and always return true in the handlers.
651         * Match the windows implementation more closely as well.
652         * This is fixing "selection" bugs with the Web Inspector
653
654         * page/qt/EventHandlerQt.cpp:
655         (WebCore::EventHandler::focusDocumentView):
656         (WebCore::EventHandler::passMousePressEventToSubframe):
657         (WebCore::EventHandler::passMouseMoveEventToSubframe):
658         (WebCore::EventHandler::passMouseReleaseEventToSubframe):
659         (WebCore::EventHandler::passMousePressEventToScrollbar):
660
661 2008-01-16  Simon Hausmann  <hausmann@webkit.org>
662
663         Reviewed by Lars Knoll <lars@trolltech.com>.
664
665         Fix crashes in the new networking code.
666
667         When the ResourceLoader cancels the handle we have to make sure not to access
668         the resource handle afterwards again.
669
670         * platform/network/qt/QNetworkReplyHandler.cpp:
671         (WebCore::QNetworkReplyHandler::finish):
672         (WebCore::QNetworkReplyHandler::forwardData):
673
674 2008-01-16  Lars Knoll  <lars@trolltech.com>
675
676         Reviewed by Simon.
677
678         add conversion methods from and to QUrl to KURL.
679
680         Use them in the places I found at the moment. Fixes a bug
681         where form data was encoded twice.
682         Also fix QWebSettings to take a QUrl for the user style sheet
683         location.
684
685         * WebCore.pro:
686         * platform/KURL.h:
687         * platform/network/qt/QNetworkReplyHandler.cpp:
688         (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
689         * platform/network/qt/ResourceRequestQt.cpp:
690         (WebCore::ResourceRequest::toNetworkRequest):
691         * platform/qt/KURLQt.cpp: Added.
692         (WebCore::KURL::KURL):
693         (WebCore::KURL::operator QUrl):
694
695 2008-01-15  Darin Adler  <darin@apple.com>
696
697         Rubber-stamped by Maciej Stachowiak and Oliver Hunt.
698
699         - fix <rdar://problem/5689748> REGRESSION: Cannot redirect to protocols handled by external applications
700
701         Put navigation policy delegate calls back for redirects.
702         Just rolled out the change where I took them out.
703
704         * loader/MainResourceLoader.cpp:
705         (WebCore::MainResourceLoader::callContinueAfterNavigationPolicy):
706         (WebCore::MainResourceLoader::continueAfterNavigationPolicy):
707         (WebCore::MainResourceLoader::willSendRequest):
708         * loader/MainResourceLoader.h:
709
710 2008-01-15  Adele Peterson  <adele@apple.com>
711
712         Reviewed by Sam.
713
714         Remove unused variable for old media control background drawing code.
715
716         * rendering/RenderThemeMac.h:
717         * rendering/RenderThemeMac.mm:
718         (WebCore::RenderThemeMac::RenderThemeMac):
719         (WebCore::RenderThemeMac::~RenderThemeMac):
720
721 2008-01-15  Sam Weinig  <sam@webkit.org>
722
723         Reviewed by Geoffrey Garen.
724
725         Fix <rdar://problem/5595552> r27608 introduced a 20% increase in JS binary size, 4% increase in WebCore binary size
726
727         - Update JS Function implementations to use a static function based method. This decreases
728           the binary size of an Intel only build by 1013.5K.
729
730         * WebCore.xcodeproj/project.pbxproj:
731         * bindings/js/JSDOMWindowCustom.cpp:
732         (WebCore::JSDOMWindow::customGetOwnPropertySlot):
733         * bindings/js/JSEventTargetBase.cpp:
734         (WebCore::jsEventTargetAddEventListener):
735         (WebCore::jsEventTargetRemoveEventListener):
736         (WebCore::jsEventTargetDispatchEvent):
737         (WebCore::retrieveEventTargetAndCorrespondingNode):
738         * bindings/js/JSEventTargetBase.h:
739         * bindings/js/JSHTMLInputElementBase.cpp:
740         (WebCore::jsHTMLInputElementBaseFunctionSetSelectionRange):
741         (WebCore::JSHTMLInputElementBase::getOwnPropertySlot):
742         * bindings/js/JSHTMLInputElementBase.h:
743         * bindings/js/JSLocation.cpp:
744         (WebCore::JSLocation::getOwnPropertySlot):
745         (WebCore::jsLocationProtoFuncReplace):
746         (WebCore::jsLocationProtoFuncReload):
747         (WebCore::jsLocationProtoFuncAssign):
748         (WebCore::jsLocationProtoFuncToString):
749         * bindings/js/JSLocation.h:
750         * bindings/js/JSXMLHttpRequest.cpp:
751         (KJS::jsXMLHttpRequestPrototypeFunctionAbort):
752         (KJS::jsXMLHttpRequestPrototypeFunctionGetAllResponseHeaders):
753         (KJS::jsXMLHttpRequestPrototypeFunctionGetResponseHeader):
754         (KJS::jsXMLHttpRequestPrototypeFunctionOpen):
755         (KJS::jsXMLHttpRequestPrototypeFunctionSend):
756         (KJS::jsXMLHttpRequestPrototypeFunctionSetRequestHeader):
757         (KJS::jsXMLHttpRequestPrototypeFunctionOverrideMIMEType):
758         (KJS::jsXMLHttpRequestPrototypeFunctionAddEventListener):
759         (KJS::jsXMLHttpRequestPrototypeFunctionRemoveEventListener):
760         (KJS::jsXMLHttpRequestPrototypeFunctionDispatchEvent):
761         * bindings/js/JSXMLHttpRequest.h:
762         * bindings/js/JSXSLTProcessor.cpp:
763         (KJS::jsXSLTProcessorPrototypeFunctionImportStylesheet):
764         (KJS::jsXSLTProcessorPrototypeFunctionTransformToFragment):
765         (KJS::jsXSLTProcessorPrototypeFunctionTransformToDocument):
766         (KJS::jsXSLTProcessorPrototypeFunctionSetParameter):
767         (KJS::jsXSLTProcessorPrototypeFunctionGetParameter):
768         (KJS::jsXSLTProcessorPrototypeFunctionRemoveParameter):
769         (KJS::jsXSLTProcessorPrototypeFunctionClearParameters):
770         (KJS::jsXSLTProcessorPrototypeFunctionReset):
771         * bindings/js/JSXSLTProcessor.h:
772         * bindings/js/kjs_events.cpp:
773         (WebCore::jsClipboardPrototypeFunctionClearData):
774         (WebCore::jsClipboardPrototypeFunctionGetData):
775         (WebCore::jsClipboardPrototypeFunctionSetData):
776         (WebCore::jsClipboardPrototypeFunctionSetDragImage):
777         * bindings/js/kjs_events.h:
778         * bindings/js/kjs_navigator.cpp:
779         (KJS::pluginsFunctionRefresh):
780         (KJS::navigatorProtoFuncJavaEnabled):
781         * bindings/js/kjs_navigator.h:
782         * bindings/js/kjs_window.cpp:
783         (KJS::Window::getOwnPropertySlot):
784         (KJS::windowProtoFuncAToB):
785         (KJS::windowProtoFuncBToA):
786         (KJS::windowProtoFuncOpen):
787         (KJS::windowProtoFuncSetTimeout):
788         (KJS::windowProtoFuncClearTimeout):
789         (KJS::windowProtoFuncSetInterval):
790         (KJS::windowProtoFuncAddEventListener):
791         (KJS::windowProtoFuncRemoveEventListener):
792         (KJS::windowProtoFuncShowModalDialog):
793         (KJS::windowProtoFuncNotImplemented):
794         * bindings/js/kjs_window.h:
795         * bindings/scripts/CodeGenerator.pm:
796         * bindings/scripts/CodeGeneratorJS.pm:
797
798 2008-01-15  Adele Peterson  <adele@apple.com>
799
800         Reviewed by Dan.
801
802         Fix for <rdar://problem/5682492> With the <video> element, the audio is heard when forwarding or rewinding a movie while it's playing
803
804         * rendering/MediaControlElements.cpp: (WebCore::MediaControlSeekButtonElement::defaultEventHandler):
805           Instead of pausing the media when you stop seeking on mouse up, pause the video when you first start seeking on mouse down. 
806
807 2008-01-15  Alp Toker  <alp@atoker.com>
808
809         Rubber-stamped by Anders.
810
811         Make the HTTP backend configurable in the GTK+ port. curl is currently
812         the only option.
813
814         * GNUmakefile.am:
815
816 2008-01-15  Adele Peterson  <adele@apple.com>
817
818         Build fix.
819
820         * rendering/RenderThemeSafari.cpp: Removing MediaBackgroundAppearance.
821
822 2008-01-14  Samuel Weinig  <sam@webkit.org>
823
824         Reviewed by Darin.
825
826         Fix for <rdar://problem/5671040>
827         REGRESSION: 6% HTML iBench regression from r28722 (getElementsByClassName)
828
829         On my most consistent tests, this brings the HTML iBench from 1.46 -> 1.41,
830         which does not completely make up reported regression, but I was not able to
831         reproduce those findings either.
832
833         * css/CSSStyleSelector.cpp:
834         (WebCore::CSSStyleSelector::matchRules):
835         (WebCore::CSSStyleSelector::checkOneSelector):
836         * dom/ClassNames.cpp:
837         (WebCore::ClassNames::parseClassAttribute):
838         * dom/ClassNames.h:
839         (WebCore::ClassNames::contains):
840         (WebCore::ClassNames::operator[]):
841
842 2008-01-15  Adele Peterson  <adele@apple.com>
843
844         Build fix.  This time for real.
845
846         * rendering/RenderThemeSafari.cpp:
847
848 2008-01-15  Adele Peterson  <adele@apple.com>
849
850         Build fix.
851
852         * rendering/RenderThemeSafari.cpp:
853
854 2008-01-15  Dan Bernstein  <mitz@apple.com>
855
856         Reviewed by Darin Adler.
857
858         - fix <rdar://problem/5666926> svg/custom/use-css-no-effect-on-shadow-tree.svg is failing
859
860         * svg/SVGPreserveAspectRatio.cpp:
861         (WebCore::SVGPreserveAspectRatio::getCTM): Changed the arguments' type
862         from float to double in order to make the values passed to scale() and
863         translate() on Mac OS X and on Windows the same.
864         * svg/SVGPreserveAspectRatio.h:
865
866 2008-01-15  Alexey Proskuryakov  <ap@webkit.org>
867
868         Reviewed by Darin.
869
870         <rdar://problem/5342813> REGRESSION: Safari encodes mailto URLs incorrectly
871
872         Test: fast/encoding/mailto-always-utf-8.html
873
874         * platform/KURL.cpp: (WebCore::encodeRelativeString): Always use UTF-8 for mailto URLs.
875
876 2008-01-15  Adele Peterson  <adele@apple.com>
877
878         Reviewed by Adam and Antti.
879
880         WebCore part of fix for <rdar://problem/5619062> Add load progress indicator to video controls
881
882         * WebCore.base.exp: Removed symbol for wkGetMediaControlBackgroundImageData.  Added symbol for wkDrawMediaSliderTrack.
883         * css/CSSPrimitiveValueMappings.h: (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Removed case for MediaBackgroundAppearance.
884         * css/html4.css: Removed -webkit-appearance: media-background rule for the media panel element.  Removed unnecessary margin for slider.
885         * rendering/RenderStyle.h: (WebCore::): Removed MediaBackgroundAppearance.
886
887         * html/HTMLMediaElement.cpp: (WebCore::HTMLMediaElement::initAndDispatchProgressEvent):
888           Call updateMediaPlayer more frequently so the load progress control gets updated appropriately.
889         * platform/mac/WebCoreSystemInterface.h: Removed wkGetMediaControlBackgroundImageData.  Added wkDrawMediaSliderTrack.
890         * platform/mac/WebCoreSystemInterface.mm: ditto.
891
892         * rendering/RenderTheme.h: Removed paintMediaBackground. Added paintMediaSliderTrack.
893         * rendering/RenderTheme.cpp: (WebCore::RenderTheme::paint): Call paintMediaSliderTrack for elements with MediaSliderAppearance.
894         * rendering/RenderThemeMac.h: Removed paintMediaBackground. Added paintMediaSliderTrack.
895         * rendering/RenderThemeMac.mm:
896         (WebCore::RenderThemeMac::adjustSliderThumbSize): Added different sizes for the media slider thumb.
897         (WebCore::RenderThemeMac::paintMediaSliderTrack): Added.  Calls wkDrawMediaSliderTrack with the percentage the media has loaded.
898         * rendering/RenderThemeSafari.cpp: ditto.
899         (WebCore::RenderThemeSafari::adjustSliderThumbSize):
900         (WebCore::RenderThemeSafari::paintMediaSliderTrack):
901         * rendering/RenderThemeSafari.h:
902
903 2008-01-15  Alexey Proskuryakov  <ap@webkit.org>
904
905         Reviewed by Mark Rowe.
906
907         Some logging channels weren't initialized from user defaults.
908
909         * platform/mac/LoggingMac.mm: (WebCore::InitializeLoggingChannelsIfNecessary):
910         Initialize LogPlatformLeaks, LogStorageAPI, LogMedia, LogPlugin.
911
912 2008-01-14  Steve Falkenburg  <sfalken@apple.com>
913
914         Use shared vsprops for most vcproj properties.
915         
916         Reviewed by Darin.
917
918         * WebCore.vcproj/QTMovieWin.vcproj:
919         * WebCore.vcproj/WebCore.vcproj:
920         * platform/graphics/win/QTMovieWin.cpp:
921         (QTMovieWin::initializeQuickTime): Fix compiler warning.
922
923 2008-01-14  Eric Seidel  <eric@webkit.org>
924
925         Reviewed by mjs.
926
927         Remove a couple more uses of DeprecatedString
928
929         No functional changes, thus no test case.
930
931         * dom/Document.cpp:
932         (WebCore::Document::write):
933         (WebCore::Document::writeln):
934         (WebCore::Document::recalcStyleSelector):
935         * dom/Document.h:
936
937 2008-01-14  Pierre-Luc Beaudoin  <pierre-luc.beaudoin@collabora.co.uk>
938
939         Reviewed by Alp Toker.
940
941         Build fix: missing symbols when compiling WebKit/Gtk+ with --enable-svg-filters
942         http://bugs.webkit.org/show_bug.cgi?id=16874
943
944         * GNUmakefile.am:
945         * svg/graphics/cairo/SVGResourceFilterCairo.cpp: Added.
946         (WebCore::SVGResourceFilter::createPlatformData):
947         (WebCore::SVGResourceFilter::prepareFilter):
948         (WebCore::SVGResourceFilter::applyFilter):
949
950 2008-01-14  Finnur Thorarinsson  <finnur.webkit@gmail.com>
951
952         Reviewed by hyatt & eseidel.
953
954         - fix http://bugs.webkit.org/show_bug.cgi?id=16844
955         RenderText::addLineBoxRects erroneously includes last char for boundingBox
956
957         This patch fixes an issue with addLineBoxRects not correctly calculating the 
958         rects due to an off-by-one error in using box->end(). We were assuming that 
959         end() gives the index past the last character, when in fact it gives the 
960         index _of_ the last character. 
961
962         Eric Seidel and I could not find a way to test this via DRT. This method is 
963         only used by WebKit or Safari for displaying selection rects AFAICT.
964
965         * rendering/RenderText.cpp:
966         (WebCore::RenderText::addLineBoxRects):
967
968 2008-01-14  Darin Adler  <darin@apple.com>
969
970         Reviewed by Geoff.
971
972         - fix crash seen in layout tests
973
974         * html/HTMLFrameSetElement.cpp:
975         (WebCore::HTMLFrameSetElement::attach):
976         Remove incorrect cast to HTMLElement* for parentNode(). The parent is either an
977         HTMLElement or a Document, not necessarily an HTMLElement.
978
979 2008-01-14  Darin Adler  <darin@apple.com>
980
981         Reviewed by Sam.
982
983         - fix mistakes Sam noticed in my re-speed-up patch
984
985         * dom/Element.cpp:
986         (WebCore::Element::virtualHasTagName): Moved out of header file. No reason to make
987         this inline.
988         * dom/Element.h: Moved virtualHasTagName out of header file.
989
990         * dom/Node.cpp:
991         (WebCore::Node::virtualHasTagName): Moved out of header file. No reason to make
992         this inline.
993         * dom/Node.h: Removed incorrect "virtual" on hasTagName and moved virtualHasTagName
994         out of header file.
995
996         * platform/text/StringBuffer.h: Added. Has just the new StringBuffer class.
997
998         * platform/text/StringImpl.h: Removed StringBuffer class.
999
1000         * loader/DocumentLoader.cpp: Added StringBuffer.h include.
1001         * platform/text/String.cpp: Ditto.
1002         * platform/text/StringImpl.cpp: Ditto.
1003         * platform/text/TextCodecLatin1.cpp: Ditto.
1004         * platform/text/TextCodecUTF16.cpp: Ditto.
1005         * platform/text/TextCodecUserDefined.cpp: Ditto.
1006
1007         * WebCore.vcproj/WebCore.vcproj: Added StringBuffer.h.
1008         * WebCore.xcodeproj/project.pbxproj: Ditto.
1009
1010 2008-01-14  Dave Hyatt  <hyatt@apple.com>
1011
1012         Clean up all the misplaced graphics files after the recent file moves.  Clean up the project to
1013         accurately reflect the location of all the graphics files.
1014         
1015         Reviewed by Adam
1016
1017         * WebCore.vcproj/WebCore.vcproj:
1018         * platform/graphics/win/GraphicsContextWin.cpp: Copied from platform/win/GraphicsContextWin.cpp.
1019         * platform/graphics/win/UniscribeController.cpp: Copied from platform/win/UniscribeController.cpp.
1020         * platform/graphics/win/UniscribeController.h: Copied from platform/win/UniscribeController.h.
1021         * platform/win/GraphicsContextWin.cpp: Removed.
1022         * platform/win/UniscribeController.cpp: Removed.
1023         * platform/win/UniscribeController.h: Removed.
1024
1025 2008-01-14  Geoffrey Garen  <ggaren@apple.com>
1026
1027         Reviewed by Sam Weinig.
1028         
1029         Some cleanup to my last patch.
1030
1031         Removed one unused setter declaration and one unused setter definition.
1032         
1033         Renamed DoNotCheckDomainSecurityOnRead to DoNotCheckDomainSecurityOnGet
1034         because "get" is all over the IDL files, and "read" is not.
1035
1036         * bindings/scripts/CodeGeneratorJS.pm:
1037         * page/DOMWindow.h:
1038         (WebCore::DOMWindow::defaultstatus):
1039         * page/DOMWindow.idl:
1040
1041 2008-01-14  Dan Bernstein  <mitz@apple.com>
1042
1043         Rubber-stamped by Alice Liu.
1044
1045         - remove reference to nonexistent file
1046
1047         * WebCore.vcproj/WebCore.vcproj: Removed reference to SVGFont.h.
1048
1049 2008-01-14  Darin Adler  <darin@apple.com>
1050
1051         Reviewed by Adam.
1052
1053         - re-speed-up the page load test (my StringImpl change slowed it down)
1054           <rdar://problem/5677241> 1.5% PLT regression from r29098
1055
1056         To reverse the slowdown I caused by changing StringImpl, I tightened it up,
1057         and also did a little optimization in the HTML tokenizer and in other clients
1058         of Vector.
1059
1060         * WebCore.base.exp: Removed export of a now-inline function.
1061
1062         * css/CSSParser.cpp:
1063         (WebCore::CSSParser::parseTransitionProperty): Removed use of DeprecatedString
1064         to get property ID. This could be sped up even more by writing a fast path
1065         to use a local Vector<char> rather than allocating a string.
1066         (WebCore::convertASCIIToFloat): Added. Allows numeric conversion without
1067         allocating a string object to hold the number.
1068         (WebCore::CSSParser::lex): Changed to call convertASCIIToFloat instead of
1069         DeprecatedString::toFloat.
1070
1071         * dom/Element.h:
1072         (WebCore::Element::hasTagName): Made this non-virtual and inline if you have
1073         an Element*. It's still virtual if you have a Node*.
1074         (WebCore::Element::virtualHasTagName): Virtual version that makes the Node*
1075         case work.
1076
1077         * dom/Node.h:
1078         (WebCore::Node::hasTagName): Made this non-virtual and inline so that Element
1079         can override it with an inline. This is the same technique we use for
1080         firstChild and lastChild.
1081         (WebCore::Node::virtualHasTagName): This is the private virtual that Element
1082         overrides.
1083
1084         * dom/Text.cpp:
1085         (WebCore::Text::splitText): Clean up by using a RefPtr here instead of a
1086         PassRefPtr.
1087
1088         * html/HTMLTokenizer.cpp:
1089         (WebCore::HTMLTokenizer::parseSpecial): Use the new advancePastNonNewline(),
1090         which is more efficient in cases where we know the character is not a newline
1091         and hence we don't have to update the line number.
1092         (WebCore::HTMLTokenizer::parseComment): Ditto.
1093         (WebCore::HTMLTokenizer::parseServer): Ditto.
1094         (WebCore::HTMLTokenizer::parseProcessingInstruction): Ditto.
1095         (WebCore::HTMLTokenizer::parseText): Ditto.
1096         (WebCore::HTMLTokenizer::parseEntity): Ditto.
1097         (WebCore::HTMLTokenizer::parseTag): Ditto. Also streamline the QuotedValue case
1098         so there's one less branch taken for non-punctuation characters since this
1099         code path is *so* hot.
1100         (WebCore::HTMLTokenizer::write): More of the same.
1101
1102         * loader/Cache.cpp:
1103         (WebCore::Cache::lruListFor): Use Vector::grow instead of resize.
1104
1105         * loader/DocumentLoader.cpp:
1106         (WebCore::canonicalizedTitle): Use StringBuffer instead of Vector<UChar>.
1107
1108         * loader/TextResourceDecoder.cpp:
1109         (WebCore::TextResourceDecoder::checkForCSSCharset): Use Vector::grow instead of resize.
1110         (WebCore::TextResourceDecoder::checkForHeadCharset): Ditto.
1111         (WebCore::TextResourceDecoder::decode): Use Vector::grow and shrink instead of resize.
1112         (WebCore::TextResourceDecoder::flush): Use Vector::shrink instead of resize.
1113
1114         * platform/KURL.cpp:
1115         (WebCore::KURL::decode_string): Use Vector::grow instead of resize.
1116
1117         * platform/SharedBuffer.cpp:
1118         (WebCore::SharedBuffer::clear): Use Vector::shrink instead of resize.
1119
1120         * platform/graphics/BitmapImage.cpp:
1121         (WebCore::BitmapImage::cacheFrame): Use Vector::grow instead of resize.
1122
1123         * platform/network/FormData.cpp:
1124         (WebCore::FormData::appendData): Use Vector::grow instead of resize.
1125         (WebCore::FormData::flatten): Ditto.
1126
1127         * platform/text/AtomicString.cpp:
1128         (WebCore::CStringTranslator::translate): Use a new StringImpl constructor made just
1129         for use by AtomicString. Avoids setting fields twice, and also preserves reference
1130         count behavior (which I changed for the other constructors, since they're entirely
1131         private and used only inside the class).
1132         (WebCore::UCharBufferTranslator::translate): Ditto.
1133
1134         * platform/text/Base64.cpp:
1135         (WebCore::base64Encode): Use Vector::grow instead of resize.
1136         (WebCore::base64Decode): Use Vector::grow and shrink instead of resize.
1137
1138         * platform/text/PlatformString.h:
1139         (WebCore::String::adopt): Added an overload for the new StringBuffer class. Also
1140         made both versions inline.
1141
1142         * platform/text/SegmentedString.h:
1143         (WebCore::SegmentedString::advancePastNewline): Added. One less branch for case
1144         where the character is known to be a newline.
1145         (WebCore::SegmentedString::advancePastNonNewline): Added. Less code for case where
1146         the character is known not to be a newline.
1147
1148         * platform/text/String.cpp:
1149         (WebCore::String::append): Use StringBuffer instead of Vector<UChar>.
1150         (WebCore::String::insert): Ditto.
1151         (WebCore::String::truncate): Ditto.
1152         (WebCore::String::remove): Ditto.
1153         (WebCore::String::format): Use Vector::grow instead of resize.
1154
1155         * platform/text/StringImpl.cpp:
1156         (WebCore::StringImpl::StringImpl): Changed constructors to start with a refCount
1157         of 1 instead of 0, and made them all inline. Eliminates the WithOneRef constructor
1158         since they all behave this way now. The only exceptions are the constructors for
1159         AtomicString, which retain the old behavior.
1160         (WebCore::StringImpl::empty): Simplified, since we no longer need to use the
1161         special WithOneRef constructor.
1162         (WebCore::StringImpl::toCoordsArray): Use StringBuffer instead of Vector<UChar>.
1163         (WebCore::StringImpl::lower): Ditto.
1164         (WebCore::StringImpl::upper): Ditto.
1165         (WebCore::StringImpl::secure): Ditto.
1166         (WebCore::StringImpl::foldCase): Ditto.
1167         (WebCore::StringImpl::simplifyWhiteSpace): Ditto. Also change to use Vector::shrink
1168         instead of resize (since half of the function uses Vector<UChar>).
1169         (WebCore::StringImpl::capitalize): Use StringBuffer instead of Vector<UChar>.
1170         (WebCore::StringImpl::replace): Ditto.
1171         (WebCore::StringImpl::ascii): Streamlined a bit.
1172         (WebCore::StringImpl::createStrippingNullCharacters): Use StringBuffer insetad of
1173         Vector<UChar>. Took out checks for null characters and 0 length that aren't needed.
1174         Coded the check for null characters in a slightly more efficient way. Since this
1175         is so hot, didn't call adopt at all, putting the code right in here, including
1176         the call to the StringImpl constructor and adoptRef (for the fast case).
1177         (WebCore::StringImpl::adopt): Added a version for the new StringBuffer class.
1178         Removed the attempt to resize the buffer at the time we adopt based on measuring
1179         actual use and realizing that it's just a character here or there and not worth
1180         a call to fastRealloc. Changed to use adoptRef since the constructor now starts
1181         with a refCount of 1.
1182         (WebCore::StringImpl::create): Changed to use adoptRef since the constructor now
1183         starts with a refCount of 1.
1184         (WebCore::StringImpl::createWithTerminatingNullCharacter): Ditto.
1185         (WebCore::StringImpl::copy): Ditto. Also made non-inline since the constructor
1186         itself is now inline.
1187
1188         * platform/text/StringImpl.h: Added a StringBuffer class that's useful for
1189         putting characters into a buffer before creating an immutable string. Not good
1190         at resizing the way Vector<UChar> is, so only useful for things that rarely need
1191         to be resized. Added a new AdoptBuffer constructor and empty constructor, but
1192         made all constructors private so they can be inlined and only used inside the
1193         StringImpl class. Added two new constructors for AtomicString. Made copy()
1194         no longer inline. Changed the type of the [] operator to unsigned instead of
1195         int and added an assertion. Made the hash functions inline.
1196
1197         * platform/text/TextCodecICU.cpp:
1198         (WebCore::TextCodecICU::encode): Use Vector::grow instead of resize.
1199
1200         * platform/text/TextCodecLatin1.cpp:
1201         (WebCore::TextCodecLatin1::decode): Use StringBuffer instead of Vector<UChar>.
1202         (WebCore::encodeComplexWindowsLatin1): Use Vector::grow instead of resize.
1203
1204         * platform/text/TextCodecUTF16.cpp:
1205         (WebCore::TextCodecUTF16::decode): Use StringBuffer instead of Vector<UChar>.
1206
1207         * platform/text/TextCodecUserDefined.cpp:
1208         (WebCore::TextCodecUserDefined::decode): Use StringBuffer instead of Vector<UChar>.
1209         (WebCore::encodeComplexUserDefined): Use Vector::grow instead of resize.
1210
1211         * platform/text/TextEncoding.cpp:
1212         (WebCore::TextEncoding::encode): Use Vector::grow instead of resize.
1213
1214         * platform/text/TextStream.cpp:
1215         (WebCore::TextStream::operator<<): Use Vector::grow instead of resize.
1216
1217         * platform/text/mac/TextCodecMac.cpp:
1218         (WebCore::TextCodecMac::encode): Use Vector::grow instead of resize.
1219
1220         * rendering/AutoTableLayout.cpp:
1221         (WebCore::AutoTableLayout::insertSpanCell): Use Vector::grow instead of resize.
1222
1223         * rendering/RenderFrameSet.h:
1224         (WebCore::FrameEdgeInfo::FrameEdgeInfo): Allocate vectors with the correct initial
1225         size instead of calling resize on them after allocating empty.
1226
1227         * rendering/RenderListMarker.cpp:
1228         (WebCore::RenderListMarker::paint): Use Vector::grow instead of resize.
1229
1230         * rendering/RenderStyle.cpp: Removed CursorList::operator==.
1231         * rendering/RenderStyle.h:
1232         (WebCore::CursorList::operator==): Implemented using the Vector ==.
1233         (WebCore::CursorList::operator!=): Ditto.
1234
1235         * rendering/RenderTable.cpp:
1236         (WebCore::RenderTable::splitColumn): Use Vector::grow instead of resize.
1237         (WebCore::RenderTable::appendColumn): Ditto.
1238
1239         * rendering/RenderTableSection.cpp:
1240         (WebCore::RenderTableSection::ensureRows): Use Vector::grow instead of resize.
1241
1242         * rendering/bidi.cpp:
1243         (WebCore::addMidpoint): Use Vector::grow instead of resize.
1244
1245         * xml/XPathNodeSet.h:
1246         (WebCore::XPath::NodeSet::clear): Use Vector::shrink instead of resize.
1247
1248 2008-01-13  Steve Falkenburg  <sfalken@apple.com>
1249
1250         Share common files across projects.
1251         
1252         Unify vsprops files
1253         Debug:          common.vsprops, debug.vsprops
1254         Debug_Internal: common.vsprops, debug.vsprops, debug_internal.vsprops
1255         Release:        common.vsprops, release.vsprops
1256         
1257         Shared properties can go into common.vsprops, shared debug settings can go into debug.vsprops.
1258         debug_internal.vsprops will be mostly empty except for file path prefix modifiers.
1259
1260         Pull auto-version.sh, VERSION, and PRODUCTVERSION from tools.
1261
1262         Reviewed by Adam Roben.
1263
1264         * WebCore.vcproj/PRODUCTVERSION: Removed.
1265         * WebCore.vcproj/QTMovieWin.vcproj:
1266         * WebCore.vcproj/VERSION: Removed.
1267         * WebCore.vcproj/WebCore.vcproj:
1268         * WebCore.vcproj/auto-version.sh: Removed.
1269         * WebCore.vcproj/debug.vsprops: Removed.
1270         * WebCore.vcproj/debug_internal.vsprops: Removed.
1271         * WebCore.vcproj/release.vsprops: Removed.
1272
1273 2008-01-13  Dan Bernstein  <mitz@apple.com>
1274
1275         Reviewed by Darin Adler.
1276
1277         - fix http://bugs.webkit.org/show_bug.cgi?id=16865
1278           fast/layers/resize-layer-deletion-crash.html crashes under GuardMalloc
1279
1280         * rendering/RenderBox.cpp:
1281         (WebCore::RenderBox::destroy): Removed the call to
1282         RenderLayer::destroy() from here, because ~RenderLayer() calls
1283         RenderObject() methods.
1284         * rendering/RenderObject.cpp:
1285         (WebCore::RenderObject::destroy): Added the call to
1286         RenderLayer::destroy() here.
1287
1288 2008-01-13  Eric Seidel  <eric@webkit.org>
1289
1290         Reviewed by darin.
1291
1292         Range.insertNode does not update endContainer endIndex correctly
1293         in the case where it had to split a text node.
1294         http://bugs.webkit.org/show_bug.cgi?id=16765
1295         
1296         Darin pointed out during review that we still don't handle the dynamic
1297         range case (where the dom tree changes not using range methods)
1298         Thus this code will get ripped out when we add that.  The test cases
1299         are still valid and useful however, so I'm landing this as-is.
1300
1301         Tests: fast/dom/Range/range-insertNode-separate-endContainer.html
1302                fast/dom/Range/range-insertNode-splittext.html
1303
1304         * dom/Range.cpp:
1305         (WebCore::Range::insertNode): handle the splitText case correctly.
1306
1307 2008-01-13  Darin Adler  <darin@apple.com>
1308
1309         Reviewed by Eric.
1310
1311         - http://bugs.webkit.org/show_bug.cgi?id=16861
1312           get rid of unnecessary string copying
1313
1314         * dom/Document.cpp:
1315         (WebCore::Document::setDomain): Removed unneeded call to copy.
1316         (WebCore::Document::parseQualifiedName): Removed unneeded call to copy, and
1317         unneeded length argument to substring, which stops at the end of the string
1318         if you don't specify a length.
1319         (WebCore::Document::createAttributeNS): Replaced code that was calling copy
1320         with more-efficient code using the substring function.
1321         * dom/StyledElement.cpp:
1322         (WebCore::StyledElement::addCSSColor): Removed unneeded call to copy.
1323         * editing/InsertIntoTextNodeCommand.cpp:
1324         (WebCore::InsertIntoTextNodeCommand::InsertIntoTextNodeCommand): Removed
1325         unneeded copy and also initialized text instead of assigning to it.
1326         (WebCore::InsertIntoTextNodeCommand::doApply): Removed redundant assertions.
1327         (WebCore::InsertIntoTextNodeCommand::doUnapply): Ditto.
1328
1329         * editing/htmlediting.cpp:
1330         (WebCore::stringWithRebalancedWhitespace): Removed unneeded call to copy.
1331         This one was particularly bad since we just turned around and copied it again!
1332
1333         * editing/markup.cpp:
1334         (WebCore::stringValueForRange): Removed unneeded call to copy.
1335
1336         * loader/icon/IconDatabase.cpp:
1337         (WebCore::IconDatabase::performOpenInitialization): Changed logging code to not
1338         get the path from the database object. This was the only reason the database
1339         had to keep its path around.
1340
1341         * platform/sql/SQLiteDatabase.cpp:
1342         (WebCore::SQLiteDatabase::open): Use a local variable instead of a data member to
1343         convert the string to a null-terminated one.
1344         (WebCore::SQLiteDatabase::close): Removed the code to clear out m_path.
1345         * platform/sql/SQLiteDatabase.h: Removed the m_path data member and the path
1346         functio member. Also tweaked formatting and comments a bit. Removed the unused
1347         escapeSQLString function.
1348
1349         * platform/text/String.cpp: (WebCore::operator+): Removed uneeded calls to copy.
1350
1351 2008-01-13  Oliver Hunt  <oliver@apple.com>
1352
1353         Attempt to fix QT build
1354
1355         * html/CanvasRenderingContext2D.cpp:
1356         (WebCore::CanvasRenderingContext2D::willDraw):
1357
1358 2008-01-13  Oliver Hunt  <oliver@apple.com>
1359
1360         Reviewed by Mark Rowe.
1361
1362         Avoid repainting the entire canvas element when possible.
1363
1364         http://bugs.webkit.org/show_bug.cgi?id=16859
1365
1366         We now only register the dirty regions of a canvas for repainting, rather
1367         than the entire element (though repaint coalescing may choose to combine
1368         these regions).  This doesn't cause a measurable regression in the worst
1369         case (clearing the canvas repeatedly), but is a moderate-large win if only
1370         a minor update has occurred.  If there is any CSS scaling applied to the
1371         canvas almost any update short of clearing the entire element is substantially
1372         faster.
1373
1374         * html/CanvasRenderingContext2D.cpp:
1375         (WebCore::CanvasRenderingContext2D::willDraw):
1376         * html/HTMLCanvasElement.cpp:
1377         (WebCore::HTMLCanvasElement::willDraw):
1378
1379 2008-01-13  Michael Goddard  <michael.goddard@trolltech.com>
1380
1381         Reviewed by Anders Carlsson.
1382
1383         Move RuntimeObjectImp creations into Instance.
1384         Make the ctor protected, and Instance a friend class, so
1385         that all creation of RuntimeObjectImps goes through
1386         one place.
1387
1388         * bindings/js/kjs_dom.cpp:
1389         (WebCore::getRuntimeObject):
1390
1391 2008-01-12  Rodney Dawes  <dobey@wayofthemonkey.com>
1392
1393         Gtk debug build fix.  Reviewed by Mark Rowe.
1394
1395         Add plugin logging channel, and use it rather than Win32-specific debugging methods _RPTF1 _RPTF2 and _CRT_WARN.
1396
1397         * WebCore.pro: Add plugins directory to DEPENDPATH so dependencies are correctly tracked.
1398         * platform/Logging.cpp:
1399         * platform/Logging.h:
1400         * plugins/PluginDebug.h:
1401
1402 2008-01-12  Adam Barth  <hk9565@gmail.com>
1403
1404         Reviewed by Maciej (and also tweaked a little bit).
1405
1406         - more thorough fix for some crashing tests
1407           http://bugs.webkit.org/show_bug.cgi?id=16782
1408
1409         * loader/FrameLoader.cpp:
1410         (WebCore::FrameLoader::urlSelected):
1411         (WebCore::FrameLoader::submitForm):
1412         (WebCore::FrameLoader::executeIfJavaScriptURL):
1413         * loader/FrameLoader.h:
1414
1415 2008-01-12  Maciej Stachowiak  <mjs@apple.com>
1416
1417         Reviewed by Sam.
1418
1419         - fixed <rdar://problem/5556374> REGRESSION: cross-domain error when one URL uses an explicit port number and another doesn't
1420         
1421         * platform/SecurityOrigin.cpp:
1422         (WebCore::isDefaultPortForProtocol):
1423         (WebCore::SecurityOrigin::SecurityOrigin):
1424
1425 2008-01-11  Geoffrey Garen  <ggaren@apple.com>
1426
1427         Reviewed by Oliver Hunt.
1428         
1429         Fixed <rdar://problem/5665251> REGRESSION (r28880-r28886): Global
1430         variable access (16644)
1431         
1432         Removed the ReadOnly bit from some properties, to match Firefox. Also
1433         removed status-related setters, to allow using their names as variable
1434         names.
1435         
1436         * bindings/scripts/CodeGeneratorJS.pm: Added support for properties that
1437         are one-way across domain boundaries, to match Firefox.
1438
1439         * bindings/js/kjs_window.cpp: Changed ReadOnly declarations to match FF.
1440
1441         * bindings/scripts/CodeGeneratorJS.pm: Don't use JSObject:: because
1442         we don't know that JSObject is our base class.
1443
1444         * page/DOMWindow.idl: Replaced lots of readonly declarations with
1445         [Replaceable] declarations.
1446
1447         * page/DOMWindow.h: Removed interfaces for setting status text via the
1448         DOM. (They were getting in the way of, e.g., "var status"
1449         declarations.) By default, IE 7 and FF disable these interfaces in order
1450         to defend against phishing attacks that try to spoof domain names in the
1451         statusbar.
1452         * page/DOMWindow.cpp:
1453
1454 2008-01-11  Anyang Ren  <anyang.ren@gmail.com>
1455
1456         Reviewed by Darin Adler.
1457
1458         http://bugs.webkit.org/show_bug.cgi?id=15960
1459         The view source mode should skip an empty attribute value only if
1460         the attribute name is not followed by an equal sign (=).
1461
1462         Test: fast/frames/viewsource-empty-attribute-value.html
1463
1464         * html/HTMLViewSourceDocument.cpp:
1465         (WebCore::HTMLViewSourceDocument::addViewSourceToken):
1466
1467 2008-01-11  Sylvain Pasche  <sylvain.pasche@gmail.com>
1468
1469         Reviewed by Alp Toker.
1470
1471         [Gtk] Uneven glyph spacing with subpixel antialiasing
1472         http://bugs.webkit.org/show_bug.cgi?id=16715
1473
1474         Use cairo font options from the default GDK screen when creating a
1475         scaled font.
1476
1477         * platform/graphics/gtk/FontPlatformDataGtk.cpp:
1478         (WebCore::FontPlatformData::FontPlatformData):
1479
1480 2008-01-11  Cameron Zwarich  <cwzwarich@uwaterloo.ca>
1481
1482         Reviewed by Maciej.
1483
1484         Added a new forwarding header, because Activation.h has been separated
1485         from function.h
1486
1487         * ForwardingHeaders/kjs/Activation.h: Added.
1488
1489 2008-01-11  Luca Bruno  <lethalman88@gmail.com>
1490
1491         Reviewed by Alp Toker.
1492
1493         http://bugs.webkit.org/show_bug.cgi?id=16729
1494         [cURL] Allow multiple files for upload
1495
1496         * platform/network/ResourceHandleInternal.h:
1497         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
1498         * platform/network/curl/ResourceHandleCurl.cpp:
1499         (WebCore::ResourceHandleInternal::~ResourceHandleInternal):
1500         * platform/network/curl/ResourceHandleManager.cpp:
1501         (WebCore::readCallback): added
1502         (WebCore::ResourceHandleManager::setupPOST): setup for streaming the POST
1503         (WebCore::ResourceHandleManager::startJob):
1504         (WebCore::ResourceHandleManager::cancel): revert the previous patch for regression
1505         * platform/network/curl/ResourceHandleManager.h:
1506
1507 2008-01-11  Christian Dywan  <christian@imendio.com>
1508
1509         Reviewed by Alp Toker.
1510
1511         [Gtk] Menu items need underscores
1512         http://bugs.webkit.org/show_bug.cgi?id=16817
1513
1514         Add underscores to appropriate menu labels.
1515         Also adjust strings slightly.
1516
1517         * platform/gtk/ContextMenuItemGtk.cpp:
1518         (WebCore::ContextMenuItem::createNativeMenuItem):
1519         * platform/gtk/LocalizedStringsGtk.cpp:
1520         (WebCore::searchableIndexIntroduction):
1521         (WebCore::fileButtonChooseFileLabel):
1522         (WebCore::fileButtonNoFileSelectedLabel):
1523         (WebCore::contextMenuItemTagOpenLinkInNewWindow):
1524         (WebCore::contextMenuItemTagDownloadLinkToDisk):
1525         (WebCore::contextMenuItemTagCopyLinkToClipboard):
1526         (WebCore::contextMenuItemTagOpenImageInNewWindow):
1527         (WebCore::contextMenuItemTagDownloadImageToDisk):
1528         (WebCore::contextMenuItemTagCopyImageToClipboard):
1529         (WebCore::contextMenuItemTagOpenFrameInNewWindow):
1530         (WebCore::contextMenuItemTagCopy):
1531         (WebCore::contextMenuItemTagGoBack):
1532         (WebCore::contextMenuItemTagGoForward):
1533         (WebCore::contextMenuItemTagStop):
1534         (WebCore::contextMenuItemTagReload):
1535         (WebCore::contextMenuItemTagCut):
1536         (WebCore::contextMenuItemTagPaste):
1537         (WebCore::contextMenuItemTagIgnoreSpelling):
1538         (WebCore::contextMenuItemTagLearnSpelling):
1539         (WebCore::contextMenuItemTagSearchWeb):
1540         (WebCore::contextMenuItemTagLookUpInDictionary):
1541         (WebCore::contextMenuItemTagOpenLink):
1542         (WebCore::contextMenuItemTagIgnoreGrammar):
1543         (WebCore::contextMenuItemTagSpellingMenu):
1544         (WebCore::contextMenuItemTagShowSpellingPanel):
1545         (WebCore::contextMenuItemTagCheckSpelling):
1546         (WebCore::contextMenuItemTagCheckSpellingWhileTyping):
1547         (WebCore::contextMenuItemTagCheckGrammarWithSpelling):
1548         (WebCore::contextMenuItemTagFontMenu):
1549         (WebCore::contextMenuItemTagBold):
1550         (WebCore::contextMenuItemTagItalic):
1551         (WebCore::contextMenuItemTagUnderline):
1552         (WebCore::contextMenuItemTagOutline):
1553         (WebCore::contextMenuItemTagWritingDirectionMenu):
1554         (WebCore::contextMenuItemTagDefaultDirection):
1555         (WebCore::contextMenuItemTagLeftToRight):
1556         (WebCore::contextMenuItemTagRightToLeft):
1557         (WebCore::contextMenuItemTagInspectElement):
1558         (WebCore::searchMenuClearRecentSearchesText):
1559
1560 2008-01-11  Ada Chan  <adachan@apple.com>
1561
1562         <rdar://problem/5681557> On Windows Safari, mouse events are ignored after clicking on link that triggers download
1563         Moved the call to cache page from provisionalLoadStarted() to commitProvisionalLoad(), since 
1564         provisionalLoadStarted() can be called for cases that do not result in a page navigation, for example,
1565         when a link to download a file has been clicked.
1566
1567         Reviewed by John and Anders.
1568
1569         * loader/FrameLoader.cpp:
1570         (WebCore::FrameLoader::provisionalLoadStarted):
1571         (WebCore::FrameLoader::commitProvisionalLoad):
1572
1573 2008-01-11  Jon Honeycutt  <jhoneycutt@apple.com>
1574
1575         Reviewed by Anders.
1576
1577         <rdar://problem/5683529> plugins/embed-inside-object.html is timing
1578         out/failing
1579
1580         Revert to using FrameTree::find() so that frame aliases like "_self" and
1581         "_current" are interpreted properly
1582
1583         * plugins/win/PluginViewWin.cpp:
1584         (WebCore::PluginViewWin::performRequest):
1585         (WebCore::PluginViewWin::load):
1586
1587 2008-01-11  Alp Toker  <alp@atoker.com>
1588
1589         Reviewed by Dave Hyatt and Mark Rowe.
1590
1591         http://bugs.webkit.org/show_bug.cgi?id=16089
1592         [GTK] Support custom fonts, CachedFont::platformDataFromCustomData()
1593
1594         Add support for CSS2 @font-face custom/downloadable fonts to the GTK+
1595         port.
1596
1597         * GNUmakefile.am:
1598         * WebCore.pro:
1599         * loader/CachedFont.cpp:
1600         (WebCore::CachedFont::~CachedFont):
1601         (WebCore::CachedFont::ensureCustomFontData):
1602         (WebCore::CachedFont::platformDataFromCustomData):
1603         (WebCore::CachedFont::allReferencesRemoved):
1604         * platform/graphics/gtk/FontCustomPlatformData.cpp: Added.
1605         (WebCore::FontCustomPlatformData::~FontCustomPlatformData):
1606         (WebCore::FontCustomPlatformData::fontPlatformData):
1607         (WebCore::releaseData):
1608         (WebCore::createFontCustomPlatformData):
1609         * platform/graphics/gtk/FontCustomPlatformData.h: Added.
1610         (WebCore::FontCustomPlatformData::FontCustomPlatformData):
1611         * platform/graphics/gtk/FontPlatformData.h:
1612         * platform/graphics/gtk/FontPlatformDataGtk.cpp:
1613         (WebCore::FontPlatformData::FontPlatformData):
1614         (WebCore::FontPlatformData::init):
1615         (WebCore::FontPlatformData::isFixedPitch):
1616         * platform/graphics/gtk/SimpleFontDataGtk.cpp:
1617         (WebCore::SimpleFontData::platformDestroy):
1618
1619 2008-01-11  Adam Roben  <aroben@apple.com>
1620
1621         Remove FrameLoader::committedFirstRealDocumentLoad
1622         
1623         This method no longer has any callers.
1624
1625         Reviewed by Hyatt.
1626
1627         * loader/FrameLoader.h:
1628
1629 2008-01-11  Antti Koivisto  <antti@apple.com>
1630
1631         Add a standalone version of the blog post video player as a manual test.
1632
1633         * manual-tests/resources/touch-poster.png: Added.
1634         * manual-tests/video-player.html: Added.
1635
1636 2008-01-10  Antti Koivisto  <antti@apple.com>
1637
1638         Reviewed by Adam.
1639
1640         Fix <rdar://problem/5682767>
1641         Video does not show up in http://webkit.org/blog/140/html5-media-support/ on Windows
1642         
1643         Take care that GWorld is created and deletes when needed as size or visibility changes.
1644
1645         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.cpp:
1646         (WebCore::MediaPlayerPrivate::load):
1647         * platform/graphics/win/QTMovieWin.cpp:
1648         (QTMovieWinPrivate::QTMovieWinPrivate):
1649         (QTMovieWinPrivate::updateGWorld):
1650         (QTMovieWinPrivate::setSize):
1651         (QTMovieWin::setVisible):
1652         (QTMovieWin::initializeQuickTime):
1653
1654 2008-01-11  David Hyatt  <hyatt@apple.com>
1655
1656         Fix for bug 11188, setting hspace on a table overrides align=center.  Fix align=center to be done using
1657         mapped attributes so that it does not get overridden by hspace all the time.
1658
1659         Reviewed by mitz
1660
1661         Added fast/table/table-hspace-align-center.html
1662
1663         * css/html4.css:
1664         * html/HTMLTableElement.cpp:
1665         (WebCore::HTMLTableElement::parseMappedAttribute):
1666
1667 2008-01-11  Mark Rowe  <mrowe@apple.com>
1668
1669         Qt build fix.
1670
1671         * platform/qt/TemporaryLinkStubs.cpp: Include CString.h.
1672
1673 2008-01-11  Mark Rowe  <mrowe@apple.com>
1674
1675         Qt build fix.  Add link stubs for the new FileSystem.h functions introduced
1676         in r29399.
1677
1678         * platform/qt/TemporaryLinkStubs.cpp:
1679         (WebCore::openTemporaryFile):
1680
1681 2008-01-11  Rodney Dawes  <dobey@wayofthemonkey.com>
1682
1683         Reviewed by Anders Carlsson.
1684
1685         Bug 16779: Make the PluginStream implementation be shared across platforms
1686         http://bugs.webkit.org/show_bug.cgi?id=16779
1687
1688         Add the new shared PluginStream files to the GTK+ and Win32 builds.
1689         Add PluginStreamClient class for the streamDidFinishLoading method.
1690         Add open/close/write methods to FileSystem for temporary file handling.
1691         Add PluginDebug.h and npfunctions.h for shared PluginStream.
1692         Add shared PluginStream.
1693         Remove PluginStreamWin.
1694         Update PluginViewWin to use shared PluginStream and PluginStreamClass.
1695
1696         * GNUmakefile.am:
1697         * WebCore.pro:
1698         * WebCore.vcproj/WebCore.vcproj:
1699         * platform/FileSystem.h:
1700         * platform/gtk/FileSystemGtk.cpp:
1701         * platform/win/FileSystemWin.cpp:
1702         * plugins/PluginDebug.h:
1703         * plugins/PluginStream.cpp:
1704         * plugins/PluginStream.h:
1705         * plugins/npfunctions.h:
1706         * plugins/win/PluginDebug: Moved to PluginDebug.h.
1707         * plugins/win/PluginStreamWin.cpp: Moved to PluginStream.cpp.
1708         * plugins/win/PluginStreamWin.h: Moved to PluginStream.h
1709         * plugins/win/PluginViewWin.cpp:
1710         * plugins/win/PluginViewWin.h:
1711         * plugins/win/npfunctions.h: Moved to npfunctions.h
1712
1713 2008-01-11  Geoffrey Garen  <ggaren@apple.com>
1714
1715         Try to fix Mac build: Edit the right .exp file.
1716
1717         * WebCore.base.exp:
1718
1719 2008-01-11  Geoffrey Garen  <ggaren@apple.com>
1720
1721         Try to fix Qt build: don't use pthreads if they're not available.
1722
1723         * bindings/js/GCController.cpp:
1724
1725 2008-01-10  Geoffrey Garen  <ggaren@apple.com>
1726
1727         Reviewed by John Sullivan.
1728
1729         Fixed some world leak reports:
1730         * <rdar://problem/5669436> PLT complains about world leak of 1 JavaScript
1731         Interpreter after running cvs-base suite
1732
1733         * <rdar://problem/5669423> PLT complains about world leak if browser
1734         window is open when PLT starts
1735         
1736         These were both bugs in the reporting mechanism, so I took the
1737         opportunity to do some house cleaning there.
1738
1739         Stupid class, I kill you:
1740         * bridge/JavaScriptStatistics.cpp: Removed.
1741         * bridge/JavaScriptStatistics.h: Removed.
1742
1743         * bindings/js/GCController.h: Adopted the only useful features of
1744         JavaScriptStatistics, since they were GC-related.
1745         * bindings/js/GCController.cpp:
1746
1747 2008-01-10  Eric Seidel  <eric@webkit.org>
1748
1749         Reviewed by Adele.
1750
1751         No functional changes, only code cleanup.
1752
1753         * css/MediaQueryEvaluator.cpp:
1754         (WebCore::compareValue): renamed from cmpvalue
1755         (WebCore::colorMediaFeatureEval):
1756         (WebCore::device_aspect_ratioMediaFeatureEval):
1757         (WebCore::device_pixel_ratioMediaFeatureEval):
1758         (WebCore::gridMediaFeatureEval):
1759         (WebCore::device_heightMediaFeatureEval):
1760         (WebCore::device_widthMediaFeatureEval):
1761         (WebCore::heightMediaFeatureEval):
1762         (WebCore::widthMediaFeatureEval):
1763
1764 2008-01-10  Dan Bernstein  <mitz@apple.com>
1765
1766         Reviewed by Anders Carlsson.
1767
1768         - fix a crash when calling alert() from a repeating timer
1769
1770         On non-Mac platforms, the PageGroupLoadDeferrer pauses DOM timers during
1771         alert() and other similar functions, which deletes the actual
1772         DOMWindowTimer objects and replaces them with new objects when resuming.
1773
1774         * bindings/js/kjs_window.cpp:
1775         (KJS::Window::timerFired): Re-fetch the timer object from the map in
1776         case it has been deleted or replaced.
1777
1778 2008-01-10  Maciej Stachowiak  <mjs@apple.com>
1779
1780         Reviewed by Sam.
1781
1782         - remove SecurityOriginData and fold its functionality into SecurityOrigin
1783
1784         * GNUmakefile.am:
1785         * WebCore.base.exp:
1786         * WebCore.pro:
1787         * WebCore.vcproj/WebCore.vcproj:
1788         * WebCore.xcodeproj/project.pbxproj:
1789         * WebCoreSources.bkl:
1790         * bindings/js/JSDOMWindowCustom.cpp:
1791         (WebCore::JSDOMWindow::postMessage):
1792         * dom/Document.cpp:
1793         (WebCore::Document::domain):
1794         * page/Chrome.cpp:
1795         (WebCore::Chrome::requestQuotaIncreaseForNewDatabase):
1796         (WebCore::Chrome::requestQuotaIncreaseForDatabaseOperation):
1797         * page/Chrome.h:
1798         * page/ChromeClient.h:
1799         * platform/SecurityOrigin.cpp:
1800         (WebCore::SecurityOrigin::copy):
1801         (WebCore::SecurityOrigin::createFromIdentifier):
1802         (WebCore::SecurityOrigin::stringIdentifier):
1803         * platform/SecurityOrigin.h:
1804         (WebCore::SecurityOrigin::host):
1805         (WebCore::SecurityOrigin::protocol):
1806         (WebCore::SecurityOrigin::port):
1807         (WebCore::SecurityOrigin::equal):
1808         * platform/SecurityOriginData.cpp: Removed.
1809         * platform/SecurityOriginData.h: Removed.
1810         * storage/Database.cpp:
1811         (WebCore::Database::openDatabase):
1812         (WebCore::Database::Database):
1813         (WebCore::Database::securityOriginCopy):
1814         * storage/Database.h:
1815         * storage/DatabaseTracker.cpp:
1816         (WebCore::SecurityOriginHash::hash):
1817         (WebCore::SecurityOriginHash::equal):
1818         (WebCore::SecurityOriginTraits::deletedValue):
1819         (WebCore::SecurityOriginTraits::emptyValue):
1820         (WebCore::DatabaseTracker::canEstablishDatabase):
1821         (WebCore::DatabaseTracker::hasEntryForOrigin):
1822         (WebCore::DatabaseTracker::hasEntryForDatabase):
1823         (WebCore::DatabaseTracker::establishEntryForOrigin):
1824         (WebCore::DatabaseTracker::fullPathForDatabase):
1825         (WebCore::DatabaseTracker::populateOrigins):
1826         (WebCore::DatabaseTracker::origins):
1827         (WebCore::DatabaseTracker::databaseNamesForOrigin):
1828         (WebCore::DatabaseTracker::detailsForNameAndOrigin):
1829         (WebCore::DatabaseTracker::setDatabaseDetails):
1830         (WebCore::DatabaseTracker::usageForDatabase):
1831         (WebCore::DatabaseTracker::usageForOrigin):
1832         (WebCore::DatabaseTracker::quotaForOrigin):
1833         (WebCore::DatabaseTracker::setQuota):
1834         (WebCore::DatabaseTracker::addDatabase):
1835         (WebCore::DatabaseTracker::deleteAllDatabases):
1836         (WebCore::DatabaseTracker::deleteDatabasesWithOrigin):
1837         (WebCore::DatabaseTracker::deleteDatabase):
1838         (WebCore::DatabaseTracker::deleteDatabaseFile):
1839         (WebCore::notificationQueue):
1840         (WebCore::DatabaseTracker::scheduleNotifyDatabaseChanged):
1841         (WebCore::DatabaseTracker::notifyDatabasesChanged):
1842         * storage/DatabaseTracker.h:
1843         * storage/DatabaseTrackerClient.h:
1844         * storage/SQLTransaction.cpp:
1845         (WebCore::SQLTransaction::openTransactionAndPreflight):
1846         (WebCore::SQLTransaction::runStatements):
1847         (WebCore::SQLTransaction::deliverQuotaIncreaseCallback):
1848         (WebCore::SQLTransaction::postflightAndCommit):
1849         (WebCore::SQLTransaction::cleanupAfterTransactionErrorCallback):
1850         * svg/graphics/SVGImageEmptyClients.h:
1851         (WebCore::SVGEmptyChromeClient::requestQuotaIncreaseForNewDatabase):
1852         (WebCore::SVGEmptyChromeClient::requestQuotaIncreaseForDatabaseOperation):
1853
1854 2008-01-10  Anders Carlsson  <andersca@apple.com>
1855
1856         Reviewed by Sam.
1857
1858         Use the correct frame loader load method. Using the old method would not cause a 
1859         new window to be open if the frame navigation was not allowed.
1860         
1861         * plugins/win/PluginViewWin.cpp:
1862         (WebCore::PluginViewWin::performRequest):
1863
1864 2008-01-10  Alp Toker  <alp@atoker.com>
1865
1866         SVG font build fix for GTK+/autotools.
1867
1868         * GNUmakefile.am:
1869
1870 2008-01-10  Adam Barth  <hk9565@gmail.com>
1871
1872         Reviewed by Sam Weinig and Anders Carlsson.
1873
1874         Fixes: http://bugs.webkit.org/show_bug.cgi?id=16522
1875         <rdar://problem/5657355>
1876
1877         This patch makes two changes:
1878
1879         1) Java calls FrameLoader::load in a slightly different way than
1880            JavaScript, which previously let a malicious web site bypass the
1881            shouldAllowNavigation check.  This patch adds that check to that
1882            code path.
1883
1884         2) FrameLoader now wraps calls to m_frame->tree()->find(name) with
1885            findFrameForNavigation, which calls shouldAllowNavigation.  This
1886            treats disallowed frame navigations as if the named frame did not
1887            exist, resulting in a popup window when appropriate.
1888
1889         Tests: http/tests/security/frameNavigation/xss-DENIED-plugin-navigation.html
1890                http/tests/security/frameNavigation/xss-DENIED-targeted-link-navigation.html
1891
1892         * WebCore.base.exp:
1893         * bindings/js/kjs_window.cpp:
1894         (KJS::WindowProtoFuncOpen::callAsFunction):
1895         * loader/FrameLoader.cpp:
1896         (WebCore::FrameLoader::createWindow):
1897         (WebCore::FrameLoader::load):
1898         (WebCore::FrameLoader::post):
1899         (WebCore::FrameLoader::findFrameForNavigation):
1900         * loader/FrameLoader.h:
1901
1902 2008-01-10  John Sullivan  <sullivan@apple.com>
1903
1904         Written by Hyatt, reviewed by me
1905         
1906         - fixed <rdar://problem/5654297> Mail crashes occurs at WebCore::FontFallbackList::fontDataAt() when attempting to display 
1907           a <video> element that uses controls attribute
1908
1909         * rendering/MediaControlElements.cpp:
1910         (WebCore::MediaControlShadowRootElement::MediaControlShadowRootElement):
1911         force the render style to inherit from the media element's style; Hyatt filed 5682383 to cover cleaning
1912         up this architecture, but this one-line fix will prevent the crash in the meantime
1913
1914 2008-01-10  Ada Chan  <adachan@apple.com>
1915
1916         Fix fast/forms/input-radio-checked-tab.html
1917         Meta key is not the same as Alt key on windows.
1918
1919         Reviewed by Darin.
1920
1921         * platform/win/KeyEventWin.cpp:
1922         (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):
1923
1924 2008-01-10  Anders Carlsson  <andersca@apple.com>
1925
1926         Reviewed by Jon.
1927
1928         Fix an assert that would happen when a plug-in tries to load a URL while a provisional load is going.
1929         
1930         * plugins/win/PluginViewWin.cpp:
1931         (WebCore::PluginViewWin::performRequest):
1932         Move document loader check here since we don't start loading until here and a new document load could have started in the meantime.
1933         
1934         (WebCore::PluginViewWin::requestTimerFired):
1935         Don't leak the plugin requests.
1936         
1937         (WebCore::PluginViewWin::load):
1938
1939 2008-01-10  Anders Carlsson  <andersca@apple.com>
1940
1941         Reviewed by John Sullivan.
1942
1943         <rdar://problem/5455889>
1944         REGRESSION: BumperCar crashes when attempting to load a long invalid URL
1945         
1946         Make sure to call FrameLoader::receivedMainResourceError before calling
1947         FrameLoader::didFailToLoad. The call to receivedMainResourceError takes care of
1948         clearing out the provisional document loader so that we won't call the didFail
1949         ResourceLoadDelegate method twice. This also makes us call the FrameLoadDelegate method
1950         didFailPrivisionalLoad before calling the ResourceLoadDelegate method, which Safari 2.0 does.
1951         
1952         * loader/MainResourceLoader.cpp:
1953         (WebCore::MainResourceLoader::receivedError):
1954
1955 2008-01-10  Antti Koivisto  <antti@apple.com>
1956
1957         Reviewed by Adele.
1958
1959         Fix <rdar://problem/5658048>
1960         After <video> has finished playing, dragging the scroller on different location of controller starts to play movie
1961         
1962         - Move to paused state if the playback had ended and the controller is used to seek to earlier time
1963         - Pause video playback during drag so the knob does not constantly try to escape from the mouse pointer
1964
1965         * html/HTMLMediaElement.cpp:
1966         (WebCore::HTMLMediaElement::HTMLMediaElement):
1967         (WebCore::HTMLMediaElement::updateMediaPlayer):
1968         (WebCore::HTMLMediaElement::setPausedInternal):
1969         * html/HTMLMediaElement.h:
1970         * rendering/MediaControlElements.cpp:
1971         (WebCore::MediaControlTimelineElement::defaultEventHandler):
1972
1973 2008-01-10  Alexey Proskuryakov  <ap@webkit.org>
1974
1975         Reviewed by Adam Roben.
1976
1977         <rdar://problem/5667003> fast/dom/xmlhttprequest-html-response-encoding.html is failing
1978
1979         * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::send): Do not disable sniffing for file://
1980         requests, as CFNetwork doesn't perform extension to MIME type mapping then.
1981
1982 2008-01-10  Adam Roben  <aroben@apple.com>
1983
1984         Fixes to allow multiple FrameViews on Windows
1985
1986         Reviewed by Hyatt.
1987
1988         * page/FrameView.cpp:
1989         (WebCore::FrameView::FrameView): Added a new constructor that takes an
1990         IntSize to specify the FrameView's initial size.
1991         (WebCore::FrameView::scheduleRelayout): Added an assertion that our
1992         Document is not in the page cache.
1993         * page/FrameView.h:
1994         * platform/gtk/WidgetGtk.cpp:
1995         (WebCore::Widget::~Widget): Add a warm, fuzzy ASSERT.
1996         * platform/qt/WidgetQt.cpp:
1997         (WebCore::Widget::~Widget): Ditto.
1998         * rendering/RenderWidget.cpp:
1999         (WebCore::RenderWidget::setWidget): Make sure to remove any existing
2000         Widget from the Widget hierarchy before deleting it. One instance
2001         where this is needed is when setWidget is called during FrameView
2002         creation on Windows.
2003
2004 2008-01-10  Alp Toker  <alp@atoker.com>
2005
2006         Include math.h to get ceilf(). Part of the SVG font GTK+ build fix.
2007
2008         * svg/SVGFontFaceElement.cpp:
2009
2010 2008-01-10  Justin Garcia  <justin.garcia@apple.com>
2011
2012         Reviewed by Alice Liu.
2013
2014         <rdar://problem/5658603> Crash in InsertNodeBefore::doUnapply() on Undo in Yahoo Mail
2015         <rdar://problem/5658709> Crash in RenderView::setSelection on Undo in Yahoo Mail
2016         
2017         Make sure we have an updated layout before we perform any editing work.
2018
2019         * editing/EditCommand.cpp:
2020         (WebCore::EditCommand::apply):
2021         (WebCore::EditCommand::unapply):
2022         (WebCore::EditCommand::reapply):
2023
2024 2008-01-10  Luca Bruno  <lethalman88@gmail.com>
2025
2026         Reviewed by Alp Toker.
2027
2028         Back out r29206 which was causing regressions in curl http job
2029         cancellation.
2030
2031         * platform/network/curl/ResourceHandleManager.cpp
2032         (ResourceHandleManager::cancel): 
2033
2034 2008-01-10  Kevin McCullough  <kmccullough@apple.com>
2035
2036         Reviewed by Darin, Sam, and Adam.
2037
2038         - <rdar://problem/5654486> REGRESSION (Safari 3.0.4-TOT): clicking on
2039         - link in gmail message displays JavaScript alert falsely complaining
2040         about pop-up blocking
2041         - When trying to open a new window, we now see if the user gesture 
2042         occurred in the global dynamic object instead of the frame since that is
2043         the only place an event can occur. 
2044
2045         * bindings/js/kjs_window.cpp: - Check the dynamic global object instead
2046         of the frame.
2047         (KJS::allowPopUp):
2048         (KJS::showModalDialog):
2049         (KJS::WindowProtoFuncOpen::callAsFunction):
2050
2051 2008-01-10  David Hyatt  <hyatt@apple.com>
2052
2053         Fix for bug 16247, visibility:hidden not honored when hit testing inline replaced elements.
2054
2055         Reviewed by adele
2056
2057         Added fast/css/visibility-hit-test.html test case.
2058
2059         * rendering/RenderBox.cpp:
2060         (WebCore::RenderBox::nodeAtPoint):
2061
2062 2008-01-10  Lars Knoll  <lars@trolltech.com>
2063
2064         Reviewed by Simon.
2065
2066         rename QWebPageHistory to QWebHistory.
2067
2068         * WebCore.pro:
2069
2070 2008-01-10  Lars Knoll  <lars@trolltech.com>
2071
2072         Reviewed by Simon.
2073
2074         fix the drawing errors that where introduced due to refactoring.
2075
2076         Correctly clip to the rectangle we want to draw in ScrollView::paint().
2077
2078         * platform/qt/ScrollViewQt.cpp:
2079         (WebCore::ScrollView::paint):
2080
2081 2008-01-10  Simon Hausmann  <hausmann@webkit.org>
2082
2083         Reviewed by Lars.
2084
2085         Temporarily disable gzip decompression in qhttp due to a bug.
2086
2087         * platform/network/qt/QNetworkReplyHandler.cpp:
2088         (WebCore::QNetworkReplyHandler::QNetworkReplyHandler):
2089
2090 2008-01-10  Simon Hausmann  <hausmann@webkit.org>
2091
2092         Reviewed by Lars.
2093
2094         http://bugs.webkit.org/show_bug.cgi?id=16588
2095
2096         Added a (last) Frame argument to ResourceHandle::loadResourceSynchronously.
2097         This allows implementing the synchronous loading correctly for the Qt port where the networking
2098         backend is bound to the page.
2099
2100         * loader/FrameLoader.cpp:
2101         (WebCore::FrameLoader::loadResourceSynchronously):
2102         * platform/network/ResourceHandle.h:
2103         * platform/network/cf/ResourceHandleCFNet.cpp:
2104         * platform/network/curl/ResourceHandleCurl.cpp:
2105         * platform/network/mac/ResourceHandleMac.mm:
2106         * platform/network/qt/ResourceHandleQt.cpp:
2107         (WebCore::ResourceHandle::loadResourceSynchronously):
2108
2109 2008-01-10  Kevin Ollivier  <kevino@theolliviers.com>
2110
2111         wx build fix for changes in r29328
2112
2113         * WebCoreSources.bkl:
2114
2115 2008-01-09  Maciej Stachowiak  <mjs@apple.com>
2116
2117         Reviewed by Sam.
2118
2119         - refactor SecurityOrigin in preparation for merging with SecurityOriginData
2120
2121         * platform/SecurityOrigin.cpp:
2122         (WebCore::SecurityOrigin::SecurityOrigin):
2123         (WebCore::SecurityOrigin::create):
2124         (WebCore::SecurityOrigin::createForFrame):
2125         * platform/SecurityOrigin.h:
2126
2127 2008-01-09  Ada Chan  <adachan@apple.com>
2128
2129         Tabs with ctrl, meta, or altgraph modifier key down should not advance focus.
2130
2131         Reviewed by Darin.
2132
2133         Test: fast/forms/tabs-with-modifiers.html
2134
2135         * page/EventHandler.cpp:
2136         (WebCore::EventHandler::defaultKeyboardEventHandler):
2137         (WebCore::EventHandler::defaultTabEventHandler): bail if ctrl, meta, or altgraph key is down.  
2138         Clean up the code a bit.
2139         * page/EventHandler.h:
2140         * page/FocusController.cpp: Remove the advanceFocus() that takes in a KeyboardEvent.  It was
2141         only called in EventHandler::defaultTabEventHandler() but we have cleaned up the code there and
2142         no longer needs it.
2143         * page/FocusController.h:
2144
2145 2008-01-09  Antti Koivisto  <antti@apple.com>
2146
2147         Reviewed by Mitz.
2148
2149         Fix http://bugs.webkit.org/show_bug.cgi?id=16376
2150         <rdar://problem/5665206>
2151         <video> element fails to play frames when navigating back to page (16376)
2152         
2153         Don't make MediaPlayer visible when it is actually in page cache.
2154
2155         * rendering/RenderVideo.cpp:
2156         (WebCore::RenderVideo::updatePlayer):
2157
2158 2008-01-09  Anders Carlsson  <andersca@apple.com>
2159
2160         Reviewed by Darin.
2161
2162         <rdar://problem/5532361> 
2163         CrashTracer: 9840 crashes in Safari at com.apple.JavaScriptCore: KJS::Bindings::CInstance::~CInstance [in-charge deleting] + 35
2164         
2165         Clear the frame's plugin root objects so that they don't outlive the plugin bundle.
2166         
2167         * page/Frame.cpp:
2168         (WebCore::Frame::pageDestroyed):
2169
2170 2008-01-09  John Sullivan  <sullivan@apple.com>
2171
2172         Reviewed by Adam Roben and Anders Carlsson
2173         
2174         - fixed <rdar://problem/5469398> Repro assertion failure in context menu code due to 
2175           missing-but-expected Reload item
2176
2177         * platform/ContextMenu.cpp:
2178         (WebCore::ContextMenu::populate):
2179         use isLoadingInAPISense when deciding whether to include Stop or Reload in context
2180         menu, to match the WebKit API
2181
2182 2008-01-09  Mark Rowe  <mrowe@apple.com>
2183
2184         Fix Windows debug build for opensource developers.
2185
2186         * WebCore.vcproj/QTMovieWin.vcproj: Use the correct library suffix.
2187
2188 2007-10-01  Allan Sandfeld Jensen  <sandfeld@kde.org>
2189
2190         Reworked by Eric, Reviewed by Hyatt.
2191
2192         - fix http://bugs.webkit.org/show_bug.cgi?id=9454
2193         Add support for :lang inheritance and xml:lang support.
2194
2195         Tests: fast/selectors/lang-inheritance.html
2196                fast/selectors/lang-inheritance2.html
2197                fast/selectors/lang-vs-xml-lang.html
2198                fast/selectors/lang-vs-xml-lang-xhtml.xhtml
2199
2200         * css/CSSStyleSelector.cpp:
2201         (WebCore::CSSStyleSelector::canShareStyleWithElement): Do not share style between elements with
2202         different LANG-attribute.
2203         (WebCore::CSSStyleSelector::checkOneSelector): Change :lang() to recursively check the LANG attribute
2204         for all the elements parents and the content-language of the document.
2205         * dom/Document.cpp:
2206         (WebCore::Document::processHttpEquiv): Parse MIME Content-Language
2207         * dom/Document.h:
2208         (WebCore::Document::contentLanguage):
2209         (WebCore::Document::setContentLanguage):
2210
2211 2008-01-08  Timothy Hatcher  <timothy@apple.com>
2212
2213         Reviewed by Brady.
2214
2215         Bug 16678: Unreproducible crash in KJS::JSObject::inherits() after using Web Inspector
2216         http://bugs.webkit.org/show_bug.cgi?id=16678
2217
2218         Add a NULL check for controller before calling JSObjectSetPrivate.
2219
2220         * page/InspectorController.cpp:
2221         (WebCore::InspectorController::~InspectorController):
2222
2223 2008-01-08  Xan Lopez  <xan@gnome.org>
2224
2225         Reviewed by Alp Toker.
2226
2227         http://bugs.webkit.org/show_bug.cgi?id=15610
2228         [GTK] Text rendering using Pango
2229
2230         Use Pango to render Complex path text.
2231
2232         * platform/graphics/gtk/FontGtk.cpp:
2233         (WebCore::utf16_to_utf8):
2234         (WebCore::convertUniCharToUTF8):
2235         (WebCore::setPangoAttributes):
2236         (WebCore::Font::drawGlyphs):
2237         (WebCore::Font::drawComplexText):
2238         (WebCore::Font::floatWidthForComplexText):
2239         (WebCore::Font::offsetForPositionForComplexText):
2240
2241 2008-01-08  Timothy Hatcher  <timothy@apple.com>
2242
2243         Reviewed by Darin Adler.
2244
2245         <rdar://problem/5665860> With the web inspector displayed, a crash occurs
2246         at WebCore::Frame::document() when navigating back to previous page
2247
2248         This fixes the crash, but the inspector was totally broken with back/forward.
2249         So this also fixes back/forward navigation so the right main resource shows
2250         up in the inspector.
2251
2252         * page/InspectorController.cpp:
2253         (WebCore::addSourceToFrame): Add some null checks for the frame when
2254         getting the textEncoding. This was the crash.
2255         (WebCore::InspectorController::addScriptResource): Create a script object
2256         only if needed, and always add it by calling addResource.
2257         (WebCore::InspectorController::didCommitLoad): Check if the loader is 
2258         loading from the page cache, and clear m_mainResource. If the load is
2259         normal, then call addAndUpdateScriptResource with the main resource. 
2260         (WebCore::InspectorController::identifierForInitialRequest): If the load
2261         is from the page cache and the resource is the main resource call
2262         addAndUpdateScriptResource since didCommitLoad did not do it.
2263
2264 2008-01-08  Alp Toker  <alp@atoker.com>
2265
2266         Back out VIDEO by default in the GTK+ qmake build. The build bot
2267         doesn't have the necessary libraries installed.
2268
2269         * WebCore.pro:
2270
2271 2008-01-08  Alp Toker  <alp@atoker.com>
2272
2273         Win build fix for breakage introduced in r29328.
2274
2275         * WebCore.vcproj/WebCore.vcproj:
2276
2277 2008-01-08  Alp Toker  <alp@atoker.com>
2278
2279         Rubber-stamped by Mark Rowe.
2280
2281         Enable VIDEO by default in the GTK+ qmake build.
2282
2283         * WebCore.pro:
2284
2285 2008-01-08  Alp Toker  <alp@atoker.com>
2286
2287         GTK+ VIDEO build fix for breakage introduced in r29328.
2288
2289         Issue noticed by Ori_B.
2290
2291         * GNUmakefile.am:
2292         * WebCore.pro:
2293
2294 2008-01-08  Antti Koivisto  <antti@apple.com>
2295
2296         Reviewed by Darin.
2297         
2298         HTMLAudioElement needs generated constructor. Otherwise video instanceof HTMLAudioElement is true which is 
2299         bit strange.
2300         
2301         Renamed custom constructor JSHTMLAudioElementConstructor to JSAudioConstructor to avoid name clashes.
2302
2303         Test: media/constructors.html
2304
2305         * ChangeLog:
2306         * WebCore.xcodeproj/project.pbxproj:
2307         * bindings/js/JSAudioConstructor.cpp: Copied from WebCore/bindings/js/JSHTMLAudioElementConstructor.cpp.
2308         (WebCore::JSAudioConstructor::JSAudioConstructor):
2309         (WebCore::JSAudioConstructor::implementsConstruct):
2310         (WebCore::JSAudioConstructor::construct):
2311         * bindings/js/JSAudioConstructor.h: Copied from WebCore/bindings/js/JSHTMLAudioElementConstructor.h.
2312         * bindings/js/JSHTMLAudioElementConstructor.cpp: Removed.
2313         * bindings/js/JSHTMLAudioElementConstructor.h: Removed.
2314         * bindings/js/kjs_window.cpp:
2315         (KJS::Window::getValueProperty):
2316         * html/HTMLAudioElement.idl:
2317
2318 2008-01-08  Anders Carlsson  <andersca@apple.com>
2319
2320         Reviewed by Mitz.
2321
2322         Don't add the applet widget to the view, that's done later by RenderApplet.
2323             
2324         * loader/FrameLoader.cpp:
2325         (WebCore::FrameLoader::createJavaAppletWidget):
2326
2327 2008-01-08  Antti Koivisto  <antti@apple.com>
2328
2329         Reviewed by Weinig.
2330         
2331         Add security check for Audio constructor.
2332
2333         * bindings/js/kjs_window.cpp:
2334         (KJS::Window::getValueProperty):
2335
2336 2008-01-08  Timothy Hatcher  <timothy@apple.com>
2337
2338         Reviewed by Adam Roben.
2339
2340         <rdar://problem/5676515> List of scripts and images missing when opening Web Inspector from new window (16567)
2341
2342         InspectorController::didLoadResourceFromMemoryCache was not being called for
2343         resources that loaded from the memory cache that the FrameLoader's client
2344         has already been notified about. This fix always calls the InspectorController
2345         when loading a memory cached resource. No test possible for the Web Inspector.
2346
2347         * loader/DocLoader.cpp:
2348         (WebCore::DocLoader::checkCacheObjectStatus): Moved most of the logic to
2349         FrameLoader::loadedResourceFromMemoryCache so the InspectorController can always be notified.
2350         * loader/FrameLoader.cpp:
2351         (WebCore::FrameLoader::didTellClientAboutLoad): Renamed from didTellBridgeAboutLoad.
2352         (WebCore::FrameLoader::haveToldClientAboutLoad): Renamed from haveToldBridgeAboutLoad.
2353         (WebCore::FrameLoader::loadResourceSynchronously): Call the renamed didTellClientAboutLoad.
2354         (WebCore::FrameLoader::loadedResourceFromMemoryCache): Only takes a CachedResource now.
2355         Always call InspectorController. If the resource's sendResourceLoadCallbacks is false or
2356         didTellClientAboutLoad is true, do an early return. Otherwise call the client and call
2357         didTellClientAboutLoad.
2358         (WebCore::FrameLoader::dispatchDidLoadResourceFromMemoryCache): Removed, work now done
2359         in FrameLoader::loadedResourceFromMemoryCache.
2360         * loader/FrameLoader.h: Renamed {didTell,haveTold}BridgeAboutLoad to {didTell,haveTold}ClientAboutLoad.
2361         Made loadedResourceFromMemoryCache only take a CachedResource. Renamed m_urlsBridgeKnowsAbout to 
2362         m_urlsClientKnowsAbout.
2363         * loader/SubresourceLoader.cpp:
2364         (WebCore::SubresourceLoader::load): Call the renamed didTellClientAboutLoad.
2365
2366 2008-01-08  Dan Bernstein  <mitz@apple.com>
2367
2368         Rubber-stamped by Sam Weinig.
2369
2370         - prefix all member variables in CSSStyleSelector with m_
2371
2372         * css/CSSStyleSelector.cpp:
2373         (WebCore::CSSStyleSelector::CSSStyleSelector):
2374         (WebCore::CSSStyleSelector::init):
2375         (WebCore::CSSStyleSelector::setEncodedURL):
2376         (WebCore::CSSStyleSelector::loadDefaultStyle):
2377         (WebCore::CSSStyleSelector::matchRules):
2378         (WebCore::CSSStyleSelector::matchRulesForList):
2379         (WebCore::CSSStyleSelector::initElementAndPseudoState):
2380         (WebCore::CSSStyleSelector::initForStyleResolve):
2381         (WebCore::CSSStyleSelector::canShareStyleWithElement):
2382         (WebCore::CSSStyleSelector::locateSharedStyle):
2383         (WebCore::CSSStyleSelector::matchUARules):
2384         (WebCore::CSSStyleSelector::styleForElement):
2385         (WebCore::CSSStyleSelector::pseudoStyleForElement):
2386         (WebCore::CSSStyleSelector::updateFont):
2387         (WebCore::CSSStyleSelector::cacheBorderAndBackground):
2388         (WebCore::CSSStyleSelector::checkSelector):
2389         (WebCore::CSSStyleSelector::checkOneSelector):
2390         (WebCore::CSSStyleSelector::applyProperty):
2391         (WebCore::CSSStyleSelector::mapBackgroundImage):
2392         (WebCore::CSSStyleSelector::mapBackgroundSize):
2393         (WebCore::CSSStyleSelector::mapBackgroundXPosition):
2394         (WebCore::CSSStyleSelector::mapBackgroundYPosition):
2395         (WebCore::CSSStyleSelector::checkForTextSizeAdjust):
2396         (WebCore::CSSStyleSelector::getColorFromPrimitiveValue):
2397         * css/CSSStyleSelector.h:
2398         (WebCore::CSSStyleSelector::):
2399         (WebCore::CSSRuleData::CSSRuleData):
2400         (WebCore::CSSRuleDataList::CSSRuleDataList):
2401         (WebCore::CSSRuleDataList::append):
2402         * css/SVGCSSStyleSelector.cpp:
2403         (WebCore::CSSStyleSelector::applySVGProperty):
2404         * rendering/RenderStyle.cpp:
2405         (WebCore::RenderStyle::isStyleAvailable):
2406
2407 2008-01-08  David D. Kilzer  <ddkilzer@apple.com>
2408
2409         Removed unnecessary files from Copy Bundle Resources build phase.
2410
2411         Reviewed by Sam.
2412
2413         * WebCore.xcodeproj/project.pbxproj: Files removed from build phase:
2414         DOMCoreException.idl
2415         EventException.idl
2416         MessageEvent.idl
2417         SVGAElement.idl
2418         SVGAngle.idl
2419         SVGAnimateColorElement.idl
2420         SVGAnimateElement.idl
2421         SVGAnimateTransformElement.idl
2422         SVGAnimatedAngle.idl
2423         SVGAnimatedBoolean.idl
2424         SVGAnimatedEnumeration.idl
2425         SVGAnimatedInteger.idl
2426         SVGAnimatedLength.idl
2427         SVGAnimatedLengthList.idl
2428         SVGAnimatedNumber.idl
2429         SVGAnimatedNumberList.idl
2430         SVGAnimatedPathData.idl
2431         SVGAnimatedPoints.idl
2432         SVGAnimatedPreserveAspectRatio.idl
2433         SVGAnimatedRect.idl
2434         SVGAnimatedString.idl
2435         SVGAnimatedTransformList.idl
2436         SVGAnimationElement.idl
2437         SVGCSSPropertyNames.in
2438         SVGCSSValueKeywords.in
2439         SVGCircleElement.idl
2440         SVGClipPathElement.idl
2441         SVGColor.idl
2442         SVGComponentTransferFunctionElement.idl
2443         SVGCursorElement.idl
2444         SVGDefinitionSrcElement.idl
2445         SVGDefsElement.idl
2446         SVGDescElement.idl
2447         SVGDocument.idl
2448         SVGElement.idl
2449         SVGElementInstance.idl
2450         SVGElementInstanceList.idl
2451         SVGEllipseElement.idl
2452         SVGException.idl
2453         SVGExternalResourcesRequired.idl
2454         SVGFEBlendElement.idl
2455         SVGFEColorMatrixElement.idl
2456         SVGFEComponentTransferElement.idl
2457         SVGFECompositeElement.idl
2458         SVGFEDiffuseLightingElement.idl
2459         SVGFEDisplacementMapElement.idl
2460         SVGFEDistantLightElement.idl
2461         SVGFEFloodElement.idl
2462         SVGFEFuncAElement.idl
2463         SVGFEFuncBElement.idl
2464         SVGFEFuncGElement.idl
2465         SVGFEFuncRElement.idl
2466         SVGFEGaussianBlurElement.idl
2467         SVGFEImageElement.idl
2468         SVGFEMergeElement.idl
2469         SVGFEMergeNodeElement.idl
2470         SVGFEOffsetElement.idl
2471         SVGFEPointLightElement.idl
2472         SVGFESpecularLightingElement.idl
2473         SVGFESpotLightElement.idl
2474         SVGFETileElement.idl
2475         SVGFETurbulenceElement.idl
2476         SVGFilterElement.idl
2477         SVGFilterPrimitiveStandardAttributes.idl
2478         SVGFitToViewBox.idl
2479         SVGFontElement.idl
2480         SVGFontFaceElement.idl
2481         SVGFontFaceFormatElement.idl
2482         SVGFontFaceNameElement.idl
2483         SVGFontFaceSrcElement.idl
2484         SVGFontFaceUriElement.idl
2485         SVGForeignObjectElement.idl
2486         SVGGElement.idl
2487         SVGGlyphElement.idl
2488         SVGGradientElement.idl
2489         SVGImageElement.idl
2490         SVGLangSpace.idl
2491         SVGLength.idl
2492         SVGLengthList.idl
2493         SVGLineElement.idl
2494         SVGLinearGradientElement.idl
2495         SVGLocatable.idl
2496         SVGMarkerElement.idl
2497         SVGMaskElement.idl
2498         SVGMatrix.idl
2499         SVGMetadataElement.idl
2500         SVGMissingGlyphElement.idl
2501         SVGNumber.idl
2502         SVGNumberList.idl
2503         SVGPaint.idl
2504         SVGPathElement.idl
2505         SVGPathSeg.idl
2506         SVGPathSegArcAbs.idl
2507         SVGPathSegArcRel.idl
2508         SVGPathSegClosePath.idl
2509         SVGPathSegCurvetoCubicAbs.idl
2510         SVGPathSegCurvetoCubicRel.idl
2511         SVGPathSegCurvetoCubicSmoothAbs.idl
2512         SVGPathSegCurvetoCubicSmoothRel.idl
2513         SVGPathSegCurvetoQuadraticAbs.idl
2514         SVGPathSegCurvetoQuadraticRel.idl
2515         SVGPathSegCurvetoQuadraticSmoothAbs.idl
2516         SVGPathSegCurvetoQuadraticSmoothRel.idl
2517         SVGPathSegLinetoAbs.idl
2518         SVGPathSegLinetoHorizontalAbs.idl
2519         SVGPathSegLinetoHorizontalRel.idl
2520         SVGPathSegLinetoRel.idl
2521         SVGPathSegLinetoVerticalAbs.idl
2522         SVGPathSegLinetoVerticalRel.idl
2523         SVGPathSegList.idl
2524         SVGPathSegMovetoAbs.idl
2525         SVGPathSegMovetoRel.idl
2526         SVGPatternElement.idl
2527         SVGPoint.idl
2528         SVGPointList.idl
2529         SVGPolygonElement.idl
2530         SVGPolylineElement.idl
2531         SVGPreserveAspectRatio.idl
2532         SVGRadialGradientElement.idl
2533         SVGRect.idl
2534         SVGRectElement.idl
2535         SVGRenderingIntent.idl
2536         SVGSVGElement.idl
2537         SVGScriptElement.idl
2538         SVGSetElement.idl
2539         SVGStopElement.idl
2540         SVGStringList.idl
2541         SVGStylable.idl
2542         SVGStyleElement.idl
2543         SVGSwitchElement.idl
2544         SVGSymbolElement.idl
2545         SVGTRefElement.idl
2546         SVGTSpanElement.idl
2547         SVGTests.idl
2548         SVGTextContentElement.idl
2549         SVGTextElement.idl
2550         SVGTextPathElement.idl
2551         SVGTextPositioningElement.idl
2552         SVGTitleElement.idl
2553         SVGTransform.idl
2554         SVGTransformList.idl
2555         SVGTransformable.idl
2556         SVGURIReference.idl
2557         SVGUnitTypes.idl
2558         SVGUseElement.idl
2559         SVGViewElement.idl
2560         SVGViewSpec.idl
2561         SVGZoomAndPan.idl
2562         SVGZoomEvent.idl
2563         XMLHttpRequestException.idl
2564         XPathException.idl
2565         character-sets.txt
2566         mac-encodings.txt
2567         make-charset-table.pl
2568         svgattrs.in
2569         svgtags.in
2570         xlinkattrs.in
2571
2572 2008-01-08  Luca Bruno  <lethalman88@gmail.com>
2573
2574         Reviewed by Alp Toker.
2575
2576         Support copying the selected URL to the clipboard.
2577
2578         * platform/gtk/PasteboardGtk.cpp:
2579         (WebCore::Pasteboard::writeURL): implemented
2580
2581 2008-01-08  David D. Kilzer  <ddkilzer@webkit.org>
2582
2583         Renamed CharacterData::m_str to m_data
2584
2585         Rubber-stamped by Adam again.
2586
2587         No test cases added since there is no change in behavior.
2588
2589         * dom/CDATASection.cpp:
2590         * dom/CharacterData.cpp:
2591         (WebCore::CharacterData::CharacterData):
2592         (WebCore::CharacterData::setData):
2593         (WebCore::CharacterData::substringData):
2594         (WebCore::CharacterData::appendData):
2595         (WebCore::CharacterData::insertData):
2596         (WebCore::CharacterData::deleteData):
2597         (WebCore::CharacterData::replaceData):
2598         (WebCore::CharacterData::nodeValue):
2599         (WebCore::CharacterData::containsOnlyWhitespace):
2600         (WebCore::CharacterData::dispatchModifiedEvent):
2601         (WebCore::CharacterData::checkCharDataOperation):
2602         (WebCore::CharacterData::dump):
2603         * dom/CharacterData.h:
2604         * dom/Comment.cpp:
2605         * dom/Text.cpp:
2606         (WebCore::Text::splitText):
2607         (WebCore::Text::createRenderer):
2608         (WebCore::Text::recalcStyle):
2609
2610 2008-01-08  Steve Falkenburg  <sfalken@apple.com>
2611
2612         Fix a couple of compiler warnings.
2613         
2614         Reviewed by Mitz.
2615
2616         * platform/win/ThreadingWin.cpp:
2617         * platform/win/UniscribeController.cpp: Remove unused function.
2618         (WebCore::UniscribeController::advance): Fix bogus warning about un-initialized variable.
2619
2620 2008-01-08  Adele Peterson  <adele@apple.com>
2621
2622         Reviewed by Darin.
2623
2624         Fix for <rdar://problem/5674667> fast/forms/slider-mouse-events.html is broken by media control checkin 29257
2625
2626         * rendering/RenderSlider.cpp: (WebCore::HTMLSliderThumbElement::defaultEventHandler):
2627           After fixing a bug in EventHandler to make sure events always go to the capturing node, this bug was exposed.
2628           MouseMove and MouseUp events were going to the thumb element, but not to the slider input element.  
2629           This change makes the input element the capturing node, and then the input element forwards the mouse events to the thumb element.
2630           I also added a missing call to setDefaultHandled for the mousemove event.
2631
2632 2008-01-08  Adele Peterson  <adele@apple.com>
2633
2634         Reviewed by Adam. 
2635
2636         * rendering/RenderThemeSafari.cpp: Use the SafariTheme version number to decide whether or not to
2637         paint the media controls in RenderThemeSafari.
2638
2639 2008-01-08  Oliver Hunt  <oliver@apple.com>
2640
2641         Reviewed by Adele and John.
2642
2643         Fix <rdar://problem/5652740> Crash occurs at WebCore::Widget::getView() after
2644         dragging file into window that contains web page ( http://www.econocraft.com/flood_arch.htm )
2645
2646         We hit this crash if the page reloads between DragController::dragUpdated
2647         and DragController::performDrag, meaning that m_document starts pointing to
2648         a now viewless document.  This is picked up by an assertion in performDrag
2649         which I have now replaced with an assignment given that the assertion is 
2650         invalid -- it is possible for m_document to be changed between dragUpdated
2651         performDrag
2652
2653         * page/DragController.cpp:
2654         (WebCore::DragController::performDrag):
2655
2656 2008-01-08  Alexey Proskuryakov  <ap@webkit.org>
2657
2658         Reviewed by Darin.
2659
2660         <rdar://problem/5659812> CrashTracer: 462 crashes in Safari at com.apple.WebCore:
2661         WebCore::Node::setChanged + 96
2662
2663         Test: fast/dom/cssTarget-crash.html
2664
2665         * dom/Node.cpp: (WebCore::Node::removedFromDocument):
2666         Check to see if the node being removed is currently set as the Document's cssTarget.
2667         If it is, clear the cssTarget to prevent a hanging reference to it.
2668
2669 2008-01-08  Adam Roben  <aroben@apple.com>
2670
2671         * bindings/scripts/CodeGeneratorJS.pm: Touch this so the bindings will
2672         rebuild on Windows now that the media elements are enabled.
2673
2674 2008-01-08  Adam Roben  <aroben@apple.com>
2675
2676         * svg/svgtags.in: Touch this again for the sake of the Windows bots.
2677
2678 2008-01-08  Timothy Hatcher  <timothy@apple.com>
2679
2680         Reviewed by Adam Roben.
2681
2682         Use JSRetainPtr in the Web Inspector everywhere we own a JSStringRef.
2683         Also added some #pragma marks to help find places in the file.
2684
2685         * page/InspectorController.cpp:
2686         (WebCore::callSimpleFunction): Use JSRetainPtr<JSStringRef>.
2687         And return the result of JSObjectCallAsFunction.
2688         (WebCore::search): Use JSRetainPtr<JSStringRef>.
2689         (WebCore::databaseTableNames): Ditto.
2690         (WebCore::localizedStrings): Ditto.
2691         (WebCore::InspectorController::~InspectorController): Ditto.
2692         (WebCore::InspectorController::focusNode): Ditto.
2693         (WebCore::InspectorController::windowScriptObjectAvailable): Ditto.
2694         (WebCore::InspectorController::scriptObjectReady): Ditto.
2695         (WebCore::addHeaders): Ditto.
2696         (WebCore::InspectorController::addScriptResource): Ditto.
2697         (WebCore::InspectorController::removeScriptResource): Ditto.
2698         (WebCore::InspectorController::updateScriptResourceRequest): Ditto.
2699         (WebCore::InspectorController::updateScriptResourceResponse): Ditto.
2700         (WebCore::InspectorController::updateScriptResource): Ditto.
2701         (WebCore::InspectorController::addDatabaseScriptResource): Ditto.
2702         (WebCore::InspectorController::removeDatabaseScriptResource): Ditto.
2703         (WebCore::InspectorController::addScriptConsoleMessage): Ditto.
2704
2705 2008-01-08  Dan Bernstein  <mitz@apple.com>
2706
2707         Rubber-stamped by Sam Weinig.
2708
2709         - rename FontDataBaseClass.{cpp,h} back to FontData.{cpp,h}
2710
2711         * GNUmakefile.am:
2712         * WebCore.pro:
2713         * WebCore.vcproj/WebCore.vcproj:
2714         * WebCore.xcodeproj/project.pbxproj:
2715         * WebCoreSources.bkl:
2716         * editing/Editor.cpp:
2717         * platform/graphics/FontData.cpp: Copied from WebCore/platform/graphics/FontDataBaseClass.cpp.
2718         * platform/graphics/FontData.h: Copied from WebCore/platform/graphics/FontDataBaseClass.h.
2719         * platform/graphics/FontDataBaseClass.cpp: Removed.
2720         * platform/graphics/FontDataBaseClass.h: Removed.
2721         * platform/graphics/SegmentedFontData.h:
2722         * platform/graphics/SimpleFontData.h:
2723
2724 2008-01-08  Dan Bernstein  <mitz@apple.com>
2725
2726         Fix a Wx build error.
2727
2728         * platform/graphics/wx/GlyphMapWx.cpp:
2729         (WebCore::GlyphPage::fill):
2730
2731 2008-01-08  Dan Bernstein  <mitz@apple.com>
2732
2733         Fix a Qt build error.
2734
2735         * platform/graphics/qt/SimpleFontDataQt.cpp:
2736         (WebCore::SimpleFontData::containsCharacters):
2737         (WebCore::SimpleFontData::fontDataForCharacter):
2738         (WebCore::SimpleFontData::isSegmented):
2739
2740 2008-01-08  Adam Roben  <aroben@apple.com>
2741
2742         Windows build fix.
2743
2744         Touch config.h to force a rebuild (apparently changing preprocessor
2745         definitions in the .vcproj doesn't force a rebuild).
2746
2747         * config.h:
2748
2749 2008-01-08  Dan Bernstein  <mitz@apple.com>
2750
2751         Fix a Wx build failure.
2752
2753         * webcore-wx.bkl:
2754
2755 2008-01-08  Dan Bernstein  <mitz@apple.com>
2756
2757         Fix a Qt build failure.
2758
2759         * WebCore.pro:
2760
2761 2008-01-08  John Sullivan  <sullivan@apple.com>
2762
2763         Reviewed by Adam Roben
2764         
2765         - fixed <rdar://problem/5671668> REGRESSION (r28711-r28730): With caret in an empty form field, 
2766           Delete menu item is enabled but shouldn't be
2767
2768         The enabled logic was incorrect for the Delete menu item. To fix this, I added an EditorCommandSource
2769         parameter to the enabled functions so that they can have parallel logic to the execute functions.
2770
2771         * editing/EditorCommand.cpp:
2772         added EditorCommandSource parameter to isEnabled function prototype
2773         (WebCore::enabled):
2774         added unused EditorCommandSource parameter to these isEnabled functions:
2775         (WebCore::enabledAnySelection):
2776         (WebCore::enabledAnySelectionAndMark):
2777         (WebCore::enableCaretInEditableText):
2778         (WebCore::enabledCopy):
2779         (WebCore::enabledCut):
2780
2781         (WebCore::enabledDelete):
2782         new function, uses logic previously used by Delete command for DOM sources; uses logic in enabledCut
2783         for menu source
2784
2785         added unused EditorCommandSource parameter to these isEnabled functions:
2786         (WebCore::enabledInEditableText):
2787         (WebCore::enabledInRichlyEditableText):
2788         (WebCore::enabledPaste):
2789         (WebCore::enabledRangeInEditableText):
2790         (WebCore::enabledRangeInRichlyEditableText):
2791         (WebCore::enabledRedo):
2792         (WebCore::enabledUndo):
2793         
2794         (WebCore::CommandEntry::):
2795         wire up new enabledDelete function as delete function for Delete command
2796         
2797         (WebCore::Editor::Command::isEnabled):
2798         pass EditorCommandSource parameter to isEnabled function
2799
2800 2008-01-08  Adam Roben  <aroben@apple.com>
2801
2802         Visual C++ Express build fix
2803
2804         * WebCore.vcproj/QTMovieWin.vcproj: Explicitly link against user32.lib
2805         and advapi32.lib. VS implicitly links against these, VC++ Express
2806         doesn't.
2807
2808 2008-01-08  Dan Bernstein  <mitz@apple.com>
2809
2810         - add bug number
2811
2812         * platform/graphics/mac/FontCustomPlatformData.cpp:
2813         (WebCore::createFontCustomPlatformData):
2814
2815 2008-01-08  Dan Bernstein  <mitz@apple.com>
2816
2817         Try to fix the Qt build.
2818
2819         * WebCore.pro:
2820
2821 2008-01-08  Nikolas Zimmermann  <zimmermann@kde.org>
2822
2823         Not reviewed. Try to fix Qt builds after Timothy's inspector changes.
2824
2825         * page/inspector/WebKit.qrc:
2826
2827 2008-01-08  Maciej Stachowiak  <mjs@apple.com>
2828
2829         Reviewed by Mark.
2830
2831         - remove duplicate definition of getElementById from HTMLDocument IDL (and ObjC bindings)
2832
2833         * bindings/objc/PublicDOMInterfaces.h:
2834         * html/HTMLDocument.idl:
2835
2836 2008-01-08  David D. Kilzer  <ddkilzer@webkit.org>
2837
2838         Renamed CharacterData::str to m_str to match coding style
2839
2840         Rubber-stamped by Adam.
2841
2842         No test cases added since there is no change in behavior.
2843
2844         * dom/CDATASection.cpp:
2845         * dom/CharacterData.cpp:
2846         (WebCore::CharacterData::CharacterData):
2847         (WebCore::CharacterData::setData):
2848         (WebCore::CharacterData::substringData):
2849         (WebCore::CharacterData::appendData):
2850         (WebCore::CharacterData::insertData):
2851         (WebCore::CharacterData::deleteData):
2852         (WebCore::CharacterData::replaceData):
2853         (WebCore::CharacterData::nodeValue):
2854         (WebCore::CharacterData::containsOnlyWhitespace):
2855         (WebCore::CharacterData::dispatchModifiedEvent):
2856         (WebCore::CharacterData::checkCharDataOperation):
2857         (WebCore::CharacterData::dump):
2858         * dom/CharacterData.h:
2859         * dom/Comment.cpp:
2860         * dom/Text.cpp:
2861         (WebCore::Text::splitText):
2862         (WebCore::Text::createRenderer):
2863         (WebCore::Text::recalcStyle):
2864
2865 2008-01-08  Oliver Hunt  <oliver@apple.com>
2866
2867         Set the ENABLE_SVG_FONTS flag in Windows build, now builds, 
2868         I'm not sure if it just caused the right files to regenerate,
2869         or if there's some configuration weirdness in the non-SVG-fonts
2870         build. 
2871
2872         * WebCore.vcproj/WebCore.vcproj:
2873
2874 2008-01-07  Maciej Stachowiak  <mjs@apple.com>
2875
2876         Reviewed by Brady.
2877
2878         - fixed <rdar://problem/5644300> Back/Forward Cache should not include pages with databases
2879         
2880         Track whether a document has ever opened a database; if so, exclude it from b/f caching (for now)
2881         
2882         * dom/Document.cpp:
2883         (WebCore::Document::Document):
2884         * dom/Document.h:
2885         (WebCore::Document::setHasOpenDatabases):
2886         (WebCore::Document::hasOpenDatabases):
2887         * loader/FrameLoader.cpp:
2888         (WebCore::FrameLoader::canCachePage):
2889         * storage/Database.cpp:
2890         (WebCore::Database::openDatabase):
2891
2892 2008-01-07  Dan Bernstein  <mitz@apple.com>
2893
2894         Reviewed by Oliver Hunt.
2895
2896         - fix leaks seen on the build bot
2897
2898         * css/CSSFontSelector.cpp:
2899         (WebCore::CSSFontSelector::addFontFaceRule): Avoid creating a
2900         CSSFontFaceSource for SVG font-face elements going into an
2901         SVGCSSFontFace because it just leaks them. Avoid adding SVG font-
2902         face elements to a CSSFontFace because it will not work as expected.
2903
2904 2008-01-07  Mark Rowe  <mrowe@apple.com>
2905
2906         Tiger build fix.
2907
2908         * platform/graphics/mac/FontCustomPlatformData.cpp:
2909         (WebCore::createFontCustomPlatformData): Only include this code on Leopard.
2910         It's not needed on Tiger, and breaks the build.
2911
2912 2008-01-07  Antti Koivisto  <antti@apple.com>
2913
2914         Reviewed by Steve.
2915
2916         Re-enable media support in Windows build.
2917
2918         * WebCore.vcproj/QTMovieWin.vcproj:
2919         * WebCore.vcproj/WebCore.vcproj:
2920         * WebCore.vcproj/build-generated-files.sh:
2921
2922 2008-01-07  Steve Falkenburg  <sfalken@apple.com>
2923
2924         Add version resource to QTMovieWin.dll
2925         
2926         Reviewed by Adam.
2927
2928         * WebCore.vcproj/PRODUCTVERSION: Copied from ../WebKit/win/WebKit.vcproj/PRODUCTVERSION.
2929         * WebCore.vcproj/QTMovieWin.rc: Added.
2930         * WebCore.vcproj/QTMovieWin.vcproj:
2931         * WebCore.vcproj/VERSION: Copied from ../WebKit/win/WebKit.vcproj/VERSION.
2932         * WebCore.vcproj/auto-version.sh: Copied from ../WebKit/win/WebKit.vcproj/auto-version.sh.
2933
2934 2008-01-07  Dan Bernstein  <mitz@apple.com>
2935
2936         Build fix.
2937
2938         * platform/graphics/qt/FontCustomPlatformData.cpp:
2939         (WebCore::FontCustomPlatformData::~FontCustomPlatformData): Added.
2940         Calls QFontDatabase::removeApplicationFont().
2941         * platform/graphics/qt/FontCustomPlatformData.h:
2942         * platform/graphics/qt/GlyphPageTreeNodeQt.cpp:
2943         (WebCore::GlyphPageTreeNode::pruneTreeCustomFontData): Removed the
2944         implementation because Qt does not use the WebCore glyph cache.
2945
2946 2008-01-07  Dan Bernstein  <mitz@apple.com>
2947
2948         Reviewed by Oliver Hunt.
2949
2950         - fix an assertion failure in svg/W3C-SVG-1.1/fonts-elem-03-b.svg on
2951           Tiger and multiple SVG layout test failures on Leopard.
2952
2953         * css/CSSSegmentedFontFace.cpp:
2954         (WebCore::CSSSegmentedFontFace::getFontData): Avoid returning an
2955         empty SegmentedFontData.
2956         * platform/graphics/mac/FontCustomPlatformData.cpp:
2957         (WebCore::createFontCustomPlatformData): Avoid creating a font that
2958         contains no glyphs. On Leopard, ATS might create such a font given
2959         data in an unsupported format (such as SVG).
2960
2961 2008-01-07  Steve Falkenburg  <sfalken@apple.com>
2962
2963         Build fix.
2964
2965         * WebCore.vcproj/WebCore.sln:
2966         * WebCore.vcproj/WebCore.submit.sln:
2967
2968 2008-01-07  Oliver Hunt  <oliver@apple.com>
2969
2970         Reviewed by Niko.
2971
2972         Fix painting of SVG <image> when the image must be scaled to retain aspect ratio
2973
2974         Test: svg/custom/image-with-aspect-ratio-stretch.svg
2975
2976         * rendering/RenderSVGImage.cpp:
2977         (WebCore::RenderSVGImage::adjustRectsForAspectRatio):
2978
2979 2008-01-07  Dan Bernstein  <mitz@apple.com>
2980
2981         Build fix.
2982
2983         * platform/graphics/qt/GlyphPageTreeNodeQt.cpp:
2984         (WebCore::GlyphPageTreeNode::pruneTreeCustomFontData):
2985
2986 2008-01-07  Adele Peterson  <adele@apple.com>
2987
2988         Add missing newline.
2989
2990         * rendering/MediaControlElements.cpp:
2991
2992 2008-01-07  Jon Honeycutt  <jhoneycutt@apple.com>
2993
2994         Reviewed by Hyatt.
2995
2996         <rdar://problem/5673489> Safari does not render windowless plugins in an
2997         iframe when opacity < 1.0
2998
2999         Plugins in transparency layers handle their own world transforms, so
3000         only apply the horizontal/vertical transform if we are not in a
3001         transparency layer.
3002
3003         * platform/graphics/GraphicsContext.h: Add a Windows-platform-only
3004         inTransparencyLayer() function
3005         * platform/win/GraphicsContextWin.cpp:
3006         (WebCore::GraphicsContext::getWindowsContext): Use inTransparencyLayer()
3007         (WebCore::GraphicsContext::inTransparencyLayer):
3008         (WebCore::GraphicsContext::releaseWindowsContext): Use
3009         inTransparencyLayer()
3010         * plugins/win/PluginViewWin.cpp:
3011         (WebCore::PluginViewWin::paint): When retrieving the HDC, use the rect
3012         relative to the window. Pass m_isTransparent to
3013         get/releaseWindowsContext(). Only set the world transform if we are not
3014         in a transparency layer.
3015
3016 2008-01-07  Adele Peterson  <adele@apple.com>
3017
3018         Build fix.  Need to wrap these classes in #if ENABLE(VIDEO)
3019
3020         * rendering/MediaControlElements.cpp:
3021         * rendering/MediaControlElements.h:
3022
3023 2008-01-07  Nikolas Zimmermann  <zimmermann@kde.org>
3024
3025         Reviewed by Mark.
3026
3027         Enable SVG_FONTS by default.
3028
3029         * Configurations/WebCore.xcconfig:
3030         * WebCore.vcproj/build-generated-files.sh:
3031
3032 2008-01-07  Dan Bernstein  <mitz@apple.com>
3033
3034         Build fix.
3035
3036         * platform/graphics/qt/SimpleFontDataQt.cpp:
3037         (WebCore::SimpleFontData::SimpleFontData):
3038         (WebCore::SimpleFontData::~SimpleFontData):
3039
3040 2008-01-07  Adam Barth  <hk9565@gmail.com>
3041
3042         Reviewed by Sam Weinig
3043
3044         Fixes: http://bugs.webkit.org/show_bug.cgi?id=16523
3045         <rdar://problem/5657447>
3046
3047         When a frame is created with the URL "about:blank" or "", it should
3048         inherit its SecurityOrigin from its opener.  However, once it has
3049         decided on that SecurityOrigin, it should not change its mind.
3050         Prior to this patch, several events could induce the frame to change
3051         its SecurityOrigin, permitting an attacker to inject script into an
3052         arbitrary SecurityOrigin.
3053
3054         This patch makes several changes:
3055
3056         1) Documents refuse to change from one SecurityOrigin to another
3057            unless explicitly instructed to do so.
3058
3059         2) Navigating to a JavaScript URL that produces a value
3060            preserves the current SecurityOrigin explicitly instead of
3061            relying on the URL to preserve the origin (which fails for
3062            about:blank URLs and SecurityOrigins with document.domain set).
3063
3064            Ideally, we should not preserve the URL at all.  Instead, the
3065            frame's URL should be the JavaScript URL, as in Firefox, but this
3066            would require changes that are too risky for this patch.  I'll
3067            file this as a separate issue.
3068
3069         3) Various methods of navigating to JavaScript URLs were not
3070            properly handling JavaScript that returned a value (and should
3071            therefore replace the current document).  This patch unifies
3072            those code paths with the path that works.
3073
3074            There are still a handful of bugs relating to the handling of
3075            JavaScript URLs, but I'll file those as separate issues.
3076
3077         Tests: http/tests/security/aboutBlank/xss-DENIED-navigate-opener-document-write.html
3078                http/tests/security/aboutBlank/xss-DENIED-navigate-opener-javascript-url.html
3079                http/tests/security/aboutBlank/xss-DENIED-set-opener.html
3080
3081         * dom/Document.cpp:
3082         (WebCore::Document::initSecurityOrigin):
3083         * dom/Document.h:
3084         (WebCore::Document::setSecurityOrigin):
3085         * loader/FrameLoader.cpp:
3086         (WebCore::FrameLoader::changeLocation):
3087         (WebCore::FrameLoader::urlSelected):
3088         (WebCore::FrameLoader::requestFrame):
3089         (WebCore::FrameLoader::submitForm):
3090         (WebCore::FrameLoader::executeIfJavaScriptURL):
3091         (WebCore::FrameLoader::begin):
3092         * loader/FrameLoader.h:
3093         * platform/SecurityOrigin.cpp:
3094         (WebCore::SecurityOrigin::setForURL):
3095         (WebCore::SecurityOrigin::createForFrame):
3096         * platform/SecurityOrigin.h:
3097
3098 2008-01-07  Adele Peterson  <adele@apple.com>
3099
3100         Forgot to check in these changes in my last checkin.
3101
3102         * rendering/RenderThemeSafari.cpp:
3103
3104 2008-01-07  Dan Bernstein  <mitz@apple.com>
3105
3106         Build fixes.
3107
3108         * WebCore.pro:
3109         * platform/graphics/qt/FontCacheQt.cpp:
3110         (WebCore::FontCache::getCachedFontData):
3111
3112 2008-01-07  Timothy Hatcher  <timothy@apple.com>
3113
3114         Reviewed by John Sullivan.
3115
3116         <rdar://problem/5674119> Make the Web Inspector toolbar the normal size when not docked
3117
3118         * page/inspector/inspector.css: Changed CSS rules to have the toolbar and buttons be
3119           normal height when not docked, and small when docked. Also added some cursor properties
3120           prevent showing the text cursor over areas that are not selectable.
3121         * page/inspector/Images: A few images added and old ones removed or renamed.
3122
3123 2008-01-07  Alp Toker  <alp@atoker.com>
3124
3125         Prospective GTK+ autotools/qmake VIDEO build fix for breakage
3126         introduced in r29257.
3127
3128         * GNUmakefile.am:
3129         * WebCore.pro:
3130
3131 2008-01-07  Nikolas Zimmermann  <zimmermann@kde.org>
3132
3133         Reviewed by Oliver.
3134
3135         Build fix affecting all builds - again related to the unicode-range addition.
3136
3137         * css/CSSFontSelector.cpp:
3138         (WebCore::CSSFontSelector::addFontFaceRule):
3139         * css/SVGCSSFontFace.cpp:
3140         (WebCore::SVGCSSFontFace::SVGCSSFontFace):
3141         * css/SVGCSSFontFace.h:
3142         * rendering/RenderSVGText.cpp:
3143         * svg/SVGFont.cpp:
3144         (WebCore::svgFontAndFontFaceElementForFontData):
3145         (WebCore::floatWidthMissingGlyphCallback):
3146         (WebCore::drawTextMissingGlyphCallback):
3147         * svg/SVGFontFaceElement.cpp:
3148
3149 2008-01-07  Adele Peterson  <adele@apple.com>
3150
3151         Reviewed by Antti, Adam, and Mitz.
3152
3153         WebCore part of fix for 
3154         <rdar://problem/5619073> Updated look for <video> controls
3155         <rdar://problem/5619057> Add volume control to video controls
3156
3157         * WebCore.base.exp: Added symbols for WebKitSystemInterface drawing methods.
3158         * WebCore.xcodeproj/project.pbxproj: Added MediaControlElements.h/cpp
3159         * WebCore.vcproj/WebCore.vcproj: ditto.
3160
3161         * css/CSSPrimitiveValueMappings.h: (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Added cases for new appearances.
3162         * css/CSSSelector.cpp: (WebCore::CSSSelector::extractPseudoType): Added cases for new types.
3163         * css/CSSSelector.h: (WebCore::CSSSelector::): Added new pseudo elements.
3164         * css/CSSStyleSelector.cpp: (WebCore::CSSStyleSelector::checkOneSelector): ditto.
3165         * css/CSSValueKeywords.in: Added keywords for new control appearance styles.
3166         * css/html4.css: Added new styles for new controls.
3167
3168         * html/HTMLMediaElement.cpp: (WebCore::HTMLMediaElement::canPlay): Added. Takes loading state into account.
3169         * html/HTMLMediaElement.h:
3170
3171         * page/EventHandler.cpp: (WebCore::EventHandler::updateMouseEventTargetNode): Make sure the events always go to the capturing node, if there is one.
3172
3173         * platform/mac/WebCoreSystemInterface.h: Added drawing methods for controls.
3174         * platform/mac/WebCoreSystemInterface.mm: ditto.
3175
3176         * rendering/MediaControlElements.cpp: Added.
3177         (WebCore::MediaControlShadowRootElement::MediaControlShadowRootElement): Moved from RenderMedia.  Made this relatively positioned, instead of absolute.
3178         (WebCore::MediaControlInputElement::MediaControlInputElement): Moved from RenderMedia.  Removed call to updateFromElement, 
3179          since its too early to do this here, and causes crashes for the slider.
3180         (WebCore::MediaControlInputElement::attachToParent): Moved from RenderMedia.
3181         (WebCore::MediaControlInputElement::update): ditto.
3182         (WebCore::MediaControlMuteButtonElement::MediaControlMuteButtonElement): Added.
3183         (WebCore::MediaControlMuteButtonElement::defaultEventHandler): ditto.
3184         (WebCore::MediaControlPlayButtonElement::MediaControlPlayButtonElement): Moved from RenderMedia.
3185         (WebCore::MediaControlPlayButtonElement::defaultEventHandler): ditto.
3186         (WebCore::MediaControlSeekButtonElement::MediaControlSeekButtonElement): Added.
3187         (WebCore::MediaControlSeekButtonElement::defaultEventHandler): ditto.
3188         (WebCore::MediaControlSeekButtonElement::seekTimerFired): ditto.
3189         (WebCore::MediaControlTimelineElement::MediaControlTimelineElement): Moved from RenderMedia.
3190         (WebCore::MediaControlTimelineElement::defaultEventHandler): ditto.
3191         (WebCore::MediaControlTimelineElement::update): ditto. 
3192         (WebCore::MediaControlFullscreenButtonElement::MediaControlFullscreenButtonElement): Added.
3193         (WebCore::MediaControlFullscreenButtonElement::defaultEventHandler): ditto.
3194         * rendering/MediaControlElements.h: Added. Moved from RenderMedia.
3195         (WebCore::MediaControlShadowRootElement::isShadowNode):
3196         (WebCore::MediaControlShadowRootElement::shadowParentNode):
3197         (WebCore::RenderMediaControlShadowRoot::RenderMediaControlShadowRoot):
3198         (WebCore::RenderMediaControlShadowRoot::setParent):
3199
3200         * rendering/RenderMedia.cpp: Moved control element classes to MediaControlElements files.
3201         (WebCore::RenderMedia::RenderMedia): No need to initialize RefPtrs.
3202         (WebCore::RenderMedia::layout): Set the position for the controlsRenderer.
3203         (WebCore::RenderMedia::createPanel): Added nil check for the renderer.
3204         (WebCore::RenderMedia::createMuteButton): Added.
3205         (WebCore::RenderMedia::createSeekBackButton): ditto.
3206         (WebCore::RenderMedia::createSeekForwardButton): ditto.
3207         (WebCore::RenderMedia::createTimeDisplay): Added nil check for the renderer.
3208         (WebCore::RenderMedia::createFullscreenButton): Added.
3209         (WebCore::RenderMedia::updateControls): Create, delete, and update new controls when appropriate.
3210         (WebCore::RenderMedia::updateControlVisibility): Don't fade controls for audio controls. 
3211         (WebCore::RenderMedia::forwardEvent): Forward events for new controls.
3212         * rendering/RenderMedia.h: Added new methods for creating new controls.
3213
3214         * rendering/RenderObject.cpp: (WebCore::RenderObject::containingBlock): Updated special case for media elements, which are replaced elements, 
3215           but also can contain children (the controls' container) that may need to look for the containing block.
3216
3217         * rendering/RenderSlider.cpp: (WebCore::RenderSlider::createThumbStyle): Added case for MediaSliderAppearance.
3218
3219         * rendering/RenderStyle.h: Added appearance constants and pseudo ids for new controls.
3220         (WebCore::):
3221         (WebCore::RenderStyle::):
3222
3223         * rendering/RenderTheme.cpp:
3224         (WebCore::RenderTheme::adjustStyle): Added cases for new appearances.
3225         (WebCore::RenderTheme::paint): ditto.
3226         * rendering/RenderTheme.h: Added new methods for painting new appearances.
3227         (WebCore::RenderTheme::paintMediaBackground):
3228         (WebCore::RenderTheme::paintMediaFullscreenButton):
3229         (WebCore::RenderTheme::paintMediaPlayButton):
3230         (WebCore::RenderTheme::paintMediaMuteButton):
3231         (WebCore::RenderTheme::paintMediaSeekBackButton):
3232         (WebCore::RenderTheme::paintMediaSeekForwardButton):
3233         (WebCore::RenderTheme::paintMediaSliderThumb):
3234         * rendering/RenderThemeMac.h:
3235         * rendering/RenderThemeMac.mm:
3236         (WebCore::RenderThemeMac::RenderThemeMac): Initialize m_mediaControlBackgroundImage.
3237         (WebCore::RenderThemeMac::~RenderThemeMac): Delete m_mediaControlBackgroundImage.
3238         (WebCore::RenderThemeMac::paintCapsLockIndicator): Use LocalCurrentGraphicsContext here too, since we use it in all other painting methods.
3239         (WebCore::RenderThemeMac::paintSliderTrack): Added case for MediaSliderAppearance.
3240         (WebCore::RenderThemeMac::adjustSliderThumbSize): Added case for MediaSliderThumbAppearance.
3241         (WebCore::RenderThemeMac::paintMediaBackground): Draws the new artwork for the controls.
3242         (WebCore::RenderThemeMac::paintMediaFullscreenButton): ditto.
3243         (WebCore::RenderThemeMac::paintMediaMuteButton): ditto.
3244         (WebCore::RenderThemeMac::paintMediaPlayButton): ditto.
3245         (WebCore::RenderThemeMac::paintMediaSeekBackButton): ditto.
3246         (WebCore::RenderThemeMac::paintMediaSeekForwardButton): ditto.
3247         (WebCore::RenderThemeMac::paintMediaSliderThumb): ditto.
3248         * rendering/RenderThemeSafari.cpp: Draws the new artwork on Windows.
3249         (WebCore::RenderThemeSafari::paintSliderTrack):
3250         (WebCore::RenderThemeSafari::adjustSliderThumbSize):
3251         (WebCore::RenderThemeSafari::paintMediaBackground):
3252         (WebCore::RenderThemeSafari::paintMediaFullscreenButton):
3253         (WebCore::RenderThemeSafari::paintMediaMuteButton):
3254         (WebCore::RenderThemeSafari::paintMediaPlayButton):
3255         (WebCore::RenderThemeSafari::paintMediaSeekBackButton):
3256         (WebCore::RenderThemeSafari::paintMediaSeekForwardButton):
3257         (WebCore::RenderThemeSafari::paintMediaSliderThumb):
3258         * rendering/RenderThemeSafari.h:
3259
3260 2008-01-07  Timothy Hatcher  <timothy@apple.com>
3261
3262         Reviewed by Darin Adler.
3263
3264         Fix ASSERTION FAILED: dstOffset + srcSegmentLength == static_cast<int>(data.size())
3265         when the replacment string is a different length.
3266
3267         * platform/text/StringImpl.cpp:
3268         (WebCore::StringImpl::replace): Move the parenthesis to be around only the subtraction in
3269         the Vector size calculation, correcting the order of math operations.
3270
3271 2008-01-07  Nikolas Zimmermann  <zimmermann@kde.org>
3272
3273         Reviewed by Eric. Hopefully fix build with mac tiger after the unicode-range addition. NSInteger not available there.
3274
3275         * platform/graphics/mac/FontCacheMac.mm:
3276
3277 2008-01-07  Nikolas Zimmermann  <zimmermann@kde.org>
3278
3279         Reviewed by Oliver. Fix build error introduced by Dan's unicode-range support patch & enabling SVG_FONTS by default.
3280
3281         * css/CSSFontSelector.cpp:
3282         (WebCore::CSSFontSelector::getFontData):
3283
3284 2008-01-07  Nikolas Zimmermann  <zimmermann@kde.org>
3285
3286         Not reviewed. Next try to fix wx/mac leopard build.
3287
3288         * css/CSSFontSelector.cpp: Need to wrap a SVG* include in ENABLE(SVG) blocks, as this port doesn't build this generated file.
3289         * svg/SVGFontFaceElement.cpp:
3290         (WebCore::SVGFontFaceElement::createFontData): Fix double<->float conversion issue.
3291         * webcore-base.bkl: Undo svg/ include.
3292
3293 2008-01-07  Dan Bernstein  <mitz@apple.com>
3294
3295         Reviewed by Dave Hyatt.
3296
3297         - <rdar://problem/5665216> Support the unicode-range property in @font-face rules
3298
3299         * GNUmakefile.am:
3300         * WebCore.pro:
3301         * WebCore.vcproj/WebCore.vcproj:
3302         * WebCore.xcodeproj/project.pbxproj:
3303         * WebCoreSources.bkl:
3304         * bindings/objc/DOM.mm:
3305         * bridge/mac/WebCoreAXObject.mm:
3306         * css/CSSComputedStyleDeclaration.cpp:
3307         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3308         * css/CSSFontFace.cpp:
3309         (WebCore::CSSFontFace::fontLoaded): Changed to call the owning segmented
3310         font face.
3311         (WebCore::CSSFontFace::getFontData):
3312         * css/CSSFontFace.h:
3313         (WebCore::CSSFontFace::CSSFontFace):
3314         (WebCore::CSSFontFace::setSegmentedFontFace):
3315         * css/CSSFontFaceSource.cpp:
3316         (WebCore::CSSFontFaceSource::pruneTable): Removed the calls to
3317         GlyphPageTreeNode::pruneTreeCustomFontData because the fonts in the
3318         font table are not exposed in the glyph page tree. Only the segmented
3319         font is, and that is taken care of by the segmented font face.
3320         (WebCore::CSSFontFaceSource::getFontData):
3321         * css/CSSFontFaceSource.h:
3322         * css/CSSFontSelector.cpp:
3323         (WebCore::CSSFontSelector::addFontFaceRule): Changed to collect
3324         @font-face rules with the same family and traits into a single
3325         segmented font face, instead of just retaining the most recent one.
3326         (WebCore::CSSFontSelector::fontLoaded):
3327         (WebCore::CSSFontSelector::getFontData):
3328         * css/CSSFontSelector.h:
3329         * css/CSSGrammar.y:
3330         * css/CSSParser.cpp:
3331         (WebCore::CSSParser::parseValue):
3332         (WebCore::CSSParser::parseFontFaceUnicodeRange): Added. Parses a unicode
3333         range value.
3334         * css/CSSParser.h:
3335         * css/CSSPrimitiveValue.h:
3336         (WebCore::CSSPrimitiveValue::):
3337         * css/CSSPropertyNames.in:
3338         * css/CSSSegmentedFontFace.cpp: Added.
3339         (WebCore::CSSSegmentedFontFace::CSSSegmentedFontFace):
3340         (WebCore::CSSSegmentedFontFace::~CSSSegmentedFontFace):
3341         (WebCore::CSSSegmentedFontFace::pruneTable):
3342         (WebCore::CSSSegmentedFontFace::isLoaded):
3343         (WebCore::CSSSegmentedFontFace::isValid):
3344         (WebCore::CSSSegmentedFontFace::fontLoaded):
3345         (WebCore::CSSSegmentedFontFace::overlayRange):
3346         (WebCore::CSSSegmentedFontFace::getFontData):
3347         * css/CSSSegmentedFontFace.h: Added.
3348         (WebCore::FontFaceRange::FontFaceRange):
3349         (WebCore::FontFaceRange::from):
3350         (WebCore::FontFaceRange::to):
3351         (WebCore::FontFaceRange::fontFace):
3352         (WebCore::CSSSegmentedFontFace::fontSelector):
3353         * css/CSSStyleSelector.cpp:
3354         (WebCore::CSSStyleSelector::applyProperty):
3355         * css/CSSUnicodeRangeValue.cpp: Added.
3356         (WebCore::CSSUnicodeRangeValue::~CSSUnicodeRangeValue):
3357         (WebCore::CSSUnicodeRangeValue::cssText):
3358         * css/CSSUnicodeRangeValue.h: Added.
3359         (WebCore::CSSUnicodeRangeValue::CSSUnicodeRangeValue):
3360         (WebCore::CSSUnicodeRangeValue::from):
3361         (WebCore::CSSUnicodeRangeValue::to):
3362         * css/SVGCSSFontFace.cpp:
3363         (WebCore::SVGCSSFontFace::getFontData):
3364         * css/SVGCSSFontFace.h:
3365         * editing/Editor.cpp:
3366         (WebCore::Editor::fontForSelection):
3367         * editing/Editor.h:
3368         * page/mac/FrameMac.mm:
3369         * page/mac/WebCoreFrameBridge.mm:
3370         (-[WebCoreFrameBridge fontForSelection:]):
3371         * platform/graphics/Font.cpp:
3372         (WebCore::WidthIterator::advance):
3373         (WebCore::Font::glyphDataForCharacter):
3374         (WebCore::Font::primaryFont): Changed to return the simple font data
3375         used for the space character.
3376         (WebCore::Font::fontDataAt):
3377         (WebCore::Font::fontDataForCharacters):
3378         (WebCore::Font::drawGlyphBuffer):
3379         * platform/graphics/Font.h:
3380         * platform/graphics/FontCache.cpp:
3381         (WebCore::FontCache::getCachedFontData):
3382         (WebCore::FontCache::getFontData):
3383         * platform/graphics/FontCache.h:
3384         * platform/graphics/FontData.cpp: Renamed to SimpleFontData.cpp
3385         * platform/graphics/FontData.h: Renamed to SimpleFontData.cpp.
3386         * platform/graphics/FontDataBaseClass.cpp: Added. This will be renamed
3387         FontData.cpp.
3388         (WebCore::FontData::~FontData):
3389         * platform/graphics/FontDataBaseClass.h: Added. This will be renamed
3390         FontData.h.
3391         * platform/graphics/FontFallbackList.cpp:
3392         (WebCore::FontFallbackList::determinePitch):
3393         (WebCore::FontFallbackList::fontDataAt):
3394         (WebCore::FontFallbackList::fontDataForCharacters):
3395         * platform/graphics/FontFallbackList.h:
3396         (WebCore::FontFallbackList::primaryFont):
3397         * platform/graphics/FontSelector.h:
3398         * platform/graphics/GlyphBuffer.h:
3399         (WebCore::GlyphBuffer::fontDataAt):
3400         (WebCore::GlyphBuffer::swap):
3401         (WebCore::GlyphBuffer::add):
3402         * platform/graphics/GlyphPageTreeNode.cpp:
3403         (WebCore::GlyphPageTreeNode::pruneTreeCustomFontData):
3404         (WebCore::GlyphPageTreeNode::initializePage): Added code to initialize
3405         pages for segmented font data.
3406         (WebCore::GlyphPageTreeNode::getChild):
3407         (WebCore::GlyphPageTreeNode::pruneCustomFontData):
3408         * platform/graphics/GlyphPageTreeNode.h:
3409         (WebCore::GlyphPage::setGlyphDataForCharacter):
3410         (WebCore::GlyphPage::setGlyphDataForIndex):
3411         (WebCore::GlyphPageTreeNode::getRootChild):
3412         * platform/graphics/SegmentedFontData.cpp: Added.
3413         (WebCore::SegmentedFontData::~SegmentedFontData):
3414         (WebCore::SegmentedFontData::fontDataForCharacter):
3415         (WebCore::SegmentedFontData::containsCharacters):
3416         (WebCore::SegmentedFontData::isCustomFont):
3417         (WebCore::SegmentedFontData::isLoading):
3418         (WebCore::SegmentedFontData::isSegmented):
3419         * platform/graphics/SegmentedFontData.h: Added.
3420         (WebCore::FontDataRange::FontDataRange):
3421         (WebCore::FontDataRange::from):
3422         (WebCore::FontDataRange::to):
3423         (WebCore::FontDataRange::fontData):
3424         (WebCore::SegmentedFontData::appendRange):
3425         (WebCore::SegmentedFontData::numRanges):
3426         (WebCore::SegmentedFontData::rangeAt):
3427         * platform/graphics/SimpleFontData.cpp: Copied from WebCore/platform/graphics/FontData.cpp.
3428         (WebCore::SimpleFontData::SimpleFontData):
3429         (WebCore::SimpleFontData::~SimpleFontData):
3430         (WebCore::SimpleFontData::ascent):
3431         (WebCore::SimpleFontData::descent):
3432         (WebCore::SimpleFontData::widthForGlyph):
3433         (WebCore::SimpleFontData::fontDataForCharacter):
3434         (WebCore::SimpleFontData::isSegmented):
3435         * platform/graphics/SimpleFontData.h: Copied from WebCore/platform/graphics/FontData.h.
3436         (WebCore::SimpleFontData::isCustomFont):
3437         (WebCore::SimpleFontData::isLoading):
3438         * platform/graphics/cairo/GraphicsContextCairo.cpp:
3439         (WebCore::GraphicsContext::setPlatformFont):
3440         * platform/graphics/gtk/FontCacheGtk.cpp:
3441         (WebCore::FontCache::getFontDataForCharacters):
3442         * platform/graphics/gtk/FontDataGtk.cpp: Renamed to
3443         SimpleFontDataGtk.cpp.
3444         * platform/graphics/gtk/FontGtk.cpp:
3445         (WebCore::Font::drawGlyphs):
3446         * platform/graphics/gtk/GlyphPageTreeNodeGtk.cpp:
3447         (WebCore::GlyphPage::fill):
3448         * platform/graphics/gtk/SimpleFontDataGtk.cpp: Copied from WebCore/platform/graphics/gtk/FontDataGtk.cpp.
3449         (WebCore::SimpleFontData::platformInit):
3450         (WebCore::SimpleFontData::platformDestroy):
3451         (WebCore::SimpleFontData::smallCapsFontData):
3452         (WebCore::SimpleFontData::containsCharacters):
3453         (WebCore::SimpleFontData::determinePitch):
3454         (WebCore::SimpleFontData::platformWidthForGlyph):
3455         (WebCore::SimpleFontData::setFont):
3456         * platform/graphics/mac/FontCacheMac.mm:
3457         (WebCore::FontCache::getFontDataForCharacters):
3458         * platform/graphics/mac/FontDataMac.mm: Renamed to SimpleFontDataMac.mm.
3459         * platform/graphics/mac/FontMac.mm:
3460         (WebCore::initializeATSUStyle):
3461         (WebCore::overrideLayoutOperation):
3462         (WebCore::ATSULayoutParameters::initialize):
3463         (WebCore::Font::drawGlyphs):
3464         * platform/graphics/mac/GlyphPageTreeNodeMac.cpp:
3465         (WebCore::GlyphPage::fill):
3466         * platform/graphics/mac/SimpleFontDataMac.mm: Copied from WebCore/platform/graphics/mac/FontDataMac.mm.
3467         (WebCore::initFontData):
3468         (WebCore::SimpleFontData::platformInit):
3469         (WebCore::SimpleFontData::platformDestroy):
3470         (WebCore::SimpleFontData::smallCapsFontData):
3471         (WebCore::SimpleFontData::containsCharacters):
3472         (WebCore::SimpleFontData::determinePitch):
3473         (WebCore::SimpleFontData::platformWidthForGlyph):
3474         (WebCore::SimpleFontData::checkShapesArabic):
3475         * platform/graphics/qt/FontDataQt.cpp: Renamed to SimpleFontDataQt.cpp.
3476         * platform/graphics/qt/GlyphPageTreeNodeQt.cpp:
3477         (WebCore::GlyphPageTreeNode::pruneTreeCustomFontData):
3478         * platform/graphics/qt/SimpleFontDataQt.cpp: Copied from WebCore/platform/graphics/qt/FontDataQt.cpp.
3479         * platform/graphics/win/FontCacheWin.cpp:
3480         (WebCore::FontCache::getFontDataForCharacters):
3481         * platform/graphics/win/FontDataWin.cpp: Renamed to
3482         SimpleFontDataWin.cpp.
3483         * platform/graphics/win/FontWin.cpp:
3484         (WebCore::Font::drawGlyphs):
3485         * platform/graphics/win/GlyphPageTreeNodeWin.cpp:
3486         (WebCore::GlyphPage::fill):
3487         * platform/graphics/win/SimpleFontDataWin.cpp: Copied from WebCore/platform/graphics/win/FontDataWin.cpp.
3488         (WebCore::SimpleFontData::setShouldApplyMacAscentHack):
3489         (WebCore::SimpleFontData::platformInit):
3490         (WebCore::SimpleFontData::platformDestroy):
3491         (WebCore::SimpleFontData::smallCapsFontData):
3492         (WebCore::SimpleFontData::containsCharacters):
3493         (WebCore::SimpleFontData::determinePitch):
3494         (WebCore::SimpleFontData::platformWidthForGlyph):
3495         (WebCore::SimpleFontData::scriptFontProperties):
3496         * platform/graphics/wx/FontCacheWx.cpp:
3497         (WebCore::FontCache::getFontDataForCharacters):
3498         * platform/graphics/wx/FontDataWx.cpp: Renamed to SimpleFontDataWx.cpp.
3499         * platform/graphics/wx/FontWx.cpp:
3500         (WebCore::Font::drawGlyphs):
3501         * platform/graphics/wx/GlyphMapWx.cpp:
3502         (WebCore::GlyphPage::fill):
3503         * platform/graphics/wx/SimpleFontDataWx.cpp: Copied from WebCore/platform/graphics/wx/FontDataWx.cpp.
3504         (WebCore::SimpleFontData::platformInit):
3505         (WebCore::SimpleFontData::platformDestroy):
3506         (WebCore::SimpleFontData::smallCapsFontData):
3507         (WebCore::SimpleFontData::containsCharacters):
3508         (WebCore::SimpleFontData::determinePitch):
3509         (WebCore::SimpleFontData::platformWidthForGlyph):
3510         * platform/mac/FileChooserMac.mm:
3511         * platform/mac/PopupMenuMac.mm:
3512         * platform/mac/WebCoreTextRenderer.mm:
3513         * platform/win/PopupMenuWin.cpp:
3514         * platform/win/UniscribeController.cpp:
3515         (WebCore::UniscribeController::advance):
3516         (WebCore::UniscribeController::itemizeShapeAndPlace):
3517         (WebCore::UniscribeController::shapeAndPlaceItem):
3518         (WebCore::UniscribeController::shape):
3519         * platform/win/UniscribeController.h:
3520         * svg/SVGFont.cpp:
3521         (WebCore::Font::drawGlyphsWithSVGFont):
3522         * svg/SVGFontElement.cpp:
3523         (WebCore::SVGFontElement::collectGlyphs):
3524         * svg/SVGFontFaceElement.cpp:
3525         (WebCore::SVGFontFaceElement::createFontData):
3526         * svg/SVGFontFaceElement.h:
3527         * svg/SVGGlyphElement.cpp:
3528
3529 2008-01-07  Nikolas Zimmermann  <zimmermann@kde.org>
3530
3531         Not reviewed. Try to fix mac build by forcing SVGNames regeneration.
3532
3533         * svg/svgtags.in:
3534
3535 2008-01-07  Nikolas Zimmermann  <zimmermann@kde.org>
3536
3537         Not reviewed. Proposed build fix for wx.
3538
3539         * webcore-base.bkl:
3540
3541 2008-01-07  Dan Bernstein  <mitz@apple.com>
3542
3543         64-bit build fix
3544
3545         * platform/graphics/mac/FontCustomPlatformData.cpp:
3546         (WebCore::FontCustomPlatformData::fontPlatformData): Have to use a
3547         cast here since FMGetFontFromATSFontRef() is not available on 64-bit.
3548
3549 2008-01-06  Nikolas Zimmermann  <zimmermann@kde.org>
3550
3551         Reviewed by Oliver. Parts reviewed by Eric, David Hyatt & Dan & Alexey.
3552         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)
3553
3554         Display SVG Fonts, fill svg/SVGFont.cpp with life by adding all needed code to
3555         measure & render glyphs contained in SVG Fonts, including ligature lookup support.
3556
3557         Implement floatWidth/selectionRectForText for SVG Fonts, fixing text selection.
3558
3559         Support horiz-origin-x/y, horiz-adv-x, vert-adv-y, vert-origin-x/y & arabic-form.
3560         Implement simple algorithm to determine the arabic forms for a string (initial, isolated, medial, terminal).
3561
3562         Removed drawGlyphsWithSVGFont - create a new function drawTextWithSVGFont instead.
3563         This doesn't involve creating/using a 'GlyphBuffer' object anymore, which is not
3564         required for SVG Fonts anyway (we already know all our offsets/advances/etc..)
3565
3566         Don't call it from drawSimpleText anymore, but directly in drawText - as Dan suggested.
3567
3568         <glyph> elements now register themselves in the SVGFontElement's glyph cache.
3569         (insertedIntoDocument / removedFromDocument take care of this)
3570
3571         The cache is built once now, and is kept updated - it's not rebuild anymore
3572         on painting (!) - which was a crude hack for testing.
3573
3574         W3C testcase which include SVG Fonts:
3575         svg/W3C-SVG-1.1/animate-elem-03-t.svg (Fixed, of course not the anim itself, but it's SVG Fonts usage)
3576         svg/W3C-SVG-1.1/animate-elem-24-t.svg (Ditto)
3577         svg/W3C-SVG-1.1/animate-elem-36-t.svg (Ditto)
3578         svg/W3C-SVG-1.1/animate-elem-40-t.svg (Ditto)
3579         svg/W3C-SVG-1.1/fonts-kern-01-t.svg (missing <vkern>/<hkern> support)
3580         svg/W3C-SVG-1.1/fonts-desc-02-t.svg (Fixed, tests CSS font matching based on font-variant attribute)
3581         svg/W3C-SVG-1.1/fonts-elem-01-t.svg (Fixed, basic SVG font test)
3582         svg/W3C-SVG-1.1/fonts-elem-02-t.svg (Fixed, accuracy test for embedded SVG font)
3583         svg/W3C-SVG-1.1/fonts-elem-05-t.svg (Fixed, checks horiz-origin-x support, note: W3C reference image is wrong)
3584         svg/W3C-SVG-1.1/fonts-elem-06-t.svg (Fixed, checks horiz-adv-x support)
3585         svg/W3C-SVG-1.1/fonts-glyph-02-t.svg (Fixed, checks arabic-form support)
3586         svg/W3C-SVG-1.1/fonts-glyph-03-t.svg (Fixed, checks glyph matching based on xml:lang)
3587         svg/W3C-SVG-1.1/masking-mask-01-b.svg (Fixed, SVG Fonts & masking)
3588         svg/W3C-SVG-1.1/pservers-grad-08-b.svg (Fixed, SVG Fonts & gradient on fill/stroke)
3589         svg/W3C-SVG-1.1/render-elems-06-t.svg (Fixed, simple 'fill' property test)
3590         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)
3591         svg/W3C-SVG-1.1/render-elems-08-t.svg (Fixed, simple 'fill' & 'stroke' property test)
3592         svg/W3C-SVG-1.1/render-groups-01-b.svg (missing <vkern>/<hkern> support)
3593         svg/W3C-SVG-1.1/render-groups-03-t.svg (Ditto)
3594         svg