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