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