2009-02-27 Dimitri Glazkov <dglazkov@chromium.org>
[WebKit-https.git] / WebCore / ChangeLog
1 2009-02-27  Dimitri Glazkov  <dglazkov@chromium.org>
2
3         Reviewed by Eric Seidel.
4
5         https://bugs.webkit.org/show_bug.cgi?id=24211
6         Add ScheduledAction for V8.
7
8         * bindings/v8/ScheduledAction.cpp: Added.
9         (WebCore::ScheduledAction::ScheduledAction):
10         (WebCore::ScheduledAction::~ScheduledAction):
11         (WebCore::ScheduledAction::execute):
12         * bindings/v8/ScheduledAction.h: Added.
13         (WebCore::ScheduledAction::ScheduledAction):
14
15 2009-02-27  Zack Rusin  <zack@kde.org>
16
17         Reviewed by Nikolas Zimmermann.
18
19         Qt: be more reasonable about scrolled lines
20
21         cMouseWheelPixelsPerLineStep is currently a constant set to 13.3. it doesn't
22         match our metrics meaning that Qt scrolls by ~2 lines by default which is quite
23         irritating. so lets scroll vertically by the Qt set number of lines * Qt default
24         single step scroll
25
26         * platform/qt/WheelEventQt.cpp:
27
28 2009-02-27  Xan Lopez  <xan@gnome.org>
29
30         Rubber-stamped by Alexey Proskuryakov.
31
32         https://bugs.webkit.org/show_bug.cgi?id=24222
33         [GTK] Remove checks for old glib versions
34
35         libsoup, which is a hard dependency, needs at least glib 2.15.3,
36         so remove all glib checks for versions older than that.
37
38         * platform/gtk/ContextMenuGtk.cpp:
39         (WebCore::ContextMenu::ContextMenu):
40         * platform/gtk/ContextMenuItemGtk.cpp:
41         (WebCore::ContextMenuItem::setSubMenu):
42         * platform/gtk/PopupMenuGtk.cpp:
43         (WebCore::PopupMenu::show):
44         * platform/gtk/WidgetGtk.cpp:
45         (WebCore::Widget::retainPlatformWidget):
46         * platform/network/soup/ResourceHandleSoup.cpp:
47
48 2009-02-26  Dirk Schulze  <krit@webkit.org>
49
50         Reviewed by Oliver Hunt.
51
52         Added support for Gradients and Patterns on filled or stroked Fonts
53         in Cairo. I also added support for globalAlpha on FontCairo.
54
55         [CAIRO] SVG/Canvas fonts miss gradients/pattern support
56         https://bugs.webkit.org/show_bug.cgi?id=18617
57
58         * html/CanvasRenderingContext2D.cpp:
59         (WebCore::CanvasRenderingContext2D::drawTextInternal):
60         * platform/graphics/cairo/FontCairo.cpp:
61         (WebCore::Font::drawGlyphs):
62
63 2009-02-26  Stephen White  <senorblanco@chromium.org>
64
65         Reviewed by Eric Seidel.
66
67         https://bugs.webkit.org/show_bug.cgi?id=23957
68
69         Fix for SVG gradient and pattern text for Chromium/skia. 
70         Added accessors for the fill and stroke gradients to
71         GraphicsContext.  Changed the paintSkiaText function to take a
72         GraphicsContext, so we can check for gradients/patterns. 
73         Changed the skiaDrawText function to set the SkPaint shader
74         correctly, and to scale up the gradient shader matrix to
75         encompass the entire text string.  Also offset each glyph
76         separately, rather than transforming the canvas, so that the
77         gradient/pattern stays fixed relative to the text origin.
78
79         * platform/graphics/GraphicsContext.cpp:
80         (WebCore::GraphicsContext::getFillGradient):
81         (WebCore::GraphicsContext::getStrokeGradient):
82         (WebCore::GraphicsContext::getFillPattern):
83         (WebCore::GraphicsContext::getStrokePattern):
84         * platform/graphics/GraphicsContext.h:
85         * platform/graphics/chromium/FontChromiumWin.cpp:
86         (WebCore::Font::drawGlyphs):
87         * platform/graphics/chromium/UniscribeHelper.cpp:
88         (WebCore::UniscribeHelper::draw):
89         * platform/graphics/skia/SkiaFontWin.cpp:
90         (WebCore::windowsCanHandleTextDrawing):
91         (WebCore::skiaDrawText):
92         (WebCore::paintSkiaText):
93         * platform/graphics/skia/SkiaFontWin.h:
94
95 2009-02-26  Dimitri Glazkov  <dglazkov@chromium.org>
96
97         Reviewed by Eric Seidel.
98
99         https://bugs.webkit.org/show_bug.cgi?id=24208
100         Add custom V8 bindings for Navigator, Clipboard, Document, and Node.
101
102         * bindings/v8/custom/V8ClipboardCustom.cpp: Added.
103         (WebCore::ACCESSOR_GETTER):
104         (WebCore::CALLBACK_FUNC_DECL):
105         * bindings/v8/custom/V8DocumentCustom.cpp: Added.
106         (WebCore::CALLBACK_FUNC_DECL):
107         * bindings/v8/custom/V8NavigatorCustom.cpp: Added.
108         (WebCore::ACCESSOR_GETTER):
109         * bindings/v8/custom/V8NodeCustom.cpp: Added.
110         (WebCore::CALLBACK_FUNC_DECL):
111
112 2009-02-26  Gustavo Noronha Silva  <gns@gnome.org>
113
114         Unreviewed build fix for building with GNOME Keyring enabled.
115
116         * platform/network/soup/webkit-soup-auth-dialog.c:
117         (show_auth_dialog):
118
119 2009-02-26  Xan Lopez  <xan@gnome.org>
120
121         Reviewed by Holger Freyther.
122
123         https://bugs.webkit.org/show_bug.cgi?id=16947
124         [GTK] Missing HTTP Auth challenge
125
126         Add HTTP authentication dialog with optional GNOME Keyring
127         storage.
128
129         * GNUmakefile.am:
130         * platform/network/ResourceHandleInternal.h:
131         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
132         * platform/network/soup/ResourceHandleSoup.cpp:
133         (WebCore::currentToplevelCallback):
134         (WebCore::ResourceHandle::startHttp):
135         (WebCore::ResourceHandle::start):
136         * platform/network/soup/webkit-soup-auth-dialog.c: Added.
137         (webkit_soup_auth_dialog_class_init):
138         (webkit_soup_auth_dialog_init):
139         (webkit_soup_auth_dialog_session_feature_init):
140         (free_authData):
141         (set_password_callback):
142         (response_callback):
143         (show_auth_dialog):
144         (find_password_callback):
145         (session_authenticate):
146         (attach):
147         * platform/network/soup/webkit-soup-auth-dialog.h: Added.
148
149 2009-02-25  Ojan Vafai  <ojan@chromium.org> and Eric Seidel <eric@webkit.org>
150
151         Reviewed by Dave Hyatt.
152
153         After Ojan's positionForCoordinates fix http://trac.webkit.org/changeset/41191
154         svg/custom/pointer-events-image.svg and svg/custom/pointer-events-text.svg
155         started failing because Ojan's new code was now *correctly* calling through to
156         SVG asking for the closest text offset in the last line box, instead of
157         just returning the offset at the end of the last line box when clicking below a box.
158
159         But!  The SVG code was wrong, in that it returned the character offset of the last
160         character when you asked for a character offset after the end of the box, instead
161         it should return the offset *after* the last character.  This patch fixes
162         that behavior by reordering the last two clauses in svgCharacterHitsPosition.
163
164         The SVG positionForCoordinates function is still wrong, and I've added some FIXMEs
165         to document what's wrong.  I've also cleaned up the code a bit so it's clearer
166         what it is doing (which also makes more obvious what's wrong with it).
167
168         * rendering/RenderSVGInlineText.cpp:
169         (WebCore::RenderSVGInlineText::positionForCoordinates):
170         * rendering/SVGInlineTextBox.cpp:
171         (WebCore::SVGInlineTextBoxClosestCharacterToPositionWalker::SVGInlineTextBoxClosestCharacterToPositionWalker):
172         (WebCore::SVGInlineTextBoxClosestCharacterToPositionWalker::chunkPortionCallback):
173         (WebCore::SVGInlineTextBoxClosestCharacterToPositionWalker::offsetOfHitCharacter):
174         (WebCore::SVGInlineTextBox::closestCharacterToPosition):
175         (WebCore::SVGInlineTextBox::svgCharacterHitsPosition):
176
177 2009-02-26  Darin Fisher  <darin@chromium.org>
178
179         Reviewed by Eric Seidel.
180
181         Minor cleanup of ChromiumBridge:
182         Removing unused matchesMIMEType method and s/Javascript/JavaScript/
183
184         * platform/chromium/ChromiumBridge.h:
185         * platform/chromium/MimeTypeRegistryChromium.cpp:
186         (WebCore::MIMETypeRegistry::isSupportedImageMIMEType):
187         (WebCore::MIMETypeRegistry::isSupportedJavaScriptMIMEType):
188         (WebCore::MIMETypeRegistry::isSupportedNonImageMIMEType):
189
190 2009-02-26  David Hyatt  <hyatt@apple.com>
191
192         Reviewed by Sam Weinig
193
194         Fix text-bottom vertical alignment.  It was incorrectly aligning the bottom of the descent instead of including
195         the line-height below the descent.
196
197         Added fast/inline/vertical-align-text-bottom.html
198
199         * rendering/RenderBoxModelObject.cpp:
200         (WebCore::RenderBoxModelObject::verticalPosition):
201
202 2009-02-26  Dirk Schulze  <krit@webkit.org>
203
204         Reviewed by Eric Seidel.
205
206         Make SVG Masking platform independet with the use of ImageBuffer::getImageData(),
207         ImageBuffer::putImageData() and GraphicsContext::clipToImageBuffer(). Every platform has
208         just to implement this three methods to support SVG Masking now.
209  
210         Make SVG Masking platform aware
211         https://bugs.webkit.org/show_bug.cgi?id=19243
212
213         * GNUmakefile.am:
214         * WebCore.pro:
215         * WebCore.vcproj/WebCore.vcproj:
216         * WebCore.xcodeproj/project.pbxproj:
217         * svg/graphics/SVGResourceMasker.cpp:
218         (WebCore::SVGResourceMasker::applyMask):
219         * svg/graphics/cairo/SVGResourceMaskerCairo.cpp: Removed.
220         * svg/graphics/cg/SVGResourceMaskerCg.cpp: Removed.
221         * svg/graphics/cg/SVGResourceMaskerCg.mm: Removed.
222         * svg/graphics/qt/SVGResourceMaskerQt.cpp: Removed.
223         * svg/graphics/skia/SVGResourceMaskerSkia.cpp: Removed.
224
225 2009-02-26  Yong Li  <yong.li@torchmobile.com>
226
227         Reviewed by Darin Adler, Antti Koivisto and Alexey Proskuryakov.
228
229         Test: http/tests/misc/slow-preload-cancel.html
230
231         https://bugs.webkit.org/show_bug.cgi?id=24133
232         Clear all pending preloads in the DocLoader object when we decide to
233         cancel its all requests.
234
235         * loader/DocLoader.cpp:
236         (WebCore::DocLoader::clearPendingPreloads):
237         * loader/DocLoader.h:
238         * loader/loader.cpp:
239         (WebCore::Loader::cancelRequests):
240
241 2009-02-26  Dimitri Glazkov  <dglazkov@chromium.org>
242
243         Reviewed by Eric Seidel.
244
245         https://bugs.webkit.org/show_bug.cgi?id=24182
246         Add NodeFilter, NodeIterator, and TreeWalker custom V8 bindings.
247
248         * bindings/v8/custom/V8NodeFilterCustom.cpp: Added.
249         (WebCore::CALLBACK_FUNC_DECL):
250         * bindings/v8/custom/V8NodeIteratorCustom.cpp: Added.
251         (WebCore::toV8):
252         (WebCore::CALLBACK_FUNC_DECL):
253         * bindings/v8/custom/V8TreeWalkerCustom.cpp: Added.
254         (WebCore::toV8):
255         (WebCore::CALLBACK_FUNC_DECL):
256
257 2009-02-26  Alexey Proskuryakov  <ap@webkit.org>
258
259         Reviewed by Darin Adler.
260
261         https://bugs.webkit.org/show_bug.cgi?id=23500
262         KURL::parse() incorrectly compares its result to original string
263
264         * platform/KURL.cpp: (WebCore::KURL::parse): Take string length into account.
265
266 2009-02-26  Ojan Vafai  <ojan@chromium.org>
267
268         Reviewed by Kevin McCullough.
269
270         Manual test for inspector node highlighting.
271
272         * manual-tests/inspector/highlight-nodes.html: Added.
273
274 2009-02-16  Anantanarayanan Iyengar  <ananta@chromium.org>
275
276         Reviewed by Darin Fisher.
277
278         https://bugs.webkit.org/show_bug.cgi?id=23973
279         ScrollView::scrollContents can be invoked during view shutdown.  In
280         this scenario the FrameView::hostWindow method can return NULL, which
281         indicates that the frame/page is being destroyed. This causes a crash
282         when we try to dereference a NULL hostWindow pointer.  Fix is to add a
283         NULL check for this.  
284
285         * platform/ScrollView.cpp:
286         (WebCore::ScrollView::scrollContents):
287
288 2009-02-26  Rahul Kuchhal  <kuchhal@chromium.org>
289
290         Reviewed by Dave Hyatt.
291
292         https://bugs.webkit.org/show_bug.cgi?id=24003
293         Fix a crash caused by unsafe type conversion.
294
295         Test: fast/block/positioning/absolute-in-inline-rtl-4.html
296
297         * rendering/RenderBox.cpp:
298         (WebCore::RenderBox::calcAbsoluteHorizontalValues):
299
300 2009-02-26  Ojan Vafai  <ojan@chromium.org>
301
302         Reviewed by Adam Roben.
303
304         https://bugs.webkit.org/show_bug.cgi?id=24202
305         Have drawNodeHighlight clip instead of clearing. This makes it work for
306         both Safari and Chromium since Chromium draws the inspector highlighting
307         in the same buffer as the page.
308
309         * inspector/InspectorController.cpp:
310         (WebCore::quadToPath):
311         (WebCore::drawOutlinedQuad):
312         (WebCore::drawOutlinedQuadWithClip):
313         (WebCore::drawHighlightForBox):
314
315 2009-02-26  David Hyatt  <hyatt@apple.com>
316
317         Reviewed by Dan Bernstein & Darin Adler
318
319         Make sure the border/padding are properly omitted at the start of an inline that is a continuation.
320         
321         Added fast/inline/inline-continuation-borders.html
322
323         * rendering/InlineFlowBox.cpp:
324         (WebCore::InlineFlowBox::determineSpacingForFlowBoxes):
325
326 2009-02-26  Simon Fraser  <simon.fraser@apple.com>
327
328         Build fix, no review.
329         
330         Try to fix the wx build after r41218.
331
332         * WebCoreSources.bkl:
333
334 2009-02-26  Alexey Proskuryakov  <ap@webkit.org>
335
336         Reviewed by Darin Adler.
337
338         https://bugs.webkit.org/show_bug.cgi?id=19527
339         ASSERTION FAILED: containerA && containerB
340
341         Test: fast/dom/Range/bug-19527.html
342
343         * dom/Range.cpp:
344         (WebCore::Range::isPointInRange):
345         (WebCore::Range::comparePoint):
346         Bring the behavior in line with current Firefox, making it impossible for these methods
347         to pass a null container to compareBoundaryPoints().
348
349 2009-02-26  Jonathon Jongsma  <jonathon@quotidian.org>
350
351         Reviewed by Holger Freyther.
352
353         https://bugs.webkit.org/show_bug.cgi?id=20358
354
355         * platform/graphics/gtk/SimpleFontDataGtk.cpp:
356         (WebCore::SimpleFontData::smallCapsFontData): the small-caps font data
357         should set the computed size rather than the specified size, otherwise
358         the caps just get rendered normal size.
359
360 2009-02-26  Benjamin Meyer  <benjamin.meyer@torchmobile.com>
361
362         Reviewed by George Staikos.
363
364         https://bugs.webkit.org/show_bug.cgi?id=24062
365         QNetworkCookieJar expects the url and not the policy url.  Sending the
366         policy url will cause QNetworkCookieJar to behave incorrectly.  One
367         example would be a cookie that does not have a path or domain.
368         QNetworkCookieJar will use the url it is given to fill in default values.
369         This allows setting cookies on the url of the main frame from an iFrame
370         when the cookie should be set on the url of the iFrame.
371
372         Originally noticed on http://writer.zoho.com/jsp/home.jsp?serviceurl=/index.do
373
374         * platform/qt/CookieJarQt.cpp:
375         (WebCore::setCookies):
376
377 2009-02-26  Charles Wei  <charles.wei@torchmobile.com.cn>
378
379         Reviewed by George Staikos.
380
381         make WebKit/Qt compile with SVG disabled
382
383         * WebCore.pro:
384         * platform/graphics/qt/FontPlatformDataQt.cpp:
385
386 2009-02-25  Gustavo Noronha Silva  <gns@gnome.org>
387
388         Unreviewed build fix. Add WebCore/workers to the list of paths
389         searched by the bindings generator perl script.
390
391         * GNUmakefile.am:
392
393 2009-02-25  Sam Weinig  <sam@webkit.org>
394
395         Reviewed by Geoffrey Garen.
396
397         Add canvas to the list of RenderObjects that can mark a page as
398         visually not empty.
399
400         * rendering/RenderHTMLCanvas.cpp:
401         (WebCore::RenderHTMLCanvas::RenderHTMLCanvas):
402
403 2009-02-25  Eric Carlson  <eric.carlson@apple.com>
404
405         Reviewed by Dave Hyatt.
406
407         * rendering/RenderBox.cpp:
408         (WebCore::RenderBox::nodeAtPoint): Remove assertion fired when child has layer
409         as RenderMedia with controls always has a layer.
410
411 2009-02-25  Dan Bernstein  <mitz@apple.com>
412
413         Reviewed by Simon Fraser.
414
415         - fix https://bugs.webkit.org/show_bug.cgi?id=24130
416           <rdar://problem/6618196> Paint very slow when horizontally resizing
417
418         Test: fast/gradients/background-clipped.html
419
420         * rendering/RenderBoxModelObject.cpp:
421         (WebCore::RenderBoxModelObject::paintFillLayerExtended): Intersect the
422         destination rectangle passed to drawTiledImage() with the dirty
423         rectangle. This makes it more likely for the destination rect to be
424         contained in a single tile rect, which results in a faster code path
425         being taken down the road (just drawing a single tile instead of
426         tiling).
427
428 2009-02-25  Ojan Vafai  <ojan@chromium.org>
429
430         Reviewed by Eric Seidel.
431
432         Fix test regressions from positionForCoordinates patch.
433         https://bugs.webkit.org/show_bug.cgi?id=24148
434
435         * rendering/RenderBlock.cpp:
436         (WebCore::positionForPointWithInlineChildren):
437         Remove ASSERT that placeholder text codepath is hitting.
438
439 2009-02-25  Chris Fleizach  <cfleizach@apple.com>
440
441         Reviewed by Beth Dakin.
442
443         Bug 24143: Crash occurs at WebCore::AccessibilityTable::isTableExposableThroughAccessibility() when applying a link in GMail
444         https://bugs.webkit.org/show_bug.cgi?id=24143
445
446         When an AX object is marked dirty, do not create AX elements while going up the parent chain.
447         Do not allow AXRenderObjects to remove their own IDs from the cache, all the cache to do that work
448         Make sure the AXObjectWrapper's have an object before calling them
449         In AXObjectCache, change get -> getOrCreate. Use get() to only retrieve an element if it exists
450
451         Test: platform/mac-snowleopard/accessibility/table-updating.html
452
453         * WebCore.base.exp:
454         * page/AXObjectCache.cpp:
455         (WebCore::AXObjectCache::~AXObjectCache):
456         (WebCore::AXObjectCache::get):
457         (WebCore::AXObjectCache::getOrCreate):
458         (WebCore::AXObjectCache::removeAXID):
459         (WebCore::AXObjectCache::handleActiveDescendantChanged):
460         (WebCore::AXObjectCache::handleAriaRoleChanged):
461         * page/AXObjectCache.h:
462         * page/AccessibilityImageMapLink.cpp:
463         (WebCore::AccessibilityImageMapLink::parentObject):
464         * page/AccessibilityListBox.cpp:
465         (WebCore::AccessibilityListBox::listBoxOptionAccessibilityObject):
466         (WebCore::AccessibilityListBox::doAccessibilityHitTest):
467         * page/AccessibilityListBoxOption.cpp:
468         (WebCore::AccessibilityListBoxOption::elementRect):
469         (WebCore::AccessibilityListBoxOption::parentObject):
470         * page/AccessibilityObject.cpp:
471         (WebCore::AccessibilityObject::detach):
472         (WebCore::AccessibilityObject::parentObjectIfExists):
473         (WebCore::replacedNodeNeedsCharacter):
474         (WebCore::AccessibilityObject::accessibilityObjectForPosition):
475         * page/AccessibilityObject.h:
476         * page/AccessibilityRenderObject.cpp:
477         (WebCore::AccessibilityRenderObject::firstChild):
478         (WebCore::AccessibilityRenderObject::lastChild):
479         (WebCore::AccessibilityRenderObject::previousSibling):
480         (WebCore::AccessibilityRenderObject::nextSibling):
481         (WebCore::AccessibilityRenderObject::parentObjectIfExists):
482         (WebCore::AccessibilityRenderObject::parentObject):
483         (WebCore::AccessibilityRenderObject::isAttachment):
484         (WebCore::AccessibilityRenderObject::headingLevel):
485         (WebCore::AccessibilityRenderObject::anchorElement):
486         (WebCore::AccessibilityRenderObject::menuForMenuButton):
487         (WebCore::AccessibilityRenderObject::menuButtonForMenu):
488         (WebCore::AccessibilityRenderObject::checkboxOrRadioRect):
489         (WebCore::AccessibilityRenderObject::internalLinkElement):
490         (WebCore::AccessibilityRenderObject::addRadioButtonGroupMembers):
491         (WebCore::AccessibilityRenderObject::titleUIElement):
492         (WebCore::AccessibilityRenderObject::accessibilityIsIgnored):
493         (WebCore::AccessibilityRenderObject::accessibilityParentForImageMap):
494         (WebCore::AccessibilityRenderObject::getDocumentLinks):
495         (WebCore::AccessibilityRenderObject::doAccessibilityHitTest):
496         (WebCore::AccessibilityRenderObject::focusedUIElement):
497         (WebCore::AccessibilityRenderObject::activeDescendant):
498         (WebCore::AccessibilityRenderObject::observableObject):
499         (WebCore::AccessibilityRenderObject::childrenChanged):
500         (WebCore::AccessibilityRenderObject::addChildren):
501         * page/AccessibilityRenderObject.h:
502         (WebCore::AccessibilityRenderObject::setRenderObject):
503         * page/AccessibilityTable.cpp:
504         (WebCore::AccessibilityTable::addChildren):
505         (WebCore::AccessibilityTable::headerContainer):
506         (WebCore::AccessibilityTable::cellForColumnAndRow):
507         * page/AccessibilityTableCell.cpp:
508         (WebCore::AccessibilityTableCell::isTableCell):
509         (WebCore::AccessibilityTableCell::titleUIElement):
510         * page/AccessibilityTableColumn.cpp:
511         (WebCore::AccessibilityTableColumn::headerObjectForSection):
512         * page/AccessibilityTableRow.cpp:
513         (WebCore::AccessibilityTableRow::isTableRow):
514         * page/gtk/AccessibilityObjectWrapperAtk.cpp:
515         * page/mac/AXObjectCacheMac.mm:
516         (WebCore::AXObjectCache::postNotification):
517         (WebCore::AXObjectCache::postNotificationToElement):
518         * page/mac/AccessibilityObjectWrapper.mm:
519         (textMarkerForVisiblePosition):
520         (AXLinkElementForNode):
521         (nsStringForReplacedNode):
522         (-[AccessibilityObjectWrapper doAXAttributedStringForTextMarkerRange:]):
523         (-[AccessibilityObjectWrapper accessibilityActionNames]):
524         (-[AccessibilityObjectWrapper accessibilityAttributeNames]):
525         (-[AccessibilityObjectWrapper accessibilityFocusedUIElement]):
526         (-[AccessibilityObjectWrapper accessibilityHitTest:]):
527         (-[AccessibilityObjectWrapper accessibilityIsAttributeSettable:]):
528         (-[AccessibilityObjectWrapper accessibilityIsIgnored]):
529         (-[AccessibilityObjectWrapper accessibilityParameterizedAttributeNames]):
530         (-[AccessibilityObjectWrapper accessibilityPerformPressAction]):
531         (-[AccessibilityObjectWrapper accessibilityPerformAction:]):
532         (-[AccessibilityObjectWrapper accessibilitySetValue:forAttribute:]):
533         (-[AccessibilityObjectWrapper _accessibilityParentForSubview:]):
534         (-[AccessibilityObjectWrapper accessibilityIndexOfChild:]):
535         (-[AccessibilityObjectWrapper accessibilityArrayAttributeCount:]):
536         (-[AccessibilityObjectWrapper accessibilityArrayAttributeValues:index:maxCount:]):
537
538 2009-02-25  Beth Dakin  <bdakin@apple.com>
539
540         Reviewed by Geoff Garen.
541
542         Re-working of <rdar://problem/6487249> repro crash in 
543         WebCore::CSSParser::parseFillImage copying entire contents of this 
544         page
545         -and corresponding: https://bugs.webkit.org/show_bug.cgi?id=24172
546
547         Fixes a bunch of layout test failures I caused!
548
549         * css/CSSParser.cpp:
550         (WebCore::CSSParser::parseValue):
551         (WebCore::CSSParser::parseContent):
552         (WebCore::CSSParser::parseFillImage):
553         (WebCore::CSSParser::parseFontFaceSrc):
554         (WebCore::CSSParser::parseBorderImage):
555
556 2009-02-25  Dimitri Glazkov  <dglazkov@chromium.org>
557
558         Reviewed by Eric Seidel.
559
560         https://bugs.webkit.org/show_bug.cgi?id=24174
561         Add more V8 custom bindings.
562
563         * bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp: Added.
564         (WebCore::hasCSSPropertyNamePrefix):
565         (WebCore::cssPropertyName):
566         (WebCore::NAMED_PROPERTY_GETTER):
567         (WebCore::NAMED_PROPERTY_SETTER):
568         * bindings/v8/custom/V8DOMStringListCustom.cpp: Added.
569         (WebCore::INDEXED_PROPERTY_GETTER):
570         (WebCore::CALLBACK_FUNC_DECL):
571         * bindings/v8/custom/V8EventCustom.cpp: Added.
572         (WebCore::ACCESSOR_SETTER):
573         (WebCore::ACCESSOR_GETTER):
574         * bindings/v8/custom/V8HTMLDocumentCustom.cpp: Added.
575         (WebCore::NAMED_PROPERTY_DELETER):
576         (WebCore::NAMED_PROPERTY_SETTER):
577         (WebCore::NAMED_PROPERTY_GETTER):
578         * bindings/v8/custom/V8HTMLFrameSetElementCustom.cpp: Added.
579         (WebCore::NAMED_PROPERTY_GETTER):
580         * bindings/v8/custom/V8NamedNodeMapCustom.cpp: Added.
581         (WebCore::INDEXED_PROPERTY_GETTER):
582         (WebCore::NAMED_PROPERTY_GETTER):
583         * bindings/v8/custom/V8NodeListCustom.cpp: Added.
584         (WebCore::NAMED_PROPERTY_GETTER):
585         * bindings/v8/custom/V8StyleSheetListCustom.cpp: Added.
586         (WebCore::NAMED_PROPERTY_GETTER):
587
588 2009-02-25  Scott Violet  <sky@google.com>
589
590         Reviewed by Dave Hyatt.
591
592         https://bugs.webkit.org/show_bug.cgi?id=24171
593         Provides a RenderTheme method for getting the scroll bar size and
594         changes RenderListBox to use it. RenderTheme returns a size of regular,
595         and Mac's override to return small. Changes ScrollbarThemeChromium to
596         use the scrollbarsize of the scrollbar when getting the size
597         instead of passing in no-args.
598
599         * platform/chromium/ScrollbarThemeChromium.cpp:
600         (WebCore::ScrollbarThemeChromium::trackRect):
601         (WebCore::ScrollbarThemeChromium::buttonSize):
602         * rendering/RenderListBox.cpp:
603         (WebCore::RenderListBox::createScrollbar):
604         * rendering/RenderTheme.h:
605         (WebCore::RenderTheme::scrollbarControlSizeForPart):
606         * rendering/RenderThemeChromiumMac.h:
607         (WebCore::RenderThemeChromiumMac::scrollbarControlSizeForPart):
608         * rendering/RenderThemeMac.h:
609         (WebCore::RenderThemeMac::scrollbarControlSizeForPart):
610
611 2009-02-25  Beth Dakin  <bdakin@apple.com>
612
613         Reviewed by Darin Adler.
614
615         Fix for <rdar://problem/6487249> repro crash in 
616         WebCore::CSSParser::parseFillImage copying entire contents of this 
617         page
618         -and corresponding: https://bugs.webkit.org/show_bug.cgi?id=24172
619
620         * css/CSSParser.cpp:
621         (WebCore::CSSParser::parseValue): Null-check m_styleSheet
622
623 2009-02-25  Adam Treat  <adam.treat@torchmobile.com>
624
625         Fix the Qt build.
626
627         * WebCore.pro:
628
629 2009-02-25  Jan Michael Alonzo  <jmalonzo@webkit.org>
630
631         Gtk build fix. Not reviewed.
632
633         Add files to the build per r41218.
634         Rename WebkitPoint.h to WebKitPoint.h in DOMWindow.cpp
635
636         * GNUmakefile.am:
637         * page/DOMWindow.cpp:
638
639 2009-02-25  Zan Dobersek  <zandobersek@gmail.com>
640
641         Reviewed by Alexey Proskuryakov.
642
643         https://bugs.webkit.org/show_bug.cgi?id=24043
644         When faced with URLs with unsupported protocol on Gtk port,
645         report the error through an idle function and return true, so
646         a proper resource handle is created.
647
648         * platform/network/soup/ResourceHandleSoup.cpp:
649         (WebCore::reportUnknownProtocolError):
650         (WebCore::ResourceHandle::start):
651
652 2009-02-25  Steve Falkenburg  <sfalken@apple.com>
653
654         Windows build fix.
655         Use struct to forward declare ResourceRequest.
656
657         * history/HistoryItem.h:
658         * inspector/InspectorController.h:
659         * loader/DocumentThreadableLoader.h:
660         * loader/FrameLoaderClient.h:
661         * loader/MainResourceLoader.h:
662         * loader/SubresourceLoader.h:
663         * loader/SubresourceLoaderClient.h:
664         * loader/ThreadableLoader.h:
665         * loader/WorkerThreadableLoader.h:
666         * platform/CrossThreadCopier.h:
667         * platform/network/ResourceHandle.h:
668         * platform/network/ResourceHandleClient.h:
669         * platform/network/ResourceRequestBase.h:
670         * platform/network/cf/ResourceRequestCFNet.h:
671         * xml/XMLHttpRequest.h:
672
673 2009-02-25  Steve Falkenburg  <sfalken@apple.com>
674
675         Partial Windows build fix.
676         
677         * DerivedSources.cpp:
678         * WebCore.vcproj/WebCore.vcproj:
679
680 2009-02-25  Dirk Schulze  <krit@webkit.org>
681
682         Reviewed by Oliver Hunt.
683
684         Ported arcTo to Qt. Qt has no native support for arcTo. This changes
685         calculate the behavior of arcTo and draws it with lineTo and arc.
686
687         [QT] implement Canvas arcTo
688         https://bugs.webkit.org/show_bug.cgi?id=23873
689
690         * platform/graphics/qt/PathQt.cpp:
691         (WebCore::Path::addArcTo):
692
693 2009-02-25  Simon Fraser  <simon.fraser@apple.com>
694
695         Reviewed by Dan Bernstein
696
697         Remove idl files from Resources, and sort.
698         
699         * WebCore.xcodeproj/project.pbxproj:
700
701 2009-02-25  Chris Marrin  <cmarrin@apple.com>
702
703         Reviewed by Simon Fraser.
704
705         https://bugs.webkit.org/show_bug.cgi?id=23943
706
707         Added webkitConvertPointFromNodeToPage and webkitConvertPointFromPageToNode on
708         the window object. Also added WebKitPoint object, which is passed in and out
709         of these functions.
710
711         Test: fast/dom/Window/webkitConvertPoint.html
712
713         * DerivedSources.make:
714         * WebCore.pro:
715         * WebCore.vcproj/WebCore.vcproj:
716         * WebCore.xcodeproj/project.pbxproj:
717         * WebCoreSources.bkl:
718         * bindings/js/JSDOMWindowBase.cpp:
719         (jsDOMWindowBaseWebKitPoint):
720         (setJSDOMWindowBaseWebKitPoint):
721         * bindings/js/JSWebKitPointConstructor.cpp: Added.
722         (WebCore::):
723         (WebCore::JSWebKitPointConstructor::JSWebKitPointConstructor):
724         (WebCore::constructWebKitPoint):
725         (WebCore::JSWebKitPointConstructor::getConstructData):
726         * bindings/js/JSWebKitPointConstructor.h: Added.
727         (WebCore::JSWebKitPointConstructor::classInfo):
728         * dom/Node.cpp:
729         (WebCore::Node::convertToPage):
730         (WebCore::Node::convertFromPage):
731         * dom/Node.h:
732         * page/DOMWindow.cpp:
733         (WebCore::DOMWindow::webkitConvertPointFromNodeToPage):
734         (WebCore::DOMWindow::webkitConvertPointFromPageToNode):
735         * page/DOMWindow.h:
736         * page/DOMWindow.idl:
737         * page/WebKitPoint.h: Added.
738         (WebCore::WebKitPoint::create):
739         (WebCore::WebKitPoint::x):
740         (WebCore::WebKitPoint::y):
741         (WebCore::WebKitPoint::setX):
742         (WebCore::WebKitPoint::setY):
743         (WebCore::WebKitPoint::WebKitPoint):
744         * page/WebKitPoint.idl: Added.
745
746 2009-02-25  Jian Li  <jianli@chromium.org>
747
748         Reviewed by Alexey Proskuryakov.
749
750         Remove "#if ENABLE(WORKERS)" wrap from CrossThreadCopier files.
751         https://bugs.webkit.org/show_bug.cgi?id=24145
752
753         * platform/CrossThreadCopier.cpp:
754         * platform/CrossThreadCopier.h:
755
756 2009-02-25  David Levin  <levin@chromium.org>
757
758         Reviewed by Alexey Proskuryakov.
759
760         Bug 23688: ThreadableLoader needs a sync implementation for Workers.
761         <https://bugs.webkit.org/show_bug.cgi?id=23688>
762
763         No observable change in behavior, so no test.
764
765         * loader/ThreadableLoader.cpp:
766         (WebCore::ThreadableLoader::loadResourceSynchronously):
767         * loader/ThreadableLoaderClientWrapper.h:
768         (WebCore::ThreadableLoaderClientWrapper::clearClient):
769         (WebCore::ThreadableLoaderClientWrapper::done):
770         (WebCore::ThreadableLoaderClientWrapper::didFinishLoading):
771         (WebCore::ThreadableLoaderClientWrapper::didFail):
772         (WebCore::ThreadableLoaderClientWrapper::didFailRedirectCheck):
773         (WebCore::ThreadableLoaderClientWrapper::ThreadableLoaderClientWrapper):
774         Expose whether the loader is done (based on what callbacks were done).
775
776         * loader/WorkerThreadableLoader.cpp:
777         (WebCore::WorkerThreadableLoader::WorkerThreadableLoader):
778         (WebCore::WorkerThreadableLoader::loadResourceSynchronously):
779         Each loader is given its own mode so that only its callbacks get through the run loop.
780
781         The xhr spec says that the readystatechange events are synchronous, so in the case of a
782         nested sync xhr no readystatechange events should be fired for the outer xhr.
783
784         (WebCore::WorkerThreadableLoader::MainThreadBridge::MainThreadBridge):
785
786         * loader/WorkerThreadableLoader.h:
787         (WebCore::WorkerThreadableLoader::create):
788         (WebCore::WorkerThreadableLoader::done):
789
790         * workers/WorkerRunLoop.cpp:
791         (WebCore::WorkerRunLoop::WorkerRunLoop):
792         * workers/WorkerRunLoop.h:
793         (WebCore::WorkerRunLoop::createUniqueId):
794         Simple method to create a uniqueId on demand with respect to the run loop.
795
796         * workers/WorkerThread.h:
797
798 2009-02-25  David Levin  <levin@chromium.org>
799
800         Reviewed by Alexey Proskuryakov.
801
802         Bug 24089: ThreadableLoader::loadResourceSynchronously should do callbacks like the async code.
803         <https://bugs.webkit.org/show_bug.cgi?id=24089>
804
805         Make threadable loader callbacks to happen during the sync load call.
806
807         Changes the behavior of sync xhr for insecure redirects in two ways:
808         + Sends an error event instead of an abort event (which is the same as async xhr's behavior).
809         + Throws a network exception which is what other browsers do and what the spec
810         says to do (http://www.w3.org/TR/XMLHttpRequest/).
811
812         * loader/DocumentThreadableLoader.cpp:
813         (WebCore::DocumentThreadableLoader::loadResourceSynchronously):
814         * loader/DocumentThreadableLoader.h:
815         * loader/ThreadableLoader.cpp:
816         (WebCore::ThreadableLoader::loadResourceSynchronously):
817         * loader/ThreadableLoader.h:
818         * xml/XMLHttpRequest.cpp:
819         (WebCore::XMLHttpRequest::XMLHttpRequest):
820         (WebCore::XMLHttpRequest::loadRequestSynchronously):
821         (WebCore::XMLHttpRequest::loadRequestAsynchronously):
822         (WebCore::XMLHttpRequest::didFail):
823         (WebCore::XMLHttpRequest::didFailRedirectCheck):
824         * xml/XMLHttpRequest.h:
825
826 2009-02-24  Chris Marrin  <cmarrin@apple.com>
827
828         Reviewed by David Hyatt.
829
830         https://bugs.webkit.org/show_bug.cgi?id=23368
831
832         Added logic to correctly hit test accelerated layers.
833
834         Tests: animations/animation-hit-test-transform.html
835                animations/animation-hit-test.html
836                transitions/transition-hit-test-transform.html
837                transitions/transition-hit-test.html
838
839         * page/animation/KeyframeAnimation.cpp:
840         (WebCore::KeyframeAnimation::animate):
841         * rendering/RenderLayer.cpp:
842         (WebCore::RenderLayer::hitTestLayer):
843         (WebCore::RenderLayer::updateClipRects):
844         * rendering/RenderLayerBacking.cpp:
845         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
846
847 2009-02-25  Alexey Proskuryakov  <ap@webkit.org>
848
849         Reviewed by Darin Adler.
850
851         https://bugs.webkit.org/show_bug.cgi?id=24067
852         REGRESSION: Crash in WebCore::Document::initSecurityContext
853
854         The crash started to happen when we removed a check for frame->document() being null.
855         However, the original document shouldn't be null here, because it is needed to alias
856         security origins. So, this patch fixes the crash by correcting security origin behavior.
857
858         Test: http/tests/security/aboutBlank/window-open-self-about-blank.html
859         This tests for not crashing, and for inheriting the domain from the document being replaced.
860         Preserving the aliasing cannot be tested for automatically, because we'd need a non-trivial
861         domain to remove a prefix from.
862
863         * loader/FrameLoader.cpp: (WebCore::FrameLoader::begin): Create a new document before
864         clearing the frame, so that Document::initSecurityContext() could access the old one.
865
866 2009-02-25  Jay Campan  <jcampan@google.com>
867
868         Reviewed by Darin Fisher.
869
870         https://bugs.webkit.org/show_bug.cgi?id=24066
871
872         Items in drop-downs were not painted correctly.  Makes sure the
873         PopupListBox invalidates in the coordinates of the window as this is
874         FramelessScrollView::invalidateRect paints to.
875
876         * platform/chromium/PopupMenuChromium.cpp:
877         (WebCore::PopupListBox::invalidateRow):
878
879 2009-02-24  Simon Fraser  <simon.fraser@apple.com>
880
881         Reviewed by Anders Carlsson
882
883         https://bugs.webkit.org/show_bug.cgi?id=15081
884         
885         Make display:none work for applet, emebed and object elements
886         by calling rendererIsNeeded() on superclasses.
887
888         Tests: fast/replaced/applet-display-none.html
889                fast/replaced/embed-display-none.html
890                fast/replaced/object-display-none.html
891
892         * html/HTMLAppletElement.cpp:
893         (WebCore::HTMLAppletElement::rendererIsNeeded):
894         * html/HTMLElement.cpp:
895         (WebCore::HTMLElement::rendererIsNeeded):
896         * html/HTMLEmbedElement.cpp:
897         (WebCore::HTMLEmbedElement::rendererIsNeeded):
898         * html/HTMLObjectElement.cpp:
899         (WebCore::HTMLObjectElement::rendererIsNeeded):
900
901 2009-02-24  Simon Fraser  <simon.fraser@apple.com>
902
903         Reviewed by Dave Hyatt
904
905         https://bugs.webkit.org/show_bug.cgi?id=24137
906         
907         Fix localToAbsolute() and absoluteToLocal() to map points through 3d transforms,
908         taking perspective and transform-style: preserve-3d into account.
909         
910         In order to support transform-style: preserve-3d, which keeps elements in a
911         3d space, we have to carry along an accumulated matrix in TransformState.
912         We also need to apply the perspective from the parent, if any, with the
913         appropriate origin.
914
915         * GNUmakefile.am:
916         * WebCore.base.exp:
917         * WebCore.pro:
918         * WebCore.scons:
919         * WebCore.vcproj/WebCore.vcproj:
920         * WebCore.xcodeproj/project.pbxproj:
921         * WebCoreSources.bkl:
922         * css/CSSComputedStyleDeclaration.cpp:
923         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
924         * platform/graphics/transforms/TransformationMatrix.cpp:
925         (WebCore::TransformationMatrix::translate):
926         (WebCore::TransformationMatrix::translate3d):
927         (WebCore::TransformationMatrix::translateRight3d):
928         * platform/graphics/transforms/TransformationMatrix.h:
929         * rendering/RenderBox.cpp:
930         (WebCore::RenderBox::mapLocalToAbsolutePoint):
931         (WebCore::RenderBox::mapAbsoluteToLocalPoint):
932         * rendering/RenderBox.h:
933         * rendering/RenderLayer.cpp:
934         (WebCore::RenderLayer::updateTransform):
935         (WebCore::RenderLayer::perspectiveTransform):
936         (WebCore::RenderLayer::perspectiveOrigin):
937         * rendering/RenderLayer.h:
938         * rendering/RenderLayerBacking.cpp:
939         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
940         * rendering/RenderLayerCompositor.cpp:
941         (WebCore::requiresCompositingLayerForTransform):
942         (WebCore::RenderLayerCompositor::layerHas3DContent):
943         * rendering/RenderObject.cpp:
944         (WebCore::RenderObject::localToAbsolute):
945         (WebCore::RenderObject::absoluteToLocal):
946         (WebCore::RenderObject::mapLocalToAbsolutePoint):
947         (WebCore::RenderObject::mapAbsoluteToLocalPoint):
948         * rendering/RenderObject.h:
949         * rendering/RenderTableCell.cpp:
950         (WebCore::RenderTableCell::mapLocalToAbsolutePoint):
951         (WebCore::RenderTableCell::mapAbsoluteToLocalPoint):
952         * rendering/RenderTableCell.h:
953         * rendering/RenderView.cpp:
954         (WebCore::RenderView::mapLocalToAbsolutePoint):
955         (WebCore::RenderView::mapAbsoluteToLocalPoint):
956         * rendering/RenderView.h:
957         * rendering/TransformState.cpp: Added.
958         (WebCore::TransformState::move):
959         (WebCore::TransformState::applyTransform):
960         (WebCore::TransformState::flatten):
961         * rendering/TransformState.h: Added.
962         (WebCore::TransformState::):
963         (WebCore::TransformState::TransformState):
964         (WebCore::TransformState::move):
965         * rendering/style/RenderStyle.h:
966         (WebCore::InheritedFlags::hasPerspective):
967
968 2009-02-24  Sam Weinig  <sam@webkit.org>
969
970         Reviewed by David Hyatt.
971
972         Fix for https://bugs.webkit.org/show_bug.cgi?id=23990
973         Regression (r40837): JavaScript image popup doesn't work
974
975         Make the getClientRects and getBoundingClientRect methods return rects
976         relative to the viewport.
977
978         Test: fast/dom/getBoundingClientRect-getClientRects-relative-to-viewport.html
979
980         * dom/Element.cpp:
981         (WebCore::Element::getClientRects):
982         (WebCore::Element::getBoundingClientRect):
983
984 2009-02-24  Ojan Vafai  <ojan@chromium.org>
985
986         Reviewed by Eric Seidel.
987
988         SVG pages don't have a body or an html element! 
989         Don't return early if there is no body.
990
991         * editing/VisiblePosition.cpp:
992         (WebCore::VisiblePosition::canonicalPosition):
993
994 2009-02-23  David Hyatt  <hyatt@apple.com>
995
996         Reviewed by Eric Seidel
997
998         https://bugs.webkit.org/show_bug.cgi?id=23740, painting order wrong for normal flow elements with overflow: hidden
999         
1000         This patch reworks the painting of overflow.  There is now the concept of a "self-painting layer."  All
1001         layers are considered to be self-painting except for overflow layers that are normal flow (and that don't have
1002         reflections or masks).
1003         
1004         If an overflow layer is not self-painting, then it ends up painted by its parent just like any other normal flow object.
1005         The only difference is that the clip has to be pushed and popped when painting the object's children.
1006         
1007         The lightweight clipping scheme used for controls has been extended to cover overflow now in this simplified case.  With
1008         the code consolidated into reusable push/pop functions, all of the renderers that use overflow have been patched to
1009         use the new functions.
1010         
1011         Hit testing has also been patched to check the overflow clip rect first before recurring into children.
1012         
1013         Scrollbar paint has been moved into RenderBlock for now, since none of the table objects support scrollbars
1014         yet, and scrollbar hit testing was already there anyway.  Now the two code paths are more symmetrical.
1015         
1016         Masks are now treated like normal flow layers (just like reflections).
1017
1018         A couple of test cases have been added to fast/overflow to test the stacking order. 
1019
1020         * rendering/InlineFlowBox.cpp:
1021         (WebCore::InlineFlowBox::nodeAtPoint):
1022         (WebCore::InlineFlowBox::paint):
1023         * rendering/RenderBlock.cpp:
1024         (WebCore::RenderBlock::repaintOverhangingFloats):
1025         (WebCore::RenderBlock::paint):
1026         (WebCore::RenderBlock::paintChildren):
1027         (WebCore::RenderBlock::paintObject):
1028         (WebCore::RenderBlock::paintFloats):
1029         (WebCore::RenderBlock::insertFloatingObject):
1030         (WebCore::RenderBlock::floatRect):
1031         (WebCore::RenderBlock::lowestPosition):
1032         (WebCore::RenderBlock::rightmostPosition):
1033         (WebCore::RenderBlock::leftmostPosition):
1034         (WebCore::RenderBlock::addOverhangingFloats):
1035         (WebCore::RenderBlock::nodeAtPoint):
1036         (WebCore::RenderBlock::hitTestContents):
1037         * rendering/RenderBox.cpp:
1038         (WebCore::RenderBox::nodeAtPoint):
1039         (WebCore::RenderBox::pushContentsClip):
1040         (WebCore::RenderBox::popContentsClip):
1041         * rendering/RenderBox.h:
1042         (WebCore::RenderBox::paintObject):
1043         * rendering/RenderBoxModelObject.cpp:
1044         (WebCore::RenderBoxModelObject::hasSelfPaintingLayer):
1045         * rendering/RenderBoxModelObject.h:
1046         * rendering/RenderLayer.cpp:
1047         (WebCore::RenderLayer::paintLayer):
1048         (WebCore::RenderLayer::hitTestLayer):
1049         (WebCore::RenderLayer::shouldBeNormalFlowOnly):
1050         (WebCore::RenderLayer::isSelfPaintingLayer):
1051         * rendering/RenderLayer.h:
1052         * rendering/RenderTable.cpp:
1053         (WebCore::RenderTable::paint):
1054         (WebCore::RenderTable::paintObject):
1055         (WebCore::RenderTable::nodeAtPoint):
1056         * rendering/RenderTable.h:
1057         * rendering/RenderTableCell.cpp:
1058         (WebCore::RenderTableCell::paint):
1059         * rendering/RenderTableRow.cpp:
1060         (WebCore::RenderTableRow::nodeAtPoint):
1061         (WebCore::RenderTableRow::paint):
1062         * rendering/RenderTableRow.h:
1063         * rendering/RenderTableSection.cpp:
1064         (WebCore::RenderTableSection::paint):
1065         (WebCore::RenderTableSection::paintObject):
1066         (WebCore::RenderTableSection::nodeAtPoint):
1067         * rendering/RenderTableSection.h:
1068         * rendering/RenderTreeAsText.cpp:
1069         (WebCore::write):
1070         (WebCore::writeLayers):
1071
1072 2009-02-24  David Levin  <levin@chromium.org>
1073
1074         Reviewed by NOBODY (build fix).
1075
1076         Attempted build fix for wx-mac.
1077
1078         * WebCoreSources.bkl:
1079
1080 2009-02-24  David Levin  <levin@chromium.org>
1081
1082         Reviewed by NOBODY (build fix).
1083
1084         Attempted build fixes for qt-linux and wx-mac.
1085
1086         * WebCore.pro:
1087         * webcore-base.bkl:
1088
1089 2009-02-24  Ojan Vafai  <ojan@dhcp-172-31-134-214.sfo.corp.google.com>
1090
1091         Reviewed by Sam Weinig.
1092
1093         Fix null pointer error. If the node is the Document, then ownerDocument() 
1094         returns null, document() does not.
1095
1096         * editing/VisiblePosition.cpp:
1097         (WebCore::VisiblePosition::canonicalPosition):
1098
1099 2009-02-24  Jian Li  <jianli@chromium.org>
1100
1101         Reviewed by NOBODY (attempted build fixes).
1102
1103         Fix build break for Windows and Linux.
1104
1105         * GNUmakefile.am:
1106         * WebCore.vcproj/WebCore.vcproj:
1107
1108 2009-02-24  Dimitri Glazkov  <dglazkov@chromium.org>
1109
1110         Reviewed by Eric Seidel.
1111
1112         https://bugs.webkit.org/show_bug.cgi?id=24131
1113         Fix-up COM/RefCounted dichotomy in Chromium port.
1114
1115         * page/chromium/AccessibilityObjectWrapper.h:
1116         (WebCore::AccessibilityObjectWrapper::AccessibilityObjectWrapper): Added
1117         explicit setting of recount.
1118
1119 2009-02-24  Dimitri Glazkov  <dglazkov@chromium.org>
1120
1121         Reviewed by Eric Seidel.
1122
1123         https://bugs.webkit.org/show_bug.cgi?id=24141
1124         Add clarity to V8 interceptor helper function.
1125
1126         * bindings/v8/custom/V8HTMLPlugInElementCustom.cpp:
1127         (WebCore::NAMED_PROPERTY_GETTER): Renamed to notHandledByInterceptor.
1128         (WebCore::NAMED_PROPERTY_SETTER): Ditto.
1129         (WebCore::INDEXED_PROPERTY_GETTER): Ditto.
1130         (WebCore::INDEXED_PROPERTY_SETTER): Ditto.
1131
1132 2009-02-24  Simon Fraser  <simon.fraser@apple.com>
1133
1134         Reviewed by Eric Seidel
1135
1136         Minor numeric cleanup: convert float literals to doubles.
1137         
1138         * platform/graphics/transforms/RotateTransformOperation.cpp:
1139         (WebCore::RotateTransformOperation::blend):
1140
1141 2009-02-24  Mark Mentovai  <mark@chromium.org>
1142
1143         Reviewed by Eric Seidel.
1144
1145         https://bugs.webkit.org/show_bug.cgi?id=24139
1146         Add missing include.
1147
1148         * bindings/v8/ScriptInstance.h:
1149
1150 2009-02-24  Jian Li  <jianli@chromium.org>
1151
1152         Reviewed by Alexey Proskuryakov.
1153
1154         Move worker related files from dom directory to worker directory under WebCore.
1155         https://bugs.webkit.org/show_bug.cgi?id=24123
1156
1157         * DerivedSources.make:
1158         * GNUmakefile.am:
1159         * WebCore.pro:
1160         * WebCore.scons:
1161         * WebCore.vcproj/MigrateIDLAndScripts:
1162         * WebCore.vcproj/WebCore.vcproj:
1163         * WebCore.xcodeproj/project.pbxproj:
1164         * platform/CrossThreadCopier.cpp: Renamed from WebCore/dom/CrossThreadCopier.cpp.
1165         * platform/CrossThreadCopier.h: Renamed from WebCore/dom/CrossThreadCopier.h.
1166         * workers/GenericWorkerTask.h: Renamed from WebCore/dom/GenericWorkerTask.h.
1167         * workers/Worker.cpp: Renamed from WebCore/dom/Worker.cpp.
1168         * workers/Worker.h: Renamed from WebCore/dom/Worker.h.
1169         * workers/Worker.idl: Renamed from WebCore/dom/Worker.idl.
1170         * workers/WorkerContext.cpp: Renamed from WebCore/dom/WorkerContext.cpp.
1171         * workers/WorkerContext.h: Renamed from WebCore/dom/WorkerContext.h.
1172         * workers/WorkerContext.idl: Renamed from WebCore/dom/WorkerContext.idl.
1173         * workers/WorkerContextProxy.h: Renamed from WebCore/dom/WorkerContextProxy.h.
1174         * workers/WorkerLocation.cpp: Renamed from WebCore/dom/WorkerLocation.cpp.
1175         * workers/WorkerLocation.h: Renamed from WebCore/dom/WorkerLocation.h.
1176         * workers/WorkerLocation.idl: Renamed from WebCore/dom/WorkerLocation.idl.
1177         * workers/WorkerMessagingProxy.cpp: Renamed from WebCore/dom/WorkerMessagingProxy.cpp.
1178         * workers/WorkerMessagingProxy.h: Renamed from WebCore/dom/WorkerMessagingProxy.h.
1179         * workers/WorkerObjectProxy.h: Renamed from WebCore/dom/WorkerObjectProxy.h.
1180         * workers/WorkerRunLoop.cpp: Renamed from WebCore/dom/WorkerRunLoop.cpp.
1181         * workers/WorkerRunLoop.h: Renamed from WebCore/dom/WorkerRunLoop.h.
1182         * workers/WorkerThread.cpp: Renamed from WebCore/dom/WorkerThread.cpp.
1183         * workers/WorkerThread.h: Renamed from WebCore/dom/WorkerThread.h.
1184
1185 2009-02-05  Ojan Vafai  <ojan@chromium.org> and Eric Seidel <eric@webkit.org>
1186
1187         Reviewed by Dave Hyatt.
1188
1189         Make cursor positions match IE6/IE7/FF3 when clicking in margins/padding
1190         around divs inside editable regions.
1191         https://bugs.webkit.org/show_bug.cgi?id=23605
1192
1193         Fix clicks outside editable regions from focusing the editable region.
1194         https://bugs.webkit.org/show_bug.cgi?id=23607
1195
1196         Removed editing/selection/contenteditable-click-outside.html as it's
1197         not as useful as our new tests.
1198
1199         Clean up RenderBlock::positionForCoordinates to remove dead code,
1200         duplicate code, and generally make it more readable.
1201
1202         Tests: editing/selection/click-in-margins-inside-editable-div.html
1203                editing/selection/click-in-padding-with-multiple-line-boxes.html
1204                editing/selection/click-outside-editable-div.html
1205
1206         * editing/VisiblePosition.cpp:
1207         (WebCore::VisiblePosition::canonicalPosition):
1208         * rendering/RenderBlock.cpp:
1209         (WebCore::positionForPointRespectingEditingBoundaries):
1210         (WebCore::positionForPointWithInlineChildren):
1211         (WebCore::RenderBlock::positionForCoordinates):
1212         (WebCore::RenderBlock::updateFirstLetter):
1213
1214 2009-02-24  Sam Weinig  <sam@webkit.org>
1215
1216         Reviewed by Geoffrey Garen.
1217
1218         Related to <rdar://problem/6590295>
1219         Allow disabling javascript: urls.
1220
1221         * WebCore.base.exp:
1222         * html/HTMLAnchorElement.cpp:
1223         (WebCore::HTMLAnchorElement::parseMappedAttribute):
1224         * loader/FrameLoader.cpp:
1225         (WebCore::FrameLoader::executeIfJavaScriptURL):
1226         * page/Page.cpp:
1227         (WebCore::Page::Page):
1228         (WebCore::Page::setJavaScriptURLsAreAllowed):
1229         (WebCore::Page::javaScriptURLsAreAllowed):
1230         * page/Page.h:
1231
1232 2009-02-24  Simon Fraser  <simon.fraser@apple.com>
1233
1234         Fix build when ACCELERATED_COMPOSITING is turned on
1235         (overflowList() -> normalFlowList()).
1236     
1237         * rendering/RenderLayerBacking.cpp:
1238         (WebCore::RenderLayerBacking::hasNonCompositingContent):
1239         (WebCore::RenderLayerBacking::paintIntoLayer):
1240         * rendering/RenderLayerCompositor.cpp:
1241         (WebCore::RenderLayerCompositor::calculateCompositedBounds):
1242         (WebCore::RenderLayerCompositor::computeCompositingRequirements):
1243         (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
1244         (WebCore::RenderLayerCompositor::recursiveRepaintLayerRect):
1245         (WebCore::RenderLayerCompositor::layerHas3DContent):
1246
1247 2009-02-24  Simon Fraser  <simon.fraser@apple.com>
1248
1249         Reviewed by Darin Adler
1250         
1251         https://bugs.webkit.org/show_bug.cgi?id=24135
1252         
1253         Round the FloatPoint returned by absoluteToLocal(), rather than
1254         truncating it.
1255
1256         * dom/MouseRelatedEvent.cpp:
1257         (WebCore::MouseRelatedEvent::receivedTarget):
1258
1259 2009-02-24  Beth Dakin  <bdakin@apple.com>
1260
1261         Reviewed by Sam Weinig.
1262
1263         Fix for https://bugs.webkit.org/show_bug.cgi?id=24004 REGRESSION: 
1264         Ordered list item marker misaligned when line height is not 1.2 
1265         -and corresponding <rdar://problem/6602506>
1266
1267         This is a regression from http://trac.webkit.org/changeset/40880 
1268         where createInlineBox was taken off of RenderObject and moved to 
1269         RenderBox. The problem was that the RenderBox version still needs 
1270         to be virtual because there is still an existing implementation in 
1271         RenderListMarker. 
1272
1273         * rendering/RenderBox.h:
1274         * rendering/RenderListMarker.cpp:
1275         (WebCore::RenderListMarker::createInlineBox):
1276         * rendering/RenderListMarker.h:
1277
1278 2009-02-24  Dimitri Glazkov  <dglazkov@chromium.org>
1279
1280         Reviewed by Eric Seidel.
1281
1282         https://bugs.webkit.org/show_bug.cgi?id=24128
1283         Upstream more V8 custom bindings: constructors, XSLTProcessor.
1284
1285         * bindings/v8/custom/V8DOMParserConstructor.cpp: Added.
1286         (WebCore::CALLBACK_FUNC_DECL):
1287         * bindings/v8/custom/V8MessageChannelConstructor.cpp: Added.
1288         (WebCore::CALLBACK_FUNC_DECL):
1289         * bindings/v8/custom/V8WebKitCSSMatrixConstructor.cpp: Added.
1290         (WebCore::CALLBACK_FUNC_DECL):
1291         * bindings/v8/custom/V8XMLSerializerConstructor.cpp: Added.
1292         (WebCore::CALLBACK_FUNC_DECL):
1293         * bindings/v8/custom/V8XPathEvaluatorConstructor.cpp: Added.
1294         (WebCore::CALLBACK_FUNC_DECL):
1295         * bindings/v8/custom/V8XSLTProcessorCustom.cpp: Added.
1296         (WebCore::CALLBACK_FUNC_DECL):
1297
1298 2009-02-24  David Levin  <levin@chromium.org>
1299
1300         Reviewed by Alexey Proskuryakov.
1301
1302         Bug 24090: WorkerThreadableLoader needs to be able to post tasks for a mode.
1303         <https://bugs.webkit.org/show_bug.cgi?id=24090>
1304
1305         No observable change in behavior, so no test.
1306
1307         * dom/WorkerMessagingProxy.cpp:
1308         (WebCore::WorkerMessagingProxy::postMessageToWorkerContext):
1309         (WebCore::WorkerMessagingProxy::postTaskToWorkerContext):
1310         Fixed the bug that m_unconfirmedMessageCount was getting incremented for non-message tasks.
1311
1312         (WebCore::WorkerMessagingProxy::postTaskForModeToWorkerContext):
1313
1314         * dom/WorkerMessagingProxy.h:
1315         * loader/ThreadableLoader.cpp:
1316         (WebCore::ThreadableLoader::create):
1317         * loader/WorkerThreadableLoader.cpp:
1318         (WebCore::WorkerThreadableLoader::WorkerThreadableLoader):
1319         (WebCore::WorkerThreadableLoader::MainThreadBridge::MainThreadBridge):
1320         (WebCore::WorkerThreadableLoader::MainThreadBridge::didSendData):
1321         (WebCore::WorkerThreadableLoader::MainThreadBridge::didReceiveResponse):
1322         (WebCore::WorkerThreadableLoader::MainThreadBridge::didReceiveData):
1323         (WebCore::WorkerThreadableLoader::MainThreadBridge::didFinishLoading):
1324         (WebCore::WorkerThreadableLoader::MainThreadBridge::didFail):
1325         (WebCore::WorkerThreadableLoader::MainThreadBridge::didFailRedirectCheck):
1326         (WebCore::WorkerThreadableLoader::MainThreadBridge::didReceiveAuthenticationCancellation):
1327         Changed these methods to post task using a mode.
1328
1329         * loader/WorkerThreadableLoader.h:
1330         (WebCore::WorkerThreadableLoader::create):
1331
1332 2009-02-24  Alexey Proskuryakov  <ap@webkit.org>
1333
1334         Reviewed by Darin Adler.
1335
1336         https://bugs.webkit.org/show_bug.cgi?id=24091
1337         <rdar://problem/6468660> Start of redirect chain ends up as master entry in Application Cache
1338
1339         Test: http/tests/appcache/access-via-redirect.php
1340
1341         * loader/appcache/ApplicationCacheGroup.cpp:
1342         (WebCore::ApplicationCacheGroup::finishedLoadingMainResource): Use the URL we ended up with,
1343         not the original one.
1344
1345 2009-02-24  Jian Li  <jianli@chromium.org>
1346
1347         Reviewed by Alexey Proskuryakov.
1348
1349         Change to include WorkerObjectProxy.h instead of WorkerMessagingProxy.h in WorkerContext.cpp and WorkerScriptController.cpp.
1350         https://bugs.webkit.org/show_bug.cgi?id=24112
1351
1352         * bindings/js/WorkerScriptController.cpp:
1353         * dom/WorkerContext.cpp:
1354
1355 2009-02-23  Antti Koivisto  <antti@apple.com>
1356
1357         Reviewed by Oliver Hunt.
1358
1359         <rdar://problem/6613796> Extended text codecs registered on webview creation
1360
1361         Comparing a text encoding with string "GBK" ended up constructing
1362         TextEncoding("GBK") which in turn initialized all extended
1363         text codecs.
1364
1365         * platform/text/TextCodecICU.cpp:
1366         (WebCore::TextCodecICU::decode):
1367
1368 2009-02-23  Sam Weinig  <sam@webkit.org>
1369
1370         Fix Qt build.
1371
1372         * bridge/qt/qt_runtime.cpp:
1373         (JSC::Bindings::valueRealType):
1374
1375 2009-02-23  Julien Chaffraix  <jchaffraix@webkit.org>
1376
1377         Reviewed by Darin Adler.
1378
1379         Bug 23956: Safari crashes when cloneNode fails (cloning a XML element with an invalid nodeName)
1380
1381         The crash occurred because Document::cloneNode would call Document::createElementNS. Unfortunately
1382         element created with createElement could have a wrong nodeName (createElement sets the string as the
1383         localName without checking for a prefix).
1384
1385         The fix is to call Document::createElement(const QualifiedName&, bool) that will not do any checks on the QualifiedName
1386         and will always succeed.
1387         Also rolled-out the HTMLElement specialisation of clonedNode as it was equivalent to what is done now (added an ASSERT
1388         to ensure that).
1389
1390         Test: fast/dom/cloneNode.html
1391
1392         * dom/Element.cpp:
1393         (WebCore::Element::cloneNode): Call createElement(const QualifiedName&, bool) instead of createElementNS as it will
1394         always return an element.
1395
1396         * html/HTMLElement.cpp:
1397         * html/HTMLElement.h: Removed HTMLElement::clonedNode as it is equivalent to what is now done.
1398
1399 2009-02-23  Dimitri Glazkov  <dglazkov@chromium.org>
1400
1401         Reviewed by Eric Seidel.
1402
1403         https://bugs.webkit.org/show_bug.cgi?id=24109
1404         Upstream V8 Script abstractions, all except ScriptController.
1405
1406         * bindings/v8/ScriptCachedFrameData.h: Added.
1407         (WebCore::ScriptCachedFrameData::ScriptCachedFrameData):
1408         (WebCore::ScriptCachedFrameData::~ScriptCachedFrameData):
1409         (WebCore::ScriptCachedFrameData::restore):
1410         (WebCore::ScriptCachedFrameData::clear):
1411         (WebCore::ScriptCachedFrameData::domWindow):
1412         * bindings/v8/ScriptCallFrame.cpp: Added.
1413         (WebCore::ScriptCallFrame::ScriptCallFrame):
1414         (WebCore::ScriptCallFrame::~ScriptCallFrame):
1415         (WebCore::ScriptCallFrame::argumentAt):
1416         * bindings/v8/ScriptCallFrame.h: Added.
1417         (WebCore::ScriptCallFrame::functionName):
1418         (WebCore::ScriptCallFrame::sourceURL):
1419         (WebCore::ScriptCallFrame::lineNumber):
1420         (WebCore::ScriptCallFrame::argumentCount):
1421         * bindings/v8/ScriptCallStack.cpp: Added.
1422         (WebCore::ScriptCallStack::ScriptCallStack):
1423         (WebCore::ScriptCallStack::~ScriptCallStack):
1424         (WebCore::ScriptCallStack::at):
1425         * bindings/v8/ScriptCallStack.h: Added.
1426         (WebCore::ScriptCallStack::size):
1427         * bindings/v8/ScriptInstance.cpp: Added.
1428         (WebCore::V8ScriptInstance::V8ScriptInstance):
1429         (WebCore::V8ScriptInstance::~V8ScriptInstance):
1430         (WebCore::V8ScriptInstance::instance):
1431         (WebCore::V8ScriptInstance::clear):
1432         (WebCore::V8ScriptInstance::set):
1433         * bindings/v8/ScriptInstance.h: Added.
1434         (WebCore::V8ScriptInstance::create):
1435         * bindings/v8/ScriptSourceCode.h: Added.
1436         (WebCore::ScriptSourceCode::ScriptSourceCode):
1437         (WebCore::ScriptSourceCode::isEmpty):
1438         (WebCore::ScriptSourceCode::source):
1439         (WebCore::ScriptSourceCode::url):
1440         (WebCore::ScriptSourceCode::startLine):
1441         * bindings/v8/ScriptState.h: Added.
1442         (WebCore::ScriptState::hadException):
1443         (WebCore::ScriptState::setException):
1444         (WebCore::ScriptState::exception):
1445         * bindings/v8/ScriptString.h: Added.
1446         (WebCore::ScriptString::ScriptString):
1447         (WebCore::ScriptString::operator String):
1448         (WebCore::ScriptString::isNull):
1449         (WebCore::ScriptString::size):
1450         (WebCore::ScriptString::operator=):
1451         (WebCore::ScriptString::operator+=):
1452         * bindings/v8/ScriptValue.cpp: Added.
1453         (WebCore::ScriptValue::getString):
1454         * bindings/v8/ScriptValue.h: Added.
1455         (WebCore::ScriptValue::ScriptValue):
1456         (WebCore::ScriptValue::operator=):
1457         (WebCore::ScriptValue::operator==):
1458         (WebCore::ScriptValue::operator!=):
1459         (WebCore::ScriptValue::isNull):
1460         (WebCore::ScriptValue::isUndefined):
1461         (WebCore::ScriptValue::clear):
1462         (WebCore::ScriptValue::~ScriptValue):
1463         (WebCore::ScriptValue::v8Value):
1464
1465 2009-02-23  Adam Treat  <adam.treat@torchmobile.com>
1466
1467         Reviewed by Timothy Hatcher.
1468
1469         https://bugs.webkit.org/show_bug.cgi?id=24106
1470         The Qt port is crashing on exit because the tear down procedure involves
1471         the WebCore::InspectorController trying to access the JS execution context
1472         for a page that is being deleted.  This patch amends the inspector so
1473         that it does not try and access the execution context of the WebCore::Page
1474         in the midst of deletion.
1475
1476         * inspector/InspectorController.cpp:
1477         (WebCore::InspectorController::inspectedPageDestroyed):
1478         (WebCore::InspectorController::stopUserInitiatedProfiling):
1479
1480 2009-02-23  David Levin  <levin@chromium.org>
1481
1482         Reviewed by Alexey Proskuryakov.
1483
1484         Bug 24088: ThreadableLoaderClient::didFailWillSendRequestCheck isn't wired up completely for workers and could use a better name.
1485         <https://bugs.webkit.org/show_bug.cgi?id=24088>
1486
1487         No observable change in behavior, so no test.
1488
1489         * loader/DocumentThreadableLoader.cpp:
1490         (WebCore::DocumentThreadableLoader::create):
1491         * loader/ThreadableLoaderClient.h:
1492         (WebCore::ThreadableLoaderClient::didFailRedirectCheck):
1493         * loader/ThreadableLoaderClientWrapper.h:
1494         (WebCore::ThreadableLoaderClientWrapper::didFailRedirectCheck):
1495         * loader/WorkerThreadableLoader.cpp:
1496         (WebCore::workerContextDidFailRedirectCheck):
1497         (WebCore::WorkerThreadableLoader::MainThreadBridge::didFailRedirectCheck):
1498         * loader/WorkerThreadableLoader.h:
1499         * xml/XMLHttpRequest.cpp:
1500         (WebCore::XMLHttpRequest::didFinishLoading):
1501         * xml/XMLHttpRequest.h:
1502
1503 2009-02-23  David Levin  <levin@chromium.org>
1504
1505         Reviewed by Alexey Proskuryakov.
1506
1507         Bug 24047: Need to simplify nested if's in WorkerRunLoop::runInMode
1508         <https://bugs.webkit.org/show_bug.cgi?id=24047>
1509
1510         Made a nested if inside of WorkerRunLoop::runInMode a lot simpler by
1511         using only MessageQueue::waitForMessageFilteredWithTimeout instead
1512         of three different MessageQueue methods.
1513
1514         No observable change in behavior, so no test.
1515
1516         * dom/WorkerRunLoop.cpp:
1517         (WebCore::ModePredicate::operator()):
1518         Minor clean-up to able to pass a const ref point for ModePredicate into runInMode.
1519         (WebCore::WorkerRunLoop::runInMode):
1520         * dom/WorkerRunLoop.h:
1521
1522 2009-02-23  David Hyatt  <hyatt@apple.com>
1523
1524         In preparation for making layers for multicol objects (so that they can properly split child layers
1525         into multiple columns), rename all of the "overflowOnly" and "overflowList" members and functions
1526         of RenderLayer to use the term "normal flow" instead.
1527
1528         Reviewed by Cameron Zwarich
1529
1530         * rendering/RenderLayer.cpp:
1531         (WebCore::RenderLayer::RenderLayer):
1532         (WebCore::RenderLayer::~RenderLayer):
1533         (WebCore::RenderLayer::setHasVisibleContent):
1534         (WebCore::RenderLayer::enclosingCompositingLayer):
1535         (WebCore::RenderLayer::addChild):
1536         (WebCore::RenderLayer::removeChild):
1537         (WebCore::RenderLayer::paintLayer):
1538         (WebCore::RenderLayer::hitTestLayer):
1539         (WebCore::RenderLayer::dirtyNormalFlowList):
1540         (WebCore::RenderLayer::updateNormalFlowList):
1541         (WebCore::RenderLayer::collectLayers):
1542         (WebCore::RenderLayer::updateLayerListsIfNeeded):
1543         (WebCore::RenderLayer::shouldBeNormalFlowOnly):
1544         (WebCore::RenderLayer::styleChanged):
1545         * rendering/RenderLayer.h:
1546         (WebCore::RenderLayer::isNormalFlowOnly):
1547         (WebCore::RenderLayer::normalFlowList):
1548         * rendering/RenderTreeAsText.cpp:
1549         (WebCore::writeLayers):
1550
1551 2009-02-23  David Hyatt  <hyatt@apple.com>
1552
1553         Fix the stacking order for column rules in multi-column layout.  Column rules should paint as part of the background of an element, just
1554         after all other components of the background have been painted.  This allows negative z-index children to still paint on top of the
1555         column rules (rather than ending up above the background of the box but behind the column rules).
1556
1557         Reviewed by Eric Seidel
1558
1559         Added fast/multicol/column-rules-stacking.html
1560
1561         * rendering/RenderBlock.cpp:
1562         (WebCore::RenderBlock::paintColumnRules):
1563         (WebCore::RenderBlock::paintColumnContents):
1564         (WebCore::RenderBlock::paintObject):
1565         * rendering/RenderBlock.h:
1566
1567 2009-02-23  Adam Treat  <adam.treat@torchmobile.com>
1568
1569         Reviewed by David Hyatt.
1570
1571         No testcases have been added or modified since this patch should not result in
1572         a behavior change for ports that have layout tests enabled.
1573
1574         Currently, the implementation of GraphicsContext::drawLineForText amongst
1575         the various ports differ in that some of them are honoring the context's
1576         strokeStyle when drawing a text-decoration and some of them are not.
1577         For instance, Apple's Mac port *does not* honor the context's strokeStyle(),
1578         but the Cairo implementation does and has an explicit workaround that
1579         sets the strokeStyle() temporarily.
1580
1581         This patch fixes so that all ports are consistent by explicitly making sure
1582         to set the GraphicsContext strokeStyle to SolidStroke whenever
1583         painting the text-decoration of an InlineFlowBox or InlineTextBox as these
1584         should always use a solid stroke.
1585
1586         This patch addresses these bugs:
1587         https://bugs.webkit.org/show_bug.cgi?id=19364
1588         https://bugs.webkit.org/show_bug.cgi?id=15659
1589
1590         * rendering/InlineFlowBox.cpp:
1591         (WebCore::InlineFlowBox::paintTextDecorations):
1592         * rendering/InlineTextBox.cpp:
1593         (WebCore::InlineTextBox::paintDecoration):
1594
1595 2009-02-23  Scott Violet  <sky@google.com>
1596
1597         Reviewed by Eric Seidel.
1598
1599         https://bugs.webkit.org/show_bug.cgi?id=24098
1600         Bugs in ClipboardChromium
1601
1602         Fixes the following bugs in ClipboardChromium:
1603         * It's possible for the extension to be empty, resulting in a bad file
1604           name, for example, 'foo.' or just '.'.
1605         * We weren't restricting the size of the file to MAX_PATH.
1606         * We weren't removing characters that are invalid for file system names.
1607
1608         * platform/chromium/ClipboardChromium.cpp:
1609         (WebCore::writeImageToDataObject):
1610         * platform/chromium/ClipboardChromium.h:
1611         * platform/chromium/ClipboardChromiumLinux.cpp: Added.
1612         (WebCore::ClipboardChromium::validateFileName):
1613         * platform/chromium/ClipboardChromiumMac.cpp: Added.
1614         (WebCore::ClipboardChromium::validateFileName):
1615         * platform/chromium/ClipboardChromiumWin.cpp: Added.
1616         (WebCore::isInvalidFileCharacter):
1617         (WebCore::ClipboardChromium::validateFileName):
1618
1619 2009-02-23  Thiago Macieira  <thiago.macieira@nokia.com>
1620
1621         Reviewed by Simon Hausmann.
1622
1623         Fix the Copyright notices in a few files
1624
1625         * platform/qt/RenderThemeQt.h:
1626
1627 2009-02-23  Xan Lopez  <xan@gnome.org>
1628
1629         Reviewed by Alexey Proskuryakov.
1630
1631         https://bugs.webkit.org/show_bug.cgi?id=22624
1632         [SOUP][GTK] Need API to get SoupSession from WebKit.
1633
1634         Allow to retrieve the Soup session and modify the code to take
1635         into account users changing features on it.
1636
1637         * platform/network/ResourceHandle.h:
1638         * platform/network/soup/CookieJarSoup.cpp:
1639         (WebCore::defaultCookieJar):
1640         (WebCore::setDefaultCookieJar):
1641         * platform/network/soup/CookieJarSoup.h:
1642         * platform/network/soup/ResourceHandleSoup.cpp:
1643         (WebCore::createSoupSession):
1644         (WebCore::ensureSessionIsInitialized):
1645         (WebCore::ResourceHandle::startHttp):
1646         (WebCore::ResourceHandle::cancel):
1647         (WebCore::ResourceHandle::defaultSession):
1648
1649 2009-02-23  Xan Lopez  <xan@gnome.org>
1650
1651         Reviewed by Alexey Proskuryakov.
1652
1653         https://bugs.webkit.org/show_bug.cgi?id=22624
1654         [SOUP][GTK] Need API to get SoupSession from WebKit.
1655
1656         Remove CURL support.
1657
1658         * GNUmakefile.am:
1659
1660 2009-02-23  Alexey Proskuryakov  <ap@webkit.org>
1661
1662         Reviewed by Mark Rowe.
1663
1664         Test: fast/dom/empty-hash-and-search.html
1665
1666         https://bugs.webkit.org/show_bug.cgi?id=21147
1667         hash property returns incorrect value for links w/o hash
1668
1669         Make hash() and search() behavior for empty and missing parts match IE and Firefox.
1670
1671         * platform/KURL.cpp:
1672         (WebCore::KURL::query): Changed to return query without '?', as it is already done for ref().
1673         (WebCore::KURL::prettyURL): Append the query with the question mark.
1674
1675         * page/Location.cpp:
1676         (WebCore::Location::search): Return an empty string if query is empty or missing.
1677         (WebCore::Location::hash): Return an empty string for empty hashes, not only missing ones.
1678
1679         * dom/WorkerLocation.cpp:
1680         (WebCore::WorkerLocation::search):
1681         (WebCore::WorkerLocation::hash):
1682         Match document.location fixes above.
1683
1684         * html/HTMLAnchorElement.cpp:
1685         (WebCore::HTMLAnchorElement::hash):
1686         (WebCore::HTMLAnchorElement::search):
1687         Return an empty string for empty and missing parts.
1688
1689 2009-02-23  Alexey Proskuryakov  <ap@webkit.org>
1690
1691         Reviewed by Darin Adler.
1692
1693         https://bugs.webkit.org/show_bug.cgi?id=20184
1694         SELECT with no name generates invalid query string
1695
1696         Test: fast/forms/select-no-name.html
1697
1698         * html/HTMLSelectElement.cpp:
1699         (WebCore::HTMLSelectElement::appendFormData): Added a check for empty name.
1700
1701 2009-02-23  Alexey Proskuryakov  <ap@webkit.org>
1702
1703         Apply review comments for the previous check-in (forgot to save the file, oops).
1704
1705         * dom/ContainerNode.cpp: (WebCore::ContainerNode::removeChildren):
1706
1707 2009-02-23  Alexey Proskuryakov  <ap@webkit.org>
1708
1709         Reviewed by Darin Adler.
1710
1711         https://bugs.webkit.org/show_bug.cgi?id=15707
1712         Crash when manipulating document from within an iframe onload function
1713
1714         Test: fast/dom/onload-open.html
1715
1716         * dom/ContainerNode.cpp: (WebCore::ContainerNode::removeChildren): Protect the container and
1717         the current node, because anything can happen when dispatching events.
1718
1719 2009-02-23  Alexey Proskuryakov  <ap@webkit.org>
1720
1721         Reviewed by Darin Adler.
1722
1723         https://bugs.webkit.org/show_bug.cgi?id=18970
1724         Numerically named input fields cause document.forms loop problems
1725
1726         Test: fast/forms/numeric-input-name.html
1727
1728         * bindings/scripts/CodeGeneratorJS.pm: Try index getter before name getter, even if the
1729         latter overrides properties.
1730
1731 2009-02-23  Alexey Proskuryakov  <ap@webkit.org>
1732
1733         Reviewed by Sam Weinig.
1734
1735         https://bugs.webkit.org/show_bug.cgi?id=24059
1736         Tokenizer::write() return value is never used
1737
1738         * dom/Tokenizer.h:
1739         * dom/XMLTokenizer.cpp:
1740         (WebCore::XMLTokenizer::write):
1741         * dom/XMLTokenizer.h:
1742         * html/HTMLTokenizer.cpp:
1743         (WebCore::HTMLTokenizer::write):
1744         * html/HTMLTokenizer.h:
1745         * loader/FTPDirectoryDocument.cpp:
1746         (WebCore::FTPDirectoryTokenizer::write):
1747         * loader/ImageDocument.cpp:
1748         (WebCore::ImageTokenizer::write):
1749         * loader/MediaDocument.cpp:
1750         (WebCore::MediaTokenizer::write):
1751         * loader/PluginDocument.cpp:
1752         (WebCore::PluginTokenizer::write):
1753         * loader/TextDocument.cpp:
1754         (WebCore::TextTokenizer::write):
1755         Made write() return void, not bool.
1756
1757 2009-02-20  Geoffrey Garen  <ggaren@apple.com>
1758
1759         Reviewed by Sam Weinig.
1760
1761         Updated for JavaScriptCore changes to timeout checking.
1762
1763         * bindings/js/JSCustomPositionCallback.cpp:
1764         (WebCore::JSCustomPositionCallback::handleEvent):
1765         * bindings/js/JSCustomPositionErrorCallback.cpp:
1766         (WebCore::JSCustomPositionErrorCallback::handleEvent):
1767         * bindings/js/JSCustomSQLStatementCallback.cpp:
1768         (WebCore::JSCustomSQLStatementCallback::handleEvent):
1769         * bindings/js/JSCustomSQLStatementErrorCallback.cpp:
1770         (WebCore::JSCustomSQLStatementErrorCallback::handleEvent):
1771         * bindings/js/JSCustomSQLTransactionCallback.cpp:
1772         (WebCore::JSCustomSQLTransactionCallback::handleEvent):
1773         * bindings/js/JSCustomSQLTransactionErrorCallback.cpp:
1774         (WebCore::JSCustomSQLTransactionErrorCallback::handleEvent):
1775         * bindings/js/JSCustomVoidCallback.cpp:
1776         (WebCore::JSCustomVoidCallback::handleEvent):
1777         * bindings/js/JSCustomXPathNSResolver.cpp:
1778         (WebCore::JSCustomXPathNSResolver::lookupNamespaceURI):
1779         * bindings/js/JSDOMWindowBase.cpp:
1780         (WebCore::JSDOMWindowBase::JSDOMWindowBase):
1781         (WebCore::JSDOMWindowBase::commonJSGlobalData):
1782         * bindings/js/JSEventListener.cpp:
1783         (WebCore::JSAbstractEventListener::handleEvent):
1784         * bindings/js/ScheduledAction.cpp:
1785         (WebCore::ScheduledAction::executeFunctionInContext):
1786         * bindings/js/ScriptController.cpp:
1787         (WebCore::ScriptController::evaluate):
1788         * bindings/js/WorkerScriptController.cpp:
1789         (WebCore::WorkerScriptController::evaluate):
1790         (WebCore::WorkerScriptController::forbidExecution):
1791         * bindings/objc/WebScriptObject.mm:
1792         (-[WebScriptObject callWebScriptMethod:withArguments:]):
1793         (-[WebScriptObject evaluateWebScript:]):
1794         * bridge/NP_jsobject.cpp:
1795         (_NPN_InvokeDefault):
1796         (_NPN_Invoke):
1797         (_NPN_Evaluate):
1798         (_NPN_Construct):
1799         * bridge/jni/jni_jsobject.mm:
1800         (JavaJSObject::call):
1801         (JavaJSObject::eval):
1802
1803 2009-02-21  Hironori Bono  <hbono@chromium.org>
1804
1805         Reviewed by Alexey Proskuryakov.
1806
1807         https://bugs.webkit.org/show_bug.cgi?id=23786
1808         [Chromium] line-break characters in a complex text are treated as zero-width spaces
1809
1810         This change prevents the UniscribeHelper class from treating the line-break characters
1811         as whitespaces.
1812
1813         Tests: fast/text/international/bidi-linebreak-001.html
1814                fast/text/international/bidi-linebreak-002.html
1815                fast/text/international/bidi-linebreak-003.html
1816
1817         * platform/graphics/chromium/UniscribeHelper.cpp:
1818         (WebCore::UniscribeHelper::adjustSpaceAdvances):
1819         Make the UniscribeHelper::adjustSpaceAdvances() function treat all characters in
1820         the treatAsSpace() function (e.g. U+0020, U+000A, U+000D, U+00A0) as whitespaces,
1821         so does when Chromium renders a simple text.
1822
1823 2009-02-20  Julien Chaffraix  <jchaffraix@webkit.org>
1824
1825         Reviewed by Alexey Proskuryakov.
1826
1827         Bug 23940: Use Document::createElement(const QualifiedName&, bool) when creating a known element inside WebCore
1828
1829         Document::createElement(const QualifiedName&, bool) does not check for the prefix as opposed the the one taking an AtomicString
1830         or Document::createElementNS. This is perfectly fine internally because we know the type of element created and the check is
1831         unneeded.
1832
1833         It also removes the use of an ExceptionCode argument which was here only to check that the prefix check was fine. Finally it
1834         enables us to use some generated QualifiedName.
1835
1836         * bindings/js/JSOptionConstructor.cpp:
1837         (WebCore::constructHTMLOptionElement):
1838         * dom/Document.cpp:
1839         (WebCore::Document::setTitle):
1840         * dom/XMLTokenizer.cpp:
1841         (WebCore::createXHTMLParserErrorHeader):
1842         (WebCore::XMLTokenizer::insertErrorMessageBlock):
1843         * editing/CompositeEditCommand.cpp:
1844         (WebCore::createBlockPlaceholderElement):
1845         * editing/htmlediting.cpp:
1846         (WebCore::createTabSpanElement):
1847         * html/HTMLSelectElement.cpp:
1848         (WebCore::HTMLSelectElement::setLength):
1849         * loader/FTPDirectoryDocument.cpp:
1850         (WebCore::FTPDirectoryTokenizer::appendEntry):
1851         (WebCore::FTPDirectoryTokenizer::createTDForFilename):
1852         (WebCore::FTPDirectoryTokenizer::loadDocumentTemplate):
1853         (WebCore::FTPDirectoryTokenizer::createBasicDocument):
1854         * loader/ImageDocument.cpp:
1855         (WebCore::ImageDocument::createDocumentStructure):
1856         * loader/MediaDocument.cpp:
1857         (WebCore::MediaTokenizer::createDocumentStructure):
1858         * loader/PluginDocument.cpp:
1859         (WebCore::PluginTokenizer::createDocumentStructure):
1860         * loader/TextDocument.cpp:
1861         (WebCore::TextTokenizer::write):
1862         * page/Frame.cpp:
1863         (WebCore::Frame::selectionComputedStyle):
1864         (WebCore::Frame::styleForSelectionStart):
1865         Document::createElement(const AtomicString&, ...) to Document::createElement(const QualifiedName&, ...) switch.
1866
1867         * xml/XPathFunctions.cpp:
1868         (WebCore::XPath::FunLang::evaluate): Re-use langAttr instead of creating a new attribute.
1869         * page/DragController.cpp:
1870         (WebCore::documentFragmentFromDragData): Use the HTMLAnchorElement directly to get rid of the static cast.
1871
1872 2009-02-19  Dimitri Glazkov  <dglazkov@chromium.org>
1873
1874         Reviewed by Eric Seidel.
1875
1876         https://bugs.webkit.org/show_bug.cgi?id=24060
1877         Fix up to accommodate for CanvasPixelArray return.
1878
1879         * platform/graphics/skia/ImageBufferSkia.cpp:
1880         (WebCore::ImageBuffer::getImageData): Added an extra data() to call.
1881         (WebCore::ImageBuffer::putImageData): Ditto.
1882
1883 2009-02-20  Eric Carlson  <eric.carlson@apple.com>
1884
1885         Simon Fraser
1886
1887         https://bugs.webkit.org/show_bug.cgi?id=24042
1888         Bug 24042: MediaPlayer should cache plug-in proxy
1889
1890         The changes in https://bugs.webkit.org/show_bug.cgi?id=23917 assume that
1891         MediaPlayer will always have created the private media player object before
1892         the plug-in is instantiated and calls back with the proxy object. This is not
1893         true on all platforms because of threading latency, so MediaPlayer should
1894         cache the plug-in proxy so it can pass it to the media engine at a later time.
1895
1896         * platform/graphics/MediaPlayer.cpp:
1897         (WebCore::NullMediaPlayerPrivate::setPoster): Null media engine implementation of proxy methods.
1898         (WebCore::NullMediaPlayerPrivate::deliverNotification): Ditto.
1899         (WebCore::NullMediaPlayerPrivate::setMediaPlayerProxy): Ditto.
1900         (WebCore::MediaPlayer::MediaPlayer): Initialize m_playerProxy.
1901         (WebCore::MediaPlayer::load): Pass m_playerProxy to newly created engine.
1902         (WebCore::MediaPlayer::setMediaPlayerProxy): Cache m_playerProxy.
1903         * platform/graphics/MediaPlayer.h: Declare m_playerProxy.
1904
1905 2009-02-20  Eric Carlson  <eric.carlson@apple.com>
1906
1907         Simon Fraser.
1908
1909         https://bugs.webkit.org/show_bug.cgi?id=24063
1910         Make it possible for a port to require a user gesture to play/pause an <audio> or <video> element
1911
1912         * html/HTMLMediaElement.cpp:
1913         (WebCore::HTMLMediaElement::HTMLMediaElement):  Rename m_loadRestrictions to m_Restrictions.
1914         Initialize m_internalCall.
1915         (WebCore::HTMLMediaElement::loadTimerFired): Increment m_internalCall around call to load().
1916         (WebCore::HTMLMediaElement::load): Call loadInternal if restrictions check out.
1917         (WebCore::HTMLMediaElement::loadInternal): New, guts of old load()
1918         (WebCore::HTMLMediaElement::setNetworkState): Fix bug introduced in r40943
1919         (WebCore::HTMLMediaElement::play): Call playInternal if restrictions check out.
1920         (WebCore::HTMLMediaElement::playInternal): New, guts of old play()
1921         (WebCore::HTMLMediaElement::pause): Call pauseInternal if restrictions check out.
1922         (WebCore::HTMLMediaElement::pauseInternal): New, guts of old pause()
1923         (WebCore::HTMLMediaElement::togglePlayState): Call playInternal/pauseInternal
1924         (WebCore::HTMLMediaElement::deliverNotification): Remove unnecessary white space.
1925         * html/HTMLMediaElement.h: Rename m_loadRestrictions to m_Restrictions, add m_internalCall,
1926         add RequireUserGestureRateChangeRestriction.
1927
1928 2009-02-20  Darin Fisher  <darin@chromium.org>
1929
1930         Fix build bustage in FileSystemWin.cpp.
1931
1932         Need to return CString() instead of 0 since there are now two CString
1933         constructors that take a pointer type.
1934
1935         * platform/win/FileSystemWin.cpp:
1936         (WebCore::openTemporaryFile):
1937
1938 2009-02-20  Dimitri Glazkov  <dglazkov@chromium.org>
1939
1940         Reviewed by Sam Weinig.
1941
1942         https://bugs.webkit.org/show_bug.cgi?id=23999
1943         Change license headers to accurately reflect code history.
1944
1945         * platform/ContentType.cpp:
1946         * platform/ContentType.h:
1947
1948 2009-02-18  Dimitri Glazkov  <dglazkov@chromium.org>
1949
1950         Reviewed by Antti Koivisto.
1951
1952         https://bugs.webkit.org/show_bug.cgi?id=23999
1953         Split off MIME type parsing into its own class.
1954
1955         * GNUmakefile.am: Added ContentType sources.
1956         * WebCore.pro: Ditto.
1957         * WebCore.scons: Ditto.
1958         * WebCore.vcproj/WebCore.vcproj: Ditto.
1959         * WebCore.xcodeproj/project.pbxproj: Ditto.
1960         * WebCoreSources.bkl: Ditto.
1961         * html/HTMLMediaElement.cpp: Changed to use ContentType.
1962         (WebCore::HTMLMediaElement::selectMediaURL):
1963         * platform/ContentType.cpp: Added.
1964         (WebCore::ContentType::ContentType):
1965         (WebCore::ContentType::parameter):
1966         (WebCore::ContentType::type):
1967         * platform/ContentType.h: Added.
1968         (WebCore::ContentType::raw):
1969         * platform/MIMETypeRegistry.cpp:
1970         * platform/MIMETypeRegistry.h:
1971         * platform/graphics/MediaPlayer.cpp:
1972         (WebCore::MediaPlayer::load):
1973         * rendering/style/ContentData.h: Renamed ContentType to StyleContentType.
1974         * rendering/style/RenderStyleConstants.h: Ditto.
1975         (WebCore::):
1976
1977 2009-02-20  Holger Hans Peter Freyther  <zecke@selfish.org>
1978
1979         Unreviewed build fix.
1980
1981         Use CString() instead of 0.
1982
1983         * platform/gtk/FileSystemGtk.cpp:
1984         (WebCore::openTemporaryFile):
1985         * platform/qt/FileSystemQt.cpp:
1986         (WebCore::openTemporaryFile):
1987
1988 2009-02-20  Gustavo Noronha Silva  <gns@gnome.org>
1989
1990         Reviewed by Holger Freyther.
1991
1992         When dealing with local files, use a path instead of an URI. GFile
1993         has problems decoding URIs with percent signs on them.
1994
1995         * platform/network/soup/ResourceHandleSoup.cpp:
1996         (WebCore::ResourceHandle::startGio):
1997
1998 2009-02-20  Gustavo Noronha Silva  <gns@gnome.org>
1999
2000         Reviewed by Holger Freyther.
2001
2002         Protect the ResourceHandle instance from being destroyed by
2003         didReceiveData inside the GIO readCallback call, so that
2004         cancelling caused by scripts is handled correctly.
2005
2006         * platform/network/soup/ResourceHandleSoup.cpp:
2007         (WebCore::readCallback):
2008
2009 2009-02-20  David Kilzer  <ddkilzer@apple.com>
2010
2011         Make IconDatabaseNone.cpp compile with -Wunused and pass check-for-exit-time-destructors
2012
2013         Reviewed by Sam Weinig.
2014
2015         * loader/icon/IconDatabaseNone.cpp:
2016         (WebCore::IconDatabase::defaultDatabaseFilename): Use DEFINE_STATIC_LOCAL().
2017         (WebCore::IconDatabase::open): Commented out unused parameter.
2018         (WebCore::IconDatabase::setPrivateBrowsingEnabled): Ditto.
2019         (WebCore::IconDatabase::iconForPageURL): Ditto.
2020         (WebCore::IconDatabase::iconURLForPageURL): Ditto.
2021         (WebCore::IconDatabase::defaultIcon): Ditto.
2022         (WebCore::IconDatabase::retainIconForPageURL): Ditto.
2023         (WebCore::IconDatabase::releaseIconForPageURL): Ditto.
2024         (WebCore::IconDatabase::setIconDataForIconURL): Ditto.
2025         (WebCore::IconDatabase::setIconURLForPageURL): Ditto.
2026         (WebCore::IconDatabase::setEnabled): Ditto.
2027         (WebCore::IconDatabase::pageURLMappingCount): Added stub.
2028         (WebCore::IconDatabase::retainedPageURLCount): Ditto.
2029         (WebCore::IconDatabase::iconRecordCount): Ditto.
2030         (WebCore::IconDatabase::iconRecordCountWithData): Ditto.
2031
2032 2009-02-20  David Kilzer  <ddkilzer@apple.com>
2033
2034         Add comment to generated code when shadowing a built-in object
2035
2036         Reviewed by Sam Weinig.
2037
2038         * bindings/scripts/CodeGeneratorJS.pm: Added comment to
2039         generated code output.
2040
2041 2009-02-20  Avi Drissman  <avi@chromium.org>
2042
2043         Reviewed by Eric Seidel.
2044
2045         https://bugs.webkit.org/show_bug.cgi?id=24036
2046         Keyboard events need disambiguation on the Linux platform too.
2047
2048         * platform/chromium/PlatformKeyboardEventChromium.cpp:
2049         (WebCore::PlatformKeyboardEvent::disambiguateKeyDownEvent):
2050
2051 2009-02-19  Darin Fisher  <darin@chromium.org>
2052
2053         Reviewed by Eric Seidel.
2054
2055         https://bugs.webkit.org/show_bug.cgi?id=24046
2056
2057         Several improvements to CString:
2058         1- Make it possible to initialize a CString from a CStringBuffer
2059         2- Make it possible to get a CStringBuffer from a CString
2060         3- Change CStringBuffer::data() to return a const pointer to ward off mutation
2061         4- Remove unused releaseBuffer() methods.
2062         5- Make CStringBuffer::create() private to force consumers to get a CStringBuffer from a CString.
2063
2064         * platform/text/CString.cpp:
2065         (WebCore::CString::init):
2066         (WebCore::CString::mutableData):
2067         (WebCore::CString::newUninitialized):
2068         (WebCore::CString::copyBufferIfNeeded):
2069         * platform/text/CString.h:
2070         (WebCore::CStringBuffer::data):
2071         (WebCore::CStringBuffer::length):
2072         (WebCore::CStringBuffer::create):
2073         (WebCore::CStringBuffer::mutableData):
2074         (WebCore::CString::CString):
2075         (WebCore::CString::buffer):
2076
2077 2009-02-19  Dmitry Titov  <dimich@chromium.org>
2078
2079         Reviewed by Alexey Proskuryakov.
2080
2081         https://bugs.webkit.org/show_bug.cgi?id=24017
2082         Remove some usage of Document in Worker.
2083
2084         * dom/WorkerContext.h:
2085         (WebCore::WorkerContext::userAgent):
2086         * dom/Document.cpp:
2087         (WebCore::Document::userAgent):
2088         * dom/Document.h:
2089         * dom/ScriptExecutionContext.h:
2090         Added virtual ScriptExecutionContext::userAgent(const KURL&).
2091         Document implementation uses FrameLoader::userAgent and
2092         WorkerContext receives the string on creation and stores it in a member.
2093
2094         * dom/Worker.cpp:
2095         (WebCore::Worker::Worker):
2096         (WebCore::Worker::notifyFinished):
2097         * dom/Worker.h:
2098         (WebCore::Worker::create):
2099         Instead of Document the Worker constructor now gets a ScriptExecutionContext.
2100         Start using some methods on SEC (like completeURL() and userAgent()).
2101         For others, explicitly case to Document and add a FIXME.
2102         Remove Worker::document() too.
2103
2104 2009-02-20  Gustavo Noronha Silva  <gns@gnome.org>
2105
2106         Rubber-stamped by Holger Freyther.
2107
2108         Do not set httpStatus to SOUP_STATUS_OK when serving local files
2109         to match other ports' behavior, fixing xmlhttprequest test
2110         regressions.
2111
2112         * platform/network/soup/ResourceHandleSoup.cpp:
2113         (WebCore::queryInfoCallback):
2114
2115 2009-02-19  Dan Bernstein  <mitz@apple.com>
2116
2117         Reviewed by Sam Weinig.
2118
2119         - WebCore part of fixing https://bugs.webkit.org/show_bug.cgi?id=24027
2120           Do not send loader callbacks during CSS styling
2121
2122         Undo the iChat-specific quirk added in
2123         <http://trac.webkit.org/changeset/41071>. Instead, always suspend memory
2124         cache client callbacks during attach() and recalcStyle().
2125
2126         * WebCore.base.exp: Removed
2127         Settings::setNeedsIChatMemoryCacheCallsQuirk().
2128         * dom/ContainerNode.cpp:
2129         (WebCore::ContainerNode::suspendPostAttachCallbacks): Disable memory
2130         cache client callbacks and remember to enable them afterwards if needed.
2131         (WebCore::ContainerNode::resumePostAttachCallbacks): Re-enable memory
2132         cache client callbacks if they were disabled in
2133         suspendPostAttachCallbacks().
2134         (WebCore::ContainerNode::attach): Use suspendPostAttachCallbacks() and
2135         resumePostAttachCallbacks().
2136         * dom/ContainerNode.h: Made suspendPostAttachCallbacks()
2137         and resumePostAttachCallbacks() non-static.
2138         * dom/Document.cpp:
2139         (WebCore::Document::dispatchImageLoadEventsNow): Reverted iChat-specific
2140         workaround.
2141         * page/Settings.cpp: Removed m_needsIChatMemoryCacheCallsQuirk and
2142         related code.
2143         (WebCore::Settings::Settings):
2144         * page/Settings.h:
2145
2146 2009-02-19  Holger Hans Peter Freyther  <zecke@selfish.org>
2147
2148         Unreviewed build fix.
2149
2150         Build fix after r41092. Make the memoryUsage method
2151         public. It will be shadowed by cf/mac and for curl/soup/qt
2152         the implementation from ResourceResponseBase will be used.
2153
2154         * platform/network/ResourceResponseBase.h:
2155         (WebCore::ResourceResponseBase::memoryUsage):
2156
2157 2009-02-19  Beth Dakin  <bdakin@apple.com>
2158
2159         Reviewed by Dave Hyatt.
2160
2161         Fix for <rdar://problem/6077775> Should be able to specify
2162         inactive ::selection color
2163
2164         This patch makes the ::selction pseudo-element work with
2165         the :window-inactive pseudo type. This was, a user can specify a
2166         different ::selection style when a window is inactive.
2167
2168         * css/CSSStyleSelector.cpp:
2169         (WebCore::CSSStyleSelector::SelectorChecker::checkSelector):
2170         (WebCore::CSSStyleSelector::SelectorChecker::checkOneSelector):
2171         * rendering/RenderObject.cpp:
2172         (WebCore::RenderObject::selectionBackgroundColor):
2173         (WebCore::RenderObject::selectionForegroundColor):
2174
2175 2009-02-19  Sam Weinig  <sam@webkit.org>
2176
2177         Reviewed by Beth Dakin.
2178
2179         Patch for https://bugs.webkit.org/show_bug.cgi?id=24044
2180         Update querySelector/querySelectorAll to match the latest spec
2181
2182         Update querySelector and querySelectorAll to match the latest version
2183         of the Selectors API spec.  We now stringify null and undefined to "null"
2184         and "undefined" respectively instead of to "".
2185
2186         Test: fast/dom/SelectorAPI/undefined-null-stringify.html
2187
2188         * dom/Document.idl:
2189         * dom/DocumentFragment.idl:
2190         * dom/Element.idl:
2191
2192 2009-02-19  Dimitri Glazkov  <dglazkov@chromium.org>
2193
2194         Reviewed by Geoffrey Garen.
2195
2196         https://bugs.webkit.org/show_bug.cgi?id=23732
2197         Rework CachedResource overhead accounting to allow platforms to diverge
2198         in numbers.
2199
2200         * loader/CachedResource.cpp:
2201         (WebCore::CachedResource::overheadSize): Changed to ask ResourceResponse
2202         for its size and to use actual URL size.
2203         * platform/network/ResourceResponseBase.h:
2204         (WebCore::ResourceResponseBase::size): Added default size method.
2205         * platform/network/cf/ResourceResponse.h:
2206         (WebCore::ResourceResponse::size): Added Win/CF size method
2207         * platform/network/mac/ResourceResponse.h:
2208         (WebCore::ResourceResponse::size): Added Mac size method.
2209
2210 2009-02-19  Anders Carlsson  <andersca@apple.com>
2211
2212         Reviewed by Kevin Decker.
2213
2214         - Fix for <rdar://problem/6604968>
2215
2216         On Tiger, create an autorelease pool before creating the NSGraphicsContext and drain it immediately
2217         after the call to -[NSView displayRectIgnoringOpacity:inContext:].
2218
2219         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
2220         (WebCore::MediaPlayerPrivate::paint):
2221
2222 2009-02-19  David Hyatt  <hyatt@apple.com>
2223
2224         Fix a bug where reflections didn't work properly if opacity was < 1.  Make sure that replaced elements
2225         also consider reflections to be part of their visual overflow.  This had already been done for blocks
2226         and lines, but it wasn't being done yet for replaced elements.
2227
2228         Also make sure that when the object being reflected has opacity < 1 that we don't end up popping the outer
2229         transparency layer early.  Since the reflected object paints twice, we don't want to end the transparency
2230         layer it pushed until we're done painting the real object (rather than the reflection).
2231
2232         Reviewed by Dan Bernstein
2233
2234         Added fast/reflections/reflection-masks-opacity.html
2235
2236         * rendering/RenderLayer.cpp:
2237         (WebCore::RenderLayer::paintLayer):
2238         * rendering/RenderPartObject.cpp:
2239         (WebCore::RenderPartObject::layout):
2240         * rendering/RenderReplaced.cpp:
2241         (WebCore::RenderReplaced::layout):
2242         (WebCore::RenderReplaced::adjustOverflowForBoxShadowAndReflect):
2243         * rendering/RenderReplaced.h:
2244
2245 2009-02-19  David Levin  <levin@chromium.org>
2246
2247         Reviewed by Alexey Proskuryakov.
2248
2249         Bug 23980: WorkerRunLoop needs a way to run in a given mode similar to CFRunLoopInMode.
2250         <https://bugs.webkit.org/show_bug.cgi?id=23980>
2251
2252         WorkerRunLoop has the ability to run in a mode which filters the tasks to be run.
2253         * When WorkerRunLoop::runInMode is called, only task for that mode will run.
2254         * When WorkerRunLoop::run is called (or the default mode is used), then all tasks
2255           will run regardless of their posted mode.
2256
2257         Here's a demonstration of the api:
2258
2259             RefPtr<NameResolution> nameResolution = NameResolution::create(workerRunLoop);
2260
2261             //  Internally nameResolution will do workerRunLoop.postTaskForMode(task, "MyCoolMode")
2262             //  for any tasks that need to be run during this loop.
2263             nameResolution->setTaskMode("MyCoolMode");
2264
2265             nameResolution->start();
2266             while (!nameResolution->done()) {
2267                 // Only tasks which are posted for "MyCoolMode" will run.
2268                 workerRunLoop.runInMode(context, "MyCoolMode");
2269             }
2270
2271         No observable change in behavior, so no test.
2272
2273         * dom/WorkerRunLoop.cpp:
2274         (WebCore::ModePredicate::ModePredicate):
2275         (WebCore::ModePredicate::operator()):
2276         (WebCore::WorkerRunLoop::WorkerRunLoop):
2277         (WebCore::WorkerRunLoop::~WorkerRunLoop):
2278         (WebCore::WorkerRunLoop::setSharedTimer):
2279         (WebCore::WorkerRunLoop::resetSharedTimer):
2280         (WebCore::WorkerRunLoop::run):
2281         (WebCore::WorkerRunLoop::runInMode):
2282         (WebCore::WorkerRunLoop::postTask):
2283         (WebCore::WorkerRunLoop::postTaskForMode):
2284         * dom/WorkerRunLoop.h:
2285         (WebCore::WorkerRunLoop::Task::create):
2286         (WebCore::WorkerRunLoop::Task::mode):
2287         (WebCore::WorkerRunLoop::Task::performTask):
2288         (WebCore::WorkerRunLoop::Task::Task):
2289
2290 2009-02-19  Dimitri Glazkov  <dglazkov@chromium.org>
2291
2292         Reviewed by Eric Seidel.
2293
2294         https://bugs.webkit.org/show_bug.cgi?id=24034
2295         Fix up Selection->VisibleSelection change.
2296
2297         * page/chromium/EventHandlerChromium.cpp:
2298         (WebCore::EventHandler::passMousePressEventToSubframe): Renamed Selection
2299         to VisibleSelection.
2300
2301 2009-02-19  Dimitri Glazkov  <dglazkov@chromium.org>
2302
2303         Reviewed by Eric Seidel.
2304
2305         https://bugs.webkit.org/show_bug.cgi?id=24041
2306         Correct Skia type conversion issues, fix Chromium Linux build.
2307
2308         * platform/graphics/chromium/FontLinux.cpp:
2309         (WebCore::Font::drawGlyphs): changed parameters to RGBA32, not WebCore::Color.
2310
2311 2009-02-19  Jungshik Shin <jshin@chromium.org>
2312
2313         Reviewed by Eric Seidel.
2314
2315         https://bugs.webkit.org/show_bug.cgi?id=20531
2316         Chromium-part follow-up to the patch landed in r40636
2317         for bug 20531.
2318         Remove a static member function alternateFamilyName
2319         from Chromium's Win/Linux ports of FontCache. In r40636,
2320         alternateFamilyName was customized using #ifdef PLATFORM(WIN_OS).
2321         So, there's no more need for the static member function per
2322         platform.
2323
2324         * platform/graphics/chromium/FontCacheChromiumWin.cpp:
2325         * platform/graphics/chromium/FontCacheLinux.cpp:
2326
2327 2009-02-19  Simon Fraser  <simon.fraser@apple.com>
2328
2329         Reviewed by Adele Peterson.
2330
2331         Call documentWillBecomeInactive() from Document::detach to ensure that
2332         media elements are shut down, because they may be kept alive by references
2333         from JS past document teardown.
2334
2335         documentWillBecomeInactive() calls  renderView()->willMoveOffscreen(), so no
2336         need to do that in detach() as well.
2337
2338         We no longer need to call documentWillBecomeInactive() from ~Page() (which
2339         was added for <https://bugs.webkit.org/show_bug.cgi?id=21116>), since this
2340         supersedes that change.
2341
2342         * dom/Document.cpp:
2343         (WebCore::Document::detach):
2344         * page/Page.cpp:
2345         (WebCore::Page::~Page):
2346
2347 2009-02-19  Dimitri Glazkov  <dglazkov@chromium.org>
2348
2349         Reviewed by Eric Seidel.
2350
2351         https://bugs.webkit.org/show_bug.cgi?id=24028
2352         Fix up Skia path changes.
2353
2354         * platform/graphics/skia/GraphicsContextSkia.cpp:
2355         (WebCore::GraphicsContext::strokePath): Removed illegal indirection.
2356         * platform/graphics/skia/PathSkia.cpp:
2357         (WebCore::boundingBoxForCurrentStroke): Changed call name.
2358
2359 2009-02-19  Gustavo Noronha Silva  <gns@gnome.org>
2360
2361         Reviewed by Alexey Proskuryakov.
2362
2363         Ignore ports on local URLs. This fixes a regression in
2364         fast/loader/file-URL-with-port-number.html
2365
2366         * platform/network/soup/ResourceHandleSoup.cpp:
2367         (WebCore::ResourceHandle::startGio):
2368
2369 2009-02-19  Gustavo Noronha Silva  <gns@gnome.org>
2370
2371         Reviewed by Alexey Proskuryakov.
2372
2373         https://bugs.webkit.org/show_bug.cgi?id=24011
2374         KURL's setPort doesn't unset port if 0 is given
2375
2376         Make setPort remove port if 0 is given to it, as promised by the
2377         comment in KURL's header.
2378
2379         * platform/KURL.cpp:
2380         (WebCore::KURL::setPort):
2381
2382 2009-02-18  Dan Bernstein  <mitz@apple.com>
2383
2384         Reviewed by Brady Eidson.
2385
2386         - WebCore part of fixing <rdar://problem/6507512> Crash in iChat at CSSStyleSelector::adjustRenderStyle
2387
2388         The crash results from re-entry into
2389         CSSMutableStyleDeclaration::setCssText, which in turn is caused by
2390         the first style change causing a cached image to load from the memory
2391         cache, causing load delegate dispatch, and iChat's delegate method
2392         calling back into WebKit.
2393
2394         The workaround is to use defer delegate callbacks for memory cache. In
2395         this case, deferring callbacks during image load event dispatch was
2396         found to be sufficient.
2397
2398         The crash is a regression. See also the discussion in
2399         <https://bugs.webkit.org/show_bug.cgi?id=22521>.
2400
2401         * WebCore.base.exp: Added
2402         Settings::setNeedsIChatMemoryCacheCallsQuirk().
2403         * dom/Document.cpp:
2404         (WebCore::Document::dispatchImageLoadEventsNow): If the quirk is
2405         enabled, defer memory cache callbacks during image load event dispatch.
2406         * page/Settings.cpp:
2407         (WebCore::Settings::Settings): Initialize
2408         m_needsIChatMemoryCacheCallsQuirk.
2409         (WebCore::Settings::setNeedsIChatMemoryCacheCallsQuirk): Added this
2410         setter.
2411         * page/Settings.h:
2412         (WebCore::Settings::needsIChatMemoryCacheCallsQuirk): Added this getter.
2413
2414 2009-02-18  Adam Roben  <aroben@apple.com>
2415
2416         Export WebCore::handCursor and Cursor.h
2417
2418         Reviewed by John Sullivan.
2419
2420         * WebCore.base.exp: Added WebCore::handCursor.
2421         * WebCore.xcodeproj/project.pbxproj: Made Cursor.h private.
2422
2423 2009-02-18  Ojan Vafai  <ojan@chromium.org>
2424
2425         Reviewed by Alexey Proskuryakov.
2426
2427         https://bugs.webkit.org/show_bug.cgi?id=23992
2428         REGRESSION: crash on windows loading http://www.stickam.com/liveStreams.do
2429
2430         Unable to reduce to a layout test.
2431
2432         * page/Frame.cpp:
2433         (WebCore::Frame::contentRenderer):
2434
2435 2009-02-18  Evan Stade  <estade@chromium.org>
2436
2437         Reviewed by Eric Seidel.
2438
2439         https://bugs.webkit.org/show_bug.cgi?id=23861
2440         Stroke font outlines on chromium linux
2441
2442         TEST=LayoutTests/svg/custom/pointer-events-text.svg
2443
2444         * platform/graphics/chromium/FontLinux.cpp:
2445         (WebCore::Font::drawGlyphs):
2446
2447 2009-02-18  Evan Stade  <estade@chromium.org>
2448
2449         Reviewed by Eric Seidel.
2450
2451         https://bugs.webkit.org/show_bug.cgi?id=23860
2452         Resync some graphics/skia files with their chromium counterparts
2453
2454         This comes from chromium patches <http://codereview.chromium.org/17633>
2455         and <http://codereview.chromium.org/17454>
2456
2457         * platform/graphics/skia/GraphicsContextSkia.cpp:
2458         (WebCore::GraphicsContext::clipPath):
2459         (WebCore::GraphicsContext::fillPath):
2460         * platform/graphics/skia/PlatformContextSkia.cpp:
2461         (PlatformContextSkia::addPath):
2462         (PlatformContextSkia::currentPath):
2463         * platform/graphics/skia/PlatformContextSkia.h:
2464
2465 2009-02-18  Gustavo Noronha Silva  <gns@gnome.org>
2466
2467         Unreviewed.
2468
2469         Build fix after r41060.
2470
2471         * GNUmakefile.am:
2472
2473 2009-02-18  Dimitri Glazkov  <dglazkov@chromium.org>
2474
2475         Reviewed by Eric Seidel.
2476
2477         https://bugs.webkit.org/show_bug.cgi?id=24005
2478         Add an include to fix Chromium build.
2479
2480         * page/animation/AnimationController.cpp: Add UnusedParam.h include.
2481
2482 2009-02-18  Gustavo Noronha Silva  <gns@gnome.org>
2483
2484         Reviewed by Holger Freyther.
2485
2486         Fix symbols.filter location, and add other missing files to the
2487         autotools build, so that make dist works.
2488
2489         * GNUmakefile.am:
2490
2491 2009-02-18  Zan Dobersek  <zandobersek@gmail.com>
2492
2493         Rubber-stamped by Holger Hans Peter Freyther.
2494
2495         Allow POST method for local requests.
2496
2497         * platform/network/soup/ResourceHandleSoup.cpp:
2498         (WebCore::ResourceHandle::startGio):
2499
2500 2009-02-18  Gustavo Noronha Silva  <gns@gnome.org>
2501
2502         Reviewed by Holger Hans Peter Freyther.
2503
2504         Use KURL in startGio instead of passing a string with the URL, so
2505         that we can handle removing refs and queries more elegantly. This
2506         is fixing more regressions that came from the curl->soup switch.
2507
2508         Original work by Zan Dobersek.
2509
2510         * platform/network/ResourceHandle.h:
2511         * platform/network/soup/ResourceHandleSoup.cpp:
2512         (WebCore::ResourceHandle::start):
2513         (WebCore::ResourceHandle::startGio):
2514
2515 2009-02-18  Holger Hans Peter Freyther  <zecke@selfish.org>
2516
2517         Reviewed by Alexey Proskuryakov.
2518
2519         Implement ResourceHandle::loadResourceSynchronously in ResourceHandleSoup.cpp
2520
2521         The implementation is needed to have synchronous loading, e.g. for
2522         JavaScript interaction. This is fixing various regressions that
2523         came from the curl->soup switch.
2524
2525         * platform/network/soup/ResourceHandleSoup.cpp:
2526         (WebCore::WebCoreSynchronousLoader::WebCoreSynchronousLoader):
2527         (WebCore::WebCoreSynchronousLoader::~WebCoreSynchronousLoader):
2528         (WebCore::WebCoreSynchronousLoader::didReceiveResponse):
2529         (WebCore::WebCoreSynchronousLoader::didReceiveData):
2530         (WebCore::WebCoreSynchronousLoader::didFinishLoading):
2531         (WebCore::WebCoreSynchronousLoader::didFail):
2532         (WebCore::WebCoreSynchronousLoader::run):
2533         (WebCore::ResourceHandle::loadResourceSynchronously):
2534
2535 2009-02-18  Xan Lopez  <xan@gnome.org>
2536
2537         Reviewed by Mark Rowe.
2538
2539         https://bugs.webkit.org/show_bug.cgi?id=23989
2540
2541         Based on a patch by Bo Yang  <techrazy.yang@gmail.com>
2542
2543         Make the cursor cache global, that's all we really need and
2544         otherwise we can miss cursor transitions in some situations (see
2545         the bug for one testcase). Also remove some now useless code.
2546
2547         * platform/Widget.h:
2548         * platform/gtk/WidgetGtk.cpp:
2549         (WebCore::Widget::Widget):
2550         (WebCore::Widget::~Widget):
2551         (WebCore::Widget::setCursor):
2552
2553 2009-02-17  Adam Roben  <aroben@apple.com>
2554
2555         Windows build fix
2556
2557         * loader/FrameLoader.cpp:
2558         (WebCore::toPlugInElement): Don't rely on #if being processed before
2559         ASSERT.
2560
2561 2009-02-17  David Levin  <levin@chromium.org>
2562
2563         Reviewed by Alexey Proskuryakov.
2564
2565         Bug 23977: Unnecessary timer related headers in files.
2566         <https://bugs.webkit.org/show_bug.cgi?id=23977>
2567
2568         No observable change in behavior, so no test.
2569
2570         * dom/Document.cpp:
2571         * dom/WorkerRunLoop.cpp:
2572         * dom/WorkerRunLoop.h:
2573
2574 2009-02-17  Peter Abrahamsen  <rainhead@gmail.com>
2575
2576         Reviewed by Sam Weinig.
2577
2578         https://bugs.webkit.org/show_bug.cgi?id=23958
2579         <rdar://problem/6587815>
2580
2581         Updated XMLHttpRequest with new header names from the latest Access
2582         Control draft: http://www.w3.org/TR/access-control/
2583         - Access-Control-Origin becomes Access-Control-Allow-Origin
2584         - Access-Control-Credentials becomes Access-Control-Allow-Credentials
2585
2586         * xml/XMLHttpRequest.cpp:
2587         (WebCore::XMLHttpRequest::accessControlCheck):
2588
2589 2009-02-17  Kevin Ollivier  <kevino@theolliviers.com>
2590
2591         wx build fix. Add missing constructor used for empty values.
2592
2593         * platform/graphics/wx/FontPlatformData.h:
2594         (WebCore::FontPlatformData::FontPlatformData):
2595
2596 2009-02-17  Antti Koivisto  <antti@apple.com>
2597
2598         Reviewed by Dave Kilzer.
2599
2600         <rdar://problem/6592446> dynamically updating page doesn't seem to draw when updated
2601
2602         Need update after callback.
2603
2604         * bindings/js/JSCustomPositionCallback.cpp:
2605         (WebCore::JSCustomPositionCallback::handleEvent):
2606         * bindings/js/JSCustomPositionErrorCallback.cpp:
2607         (WebCore::JSCustomPositionErrorCallback::handleEvent):
2608
2609 2009-02-17  Eric Carlson  <eric.carlson@apple.com>
2610
2611         Reviewed by Antti Koivisto.
2612
2613         https://bugs.webkit.org/show_bug.cgi?id=23917
2614         Allow a WebKit plug-in to act as a proxy for the <audio> and <video>
2615         element.
2616
2617         * DerivedSources.make: add media element proxy exports to .exp file when feature is defined.
2618
2619         * WebCore.VideoProxy.exp: New, define the informal protocol exported by a media element proxy.
2620
2621         * WebCore.xcodeproj/project.pbxproj: Add MediaPlayerProxy.h.
2622
2623         * html/HTMLMediaElement.cpp:
2624         (WebCore::HTMLMediaElement::HTMLMediaElement): Initialize m_needWidgetUpdate.
2625         (WebCore::HTMLMediaElement::attributeChanged): Don't detach+attach when PLUGIN_PROXY_FOR_VIDEO, the
2626         proxy plug-in handles the poster frame.
2627         (WebCore::HTMLMediaElement::rendererIsNeeded): New logic for PLUGIN_PROXY_FOR_VIDEO.
2628         (WebCore::HTMLMediaElement::createRenderer): Create RenderPartObject when PLUGIN_PROXY_FOR_VIDEO.
2629         (WebCore::HTMLMediaElement::attach): Set m_needWidgetUpdate when PLUGIN_PROXY_FOR_VIDEO
2630         (WebCore::HTMLMediaElement::load): Don't reallocate MediaPlayer when PLUGIN_PROXY_FOR_VIDEO, we keep the
2631         same plug-in for the life of the element.
2632         (WebCore::HTMLMediaElement::mediaPlayerNetworkStateChanged): update m_networkState when media player
2633         network state changes to EMPTY, otherwise we can get out of sync with engine.
2634         (WebCore::HTMLMediaElement::defaultEventHandler): pass event to widget when PLUGIN_PROXY_FOR_VIDEO
2635         (WebCore::HTMLMediaElement::deliverNotification): New, deliver notification from proxy plug-in to
2636         media player.
2637         (WebCore::HTMLMediaElement::setMediaPlayerProxy): New, pass proxy object to media player.
2638         (WebCore::HTMLMediaElement::initialURL): New, return the url from the "src" attr or the appropriate
2639         <source> element to be used as the initial url for the proxy.
2640         (WebCore::HTMLMediaElement::finishParsingChildren): New, allocate MediaPlayer and update widget.
2641         * html/HTMLMediaElement.h: Declare new methods for proxy, add m_needWidgetUpdate.
2642         (WebCore::HTMLMediaElement::setNeedWidgetUpdate):
2643
2644         * html/HTMLVideoElement.cpp:
2645         (WebCore::HTMLVideoElement::attach): Poster image is handled by proxy when PLUGIN_PROXY_FOR_VIDEO.
2646         (WebCore::HTMLVideoElement::parseMappedAttribute): Ditto.
2647         * html/HTMLVideoElement.h:
2648
2649         * loader/FrameLoader.cpp:
2650         (WebCore::toPlugInElement): Allow cast if element is <video> or <audio>
2651
2652         * platform/graphics/MediaPlayer.cpp:
2653         (WebCore::MediaPlayer::MediaPlayer): Remove white space.
2654         (WebCore::MediaPlayer::setPoster): New, forward call to private player.
2655         (WebCore::MediaPlayer::deliverNotification): Ditto.
2656         (WebCore::MediaPlayer::setMediaPlayerProxy): Ditto.
2657         * platform/graphics/MediaPlayer.h:
2658         (WebCore::MediaPlayer::mediaPlayerClient):
2659
2660         * platform/graphics/mac/MediaPlayerProxy.h: New, defines media player proxy interface.
2661
2662         * rendering/RenderPart.cpp:
2663         (WebCore::RenderPart::RenderPart): Change constructor to take Element* instead of Node* as a
2664         non-element node doesn't need a renderer
2665         * rendering/RenderPart.h: Ditto.
2666
2667         * rendering/RenderPartObject.cpp:
2668         (WebCore::RenderPartObject::RenderPartObject): Ditto.
2669         (WebCore::RenderPartObject::updateWidget): Package params for proxy plug-in when element is
2670         <video> or <audio>.
2671         * rendering/RenderPartObject.h:
2672
2673 2009-02-17  David Hyatt  <hyatt@apple.com>
2674
2675         Reviewed by Eric Seidel
2676
2677         Fix for https://bugs.webkit.org/show_bug.cgi?id=23985
2678
2679         Don't allow legends to be anything but display:block.
2680
2681         Added fast/forms/inline-ignored-on-legend.html
2682
2683         * GNUmakefile.am:
2684         * WebCore.pro:
2685         * WebCore.vcproj/WebCore.vcproj:
2686         * WebCore.xcodeproj/project.pbxproj:
2687         * WebCoreSources.bkl:
2688         * css/html4.css:
2689         * html/HTMLLegendElement.cpp:
2690         * html/HTMLLegendElement.h:
2691         * rendering/RenderLegend.cpp: Removed.
2692         * rendering/RenderLegend.h: Removed.
2693         * wml/WMLInsertedLegendElement.cpp:
2694         * wml/WMLInsertedLegendElement.h:
2695
2696 2009-02-13  Brett Wilson  <brettw@dhcp-172-22-71-167.mtv.corp.google.com>
2697
2698         Reviewed by Simon Fraser.
2699
2700         https://bugs.webkit.org/attachment.cgi?id=27666
2701         Fix Chromium build build: forgotten include in RenderObject, sync
2702         RenderTheme to the recent changes in RenderObject.
2703
2704         * rendering/RenderObject.cpp:
2705         * rendering/RenderThemeChromiumMac.mm:
2706         (WebCore::RenderThemeChromiumMac::updatePressedState):
2707
2708 2009-02-17  Gustavo Noronha Silva  <gns@gnome.org>
2709
2710         Reviewed by Darin Adler.
2711
2712         https://bugs.webkit.org/show_bug.cgi?id=22966
2713         crash when destroying a webview that opened a page containing <script>
2714         tags
2715
2716         Fix m_group being set to 0 instead of to m_singlePageGroup when
2717         GroupName is set to empty
2718
2719         * page/Page.cpp:
2720         (WebCore::Page::setGroupName):
2721
2722 2009-02-16  Beth Dakin  <bdakin@apple.com>
2723
2724         Reviewed by Sam Weinig.
2725
2726         Fix for <rdar://problem/6386623>
2727
2728         I made m_numParsedProperties and m_maxParsedProperties unsigned
2729         instead of int, and then added an early return from addPropery() if
2730         m_maxParsedProperties exceeds the max value.
2731
2732         * css/CSSParser.cpp:
2733         (WebCore::CSSParser::addProperty):
2734         (WebCore::CSSParser::rollbackLastProperties):
2735         (WebCore::CSSParser::clearProperties):
2736         (WebCore::CSSParser::createFontFaceRule):
2737         (WebCore::CSSParser::deleteFontFaceOnlyValues):
2738         * css/CSSParser.h:
2739
2740 2009-02-16  Justin Garcia  <justin.garcia@apple.com>
2741
2742         Reviewed by Mark Rowe.
2743
2744         https://bugs.webkit.org/show_bug.cgi?id=16309
2745         HTML5: The third execCommand argument for insert{un}orderedlist should be ignored
2746
2747         When we originally implemented this command, MSDN documentation said that IE set the
2748         id attribute of inserted lists to the third argument to execCommand, but IE doesn't
2749         do this nor do any other browsers.
2750
2751         * editing/EditorCommand.cpp:
2752         (WebCore::executeInsertOrderedList):
2753         (WebCore::executeInsertUnorderedList):
2754         * editing/IndentOutdentCommand.cpp:
2755         (WebCore::IndentOutdentCommand::outdentParagraph):
2756         * editing/InsertListCommand.cpp:
2757         (WebCore::InsertListCommand::insertList):
2758         (WebCore::InsertListCommand::InsertListCommand):
2759         (WebCore::InsertListCommand::doApply):
2760         * editing/InsertListCommand.h:
2761         (WebCore::InsertListCommand::create):
2762
2763 2009-02-16  Dan Bernstein  <mitz@apple.com>
2764
2765         Reviewed by Geoffrey Garen.
2766
2767         - fix <rdar://problem/6561077> REGRESSION (r39634): Unable to select an item in stocks widget with the mouse
2768
2769         Test: platform/mac/fast/events/pointer-events-dashboard.html
2770
2771         * css/CSSStyleSelector.cpp:
2772         (WebCore::CSSStyleSelector::applyProperty): Do not apply the
2773         pointer-events property in Dashboard backwards compatibility mode,
2774         in order to work around misuse of that property by the Stocks widget.
2775
2776 2009-02-16  Justin Garcia  <justin.garcia@apple.com>
2777
2778         Reviewed by Eric Seidel.
2779
2780         https://bugs.webkit.org/show_bug.cgi?id=15381
2781         execCommand justify modifies the contentEditable node
2782
2783         * editing/CompositeEditCommand.cpp:
2784         (WebCore::CompositeEditCommand::moveParagraphContentsToNewBlockIfNecessary): Avoid modifying not just
2785         the body element, but any root editable element.
2786
2787 2009-02-16  Chris Fleizach  <cfleizach@apple.com>
2788
2789         Reviewed by Adele Peterson.
2790
2791         Bug 23979: AX: alt tag not returned for <input type="image">
2792         https://bugs.webkit.org/show_bug.cgi?id=23979
2793
2794         Test: accessibility/input-image-alt.html
2795
2796         * page/AccessibilityRenderObject.cpp:
2797         (WebCore::AccessibilityRenderObject::accessibilityDescription):
2798
2799 2009-02-16  Kevin Watters  <kevinwatters@gmail.com>
2800
2801         Reviewed by Kevin Ollivier.
2802
2803         The ref data is not properly set unless we use the CreateMatrix function.
2804
2805         https://bugs.webkit.org/show_bug.cgi?id=23978
2806
2807         * platform/graphics/wx/TransformationMatrixWx.cpp:
2808         (WebCore::TransformationMatrix::operator wxGraphicsMatrix):
2809
2810 2009-02-16  Dan Bernstein  <mitz@apple.com>
2811
2812         Reviewed by John Sullivan.
2813
2814         - fix <rdar://problem/6516829> FontPlatformData constructor passes NULL to CTFontCopyGraphicsFont and CTFontGetPlatformFont
2815
2816         * platform/graphics/FontCache.cpp:
2817         (WebCore::FontDataCacheKeyTraits::emptyValue): Changed to use the
2818         FontPlatformData(float, bool, bool) constructor.
2819         * platform/graphics/mac/FontCacheMac.mm:
2820         (WebCore::FontCache::createFontPlatformData): Changed to pass a valid
2821         NSFont to the FontPlatformData constructor, instead of implicitly
2822         passing 0 and then calling setFont().
2823         * platform/graphics/mac/FontPlatformData.h: Made the NSFont parameter
2824         of the constructor mandatory.
2825
2826 2009-02-15  David Kilzer  <ddkilzer@apple.com>
2827
2828         Move duplicate caretWidth constants to RenderObject.h
2829
2830         Reviewed by Dan Bernstein.
2831
2832         No test since no change in behavior.
2833
2834         * rendering/RenderBlock.cpp:
2835         (WebCore::RenderBlock::localCaretRect): Removed caretWidth.
2836         * rendering/RenderBox.cpp:
2837         (WebCore::RenderBox::localCaretRect): Ditto.
2838         * rendering/RenderObject.h: Added caretWidth definition.
2839         * rendering/RenderText.cpp:
2840         (WebCore::RenderText::localCaretRect): Removed caretWidth.
2841
2842 2009-02-13  Dimitri Glazkov  <dglazkov@chromium.org>
2843
2844         Reviewed by Eric Seidel.
2845
2846         https://bugs.webkit.org/show_bug.cgi?id=23955
2847         V8HTMLPlugInCustom returns undefined, which fools interceptors.
2848
2849         * bindings/v8/custom/V8HTMLPlugInElementCustom.cpp:
2850         (WebCore::NAMED_PROPERTY_GETTER): Use deferToInterceptor() return value.
2851         (WebCore::NAMED_PROPERTY_SETTER): Ditto.
2852         (WebCore::INDEXED_PROPERTY_GETTER): Ditto.
2853         (WebCore::INDEXED_PROPERTY_SETTER): Ditto.
2854
2855 2009-02-13  Dimitri Glazkov  <dglazkov@chromium.org>
2856
2857         Reviewed by Eric Seidel.
2858
2859         https://bugs.webkit.org/show_bug.cgi?id=23954
2860         Add V8 custom bindings for CanvasRenderingContext2D.
2861
2862         * bindings/v8/custom/V8CanvasRenderingContext2DCustom.cpp: Added.
2863         (WebCore::toV8):
2864         (WebCore::toCanvasStyle):
2865         (WebCore::ACCESSOR_GETTER):
2866         (WebCore::ACCESSOR_SETTER):
2867
2868 2009-02-13  Anders Carlsson  <andersca@apple.com>
2869
2870         Reviewed by Darin Adler and Dan Bernstein.
2871
2872         <rdar://problem/6583187>
2873
2874         * page/NavigatorBase.cpp:
2875         Handle PPC64 and X86_64 as well.
2876
2877 2009-02-13  Darin Adler  <darin@apple.com>
2878
2879         Reviewed by Mark Rowe.
2880
2881         Fix broken tokenizer regression test that reflected a lifetime bug
2882         in the document.write optimization. The test failure was trivial to
2883         reproduce in COLLECT_ON_EVERY_ALLOCATION mode.
2884
2885         * bindings/js/JSHTMLDocumentCustom.cpp:
2886         (WebCore::documentWrite): Convert strings to String rather than passing
2887         the pointer and length to SegmentedString. The optimization is thus
2888         mostly gone. However, there are two ways to bring it back: 1) Apply
2889         the patch that makes UString and String share the same buffers.
2890         2) Add a UString feature to SegmentedString; simple to do but might
2891         risk slowing down normal document parsing.
2892
2893 2009-02-13  Adam Treat  <adam.treat@torchmobile.com>
2894
2895         Caught by Darin Adler.
2896
2897         No reason to check m_tokenizer twice for 0 in a row.
2898
2899         * dom/Document.cpp:
2900         (WebCore::Document::write):
2901
2902 2009-02-13  Lyon Chen  <lyon.chen@torchmobile.com>
2903
2904         Reviewed by Dave Hyatt.
2905
2906         Take into account y() + height() when calculating getLowerRightCorner.
2907
2908         * dom/ContainerNode.cpp:
2909         (WebCore::ContainerNode::getLowerRightCorner):
2910
2911 2009-02-13  Antti Koivisto  <antti@apple.com>
2912
2913         Reviewed by Dave Hyatt.
2914
2915         Most of this code was in RenderBox, restore the copyright lines.
2916
2917         * rendering/RenderBoxModelObject.cpp:
2918         * rendering/RenderBoxModelObject.h:
2919
2920 2009-02-13  David Hyatt  <hyatt@apple.com>
2921
2922         Get rid of printBoxDecorations, since it is dead code.
2923
2924         Reviewed by Dan Bernstein
2925
2926         * rendering/RenderObject.h:
2927
2928 2009-02-13  Adam Treat  <adam.treat@torchmobile.com>
2929
2930         Reviewed by Darin Adler.
2931
2932         https://bugs.webkit.org/show_bug.cgi?id=23952
2933         Add Document::write overload which takes a SegmentedString since this
2934         is what the tokenizer expects anyway.  Modified JSHTMLDocument so it once
2935         again calls Document::write instead of injecting the string directly into
2936         the tokenizer.  This ensures that all document.write's are funneled through
2937         one method again, but should still be just as fast for JSHTMLDocumentCustom.
2938
2939         * bindings/js/JSHTMLDocumentCustom.cpp:
2940         (WebCore::documentWrite):
2941         * dom/Document.cpp:
2942         (WebCore::Document::write):
2943         * dom/Document.h:
2944
2945 2009-02-13  David Hyatt  <hyatt@apple.com>
2946
2947         Reviewed by Simon Fraser
2948
2949         Remove updateWidgetPosition on RenderObject.  Change RenderView's set of widgets
2950         to have a tighter type: RenderWidget instead of RenderObject.  Devirtualize
2951         updateWidgetPosition, since all RenderWidgets (except for applets) are now
2952         RenderParts also.
2953
2954         * rendering/RenderObject.cpp:
2955         * rendering/RenderObject.h:
2956         * rendering/RenderPart.cpp:
2957         * rendering/RenderPart.h:
2958         * rendering/RenderView.cpp:
2959         (WebCore::RenderView::updateWidgetPositions):
2960         (WebCore::RenderView::addWidget):
2961         (WebCore::RenderView::removeWidget):
2962         * rendering/RenderView.h:
2963         * rendering/RenderWidget.cpp:
2964         (WebCore::RenderWidget::updateWidgetPosition):
2965         * rendering/RenderWidget.h:
2966
2967 2009-02-13  David Hyatt  <hyatt@apple.com>
2968
2969         Reviewed by Eric Seidel
2970
2971         Remove isEditable() on RenderObject.  It is dead code.
2972
2973         * rendering/RenderObject.cpp:
2974         * rendering/RenderObject.h:
2975
2976 2009-02-13  David Hyatt  <hyatt@apple.com>
2977
2978         Reviewed by Eric Seidel
2979
2980         Add isTextControl() to RenderObject.  Patch call sites thats asked isTextField() || isTextArea() to just use
2981         isTextControl() instead.
2982
2983         Add a toRenderTextControl converter for doing checked casting to RenderTextControls.
2984
2985         * dom/Document.cpp:
2986         (WebCore::Document::setFocusedNode):
2987         * dom/InputElement.cpp:
2988         (WebCore::InputElement::updateSelectionRange):
2989         * editing/ReplaceSelectionCommand.cpp:
2990         (WebCore::ReplacementFragment::ReplacementFragment):
2991         * editing/TextIterator.cpp:
2992         (WebCore::TextIterator::handleReplacedElement):
2993         * html/HTMLInputElement.cpp:
2994         (WebCore::HTMLInputElement::selectionStart):
2995         (WebCore::HTMLInputElement::selectionEnd):
2996         (WebCore::HTMLInputElement::setSelectionStart):
2997         (WebCore::HTMLInputElement::setSelectionEnd):
2998         (WebCore::HTMLInputElement::select):
2999         (WebCore::HTMLInputElement::defaultEventHandler):
3000         (WebCore::HTMLInputElement::selection):
3001         * html/HTMLTextAreaElement.cpp:
3002         (WebCore::HTMLTextAreaElement::selectionStart):
3003         (WebCore::HTMLTextAreaElement::selectionEnd):
3004         (WebCore::HTMLTextAreaElement::setSelectionStart):
3005         (WebCore::HTMLTextAreaElement::setSelectionEnd):
3006         (WebCore::HTMLTextAreaElement::select):
3007         (WebCore::HTMLTextAreaElement::setSelectionRange):
3008         (WebCore::HTMLTextAreaElement::appendFormData):
3009         (WebCore::HTMLTextAreaElement::updateValue):
3010         (WebCore::HTMLTextAreaElement::selection):
3011         * page/AccessibilityRenderObject.cpp:
3012         (WebCore::AccessibilityRenderObject::isNativeTextControl):
3013         (WebCore::AccessibilityRenderObject::text):
3014         (WebCore::AccessibilityRenderObject::selectedText):
3015         (WebCore::AccessibilityRenderObject::selectedTextRange):
3016         (WebCore::AccessibilityRenderObject::setSelectedTextRange):
3017         (WebCore::AccessibilityRenderObject::visiblePositionForIndex):
3018         (WebCore::AccessibilityRenderObject::indexForVisiblePosition):
3019         (WebCore::AccessibilityRenderObject::observableObject):
3020         * page/Frame.cpp:
3021         (WebCore::Frame::notifyRendererOfSelectionChange):
3022         * rendering/RenderObject.h:
3023         (WebCore::RenderObject::isTextControl):
3024         (WebCore::objectIsRelayoutBoundary):
3025         * rendering/RenderTextControl.h:
3026         (WebCore::RenderTextControl::isTextControl):
3027         (WebCore::toRenderTextControl):
3028         * rendering/TextControlInnerElements.cpp:
3029         (WebCore::TextControlInnerTextElement::defaultEventHandler):
3030         * wml/WMLInputElement.cpp:
3031         (WebCore::WMLInputElement::select):
3032         (WebCore::WMLInputElement::defaultEventHandler):
3033         (WebCore::WMLInputElement::isConformedToInputMask):
3034
3035 2009-02-13  David Hyatt  <hyatt@apple.com>
3036
3037         Get rid of isEdited/setEdited on RenderObject.  Devirtualize isEdited/setEdited on RenderTextControl.
3038         Callers were already asking if the renderer was a text field (or a text area), so it was especially
3039         pointless to waste a second virtual function call after making one just to determine the object type.
3040
3041         Reviewed by Simon Fraser
3042
3043         * dom/Document.cpp:
3044         (WebCore::Document::setFocusedNode):
3045         * html/HTMLInputElement.cpp:
3046         (WebCore::HTMLInputElement::defaultEventHandler):
3047         * rendering/RenderObject.h:
3048         * rendering/RenderTextControl.h:
3049         (WebCore::RenderTextControl::isEdited):
3050         (WebCore::RenderTextControl::setEdited):
3051
3052 2009-02-13  Scott Violet  <sky@google.com>
3053
3054         Reviewed by Eric Seidel.
3055
3056         https://bugs.webkit.org/show_bug.cgi?id=23934
3057         Skia platform doesn't render text decoration shadows.
3058
3059         Makes Skia render text decoration shadows correctly. We weren't
3060         preparing the SkPaint correctly and didn't have a couple of checks
3061         CG has. Additionally makes the fillColor/strokeColor methods
3062         consistent.
3063
3064         This behavior is covered by existing layout tests (see bug for list).
3065
3066         * platform/graphics/chromium/FontChromiumWin.cpp:
3067         (WebCore::Font::drawGlyphs):
3068         (WebCore::Font::drawComplexText):
3069         * platform/graphics/skia/GraphicsContextSkia.cpp:
3070         (WebCore::GraphicsContext::drawLineForText):
3071         * platform/graphics/skia/PlatformContextSkia.cpp:
3072         (PlatformContextSkia::effectiveFillColor):
3073         (PlatformContextSkia::effectiveStrokeColor):
3074         * platform/graphics/skia/PlatformContextSkia.h:
3075
3076 2009-02-12  Darin Fisher  <darin@chromium.org>
3077
3078         Reviewed by Eric Seidel.
3079
3080         https://bugs.webkit.org/show_bug.cgi?id=23944
3081         KURLGoogle's pre-parsed canonicalSpec constructor should take a CString
3082
3083         * platform/KURL.h:
3084         * platform/KURLGoogle.cpp:
3085         (WebCore::KURLGooglePrivate::setUtf8):
3086         (WebCore::KURLGooglePrivate::setAscii):
3087         (WebCore::KURLGooglePrivate::init):
3088         (WebCore::KURLGooglePrivate::replaceComponents):
3089         (WebCore::KURL::KURL):
3090         * platform/KURLGooglePrivate.h:
3091
3092 2009-02-13  David Hyatt  <hyatt@apple.com>
3093
3094         Remove leftmost/rightmost/lowestPosition from RenderObject.  They only need to be called on boxes.
3095
3096         Reviewed by Dan Bernstein
3097
3098         * rendering/RenderBlock.cpp:
3099         (WebCore::RenderBlock::lowestPosition):
3100         (WebCore::RenderBlock::rightmostPosition):
3101         (WebCore::RenderBlock::leftmostPosition):
3102         * rendering/RenderLayer.cpp:
3103         (WebCore::RenderLayer::computeScrollDimensions):
3104         * rendering/RenderMedia.cpp:
3105         (WebCore::RenderMedia::lowestPosition):
3106         (WebCore::RenderMedia::rightmostPosition):
3107         (WebCore::RenderMedia::leftmostPosition):
3108         * rendering/RenderObject.h:
3109         * rendering/RenderTableSection.cpp:
3110         (WebCore::RenderTableSection::lowestPosition):
3111         (WebCore::RenderTableSection::rightmostPosition):
3112         (WebCore::RenderTableSection::leftmostPosition):
3113
3114 2009-02-12  Simon Fraser  <simon.fraser@apple.com>
3115
3116         Fix build with ACCELERATED_COMPOSITING turned on.
3117
3118         toRenderBox()->x() asserts for a layer on an inline; use
3119         m_owningLayer->renderBoxX() instead.
3120
3121         * rendering/RenderLayerBacking.cpp:
3122         (WebCore::RenderLayerBacking::paintIntoLayer):
3123
3124 2009-02-12  Darin Adler  <darin@apple.com>
3125
3126         Reviewed by Oliver Hunt.
3127
3128         Speed up document.write a bit.
3129
3130         * bindings/js/JSHTMLDocumentCustom.cpp:
3131         (WebCore::documentWrite): Added. Uses SegmentedString to avoid conversion from
3132         UString to String and to avoid appending strings. Also added code to handle
3133         newlines efficiently.
3134         (WebCore::JSHTMLDocument::write): Changed to use documentWrite.
3135         (WebCore::JSHTMLDocument::writeln): Ditto.
3136
3137         * dom/Document.cpp:
3138         (WebCore::Document::prepareToWrite): Added. Refactored the initialization part
3139         of write into a separate function for use in the JavaScript binding.
3140         (WebCore::Document::write): Changed to call prepareToWrite.
3141
3142         * dom/Document.h: Added declaration for prepareToWrite.
3143
3144 2009-02-13  Prasanth Ullattil  <pullatti@trolltech.com>
3145
3146         Reviewed by Simon Hausmann.
3147
3148         Fixes crash in the Qt port on Windows with comboboxes
3149
3150         The focusWidget in the input context is not reset properly.
3151         The QApplication::setFocusWidget() wont reset the IC if the reason is
3152         PopupFocusReason, this is not ideal. For the time being we are going
3153         to do this from webkit itself.
3154
3155         * platform/qt/QWebPopup.cpp:
3156         (WebCore::QWebPopup::hidePopup):
3157
3158 2009-02-12  Kevin Ollivier  <kevino@theolliviers.com>
3159
3160         wx build fix, typo while tweaking last patch for commit.
3161
3162         * platform/wx/wxcode/gtk/fontprops.cpp:
3163         (GetTextExtent):
3164
3165 2009-02-12  miggilin  <mr.diggilin@gmail.com>
3166
3167         Reviewed by Kevin Ollivier.
3168
3169         Use Cairo/PANGO to fix text measurements and implement proper
3170         non-kerned text drawing on wxGTK.
3171
3172         https://bugs.webkit.org/show_bug.cgi?id=17727
3173
3174         * platform/graphics/GlyphBuffer.h:
3175         * platform/graphics/wx/FontPlatformDataWx.cpp:
3176         (WebCore::fontWeightToWxFontWeight):
3177         * platform/graphics/wx/SimpleFontDataWx.cpp:
3178         (WebCore::SimpleFontData::platformWidthForGlyph):
3179         * platform/wx/wxcode/fontprops.h:
3180         * platform/wx/wxcode/gtk/fontprops.cpp:
3181         (wxFontProperties::wxFontProperties):
3182         (GetTextExtent):
3183         * platform/wx/wxcode/gtk/non-kerned-drawing.cpp:
3184         (WebCore::pangoFontMap):
3185         (WebCore::createPangoFontForFont):
3186         (WebCore::createScaledFontForFont):
3187         (WebCore::pango_font_get_glyph):
3188         (WebCore::drawTextWithSpacing):
3189         * platform/wx/wxcode/non-kerned-drawing.h:
3190
3191 2009-02-12  Chris Marrin  <cmarrin@apple.com>
3192
3193         Reviewed by Simon Fraser
3194
3195         https://bugs.webkit.org/show_bug.cgi?id=23942
3196
3197         Hook up 3D CSS transforms to the accelerated compositor backend.
3198         Not enabled by default.
3199
3200         * page/animation/AnimationBase.cpp:
3201         (WebCore::blendFunc):
3202         (WebCore::ensurePropertyMap):
3203         * page/animation/CompositeAnimation.cpp:
3204         (WebCore::CompositeAnimationPrivate::updateTransitions):
3205         * page/animation/ImplicitAnimation.cpp:
3206         (WebCore::ImplicitAnimation::willNeedService):
3207         * page/animation/KeyframeAnimation.cpp:
3208         (WebCore::KeyframeAnimation::willNeedService):
3209         * platform/graphics/GraphicsLayer.cpp:
3210         (WebCore::GraphicsLayer::TransformValueList::makeFunctionList):
3211         (WebCore::GraphicsLayer::dumpProperties):
3212         * platform/graphics/mac/GraphicsLayerCA.mm:
3213         (WebCore::copyTransform):
3214         (WebCore::getValueFunctionNameForTransformOperation):
3215         (WebCore::GraphicsLayerCA::animateTransform):
3216         * rendering/RenderBox.cpp:
3217         (WebCore::RenderBox::updateBoxModelInfoFromStyle):
3218         * rendering/RenderLayer.cpp:
3219         (WebCore::RenderLayer::updateTransform):
3220         (WebCore::RenderLayer::hasTransformStyle3D):
3221         (WebCore::RenderLayer::hasPerspective):
3222         (WebCore::RenderLayer::perspectiveTransform):
3223         * rendering/RenderLayer.h:
3224         * rendering/RenderLayerBacking.cpp:
3225         (WebCore::RenderLayerBacking::updateGraphicsLayers):
3226         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
3227         (WebCore::RenderLayerBacking::computeTransformOrigin):
3228         (WebCore::RenderLayerBacking::computePerspectiveOrigin):
3229         * rendering/RenderLayerBacking.h:
3230         * rendering/RenderLayerCompositor.cpp:
3231         (WebCore::RenderLayerCompositor::has3DContent):
3232         (WebCore::requiresCompositingLayerForTransform):
3233         (WebCore::RenderLayerCompositor::requiresCompositingLayer):
3234         (WebCore::RenderLayerCompositor::layerHas3DContent):
3235         * rendering/RenderLayerCompositor.h:
3236
3237 2009-02-12  David Hyatt  <hyatt@apple.com>
3238
3239         Reviewed by Eric Seidel
3240
3241         Get rid of containingBlockHeight(), since it had only one implementation (despite being virtual) and just returned
3242         containingBlock()->availableHeight().  The latter reads better anyway.  Rename containingBlockWidth() to
3243         containingBlockWidthForContent() and move it to RenderBoxModelObject.
3244
3245         * rendering/RenderBlock.cpp:
3246         (WebCore::RenderBlock::localCaretRect):
3247         * rendering/RenderBox.cpp:
3248         (WebCore::RenderBox::containingBlockWidthForContent):
3249         (WebCore::RenderBox::calcWidth):
3250         (WebCore::RenderBox::calcReplacedWidthUsing):
3251         * rendering/RenderBox.h:
3252         * rendering/RenderBoxModelObject.cpp:
3253         (WebCore::RenderBoxModelObject::relativePositionOffsetX):
3254         (WebCore::RenderBoxModelObject::relativePositionOffsetY):
3255         (WebCore::RenderBoxModelObject::containingBlockWidthForContent):
3256         * rendering/RenderBoxModelObject.h:
3257         * rendering/RenderInline.cpp:
3258         (WebCore::RenderInline::marginLeft):
3259         (WebCore::RenderInline::marginRight):
3260         * rendering/RenderObject.cpp:
3261         * rendering/RenderObject.h:
3262         * rendering/RenderSVGContainer.cpp:
3263         (WebCore::RenderSVGContainer::calcReplacedWidth):
3264
3265 2009-02-12  Simon Fraser  <simon.fraser@apple.com>
3266
3267         Fix non-Mac builds by adding Matrix3DTransformOperation.* and
3268         PerspectiveTransformOperation.*. Cleaned out some cruft in
3269         the WebCore.vcproj fle.
3270
3271         * GNUmakefile.am:
3272         * WebCore.pro:
3273         * WebCore.scons:
3274         * WebCore.vcproj/WebCore.vcproj:
3275
3276 2009-02-12  David Smith  <catfish.man@gmail.com>
3277
3278         Reviewed by Dave Hyatt.
3279
3280         Fix https://bugs.webkit.org/show_bug.cgi?id=23935
3281         Nested :not() and non-simple selectors in :not() should be invalid
3282
3283         * css/CSSGrammar.y: Reject nested :not()
3284         * css/CSSStyleSelector.cpp:
3285         (WebCore::CSSStyleSelector::SelectorChecker::checkOneSelector): ASSERT() rather than checking, since the parser enforces it now
3286
3287 2009-02-12  Kevin Ollivier  <kevino@theolliviers.com>
3288
3289         wx build fixes.
3290
3291         * WebCoreSources.bkl:
3292
3293 2009-02-12  Simon Fraser  <simon.fraser@apple.com>
3294
3295         Fix build with ACCELERATED_COMPOSITING turned on.
3296
3297         Need to cast toRenderBox() in order to call overflowClipRect().
3298
3299         * rendering/RenderLayerBacking.cpp:
3300         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
3301
3302 2009-02-12  Oliver Hunt  <oliver@apple.com>
3303
3304         Reviewed by NOBODY (Build fix).
3305
3306         Fix windows build.
3307
3308         * css/CSSParser.h:
3309
3310 2009-02-12  David Hyatt  <hyatt@apple.com>
3311
3312         Rename getOverflowClipRect and getClipRect to overflowClipRect and clipRect.  Move them to RenderBox, since these methods
3313         only apply to boxes.  Devirtualize clipRect, since it was not subclassed.  Move controlClip stuff to RenderBox also.
3314
3315         Reviewed by Simon Fraser
3316
3317         * editing/Editor.cpp:
3318         (WebCore::Editor::insideVisibleArea):
3319         * rendering/RenderBox.cpp:
3320         (WebCore::RenderBox::overflowClipRect):
3321         (WebCore::RenderBox::clipRect):
3322         * rendering/RenderBox.h:
3323         (WebCore::RenderBox::hasControlClip):
3324         (WebCore::RenderBox::controlClipRect):
3325         * rendering/RenderForeignObject.cpp:
3326         (WebCore::RenderForeignObject::paint):
3327         * rendering/RenderLayer.cpp:
3328         (WebCore::RenderLayer::calculateClipRects):
3329         (WebCore::RenderLayer::calculateRects):
3330         * rendering/RenderLayerBacking.cpp:
3331         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
3332         * rendering/RenderObject.h:
3333         (WebCore::RenderObject::hasClip):
3334         (WebCore::RenderObject::hasOverflowClip):
3335         * rendering/RenderTable.cpp:
3336         (WebCore::RenderTable::overflowClipRect):
3337         * rendering/RenderTable.h:
3338
3339 2009-02-12  Simon Fraser  <simon.fraser@apple.com>
3340
3341         Fix build with ACCELERATED_COMPOSITING turned on (simple copy/paste error)
3342
3343         * platform/graphics/mac/GraphicsLayerCA.mm:
3344         (WebCore::GraphicsLayerCA::setBasicAnimation):
3345
3346 2009-02-12  Julien Chaffraix  <jchaffraix@webkit.org>
3347
3348         Not reviewed.
3349
3350         Release build fix when VIDEO is disabled (it should also
3351         help the builds with WORKERS or XSLT disabled).
3352
3353         * bindings/js/JSDOMWindowBase.cpp:
3354         (jsDOMWindowBaseAudio): Added an UNUSED_PARAM for exec and slot when
3355         VIDEO is disabled.
3356         (jsDOMWindowBaseWorker): Ditto for WORKERS.
3357         (jsDOMWindowBaseXSLTProcessor): Ditto for XSLT.
3358
3359 2009-02-12  Eric Carlson  <eric.carlson@apple.com>
3360
3361         Reviewed by Simon Fraser.
3362
3363         https://bugs.webkit.org/show_bug.cgi?id=23923
3364         Implement mediaPlayerVolumeChanged so a media engine can report autonomous volume changes.
3365         Supporting this requires that we know when we are processing a media engine callback so
3366         we don't turn around and tell the media player to change the volume when it is reporting
3367         a volume change.
3368
3369         * html/HTMLMediaElement.cpp:
3370         (WebCore::HTMLMediaElement::HTMLMediaElement): initialize m_processingMediaPlayerCallback
3371         (WebCore::HTMLMediaElement::mediaPlayerNetworkStateChanged): call begin/endProcessingMediaPlayerCallback
3372         (WebCore::HTMLMediaElement::setNetworkState): logic split out of mediaPlayerNetworkStateChanged
3373         to make it easier to maintain m_processingMediaPlayerCallback.
3374         (WebCore::HTMLMediaElement::mediaPlayerReadyStateChanged): call begin/endProcessingMediaPlayerCallback
3375         (WebCore::HTMLMediaElement::mediaPlayerTimeChanged): Ditto.
3376         (WebCore::HTMLMediaElement::mediaPlayerRepaint): Ditto.
3377         (WebCore::HTMLMediaElement::mediaPlayerVolumeChanged): New
3378         (WebCore::HTMLMediaElement::updateVolume): Don't change media engine volume if we are processing
3379         a callback from the engine.
3380         * html/HTMLMediaElement.h:
3381         (WebCore::HTMLMediaElement::processingMediaPlayerCallback): New, return true if (m_processingMediaPlayerCallback>0)
3382         (WebCore::HTMLMediaElement::beginProcessingMediaPlayerCallback): New, increment m_processingMediaPlayerCallback
3383         (WebCore::HTMLMediaElement::endProcessingMediaPlayerCallback): New, decrement m_processingMediaPlayerCallback
3384
3385 2009-02-12  Eric Carlson  <eric.carlson@apple.com>
3386
3387         Reviewed by Simon Fraser.
3388
3389         Support MPEG content on Mac and Windows.
3390         <rdar://problem/5917509>
3391         https://bugs.webkit.org/show_bug.cgi?id=23495
3392
3393         Test: media/audio-mpeg-supported.html
3394
3395         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
3396         (WebCore::MediaPlayerPrivate::disableUnsupportedTracks):
3397
3398         * platform/graphics/win/QTMovieWin.cpp:
3399         (QTMovieWin::disableUnsupportedTracks):
3400
3401         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.h: fix typo added in r40925
3402
3403 2009-02-12  David Hyatt  <hyatt@apple.com>
3404
3405         Reviewed by Sam Weinig
3406
3407         Move containsFloats, hasOverhangingFloats, shrinkToAvoidFloats and avoidsFloats down to
3408         RenderBox, since these methods only apply to boxes.
3409
3410         * rendering/RenderBlock.cpp:
3411         (WebCore::RenderBlock::collapseMargins):
3412         (WebCore::RenderBlock::clearFloatsIfNeeded):
3413         (WebCore::RenderBlock::layoutBlockChildren):
3414         (WebCore::RenderBlock::clearFloats):
3415         (WebCore::RenderBlock::markAllDescendantsWithFloatsForLayout):
3416         (WebCore::RenderBlock::calcBlockPrefWidths):
3417         * rendering/RenderBlock.h:
3418         (WebCore::RenderBlock::containsFloats):
3419         (WebCore::RenderBlock::hasOverhangingFloats):
3420         * rendering/RenderBox.cpp:
3421         (WebCore::RenderBox::shrinkToAvoidFloats):
3422         (WebCore::RenderBox::avoidsFloats):
3423         * rendering/RenderBox.h:
3424         * rendering/RenderObject.cpp:
3425         * rendering/RenderObject.h:
3426         (WebCore::RenderObject::isFloatingOrPositioned):
3427         * rendering/RenderView.h:
3428
3429 2009-02-12  Chris Marrin  <cmarrin@apple.com>
3430
3431         Reviewed by Dave Hyatt
3432
3433         https://bugs.webkit.org/show_bug.cgi?id=23908
3434
3435         Added parsing of 3d transform functions and properties
3436         (perspective, perspective-origin, transform-style-3d,
3437         and backface-visibility).
3438
3439         Test: transforms/3d/cssmatrix-3d-interface.xhtml
3440
3441         * css/CSSComputedStyleDeclaration.cpp:
3442         (WebCore::):
3443         (WebCore::computedTransform):
3444         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3445         * css/CSSMutableStyleDeclaration.cpp:
3446         (WebCore::CSSMutableStyleDeclaration::getPropertyValue):
3447         * css/CSSParser.cpp:
3448         (WebCore::CSSParser::parseValue):
3449         (WebCore::CSSParser::parseFillProperty):
3450         (WebCore::CSSParser::parseTransformOriginShorthand):
3451         (WebCore::TransformOperationInfo::TransformOperationInfo):
3452         (WebCore::CSSParser::parseTransform):
3453         (WebCore::CSSParser::parseTransformOrigin):
3454         (WebCore::CSSParser::parsePerspectiveOrigin):
3455         * css/CSSParser.h:
3456         * css/CSSPrimitiveValue.h:
3457         (WebCore::CSSPrimitiveValue::isUnitTypeLength):
3458         * css/CSSPropertyNames.in:
3459         * css/CSSStyleSelector.cpp:
3460         (WebCore::CSSStyleSelector::adjustRenderStyle):
3461         (WebCore::convertToLength):
3462         (WebCore::CSSStyleSelector::applyProperty):
3463         (WebCore::CSSStyleSelector::mapFillSize):
3464         (WebCore::CSSStyleSelector::mapFillXPosition):
3465         (WebCore::CSSStyleSelector::mapFillYPosition):
3466         (WebCore::getTransformOperationType):
3467         (WebCore::CSSStyleSelector::createTransformOperations):
3468         * css/CSSValueKeywords.in:
3469         * css/WebKitCSSTransformValue.cpp:
3470         (WebCore::WebKitCSSTransformValue::cssText):
3471         * css/WebKitCSSTransformValue.h:
3472         (WebCore::WebKitCSSTransformValue::):
3473         * css/WebKitCSSTransformValue.idl:
3474         * platform/graphics/transforms/Matrix3DTransformOperation.cpp:
3475         * platform/graphics/transforms/Matrix3DTransformOperation.h:
3476         * platform/graphics/transforms/PerspectiveTransformOperation.cpp:
3477         * platform/graphics/transforms/PerspectiveTransformOperation.h:
3478         * platform/graphics/transforms/RotateTransformOperation.cpp:
3479         (WebCore::RotateTransformOperation::blend):
3480         * platform/graphics/transforms/RotateTransformOperation.h:
3481         (WebCore::RotateTransformOperation::RotateTransformOperation):
3482         * platform/graphics/transforms/ScaleTransformOperation.h:
3483         (WebCore::ScaleTransformOperation::ScaleTransformOperation):
3484         * platform/graphics/transforms/TransformOperation.h:
3485         (WebCore::TransformOperation::is3DOperation):
3486         * platform/graphics/transforms/TransformOperations.h:
3487         (WebCore::TransformOperations::has3DOperation):
3488         * platform/graphics/transforms/TranslateTransformOperation.h:
3489         (WebCore::TranslateTransformOperation::TranslateTransformOperation):
3490
3491 2009-02-12  Kevin Ollivier  <kevino@theolliviers.com>
3492
3493         wx build fix.
3494
3495         * webcore-base.bkl:
3496
3497 2009-02-12  Brady Eidson  <beidson@apple.com>
3498
3499         Reviewed by Darin Adler
3500
3501         Fix potential ref-count or null-deref problems with C++ objects as Obj-C members.
3502
3503         * platform/mac/SharedBufferMac.mm: Change to use RefPtr<> instead of ref()/deref().
3504         (-[WebCoreSharedBufferData dealloc]):
3505         (-[WebCoreSharedBufferData finalize]):
3506         (-[WebCoreSharedBufferData initWithSharedBuffer:]):
3507
3508 2009-02-12  David Hyatt  <hyatt@apple.com>
3509
3510         Remove calcWidth from RenderObject.  Nobody ever called it on RenderObjects.
3511
3512         Reviewed by Sam Weinig
3513
3514         * rendering/RenderObject.h:
3515
3516 2009-02-12  David Hyatt  <hyatt@apple.com>
3517
3518         Reviewed by Mark Rowe
3519
3520         Fix for regression where form controls would paint yellow highlights.  The containsComposition check needs to
3521         null check node() now.
3522
3523         * rendering/InlineTextBox.cpp:
3524         (WebCore::InlineTextBox::paint):
3525
3526 2009-02-12  Simon Fraser  <simon.fraser@apple.com>
3527
3528         Build fix
3529
3530         Change Animation::setDirection() to take the new enum value, and fix
3531         the single caller.
3532
3533         Fix build error in MediaPlayerPrivateQTKit.h.
3534
3535         * css/CSSStyleSelector.cpp:
3536         (WebCore::CSSStyleSelector::mapAnimationDirection):
3537         * platform/animation/Animation.h:
3538         (WebCore::Animation::setDirection):
3539         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
3540
3541 2009-02-12  David Hyatt  <hyatt@apple.com>
3542
3543         Reviewed by Simon Fraser
3544
3545         Remove the overrideSize methods from RenderObject.  Devirtualize all of the accessors on RenderBox.
3546
3547         * rendering/RenderBox.h:
3548         * rendering/RenderObject.h:
3549
3550 2009-02-12  Eric Carlson  <eric.carlson@apple.com>
3551
3552         Darin Adler, Antti Koivisto, Holger Hans Peter Freyther
3553
3554         Bug 23797: A platform should be able to use more than one media engine for <video> and <audio>
3555         https://bugs.webkit.org/show_bug.cgi?id=23797
3556
3557         * WebCore.xcodeproj/project.pbxproj: add MediaPlayerPrivate.h
3558
3559         * html/HTMLMediaElement.cpp:
3560         (WebCore::HTMLMediaElement::load): selectMediaURL now also returns a MIME type, pass it to
3561         MediaPlayer::load so it can choose the right media engine
3562         (WebCore::HTMLMediaElement::selectMediaURL): renamed from pickMedia. use MIMETypeRegistry
3563         functions to strip params from the url and extract the codecs parameter. call
3564         MediaPlayer::supportsType to see if we can open the file since only a media engine can
3565         answer questions about supported type+codecs.
3566         * html/HTMLMediaElement.h:
3567
3568         * platform/MIMETypeRegistry.cpp:
3569         (WebCore::MIMETypeRegistry::getParameterFromMIMEType): New, find and return a MIME type parameter
3570         (WebCore::MIMETypeRegistry::stripParametersFromMIMEType): New, strip all parameters from a MIME type
3571         * platform/MIMETypeRegistry.h:
3572
3573         * platform/graphics/MediaPlayer.cpp:
3574         (WebCore::NullMediaPlayerPrivate::NullMediaPlayerPrivate):
3575         (WebCore::NullMediaPlayerPrivate::load):
3576         (WebCore::NullMediaPlayerPrivate::cancelLoad):
3577         (WebCore::NullMediaPlayerPrivate::play):
3578         (WebCore::NullMediaPlayerPrivate::pause):
3579         (WebCore::NullMediaPlayerPrivate::naturalSize):
3580         (WebCore::NullMediaPlayerPrivate::hasVideo):
3581         (WebCore::NullMediaPlayerPrivate::setVisible):
3582         (WebCore::NullMediaPlayerPrivate::duration):
3583         (WebCore::NullMediaPlayerPrivate::currentTime):
3584         (WebCore::NullMediaPlayerPrivate::seek):
3585         (WebCore::NullMediaPlayerPrivate::seeking):
3586         (WebCore::NullMediaPlayerPrivate::setEndTime):
3587         (WebCore::NullMediaPlayerPrivate::setRate):
3588         (WebCore::NullMediaPlayerPrivate::paused):
3589         (WebCore::NullMediaPlayerPrivate::setVolume):
3590         (WebCore::NullMediaPlayerPrivate::networkState):
3591         (WebCore::NullMediaPlayerPrivate::readyState):
3592         (WebCore::NullMediaPlayerPrivate::maxTimeSeekable):
3593         (WebCore::NullMediaPlayerPrivate::maxTimeBuffered):
3594         (WebCore::NullMediaPlayerPrivate::dataRate):
3595         (WebCore::NullMediaPlayerPrivate::totalBytesKnown):
3596         (WebCore::NullMediaPlayerPrivate::totalBytes):
3597         (WebCore::NullMediaPlayerPrivate::bytesLoaded):
3598         (WebCore::NullMediaPlayerPrivate::setRect):
3599         (WebCore::NullMediaPlayerPrivate::paint):
3600         (WebCore::createNullMediaPlayer):
3601         Do nothing media player so MediaPlayer doesn't have to NULL check before calling current engine.
3602
3603         (WebCore::MediaPlayerFactory::MediaPlayerFactory): New, factory constructor.
3604         (WebCore::installedMediaEngines): New, returns vector of all installed engines.
3605         (WebCore::addMediaEngine): New, add a media engine to the cache.
3606         (WebCore::chooseBestEngineForTypeAndCodecs): New, return an engine that might support a MIME type.
3607         (WebCore::MediaPlayer::MediaPlayer): create NULL media player so we have a default. Initialize m_currentMediaEngine.
3608         (WebCore::MediaPlayer::~MediaPlayer): don't need to delete m_private, it is now an OwnPtr.
3609         (WebCore::MediaPlayer::load): Take MIME type as well as url, since we need it to find the right
3610           media engine. If no MIME type is provided, try to devine one from the url. Choose a media engine
3611           based on the MIME type and codecs parameter.
3612         (WebCore::MediaPlayer::currentTime): Remove excess white space.
3613         (WebCore::MediaPlayer::supportsType): Take codecs param as well as MIME type. Return enum so we can
3614         indicate "maybe" condition.
3615         (WebCore::MediaPlayer::getSupportedTypes): Build up list of MIME types by consulting all engines.
3616         (WebCore::MediaPlayer::isAvailable): return true if any media engine is installed.
3617
3618         * platform/graphics/MediaPlayer.h:
3619         (WebCore::MediaPlayer::):
3620         (WebCore::MediaPlayer::frameView): accessor function.
3621
3622         *