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