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