2011-04-25 Adam Klein <adamk@chromium.org>
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2011-04-25  Adam Klein  <adamk@chromium.org>
2
3         Reviewed by James Robinson.
4
5         Fix OwnPtr strict errors in some SVG classes.
6         https://bugs.webkit.org/show_bug.cgi?id=59395
7
8         * rendering/style/SVGRenderStyleDefs.cpp:
9         (WebCore::StyleShadowSVGData::StyleShadowSVGData):
10         * svg/SVGSVGElement.cpp:
11         (WebCore::SVGSVGElement::SVGSVGElement):
12         * svg/SVGStyledTransformableElement.cpp:
13         (WebCore::SVGStyledTransformableElement::supplementalTransform):
14         * svg/SVGTextElement.cpp:
15         (WebCore::SVGTextElement::supplementalTransform):
16         * svg/graphics/SVGImage.cpp:
17         (WebCore::SVGImage::dataChanged):
18
19 2011-04-25  Adam Barth  <abarth@webkit.org>
20
21         Re-land changes to ValidationMessage.
22
23         * html/ValidationMessage.cpp:
24         (WebCore::ValidationMessage::setMessage):
25         (WebCore::ValidationMessage::setMessageDOMAndStartTimer):
26         (WebCore::ValidationMessage::requestToHideMessage):
27
28 2011-04-25  Ojan Vafai  <ojan@chromium.org>
29
30         Reviewed by James Robinson.
31
32         fix OwnPtr strict error in FrameView.cpp
33         https://bugs.webkit.org/show_bug.cgi?id=59402
34
35         * page/FrameView.cpp:
36         (WebCore::FrameView::FrameView):
37         (WebCore::FrameView::addWidgetToUpdate):
38
39 2011-04-25  Adam Klein  <adamk@chromium.org>
40
41         Unreviewed, rolling out r84844.
42         http://trac.webkit.org/changeset/84844
43         https://bugs.webkit.org/show_bug.cgi?id=59395
44
45         Checked in too much.
46
47         * rendering/style/SVGRenderStyleDefs.cpp:
48         (WebCore::StyleShadowSVGData::StyleShadowSVGData):
49         * svg/SVGDocumentExtensions.cpp:
50         (WebCore::SVGDocumentExtensions::removePendingResource):
51         * svg/SVGSVGElement.cpp:
52         (WebCore::SVGSVGElement::SVGSVGElement):
53         * svg/SVGStyledTransformableElement.cpp:
54         (WebCore::SVGStyledTransformableElement::supplementalTransform):
55         * svg/SVGTextElement.cpp:
56         (WebCore::SVGTextElement::supplementalTransform):
57         * svg/graphics/SVGImage.cpp:
58         (WebCore::SVGImage::dataChanged):
59
60 2011-04-25  Adrienne Walker  <enne@google.com>
61
62         Reviewed by David Levin.
63
64         Make ActiveDOMCallback play nice with OwnPtr strict mode
65         https://bugs.webkit.org/show_bug.cgi?id=59398
66
67         * bindings/generic/ActiveDOMCallback.cpp:
68         (WebCore::ActiveDOMCallback::ActiveDOMCallback):
69
70 2011-04-25  Adam Klein  <adamk@chromium.org>
71
72         Reviewed by James Robinson.
73
74         Fix OwnPtr strict errors in some SVG classes.
75         https://bugs.webkit.org/show_bug.cgi?id=59395
76
77         * rendering/style/SVGRenderStyleDefs.cpp:
78         (WebCore::StyleShadowSVGData::StyleShadowSVGData):
79         * svg/SVGSVGElement.cpp:
80         (WebCore::SVGSVGElement::SVGSVGElement):
81         * svg/SVGStyledTransformableElement.cpp:
82         (WebCore::SVGStyledTransformableElement::supplementalTransform):
83         * svg/SVGTextElement.cpp:
84         (WebCore::SVGTextElement::supplementalTransform):
85         * svg/graphics/SVGImage.cpp:
86         (WebCore::SVGImage::dataChanged):
87
88 2011-04-25  James Robinson  <jamesr@chromium.org>
89
90         Unreviewed, rolling out r84835.
91         http://trac.webkit.org/changeset/84835
92         https://bugs.webkit.org/show_bug.cgi?id=59394
93
94         Breaks compile because Deque<OwnPtr> doesn't work
95
96         * dom/XMLDocumentParserLibxml2.cpp:
97         (WebCore::PendingCallbacks::~PendingCallbacks):
98         (WebCore::PendingCallbacks::appendStartElementNSCallback):
99         (WebCore::PendingCallbacks::appendEndElementNSCallback):
100         (WebCore::PendingCallbacks::appendCharactersCallback):
101         (WebCore::PendingCallbacks::appendProcessingInstructionCallback):
102         (WebCore::PendingCallbacks::appendCDATABlockCallback):
103         (WebCore::PendingCallbacks::appendCommentCallback):
104         (WebCore::PendingCallbacks::appendInternalSubsetCallback):
105         (WebCore::PendingCallbacks::appendErrorCallback):
106         (WebCore::XMLDocumentParser::XMLDocumentParser):
107         * html/ValidationMessage.cpp:
108         (WebCore::ValidationMessage::setMessage):
109         (WebCore::ValidationMessage::setMessageDOMAndStartTimer):
110         (WebCore::ValidationMessage::requestToHideMessage):
111
112 2011-04-25  James Robinson  <jamesr@chromium.org>
113
114         Reviewed by Sam Weinig.
115
116         Fix OwnPtr strict mode violation in ImageBufferCG
117         https://bugs.webkit.org/show_bug.cgi?id=59396
118
119         * platform/graphics/cg/ImageBufferCG.cpp:
120         (WebCore::ImageBuffer::ImageBuffer):
121
122 2011-04-25  Huang Dongsung  <luxtella@company100.net>
123
124         Reviewed by Dirk Schulze.
125
126         [Skia] Remove an unused local variable in PlatformContextSkia::readbackHardwareToSoftware().
127         https://bugs.webkit.org/show_bug.cgi?id=59308
128
129         An unused local variable is created and even allocates heap memory.
130
131         * platform/graphics/skia/PlatformContextSkia.cpp:
132         (WebCore::PlatformContextSkia::readbackHardwareToSoftware):
133
134 2011-04-25  Geoffrey Garen  <ggaren@apple.com>
135
136         Qt build fix: Updated files not used by other ports for rename.
137
138         * bindings/js/JSTouchCustom.cpp:
139         (WebCore::toJSNewlyCreated):
140         * bindings/js/JSTouchListCustom.cpp:
141         (WebCore::toJSNewlyCreated):
142
143 2011-04-25  Adrienne Walker  <enne@google.com>
144
145         Reviewed by David Levin.
146
147         WebCore/css/CSS* files should play nice with strict OwnPtrs
148         https://bugs.webkit.org/show_bug.cgi?id=59382
149
150         * css/CSSFontFaceSource.cpp:
151         (WebCore::CSSFontFaceSource::getFontData):
152         * css/CSSParser.cpp:
153         (WebCore::CSSParser::addProperty):
154         (WebCore::CSSParser::parseValue):
155
156 2011-04-25  Adam Barth  <abarth@webkit.org>
157
158         Reviewed by James Robinson.
159
160         ValidationMessage and XMLDocumentParserLibxml2 should play nice with strict OwnPtrs
161         https://bugs.webkit.org/show_bug.cgi?id=59394
162
163         * dom/XMLDocumentParserLibxml2.cpp:
164         (WebCore::PendingCallbacks::PendingCallbacks):
165         (WebCore::PendingCallbacks::appendStartElementNSCallback):
166         (WebCore::PendingCallbacks::appendEndElementNSCallback):
167         (WebCore::PendingCallbacks::appendCharactersCallback):
168         (WebCore::PendingCallbacks::appendProcessingInstructionCallback):
169         (WebCore::PendingCallbacks::appendCDATABlockCallback):
170         (WebCore::PendingCallbacks::appendCommentCallback):
171         (WebCore::PendingCallbacks::appendInternalSubsetCallback):
172         (WebCore::PendingCallbacks::appendErrorCallback):
173         (WebCore::XMLDocumentParser::XMLDocumentParser):
174         * html/ValidationMessage.cpp:
175         (WebCore::ValidationMessage::setMessage):
176         (WebCore::ValidationMessage::setMessageDOMAndStartTimer):
177         (WebCore::ValidationMessage::requestToHideMessage):
178
179 2011-04-25  James Robinson  <jamesr@chromium.org>
180
181         Reviewed by Adam Barth.
182
183         Fix OwnPtr strictness issues in WebCore/inspector/
184         https://bugs.webkit.org/show_bug.cgi?id=59387
185
186         * inspector/InspectorAgent.cpp:
187         (WebCore::InspectorAgent::InspectorAgent):
188         * inspector/InspectorController.cpp:
189         (WebCore::InspectorController::InspectorController):
190         * inspector/InspectorStyleSheet.cpp:
191         (WebCore::InspectorStyleSheet::ensureSourceData):
192
193 2011-04-25  Geoffrey Garen  <ggaren@apple.com>
194
195         Reviewed by Beth Dakin.
196
197         Removed XPathNamespace because it was unused
198         https://bugs.webkit.org/show_bug.cgi?id=59381
199         
200         This allows us to make Node::ownerDocument() non-virtual, though it has
201         the unhappy side-effect of rebuilding the world.
202
203         * CMakeLists.txt:
204         * GNUmakefile.list.am:
205         * WebCore.gypi:
206         * WebCore.pro:
207         * WebCore.vcproj/WebCore.vcproj:
208         * WebCore.xcodeproj/project.pbxproj: Bye bye dead code.
209
210         * dom/Node.h: Hello fast code!
211
212         * xml/XPathNamespace.cpp: Removed.
213         * xml/XPathNamespace.h: Removed.
214
215 2011-04-25  Adam Barth  <abarth@webkit.org>
216
217         Reviewed by Darin Adler.
218
219         HistoryItemMac should play nice with OwnPtrs
220         https://bugs.webkit.org/show_bug.cgi?id=59388
221
222         * history/mac/HistoryItemMac.mm:
223         (WebCore::HistoryItem::setTransientProperty):
224
225 2011-04-25  David Levin  <levin@chromium.org>
226
227         Reviewed by Kenneth Russell.
228
229         Fix strict OwnPtrs in ContextMenuController.cpp
230         https://bugs.webkit.org/show_bug.cgi?id=59375
231
232         * page/ContextMenuController.cpp:
233         (WebCore::ContextMenuController::createContextMenu):
234         (WebCore::separatorItem):
235
236 2011-04-25  Adam Barth  <abarth@webkit.org>
237
238         Reviewed by Darin Adler.
239
240         CheckedRadioButton should play nice with strict OwnPtr
241         https://bugs.webkit.org/show_bug.cgi?id=59386
242
243         * dom/CheckedRadioButtons.cpp:
244         (WebCore::CheckedRadioButtons::addButton):
245
246 2011-04-25  Adam Barth  <abarth@webkit.org>
247
248         Reviewed by David Levin.
249
250         Resource*.cpp should play nice with strict OwnPtrs
251         https://bugs.webkit.org/show_bug.cgi?id=59383
252
253         * bridge/runtime_method.cpp:
254         (JSC::RuntimeMethod::RuntimeMethod):
255         * platform/network/ResourceHandle.cpp:
256         (WebCore::ResourceHandle::ResourceHandle):
257         * platform/network/ResourceResponseBase.cpp:
258         (WebCore::ResourceResponseBase::adopt):
259         (WebCore::ResourceResponseBase::copyData):
260
261 2011-04-25  Adam Barth  <abarth@webkit.org>
262
263         Reviewed by David Levin.
264
265         Page*.cpp and objc_runtime.mm should play nice with strict OwnPtrs
266         https://bugs.webkit.org/show_bug.cgi?id=59374
267
268         * bridge/objc/objc_runtime.mm:
269         (JSC::Bindings::callObjCFallbackObject):
270         * page/Page.cpp:
271         (WebCore::Page::Page):
272         (WebCore::Page::initGroup):
273         * page/PageGroup.cpp:
274         (WebCore::PageGroup::addUserScriptToWorld):
275         (WebCore::PageGroup::addUserStyleSheetToWorld):
276         * page/mac/PageMac.cpp:
277         (WebCore::Page::addSchedulePair):
278
279 2011-04-25  Geoffrey Garen  <ggaren@apple.com>
280
281         Build fix: This time for sure!
282         
283         * dom/make_names.pl:
284
285 2011-04-25  Geoffrey Garen  <ggaren@apple.com>
286
287         Build fix: Let's edit the script instead of the autogenrated file. That
288         way, our change will stand the test of time.
289
290         * dom/make_names.pl:
291
292 2011-04-25  Adam Barth  <abarth@webkit.org>
293
294         Reviewed by David Levin.
295
296         Fix strict OwnPtrs in HTMLMediaElement and HTTPHeaderMap
297         https://bugs.webkit.org/show_bug.cgi?id=59368
298
299         * html/HTMLMediaElement.cpp:
300         (WebCore::HTMLMediaElement::HTMLMediaElement):
301         * platform/network/HTTPHeaderMap.cpp:
302         (WebCore::HTTPHeaderMap::copyData):
303
304 2011-04-25  James Robinson  <jamesr@chromium.org>
305
306         Reviewed by Adam Barth.
307
308         Fix strict OwnPtr violations in Render*.cpp
309         https://bugs.webkit.org/show_bug.cgi?id=59361
310
311         * rendering/RenderBlock.cpp:
312         (WebCore::RenderBlock::RenderBlock):
313         (WebCore::RenderBlock::finishDelayUpdateScrollInfo):
314         * rendering/RenderBox.cpp:
315         (WebCore::RenderBox::addLayoutOverflow):
316         (WebCore::RenderBox::addVisualOverflow):
317         * rendering/RenderButton.cpp:
318         (WebCore::RenderButton::styleDidChange):
319         * rendering/RenderLayer.cpp:
320         (WebCore::RenderLayer::updateTransform):
321         (WebCore::RenderLayer::paintChildLayerIntoColumns):
322         (WebCore::RenderLayer::hitTestChildLayerColumns):
323         (WebCore::RenderLayer::ensureBacking):
324         * rendering/RenderTable.cpp:
325         (WebCore::RenderTable::styleDidChange):
326         * rendering/RenderView.cpp:
327         (WebCore::RenderView::compositor):
328         * rendering/style/RenderStyle.cpp:
329         (WebCore::RenderStyle::addCachedPseudoStyle):
330         (WebCore::RenderStyle::accessCounterDirectives):
331         (WebCore::RenderStyle::accessAnimations):
332         (WebCore::RenderStyle::accessTransitions):
333         * rendering/svg/RenderSVGResourceFilter.cpp:
334         (WebCore::RenderSVGResourceFilter::applyResource):
335         * rendering/svg/SVGResources.cpp:
336         (WebCore::SVGResources::SVGResources):
337
338 2011-04-25  Adam Barth  <abarth@webkit.org>
339
340         Attempt to fix the compile.
341
342         * platform/graphics/MediaPlayer.cpp:
343         (WebCore::MediaPlayer::loadWithNextMediaEngine):
344
345 2011-04-25  Geoffrey Garen  <ggaren@apple.com>
346
347         Rubber-stamped by Beth Dakin.
348
349         Merged CREATE_DOM_NODE_WRAPPER and CREATE_DOM_OBJECT_WRAPPER into 
350         CREATE_DOM_WRAPPER because there's no meaningful difference between
351         them anymore.
352
353         * bindings/js/JSCDATASectionCustom.cpp:
354         (WebCore::toJSNewlyCreated):
355         * bindings/js/JSCSSRuleCustom.cpp:
356         (WebCore::toJS):
357         * bindings/js/JSCSSValueCustom.cpp:
358         (WebCore::toJS):
359         * bindings/js/JSDOMBinding.h:
360         * bindings/js/JSDocumentCustom.cpp:
361         (WebCore::toJS):
362         * bindings/js/JSElementCustom.cpp:
363         (WebCore::toJSNewlyCreated):
364         * bindings/js/JSEventCustom.cpp:
365         (WebCore::toJS):
366         * bindings/js/JSHTMLCollectionCustom.cpp:
367         (WebCore::toJS):
368         * bindings/js/JSImageDataCustom.cpp:
369         (WebCore::toJS):
370         * bindings/js/JSNodeCustom.cpp:
371         (WebCore::createWrapperInline):
372         * bindings/js/JSSVGPathSegCustom.cpp:
373         (WebCore::toJS):
374         * bindings/js/JSStyleSheetCustom.cpp:
375         (WebCore::toJS):
376         * bindings/js/JSTextCustom.cpp:
377         (WebCore::toJSNewlyCreated):
378         * bindings/js/JSWebKitCSSMatrixCustom.cpp:
379         (WebCore::JSWebKitCSSMatrixConstructor::constructJSWebKitCSSMatrix):
380         * bindings/js/JSWebSocketCustom.cpp:
381         (WebCore::JSWebSocketConstructor::constructJSWebSocket):
382         * bindings/js/JSXMLHttpRequestCustom.cpp:
383         (WebCore::JSXMLHttpRequestConstructor::constructJSXMLHttpRequest):
384         * bindings/js/JSXSLTProcessorCustom.cpp:
385         (WebCore::JSXSLTProcessorConstructor::constructJSXSLTProcessor):
386
387 2011-04-25  Adam Barth  <abarth@webkit.org>
388
389         Reviewed by James Robinson.
390
391         HTMLDocumentParser should play nice with OwnPtrs
392         https://bugs.webkit.org/show_bug.cgi?id=59363
393
394         * html/parser/HTMLDocumentParser.cpp:
395         (WebCore::HTMLDocumentParser::pumpTokenizer):
396
397 2011-04-25  Adam Barth  <abarth@webkit.org>
398
399         Reviewed by James Robinson.
400
401         Frame.cpp should work with strict OwnPtrs
402         https://bugs.webkit.org/show_bug.cgi?id=59360
403
404         * page/Frame.cpp:
405         (WebCore::createRegExpForLabels):
406
407 2011-04-25  Adam Barth  <abarth@webkit.org>
408
409         Reviewed by David Levin.
410
411         Fix strict OwnPtr in Element.cpp
412         https://bugs.webkit.org/show_bug.cgi?id=59357
413
414         * dom/NodeRareData.h:
415         (WebCore::NodeRareData::ensureEventTargetData):
416
417 2011-04-25  Adam Barth  <abarth@webkit.org>
418
419         Reviewed by David Levin.
420
421         Fix strict OwnPtr issues in Media*.cpp
422         https://bugs.webkit.org/show_bug.cgi?id=59354
423
424         There's still a tricky case in MediaPlayer.cpp, but we'll worry about
425         that later.
426
427         * css/MediaQueryMatcher.cpp:
428         (WebCore::MediaQueryMatcher::addListener):
429         * dom/Document.cpp:
430         * platform/graphics/MediaPlayer.cpp:
431         (WebCore::createNullMediaPlayer):
432
433 2011-04-25  James Robinson  <jamesr@chromium.org>
434
435         Reviewed by David Levin.
436
437         Fix strict OwnPtr violations in ListHashSet and RenderLayerCompositor
438         https://bugs.webkit.org/show_bug.cgi?id=59353
439
440         * rendering/RenderLayerCompositor.cpp:
441         (WebCore::RenderLayerCompositor::RenderLayerCompositor):
442
443 2011-04-25  Adam Barth  <abarth@webkit.org>
444
445         Reviewed by James Robinson.
446
447         Worker*.cpp should work with strict OwnPtrs
448         https://bugs.webkit.org/show_bug.cgi?id=59346
449
450         * inspector/WorkerInspectorController.cpp:
451         (WebCore::WorkerInspectorController::WorkerInspectorController):
452         * workers/WorkerContext.cpp:
453         (WebCore::WorkerContext::WorkerContext):
454         * workers/WorkerRunLoop.cpp:
455         (WebCore::WorkerRunLoop::WorkerRunLoop):
456         * workers/WorkerScriptLoader.cpp:
457         (WebCore::WorkerScriptLoader::createResourceRequest):
458
459 2011-04-25  James Robinson  <jamesr@chromium.org>
460
461         Reviewed by Adam Barth.
462
463         Remove bad use of OwnPtr::set() in IconDatabase.cpp
464         https://bugs.webkit.org/show_bug.cgi?id=59344
465
466         Needed for strict OwnPtr compliance.
467
468         * loader/icon/IconDatabase.cpp:
469         (WebCore::readySQLiteStatement):
470
471 2011-04-25  Adam Barth  <abarth@webkit.org>
472
473         Reviewed by Maciej Stachowiak.
474
475         ImageBuffer.h should work with strict OwnPtrs
476         https://bugs.webkit.org/show_bug.cgi?id=59341
477
478         This patch is to prepare for the strict OwnPtr hack-a-thon.
479
480         * platform/graphics/ImageBuffer.h:
481         (WebCore::ImageBuffer::create):
482
483 2011-04-25  Steve Falkenburg  <sfalken@apple.com>
484
485         Reviewed by Brian Weinstein.
486
487         WebCore build on Windows should include windows.h in its precompiled header to speed builds
488         https://bugs.webkit.org/show_bug.cgi?id=59339
489
490         windows.h is included by several of the underlying wtf headers, including Atomics.h and
491         ThreadingPrimitives.h anyway, so include it in the WebCorePrefix.h to speed up compilation.
492         
493         On my 8 core Mac Pro, this reduces a clean rebuild of debug WebCore from 8 minutes to 7 minutes
494         (a 12% speedup).
495
496         * WebCorePrefix.h: Include windows.h
497
498 2011-04-25  Martin Robinson  <mrobinson@igalia.com>
499
500         Reviewed by Xan Lopez.
501
502         [GTK] Crash in WebCore::FrameView::notifyPageThatContentAreaWillPaint()
503         https://bugs.webkit.org/show_bug.cgi?id=59311
504
505         * platform/gtk/MainFrameScrollbarGtk.cpp:
506         (MainFrameScrollbarGtk::attachAdjustment): Before connecting an adjustment to a scrollbar
507         disconnect any lingering signal handlers. This prevents an adjustment from controlling the
508         active ScrollView and some zombie ScrollView.
509
510 2011-04-25  Geoffrey Garen  <ggaren@apple.com>
511
512         Another shot at fixing the EFL build.
513
514         * UseJSC.cmake:
515         * bindings/js/JSDOMBinding.cpp:
516
517 2011-04-25  Geoffrey Garen  <ggaren@apple.com>
518
519         Try to fix EFL build.
520
521         * UseJSC.cmake: Added a missing file.
522
523 2011-04-25  Geoffrey Garen  <ggaren@apple.com>
524
525         Reviewed by Oliver Hunt.
526
527         Removed a use of markDOMObjectWrapper: ActiveDOMObjects, Workers, and MessagePorts
528         https://bugs.webkit.org/show_bug.cgi?id=59333
529
530         * WebCore.xcodeproj/project.pbxproj: Added .idl files for easier editing.
531
532         * bindings/js/JSDOMBinding.cpp:
533         * bindings/js/JSDOMBinding.h:
534         * bindings/js/JSDocumentCustom.cpp:
535         * bindings/js/JSWorkerContextCustom.cpp:
536         (WebCore::JSWorkerContext::visitChildren): Removed now-unused functions.
537
538         * bindings/scripts/CodeGeneratorJS.pm: Added support for ActiveDOMObject
539         lifetime management.
540
541         * dom/Document.idl: No need for a custom mark function anymore, since
542         ActiveDOMObjets now manage their own lifetimes.
543
544         * dom/MessagePort.cpp:
545         (WebCore::MessagePort::hasPendingActivity): Correctly report that we
546         have pending activity when we're remotely entangled, instead of relying
547         on our clients to know this about us and do the check for us.
548
549         * dom/MessagePort.h: FIXME!
550
551         * dom/MessagePort.idl:
552         * fileapi/DOMFileSystem.idl:
553         * fileapi/FileReader.idl:
554         * fileapi/FileWriter.idl:
555         * notifications/Notification.idl:
556         * notifications/NotificationCenter.idl:
557         * page/EventSource.idl:
558         * storage/IDBDatabase.idl:
559         * storage/IDBRequest.idl:
560         * storage/IDBTransaction.idl:
561         * webaudio/AudioContext.idl:
562         * websockets/WebSocket.idl:
563         * workers/AbstractWorker.idl:
564         * workers/SharedWorker.idl:
565         * workers/Worker.idl: Opt in to ActiveDOMObject lifetime management.
566
567         * workers/WorkerContext.cpp:
568         (WebCore::WorkerContext::hasPendingActivity): No need to make up for
569         MessagePort::hasPendingActivity being wrong anymore, since it's now right.
570
571         * xml/XMLHttpRequest.idl: Opt in to ActiveDOMObject lifetime management.
572
573 2011-04-25  Yury Semikhatsky  <yurys@chromium.org>
574
575         Reviewed by Pavel Feldman.
576
577         Web Inspector: worker messages should be routed to corresponding worker front-end
578         https://bugs.webkit.org/show_bug.cgi?id=59323
579
580         Added WorkerManager which is responsible for routing messages between
581         Page inspector front-end and Worker inspector front-ends.
582
583         * WebCore.gypi:
584         * inspector/front-end/WebKit.qrc:
585         * inspector/front-end/WorkerManager.js: Added.
586         (WebInspector.WorkerManager):
587         (WebInspector.WorkerManager.loaded.InspectorFrontendHost.sendMessageToBackend):
588         (WebInspector.WorkerManager.loaded.InspectorFrontendHost.loaded):
589         (WebInspector.WorkerManager.loaded):
590         (WebInspector.WorkerFrontendStub):
591         (WebInspector.WorkerFrontendStub.prototype._receiveMessage):
592         (WebInspector.WorkerDispatcher):
593         (WebInspector.WorkerDispatcher.prototype._receiveMessage):
594         (WebInspector.WorkerDispatcher.prototype.workerCreated):
595         (WebInspector.WorkerDispatcher.prototype.dispatchMessageFromWorker):
596         * inspector/front-end/inspector.html:
597         * inspector/front-end/inspector.js:
598         (WebInspector.loaded):
599
600 2011-04-25  Annie Sullivan  <sullivan@chromium.org>
601
602         Reviewed by Pavel Feldman.
603
604         Web Inspector: [Resources panel] Should be easy to copy data.
605         https://bugs.webkit.org/show_bug.cgi?id=45662
606
607         Adds context menu items to copy resource location, resource request headers, and resource response headers.
608
609         * inspector/front-end/NetworkPanel.js:
610         (WebInspector.NetworkPanel.prototype._contextMenu): Add new items to context menu.
611         (WebInspector.NetworkPanel.prototype._exportLocation): Copy resource location to clipboard.
612         (WebInspector.NetworkPanel.prototype._exportRequestHeaders): Copy resource request headers to clipboard.
613         (WebInspector.NetworkPanel.prototype._exportResponseHeaders): Copy resource response headers to clipboard.
614         * inspector/front-end/Resource.js:
615         (WebInspector.Resource.prototype.get requestHeadersText): If _requestHeadersText is undefined, generate it from requestHeaders.
616         (WebInspector.Resource.prototype.get responseHeadersText): If _responseHeadersText is undefined, generate it form responseHeaders.
617
618 2011-04-25  Alexander Pavlov  <apavlov@chromium.org>
619
620         Reviewed by Yury Semikhatsky.
621
622         Web Inspector: CSS is parsed improperly when saved in UTF-8 with a BOM
623         https://bugs.webkit.org/show_bug.cgi?id=59322
624
625         Use TextResourceDecoder to determine external stylesheet charsets correctly.
626
627         Test: inspector/styles/parse-utf8-bom.html
628
629         * inspector/InspectorStyleSheet.cpp:
630         (WebCore::InspectorStyleSheet::originalStyleSheetText):
631
632 2011-04-25  Pavel Feldman  <pfeldman@google.com>
633
634         Not reviewed: Inspector.json cleanup.
635
636         * inspector/Inspector.json:
637
638 2011-04-25  Yury Semikhatsky  <yurys@chromium.org>
639
640         Reviewed by Pavel Feldman.
641
642         Web Inspector: introduce InspectorWorkerAgent
643         https://bugs.webkit.org/show_bug.cgi?id=59320
644
645         InspectorWorkerAgent is responsible for routing inspector messages
646         between worker context inspector agents and corresponding worker
647         inspector front-end.
648
649         * CMakeLists.txt:
650         * GNUmakefile.list.am:
651         * WebCore.gypi:
652         * WebCore.pro:
653         * WebCore.vcproj/WebCore.vcproj:
654         * WebCore.xcodeproj/project.pbxproj:
655         * inspector/CodeGeneratorInspector.pm:
656         * inspector/Inspector.json:
657         * inspector/InspectorAgent.cpp:
658         (WebCore::InspectorAgent::InspectorAgent):
659         (WebCore::InspectorAgent::setFrontend):
660         (WebCore::InspectorAgent::disconnectFrontend):
661         * inspector/InspectorAgent.h:
662         (WebCore::InspectorAgent::workerAgent):
663         * inspector/InspectorController.cpp:
664         (WebCore::InspectorController::connectFrontend):
665         (WebCore::InspectorController::disconnectFrontend):
666         * inspector/InspectorInstrumentation.cpp:
667         (WebCore::InspectorInstrumentation::didStartWorkerContextImpl):
668         * inspector/InspectorInstrumentation.h:
669         (WebCore::InspectorInstrumentation::willStartWorkerContext):
670         (WebCore::InspectorInstrumentation::didStartWorkerContext):
671         * inspector/InspectorWorkerAgent.cpp: Added.
672         (WebCore::InspectorWorkerAgent::WorkerFrontendChannel::WorkerFrontendChannel):
673         (WebCore::InspectorWorkerAgent::WorkerFrontendChannel::~WorkerFrontendChannel):
674         (WebCore::InspectorWorkerAgent::WorkerFrontendChannel::id):
675         (WebCore::InspectorWorkerAgent::WorkerFrontendChannel::inspectorProxy):
676         (WebCore::InspectorWorkerAgent::WorkerFrontendChannel::sendMessageToFrontend):
677         (WebCore::InspectorWorkerAgent::create):
678         (WebCore::InspectorWorkerAgent::InspectorWorkerAgent):
679         (WebCore::InspectorWorkerAgent::~InspectorWorkerAgent):
680         (WebCore::InspectorWorkerAgent::setFrontend):
681         (WebCore::InspectorWorkerAgent::clearFrontend):
682         (WebCore::InspectorWorkerAgent::dispatchMessageOnWorkerInspector):
683         (WebCore::InspectorWorkerAgent::didStartWorkerContext):
684         * inspector/InspectorWorkerAgent.h: Added.
685         * inspector/InstrumentingAgents.h:
686         (WebCore::InstrumentingAgents::InstrumentingAgents):
687         (WebCore::InstrumentingAgents::inspectorWorkerAgent):
688         (WebCore::InstrumentingAgents::setInspectorWorkerAgent):
689         * inspector/WorkerInspectorController.cpp:
690         (WebCore::WorkerInspectorController::connectFrontend):
691         * inspector/generate-inspector-idl:
692         * workers/Worker.cpp:
693         (WebCore::Worker::notifyFinished):
694         * workers/WorkerContextInspectorProxy.h: Added. Platform-specific transport for inspector
695         messages sent from the inspected page worker agent to the worker context inspector agents.
696         (WebCore::WorkerContextInspectorProxy::connectFrontend):
697         (WebCore::WorkerContextInspectorProxy::disconnectFrontend):
698         (WebCore::WorkerContextInspectorProxy::sendMessageToWorkerContextInspector):
699         (WebCore::WorkerContextInspectorProxy::~WorkerContextInspectorProxy):
700         * workers/WorkerContextProxy.h:
701         (WebCore::WorkerContextProxy::inspectorProxy):
702
703 2011-04-25  Pavel Feldman  <pfeldman@google.com>
704
705         Reviewed by Yury Semikhatsky.
706
707         Web Inspector: move Frame and Resource Tree management into the Page agent.
708         https://bugs.webkit.org/show_bug.cgi?id=59321
709
710         Network agent should only handle network-related activities.
711         Frame structure should be managed by the Page agent instead.
712
713         * inspector/Inspector.json:
714         * inspector/InspectorAgent.cpp:
715         (WebCore::InspectorAgent::InspectorAgent):
716         * inspector/InspectorDOMAgent.cpp:
717         (WebCore::InspectorDOMAgent::InspectorDOMAgent):
718         (WebCore::InspectorDOMAgent::setFrontend):
719         (WebCore::InspectorDOMAgent::restore):
720         (WebCore::InspectorDOMAgent::highlightFrame):
721         * inspector/InspectorDOMAgent.h:
722         (WebCore::InspectorDOMAgent::create):
723         * inspector/InspectorInstrumentation.cpp:
724         (WebCore::InspectorInstrumentation::domContentLoadedEventFiredImpl):
725         (WebCore::InspectorInstrumentation::loadEventFiredImpl):
726         (WebCore::InspectorInstrumentation::frameDetachedFromParentImpl):
727         (WebCore::InspectorInstrumentation::didCommitLoadImpl):
728         * inspector/InspectorPageAgent.cpp:
729         (WebCore::InspectorPageAgent::create):
730         (WebCore::InspectorPageAgent::resourceContent):
731         (WebCore::InspectorPageAgent::resourceContentBase64):
732         (WebCore::InspectorPageAgent::resourceData):
733         (WebCore::InspectorPageAgent::cachedResource):
734         (WebCore::InspectorPageAgent::resourceTypeString):
735         (WebCore::InspectorPageAgent::cachedResourceType):
736         (WebCore::InspectorPageAgent::cachedResourceTypeString):
737         (WebCore::InspectorPageAgent::InspectorPageAgent):
738         (WebCore::InspectorPageAgent::setFrontend):
739         (WebCore::InspectorPageAgent::reload):
740         (WebCore::InspectorPageAgent::open):
741         (WebCore::InspectorPageAgent::getCookies):
742         (WebCore::InspectorPageAgent::deleteCookie):
743         (WebCore::InspectorPageAgent::getResourceTree):
744         (WebCore::InspectorPageAgent::getResourceContent):
745         (WebCore::InspectorPageAgent::restore):
746         (WebCore::InspectorPageAgent::domContentEventFired):
747         (WebCore::InspectorPageAgent::loadEventFired):
748         (WebCore::InspectorPageAgent::frameNavigated):
749         (WebCore::InspectorPageAgent::frameDetached):
750         (WebCore::InspectorPageAgent::didClearWindowObjectInWorld):
751         (WebCore::InspectorPageAgent::mainFrame):
752         (WebCore::pointerAsId):
753         (WebCore::InspectorPageAgent::frameForId):
754         (WebCore::InspectorPageAgent::frameId):
755         (WebCore::InspectorPageAgent::loaderId):
756         (WebCore::InspectorPageAgent::buildObjectForFrame):
757         (WebCore::InspectorPageAgent::buildObjectForFrameTree):
758         * inspector/InspectorPageAgent.h:
759         * inspector/InspectorResourceAgent.cpp:
760         (WebCore::buildObjectForCachedResource):
761         (WebCore::InspectorResourceAgent::willSendRequest):
762         (WebCore::InspectorResourceAgent::didReceiveResponse):
763         (WebCore::InspectorResourceAgent::didLoadResourceFromMemoryCache):
764         (WebCore::InspectorResourceAgent::setInitialScriptContent):
765         (WebCore::InspectorResourceAgent::setInitialXHRContent):
766         (WebCore::InspectorResourceAgent::InspectorResourceAgent):
767         * inspector/InspectorResourceAgent.h:
768         (WebCore::InspectorResourceAgent::create):
769         * inspector/InspectorStyleSheet.cpp:
770         (WebCore::InspectorStyleSheet::resourceStyleSheetText):
771         * inspector/front-end/NetworkManager.js:
772         (WebInspector.NetworkManager.prototype.requestContent):
773         * inspector/front-end/NetworkPanel.js:
774         (WebInspector.NetworkPanel):
775         (WebInspector.NetworkPanel.prototype.frameNavigated):
776         * inspector/front-end/ResourceTreeModel.js:
777         (WebInspector.ResourceTreeModel):
778         (WebInspector.ResourceTreeModel.prototype.frontendReused):
779         (WebInspector.ResourceTreeModel.prototype.frameNavigated):
780         (WebInspector.ResourceTreeModel.prototype.frameDetached):
781         * inspector/front-end/inspector.js:
782         (WebInspector.domContentEventFired):
783         (WebInspector.loadEventFired):
784         (WebInspector.frameNavigated):
785         (WebInspector.frameDetached):
786
787 2011-04-25  Pavel Feldman  <pfeldman@google.com>
788
789         Reviewed by Yury Semikhatsky.
790
791         Web Inspector: few protocol improvements.
792         https://bugs.webkit.org/show_bug.cgi?id=59319
793
794         - Page domain is documented
795         - setUserAgentOverride is moved to the Network agent
796         - setSearchingForNode -> setInspectModeEnabled
797         - highlightDOMNode -> highlightNode
798         - reloadPage -> reload
799         - openInNewWindow -> open with optional parameter
800
801         * inspector/Inspector.json:
802         * inspector/InspectorDOMAgent.cpp:
803         (WebCore::InspectorDOMAgent::setInspectModeEnabled):
804         (WebCore::InspectorDOMAgent::highlightNode):
805         * inspector/InspectorDOMAgent.h:
806         (WebCore::InspectorDOMAgent::hideNodeHighlight):
807         * inspector/InspectorInstrumentation.cpp:
808         (WebCore::InspectorInstrumentation::applyUserAgentOverrideImpl):
809         * inspector/InspectorPageAgent.cpp:
810         (WebCore::InspectorPageAgent::clearFrontend):
811         (WebCore::InspectorPageAgent::reload):
812         (WebCore::InspectorPageAgent::open):
813         * inspector/InspectorPageAgent.h:
814         * inspector/InspectorResourceAgent.cpp:
815         (WebCore::InspectorResourceAgent::clearFrontend):
816         (WebCore::InspectorResourceAgent::applyUserAgentOverride):
817         (WebCore::InspectorResourceAgent::setUserAgentOverride):
818         * inspector/InspectorResourceAgent.h:
819         * inspector/front-end/AuditsPanel.js:
820         (WebInspector.AuditsPanel.prototype._reloadResources):
821         * inspector/front-end/ElementsPanel.js:
822         (WebInspector.ElementsPanel.prototype.setSearchingForNode):
823         * inspector/front-end/ExtensionServer.js:
824         (WebInspector.ExtensionServer.prototype._onReload):
825         * inspector/front-end/NetworkPanel.js:
826         (WebInspector.NetworkDataGridNode.prototype._openInNewTab):
827         * inspector/front-end/ResourcesPanel.js:
828         (WebInspector.FrameResourceTreeElement.prototype.ondblclick):
829         * inspector/front-end/inspector.js:
830         (WebInspector.highlightDOMNode):
831         (WebInspector.openResource):
832         (WebInspector.documentKeyDown):
833
834 2011-04-25  Jon Lee  <jonlee@apple.com>
835
836         Reviewed by Maciej Stachowiak.
837
838         Overlay scroller hard to see on pages with dark background (59183)
839         https://bugs.webkit.org/show_bug.cgi?id=59183
840         <rdar://problem/8975367>
841
842         Switch the scrollbar's overlay style depending on its frame's background color.
843         This refactors the getDocumentBackgroundColor method needed for gestures. The style
844         is determined and set on every paint() call to the Mac scrollbar theme.
845
846         * WebCore.exp.in: adding method to allow changing style
847         * page/Frame.cpp:
848         (WebCore::Frame::getDocumentBackgroundColor): moving code from WebFrame for reuse by FrameView
849         * page/Frame.h:
850         * page/FrameView.cpp:
851         (WebCore::FrameView::recommendedScrollbarOverlayStyle): overridden to suggest a style based on CSS background color
852         * page/FrameView.h:
853         * platform/ScrollTypes.h: new enum to represent different overlay scrollbar styles
854         * platform/ScrollableArea.h:
855         (WebCore::ScrollableArea::recommendedScrollbarOverlayStyle): new virtual function to return a suggested overlay style
856         * platform/mac/ScrollbarThemeMac.mm:
857         (WebCore::ScrollbarThemeMac::paint):
858         * platform/mac/WebCoreSystemInterface.h:
859         * platform/mac/WebCoreSystemInterface.mm:
860
861 2011-04-25  Dan Bernstein  <mitz@apple.com>
862
863         Reviewed by Maciej Stachowiak.
864
865         <rdar://problem/9113516> REGRESSION (WK2): Holding down Option while dragging scrollbar thumb has no effect (should make scroll distance equal mouse translation)
866         https://bugs.webkit.org/show_bug.cgi?id=59315
867
868         * platform/Scrollbar.cpp:
869         (WebCore::Scrollbar::Scrollbar): Initialize new member variables.
870         (WebCore::Scrollbar::moveThumb): Added a boolean draggingDocument parameter. When true, the document
871         is scrolled a distance equal to the change in the mouse position.
872         (WebCore::Scrollbar::mouseMoved): Check with the theme whether the mouse move event should drag
873         the document rather than the thumb, and pass the result to moveThumb.
874         (WebCore::Scrollbar::mouseUp): Reset m_draggingDocument.
875         * platform/Scrollbar.h:
876         * platform/ScrollbarTheme.h:
877         (WebCore::ScrollbarTheme::shouldDragDocumentInsteadOfThumb): Added. The base class implementation
878         returns false.
879         * platform/mac/ScrollbarThemeMac.h:
880         * platform/mac/ScrollbarThemeMac.mm:
881         (WebCore::ScrollbarThemeMac::shouldDragDocumentInsteadOfThumb): Overridden to return true if the
882         Option key is down.
883
884 2011-04-24  Geoffrey Garen  <ggaren@apple.com>
885
886         Reviewed by Sam Weinig.
887
888         Removed a use of markDOMObjectWrapper: WebGL, XHR, workers; plus, more autogeneration
889         https://bugs.webkit.org/show_bug.cgi?id=59307
890
891         * WebCore.xcodeproj/project.pbxproj: Added Blob.idl, so it's easier to edit.
892
893         * bindings/js/JSCSSRuleCustom.cpp:
894         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
895         * bindings/js/JSCanvasRenderingContextCustom.cpp:
896         * bindings/js/JSDOMApplicationCacheCustom.cpp: Autogenerate these instead
897         of hand-coding them.
898
899         * bindings/js/JSDOMBinding.h:
900         (WebCore::root): Moved some GC helpers here from JSNodeCustom.h, because
901         they're reasonably generic.
902
903         * bindings/js/JSDOMImplementationCustom.cpp:
904         * bindings/js/JSDOMStringMapCustom.cpp:
905         * bindings/js/JSDOMTokenListCustom.cpp:
906         * bindings/js/JSHTMLCollectionCustom.cpp:
907         * bindings/js/JSMediaListCustom.cpp: Autogenerate these instead of
908         hand-coding them.
909
910         * bindings/js/JSMessageChannelCustom.cpp:
911         (WebCore::JSMessageChannel::visitChildren):
912         * bindings/js/JSMessagePortCustom.cpp:
913         (WebCore::JSMessagePort::visitChildren): Use addOpaqueRoot instead of
914         markDOMObjectWrapper. This is one of the few cases where a DOM object is
915         considered a stand-alone root. It's not as efficient as the shared root
916         case, but workers and message ports are very rare objects, so it's no
917         big deal.
918
919         * bindings/js/JSNamedNodeMapCustom.cpp: Autogenerate!
920
921         * bindings/js/JSNodeCustom.h: Moved to JSDOMBinding.h.
922
923         * bindings/js/JSSharedWorkerCustom.cpp:
924         (WebCore::JSSharedWorker::visitChildren): Use addOpaqueRoot instead of
925         markDOMObjectWrapper, as above. Once again, a stand-alone root.
926
927         * bindings/js/JSStyleSheetCustom.cpp:
928         * bindings/js/JSStyleSheetListCustom.cpp: Autogenerate!
929
930         * bindings/js/JSWebGLRenderingContextCustom.cpp:
931         (WebCore::JSWebGLRenderingContext::visitChildren): Use the opaque roots
932         system for marking WebGL contexts and their associated satellite objects.
933
934         * bindings/js/JSWorkerContextCustom.cpp:
935         (WebCore::JSWorkerContext::visitChildren):
936         * bindings/js/JSXMLHttpRequestCustom.cpp: Use addOpaqueRoot instead of
937         markDOMObjectWrapper, as above. Once again, stand-alone roots.
938
939         (WebCore::JSXMLHttpRequest::visitChildren):
940         * bindings/js/JSXMLHttpRequestUploadCustom.cpp: No need to mark our owner
941         XHR because it is not reachable from us.
942
943         * bindings/scripts/CodeGeneratorJS.pm: Added autogeneration support for a
944         bunch of repetitive cases of isReachableFromOpaqueRoots callbacks.
945
946         * css/CSSRule.idl:
947         * css/CSSStyleDeclaration.idl:
948         * css/MediaList.idl:
949         * css/StyleMedia.idl:
950         * css/StyleSheet.idl:
951         * css/StyleSheetList.idl:
952         * dom/DOMImplementation.idl:
953         * dom/DOMStringMap.idl:
954         * dom/MessagePort.idl:
955         * dom/NamedNodeMap.idl:
956         * fileapi/Blob.idl:
957         * html/DOMTokenList.idl: Opt in to autogeneration.
958
959         * html/HTMLCanvasElement.cpp:
960         (WebCore::HTMLCanvasElement::getContext): Standardized on PassOwnPtr/OwnPtr
961         usage, to reduce human error and make ownership rules more obvious.
962
963         * html/HTMLCollection.idl:
964         * html/canvas/ArrayBuffer.idl: Opt in to autogeneration.
965
966         * html/canvas/CanvasRenderingContext.cpp:
967         * html/canvas/CanvasRenderingContext.h:
968         (WebCore::CanvasRenderingContext::ref):
969         (WebCore::CanvasRenderingContext::deref):
970         * html/canvas/CanvasRenderingContext2D.h:
971         (WebCore::CanvasRenderingContext2D::create):
972         (WebCore::CanvasRenderingContext2D::state): Standardized on PassOwnPtr/OwnPtr
973         usage, to reduce human error and make ownership rules more obvious.
974         
975         Inlined some functions to match our standard idiom and to make the code
976         in the header document itself.
977
978         * html/canvas/CanvasRenderingContext.idl: Opt in to autogeneration.
979
980         * html/canvas/OESStandardDerivatives.cpp:
981         (WebCore::OESStandardDerivatives::OESStandardDerivatives):
982         (WebCore::OESStandardDerivatives::create):
983         * html/canvas/OESStandardDerivatives.h:
984         * html/canvas/OESStandardDerivatives.idl:
985         * html/canvas/OESTextureFloat.cpp:
986         (WebCore::OESTextureFloat::OESTextureFloat):
987         (WebCore::OESTextureFloat::create):
988         * html/canvas/OESTextureFloat.h:
989         * html/canvas/OESTextureFloat.idl:
990         * html/canvas/OESVertexArrayObject.cpp:
991         (WebCore::OESVertexArrayObject::OESVertexArrayObject):
992         (WebCore::OESVertexArrayObject::create):
993         * html/canvas/OESVertexArrayObject.h:
994         * html/canvas/OESVertexArrayObject.idl:
995         * html/canvas/WebGLExtension.cpp:
996         (WebCore::WebGLExtension::WebGLExtension):
997         * html/canvas/WebGLExtension.h:
998         (WebCore::WebGLExtension::ref):
999         (WebCore::WebGLExtension::deref):
1000         (WebCore::WebGLExtension::context):
1001         * html/canvas/WebGLRenderingContext.cpp:
1002         (WebCore::WebGLRenderingContext::~WebGLRenderingContext):
1003         (WebCore::WebGLRenderingContext::getExtension):
1004         * html/canvas/WebGLRenderingContext.h:
1005         * html/canvas/WebKitLoseContext.cpp:
1006         (WebCore::WebKitLoseContext::WebKitLoseContext):
1007         (WebCore::WebKitLoseContext::create):
1008         (WebCore::WebKitLoseContext::loseContext):
1009         * html/canvas/WebKitLoseContext.h:
1010         * html/canvas/WebKitLoseContext.idl: Updated the ownership model for WebGL
1011         canavs rendering contexts to match the model for 2D canvas rendering
1012         contexts. This makes garbage collection a lot more straightforward, but
1013         it also makes the behavior of these objects more reliable. (Previously,
1014         satellite objects would magically stop working when the last reference
1015         to their owner object was dropped. Now, satellite objects keep their owner
1016         alive through reference counting.)
1017
1018         * loader/appcache/DOMApplicationCache.idl:
1019         * page/BarInfo.idl:
1020         * page/Console.idl:
1021         * page/DOMSelection.idl:
1022         * page/Geolocation.idl:
1023         * page/History.idl:
1024         * page/Location.idl:
1025         * page/Navigator.idl:
1026         * page/Screen.idl:
1027         * page/WorkerNavigator.idl:
1028         * plugins/DOMMimeTypeArray.h:
1029         (WebCore::DOMMimeTypeArray::frame):
1030         * plugins/DOMMimeTypeArray.idl:
1031         * plugins/DOMPluginArray.h:
1032         (WebCore::DOMPluginArray::frame):
1033         * plugins/DOMPluginArray.idl:
1034         * storage/Storage.idl:
1035         * workers/WorkerLocation.idl: Opt in to autogeneration.
1036
1037         * xml/XMLHttpRequest.cpp:
1038         (WebCore::XMLHttpRequest::~XMLHttpRequest):
1039         * xml/XMLHttpRequest.h:
1040         * xml/XMLHttpRequestUpload.cpp:
1041         (WebCore::XMLHttpRequestUpload::scriptExecutionContext):
1042         * xml/XMLHttpRequestUpload.h:
1043         (WebCore::XMLHttpRequestUpload::create):
1044         (WebCore::XMLHttpRequestUpload::ref):
1045         (WebCore::XMLHttpRequestUpload::deref):
1046         (WebCore::XMLHttpRequestUpload::xmlHttpRequest):
1047         (WebCore::XMLHttpRequestUpload::toXMLHttpRequestUpload):
1048         * xml/XMLHttpRequestUpload.idl: Updated the ownership model for XHR and
1049         its associated upload object to match the model for canvas. This makes
1050         garbage collection a lot more straightforward, but it also makes the
1051         behavior of these objects more reliable.
1052
1053 2011-04-24  Sheriff Bot  <webkit.review.bot@gmail.com>
1054
1055         Unreviewed, rolling out r84759.
1056         http://trac.webkit.org/changeset/84759
1057         https://bugs.webkit.org/show_bug.cgi?id=59306
1058
1059         Caused gc-shadow.html to start crashing in V8. (Requested by
1060         dglazkov|away on #webkit).
1061
1062         * dom/Node.cpp:
1063         (WebCore::NodeRendererFactory::createRendererAndStyle):
1064         (WebCore::Node::styleForRenderer):
1065
1066 2011-04-24  Maciej Stachowiak  <mjs@apple.com>
1067
1068         Reviewed by George Staikos.
1069
1070         Handling of URLs like http:/example.com/ is incorrect
1071         https://bugs.webkit.org/show_bug.cgi?id=59300
1072         <rdar://problem/9231956>
1073
1074         URLs like http:/example.com/ or http:example.com/ are now correctly
1075         canonicalized as http://example.com/
1076         
1077         The code still doesn't quite match other browsers - at least some
1078         other browsers seem to base parsing behavior on whether they
1079         recongize a scheme from a fixed list, and ignore whether // is
1080         present in the URL or not.
1081         
1082         * platform/KURL.cpp:
1083         (WebCore::isNonFileHierarchicalScheme): New helper function.
1084         (WebCore::KURL::parse): For a particular list of whitelisted schemes,
1085         assume they are hierarchical and need an authority even if there is no //
1086         after the :/
1087
1088 2011-04-24  Dan Bernstein  <mitz@apple.com>
1089
1090         LLVM Compiler build fix.
1091
1092         * page/ContentSecurityPolicy.cpp: Removed an unused function.
1093
1094 2011-04-24  Dominic Cooney  <dominicc@chromium.org>
1095
1096         Reviewed by Dimitri Glazkov.
1097
1098         Crash when adding a text node to a shadow root
1099         https://bugs.webkit.org/show_bug.cgi?id=59304
1100
1101         Text nodes need to consult their host element for style.
1102
1103         Test: fast/dom/shadow/append-child-text.html
1104
1105         * dom/Node.cpp:
1106         (WebCore::NodeRendererFactory::styleForRenderer):
1107         (WebCore::NodeRendererFactory::createRendererAndStyle):
1108         (WebCore::Node::styleForRenderer): forward to NodeRendererFactory
1109
1110 2011-04-24  Adam Barth  <abarth@webkit.org>
1111
1112         Reviewed by Eric Seidel.
1113
1114         Update Content-Security-Policy syntax to match new version of spec
1115         https://bugs.webkit.org/show_bug.cgi?id=59291
1116
1117         Brandon removed disable-xss-protection in favor of unsafe-inline and
1118         allow-eval in favor of unsafe-eval.  This change in syntax also means
1119         the options directive no longer exists.
1120
1121         * page/ContentSecurityPolicy.cpp:
1122         (WebCore::CSPSourceList::allowInline):
1123         (WebCore::CSPSourceList::allowEval):
1124         (WebCore::CSPSourceList::CSPSourceList):
1125         (WebCore::CSPSourceList::parseSource):
1126         (WebCore::CSPSourceList::addSourceUnsafeInline):
1127         (WebCore::CSPSourceList::addSourceUnsafeEval):
1128         (WebCore::CSPDirective::allowInline):
1129         (WebCore::CSPDirective::allowEval):
1130         (WebCore::ContentSecurityPolicy::allowJavaScriptURLs):
1131         (WebCore::ContentSecurityPolicy::allowInlineEventHandlers):
1132         (WebCore::ContentSecurityPolicy::allowInlineScript):
1133         (WebCore::ContentSecurityPolicy::allowEval):
1134         (WebCore::ContentSecurityPolicy::addDirective):
1135         * page/ContentSecurityPolicy.h:
1136
1137 2011-04-24  Dan Bernstein  <mitz@apple.com>
1138
1139         Reviewed by Maciej Stachowiak.
1140
1141         Manual test for <rdar://problem/9329741> Reproducible crash in WebChromeClient::invalidateContentsAndWindow() on simonscat.com
1142         https://bugs.webkit.org/show_bug.cgi?id=59299
1143
1144         * manual-tests/back-from-document-with-scrollbar.html: Added.
1145
1146 2011-04-24  Rik Cabanier  <cabanier@adobe.com>
1147
1148         Reviewed by Simon Fraser.
1149
1150         Tables are not rendered correctly
1151         https://bugs.webkit.org/show_bug.cgi?id=59138
1152
1153         Test: fast/table/auto-100-percent-width.html
1154
1155         * rendering/AutoTableLayout.cpp:
1156         (WebCore::AutoTableLayout::computePreferredLogicalWidths):
1157
1158 2011-04-23  Simon Fraser  <simon.fraser@apple.com>
1159
1160         Fix Windows build, which complains about unreachable code.
1161
1162         * platform/ScrollableArea.cpp:
1163         (WebCore::ScrollableArea::hasLayerForHorizontalScrollbar):
1164         (WebCore::ScrollableArea::hasLayerForVerticalScrollbar):
1165         (WebCore::ScrollableArea::hasLayerForScrollCorner):
1166
1167 2011-04-23  Simon Fraser  <simon.fraser@apple.com>
1168
1169         Reviewed by Dan Bernstein.
1170
1171         Area under composited scrollbars not repainted in WebKit2 on scrolling
1172         https://bugs.webkit.org/show_bug.cgi?id=59294
1173         <rdar://problem/9299062>
1174         
1175         When computing the rect that can be copied on scrolling, we normally
1176         exclude the areas occupied by overlay scrollbars to avoid smeared scrollbars;
1177         the assumption is that other code will repaint these areas. However, when
1178         scrollbars are in their own compositing layers, we can, and should
1179         copy the entire area.
1180
1181         Not testable in DRT because it does not allow tests to use overlay scrollbars.
1182
1183         * platform/ScrollView.h:
1184         * platform/ScrollView.cpp:
1185         (WebCore::ScrollView::rectToCopyOnScroll):
1186         New method, with code moved from scrollContents and fixed to look
1187         for scrollbars in layers.
1188         (WebCore::ScrollView::scrollContents):
1189         Call rectToCopyOnScroll().
1190         
1191         * platform/ScrollableArea.h:
1192         * platform/ScrollableArea.cpp:
1193         (WebCore::ScrollableArea::hasLayerForHorizontalScrollbar):
1194         (WebCore::ScrollableArea::hasLayerForVerticalScrollbar):
1195         (WebCore::ScrollableArea::hasLayerForScrollCorner):
1196         Methods we can call outside of the ACCELERATED_COMPOSITING #ifdef.
1197
1198 2011-04-23  Sheriff Bot  <webkit.review.bot@gmail.com>
1199
1200         Unreviewed, rolling out r84740.
1201         http://trac.webkit.org/changeset/84740
1202         https://bugs.webkit.org/show_bug.cgi?id=59290
1203
1204         change breaks apple internal builds and is incorrect
1205         (Requested by smfr on #webkit).
1206
1207         * WebCore.exp.in:
1208         * page/FrameView.cpp:
1209         * page/FrameView.h:
1210         * platform/ScrollTypes.h:
1211         * platform/ScrollableArea.h:
1212         * platform/mac/ScrollbarThemeMac.mm:
1213         (WebCore::ScrollbarThemeMac::paint):
1214         * platform/mac/WebCoreSystemInterface.h:
1215         * platform/mac/WebCoreSystemInterface.mm:
1216
1217 2011-04-23  Dan Bernstein  <mitz@apple.com>
1218
1219         Reviewed by Simon Fraser.
1220
1221         <rdar://problem/8970549> WebFindOptionsAtWordStarts fails with Japanese words
1222         https://bugs.webkit.org/show_bug.cgi?id=59288
1223
1224         * platform/text/mac/TextBoundaries.mm:
1225         (WebCore::wordStringTokenizer): Added this helper function.
1226         (WebCore::findNextWordFromIndex): Changed to use a CFStringTokenizer with kCFStringTokenizerUnitWord,
1227         whose behavior is not locale-dependent.
1228
1229 2011-04-23  Dominic Cooney  <dominicc@chromium.org>
1230
1231         Reviewed by Dimitri Glazkov.
1232
1233         [V8] Nodes in shadow DOM should not be GCed while their hosts are alive
1234         https://bugs.webkit.org/show_bug.cgi?id=59284
1235
1236         Test: fast/dom/shadow/gc-shadow.html
1237
1238         * bindings/v8/V8GCController.cpp:
1239         (WebCore::calculateGroupId): group shadow nodes with their hosts
1240
1241 2011-04-23  MORITA Hajime <morrita@google.com>
1242
1243         Reviewed by Dimitri Glazkov.
1244
1245         [Refactoring] NodeRenderParentDetector should be NodeRenderFactory
1246         https://bugs.webkit.org/show_bug.cgi?id=59280
1247         
1248         - Rename NodeRenderParentDetector to NodeRendererFactory
1249         - move createRendererAndStyle() and createRendererIfNeeded to
1250           NodeRendererFactory
1251
1252         No new test, no behavioral change.
1253         
1254         * dom/Node.cpp:
1255         (WebCore::NodeRendererFactory::NodeRendererFactory):
1256         (WebCore::NodeRendererFactory::document):
1257         (WebCore::NodeRendererFactory::nextRenderer):
1258         (WebCore::NodeRendererFactory::findVisualParent):
1259         (WebCore::NodeRendererFactory::shouldCreateRenderer):
1260         (WebCore::NodeRendererFactory::createRendererAndStyle):
1261         (WebCore::NodeRendererFactory::createRendererIfNeeded):
1262         (WebCore::Node::parentNodeForRenderingAndStyle):
1263         (WebCore::Node::createRendererIfNeeded):
1264         * dom/Node.h:
1265         * html/HTMLDetailsElement.cpp:
1266         (WebCore::DetailsSummaryElement::detailsElement): Added const_cast due to the chage on parentNodeForRenderingAndStyle() 
1267
1268 2011-04-23  MORITA Hajime  <morrita@google.com>
1269
1270         Reviewed by Kent Tamura.
1271
1272         REGRESSION: (non-Mac) <meter>'s bar part isn't rendered for with -webkit-writing-mode: vertical-lr from r82899
1273         https://bugs.webkit.org/show_bug.cgi?id=59281
1274
1275         Styles for -webkit-meter-bar and -webkit-progress-bar missed width property, which caused unexpected layout results
1276         for vertical writing modes. This fix added a width property for each of them.
1277         
1278         Tests: fast/dom/HTMLMeterElement/meter-writing-mode.html
1279                fast/dom/HTMLProgressElement/progress-writing-mode.html
1280
1281         * css/html.css:
1282         (meter::-webkit-meter-bar):
1283         (progress::-webkit-progress-bar):
1284
1285 2011-04-23  Kevin Ollivier  <kevino@theolliviers.com>
1286
1287         [wx] Unreviewed build fix. Added missing header.
1288         
1289         * platform/graphics/filters/FEDropShadow.h:
1290
1291 2011-04-23  Alexey Proskuryakov  <ap@apple.com>
1292
1293         Reviewed by Maciej Stachowiak.
1294
1295         REGRESSION (r80812): window.print();window.close() doesn't work in WebKit2
1296         https://bugs.webkit.org/show_bug.cgi?id=59241
1297         <rdar://problem/9150861>
1298
1299         Covered by manual-tests/print-after-window-close.html.
1300
1301         Re-fixing <https://bugs.webkit.org/show_bug.cgi?id=51357> in a way that doesn't cause the
1302         regression.
1303
1304         * loader/MainResourceLoader.cpp: (WebCore::MainResourceLoader::didCancel): We shouldn't be
1305         doing complicated work while the loader is half-canceled.
1306
1307         * manual-tests/print-after-window-close.html: Extended to actually print a non-empty page,
1308         thus being more practical.
1309
1310         * page/Chrome.cpp: (WebCore::Chrome::print): Added a FIXME about a need for PageGroupLoadDeferrer.
1311         It's too scary for me to try now.
1312
1313         * page/DOMWindow.cpp:
1314         (WebCore::DOMWindow::DOMWindow):
1315         (WebCore::DOMWindow::finishedLoading):
1316         * page/DOMWindow.h:
1317         Reverted the previous fix for <https://bugs.webkit.org/show_bug.cgi?id=51357>.
1318
1319 2011-04-19  Vitaly Repeshko  <vitalyr@chromium.org>
1320
1321         Reviewed by Adam Barth.
1322
1323         [V8] Use implicit references for V8 listeners on DOM nodes.
1324         https://bugs.webkit.org/show_bug.cgi?id=58953
1325
1326         Instead of allocating an auxiliary V8 array referencing V8
1327         listener objects associated with a DOM node and using an extra
1328         pointer in every DOM node wrapper, we can register implicit
1329         references between nodes and their listeners during GC. This also
1330         makes V8 bindings more aligned with JSC bindings.
1331
1332         No new tests because this is a refactoring.
1333
1334         * bindings/scripts/CodeGeneratorV8.pm: Stopped generating the
1335         listener cache internal field for DOM nodes.
1336         * bindings/v8/V8AbstractEventListener.h: Exposed the lister handle
1337         to the GC.
1338         (WebCore::V8AbstractEventListener::existingListenerObjectPeristentHandle):
1339         * bindings/v8/V8GCController.cpp: Started using implicit references.
1340         (WebCore::GrouperVisitor::visitDOMWrapper):
1341         * dom/EventTarget.h: Implemented an iterator over all listeners.
1342         (WebCore::EventListenerIterator):
1343
1344 2011-04-22  Jon Lee  <jonlee@apple.com>
1345
1346         Reviewed by Beth Dakin.
1347
1348         Overlay scroller hard to see on pages with dark background (59183)
1349         https://bugs.webkit.org/show_bug.cgi?id=59183
1350         <rdar://problem/8975367>
1351
1352         * WebCore.exp.in: adding method to allow changing style
1353         * page/FrameView.cpp:
1354         (WebCore::FrameView::recommendedScrollbarOverlayStyle): overridden to suggest a style based on CSS background color
1355         * page/FrameView.h:
1356         * platform/ScrollTypes.h: new enum to represent different overlay scrollbar styles
1357         * platform/ScrollableArea.cpp:
1358         (WebCore::ScrollableArea::recommendedScrollbarOverlayStyle): new virtual function to return a suggested overlay style
1359         * platform/ScrollableArea.h:
1360         * platform/mac/ScrollbarThemeMac.mm:
1361         (WebCore::ScrollbarThemeMac::paint):
1362         * platform/mac/WebCoreSystemInterface.h:
1363         * platform/mac/WebCoreSystemInterface.mm:
1364
1365 2011-04-22  Chris Evans  <cevans@chromium.org>
1366
1367         Reviewed by Adam Barth.
1368
1369         Upgrade CSS loads from mixed content warning (displayed) to mixed
1370         content error (ran)
1371         https://bugs.webkit.org/show_bug.cgi?id=59056
1372
1373         Test: http/tests/security/mixedContent/insecure-css-in-iframe.html
1374         Test: http/tests/security/mixedContent/insecure-css-in-main-frame.html
1375
1376         * loader/cache/CachedResourceLoader.cpp:
1377         (WebCore::CachedResourceLoader::canRequest): CSS loads are running rather than displaying content.
1378
1379 2011-04-22  Geoffrey Garen  <ggaren@apple.com>
1380
1381         Fixed an upside-down conditional in my last check-in.
1382
1383         * bindings/js/JSDOMApplicationCacheCustom.cpp:
1384         (WebCore::isObservable):
1385
1386 2011-04-22  Geoffrey Garen  <ggaren@apple.com>
1387         
1388         Rolled back in r84725 and r84728 with appcache crash fixed.
1389
1390         Reviewed by Oliver Hunt.
1391
1392         Removed a use of markDOMObjectWrapper: DOMWindow
1393         https://bugs.webkit.org/show_bug.cgi?id=59260
1394
1395         * bindings/js/JSDOMWindowCustom.cpp:
1396         (WebCore::JSDOMWindow::visitChildren): No need to mark explicitly, since
1397         we use the opaque roots system now.
1398
1399         * bindings/js/JSNavigatorCustom.cpp: Ditto.
1400
1401         * bindings/scripts/CodeGeneratorJS.pm: Added autogeneration for objects
1402         whose opaque roots are frames.
1403
1404         * css/StyleMedia.h:
1405         (WebCore::StyleMedia::frame): Added an accessor for the sake of GC.
1406
1407         * css/StyleMedia.idl:
1408         * loader/appcache/DOMApplicationCache.idl:
1409         * page/BarInfo.idl:
1410         * page/Console.idl:
1411         * page/DOMSelection.idl:
1412         * page/Geolocation.idl:
1413         * page/History.idl:
1414         * page/Location.idl:
1415         * page/Navigator.idl:
1416         * page/Screen.idl:
1417         * storage/Storage.idl: Updated to use the opaque roots system.
1418
1419 2011-04-22  Nate Chapin  <japhet@chromium.org>
1420
1421         Reviewed by Adam Barth.
1422
1423         Don't use XMLTreeViewer when script is disabled (it uses Javascript
1424         to build a prettified version of the xml document).
1425         https://bugs.webkit.org/show_bug.cgi?id=59113
1426
1427         * xml/XMLTreeViewer.cpp:
1428         (WebCore::XMLTreeViewer::transformDocumentToTreeView):
1429
1430 2011-04-22  Sheriff Bot  <webkit.review.bot@gmail.com>
1431
1432         Unreviewed, rolling out r84725 and r84728.
1433         http://trac.webkit.org/changeset/84725
1434         http://trac.webkit.org/changeset/84728
1435         https://bugs.webkit.org/show_bug.cgi?id=59270
1436
1437         It broke http/tests/appcache tests (Requested by Ossy on
1438         #webkit).
1439
1440         * bindings/js/JSDOMWindowCustom.cpp:
1441         (WebCore::JSDOMWindow::visitChildren):
1442         * bindings/js/JSNavigatorCustom.cpp:
1443         (WebCore::JSNavigator::visitChildren):
1444         * bindings/scripts/CodeGeneratorJS.pm:
1445         * css/StyleMedia.h:
1446         * css/StyleMedia.idl:
1447         * loader/appcache/DOMApplicationCache.idl:
1448         * page/BarInfo.idl:
1449         * page/Console.idl:
1450         * page/DOMSelection.idl:
1451         * page/DOMWindow.h:
1452         (WebCore::DOMWindow::optionalScreen):
1453         (WebCore::DOMWindow::optionalSelection):
1454         (WebCore::DOMWindow::optionalHistory):
1455         (WebCore::DOMWindow::optionalCrypto):
1456         (WebCore::DOMWindow::optionalLocationbar):
1457         (WebCore::DOMWindow::optionalMenubar):
1458         (WebCore::DOMWindow::optionalPersonalbar):
1459         (WebCore::DOMWindow::optionalScrollbars):
1460         (WebCore::DOMWindow::optionalStatusbar):
1461         (WebCore::DOMWindow::optionalToolbar):
1462         (WebCore::DOMWindow::optionalConsole):
1463         (WebCore::DOMWindow::optionalNavigator):
1464         (WebCore::DOMWindow::optionalLocation):
1465         (WebCore::DOMWindow::optionalMedia):
1466         (WebCore::DOMWindow::optionalSessionStorage):
1467         (WebCore::DOMWindow::optionalLocalStorage):
1468         (WebCore::DOMWindow::optionalPerformance):
1469         * page/Geolocation.idl:
1470         * page/History.idl:
1471         * page/Location.idl:
1472         * page/Navigator.h:
1473         (WebCore::Navigator::optionalGeolocation):
1474         * page/Navigator.idl:
1475         * page/Screen.idl:
1476         * storage/Storage.idl:
1477
1478 2011-04-22  Dimitri Glazkov  <dglazkov@chromium.org>
1479
1480         Reviewed by Kent Tamura.
1481
1482         Change SVG-related shadow root checks to use isSVGShadowRoot.
1483         https://bugs.webkit.org/show_bug.cgi?id=59237
1484
1485         Covered by existing tests, no behavior change.
1486
1487         * css/CSSStyleSelector.cpp:
1488         (WebCore::CSSStyleSelector::SelectorChecker::checkSelector): Use isSVGShadowRoot.
1489         * svg/SVGUseElement.cpp:
1490         (WebCore::ShadowTreeUpdateBlocker::while): Ditto.
1491         * svg/animation/SVGSMILElement.cpp:
1492         (WebCore::SVGSMILElement::insertedIntoDocument): Ditto.
1493
1494 2011-04-22  Geoffrey Garen  <ggaren@apple.com>
1495
1496         Mac build fix.
1497
1498         * page/DOMWindow.h:
1499         (WebCore::DOMWindow::optionalApplicationCache): Restored this function,
1500         which is used after all.
1501
1502 2011-04-22  Geoffrey Garen  <ggaren@apple.com>
1503
1504         Mac build fix.
1505
1506         * page/DOMWindow.h:
1507         (WebCore::DOMWindow::optionalApplicationCache): Restored this function,
1508         which is used after all.
1509
1510 2011-04-22  Geoffrey Garen  <ggaren@apple.com>
1511
1512         Reviewed by Oliver Hunt.
1513
1514         Removed a use of markDOMObjectWrapper: DOMWindow
1515         https://bugs.webkit.org/show_bug.cgi?id=59260
1516
1517         * bindings/js/JSDOMWindowCustom.cpp:
1518         (WebCore::JSDOMWindow::visitChildren): No need to mark explicitly, since
1519         we use the opaque roots system now.
1520
1521         * bindings/js/JSNavigatorCustom.cpp: Ditto.
1522
1523         * bindings/scripts/CodeGeneratorJS.pm: Added autogeneration for objects
1524         whose opaque roots are frames.
1525
1526         * css/StyleMedia.h:
1527         (WebCore::StyleMedia::frame): Added an accessor for the sake of GC.
1528
1529         * css/StyleMedia.idl:
1530         * loader/appcache/DOMApplicationCache.idl:
1531         * page/BarInfo.idl:
1532         * page/Console.idl:
1533         * page/DOMSelection.idl:
1534         * page/Geolocation.idl:
1535         * page/History.idl:
1536         * page/Location.idl:
1537         * page/Navigator.idl:
1538         * page/Screen.idl:
1539         * storage/Storage.idl: Updated to use the opaque roots system.
1540
1541 2011-04-22  Xiaomei Ji  <xji@chromium.org>
1542
1543         Reviewed by Ryosuke Niwa.
1544
1545         move caret by word in visual order returns wrong result when caret itself is at word boundary.
1546         https://bugs.webkit.org/show_bug.cgi?id=58504.
1547
1548         positionBeforeNextWord should take care that the current position is after current word.
1549         positionAfterPreviousWord should take care that the current positin is before current word.
1550
1551         * editing/visible_units.cpp:
1552         (WebCore::positionBeforeNextWord):
1553         (WebCore::positionAfterPreviousWord):
1554
1555 2011-04-19  Jer Noble  <jer.noble@apple.com>
1556
1557         Reviewed by Daniel Bates.
1558
1559         Full Screen from within an <iframe> does not cause <iframe> to resize.
1560         https://bugs.webkit.org/show_bug.cgi?id=58638
1561
1562         Tests: fullscreen/full-screen-frameset.html
1563
1564         * css/CSSStyleSelector.cpp:
1565         (WebCore::CSSStyleSelector::SelectorChecker::checkOneSelector): Add the 
1566             -webkit-full-screen pseudo class to frame elements which contain
1567             full screen elements.
1568         * css/fullscreen.css:
1569         (iframe:-webkit-full-screen): Add iframe-specific styling rules.
1570         * dom/Document.cpp:
1571         (WebCore::Document::setContainsFullScreenElementRecursively): Added.  Walk up each
1572             successive document owner element, calling setContainsFullScreenElement() if 
1573             owner is a frame element.
1574         (WebCore::Document::fullScreenIsAllowedForElement): Use the new Element::isFrameElementBase
1575             call instead of checking the element's tag name.
1576         (WebCore::Document::webkitWillEnterFullScreenForElement): Mark any containing
1577             iframes as containing a full screen element.
1578         (WebCore::Document::webkitWillExitFullScreenForElement): Ditto.
1579         * dom/Element.h:
1580         (WebCore::Element::isFrameElementBase): Added.
1581         * html/HTMLFrameElement.h:
1582         (WebCore::HTMLFrameElement::allowFullScreen): Disable full screen from within
1583             HTMLFrameElements.
1584         * html/HTMLFrameElementBase.cpp:
1585         (WebCore::HTMLFrameElementBase::setContainsFullScreenElement): Added.
1586         * html/HTMLFrameElementBase.h:
1587         (WebCore::HTMLFrameElementBase::containsFullScreenElement): Added.
1588         (WebCore::HTMLFrameElementBase::isFrameElementBase): Added.
1589
1590 2011-04-22  Michael Saboff  <msaboff@apple.com>
1591
1592         Reviewed by Maciej Stachowiak.
1593
1594         Creating copy of ContainerNode's when inserting or removing is inefficient
1595         https://bugs.webkit.org/show_bug.cgi?id=58695
1596
1597         Eliminated node copying in willRemove() and insertedIntoDocument().
1598
1599         No new tests as this is a more efficient implementation of
1600         existing code that is covered by existing tests.
1601
1602         * dom/ContainerNode.cpp:
1603         (WebCore::ContainerNode::willRemove): Changed method to use
1604         RefPtr<> to protect against modification during removal.
1605         (WebCore::ContainerNode::insertedIntoDocument): Changed method to use
1606         RefPtr<> and two other deletion checks to protect against 
1607         modification during insertion.
1608
1609 2011-04-22  Geoffrey Garen  <ggaren@apple.com>
1610
1611         Reviewed by Sam Weinig.
1612
1613         We have an autogenerator, so use it
1614         https://bugs.webkit.org/show_bug.cgi?id=59247
1615
1616         * bindings/js/JSCSSRuleCustom.cpp:
1617         * bindings/js/JSCSSRuleListCustom.cpp:
1618         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
1619         * bindings/js/JSCSSValueCustom.cpp:
1620         * bindings/js/JSCanvasRenderingContextCustom.cpp:
1621         * bindings/js/JSDOMImplementationCustom.cpp:
1622         * bindings/js/JSDOMStringMapCustom.cpp:
1623         * bindings/js/JSHTMLCollectionCustom.cpp:
1624         * bindings/js/JSNamedNodeMapCustom.cpp:
1625         * bindings/js/JSNodeCustom.h:
1626         * bindings/js/JSNodeListCustom.cpp:
1627         * bindings/js/JSStyleSheetCustom.cpp:
1628         * bindings/js/JSStyleSheetListCustom.cpp: Removed repetitive hand-written code.
1629
1630         * bindings/scripts/CodeGeneratorJS.pm: Augmented autogenerator to do the job.
1631
1632         * css/CSSRule.idl:
1633         * css/CSSRuleList.idl:
1634         * css/CSSStyleDeclaration.idl:
1635         * css/CSSValue.idl:
1636         * css/MediaList.idl:
1637         * css/StyleSheet.idl:
1638         * css/StyleSheetList.idl:
1639         * dom/DOMImplementation.idl:
1640         * dom/DOMStringMap.idl:
1641         * dom/NamedNodeMap.idl:
1642         * dom/Node.idl:
1643         * dom/NodeList.idl:
1644         * html/DOMTokenList.idl:
1645         * html/HTMLCollection.idl:
1646         * html/canvas/CanvasRenderingContext.idl: Updated attributes to plug into
1647         the autogenerator.
1648
1649 2011-04-22  Beth Dakin  <bdakin@apple.com>
1650
1651         Reviewed by Maciej Stachowiak.
1652
1653         https://bugs.webkit.org/show_bug.cgi?id=59223
1654         REGRESSION (r82185): iframe not displayed after navigation back to cached page
1655
1656         Manual test added.
1657         * manual-tests/frame-layout-on-back.html: Added.
1658         * manual-tests/resources/empty-document-goes-back.html: Added.
1659         * manual-tests/resources/simple-iframe.html: Added.
1660
1661 2011-04-22  Yael Aharon  <yael.aharon@nokia.com>
1662
1663         Reviewed by Sam Weinig.
1664
1665         HTMLFormControlElement::labels should allow custom attributes.
1666         https://bugs.webkit.org/show_bug.cgi?id=59128
1667
1668         Cache the labels list when it is created and keep using it for future
1669         labels calls.
1670
1671         Test: fast/forms/labels-custom-property.html
1672
1673         * html/HTMLFormControlElement.cpp:
1674         (WebCore::HTMLFormControlElement::labels):
1675
1676 2011-04-22  Adrienne Walker  <enne@google.com>
1677
1678         Reviewed by James Robinson.
1679
1680         [chromium] Remove minimum texture size for compositor tiling
1681         https://bugs.webkit.org/show_bug.cgi?id=59236
1682
1683         This was mistakenly committed in r83915 and causes bad filtering
1684         on very small textures.
1685
1686         Tests: compositing/images/content-image-change.html
1687
1688         * platform/graphics/chromium/LayerTilerChromium.cpp:
1689         (WebCore::LayerTilerChromium::setTileSize):
1690
1691 2011-04-22  Beth Dakin  <bdakin@apple.com>
1692
1693         Reviewed by Maciej Stachowiak.
1694
1695         https://bugs.webkit.org/show_bug.cgi?id=59223
1696         REGRESSION (r82185): iframe not displayed after navigation back to cached page
1697         -and corresponding-
1698         <rdar://problem/9323763>
1699
1700         Cache the scroll position in Document::setInPageCache() instead of 
1701         FrameView::resetScrollbarsAndClearContentsSize(), and only clear the contents size 
1702         for the mainFrame(). Still resetScrollbars() for other frames, which matches pre-
1703         r82185 code.
1704         * dom/Document.cpp:
1705         (WebCore::Document::setInPageCache):
1706         * page/FrameView.cpp:
1707         (WebCore::FrameView::resetScrollbarsAndClearContentsSize):
1708
1709 2011-04-22  Joseph Pecoraro  <joepeck@webkit.org>
1710
1711         Reviewed by Kent Tamura.
1712
1713         Let the RenderTheme decide if an input type should have a spinner
1714         https://bugs.webkit.org/show_bug.cgi?id=59246
1715
1716         Whether an input should have a spinner or not should
1717         be a UI decision made by the RenderTheme. Remove
1718         WebCore's default hasSpinButton values and defer
1719         to the RenderTheme.
1720
1721         No change in functionality, covered by existing tests.
1722
1723         * html/HTMLInputElement.cpp:
1724         (WebCore::HTMLInputElement::isRangeControl): expose isRangeControl
1725         for possible RenderTheme queries.
1726         * html/HTMLInputElement.h:
1727
1728         * rendering/RenderTextControlSingleLine.cpp:
1729         (WebCore::RenderTextControlSingleLine::createSubtreeIfNeeded):
1730         (WebCore::RenderTextControlSingleLine::createInnerTextStyle):
1731         For both of these ask the render theme if the input should
1732         have a spinner.
1733
1734         * rendering/RenderTheme.cpp:
1735         (WebCore::RenderTheme::shouldHaveSpinButtonForInputElement):
1736         Steppable inputs (number, date, and range) but not range
1737         should have spinners. This does not change existing behavior.
1738         * rendering/RenderTheme.h:
1739
1740         * dom/InputElement.h:
1741         * html/BaseDateAndTimeInputType.cpp: remove hasSpinButton.
1742         * html/BaseDateAndTimeInputType.h: remove hasSpinButton.
1743         * html/InputType.cpp: remove hasSpinButton.
1744         * html/InputType.h: remove hasSpinButton.
1745         * html/NumberInputType.cpp: remove hasSpinButton.
1746         * html/NumberInputType.h: remove hasSpinButton.
1747
1748 2011-04-22  Joseph Pecoraro  <joepeck@webkit.org>
1749
1750         Reviewed by Kent Tamura.
1751
1752         Don't rely on hasSpinButton to check if an input type can be stepped
1753         https://bugs.webkit.org/show_bug.cgi?id=59224
1754
1755         Add isSteppable to know for certain if an input type can
1756         be stepped or not. Previously we were checking if the input
1757         has a spin control or is the range input type. These are UI
1758         details, but the step functionality does not require there
1759         to be a UI.
1760
1761         No change in behavior, covered by existing tests.
1762
1763         * html/BaseDateAndTimeInputType.cpp:
1764         (WebCore::BaseDateAndTimeInputType::isSteppable):
1765         * html/BaseDateAndTimeInputType.h:
1766         * html/HTMLInputElement.cpp:
1767         (WebCore::HTMLInputElement::isSteppable):
1768         (WebCore::HTMLInputElement::stepUpFromRenderer): remove the
1769         check for a spinner and range control and instead ASSERT
1770         that the type is steppable.
1771         * html/HTMLInputElement.h:
1772         * html/InputType.cpp:
1773         (WebCore::InputType::isSteppable):
1774         * html/InputType.h:
1775         * html/NumberInputType.cpp:
1776         (WebCore::NumberInputType::isSteppable):
1777         * html/NumberInputType.h:
1778         * html/RangeInputType.cpp:
1779         (WebCore::RangeInputType::isSteppable):
1780         * html/RangeInputType.h:
1781
1782 2011-04-22  Adam Barth  <abarth@webkit.org>
1783
1784         Reviewed by Eric Seidel.
1785
1786         CSP frame-src is missing
1787         https://bugs.webkit.org/show_bug.cgi?id=58643
1788
1789         In this patch, I've audited all the callers to
1790         SecurityOrigin::canDisplay to make sure they all the appropriate
1791         Content-Security-Policy method as well.  I'm not sure how to test all
1792         these cases, but making this changes fixed the frame-src test.
1793
1794         * loader/SubframeLoader.cpp:
1795         (WebCore::SubframeLoader::loadMediaPlayerProxyPlugin):
1796         (WebCore::SubframeLoader::createJavaAppletWidget):
1797         (WebCore::SubframeLoader::loadSubframe):
1798         (WebCore::SubframeLoader::loadPlugin):
1799         * loader/SubresourceLoader.cpp:
1800         (WebCore::SubresourceLoader::create):
1801         * loader/cache/CachedResourceLoader.cpp:
1802         (WebCore::CachedResourceLoader::canRequest):
1803         (WebCore::CachedResourceLoader::requestResource):
1804             - While I was understanding this code, I fixed the FIXME here.
1805         * loader/cache/CachedResourceLoader.h:
1806
1807 2011-04-22  Adrienne Walker  <enne@google.com>
1808
1809         Reviewed by Simon Fraser.
1810
1811         Clear shared graphics context when destroying CanvasRenderingContext2D.
1812         https://bugs.webkit.org/show_bug.cgi?id=59212
1813
1814         * html/canvas/CanvasRenderingContext2D.cpp:
1815         (WebCore::CanvasRenderingContext2D::~CanvasRenderingContext2D):
1816
1817 2011-04-22  Levi Weintraub  <leviw@chromium.org>
1818
1819         Reviewed by Ryosuke Niwa.
1820
1821         End/Home keys do not work in a contentEditable element
1822         https://bugs.webkit.org/show_bug.cgi?id=50564
1823
1824         Changing logical[Start/End]OfLine to return a valid VisiblePosition for for editable contexts that are
1825         inline and share a line with non-editable content.
1826
1827         Test: editing/selection/modify-by-lineboundary-in-inline-editable-contexts.html
1828
1829         * editing/visible_units.cpp:
1830         (WebCore::logicalStartOfLine):
1831         (WebCore::logicalEndOfLine):
1832
1833 2011-04-22  Dimitri Glazkov  <dglazkov@chromium.org>
1834
1835         Reviewed by Kent Tamura.
1836
1837         Make showTree/showTreeForThis aware of the shadow DOM
1838         https://bugs.webkit.org/show_bug.cgi?id=52965
1839
1840         No new tests, because this code is only compiled in DEBUG.
1841
1842         * dom/Node.cpp:
1843         (WebCore::traverseTreeAndMark): Moved tree traversal logic here, adding
1844             recursive sub-traversal of the shadow tree.
1845         (WebCore::Node::showTreeAndMark): Changed to use the new tree traversal function.
1846
1847 2011-04-22  Sam Weinig  <sam@webkit.org>
1848
1849         Reviewed by Gavin Barraclough and Oliver Hunt.
1850
1851         Arrays should participate in global object forwarding fun
1852         https://bugs.webkit.org/show_bug.cgi?id=59215
1853
1854         Change callers of constructArray to use the new variant that takes
1855         a global object.
1856
1857         * bindings/js/JSClipboardCustom.cpp:
1858         (WebCore::JSClipboard::types):
1859         * bindings/js/JSConsoleCustom.cpp:
1860         (WebCore::JSConsole::profiles):
1861         * bindings/js/JSJavaScriptCallFrameCustom.cpp:
1862         (WebCore::JSJavaScriptCallFrame::scopeChain):
1863         * bindings/js/JSMessageEventCustom.cpp:
1864         (WebCore::JSMessageEvent::ports):
1865         * bindings/js/JSScriptProfileNodeCustom.cpp:
1866         (WebCore::JSScriptProfileNode::children):
1867         * bindings/js/JSWebGLRenderingContextCustom.cpp:
1868         (WebCore::toJS):
1869         (WebCore::JSWebGLRenderingContext::getAttachedShaders):
1870         (WebCore::JSWebGLRenderingContext::getSupportedExtensions):
1871
1872 2011-04-22  Csaba Osztrogon√°c  <ossy@webkit.org>
1873
1874         [Qt] Unreviewed typo fix after r84522.
1875
1876         * WebCore.pro:
1877
1878 2011-04-22  Daniel Bates  <dbates@rim.com>
1879
1880         Fix misspelled word in comment; tagets => targets.
1881
1882         * page/EventHandler.cpp:
1883         (WebCore::EventHandler::handleTouchEvent):
1884
1885 2011-04-21  Geoffrey Garen  <ggaren@apple.com>
1886
1887         Reviewed by Oliver Hunt.
1888
1889         Removed a use of markDOMObjectWrapper: Element and Document
1890         https://bugs.webkit.org/show_bug.cgi?id=59178
1891
1892         * GNUmakefile.list.am:
1893         * UseJSC.cmake:
1894         * WebCore.gypi:
1895         * WebCore.pro:
1896         * WebCore.vcproj/WebCore.vcproj:
1897         * WebCore.xcodeproj/project.pbxproj:
1898         * bindings/js/JSBindingsAllInOne.cpp: Build!
1899
1900         * bindings/js/JSDOMImplementationCustom.cpp:
1901         (WebCore::JSDOMImplementationOwner::isReachableFromOpaqueRoots):
1902         (WebCore::JSDOMImplementationOwner::finalize):
1903         (WebCore::wrapperOwner):
1904         (WebCore::wrapperContext):
1905         (WebCore::toJS): Use the opaque roots system for DOMImplementation. Also,
1906         DOMImplementation does not need to keep its document wrapper alive, since
1907         there's no DOM API for getting a DOMImplementation's document.
1908
1909         * bindings/js/JSDOMStringMapCustom.cpp:
1910         (WebCore::JSDOMStringMapOwner::isReachableFromOpaqueRoots):
1911         (WebCore::JSDOMStringMapOwner::finalize):
1912         (WebCore::wrapperOwner):
1913         (WebCore::wrapperContext):
1914         (WebCore::toJS): Use the opaque roots system for DOMStringMap.
1915
1916         * bindings/js/JSDOMTokenListCustom.cpp: Added.
1917         (WebCore::JSDOMTokenListOwner::isReachableFromOpaqueRoots):
1918         (WebCore::JSDOMTokenListOwner::finalize):
1919         (WebCore::wrapperOwner):
1920         (WebCore::wrapperContext):
1921         (WebCore::toJS): Use the opaque roots system for DOMTokenList.
1922
1923         * bindings/js/JSDocumentCustom.cpp:
1924         (WebCore::JSDocument::visitChildren):
1925         * bindings/js/JSElementCustom.cpp: No more need for explicit marking.
1926
1927         * bindings/scripts/CodeGeneratorV8.pm: Boo on whoever made this design decision.
1928
1929         * dom/DOMImplementation.cpp:
1930         (WebCore::DOMImplementation::DOMImplementation):
1931         (WebCore::DOMImplementation::createDocument):
1932         (WebCore::DOMImplementation::createHTMLDocument):
1933         * dom/DOMImplementation.h:
1934         (WebCore::DOMImplementation::create):
1935         (WebCore::DOMImplementation::ref):
1936         (WebCore::DOMImplementation::deref):
1937         (WebCore::DOMImplementation::document): Fixed the DOMImplementation
1938         ownership model to match other satellite objects in the DOM. This was
1939         necessary to fix some crashes due to incorrect reference counting.
1940
1941         * dom/DOMImplementation.idl:
1942         * dom/DOMStringMap.idl:
1943         * dom/Document.cpp:
1944         (WebCore::Document::~Document):
1945         * dom/Document.h:
1946         * dom/Element.cpp:
1947         * dom/Element.h:
1948         * dom/Element.idl:
1949         * html/DOMTokenList.idl: Updated to match changes above.
1950
1951 2011-04-22  Simon Fraser  <simon.fraser@apple.com>
1952
1953         Reviewed by Dan Bernstein.
1954
1955         Rounded corners don't looks smooth when background-image is a gradient
1956         https://bugs.webkit.org/show_bug.cgi?id=59213
1957         
1958         Add the "shrink background" behavior to the slow background
1959         drawing code path.
1960
1961         Test: fast/backgrounds/gradient-background-leakage.html
1962
1963         * rendering/RenderBoxModelObject.cpp:
1964         (WebCore::backgroundRectAdjustedForBleedAvoidance):
1965         Utility function that returns a shrunk border rect based
1966         on the context scale.
1967         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
1968         Use backgroundRectAdjustedForBleedAvoidance() in both the fast
1969         and slow paths.
1970
1971 2011-04-22  Xiaomei Ji  <xji@chromium.org>
1972
1973         Reviewed by David Hyatt.
1974
1975         Local caret rectangle calculation should be relative to its containing block.
1976         https://bugs.webkit.org/show_bug.cgi?id=49508.
1977
1978         InlineBox and caret rectangle are positioned relative to its containing block.
1979         So its left and right edge value should be relative to its containing block as well. 
1980
1981         Test: fast/forms/cursor-at-editable-content-boundary.html
1982
1983         * rendering/RenderText.cpp:
1984         (WebCore::RenderText::localCaretRect):
1985
1986 2011-04-22  Levi Weintraub  <leviw@chromium.org>
1987
1988         Reviewed by Darin Fisher.
1989
1990         REGRESSION: left property broken with position:fixed elements in RTL documents
1991         https://bugs.webkit.org/show_bug.cgi?id=59204
1992         http://code.google.com/p/chromium/issues/detail?id=80216
1993
1994         Test: fast/block/positioning/rtl-fixed-positioning.html
1995               fast/block/positioning/vertical-rl/fixed-positioning.html
1996
1997         Returning the proper scroll offsets for fixed position content in RTL documents.
1998         We regressed to X and Y offsets not updating while scrolling when we clamped to zero,
1999         but RTL documents scroll in negative space.
2000
2001         * page/FrameView.cpp:
2002         (WebCore::FrameView::scrollXForFixedPosition): Properly handling RTL documents where
2003         the scroll origin and offsets are negative.
2004         (WebCore::FrameView::scrollYForFixedPosition): Properly handling vertical writing-
2005         mode RTL documents, like above.
2006         * platform/ScrollView.h:
2007         (WebCore::ScrollView::scrollOrigin): Changing this accessor to const.
2008
2009 2011-04-22  Justin Schuh  <jschuh@chromium.org>
2010
2011         Reviewed by Eric Seidel.
2012
2013         Should assert on invalid type in FEComponentTransfer::apply
2014         https://bugs.webkit.org/show_bug.cgi?id=57959
2015
2016         No functional change. No new tests needed.
2017
2018         * platform/graphics/filters/FEComponentTransfer.cpp:
2019         (WebCore::FEComponentTransfer::apply):
2020
2021 2011-04-22  MORITA Hajime  <morrita@google.com>
2022
2023         Unreviewed crash fix.
2024
2025         * html/HTMLDetailsElement.cpp:
2026         (WebCore::DetailsSummaryElement::shouldInclude):
2027
2028 2011-04-22  Dan Bernstein  <mitz@apple.com>
2029
2030         Reviewed by Sam Weinig.
2031
2032         Exclude scrollbars from the dirty rect passed to the document
2033         https://bugs.webkit.org/show_bug.cgi?id=59206
2034
2035         No test added because functionality is unchanged.
2036
2037         * platform/ScrollView.cpp:
2038         (WebCore::ScrollView::paint): Compute a clip rectangle (analogous to the frame of the clip view
2039         in an NSScrollView) by subtracting non-overlay scrollbars, and intersect the document dirty rect
2040         with it. If the result is empty, avoid calling paintContents().
2041
2042 2011-04-22  Jer Noble  <jer.noble@apple.com>
2043
2044         Reviewed by Maciej Stachowiak.
2045
2046         Disable MediaPlayerPrivateAVFoundation when using old full screen mode.
2047         https://bugs.webkit.org/show_bug.cgi?id=59147
2048
2049         Add a new isAVFoundationEnabled setting and check it before adding 
2050         MediaPlayerPrivateAVFoundationObjC to the media engine registry.
2051
2052         * WebCore.exp.in:
2053         * page/Settings.cpp:
2054         * page/Settings.h:
2055         (WebCore::Settings::setAVFoundationEnabled): Added.
2056         (WebCore::Settings::isAVFoundationEnabled): Added.
2057         * platform/graphics/MediaPlayer.cpp:
2058         (WebCore::installedMediaEngines): Check the settings added above.
2059
2060 2011-04-22  Sam Weinig  <sam@webkit.org>
2061
2062         Reviewed by Gavin Barraclough.
2063
2064         Remove remaining uses of deprecated version of toJS
2065         https://bugs.webkit.org/show_bug.cgi?id=59170
2066
2067         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
2068         (WebCore::toJS):
2069         (WebCore::JSCanvasRenderingContext2D::strokeStyle):
2070         (WebCore::JSCanvasRenderingContext2D::fillStyle):
2071         (WebCore::JSCanvasRenderingContext2D::createPattern):
2072         * bindings/js/JSConsoleCustom.cpp:
2073         (WebCore::JSConsole::profiles):
2074         * bindings/js/JSCustomSQLStatementErrorCallback.cpp:
2075         (WebCore::JSSQLStatementErrorCallback::handleEvent):
2076         * bindings/js/JSDOMBinding.h:
2077         * bindings/js/JSDOMMimeTypeArrayCustom.cpp:
2078         (WebCore::JSDOMMimeTypeArray::nameGetter):
2079         * bindings/js/JSDOMPluginArrayCustom.cpp:
2080         (WebCore::JSDOMPluginArray::nameGetter):
2081         * bindings/js/JSDOMPluginCustom.cpp:
2082         (WebCore::JSDOMPlugin::nameGetter):
2083         * bindings/js/JSDOMWindowCustom.cpp:
2084         (WebCore::namedItemGetter):
2085         (WebCore::JSDOMWindow::event):
2086         * bindings/js/JSEventTarget.cpp:
2087         (WebCore::toJS):
2088         * bindings/js/JSInjectedScriptHostCustom.cpp:
2089         Propagate stored global object down access chain.
2090
2091         (WebCore::InjectedScriptHost::nodeAsScriptValue):
2092         Replace use of deprecated toJS overload with explicit call to deprecatedGlobalObjectForPrototype.
2093
2094         (WebCore::JSInjectedScriptHost::currentCallFrame):
2095         (WebCore::JSInjectedScriptHost::inspectedNode):
2096         * bindings/js/JSNamedNodeMapCustom.cpp:
2097         (WebCore::JSNamedNodeMap::nameGetter):
2098         * bindings/js/JSNodeListCustom.cpp:
2099         (WebCore::callNodeList):
2100         (WebCore::JSNodeList::nameGetter):
2101         * bindings/js/JSScriptProfileNodeCustom.cpp:
2102         (WebCore::JSScriptProfileNode::children):
2103         * bindings/js/JSStyleSheetListCustom.cpp:
2104         (WebCore::JSStyleSheetList::nameGetter):
2105         * bindings/js/JSXSLTProcessorCustom.cpp:
2106         (WebCore::JSXSLTProcessor::transformToFragment):
2107         (WebCore::JSXSLTProcessor::transformToDocument):
2108         * bindings/scripts/CodeGeneratorJS.pm:
2109         Propagate stored global object down access chain.
2110
2111         * css/MediaQueryListListener.cpp:
2112         (WebCore::MediaQueryListListener::queryChanged):
2113         Replace use of deprecated toJS overload with explicit call to deprecatedGlobalObjectForPrototype,
2114         we will want refactor this to match other callbacks so we can remove this.
2115
2116 2011-04-22  Naoki Takano  <takano.naoki@gmail.com>
2117
2118         Reviewed by Eric Seidel.
2119
2120         [Chromium]Mac UI polish to add left/right padding space for autofill popup window.
2121         https://bugs.webkit.org/show_bug.cgi?id=58960
2122         http://code.google.com/p/chromium/issues/detail?id=51077
2123
2124         No new test because Chromium Autofill popup window doesn't have any test framework.
2125         This assumes only AutofillPopupMenuClient gives TexFieldPart appearance.
2126         Only if Autofill popup window has right/left padding.
2127         The code should be removed after Autofill popup window logic is separated from WebKit to Chromium.
2128
2129         * rendering/RenderThemeChromiumMac.h: Add popupInternalPaddingRight() and popupInternalPaddingLeft().
2130         * rendering/RenderThemeChromiumMac.mm:
2131         (WebCore::RenderThemeChromiumMac::popupInternalPaddingLeft): Return padding size only if TextFieldPart is specified.
2132         (WebCore::RenderThemeChromiumMac::popupInternalPaddingRight): Return padding size only if TextFieldPart is specified.
2133
2134 2011-04-21  Adam Roben  <aroben@apple.com>
2135
2136         Add code to enumerate all the functions imported by a particular Windows binary
2137
2138         PEImage is where all the logic starts. It represents a single Portable Executable (PE)
2139         binary. The various enumerator classes are used in conjunction with PEImage to enumerate the
2140         modules and functions imported by that image.
2141
2142         I couldn't figure out how to write a test for this. :-(
2143
2144         Part of <http://webkit.org/b/51063> <rdar://problem/8769281> REGRESSION (WebKit2): No
2145         context menu appears when right-clicking on windowless Flash plugin
2146
2147         Reviewed by Sam Weinig, and given a good once-over by Jeff Miller.
2148
2149         * WebCore.vcproj/WebCore.vcproj: Added the new files.
2150
2151         * platform/win/PEImage.cpp: Added.
2152         (WebCore::PEImage::PEImage): Checks that the module contains the expected magic numbers,
2153         then initializes m_ntHeaders using the module.
2154         (WebCore::PEImage::convertRVAToAddress): Converts a relative virtual address (RVA) to a
2155         non-relative address, which can then be dereferenced. (The PE format uses RVAs in lots of
2156         places.)
2157         (WebCore::PEImage::dataDirectoryEntryAddress): Returns the address of the data associated
2158         with the given entry in the image's DataDirectory.
2159
2160         * platform/win/PEImage.h: Added.
2161         (WebCore::PEImage::isValid): We're a valid image if the validation code in our constructor
2162         succeeded, in which case m_ntHeaders will be set.
2163
2164         * platform/win/ImportedFunctionsEnumerator.cpp: Added. This class enumerates all the
2165         functions imported by the image from a single module by walking the Import Name Table (INT)
2166         and Import Address Table (IAT).
2167         (WebCore::ImportedFunctionsEnumerator::ImportedFunctionsEnumerator): Initialize our members.
2168         (WebCore::ImportedFunctionsEnumerator::isAtEnd): The INT and IAT are both 0-terminated
2169         arrays.
2170         (WebCore::ImportedFunctionsEnumerator::next): Step to the next entries in the INT and IAT.
2171         (WebCore::ImportedFunctionsEnumerator::currentFunctionName): Gets the address of the
2172         function's name, if possible, using the INT.
2173         (WebCore::ImportedFunctionsEnumerator::addressOfCurrentFunctionPointer): Returns the address
2174         of the function pointer for the current function. This function pointer is used whenever
2175         code in m_image calls the current function. (A future patch will take advantage of this by
2176         overwriting this function pointer with another, thereby redirecting calls to that function.)
2177
2178         * platform/win/ImportedFunctionsEnumerator.h: Added.
2179
2180         * platform/win/ImportedModulesEnumeratorBase.h: Added. This base class is used by
2181         ImportedModulesEnumerator and DelayLoadedModulesEnumerator, and allows code to be written
2182         that works with either one.
2183
2184         * platform/win/ImportedModulesEnumerator.cpp: Added. This class enumerates all the
2185         non-delay-loaded modules imported by the image by walking the image's import array.
2186         (WebCore::ImportedModulesEnumerator::ImportedModulesEnumerator): Module import information
2187         is stored in the IMAGE_DIRECTORY_ENTRY_IMPORT entry of the image's DataDirectory.
2188         (WebCore::ImportedModulesEnumerator::isAtEnd): The import array is 0-terminated.
2189         (WebCore::ImportedModulesEnumerator::next): Steps along the import array.
2190         (WebCore::ImportedModulesEnumerator::currentModuleName): Gets the address of the module's
2191         name.
2192         (WebCore::ImportedModulesEnumerator::functionsEnumerator): Get's the addresses of the INT
2193         and IAT for this module and wraps them in an ImportedFunctionsEnumerator.
2194
2195         * platform/win/ImportedModulesEnumerator.h: Added.
2196
2197         * platform/win/DelayLoadedModulesEnumerator.cpp: Added. This class enumerates all the
2198         delay-loaded modules that are imported by the given PEImage by walking the image's
2199         ImageDelayDescr array.
2200         (WebCore::DelayLoadedModulesEnumerator::DelayLoadedModulesEnumerator): Delay-load
2201         information is stored in the IMAGE_DIRECTORY_ENTRY_DELAY_IMPORT entry of the image's
2202         DataDirectory.
2203         (WebCore::DelayLoadedModulesEnumerator::isAtEnd): The delay-loaded modules array is
2204         0-terminated.
2205         (WebCore::DelayLoadedModulesEnumerator::next): Steps along the delay-loaded modules array.
2206         (WebCore::DelayLoadedModulesEnumerator::currentModuleName): Gets the address of the module's
2207         name out of the descriptor.
2208         (WebCore::DelayLoadedModulesEnumerator::functionsEnumerator): Gets the INT and IAT for the
2209         current module out of the descriptor and makes an ImportedFunctionsEnumerator from them.
2210         (WebCore::DelayLoadedModulesEnumerator::convertPotentialRVAToAddress): Pre-VC7.0 images
2211         stored non-relative addresses in the ImageDelayDescr structures, while VC7.0 and later
2212         images store RVAs. This function abstracts away the difference.
2213
2214         * platform/win/DelayLoadedModulesEnumerator.h: Added.
2215
2216 2011-04-21  Adam Roben  <aroben@apple.com>
2217
2218         Add a shared do-nothing window class that anyone can use
2219
2220         Fixes <http://webkit.org/b/59102> WebKit has too many dummy window classes
2221
2222         Reviewed by Anders Carlsson.
2223
2224         * WebCore.vcproj/WebCore.vcproj: Added DefWndProcWindowClass.{cpp,h}. Moved Arena.cpp out of
2225         platform/win and into platform. Let VS reorder other files.
2226
2227         * platform/graphics/ca/win/CACFLayerTreeHost.cpp:
2228         (WebCore::CACFLayerTreeHost::acceleratedCompositingAvailable): Changed to use the shared
2229         dummy window class instead of creating our own.
2230
2231         * platform/win/DefWndProcWindowClass.cpp: Added.
2232         (WebCore::registerClass): Register it!
2233         (WebCore::defWndProcWindowClassName): Register it and return it!
2234
2235         * platform/win/DefWndProcWindowClass.h: Added.
2236
2237 2011-04-21  MORITA Hajime  <morrita@google.com>
2238
2239         Reviewed by Dimitri Glazkov.
2240         
2241         Content of <details> should be forwarded through the shadow DOM
2242         https://bugs.webkit.org/show_bug.cgi?id=59055
2243
2244         - Made ShadowContentElement abstract and added shouldInclude() pure virtual method.
2245         - Added SummaryContentElement, DetailsContentElement, DetailsSummaryElement as
2246           subclasses of ShadowContentElement.
2247         - Gave two shadow children for HTMLDetailsElement. One is DetailsContentElement, that
2248           handles non-summary contents of <details>. Another is SummaryContentElement, that
2249           handles the main summary element.
2250         - Removed most of RenderDetails custom layout mechanism, which is replaced by
2251           ShadowContentElement subclasses.
2252
2253         Tests: fast/html/details-add-child-1.html
2254                fast/html/details-add-child-2.html
2255                fast/html/details-remove-child-1.html
2256                fast/html/details-remove-child-2.html
2257
2258         * dom/ShadowRoot.cpp:
2259         (WebCore::ShadowRoot::contentContainerFor):
2260         (WebCore::ShadowRoot::hostChildrenChanged):
2261         (WebCore::ShadowRoot::hasContentElement):
2262         * dom/ShadowRoot.h:
2263         * html/HTMLDetailsElement.cpp:
2264         (WebCore::DetailsContentElement::DetailsContentElement):
2265         (WebCore::DetailsContentElement::create):
2266         (WebCore::DetailsContentElement::shouldInclude):
2267         (WebCore::DetailsSummaryElement::DetailsSummaryElement):
2268         (WebCore::DetailsSummaryElement::create):
2269         (WebCore::DetailsSummaryElement::shouldInclude):
2270         (WebCore::HTMLDetailsElement::create):
2271         (WebCore::HTMLDetailsElement::HTMLDetailsElement):
2272         (WebCore::HTMLDetailsElement::ensureShadowSubtreeOf):
2273         (WebCore::findSummaryFor):
2274         (WebCore::HTMLDetailsElement::ensureMainSummary):
2275         (WebCore::HTMLDetailsElement::refreshMainSummary):
2276         (WebCore::HTMLDetailsElement::createShadowSubtree):
2277         * html/HTMLDetailsElement.h:
2278         * html/HTMLSummaryElement.cpp:
2279         (WebCore::SummaryContentElement::SummaryContentElement):
2280         (WebCore::SummaryContentElement::shouldInclude):
2281         (WebCore::SummaryContentElement::create):
2282         (WebCore::HTMLSummaryElement::createShadowSubtree):
2283         * html/shadow/ShadowContentElement.h:
2284         * rendering/RenderDetails.cpp:
2285         (WebCore::RenderDetails::RenderDetails):
2286         (WebCore::RenderDetails::addChild):
2287         * rendering/RenderDetails.h:
2288         * rendering/RenderSummary.cpp:
2289         * rendering/RenderSummary.h:
2290
2291 2011-04-21  Simon Fraser  <simon.fraser@apple.com>
2292
2293         Reviewed by Dan Bernstein.
2294
2295         Extra GraphicsContext::save() in InlineTextBox::paintDecoration()
2296         https://bugs.webkit.org/show_bug.cgi?id=59109
2297         
2298         Remove an extraneous GraphicsContext::save() in InlineTextBox::paintDecoration().
2299         
2300         Add an assertion that fires when a GraphicsContext() is destroyed with a non-
2301         empty state stack. Fix canvas to avoid this assertion, since bad content might
2302         trigger it.
2303         
2304         Also add an assertion that fires for mismatched begin/endTransparencyLayers.
2305
2306         Test: fast/text/multiple-text-shadow-alpha.html
2307
2308         * html/HTMLCanvasElement.cpp:
2309         (WebCore::HTMLCanvasElement::~HTMLCanvasElement):
2310         Make sure that the CanvasRenderingContext goes away before the ImageBuffer,
2311         so that CanvasRenderingContext2D has a chance to unwind the state stack in
2312         the ImageBuffer's GraphicsContext.
2313         
2314         * html/canvas/CanvasRenderingContext2D.cpp:
2315         (WebCore::CanvasRenderingContext2D::~CanvasRenderingContext2D):
2316         Balance unmatched state saves in the canvas context.
2317         
2318         * platform/graphics/GraphicsContext.cpp:
2319         (WebCore::GraphicsContext::~GraphicsContext):
2320         Assert that the stack is empty.
2321         
2322         * platform/graphics/cg/GraphicsContextPlatformPrivateCG.h:
2323         (WebCore::GraphicsContextPlatformPrivate::GraphicsContextPlatformPrivate):
2324         (WebCore::GraphicsContextPlatformPrivate::~GraphicsContextPlatformPrivate):
2325         (WebCore::GraphicsContextPlatformPrivate::beginTransparencyLayer):
2326         (WebCore::GraphicsContextPlatformPrivate::endTransparencyLayer):
2327         Changes to allow for asserting for unmatched transparency layer begin/ends.
2328         
2329         * rendering/InlineTextBox.cpp:
2330         (WebCore::InlineTextBox::paintDecoration):
2331         Remove an unbalanced save().
2332
2333 2011-04-22  Pavel Feldman  <pfeldman@google.com>
2334
2335         Reviewed by Yury Semikhatsky.
2336
2337         Web Inspector: add Save As context menu item to the TextViewer.
2338         https://bugs.webkit.org/show_bug.cgi?id=59196
2339
2340         * inspector/front-end/ResourceView.js:
2341         (WebInspector.ResourceSourceFrame.prototype.requestContent):
2342         (WebInspector.ResourceSourceFrame.prototype.suggestedFileName):
2343         (WebInspector.RevisionSourceFrame.prototype.requestContent):
2344         (WebInspector.RevisionSourceFrame.prototype.suggestedFileName):
2345         * inspector/front-end/ScriptsPanel.js:
2346         (WebInspector.ScriptsPanel.prototype._createSourceFrame):
2347         (WebInspector.SourceFrameDelegateForScriptsPanel):
2348         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.formatSourceFilesToggled):
2349         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.suggestedFileName):
2350         * inspector/front-end/SourceFrame.js:
2351         (WebInspector.SourceFrame.prototype._initializeTextViewer):
2352         (WebInspector.SourceFrame.prototype.populateTextAreaContextMenu):
2353         (WebInspector.SourceFrame.prototype.suggestedFileName):
2354         (WebInspector.SourceFrameDelegate.prototype.formatSourceFilesToggled):
2355         (WebInspector.SourceFrameDelegate.prototype.suggestedFileName):
2356         * inspector/front-end/TextViewer.js:
2357         (WebInspector.TextViewer.prototype._contextMenu):
2358         (WebInspector.TextViewerDelegate.prototype.cancelEditing):
2359         (WebInspector.TextViewerDelegate.prototype.populateLineGutterContextMenu):
2360         (WebInspector.TextViewerDelegate.prototype.populateTextAreaContextMenu):
2361         (WebInspector.TextViewerDelegate.prototype.suggestedFileName):
2362
2363 2011-04-22  Mikhail Naganov  <mnaganov@chromium.org>
2364
2365         Reviewed by Pavel Feldman.
2366
2367         Web Inspector: [Chromium] Move detailed heap snapshots storage and processing into workers.
2368         https://bugs.webkit.org/show_bug.cgi?id=59094
2369
2370         * WebCore.gypi:
2371         * WebCore.vcproj/WebCore.vcproj:
2372         * gyp/streamline-inspector-source.sh:
2373         * inspector/front-end/DetailedHeapshotGridNodes.js:
2374         (WebInspector.HeapSnapshotGridNode.prototype.dispose):
2375         (WebInspector.HeapSnapshotObjectNode.prototype._createProvider):
2376         (WebInspector.HeapSnapshotInstanceNode.prototype._createProvider):
2377         (WebInspector.HeapSnapshotConstructorNode.prototype._createNodesProvider):
2378         (WebInspector.HeapSnapshotIteratorsTuple.prototype.dispose):
2379         (WebInspector.HeapSnapshotDiffNode.prototype.calculateDiff.diffCalculated):
2380         (WebInspector.HeapSnapshotDiffNode.prototype._createNodesProvider.createProvider):
2381         (WebInspector.HeapSnapshotDiffNode.prototype._createNodesProvider):
2382         (WebInspector.HeapSnapshotDominatorObjectNode.prototype._createProvider):
2383         (MixInSnapshotNodeFunctions):
2384         * inspector/front-end/DetailedHeapshotView.js:
2385         (WebInspector.HeapSnapshotSortableDataGrid.prototype.dispose):
2386         (WebInspector.HeapSnapshotSortableDataGrid.prototype.resetSortingCache):
2387         (WebInspector.HeapSnapshotDiffDataGrid.prototype.setBaseDataSource):
2388         (WebInspector.HeapSnapshotRetainingPathsList.prototype.dispose):
2389         (WebInspector.HeapSnapshotRetainingPathsList.prototype._resetPaths):
2390         (WebInspector.HeapSnapshotRetainingPathsList.prototype.setDataSource):
2391         (WebInspector.HeapSnapshotRetainingPathsList.prototype.showNext):
2392         (WebInspector.HeapSnapshotRetainingPathsList.prototype.searchCancelled):
2393         (WebInspector.HeapSnapshotRetainingPathsList.prototype._setRootChildrenForFinder):
2394         (WebInspector.DetailedHeapshotView.prototype.dispose):
2395         (WebInspector.DetailedHeapshotView.prototype.get profileWrapper):
2396         (WebInspector.DetailedHeapshotView.prototype.get baseProfileWrapper):
2397         * inspector/front-end/HeapSnapshot.js:
2398         (WebInspector.HeapSnapshotLoader):
2399         (WebInspector.HeapSnapshotLoader.prototype.finishLoading):
2400         (WebInspector.HeapSnapshotLoader.prototype.pushJSONChunk):
2401         (WebInspector.HeapSnapshot.prototype.pushBaseIds):
2402         (WebInspector.HeapSnapshot.prototype.createDiff):
2403         (WebInspector.HeapSnapshot.prototype._parseFilter):
2404         (WebInspector.HeapSnapshot.prototype.createEdgesProvider):
2405         (WebInspector.HeapSnapshot.prototype.createNodesProvider):
2406         (WebInspector.HeapSnapshot.prototype.createPathFinder):
2407         (WebInspector.HeapSnapshot.prototype.updateStaticData):
2408         (WebInspector.HeapSnapshotPathFinder):
2409         (WebInspector.HeapSnapshotPathFinder.prototype.updateRoots):
2410         (WebInspector.HeapSnapshotPathFinder.prototype._reset):
2411         * inspector/front-end/HeapSnapshotProxy.js:
2412         (WebInspector.HeapSnapshotRealWorker):
2413         (WebInspector.HeapSnapshotRealWorker.prototype._messageReceived):
2414         (WebInspector.HeapSnapshotRealWorker.prototype.postMessage):
2415         (WebInspector.HeapSnapshotRealWorker.prototype.terminate):
2416         (WebInspector.HeapSnapshotFakeWorker):
2417         (WebInspector.HeapSnapshotFakeWorker.prototype.postMessage):
2418         (WebInspector.HeapSnapshotFakeWorker.prototype.terminate):
2419         (WebInspector.HeapSnapshotFakeWorker.prototype._postMessageFromWorker):
2420         (WebInspector.HeapSnapshotWorker):
2421         (WebInspector.HeapSnapshotWorker.prototype.createObject):
2422         (WebInspector.HeapSnapshotWorker.prototype.dispose):
2423         (WebInspector.HeapSnapshotWorker.prototype.disposeObject):
2424         (WebInspector.HeapSnapshotWorker.prototype.callGetter):
2425         (WebInspector.HeapSnapshotWorker.prototype.callFactoryMethod.wrapCallback):
2426         (WebInspector.HeapSnapshotWorker.prototype.callFactoryMethod):
2427         (WebInspector.HeapSnapshotWorker.prototype.callMethod):
2428         (WebInspector.HeapSnapshotWorker.prototype._findFunction):
2429         (WebInspector.HeapSnapshotWorker.prototype._messageReceived):
2430         (WebInspector.HeapSnapshotWorker.prototype._postMessage):
2431         (WebInspector.HeapSnapshotProxyObject):
2432         (WebInspector.HeapSnapshotProxyObject.prototype._callWorker):
2433         (WebInspector.HeapSnapshotProxyObject.prototype.dispose):
2434         (WebInspector.HeapSnapshotProxyObject.prototype.disposeWorker):
2435         (WebInspector.HeapSnapshotProxyObject.prototype.callFactoryMethod):
2436         (WebInspector.HeapSnapshotProxyObject.prototype.callGetter):
2437         (WebInspector.HeapSnapshotProxyObject.prototype.callMethod):
2438         (WebInspector.HeapSnapshotLoaderProxy):
2439         (WebInspector.HeapSnapshotLoaderProxy.prototype.finishLoading.callLoadCallbacks):
2440         (WebInspector.HeapSnapshotLoaderProxy.prototype.finishLoading.updateStaticData):
2441         (WebInspector.HeapSnapshotLoaderProxy.prototype.finishLoading):
2442         (WebInspector.HeapSnapshotLoaderProxy.prototype.get loaded):
2443         (WebInspector.HeapSnapshotLoaderProxy.prototype.startLoading):
2444         (WebInspector.HeapSnapshotLoaderProxy.prototype.pushJSONChunk):
2445         (WebInspector.HeapSnapshotProxy):
2446         (WebInspector.HeapSnapshotProxy.prototype.aggregates):
2447         (WebInspector.HeapSnapshotProxy.prototype.createDiff):
2448         (WebInspector.HeapSnapshotProxy.prototype.createEdgesProvider):
2449         (WebInspector.HeapSnapshotProxy.prototype.createNodesProvider):
2450         (WebInspector.HeapSnapshotProxy.prototype.createPathFinder):
2451         (WebInspector.HeapSnapshotProxy.prototype.dispose):
2452         (WebInspector.HeapSnapshotProxy.prototype.finishLoading):
2453         (WebInspector.HeapSnapshotProxy.prototype.get loaded):
2454         (WebInspector.HeapSnapshotProxy.prototype.get nodeCount):
2455         (WebInspector.HeapSnapshotProxy.prototype.nodeFieldValuesByIndex):
2456         (WebInspector.HeapSnapshotProxy.prototype.pushBaseIds):
2457         (WebInspector.HeapSnapshotProxy.prototype.get rootNodeIndex):
2458         (WebInspector.HeapSnapshotProxy.prototype.updateStaticData):
2459         (WebInspector.HeapSnapshotProxy.prototype.startLoading):
2460         (WebInspector.HeapSnapshotProxy.prototype.get totalSize):
2461         (WebInspector.HeapSnapshotProxy.prototype.get uid):
2462         (WebInspector.HeapSnapshotProviderProxy):
2463         (WebInspector.HeapSnapshotProviderProxy.prototype.isEmpty):
2464         (WebInspector.HeapSnapshotProviderProxy.prototype.serializeNextItems):
2465         (WebInspector.HeapSnapshotProviderProxy.prototype.sortAndRewind):
2466         (WebInspector.HeapSnapshotPathFinderProxy):
2467         (WebInspector.HeapSnapshotPathFinderProxy.prototype.findNext):
2468         (WebInspector.HeapSnapshotPathFinderProxy.prototype.updateRoots):
2469         (WebInspector.HeapSnapshotsDiffProxy):
2470         (WebInspector.HeapSnapshotsDiffProxy.prototype.calculate):
2471         (WebInspector.HeapSnapshotsDiffProxy.prototype.pushBaseIds):
2472         (WebInspector.HeapSnapshotsDiffProxy.prototype.pushBaseSelfSizes):
2473         * inspector/front-end/HeapSnapshotWorker.js: Added.
2474         (WebInspector.UIString):
2475         (postMessageWrapper):
2476         * inspector/front-end/HeapSnapshotWorkerDispatcher.js: Added.
2477         (WebInspector.HeapSnapshotWorkerDispatcher):
2478         (WebInspector.HeapSnapshotWorkerDispatcher.prototype._findFunction):
2479         (WebInspector.HeapSnapshotWorkerDispatcher.prototype.dispatchMessage):
2480         * inspector/front-end/ProfilesPanel.js:
2481         (WebInspector.ProfilesPanel.prototype.loadHeapSnapshot):
2482         (WebInspector.ProfilesPanel.prototype._finishHeapSnapshot.else.parsed):
2483         (WebInspector.ProfilesPanel.prototype._finishHeapSnapshot):
2484         * inspector/front-end/WebKit.qrc:
2485         * inspector/front-end/inspector.html:
2486
2487 2011-04-22  Pavel Podivilov  <podivilov@chromium.org>
2488
2489         Reviewed by Pavel Feldman.
2490
2491         Web Inspector: fix de-obfuscation of scripts inlined in html.
2492         https://bugs.webkit.org/show_bug.cgi?id=58538
2493
2494         Use html tokenizer to find script boundaries instead of relying on scriptParsed events.
2495
2496         Test: inspector/debugger/script-formatter.html
2497
2498         * WebCore.gypi:
2499         * WebCore.vcproj/WebCore.vcproj:
2500         * inspector/front-end/JavaScriptFormatter.js: Renamed from Source/WebCore/inspector/front-end/UglifyJS/JavaScriptFormatter.js.
2501         * inspector/front-end/ScriptFormatter.js:
2502         (WebInspector.ScriptFormatter):
2503         (WebInspector.ScriptFormatter.prototype.formatContent):
2504         (WebInspector.ScriptFormatter.prototype._didFormatContent):
2505         * inspector/front-end/ScriptFormatterWorker.js:
2506         (onmessage):
2507         (formatScript):
2508         (HTMLScriptFormatter):
2509         (HTMLScriptFormatter.prototype.format):
2510         (HTMLScriptFormatter.prototype.scriptStarted):
2511         (HTMLScriptFormatter.prototype.scriptEnded):
2512         (HTMLScriptFormatter.prototype.styleSheetStarted):
2513         (HTMLScriptFormatter.prototype.styleSheetEnded):
2514         * inspector/front-end/SourceFile.js:
2515         (WebInspector.FormattedSourceFile.prototype._didRequestContent):
2516         * inspector/front-end/SourceHTMLTokenizer.js:
2517         (WebInspector.SourceHTMLTokenizer.prototype.scriptStarted):
2518         (WebInspector.SourceHTMLTokenizer.prototype.scriptEnded):
2519         (WebInspector.SourceHTMLTokenizer.prototype.styleSheetStarted):
2520         (WebInspector.SourceHTMLTokenizer.prototype.styleSheetEnded):
2521         (WebInspector.SourceHTMLTokenizer.prototype.nextToken):
2522         * inspector/front-end/SourceHTMLTokenizer.re2js:
2523         * inspector/front-end/WebKit.qrc:
2524
2525 2011-04-22  Andrey Kosyakov  <caseq@chromium.org>
2526
2527         Reviewed by Pavel Feldman.
2528
2529         Web Inspector: [Extensions API] misc API cleanup
2530         https://bugs.webkit.org/show_bug.cgi?id=59194
2531
2532         * inspector/front-end/ExtensionAPISchema.json:
2533         * inspector/front-end/ExtensionPanel.js:
2534         (WebInspector.ExtensionSidebarPane.prototype._setObject):
2535
2536 2011-04-21  Pavel Feldman  <pfeldman@google.com>
2537
2538         Reviewed by Yury Semikhatsky.
2539
2540         Web Inspector: group content scripts in the scripts panel drop down.
2541         https://bugs.webkit.org/show_bug.cgi?id=59108
2542
2543         * English.lproj/localizedStrings.js:
2544         * inspector/front-end/ScriptsPanel.js:
2545         (WebInspector.ScriptsPanel.prototype._addOptionToFilesSelect.optionCompare):
2546         (WebInspector.ScriptsPanel.prototype._addOptionToFilesSelect):
2547
2548 2011-04-22  Mike West  <mkwst@google.com>
2549
2550         Reviewed by Pavel Feldman.
2551
2552         Web Inspector: Tiny improvement to UI for adding an XHR breakpoint
2553         https://bugs.webkit.org/show_bug.cgi?id=59100
2554
2555         Improve web inspector UI around adding XHR breakpoints by adding
2556         a textual label to the input-like `span` used to specify which
2557         XHR requests the breakpoint ought to target.
2558
2559         * inspector/front-end/BreakpointsSidebarPane.js:
2560         (WebInspector.XHRBreakpointsSidebarPane.prototype._addButtonClicked.finishEditing):
2561         (WebInspector.XHRBreakpointsSidebarPane.prototype._addButtonClicked):
2562         * inspector/front-end/inspector.css:
2563         (#breakpoint-condition-input):
2564
2565 2011-04-22  Pavel Podivilov  <podivilov@chromium.org>
2566
2567         Reviewed by Pavel Feldman.
2568
2569         Web Inspector: js formatter should never insert new tokens or remove existing tokens and comments.
2570         https://bugs.webkit.org/show_bug.cgi?id=59191
2571
2572         * WebCore.gypi:
2573         * WebCore.vcproj/WebCore.vcproj:
2574         * inspector/front-end/ScriptFormatter.js:
2575         (WebInspector.ScriptFormatter.prototype.formatContent.didFormatChunks):
2576         (WebInspector.ScriptFormatter.prototype.formatContent):
2577         * inspector/front-end/ScriptFormatterWorker.js:
2578         (onmessage):
2579         * inspector/front-end/SourceFile.js:
2580         (WebInspector.SourceFile.prototype._loadResourceContent):
2581         (WebInspector.FormattedSourceFile.prototype._didRequestContent):
2582         (WebInspector.FormattedSourceMapping):
2583         (WebInspector.FormattedSourceMapping.prototype.scriptLocationToSourceLine):
2584         (WebInspector.FormattedSourceMapping.prototype.sourceLineToScriptLocation):
2585         (WebInspector.FormattedSourceMapping.prototype._convertPosition):
2586         * inspector/front-end/UglifyJS/JavaScriptFormatter.js: Added.
2587         (FormattedContentBuilder): Helper class for building formatted script content.
2588         (FormattedContentBuilder.prototype.addToken):
2589         (FormattedContentBuilder.prototype.addSpace):
2590         (FormattedContentBuilder.prototype.addNewLine):
2591         (FormattedContentBuilder.prototype.increaseNestingLevel):
2592         (FormattedContentBuilder.prototype.decreaseNestingLevel):
2593         (FormattedContentBuilder.prototype.content):
2594         (FormattedContentBuilder.prototype.mapping):
2595         (Tokenizer): Wrapper class for UglifyJS tokenizer.
2596         (Tokenizer.prototype.content):
2597         (Tokenizer.prototype.next):
2598         (Tokenizer.prototype._convertUglifyToken):
2599         (JavaScriptFormatter): New formatter based on UglifyJS tokenizer.
2600         (JavaScriptFormatter.prototype.format):
2601         * inspector/front-end/UglifyJS/process.js: Removed.
2602         * inspector/front-end/WebKit.qrc:
2603
2604 2011-04-22  Mikhail Naganov  <mnaganov@chromium.org>
2605
2606         Reviewed by Pavel Feldman.
2607
2608         Web Inspector: [Chromium] Refactor code prior to moving detailed heap snapshots into workers.
2609         https://bugs.webkit.org/show_bug.cgi?id=59189
2610
2611         * WebCore.gypi:
2612         * WebCore.vcproj/WebCore.vcproj:
2613         * inspector/front-end/BinarySearch.js: Added.
2614         * inspector/front-end/DetailedHeapshotGridNodes.js:
2615         (WebInspector.HeapSnapshotGridNode.prototype._populate.sorted):
2616         (WebInspector.HeapSnapshotGridNode.prototype._populate):
2617         (WebInspector.HeapSnapshotGridNode.prototype.populateChildren):
2618         (WebInspector.HeapSnapshotGridNode.prototype.sort.afterSort.afterPopulate):
2619         (WebInspector.HeapSnapshotGridNode.prototype.sort.afterSort):
2620         (WebInspector.HeapSnapshotGridNode.prototype.sort):
2621         (WebInspector.HeapSnapshotObjectNode):
2622         (WebInspector.HeapSnapshotObjectNode.prototype._createChildNode):
2623         (WebInspector.HeapSnapshotInstanceNode.prototype._createChildNode):
2624         (WebInspector.HeapSnapshotInstanceNode.prototype._enhanceData):
2625         (WebInspector.HeapSnapshotInstanceNode.prototype.get isDeletedNode):
2626         (WebInspector.HeapSnapshotDiffNode.prototype.calculateDiff.diffCalculated):
2627         (WebInspector.HeapSnapshotDiffNode.prototype.calculateDiff.baseIdsReceived):
2628         (WebInspector.HeapSnapshotDiffNode.prototype.get data):
2629         * inspector/front-end/DetailedHeapshotView.js:
2630         (WebInspector.HeapSnapshotSortableDataGrid.prototype.sortingChanged.sort):
2631         (WebInspector.HeapSnapshotSortableDataGrid.prototype.sortingChanged):
2632         (WebInspector.HeapSnapshotSortableDataGrid.prototype._performSorting):
2633         (WebInspector.HeapSnapshotSortableDataGrid.prototype.recursiveSortingEnter):
2634         (WebInspector.HeapSnapshotSortableDataGrid.prototype.recursiveSortingLeave):
2635         (WebInspector.HeapSnapshotContainmentDataGrid):
2636         (WebInspector.HeapSnapshotContainmentDataGrid.prototype._defaultPopulateCount.100.setDataSource):
2637         (WebInspector.HeapSnapshotContainmentDataGrid.prototype.sortingChanged):
2638         (WebInspector.HeapSnapshotDiffDataGrid.prototype.setBaseDataSource):
2639         (WebInspector.HeapSnapshotDiffDataGrid.prototype.populateChildren.baseAggregatesReceived.aggregatesReceived.addNodeIfNonZeroDiff):
2640         (WebInspector.HeapSnapshotDiffDataGrid.prototype.populateChildren.baseAggregatesReceived.aggregatesReceived):
2641         (WebInspector.HeapSnapshotDiffDataGrid.prototype.populateChildren):
2642         (WebInspector.HeapSnapshotDominatorsDataGrid):
2643         (WebInspector.HeapSnapshotDominatorsDataGrid.prototype._defaultPopulateCount.25.setDataSource):
2644         (WebInspector.HeapSnapshotDominatorsDataGrid.prototype.sortingChanged):
2645         (WebInspector.HeapSnapshotRetainingPathsList.prototype._performSorting):
2646         (WebInspector.DetailedHeapshotView.prototype._changeBase.baseProfileLoaded):
2647         (WebInspector.DetailedHeapshotView.prototype._changeBase):
2648         (WebInspector.DetailedHeapshotView.prototype._changeView):
2649         (WebInspector.DetailedHeapshotView.prototype._showStringContentPopup.displayString):
2650         (WebInspector.DetailedHeapshotView.prototype._showStringContentPopup):
2651         * inspector/front-end/HeapSnapshot.js:
2652         (WebInspector.HeapSnapshot.prototype.dispose):
2653         (WebInspector.HeapSnapshot.prototype.pushBaseNodeIds):
2654         (WebInspector.HeapSnapshotFilteredOrderedIterator.prototype.serializeNextItems):
2655         (WebInspector.HeapSnapshotFilteredOrderedIterator.prototype.sortAndRewind):
2656         (WebInspector.HeapSnapshotEdgesProvider.prototype._serialize):
2657         (WebInspector.HeapSnapshotNodesProvider.prototype._serialize):
2658         (WebInspector.HeapSnapshotsDiff.prototype.calculate):
2659         (WebInspector.HeapSnapshotsDiff.prototype.pushBaseIds):
2660         (WebInspector.HeapSnapshotsDiff.prototype.pushBaseSelfSizes):
2661         * inspector/front-end/HeapSnapshotProxy.js:
2662         (WebInspector.HeapSnapshotProxy.prototype.createEdgesProvider):
2663         (WebInspector.HeapSnapshotProxy.prototype.createNodesProvider):
2664         (WebInspector.HeapSnapshotProxy.prototype.pushBaseIds):
2665         (WebInspector.HeapSnapshotProviderProxy):
2666         (WebInspector.HeapSnapshotProviderProxy.prototype.serializeNextItems):
2667         (WebInspector.HeapSnapshotProviderProxy.prototype.sortAndRewind):
2668         (WebInspector.HeapSnapshotsDiffProxy.prototype.pushBaseIds):
2669         (WebInspector.HeapSnapshotsDiffProxy.prototype.pushBaseSelfSizes):
2670         * inspector/front-end/PleaseWaitMessage.js:
2671         (WebInspector.PleaseWaitMessage.prototype.showAndWaitFor):
2672         (WebInspector.PleaseWaitMessage.prototype.unlistenAndHide):
2673         * inspector/front-end/WebKit.qrc:
2674         * inspector/front-end/inspector.html:
2675         * inspector/front-end/utilities.js:
2676
2677 2011-04-22  Mikhail Naganov  <mnaganov@chromium.org>
2678
2679         Unreviewed fix after r84484 -- conditional statement was inverted incorrectly.
2680
2681         * inspector/front-end/ProfilesPanel.js:
2682         (WebInspector.ProfilesPanel.prototype.handleShortcut):
2683
2684 2011-04-22  Annie Sullivan  <sullivan@chromium.org>
2685
2686         Reviewed by Pavel Feldman.
2687
2688         Web Inspector: Timeline is too narrow
2689         https://bugs.webkit.org/show_bug.cgi?id=58399
2690
2691         Changed Network Panel widths so that Timeline is 50%.
2692         Added titles to the values in the other columns, so that a tooltip will show the value if the column is too narrow.
2693
2694         * inspector/front-end/NetworkPanel.js:
2695         (WebInspector.NetworkPanel.prototype._createTable):  Changed column widths.
2696         (WebInspector.NetworkPanel.prototype._toggleGridMode): Changed column widths.
2697         (WebInspector.NetworkDataGridNode.prototype.refreshResource): Added titles to column values.
2698         (WebInspector.NetworkDataGridNode.prototype._refreshStatusCell): Ditto
2699         (WebInspector.NetworkDataGridNode.prototype._refreshSizeCell): Ditto
2700         (WebInspector.NetworkDataGridNode.prototype._refreshTimeCell): Ditto
2701         * inspector/front-end/utilities.js:
2702         (Element.prototype.setTextAndTitle): Added new method to set the textContent and title of an Element at the same time, so that it can have a tooltip.
2703
2704 2011-04-22  Dan Bernstein  <mitz@apple.com>
2705
2706         Reviewed by Maciej Stachowiak.
2707
2708         <rdar://problem/9322486> REGRESSION (r83397): Default controls fade out when playing audio-only media
2709         https://bugs.webkit.org/show_bug.cgi?id=59180
2710
2711         Test: media/audio-controls-do-not-fade-out.html
2712
2713         * html/HTMLMediaElement.cpp:
2714         (WebCore::HTMLMediaElement::playbackProgressTimerFired): Only start fading out the controls if there is
2715         a video track.
2716
2717 2011-04-22  Luke Macpherson   <macpherson@chromium.org>
2718
2719         Reviewed by Eric Seidel.
2720
2721         Add FontItalics and FontSmallCaps enums to be used instead of boolean values.
2722         https://bugs.webkit.org/show_bug.cgi?id=59080
2723
2724         No new tests as no new functionality added.
2725
2726         * css/CSSPrimitiveValueMappings.h:
2727         Add casts to/from FontItalics and FontSmallCaps
2728         * css/CSSStyleSelector.cpp:
2729         Use new casts defined in PrimitiveValueMappings.h
2730         * platform/graphics/Font.h:
2731         Use FontItalics enum.
2732         * platform/graphics/FontDescription.h:
2733         Define and use FontItalics and FontSmallCaps enums.
2734
2735 2011-04-21  Andrey Kosyakov  <caseq@chromium.org>
2736
2737         Reviewed by Yury Semikhatsky.
2738
2739         Web Inspector: exception in front-end when user selects resource info for resource that does not have response headers yet
2740         https://bugs.webkit.org/show_bug.cgi?id=59123
2741
2742         * inspector/front-end/ResourceCookiesView.js:
2743         (WebInspector.ResourceCookiesView):
2744         (WebInspector.ResourceCookiesView.prototype.show):
2745         (WebInspector.ResourceCookiesView.prototype.get _gotCookies):
2746         (WebInspector.ResourceCookiesView.prototype._buildCookiesTable):
2747
2748 2011-04-21  Beth Dakin  <bdakin@apple.com>
2749
2750         Reviewed by Dan Bernstein.
2751
2752         https://bugs.webkit.org/show_bug.cgi?id=57898
2753         REGRESSION (r82185): Scroll position not restored on navigation back to a page in 
2754         the page cache
2755         -and corresponding-
2756         <rdar://problem/9226652>
2757
2758         The original fix for this change broke scroll-position restore for pages that are 
2759         *not* in the page cache. This patch fixes both cached and non-cached pages by 
2760         using the cachedScrollPosition() only for cached pages.
2761         * loader/HistoryController.cpp:
2762         (WebCore::HistoryController::saveScrollPositionAndViewStateToItem):
2763
2764 2011-04-21  Luke Macpherson   <macpherson@chromium.org>
2765
2766         Reviewed by Eric Seidel.
2767
2768         Remove redundant calls to RenderStyle::setDisplay()
2769         https://bugs.webkit.org/show_bug.cgi?id=59060
2770
2771         No new tests / no new functionality added.
2772
2773         * css/CSSStyleSelector.cpp:
2774         (WebCore::CSSStyleSelector::applyProperty):
2775         Remove redundant calls to RenderStyle::setDisplay()
2776
2777 2011-04-21  John Bauman  <jbauman@chromium.org>
2778
2779         Reviewed by Kenneth Russell.
2780
2781         WebGL context drawing buffer may not be cleared if FBO bound
2782         https://bugs.webkit.org/show_bug.cgi?id=58956
2783
2784         Clear the drawing buffer even if it's not currently bound, by
2785         switching between FBOs around the clear. Also, make sure that we
2786         handle depth and stencil masks properly.
2787
2788         No new tests, because testing this under DRT doesn't work.
2789
2790         * html/canvas/WebGLRenderingContext.cpp:
2791         (WebCore::WebGLRenderingContext::initializeNewContext):
2792         (WebCore::WebGLRenderingContext::clearIfComposited):
2793         (WebCore::WebGLRenderingContext::depthMask):
2794         * html/canvas/WebGLRenderingContext.h:
2795         *
2796 2011-04-21  Chris Fleizach  <cfleizach@apple.com>
2797
2798         Reviewed by Beth Dakin.
2799
2800         WebKit is erroneously modifying the DOM; adding 'aria-selected' to tables
2801         https://bugs.webkit.org/show_bug.cgi?id=59140
2802
2803         WebKit should not modify the DOM when the screen reader requests certain things be set. There is no
2804         specification that allows this behavior yet, but we are working on something for the future.
2805
2806         * accessibility/AccessibilityRenderObject.cpp:
2807         (WebCore::AccessibilityRenderObject::setARIAGrabbed):
2808         (WebCore::AccessibilityRenderObject::setIsExpanded):
2809         (WebCore::AccessibilityRenderObject::setSelected):
2810         (WebCore::AccessibilityRenderObject::setValue):
2811
2812 2011-04-21  Chris Fleizach  <cfleizach@apple.com>
2813
2814         Reviewed by Beth Dakin.
2815
2816         AX: order AccessibilityRole alphabetically
2817         https://bugs.webkit.org/show_bug.cgi?id=31524
2818
2819         * accessibility/AccessibilityObject.h:
2820
2821 2011-04-21  Jia Pu  <jpu@apple.com>
2822
2823         Reviewed by Maciej Stachowiak.
2824
2825         [Mac] correctionPanelTimerFired() crashes due to rangeToBeReplaced being cleared.
2826         https://bugs.webkit.org/show_bug.cgi?id=59155
2827         <rdar://problem/9261698>
2828
2829         Make sure the range isn't cleared before calling windowRectForRange() on it. Also removed unused functions in Editor.h,
2830         and fixed a typo in function name.
2831
2832         * editing/Editor.h:
2833         * editing/SpellingCorrectionController.cpp:
2834         (WebCore::SpellingCorrectionController::correctionPanelTimerFired):
2835         (WebCore::SpellingCorrectionController::respondToChangedSelection):
2836         * editing/SpellingCorrectionController.h:
2837         (WebCore::SpellingCorrectionController::shouldStartTimerFor):
2838
2839 2011-04-21  Maciej Stachowiak  <mjs@apple.com>
2840
2841         Reviewed by Adam Roben.
2842
2843         Add a feature define to allow <details> and <summary> to be disabled
2844         https://bugs.webkit.org/show_bug.cgi?id=59118
2845         <rdar://problem/9257045>
2846
2847         No new tests; no behavior change.
2848
2849         * Configurations/FeatureDefines.xcconfig:
2850         * DerivedSources.make:
2851         * GNUmakefile.am:
2852         * features.pri:
2853         * html/HTMLDetailsElement.cpp:
2854         * html/HTMLSummaryElement.cpp:
2855         * html/HTMLTagNames.in:
2856         * html/shadow/DetailsMarkerControl.cpp:
2857         * rendering/RenderBlock.cpp:
2858         (WebCore::canMergeContiguousAnonymousBlocks):
2859         * rendering/RenderDetails.cpp:
2860         * rendering/RenderDetails.h:
2861         * rendering/RenderDetailsMarker.cpp:
2862         * rendering/RenderDetailsMarker.h:
2863         * rendering/RenderObject.h:
2864         * rendering/RenderSummary.cpp:
2865         * rendering/RenderSummary.h:
2866         * rendering/RenderTreeAsText.cpp:
2867         (WebCore::RenderTreeAsText::writeRenderObject):
2868
2869 2011-04-21  Dimitri Glazkov  <dglazkov@chromium.org>
2870
2871         Reviewed by Adele Peterson.
2872
2873         REGRESSION (r83386): Typing in WSJ.com search field doesn't clear placeholder text
2874         https://bugs.webkit.org/show_bug.cgi?id=59053
2875
2876         Turns out, the relatedTarget of an event could be also an ancestor of an event,
2877         not just its parent. Duh.
2878
2879         * dom/EventDispatcher.cpp:
2880         (WebCore::EventDispatcher::adjustToShadowBoundaries): Changed to use shadowHost
2881             explicitly.
2882
2883 2011-04-21  Michael Saboff  <msaboff@apple.com>
2884
2885         Reviewed by Maciej Stachowiak.
2886
2887         Qualified names used for all TagName access, yet namespace usage is rare
2888         https://bugs.webkit.org/show_bug.cgi?id=58997
2889
2890         The methods getElementsByTagName and getElementsByTagNameNS where
2891         always creating and using QualifiedNames.  QualifiedName::init
2892         was consistently in the top 3 routines when running the Dromaeo
2893         DOM-query benchmark.  Split out the functionality so that
2894         getElementsByTagName uses just the local name, an implied "*"
2895         namespace and a separate TagNodeListCache keyed by an atomic name
2896         instead of a QualifiedName.  Access to elements via
2897         getElementsByTagNameNS that have "*" namespace are forwarded to
2898         getElementsByTagName as well.  This provides ~10% speed up in that
2899         Dromaeo test.
2900
2901         No new tests added, existing tests have coverage.  The changes are
2902         an optimization of existing functionality.
2903
2904         * dom/Node.cpp:
2905         (WebCore::Node::removeCachedTagNodeList):
2906         (WebCore::Node::getElementsByTagName):
2907         (WebCore::Node::getElementsByTagNameNS):
2908         (WebCore::NodeListsNodeData::invalidateCaches):
2909         (WebCore::NodeListsNodeData::isEmpty):
2910         * dom/Node.h:
2911         * dom/NodeRareData.h:
2912         * dom/TagNodeList.cpp:
2913         (WebCore::TagNodeList::~TagNodeList):
2914
2915 2011-04-21  Geoffrey Garen  <ggaren@apple.com>
2916
2917         Reviewed by Oliver Hunt.
2918
2919         Removed a use of markDOMObjectWrapper: more style- and node-related stuff
2920         https://bugs.webkit.org/show_bug.cgi?id=59127
2921
2922         * bindings/js/JSCanvasRenderingContextCustom.cpp:
2923         * bindings/js/JSCanvasRenderingContextCustom.cpp:
2924         (WebCore::JSCanvasRenderingContextOwner::isReachableFromOpaqueRoots):
2925         (WebCore::JSCanvasRenderingContextOwner::finalize):
2926         (WebCore::wrapperOwner):
2927         (WebCore::wrapperContext): Use opaque roots for marking canvas rendering
2928         contexts, so JSNode isn't responsible for it.
2929
2930         * bindings/js/JSElementCustom.cpp:
2931         (WebCore::JSElement::markChildren):
2932         * bindings/js/JSHTMLCanvasElementCustom.cpp:
2933         * bindings/js/JSHTMLLinkElementCustom.cpp:
2934         * bindings/js/JSHTMLStyleElementCustom.cpp: Removed obsolete marking code.
2935
2936         * bindings/js/JSNodeCustom.cpp:
2937         (WebCore::isObservable):
2938         (WebCore::isReachableFromDOM):
2939         (WebCore::JSNodeOwner::isReachableFromOpaqueRoots): Removed a bunch of
2940         CSS object model related special cases, since the CSS object model
2941         now tracks its own lifetime through the opaque roots system. Removed
2942         canvas special case, covered above.
2943
2944         * bindings/js/JSProcessingInstructionCustom.cpp:
2945         * bindings/js/JSWebKitAnimationListCustom.cpp:
2946         * dom/ProcessingInstruction.idl:
2947         * html/HTMLCanvasElement.idl:
2948         * html/HTMLLinkElement.idl:
2949         * html/HTMLStyleElement.idl:
2950         * page/WebKitAnimationList.idl: Removed obsolete marking code.
2951
2952 2011-04-21  Vangelis Kokkevis  <vangelis@chromium.org>
2953
2954         Reviewed by James Robinson.
2955
2956         [chromium] Only update the contents of layers that are going to
2957         be drawn. Remove individual texture unreserves that happen
2958         after the layer draw calls with a single unreserve for all the
2959         textures in the texture manager.
2960         https://bugs.webkit.org/show_bug.cgi?id=59129
2961
2962         Tests: No new functionality.  Covered by existing layout tests.
2963
2964         * platform/graphics/chromium/ContentLayerChromium.cpp:
2965         (WebCore::ContentLayerChromium::draw):
2966         * platform/graphics/chromium/ContentLayerChromium.h:
2967         * platform/graphics/chromium/ImageLayerChromium.cpp:
2968         (WebCore::ImageLayerChromium::paintContentsIfDirty):
2969         (WebCore::ImageLayerChromium::updateCompositorResources):
2970         * platform/graphics/chromium/LayerRendererChromium.cpp:
2971         (WebCore::LayerRendererChromium::drawRootLayer):
2972         (WebCore::LayerRendererChromium::updateAndDrawLayers):
2973         (WebCore::LayerRendererChromium::updateLayers):
2974         (WebCore::LayerRendererChromium::paintLayerContents):
2975         * platform/graphics/chromium/LayerRendererChromium.h:
2976         * platform/graphics/chromium/LayerTexture.cpp:
2977         * platform/graphics/chromium/LayerTexture.h:
2978         * platform/graphics/chromium/LayerTilerChromium.cpp:
2979         * platform/graphics/chromium/LayerTilerChromium.h:
2980         * platform/graphics/chromium/RenderSurfaceChromium.cpp:
2981         (WebCore::RenderSurfaceChromium::drawSurface):
2982         * platform/graphics/chromium/TextureManager.cpp:
2983         (WebCore::TextureManager::unprotectAllTextures):
2984         * platform/graphics/chromium/TextureManager.h:
2985         * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
2986         (WebCore::CCHeadsUpDisplay::draw):
2987         * platform/graphics/chromium/cc/CCLayerImpl.h:
2988         (WebCore::CCLayerImpl::owner):
2989
2990 2011-04-21  Ryosuke Niwa  <rniwa@webkit.org>
2991
2992         Reviewed by Sam Weinig.
2993
2994         Add Frame* to the argument lists of canCopyCut and canPaste
2995         https://bugs.webkit.org/show_bug.cgi?id=59153
2996
2997         canCopyCut and canPaste now takes Frame* for which supportedCopyCut and supportedPaste are called.
2998         This allows editor client to grant copy/cut and paste permissions per origin.
2999
3000         * editing/EditorCommand.cpp:
3001         (WebCore::supportedCopyCut):
3002         (WebCore::supportedPaste):
3003         * loader/EmptyClients.h:
3004         (WebCore::EmptyEditorClient::canCopyCut):
3005         (WebCore::EmptyEditorClient::canPaste):
3006         * page/EditorClient.h:
3007
3008 2011-04-21  Oliver Hunt  <oliver@apple.com>
3009
3010         Whoops, change lost during merge
3011
3012         * bindings/js/JSEventListener.h:
3013
3014 2011-04-21  Geoffrey Garen  <ggaren@apple.com>
3015
3016         Reviewed by Sam Weinig.
3017
3018         Fixed a failure seen in fast/dom/prototype-inheritance-2.html due to
3019         wrong global object use.
3020
3021         * bindings/js/JSHTMLDocumentCustom.cpp:
3022         (WebCore::JSHTMLDocument::nameGetter):
3023         (WebCore::JSHTMLDocument::all):
3024         * bindings/js/JSHTMLFormElementCustom.cpp:
3025         (WebCore::JSHTMLFormElement::nameGetter): Use the right global object.
3026
3027 2011-04-21  Oliver Hunt  <oliver@apple.com>
3028
3029         Reviewed by Geoffrey Garen.
3030
3031         Start moving to a general visitor pattern for GC traversal
3032         https://bugs.webkit.org/show_bug.cgi?id=59141
3033
3034         This is just a rename:
3035             markChildren -> visitChildren
3036             markAggregate -> visitAggregate
3037             markStack -> visitor
3038             MarkStack -> typedef'd to SlotVisitor
3039
3040         * bindings/js/JSAttrCustom.cpp:
3041         (WebCore::JSAttr::visitChildren):
3042         * bindings/js/JSAudioConstructor.cpp:
3043         (WebCore::constructAudio):
3044         * bindings/js/JSCSSRuleCustom.cpp:
3045         (WebCore::JSCSSRule::visitChildren):
3046         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
3047         (WebCore::JSCSSStyleDeclaration::visitChildren):
3048         * bindings/js/JSDOMBinding.cpp:
3049         (WebCore::visitActiveObjectsForContext):
3050         (WebCore::markDOMObjectWrapper):
3051         * bindings/js/JSDOMBinding.h:
3052         * bindings/js/JSDOMGlobalObject.cpp:
3053         (WebCore::JSDOMGlobalObject::visitChildren):
3054         * bindings/js/JSDOMGlobalObject.h:
3055         * bindings/js/JSDOMImplementationCustom.cpp:
3056         (WebCore::JSDOMImplementation::visitChildren):
3057         * bindings/js/JSDOMWindowCustom.cpp:
3058         (WebCore::JSDOMWindow::visitChildren):
3059         * bindings/js/JSDOMWindowShell.cpp:
3060         (WebCore::JSDOMWindowShell::visitChildren):
3061         * bindings/js/JSDOMWindowShell.h:
3062         * bindings/js/JSDocumentCustom.cpp:
3063         (WebCore::JSDocument::visitChildren):
3064         * bindings/js/JSElementCustom.cpp:
3065         (WebCore::JSElement::visitChildren):
3066         * bindings/js/JSEventListener.cpp:
3067         (WebCore::JSEventListener::markJSFunction):
3068         * bindings/js/JSEventListener.h:
3069         * bindings/js/JSHTMLCanvasElementCustom.cpp:
3070         (WebCore::JSHTMLCanvasElement::visitChildren):
3071         * bindings/js/JSHTMLLinkElementCustom.cpp:
3072         (WebCore::JSHTMLLinkElement::visitChildren):
3073         * bindings/js/JSHTMLStyleElementCustom.cpp:
3074         (WebCore::JSHTMLStyleElement::visitChildren):
3075         * bindings/js/JSImageConstructor.cpp:
3076         (WebCore::constructImage):
3077         * bindings/js/JSJavaScriptAudioNodeCustom.cpp:
3078         (WebCore::JSJavaScriptAudioNode::visitChildren):
3079         * bindings/js/JSMessageChannelCustom.cpp:
3080         (WebCore::JSMessageChannel::visitChildren):
3081         * bindings/js/JSMessagePortCustom.cpp:
3082         (WebCore::JSMessagePort::visitChildren):
3083         * bindings/js/JSNamedNodeMapCustom.cpp:
3084         (WebCore::JSNamedNodeMapOwner::isReachableFromOpaqueRoots):
3085         (WebCore::JSNamedNodeMap::visitChildren):
3086         * bindings/js/JSNavigatorCustom.cpp:
3087         (WebCore::JSNavigator::visitChildren):
3088         * bindings/js/JSNodeCustom.cpp:
3089         (WebCore::isObservable):
3090         (WebCore::isReachableFromDOM):
3091         (WebCore::JSNodeOwner::isReachableFromOpaqueRoots):
3092         (WebCore::JSNode::visitChildren):
3093         * bindings/js/JSNodeCustom.h:
3094         * bindings/js/JSNodeFilterCondition.cpp:
3095         (WebCore::JSNodeFilterCondition::WeakOwner::isReachableFromOpaqueRoots):
3096         * bindings/js/JSNodeFilterCondition.h:
3097         * bindings/js/JSNodeFilterCustom.cpp:
3098         (WebCore::JSNodeFilter::visitChildren):
3099         * bindings/js/JSNodeIteratorCustom.cpp:
3100         (WebCore::JSNodeIterator::visitChildren):
3101         * bindings/js/JSNodeListCustom.cpp:
3102         (WebCore::JSNodeListOwner::isReachableFromOpaqueRoots):
3103         * bindings/js/JSProcessingInstructionCustom.cpp:
3104         (WebCore::JSProcessingInstruction::visitChildren):
3105         * bindings/js/JSSVGElementInstanceCustom.cpp:
3106         (WebCore::JSSVGElementInstance::visitChildren):
3107         * bindings/js/JSSharedWorkerCustom.cpp:
3108         (WebCore::JSSharedWorker::visitChildren):
3109         * bindings/js/JSStyleSheetCustom.cpp:
3110         (WebCore::JSStyleSheet::visitChildren):
3111         * bindings/js/JSTreeWalkerCustom.cpp:
3112         (WebCore::JSTreeWalker::visitChildren):
3113         * bindings/js/JSWebGLRenderingContextCustom.cpp:
3114         (WebCore::JSWebGLRenderingContext::visitChildren):
3115         * bindings/js/JSWebKitAnimationListCustom.cpp:
3116         (WebCore::JSWebKitAnimationList::visitChildren):
3117         * bindings/js/JSWorkerContextCustom.cpp:
3118         (WebCore::JSWorkerContext::visitChildren):
3119         * bindings/js/JSXMLHttpRequestCustom.cpp:
3120         (WebCore::JSXMLHttpRequest::visitChildren):
3121         * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
3122         (WebCore::JSXMLHttpRequestUpload::visitChildren):
3123         * bindings/scripts/CodeGeneratorJS.pm:
3124         * bridge/qt/qt_instance.cpp:
3125         (JSC::Bindings::QtRuntimeObject::visitChildren):
3126         (JSC::Bindings::QtInstance::markAggregate):
3127         * bridge/qt/qt_instance.h:
3128         * bridge/qt/qt_pixmapruntime.cpp:
3129         * bridge/qt/qt_runtime.cpp:
3130         (JSC::Bindings::QtRuntimeMetaMethod::visitChildren):
3131         * bridge/qt/qt_runtime.h:
3132         * dom/EventListener.h:
3133         (WebCore::EventListener::visitJSFunction):
3134         * dom/EventTarget.h:
3135         (WebCore::EventTarget::visitJSEventListeners):
3136         * dom/Node.h:
3137         * dom/NodeFilterCondition.h:
3138         (WebCore::NodeFilterCondition::visitAggregate):
3139         * page/DOMWindow.h:
3140         * workers/WorkerContext.h:
3141
3142 2011-04-21  Beth Dakin  <bdakin@apple.com>
3143
3144         Reviewed by Dan Bernstein.
3145
3146         https://bugs.webkit.org/show_bug.cgi?id=59048
3147         Need to track whether overlay scrollbar is currently visible and in lower-
3148         righthand corner
3149         -and corresponding-
3150         <rdar://problem/9211232>
3151
3152         Whenever we start a new ScrollbarPartAnimation, check if the scrollbar is vertical 
3153         and showing (alpha of 1), and if so, call setVisibleScrollerThumbRect with the 
3154         knob rect, otherwise with an empty rect. ScrollAnimatorMac has a local rect to 
3155         track this value so that it can avoid sending messages across the ChromeClient to 
3156         the UIProcess if the rect has not changed.
3157         * platform/mac/ScrollAnimatorMac.h:
3158         * platform/mac/ScrollAnimatorMac.mm:
3159         (-[ScrollbarPainterDelegate setUpAnimation:scrollerPainter:part:WebCore::animateAlphaTo:duration:]):
3160         (WebCore::ScrollAnimatorMac::ScrollAnimatorMac):
3161         (WebCore::ScrollAnimatorMac::setVisibleScrollerThumbRect):
3162
3163         Plumbing for the chrome client.
3164         * page/ChromeClient.h:
3165         (WebCore::ChromeClient::notifyScrollerThumbIsVisibleInRect):
3166         * page/FrameView.cpp:
3167         (WebCore::FrameView::setVisibleScrollerThumbRect):
3168         * page/FrameView.h:
3169         * platform/ScrollableArea.h:
3170         (WebCore::ScrollableArea::setVisibleScrollerThumbRect):
3171
3172         New WebCoreSystemInterface function to get the knob rect.
3173         * WebCore.exp.in:
3174         * platform/mac/WebCoreSystemInterface.h:
3175         * platform/mac/WebCoreSystemInterface.mm:
3176
3177 2011-04-21  Nat Duca  <nduca@chromium.org>
3178
3179         Reviewed by James Robinson.
3180
3181         [chromium] Fix artefacts in compositor HUD when resizing
3182         https://bugs.webkit.org/show_bug.cgi?id=58969
3183
3184         HUD was using the tiler program and not setting the texture
3185         transform. The HUD would thus draw with a texture transform based
3186         on the last tile drawn, leading sometimes to distortion.
3187
3188         * platform/graphics/chromium/LayerRendererChromium.cpp:
3189         (WebCore::LayerRendererChromium::initializeSharedObjects):
3190         (WebCore::LayerRendererChromium::cleanupSharedObjects):
3191         * platform/graphics/chromium/LayerRendererChromium.h:
3192         (WebCore::LayerRendererChromium::headsUpDisplayProgram):
3193         * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
3194         (WebCore::CCHeadsUpDisplay::draw):
3195         * platform/graphics/chromium/cc/CCHeadsUpDisplay.h:
3196
3197 2011-04-21  Mike Reed  <reed@google.com>
3198
3199         Reviewed by Kenneth Russell.
3200
3201         only return false if we actually in a skia-gpu accelerated canvas for isNativeFontRenderingAllowed
3202         https://bugs.webkit.org/show_bug.cgi?id=59024
3203
3204         No new tests. The bug (and fix) depend on enabling SKIA_GPU. When that is enabled, the bug
3205         shows all text w/o lcd rendering. This is a regression from a recent CL when we switch to
3206         calling skia::SupportsPlatformPaint. This CL fixes that.
3207         There should be no change for the default builds when SKIA_GPU is not enabled.
3208
3209         * platform/graphics/skia/PlatformContextSkia.cpp:
3210         (WebCore::PlatformContextSkia::isNativeFontRenderingAllowed):
3211
3212 2011-04-21  Adrienne Walker  <enne@google.com>
3213
3214         Reviewed by James Robinson.
3215
3216         [chromium] Don't upload partially drawn tiles in the compositor
3217         https://bugs.webkit.org/show_bug.cgi?id=59112
3218
3219         Use the same set of tiles for painting as is used for updating.
3220         Before, a larger set of tiles were being uploaded, causing some to
3221         only be partially undirtied because they were not fully painted.
3222         As tiles are clear their dirty rect after being unpainted, this caused
3223         artifacts to appear when scrolling.
3224
3225         Unfortunately, no layout test can test this behavior yet because
3226         scrolling invalidations are done differently in test shell.
3227
3228         * platform/graphics/chromium/ImageLayerChromium.cpp:
3229         (WebCore::ImageLayerChromium::updateCompositorResources):
3230         * platform/graphics/chromium/LayerTilerChromium.cpp:
3231         (WebCore::LayerTilerChromium::update):
3232         (WebCore::LayerTilerChromium::uploadCanvas):
3233         (WebCore::LayerTilerChromium::updateFromPixels):
3234         * platform/graphics/chromium/LayerTilerChromium.h:
3235
3236 2011-04-21  Ben Taylor  <bentaylor.solx86@gmail.com>
3237
3238         Reviewed by Alexey Proskuryakov.
3239
3240         https://bugs.webkit.org/show_bug.cgi?id=58725
3241
3242         Fix a compile issue on Solaris 10 with Sun Studio 12,
3243         ternary operators (?:) must have the same types
3244
3245         * loader/DocumentLoader.cpp:
3246         (WebCore::DocumentLoader::popArchiveForSubframe):
3247         * loader/archive/ArchiveFactory.cpp:
3248         (WebCore::ArchiveFactory::create):
3249         * loader/icon/IconDatabase.cpp:
3250         (WebCore::IconDatabase::setIconDataForIconURL):
3251         * page/animation/AnimationBase.cpp:
3252         (WebCore::blendFunc):
3253         * rendering/RenderLayer.cpp:
3254         (WebCore::RenderLayer::updateScrollCornerStyle):
3255         (WebCore::RenderLayer::updateResizerStyle):
3256         * rendering/RenderScrollbar.cpp:
3257         (WebCore::RenderScrollbar::updateScrollbarPart):
3258         * rendering/RenderTextFragment.cpp:
3259         (WebCore::RenderTextFragment::RenderTextFragment):
3260
3261 2011-04-21  Mike Reed  <reed@google.com>
3262
3263         Reviewed by Kenneth Russell.
3264
3265         [chromium, win] Multiple failures of shadow rendering layout tests
3266         https://bugs.webkit.org/show_bug.cgi?id=58772
3267
3268         No new tests. This CL fixes a regression in the following tests
3269         fast/multicol/shadow-breaking.html
3270         fast/repaint/shadow-multiple-horizontal.html
3271         fast/repaint/shadow-multiple-strict-horizontal.html
3272         fast/repaint/shadow-multiple-strict-vertical.html
3273         fast/repaint/shadow-multiple-vertical.html
3274         fast/text/shadow-translucent-fill.html
3275         fast/transforms/shadows.html
3276         svg/css/group-with-shadow.svg
3277         svg/css/shadow-changes.svg
3278         svg/css/text-shadow-multiple.xhtml
3279         transitions/svg-text-shadow-transition.html
3280         svg/css/composite-shadow-text.svg
3281  
3282
3283         * platform/graphics/skia/GraphicsContextSkia.cpp:
3284         (WebCore::GraphicsContext::setPlatformShadow):
3285
3286 2011-04-21  Geoffrey Garen  <ggaren@apple.com>
3287
3288         Try to fix the Qt build.
3289
3290         * UseJSC.cmake:
3291         * WebCore.pro: Use correct file name.
3292
3293 2011-04-21  Dirk Schulze  <krit@webkit.org>
3294
3295         Unreviewed Qt build fix.
3296
3297         SVG feDropShadow implementation of SVG Filters 1.2
3298         https://bugs.webkit.org/show_bug.cgi?id=52513
3299
3300         * CodeGenerators.pri:
3301
3302 2011-04-21  Adrienne Walker  <enne@google.com>
3303
3304         Reviewed by James Robinson.
3305
3306         [chromium] Clamp dirty regions on content layers to layer bounds
3307         https://bugs.webkit.org/show_bug.cgi?id=58933
3308
3309         This prevents garbage being rendered when layers are resized and a
3310         previous invalidation (now off-layer) is no longer valid.
3311
3312         * platform/graphics/chromium/ContentLayerChromium.cpp:
3313         (WebCore::ContentLayerChromium::paintContentsIfDirty):
3314
3315 2011-04-21  Roland Steiner  <rolandsteiner@chromium.org>
3316
3317         Reviewed by Kent Tamura.
3318
3319         Bug 59012 - Shadows should be imported along with their host nodes
3320         https://bugs.webkit.org/show_bug.cgi?id=59012
3321
3322         Copy the shadow tree of an element (even on a shallow copy!).
3323
3324         Test: fast/dom/shadow/import-shadowroot.html
3325
3326         * dom/Element.cpp:
3327         (WebCore::Element::copyNonAttributeProperties):
3328         * dom/Element.h:
3329
3330 2011-04-20  Geoffrey Garen  <ggaren@apple.com>
3331
3332         Reviewed by Oliver Hunt.
3333
3334         Removed a use of markDOMObjectWrapper: CSS Object Model
3335         https://bugs.webkit.org/show_bug.cgi?id=59057
3336
3337         This is 24 hours of my life I will never get back. Thank you, W3C.
3338
3339         * GNUmakefile.list.am:
3340         * WebCore.gypi:
3341         * WebCore.vcproj/WebCore.vcproj:
3342         * WebCore.xcodeproj/project.pbxproj: Build!
3343
3344         * bindings/js/JSCSSFontFaceRuleCustom.cpp:
3345         * bindings/js/JSCSSImportRuleCustom.cpp:
3346         * bindings/js/JSCSSMediaRuleCustom.cpp:
3347         * bindings/js/JSCSSPageRuleCustom.cpp:
3348         * bindings/js/JSCSSRuleCustom.cpp:
3349         (WebCore::JSCSSRuleOwner::isReachableFromOpaqueRoots):
3350         (WebCore::JSCSSRuleOwner::finalize):
3351         (WebCore::wrapperOwner):
3352         (WebCore::wrapperContext):
3353         (WebCore::JSCSSRule::markChildren):
3354         * bindings/js/JSCSSRuleListCustom.cpp:
3355         (WebCore::JSCSSRuleListOwner::isReachableFromOpaqueRoots):
3356         (WebCore::JSCSSRuleListOwner::finalize):
3357         (WebCore::wrapperOwner):
3358         (WebCore::wrapperContext):
3359         (WebCore::toJS):
3360         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
3361         (WebCore::JSCSSStyleDeclarationOwner::isReachableFromOpaqueRoots):
3362         (WebCore::JSCSSStyleDeclarationOwner::finalize):
3363         (WebCore::wrapperOwner):
3364         (WebCore::wrapperContext):
3365         (WebCore::JSCSSStyleDeclaration::markChildren): Removed custom mark functions,
3366         and replaced with use of the opaque roots system. This has the nice benefit
3367         of allowing us to eagerly recycle far more CSS wrappers and their associated
3368         DOM wrappers.
3369
3370         (WebCore::JSCSSStyleDeclaration::getPropertyCSSValue): Made this function
3371         custom because it must maintain the sorrowful invariant that primitive
3372         values can be mapped back to objects that are reachable through the DOM.
3373         We maintain this invariant through an external hash table because
3374         making all primitive values bigger would be a too-large memory use
3375         penalty. Luckily, nobody uses this feature, so the cost of the hash table
3376         is no big deal.
3377
3378         (WebCore::toJS): We need a custom toJS so we can specify our own WeakHandleOwner.
3379
3380         * bindings/js/JSCSSStyleRuleCustom.cpp: Removed custom mark, as above.
3381
3382         * bindings/js/JSCSSValueCustom.cpp:
3383         (WebCore::cssValueRoots):
3384         (WebCore::JSCSSValueOwner::isReachableFromOpaqueRoots):
3385         (WebCore::JSCSSValueOwner::finalize):
3386         (WebCore::wrapperOwner):
3387         (WebCore::wrapperContext): Use the opaque roots system. Piggy-back on
3388         the external hash table filled by JSCSSStyleDeclaration::getPropertyCSSValue.
3389
3390         * bindings/js/JSDocumentCustom.cpp:
3391         (WebCore::JSDocument::markChildren): No need to mark our stylesheet list,
3392         since all style-related objects can use our opaque root to determine
3393         liveness.
3394
3395         * bindings/js/JSMediaListCustom.cpp: Added.
3396         (WebCore::JSMediaListOwner::isReachableFromOpaqueRoots):
3397         (WebCore::JSMediaListOwner::finalize):
3398         (WebCore::wrapperOwner):
3399         (WebCore::wrapperContext):
3400         (WebCore::toJS): Use the opaque roots system.
3401
3402         * bindings/js/JSNodeCustom.h:
3403         (WebCore::root): Added helpers for computing style-related roots.
3404
3405         * bindings/js/JSStyleSheetCustom.cpp:
3406         (WebCore::JSStyleSheetOwner::isReachableFromOpaqueRoots):
3407         (WebCore::JSStyleSheetOwner::finalize):
3408         (WebCore::wrapperOwner):
3409         (WebCore::wrapperContext):
3410         (WebCore::JSStyleSheet::markChildren): Use the opaque roots system instead
3411         of direct marking.
3412         
3413         * bindings/js/JSStyleSheetListCustom.cpp:
3414         (WebCore::JSStyleSheetListOwner::isReachableFromOpaqueRoots):
3415         (WebCore::JSStyleSheetListOwner::finalize):
3416         (WebCore::wrapperOwner):
3417         (WebCore::wrapperContext):
3418         (WebCore::toJS): Ditto.
3419
3420         * bindings/js/JSWebKitCSSKeyframeRuleCustom.cpp:
3421         * bindings/js/JSWebKitCSSKeyframesRuleCustom.cpp:
3422         * css/CSSFontFaceRule.idl:
3423         * css/CSSImportRule.idl: No more custom mark, since we use the opaque
3424         roots system instead.
3425
3426         * css/CSSMediaRule.cpp:
3427         (WebCore::CSSMediaRule::CSSMediaRule): Fixed a bug where a media rule
3428         would incorrectly have no parent, since this got in the way of correctly
3429         computing the media rule's root.
3430
3431         * css/CSSMediaRule.idl:
3432         * css/CSSPageRule.idl:
3433         * css/CSSRuleList.idl:
3434         * css/CSSStyleDeclaration.idl:
3435         * css/CSSStyleRule.idl:
3436         * css/MediaList.idl: Match behavior changes above.
3437
3438         * css/StyleBase.cpp:
3439         (WebCore::StyleBase::node): Helper function for computing roots of the
3440         style system. This object model is pretty weird and not very well factored,
3441         but I'm pretty sure this covers all the relevant cases.
3442
3443         * css/StyleBase.h:
3444         * css/StyleSheetList.idl:
3445         * css/WebKitCSSKeyframeRule.idl:
3446         * css/WebKitCSSKeyframesRule.idl: Updated to match the behavior changes above.
3447
3448 2011-04-21  Dirk Schulze  <krit@webkit.org>
3449
3450         Reviewed by Nikolas Zimmermann.
3451
3452         SVG feDropShadow implementation of SVG Filters 1.2
3453         https://bugs.webkit.org/show_bug.cgi?id=52513
3454
3455         This is the implementation of feDropShadow, a shorthand filter and a combination of feGaussianBlur,
3456         feOffset, feFlood and feComposite to create a drop shadow of an input effect.
3457         Creating this new filter effect makes it possible to optimize the often used workflow. ShadowBlur, with its
3458         fast blurring algorithm, is used to blur the shadow and composite operators are responsible for combining the
3459         source with different colored shadows.
3460         Shadow color and opacity can be set with the properties flood-color and flood-opacity.
3461
3462         Tests: svg/dynamic-updates/SVGFEDropShadowElement-dom-dx-attr.html
3463                svg/dynamic-updates/SVGFEDropShadowElement-dom-dy-attr.html
3464                svg/dynamic-updates/SVGFEDropShadowElement-dom-in-attr.html
3465                svg/dynamic-updates/SVGFEDropShadowElement-dom-shadow-color-attr.html
3466                svg/dynamic-updates/SVGFEDropShadowElement-dom-shadow-opacity-attr.html
3467                svg/dynamic-updates/SVGFEDropShadowElement-dom-stdDeviation-attr.html
3468                svg/dynamic-updates/SVGFEDropShadowElement-svgdom-dx-prop.html
3469                svg/dynamic-updates/SVGFEDropShadowElement-svgdom-dy-prop.html
3470                svg/dynamic-updates/SVGFEDropShadowElement-svgdom-in-prop.html
3471                svg/dynamic-updates/SVGFEDropShadowElement-svgdom-shadow-color-prop.html
3472                svg/dynamic-updates/SVGFEDropShadowElement-svgdom-shadow-opacity-prop.html
3473                svg/dynamic-updates/SVGFEDropShadowElement-svgdom-stdDeviation-prop.html
3474                svg/filters/feDropShadow.svg
3475
3476         * Android.mk:
3477         * CMakeLists.txt:
3478         * DerivedSources.cpp:
3479         * DerivedSources.make:
3480         * GNUmakefile.list.am:
3481         * WebCore.exp.in:
3482         * WebCore.gypi:
3483         * WebCore.pro:
3484         * WebCore.vcproj/WebCore.vcproj:
3485         * WebCore.xcodeproj/project.pbxproj:
3486         * bindings/objc/DOM.mm:
3487         (WebCore::createElementClassMap):
3488         * bindings/objc/DOMSVG.h:
3489         * page/DOMWindow.idl:
3490         * platform/graphics/ShadowBlur.cpp: Added missing copyright after r84410.
3491         * platform/graphics/ShadowBlur.h: Made blurLayerImage public.
3492         * platform/graphics/filters/FEDropShadow.cpp: Added.