https://bugs.webkit.org/show_bug.cgi?id=81617 fast/repaint/canvas-putImageData.html...
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2012-03-19  Anders Carlsson  <andersca@apple.com>
2
3         Fix Snow Leopard build.
4
5         * platform/graphics/ca/mac/TileCache.mm:
6         (WebCore::TileCache::createTileLayer):
7
8 2012-03-19  Michal Mocny  <mmocny@google.com>
9
10         [chromium] Adding support for GL_EXT_discard_framebuffer.
11         https://bugs.webkit.org/show_bug.cgi?id=81383
12
13         Reviewed by James Robinson.
14
15         * platform/graphics/chromium/Extensions3DChromium.h:
16
17 2012-03-19  Adam Klein  <adamk@chromium.org>
18
19         Refactor ContainerNode::replaceChild to match other mutation methods and share code
20         https://bugs.webkit.org/show_bug.cgi?id=81579
21
22         Reviewed by Ojan Vafai.
23
24         A future change will make use of the consistency among insertBefore/appendChild/replaceChild
25         to handle insertion of DocumentFragments more cleanly.
26
27         No new tests, no change in behavior.
28
29         * dom/ContainerNode.cpp:
30         (WebCore::ContainerNode::replaceChild): Use collectTargetNodes rather than walking through DocumentFragment children.
31         Insert before rather than inserting after. Dispatch to other methods to update parent/sibling pointers.
32         (WebCore::ContainerNode::appendChild): Call appendChildToContainer to update parent/sibling pointers.
33         (WebCore::ContainerNode::parserAddChild): Use type inference in call to appendChildToContainer.
34
35 2012-03-19  Ian Vollick  <vollick@chromium.org>
36
37         [chromium] Times in the cc should be expressed in seconds.
38         https://bugs.webkit.org/show_bug.cgi?id=80514
39
40         Reviewed by James Robinson.
41
42         Updated timer tests to use seconds.
43
44         * platform/TouchFlingPlatformGestureCurve.h:
45         (TouchFlingPlatformGestureCurve):
46         * platform/graphics/chromium/cc/CCActiveGestureAnimation.cpp:
47         (WebCore::CCActiveGestureAnimation::animate):
48         * platform/graphics/chromium/cc/CCActiveGestureAnimation.h:
49         (CCActiveGestureAnimation):
50         * platform/graphics/chromium/cc/CCDelayBasedTimeSource.cpp:
51         (WebCore::CCDelayBasedTimeSource::create):
52         (WebCore::CCDelayBasedTimeSource::CCDelayBasedTimeSource):
53         (WebCore::CCDelayBasedTimeSource::setActive):
54         (WebCore::CCDelayBasedTimeSource::onTimerFired):
55         (WebCore::CCDelayBasedTimeSource::monotonicallyIncreasingTime):
56         (WebCore):
57         (WebCore::CCDelayBasedTimeSource::postNextTickTask):
58         * platform/graphics/chromium/cc/CCDelayBasedTimeSource.h:
59         (CCDelayBasedTimeSource):
60         * platform/graphics/chromium/cc/CCGestureCurve.h:
61         (CCGestureCurve):
62         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
63         (WTF):
64         (WebCore::CCThreadProxy::beginContextRecreation):
65         (WebCore::CCThreadProxy::tryToRecreateContext):
66         (WebCore::CCThreadProxy::initializeImplOnImplThread):
67         * platform/graphics/chromium/cc/CCTimer.cpp:
68         (WebCore::CCTimer::startOneShot):
69         * platform/graphics/chromium/cc/CCTimer.h:
70         (CCTimer):
71
72 2012-03-19  Florin Malita  <fmalita@google.com>
73
74         Relative-height block SVG root not layed out on container height change
75         https://bugs.webkit.org/show_bug.cgi?id=81513
76
77         Reviewed by Dirk Schulze.
78
79         Tests: svg/custom/svg-percent-scale-block-expected.html
80                svg/custom/svg-percent-scale-block.html
81
82         A couple of places still have style()->logical{Min,Max,}Height percent checks,
83         which do not work for SVG elements. This patch adds a virtual hasRelativeLogicalHeight()
84         RenderBox method to replace the explicit style checks.
85
86         * rendering/RenderBlock.cpp:
87         (WebCore::RenderBlock::layoutBlockChildren):
88         Use virtual hasRelativeLogicalHeight() instead of logical height style checks.
89
90         * rendering/RenderBox.cpp:
91         (WebCore::RenderBox::hasRelativeLogicalHeight):
92         (WebCore):
93         * rendering/RenderBox.h:
94         (RenderBox):
95         Add virtual hasRelativeLogicalHeight().
96
97         * rendering/RenderView.cpp:
98         (WebCore::RenderView::layout):
99         Use virtual hasRelativeLogicalHeight() instead of logical height style checks, if possible.
100
101         * rendering/svg/RenderSVGRoot.cpp:
102         (WebCore::RenderSVGRoot::hasRelativeLogicalHeight):
103         (WebCore):
104         * rendering/svg/RenderSVGRoot.h:
105         (RenderSVGRoot):
106         Add hasRelativeLogicalHeight() override.
107
108 2012-03-19  Jer Noble  <jer.noble@apple.com>
109
110         Assertion failure in RenderBlock::addChildIgnoringAnonymousColumnBlocks when running fullscreen/full-screen-twice-crash.html 
111         causing "crashes" on the Lion Intel Debug WebKit2 test bots.
112         https://bugs.webkit.org/show_bug.cgi?id=81171
113
114         Reviewed by Dan Bernstein.
115
116         No new tests; fixes fullscreen/* tests when running in WebKitTestRunner (WebKit2).
117
118         Add a special-case check if the parent anonymous container is a full screen renderer or placeholder.
119
120         * rendering/RenderBlock.cpp:
121         (WebCore::RenderBlock::addChildIgnoringAnonymousColumnBlocks):
122
123 2012-03-19  Enrica Casucci  <enrica@apple.com>
124
125         WebKit2: create sandbox extensions for files that are dropped in an input control.
126         https://bugs.webkit.org/show_bug.cgi?id=81153
127         <rdar://problem/11031207>
128
129         Reviewed by Alexey Proskuryakov.
130
131         Now the pasteboard access is performed only in the UI process, it is
132         necessary to create sandbox extensions for each file that is dropped into
133         an input type=file element. The extensions are created at the time the files
134         are dropped and consumed immediately.
135
136         * page/DragActions.h: Added new drag action to be used by the WebDragClient.
137         * page/DragController.cpp:
138         (WebCore::DragController::concludeEditDrag): Added call to the drag client with the new action.
139
140 2012-03-19  Eric Seidel  <eric@webkit.org>
141
142         Fix Chromium Win
143         https://bugs.webkit.org/show_bug.cgi?id=81281
144
145         Unreviewed build fix.
146
147         * platform/graphics/chromium/TransparencyWin.h:
148
149 2012-03-19  Eric Seidel  <eric@webkit.org>
150
151         Fix the chromium world.
152         https://bugs.webkit.org/show_bug.cgi?id=81281
153
154         Unreviewed build fix.
155
156         * rendering/RenderThemeChromiumSkia.cpp:
157
158 2012-03-19  Brady Eidson  <beidson@apple.com>
159
160         <rdar://problem/10917120> and https://bugs.webkit.org/show_bug.cgi?id=81066
161         Crash in 3rd party WebKit apps under XHR/Cache code
162
163         Reviewed by Antti Koivisto.
164
165         No new layout tests.
166         TestWebKitAPI test MemoryCachePruneWithinResourceLoadDelegate included
167
168         A CachedResource representing an XHR was being deleted by cache pruning during a delegate callback.
169         This worked until http://trac.webkit.org/changeset/98380
170
171         * history/PageCache.cpp:
172         (WebCore::PageCache::releaseAutoreleasedPagesNow): Only trigger pruning after the page cache
173           autorelease if it was enabled before.
174
175         * loader/cache/CachedResourceLoader.cpp:
176         (WebCore::CachedResourceLoader::loadResource): Disable pruning before loading the resource and
177           re-enable it afterwards if necessary.
178
179         * loader/cache/MemoryCache.h:
180         (WebCore::MemoryCache::pruneEnabled):
181
182 2012-03-19  Anders Carlsson  <andersca@apple.com>
183
184         Fix Windows build.
185
186         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
187         (WebCore::MediaPlayerPrivateQuickTimeVisualContext::LayerClient::platformCALayerDeviceScaleFactor):
188
189 2012-03-18  James Robinson  <jamesr@chromium.org>
190
191         [chromium] Implement fling-by-wheel on compositor thread
192         https://bugs.webkit.org/show_bug.cgi?id=81462
193
194         Reviewed by Adrienne Walker.
195
196         Adds compositor thread support for a fling type implemented as a sequence of wheel scrolls. Covered by new tests
197         in WebCompositorInputHandlerImplTests.
198
199         * platform/graphics/chromium/cc/CCInputHandler.h:
200         (CCInputHandler):
201         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
202         (WebCore::CCLayerTreeHostImpl::scheduleAnimation):
203         (WebCore):
204         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
205         (CCLayerTreeHostImpl):
206         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
207         (WebCore::CCThreadProxy::scheduledActionDrawAndSwap):
208
209 2012-03-19  Emil A Eklund  <eae@chromium.org>
210
211         [mac/chromium] Change platform code to use pixelSnappedRect methods
212         https://bugs.webkit.org/show_bug.cgi?id=81016
213
214         Reviewed by Eric Seidel.
215
216         Change platform code to use Node::getPixelSnappedRect,
217         pixelSnappedBoundingBoxRect and pixelSnappedAbsoluteClippedOverflowRect
218         to avoid exposing subpixel types to the platform layer.
219
220         No new tests.
221
222         * WebCore.exp.in:
223         * rendering/RenderObject.cpp:
224         (WebCore::RenderObject::pixelSnappedAbsoluteClippedOverflowRect):
225         Add pixelSnapped version of absoluteClippedOverflowRect
226         
227         (WebCore):
228         * rendering/RenderObject.h:
229         (RenderObject):
230
231 2012-03-19  Brady Eidson  <beidson@apple.com>
232
233         <rdar://problem/10848575> and https://bugs.webkit.org/show_bug.cgi?id=81516
234         REGRESSION (r107435) URLs copied from WebKit apps aren't in the right pasteboard format
235
236         Reviewed by Enrica Casucci.
237
238         r107435 started saving/restoring URLs as strings.
239         We need to go back to setting the URL on the pasteboard using AppKit URL pasteboard APIs.
240
241         WebKit API test: ContextMenuCanCopyURL
242         No WebKit2 API test possible at this time.
243
244         * platform/mac/PlatformPasteboardMac.mm:
245         (WebCore::PlatformPasteboard::setURL):
246
247 2012-03-19  Anders Carlsson  <andersca@apple.com>
248
249         Make the TileCache work with HiDPI again
250         https://bugs.webkit.org/show_bug.cgi?id=81569
251         <rdar://problem/11031542>
252
253         Reviewed by Sam Weinig.
254
255         Set the contentsScale of the individual tile layers to be the same as the device scale factor.
256         Also, take into account the fact that the value passed to TileCache::setScale is the product of the
257         page scale factor and the device scale factor, so divide it by the device scale factor before storing
258         it in m_scale.
259
260         * platform/graphics/ca/GraphicsLayerCA.cpp:
261         (WebCore::GraphicsLayerCA::platformCALayerDeviceScaleFactor):
262         (WebCore):
263         * platform/graphics/ca/GraphicsLayerCA.h:
264         (GraphicsLayerCA):
265         * platform/graphics/ca/PlatformCALayerClient.h:
266         (PlatformCALayerClient):
267         * platform/graphics/ca/mac/TileCache.h:
268         (TileCache):
269         * platform/graphics/ca/mac/TileCache.mm:
270         (WebCore::TileCache::TileCache):
271         (WebCore::TileCache::setScale):
272         (WebCore::TileCache::createTileLayer):
273
274 2012-03-19  Abhishek Arya  <inferno@chromium.org>
275
276         Crash due to layer tree information not updated when moving run-in children.
277         https://bugs.webkit.org/show_bug.cgi?id=81265
278
279         Reviewed by Julien Chaffraix.
280
281         We need to do a full removal as the run-in child is getting inserted into
282         the neighbouring block and |blockRunIn| is going to be destroyed later
283         in the function.
284
285         Test: fast/runin/run-in-layer-not-removed-crash.html
286
287         * rendering/RenderBlock.cpp:
288         (WebCore::RenderBlock::handleRunInChild):
289
290 2012-03-19  Dana Jansens  <danakj@chromium.org>
291
292         [chromium] Remove misleading double-if
293         https://bugs.webkit.org/show_bug.cgi?id=81557
294
295         Reviewed by Adrienne Walker.
296
297         Simple code cleanup, no functionality change.
298
299         * platform/graphics/chromium/TiledLayerChromium.cpp:
300         (WebCore::TiledLayerChromium::prepareToUpdateTiles):
301
302 2012-03-19  Eric Seidel  <eric@webkit.org>
303
304         Fix WTF header include discipline in Chromium WebKit
305         https://bugs.webkit.org/show_bug.cgi?id=81281
306
307         Reviewed by James Robinson.
308
309         I also fixed some bad include dicipline for other ports
310         as well.  Those changes are not yet necessary for those ports
311         to keep building, but soon should be as those authors
312         remove all the extra WTF includes from WebCore and other non-WTF projects.
313
314         * Modules/indexeddb/IDBLevelDBBackingStore.cpp:
315         * bindings/scripts/test/CPP/WebDOMFloat64Array.cpp:
316         * bindings/scripts/test/GObject/WebKitDOMFloat64Array.cpp:
317         * bindings/scripts/test/GObject/WebKitDOMFloat64ArrayPrivate.h:
318         * bindings/scripts/test/ObjC/DOMFloat64Array.mm:
319         * bindings/v8/NPV8Object.cpp:
320         * bindings/v8/SerializedScriptValue.cpp:
321         * bindings/v8/SerializedScriptValue.h:
322         * bindings/v8/V8Binding.cpp:
323         * bindings/v8/V8Binding.h:
324         * bindings/v8/V8DOMWrapper.cpp:
325         * bindings/v8/V8Utilities.cpp:
326         * bindings/v8/custom/V8ArrayBufferCustom.cpp:
327         * bindings/v8/custom/V8ArrayBufferViewCustom.h:
328         * bindings/v8/custom/V8AudioContextCustom.cpp:
329         * bindings/v8/custom/V8DOMWindowCustom.cpp:
330         * bindings/v8/custom/V8DedicatedWorkerContextCustom.cpp:
331         * bindings/v8/custom/V8Float32ArrayCustom.cpp:
332         * bindings/v8/custom/V8Float64ArrayCustom.cpp:
333         * bindings/v8/custom/V8Int16ArrayCustom.cpp:
334         * bindings/v8/custom/V8Int32ArrayCustom.cpp:
335         * bindings/v8/custom/V8Int8ArrayCustom.cpp:
336         * bindings/v8/custom/V8MessagePortCustom.cpp:
337         * bindings/v8/custom/V8Uint16ArrayCustom.cpp:
338         * bindings/v8/custom/V8Uint32ArrayCustom.cpp:
339         * bindings/v8/custom/V8Uint8ArrayCustom.cpp:
340         * bindings/v8/custom/V8Uint8ClampedArrayCustom.cpp:
341         * bindings/v8/custom/V8WorkerCustom.cpp:
342         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
343         * bridge/qt/qt_runtime.cpp:
344         * editing/gtk/FrameSelectionGtk.cpp:
345         * loader/archive/mhtml/MHTMLArchive.cpp:
346         * platform/ScrollAnimatorNone.cpp:
347         * platform/blackberry/CookieMap.h:
348         * platform/blackberry/CookieParser.h:
349         * platform/blackberry/SSLKeyGeneratorBlackBerry.cpp:
350         * platform/chromium/DragImageChromiumSkia.cpp:
351         * platform/chromium/PlatformCursor.h:
352         * platform/chromium/PlatformSupport.h:
353         * platform/chromium/PopupMenuPrivate.h:
354         * platform/chromium/TraceEvent.h:
355         * platform/chromium/WidgetChromium.cpp:
356         * platform/efl/RefPtrEfl.h:
357         * platform/graphics/cairo/RefPtrCairo.h:
358         * platform/graphics/chromium/RateLimiter.h:
359         * platform/graphics/chromium/TiledLayerChromium.cpp:
360         * platform/graphics/efl/IconEfl.cpp:
361         * platform/graphics/gstreamer/GStreamerGWorld.h:
362         * platform/graphics/gtk/IconGtk.cpp:
363         * platform/graphics/skia/PlatformContextSkia.h:
364         * platform/graphics/texmap/TextureMapperBackingStore.h:
365         * platform/graphics/texmap/TextureMapperLayer.cpp:
366         * platform/graphics/wx/TransformationMatrixWx.cpp:
367         * platform/gtk/PlatformMouseEventGtk.cpp:
368         * platform/leveldb/LevelDBSlice.h:
369         * platform/mediastream/MediaStreamCenter.cpp:
370         * platform/network/soup/SocketStreamHandleSoup.cpp:
371         * platform/network/win/ResourceHandleWin.cpp:
372         * platform/qt/RenderThemeQtMobile.cpp:
373         * platform/wx/MouseEventWx.cpp:
374         * platform/wx/wxcode/win/fontprops.cpp:
375
376 2012-03-19  Dana Jansens  <danakj@chromium.org>
377
378         [chromium] Invalidate/update evicted tiles during commit
379         https://bugs.webkit.org/show_bug.cgi?id=81529
380
381         Reviewed by Adrienne Walker.
382
383         A previous change caused a regression where evicted (invalid) tiles
384         were no longer marked as dirty and updated. The regress was caused
385         in https://bugs.webkit.org/show_bug.cgi?id=81175 and is fixed here.
386
387         Unit test: TiledLayerChromiumTest.pushDeletedTiles
388
389         * platform/graphics/chromium/TiledLayerChromium.cpp:
390         (WebCore::UpdatableTile::copyAndClearDirty):
391         (WebCore::TiledLayerChromium::prepareToUpdateTiles):
392
393 2012-03-19  Adam Barth  <abarth@webkit.org>
394
395         Remove PLATFORM(TORCHMOBILE) ifdef from MainResourceLoader.cpp
396         https://bugs.webkit.org/show_bug.cgi?id=81549
397
398         Reviewed by Eric Seidel.
399
400         This appears to be the only PLATFORM(TORCHMOBILE) ifdef in WebCore.  I
401         don't believe this ifdef is needed anymore.
402
403         * loader/MainResourceLoader.cpp:
404         (WebCore::shouldLoadAsEmptyDocument):
405         (WebCore):
406
407 2012-03-19  Sheriff Bot  <webkit.review.bot@gmail.com>
408
409         Unreviewed, rolling out r111207.
410         http://trac.webkit.org/changeset/111207
411         https://bugs.webkit.org/show_bug.cgi?id=81561
412
413         Causing chromium unit test failure (Requested by reveman on
414         #webkit).
415
416         * platform/graphics/chromium/Extensions3DChromium.h:
417         (Extensions3DChromium):
418
419 2012-03-19  Anders Carlsson  <andersca@apple.com>
420
421         Remove unnecessary CALayer overrides from WebTileCacheLayer
422         https://bugs.webkit.org/show_bug.cgi?id=81562
423
424         Reviewed by Dan Bernstein.
425
426         * platform/graphics/ca/mac/TileCache.h:
427         (TileCache):
428         * platform/graphics/ca/mac/WebTileCacheLayer.mm:
429
430 2012-03-19  Emil A Eklund  <eae@chromium.org>
431
432         Correct usage of LayoutUnits in page code in preparation for turning on subpixel layout
433         https://bugs.webkit.org/show_bug.cgi?id=81538
434
435         Reviewed by Eric Seidel.
436
437         Fix usage of LayoutUnits and conversions between types in page code.
438
439         No new tests.
440
441         * page/DOMWindow.cpp:
442         (WebCore::DOMWindow::innerHeight):
443         (WebCore::DOMWindow::innerWidth):
444         Explicitly cast long to int. InspectorInstrumentation requires a long and
445         FractionalLayoutUnit has no constructor that takes long.
446         
447         * page/EventHandler.cpp:
448         (WebCore::EventHandler::sendContextMenuEventForKey):
449         Pixel snap overflow rect as selection rects are integer based.
450         
451         * page/FrameView.cpp:
452         (WebCore::FrameView::scrollContentsFastPath):
453         Pixel snap repaint rects when computing update rect as all scrolling is
454         done on integer bounds.
455         
456         * page/GestureTapHighlighter.cpp:
457         Change rects vector to IntRect as addFocusRingRects operates on IntRects.
458         
459         * page/Page.cpp:
460         (WebCore::Page::addRelevantRepaintedObject):
461         (WebCore::Page::addRelevantUnpaintedObject):
462         Change paint methods to take a LayoutRect paint rect.
463         
464         * page/SpatialNavigation.cpp:
465         (WebCore::distanceDataForNode):
466         Change distance calculation to use floats instead of converting to float
467         at the end.
468
469 2012-03-19  David Hyatt  <hyatt@apple.com>
470
471         https://bugs.webkit.org/show_bug.cgi?id=81553
472         
473         [New Multicolumn] Stub out classes to represent sets of column region boxes.
474
475         RenderRegionSet is an abstract class representing a set of contiguous anonymous
476         same-size regions.
477         
478         RenderMultiColumnSet derives from RenderRegionSet and represents a set of contiguous
479         columns. It will also handle unique column behavior like column rule painting.
480         
481         Eventually there will be a RenderPageSet derived class for printing/pages, but
482         that will come later after I finish rebuilding multi-column layout.
483
484         Reviewed by Dan Bernstein.
485
486         * GNUmakefile.list.am:
487         * Target.pri:
488         * WebCore.gypi:
489         * WebCore.vcproj/WebCore.vcproj:
490         * WebCore.xcodeproj/project.pbxproj:
491         * rendering/RenderMultiColumnSet.cpp: Added.
492         (WebCore):
493         (WebCore::RenderMultiColumnSet::RenderMultiColumnSet):
494         (WebCore::RenderMultiColumnSet::renderName):
495         * rendering/RenderMultiColumnSet.h: Added.
496         (WebCore):
497         (RenderMultiColumnSet):
498         * rendering/RenderRegionSet.cpp: Added.
499         (WebCore):
500         (WebCore::RenderRegionSet::RenderRegionSet):
501         * rendering/RenderRegionSet.h: Added.
502         (WebCore):
503         (RenderRegionSet):
504
505 2012-03-19  Raymond Toy  <rtoy@google.com>
506
507         Add playback state for AudioBufferSourceNode and add number of active nodes
508         https://bugs.webkit.org/show_bug.cgi?id=79701
509
510         Add a playback state to AudioBufferSourceNode so that the user can
511         tell if the node is scheduled, playing, or finished.
512
513         For an AudioContext, add a count of the number of
514         AudioBufferSourceNode's that are active (playing audio).
515
516         Deleted m_isPlaying and m_hasFinished. For the record, m_isPlaying
517         is the same as a playbackState of SCHEDULED_STATE or PLAYING_STATE.
518         m_hasFinished is equivalent to a playbackState of FINISHED_STATE.
519         
520         Reviewed by Chris Rogers.
521
522         Test: webaudio/audiobuffersource-playbackState.html
523
524         * webaudio/AudioBufferSourceNode.cpp:
525         (WebCore):
526         (WebCore::AudioBufferSourceNode::AudioBufferSourceNode):
527         initialize playbackState, remove m_isPlaying, m_hasFinished.
528         (WebCore::AudioBufferSourceNode::process): Update playbackState
529         (WebCore::AudioBufferSourceNode::finish): Update playbackState
530         (WebCore::AudioBufferSourceNode::noteOn): Update playbackState
531         (WebCore::AudioBufferSourceNode::noteGrainOn): Update playbackState
532         (WebCore::AudioBufferSourceNode::noteOff): Use playbackState 
533         * webaudio/AudioBufferSourceNode.h:
534         (AudioBufferSourceNode): Define states, remove m_isPlaying, m_hasFinished.
535         (WebCore::AudioBufferSourceNode::playbackState): Added.
536         * webaudio/AudioBufferSourceNode.idl: Define constants for the
537         playback state, add attribute playbackState.
538         * webaudio/AudioContext.cpp:
539         (WebCore::AudioContext::activeSourceCount): Added.
540         (WebCore::AudioContext::incrementActiveSourceCount): Added.
541         (WebCore::AudioContext::decrementActiveSourceCount): Added.
542         * webaudio/AudioContext.h:
543         (AudioContext):
544         * webaudio/AudioContext.idl: Add attribute activeSourceCount.
545
546 2012-03-19  Sheriff Bot  <webkit.review.bot@gmail.com>
547
548         Unreviewed, rolling out r109014.
549         http://trac.webkit.org/changeset/109014
550         https://bugs.webkit.org/show_bug.cgi?id=81551
551
552         Causing crashes (Requested by inferno-sec on #webkit).
553
554         * rendering/style/RenderStyle.h:
555
556 2012-03-19  Tony Chang  <tony@chromium.org>
557
558         Unreviewed, remove headers that no longer exist or moved in WebCore.gypi.
559
560         * WebCore.gypi:
561
562 2012-03-19  Mihnea Ovidenie  <mihnea@adobe.com>
563
564         [CSSRegions]Implement NamedFlow::contentNodes attribute
565         https://bugs.webkit.org/show_bug.cgi?id=80134
566
567         Reviewed by David Hyatt.
568
569         The named flow content nodes collection contains those nodes with webkitFlowInto property set to 'flow'.
570         In the list, the nodes are placed in document order. Nodes with display:none are also part of the list.
571         The list of nodes is returned as a static node list.
572
573         Test: fast/regions/webkit-named-flow-content-nodes.html
574
575         * dom/Document.cpp:
576         (WebCore::Document::webkitGetFlowByName):
577         * dom/Document.h:
578         * dom/Element.cpp:
579         (WebCore::Element::detach):
580         * dom/NodeRenderingContext.cpp:
581         (WebCore::NodeRenderingContext::moveToFlowThreadIfNeeded):
582         * dom/WebKitNamedFlow.cpp:
583         (WebCore::WebKitNamedFlow::contentNodes):
584         (WebCore):
585         (WebCore::WebKitNamedFlow::registerContentNode):
586         * dom/WebKitNamedFlow.h:
587         (WebCore):
588         (WebKitNamedFlow):
589         (WebCore::WebKitNamedFlow::unregisterContentNode):
590         * dom/WebKitNamedFlow.idl:
591
592 2012-03-19  Xingnan Wang  <xingnan.wang@intel.com>
593
594         ConvolverNode should not incur processing latency
595         https://bugs.webkit.org/show_bug.cgi?id=75564
596
597         Reviewed by Chris Rogers.
598
599         Add the DirectConvolver instead of FFTConvolver for the processing of the leading portion of impulse response.
600
601         * WebCore.gypi:
602         * platform/audio/DirectConvolver.cpp: Added.
603         (WebCore):
604         (WebCore::DirectConvolver::DirectConvolver):
605         (WebCore::DirectConvolver::process):
606         (WebCore::DirectConvolver::reset):
607         * platform/audio/DirectConvolver.h: Added.
608         (WebCore):
609         (DirectConvolver):
610         (WebCore::DirectConvolver::convolveSize):
611         * platform/audio/ReverbConvolver.cpp:
612         (WebCore::ReverbConvolver::ReverbConvolver):
613         * platform/audio/ReverbConvolver.h:
614         * platform/audio/ReverbConvolverStage.cpp:
615         (WebCore::ReverbConvolverStage::ReverbConvolverStage):
616         (WebCore::ReverbConvolverStage::process):
617         (WebCore::ReverbConvolverStage::reset):
618         * platform/audio/ReverbConvolverStage.h:
619         (WebCore):
620         (ReverbConvolverStage):
621
622 2012-03-19  Anders Carlsson  <andersca@apple.com>
623
624         Find in page highlights get out of place when scrolling
625         https://bugs.webkit.org/show_bug.cgi?id=81543
626
627         Reviewed by Sam Weinig.
628
629         Remove a now unused function from GraphicsLayer.
630
631         * platform/graphics/GraphicsLayer.h:
632         (GraphicsLayer):
633         * platform/graphics/ca/GraphicsLayerCA.h:
634         (GraphicsLayerCA):
635
636 2012-03-19  David Hyatt  <hyatt@apple.com>
637
638         https://bugs.webkit.org/show_bug.cgi?id=81534
639
640         [New Multicolumn] Make the multi-column block re-layout its children when the column width/count change.
641         Cache the count/width on the multi-column block for easy access.
642
643         Reviewed by Antti Koivisto.
644
645         * rendering/RenderBlock.cpp:
646         (WebCore::RenderBlock::recomputeLogicalWidth):
647         (WebCore::RenderBlock::layoutBlock):
648         * rendering/RenderBlock.h:
649         Virtualize the code that recomputes the logical width for a block and sets relayoutChildren to true,
650         so that column code can subclass the method to also check for changes in the column width/count.
651
652         * rendering/RenderMultiColumnBlock.cpp:
653         (WebCore::RenderMultiColumnBlock::computeColumnCountAndWidth):
654         The column count/width determination algorithm in one method on the RenderMultiColumnBlock. It's a copy
655         of the code from RenderBlock (which will be going away eventually).
656
657         (WebCore::RenderMultiColumnBlock::recomputeLogicalWidth):
658         * rendering/RenderMultiColumnBlock.h:
659         (RenderMultiColumnBlock):
660         Subclassed method to also check for changes in the column width to set relayoutChildren to true.
661
662 2012-03-19  Michal Mocny  <mmocny@google.com>
663
664         [chromium] Updating WebGraphicsContext3D MemoryAllocation callback to accept a struct with have backbuffer suggestion.
665         https://bugs.webkit.org/show_bug.cgi?id=81279
666
667         Reviewed by James Robinson.
668
669         * platform/graphics/chromium/Extensions3DChromium.h:
670         (GpuMemoryAllocationCHROMIUM):
671         (WebCore::Extensions3DChromium::GpuMemoryAllocationCHROMIUM::GpuMemoryAllocationCHROMIUM):
672         (GpuMemoryAllocationChangedCallbackCHROMIUM):
673
674 2012-03-19  Tony Chang  <tony@chromium.org>
675
676         flex-item-align: stretch should only grow, never shrink
677         https://bugs.webkit.org/show_bug.cgi?id=80882
678
679         Reviewed by Ojan Vafai.
680
681         New test cases in css3/flexbox/flex-align-stretch.html.
682
683         * rendering/RenderFlexibleBox.cpp:
684         (WebCore::RenderFlexibleBox::alignChildren): Move stretch code into a separate function.
685         (WebCore::RenderFlexibleBox::alignChildStretch): Add an early return if our height is shrinking.
686         (WebCore):
687         * rendering/RenderFlexibleBox.h:
688         (RenderFlexibleBox):
689
690 2012-03-19  Vsevolod Vlasov  <vsevik@chromium.org>
691
692         Web Inspector: Implement snippets evaluation.
693         https://bugs.webkit.org/show_bug.cgi?id=81334
694
695         Reviewed by Pavel Feldman.
696
697         * inspector/front-end/ConsoleView.js:
698         (WebInspector.ConsoleView.prototype.evaluateUsingTextPrompt):
699         (WebInspector.ConsoleView.prototype._enterKeyPressed):
700         * inspector/front-end/ScriptMapping.js:
701         (WebInspector.MainScriptMapping):
702         * inspector/front-end/SnippetsModel.js:
703         * inspector/front-end/externs.js:
704         (WebInspector.evaluateInConsole):
705         * inspector/front-end/inspector.js:
706         (WebInspector.evaluateInConsole):
707
708 2012-03-19  Tommy Widenflycht  <tommyw@google.com>
709
710         MediaStream API (JSEP): Introducing PeerConnection00Handler
711         https://bugs.webkit.org/show_bug.cgi?id=81333
712
713         Reviewed by Adam Barth.
714
715         In preparation of the last WebCore patch that will introduce PeerConnection00 here's its platform representation.
716
717         Not possible to test until the entire JSEP feature is commited.
718
719         * GNUmakefile.list.am:
720         * WebCore.gypi:
721         * platform/mediastream/PeerConnection00Handler.cpp: Added.
722         (WebCore):
723         (WebCore::PeerConnection00Handler::create):
724         (WebCore::PeerConnection00Handler::PeerConnection00Handler):
725         (WebCore::PeerConnection00Handler::~PeerConnection00Handler):
726         (WebCore::PeerConnection00Handler::createOffer):
727         (WebCore::PeerConnection00Handler::createAnswer):
728         (WebCore::PeerConnection00Handler::setLocalDescription):
729         (WebCore::PeerConnection00Handler::setRemoteDescription):
730         (WebCore::PeerConnection00Handler::localDescription):
731         (WebCore::PeerConnection00Handler::remoteDescription):
732         (WebCore::PeerConnection00Handler::startIce):
733         (WebCore::PeerConnection00Handler::processIceMessage):
734         (WebCore::PeerConnection00Handler::addStream):
735         (WebCore::PeerConnection00Handler::removeStream):
736         (WebCore::PeerConnection00Handler::stop):
737         * platform/mediastream/PeerConnection00Handler.h: Added.
738         (WebCore):
739         (PeerConnection00Handler):
740         * platform/mediastream/PeerConnection00HandlerClient.h: Added.
741         (WebCore):
742         (PeerConnection00HandlerClient):
743         (WebCore::PeerConnection00HandlerClient::~PeerConnection00HandlerClient):
744
745 2012-03-19  David Reveman  <reveman@chromium.org>
746
747         [Chromium] GL_EXT_occlusion_query_boolean and GL_CHROMIUM_command_buffer_query support.
748         https://bugs.webkit.org/show_bug.cgi?id=80988
749
750         Reviewed by Adrienne Walker.
751
752         Expose EXT_occlusion_query API to WebKit compositor. Add
753         GL_EXT_occlusion_query_boolean and GL_CHROMIUM_command_buffer_query
754         enums.
755
756         * platform/graphics/chromium/Extensions3DChromium.h:
757         (Extensions3DChromium):
758
759 2012-03-19  Mike Lawther  <mikelawther@chromium.org>
760
761         CSS3 calc: make mask images work with mixed percent/absolute
762         https://bugs.webkit.org/show_bug.cgi?id=81477
763
764         Reviewed by Ojan Vafai.
765
766         Test: css3/calc/simple-composited-mask-expected.html
767
768         * css/CSSStyleSelector.cpp:
769         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
770
771 2012-03-19  Mark Pilgrim  <pilgrim@chromium.org>
772
773         Style cleanup in Modules/filesystem/
774         https://bugs.webkit.org/show_bug.cgi?id=81520
775
776         Reviewed by Adam Barth.
777
778         No new tests, all existing tests pass.
779
780         * Modules/filesystem/AsyncFileWriter.h:
781         (WebCore::AsyncFileWriter::~AsyncFileWriter):
782         * Modules/filesystem/AsyncFileWriterClient.h:
783         (WebCore::AsyncFileWriterClient::~AsyncFileWriterClient):
784         * Modules/filesystem/DOMFilePath.cpp:
785         (WebCore::DOMFilePath::getDirectory):
786         * Modules/filesystem/DOMFilePath.h:
787         (DOMFilePath):
788         * Modules/filesystem/DOMFileSystemBase.h:
789         (DOMFileSystemBase):
790         * Modules/filesystem/DirectoryEntry.h:
791         * Modules/filesystem/DirectoryEntrySync.h:
792         * Modules/filesystem/EntryArray.h:
793         (EntryArray):
794         * Modules/filesystem/FileEntry.h:
795         (FileEntry):
796         * Modules/filesystem/FileSystemCallbacks.h:
797         (FileSystemCallbacksBase):
798         * Modules/filesystem/FileWriter.cpp:
799         (WebCore::FileWriter::abort):
800
801 2012-03-19  Mike Lawther  <mikelawther@chromium.org>
802
803         CSS3 calc: background positioning works with mixed percent/absolute expressions
804         https://bugs.webkit.org/show_bug.cgi?id=81478
805
806         Reviewed by Ojan Vafai.
807
808         Test: css3/calc/background-position-parsing-expected.html
809
810         * css/CSSStyleSelector.cpp:
811         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
812
813 2012-03-19  Alexander Færøy  <alexander.faeroy@nokia.com>
814
815         Add NodeRenderStyle.h to TouchAdjustment.cpp
816
817         Unreviewed build fix after r111185.
818
819         * page/TouchAdjustment.cpp:
820
821 2012-03-19  Leo Yang  <leo.yang@torchmobile.com.cn>
822
823         [BlackBerry] Add PlatformMediaEngineClassName for blackberry in platform/graphics/MediaPlayer.cpp
824         https://bugs.webkit.org/show_bug.cgi?id=81489
825
826         Reviewed by Rob Buis.
827
828         * platform/graphics/MediaPlayer.cpp:
829
830 2012-03-19  Leo Yang  <leo.yang@torchmobile.com.cn>
831
832         [BlackBerry] Upstream the BlackBerry change to platform/PlatformKeyboardEvent.h
833         https://bugs.webkit.org/show_bug.cgi?id=81312
834
835         Reviewed by Rob Buis.
836
837         * platform/PlatformKeyboardEvent.h:
838         (Platform):
839         (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):
840         (PlatformKeyboardEvent):
841         (WebCore::PlatformKeyboardEvent::unmodifiedCharacter):
842         Add BlackBerry specific constructor and member fields.
843         * platform/blackberry/PlatformKeyboardEventBlackBerry.cpp:
844         (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):
845         Change the parameter type to const reference type to adapt to the declaration.
846
847 2012-03-19  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
848
849         Select best target for tap gesture.
850         https://bugs.webkit.org/show_bug.cgi?id=78801
851
852         Reviewed by Kenneth Rohde Christiansen.
853         IntRect changes reviewed by Dave Hyatt.
854
855         The new API is available through EventHandler::bestClickableNodeForTouchPoint, but
856         implementation details have been placed in page/TouchAdjustment.
857
858         The default hit detection is performed by measuring the distance to the center
859         lines of the absolute rects of the hit nodes. Absolute rects are used instead
860         of bounding rects to make hit-detecting against links over line breaks. Distance
861         to center line is used to make it easier to hit small links next to large links.
862         For line-rects the distance to the center-line is a better expression of the distance
863         to a rectangles center than the distance to the center-point.
864
865         Tests: touchadjustment/event-triggered-widgets.html
866                touchadjustment/html-label.html
867                touchadjustment/nested-touch.html
868                touchadjustment/touch-inlines.html
869
870         * Target.pri:
871         * page/EventHandler.cpp:
872         (WebCore::EventHandler::handleGestureTap):
873         (WebCore::EventHandler::bestClickableNodeForTouchPoint):
874         * page/EventHandler.h:
875         * page/TouchAdjustment.cpp: Added.
876         (WebCore::TouchAdjustment::QuadForHitTest::QuadForHitTest):
877         (WebCore::TouchAdjustment::QuadForHitTest::node):
878         (WebCore::TouchAdjustment::QuadForHitTest::quad):
879         (WebCore::TouchAdjustment::QuadForHitTest::boundingBox):
880         (WebCore::TouchAdjustment::nodeRespondsToTapGesture):
881         (WebCore::TouchAdjustment::appendAbsoluteQuadsForNodeToHitTestList):
882         (WebCore::TouchAdjustment::compileQuadsForHitTesting):
883         (WebCore::TouchAdjustment::distanceSquaredToQuadCenterLine):
884         (WebCore::TouchAdjustment::findNodeWithLowestMetric):
885         (WebCore::findBestClickableCandidate):
886         * page/TouchAdjustment.h: Added.
887         * platform/graphics/FloatQuad.h:
888         (WebCore::FloatQuad::center):
889         * platform/graphics/IntPoint.h:
890         (WebCore::IntPoint::distanceSquaredToPoint):
891         * platform/graphics/IntRect.cpp:
892         (WebCore::distanceToInterval):
893         (WebCore::IntRect::differenceToPoint):
894         (WebCore::IntRect::differenceFromCenterLineToPoint):
895         * platform/graphics/IntRect.h:
896         (WebCore::IntRect::distanceSquaredToPoint):
897         (WebCore::IntRect::distanceSquaredFromCenterLineToPoint):
898         * platform/graphics/IntSize.h:
899         (WebCore::IntSize::diagonalLengthSquared):
900         * testing/Internals.cpp:
901         (WebCore::Internals::touchPositionAdjustedToBestClickableNode):
902         (WebCore::Internals::touchNodeAdjustedToBestClickableNode):
903         * testing/Internals.h:
904         * testing/Internals.idl:
905
906 2012-03-19  Mark Pilgrim  <pilgrim@chromium.org>
907
908         Add ENABLED(FILE_SYSTEM) to DOMFilePath.h
909         https://bugs.webkit.org/show_bug.cgi?id=81393
910
911         Reviewed by Kentaro Hara.
912
913         No new tests, all existing tests pass.
914
915         * Modules/filesystem/DOMFilePath.h:
916
917 2012-03-19  Max Vujovic  <mvujovic@adobe.com>
918
919         inspector highlight of SVG root element with viewbox does not match dimensions of element
920         https://bugs.webkit.org/show_bug.cgi?id=78037
921
922         Reviewed by Nikolas Zimmermann.
923
924         Functions such as RenderBox::absoluteQuads and DOMNodeHighlighter::getOrDrawNodeHighlight
925         eventually call RenderSVGRoot::mapLocalToContainer, passing along local CSS box coordinates.
926
927         However, before this patch, RenderSVGRoot::mapLocalToContainer expected local SVG viewport
928         coordinates. This caused the inspector highlight to be incorrectly sized and positioned.
929
930         Now, RenderSVGRoot::mapLocalToContainer expects local CSS box coordinates, like other HTML
931         renderers.
932
933         Test: inspector/elements/highlight-svg-root.html
934
935         * dom/Element.cpp:
936         (WebCore::Element::getBoundingClientRect):
937             Now, the SVG root element can use the code path for elements with CSS boxes to calculate
938             its bounding client rect.
939
940         * rendering/svg/RenderSVGRoot.cpp:
941         (WebCore::RenderSVGRoot::mapLocalToContainer):
942             RenderSVGRoot::mapLocalToContainer no longer needs to apply the
943             localToBorderBoxTransform to convert from local SVG viewport coordinates to local CSS
944             box coordinates. Now, it receives local CSS box coordinates.
945
946         * rendering/svg/RenderSVGRoot.h:
947         (WebCore::RenderSVGRoot::localToBorderBoxTransform):
948             RenderSVGRoot::localToBorderBoxTransform has been exposed for child elements in the SVG
949             namespace to use when mapping from local SVG viewport coordinates to local CSS box
950             coordinates.
951
952         (RenderSVGRoot):
953         * rendering/svg/SVGRenderSupport.cpp:
954         (WebCore::SVGRenderSupport::mapLocalToContainer):
955             Elements in the SVG namespace should now apply the localToBorderBoxTransform at the
956             SVG/HTML boundary (aka RenderSVGRoot) when mapping their coordinates up the render tree.
957
958         * svg/SVGSVGElement.cpp:
959         (WebCore::SVGSVGElement::localCoordinateSpaceTransform):
960             Same as above. This method is eventually used in the SVGLocatable::getScreenCTM
961             calculation.
962
963 2012-03-19  Hironori Bono  <hbono@chromium.org>
964
965         Add a copy constructor to CollapsedBorderValue
966         https://bugs.webkit.org/show_bug.cgi?id=81502
967
968         Reviewed by Hajime Morita.
969
970         Due to the lack of this copy constructor, GCC (x86) creates a broken copy
971         constructor and it causes a build break on Google Chrome.
972
973         * rendering/style/CollapsedBorderValue.h:
974         (WebCore::CollapsedBorderValue::CollapsedBorderValue):
975         (CollapsedBorderValue):
976
977 2012-03-18  Matt Falkenhagen  <falken@chromium.org>
978
979         Fallback to common script when per-script font setting is the empty string
980         https://bugs.webkit.org/show_bug.cgi?id=81329
981
982         Reviewed by Kent Tamura.
983
984         Tests: fast/text/international/font-fallback-to-common-script.html
985
986         * page/Settings.cpp:
987         (WebCore::setGenericFontFamilyForScript): Remove the setting when the per-script font family is the empty string.
988
989 2012-03-18  Luke Macpherson   <macpherson@chromium.org>
990
991         Remove remnants of code that assume Lengths are 28 bit integers.
992         https://bugs.webkit.org/show_bug.cgi?id=67976
993
994         Reviewed by Eric Seidel.
995
996         Test: LayoutTests/fast/table/max-width-integer-overflow-expected.html
997
998         * css/CSSPrimitiveValue.cpp:
999         (WebCore::CSSPrimitiveValue::computeLength):
1000         Bound by INT_MAX and INT_MIN instead of 28 bit bounds.
1001         * css/CSSStyleApplyProperty.cpp:
1002         (WebCore::ApplyPropertyBorderRadius::applyValue):
1003         Use PrimitiveValue::computeLength function directly.
1004         * platform/Length.h:
1005         Remove 28 bit integer limit constants.
1006         * rendering/AutoTableLayout.cpp:
1007         (WebCore::AutoTableLayout::computePreferredLogicalWidths):
1008         Use std::numeric_limits.
1009
1010 2012-03-16  Shinya Kawanaka  <shinyak@chromium.org>
1011
1012         Should remove RuntimeEnabledFeatures::multipleShadowSubtreesEnabled
1013         https://bugs.webkit.org/show_bug.cgi?id=79307
1014
1015         Reviewed by Dimitri Glazkov.
1016
1017         Since RuntimeEnabledFeatures::multipleShadowSubtreesEnabled was introduced for
1018         temporal unstability of multiple shadow roots. We should remove it now, and
1019         enable it by default.
1020
1021         Test: fast/dom/shadow/shadow-root-js-api.html should cover this change.
1022         The other shadow related tests should also covers this change.
1023
1024         * WebCore.exp.in:
1025         * bindings/generic/RuntimeEnabledFeatures.cpp:
1026         (WebCore):
1027         * bindings/generic/RuntimeEnabledFeatures.h:
1028         (RuntimeEnabledFeatures):
1029         * dom/ShadowRoot.cpp:
1030         (WebCore::ShadowRoot::create):
1031         * dom/ShadowTree.cpp:
1032         (WebCore::ShadowTree::addShadowRoot):
1033         * testing/Internals.cpp:
1034         * testing/Internals.h:
1035         (Internals):
1036         * testing/Internals.idl:
1037
1038 2012-03-18  Dana Jansens  <danakj@chromium.org>
1039
1040         [chromium] Don't occlude on main-thread behind layers/surfaces with impl-thread animations
1041         https://bugs.webkit.org/show_bug.cgi?id=81354
1042
1043         Reviewed by Adrienne Walker.
1044
1045         Layers and surfaces can have an animating opacity or translation on the
1046         impl thread. In this case, the main thread does not know their actual
1047         values, and treats these values as "unknowns". This means we can't use
1048         them for marking areas of the screen as occluded, and we can't consider
1049         a part of a layer occluded in a space that we can not reliably transform
1050         to.
1051
1052         Unit test: CCOcclusionTrackerTestAnimationOpacity0OnMainThread
1053                    CCOcclusionTrackerTestAnimationOpacity1OnMainThread
1054                    CCOcclusionTrackerTestAnimationTranslateOnMainThread
1055
1056         * platform/graphics/chromium/cc/CCOcclusionTracker.cpp:
1057         (WebCore::layerOpacityKnown):
1058         (WebCore::layerTransformsToTargetKnown):
1059         (WebCore::layerTransformsToScreenKnown):
1060         (WebCore):
1061         (WebCore::surfaceOpacityUnknown):
1062         (WebCore::surfaceTransformsToTargetUnknown):
1063         (WebCore::surfaceTransformsToScreenUnknown):
1064         (WebCore::::finishedTargetRenderSurface):
1065         (WebCore::contentToScreenSpaceTransform):
1066         (WebCore::contentToTargetSurfaceTransform):
1067         (WebCore::::markOccludedBehindLayer):
1068         (WebCore::::occluded):
1069         (WebCore::::unoccludedContentRect):
1070
1071 2012-03-18  Dana Jansens  <danakj@chromium.org>
1072
1073         [chromium] Animating opacity is not opaque and should create a render surface on main thread
1074         https://bugs.webkit.org/show_bug.cgi?id=81401
1075
1076         Reviewed by James Robinson.
1077
1078         Unit test: CCLayerTreeHostCommonTest.verifyAnimationsForRenderSurfaceHierarchy
1079
1080         * platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp:
1081         (WebCore::layerOpacityIsOpaque):
1082         (WebCore):
1083         (WebCore::subtreeShouldRenderToSeparateSurface):
1084
1085 2012-03-18  Sam Weinig  <sam@webkit.org>
1086
1087         WebCore::BitmapImage::getCGImageRef should not be used off the main thread.
1088         https://bugs.webkit.org/show_bug.cgi?id=81441
1089
1090         Reviewed by Anders Carlsson.
1091
1092         Covered by existing tests.
1093
1094         * loader/cache/MemoryCache.cpp:
1095         (WebCore::memoryCache):
1096         (WebCore::MemoryCache::add):
1097         (WebCore::MemoryCache::revalidationFailed):
1098         (WebCore::MemoryCache::resourceForURL):
1099         (WebCore::MemoryCache::evict):
1100         Add back main thread assertions.
1101
1102         * platform/graphics/cg/PatternCG.cpp:
1103         (PatternCallbackData):
1104         (WebCore::patternCallback):
1105         (WebCore::patternReleaseOnMainThreadCallback):
1106         (WebCore::Pattern::createPlatformPattern):
1107         Instead of pulling out the CGImageRef in the pattern callback, do it upfront.
1108
1109 2012-03-18  Alexander Færøy  <alexander.faeroy@nokia.com>
1110
1111         [Qt] Don't prepare SQL statements when the database is not open
1112         https://bugs.webkit.org/show_bug.cgi?id=81470
1113
1114         Reviewed by Kenneth Rohde Christiansen.
1115
1116         Already covered by existing tests.
1117
1118         * platform/qt/CookieJarQt.cpp:
1119         (WebCore::SharedCookieJarQt::deleteCookiesForHostname):
1120         (WebCore::SharedCookieJarQt::deleteAllCookies):
1121         (WebCore::SharedCookieJarQt::setCookiesFromUrl):
1122         (WebCore::SharedCookieJarQt::loadCookies):
1123
1124 2012-03-18  Kentaro Hara  <haraken@chromium.org>
1125
1126         Unreviewed, rolling out r110994 due to Chromium crash
1127
1128         * CMakeLists.txt:
1129         * DerivedSources.make:
1130         * DerivedSources.pri:
1131         * GNUmakefile.list.am:
1132         * Target.pri:
1133         * WebCore.gypi:
1134         * WebCore.vcproj/WebCore.vcproj:
1135         * WebCore.xcodeproj/project.pbxproj:
1136         * notifications/DOMWindowNotifications.cpp: Removed.
1137         * notifications/DOMWindowNotifications.h: Removed.
1138         * notifications/DOMWindowNotifications.idl: Removed.
1139         * page/DOMWindow.cpp:
1140         (WebCore::DOMWindow::~DOMWindow):
1141         (WebCore::DOMWindow::willDetachPage):
1142         (WebCore::DOMWindow::disconnectDOMWindowProperties):
1143         (WebCore::DOMWindow::clearDOMWindowProperties):
1144         (WebCore):
1145         (WebCore::DOMWindow::webkitNotifications):
1146         (WebCore::DOMWindow::resetNotifications):
1147         * page/DOMWindow.h:
1148         (WebCore):
1149         (DOMWindow):
1150         * page/DOMWindow.idl:
1151         * page/Frame.cpp:
1152         (WebCore::Frame::willDetachPage):
1153         (WebCore::Frame::transferChildFrameToNewDocument):
1154
1155 2012-03-18  Kentaro Hara  <haraken@chromium.org>
1156
1157         Unreviewed, rolling out r111086.
1158         http://trac.webkit.org/changeset/111086
1159         https://bugs.webkit.org/show_bug.cgi?id=81374
1160
1161         Chromium crash
1162
1163         * notifications/DOMWindowNotifications.cpp:
1164         (WebCore::DOMWindowNotifications::disconnectFrame):
1165
1166 2012-03-18  David Reveman  <reveman@chromium.org>
1167
1168         Invalidation issue when creating backing layer for fixed positioned element.
1169         https://bugs.webkit.org/show_bug.cgi?id=80647
1170
1171         Reviewed by James Robinson.
1172
1173         Ensure that root layer is correctly invalidated by handling scroll and
1174         invalidation from movement of fixed position elements prior to creating
1175         any backing layers.
1176
1177         Test: compositing/layer-creation/fixed-position-scroll.html
1178
1179         * page/FrameView.cpp:
1180         (WebCore::FrameView::repaintFixedElementsAfterScrolling):
1181         (WebCore):
1182         (WebCore::FrameView::updateFixedElementsAfterScrolling):
1183         * page/FrameView.h:
1184         (FrameView):
1185         * platform/ScrollView.cpp:
1186         (WebCore::ScrollView::scrollTo):
1187         * platform/ScrollView.h:
1188         (WebCore::ScrollView::repaintFixedElementsAfterScrolling):
1189         (WebCore::ScrollView::updateFixedElementsAfterScrolling):
1190
1191 2012-03-18  Dana Jansens  <danakj@chromium.org>
1192
1193         [chromium] Transform animation state should be inherited from parents
1194         https://bugs.webkit.org/show_bug.cgi?id=81363
1195
1196         Reviewed by Adrienne Walker.
1197
1198         Adds a drawTransformIsAnimating() and screenSpaceTransformIsAnimating()
1199         to the layer classes, and similar to the surface classes. These inherit
1200         the values from their parents in the same way that the transforms
1201         themselves do, and reflect if the layer's transform is being affected
1202         by some active animation.
1203
1204         These can be used in main-thread culling when determining if the layer's
1205         position is static in the given coordinate space or being animated.
1206
1207         Unit test: CCLayerTreeHostCommonTest.verifyAnimationsForRenderSurfaceHierarchy
1208
1209         * platform/graphics/chromium/LayerChromium.cpp:
1210         (WebCore::LayerChromium::LayerChromium):
1211         * platform/graphics/chromium/LayerChromium.h:
1212         (LayerChromium):
1213         (WebCore::LayerChromium::drawTransformIsAnimating):
1214         (WebCore::LayerChromium::setDrawTransformIsAnimating):
1215         (WebCore::LayerChromium::screenSpaceTransformIsAnimating):
1216         (WebCore::LayerChromium::setScreenSpaceTransformIsAnimating):
1217         * platform/graphics/chromium/RenderSurfaceChromium.cpp:
1218         (WebCore::RenderSurfaceChromium::RenderSurfaceChromium):
1219         * platform/graphics/chromium/RenderSurfaceChromium.h:
1220         (WebCore::RenderSurfaceChromium::targetSurfaceTransformsAreAnimating):
1221         (WebCore::RenderSurfaceChromium::setTargetSurfaceTransformsAreAnimating):
1222         (WebCore::RenderSurfaceChromium::screenSpaceTransformsAreAnimating):
1223         (WebCore::RenderSurfaceChromium::setScreenSpaceTransformsAreAnimating):
1224         (RenderSurfaceChromium):
1225         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
1226         (WebCore::CCLayerImpl::CCLayerImpl):
1227         * platform/graphics/chromium/cc/CCLayerImpl.h:
1228         (CCLayerImpl):
1229         (WebCore::CCLayerImpl::drawTransformIsAnimating):
1230         (WebCore::CCLayerImpl::setDrawTransformIsAnimating):
1231         (WebCore::CCLayerImpl::screenSpaceTransformIsAnimating):
1232         (WebCore::CCLayerImpl::setScreenSpaceTransformIsAnimating):
1233         * platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp:
1234         (WebCore::subtreeShouldBeSkipped):
1235         (WebCore::calculateDrawTransformsAndVisibilityInternal):
1236         * platform/graphics/chromium/cc/CCRenderSurface.cpp:
1237         (WebCore::CCRenderSurface::CCRenderSurface):
1238         * platform/graphics/chromium/cc/CCRenderSurface.h:
1239         (WebCore::CCRenderSurface::targetSurfaceTransformsAreAnimating):
1240         (WebCore::CCRenderSurface::setTargetSurfaceTransformsAreAnimating):
1241         (WebCore::CCRenderSurface::screenSpaceTransformsAreAnimating):
1242         (WebCore::CCRenderSurface::setScreenSpaceTransformsAreAnimating):
1243         (CCRenderSurface):
1244
1245 2012-03-18  Pratik Solanki  <psolanki@apple.com>
1246
1247         Fix compile when FULLSCREEN_API is not enabled on Mac
1248         https://bugs.webkit.org/show_bug.cgi?id=81474
1249
1250         Reviewed by Ada Chan.
1251
1252         Guard the full screen api code inside ENABLE(FULLSCREEN_API).
1253
1254         No new tests because no functional changes.
1255
1256         * platform/mac/WebCoreFullScreenWindow.h:
1257         * platform/mac/WebCoreFullScreenWindow.mm:
1258
1259 2012-03-18  Kentaro Hara  <haraken@chromium.org>
1260
1261         Change the initial buffer size of a plain text
1262         https://bugs.webkit.org/show_bug.cgi?id=81192
1263
1264         Reviewed by Dimitri Glazkov.
1265
1266         r111109 changed the initial buffer size of a plain text
1267         from 1<<16 to 1<<15 in Chromium/Mac only, for the following reasons:
1268
1269         - As far as I experimented locally, while 1<<15 is better than 1<<16 in Chromium/Mac,
1270         1<<15 and 1<<16 are the same in AppleWebKit/Mac and Chromium/Linux (their performance
1271         "gap" exists at between 1<<17 and 1<<18).
1272         - The reason why I changed 1<<16 to 1<<15 in Chromium/Mac only is that
1273         the value highly depends on the underlying malloc system and I was a bit afraid
1274         that changing to 1<<15 _might_ cause unintentional performance regression in some
1275         platform.
1276
1277         That being said, it seems that 1<<15 would not be worse than 1<<16 in all platforms,
1278         and we should just keep the value consistent. In the first place, according to anttik
1279         (who wrote 1<<16 a long time ago), there was no strong reason for 1<<16.
1280
1281         Based on these observations (See https://bugs.webkit.org/show_bug.cgi?id=81192
1282         for more details), this patch unifies the value to 1<<15 in all platforms.
1283
1284         No tests. No change in behavior.
1285
1286         * editing/TextIterator.cpp:
1287         (WebCore::plainTextToMallocAllocatedBuffer):
1288
1289 2012-02-13  Robert Hogan  <robert@webkit.org>
1290
1291         CSS 2.1 failure: eof-003.htm fails
1292         https://bugs.webkit.org/show_bug.cgi?id=78538
1293
1294         Reviewed by Antti Koivisto.
1295
1296         Tests: css2.1/20110323/eof-001.htm
1297                css2.1/20110323/eof-003.htm
1298                css2.1/20110323/eof-004.htm
1299                css2.1/20110323/eof-005.htm
1300                css2.1/20110323/eof-006.htm
1301                css2.1/20110323/eof-007.htm
1302
1303         This patch fixes eof-003.htm, eof-005.htm and eof-006.htm. The other eof-* tests already pass.
1304
1305         * css/CSSGrammar.y: Allow EOF as well as ';' to terminate import rules.
1306                             This should probably be done for other rules in a separate patch.
1307         * css/CSSParser.cpp:
1308         (WebCore::CSSParser::checkAndSkipString): Allow strings to end with EOF.
1309         (WebCore::CSSParser::parseString): ditto
1310
1311 2012-03-17  David Reveman  <reveman@chromium.org>
1312
1313         [Chromium] PlatformContextSkia::m_drawingToImageBuffer is not correctly set when using per-tile painting.
1314         https://bugs.webkit.org/show_bug.cgi?id=81463
1315
1316         Reviewed by James Robinson.
1317
1318         Call PlatformContextSkia::setDrawingToImageBuffer() from
1319         SkPictureCanvasLayerTextureUpdater::prepareToUpdate so that sub-pixel
1320         text rendering is not used incorrectly with per-tile painting.
1321
1322         No new tests.
1323
1324         * platform/graphics/chromium/SkPictureCanvasLayerTextureUpdater.cpp:
1325         (WebCore::SkPictureCanvasLayerTextureUpdater::prepareToUpdate):
1326
1327 2012-03-17  Robert Kroeger  <rjkroege@chromium.org>
1328
1329         [chromium] Make pixel-accurate wheel scrolling be unanimated
1330         https://bugs.webkit.org/show_bug.cgi?id=81457
1331
1332         Reviewed by James Robinson.
1333
1334         * platform/ScrollAnimatorNone.cpp:
1335         (WebCore::ScrollAnimatorNone::scroll):
1336
1337 2012-03-17  Rob Buis  <rbuis@rim.com>
1338
1339         [BlackBerry] Implement openTemporaryFile in FileSystem
1340         https://bugs.webkit.org/show_bug.cgi?id=81373
1341
1342         Reviewed by George Staikos.
1343
1344         Move the Efl implementation to Posix, this way BlackBerry port can reuse it.
1345
1346         * platform/blackberry/FileSystemBlackBerry.cpp:
1347         * platform/efl/FileSystemEfl.cpp:
1348         * platform/posix/FileSystemPOSIX.cpp:
1349         (WebCore::openTemporaryFile):
1350         (WebCore):
1351
1352 2012-03-17  Joe Thomas  <joethomas@motorola.com>
1353
1354         move calc*Value functions out from Length (and platform)
1355         https://bugs.webkit.org/show_bug.cgi?id=80897
1356
1357         Moving the Length calc*Value functions out from Length structure and also from /WebCore/platform/ folder.
1358         This helps to avoid the layering violation while length calculation. Otherwise layer violation can be avoided only by adding a virtual interface(bug 27160).
1359
1360         Reviewed by Antti Koivisto.
1361
1362         * GNUmakefile.list.am: Build system changes for adding new files.
1363         * Target.pri: Ditto.
1364         * WebCore.gypi: Ditto.
1365         * WebCore.vcproj/WebCore.vcproj: Ditto.
1366         * WebCore.xcodeproj/project.pbxproj: Ditto.
1367         * accessibility/gtk/WebKitAccessibleInterfaceText.cpp:
1368         (getAttributeSetForAccessibilityObject):
1369         * css/CSSComputedStyleDeclaration.cpp:
1370         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1371         * css/LengthFunctions.h: Added. Moved calc*Value functions of Length.
1372         (WebCore):
1373         (WebCore::calculateMinimumValue):
1374         (WebCore::calculateValue):
1375         (WebCore::calculateFloatValue):
1376         * dom/Document.cpp:
1377         (WebCore::Document::pageSizeAndMarginsInPixels):
1378         * html/HTMLAreaElement.cpp:
1379         (WebCore::HTMLAreaElement::getRegion):
1380         * platform/CalculationValue.h:
1381         (WebCore::CalcExpressionLength::evaluate):
1382         * platform/Length.h: Removed the calc*Value functions from Length structure.
1383         (Length):
1384         (WebCore::Length::getFloatValue):
1385         (WebCore::Length::getIntValue):
1386         * platform/graphics/ca/mac/PlatformCAAnimationMac.mm:
1387         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
1388         (PlatformCALayer::setFilters):
1389         * platform/graphics/chromium/cc/CCRenderSurfaceFilters.cpp:
1390         (WebCore::CCRenderSurfaceFilters::apply):
1391         * platform/graphics/filters/FilterOperations.cpp:
1392         (WebCore::FilterOperations::getOutsets):
1393         * platform/graphics/transforms/PerspectiveTransformOperation.cpp:
1394         (WebCore::PerspectiveTransformOperation::blend):
1395         * platform/graphics/transforms/PerspectiveTransformOperation.h:
1396         (WebCore::PerspectiveTransformOperation::isIdentity):
1397         (WebCore::PerspectiveTransformOperation::apply):
1398         * platform/graphics/transforms/TranslateTransformOperation.h:
1399         (WebCore::TranslateTransformOperation::x):
1400         (WebCore::TranslateTransformOperation::y):
1401         (WebCore::TranslateTransformOperation::z):
1402         (WebCore::TranslateTransformOperation::isIdentity):
1403         * platform/win/PopupMenuWin.cpp:
1404         (WebCore::PopupMenuWin::paint):
1405         * rendering/AutoTableLayout.cpp:
1406         (WebCore::AutoTableLayout::layout):
1407         * rendering/FilterEffectRenderer.cpp:
1408         (WebCore::FilterEffectRenderer::build):
1409         * rendering/FixedTableLayout.cpp:
1410         (WebCore::FixedTableLayout::layout):
1411         * rendering/RenderBlock.cpp:
1412         (WebCore::RenderBlock::textIndentOffset):
1413         (WebCore::RenderBlock::computeInlinePreferredLogicalWidths):
1414         * rendering/RenderBox.cpp:
1415         (WebCore::RenderBox::reflectionOffset):
1416         (WebCore::RenderBox::clipRect):
1417         (WebCore::RenderBox::computeLogicalWidthInRegion):
1418         (WebCore::RenderBox::computeLogicalWidthInRegionUsing):
1419         (WebCore::RenderBox::computeInlineDirectionMargins):
1420         (WebCore::RenderBox::computePercentageLogicalHeight):
1421         (WebCore::RenderBox::computeReplacedLogicalWidthUsing):
1422         (WebCore::RenderBox::computeReplacedLogicalHeightUsing):
1423         (WebCore::RenderBox::availableLogicalHeightUsing):
1424         (WebCore::RenderBox::computeBlockDirectionMargins):
1425         (WebCore::RenderBox::computePositionedLogicalWidthUsing):
1426         (WebCore::RenderBox::computePositionedLogicalHeightUsing):
1427         (WebCore::RenderBox::computePositionedLogicalWidthReplaced):
1428         (WebCore::RenderBox::computePositionedLogicalHeightReplaced):
1429         * rendering/RenderBoxModelObject.cpp:
1430         (WebCore::RenderBoxModelObject::relativePositionOffsetX):
1431         (WebCore::RenderBoxModelObject::relativePositionOffsetY):
1432         (WebCore::RenderBoxModelObject::paddingTop):
1433         (WebCore::RenderBoxModelObject::paddingBottom):
1434         (WebCore::RenderBoxModelObject::paddingLeft):
1435         (WebCore::RenderBoxModelObject::paddingRight):
1436         (WebCore::RenderBoxModelObject::paddingBefore):
1437         (WebCore::RenderBoxModelObject::paddingAfter):
1438         (WebCore::RenderBoxModelObject::paddingStart):
1439         (WebCore::RenderBoxModelObject::paddingEnd):
1440         (WebCore::RenderBoxModelObject::calculateFillTileSize):
1441         (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
1442         (WebCore::computeBorderImageSide):
1443         (WebCore::RenderBoxModelObject::paintNinePieceImage):
1444         * rendering/RenderFlexibleBox.cpp:
1445         (WebCore::RenderFlexibleBox::preferredMainAxisContentExtentForChild):
1446         (WebCore::RenderFlexibleBox::computeMainAxisPreferredSizes):
1447         (WebCore::RenderFlexibleBox::runFreeSpaceAllocationAlgorithm):
1448         * rendering/RenderFrameSet.cpp:
1449         (WebCore::RenderFrameSet::layOutAxis):
1450         * rendering/RenderInline.cpp:
1451         (WebCore::computeMargin):
1452         * rendering/RenderLayer.cpp:
1453         (WebCore::RenderLayer::perspectiveTransform):
1454         (WebCore::RenderLayer::perspectiveOrigin):
1455         * rendering/RenderLayerBacking.cpp:
1456         (WebCore::RenderLayerBacking::computeTransformOrigin):
1457         (WebCore::RenderLayerBacking::computePerspectiveOrigin):
1458         * rendering/RenderMarquee.cpp:
1459         (WebCore::RenderMarquee::timerFired):
1460         * rendering/RenderMenuList.cpp:
1461         (WebCore::RenderMenuList::updateOptionsWidth):
1462         * rendering/RenderObject.cpp:
1463         (WebCore::RenderObject::repaintAfterLayoutIfNeeded):
1464         * rendering/RenderReplaced.cpp:
1465         (WebCore::RenderReplaced::computeReplacedLogicalWidth):
1466         * rendering/RenderScrollbarPart.cpp:
1467         (WebCore::calcScrollbarThicknessUsing):
1468         (WebCore::RenderScrollbarPart::computeScrollbarWidth):
1469         (WebCore::RenderScrollbarPart::computeScrollbarHeight):
1470         * rendering/RenderTable.cpp:
1471         (WebCore::RenderTable::computeLogicalWidth):
1472         (WebCore::RenderTable::convertStyleLogicalWidthToComputedWidth):
1473         * rendering/RenderTableCell.cpp:
1474         (WebCore::RenderTableCell::logicalHeightForRowSizing):
1475         * rendering/RenderTableSection.cpp:
1476         (WebCore::RenderTableSection::calcRowLogicalHeight):
1477         * rendering/RenderText.h:
1478         (WebCore::RenderText::marginLeft):
1479         (WebCore::RenderText::marginRight):
1480         * rendering/RootInlineBox.cpp:
1481         (WebCore::RootInlineBox::verticalPositionForBox):
1482         * rendering/style/RenderStyle.cpp:
1483         (WebCore::RenderStyle::applyTransform):
1484         (WebCore::calcRadiiFor):
1485         * rendering/style/RenderStyle.h:
1486         * rendering/svg/RenderSVGRoot.cpp:
1487         (WebCore::RenderSVGRoot::computeIntrinsicRatioInformation):
1488         (WebCore::resolveLengthAttributeForSVG):
1489         * svg/SVGSVGElement.cpp:
1490         (WebCore::SVGSVGElement::currentViewBoxRect):
1491         (WebCore::SVGSVGElement::currentViewportSize):
1492         * svg/graphics/SVGImage.cpp:
1493         (WebCore::SVGImage::computeIntrinsicDimensions):
1494
1495 2012-03-17  Nikolas Zimmermann  <nzimmermann@rim.com>
1496
1497         Enable animVal support for SVGNumberOptionalNumber
1498         https://bugs.webkit.org/show_bug.cgi?id=81448
1499
1500         Reviewed by Antti Koivisto.
1501
1502         Enable animVal support for SVGNumberOptionalNumber. Its a special case as two SVG DOM properties
1503         eg. stdDeviationX/stdDeviationY are mapped to a single XML attribute: SVGNames::stdDeviationAttr.
1504
1505         When animating properties like this, both animVal wrappers need to reflect changes.
1506         Generalize the current animVal code to support more than one SVGAnimatedProperty that gets
1507         animated for a single attributeName. This allows us to remove SVGAnimatedType::variantValue/setVariantValue
1508         which paves the way for removing SVGGenericAnimatedType from even more places.
1509
1510         Covered by existing tests.
1511
1512         * svg/SVGAnimateElement.cpp:
1513         (WebCore::SVGAnimateElement::SVGAnimateElement):
1514         (WebCore::SVGAnimateElement::calculateAnimatedValue):
1515         (WebCore::SVGAnimateElement::resetToBaseValue):
1516         (WebCore::SVGAnimateElement::targetElementWillChange):
1517         * svg/SVGAnimateElement.h:
1518         (SVGAnimateElement):
1519         * svg/SVGAnimatedLength.cpp:
1520         (WebCore::SVGAnimatedLengthAnimator::constructFromBaseValue):
1521         (WebCore):
1522         (WebCore::SVGAnimatedLengthAnimator::resetAnimatedTypeToBaseValue):
1523         * svg/SVGAnimatedLength.h:
1524         (SVGAnimatedLengthAnimator):
1525         * svg/SVGAnimatedLengthList.cpp:
1526         (WebCore::SVGAnimatedLengthListAnimator::constructFromBaseValue):
1527         (WebCore):
1528         (WebCore::SVGAnimatedLengthListAnimator::resetAnimatedTypeToBaseValue):
1529         * svg/SVGAnimatedLengthList.h:
1530         (SVGAnimatedLengthListAnimator):
1531         * svg/SVGAnimatedNumber.cpp:
1532         (WebCore::SVGAnimatedNumberAnimator::constructFromBaseValue):
1533         (WebCore):
1534         (WebCore::SVGAnimatedNumberAnimator::resetAnimatedTypeToBaseValue):
1535         * svg/SVGAnimatedNumber.h:
1536         (SVGAnimatedNumberAnimator):
1537         * svg/SVGAnimatedNumberList.cpp:
1538         (WebCore::SVGAnimatedNumberListAnimator::constructFromBaseValue):
1539         (WebCore):
1540         (WebCore::SVGAnimatedNumberListAnimator::resetAnimatedTypeToBaseValue):
1541         * svg/SVGAnimatedNumberList.h:
1542         (SVGAnimatedNumberListAnimator):
1543         * svg/SVGAnimatedNumberOptionalNumber.cpp:
1544         (WebCore::SVGAnimatedNumberOptionalNumberAnimator::constructFromBaseValue):
1545         (WebCore):
1546         (WebCore::SVGAnimatedNumberOptionalNumberAnimator::resetAnimatedTypeToBaseValue):
1547         * svg/SVGAnimatedNumberOptionalNumber.h:
1548         (WebCore):
1549         (SVGAnimatedNumberOptionalNumberAnimator):
1550         * svg/SVGAnimatedTransformList.cpp:
1551         (WebCore::SVGAnimatedTransformListAnimator::constructFromBaseValue):
1552         (WebCore::SVGAnimatedTransformListAnimator::resetAnimatedTypeToBaseValue):
1553         (WebCore):
1554         * svg/SVGAnimatedTransformList.h:
1555         (SVGAnimatedTransformListAnimator):
1556         * svg/SVGAnimatedType.cpp:
1557         (WebCore::SVGAnimatedType::supportsAnimVal):
1558         * svg/SVGAnimatedType.h:
1559         (SVGAnimatedType):
1560         * svg/SVGAnimatedTypeAnimator.h:
1561         (SVGAnimatedTypeAnimator):
1562         (WebCore::SVGAnimatedTypeAnimator::constructFromBaseValue):
1563         (WebCore::SVGAnimatedTypeAnimator::resetAnimatedTypeToBaseValue):
1564         (WebCore::SVGAnimatedTypeAnimator::currentBaseValueVariant):
1565         (WebCore::SVGAnimatedTypeAnimator::constructFromOneBaseValue):
1566         (WebCore::SVGAnimatedTypeAnimator::resetAnimatedTypeFromOneBaseValue):
1567         (WebCore::SVGAnimatedTypeAnimator::constructFromTwoBaseValues):
1568         (WebCore::SVGAnimatedTypeAnimator::resetAnimatedTypeFromTwoBaseValues):
1569         * svg/SVGAnimationElement.cpp:
1570         (WebCore::findMatchingAnimatedProperties):
1571         (WebCore::SVGAnimationElement::applyAnimatedValue):
1572         (WebCore::notifyAnimatedPropertyAboutAnimationBeginEnd):
1573         (WebCore::SVGAnimationElement::animationStarted):
1574         (WebCore::SVGAnimationElement::animationEnded):
1575         (WebCore::SVGAnimationElement::animatedPropertiesForType):
1576         * svg/SVGAnimationElement.h:
1577         * svg/properties/SVGAnimatedListPropertyTearOff.h:
1578         (WebCore::SVGAnimatedListPropertyTearOff::currentBaseValueVariant):
1579         (WebCore::SVGAnimatedListPropertyTearOff::animationStarted):
1580         * svg/properties/SVGAnimatedProperty.h:
1581         (SVGAnimatedProperty):
1582         * svg/properties/SVGAnimatedPropertyTearOff.h:
1583         (WebCore::SVGAnimatedPropertyTearOff::currentBaseValueVariant):
1584         (WebCore::SVGAnimatedPropertyTearOff::animationStarted):
1585         * svg/properties/SVGAnimatedStaticPropertyTearOff.h:
1586         (WebCore::SVGAnimatedStaticPropertyTearOff::currentBaseValueVariant):
1587         (WebCore::SVGAnimatedStaticPropertyTearOff::animationStarted):
1588
1589 2012-03-12  Philippe Normand  <pnormand@igalia.com>
1590
1591         [GStreamer] run AudioFileReader in a nested loop
1592         https://bugs.webkit.org/show_bug.cgi?id=80823
1593
1594         Reviewed by Martin Robinson.
1595
1596         Use a separate main loop for the file reader, this approach is
1597         much cleaner than polling the default GLib main context.
1598
1599         * platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
1600         (AudioFileReader):
1601         (WebCore::enteredMainLoopCallback):
1602         (WebCore):
1603         (WebCore::AudioFileReader::AudioFileReader):
1604         (WebCore::AudioFileReader::handleMessage):
1605         (WebCore::AudioFileReader::start):
1606         (WebCore::AudioFileReader::createBus):
1607
1608 2012-02-07  Robert Hogan  <robert@webkit.org>
1609
1610         CSS 2.1 failure: fixed-table-layout-013 and fixed-table-layout-015 fail
1611         https://bugs.webkit.org/show_bug.cgi?id=78027
1612
1613         Reviewed by Julien Chaffraix.
1614
1615         Both of these test the (slightly implicit) rule that width set on column-groups cannot
1616         affect the width of columns in a fixed layout table: http://www.w3.org/TR/CSS21/tables.html#fixed-table-layout
1617         FF, Opera and IE all pass these two tests.
1618
1619         Tests: css2.1/20110323/fixed-table-layout-013.htm
1620                css2.1/20110323/fixed-table-layout-015.htm
1621                fast/table/fixed-table-layout-toggle-colwidth.html
1622
1623         * rendering/FixedTableLayout.cpp:
1624         (WebCore::nextCol): A helper function for finding the next column along.
1625         (WebCore::FixedTableLayout::calcWidthArray): Ignore width specified by column groups.
1626         * rendering/RenderTableCol.h:
1627         (WebCore::RenderTableCol::isTableColGroup): Convenience function for identifying column groups.
1628
1629 2012-03-16  Leo Yang  <leo.yang@torchmobile.com.cn>
1630
1631         [BlackBerry] Add BlackBerry to NavigatorBase.cpp
1632         https://bugs.webkit.org/show_bug.cgi?id=81303
1633
1634         Reviewed by Rob Buis.
1635
1636         * page/NavigatorBase.cpp:
1637
1638 2012-03-16  Leo Yang  <leo.yang@torchmobile.com.cn>
1639
1640         [BlackBerry] Add typedef of DragDataRef for blackberry
1641         https://bugs.webkit.org/show_bug.cgi?id=81301
1642
1643         Reviewed by Rob Buis.
1644
1645         * platform/DragData.h:
1646
1647 2012-03-16  James Robinson  <jamesr@chromium.org>
1648
1649         [chromium] Unify the drawing logic for different layer types that output textures to the compositor
1650         https://bugs.webkit.org/show_bug.cgi?id=81286
1651
1652         Reviewed by Adrienne Walker.
1653
1654         Currently canvas 2d, webgl, and plugin layers all export a texture to the compositor that then needs to be
1655         drawn.  There are a small set of operations that can be applied to the texture at draw time - do a Y flip,
1656         stretch a subrect to the layer bounds, set the blend mode etc but they are fundamentally the same thing. This
1657         collapses the nearly-redundant code into a single impl-side layer type for a texture-backed layer that can
1658         handle the union of the bits needed for each layer type.
1659
1660         Canvas 2d, WebGL and plugin composited rendering are all covered by layout tests.
1661
1662         * WebCore.gypi:
1663         * platform/graphics/chromium/Canvas2DLayerChromium.cpp:
1664         (WebCore::Canvas2DLayerChromium::pushPropertiesTo):
1665         * platform/graphics/chromium/CanvasLayerChromium.cpp:
1666         (WebCore::CanvasLayerChromium::createCCLayerImpl):
1667         * platform/graphics/chromium/LayerRendererChromium.cpp:
1668         (WebCore::LayerRendererChromium::drawQuad):
1669         (WebCore::TexStretchTextureProgramBinding::set):
1670         (WebCore::TexTransformTextureProgramBinding::set):
1671         (WebCore::LayerRendererChromium::drawTextureQuad):
1672         (WebCore::LayerRendererChromium::textureLayerProgramFlip):
1673         (WebCore::LayerRendererChromium::textureLayerProgramStretch):
1674         (WebCore::LayerRendererChromium::textureLayerProgramStretchFlip):
1675         (WebCore::LayerRendererChromium::textureLayerTexRectProgram):
1676         (WebCore::LayerRendererChromium::textureLayerTexRectProgramFlip):
1677         (WebCore::LayerRendererChromium::cleanupSharedObjects):
1678         * platform/graphics/chromium/LayerRendererChromium.h:
1679         (WebCore):
1680         (LayerRendererChromium):
1681         * platform/graphics/chromium/PluginLayerChromium.cpp:
1682         (WebCore::PluginLayerChromium::PluginLayerChromium):
1683         (WebCore::PluginLayerChromium::createCCLayerImpl):
1684         (WebCore::PluginLayerChromium::setIOSurfaceProperties):
1685         (WebCore::PluginLayerChromium::pushPropertiesTo):
1686         * platform/graphics/chromium/PluginLayerChromium.h:
1687         (PluginLayerChromium):
1688         * platform/graphics/chromium/WebGLLayerChromium.cpp:
1689         (WebCore::WebGLLayerChromium::pushPropertiesTo):
1690         * platform/graphics/chromium/cc/CCCanvasDrawQuad.cpp: Removed.
1691         * platform/graphics/chromium/cc/CCCanvasDrawQuad.h: Removed.
1692         * platform/graphics/chromium/cc/CCCanvasLayerImpl.cpp: Removed.
1693         * platform/graphics/chromium/cc/CCCanvasLayerImpl.h: Removed.
1694         * platform/graphics/chromium/cc/CCDrawQuad.cpp:
1695         (WebCore::CCDrawQuad::toTextureDrawQuad):
1696         * platform/graphics/chromium/cc/CCDrawQuad.h:
1697         (WebCore):
1698         (CCDrawQuad):
1699         * platform/graphics/chromium/cc/CCTextureDrawQuad.cpp: Renamed from Source/WebCore/platform/graphics/chromium/cc/CCPluginDrawQuad.cpp.
1700         (WebCore):
1701         (WebCore::CCTextureDrawQuad::create):
1702         (WebCore::CCTextureDrawQuad::CCTextureDrawQuad):
1703         * platform/graphics/chromium/cc/CCTextureDrawQuad.h: Renamed from Source/WebCore/platform/graphics/chromium/cc/CCPluginDrawQuad.h.
1704         (WebCore):
1705         (CCTextureDrawQuad):
1706         (WebCore::CCTextureDrawQuad::textureId):
1707         (WebCore::CCTextureDrawQuad::hasAlpha):
1708         (WebCore::CCTextureDrawQuad::premultipliedAlpha):
1709         (WebCore::CCTextureDrawQuad::uvRect):
1710         (WebCore::CCTextureDrawQuad::flipped):
1711         (WebCore::CCTextureDrawQuad::ioSurfaceSize):
1712         (WebCore::CCTextureDrawQuad::ioSurfaceTextureId):
1713         * platform/graphics/chromium/cc/CCTextureLayerImpl.cpp: Renamed from Source/WebCore/platform/graphics/chromium/cc/CCPluginLayerImpl.cpp.
1714         (WebCore):
1715         (WebCore::CCTextureLayerImpl::CCTextureLayerImpl):
1716         (WebCore::CCTextureLayerImpl::~CCTextureLayerImpl):
1717         (WebCore::CCTextureLayerImpl::willDraw):
1718         (WebCore::CCTextureLayerImpl::appendQuads):
1719         (WebCore::CCTextureLayerImpl::dumpLayerProperties):
1720         (WebCore::CCTextureLayerImpl::didLoseContext):
1721         (WebCore::CCTextureLayerImpl::setIOSurfaceProperties):
1722         * platform/graphics/chromium/cc/CCTextureLayerImpl.h: Renamed from Source/WebCore/platform/graphics/chromium/cc/CCPluginLayerImpl.h.
1723         (WebCore):
1724         (CCTextureLayerImpl):
1725         (WebCore::CCTextureLayerImpl::create):
1726         (WebCore::CCTextureLayerImpl::textureId):
1727         (WebCore::CCTextureLayerImpl::setTextureId):
1728         (WebCore::CCTextureLayerImpl::setHasAlpha):
1729         (WebCore::CCTextureLayerImpl::setPremultipliedAlpha):
1730         (WebCore::CCTextureLayerImpl::setFlipped):
1731         (WebCore::CCTextureLayerImpl::setUVRect):
1732         (WebCore::CCTextureLayerImpl::layerTypeAsString):
1733
1734 2012-03-16  Martin Robinson  <mrobinson@igalia.com>
1735
1736         [Cairo] Text extent of shadowed text is calculated incorrectly
1737         https://bugs.webkit.org/show_bug.cgi?id=65035
1738
1739         Reviewed by Martin Robinson.
1740
1741         No new tests. This is already covered by fast/canvas/fillText-shadow.html.
1742
1743         Correct determine the size of rendered text using x and y bearing from the font
1744         extents.
1745
1746         * platform/graphics/cairo/FontCairo.cpp:
1747         (WebCore::drawGlyphsShadow): Use the x and y bearing to calculate text extents.
1748         This gives a more accurate sizing and avoids clipping the edges of the shadow.
1749
1750 2012-03-16  Kentaro Hara  <haraken@chromium.org>
1751
1752         [Chromium][Performance] Optimize innerText and outerText in Chromium/Mac
1753         https://bugs.webkit.org/show_bug.cgi?id=81192
1754
1755         Reviewed by Dimitri Glazkov.
1756
1757         This patch makes innerText and outerText 4 times faster on Chromium/Mac.
1758         A similar performance improvement will be also observed in APIs that are using
1759         TextIterator::plainText() (e.g. Editting, SpellChecker, Clipboard, Pasteboard etc).
1760
1761         Performance test: https://bugs.webkit.org/attachment.cgi?id=131989
1762
1763         - AppleWebKit/JavaScriptCore/Mac:
1764         div.innerText : 2978.4ms
1765         div.outerText : 2944.4ms
1766
1767         - Chromium/V8/Mac without the patch:
1768         div.innerText : 10050.8ms
1769         div.outerText : 10072.2ms
1770
1771         - Chromium/V8/Mac with the patch:
1772         div.innerText: 2536.4ms
1773         div.outerText: 2714ms
1774
1775         This patch just changes the initial buffer size of a plain text buffer on Chromium/Mac.
1776         As shown below, in my local Chromium/Mac environment the performance changes
1777         dramatically between 1<<15 and 1<<16, and in my local Chromium/Linux environment
1778         the performance changes between 1<<17 and 1<<18. I am not yet sure what determines
1779         these figures, but it seems there exists a performance gap at some point
1780         depending on a malloc mechanism.
1781
1782         - div.innerText results on Chromium/V8/Mac:
1783         WTF_TEXT_ITERATOR_BUFFER_INITIAL_CAPACITY = 1 << 14 ==> 2465.6 ms
1784         WTF_TEXT_ITERATOR_BUFFER_INITIAL_CAPACITY = 1 << 15 ==> 2447.2 ms   <--- after this patch
1785         WTF_TEXT_ITERATOR_BUFFER_INITIAL_CAPACITY = 1 << 16 ==> 10250.8 ms  <--- before this patch
1786         WTF_TEXT_ITERATOR_BUFFER_INITIAL_CAPACITY = 1 << 17 ==> 10278.2 ms
1787
1788         - div.innerText results on Chromium/V8/Linux:
1789         WTF_TEXT_ITERATOR_BUFFER_INITIAL_CAPACITY = 1 << 14 ==> 1569.8 ms
1790         WTF_TEXT_ITERATOR_BUFFER_INITIAL_CAPACITY = 1 << 15 ==> 1531.8 ms
1791         WTF_TEXT_ITERATOR_BUFFER_INITIAL_CAPACITY = 1 << 16 ==> 1543.2 ms  <--- before/after this patch
1792         WTF_TEXT_ITERATOR_BUFFER_INITIAL_CAPACITY = 1 << 17 ==> 1541.6 ms
1793         WTF_TEXT_ITERATOR_BUFFER_INITIAL_CAPACITY = 1 << 18 ==> 12540.8 ms
1794         WTF_TEXT_ITERATOR_BUFFER_INITIAL_CAPACITY = 1 << 19 ==> 12340.8 ms
1795
1796         * editing/TextIterator.cpp:
1797         (WebCore::plainTextToMallocAllocatedBuffer):
1798
1799 2012-03-16  Dmitry Titov  <dimich@chromium.org>
1800
1801         HTMLFrameElementBase::m_remainsAliveOnRemovalFromTree can be cleared without unloading the frame.
1802         https://bugs.webkit.org/show_bug.cgi?id=80766
1803
1804         Reviewed by Adam Barth.
1805
1806         * html/HTMLFrameElementBase.cpp:
1807         (WebCore::HTMLFrameElementBase::insertedIntoDocument):
1808         (WebCore::HTMLFrameElementBase::setRemainsAliveOnRemovalFromTree):
1809         if adoptNode() is called on a detached iframe or with a detached document,
1810         unload the iframe to avoid live iframe to hang around w/o being attached to
1811         a document.
1812
1813 2012-03-16  Joe Thomas  <joethomas@motorola.com>
1814
1815         Xcode project file is not sorted.
1816         https://bugs.webkit.org/show_bug.cgi?id=81439
1817
1818         Sorted the project file entries using sort-Xcode-project-file script.
1819
1820         Reviewed by Eric Seidel.
1821
1822         * WebCore.xcodeproj/project.pbxproj:
1823
1824 2012-03-16  Yael Aharon  <yael.aharon@nokia.com>
1825
1826         Unreviewed build fix after r111075.
1827         Correct the path of WebKitBlobBuilder.idl.
1828
1829         * DerivedSources.pri:
1830
1831 2012-03-16  David Levin  <levin@chromium.org>
1832
1833         Fix for test runs for non-chromium platforms.
1834
1835         * loader/cache/MemoryCache.cpp:
1836         (WebCore::memoryCache):
1837         (WebCore::MemoryCache::add):
1838         (WebCore::MemoryCache::revalidationFailed):
1839         (WebCore::MemoryCache::resourceForURL):
1840         (WebCore::MemoryCache::evict):
1841
1842 2012-03-16  Tony Chang  <tony@chromium.org>
1843
1844         Unreviewed, rolling out r111094.
1845         http://trac.webkit.org/changeset/111094
1846         https://bugs.webkit.org/show_bug.cgi?id=80882
1847
1848         broke test on chromium-win
1849
1850         * rendering/RenderFlexibleBox.cpp:
1851         (WebCore::RenderFlexibleBox::alignChildren):
1852         * rendering/RenderFlexibleBox.h:
1853         (RenderFlexibleBox):
1854
1855 2012-03-16  Anders Carlsson  <andersca@apple.com>
1856
1857         REGRESSION (r110737): Height element changes on scrolled page causes failure
1858         https://bugs.webkit.org/show_bug.cgi?id=81381
1859         <rdar://problem/11066006>
1860
1861         Reviewed by Sam Weinig.
1862
1863         Limit the fix made in r110737 to check if there's a rubber-band gesture in progress and only ignore the range if that is the case.
1864
1865         * platform/ScrollAnimator.h:
1866         (WebCore::ScrollAnimator::isRubberBandInProgress):
1867         (ScrollAnimator):
1868         * platform/ScrollView.cpp:
1869         (WebCore::ScrollView::updateScrollbars):
1870         * platform/mac/ScrollAnimatorMac.h:
1871         (ScrollAnimatorMac):
1872         * platform/mac/ScrollAnimatorMac.mm:
1873         (WebCore::ScrollAnimatorMac::isRubberBandInProgress):
1874         (WebCore):
1875         * platform/mac/ScrollElasticityController.h:
1876         (ScrollElasticityController):
1877         * platform/mac/ScrollElasticityController.mm:
1878         (WebCore::ScrollElasticityController::isRubberBandInProgress):
1879         (WebCore):
1880
1881 2012-03-16  Robert Kroeger  <rjkroege@chromium.org>
1882
1883         GestureTapDown needs to pin in-progress flings
1884         https://bugs.webkit.org/show_bug.cgi?id=80875
1885
1886         Reviewed by Adam Barth.
1887
1888         * page/EventHandler.cpp:
1889         (WebCore):
1890         (WebCore::EventHandler::handleGestureTapDown):
1891         * page/EventHandler.h:
1892         (EventHandler):
1893
1894 2012-03-16  Chris Rogers  <crogers@google.com>
1895
1896         Account for sample-rate in convolution normalization
1897         https://bugs.webkit.org/show_bug.cgi?id=81432
1898
1899         Reviewed by James Robinson.
1900
1901         * platform/audio/Reverb.cpp:
1902         (WebCore):
1903         (WebCore::calculateNormalizationScale):
1904         * webaudio/ConvolverNode.cpp:
1905         (WebCore::ConvolverNode::setBuffer):
1906
1907 2012-03-16  Tom Sepez  <tsepez@chromium.org>
1908
1909         Make V8 window.open.call(), window.open.showModalDialog() results more closely match JSC. 
1910         https://bugs.webkit.org/show_bug.cgi?id=81260
1911         https://bugs.webkit.org/show_bug.cgi?id=39897
1912
1913         Reviewed by Adam Barth.
1914
1915         Tested via http/tests/security/cross-frame-access-call.htm
1916
1917         * bindings/v8/custom/V8DOMWindowCustom.cpp:
1918         (WebCore::V8DOMWindow::showModalDialogCallback):
1919         (WebCore::V8DOMWindow::openCallback):
1920
1921 2012-03-16  Matt Lilek  <mrl@apple.com>
1922
1923         Use modern NSNumberFormatter API in LocalizedNumberMac.mm
1924         https://bugs.webkit.org/show_bug.cgi?id=81429
1925
1926         Reviewed by Dan Bernstein.
1927
1928         No new tests as no change in behavior.
1929
1930         * platform/text/mac/LocalizedNumberMac.mm:
1931         (WebCore::createFormatterForCurrentLocaleForDisplay):
1932
1933 2012-03-16  Tony Chang  <tony@chromium.org>
1934
1935         flex-item-align: stretch should only grow, never shrink
1936         https://bugs.webkit.org/show_bug.cgi?id=80882
1937
1938         Reviewed by Ojan Vafai.
1939
1940         New test cases in css3/flexbox/flex-align-stretch.html.
1941
1942         * rendering/RenderFlexibleBox.cpp:
1943         (WebCore::RenderFlexibleBox::alignChildren): Move stretch code into a separate function.
1944         (WebCore::RenderFlexibleBox::alignChildStretch): Add an early return if our height is shrinking.
1945         (WebCore):
1946         * rendering/RenderFlexibleBox.h:
1947         (RenderFlexibleBox):
1948
1949 2012-03-16  Raphael Kubo da Costa  <kubo@profusion.mobi>
1950
1951         [EFL] Unreviewed, fix build after r111041.
1952
1953         * platform/efl/RenderThemeEfl.cpp:
1954         (WebCore::RenderThemeEfl::emitMediaButtonSignal): Rename
1955         MediaFullscreenButton to MediaEnterFullscreenButton.
1956         (WebCore::RenderThemeEfl::paintMediaFullscreenButton): Ditto.
1957
1958 2012-03-16  Dmitry Lomov  <dslomov@google.com>
1959
1960         REGRESSION: DOMURL::revokeObjectURL accesses memoryCache on worker thread.
1961         https://bugs.webkit.org/show_bug.cgi?id=80889
1962         On worker threads, post a task to main thread to evict from cache.
1963         ASSERT that MemoryCache is only accessed from main thread.
1964
1965         Reviewed by David Levin.
1966
1967         * html/DOMURL.cpp:
1968         (WebCore::DOMURL::revokeObjectURL):
1969         * loader/cache/MemoryCache.cpp:
1970         (WebCore::memoryCache):
1971         (WebCore::MemoryCache::add):
1972         (WebCore::MemoryCache::revalidationFailed):
1973         (WebCore::MemoryCache::resourceForURL):
1974         (WebCore::MemoryCache::evict):
1975         (WebCore):
1976         (WebCore::MemoryCache::removeUrlFromCache):
1977         (WebCore::MemoryCache::removeUrlFromCacheImpl):
1978         * loader/cache/MemoryCache.h:
1979         (WebCore):
1980         (MemoryCache):
1981
1982 2012-03-16  Jacky Jiang  <zhajiang@rim.com>
1983
1984         [BlackBerry] Upstream ScriptControllerBlackBerry.cpp
1985         https://bugs.webkit.org/show_bug.cgi?id=81397
1986
1987         Reviewed by Rob Buis.
1988
1989         Initial upstream, no new tests.
1990
1991         * bindings/js/ScriptControllerBlackBerry.cpp: Added.
1992
1993 2012-03-16  Adam Barth  <abarth@webkit.org>
1994
1995         remove-body-during-body-replacement2.html is triggering crashes on all platforms
1996         https://bugs.webkit.org/show_bug.cgi?id=81374
1997
1998         Reviewed by Eric Seidel.
1999
2000         When overriding disconnectFrame, we need to call the base class version
2001         of the method so that it can clear the m_frame pointer.
2002
2003         Tests: This patch fixes a large number of crashes in tests.
2004
2005         * notifications/DOMWindowNotifications.cpp:
2006         (WebCore::DOMWindowNotifications::disconnectFrame):
2007
2008 2012-03-16  Leo Yang  <leo.yang@torchmobile.com.cn>
2009
2010         [BlackBerry] Upstream the BlackBerry change to platform/Widget.h
2011         https://bugs.webkit.org/show_bug.cgi?id=81304
2012
2013         Reviewed by Rob Buis.
2014
2015         typedefs of PlatformWidget and PlatformPageClient for the BlackBerry.
2016
2017         * platform/Widget.h:
2018
2019 2012-03-16  David Barton  <dbarton@mathscribe.com>
2020
2021         MathML internals - factor code for almost anonymous blocks
2022         https://bugs.webkit.org/show_bug.cgi?id=81387
2023
2024         Reviewed by Eric Seidel.
2025
2026         MathML uses "almost anonymous" blocks to layout parts of mathematical expressions. These
2027         will be converted to true anonymous blocks in a later patch. Here we factor out the code
2028         to create them into RenderMathMLBlock::createAlmostAnonymousBlock().
2029
2030         No new tests. Some tree dump output is modified for existing tests. <munder>, <mover>,
2031         and <munderover> renderers already used true anonymous blocks, so we change them to call
2032         RenderBlock::createAnonymousBlock(). In the other direction, <mroot>'s almost anonymous
2033         blocks are now made RenderMathMLBlock not just RenderBlock, in agreement with other
2034         current MathML renderers.
2035
2036         * rendering/mathml/RenderMathMLBlock.cpp:
2037         (WebCore::RenderMathMLBlock::createAlmostAnonymousBlock):
2038         * rendering/mathml/RenderMathMLBlock.h:
2039         (RenderMathMLBlock):
2040         (WebCore::RenderMathMLBlock::getBoxModelObjectWidth):
2041         * rendering/mathml/RenderMathMLFenced.cpp:
2042         (WebCore::RenderMathMLFenced::addChild):
2043         * rendering/mathml/RenderMathMLFraction.cpp:
2044         (WebCore::RenderMathMLFraction::updateFromElement):
2045             - improve some variable names
2046         (WebCore::RenderMathMLFraction::addChild):
2047         (WebCore::RenderMathMLFraction::layout):
2048         (WebCore::RenderMathMLFraction::paint):
2049         (WebCore::RenderMathMLFraction::baselinePosition):
2050         * rendering/mathml/RenderMathMLRoot.cpp:
2051         (WebCore::RenderMathMLRoot::addChild):
2052         * rendering/mathml/RenderMathMLSubSup.cpp:
2053         (WebCore::RenderMathMLSubSup::addChild):
2054         * rendering/mathml/RenderMathMLSubSup.h:
2055         * rendering/mathml/RenderMathMLUnderOver.cpp:
2056         (WebCore::RenderMathMLUnderOver::addChild):
2057
2058 2012-03-16  Levi Weintraub  <leviw@chromium.org>
2059
2060         Prepare RenderObject for FractionalLayoutUnits
2061         https://bugs.webkit.org/show_bug.cgi?id=81178
2062
2063         Reviewed by Eric Seidel.
2064
2065         This readies RenderObject to deal with FractionalLayoutUnits as a backend for the
2066         LayoutUnit abstraction.
2067
2068         No new tests. No change in behavior.
2069
2070         * rendering/RenderObject.cpp:
2071         (WebCore::RenderObject::pixelSnappedAbsoluteClippedOverflowRect): Convenience method to be
2072         used instead of absouluteClippedOverflowRect in platform code. Platform updates will come
2073         in a separate patch.
2074         (WebCore):
2075         (WebCore::RenderObject::repaintAfterLayoutIfNeeded): Borders remain ints when we move to
2076         sub-pixel layout. This adjusts border variables for this, and adds compiler fixes when
2077         using std::max and std::min with mixed int/LayoutUnits.
2078         (WebCore::RenderObject::adjustRectForOutlineAndShadow): Outlines, like borders, remain
2079         ints in the new sub-pixel world. Using variables that reflect that.
2080         * rendering/RenderObject.h:
2081         (RenderObject):
2082         (WebCore::adjustForAbsoluteZoom): Handles FractionalLayoutUnit values. Flooring is what
2083         JavaScript requires since this is used with values that must return ints.
2084         (WebCore): Adding FractionalLayoutUnit.h to support the new adjusteForAbsoluteZoom method.
2085
2086 2012-03-16  Brady Eidson  <beidson@apple.com>
2087
2088         <rdar://problem/11027997> and https://bugs.webkit.org/show_bug.cgi?id=81412
2089         REGRESSION (r107435) Copy a link and paste to Mail: Nothing is pasted
2090
2091         Reviewed by Geoff Garen.
2092
2093         WebKit API test WebViewCanPasteURL.mm added.
2094
2095         * WebCore.exp.in:
2096
2097         Add a strategy method specifically for getting the URL:
2098         * platform/PasteboardStrategy.h:
2099
2100         Use that strategy method when creating the fragment for a URL:
2101         * platform/mac/PasteboardMac.mm:
2102         (WebCore::Pasteboard::documentFragment):
2103
2104         Add a platform pasteboard accessor to "do the right thing" for getting a URL:
2105         * platform/PlatformPasteboard.h:
2106         * platform/mac/PlatformPasteboardMac.mm:
2107         (WebCore::PlatformPasteboard::url):
2108
2109 2012-03-16  Joseph Pecoraro  <pecoraro@apple.com>
2110
2111         <http://webkit.org/b/81380> clang warning unused variable when ENABLE(TEXT_CARET) is disabled
2112
2113         Reviewed by Dan Bernstein.
2114
2115         * editing/FrameSelection.cpp:
2116         (WebCore::FrameSelection::recomputeCaretRect):
2117         Put the variable inside of a guard because it is only
2118         used inside of a guard.
2119
2120 2012-03-16  Andreas Kling  <kling@webkit.org>
2121
2122         Shrink BorderValue.
2123         <http://webkit.org/b/69521>
2124
2125         Reviewed by Anders Carlsson.
2126
2127         Split BorderValue's Color member into RGBA32/bool buddies and stash the bool in
2128         the BorderValue bitfield.
2129
2130         This shrinks BorderValue by 4 bytes, in turn shrinking BorderData by 16 bytes.
2131         Altogether this yields ~800 kB in reduced memory consumption when viewing the full
2132         HTML5 spec at <http://whatwg.org/c>
2133
2134         * rendering/style/BorderValue.h:
2135         (WebCore::BorderValue::BorderValue):
2136         (WebCore::BorderValue::isTransparent):
2137         (WebCore::BorderValue::operator==):
2138         (BorderValue):
2139         (WebCore::BorderValue::setColor):
2140         (WebCore::BorderValue::color):
2141         * rendering/style/OutlineValue.h:
2142         (WebCore::OutlineValue::operator==):
2143         * rendering/style/RenderStyle.cpp:
2144         (SameSizeAsBorderValue):
2145         * rendering/style/RenderStyle.h:
2146
2147 2012-03-16  Mark Pilgrim  <pilgrim@chromium.org>
2148
2149         Moves remaining filesystem files to Modules/filesystem/
2150         https://bugs.webkit.org/show_bug.cgi?id=81353
2151
2152         Reviewed by Adam Barth.
2153
2154         No new tests, all existing tests pass.
2155
2156         * CMakeLists.txt:
2157         * DerivedSources.make:
2158         * DerivedSources.pri:
2159         * GNUmakefile.list.am:
2160         * Modules/filesystem/AsyncFileWriter.h: Copied from Source/WebCore/fileapi/AsyncFileWriter.h.
2161         * Modules/filesystem/AsyncFileWriterClient.h: Copied from Source/WebCore/fileapi/AsyncFileWriterClient.h.
2162         * Modules/filesystem/DOMFilePath.cpp: Copied from Source/WebCore/fileapi/DOMFilePath.cpp.
2163         * Modules/filesystem/DOMFilePath.h: Copied from Source/WebCore/fileapi/DOMFilePath.h.
2164         * Modules/filesystem/DOMFileSystem.cpp: Copied from Source/WebCore/fileapi/DOMFileSystem.cpp.
2165         * Modules/filesystem/DOMFileSystem.h: Copied from Source/WebCore/fileapi/DOMFileSystem.h.
2166         * Modules/filesystem/DOMFileSystem.idl: Copied from Source/WebCore/fileapi/DOMFileSystem.idl.
2167         * Modules/filesystem/DOMFileSystemBase.cpp: Copied from Source/WebCore/fileapi/DOMFileSystemBase.cpp.
2168         * Modules/filesystem/DOMFileSystemBase.h: Copied from Source/WebCore/fileapi/DOMFileSystemBase.h.
2169         * Modules/filesystem/DOMFileSystemSync.cpp: Copied from Source/WebCore/fileapi/DOMFileSystemSync.cpp.
2170         * Modules/filesystem/DOMFileSystemSync.h: Copied from Source/WebCore/fileapi/DOMFileSystemSync.h.
2171         * Modules/filesystem/DOMFileSystemSync.idl: Copied from Source/WebCore/fileapi/DOMFileSystemSync.idl.
2172         * Modules/filesystem/Entry.cpp: Copied from Source/WebCore/fileapi/Entry.cpp.
2173         * Modules/filesystem/Entry.h: Copied from Source/WebCore/fileapi/Entry.h.
2174         * Modules/filesystem/Entry.idl: Copied from Source/WebCore/fileapi/Entry.idl.
2175         * Modules/filesystem/EntryArray.cpp: Copied from Source/WebCore/fileapi/EntryArray.cpp.
2176         * Modules/filesystem/EntryArray.h: Copied from Source/WebCore/fileapi/EntryArray.h.
2177         * Modules/filesystem/EntryArray.idl: Copied from Source/WebCore/fileapi/EntryArray.idl.
2178         * Modules/filesystem/EntryArraySync.cpp: Copied from Source/WebCore/fileapi/EntryArraySync.cpp.
2179         * Modules/filesystem/EntryArraySync.h: Copied from Source/WebCore/fileapi/EntryArraySync.h.
2180         * Modules/filesystem/EntryArraySync.idl: Copied from Source/WebCore/fileapi/EntryArraySync.idl.
2181         * Modules/filesystem/EntryBase.cpp: Copied from Source/WebCore/fileapi/EntryBase.cpp.
2182         * Modules/filesystem/EntryBase.h: Copied from Source/WebCore/fileapi/EntryBase.h.
2183         * Modules/filesystem/EntryCallback.h: Copied from Source/WebCore/fileapi/EntryCallback.h.
2184         * Modules/filesystem/EntryCallback.idl: Copied from Source/WebCore/fileapi/EntryCallback.idl.
2185         * Modules/filesystem/EntrySync.cpp: Copied from Source/WebCore/fileapi/EntrySync.cpp.
2186         * Modules/filesystem/EntrySync.h: Copied from Source/WebCore/fileapi/EntrySync.h.
2187         * Modules/filesystem/EntrySync.idl: Copied from Source/WebCore/fileapi/EntrySync.idl.
2188         * Modules/filesystem/ErrorCallback.h: Copied from Source/WebCore/fileapi/ErrorCallback.h.
2189         * Modules/filesystem/ErrorCallback.idl: Copied from Source/WebCore/fileapi/ErrorCallback.idl.
2190         * Modules/filesystem/FileCallback.h: Copied from Source/WebCore/fileapi/FileCallback.h.
2191         * Modules/filesystem/FileCallback.idl: Copied from Source/WebCore/fileapi/FileCallback.idl.
2192         * Modules/filesystem/FileEntry.cpp: Copied from Source/WebCore/fileapi/FileEntry.cpp.
2193         * Modules/filesystem/FileEntry.h: Copied from Source/WebCore/fileapi/FileEntry.h.
2194         * Modules/filesystem/FileEntry.idl: Copied from Source/WebCore/fileapi/FileEntry.idl.
2195         * Modules/filesystem/FileEntrySync.cpp: Copied from Source/WebCore/fileapi/FileEntrySync.cpp.
2196         * Modules/filesystem/FileEntrySync.h: Copied from Source/WebCore/fileapi/FileEntrySync.h.
2197         * Modules/filesystem/FileEntrySync.idl: Copied from Source/WebCore/fileapi/FileEntrySync.idl.
2198         * Modules/filesystem/FileSystemCallback.h: Copied from Source/WebCore/fileapi/FileSystemCallback.h.
2199         * Modules/filesystem/FileSystemCallback.idl: Copied from Source/WebCore/fileapi/FileSystemCallback.idl.
2200         * Modules/filesystem/FileSystemCallbacks.cpp: Copied from Source/WebCore/fileapi/FileSystemCallbacks.cpp.
2201         * Modules/filesystem/FileSystemCallbacks.h: Copied from Source/WebCore/fileapi/FileSystemCallbacks.h.
2202         * Modules/filesystem/FileWriter.cpp: Copied from Source/WebCore/fileapi/FileWriter.cpp.
2203         * Modules/filesystem/FileWriter.h: Copied from Source/WebCore/fileapi/FileWriter.h.
2204         * Modules/filesystem/FileWriter.idl: Copied from Source/WebCore/fileapi/FileWriter.idl.
2205         * Modules/filesystem/FileWriterBase.cpp: Copied from Source/WebCore/fileapi/FileWriterBase.cpp.
2206         * Modules/filesystem/FileWriterBase.h: Copied from Source/WebCore/fileapi/FileWriterBase.h.
2207         * Modules/filesystem/FileWriterBaseCallback.h: Copied from Source/WebCore/fileapi/FileWriterBaseCallback.h.
2208         * Modules/filesystem/FileWriterCallback.h: Copied from Source/WebCore/fileapi/FileWriterCallback.h.
2209         * Modules/filesystem/FileWriterCallback.idl: Copied from Source/WebCore/fileapi/FileWriterCallback.idl.
2210         * Modules/filesystem/FileWriterSync.cpp: Copied from Source/WebCore/fileapi/FileWriterSync.cpp.
2211         * Modules/filesystem/FileWriterSync.h: Copied from Source/WebCore/fileapi/FileWriterSync.h.
2212         * Modules/filesystem/FileWriterSync.idl: Copied from Source/WebCore/fileapi/FileWriterSync.idl.
2213         * Modules/filesystem/LocalFileSystem.cpp: Copied from Source/WebCore/fileapi/LocalFileSystem.cpp.
2214         * Modules/filesystem/LocalFileSystem.h: Copied from Source/WebCore/fileapi/LocalFileSystem.h.
2215         * Modules/filesystem/Metadata.h: Copied from Source/WebCore/fileapi/Metadata.h.
2216         * Modules/filesystem/Metadata.idl: Copied from Source/WebCore/fileapi/Metadata.idl.
2217         * Modules/filesystem/MetadataCallback.h: Copied from Source/WebCore/fileapi/MetadataCallback.h.
2218         * Modules/filesystem/MetadataCallback.idl: Copied from Source/WebCore/fileapi/MetadataCallback.idl.
2219         * Modules/filesystem/SyncCallbackHelper.h: Copied from Source/WebCore/fileapi/SyncCallbackHelper.h.
2220         * Modules/filesystem/WebKitFlags.h: Copied from Source/WebCore/fileapi/WebKitFlags.h.
2221         * Modules/filesystem/WorkerContextFileSystem.cpp: Copied from Source/WebCore/fileapi/WorkerContextFileSystem.cpp.
2222         * Modules/filesystem/WorkerContextFileSystem.h: Copied from Source/WebCore/fileapi/WorkerContextFileSystem.h.
2223         * Modules/filesystem/WorkerContextFileSystem.idl: Copied from Source/WebCore/fileapi/WorkerContextFileSystem.idl.
2224         * Target.pri:
2225         * WebCore.gyp/WebCore.gyp:
2226         * WebCore.gypi:
2227         * WebCore.vcproj/WebCore.vcproj:
2228         * WebCore.xcodeproj/project.pbxproj:
2229         * fileapi/AsyncFileWriter.h: Removed.
2230         * fileapi/AsyncFileWriterClient.h: Removed.
2231         * fileapi/DOMFilePath.cpp: Removed.
2232         * fileapi/DOMFilePath.h: Removed.
2233         * fileapi/DOMFileSystem.cpp: Removed.
2234         * fileapi/DOMFileSystem.h: Removed.
2235         * fileapi/DOMFileSystem.idl: Removed.
2236         * fileapi/DOMFileSystemBase.cpp: Removed.
2237         * fileapi/DOMFileSystemBase.h: Removed.
2238         * fileapi/DOMFileSystemSync.cpp: Removed.
2239         * fileapi/DOMFileSystemSync.h: Removed.
2240         * fileapi/DOMFileSystemSync.idl: Removed.
2241         * fileapi/Entry.cpp: Removed.
2242         * fileapi/Entry.h: Removed.
2243         * fileapi/Entry.idl: Removed.
2244         * fileapi/EntryArray.cpp: Removed.
2245         * fileapi/EntryArray.h: Removed.
2246         * fileapi/EntryArray.idl: Removed.
2247         * fileapi/EntryArraySync.cpp: Removed.
2248         * fileapi/EntryArraySync.h: Removed.
2249         * fileapi/EntryArraySync.idl: Removed.
2250         * fileapi/EntryBase.cpp: Removed.
2251         * fileapi/EntryBase.h: Removed.
2252         * fileapi/EntryCallback.h: Removed.
2253         * fileapi/EntryCallback.idl: Removed.
2254         * fileapi/EntrySync.cpp: Removed.
2255         * fileapi/EntrySync.h: Removed.
2256         * fileapi/EntrySync.idl: Removed.
2257         * fileapi/ErrorCallback.h: Removed.
2258         * fileapi/ErrorCallback.idl: Removed.
2259         * fileapi/FileCallback.h: Removed.
2260         * fileapi/FileCallback.idl: Removed.
2261         * fileapi/FileEntry.cpp: Removed.
2262         * fileapi/FileEntry.h: Removed.
2263         * fileapi/FileEntry.idl: Removed.
2264         * fileapi/FileEntrySync.cpp: Removed.
2265         * fileapi/FileEntrySync.h: Removed.
2266         * fileapi/FileEntrySync.idl: Removed.
2267         * fileapi/FileSystemCallback.h: Removed.
2268         * fileapi/FileSystemCallback.idl: Removed.
2269         * fileapi/FileSystemCallbacks.cpp: Removed.
2270         * fileapi/FileSystemCallbacks.h: Removed.
2271         * fileapi/FileWriter.cpp: Removed.
2272         * fileapi/FileWriter.h: Removed.
2273         * fileapi/FileWriter.idl: Removed.
2274         * fileapi/FileWriterBase.cpp: Removed.
2275         * fileapi/FileWriterBase.h: Removed.
2276         * fileapi/FileWriterBaseCallback.h: Removed.
2277         * fileapi/FileWriterCallback.h: Removed.
2278         * fileapi/FileWriterCallback.idl: Removed.
2279         * fileapi/FileWriterSync.cpp: Removed.
2280         * fileapi/FileWriterSync.h: Removed.
2281         * fileapi/FileWriterSync.idl: Removed.
2282         * fileapi/LocalFileSystem.cpp: Removed.
2283         * fileapi/LocalFileSystem.h: Removed.
2284         * fileapi/Metadata.h: Removed.
2285         * fileapi/Metadata.idl: Removed.
2286         * fileapi/MetadataCallback.h: Removed.
2287         * fileapi/MetadataCallback.idl: Removed.
2288         * fileapi/SyncCallbackHelper.h: Removed.
2289         * fileapi/WebKitFlags.h: Removed.
2290         * fileapi/WorkerContextFileSystem.cpp: Removed.
2291         * fileapi/WorkerContextFileSystem.h: Removed.
2292         * fileapi/WorkerContextFileSystem.idl: Removed.
2293
2294 2012-03-16  Mark Pilgrim  <pilgrim@chromium.org>
2295
2296         Collapse ENABLE(BLOB)|ENABLE(FILE_SYSTEM) to just ENABLE(BLOB) in OperationNotAllowedException.idl
2297         https://bugs.webkit.org/show_bug.cgi?id=81391
2298
2299         Reviewed by Adam Barth.
2300
2301         No new tests, all existing tests pass.
2302
2303         * fileapi/OperationNotAllowedException.idl:
2304
2305 2012-03-16  Emil A Eklund  <eae@chromium.org>
2306
2307         Fix rounding and usage of LayoutUnits in RenderBoxModelObject
2308         https://bugs.webkit.org/show_bug.cgi?id=81057
2309
2310         Reviewed by Julien Chaffraix.
2311
2312         No new tests.
2313
2314         (WebCore):
2315         * rendering/RenderBoxModelObject.cpp:
2316         (WebCore::RenderBoxModelObject::pixelSnappedOffsetWidth):
2317         (WebCore::RenderBoxModelObject::pixelSnappedOffsetHeight):
2318         Fix implementation of pixelSnappedOffsetWidth/Height. The location
2319         parameter will be ignored until we enable subpixel support.
2320
2321         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
2322         Use ints for border widths.
2323         
2324         (WebCore::resolveWidthForRatio):
2325         (WebCore::resolveHeightForRatio):
2326         (WebCore::resolveAgainstIntrinsicWidthOrHeightAndRatio):
2327         (WebCore::resolveAgainstIntrinsicRatio):
2328         Change resolve*Ratio methods to operate on IntSizes as none of the
2329         callers need subpixel precision.
2330
2331         (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
2332         (WebCore::RenderBoxModelObject::paintNinePieceImage):
2333         Pixel snap paintRect when computing image geometry.
2334
2335 2012-03-16  Terry Anderson  <tdanderson@chromium.org>
2336
2337         100% height elements to not respond to vertical browser rescaling
2338         https://bugs.webkit.org/show_bug.cgi?id=43022
2339
2340         Reviewed by Julien Chaffraix.
2341
2342         Test: fast/replaced/vertical-resize-100percent-element.html
2343
2344         * rendering/RenderBox.cpp:
2345         (WebCore::RenderBox::computeReplacedLogicalHeightUsing):
2346             For the case where a replaced element has a percentage height,
2347             we update the entries in RenderBlock::gPercentHeightDescendantsMap
2348             corresponding to all ancestors of the replaced element.
2349
2350 2012-03-15  Daniel Cheng  <dcheng@chromium.org>
2351
2352         [chromium] Refactor ClipboardChromium and DataTransferItemList/DataTransferItem to support HTML spec
2353         https://bugs.webkit.org/show_bug.cgi?id=76598
2354
2355         Reviewed by Tony Chang.
2356
2357         We no longer store drag/clipboard data in named fields. We used to maintain the data store
2358         list separately, which resulted in a lot of complicated code to try to make sure that
2359         ChromiumDataObject and this list stayed in sync. We now just store what is essentially a
2360         list MIME type/data pairs directly in ChromiumDataObject. This has the benefit of letting us
2361         easily add write support during dragstart/copy operations using DataTransferItemList.
2362
2363         Tests: fast/events/clipboard-dataTransferItemList.html
2364                fast/events/drag-dataTransferItemList.html
2365
2366         * platform/chromium/ChromiumDataObject.cpp:
2367         (WebCore::findItem):
2368         (WebCore::ChromiumDataObject::createFromPasteboard):
2369         (WebCore::ChromiumDataObject::create):
2370         (WebCore::ChromiumDataObject::copy):
2371         (WebCore::ChromiumDataObject::items):
2372         (WebCore::ChromiumDataObject::clearData):
2373         (WebCore::ChromiumDataObject::clearAll):
2374         (WebCore::ChromiumDataObject::clearAllExceptFiles):
2375         (WebCore::ChromiumDataObject::types):
2376         (WebCore::ChromiumDataObject::getData):
2377         (WebCore::ChromiumDataObject::setData):
2378         (WebCore::ChromiumDataObject::urlAndTitle):
2379         (WebCore::ChromiumDataObject::setURLAndTitle):
2380         (WebCore::ChromiumDataObject::htmlAndBaseURL):
2381         (WebCore::ChromiumDataObject::setHTMLAndBaseURL):
2382         (WebCore::ChromiumDataObject::containsFilenames):
2383         (WebCore):
2384         (WebCore::ChromiumDataObject::filenames):
2385         (WebCore::ChromiumDataObject::addFilename):
2386         (WebCore::ChromiumDataObject::addSharedBuffer):
2387         (WebCore::ChromiumDataObject::ChromiumDataObject):
2388         * platform/chromium/ChromiumDataObject.h:
2389         (WebCore):
2390         (ChromiumDataObject):
2391         * platform/chromium/ClipboardChromium.cpp:
2392         (WebCore::normalizeType):
2393         (WebCore::ClipboardChromium::ClipboardChromium):
2394         (WebCore::ClipboardChromium::clearData):
2395         (WebCore::ClipboardChromium::clearAllData):
2396         (WebCore::ClipboardChromium::getData):
2397         (WebCore::ClipboardChromium::setData):
2398         (WebCore::ClipboardChromium::types):
2399         (WebCore::ClipboardChromium::files):
2400         (WebCore::writeImageToDataObject):
2401         (WebCore::ClipboardChromium::declareAndWriteDragImage):
2402         (WebCore::ClipboardChromium::writeURL):
2403         (WebCore::ClipboardChromium::writeRange):
2404         (WebCore::ClipboardChromium::writePlainText):
2405         (WebCore::ClipboardChromium::hasData):
2406         (WebCore::ClipboardChromium::items):
2407         * platform/chromium/ClipboardChromium.h:
2408         (WebCore):
2409         (ClipboardChromium):
2410         (WebCore::ClipboardChromium::frame):
2411         * platform/chromium/ClipboardUtilitiesChromium.cpp:
2412         (WebCore::convertURIListToURL):
2413         (WebCore):
2414         * platform/chromium/ClipboardUtilitiesChromium.h:
2415         (WebCore):
2416         * platform/chromium/DataTransferItemChromium.cpp:
2417         (WebCore::DataTransferItemChromium::createFromString):
2418         (WebCore::DataTransferItemChromium::createFromFile):
2419         (WebCore::DataTransferItemChromium::createFromURL):
2420         (WebCore::DataTransferItemChromium::createFromHTML):
2421         (WebCore):
2422         (WebCore::DataTransferItemChromium::createFromSharedBuffer):
2423         (WebCore::DataTransferItemChromium::createFromPasteboard):
2424         (WebCore::DataTransferItemChromium::DataTransferItemChromium):
2425         (WebCore::DataTransferItemChromium::getAsString):
2426         (WebCore::DataTransferItemChromium::getAsFile):
2427         (WebCore::DataTransferItemChromium::internalGetAsString):
2428         (WebCore::DataTransferItemChromium::isFilename):
2429         * platform/chromium/DataTransferItemChromium.h:
2430         (WebCore):
2431         (DataTransferItemChromium):
2432         (WebCore::DataTransferItemChromium::kind):
2433         (WebCore::DataTransferItemChromium::type):
2434         (WebCore::DataTransferItemChromium::sharedBuffer):
2435         (WebCore::DataTransferItemChromium::title):
2436         (WebCore::DataTransferItemChromium::baseURL):
2437         * platform/chromium/DataTransferItemListChromium.cpp:
2438         (WebCore::DataTransferItemListChromium::create):
2439         (WebCore::DataTransferItemListChromium::createFromPasteboard):
2440         (WebCore):
2441         (WebCore::DataTransferItemListChromium::DataTransferItemListChromium):
2442         (WebCore::DataTransferItemListChromium::length):
2443         (WebCore::DataTransferItemListChromium::item):
2444         (WebCore::DataTransferItemListChromium::deleteItem):
2445         (WebCore::DataTransferItemListChromium::clear):
2446         (WebCore::DataTransferItemListChromium::add):
2447         (WebCore::DataTransferItemListChromium::internalAddStringItem):
2448         (WebCore::DataTransferItemListChromium::internalAddFileItem):
2449         * platform/chromium/DataTransferItemListChromium.h:
2450         (WebCore):
2451         (DataTransferItemListChromium):
2452         * platform/chromium/DragDataChromium.cpp:
2453         (WebCore::DragData::asURL):
2454         (WebCore::DragData::asPlainText):
2455         (WebCore::DragData::asFragment):
2456
2457 2012-03-16  Matt Lilek  <mrl@apple.com>
2458
2459         Don't install libWebCoreTestSupport on OS X production builds
2460         https://bugs.webkit.org/show_bug.cgi?id=81087
2461
2462         Reviewed by Mark Rowe.
2463
2464         * Configurations/WebCoreTestSupport.xcconfig:
2465
2466 2012-03-16  Tony Chang  <tony@chromium.org>
2467
2468         incorrectly removing scrollbar height for auto height flexbox children
2469         https://bugs.webkit.org/show_bug.cgi?id=81388
2470
2471         Reviewed by Ojan Vafai.
2472
2473         In a column flexbox, when computing the preferred height of an auto
2474         height child, we were subtracting out the horizontal scrollbar height.
2475
2476         New test case in css3/flexbox/columns-auto-size.html.
2477
2478         * rendering/RenderFlexibleBox.cpp:
2479         (WebCore::RenderFlexibleBox::preferredMainAxisContentExtentForChild):
2480
2481 2012-03-16  Adam Klein  <adamk@chromium.org>
2482
2483         Out-of-document radio buttons should be grouped when associated with a form
2484         https://bugs.webkit.org/show_bug.cgi?id=81268
2485
2486         Reviewed by Kent Tamura.
2487
2488         Per the HTML spec, and the behavior of Firefox and IE 8/9, radio buttons
2489         with a form owner should be grouped, even if that form is not in the document.
2490
2491         r104668 added many inDocument() tests to radio button grouping code.
2492         While those are necessary to avoid unattached <input type=radio>
2493         elements being grouped together, it also kept them from being grouped
2494         when associated with a form outside the document.
2495
2496         This patch changes the HTMLInputElement::checkedRadioButtons() method
2497         to return either a pointer to the proper CheckedRadioButtons instance
2498         (either the document's or a form's), but will return null if the
2499         element should not be associated with any radio button group.
2500
2501         The main fallout of this was that the callers of checkedRadioButtons()
2502         now have to check for null, resulting in the creation of a few helper
2503         methods in HTMLInputElement to wrap the null checks.
2504
2505         This refactoring has the pleasant side-effect of exposing a cleaner API between
2506         HTMLInputElement and RadioInputType, and making a clearer contract
2507         between HTMLInputElement and CheckedRadioButtons (e.g., all
2508         CheckedRadioButtons methods that take an element can now assume that
2509         it is a radio button, where previously some checked for that and
2510         others asserted it).
2511
2512         Test: fast/forms/radio/radio-group-in-detached-form.html
2513
2514         * dom/CheckedRadioButtons.cpp:
2515         (WebCore): Removed shouldMakeRadioGroup() helper function.
2516         (WebCore::CheckedRadioButtons::addButton): Replace call to shouldMakeRadioGroup
2517         with appropriate assert and name check.
2518         (WebCore::CheckedRadioButtons::updateCheckedState): ditto.
2519         (WebCore::CheckedRadioButtons::requiredAttributeChanged): ditto.
2520         (WebCore::CheckedRadioButtons::isRequiredGroup): Renamed from isInRequiredGroup,
2521         changed to take only a group name, not an element.
2522         (WebCore::CheckedRadioButtons::removeButton): Replace call to shouldMakeRadioGroup.
2523         with appropriate assert and name check.
2524         * dom/CheckedRadioButtons.h:
2525         (CheckedRadioButtons):
2526         * html/HTMLInputElement.cpp:
2527         (WebCore::HTMLInputElement::~HTMLInputElement): Added isRadioButton check
2528         now that it's asserted in CheckedRadioButtons.
2529         (WebCore::HTMLInputElement::updateType): Call helper method instead of
2530         calling directly into CheckedRadioButtons.
2531         (WebCore::HTMLInputElement::parseAttribute): ditto.
2532         (WebCore::HTMLInputElement::setChecked): ditto.
2533         (WebCore::HTMLInputElement::willChangeForm): ditto.
2534         (WebCore::HTMLInputElement::didChangeForm): ditto.
2535         (WebCore::HTMLInputElement::insertedIntoDocument): ditto.
2536         (WebCore::HTMLInputElement::removedFromDocument): ditto.
2537         (WebCore::HTMLInputElement::didMoveToNewDocument): Added isRadioButton check.
2538         (WebCore::HTMLInputElement::requiredAttributeChanged): Check for membership in a group
2539         before calling into CheckedRadioButtons.
2540         (WebCore::HTMLInputElement::isInRequiredRadioButtonGroup): Added helper method for use by RadioInputType.
2541         (WebCore):
2542         (WebCore::HTMLInputElement::checkedRadioButtonForGroup): ditto.
2543         (WebCore::HTMLInputElement::checkedRadioButtons): Changed to return a
2544         pointer, only return non-null if actually a member of a group.
2545         (WebCore::HTMLInputElement::addToRadioButtonGroup): Helper method for
2546         use in HTMLInputElement.
2547         (WebCore::HTMLInputElement::removeFromRadioButtonGroup): ditto.
2548         * html/HTMLInputElement.h:
2549         (HTMLInputElement): Added/removed methods, removed outdated comment about visibility.
2550         * html/RadioInputType.cpp:
2551         (WebCore::RadioInputType::valueMissing): Call new HTMLInputElement methods instead
2552         of interacting directly with CheckedRadioButtons.
2553         (WebCore::RadioInputType::isKeyboardFocusable): ditto.
2554         (WebCore::RadioInputType::willDispatchClick): ditto.
2555
2556 2012-03-16  David Hyatt  <hyatt@apple.com>
2557
2558         https://bugs.webkit.org/show_bug.cgi?id=81366
2559         
2560         Add RenderMultiColumnBlock subclass of RenderBlock. This new class will hold all of the multi-column
2561         logic (as well as painting/hit testing). That way the column code can be kept out of the base class
2562         and be more cleanly factored.
2563
2564         Patch Node::diff so that we detach and re-attach the renderer if column counts or widths change
2565         from auto to non-auto (and vice versa) to ensure the right renderer gets made.
2566         
2567         Patch RenderObject::createObject to make a RenderMultiColumnBlock if either the column count or
2568         column width is non-auto.
2569         
2570         Patch RenderBlock::calcColumnWidth to "turn off" the old implementation of columns if the pref to use
2571         the new column implementation is set. This single chokepoint should be sufficient for disabling the old
2572         columns in favor of the new.
2573
2574         Reviewed by Dan Bernstein.
2575
2576         * CMakeLists.txt:
2577         * GNUmakefile.list.am:
2578         * WebCore.gypi:
2579         * WebCore.vcproj/WebCore.vcproj:
2580         * WebCore.xcodeproj/project.pbxproj:
2581         * dom/Document.cpp:
2582         (WebCore::Document::regionBasedColumnsEnabled):
2583         (WebCore):
2584         (WebCore::Document::recalcStyle):
2585         * dom/Document.h:
2586         (Document):
2587         * dom/Element.cpp:
2588         (WebCore::Element::recalcStyle):
2589         * dom/Node.cpp:
2590         (WebCore::Node::diff):
2591         * dom/Node.h:
2592         * rendering/RenderBlock.cpp:
2593         (WebCore::RenderBlock::calcColumnWidth):
2594         (WebCore::RenderBlock::updateFirstLetterStyle):
2595         * rendering/RenderMultiColumnBlock.cpp: Added.
2596         (WebCore):
2597         (WebCore::RenderMultiColumnBlock::RenderMultiColumnBlock):
2598         (WebCore::RenderMultiColumnBlock::renderName):
2599         * rendering/RenderMultiColumnBlock.h: Added.
2600         (WebCore):
2601         (RenderMultiColumnBlock):
2602         * rendering/RenderObject.cpp:
2603         (WebCore::RenderObject::createObject):
2604         * rendering/RenderObjectChildList.cpp:
2605         (WebCore::RenderObjectChildList::updateBeforeAfterContent):
2606
2607 2012-03-16  Stephen White  <senorblanco@chromium.org>
2608
2609         [chromium] Improve CSS3 filter blur performance.
2610         https://bugs.webkit.org/show_bug.cgi?id=81360
2611
2612         This change improves blur performance by 2-2.5X on blurred CSS
2613         3D transforms and accelerated canvas demos by skipping an unnecessary
2614         texture allocation and bitmap draw.
2615
2616         Reviewed by James Robinson.
2617
2618         Covered by existing layout tests in css3/filters.
2619
2620         * platform/graphics/chromium/cc/CCRenderSurfaceFilters.cpp:
2621         (WebCore::CCRenderSurfaceFilters::apply):
2622         Call SkCanvas::drawSprite() directly instead of using
2623         saveLayer()/restore().
2624
2625 2012-03-16  Joshua Bell  <jsbell@chromium.org>
2626
2627         [Chromium] IndexedDB: Assertion failure when storing File objects
2628         https://bugs.webkit.org/show_bug.cgi?id=76746
2629
2630         The blob data in Blob/File/FileList objects is serialized "by reference" (the
2631         internal URL) rather than "by value" (the actual data); this is sufficient for
2632         postMessage() but not for IndexedDB since the referenced data is not retained
2633         Expose a mechanism to enumerate the URLs so that SSVs can be rejected by IDB
2634         until blob data serialization can is implemented (outside the SSV mechanism, and
2635         potentially asynchronously).
2636
2637         Also, correct issue in V8DOMWrapper::instantiateV8Object where context is assumed
2638         to be a Worker context if it's not a Window, which is incorrect for the
2639         Chromium utility process; this is hit if Blobs are not blocked.
2640
2641         Reviewed by Tony Chang.
2642
2643         Test: storage/indexeddb/noblobs.html
2644
2645         * Modules/indexeddb/IDBCursor.cpp:
2646         (WebCore::IDBCursor::update): Reject SSVs that contain blob references.
2647         * Modules/indexeddb/IDBObjectStore.cpp:
2648         (WebCore::IDBObjectStore::add): Reject SSVs that contain blob references.
2649         (WebCore::IDBObjectStore::put): Reject SSVs that contain blob references.
2650         * bindings/js/SerializedScriptValue.cpp:
2651         (WebCore::CloneSerializer::serialize):
2652         (WebCore::CloneSerializer::CloneSerializer):
2653         (WebCore::CloneSerializer::dumpIfTerminal):
2654         (WebCore::CloneSerializer::write):
2655         (CloneSerializer):
2656         (WebCore::SerializedScriptValue::SerializedScriptValue):
2657         (WebCore::SerializedScriptValue::create):
2658         (WebCore::SerializedScriptValue::undefinedValue):
2659         (WebCore::SerializedScriptValue::booleanValue):
2660         * bindings/js/SerializedScriptValue.h: New API to enable the clients to be picky.
2661         * bindings/v8/SerializedScriptValue.cpp:
2662         (WebCore::SerializedScriptValue::SerializedScriptValue):
2663         * bindings/v8/SerializedScriptValue.h: New API to enable the clients to be picky.
2664         (WebCore::SerializedScriptValue::blobURLs):
2665         (SerializedScriptValue):
2666         * bindings/v8/V8DOMWrapper.cpp:
2667         (WebCore::V8DOMWrapper::instantiateV8Object):  Ensure context is a worker context before treating it as such.
2668
2669 2012-03-16  Erik Arvidsson  <arv@chromium.org>
2670
2671         [V8] Ensure that invalid syntax in inline event handlers does not cause a crash
2672         https://bugs.webkit.org/show_bug.cgi?id=81385
2673
2674         Reviewed by Nate Chapin.
2675
2676         The way that V8 does its inline event handler involves concatting strings and
2677         if the attribute value is crafted in a special way this could cause a crash.
2678
2679         Test: fast/dom/inline-event-attributes-crash.html
2680
2681         * bindings/v8/V8LazyEventListener.cpp:
2682         (WebCore::V8LazyEventListener::prepareListenerObject):
2683
2684 2012-03-14  Jer Noble  <jer.noble@apple.com>
2685
2686         Wrong icon to restore to windowed mode in full screen video panel
2687         https://bugs.webkit.org/show_bug.cgi?id=70437
2688
2689         Reviewed by Eric Carlson.
2690
2691         No new tests. Updated platform/mac/accessibility/media-element-expected.txt.
2692
2693         Renamed MediaFullscreenButton to MediaEnterFullscreenButton and added MediaExitFullscreenButton:
2694         * accessibility/AccessibilityMediaControls.cpp:
2695         (WebCore::AccessibilityMediaControl::controlTypeName):
2696         (WebCore::AccessibilityMediaControl::roleValue):
2697         * html/shadow/MediaControlElements.cpp:
2698         (WebCore::MediaControlFullscreenButtonElement::MediaControlFullscreenButtonElement):
2699         * css/CSSPrimitiveValueMappings.h:
2700         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
2701         * css/CSSValueKeywords.in:
2702         * platform/ThemeTypes.h:
2703
2704         Added setIsFullscreen which controls the display of the enter/exit fullscreen button:
2705         * html/shadow/MediaControlElements.cpp:
2706         (WebCore::MediaControlFullscreenButtonElement::setIsFullscreen): Added.
2707         * html/shadow/MediaControlElements.h:
2708         * html/shadow/MediaControlRootElement.cpp:
2709         (WebCore::MediaControlRootElement::enteredFullscreen):
2710         (WebCore::MediaControlRootElement::exitedFullscreen):
2711
2712         Paint the enter/exit fullscreen button accordingly:
2713         * rendering/RenderMediaControlsChromium.cpp:
2714         (WebCore::RenderMediaControlsChromium::paintMediaControlsPart):
2715         * rendering/RenderTheme.cpp:
2716         (WebCore::RenderTheme::paint):
2717         * rendering/RenderThemeChromiumAndroid.cpp:
2718         (WebCore::RenderThemeChromiumAndroid::paintMediaFullscreenButton):
2719         * rendering/RenderThemeMac.mm:
2720         (WebCore::RenderThemeMac::paintMediaFullscreenButton):
2721         * rendering/RenderMediaControls.cpp:
2722         (WebCore::RenderMediaControls::paintMediaControlsPart):
2723         * rendering/RenderThemeSafari.cpp:
2724         (WebCore::RenderThemeSafari::paintMediaFullscreenButton):
2725
2726         Update the localized strings for the exit and enter fullscreen buttons:
2727         * English.lproj/Localizable.strings:
2728         * platform/LocalizedStrings.cpp:
2729         (WebCore::localizedMediaControlElementString):
2730         * platform/gtk/LocalizedStringsGtk.cpp:
2731         (WebCore::localizedMediaControlElementString):
2732         (WebCore::localizedMediaControlElementHelpText):
2733         * platform/qt/LocalizedStringsQt.cpp:
2734         (WebCore::localizedMediaControlElementString):
2735         (WebCore::localizedMediaControlElementHelpText):
2736
2737 2012-03-16  Levi Weintraub  <leviw@chromium.org>
2738
2739         Update LayoutUnit usage in RenderListBox
2740         https://bugs.webkit.org/show_bug.cgi?id=81038
2741
2742         Reviewed by Julien Chaffraix.
2743
2744         Bringing RenderListBox in line with the rules listed in
2745         https://trac.webkit.org/wiki/LayoutUnit
2746
2747         No new tests. No change in behavior.
2748
2749         * rendering/RenderListBox.cpp:
2750         (WebCore::RenderListBox::paintScrollbar): Pixel snapping before handing off scrollbar
2751         painting to the platform.
2752         (WebCore::RenderListBox::paintItemForeground): Rounding the offset for text painting.
2753         (WebCore::RenderListBox::paintItemBackground): Pixel snapping the background rect.
2754         (WebCore::RenderListBox::panScroll): EventHandler::currentMousePosition is an IntPoint,
2755         so it doesn't require additional rounding in RenderListBox.
2756
2757 2012-03-16  Sheriff Bot  <webkit.review.bot@gmail.com>
2758
2759         Unreviewed, rolling out r111020.
2760         http://trac.webkit.org/changeset/111020
2761         https://bugs.webkit.org/show_bug.cgi?id=81377
2762
2763         Broke Chromium Win compile (Requested by pkasting on #webkit).
2764
2765         * GNUmakefile.list.am:
2766         * WebCore.gypi:
2767         * platform/mediastream/PeerConnection00Handler.cpp: Removed.
2768         * platform/mediastream/PeerConnection00Handler.h: Removed.
2769         * platform/mediastream/PeerConnection00HandlerClient.h: Removed.
2770
2771 2012-03-16  Dominic Mazzoni  <dmazzoni@google.com>
2772
2773         File input control accessibility can cause a crash
2774         https://bugs.webkit.org/show_bug.cgi?id=80896
2775
2776         Reviewed by Chris Fleizach.
2777
2778         Test: accessibility/input-file-causes-crash.html
2779
2780         * accessibility/AccessibilityRenderObject.cpp:
2781         (WebCore::AccessibilityRenderObject::textUnderElement):
2782
2783 2012-03-08  Jer Noble  <jer.noble@apple.com>
2784
2785         Support W3C Full Screen API proposal
2786         https://bugs.webkit.org/show_bug.cgi?id=80660
2787
2788         Reviewed by Alexey Proskuryakov.
2789
2790         Tests: fullscreen/full-screen-element-stack.html
2791                fullscreen/full-screen-enabled.html
2792                fullscreen/full-screen-restrictions.html
2793
2794         The W3C proposal for taking arbitrary elements into full-screen mode is significantly
2795         different than the Mozilla proposal. For example, the W3C has proposed a lower-case "s"
2796         in "Fullscreen", which means the W3C and Mozilla "requestFullscreen" APIs differ only by
2797         in that lower-case "s". Annoying as this is, it does allow us to retain the semantics for
2798         the Mozilla case (har!).
2799
2800         A significant difficulty is obeying the new W3C spec rules is that we would like to apply the
2801         fullscreen CSS rules while exiting fullscreen mode, though the W3C spec insists that the
2802         webkitFullscreenElement returns the new value immediately.  As such, we retain the m_fullScreenElement
2803         variable (distinct from the top of the m_fullScreenElements stack) which is controlled by the
2804         webkit{Will,Did}{Enter,Exit}FullScreen functions.
2805
2806         New APIs for the W3C Fullscreen spec:
2807         * dom/Document.h:
2808         (WebCore::Document::webkitFullscreenElement):
2809         (WebCore::Document::webkitFullscreenEnabled):
2810         * dom/Document.idl:
2811         * dom/Element.cpp:
2812         (WebCore::Element::webkitRequestFullscreen):
2813         * dom/Element.h:
2814         * dom/Element.idl:
2815
2816         * dom/Document.cpp:
2817         (WebCore::Document::removedLastRef): Clear m_fullScreenElementStack.
2818         (WebCore::Document::requestFullScreenForElement): Implement the W3C requirements.
2819         (WebCore::Document::webkitExitFullscreen): Ditto.
2820         (WebCore::Document::webkitCancelFullScreen): Implement in terms of webkitCancelFullscreen.
2821         (WebCore::Document::webkitDidEnterFullScreenForElement): 
2822         (WebCore::Document::webkitWillExitFullScreenForElement):
2823         (WebCore::Document::webkitDidExitFullScreenForElement):
2824         (WebCore::Document::fullScreenChangeDelayTimerFired): Protect against items being
2825             added to the event and error queue by swapping out empty queues before starting.
2826         (WebCore::Document::clearFullscreenElementStack): Simple accessor.
2827         (WebCore::Document::popFullscreenElementStack): Ditto.
2828         (WebCore::Document::pushFullscreenElementStack): Ditto.
2829         * dom/Element.cpp:
2830         (WebCore::Element::webkitRequestFullScreen):
2831
2832         Add new RuntimeEnabledFeatures functions for the added Document and Element functions.
2833         * bindings/generic/RuntimeEnabledFeatures.h:
2834         (RuntimeEnabledFeatures):
2835         (WebCore::RuntimeEnabledFeatures::webkitFullscreenEnabledEnabled):
2836         (WebCore::RuntimeEnabledFeatures::webkitFullscreenElementEnabled):
2837         (WebCore::RuntimeEnabledFeatures::webkitExitFullscreenEnabled):
2838         (WebCore::RuntimeEnabledFeatures::webkitRequestFullscreenEnabled):
2839
2840
2841 2012-03-16  Adam Klein  <adamk@chromium.org>
2842
2843         Make HTMLInputElement::isRadioButton non-virtual and remove unused HTMLFormControlElement::isRadioButton method
2844         https://bugs.webkit.org/show_bug.cgi?id=81255
2845
2846         Reviewed by Kent Tamura.
2847
2848         No new tests, no change in behavior.
2849
2850         * html/HTMLFormControlElement.h:
2851         * html/HTMLInputElement.h:
2852         (HTMLInputElement):
2853
2854 2012-03-16  Tay Grigg  <tgrigg@rim.com>
2855
2856         [BlackBerry] Update NetworkJob to accept batched headers
2857         https://bugs.webkit.org/show_bug.cgi?id=81273
2858
2859         Batch up the headers into a vector before they come into
2860         webkit to increase performance, and simplify the API.
2861
2862         Reviewed by George Staikos.
2863
2864         * platform/network/blackberry/NetworkJob.cpp:
2865         (WebCore::NetworkJob::notifyHeadersReceived):
2866         * platform/network/blackberry/NetworkJob.h:
2867         (NetworkJob):
2868
2869 2012-03-16  Dana Jansens  <danakj@chromium.org>
2870
2871         [chromium] Add overdraw metrics for texture uploads
2872         https://bugs.webkit.org/show_bug.cgi?id=81175
2873
2874         Reviewed by Adrienne Walker.
2875
2876         Record texture upload metrics during paint. To properly record
2877         the amount of pixels culled, we must compute the amount of pixels we
2878         would have uploaded for a tile. This requires knowing the dirty rect of
2879         the tile, but the dirty rect can be changed by WebKit during a paint, so
2880         we always store the dirtyRect in the tile's updateRect. We add an
2881         m_updateCulled bool to the UpdatableTile structure, to identify tiles
2882         that were not updated, and know a tile was updated if updateRect is not
2883         empty and updateCulled is false.
2884
2885         Tested by all TiledLayerChromiumTests that use occlusion tracker.
2886
2887         * platform/graphics/chromium/TiledLayerChromium.cpp:
2888         (UpdatableTile):
2889         (WebCore::TiledLayerChromium::prepareToUpdateTiles):
2890         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
2891         (WebCore::CCLayerTreeHost::paintLayerContents):
2892
2893 2012-03-16  Jer Noble  <jer.noble@apple.com>
2894
2895         Allow AudioContext::create() to emit an ExceptionCode.
2896         https://bugs.webkit.org/show_bug.cgi?id=81049
2897
2898         Reviewed by Kentaro Hara.
2899
2900         No new tests; no change in functionality.
2901
2902         Pass through an ExceptionCode parameter to AudioContext::create().  It is currently
2903         never modified, but exceptions will be added in the future.
2904
2905         * bindings/js/JSAudioContextCustom.cpp:
2906         (WebCore::JSAudioContextConstructor::constructJSAudioContext):
2907         * bindings/v8/custom/V8AudioContextCustom.cpp:
2908         (WebCore::V8AudioContext::constructorCallback):
2909         * webaudio/AudioContext.cpp:
2910         (WebCore::AudioContext::create):
2911         * webaudio/AudioContext.h:
2912
2913 2012-03-16  Dana Jansens  <danakj@chromium.org>
2914
2915         [chromium] Remove surface damage client from occlusion tracker
2916         https://bugs.webkit.org/show_bug.cgi?id=81242
2917
2918         Reviewed by Adrienne Walker.
2919
2920         Code was not used yet, so no new tests. Removing tests instead!
2921
2922         * platform/graphics/chromium/cc/CCOcclusionTracker.cpp:
2923         (WebCore::::CCOcclusionTrackerBase):
2924         (WebCore::::layerScissorRectInTargetSurface):
2925         (WebCore):
2926         * platform/graphics/chromium/cc/CCOcclusionTracker.h:
2927         (WebCore):
2928         (CCOcclusionTrackerBase):
2929
2930 2012-03-16  Tommy Widenflycht  <tommyw@google.com>
2931
2932         MediaStream API (JSEP): Introducing PeerConnection00Handler
2933         https://bugs.webkit.org/show_bug.cgi?id=81333
2934
2935         Reviewed by Adam Barth.
2936
2937         In preparation of the last WebCore patch that will introduce PeerConnection00 here's its platform representation.
2938
2939         Not possible to test until the entire JSEP feature is commited.
2940
2941         * GNUmakefile.list.am:
2942         * WebCore.gypi:
2943         * platform/mediastream/PeerConnection00Handler.cpp: Added.
2944         (WebCore):
2945         (WebCore::PeerConnection00Handler::create):
2946         (WebCore::PeerConnection00Handler::PeerConnection00Handler):
2947         (WebCore::PeerConnection00Handler::~PeerConnection00Handler):
2948         (WebCore::PeerConnection00Handler::createOffer):
2949         (WebCore::PeerConnection00Handler::createAnswer):
2950         (WebCore::PeerConnection00Handler::setLocalDescription):
2951         (WebCore::PeerConnection00Handler::setRemoteDescription):
2952         (WebCore::PeerConnection00Handler::localDescription):
2953         (WebCore::PeerConnection00Handler::remoteDescription):
2954         (WebCore::PeerConnection00Handler::startIce):
2955         (WebCore::PeerConnection00Handler::processIceMessage):
2956         (WebCore::PeerConnection00Handler::addStream):
2957         (WebCore::PeerConnection00Handler::removeStream):
2958         (WebCore::PeerConnection00Handler::stop):
2959         * platform/mediastream/PeerConnection00Handler.h: Added.
2960         (WebCore):
2961         (PeerConnection00Handler):
2962         * platform/mediastream/PeerConnection00HandlerClient.h: Added.
2963         (WebCore):
2964         (PeerConnection00HandlerClient):
2965         (WebCore::PeerConnection00HandlerClient::~PeerConnection00HandlerClient):
2966
2967 2012-03-16  Pavel Podivilov  <podivilov@chromium.org>
2968
2969         Web Inspector: fix exception when hovering over bound function in heap profiler.
2970         https://bugs.webkit.org/show_bug.cgi?id=81362
2971
2972         Reviewed by Yury Semikhatsky.
2973
2974         * inspector/front-end/DebuggerPresentationModel.js:
2975         (WebInspector.DebuggerPresentationModel.Linkifier.prototype.linkifyRawLocation):
2976
2977 2012-03-16  Yoshifumi Inoue  <yosin@chromium.org>
2978
2979         [Forms] The "progress" element should not be a form-associated element.
2980         https://bugs.webkit.org/show_bug.cgi?id=80240
2981
2982         Reviewed by Kent Tamura.
2983
2984         This patch changes base class of HTMLProgressElement to LabelableElement from
2985         HTMLFormControlElement for saving memory space and iteration time of
2986         extra "progress" elements in HTMLFormElement::m_formAssociatedElements
2987         and matching the HTML5 specification for ease of maintenance.
2988
2989         Changes of TextIterator is lead by usage of isFormControlElement. This
2990         changes will be replaced with more meaningful predicate as part of
2991         https://bugs.webkit.org/show_bug.cgi?id=80381
2992
2993         No new tests. Update existing tests to cover this change.
2994
2995         * css/CSSStyleSelector.cpp:
2996         (WebCore::CSSStyleSelector::canShareStyleWithElement): Moved the "progress" element support code from canShareStyleWithControl.
2997         (WebCore::CSSStyleSelector::canShareStyleWithControl):
2998         * css/SelectorChecker.cpp:
2999         (WebCore::SelectorChecker::checkOneSelector): Remove isFormControlElement check for PseudoIndeterminate.
3000         * editing/TextIterator.cpp:
3001         (WebCore::TextIterator::advance): Check HTMLProgressElement in addition to isFormControlElement. This change is for text dump in LayoutTests implemented by document.innerText attribute.
3002         * html/HTMLProgressElement.cpp: Remove unused include file.
3003         (WebCore::HTMLProgressElement::HTMLProgressElement): Changed base class to LabelableElement.
3004         (WebCore::HTMLProgressElement::create): Remove form paraprogress.
3005         (WebCore::HTMLProgressElement::parseAttribute): Replace HTMLFormControlElement to LabelableElement.
3006         (WebCore::HTMLProgressElement::attach): Replace HTMLFormControlElement to LabelableElement.
3007         * html/HTMLProgressElement.h:
3008         (HTMLProgressElement):
3009         * html/HTMLProgressElement.idl: Remove the "form" attribute which isn't listed in the HTML5 specification.
3010         * html/HTMLTagNames.in: Remove "constructorNeedsFormElement" for not passing "form" parameter in HTMLElementFactory.
3011
3012 2012-03-16  Ilya Tikhonovsky  <loislo@chromium.org>
3013
3014         Web Inspector: Heap Snapshot: Unreviewed single line fix for isWindow getter.
3015
3016         * inspector/front-end/HeapSnapshot.js:
3017         (WebInspector.HeapSnapshotNode.prototype.get isWindow):
3018
3019 2012-03-16  Tommy Widenflycht  <tommyw@google.com>
3020
3021         MediaStream API (JSEP): Fixing a few nits
3022         https://bugs.webkit.org/show_bug.cgi?id=81322
3023
3024         Reviewed by Adam Barth.
3025
3026         Addressing the nits from bugs 81206 and 81207.
3027
3028         Nothing to test.
3029
3030         * Modules/mediastream/SessionDescription.idl:
3031         * platform/mediastream/IceOptions.h:
3032         (WebCore::IceOptions::IceOptions):
3033         * platform/mediastream/SessionDescriptionDescriptor.h:
3034         (SessionDescriptionDescriptor):
3035
3036 2012-03-16  Peter Rybin  <peter.rybin@gmail.com>
3037
3038         Web Inspector: TypeBuilder: Introduce OptOutput class for optional output parameters
3039         https://bugs.webkit.org/show_bug.cgi?id=80789
3040
3041         Reviewed by Yury Semikhatsky.
3042
3043         OptOutput class is added for optional return parameters.
3044
3045         Strict mode added to Generator that makes all parameter types strict
3046         and drop pre-set default values for return parameters.
3047
3048         Debugger and Page domain is switched to strict mode.
3049
3050         * inspector/CodeGeneratorInspector.py:
3051         (CommandReturnPassModel.OptOutput):
3052         (CommandReturnPassModel.OptOutput.__init__):
3053         (CommandReturnPassModel.OptOutput.get_return_var_type):
3054         (CommandReturnPassModel.OptOutput.get_output_argument_prefix):
3055         (CommandReturnPassModel.OptOutput.get_output_to_raw_expression):
3056         (CommandReturnPassModel.OptOutput.get_output_parameter_type):
3057         (CommandReturnPassModel):
3058         (CommandReturnPassModel.OptOutput.get_set_return_condition):
3059         (TypeModel.Enum.get_optional.EnumOptional.get_command_return_pass_model):
3060         (TypeModel.ValueType.ValueOptional.get_command_return_pass_model):
3061         (OptOutput):
3062         (Generator.process_event):
3063         (Generator.process_command):
3064         * inspector/ContentSearchUtils.cpp:
3065         (WebCore::ContentSearchUtils::buildObjectForSearchMatch):
3066         (WebCore::ContentSearchUtils::searchInTextByLines):
3067         * inspector/ContentSearchUtils.h:
3068         (ContentSearchUtils):
3069         * inspector/InjectedScript.cpp:
3070         (WebCore::InjectedScript::evaluate):
3071         (WebCore::InjectedScript::callFunctionOn):
3072         (WebCore::InjectedScript::evaluateOnCallFrame):
3073         (WebCore::InjectedScript::makeEvalCall):
3074         * inspector/InjectedScript.h:
3075         (InjectedScript):
3076         * inspector/InspectorDOMDebuggerAgent.cpp:
3077         (WebCore::InspectorDOMDebuggerAgent::didInvalidateStyleAttr):
3078         (WebCore::InspectorDOMDebuggerAgent::willInsertDOMNode):
3079         (WebCore::InspectorDOMDebuggerAgent::willRemoveDOMNode):
3080         (WebCore::InspectorDOMDebuggerAgent::willModifyDOMAttr):
3081         (WebCore::InspectorDOMDebuggerAgent::pauseOnNativeEventIfNeeded):
3082         (WebCore::InspectorDOMDebuggerAgent::willSendXMLHttpRequest):
3083         * inspector/InspectorDebuggerAgent.cpp:
3084         (WebCore::InspectorDebuggerAgent::setBreakpointByUrl):
3085         (WebCore::InspectorDebuggerAgent::setBreakpoint):
3086         (WebCore::InspectorDebuggerAgent::searchInContent):
3087         (WebCore::InspectorDebuggerAgent::setScriptSource):
3088         (WebCore::InspectorDebuggerAgent::getFunctionDetails):
3089         (WebCore::InspectorDebuggerAgent::schedulePauseOnNextStatement):
3090         (WebCore::InspectorDebuggerAgent::evaluateOnCallFrame):
3091         (WebCore::InspectorDebuggerAgent::didPause):
3092         (WebCore::InspectorDebuggerAgent::breakProgram):
3093         (WebCore::InspectorDebuggerAgent::clearBreakDetails):
3094         * inspector/InspectorDebuggerAgent.h:
3095         (InspectorDebuggerAgent):
3096         * inspector/InspectorPageAgent.cpp:
3097         (WebCore::buildObjectForCookie):
3098         (WebCore::buildArrayForCookies):
3099         (WebCore::InspectorPageAgent::getCookies):
3100         (WebCore::InspectorPageAgent::getResourceTree):
3101         (WebCore::InspectorPageAgent::searchInResource):
3102         (WebCore::InspectorPageAgent::searchInResources):
3103         (WebCore::InspectorPageAgent::buildObjectForFrame):
3104         (WebCore::InspectorPageAgent::buildObjectForFrameTree):
3105         * inspector/InspectorPageAgent.h:
3106         * inspector/InspectorRuntimeAgent.cpp:
3107         (WebCore::InspectorRuntimeAgent::evaluate):
3108         (WebCore::InspectorRuntimeAgent::callFunctionOn):
3109
3110 2012-03-16  Kentaro Hara  <haraken@chromium.org>
3111
3112         The IDL parser should support sequence<T> type
3113         https://bugs.webkit.org/show_bug.cgi?id=81345
3114
3115         Reviewed by Adam Barth.
3116
3117         This patch makes the IDL parser support sequence<T> type.
3118         This patch just makes sequence<T> parseable, and the generated code
3119         for sequence<T> is wrong. This issue will be soon fixed in bug 80696.
3120         This is a preparing patch for bug 80696.
3121
3122         Test: bindings/scripts/test/TestObj.idl
3123
3124         * bindings/scripts/test/TestObj.idl: Added tests for sequence<T>.
3125
3126         * bindings/scripts/IDLStructure.pm: Updated the regular expressions to support sequence<T>.
3127
3128         * bindings/scripts/test/CPP/WebDOMTestObj.cpp: Updated run-bindings-tests results.
3129         (WebDOMTestObj::sequenceAttr):
3130         (WebDOMTestObj::setSequenceAttr):
3131         (WebDOMTestObj::methodWithSequenceArg):
3132         (WebDOMTestObj::methodReturningSequence):
3133         * bindings/scripts/test/CPP/WebDOMTestObj.h:
3134         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
3135         (webkit_dom_test_obj_method_with_sequence_arg):
3136         (webkit_dom_test_obj_method_returning_sequence):
3137         (webkit_dom_test_obj_get_sequence_attr):
3138         (webkit_dom_test_obj_set_sequence_attr):
3139         (webkit_dom_test_obj_get_property):
3140         (webkit_dom_test_obj_class_init):
3141         * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
3142         * bindings/scripts/test/JS/JSTestObj.cpp:
3143         (WebCore):
3144         (WebCore::jsTestObjSequenceAttr):
3145         (WebCore::setJSTestObjSequenceAttr):
3146         (WebCore::jsTestObjPrototypeFunctionMethodWithSequenceArg):
3147         (WebCore::jsTestObjPrototypeFunctionMethodReturningSequence):
3148         * bindings/scripts/test/JS/JSTestObj.h:
3149         (WebCore):
3150         * bindings/scripts/test/ObjC/DOMTestObj.h:
3151         * bindings/scripts/test/ObjC/DOMTestObj.mm:
3152         (-[DOMTestObj sequenceAttr]):
3153         (-[DOMTestObj setSequenceAttr:]):
3154         (-[DOMTestObj methodWithSequenceArg:]):
3155         (-[DOMTestObj methodReturningSequence:]):
3156         * bindings/scripts/test/V8/V8TestObj.cpp:
3157         (WebCore::TestObjInternal::sequenceAttrAttrGetter):
3158         (TestObjInternal):
3159         (WebCore::TestObjInternal::sequenceAttrAttrSetter):
3160         (WebCore::TestObjInternal::methodWithSequenceArgCallback):
3161         (WebCore::TestObjInternal::methodReturningSequenceCallback):
3162         (WebCore):
3163         (WebCore::ConfigureV8TestObjTemplate):
3164
3165 2012-03-16  Ilya Tikhonovsky  <loislo@chromium.org>
3166
3167         Web Inspector: HeapSnapshot: merge two long operations into one.
3168         https://bugs.webkit.org/show_bug.cgi?id=81347
3169
3170         Reviewed by Yury Semikhatsky.
3171
3172         * inspector/front-end/HeapSnapshot.js:
3173         (WebInspector.HeapSnapshot.prototype.aggregates):
3174         (WebInspector.HeapSnapshot.prototype._buildAggregates):
3175         (WebInspector.HeapSnapshot.prototype._buildAggregates.forDominatedNodes):
3176
3177 2012-03-16  Gavin Peters  <gavinp@chromium.org>
3178
3179         Add asserts and improve logging in PageCache.
3180         https://bugs.webkit.org/show_bug.cgi?id=81179
3181
3182         Reviewed by Brady Eidson.
3183
3184         The early exits from logCanCacheFrameDecision had the potential to skew histogram data.  Moving
3185         the DocumentLoader check to the top, but eliminating the early exits is a compromise that keeps
3186         the logged data mostly accurate.
3187
3188         * history/PageCache.cpp:
3189         (WebCore::logCanCacheFrameDecision):
3190
3191 2012-03-16  Yoshifumi Inoue  <yosin@chromium.org>
3192
3193         [Forms] label.form attribute doesn't work
3194         https://bugs.webkit.org/show_bug.cgi?id=80499
3195
3196         Reviewed by Kent Tamura.
3197
3198         This patch changes implementation of label.form of IDL attribute to
3199         compute it to the form element specified by the "form" HTML attribute
3200         or form ancestor when the "form" HTML attribute isn't in HTML.
3201
3202         This patch introduces new function FormAssociatedElement::findAssociatedForm
3203         for sharing code among FormAssociateElement::insertedIntoTree, resetFormOwner
3204         and HTMLLabelElement::form.
3205
3206         No new tests. Update existing tests.
3207
3208         * html/FormAssociatedElement.cpp:
3209         (WebCore::FormAssociatedElement::findAssociatedForm): Added.
3210         (WebCore):
3211         (WebCore::FormAssociatedElement::insertedIntoTree):
3212         (WebCore::FormAssociatedElement::resetFormOwner):
3213         * html/FormAssociatedElement.h:
3214         (FormAssociatedElement):
3215         * html/HTMLLabelElement.cpp: Remove unused include files
3216         (WebCore::HTMLLabelElement::form): Added.
3217
3218 2012-03-16  Kenneth Rohde Christiansen  <kenneth@webkit.org>
3219
3220         Use the normalize method of FloatPoint instead of normalizing manually
3221         https://bugs.webkit.org/show_bug.cgi?id=81343
3222
3223         Reviewed by Simon Hausmann.
3224
3225         * platform/graphics/TiledBackingStore.cpp:
3226         (WebCore::TiledBackingStore::coverWithTilesIfNeeded):
3227         (WebCore::TiledBackingStore::computeCoverAndKeepRect):
3228
3229 2012-03-16  Kentaro Hara  <haraken@chromium.org>
3230
3231         Move Notifications APIs from DOMWindow.idl to DOMWindowNotifications.idl
3232         https://bugs.webkit.org/show_bug.cgi?id=79636
3233
3234         Reviewed by Adam Barth.
3235
3236         For WebKit modularization, this patch moves Notifications-related APIs
3237         from DOMWindow.idl to DOMWindowNotifications.idl.
3238
3239         Tests: fast/notifications/* (No change in test results)
3240
3241         * CMakeLists.txt: Added DOMWindowNotifications.{h,cpp,idl}.
3242         * DerivedSources.make: Ditto.
3243         * DerivedSources.pri: Ditto.
3244         * GNUmakefile.list.am: Ditto.
3245         * Target.pri: Ditto.
3246         * WebCore.gypi: Ditto.
3247         * WebCore.vcproj/WebCore.vcproj: Ditto.
3248
3249         * WebCore.exp.in: Added mangled signatures of webkitNotifications().
3250
3251         * notifications/DOMWindowNotifications.cpp: Added.
3252         (WebCore):
3253         (WebCore::DOMWindowNotifications::DOMWindowNotifications):
3254         (WebCore::DOMWindowNotifications::~DOMWindowNotifications):
3255         (WebCore::DOMWindowNotifications::from):
3256         (WebCore::DOMWindowNotifications::webkitNotifications):
3257         (WebCore::DOMWindowNotifications::ensureWebkitNotifications):
3258         (WebCore::DOMWindowNotifications::disconnectFrame):
3259         * notifications/DOMWindowNotifications.h: Added.
3260         (WebCore):
3261         (DOMWindowNotifications):
3262         * notifications/DOMWindowNotifications.idl: Added.
3263
3264         * page/DOMWindow.cpp: Removed ENABLE(NOTIFICATIONS).
3265         (WebCore::DOMWindow::~DOMWindow):
3266         (WebCore::DOMWindow::willDetachPage):
3267         (WebCore::DOMWindow::clear):
3268         * page/DOMWindow.h: Ditto.
3269         (WebCore):
3270         (DOMWindow):
3271         * page/DOMWindow.idl: Ditto.
3272         * page/Frame.cpp: Ditto.
3273         (WebCore::Frame::willDetachPage):
3274         (WebCore::Frame::transferChildFrameToNewDocument):
3275
3276 2012-03-16  Kentaro Hara  <haraken@chromium.org>
3277
3278         [Performance] Optimize innerHTML and outerHTML
3279         https://bugs.webkit.org/show_bug.cgi?id=81214
3280
3281         Reviewed by Adam Barth.
3282
3283         This patch makes innerHTML and outerHTML 2.4 times faster.
3284
3285         Performance test: https://bugs.webkit.org/attachment.cgi?id=132034
3286         The performance test measures body.innerHTML for 3000 lines of HTML,
3287         which is copied from the HTML spec.
3288
3289         - Chromium/Mac without the patch
3290         div.innerHTML: 1658.6 ms
3291         div.outerHTML: 4859.6 ms
3292         body.innerHTML: 640.2 ms
3293         body.outerHTML: 641.8 ms
3294
3295         - Chromium/Mac with the patch
3296         div.innerHTML:  751.0 ms
3297         div.outerHTML: 2096.0 ms
3298         body.innerHTML: 271.2 ms
3299         body.outerHTML: 271.2 ms
3300
3301         - Chromium/Linux without the patch
3302         div.innerHTML:  950.4 ms
3303         div.outerHTML: 2257.8 ms
3304         body.innerHTML: 452.8 ms
3305         body.outerHTML: 457.6 ms
3306
3307         - Chromium/Linux with the patch
3308         div.innerHTML:  582.4 ms
3309         div.outerHTML: 1283.0 ms
3310         body.innerHTML: 233.0 ms
3311         body.outerHTML: 233.4 ms
3312
3313         - AppleWebKit/Mac without the patch
3314         div.innerHTML:  900.6 ms
3315         div.outerHTML: 2245.2 ms
3316         body.innerHTML: 462.6 ms
3317         body.outerHTML: 468.0 ms
3318
3319         - AppleWebKit/Mac with the patch
3320         div.innerHTML:  529.8  ms
3321         div.outerHTML: 1090.2 ms
3322         body.innerHTML: 239.2 ms
3323         body.outerHTML: 239.2 ms
3324
3325         This patch applies the following two optimizations:
3326
3327         (a) Remove redundant copies between Vector<String> and StringBuilders
3328         in MarkupAccumulator::serializeNodes(), MarkupAccumulator::appendStartTag(),
3329         and MarkupAccumulator::appendEndTag().
3330
3331             (Previous behavior)
3332             - Create a StringBuilder for each tag.
3333             - Append a created string in each StringBuilder to Vector<String>,
3334               parsing the DOM tree.
3335             - After the parsing, allocate a StringBuilder whose size is the sum
3336               of all Strings in Vector<String>.
3337             - Append all Strings in Vector<String> to the StringBuilder.
3338             (New behavior)
3339             - Allocate a StringBuilder with a default buffer size.
3340             - Append created strings to the StringBuilder, incrementally parsing
3341               the DOM tree.
3342
3343         (b) Optimize stringBuilder.append().
3344             (b-1) Replace stringBuilder.append("A") with stringBuilder.append('A').
3345                   stringBuilder.append("A") requires to cast the characters to LChar*,
3346                   and then call strlen("A"). stringBuilder.append('A') is faster.
3347             (b-2) Replace stringBuilder.append("AB") with stringBuilder.append('A')
3348                   and stringBuilder.append('B'). In my experiment, appending characters
3349                   one by one is faster than appending the characters at a breath if the
3350                   number of characters is less than 3.
3351             (b-3) Hard-code a string length; i.e. replace stringBuilder.append("ABCDE")
3352                   with stringBuilder.append("ABCDE", 5). While the former requires to call
3353                   strlen("ABCDE"), the latter does not.
3354
3355         (a) improves performance by 170% ~ 200%. (b) improves performance by 30 ~ 40%.
3356
3357         Tests: fast/dom/Range/range-extract-contents.html
3358                fast/dom/serialize-nodes.xhtml
3359                fast/dom/XMLSerializer.html
3360                and all other tests that use innerHTML or outerHTML.
3361                No change in the test results.
3362
3363         * editing/MarkupAccumulator.cpp:
3364         (WebCore::MarkupAccumulator::serializeNodes):
3365         (WebCore::MarkupAccumulator::appendString):
3366         (WebCore::MarkupAccumulator::appendStartTag):
3367         (WebCore::MarkupAccumulator::appendEndTag):
3368         (WebCore::MarkupAccumulator::concatenateMarkup):
3369         (WebCore::MarkupAccumulator::appendQuotedURLAttributeValue):
3370         (WebCore::MarkupAccumulator::appendComment):
3371         (WebCore::MarkupAccumulator::appendDocumentType):
3372         (WebCore::MarkupAccumulator::appendProcessingInstruction):
3373         (WebCore::MarkupAccumulator::appendOpenTag):
3374         (WebCore::MarkupAccumulator::appendAttribute):
3375         (WebCore::MarkupAccumulator::appendCDATASection):
3376         * editing/MarkupAccumulator.h:
3377         (MarkupAccumulator):
3378
3379 2012-03-16  Kihong Kwon  <kihong.kwon@samsung.com>
3380
3381         Support for Battery Status API
3382         https://bugs.webkit.org/show_bug.cgi?id=62698
3383
3384         Battery Status API is implemented under the Navigator class.
3385         Battery Status API has four types of events, and all events are operated based on a callback mechanism.
3386          : onchargingchange, onchargingtimechange, ondischargingtimechange, onlevelchange.
3387         The battery status can be accessed using BatteryManager(navigator.webkitBattery), and battery status is controlled by BatteryController which manages instances of BatteryManager.
3388         When battery status event is raised, BatteryController calls all registered BatteryManager's event dispatcher.
3389         http://www.w3.org/TR/battery-status/
3390
3391         Reviewed by Adam Barth.
3392
3393         Tests: batterystatus/add-listener-from-callback.html
3394                batterystatus/basic-all-types-of-events.html
3395                batterystatus/basic-operation.html
3396                batterystatus/event-after-navigation.html
3397                batterystatus/multiple-frames.html
3398                batterystatus/updates.html
3399                batterystatus/window-property.html
3400
3401         * CMakeLists.txt:
3402         * Modules/battery/BatteryClient.h: Added.
3403         (WebCore):
3404         (BatteryClient):
3405         (WebCore::BatteryClient::~BatteryClient):
3406         * Modules/battery/BatteryController.cpp: Added.
3407         (WebCore):
3408         (WebCore::BatteryController::BatteryController):
3409         (WebCore::BatteryController::~BatteryController):
3410         (WebCore::BatteryController::create):
3411         (WebCore::BatteryController::addListener):
3412         (WebCore::BatteryController::removeListener):
3413         (WebCore::BatteryController::didChangeBatteryStatus):
3414         (WebCore::BatteryController::supplementName):
3415         (WebCore::BatteryController::isActive):
3416         (WebCore::provideBatteryTo):
3417         * Modules/battery/BatteryController.h: Added.
3418         (WebCore):
3419         (BatteryController):
3420         (WebCore::BatteryController::client):
3421         (WebCore::BatteryController::from):
3422         * Modules/battery/BatteryManager.cpp: Added.
3423         (WebCore):
3424         (WebCore::BatteryManager::create):
3425         (WebCore::BatteryManager::~BatteryManager):
3426         (WebCore::BatteryManager::BatteryManager):
3427         (WebCore::BatteryManager::charging):
3428         (WebCore::BatteryManager::chargingTime):
3429         (WebCore::BatteryManager::dischargingTime):
3430         (WebCore::BatteryManager::level):
3431         (WebCore::BatteryManager::didChangeBatteryStatus):
3432         (WebCore::BatteryManager::suspend):
3433         (WebCore::BatteryManager::resume):
3434         (WebCore::BatteryManager::stop):
3435         * Modules/battery/BatteryManager.h: Added.
3436         (WebCore):
3437         (BatteryManager):
3438         (WebCore::BatteryManager::interfaceName):
3439         (WebCore::BatteryManager::scriptExecutionContext):
3440         (WebCore::BatteryManager::batteryControllerDestroyed):
3441         (WebCore::BatteryManager::canSuspend):
3442         (WebCore::BatteryManager::eventTargetData):
3443         (WebCore::BatteryManager::ensureEventTargetData):
3444         (WebCore::BatteryManager::refEventTarget):
3445         (WebCore::BatteryManager::derefEventTarget):
3446         * Modules/battery/BatteryManager.idl: Added.
3447         * Modules/battery/BatteryStatus.cpp: Added.
3448         (WebCore):
3449         (WebCore::BatteryStatus::create):
3450         (WebCore::BatteryStatus::BatteryStatus):
3451         * Modules/battery/BatteryStatus.h: Added.
3452         (WebCore):
3453         (BatteryStatus):
3454         (WebCore::BatteryStatus::charging):
3455         (WebCore::BatteryStatus::chargingTime):
3456         (WebCore::BatteryStatus::dischargingTime):
3457         (WebCore::BatteryStatus::level):
3458         * Modules/battery/NavigatorBattery.cpp: Added.
3459         (WebCore):
3460         (WebCore::NavigatorBattery::NavigatorBattery):
3461         (WebCore::NavigatorBattery::~NavigatorBattery):
3462         (WebCore::NavigatorBattery::webkitBattery):
3463         (WebCore::NavigatorBattery::from):