2009-10-12 Dirk Schulze <krit@webkit.org>
[WebKit-https.git] / WebCore / ChangeLog
1 2009-10-12  Dirk Schulze  <krit@webkit.org>
2
3         Reviewed by Eric Seidel.
4
5         SVG - crash on feMerge when input not available
6         [https://bugs.webkit.org/show_bug.cgi?id=30297]
7
8         Make a early return in SVGFEMergeElement if the needed
9         filter effect doesn't exist.
10
11         Test: svg/filters/feMerge-wrong-input.svg
12
13         * svg/SVGFEMergeElement.cpp:
14         (WebCore::SVGFEMergeElement::build):
15
16 2009-10-12  Chris Marrin  <cmarrin@apple.com>
17
18         Reviewed by Oliver Hunt.
19
20         Added automatic flush before compositing
21         https://bugs.webkit.org/show_bug.cgi?id=30236
22
23         This causes image to always render correctly. In writing a testcase
24         I needed to implement readPixels. This exposed a bug in reading back
25         values from a CanvasArray subclass, so I fixed that as well. Now when
26         you wrap a CanvasArray in a JSValue it actually wraps the specific
27         subclass. To do this I need to add virtual methods to each CanvasArray
28         subclass to determine the type and a custom toJS method for CanvasArray
29         to create the proper wrapper. 
30
31         Test: fast/canvas/webgl/triangle.html
32
33         * WebCore.xcodeproj/project.pbxproj:
34         * bindings/js/JSCanvasArrayCustom.cpp:
35         (WebCore::toJS):
36         * html/canvas/CanvasArray.h:
37         (WebCore::CanvasArray::isByteArray):
38         (WebCore::CanvasArray::isUnsignedByteArray):
39         (WebCore::CanvasArray::isShortArray):
40         (WebCore::CanvasArray::isUnsignedShortArray):
41         (WebCore::CanvasArray::isIntArray):
42         (WebCore::CanvasArray::isUnsignedIntArray):
43         (WebCore::CanvasArray::isFloatArray):
44         * html/canvas/CanvasArray.idl:
45         * html/canvas/CanvasByteArray.h:
46         (WebCore::CanvasByteArray::isByteArray):
47         * html/canvas/CanvasFloatArray.h:
48         (WebCore::CanvasFloatArray::isFloatArray):
49         * html/canvas/CanvasIntArray.h:
50         (WebCore::CanvasIntArray::isIntArray):
51         * html/canvas/CanvasRenderingContext3D.cpp:
52         (WebCore::CanvasRenderingContext3D::readPixels):
53         * html/canvas/CanvasRenderingContext3D.h:
54         * html/canvas/CanvasRenderingContext3D.idl:
55         * html/canvas/CanvasShortArray.h:
56         (WebCore::CanvasShortArray::isShortArray):
57         * html/canvas/CanvasUnsignedByteArray.h:
58         (WebCore::CanvasUnsignedByteArray::isUnsignedByteArray):
59         * html/canvas/CanvasUnsignedIntArray.h:
60         (WebCore::CanvasUnsignedIntArray::isUnsignedIntArray):
61         * html/canvas/CanvasUnsignedShortArray.h:
62         (WebCore::CanvasUnsignedShortArray::isUnsignedShortArray):
63         * platform/graphics/GraphicsContext3D.h:
64         * platform/graphics/mac/Canvas3DLayer.mm:
65         (-[Canvas3DLayer drawInCGLContext:pixelFormat:forLayerTime:displayTime:]):
66         * platform/graphics/mac/GraphicsContext3DMac.cpp:
67         (WebCore::GraphicsContext3D::readPixels):
68
69 2009-10-12  Sebastian Dröge  <sebastian.droege@collabora.co.uk>
70
71         Reviewed by Gustavo Noronha.
72
73         https://bugs.webkit.org/show_bug.cgi?id=30307
74         
75         Fix 0 sentinel for g_object_set() function call.
76
77         * platform/graphics/gtk/DataSourceGStreamer.cpp:
78         (webkit_data_src_uri_set_uri):
79         0 is passed as 32 bit value on x86-64 in vararg functions, but
80         g_object_set() expects a 64 bit 0. This will cause crashes.
81
82 2009-10-12  Cameron McCormack  <cam@mcc.id.au>
83
84         Reviewed by Eric Seidel.
85
86         Drop in="" from <feFlood>
87         https://bugs.webkit.org/show_bug.cgi?id=29001
88
89         This makes <feFlood in="bogus"> have an effect, too.
90
91         http://www.w3.org/2003/01/REC-SVG11-20030114-errata#feflood-attribute
92
93         Test: svg/dom/feFlood-no-in1.html
94
95         * svg/SVGFEFloodElement.cpp:
96         (WebCore::SVGFEFloodElement::SVGFEFloodElement):
97         (WebCore::SVGFEFloodElement::build):
98         * svg/SVGFEFloodElement.h:
99         * svg/SVGFEFloodElement.idl:
100         * svg/graphics/filters/SVGFEFlood.cpp:
101         (WebCore::FEFlood::FEFlood):
102         (WebCore::FEFlood::create):
103         * svg/graphics/filters/SVGFEFlood.h:
104
105 2009-10-12  Sebastian Dröge  <sebastian.droege@collabora.co.uk>
106
107         Reviewed by Gustavo Noronha.
108
109         https://bugs.webkit.org/show_bug.cgi?id=29998
110         
111         Scale video to completely fill the target surface while
112         keeping the aspect ratio. This fixes displaying of the
113         YouTube HTML5 sample website.
114
115         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
116         Scale video to completely fill the target surface, keep
117         the aspect ratio and center it.
118
119 2009-10-12  Sebastian Dröge  <sebastian.droege@collabora.co.uk>
120
121         Reviewed by Gustavo Noronha.
122
123         https://bugs.webkit.org/show_bug.cgi?id=29997
124         
125         Fixes double memcpy of all rendered video frames.
126
127         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
128         (WebCore::mediaPlayerPrivateRepaintCallback):
129         (WebCore::MediaPlayerPrivate::MediaPlayerPrivate):
130         (WebCore::MediaPlayerPrivate::~MediaPlayerPrivate):
131         (WebCore::MediaPlayerPrivate::duration):
132         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.h:
133         * platform/graphics/gtk/VideoSinkGStreamer.cpp:
134         (webkit_video_sink_timeout_func):
135         (webkit_video_sink_dispose):
136         (unlock_buffer_mutex):
137         (webkit_video_sink_unlock):
138         (marshal_VOID__MINIOBJECT):
139         (webkit_video_sink_class_init):
140         (webkit_video_sink_new):
141         * platform/graphics/gtk/VideoSinkGStreamer.h:
142         Directly pass the buffers up to the MediaPlayerPrivate::paint()
143         method instead of rendering them first to an intermediate cairo
144         surface. This should increase performance and peak memory usage.
145
146 2009-10-11  Daniel Bates  <dbates@webkit.org>
147
148         Reviewed by Adam Barth.
149
150         https://bugs.webkit.org/show_bug.cgi?id=30242
151         
152         Fixes an issue where JavaScript URLs that are URL-encoded twice can 
153         bypass the XSSAuditor.
154         
155         JavaScript URLs that are completed by method Document::completeURL have added
156         URL-encoded characters such that a direct comparison with the URL-decoded 
157         outgoing HTTP parameters is not sufficient. Instead, the URL-decoded outgoing 
158         HTTP parameters must be URL-decoded before comparison.
159
160         Tests: http/tests/security/xssAuditor/iframe-javascript-url-twice-url-encode.html
161                http/tests/security/xssAuditor/iframe-javascript-url-twice-url-encode2.html
162                http/tests/security/xssAuditor/iframe-javascript-url-twice-url-encode3.html
163
164         * bindings/ScriptControllerBase.cpp:
165         (WebCore::ScriptController::executeIfJavaScriptURL): Modified to pass XSSAuditor
166         the URL-decoded source code for the JavaScript URL.
167         * page/XSSAuditor.cpp:
168         (WebCore::isIllegalURICharacter): Minor syntactical change to the comment.
169         (WebCore::XSSAuditor::CachingURLCanonicalizer::canonicalizeURL): Added 
170         parameter decodeURLEscapeSequencesTwice.
171         (WebCore::XSSAuditor::canEvaluateJavaScriptURL):
172         (WebCore::XSSAuditor::decodeURL): Ditto.
173         (WebCore::XSSAuditor::findInRequest): Ditto.
174         * page/XSSAuditor.h:
175         (WebCore::XSSAuditor::CachingURLCanonicalizer::CachingURLCanonicalizer): Ditto.
176
177 2009-10-11  Dominic Cooney  <dominicc@google.com>
178
179         Reviewed by Adam Barth.
180
181         Fixes a build break in the V8 bindings caused by revision 49420.
182         https://bugs.webkit.org/show_bug.cgi?id=30294
183
184         Revision 49420 introduces an IDL-defined CanvasActiveInfo
185         type. This causes a build break in the V8 bindings where
186         CanvasGraphicsContext3D naively refers to CanvasActiveInfo as a
187         non-ref type.
188
189         * WebCore.gypi: Include CanvasActiveInfo.idl in build.
190         * bindings/scripts/CodeGeneratorV8.pm: CanvasActiveInfo is a ref
191           ptr type.
192         * bindings/v8/DOMObjectsInclude.h: Include generated
193           CanvasActiveInfo files.
194         * bindings/v8/DerivedSourcesAllInOne.cpp:
195         * bindings/v8/V8Index.cpp:
196         * bindings/v8/V8Index.h:
197
198 2009-10-11  Collin Jackson  <collinj@webkit.org>
199
200         Reviewed by Adam Barth.
201
202         Log mixed content warnings to console
203
204         https://bugs.webkit.org/show_bug.cgi?id=30290
205
206         * loader/FrameLoader.cpp:
207         (WebCore::FrameLoader::checkIfDisplayInsecureContent):
208         (WebCore::FrameLoader::checkIfRunInsecureContent):
209
210 2009-10-11  Søren Gjesse  <sgjesse@chromium.org>
211
212         Reviewed by Adam Barth.
213
214         [V8] Add a context scope in JS listener destructor. The destructor code uses the cotext. See http://crbug.com/24200.
215         https://bugs.webkit.org/show_bug.cgi?id=30250
216
217         * bindings/v8/V8AbstractEventListener.cpp:
218         (WebCore::V8AbstractEventListener::~V8AbstractEventListener):
219
220 2009-10-11  Lyon Chen  <lyon.chen@torchmobile.com>
221
222         Reviewed by Alexey Proskuryakov.
223
224         Correct the position of #endif sentence inside WebCore::Document::finishedParsing().
225
226         https://bugs.webkit.org/show_bug.cgi?id=30244
227
228         This change requires no test case as it fix a compiling error.
229
230         * dom/Document.cpp:
231         (WebCore::Document::finishedParsing):
232
233 2009-10-11  Dominic Cooney  <dominicc@google.com>
234
235         Reviewed by Adam Barth.
236
237         Sets a 500K stack limit for JavaScript workers in Chromium.
238         https://bugs.webkit.org/show_bug.cgi?id=29797
239
240         Runaway recursion in JavaScript workers crashes the Chromium
241         worker process on OS X. This is because V8's default stack limit
242         is 512K on ia32 or 1M on x64, but the worker process runs workers
243         on a thread with the OS X default stack size--512K. Because there
244         are already some C++ frames on the stack when V8 establishes its
245         512K default stack limit, and V8 doesn't precisely enforce the
246         stack limit, runaway recursion in V8 workers overflows the OS
247         stack and segfaults, killing the worker process. This is described
248         in Chromium bug 21653 <http://crbug.com/21653>.
249
250         This patch sets the V8 stack limit for worker JavaScript in
251         Chromium to a more conservative 500K on all platforms. This allows
252         some "headroom" for the C++ stack in use when the limit is set up,
253         and some "legroom" for the V8 helper functions which in practice
254         briefly flout the V8 stack limit.
255
256         Test: LayoutTests/fast/workers/use-machine-stack.html
257
258         * bindings/v8/WorkerContextExecutionProxy.cpp:
259         (WebCore::WorkerContextExecutionProxy::initV8IfNeeded):
260         * bindings/v8/WorkerContextExecutionProxy.h:
261
262 2009-10-11  Kevin Ollivier  <kevino@theolliviers.com>
263
264         wx build fix for wxMac 2.9, use wxGC API for measuring text.
265
266         * platform/wx/wxcode/mac/carbon/fontprops.cpp:
267         (GetTextExtent):
268
269 2009-10-10  Cameron McCormack  <cam@mcc.id.au>
270
271         Reviewed by Sam Weinig.
272
273         Allow [Reflect] on SVG elements.
274         https://bugs.webkit.org/show_bug.cgi?id=28936
275
276         Update the JS binding generators to reference SVGNames instead of
277         HTMLNames, if [Reflect]ing an attribute on an SVG element.  Make
278         SVGElement::id use [Reflect].
279
280         Also make [Reflect] on an attribute with a setter exception work in ObjC
281         bindings.
282
283         Test: svg/dom/id-reflect.html
284
285         * bindings/scripts/CodeGenerator.pm: Add a function to determine the
286         appropriate C++ namespace for attribute name constants.
287         * bindings/scripts/CodeGeneratorObjC.pm: Generate ExceptionCode handling
288         code for [Reflect] on an attribute with a setter exception.
289         * bindings/scripts/CodeGeneratorCOM.pm: Generate "SVGNames" instead of
290         "HTMLNames" when appropriate.
291         * bindings/scripts/CodeGeneratorJS.pm: Ditto.
292         * bindings/scripts/CodeGeneratorV8.pm: Ditto.
293         * svg/SVGElement.cpp: Remove getter and setter methods for id.
294         * svg/SVGElement.h: Ditto.
295         * svg/SVGElement.idl: Add [Reflect] to id.
296
297 2009-10-10  Oliver Hunt  <oliver@apple.com>
298
299         Fix paths in xcode.
300
301         * WebCore.xcodeproj/project.pbxproj:
302
303 2009-10-10  Oliver Hunt  <oliver@apple.com>
304
305         Reviewed by Eric Carlson.
306
307         Implement getActiveAttrib and getActiveUniform
308         https://bugs.webkit.org/show_bug.cgi?id=30276
309
310         Implements the getActiveAttrib and getActiveUniform APIs.
311         Rather simple patch, adds CanvasActiveInfo definition and implementation
312         and adds forwarding to the GraphicsContext3D.
313
314         Test: fast/canvas/webgl/getActiveTest.html
315
316         * DerivedSources.make:
317         * WebCore.xcodeproj/project.pbxproj:
318         * html/canvas/CanvasActiveInfo.h: Added.
319         (WebCore::CanvasActiveInfo::create):
320         (WebCore::CanvasActiveInfo::name):
321         (WebCore::CanvasActiveInfo::type):
322         (WebCore::CanvasActiveInfo::size):
323         (WebCore::CanvasActiveInfo::CanvasActiveInfo):
324         * html/canvas/CanvasActiveInfo.idl: Added.
325         * html/canvas/CanvasObject.h:
326         (WebCore::CanvasObject::context):
327           Need to make the context public as it is needed to ensure we don't
328           provide a program from one context as an argument to another.
329         * html/canvas/CanvasRenderingContext3D.cpp:
330         (WebCore::CanvasRenderingContext3D::getActiveAttrib):
331         (WebCore::CanvasRenderingContext3D::getActiveUniform):
332         * html/canvas/CanvasRenderingContext3D.h:
333         * html/canvas/CanvasRenderingContext3D.idl:
334         * platform/graphics/GraphicsContext3D.h:
335         * platform/graphics/mac/GraphicsContext3DMac.cpp:
336         (WebCore::GraphicsContext3D::getActiveAttrib):
337         (WebCore::GraphicsContext3D::getActiveUniform):
338
339 2009-10-10  Pavel Feldman  <pfeldman@chromium.org>
340
341         Reviewed by Timothy Hatcher.
342
343         Web Inspector: Adding new attributes in Element Panel is
344         counterintuitive.
345
346         https://bugs.webkit.org/show_bug.cgi?id=30057
347
348         * inspector/front-end/ElementsTreeOutline.js:
349         (WebInspector.ElementsTreeOutline.prototype._onmousemove):
350         (WebInspector.ElementsTreeElement.prototype.set hovered):
351         (WebInspector.ElementsTreeElement.prototype.toggleNewAttributeButton):
352
353 2009-10-10  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
354
355         Reviewed by Holger Freyther.
356
357         Build fix if Netscape plugin support is turned off
358         https://bugs.webkit.org/show_bug.cgi?id=30275
359
360         In addition to fixing the build break with guards
361         remove notImplemented() from PluginViewNone.cpp and
362         make them just just be empty functions.
363
364         * plugins/PluginView.cpp:
365         (WebCore::PluginView::handleEvent):
366         (WebCore::PluginView::PluginView):
367         * plugins/PluginView.h:
368         * plugins/PluginViewNone.cpp:
369         (WebCore::PluginView::setFocus):
370         (WebCore::PluginView::show):
371         (WebCore::PluginView::hide):
372         (WebCore::PluginView::paint):
373         (WebCore::PluginView::handleKeyboardEvent):
374         (WebCore::PluginView::handleMouseEvent):
375         (WebCore::PluginView::setParent):
376         (WebCore::PluginView::setNPWindowRect):
377         (WebCore::PluginView::handlePostReadFile):
378         (WebCore::PluginView::getValue):
379         (WebCore::PluginView::getValueStatic):
380         (WebCore::PluginView::invalidateRect):
381         (WebCore::PluginView::invalidateRegion):
382         (WebCore::PluginView::forceRedraw):
383         (WebCore::PluginView::platformStart):
384         (WebCore::PluginView::platformDestroy):
385         (WebCore::PluginView::setParentVisible):
386         (WebCore::PluginView::updatePluginWidget):
387
388 2009-10-10  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
389
390         Unreviewed.
391
392         [Qt] Build fix for QtWebKit after r49415.
393
394         Add HistoryController.cpp to the build.
395
396         * WebCore.pro:
397
398 2009-10-09  Darin Fisher  <darin@chromium.org>
399
400         Reviewed by Eric Seidel.
401
402         [Chromium] KURLGoogle's protocolIs barfs on input containing hyphens
403         https://bugs.webkit.org/show_bug.cgi?id=30262
404
405         This is not testable from WebKit since WebKit never uses the member
406         function form of protocolIs with input that can be controlled from a
407         web page.  It always passes string literals lacking hyphens.
408
409         * platform/KURLGoogle.cpp:
410         (WebCore::lowerCaseEqualsASCII): Only assert if toASCIILower would
411         transform the input character.
412
413 2009-10-10  Adam Barth  <abarth@webkit.org>
414
415         Reviewed by Oliver Hunt.
416
417         Move HistoryController to its own file
418         https://bugs.webkit.org/show_bug.cgi?id=30272
419
420         Purely mechanical.
421
422         * GNUmakefile.am:
423         * WebCore.gypi:
424         * WebCore.vcproj/WebCore.vcproj:
425         * WebCore.xcodeproj/project.pbxproj:
426         * WebCoreSources.bkl:
427         * loader/FrameLoader.cpp:
428         * loader/FrameLoader.h:
429         * loader/HistoryController.cpp: Added.
430         * loader/HistoryController.h: Added.
431
432 2009-10-09  Ryosuke Niwa  <rniwa@webkit.org>
433
434         Reviewed by Eric Seidel.
435
436         ApplyStyleCommand removes presentational tags even when not necessary
437         https://bugs.webkit.org/show_bug.cgi?id=28091
438
439         This patch updates implicitlyStyledElementShouldBeRemovedWhenApplyingStyle to return true
440         (triggering removal of tag) only if the style implicitly added by the element is not present in
441         the new style to apply. It also changes surroundNodeRangeWithElement so that it merges the
442         surrounding element when possible. applyTextDecorationStyle is modified so that it does not add
443         style span when the style attribute is empty.
444
445         Test: editing/execCommand/toggle-style-3.html
446
447         * editing/ApplyStyleCommand.cpp:
448         (WebCore::ApplyStyleCommand::shouldRemoveTextDecorationTag): Returns true if specified text
449         decoration is not present in the style to apply
450         (WebCore::ApplyStyleCommand::implicitlyStyledElementShouldBeRemovedWhenApplyingStyle): No longer
451         returns true if the tag is used in new style
452         (WebCore::ApplyStyleCommand::applyTextDecorationStyle): Does not add style-span when redundant
453         (WebCore::ApplyStyleCommand::surroundNodeRangeWithElement): Merges the newly created element
454         with the surrounding identical elements
455         * editing/ApplyStyleCommand.h:
456
457 2009-10-09  Adam Barth  <abarth@webkit.org>
458
459         Reviewed by Darin Adler.
460
461         Factor HistoryController out of FrameLoader
462         https://bugs.webkit.org/show_bug.cgi?id=30246
463
464         HistoryController is in charge of managing the current / previous /
465         provisional HistoryItems.  The split isn't perfect, but it's a place to
466         start.  I'll move HistoryController into its own file in another patch.
467
468         * WebCore.base.exp:
469         * loader/FrameLoader.cpp:
470         (WebCore::HistoryController::HistoryController):
471         (WebCore::HistoryController::~HistoryController):
472         (WebCore::FrameLoader::FrameLoader):
473         (WebCore::FrameLoader::closeURL):
474         (WebCore::FrameLoader::begin):
475         (WebCore::HistoryController::restoreDocumentState):
476         (WebCore::HistoryController::setCurrentItem):
477         (WebCore::HistoryController::setProvisionalItem):
478         (WebCore::FrameLoader::loadURLIntoChildFrame):
479         (WebCore::FrameLoader::canCachePageContainingThisFrame):
480         (WebCore::FrameLoader::logCanCacheFrameDecision):
481         (WebCore::FrameLoader::scrollToAnchor):
482         (WebCore::FrameLoader::commitProvisionalLoad):
483         (WebCore::FrameLoader::transitionToCommitted):
484         (WebCore::FrameLoader::checkLoadCompleteForThisFrame):
485         (WebCore::FrameLoader::didFirstLayout):
486         (WebCore::HistoryController::updateForFrameLoadCompleted):
487         (WebCore::FrameLoader::frameLoadCompleted):
488         (WebCore::FrameLoader::detachFromParent):
489         (WebCore::FrameLoader::receivedMainResourceError):
490         (WebCore::FrameLoader::continueFragmentScrollAfterNavigationPolicy):
491         (WebCore::FrameLoader::continueLoadAfterNavigationPolicy):
492         (WebCore::HistoryController::addHistoryItemForFragmentScroll):
493         (WebCore::FrameLoader::loadProvisionalItemFromCachedPage):
494         (WebCore::FrameLoader::shouldTreatURLAsSameAsCurrent):
495         (WebCore::HistoryController::createHistoryItem):
496         (WebCore::FrameLoader::checkDidPerformFirstNavigation):
497         (WebCore::HistoryController::addBackForwardItemClippedAtTarget):
498         (WebCore::HistoryController::createHistoryItemTree):
499         (WebCore::HistoryController::saveScrollPositionAndViewStateToItem):
500         (WebCore::HistoryController::restoreScrollPositionAndViewState):
501         (WebCore::HistoryController::invalidateCurrentItemCachedPage):
502         (WebCore::HistoryController::saveDocumentState):
503         (WebCore::FrameLoader::loadItem):
504         (WebCore::HistoryController::urlsMatchItem):
505         (WebCore::HistoryController::goToItem):
506         (WebCore::HistoryController::recursiveGoToItem):
507         (WebCore::HistoryController::childFramesMatchItem):
508         (WebCore::HistoryController::updateForStandardLoad):
509         (WebCore::HistoryController::updateForClientRedirect):
510         (WebCore::HistoryController::updateForBackForwardNavigation):
511         (WebCore::HistoryController::updateForReload):
512         (WebCore::HistoryController::updateForRedirectWithLockedBackForwardList):
513         (WebCore::HistoryController::updateForCommit):
514         (WebCore::HistoryController::updateForAnchorScroll):
515         (WebCore::HistoryController::saveDocumentAndScrollState):
516         (WebCore::HistoryController::setCurrentItemTitle):
517         (WebCore::FrameLoader::didChangeTitle):
518         * loader/FrameLoader.h:
519         (WebCore::HistoryController::current):
520         (WebCore::HistoryController::provisional):
521         (WebCore::FrameLoader::policyChecker):
522         (WebCore::FrameLoader::history):
523         (WebCore::FrameLoader::creatingInitialEmptyDocument):
524         * page/Page.cpp:
525         (WebCore::Page::goToItem):
526
527 2009-10-09  Alexey Proskuryakov  <ap@apple.com>
528
529         Unreviewed - fixing an obvious typo in my previous check-in.
530
531         https://bugs.webkit.org/show_bug.cgi?id=30260
532         <rdar://problem/6447115> REGRESSION: Logging out from SAP doesn't work
533
534         Fixes existing tests (which I thought I had run the previous time).
535
536         * platform/network/CredentialStorage.cpp: (WebCore::originsWithCredentials): Return the
537         set by reference.
538
539 2009-10-09  David Levin  <levin@chromium.org>
540
541         Reviewed by Eric Seidel.
542
543         [v8] Need change to V8WorkerContextEventListener::reportError signature to match the base class.
544         https://bugs.webkit.org/show_bug.cgi?id=30264
545
546         The base class method changed in r48884.
547
548         Test: fast/worker/worker-script-error.html
549
550         * bindings/v8/V8WorkerContextEventListener.cpp:
551         (WebCore::V8WorkerContextEventListener::reportError):
552         * bindings/v8/V8WorkerContextEventListener.h:
553
554 2009-10-09  Alexey Proskuryakov  <ap@apple.com>
555
556         Reviewed by Brady Eidson.
557
558         https://bugs.webkit.org/show_bug.cgi?id=30260
559         <rdar://problem/6447115> REGRESSION: Logging out from SAP doesn't work
560
561         Tests: http/tests/xmlhttprequest/logout.html
562                http/tests/xmlhttprequest/re-login-async.html
563                http/tests/xmlhttprequest/re-login.html
564
565         Fix several issues with existing credential handling code.
566
567         * platform/network/CredentialStorage.cpp:
568         (WebCore::pathToDefaultProtectionSpaceMap): Changed the data structure to a simpler one.
569         (WebCore::originsWithCredentials): The reason for two-stage lookup above was that we didn't
570         want to iterate paths for origins that never had credentials associated with them. Changed
571         to use a separate HashSet for this.
572         (WebCore::pathToDefaultProtectionSpaceMap): The concept of default per-path credentials didn't
573         match the spec very well. UAs are supposed to deduce protection space from an URL, and then
574         use whichever credentials are known for this protection space. So, OriginToDefaultBasicCredentialMap
575         is now PathToDefaultProtectionSpaceMap.
576         (WebCore::protectionSpaceMapKeyFromURL): Factored out a helper that extracts a directory
577         URL from a given URL. These directory URLs are what we use as keys in PathToDefaultProtectionSpaceMap.
578         (WebCore::CredentialStorage::set): Updated for above changes.
579         (WebCore::findDefaultProtectionSpaceForURL): Factored out code iterating path length to find
580         a prefix in OriginToDefaultBasicCredentialMap.
581         (WebCore::CredentialStorage::set): Another version of set() can update credentials for a
582         URL default protection space. It does nothing if the given URL doesn't correspond to a known
583         protection space.
584         (WebCore::CredentialStorage::get): Renamed from getDefaultAuthenticationCredential.
585
586         * platform/network/CredentialStorage.h: Made the distinction between methods that use a known
587         protection space and those that deduce one from URL more clear.
588
589         * platform/network/mac/ResourceHandleMac.mm:
590         (WebCore::ResourceHandle::start): Update credentials before starting the request for real.
591         This makes the following pattern work:
592           var req = new XMLHttpRequest("GET", "logout.html", "logout", "logout"); // wrong credentials
593           req.send("");
594           req.abort();
595         Abort() is used here to avoid having UA present an auth dialog after getting a 401 response.
596         Note that one cannot log in using the same method, because there isn't a known protection
597         space for the URL yet in that case, so the added code has no effect.
598         (WebCore::ResourceHandle::didReceiveAuthenticationChallenge): Use a correct persistence for
599         calling receivedCredential(). This fixes logging in using an async XHR (withut abort(), of
600         course), and matches sync case.
601         (+[WebCoreSynchronousLoader loadRequest:allowStoredCredentials:returningResponse:error:]):
602         Renamed getDefaultAuthenticationCredential() to get().
603
604         * platform/network/cf/ResourceHandleCFNet.cpp:
605         (WebCore::ResourceHandle::start):
606         (WebCore::WebCoreSynchronousLoader::load):
607         Same changes as in Mac code.
608
609 2009-10-09  Enrica Casucci  <enrica@apple.com>
610
611         Reviewed by Adele Peterson.
612
613         Undoing a indent removes text instead of it's formatting.
614         <rdar://problem/7169206>
615         https://bugs.webkit.org/show_bug.cgi?id=28722
616         Restored the behavior prior to http://trac.webkit.org/changeset/46143. This change implemented the
617         indent command making simple DOM operation, without using moveParagraph which cause undo to be broken.
618         
619         Added editing/undo/undo-indent.html test.
620
621         * editing/IndentOutdentCommand.cpp:
622         (WebCore::IndentOutdentCommand::prepareBlockquoteLevelForInsertion): Restored. 
623         (WebCore::IndentOutdentCommand::tryIndentingAsListItem): Merged changes.
624         (WebCore::IndentOutdentCommand::indentIntoBlockquote): Restored.
625         (WebCore::IndentOutdentCommand::indentRegion): Restored and added call to updateLayout to
626         ensure TextIterator could correctly calculate the position starting from the index.
627         * editing/IndentOutdentCommand.h: Restored.
628
629 2009-10-09  Jens Alfke  <snej@chromium.org>
630
631         Reviewed by Darin Adler.
632         
633         Optimization: Many StringImpl transformations are no-ops and should just return 'this'
634         https://bugs.webkit.org/show_bug.cgi?id=30186
635
636         Optimized StringImpl methods lower(), stripWhiteSpace() and simplifyWhiteSpace() to
637         detect no-ops and return this instead of creating a new instance.
638         Empirical testing shows that the majority of calls to these methods are no-ops, making
639         this worthwhile even if (in the case of lower()) the non-no-op case is slightly slowed.
640         Upper() is very rarely a no-op, so it wasn't worthwhile to optimize it.
641
642         * platform/text/StringImpl.cpp:
643         (WebCore::StringImpl::lower):
644         (WebCore::StringImpl::upper): Just add a comment explaining why this wasn't optimized
645         (WebCore::StringImpl::stripWhiteSpace):
646         (WebCore::StringImpl::simplifyWhiteSpace):
647
648 2009-10-09  Dirk Schulze  <krit@webkit.org>
649
650         Reviewed by Oliver Hunt.
651
652         SVG Filter feGaussianBlur implementation is missing
653         [https://bugs.webkit.org/show_bug.cgi?id=28141]
654
655         This is the implementation of GaussianBlur filter for SVG.
656
657         There is already a test for feGaussianBlur
658         Test: svg/W3C-SVG-1.1/filters-gauss-01-b-w3c.svg 
659
660         Test: svg/filters/feGaussianBlur.svg
661
662         * platform/graphics/filters/FilterEffect.cpp:
663         (WebCore::FilterEffect::FilterEffect):
664         * platform/graphics/filters/FilterEffect.h:
665         (WebCore::FilterEffect::isAlphaImage):
666         (WebCore::FilterEffect::setIsAlphaImage):
667         * platform/graphics/filters/SourceAlpha.cpp:
668         (WebCore::SourceAlpha::apply):
669         * svg/graphics/filters/SVGFEGaussianBlur.cpp:
670         (WebCore::boxBlur):
671         (WebCore::FEGaussianBlur::apply):
672
673 2009-10-09  Philippe Normand  <pnormand@igalia.com>
674
675         Reviewed by Gustavo Noronha.
676
677         [GTK] QoS support in the video sink
678         https://bugs.webkit.org/show_bug.cgi?id=29959
679
680         Removed the async buffer queue from the sink. Synchronize the
681         render method of the sink using a g_timeout_add() combined with a
682         gcond triggered when the buffer has been rendered.
683         Also fixed the video sink reference handling in the player, now
684         that the idle is not there anymore to mess up things.
685
686         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
687         (WebCore::MediaPlayerPrivate::~MediaPlayerPrivate):
688         (WebCore::MediaPlayerPrivate::createGSTPlayBin):
689         * platform/graphics/gtk/VideoSinkGStreamer.cpp:
690         (webkit_video_sink_init):
691         (webkit_video_sink_timeout_func):
692         (webkit_video_sink_render):
693         (webkit_video_sink_dispose):
694         (unlock_buffer_mutex):
695         (webkit_video_sink_unlock):
696         (webkit_video_sink_stop):
697         (webkit_video_sink_class_init):
698
699 2009-10-09  Dirk Schulze  <krit@webkit.org>
700
701         Reviewed by Nikolas Zimmermann.
702
703         feMorphology filter is not implemented
704         [https://bugs.webkit.org/show_bug.cgi?id=5863]
705
706         Adds SVGFEMorphologyElement, for the SVG filter. It also fixes a bug
707         with the attribute "operator". It was only accessible via "_operator" 
708         on JavaScript.
709
710         Test: svg/dom/operatorAttribute.xhtml
711
712         * DerivedSources.cpp:
713         * DerivedSources.make:
714         * GNUmakefile.am:
715         * WebCore.SVG.Filters.exp:
716         * WebCore.gypi:
717         * WebCore.pro:
718         * WebCore.xcodeproj/project.pbxproj:
719         * bindings/objc/DOM.mm:
720         (WebCore::createElementClassMap):
721         * bindings/objc/DOMSVG.h:
722         * bindings/scripts/CodeGeneratorJS.pm:
723         * bindings/scripts/CodeGeneratorObjC.pm:
724         * page/DOMWindow.idl:
725         * svg/SVGAllInOne.cpp:
726         * svg/SVGFECompositeElement.idl:
727         * svg/SVGFEMorphologyElement.cpp: Added.
728         (WebCore::SVGFEMorphologyElement::SVGFEMorphologyElement):
729         (WebCore::SVGFEMorphologyElement::~SVGFEMorphologyElement):
730         (WebCore::SVGFEMorphologyElement::setRadius):
731         (WebCore::SVGFEMorphologyElement::parseMappedAttribute):
732         (WebCore::SVGFEMorphologyElement::build):
733         * svg/SVGFEMorphologyElement.h: Added.
734         * svg/SVGFEMorphologyElement.idl: Added.
735         * svg/graphics/filters/SVGFEMorphology.cpp:
736         (WebCore::operator<<):
737         * svg/graphics/filters/SVGFEMorphology.h:
738         (WebCore::):
739         * svg/svgtags.in:
740
741 2009-10-09  Yury Semikhatsky  <yurys@chromium.org>
742
743         Reviewed by Dimitri Glazkov.
744
745         Fix Chromium breakage.
746
747         https://bugs.webkit.org/show_bug.cgi?id=30104
748
749         * inspector/front-end/inspector.js:
750         (WebInspector.addCookieDomain): check that Storage panel is present before calling its methods.
751
752 2009-10-09  Joe Ligman  <joseph.ligman@nokia.com>
753
754         Reviewed by Simon Hausmann.
755
756         [Qt] Added pure virtual methods setInputMethodEnabled and setInputMethodHint to QWebPageClient
757
758         https://bugs.webkit.org/show_bug.cgi?id=30023
759
760         * platform/qt/QWebPageClient.h:
761
762 2009-10-08  Dave Hyatt  <hyatt@apple.com>
763
764         Reviewed by Darin Adler.
765
766         Implement beforeload for images.  ImageLoadEventSender has been refactored into a more generic
767         ImageEventSender that can be used by both load and beforeload events.  If the document has any
768         beforeload listeners, then the installation of images onto the renderer becomes asynchronous
769         and will be held up until the beforeload event can fire at a later date.
770
771         Both beforeload and load events now fire at the end of the tokenizer write() methods, so that
772         in the typical parsing case we don't have to put off the beforeload/load events until after
773         a layout or paint might already have happened.  This lets beforeload/load not cause extra
774         layouts and repaints.
775
776         * dom/ContainerNode.cpp:
777         (WebCore::ContainerNode::dispatchBeforeLoadEvent):
778         * dom/Document.cpp:
779         (WebCore::Document::implicitClose):
780         (WebCore::Document::addListenerTypeIfNeeded):
781         * dom/Document.h:
782         (WebCore::Document::):
783         * dom/XMLTokenizer.cpp:
784         (WebCore::XMLTokenizer::write):
785         * html/HTMLImageElement.cpp:
786         (WebCore::HTMLImageElement::attach):
787         * html/HTMLInputElement.cpp:
788         (WebCore::HTMLInputElement::attach):
789         * html/HTMLTokenizer.cpp:
790         (WebCore::HTMLTokenizer::write):
791         * loader/ImageLoader.cpp:
792         (WebCore::ImageBeforeLoadEventSender::ImageBeforeLoadEventSender):
793         (WebCore::ImageLoadEventSender::ImageLoadEventSender):
794         (WebCore::beforeLoadEventSender):
795         (WebCore::ImageLoader::ImageLoader):
796         (WebCore::ImageLoader::~ImageLoader):
797         (WebCore::ImageLoader::setImage):
798         (WebCore::ImageLoader::setLoadingImage):
799         (WebCore::ImageLoader::updateFromElement):
800         (WebCore::ImageLoader::notifyFinished):
801         (WebCore::ImageLoader::dispatchPendingBeforeLoadEvent):
802         (WebCore::ImageLoader::dispatchPendingEvents):
803         (WebCore::ImageEventSender::ImageEventSender):
804         (WebCore::ImageEventSender::dispatchEventSoon):
805         (WebCore::ImageEventSender::cancelEvent):
806         (WebCore::ImageEventSender::dispatchPendingEvents):
807         (WebCore::ImageEventSender::timerFired):
808         * loader/ImageLoader.h:
809         (WebCore::ImageLoader::haveFiredBeforeLoadEvent):
810         * wml/WMLImageElement.cpp:
811         (WebCore::WMLImageElement::attach):
812
813 2009-10-09  Pavel Feldman  <pfeldman@chromium.org>
814
815         Reviewed by Dimitri Glazkov.
816
817         Web Inspector: Wrap Database into ScriptObject in v8 bindings.
818
819         https://bugs.webkit.org/show_bug.cgi?id=30174
820
821         No tests due to no Script* test infrastructure.
822
823         * bindings/v8/ScriptObjectQuarantine.cpp:
824         (WebCore::getQuarantinedScriptObject):
825
826 2009-10-09  Girish Ramakrishnan  <girish@forwardbias.in>
827
828         Reviewed by Simon Hausmann.
829
830         [Qt] Windowless Plugins : Fix crash when using QWebPage without QWebView.
831         
832         'client' is 0 when we have no view.
833
834         https://bugs.webkit.org/show_bug.cgi?id=30251
835
836         * plugins/qt/PluginViewQt.cpp:
837         (WebCore::PluginView::paint):
838
839 2009-10-09  Girish Ramakrishnan  <girish@forwardbias.in>
840
841         Reviewed by Simon Hausmann.
842
843         [Qt] Plugins : Add missing setCurrentPlugin(0)
844
845         https://bugs.webkit.org/show_bug.cgi?id=30248
846
847         * plugins/qt/PluginViewQt.cpp:
848         (WebCore::PluginView::dispatchNPEvent):
849
850 2009-10-09  Jakub Wieczorek  <faw217@gmail.com>
851
852         Reviewed by Simon Hausmann.
853
854         [Qt] beforeload event does not fire on script elements in XML
855         https://bugs.webkit.org/show_bug.cgi?id=30235
856
857         r49194 was lacking a change to XMLTokenizerQt.cpp, equivalent to the one
858         made in XMLTokenizerLibxml2.cpp.
859
860         * dom/XMLTokenizerQt.cpp:
861         (WebCore::XMLTokenizer::parseEndElement):
862
863 2009-10-09  Zoltan Horvath  <zoltan@webkit.org>
864
865         Reviewed by Darin Adler.
866
867         Allow custom memory allocation control for WebCore's CSSParserValueList
868         https://bugs.webkit.org/show_bug.cgi?id=30249
869
870         Inherits CSSParserValueList class from FastAllocBase because it has 
871         been instantiated by 'new' in WebCore/css/CSSGrammar.y:1271.
872
873         * css/CSSParserValues.h:
874
875 2009-10-09  Girish Ramakrishnan  <girish@forwardbias.in>
876
877         Reviewed by Simon Hausmann.
878
879         [Qt] Windowless Plugins : Create Pixmap only when size changes.
880
881         https://bugs.webkit.org/show_bug.cgi?id=30214
882
883         * plugins/qt/PluginViewQt.cpp:
884         (WebCore::PluginView::updatePluginWidget):
885
886 2009-10-08  Jon Honeycutt  <jhoneycutt@apple.com>
887
888         Remove the WebKitPluginHalterEnabledPreferenceKey in favor of checking
889         for the existence of a PluginHalterDelegate.
890
891         This fixes a leak of WebPluginHalterClients:
892         https://bugs.webkit.org/show_bug.cgi?id=30119.
893
894         Reviewed by Dan Bernstein.
895
896         * WebCore.base.exp:
897         Removed the export of WebCore::Settings::setPluginHalterEnabled().
898
899         * loader/EmptyClients.h:
900         (WebCore::EmptyPluginHalterClient::enabled):
901
902         * page/Page.cpp:
903         (WebCore::Page::Page):
904         Remove initialization of m_pluginHalterClient, which was removed. If a
905         non-null PluginHalterClient was passed, create the PluginHalter, and
906         set its allowed run time.
907
908         * page/Page.h:
909         Removed pluginHalterEnabledStateChanged() and m_pluginHalterClient.
910
911         * page/PluginHalter.cpp:
912         (WebCore::PluginHalter::didStartPlugin):
913         Check whether the PluginHalterClient is enabled.
914         (WebCore::PluginHalter::didStopPlugin):
915         Ditto.
916
917         * page/PluginHalter.h:
918         Made m_client an OwnPtr.
919
920         * page/PluginHalterClient.h:
921         Added a function to return the enabled state.
922
923         * page/Settings.cpp:
924         (WebCore::Settings::Settings):
925         Remove initialization of removed member.
926
927         * page/Settings.h:
928         Removed settings for the enabled state of the PluginHalter; we now use
929         the existence of a WebPluginHalterDelegate to determine whether the
930         PluginHalter is enabled.
931
932 2009-10-08  Adam Barth  <abarth@webkit.org>
933
934         Reviewed by Eric Seidel.
935
936         Move executeScript from FrameLoader to ScriptController
937         https://bugs.webkit.org/show_bug.cgi?id=30200
938
939         These methods have virtually no interaction with FrameLoader.  They
940         really seem like they ought to belong to ScriptController.
941
942         * WebCore.base.exp:
943         * bindings/js/ScheduledAction.cpp:
944         (WebCore::ScheduledAction::execute):
945         * bindings/js/ScriptController.cpp:
946         (WebCore::ScriptController::ScriptController):
947         (WebCore::ScriptController::executeScript):
948         (WebCore::ScriptController::executeIfJavaScriptURL):
949         (WebCore::ScriptController::evaluate):
950         * bindings/js/ScriptController.h:
951         * bindings/v8/ScriptController.cpp:
952         (WebCore::ScriptController::ScriptController):
953         (WebCore::ScriptController::executeScript):
954         (WebCore::ScriptController::executeIfJavaScriptURL):
955         * bindings/v8/ScriptController.h:
956         * dom/XMLTokenizer.cpp:
957         (WebCore::XMLTokenizer::notifyFinished):
958         * dom/XMLTokenizerLibxml2.cpp:
959         (WebCore::XMLTokenizer::endElementNs):
960         * dom/XMLTokenizerQt.cpp:
961         (WebCore::XMLTokenizer::parseEndElement):
962         * html/HTMLTokenizer.cpp:
963         (WebCore::HTMLTokenizer::scriptExecution):
964         * loader/FrameLoader.cpp:
965         (WebCore::FrameLoader::changeLocation):
966         (WebCore::FrameLoader::urlSelected):
967         (WebCore::FrameLoader::requestFrame):
968         (WebCore::FrameLoader::submitForm):
969         (WebCore::FrameLoader::replaceDocument):
970         * loader/FrameLoader.h:
971         * plugins/PluginView.cpp:
972         (WebCore::PluginView::performRequest):
973
974 2009-10-08  Geoffrey Garen  <ggaren@apple.com>
975
976         Windows build fix: added missing #include.
977
978         * ForwardingHeaders/runtime/StructureChain.h: Copied from WebCore/ForwardingHeaders/runtime/PropertyNameArray.h.
979
980 2009-10-08  Brian Weinstein  <bweinstein@apple.com>
981
982         Reviewed by Timothy Hatcher.
983
984         Fixes <https://bugs.webkit.org/show_bug.cgi?id=30237>.
985         DOM Content and Load lines aren't shown if a page is loaded when the inspector is up.
986         
987         Make sure to call update script object if we have an InspectorFrontend to
988         call it on when we get one of the new events.
989
990         * inspector/InspectorController.cpp:
991         (WebCore::InspectorController::mainResourceFiredDOMContentEvent):
992         (WebCore::InspectorController::mainResourceFiredLoadEvent):
993
994 2009-10-08  Geoffrey Garen  <ggaren@apple.com>
995
996         Build fix: updated for removal of Structure::markAggregate().
997
998         * bindings/js/JSDOMGlobalObject.cpp:
999         (WebCore::JSDOMGlobalObject::markChildren):
1000
1001 2009-10-08  Jens Alfke  <snej@chromium.org>
1002
1003         Reviewed by Darin Adler.
1004
1005         Make AtomicString create its StringImpl via create(), not the constructor,
1006         so it gets allocated in a single heap block, saving memory and CPU cycles.
1007         This eliminates two StringImpl constructors, making the remaining ones
1008         unambiguous, so the "AdoptBuffer" parameter is no longer needed.
1009         Added const attribute to UChar* in StringImpl constructor, eliminating the
1010         need for several const_casts in calls to it.
1011         StringImpl also unfriends AtomicString (OMG drama!!!)
1012         https://bugs.webkit.org/show_bug.cgi?id=30141
1013
1014         * platform/text/AtomicString.cpp:
1015         (WebCore::CStringTranslator::translate): Call StringImpl::create().
1016         (WebCore::UCharBufferTranslator::translate): Ditto.
1017         (WebCore::HashAndCharactersTranslator::translate): Ditto.
1018         * platform/text/StringImpl.cpp:
1019         (WebCore::StringImpl::StringImpl): Remove unnecessary AdoptBuffer param.
1020         (WebCore::StringImpl::adopt): Ditto.
1021         (WebCore::StringImpl::createUninitialized): Ditto.
1022         (WebCore::StringImpl::create): Ditto.
1023         (WebCore::StringImpl::crossThreadString): Ditto.
1024         * platform/text/StringImpl.h:
1025         (WebCore::StringImpl::setHash): Used by AtomicString when creating StringImpls.
1026
1027 2009-10-08  Anders Carlsson  <andersca@apple.com>
1028
1029         Reviewed by Sam Weinig.
1030
1031         Remove the shouldLoadMediaElementURL frame loader client function.
1032
1033         * loader/FrameLoader.cpp:
1034         (WebCore::FrameLoader::willLoadMediaElementURL):
1035
1036 2009-10-08  John Gregg  <johnnyg@google.com>
1037
1038         Reviewed by Dimitri Glazkov.
1039
1040         SVGURIReference Build problem for V8.  An additional stale reference to SVGURIReference bindings
1041         which wasn't exposed until a clean build.
1042         https://bugs.webkit.org/show_bug.cgi?id=30217
1043
1044         No new tests, just a build fix.
1045
1046         * bindings/v8/V8Index.cpp:
1047
1048 2009-10-08  Nikolas Zimmermann  <nzimmermann@rim.com>
1049
1050         Not reviewed. Sort XCode project file.
1051
1052         * WebCore.xcodeproj/project.pbxproj:
1053
1054 2009-10-08  Patrick Mueller  <Patrick_Mueller@us.ibm.com>
1055
1056         Reviewed by Timothy Hatcher.
1057
1058         unselectable resources in resource panel
1059         https://bugs.webkit.org/show_bug.cgi?id=30079
1060
1061         manual test added
1062         
1063         Also changed the way DnD for resources in the Resources panel is 
1064         handled.
1065
1066         * inspector/front-end/ResourcesPanel.js:
1067         (WebInspector.ResourceSidebarTreeElement.prototype.onattach):
1068         (WebInspector.ResourceSidebarTreeElement.prototype.ondragstart):
1069         * manual-tests/inspector/duplicate-resource-urls.html: Added.
1070
1071 2009-10-08  Brian Weinstein  <bweinstein@apple.com>
1072
1073         Reviewed by Timothy Hatcher.
1074
1075         Fixes <http://webkit.org/b/30233>
1076         Local Storage and Cookies show Blank Titles on Local Files.
1077
1078         If a local storage or cookies sidebar item has no domain, set the 
1079         title to "Local Files", because that is what it represents.
1080
1081         * English.lproj/localizedStrings.js:
1082         * inspector/front-end/StoragePanel.js:
1083         (WebInspector.DOMStorageSidebarTreeElement.prototype.get mainTitle):
1084         (WebInspector.CookieSidebarTreeElement.prototype.get mainTitle):
1085         (WebInspector.CookieSidebarTreeElement.prototype.set mainTitle):
1086
1087 2009-10-08  Dave Hyatt  <hyatt@apple.com>
1088
1089         Reviewed by Oliver Hunt.
1090
1091         Fix failing media layout tests.  Don't make beforeload block loads of objects that aren't in the
1092         document, since video/audio (and images eventually too) can load when not in the document yet.
1093
1094         * dom/ContainerNode.cpp:
1095         (WebCore::ContainerNode::dispatchBeforeLoadEvent):
1096
1097 2009-10-08  Nikolas Zimmermann  <nzimmermann@rim.com>
1098
1099         Reviewed by Eric Seidel.
1100
1101         Move SVGFitToViewBox ANIMATED_* macros in classes that inherit from it
1102         https://bugs.webkit.org/show_bug.cgi?id=30230
1103
1104         This patch also devirtualizes viewBoxToViewTransform(), is it's superflous.
1105         viewBoxToViewTransform() is now a simple static heper function in SVGFitToViewBox.
1106         As a result, the SVGSVGElement::viewBoxToViewTransform() function now resuses the same logic.
1107
1108         As side-effect this patch fixes svg/custom/linking-a-03-b-transform.svg, the return
1109         statement in SVGSVGElement::viewBoxToViewTransform() was clearly wrong.
1110
1111         * svg/SVGFitToViewBox.cpp:
1112         (WebCore::SVGFitToViewBox::SVGFitToViewBox):
1113         (WebCore::SVGFitToViewBox::viewBoxToViewTransform):
1114         * svg/SVGFitToViewBox.h:
1115         * svg/SVGMarkerElement.cpp:
1116         (WebCore::SVGMarkerElement::SVGMarkerElement):
1117         (WebCore::SVGMarkerElement::viewBoxToViewTransform):
1118         * svg/SVGMarkerElement.h:
1119         * svg/SVGPatternElement.cpp:
1120         (WebCore::SVGPatternElement::SVGPatternElement):
1121         (WebCore::SVGPatternElement::buildPattern):
1122         * svg/SVGPatternElement.h:
1123         * svg/SVGSVGElement.cpp:
1124         (WebCore::SVGSVGElement::SVGSVGElement):
1125         (WebCore::SVGSVGElement::viewBoxToViewTransform):
1126         * svg/SVGSVGElement.h:
1127         * svg/SVGSymbolElement.cpp:
1128         (WebCore::SVGSymbolElement::SVGSymbolElement):
1129         * svg/SVGSymbolElement.h:
1130         * svg/SVGViewElement.cpp:
1131         (WebCore::SVGViewElement::SVGViewElement):
1132         * svg/SVGViewElement.h:
1133         * svg/SVGViewSpec.cpp:
1134         (WebCore::SVGViewSpec::SVGViewSpec):
1135         * svg/SVGViewSpec.h:
1136
1137 2009-10-08  Brian Weinstein  <bweinstein@apple.com>
1138
1139         Reviewed by Jon Honeycutt.
1140
1141         Correct a typo that fixes the resizing of columns in Cookie view when you
1142         resize the Inspector window.
1143
1144         * inspector/front-end/CookieItemsView.js:
1145         (WebInspector.CookieItemsView.prototype.resize):
1146
1147 2009-10-08  Brian Weinstein  <bweinstein@apple.com>
1148
1149         Reviewed by Adam Roben.
1150
1151         Fixes <https://bugs.webkit.org/show_bug.cgi?id=29811>
1152         Text in Inspector's Styles gear menu is invisible.
1153         
1154         Adds a style rule for the option text and hr's in the gear menu,
1155         to prevent them from being transparent.
1156
1157         * inspector/front-end/inspector.css:
1158
1159 2009-10-08  John Gregg  <johnnyg@google.com>
1160
1161         Reviewed by David Levin.
1162
1163         Fix build problem with SVGURIReference in V8.
1164         https://bugs.webkit.org/show_bug.cgi?id=30217
1165
1166         No new tests, just a build fix.
1167
1168         * WebCore.gypi:
1169         * bindings/v8/DerivedSourcesAllInOne.cpp:
1170
1171 2009-10-07  Dave Hyatt  <hyatt@apple.com>
1172
1173         Reviewed by Eric Carlson.
1174
1175         Make beforeload work on <video>/<audio> elements.
1176
1177         Added fast/dom/beforeload/video-before-load.html
1178
1179         * html/HTMLMediaElement.cpp:
1180         (WebCore::HTMLMediaElement::parseMappedAttribute):
1181         (WebCore::HTMLMediaElement::selectMediaResource):
1182         (WebCore::HTMLMediaElement::selectNextSourceChild):
1183
1184 2009-10-08  Nikolas Zimmermann  <nzimmermann@rim.com>
1185
1186         Reviewed by Eric Seidel.
1187
1188         Move SVGExternalResourcesRequired ANIMATED_* macros in classes that inherit from it
1189         https://bugs.webkit.org/show_bug.cgi?id=30218
1190
1191         The long term goal is to kill the need for the virtual contextElement() function in SVG code. 
1192         No change in functionality, thus no new tests.
1193
1194         * svg/SVGAElement.cpp:
1195         (WebCore::SVGAElement::SVGAElement):
1196         * svg/SVGAElement.h:
1197         * svg/SVGAnimationElement.cpp:
1198         (WebCore::SVGAnimationElement::SVGAnimationElement):
1199         * svg/SVGAnimationElement.h:
1200         * svg/SVGCircleElement.cpp:
1201         (WebCore::SVGCircleElement::SVGCircleElement):
1202         * svg/SVGCircleElement.h:
1203         * svg/SVGClipPathElement.cpp:
1204         (WebCore::SVGClipPathElement::SVGClipPathElement):
1205         * svg/SVGClipPathElement.h:
1206         * svg/SVGCursorElement.cpp:
1207         (WebCore::SVGCursorElement::SVGCursorElement):
1208         * svg/SVGCursorElement.h:
1209         * svg/SVGDefsElement.cpp:
1210         (WebCore::SVGDefsElement::SVGDefsElement):
1211         * svg/SVGDefsElement.h:
1212         * svg/SVGEllipseElement.cpp:
1213         (WebCore::SVGEllipseElement::SVGEllipseElement):
1214         * svg/SVGEllipseElement.h:
1215         * svg/SVGExternalResourcesRequired.cpp:
1216         (WebCore::SVGExternalResourcesRequired::SVGExternalResourcesRequired):
1217         * svg/SVGExternalResourcesRequired.h:
1218         * svg/SVGFEImageElement.cpp:
1219         (WebCore::SVGFEImageElement::SVGFEImageElement):
1220         * svg/SVGFEImageElement.h:
1221         * svg/SVGFilterElement.cpp:
1222         (WebCore::SVGFilterElement::SVGFilterElement):
1223         * svg/SVGFilterElement.h:
1224         * svg/SVGFontElement.cpp:
1225         (WebCore::SVGFontElement::SVGFontElement):
1226         * svg/SVGFontElement.h:
1227         * svg/SVGForeignObjectElement.cpp:
1228         (WebCore::SVGForeignObjectElement::SVGForeignObjectElement):
1229         * svg/SVGForeignObjectElement.h:
1230         * svg/SVGGElement.cpp:
1231         (WebCore::SVGGElement::SVGGElement):
1232         * svg/SVGGElement.h:
1233         * svg/SVGGradientElement.cpp:
1234         (WebCore::SVGGradientElement::SVGGradientElement):
1235         * svg/SVGGradientElement.h:
1236         * svg/SVGImageElement.cpp:
1237         (WebCore::SVGImageElement::SVGImageElement):
1238         * svg/SVGImageElement.h:
1239         * svg/SVGLineElement.cpp:
1240         (WebCore::SVGLineElement::SVGLineElement):
1241         * svg/SVGLineElement.h:
1242         * svg/SVGMPathElement.cpp:
1243         (WebCore::SVGMPathElement::SVGMPathElement):
1244         * svg/SVGMPathElement.h:
1245         * svg/SVGMarkerElement.cpp:
1246         (WebCore::SVGMarkerElement::SVGMarkerElement):
1247         * svg/SVGMarkerElement.h:
1248         * svg/SVGMaskElement.cpp:
1249         (WebCore::SVGMaskElement::SVGMaskElement):
1250         * svg/SVGMaskElement.h:
1251         * svg/SVGPathElement.cpp:
1252         (WebCore::SVGPathElement::SVGPathElement):
1253         * svg/SVGPathElement.h:
1254         * svg/SVGPatternElement.cpp:
1255         (WebCore::SVGPatternElement::SVGPatternElement):
1256         * svg/SVGPatternElement.h:
1257         * svg/SVGPolyElement.cpp:
1258         (WebCore::SVGPolyElement::SVGPolyElement):
1259         * svg/SVGPolyElement.h:
1260         * svg/SVGRectElement.cpp:
1261         (WebCore::SVGRectElement::SVGRectElement):
1262         * svg/SVGRectElement.h:
1263         * svg/SVGSVGElement.cpp:
1264         (WebCore::SVGSVGElement::SVGSVGElement):
1265         * svg/SVGSVGElement.h:
1266         * svg/SVGScriptElement.cpp:
1267         (WebCore::SVGScriptElement::SVGScriptElement):
1268         * svg/SVGScriptElement.h:
1269         * svg/SVGSwitchElement.cpp:
1270         (WebCore::SVGSwitchElement::SVGSwitchElement):
1271         * svg/SVGSwitchElement.h:
1272         * svg/SVGSymbolElement.cpp:
1273         (WebCore::SVGSymbolElement::SVGSymbolElement):
1274         * svg/SVGSymbolElement.h:
1275         * svg/SVGTextContentElement.cpp:
1276         (WebCore::SVGTextContentElement::SVGTextContentElement):
1277         * svg/SVGTextContentElement.h:
1278         * svg/SVGUseElement.cpp:
1279         (WebCore::SVGUseElement::SVGUseElement):
1280         * svg/SVGUseElement.h:
1281         * svg/SVGViewElement.cpp:
1282         (WebCore::SVGViewElement::SVGViewElement):
1283         * svg/SVGViewElement.h:
1284
1285 2009-10-08  Dirk Schulze  <krit@webkit.org>
1286
1287         Reviewed by Darin Adler.
1288
1289         SVG feComposite: operator over mixes up inputs
1290         [https://bugs.webkit.org/show_bug.cgi?id=30205]
1291
1292         SVG feComposite operator over mixed up the inputs.
1293         The pixel-test svg/filters/feComposite.svg can already test this.
1294         No new test result is needed as long as filters are disabled.
1295
1296         * platform/graphics/filters/FEComposite.cpp:
1297         (WebCore::FEComposite::apply):
1298
1299 2009-10-08  Nikolas Zimmermann  <nzimmermann@rim.com>
1300
1301         Reviewed by George Staikos.
1302
1303         Move SVGURIReference ANIMATED_* macros in classes that inherit from it
1304         https://bugs.webkit.org/show_bug.cgi?id=30184
1305
1306         The long term goal is to kill the need for the virtual contextElement() function in SVG code. 
1307         No change in functionality, thus no new tests.
1308
1309         * svg/SVGAElement.cpp:
1310         (WebCore::SVGAElement::SVGAElement):
1311         * svg/SVGAElement.h:
1312         * svg/SVGAltGlyphElement.cpp:
1313         (WebCore::SVGAltGlyphElement::SVGAltGlyphElement):
1314         * svg/SVGAltGlyphElement.h:
1315         * svg/SVGCursorElement.cpp:
1316         (WebCore::SVGCursorElement::SVGCursorElement):
1317         * svg/SVGCursorElement.h:
1318         * svg/SVGFEImageElement.cpp:
1319         (WebCore::SVGFEImageElement::SVGFEImageElement):
1320         * svg/SVGFEImageElement.h:
1321         * svg/SVGFilterElement.cpp:
1322         (WebCore::SVGFilterElement::SVGFilterElement):
1323         * svg/SVGFilterElement.h:
1324         * svg/SVGForeignObjectElement.cpp:
1325         (WebCore::SVGForeignObjectElement::SVGForeignObjectElement):
1326         * svg/SVGForeignObjectElement.h:
1327         * svg/SVGGradientElement.cpp:
1328         (WebCore::SVGGradientElement::SVGGradientElement):
1329         * svg/SVGGradientElement.h:
1330         * svg/SVGImageElement.cpp:
1331         (WebCore::SVGImageElement::SVGImageElement):
1332         * svg/SVGImageElement.h:
1333         * svg/SVGMPathElement.cpp:
1334         (WebCore::SVGMPathElement::SVGMPathElement):
1335         (WebCore::SVGMPathElement::pathElement):
1336         * svg/SVGMPathElement.h:
1337         * svg/SVGMaskElement.cpp:
1338         (WebCore::SVGMaskElement::SVGMaskElement):
1339         * svg/SVGMaskElement.h:
1340         * svg/SVGPatternElement.cpp:
1341         (WebCore::SVGPatternElement::SVGPatternElement):
1342         * svg/SVGPatternElement.h:
1343         * svg/SVGScriptElement.cpp:
1344         (WebCore::SVGScriptElement::SVGScriptElement):
1345         * svg/SVGScriptElement.h:
1346         * svg/SVGTRefElement.cpp:
1347         (WebCore::SVGTRefElement::SVGTRefElement):
1348         * svg/SVGTRefElement.h:
1349         * svg/SVGTextPathElement.cpp:
1350         (WebCore::SVGTextPathElement::SVGTextPathElement):
1351         * svg/SVGTextPathElement.h:
1352         * svg/SVGURIReference.cpp:
1353         (WebCore::SVGURIReference::SVGURIReference):
1354         * svg/SVGURIReference.h:
1355         * svg/SVGUseElement.cpp:
1356         (WebCore::SVGUseElement::SVGUseElement):
1357         * svg/SVGUseElement.h:
1358
1359 2009-10-08  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
1360
1361         Reviewed by Simon Hausmann.
1362
1363         [Qt] Re-add the QApplication::syncX() line for plugin windows removed
1364         by r49169. Also changed the location of the sync just after the
1365         creation instead of just before sending it to the plugin.
1366         https://bugs.webkit.org/show_bug.cgi?id=25053
1367
1368         * plugins/qt/PluginViewQt.cpp:
1369         (WebCore::PluginView::platformStart):
1370
1371 2009-10-08  Joseph Pecoraro  <joepeck@webkit.org>
1372
1373         Reviewed by Timothy Hatcher.
1374
1375         Inspector: NodeLists Don't Display Well in the Console
1376         https://bugs.webkit.org/show_bug.cgi?id=28061
1377
1378         * inspector/front-end/InjectedScript.js:
1379         (Object.type):
1380
1381 2009-10-08  Girish Ramakrishnan  <girish@forwardbias.in>
1382
1383         Reviewed by Simon Hausmann.
1384
1385         [Qt] Windowless plugins: Remove unnecessary XSync for opaque mode.
1386         
1387         The reason for the XSync was that the plugin would not know about the
1388         Drawable. It turns out that the real reason behind this is that even
1389         though XCreatePixmap returns a handle, this id is unknown to the server
1390         until we flush the connection.
1391         
1392         So, move the XSync to right after we create the Pixmap.
1393
1394         https://bugs.webkit.org/show_bug.cgi?id=30207
1395
1396         * plugins/qt/PluginViewQt.cpp:
1397         (WebCore::PluginView::updatePluginWidget):
1398         (WebCore::PluginView::paint):
1399
1400 2009-10-07  Daniel Bates  <dbates@webkit.org>
1401
1402         Reviewed by Eric Seidel.
1403
1404         https://bugs.webkit.org/show_bug.cgi?id=30188
1405         
1406         Fixes an issue where performing a non DHTML drag-and-drop operation 
1407         does not work as expected. For instance, dragging some selected text 
1408         to an external application, such as TextEdit.
1409         
1410         This issue was a regression that arose from patching bug #30107.
1411         
1412         This change is covered by the manual test: 
1413         drag-out-of-background-window.html
1414
1415         * page/DragController.cpp:
1416         (WebCore::DragController::startDrag): When performing a non-DHTML drag 
1417         operation then default to drag operations DragOperationGeneric and 
1418         DragOperationCopy according to similar functionality removed when fixing
1419         bug #30107, see: 
1420         http://trac.webkit.org/browser/trunk/WebKit/mac/WebView/WebHTMLView.mm?rev=48526#L3430 
1421
1422 2009-10-07  Xan Lopez  <xlopez@igalia.com>
1423
1424         Fix more breakage in the GTK+ build.
1425
1426         * GNUmakefile.am:
1427
1428 2009-10-07  Adam Barth  <abarth@webkit.org>
1429
1430         Reviewed by Eric Seidel.
1431
1432         Move PolicyChecker to it's own file
1433         https://bugs.webkit.org/show_bug.cgi?id=30193
1434
1435         This is just moving code around and re-naming things.
1436
1437         * GNUmakefile.am:
1438         * WebCore.gypi:
1439         * WebCore.pro:
1440         * WebCore.vcproj/WebCore.vcproj:
1441         * WebCore.xcodeproj/project.pbxproj:
1442         * loader/FrameLoader.cpp:
1443         * loader/FrameLoader.h:
1444         * loader/PolicyCallback.cpp: Added.
1445         (WebCore::PolicyCallback::PolicyCallback):
1446         (WebCore::PolicyCallback::~PolicyCallback):
1447         (WebCore::PolicyCallback::clear):
1448         (WebCore::PolicyCallback::set):
1449         (WebCore::PolicyCallback::call):
1450         (WebCore::PolicyCallback::clearRequest):
1451         (WebCore::PolicyCallback::cancel):
1452         * loader/PolicyCallback.h: Added.
1453         (WebCore::PolicyCallback::request):
1454         * loader/PolicyCheck.cpp: Removed.
1455         * loader/PolicyCheck.h: Removed.
1456
1457 2009-10-07  Joel Stanley  <joel@jms.id.au>
1458
1459         Reviewed by Mark Rowe.
1460
1461         Include <limits> for std::numeric_limits.  Required by gcc-4.4
1462         https://bugs.webkit.org/show_bug.cgi?id=30197
1463
1464         * html/canvas/CanvasByteArray.h:
1465         * html/canvas/CanvasIntArray.h:
1466         * html/canvas/CanvasShortArray.h:
1467         * html/canvas/CanvasUnsignedByteArray.h:
1468         * html/canvas/CanvasUnsignedIntArray.h:
1469         * html/canvas/CanvasUnsignedShortArray.h:
1470
1471 2009-10-07  Adam Barth  <abarth@webkit.org>
1472
1473         Reviewed by Darin Adler.
1474
1475         Factor PolicyChecker out of FrameLoader
1476         https://bugs.webkit.org/show_bug.cgi?id=30155
1477
1478         This patch separates PolicyChecker from FrameLoader.  Loader policy is
1479         in change of managing the FrameLoaderClient callbacks.  Ideally, it
1480         shouldn't know anything about FrameLoader, but I couldn't quite remove
1481         all knowledge (although we might be able to do more later).  In a
1482         future patch, I'll move PolicyChecker into a separate file.
1483
1484         * loader/FrameLoader.cpp:
1485         (WebCore::FrameLoader::FrameLoader):
1486         (WebCore::FrameLoader::loadURL):
1487         (WebCore::FrameLoader::load):
1488         (WebCore::FrameLoader::loadWithDocumentLoader):
1489         (WebCore::PolicyChecker::handleUnimplementablePolicy):
1490         (WebCore::PolicyChecker::cannotShowMIMEType):
1491         (WebCore::PolicyChecker::PolicyChecker):
1492         (WebCore::PolicyChecker::checkNavigationPolicy):
1493         (WebCore::PolicyChecker::checkContentPolicy):
1494         (WebCore::FrameLoader::shouldReloadToHandleUnreachableURL):
1495         (WebCore::FrameLoader::stopAllLoaders):
1496         (WebCore::PolicyChecker::cancelCheck):
1497         (WebCore::PolicyChecker::stopCheck):
1498         (WebCore::PolicyChecker::continueAfterContentPolicy):
1499         (WebCore::PolicyChecker::continueLoadAfterWillSubmitForm):
1500         (WebCore::FrameLoader::continueLoadAfterWillSubmitForm):
1501         (WebCore::FrameLoader::loadPostRequest):
1502         (WebCore::FrameLoader::continueFragmentScrollAfterNavigationPolicy):
1503         (WebCore::PolicyChecker::checkNewWindowPolicy):
1504         (WebCore::PolicyChecker::continueAfterNewWindowPolicy):
1505         (WebCore::PolicyChecker::continueAfterNavigationPolicy):
1506         (WebCore::FrameLoader::continueLoadAfterNavigationPolicy):
1507         * loader/FrameLoader.h:
1508         (WebCore::PolicyChecker::loadType):
1509         (WebCore::PolicyChecker::setLoadType):
1510         (WebCore::PolicyChecker::delegateIsDecidingNavigationPolicy):
1511         (WebCore::PolicyChecker::delegateIsHandlingUnimplementablePolicy):
1512         (WebCore::FrameLoader::policy):
1513         * loader/FrameLoaderClient.h:
1514         * loader/MainResourceLoader.cpp:
1515         (WebCore::MainResourceLoader::didCancel):
1516         (WebCore::MainResourceLoader::willSendRequest):
1517         (WebCore::MainResourceLoader::continueAfterContentPolicy):
1518         (WebCore::MainResourceLoader::didReceiveResponse):
1519         * svg/graphics/SVGImage.cpp:
1520         (WebCore::SVGImage::dataChanged):
1521
1522 2009-10-07  Geoffrey Garen  <ggaren@apple.com>
1523
1524         Reviewed by Oliver Hunt.
1525
1526         Fixed <rdar://problem/5751979> Database code takes JSLock on secondary
1527         thread, permanently slowing down JavaScript
1528
1529         Changed callback objects to use a standard helper object. The helper
1530         object ASSERTs that it is deleted on the main thread, so no lock is
1531         required when unprotecting its members. It also centralizes some previously
1532         duplicated code.
1533         
1534         Callback objects that might be deleted on a secondary thread use
1535         callOnMainThread to delete their helper objects on the main thread.
1536
1537         * WebCore.xcodeproj/project.pbxproj:
1538         * bindings/js/JSCallbackData.cpp: Copied from bindings/js/JSCustomSQLTransactionCallback.cpp.
1539         (WebCore::JSCallbackData::deleteData):
1540         (WebCore::JSCallbackData::invokeCallback):
1541         * bindings/js/JSCallbackData.h: Copied from bindings/js/JSCustomSQLTransactionCallback.cpp.
1542         (WebCore::JSCallbackData::JSCallbackData):
1543         (WebCore::JSCallbackData::~JSCallbackData):
1544         (WebCore::JSCallbackData::callback):
1545         * bindings/js/JSCustomPositionCallback.cpp:
1546         (WebCore::JSCustomPositionCallback::JSCustomPositionCallback):
1547         (WebCore::JSCustomPositionCallback::handleEvent):
1548         * bindings/js/JSCustomPositionCallback.h:
1549         * bindings/js/JSCustomPositionErrorCallback.cpp:
1550         (WebCore::JSCustomPositionErrorCallback::JSCustomPositionErrorCallback):
1551         (WebCore::JSCustomPositionErrorCallback::handleEvent):
1552         * bindings/js/JSCustomPositionErrorCallback.h:
1553         * bindings/js/JSCustomSQLStatementCallback.cpp:
1554         (WebCore::JSCustomSQLStatementCallback::JSCustomSQLStatementCallback):
1555         (WebCore::JSCustomSQLStatementCallback::~JSCustomSQLStatementCallback):
1556         (WebCore::JSCustomSQLStatementCallback::handleEvent):
1557         * bindings/js/JSCustomSQLStatementCallback.h:
1558         * bindings/js/JSCustomSQLStatementErrorCallback.cpp:
1559         (WebCore::JSCustomSQLStatementErrorCallback::JSCustomSQLStatementErrorCallback):
1560         (WebCore::JSCustomSQLStatementErrorCallback::~JSCustomSQLStatementErrorCallback):
1561         (WebCore::JSCustomSQLStatementErrorCallback::handleEvent):
1562         * bindings/js/JSCustomSQLStatementErrorCallback.h:
1563         * bindings/js/JSCustomSQLTransactionCallback.cpp:
1564         (WebCore::JSCustomSQLTransactionCallback::JSCustomSQLTransactionCallback):
1565         (WebCore::JSCustomSQLTransactionCallback::~JSCustomSQLTransactionCallback):
1566         (WebCore::JSCustomSQLTransactionCallback::handleEvent):
1567         * bindings/js/JSCustomSQLTransactionCallback.h:
1568         * bindings/js/JSCustomSQLTransactionErrorCallback.cpp:
1569         (WebCore::JSCustomSQLTransactionErrorCallback::JSCustomSQLTransactionErrorCallback):
1570         (WebCore::JSCustomSQLTransactionErrorCallback::~JSCustomSQLTransactionErrorCallback):
1571         (WebCore::JSCustomSQLTransactionErrorCallback::handleEvent):
1572         * bindings/js/JSCustomSQLTransactionErrorCallback.h:
1573         * bindings/js/JSCustomVoidCallback.cpp:
1574         (WebCore::JSCustomVoidCallback::JSCustomVoidCallback):
1575         (WebCore::JSCustomVoidCallback::~JSCustomVoidCallback):
1576         (WebCore::JSCustomVoidCallback::handleEvent):
1577         * bindings/js/JSCustomVoidCallback.h:
1578         * storage/Database.cpp:
1579         (WebCore::Database::Database):
1580
1581 2009-10-07  Jens Alfke  <snej@chromium.org>
1582
1583         Reviewed by Dave Levin.
1584
1585         Fix StringImpl::m_buffer
1586         https://bugs.webkit.org/show_bug.cgi?id=30189
1587
1588         Fix my previous StringImpl patch to avoid using an indefinite-length array member,
1589         since MSVC doesn't like it. Instead, go back to offsetting by sizeof(StringImpl).
1590
1591         * platform/text/StringImpl.cpp:
1592         (WebCore::StringImpl::StringImpl):
1593         (WebCore::StringImpl::createUninitialized):
1594         * platform/text/StringImpl.h:
1595         (WebCore::StringImpl::bufferIsInternal):
1596
1597 2009-10-07  Aaron Boodman  <aa@chromium.org>
1598
1599         Reviewed by Adam Barth.
1600
1601         Update isolated worlds under v8 to support world reuse.
1602         https://bugs.webkit.org/show_bug.cgi?id=30145
1603
1604         * bindings/v8/ScriptController.cpp:
1605         Replace evaluateInNewIsolatedWorld() withe evaluateInIsolatedWorld(id).
1606         (WebCore::ScriptController::evaluateInIsolatedWorld):
1607         * bindings/v8/ScriptController.h: Ditto.
1608         * bindings/v8/V8Proxy.cpp: Ditto.
1609         (WebCore::V8Proxy::~V8Proxy): Dittio.
1610         (WebCore::V8Proxy::evaluateInIsolatedWorld): Ditto.
1611         * bindings/v8/V8Proxy.h: Ditto.
1612         * bindings/v8/V8IsolatedWorld.cpp:
1613         Add support for controlling lifetime of a world, rather than relying on GC.
1614         (WebCore::V8IsolatedWorld::contextWeakReferenceCallback): Ditto.
1615         (WebCore::V8IsolatedWorld::V8IsolatedWorld): Ditto.
1616         (WebCore::V8IsolatedWorld::destroy): Ditto.
1617         * bindings/v8/V8IsolatedWorld.h: Ditto.
1618
1619 2009-10-07  Jeremy Orlow  <jorlow@chromium.org>
1620
1621         Build fix for http://trac.webkit.org/changeset/49272 on Windows
1622
1623         * platform/text/StringImpl.h:
1624
1625 2009-10-07  Jens Alfke  <snej@chromium.org>
1626
1627         Reviewed by Darin Adler.
1628
1629         Optimization of StringImpl:
1630         - Remove unnecessary m_bufferIsInternal member (saves 4 bytes). Instead, check whether
1631           m_data points to just past the end of the object's members.
1632         - copy() and createWithTerminatingNullCharacter() create the string in a single malloc
1633           block instead of 2 (saves ~20 bytes and considerable CPU cycles, increases locality).
1634         - Move m_length next to m_hash to save 4 bytes of padding in 64-bit builds.
1635           
1636         https://bugs.webkit.org/show_bug.cgi?id=29500
1637
1638         * platform/text/StringImpl.cpp:
1639         (WebCore::StringImpl::StringImpl): Re-ordered members.
1640         (WebCore::StringImpl::~StringImpl): Change to is-buffer-internal check.
1641         (WebCore::StringImpl::createUninitialized): Use new m_buffer member instead of sizeof()
1642             to ensure chars are copied to correct location.
1643         (WebCore::StringImpl::createWithTerminatingNullCharacter): Make sure copy is created
1644             in a single malloc block.
1645         (WebCore::StringImpl::threadsafeCopy): Make sure copy is created in a single malloc block.
1646         (WebCore::StringImpl::crossThreadString): Make sure copy is created in a single malloc block.
1647         (WebCore::StringImpl::sharedBuffer): Change to is-buffer-internal check.
1648         * platform/text/StringImpl.h:
1649         (WebCore::StringImpl::startsWith): Just fixed a confusing param name.
1650         (WebCore::StringImpl::bufferIsInternal): Changed member var into accessor method.
1651         (WebCore::StringImpl::m_data): Repositioned for optimal member packing in 64-bit.
1652         (WebCore::StringImpl::m_buffer): Added to provide an explicit location for where internal buffer goes.
1653
1654 2009-10-07  Daniel Bates  <dbates@webkit.org>
1655
1656         Reviewed by Darin Adler.
1657
1658         https://bugs.webkit.org/show_bug.cgi?id=30102
1659         And
1660         <rdar://problem/5015957>
1661         
1662         Manual test to confirm that the not-allowed cursor is shown for an
1663         invalid drag-and-drop operation.
1664         
1665         We cannot test this using DRT because of a discrepancy between the Windows
1666         API-based drop effect and the WebKit drop effect. See bug #24731 for more
1667         details.
1668
1669         * manual-tests/drag-cursor-notallowed.html: Added.
1670
1671 2009-10-07  Mark Rowe  <mrowe@apple.com>
1672
1673         Fix the build.
1674
1675         * WebCore.xcodeproj/project.pbxproj:
1676
1677 2009-10-07  Brian Weinstein  <bweinstein@apple.com>
1678
1679         Reviewed by Timothy Hatcher.
1680
1681         Fixes <http://webkit.org/b/30104>.
1682         Inspector should show cookies of sub-resources on the page.
1683         
1684         This function implements showing cookies for all sub-resources of a page.
1685         When the page is loaded, it populates the Storage Panel with a list of all
1686         domains that were loaded as part of the full page load (iframes, ads, etc).
1687         When the user selects one of the domains, the inspector calls back into the
1688         controller, and the controller combines all of the cookies from that domain
1689         into a list, and sends that list is sent back to the controller to render.
1690         
1691         A domain now needs to be passed into CookieItemsView, and CookieSidebarTreeElement.
1692         
1693         As a result of a previous patch, we now have detailed cookie information for
1694         both Windows on CFNetwork and Mac. Additionally, this patch provides deleteCookie
1695         support on Windows.
1696
1697         * bindings/js/ScriptObject.cpp:
1698         (WebCore::ScriptObject::set):
1699         * bindings/js/ScriptObject.h:
1700         * inspector/InspectorBackend.cpp:
1701         (WebCore::InspectorBackend::getCookies):
1702         (WebCore::InspectorBackend::deleteCookie):
1703         * inspector/InspectorBackend.h:
1704         * inspector/InspectorBackend.idl:
1705         * inspector/InspectorController.cpp:
1706         (WebCore::InspectorController::populateScriptObjects):
1707         (WebCore::InspectorController::didFinishLoading):
1708         (WebCore::InspectorController::getCookies):
1709         (WebCore::InspectorController::buildArrayForCookies):
1710         (WebCore::InspectorController::buildObjectForCookie):
1711         (WebCore::InspectorController::deleteCookie):
1712         * inspector/InspectorController.h:
1713         * inspector/InspectorDOMAgent.cpp:
1714         * inspector/InspectorDOMAgent.h:
1715         * inspector/InspectorFrontend.cpp:
1716         (WebCore::InspectorFrontend::addCookieDomainForDocument):
1717         * inspector/InspectorFrontend.h:
1718         * inspector/front-end/CookieItemsView.js:
1719         (WebInspector.CookieItemsView):
1720         (WebInspector.CookieItemsView.prototype.update):
1721         (WebInspector.CookieItemsView.prototype._deleteButtonClicked):
1722         * inspector/front-end/DOMAgent.js:
1723         (WebInspector.Cookies.getCookiesAsync):
1724         * inspector/front-end/StoragePanel.js:
1725         (WebInspector.StoragePanel):
1726         (WebInspector.StoragePanel.prototype.reset):
1727         (WebInspector.StoragePanel.prototype.addCookieDomain):
1728         (WebInspector.StoragePanel.prototype.showCookies):
1729         (WebInspector.CookieSidebarTreeElement):
1730         (WebInspector.CookieSidebarTreeElement.prototype.onselect):
1731         * inspector/front-end/inspector.js:
1732         (WebInspector.addCookieDomain):
1733         * platform/Cookie.h:
1734         (WebCore::CookieHash::hash):
1735         (WebCore::CookieHash::equal):
1736         (WTF::):
1737         * platform/network/win/CookieJarCFNetWin.cpp:
1738         (WebCore::deleteCookie):
1739
1740 2009-10-07  Pavel Feldman  <pfeldman@chromium.org>
1741
1742         Reviewed by Timothy Hatcher.
1743
1744         Web Inspector: Add ScriptObject::set(const char*, unsigned).
1745
1746         https://bugs.webkit.org/show_bug.cgi?id=30104
1747
1748         * bindings/v8/ScriptObject.cpp:
1749         (WebCore::ScriptObject::set):
1750         * bindings/v8/ScriptObject.h:
1751
1752 2009-10-07  Brent Fulgham  <bfulgham@webkit.org>
1753
1754         Unreviewed build fix for Windows (Cairo).
1755
1756         Provide implementation of new BitmapImage::create that was
1757         added in @r49060.
1758
1759         * platform/graphics/win/ImageCairoWin.cpp:
1760
1761 2009-10-07  Andrew Scherkus  <scherkus@chromium.org>
1762
1763         Reviewed by Eric Carlson.
1764
1765         Refactor RenderThemeChromiumMac and RenderThemeChromiumSkia to render media controls using GraphicsContext.
1766
1767         Design was based on existing RenderMediaControls.cpp used by RenderThemeSafari/Win.
1768
1769         https://bugs.webkit.org/show_bug.cgi?id=29987
1770
1771         Covered by existing layout tests as no new functionality was introduced.
1772
1773         * WebCore.gypi: Added RenderMediaControlsChromium.cpp/h.
1774         * css/mediaControlsChromium.css: Tweaked media slider position and border style.
1775         * rendering/MediaControlElements.cpp:
1776         (WebCore::toParentMediaElement): Taken from RenderMediaControls.
1777         (WebCore::MediaControlElement::rendererIsNeeded): Don't call shouldRenderMediaControlPart() if element has no appearance.
1778         (WebCore::MediaControlInputElement::rendererIsNeeded): Ditto.
1779         * rendering/RenderMediaControls.cpp: Moved parentMediaElement() to MediaControlElements.
1780         * rendering/RenderMediaControlsChromium.cpp: Added.
1781         (WebCore::platformResource): Helper to load and cache media control image resources.
1782         (WebCore::mediaSliderThumbImage): Implementation refactored from RenderThemeChromiumMac/Skia.
1783         (WebCore::mediaVolumeSliderThumbImage): Ditto.
1784         (WebCore::paintMediaButton): Ditto.
1785         (WebCore::paintMediaMuteButton): Ditto.
1786         (WebCore::paintMediaPlayButton): Ditto.
1787         (WebCore::paintMediaSlider): Ditto.
1788         (WebCore::paintMediaSliderThumb): Ditto.
1789         (WebCore::paintMediaVolumeSlider): Ditto.
1790         (WebCore::paintMediaVolumeSliderThumb): Ditto.
1791         (WebCore::paintMediaTimelineContainer): Ditto.
1792         (WebCore::RenderMediaControlsChromium::shouldRenderMediaControlPart): Ditto.
1793         (WebCore::RenderMediaControlsChromium::paintMediaControlsPart): Same
1794         (WebCore::RenderMediaControlsChromium::adjustMediaSliderThumbSize):
1795         * rendering/RenderMediaControlsChromium.h: Added.
1796         * rendering/RenderThemeChromiumMac.h:
1797         * rendering/RenderThemeChromiumMac.mm:
1798         (WebCore::RenderThemeChromiumMac::adjustSliderThumbSize): Implementation delegated to RenderMediaControlsChromium.
1799         (WebCore::RenderThemeChromiumMac::shouldRenderMediaControlPart): Ditto.
1800         (WebCore::RenderThemeChromiumMac::paintMediaPlayButton): Ditto.
1801         (WebCore::RenderThemeChromiumMac::paintMediaMuteButton): Ditto.
1802         (WebCore::RenderThemeChromiumMac::paintMediaSliderTrack): Ditto.
1803         (WebCore::RenderThemeChromiumMac::paintMediaVolumeSliderTrack): Ditto.
1804         (WebCore::RenderThemeChromiumMac::paintMediaSliderThumb): Ditto.
1805         (WebCore::RenderThemeChromiumMac::paintMediaVolumeSliderThumb): Ditto.
1806         (WebCore::RenderThemeChromiumMac::paintMediaControlsBackground): Ditto.
1807         * rendering/RenderThemeChromiumSkia.cpp:
1808         (WebCore::RenderThemeChromiumSkia::paintMediaControlsBackground): Implementation delegated to RenderMediaControlsChromium.
1809         (WebCore::RenderThemeChromiumSkia::paintMediaSliderTrack): Ditto.
1810         (WebCore::RenderThemeChromiumSkia::paintMediaVolumeSliderTrack): Ditto.
1811         (WebCore::RenderThemeChromiumSkia::adjustSliderThumbSize): Ditto.
1812         (WebCore::RenderThemeChromiumSkia::paintMediaSliderThumb): Ditto.
1813         (WebCore::RenderThemeChromiumSkia::paintMediaVolumeSliderThumb): Ditto.
1814         (WebCore::RenderThemeChromiumSkia::paintMediaPlayButton): Ditto.
1815         (WebCore::RenderThemeChromiumSkia::paintMediaMuteButton): Ditto.
1816         (WebCore::RenderThemeChromiumSkia::shouldRenderMediaControlPart): Ditto.
1817
1818 2009-10-07  Dave Hyatt  <hyatt@apple.com>
1819
1820         Reviewed by Adam Roben.
1821
1822         Make plugins work with beforeload.
1823
1824         Added fast/dom/beforeload/flash-before-load.html
1825
1826         * html/HTMLObjectElement.cpp:
1827         (WebCore::HTMLObjectElement::parseMappedAttribute):
1828         * rendering/RenderPartObject.cpp:
1829         (WebCore::RenderPartObject::updateWidget):
1830
1831 2009-10-07  Vitaly Repeshko  <vitalyr@chromium.org>
1832
1833         Reviewed by Adam Barth.
1834
1835         [V8] Protect JS listener object from GC while clearing a property on it.
1836         See http://crbug.com/23780.
1837         https://bugs.webkit.org/show_bug.cgi?id=30137
1838
1839         * bindings/v8/V8AbstractEventListener.cpp:
1840         (WebCore::V8AbstractEventListener::~V8AbstractEventListener):
1841
1842 2009-10-07  Zoltan Horvath  <zoltan@webkit.org>
1843
1844         Rubber-stamped by Eric Seidel.
1845
1846         Allow custom memory allocation control for WebCore's CachedResourceClient class
1847         https://bugs.webkit.org/show_bug.cgi?id=30165
1848
1849         Inherits CachedResourceClient class from FastAllocBase because (its
1850         child class) CSSFontFaceSource has been instantiated by 'new' in WebCore/css/CSSFontFaceSource.h:46.
1851
1852         * loader/CachedResourceClient.h:
1853
1854 2009-10-07  Zoltan Horvath  <zoltan@webkit.org>
1855
1856         Reviewed by Darin Adler.
1857
1858         Allow custom memory allocation control for WebCore's IdentifierRep 
1859         https://bugs.webkit.org/show_bug.cgi?id=30159                                                        
1860
1861         Inherits IdentifierRep class from FastAllocBase because it has been                                 
1862         instantiated by 'new' in WebCore/bridge/IdentifierRep.cpp:61.  
1863
1864         * bridge/IdentifierRep.h:
1865
1866 2009-10-07  Anton Muhin  <antonm@chromium.org>
1867
1868         Reviewed by Adam Barth.
1869
1870         Fetch pointers to C++ DOM window immediately from holder
1871         object (do not search prototype chain for proper JS wrapper).
1872         https://bugs.webkit.org/show_bug.cgi?id=29031
1873
1874         * bindings/scripts/CodeGeneratorV8.pm:
1875         * bindings/v8/V8DOMWrapper.cpp:
1876         (WebCore::V8DOMWrapper::getTemplate):
1877         * bindings/v8/V8Proxy.cpp:
1878         (WebCore::V8Proxy::createNewContext):
1879         (WebCore::V8Proxy::installDOMWindow):
1880         * bindings/v8/custom/V8DOMWindowCustom.cpp:
1881         (WebCore::ACCESSOR_GETTER):
1882         (WebCore::ACCESSOR_SETTER):
1883         (WebCore::INDEXED_PROPERTY_GETTER):
1884         (WebCore::NAMED_PROPERTY_GETTER):
1885         (WebCore::NAMED_ACCESS_CHECK):
1886         (WebCore::INDEXED_ACCESS_CHECK):
1887 2009-10-07  Adam Roben  <aroben@apple.com>
1888
1889         Fix typo in PluginView::load that was causing cross-origin loads to
1890         be allowed
1891
1892         This typo was introduced in the build fix in r49213.
1893
1894         Fixes <http://webkit.org/b/30168> REGRESSION (r49213):
1895         http/tests/plugins/local-geturl-from-remote.html is failing on Windows
1896
1897         Reviewed by Sam Weinig.
1898
1899         * plugins/PluginView.cpp:
1900         (WebCore::PluginView::load): Removed a comma operator that was making
1901         a condition always evaluate to true.
1902
1903 2009-10-07  Kenneth Rohde Christiansen  <kenneth@webkit.org>
1904
1905         Reviewed by Simon Hausmann.
1906
1907         Do not create valid QColor's for invalid WebCore::Color's.
1908
1909         * platform/graphics/qt/ColorQt.cpp:
1910         (WebCore::Color::operator QColor):
1911
1912 2009-10-07  Janne Koskinen  <janne.p.koskinen@digia.com>
1913
1914         Reviewed by Simon Hausmann.
1915
1916         [Qt] Symbian SBSv2 .data segment adress fix
1917         https://bugs.webkit.org/show_bug.cgi?id=30157
1918
1919         RO-section in qtwebkit.dll exceeds allocated space in SBSv2. Move RW-section
1920         base address to start from 0x800000 instead of the toolchain default 0x400000
1921
1922         * WebCore.pro:
1923
1924 2009-10-07  Pavel Feldman  <pfeldman@chromium.org>
1925
1926         Reviewed by Timothy Hatcher.
1927
1928         Web Inspector: Migrate database inspection to the injected script-based schema.
1929
1930         https://bugs.webkit.org/show_bug.cgi?id=29788
1931
1932         * bindings/js/JSInspectorBackendCustom.cpp:
1933         (WebCore::JSInspectorBackend::databaseForId):
1934         * bindings/v8/custom/V8CustomBinding.h:
1935         * bindings/v8/custom/V8InspectorBackendCustom.cpp:
1936         (WebCore::CALLBACK_FUNC_DECL):
1937         * inspector/InspectorBackend.cpp:
1938         (WebCore::InspectorBackend::dispatchOnInjectedScript):
1939         (WebCore::InspectorBackend::databaseForId):
1940         (WebCore::InspectorBackend::selectDatabase):
1941         (WebCore::InspectorBackend::getDatabaseTableNames):
1942         (WebCore::InspectorBackend::reportDidDispatchOnInjectedScript):
1943         * inspector/InspectorBackend.h:
1944         * inspector/InspectorBackend.idl:
1945         * inspector/InspectorController.cpp:
1946         (WebCore::InspectorController::populateScriptObjects):
1947         (WebCore::InspectorController::resetScriptObjects):
1948         (WebCore::InspectorController::selectDatabase):
1949         (WebCore::InspectorController::databaseForId):
1950         (WebCore::InspectorController::didOpenDatabase):
1951         (WebCore::InspectorController::didUseDOMStorage):
1952         (WebCore::InspectorController::selectDOMStorage):
1953         (WebCore::InspectorController::getDOMStorageResourceForId):
1954         * inspector/InspectorController.h:
1955         * inspector/InspectorDatabaseResource.cpp:
1956         (WebCore::InspectorDatabaseResource::InspectorDatabaseResource):
1957         (WebCore::InspectorDatabaseResource::bind):
1958         * inspector/InspectorDatabaseResource.h:
1959         (WebCore::InspectorDatabaseResource::database):
1960         (WebCore::InspectorDatabaseResource::id):
1961         * inspector/InspectorFrontend.cpp:
1962         (WebCore::InspectorFrontend::addDatabase):
1963         (WebCore::InspectorFrontend::selectDatabase):
1964         (WebCore::InspectorFrontend::didGetDatabaseTableNames):
1965         (WebCore::InspectorFrontend::addDOMStorage):
1966         * inspector/InspectorFrontend.h:
1967         * inspector/front-end/Database.js:
1968         (WebInspector.Database):
1969         (WebInspector.Database.prototype.get id):
1970         (WebInspector.Database.prototype.set name):
1971         (WebInspector.Database.prototype.set version):
1972         (WebInspector.Database.prototype.set domain):
1973         (WebInspector.Database.prototype.getTableNames):
1974         (WebInspector.Database.prototype.executeSql):
1975         * inspector/front-end/InjectedScript.js:
1976         (InjectedScript.dispatch):
1977         (InjectedScript.executeSql):
1978         (InjectedScript.executeSql.errorCallback):
1979         (InjectedScript.executeSql.queryTransaction):
1980         * inspector/front-end/InjectedScriptAccess.js:
1981         (InjectedScriptAccess._installHandler.InjectedScriptAccess.methodName):
1982         (InjectedScriptAccess._installHandler):
1983         * inspector/front-end/StoragePanel.js:
1984         (WebInspector.StoragePanel.prototype.selectDatabase):
1985         (WebInspector.StoragePanel.prototype.dataGridForResult):
1986         * inspector/front-end/inspector.js:
1987         (WebInspector.addDatabase):
1988
1989 2009-10-07  Girish Ramakrishnan  <girish@forwardbias.in>
1990
1991         Reviewed by Simon Hausmann.
1992
1993         [Qt] Windowless Plugins: Disable content propagation for QGraphicsView items
1994         
1995         We cannot support content propagation for items in QGraphicsView because
1996         the contents of the backing store might be transformed. So turn it off
1997         if we are not painting on QWidget.
1998         
1999         Note that this check will not work for a QWebView in a
2000         QGraphicsProxyWidget, but I guess it's fine. Alternative is to do an
2001         even uglier cast: static_cast painter's paintDevice() to QWidget and
2002         check if it is the viewport() of QGraphicsView.
2003
2004         https://bugs.webkit.org/show_bug.cgi?id=30149
2005
2006         * plugins/qt/PluginViewQt.cpp:
2007         (WebCore::PluginView::paint):
2008
2009 2009-10-07  Simon Hausmann  <simon.hausmann@nokia.com>
2010
2011         Fix the Qt build by adding the missing files to the build.
2012
2013         * WebCore.pro:
2014
2015 2009-10-07  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
2016
2017         Reviewed by Xan Lopez.
2018
2019         Fix incorrect convertion of double into int while assigning it to
2020         a float.
2021
2022         * platform/graphics/gtk/SimpleFontDataGtk.cpp:
2023         (WebCore::SimpleFontData::platformInit):
2024         * platform/graphics/gtk/SimpleFontDataPango.cpp:
2025         (WebCore::SimpleFontData::platformInit):
2026
2027 2009-10-07  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
2028
2029         Reviewed by Xan Lopez.
2030
2031         Fix rounding error issues in height calculation in 64 bits.
2032
2033         Already covered by existing tests.
2034
2035         * platform/graphics/gtk/SimpleFontDataGtk.cpp:
2036         (WebCore::SimpleFontData::platformInit):
2037         * platform/graphics/gtk/SimpleFontDataPango.cpp:
2038         (WebCore::SimpleFontData::platformInit):
2039
2040 2009-10-07  Shinichiro Hamaji  <hamaji@chromium.org>
2041
2042         Reviewed by Eric Seidel.
2043
2044         Dual lines in css2.1 layout tests do not match:
2045         https://bugs.webkit.org/show_bug.cgi?id=23262
2046
2047         Now we can put a counter node as the next sibling of a reset node.
2048         Re-layout the counter content when the count is updated.
2049
2050         Tests: fast/css/counters/t1204-increment-00-c-o.html
2051                fast/css/counters/t1204-increment-01-c-o.html
2052
2053         * rendering/CounterNode.cpp:
2054         (WebCore::CounterNode::recount):
2055         * rendering/RenderCounter.cpp:
2056         (WebCore::findPlaceForCounter):
2057
2058 2009-10-06  Xan Lopez  <xlopez@igalia.com>
2059
2060         Try to fix the GTK+ build.
2061
2062         * GNUmakefile.am:
2063
2064 2009-10-06  Adam Barth  <abarth@webkit.org>
2065
2066         Reviewed by Adam Barth.
2067
2068         Removed unused member variable from FrameLoader
2069         https://bugs.webkit.org/show_bug.cgi?id=30146
2070
2071         * loader/FrameLoader.cpp:
2072         (WebCore::FrameLoader::FrameLoader):
2073         * loader/FrameLoader.h:
2074
2075 2009-10-06  David Levin  <levin@chromium.org>
2076
2077         Reviewed by NOBODY (build fix).
2078
2079         A few small/trivial tweaks to the last build fix.
2080
2081         * bindings/scripts/CodeGeneratorV8.pm:
2082
2083 2009-10-06  David Levin  <levin@chromium.org>
2084
2085         Reviewed by Dimitri Glazkov.
2086
2087         [Chromium] Need to adjust MessagePort, etc. code for the post clone work done.
2088         https://bugs.webkit.org/show_bug.cgi?id=30147
2089
2090         No change in functionality so no new tests.
2091
2092         * WebCore.gypi:
2093         * bindings/scripts/CodeGeneratorV8.pm:
2094         * bindings/v8/SerializedScriptValue.h: Added.
2095          A very simple implementation of SerializedScriptValue
2096          that only works for strings.
2097         * bindings/v8/custom/V8DOMWindowCustom.cpp:
2098         (WebCore::CALLBACK_FUNC_DECL):
2099         * bindings/v8/custom/V8DedicatedWorkerContextCustom.cpp:
2100         (WebCore::CALLBACK_FUNC_DECL):
2101         * bindings/v8/custom/V8MessageEventCustom.cpp:
2102         (WebCore::CALLBACK_FUNC_DECL):
2103         * bindings/v8/custom/V8MessagePortCustom.cpp:
2104         (WebCore::CALLBACK_FUNC_DECL):
2105         * bindings/v8/custom/V8WorkerCustom.cpp:
2106         (WebCore::CALLBACK_FUNC_DECL):
2107
2108 2009-10-06  Sam Weinig  <sam@webkit.org>
2109
2110         Reviewed by Brady Eidson.
2111
2112         Fix for <rdar://problem/7271202>
2113         Dispatch resource load delegate functions for the media element.
2114         Since we don't get the required callbacks from the media engine,
2115         just fake the parameters to the delegate functions as best as possible.
2116
2117         * html/HTMLMediaElement.cpp:
2118         (WebCore::HTMLMediaElement::loadResource):
2119         (WebCore::HTMLMediaElement::isSafeToLoadURL):
2120         * loader/FrameLoader.cpp:
2121         (WebCore::FrameLoader::willLoadMediaElementURL):
2122         * loader/FrameLoader.h:
2123
2124 2009-10-06  Oliver Hunt  <oliver@apple.com>
2125
2126         Reviewed by NOBODY (Build fix).
2127
2128         More build fixes.
2129
2130         * bindings/js/SerializedScriptValue.cpp:
2131         (WebCore::DeserializingTreeWalker::getProperty):
2132         (WebCore::TeardownTreeWalker::getProperty):
2133         * bindings/js/SerializedScriptValue.h:
2134         (WebCore::SerializedScriptValue::SerializedScriptValue):
2135
2136 2009-10-06  Oliver Hunt  <oliver@apple.com>
2137
2138         Reviewed by NOBODY (Build fix).
2139
2140         Build and formatting fix.
2141
2142         * ForwardingHeaders/runtime/ExceptionHelpers.h: Added.
2143         * bindings/js/SerializedScriptValue.cpp:
2144         * bindings/js/SerializedScriptValue.h:
2145         (WebCore::SerializedScriptValueData::operator bool):
2146         (WebCore::SerializedScriptValueData::release):
2147         (WebCore::SerializedScriptValue::release):
2148         (WebCore::SerializedScriptValue::toString):
2149         (WebCore::SerializedScriptValue::~SerializedScriptValue):
2150         (WebCore::SerializedScriptValue::SerializedScriptValue):
2151
2152 2009-10-05  Oliver Hunt  <oliver@apple.com>
2153
2154         Reviewed by Gavin Barraclough.
2155
2156         It should be possible to post (clone) built-in JS objects to Workers
2157         https://bugs.webkit.org/show_bug.cgi?id=22878
2158
2159         Implement object cloning semantics for postMessage.  Currently only
2160         a partial implementation of the spec -- cloning of File, FileList,
2161         ImageData, and RegExp were left out as they would have significantly
2162         increased patch size.
2163
2164         Cloning requires multiple tree walks so we use a templated tree
2165         walk function, allowing us to share a single implementation for
2166         serialization, deserialization, and eventual destruction of the
2167         serialized object tree.
2168
2169         Test: fast/dom/Window/window-postmessage-clone.html
2170
2171         * WebCore.vcproj/WebCore.vcproj:
2172         * WebCore.xcodeproj/project.pbxproj:
2173         * bindings/js/JSDOMWindowCustom.cpp:
2174         (WebCore::JSDOMWindow::postMessage):
2175         * bindings/js/JSMessageEventCustom.cpp:
2176         (WebCore::JSMessageEvent::initMessageEvent):
2177         * bindings/js/JSMessagePortCustom.h:
2178         (WebCore::handlePostMessage):
2179         * bindings/js/SerializedScriptValue.cpp: Added.
2180         (WebCore::SerializedObject::set):
2181         (WebCore::SerializedObject::names):
2182         (WebCore::SerializedObject::values):
2183         (WebCore::SerializedObject::create):
2184         (WebCore::SerializedObject::clear):
2185         (WebCore::SerializedObject::SerializedObject):
2186         (WebCore::SerializedArray::setIndex):
2187         (WebCore::SerializedArray::canDoFastRead):
2188         (WebCore::SerializedArray::getIndex):
2189         (WebCore::SerializedArray::getSparseIndex):
2190         (WebCore::SerializedArray::length):
2191         (WebCore::SerializedArray::create):
2192         (WebCore::SerializedArray::clear):
2193         (WebCore::SerializedArray::SerializedArray):
2194         (WebCore::SerializedScriptValueData::SerializedScriptValueData):
2195         (WebCore::SharedSerializedData::asArray):
2196         (WebCore::SharedSerializedData::asObject):
2197         (WebCore::):
2198         (WebCore::walk):
2199         (WebCore::BaseWalker::BaseWalker):
2200         (WebCore::BaseWalker::shouldTerminate):
2201         (WebCore::BaseWalker::ticksUntilNextCheck):
2202         (WebCore::BaseWalker::didTimeOut):
2203         (WebCore::BaseWalker::throwStackOverflow):
2204         (WebCore::BaseWalker::throwInterruptedException):
2205         (WebCore::SerializingTreeWalker::SerializingTreeWalker):
2206         (WebCore::SerializingTreeWalker::null):
2207         (WebCore::SerializingTreeWalker::isArray):
2208         (WebCore::SerializingTreeWalker::isObject):
2209         (WebCore::SerializingTreeWalker::asInputArray):
2210         (WebCore::SerializingTreeWalker::asInputObject):
2211         (WebCore::SerializingTreeWalker::createOutputArray):
2212         (WebCore::SerializingTreeWalker::createOutputObject):
2213         (WebCore::SerializingTreeWalker::length):
2214         (WebCore::SerializingTreeWalker::canDoFastRead):
2215         (WebCore::SerializingTreeWalker::getIndex):
2216         (WebCore::SerializingTreeWalker::getSparseIndex):
2217         (WebCore::SerializingTreeWalker::getProperty):
2218         (WebCore::SerializingTreeWalker::convertIfTerminal):
2219         (WebCore::SerializingTreeWalker::getPropertyNames):
2220         (WebCore::SerializingTreeWalker::putIndex):
2221         (WebCore::SerializingTreeWalker::putProperty):
2222         (WebCore::SerializingTreeWalker::startArray):
2223         (WebCore::SerializingTreeWalker::endArray):
2224         (WebCore::SerializingTreeWalker::startObject):
2225         (WebCore::SerializingTreeWalker::endObject):
2226         (WebCore::SerializedScriptValueData::serialize):
2227         (WebCore::DeserializingTreeWalker::DeserializingTreeWalker):
2228         (WebCore::DeserializingTreeWalker::null):
2229         (WebCore::DeserializingTreeWalker::isArray):
2230         (WebCore::DeserializingTreeWalker::isObject):
2231         (WebCore::DeserializingTreeWalker::asInputArray):
2232         (WebCore::DeserializingTreeWalker::asInputObject):
2233         (WebCore::DeserializingTreeWalker::createOutputArray):
2234         (WebCore::DeserializingTreeWalker::createOutputObject):
2235         (WebCore::DeserializingTreeWalker::length):
2236         (WebCore::DeserializingTreeWalker::canDoFastRead):
2237         (WebCore::DeserializingTreeWalker::getIndex):
2238         (WebCore::DeserializingTreeWalker::getSparseIndex):
2239         (WebCore::DeserializingTreeWalker::getProperty):
2240         (WebCore::DeserializingTreeWalker::convertIfTerminal):
2241         (WebCore::DeserializingTreeWalker::getPropertyNames):
2242         (WebCore::DeserializingTreeWalker::putIndex):
2243         (WebCore::DeserializingTreeWalker::putProperty):
2244         (WebCore::DeserializingTreeWalker::startArray):
2245         (WebCore::DeserializingTreeWalker::endArray):
2246         (WebCore::DeserializingTreeWalker::startObject):
2247         (WebCore::DeserializingTreeWalker::endObject):
2248         (WebCore::SerializedScriptValueData::deserialize):
2249         (WebCore::TeardownTreeWalker::shouldTerminate):
2250         (WebCore::TeardownTreeWalker::ticksUntilNextCheck):
2251         (WebCore::TeardownTreeWalker::didTimeOut):
2252         (WebCore::TeardownTreeWalker::throwStackOverflow):
2253         (WebCore::TeardownTreeWalker::throwInterruptedException):
2254         (WebCore::TeardownTreeWalker::null):
2255         (WebCore::TeardownTreeWalker::isArray):
2256         (WebCore::TeardownTreeWalker::isObject):
2257         (WebCore::TeardownTreeWalker::asInputArray):
2258         (WebCore::TeardownTreeWalker::asInputObject):
2259         (WebCore::TeardownTreeWalker::createOutputArray):
2260         (WebCore::TeardownTreeWalker::createOutputObject):
2261         (WebCore::TeardownTreeWalker::length):
2262         (WebCore::TeardownTreeWalker::canDoFastRead):
2263         (WebCore::TeardownTreeWalker::getIndex):
2264         (WebCore::TeardownTreeWalker::getSparseIndex):
2265         (WebCore::TeardownTreeWalker::getProperty):
2266         (WebCore::TeardownTreeWalker::convertIfTerminal):
2267         (WebCore::TeardownTreeWalker::getPropertyNames):
2268         (WebCore::TeardownTreeWalker::putIndex):
2269         (WebCore::TeardownTreeWalker::putProperty):
2270         (WebCore::TeardownTreeWalker::startArray):
2271         (WebCore::TeardownTreeWalker::endArray):
2272         (WebCore::TeardownTreeWalker::startObject):
2273         (WebCore::TeardownTreeWalker::endObject):
2274         (WebCore::SerializedScriptValueData::tearDownSerializedData):
2275         * bindings/js/SerializedScriptValue.h: Added.
2276         (WebCore::SharedSerializedData::~SharedSerializedData):
2277         (WebCore::SerializedScriptValueData::):
2278         (WebCore::SerializedScriptValueData::type):
2279         (WebCore::SerializedScriptValueData::~SerializedScriptValueData):
2280         (WebCore::SerializedScriptValueData::SerializedScriptValueData):
2281         (WebCore::SerializedScriptValueData::asImmediate):
2282         (WebCore::SerializedScriptValueData::asDouble):
2283         (WebCore::SerializedScriptValueData::asString):
2284         (WebCore::SerializedScriptValueData::asObject):
2285         (WebCore::SerializedScriptValueData::asArray):
2286         (WebCore::SerializedScriptValueData::operator bool ):
2287         (WebCore::SerializedScriptValueData::release):
2288         (WebCore::SerializedScriptValue::create):
2289         (WebCore::SerializedScriptValue::release):
2290         (WebCore::SerializedScriptValue::toString):
2291         (WebCore::SerializedScriptValue::deserialize):
2292         (WebCore::SerializedScriptValue::~SerializedScriptValue):
2293         (WebCore::SerializedScriptValue::SerializedScriptValue):
2294         * bindings/scripts/CodeGeneratorJS.pm:
2295         * bindings/scripts/CodeGeneratorObjC.pm:
2296         * dom/MessageEvent.cpp:
2297         (WebCore::MessageEvent::MessageEvent):
2298         (WebCore::MessageEvent::initMessageEvent):
2299         * dom/MessageEvent.h:
2300         (WebCore::MessageEvent::create):
2301         (WebCore::MessageEvent::data):
2302         * dom/MessageEvent.idl:
2303         * dom/MessagePort.cpp:
2304         (WebCore::MessagePort::postMessage):
2305         * dom/MessagePort.h:
2306         * dom/MessagePortChannel.cpp:
2307         (WebCore::MessagePortChannel::EventData::create):
2308         (WebCore::MessagePortChannel::EventData::EventData):
2309         * dom/MessagePortChannel.h:
2310         (WebCore::MessagePortChannel::EventData::message):
2311         * page/DOMWindow.cpp:
2312         (WebCore::PostMessageTimer::PostMessageTimer):
2313         (WebCore::DOMWindow::postMessage):
2314         * page/DOMWindow.h:
2315         * page/DOMWindow.idl:
2316         * page/EventSource.cpp:
2317         (WebCore::EventSource::createMessageEvent):
2318         * websockets/WebSocket.cpp:
2319         (WebCore::WebSocket::didReceiveMessage):
2320         * workers/DedicatedWorkerContext.cpp:
2321         (WebCore::DedicatedWorkerContext::postMessage):
2322         * workers/DedicatedWorkerContext.h:
2323         * workers/DedicatedWorkerContext.idl:
2324         * workers/Worker.cpp:
2325         (WebCore::Worker::postMessage):
2326         * workers/Worker.h:
2327         * workers/Worker.idl:
2328         * workers/WorkerContextProxy.h:
2329         * workers/WorkerMessagingProxy.cpp:
2330         (WebCore::MessageWorkerContextTask::create):
2331         (WebCore::MessageWorkerContextTask::MessageWorkerContextTask):
2332         (WebCore::MessageWorkerTask::create):
2333         (WebCore::MessageWorkerTask::MessageWorkerTask):
2334         (WebCore::WorkerMessagingProxy::postMessageToWorkerObject):
2335         (WebCore::WorkerMessagingProxy::postMessageToWorkerContext):
2336         * workers/WorkerMessagingProxy.h:
2337         * workers/WorkerObjectProxy.h:
2338
2339 2009-10-06  Adam Barth  <abarth@webkit.org>
2340
2341         Unreviewed build fix for Windows.
2342
2343         * plugins/PluginView.cpp:
2344         (WebCore::PluginView::load):
2345
2346 2009-10-06  Adam Barth  <abarth@webkit.org>
2347
2348         Reviewed by Eric Seidel.
2349
2350         Move FrameLoader::canLoad to SecurityOrigin
2351         https://bugs.webkit.org/show_bug.cgi?id=30111
2352
2353         * WebCore.base.exp:
2354         * html/HTMLMediaElement.cpp:
2355         (WebCore::HTMLMediaElement::isSafeToLoadURL):
2356         * loader/Cache.cpp:
2357         (WebCore::Cache::requestResource):
2358         * loader/FrameLoader.cpp:
2359         (WebCore::FrameLoader::loadSubframe):
2360         (WebCore::FrameLoader::loadPlugin):
2361         (WebCore::FrameLoader::loadFrameRequest):
2362         (WebCore::FrameLoader::loadResourceSynchronously):
2363         (WebCore::FrameLoader::createJavaAppletWidget):
2364         * loader/FrameLoader.h:
2365         * loader/SubresourceLoader.cpp:
2366         (WebCore::SubresourceLoader::create):
2367         * page/SecurityOrigin.cpp:
2368         (WebCore::SecurityOrigin::canLoad):
2369         (WebCore::SecurityOrigin::shouldHideReferrer):
2370         * page/SecurityOrigin.h:
2371
2372 2009-10-06  Adam Barth  <abarth@webkit.org>
2373
2374         Reviewed by Eric Seidel.
2375
2376         Move setLocalLoadPolicy and friends to SecurityOrigin
2377         https://bugs.webkit.org/show_bug.cgi?id=30110
2378
2379         These have more to do with security policies than with loading frames.
2380
2381         * WebCore.base.exp:
2382         * dom/Document.cpp:
2383         (WebCore::Document::initSecurityContext):
2384         * loader/Cache.cpp:
2385         (WebCore::Cache::requestResource):
2386         * loader/FrameLoader.cpp:
2387         * loader/FrameLoader.h:
2388         * loader/SubresourceLoader.cpp:
2389         (WebCore::SubresourceLoader::create):
2390         * page/SecurityOrigin.cpp:
2391         (WebCore::SecurityOrigin::setLocalLoadPolicy):
2392         (WebCore::SecurityOrigin::restrictAccessToLocal):
2393         (WebCore::SecurityOrigin::allowSubstituteDataAccessToLocal):
2394         * page/SecurityOrigin.h:
2395         (WebCore::SecurityOrigin::):
2396
2397 2009-10-06  Brian Weinstein  <bweinstein@apple.com>
2398
2399         Reviewed by Brady Eidson.
2400
2401         Preparation for <http://webkit.org/b/30104>.
2402         Inspector should show cookies of sub-resources on the page.
2403         
2404         Implement getRawCookies for CFNetwork for Windows, so we can see more
2405         than just a key/value pair for Cookies when we are on Windows.
2406
2407         * platform/network/win/CookieJarCFNetWin.cpp:
2408         (WebCore::getRawCookies):
2409
2410 2009-10-06  Dave Hyatt  <hyatt@apple.com>
2411
2412         Reviewed by Adam Roben.
2413
2414         https://bugs.webkit.org/show_bug.cgi?id=30132, make beforeload work with <link> elements and
2415         XML processing instructions.
2416
2417         Fix up ProcessingInstruction's setData call so that it actually updates a stylesheet when the
2418         data gets changed.
2419
2420         Move dispatchBeforeLoadedEvent to ContainerNode so all Elements (and ProcessingInstruction) can
2421         access it.
2422
2423         Added fast/dom/beforeload/link-before-load.html
2424
2425         * dom/ContainerNode.cpp:
2426         (WebCore::ContainerNode::dispatchBeforeLoadEvent):
2427         * dom/ContainerNode.h:
2428         * dom/ProcessingInstruction.cpp:
2429         (WebCore::ProcessingInstruction::checkStyleSheet):
2430         (WebCore::ProcessingInstruction::setData):
2431         * dom/ScriptElement.cpp:
2432         (WebCore::ScriptElementData::requestScript):
2433         * dom/ScriptElement.h:
2434         * dom/XMLTokenizerLibxml2.cpp:
2435         (WebCore::XMLTokenizer::endElementNs):
2436         * html/HTMLLinkElement.cpp:
2437         (WebCore::HTMLLinkElement::parseMappedAttribute):
2438         (WebCore::HTMLLinkElement::process):
2439         * html/HTMLScriptElement.cpp:
2440         (WebCore::HTMLScriptElement::forAttributeValue):
2441         * html/HTMLScriptElement.h:
2442         * svg/SVGScriptElement.cpp:
2443         * svg/SVGScriptElement.h:
2444
2445 2009-10-06  Simon Fraser  <simon.fraser@apple.com>
2446
2447         Reviewed by Mark Rowe.
2448
2449         accessibility/media-element.html crashes (and has incorrect result)
2450         https://bugs.webkit.org/show_bug.cgi?id=30108
2451
2452         Fix up the accessibilty label for the newly added fullscreen button,
2453         and update the test result accordingly.
2454
2455         * accessibility/AccessibilityMediaControls.cpp:
2456         (WebCore::AccessibilityMediaControl::controlTypeName):
2457
2458 2009-10-06  Kelly Norton  <knorton@google.com>
2459
2460         Reviewed by Timothy Hatcher.
2461
2462         Fixes <https://bugs.webkit.org/show_bug.cgi?id=30028>
2463         Multiple calls to SetFrontendProxyObject can leave an InspectorTimelineAgent with an invalid
2464         InspectorFrontend.
2465
2466         * inspector/InspectorController.cpp:
2467         (WebCore::InspectorController::setFrontendProxyObject): Adds a check for an existing timeline agent.
2468
2469 2009-10-06  Antti Koivisto  <antti@apple.com>
2470
2471         Reviewed by Dave Kilzer.
2472
2473         Move textRects to the right category in DOM.mm. Include DOMPrivate.h to ensure that the interfaces match.
2474
2475         * bindings/objc/DOM.mm:
2476         (-[DOMNode textRects]):
2477
2478 2009-10-06  Benjamin C Meyer  <bmeyer@rim.com>
2479
2480         Reviewed by Ariya Hidayat.
2481         
2482         Match the behavior of other WebKit browser and have the first url of the drag data be the url passed in declareAndWriteDragImage and set the text of the drag data to be the title argument.
2483         
2484         Manual test: Drag the readability js link from http://lab.arc90.com/experiments/readability/
2485         
2486         * platform/qt/ClipboardQt.cpp:
2487         (WebCore::ClipboardQt::declareAndWriteDragImage):
2488
2489 2009-10-06  Kent Tamura  <tkent@chromium.org>
2490
2491         Reviewed by Darin Adler.
2492
2493         Implement min/max attributes, ValidityState.rangeUnderflow and
2494         ValidityState.rangeOverflow for <input type=number> and <input type=range>
2495         https://bugs.webkit.org/show_bug.cgi?id=29069
2496         
2497         HTMLInputElement::max and min are not defined for COM because they
2498         conflict with the standard min() and max() macros.
2499
2500         Tests: fast/forms/ValidityState-rangeOverflow-number.html
2501                fast/forms/ValidityState-rangeOverflow-range.html
2502                fast/forms/ValidityState-rangeUnderflow-number.html
2503                fast/forms/ValidityState-rangeUnderflow-range.html
2504                fast/forms/input-minmax.html
2505
2506         * html/HTMLInputElement.cpp:
2507         (WebCore::HTMLInputElement::rangeUnderflow):
2508         (WebCore::HTMLInputElement::rangeOverflow):
2509         (WebCore::HTMLInputElement::rangeMinimum):
2510         (WebCore::HTMLInputElement::rangeMaximum):
2511         * html/HTMLInputElement.h:
2512         * html/HTMLInputElement.idl:
2513         * html/ValidityState.cpp:
2514         (WebCore::ValidityState::rangeUnderflow):
2515         (WebCore::ValidityState::rangeOverflow):
2516         * html/ValidityState.h:
2517         * rendering/RenderSlider.cpp:
2518         (WebCore::SliderRange::SliderRange):
2519         (WebCore::SliderRange::valueFromElement):
2520
2521 2009-10-06  Adam Barth  <abarth@webkit.org>
2522
2523         Reviewed by Eric Seidel.
2524
2525         Move m_openedByDOM to Page
2526         https://bugs.webkit.org/show_bug.cgi?id=30109
2527
2528         We only need one instance of m_openedByDOM per page, we should move it
2529         to a page-scoped object.  Notice that it's only ever touched for the
2530         main frame.
2531
2532         * bindings/js/JSDOMWindowCustom.cpp:
2533         (WebCore::createWindow):
2534         * bindings/v8/custom/V8DOMWindowCustom.cpp:
2535         (WebCore::createWindow):
2536         * loader/FrameLoader.cpp:
2537         * loader/FrameLoader.h:
2538         * page/DOMWindow.cpp:
2539         (WebCore::DOMWindow::close):
2540         * page/Page.cpp:
2541         (WebCore::Page::Page):
2542         (WebCore::Page::openedByDOM):
2543         (WebCore::Page::setOpenedByDOM):
2544         * page/Page.h:
2545
2546 2009-10-06  Carol Szabo  <carol.szabo@nokia.com>
2547
2548         Reviewed by Ariya Hidayat.
2549
2550         [Qt] Some functions in GraphicsContext do not work
2551         as expected if the associated painter has no clipping.
2552         https://bugs.webkit.org/show_bug.cgi?id=29691
2553
2554         No new tests are associated with this because DumpRenderTree
2555         always sets clipping on the painter, thus it would never hit 
2556         the test case, but fast/box-shadow/basic-shadows.html is a
2557         good example of what happens if the clipping is not set by
2558         the user of QtWebKit.
2559
2560         * platform/graphics/qt/GraphicsContextQt.cpp:
2561         (WebCore::GraphicsContext::clipOut):
2562         (WebCore::GraphicsContext::clipOutEllipseInRect):
2563         Fixed to handle the case that there is no clipping
2564         before the call.
2565
2566 2009-10-06  Dave Hyatt  <hyatt@apple.com>
2567
2568         Reviewed by Adam Roben.
2569
2570         https://bugs.webkit.org/show_bug.cgi?id=30131, make beforeload fire on script elements.
2571
2572         Added tests in fast/dom/beforeload/.
2573
2574         * dom/ScriptElement.cpp:
2575         (WebCore::ScriptElementData::requestScript):
2576         * dom/ScriptElement.h:
2577         * dom/XMLTokenizerLibxml2.cpp:
2578         (WebCore::XMLTokenizer::endElementNs):
2579         * html/HTMLAttributeNames.in:
2580         * html/HTMLScriptElement.cpp:
2581         (WebCore::HTMLScriptElement::parseMappedAttribute):
2582         (WebCore::HTMLScriptElement::dispatchBeforeLoadEvent):
2583         * html/HTMLScriptElement.h:
2584         * html/HTMLTokenizer.cpp:
2585         (WebCore::HTMLTokenizer::scriptHandler):
2586         * svg/SVGScriptElement.cpp:
2587         (WebCore::SVGScriptElement::dispatchBeforeLoadEvent):
2588         * svg/SVGScriptElement.h:
2589
2590 2009-10-06  Xan Lopez  <xlopez@igalia.com>
2591
2592         Reviewed by Eric Seidel.
2593
2594         https://bugs.webkit.org/show_bug.cgi?id=25526
2595         [Gtk] Additional support is needed for caret browsing
2596
2597         Enable caret movement commands also when caret browsing setting is
2598         enabled.
2599
2600         * editing/EditorCommand.cpp:
2601         (WebCore::caretBrowsingEnabled):
2602         (WebCore::enabledVisibleSelectionOrCaretBrowsing):
2603         (WebCore::enabledInEditableTextOrCaretBrowsing):
2604         (WebCore::CommandEntry::):
2605         * manual-tests/gtk/caret-browsing.html: Added.
2606
2607 2009-10-06  Anton Muhin  <antonm@chromium>
2608
2609         Reviewed by Dimitri Glazkov.
2610
2611         Non standard, but popular exetension allows automagically
2612         turn a function into a namespace resolver.  Support that in
2613         Chromium as well.
2614
2615         Adjust CodeGeneratorV8 to treat XPathNSResolver in a special way.
2616         https://bugs.webkit.org/show_bug.cgi?id=30128
2617
2618         * bindings/scripts/CodeGeneratorV8.pm:
2619         * bindings/v8/V8DOMWrapper.h:
2620         (WebCore::V8DOMWrapper::getXPathNSResolver):
2621         * bindings/v8/custom/V8DocumentCustom.cpp:
2622         (WebCore::CALLBACK_FUNC_DECL):
2623
2624 2009-10-06  Pavel Feldman  <pfeldman@chromium.org>
2625
2626         Reviewed by Timothy Hatcher.
2627
2628         Web Inspector: close inspector client view on
2629         InspectorController::close API call.
2630
2631         In order to run batch web inspector layout tests (and not affect
2632         subsequent tests) we should close inspector client's view upon
2633         InspectorController::close API call.
2634
2635         https://bugs.webkit.org/show_bug.cgi?id=30009
2636
2637         * inspector/InspectorController.cpp:
2638         (WebCore::InspectorController::inspectedPageDestroyed):
2639         (WebCore::InspectorController::close):
2640
2641 2009-10-06  Simon Hausmann  <simon.hausmann@nokia.com>
2642
2643         Reviewed by Tor Arne Vestbø.
2644
2645         Fix the Qt/Windows build by stubbing out the still image
2646         support for halted plugins for the Qt build.
2647
2648         Bugzilla entry https://bugs.webkit.org/show_bug.cgi?id=30130
2649         tracks removing this by implementing Frame::nodeImage().
2650
2651         * plugins/win/PluginViewWin.cpp:
2652         (WebCore::PluginView::halt):
2653
2654 2009-10-05  Holger Hans Peter Freyther  <zecke@selfish.org>
2655
2656         Reviewed by Simon Hausmann.
2657
2658         [Qt] Change QImageReader usage in ImageDecoderQt
2659         https://bugs.webkit.org/show_bug.cgi?id=27538
2660
2661         Replace the ReadContext with another appoach to
2662         reading the image. Attempt to only read meta information
2663         like the image size and number of frames (for animations)
2664         first and then when the page is getting drawn decode
2665         the image with the QImageReader.
2666
2667         This is a huge benefit on pages with many images and saves
2668         ~2GB of memory on the szeged image test page.
2669
2670         * platform/graphics/qt/ImageDecoderQt.cpp:
2671         (WebCore::ImageDecoderQt::ImageDecoderQt):
2672         (WebCore::ImageDecoderQt::setData):
2673         (WebCore::ImageDecoderQt::isSizeAvailable):
2674         (WebCore::ImageDecoderQt::frameCount):
2675         (WebCore::ImageDecoderQt::repetitionCount):
2676         (WebCore::ImageDecoderQt::filenameExtension):
2677         (WebCore::ImageDecoderQt::frameBufferAtIndex):
2678         (WebCore::ImageDecoderQt::clearFrameBufferCache):
2679         (WebCore::ImageDecoderQt::internalDecodeSize):
2680         (WebCore::ImageDecoderQt::internalReadImage):
2681         (WebCore::ImageDecoderQt::internalHandleCurrentImage):
2682         (WebCore::ImageDecoderQt::forceLoadEverything):
2683         (WebCore::ImageDecoderQt::failRead):
2684         * platform/graphics/qt/ImageDecoderQt.h:
2685
2686 2009-10-05  Holger Hans Peter Freyther  <zecke@selfish.org>
2687
2688         Reviewed by Simon Hausmann.
2689
2690         [Qt] Make use of RGBA32Buffer in ImageDecoderQt
2691         https://bugs.webkit.org/show_bug.cgi?id=27538
2692
2693         Use the RGBA32Buffer instead of the internal ImageData
2694         to be able to use support of the base class, optionally
2695         support WebCore decoders for Qt and most importantly
2696         separate metadata and image data for better cache control.
2697
2698         Remove ImageSourceQt as everything is now shared with
2699         the normal ImageSource.
2700
2701         Change the ownership of the NativeImagePtr/QPixmap in
2702         ImageQt.cpp to delete the m_frame to be subject to cache
2703         control.
2704
2705         * WebCore.pro:
2706         * platform/graphics/ImageSource.cpp:
2707         * platform/graphics/qt/ImageDecoderQt.cpp:
2708         (WebCore::ImageDecoderQt::ReadContext::ReadContext):
2709         (WebCore::ImageDecoderQt::ReadContext::read):
2710         (WebCore::ImageDecoderQt::ReadContext::readImageLines):
2711         (WebCore::ImageDecoderQt::ImageDecoderQt):
2712         (WebCore::ImageDecoderQt::setData):
2713         (WebCore::ImageDecoderQt::frameCount):
2714         (WebCore::ImageDecoderQt::frameBufferAtIndex):
2715         (WebCore::ImageDecoderQt::clearFrameBufferCache):
2716         * platform/graphics/qt/ImageDecoderQt.h:
2717         * platform/graphics/qt/ImageSourceQt.cpp: Removed.
2718         * platform/image-decoders/ImageDecoder.h:
2719         (WebCore::RGBA32Buffer::decodedImage):
2720         (WebCore::RGBA32Buffer::getAddr):
2721         * platform/image-decoders/qt/RGBA32BufferQt.cpp: Added.
2722         (WebCore::RGBA32Buffer::RGBA32Buffer):
2723         (WebCore::RGBA32Buffer::setDecodedImage):
2724         (WebCore::RGBA32Buffer::clear):
2725         (WebCore::RGBA32Buffer::zeroFill):
2726         (WebCore::RGBA32Buffer::copyBitmapData):
2727         (WebCore::RGBA32Buffer::setSize):
2728         (WebCore::RGBA32Buffer::asNewNativeImage):
2729         (WebCore::RGBA32Buffer::hasAlpha):
2730         (WebCore::RGBA32Buffer::setHasAlpha):
2731         (WebCore::RGBA32Buffer::setStatus):
2732         (WebCore::RGBA32Buffer::operator=):
2733         (WebCore::RGBA32Buffer::width):
2734         (WebCore::RGBA32Buffer::height):
2735
2736 2009-10-05  Holger Hans Peter Freyther  <zecke@selfish.org>
2737
2738         Reviewed by Simon Hausmann.
2739
2740         [Qt] ImageDecoderQt avoid QString creation.
2741         https://bugs.webkit.org/show_bug.cgi?id=27538
2742
2743         Avoid going from CString to QString to String
2744         and go directly from CString to String. Also
2745         avoid going to lower case to avoid an extra
2746         memory allocation.
2747
2748         * platform/graphics/qt/ImageDecoderQt.cpp:
2749         (WebCore::ImageDecoder::create):
2750         (WebCore::ImageDecoderQt::ImageDecoderQt):
2751         * platform/graphics/qt/ImageDecoderQt.h:
2752
2753 2009-10-05  Holger Hans Peter Freyther  <zecke@selfish.org>
2754
2755         Reviewed by Simon Hausmann.
2756
2757         [Qt] Cleanup the ImageDecoder of Qt.
2758         https://bugs.webkit.org/show_bug.cgi?id=27538
2759
2760         Remove the various enums for partial load. The fact is
2761         that this image decoder will decode everything that is
2762         in the file at once. Make it look like it behaves to
2763         ease fixing this core problem.
2764
2765         * platform/graphics/qt/ImageDecoderQt.cpp:
2766         (WebCore::ImageDecoderQt::ImageData::ImageData):
2767         (WebCore::ImageDecoderQt::ReadContext::ReadContext):
2768         (WebCore::ImageDecoderQt::ReadContext::read):
2769         (WebCore::ImageDecoderQt::ReadContext::readImageLines):
2770         (WebCore::ImageDecoderQt::hasFirstImageHeader):
2771         (WebCore::ImageDecoderQt::setData):
2772         * platform/graphics/qt/ImageDecoderQt.h:
2773
2774 2009-10-04  Holger Hans Peter Freyther  <zecke@selfish.org>
2775
2776         Reviewed by Simon Hausmann.
2777
2778         [Qt] Reimplement instead of overload frameCount in ImageDecoderQt.cpp
2779         https://bugs.webkit.org/show_bug.cgi?id=27538
2780
2781         Reimplement frameCount instead of overloading it.
2782
2783         * platform/graphics/qt/ImageDecoderQt.cpp:
2784         (WebCore::ImageDecoderQt::frameCount):
2785         * platform/graphics/qt/ImageDecoderQt.h:
2786
2787 2009-10-04  Holger Hans Peter Freyther  <zecke@selfish.org>
2788
2789         Reviewed by Simon Hausmann.
2790
2791         [Qt] QImageReader does not support progressive reading
2792         https://bugs.webkit.org/show_bug.cgi?id=27538
2793
2794         Change the ImageDecoderQt::setData to store the encoded
2795         data in ImageDecoder.
2796
2797         Only call ReadContext when the whole Resource has been
2798         loaded to avoid needless calls to reset and the
2799         ReadContext as progressive loading is not supported.
2800
2801         * platform/graphics/qt/ImageDecoderQt.cpp:
2802         (WebCore::ImageDecoderQt::setData):
2803         * platform/graphics/qt/ImageDecoderQt.h:
2804
2805 2009-10-04  Holger Hans Peter Freyther  <zecke@selfish.org>
2806
2807         Reviewed by Simon Hausmann.
2808
2809         [Qt] Remove dead code from ImageDecoderQt
2810         https://bugs.webkit.org/show_bug.cgi?id=27538
2811
2812         Remove unused variables and debugging code. The debug
2813         code has never been used and does not provide anything
2814         useful.
2815
2816         * platform/graphics/qt/ImageDecoderQt.cpp:
2817         (WebCore::ImageDecoderQt::ReadContext::read):
2818         (WebCore::ImageDecoderQt::ReadContext::readImageLines):
2819         (WebCore::ImageDecoderQt::setData):
2820         (WebCore::ImageDecoderQt::isSizeAvailable):
2821         (WebCore::ImageDecoderQt::frameCount):
2822         (WebCore::ImageDecoderQt::repetitionCount):
2823         (WebCore::ImageDecoderQt::filenameExtension):
2824         (WebCore::ImageDecoderQt::imageAtIndex):
2825
2826 2009-10-06  Philippe Normand  <pnormand@igalia.com>
2827
2828         Reviewed by Xan Lopez.
2829
2830         [GTK] segfault when calling gst_video_format_parse_caps in the video sink
2831         https://bugs.webkit.org/show_bug.cgi?id=30120
2832
2833         Fix use of gst_video_format_parse_caps()
2834
2835         * platform/graphics/gtk/VideoSinkGStreamer.cpp:
2836         (webkit_video_sink_idle_func):
2837
2838 2009-10-06  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
2839
2840         Reviewed by Simon Hausmann.
2841
2842         [Qt] Update mediaControls CSS
2843
2844         * css/mediaControlsQt.css:
2845
2846 2009-10-06  Pavel Feldman  <pfeldman@chromium.org>
2847
2848         Reviewed by Timothy Hatcher.
2849
2850         Web Inspector: Get rid of Preferences.ignoreWhitespace.
2851
2852         https://bugs.webkit.org/show_bug.cgi?id=30092
2853
2854         * inspector/front-end/DOMAgent.js:
2855         (WebInspector.DOMAgent):
2856         (WebInspector.DOMAgent.prototype._childNodeCountUpdated):
2857         * inspector/front-end/ElementsTreeOutline.js:
2858         (WebInspector.ElementsTreeOutline.prototype.update):
2859         (WebInspector.ElementsTreeElement):
2860         (WebInspector.ElementsTreeElement.prototype.onpopulate):
2861         (WebInspector.ElementsTreeElement.prototype._updateChildren.updateChildrenOfNode):
2862         (WebInspector.ElementsTreeElement.prototype._updateChildren):
2863         * inspector/front-end/TextPrompt.js:
2864         (WebInspector.TextPrompt.prototype.isCaretAtEndOfPrompt):
2865         * inspector/front-end/inspector.js:
2866         * inspector/front-end/utilities.js:
2867         (Node.prototype.rangeOfWord):
2868         (traverseNextNode):
2869         (traversePreviousNode):
2870         (onlyTextChild):
2871
2872 2009-10-06  Pavel Feldman  <pfeldman@chromium.org>
2873
2874         Reviewed by Timothy Hatcher.
2875
2876         Web Inspector: Do not call nodeTitleInfo twice +
2877         followup fixes for r49101.
2878
2879         https://bugs.webkit.org/show_bug.cgi?id=30087
2880
2881         * inspector/front-end/ElementsTreeOutline.js:
2882         (WebInspector.ElementsTreeElement):
2883
2884 2009-10-06  Girish Ramakrishnan  <girish@forwardbias.in>
2885
2886         Reviewed by Simon Hausmann.
2887
2888         [Qt] Windowless plugins: Enable painting on printer.
2889
2890         The print preview dialog crashed because the depth of the drawable
2891         changed owing to a bug in Qt - if you draw onto a 32-bit pixmap,
2892         and set a 24-bit pixmap as source, it will convert the source to
2893         32-bit.
2894
2895         1210fa5b2d65895ad2be1f9ca7cae586e3b29dc1 is the bug fix in Qt.
2896
2897         https://bugs.webkit.org/show_bug.cgi?id=20081
2898
2899         * plugins/qt/PluginViewQt.cpp:
2900         (WebCore::PluginView::paint):
2901
2902 2009-10-06  Girish Ramakrishnan  <girish@forwardbias.in>
2903
2904         Reviewed by Simon Hausmann.
2905
2906         [Qt] Windowless plugins: Make painting and events work when page is zoomed.
2907
2908         The element gets resized when zoomed. So, we have to make sure that we resize
2909         the drawable and do a setwindow call. Multiple calls to setwindow do not
2910         crash plugin in windowless mode (unlike in windowed mode).
2911
2912         For mouse events we have to convert the pos to post-zoom position.
2913
2914         https://bugs.webkit.org/show_bug.cgi?id=20081
2915
2916         * plugins/qt/PluginViewQt.cpp:
2917         (WebCore::setXButtonEventSpecificFields):
2918         (WebCore::setXMotionEventSpecificFields):
2919         (WebCore::setXCrossingEventSpecificFields):
2920         (WebCore::PluginView::handleMouseEvent):
2921         (WebCore::PluginView::setNPWindowIfNeeded):
2922
2923 2009-10-06  Girish Ramakrishnan  <girish@forwardbias.in>
2924
2925         Reviewed by Simon Hausmann.
2926
2927         [Qt] Windowless plugins: Add PluginQuirkRequiresDefaultScreenDepth quirk for Flash.
2928
2929         Flash does not use the visual provided by us to draw into the drawable.
2930         It instead uses the system default visual (as returned by XDefaultVisual).
2931         This means that if the screen default visual is 24-bit, Flash won't be
2932         able to draw on 32-bit drawable created by us. This is a bug in Flash
2933         and for the moment, the above quirk is only set for Flash.
2934
2935         Our strategy to create the drawable:
2936         1. Create a 32-bit drawable if the default screen depth is 32 or the
2937         quirk is not set (i.e not flash)
2938         2. If we didn't create a 32-bit drawable (maybe the Display has no such
2939         visual), we create a drawable with default screen depth.
2940
2941         As a result of the above changes, content propagation behavior changes as:
2942         1. Content propagation is possible only if the drawable we create and
2943         Qt's backing store are of the same depth.
2944         2. If we created a 32-bit drawable, there is no need for content
2945         propagation (Qt will take care of it).
2946
2947         https://bugs.webkit.org/show_bug.cgi?id=20081
2948
2949         * plugins/PluginPackage.cpp:
2950         (WebCore::PluginPackage::determineQuirks):
2951         * plugins/PluginQuirkSet.h:
2952         (WebCore::):
2953         * plugins/PluginView.cpp:
2954         (WebCore::PluginView::PluginView):
2955         * plugins/PluginView.h:
2956         * plugins/qt/PluginViewQt.cpp:
2957         (WebCore::PluginView::updatePluginWidget):
2958         (WebCore::PluginView::paint):
2959         (WebCore::getVisualAndColormap):
2960         (WebCore::PluginView::platformStart):
2961         (WebCore::PluginView::platformDestroy):
2962
2963 2009-10-06  Fumitoshi Ukai  <ukai@chromium.org>
2964
2965         Reviewed by Ariya Hidayat.
2966
2967         Qt build fix.
2968         https://bugs.webkit.org/show_bug.cgi?id=29362.
2969
2970         In Qt 4.5, a new function QPainter::fillRect(QRect, QColor) is
2971         introduced to avoid the expensive construction of QBrush.
2972         By casting WebCore::Color to QColor, we can compile on Qt 4.4
2973         and use optimization for solid color fill in Qt 4.5.
2974
2975         * platform/graphics/qt/GraphicsContextQt.cpp:
2976         (WebCore::GraphicsContext::drawRect):
2977         (WebCore::GraphicsContext::drawLine):
2978         (WebCore::drawBorderlessRectShadow):
2979
2980 2009-10-05  Andrei Popescu  <andreip@google.com>
2981
2982         Reviewed by Eric Carlson.
2983
2984         Allow the platform media player to know the <video> poster URL.
2985         Add MediaPlayerPrivate::prepareToPlay() to support media engines
2986         that do not buffer video data automatically. This method allows
2987         such media engines to start the buffering just before starting
2988         playback.
2989         https://bugs.webkit.org/show_bug.cgi?id=29133
2990
2991         All platforms that currently implement <video> return false
2992         in MediaPlayerPrivate::canLoadPoster() and do nothing in
2993         MediaPlayerPrivate::prepareToPlay() their behavior is
2994         unchanged. The current set of media test should then be
2995         sufficient to guarantee that this patch does not break anything.
2996
2997         * html/HTMLMediaElement.cpp:
2998         (WebCore::HTMLMediaElement::loadResource):
2999         After the MediaPlayer is created, inform it what the poster URL is.
3000         (WebCore::HTMLMediaElement::updatePlayState):
3001         Add another case where prepareToPlay is called for the platforms
3002         that do not buffer video content automatically.
3003         (WebCore::HTMLMediaElement::couldPlayIfEnoughData)
3004         Same as potentiallyPlaying, except that we don't check for
3005         the readyState being at least HAVE_FUTURE_DATA.
3006         * platform/graphics/MediaPlayer.cpp:
3007         (WebCore::NullMediaPlayerPrivate::canLoadPoster):
3008         Empty implementation for the NullMediaPlayerPrivate.
3009         (WebCore::NullMediaPlayerPrivate::setPoster):
3010         Empty implementation for the NullMediaPlayerPrivate.
3011         (WebCore::MediaPlayer::canLoadPoster):
3012         Proxy to the m_private.
3013         (WebCore::MediaPlayer::setPoster):
3014         Proxy to m_private.
3015         * platform/graphics/MediaPlayer.h:
3016         * platform/graphics/MediaPlayerPrivate.h:
3017         (WebCore::MediaPlayerPrivateInterface::canLoadPoster):
3018         (WebCore::MediaPlayerPrivateInterface::setPoster):
3019         Add new methods that allow the platform player to receive the poster URL.
3020         (WebCore::MediaPlayerPrivateInterface::prepareToPlay):
3021         Notifies the media engine that playback should start. The media engine
3022         should start preparing (e.g. by initializing the player and starting to buffer)
3023         and call back when the state is changed to HAVE_FUTURE_DATA.
3024
3025 2009-10-06  David Levin  <levin@chromium.org>
3026
3027         Reviewed by Oliver Hunt.
3028
3029         StringImpl needs a method to get an instance for another thread which doesn't copy the underlying buffer.
3030         https://bugs.webkit.org/show_bug.cgi?id=30095
3031
3032         All String::copy methods were changed to call either threadsafeCopy or crossThreadString. The method
3033         call was made threadsafeCopy unless I could show that threadsafety wasn't needed.
3034
3035         No visible change in functionality so no new tests.
3036
3037         * dom/MessagePortChannel.cpp:
3038         (WebCore::MessagePortChannel::EventData::EventData):
3039         * loader/WorkerThreadableLoader.cpp:
3040         (WebCore::WorkerThreadableLoader::MainThreadBridge::MainThreadBridge):
3041         * loader/icon/IconDatabase.cpp:
3042         (WebCore::IconDatabase::open):
3043         (WebCore::IconDatabase::iconForPageURL):
3044         (WebCore::IconDatabase::iconURLForPageURL):
3045         (WebCore::IconDatabase::retainIconForPageURL):
3046         (WebCore::IconDatabase::releaseIconForPageURL):
3047         (WebCore::IconDatabase::setIconDataForIconURL):
3048         (WebCore::IconDatabase::setIconURLForPageURL):
3049         (WebCore::IconDatabase::databasePath):
3050         (WebCore::IconDatabase::defaultDatabaseFilename):
3051         * page/SecurityOrigin.cpp:
3052         (WebCore::SecurityOrigin::SecurityOrigin): Since this is used by SecurityOrigin::threadsafeCopy,
3053         it makes threadsafe calls.
3054         (WebCore::SecurityOrigin::threadsafeCopy): The only place that called this
3055         needed a threadsafe method.
3056         * page/SecurityOrigin.h:
3057         * platform/CrossThreadCopier.cpp:
3058         (WebCore::::copy):
3059         * platform/KURL.cpp:
3060         (WebCore::KURL::copy):
3061         * platform/network/HTTPHeaderMap.cpp:
3062         (WebCore::HTTPHeaderMap::copyData):
3063         * platform/network/ResourceErrorBase.cpp:
3064         (WebCore::ResourceErrorBase::copy):
3065         * platform/network/ResourceRequestBase.cpp:
3066         (WebCore::ResourceRequestBase::copyData):
3067         * platform/network/ResourceResponseBase.cpp:
3068         (WebCore::ResourceResponseBase::copyData):
3069         * platform/sql/SQLValue.cpp:
3070         (WebCore::SQLValue::SQLValue):
3071         (WebCore::SQLValue::string):
3072         * platform/sql/SQLValue.h:
3073         (WebCore::SQLValue::SQLValue):
3074         All constructors now initialize the m_number which is a double. Failure to
3075         do so can result in unexpected crashes when it is copied in the copy constructor.
3076         See http://blogs.msdn.com/oldnewthing/archive/2008/07/02/8679191.aspx, I was that colleague.
3077         * platform/text/PlatformString.h:
3078         * platform/text/String.cpp:
3079         (WebCore::String::threadsafeCopy):
3080         (WebCore::String::crossThreadString):
3081         * platform/text/StringImpl.cpp:
3082         Removed StringImpl::substringCopy which was no longer being used anywhere.
3083         (WebCore::StringImpl::threadsafeCopy): Changed the name to indicate that
3084         it is threadsafe.
3085         (WebCore::StringImpl::crossThreadString): The way to get strings for
3086         another thread which is not threadsafe. This shares the underlying buffer
3087         with both strings and gives them a way to do threadsafe refcounting for it.
3088         * platform/text/StringImpl.h:
3089         * storage/ChangeVersionWrapper.cpp:
3090         (WebCore::ChangeVersionWrapper::ChangeVersionWrapper):
3091         * storage/Database.cpp:
3092         (WebCore::updateGuidVersionMap):
3093         (WebCore::Database::Database):
3094         (WebCore::Database::getVersionFromDatabase):
3095         (WebCore::Database::setVersionInDatabase):
3096         (WebCore::Database::version):
3097         (WebCore::Database::setExpectedVersion):
3098         (WebCore::Database::securityOriginCopy):
3099         (WebCore::Database::stringIdentifier):
3100         * storage/DatabaseTracker.cpp:
3101         (WebCore::DatabaseTracker::scheduleNotifyDatabaseChanged):
3102         * storage/OriginQuotaManager.cpp:
3103         (WebCore::OriginQuotaManager::addDatabase):
3104         * storage/SQLError.h:
3105         (WebCore::SQLError::message):
3106         (WebCore::SQLError::SQLError):
3107         * storage/SQLStatement.cpp:
3108         (WebCore::SQLStatement::SQLStatement):
3109         * storage/StorageAreaSync.cpp:
3110         (WebCore::StorageAreaSync::syncTimerFired):
3111         * storage/StorageMap.cpp:
3112         (WebCore::StorageMap::importItem):
3113         * storage/StorageNamespaceImpl.cpp:
3114         (WebCore::StorageNamespaceImpl::StorageNamespaceImpl):
3115         * storage/StorageSyncManager.cpp:
3116         (WebCore::StorageSyncManager::StorageSyncManager):
3117         * workers/DefaultSharedWorkerRepository.cpp:
3118         (WebCore::SharedWorkerProxy::url): Do the copy of the url in a way that is threadsafe.
3119         (WebCore::SharedWorkerProxy::name):
3120         (WebCore::SharedWorkerProxy::SharedWorkerProxy):
3121         (WebCore::DefaultSharedWorkerRepository::getProxy): Do the copy of the url in a way that is threadsafe.
3122         * workers/SharedWorkerThread.cpp:
3123         (WebCore::SharedWorkerThread::SharedWorkerThread):
3124         * workers/WorkerMessagingProxy.cpp:
3125         (WebCore::MessageWorkerContextTask::MessageWorkerContextTask):
3126         (WebCore::MessageWorkerTask::MessageWorkerTask):
3127         (WebCore::WorkerExceptionTask::WorkerExceptionTask):
3128         * workers/WorkerRunLoop.cpp:
3129         (WebCore::WorkerRunLoop::Task::Task):
3130         (WebCore::WorkerRunLoop::postTaskForMode):
3131         * workers/WorkerThread.cpp:
3132         (WebCore::WorkerThreadStartupData::WorkerThreadStartupData):
3133
3134 2009-10-06  Girish Ramakrishnan  <girish@forwardbias.in>
3135
3136         Reviewed by Simon Hausmann.
3137
3138         [Qt] Windowless plugins: Use X Pixmap instead of QPixmap.
3139
3140         This has the following advantages:
3141         1. Allows more sharing of code between gtk and Qt ports in the future
3142         2. QPixmap creates 24-bit by default. We have to later 'upgrade' it to 32-bit.
3143         3. QPixmap may sometime change depth behind our back! This will require us to
3144         update the plugin about the new visual and colormap.
3145         4. We cannot ensure that QPixmap is backed by a X Drawable. For example, with
3146         -graphicssystem raster, QPixmap uses the raster (image) backend.
3147
3148         https://bugs.webkit.org/show_bug.cgi?id=20081
3149
3150         * plugins/PluginView.cpp:
3151         (WebCore::PluginView::PluginView):
3152         * plugins/PluginView.h:
3153         * plugins/qt/PluginViewQt.cpp:
3154         (WebCore::PluginView::updatePluginWidget):
3155         (WebCore::PluginView::paint):
3156         (WebCore::PluginView::platformDestroy):
3157
3158 2009-10-06  Girish Ramakrishnan  <girish@forwardbias.in>
3159
3160         Reviewed by Simon Hausmann.
3161
3162         [Qt] Add support for windowless NPAPI plugins
3163
3164         https://bugs.webkit.org/show_bug.cgi?id=20081
3165
3166         * plugins/PluginView.cpp:
3167         (WebCore::PluginView::setFrameRect):
3168         (WebCore::PluginView::handleEvent):
3169         (WebCore::PluginView::PluginView):
3170         * plugins/PluginView.h:
3171         * plugins/qt/PluginViewQt.cpp:
3172         (WebCore::PluginView::updatePluginWidget):
3173         (WebCore::PluginView::paint):
3174         (WebCore::PluginView::dispatchNPEvent):
3175         (WebCore::setSharedXEventFields):
3176         (WebCore::PluginView::initXEvent):
3177         (WebCore::setXKeyEventSpecificFields):
3178         (WebCore::PluginView::handleKeyboardEvent):
3179         (WebCore::inputEventState):
3180         (WebCore::setXButtonEventSpecificFields):
3181         (WebCore::setXMotionEventSpecificFields):
3182         (WebCore::setXCrossingEventSpecificFields):
3183         (WebCore::PluginView::handleMouseEvent):
3184         (WebCore::PluginView::handleFocusInEvent):
3185         (WebCore::PluginView::handleFocusOutEvent):
3186         (WebCore::PluginView::setNPWindowRect):
3187         (WebCore::PluginView::setNPWindowIfNeeded):
3188         (WebCore::PluginView::getValueStatic):
3189         (WebCore::PluginView::invalidateRect):
3190         (WebCore::PluginView::invalidateRegion):
3191         (WebCore::PluginView::forceRedraw):
3192         (WebCore::getPluginDisplay):
3193         (WebCore::PluginView::platformStart):
3194
3195 2009-10-05  Dirk Schulze  <krit@webkit.org>
3196
3197         Reviewed by Nikolas Zimmermann.
3198
3199         SVG Filters do not support source images besides "sourceGraphic"
3200         [https://bugs.webkit.org/show_bug.cgi?id=6022]
3201
3202         Add support for SourceAlpha to SVG filters.
3203
3204         Test: svg/filters/sourceAlpha.svg
3205
3206         * platform/graphics/filters/SourceAlpha.cpp:
3207         (WebCore::SourceAlpha::calculateEffectRect):
3208         (WebCore::SourceAlpha::apply):
3209         * platform/graphics/filters/SourceAlpha.h:
3210
3211 2009-10-05  John Abd-El-Malek  <jam@chromium.org>
3212
3213         Reviewed by Adam Barth.
3214
3215         Fix reliablity bot crash in DateExtension.
3216         https://bugs.webkit.org/show_bug.cgi?id=30033
3217
3218         There were a few problems using the weak persistent pointers because no one else had a
3219         handle to them.  The new approach stores them as a hidden value on the Date constructor.
3220
3221         * bindings/v8/DateExtension.cpp:
3222         (WebCore::DateExtension::setAllowSleep):
3223         (WebCore::DateExtension::GetNativeFunction):
3224         (WebCore::DateExtension::Setup):
3225         (WebCore::DateExtension::OnSleepDetected):
3226         * bindings/v8/DateExtension.h:
3227         * bindings/v8/V8HiddenPropertyName.cpp:
3228         (WebCore::V8HiddenPropertyName::sleepFunction):
3229         * bindings/v8/V8HiddenPropertyName.h:
3230
3231 2009-10-05  Stephanie Lewis  <slewis@apple.com>
3232
3233         Reviewed by Dan Bernstein.
3234
3235         Crash when trying to load a null stylesheet for a site specific hack. 
3236         https://bugs.webkit.org/show_bug.cgi?id=30105
3237
3238         Created a testcase and tested in browser.  DRT doesn't test
3239         site specific hacks.
3240
3241         * html/HTMLLinkElement.cpp:
3242         (WebCore::HTMLLinkElement::setCSSStyleSheet):
3243
3244 2009-10-05  James Robinson  <jamesr@google.com>
3245
3246         Reviewed by Darin Adler.
3247
3248         Fix forward declaration (struct vs class mismatch)
3249
3250         https://bugs.webkit.org/show_bug.cgi?id=30094
3251
3252         * loader/RedirectScheduler.h:
3253
3254 2009-10-05  Julie Parent  <jparent@chromium.org>
3255
3256         Unreviewed, last Chromium build fix corresponding to revision 49113.
3257         Add include for BeforeLoadEvent to DOMObjectsInclude.h.
3258
3259         * bindings/v8/DOMObjectsInclude.h:
3260
3261 2009-10-05  Simon Fraser  <simon.fraser@apple.com>
3262
3263         Fix Windows build.
3264
3265         * html/HTMLMediaElement.cpp:
3266
3267 2009-10-05  Simon Fraser  <simon.fraser@apple.com>
3268
3269         Fix the build: MediaControllerThemeQT was renamed to MediaControllerThemeQuickTime.
3270
3271         * rendering/RenderThemeMac.mm:
3272         (WebCore::RenderThemeMac::shouldRenderMediaControlPart):
3273
3274 2009-10-05  Pierre d'Herbemont  <pdherbemont@webkit.org>
3275
3276         Reviewed by Simon Fraser
3277         
3278         Support fullscreen in MediaPlayer (Mac)
3279         https://bugs.webkit.org/show_bug.cgi?id=26742
3280
3281         Add a fullscreen button to the <video> controller if the media engine,
3282         and the theme have support for fullscreen, and can show appropriate controls.
3283         Clicking the button calls through the ChromeClient to the WebVideoFullscreenController
3284         in WebKit to do a nice animation to fullscreen, with a custom controller.
3285
3286         * DerivedSources.make:
3287         * WebCore.Video.exp: Added.
3288         New export file for when VIDEO is enabled.
3289         
3290         * WebCore.base.exp: Export WebCore::HTMLNames::videoTag
3291         * WebCore.xcodeproj/project.pbxproj: New files
3292         
3293         * html/HTMLMediaElement.h:
3294         * html/HTMLMediaElement.cpp:
3295         (WebCore::HTMLMediaElement::HTMLMediaElement):
3296         (WebCore::HTMLMediaElement::willRemove):
3297         (WebCore::HTMLMediaElement::screenRect):
3298         (WebCore::HTMLMediaElement::enterFullscreen):
3299         (WebCore::HTMLMediaElement::exitFullscreen):
3300         (WebCore::HTMLMediaElement::platformMedia):
3301         Add fullscreen logic. platformMedia returns a pointer to platform-specific playback data
3302         used for fullscreen.
3303         
3304         * html/HTMLVideoElement.h:
3305         * html/HTMLVideoElement.cpp:
3306         (WebCore::HTMLVideoElement::supportsFullscreen): Check with both the player and the ChromeClient
3307         to see if it's possile to enter fullscreen for this element.
3308         
3309         * page/ChromeClient.h:
3310         (WebCore::ChromeClient::supportsFullscreenForNode):
3311         (WebCore::ChromeClient::enterFullscreenForNode):
3312         (WebCore::ChromeClient::exitFullscreenForNode):
3313         New methods
3314         
3315         * platform/graphics/MediaPlayer.h:
3316         * platform/graphics/MediaPlayer.cpp:
3317         (WebCore::NullMediaPlayerPrivate::platformMedia):
3318         (WebCore::MediaPlayer::platformMedia):
3319         * platform/graphics/MediaPlayerPrivate.h:
3320         (WebCore::MediaPlayerPrivateInterface::platformMedia):
3321         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
3322         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
3323         (WebCore::MediaPlayerPrivate::platformMedia):
3324         (WebCore::MediaPlayerPrivate::supportsFullscreen):
3325         New methods to return platform-specific playback data for fullscreen.
3326         
3327         * rendering/MediaControlElements.cpp:
3328         (WebCore::MediaControlFullscreenButtonElement::defaultEventHandler):
3329         Hook up the fullscreen button.
3330         * rendering/RenderThemeMac.h:
3331         * rendering/RenderThemeMac.mm:
3332         (WebCore::RenderThemeMac::shouldRenderMediaControlPart):
3333         Allow the RenderThemeMac to make a decision about the availability of fullscreen based
3334         on the QuickTime version, since this affects what controls are availabl.e
3335
3336 2009-10-05  Kevin Decker  <kdecker@apple.com>
3337
3338         Export a few more methods from Settings.h
3339         
3340         Rubberstamped by Jon Honeycutt.
3341         
3342         * WebCore.base.exp:
3343
3344 2009-10-05  Dmitry Titov  <dimich@chromium.org>
3345
3346         Reviewed by Darin Adler.
3347
3348         1-char fix for obviously reverse condition.
3349         https://bugs.webkit.org/show_bug.cgi?id=30100
3350         No test since the only difference is a timing of GC.
3351
3352         * bindings/js/ScriptCachedFrameData.cpp:
3353         (WebCore::ScriptCachedFrameData::clear): Revert condition. Almost a typo.
3354
3355 2009-09-30  Kenneth Russell  <kbr@google.com>
3356
3357         Reviewed by Darin Fisher.
3358
3359         Update platform-specific #ifdefs in GraphicsContext3D.h for the
3360         Chromium port.
3361         https://bugs.webkit.org/show_bug.cgi?id=29936
3362
3363         * platform/graphics/GraphicsContext3D.h:
3364         Changed #if PLATFORM(SKIA) to #if PLATFORM(CHROMIUM).
3365
3366 2009-10-05  Dan Bernstein  <mitz@apple.com>
3367
3368         Reviewed by Darin Adler.
3369
3370         REGRESSION (r47440): Inserting text in the middle of content in a scrolled textfield results in painting bugs
3371         <rdar://problem/7269108>
3372         https://bugs.webkit.org/show_bug.cgi?id=29982
3373
3374         Test: fast/repaint/line-in-scrolled-clipped-block.html
3375
3376         * rendering/RenderBlock.cpp:
3377         (WebCore::RenderBlock::layoutBlock): Use the unclipped overflow rect
3378         (including layout overflow) for the repaint rect calculation.
3379
3380 2009-10-05  Drew Wilson  <atwilson@google.com>
3381
3382         Reviewed by David Levin.
3383
3384         Chromium wants to turn off SharedWorkers at runtime
3385         https://bugs.webkit.org/show_bug.cgi?id=29757
3386
3387         * bindings/js/JSDOMWindowCustom.cpp:
3388         (WebCore::JSDOMWindow::sharedWorker):
3389         Now returns jsUndefined if isAvailable() returns false, to allow SharedWorkers to be disabled at runtime.
3390         * workers/DefaultSharedWorkerRepository.cpp:
3391         (WebCore::SharedWorkerRepository::isAvailable):
3392         Made SharedWorkers available by default.
3393         * workers/SharedWorkerRepository.h:
3394         Added definition for SharedWorkerRepository::isAvailable().
3395
3396 2009-10-05  Hironori Bono  <hbono@chromium.org>
3397
3398         Reviewed by Eric Seidel.
3399
3400         A super quick fix for Bug 28710.
3401
3402         https://bugs.webkit.org/show_bug.cgi?id=28710
3403
3404         This change just resets the style sent to addStyleMarkup() to avoid an assertion error
3405         and creates an empty style when computedStyleAtPosition is 0 to avoid a crash.
3406         (This change is nothing but a better-than-crash change.)
3407
3408         Tests: editing/selection/select-crash-001.html
3409                editing/selection/select-crash-002.html
3410
3411         * editing/ApplyStyleCommand.cpp:
3412         (WebCore::editingStyleAtPosition): Resets the style sent to addStyleMarkup() if it is not valid.
3413         * editing/markup.cpp:
3414         (WebCore::createMarkup): Creates an empty style if computedStyleAtPosition is 0.
3415
3416 2009-10-05  Sam Weinig  <sam@webkit.org>
3417
3418         Reviewed by Mark Rowe.
3419
3420         Silence duplicate errors logged for missing getComputedStyle
3421         implementations. Improves the error message as well.
3422
3423         * css/CSSComputedStyleDeclaration.cpp:
3424         (WebCore::logUnimplementedPropertyID):
3425         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3426
3427 2009-10-05  Julie Parent  <jparent@chromium.org>
3428
3429         Unreviewed, Chromium build fix #3.  Add V8BeforeLoadEvent.[cc|h] to derived sources.
3430
3431         * bindings/v8/DerivedSourcesAllInOne.cpp:
3432         * bindings/v8/V8Index.cpp:
3433
3434 2009-10-05  Mark Rowe  <mrowe@apple.com>
3435
3436         Try and fix the GTK build.
3437
3438         * GNUmakefile.am:
3439
3440 2009-10-05  Julie Parent  <jparent@chromium.org>
3441
3442         Unreviewed, Chromium build fix #2.  Add new BEFORELOADEVENT to V8ClassIndex.
3443
3444         * bindings/v8/V8Index.h:
3445
3446 2009-10-05  Julie Parent  <jparent@chromium.org>
3447
3448         Unreviewed, Chromium build fix.  Missing "," after entry for BeforeLoadEvent.idl. 
3449
3450         * WebCore.gypi:
3451
3452 2009-10-05  Dave Hyatt  <hyatt@apple.com>
3453
3454         Reviewed by Sam Weinig.
3455
3456         Add a beforeload event that will be fired before subresources load. (It isn't fired yet.)  The event
3457         has one field, the URL that is going to be requested.  Setting preventDefault will stop the load
3458         from occurring.
3459
3460         * DerivedSources.cpp:
3461         * DerivedSources.make:
3462         * WebCore.gypi:
3463         * WebCore.vcproj/WebCore.vcproj:
3464         * WebCore.xcodeproj/project.pbxproj:
3465         * dom/BeforeLoadEvent.h: Added.
3466         (WebCore::BeforeLoadEvent::create):
3467         (WebCore::BeforeLoadEvent::initBeforeLoadEvent):
3468         (WebCore::BeforeLoadEvent::url):
3469         (WebCore::BeforeLoadEvent::BeforeLoadEvent):
3470         * dom/BeforeLoadEvent.idl: Added.
3471         * dom/EventNames.h:
3472         * page/DOMWindow.idl:
3473
3474 2009-10-05  Priit Laes  <plaes@plaes.org>
3475
3476         Reviewed by Gustavo Noronha.
3477
3478         Add Gentoo-specific paths for searching browser plugins.
3479         https://bugs.webkit.org/show_bug.cgi?id=30088
3480
3481         * plugins/PluginDatabase.cpp:
3482         (WebCore::PluginDatabase::defaultPluginDirectories):
3483
3484 2009-10-02  Chris Marrin  <cmarrin@apple.com>
3485
3486         Reviewed by Adele Peterson.
3487
3488         Add functionality to pause/throttle CSS transitions/animations in a WebView
3489         https://bugs.webkit.org/show_bug.cgi?id=29942
3490
3491         Exporting call from AnimationController
3492
3493         * WebCore.base.exp:
3494
3495 2009-10-05  Kevin Decker  <kdecker@apple.com>
3496
3497         Rubberstamped by Anders Carlsson.
3498         
3499         * WebCore.base.exp: Update export of HaltablePlugin/PluginHalterClient.
3500         * WebCore.xcodeproj/project.pbxproj: Likewise.
3501
3502 2009-10-05  Eric Seidel  <eric@webkit.org>
3503
3504         No review, rolling out r49104.
3505         http://trac.webkit.org/changeset/49104
3506
3507         * html/HTMLInputElement.cpp:
3508         * html/HTMLInputElement.h:
3509         * html/HTMLInputElement.idl:
3510         * html/ValidityState.cpp:
3511         * html/ValidityState.h:
3512         (WebCore::ValidityState::rangeUnderflow):
3513         (WebCore::ValidityState::rangeOverflow):
3514         * rendering/RenderSlider.cpp:
3515         (WebCore::SliderRange::SliderRange):
3516         (WebCore::SliderRange::valueFromElement):
3517
3518 2009-10-05  Kent Tamura  <tkent@chromium.org>
3519
3520         Reviewed by Eric Seidel.
3521
3522         Update style immediately when validation-related values are updated.
3523         https://bugs.webkit.org/show_bug.cgi?id=28868
3524
3525         In order to apply :valid, :invalid, :optional or :required lively,
3526           - call setNeedsStyleRecalc() when properties which can change
3527             willValidate state are updated, and
3528              (Parent form element, name, disabled, readonly)
3529           - call updateValidity() when properties which can change validity
3530             state are updated. (value, pattern, required)
3531
3532         Tests: fast/forms/input-live-pseudo-selectors.html
3533                fast/forms/textarea-live-pseudo-selectors.html
3534
3535         * html/HTMLFormControlElement.cpp:
3536         (WebCore::HTMLFormControlElement::HTMLFormControlElement):
3537         (WebCore::HTMLFormControlElement::parseMappedAttribute):
3538         (WebCore::HTMLFormControlElement::required):
3539         (WebCore::HTMLFormControlElement::updateValidity):
3540         * html/HTMLFormControlElement.h:
3541         * html/HTMLInputElement.cpp:
3542         (WebCore::HTMLInputElement::setInputType):
3543         (WebCore::HTMLInputElement::parseMappedAttribute):
3544         (WebCore::HTMLInputElement::setValue):
3545         (WebCore::HTMLInputElement::setValueFromRenderer):
3546         (WebCore::HTMLInputElement::setFileListFromRenderer):
3547         * html/HTMLTextAreaElement.cpp:
3548         (WebCore::HTMLTextAreaElement::setValue):
3549         * rendering/RenderTextControlMultiLine.cpp:
3550         (WebCore::RenderTextControlMultiLine::subtreeHasChanged):
3551
3552 2009-10-05  Kent Tamura  <tkent@chromium.org>
3553
3554         Reviewed by Darin Adler.
3555
3556         Implement min/max attributes, ValidityState.rangeUnderflow and
3557         ValidityState.rangeOverflow for <input type=number> and <input type=range>
3558         https://bugs.webkit.org/show_bug.cgi?id=29069
3559
3560         Tests: fast/forms/ValidityState-rangeOverflow-number.html
3561                fast/forms/ValidityState-rangeOverflow-range.html
3562                fast/forms/ValidityState-rangeUnderflow-number.html
3563                fast/forms/ValidityState-rangeUnderflow-range.html
3564                fast/forms/input-minmax.html
3565
3566         * html/HTMLInputElement.cpp:
3567         (WebCore::HTMLInputElement::rangeUnderflow):
3568         (WebCore::HTMLInputElement::rangeOverflow):
3569         (WebCore::HTMLInputElement::rangeMinimum):
3570         (WebCore::HTMLInputElement::rangeMaximum):
3571         * html/HTMLInputElement.h:
3572         * html/HTMLInputElement.idl:
3573         * html/ValidityState.cpp:
3574         (WebCore::ValidityState::rangeUnderflow):
3575         (WebCore::ValidityState::rangeOverflow):
3576         * html/ValidityState.h:
3577         * rendering/RenderSlider.cpp:
3578         (WebCore::SliderRange::SliderRange):
3579         (WebCore::SliderRange::valueFromElement):
3580
3581 2009-10-05  Kent Tamura  <tkent@chromium.org>
3582
3583         Reviewed by Eric Seidel.
3584
3585         Introduces
3586          - new CSS pseudo selector: "-webkit-input-list-button"
3587          - new CSS apperance type: "list-button"
3588          - new ControlPart value: "ListButtonPart"
3589         for the UI of the list attribute of the input element, and adds
3590         implementation to draw ListButtonPart on Mac.
3591         The code is guarded by ENABLE(DATALIST).
3592
3593         https://bugs.webkit.org/show_bug.cgi?id=27794
3594
3595         Test: platform/mac/fast/forms/input-list-button-size.html
3596
3597         * css/CSSPrimitiveValueMappings.h:
3598         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
3599         * css/CSSSelector.cpp:
3600         (WebCore::CSSSelector::extractPseudoType):
3601         * css/CSSSelector.h:
3602         (WebCore::CSSSelector::):