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