8c280640c97f9433ab205ca6c5e7e257f790946e
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2012-03-22  Emil A Eklund  <eae@chromium.org>
2
3         Unreviewed, add missing import.
4
5         * rendering/RenderThemeMac.mm:
6
7 2012-03-22  Anders Carlsson  <andersca@apple.com>
8
9         ASSERT(!needsLayout) in RenderView.cpp when visiting http://www.panic.com/blog/
10         https://bugs.webkit.org/show_bug.cgi?id=81953
11         <rdar://problem/11086998>
12
13         Reviewed by Sam Weinig.
14
15         If a page ends up creating CATiledLayers, CA transactions can be committed outside of the normal
16         CA run loop observer, so we can't call setNeedsDisplay on tile cache layers directly because then
17         we'll end up calling into painting code before all the layers have been flushed.
18
19         Fix this by adding a list of dirty rects to platformCALayerDidCreateTiles and change GraphicsLayerCA to
20         mark them as dirty. This ensures that any CA transaction commits won't cause newly added layers to be painted.
21
22         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
23         (WebCore::LayerClient::platformCALayerDidCreateTiles):
24         * platform/graphics/ca/GraphicsLayerCA.cpp:
25         (WebCore::GraphicsLayerCA::platformCALayerDidCreateTiles):
26         * platform/graphics/ca/GraphicsLayerCA.h:
27         (GraphicsLayerCA):
28         * platform/graphics/ca/PlatformCALayerClient.h:
29         (PlatformCALayerClient):
30         * platform/graphics/ca/mac/TileCache.mm:
31         (WebCore::TileCache::setScale):
32         (WebCore::TileCache::revalidateTiles):
33         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
34         (WebCore::MediaPlayerPrivateQuickTimeVisualContext::LayerClient::platformCALayerDidCreateTiles):
35
36 2012-03-19  Robert Hogan  <robert@webkit.org>
37
38         Text should overflow when list item height set to 0
39         https://bugs.webkit.org/show_bug.cgi?id=78726
40
41         Reviewed by Julien Chaffraix.
42
43         Tests: css2.1/20110323/height-applies-to-010a-expected.html
44                fast/css/heightless-list-item-expected.html
45                fast/css/heightless-list-item.html
46
47         * rendering/RenderListItem.cpp:
48         (WebCore::RenderListItem::paint):
49            If the list item has height:0, only paint it if the list item allows any block or inline content 
50            to overflow unclipped. The zero-height check is a shortcut to avoid unnecessary painting and 
51            this seems to be the only case where there's something to do.
52
53 2012-03-22  Dave Michael  <dmichael@chromium.org>
54
55         HTMLPluginElement is not destroyed on reload or navigation if getNPObject is called
56         https://bugs.webkit.org/show_bug.cgi?id=80428
57
58         Reviewed by Eric Seidel.
59
60         Make HTMLPluginElement release its m_NPObject in detach() to break a
61         reference-counting cycle that happens on reload or navigation. With this
62         change, HTMLPlugInElement::removedFromDocument is unnecessary, so it
63         was removed. Note that Releasing m_NPObject does not result in a call to
64         the plugin; it simply releases a reference count on the wrapper object
65         for this HTMLPlugInElement. (The plugin's NPP_Deallocate is invoked
66         when the render tree is destroyed, when PluginView calls
67         PluginPackage::unload.) Thus, it is safe to release m_NPObject in
68         detach, because it can not result in layout or style changes.
69
70         Also added numberOfLiveNodes() and numberOfLiveDocuments() to
71         window.internals to enable testing.
72
73         Test: plugins/netscape-dom-access-and-reload.html
74
75         * WebCore.exp.in:
76         * html/HTMLPlugInElement.cpp:
77         (WebCore::HTMLPlugInElement::detach):
78         * html/HTMLPlugInElement.h:
79         (HTMLPlugInElement):
80         * testing/Internals.cpp:
81         (WebCore::Internals::numberOfLiveDocuments):
82         (WebCore::Internals::numberOfLiveNodes):
83         (WebCore):
84         * testing/Internals.h:
85         (Internals):
86         * testing/Internals.idl:
87
88 2012-03-22  Shawn Singh  <shawnsingh@chromium.org>
89
90         [chromium] Make CCDamageTracker robust to empty layer lists
91         https://bugs.webkit.org/show_bug.cgi?id=81831
92
93         Reviewed by Adrienne Walker.
94
95         Added a unit test in CCDamageTrackerTest that causes a crash in
96         the old code. With this patch applied, the crash will not occur.
97         In theory, that crash should never occur anyway, unless there is a
98         bug outside the damage tracker, but for robustness it's
99         appropriate to handle it properly.
100
101         In addition to this fix, performed some trivial maintenance on the
102         damage tracker code.
103
104         * platform/graphics/chromium/cc/CCDamageTracker.cpp:
105         (WebCore::CCDamageTracker::updateDamageTrackingState): removed
106         unclean code that accessed the targetSurface to get necessary
107         information. Instead, we now pass those args through the damage
108         tracker's API.
109
110         * platform/graphics/chromium/cc/CCDamageTracker.h:
111         (CCDamageTracker): modified args passed to damage tracker on update.
112
113         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
114         (WebCore::CCLayerTreeHostImpl::trackDamageForAllSurfaces):
115         modified args passed to damage tracker on update.
116
117 2012-03-22  Julien Chaffraix  <jchaffraix@webkit.org>
118
119         Enable style sharing for elements with a style attribute
120         https://bugs.webkit.org/show_bug.cgi?id=81523
121
122         Reviewed by Antti Koivisto.
123
124         Memory improvement change only.
125
126         Overall, this is a performance wash (some benchmarks may regress a bit due to the increase in time taken
127         by CSSStyleSelector::locateSharedStyle as we try more nodes, others increase their performance due to style sharing).
128
129         Instrumenting our style sharing, this should give us some nice memory shavings on some benchmarks:
130         - HTML5 isn't impacted as it doesn't use much inline style
131         - page cyclers' intl1 showed a 6% increase in style sharing.
132
133         * css/CSSStyleSelector.cpp:
134         (WebCore::CSSStyleSelector::canShareStyleWithElement):
135         This method now handles inline style like presentation attributes on the element.
136
137         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
138         (WebCore::CSSStyleSelector::locateSharedStyle):
139         Don't bail out for an element with an inline style declaration.
140
141         (WebCore::CSSStyleSelector::stylesEqual):
142         Generalized attributeStylesEqual to share the logic between attribute and
143         inline style property set. This means that attribute checks are actually
144         doing a little extra more work but that didn't impact our benchmarks.
145
146 2012-03-22  Kevin Ollivier  <kevino@theolliviers.com>
147
148         [wx] Unreviewed. WebDOM build fix after array type changes.
149
150         * bindings/scripts/CodeGeneratorCPP.pm:
151         (ShouldSkipType):
152
153 2012-03-22  Pavel Feldman  <pfeldman@chromium.org>
154
155         Web Inspector: text gutter decorations should move upon edits.
156         https://bugs.webkit.org/show_bug.cgi?id=81932
157
158         Reviewed by Vsevolod Vlasov.
159
160         Decorations set by the line number now shift as editing inserts / removes lines.
161
162         * inspector/front-end/TextViewer.js:
163         (WebInspector.TextViewer.prototype._syncLineHeight):
164         (WebInspector.TextEditorGutterPanel):
165         (WebInspector.TextEditorGutterPanel.prototype.textChanged):
166         (WebInspector.TextEditorGutterPanel.prototype.syncClientHeight):
167         (WebInspector.TextEditorGutterPanel.prototype.addDecoration):
168         (WebInspector.TextEditorGutterPanel.prototype.removeDecoration):
169
170 2012-03-21  Robert Hogan  <robert@webkit.org>
171
172         CSS 2.1 failure: fixed-table-layout-006 fails
173         https://bugs.webkit.org/show_bug.cgi?id=78412
174
175         Reviewed by Julien Chaffraix.
176
177         Tests: css2.1/20110323/fixed-table-layout-006.htm
178                fast/css/fixed-table-layout-cell-padding.htm
179
180         In fixed tables, positive width specified on a column should include borders and padding.
181         See the thread at http://lists.w3.org/Archives/Public/www-style/2011Oct/0502.html. The discussion
182         there resulted in a whole new set of tests for section 17.5.2.1 in the CSS 2.1 spec. See 
183         http://test.csswg.org/harness/test/CSS21_DEV/section/17.5.2.1/. This patch allows WebKit
184         to pass all of them, and all tests for the 17.5.2.1 section as a whole. I'll land them all separately.
185     
186         * rendering/FixedTableLayout.cpp:
187         (WebCore::FixedTableLayout::calcWidthArray): Include border width and cell padding in the width of the column.
188          Note that borderAndPaddingLogicalWidth() returns the border width for separate and collapsed borders as appropriate.
189
190 2012-03-22  Simon Fraser  <simon.fraser@apple.com>
191
192         Factor compositing layer updates after scroll into a new method
193         https://bugs.webkit.org/show_bug.cgi?id=81943
194
195         Reviewed by Dean Jackson.
196
197         Move some code that updates compositing layers after scrolling
198         into its own method, for cleanliness.
199
200         * rendering/RenderLayer.cpp:
201         (WebCore::RenderLayer::scrollTo):
202         (WebCore::RenderLayer::updateCompositingLayersAfterScroll):
203         (WebCore):
204         * rendering/RenderLayer.h:
205         (RenderLayer):
206
207 2012-03-22  Gavin Barraclough  <barraclough@apple.com>
208
209         Add JSValue::isFunction
210         https://bugs.webkit.org/show_bug.cgi?id=81935
211
212         Reviewed by Geoff Garen.
213
214         This would be useful in the WebCore bindings code.
215         Also, remove asFunction, replace with jsCast<JSFunction*>.
216
217         * bindings/js/JSInjectedScriptHostCustom.cpp:
218         (WebCore::JSInjectedScriptHost::functionDetails):
219         * bindings/js/ScriptCallStackFactory.cpp:
220         (WebCore::createScriptCallStack):
221
222 2012-03-22  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
223
224         TiledBackingStore: Fix test regressions that appeared with r111560.
225         https://bugs.webkit.org/show_bug.cgi?id=81519
226
227         Reviewed by Kenneth Rohde Christiansen.
228
229         The visible rect wasn't intersected with the contents rect anymore which
230         could lead to an astronomical layer size to check for intersecting tiles.
231
232         Add a visibleContentsRect that doesn't do the conversion and use it
233         in visibleAreaIsCovered.
234
235         * platform/graphics/TiledBackingStore.cpp:
236         (WebCore::TiledBackingStore::visibleContentsRect):
237         (WebCore):
238         (WebCore::TiledBackingStore::visibleRect):
239         (WebCore::TiledBackingStore::visibleAreaIsCovered):
240         * platform/graphics/TiledBackingStore.h:
241         (TiledBackingStore):
242
243 2012-03-22  Joe Thomas  <joethomas@motorola.com>
244
245         Make Length Calculation functions non-inline
246         https://bugs.webkit.org/show_bug.cgi?id=81733
247
248         Currently length calculation functions in LengthFunctions.h are inline. These functions are pretty big to be inline.
249         And these functions are expected to grow again when new length units will be introduced in bug 27160.
250
251         A decent rule of thumb is to not inline a function if it is more than 10 lines long. Also it's typically not cost effective to inline
252         functions with loops or switch statements. (Reference: http://google-styleguide.googlecode.com/svn/trunk/cppguide.xml#Inline_Functions).
253
254         Ran PerformanceTests/Parser/html5-full-render.html on Mac Snow-Leopard with and without the patch and did not see much performance difference.
255
256         Reviewed by Antti Koivisto.
257
258         * CMakeLists.txt:
259         * GNUmakefile.list.am:
260         * Target.pri:
261         * WebCore.gypi:
262         * WebCore.vcproj/WebCore.vcproj:
263         * WebCore.xcodeproj/project.pbxproj:
264         * css/LengthFunctions.cpp: Added.
265         (WebCore):
266         (WebCore::miminumValueForLength):
267         (WebCore::valueForLength):
268         (WebCore::floatValueForLength):
269         * css/LengthFunctions.h:
270         (WebCore):
271
272 2012-03-22  Alexis Menard  <alexis.menard@openbossa.org>
273
274         Increase code sharing between CSSParser and CSSPropertyLonghand.
275         https://bugs.webkit.org/show_bug.cgi?id=81587
276
277         Reviewed by Antti Koivisto.
278
279         Expose the longhands declaration for a given shorthand in CSSPropertyLonghand and
280         make CSSParser use them. It will make the declaration of longhands in one place only.
281         Remove the map of CSSPropertyLonghand and replace it by a regular switch/case.
282         The map doesn't bring much here and it's cleaner and faster to use the switch.
283         It also shows a little performance improvement in CSS/CSSPropertySetterGetter.html.
284
285         No new tests : no behavior change.
286
287         * css/CSSParser.cpp:
288         (WebCore::CSSParser::parseValue):
289         (WebCore::CSSParser::parseAnimationShorthand):
290         (WebCore::CSSParser::parseTransitionShorthand):
291         (WebCore::CSSParser::parseShorthand):
292         Modify the prototype of this function to directly use the CSSPropertyLonghand.
293         * css/CSSParser.h:
294         (WebCore):
295         (CSSParser):
296         * css/CSSPropertyLonghand.cpp:
297         (WebCore):
298         (WebCore::backgroundLonghand):
299         (WebCore::backgroundPositionLonghand):
300         (WebCore::backgroundRepeatLonghand):
301         (WebCore::borderLonghand):
302         (WebCore::borderBottomLonghand):
303         (WebCore::borderColorLonghand):
304         (WebCore::borderImageLonghand):
305         (WebCore::borderLeftLonghand):
306         (WebCore::borderRadiusLonghand):
307         (WebCore::borderRightLonghand):
308         (WebCore::borderSpacingLonghand):
309         (WebCore::borderStyleLonghand):
310         (WebCore::borderTopLonghand):
311         (WebCore::borderWidthLonghand):
312         (WebCore::listStyleLonghand):
313         (WebCore::fontLonghand):
314         (WebCore::marginLonghand):
315         (WebCore::outlineLonghand):
316         (WebCore::overflowLonghand):
317         (WebCore::paddingLonghand):
318         (WebCore::webkitAnimationLonghand):
319         (WebCore::webkitBorderAfterLonghand):
320         (WebCore::webkitBorderBeforeLonghand):
321         (WebCore::webkitBorderEndLonghand):
322         (WebCore::webkitBorderStartLonghand):
323         (WebCore::webkitColumnsLonghand):
324         (WebCore::webkitColumnRuleLonghand):
325         (WebCore::webkitFlexFlowLonghand):
326         (WebCore::webkitMarginCollapseLonghand):
327         (WebCore::webkitMarqueeLonghand):
328         (WebCore::webkitMaskLonghand):
329         (WebCore::webkitMaskPositionLonghand):
330         (WebCore::webkitMaskRepeatLonghand):
331         (WebCore::webkitTextEmphasisLonghand):
332         (WebCore::webkitTextStrokeLonghand):
333         (WebCore::webkitTransitionLonghand):
334         (WebCore::webkitTransformOriginLonghand):
335         (WebCore::webkitWrapLonghand):
336         (WebCore::longhandForProperty):
337         * css/CSSPropertyLonghand.h:
338         (WebCore):
339
340 2012-03-22  Emil A Eklund  <eae@chromium.org>
341
342         Unreviewed, touching file to force bots to pick up CSS_SHADERS flag change. 
343
344         * css/CSSStyleSelector.h:
345         (CSSStyleSelector):
346
347 2012-03-22  Xingnan Wang  <xingnan.wang@intel.com>
348
349         ReverbConvolver::latencyFrames() should return 0.
350         https://bugs.webkit.org/show_bug.cgi?id=81806
351
352         Reviewed by Chris Rogers.
353
354         * platform/audio/ReverbConvolver.cpp:
355         (WebCore::ReverbConvolver::latencyFrames):
356
357 2012-03-22  Tony Chang  <tony@chromium.org>
358
359         refactor flexbox in preparation for flex-line-pack
360         https://bugs.webkit.org/show_bug.cgi?id=81843
361
362         Reviewed by Ojan Vafai.
363
364         Replace WrapReverseContext with a vector of LineContexts that contain
365         the same information, plus values needed for flex-align.
366
367         alignChildren has been moved to after all the lines have been
368         positioned. We want to align children after flex-line-pack has changed
369         the size of each line to avoid unnecessary layouts.
370
371         Take 2: Remove the assert. If there are no children, then there are no
372         flex lines. Instead, assert that child is not null.
373
374         No new tests, just refactoring.
375
376         * rendering/RenderFlexibleBox.cpp:
377         (WebCore::RenderFlexibleBox::LineContext::LineContext): New struct,
378         holds information needed for wrap-reverse and aligning children.
379         (RenderFlexibleBox::LineContext):
380         (WebCore::RenderFlexibleBox::layoutFlexItems): alignChildren after layout out all the lines rather than after each line.
381         (WebCore::RenderFlexibleBox::layoutAndPlaceChildren): don't alignChildren
382         (WebCore::RenderFlexibleBox::alignChildren): align all flex items, not just a line at a time.
383         (WebCore::RenderFlexibleBox::flipForWrapReverse): Update to use LineContext
384         * rendering/RenderFlexibleBox.h:
385
386 2012-03-22  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
387
388         Event dispatching in XMLHttpRequestProgressEventThrottle should go through XMLHttpRequestProgressEventThrottle::dispatchEvent
389         https://bugs.webkit.org/show_bug.cgi?id=46743
390
391         Reviewed by Julien Chaffraix
392         Based on original patch by Anton D'Auria
393
394         In preparation for platform-specific queuing of XMLHttpRequest events,
395         this patch changes all calls to m_target->dispatchEvent to
396         XMLHttpRequestProgressEventThrottle::dispatchEvent.
397         Currently, we queue only one progress event on suspend() if we have
398         throttled progress events. We should be able to queue all XHR events
399         that can be generated after suspend(), if the platform network layer
400         continues to receive data.
401         XMLHttpRequest uses XMLHttpRequestProgressEventThrottle to dispatch only
402         download events, so this doesn't change behavior of upload events, which
403         aren't throttled or queued.
404
405         * xml/XMLHttpRequest.cpp:
406         (WebCore::XMLHttpRequest::callReadyStateChangeListener):
407         * xml/XMLHttpRequestProgressEventThrottle.cpp:
408         (WebCore::XMLHttpRequestProgressEventThrottle::dispatchReadyStateChangeEvent):
409         (WebCore::XMLHttpRequestProgressEventThrottle::dispatchEvent):
410         (WebCore::XMLHttpRequestProgressEventThrottle::flushProgressEvent):
411         (WebCore::XMLHttpRequestProgressEventThrottle::dispatchPausedEvent):
412         (WebCore::XMLHttpRequestProgressEventThrottle::fired):
413         * xml/XMLHttpRequestProgressEventThrottle.h:
414         (XMLHttpRequestProgressEventThrottle):
415
416 2012-03-22  Sudarsana Nagineni  <sudarsana.nagineni@linux.intel.com>
417
418         [EFL] Map BackSpace key code to Unicode value
419         https://bugs.webkit.org/show_bug.cgi?id=81130
420
421         Reviewed by Gustavo Noronha Silva.
422
423         Test: fast/events/backspace-navigates-back.html
424
425         * platform/efl/EflKeyboardUtilities.cpp:
426         (WebCore::createKeyMap): Map BackSpace to Unicode value
427
428 2012-03-22  Abhishek Arya  <inferno@chromium.org>
429
430         Incorrect beforeChild parent calculation in RenderRubyBase::moveChildren.
431         https://bugs.webkit.org/show_bug.cgi?id=80297
432
433         Reviewed by Julien Chaffraix.
434
435         beforeChild might share the same anonymous block parent with other previous
436         siblings. Before moving the children across ruby bases, we need to make sure
437         to split the tree across the beforeChild correctly.
438
439         Test: fast/ruby/ruby-text-before-child-split.html
440
441         * rendering/RenderRubyBase.cpp:
442         (WebCore::RenderRubyBase::moveChildren):
443
444 2012-03-22  Kristóf Kosztyó  <kkristof@inf.u-szeged.hu>
445
446         [Qt] Fix Qt minimal build after r111692
447
448         Reviewed by Csaba Osztrogonác.
449
450         * bindings/js/JSScriptProfileNodeCustom.cpp:
451
452 2012-03-22  Adrienne Walker  <enne@google.com>
453
454         [chromium] Fix scrollbar layers holding onto invalid textures after lost context
455         https://bugs.webkit.org/show_bug.cgi?id=81841
456
457         Reviewed by James Robinson.
458
459         Unit test: CCLayerTreeHostImplTest.scrollbarLayerLostContext
460
461         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.cpp:
462         (WebCore::CCScrollbarLayerImpl::willDraw):
463
464 2012-03-22  Philippe Normand  <pnormand@igalia.com>
465
466         [GTK] ASSERT bug in WebAudio (AudioFileReader)
467         https://bugs.webkit.org/show_bug.cgi?id=81777
468
469         Reviewed by Martin Robinson.
470
471         * platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
472         (WebCore::AudioFileReader::decodeAudioForBusCreation): Don't steal
473         the GstBus floating reference.
474         (WebCore::AudioFileReader::createBus): Ditto.
475
476 2012-03-22  Ilya Tikhonovsky  <loislo@chromium.org>
477
478         Unreviewed: Web Inspector: fix syntax error in text.
479
480         * English.lproj/localizedStrings.js:
481         * inspector/front-end/HeapSnapshotProxy.js:
482         (WebInspector.HeapSnapshotWorker.prototype._messageReceived):
483
484 2012-03-22  Sheriff Bot  <webkit.review.bot@gmail.com>
485
486         Unreviewed, rolling out r111688.
487         http://trac.webkit.org/changeset/111688
488         https://bugs.webkit.org/show_bug.cgi?id=81912
489
490         "Heap profiler test fails" (Requested by yurys on #webkit).
491
492         * inspector/front-end/HeapSnapshot.js:
493         (WebInspector.HeapSnapshot.prototype._buildRetainers):
494
495 2012-03-22  Dana Jansens  <danakj@chromium.org>
496
497         [chromium] Early out in a new prepareToDraw() step if checkerboarding an accelerated animation in order to skip the frame
498         https://bugs.webkit.org/show_bug.cgi?id=81437
499
500         Reviewed by Adrienne Walker.
501
502         Split CCLayerTreeHostImpl::drawLayers() into two phases:
503         prepareToDraw() and drawLayers().
504
505         When calculating a RenderPass, and we checkerboard a quad on a
506         layer, bubble this info back up to CCLayerTreeHostImpl. If the
507         layer is transforming in an animation, then abort the prepareToDraw()
508         phase and cause it to return false back to the thread proxy.
509
510         Unit test: CCLayerTreeHostImplTest.prepareToDrawFailsWhenAnimationUsesCheckerboard
511
512         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
513         (WebCore::CCLayerImpl::appendQuads):
514         * platform/graphics/chromium/cc/CCLayerImpl.h:
515         (CCLayerImpl):
516         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
517         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
518         (WebCore::CCLayerTreeHostImpl::prepareToDraw):
519         (WebCore):
520         (WebCore::CCLayerTreeHostImpl::drawLayers):
521         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
522         (CCLayerTreeHostImpl):
523         (FrameData):
524         * platform/graphics/chromium/cc/CCQuadCuller.cpp:
525         (WebCore::CCQuadCuller::append):
526         * platform/graphics/chromium/cc/CCQuadCuller.h:
527         (CCQuadCuller):
528         * platform/graphics/chromium/cc/CCRenderPass.cpp:
529         (WebCore::CCRenderPass::appendQuadsForLayer):
530         * platform/graphics/chromium/cc/CCRenderPass.h:
531         (CCRenderPass):
532         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.cpp:
533         (WebCore::CCScrollbarLayerImpl::appendQuads):
534         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.h:
535         (CCScrollbarLayerImpl):
536         * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
537         (WebCore::CCSingleThreadProxy::doComposite):
538         * platform/graphics/chromium/cc/CCSolidColorLayerImpl.cpp:
539         (WebCore::CCSolidColorLayerImpl::appendQuads):
540         * platform/graphics/chromium/cc/CCSolidColorLayerImpl.h:
541         (CCSolidColorLayerImpl):
542         * platform/graphics/chromium/cc/CCTextureLayerImpl.cpp:
543         (WebCore::CCTextureLayerImpl::appendQuads):
544         * platform/graphics/chromium/cc/CCTextureLayerImpl.h:
545         (CCTextureLayerImpl):
546         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
547         (WebCore::CCThreadProxy::scheduledActionDrawAndSwap):
548         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
549         (WebCore::CCTiledLayerImpl::appendQuads):
550         * platform/graphics/chromium/cc/CCTiledLayerImpl.h:
551         (CCTiledLayerImpl):
552         * platform/graphics/chromium/cc/CCVideoLayerImpl.cpp:
553         (WebCore::CCVideoLayerImpl::appendQuads):
554         * platform/graphics/chromium/cc/CCVideoLayerImpl.h:
555         (CCVideoLayerImpl):
556
557 2012-03-22  Levi Weintraub  <leviw@chromium.org>
558
559         Correct LayoutUnit usage in Accessibility code
560         https://bugs.webkit.org/show_bug.cgi?id=81789
561
562         Reviewed by Eric Seidel.
563
564         Reverting Accessibility hit testing code back to integers. Accessibility hit tests originate from
565         the embedder and don't accumulate offsets, so we get nothing from using LayoutUnits, and needlessly
566         expose them to the embedder.
567
568         No new tests. No change in behavior.
569
570         * accessibility/AccessibilityListBox.cpp:
571         (WebCore::AccessibilityListBox::elementAccessibilityHitTest): See above.
572         * accessibility/AccessibilityListBox.h:
573         (AccessibilityListBox):
574         * accessibility/AccessibilityObject.cpp:
575         (WebCore::AccessibilityObject::clickPoint): This value is only ever used to display a context menu,
576         which is always done with integer coordinates.
577         (WebCore::AccessibilityObject::boundingBoxForQuads): This is a bounding box built from floats. We
578         don't pixel snap floats, so we return an integer bounding box.
579         (WebCore::AccessibilityObject::elementAccessibilityHitTest): See above.
580         (WebCore::AccessibilityObject::scrollToMakeVisible): Pixel snapping the bounding box and simplifying
581         up the code to position it at (0,0).
582         * accessibility/AccessibilityObject.h:
583         (WebCore::AccessibilityObject::accessibilityHitTest): See above.
584         (AccessibilityObject):
585         (WebCore::AccessibilityObject::pixelSnappedBoundingBoxRect): Convenience method for embedder callers.
586         * accessibility/AccessibilityRenderObject.cpp:
587         (WebCore::AccessibilityRenderObject::visiblePositionForPoint): The point passed in here is comes from
588         screen coordinates and originates in embedder code. Reverting it to take an integer.
589         (WebCore::AccessibilityRenderObject::accessibilityImageMapHitTest): See above.
590         (WebCore::AccessibilityRenderObject::accessibilityHitTest): See above.
591         * accessibility/AccessibilityRenderObject.h:
592         (AccessibilityRenderObject):
593         * accessibility/AccessibilityScrollView.cpp:
594         (WebCore::AccessibilityScrollView::accessibilityHitTest): See above.
595         * accessibility/AccessibilityScrollView.h:
596         (AccessibilityScrollView):
597         * accessibility/AccessibilitySlider.cpp:
598         (WebCore::AccessibilitySlider::elementAccessibilityHitTest): See above.
599         * accessibility/AccessibilitySlider.h:
600         (AccessibilitySlider):
601
602 2012-03-21  Ilya Tikhonovsky  <loislo@chromium.org>
603
604         Web Inspector: HeapProfiler: Heap snapshot worker has to report the errors to the front-end
605         https://bugs.webkit.org/show_bug.cgi?id=81804
606
607         Sometimes the worker process of HeapSnapshot does some wrong thing and throw an Exception.
608         At this momemnt we have no way to see the error in the front-end.
609
610         Reviewed by Yury Semikhatsky.
611
612         * English.lproj/localizedStrings.js:
613         * inspector/front-end/HeapSnapshotProxy.js: check the exception field and dump it into front-end's console.
614         (WebInspector.HeapSnapshotWorker.prototype._messageReceived):
615         * inspector/front-end/HeapSnapshotWorkerDispatcher.js: catch the exception and transfer it's text to requester's side.
616         (WebInspector.HeapSnapshotWorkerDispatcher.prototype.dispatchMessage):
617
618 2012-03-22  Carlos Garcia Campos  <cgarcia@bb-webkit-rel-64.local.igalia.com>
619
620         [GTK] Use the angle-bracket form to include wtf headers
621         https://bugs.webkit.org/show_bug.cgi?id=81884
622
623         Reviewed by Eric Seidel.
624
625         Use #include <wtf/foo> instead of #include "foo".
626
627         * platform/graphics/freetype/FontPlatformData.h:
628         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
629         * platform/gtk/DataObjectGtk.h:
630         * platform/network/ResourceHandleInternal.h:
631         * platform/network/soup/SocketStreamHandleSoup.cpp:
632
633 2012-03-22  Alexander Pavlov  <apavlov@chromium.org>
634
635         Web Inspector: Case of the elements of the xml document should be shown as it is in the console
636         https://bugs.webkit.org/show_bug.cgi?id=81902
637
638         When registering a detached root, DOMAgent always presumes it is a node,
639         while it can also be a document.
640
641         Reviewed by Vsevolod Vlasov.
642
643         Test: inspector/console/console-xml-document.html
644
645         * inspector/front-end/ConsoleMessage.js:
646         (WebInspector.ConsoleMessageImpl.prototype._formatParameterAsNode):
647         * inspector/front-end/DOMAgent.js:
648         (WebInspector.DOMAgent.prototype._setDetachedRoot):
649
650 2012-03-22  Vsevolod Vlasov  <vsevik@chromium.org>
651
652         Web Inspector: Introduce ScriptBound/ScriptUnbound events in ScriptMapping.
653         https://bugs.webkit.org/show_bug.cgi?id=81904
654
655         Reviewed by Pavel Feldman.
656
657         This is another step on the way to cleaner BreakpointManager logic.
658         Here we extract ScriptBound/ScriptUnbound events from UISourceCodeListChanged event.
659         This allows us to handle script-uiSourceCode binding separately from
660         uiSourceCode creation/deletion and to handle unbinding that was not
661         possible at all before.
662
663         * inspector/front-end/CompilerScriptMapping.js:
664         (WebInspector.CompilerScriptMapping.prototype._uiSourceCodesForSourceMap):
665         (WebInspector.CompilerScriptMapping.prototype.addScript.get this):
666         (WebInspector.CompilerScriptMapping.prototype.addScript):
667         (WebInspector.CompilerScriptMapping.prototype.reset):
668         * inspector/front-end/ResourceScriptMapping.js:
669         (WebInspector.ResourceScriptMapping.prototype._uiSourceCodeChanged):
670         * inspector/front-end/ScriptMapping.js:
671         (WebInspector.MainScriptMapping):
672         (WebInspector.MainScriptMapping.prototype._updateLiveLocation):
673         (WebInspector.MainScriptMapping.prototype._handleUISourceCodeListChanged):
674         (WebInspector.MainScriptMapping.prototype._handleScriptBound):
675         (WebInspector.MainScriptMapping.prototype._handleScriptUnbound):
676         * inspector/front-end/SnippetsModel.js:
677         (WebInspector.SnippetsScriptMapping.prototype.addScript.get this):
678         (WebInspector.SnippetsScriptMapping.prototype._snippetAdded):
679         (WebInspector.SnippetsScriptMapping.prototype._createUISourceCodeForScript):
680         (WebInspector.SnippetsScriptMapping.prototype._snippetRemoved.get this):
681         (WebInspector.SnippetsScriptMapping.prototype._snippetRemoved):
682         (WebInspector.SnippetsScriptMapping.prototype.reset):
683
684 2012-03-22  Vineet Chaudhary  <rgf748@motorola.com>
685
686         https://bugs.webkit.org/show_bug.cgi?id=81893
687         Remove custom bindings form ScriptProfileNode.idl of attribute type Array.
688
689         Reviewed by Kentaro Hara.
690
691         Replace [CustomGetter] Array with sequence<ScriptProfileNode>.
692         To remove the custom bindings code.
693
694         Test: No new tests. LayoutTests/fast/profiler/* test are enough for this.
695
696         * bindings/js/JSScriptProfileNodeCustom.cpp: Removed custom function.
697         (WebCore::JSScriptProfileNode::callUID):
698         * bindings/v8/custom/V8ScriptProfileNodeCustom.cpp: Removed custom function.
699         (WebCore):
700         * inspector/ScriptProfileNode.idl: Replaced Array with sequence<ScriptProfileNode>.
701
702 2012-03-22  Andrey Kosyakov  <caseq@chromium.org>
703
704         Web Inspector: only update timeline overview categories strips when these are visible
705         https://bugs.webkit.org/show_bug.cgi?id=81903
706
707         Reviewed by Pavel Feldman.
708
709         - factor out category strips update into a separate method;
710         - only invoke it when "Timeline" overview mode is selected.
711
712         * inspector/front-end/TimelineOverviewPane.js:
713         (WebInspector.TimelineOverviewPane.prototype._showTimelines):
714         (WebInspector.TimelineOverviewPane.prototype.update):
715         (WebInspector.TimelineOverviewPane.prototype._updateCategoryStrips):
716
717 2012-03-22  Levi Weintraub  <leviw@chromium.org>
718
719         Update LayoutUnit usage in FrameSelection
720         https://bugs.webkit.org/show_bug.cgi?id=81754
721
722         Reviewed by Eric Seidel.
723
724         FrameSelection stores its caret and repaint bounds in absolute coordinates. Absolute coordinates
725         we treat as pixel values, so this patch changes these values to integers. Sub-pixel precision
726         will still be used when these coordinates are passed down and used locally.
727
728         No new tests. No change in behavior.
729
730         * editing/FrameSelection.cpp:
731         (WebCore::absoluteCaretY): Uses absolute coordinates, which are ints.
732         (WebCore::FrameSelection::modify): Uses absolute coordinates to handle vertical selection
733         modification. Sub-pixel precision will be used when these values are converted to local ones.
734         (WebCore::CaretBase::absoluteBoundsForLocalRect): Absolute coordinates -> ints.
735         (WebCore::FrameSelection::absoluteCaretBounds): Ditto.
736         (WebCore::CaretBase::caretRepaintRect): The caret repaint rect is stored in absolute coordinates.
737         Reverting the values to ints.
738         (WebCore::FrameSelection::recomputeCaretRect): Ditto.
739         * editing/FrameSelection.h:
740         (FrameSelection):
741         * editing/mac/FrameSelectionMac.mm:
742         (WebCore::FrameSelection::notifyAccessibilityForSelectionChange): Switching to store absolute
743         coordinates as integers.
744
745 2012-03-22  Alexei Filippov  <alexeif@chromium.org>
746
747         Web Inspector: Speed up the build retainers phase.
748         https://bugs.webkit.org/show_bug.cgi?id=81763
749
750         Replacing the edge iterator with a raw loop makes it
751         faster by more than 10 times.
752
753         Reviewed by Yury Semikhatsky.
754
755         * inspector/front-end/HeapSnapshot.js:
756         (WebInspector.HeapSnapshot.prototype._buildRetainers):
757
758 2012-03-22  No'am Rosenthal  <noam.rosenthal@nokia.com>
759
760         [Qt][WK2] The background appears to have one extra pixel from the contents
761         https://bugs.webkit.org/show_bug.cgi?id=81830
762
763         Reviewed by Kenneth Rohde Christiansen.
764
765         TextureMapperGL applied a 1-offset that was covering for another bug,
766         which was already fixed.
767
768         No new tests, this would be tested once we test GL rendering results.
769
770         * platform/graphics/texmap/TextureMapperGL.cpp:
771         (WebCore::TextureMapperGLData::SharedGLData::scissorClip):
772
773 2012-03-22  W. James MacLean  <wjmaclean@chromium.org>
774
775         Rename touchpad fling curve, add curve parameters to constructor.
776         https://bugs.webkit.org/show_bug.cgi?id=81820
777
778         Reviewed by Adrienne Walker.
779
780         Covered by existing unit tests.
781
782         * GNUmakefile.list.am:
783         * WebCore.gypi:
784         * platform/ScrollAnimatorNone.cpp:
785         (WebCore::ScrollAnimatorNone::fireUpAnAnimation):
786         * platform/TouchpadFlingPlatformGestureCurve.cpp: Renamed from Source/WebCore/platform/TouchFlingPlatformGestureCurve.cpp.
787         (WebCore):
788         (WebCore::TouchpadFlingPlatformGestureCurve::create):
789         (WebCore::TouchpadFlingPlatformGestureCurve::TouchpadFlingPlatformGestureCurve):
790         (WebCore::TouchpadFlingPlatformGestureCurve::~TouchpadFlingPlatformGestureCurve):
791         (WebCore::TouchpadFlingPlatformGestureCurve::apply):
792         * platform/TouchpadFlingPlatformGestureCurve.h: Renamed from Source/WebCore/platform/TouchFlingPlatformGestureCurve.h.
793         (WebCore):
794         (TouchpadFlingPlatformGestureCurve):
795
796 2012-03-22  Pavel Feldman  <pfeldman@chromium.org>
797
798         Web Inspector: make CSS and JavaScript files editable by default.
799         https://bugs.webkit.org/show_bug.cgi?id=81787
800
801         Reviewed by Vsevolod Vlasov.
802
803         This change removes cancelEditing and setReadOnly capabilities from source frame.
804         It removes dblclick handler as well since one does not need to enter editing mode.
805         It also establishes proper content dispatching so that views are updated with the
806         resource content. All these are inter-dependent, need to be landed simultaneously.
807         Drive-by follow up to the r111675 where range is modified prior to the exiting
808         edit mode.
809
810         * inspector/front-end/JavaScriptSourceFrame.js:
811         (WebInspector.JavaScriptSourceFrame):
812         (WebInspector.JavaScriptSourceFrame.prototype.requestContent):
813         (WebInspector.JavaScriptSourceFrame.prototype.afterTextChanged):
814         (WebInspector.JavaScriptSourceFrame.prototype.beforeTextChanged):
815         (WebInspector.JavaScriptSourceFrame.prototype.didEditContent):
816         (WebInspector.JavaScriptSourceFrame.prototype._lineNumberAfterEditing):
817         * inspector/front-end/ResourceView.js:
818         (WebInspector.ResourceSourceFrame):
819         (WebInspector.ResourceSourceFrame.prototype.suggestedFileName):
820         (WebInspector.ResourceSourceFrame.prototype._contentChanged):
821         (WebInspector.EditableResourceSourceFrame.prototype.canEditSource):
822         (WebInspector.EditableResourceSourceFrame.prototype.editContent.callbackWrapper):
823         (WebInspector.EditableResourceSourceFrame.prototype.editContent):
824         (WebInspector.EditableResourceSourceFrame.prototype._contentChanged):
825         * inspector/front-end/ResourcesPanel.js:
826         (WebInspector.ResourcesPanel.prototype._innerShowView):
827         (WebInspector.FrameResourceTreeElement.prototype._appendRevision):
828         * inspector/front-end/ScriptsPanel.js:
829         (WebInspector.ScriptsPanel.prototype.setScriptSourceIsDirty):
830         * inspector/front-end/Settings.js:
831         (WebInspector.ExperimentsSettings):
832         * inspector/front-end/SourceFrame.js:
833         (WebInspector.SourceFrame):
834         (WebInspector.SourceFrame.prototype.wasShown):
835         (WebInspector.SourceFrame.prototype.willHide):
836         (WebInspector.SourceFrame.prototype.beforeTextChanged):
837         (WebInspector.SourceFrame.prototype.setContent):
838         (WebInspector.SourceFrame.prototype.commitEditing):
839         (WebInspector.SourceFrame.prototype.didEditContent):
840         (WebInspector.SourceFrame.prototype.editContent):
841         * inspector/front-end/TextPrompt.js:
842         (WebInspector.TextPrompt.prototype._startEditing):
843         (WebInspector.TextPrompt.prototype._stopEditing):
844         * inspector/front-end/TextViewer.js:
845         (WebInspector.TextViewer):
846         (WebInspector.TextViewer.prototype._registerShortcuts):
847         (WebInspector.TextEditorMainPanel.prototype.handleEnterKey):
848
849 2012-03-22  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
850
851         [Qt] Enable FAST_MOBILE_SCROLLING when scrolling is delegated.
852         https://bugs.webkit.org/show_bug.cgi?id=81889
853
854         Reviewed by Kenneth Rohde Christiansen.
855
856         On the Qt platform only enable the fast mobile scroll feature when scrolling is delegated.
857
858         * rendering/RenderObject.cpp:
859         (WebCore::RenderObject::styleWillChange):
860
861 2012-03-22  Pavel Feldman  <pfeldman@chromium.org>
862
863         Web Inspector: dispatch styleSheetChanged event synchronously.
864         https://bugs.webkit.org/show_bug.cgi?id=81892
865
866         Reviewed by Vsevolod Vlasov.
867
868         Today, backend generates stylesheet change event synchronously from within set* command.
869         But CSSStyleModel defers its dispatching until the stylesheet content is available. This
870         prevents us from ignoring update events from within commands that initiated those updates.
871
872         This change makes stylesheet change event dispatch synchronously and delegates stylesheet
873         content fetching to the event client.
874
875         * inspector/front-end/CSSStyleModel.js:
876         (WebInspector.CSSStyleModel.prototype._fireStyleSheetChanged):
877         (WebInspector.CSSStyleDeclaration.prototype.insertPropertyAt):
878         (WebInspector.CSSStyleModelResourceBinding.prototype.setContent):
879         (WebInspector.CSSStyleModelResourceBinding.prototype._innerSetContent.callbackWrapper):
880         (WebInspector.CSSStyleModelResourceBinding.prototype._innerSetContent):
881         (WebInspector.CSSStyleModelResourceBinding.prototype._styleSheetChanged.callback):
882         (WebInspector.CSSStyleModelResourceBinding.prototype._styleSheetChanged):
883         (WebInspector.CSSStyleModelResourceBinding.prototype._innerStyleSheetChanged):
884
885 2012-03-21  Ian Vollick  <vollick@chromium.org>
886
887         [chromium] timing functions are getting incorrectly applied for accelerated css transitions
888         https://bugs.webkit.org/show_bug.cgi?id=81692
889
890         Reviewed by Adrienne Walker.
891
892         Tested in CCLayerTreeHostTestAddAnimationWithTimingFunction
893
894         * platform/graphics/chromium/cc/CCLayerAnimationController.cpp:
895
896 2012-03-22  Pavel Feldman  <pfeldman@chromium.org>
897
898         Web Inspector: allow on-hover popover while in edit mode.
899         https://bugs.webkit.org/show_bug.cgi?id=81898
900
901         Reviewed by Vsevolod Vlasov.
902
903         This change allows popover while in-edit mode, hides it upon Esc. It also introduces anchorOverride
904         concept in ObjectPopoverHelper that allows dynamically switching the anchor (say if we want to highlight anchor itself).
905
906         * inspector/front-end/DetailedHeapshotView.js:
907         * inspector/front-end/ElementsPanel.js:
908         * inspector/front-end/JavaScriptSourceFrame.js:
909         (WebInspector.JavaScriptSourceFrame.prototype._resolveObjectForPopover.showObjectPopover):
910         (WebInspector.JavaScriptSourceFrame.prototype._resolveObjectForPopover):
911         (WebInspector.JavaScriptSourceFrame.prototype._onKeyDown):
912         * inspector/front-end/NetworkPanel.js:
913         * inspector/front-end/ObjectPopoverHelper.js:
914         (WebInspector.ObjectPopoverHelper.prototype._showObjectPopover.showObjectPopover.):
915         (WebInspector.ObjectPopoverHelper.prototype._showObjectPopover):
916         * inspector/front-end/Popover.js:
917         (WebInspector.PopoverHelper.prototype.isPopoverVisible):
918         * inspector/front-end/TimelinePanel.js:
919
920 2012-03-22  Pavel Feldman  <pfeldman@chromium.org>
921
922         Web Inspector: breakpoints should shift when line break is inserted in the middle of the line.
923         https://bugs.webkit.org/show_bug.cgi?id=81896
924
925         Reviewed by Vsevolod Vlasov.
926
927         There is a bug that collapses selection prior to exiting change mode, we should never
928         collapse edit area prior committing.
929
930         * inspector/front-end/TextEditorModel.js:
931         (WebInspector.TextEditorModel.endsWithBracketRegex.):
932         * inspector/front-end/TextViewer.js:
933         (WebInspector.TextViewer):
934         (WebInspector.TextEditorMainPanel.prototype.highlightLine):
935         (WebInspector.TextEditorMainPanel.prototype.handleUndoRedo.callback):
936         (WebInspector.TextEditorMainPanel.prototype.handleUndoRedo):
937
938 2012-03-22  Zoltan Herczeg  <zherczeg@webkit.org>
939
940         Merge SVGImageBufferTools to SVGRenderingContext
941         https://bugs.webkit.org/show_bug.cgi?id=81890
942
943         Reviewed by Nikolas Zimmermann.
944
945         Copy the code to SVGRenderingContext and delete
946         SVGImageBufferTools[.cpp.h]. Update build systems,
947         no functionality change. This is the first step
948         towards making SVGImageBufferTools stageful.
949
950         Existing tests cover this issue.
951
952         * CMakeLists.txt:
953         * GNUmakefile.list.am:
954         * Target.pri:
955         * WebCore.gypi:
956         * WebCore.xcodeproj/project.pbxproj:
957         * platform/graphics/filters/FETile.cpp:
958         (WebCore::FETile::platformApplySoftware):
959         * rendering/svg/RenderSVGAllInOne.cpp:
960         * rendering/svg/RenderSVGInlineText.cpp:
961         (WebCore::RenderSVGInlineText::computeNewScaledFontForStyle):
962         * rendering/svg/RenderSVGResourceClipper.cpp:
963         (WebCore::RenderSVGResourceClipper::applyClippingToContext):
964         (WebCore::RenderSVGResourceClipper::drawContentIntoMaskImage):
965         * rendering/svg/RenderSVGResourceFilter.cpp:
966         (WebCore::RenderSVGResourceFilter::applyResource):
967         * rendering/svg/RenderSVGResourceGradient.cpp:
968         (WebCore::createMaskAndSwapContextForTextGradient):
969         (WebCore::clipToTextMask):
970         * rendering/svg/RenderSVGResourceMasker.cpp:
971         (WebCore::RenderSVGResourceMasker::applyResource):
972         (WebCore::RenderSVGResourceMasker::drawContentIntoMaskImage):
973         * rendering/svg/RenderSVGResourcePattern.cpp:
974         (WebCore::RenderSVGResourcePattern::applyResource):
975         (WebCore::RenderSVGResourcePattern::createTileImage):
976         * rendering/svg/SVGImageBufferTools.cpp: Removed.
977         * rendering/svg/SVGImageBufferTools.h: Removed.
978         * rendering/svg/SVGInlineTextBox.cpp:
979         * rendering/svg/SVGRenderingContext.cpp:
980         (WebCore::currentContentTransformation):
981         (WebCore):
982         (WebCore::SVGRenderingContext::calculateTransformationToOutermostSVGCoordinateSystem):
983         (WebCore::SVGRenderingContext::createImageBuffer):
984         (WebCore::SVGRenderingContext::createImageBufferForPattern):
985         (WebCore::SVGRenderingContext::renderSubtreeToImageBuffer):
986         (WebCore::SVGRenderingContext::clipToImageBuffer):
987         (WebCore::SVGRenderingContext::clampedAbsoluteTargetRect):
988         (WebCore::SVGRenderingContext::clampedAbsoluteSize):
989         (WebCore::SVGRenderingContext::clear2DRotation):
990         * rendering/svg/SVGRenderingContext.h:
991         (SVGRenderingContext):
992         (WebCore::SVGRenderingContext::calculateImageBufferRect):
993         * svg/graphics/filters/SVGFEImage.cpp:
994         (WebCore::FEImage::platformApplySoftware):
995
996 2012-03-22  Hyowon Kim  <hw1008.kim@samsung.com>
997
998         [EFL] Add PageClientEfl to WebCoreSupport.
999         https://bugs.webkit.org/show_bug.cgi?id=80748
1000
1001         Reviewed by Noam Rosenthal.
1002
1003         * platform/Widget.h: Use PageClientEfl as type for PlatformPageClient.
1004         (WebCore):
1005         * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
1006         (WebCore::GraphicsContext3DPrivate::createSurface): Change the argument type.
1007         * plugins/efl/PluginViewEfl.cpp:
1008         (WebCore::PluginView::platformGetValue): Use PageClientEfl.
1009
1010 2012-03-22  Kaustubh Atrawalkar  <kaustubh@motorola.com>
1011
1012         blur() on shadow host should work when a shadow host contains a focused element in its shadow DOM subtrees
1013         https://bugs.webkit.org/show_bug.cgi?id=81102
1014
1015         Reviewed by Hajime Morita.
1016
1017         This implementation will support blur for a focused element when its shadowHost's blur() is called.
1018         To achieve this Element::blur() function is modified to blur the focused node in it's treeScope.
1019
1020         Test: fast/dom/shadow/shadow-root-blur.html
1021
1022         * dom/Element.cpp:
1023         (WebCore::Element::blur): Modified to blur current treeScope's focused node.
1024         * dom/ShadowRoot.h:
1025         (WebCore::ShadowRoot::activeElement): Rework for code sharing.
1026         * dom/TreeScope.cpp:
1027         (WebCore::TreeScope::focusedNode): Added new function to share code for getting focused node.
1028         * dom/TreeScope.h:
1029         (TreeScope): New function declartion.
1030         * html/HTMLDocument.cpp:
1031         (WebCore::HTMLDocument::activeElement): Rework for code sharing.
1032
1033 2012-03-22  Vsevolod Vlasov  <vsevik@chromium.org>
1034
1035         Web Inspector: RawSourceCode does not need uiSourceCode lists because it never has more than one.
1036         https://bugs.webkit.org/show_bug.cgi?id=81894
1037
1038         RawSourceCode never has more than one uiSourceCode, uiSourceCodeList
1039         are just remains of older implementation. This patch switches RawSourceCode
1040         and SourceMappings from uiSourceCodeList to uiSourceCode.
1041
1042         Reviewed by Pavel Feldman.
1043
1044         * inspector/front-end/RawSourceCode.js:
1045         (WebInspector.RawSourceCode.prototype.uiSourceCode):
1046         (WebInspector.RawSourceCode.prototype._saveSourceMapping):
1047         (WebInspector.RawSourceCode.SourceMapping.prototype.uiLocationToRawLocation):
1048         (WebInspector.RawSourceCode.SourceMapping.prototype.uiSourceCode):
1049         (WebInspector.RawSourceCode.PlainSourceMapping):
1050         (WebInspector.RawSourceCode.PlainSourceMapping.prototype.rawLocationToUILocation):
1051         (WebInspector.RawSourceCode.PlainSourceMapping.prototype.uiLocationToRawLocation):
1052         (WebInspector.RawSourceCode.PlainSourceMapping.prototype.uiSourceCode):
1053         (WebInspector.RawSourceCode.FormattedSourceMapping):
1054         (WebInspector.RawSourceCode.FormattedSourceMapping.prototype.rawLocationToUILocation):
1055         (WebInspector.RawSourceCode.FormattedSourceMapping.prototype.uiLocationToRawLocation):
1056         (WebInspector.RawSourceCode.FormattedSourceMapping.prototype.uiSourceCode):
1057         * inspector/front-end/ResourceScriptMapping.js:
1058         (WebInspector.ResourceScriptMapping.prototype.uiSourceCodeList):
1059         (WebInspector.ResourceScriptMapping.prototype.addScript):
1060         (WebInspector.ResourceScriptMapping.prototype._handleUISourceCodeChanged):
1061         (WebInspector.ResourceScriptMapping.prototype._uiSourceCodeChanged):
1062         (WebInspector.ResourceScriptMapping.prototype.reset):
1063
1064 2012-03-22  Mario Sanchez Prada  <msanchez@igalia.com>
1065
1066         [GTK] Fix the only remaining coding style issue in GTK accessibility code
1067         https://bugs.webkit.org/show_bug.cgi?id=81885
1068
1069         Reviewed by Xan Lopez.
1070
1071         Add needed extra line and remove an unneeded one.
1072
1073         * accessibility/gtk/AccessibilityObjectAtk.cpp:
1074
1075 2012-03-22  Kent Tamura  <tkent@chromium.org>
1076
1077         Expand RenderTextControlSingleLine::controlClipRect() to contain contentRect().
1078         https://bugs.webkit.org/show_bug.cgi?id=81866
1079
1080         Reviewed by Hajime Morita.
1081
1082         We need to expand the controlClipRect because the existing shadow
1083         tree of a text field can be wrapped by another shadow tree. e.g.
1084
1085         A current situation:
1086
1087         <input>
1088           ┗ ShadowRoot
1089              ┗ container element
1090         ┌────────────┐<input>'s border box
1091         │┌──────────┐│
1092         ││container box       ││
1093         │└──────────┘│
1094         └────────────┘
1095
1096         Wrapped by another ShadowRoot:
1097
1098         <input>
1099           ┗ New ShadowRoot
1100              ┣ <shadow> represents the existing shadow tree
1101              ┃  ┗ container element
1102              ┗ D: an additional decoration element
1103         ┌────────────┐<input>'s border box
1104         │┌───────┬──┐│
1105         ││container box │ D  ││
1106         │└───────┴──┘│
1107         └────────────┘
1108         In this case, if we clip child renderers by container box, D is not
1109         drawn. We should clip by the content box of the <input>.
1110
1111         A search field has an exceptional behavior. It can have the container
1112         box of which height is taller than the content box height. The
1113         controlClipRect should contain both of the container box and the content
1114         box in this case. In other cases, the container box is equivalent to the
1115         content box. So the code always unites them.
1116
1117         No new tests. This won't make any behavior change for now.
1118
1119         * rendering/RenderTextControlSingleLine.cpp:
1120         (WebCore::RenderTextControlSingleLine::controlClipRect):
1121
1122 2012-03-22  Yoshifumi Inoue  <yosin@chromium.org>
1123
1124         [Forms] The option element should not be form associated element.
1125         https://bugs.webkit.org/show_bug.cgi?id=79764
1126
1127         Reviewed by Kent Tamura.
1128
1129         This patch changes base class of HTMLOptionELement to HTMLElement
1130         from HTMLFormControlElement for saving memory space and iteration
1131         time of extra "option" elements in HTMLFormElement::m_formAssociatedElements
1132         and matching the HTML5 specification for ease of maintenance.
1133
1134         This patch changes behavior of handling of CSS pseudo classes "invalid"
1135         and "valid". The "option" elements no longer use these CSS pseudo classes
1136         as HTML5 specification. This bug was filed in https://bugs.webkit.org/show_bug.cgi?id=80088
1137
1138         Changes of TextIterator is lead by usage of isFormControlElement. This
1139         changes will be replaced with more meaningful predicate as part of
1140         https://bugs.webkit.org/show_bug.cgi?id=80381
1141
1142         No new tests but updated select-live-pseudo-selectors.html test.
1143
1144         * css/CSSStyleSelector.cpp:
1145         (WebCore::CSSStyleSelector::canShareStyleWithElement): Added checking of the "option" element and returns false as HTMLFormControlElement.
1146         * css/SelectorChecker.cpp:
1147         (WebCore::SelectorChecker::checkOneSelector): Removed isFormControlElement for PseudoDisabled and PseudoChecked.
1148         * html/HTMLKeygenElement.cpp:
1149         (WebCore::HTMLKeygenElement::HTMLKeygenElement): Removed form parameter of call site of HTMLOptionElement::create.
1150         * html/HTMLOptionElement.cpp:
1151         (WebCore::HTMLOptionElement::HTMLOptionElement): Removed form parameter which no longer needed. Changed base class in initialization list. Added m_disabled initialization.
1152         (WebCore::HTMLOptionElement::create): Removed form parameter which no longer needed.
1153         (WebCore::HTMLOptionElement::attach): Changeid base class.
1154         (WebCore::HTMLOptionElement::detach): Changed base class.
1155         (WebCore::HTMLOptionElement::parseAttribute): Changed base class. Added "disabled" attribute handling.
1156         (WebCore::HTMLOptionElement::childrenChanged): Changed base class.
1157         (WebCore::HTMLOptionElement::insertedIntoTree): Changed base class.
1158         * html/HTMLOptionElement.h:
1159         (HTMLOptionElement): Added new member variable m_disabled which was in HTMLFormControlElement.
1160         (WebCore::HTMLOptionElement::ownElementDisabled): Changed for using m_disabled.
1161         * html/HTMLTagNames.in: Removed constructorNeedsFormElement for the "option" element, which was used for passing form parameter to create function.
1162
1163 2012-03-21  Pavel Podivilov  <podivilov@chromium.org>
1164
1165         Web Inspector: rename ClosureCompilerSourceMapping to SourceMapParser and move it to CompilerScriptMapping.js.
1166         https://bugs.webkit.org/show_bug.cgi?id=81780
1167
1168         Reviewed by Pavel Feldman.
1169
1170         * WebCore.gypi:
1171         * WebCore.vcproj/WebCore.vcproj:
1172         * inspector/compile-front-end.py:
1173         * inspector/front-end/CompilerScriptMapping.js:
1174         (WebInspector.CompilerScriptMapping.prototype.loadSourceMapForScript):
1175         (WebInspector.SourceMapParserPayload):
1176         (WebInspector.SourceMapParser):
1177         (WebInspector.SourceMapParser.prototype.load):
1178         (WebInspector.SourceMapParser.prototype.compiledLocationToSourceLocation):
1179         (WebInspector.SourceMapParser.prototype.sourceLocationToCompiledLocation):
1180         (WebInspector.SourceMapParser.prototype.sources):
1181         (WebInspector.SourceMapParser.prototype.loadSourceCode):
1182         (WebInspector.SourceMapParser.prototype._findMapping):
1183         (WebInspector.SourceMapParser.prototype._parseMappingPayload):
1184         (WebInspector.SourceMapParser.prototype._parseSections):
1185         (WebInspector.SourceMapParser.prototype._parseMap):
1186         (WebInspector.SourceMapParser.prototype._isSeparator):
1187         (WebInspector.SourceMapParser.prototype._decodeVLQ):
1188         (WebInspector.SourceMapParser.prototype._canonicalizeURL):
1189         (WebInspector.SourceMapParser.StringCharIterator):
1190         (WebInspector.SourceMapParser.StringCharIterator.prototype.next):
1191         (WebInspector.SourceMapParser.StringCharIterator.prototype.peek):
1192         (WebInspector.SourceMapParser.StringCharIterator.prototype.hasNext):
1193         * inspector/front-end/CompilerSourceMapping.js: Removed.
1194         * inspector/front-end/WebKit.qrc:
1195         * inspector/front-end/inspector.html:
1196
1197 2012-03-21  Vsevolod Vlasov  <vsevik@chromium.org>
1198
1199         Web Inspector: IndexedDB transaction is not closed when requesting data.
1200         https://bugs.webkit.org/show_bug.cgi?id=81837
1201
1202         Reviewed by Pavel Feldman.
1203
1204         * inspector/InspectorIndexedDBAgent.cpp: Added missing IDBCursorBackendInterface::postSuccessHandlerCallback() call.
1205         (WebCore):
1206
1207 2012-03-21  Yury Semikhatsky  <yurys@chromium.org>
1208
1209         Web Inspector: event listeners section is broken for about:blank page
1210         https://bugs.webkit.org/show_bug.cgi?id=81795
1211
1212         Parse about:blank as a valid URL.
1213
1214         Reviewed by Pavel Feldman.
1215
1216         Test: inspector/elements/event-listeners-about-blank.html
1217
1218         * inspector/front-end/utilities.js:
1219         (String.prototype.asParsedURL):
1220
1221 2012-03-21  Dan Bernstein  <mitz@apple.com>
1222
1223         REGRESSION (r111635): Assertion failure in RenderFlexibleBox::layoutFlexItems() (!lineContexts.size()) in many flexbox tests
1224         https://bugs.webkit.org/show_bug.cgi?id=81870
1225
1226         Reverted r111635, the fix for bug 81843.
1227
1228         * rendering/RenderFlexibleBox.cpp:
1229         (WebCore::RenderFlexibleBox::WrapReverseContext::WrapReverseContext):
1230         (WebCore::RenderFlexibleBox::WrapReverseContext::addCrossAxisOffset):
1231         (RenderFlexibleBox::WrapReverseContext):
1232         (WebCore::RenderFlexibleBox::WrapReverseContext::addNumberOfChildrenOnLine):
1233         (WebCore::RenderFlexibleBox::WrapReverseContext::lineCrossAxisDelta):
1234         (WebCore::RenderFlexibleBox::layoutFlexItems):
1235         (WebCore::RenderFlexibleBox::layoutAndPlaceChildren):
1236         (WebCore::RenderFlexibleBox::alignChildren):
1237         (WebCore::RenderFlexibleBox::flipForWrapReverse):
1238         * rendering/RenderFlexibleBox.h:
1239
1240 2012-03-21  Emil A Eklund  <eae@chromium.org>
1241
1242         Unreviewed change touching CustomFilterProgram.h to try
1243         to force the chromium-win bots to rebuilt it and pick up
1244         on the fact that CSS_SHADERS is not set (since r111610). 
1245
1246         * platform/graphics/filters/CustomFilterProgram.h:
1247
1248 2012-03-21  Vangelis Kokkevis  <vangelis@chromium.org>
1249
1250         [chromium] FPS counter causes garbage to be displayed at top left corner
1251         https://bugs.webkit.org/show_bug.cgi?id=81851
1252
1253         The HUD expects the PlatformCanvas it paints on to be cleared on creation which is
1254         no longer true after http://src.chromium.org/viewvc/chrome?view=rev&revision=127196 .
1255         This patch does an explicit clearRect before the HUD contents are painted.
1256
1257         Reviewed by Adrienne Walker.
1258
1259         TEST=Manually verified that --show-fps-counter and --show-composited-layer-tree work correctly.
1260
1261         * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
1262         (WebCore::CCHeadsUpDisplay::draw):
1263
1264 2012-03-21  Ryosuke Niwa  <rniwa@webkit.org>
1265
1266         Touch a file to make Chromium Windows bots happy.
1267
1268         * css/CSSValueKeywords.in:
1269
1270 2012-03-19  Igor Oliveira  <igor.o@sisa.samsung.com>
1271
1272         Every call to RenderObject::setAnimatableStyle() iterates through all m_compositeAnimations: potentially O(N^2)
1273         https://bugs.webkit.org/show_bug.cgi?id=38025
1274
1275         Implement updateAnimationTimerForRender. This reduces unnecessary animation
1276         steps on the current RenderObject by checking the value of timeToNextService
1277         before starting a new timer.
1278
1279         Reviewed by Dean Jackson.
1280
1281         Test: animations/animation-welcome-safari.html
1282
1283         * page/animation/AnimationController.cpp:
1284         (WebCore::AnimationControllerPrivate::updateAnimationTimerForRenderer):
1285         (WebCore):
1286         (WebCore::AnimationController::updateAnimations):
1287         * page/animation/AnimationControllerPrivate.h:
1288         (AnimationControllerPrivate):
1289
1290 2012-03-21  Sheriff Bot  <webkit.review.bot@gmail.com>
1291
1292         Unreviewed, rolling out r111616.
1293         http://trac.webkit.org/changeset/111616
1294         https://bugs.webkit.org/show_bug.cgi?id=81862
1295
1296         broke chromium mac (Requested by eae on #webkit).
1297
1298         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
1299         (WebCore::CCLayerImpl::appendQuads):
1300         * platform/graphics/chromium/cc/CCLayerImpl.h:
1301         (CCLayerImpl):
1302         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
1303         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
1304         (WebCore::CCLayerTreeHostImpl::drawLayers):
1305         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
1306         (CCLayerTreeHostImpl):
1307         * platform/graphics/chromium/cc/CCQuadCuller.cpp:
1308         (WebCore::CCQuadCuller::append):
1309         * platform/graphics/chromium/cc/CCQuadCuller.h:
1310         (CCQuadCuller):
1311         * platform/graphics/chromium/cc/CCRenderPass.cpp:
1312         (WebCore::CCRenderPass::appendQuadsForLayer):
1313         * platform/graphics/chromium/cc/CCRenderPass.h:
1314         (CCRenderPass):
1315         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.cpp:
1316         (WebCore::CCScrollbarLayerImpl::appendQuads):
1317         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.h:
1318         (CCScrollbarLayerImpl):
1319         * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
1320         (WebCore::CCSingleThreadProxy::doComposite):
1321         * platform/graphics/chromium/cc/CCSolidColorLayerImpl.cpp:
1322         (WebCore::CCSolidColorLayerImpl::appendQuads):
1323         * platform/graphics/chromium/cc/CCSolidColorLayerImpl.h:
1324         (CCSolidColorLayerImpl):
1325         * platform/graphics/chromium/cc/CCTextureLayerImpl.cpp:
1326         (WebCore::CCTextureLayerImpl::appendQuads):
1327         * platform/graphics/chromium/cc/CCTextureLayerImpl.h:
1328         (CCTextureLayerImpl):
1329         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
1330         (WebCore::CCThreadProxy::scheduledActionDrawAndSwap):
1331         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
1332         (WebCore::CCTiledLayerImpl::appendQuads):
1333         * platform/graphics/chromium/cc/CCTiledLayerImpl.h:
1334         (CCTiledLayerImpl):
1335         * platform/graphics/chromium/cc/CCVideoLayerImpl.cpp:
1336         (WebCore::CCVideoLayerImpl::appendQuads):
1337         * platform/graphics/chromium/cc/CCVideoLayerImpl.h:
1338         (CCVideoLayerImpl):
1339
1340 2012-03-21  Beth Dakin  <bdakin@apple.com>
1341
1342         https://bugs.webkit.org/show_bug.cgi?id=80322
1343         Implement image-set
1344
1345         Reviewed by Dean Jackson.
1346
1347         This initial implementation of -webkit-image-set. 
1348         http://lists.w3.org/Archives/Public/www-style/2012Feb/1103.html
1349         The idea behind the feature is to allow authors to provide multiple variants 
1350         of the same image at differing resolutions, and to allow the User Agent to 
1351         choose the resource that is most appropriate at the time. This patch will 
1352         choose the most appropriate image based on device scale factor.
1353
1354         CSSImageSetValue inherits from CSSValueList and behaves a lot like 
1355         CSSImageValue.
1356         * WebCore.xcodeproj/project.pbxproj:
1357         * css/CSSImageSetValue.h: Added.
1358         (WebCore):
1359         (CSSImageSetValue):
1360         (WebCore::CSSImageSetValue::create):
1361         (WebCore::CSSImageSetValue::isPending):
1362         (ImageWithScale):
1363         (WebCore::CSSImageSetValue::compareByScaleFactor):
1364         * css/CSSImageSetValue.cpp: Added.
1365         (WebCore):
1366         (WebCore::CSSImageSetValue::CSSImageSetValue):
1367         (WebCore::CSSImageSetValue::~CSSImageSetValue):
1368         (WebCore::CSSImageSetValue::cachedOrPendingImageSet):
1369         (WebCore::CSSImageSetValue::customCssText):
1370
1371         fillImageSet() iterates through the value list and turns the information into 
1372         a sorted Vector of ImageWithScales (which is a struct containing image URLs 
1373         and scale factors).
1374         (WebCore::CSSImageSetValue::fillImageSet):
1375
1376         cachedImageSet() finds which image is most appropriate based on the device 
1377         scale factor, and it loads only that image. In the future, additional scale 
1378         factors will be taken into account.
1379         (WebCore::CSSImageSetValue::bestImageForScaleFactor):
1380         (WebCore::CSSImageSetValue::cachedImageSet):
1381
1382         parseImageSet() is called everywhere in the CSSParser that a regular image or 
1383         generated image can be found.
1384         * css/CSSParser.cpp:
1385         (WebCore::CSSParser::parseValue):
1386         (WebCore::CSSParser::parseContent):
1387         (WebCore::CSSParser::parseFillImage):
1388         (WebCore::CSSParser::parseBorderImage):
1389         (WebCore):
1390         (WebCore::CSSParser::parseImageSet):
1391         * css/CSSParser.h:
1392
1393         Since CSSImageSetValue is implemented as a value list, 
1394         ApplyPropertyFillLayer::applyValue() needs to be more specific when it's 
1395         looking for a list of multiple URLs.
1396         * css/CSSStyleApplyProperty.cpp:
1397         (WebCore::ApplyPropertyFillLayer::applyValue):
1398
1399         Handle image-set as a valid image value.
1400         * css/CSSStyleSelector.cpp:
1401         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
1402         * css/CSSStyleSelector.h:
1403         (CSSStyleSelector):
1404         * css/CSSValue.cpp:
1405         (WebCore::CSSValue::cssText):
1406         (WebCore::CSSValue::destroy):
1407         * css/CSSValue.h:
1408         (CSSValue):
1409         (WebCore::CSSValue::isImageSetValue):
1410
1411         computeIntrinsicDimensions() now takes an optional scaleFactor parameter that represents the author-enforced "intrinsic" scale factor of the image.
1412         * loader/cache/CachedImage.cpp:
1413         (WebCore::CachedImage::computeIntrinsicDimensions):
1414         * loader/cache/CachedImage.h:
1415         (CachedImage):
1416         * platform/graphics/GeneratedImage.h:
1417         (GeneratedImage):
1418         * platform/graphics/GeneratorGeneratedImage.cpp:
1419         (WebCore::GeneratedImage::computeIntrinsicDimensions):
1420         * platform/graphics/Image.cpp:
1421         (WebCore::Image::computeIntrinsicDimensions):
1422         * platform/graphics/Image.h:
1423         (Image):
1424         * platform/graphics/cg/PDFDocumentImage.cpp:
1425         (WebCore::PDFDocumentImage::computeIntrinsicDimensions):
1426         * platform/graphics/cg/PDFDocumentImage.h:
1427         (PDFDocumentImage):
1428         * svg/graphics/SVGImage.cpp:
1429         (WebCore::SVGImage::computeIntrinsicDimensions):
1430         * svg/graphics/SVGImage.h:
1431         (SVGImage):
1432
1433         Inherits from StyleImage and returns a scaled size for imageSize() and 
1434         computeIntrinsicDimensions().
1435         * rendering/style/StyleCachedImageSet.cpp: Added.
1436         (WebCore):
1437         (WebCore::StyleCachedImageSet::StyleCachedImageSet):
1438         (WebCore::StyleCachedImageSet::cssValue):
1439         (WebCore::StyleCachedImageSet::canRender):
1440         (WebCore::StyleCachedImageSet::isLoaded):
1441         (WebCore::StyleCachedImageSet::errorOccurred):
1442         (WebCore::StyleCachedImageSet::imageSize):
1443         (WebCore::StyleCachedImageSet::imageHasRelativeWidth):
1444         (WebCore::StyleCachedImageSet::imageHasRelativeHeight):
1445         (WebCore::StyleCachedImageSet::computeIntrinsicDimensions):
1446         (WebCore::StyleCachedImageSet::usesImageContainerSize):
1447         (WebCore::StyleCachedImageSet::setContainerSizeForRenderer):
1448         (WebCore::StyleCachedImageSet::addClient):
1449         (WebCore::StyleCachedImageSet::removeClient):
1450         (WebCore::StyleCachedImageSet::image):
1451         * rendering/style/StyleCachedImageSet.h: Added.
1452         (WebCore):
1453         (StyleCachedImageSet):
1454         (WebCore::StyleCachedImageSet::create):
1455         (WebCore::StyleCachedImageSet::data):
1456         (WebCore::StyleCachedImageSet::cachedImage):
1457
1458         Handle image-set.
1459         * rendering/style/StyleImage.h:
1460         (WebCore::StyleImage::isCachedImageSet):
1461         (WebCore::StyleImage::StyleImage):
1462         (StyleImage):
1463         * rendering/style/StylePendingImage.h:
1464         (StylePendingImage):
1465         (WebCore::StylePendingImage::cssImageSetValue):
1466
1467 2012-03-21  David Barton  <dbarton@mathscribe.com>
1468
1469         MathML internals - improve naming in RenderMathMLSquareRoot.cpp and RenderMathMLRoot.cpp
1470         https://bugs.webkit.org/show_bug.cgi?id=81850
1471
1472         Reviewed by Eric Seidel.
1473
1474         This prepares these files for bug fixes, and eventually combining their common code. To
1475         understand this patch, I suggest you start with RenderMathMLSquareRoot.cpp, as it's
1476         simpler than RenderMathMLRoot.cpp.
1477
1478         No new tests. LayoutTests/mathml/presentation/roots.xhtml is thorough enough for this.
1479
1480         * rendering/mathml/RenderMathMLRoot.cpp:
1481         (WebCore):
1482         (WebCore::RenderMathMLRoot::addChild):
1483         (WebCore::RenderMathMLRoot::paint):
1484         (WebCore::RenderMathMLRoot::layout):
1485         * rendering/mathml/RenderMathMLRoot.h:
1486         (WebCore):
1487         (RenderMathMLRoot):
1488         * rendering/mathml/RenderMathMLSquareRoot.cpp:
1489         (WebCore):
1490         (WebCore::RenderMathMLSquareRoot::paint):
1491         (WebCore::RenderMathMLSquareRoot::layout):
1492         * rendering/mathml/RenderMathMLSquareRoot.h:
1493         (WebCore):
1494         (RenderMathMLSquareRoot):
1495         * rendering/mathml/RenderMathMLSubSup.h:
1496         (WebCore):
1497
1498 2012-03-21  Tony Chang  <tony@chromium.org>
1499
1500         refactor flexbox in preparation for flex-line-pack
1501         https://bugs.webkit.org/show_bug.cgi?id=81843
1502
1503         Reviewed by Ojan Vafai.
1504
1505         Replace WrapReverseContext with a vector of LineContexts that contain
1506         the same information, plus values needed for flex-align.
1507
1508         alignChildren has been moved to after all the lines have been
1509         positioned. We want to align children after flex-line-pack has changed
1510         the size of each line to avoid unnecessary layouts.
1511
1512         No new tests, just refactoring.
1513
1514         * rendering/RenderFlexibleBox.cpp:
1515         (WebCore::RenderFlexibleBox::LineContext::LineContext): New struct,
1516         holds information needed for wrap-reverse and aligning children.
1517         (RenderFlexibleBox::LineContext):
1518         (WebCore::RenderFlexibleBox::layoutFlexItems): alignChildren after layout out all the lines rather than after each line.
1519         (WebCore::RenderFlexibleBox::layoutAndPlaceChildren): don't alignChildren
1520         (WebCore::RenderFlexibleBox::alignChildren): align all flex items, not just a line at a time.
1521         (WebCore::RenderFlexibleBox::flipForWrapReverse): Update to use LineContext
1522         * rendering/RenderFlexibleBox.h:
1523
1524 2012-03-21  Ryosuke Niwa  <rniwa@webkit.org>
1525
1526         BDI element should have dir=auto by default
1527         https://bugs.webkit.org/show_bug.cgi?id=68773
1528
1529         Reviewed by Daniel Bates.
1530
1531         Treat bdi elements without dir content attribute as if they have dir=auto per spec:
1532         http://www.whatwg.org/specs/web-apps/current-work/multipage/text-level-semantics.html#the-bdi-element
1533
1534         The patch tries to encapsulate the logic to look for dir content attribute and dir=auto.
1535
1536         It also adds HTMLBDIElement interface (binding remains to use HTMLElement) to set
1537         selfOrAncestorHasDirAutoAttribute flag true by default, which is used by functions like
1538         directionalityIfhasDirAutoAttribute to look for elements with dir=auto. Since dir=auto-ness of bdi
1539         elements can be overridden by dir content attribute, we must change and only change the default value.
1540
1541         Tests: fast/text/international/bdi-dir-default-to-auto-expected.html
1542                fast/text/international/bdi-dir-default-to-auto.html
1543
1544         * GNUmakefile.list.am:
1545         * Target.pri:
1546         * WebCore.gypi:
1547         * WebCore.vcproj/WebCore.vcproj:
1548         * WebCore.xcodeproj/project.pbxproj:
1549         * css/CSSStyleSelector.cpp:
1550         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
1551         * html/HTMLBDIElement.h: Added.
1552         (WebCore):
1553         (HTMLBDIElement):
1554         (WebCore::HTMLBDIElement::create):
1555         (WebCore::HTMLBDIElement::HTMLBDIElement): Sets selfOrAncestorHasDirAutoAttribute to true because
1556         bdi elements are treated as if it has dir=auto by default.
1557         * html/HTMLElement.cpp:
1558         (WebCore::elementAffectsDirectionality): Added. Checks if the specified element is bdi or
1559         has dir content attribute.
1560         (WebCore):
1561         (WebCore::setHasDirAutoFlagRecursively):
1562         (WebCore::HTMLElement::hasDirectionAuto): Added. Checks if the specified element should be treated
1563         as if it has dir=auto (bdi or element with dir=auto).
1564         (WebCore::HTMLElement::directionalityIfhasDirAutoAttribute):
1565         (WebCore::HTMLElement::adjustDirectionalityIfNeededAfterChildAttributeChanged):
1566         (WebCore::HTMLElement::adjustDirectionalityIfNeededAfterChildrenChanged):
1567         * html/HTMLElement.h:
1568         (HTMLElement):
1569         * html/HTMLTagNames.in: Use HTMLBDIElement instead of HTMLElement for constructing bdi element
1570         to set selfOrAncestorHasDirAutoAttribute true but still use HTMLElement for binding.
1571
1572 2012-03-21  Luke Macpherson  <macpherson@chromium.org>
1573
1574         Use CSSPrimitiveValue::convertToLength() in a few places.
1575         https://bugs.webkit.org/show_bug.cgi?id=81492
1576
1577         Reviewed by Eric Seidel.
1578
1579         No new tests - refactoring only.
1580
1581         CSSPrimitiveValue::convertToLength() provides the same functionality that is duplicated
1582         in many places in CSSStyleSelector. This patch removes some of that code duplication.
1583
1584         * css/CSSStyleApplyProperty.cpp:
1585         (WebCore::ApplyPropertyVerticalAlign::applyValue):
1586         * css/CSSStyleSelector.cpp:
1587         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
1588
1589 2012-03-21  Patrick Gansterer  <paroga@webkit.org>
1590
1591         Build fix for ENABLE(SVG) && !ENABLE(FILTERS) after r111601.
1592
1593         * rendering/svg/RenderSVGRoot.cpp:
1594
1595 2012-03-21  Patrick Gansterer  <paroga@webkit.org>
1596
1597         Build fix for !ENABLE(INSPECTOR) after r104831.
1598
1599         * bindings/js/ScriptDebugServer.cpp:
1600         (WebCore::ScriptDebugServer::dispatchDidParseSource):
1601
1602 2012-03-21  Xiaomei Ji  <xji@chromium.org>
1603
1604         visual word movement: using cache to decrease the number of collectLeafBoxesInLogicalOrder on RootInlineBox
1605         https://bugs.webkit.org/show_bug.cgi?id=81408
1606
1607         Reviewed by Ryosuke Niwa.
1608
1609         Cache logically ordered leaf boxes under a particular root box.
1610         Also, move 'Vector<UChar, 1024> string' declared in visualWordPosition() to outside of loop (it is always
1611         clear-ed before use).
1612
1613         * editing/visible_units.cpp:
1614         (CachedLogicallyOrderedLeafBoxes): Add class to cache logically ordered leaf boxes under a particular root box.
1615         (WebCore::CachedLogicallyOrderedLeafBoxes::size):
1616         (WebCore::CachedLogicallyOrderedLeafBoxes::firstBox):
1617         (WebCore):
1618         (WebCore::CachedLogicallyOrderedLeafBoxes::CachedLogicallyOrderedLeafBoxes):
1619         (WebCore::CachedLogicallyOrderedLeafBoxes::previousTextBox):
1620         (WebCore::CachedLogicallyOrderedLeafBoxes::nextTextBox):
1621         (WebCore::CachedLogicallyOrderedLeafBoxes::collectBoxes):
1622         (WebCore::CachedLogicallyOrderedLeafBoxes::boxIndexInLeaves):
1623         (WebCore::logicallyPreviousBox): Pass CachedLogicallyOrderedLeafBoxes object around.
1624         (WebCore::logicallyNextBox):
1625         (WebCore::wordBreakIteratorForMinOffsetBoundary):
1626         (WebCore::wordBreakIteratorForMaxOffsetBoundary):
1627         (WebCore::visualWordPosition):
1628
1629 2012-03-21  Dana Jansens  <danakj@chromium.org>
1630
1631         [chromium] Early out in a new prepareToDraw() step if checkerboarding an accelerated animation in order to skip the frame
1632         https://bugs.webkit.org/show_bug.cgi?id=81437
1633
1634         Reviewed by Adrienne Walker.
1635
1636         Split CCLayerTreeHostImpl::drawLayers() into two phases:
1637         prepareToDraw() and drawLayers().
1638
1639         When calculating a RenderPass, and we checkerboard a quad on a
1640         layer, bubble this info back up to CCLayerTreeHostImpl. If the
1641         layer is transforming in an animation, then abort the prepareToDraw()
1642         phase and cause it to return false back to the thread proxy.
1643
1644         Unit test: CCLayerTreeHostImplTest.prepareToDrawFailsWhenAnimationUsesCheckerboard
1645
1646         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
1647         (WebCore::CCLayerImpl::appendQuads):
1648         * platform/graphics/chromium/cc/CCLayerImpl.h:
1649         (CCLayerImpl):
1650         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
1651         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
1652         (WebCore::CCLayerTreeHostImpl::prepareToDraw):
1653         (WebCore):
1654         (WebCore::CCLayerTreeHostImpl::drawLayers):
1655         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
1656         (CCLayerTreeHostImpl):
1657         (FrameData):
1658         * platform/graphics/chromium/cc/CCQuadCuller.cpp:
1659         (WebCore::CCQuadCuller::append):
1660         * platform/graphics/chromium/cc/CCQuadCuller.h:
1661         (CCQuadCuller):
1662         * platform/graphics/chromium/cc/CCRenderPass.cpp:
1663         (WebCore::CCRenderPass::appendQuadsForLayer):
1664         * platform/graphics/chromium/cc/CCRenderPass.h:
1665         (CCRenderPass):
1666         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.cpp:
1667         (WebCore::CCScrollbarLayerImpl::appendQuads):
1668         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.h:
1669         (CCScrollbarLayerImpl):
1670         * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
1671         (WebCore::CCSingleThreadProxy::doComposite):
1672         * platform/graphics/chromium/cc/CCSolidColorLayerImpl.cpp:
1673         (WebCore::CCSolidColorLayerImpl::appendQuads):
1674         * platform/graphics/chromium/cc/CCSolidColorLayerImpl.h:
1675         (CCSolidColorLayerImpl):
1676         * platform/graphics/chromium/cc/CCTextureLayerImpl.cpp:
1677         (WebCore::CCTextureLayerImpl::appendQuads):
1678         * platform/graphics/chromium/cc/CCTextureLayerImpl.h:
1679         (CCTextureLayerImpl):
1680         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
1681         (WebCore::CCThreadProxy::scheduledActionDrawAndSwap):
1682         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
1683         (WebCore::CCTiledLayerImpl::appendQuads):
1684         * platform/graphics/chromium/cc/CCTiledLayerImpl.h:
1685         (CCTiledLayerImpl):
1686         * platform/graphics/chromium/cc/CCVideoLayerImpl.cpp:
1687         (WebCore::CCVideoLayerImpl::appendQuads):
1688         * platform/graphics/chromium/cc/CCVideoLayerImpl.h:
1689         (CCVideoLayerImpl):
1690
1691 2012-03-21  Enrica Casucci  <enrica@apple.com>
1692
1693         WebKitURLWithTitles pasteboard format should support URLs containing Emoji characters.
1694         https://bugs.webkit.org/show_bug.cgi?id=81835
1695         <rdar://problem/11082749>
1696
1697         Reviewed by Brady Eidson.
1698
1699         When writing the URL in the pasteboard for the WebURLWithTitles format,
1700         we use the user visible string instead of the original URL.
1701         In case of URL with Unicode characters, we lose the encoding.
1702         
1703         Added TestWebKitAPI test.
1704
1705         * platform/mac/PasteboardMac.mm:
1706         (WebCore::writeURLForTypes): Writes to the pasteboard the original URL.
1707
1708 2012-03-21  Levi Weintraub  <leviw@chromium.org>
1709
1710         Correct LayoutUnit usage in VisiblePosition.cpp
1711         https://bugs.webkit.org/show_bug.cgi?id=81775
1712
1713         Reviewed by Eric Seidel.
1714
1715         Correcting a mismatch between the .h and .cpp for the definition of localCaretRect,
1716         and properly using LayoutUnits for local coordinates.
1717
1718         No new tests. No change in behavior.
1719
1720         * editing/VisiblePosition.cpp:
1721         (WebCore::VisiblePosition::localCaretRect): Switching to return a LayoutRect, as in the
1722         header. Local coordinates are in LayoutUnits.
1723         (WebCore::VisiblePosition::absoluteCaretBounds): Using LayoutRect for the localCaretRect.
1724         (WebCore::VisiblePosition::lineDirectionPointForBlockDirectionNavigation): Ditto.
1725
1726 2012-03-21  Adam Klein  <adamk@chromium.org>
1727
1728         "this" argument for MutationCallbacks should be the MutationObserver
1729         https://bugs.webkit.org/show_bug.cgi?id=81712
1730
1731         Reviewed by Adam Barth.
1732
1733         Test: fast/mutation/callback-arguments.html
1734
1735         * bindings/js/JSCallbackData.cpp:
1736         (WebCore::JSCallbackData::invokeCallback): Add an overload that takes
1737         an explicit this argument and have the old method call the new one.
1738         * bindings/js/JSCallbackData.h:
1739         (JSCallbackData):
1740         * bindings/js/JSMutationCallbackCustom.cpp:
1741         (WebCore::JSMutationCallback::handleEvent): Call the new overload.
1742         * bindings/v8/custom/V8CustomVoidCallback.cpp:
1743         (WebCore::invokeCallback): Add an overload that takes an explicit this
1744         argument and have the old method call the new one.
1745         * bindings/v8/custom/V8CustomVoidCallback.h:
1746         (WebCore):
1747         * bindings/v8/custom/V8MutationCallbackCustom.cpp:
1748         (WebCore::V8MutationCallback::handleEvent): Call the new overload.
1749
1750 2012-03-21  Alexandru Chiculita  <achicu@adobe.com>
1751
1752         [CSS Shaders] Make CSS Shaders compile on Chromium
1753         https://bugs.webkit.org/show_bug.cgi?id=81435
1754
1755         Reviewed by Stephen White.
1756
1757         This patch enables the CSS Shaders compile time flag, but keeps the runtime flag disabled.
1758         The only way to test the functionality now is to use the overridePreference from dump render tree.
1759
1760         Also part of this patch I fix a layering violation: I removed the "Document" reference from the FECustomFilter.cpp and passed the
1761         HostWindow directly. There should be no problem when the HostWindow changes, because the RenderLayer and the FECustomFilter
1762         get recreated anyway.
1763
1764         No new tests. I've updated the existing custom filter tests to run under Chromium and added the expected results.
1765         I've just added window.layoutTestController.overridePreference("WebKitCSSCustomFilterEnabled", "1") to force 
1766         enable the feature at runtime. 
1767
1768         * loader/cache/CachedResource.cpp: Made CachedResource::ShaderResource report as ResourceRequest::TargetIsSubresource for Chromium.
1769         (WebCore::cachedResourceTypeToTargetType):
1770
1771         * platform/graphics/filters/FECustomFilter.cpp:
1772         (WebCore::FECustomFilter::FECustomFilter): Removed Document and just used the HostWindow directly.
1773         (WebCore::FECustomFilter::create):
1774         (WebCore::FECustomFilter::initializeContext):
1775         (WebCore::FECustomFilter::bindVertexAttribute): There was a typo and instead of using the "size" parameter it always used 4 component attribute.
1776         Other drivers didn't complain about it, but it was clearly a bug.
1777         (WebCore::FECustomFilter::bindProgramAndBuffers): Reading the image back from GPU will flip vertically the framebuffer in Chromium. I've flipped the
1778         projection matrix only on Chromium, so that we get the correct result.
1779
1780         * rendering/FilterEffectRenderer.cpp:
1781         (WebCore::FilterEffectRenderer::build): Passing the HostWindow instead of the Document.
1782
1783 2012-03-21  Mark Pilgrim  <pilgrim@chromium.org>
1784
1785         Realphabetize about webaudio move
1786         https://bugs.webkit.org/show_bug.cgi?id=81825
1787
1788         Reviewed by Adam Barth.
1789
1790         No new tests, all existing tests pass.
1791
1792         * CMakeLists.txt:
1793
1794 2012-03-21  Anders Carlsson  <andersca@apple.com>
1795
1796         Evict tiles from pages in background tabs
1797         https://bugs.webkit.org/show_bug.cgi?id=81829
1798         <rdar://problem/10866152>
1799
1800         Reviewed by Andreas Kling.
1801
1802         When the tile cache for a page is no longer in a window (which happens when it's moved to 
1803         a background tab), schedule a tile revalidation after 4 seconds. This tile revalidation 
1804         will ensure that tiles outside of the visible rect will be dropped.
1805
1806         * platform/graphics/ca/mac/TileCache.h:
1807         (TileCache):
1808         * platform/graphics/ca/mac/TileCache.mm:
1809         (WebCore::TileCache::tileCacheLayerBoundsChanged):
1810         (WebCore::TileCache::setIsInWindow):
1811         (WebCore::TileCache::tileCoverageRect):
1812         (WebCore):
1813         (WebCore::TileCache::scheduleTileRevalidation):
1814         (WebCore::TileCache::revalidateTiles):
1815
1816 2012-03-21  Stephen Chenney  <schenney@chromium.org>
1817
1818         SVG layout leaves objects still needing layout
1819         https://bugs.webkit.org/show_bug.cgi?id=81006
1820
1821         Reviewed by Nikolas Zimmermann.
1822
1823         Change the layout of SVG objects such that resources that trigger
1824         layout of other objects are handled in a distinct pass, and then
1825         objects still requiring layout are laid out again.
1826
1827         Test: svg/custom/delete-text-innerText-crash.html
1828
1829         * rendering/svg/RenderSVGResourceContainer.cpp:
1830         (WebCore::RenderSVGResourceContainer::layout):
1831         * rendering/svg/RenderSVGResourceMarker.cpp:
1832         (WebCore::RenderSVGResourceMarker::layout):
1833         * rendering/svg/RenderSVGRoot.cpp:
1834         (WebCore::RenderSVGRoot::layout):
1835         (WebCore::RenderSVGRoot::addResourceForClientInvalidation):
1836         (WebCore):
1837         * rendering/svg/RenderSVGRoot.h:
1838         (RenderSVGRoot):
1839
1840 2012-03-21  Tim Horton  <timothy_horton@apple.com>
1841
1842         Make use of CG rounded-rect primitives
1843         https://bugs.webkit.org/show_bug.cgi?id=79932
1844         <rdar://problem/9274953>
1845
1846         Reviewed by Simon Fraser.
1847
1848         Portions of patch by Nikolas Zimmermann and Mustafizur Rahaman.
1849
1850         Dispatch to potentially platform-specific rounded rectangle path
1851         construction from addPathForRoundedRect. Make use of this to call
1852         wkCGPathAddRoundedRect on Lion and above, as long as the rounded
1853         corners are all equivalent.
1854
1855         The origin of the stroke dash differs between the bezier approach
1856         and the path added by wkCGPathAddRoundedRect, so Path::addRoundedRect()
1857         takes a new parameter allowing code which is sensitive to stroke dash
1858         origin (i.e. SVG) to fall back to the old behavior if need be.
1859
1860         Make use of the new Path::addRoundedRect() parameter to fall back to
1861         the old (bezier) rounded-rect behavior when constructing a dashed SVG path,
1862         in order to continue complying with the spec.
1863
1864         No new tests, as this is covered by many that use rounded corners,
1865         and is only a performance improvement.
1866
1867         * WebCore.exp.in:
1868         * platform/graphics/Path.cpp:
1869         (WebCore::Path::addRoundedRect):
1870         (WebCore):
1871         (WebCore::Path::addPathForRoundedRect):
1872         * platform/graphics/Path.h:
1873         (Path):
1874         * platform/graphics/cg/PathCG.cpp:
1875         (WebCore::Path::platformAddPathForRoundedRect):
1876         (WebCore):
1877         * platform/mac/WebCoreSystemInterface.h:
1878         * platform/mac/WebCoreSystemInterface.mm:
1879         * rendering/svg/SVGPathData.cpp:
1880         (WebCore::updatePathFromRectElement):
1881
1882 2012-03-21  David Reveman  <reveman@chromium.org>
1883
1884         [Chromium] GL_EXT_occlusion_query_boolean and GL_CHROMIUM_command_buffer_query support.
1885         https://bugs.webkit.org/show_bug.cgi?id=80988
1886
1887         Reviewed by Adrienne Walker.
1888
1889         Expose EXT_occlusion_query API to WebKit compositor. Add
1890         GL_EXT_occlusion_query_boolean and GL_CHROMIUM_command_buffer_query
1891         enums.
1892
1893         * platform/graphics/chromium/Extensions3DChromium.h:
1894         (Extensions3DChromium):
1895
1896 2012-03-21  Tony Chang  <tony@chromium.org>
1897
1898         compute the sign of flexibility for new flexbox
1899         https://bugs.webkit.org/show_bug.cgi?id=81722
1900
1901         Reviewed by Ojan Vafai.
1902
1903         This implements the computation of the sign of flexibility used by the
1904         new flexing algorithm.
1905         http://dev.w3.org/csswg/css3-flexbox/#resolve-the-flexible-lengths
1906
1907         No new tests, we don't use the sign of flexibility yet.
1908
1909         * rendering/RenderFlexibleBox.cpp:
1910         (WebCore::RenderFlexibleBox::layoutFlexItems):
1911         (WebCore::RenderFlexibleBox::computeNextFlexLine): Compute the size
1912         adjusted for min/max as well as not adjusted.
1913         (WebCore::RenderFlexibleBox::resolveFlexibleLengths): Renamed to match
1914         spec text better.
1915         * rendering/RenderFlexibleBox.h: Added enum for flex sign.
1916
1917 2012-03-21  Vsevolod Vlasov  <vsevik@chromium.org>
1918
1919         Web Inspector: Extract WebInspector.UIBreakpoint from WebInspector.Breakpoint.
1920         https://bugs.webkit.org/show_bug.cgi?id=81669
1921
1922         Reviewed by Pavel Feldman.
1923
1924         * inspector/front-end/BreakpointManager.js:
1925         (WebInspector.BreakpointManager.get for):
1926         (WebInspector.BreakpointManager):
1927         (WebInspector.BreakpointManager.prototype.uiSourceCodeAdded):
1928         (WebInspector.BreakpointManager.prototype.uiSourceCodeRemoved):
1929         (WebInspector.BreakpointManager.prototype.breakpointsForUISourceCode):
1930         (WebInspector.BreakpointManager.prototype.setBreakpoint):
1931         (WebInspector.BreakpointManager.prototype.removeBreakpoint):
1932         (WebInspector.BreakpointManager.prototype._innerRemoveBreakpoint):
1933         (WebInspector.BreakpointManager.prototype.removeAllBreakpoints):
1934         (WebInspector.BreakpointManager.prototype._moveBreakpointInUI):
1935         (WebInspector.BreakpointManager.prototype._uiBreakpoints.get this):
1936         (WebInspector.BreakpointManager.prototype._uiBreakpoints):
1937         (WebInspector.BreakpointManager.prototype.get _uiBreakpoint):
1938         (WebInspector.BreakpointManager.prototype._addBreakpointToUI):
1939         (WebInspector.BreakpointManager.prototype._removeBreakpointFromUI):
1940         (WebInspector.BreakpointManager.prototype._breakpoints):
1941         (WebInspector.BreakpointManager.prototype._breakpoint):
1942         (WebInspector.BreakpointManager.prototype._addBreakpointToModel):
1943         (WebInspector.BreakpointManager.prototype._removeBreakpointFromModel):
1944         (WebInspector.BreakpointManager.prototype._forEachBreakpoint):
1945         (WebInspector.BreakpointManager.prototype._setBreakpointInDebugger):
1946         (WebInspector.BreakpointManager.prototype._removeBreakpointFromDebugger):
1947         (WebInspector.BreakpointManager.prototype.debuggerReset):
1948         (WebInspector.Breakpoint.prototype.serialize):
1949         (WebInspector.Breakpoint.prototype.get uiBreakpoint):
1950         (WebInspector.Breakpoint.prototype.createUIBreakpoint):
1951         (WebInspector.Breakpoint.prototype.removeUIBreakpoint):
1952         (WebInspector.UIBreakpoint):
1953         * inspector/front-end/DebuggerPresentationModel.js:
1954         (WebInspector.DebuggerPresentationModel.prototype._handleUISourceCodeListChanged):
1955         (WebInspector.DebuggerPresentationModel.prototype.findBreakpoint):
1956         (WebInspector.DebuggerPresentationModel.prototype._breakpointAdded):
1957         (WebInspector.DebuggerPresentationModel.prototype._breakpointRemoved):
1958         * inspector/front-end/ScriptsPanel.js:
1959
1960 2012-03-21  Anders Carlsson  <andersca@apple.com>
1961
1962         TileCache needs to know if its containing page is in a window
1963         https://bugs.webkit.org/show_bug.cgi?id=81821
1964
1965         Reviewed by Andreas Kling.
1966
1967         This is in preparation for throwing away invisible tiles in background tabs to reduce memory usage.
1968
1969         * page/FrameView.cpp:
1970         (WebCore::FrameView::didMoveOnscreen):
1971         (WebCore::FrameView::willMoveOffscreen):
1972         * page/Page.cpp:
1973         (WebCore::Page::Page):
1974         (WebCore::Page::didMoveOnscreen):
1975         (WebCore::Page::willMoveOffscreen):
1976         * page/Page.h:
1977         (WebCore::Page::isOnscreen):
1978         (Page):
1979         * platform/graphics/TiledBacking.h:
1980         (TiledBacking):
1981         * platform/graphics/ca/mac/TileCache.h:
1982         (TileCache):
1983         * platform/graphics/ca/mac/TileCache.mm:
1984         (WebCore::TileCache::TileCache):
1985         (WebCore::TileCache::setIsInWindow):
1986         (WebCore):
1987         * rendering/RenderLayerBacking.cpp:
1988         (WebCore::RenderLayerBacking::RenderLayerBacking):
1989
1990 2012-03-21  Xingnan Wang  <xingnan.wang@intel.com>
1991
1992         Web audio layout test failed in debug with an ASSERT error in ReverbConvolverStage.cpp
1993         https://bugs.webkit.org/show_bug.cgi?id=81744
1994
1995         Reviewed by Chris Rogers.
1996
1997         * platform/audio/ReverbConvolverStage.cpp:
1998         (WebCore::ReverbConvolverStage::ReverbConvolverStage):
1999
2000 2012-03-21  Xiaomei Ji  <xji@chromium.org>
2001
2002         [chromium] Font fallback in cr-win is wrong for string contains zero-width-space.
2003         https://bugs.webkit.org/show_bug.cgi?id=79961
2004
2005         Reviewed by Adam Barth.
2006
2007         Treat zero-width-space (\u200B) as true for treatAsZeroWidthSpaceInComplexScipt().
2008
2009         * platform/graphics/Font.h:
2010         (WebCore::Font::treatAsZeroWidthSpaceInComplexScript):
2011         * platform/graphics/mac/ComplexTextController.cpp:
2012         (WebCore::ComplexTextController::adjustGlyphsAndAdvances):
2013         * platform/graphics/win/UniscribeController.cpp:
2014         (WebCore::UniscribeController::shapeAndPlaceItem):
2015
2016 2012-03-21  Patrick Gansterer  <paroga@webkit.org>
2017
2018         Build fix for !ENABLE(INSPECTOR) after r111005.
2019
2020         * inspector/ContentSearchUtils.h:
2021
2022 2012-03-21  Ulan Degenbaev  <ulan@chromium.org>
2023
2024         [V8] V8GCForContextDispose should indicate whether a context is disposed for the main frame or not
2025         https://bugs.webkit.org/show_bug.cgi?id=81200
2026
2027         Reviewed by Adam Barth.
2028
2029         Pass a hint to V8::IdleNotification that requests more aggressive GC
2030         when a main frame context is disposed and requests incremental GC otherwise.
2031
2032         * bindings/v8/V8DOMWindowShell.cpp:
2033         (WebCore::V8DOMWindowShell::disposeContextHandles):
2034         * bindings/v8/V8GCForContextDispose.cpp:
2035         (WebCore::V8GCForContextDispose::V8GCForContextDispose):
2036         (WebCore::V8GCForContextDispose::notifyContextDisposed):
2037         (WebCore::V8GCForContextDispose::pseudoIdleTimerFired):
2038         * bindings/v8/V8GCForContextDispose.h:
2039         (V8GCForContextDispose):
2040
2041 2012-03-21  Nat Duca  <nduca@chromium.org>
2042
2043         [chromium] CCThreadProxy must initialize frameBeginTime to monotonicallyIncreasingTime rather than zero
2044         https://bugs.webkit.org/show_bug.cgi?id=81790
2045
2046         Reviewed by James Robinson.
2047
2048         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
2049         (WebCore::CCThreadProxy::scheduledActionBeginFrame):
2050
2051 2012-03-21  Xingnan Wang  <xingnan.wang@intel.com>
2052
2053         Add multichannel support in RealtimeAnalyser
2054         https://bugs.webkit.org/show_bug.cgi?id=81745
2055
2056         Reviewed by Chris Rogers.
2057
2058         * Modules/webaudio/RealtimeAnalyser.cpp:
2059         (WebCore::RealtimeAnalyser::writeInput):
2060         (WebCore):
2061
2062 2012-03-21  Eric Carlson  <eric.carlson@apple.com>
2063
2064         Removing HTMLTrackElement does not delete TextTrack
2065         https://bugs.webkit.org/show_bug.cgi?id=80873
2066
2067         Reviewed by Antti Koivisto.
2068
2069         No new tests, but media/track/track-language-preference.html has been updated
2070         to test this fix.
2071
2072         * html/HTMLMediaElement.cpp:
2073         (WebCore::HTMLMediaElement::didAddTrack): Renamed from trackWasAdded.
2074         (WebCore::HTMLMediaElement::willRemoveTrack): Renamed from trackWasRemoved because it is
2075         called before the track is removed, to allow the TextTrack to be removed.
2076         * html/HTMLMediaElement.h:
2077
2078         * html/HTMLTrackElement.cpp:
2079         (WebCore::HTMLTrackElement::insertedIntoTree): Renamed from insertedIntoDocument
2080         (WebCore::HTMLTrackElement::willRemove): Renamed from removedFromDocument.
2081         * html/HTMLTrackElement.h:
2082
2083         * html/track/LoadableTextTrack.cpp:
2084         (WebCore::LoadableTextTrack::trackElementIndex): Don't include tracks that are not in the
2085         document in the calcualtion.
2086
2087 2012-03-21  Zeno Albisser  <zeno@webkit.org>
2088
2089         [Qt][Mac] ranlib segfaults when creating symbol tables for libWebCore.a.
2090         https://bugs.webkit.org/show_bug.cgi?id=81750
2091
2092         Building WebCore on mac currently creates an archive that is bigger than
2093         4GB. But ranlib fails to create a symbol table for such a big archive,
2094         even on 64bit machines.
2095         Therefore we start using SVGAllInOne.cpp when building debug
2096         on mac. This reduces the size of the archive by about 300MB.
2097
2098         Reviewed by Tor Arne Vestbø.
2099
2100         * Target.pri:
2101
2102 2012-03-21  Tommy Widenflycht  <tommyw@google.com>
2103
2104         [chromium] MediaStream API (JSEP): Introducing WebSessionDescription and WebIceCandidate
2105         https://bugs.webkit.org/show_bug.cgi?id=81339
2106
2107         Reviewed by Adam Barth.
2108
2109         Not possible to test until the entire JSEP feature is commited.
2110
2111         * Modules/mediastream/IceCandidate.cpp:
2112         (WebCore::IceCandidate::toSdp):
2113         * Modules/mediastream/SessionDescription.cpp:
2114         (WebCore::SessionDescription::toSdp):
2115         * platform/mediastream/IceCandidateDescriptor.cpp:
2116         (WebCore::IceCandidateDescriptor::toSDP):
2117         * platform/mediastream/IceCandidateDescriptor.h:
2118         (IceCandidateDescriptor):
2119         * platform/mediastream/MediaStreamCenter.cpp:
2120         (WebCore::MediaStreamCenter::constructSDP):
2121         * platform/mediastream/MediaStreamCenter.h:
2122         (MediaStreamCenter):
2123         * platform/mediastream/SessionDescriptionDescriptor.cpp:
2124         (WebCore::SessionDescriptionDescriptor::SessionDescriptionDescriptor):
2125         (WebCore::SessionDescriptionDescriptor::toSDP):
2126         (WebCore::SessionDescriptionDescriptor::initialSDP):
2127         * platform/mediastream/SessionDescriptionDescriptor.h:
2128         (SessionDescriptionDescriptor):
2129
2130 2012-03-21  Yuta Kitamura  <yutak@chromium.org>
2131
2132         Use RFC version of WebSocket protocol by default
2133         https://bugs.webkit.org/show_bug.cgi?id=81718
2134
2135         Reviewed by Kent Tamura.
2136
2137         Flip the default value of Settings::m_useHixie76WebSocketProtocol so WebKit ports will use
2138         RFC version of WebSocket protocol by default.
2139
2140         All the existing ports already use the RFC protocol as of now, so this change will not make
2141         any impact (hopefully).
2142
2143         No new tests. No change in functionality.
2144
2145         * page/Settings.cpp:
2146         (WebCore::Settings::Settings):
2147
2148 2012-03-21  Andrey Kosyakov  <caseq@chromium.org>
2149
2150         Web Inspector: only show JS event listeners in Event Listeners tab of Elements panel
2151         https://bugs.webkit.org/show_bug.cgi?id=81798
2152
2153         Reviewed by Pavel Feldman.
2154
2155         * bindings/js/JSInjectedScriptHostCustom.cpp:
2156         (WebCore::getJSListenerFunctions):
2157         * bindings/js/ScriptEventListener.cpp:
2158         (WebCore::eventListenerHandlerBody):
2159         (WebCore::eventListenerHandlerLocation):
2160         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
2161         (WebCore::getJSListenerFunctions):
2162         * inspector/InspectorDOMAgent.cpp:
2163         (WebCore::InspectorDOMAgent::getEventListeners):
2164
2165 2012-03-21  Andrey Kosyakov  <caseq@chromium.org>
2166
2167         EventListener::Type enum has unused member InspectorDOMAgentType
2168         https://bugs.webkit.org/show_bug.cgi?id=81794
2169
2170         Reviewed by Pavel Feldman.
2171
2172         * dom/EventListener.h:
2173
2174 2012-03-21  Tom Hudson  <tomhudson@google.com>
2175
2176         Incremental cleanup of BitmapImage: inlined virtual functions
2177         https://bugs.webkit.org/show_bug.cgi?id=81688
2178
2179         Reviewed by James Robinson.
2180
2181         No change in functionality, so no new tests.
2182
2183         Move virtual functions defined in headers into .cpp files.
2184
2185         * WebCore.gypi:
2186         * platform/graphics/BitmapImage.cpp:
2187         (WebCore::BitmapImage::isBitmapImage):
2188         (WebCore):
2189         (WebCore::BitmapImage::hasSingleSecurityOrigin):
2190         (WebCore::BitmapImage::nativeImageForCurrentFrame):
2191         (WebCore::BitmapImage::currentFrameHasAlpha):
2192         (WebCore::BitmapImage::notSolidColor):
2193         (WebCore::BitmapImage::decodedSize):
2194         (WebCore::BitmapImage::mayFillWithSolidColor):
2195         (WebCore::BitmapImage::solidColor):
2196         * platform/graphics/BitmapImage.h:
2197         (BitmapImage):
2198         * platform/graphics/skia/BitmapImageSingleFrameSkia.cpp: Added.
2199         (WebCore):
2200         (WebCore::BitmapImageSingleFrameSkia::isBitmapImage):
2201         (WebCore::BitmapImageSingleFrameSkia::currentFrameHasAlpha):
2202         (WebCore::BitmapImageSingleFrameSkia::size):
2203         (WebCore::BitmapImageSingleFrameSkia::destroyDecodedData):
2204         (WebCore::BitmapImageSingleFrameSkia::decodedSize):
2205         (WebCore::BitmapImageSingleFrameSkia::nativeImageForCurrentFrame):
2206         (WebCore::BitmapImageSingleFrameSkia::notSolidColor):
2207         * platform/graphics/skia/BitmapImageSingleFrameSkia.h:
2208         (BitmapImageSingleFrameSkia):
2209
2210 2012-03-21  Alexey Proskuryakov  <ap@apple.com>
2211
2212         Remove obsolete File attributes
2213         https://bugs.webkit.org/show_bug.cgi?id=79383
2214
2215         Reviewed by Hajime Morita.
2216
2217         * bindings/objc/PublicDOMInterfaces.h:
2218         * fileapi/File.h:
2219         * fileapi/File.idl:
2220         Removed fileName and fileSize, they have different names now.
2221
2222         * html/FileInputType.cpp:
2223         (WebCore::FileInputType::appendFormData):
2224         (WebCore::FileInputType::getTypeSpecificValue):
2225         (WebCore::FileInputType::defaultToolTip):
2226         Updated to use new function names.
2227
2228 2012-03-21  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
2229
2230         TiledBackingStore: Create the first round of tiles synchronously after setting the visible rect.
2231         https://bugs.webkit.org/show_bug.cgi?id=81762
2232
2233         Reviewed by Kenneth Rohde Christiansen.
2234
2235         The first round of tiles should cover completely the visible rect.
2236         Creating the tiles synchronously allows us to get the new tiles immediately
2237         and prevents an extra AC layers sync to be able to remove the old tiles.
2238
2239         At some point it might also make sense to remove the tile creation timer
2240         completely.
2241
2242         * platform/graphics/TiledBackingStore.cpp:
2243         (WebCore::TiledBackingStore::coverWithTilesIfNeeded):
2244
2245 2012-03-19  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
2246
2247         TiledBackingStore: When checking if the visible area is covered, only convert to scaled coordinates once.
2248         https://bugs.webkit.org/show_bug.cgi?id=81519
2249
2250         Reviewed by Kenneth Rohde Christiansen.
2251
2252         Both visibleRect and coverageRatio call mapFromContents on the input rect,
2253         this woulc cause the coverageRatio to never reach 1.0 when the contents is
2254         scaled up.
2255
2256         * platform/graphics/TiledBackingStore.cpp:
2257         (WebCore::TiledBackingStore::visibleAreaIsCovered):
2258
2259 2012-03-21  Mao Yujie  <yujie.mao@intel.com>
2260
2261         MediaStream API: Need to support MediaStream constructor for JSC
2262         https://bugs.webkit.org/show_bug.cgi?id=78781
2263
2264         Reviewed by Adam Barth.
2265
2266         No new tests.
2267
2268         * Modules/mediastream/DOMWindowMediaStream.idl:
2269         * bindings/generic/RuntimeEnabledFeatures.h:
2270         (WebCore::RuntimeEnabledFeatures::webkitMediaStreamEnabled):
2271
2272 2012-03-21  Philip Rogers  <pdr@google.com>
2273
2274         Skip building resources if SVGTRef is not in a document
2275         https://bugs.webkit.org/show_bug.cgi?id=81473
2276
2277         Reviewed by Nikolas Zimmermann.
2278
2279         We can skip the building of pending resources in SVGTRef if we're not
2280         yet in a document. This mirrors the nearly identical logic in
2281         SVGUseElement::buildPendingResource() and
2282         SVGFEImageElement::buildPendingResource().
2283
2284         Test: http/tests/svg/tref-adoptNode-crash.html
2285
2286         * svg/SVGTRefElement.cpp:
2287         (WebCore::SVGTRefElement::buildPendingResource):
2288
2289 2012-03-21  Sami Kyostila  <skyostil@chromium.org>
2290
2291         [chromium] Use floating point scroll deltas for layers
2292         https://bugs.webkit.org/show_bug.cgi?id=81546
2293
2294         Reviewed by James Robinson.
2295
2296         Use floating point scroll deltas for layers instead of integral scroll
2297         deltas. This is because due to page scaling it may be necessary to
2298         scroll layers in sub-CSS-pixel steps to avoid visible jumps. When the
2299         floating point scroll offset is committed to the main thread, it is
2300         truncated to integer, but the fractional part is kept on the CC side to
2301         make sure fractional scroll offsets are accumulated correctly over
2302         multiple commits.
2303
2304         Test: CCLayerTreeHostTestFractionalScroll
2305
2306         * platform/graphics/FloatPoint.h:
2307         (WebCore::toSize):
2308         (WebCore):
2309         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
2310         (WebCore::CCLayerImpl::scrollBy):
2311         (WebCore::CCLayerImpl::setScrollDelta):
2312         * platform/graphics/chromium/cc/CCLayerImpl.h:
2313         (WebCore::CCLayerImpl::scrollDelta):
2314         (CCLayerImpl):
2315         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
2316         (WebCore::CCLayerTreeHostImpl::startPageScaleAnimation):
2317         (WebCore::CCLayerTreeHostImpl::adjustScrollsForPageScaleChange):
2318         (WebCore::CCLayerTreeHostImpl::processScrollDeltas):
2319         (WebCore::CCLayerTreeHostImpl::animatePageScale):
2320
2321 2012-03-21  Li Yin  <li.yin@intel.com>
2322
2323         [WebSocket]The Sec-WebSocket-Accept MUST NOT appear more than once in an HTTP response
2324         https://bugs.webkit.org/show_bug.cgi?id=81655
2325
2326         Reviewed by Adam Barth.
2327
2328         Test: http/tests/websocket/tests/hybi/handshake-fail-by-more-accept-header.html
2329
2330         * Modules/websockets/WebSocketHandshake.cpp:
2331         (WebCore::WebSocketHandshake::readHTTPHeaders):
2332
2333 2012-03-21  Alexei Filippov  <alexeif@chromium.org>
2334
2335         Web Inspector: Speedup heap snapshot loading.
2336         https://bugs.webkit.org/show_bug.cgi?id=81788
2337
2338         Reviewed by Yury Semikhatsky.
2339
2340         * inspector/front-end/HeapSnapshot.js:
2341         (WebInspector.HeapSnapshotLoader.prototype._parseNodes):
2342
2343 2012-03-21  Pavel Feldman  <pfeldman@chromium.org>
2344
2345         Web Inspector: get rid of isInEditMode, use isBeingEdited on particular element.
2346         https://bugs.webkit.org/show_bug.cgi?id=81766
2347
2348         Reviewed by Yury Semikhatsky.
2349
2350         We should check event target and its ancestors for being edited, not use some
2351         global property. This change also introduces Event.prototype.consume so that we
2352         were consistently consuming events.
2353
2354         * inspector/front-end/AdvancedSearchController.js:
2355         (WebInspector.SearchView.prototype._onKeyDown):
2356         * inspector/front-end/BreakpointsSidebarPane.js:
2357         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointCheckboxClicked):
2358         * inspector/front-end/CSSSelectorProfileView.js:
2359         * inspector/front-end/Checkbox.js:
2360         (WebInspector.Checkbox.prototype.addEventListener):
2361         * inspector/front-end/ConsoleView.js:
2362         (WebInspector.ConsoleView.prototype._enterKeyPressed):
2363         (WebInspector.ConsoleGroup.prototype._titleClicked):
2364         * inspector/front-end/ContextMenu.js:
2365         (WebInspector.ContextMenu.prototype.show):
2366         * inspector/front-end/DataGrid.js:
2367         (WebInspector.DataGrid.prototype._keyDown):
2368         * inspector/front-end/DatabaseQueryView.js:
2369         (WebInspector.DatabaseQueryView.prototype._enterKeyPressed):
2370         * inspector/front-end/DetailedHeapshotView.js:
2371         (WebInspector.DetailedHeapshotView.prototype._mouseDownInContentsGrid):
2372         (WebInspector.DetailedHeapshotView.prototype._startRetainersHeaderDragging):
2373         (WebInspector.DetailedHeapshotView.prototype._retainersHeaderDragging):
2374         (WebInspector.DetailedHeapshotView.prototype._endRetainersHeaderDragging):
2375         * inspector/front-end/Dialog.js:
2376         (WebInspector.Dialog.prototype._onKeyDown):
2377         * inspector/front-end/Drawer.js:
2378         (WebInspector.Drawer.prototype._startStatusBarDragging):
2379         (WebInspector.Drawer.prototype._statusBarDragging):
2380         (WebInspector.Drawer.prototype._endStatusBarDragging):
2381         * inspector/front-end/EventListenersSidebarPane.js:
2382         (WebInspector.EventListenersSidebarPane.get if):
2383         * inspector/front-end/HelpScreen.js:
2384         (WebInspector.HelpScreen.prototype._onKeyDown):
2385         * inspector/front-end/InspectorView.js:
2386         (WebInspector.InspectorView.prototype._keyDown):
2387         * inspector/front-end/MetricsSidebarPane.js:
2388         (WebInspector.MetricsSidebarPane.prototype._highlightDOMNode):
2389         * inspector/front-end/NetworkPanel.js:
2390         * inspector/front-end/Object.js:
2391         (WebInspector.Event.prototype.preventDefault):
2392         (WebInspector.Event.prototype.consume):
2393         * inspector/front-end/ObjectPropertiesSection.js:
2394         (WebInspector.ObjectPropertyTreeElement.prototype._promptKeyDown):
2395         * inspector/front-end/ProfileView.js:
2396         * inspector/front-end/SearchController.js:
2397         (WebInspector.SearchController.prototype._onKeyDown):
2398         * inspector/front-end/Section.js:
2399         (WebInspector.Section.prototype.handleClick):
2400         * inspector/front-end/Settings.js:
2401         (WebInspector.ExperimentsSettings):
2402         * inspector/front-end/SoftContextMenu.js:
2403         (.WebInspector.SoftContextMenu.prototype.show):
2404         (.WebInspector.SoftContextMenu.prototype._menuItemMouseDown):
2405         (.WebInspector.SoftContextMenu.prototype._menuKeyDown):
2406         (.WebInspector.SoftContextMenu.prototype._discardMenu):
2407         * inspector/front-end/Spectrum.js:
2408         (WebInspector.Spectrum.draggable.consume):
2409         (WebInspector.Spectrum.draggable.start):
2410         (WebInspector.Spectrum.draggable.stop):
2411         (WebInspector.Spectrum.draggable):
2412         (WebInspector.Spectrum.prototype._onKeyDown):
2413         * inspector/front-end/StylesSidebarPane.js:
2414         (WebInspector.StylesSidebarPane.muteEventListener):
2415         (WebInspector.StylesSidebarPane):
2416         (WebInspector.StylesSidebarPane.prototype.set _createNewRule):
2417         (WebInspector.StylesSidebarPane.prototype._toggleElementStatePane):
2418         (WebInspector.StylePropertiesSection.prototype._handleEmptySpaceClick):
2419         (WebInspector.StylePropertiesSection.prototype._handleSelectorClick):
2420         (WebInspector.StylePropertyTreeElement.prototype.updateTitle.):
2421         (WebInspector.StylePropertyTreeElement.prototype):
2422         * inspector/front-end/TextPrompt.js:
2423         (WebInspector.TextPrompt.prototype.onKeyDown):
2424         (WebInspector.TextPromptWithHistory.prototype.defaultKeyHandler):
2425         (WebInspector.TextPrompt.SuggestBox.prototype._onItemMouseDown):
2426         * inspector/front-end/TextViewer.js:
2427         (WebInspector.TextViewer.prototype._handleKeyDown):
2428         * inspector/front-end/Toolbar.js:
2429         (WebInspector.ToolbarDropdown.prototype._onKeyDown):
2430         * inspector/front-end/UIUtils.js:
2431         (WebInspector.isBeingEdited):
2432         (WebInspector.startEditing):
2433         * inspector/front-end/View.js:
2434         (WebInspector.View.prototype._doLoadCSS):
2435         * inspector/front-end/WatchExpressionsSidebarPane.js:
2436         (WebInspector.WatchExpressionsSidebarPane.prototype._addButtonClicked):
2437         (WebInspector.WatchExpressionsSidebarPane.prototype._refreshButtonClicked):
2438         * inspector/front-end/inspector.js:
2439         (WebInspector.documentClick.followLink):
2440         (WebInspector.documentClick):
2441         (WebInspector.documentKeyDown):
2442         (WebInspector.postDocumentKeyDown):
2443         (WebInspector.addMainEventListeners):
2444         * inspector/front-end/treeoutline.js:
2445         (TreeOutline.prototype._treeKeyPress):
2446         (TreeOutline.prototype._treeKeyDown):
2447         (TreeOutline.prototype._searchInputKeyDown):
2448         (TreeElement.treeElementToggled):
2449         (TreeElement.prototype.selectOnMouseDown):
2450         * inspector/front-end/utilities.js:
2451         (Event.prototype.consume):
2452
2453 2012-03-21  Yury Semikhatsky  <yurys@chromium.org>
2454
2455         Web Inspector: event listener section doesn't show all event listeners of the element ancestors
2456         https://bugs.webkit.org/show_bug.cgi?id=81782
2457
2458         Event listeners section now contains all event listeners for the selected
2459         element ancestors chain (in case option "All Nodes" is selected).
2460
2461         Reviewed by Pavel Feldman.
2462
2463         * inspector/InspectorDOMAgent.cpp:
2464         (WebCore::InspectorDOMAgent::getEventListenersForNode):
2465         * inspector/front-end/EventListenersSidebarPane.js:
2466         (WebInspector.EventListenersSidebarPane.prototype.update.callback):
2467         (WebInspector.EventListenersSidebarPane.prototype.update):
2468         (WebInspector.EventListenersSidebarPane.prototype):
2469
2470 2012-03-21  Ilya Tikhonovsky  <loislo@chromium.org>
2471
2472         Web Inspector: HeapSnapshot: move all builders and calculation calls to HeapSnapshot._init function.
2473         https://bugs.webkit.org/show_bug.cgi?id=81784
2474
2475         Reviewed by Yury Semikhatsky.
2476
2477         * inspector/front-end/HeapSnapshot.js:
2478         (WebInspector.HeapSnapshot.prototype._init):
2479         (WebInspector.HeapSnapshot.prototype.dispose):
2480         (WebInspector.HeapSnapshot.prototype._retainersForNode):
2481         (WebInspector.HeapSnapshot.prototype._dominatedNodesOfNode):
2482         (WebInspector.HeapSnapshot.prototype._flagsOfNode):
2483         (WebInspector.HeapSnapshot.prototype.aggregates):
2484         (WebInspector.HeapSnapshot.prototype._buildRetainers):
2485         (WebInspector.HeapSnapshot.prototype.get nodeIndexes):
2486
2487 2012-03-21  Jessie Berlin  <jberlin@apple.com>
2488
2489         WTF headers should be in $(ConfigurationBuildDir)\include\private\wtf, not
2490         $(ConfigurationBuildDir)\include\private\JavaScriptCore\wtf.
2491         https://bugs.webkit.org/show_bug.cgi?id=81739
2492
2493         Reviewed by Dan Bernstein.
2494
2495         * WebCore.vcproj/WebCore.vcproj:
2496         Look for AtomicString.cpp, StringBuilder.cpp, StringImpl.cpp, and WTFString.cpp in the wtf
2497         subdirectory of the build output, not the JavaScriptCore/wtf subdirectory.
2498
2499 2012-03-21  Jonathan Dong  <jonathan.dong@torchmobile.com.cn>
2500
2501         [BlackBerry] Credential save and autofill implemetation
2502         https://bugs.webkit.org/show_bug.cgi?id=80401
2503
2504         Reviewed by Rob Buis.
2505
2506         Added interface function authenticationChallenge() and
2507         notifyShouldSaveCredential() into PageClientBlackBerry.
2508         As this class is our platform specific interface,
2509         by doing this we don't need to add an interface function
2510         in class FrameLoaderClient which is a platform
2511         independent interface.
2512
2513         No new tests.
2514
2515         * platform/blackberry/PageClientBlackBerry.h:
2516         (WebCore):
2517         * platform/network/blackberry/NetworkJob.cpp:
2518         (WebCore::NetworkJob::sendRequestWithCredentials):
2519
2520 2012-03-21  Ilya Tikhonovsky  <loislo@chromium.org>
2521
2522         Web Inspector: HeapProfiler: DOM node id can overflow Int32.
2523         https://bugs.webkit.org/show_bug.cgi?id=81776
2524
2525         Reviewed by Pavel Feldman.
2526
2527         * inspector/front-end/HeapSnapshot.js:
2528         (WebInspector.Uint32Array):
2529         (WebInspector.HeapSnapshotLoader.prototype.pushJSONChunk):
2530         (WebInspector.HeapSnapshot.prototype._buildReverseIndex.var):
2531         (WebInspector.HeapSnapshot.prototype._buildReverseIndex):
2532         (WebInspector.HeapSnapshot.prototype._buildNodeIndex):
2533
2534 2012-03-21  Tim Dresser  <tdresser@chromium.org>
2535
2536         [chromium] Increase size of Combo Box Options for touch and high DPI devices
2537         https://bugs.webkit.org/show_bug.cgi?id=80027
2538
2539         Reviewed by Darin Fisher.
2540
2541         Scale Combo box popups by defaultDeviceScaleFactor, and add padding to
2542         <option> elements when touch is enabled.
2543
2544         Manually tested with --default-device-scale-factor=1,2 and unset.
2545         Each of these were tested with RuntimeEnabledFeatures::touchEnabled
2546         set to true and false.
2547
2548         * platform/chromium/PopupListBox.cpp:
2549         (WebCore::PopupListBox::paint):
2550         (WebCore::PopupListBox::paintRow):
2551         (WebCore::PopupListBox::getRowHeight):
2552         * platform/chromium/PopupListBox.h:
2553         (PopupContainerSettings):
2554         * platform/chromium/PopupMenuChromium.cpp:
2555         (WebCore):
2556         (WebCore::PopupMenuChromium::show):
2557         * platform/chromium/PopupMenuChromium.h:
2558         (WebCore::PopupMenuChromium::optionPaddingForTouch):
2559         (WebCore::PopupMenuChromium::setOptionPaddingForTouch):
2560         (PopupMenuChromium):
2561         * rendering/RenderMenuList.cpp:
2562         (WebCore::RenderMenuList::showPopup):
2563
2564 2012-03-21  Takashi Toyoshima  <toyoshim@chromium.org>
2565
2566         [Chromium] [WebSocket] provide WebFrameClient with a chance of
2567         accessing to opening WebSocketStreamHandle.
2568         https://bugs.webkit.org/show_bug.cgi?id=78459
2569
2570         Reviewed by Kent Tamura and Darin Fisher.
2571
2572         Add willOpenSocketStream client function to WebFrameClient with an
2573         argument representing an opening SocketStreamHandle.
2574         These mechanisms provide embedders with a chance to bind arbitrary
2575         data to a WebSocketStreamHandle from WebFrameClient to which the
2576         WebSocket object having the WebSocketStreamHandle belongs.
2577
2578         No new tests because this change just provide mechanisms to embedders.
2579
2580         * Modules/websockets/WebSocketChannel.cpp: Implement willOpenSocketStream to call a client function in WebFrameClient.
2581         (WebCore::WebSocketChannel::willOpenSocketStream):
2582         (WebCore):
2583         * Modules/websockets/WebSocketChannel.h: Add willOpenSocketStream declaration.
2584         (WebSocketChannel):
2585         * loader/FrameLoaderClient.h: Add dispatchWillOpenSocketStream declaration.
2586         (WebCore):
2587         (FrameLoaderClient):
2588         (WebCore::FrameLoaderClient::dispatchWillOpenSocketStream):
2589         * platform/network/SocketStreamHandleClient.h: Add willOpenSocketStream declaration.
2590         (WebCore::SocketStreamHandleClient::willOpenSocketStream):
2591
2592 2012-03-21  Vineet Chaudhary  <rgf748@motorola.com>
2593
2594         https://bugs.webkit.org/show_bug.cgi?id=81761
2595         Fix Gobject binding for sequence<T> for function return type.
2596
2597         Reviewed by Kentaro Hara.
2598
2599         No new tests.
2600
2601         * bindings/scripts/CodeGeneratorGObject.pm:
2602         (SkipFunction): Skip function with sequence<T> return type.
2603         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
2604         (webkit_dom_test_obj_method_with_sequence_arg):
2605         * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
2606
2607 2012-03-21  Andrey Kosyakov  <caseq@chromium.org>
2608
2609         Unreviewed build fix for r111529.
2610
2611         * inspector/InjectedScriptHost.h:
2612         (WebCore):
2613
2614 2012-03-21  Sheriff Bot  <webkit.review.bot@gmail.com>
2615
2616         Unreviewed, rolling out r111497, r111506, r111508, and
2617         r111513.
2618         http://trac.webkit.org/changeset/111497
2619         http://trac.webkit.org/changeset/111506
2620         http://trac.webkit.org/changeset/111508
2621         http://trac.webkit.org/changeset/111513
2622         https://bugs.webkit.org/show_bug.cgi?id=81774
2623
2624         It broke 2 tests on all platform (Requested by Ossy on
2625         #webkit).
2626
2627         * css/CSSStyleSelector.cpp:
2628         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
2629         * css/SelectorChecker.cpp:
2630         (WebCore::SelectorChecker::checkOneSelector):
2631         * html/HTMLKeygenElement.cpp:
2632         (WebCore::HTMLKeygenElement::HTMLKeygenElement):
2633         * html/HTMLOptionElement.cpp:
2634         (WebCore::HTMLOptionElement::HTMLOptionElement):
2635         (WebCore::HTMLOptionElement::create):
2636         (WebCore::HTMLOptionElement::attach):
2637         (WebCore::HTMLOptionElement::detach):
2638         (WebCore::HTMLOptionElement::formControlType):
2639         (WebCore):
2640         (WebCore::HTMLOptionElement::parseAttribute):
2641         (WebCore::HTMLOptionElement::childrenChanged):
2642         (WebCore::HTMLOptionElement::insertedIntoTree):
2643         * html/HTMLOptionElement.h:
2644         (HTMLOptionElement):
2645         (WebCore::HTMLOptionElement::ownElementDisabled):
2646         * html/HTMLTagNames.in:
2647
2648 2012-03-21  Andrey Kosyakov  <caseq@chromium.org>
2649
2650         Web Inspector: expose getEventListeners() to console command line API
2651         https://bugs.webkit.org/show_bug.cgi?id=81658
2652
2653         Reviewed by Yury Semikhatsky.
2654
2655         Test: inspector/console/command-line-api-getEventListeners.html
2656
2657         * bindings/js/JSInjectedScriptHostCustom.cpp:
2658         (WebCore::JSInjectedScriptHost::functionDetails):
2659         (WebCore):
2660         (WebCore::getJSListenerFunctions):
2661         (WebCore::JSInjectedScriptHost::getEventListeners):
2662         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
2663         (WebCore::getJSListenerFunctions):
2664         (WebCore):
2665         (WebCore::V8InjectedScriptHost::getEventListenersCallback):
2666         * inspector/InjectedScriptHost.cpp:
2667         (WebCore::InjectedScriptHost::InjectedScriptHost):
2668         (WebCore::InjectedScriptHost::disconnect):
2669         (WebCore::InjectedScriptHost::getEventListenersImpl):
2670         (WebCore):
2671         * inspector/InjectedScriptHost.h:
2672         (WebCore):
2673         (WebCore::InjectedScriptHost::init):
2674         (InjectedScriptHost):
2675         * inspector/InjectedScriptHost.idl:
2676         * inspector/InjectedScriptSource.js:
2677         (.):
2678         * inspector/InspectorController.cpp:
2679         (WebCore::InspectorController::InspectorController):
2680         * inspector/InspectorDOMAgent.cpp:
2681         (WebCore::InspectorDOMAgent::getEventListenersForNode):
2682         (WebCore::InspectorDOMAgent::getEventListeners):
2683         (WebCore):
2684         * inspector/InspectorDOMAgent.h:
2685         (InspectorDOMAgent):
2686         * inspector/WorkerInspectorController.cpp:
2687         (WebCore::WorkerInspectorController::WorkerInspectorController):
2688
2689 2012-03-21  Kentaro Hara  <haraken@chromium.org>
2690
2691         Unreviewed, rebaselined run-bindings-tests results.
2692
2693         * bindings/scripts/test/CPP/WebDOMFloat64Array.cpp:
2694         * bindings/scripts/test/GObject/WebKitDOMFloat64Array.cpp:
2695         * bindings/scripts/test/GObject/WebKitDOMFloat64ArrayPrivate.h:
2696         * bindings/scripts/test/ObjC/DOMFloat64Array.mm:
2697
2698 2012-03-21  Ian Vollick  <vollick@chromium.org>
2699
2700         [chromium] timing functions are getting incorrectly applied for accelerated css transitions
2701         https://bugs.webkit.org/show_bug.cgi?id=81692
2702
2703         Reviewed by Adrienne Walker.
2704
2705         Tested in CCLayerTreeHostTestAddAnimationWithTimingFunction
2706
2707         * platform/graphics/chromium/cc/CCLayerAnimationController.cpp:
2708
2709 2012-03-21  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
2710
2711         [Qt] Cookie Jar blocks on fsync in SQLITE
2712         https://bugs.webkit.org/show_bug.cgi?id=81755
2713
2714         Reviewed by Simon Hausmann.
2715
2716         Set PRAGMA synchronous to OFF, which tells SQLITE to never fsync.
2717
2718         * platform/qt/CookieJarQt.cpp:
2719         (WebCore::SharedCookieJarQt::ensureDatabaseTable):
2720
2721 2012-03-21  Ian Vollick  <vollick@chromium.org>
2722
2723         [chromium] Animation events should only be used for synchronizing animation start times
2724         https://bugs.webkit.org/show_bug.cgi?id=81484
2725
2726         Reviewed by Adrienne Walker.
2727
2728         Tested in CCLayerTreeHostTestSynchronizeAnimationStartTimes
2729
2730         Eliminated animation finished events. Animations will finish naturally on the
2731         main thread and the final values will be set.
2732
2733         Animation started events are now also used to synchronize the main thread
2734         animations' start times with their impl thread equivalents, preventing skew.
2735         Until main thread animations receive their synchronized start times, they will
2736         apply their initial values (i.e., they will be paused at time zero). This
2737         guarantees that we will not jump to the animation's final value on the main
2738         thread while we wait for the synchronized start time.
2739
2740         * WebCore.gypi:
2741         * platform/graphics/chromium/LayerChromium.cpp:
2742         (WebCore::LayerChromium::notifyAnimationStarted):
2743         * platform/graphics/chromium/LayerChromium.h:
2744         (WebCore):
2745         (LayerChromium):
2746         * platform/graphics/chromium/cc/CCActiveAnimation.cpp:
2747         (WebCore::CCActiveAnimation::CCActiveAnimation):
2748         * platform/graphics/chromium/cc/CCActiveAnimation.h:
2749         (CCActiveAnimation):
2750         (WebCore::CCActiveAnimation::needsSynchronizedStartTime):
2751         (WebCore::CCActiveAnimation::setNeedsSynchronizedStartTime):
2752         * platform/graphics/chromium/cc/CCAnimationEvents.cpp: Removed.
2753         * platform/graphics/chromium/cc/CCAnimationEvents.h:
2754         (WebCore::CCAnimationStartedEvent::CCAnimationStartedEvent):
2755         (CCAnimationStartedEvent):
2756         (WebCore):
2757         * platform/graphics/chromium/cc/CCLayerAnimationController.cpp:
2758         (WebCore::CCLayerAnimationController::animate):
2759         (WebCore::CCLayerAnimationController::notifyAnimationStarted):
2760         (WebCore):
2761         (WebCore::CCLayerAnimationController::pushNewAnimationsToImplThread):
2762         (WebCore::CCLayerAnimationController::startAnimationsWaitingForNextTick):
2763         (WebCore::CCLayerAnimationController::startAnimationsWaitingForStartTime):
2764         (WebCore::CCLayerAnimationController::startAnimationsWaitingForTargetAvailability):
2765         (WebCore::CCLayerAnimationController::purgeFinishedAnimations):
2766         (WebCore::CCLayerAnimationController::tickAnimations):
2767         * platform/graphics/chromium/cc/CCLayerAnimationController.h:
2768         (CCLayerAnimationController):
2769         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
2770         (WebCore::CCLayerTreeHost::updateAnimations):
2771         (WebCore::CCLayerTreeHost::setAnimationEventsRecursive):
2772         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
2773         (CCLayerTreeHost):
2774
2775 2012-03-21  Zeno Albisser  <zeno@webkit.org>
2776
2777         [Qt][WK2][Mac] MiniBrowser asserts at HashTable.h:480
2778         https://bugs.webkit.org/show_bug.cgi?id=81113
2779
2780         The GLContext is created by QWindow/QSurface using
2781         QOpenGLContext which is implemented using NSOpenGL functions
2782         on mac. Therefore we should use QOpenGLContext as well when
2783         querying for the current context. AGL is not supposed
2784         to be paired with NSOpenGL.
2785         Altering the typedef for GLContext is fine, since
2786         the GLContext type is only used as a key in a map.
2787
2788         Reviewed by Kenneth Rohde Christiansen.
2789
2790         * platform/graphics/texmap/TextureMapperGL.cpp:
2791         (SharedGLData):
2792         (WebCore::TextureMapperGLData::SharedGLData::getCurrentGLContext):
2793
2794 2012-03-21  Ilya Tikhonovsky  <loislo@chromium.org>
2795
2796         Web Inspector: HeapSnapshot: make _bfs twice as fast as the old version.
2797         https://bugs.webkit.org/show_bug.cgi?id=81756
2798
2799         Reviewed by Yury Semikhatsky.
2800
2801         * inspector/front-end/HeapSnapshot.js:
2802         (WebInspector.HeapSnapshot.prototype._calculateObjectToWindowDistance):
2803         (WebInspector.HeapSnapshot.prototype._bfs):
2804
2805 2012-03-21  Vineet Chaudhary  <rgf748@motorola.com>
2806
2807         https://bugs.webkit.org/show_bug.cgi?id=81705
2808         REGRESSION (r111416): fast/dom/prototype-inheritance-2.html is failing.
2809
2810         Reviewed by Csaba Osztrogonác.
2811
2812         No new tests.
2813
2814         * bindings/js/JSDOMBinding.h: Needs passing globalObject to constructArray().
2815         (WebCore::jsArray):
2816
2817 2012-03-21  Jonathan Dong  <jonathan.dong@torchmobile.com.cn>
2818
2819         [BlackBerry] Upstreaming blackberry specific css file
2820         https://bugs.webkit.org/show_bug.cgi?id=81650
2821
2822         Ustream BlackBerry specific css files, including:
2823         css/themeBlackBerry.css
2824         css/mediaControlsBlackBerry.css
2825
2826         Reviewed by Nikolas Zimmermann.
2827
2828         No new tests, this is the initial upstream patch
2829         for BlackBerry specific css files.
2830
2831         * css/mediaControlsBlackBerry.css: Added.
2832         (audio):
2833         (audio::-webkit-media-controls-panel, video::-webkit-media-controls-panel):
2834         (video:-webkit-full-page-media::-webkit-media-controls-panel):
2835         (audio::-webkit-media-controls-play-button, video::-webkit-media-controls-play-button):
2836         (audio::-webkit-media-controls-timeline-container, video::-webkit-media-controls-timeline-container):
2837         (audio::-webkit-media-controls-current-time-display, video::-webkit-media-controls-current-time-display):
2838         (audio::-webkit-media-controls-time-remaining-display, video::-webkit-media-controls-time-remaining-display):
2839         (audio::-webkit-media-controls-timeline, video::-webkit-media-controls-timeline):
2840         (audio::-webkit-media-controls-fullscreen-button, video::-webkit-media-controls-fullscreen-button):
2841         (audio::-webkit-media-controls-mute-button, video::-webkit-media-controls-mute-button):
2842         (audio::-webkit-media-controls-volume-slider-container, video::-webkit-media-controls-volume-slider-container):
2843         (audio::-webkit-media-controls-volume-slider, video::-webkit-media-controls-volume-slider):
2844         (audio::-webkit-media-controls-seek-back-button, video::-webkit-media-controls-seek-back-button):
2845         (audio::-webkit-media-controls-seek-forward-button, video::-webkit-media-controls-seek-forward-button):
2846         * css/themeBlackBerry.css: Added.
2847         (textarea):
2848         (input, textarea):
2849         (input[type="color"]):
2850         (select:focus):
2851         (select[size][multiple]):
2852         (select[size][multiple]:focus):
2853
2854 2012-03-21  Levi Weintraub  <leviw@chromium.org>
2855
2856         Update LayoutUnit usage in descendants of RenderReplaced
2857         https://bugs.webkit.org/show_bug.cgi?id=80918
2858
2859         Reviewed by Eric Seidel.
2860
2861         Replaced elements have to flow in the new sub-pixel Render Tree, but since the rendering of these
2862         often takes place outside of WebCore (or in cases such as foreign objects, in WebCore after
2863         passing through platform code), care must be taken to determine the final rendered size and
2864         location before render time. This patch brings these classes up to the latest and greatest in the
2865         subpixellayout branch.
2866
2867         See https://trac.webkit.org/wiki/LayoutUnit for more information.
2868
2869         No new tests. No change in behavior.
2870
2871         * rendering/RenderFrameBase.cpp:
2872         (WebCore::RenderFrameBase::layoutWithFlattening): Build Fix.
2873         * rendering/RenderFullScreen.cpp:
2874         (RenderFullScreen::createPlaceholder): Ditto.
2875         * rendering/RenderFullScreen.h:
2876         (RenderFullScreen): Ditto.
2877         * rendering/RenderHTMLCanvas.cpp:
2878         (WebCore::RenderHTMLCanvas::canvasSizeChanged): Ditto.
2879         * rendering/RenderIFrame.cpp:
2880         (WebCore::RenderIFrame::computeLogicalHeight): Ditto.
2881         (WebCore::RenderIFrame::computeLogicalWidth): Ditto.
2882         * rendering/RenderImage.cpp:
2883         (WebCore::RenderImage::updateIntrinsicSizeIfNeeded): Intrinsic sizes are always integers, since they
2884         originate outside of WebCore.
2885         (WebCore::RenderImage::paintIntoRect): Use pixel snapping to paint into an arbitrary rect.
2886         (WebCore::RenderImage::computeReplacedLogicalWidth): Intrinsic size is always integral -- rounding
2887         values to integers.
2888         * rendering/RenderImage.h:
2889         (RenderImage):
2890         * rendering/RenderVideo.cpp:
2891         (WebCore::RenderVideo::videoBox):
2892         (WebCore::RenderVideo::paintReplaced): Painting at integer boundaries.
2893         * rendering/RenderWidget.cpp:
2894         (WebCore):
2895         (WebCore::roundedIntRect): Widgets are rendered outside of WebCore, so we always align them to
2896         integer boundaries. This means we can actually round the size of our ultimate content box. This
2897         function is implemented here specifically to prevent its misuse if we put it elsewhere.
2898         (WebCore::RenderWidget::setWidgetGeometry): We simplify layout by taking a LayoutRect and rounding
2899         it to its final location within this function.
2900         (WebCore::RenderWidget::updateWidgetGeometry): We keep things in LayoutUnits until handing off to
2901         setWidgetGeometry.
2902         (WebCore::RenderWidget::paint): Rounding the paint location before handing painting off to the
2903         widget itself.
2904         * rendering/RenderWidget.h:
2905         (RenderWidget):
2906
2907 2012-03-21  Ilya Tikhonovsky  <loislo@chromium.org>
2908
2909         Web Inspector: HeapProfiler: support distance column in Summary View.
2910         https://bugs.webkit.org/show_bug.cgi?id=81675
2911
2912         In many cases when a page leaked an object we see not only this object
2913         but the all objects it retains. It is quite difficult to find out which
2914         the object is the root of leak. It'd be simpler to sort the leaked
2915         objects by Distance column and track down the first one.
2916
2917         Reviewed by Yury Semikhatsky.
2918
2919         * inspector/front-end/DetailedHeapshotGridNodes.js:
2920         (WebInspector.HeapSnapshotGenericObjectNode):
2921         (WebInspector.HeapSnapshotGenericObjectNode.prototype.get data):
2922         (WebInspector.HeapSnapshotInstanceNode.prototype.comparator):
2923         (WebInspector.HeapSnapshotConstructorNode):
2924         (WebInspector.HeapSnapshotConstructorNode.prototype.comparator):
2925         (WebInspector.HeapSnapshotConstructorNode.prototype.get data):
2926         * inspector/front-end/DetailedHeapshotView.js:
2927         (WebInspector.HeapSnapshotConstructorsDataGrid):
2928         (WebInspector.HeapSnapshotConstructorsDataGrid.prototype._defaultPopulateCount.100._sortFields):
2929         * inspector/front-end/HeapSnapshot.js:
2930         (WebInspector.HeapSnapshotNodesProvider.prototype._serialize):
2931
2932 2012-03-21  Charles Wei  <charles.wei@torchmobile.com.cn>
2933
2934         [BlackBerry] Remove redundant code in SocketStreamHandler
2935         https://bugs.webkit.org/show_bug.cgi?id=81726
2936
2937         Reviewed by George Staikos.
2938
2939         No new tests needed. Just remove redundant code.
2940
2941         * platform/network/blackberry/SocketStreamHandle.h:
2942         (SocketStreamHandle):
2943         * platform/network/blackberry/SocketStreamHandleBlackBerry.cpp:
2944
2945 2012-03-20  Eric Seidel  <eric@webkit.org>
2946
2947         Move wtf/Platform.h from JavaScriptCore to Source/WTF/wtf
2948         https://bugs.webkit.org/show_bug.cgi?id=80911
2949
2950         Reviewed by Adam Barth.
2951
2952         * CMakeLists.txt:
2953          - Look for headers in Source/WTF as well.
2954
2955 2012-03-20  Dana Jansens  <danakj@chromium.org>
2956
2957         [chromium] Use origin transform to transform occlusion from surface content space to its target content space
2958         https://bugs.webkit.org/show_bug.cgi?id=81730
2959
2960         Reviewed by Adrienne Walker.
2961
2962         Unit test: CCOcclusionTrackerTestSurfaceOcclusionTranslatesToParent
2963
2964         * platform/graphics/chromium/cc/CCOcclusionTracker.cpp:
2965         (WebCore::transformSurfaceOpaqueRegion):
2966         (WebCore::::leaveToTargetRenderSurface):
2967
2968 2012-03-19  Shinya Kawanaka  <shinyak@chromium.org>
2969
2970         [Crash] RenderMenuList::addChild() in Shadow DOM.
2971         https://bugs.webkit.org/show_bug.cgi?id=81201
2972
2973         Reviewed by Dimitri Glazkov.
2974
2975         <audio>, <video>, <meter>, <progress>, and <select> are implemented using
2976         Shadow DOM having HTMLContentElement. Their renderer children basically should not
2977         create a renderer unless they are on the upper shadow encapsulation boundary,
2978         which means they are the direct children of the shadow root.
2979
2980         However, current implementation allows their renderer children to create a renderer
2981         even if they are on a lower shadow encapsulation boundary, which means
2982         they are distributed elements of HTMLContentElement.
2983
2984         This patch makes there renderer children not to create a renderer if they are on a lower shadow
2985         encapsulation boudary.
2986
2987         Tests: fast/dom/shadow/content-element-in-media-element.html
2988                fast/dom/shadow/content-element-in-meter-element.html
2989                fast/dom/shadow/content-element-in-progress-element.html
2990                fast/dom/shadow/content-element-in-select-element.html
2991
2992         * dom/NodeRenderingContext.h:
2993         (NodeRenderingContext):
2994         (WebCore::NodeRenderingContext::isOnUpperEncapsulationBoundary):
2995         (WebCore):
2996         * html/HTMLMediaElement.cpp:
2997         (WebCore::HTMLMediaElement::childShouldCreateRenderer):
2998         * html/HTMLMeterElement.cpp:
2999         (WebCore::HTMLMeterElement::childShouldCreateRenderer):
3000         * html/HTMLProgressElement.cpp:
3001         (WebCore::HTMLProgressElement::childShouldCreateRenderer):
3002         * html/HTMLSelectElement.cpp:
3003         (WebCore::HTMLSelectElement::childShouldCreateRenderer):
3004
3005 2012-03-20  Dana Jansens  <danakj@chromium.org>
3006
3007         [chromium] Store origin/screen space transforms for surface and replica in the surface
3008         https://bugs.webkit.org/show_bug.cgi?id=81296
3009
3010         Reviewed by Adrienne Walker.
3011
3012         Compute and save a number of transforms for render surfaces. The origin
3013         tranform for the replica into its target surface. The origin transform
3014         for the replica into the screen. And the origin transform for the surface
3015         into the screen.
3016
3017         These transforms will allow us to detect occlusion of render surfaces,
3018         allowing us to cull (or partially-cull) the render surface quad during
3019         drawing.
3020
3021         This also fixes a subtle bug in the transforms used by the damage
3022         tracking code.
3023
3024         Unit test: CCLayerTreeHostCommonTest.verifyTransformsForSingleRenderSurface
3025                    CCLayerTreeHostCommonTest.verifyTransformsForReplica
3026                    CCLayerTreeHostCommonTest.verifyTransformsForRenderSurfaceHierarchy
3027
3028         * platform/graphics/chromium/RenderSurfaceChromium.h:
3029         (WebCore::RenderSurfaceChromium::screenSpaceTransform):
3030         (WebCore::RenderSurfaceChromium::setScreenSpaceTransform):
3031         (RenderSurfaceChromium):
3032         (WebCore::RenderSurfaceChromium::replicaOriginTransform):
3033         (WebCore::RenderSurfaceChromium::setReplicaOriginTransform):
3034         (WebCore::RenderSurfaceChromium::replicaScreenSpaceTransform):
3035         (WebCore::RenderSurfaceChromium::setReplicaScreenSpaceTransform):
3036         * platform/graphics/chromium/cc/CCDamageTracker.cpp:
3037         (WebCore::CCDamageTracker::extendDamageForRenderSurface):
3038         * platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp:
3039         (WebCore::calculateDrawTransformsAndVisibilityInternal):
3040         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
3041         (WebCore::damageInSurfaceSpace):
3042         * platform/graphics/chromium/cc/CCRenderSurface.h:
3043         (WebCore::CCRenderSurface::setDrawTransform):
3044         (WebCore::CCRenderSurface::drawTransform):
3045         (WebCore::CCRenderSurface::setScreenSpaceTransform):
3046         (WebCore::CCRenderSurface::screenSpaceTransform):
3047         (CCRenderSurface):
3048         (WebCore::CCRenderSurface::setReplicaDrawTransform):
3049         (WebCore::CCRenderSurface::replicaDrawTransform):
3050         (WebCore::CCRenderSurface::setReplicaOriginTransform):
3051         (WebCore::CCRenderSurface::replicaOriginTransform):
3052         (WebCore::CCRenderSurface::setReplicaScreenSpaceTransform):
3053         (WebCore::CCRenderSurface::replicaScreenSpaceTransform):
3054
3055 2012-03-20  Yoshifumi Inoue  <yosin@chromium.org>
3056
3057         [Forms] The option element should not be form associated element.
3058         https://bugs.webkit.org/show_bug.cgi?id=79764
3059
3060         Reviewed by Kent Tamura.
3061
3062         This patch changes base class of HTMLOptionELement to HTMLElement
3063         from HTMLFormControlElement for saving memory space and iteration
3064         time of extra "option" elements in HTMLFormElement::m_formAssociatedElements
3065         and matching the HTML5 specification for ease of maintenance.
3066
3067         This patch changes behavior of handling of CSS pseudo classes "invalid"
3068         and "valid". The "option" elements no longer use these CSS pseudo classes
3069         as HTML5 specification. This bug was filed in https://bugs.webkit.org/show_bug.cgi?id=80088
3070
3071         Changes of TextIterator is lead by usage of isFormControlElement. This
3072         changes will be replaced with more meaningful predicate as part of
3073         https://bugs.webkit.org/show_bug.cgi?id=80381
3074
3075         No new tests but updated select-live-pseudo-selectors.html test.
3076
3077         * css/CSSStyleSelector.cpp:
3078         (WebCore::CSSStyleSelector::canShareStyleWithElement): Added checking of the "option" element and returns false as HTMLFormControlElement.
3079         * css/SelectorChecker.cpp:
3080         (WebCore::SelectorChecker::checkOneSelector): Removed isFormControlElement for PseudoDisabled and PseudoChecked.
3081         * html/HTMLKeygenElement.cpp:
3082         (WebCore::HTMLKeygenElement::HTMLKeygenElement): Removed form parameter of call site of HTMLOptionElement::create.
3083         * html/HTMLOptionElement.cpp:
3084         (WebCore::HTMLOptionElement::HTMLOptionElement): Removed form parameter which no longer needed. Changed base class in initialization list. Added m_disabled initialization.
3085         (WebCore::HTMLOptionElement::create): Removed form parameter which no longer needed.
3086         (WebCore::HTMLOptionElement::attach): Changeid base class.
3087         (WebCore::HTMLOptionElement::detach): Changed base class.
3088         (WebCore::HTMLOptionElement::parseAttribute): Changed base class. Added "disabled" attribute handling.
3089         (WebCore::HTMLOptionElement::childrenChanged): Changed base class.
3090         (WebCore::HTMLOptionElement::insertedIntoTree): Changed base class.
3091         * html/HTMLOptionElement.h:
3092         (HTMLOptionElement): Added new member variable m_disabled which was in HTMLFormControlElement.
3093         (WebCore::HTMLOptionElement::ownElementDisabled): Changed for using m_disabled.
3094         * html/HTMLTagNames.in: Removed constructorNeedsFormElement for the "option" element, which was used for passing form parameter to create function.
3095
3096 2012-03-20  Xiaomei Ji  <xji@chromium.org>
3097
3098         Crash introduced in r110965.
3099         https://bugs.webkit.org/show_bug.cgi?id=81720
3100
3101         Reviewed by Ryosuke Niwa.
3102
3103         Since word break iterator just keeps a pointer to the UChar array given to the constructor,
3104         we need to allocate the UChar array deeper in the stack than the iterator.
3105
3106         Test: editing/selection/move-by-word-visually-crash-test-5.html
3107
3108         * editing/visible_units.cpp:
3109         (WebCore::wordBreakIteratorForMinOffsetBoundary):
3110         (WebCore::wordBreakIteratorForMaxOffsetBoundary):
3111         (WebCore::visualWordPosition):
3112
3113 2012-03-20  W. James MacLean  <wjmaclean@chromium.org>
3114
3115         [chromium] Convert TouchFlingPlatformGestureCurve to a 2-D Bezier for better control of curve shape.
3116         https://bugs.webkit.org/show_bug.cgi?id=81713
3117
3118         Reviewed by Dirk Pranke.
3119
3120         Exisiting unit test revised to cover this change.
3121
3122         Change the fling gesture animation curve to use a 2-D Bezier to obtain greater control
3123         over the shape of the curve. Also, change time scaling code to be logarithmic for more
3124         natural feel.
3125
3126         * platform/TouchFlingPlatformGestureCurve.cpp:
3127         (WebCore::TouchFlingPlatformGestureCurve::TouchFlingPlatformGestureCurve):
3128         (WebCore::TouchFlingPlatformGestureCurve::apply):
3129
3130 2012-03-18  Tim Horton  <timothy_horton@apple.com>
3131
3132         Infinite repaint loop with SVGImageCache and deferred repaint timers
3133         https://bugs.webkit.org/show_bug.cgi?id=78315
3134         <rdar://problem/10651634>
3135
3136         Reviewed by Nikolas Zimmermann.
3137
3138         Only defer image redraw on a timer if we're in layout. This breaks
3139         the repaint loop while still preventing us from drawing inside layout.
3140
3141         Completely disable repaint during relayout inside SVGImage::drawSVGToImageBuffer,
3142         preventing deferred repaint timers from being started during that process.
3143
3144         No new tests, as the problem only occurs in a nonstandard configuration.
3145
3146         * page/FrameView.cpp:
3147         (WebCore::FrameView::FrameView):
3148         (WebCore::FrameView::reset):
3149         (WebCore::FrameView::repaintContentRectangle):
3150         (WebCore::FrameView::endDeferredRepaints):
3151         (WebCore::FrameView::startDeferredRepaintTimer):
3152         (WebCore):
3153         (WebCore::FrameView::doDeferredRepaints):
3154         (WebCore::FrameView::deferredRepaintTimerFired):
3155         (WebCore::FrameView::beginDisableRepaints):
3156         (WebCore::FrameView::endDisableRepaints):
3157         * page/FrameView.h:
3158         (FrameView):
3159         (WebCore::FrameView::repaintsDisabled):
3160         * rendering/RenderView.cpp:
3161         (WebCore::RenderView::shouldRepaint):
3162         * svg/graphics/SVGImage.cpp:
3163         (WebCore::SVGImage::drawSVGToImageBuffer):
3164         (WebCore::SVGImage::draw):
3165         (WebCore::SVGImage::frameView):
3166         (WebCore):
3167         * svg/graphics/SVGImage.h:
3168         (WebCore):
3169         * svg/graphics/SVGImageCache.cpp:
3170         (WebCore::SVGImageCache::imageContentChanged):
3171         (WebCore::SVGImageCache::redraw):
3172         (WebCore::SVGImageCache::redrawTimerFired):
3173         (WebCore):
3174         * svg/graphics/SVGImageCache.h:
3175         (SVGImageCache):
3176
3177 2012-03-20  Adam Klein  <adamk@chromium.org>
3178
3179         Include fix for dom/xhtml test promised in r111449.
3180
3181         * dom/ContainerNode.cpp:
3182         (WebCore::ContainerNode::replaceChild): Check against next instead of
3183         prev when deciding there's no work to do.
3184
3185 2012-03-20  Jon Lee  <jonlee@apple.com>
3186
3187         Restrict access to notifications for unique origins and file URLs with no local file access
3188         https://bugs.webkit.org/show_bug.cgi?id=79704
3189         <rdar://problem/10912430>
3190
3191         Reviewed by Adam Barth.
3192
3193         Before checking or requesting permissions, we look at whether we can show notifications based on
3194         the security context. If not, we short circuit and do not forward the request to the client.
3195
3196         * notifications/Notification.cpp:
3197         (WebCore::Notification::Notification): Fix a bug where creating a notification goes through slightly
3198         different logic for checking permissions than when checking permissions through the
3199         notification center.
3200         * notifications/NotificationCenter.cpp:
3201         (WebCore::NotificationCenter::checkPermission): Check to see if the origin can show notifications.
3202         (WebCore::NotificationCenter::requestPermission): If we know whether an origin can show notifications,
3203         we asynchronously call the callback with that decision. Otherwise we ask the client.
3204
3205         Add new variable in the notification center to keep track of pending callbacks when we short-circuit
3206         requestPermission().
3207         * notifications/NotificationCenter.h:
3208         (NotificationRequestCallback): Add new private class encapsulating the callback.
3209         * notifications/NotificationCenter.cpp:
3210         (WebCore::NotificationCenter::requestTimedOut): Remove the request from the set of pending callbacks.
3211         (WebCore::NotificationCenter::NotificationRequest::createAndStartTimer): Because this is used when we already
3212         know the decision, and are not asking the client to decide, we can immediately trigger a one-shot timer
3213         to invoke the callback.
3214         (WebCore::NotificationCenter::NotificationRequest::NotificationRequest):
3215         (WebCore::NotificationCenter::NotificationRequest::startTimer):
3216         (WebCore::NotificationCenter::NotificationRequest::timerFired): Invoke the callback and tell the notification
3217         center.
3218         * page/SecurityOrigin.h: Add new toRawString() method to return the string representation of the origin,
3219         regardless of any restrictions that might otherwise cause toString() to return "null".
3220         * page/SecurityOrigin.cpp:
3221         (WebCore::SecurityOrigin::canShowNotifications): Added to return a tri-state regarding whether we know
3222         the origin can show notifications. If the origin is unique, we never let it show. If the origin has
3223         universal access, we always let it show. Otherwise the client should be asked.
3224         (WebCore::SecurityOrigin::toString): Refactor to use toRawString().
3225         (WebCore::SecurityOrigin::toRawString):
3226
3227         Added FIXME's regarding the naming of enforceFilePathSeparation().
3228         * dom/Document.cpp:
3229         (WebCore::Document::initSecurityContext): Also, tab reformatting.
3230
3231         * WebCore.exp.in: Export toRawString().
3232
3233 2012-03-20  Mark Pilgrim  <pilgrim@chromium.org>
3234
3235         Move webaudio to Modules/webaudio/
3236         https://bugs.webkit.org/show_bug.cgi?id=81541
3237
3238         Reviewed by Kentaro Hara.
3239
3240         No new tests, all existing tests pass.
3241
3242         * CMakeLists.txt:
3243         * DerivedSources.make:
3244         * DerivedSources.pri:
3245         * GNUmakefile.am:
3246         * GNUmakefile.list.am:
3247         * Modules/webaudio: Added.
3248         * Modules/webaudio/AsyncAudioDecoder.cpp: Copied from Source/WebCore/webaudio/AsyncAudioDecoder.cpp.
3249         * Modules/webaudio/AsyncAudioDecoder.h: Copied from Source/WebCore/webaudio/AsyncAudioDecoder.h.
3250         * Modules/webaudio/AudioBasicProcessorNode.cpp: Copied from Source/WebCore/webaudio/AudioBasicProcessorNode.cpp.
3251         * Modules/webaudio/AudioBasicProcessorNode.h: Copied from Source/WebCore/webaudio/AudioBasicProcessorNode.h.
3252         * Modules/webaudio/AudioBuffer.cpp: Copied from Source/WebCore/webaudio/AudioBuffer.cpp.
3253         * Modules/webaudio/AudioBuffer.h: Copied from Source/WebCore/webaudio/AudioBuffer.h.
3254         * Modules/webaudio/AudioBuffer.idl: Copied from Source/WebCore/webaudio/AudioBuffer.idl.
3255         * Modules/webaudio/AudioBufferCallback.h: Copied from Source/WebCore/webaudio/AudioBufferCallback.h.
3256         * Modules/webaudio/AudioBufferCallback.idl: Copied from Source/WebCore/webaudio/AudioBufferCallback.idl.
3257         * Modules/webaudio/AudioBufferSourceNode.cpp: Copied from Source/WebCore/webaudio/AudioBufferSourceNode.cpp.
3258         * Modules/webaudio/AudioBufferSourceNode.h: Copied from Source/WebCore/webaudio/AudioBufferSourceNode.h.
3259         * Modules/webaudio/AudioBufferSourceNode.idl: Copied from Source/WebCore/webaudio/AudioBufferSourceNode.idl.
3260         * Modules/webaudio/AudioChannelMerger.cpp: Copied from Source/WebCore/webaudio/AudioChannelMerger.cpp.
3261         * Modules/webaudio/AudioChannelMerger.h: Copied from Source/WebCore/webaudio/AudioChannelMerger.h.
3262         * Modules/webaudio/AudioChannelMerger.idl: Copied from Source/WebCore/webaudio/AudioChannelMerger.idl.
3263         * Modules/webaudio/AudioChannelSplitter.cpp: Copied from Source/WebCore/webaudio/AudioChannelSplitter.cpp.
3264         * Modules/webaudio/AudioChannelSplitter.h: Copied from Source/WebCore/webaudio/AudioChannelSplitter.h.
3265         * Modules/webaudio/AudioChannelSplitter.idl: Copied from Source/WebCore/webaudio/AudioChannelSplitter.idl.
3266         * Modules/webaudio/AudioContext.cpp: Copied from Source/WebCore/webaudio/AudioContext.cpp.
3267         * Modules/webaudio/AudioContext.h: Copied from Source/WebCore/webaudio/AudioContext.h.
3268         * Modules/webaudio/AudioContext.idl: Copied from Source/WebCore/webaudio/AudioContext.idl.
3269         * Modules/webaudio/AudioDestinationNode.cpp: Copied from Source/WebCore/webaudio/AudioDestinationNode.cpp.
3270         * Modules/webaudio/AudioDestinationNode.h: Copied from Source/WebCore/webaudio/AudioDestinationNode.h.
3271         * Modules/webaudio/AudioDestinationNode.idl: Copied from Source/WebCore/webaudio/AudioDestinationNode.idl.
3272         * Modules/webaudio/AudioGain.h: Copied from Source/WebCore/webaudio/AudioGain.h.
3273         * Modules/webaudio/AudioGain.idl: Copied from Source/WebCore/webaudio/AudioGain.idl.
3274         * Modules/webaudio/AudioGainNode.cpp: Copied from Source/WebCore/webaudio/AudioGainNode.cpp.
3275         * Modules/webaudio/AudioGainNode.h: Copied from Source/WebCore/webaudio/AudioGainNode.h.
3276         * Modules/webaudio/AudioGainNode.idl: Copied from Source/WebCore/webaudio/AudioGainNode.idl.
3277         * Modules/webaudio/AudioListener.cpp: Copied from Source/WebCore/webaudio/AudioListener.cpp.
3278         * Modules/webaudio/AudioListener.h: Copied from Source/WebCore/webaudio/AudioListener.h.
3279         * Modules/webaudio/AudioListener.idl: Copied from Source/WebCore/webaudio/AudioListener.idl.
3280         * Modules/webaudio/AudioNode.cpp: Copied from Source/WebCore/webaudio/AudioNode.cpp.
3281         * Modules/webaudio/AudioNode.h: Copied from Source/WebCore/webaudio/AudioNode.h.
3282         * Modules/webaudio/AudioNode.idl: Copied from Source/WebCore/webaudio/AudioNode.idl.
3283         * Modules/webaudio/AudioNodeInput.cpp: Copied from Source/WebCore/webaudio/AudioNodeInput.cpp.
3284         * Modules/webaudio/AudioNodeInput.h: Copied from Source/WebCore/webaudio/AudioNodeInput.h.
3285         * Modules/webaudio/AudioNodeOutput.cpp: Copied from Source/WebCore/webaudio/AudioNodeOutput.cpp.
3286         * Modules/webaudio/AudioNodeOutput.h: Copied from Source/WebCore/webaudio/AudioNodeOutput.h.
3287         * Modules/webaudio/AudioPannerNode.cpp: Copied from Source/WebCore/webaudio/AudioPannerNode.cpp.
3288         * Modules/webaudio/AudioPannerNode.h: Copied from Source/WebCore/webaudio/AudioPannerNode.h.
3289         * Modules/webaudio/AudioPannerNode.idl: Copied from Source/WebCore/webaudio/AudioPannerNode.idl.
3290         * Modules/webaudio/AudioParam.cpp: Copied from Source/WebCore/webaudio/AudioParam.cpp.
3291         * Modules/webaudio/AudioParam.h: Copied from Source/WebCore/webaudio/AudioParam.h.
3292         * Modules/webaudio/AudioParam.idl: Copied from Source/WebCore/webaudio/AudioParam.idl.
3293         * Modules/webaudio/AudioParamTimeline.cpp: Copied from Source/WebCore/webaudio/AudioParamTimeline.cpp.
3294         * Modules/webaudio/AudioParamTimeline.h: Copied from Source/WebCore/webaudio/AudioParamTimeline.h.
3295         * Modules/webaudio/AudioProcessingEvent.cpp: Copied from Source/WebCore/webaudio/AudioProcessingEvent.cpp.
3296         * Modules/webaudio/AudioProcessingEvent.h: Copied from Source/WebCore/webaudio/AudioProcessingEvent.h.
3297         * Modules/webaudio/AudioProcessingEvent.idl: Copied from Source/WebCore/webaudio/AudioProcessingEvent.idl.
3298         * Modules/webaudio/AudioSourceNode.h: Copied from Source/WebCore/webaudio/AudioSourceNode.h.
3299         * Modules/webaudio/AudioSourceNode.idl: Copied from Source/WebCore/webaudio/AudioSourceNode.idl.
3300         * Modules/webaudio/BiquadDSPKernel.cpp: Copied from Source/WebCore/webaudio/BiquadDSPKernel.cpp.
3301         * Modules/webaudio/BiquadDSPKernel.h: Copied from Source/WebCore/webaudio/BiquadDSPKernel.h.
3302         * Modules/webaudio/BiquadFilterNode.cpp: Copied from Source/WebCore/webaudio/BiquadFilterNode.cpp.
3303         * Modules/webaudio/BiquadFilterNode.h: Copied from Source/WebCore/webaudio/BiquadFilterNode.h.
3304         * Modules/webaudio/BiquadFilterNode.idl: Copied from Source/WebCore/webaudio/BiquadFilterNode.idl.
3305         * Modules/webaudio/BiquadProcessor.cpp: Copied from Source/WebCore/webaudio/BiquadProcessor.cpp.
3306         * Modules/webaudio/BiquadProcessor.h: Copied from Source/WebCore/webaudio/BiquadProcessor.h.
3307         * Modules/webaudio/ConvolverNode.cpp: Copied from Source/WebCore/webaudio/ConvolverNode.cpp.
3308         * Modules/webaudio/ConvolverNode.h: Copied from Source/WebCore/webaudio/ConvolverNode.h.
3309         * Modules/webaudio/ConvolverNode.idl: Copied from Source/WebCore/webaudio/ConvolverNode.idl.
3310         * Modules/webaudio/DOMWindowWebAudio.idl: Copied from Source/WebCore/webaudio/DOMWindowWebAudio.idl.
3311         * Modules/webaudio/DefaultAudioDestinationNode.cpp: Copied from Source/WebCore/webaudio/DefaultAudioDestinationNode.cpp.
3312         * Modules/webaudio/DefaultAudioDestinationNode.h: Copied from Source/WebCore/webaudio/DefaultAudioDestinationNode.h.
3313         * Modules/webaudio/DelayDSPKernel.cpp: Copied from Source/WebCore/webaudio/DelayDSPKernel.cpp.
3314         * Modules/webaudio/DelayDSPKernel.h: Copied from Source/WebCore/webaudio/DelayDSPKernel.h.
3315         * Modules/webaudio/DelayNode.cpp: Copied from Source/WebCore/webaudio/DelayNode.cpp.
3316         * Modules/webaudio/DelayNode.h: Copied from Source/WebCore/webaudio/DelayNode.h.
3317         * Modules/webaudio/DelayNode.idl: Copied from Source/WebCore/webaudio/DelayNode.idl.
3318         * Modules/webaudio/DelayProcessor.cpp: Copied from Source/WebCore/webaudio/DelayProcessor.cpp.
3319         * Modules/webaudio/DelayProcessor.h: Copied from Source/WebCore/webaudio/DelayProcessor.h.
3320         * Modules/webaudio/DynamicsCompressorNode.cpp: Copied from Source/WebCore/webaudio/DynamicsCompressorNode.cpp.
3321         * Modules/webaudio/DynamicsCompressorNode.h: Copied from Source/WebCore/webaudio/DynamicsCompressorNode.h.
3322         * Modules/webaudio/DynamicsCompressorNode.idl: Copied from Source/WebCore/webaudio/DynamicsCompressorNode.idl.
3323         * Modules/webaudio/HighPass2FilterNode.cpp: Copied from Source/WebCore/webaudio/HighPass2FilterNode.cpp.
3324         * Modules/webaudio/HighPass2FilterNode.h: Copied from Source/WebCore/webaudio/HighPass2FilterNode.h.
3325         * Modules/webaudio/HighPass2FilterNode.idl: Copied from Source/WebCore/webaudio/HighPass2FilterNode.idl.
3326         * Modules/webaudio/JavaScriptAudioNode.cpp: Copied from Source/WebCore/webaudio/JavaScriptAudioNode.cpp.
3327         * Modules/webaudio/JavaScriptAudioNode.h: Copied from Source/WebCore/webaudio/JavaScriptAudioNode.h.
3328         * Modules/webaudio/JavaScriptAudioNode.idl: Copied from Source/WebCore/webaudio/JavaScriptAudioNode.idl.
3329         * Modules/webaudio/LowPass2FilterNode.cpp: Copied from Source/WebCore/webaudio/LowPass2FilterNode.cpp.
3330         * Modules/webaudio/LowPass2FilterNode.h: Copied from Source/WebCore/webaudio/LowPass2FilterNode.h.
3331         * Modules/webaudio/LowPass2FilterNode.idl: Copied from Source/WebCore/webaudio/LowPass2FilterNode.idl.
3332         * Modules/webaudio/MediaElementAudioSourceNode.cpp: Copied from Source/WebCore/webaudio/MediaElementAudioSourceNode.cpp.
3333         * Modules/webaudio/MediaElementAudioSourceNode.h: Copied from Source/WebCore/webaudio/MediaElementAudioSourceNode.h.
3334         * Modules/webaudio/MediaElementAudioSourceNode.idl: Copied from Source/WebCore/webaudio/MediaElementAudioSourceNode.idl.
3335         * Modules/webaudio/OfflineAudioCompletionEvent.cpp: Copied from Source/WebCore/webaudio/OfflineAudioCompletionEvent.cpp.
3336         * Modules/webaudio/OfflineAudioCompletionEvent.h: Copied from Source/WebCore/webaudio/OfflineAudioCompletionEvent.h.
3337         * Modules/webaudio/OfflineAudioCompletionEvent.idl: Copied from Source/WebCore/webaudio/OfflineAudioCompletionEvent.idl.
3338         * Modules/webaudio/OfflineAudioDestinationNode.cpp: Copied from Source/WebCore/webaudio/OfflineAudioDestinationNode.cpp.
3339         * Modules/webaudio/OfflineAudioDestinationNode.h: Copied from Source/WebCore/webaudio/OfflineAudioDestinationNode.h.
3340         * Modules/webaudio/RealtimeAnalyser.cpp: Copied from Source/WebCore/webaudio/RealtimeAnalyser.cpp.
3341         * Modules/webaudio/RealtimeAnalyser.h: Copied from Source/WebCore/webaudio/RealtimeAnalyser.h.
3342         * Modules/webaudio/RealtimeAnalyserNode.cpp: Copied from Source/WebCore/webaudio/RealtimeAnalyserNode.cpp.
3343         * Modules/webaudio/RealtimeAnalyserNode.h: Copied from Source/WebCore/webaudio/RealtimeAnalyserNode.h.
3344         * Modules/webaudio/RealtimeAnalyserNode.idl: Copied from Source/WebCore/webaudio/RealtimeAnalyserNode.idl.
3345         * Modules/webaudio/WaveShaperDSPKernel.cpp: Copied from Source/WebCore/webaudio/WaveShaperDSPKernel.cpp.
3346         * Modules/webaudio/WaveShaperDSPKernel.h: Copied from Source/WebCore/webaudio/WaveShaperDSPKernel.h.
3347         * Modules/webaudio/WaveShaperNode.cpp: Copied from Source/WebCore/webaudio/WaveShaperNode.cpp.
3348         * Modules/webaudio/WaveShaperNode.h: Copied from Source/WebCore/webaudio/WaveShaperNode.h.
3349         * Modules/webaudio/WaveShaperNode.idl: Copied from Source/WebCore/webaudio/WaveShaperNode.idl.
3350         * Modules/webaudio/WaveShaperProcessor.cpp: Copied from Source/WebCore/webaudio/WaveShaperProcessor.cpp.
3351         * Modules/webaudio/WaveShaperProcessor.h: Copied from Source/WebCore/webaudio/WaveShaperProcessor.h.
3352         * WebCore.gyp/WebCore.gyp:
3353         * WebCore.gypi:
3354         * WebCore.pri:
3355         * WebCore.xcodeproj/project.pbxproj:
3356         * webaudio/AsyncAudioDecoder.cpp: Removed.
3357         * webaudio/AsyncAudioDecoder.h: Removed.
3358         * webaudio/AudioBasicProcessorNode.cpp: Removed.
3359         * webaudio/AudioBasicProcessorNode.h: Removed.
3360         * webaudio/AudioBuffer.cpp: Removed.
3361         * webaudio/AudioBuffer.h: Removed.
3362         * webaudio/AudioBuffer.idl: Removed.
3363         * webaudio/AudioBufferCallback.h: Removed.
3364         * webaudio/AudioBufferCallback.idl: Removed.
3365         * webaudio/AudioBufferSourceNode.cpp: Removed.
3366         * webaudio/AudioBufferSourceNode.h: Removed.
3367         * webaudio/AudioBufferSourceNode.idl: Removed.
3368         * webaudio/AudioChannelMerger.cpp: Removed.
3369         * webaudio/AudioChannelMerger.h: Removed.
3370         * webaudio/AudioChannelMerger.idl: Removed.
3371         * webaudio/AudioChannelSplitter.cpp: Removed.
3372         * webaudio/AudioChannelSplitter.h: Removed.
3373         * webaudio/AudioChannelSplitter.idl: Removed.
3374         * webaudio/AudioContext.cpp: Removed.
3375         * webaudio/AudioContext.h: Removed.
3376         * webaudio/AudioContext.idl: Removed.
3377         * webaudio/AudioDestinationNode.cpp: Removed.
3378         * webaudio/AudioDestinationNode.h: Removed.
3379         * webaudio/AudioDestinationNode.idl: Removed.
3380         * webaudio/AudioGain.h: Removed.
3381         * webaudio/AudioGain.idl: Removed.
3382         * webaudio/AudioGainNode.cpp: Removed.
3383         * webaudio/AudioGainNode.h: Removed.
3384         * webaudio/AudioGainNode.idl: Removed.
3385         * webaudio/AudioListener.cpp: Removed.
3386         * webaudio/AudioListener.h: Removed.
3387         * webaudio/AudioListener.idl: Removed.
3388         * webaudio/AudioNode.cpp: Removed.
3389         * webaudio/AudioNode.h: Removed.
3390         * webaudio/AudioNode.idl: Removed.
3391         * webaudio/AudioNodeInput.cpp: Removed.
3392         * webaudio/AudioNodeInput.h: Removed.
3393         * webaudio/AudioNodeOutput.cpp: Removed.
3394         * webaudio/AudioNodeOutput.h: Removed.
3395         * webaudio/AudioPannerNode.cpp: Removed.
3396         * webaudio/AudioPannerNode.h: Removed.
3397         * webaudio/AudioPannerNode.idl: Removed.
3398         * webaudio/AudioParam.cpp: Removed.
3399         * webaudio/AudioParam.h: Removed.
3400         * webaudio/AudioParam.idl: Removed.
3401         * webaudio/AudioParamTimeline.cpp: Removed.
3402         * webaudio/AudioParamTimeline.h: Removed.
3403         * webaudio/AudioProcessingEvent.cpp: Removed.
3404         * webaudio/AudioProcessingEvent.h: Removed.
3405         * webaudio/AudioProcessingEvent.idl: Removed.
3406         * webaudio/AudioSourceNode.h: Removed.
3407         * webaudio/AudioSourceNode.idl: Removed.
3408         * webaudio/BiquadDSPKernel.cpp: Removed.
3409         * webaudio/BiquadDSPKernel.h: Removed.
3410         * webaudio/BiquadFilterNode.cpp: Removed.
3411         * webaudio/BiquadFilterNode.h: Removed.
3412         * webaudio/BiquadFilterNode.idl: Removed.
3413         * webaudio/BiquadProcessor.cpp: Removed.
3414         * webaudio/BiquadProcessor.h: Removed.
3415         * webaudio/ConvolverNode.cpp: Removed.
3416         * webaudio/ConvolverNode.h: Removed.
3417         * webaudio/ConvolverNode.idl: Removed.
3418         * webaudio/DOMWindowWebAudio.idl: Removed.
3419         * webaudio/DefaultAudioDestinationNode.cpp: Removed.
3420         * webaudio/DefaultAudioDestinationNode.h: Removed.
3421         * webaudio/DelayDSPKernel.cpp: Removed.
3422         * webaudio/DelayDSPKernel.h: Removed.
3423         * webaudio/DelayNode.cpp: Removed.
3424         * webaudio/DelayNode.h: Removed.
3425         * webaudio/DelayNode.idl: Removed.
3426         * webaudio/DelayProcessor.cpp: Removed.
3427         * webaudio/DelayProcessor.h: Removed.
3428         * webaudio/DynamicsCompressorNode.cpp: Removed.
3429         * webaudio/DynamicsCompressorNode.h: Removed.
3430         * webaudio/DynamicsCompressorNode.idl: Removed.
3431         * webaudio/HighPass2FilterNode.cpp: Removed.
3432         * webaudio/HighPass2FilterNode.h: Removed.
3433         * webaudio/HighPass2FilterNode.idl: Removed.
3434         * webaudio/JavaScriptAudioNode.cpp: Removed.
3435         * webaudio/JavaScriptAudioNode.h: Removed.
3436         * webaudio/JavaScriptAudioNode.idl: Removed.
3437         * webaudio/LowPass2FilterNode.cpp: Removed.
3438         * webaudio/LowPass2FilterNode.h: Removed.
3439         * webaudio/LowPass2FilterNode.idl: Removed.
3440         * webaudio/MediaElementAudioSourceNode.cpp: Removed.
3441         * webaudio/MediaElementAudioSourceNode.h: Removed.
3442         * webaudio/MediaElementAudioSourceNode.idl: Removed.
3443         * webaudio/OfflineAudioCompletionEvent.cpp: Removed.
3444         * webaudio/OfflineAudioCompletionEvent.h: Removed.
3445         * webaudio/OfflineAudioCompletionEvent.idl: Removed.
3446         * webaudio/OfflineAudioDestinationNode.cpp: Removed.
3447         * webaudio/OfflineAudioDestinationNode.h: Removed.
3448         * webaudio/RealtimeAnalyser.cpp: Removed.
3449         * webaudio/RealtimeAnalyser.h: Removed.
3450         * webaudio/RealtimeAnalyserNode.cpp: Removed.
3451         * webaudio/RealtimeAnalyserNode.h: Removed.
3452         * webaudio/RealtimeAnalyserNode.idl: Removed.
3453         * webaudio/WaveShaperDSPKernel.cpp: Removed.
3454         * webaudio/WaveShaperDSPKernel.h: Removed.
3455         * webaudio/WaveShaperNode.cpp: Removed.
3456         * webaudio/WaveShaperNode.h: Removed.
3457         * webaudio/WaveShaperNode.idl: Removed.
3458         * webaudio/WaveShaperProcessor.cpp: Removed.
3459         * webaudio/WaveShaperProcessor.h: Removed.
3460
3461 2012-03-20  Anders Carlsson  <andersca@apple.com>
3462
3463         Add a per-ScrollableArea tile cache base class
3464         https://bugs.webkit.org/show_bug.cgi?id=81694
3465
3466         Reviewed by Sam Weinig.
3467
3468         Add an abstract base class, TiledBacking, that can be used to inform tile caches about changed
3469         state in scrollable areas (such as the currently visible rect, whether the page is active or not, etc).
3470
3471         Make TileCache inherit from TiledBacking and port updating the visible rect over to this new mechanism.
3472
3473         * WebCore.xcodeproj/project.pbxproj:
3474         * page/FrameView.cpp:
3475         (WebCore::FrameView::tiledBacking):
3476         (WebCore):
3477         * page/FrameView.h:
3478         (FrameView):
3479         * platform/ScrollableArea.h:
3480         (WebCore):
3481         (ScrollableArea):
3482         (WebCore::ScrollableArea::tiledBacking):
3483         * platform/graphics/GraphicsLayer.h:
3484         (WebCore):
3485         (WebCore::GraphicsLayer::tiledBacking):
3486         * platform/graphics/TiledBacking.h: Added.
3487         (WebCore):
3488         (TiledBacking):
3489         (WebCore::TiledBacking::~TiledBacking):
3490         * platform/graphics/ca/GraphicsLayerCA.cpp:
3491         (WebCore::GraphicsLayerCA::tiledBacking):
3492         * platform/graphics/ca/GraphicsLayerCA.h:
3493         (GraphicsLayerCA):
3494         * platform/graphics/ca/PlatformCALayer.h:
3495         (PlatformCALayer):
3496         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
3497         (PlatformCALayer::tiledBacking):
3498         * platform/graphics/ca/mac/TileCache.h:
3499         (TileCache):
3500         * platform/graphics/ca/mac/WebTileCacheLayer.h:
3501         (WebCore):
3502         * platform/graphics/ca/mac/WebTileCacheLayer.mm:
3503         (-[WebTileCacheLayer WebCore::]):
3504         * platform/graphics/ca/win/PlatformCALayerWin.cpp:
3505         (PlatformCALayer::tiledBacking):
3506         * rendering/RenderLayerCompositor.cpp:
3507         (WebCore::RenderLayerCompositor::frameViewDidScroll):
3508
3509 2012-03-20  Xiaomei Ji  <xji@chromium.org>
3510
3511         visual word movement: crashes on CSS generated content.
3512         https://bugs.webkit.org/show_bug.cgi?id=81581
3513
3514         Reviewed by Ryosuke Niwa.
3515
3516         Check for null pointer when referencing box->renderer()->node() in previousRootInlineBox and nextRootInlineBox.
3517
3518         Test: editing/selection/move-by-word-visually-crash-test-css-generated-content.html
3519
3520         * editing/visible_units.cpp:
3521         (WebCore::previousRootInlineBox):
3522         (WebCore::nextRootInlineBox):
3523
3524 2012-03-20  Luke Macpherson  <macpherson@chromium.org>
3525
3526         Use CSSPrimitiveValue::convertToLength() to handle CSSPropertyWebkitBoxReflect and in createGridTrackBreadth.
3527         https://bugs.webkit.org/show_bug.cgi?id=81633
3528
3529         Reviewed by Andreas Kling.
3530
3531         No new tests / refactoring only.
3532
3533         * css/CSSStyleSelector.cpp:
3534         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
3535
3536 2012-03-20  Sheriff Bot  <webkit.review.bot@gmail.com>
3537
3538         Unreviewed, rolling out r111442.
3539         http://trac.webkit.org/changeset/111442
3540         https://bugs.webkit.org/show_bug.cgi?id=81711
3541
3542         Causes crashes and image mismatches in canvas tests (Requested
3543         by leviw on #webkit).
3544
3545         * html/HTMLCanvasElement.cpp:
3546         (WebCore::HTMLCanvasElement::HTMLCanvasElement):
3547         (WebCore::HTMLCanvasElement::reset):
3548         (WebCore::HTMLCanvasElement::createImageBuffer):
3549         (WebCore::HTMLCanvasElement::clearCopiedImage):
3550         * html/HTMLCanvasElement.h:
3551         (HTMLCanvasElement):
3552         * html/canvas/CanvasRenderingContext2D.cpp:
3553         (WebCore::CanvasRenderingContext2D::CanvasRenderingContext2D):
3554         (WebCore::CanvasRenderingContext2D::unwindStateStack):
3555         (WebCore::CanvasRenderingContext2D::reset):
3556
3557 2012-03-20  Adrienne Walker  <enne@google.com>
3558
3559         RenderLayerCompositor doesn't properly clip graphics layer sizes
3560         https://bugs.webkit.org/show_bug.cgi?id=80372
3561
3562         Reviewed by Simon Fraser.
3563
3564         To find the bounds for a composited layer, calculateCompositedBounds
3565         iterates through all non-composited child layers using z-order and
3566         normal flow lists. This does not preserve clipping from ancestor
3567         layers, because a clipping ancestor layer can end up as a sibling to
3568         its clipped descendent because it is not a stacking context.
3569
3570         Fix by explicitly checking cached clip roots.
3571
3572         Test: compositing/clip-child-by-non-stacking-ancestor.html
3573
3574         * rendering/RenderLayer.cpp:
3575         (WebCore::RenderLayer::localClipRect):
3576         (WebCore):
3577         * rendering/RenderLayer.h:
3578         (RenderLayer):
3579         * rendering/RenderLayerCompositor.cpp:
3580         (WebCore::RenderLayerCompositor::repaintOnCompositingChange):
3581         (WebCore::RenderLayerCompositor::calculateCompositedBounds):
3582
3583 2012-03-20  Sheriff Bot  <webkit.review.bot@gmail.com>
3584
3585         Unreviewed, rolling out r111445 and r111446.
3586         http://trac.webkit.org/changeset/111445
3587         http://trac.webkit.org/changeset/111446
3588         https://bugs.webkit.org/show_bug.cgi?id=81708
3589
3590         It broke Qt and GTK build intentionally (Requested by Ossy on
3591         #webkit).
3592
3593         * WebCore.exp.in:
3594         * dom/Document.cpp:
3595         (WebCore::Document::initSecurityContext):
3596         * notifications/Notification.cpp:
3597         (WebCore::Notification::Notification):
3598         * notifications/NotificationCenter.cpp:
3599         (WebCore::NotificationCenter::checkPermission):
3600         (WebCore::NotificationCenter::requestPermission):
3601         * notifications/NotificationCenter.h:
3602         (NotificationCenter):
3603         * page/SecurityOrigin.cpp:
3604         (WebCore::SecurityOrigin::toString):
3605         * page/SecurityOrigin.h:
3606         (SecurityOrigin):
3607
3608 2012-03-20  Adam Klein  <adamk@chromium.org>
3609
3610         Refactor ContainerNode::replaceChild to match other mutation methods and share code
3611         https://bugs.webkit.org/show_bug.cgi?id=81579
3612
3613         Reviewed by Ojan Vafai.
3614
3615         Originally landed as r111310, this fixes a bug in replaceChild
3616         introduced when switching to the insert-before logic.
3617
3618         A future change will make use of the consistency among insertBefore/appendChild/replaceChild
3619         to handle insertion of DocumentFragments more cleanly.
3620
3621         No new tests, no change in behavior.
3622
3623         * dom/ContainerNode.cpp:
3624         (WebCore::ContainerNode::replaceChild): Use collectTargetNodes rather than walking through DocumentFragment children.
3625         Insert before rather than inserting after. Dispatch to other methods to update parent/sibling pointers.
3626         (WebCore::ContainerNode::appendChild): Call appendChildToContainer to update parent/sibling pointers.
3627         (WebCore::ContainerNode::parserAddChild): Use type inference in call to appendChildToContainer.
3628
3629 2012-03-20  Jon Lee  <jonlee@apple.com>
3630
3631         Restrict access to notifications for unique origins and file URLs with no local file access
3632         https://bugs.webkit.org/show_bug.cgi?id=79704
3633         <rdar://problem/10912430>
3634
3635         Reviewed by Adam Barth.
3636
3637         Before checking or requesting permissions, we look at whether we can show notifications based on
3638         the security context. If not, we short circuit and do not forward the request to the client.
3639
3640         * notifications/Notification.cpp:
3641         (WebCore::Notification::Notification): Fix a bug where creating a notification goes through slightly
3642         different logic for checking permissions than when checking permissions through the
3643         notification center.
3644         * notifications/NotificationCenter.cpp:
3645         (WebCore::NotificationCenter::checkPermission): Check to see if the origin can show notifications.
3646         (WebCore::NotificationCenter::requestPermission): If we know whether an origin can show notifications,
3647         we asynchronously call the callback with that decision. Otherwise we ask the client.
3648
3649         Add new variable in the notification center to keep track of pending callbacks when we short-circuit
3650         requestPermission().
3651         * notifications/NotificationCenter.h:
3652         (NotificationRequestCallback): Add new private class encapsulating the callback.
3653         * notifications/NotificationCenter.cpp:
3654         (WebCore::NotificationCenter::requestTimedOut): Remove the request from the set of pending callbacks.
3655         (WebCore::NotificationCenter::NotificationRequest::createAndStartTimer): Because this is used when we already
3656         know the decision, and are not asking the client to decide, we can immediately trigger a one-shot timer
3657         to invoke the callback.
3658         (WebCore::NotificationCenter::NotificationRequest::NotificationRequest):
3659         (WebCore::NotificationCenter::NotificationRequest::startTimer):
3660         (WebCore::NotificationCenter::NotificationRequest::timerFired): Invoke the callback and tell the notification
3661         center.
3662         * page/SecurityOrigin.h: Add new toRawString() method to return the string representation of the origin,
3663         regardless of any restrictions that might otherwise cause toString() to return "null".
3664         * page/SecurityOrigin.cpp:
3665         (WebCore::SecurityOrigin::canShowNotifications): Added to return a tri-state regarding whether we know
3666         the origin can show notifications. If the origin is unique, we never let it show. If the origin has
3667         universal access, we always let it show. Otherwise the client should be asked.
3668         (WebCore::SecurityOrigin::toString): Refactor to use toRawString().
3669         (WebCore::SecurityOrigin::toRawString):
3670
3671         Added FIXME's regarding the naming of enforceFilePathSeparation().
3672         * dom/Document.cpp:
3673         (WebCore::Document::initSecurityContext): Also, tab reformatting.
3674
3675         * WebCore.exp.in: Export toRawString().
3676
3677 2012-03-20  Andreas Kling  <kling@webkit.org>
3678
3679         Remove unused CSSPrimitiveValue constructors.
3680         <http://webkit.org/b/81695>
3681
3682         Reviewed by Antti Koivisto.
3683
3684         Kill off CSSPrimitiveValue constructors that aren't used anywhere.
3685
3686         * css/CSSPrimitiveValue.cpp:
3687         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
3688         * css/CSSPrimitiveValue.h:
3689         (CSSPrimitiveValueBase):
3690         (WebCore::CSSPrimitiveValueBase::CSSPrimitiveValueBase):
3691         (CSSPrimitiveValue):
3692         * css/CSSPrimitiveValueMappings.h:
3693
3694 2012-03-20  Sami Kyostila  <skyostil@chromium.org>
3695
3696         Reuse buffer allocation if canvas size does not change
3697         https://bugs.webkit.org/show_bug.cgi?id=80871
3698
3699         Reviewed by Stephen White.
3700
3701         If the user changes the width or height attributes of a canvas element,
3702         the contents of the canvas should be cleared and the context state
3703         should be reset. This has become a common idiom to clear the canvas
3704         "efficiently" at the start of a frame.
3705
3706         Previously, this code path triggered a full reallocation of the image
3707         buffer backing the canvas, leading to reduced performance. This patch
3708         implements an optimization where we reuse the previous image buffer
3709         allocation if the size of the canvas did not change. Also, instead of
3710         clearing the canvas every time its dimensions are touched, we only clear
3711         if anything has been drawn into the canvas since it was previously
3712         cleared.
3713
3714         Note that for now this optimization only applies for 2D canvases,
3715         since it is not entirely clear how touching the dimensions of a WebGL
3716         canvas should work.
3717
3718         Test: fast/canvas/canvas-resize-after-paint-without-layout.html +
3719               existing layout tests for canvas resetting.
3720
3721         * html/HTMLCanvasElement.cpp:
3722         (WebCore::HTMLCanvasElement::HTMLCanvasElement):
3723         (WebCore::HTMLCanvasElement::reset):
3724         (WebCore::HTMLCanvasElement::createImageBuffer):
3725         (WebCore::HTMLCanvasElement::clearImageBuffer):
3726         (WebCore):
3727         (WebCore::HTMLCanvasElement::clearCopiedImage):
3728         * html/HTMLCanvasElement.h:
3729         (HTMLCanvasElement):
3730         * html/canvas/CanvasRenderingContext2D.cpp:
3731         (WebCore::CanvasRenderingContext2D::CanvasRenderingContext2D): Save the
3732         initial graphics context state so we can restore it without creating a
3733         new context.
3734         (WebCore::CanvasRenderingContext2D::unwindStateStack):
3735         (WebCore::CanvasRenderingContext2D::reset): No need to notify the
3736         compositor when the context is reset, because clearing the image buffer
3737         does the same thing. We can also skip the notification if we did not
3738         have an image buffer at the time of the reset, because the reset will
3739         not have any visual impact in this case. Finally, if the canvas size
3740         did change, the notification is also unnecessary because of the call
3741         to RenderObject::repaint() from HTMLCanvasElement::reset().
3742
3743 2012-03-20  Dana Jansens  <danakj@chromium.org>
3744
3745         [chromium] Allow us to disable overdraw metrics when tracing is off
3746         https://bugs.webkit.org/show_bug.cgi?id=81431
3747
3748         Reviewed by Adrienne Walker.
3749
3750         This change allows us to disable overdraw metrics conditionally in the
3751         future with a one-line change in each LayerTreeHost class.
3752
3753         Unit test: CCQuadCullerTest.verifyWithoutMetrics
3754
3755         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
3756         (WebCore::CCLayerTreeHost::paintLayerContents):
3757         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
3758         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
3759         * platform/graphics/chromium/cc/CCOcclusionTracker.cpp:
3760         (WebCore::::CCOcclusionTrackerBase):
3761         (WebCore):
3762         * platform/graphics/chromium/cc/CCOcclusionTracker.h:
3763         (CCOcclusionTrackerBase):
3764         * platform/graphics/chromium/cc/CCOverdrawMetrics.cpp:
3765         (WebCore::CCOverdrawMetrics::CCOverdrawMetrics):
3766         (WebCore::CCOverdrawMetrics::didCull):
3767         (WebCore::CCOverdrawMetrics::didDraw):
3768         (WebCore::CCOverdrawMetrics::recordMetrics):
3769         * platform/graphics/chromium/cc/CCOverdrawMetrics.h:
3770         (WebCore::CCOverdrawMetrics::create):
3771         (CCOverdrawMetrics):
3772
3773 2012-03-20  Robert Hogan  <robert@webkit.org>
3774
3775         Use-after-free of continuation in RenderBlock::paintContinuationOutlines()
3776         https://bugs.webkit.org/show_bug.cgi?id=81276
3777
3778         Reviewed by David Hyatt.
3779
3780         Test: fast/css/relative-positioned-block-crash.html
3781
3782         https://trac.webkit.org/changeset/108185/ allowed anonymous blocks to get their own layer (when they're
3783         relatively positioned). This broke the dependency in addContinuationWithOutline() on the owner of the continuation
3784         table and the renderer getting added to it always being in the same layer. When they're not in the same layer
3785         there's no guarantee that the owner of the continuation table will get painted again and so avoid any stale pointers
3786         in its continuation table should any of the renderers in there get destroyed.
3787
3788         Fix this for now by only adding renderers to the containing block's continuation table if we don't have our own layer.
3789         This fix causes fast/inline/continuation-outlines-with-layers.html to regress as it uses blocks inside relatively positioned
3790         inlines, so skip it on all platforms pending a medium-term fix.
3791
3792         * rendering/RenderBlock.cpp:
3793         (WebCore::RenderBlock::paintObject):
3794
3795 2012-03-20  Adele Peterson  <adele@apple.com>
3796
3797         "Attempt to insert nil value " exception when calling attributed string APIs on content with a custom font
3798         https://bugs.webkit.org/show_bug.cgi?id=81630
3799         <rdar://problem/10650660> 
3800
3801         Reviewed by Alexey Proskuryakov. 
3802
3803         Test: TestWebKitAPI/Tests/mac/AttributedString.mm 
3804
3805         If content is using a custom font, then the platform font will be nil and needs to be nil checked.
3806
3807         * platform/mac/HTMLConverter.mm: (+[WebHTMLConverter editingAttributedStringFromRange:]):
3808
3809 2012-03-20  Julien Chaffraix  <jchaffraix@webkit.org>
3810
3811         Make distributeExtraLogicalHeightToRows return the consumed logical height
3812         https://bugs.webkit.org/show_bug.cgi?id=81678
3813
3814         Reviewed by Tony Chang.
3815
3816         Small refactoring, no change in behavior.
3817
3818         * rendering/RenderTable.cpp:
3819         (WebCore::RenderTable::distributeExtraLogicalHeight):
3820         Remove the consumed logical height from the available height.
3821
3822         * rendering/RenderTableSection.cpp:
3823         (WebCore::RenderTableSection::distributeExtraLogicalHeightToPercentRows):
3824         (WebCore::RenderTableSection::distributeExtraLogicalHeightToAutoRows):
3825         (WebCore::RenderTableSection::distributeRemainingExtraLogicalHeight):
3826         Changed those method to not return anything but remove from the available width.
3827
3828         (WebCore::RenderTableSection::distributeExtraLogicalHeightToRows):
3829         Return the consumed logical height.
3830
3831         * rendering/RenderTableSection.h:
3832         Updated the previous distribute functions signature and the comment about
3833         the returned value from distributeExtraLogicalHeightToRows.
3834
3835 2012-03-20  Jacky Jiang  <zhajiang@rim.com>
3836
3837         [BlackBerry] Dijit crash WebCore::CookieManager::getRawCookies
3838         https://bugs.webkit.org/show_bug.cgi?id=81686
3839
3840         Reviewed by Rob Buis.
3841
3842         HTML plugin element with an empty src caused an ASSERT failure on debug
3843         build and a crash on release build.
3844         When getting cookie, url can be null, so we need to check for it to
3845         avoid the crash.
3846
3847         No new tests as this is covered by
3848         LayoutTests/fast/loader/empty-embed-src-attribute.html.
3849
3850         * platform/network/blackberry/ResourceRequestBlackBerry.cpp:
3851         (WebCore::ResourceRequest::initializePlatformRequest):
3852
3853 2012-03-20  Vsevolod Vlasov  <vsevik@chromium.org>
3854
3855         Web Inspector: Tabbed pane drop down should be sorted.
3856         https://bugs.webkit.org/show_bug.cgi?id=81680
3857
3858         Reviewed by Pavel Feldman.
3859
3860         * inspector/front-end/TabbedPane.js:
3861         (WebInspector.TabbedPane.prototype._populateDropDownFromIndex.compareFunction):
3862         (WebInspector.TabbedPane.prototype._populateDropDownFromIndex):
3863
3864 2012-03-20  Vsevolod Vlasov  <vsevik@chromium.org>
3865
3866         Web Inspector: Open resource dialog scripts list should be sorted.
3867         https://bugs.webkit.org/show_bug.cgi?id=81682
3868
3869         Reviewed by Pavel Feldman.
3870
3871         * inspector/front-end/FilteredItemSelectionDialog.js:
3872         (WebInspector.OpenResourceDialog.compareFunction):
3873         (WebInspector.OpenResourceDialog):
3874
3875 2012-03-20  Dana Jansens  <danakj@chromium.org>
3876
3877         [chromium] Use opaque contents for paint culling
3878         https://bugs.webkit.org/show_bug.cgi?id=81676
3879
3880         Reviewed by Adrienne Walker.
3881
3882         UnitTest: CCLayerTreeHostTestContentLayerOcclusion
3883
3884         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
3885         (WebCore::CCLayerTreeHost::paintLayerContents):
3886
3887 2012-03-20  Dan Bernstein  <mitz@apple.com>
3888
3889         Build fix after r111419.
3890
3891         * dom/WebKitNamedFlow.cpp:
3892         * dom/WebKitNamedFlow.h:
3893
3894 2012-03-20  Dan Bernstein  <mitz@apple.com>
3895
3896         REGRESSION (r111229): css1/basic/inheritance.html is failing
3897         https://bugs.webkit.org/show_bug.cgi?id=81684
3898
3899         Reverted r111229.
3900
3901         Rubber-stamped by Dave Hyatt.
3902
3903         * dom/Document.cpp:
3904         (WebCore::Document::webkitGetFlowByName):
3905         * dom/Document.h:
3906         (Document):
3907         * dom/Element.cpp:
3908         (WebCore::Element::detach):
3909         * dom/NodeRenderingContext.cpp:
3910         (WebCore::NodeRenderingContext::moveToFlowThreadIfNeeded):
3911         * dom/WebKitNamedFlow.cpp:
3912         (WebCore):
3913         * dom/WebKitNamedFlow.h:
3914         (WebCore):
3915         (WebKitNamedFlow):
3916         * dom/WebKitNamedFlow.idl:
3917
3918 2012-03-20  Vineet Chaudhary  <rgf748@motorola.com>
3919
3920         https://bugs.webkit.org/show_bug.cgi?id=80696
3921         Remove custom bindings for attribute type Array.
3922
3923         Reviewed by Kentaro Hara.
3924
3925         No new tests.
3926
3927         * bindings/js/JSConsoleCustom.cpp: Removed custom function.
3928         (WebCore):
3929         * bindings/js/JSDOMBinding.h: Added template jsArray and toNativeArray.
3930         (WebCore):
3931         (WebCore::jsArray):
3932         (WebCore::toNativeArray):
3933         * bindings/scripts/CodeGenerator.pm: Modified codegenerators to generate appropriate code.
3934         (GetArrayType): Added GetArrayType to get return type of attribute interface.
3935         * bindings/scripts/CodeGeneratorGObject.pm: Modified codegenerators to generate appropriate code.
3936         (SkipAttribute):
3937         * bindings/scripts/CodeGeneratorJS.pm: Modified codegenerators to generate appropriate code.
3938         (AddIncludesForType):
3939         (JSValueToNative):
3940         (NativeToJSValue):
3941         * bindings/scripts/CodeGeneratorV8.pm: Modified codegenerators to generate appropriate code.
3942         (GenerateNormalAttrGetter):
3943         (GenerateNormalAttrSetter):
3944         (JSValueToNative):
3945         (NativeToJSValue):
3946         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp: Updated results from running binding tests.
3947         (webkit_dom_test_obj_get_property):
3948         (webkit_dom_test_obj_class_init):
3949         * bindings/scripts/test/GObject/WebKitDOMTestObj.h: Ditto.
3950         * bindings/scripts/test/JS/JSTestObj.cpp: Ditto.
3951         (WebCore::jsTestObjSequenceAttr):
3952         (WebCore::setJSTestObjSequenceAttr):
3953         (WebCore::jsTestObjPrototypeFunctionMethodReturningSequence):
3954         * bindings/scripts/test/V8/V8TestObj.cpp: Ditto.
3955         (WebCore::TestObjInternal::sequenceAttrAttrGetter):
3956         (WebCore::TestObjInternal::sequenceAttrAttrSetter):
3957         (WebCore::TestObjInternal::methodReturningSequenceCallback):
3958         * bindings/v8/V8Binding.h: Added template v8Array and toNativeArray.
3959         (WebCore):
3960         (WebCore::v8Array):
3961         (WebCore::toNativeArray):
3962         * bindings/v8/custom/V8ConsoleCustom.cpp: Removed custom function.
3963         (WebCore):
3964         * page/Console.idl: Replaced attribute type Array to sequence<SriptProfile> to remove
3965           custom bindings.
3966
3967 2012-03-20  Sheriff Bot  <webkit.review.bot@gmail.com>
3968
3969         Unreviewed, rolling out r111310.
3970         http://trac.webkit.org/changeset/111310
3971         https://bugs.webkit.org/show_bug.cgi?id=81683
3972
3973         Broke layout test
3974         dom/xhtml/level3/core/nodereplacechild30.xhtml (Requested by
3975         aklein on #webkit).
3976
3977         * dom/ContainerNode.cpp:
3978         (WebCore::ContainerNode::replaceChild):
3979         (WebCore::ContainerNode::appendChild):
3980         (WebCore::ContainerNode::parserAddChild):
3981
3982 2012-03-20  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
3983
3984         Convert hasSpellingMarker to use Internals interface.
3985         https://bugs.webkit.org/show_bug.cgi?id=81300
3986
3987         Reviewed by Ryosuke Niwa.
3988
3989         Remove hasSpellingMarker functions, because it is able to work in the
3990         cross-port way through the Internals interface.
3991
3992         No new tests, since we are improving here the infra-structure
3993         for testing a specific method.
3994
3995         * testing/Internals.cpp:
3996         (WebCore::Internals::hasSpellingMarker):
3997         (WebCore):
3998         * testing/Internals.h:
3999         (Internals):
4000         * testing/Internals.idl:
4001
4002 2012-03-20  Dan Bernstein  <mitz@apple.com>
4003
4004         Build fix.
4005
4006         * history/PageCache.cpp: Fixed an unused function warning introduced in r111391.
4007
4008 2012-03-20  Konrad Piascik  <kpiascik@rim.com>
4009
4010         (r110063) m_mouseDownMayStartDrag is used without being behind the ENABLE(DRAG_SUPPORT) macro
4011         https://bugs.webkit.org/show_bug.cgi?id=81666
4012
4013         Reviewed by Rob Buis.
4014
4015         Compiled with feature disabled and built.